(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[33],[
/* 0 */,
/* 1 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(global, module) {var __WEBPACK_AMD_DEFINE_RESULT__;/**
 * @license
 * Lodash <https://lodash.com/>
 * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
 * Released under MIT license <https://lodash.com/license>
 * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
 */
;(function() {

  /** Used as a safe reference for `undefined` in pre-ES5 environments. */
  var undefined;

  /** Used as the semantic version number. */
  var VERSION = '4.17.19';

  /** Used as the size to enable large array optimizations. */
  var LARGE_ARRAY_SIZE = 200;

  /** Error message constants. */
  var CORE_ERROR_TEXT = 'Unsupported core-js use. Try https://npms.io/search?q=ponyfill.',
      FUNC_ERROR_TEXT = 'Expected a function';

  /** Used to stand-in for `undefined` hash values. */
  var HASH_UNDEFINED = '__lodash_hash_undefined__';

  /** Used as the maximum memoize cache size. */
  var MAX_MEMOIZE_SIZE = 500;

  /** Used as the internal argument placeholder. */
  var PLACEHOLDER = '__lodash_placeholder__';

  /** Used to compose bitmasks for cloning. */
  var CLONE_DEEP_FLAG = 1,
      CLONE_FLAT_FLAG = 2,
      CLONE_SYMBOLS_FLAG = 4;

  /** Used to compose bitmasks for value comparisons. */
  var COMPARE_PARTIAL_FLAG = 1,
      COMPARE_UNORDERED_FLAG = 2;

  /** Used to compose bitmasks for function metadata. */
  var WRAP_BIND_FLAG = 1,
      WRAP_BIND_KEY_FLAG = 2,
      WRAP_CURRY_BOUND_FLAG = 4,
      WRAP_CURRY_FLAG = 8,
      WRAP_CURRY_RIGHT_FLAG = 16,
      WRAP_PARTIAL_FLAG = 32,
      WRAP_PARTIAL_RIGHT_FLAG = 64,
      WRAP_ARY_FLAG = 128,
      WRAP_REARG_FLAG = 256,
      WRAP_FLIP_FLAG = 512;

  /** Used as default options for `_.truncate`. */
  var DEFAULT_TRUNC_LENGTH = 30,
      DEFAULT_TRUNC_OMISSION = '...';

  /** Used to detect hot functions by number of calls within a span of milliseconds. */
  var HOT_COUNT = 800,
      HOT_SPAN = 16;

  /** Used to indicate the type of lazy iteratees. */
  var LAZY_FILTER_FLAG = 1,
      LAZY_MAP_FLAG = 2,
      LAZY_WHILE_FLAG = 3;

  /** Used as references for various `Number` constants. */
  var INFINITY = 1 / 0,
      MAX_SAFE_INTEGER = 9007199254740991,
      MAX_INTEGER = 1.7976931348623157e+308,
      NAN = 0 / 0;

  /** Used as references for the maximum length and index of an array. */
  var MAX_ARRAY_LENGTH = 4294967295,
      MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1,
      HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1;

  /** Used to associate wrap methods with their bit flags. */
  var wrapFlags = [
    ['ary', WRAP_ARY_FLAG],
    ['bind', WRAP_BIND_FLAG],
    ['bindKey', WRAP_BIND_KEY_FLAG],
    ['curry', WRAP_CURRY_FLAG],
    ['curryRight', WRAP_CURRY_RIGHT_FLAG],
    ['flip', WRAP_FLIP_FLAG],
    ['partial', WRAP_PARTIAL_FLAG],
    ['partialRight', WRAP_PARTIAL_RIGHT_FLAG],
    ['rearg', WRAP_REARG_FLAG]
  ];

  /** `Object#toString` result references. */
  var argsTag = '[object Arguments]',
      arrayTag = '[object Array]',
      asyncTag = '[object AsyncFunction]',
      boolTag = '[object Boolean]',
      dateTag = '[object Date]',
      domExcTag = '[object DOMException]',
      errorTag = '[object Error]',
      funcTag = '[object Function]',
      genTag = '[object GeneratorFunction]',
      mapTag = '[object Map]',
      numberTag = '[object Number]',
      nullTag = '[object Null]',
      objectTag = '[object Object]',
      promiseTag = '[object Promise]',
      proxyTag = '[object Proxy]',
      regexpTag = '[object RegExp]',
      setTag = '[object Set]',
      stringTag = '[object String]',
      symbolTag = '[object Symbol]',
      undefinedTag = '[object Undefined]',
      weakMapTag = '[object WeakMap]',
      weakSetTag = '[object WeakSet]';

  var arrayBufferTag = '[object ArrayBuffer]',
      dataViewTag = '[object DataView]',
      float32Tag = '[object Float32Array]',
      float64Tag = '[object Float64Array]',
      int8Tag = '[object Int8Array]',
      int16Tag = '[object Int16Array]',
      int32Tag = '[object Int32Array]',
      uint8Tag = '[object Uint8Array]',
      uint8ClampedTag = '[object Uint8ClampedArray]',
      uint16Tag = '[object Uint16Array]',
      uint32Tag = '[object Uint32Array]';

  /** Used to match empty string literals in compiled template source. */
  var reEmptyStringLeading = /\b__p \+= '';/g,
      reEmptyStringMiddle = /\b(__p \+=) '' \+/g,
      reEmptyStringTrailing = /(__e\(.*?\)|\b__t\)) \+\n'';/g;

  /** Used to match HTML entities and HTML characters. */
  var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g,
      reUnescapedHtml = /[&<>"']/g,
      reHasEscapedHtml = RegExp(reEscapedHtml.source),
      reHasUnescapedHtml = RegExp(reUnescapedHtml.source);

  /** Used to match template delimiters. */
  var reEscape = /<%-([\s\S]+?)%>/g,
      reEvaluate = /<%([\s\S]+?)%>/g,
      reInterpolate = /<%=([\s\S]+?)%>/g;

  /** Used to match property names within property paths. */
  var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
      reIsPlainProp = /^\w*$/,
      rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;

  /**
   * Used to match `RegExp`
   * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).
   */
  var reRegExpChar = /[\\^$.*+?()[\]{}|]/g,
      reHasRegExpChar = RegExp(reRegExpChar.source);

  /** Used to match leading and trailing whitespace. */
  var reTrim = /^\s+|\s+$/g,
      reTrimStart = /^\s+/,
      reTrimEnd = /\s+$/;

  /** Used to match wrap detail comments. */
  var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,
      reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/,
      reSplitDetails = /,? & /;

  /** Used to match words composed of alphanumeric characters. */
  var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;

  /** Used to match backslashes in property paths. */
  var reEscapeChar = /\\(\\)?/g;

  /**
   * Used to match
   * [ES template delimiters](http://ecma-international.org/ecma-262/7.0/#sec-template-literal-lexical-components).
   */
  var reEsTemplate = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g;

  /** Used to match `RegExp` flags from their coerced string values. */
  var reFlags = /\w*$/;

  /** Used to detect bad signed hexadecimal string values. */
  var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;

  /** Used to detect binary string values. */
  var reIsBinary = /^0b[01]+$/i;

  /** Used to detect host constructors (Safari). */
  var reIsHostCtor = /^\[object .+?Constructor\]$/;

  /** Used to detect octal string values. */
  var reIsOctal = /^0o[0-7]+$/i;

  /** Used to detect unsigned integer values. */
  var reIsUint = /^(?:0|[1-9]\d*)$/;

  /** Used to match Latin Unicode letters (excluding mathematical operators). */
  var reLatin = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g;

  /** Used to ensure capturing order of template delimiters. */
  var reNoMatch = /($^)/;

  /** Used to match unescaped characters in compiled string literals. */
  var reUnescapedString = /['\n\r\u2028\u2029\\]/g;

  /** Used to compose unicode character classes. */
  var rsAstralRange = '\\ud800-\\udfff',
      rsComboMarksRange = '\\u0300-\\u036f',
      reComboHalfMarksRange = '\\ufe20-\\ufe2f',
      rsComboSymbolsRange = '\\u20d0-\\u20ff',
      rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,
      rsDingbatRange = '\\u2700-\\u27bf',
      rsLowerRange = 'a-z\\xdf-\\xf6\\xf8-\\xff',
      rsMathOpRange = '\\xac\\xb1\\xd7\\xf7',
      rsNonCharRange = '\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf',
      rsPunctuationRange = '\\u2000-\\u206f',
      rsSpaceRange = ' \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000',
      rsUpperRange = 'A-Z\\xc0-\\xd6\\xd8-\\xde',
      rsVarRange = '\\ufe0e\\ufe0f',
      rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;

  /** Used to compose unicode capture groups. */
  var rsApos = "['\u2019]",
      rsAstral = '[' + rsAstralRange + ']',
      rsBreak = '[' + rsBreakRange + ']',
      rsCombo = '[' + rsComboRange + ']',
      rsDigits = '\\d+',
      rsDingbat = '[' + rsDingbatRange + ']',
      rsLower = '[' + rsLowerRange + ']',
      rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',
      rsFitz = '\\ud83c[\\udffb-\\udfff]',
      rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',
      rsNonAstral = '[^' + rsAstralRange + ']',
      rsRegional = '(?:\\ud83c[\\udde6-\\uddff]){2}',
      rsSurrPair = '[\\ud800-\\udbff][\\udc00-\\udfff]',
      rsUpper = '[' + rsUpperRange + ']',
      rsZWJ = '\\u200d';

  /** Used to compose unicode regexes. */
  var rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',
      rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',
      rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',
      rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',
      reOptMod = rsModifier + '?',
      rsOptVar = '[' + rsVarRange + ']?',
      rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',
      rsOrdLower = '\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])',
      rsOrdUpper = '\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])',
      rsSeq = rsOptVar + reOptMod + rsOptJoin,
      rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq,
      rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';

  /** Used to match apostrophes. */
  var reApos = RegExp(rsApos, 'g');

  /**
   * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and
   * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).
   */
  var reComboMark = RegExp(rsCombo, 'g');

  /** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */
  var reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');

  /** Used to match complex or compound words. */
  var reUnicodeWord = RegExp([
    rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',
    rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',
    rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,
    rsUpper + '+' + rsOptContrUpper,
    rsOrdUpper,
    rsOrdLower,
    rsDigits,
    rsEmoji
  ].join('|'), 'g');

  /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */
  var reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange  + rsComboRange + rsVarRange + ']');

  /** Used to detect strings that need a more robust regexp to match words. */
  var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;

  /** Used to assign default `context` object properties. */
  var contextProps = [
    'Array', 'Buffer', 'DataView', 'Date', 'Error', 'Float32Array', 'Float64Array',
    'Function', 'Int8Array', 'Int16Array', 'Int32Array', 'Map', 'Math', 'Object',
    'Promise', 'RegExp', 'Set', 'String', 'Symbol', 'TypeError', 'Uint8Array',
    'Uint8ClampedArray', 'Uint16Array', 'Uint32Array', 'WeakMap',
    '_', 'clearTimeout', 'isFinite', 'parseInt', 'setTimeout'
  ];

  /** Used to make template sourceURLs easier to identify. */
  var templateCounter = -1;

  /** Used to identify `toStringTag` values of typed arrays. */
  var typedArrayTags = {};
  typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =
  typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =
  typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =
  typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =
  typedArrayTags[uint32Tag] = true;
  typedArrayTags[argsTag] = typedArrayTags[arrayTag] =
  typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =
  typedArrayTags[dataViewTag] = typedArrayTags[dateTag] =
  typedArrayTags[errorTag] = typedArrayTags[funcTag] =
  typedArrayTags[mapTag] = typedArrayTags[numberTag] =
  typedArrayTags[objectTag] = typedArrayTags[regexpTag] =
  typedArrayTags[setTag] = typedArrayTags[stringTag] =
  typedArrayTags[weakMapTag] = false;

  /** Used to identify `toStringTag` values supported by `_.clone`. */
  var cloneableTags = {};
  cloneableTags[argsTag] = cloneableTags[arrayTag] =
  cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] =
  cloneableTags[boolTag] = cloneableTags[dateTag] =
  cloneableTags[float32Tag] = cloneableTags[float64Tag] =
  cloneableTags[int8Tag] = cloneableTags[int16Tag] =
  cloneableTags[int32Tag] = cloneableTags[mapTag] =
  cloneableTags[numberTag] = cloneableTags[objectTag] =
  cloneableTags[regexpTag] = cloneableTags[setTag] =
  cloneableTags[stringTag] = cloneableTags[symbolTag] =
  cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =
  cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
  cloneableTags[errorTag] = cloneableTags[funcTag] =
  cloneableTags[weakMapTag] = false;

  /** Used to map Latin Unicode letters to basic Latin letters. */
  var deburredLetters = {
    // Latin-1 Supplement block.
    '\xc0': 'A',  '\xc1': 'A', '\xc2': 'A', '\xc3': 'A', '\xc4': 'A', '\xc5': 'A',
    '\xe0': 'a',  '\xe1': 'a', '\xe2': 'a', '\xe3': 'a', '\xe4': 'a', '\xe5': 'a',
    '\xc7': 'C',  '\xe7': 'c',
    '\xd0': 'D',  '\xf0': 'd',
    '\xc8': 'E',  '\xc9': 'E', '\xca': 'E', '\xcb': 'E',
    '\xe8': 'e',  '\xe9': 'e', '\xea': 'e', '\xeb': 'e',
    '\xcc': 'I',  '\xcd': 'I', '\xce': 'I', '\xcf': 'I',
    '\xec': 'i',  '\xed': 'i', '\xee': 'i', '\xef': 'i',
    '\xd1': 'N',  '\xf1': 'n',
    '\xd2': 'O',  '\xd3': 'O', '\xd4': 'O', '\xd5': 'O', '\xd6': 'O', '\xd8': 'O',
    '\xf2': 'o',  '\xf3': 'o', '\xf4': 'o', '\xf5': 'o', '\xf6': 'o', '\xf8': 'o',
    '\xd9': 'U',  '\xda': 'U', '\xdb': 'U', '\xdc': 'U',
    '\xf9': 'u',  '\xfa': 'u', '\xfb': 'u', '\xfc': 'u',
    '\xdd': 'Y',  '\xfd': 'y', '\xff': 'y',
    '\xc6': 'Ae', '\xe6': 'ae',
    '\xde': 'Th', '\xfe': 'th',
    '\xdf': 'ss',
    // Latin Extended-A block.
    '\u0100': 'A',  '\u0102': 'A', '\u0104': 'A',
    '\u0101': 'a',  '\u0103': 'a', '\u0105': 'a',
    '\u0106': 'C',  '\u0108': 'C', '\u010a': 'C', '\u010c': 'C',
    '\u0107': 'c',  '\u0109': 'c', '\u010b': 'c', '\u010d': 'c',
    '\u010e': 'D',  '\u0110': 'D', '\u010f': 'd', '\u0111': 'd',
    '\u0112': 'E',  '\u0114': 'E', '\u0116': 'E', '\u0118': 'E', '\u011a': 'E',
    '\u0113': 'e',  '\u0115': 'e', '\u0117': 'e', '\u0119': 'e', '\u011b': 'e',
    '\u011c': 'G',  '\u011e': 'G', '\u0120': 'G', '\u0122': 'G',
    '\u011d': 'g',  '\u011f': 'g', '\u0121': 'g', '\u0123': 'g',
    '\u0124': 'H',  '\u0126': 'H', '\u0125': 'h', '\u0127': 'h',
    '\u0128': 'I',  '\u012a': 'I', '\u012c': 'I', '\u012e': 'I', '\u0130': 'I',
    '\u0129': 'i',  '\u012b': 'i', '\u012d': 'i', '\u012f': 'i', '\u0131': 'i',
    '\u0134': 'J',  '\u0135': 'j',
    '\u0136': 'K',  '\u0137': 'k', '\u0138': 'k',
    '\u0139': 'L',  '\u013b': 'L', '\u013d': 'L', '\u013f': 'L', '\u0141': 'L',
    '\u013a': 'l',  '\u013c': 'l', '\u013e': 'l', '\u0140': 'l', '\u0142': 'l',
    '\u0143': 'N',  '\u0145': 'N', '\u0147': 'N', '\u014a': 'N',
    '\u0144': 'n',  '\u0146': 'n', '\u0148': 'n', '\u014b': 'n',
    '\u014c': 'O',  '\u014e': 'O', '\u0150': 'O',
    '\u014d': 'o',  '\u014f': 'o', '\u0151': 'o',
    '\u0154': 'R',  '\u0156': 'R', '\u0158': 'R',
    '\u0155': 'r',  '\u0157': 'r', '\u0159': 'r',
    '\u015a': 'S',  '\u015c': 'S', '\u015e': 'S', '\u0160': 'S',
    '\u015b': 's',  '\u015d': 's', '\u015f': 's', '\u0161': 's',
    '\u0162': 'T',  '\u0164': 'T', '\u0166': 'T',
    '\u0163': 't',  '\u0165': 't', '\u0167': 't',
    '\u0168': 'U',  '\u016a': 'U', '\u016c': 'U', '\u016e': 'U', '\u0170': 'U', '\u0172': 'U',
    '\u0169': 'u',  '\u016b': 'u', '\u016d': 'u', '\u016f': 'u', '\u0171': 'u', '\u0173': 'u',
    '\u0174': 'W',  '\u0175': 'w',
    '\u0176': 'Y',  '\u0177': 'y', '\u0178': 'Y',
    '\u0179': 'Z',  '\u017b': 'Z', '\u017d': 'Z',
    '\u017a': 'z',  '\u017c': 'z', '\u017e': 'z',
    '\u0132': 'IJ', '\u0133': 'ij',
    '\u0152': 'Oe', '\u0153': 'oe',
    '\u0149': "'n", '\u017f': 's'
  };

  /** Used to map characters to HTML entities. */
  var htmlEscapes = {
    '&': '&amp;',
    '<': '&lt;',
    '>': '&gt;',
    '"': '&quot;',
    "'": '&#39;'
  };

  /** Used to map HTML entities to characters. */
  var htmlUnescapes = {
    '&amp;': '&',
    '&lt;': '<',
    '&gt;': '>',
    '&quot;': '"',
    '&#39;': "'"
  };

  /** Used to escape characters for inclusion in compiled string literals. */
  var stringEscapes = {
    '\\': '\\',
    "'": "'",
    '\n': 'n',
    '\r': 'r',
    '\u2028': 'u2028',
    '\u2029': 'u2029'
  };

  /** Built-in method references without a dependency on `root`. */
  var freeParseFloat = parseFloat,
      freeParseInt = parseInt;

  /** Detect free variable `global` from Node.js. */
  var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;

  /** Detect free variable `self`. */
  var freeSelf = typeof self == 'object' && self && self.Object === Object && self;

  /** Used as a reference to the global object. */
  var root = freeGlobal || freeSelf || Function('return this')();

  /** Detect free variable `exports`. */
  var freeExports =  true && exports && !exports.nodeType && exports;

  /** Detect free variable `module`. */
  var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;

  /** Detect the popular CommonJS extension `module.exports`. */
  var moduleExports = freeModule && freeModule.exports === freeExports;

  /** Detect free variable `process` from Node.js. */
  var freeProcess = moduleExports && freeGlobal.process;

  /** Used to access faster Node.js helpers. */
  var nodeUtil = (function() {
    try {
      // Use `util.types` for Node.js 10+.
      var types = freeModule && freeModule.require && freeModule.require('util').types;

      if (types) {
        return types;
      }

      // Legacy `process.binding('util')` for Node.js < 10.
      return freeProcess && freeProcess.binding && freeProcess.binding('util');
    } catch (e) {}
  }());

  /* Node.js helper references. */
  var nodeIsArrayBuffer = nodeUtil && nodeUtil.isArrayBuffer,
      nodeIsDate = nodeUtil && nodeUtil.isDate,
      nodeIsMap = nodeUtil && nodeUtil.isMap,
      nodeIsRegExp = nodeUtil && nodeUtil.isRegExp,
      nodeIsSet = nodeUtil && nodeUtil.isSet,
      nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;

  /*--------------------------------------------------------------------------*/

  /**
   * A faster alternative to `Function#apply`, this function invokes `func`
   * with the `this` binding of `thisArg` and the arguments of `args`.
   *
   * @private
   * @param {Function} func The function to invoke.
   * @param {*} thisArg The `this` binding of `func`.
   * @param {Array} args The arguments to invoke `func` with.
   * @returns {*} Returns the result of `func`.
   */
  function apply(func, thisArg, args) {
    switch (args.length) {
      case 0: return func.call(thisArg);
      case 1: return func.call(thisArg, args[0]);
      case 2: return func.call(thisArg, args[0], args[1]);
      case 3: return func.call(thisArg, args[0], args[1], args[2]);
    }
    return func.apply(thisArg, args);
  }

  /**
   * A specialized version of `baseAggregator` for arrays.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} setter The function to set `accumulator` values.
   * @param {Function} iteratee The iteratee to transform keys.
   * @param {Object} accumulator The initial aggregated object.
   * @returns {Function} Returns `accumulator`.
   */
  function arrayAggregator(array, setter, iteratee, accumulator) {
    var index = -1,
        length = array == null ? 0 : array.length;

    while (++index < length) {
      var value = array[index];
      setter(accumulator, value, iteratee(value), array);
    }
    return accumulator;
  }

  /**
   * A specialized version of `_.forEach` for arrays without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @returns {Array} Returns `array`.
   */
  function arrayEach(array, iteratee) {
    var index = -1,
        length = array == null ? 0 : array.length;

    while (++index < length) {
      if (iteratee(array[index], index, array) === false) {
        break;
      }
    }
    return array;
  }

  /**
   * A specialized version of `_.forEachRight` for arrays without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @returns {Array} Returns `array`.
   */
  function arrayEachRight(array, iteratee) {
    var length = array == null ? 0 : array.length;

    while (length--) {
      if (iteratee(array[length], length, array) === false) {
        break;
      }
    }
    return array;
  }

  /**
   * A specialized version of `_.every` for arrays without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} predicate The function invoked per iteration.
   * @returns {boolean} Returns `true` if all elements pass the predicate check,
   *  else `false`.
   */
  function arrayEvery(array, predicate) {
    var index = -1,
        length = array == null ? 0 : array.length;

    while (++index < length) {
      if (!predicate(array[index], index, array)) {
        return false;
      }
    }
    return true;
  }

  /**
   * A specialized version of `_.filter` for arrays without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} predicate The function invoked per iteration.
   * @returns {Array} Returns the new filtered array.
   */
  function arrayFilter(array, predicate) {
    var index = -1,
        length = array == null ? 0 : array.length,
        resIndex = 0,
        result = [];

    while (++index < length) {
      var value = array[index];
      if (predicate(value, index, array)) {
        result[resIndex++] = value;
      }
    }
    return result;
  }

  /**
   * A specialized version of `_.includes` for arrays without support for
   * specifying an index to search from.
   *
   * @private
   * @param {Array} [array] The array to inspect.
   * @param {*} target The value to search for.
   * @returns {boolean} Returns `true` if `target` is found, else `false`.
   */
  function arrayIncludes(array, value) {
    var length = array == null ? 0 : array.length;
    return !!length && baseIndexOf(array, value, 0) > -1;
  }

  /**
   * This function is like `arrayIncludes` except that it accepts a comparator.
   *
   * @private
   * @param {Array} [array] The array to inspect.
   * @param {*} target The value to search for.
   * @param {Function} comparator The comparator invoked per element.
   * @returns {boolean} Returns `true` if `target` is found, else `false`.
   */
  function arrayIncludesWith(array, value, comparator) {
    var index = -1,
        length = array == null ? 0 : array.length;

    while (++index < length) {
      if (comparator(value, array[index])) {
        return true;
      }
    }
    return false;
  }

  /**
   * A specialized version of `_.map` for arrays without support for iteratee
   * shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @returns {Array} Returns the new mapped array.
   */
  function arrayMap(array, iteratee) {
    var index = -1,
        length = array == null ? 0 : array.length,
        result = Array(length);

    while (++index < length) {
      result[index] = iteratee(array[index], index, array);
    }
    return result;
  }

  /**
   * Appends the elements of `values` to `array`.
   *
   * @private
   * @param {Array} array The array to modify.
   * @param {Array} values The values to append.
   * @returns {Array} Returns `array`.
   */
  function arrayPush(array, values) {
    var index = -1,
        length = values.length,
        offset = array.length;

    while (++index < length) {
      array[offset + index] = values[index];
    }
    return array;
  }

  /**
   * A specialized version of `_.reduce` for arrays without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @param {*} [accumulator] The initial value.
   * @param {boolean} [initAccum] Specify using the first element of `array` as
   *  the initial value.
   * @returns {*} Returns the accumulated value.
   */
  function arrayReduce(array, iteratee, accumulator, initAccum) {
    var index = -1,
        length = array == null ? 0 : array.length;

    if (initAccum && length) {
      accumulator = array[++index];
    }
    while (++index < length) {
      accumulator = iteratee(accumulator, array[index], index, array);
    }
    return accumulator;
  }

  /**
   * A specialized version of `_.reduceRight` for arrays without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @param {*} [accumulator] The initial value.
   * @param {boolean} [initAccum] Specify using the last element of `array` as
   *  the initial value.
   * @returns {*} Returns the accumulated value.
   */
  function arrayReduceRight(array, iteratee, accumulator, initAccum) {
    var length = array == null ? 0 : array.length;
    if (initAccum && length) {
      accumulator = array[--length];
    }
    while (length--) {
      accumulator = iteratee(accumulator, array[length], length, array);
    }
    return accumulator;
  }

  /**
   * A specialized version of `_.some` for arrays without support for iteratee
   * shorthands.
   *
   * @private
   * @param {Array} [array] The array to iterate over.
   * @param {Function} predicate The function invoked per iteration.
   * @returns {boolean} Returns `true` if any element passes the predicate check,
   *  else `false`.
   */
  function arraySome(array, predicate) {
    var index = -1,
        length = array == null ? 0 : array.length;

    while (++index < length) {
      if (predicate(array[index], index, array)) {
        return true;
      }
    }
    return false;
  }

  /**
   * Gets the size of an ASCII `string`.
   *
   * @private
   * @param {string} string The string inspect.
   * @returns {number} Returns the string size.
   */
  var asciiSize = baseProperty('length');

  /**
   * Converts an ASCII `string` to an array.
   *
   * @private
   * @param {string} string The string to convert.
   * @returns {Array} Returns the converted array.
   */
  function asciiToArray(string) {
    return string.split('');
  }

  /**
   * Splits an ASCII `string` into an array of its words.
   *
   * @private
   * @param {string} The string to inspect.
   * @returns {Array} Returns the words of `string`.
   */
  function asciiWords(string) {
    return string.match(reAsciiWord) || [];
  }

  /**
   * The base implementation of methods like `_.findKey` and `_.findLastKey`,
   * without support for iteratee shorthands, which iterates over `collection`
   * using `eachFunc`.
   *
   * @private
   * @param {Array|Object} collection The collection to inspect.
   * @param {Function} predicate The function invoked per iteration.
   * @param {Function} eachFunc The function to iterate over `collection`.
   * @returns {*} Returns the found element or its key, else `undefined`.
   */
  function baseFindKey(collection, predicate, eachFunc) {
    var result;
    eachFunc(collection, function(value, key, collection) {
      if (predicate(value, key, collection)) {
        result = key;
        return false;
      }
    });
    return result;
  }

  /**
   * The base implementation of `_.findIndex` and `_.findLastIndex` without
   * support for iteratee shorthands.
   *
   * @private
   * @param {Array} array The array to inspect.
   * @param {Function} predicate The function invoked per iteration.
   * @param {number} fromIndex The index to search from.
   * @param {boolean} [fromRight] Specify iterating from right to left.
   * @returns {number} Returns the index of the matched value, else `-1`.
   */
  function baseFindIndex(array, predicate, fromIndex, fromRight) {
    var length = array.length,
        index = fromIndex + (fromRight ? 1 : -1);

    while ((fromRight ? index-- : ++index < length)) {
      if (predicate(array[index], index, array)) {
        return index;
      }
    }
    return -1;
  }

  /**
   * The base implementation of `_.indexOf` without `fromIndex` bounds checks.
   *
   * @private
   * @param {Array} array The array to inspect.
   * @param {*} value The value to search for.
   * @param {number} fromIndex The index to search from.
   * @returns {number} Returns the index of the matched value, else `-1`.
   */
  function baseIndexOf(array, value, fromIndex) {
    return value === value
      ? strictIndexOf(array, value, fromIndex)
      : baseFindIndex(array, baseIsNaN, fromIndex);
  }

  /**
   * This function is like `baseIndexOf` except that it accepts a comparator.
   *
   * @private
   * @param {Array} array The array to inspect.
   * @param {*} value The value to search for.
   * @param {number} fromIndex The index to search from.
   * @param {Function} comparator The comparator invoked per element.
   * @returns {number} Returns the index of the matched value, else `-1`.
   */
  function baseIndexOfWith(array, value, fromIndex, comparator) {
    var index = fromIndex - 1,
        length = array.length;

    while (++index < length) {
      if (comparator(array[index], value)) {
        return index;
      }
    }
    return -1;
  }

  /**
   * The base implementation of `_.isNaN` without support for number objects.
   *
   * @private
   * @param {*} value The value to check.
   * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.
   */
  function baseIsNaN(value) {
    return value !== value;
  }

  /**
   * The base implementation of `_.mean` and `_.meanBy` without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} array The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @returns {number} Returns the mean.
   */
  function baseMean(array, iteratee) {
    var length = array == null ? 0 : array.length;
    return length ? (baseSum(array, iteratee) / length) : NAN;
  }

  /**
   * The base implementation of `_.property` without support for deep paths.
   *
   * @private
   * @param {string} key The key of the property to get.
   * @returns {Function} Returns the new accessor function.
   */
  function baseProperty(key) {
    return function(object) {
      return object == null ? undefined : object[key];
    };
  }

  /**
   * The base implementation of `_.propertyOf` without support for deep paths.
   *
   * @private
   * @param {Object} object The object to query.
   * @returns {Function} Returns the new accessor function.
   */
  function basePropertyOf(object) {
    return function(key) {
      return object == null ? undefined : object[key];
    };
  }

  /**
   * The base implementation of `_.reduce` and `_.reduceRight`, without support
   * for iteratee shorthands, which iterates over `collection` using `eachFunc`.
   *
   * @private
   * @param {Array|Object} collection The collection to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @param {*} accumulator The initial value.
   * @param {boolean} initAccum Specify using the first or last element of
   *  `collection` as the initial value.
   * @param {Function} eachFunc The function to iterate over `collection`.
   * @returns {*} Returns the accumulated value.
   */
  function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) {
    eachFunc(collection, function(value, index, collection) {
      accumulator = initAccum
        ? (initAccum = false, value)
        : iteratee(accumulator, value, index, collection);
    });
    return accumulator;
  }

  /**
   * The base implementation of `_.sortBy` which uses `comparer` to define the
   * sort order of `array` and replaces criteria objects with their corresponding
   * values.
   *
   * @private
   * @param {Array} array The array to sort.
   * @param {Function} comparer The function to define sort order.
   * @returns {Array} Returns `array`.
   */
  function baseSortBy(array, comparer) {
    var length = array.length;

    array.sort(comparer);
    while (length--) {
      array[length] = array[length].value;
    }
    return array;
  }

  /**
   * The base implementation of `_.sum` and `_.sumBy` without support for
   * iteratee shorthands.
   *
   * @private
   * @param {Array} array The array to iterate over.
   * @param {Function} iteratee The function invoked per iteration.
   * @returns {number} Returns the sum.
   */
  function baseSum(array, iteratee) {
    var result,
        index = -1,
        length = array.length;

    while (++index < length) {
      var current = iteratee(array[index]);
      if (current !== undefined) {
        result = result === undefined ? current : (result + current);
      }
    }
    return result;
  }

  /**
   * The base implementation of `_.times` without support for iteratee shorthands
   * or max array length checks.
   *
   * @private
   * @param {number} n The number of times to invoke `iteratee`.
   * @param {Function} iteratee The function invoked per iteration.
   * @returns {Array} Returns the array of results.
   */
  function baseTimes(n, iteratee) {
    var index = -1,
        result = Array(n);

    while (++index < n) {
      result[index] = iteratee(index);
    }
    return result;
  }

  /**
   * The base implementation of `_.toPairs` and `_.toPairsIn` which creates an array
   * of key-value pairs for `object` corresponding to the property names of `props`.
   *
   * @private
   * @param {Object} object The object to query.
   * @param {Array} props The property names to get values for.
   * @returns {Object} Returns the key-value pairs.
   */
  function baseToPairs(object, props) {
    return arrayMap(props, function(key) {
      return [key, object[key]];
    });
  }

  /**
   * The base implementation of `_.unary` without support for storing metadata.
   *
   * @private
   * @param {Function} func The function to cap arguments for.
   * @returns {Function} Returns the new capped function.
   */
  function baseUnary(func) {
    return function(value) {
      return func(value);
    };
  }

  /**
   * The base implementation of `_.values` and `_.valuesIn` which creates an
   * array of `object` property values corresponding to the property names
   * of `props`.
   *
   * @private
   * @param {Object} object The object to query.
   * @param {Array} props The property names to get values for.
   * @returns {Object} Returns the array of property values.
   */
  function baseValues(object, props) {
    return arrayMap(props, function(key) {
      return object[key];
    });
  }

  /**
   * Checks if a `cache` value for `key` exists.
   *
   * @private
   * @param {Object} cache The cache to query.
   * @param {string} key The key of the entry to check.
   * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
   */
  function cacheHas(cache, key) {
    return cache.has(key);
  }

  /**
   * Used by `_.trim` and `_.trimStart` to get the index of the first string symbol
   * that is not found in the character symbols.
   *
   * @private
   * @param {Array} strSymbols The string symbols to inspect.
   * @param {Array} chrSymbols The character symbols to find.
   * @returns {number} Returns the index of the first unmatched string symbol.
   */
  function charsStartIndex(strSymbols, chrSymbols) {
    var index = -1,
        length = strSymbols.length;

    while (++index < length && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {}
    return index;
  }

  /**
   * Used by `_.trim` and `_.trimEnd` to get the index of the last string symbol
   * that is not found in the character symbols.
   *
   * @private
   * @param {Array} strSymbols The string symbols to inspect.
   * @param {Array} chrSymbols The character symbols to find.
   * @returns {number} Returns the index of the last unmatched string symbol.
   */
  function charsEndIndex(strSymbols, chrSymbols) {
    var index = strSymbols.length;

    while (index-- && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {}
    return index;
  }

  /**
   * Gets the number of `placeholder` occurrences in `array`.
   *
   * @private
   * @param {Array} array The array to inspect.
   * @param {*} placeholder The placeholder to search for.
   * @returns {number} Returns the placeholder count.
   */
  function countHolders(array, placeholder) {
    var length = array.length,
        result = 0;

    while (length--) {
      if (array[length] === placeholder) {
        ++result;
      }
    }
    return result;
  }

  /**
   * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A
   * letters to basic Latin letters.
   *
   * @private
   * @param {string} letter The matched letter to deburr.
   * @returns {string} Returns the deburred letter.
   */
  var deburrLetter = basePropertyOf(deburredLetters);

  /**
   * Used by `_.escape` to convert characters to HTML entities.
   *
   * @private
   * @param {string} chr The matched character to escape.
   * @returns {string} Returns the escaped character.
   */
  var escapeHtmlChar = basePropertyOf(htmlEscapes);

  /**
   * Used by `_.template` to escape characters for inclusion in compiled string literals.
   *
   * @private
   * @param {string} chr The matched character to escape.
   * @returns {string} Returns the escaped character.
   */
  function escapeStringChar(chr) {
    return '\\' + stringEscapes[chr];
  }

  /**
   * Gets the value at `key` of `object`.
   *
   * @private
   * @param {Object} [object] The object to query.
   * @param {string} key The key of the property to get.
   * @returns {*} Returns the property value.
   */
  function getValue(object, key) {
    return object == null ? undefined : object[key];
  }

  /**
   * Checks if `string` contains Unicode symbols.
   *
   * @private
   * @param {string} string The string to inspect.
   * @returns {boolean} Returns `true` if a symbol is found, else `false`.
   */
  function hasUnicode(string) {
    return reHasUnicode.test(string);
  }

  /**
   * Checks if `string` contains a word composed of Unicode symbols.
   *
   * @private
   * @param {string} string The string to inspect.
   * @returns {boolean} Returns `true` if a word is found, else `false`.
   */
  function hasUnicodeWord(string) {
    return reHasUnicodeWord.test(string);
  }

  /**
   * Converts `iterator` to an array.
   *
   * @private
   * @param {Object} iterator The iterator to convert.
   * @returns {Array} Returns the converted array.
   */
  function iteratorToArray(iterator) {
    var data,
        result = [];

    while (!(data = iterator.next()).done) {
      result.push(data.value);
    }
    return result;
  }

  /**
   * Converts `map` to its key-value pairs.
   *
   * @private
   * @param {Object} map The map to convert.
   * @returns {Array} Returns the key-value pairs.
   */
  function mapToArray(map) {
    var index = -1,
        result = Array(map.size);

    map.forEach(function(value, key) {
      result[++index] = [key, value];
    });
    return result;
  }

  /**
   * Creates a unary function that invokes `func` with its argument transformed.
   *
   * @private
   * @param {Function} func The function to wrap.
   * @param {Function} transform The argument transform.
   * @returns {Function} Returns the new function.
   */
  function overArg(func, transform) {
    return function(arg) {
      return func(transform(arg));
    };
  }

  /**
   * Replaces all `placeholder` elements in `array` with an internal placeholder
   * and returns an array of their indexes.
   *
   * @private
   * @param {Array} array The array to modify.
   * @param {*} placeholder The placeholder to replace.
   * @returns {Array} Returns the new array of placeholder indexes.
   */
  function replaceHolders(array, placeholder) {
    var index = -1,
        length = array.length,
        resIndex = 0,
        result = [];

    while (++index < length) {
      var value = array[index];
      if (value === placeholder || value === PLACEHOLDER) {
        array[index] = PLACEHOLDER;
        result[resIndex++] = index;
      }
    }
    return result;
  }

  /**
   * Converts `set` to an array of its values.
   *
   * @private
   * @param {Object} set The set to convert.
   * @returns {Array} Returns the values.
   */
  function setToArray(set) {
    var index = -1,
        result = Array(set.size);

    set.forEach(function(value) {
      result[++index] = value;
    });
    return result;
  }

  /**
   * Converts `set` to its value-value pairs.
   *
   * @private
   * @param {Object} set The set to convert.
   * @returns {Array} Returns the value-value pairs.
   */
  function setToPairs(set) {
    var index = -1,
        result = Array(set.size);

    set.forEach(function(value) {
      result[++index] = [value, value];
    });
    return result;
  }

  /**
   * A specialized version of `_.indexOf` which performs strict equality
   * comparisons of values, i.e. `===`.
   *
   * @private
   * @param {Array} array The array to inspect.
   * @param {*} value The value to search for.
   * @param {number} fromIndex The index to search from.
   * @returns {number} Returns the index of the matched value, else `-1`.
   */
  function strictIndexOf(array, value, fromIndex) {
    var index = fromIndex - 1,
        length = array.length;

    while (++index < length) {
      if (array[index] === value) {
        return index;
      }
    }
    return -1;
  }

  /**
   * A specialized version of `_.lastIndexOf` which performs strict equality
   * comparisons of values, i.e. `===`.
   *
   * @private
   * @param {Array} array The array to inspect.
   * @param {*} value The value to search for.
   * @param {number} fromIndex The index to search from.
   * @returns {number} Returns the index of the matched value, else `-1`.
   */
  function strictLastIndexOf(array, value, fromIndex) {
    var index = fromIndex + 1;
    while (index--) {
      if (array[index] === value) {
        return index;
      }
    }
    return index;
  }

  /**
   * Gets the number of symbols in `string`.
   *
   * @private
   * @param {string} string The string to inspect.
   * @returns {number} Returns the string size.
   */
  function stringSize(string) {
    return hasUnicode(string)
      ? unicodeSize(string)
      : asciiSize(string);
  }

  /**
   * Converts `string` to an array.
   *
   * @private
   * @param {string} string The string to convert.
   * @returns {Array} Returns the converted array.
   */
  function stringToArray(string) {
    return hasUnicode(string)
      ? unicodeToArray(string)
      : asciiToArray(string);
  }

  /**
   * Used by `_.unescape` to convert HTML entities to characters.
   *
   * @private
   * @param {string} chr The matched character to unescape.
   * @returns {string} Returns the unescaped character.
   */
  var unescapeHtmlChar = basePropertyOf(htmlUnescapes);

  /**
   * Gets the size of a Unicode `string`.
   *
   * @private
   * @param {string} string The string inspect.
   * @returns {number} Returns the string size.
   */
  function unicodeSize(string) {
    var result = reUnicode.lastIndex = 0;
    while (reUnicode.test(string)) {
      ++result;
    }
    return result;
  }

  /**
   * Converts a Unicode `string` to an array.
   *
   * @private
   * @param {string} string The string to convert.
   * @returns {Array} Returns the converted array.
   */
  function unicodeToArray(string) {
    return string.match(reUnicode) || [];
  }

  /**
   * Splits a Unicode `string` into an array of its words.
   *
   * @private
   * @param {string} The string to inspect.
   * @returns {Array} Returns the words of `string`.
   */
  function unicodeWords(string) {
    return string.match(reUnicodeWord) || [];
  }

  /*--------------------------------------------------------------------------*/

  /**
   * Create a new pristine `lodash` function using the `context` object.
   *
   * @static
   * @memberOf _
   * @since 1.1.0
   * @category Util
   * @param {Object} [context=root] The context object.
   * @returns {Function} Returns a new `lodash` function.
   * @example
   *
   * _.mixin({ 'foo': _.constant('foo') });
   *
   * var lodash = _.runInContext();
   * lodash.mixin({ 'bar': lodash.constant('bar') });
   *
   * _.isFunction(_.foo);
   * // => true
   * _.isFunction(_.bar);
   * // => false
   *
   * lodash.isFunction(lodash.foo);
   * // => false
   * lodash.isFunction(lodash.bar);
   * // => true
   *
   * // Create a suped-up `defer` in Node.js.
   * var defer = _.runInContext({ 'setTimeout': setImmediate }).defer;
   */
  var runInContext = (function runInContext(context) {
    context = context == null ? root : _.defaults(root.Object(), context, _.pick(root, contextProps));

    /** Built-in constructor references. */
    var Array = context.Array,
        Date = context.Date,
        Error = context.Error,
        Function = context.Function,
        Math = context.Math,
        Object = context.Object,
        RegExp = context.RegExp,
        String = context.String,
        TypeError = context.TypeError;

    /** Used for built-in method references. */
    var arrayProto = Array.prototype,
        funcProto = Function.prototype,
        objectProto = Object.prototype;

    /** Used to detect overreaching core-js shims. */
    var coreJsData = context['__core-js_shared__'];

    /** Used to resolve the decompiled source of functions. */
    var funcToString = funcProto.toString;

    /** Used to check objects for own properties. */
    var hasOwnProperty = objectProto.hasOwnProperty;

    /** Used to generate unique IDs. */
    var idCounter = 0;

    /** Used to detect methods masquerading as native. */
    var maskSrcKey = (function() {
      var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
      return uid ? ('Symbol(src)_1.' + uid) : '';
    }());

    /**
     * Used to resolve the
     * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
     * of values.
     */
    var nativeObjectToString = objectProto.toString;

    /** Used to infer the `Object` constructor. */
    var objectCtorString = funcToString.call(Object);

    /** Used to restore the original `_` reference in `_.noConflict`. */
    var oldDash = root._;

    /** Used to detect if a method is native. */
    var reIsNative = RegExp('^' +
      funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&')
      .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
    );

    /** Built-in value references. */
    var Buffer = moduleExports ? context.Buffer : undefined,
        Symbol = context.Symbol,
        Uint8Array = context.Uint8Array,
        allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined,
        getPrototype = overArg(Object.getPrototypeOf, Object),
        objectCreate = Object.create,
        propertyIsEnumerable = objectProto.propertyIsEnumerable,
        splice = arrayProto.splice,
        spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined,
        symIterator = Symbol ? Symbol.iterator : undefined,
        symToStringTag = Symbol ? Symbol.toStringTag : undefined;

    var defineProperty = (function() {
      try {
        var func = getNative(Object, 'defineProperty');
        func({}, '', {});
        return func;
      } catch (e) {}
    }());

    /** Mocked built-ins. */
    var ctxClearTimeout = context.clearTimeout !== root.clearTimeout && context.clearTimeout,
        ctxNow = Date && Date.now !== root.Date.now && Date.now,
        ctxSetTimeout = context.setTimeout !== root.setTimeout && context.setTimeout;

    /* Built-in method references for those with the same name as other `lodash` methods. */
    var nativeCeil = Math.ceil,
        nativeFloor = Math.floor,
        nativeGetSymbols = Object.getOwnPropertySymbols,
        nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined,
        nativeIsFinite = context.isFinite,
        nativeJoin = arrayProto.join,
        nativeKeys = overArg(Object.keys, Object),
        nativeMax = Math.max,
        nativeMin = Math.min,
        nativeNow = Date.now,
        nativeParseInt = context.parseInt,
        nativeRandom = Math.random,
        nativeReverse = arrayProto.reverse;

    /* Built-in method references that are verified to be native. */
    var DataView = getNative(context, 'DataView'),
        Map = getNative(context, 'Map'),
        Promise = getNative(context, 'Promise'),
        Set = getNative(context, 'Set'),
        WeakMap = getNative(context, 'WeakMap'),
        nativeCreate = getNative(Object, 'create');

    /** Used to store function metadata. */
    var metaMap = WeakMap && new WeakMap;

    /** Used to lookup unminified function names. */
    var realNames = {};

    /** Used to detect maps, sets, and weakmaps. */
    var dataViewCtorString = toSource(DataView),
        mapCtorString = toSource(Map),
        promiseCtorString = toSource(Promise),
        setCtorString = toSource(Set),
        weakMapCtorString = toSource(WeakMap);

    /** Used to convert symbols to primitives and strings. */
    var symbolProto = Symbol ? Symbol.prototype : undefined,
        symbolValueOf = symbolProto ? symbolProto.valueOf : undefined,
        symbolToString = symbolProto ? symbolProto.toString : undefined;

    /*------------------------------------------------------------------------*/

    /**
     * Creates a `lodash` object which wraps `value` to enable implicit method
     * chain sequences. Methods that operate on and return arrays, collections,
     * and functions can be chained together. Methods that retrieve a single value
     * or may return a primitive value will automatically end the chain sequence
     * and return the unwrapped value. Otherwise, the value must be unwrapped
     * with `_#value`.
     *
     * Explicit chain sequences, which must be unwrapped with `_#value`, may be
     * enabled using `_.chain`.
     *
     * The execution of chained methods is lazy, that is, it's deferred until
     * `_#value` is implicitly or explicitly called.
     *
     * Lazy evaluation allows several methods to support shortcut fusion.
     * Shortcut fusion is an optimization to merge iteratee calls; this avoids
     * the creation of intermediate arrays and can greatly reduce the number of
     * iteratee executions. Sections of a chain sequence qualify for shortcut
     * fusion if the section is applied to an array and iteratees accept only
     * one argument. The heuristic for whether a section qualifies for shortcut
     * fusion is subject to change.
     *
     * Chaining is supported in custom builds as long as the `_#value` method is
     * directly or indirectly included in the build.
     *
     * In addition to lodash methods, wrappers have `Array` and `String` methods.
     *
     * The wrapper `Array` methods are:
     * `concat`, `join`, `pop`, `push`, `shift`, `sort`, `splice`, and `unshift`
     *
     * The wrapper `String` methods are:
     * `replace` and `split`
     *
     * The wrapper methods that support shortcut fusion are:
     * `at`, `compact`, `drop`, `dropRight`, `dropWhile`, `filter`, `find`,
     * `findLast`, `head`, `initial`, `last`, `map`, `reject`, `reverse`, `slice`,
     * `tail`, `take`, `takeRight`, `takeRightWhile`, `takeWhile`, and `toArray`
     *
     * The chainable wrapper methods are:
     * `after`, `ary`, `assign`, `assignIn`, `assignInWith`, `assignWith`, `at`,
     * `before`, `bind`, `bindAll`, `bindKey`, `castArray`, `chain`, `chunk`,
     * `commit`, `compact`, `concat`, `conforms`, `constant`, `countBy`, `create`,
     * `curry`, `debounce`, `defaults`, `defaultsDeep`, `defer`, `delay`,
     * `difference`, `differenceBy`, `differenceWith`, `drop`, `dropRight`,
     * `dropRightWhile`, `dropWhile`, `extend`, `extendWith`, `fill`, `filter`,
     * `flatMap`, `flatMapDeep`, `flatMapDepth`, `flatten`, `flattenDeep`,
     * `flattenDepth`, `flip`, `flow`, `flowRight`, `fromPairs`, `functions`,
     * `functionsIn`, `groupBy`, `initial`, `intersection`, `intersectionBy`,
     * `intersectionWith`, `invert`, `invertBy`, `invokeMap`, `iteratee`, `keyBy`,
     * `keys`, `keysIn`, `map`, `mapKeys`, `mapValues`, `matches`, `matchesProperty`,
     * `memoize`, `merge`, `mergeWith`, `method`, `methodOf`, `mixin`, `negate`,
     * `nthArg`, `omit`, `omitBy`, `once`, `orderBy`, `over`, `overArgs`,
     * `overEvery`, `overSome`, `partial`, `partialRight`, `partition`, `pick`,
     * `pickBy`, `plant`, `property`, `propertyOf`, `pull`, `pullAll`, `pullAllBy`,
     * `pullAllWith`, `pullAt`, `push`, `range`, `rangeRight`, `rearg`, `reject`,
     * `remove`, `rest`, `reverse`, `sampleSize`, `set`, `setWith`, `shuffle`,
     * `slice`, `sort`, `sortBy`, `splice`, `spread`, `tail`, `take`, `takeRight`,
     * `takeRightWhile`, `takeWhile`, `tap`, `throttle`, `thru`, `toArray`,
     * `toPairs`, `toPairsIn`, `toPath`, `toPlainObject`, `transform`, `unary`,
     * `union`, `unionBy`, `unionWith`, `uniq`, `uniqBy`, `uniqWith`, `unset`,
     * `unshift`, `unzip`, `unzipWith`, `update`, `updateWith`, `values`,
     * `valuesIn`, `without`, `wrap`, `xor`, `xorBy`, `xorWith`, `zip`,
     * `zipObject`, `zipObjectDeep`, and `zipWith`
     *
     * The wrapper methods that are **not** chainable by default are:
     * `add`, `attempt`, `camelCase`, `capitalize`, `ceil`, `clamp`, `clone`,
     * `cloneDeep`, `cloneDeepWith`, `cloneWith`, `conformsTo`, `deburr`,
     * `defaultTo`, `divide`, `each`, `eachRight`, `endsWith`, `eq`, `escape`,
     * `escapeRegExp`, `every`, `find`, `findIndex`, `findKey`, `findLast`,
     * `findLastIndex`, `findLastKey`, `first`, `floor`, `forEach`, `forEachRight`,
     * `forIn`, `forInRight`, `forOwn`, `forOwnRight`, `get`, `gt`, `gte`, `has`,
     * `hasIn`, `head`, `identity`, `includes`, `indexOf`, `inRange`, `invoke`,
     * `isArguments`, `isArray`, `isArrayBuffer`, `isArrayLike`, `isArrayLikeObject`,
     * `isBoolean`, `isBuffer`, `isDate`, `isElement`, `isEmpty`, `isEqual`,
     * `isEqualWith`, `isError`, `isFinite`, `isFunction`, `isInteger`, `isLength`,
     * `isMap`, `isMatch`, `isMatchWith`, `isNaN`, `isNative`, `isNil`, `isNull`,
     * `isNumber`, `isObject`, `isObjectLike`, `isPlainObject`, `isRegExp`,
     * `isSafeInteger`, `isSet`, `isString`, `isUndefined`, `isTypedArray`,
     * `isWeakMap`, `isWeakSet`, `join`, `kebabCase`, `last`, `lastIndexOf`,
     * `lowerCase`, `lowerFirst`, `lt`, `lte`, `max`, `maxBy`, `mean`, `meanBy`,
     * `min`, `minBy`, `multiply`, `noConflict`, `noop`, `now`, `nth`, `pad`,
     * `padEnd`, `padStart`, `parseInt`, `pop`, `random`, `reduce`, `reduceRight`,
     * `repeat`, `result`, `round`, `runInContext`, `sample`, `shift`, `size`,
     * `snakeCase`, `some`, `sortedIndex`, `sortedIndexBy`, `sortedLastIndex`,
     * `sortedLastIndexBy`, `startCase`, `startsWith`, `stubArray`, `stubFalse`,
     * `stubObject`, `stubString`, `stubTrue`, `subtract`, `sum`, `sumBy`,
     * `template`, `times`, `toFinite`, `toInteger`, `toJSON`, `toLength`,
     * `toLower`, `toNumber`, `toSafeInteger`, `toString`, `toUpper`, `trim`,
     * `trimEnd`, `trimStart`, `truncate`, `unescape`, `uniqueId`, `upperCase`,
     * `upperFirst`, `value`, and `words`
     *
     * @name _
     * @constructor
     * @category Seq
     * @param {*} value The value to wrap in a `lodash` instance.
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * function square(n) {
     *   return n * n;
     * }
     *
     * var wrapped = _([1, 2, 3]);
     *
     * // Returns an unwrapped value.
     * wrapped.reduce(_.add);
     * // => 6
     *
     * // Returns a wrapped value.
     * var squares = wrapped.map(square);
     *
     * _.isArray(squares);
     * // => false
     *
     * _.isArray(squares.value());
     * // => true
     */
    function lodash(value) {
      if (isObjectLike(value) && !isArray(value) && !(value instanceof LazyWrapper)) {
        if (value instanceof LodashWrapper) {
          return value;
        }
        if (hasOwnProperty.call(value, '__wrapped__')) {
          return wrapperClone(value);
        }
      }
      return new LodashWrapper(value);
    }

    /**
     * The base implementation of `_.create` without support for assigning
     * properties to the created object.
     *
     * @private
     * @param {Object} proto The object to inherit from.
     * @returns {Object} Returns the new object.
     */
    var baseCreate = (function() {
      function object() {}
      return function(proto) {
        if (!isObject(proto)) {
          return {};
        }
        if (objectCreate) {
          return objectCreate(proto);
        }
        object.prototype = proto;
        var result = new object;
        object.prototype = undefined;
        return result;
      };
    }());

    /**
     * The function whose prototype chain sequence wrappers inherit from.
     *
     * @private
     */
    function baseLodash() {
      // No operation performed.
    }

    /**
     * The base constructor for creating `lodash` wrapper objects.
     *
     * @private
     * @param {*} value The value to wrap.
     * @param {boolean} [chainAll] Enable explicit method chain sequences.
     */
    function LodashWrapper(value, chainAll) {
      this.__wrapped__ = value;
      this.__actions__ = [];
      this.__chain__ = !!chainAll;
      this.__index__ = 0;
      this.__values__ = undefined;
    }

    /**
     * By default, the template delimiters used by lodash are like those in
     * embedded Ruby (ERB) as well as ES2015 template strings. Change the
     * following template settings to use alternative delimiters.
     *
     * @static
     * @memberOf _
     * @type {Object}
     */
    lodash.templateSettings = {

      /**
       * Used to detect `data` property values to be HTML-escaped.
       *
       * @memberOf _.templateSettings
       * @type {RegExp}
       */
      'escape': reEscape,

      /**
       * Used to detect code to be evaluated.
       *
       * @memberOf _.templateSettings
       * @type {RegExp}
       */
      'evaluate': reEvaluate,

      /**
       * Used to detect `data` property values to inject.
       *
       * @memberOf _.templateSettings
       * @type {RegExp}
       */
      'interpolate': reInterpolate,

      /**
       * Used to reference the data object in the template text.
       *
       * @memberOf _.templateSettings
       * @type {string}
       */
      'variable': '',

      /**
       * Used to import variables into the compiled template.
       *
       * @memberOf _.templateSettings
       * @type {Object}
       */
      'imports': {

        /**
         * A reference to the `lodash` function.
         *
         * @memberOf _.templateSettings.imports
         * @type {Function}
         */
        '_': lodash
      }
    };

    // Ensure wrappers are instances of `baseLodash`.
    lodash.prototype = baseLodash.prototype;
    lodash.prototype.constructor = lodash;

    LodashWrapper.prototype = baseCreate(baseLodash.prototype);
    LodashWrapper.prototype.constructor = LodashWrapper;

    /*------------------------------------------------------------------------*/

    /**
     * Creates a lazy wrapper object which wraps `value` to enable lazy evaluation.
     *
     * @private
     * @constructor
     * @param {*} value The value to wrap.
     */
    function LazyWrapper(value) {
      this.__wrapped__ = value;
      this.__actions__ = [];
      this.__dir__ = 1;
      this.__filtered__ = false;
      this.__iteratees__ = [];
      this.__takeCount__ = MAX_ARRAY_LENGTH;
      this.__views__ = [];
    }

    /**
     * Creates a clone of the lazy wrapper object.
     *
     * @private
     * @name clone
     * @memberOf LazyWrapper
     * @returns {Object} Returns the cloned `LazyWrapper` object.
     */
    function lazyClone() {
      var result = new LazyWrapper(this.__wrapped__);
      result.__actions__ = copyArray(this.__actions__);
      result.__dir__ = this.__dir__;
      result.__filtered__ = this.__filtered__;
      result.__iteratees__ = copyArray(this.__iteratees__);
      result.__takeCount__ = this.__takeCount__;
      result.__views__ = copyArray(this.__views__);
      return result;
    }

    /**
     * Reverses the direction of lazy iteration.
     *
     * @private
     * @name reverse
     * @memberOf LazyWrapper
     * @returns {Object} Returns the new reversed `LazyWrapper` object.
     */
    function lazyReverse() {
      if (this.__filtered__) {
        var result = new LazyWrapper(this);
        result.__dir__ = -1;
        result.__filtered__ = true;
      } else {
        result = this.clone();
        result.__dir__ *= -1;
      }
      return result;
    }

    /**
     * Extracts the unwrapped value from its lazy wrapper.
     *
     * @private
     * @name value
     * @memberOf LazyWrapper
     * @returns {*} Returns the unwrapped value.
     */
    function lazyValue() {
      var array = this.__wrapped__.value(),
          dir = this.__dir__,
          isArr = isArray(array),
          isRight = dir < 0,
          arrLength = isArr ? array.length : 0,
          view = getView(0, arrLength, this.__views__),
          start = view.start,
          end = view.end,
          length = end - start,
          index = isRight ? end : (start - 1),
          iteratees = this.__iteratees__,
          iterLength = iteratees.length,
          resIndex = 0,
          takeCount = nativeMin(length, this.__takeCount__);

      if (!isArr || (!isRight && arrLength == length && takeCount == length)) {
        return baseWrapperValue(array, this.__actions__);
      }
      var result = [];

      outer:
      while (length-- && resIndex < takeCount) {
        index += dir;

        var iterIndex = -1,
            value = array[index];

        while (++iterIndex < iterLength) {
          var data = iteratees[iterIndex],
              iteratee = data.iteratee,
              type = data.type,
              computed = iteratee(value);

          if (type == LAZY_MAP_FLAG) {
            value = computed;
          } else if (!computed) {
            if (type == LAZY_FILTER_FLAG) {
              continue outer;
            } else {
              break outer;
            }
          }
        }
        result[resIndex++] = value;
      }
      return result;
    }

    // Ensure `LazyWrapper` is an instance of `baseLodash`.
    LazyWrapper.prototype = baseCreate(baseLodash.prototype);
    LazyWrapper.prototype.constructor = LazyWrapper;

    /*------------------------------------------------------------------------*/

    /**
     * Creates a hash object.
     *
     * @private
     * @constructor
     * @param {Array} [entries] The key-value pairs to cache.
     */
    function Hash(entries) {
      var index = -1,
          length = entries == null ? 0 : entries.length;

      this.clear();
      while (++index < length) {
        var entry = entries[index];
        this.set(entry[0], entry[1]);
      }
    }

    /**
     * Removes all key-value entries from the hash.
     *
     * @private
     * @name clear
     * @memberOf Hash
     */
    function hashClear() {
      this.__data__ = nativeCreate ? nativeCreate(null) : {};
      this.size = 0;
    }

    /**
     * Removes `key` and its value from the hash.
     *
     * @private
     * @name delete
     * @memberOf Hash
     * @param {Object} hash The hash to modify.
     * @param {string} key The key of the value to remove.
     * @returns {boolean} Returns `true` if the entry was removed, else `false`.
     */
    function hashDelete(key) {
      var result = this.has(key) && delete this.__data__[key];
      this.size -= result ? 1 : 0;
      return result;
    }

    /**
     * Gets the hash value for `key`.
     *
     * @private
     * @name get
     * @memberOf Hash
     * @param {string} key The key of the value to get.
     * @returns {*} Returns the entry value.
     */
    function hashGet(key) {
      var data = this.__data__;
      if (nativeCreate) {
        var result = data[key];
        return result === HASH_UNDEFINED ? undefined : result;
      }
      return hasOwnProperty.call(data, key) ? data[key] : undefined;
    }

    /**
     * Checks if a hash value for `key` exists.
     *
     * @private
     * @name has
     * @memberOf Hash
     * @param {string} key The key of the entry to check.
     * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
     */
    function hashHas(key) {
      var data = this.__data__;
      return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);
    }

    /**
     * Sets the hash `key` to `value`.
     *
     * @private
     * @name set
     * @memberOf Hash
     * @param {string} key The key of the value to set.
     * @param {*} value The value to set.
     * @returns {Object} Returns the hash instance.
     */
    function hashSet(key, value) {
      var data = this.__data__;
      this.size += this.has(key) ? 0 : 1;
      data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;
      return this;
    }

    // Add methods to `Hash`.
    Hash.prototype.clear = hashClear;
    Hash.prototype['delete'] = hashDelete;
    Hash.prototype.get = hashGet;
    Hash.prototype.has = hashHas;
    Hash.prototype.set = hashSet;

    /*------------------------------------------------------------------------*/

    /**
     * Creates an list cache object.
     *
     * @private
     * @constructor
     * @param {Array} [entries] The key-value pairs to cache.
     */
    function ListCache(entries) {
      var index = -1,
          length = entries == null ? 0 : entries.length;

      this.clear();
      while (++index < length) {
        var entry = entries[index];
        this.set(entry[0], entry[1]);
      }
    }

    /**
     * Removes all key-value entries from the list cache.
     *
     * @private
     * @name clear
     * @memberOf ListCache
     */
    function listCacheClear() {
      this.__data__ = [];
      this.size = 0;
    }

    /**
     * Removes `key` and its value from the list cache.
     *
     * @private
     * @name delete
     * @memberOf ListCache
     * @param {string} key The key of the value to remove.
     * @returns {boolean} Returns `true` if the entry was removed, else `false`.
     */
    function listCacheDelete(key) {
      var data = this.__data__,
          index = assocIndexOf(data, key);

      if (index < 0) {
        return false;
      }
      var lastIndex = data.length - 1;
      if (index == lastIndex) {
        data.pop();
      } else {
        splice.call(data, index, 1);
      }
      --this.size;
      return true;
    }

    /**
     * Gets the list cache value for `key`.
     *
     * @private
     * @name get
     * @memberOf ListCache
     * @param {string} key The key of the value to get.
     * @returns {*} Returns the entry value.
     */
    function listCacheGet(key) {
      var data = this.__data__,
          index = assocIndexOf(data, key);

      return index < 0 ? undefined : data[index][1];
    }

    /**
     * Checks if a list cache value for `key` exists.
     *
     * @private
     * @name has
     * @memberOf ListCache
     * @param {string} key The key of the entry to check.
     * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
     */
    function listCacheHas(key) {
      return assocIndexOf(this.__data__, key) > -1;
    }

    /**
     * Sets the list cache `key` to `value`.
     *
     * @private
     * @name set
     * @memberOf ListCache
     * @param {string} key The key of the value to set.
     * @param {*} value The value to set.
     * @returns {Object} Returns the list cache instance.
     */
    function listCacheSet(key, value) {
      var data = this.__data__,
          index = assocIndexOf(data, key);

      if (index < 0) {
        ++this.size;
        data.push([key, value]);
      } else {
        data[index][1] = value;
      }
      return this;
    }

    // Add methods to `ListCache`.
    ListCache.prototype.clear = listCacheClear;
    ListCache.prototype['delete'] = listCacheDelete;
    ListCache.prototype.get = listCacheGet;
    ListCache.prototype.has = listCacheHas;
    ListCache.prototype.set = listCacheSet;

    /*------------------------------------------------------------------------*/

    /**
     * Creates a map cache object to store key-value pairs.
     *
     * @private
     * @constructor
     * @param {Array} [entries] The key-value pairs to cache.
     */
    function MapCache(entries) {
      var index = -1,
          length = entries == null ? 0 : entries.length;

      this.clear();
      while (++index < length) {
        var entry = entries[index];
        this.set(entry[0], entry[1]);
      }
    }

    /**
     * Removes all key-value entries from the map.
     *
     * @private
     * @name clear
     * @memberOf MapCache
     */
    function mapCacheClear() {
      this.size = 0;
      this.__data__ = {
        'hash': new Hash,
        'map': new (Map || ListCache),
        'string': new Hash
      };
    }

    /**
     * Removes `key` and its value from the map.
     *
     * @private
     * @name delete
     * @memberOf MapCache
     * @param {string} key The key of the value to remove.
     * @returns {boolean} Returns `true` if the entry was removed, else `false`.
     */
    function mapCacheDelete(key) {
      var result = getMapData(this, key)['delete'](key);
      this.size -= result ? 1 : 0;
      return result;
    }

    /**
     * Gets the map value for `key`.
     *
     * @private
     * @name get
     * @memberOf MapCache
     * @param {string} key The key of the value to get.
     * @returns {*} Returns the entry value.
     */
    function mapCacheGet(key) {
      return getMapData(this, key).get(key);
    }

    /**
     * Checks if a map value for `key` exists.
     *
     * @private
     * @name has
     * @memberOf MapCache
     * @param {string} key The key of the entry to check.
     * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
     */
    function mapCacheHas(key) {
      return getMapData(this, key).has(key);
    }

    /**
     * Sets the map `key` to `value`.
     *
     * @private
     * @name set
     * @memberOf MapCache
     * @param {string} key The key of the value to set.
     * @param {*} value The value to set.
     * @returns {Object} Returns the map cache instance.
     */
    function mapCacheSet(key, value) {
      var data = getMapData(this, key),
          size = data.size;

      data.set(key, value);
      this.size += data.size == size ? 0 : 1;
      return this;
    }

    // Add methods to `MapCache`.
    MapCache.prototype.clear = mapCacheClear;
    MapCache.prototype['delete'] = mapCacheDelete;
    MapCache.prototype.get = mapCacheGet;
    MapCache.prototype.has = mapCacheHas;
    MapCache.prototype.set = mapCacheSet;

    /*------------------------------------------------------------------------*/

    /**
     *
     * Creates an array cache object to store unique values.
     *
     * @private
     * @constructor
     * @param {Array} [values] The values to cache.
     */
    function SetCache(values) {
      var index = -1,
          length = values == null ? 0 : values.length;

      this.__data__ = new MapCache;
      while (++index < length) {
        this.add(values[index]);
      }
    }

    /**
     * Adds `value` to the array cache.
     *
     * @private
     * @name add
     * @memberOf SetCache
     * @alias push
     * @param {*} value The value to cache.
     * @returns {Object} Returns the cache instance.
     */
    function setCacheAdd(value) {
      this.__data__.set(value, HASH_UNDEFINED);
      return this;
    }

    /**
     * Checks if `value` is in the array cache.
     *
     * @private
     * @name has
     * @memberOf SetCache
     * @param {*} value The value to search for.
     * @returns {number} Returns `true` if `value` is found, else `false`.
     */
    function setCacheHas(value) {
      return this.__data__.has(value);
    }

    // Add methods to `SetCache`.
    SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
    SetCache.prototype.has = setCacheHas;

    /*------------------------------------------------------------------------*/

    /**
     * Creates a stack cache object to store key-value pairs.
     *
     * @private
     * @constructor
     * @param {Array} [entries] The key-value pairs to cache.
     */
    function Stack(entries) {
      var data = this.__data__ = new ListCache(entries);
      this.size = data.size;
    }

    /**
     * Removes all key-value entries from the stack.
     *
     * @private
     * @name clear
     * @memberOf Stack
     */
    function stackClear() {
      this.__data__ = new ListCache;
      this.size = 0;
    }

    /**
     * Removes `key` and its value from the stack.
     *
     * @private
     * @name delete
     * @memberOf Stack
     * @param {string} key The key of the value to remove.
     * @returns {boolean} Returns `true` if the entry was removed, else `false`.
     */
    function stackDelete(key) {
      var data = this.__data__,
          result = data['delete'](key);

      this.size = data.size;
      return result;
    }

    /**
     * Gets the stack value for `key`.
     *
     * @private
     * @name get
     * @memberOf Stack
     * @param {string} key The key of the value to get.
     * @returns {*} Returns the entry value.
     */
    function stackGet(key) {
      return this.__data__.get(key);
    }

    /**
     * Checks if a stack value for `key` exists.
     *
     * @private
     * @name has
     * @memberOf Stack
     * @param {string} key The key of the entry to check.
     * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.
     */
    function stackHas(key) {
      return this.__data__.has(key);
    }

    /**
     * Sets the stack `key` to `value`.
     *
     * @private
     * @name set
     * @memberOf Stack
     * @param {string} key The key of the value to set.
     * @param {*} value The value to set.
     * @returns {Object} Returns the stack cache instance.
     */
    function stackSet(key, value) {
      var data = this.__data__;
      if (data instanceof ListCache) {
        var pairs = data.__data__;
        if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {
          pairs.push([key, value]);
          this.size = ++data.size;
          return this;
        }
        data = this.__data__ = new MapCache(pairs);
      }
      data.set(key, value);
      this.size = data.size;
      return this;
    }

    // Add methods to `Stack`.
    Stack.prototype.clear = stackClear;
    Stack.prototype['delete'] = stackDelete;
    Stack.prototype.get = stackGet;
    Stack.prototype.has = stackHas;
    Stack.prototype.set = stackSet;

    /*------------------------------------------------------------------------*/

    /**
     * Creates an array of the enumerable property names of the array-like `value`.
     *
     * @private
     * @param {*} value The value to query.
     * @param {boolean} inherited Specify returning inherited property names.
     * @returns {Array} Returns the array of property names.
     */
    function arrayLikeKeys(value, inherited) {
      var isArr = isArray(value),
          isArg = !isArr && isArguments(value),
          isBuff = !isArr && !isArg && isBuffer(value),
          isType = !isArr && !isArg && !isBuff && isTypedArray(value),
          skipIndexes = isArr || isArg || isBuff || isType,
          result = skipIndexes ? baseTimes(value.length, String) : [],
          length = result.length;

      for (var key in value) {
        if ((inherited || hasOwnProperty.call(value, key)) &&
            !(skipIndexes && (
               // Safari 9 has enumerable `arguments.length` in strict mode.
               key == 'length' ||
               // Node.js 0.10 has enumerable non-index properties on buffers.
               (isBuff && (key == 'offset' || key == 'parent')) ||
               // PhantomJS 2 has enumerable non-index properties on typed arrays.
               (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||
               // Skip index properties.
               isIndex(key, length)
            ))) {
          result.push(key);
        }
      }
      return result;
    }

    /**
     * A specialized version of `_.sample` for arrays.
     *
     * @private
     * @param {Array} array The array to sample.
     * @returns {*} Returns the random element.
     */
    function arraySample(array) {
      var length = array.length;
      return length ? array[baseRandom(0, length - 1)] : undefined;
    }

    /**
     * A specialized version of `_.sampleSize` for arrays.
     *
     * @private
     * @param {Array} array The array to sample.
     * @param {number} n The number of elements to sample.
     * @returns {Array} Returns the random elements.
     */
    function arraySampleSize(array, n) {
      return shuffleSelf(copyArray(array), baseClamp(n, 0, array.length));
    }

    /**
     * A specialized version of `_.shuffle` for arrays.
     *
     * @private
     * @param {Array} array The array to shuffle.
     * @returns {Array} Returns the new shuffled array.
     */
    function arrayShuffle(array) {
      return shuffleSelf(copyArray(array));
    }

    /**
     * This function is like `assignValue` except that it doesn't assign
     * `undefined` values.
     *
     * @private
     * @param {Object} object The object to modify.
     * @param {string} key The key of the property to assign.
     * @param {*} value The value to assign.
     */
    function assignMergeValue(object, key, value) {
      if ((value !== undefined && !eq(object[key], value)) ||
          (value === undefined && !(key in object))) {
        baseAssignValue(object, key, value);
      }
    }

    /**
     * Assigns `value` to `key` of `object` if the existing value is not equivalent
     * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons.
     *
     * @private
     * @param {Object} object The object to modify.
     * @param {string} key The key of the property to assign.
     * @param {*} value The value to assign.
     */
    function assignValue(object, key, value) {
      var objValue = object[key];
      if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||
          (value === undefined && !(key in object))) {
        baseAssignValue(object, key, value);
      }
    }

    /**
     * Gets the index at which the `key` is found in `array` of key-value pairs.
     *
     * @private
     * @param {Array} array The array to inspect.
     * @param {*} key The key to search for.
     * @returns {number} Returns the index of the matched value, else `-1`.
     */
    function assocIndexOf(array, key) {
      var length = array.length;
      while (length--) {
        if (eq(array[length][0], key)) {
          return length;
        }
      }
      return -1;
    }

    /**
     * Aggregates elements of `collection` on `accumulator` with keys transformed
     * by `iteratee` and values set by `setter`.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} setter The function to set `accumulator` values.
     * @param {Function} iteratee The iteratee to transform keys.
     * @param {Object} accumulator The initial aggregated object.
     * @returns {Function} Returns `accumulator`.
     */
    function baseAggregator(collection, setter, iteratee, accumulator) {
      baseEach(collection, function(value, key, collection) {
        setter(accumulator, value, iteratee(value), collection);
      });
      return accumulator;
    }

    /**
     * The base implementation of `_.assign` without support for multiple sources
     * or `customizer` functions.
     *
     * @private
     * @param {Object} object The destination object.
     * @param {Object} source The source object.
     * @returns {Object} Returns `object`.
     */
    function baseAssign(object, source) {
      return object && copyObject(source, keys(source), object);
    }

    /**
     * The base implementation of `_.assignIn` without support for multiple sources
     * or `customizer` functions.
     *
     * @private
     * @param {Object} object The destination object.
     * @param {Object} source The source object.
     * @returns {Object} Returns `object`.
     */
    function baseAssignIn(object, source) {
      return object && copyObject(source, keysIn(source), object);
    }

    /**
     * The base implementation of `assignValue` and `assignMergeValue` without
     * value checks.
     *
     * @private
     * @param {Object} object The object to modify.
     * @param {string} key The key of the property to assign.
     * @param {*} value The value to assign.
     */
    function baseAssignValue(object, key, value) {
      if (key == '__proto__' && defineProperty) {
        defineProperty(object, key, {
          'configurable': true,
          'enumerable': true,
          'value': value,
          'writable': true
        });
      } else {
        object[key] = value;
      }
    }

    /**
     * The base implementation of `_.at` without support for individual paths.
     *
     * @private
     * @param {Object} object The object to iterate over.
     * @param {string[]} paths The property paths to pick.
     * @returns {Array} Returns the picked elements.
     */
    function baseAt(object, paths) {
      var index = -1,
          length = paths.length,
          result = Array(length),
          skip = object == null;

      while (++index < length) {
        result[index] = skip ? undefined : get(object, paths[index]);
      }
      return result;
    }

    /**
     * The base implementation of `_.clamp` which doesn't coerce arguments.
     *
     * @private
     * @param {number} number The number to clamp.
     * @param {number} [lower] The lower bound.
     * @param {number} upper The upper bound.
     * @returns {number} Returns the clamped number.
     */
    function baseClamp(number, lower, upper) {
      if (number === number) {
        if (upper !== undefined) {
          number = number <= upper ? number : upper;
        }
        if (lower !== undefined) {
          number = number >= lower ? number : lower;
        }
      }
      return number;
    }

    /**
     * The base implementation of `_.clone` and `_.cloneDeep` which tracks
     * traversed objects.
     *
     * @private
     * @param {*} value The value to clone.
     * @param {boolean} bitmask The bitmask flags.
     *  1 - Deep clone
     *  2 - Flatten inherited properties
     *  4 - Clone symbols
     * @param {Function} [customizer] The function to customize cloning.
     * @param {string} [key] The key of `value`.
     * @param {Object} [object] The parent object of `value`.
     * @param {Object} [stack] Tracks traversed objects and their clone counterparts.
     * @returns {*} Returns the cloned value.
     */
    function baseClone(value, bitmask, customizer, key, object, stack) {
      var result,
          isDeep = bitmask & CLONE_DEEP_FLAG,
          isFlat = bitmask & CLONE_FLAT_FLAG,
          isFull = bitmask & CLONE_SYMBOLS_FLAG;

      if (customizer) {
        result = object ? customizer(value, key, object, stack) : customizer(value);
      }
      if (result !== undefined) {
        return result;
      }
      if (!isObject(value)) {
        return value;
      }
      var isArr = isArray(value);
      if (isArr) {
        result = initCloneArray(value);
        if (!isDeep) {
          return copyArray(value, result);
        }
      } else {
        var tag = getTag(value),
            isFunc = tag == funcTag || tag == genTag;

        if (isBuffer(value)) {
          return cloneBuffer(value, isDeep);
        }
        if (tag == objectTag || tag == argsTag || (isFunc && !object)) {
          result = (isFlat || isFunc) ? {} : initCloneObject(value);
          if (!isDeep) {
            return isFlat
              ? copySymbolsIn(value, baseAssignIn(result, value))
              : copySymbols(value, baseAssign(result, value));
          }
        } else {
          if (!cloneableTags[tag]) {
            return object ? value : {};
          }
          result = initCloneByTag(value, tag, isDeep);
        }
      }
      // Check for circular references and return its corresponding clone.
      stack || (stack = new Stack);
      var stacked = stack.get(value);
      if (stacked) {
        return stacked;
      }
      stack.set(value, result);

      if (isSet(value)) {
        value.forEach(function(subValue) {
          result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));
        });
      } else if (isMap(value)) {
        value.forEach(function(subValue, key) {
          result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack));
        });
      }

      var keysFunc = isFull
        ? (isFlat ? getAllKeysIn : getAllKeys)
        : (isFlat ? keysIn : keys);

      var props = isArr ? undefined : keysFunc(value);
      arrayEach(props || value, function(subValue, key) {
        if (props) {
          key = subValue;
          subValue = value[key];
        }
        // Recursively populate clone (susceptible to call stack limits).
        assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack));
      });
      return result;
    }

    /**
     * The base implementation of `_.conforms` which doesn't clone `source`.
     *
     * @private
     * @param {Object} source The object of property predicates to conform to.
     * @returns {Function} Returns the new spec function.
     */
    function baseConforms(source) {
      var props = keys(source);
      return function(object) {
        return baseConformsTo(object, source, props);
      };
    }

    /**
     * The base implementation of `_.conformsTo` which accepts `props` to check.
     *
     * @private
     * @param {Object} object The object to inspect.
     * @param {Object} source The object of property predicates to conform to.
     * @returns {boolean} Returns `true` if `object` conforms, else `false`.
     */
    function baseConformsTo(object, source, props) {
      var length = props.length;
      if (object == null) {
        return !length;
      }
      object = Object(object);
      while (length--) {
        var key = props[length],
            predicate = source[key],
            value = object[key];

        if ((value === undefined && !(key in object)) || !predicate(value)) {
          return false;
        }
      }
      return true;
    }

    /**
     * The base implementation of `_.delay` and `_.defer` which accepts `args`
     * to provide to `func`.
     *
     * @private
     * @param {Function} func The function to delay.
     * @param {number} wait The number of milliseconds to delay invocation.
     * @param {Array} args The arguments to provide to `func`.
     * @returns {number|Object} Returns the timer id or timeout object.
     */
    function baseDelay(func, wait, args) {
      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      return setTimeout(function() { func.apply(undefined, args); }, wait);
    }

    /**
     * The base implementation of methods like `_.difference` without support
     * for excluding multiple arrays or iteratee shorthands.
     *
     * @private
     * @param {Array} array The array to inspect.
     * @param {Array} values The values to exclude.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of filtered values.
     */
    function baseDifference(array, values, iteratee, comparator) {
      var index = -1,
          includes = arrayIncludes,
          isCommon = true,
          length = array.length,
          result = [],
          valuesLength = values.length;

      if (!length) {
        return result;
      }
      if (iteratee) {
        values = arrayMap(values, baseUnary(iteratee));
      }
      if (comparator) {
        includes = arrayIncludesWith;
        isCommon = false;
      }
      else if (values.length >= LARGE_ARRAY_SIZE) {
        includes = cacheHas;
        isCommon = false;
        values = new SetCache(values);
      }
      outer:
      while (++index < length) {
        var value = array[index],
            computed = iteratee == null ? value : iteratee(value);

        value = (comparator || value !== 0) ? value : 0;
        if (isCommon && computed === computed) {
          var valuesIndex = valuesLength;
          while (valuesIndex--) {
            if (values[valuesIndex] === computed) {
              continue outer;
            }
          }
          result.push(value);
        }
        else if (!includes(values, computed, comparator)) {
          result.push(value);
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.forEach` without support for iteratee shorthands.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @returns {Array|Object} Returns `collection`.
     */
    var baseEach = createBaseEach(baseForOwn);

    /**
     * The base implementation of `_.forEachRight` without support for iteratee shorthands.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @returns {Array|Object} Returns `collection`.
     */
    var baseEachRight = createBaseEach(baseForOwnRight, true);

    /**
     * The base implementation of `_.every` without support for iteratee shorthands.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} predicate The function invoked per iteration.
     * @returns {boolean} Returns `true` if all elements pass the predicate check,
     *  else `false`
     */
    function baseEvery(collection, predicate) {
      var result = true;
      baseEach(collection, function(value, index, collection) {
        result = !!predicate(value, index, collection);
        return result;
      });
      return result;
    }

    /**
     * The base implementation of methods like `_.max` and `_.min` which accepts a
     * `comparator` to determine the extremum value.
     *
     * @private
     * @param {Array} array The array to iterate over.
     * @param {Function} iteratee The iteratee invoked per iteration.
     * @param {Function} comparator The comparator used to compare values.
     * @returns {*} Returns the extremum value.
     */
    function baseExtremum(array, iteratee, comparator) {
      var index = -1,
          length = array.length;

      while (++index < length) {
        var value = array[index],
            current = iteratee(value);

        if (current != null && (computed === undefined
              ? (current === current && !isSymbol(current))
              : comparator(current, computed)
            )) {
          var computed = current,
              result = value;
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.fill` without an iteratee call guard.
     *
     * @private
     * @param {Array} array The array to fill.
     * @param {*} value The value to fill `array` with.
     * @param {number} [start=0] The start position.
     * @param {number} [end=array.length] The end position.
     * @returns {Array} Returns `array`.
     */
    function baseFill(array, value, start, end) {
      var length = array.length;

      start = toInteger(start);
      if (start < 0) {
        start = -start > length ? 0 : (length + start);
      }
      end = (end === undefined || end > length) ? length : toInteger(end);
      if (end < 0) {
        end += length;
      }
      end = start > end ? 0 : toLength(end);
      while (start < end) {
        array[start++] = value;
      }
      return array;
    }

    /**
     * The base implementation of `_.filter` without support for iteratee shorthands.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} predicate The function invoked per iteration.
     * @returns {Array} Returns the new filtered array.
     */
    function baseFilter(collection, predicate) {
      var result = [];
      baseEach(collection, function(value, index, collection) {
        if (predicate(value, index, collection)) {
          result.push(value);
        }
      });
      return result;
    }

    /**
     * The base implementation of `_.flatten` with support for restricting flattening.
     *
     * @private
     * @param {Array} array The array to flatten.
     * @param {number} depth The maximum recursion depth.
     * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.
     * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.
     * @param {Array} [result=[]] The initial result value.
     * @returns {Array} Returns the new flattened array.
     */
    function baseFlatten(array, depth, predicate, isStrict, result) {
      var index = -1,
          length = array.length;

      predicate || (predicate = isFlattenable);
      result || (result = []);

      while (++index < length) {
        var value = array[index];
        if (depth > 0 && predicate(value)) {
          if (depth > 1) {
            // Recursively flatten arrays (susceptible to call stack limits).
            baseFlatten(value, depth - 1, predicate, isStrict, result);
          } else {
            arrayPush(result, value);
          }
        } else if (!isStrict) {
          result[result.length] = value;
        }
      }
      return result;
    }

    /**
     * The base implementation of `baseForOwn` which iterates over `object`
     * properties returned by `keysFunc` and invokes `iteratee` for each property.
     * Iteratee functions may exit iteration early by explicitly returning `false`.
     *
     * @private
     * @param {Object} object The object to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @param {Function} keysFunc The function to get the keys of `object`.
     * @returns {Object} Returns `object`.
     */
    var baseFor = createBaseFor();

    /**
     * This function is like `baseFor` except that it iterates over properties
     * in the opposite order.
     *
     * @private
     * @param {Object} object The object to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @param {Function} keysFunc The function to get the keys of `object`.
     * @returns {Object} Returns `object`.
     */
    var baseForRight = createBaseFor(true);

    /**
     * The base implementation of `_.forOwn` without support for iteratee shorthands.
     *
     * @private
     * @param {Object} object The object to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @returns {Object} Returns `object`.
     */
    function baseForOwn(object, iteratee) {
      return object && baseFor(object, iteratee, keys);
    }

    /**
     * The base implementation of `_.forOwnRight` without support for iteratee shorthands.
     *
     * @private
     * @param {Object} object The object to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @returns {Object} Returns `object`.
     */
    function baseForOwnRight(object, iteratee) {
      return object && baseForRight(object, iteratee, keys);
    }

    /**
     * The base implementation of `_.functions` which creates an array of
     * `object` function property names filtered from `props`.
     *
     * @private
     * @param {Object} object The object to inspect.
     * @param {Array} props The property names to filter.
     * @returns {Array} Returns the function names.
     */
    function baseFunctions(object, props) {
      return arrayFilter(props, function(key) {
        return isFunction(object[key]);
      });
    }

    /**
     * The base implementation of `_.get` without support for default values.
     *
     * @private
     * @param {Object} object The object to query.
     * @param {Array|string} path The path of the property to get.
     * @returns {*} Returns the resolved value.
     */
    function baseGet(object, path) {
      path = castPath(path, object);

      var index = 0,
          length = path.length;

      while (object != null && index < length) {
        object = object[toKey(path[index++])];
      }
      return (index && index == length) ? object : undefined;
    }

    /**
     * The base implementation of `getAllKeys` and `getAllKeysIn` which uses
     * `keysFunc` and `symbolsFunc` to get the enumerable property names and
     * symbols of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @param {Function} keysFunc The function to get the keys of `object`.
     * @param {Function} symbolsFunc The function to get the symbols of `object`.
     * @returns {Array} Returns the array of property names and symbols.
     */
    function baseGetAllKeys(object, keysFunc, symbolsFunc) {
      var result = keysFunc(object);
      return isArray(object) ? result : arrayPush(result, symbolsFunc(object));
    }

    /**
     * The base implementation of `getTag` without fallbacks for buggy environments.
     *
     * @private
     * @param {*} value The value to query.
     * @returns {string} Returns the `toStringTag`.
     */
    function baseGetTag(value) {
      if (value == null) {
        return value === undefined ? undefinedTag : nullTag;
      }
      return (symToStringTag && symToStringTag in Object(value))
        ? getRawTag(value)
        : objectToString(value);
    }

    /**
     * The base implementation of `_.gt` which doesn't coerce arguments.
     *
     * @private
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if `value` is greater than `other`,
     *  else `false`.
     */
    function baseGt(value, other) {
      return value > other;
    }

    /**
     * The base implementation of `_.has` without support for deep paths.
     *
     * @private
     * @param {Object} [object] The object to query.
     * @param {Array|string} key The key to check.
     * @returns {boolean} Returns `true` if `key` exists, else `false`.
     */
    function baseHas(object, key) {
      return object != null && hasOwnProperty.call(object, key);
    }

    /**
     * The base implementation of `_.hasIn` without support for deep paths.
     *
     * @private
     * @param {Object} [object] The object to query.
     * @param {Array|string} key The key to check.
     * @returns {boolean} Returns `true` if `key` exists, else `false`.
     */
    function baseHasIn(object, key) {
      return object != null && key in Object(object);
    }

    /**
     * The base implementation of `_.inRange` which doesn't coerce arguments.
     *
     * @private
     * @param {number} number The number to check.
     * @param {number} start The start of the range.
     * @param {number} end The end of the range.
     * @returns {boolean} Returns `true` if `number` is in the range, else `false`.
     */
    function baseInRange(number, start, end) {
      return number >= nativeMin(start, end) && number < nativeMax(start, end);
    }

    /**
     * The base implementation of methods like `_.intersection`, without support
     * for iteratee shorthands, that accepts an array of arrays to inspect.
     *
     * @private
     * @param {Array} arrays The arrays to inspect.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of shared values.
     */
    function baseIntersection(arrays, iteratee, comparator) {
      var includes = comparator ? arrayIncludesWith : arrayIncludes,
          length = arrays[0].length,
          othLength = arrays.length,
          othIndex = othLength,
          caches = Array(othLength),
          maxLength = Infinity,
          result = [];

      while (othIndex--) {
        var array = arrays[othIndex];
        if (othIndex && iteratee) {
          array = arrayMap(array, baseUnary(iteratee));
        }
        maxLength = nativeMin(array.length, maxLength);
        caches[othIndex] = !comparator && (iteratee || (length >= 120 && array.length >= 120))
          ? new SetCache(othIndex && array)
          : undefined;
      }
      array = arrays[0];

      var index = -1,
          seen = caches[0];

      outer:
      while (++index < length && result.length < maxLength) {
        var value = array[index],
            computed = iteratee ? iteratee(value) : value;

        value = (comparator || value !== 0) ? value : 0;
        if (!(seen
              ? cacheHas(seen, computed)
              : includes(result, computed, comparator)
            )) {
          othIndex = othLength;
          while (--othIndex) {
            var cache = caches[othIndex];
            if (!(cache
                  ? cacheHas(cache, computed)
                  : includes(arrays[othIndex], computed, comparator))
                ) {
              continue outer;
            }
          }
          if (seen) {
            seen.push(computed);
          }
          result.push(value);
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.invert` and `_.invertBy` which inverts
     * `object` with values transformed by `iteratee` and set by `setter`.
     *
     * @private
     * @param {Object} object The object to iterate over.
     * @param {Function} setter The function to set `accumulator` values.
     * @param {Function} iteratee The iteratee to transform values.
     * @param {Object} accumulator The initial inverted object.
     * @returns {Function} Returns `accumulator`.
     */
    function baseInverter(object, setter, iteratee, accumulator) {
      baseForOwn(object, function(value, key, object) {
        setter(accumulator, iteratee(value), key, object);
      });
      return accumulator;
    }

    /**
     * The base implementation of `_.invoke` without support for individual
     * method arguments.
     *
     * @private
     * @param {Object} object The object to query.
     * @param {Array|string} path The path of the method to invoke.
     * @param {Array} args The arguments to invoke the method with.
     * @returns {*} Returns the result of the invoked method.
     */
    function baseInvoke(object, path, args) {
      path = castPath(path, object);
      object = parent(object, path);
      var func = object == null ? object : object[toKey(last(path))];
      return func == null ? undefined : apply(func, object, args);
    }

    /**
     * The base implementation of `_.isArguments`.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an `arguments` object,
     */
    function baseIsArguments(value) {
      return isObjectLike(value) && baseGetTag(value) == argsTag;
    }

    /**
     * The base implementation of `_.isArrayBuffer` without Node.js optimizations.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`.
     */
    function baseIsArrayBuffer(value) {
      return isObjectLike(value) && baseGetTag(value) == arrayBufferTag;
    }

    /**
     * The base implementation of `_.isDate` without Node.js optimizations.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a date object, else `false`.
     */
    function baseIsDate(value) {
      return isObjectLike(value) && baseGetTag(value) == dateTag;
    }

    /**
     * The base implementation of `_.isEqual` which supports partial comparisons
     * and tracks traversed objects.
     *
     * @private
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @param {boolean} bitmask The bitmask flags.
     *  1 - Unordered comparison
     *  2 - Partial comparison
     * @param {Function} [customizer] The function to customize comparisons.
     * @param {Object} [stack] Tracks traversed `value` and `other` objects.
     * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
     */
    function baseIsEqual(value, other, bitmask, customizer, stack) {
      if (value === other) {
        return true;
      }
      if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {
        return value !== value && other !== other;
      }
      return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);
    }

    /**
     * A specialized version of `baseIsEqual` for arrays and objects which performs
     * deep comparisons and tracks traversed objects enabling objects with circular
     * references to be compared.
     *
     * @private
     * @param {Object} object The object to compare.
     * @param {Object} other The other object to compare.
     * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.
     * @param {Function} customizer The function to customize comparisons.
     * @param {Function} equalFunc The function to determine equivalents of values.
     * @param {Object} [stack] Tracks traversed `object` and `other` objects.
     * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.
     */
    function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {
      var objIsArr = isArray(object),
          othIsArr = isArray(other),
          objTag = objIsArr ? arrayTag : getTag(object),
          othTag = othIsArr ? arrayTag : getTag(other);

      objTag = objTag == argsTag ? objectTag : objTag;
      othTag = othTag == argsTag ? objectTag : othTag;

      var objIsObj = objTag == objectTag,
          othIsObj = othTag == objectTag,
          isSameTag = objTag == othTag;

      if (isSameTag && isBuffer(object)) {
        if (!isBuffer(other)) {
          return false;
        }
        objIsArr = true;
        objIsObj = false;
      }
      if (isSameTag && !objIsObj) {
        stack || (stack = new Stack);
        return (objIsArr || isTypedArray(object))
          ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)
          : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);
      }
      if (!(bitmask & COMPARE_PARTIAL_FLAG)) {
        var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),
            othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');

        if (objIsWrapped || othIsWrapped) {
          var objUnwrapped = objIsWrapped ? object.value() : object,
              othUnwrapped = othIsWrapped ? other.value() : other;

          stack || (stack = new Stack);
          return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);
        }
      }
      if (!isSameTag) {
        return false;
      }
      stack || (stack = new Stack);
      return equalObjects(object, other, bitmask, customizer, equalFunc, stack);
    }

    /**
     * The base implementation of `_.isMap` without Node.js optimizations.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a map, else `false`.
     */
    function baseIsMap(value) {
      return isObjectLike(value) && getTag(value) == mapTag;
    }

    /**
     * The base implementation of `_.isMatch` without support for iteratee shorthands.
     *
     * @private
     * @param {Object} object The object to inspect.
     * @param {Object} source The object of property values to match.
     * @param {Array} matchData The property names, values, and compare flags to match.
     * @param {Function} [customizer] The function to customize comparisons.
     * @returns {boolean} Returns `true` if `object` is a match, else `false`.
     */
    function baseIsMatch(object, source, matchData, customizer) {
      var index = matchData.length,
          length = index,
          noCustomizer = !customizer;

      if (object == null) {
        return !length;
      }
      object = Object(object);
      while (index--) {
        var data = matchData[index];
        if ((noCustomizer && data[2])
              ? data[1] !== object[data[0]]
              : !(data[0] in object)
            ) {
          return false;
        }
      }
      while (++index < length) {
        data = matchData[index];
        var key = data[0],
            objValue = object[key],
            srcValue = data[1];

        if (noCustomizer && data[2]) {
          if (objValue === undefined && !(key in object)) {
            return false;
          }
        } else {
          var stack = new Stack;
          if (customizer) {
            var result = customizer(objValue, srcValue, key, object, source, stack);
          }
          if (!(result === undefined
                ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)
                : result
              )) {
            return false;
          }
        }
      }
      return true;
    }

    /**
     * The base implementation of `_.isNative` without bad shim checks.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a native function,
     *  else `false`.
     */
    function baseIsNative(value) {
      if (!isObject(value) || isMasked(value)) {
        return false;
      }
      var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
      return pattern.test(toSource(value));
    }

    /**
     * The base implementation of `_.isRegExp` without Node.js optimizations.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a regexp, else `false`.
     */
    function baseIsRegExp(value) {
      return isObjectLike(value) && baseGetTag(value) == regexpTag;
    }

    /**
     * The base implementation of `_.isSet` without Node.js optimizations.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a set, else `false`.
     */
    function baseIsSet(value) {
      return isObjectLike(value) && getTag(value) == setTag;
    }

    /**
     * The base implementation of `_.isTypedArray` without Node.js optimizations.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
     */
    function baseIsTypedArray(value) {
      return isObjectLike(value) &&
        isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
    }

    /**
     * The base implementation of `_.iteratee`.
     *
     * @private
     * @param {*} [value=_.identity] The value to convert to an iteratee.
     * @returns {Function} Returns the iteratee.
     */
    function baseIteratee(value) {
      // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.
      // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.
      if (typeof value == 'function') {
        return value;
      }
      if (value == null) {
        return identity;
      }
      if (typeof value == 'object') {
        return isArray(value)
          ? baseMatchesProperty(value[0], value[1])
          : baseMatches(value);
      }
      return property(value);
    }

    /**
     * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names.
     */
    function baseKeys(object) {
      if (!isPrototype(object)) {
        return nativeKeys(object);
      }
      var result = [];
      for (var key in Object(object)) {
        if (hasOwnProperty.call(object, key) && key != 'constructor') {
          result.push(key);
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names.
     */
    function baseKeysIn(object) {
      if (!isObject(object)) {
        return nativeKeysIn(object);
      }
      var isProto = isPrototype(object),
          result = [];

      for (var key in object) {
        if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {
          result.push(key);
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.lt` which doesn't coerce arguments.
     *
     * @private
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if `value` is less than `other`,
     *  else `false`.
     */
    function baseLt(value, other) {
      return value < other;
    }

    /**
     * The base implementation of `_.map` without support for iteratee shorthands.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} iteratee The function invoked per iteration.
     * @returns {Array} Returns the new mapped array.
     */
    function baseMap(collection, iteratee) {
      var index = -1,
          result = isArrayLike(collection) ? Array(collection.length) : [];

      baseEach(collection, function(value, key, collection) {
        result[++index] = iteratee(value, key, collection);
      });
      return result;
    }

    /**
     * The base implementation of `_.matches` which doesn't clone `source`.
     *
     * @private
     * @param {Object} source The object of property values to match.
     * @returns {Function} Returns the new spec function.
     */
    function baseMatches(source) {
      var matchData = getMatchData(source);
      if (matchData.length == 1 && matchData[0][2]) {
        return matchesStrictComparable(matchData[0][0], matchData[0][1]);
      }
      return function(object) {
        return object === source || baseIsMatch(object, source, matchData);
      };
    }

    /**
     * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.
     *
     * @private
     * @param {string} path The path of the property to get.
     * @param {*} srcValue The value to match.
     * @returns {Function} Returns the new spec function.
     */
    function baseMatchesProperty(path, srcValue) {
      if (isKey(path) && isStrictComparable(srcValue)) {
        return matchesStrictComparable(toKey(path), srcValue);
      }
      return function(object) {
        var objValue = get(object, path);
        return (objValue === undefined && objValue === srcValue)
          ? hasIn(object, path)
          : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
      };
    }

    /**
     * The base implementation of `_.merge` without support for multiple sources.
     *
     * @private
     * @param {Object} object The destination object.
     * @param {Object} source The source object.
     * @param {number} srcIndex The index of `source`.
     * @param {Function} [customizer] The function to customize merged values.
     * @param {Object} [stack] Tracks traversed source values and their merged
     *  counterparts.
     */
    function baseMerge(object, source, srcIndex, customizer, stack) {
      if (object === source) {
        return;
      }
      baseFor(source, function(srcValue, key) {
        stack || (stack = new Stack);
        if (isObject(srcValue)) {
          baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);
        }
        else {
          var newValue = customizer
            ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)
            : undefined;

          if (newValue === undefined) {
            newValue = srcValue;
          }
          assignMergeValue(object, key, newValue);
        }
      }, keysIn);
    }

    /**
     * A specialized version of `baseMerge` for arrays and objects which performs
     * deep merges and tracks traversed objects enabling objects with circular
     * references to be merged.
     *
     * @private
     * @param {Object} object The destination object.
     * @param {Object} source The source object.
     * @param {string} key The key of the value to merge.
     * @param {number} srcIndex The index of `source`.
     * @param {Function} mergeFunc The function to merge values.
     * @param {Function} [customizer] The function to customize assigned values.
     * @param {Object} [stack] Tracks traversed source values and their merged
     *  counterparts.
     */
    function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {
      var objValue = safeGet(object, key),
          srcValue = safeGet(source, key),
          stacked = stack.get(srcValue);

      if (stacked) {
        assignMergeValue(object, key, stacked);
        return;
      }
      var newValue = customizer
        ? customizer(objValue, srcValue, (key + ''), object, source, stack)
        : undefined;

      var isCommon = newValue === undefined;

      if (isCommon) {
        var isArr = isArray(srcValue),
            isBuff = !isArr && isBuffer(srcValue),
            isTyped = !isArr && !isBuff && isTypedArray(srcValue);

        newValue = srcValue;
        if (isArr || isBuff || isTyped) {
          if (isArray(objValue)) {
            newValue = objValue;
          }
          else if (isArrayLikeObject(objValue)) {
            newValue = copyArray(objValue);
          }
          else if (isBuff) {
            isCommon = false;
            newValue = cloneBuffer(srcValue, true);
          }
          else if (isTyped) {
            isCommon = false;
            newValue = cloneTypedArray(srcValue, true);
          }
          else {
            newValue = [];
          }
        }
        else if (isPlainObject(srcValue) || isArguments(srcValue)) {
          newValue = objValue;
          if (isArguments(objValue)) {
            newValue = toPlainObject(objValue);
          }
          else if (!isObject(objValue) || isFunction(objValue)) {
            newValue = initCloneObject(srcValue);
          }
        }
        else {
          isCommon = false;
        }
      }
      if (isCommon) {
        // Recursively merge objects and arrays (susceptible to call stack limits).
        stack.set(srcValue, newValue);
        mergeFunc(newValue, srcValue, srcIndex, customizer, stack);
        stack['delete'](srcValue);
      }
      assignMergeValue(object, key, newValue);
    }

    /**
     * The base implementation of `_.nth` which doesn't coerce arguments.
     *
     * @private
     * @param {Array} array The array to query.
     * @param {number} n The index of the element to return.
     * @returns {*} Returns the nth element of `array`.
     */
    function baseNth(array, n) {
      var length = array.length;
      if (!length) {
        return;
      }
      n += n < 0 ? length : 0;
      return isIndex(n, length) ? array[n] : undefined;
    }

    /**
     * The base implementation of `_.orderBy` without param guards.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function[]|Object[]|string[]} iteratees The iteratees to sort by.
     * @param {string[]} orders The sort orders of `iteratees`.
     * @returns {Array} Returns the new sorted array.
     */
    function baseOrderBy(collection, iteratees, orders) {
      if (iteratees.length) {
        iteratees = arrayMap(iteratees, function(iteratee) {
          if (isArray(iteratee)) {
            return function(value) {
              return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee);
            }
          }
          return iteratee;
        });
      } else {
        iteratees = [identity];
      }

      var index = -1;
      iteratees = arrayMap(iteratees, baseUnary(getIteratee()));

      var result = baseMap(collection, function(value, key, collection) {
        var criteria = arrayMap(iteratees, function(iteratee) {
          return iteratee(value);
        });
        return { 'criteria': criteria, 'index': ++index, 'value': value };
      });

      return baseSortBy(result, function(object, other) {
        return compareMultiple(object, other, orders);
      });
    }

    /**
     * The base implementation of `_.pick` without support for individual
     * property identifiers.
     *
     * @private
     * @param {Object} object The source object.
     * @param {string[]} paths The property paths to pick.
     * @returns {Object} Returns the new object.
     */
    function basePick(object, paths) {
      return basePickBy(object, paths, function(value, path) {
        return hasIn(object, path);
      });
    }

    /**
     * The base implementation of  `_.pickBy` without support for iteratee shorthands.
     *
     * @private
     * @param {Object} object The source object.
     * @param {string[]} paths The property paths to pick.
     * @param {Function} predicate The function invoked per property.
     * @returns {Object} Returns the new object.
     */
    function basePickBy(object, paths, predicate) {
      var index = -1,
          length = paths.length,
          result = {};

      while (++index < length) {
        var path = paths[index],
            value = baseGet(object, path);

        if (predicate(value, path)) {
          baseSet(result, castPath(path, object), value);
        }
      }
      return result;
    }

    /**
     * A specialized version of `baseProperty` which supports deep paths.
     *
     * @private
     * @param {Array|string} path The path of the property to get.
     * @returns {Function} Returns the new accessor function.
     */
    function basePropertyDeep(path) {
      return function(object) {
        return baseGet(object, path);
      };
    }

    /**
     * The base implementation of `_.pullAllBy` without support for iteratee
     * shorthands.
     *
     * @private
     * @param {Array} array The array to modify.
     * @param {Array} values The values to remove.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns `array`.
     */
    function basePullAll(array, values, iteratee, comparator) {
      var indexOf = comparator ? baseIndexOfWith : baseIndexOf,
          index = -1,
          length = values.length,
          seen = array;

      if (array === values) {
        values = copyArray(values);
      }
      if (iteratee) {
        seen = arrayMap(array, baseUnary(iteratee));
      }
      while (++index < length) {
        var fromIndex = 0,
            value = values[index],
            computed = iteratee ? iteratee(value) : value;

        while ((fromIndex = indexOf(seen, computed, fromIndex, comparator)) > -1) {
          if (seen !== array) {
            splice.call(seen, fromIndex, 1);
          }
          splice.call(array, fromIndex, 1);
        }
      }
      return array;
    }

    /**
     * The base implementation of `_.pullAt` without support for individual
     * indexes or capturing the removed elements.
     *
     * @private
     * @param {Array} array The array to modify.
     * @param {number[]} indexes The indexes of elements to remove.
     * @returns {Array} Returns `array`.
     */
    function basePullAt(array, indexes) {
      var length = array ? indexes.length : 0,
          lastIndex = length - 1;

      while (length--) {
        var index = indexes[length];
        if (length == lastIndex || index !== previous) {
          var previous = index;
          if (isIndex(index)) {
            splice.call(array, index, 1);
          } else {
            baseUnset(array, index);
          }
        }
      }
      return array;
    }

    /**
     * The base implementation of `_.random` without support for returning
     * floating-point numbers.
     *
     * @private
     * @param {number} lower The lower bound.
     * @param {number} upper The upper bound.
     * @returns {number} Returns the random number.
     */
    function baseRandom(lower, upper) {
      return lower + nativeFloor(nativeRandom() * (upper - lower + 1));
    }

    /**
     * The base implementation of `_.range` and `_.rangeRight` which doesn't
     * coerce arguments.
     *
     * @private
     * @param {number} start The start of the range.
     * @param {number} end The end of the range.
     * @param {number} step The value to increment or decrement by.
     * @param {boolean} [fromRight] Specify iterating from right to left.
     * @returns {Array} Returns the range of numbers.
     */
    function baseRange(start, end, step, fromRight) {
      var index = -1,
          length = nativeMax(nativeCeil((end - start) / (step || 1)), 0),
          result = Array(length);

      while (length--) {
        result[fromRight ? length : ++index] = start;
        start += step;
      }
      return result;
    }

    /**
     * The base implementation of `_.repeat` which doesn't coerce arguments.
     *
     * @private
     * @param {string} string The string to repeat.
     * @param {number} n The number of times to repeat the string.
     * @returns {string} Returns the repeated string.
     */
    function baseRepeat(string, n) {
      var result = '';
      if (!string || n < 1 || n > MAX_SAFE_INTEGER) {
        return result;
      }
      // Leverage the exponentiation by squaring algorithm for a faster repeat.
      // See https://en.wikipedia.org/wiki/Exponentiation_by_squaring for more details.
      do {
        if (n % 2) {
          result += string;
        }
        n = nativeFloor(n / 2);
        if (n) {
          string += string;
        }
      } while (n);

      return result;
    }

    /**
     * The base implementation of `_.rest` which doesn't validate or coerce arguments.
     *
     * @private
     * @param {Function} func The function to apply a rest parameter to.
     * @param {number} [start=func.length-1] The start position of the rest parameter.
     * @returns {Function} Returns the new function.
     */
    function baseRest(func, start) {
      return setToString(overRest(func, start, identity), func + '');
    }

    /**
     * The base implementation of `_.sample`.
     *
     * @private
     * @param {Array|Object} collection The collection to sample.
     * @returns {*} Returns the random element.
     */
    function baseSample(collection) {
      return arraySample(values(collection));
    }

    /**
     * The base implementation of `_.sampleSize` without param guards.
     *
     * @private
     * @param {Array|Object} collection The collection to sample.
     * @param {number} n The number of elements to sample.
     * @returns {Array} Returns the random elements.
     */
    function baseSampleSize(collection, n) {
      var array = values(collection);
      return shuffleSelf(array, baseClamp(n, 0, array.length));
    }

    /**
     * The base implementation of `_.set`.
     *
     * @private
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to set.
     * @param {*} value The value to set.
     * @param {Function} [customizer] The function to customize path creation.
     * @returns {Object} Returns `object`.
     */
    function baseSet(object, path, value, customizer) {
      if (!isObject(object)) {
        return object;
      }
      path = castPath(path, object);

      var index = -1,
          length = path.length,
          lastIndex = length - 1,
          nested = object;

      while (nested != null && ++index < length) {
        var key = toKey(path[index]),
            newValue = value;

        if (key === '__proto__' || key === 'constructor' || key === 'prototype') {
          return object;
        }

        if (index != lastIndex) {
          var objValue = nested[key];
          newValue = customizer ? customizer(objValue, key, nested) : undefined;
          if (newValue === undefined) {
            newValue = isObject(objValue)
              ? objValue
              : (isIndex(path[index + 1]) ? [] : {});
          }
        }
        assignValue(nested, key, newValue);
        nested = nested[key];
      }
      return object;
    }

    /**
     * The base implementation of `setData` without support for hot loop shorting.
     *
     * @private
     * @param {Function} func The function to associate metadata with.
     * @param {*} data The metadata.
     * @returns {Function} Returns `func`.
     */
    var baseSetData = !metaMap ? identity : function(func, data) {
      metaMap.set(func, data);
      return func;
    };

    /**
     * The base implementation of `setToString` without support for hot loop shorting.
     *
     * @private
     * @param {Function} func The function to modify.
     * @param {Function} string The `toString` result.
     * @returns {Function} Returns `func`.
     */
    var baseSetToString = !defineProperty ? identity : function(func, string) {
      return defineProperty(func, 'toString', {
        'configurable': true,
        'enumerable': false,
        'value': constant(string),
        'writable': true
      });
    };

    /**
     * The base implementation of `_.shuffle`.
     *
     * @private
     * @param {Array|Object} collection The collection to shuffle.
     * @returns {Array} Returns the new shuffled array.
     */
    function baseShuffle(collection) {
      return shuffleSelf(values(collection));
    }

    /**
     * The base implementation of `_.slice` without an iteratee call guard.
     *
     * @private
     * @param {Array} array The array to slice.
     * @param {number} [start=0] The start position.
     * @param {number} [end=array.length] The end position.
     * @returns {Array} Returns the slice of `array`.
     */
    function baseSlice(array, start, end) {
      var index = -1,
          length = array.length;

      if (start < 0) {
        start = -start > length ? 0 : (length + start);
      }
      end = end > length ? length : end;
      if (end < 0) {
        end += length;
      }
      length = start > end ? 0 : ((end - start) >>> 0);
      start >>>= 0;

      var result = Array(length);
      while (++index < length) {
        result[index] = array[index + start];
      }
      return result;
    }

    /**
     * The base implementation of `_.some` without support for iteratee shorthands.
     *
     * @private
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} predicate The function invoked per iteration.
     * @returns {boolean} Returns `true` if any element passes the predicate check,
     *  else `false`.
     */
    function baseSome(collection, predicate) {
      var result;

      baseEach(collection, function(value, index, collection) {
        result = predicate(value, index, collection);
        return !result;
      });
      return !!result;
    }

    /**
     * The base implementation of `_.sortedIndex` and `_.sortedLastIndex` which
     * performs a binary search of `array` to determine the index at which `value`
     * should be inserted into `array` in order to maintain its sort order.
     *
     * @private
     * @param {Array} array The sorted array to inspect.
     * @param {*} value The value to evaluate.
     * @param {boolean} [retHighest] Specify returning the highest qualified index.
     * @returns {number} Returns the index at which `value` should be inserted
     *  into `array`.
     */
    function baseSortedIndex(array, value, retHighest) {
      var low = 0,
          high = array == null ? low : array.length;

      if (typeof value == 'number' && value === value && high <= HALF_MAX_ARRAY_LENGTH) {
        while (low < high) {
          var mid = (low + high) >>> 1,
              computed = array[mid];

          if (computed !== null && !isSymbol(computed) &&
              (retHighest ? (computed <= value) : (computed < value))) {
            low = mid + 1;
          } else {
            high = mid;
          }
        }
        return high;
      }
      return baseSortedIndexBy(array, value, identity, retHighest);
    }

    /**
     * The base implementation of `_.sortedIndexBy` and `_.sortedLastIndexBy`
     * which invokes `iteratee` for `value` and each element of `array` to compute
     * their sort ranking. The iteratee is invoked with one argument; (value).
     *
     * @private
     * @param {Array} array The sorted array to inspect.
     * @param {*} value The value to evaluate.
     * @param {Function} iteratee The iteratee invoked per element.
     * @param {boolean} [retHighest] Specify returning the highest qualified index.
     * @returns {number} Returns the index at which `value` should be inserted
     *  into `array`.
     */
    function baseSortedIndexBy(array, value, iteratee, retHighest) {
      var low = 0,
          high = array == null ? 0 : array.length;
      if (high === 0) {
        return 0;
      }

      value = iteratee(value);
      var valIsNaN = value !== value,
          valIsNull = value === null,
          valIsSymbol = isSymbol(value),
          valIsUndefined = value === undefined;

      while (low < high) {
        var mid = nativeFloor((low + high) / 2),
            computed = iteratee(array[mid]),
            othIsDefined = computed !== undefined,
            othIsNull = computed === null,
            othIsReflexive = computed === computed,
            othIsSymbol = isSymbol(computed);

        if (valIsNaN) {
          var setLow = retHighest || othIsReflexive;
        } else if (valIsUndefined) {
          setLow = othIsReflexive && (retHighest || othIsDefined);
        } else if (valIsNull) {
          setLow = othIsReflexive && othIsDefined && (retHighest || !othIsNull);
        } else if (valIsSymbol) {
          setLow = othIsReflexive && othIsDefined && !othIsNull && (retHighest || !othIsSymbol);
        } else if (othIsNull || othIsSymbol) {
          setLow = false;
        } else {
          setLow = retHighest ? (computed <= value) : (computed < value);
        }
        if (setLow) {
          low = mid + 1;
        } else {
          high = mid;
        }
      }
      return nativeMin(high, MAX_ARRAY_INDEX);
    }

    /**
     * The base implementation of `_.sortedUniq` and `_.sortedUniqBy` without
     * support for iteratee shorthands.
     *
     * @private
     * @param {Array} array The array to inspect.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @returns {Array} Returns the new duplicate free array.
     */
    function baseSortedUniq(array, iteratee) {
      var index = -1,
          length = array.length,
          resIndex = 0,
          result = [];

      while (++index < length) {
        var value = array[index],
            computed = iteratee ? iteratee(value) : value;

        if (!index || !eq(computed, seen)) {
          var seen = computed;
          result[resIndex++] = value === 0 ? 0 : value;
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.toNumber` which doesn't ensure correct
     * conversions of binary, hexadecimal, or octal string values.
     *
     * @private
     * @param {*} value The value to process.
     * @returns {number} Returns the number.
     */
    function baseToNumber(value) {
      if (typeof value == 'number') {
        return value;
      }
      if (isSymbol(value)) {
        return NAN;
      }
      return +value;
    }

    /**
     * The base implementation of `_.toString` which doesn't convert nullish
     * values to empty strings.
     *
     * @private
     * @param {*} value The value to process.
     * @returns {string} Returns the string.
     */
    function baseToString(value) {
      // Exit early for strings to avoid a performance hit in some environments.
      if (typeof value == 'string') {
        return value;
      }
      if (isArray(value)) {
        // Recursively convert values (susceptible to call stack limits).
        return arrayMap(value, baseToString) + '';
      }
      if (isSymbol(value)) {
        return symbolToString ? symbolToString.call(value) : '';
      }
      var result = (value + '');
      return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
    }

    /**
     * The base implementation of `_.uniqBy` without support for iteratee shorthands.
     *
     * @private
     * @param {Array} array The array to inspect.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new duplicate free array.
     */
    function baseUniq(array, iteratee, comparator) {
      var index = -1,
          includes = arrayIncludes,
          length = array.length,
          isCommon = true,
          result = [],
          seen = result;

      if (comparator) {
        isCommon = false;
        includes = arrayIncludesWith;
      }
      else if (length >= LARGE_ARRAY_SIZE) {
        var set = iteratee ? null : createSet(array);
        if (set) {
          return setToArray(set);
        }
        isCommon = false;
        includes = cacheHas;
        seen = new SetCache;
      }
      else {
        seen = iteratee ? [] : result;
      }
      outer:
      while (++index < length) {
        var value = array[index],
            computed = iteratee ? iteratee(value) : value;

        value = (comparator || value !== 0) ? value : 0;
        if (isCommon && computed === computed) {
          var seenIndex = seen.length;
          while (seenIndex--) {
            if (seen[seenIndex] === computed) {
              continue outer;
            }
          }
          if (iteratee) {
            seen.push(computed);
          }
          result.push(value);
        }
        else if (!includes(seen, computed, comparator)) {
          if (seen !== result) {
            seen.push(computed);
          }
          result.push(value);
        }
      }
      return result;
    }

    /**
     * The base implementation of `_.unset`.
     *
     * @private
     * @param {Object} object The object to modify.
     * @param {Array|string} path The property path to unset.
     * @returns {boolean} Returns `true` if the property is deleted, else `false`.
     */
    function baseUnset(object, path) {
      path = castPath(path, object);
      object = parent(object, path);
      return object == null || delete object[toKey(last(path))];
    }

    /**
     * The base implementation of `_.update`.
     *
     * @private
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to update.
     * @param {Function} updater The function to produce the updated value.
     * @param {Function} [customizer] The function to customize path creation.
     * @returns {Object} Returns `object`.
     */
    function baseUpdate(object, path, updater, customizer) {
      return baseSet(object, path, updater(baseGet(object, path)), customizer);
    }

    /**
     * The base implementation of methods like `_.dropWhile` and `_.takeWhile`
     * without support for iteratee shorthands.
     *
     * @private
     * @param {Array} array The array to query.
     * @param {Function} predicate The function invoked per iteration.
     * @param {boolean} [isDrop] Specify dropping elements instead of taking them.
     * @param {boolean} [fromRight] Specify iterating from right to left.
     * @returns {Array} Returns the slice of `array`.
     */
    function baseWhile(array, predicate, isDrop, fromRight) {
      var length = array.length,
          index = fromRight ? length : -1;

      while ((fromRight ? index-- : ++index < length) &&
        predicate(array[index], index, array)) {}

      return isDrop
        ? baseSlice(array, (fromRight ? 0 : index), (fromRight ? index + 1 : length))
        : baseSlice(array, (fromRight ? index + 1 : 0), (fromRight ? length : index));
    }

    /**
     * The base implementation of `wrapperValue` which returns the result of
     * performing a sequence of actions on the unwrapped `value`, where each
     * successive action is supplied the return value of the previous.
     *
     * @private
     * @param {*} value The unwrapped value.
     * @param {Array} actions Actions to perform to resolve the unwrapped value.
     * @returns {*} Returns the resolved value.
     */
    function baseWrapperValue(value, actions) {
      var result = value;
      if (result instanceof LazyWrapper) {
        result = result.value();
      }
      return arrayReduce(actions, function(result, action) {
        return action.func.apply(action.thisArg, arrayPush([result], action.args));
      }, result);
    }

    /**
     * The base implementation of methods like `_.xor`, without support for
     * iteratee shorthands, that accepts an array of arrays to inspect.
     *
     * @private
     * @param {Array} arrays The arrays to inspect.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of values.
     */
    function baseXor(arrays, iteratee, comparator) {
      var length = arrays.length;
      if (length < 2) {
        return length ? baseUniq(arrays[0]) : [];
      }
      var index = -1,
          result = Array(length);

      while (++index < length) {
        var array = arrays[index],
            othIndex = -1;

        while (++othIndex < length) {
          if (othIndex != index) {
            result[index] = baseDifference(result[index] || array, arrays[othIndex], iteratee, comparator);
          }
        }
      }
      return baseUniq(baseFlatten(result, 1), iteratee, comparator);
    }

    /**
     * This base implementation of `_.zipObject` which assigns values using `assignFunc`.
     *
     * @private
     * @param {Array} props The property identifiers.
     * @param {Array} values The property values.
     * @param {Function} assignFunc The function to assign values.
     * @returns {Object} Returns the new object.
     */
    function baseZipObject(props, values, assignFunc) {
      var index = -1,
          length = props.length,
          valsLength = values.length,
          result = {};

      while (++index < length) {
        var value = index < valsLength ? values[index] : undefined;
        assignFunc(result, props[index], value);
      }
      return result;
    }

    /**
     * Casts `value` to an empty array if it's not an array like object.
     *
     * @private
     * @param {*} value The value to inspect.
     * @returns {Array|Object} Returns the cast array-like object.
     */
    function castArrayLikeObject(value) {
      return isArrayLikeObject(value) ? value : [];
    }

    /**
     * Casts `value` to `identity` if it's not a function.
     *
     * @private
     * @param {*} value The value to inspect.
     * @returns {Function} Returns cast function.
     */
    function castFunction(value) {
      return typeof value == 'function' ? value : identity;
    }

    /**
     * Casts `value` to a path array if it's not one.
     *
     * @private
     * @param {*} value The value to inspect.
     * @param {Object} [object] The object to query keys on.
     * @returns {Array} Returns the cast property path array.
     */
    function castPath(value, object) {
      if (isArray(value)) {
        return value;
      }
      return isKey(value, object) ? [value] : stringToPath(toString(value));
    }

    /**
     * A `baseRest` alias which can be replaced with `identity` by module
     * replacement plugins.
     *
     * @private
     * @type {Function}
     * @param {Function} func The function to apply a rest parameter to.
     * @returns {Function} Returns the new function.
     */
    var castRest = baseRest;

    /**
     * Casts `array` to a slice if it's needed.
     *
     * @private
     * @param {Array} array The array to inspect.
     * @param {number} start The start position.
     * @param {number} [end=array.length] The end position.
     * @returns {Array} Returns the cast slice.
     */
    function castSlice(array, start, end) {
      var length = array.length;
      end = end === undefined ? length : end;
      return (!start && end >= length) ? array : baseSlice(array, start, end);
    }

    /**
     * A simple wrapper around the global [`clearTimeout`](https://mdn.io/clearTimeout).
     *
     * @private
     * @param {number|Object} id The timer id or timeout object of the timer to clear.
     */
    var clearTimeout = ctxClearTimeout || function(id) {
      return root.clearTimeout(id);
    };

    /**
     * Creates a clone of  `buffer`.
     *
     * @private
     * @param {Buffer} buffer The buffer to clone.
     * @param {boolean} [isDeep] Specify a deep clone.
     * @returns {Buffer} Returns the cloned buffer.
     */
    function cloneBuffer(buffer, isDeep) {
      if (isDeep) {
        return buffer.slice();
      }
      var length = buffer.length,
          result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);

      buffer.copy(result);
      return result;
    }

    /**
     * Creates a clone of `arrayBuffer`.
     *
     * @private
     * @param {ArrayBuffer} arrayBuffer The array buffer to clone.
     * @returns {ArrayBuffer} Returns the cloned array buffer.
     */
    function cloneArrayBuffer(arrayBuffer) {
      var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
      new Uint8Array(result).set(new Uint8Array(arrayBuffer));
      return result;
    }

    /**
     * Creates a clone of `dataView`.
     *
     * @private
     * @param {Object} dataView The data view to clone.
     * @param {boolean} [isDeep] Specify a deep clone.
     * @returns {Object} Returns the cloned data view.
     */
    function cloneDataView(dataView, isDeep) {
      var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer;
      return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);
    }

    /**
     * Creates a clone of `regexp`.
     *
     * @private
     * @param {Object} regexp The regexp to clone.
     * @returns {Object} Returns the cloned regexp.
     */
    function cloneRegExp(regexp) {
      var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));
      result.lastIndex = regexp.lastIndex;
      return result;
    }

    /**
     * Creates a clone of the `symbol` object.
     *
     * @private
     * @param {Object} symbol The symbol object to clone.
     * @returns {Object} Returns the cloned symbol object.
     */
    function cloneSymbol(symbol) {
      return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {};
    }

    /**
     * Creates a clone of `typedArray`.
     *
     * @private
     * @param {Object} typedArray The typed array to clone.
     * @param {boolean} [isDeep] Specify a deep clone.
     * @returns {Object} Returns the cloned typed array.
     */
    function cloneTypedArray(typedArray, isDeep) {
      var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;
      return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
    }

    /**
     * Compares values to sort them in ascending order.
     *
     * @private
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {number} Returns the sort order indicator for `value`.
     */
    function compareAscending(value, other) {
      if (value !== other) {
        var valIsDefined = value !== undefined,
            valIsNull = value === null,
            valIsReflexive = value === value,
            valIsSymbol = isSymbol(value);

        var othIsDefined = other !== undefined,
            othIsNull = other === null,
            othIsReflexive = other === other,
            othIsSymbol = isSymbol(other);

        if ((!othIsNull && !othIsSymbol && !valIsSymbol && value > other) ||
            (valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol) ||
            (valIsNull && othIsDefined && othIsReflexive) ||
            (!valIsDefined && othIsReflexive) ||
            !valIsReflexive) {
          return 1;
        }
        if ((!valIsNull && !valIsSymbol && !othIsSymbol && value < other) ||
            (othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol) ||
            (othIsNull && valIsDefined && valIsReflexive) ||
            (!othIsDefined && valIsReflexive) ||
            !othIsReflexive) {
          return -1;
        }
      }
      return 0;
    }

    /**
     * Used by `_.orderBy` to compare multiple properties of a value to another
     * and stable sort them.
     *
     * If `orders` is unspecified, all values are sorted in ascending order. Otherwise,
     * specify an order of "desc" for descending or "asc" for ascending sort order
     * of corresponding values.
     *
     * @private
     * @param {Object} object The object to compare.
     * @param {Object} other The other object to compare.
     * @param {boolean[]|string[]} orders The order to sort by for each property.
     * @returns {number} Returns the sort order indicator for `object`.
     */
    function compareMultiple(object, other, orders) {
      var index = -1,
          objCriteria = object.criteria,
          othCriteria = other.criteria,
          length = objCriteria.length,
          ordersLength = orders.length;

      while (++index < length) {
        var result = compareAscending(objCriteria[index], othCriteria[index]);
        if (result) {
          if (index >= ordersLength) {
            return result;
          }
          var order = orders[index];
          return result * (order == 'desc' ? -1 : 1);
        }
      }
      // Fixes an `Array#sort` bug in the JS engine embedded in Adobe applications
      // that causes it, under certain circumstances, to provide the same value for
      // `object` and `other`. See https://github.com/jashkenas/underscore/pull/1247
      // for more details.
      //
      // This also ensures a stable sort in V8 and other engines.
      // See https://bugs.chromium.org/p/v8/issues/detail?id=90 for more details.
      return object.index - other.index;
    }

    /**
     * Creates an array that is the composition of partially applied arguments,
     * placeholders, and provided arguments into a single array of arguments.
     *
     * @private
     * @param {Array} args The provided arguments.
     * @param {Array} partials The arguments to prepend to those provided.
     * @param {Array} holders The `partials` placeholder indexes.
     * @params {boolean} [isCurried] Specify composing for a curried function.
     * @returns {Array} Returns the new array of composed arguments.
     */
    function composeArgs(args, partials, holders, isCurried) {
      var argsIndex = -1,
          argsLength = args.length,
          holdersLength = holders.length,
          leftIndex = -1,
          leftLength = partials.length,
          rangeLength = nativeMax(argsLength - holdersLength, 0),
          result = Array(leftLength + rangeLength),
          isUncurried = !isCurried;

      while (++leftIndex < leftLength) {
        result[leftIndex] = partials[leftIndex];
      }
      while (++argsIndex < holdersLength) {
        if (isUncurried || argsIndex < argsLength) {
          result[holders[argsIndex]] = args[argsIndex];
        }
      }
      while (rangeLength--) {
        result[leftIndex++] = args[argsIndex++];
      }
      return result;
    }

    /**
     * This function is like `composeArgs` except that the arguments composition
     * is tailored for `_.partialRight`.
     *
     * @private
     * @param {Array} args The provided arguments.
     * @param {Array} partials The arguments to append to those provided.
     * @param {Array} holders The `partials` placeholder indexes.
     * @params {boolean} [isCurried] Specify composing for a curried function.
     * @returns {Array} Returns the new array of composed arguments.
     */
    function composeArgsRight(args, partials, holders, isCurried) {
      var argsIndex = -1,
          argsLength = args.length,
          holdersIndex = -1,
          holdersLength = holders.length,
          rightIndex = -1,
          rightLength = partials.length,
          rangeLength = nativeMax(argsLength - holdersLength, 0),
          result = Array(rangeLength + rightLength),
          isUncurried = !isCurried;

      while (++argsIndex < rangeLength) {
        result[argsIndex] = args[argsIndex];
      }
      var offset = argsIndex;
      while (++rightIndex < rightLength) {
        result[offset + rightIndex] = partials[rightIndex];
      }
      while (++holdersIndex < holdersLength) {
        if (isUncurried || argsIndex < argsLength) {
          result[offset + holders[holdersIndex]] = args[argsIndex++];
        }
      }
      return result;
    }

    /**
     * Copies the values of `source` to `array`.
     *
     * @private
     * @param {Array} source The array to copy values from.
     * @param {Array} [array=[]] The array to copy values to.
     * @returns {Array} Returns `array`.
     */
    function copyArray(source, array) {
      var index = -1,
          length = source.length;

      array || (array = Array(length));
      while (++index < length) {
        array[index] = source[index];
      }
      return array;
    }

    /**
     * Copies properties of `source` to `object`.
     *
     * @private
     * @param {Object} source The object to copy properties from.
     * @param {Array} props The property identifiers to copy.
     * @param {Object} [object={}] The object to copy properties to.
     * @param {Function} [customizer] The function to customize copied values.
     * @returns {Object} Returns `object`.
     */
    function copyObject(source, props, object, customizer) {
      var isNew = !object;
      object || (object = {});

      var index = -1,
          length = props.length;

      while (++index < length) {
        var key = props[index];

        var newValue = customizer
          ? customizer(object[key], source[key], key, object, source)
          : undefined;

        if (newValue === undefined) {
          newValue = source[key];
        }
        if (isNew) {
          baseAssignValue(object, key, newValue);
        } else {
          assignValue(object, key, newValue);
        }
      }
      return object;
    }

    /**
     * Copies own symbols of `source` to `object`.
     *
     * @private
     * @param {Object} source The object to copy symbols from.
     * @param {Object} [object={}] The object to copy symbols to.
     * @returns {Object} Returns `object`.
     */
    function copySymbols(source, object) {
      return copyObject(source, getSymbols(source), object);
    }

    /**
     * Copies own and inherited symbols of `source` to `object`.
     *
     * @private
     * @param {Object} source The object to copy symbols from.
     * @param {Object} [object={}] The object to copy symbols to.
     * @returns {Object} Returns `object`.
     */
    function copySymbolsIn(source, object) {
      return copyObject(source, getSymbolsIn(source), object);
    }

    /**
     * Creates a function like `_.groupBy`.
     *
     * @private
     * @param {Function} setter The function to set accumulator values.
     * @param {Function} [initializer] The accumulator object initializer.
     * @returns {Function} Returns the new aggregator function.
     */
    function createAggregator(setter, initializer) {
      return function(collection, iteratee) {
        var func = isArray(collection) ? arrayAggregator : baseAggregator,
            accumulator = initializer ? initializer() : {};

        return func(collection, setter, getIteratee(iteratee, 2), accumulator);
      };
    }

    /**
     * Creates a function like `_.assign`.
     *
     * @private
     * @param {Function} assigner The function to assign values.
     * @returns {Function} Returns the new assigner function.
     */
    function createAssigner(assigner) {
      return baseRest(function(object, sources) {
        var index = -1,
            length = sources.length,
            customizer = length > 1 ? sources[length - 1] : undefined,
            guard = length > 2 ? sources[2] : undefined;

        customizer = (assigner.length > 3 && typeof customizer == 'function')
          ? (length--, customizer)
          : undefined;

        if (guard && isIterateeCall(sources[0], sources[1], guard)) {
          customizer = length < 3 ? undefined : customizer;
          length = 1;
        }
        object = Object(object);
        while (++index < length) {
          var source = sources[index];
          if (source) {
            assigner(object, source, index, customizer);
          }
        }
        return object;
      });
    }

    /**
     * Creates a `baseEach` or `baseEachRight` function.
     *
     * @private
     * @param {Function} eachFunc The function to iterate over a collection.
     * @param {boolean} [fromRight] Specify iterating from right to left.
     * @returns {Function} Returns the new base function.
     */
    function createBaseEach(eachFunc, fromRight) {
      return function(collection, iteratee) {
        if (collection == null) {
          return collection;
        }
        if (!isArrayLike(collection)) {
          return eachFunc(collection, iteratee);
        }
        var length = collection.length,
            index = fromRight ? length : -1,
            iterable = Object(collection);

        while ((fromRight ? index-- : ++index < length)) {
          if (iteratee(iterable[index], index, iterable) === false) {
            break;
          }
        }
        return collection;
      };
    }

    /**
     * Creates a base function for methods like `_.forIn` and `_.forOwn`.
     *
     * @private
     * @param {boolean} [fromRight] Specify iterating from right to left.
     * @returns {Function} Returns the new base function.
     */
    function createBaseFor(fromRight) {
      return function(object, iteratee, keysFunc) {
        var index = -1,
            iterable = Object(object),
            props = keysFunc(object),
            length = props.length;

        while (length--) {
          var key = props[fromRight ? length : ++index];
          if (iteratee(iterable[key], key, iterable) === false) {
            break;
          }
        }
        return object;
      };
    }

    /**
     * Creates a function that wraps `func` to invoke it with the optional `this`
     * binding of `thisArg`.
     *
     * @private
     * @param {Function} func The function to wrap.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @param {*} [thisArg] The `this` binding of `func`.
     * @returns {Function} Returns the new wrapped function.
     */
    function createBind(func, bitmask, thisArg) {
      var isBind = bitmask & WRAP_BIND_FLAG,
          Ctor = createCtor(func);

      function wrapper() {
        var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
        return fn.apply(isBind ? thisArg : this, arguments);
      }
      return wrapper;
    }

    /**
     * Creates a function like `_.lowerFirst`.
     *
     * @private
     * @param {string} methodName The name of the `String` case method to use.
     * @returns {Function} Returns the new case function.
     */
    function createCaseFirst(methodName) {
      return function(string) {
        string = toString(string);

        var strSymbols = hasUnicode(string)
          ? stringToArray(string)
          : undefined;

        var chr = strSymbols
          ? strSymbols[0]
          : string.charAt(0);

        var trailing = strSymbols
          ? castSlice(strSymbols, 1).join('')
          : string.slice(1);

        return chr[methodName]() + trailing;
      };
    }

    /**
     * Creates a function like `_.camelCase`.
     *
     * @private
     * @param {Function} callback The function to combine each word.
     * @returns {Function} Returns the new compounder function.
     */
    function createCompounder(callback) {
      return function(string) {
        return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');
      };
    }

    /**
     * Creates a function that produces an instance of `Ctor` regardless of
     * whether it was invoked as part of a `new` expression or by `call` or `apply`.
     *
     * @private
     * @param {Function} Ctor The constructor to wrap.
     * @returns {Function} Returns the new wrapped function.
     */
    function createCtor(Ctor) {
      return function() {
        // Use a `switch` statement to work with class constructors. See
        // http://ecma-international.org/ecma-262/7.0/#sec-ecmascript-function-objects-call-thisargument-argumentslist
        // for more details.
        var args = arguments;
        switch (args.length) {
          case 0: return new Ctor;
          case 1: return new Ctor(args[0]);
          case 2: return new Ctor(args[0], args[1]);
          case 3: return new Ctor(args[0], args[1], args[2]);
          case 4: return new Ctor(args[0], args[1], args[2], args[3]);
          case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]);
          case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);
          case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);
        }
        var thisBinding = baseCreate(Ctor.prototype),
            result = Ctor.apply(thisBinding, args);

        // Mimic the constructor's `return` behavior.
        // See https://es5.github.io/#x13.2.2 for more details.
        return isObject(result) ? result : thisBinding;
      };
    }

    /**
     * Creates a function that wraps `func` to enable currying.
     *
     * @private
     * @param {Function} func The function to wrap.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @param {number} arity The arity of `func`.
     * @returns {Function} Returns the new wrapped function.
     */
    function createCurry(func, bitmask, arity) {
      var Ctor = createCtor(func);

      function wrapper() {
        var length = arguments.length,
            args = Array(length),
            index = length,
            placeholder = getHolder(wrapper);

        while (index--) {
          args[index] = arguments[index];
        }
        var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder)
          ? []
          : replaceHolders(args, placeholder);

        length -= holders.length;
        if (length < arity) {
          return createRecurry(
            func, bitmask, createHybrid, wrapper.placeholder, undefined,
            args, holders, undefined, undefined, arity - length);
        }
        var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
        return apply(fn, this, args);
      }
      return wrapper;
    }

    /**
     * Creates a `_.find` or `_.findLast` function.
     *
     * @private
     * @param {Function} findIndexFunc The function to find the collection index.
     * @returns {Function} Returns the new find function.
     */
    function createFind(findIndexFunc) {
      return function(collection, predicate, fromIndex) {
        var iterable = Object(collection);
        if (!isArrayLike(collection)) {
          var iteratee = getIteratee(predicate, 3);
          collection = keys(collection);
          predicate = function(key) { return iteratee(iterable[key], key, iterable); };
        }
        var index = findIndexFunc(collection, predicate, fromIndex);
        return index > -1 ? iterable[iteratee ? collection[index] : index] : undefined;
      };
    }

    /**
     * Creates a `_.flow` or `_.flowRight` function.
     *
     * @private
     * @param {boolean} [fromRight] Specify iterating from right to left.
     * @returns {Function} Returns the new flow function.
     */
    function createFlow(fromRight) {
      return flatRest(function(funcs) {
        var length = funcs.length,
            index = length,
            prereq = LodashWrapper.prototype.thru;

        if (fromRight) {
          funcs.reverse();
        }
        while (index--) {
          var func = funcs[index];
          if (typeof func != 'function') {
            throw new TypeError(FUNC_ERROR_TEXT);
          }
          if (prereq && !wrapper && getFuncName(func) == 'wrapper') {
            var wrapper = new LodashWrapper([], true);
          }
        }
        index = wrapper ? index : length;
        while (++index < length) {
          func = funcs[index];

          var funcName = getFuncName(func),
              data = funcName == 'wrapper' ? getData(func) : undefined;

          if (data && isLaziable(data[0]) &&
                data[1] == (WRAP_ARY_FLAG | WRAP_CURRY_FLAG | WRAP_PARTIAL_FLAG | WRAP_REARG_FLAG) &&
                !data[4].length && data[9] == 1
              ) {
            wrapper = wrapper[getFuncName(data[0])].apply(wrapper, data[3]);
          } else {
            wrapper = (func.length == 1 && isLaziable(func))
              ? wrapper[funcName]()
              : wrapper.thru(func);
          }
        }
        return function() {
          var args = arguments,
              value = args[0];

          if (wrapper && args.length == 1 && isArray(value)) {
            return wrapper.plant(value).value();
          }
          var index = 0,
              result = length ? funcs[index].apply(this, args) : value;

          while (++index < length) {
            result = funcs[index].call(this, result);
          }
          return result;
        };
      });
    }

    /**
     * Creates a function that wraps `func` to invoke it with optional `this`
     * binding of `thisArg`, partial application, and currying.
     *
     * @private
     * @param {Function|string} func The function or method name to wrap.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @param {*} [thisArg] The `this` binding of `func`.
     * @param {Array} [partials] The arguments to prepend to those provided to
     *  the new function.
     * @param {Array} [holders] The `partials` placeholder indexes.
     * @param {Array} [partialsRight] The arguments to append to those provided
     *  to the new function.
     * @param {Array} [holdersRight] The `partialsRight` placeholder indexes.
     * @param {Array} [argPos] The argument positions of the new function.
     * @param {number} [ary] The arity cap of `func`.
     * @param {number} [arity] The arity of `func`.
     * @returns {Function} Returns the new wrapped function.
     */
    function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity) {
      var isAry = bitmask & WRAP_ARY_FLAG,
          isBind = bitmask & WRAP_BIND_FLAG,
          isBindKey = bitmask & WRAP_BIND_KEY_FLAG,
          isCurried = bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG),
          isFlip = bitmask & WRAP_FLIP_FLAG,
          Ctor = isBindKey ? undefined : createCtor(func);

      function wrapper() {
        var length = arguments.length,
            args = Array(length),
            index = length;

        while (index--) {
          args[index] = arguments[index];
        }
        if (isCurried) {
          var placeholder = getHolder(wrapper),
              holdersCount = countHolders(args, placeholder);
        }
        if (partials) {
          args = composeArgs(args, partials, holders, isCurried);
        }
        if (partialsRight) {
          args = composeArgsRight(args, partialsRight, holdersRight, isCurried);
        }
        length -= holdersCount;
        if (isCurried && length < arity) {
          var newHolders = replaceHolders(args, placeholder);
          return createRecurry(
            func, bitmask, createHybrid, wrapper.placeholder, thisArg,
            args, newHolders, argPos, ary, arity - length
          );
        }
        var thisBinding = isBind ? thisArg : this,
            fn = isBindKey ? thisBinding[func] : func;

        length = args.length;
        if (argPos) {
          args = reorder(args, argPos);
        } else if (isFlip && length > 1) {
          args.reverse();
        }
        if (isAry && ary < length) {
          args.length = ary;
        }
        if (this && this !== root && this instanceof wrapper) {
          fn = Ctor || createCtor(fn);
        }
        return fn.apply(thisBinding, args);
      }
      return wrapper;
    }

    /**
     * Creates a function like `_.invertBy`.
     *
     * @private
     * @param {Function} setter The function to set accumulator values.
     * @param {Function} toIteratee The function to resolve iteratees.
     * @returns {Function} Returns the new inverter function.
     */
    function createInverter(setter, toIteratee) {
      return function(object, iteratee) {
        return baseInverter(object, setter, toIteratee(iteratee), {});
      };
    }

    /**
     * Creates a function that performs a mathematical operation on two values.
     *
     * @private
     * @param {Function} operator The function to perform the operation.
     * @param {number} [defaultValue] The value used for `undefined` arguments.
     * @returns {Function} Returns the new mathematical operation function.
     */
    function createMathOperation(operator, defaultValue) {
      return function(value, other) {
        var result;
        if (value === undefined && other === undefined) {
          return defaultValue;
        }
        if (value !== undefined) {
          result = value;
        }
        if (other !== undefined) {
          if (result === undefined) {
            return other;
          }
          if (typeof value == 'string' || typeof other == 'string') {
            value = baseToString(value);
            other = baseToString(other);
          } else {
            value = baseToNumber(value);
            other = baseToNumber(other);
          }
          result = operator(value, other);
        }
        return result;
      };
    }

    /**
     * Creates a function like `_.over`.
     *
     * @private
     * @param {Function} arrayFunc The function to iterate over iteratees.
     * @returns {Function} Returns the new over function.
     */
    function createOver(arrayFunc) {
      return flatRest(function(iteratees) {
        iteratees = arrayMap(iteratees, baseUnary(getIteratee()));
        return baseRest(function(args) {
          var thisArg = this;
          return arrayFunc(iteratees, function(iteratee) {
            return apply(iteratee, thisArg, args);
          });
        });
      });
    }

    /**
     * Creates the padding for `string` based on `length`. The `chars` string
     * is truncated if the number of characters exceeds `length`.
     *
     * @private
     * @param {number} length The padding length.
     * @param {string} [chars=' '] The string used as padding.
     * @returns {string} Returns the padding for `string`.
     */
    function createPadding(length, chars) {
      chars = chars === undefined ? ' ' : baseToString(chars);

      var charsLength = chars.length;
      if (charsLength < 2) {
        return charsLength ? baseRepeat(chars, length) : chars;
      }
      var result = baseRepeat(chars, nativeCeil(length / stringSize(chars)));
      return hasUnicode(chars)
        ? castSlice(stringToArray(result), 0, length).join('')
        : result.slice(0, length);
    }

    /**
     * Creates a function that wraps `func` to invoke it with the `this` binding
     * of `thisArg` and `partials` prepended to the arguments it receives.
     *
     * @private
     * @param {Function} func The function to wrap.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @param {*} thisArg The `this` binding of `func`.
     * @param {Array} partials The arguments to prepend to those provided to
     *  the new function.
     * @returns {Function} Returns the new wrapped function.
     */
    function createPartial(func, bitmask, thisArg, partials) {
      var isBind = bitmask & WRAP_BIND_FLAG,
          Ctor = createCtor(func);

      function wrapper() {
        var argsIndex = -1,
            argsLength = arguments.length,
            leftIndex = -1,
            leftLength = partials.length,
            args = Array(leftLength + argsLength),
            fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;

        while (++leftIndex < leftLength) {
          args[leftIndex] = partials[leftIndex];
        }
        while (argsLength--) {
          args[leftIndex++] = arguments[++argsIndex];
        }
        return apply(fn, isBind ? thisArg : this, args);
      }
      return wrapper;
    }

    /**
     * Creates a `_.range` or `_.rangeRight` function.
     *
     * @private
     * @param {boolean} [fromRight] Specify iterating from right to left.
     * @returns {Function} Returns the new range function.
     */
    function createRange(fromRight) {
      return function(start, end, step) {
        if (step && typeof step != 'number' && isIterateeCall(start, end, step)) {
          end = step = undefined;
        }
        // Ensure the sign of `-0` is preserved.
        start = toFinite(start);
        if (end === undefined) {
          end = start;
          start = 0;
        } else {
          end = toFinite(end);
        }
        step = step === undefined ? (start < end ? 1 : -1) : toFinite(step);
        return baseRange(start, end, step, fromRight);
      };
    }

    /**
     * Creates a function that performs a relational operation on two values.
     *
     * @private
     * @param {Function} operator The function to perform the operation.
     * @returns {Function} Returns the new relational operation function.
     */
    function createRelationalOperation(operator) {
      return function(value, other) {
        if (!(typeof value == 'string' && typeof other == 'string')) {
          value = toNumber(value);
          other = toNumber(other);
        }
        return operator(value, other);
      };
    }

    /**
     * Creates a function that wraps `func` to continue currying.
     *
     * @private
     * @param {Function} func The function to wrap.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @param {Function} wrapFunc The function to create the `func` wrapper.
     * @param {*} placeholder The placeholder value.
     * @param {*} [thisArg] The `this` binding of `func`.
     * @param {Array} [partials] The arguments to prepend to those provided to
     *  the new function.
     * @param {Array} [holders] The `partials` placeholder indexes.
     * @param {Array} [argPos] The argument positions of the new function.
     * @param {number} [ary] The arity cap of `func`.
     * @param {number} [arity] The arity of `func`.
     * @returns {Function} Returns the new wrapped function.
     */
    function createRecurry(func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary, arity) {
      var isCurry = bitmask & WRAP_CURRY_FLAG,
          newHolders = isCurry ? holders : undefined,
          newHoldersRight = isCurry ? undefined : holders,
          newPartials = isCurry ? partials : undefined,
          newPartialsRight = isCurry ? undefined : partials;

      bitmask |= (isCurry ? WRAP_PARTIAL_FLAG : WRAP_PARTIAL_RIGHT_FLAG);
      bitmask &= ~(isCurry ? WRAP_PARTIAL_RIGHT_FLAG : WRAP_PARTIAL_FLAG);

      if (!(bitmask & WRAP_CURRY_BOUND_FLAG)) {
        bitmask &= ~(WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG);
      }
      var newData = [
        func, bitmask, thisArg, newPartials, newHolders, newPartialsRight,
        newHoldersRight, argPos, ary, arity
      ];

      var result = wrapFunc.apply(undefined, newData);
      if (isLaziable(func)) {
        setData(result, newData);
      }
      result.placeholder = placeholder;
      return setWrapToString(result, func, bitmask);
    }

    /**
     * Creates a function like `_.round`.
     *
     * @private
     * @param {string} methodName The name of the `Math` method to use when rounding.
     * @returns {Function} Returns the new round function.
     */
    function createRound(methodName) {
      var func = Math[methodName];
      return function(number, precision) {
        number = toNumber(number);
        precision = precision == null ? 0 : nativeMin(toInteger(precision), 292);
        if (precision && nativeIsFinite(number)) {
          // Shift with exponential notation to avoid floating-point issues.
          // See [MDN](https://mdn.io/round#Examples) for more details.
          var pair = (toString(number) + 'e').split('e'),
              value = func(pair[0] + 'e' + (+pair[1] + precision));

          pair = (toString(value) + 'e').split('e');
          return +(pair[0] + 'e' + (+pair[1] - precision));
        }
        return func(number);
      };
    }

    /**
     * Creates a set object of `values`.
     *
     * @private
     * @param {Array} values The values to add to the set.
     * @returns {Object} Returns the new set.
     */
    var createSet = !(Set && (1 / setToArray(new Set([,-0]))[1]) == INFINITY) ? noop : function(values) {
      return new Set(values);
    };

    /**
     * Creates a `_.toPairs` or `_.toPairsIn` function.
     *
     * @private
     * @param {Function} keysFunc The function to get the keys of a given object.
     * @returns {Function} Returns the new pairs function.
     */
    function createToPairs(keysFunc) {
      return function(object) {
        var tag = getTag(object);
        if (tag == mapTag) {
          return mapToArray(object);
        }
        if (tag == setTag) {
          return setToPairs(object);
        }
        return baseToPairs(object, keysFunc(object));
      };
    }

    /**
     * Creates a function that either curries or invokes `func` with optional
     * `this` binding and partially applied arguments.
     *
     * @private
     * @param {Function|string} func The function or method name to wrap.
     * @param {number} bitmask The bitmask flags.
     *    1 - `_.bind`
     *    2 - `_.bindKey`
     *    4 - `_.curry` or `_.curryRight` of a bound function
     *    8 - `_.curry`
     *   16 - `_.curryRight`
     *   32 - `_.partial`
     *   64 - `_.partialRight`
     *  128 - `_.rearg`
     *  256 - `_.ary`
     *  512 - `_.flip`
     * @param {*} [thisArg] The `this` binding of `func`.
     * @param {Array} [partials] The arguments to be partially applied.
     * @param {Array} [holders] The `partials` placeholder indexes.
     * @param {Array} [argPos] The argument positions of the new function.
     * @param {number} [ary] The arity cap of `func`.
     * @param {number} [arity] The arity of `func`.
     * @returns {Function} Returns the new wrapped function.
     */
    function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary, arity) {
      var isBindKey = bitmask & WRAP_BIND_KEY_FLAG;
      if (!isBindKey && typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      var length = partials ? partials.length : 0;
      if (!length) {
        bitmask &= ~(WRAP_PARTIAL_FLAG | WRAP_PARTIAL_RIGHT_FLAG);
        partials = holders = undefined;
      }
      ary = ary === undefined ? ary : nativeMax(toInteger(ary), 0);
      arity = arity === undefined ? arity : toInteger(arity);
      length -= holders ? holders.length : 0;

      if (bitmask & WRAP_PARTIAL_RIGHT_FLAG) {
        var partialsRight = partials,
            holdersRight = holders;

        partials = holders = undefined;
      }
      var data = isBindKey ? undefined : getData(func);

      var newData = [
        func, bitmask, thisArg, partials, holders, partialsRight, holdersRight,
        argPos, ary, arity
      ];

      if (data) {
        mergeData(newData, data);
      }
      func = newData[0];
      bitmask = newData[1];
      thisArg = newData[2];
      partials = newData[3];
      holders = newData[4];
      arity = newData[9] = newData[9] === undefined
        ? (isBindKey ? 0 : func.length)
        : nativeMax(newData[9] - length, 0);

      if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) {
        bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG);
      }
      if (!bitmask || bitmask == WRAP_BIND_FLAG) {
        var result = createBind(func, bitmask, thisArg);
      } else if (bitmask == WRAP_CURRY_FLAG || bitmask == WRAP_CURRY_RIGHT_FLAG) {
        result = createCurry(func, bitmask, arity);
      } else if ((bitmask == WRAP_PARTIAL_FLAG || bitmask == (WRAP_BIND_FLAG | WRAP_PARTIAL_FLAG)) && !holders.length) {
        result = createPartial(func, bitmask, thisArg, partials);
      } else {
        result = createHybrid.apply(undefined, newData);
      }
      var setter = data ? baseSetData : setData;
      return setWrapToString(setter(result, newData), func, bitmask);
    }

    /**
     * Used by `_.defaults` to customize its `_.assignIn` use to assign properties
     * of source objects to the destination object for all destination properties
     * that resolve to `undefined`.
     *
     * @private
     * @param {*} objValue The destination value.
     * @param {*} srcValue The source value.
     * @param {string} key The key of the property to assign.
     * @param {Object} object The parent object of `objValue`.
     * @returns {*} Returns the value to assign.
     */
    function customDefaultsAssignIn(objValue, srcValue, key, object) {
      if (objValue === undefined ||
          (eq(objValue, objectProto[key]) && !hasOwnProperty.call(object, key))) {
        return srcValue;
      }
      return objValue;
    }

    /**
     * Used by `_.defaultsDeep` to customize its `_.merge` use to merge source
     * objects into destination objects that are passed thru.
     *
     * @private
     * @param {*} objValue The destination value.
     * @param {*} srcValue The source value.
     * @param {string} key The key of the property to merge.
     * @param {Object} object The parent object of `objValue`.
     * @param {Object} source The parent object of `srcValue`.
     * @param {Object} [stack] Tracks traversed source values and their merged
     *  counterparts.
     * @returns {*} Returns the value to assign.
     */
    function customDefaultsMerge(objValue, srcValue, key, object, source, stack) {
      if (isObject(objValue) && isObject(srcValue)) {
        // Recursively merge objects and arrays (susceptible to call stack limits).
        stack.set(srcValue, objValue);
        baseMerge(objValue, srcValue, undefined, customDefaultsMerge, stack);
        stack['delete'](srcValue);
      }
      return objValue;
    }

    /**
     * Used by `_.omit` to customize its `_.cloneDeep` use to only clone plain
     * objects.
     *
     * @private
     * @param {*} value The value to inspect.
     * @param {string} key The key of the property to inspect.
     * @returns {*} Returns the uncloned value or `undefined` to defer cloning to `_.cloneDeep`.
     */
    function customOmitClone(value) {
      return isPlainObject(value) ? undefined : value;
    }

    /**
     * A specialized version of `baseIsEqualDeep` for arrays with support for
     * partial deep comparisons.
     *
     * @private
     * @param {Array} array The array to compare.
     * @param {Array} other The other array to compare.
     * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.
     * @param {Function} customizer The function to customize comparisons.
     * @param {Function} equalFunc The function to determine equivalents of values.
     * @param {Object} stack Tracks traversed `array` and `other` objects.
     * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.
     */
    function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {
      var isPartial = bitmask & COMPARE_PARTIAL_FLAG,
          arrLength = array.length,
          othLength = other.length;

      if (arrLength != othLength && !(isPartial && othLength > arrLength)) {
        return false;
      }
      // Check that cyclic values are equal.
      var arrStacked = stack.get(array);
      var othStacked = stack.get(other);
      if (arrStacked && othStacked) {
        return arrStacked == other && othStacked == array;
      }
      var index = -1,
          result = true,
          seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;

      stack.set(array, other);
      stack.set(other, array);

      // Ignore non-index properties.
      while (++index < arrLength) {
        var arrValue = array[index],
            othValue = other[index];

        if (customizer) {
          var compared = isPartial
            ? customizer(othValue, arrValue, index, other, array, stack)
            : customizer(arrValue, othValue, index, array, other, stack);
        }
        if (compared !== undefined) {
          if (compared) {
            continue;
          }
          result = false;
          break;
        }
        // Recursively compare arrays (susceptible to call stack limits).
        if (seen) {
          if (!arraySome(other, function(othValue, othIndex) {
                if (!cacheHas(seen, othIndex) &&
                    (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {
                  return seen.push(othIndex);
                }
              })) {
            result = false;
            break;
          }
        } else if (!(
              arrValue === othValue ||
                equalFunc(arrValue, othValue, bitmask, customizer, stack)
            )) {
          result = false;
          break;
        }
      }
      stack['delete'](array);
      stack['delete'](other);
      return result;
    }

    /**
     * A specialized version of `baseIsEqualDeep` for comparing objects of
     * the same `toStringTag`.
     *
     * **Note:** This function only supports comparing values with tags of
     * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.
     *
     * @private
     * @param {Object} object The object to compare.
     * @param {Object} other The other object to compare.
     * @param {string} tag The `toStringTag` of the objects to compare.
     * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.
     * @param {Function} customizer The function to customize comparisons.
     * @param {Function} equalFunc The function to determine equivalents of values.
     * @param {Object} stack Tracks traversed `object` and `other` objects.
     * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.
     */
    function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {
      switch (tag) {
        case dataViewTag:
          if ((object.byteLength != other.byteLength) ||
              (object.byteOffset != other.byteOffset)) {
            return false;
          }
          object = object.buffer;
          other = other.buffer;

        case arrayBufferTag:
          if ((object.byteLength != other.byteLength) ||
              !equalFunc(new Uint8Array(object), new Uint8Array(other))) {
            return false;
          }
          return true;

        case boolTag:
        case dateTag:
        case numberTag:
          // Coerce booleans to `1` or `0` and dates to milliseconds.
          // Invalid dates are coerced to `NaN`.
          return eq(+object, +other);

        case errorTag:
          return object.name == other.name && object.message == other.message;

        case regexpTag:
        case stringTag:
          // Coerce regexes to strings and treat strings, primitives and objects,
          // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring
          // for more details.
          return object == (other + '');

        case mapTag:
          var convert = mapToArray;

        case setTag:
          var isPartial = bitmask & COMPARE_PARTIAL_FLAG;
          convert || (convert = setToArray);

          if (object.size != other.size && !isPartial) {
            return false;
          }
          // Assume cyclic values are equal.
          var stacked = stack.get(object);
          if (stacked) {
            return stacked == other;
          }
          bitmask |= COMPARE_UNORDERED_FLAG;

          // Recursively compare objects (susceptible to call stack limits).
          stack.set(object, other);
          var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);
          stack['delete'](object);
          return result;

        case symbolTag:
          if (symbolValueOf) {
            return symbolValueOf.call(object) == symbolValueOf.call(other);
          }
      }
      return false;
    }

    /**
     * A specialized version of `baseIsEqualDeep` for objects with support for
     * partial deep comparisons.
     *
     * @private
     * @param {Object} object The object to compare.
     * @param {Object} other The other object to compare.
     * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.
     * @param {Function} customizer The function to customize comparisons.
     * @param {Function} equalFunc The function to determine equivalents of values.
     * @param {Object} stack Tracks traversed `object` and `other` objects.
     * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.
     */
    function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {
      var isPartial = bitmask & COMPARE_PARTIAL_FLAG,
          objProps = getAllKeys(object),
          objLength = objProps.length,
          othProps = getAllKeys(other),
          othLength = othProps.length;

      if (objLength != othLength && !isPartial) {
        return false;
      }
      var index = objLength;
      while (index--) {
        var key = objProps[index];
        if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {
          return false;
        }
      }
      // Check that cyclic values are equal.
      var objStacked = stack.get(object);
      var othStacked = stack.get(other);
      if (objStacked && othStacked) {
        return objStacked == other && othStacked == object;
      }
      var result = true;
      stack.set(object, other);
      stack.set(other, object);

      var skipCtor = isPartial;
      while (++index < objLength) {
        key = objProps[index];
        var objValue = object[key],
            othValue = other[key];

        if (customizer) {
          var compared = isPartial
            ? customizer(othValue, objValue, key, other, object, stack)
            : customizer(objValue, othValue, key, object, other, stack);
        }
        // Recursively compare objects (susceptible to call stack limits).
        if (!(compared === undefined
              ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))
              : compared
            )) {
          result = false;
          break;
        }
        skipCtor || (skipCtor = key == 'constructor');
      }
      if (result && !skipCtor) {
        var objCtor = object.constructor,
            othCtor = other.constructor;

        // Non `Object` object instances with different constructors are not equal.
        if (objCtor != othCtor &&
            ('constructor' in object && 'constructor' in other) &&
            !(typeof objCtor == 'function' && objCtor instanceof objCtor &&
              typeof othCtor == 'function' && othCtor instanceof othCtor)) {
          result = false;
        }
      }
      stack['delete'](object);
      stack['delete'](other);
      return result;
    }

    /**
     * A specialized version of `baseRest` which flattens the rest array.
     *
     * @private
     * @param {Function} func The function to apply a rest parameter to.
     * @returns {Function} Returns the new function.
     */
    function flatRest(func) {
      return setToString(overRest(func, undefined, flatten), func + '');
    }

    /**
     * Creates an array of own enumerable property names and symbols of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names and symbols.
     */
    function getAllKeys(object) {
      return baseGetAllKeys(object, keys, getSymbols);
    }

    /**
     * Creates an array of own and inherited enumerable property names and
     * symbols of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names and symbols.
     */
    function getAllKeysIn(object) {
      return baseGetAllKeys(object, keysIn, getSymbolsIn);
    }

    /**
     * Gets metadata for `func`.
     *
     * @private
     * @param {Function} func The function to query.
     * @returns {*} Returns the metadata for `func`.
     */
    var getData = !metaMap ? noop : function(func) {
      return metaMap.get(func);
    };

    /**
     * Gets the name of `func`.
     *
     * @private
     * @param {Function} func The function to query.
     * @returns {string} Returns the function name.
     */
    function getFuncName(func) {
      var result = (func.name + ''),
          array = realNames[result],
          length = hasOwnProperty.call(realNames, result) ? array.length : 0;

      while (length--) {
        var data = array[length],
            otherFunc = data.func;
        if (otherFunc == null || otherFunc == func) {
          return data.name;
        }
      }
      return result;
    }

    /**
     * Gets the argument placeholder value for `func`.
     *
     * @private
     * @param {Function} func The function to inspect.
     * @returns {*} Returns the placeholder value.
     */
    function getHolder(func) {
      var object = hasOwnProperty.call(lodash, 'placeholder') ? lodash : func;
      return object.placeholder;
    }

    /**
     * Gets the appropriate "iteratee" function. If `_.iteratee` is customized,
     * this function returns the custom method, otherwise it returns `baseIteratee`.
     * If arguments are provided, the chosen function is invoked with them and
     * its result is returned.
     *
     * @private
     * @param {*} [value] The value to convert to an iteratee.
     * @param {number} [arity] The arity of the created iteratee.
     * @returns {Function} Returns the chosen function or its result.
     */
    function getIteratee() {
      var result = lodash.iteratee || iteratee;
      result = result === iteratee ? baseIteratee : result;
      return arguments.length ? result(arguments[0], arguments[1]) : result;
    }

    /**
     * Gets the data for `map`.
     *
     * @private
     * @param {Object} map The map to query.
     * @param {string} key The reference key.
     * @returns {*} Returns the map data.
     */
    function getMapData(map, key) {
      var data = map.__data__;
      return isKeyable(key)
        ? data[typeof key == 'string' ? 'string' : 'hash']
        : data.map;
    }

    /**
     * Gets the property names, values, and compare flags of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the match data of `object`.
     */
    function getMatchData(object) {
      var result = keys(object),
          length = result.length;

      while (length--) {
        var key = result[length],
            value = object[key];

        result[length] = [key, value, isStrictComparable(value)];
      }
      return result;
    }

    /**
     * Gets the native function at `key` of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @param {string} key The key of the method to get.
     * @returns {*} Returns the function if it's native, else `undefined`.
     */
    function getNative(object, key) {
      var value = getValue(object, key);
      return baseIsNative(value) ? value : undefined;
    }

    /**
     * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
     *
     * @private
     * @param {*} value The value to query.
     * @returns {string} Returns the raw `toStringTag`.
     */
    function getRawTag(value) {
      var isOwn = hasOwnProperty.call(value, symToStringTag),
          tag = value[symToStringTag];

      try {
        value[symToStringTag] = undefined;
        var unmasked = true;
      } catch (e) {}

      var result = nativeObjectToString.call(value);
      if (unmasked) {
        if (isOwn) {
          value[symToStringTag] = tag;
        } else {
          delete value[symToStringTag];
        }
      }
      return result;
    }

    /**
     * Creates an array of the own enumerable symbols of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of symbols.
     */
    var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
      if (object == null) {
        return [];
      }
      object = Object(object);
      return arrayFilter(nativeGetSymbols(object), function(symbol) {
        return propertyIsEnumerable.call(object, symbol);
      });
    };

    /**
     * Creates an array of the own and inherited enumerable symbols of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of symbols.
     */
    var getSymbolsIn = !nativeGetSymbols ? stubArray : function(object) {
      var result = [];
      while (object) {
        arrayPush(result, getSymbols(object));
        object = getPrototype(object);
      }
      return result;
    };

    /**
     * Gets the `toStringTag` of `value`.
     *
     * @private
     * @param {*} value The value to query.
     * @returns {string} Returns the `toStringTag`.
     */
    var getTag = baseGetTag;

    // Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
    if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||
        (Map && getTag(new Map) != mapTag) ||
        (Promise && getTag(Promise.resolve()) != promiseTag) ||
        (Set && getTag(new Set) != setTag) ||
        (WeakMap && getTag(new WeakMap) != weakMapTag)) {
      getTag = function(value) {
        var result = baseGetTag(value),
            Ctor = result == objectTag ? value.constructor : undefined,
            ctorString = Ctor ? toSource(Ctor) : '';

        if (ctorString) {
          switch (ctorString) {
            case dataViewCtorString: return dataViewTag;
            case mapCtorString: return mapTag;
            case promiseCtorString: return promiseTag;
            case setCtorString: return setTag;
            case weakMapCtorString: return weakMapTag;
          }
        }
        return result;
      };
    }

    /**
     * Gets the view, applying any `transforms` to the `start` and `end` positions.
     *
     * @private
     * @param {number} start The start of the view.
     * @param {number} end The end of the view.
     * @param {Array} transforms The transformations to apply to the view.
     * @returns {Object} Returns an object containing the `start` and `end`
     *  positions of the view.
     */
    function getView(start, end, transforms) {
      var index = -1,
          length = transforms.length;

      while (++index < length) {
        var data = transforms[index],
            size = data.size;

        switch (data.type) {
          case 'drop':      start += size; break;
          case 'dropRight': end -= size; break;
          case 'take':      end = nativeMin(end, start + size); break;
          case 'takeRight': start = nativeMax(start, end - size); break;
        }
      }
      return { 'start': start, 'end': end };
    }

    /**
     * Extracts wrapper details from the `source` body comment.
     *
     * @private
     * @param {string} source The source to inspect.
     * @returns {Array} Returns the wrapper details.
     */
    function getWrapDetails(source) {
      var match = source.match(reWrapDetails);
      return match ? match[1].split(reSplitDetails) : [];
    }

    /**
     * Checks if `path` exists on `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @param {Array|string} path The path to check.
     * @param {Function} hasFunc The function to check properties.
     * @returns {boolean} Returns `true` if `path` exists, else `false`.
     */
    function hasPath(object, path, hasFunc) {
      path = castPath(path, object);

      var index = -1,
          length = path.length,
          result = false;

      while (++index < length) {
        var key = toKey(path[index]);
        if (!(result = object != null && hasFunc(object, key))) {
          break;
        }
        object = object[key];
      }
      if (result || ++index != length) {
        return result;
      }
      length = object == null ? 0 : object.length;
      return !!length && isLength(length) && isIndex(key, length) &&
        (isArray(object) || isArguments(object));
    }

    /**
     * Initializes an array clone.
     *
     * @private
     * @param {Array} array The array to clone.
     * @returns {Array} Returns the initialized clone.
     */
    function initCloneArray(array) {
      var length = array.length,
          result = new array.constructor(length);

      // Add properties assigned by `RegExp#exec`.
      if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {
        result.index = array.index;
        result.input = array.input;
      }
      return result;
    }

    /**
     * Initializes an object clone.
     *
     * @private
     * @param {Object} object The object to clone.
     * @returns {Object} Returns the initialized clone.
     */
    function initCloneObject(object) {
      return (typeof object.constructor == 'function' && !isPrototype(object))
        ? baseCreate(getPrototype(object))
        : {};
    }

    /**
     * Initializes an object clone based on its `toStringTag`.
     *
     * **Note:** This function only supports cloning values with tags of
     * `Boolean`, `Date`, `Error`, `Map`, `Number`, `RegExp`, `Set`, or `String`.
     *
     * @private
     * @param {Object} object The object to clone.
     * @param {string} tag The `toStringTag` of the object to clone.
     * @param {boolean} [isDeep] Specify a deep clone.
     * @returns {Object} Returns the initialized clone.
     */
    function initCloneByTag(object, tag, isDeep) {
      var Ctor = object.constructor;
      switch (tag) {
        case arrayBufferTag:
          return cloneArrayBuffer(object);

        case boolTag:
        case dateTag:
          return new Ctor(+object);

        case dataViewTag:
          return cloneDataView(object, isDeep);

        case float32Tag: case float64Tag:
        case int8Tag: case int16Tag: case int32Tag:
        case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag:
          return cloneTypedArray(object, isDeep);

        case mapTag:
          return new Ctor;

        case numberTag:
        case stringTag:
          return new Ctor(object);

        case regexpTag:
          return cloneRegExp(object);

        case setTag:
          return new Ctor;

        case symbolTag:
          return cloneSymbol(object);
      }
    }

    /**
     * Inserts wrapper `details` in a comment at the top of the `source` body.
     *
     * @private
     * @param {string} source The source to modify.
     * @returns {Array} details The details to insert.
     * @returns {string} Returns the modified source.
     */
    function insertWrapDetails(source, details) {
      var length = details.length;
      if (!length) {
        return source;
      }
      var lastIndex = length - 1;
      details[lastIndex] = (length > 1 ? '& ' : '') + details[lastIndex];
      details = details.join(length > 2 ? ', ' : ' ');
      return source.replace(reWrapComment, '{\n/* [wrapped with ' + details + '] */\n');
    }

    /**
     * Checks if `value` is a flattenable `arguments` object or array.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.
     */
    function isFlattenable(value) {
      return isArray(value) || isArguments(value) ||
        !!(spreadableSymbol && value && value[spreadableSymbol]);
    }

    /**
     * Checks if `value` is a valid array-like index.
     *
     * @private
     * @param {*} value The value to check.
     * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.
     * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.
     */
    function isIndex(value, length) {
      var type = typeof value;
      length = length == null ? MAX_SAFE_INTEGER : length;

      return !!length &&
        (type == 'number' ||
          (type != 'symbol' && reIsUint.test(value))) &&
            (value > -1 && value % 1 == 0 && value < length);
    }

    /**
     * Checks if the given arguments are from an iteratee call.
     *
     * @private
     * @param {*} value The potential iteratee value argument.
     * @param {*} index The potential iteratee index or key argument.
     * @param {*} object The potential iteratee object argument.
     * @returns {boolean} Returns `true` if the arguments are from an iteratee call,
     *  else `false`.
     */
    function isIterateeCall(value, index, object) {
      if (!isObject(object)) {
        return false;
      }
      var type = typeof index;
      if (type == 'number'
            ? (isArrayLike(object) && isIndex(index, object.length))
            : (type == 'string' && index in object)
          ) {
        return eq(object[index], value);
      }
      return false;
    }

    /**
     * Checks if `value` is a property name and not a property path.
     *
     * @private
     * @param {*} value The value to check.
     * @param {Object} [object] The object to query keys on.
     * @returns {boolean} Returns `true` if `value` is a property name, else `false`.
     */
    function isKey(value, object) {
      if (isArray(value)) {
        return false;
      }
      var type = typeof value;
      if (type == 'number' || type == 'symbol' || type == 'boolean' ||
          value == null || isSymbol(value)) {
        return true;
      }
      return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||
        (object != null && value in Object(object));
    }

    /**
     * Checks if `value` is suitable for use as unique object key.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is suitable, else `false`.
     */
    function isKeyable(value) {
      var type = typeof value;
      return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')
        ? (value !== '__proto__')
        : (value === null);
    }

    /**
     * Checks if `func` has a lazy counterpart.
     *
     * @private
     * @param {Function} func The function to check.
     * @returns {boolean} Returns `true` if `func` has a lazy counterpart,
     *  else `false`.
     */
    function isLaziable(func) {
      var funcName = getFuncName(func),
          other = lodash[funcName];

      if (typeof other != 'function' || !(funcName in LazyWrapper.prototype)) {
        return false;
      }
      if (func === other) {
        return true;
      }
      var data = getData(other);
      return !!data && func === data[0];
    }

    /**
     * Checks if `func` has its source masked.
     *
     * @private
     * @param {Function} func The function to check.
     * @returns {boolean} Returns `true` if `func` is masked, else `false`.
     */
    function isMasked(func) {
      return !!maskSrcKey && (maskSrcKey in func);
    }

    /**
     * Checks if `func` is capable of being masked.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `func` is maskable, else `false`.
     */
    var isMaskable = coreJsData ? isFunction : stubFalse;

    /**
     * Checks if `value` is likely a prototype object.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.
     */
    function isPrototype(value) {
      var Ctor = value && value.constructor,
          proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;

      return value === proto;
    }

    /**
     * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.
     *
     * @private
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` if suitable for strict
     *  equality comparisons, else `false`.
     */
    function isStrictComparable(value) {
      return value === value && !isObject(value);
    }

    /**
     * A specialized version of `matchesProperty` for source values suitable
     * for strict equality comparisons, i.e. `===`.
     *
     * @private
     * @param {string} key The key of the property to get.
     * @param {*} srcValue The value to match.
     * @returns {Function} Returns the new spec function.
     */
    function matchesStrictComparable(key, srcValue) {
      return function(object) {
        if (object == null) {
          return false;
        }
        return object[key] === srcValue &&
          (srcValue !== undefined || (key in Object(object)));
      };
    }

    /**
     * A specialized version of `_.memoize` which clears the memoized function's
     * cache when it exceeds `MAX_MEMOIZE_SIZE`.
     *
     * @private
     * @param {Function} func The function to have its output memoized.
     * @returns {Function} Returns the new memoized function.
     */
    function memoizeCapped(func) {
      var result = memoize(func, function(key) {
        if (cache.size === MAX_MEMOIZE_SIZE) {
          cache.clear();
        }
        return key;
      });

      var cache = result.cache;
      return result;
    }

    /**
     * Merges the function metadata of `source` into `data`.
     *
     * Merging metadata reduces the number of wrappers used to invoke a function.
     * This is possible because methods like `_.bind`, `_.curry`, and `_.partial`
     * may be applied regardless of execution order. Methods like `_.ary` and
     * `_.rearg` modify function arguments, making the order in which they are
     * executed important, preventing the merging of metadata. However, we make
     * an exception for a safe combined case where curried functions have `_.ary`
     * and or `_.rearg` applied.
     *
     * @private
     * @param {Array} data The destination metadata.
     * @param {Array} source The source metadata.
     * @returns {Array} Returns `data`.
     */
    function mergeData(data, source) {
      var bitmask = data[1],
          srcBitmask = source[1],
          newBitmask = bitmask | srcBitmask,
          isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG);

      var isCombo =
        ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_CURRY_FLAG)) ||
        ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_REARG_FLAG) && (data[7].length <= source[8])) ||
        ((srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG)) && (source[7].length <= source[8]) && (bitmask == WRAP_CURRY_FLAG));

      // Exit early if metadata can't be merged.
      if (!(isCommon || isCombo)) {
        return data;
      }
      // Use source `thisArg` if available.
      if (srcBitmask & WRAP_BIND_FLAG) {
        data[2] = source[2];
        // Set when currying a bound function.
        newBitmask |= bitmask & WRAP_BIND_FLAG ? 0 : WRAP_CURRY_BOUND_FLAG;
      }
      // Compose partial arguments.
      var value = source[3];
      if (value) {
        var partials = data[3];
        data[3] = partials ? composeArgs(partials, value, source[4]) : value;
        data[4] = partials ? replaceHolders(data[3], PLACEHOLDER) : source[4];
      }
      // Compose partial right arguments.
      value = source[5];
      if (value) {
        partials = data[5];
        data[5] = partials ? composeArgsRight(partials, value, source[6]) : value;
        data[6] = partials ? replaceHolders(data[5], PLACEHOLDER) : source[6];
      }
      // Use source `argPos` if available.
      value = source[7];
      if (value) {
        data[7] = value;
      }
      // Use source `ary` if it's smaller.
      if (srcBitmask & WRAP_ARY_FLAG) {
        data[8] = data[8] == null ? source[8] : nativeMin(data[8], source[8]);
      }
      // Use source `arity` if one is not provided.
      if (data[9] == null) {
        data[9] = source[9];
      }
      // Use source `func` and merge bitmasks.
      data[0] = source[0];
      data[1] = newBitmask;

      return data;
    }

    /**
     * This function is like
     * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)
     * except that it includes inherited enumerable properties.
     *
     * @private
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names.
     */
    function nativeKeysIn(object) {
      var result = [];
      if (object != null) {
        for (var key in Object(object)) {
          result.push(key);
        }
      }
      return result;
    }

    /**
     * Converts `value` to a string using `Object.prototype.toString`.
     *
     * @private
     * @param {*} value The value to convert.
     * @returns {string} Returns the converted string.
     */
    function objectToString(value) {
      return nativeObjectToString.call(value);
    }

    /**
     * A specialized version of `baseRest` which transforms the rest array.
     *
     * @private
     * @param {Function} func The function to apply a rest parameter to.
     * @param {number} [start=func.length-1] The start position of the rest parameter.
     * @param {Function} transform The rest array transform.
     * @returns {Function} Returns the new function.
     */
    function overRest(func, start, transform) {
      start = nativeMax(start === undefined ? (func.length - 1) : start, 0);
      return function() {
        var args = arguments,
            index = -1,
            length = nativeMax(args.length - start, 0),
            array = Array(length);

        while (++index < length) {
          array[index] = args[start + index];
        }
        index = -1;
        var otherArgs = Array(start + 1);
        while (++index < start) {
          otherArgs[index] = args[index];
        }
        otherArgs[start] = transform(array);
        return apply(func, this, otherArgs);
      };
    }

    /**
     * Gets the parent value at `path` of `object`.
     *
     * @private
     * @param {Object} object The object to query.
     * @param {Array} path The path to get the parent value of.
     * @returns {*} Returns the parent value.
     */
    function parent(object, path) {
      return path.length < 2 ? object : baseGet(object, baseSlice(path, 0, -1));
    }

    /**
     * Reorder `array` according to the specified indexes where the element at
     * the first index is assigned as the first element, the element at
     * the second index is assigned as the second element, and so on.
     *
     * @private
     * @param {Array} array The array to reorder.
     * @param {Array} indexes The arranged array indexes.
     * @returns {Array} Returns `array`.
     */
    function reorder(array, indexes) {
      var arrLength = array.length,
          length = nativeMin(indexes.length, arrLength),
          oldArray = copyArray(array);

      while (length--) {
        var index = indexes[length];
        array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined;
      }
      return array;
    }

    /**
     * Gets the value at `key`, unless `key` is "__proto__" or "constructor".
     *
     * @private
     * @param {Object} object The object to query.
     * @param {string} key The key of the property to get.
     * @returns {*} Returns the property value.
     */
    function safeGet(object, key) {
      if (key === 'constructor' && typeof object[key] === 'function') {
        return;
      }

      if (key == '__proto__') {
        return;
      }

      return object[key];
    }

    /**
     * Sets metadata for `func`.
     *
     * **Note:** If this function becomes hot, i.e. is invoked a lot in a short
     * period of time, it will trip its breaker and transition to an identity
     * function to avoid garbage collection pauses in V8. See
     * [V8 issue 2070](https://bugs.chromium.org/p/v8/issues/detail?id=2070)
     * for more details.
     *
     * @private
     * @param {Function} func The function to associate metadata with.
     * @param {*} data The metadata.
     * @returns {Function} Returns `func`.
     */
    var setData = shortOut(baseSetData);

    /**
     * A simple wrapper around the global [`setTimeout`](https://mdn.io/setTimeout).
     *
     * @private
     * @param {Function} func The function to delay.
     * @param {number} wait The number of milliseconds to delay invocation.
     * @returns {number|Object} Returns the timer id or timeout object.
     */
    var setTimeout = ctxSetTimeout || function(func, wait) {
      return root.setTimeout(func, wait);
    };

    /**
     * Sets the `toString` method of `func` to return `string`.
     *
     * @private
     * @param {Function} func The function to modify.
     * @param {Function} string The `toString` result.
     * @returns {Function} Returns `func`.
     */
    var setToString = shortOut(baseSetToString);

    /**
     * Sets the `toString` method of `wrapper` to mimic the source of `reference`
     * with wrapper details in a comment at the top of the source body.
     *
     * @private
     * @param {Function} wrapper The function to modify.
     * @param {Function} reference The reference function.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @returns {Function} Returns `wrapper`.
     */
    function setWrapToString(wrapper, reference, bitmask) {
      var source = (reference + '');
      return setToString(wrapper, insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask)));
    }

    /**
     * Creates a function that'll short out and invoke `identity` instead
     * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`
     * milliseconds.
     *
     * @private
     * @param {Function} func The function to restrict.
     * @returns {Function} Returns the new shortable function.
     */
    function shortOut(func) {
      var count = 0,
          lastCalled = 0;

      return function() {
        var stamp = nativeNow(),
            remaining = HOT_SPAN - (stamp - lastCalled);

        lastCalled = stamp;
        if (remaining > 0) {
          if (++count >= HOT_COUNT) {
            return arguments[0];
          }
        } else {
          count = 0;
        }
        return func.apply(undefined, arguments);
      };
    }

    /**
     * A specialized version of `_.shuffle` which mutates and sets the size of `array`.
     *
     * @private
     * @param {Array} array The array to shuffle.
     * @param {number} [size=array.length] The size of `array`.
     * @returns {Array} Returns `array`.
     */
    function shuffleSelf(array, size) {
      var index = -1,
          length = array.length,
          lastIndex = length - 1;

      size = size === undefined ? length : size;
      while (++index < size) {
        var rand = baseRandom(index, lastIndex),
            value = array[rand];

        array[rand] = array[index];
        array[index] = value;
      }
      array.length = size;
      return array;
    }

    /**
     * Converts `string` to a property path array.
     *
     * @private
     * @param {string} string The string to convert.
     * @returns {Array} Returns the property path array.
     */
    var stringToPath = memoizeCapped(function(string) {
      var result = [];
      if (string.charCodeAt(0) === 46 /* . */) {
        result.push('');
      }
      string.replace(rePropName, function(match, number, quote, subString) {
        result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));
      });
      return result;
    });

    /**
     * Converts `value` to a string key if it's not a string or symbol.
     *
     * @private
     * @param {*} value The value to inspect.
     * @returns {string|symbol} Returns the key.
     */
    function toKey(value) {
      if (typeof value == 'string' || isSymbol(value)) {
        return value;
      }
      var result = (value + '');
      return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
    }

    /**
     * Converts `func` to its source code.
     *
     * @private
     * @param {Function} func The function to convert.
     * @returns {string} Returns the source code.
     */
    function toSource(func) {
      if (func != null) {
        try {
          return funcToString.call(func);
        } catch (e) {}
        try {
          return (func + '');
        } catch (e) {}
      }
      return '';
    }

    /**
     * Updates wrapper `details` based on `bitmask` flags.
     *
     * @private
     * @returns {Array} details The details to modify.
     * @param {number} bitmask The bitmask flags. See `createWrap` for more details.
     * @returns {Array} Returns `details`.
     */
    function updateWrapDetails(details, bitmask) {
      arrayEach(wrapFlags, function(pair) {
        var value = '_.' + pair[0];
        if ((bitmask & pair[1]) && !arrayIncludes(details, value)) {
          details.push(value);
        }
      });
      return details.sort();
    }

    /**
     * Creates a clone of `wrapper`.
     *
     * @private
     * @param {Object} wrapper The wrapper to clone.
     * @returns {Object} Returns the cloned wrapper.
     */
    function wrapperClone(wrapper) {
      if (wrapper instanceof LazyWrapper) {
        return wrapper.clone();
      }
      var result = new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__);
      result.__actions__ = copyArray(wrapper.__actions__);
      result.__index__  = wrapper.__index__;
      result.__values__ = wrapper.__values__;
      return result;
    }

    /*------------------------------------------------------------------------*/

    /**
     * Creates an array of elements split into groups the length of `size`.
     * If `array` can't be split evenly, the final chunk will be the remaining
     * elements.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to process.
     * @param {number} [size=1] The length of each chunk
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the new array of chunks.
     * @example
     *
     * _.chunk(['a', 'b', 'c', 'd'], 2);
     * // => [['a', 'b'], ['c', 'd']]
     *
     * _.chunk(['a', 'b', 'c', 'd'], 3);
     * // => [['a', 'b', 'c'], ['d']]
     */
    function chunk(array, size, guard) {
      if ((guard ? isIterateeCall(array, size, guard) : size === undefined)) {
        size = 1;
      } else {
        size = nativeMax(toInteger(size), 0);
      }
      var length = array == null ? 0 : array.length;
      if (!length || size < 1) {
        return [];
      }
      var index = 0,
          resIndex = 0,
          result = Array(nativeCeil(length / size));

      while (index < length) {
        result[resIndex++] = baseSlice(array, index, (index += size));
      }
      return result;
    }

    /**
     * Creates an array with all falsey values removed. The values `false`, `null`,
     * `0`, `""`, `undefined`, and `NaN` are falsey.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to compact.
     * @returns {Array} Returns the new array of filtered values.
     * @example
     *
     * _.compact([0, 1, false, 2, '', 3]);
     * // => [1, 2, 3]
     */
    function compact(array) {
      var index = -1,
          length = array == null ? 0 : array.length,
          resIndex = 0,
          result = [];

      while (++index < length) {
        var value = array[index];
        if (value) {
          result[resIndex++] = value;
        }
      }
      return result;
    }

    /**
     * Creates a new array concatenating `array` with any additional arrays
     * and/or values.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to concatenate.
     * @param {...*} [values] The values to concatenate.
     * @returns {Array} Returns the new concatenated array.
     * @example
     *
     * var array = [1];
     * var other = _.concat(array, 2, [3], [[4]]);
     *
     * console.log(other);
     * // => [1, 2, 3, [4]]
     *
     * console.log(array);
     * // => [1]
     */
    function concat() {
      var length = arguments.length;
      if (!length) {
        return [];
      }
      var args = Array(length - 1),
          array = arguments[0],
          index = length;

      while (index--) {
        args[index - 1] = arguments[index];
      }
      return arrayPush(isArray(array) ? copyArray(array) : [array], baseFlatten(args, 1));
    }

    /**
     * Creates an array of `array` values not included in the other given arrays
     * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons. The order and references of result values are
     * determined by the first array.
     *
     * **Note:** Unlike `_.pullAll`, this method returns a new array.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {...Array} [values] The values to exclude.
     * @returns {Array} Returns the new array of filtered values.
     * @see _.without, _.xor
     * @example
     *
     * _.difference([2, 1], [2, 3]);
     * // => [1]
     */
    var difference = baseRest(function(array, values) {
      return isArrayLikeObject(array)
        ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true))
        : [];
    });

    /**
     * This method is like `_.difference` except that it accepts `iteratee` which
     * is invoked for each element of `array` and `values` to generate the criterion
     * by which they're compared. The order and references of result values are
     * determined by the first array. The iteratee is invoked with one argument:
     * (value).
     *
     * **Note:** Unlike `_.pullAllBy`, this method returns a new array.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {...Array} [values] The values to exclude.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Array} Returns the new array of filtered values.
     * @example
     *
     * _.differenceBy([2.1, 1.2], [2.3, 3.4], Math.floor);
     * // => [1.2]
     *
     * // The `_.property` iteratee shorthand.
     * _.differenceBy([{ 'x': 2 }, { 'x': 1 }], [{ 'x': 1 }], 'x');
     * // => [{ 'x': 2 }]
     */
    var differenceBy = baseRest(function(array, values) {
      var iteratee = last(values);
      if (isArrayLikeObject(iteratee)) {
        iteratee = undefined;
      }
      return isArrayLikeObject(array)
        ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true), getIteratee(iteratee, 2))
        : [];
    });

    /**
     * This method is like `_.difference` except that it accepts `comparator`
     * which is invoked to compare elements of `array` to `values`. The order and
     * references of result values are determined by the first array. The comparator
     * is invoked with two arguments: (arrVal, othVal).
     *
     * **Note:** Unlike `_.pullAllWith`, this method returns a new array.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {...Array} [values] The values to exclude.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of filtered values.
     * @example
     *
     * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];
     *
     * _.differenceWith(objects, [{ 'x': 1, 'y': 2 }], _.isEqual);
     * // => [{ 'x': 2, 'y': 1 }]
     */
    var differenceWith = baseRest(function(array, values) {
      var comparator = last(values);
      if (isArrayLikeObject(comparator)) {
        comparator = undefined;
      }
      return isArrayLikeObject(array)
        ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true), undefined, comparator)
        : [];
    });

    /**
     * Creates a slice of `array` with `n` elements dropped from the beginning.
     *
     * @static
     * @memberOf _
     * @since 0.5.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {number} [n=1] The number of elements to drop.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * _.drop([1, 2, 3]);
     * // => [2, 3]
     *
     * _.drop([1, 2, 3], 2);
     * // => [3]
     *
     * _.drop([1, 2, 3], 5);
     * // => []
     *
     * _.drop([1, 2, 3], 0);
     * // => [1, 2, 3]
     */
    function drop(array, n, guard) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return [];
      }
      n = (guard || n === undefined) ? 1 : toInteger(n);
      return baseSlice(array, n < 0 ? 0 : n, length);
    }

    /**
     * Creates a slice of `array` with `n` elements dropped from the end.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {number} [n=1] The number of elements to drop.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * _.dropRight([1, 2, 3]);
     * // => [1, 2]
     *
     * _.dropRight([1, 2, 3], 2);
     * // => [1]
     *
     * _.dropRight([1, 2, 3], 5);
     * // => []
     *
     * _.dropRight([1, 2, 3], 0);
     * // => [1, 2, 3]
     */
    function dropRight(array, n, guard) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return [];
      }
      n = (guard || n === undefined) ? 1 : toInteger(n);
      n = length - n;
      return baseSlice(array, 0, n < 0 ? 0 : n);
    }

    /**
     * Creates a slice of `array` excluding elements dropped from the end.
     * Elements are dropped until `predicate` returns falsey. The predicate is
     * invoked with three arguments: (value, index, array).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'active': true },
     *   { 'user': 'fred',    'active': false },
     *   { 'user': 'pebbles', 'active': false }
     * ];
     *
     * _.dropRightWhile(users, function(o) { return !o.active; });
     * // => objects for ['barney']
     *
     * // The `_.matches` iteratee shorthand.
     * _.dropRightWhile(users, { 'user': 'pebbles', 'active': false });
     * // => objects for ['barney', 'fred']
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.dropRightWhile(users, ['active', false]);
     * // => objects for ['barney']
     *
     * // The `_.property` iteratee shorthand.
     * _.dropRightWhile(users, 'active');
     * // => objects for ['barney', 'fred', 'pebbles']
     */
    function dropRightWhile(array, predicate) {
      return (array && array.length)
        ? baseWhile(array, getIteratee(predicate, 3), true, true)
        : [];
    }

    /**
     * Creates a slice of `array` excluding elements dropped from the beginning.
     * Elements are dropped until `predicate` returns falsey. The predicate is
     * invoked with three arguments: (value, index, array).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'active': false },
     *   { 'user': 'fred',    'active': false },
     *   { 'user': 'pebbles', 'active': true }
     * ];
     *
     * _.dropWhile(users, function(o) { return !o.active; });
     * // => objects for ['pebbles']
     *
     * // The `_.matches` iteratee shorthand.
     * _.dropWhile(users, { 'user': 'barney', 'active': false });
     * // => objects for ['fred', 'pebbles']
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.dropWhile(users, ['active', false]);
     * // => objects for ['pebbles']
     *
     * // The `_.property` iteratee shorthand.
     * _.dropWhile(users, 'active');
     * // => objects for ['barney', 'fred', 'pebbles']
     */
    function dropWhile(array, predicate) {
      return (array && array.length)
        ? baseWhile(array, getIteratee(predicate, 3), true)
        : [];
    }

    /**
     * Fills elements of `array` with `value` from `start` up to, but not
     * including, `end`.
     *
     * **Note:** This method mutates `array`.
     *
     * @static
     * @memberOf _
     * @since 3.2.0
     * @category Array
     * @param {Array} array The array to fill.
     * @param {*} value The value to fill `array` with.
     * @param {number} [start=0] The start position.
     * @param {number} [end=array.length] The end position.
     * @returns {Array} Returns `array`.
     * @example
     *
     * var array = [1, 2, 3];
     *
     * _.fill(array, 'a');
     * console.log(array);
     * // => ['a', 'a', 'a']
     *
     * _.fill(Array(3), 2);
     * // => [2, 2, 2]
     *
     * _.fill([4, 6, 8, 10], '*', 1, 3);
     * // => [4, '*', '*', 10]
     */
    function fill(array, value, start, end) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return [];
      }
      if (start && typeof start != 'number' && isIterateeCall(array, value, start)) {
        start = 0;
        end = length;
      }
      return baseFill(array, value, start, end);
    }

    /**
     * This method is like `_.find` except that it returns the index of the first
     * element `predicate` returns truthy for instead of the element itself.
     *
     * @static
     * @memberOf _
     * @since 1.1.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @param {number} [fromIndex=0] The index to search from.
     * @returns {number} Returns the index of the found element, else `-1`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'active': false },
     *   { 'user': 'fred',    'active': false },
     *   { 'user': 'pebbles', 'active': true }
     * ];
     *
     * _.findIndex(users, function(o) { return o.user == 'barney'; });
     * // => 0
     *
     * // The `_.matches` iteratee shorthand.
     * _.findIndex(users, { 'user': 'fred', 'active': false });
     * // => 1
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.findIndex(users, ['active', false]);
     * // => 0
     *
     * // The `_.property` iteratee shorthand.
     * _.findIndex(users, 'active');
     * // => 2
     */
    function findIndex(array, predicate, fromIndex) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return -1;
      }
      var index = fromIndex == null ? 0 : toInteger(fromIndex);
      if (index < 0) {
        index = nativeMax(length + index, 0);
      }
      return baseFindIndex(array, getIteratee(predicate, 3), index);
    }

    /**
     * This method is like `_.findIndex` except that it iterates over elements
     * of `collection` from right to left.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @param {number} [fromIndex=array.length-1] The index to search from.
     * @returns {number} Returns the index of the found element, else `-1`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'active': true },
     *   { 'user': 'fred',    'active': false },
     *   { 'user': 'pebbles', 'active': false }
     * ];
     *
     * _.findLastIndex(users, function(o) { return o.user == 'pebbles'; });
     * // => 2
     *
     * // The `_.matches` iteratee shorthand.
     * _.findLastIndex(users, { 'user': 'barney', 'active': true });
     * // => 0
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.findLastIndex(users, ['active', false]);
     * // => 2
     *
     * // The `_.property` iteratee shorthand.
     * _.findLastIndex(users, 'active');
     * // => 0
     */
    function findLastIndex(array, predicate, fromIndex) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return -1;
      }
      var index = length - 1;
      if (fromIndex !== undefined) {
        index = toInteger(fromIndex);
        index = fromIndex < 0
          ? nativeMax(length + index, 0)
          : nativeMin(index, length - 1);
      }
      return baseFindIndex(array, getIteratee(predicate, 3), index, true);
    }

    /**
     * Flattens `array` a single level deep.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to flatten.
     * @returns {Array} Returns the new flattened array.
     * @example
     *
     * _.flatten([1, [2, [3, [4]], 5]]);
     * // => [1, 2, [3, [4]], 5]
     */
    function flatten(array) {
      var length = array == null ? 0 : array.length;
      return length ? baseFlatten(array, 1) : [];
    }

    /**
     * Recursively flattens `array`.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to flatten.
     * @returns {Array} Returns the new flattened array.
     * @example
     *
     * _.flattenDeep([1, [2, [3, [4]], 5]]);
     * // => [1, 2, 3, 4, 5]
     */
    function flattenDeep(array) {
      var length = array == null ? 0 : array.length;
      return length ? baseFlatten(array, INFINITY) : [];
    }

    /**
     * Recursively flatten `array` up to `depth` times.
     *
     * @static
     * @memberOf _
     * @since 4.4.0
     * @category Array
     * @param {Array} array The array to flatten.
     * @param {number} [depth=1] The maximum recursion depth.
     * @returns {Array} Returns the new flattened array.
     * @example
     *
     * var array = [1, [2, [3, [4]], 5]];
     *
     * _.flattenDepth(array, 1);
     * // => [1, 2, [3, [4]], 5]
     *
     * _.flattenDepth(array, 2);
     * // => [1, 2, 3, [4], 5]
     */
    function flattenDepth(array, depth) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return [];
      }
      depth = depth === undefined ? 1 : toInteger(depth);
      return baseFlatten(array, depth);
    }

    /**
     * The inverse of `_.toPairs`; this method returns an object composed
     * from key-value `pairs`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} pairs The key-value pairs.
     * @returns {Object} Returns the new object.
     * @example
     *
     * _.fromPairs([['a', 1], ['b', 2]]);
     * // => { 'a': 1, 'b': 2 }
     */
    function fromPairs(pairs) {
      var index = -1,
          length = pairs == null ? 0 : pairs.length,
          result = {};

      while (++index < length) {
        var pair = pairs[index];
        result[pair[0]] = pair[1];
      }
      return result;
    }

    /**
     * Gets the first element of `array`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @alias first
     * @category Array
     * @param {Array} array The array to query.
     * @returns {*} Returns the first element of `array`.
     * @example
     *
     * _.head([1, 2, 3]);
     * // => 1
     *
     * _.head([]);
     * // => undefined
     */
    function head(array) {
      return (array && array.length) ? array[0] : undefined;
    }

    /**
     * Gets the index at which the first occurrence of `value` is found in `array`
     * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons. If `fromIndex` is negative, it's used as the
     * offset from the end of `array`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {*} value The value to search for.
     * @param {number} [fromIndex=0] The index to search from.
     * @returns {number} Returns the index of the matched value, else `-1`.
     * @example
     *
     * _.indexOf([1, 2, 1, 2], 2);
     * // => 1
     *
     * // Search from the `fromIndex`.
     * _.indexOf([1, 2, 1, 2], 2, 2);
     * // => 3
     */
    function indexOf(array, value, fromIndex) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return -1;
      }
      var index = fromIndex == null ? 0 : toInteger(fromIndex);
      if (index < 0) {
        index = nativeMax(length + index, 0);
      }
      return baseIndexOf(array, value, index);
    }

    /**
     * Gets all but the last element of `array`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to query.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * _.initial([1, 2, 3]);
     * // => [1, 2]
     */
    function initial(array) {
      var length = array == null ? 0 : array.length;
      return length ? baseSlice(array, 0, -1) : [];
    }

    /**
     * Creates an array of unique values that are included in all given arrays
     * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons. The order and references of result values are
     * determined by the first array.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @returns {Array} Returns the new array of intersecting values.
     * @example
     *
     * _.intersection([2, 1], [2, 3]);
     * // => [2]
     */
    var intersection = baseRest(function(arrays) {
      var mapped = arrayMap(arrays, castArrayLikeObject);
      return (mapped.length && mapped[0] === arrays[0])
        ? baseIntersection(mapped)
        : [];
    });

    /**
     * This method is like `_.intersection` except that it accepts `iteratee`
     * which is invoked for each element of each `arrays` to generate the criterion
     * by which they're compared. The order and references of result values are
     * determined by the first array. The iteratee is invoked with one argument:
     * (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Array} Returns the new array of intersecting values.
     * @example
     *
     * _.intersectionBy([2.1, 1.2], [2.3, 3.4], Math.floor);
     * // => [2.1]
     *
     * // The `_.property` iteratee shorthand.
     * _.intersectionBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x');
     * // => [{ 'x': 1 }]
     */
    var intersectionBy = baseRest(function(arrays) {
      var iteratee = last(arrays),
          mapped = arrayMap(arrays, castArrayLikeObject);

      if (iteratee === last(mapped)) {
        iteratee = undefined;
      } else {
        mapped.pop();
      }
      return (mapped.length && mapped[0] === arrays[0])
        ? baseIntersection(mapped, getIteratee(iteratee, 2))
        : [];
    });

    /**
     * This method is like `_.intersection` except that it accepts `comparator`
     * which is invoked to compare elements of `arrays`. The order and references
     * of result values are determined by the first array. The comparator is
     * invoked with two arguments: (arrVal, othVal).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of intersecting values.
     * @example
     *
     * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];
     * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }];
     *
     * _.intersectionWith(objects, others, _.isEqual);
     * // => [{ 'x': 1, 'y': 2 }]
     */
    var intersectionWith = baseRest(function(arrays) {
      var comparator = last(arrays),
          mapped = arrayMap(arrays, castArrayLikeObject);

      comparator = typeof comparator == 'function' ? comparator : undefined;
      if (comparator) {
        mapped.pop();
      }
      return (mapped.length && mapped[0] === arrays[0])
        ? baseIntersection(mapped, undefined, comparator)
        : [];
    });

    /**
     * Converts all elements in `array` into a string separated by `separator`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to convert.
     * @param {string} [separator=','] The element separator.
     * @returns {string} Returns the joined string.
     * @example
     *
     * _.join(['a', 'b', 'c'], '~');
     * // => 'a~b~c'
     */
    function join(array, separator) {
      return array == null ? '' : nativeJoin.call(array, separator);
    }

    /**
     * Gets the last element of `array`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to query.
     * @returns {*} Returns the last element of `array`.
     * @example
     *
     * _.last([1, 2, 3]);
     * // => 3
     */
    function last(array) {
      var length = array == null ? 0 : array.length;
      return length ? array[length - 1] : undefined;
    }

    /**
     * This method is like `_.indexOf` except that it iterates over elements of
     * `array` from right to left.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {*} value The value to search for.
     * @param {number} [fromIndex=array.length-1] The index to search from.
     * @returns {number} Returns the index of the matched value, else `-1`.
     * @example
     *
     * _.lastIndexOf([1, 2, 1, 2], 2);
     * // => 3
     *
     * // Search from the `fromIndex`.
     * _.lastIndexOf([1, 2, 1, 2], 2, 2);
     * // => 1
     */
    function lastIndexOf(array, value, fromIndex) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return -1;
      }
      var index = length;
      if (fromIndex !== undefined) {
        index = toInteger(fromIndex);
        index = index < 0 ? nativeMax(length + index, 0) : nativeMin(index, length - 1);
      }
      return value === value
        ? strictLastIndexOf(array, value, index)
        : baseFindIndex(array, baseIsNaN, index, true);
    }

    /**
     * Gets the element at index `n` of `array`. If `n` is negative, the nth
     * element from the end is returned.
     *
     * @static
     * @memberOf _
     * @since 4.11.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {number} [n=0] The index of the element to return.
     * @returns {*} Returns the nth element of `array`.
     * @example
     *
     * var array = ['a', 'b', 'c', 'd'];
     *
     * _.nth(array, 1);
     * // => 'b'
     *
     * _.nth(array, -2);
     * // => 'c';
     */
    function nth(array, n) {
      return (array && array.length) ? baseNth(array, toInteger(n)) : undefined;
    }

    /**
     * Removes all given values from `array` using
     * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons.
     *
     * **Note:** Unlike `_.without`, this method mutates `array`. Use `_.remove`
     * to remove elements from an array by predicate.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Array
     * @param {Array} array The array to modify.
     * @param {...*} [values] The values to remove.
     * @returns {Array} Returns `array`.
     * @example
     *
     * var array = ['a', 'b', 'c', 'a', 'b', 'c'];
     *
     * _.pull(array, 'a', 'c');
     * console.log(array);
     * // => ['b', 'b']
     */
    var pull = baseRest(pullAll);

    /**
     * This method is like `_.pull` except that it accepts an array of values to remove.
     *
     * **Note:** Unlike `_.difference`, this method mutates `array`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to modify.
     * @param {Array} values The values to remove.
     * @returns {Array} Returns `array`.
     * @example
     *
     * var array = ['a', 'b', 'c', 'a', 'b', 'c'];
     *
     * _.pullAll(array, ['a', 'c']);
     * console.log(array);
     * // => ['b', 'b']
     */
    function pullAll(array, values) {
      return (array && array.length && values && values.length)
        ? basePullAll(array, values)
        : array;
    }

    /**
     * This method is like `_.pullAll` except that it accepts `iteratee` which is
     * invoked for each element of `array` and `values` to generate the criterion
     * by which they're compared. The iteratee is invoked with one argument: (value).
     *
     * **Note:** Unlike `_.differenceBy`, this method mutates `array`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to modify.
     * @param {Array} values The values to remove.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Array} Returns `array`.
     * @example
     *
     * var array = [{ 'x': 1 }, { 'x': 2 }, { 'x': 3 }, { 'x': 1 }];
     *
     * _.pullAllBy(array, [{ 'x': 1 }, { 'x': 3 }], 'x');
     * console.log(array);
     * // => [{ 'x': 2 }]
     */
    function pullAllBy(array, values, iteratee) {
      return (array && array.length && values && values.length)
        ? basePullAll(array, values, getIteratee(iteratee, 2))
        : array;
    }

    /**
     * This method is like `_.pullAll` except that it accepts `comparator` which
     * is invoked to compare elements of `array` to `values`. The comparator is
     * invoked with two arguments: (arrVal, othVal).
     *
     * **Note:** Unlike `_.differenceWith`, this method mutates `array`.
     *
     * @static
     * @memberOf _
     * @since 4.6.0
     * @category Array
     * @param {Array} array The array to modify.
     * @param {Array} values The values to remove.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns `array`.
     * @example
     *
     * var array = [{ 'x': 1, 'y': 2 }, { 'x': 3, 'y': 4 }, { 'x': 5, 'y': 6 }];
     *
     * _.pullAllWith(array, [{ 'x': 3, 'y': 4 }], _.isEqual);
     * console.log(array);
     * // => [{ 'x': 1, 'y': 2 }, { 'x': 5, 'y': 6 }]
     */
    function pullAllWith(array, values, comparator) {
      return (array && array.length && values && values.length)
        ? basePullAll(array, values, undefined, comparator)
        : array;
    }

    /**
     * Removes elements from `array` corresponding to `indexes` and returns an
     * array of removed elements.
     *
     * **Note:** Unlike `_.at`, this method mutates `array`.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to modify.
     * @param {...(number|number[])} [indexes] The indexes of elements to remove.
     * @returns {Array} Returns the new array of removed elements.
     * @example
     *
     * var array = ['a', 'b', 'c', 'd'];
     * var pulled = _.pullAt(array, [1, 3]);
     *
     * console.log(array);
     * // => ['a', 'c']
     *
     * console.log(pulled);
     * // => ['b', 'd']
     */
    var pullAt = flatRest(function(array, indexes) {
      var length = array == null ? 0 : array.length,
          result = baseAt(array, indexes);

      basePullAt(array, arrayMap(indexes, function(index) {
        return isIndex(index, length) ? +index : index;
      }).sort(compareAscending));

      return result;
    });

    /**
     * Removes all elements from `array` that `predicate` returns truthy for
     * and returns an array of the removed elements. The predicate is invoked
     * with three arguments: (value, index, array).
     *
     * **Note:** Unlike `_.filter`, this method mutates `array`. Use `_.pull`
     * to pull elements from an array by value.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Array
     * @param {Array} array The array to modify.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the new array of removed elements.
     * @example
     *
     * var array = [1, 2, 3, 4];
     * var evens = _.remove(array, function(n) {
     *   return n % 2 == 0;
     * });
     *
     * console.log(array);
     * // => [1, 3]
     *
     * console.log(evens);
     * // => [2, 4]
     */
    function remove(array, predicate) {
      var result = [];
      if (!(array && array.length)) {
        return result;
      }
      var index = -1,
          indexes = [],
          length = array.length;

      predicate = getIteratee(predicate, 3);
      while (++index < length) {
        var value = array[index];
        if (predicate(value, index, array)) {
          result.push(value);
          indexes.push(index);
        }
      }
      basePullAt(array, indexes);
      return result;
    }

    /**
     * Reverses `array` so that the first element becomes the last, the second
     * element becomes the second to last, and so on.
     *
     * **Note:** This method mutates `array` and is based on
     * [`Array#reverse`](https://mdn.io/Array/reverse).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to modify.
     * @returns {Array} Returns `array`.
     * @example
     *
     * var array = [1, 2, 3];
     *
     * _.reverse(array);
     * // => [3, 2, 1]
     *
     * console.log(array);
     * // => [3, 2, 1]
     */
    function reverse(array) {
      return array == null ? array : nativeReverse.call(array);
    }

    /**
     * Creates a slice of `array` from `start` up to, but not including, `end`.
     *
     * **Note:** This method is used instead of
     * [`Array#slice`](https://mdn.io/Array/slice) to ensure dense arrays are
     * returned.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to slice.
     * @param {number} [start=0] The start position.
     * @param {number} [end=array.length] The end position.
     * @returns {Array} Returns the slice of `array`.
     */
    function slice(array, start, end) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return [];
      }
      if (end && typeof end != 'number' && isIterateeCall(array, start, end)) {
        start = 0;
        end = length;
      }
      else {
        start = start == null ? 0 : toInteger(start);
        end = end === undefined ? length : toInteger(end);
      }
      return baseSlice(array, start, end);
    }

    /**
     * Uses a binary search to determine the lowest index at which `value`
     * should be inserted into `array` in order to maintain its sort order.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The sorted array to inspect.
     * @param {*} value The value to evaluate.
     * @returns {number} Returns the index at which `value` should be inserted
     *  into `array`.
     * @example
     *
     * _.sortedIndex([30, 50], 40);
     * // => 1
     */
    function sortedIndex(array, value) {
      return baseSortedIndex(array, value);
    }

    /**
     * This method is like `_.sortedIndex` except that it accepts `iteratee`
     * which is invoked for `value` and each element of `array` to compute their
     * sort ranking. The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The sorted array to inspect.
     * @param {*} value The value to evaluate.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {number} Returns the index at which `value` should be inserted
     *  into `array`.
     * @example
     *
     * var objects = [{ 'x': 4 }, { 'x': 5 }];
     *
     * _.sortedIndexBy(objects, { 'x': 4 }, function(o) { return o.x; });
     * // => 0
     *
     * // The `_.property` iteratee shorthand.
     * _.sortedIndexBy(objects, { 'x': 4 }, 'x');
     * // => 0
     */
    function sortedIndexBy(array, value, iteratee) {
      return baseSortedIndexBy(array, value, getIteratee(iteratee, 2));
    }

    /**
     * This method is like `_.indexOf` except that it performs a binary
     * search on a sorted `array`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {*} value The value to search for.
     * @returns {number} Returns the index of the matched value, else `-1`.
     * @example
     *
     * _.sortedIndexOf([4, 5, 5, 5, 6], 5);
     * // => 1
     */
    function sortedIndexOf(array, value) {
      var length = array == null ? 0 : array.length;
      if (length) {
        var index = baseSortedIndex(array, value);
        if (index < length && eq(array[index], value)) {
          return index;
        }
      }
      return -1;
    }

    /**
     * This method is like `_.sortedIndex` except that it returns the highest
     * index at which `value` should be inserted into `array` in order to
     * maintain its sort order.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The sorted array to inspect.
     * @param {*} value The value to evaluate.
     * @returns {number} Returns the index at which `value` should be inserted
     *  into `array`.
     * @example
     *
     * _.sortedLastIndex([4, 5, 5, 5, 6], 5);
     * // => 4
     */
    function sortedLastIndex(array, value) {
      return baseSortedIndex(array, value, true);
    }

    /**
     * This method is like `_.sortedLastIndex` except that it accepts `iteratee`
     * which is invoked for `value` and each element of `array` to compute their
     * sort ranking. The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The sorted array to inspect.
     * @param {*} value The value to evaluate.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {number} Returns the index at which `value` should be inserted
     *  into `array`.
     * @example
     *
     * var objects = [{ 'x': 4 }, { 'x': 5 }];
     *
     * _.sortedLastIndexBy(objects, { 'x': 4 }, function(o) { return o.x; });
     * // => 1
     *
     * // The `_.property` iteratee shorthand.
     * _.sortedLastIndexBy(objects, { 'x': 4 }, 'x');
     * // => 1
     */
    function sortedLastIndexBy(array, value, iteratee) {
      return baseSortedIndexBy(array, value, getIteratee(iteratee, 2), true);
    }

    /**
     * This method is like `_.lastIndexOf` except that it performs a binary
     * search on a sorted `array`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {*} value The value to search for.
     * @returns {number} Returns the index of the matched value, else `-1`.
     * @example
     *
     * _.sortedLastIndexOf([4, 5, 5, 5, 6], 5);
     * // => 3
     */
    function sortedLastIndexOf(array, value) {
      var length = array == null ? 0 : array.length;
      if (length) {
        var index = baseSortedIndex(array, value, true) - 1;
        if (eq(array[index], value)) {
          return index;
        }
      }
      return -1;
    }

    /**
     * This method is like `_.uniq` except that it's designed and optimized
     * for sorted arrays.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @returns {Array} Returns the new duplicate free array.
     * @example
     *
     * _.sortedUniq([1, 1, 2]);
     * // => [1, 2]
     */
    function sortedUniq(array) {
      return (array && array.length)
        ? baseSortedUniq(array)
        : [];
    }

    /**
     * This method is like `_.uniqBy` except that it's designed and optimized
     * for sorted arrays.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {Function} [iteratee] The iteratee invoked per element.
     * @returns {Array} Returns the new duplicate free array.
     * @example
     *
     * _.sortedUniqBy([1.1, 1.2, 2.3, 2.4], Math.floor);
     * // => [1.1, 2.3]
     */
    function sortedUniqBy(array, iteratee) {
      return (array && array.length)
        ? baseSortedUniq(array, getIteratee(iteratee, 2))
        : [];
    }

    /**
     * Gets all but the first element of `array`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * _.tail([1, 2, 3]);
     * // => [2, 3]
     */
    function tail(array) {
      var length = array == null ? 0 : array.length;
      return length ? baseSlice(array, 1, length) : [];
    }

    /**
     * Creates a slice of `array` with `n` elements taken from the beginning.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {number} [n=1] The number of elements to take.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * _.take([1, 2, 3]);
     * // => [1]
     *
     * _.take([1, 2, 3], 2);
     * // => [1, 2]
     *
     * _.take([1, 2, 3], 5);
     * // => [1, 2, 3]
     *
     * _.take([1, 2, 3], 0);
     * // => []
     */
    function take(array, n, guard) {
      if (!(array && array.length)) {
        return [];
      }
      n = (guard || n === undefined) ? 1 : toInteger(n);
      return baseSlice(array, 0, n < 0 ? 0 : n);
    }

    /**
     * Creates a slice of `array` with `n` elements taken from the end.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {number} [n=1] The number of elements to take.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * _.takeRight([1, 2, 3]);
     * // => [3]
     *
     * _.takeRight([1, 2, 3], 2);
     * // => [2, 3]
     *
     * _.takeRight([1, 2, 3], 5);
     * // => [1, 2, 3]
     *
     * _.takeRight([1, 2, 3], 0);
     * // => []
     */
    function takeRight(array, n, guard) {
      var length = array == null ? 0 : array.length;
      if (!length) {
        return [];
      }
      n = (guard || n === undefined) ? 1 : toInteger(n);
      n = length - n;
      return baseSlice(array, n < 0 ? 0 : n, length);
    }

    /**
     * Creates a slice of `array` with elements taken from the end. Elements are
     * taken until `predicate` returns falsey. The predicate is invoked with
     * three arguments: (value, index, array).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'active': true },
     *   { 'user': 'fred',    'active': false },
     *   { 'user': 'pebbles', 'active': false }
     * ];
     *
     * _.takeRightWhile(users, function(o) { return !o.active; });
     * // => objects for ['fred', 'pebbles']
     *
     * // The `_.matches` iteratee shorthand.
     * _.takeRightWhile(users, { 'user': 'pebbles', 'active': false });
     * // => objects for ['pebbles']
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.takeRightWhile(users, ['active', false]);
     * // => objects for ['fred', 'pebbles']
     *
     * // The `_.property` iteratee shorthand.
     * _.takeRightWhile(users, 'active');
     * // => []
     */
    function takeRightWhile(array, predicate) {
      return (array && array.length)
        ? baseWhile(array, getIteratee(predicate, 3), false, true)
        : [];
    }

    /**
     * Creates a slice of `array` with elements taken from the beginning. Elements
     * are taken until `predicate` returns falsey. The predicate is invoked with
     * three arguments: (value, index, array).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Array
     * @param {Array} array The array to query.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the slice of `array`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'active': false },
     *   { 'user': 'fred',    'active': false },
     *   { 'user': 'pebbles', 'active': true }
     * ];
     *
     * _.takeWhile(users, function(o) { return !o.active; });
     * // => objects for ['barney', 'fred']
     *
     * // The `_.matches` iteratee shorthand.
     * _.takeWhile(users, { 'user': 'barney', 'active': false });
     * // => objects for ['barney']
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.takeWhile(users, ['active', false]);
     * // => objects for ['barney', 'fred']
     *
     * // The `_.property` iteratee shorthand.
     * _.takeWhile(users, 'active');
     * // => []
     */
    function takeWhile(array, predicate) {
      return (array && array.length)
        ? baseWhile(array, getIteratee(predicate, 3))
        : [];
    }

    /**
     * Creates an array of unique values, in order, from all given arrays using
     * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @returns {Array} Returns the new array of combined values.
     * @example
     *
     * _.union([2], [1, 2]);
     * // => [2, 1]
     */
    var union = baseRest(function(arrays) {
      return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true));
    });

    /**
     * This method is like `_.union` except that it accepts `iteratee` which is
     * invoked for each element of each `arrays` to generate the criterion by
     * which uniqueness is computed. Result values are chosen from the first
     * array in which the value occurs. The iteratee is invoked with one argument:
     * (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Array} Returns the new array of combined values.
     * @example
     *
     * _.unionBy([2.1], [1.2, 2.3], Math.floor);
     * // => [2.1, 1.2]
     *
     * // The `_.property` iteratee shorthand.
     * _.unionBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x');
     * // => [{ 'x': 1 }, { 'x': 2 }]
     */
    var unionBy = baseRest(function(arrays) {
      var iteratee = last(arrays);
      if (isArrayLikeObject(iteratee)) {
        iteratee = undefined;
      }
      return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), getIteratee(iteratee, 2));
    });

    /**
     * This method is like `_.union` except that it accepts `comparator` which
     * is invoked to compare elements of `arrays`. Result values are chosen from
     * the first array in which the value occurs. The comparator is invoked
     * with two arguments: (arrVal, othVal).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of combined values.
     * @example
     *
     * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];
     * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }];
     *
     * _.unionWith(objects, others, _.isEqual);
     * // => [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }, { 'x': 1, 'y': 1 }]
     */
    var unionWith = baseRest(function(arrays) {
      var comparator = last(arrays);
      comparator = typeof comparator == 'function' ? comparator : undefined;
      return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), undefined, comparator);
    });

    /**
     * Creates a duplicate-free version of an array, using
     * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons, in which only the first occurrence of each element
     * is kept. The order of result values is determined by the order they occur
     * in the array.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @returns {Array} Returns the new duplicate free array.
     * @example
     *
     * _.uniq([2, 1, 2]);
     * // => [2, 1]
     */
    function uniq(array) {
      return (array && array.length) ? baseUniq(array) : [];
    }

    /**
     * This method is like `_.uniq` except that it accepts `iteratee` which is
     * invoked for each element in `array` to generate the criterion by which
     * uniqueness is computed. The order of result values is determined by the
     * order they occur in the array. The iteratee is invoked with one argument:
     * (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Array} Returns the new duplicate free array.
     * @example
     *
     * _.uniqBy([2.1, 1.2, 2.3], Math.floor);
     * // => [2.1, 1.2]
     *
     * // The `_.property` iteratee shorthand.
     * _.uniqBy([{ 'x': 1 }, { 'x': 2 }, { 'x': 1 }], 'x');
     * // => [{ 'x': 1 }, { 'x': 2 }]
     */
    function uniqBy(array, iteratee) {
      return (array && array.length) ? baseUniq(array, getIteratee(iteratee, 2)) : [];
    }

    /**
     * This method is like `_.uniq` except that it accepts `comparator` which
     * is invoked to compare elements of `array`. The order of result values is
     * determined by the order they occur in the array.The comparator is invoked
     * with two arguments: (arrVal, othVal).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new duplicate free array.
     * @example
     *
     * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }, { 'x': 1, 'y': 2 }];
     *
     * _.uniqWith(objects, _.isEqual);
     * // => [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }]
     */
    function uniqWith(array, comparator) {
      comparator = typeof comparator == 'function' ? comparator : undefined;
      return (array && array.length) ? baseUniq(array, undefined, comparator) : [];
    }

    /**
     * This method is like `_.zip` except that it accepts an array of grouped
     * elements and creates an array regrouping the elements to their pre-zip
     * configuration.
     *
     * @static
     * @memberOf _
     * @since 1.2.0
     * @category Array
     * @param {Array} array The array of grouped elements to process.
     * @returns {Array} Returns the new array of regrouped elements.
     * @example
     *
     * var zipped = _.zip(['a', 'b'], [1, 2], [true, false]);
     * // => [['a', 1, true], ['b', 2, false]]
     *
     * _.unzip(zipped);
     * // => [['a', 'b'], [1, 2], [true, false]]
     */
    function unzip(array) {
      if (!(array && array.length)) {
        return [];
      }
      var length = 0;
      array = arrayFilter(array, function(group) {
        if (isArrayLikeObject(group)) {
          length = nativeMax(group.length, length);
          return true;
        }
      });
      return baseTimes(length, function(index) {
        return arrayMap(array, baseProperty(index));
      });
    }

    /**
     * This method is like `_.unzip` except that it accepts `iteratee` to specify
     * how regrouped values should be combined. The iteratee is invoked with the
     * elements of each group: (...group).
     *
     * @static
     * @memberOf _
     * @since 3.8.0
     * @category Array
     * @param {Array} array The array of grouped elements to process.
     * @param {Function} [iteratee=_.identity] The function to combine
     *  regrouped values.
     * @returns {Array} Returns the new array of regrouped elements.
     * @example
     *
     * var zipped = _.zip([1, 2], [10, 20], [100, 200]);
     * // => [[1, 10, 100], [2, 20, 200]]
     *
     * _.unzipWith(zipped, _.add);
     * // => [3, 30, 300]
     */
    function unzipWith(array, iteratee) {
      if (!(array && array.length)) {
        return [];
      }
      var result = unzip(array);
      if (iteratee == null) {
        return result;
      }
      return arrayMap(result, function(group) {
        return apply(iteratee, undefined, group);
      });
    }

    /**
     * Creates an array excluding all given values using
     * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * for equality comparisons.
     *
     * **Note:** Unlike `_.pull`, this method returns a new array.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {Array} array The array to inspect.
     * @param {...*} [values] The values to exclude.
     * @returns {Array} Returns the new array of filtered values.
     * @see _.difference, _.xor
     * @example
     *
     * _.without([2, 1, 2, 3], 1, 2);
     * // => [3]
     */
    var without = baseRest(function(array, values) {
      return isArrayLikeObject(array)
        ? baseDifference(array, values)
        : [];
    });

    /**
     * Creates an array of unique values that is the
     * [symmetric difference](https://en.wikipedia.org/wiki/Symmetric_difference)
     * of the given arrays. The order of result values is determined by the order
     * they occur in the arrays.
     *
     * @static
     * @memberOf _
     * @since 2.4.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @returns {Array} Returns the new array of filtered values.
     * @see _.difference, _.without
     * @example
     *
     * _.xor([2, 1], [2, 3]);
     * // => [1, 3]
     */
    var xor = baseRest(function(arrays) {
      return baseXor(arrayFilter(arrays, isArrayLikeObject));
    });

    /**
     * This method is like `_.xor` except that it accepts `iteratee` which is
     * invoked for each element of each `arrays` to generate the criterion by
     * which by which they're compared. The order of result values is determined
     * by the order they occur in the arrays. The iteratee is invoked with one
     * argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Array} Returns the new array of filtered values.
     * @example
     *
     * _.xorBy([2.1, 1.2], [2.3, 3.4], Math.floor);
     * // => [1.2, 3.4]
     *
     * // The `_.property` iteratee shorthand.
     * _.xorBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x');
     * // => [{ 'x': 2 }]
     */
    var xorBy = baseRest(function(arrays) {
      var iteratee = last(arrays);
      if (isArrayLikeObject(iteratee)) {
        iteratee = undefined;
      }
      return baseXor(arrayFilter(arrays, isArrayLikeObject), getIteratee(iteratee, 2));
    });

    /**
     * This method is like `_.xor` except that it accepts `comparator` which is
     * invoked to compare elements of `arrays`. The order of result values is
     * determined by the order they occur in the arrays. The comparator is invoked
     * with two arguments: (arrVal, othVal).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Array
     * @param {...Array} [arrays] The arrays to inspect.
     * @param {Function} [comparator] The comparator invoked per element.
     * @returns {Array} Returns the new array of filtered values.
     * @example
     *
     * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];
     * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }];
     *
     * _.xorWith(objects, others, _.isEqual);
     * // => [{ 'x': 2, 'y': 1 }, { 'x': 1, 'y': 1 }]
     */
    var xorWith = baseRest(function(arrays) {
      var comparator = last(arrays);
      comparator = typeof comparator == 'function' ? comparator : undefined;
      return baseXor(arrayFilter(arrays, isArrayLikeObject), undefined, comparator);
    });

    /**
     * Creates an array of grouped elements, the first of which contains the
     * first elements of the given arrays, the second of which contains the
     * second elements of the given arrays, and so on.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Array
     * @param {...Array} [arrays] The arrays to process.
     * @returns {Array} Returns the new array of grouped elements.
     * @example
     *
     * _.zip(['a', 'b'], [1, 2], [true, false]);
     * // => [['a', 1, true], ['b', 2, false]]
     */
    var zip = baseRest(unzip);

    /**
     * This method is like `_.fromPairs` except that it accepts two arrays,
     * one of property identifiers and one of corresponding values.
     *
     * @static
     * @memberOf _
     * @since 0.4.0
     * @category Array
     * @param {Array} [props=[]] The property identifiers.
     * @param {Array} [values=[]] The property values.
     * @returns {Object} Returns the new object.
     * @example
     *
     * _.zipObject(['a', 'b'], [1, 2]);
     * // => { 'a': 1, 'b': 2 }
     */
    function zipObject(props, values) {
      return baseZipObject(props || [], values || [], assignValue);
    }

    /**
     * This method is like `_.zipObject` except that it supports property paths.
     *
     * @static
     * @memberOf _
     * @since 4.1.0
     * @category Array
     * @param {Array} [props=[]] The property identifiers.
     * @param {Array} [values=[]] The property values.
     * @returns {Object} Returns the new object.
     * @example
     *
     * _.zipObjectDeep(['a.b[0].c', 'a.b[1].d'], [1, 2]);
     * // => { 'a': { 'b': [{ 'c': 1 }, { 'd': 2 }] } }
     */
    function zipObjectDeep(props, values) {
      return baseZipObject(props || [], values || [], baseSet);
    }

    /**
     * This method is like `_.zip` except that it accepts `iteratee` to specify
     * how grouped values should be combined. The iteratee is invoked with the
     * elements of each group: (...group).
     *
     * @static
     * @memberOf _
     * @since 3.8.0
     * @category Array
     * @param {...Array} [arrays] The arrays to process.
     * @param {Function} [iteratee=_.identity] The function to combine
     *  grouped values.
     * @returns {Array} Returns the new array of grouped elements.
     * @example
     *
     * _.zipWith([1, 2], [10, 20], [100, 200], function(a, b, c) {
     *   return a + b + c;
     * });
     * // => [111, 222]
     */
    var zipWith = baseRest(function(arrays) {
      var length = arrays.length,
          iteratee = length > 1 ? arrays[length - 1] : undefined;

      iteratee = typeof iteratee == 'function' ? (arrays.pop(), iteratee) : undefined;
      return unzipWith(arrays, iteratee);
    });

    /*------------------------------------------------------------------------*/

    /**
     * Creates a `lodash` wrapper instance that wraps `value` with explicit method
     * chain sequences enabled. The result of such sequences must be unwrapped
     * with `_#value`.
     *
     * @static
     * @memberOf _
     * @since 1.3.0
     * @category Seq
     * @param {*} value The value to wrap.
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'age': 36 },
     *   { 'user': 'fred',    'age': 40 },
     *   { 'user': 'pebbles', 'age': 1 }
     * ];
     *
     * var youngest = _
     *   .chain(users)
     *   .sortBy('age')
     *   .map(function(o) {
     *     return o.user + ' is ' + o.age;
     *   })
     *   .head()
     *   .value();
     * // => 'pebbles is 1'
     */
    function chain(value) {
      var result = lodash(value);
      result.__chain__ = true;
      return result;
    }

    /**
     * This method invokes `interceptor` and returns `value`. The interceptor
     * is invoked with one argument; (value). The purpose of this method is to
     * "tap into" a method chain sequence in order to modify intermediate results.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Seq
     * @param {*} value The value to provide to `interceptor`.
     * @param {Function} interceptor The function to invoke.
     * @returns {*} Returns `value`.
     * @example
     *
     * _([1, 2, 3])
     *  .tap(function(array) {
     *    // Mutate input array.
     *    array.pop();
     *  })
     *  .reverse()
     *  .value();
     * // => [2, 1]
     */
    function tap(value, interceptor) {
      interceptor(value);
      return value;
    }

    /**
     * This method is like `_.tap` except that it returns the result of `interceptor`.
     * The purpose of this method is to "pass thru" values replacing intermediate
     * results in a method chain sequence.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Seq
     * @param {*} value The value to provide to `interceptor`.
     * @param {Function} interceptor The function to invoke.
     * @returns {*} Returns the result of `interceptor`.
     * @example
     *
     * _('  abc  ')
     *  .chain()
     *  .trim()
     *  .thru(function(value) {
     *    return [value];
     *  })
     *  .value();
     * // => ['abc']
     */
    function thru(value, interceptor) {
      return interceptor(value);
    }

    /**
     * This method is the wrapper version of `_.at`.
     *
     * @name at
     * @memberOf _
     * @since 1.0.0
     * @category Seq
     * @param {...(string|string[])} [paths] The property paths to pick.
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] };
     *
     * _(object).at(['a[0].b.c', 'a[1]']).value();
     * // => [3, 4]
     */
    var wrapperAt = flatRest(function(paths) {
      var length = paths.length,
          start = length ? paths[0] : 0,
          value = this.__wrapped__,
          interceptor = function(object) { return baseAt(object, paths); };

      if (length > 1 || this.__actions__.length ||
          !(value instanceof LazyWrapper) || !isIndex(start)) {
        return this.thru(interceptor);
      }
      value = value.slice(start, +start + (length ? 1 : 0));
      value.__actions__.push({
        'func': thru,
        'args': [interceptor],
        'thisArg': undefined
      });
      return new LodashWrapper(value, this.__chain__).thru(function(array) {
        if (length && !array.length) {
          array.push(undefined);
        }
        return array;
      });
    });

    /**
     * Creates a `lodash` wrapper instance with explicit method chain sequences enabled.
     *
     * @name chain
     * @memberOf _
     * @since 0.1.0
     * @category Seq
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * var users = [
     *   { 'user': 'barney', 'age': 36 },
     *   { 'user': 'fred',   'age': 40 }
     * ];
     *
     * // A sequence without explicit chaining.
     * _(users).head();
     * // => { 'user': 'barney', 'age': 36 }
     *
     * // A sequence with explicit chaining.
     * _(users)
     *   .chain()
     *   .head()
     *   .pick('user')
     *   .value();
     * // => { 'user': 'barney' }
     */
    function wrapperChain() {
      return chain(this);
    }

    /**
     * Executes the chain sequence and returns the wrapped result.
     *
     * @name commit
     * @memberOf _
     * @since 3.2.0
     * @category Seq
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * var array = [1, 2];
     * var wrapped = _(array).push(3);
     *
     * console.log(array);
     * // => [1, 2]
     *
     * wrapped = wrapped.commit();
     * console.log(array);
     * // => [1, 2, 3]
     *
     * wrapped.last();
     * // => 3
     *
     * console.log(array);
     * // => [1, 2, 3]
     */
    function wrapperCommit() {
      return new LodashWrapper(this.value(), this.__chain__);
    }

    /**
     * Gets the next value on a wrapped object following the
     * [iterator protocol](https://mdn.io/iteration_protocols#iterator).
     *
     * @name next
     * @memberOf _
     * @since 4.0.0
     * @category Seq
     * @returns {Object} Returns the next iterator value.
     * @example
     *
     * var wrapped = _([1, 2]);
     *
     * wrapped.next();
     * // => { 'done': false, 'value': 1 }
     *
     * wrapped.next();
     * // => { 'done': false, 'value': 2 }
     *
     * wrapped.next();
     * // => { 'done': true, 'value': undefined }
     */
    function wrapperNext() {
      if (this.__values__ === undefined) {
        this.__values__ = toArray(this.value());
      }
      var done = this.__index__ >= this.__values__.length,
          value = done ? undefined : this.__values__[this.__index__++];

      return { 'done': done, 'value': value };
    }

    /**
     * Enables the wrapper to be iterable.
     *
     * @name Symbol.iterator
     * @memberOf _
     * @since 4.0.0
     * @category Seq
     * @returns {Object} Returns the wrapper object.
     * @example
     *
     * var wrapped = _([1, 2]);
     *
     * wrapped[Symbol.iterator]() === wrapped;
     * // => true
     *
     * Array.from(wrapped);
     * // => [1, 2]
     */
    function wrapperToIterator() {
      return this;
    }

    /**
     * Creates a clone of the chain sequence planting `value` as the wrapped value.
     *
     * @name plant
     * @memberOf _
     * @since 3.2.0
     * @category Seq
     * @param {*} value The value to plant.
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * function square(n) {
     *   return n * n;
     * }
     *
     * var wrapped = _([1, 2]).map(square);
     * var other = wrapped.plant([3, 4]);
     *
     * other.value();
     * // => [9, 16]
     *
     * wrapped.value();
     * // => [1, 4]
     */
    function wrapperPlant(value) {
      var result,
          parent = this;

      while (parent instanceof baseLodash) {
        var clone = wrapperClone(parent);
        clone.__index__ = 0;
        clone.__values__ = undefined;
        if (result) {
          previous.__wrapped__ = clone;
        } else {
          result = clone;
        }
        var previous = clone;
        parent = parent.__wrapped__;
      }
      previous.__wrapped__ = value;
      return result;
    }

    /**
     * This method is the wrapper version of `_.reverse`.
     *
     * **Note:** This method mutates the wrapped array.
     *
     * @name reverse
     * @memberOf _
     * @since 0.1.0
     * @category Seq
     * @returns {Object} Returns the new `lodash` wrapper instance.
     * @example
     *
     * var array = [1, 2, 3];
     *
     * _(array).reverse().value()
     * // => [3, 2, 1]
     *
     * console.log(array);
     * // => [3, 2, 1]
     */
    function wrapperReverse() {
      var value = this.__wrapped__;
      if (value instanceof LazyWrapper) {
        var wrapped = value;
        if (this.__actions__.length) {
          wrapped = new LazyWrapper(this);
        }
        wrapped = wrapped.reverse();
        wrapped.__actions__.push({
          'func': thru,
          'args': [reverse],
          'thisArg': undefined
        });
        return new LodashWrapper(wrapped, this.__chain__);
      }
      return this.thru(reverse);
    }

    /**
     * Executes the chain sequence to resolve the unwrapped value.
     *
     * @name value
     * @memberOf _
     * @since 0.1.0
     * @alias toJSON, valueOf
     * @category Seq
     * @returns {*} Returns the resolved unwrapped value.
     * @example
     *
     * _([1, 2, 3]).value();
     * // => [1, 2, 3]
     */
    function wrapperValue() {
      return baseWrapperValue(this.__wrapped__, this.__actions__);
    }

    /*------------------------------------------------------------------------*/

    /**
     * Creates an object composed of keys generated from the results of running
     * each element of `collection` thru `iteratee`. The corresponding value of
     * each key is the number of times the key was returned by `iteratee`. The
     * iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 0.5.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee to transform keys.
     * @returns {Object} Returns the composed aggregate object.
     * @example
     *
     * _.countBy([6.1, 4.2, 6.3], Math.floor);
     * // => { '4': 1, '6': 2 }
     *
     * // The `_.property` iteratee shorthand.
     * _.countBy(['one', 'two', 'three'], 'length');
     * // => { '3': 2, '5': 1 }
     */
    var countBy = createAggregator(function(result, value, key) {
      if (hasOwnProperty.call(result, key)) {
        ++result[key];
      } else {
        baseAssignValue(result, key, 1);
      }
    });

    /**
     * Checks if `predicate` returns truthy for **all** elements of `collection`.
     * Iteration is stopped once `predicate` returns falsey. The predicate is
     * invoked with three arguments: (value, index|key, collection).
     *
     * **Note:** This method returns `true` for
     * [empty collections](https://en.wikipedia.org/wiki/Empty_set) because
     * [everything is true](https://en.wikipedia.org/wiki/Vacuous_truth) of
     * elements of empty collections.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {boolean} Returns `true` if all elements pass the predicate check,
     *  else `false`.
     * @example
     *
     * _.every([true, 1, null, 'yes'], Boolean);
     * // => false
     *
     * var users = [
     *   { 'user': 'barney', 'age': 36, 'active': false },
     *   { 'user': 'fred',   'age': 40, 'active': false }
     * ];
     *
     * // The `_.matches` iteratee shorthand.
     * _.every(users, { 'user': 'barney', 'active': false });
     * // => false
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.every(users, ['active', false]);
     * // => true
     *
     * // The `_.property` iteratee shorthand.
     * _.every(users, 'active');
     * // => false
     */
    function every(collection, predicate, guard) {
      var func = isArray(collection) ? arrayEvery : baseEvery;
      if (guard && isIterateeCall(collection, predicate, guard)) {
        predicate = undefined;
      }
      return func(collection, getIteratee(predicate, 3));
    }

    /**
     * Iterates over elements of `collection`, returning an array of all elements
     * `predicate` returns truthy for. The predicate is invoked with three
     * arguments: (value, index|key, collection).
     *
     * **Note:** Unlike `_.remove`, this method returns a new array.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the new filtered array.
     * @see _.reject
     * @example
     *
     * var users = [
     *   { 'user': 'barney', 'age': 36, 'active': true },
     *   { 'user': 'fred',   'age': 40, 'active': false }
     * ];
     *
     * _.filter(users, function(o) { return !o.active; });
     * // => objects for ['fred']
     *
     * // The `_.matches` iteratee shorthand.
     * _.filter(users, { 'age': 36, 'active': true });
     * // => objects for ['barney']
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.filter(users, ['active', false]);
     * // => objects for ['fred']
     *
     * // The `_.property` iteratee shorthand.
     * _.filter(users, 'active');
     * // => objects for ['barney']
     *
     * // Combining several predicates using `_.overEvery` or `_.overSome`.
     * _.filter(users, _.overSome([{ 'age': 36 }, ['age', 40]]));
     * // => objects for ['fred', 'barney']
     */
    function filter(collection, predicate) {
      var func = isArray(collection) ? arrayFilter : baseFilter;
      return func(collection, getIteratee(predicate, 3));
    }

    /**
     * Iterates over elements of `collection`, returning the first element
     * `predicate` returns truthy for. The predicate is invoked with three
     * arguments: (value, index|key, collection).
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to inspect.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @param {number} [fromIndex=0] The index to search from.
     * @returns {*} Returns the matched element, else `undefined`.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'age': 36, 'active': true },
     *   { 'user': 'fred',    'age': 40, 'active': false },
     *   { 'user': 'pebbles', 'age': 1,  'active': true }
     * ];
     *
     * _.find(users, function(o) { return o.age < 40; });
     * // => object for 'barney'
     *
     * // The `_.matches` iteratee shorthand.
     * _.find(users, { 'age': 1, 'active': true });
     * // => object for 'pebbles'
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.find(users, ['active', false]);
     * // => object for 'fred'
     *
     * // The `_.property` iteratee shorthand.
     * _.find(users, 'active');
     * // => object for 'barney'
     */
    var find = createFind(findIndex);

    /**
     * This method is like `_.find` except that it iterates over elements of
     * `collection` from right to left.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to inspect.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @param {number} [fromIndex=collection.length-1] The index to search from.
     * @returns {*} Returns the matched element, else `undefined`.
     * @example
     *
     * _.findLast([1, 2, 3, 4], function(n) {
     *   return n % 2 == 1;
     * });
     * // => 3
     */
    var findLast = createFind(findLastIndex);

    /**
     * Creates a flattened array of values by running each element in `collection`
     * thru `iteratee` and flattening the mapped results. The iteratee is invoked
     * with three arguments: (value, index|key, collection).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the new flattened array.
     * @example
     *
     * function duplicate(n) {
     *   return [n, n];
     * }
     *
     * _.flatMap([1, 2], duplicate);
     * // => [1, 1, 2, 2]
     */
    function flatMap(collection, iteratee) {
      return baseFlatten(map(collection, iteratee), 1);
    }

    /**
     * This method is like `_.flatMap` except that it recursively flattens the
     * mapped results.
     *
     * @static
     * @memberOf _
     * @since 4.7.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the new flattened array.
     * @example
     *
     * function duplicate(n) {
     *   return [[[n, n]]];
     * }
     *
     * _.flatMapDeep([1, 2], duplicate);
     * // => [1, 1, 2, 2]
     */
    function flatMapDeep(collection, iteratee) {
      return baseFlatten(map(collection, iteratee), INFINITY);
    }

    /**
     * This method is like `_.flatMap` except that it recursively flattens the
     * mapped results up to `depth` times.
     *
     * @static
     * @memberOf _
     * @since 4.7.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @param {number} [depth=1] The maximum recursion depth.
     * @returns {Array} Returns the new flattened array.
     * @example
     *
     * function duplicate(n) {
     *   return [[[n, n]]];
     * }
     *
     * _.flatMapDepth([1, 2], duplicate, 2);
     * // => [[1, 1], [2, 2]]
     */
    function flatMapDepth(collection, iteratee, depth) {
      depth = depth === undefined ? 1 : toInteger(depth);
      return baseFlatten(map(collection, iteratee), depth);
    }

    /**
     * Iterates over elements of `collection` and invokes `iteratee` for each element.
     * The iteratee is invoked with three arguments: (value, index|key, collection).
     * Iteratee functions may exit iteration early by explicitly returning `false`.
     *
     * **Note:** As with other "Collections" methods, objects with a "length"
     * property are iterated like arrays. To avoid this behavior use `_.forIn`
     * or `_.forOwn` for object iteration.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @alias each
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Array|Object} Returns `collection`.
     * @see _.forEachRight
     * @example
     *
     * _.forEach([1, 2], function(value) {
     *   console.log(value);
     * });
     * // => Logs `1` then `2`.
     *
     * _.forEach({ 'a': 1, 'b': 2 }, function(value, key) {
     *   console.log(key);
     * });
     * // => Logs 'a' then 'b' (iteration order is not guaranteed).
     */
    function forEach(collection, iteratee) {
      var func = isArray(collection) ? arrayEach : baseEach;
      return func(collection, getIteratee(iteratee, 3));
    }

    /**
     * This method is like `_.forEach` except that it iterates over elements of
     * `collection` from right to left.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @alias eachRight
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Array|Object} Returns `collection`.
     * @see _.forEach
     * @example
     *
     * _.forEachRight([1, 2], function(value) {
     *   console.log(value);
     * });
     * // => Logs `2` then `1`.
     */
    function forEachRight(collection, iteratee) {
      var func = isArray(collection) ? arrayEachRight : baseEachRight;
      return func(collection, getIteratee(iteratee, 3));
    }

    /**
     * Creates an object composed of keys generated from the results of running
     * each element of `collection` thru `iteratee`. The order of grouped values
     * is determined by the order they occur in `collection`. The corresponding
     * value of each key is an array of elements responsible for generating the
     * key. The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee to transform keys.
     * @returns {Object} Returns the composed aggregate object.
     * @example
     *
     * _.groupBy([6.1, 4.2, 6.3], Math.floor);
     * // => { '4': [4.2], '6': [6.1, 6.3] }
     *
     * // The `_.property` iteratee shorthand.
     * _.groupBy(['one', 'two', 'three'], 'length');
     * // => { '3': ['one', 'two'], '5': ['three'] }
     */
    var groupBy = createAggregator(function(result, value, key) {
      if (hasOwnProperty.call(result, key)) {
        result[key].push(value);
      } else {
        baseAssignValue(result, key, [value]);
      }
    });

    /**
     * Checks if `value` is in `collection`. If `collection` is a string, it's
     * checked for a substring of `value`, otherwise
     * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * is used for equality comparisons. If `fromIndex` is negative, it's used as
     * the offset from the end of `collection`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object|string} collection The collection to inspect.
     * @param {*} value The value to search for.
     * @param {number} [fromIndex=0] The index to search from.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`.
     * @returns {boolean} Returns `true` if `value` is found, else `false`.
     * @example
     *
     * _.includes([1, 2, 3], 1);
     * // => true
     *
     * _.includes([1, 2, 3], 1, 2);
     * // => false
     *
     * _.includes({ 'a': 1, 'b': 2 }, 1);
     * // => true
     *
     * _.includes('abcd', 'bc');
     * // => true
     */
    function includes(collection, value, fromIndex, guard) {
      collection = isArrayLike(collection) ? collection : values(collection);
      fromIndex = (fromIndex && !guard) ? toInteger(fromIndex) : 0;

      var length = collection.length;
      if (fromIndex < 0) {
        fromIndex = nativeMax(length + fromIndex, 0);
      }
      return isString(collection)
        ? (fromIndex <= length && collection.indexOf(value, fromIndex) > -1)
        : (!!length && baseIndexOf(collection, value, fromIndex) > -1);
    }

    /**
     * Invokes the method at `path` of each element in `collection`, returning
     * an array of the results of each invoked method. Any additional arguments
     * are provided to each invoked method. If `path` is a function, it's invoked
     * for, and `this` bound to, each element in `collection`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Array|Function|string} path The path of the method to invoke or
     *  the function invoked per iteration.
     * @param {...*} [args] The arguments to invoke each method with.
     * @returns {Array} Returns the array of results.
     * @example
     *
     * _.invokeMap([[5, 1, 7], [3, 2, 1]], 'sort');
     * // => [[1, 5, 7], [1, 2, 3]]
     *
     * _.invokeMap([123, 456], String.prototype.split, '');
     * // => [['1', '2', '3'], ['4', '5', '6']]
     */
    var invokeMap = baseRest(function(collection, path, args) {
      var index = -1,
          isFunc = typeof path == 'function',
          result = isArrayLike(collection) ? Array(collection.length) : [];

      baseEach(collection, function(value) {
        result[++index] = isFunc ? apply(path, value, args) : baseInvoke(value, path, args);
      });
      return result;
    });

    /**
     * Creates an object composed of keys generated from the results of running
     * each element of `collection` thru `iteratee`. The corresponding value of
     * each key is the last element responsible for generating the key. The
     * iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee to transform keys.
     * @returns {Object} Returns the composed aggregate object.
     * @example
     *
     * var array = [
     *   { 'dir': 'left', 'code': 97 },
     *   { 'dir': 'right', 'code': 100 }
     * ];
     *
     * _.keyBy(array, function(o) {
     *   return String.fromCharCode(o.code);
     * });
     * // => { 'a': { 'dir': 'left', 'code': 97 }, 'd': { 'dir': 'right', 'code': 100 } }
     *
     * _.keyBy(array, 'dir');
     * // => { 'left': { 'dir': 'left', 'code': 97 }, 'right': { 'dir': 'right', 'code': 100 } }
     */
    var keyBy = createAggregator(function(result, value, key) {
      baseAssignValue(result, key, value);
    });

    /**
     * Creates an array of values by running each element in `collection` thru
     * `iteratee`. The iteratee is invoked with three arguments:
     * (value, index|key, collection).
     *
     * Many lodash methods are guarded to work as iteratees for methods like
     * `_.every`, `_.filter`, `_.map`, `_.mapValues`, `_.reject`, and `_.some`.
     *
     * The guarded methods are:
     * `ary`, `chunk`, `curry`, `curryRight`, `drop`, `dropRight`, `every`,
     * `fill`, `invert`, `parseInt`, `random`, `range`, `rangeRight`, `repeat`,
     * `sampleSize`, `slice`, `some`, `sortBy`, `split`, `take`, `takeRight`,
     * `template`, `trim`, `trimEnd`, `trimStart`, and `words`
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the new mapped array.
     * @example
     *
     * function square(n) {
     *   return n * n;
     * }
     *
     * _.map([4, 8], square);
     * // => [16, 64]
     *
     * _.map({ 'a': 4, 'b': 8 }, square);
     * // => [16, 64] (iteration order is not guaranteed)
     *
     * var users = [
     *   { 'user': 'barney' },
     *   { 'user': 'fred' }
     * ];
     *
     * // The `_.property` iteratee shorthand.
     * _.map(users, 'user');
     * // => ['barney', 'fred']
     */
    function map(collection, iteratee) {
      var func = isArray(collection) ? arrayMap : baseMap;
      return func(collection, getIteratee(iteratee, 3));
    }

    /**
     * This method is like `_.sortBy` except that it allows specifying the sort
     * orders of the iteratees to sort by. If `orders` is unspecified, all values
     * are sorted in ascending order. Otherwise, specify an order of "desc" for
     * descending or "asc" for ascending sort order of corresponding values.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Array[]|Function[]|Object[]|string[]} [iteratees=[_.identity]]
     *  The iteratees to sort by.
     * @param {string[]} [orders] The sort orders of `iteratees`.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`.
     * @returns {Array} Returns the new sorted array.
     * @example
     *
     * var users = [
     *   { 'user': 'fred',   'age': 48 },
     *   { 'user': 'barney', 'age': 34 },
     *   { 'user': 'fred',   'age': 40 },
     *   { 'user': 'barney', 'age': 36 }
     * ];
     *
     * // Sort by `user` in ascending order and by `age` in descending order.
     * _.orderBy(users, ['user', 'age'], ['asc', 'desc']);
     * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 40]]
     */
    function orderBy(collection, iteratees, orders, guard) {
      if (collection == null) {
        return [];
      }
      if (!isArray(iteratees)) {
        iteratees = iteratees == null ? [] : [iteratees];
      }
      orders = guard ? undefined : orders;
      if (!isArray(orders)) {
        orders = orders == null ? [] : [orders];
      }
      return baseOrderBy(collection, iteratees, orders);
    }

    /**
     * Creates an array of elements split into two groups, the first of which
     * contains elements `predicate` returns truthy for, the second of which
     * contains elements `predicate` returns falsey for. The predicate is
     * invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the array of grouped elements.
     * @example
     *
     * var users = [
     *   { 'user': 'barney',  'age': 36, 'active': false },
     *   { 'user': 'fred',    'age': 40, 'active': true },
     *   { 'user': 'pebbles', 'age': 1,  'active': false }
     * ];
     *
     * _.partition(users, function(o) { return o.active; });
     * // => objects for [['fred'], ['barney', 'pebbles']]
     *
     * // The `_.matches` iteratee shorthand.
     * _.partition(users, { 'age': 1, 'active': false });
     * // => objects for [['pebbles'], ['barney', 'fred']]
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.partition(users, ['active', false]);
     * // => objects for [['barney', 'pebbles'], ['fred']]
     *
     * // The `_.property` iteratee shorthand.
     * _.partition(users, 'active');
     * // => objects for [['fred'], ['barney', 'pebbles']]
     */
    var partition = createAggregator(function(result, value, key) {
      result[key ? 0 : 1].push(value);
    }, function() { return [[], []]; });

    /**
     * Reduces `collection` to a value which is the accumulated result of running
     * each element in `collection` thru `iteratee`, where each successive
     * invocation is supplied the return value of the previous. If `accumulator`
     * is not given, the first element of `collection` is used as the initial
     * value. The iteratee is invoked with four arguments:
     * (accumulator, value, index|key, collection).
     *
     * Many lodash methods are guarded to work as iteratees for methods like
     * `_.reduce`, `_.reduceRight`, and `_.transform`.
     *
     * The guarded methods are:
     * `assign`, `defaults`, `defaultsDeep`, `includes`, `merge`, `orderBy`,
     * and `sortBy`
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @param {*} [accumulator] The initial value.
     * @returns {*} Returns the accumulated value.
     * @see _.reduceRight
     * @example
     *
     * _.reduce([1, 2], function(sum, n) {
     *   return sum + n;
     * }, 0);
     * // => 3
     *
     * _.reduce({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) {
     *   (result[value] || (result[value] = [])).push(key);
     *   return result;
     * }, {});
     * // => { '1': ['a', 'c'], '2': ['b'] } (iteration order is not guaranteed)
     */
    function reduce(collection, iteratee, accumulator) {
      var func = isArray(collection) ? arrayReduce : baseReduce,
          initAccum = arguments.length < 3;

      return func(collection, getIteratee(iteratee, 4), accumulator, initAccum, baseEach);
    }

    /**
     * This method is like `_.reduce` except that it iterates over elements of
     * `collection` from right to left.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @param {*} [accumulator] The initial value.
     * @returns {*} Returns the accumulated value.
     * @see _.reduce
     * @example
     *
     * var array = [[0, 1], [2, 3], [4, 5]];
     *
     * _.reduceRight(array, function(flattened, other) {
     *   return flattened.concat(other);
     * }, []);
     * // => [4, 5, 2, 3, 0, 1]
     */
    function reduceRight(collection, iteratee, accumulator) {
      var func = isArray(collection) ? arrayReduceRight : baseReduce,
          initAccum = arguments.length < 3;

      return func(collection, getIteratee(iteratee, 4), accumulator, initAccum, baseEachRight);
    }

    /**
     * The opposite of `_.filter`; this method returns the elements of `collection`
     * that `predicate` does **not** return truthy for.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the new filtered array.
     * @see _.filter
     * @example
     *
     * var users = [
     *   { 'user': 'barney', 'age': 36, 'active': false },
     *   { 'user': 'fred',   'age': 40, 'active': true }
     * ];
     *
     * _.reject(users, function(o) { return !o.active; });
     * // => objects for ['fred']
     *
     * // The `_.matches` iteratee shorthand.
     * _.reject(users, { 'age': 40, 'active': true });
     * // => objects for ['barney']
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.reject(users, ['active', false]);
     * // => objects for ['fred']
     *
     * // The `_.property` iteratee shorthand.
     * _.reject(users, 'active');
     * // => objects for ['barney']
     */
    function reject(collection, predicate) {
      var func = isArray(collection) ? arrayFilter : baseFilter;
      return func(collection, negate(getIteratee(predicate, 3)));
    }

    /**
     * Gets a random element from `collection`.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to sample.
     * @returns {*} Returns the random element.
     * @example
     *
     * _.sample([1, 2, 3, 4]);
     * // => 2
     */
    function sample(collection) {
      var func = isArray(collection) ? arraySample : baseSample;
      return func(collection);
    }

    /**
     * Gets `n` random elements at unique keys from `collection` up to the
     * size of `collection`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Collection
     * @param {Array|Object} collection The collection to sample.
     * @param {number} [n=1] The number of elements to sample.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the random elements.
     * @example
     *
     * _.sampleSize([1, 2, 3], 2);
     * // => [3, 1]
     *
     * _.sampleSize([1, 2, 3], 4);
     * // => [2, 3, 1]
     */
    function sampleSize(collection, n, guard) {
      if ((guard ? isIterateeCall(collection, n, guard) : n === undefined)) {
        n = 1;
      } else {
        n = toInteger(n);
      }
      var func = isArray(collection) ? arraySampleSize : baseSampleSize;
      return func(collection, n);
    }

    /**
     * Creates an array of shuffled values, using a version of the
     * [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher-Yates_shuffle).
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to shuffle.
     * @returns {Array} Returns the new shuffled array.
     * @example
     *
     * _.shuffle([1, 2, 3, 4]);
     * // => [4, 1, 3, 2]
     */
    function shuffle(collection) {
      var func = isArray(collection) ? arrayShuffle : baseShuffle;
      return func(collection);
    }

    /**
     * Gets the size of `collection` by returning its length for array-like
     * values or the number of own enumerable string keyed properties for objects.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object|string} collection The collection to inspect.
     * @returns {number} Returns the collection size.
     * @example
     *
     * _.size([1, 2, 3]);
     * // => 3
     *
     * _.size({ 'a': 1, 'b': 2 });
     * // => 2
     *
     * _.size('pebbles');
     * // => 7
     */
    function size(collection) {
      if (collection == null) {
        return 0;
      }
      if (isArrayLike(collection)) {
        return isString(collection) ? stringSize(collection) : collection.length;
      }
      var tag = getTag(collection);
      if (tag == mapTag || tag == setTag) {
        return collection.size;
      }
      return baseKeys(collection).length;
    }

    /**
     * Checks if `predicate` returns truthy for **any** element of `collection`.
     * Iteration is stopped once `predicate` returns truthy. The predicate is
     * invoked with three arguments: (value, index|key, collection).
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {boolean} Returns `true` if any element passes the predicate check,
     *  else `false`.
     * @example
     *
     * _.some([null, 0, 'yes', false], Boolean);
     * // => true
     *
     * var users = [
     *   { 'user': 'barney', 'active': true },
     *   { 'user': 'fred',   'active': false }
     * ];
     *
     * // The `_.matches` iteratee shorthand.
     * _.some(users, { 'user': 'barney', 'active': false });
     * // => false
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.some(users, ['active', false]);
     * // => true
     *
     * // The `_.property` iteratee shorthand.
     * _.some(users, 'active');
     * // => true
     */
    function some(collection, predicate, guard) {
      var func = isArray(collection) ? arraySome : baseSome;
      if (guard && isIterateeCall(collection, predicate, guard)) {
        predicate = undefined;
      }
      return func(collection, getIteratee(predicate, 3));
    }

    /**
     * Creates an array of elements, sorted in ascending order by the results of
     * running each element in a collection thru each iteratee. This method
     * performs a stable sort, that is, it preserves the original sort order of
     * equal elements. The iteratees are invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Collection
     * @param {Array|Object} collection The collection to iterate over.
     * @param {...(Function|Function[])} [iteratees=[_.identity]]
     *  The iteratees to sort by.
     * @returns {Array} Returns the new sorted array.
     * @example
     *
     * var users = [
     *   { 'user': 'fred',   'age': 48 },
     *   { 'user': 'barney', 'age': 36 },
     *   { 'user': 'fred',   'age': 30 },
     *   { 'user': 'barney', 'age': 34 }
     * ];
     *
     * _.sortBy(users, [function(o) { return o.user; }]);
     * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 30]]
     *
     * _.sortBy(users, ['user', 'age']);
     * // => objects for [['barney', 34], ['barney', 36], ['fred', 30], ['fred', 48]]
     */
    var sortBy = baseRest(function(collection, iteratees) {
      if (collection == null) {
        return [];
      }
      var length = iteratees.length;
      if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {
        iteratees = [];
      } else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {
        iteratees = [iteratees[0]];
      }
      return baseOrderBy(collection, baseFlatten(iteratees, 1), []);
    });

    /*------------------------------------------------------------------------*/

    /**
     * Gets the timestamp of the number of milliseconds that have elapsed since
     * the Unix epoch (1 January 1970 00:00:00 UTC).
     *
     * @static
     * @memberOf _
     * @since 2.4.0
     * @category Date
     * @returns {number} Returns the timestamp.
     * @example
     *
     * _.defer(function(stamp) {
     *   console.log(_.now() - stamp);
     * }, _.now());
     * // => Logs the number of milliseconds it took for the deferred invocation.
     */
    var now = ctxNow || function() {
      return root.Date.now();
    };

    /*------------------------------------------------------------------------*/

    /**
     * The opposite of `_.before`; this method creates a function that invokes
     * `func` once it's called `n` or more times.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {number} n The number of calls before `func` is invoked.
     * @param {Function} func The function to restrict.
     * @returns {Function} Returns the new restricted function.
     * @example
     *
     * var saves = ['profile', 'settings'];
     *
     * var done = _.after(saves.length, function() {
     *   console.log('done saving!');
     * });
     *
     * _.forEach(saves, function(type) {
     *   asyncSave({ 'type': type, 'complete': done });
     * });
     * // => Logs 'done saving!' after the two async saves have completed.
     */
    function after(n, func) {
      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      n = toInteger(n);
      return function() {
        if (--n < 1) {
          return func.apply(this, arguments);
        }
      };
    }

    /**
     * Creates a function that invokes `func`, with up to `n` arguments,
     * ignoring any additional arguments.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Function
     * @param {Function} func The function to cap arguments for.
     * @param {number} [n=func.length] The arity cap.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Function} Returns the new capped function.
     * @example
     *
     * _.map(['6', '8', '10'], _.ary(parseInt, 1));
     * // => [6, 8, 10]
     */
    function ary(func, n, guard) {
      n = guard ? undefined : n;
      n = (func && n == null) ? func.length : n;
      return createWrap(func, WRAP_ARY_FLAG, undefined, undefined, undefined, undefined, n);
    }

    /**
     * Creates a function that invokes `func`, with the `this` binding and arguments
     * of the created function, while it's called less than `n` times. Subsequent
     * calls to the created function return the result of the last `func` invocation.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Function
     * @param {number} n The number of calls at which `func` is no longer invoked.
     * @param {Function} func The function to restrict.
     * @returns {Function} Returns the new restricted function.
     * @example
     *
     * jQuery(element).on('click', _.before(5, addContactToList));
     * // => Allows adding up to 4 contacts to the list.
     */
    function before(n, func) {
      var result;
      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      n = toInteger(n);
      return function() {
        if (--n > 0) {
          result = func.apply(this, arguments);
        }
        if (n <= 1) {
          func = undefined;
        }
        return result;
      };
    }

    /**
     * Creates a function that invokes `func` with the `this` binding of `thisArg`
     * and `partials` prepended to the arguments it receives.
     *
     * The `_.bind.placeholder` value, which defaults to `_` in monolithic builds,
     * may be used as a placeholder for partially applied arguments.
     *
     * **Note:** Unlike native `Function#bind`, this method doesn't set the "length"
     * property of bound functions.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to bind.
     * @param {*} thisArg The `this` binding of `func`.
     * @param {...*} [partials] The arguments to be partially applied.
     * @returns {Function} Returns the new bound function.
     * @example
     *
     * function greet(greeting, punctuation) {
     *   return greeting + ' ' + this.user + punctuation;
     * }
     *
     * var object = { 'user': 'fred' };
     *
     * var bound = _.bind(greet, object, 'hi');
     * bound('!');
     * // => 'hi fred!'
     *
     * // Bound with placeholders.
     * var bound = _.bind(greet, object, _, '!');
     * bound('hi');
     * // => 'hi fred!'
     */
    var bind = baseRest(function(func, thisArg, partials) {
      var bitmask = WRAP_BIND_FLAG;
      if (partials.length) {
        var holders = replaceHolders(partials, getHolder(bind));
        bitmask |= WRAP_PARTIAL_FLAG;
      }
      return createWrap(func, bitmask, thisArg, partials, holders);
    });

    /**
     * Creates a function that invokes the method at `object[key]` with `partials`
     * prepended to the arguments it receives.
     *
     * This method differs from `_.bind` by allowing bound functions to reference
     * methods that may be redefined or don't yet exist. See
     * [Peter Michaux's article](http://peter.michaux.ca/articles/lazy-function-definition-pattern)
     * for more details.
     *
     * The `_.bindKey.placeholder` value, which defaults to `_` in monolithic
     * builds, may be used as a placeholder for partially applied arguments.
     *
     * @static
     * @memberOf _
     * @since 0.10.0
     * @category Function
     * @param {Object} object The object to invoke the method on.
     * @param {string} key The key of the method.
     * @param {...*} [partials] The arguments to be partially applied.
     * @returns {Function} Returns the new bound function.
     * @example
     *
     * var object = {
     *   'user': 'fred',
     *   'greet': function(greeting, punctuation) {
     *     return greeting + ' ' + this.user + punctuation;
     *   }
     * };
     *
     * var bound = _.bindKey(object, 'greet', 'hi');
     * bound('!');
     * // => 'hi fred!'
     *
     * object.greet = function(greeting, punctuation) {
     *   return greeting + 'ya ' + this.user + punctuation;
     * };
     *
     * bound('!');
     * // => 'hiya fred!'
     *
     * // Bound with placeholders.
     * var bound = _.bindKey(object, 'greet', _, '!');
     * bound('hi');
     * // => 'hiya fred!'
     */
    var bindKey = baseRest(function(object, key, partials) {
      var bitmask = WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG;
      if (partials.length) {
        var holders = replaceHolders(partials, getHolder(bindKey));
        bitmask |= WRAP_PARTIAL_FLAG;
      }
      return createWrap(key, bitmask, object, partials, holders);
    });

    /**
     * Creates a function that accepts arguments of `func` and either invokes
     * `func` returning its result, if at least `arity` number of arguments have
     * been provided, or returns a function that accepts the remaining `func`
     * arguments, and so on. The arity of `func` may be specified if `func.length`
     * is not sufficient.
     *
     * The `_.curry.placeholder` value, which defaults to `_` in monolithic builds,
     * may be used as a placeholder for provided arguments.
     *
     * **Note:** This method doesn't set the "length" property of curried functions.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Function
     * @param {Function} func The function to curry.
     * @param {number} [arity=func.length] The arity of `func`.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Function} Returns the new curried function.
     * @example
     *
     * var abc = function(a, b, c) {
     *   return [a, b, c];
     * };
     *
     * var curried = _.curry(abc);
     *
     * curried(1)(2)(3);
     * // => [1, 2, 3]
     *
     * curried(1, 2)(3);
     * // => [1, 2, 3]
     *
     * curried(1, 2, 3);
     * // => [1, 2, 3]
     *
     * // Curried with placeholders.
     * curried(1)(_, 3)(2);
     * // => [1, 2, 3]
     */
    function curry(func, arity, guard) {
      arity = guard ? undefined : arity;
      var result = createWrap(func, WRAP_CURRY_FLAG, undefined, undefined, undefined, undefined, undefined, arity);
      result.placeholder = curry.placeholder;
      return result;
    }

    /**
     * This method is like `_.curry` except that arguments are applied to `func`
     * in the manner of `_.partialRight` instead of `_.partial`.
     *
     * The `_.curryRight.placeholder` value, which defaults to `_` in monolithic
     * builds, may be used as a placeholder for provided arguments.
     *
     * **Note:** This method doesn't set the "length" property of curried functions.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Function
     * @param {Function} func The function to curry.
     * @param {number} [arity=func.length] The arity of `func`.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Function} Returns the new curried function.
     * @example
     *
     * var abc = function(a, b, c) {
     *   return [a, b, c];
     * };
     *
     * var curried = _.curryRight(abc);
     *
     * curried(3)(2)(1);
     * // => [1, 2, 3]
     *
     * curried(2, 3)(1);
     * // => [1, 2, 3]
     *
     * curried(1, 2, 3);
     * // => [1, 2, 3]
     *
     * // Curried with placeholders.
     * curried(3)(1, _)(2);
     * // => [1, 2, 3]
     */
    function curryRight(func, arity, guard) {
      arity = guard ? undefined : arity;
      var result = createWrap(func, WRAP_CURRY_RIGHT_FLAG, undefined, undefined, undefined, undefined, undefined, arity);
      result.placeholder = curryRight.placeholder;
      return result;
    }

    /**
     * Creates a debounced function that delays invoking `func` until after `wait`
     * milliseconds have elapsed since the last time the debounced function was
     * invoked. The debounced function comes with a `cancel` method to cancel
     * delayed `func` invocations and a `flush` method to immediately invoke them.
     * Provide `options` to indicate whether `func` should be invoked on the
     * leading and/or trailing edge of the `wait` timeout. The `func` is invoked
     * with the last arguments provided to the debounced function. Subsequent
     * calls to the debounced function return the result of the last `func`
     * invocation.
     *
     * **Note:** If `leading` and `trailing` options are `true`, `func` is
     * invoked on the trailing edge of the timeout only if the debounced function
     * is invoked more than once during the `wait` timeout.
     *
     * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred
     * until to the next tick, similar to `setTimeout` with a timeout of `0`.
     *
     * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
     * for details over the differences between `_.debounce` and `_.throttle`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to debounce.
     * @param {number} [wait=0] The number of milliseconds to delay.
     * @param {Object} [options={}] The options object.
     * @param {boolean} [options.leading=false]
     *  Specify invoking on the leading edge of the timeout.
     * @param {number} [options.maxWait]
     *  The maximum time `func` is allowed to be delayed before it's invoked.
     * @param {boolean} [options.trailing=true]
     *  Specify invoking on the trailing edge of the timeout.
     * @returns {Function} Returns the new debounced function.
     * @example
     *
     * // Avoid costly calculations while the window size is in flux.
     * jQuery(window).on('resize', _.debounce(calculateLayout, 150));
     *
     * // Invoke `sendMail` when clicked, debouncing subsequent calls.
     * jQuery(element).on('click', _.debounce(sendMail, 300, {
     *   'leading': true,
     *   'trailing': false
     * }));
     *
     * // Ensure `batchLog` is invoked once after 1 second of debounced calls.
     * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });
     * var source = new EventSource('/stream');
     * jQuery(source).on('message', debounced);
     *
     * // Cancel the trailing debounced invocation.
     * jQuery(window).on('popstate', debounced.cancel);
     */
    function debounce(func, wait, options) {
      var lastArgs,
          lastThis,
          maxWait,
          result,
          timerId,
          lastCallTime,
          lastInvokeTime = 0,
          leading = false,
          maxing = false,
          trailing = true;

      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      wait = toNumber(wait) || 0;
      if (isObject(options)) {
        leading = !!options.leading;
        maxing = 'maxWait' in options;
        maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;
        trailing = 'trailing' in options ? !!options.trailing : trailing;
      }

      function invokeFunc(time) {
        var args = lastArgs,
            thisArg = lastThis;

        lastArgs = lastThis = undefined;
        lastInvokeTime = time;
        result = func.apply(thisArg, args);
        return result;
      }

      function leadingEdge(time) {
        // Reset any `maxWait` timer.
        lastInvokeTime = time;
        // Start the timer for the trailing edge.
        timerId = setTimeout(timerExpired, wait);
        // Invoke the leading edge.
        return leading ? invokeFunc(time) : result;
      }

      function remainingWait(time) {
        var timeSinceLastCall = time - lastCallTime,
            timeSinceLastInvoke = time - lastInvokeTime,
            timeWaiting = wait - timeSinceLastCall;

        return maxing
          ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)
          : timeWaiting;
      }

      function shouldInvoke(time) {
        var timeSinceLastCall = time - lastCallTime,
            timeSinceLastInvoke = time - lastInvokeTime;

        // Either this is the first call, activity has stopped and we're at the
        // trailing edge, the system time has gone backwards and we're treating
        // it as the trailing edge, or we've hit the `maxWait` limit.
        return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||
          (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));
      }

      function timerExpired() {
        var time = now();
        if (shouldInvoke(time)) {
          return trailingEdge(time);
        }
        // Restart the timer.
        timerId = setTimeout(timerExpired, remainingWait(time));
      }

      function trailingEdge(time) {
        timerId = undefined;

        // Only invoke if we have `lastArgs` which means `func` has been
        // debounced at least once.
        if (trailing && lastArgs) {
          return invokeFunc(time);
        }
        lastArgs = lastThis = undefined;
        return result;
      }

      function cancel() {
        if (timerId !== undefined) {
          clearTimeout(timerId);
        }
        lastInvokeTime = 0;
        lastArgs = lastCallTime = lastThis = timerId = undefined;
      }

      function flush() {
        return timerId === undefined ? result : trailingEdge(now());
      }

      function debounced() {
        var time = now(),
            isInvoking = shouldInvoke(time);

        lastArgs = arguments;
        lastThis = this;
        lastCallTime = time;

        if (isInvoking) {
          if (timerId === undefined) {
            return leadingEdge(lastCallTime);
          }
          if (maxing) {
            // Handle invocations in a tight loop.
            clearTimeout(timerId);
            timerId = setTimeout(timerExpired, wait);
            return invokeFunc(lastCallTime);
          }
        }
        if (timerId === undefined) {
          timerId = setTimeout(timerExpired, wait);
        }
        return result;
      }
      debounced.cancel = cancel;
      debounced.flush = flush;
      return debounced;
    }

    /**
     * Defers invoking the `func` until the current call stack has cleared. Any
     * additional arguments are provided to `func` when it's invoked.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to defer.
     * @param {...*} [args] The arguments to invoke `func` with.
     * @returns {number} Returns the timer id.
     * @example
     *
     * _.defer(function(text) {
     *   console.log(text);
     * }, 'deferred');
     * // => Logs 'deferred' after one millisecond.
     */
    var defer = baseRest(function(func, args) {
      return baseDelay(func, 1, args);
    });

    /**
     * Invokes `func` after `wait` milliseconds. Any additional arguments are
     * provided to `func` when it's invoked.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to delay.
     * @param {number} wait The number of milliseconds to delay invocation.
     * @param {...*} [args] The arguments to invoke `func` with.
     * @returns {number} Returns the timer id.
     * @example
     *
     * _.delay(function(text) {
     *   console.log(text);
     * }, 1000, 'later');
     * // => Logs 'later' after one second.
     */
    var delay = baseRest(function(func, wait, args) {
      return baseDelay(func, toNumber(wait) || 0, args);
    });

    /**
     * Creates a function that invokes `func` with arguments reversed.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Function
     * @param {Function} func The function to flip arguments for.
     * @returns {Function} Returns the new flipped function.
     * @example
     *
     * var flipped = _.flip(function() {
     *   return _.toArray(arguments);
     * });
     *
     * flipped('a', 'b', 'c', 'd');
     * // => ['d', 'c', 'b', 'a']
     */
    function flip(func) {
      return createWrap(func, WRAP_FLIP_FLAG);
    }

    /**
     * Creates a function that memoizes the result of `func`. If `resolver` is
     * provided, it determines the cache key for storing the result based on the
     * arguments provided to the memoized function. By default, the first argument
     * provided to the memoized function is used as the map cache key. The `func`
     * is invoked with the `this` binding of the memoized function.
     *
     * **Note:** The cache is exposed as the `cache` property on the memoized
     * function. Its creation may be customized by replacing the `_.memoize.Cache`
     * constructor with one whose instances implement the
     * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)
     * method interface of `clear`, `delete`, `get`, `has`, and `set`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to have its output memoized.
     * @param {Function} [resolver] The function to resolve the cache key.
     * @returns {Function} Returns the new memoized function.
     * @example
     *
     * var object = { 'a': 1, 'b': 2 };
     * var other = { 'c': 3, 'd': 4 };
     *
     * var values = _.memoize(_.values);
     * values(object);
     * // => [1, 2]
     *
     * values(other);
     * // => [3, 4]
     *
     * object.a = 2;
     * values(object);
     * // => [1, 2]
     *
     * // Modify the result cache.
     * values.cache.set(object, ['a', 'b']);
     * values(object);
     * // => ['a', 'b']
     *
     * // Replace `_.memoize.Cache`.
     * _.memoize.Cache = WeakMap;
     */
    function memoize(func, resolver) {
      if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      var memoized = function() {
        var args = arguments,
            key = resolver ? resolver.apply(this, args) : args[0],
            cache = memoized.cache;

        if (cache.has(key)) {
          return cache.get(key);
        }
        var result = func.apply(this, args);
        memoized.cache = cache.set(key, result) || cache;
        return result;
      };
      memoized.cache = new (memoize.Cache || MapCache);
      return memoized;
    }

    // Expose `MapCache`.
    memoize.Cache = MapCache;

    /**
     * Creates a function that negates the result of the predicate `func`. The
     * `func` predicate is invoked with the `this` binding and arguments of the
     * created function.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Function
     * @param {Function} predicate The predicate to negate.
     * @returns {Function} Returns the new negated function.
     * @example
     *
     * function isEven(n) {
     *   return n % 2 == 0;
     * }
     *
     * _.filter([1, 2, 3, 4, 5, 6], _.negate(isEven));
     * // => [1, 3, 5]
     */
    function negate(predicate) {
      if (typeof predicate != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      return function() {
        var args = arguments;
        switch (args.length) {
          case 0: return !predicate.call(this);
          case 1: return !predicate.call(this, args[0]);
          case 2: return !predicate.call(this, args[0], args[1]);
          case 3: return !predicate.call(this, args[0], args[1], args[2]);
        }
        return !predicate.apply(this, args);
      };
    }

    /**
     * Creates a function that is restricted to invoking `func` once. Repeat calls
     * to the function return the value of the first invocation. The `func` is
     * invoked with the `this` binding and arguments of the created function.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to restrict.
     * @returns {Function} Returns the new restricted function.
     * @example
     *
     * var initialize = _.once(createApplication);
     * initialize();
     * initialize();
     * // => `createApplication` is invoked once
     */
    function once(func) {
      return before(2, func);
    }

    /**
     * Creates a function that invokes `func` with its arguments transformed.
     *
     * @static
     * @since 4.0.0
     * @memberOf _
     * @category Function
     * @param {Function} func The function to wrap.
     * @param {...(Function|Function[])} [transforms=[_.identity]]
     *  The argument transforms.
     * @returns {Function} Returns the new function.
     * @example
     *
     * function doubled(n) {
     *   return n * 2;
     * }
     *
     * function square(n) {
     *   return n * n;
     * }
     *
     * var func = _.overArgs(function(x, y) {
     *   return [x, y];
     * }, [square, doubled]);
     *
     * func(9, 3);
     * // => [81, 6]
     *
     * func(10, 5);
     * // => [100, 10]
     */
    var overArgs = castRest(function(func, transforms) {
      transforms = (transforms.length == 1 && isArray(transforms[0]))
        ? arrayMap(transforms[0], baseUnary(getIteratee()))
        : arrayMap(baseFlatten(transforms, 1), baseUnary(getIteratee()));

      var funcsLength = transforms.length;
      return baseRest(function(args) {
        var index = -1,
            length = nativeMin(args.length, funcsLength);

        while (++index < length) {
          args[index] = transforms[index].call(this, args[index]);
        }
        return apply(func, this, args);
      });
    });

    /**
     * Creates a function that invokes `func` with `partials` prepended to the
     * arguments it receives. This method is like `_.bind` except it does **not**
     * alter the `this` binding.
     *
     * The `_.partial.placeholder` value, which defaults to `_` in monolithic
     * builds, may be used as a placeholder for partially applied arguments.
     *
     * **Note:** This method doesn't set the "length" property of partially
     * applied functions.
     *
     * @static
     * @memberOf _
     * @since 0.2.0
     * @category Function
     * @param {Function} func The function to partially apply arguments to.
     * @param {...*} [partials] The arguments to be partially applied.
     * @returns {Function} Returns the new partially applied function.
     * @example
     *
     * function greet(greeting, name) {
     *   return greeting + ' ' + name;
     * }
     *
     * var sayHelloTo = _.partial(greet, 'hello');
     * sayHelloTo('fred');
     * // => 'hello fred'
     *
     * // Partially applied with placeholders.
     * var greetFred = _.partial(greet, _, 'fred');
     * greetFred('hi');
     * // => 'hi fred'
     */
    var partial = baseRest(function(func, partials) {
      var holders = replaceHolders(partials, getHolder(partial));
      return createWrap(func, WRAP_PARTIAL_FLAG, undefined, partials, holders);
    });

    /**
     * This method is like `_.partial` except that partially applied arguments
     * are appended to the arguments it receives.
     *
     * The `_.partialRight.placeholder` value, which defaults to `_` in monolithic
     * builds, may be used as a placeholder for partially applied arguments.
     *
     * **Note:** This method doesn't set the "length" property of partially
     * applied functions.
     *
     * @static
     * @memberOf _
     * @since 1.0.0
     * @category Function
     * @param {Function} func The function to partially apply arguments to.
     * @param {...*} [partials] The arguments to be partially applied.
     * @returns {Function} Returns the new partially applied function.
     * @example
     *
     * function greet(greeting, name) {
     *   return greeting + ' ' + name;
     * }
     *
     * var greetFred = _.partialRight(greet, 'fred');
     * greetFred('hi');
     * // => 'hi fred'
     *
     * // Partially applied with placeholders.
     * var sayHelloTo = _.partialRight(greet, 'hello', _);
     * sayHelloTo('fred');
     * // => 'hello fred'
     */
    var partialRight = baseRest(function(func, partials) {
      var holders = replaceHolders(partials, getHolder(partialRight));
      return createWrap(func, WRAP_PARTIAL_RIGHT_FLAG, undefined, partials, holders);
    });

    /**
     * Creates a function that invokes `func` with arguments arranged according
     * to the specified `indexes` where the argument value at the first index is
     * provided as the first argument, the argument value at the second index is
     * provided as the second argument, and so on.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Function
     * @param {Function} func The function to rearrange arguments for.
     * @param {...(number|number[])} indexes The arranged argument indexes.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var rearged = _.rearg(function(a, b, c) {
     *   return [a, b, c];
     * }, [2, 0, 1]);
     *
     * rearged('b', 'c', 'a')
     * // => ['a', 'b', 'c']
     */
    var rearg = flatRest(function(func, indexes) {
      return createWrap(func, WRAP_REARG_FLAG, undefined, undefined, undefined, indexes);
    });

    /**
     * Creates a function that invokes `func` with the `this` binding of the
     * created function and arguments from `start` and beyond provided as
     * an array.
     *
     * **Note:** This method is based on the
     * [rest parameter](https://mdn.io/rest_parameters).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Function
     * @param {Function} func The function to apply a rest parameter to.
     * @param {number} [start=func.length-1] The start position of the rest parameter.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var say = _.rest(function(what, names) {
     *   return what + ' ' + _.initial(names).join(', ') +
     *     (_.size(names) > 1 ? ', & ' : '') + _.last(names);
     * });
     *
     * say('hello', 'fred', 'barney', 'pebbles');
     * // => 'hello fred, barney, & pebbles'
     */
    function rest(func, start) {
      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      start = start === undefined ? start : toInteger(start);
      return baseRest(func, start);
    }

    /**
     * Creates a function that invokes `func` with the `this` binding of the
     * create function and an array of arguments much like
     * [`Function#apply`](http://www.ecma-international.org/ecma-262/7.0/#sec-function.prototype.apply).
     *
     * **Note:** This method is based on the
     * [spread operator](https://mdn.io/spread_operator).
     *
     * @static
     * @memberOf _
     * @since 3.2.0
     * @category Function
     * @param {Function} func The function to spread arguments over.
     * @param {number} [start=0] The start position of the spread.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var say = _.spread(function(who, what) {
     *   return who + ' says ' + what;
     * });
     *
     * say(['fred', 'hello']);
     * // => 'fred says hello'
     *
     * var numbers = Promise.all([
     *   Promise.resolve(40),
     *   Promise.resolve(36)
     * ]);
     *
     * numbers.then(_.spread(function(x, y) {
     *   return x + y;
     * }));
     * // => a Promise of 76
     */
    function spread(func, start) {
      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      start = start == null ? 0 : nativeMax(toInteger(start), 0);
      return baseRest(function(args) {
        var array = args[start],
            otherArgs = castSlice(args, 0, start);

        if (array) {
          arrayPush(otherArgs, array);
        }
        return apply(func, this, otherArgs);
      });
    }

    /**
     * Creates a throttled function that only invokes `func` at most once per
     * every `wait` milliseconds. The throttled function comes with a `cancel`
     * method to cancel delayed `func` invocations and a `flush` method to
     * immediately invoke them. Provide `options` to indicate whether `func`
     * should be invoked on the leading and/or trailing edge of the `wait`
     * timeout. The `func` is invoked with the last arguments provided to the
     * throttled function. Subsequent calls to the throttled function return the
     * result of the last `func` invocation.
     *
     * **Note:** If `leading` and `trailing` options are `true`, `func` is
     * invoked on the trailing edge of the timeout only if the throttled function
     * is invoked more than once during the `wait` timeout.
     *
     * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred
     * until to the next tick, similar to `setTimeout` with a timeout of `0`.
     *
     * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
     * for details over the differences between `_.throttle` and `_.debounce`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {Function} func The function to throttle.
     * @param {number} [wait=0] The number of milliseconds to throttle invocations to.
     * @param {Object} [options={}] The options object.
     * @param {boolean} [options.leading=true]
     *  Specify invoking on the leading edge of the timeout.
     * @param {boolean} [options.trailing=true]
     *  Specify invoking on the trailing edge of the timeout.
     * @returns {Function} Returns the new throttled function.
     * @example
     *
     * // Avoid excessively updating the position while scrolling.
     * jQuery(window).on('scroll', _.throttle(updatePosition, 100));
     *
     * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.
     * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });
     * jQuery(element).on('click', throttled);
     *
     * // Cancel the trailing throttled invocation.
     * jQuery(window).on('popstate', throttled.cancel);
     */
    function throttle(func, wait, options) {
      var leading = true,
          trailing = true;

      if (typeof func != 'function') {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      if (isObject(options)) {
        leading = 'leading' in options ? !!options.leading : leading;
        trailing = 'trailing' in options ? !!options.trailing : trailing;
      }
      return debounce(func, wait, {
        'leading': leading,
        'maxWait': wait,
        'trailing': trailing
      });
    }

    /**
     * Creates a function that accepts up to one argument, ignoring any
     * additional arguments.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Function
     * @param {Function} func The function to cap arguments for.
     * @returns {Function} Returns the new capped function.
     * @example
     *
     * _.map(['6', '8', '10'], _.unary(parseInt));
     * // => [6, 8, 10]
     */
    function unary(func) {
      return ary(func, 1);
    }

    /**
     * Creates a function that provides `value` to `wrapper` as its first
     * argument. Any additional arguments provided to the function are appended
     * to those provided to the `wrapper`. The wrapper is invoked with the `this`
     * binding of the created function.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Function
     * @param {*} value The value to wrap.
     * @param {Function} [wrapper=identity] The wrapper function.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var p = _.wrap(_.escape, function(func, text) {
     *   return '<p>' + func(text) + '</p>';
     * });
     *
     * p('fred, barney, & pebbles');
     * // => '<p>fred, barney, &amp; pebbles</p>'
     */
    function wrap(value, wrapper) {
      return partial(castFunction(wrapper), value);
    }

    /*------------------------------------------------------------------------*/

    /**
     * Casts `value` as an array if it's not one.
     *
     * @static
     * @memberOf _
     * @since 4.4.0
     * @category Lang
     * @param {*} value The value to inspect.
     * @returns {Array} Returns the cast array.
     * @example
     *
     * _.castArray(1);
     * // => [1]
     *
     * _.castArray({ 'a': 1 });
     * // => [{ 'a': 1 }]
     *
     * _.castArray('abc');
     * // => ['abc']
     *
     * _.castArray(null);
     * // => [null]
     *
     * _.castArray(undefined);
     * // => [undefined]
     *
     * _.castArray();
     * // => []
     *
     * var array = [1, 2, 3];
     * console.log(_.castArray(array) === array);
     * // => true
     */
    function castArray() {
      if (!arguments.length) {
        return [];
      }
      var value = arguments[0];
      return isArray(value) ? value : [value];
    }

    /**
     * Creates a shallow clone of `value`.
     *
     * **Note:** This method is loosely based on the
     * [structured clone algorithm](https://mdn.io/Structured_clone_algorithm)
     * and supports cloning arrays, array buffers, booleans, date objects, maps,
     * numbers, `Object` objects, regexes, sets, strings, symbols, and typed
     * arrays. The own enumerable properties of `arguments` objects are cloned
     * as plain objects. An empty object is returned for uncloneable values such
     * as error objects, functions, DOM nodes, and WeakMaps.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to clone.
     * @returns {*} Returns the cloned value.
     * @see _.cloneDeep
     * @example
     *
     * var objects = [{ 'a': 1 }, { 'b': 2 }];
     *
     * var shallow = _.clone(objects);
     * console.log(shallow[0] === objects[0]);
     * // => true
     */
    function clone(value) {
      return baseClone(value, CLONE_SYMBOLS_FLAG);
    }

    /**
     * This method is like `_.clone` except that it accepts `customizer` which
     * is invoked to produce the cloned value. If `customizer` returns `undefined`,
     * cloning is handled by the method instead. The `customizer` is invoked with
     * up to four arguments; (value [, index|key, object, stack]).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to clone.
     * @param {Function} [customizer] The function to customize cloning.
     * @returns {*} Returns the cloned value.
     * @see _.cloneDeepWith
     * @example
     *
     * function customizer(value) {
     *   if (_.isElement(value)) {
     *     return value.cloneNode(false);
     *   }
     * }
     *
     * var el = _.cloneWith(document.body, customizer);
     *
     * console.log(el === document.body);
     * // => false
     * console.log(el.nodeName);
     * // => 'BODY'
     * console.log(el.childNodes.length);
     * // => 0
     */
    function cloneWith(value, customizer) {
      customizer = typeof customizer == 'function' ? customizer : undefined;
      return baseClone(value, CLONE_SYMBOLS_FLAG, customizer);
    }

    /**
     * This method is like `_.clone` except that it recursively clones `value`.
     *
     * @static
     * @memberOf _
     * @since 1.0.0
     * @category Lang
     * @param {*} value The value to recursively clone.
     * @returns {*} Returns the deep cloned value.
     * @see _.clone
     * @example
     *
     * var objects = [{ 'a': 1 }, { 'b': 2 }];
     *
     * var deep = _.cloneDeep(objects);
     * console.log(deep[0] === objects[0]);
     * // => false
     */
    function cloneDeep(value) {
      return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);
    }

    /**
     * This method is like `_.cloneWith` except that it recursively clones `value`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to recursively clone.
     * @param {Function} [customizer] The function to customize cloning.
     * @returns {*} Returns the deep cloned value.
     * @see _.cloneWith
     * @example
     *
     * function customizer(value) {
     *   if (_.isElement(value)) {
     *     return value.cloneNode(true);
     *   }
     * }
     *
     * var el = _.cloneDeepWith(document.body, customizer);
     *
     * console.log(el === document.body);
     * // => false
     * console.log(el.nodeName);
     * // => 'BODY'
     * console.log(el.childNodes.length);
     * // => 20
     */
    function cloneDeepWith(value, customizer) {
      customizer = typeof customizer == 'function' ? customizer : undefined;
      return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG, customizer);
    }

    /**
     * Checks if `object` conforms to `source` by invoking the predicate
     * properties of `source` with the corresponding property values of `object`.
     *
     * **Note:** This method is equivalent to `_.conforms` when `source` is
     * partially applied.
     *
     * @static
     * @memberOf _
     * @since 4.14.0
     * @category Lang
     * @param {Object} object The object to inspect.
     * @param {Object} source The object of property predicates to conform to.
     * @returns {boolean} Returns `true` if `object` conforms, else `false`.
     * @example
     *
     * var object = { 'a': 1, 'b': 2 };
     *
     * _.conformsTo(object, { 'b': function(n) { return n > 1; } });
     * // => true
     *
     * _.conformsTo(object, { 'b': function(n) { return n > 2; } });
     * // => false
     */
    function conformsTo(object, source) {
      return source == null || baseConformsTo(object, source, keys(source));
    }

    /**
     * Performs a
     * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)
     * comparison between two values to determine if they are equivalent.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
     * @example
     *
     * var object = { 'a': 1 };
     * var other = { 'a': 1 };
     *
     * _.eq(object, object);
     * // => true
     *
     * _.eq(object, other);
     * // => false
     *
     * _.eq('a', 'a');
     * // => true
     *
     * _.eq('a', Object('a'));
     * // => false
     *
     * _.eq(NaN, NaN);
     * // => true
     */
    function eq(value, other) {
      return value === other || (value !== value && other !== other);
    }

    /**
     * Checks if `value` is greater than `other`.
     *
     * @static
     * @memberOf _
     * @since 3.9.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if `value` is greater than `other`,
     *  else `false`.
     * @see _.lt
     * @example
     *
     * _.gt(3, 1);
     * // => true
     *
     * _.gt(3, 3);
     * // => false
     *
     * _.gt(1, 3);
     * // => false
     */
    var gt = createRelationalOperation(baseGt);

    /**
     * Checks if `value` is greater than or equal to `other`.
     *
     * @static
     * @memberOf _
     * @since 3.9.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if `value` is greater than or equal to
     *  `other`, else `false`.
     * @see _.lte
     * @example
     *
     * _.gte(3, 1);
     * // => true
     *
     * _.gte(3, 3);
     * // => true
     *
     * _.gte(1, 3);
     * // => false
     */
    var gte = createRelationalOperation(function(value, other) {
      return value >= other;
    });

    /**
     * Checks if `value` is likely an `arguments` object.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an `arguments` object,
     *  else `false`.
     * @example
     *
     * _.isArguments(function() { return arguments; }());
     * // => true
     *
     * _.isArguments([1, 2, 3]);
     * // => false
     */
    var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {
      return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&
        !propertyIsEnumerable.call(value, 'callee');
    };

    /**
     * Checks if `value` is classified as an `Array` object.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an array, else `false`.
     * @example
     *
     * _.isArray([1, 2, 3]);
     * // => true
     *
     * _.isArray(document.body.children);
     * // => false
     *
     * _.isArray('abc');
     * // => false
     *
     * _.isArray(_.noop);
     * // => false
     */
    var isArray = Array.isArray;

    /**
     * Checks if `value` is classified as an `ArrayBuffer` object.
     *
     * @static
     * @memberOf _
     * @since 4.3.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`.
     * @example
     *
     * _.isArrayBuffer(new ArrayBuffer(2));
     * // => true
     *
     * _.isArrayBuffer(new Array(2));
     * // => false
     */
    var isArrayBuffer = nodeIsArrayBuffer ? baseUnary(nodeIsArrayBuffer) : baseIsArrayBuffer;

    /**
     * Checks if `value` is array-like. A value is considered array-like if it's
     * not a function and has a `value.length` that's an integer greater than or
     * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is array-like, else `false`.
     * @example
     *
     * _.isArrayLike([1, 2, 3]);
     * // => true
     *
     * _.isArrayLike(document.body.children);
     * // => true
     *
     * _.isArrayLike('abc');
     * // => true
     *
     * _.isArrayLike(_.noop);
     * // => false
     */
    function isArrayLike(value) {
      return value != null && isLength(value.length) && !isFunction(value);
    }

    /**
     * This method is like `_.isArrayLike` except that it also checks if `value`
     * is an object.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an array-like object,
     *  else `false`.
     * @example
     *
     * _.isArrayLikeObject([1, 2, 3]);
     * // => true
     *
     * _.isArrayLikeObject(document.body.children);
     * // => true
     *
     * _.isArrayLikeObject('abc');
     * // => false
     *
     * _.isArrayLikeObject(_.noop);
     * // => false
     */
    function isArrayLikeObject(value) {
      return isObjectLike(value) && isArrayLike(value);
    }

    /**
     * Checks if `value` is classified as a boolean primitive or object.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a boolean, else `false`.
     * @example
     *
     * _.isBoolean(false);
     * // => true
     *
     * _.isBoolean(null);
     * // => false
     */
    function isBoolean(value) {
      return value === true || value === false ||
        (isObjectLike(value) && baseGetTag(value) == boolTag);
    }

    /**
     * Checks if `value` is a buffer.
     *
     * @static
     * @memberOf _
     * @since 4.3.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.
     * @example
     *
     * _.isBuffer(new Buffer(2));
     * // => true
     *
     * _.isBuffer(new Uint8Array(2));
     * // => false
     */
    var isBuffer = nativeIsBuffer || stubFalse;

    /**
     * Checks if `value` is classified as a `Date` object.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a date object, else `false`.
     * @example
     *
     * _.isDate(new Date);
     * // => true
     *
     * _.isDate('Mon April 23 2012');
     * // => false
     */
    var isDate = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate;

    /**
     * Checks if `value` is likely a DOM element.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a DOM element, else `false`.
     * @example
     *
     * _.isElement(document.body);
     * // => true
     *
     * _.isElement('<body>');
     * // => false
     */
    function isElement(value) {
      return isObjectLike(value) && value.nodeType === 1 && !isPlainObject(value);
    }

    /**
     * Checks if `value` is an empty object, collection, map, or set.
     *
     * Objects are considered empty if they have no own enumerable string keyed
     * properties.
     *
     * Array-like values such as `arguments` objects, arrays, buffers, strings, or
     * jQuery-like collections are considered empty if they have a `length` of `0`.
     * Similarly, maps and sets are considered empty if they have a `size` of `0`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is empty, else `false`.
     * @example
     *
     * _.isEmpty(null);
     * // => true
     *
     * _.isEmpty(true);
     * // => true
     *
     * _.isEmpty(1);
     * // => true
     *
     * _.isEmpty([1, 2, 3]);
     * // => false
     *
     * _.isEmpty({ 'a': 1 });
     * // => false
     */
    function isEmpty(value) {
      if (value == null) {
        return true;
      }
      if (isArrayLike(value) &&
          (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||
            isBuffer(value) || isTypedArray(value) || isArguments(value))) {
        return !value.length;
      }
      var tag = getTag(value);
      if (tag == mapTag || tag == setTag) {
        return !value.size;
      }
      if (isPrototype(value)) {
        return !baseKeys(value).length;
      }
      for (var key in value) {
        if (hasOwnProperty.call(value, key)) {
          return false;
        }
      }
      return true;
    }

    /**
     * Performs a deep comparison between two values to determine if they are
     * equivalent.
     *
     * **Note:** This method supports comparing arrays, array buffers, booleans,
     * date objects, error objects, maps, numbers, `Object` objects, regexes,
     * sets, strings, symbols, and typed arrays. `Object` objects are compared
     * by their own, not inherited, enumerable properties. Functions and DOM
     * nodes are compared by strict equality, i.e. `===`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
     * @example
     *
     * var object = { 'a': 1 };
     * var other = { 'a': 1 };
     *
     * _.isEqual(object, other);
     * // => true
     *
     * object === other;
     * // => false
     */
    function isEqual(value, other) {
      return baseIsEqual(value, other);
    }

    /**
     * This method is like `_.isEqual` except that it accepts `customizer` which
     * is invoked to compare values. If `customizer` returns `undefined`, comparisons
     * are handled by the method instead. The `customizer` is invoked with up to
     * six arguments: (objValue, othValue [, index|key, object, other, stack]).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @param {Function} [customizer] The function to customize comparisons.
     * @returns {boolean} Returns `true` if the values are equivalent, else `false`.
     * @example
     *
     * function isGreeting(value) {
     *   return /^h(?:i|ello)$/.test(value);
     * }
     *
     * function customizer(objValue, othValue) {
     *   if (isGreeting(objValue) && isGreeting(othValue)) {
     *     return true;
     *   }
     * }
     *
     * var array = ['hello', 'goodbye'];
     * var other = ['hi', 'goodbye'];
     *
     * _.isEqualWith(array, other, customizer);
     * // => true
     */
    function isEqualWith(value, other, customizer) {
      customizer = typeof customizer == 'function' ? customizer : undefined;
      var result = customizer ? customizer(value, other) : undefined;
      return result === undefined ? baseIsEqual(value, other, undefined, customizer) : !!result;
    }

    /**
     * Checks if `value` is an `Error`, `EvalError`, `RangeError`, `ReferenceError`,
     * `SyntaxError`, `TypeError`, or `URIError` object.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an error object, else `false`.
     * @example
     *
     * _.isError(new Error);
     * // => true
     *
     * _.isError(Error);
     * // => false
     */
    function isError(value) {
      if (!isObjectLike(value)) {
        return false;
      }
      var tag = baseGetTag(value);
      return tag == errorTag || tag == domExcTag ||
        (typeof value.message == 'string' && typeof value.name == 'string' && !isPlainObject(value));
    }

    /**
     * Checks if `value` is a finite primitive number.
     *
     * **Note:** This method is based on
     * [`Number.isFinite`](https://mdn.io/Number/isFinite).
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a finite number, else `false`.
     * @example
     *
     * _.isFinite(3);
     * // => true
     *
     * _.isFinite(Number.MIN_VALUE);
     * // => true
     *
     * _.isFinite(Infinity);
     * // => false
     *
     * _.isFinite('3');
     * // => false
     */
    function isFinite(value) {
      return typeof value == 'number' && nativeIsFinite(value);
    }

    /**
     * Checks if `value` is classified as a `Function` object.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a function, else `false`.
     * @example
     *
     * _.isFunction(_);
     * // => true
     *
     * _.isFunction(/abc/);
     * // => false
     */
    function isFunction(value) {
      if (!isObject(value)) {
        return false;
      }
      // The use of `Object#toString` avoids issues with the `typeof` operator
      // in Safari 9 which returns 'object' for typed arrays and other constructors.
      var tag = baseGetTag(value);
      return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;
    }

    /**
     * Checks if `value` is an integer.
     *
     * **Note:** This method is based on
     * [`Number.isInteger`](https://mdn.io/Number/isInteger).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an integer, else `false`.
     * @example
     *
     * _.isInteger(3);
     * // => true
     *
     * _.isInteger(Number.MIN_VALUE);
     * // => false
     *
     * _.isInteger(Infinity);
     * // => false
     *
     * _.isInteger('3');
     * // => false
     */
    function isInteger(value) {
      return typeof value == 'number' && value == toInteger(value);
    }

    /**
     * Checks if `value` is a valid array-like length.
     *
     * **Note:** This method is loosely based on
     * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.
     * @example
     *
     * _.isLength(3);
     * // => true
     *
     * _.isLength(Number.MIN_VALUE);
     * // => false
     *
     * _.isLength(Infinity);
     * // => false
     *
     * _.isLength('3');
     * // => false
     */
    function isLength(value) {
      return typeof value == 'number' &&
        value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
    }

    /**
     * Checks if `value` is the
     * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
     * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is an object, else `false`.
     * @example
     *
     * _.isObject({});
     * // => true
     *
     * _.isObject([1, 2, 3]);
     * // => true
     *
     * _.isObject(_.noop);
     * // => true
     *
     * _.isObject(null);
     * // => false
     */
    function isObject(value) {
      var type = typeof value;
      return value != null && (type == 'object' || type == 'function');
    }

    /**
     * Checks if `value` is object-like. A value is object-like if it's not `null`
     * and has a `typeof` result of "object".
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is object-like, else `false`.
     * @example
     *
     * _.isObjectLike({});
     * // => true
     *
     * _.isObjectLike([1, 2, 3]);
     * // => true
     *
     * _.isObjectLike(_.noop);
     * // => false
     *
     * _.isObjectLike(null);
     * // => false
     */
    function isObjectLike(value) {
      return value != null && typeof value == 'object';
    }

    /**
     * Checks if `value` is classified as a `Map` object.
     *
     * @static
     * @memberOf _
     * @since 4.3.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a map, else `false`.
     * @example
     *
     * _.isMap(new Map);
     * // => true
     *
     * _.isMap(new WeakMap);
     * // => false
     */
    var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;

    /**
     * Performs a partial deep comparison between `object` and `source` to
     * determine if `object` contains equivalent property values.
     *
     * **Note:** This method is equivalent to `_.matches` when `source` is
     * partially applied.
     *
     * Partial comparisons will match empty array and empty object `source`
     * values against any array or object value, respectively. See `_.isEqual`
     * for a list of supported value comparisons.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Lang
     * @param {Object} object The object to inspect.
     * @param {Object} source The object of property values to match.
     * @returns {boolean} Returns `true` if `object` is a match, else `false`.
     * @example
     *
     * var object = { 'a': 1, 'b': 2 };
     *
     * _.isMatch(object, { 'b': 2 });
     * // => true
     *
     * _.isMatch(object, { 'b': 1 });
     * // => false
     */
    function isMatch(object, source) {
      return object === source || baseIsMatch(object, source, getMatchData(source));
    }

    /**
     * This method is like `_.isMatch` except that it accepts `customizer` which
     * is invoked to compare values. If `customizer` returns `undefined`, comparisons
     * are handled by the method instead. The `customizer` is invoked with five
     * arguments: (objValue, srcValue, index|key, object, source).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {Object} object The object to inspect.
     * @param {Object} source The object of property values to match.
     * @param {Function} [customizer] The function to customize comparisons.
     * @returns {boolean} Returns `true` if `object` is a match, else `false`.
     * @example
     *
     * function isGreeting(value) {
     *   return /^h(?:i|ello)$/.test(value);
     * }
     *
     * function customizer(objValue, srcValue) {
     *   if (isGreeting(objValue) && isGreeting(srcValue)) {
     *     return true;
     *   }
     * }
     *
     * var object = { 'greeting': 'hello' };
     * var source = { 'greeting': 'hi' };
     *
     * _.isMatchWith(object, source, customizer);
     * // => true
     */
    function isMatchWith(object, source, customizer) {
      customizer = typeof customizer == 'function' ? customizer : undefined;
      return baseIsMatch(object, source, getMatchData(source), customizer);
    }

    /**
     * Checks if `value` is `NaN`.
     *
     * **Note:** This method is based on
     * [`Number.isNaN`](https://mdn.io/Number/isNaN) and is not the same as
     * global [`isNaN`](https://mdn.io/isNaN) which returns `true` for
     * `undefined` and other non-number values.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.
     * @example
     *
     * _.isNaN(NaN);
     * // => true
     *
     * _.isNaN(new Number(NaN));
     * // => true
     *
     * isNaN(undefined);
     * // => true
     *
     * _.isNaN(undefined);
     * // => false
     */
    function isNaN(value) {
      // An `NaN` primitive is the only value that is not equal to itself.
      // Perform the `toStringTag` check first to avoid errors with some
      // ActiveX objects in IE.
      return isNumber(value) && value != +value;
    }

    /**
     * Checks if `value` is a pristine native function.
     *
     * **Note:** This method can't reliably detect native functions in the presence
     * of the core-js package because core-js circumvents this kind of detection.
     * Despite multiple requests, the core-js maintainer has made it clear: any
     * attempt to fix the detection will be obstructed. As a result, we're left
     * with little choice but to throw an error. Unfortunately, this also affects
     * packages, like [babel-polyfill](https://www.npmjs.com/package/babel-polyfill),
     * which rely on core-js.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a native function,
     *  else `false`.
     * @example
     *
     * _.isNative(Array.prototype.push);
     * // => true
     *
     * _.isNative(_);
     * // => false
     */
    function isNative(value) {
      if (isMaskable(value)) {
        throw new Error(CORE_ERROR_TEXT);
      }
      return baseIsNative(value);
    }

    /**
     * Checks if `value` is `null`.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is `null`, else `false`.
     * @example
     *
     * _.isNull(null);
     * // => true
     *
     * _.isNull(void 0);
     * // => false
     */
    function isNull(value) {
      return value === null;
    }

    /**
     * Checks if `value` is `null` or `undefined`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is nullish, else `false`.
     * @example
     *
     * _.isNil(null);
     * // => true
     *
     * _.isNil(void 0);
     * // => true
     *
     * _.isNil(NaN);
     * // => false
     */
    function isNil(value) {
      return value == null;
    }

    /**
     * Checks if `value` is classified as a `Number` primitive or object.
     *
     * **Note:** To exclude `Infinity`, `-Infinity`, and `NaN`, which are
     * classified as numbers, use the `_.isFinite` method.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a number, else `false`.
     * @example
     *
     * _.isNumber(3);
     * // => true
     *
     * _.isNumber(Number.MIN_VALUE);
     * // => true
     *
     * _.isNumber(Infinity);
     * // => true
     *
     * _.isNumber('3');
     * // => false
     */
    function isNumber(value) {
      return typeof value == 'number' ||
        (isObjectLike(value) && baseGetTag(value) == numberTag);
    }

    /**
     * Checks if `value` is a plain object, that is, an object created by the
     * `Object` constructor or one with a `[[Prototype]]` of `null`.
     *
     * @static
     * @memberOf _
     * @since 0.8.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     * }
     *
     * _.isPlainObject(new Foo);
     * // => false
     *
     * _.isPlainObject([1, 2, 3]);
     * // => false
     *
     * _.isPlainObject({ 'x': 0, 'y': 0 });
     * // => true
     *
     * _.isPlainObject(Object.create(null));
     * // => true
     */
    function isPlainObject(value) {
      if (!isObjectLike(value) || baseGetTag(value) != objectTag) {
        return false;
      }
      var proto = getPrototype(value);
      if (proto === null) {
        return true;
      }
      var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;
      return typeof Ctor == 'function' && Ctor instanceof Ctor &&
        funcToString.call(Ctor) == objectCtorString;
    }

    /**
     * Checks if `value` is classified as a `RegExp` object.
     *
     * @static
     * @memberOf _
     * @since 0.1.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a regexp, else `false`.
     * @example
     *
     * _.isRegExp(/abc/);
     * // => true
     *
     * _.isRegExp('/abc/');
     * // => false
     */
    var isRegExp = nodeIsRegExp ? baseUnary(nodeIsRegExp) : baseIsRegExp;

    /**
     * Checks if `value` is a safe integer. An integer is safe if it's an IEEE-754
     * double precision number which isn't the result of a rounded unsafe integer.
     *
     * **Note:** This method is based on
     * [`Number.isSafeInteger`](https://mdn.io/Number/isSafeInteger).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a safe integer, else `false`.
     * @example
     *
     * _.isSafeInteger(3);
     * // => true
     *
     * _.isSafeInteger(Number.MIN_VALUE);
     * // => false
     *
     * _.isSafeInteger(Infinity);
     * // => false
     *
     * _.isSafeInteger('3');
     * // => false
     */
    function isSafeInteger(value) {
      return isInteger(value) && value >= -MAX_SAFE_INTEGER && value <= MAX_SAFE_INTEGER;
    }

    /**
     * Checks if `value` is classified as a `Set` object.
     *
     * @static
     * @memberOf _
     * @since 4.3.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a set, else `false`.
     * @example
     *
     * _.isSet(new Set);
     * // => true
     *
     * _.isSet(new WeakSet);
     * // => false
     */
    var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;

    /**
     * Checks if `value` is classified as a `String` primitive or object.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a string, else `false`.
     * @example
     *
     * _.isString('abc');
     * // => true
     *
     * _.isString(1);
     * // => false
     */
    function isString(value) {
      return typeof value == 'string' ||
        (!isArray(value) && isObjectLike(value) && baseGetTag(value) == stringTag);
    }

    /**
     * Checks if `value` is classified as a `Symbol` primitive or object.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
     * @example
     *
     * _.isSymbol(Symbol.iterator);
     * // => true
     *
     * _.isSymbol('abc');
     * // => false
     */
    function isSymbol(value) {
      return typeof value == 'symbol' ||
        (isObjectLike(value) && baseGetTag(value) == symbolTag);
    }

    /**
     * Checks if `value` is classified as a typed array.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.
     * @example
     *
     * _.isTypedArray(new Uint8Array);
     * // => true
     *
     * _.isTypedArray([]);
     * // => false
     */
    var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;

    /**
     * Checks if `value` is `undefined`.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is `undefined`, else `false`.
     * @example
     *
     * _.isUndefined(void 0);
     * // => true
     *
     * _.isUndefined(null);
     * // => false
     */
    function isUndefined(value) {
      return value === undefined;
    }

    /**
     * Checks if `value` is classified as a `WeakMap` object.
     *
     * @static
     * @memberOf _
     * @since 4.3.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a weak map, else `false`.
     * @example
     *
     * _.isWeakMap(new WeakMap);
     * // => true
     *
     * _.isWeakMap(new Map);
     * // => false
     */
    function isWeakMap(value) {
      return isObjectLike(value) && getTag(value) == weakMapTag;
    }

    /**
     * Checks if `value` is classified as a `WeakSet` object.
     *
     * @static
     * @memberOf _
     * @since 4.3.0
     * @category Lang
     * @param {*} value The value to check.
     * @returns {boolean} Returns `true` if `value` is a weak set, else `false`.
     * @example
     *
     * _.isWeakSet(new WeakSet);
     * // => true
     *
     * _.isWeakSet(new Set);
     * // => false
     */
    function isWeakSet(value) {
      return isObjectLike(value) && baseGetTag(value) == weakSetTag;
    }

    /**
     * Checks if `value` is less than `other`.
     *
     * @static
     * @memberOf _
     * @since 3.9.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if `value` is less than `other`,
     *  else `false`.
     * @see _.gt
     * @example
     *
     * _.lt(1, 3);
     * // => true
     *
     * _.lt(3, 3);
     * // => false
     *
     * _.lt(3, 1);
     * // => false
     */
    var lt = createRelationalOperation(baseLt);

    /**
     * Checks if `value` is less than or equal to `other`.
     *
     * @static
     * @memberOf _
     * @since 3.9.0
     * @category Lang
     * @param {*} value The value to compare.
     * @param {*} other The other value to compare.
     * @returns {boolean} Returns `true` if `value` is less than or equal to
     *  `other`, else `false`.
     * @see _.gte
     * @example
     *
     * _.lte(1, 3);
     * // => true
     *
     * _.lte(3, 3);
     * // => true
     *
     * _.lte(3, 1);
     * // => false
     */
    var lte = createRelationalOperation(function(value, other) {
      return value <= other;
    });

    /**
     * Converts `value` to an array.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {Array} Returns the converted array.
     * @example
     *
     * _.toArray({ 'a': 1, 'b': 2 });
     * // => [1, 2]
     *
     * _.toArray('abc');
     * // => ['a', 'b', 'c']
     *
     * _.toArray(1);
     * // => []
     *
     * _.toArray(null);
     * // => []
     */
    function toArray(value) {
      if (!value) {
        return [];
      }
      if (isArrayLike(value)) {
        return isString(value) ? stringToArray(value) : copyArray(value);
      }
      if (symIterator && value[symIterator]) {
        return iteratorToArray(value[symIterator]());
      }
      var tag = getTag(value),
          func = tag == mapTag ? mapToArray : (tag == setTag ? setToArray : values);

      return func(value);
    }

    /**
     * Converts `value` to a finite number.
     *
     * @static
     * @memberOf _
     * @since 4.12.0
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {number} Returns the converted number.
     * @example
     *
     * _.toFinite(3.2);
     * // => 3.2
     *
     * _.toFinite(Number.MIN_VALUE);
     * // => 5e-324
     *
     * _.toFinite(Infinity);
     * // => 1.7976931348623157e+308
     *
     * _.toFinite('3.2');
     * // => 3.2
     */
    function toFinite(value) {
      if (!value) {
        return value === 0 ? value : 0;
      }
      value = toNumber(value);
      if (value === INFINITY || value === -INFINITY) {
        var sign = (value < 0 ? -1 : 1);
        return sign * MAX_INTEGER;
      }
      return value === value ? value : 0;
    }

    /**
     * Converts `value` to an integer.
     *
     * **Note:** This method is loosely based on
     * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {number} Returns the converted integer.
     * @example
     *
     * _.toInteger(3.2);
     * // => 3
     *
     * _.toInteger(Number.MIN_VALUE);
     * // => 0
     *
     * _.toInteger(Infinity);
     * // => 1.7976931348623157e+308
     *
     * _.toInteger('3.2');
     * // => 3
     */
    function toInteger(value) {
      var result = toFinite(value),
          remainder = result % 1;

      return result === result ? (remainder ? result - remainder : result) : 0;
    }

    /**
     * Converts `value` to an integer suitable for use as the length of an
     * array-like object.
     *
     * **Note:** This method is based on
     * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {number} Returns the converted integer.
     * @example
     *
     * _.toLength(3.2);
     * // => 3
     *
     * _.toLength(Number.MIN_VALUE);
     * // => 0
     *
     * _.toLength(Infinity);
     * // => 4294967295
     *
     * _.toLength('3.2');
     * // => 3
     */
    function toLength(value) {
      return value ? baseClamp(toInteger(value), 0, MAX_ARRAY_LENGTH) : 0;
    }

    /**
     * Converts `value` to a number.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to process.
     * @returns {number} Returns the number.
     * @example
     *
     * _.toNumber(3.2);
     * // => 3.2
     *
     * _.toNumber(Number.MIN_VALUE);
     * // => 5e-324
     *
     * _.toNumber(Infinity);
     * // => Infinity
     *
     * _.toNumber('3.2');
     * // => 3.2
     */
    function toNumber(value) {
      if (typeof value == 'number') {
        return value;
      }
      if (isSymbol(value)) {
        return NAN;
      }
      if (isObject(value)) {
        var other = typeof value.valueOf == 'function' ? value.valueOf() : value;
        value = isObject(other) ? (other + '') : other;
      }
      if (typeof value != 'string') {
        return value === 0 ? value : +value;
      }
      value = value.replace(reTrim, '');
      var isBinary = reIsBinary.test(value);
      return (isBinary || reIsOctal.test(value))
        ? freeParseInt(value.slice(2), isBinary ? 2 : 8)
        : (reIsBadHex.test(value) ? NAN : +value);
    }

    /**
     * Converts `value` to a plain object flattening inherited enumerable string
     * keyed properties of `value` to own properties of the plain object.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {Object} Returns the converted plain object.
     * @example
     *
     * function Foo() {
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.assign({ 'a': 1 }, new Foo);
     * // => { 'a': 1, 'b': 2 }
     *
     * _.assign({ 'a': 1 }, _.toPlainObject(new Foo));
     * // => { 'a': 1, 'b': 2, 'c': 3 }
     */
    function toPlainObject(value) {
      return copyObject(value, keysIn(value));
    }

    /**
     * Converts `value` to a safe integer. A safe integer can be compared and
     * represented correctly.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {number} Returns the converted integer.
     * @example
     *
     * _.toSafeInteger(3.2);
     * // => 3
     *
     * _.toSafeInteger(Number.MIN_VALUE);
     * // => 0
     *
     * _.toSafeInteger(Infinity);
     * // => 9007199254740991
     *
     * _.toSafeInteger('3.2');
     * // => 3
     */
    function toSafeInteger(value) {
      return value
        ? baseClamp(toInteger(value), -MAX_SAFE_INTEGER, MAX_SAFE_INTEGER)
        : (value === 0 ? value : 0);
    }

    /**
     * Converts `value` to a string. An empty string is returned for `null`
     * and `undefined` values. The sign of `-0` is preserved.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Lang
     * @param {*} value The value to convert.
     * @returns {string} Returns the converted string.
     * @example
     *
     * _.toString(null);
     * // => ''
     *
     * _.toString(-0);
     * // => '-0'
     *
     * _.toString([1, 2, 3]);
     * // => '1,2,3'
     */
    function toString(value) {
      return value == null ? '' : baseToString(value);
    }

    /*------------------------------------------------------------------------*/

    /**
     * Assigns own enumerable string keyed properties of source objects to the
     * destination object. Source objects are applied from left to right.
     * Subsequent sources overwrite property assignments of previous sources.
     *
     * **Note:** This method mutates `object` and is loosely based on
     * [`Object.assign`](https://mdn.io/Object/assign).
     *
     * @static
     * @memberOf _
     * @since 0.10.0
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} [sources] The source objects.
     * @returns {Object} Returns `object`.
     * @see _.assignIn
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     * }
     *
     * function Bar() {
     *   this.c = 3;
     * }
     *
     * Foo.prototype.b = 2;
     * Bar.prototype.d = 4;
     *
     * _.assign({ 'a': 0 }, new Foo, new Bar);
     * // => { 'a': 1, 'c': 3 }
     */
    var assign = createAssigner(function(object, source) {
      if (isPrototype(source) || isArrayLike(source)) {
        copyObject(source, keys(source), object);
        return;
      }
      for (var key in source) {
        if (hasOwnProperty.call(source, key)) {
          assignValue(object, key, source[key]);
        }
      }
    });

    /**
     * This method is like `_.assign` except that it iterates over own and
     * inherited source properties.
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @alias extend
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} [sources] The source objects.
     * @returns {Object} Returns `object`.
     * @see _.assign
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     * }
     *
     * function Bar() {
     *   this.c = 3;
     * }
     *
     * Foo.prototype.b = 2;
     * Bar.prototype.d = 4;
     *
     * _.assignIn({ 'a': 0 }, new Foo, new Bar);
     * // => { 'a': 1, 'b': 2, 'c': 3, 'd': 4 }
     */
    var assignIn = createAssigner(function(object, source) {
      copyObject(source, keysIn(source), object);
    });

    /**
     * This method is like `_.assignIn` except that it accepts `customizer`
     * which is invoked to produce the assigned values. If `customizer` returns
     * `undefined`, assignment is handled by the method instead. The `customizer`
     * is invoked with five arguments: (objValue, srcValue, key, object, source).
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @alias extendWith
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} sources The source objects.
     * @param {Function} [customizer] The function to customize assigned values.
     * @returns {Object} Returns `object`.
     * @see _.assignWith
     * @example
     *
     * function customizer(objValue, srcValue) {
     *   return _.isUndefined(objValue) ? srcValue : objValue;
     * }
     *
     * var defaults = _.partialRight(_.assignInWith, customizer);
     *
     * defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });
     * // => { 'a': 1, 'b': 2 }
     */
    var assignInWith = createAssigner(function(object, source, srcIndex, customizer) {
      copyObject(source, keysIn(source), object, customizer);
    });

    /**
     * This method is like `_.assign` except that it accepts `customizer`
     * which is invoked to produce the assigned values. If `customizer` returns
     * `undefined`, assignment is handled by the method instead. The `customizer`
     * is invoked with five arguments: (objValue, srcValue, key, object, source).
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} sources The source objects.
     * @param {Function} [customizer] The function to customize assigned values.
     * @returns {Object} Returns `object`.
     * @see _.assignInWith
     * @example
     *
     * function customizer(objValue, srcValue) {
     *   return _.isUndefined(objValue) ? srcValue : objValue;
     * }
     *
     * var defaults = _.partialRight(_.assignWith, customizer);
     *
     * defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });
     * // => { 'a': 1, 'b': 2 }
     */
    var assignWith = createAssigner(function(object, source, srcIndex, customizer) {
      copyObject(source, keys(source), object, customizer);
    });

    /**
     * Creates an array of values corresponding to `paths` of `object`.
     *
     * @static
     * @memberOf _
     * @since 1.0.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {...(string|string[])} [paths] The property paths to pick.
     * @returns {Array} Returns the picked values.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] };
     *
     * _.at(object, ['a[0].b.c', 'a[1]']);
     * // => [3, 4]
     */
    var at = flatRest(baseAt);

    /**
     * Creates an object that inherits from the `prototype` object. If a
     * `properties` object is given, its own enumerable string keyed properties
     * are assigned to the created object.
     *
     * @static
     * @memberOf _
     * @since 2.3.0
     * @category Object
     * @param {Object} prototype The object to inherit from.
     * @param {Object} [properties] The properties to assign to the object.
     * @returns {Object} Returns the new object.
     * @example
     *
     * function Shape() {
     *   this.x = 0;
     *   this.y = 0;
     * }
     *
     * function Circle() {
     *   Shape.call(this);
     * }
     *
     * Circle.prototype = _.create(Shape.prototype, {
     *   'constructor': Circle
     * });
     *
     * var circle = new Circle;
     * circle instanceof Circle;
     * // => true
     *
     * circle instanceof Shape;
     * // => true
     */
    function create(prototype, properties) {
      var result = baseCreate(prototype);
      return properties == null ? result : baseAssign(result, properties);
    }

    /**
     * Assigns own and inherited enumerable string keyed properties of source
     * objects to the destination object for all destination properties that
     * resolve to `undefined`. Source objects are applied from left to right.
     * Once a property is set, additional values of the same property are ignored.
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} [sources] The source objects.
     * @returns {Object} Returns `object`.
     * @see _.defaultsDeep
     * @example
     *
     * _.defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });
     * // => { 'a': 1, 'b': 2 }
     */
    var defaults = baseRest(function(object, sources) {
      object = Object(object);

      var index = -1;
      var length = sources.length;
      var guard = length > 2 ? sources[2] : undefined;

      if (guard && isIterateeCall(sources[0], sources[1], guard)) {
        length = 1;
      }

      while (++index < length) {
        var source = sources[index];
        var props = keysIn(source);
        var propsIndex = -1;
        var propsLength = props.length;

        while (++propsIndex < propsLength) {
          var key = props[propsIndex];
          var value = object[key];

          if (value === undefined ||
              (eq(value, objectProto[key]) && !hasOwnProperty.call(object, key))) {
            object[key] = source[key];
          }
        }
      }

      return object;
    });

    /**
     * This method is like `_.defaults` except that it recursively assigns
     * default properties.
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 3.10.0
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} [sources] The source objects.
     * @returns {Object} Returns `object`.
     * @see _.defaults
     * @example
     *
     * _.defaultsDeep({ 'a': { 'b': 2 } }, { 'a': { 'b': 1, 'c': 3 } });
     * // => { 'a': { 'b': 2, 'c': 3 } }
     */
    var defaultsDeep = baseRest(function(args) {
      args.push(undefined, customDefaultsMerge);
      return apply(mergeWith, undefined, args);
    });

    /**
     * This method is like `_.find` except that it returns the key of the first
     * element `predicate` returns truthy for instead of the element itself.
     *
     * @static
     * @memberOf _
     * @since 1.1.0
     * @category Object
     * @param {Object} object The object to inspect.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {string|undefined} Returns the key of the matched element,
     *  else `undefined`.
     * @example
     *
     * var users = {
     *   'barney':  { 'age': 36, 'active': true },
     *   'fred':    { 'age': 40, 'active': false },
     *   'pebbles': { 'age': 1,  'active': true }
     * };
     *
     * _.findKey(users, function(o) { return o.age < 40; });
     * // => 'barney' (iteration order is not guaranteed)
     *
     * // The `_.matches` iteratee shorthand.
     * _.findKey(users, { 'age': 1, 'active': true });
     * // => 'pebbles'
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.findKey(users, ['active', false]);
     * // => 'fred'
     *
     * // The `_.property` iteratee shorthand.
     * _.findKey(users, 'active');
     * // => 'barney'
     */
    function findKey(object, predicate) {
      return baseFindKey(object, getIteratee(predicate, 3), baseForOwn);
    }

    /**
     * This method is like `_.findKey` except that it iterates over elements of
     * a collection in the opposite order.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Object
     * @param {Object} object The object to inspect.
     * @param {Function} [predicate=_.identity] The function invoked per iteration.
     * @returns {string|undefined} Returns the key of the matched element,
     *  else `undefined`.
     * @example
     *
     * var users = {
     *   'barney':  { 'age': 36, 'active': true },
     *   'fred':    { 'age': 40, 'active': false },
     *   'pebbles': { 'age': 1,  'active': true }
     * };
     *
     * _.findLastKey(users, function(o) { return o.age < 40; });
     * // => returns 'pebbles' assuming `_.findKey` returns 'barney'
     *
     * // The `_.matches` iteratee shorthand.
     * _.findLastKey(users, { 'age': 36, 'active': true });
     * // => 'barney'
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.findLastKey(users, ['active', false]);
     * // => 'fred'
     *
     * // The `_.property` iteratee shorthand.
     * _.findLastKey(users, 'active');
     * // => 'pebbles'
     */
    function findLastKey(object, predicate) {
      return baseFindKey(object, getIteratee(predicate, 3), baseForOwnRight);
    }

    /**
     * Iterates over own and inherited enumerable string keyed properties of an
     * object and invokes `iteratee` for each property. The iteratee is invoked
     * with three arguments: (value, key, object). Iteratee functions may exit
     * iteration early by explicitly returning `false`.
     *
     * @static
     * @memberOf _
     * @since 0.3.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Object} Returns `object`.
     * @see _.forInRight
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.forIn(new Foo, function(value, key) {
     *   console.log(key);
     * });
     * // => Logs 'a', 'b', then 'c' (iteration order is not guaranteed).
     */
    function forIn(object, iteratee) {
      return object == null
        ? object
        : baseFor(object, getIteratee(iteratee, 3), keysIn);
    }

    /**
     * This method is like `_.forIn` except that it iterates over properties of
     * `object` in the opposite order.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Object} Returns `object`.
     * @see _.forIn
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.forInRight(new Foo, function(value, key) {
     *   console.log(key);
     * });
     * // => Logs 'c', 'b', then 'a' assuming `_.forIn` logs 'a', 'b', then 'c'.
     */
    function forInRight(object, iteratee) {
      return object == null
        ? object
        : baseForRight(object, getIteratee(iteratee, 3), keysIn);
    }

    /**
     * Iterates over own enumerable string keyed properties of an object and
     * invokes `iteratee` for each property. The iteratee is invoked with three
     * arguments: (value, key, object). Iteratee functions may exit iteration
     * early by explicitly returning `false`.
     *
     * @static
     * @memberOf _
     * @since 0.3.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Object} Returns `object`.
     * @see _.forOwnRight
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.forOwn(new Foo, function(value, key) {
     *   console.log(key);
     * });
     * // => Logs 'a' then 'b' (iteration order is not guaranteed).
     */
    function forOwn(object, iteratee) {
      return object && baseForOwn(object, getIteratee(iteratee, 3));
    }

    /**
     * This method is like `_.forOwn` except that it iterates over properties of
     * `object` in the opposite order.
     *
     * @static
     * @memberOf _
     * @since 2.0.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Object} Returns `object`.
     * @see _.forOwn
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.forOwnRight(new Foo, function(value, key) {
     *   console.log(key);
     * });
     * // => Logs 'b' then 'a' assuming `_.forOwn` logs 'a' then 'b'.
     */
    function forOwnRight(object, iteratee) {
      return object && baseForOwnRight(object, getIteratee(iteratee, 3));
    }

    /**
     * Creates an array of function property names from own enumerable properties
     * of `object`.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The object to inspect.
     * @returns {Array} Returns the function names.
     * @see _.functionsIn
     * @example
     *
     * function Foo() {
     *   this.a = _.constant('a');
     *   this.b = _.constant('b');
     * }
     *
     * Foo.prototype.c = _.constant('c');
     *
     * _.functions(new Foo);
     * // => ['a', 'b']
     */
    function functions(object) {
      return object == null ? [] : baseFunctions(object, keys(object));
    }

    /**
     * Creates an array of function property names from own and inherited
     * enumerable properties of `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The object to inspect.
     * @returns {Array} Returns the function names.
     * @see _.functions
     * @example
     *
     * function Foo() {
     *   this.a = _.constant('a');
     *   this.b = _.constant('b');
     * }
     *
     * Foo.prototype.c = _.constant('c');
     *
     * _.functionsIn(new Foo);
     * // => ['a', 'b', 'c']
     */
    function functionsIn(object) {
      return object == null ? [] : baseFunctions(object, keysIn(object));
    }

    /**
     * Gets the value at `path` of `object`. If the resolved value is
     * `undefined`, the `defaultValue` is returned in its place.
     *
     * @static
     * @memberOf _
     * @since 3.7.0
     * @category Object
     * @param {Object} object The object to query.
     * @param {Array|string} path The path of the property to get.
     * @param {*} [defaultValue] The value returned for `undefined` resolved values.
     * @returns {*} Returns the resolved value.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': 3 } }] };
     *
     * _.get(object, 'a[0].b.c');
     * // => 3
     *
     * _.get(object, ['a', '0', 'b', 'c']);
     * // => 3
     *
     * _.get(object, 'a.b.c', 'default');
     * // => 'default'
     */
    function get(object, path, defaultValue) {
      var result = object == null ? undefined : baseGet(object, path);
      return result === undefined ? defaultValue : result;
    }

    /**
     * Checks if `path` is a direct property of `object`.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The object to query.
     * @param {Array|string} path The path to check.
     * @returns {boolean} Returns `true` if `path` exists, else `false`.
     * @example
     *
     * var object = { 'a': { 'b': 2 } };
     * var other = _.create({ 'a': _.create({ 'b': 2 }) });
     *
     * _.has(object, 'a');
     * // => true
     *
     * _.has(object, 'a.b');
     * // => true
     *
     * _.has(object, ['a', 'b']);
     * // => true
     *
     * _.has(other, 'a');
     * // => false
     */
    function has(object, path) {
      return object != null && hasPath(object, path, baseHas);
    }

    /**
     * Checks if `path` is a direct or inherited property of `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The object to query.
     * @param {Array|string} path The path to check.
     * @returns {boolean} Returns `true` if `path` exists, else `false`.
     * @example
     *
     * var object = _.create({ 'a': _.create({ 'b': 2 }) });
     *
     * _.hasIn(object, 'a');
     * // => true
     *
     * _.hasIn(object, 'a.b');
     * // => true
     *
     * _.hasIn(object, ['a', 'b']);
     * // => true
     *
     * _.hasIn(object, 'b');
     * // => false
     */
    function hasIn(object, path) {
      return object != null && hasPath(object, path, baseHasIn);
    }

    /**
     * Creates an object composed of the inverted keys and values of `object`.
     * If `object` contains duplicate values, subsequent values overwrite
     * property assignments of previous values.
     *
     * @static
     * @memberOf _
     * @since 0.7.0
     * @category Object
     * @param {Object} object The object to invert.
     * @returns {Object} Returns the new inverted object.
     * @example
     *
     * var object = { 'a': 1, 'b': 2, 'c': 1 };
     *
     * _.invert(object);
     * // => { '1': 'c', '2': 'b' }
     */
    var invert = createInverter(function(result, value, key) {
      if (value != null &&
          typeof value.toString != 'function') {
        value = nativeObjectToString.call(value);
      }

      result[value] = key;
    }, constant(identity));

    /**
     * This method is like `_.invert` except that the inverted object is generated
     * from the results of running each element of `object` thru `iteratee`. The
     * corresponding inverted value of each inverted key is an array of keys
     * responsible for generating the inverted value. The iteratee is invoked
     * with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.1.0
     * @category Object
     * @param {Object} object The object to invert.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {Object} Returns the new inverted object.
     * @example
     *
     * var object = { 'a': 1, 'b': 2, 'c': 1 };
     *
     * _.invertBy(object);
     * // => { '1': ['a', 'c'], '2': ['b'] }
     *
     * _.invertBy(object, function(value) {
     *   return 'group' + value;
     * });
     * // => { 'group1': ['a', 'c'], 'group2': ['b'] }
     */
    var invertBy = createInverter(function(result, value, key) {
      if (value != null &&
          typeof value.toString != 'function') {
        value = nativeObjectToString.call(value);
      }

      if (hasOwnProperty.call(result, value)) {
        result[value].push(key);
      } else {
        result[value] = [key];
      }
    }, getIteratee);

    /**
     * Invokes the method at `path` of `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The object to query.
     * @param {Array|string} path The path of the method to invoke.
     * @param {...*} [args] The arguments to invoke the method with.
     * @returns {*} Returns the result of the invoked method.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': [1, 2, 3, 4] } }] };
     *
     * _.invoke(object, 'a[0].b.c.slice', 1, 3);
     * // => [2, 3]
     */
    var invoke = baseRest(baseInvoke);

    /**
     * Creates an array of the own enumerable property names of `object`.
     *
     * **Note:** Non-object values are coerced to objects. See the
     * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)
     * for more details.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.keys(new Foo);
     * // => ['a', 'b'] (iteration order is not guaranteed)
     *
     * _.keys('hi');
     * // => ['0', '1']
     */
    function keys(object) {
      return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
    }

    /**
     * Creates an array of the own and inherited enumerable property names of `object`.
     *
     * **Note:** Non-object values are coerced to objects.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Object
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property names.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.keysIn(new Foo);
     * // => ['a', 'b', 'c'] (iteration order is not guaranteed)
     */
    function keysIn(object) {
      return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
    }

    /**
     * The opposite of `_.mapValues`; this method creates an object with the
     * same values as `object` and keys generated by running each own enumerable
     * string keyed property of `object` thru `iteratee`. The iteratee is invoked
     * with three arguments: (value, key, object).
     *
     * @static
     * @memberOf _
     * @since 3.8.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Object} Returns the new mapped object.
     * @see _.mapValues
     * @example
     *
     * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {
     *   return key + value;
     * });
     * // => { 'a1': 1, 'b2': 2 }
     */
    function mapKeys(object, iteratee) {
      var result = {};
      iteratee = getIteratee(iteratee, 3);

      baseForOwn(object, function(value, key, object) {
        baseAssignValue(result, iteratee(value, key, object), value);
      });
      return result;
    }

    /**
     * Creates an object with the same keys as `object` and values generated
     * by running each own enumerable string keyed property of `object` thru
     * `iteratee`. The iteratee is invoked with three arguments:
     * (value, key, object).
     *
     * @static
     * @memberOf _
     * @since 2.4.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Object} Returns the new mapped object.
     * @see _.mapKeys
     * @example
     *
     * var users = {
     *   'fred':    { 'user': 'fred',    'age': 40 },
     *   'pebbles': { 'user': 'pebbles', 'age': 1 }
     * };
     *
     * _.mapValues(users, function(o) { return o.age; });
     * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)
     *
     * // The `_.property` iteratee shorthand.
     * _.mapValues(users, 'age');
     * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)
     */
    function mapValues(object, iteratee) {
      var result = {};
      iteratee = getIteratee(iteratee, 3);

      baseForOwn(object, function(value, key, object) {
        baseAssignValue(result, key, iteratee(value, key, object));
      });
      return result;
    }

    /**
     * This method is like `_.assign` except that it recursively merges own and
     * inherited enumerable string keyed properties of source objects into the
     * destination object. Source properties that resolve to `undefined` are
     * skipped if a destination value exists. Array and plain object properties
     * are merged recursively. Other objects and value types are overridden by
     * assignment. Source objects are applied from left to right. Subsequent
     * sources overwrite property assignments of previous sources.
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 0.5.0
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} [sources] The source objects.
     * @returns {Object} Returns `object`.
     * @example
     *
     * var object = {
     *   'a': [{ 'b': 2 }, { 'd': 4 }]
     * };
     *
     * var other = {
     *   'a': [{ 'c': 3 }, { 'e': 5 }]
     * };
     *
     * _.merge(object, other);
     * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] }
     */
    var merge = createAssigner(function(object, source, srcIndex) {
      baseMerge(object, source, srcIndex);
    });

    /**
     * This method is like `_.merge` except that it accepts `customizer` which
     * is invoked to produce the merged values of the destination and source
     * properties. If `customizer` returns `undefined`, merging is handled by the
     * method instead. The `customizer` is invoked with six arguments:
     * (objValue, srcValue, key, object, source, stack).
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The destination object.
     * @param {...Object} sources The source objects.
     * @param {Function} customizer The function to customize assigned values.
     * @returns {Object} Returns `object`.
     * @example
     *
     * function customizer(objValue, srcValue) {
     *   if (_.isArray(objValue)) {
     *     return objValue.concat(srcValue);
     *   }
     * }
     *
     * var object = { 'a': [1], 'b': [2] };
     * var other = { 'a': [3], 'b': [4] };
     *
     * _.mergeWith(object, other, customizer);
     * // => { 'a': [1, 3], 'b': [2, 4] }
     */
    var mergeWith = createAssigner(function(object, source, srcIndex, customizer) {
      baseMerge(object, source, srcIndex, customizer);
    });

    /**
     * The opposite of `_.pick`; this method creates an object composed of the
     * own and inherited enumerable property paths of `object` that are not omitted.
     *
     * **Note:** This method is considerably slower than `_.pick`.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The source object.
     * @param {...(string|string[])} [paths] The property paths to omit.
     * @returns {Object} Returns the new object.
     * @example
     *
     * var object = { 'a': 1, 'b': '2', 'c': 3 };
     *
     * _.omit(object, ['a', 'c']);
     * // => { 'b': '2' }
     */
    var omit = flatRest(function(object, paths) {
      var result = {};
      if (object == null) {
        return result;
      }
      var isDeep = false;
      paths = arrayMap(paths, function(path) {
        path = castPath(path, object);
        isDeep || (isDeep = path.length > 1);
        return path;
      });
      copyObject(object, getAllKeysIn(object), result);
      if (isDeep) {
        result = baseClone(result, CLONE_DEEP_FLAG | CLONE_FLAT_FLAG | CLONE_SYMBOLS_FLAG, customOmitClone);
      }
      var length = paths.length;
      while (length--) {
        baseUnset(result, paths[length]);
      }
      return result;
    });

    /**
     * The opposite of `_.pickBy`; this method creates an object composed of
     * the own and inherited enumerable string keyed properties of `object` that
     * `predicate` doesn't return truthy for. The predicate is invoked with two
     * arguments: (value, key).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The source object.
     * @param {Function} [predicate=_.identity] The function invoked per property.
     * @returns {Object} Returns the new object.
     * @example
     *
     * var object = { 'a': 1, 'b': '2', 'c': 3 };
     *
     * _.omitBy(object, _.isNumber);
     * // => { 'b': '2' }
     */
    function omitBy(object, predicate) {
      return pickBy(object, negate(getIteratee(predicate)));
    }

    /**
     * Creates an object composed of the picked `object` properties.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The source object.
     * @param {...(string|string[])} [paths] The property paths to pick.
     * @returns {Object} Returns the new object.
     * @example
     *
     * var object = { 'a': 1, 'b': '2', 'c': 3 };
     *
     * _.pick(object, ['a', 'c']);
     * // => { 'a': 1, 'c': 3 }
     */
    var pick = flatRest(function(object, paths) {
      return object == null ? {} : basePick(object, paths);
    });

    /**
     * Creates an object composed of the `object` properties `predicate` returns
     * truthy for. The predicate is invoked with two arguments: (value, key).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The source object.
     * @param {Function} [predicate=_.identity] The function invoked per property.
     * @returns {Object} Returns the new object.
     * @example
     *
     * var object = { 'a': 1, 'b': '2', 'c': 3 };
     *
     * _.pickBy(object, _.isNumber);
     * // => { 'a': 1, 'c': 3 }
     */
    function pickBy(object, predicate) {
      if (object == null) {
        return {};
      }
      var props = arrayMap(getAllKeysIn(object), function(prop) {
        return [prop];
      });
      predicate = getIteratee(predicate);
      return basePickBy(object, props, function(value, path) {
        return predicate(value, path[0]);
      });
    }

    /**
     * This method is like `_.get` except that if the resolved value is a
     * function it's invoked with the `this` binding of its parent object and
     * its result is returned.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The object to query.
     * @param {Array|string} path The path of the property to resolve.
     * @param {*} [defaultValue] The value returned for `undefined` resolved values.
     * @returns {*} Returns the resolved value.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c1': 3, 'c2': _.constant(4) } }] };
     *
     * _.result(object, 'a[0].b.c1');
     * // => 3
     *
     * _.result(object, 'a[0].b.c2');
     * // => 4
     *
     * _.result(object, 'a[0].b.c3', 'default');
     * // => 'default'
     *
     * _.result(object, 'a[0].b.c3', _.constant('default'));
     * // => 'default'
     */
    function result(object, path, defaultValue) {
      path = castPath(path, object);

      var index = -1,
          length = path.length;

      // Ensure the loop is entered when path is empty.
      if (!length) {
        length = 1;
        object = undefined;
      }
      while (++index < length) {
        var value = object == null ? undefined : object[toKey(path[index])];
        if (value === undefined) {
          index = length;
          value = defaultValue;
        }
        object = isFunction(value) ? value.call(object) : value;
      }
      return object;
    }

    /**
     * Sets the value at `path` of `object`. If a portion of `path` doesn't exist,
     * it's created. Arrays are created for missing index properties while objects
     * are created for all other missing properties. Use `_.setWith` to customize
     * `path` creation.
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 3.7.0
     * @category Object
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to set.
     * @param {*} value The value to set.
     * @returns {Object} Returns `object`.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': 3 } }] };
     *
     * _.set(object, 'a[0].b.c', 4);
     * console.log(object.a[0].b.c);
     * // => 4
     *
     * _.set(object, ['x', '0', 'y', 'z'], 5);
     * console.log(object.x[0].y.z);
     * // => 5
     */
    function set(object, path, value) {
      return object == null ? object : baseSet(object, path, value);
    }

    /**
     * This method is like `_.set` except that it accepts `customizer` which is
     * invoked to produce the objects of `path`.  If `customizer` returns `undefined`
     * path creation is handled by the method instead. The `customizer` is invoked
     * with three arguments: (nsValue, key, nsObject).
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to set.
     * @param {*} value The value to set.
     * @param {Function} [customizer] The function to customize assigned values.
     * @returns {Object} Returns `object`.
     * @example
     *
     * var object = {};
     *
     * _.setWith(object, '[0][1]', 'a', Object);
     * // => { '0': { '1': 'a' } }
     */
    function setWith(object, path, value, customizer) {
      customizer = typeof customizer == 'function' ? customizer : undefined;
      return object == null ? object : baseSet(object, path, value, customizer);
    }

    /**
     * Creates an array of own enumerable string keyed-value pairs for `object`
     * which can be consumed by `_.fromPairs`. If `object` is a map or set, its
     * entries are returned.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @alias entries
     * @category Object
     * @param {Object} object The object to query.
     * @returns {Array} Returns the key-value pairs.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.toPairs(new Foo);
     * // => [['a', 1], ['b', 2]] (iteration order is not guaranteed)
     */
    var toPairs = createToPairs(keys);

    /**
     * Creates an array of own and inherited enumerable string keyed-value pairs
     * for `object` which can be consumed by `_.fromPairs`. If `object` is a map
     * or set, its entries are returned.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @alias entriesIn
     * @category Object
     * @param {Object} object The object to query.
     * @returns {Array} Returns the key-value pairs.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.toPairsIn(new Foo);
     * // => [['a', 1], ['b', 2], ['c', 3]] (iteration order is not guaranteed)
     */
    var toPairsIn = createToPairs(keysIn);

    /**
     * An alternative to `_.reduce`; this method transforms `object` to a new
     * `accumulator` object which is the result of running each of its own
     * enumerable string keyed properties thru `iteratee`, with each invocation
     * potentially mutating the `accumulator` object. If `accumulator` is not
     * provided, a new object with the same `[[Prototype]]` will be used. The
     * iteratee is invoked with four arguments: (accumulator, value, key, object).
     * Iteratee functions may exit iteration early by explicitly returning `false`.
     *
     * @static
     * @memberOf _
     * @since 1.3.0
     * @category Object
     * @param {Object} object The object to iterate over.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @param {*} [accumulator] The custom accumulator value.
     * @returns {*} Returns the accumulated value.
     * @example
     *
     * _.transform([2, 3, 4], function(result, n) {
     *   result.push(n *= n);
     *   return n % 2 == 0;
     * }, []);
     * // => [4, 9]
     *
     * _.transform({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) {
     *   (result[value] || (result[value] = [])).push(key);
     * }, {});
     * // => { '1': ['a', 'c'], '2': ['b'] }
     */
    function transform(object, iteratee, accumulator) {
      var isArr = isArray(object),
          isArrLike = isArr || isBuffer(object) || isTypedArray(object);

      iteratee = getIteratee(iteratee, 4);
      if (accumulator == null) {
        var Ctor = object && object.constructor;
        if (isArrLike) {
          accumulator = isArr ? new Ctor : [];
        }
        else if (isObject(object)) {
          accumulator = isFunction(Ctor) ? baseCreate(getPrototype(object)) : {};
        }
        else {
          accumulator = {};
        }
      }
      (isArrLike ? arrayEach : baseForOwn)(object, function(value, index, object) {
        return iteratee(accumulator, value, index, object);
      });
      return accumulator;
    }

    /**
     * Removes the property at `path` of `object`.
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Object
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to unset.
     * @returns {boolean} Returns `true` if the property is deleted, else `false`.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': 7 } }] };
     * _.unset(object, 'a[0].b.c');
     * // => true
     *
     * console.log(object);
     * // => { 'a': [{ 'b': {} }] };
     *
     * _.unset(object, ['a', '0', 'b', 'c']);
     * // => true
     *
     * console.log(object);
     * // => { 'a': [{ 'b': {} }] };
     */
    function unset(object, path) {
      return object == null ? true : baseUnset(object, path);
    }

    /**
     * This method is like `_.set` except that accepts `updater` to produce the
     * value to set. Use `_.updateWith` to customize `path` creation. The `updater`
     * is invoked with one argument: (value).
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.6.0
     * @category Object
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to set.
     * @param {Function} updater The function to produce the updated value.
     * @returns {Object} Returns `object`.
     * @example
     *
     * var object = { 'a': [{ 'b': { 'c': 3 } }] };
     *
     * _.update(object, 'a[0].b.c', function(n) { return n * n; });
     * console.log(object.a[0].b.c);
     * // => 9
     *
     * _.update(object, 'x[0].y.z', function(n) { return n ? n + 1 : 0; });
     * console.log(object.x[0].y.z);
     * // => 0
     */
    function update(object, path, updater) {
      return object == null ? object : baseUpdate(object, path, castFunction(updater));
    }

    /**
     * This method is like `_.update` except that it accepts `customizer` which is
     * invoked to produce the objects of `path`.  If `customizer` returns `undefined`
     * path creation is handled by the method instead. The `customizer` is invoked
     * with three arguments: (nsValue, key, nsObject).
     *
     * **Note:** This method mutates `object`.
     *
     * @static
     * @memberOf _
     * @since 4.6.0
     * @category Object
     * @param {Object} object The object to modify.
     * @param {Array|string} path The path of the property to set.
     * @param {Function} updater The function to produce the updated value.
     * @param {Function} [customizer] The function to customize assigned values.
     * @returns {Object} Returns `object`.
     * @example
     *
     * var object = {};
     *
     * _.updateWith(object, '[0][1]', _.constant('a'), Object);
     * // => { '0': { '1': 'a' } }
     */
    function updateWith(object, path, updater, customizer) {
      customizer = typeof customizer == 'function' ? customizer : undefined;
      return object == null ? object : baseUpdate(object, path, castFunction(updater), customizer);
    }

    /**
     * Creates an array of the own enumerable string keyed property values of `object`.
     *
     * **Note:** Non-object values are coerced to objects.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Object
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property values.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.values(new Foo);
     * // => [1, 2] (iteration order is not guaranteed)
     *
     * _.values('hi');
     * // => ['h', 'i']
     */
    function values(object) {
      return object == null ? [] : baseValues(object, keys(object));
    }

    /**
     * Creates an array of the own and inherited enumerable string keyed property
     * values of `object`.
     *
     * **Note:** Non-object values are coerced to objects.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Object
     * @param {Object} object The object to query.
     * @returns {Array} Returns the array of property values.
     * @example
     *
     * function Foo() {
     *   this.a = 1;
     *   this.b = 2;
     * }
     *
     * Foo.prototype.c = 3;
     *
     * _.valuesIn(new Foo);
     * // => [1, 2, 3] (iteration order is not guaranteed)
     */
    function valuesIn(object) {
      return object == null ? [] : baseValues(object, keysIn(object));
    }

    /*------------------------------------------------------------------------*/

    /**
     * Clamps `number` within the inclusive `lower` and `upper` bounds.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Number
     * @param {number} number The number to clamp.
     * @param {number} [lower] The lower bound.
     * @param {number} upper The upper bound.
     * @returns {number} Returns the clamped number.
     * @example
     *
     * _.clamp(-10, -5, 5);
     * // => -5
     *
     * _.clamp(10, -5, 5);
     * // => 5
     */
    function clamp(number, lower, upper) {
      if (upper === undefined) {
        upper = lower;
        lower = undefined;
      }
      if (upper !== undefined) {
        upper = toNumber(upper);
        upper = upper === upper ? upper : 0;
      }
      if (lower !== undefined) {
        lower = toNumber(lower);
        lower = lower === lower ? lower : 0;
      }
      return baseClamp(toNumber(number), lower, upper);
    }

    /**
     * Checks if `n` is between `start` and up to, but not including, `end`. If
     * `end` is not specified, it's set to `start` with `start` then set to `0`.
     * If `start` is greater than `end` the params are swapped to support
     * negative ranges.
     *
     * @static
     * @memberOf _
     * @since 3.3.0
     * @category Number
     * @param {number} number The number to check.
     * @param {number} [start=0] The start of the range.
     * @param {number} end The end of the range.
     * @returns {boolean} Returns `true` if `number` is in the range, else `false`.
     * @see _.range, _.rangeRight
     * @example
     *
     * _.inRange(3, 2, 4);
     * // => true
     *
     * _.inRange(4, 8);
     * // => true
     *
     * _.inRange(4, 2);
     * // => false
     *
     * _.inRange(2, 2);
     * // => false
     *
     * _.inRange(1.2, 2);
     * // => true
     *
     * _.inRange(5.2, 4);
     * // => false
     *
     * _.inRange(-3, -2, -6);
     * // => true
     */
    function inRange(number, start, end) {
      start = toFinite(start);
      if (end === undefined) {
        end = start;
        start = 0;
      } else {
        end = toFinite(end);
      }
      number = toNumber(number);
      return baseInRange(number, start, end);
    }

    /**
     * Produces a random number between the inclusive `lower` and `upper` bounds.
     * If only one argument is provided a number between `0` and the given number
     * is returned. If `floating` is `true`, or either `lower` or `upper` are
     * floats, a floating-point number is returned instead of an integer.
     *
     * **Note:** JavaScript follows the IEEE-754 standard for resolving
     * floating-point values which can produce unexpected results.
     *
     * @static
     * @memberOf _
     * @since 0.7.0
     * @category Number
     * @param {number} [lower=0] The lower bound.
     * @param {number} [upper=1] The upper bound.
     * @param {boolean} [floating] Specify returning a floating-point number.
     * @returns {number} Returns the random number.
     * @example
     *
     * _.random(0, 5);
     * // => an integer between 0 and 5
     *
     * _.random(5);
     * // => also an integer between 0 and 5
     *
     * _.random(5, true);
     * // => a floating-point number between 0 and 5
     *
     * _.random(1.2, 5.2);
     * // => a floating-point number between 1.2 and 5.2
     */
    function random(lower, upper, floating) {
      if (floating && typeof floating != 'boolean' && isIterateeCall(lower, upper, floating)) {
        upper = floating = undefined;
      }
      if (floating === undefined) {
        if (typeof upper == 'boolean') {
          floating = upper;
          upper = undefined;
        }
        else if (typeof lower == 'boolean') {
          floating = lower;
          lower = undefined;
        }
      }
      if (lower === undefined && upper === undefined) {
        lower = 0;
        upper = 1;
      }
      else {
        lower = toFinite(lower);
        if (upper === undefined) {
          upper = lower;
          lower = 0;
        } else {
          upper = toFinite(upper);
        }
      }
      if (lower > upper) {
        var temp = lower;
        lower = upper;
        upper = temp;
      }
      if (floating || lower % 1 || upper % 1) {
        var rand = nativeRandom();
        return nativeMin(lower + (rand * (upper - lower + freeParseFloat('1e-' + ((rand + '').length - 1)))), upper);
      }
      return baseRandom(lower, upper);
    }

    /*------------------------------------------------------------------------*/

    /**
     * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the camel cased string.
     * @example
     *
     * _.camelCase('Foo Bar');
     * // => 'fooBar'
     *
     * _.camelCase('--foo-bar--');
     * // => 'fooBar'
     *
     * _.camelCase('__FOO_BAR__');
     * // => 'fooBar'
     */
    var camelCase = createCompounder(function(result, word, index) {
      word = word.toLowerCase();
      return result + (index ? capitalize(word) : word);
    });

    /**
     * Converts the first character of `string` to upper case and the remaining
     * to lower case.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to capitalize.
     * @returns {string} Returns the capitalized string.
     * @example
     *
     * _.capitalize('FRED');
     * // => 'Fred'
     */
    function capitalize(string) {
      return upperFirst(toString(string).toLowerCase());
    }

    /**
     * Deburrs `string` by converting
     * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)
     * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)
     * letters to basic Latin letters and removing
     * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to deburr.
     * @returns {string} Returns the deburred string.
     * @example
     *
     * _.deburr('déjà vu');
     * // => 'deja vu'
     */
    function deburr(string) {
      string = toString(string);
      return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');
    }

    /**
     * Checks if `string` ends with the given target string.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to inspect.
     * @param {string} [target] The string to search for.
     * @param {number} [position=string.length] The position to search up to.
     * @returns {boolean} Returns `true` if `string` ends with `target`,
     *  else `false`.
     * @example
     *
     * _.endsWith('abc', 'c');
     * // => true
     *
     * _.endsWith('abc', 'b');
     * // => false
     *
     * _.endsWith('abc', 'b', 2);
     * // => true
     */
    function endsWith(string, target, position) {
      string = toString(string);
      target = baseToString(target);

      var length = string.length;
      position = position === undefined
        ? length
        : baseClamp(toInteger(position), 0, length);

      var end = position;
      position -= target.length;
      return position >= 0 && string.slice(position, end) == target;
    }

    /**
     * Converts the characters "&", "<", ">", '"', and "'" in `string` to their
     * corresponding HTML entities.
     *
     * **Note:** No other characters are escaped. To escape additional
     * characters use a third-party library like [_he_](https://mths.be/he).
     *
     * Though the ">" character is escaped for symmetry, characters like
     * ">" and "/" don't need escaping in HTML and have no special meaning
     * unless they're part of a tag or unquoted attribute value. See
     * [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands)
     * (under "semi-related fun fact") for more details.
     *
     * When working with HTML you should always
     * [quote attribute values](http://wonko.com/post/html-escaping) to reduce
     * XSS vectors.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category String
     * @param {string} [string=''] The string to escape.
     * @returns {string} Returns the escaped string.
     * @example
     *
     * _.escape('fred, barney, & pebbles');
     * // => 'fred, barney, &amp; pebbles'
     */
    function escape(string) {
      string = toString(string);
      return (string && reHasUnescapedHtml.test(string))
        ? string.replace(reUnescapedHtml, escapeHtmlChar)
        : string;
    }

    /**
     * Escapes the `RegExp` special characters "^", "$", "\", ".", "*", "+",
     * "?", "(", ")", "[", "]", "{", "}", and "|" in `string`.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to escape.
     * @returns {string} Returns the escaped string.
     * @example
     *
     * _.escapeRegExp('[lodash](https://lodash.com/)');
     * // => '\[lodash\]\(https://lodash\.com/\)'
     */
    function escapeRegExp(string) {
      string = toString(string);
      return (string && reHasRegExpChar.test(string))
        ? string.replace(reRegExpChar, '\\$&')
        : string;
    }

    /**
     * Converts `string` to
     * [kebab case](https://en.wikipedia.org/wiki/Letter_case#Special_case_styles).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the kebab cased string.
     * @example
     *
     * _.kebabCase('Foo Bar');
     * // => 'foo-bar'
     *
     * _.kebabCase('fooBar');
     * // => 'foo-bar'
     *
     * _.kebabCase('__FOO_BAR__');
     * // => 'foo-bar'
     */
    var kebabCase = createCompounder(function(result, word, index) {
      return result + (index ? '-' : '') + word.toLowerCase();
    });

    /**
     * Converts `string`, as space separated words, to lower case.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the lower cased string.
     * @example
     *
     * _.lowerCase('--Foo-Bar--');
     * // => 'foo bar'
     *
     * _.lowerCase('fooBar');
     * // => 'foo bar'
     *
     * _.lowerCase('__FOO_BAR__');
     * // => 'foo bar'
     */
    var lowerCase = createCompounder(function(result, word, index) {
      return result + (index ? ' ' : '') + word.toLowerCase();
    });

    /**
     * Converts the first character of `string` to lower case.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the converted string.
     * @example
     *
     * _.lowerFirst('Fred');
     * // => 'fred'
     *
     * _.lowerFirst('FRED');
     * // => 'fRED'
     */
    var lowerFirst = createCaseFirst('toLowerCase');

    /**
     * Pads `string` on the left and right sides if it's shorter than `length`.
     * Padding characters are truncated if they can't be evenly divided by `length`.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to pad.
     * @param {number} [length=0] The padding length.
     * @param {string} [chars=' '] The string used as padding.
     * @returns {string} Returns the padded string.
     * @example
     *
     * _.pad('abc', 8);
     * // => '  abc   '
     *
     * _.pad('abc', 8, '_-');
     * // => '_-abc_-_'
     *
     * _.pad('abc', 3);
     * // => 'abc'
     */
    function pad(string, length, chars) {
      string = toString(string);
      length = toInteger(length);

      var strLength = length ? stringSize(string) : 0;
      if (!length || strLength >= length) {
        return string;
      }
      var mid = (length - strLength) / 2;
      return (
        createPadding(nativeFloor(mid), chars) +
        string +
        createPadding(nativeCeil(mid), chars)
      );
    }

    /**
     * Pads `string` on the right side if it's shorter than `length`. Padding
     * characters are truncated if they exceed `length`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to pad.
     * @param {number} [length=0] The padding length.
     * @param {string} [chars=' '] The string used as padding.
     * @returns {string} Returns the padded string.
     * @example
     *
     * _.padEnd('abc', 6);
     * // => 'abc   '
     *
     * _.padEnd('abc', 6, '_-');
     * // => 'abc_-_'
     *
     * _.padEnd('abc', 3);
     * // => 'abc'
     */
    function padEnd(string, length, chars) {
      string = toString(string);
      length = toInteger(length);

      var strLength = length ? stringSize(string) : 0;
      return (length && strLength < length)
        ? (string + createPadding(length - strLength, chars))
        : string;
    }

    /**
     * Pads `string` on the left side if it's shorter than `length`. Padding
     * characters are truncated if they exceed `length`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to pad.
     * @param {number} [length=0] The padding length.
     * @param {string} [chars=' '] The string used as padding.
     * @returns {string} Returns the padded string.
     * @example
     *
     * _.padStart('abc', 6);
     * // => '   abc'
     *
     * _.padStart('abc', 6, '_-');
     * // => '_-_abc'
     *
     * _.padStart('abc', 3);
     * // => 'abc'
     */
    function padStart(string, length, chars) {
      string = toString(string);
      length = toInteger(length);

      var strLength = length ? stringSize(string) : 0;
      return (length && strLength < length)
        ? (createPadding(length - strLength, chars) + string)
        : string;
    }

    /**
     * Converts `string` to an integer of the specified radix. If `radix` is
     * `undefined` or `0`, a `radix` of `10` is used unless `value` is a
     * hexadecimal, in which case a `radix` of `16` is used.
     *
     * **Note:** This method aligns with the
     * [ES5 implementation](https://es5.github.io/#x15.1.2.2) of `parseInt`.
     *
     * @static
     * @memberOf _
     * @since 1.1.0
     * @category String
     * @param {string} string The string to convert.
     * @param {number} [radix=10] The radix to interpret `value` by.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {number} Returns the converted integer.
     * @example
     *
     * _.parseInt('08');
     * // => 8
     *
     * _.map(['6', '08', '10'], _.parseInt);
     * // => [6, 8, 10]
     */
    function parseInt(string, radix, guard) {
      if (guard || radix == null) {
        radix = 0;
      } else if (radix) {
        radix = +radix;
      }
      return nativeParseInt(toString(string).replace(reTrimStart, ''), radix || 0);
    }

    /**
     * Repeats the given string `n` times.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to repeat.
     * @param {number} [n=1] The number of times to repeat the string.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {string} Returns the repeated string.
     * @example
     *
     * _.repeat('*', 3);
     * // => '***'
     *
     * _.repeat('abc', 2);
     * // => 'abcabc'
     *
     * _.repeat('abc', 0);
     * // => ''
     */
    function repeat(string, n, guard) {
      if ((guard ? isIterateeCall(string, n, guard) : n === undefined)) {
        n = 1;
      } else {
        n = toInteger(n);
      }
      return baseRepeat(toString(string), n);
    }

    /**
     * Replaces matches for `pattern` in `string` with `replacement`.
     *
     * **Note:** This method is based on
     * [`String#replace`](https://mdn.io/String/replace).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to modify.
     * @param {RegExp|string} pattern The pattern to replace.
     * @param {Function|string} replacement The match replacement.
     * @returns {string} Returns the modified string.
     * @example
     *
     * _.replace('Hi Fred', 'Fred', 'Barney');
     * // => 'Hi Barney'
     */
    function replace() {
      var args = arguments,
          string = toString(args[0]);

      return args.length < 3 ? string : string.replace(args[1], args[2]);
    }

    /**
     * Converts `string` to
     * [snake case](https://en.wikipedia.org/wiki/Snake_case).
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the snake cased string.
     * @example
     *
     * _.snakeCase('Foo Bar');
     * // => 'foo_bar'
     *
     * _.snakeCase('fooBar');
     * // => 'foo_bar'
     *
     * _.snakeCase('--FOO-BAR--');
     * // => 'foo_bar'
     */
    var snakeCase = createCompounder(function(result, word, index) {
      return result + (index ? '_' : '') + word.toLowerCase();
    });

    /**
     * Splits `string` by `separator`.
     *
     * **Note:** This method is based on
     * [`String#split`](https://mdn.io/String/split).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to split.
     * @param {RegExp|string} separator The separator pattern to split by.
     * @param {number} [limit] The length to truncate results to.
     * @returns {Array} Returns the string segments.
     * @example
     *
     * _.split('a-b-c', '-', 2);
     * // => ['a', 'b']
     */
    function split(string, separator, limit) {
      if (limit && typeof limit != 'number' && isIterateeCall(string, separator, limit)) {
        separator = limit = undefined;
      }
      limit = limit === undefined ? MAX_ARRAY_LENGTH : limit >>> 0;
      if (!limit) {
        return [];
      }
      string = toString(string);
      if (string && (
            typeof separator == 'string' ||
            (separator != null && !isRegExp(separator))
          )) {
        separator = baseToString(separator);
        if (!separator && hasUnicode(string)) {
          return castSlice(stringToArray(string), 0, limit);
        }
      }
      return string.split(separator, limit);
    }

    /**
     * Converts `string` to
     * [start case](https://en.wikipedia.org/wiki/Letter_case#Stylistic_or_specialised_usage).
     *
     * @static
     * @memberOf _
     * @since 3.1.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the start cased string.
     * @example
     *
     * _.startCase('--foo-bar--');
     * // => 'Foo Bar'
     *
     * _.startCase('fooBar');
     * // => 'Foo Bar'
     *
     * _.startCase('__FOO_BAR__');
     * // => 'FOO BAR'
     */
    var startCase = createCompounder(function(result, word, index) {
      return result + (index ? ' ' : '') + upperFirst(word);
    });

    /**
     * Checks if `string` starts with the given target string.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to inspect.
     * @param {string} [target] The string to search for.
     * @param {number} [position=0] The position to search from.
     * @returns {boolean} Returns `true` if `string` starts with `target`,
     *  else `false`.
     * @example
     *
     * _.startsWith('abc', 'a');
     * // => true
     *
     * _.startsWith('abc', 'b');
     * // => false
     *
     * _.startsWith('abc', 'b', 1);
     * // => true
     */
    function startsWith(string, target, position) {
      string = toString(string);
      position = position == null
        ? 0
        : baseClamp(toInteger(position), 0, string.length);

      target = baseToString(target);
      return string.slice(position, position + target.length) == target;
    }

    /**
     * Creates a compiled template function that can interpolate data properties
     * in "interpolate" delimiters, HTML-escape interpolated data properties in
     * "escape" delimiters, and execute JavaScript in "evaluate" delimiters. Data
     * properties may be accessed as free variables in the template. If a setting
     * object is given, it takes precedence over `_.templateSettings` values.
     *
     * **Note:** In the development build `_.template` utilizes
     * [sourceURLs](http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/#toc-sourceurl)
     * for easier debugging.
     *
     * For more information on precompiling templates see
     * [lodash's custom builds documentation](https://lodash.com/custom-builds).
     *
     * For more information on Chrome extension sandboxes see
     * [Chrome's extensions documentation](https://developer.chrome.com/extensions/sandboxingEval).
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category String
     * @param {string} [string=''] The template string.
     * @param {Object} [options={}] The options object.
     * @param {RegExp} [options.escape=_.templateSettings.escape]
     *  The HTML "escape" delimiter.
     * @param {RegExp} [options.evaluate=_.templateSettings.evaluate]
     *  The "evaluate" delimiter.
     * @param {Object} [options.imports=_.templateSettings.imports]
     *  An object to import into the template as free variables.
     * @param {RegExp} [options.interpolate=_.templateSettings.interpolate]
     *  The "interpolate" delimiter.
     * @param {string} [options.sourceURL='lodash.templateSources[n]']
     *  The sourceURL of the compiled template.
     * @param {string} [options.variable='obj']
     *  The data object variable name.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Function} Returns the compiled template function.
     * @example
     *
     * // Use the "interpolate" delimiter to create a compiled template.
     * var compiled = _.template('hello <%= user %>!');
     * compiled({ 'user': 'fred' });
     * // => 'hello fred!'
     *
     * // Use the HTML "escape" delimiter to escape data property values.
     * var compiled = _.template('<b><%- value %></b>');
     * compiled({ 'value': '<script>' });
     * // => '<b>&lt;script&gt;</b>'
     *
     * // Use the "evaluate" delimiter to execute JavaScript and generate HTML.
     * var compiled = _.template('<% _.forEach(users, function(user) { %><li><%- user %></li><% }); %>');
     * compiled({ 'users': ['fred', 'barney'] });
     * // => '<li>fred</li><li>barney</li>'
     *
     * // Use the internal `print` function in "evaluate" delimiters.
     * var compiled = _.template('<% print("hello " + user); %>!');
     * compiled({ 'user': 'barney' });
     * // => 'hello barney!'
     *
     * // Use the ES template literal delimiter as an "interpolate" delimiter.
     * // Disable support by replacing the "interpolate" delimiter.
     * var compiled = _.template('hello ${ user }!');
     * compiled({ 'user': 'pebbles' });
     * // => 'hello pebbles!'
     *
     * // Use backslashes to treat delimiters as plain text.
     * var compiled = _.template('<%= "\\<%- value %\\>" %>');
     * compiled({ 'value': 'ignored' });
     * // => '<%- value %>'
     *
     * // Use the `imports` option to import `jQuery` as `jq`.
     * var text = '<% jq.each(users, function(user) { %><li><%- user %></li><% }); %>';
     * var compiled = _.template(text, { 'imports': { 'jq': jQuery } });
     * compiled({ 'users': ['fred', 'barney'] });
     * // => '<li>fred</li><li>barney</li>'
     *
     * // Use the `sourceURL` option to specify a custom sourceURL for the template.
     * var compiled = _.template('hello <%= user %>!', { 'sourceURL': '/basic/greeting.jst' });
     * compiled(data);
     * // => Find the source of "greeting.jst" under the Sources tab or Resources panel of the web inspector.
     *
     * // Use the `variable` option to ensure a with-statement isn't used in the compiled template.
     * var compiled = _.template('hi <%= data.user %>!', { 'variable': 'data' });
     * compiled.source;
     * // => function(data) {
     * //   var __t, __p = '';
     * //   __p += 'hi ' + ((__t = ( data.user )) == null ? '' : __t) + '!';
     * //   return __p;
     * // }
     *
     * // Use custom template delimiters.
     * _.templateSettings.interpolate = /{{([\s\S]+?)}}/g;
     * var compiled = _.template('hello {{ user }}!');
     * compiled({ 'user': 'mustache' });
     * // => 'hello mustache!'
     *
     * // Use the `source` property to inline compiled templates for meaningful
     * // line numbers in error messages and stack traces.
     * fs.writeFileSync(path.join(process.cwd(), 'jst.js'), '\
     *   var JST = {\
     *     "main": ' + _.template(mainText).source + '\
     *   };\
     * ');
     */
    function template(string, options, guard) {
      // Based on John Resig's `tmpl` implementation
      // (http://ejohn.org/blog/javascript-micro-templating/)
      // and Laura Doktorova's doT.js (https://github.com/olado/doT).
      var settings = lodash.templateSettings;

      if (guard && isIterateeCall(string, options, guard)) {
        options = undefined;
      }
      string = toString(string);
      options = assignInWith({}, options, settings, customDefaultsAssignIn);

      var imports = assignInWith({}, options.imports, settings.imports, customDefaultsAssignIn),
          importsKeys = keys(imports),
          importsValues = baseValues(imports, importsKeys);

      var isEscaping,
          isEvaluating,
          index = 0,
          interpolate = options.interpolate || reNoMatch,
          source = "__p += '";

      // Compile the regexp to match each delimiter.
      var reDelimiters = RegExp(
        (options.escape || reNoMatch).source + '|' +
        interpolate.source + '|' +
        (interpolate === reInterpolate ? reEsTemplate : reNoMatch).source + '|' +
        (options.evaluate || reNoMatch).source + '|$'
      , 'g');

      // Use a sourceURL for easier debugging.
      // The sourceURL gets injected into the source that's eval-ed, so be careful
      // to normalize all kinds of whitespace, so e.g. newlines (and unicode versions of it) can't sneak in
      // and escape the comment, thus injecting code that gets evaled.
      var sourceURL = '//# sourceURL=' +
        (hasOwnProperty.call(options, 'sourceURL')
          ? (options.sourceURL + '').replace(/\s/g, ' ')
          : ('lodash.templateSources[' + (++templateCounter) + ']')
        ) + '\n';

      string.replace(reDelimiters, function(match, escapeValue, interpolateValue, esTemplateValue, evaluateValue, offset) {
        interpolateValue || (interpolateValue = esTemplateValue);

        // Escape characters that can't be included in string literals.
        source += string.slice(index, offset).replace(reUnescapedString, escapeStringChar);

        // Replace delimiters with snippets.
        if (escapeValue) {
          isEscaping = true;
          source += "' +\n__e(" + escapeValue + ") +\n'";
        }
        if (evaluateValue) {
          isEvaluating = true;
          source += "';\n" + evaluateValue + ";\n__p += '";
        }
        if (interpolateValue) {
          source += "' +\n((__t = (" + interpolateValue + ")) == null ? '' : __t) +\n'";
        }
        index = offset + match.length;

        // The JS engine embedded in Adobe products needs `match` returned in
        // order to produce the correct `offset` value.
        return match;
      });

      source += "';\n";

      // If `variable` is not specified wrap a with-statement around the generated
      // code to add the data object to the top of the scope chain.
      var variable = hasOwnProperty.call(options, 'variable') && options.variable;
      if (!variable) {
        source = 'with (obj) {\n' + source + '\n}\n';
      }
      // Cleanup code by stripping empty strings.
      source = (isEvaluating ? source.replace(reEmptyStringLeading, '') : source)
        .replace(reEmptyStringMiddle, '$1')
        .replace(reEmptyStringTrailing, '$1;');

      // Frame code as the function body.
      source = 'function(' + (variable || 'obj') + ') {\n' +
        (variable
          ? ''
          : 'obj || (obj = {});\n'
        ) +
        "var __t, __p = ''" +
        (isEscaping
           ? ', __e = _.escape'
           : ''
        ) +
        (isEvaluating
          ? ', __j = Array.prototype.join;\n' +
            "function print() { __p += __j.call(arguments, '') }\n"
          : ';\n'
        ) +
        source +
        'return __p\n}';

      var result = attempt(function() {
        return Function(importsKeys, sourceURL + 'return ' + source)
          .apply(undefined, importsValues);
      });

      // Provide the compiled function's source by its `toString` method or
      // the `source` property as a convenience for inlining compiled templates.
      result.source = source;
      if (isError(result)) {
        throw result;
      }
      return result;
    }

    /**
     * Converts `string`, as a whole, to lower case just like
     * [String#toLowerCase](https://mdn.io/toLowerCase).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the lower cased string.
     * @example
     *
     * _.toLower('--Foo-Bar--');
     * // => '--foo-bar--'
     *
     * _.toLower('fooBar');
     * // => 'foobar'
     *
     * _.toLower('__FOO_BAR__');
     * // => '__foo_bar__'
     */
    function toLower(value) {
      return toString(value).toLowerCase();
    }

    /**
     * Converts `string`, as a whole, to upper case just like
     * [String#toUpperCase](https://mdn.io/toUpperCase).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the upper cased string.
     * @example
     *
     * _.toUpper('--foo-bar--');
     * // => '--FOO-BAR--'
     *
     * _.toUpper('fooBar');
     * // => 'FOOBAR'
     *
     * _.toUpper('__foo_bar__');
     * // => '__FOO_BAR__'
     */
    function toUpper(value) {
      return toString(value).toUpperCase();
    }

    /**
     * Removes leading and trailing whitespace or specified characters from `string`.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to trim.
     * @param {string} [chars=whitespace] The characters to trim.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {string} Returns the trimmed string.
     * @example
     *
     * _.trim('  abc  ');
     * // => 'abc'
     *
     * _.trim('-_-abc-_-', '_-');
     * // => 'abc'
     *
     * _.map(['  foo  ', '  bar  '], _.trim);
     * // => ['foo', 'bar']
     */
    function trim(string, chars, guard) {
      string = toString(string);
      if (string && (guard || chars === undefined)) {
        return string.replace(reTrim, '');
      }
      if (!string || !(chars = baseToString(chars))) {
        return string;
      }
      var strSymbols = stringToArray(string),
          chrSymbols = stringToArray(chars),
          start = charsStartIndex(strSymbols, chrSymbols),
          end = charsEndIndex(strSymbols, chrSymbols) + 1;

      return castSlice(strSymbols, start, end).join('');
    }

    /**
     * Removes trailing whitespace or specified characters from `string`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to trim.
     * @param {string} [chars=whitespace] The characters to trim.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {string} Returns the trimmed string.
     * @example
     *
     * _.trimEnd('  abc  ');
     * // => '  abc'
     *
     * _.trimEnd('-_-abc-_-', '_-');
     * // => '-_-abc'
     */
    function trimEnd(string, chars, guard) {
      string = toString(string);
      if (string && (guard || chars === undefined)) {
        return string.replace(reTrimEnd, '');
      }
      if (!string || !(chars = baseToString(chars))) {
        return string;
      }
      var strSymbols = stringToArray(string),
          end = charsEndIndex(strSymbols, stringToArray(chars)) + 1;

      return castSlice(strSymbols, 0, end).join('');
    }

    /**
     * Removes leading whitespace or specified characters from `string`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to trim.
     * @param {string} [chars=whitespace] The characters to trim.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {string} Returns the trimmed string.
     * @example
     *
     * _.trimStart('  abc  ');
     * // => 'abc  '
     *
     * _.trimStart('-_-abc-_-', '_-');
     * // => 'abc-_-'
     */
    function trimStart(string, chars, guard) {
      string = toString(string);
      if (string && (guard || chars === undefined)) {
        return string.replace(reTrimStart, '');
      }
      if (!string || !(chars = baseToString(chars))) {
        return string;
      }
      var strSymbols = stringToArray(string),
          start = charsStartIndex(strSymbols, stringToArray(chars));

      return castSlice(strSymbols, start).join('');
    }

    /**
     * Truncates `string` if it's longer than the given maximum string length.
     * The last characters of the truncated string are replaced with the omission
     * string which defaults to "...".
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to truncate.
     * @param {Object} [options={}] The options object.
     * @param {number} [options.length=30] The maximum string length.
     * @param {string} [options.omission='...'] The string to indicate text is omitted.
     * @param {RegExp|string} [options.separator] The separator pattern to truncate to.
     * @returns {string} Returns the truncated string.
     * @example
     *
     * _.truncate('hi-diddly-ho there, neighborino');
     * // => 'hi-diddly-ho there, neighbo...'
     *
     * _.truncate('hi-diddly-ho there, neighborino', {
     *   'length': 24,
     *   'separator': ' '
     * });
     * // => 'hi-diddly-ho there,...'
     *
     * _.truncate('hi-diddly-ho there, neighborino', {
     *   'length': 24,
     *   'separator': /,? +/
     * });
     * // => 'hi-diddly-ho there...'
     *
     * _.truncate('hi-diddly-ho there, neighborino', {
     *   'omission': ' [...]'
     * });
     * // => 'hi-diddly-ho there, neig [...]'
     */
    function truncate(string, options) {
      var length = DEFAULT_TRUNC_LENGTH,
          omission = DEFAULT_TRUNC_OMISSION;

      if (isObject(options)) {
        var separator = 'separator' in options ? options.separator : separator;
        length = 'length' in options ? toInteger(options.length) : length;
        omission = 'omission' in options ? baseToString(options.omission) : omission;
      }
      string = toString(string);

      var strLength = string.length;
      if (hasUnicode(string)) {
        var strSymbols = stringToArray(string);
        strLength = strSymbols.length;
      }
      if (length >= strLength) {
        return string;
      }
      var end = length - stringSize(omission);
      if (end < 1) {
        return omission;
      }
      var result = strSymbols
        ? castSlice(strSymbols, 0, end).join('')
        : string.slice(0, end);

      if (separator === undefined) {
        return result + omission;
      }
      if (strSymbols) {
        end += (result.length - end);
      }
      if (isRegExp(separator)) {
        if (string.slice(end).search(separator)) {
          var match,
              substring = result;

          if (!separator.global) {
            separator = RegExp(separator.source, toString(reFlags.exec(separator)) + 'g');
          }
          separator.lastIndex = 0;
          while ((match = separator.exec(substring))) {
            var newEnd = match.index;
          }
          result = result.slice(0, newEnd === undefined ? end : newEnd);
        }
      } else if (string.indexOf(baseToString(separator), end) != end) {
        var index = result.lastIndexOf(separator);
        if (index > -1) {
          result = result.slice(0, index);
        }
      }
      return result + omission;
    }

    /**
     * The inverse of `_.escape`; this method converts the HTML entities
     * `&amp;`, `&lt;`, `&gt;`, `&quot;`, and `&#39;` in `string` to
     * their corresponding characters.
     *
     * **Note:** No other HTML entities are unescaped. To unescape additional
     * HTML entities use a third-party library like [_he_](https://mths.be/he).
     *
     * @static
     * @memberOf _
     * @since 0.6.0
     * @category String
     * @param {string} [string=''] The string to unescape.
     * @returns {string} Returns the unescaped string.
     * @example
     *
     * _.unescape('fred, barney, &amp; pebbles');
     * // => 'fred, barney, & pebbles'
     */
    function unescape(string) {
      string = toString(string);
      return (string && reHasEscapedHtml.test(string))
        ? string.replace(reEscapedHtml, unescapeHtmlChar)
        : string;
    }

    /**
     * Converts `string`, as space separated words, to upper case.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the upper cased string.
     * @example
     *
     * _.upperCase('--foo-bar');
     * // => 'FOO BAR'
     *
     * _.upperCase('fooBar');
     * // => 'FOO BAR'
     *
     * _.upperCase('__foo_bar__');
     * // => 'FOO BAR'
     */
    var upperCase = createCompounder(function(result, word, index) {
      return result + (index ? ' ' : '') + word.toUpperCase();
    });

    /**
     * Converts the first character of `string` to upper case.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category String
     * @param {string} [string=''] The string to convert.
     * @returns {string} Returns the converted string.
     * @example
     *
     * _.upperFirst('fred');
     * // => 'Fred'
     *
     * _.upperFirst('FRED');
     * // => 'FRED'
     */
    var upperFirst = createCaseFirst('toUpperCase');

    /**
     * Splits `string` into an array of its words.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category String
     * @param {string} [string=''] The string to inspect.
     * @param {RegExp|string} [pattern] The pattern to match words.
     * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.
     * @returns {Array} Returns the words of `string`.
     * @example
     *
     * _.words('fred, barney, & pebbles');
     * // => ['fred', 'barney', 'pebbles']
     *
     * _.words('fred, barney, & pebbles', /[^, ]+/g);
     * // => ['fred', 'barney', '&', 'pebbles']
     */
    function words(string, pattern, guard) {
      string = toString(string);
      pattern = guard ? undefined : pattern;

      if (pattern === undefined) {
        return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);
      }
      return string.match(pattern) || [];
    }

    /*------------------------------------------------------------------------*/

    /**
     * Attempts to invoke `func`, returning either the result or the caught error
     * object. Any additional arguments are provided to `func` when it's invoked.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Util
     * @param {Function} func The function to attempt.
     * @param {...*} [args] The arguments to invoke `func` with.
     * @returns {*} Returns the `func` result or error object.
     * @example
     *
     * // Avoid throwing errors for invalid selectors.
     * var elements = _.attempt(function(selector) {
     *   return document.querySelectorAll(selector);
     * }, '>_>');
     *
     * if (_.isError(elements)) {
     *   elements = [];
     * }
     */
    var attempt = baseRest(function(func, args) {
      try {
        return apply(func, undefined, args);
      } catch (e) {
        return isError(e) ? e : new Error(e);
      }
    });

    /**
     * Binds methods of an object to the object itself, overwriting the existing
     * method.
     *
     * **Note:** This method doesn't set the "length" property of bound functions.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @param {Object} object The object to bind and assign the bound methods to.
     * @param {...(string|string[])} methodNames The object method names to bind.
     * @returns {Object} Returns `object`.
     * @example
     *
     * var view = {
     *   'label': 'docs',
     *   'click': function() {
     *     console.log('clicked ' + this.label);
     *   }
     * };
     *
     * _.bindAll(view, ['click']);
     * jQuery(element).on('click', view.click);
     * // => Logs 'clicked docs' when clicked.
     */
    var bindAll = flatRest(function(object, methodNames) {
      arrayEach(methodNames, function(key) {
        key = toKey(key);
        baseAssignValue(object, key, bind(object[key], object));
      });
      return object;
    });

    /**
     * Creates a function that iterates over `pairs` and invokes the corresponding
     * function of the first predicate to return truthy. The predicate-function
     * pairs are invoked with the `this` binding and arguments of the created
     * function.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {Array} pairs The predicate-function pairs.
     * @returns {Function} Returns the new composite function.
     * @example
     *
     * var func = _.cond([
     *   [_.matches({ 'a': 1 }),           _.constant('matches A')],
     *   [_.conforms({ 'b': _.isNumber }), _.constant('matches B')],
     *   [_.stubTrue,                      _.constant('no match')]
     * ]);
     *
     * func({ 'a': 1, 'b': 2 });
     * // => 'matches A'
     *
     * func({ 'a': 0, 'b': 1 });
     * // => 'matches B'
     *
     * func({ 'a': '1', 'b': '2' });
     * // => 'no match'
     */
    function cond(pairs) {
      var length = pairs == null ? 0 : pairs.length,
          toIteratee = getIteratee();

      pairs = !length ? [] : arrayMap(pairs, function(pair) {
        if (typeof pair[1] != 'function') {
          throw new TypeError(FUNC_ERROR_TEXT);
        }
        return [toIteratee(pair[0]), pair[1]];
      });

      return baseRest(function(args) {
        var index = -1;
        while (++index < length) {
          var pair = pairs[index];
          if (apply(pair[0], this, args)) {
            return apply(pair[1], this, args);
          }
        }
      });
    }

    /**
     * Creates a function that invokes the predicate properties of `source` with
     * the corresponding property values of a given object, returning `true` if
     * all predicates return truthy, else `false`.
     *
     * **Note:** The created function is equivalent to `_.conformsTo` with
     * `source` partially applied.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {Object} source The object of property predicates to conform to.
     * @returns {Function} Returns the new spec function.
     * @example
     *
     * var objects = [
     *   { 'a': 2, 'b': 1 },
     *   { 'a': 1, 'b': 2 }
     * ];
     *
     * _.filter(objects, _.conforms({ 'b': function(n) { return n > 1; } }));
     * // => [{ 'a': 1, 'b': 2 }]
     */
    function conforms(source) {
      return baseConforms(baseClone(source, CLONE_DEEP_FLAG));
    }

    /**
     * Creates a function that returns `value`.
     *
     * @static
     * @memberOf _
     * @since 2.4.0
     * @category Util
     * @param {*} value The value to return from the new function.
     * @returns {Function} Returns the new constant function.
     * @example
     *
     * var objects = _.times(2, _.constant({ 'a': 1 }));
     *
     * console.log(objects);
     * // => [{ 'a': 1 }, { 'a': 1 }]
     *
     * console.log(objects[0] === objects[1]);
     * // => true
     */
    function constant(value) {
      return function() {
        return value;
      };
    }

    /**
     * Checks `value` to determine whether a default value should be returned in
     * its place. The `defaultValue` is returned if `value` is `NaN`, `null`,
     * or `undefined`.
     *
     * @static
     * @memberOf _
     * @since 4.14.0
     * @category Util
     * @param {*} value The value to check.
     * @param {*} defaultValue The default value.
     * @returns {*} Returns the resolved value.
     * @example
     *
     * _.defaultTo(1, 10);
     * // => 1
     *
     * _.defaultTo(undefined, 10);
     * // => 10
     */
    function defaultTo(value, defaultValue) {
      return (value == null || value !== value) ? defaultValue : value;
    }

    /**
     * Creates a function that returns the result of invoking the given functions
     * with the `this` binding of the created function, where each successive
     * invocation is supplied the return value of the previous.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Util
     * @param {...(Function|Function[])} [funcs] The functions to invoke.
     * @returns {Function} Returns the new composite function.
     * @see _.flowRight
     * @example
     *
     * function square(n) {
     *   return n * n;
     * }
     *
     * var addSquare = _.flow([_.add, square]);
     * addSquare(1, 2);
     * // => 9
     */
    var flow = createFlow();

    /**
     * This method is like `_.flow` except that it creates a function that
     * invokes the given functions from right to left.
     *
     * @static
     * @since 3.0.0
     * @memberOf _
     * @category Util
     * @param {...(Function|Function[])} [funcs] The functions to invoke.
     * @returns {Function} Returns the new composite function.
     * @see _.flow
     * @example
     *
     * function square(n) {
     *   return n * n;
     * }
     *
     * var addSquare = _.flowRight([square, _.add]);
     * addSquare(1, 2);
     * // => 9
     */
    var flowRight = createFlow(true);

    /**
     * This method returns the first argument it receives.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @param {*} value Any value.
     * @returns {*} Returns `value`.
     * @example
     *
     * var object = { 'a': 1 };
     *
     * console.log(_.identity(object) === object);
     * // => true
     */
    function identity(value) {
      return value;
    }

    /**
     * Creates a function that invokes `func` with the arguments of the created
     * function. If `func` is a property name, the created function returns the
     * property value for a given element. If `func` is an array or object, the
     * created function returns `true` for elements that contain the equivalent
     * source properties, otherwise it returns `false`.
     *
     * @static
     * @since 4.0.0
     * @memberOf _
     * @category Util
     * @param {*} [func=_.identity] The value to convert to a callback.
     * @returns {Function} Returns the callback.
     * @example
     *
     * var users = [
     *   { 'user': 'barney', 'age': 36, 'active': true },
     *   { 'user': 'fred',   'age': 40, 'active': false }
     * ];
     *
     * // The `_.matches` iteratee shorthand.
     * _.filter(users, _.iteratee({ 'user': 'barney', 'active': true }));
     * // => [{ 'user': 'barney', 'age': 36, 'active': true }]
     *
     * // The `_.matchesProperty` iteratee shorthand.
     * _.filter(users, _.iteratee(['user', 'fred']));
     * // => [{ 'user': 'fred', 'age': 40 }]
     *
     * // The `_.property` iteratee shorthand.
     * _.map(users, _.iteratee('user'));
     * // => ['barney', 'fred']
     *
     * // Create custom iteratee shorthands.
     * _.iteratee = _.wrap(_.iteratee, function(iteratee, func) {
     *   return !_.isRegExp(func) ? iteratee(func) : function(string) {
     *     return func.test(string);
     *   };
     * });
     *
     * _.filter(['abc', 'def'], /ef/);
     * // => ['def']
     */
    function iteratee(func) {
      return baseIteratee(typeof func == 'function' ? func : baseClone(func, CLONE_DEEP_FLAG));
    }

    /**
     * Creates a function that performs a partial deep comparison between a given
     * object and `source`, returning `true` if the given object has equivalent
     * property values, else `false`.
     *
     * **Note:** The created function is equivalent to `_.isMatch` with `source`
     * partially applied.
     *
     * Partial comparisons will match empty array and empty object `source`
     * values against any array or object value, respectively. See `_.isEqual`
     * for a list of supported value comparisons.
     *
     * **Note:** Multiple values can be checked by combining several matchers
     * using `_.overSome`
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Util
     * @param {Object} source The object of property values to match.
     * @returns {Function} Returns the new spec function.
     * @example
     *
     * var objects = [
     *   { 'a': 1, 'b': 2, 'c': 3 },
     *   { 'a': 4, 'b': 5, 'c': 6 }
     * ];
     *
     * _.filter(objects, _.matches({ 'a': 4, 'c': 6 }));
     * // => [{ 'a': 4, 'b': 5, 'c': 6 }]
     *
     * // Checking for several possible values
     * _.filter(users, _.overSome([_.matches({ 'a': 1 }), _.matches({ 'a': 4 })]));
     * // => [{ 'a': 1, 'b': 2, 'c': 3 }, { 'a': 4, 'b': 5, 'c': 6 }]
     */
    function matches(source) {
      return baseMatches(baseClone(source, CLONE_DEEP_FLAG));
    }

    /**
     * Creates a function that performs a partial deep comparison between the
     * value at `path` of a given object to `srcValue`, returning `true` if the
     * object value is equivalent, else `false`.
     *
     * **Note:** Partial comparisons will match empty array and empty object
     * `srcValue` values against any array or object value, respectively. See
     * `_.isEqual` for a list of supported value comparisons.
     *
     * **Note:** Multiple values can be checked by combining several matchers
     * using `_.overSome`
     *
     * @static
     * @memberOf _
     * @since 3.2.0
     * @category Util
     * @param {Array|string} path The path of the property to get.
     * @param {*} srcValue The value to match.
     * @returns {Function} Returns the new spec function.
     * @example
     *
     * var objects = [
     *   { 'a': 1, 'b': 2, 'c': 3 },
     *   { 'a': 4, 'b': 5, 'c': 6 }
     * ];
     *
     * _.find(objects, _.matchesProperty('a', 4));
     * // => { 'a': 4, 'b': 5, 'c': 6 }
     *
     * // Checking for several possible values
     * _.filter(users, _.overSome([_.matchesProperty('a', 1), _.matchesProperty('a', 4)]));
     * // => [{ 'a': 1, 'b': 2, 'c': 3 }, { 'a': 4, 'b': 5, 'c': 6 }]
     */
    function matchesProperty(path, srcValue) {
      return baseMatchesProperty(path, baseClone(srcValue, CLONE_DEEP_FLAG));
    }

    /**
     * Creates a function that invokes the method at `path` of a given object.
     * Any additional arguments are provided to the invoked method.
     *
     * @static
     * @memberOf _
     * @since 3.7.0
     * @category Util
     * @param {Array|string} path The path of the method to invoke.
     * @param {...*} [args] The arguments to invoke the method with.
     * @returns {Function} Returns the new invoker function.
     * @example
     *
     * var objects = [
     *   { 'a': { 'b': _.constant(2) } },
     *   { 'a': { 'b': _.constant(1) } }
     * ];
     *
     * _.map(objects, _.method('a.b'));
     * // => [2, 1]
     *
     * _.map(objects, _.method(['a', 'b']));
     * // => [2, 1]
     */
    var method = baseRest(function(path, args) {
      return function(object) {
        return baseInvoke(object, path, args);
      };
    });

    /**
     * The opposite of `_.method`; this method creates a function that invokes
     * the method at a given path of `object`. Any additional arguments are
     * provided to the invoked method.
     *
     * @static
     * @memberOf _
     * @since 3.7.0
     * @category Util
     * @param {Object} object The object to query.
     * @param {...*} [args] The arguments to invoke the method with.
     * @returns {Function} Returns the new invoker function.
     * @example
     *
     * var array = _.times(3, _.constant),
     *     object = { 'a': array, 'b': array, 'c': array };
     *
     * _.map(['a[2]', 'c[0]'], _.methodOf(object));
     * // => [2, 0]
     *
     * _.map([['a', '2'], ['c', '0']], _.methodOf(object));
     * // => [2, 0]
     */
    var methodOf = baseRest(function(object, args) {
      return function(path) {
        return baseInvoke(object, path, args);
      };
    });

    /**
     * Adds all own enumerable string keyed function properties of a source
     * object to the destination object. If `object` is a function, then methods
     * are added to its prototype as well.
     *
     * **Note:** Use `_.runInContext` to create a pristine `lodash` function to
     * avoid conflicts caused by modifying the original.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @param {Function|Object} [object=lodash] The destination object.
     * @param {Object} source The object of functions to add.
     * @param {Object} [options={}] The options object.
     * @param {boolean} [options.chain=true] Specify whether mixins are chainable.
     * @returns {Function|Object} Returns `object`.
     * @example
     *
     * function vowels(string) {
     *   return _.filter(string, function(v) {
     *     return /[aeiou]/i.test(v);
     *   });
     * }
     *
     * _.mixin({ 'vowels': vowels });
     * _.vowels('fred');
     * // => ['e']
     *
     * _('fred').vowels().value();
     * // => ['e']
     *
     * _.mixin({ 'vowels': vowels }, { 'chain': false });
     * _('fred').vowels();
     * // => ['e']
     */
    function mixin(object, source, options) {
      var props = keys(source),
          methodNames = baseFunctions(source, props);

      if (options == null &&
          !(isObject(source) && (methodNames.length || !props.length))) {
        options = source;
        source = object;
        object = this;
        methodNames = baseFunctions(source, keys(source));
      }
      var chain = !(isObject(options) && 'chain' in options) || !!options.chain,
          isFunc = isFunction(object);

      arrayEach(methodNames, function(methodName) {
        var func = source[methodName];
        object[methodName] = func;
        if (isFunc) {
          object.prototype[methodName] = function() {
            var chainAll = this.__chain__;
            if (chain || chainAll) {
              var result = object(this.__wrapped__),
                  actions = result.__actions__ = copyArray(this.__actions__);

              actions.push({ 'func': func, 'args': arguments, 'thisArg': object });
              result.__chain__ = chainAll;
              return result;
            }
            return func.apply(object, arrayPush([this.value()], arguments));
          };
        }
      });

      return object;
    }

    /**
     * Reverts the `_` variable to its previous value and returns a reference to
     * the `lodash` function.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @returns {Function} Returns the `lodash` function.
     * @example
     *
     * var lodash = _.noConflict();
     */
    function noConflict() {
      if (root._ === this) {
        root._ = oldDash;
      }
      return this;
    }

    /**
     * This method returns `undefined`.
     *
     * @static
     * @memberOf _
     * @since 2.3.0
     * @category Util
     * @example
     *
     * _.times(2, _.noop);
     * // => [undefined, undefined]
     */
    function noop() {
      // No operation performed.
    }

    /**
     * Creates a function that gets the argument at index `n`. If `n` is negative,
     * the nth argument from the end is returned.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {number} [n=0] The index of the argument to return.
     * @returns {Function} Returns the new pass-thru function.
     * @example
     *
     * var func = _.nthArg(1);
     * func('a', 'b', 'c', 'd');
     * // => 'b'
     *
     * var func = _.nthArg(-2);
     * func('a', 'b', 'c', 'd');
     * // => 'c'
     */
    function nthArg(n) {
      n = toInteger(n);
      return baseRest(function(args) {
        return baseNth(args, n);
      });
    }

    /**
     * Creates a function that invokes `iteratees` with the arguments it receives
     * and returns their results.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {...(Function|Function[])} [iteratees=[_.identity]]
     *  The iteratees to invoke.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var func = _.over([Math.max, Math.min]);
     *
     * func(1, 2, 3, 4);
     * // => [4, 1]
     */
    var over = createOver(arrayMap);

    /**
     * Creates a function that checks if **all** of the `predicates` return
     * truthy when invoked with the arguments it receives.
     *
     * Following shorthands are possible for providing predicates.
     * Pass an `Object` and it will be used as an parameter for `_.matches` to create the predicate.
     * Pass an `Array` of parameters for `_.matchesProperty` and the predicate will be created using them.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {...(Function|Function[])} [predicates=[_.identity]]
     *  The predicates to check.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var func = _.overEvery([Boolean, isFinite]);
     *
     * func('1');
     * // => true
     *
     * func(null);
     * // => false
     *
     * func(NaN);
     * // => false
     */
    var overEvery = createOver(arrayEvery);

    /**
     * Creates a function that checks if **any** of the `predicates` return
     * truthy when invoked with the arguments it receives.
     *
     * Following shorthands are possible for providing predicates.
     * Pass an `Object` and it will be used as an parameter for `_.matches` to create the predicate.
     * Pass an `Array` of parameters for `_.matchesProperty` and the predicate will be created using them.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {...(Function|Function[])} [predicates=[_.identity]]
     *  The predicates to check.
     * @returns {Function} Returns the new function.
     * @example
     *
     * var func = _.overSome([Boolean, isFinite]);
     *
     * func('1');
     * // => true
     *
     * func(null);
     * // => true
     *
     * func(NaN);
     * // => false
     *
     * var matchesFunc = _.overSome([{ 'a': 1 }, { 'a': 2 }])
     * var matchesPropertyFunc = _.overSome([['a', 1], ['a', 2]])
     */
    var overSome = createOver(arraySome);

    /**
     * Creates a function that returns the value at `path` of a given object.
     *
     * @static
     * @memberOf _
     * @since 2.4.0
     * @category Util
     * @param {Array|string} path The path of the property to get.
     * @returns {Function} Returns the new accessor function.
     * @example
     *
     * var objects = [
     *   { 'a': { 'b': 2 } },
     *   { 'a': { 'b': 1 } }
     * ];
     *
     * _.map(objects, _.property('a.b'));
     * // => [2, 1]
     *
     * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');
     * // => [1, 2]
     */
    function property(path) {
      return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);
    }

    /**
     * The opposite of `_.property`; this method creates a function that returns
     * the value at a given path of `object`.
     *
     * @static
     * @memberOf _
     * @since 3.0.0
     * @category Util
     * @param {Object} object The object to query.
     * @returns {Function} Returns the new accessor function.
     * @example
     *
     * var array = [0, 1, 2],
     *     object = { 'a': array, 'b': array, 'c': array };
     *
     * _.map(['a[2]', 'c[0]'], _.propertyOf(object));
     * // => [2, 0]
     *
     * _.map([['a', '2'], ['c', '0']], _.propertyOf(object));
     * // => [2, 0]
     */
    function propertyOf(object) {
      return function(path) {
        return object == null ? undefined : baseGet(object, path);
      };
    }

    /**
     * Creates an array of numbers (positive and/or negative) progressing from
     * `start` up to, but not including, `end`. A step of `-1` is used if a negative
     * `start` is specified without an `end` or `step`. If `end` is not specified,
     * it's set to `start` with `start` then set to `0`.
     *
     * **Note:** JavaScript follows the IEEE-754 standard for resolving
     * floating-point values which can produce unexpected results.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @param {number} [start=0] The start of the range.
     * @param {number} end The end of the range.
     * @param {number} [step=1] The value to increment or decrement by.
     * @returns {Array} Returns the range of numbers.
     * @see _.inRange, _.rangeRight
     * @example
     *
     * _.range(4);
     * // => [0, 1, 2, 3]
     *
     * _.range(-4);
     * // => [0, -1, -2, -3]
     *
     * _.range(1, 5);
     * // => [1, 2, 3, 4]
     *
     * _.range(0, 20, 5);
     * // => [0, 5, 10, 15]
     *
     * _.range(0, -4, -1);
     * // => [0, -1, -2, -3]
     *
     * _.range(1, 4, 0);
     * // => [1, 1, 1]
     *
     * _.range(0);
     * // => []
     */
    var range = createRange();

    /**
     * This method is like `_.range` except that it populates values in
     * descending order.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {number} [start=0] The start of the range.
     * @param {number} end The end of the range.
     * @param {number} [step=1] The value to increment or decrement by.
     * @returns {Array} Returns the range of numbers.
     * @see _.inRange, _.range
     * @example
     *
     * _.rangeRight(4);
     * // => [3, 2, 1, 0]
     *
     * _.rangeRight(-4);
     * // => [-3, -2, -1, 0]
     *
     * _.rangeRight(1, 5);
     * // => [4, 3, 2, 1]
     *
     * _.rangeRight(0, 20, 5);
     * // => [15, 10, 5, 0]
     *
     * _.rangeRight(0, -4, -1);
     * // => [-3, -2, -1, 0]
     *
     * _.rangeRight(1, 4, 0);
     * // => [1, 1, 1]
     *
     * _.rangeRight(0);
     * // => []
     */
    var rangeRight = createRange(true);

    /**
     * This method returns a new empty array.
     *
     * @static
     * @memberOf _
     * @since 4.13.0
     * @category Util
     * @returns {Array} Returns the new empty array.
     * @example
     *
     * var arrays = _.times(2, _.stubArray);
     *
     * console.log(arrays);
     * // => [[], []]
     *
     * console.log(arrays[0] === arrays[1]);
     * // => false
     */
    function stubArray() {
      return [];
    }

    /**
     * This method returns `false`.
     *
     * @static
     * @memberOf _
     * @since 4.13.0
     * @category Util
     * @returns {boolean} Returns `false`.
     * @example
     *
     * _.times(2, _.stubFalse);
     * // => [false, false]
     */
    function stubFalse() {
      return false;
    }

    /**
     * This method returns a new empty object.
     *
     * @static
     * @memberOf _
     * @since 4.13.0
     * @category Util
     * @returns {Object} Returns the new empty object.
     * @example
     *
     * var objects = _.times(2, _.stubObject);
     *
     * console.log(objects);
     * // => [{}, {}]
     *
     * console.log(objects[0] === objects[1]);
     * // => false
     */
    function stubObject() {
      return {};
    }

    /**
     * This method returns an empty string.
     *
     * @static
     * @memberOf _
     * @since 4.13.0
     * @category Util
     * @returns {string} Returns the empty string.
     * @example
     *
     * _.times(2, _.stubString);
     * // => ['', '']
     */
    function stubString() {
      return '';
    }

    /**
     * This method returns `true`.
     *
     * @static
     * @memberOf _
     * @since 4.13.0
     * @category Util
     * @returns {boolean} Returns `true`.
     * @example
     *
     * _.times(2, _.stubTrue);
     * // => [true, true]
     */
    function stubTrue() {
      return true;
    }

    /**
     * Invokes the iteratee `n` times, returning an array of the results of
     * each invocation. The iteratee is invoked with one argument; (index).
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @param {number} n The number of times to invoke `iteratee`.
     * @param {Function} [iteratee=_.identity] The function invoked per iteration.
     * @returns {Array} Returns the array of results.
     * @example
     *
     * _.times(3, String);
     * // => ['0', '1', '2']
     *
     *  _.times(4, _.constant(0));
     * // => [0, 0, 0, 0]
     */
    function times(n, iteratee) {
      n = toInteger(n);
      if (n < 1 || n > MAX_SAFE_INTEGER) {
        return [];
      }
      var index = MAX_ARRAY_LENGTH,
          length = nativeMin(n, MAX_ARRAY_LENGTH);

      iteratee = getIteratee(iteratee);
      n -= MAX_ARRAY_LENGTH;

      var result = baseTimes(length, iteratee);
      while (++index < n) {
        iteratee(index);
      }
      return result;
    }

    /**
     * Converts `value` to a property path array.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Util
     * @param {*} value The value to convert.
     * @returns {Array} Returns the new property path array.
     * @example
     *
     * _.toPath('a.b.c');
     * // => ['a', 'b', 'c']
     *
     * _.toPath('a[0].b.c');
     * // => ['a', '0', 'b', 'c']
     */
    function toPath(value) {
      if (isArray(value)) {
        return arrayMap(value, toKey);
      }
      return isSymbol(value) ? [value] : copyArray(stringToPath(toString(value)));
    }

    /**
     * Generates a unique ID. If `prefix` is given, the ID is appended to it.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Util
     * @param {string} [prefix=''] The value to prefix the ID with.
     * @returns {string} Returns the unique ID.
     * @example
     *
     * _.uniqueId('contact_');
     * // => 'contact_104'
     *
     * _.uniqueId();
     * // => '105'
     */
    function uniqueId(prefix) {
      var id = ++idCounter;
      return toString(prefix) + id;
    }

    /*------------------------------------------------------------------------*/

    /**
     * Adds two numbers.
     *
     * @static
     * @memberOf _
     * @since 3.4.0
     * @category Math
     * @param {number} augend The first number in an addition.
     * @param {number} addend The second number in an addition.
     * @returns {number} Returns the total.
     * @example
     *
     * _.add(6, 4);
     * // => 10
     */
    var add = createMathOperation(function(augend, addend) {
      return augend + addend;
    }, 0);

    /**
     * Computes `number` rounded up to `precision`.
     *
     * @static
     * @memberOf _
     * @since 3.10.0
     * @category Math
     * @param {number} number The number to round up.
     * @param {number} [precision=0] The precision to round up to.
     * @returns {number} Returns the rounded up number.
     * @example
     *
     * _.ceil(4.006);
     * // => 5
     *
     * _.ceil(6.004, 2);
     * // => 6.01
     *
     * _.ceil(6040, -2);
     * // => 6100
     */
    var ceil = createRound('ceil');

    /**
     * Divide two numbers.
     *
     * @static
     * @memberOf _
     * @since 4.7.0
     * @category Math
     * @param {number} dividend The first number in a division.
     * @param {number} divisor The second number in a division.
     * @returns {number} Returns the quotient.
     * @example
     *
     * _.divide(6, 4);
     * // => 1.5
     */
    var divide = createMathOperation(function(dividend, divisor) {
      return dividend / divisor;
    }, 1);

    /**
     * Computes `number` rounded down to `precision`.
     *
     * @static
     * @memberOf _
     * @since 3.10.0
     * @category Math
     * @param {number} number The number to round down.
     * @param {number} [precision=0] The precision to round down to.
     * @returns {number} Returns the rounded down number.
     * @example
     *
     * _.floor(4.006);
     * // => 4
     *
     * _.floor(0.046, 2);
     * // => 0.04
     *
     * _.floor(4060, -2);
     * // => 4000
     */
    var floor = createRound('floor');

    /**
     * Computes the maximum value of `array`. If `array` is empty or falsey,
     * `undefined` is returned.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Math
     * @param {Array} array The array to iterate over.
     * @returns {*} Returns the maximum value.
     * @example
     *
     * _.max([4, 2, 8, 6]);
     * // => 8
     *
     * _.max([]);
     * // => undefined
     */
    function max(array) {
      return (array && array.length)
        ? baseExtremum(array, identity, baseGt)
        : undefined;
    }

    /**
     * This method is like `_.max` except that it accepts `iteratee` which is
     * invoked for each element in `array` to generate the criterion by which
     * the value is ranked. The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Math
     * @param {Array} array The array to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {*} Returns the maximum value.
     * @example
     *
     * var objects = [{ 'n': 1 }, { 'n': 2 }];
     *
     * _.maxBy(objects, function(o) { return o.n; });
     * // => { 'n': 2 }
     *
     * // The `_.property` iteratee shorthand.
     * _.maxBy(objects, 'n');
     * // => { 'n': 2 }
     */
    function maxBy(array, iteratee) {
      return (array && array.length)
        ? baseExtremum(array, getIteratee(iteratee, 2), baseGt)
        : undefined;
    }

    /**
     * Computes the mean of the values in `array`.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Math
     * @param {Array} array The array to iterate over.
     * @returns {number} Returns the mean.
     * @example
     *
     * _.mean([4, 2, 8, 6]);
     * // => 5
     */
    function mean(array) {
      return baseMean(array, identity);
    }

    /**
     * This method is like `_.mean` except that it accepts `iteratee` which is
     * invoked for each element in `array` to generate the value to be averaged.
     * The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.7.0
     * @category Math
     * @param {Array} array The array to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {number} Returns the mean.
     * @example
     *
     * var objects = [{ 'n': 4 }, { 'n': 2 }, { 'n': 8 }, { 'n': 6 }];
     *
     * _.meanBy(objects, function(o) { return o.n; });
     * // => 5
     *
     * // The `_.property` iteratee shorthand.
     * _.meanBy(objects, 'n');
     * // => 5
     */
    function meanBy(array, iteratee) {
      return baseMean(array, getIteratee(iteratee, 2));
    }

    /**
     * Computes the minimum value of `array`. If `array` is empty or falsey,
     * `undefined` is returned.
     *
     * @static
     * @since 0.1.0
     * @memberOf _
     * @category Math
     * @param {Array} array The array to iterate over.
     * @returns {*} Returns the minimum value.
     * @example
     *
     * _.min([4, 2, 8, 6]);
     * // => 2
     *
     * _.min([]);
     * // => undefined
     */
    function min(array) {
      return (array && array.length)
        ? baseExtremum(array, identity, baseLt)
        : undefined;
    }

    /**
     * This method is like `_.min` except that it accepts `iteratee` which is
     * invoked for each element in `array` to generate the criterion by which
     * the value is ranked. The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Math
     * @param {Array} array The array to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {*} Returns the minimum value.
     * @example
     *
     * var objects = [{ 'n': 1 }, { 'n': 2 }];
     *
     * _.minBy(objects, function(o) { return o.n; });
     * // => { 'n': 1 }
     *
     * // The `_.property` iteratee shorthand.
     * _.minBy(objects, 'n');
     * // => { 'n': 1 }
     */
    function minBy(array, iteratee) {
      return (array && array.length)
        ? baseExtremum(array, getIteratee(iteratee, 2), baseLt)
        : undefined;
    }

    /**
     * Multiply two numbers.
     *
     * @static
     * @memberOf _
     * @since 4.7.0
     * @category Math
     * @param {number} multiplier The first number in a multiplication.
     * @param {number} multiplicand The second number in a multiplication.
     * @returns {number} Returns the product.
     * @example
     *
     * _.multiply(6, 4);
     * // => 24
     */
    var multiply = createMathOperation(function(multiplier, multiplicand) {
      return multiplier * multiplicand;
    }, 1);

    /**
     * Computes `number` rounded to `precision`.
     *
     * @static
     * @memberOf _
     * @since 3.10.0
     * @category Math
     * @param {number} number The number to round.
     * @param {number} [precision=0] The precision to round to.
     * @returns {number} Returns the rounded number.
     * @example
     *
     * _.round(4.006);
     * // => 4
     *
     * _.round(4.006, 2);
     * // => 4.01
     *
     * _.round(4060, -2);
     * // => 4100
     */
    var round = createRound('round');

    /**
     * Subtract two numbers.
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Math
     * @param {number} minuend The first number in a subtraction.
     * @param {number} subtrahend The second number in a subtraction.
     * @returns {number} Returns the difference.
     * @example
     *
     * _.subtract(6, 4);
     * // => 2
     */
    var subtract = createMathOperation(function(minuend, subtrahend) {
      return minuend - subtrahend;
    }, 0);

    /**
     * Computes the sum of the values in `array`.
     *
     * @static
     * @memberOf _
     * @since 3.4.0
     * @category Math
     * @param {Array} array The array to iterate over.
     * @returns {number} Returns the sum.
     * @example
     *
     * _.sum([4, 2, 8, 6]);
     * // => 20
     */
    function sum(array) {
      return (array && array.length)
        ? baseSum(array, identity)
        : 0;
    }

    /**
     * This method is like `_.sum` except that it accepts `iteratee` which is
     * invoked for each element in `array` to generate the value to be summed.
     * The iteratee is invoked with one argument: (value).
     *
     * @static
     * @memberOf _
     * @since 4.0.0
     * @category Math
     * @param {Array} array The array to iterate over.
     * @param {Function} [iteratee=_.identity] The iteratee invoked per element.
     * @returns {number} Returns the sum.
     * @example
     *
     * var objects = [{ 'n': 4 }, { 'n': 2 }, { 'n': 8 }, { 'n': 6 }];
     *
     * _.sumBy(objects, function(o) { return o.n; });
     * // => 20
     *
     * // The `_.property` iteratee shorthand.
     * _.sumBy(objects, 'n');
     * // => 20
     */
    function sumBy(array, iteratee) {
      return (array && array.length)
        ? baseSum(array, getIteratee(iteratee, 2))
        : 0;
    }

    /*------------------------------------------------------------------------*/

    // Add methods that return wrapped values in chain sequences.
    lodash.after = after;
    lodash.ary = ary;
    lodash.assign = assign;
    lodash.assignIn = assignIn;
    lodash.assignInWith = assignInWith;
    lodash.assignWith = assignWith;
    lodash.at = at;
    lodash.before = before;
    lodash.bind = bind;
    lodash.bindAll = bindAll;
    lodash.bindKey = bindKey;
    lodash.castArray = castArray;
    lodash.chain = chain;
    lodash.chunk = chunk;
    lodash.compact = compact;
    lodash.concat = concat;
    lodash.cond = cond;
    lodash.conforms = conforms;
    lodash.constant = constant;
    lodash.countBy = countBy;
    lodash.create = create;
    lodash.curry = curry;
    lodash.curryRight = curryRight;
    lodash.debounce = debounce;
    lodash.defaults = defaults;
    lodash.defaultsDeep = defaultsDeep;
    lodash.defer = defer;
    lodash.delay = delay;
    lodash.difference = difference;
    lodash.differenceBy = differenceBy;
    lodash.differenceWith = differenceWith;
    lodash.drop = drop;
    lodash.dropRight = dropRight;
    lodash.dropRightWhile = dropRightWhile;
    lodash.dropWhile = dropWhile;
    lodash.fill = fill;
    lodash.filter = filter;
    lodash.flatMap = flatMap;
    lodash.flatMapDeep = flatMapDeep;
    lodash.flatMapDepth = flatMapDepth;
    lodash.flatten = flatten;
    lodash.flattenDeep = flattenDeep;
    lodash.flattenDepth = flattenDepth;
    lodash.flip = flip;
    lodash.flow = flow;
    lodash.flowRight = flowRight;
    lodash.fromPairs = fromPairs;
    lodash.functions = functions;
    lodash.functionsIn = functionsIn;
    lodash.groupBy = groupBy;
    lodash.initial = initial;
    lodash.intersection = intersection;
    lodash.intersectionBy = intersectionBy;
    lodash.intersectionWith = intersectionWith;
    lodash.invert = invert;
    lodash.invertBy = invertBy;
    lodash.invokeMap = invokeMap;
    lodash.iteratee = iteratee;
    lodash.keyBy = keyBy;
    lodash.keys = keys;
    lodash.keysIn = keysIn;
    lodash.map = map;
    lodash.mapKeys = mapKeys;
    lodash.mapValues = mapValues;
    lodash.matches = matches;
    lodash.matchesProperty = matchesProperty;
    lodash.memoize = memoize;
    lodash.merge = merge;
    lodash.mergeWith = mergeWith;
    lodash.method = method;
    lodash.methodOf = methodOf;
    lodash.mixin = mixin;
    lodash.negate = negate;
    lodash.nthArg = nthArg;
    lodash.omit = omit;
    lodash.omitBy = omitBy;
    lodash.once = once;
    lodash.orderBy = orderBy;
    lodash.over = over;
    lodash.overArgs = overArgs;
    lodash.overEvery = overEvery;
    lodash.overSome = overSome;
    lodash.partial = partial;
    lodash.partialRight = partialRight;
    lodash.partition = partition;
    lodash.pick = pick;
    lodash.pickBy = pickBy;
    lodash.property = property;
    lodash.propertyOf = propertyOf;
    lodash.pull = pull;
    lodash.pullAll = pullAll;
    lodash.pullAllBy = pullAllBy;
    lodash.pullAllWith = pullAllWith;
    lodash.pullAt = pullAt;
    lodash.range = range;
    lodash.rangeRight = rangeRight;
    lodash.rearg = rearg;
    lodash.reject = reject;
    lodash.remove = remove;
    lodash.rest = rest;
    lodash.reverse = reverse;
    lodash.sampleSize = sampleSize;
    lodash.set = set;
    lodash.setWith = setWith;
    lodash.shuffle = shuffle;
    lodash.slice = slice;
    lodash.sortBy = sortBy;
    lodash.sortedUniq = sortedUniq;
    lodash.sortedUniqBy = sortedUniqBy;
    lodash.split = split;
    lodash.spread = spread;
    lodash.tail = tail;
    lodash.take = take;
    lodash.takeRight = takeRight;
    lodash.takeRightWhile = takeRightWhile;
    lodash.takeWhile = takeWhile;
    lodash.tap = tap;
    lodash.throttle = throttle;
    lodash.thru = thru;
    lodash.toArray = toArray;
    lodash.toPairs = toPairs;
    lodash.toPairsIn = toPairsIn;
    lodash.toPath = toPath;
    lodash.toPlainObject = toPlainObject;
    lodash.transform = transform;
    lodash.unary = unary;
    lodash.union = union;
    lodash.unionBy = unionBy;
    lodash.unionWith = unionWith;
    lodash.uniq = uniq;
    lodash.uniqBy = uniqBy;
    lodash.uniqWith = uniqWith;
    lodash.unset = unset;
    lodash.unzip = unzip;
    lodash.unzipWith = unzipWith;
    lodash.update = update;
    lodash.updateWith = updateWith;
    lodash.values = values;
    lodash.valuesIn = valuesIn;
    lodash.without = without;
    lodash.words = words;
    lodash.wrap = wrap;
    lodash.xor = xor;
    lodash.xorBy = xorBy;
    lodash.xorWith = xorWith;
    lodash.zip = zip;
    lodash.zipObject = zipObject;
    lodash.zipObjectDeep = zipObjectDeep;
    lodash.zipWith = zipWith;

    // Add aliases.
    lodash.entries = toPairs;
    lodash.entriesIn = toPairsIn;
    lodash.extend = assignIn;
    lodash.extendWith = assignInWith;

    // Add methods to `lodash.prototype`.
    mixin(lodash, lodash);

    /*------------------------------------------------------------------------*/

    // Add methods that return unwrapped values in chain sequences.
    lodash.add = add;
    lodash.attempt = attempt;
    lodash.camelCase = camelCase;
    lodash.capitalize = capitalize;
    lodash.ceil = ceil;
    lodash.clamp = clamp;
    lodash.clone = clone;
    lodash.cloneDeep = cloneDeep;
    lodash.cloneDeepWith = cloneDeepWith;
    lodash.cloneWith = cloneWith;
    lodash.conformsTo = conformsTo;
    lodash.deburr = deburr;
    lodash.defaultTo = defaultTo;
    lodash.divide = divide;
    lodash.endsWith = endsWith;
    lodash.eq = eq;
    lodash.escape = escape;
    lodash.escapeRegExp = escapeRegExp;
    lodash.every = every;
    lodash.find = find;
    lodash.findIndex = findIndex;
    lodash.findKey = findKey;
    lodash.findLast = findLast;
    lodash.findLastIndex = findLastIndex;
    lodash.findLastKey = findLastKey;
    lodash.floor = floor;
    lodash.forEach = forEach;
    lodash.forEachRight = forEachRight;
    lodash.forIn = forIn;
    lodash.forInRight = forInRight;
    lodash.forOwn = forOwn;
    lodash.forOwnRight = forOwnRight;
    lodash.get = get;
    lodash.gt = gt;
    lodash.gte = gte;
    lodash.has = has;
    lodash.hasIn = hasIn;
    lodash.head = head;
    lodash.identity = identity;
    lodash.includes = includes;
    lodash.indexOf = indexOf;
    lodash.inRange = inRange;
    lodash.invoke = invoke;
    lodash.isArguments = isArguments;
    lodash.isArray = isArray;
    lodash.isArrayBuffer = isArrayBuffer;
    lodash.isArrayLike = isArrayLike;
    lodash.isArrayLikeObject = isArrayLikeObject;
    lodash.isBoolean = isBoolean;
    lodash.isBuffer = isBuffer;
    lodash.isDate = isDate;
    lodash.isElement = isElement;
    lodash.isEmpty = isEmpty;
    lodash.isEqual = isEqual;
    lodash.isEqualWith = isEqualWith;
    lodash.isError = isError;
    lodash.isFinite = isFinite;
    lodash.isFunction = isFunction;
    lodash.isInteger = isInteger;
    lodash.isLength = isLength;
    lodash.isMap = isMap;
    lodash.isMatch = isMatch;
    lodash.isMatchWith = isMatchWith;
    lodash.isNaN = isNaN;
    lodash.isNative = isNative;
    lodash.isNil = isNil;
    lodash.isNull = isNull;
    lodash.isNumber = isNumber;
    lodash.isObject = isObject;
    lodash.isObjectLike = isObjectLike;
    lodash.isPlainObject = isPlainObject;
    lodash.isRegExp = isRegExp;
    lodash.isSafeInteger = isSafeInteger;
    lodash.isSet = isSet;
    lodash.isString = isString;
    lodash.isSymbol = isSymbol;
    lodash.isTypedArray = isTypedArray;
    lodash.isUndefined = isUndefined;
    lodash.isWeakMap = isWeakMap;
    lodash.isWeakSet = isWeakSet;
    lodash.join = join;
    lodash.kebabCase = kebabCase;
    lodash.last = last;
    lodash.lastIndexOf = lastIndexOf;
    lodash.lowerCase = lowerCase;
    lodash.lowerFirst = lowerFirst;
    lodash.lt = lt;
    lodash.lte = lte;
    lodash.max = max;
    lodash.maxBy = maxBy;
    lodash.mean = mean;
    lodash.meanBy = meanBy;
    lodash.min = min;
    lodash.minBy = minBy;
    lodash.stubArray = stubArray;
    lodash.stubFalse = stubFalse;
    lodash.stubObject = stubObject;
    lodash.stubString = stubString;
    lodash.stubTrue = stubTrue;
    lodash.multiply = multiply;
    lodash.nth = nth;
    lodash.noConflict = noConflict;
    lodash.noop = noop;
    lodash.now = now;
    lodash.pad = pad;
    lodash.padEnd = padEnd;
    lodash.padStart = padStart;
    lodash.parseInt = parseInt;
    lodash.random = random;
    lodash.reduce = reduce;
    lodash.reduceRight = reduceRight;
    lodash.repeat = repeat;
    lodash.replace = replace;
    lodash.result = result;
    lodash.round = round;
    lodash.runInContext = runInContext;
    lodash.sample = sample;
    lodash.size = size;
    lodash.snakeCase = snakeCase;
    lodash.some = some;
    lodash.sortedIndex = sortedIndex;
    lodash.sortedIndexBy = sortedIndexBy;
    lodash.sortedIndexOf = sortedIndexOf;
    lodash.sortedLastIndex = sortedLastIndex;
    lodash.sortedLastIndexBy = sortedLastIndexBy;
    lodash.sortedLastIndexOf = sortedLastIndexOf;
    lodash.startCase = startCase;
    lodash.startsWith = startsWith;
    lodash.subtract = subtract;
    lodash.sum = sum;
    lodash.sumBy = sumBy;
    lodash.template = template;
    lodash.times = times;
    lodash.toFinite = toFinite;
    lodash.toInteger = toInteger;
    lodash.toLength = toLength;
    lodash.toLower = toLower;
    lodash.toNumber = toNumber;
    lodash.toSafeInteger = toSafeInteger;
    lodash.toString = toString;
    lodash.toUpper = toUpper;
    lodash.trim = trim;
    lodash.trimEnd = trimEnd;
    lodash.trimStart = trimStart;
    lodash.truncate = truncate;
    lodash.unescape = unescape;
    lodash.uniqueId = uniqueId;
    lodash.upperCase = upperCase;
    lodash.upperFirst = upperFirst;

    // Add aliases.
    lodash.each = forEach;
    lodash.eachRight = forEachRight;
    lodash.first = head;

    mixin(lodash, (function() {
      var source = {};
      baseForOwn(lodash, function(func, methodName) {
        if (!hasOwnProperty.call(lodash.prototype, methodName)) {
          source[methodName] = func;
        }
      });
      return source;
    }()), { 'chain': false });

    /*------------------------------------------------------------------------*/

    /**
     * The semantic version number.
     *
     * @static
     * @memberOf _
     * @type {string}
     */
    lodash.VERSION = VERSION;

    // Assign default placeholders.
    arrayEach(['bind', 'bindKey', 'curry', 'curryRight', 'partial', 'partialRight'], function(methodName) {
      lodash[methodName].placeholder = lodash;
    });

    // Add `LazyWrapper` methods for `_.drop` and `_.take` variants.
    arrayEach(['drop', 'take'], function(methodName, index) {
      LazyWrapper.prototype[methodName] = function(n) {
        n = n === undefined ? 1 : nativeMax(toInteger(n), 0);

        var result = (this.__filtered__ && !index)
          ? new LazyWrapper(this)
          : this.clone();

        if (result.__filtered__) {
          result.__takeCount__ = nativeMin(n, result.__takeCount__);
        } else {
          result.__views__.push({
            'size': nativeMin(n, MAX_ARRAY_LENGTH),
            'type': methodName + (result.__dir__ < 0 ? 'Right' : '')
          });
        }
        return result;
      };

      LazyWrapper.prototype[methodName + 'Right'] = function(n) {
        return this.reverse()[methodName](n).reverse();
      };
    });

    // Add `LazyWrapper` methods that accept an `iteratee` value.
    arrayEach(['filter', 'map', 'takeWhile'], function(methodName, index) {
      var type = index + 1,
          isFilter = type == LAZY_FILTER_FLAG || type == LAZY_WHILE_FLAG;

      LazyWrapper.prototype[methodName] = function(iteratee) {
        var result = this.clone();
        result.__iteratees__.push({
          'iteratee': getIteratee(iteratee, 3),
          'type': type
        });
        result.__filtered__ = result.__filtered__ || isFilter;
        return result;
      };
    });

    // Add `LazyWrapper` methods for `_.head` and `_.last`.
    arrayEach(['head', 'last'], function(methodName, index) {
      var takeName = 'take' + (index ? 'Right' : '');

      LazyWrapper.prototype[methodName] = function() {
        return this[takeName](1).value()[0];
      };
    });

    // Add `LazyWrapper` methods for `_.initial` and `_.tail`.
    arrayEach(['initial', 'tail'], function(methodName, index) {
      var dropName = 'drop' + (index ? '' : 'Right');

      LazyWrapper.prototype[methodName] = function() {
        return this.__filtered__ ? new LazyWrapper(this) : this[dropName](1);
      };
    });

    LazyWrapper.prototype.compact = function() {
      return this.filter(identity);
    };

    LazyWrapper.prototype.find = function(predicate) {
      return this.filter(predicate).head();
    };

    LazyWrapper.prototype.findLast = function(predicate) {
      return this.reverse().find(predicate);
    };

    LazyWrapper.prototype.invokeMap = baseRest(function(path, args) {
      if (typeof path == 'function') {
        return new LazyWrapper(this);
      }
      return this.map(function(value) {
        return baseInvoke(value, path, args);
      });
    });

    LazyWrapper.prototype.reject = function(predicate) {
      return this.filter(negate(getIteratee(predicate)));
    };

    LazyWrapper.prototype.slice = function(start, end) {
      start = toInteger(start);

      var result = this;
      if (result.__filtered__ && (start > 0 || end < 0)) {
        return new LazyWrapper(result);
      }
      if (start < 0) {
        result = result.takeRight(-start);
      } else if (start) {
        result = result.drop(start);
      }
      if (end !== undefined) {
        end = toInteger(end);
        result = end < 0 ? result.dropRight(-end) : result.take(end - start);
      }
      return result;
    };

    LazyWrapper.prototype.takeRightWhile = function(predicate) {
      return this.reverse().takeWhile(predicate).reverse();
    };

    LazyWrapper.prototype.toArray = function() {
      return this.take(MAX_ARRAY_LENGTH);
    };

    // Add `LazyWrapper` methods to `lodash.prototype`.
    baseForOwn(LazyWrapper.prototype, function(func, methodName) {
      var checkIteratee = /^(?:filter|find|map|reject)|While$/.test(methodName),
          isTaker = /^(?:head|last)$/.test(methodName),
          lodashFunc = lodash[isTaker ? ('take' + (methodName == 'last' ? 'Right' : '')) : methodName],
          retUnwrapped = isTaker || /^find/.test(methodName);

      if (!lodashFunc) {
        return;
      }
      lodash.prototype[methodName] = function() {
        var value = this.__wrapped__,
            args = isTaker ? [1] : arguments,
            isLazy = value instanceof LazyWrapper,
            iteratee = args[0],
            useLazy = isLazy || isArray(value);

        var interceptor = function(value) {
          var result = lodashFunc.apply(lodash, arrayPush([value], args));
          return (isTaker && chainAll) ? result[0] : result;
        };

        if (useLazy && checkIteratee && typeof iteratee == 'function' && iteratee.length != 1) {
          // Avoid lazy use if the iteratee has a "length" value other than `1`.
          isLazy = useLazy = false;
        }
        var chainAll = this.__chain__,
            isHybrid = !!this.__actions__.length,
            isUnwrapped = retUnwrapped && !chainAll,
            onlyLazy = isLazy && !isHybrid;

        if (!retUnwrapped && useLazy) {
          value = onlyLazy ? value : new LazyWrapper(this);
          var result = func.apply(value, args);
          result.__actions__.push({ 'func': thru, 'args': [interceptor], 'thisArg': undefined });
          return new LodashWrapper(result, chainAll);
        }
        if (isUnwrapped && onlyLazy) {
          return func.apply(this, args);
        }
        result = this.thru(interceptor);
        return isUnwrapped ? (isTaker ? result.value()[0] : result.value()) : result;
      };
    });

    // Add `Array` methods to `lodash.prototype`.
    arrayEach(['pop', 'push', 'shift', 'sort', 'splice', 'unshift'], function(methodName) {
      var func = arrayProto[methodName],
          chainName = /^(?:push|sort|unshift)$/.test(methodName) ? 'tap' : 'thru',
          retUnwrapped = /^(?:pop|shift)$/.test(methodName);

      lodash.prototype[methodName] = function() {
        var args = arguments;
        if (retUnwrapped && !this.__chain__) {
          var value = this.value();
          return func.apply(isArray(value) ? value : [], args);
        }
        return this[chainName](function(value) {
          return func.apply(isArray(value) ? value : [], args);
        });
      };
    });

    // Map minified method names to their real names.
    baseForOwn(LazyWrapper.prototype, function(func, methodName) {
      var lodashFunc = lodash[methodName];
      if (lodashFunc) {
        var key = lodashFunc.name + '';
        if (!hasOwnProperty.call(realNames, key)) {
          realNames[key] = [];
        }
        realNames[key].push({ 'name': methodName, 'func': lodashFunc });
      }
    });

    realNames[createHybrid(undefined, WRAP_BIND_KEY_FLAG).name] = [{
      'name': 'wrapper',
      'func': undefined
    }];

    // Add methods to `LazyWrapper`.
    LazyWrapper.prototype.clone = lazyClone;
    LazyWrapper.prototype.reverse = lazyReverse;
    LazyWrapper.prototype.value = lazyValue;

    // Add chain sequence methods to the `lodash` wrapper.
    lodash.prototype.at = wrapperAt;
    lodash.prototype.chain = wrapperChain;
    lodash.prototype.commit = wrapperCommit;
    lodash.prototype.next = wrapperNext;
    lodash.prototype.plant = wrapperPlant;
    lodash.prototype.reverse = wrapperReverse;
    lodash.prototype.toJSON = lodash.prototype.valueOf = lodash.prototype.value = wrapperValue;

    // Add lazy aliases.
    lodash.prototype.first = lodash.prototype.head;

    if (symIterator) {
      lodash.prototype[symIterator] = wrapperToIterator;
    }
    return lodash;
  });

  /*--------------------------------------------------------------------------*/

  // Export lodash.
  var _ = runInContext();

  // Some AMD build optimizers, like r.js, check for condition patterns like:
  if (true) {
    // Expose Lodash on the global object to prevent errors when Lodash is
    // loaded by a script tag in the presence of an AMD loader.
    // See http://requirejs.org/docs/errors.html#mismatch for more details.
    // Use `_.noConflict` to remove Lodash from the global object.
    root._ = _;

    // Define as an anonymous module so, through path mapping, it can be
    // referenced as the "underscore" module.
    !(__WEBPACK_AMD_DEFINE_RESULT__ = (function() {
      return _;
    }).call(exports, __webpack_require__, exports, module),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
  }
  // Check for `exports` after `define` in case a build optimizer adds it.
  else {}
}.call(this));

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9), __webpack_require__(23)(module)))

/***/ }),
/* 2 */,
/* 3 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 */
/* harmony default export */ __webpack_exports__["a"] = (function (condition, timeout, interval) {
  return new Promise(function (resolve, reject) {
    interval = interval || 50;
    let until = timeout ? new Date().getTime() + timeout : Infinity;

    let fn = function fn() {
      let result = condition();

      if (!result) {
        if (new Date().getTime() > until) {
          return reject(new Error('did not succeed in given time interval'));
        } else {
          return window.setTimeout(fn, interval);
        }
      }

      resolve(result);
    };

    fn();
  });
});
;

/***/ }),
/* 4 */,
/* 5 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// @flow

var parse = __webpack_require__(10)
var interpret = __webpack_require__(11)
var plurals = __webpack_require__(8)
var lookupClosestLocale = __webpack_require__(7)
var origFormats = __webpack_require__(6)

/*::
import type { Types } from 'format-message-interpret'
type Locale = string
type Locales = Locale | Locale[]
type Message = string | {|
  id?: string,
  default: string,
  description?: string
|}
type Translations = { [string]: ?{ [string]: string | Translation } }
type Translation = {
  message: string,
  format?: (args?: Object) => string,
  toParts?: (args?: Object) => any[],
}
type Replacement = ?string | (string, string, locales?: Locales) => ?string
type GenerateId = (string) => string
type MissingTranslation = 'ignore' | 'warning' | 'error'
type FormatObject = { [string]: * }
type Options = {
  locale?: Locales,
  translations?: ?Translations,
  generateId?: GenerateId,
  missingReplacement?: Replacement,
  missingTranslation?: MissingTranslation,
  formats?: {
    number?: FormatObject,
    date?: FormatObject,
    time?: FormatObject
  },
  types?: Types
}
type Setup = {|
  locale: Locales,
  translations: Translations,
  generateId: GenerateId,
  missingReplacement: Replacement,
  missingTranslation: MissingTranslation,
  formats: {
    number: FormatObject,
    date: FormatObject,
    time: FormatObject
  },
  types: Types
|}
type FormatMessage = {
  (msg: Message, args?: Object, locales?: Locales): string,
  rich (msg: Message, args?: Object, locales?: Locales): any[],
  setup (opt?: Options): Setup,
  number (value: number, style?: string, locales?: Locales): string,
  date (value: number | Date, style?: string, locales?: Locales): string,
  time (value: number | Date, style?: string, locales?: Locales): string,
  select (value: any, options: Object): any,
  custom (placeholder: any[], locales: Locales, value: any, args: Object): any,
  plural (value: number, offset: any, options: any, locale: any): any,
  selectordinal (value: number, offset: any, options: any, locale: any): any,
  namespace (): FormatMessage
}
*/

function assign/*:: <T: Object> */ (target/*: T */, source/*: Object */) {
  Object.keys(source).forEach(function (key) { target[key] = source[key] })
  return target
}

function namespace ()/*: FormatMessage */ {
  var formats = assign({}, origFormats)
  var currentLocales/*: Locales */ = 'en'
  var translations/*: Translations */ = {}
  var generateId/*: GenerateId */ = function (pattern) { return pattern }
  var missingReplacement/*: Replacement */ = null
  var missingTranslation/*: MissingTranslation */ = 'warning'
  var types/*: Types */ = {}

  function formatMessage (msg/*: Message */, args/*:: ?: Object */, locales/*:: ?: Locales */) {
    var pattern = typeof msg === 'string' ? msg : msg.default
    var id = (typeof msg === 'object' && msg.id) || generateId(pattern)
    var translated = translate(pattern, id, locales || currentLocales)
    var format = translated.format || (
      translated.format = interpret(parse(translated.message), locales || currentLocales, types)
    )
    return format(args)
  }

  formatMessage.rich = function rich (msg/*: Message */, args/*:: ?: Object */, locales/*:: ?: Locales */) {
    var pattern = typeof msg === 'string' ? msg : msg.default
    var id = (typeof msg === 'object' && msg.id) || generateId(pattern)
    var translated = translate(pattern, id, locales || currentLocales)
    var format = translated.toParts || (
      translated.toParts = interpret.toParts(parse(translated.message, { tagsType: tagsType }), locales || currentLocales, types)
    )
    return format(args)
  }

  var tagsType = '<>'
  function richType (node/*: any[] */, locales/*: Locales */) {
    var style = node[2]
    return function (fn, args) {
      var props = typeof style === 'object' ? mapObject(style, args) : style
      return typeof fn === 'function' ? fn(props) : fn
    }
  }
  types[tagsType] = richType

  function mapObject (object/* { [string]: (args?: Object) => any } */, args/*: ?Object */) {
    return Object.keys(object).reduce(function (mapped, key) {
      mapped[key] = object[key](args)
      return mapped
    }, {})
  }

  function translate (pattern/*: string */, id/*: string */, locales/*: Locales */)/*: Translation */ {
    var locale = lookupClosestLocale(locales, translations) || 'en'
    var messages = translations[locale] || (translations[locale] = {})
    var translated = messages[id]
    if (typeof translated === 'string') {
      translated = messages[id] = { message: translated }
    }
    if (!translated) {
      var message = 'Translation for "' + id + '" in "' + locale + '" is missing'
      if (missingTranslation === 'warning') {
        /* istanbul ignore else */
        if (typeof console !== 'undefined') console.warn(message)
      } else if (missingTranslation !== 'ignore') { // 'error'
        throw new Error(message)
      }
      var replacement = typeof missingReplacement === 'function'
        ? missingReplacement(pattern, id, locale) || pattern
        : missingReplacement || pattern
      translated = messages[id] = { message: replacement }
    }
    return translated
  }

  formatMessage.setup = function setup (opt/*:: ?: Options */) {
    opt = opt || {}
    if (opt.locale) currentLocales = opt.locale
    if ('translations' in opt) translations = opt.translations || {}
    if (opt.generateId) generateId = opt.generateId
    if ('missingReplacement' in opt) missingReplacement = opt.missingReplacement
    if (opt.missingTranslation) missingTranslation = opt.missingTranslation
    if (opt.formats) {
      if (opt.formats.number) assign(formats.number, opt.formats.number)
      if (opt.formats.date) assign(formats.date, opt.formats.date)
      if (opt.formats.time) assign(formats.time, opt.formats.time)
    }
    if (opt.types) {
      types = opt.types
      types[tagsType] = richType
    }
    return {
      locale: currentLocales,
      translations: translations,
      generateId: generateId,
      missingReplacement: missingReplacement,
      missingTranslation: missingTranslation,
      formats: formats,
      types: types
    }
  }

  formatMessage.number = function (value/*: number */, style/*:: ?: string */, locales/*:: ?: Locales */) {
    var options = (style && formats.number[style]) ||
      formats.parseNumberPattern(style) ||
      formats.number.default
    return new Intl.NumberFormat(locales || currentLocales, options).format(value)
  }

  formatMessage.date = function (value/*:: ?: number | Date */, style/*:: ?: string */, locales/*:: ?: Locales */) {
    var options = (style && formats.date[style]) ||
      formats.parseDatePattern(style) ||
      formats.date.default
    return new Intl.DateTimeFormat(locales || currentLocales, options).format(value)
  }

  formatMessage.time = function (value/*:: ?: number | Date */, style/*:: ?: string */, locales/*:: ?: Locales */) {
    var options = (style && formats.time[style]) ||
      formats.parseDatePattern(style) ||
      formats.time.default
    return new Intl.DateTimeFormat(locales || currentLocales, options).format(value)
  }

  formatMessage.select = function (value/*: any */, options/*: Object */) {
    return options[value] || options.other
  }

  formatMessage.custom = function (placeholder/*: any[] */, locales/*: Locales */, value/*: any */, args/*: Object */) {
    if (!(placeholder[1] in types)) return value
    return types[placeholder[1]](placeholder, locales)(value, args)
  }

  formatMessage.plural = plural.bind(null, 'cardinal')
  formatMessage.selectordinal = plural.bind(null, 'ordinal')
  function plural (
    pluralType/*: 'cardinal' | 'ordinal' */,
    value/*: number */,
    offset/*: any */,
    options/*: any */,
    locale/*: any */
  ) {
    if (typeof offset === 'object' && typeof options !== 'object') { // offset is optional
      locale = options
      options = offset
      offset = 0
    }
    var closest = lookupClosestLocale(locale || currentLocales, plurals)
    var plural = (closest && plurals[closest][pluralType]) || returnOther
    return options['=' + +value] || options[plural(value - offset)] || options.other
  }
  function returnOther (/*:: n:number */) { return 'other' }

  formatMessage.namespace = namespace

  return formatMessage
}

module.exports = exports = namespace()


/***/ }),
/* 6 */
/***/ (function(module, exports) {

// @flow
var LONG = 'long'
var SHORT = 'short'
var NARROW = 'narrow'
var NUMERIC = 'numeric'
var TWODIGIT = '2-digit'

/**
 * formatting information
 **/
module.exports = {
  number: {
    decimal: {
      style: 'decimal'
    },
    integer: {
      style: 'decimal',
      maximumFractionDigits: 0
    },
    currency: {
      style: 'currency',
      currency: 'USD'
    },
    percent: {
      style: 'percent'
    },
    default: {
      style: 'decimal'
    }
  },
  date: {
    short: {
      month: NUMERIC,
      day: NUMERIC,
      year: TWODIGIT
    },
    medium: {
      month: SHORT,
      day: NUMERIC,
      year: NUMERIC
    },
    long: {
      month: LONG,
      day: NUMERIC,
      year: NUMERIC
    },
    full: {
      month: LONG,
      day: NUMERIC,
      year: NUMERIC,
      weekday: LONG
    },
    default: {
      month: SHORT,
      day: NUMERIC,
      year: NUMERIC
    }
  },
  time: {
    short: {
      hour: NUMERIC,
      minute: NUMERIC
    },
    medium: {
      hour: NUMERIC,
      minute: NUMERIC,
      second: NUMERIC
    },
    long: {
      hour: NUMERIC,
      minute: NUMERIC,
      second: NUMERIC,
      timeZoneName: SHORT
    },
    full: {
      hour: NUMERIC,
      minute: NUMERIC,
      second: NUMERIC,
      timeZoneName: SHORT
    },
    default: {
      hour: NUMERIC,
      minute: NUMERIC,
      second: NUMERIC
    }
  },
  duration: {
    default: {
      hours: {
        minimumIntegerDigits: 1,
        maximumFractionDigits: 0
      },
      minutes: {
        minimumIntegerDigits: 2,
        maximumFractionDigits: 0
      },
      seconds: {
        minimumIntegerDigits: 2,
        maximumFractionDigits: 3
      }
    }
  },
  parseNumberPattern: function (pattern/*: ?string */) {
    if (!pattern) return
    var options = {}
    var currency = pattern.match(/\b[A-Z]{3}\b/i)
    var syms = pattern.replace(/[^¤]/g, '').length
    if (!syms && currency) syms = 1
    if (syms) {
      options.style = 'currency'
      options.currencyDisplay = syms === 1 ? 'symbol' : syms === 2 ? 'code' : 'name'
      options.currency = currency ? currency[0].toUpperCase() : 'USD'
    } else if (pattern.indexOf('%') >= 0) {
      options.style = 'percent'
    }
    if (!/[@#0]/.test(pattern)) return options.style ? options : undefined
    options.useGrouping = pattern.indexOf(',') >= 0
    if (/E\+?[@#0]+/i.test(pattern) || pattern.indexOf('@') >= 0) {
      var size = pattern.replace(/E\+?[@#0]+|[^@#0]/gi, '')
      options.minimumSignificantDigits = Math.min(Math.max(size.replace(/[^@0]/g, '').length, 1), 21)
      options.maximumSignificantDigits = Math.min(Math.max(size.length, 1), 21)
    } else {
      var parts = pattern.replace(/[^#0.]/g, '').split('.')
      var integer = parts[0]
      var n = integer.length - 1
      while (integer[n] === '0') --n
      options.minimumIntegerDigits = Math.min(Math.max(integer.length - 1 - n, 1), 21)
      var fraction = parts[1] || ''
      n = 0
      while (fraction[n] === '0') ++n
      options.minimumFractionDigits = Math.min(Math.max(n, 0), 20)
      while (fraction[n] === '#') ++n
      options.maximumFractionDigits = Math.min(Math.max(n, 0), 20)
    }
    return options
  },
  parseDatePattern: function (pattern/*: ?string */) {
    if (!pattern) return
    var options = {}
    for (var i = 0; i < pattern.length;) {
      var current = pattern[i]
      var n = 1
      while (pattern[++i] === current) ++n
      switch (current) {
        case 'G':
          options.era = n === 5 ? NARROW : n === 4 ? LONG : SHORT
          break
        case 'y':
        case 'Y':
          options.year = n === 2 ? TWODIGIT : NUMERIC
          break
        case 'M':
        case 'L':
          n = Math.min(Math.max(n - 1, 0), 4)
          options.month = [ NUMERIC, TWODIGIT, SHORT, LONG, NARROW ][n]
          break
        case 'E':
        case 'e':
        case 'c':
          options.weekday = n === 5 ? NARROW : n === 4 ? LONG : SHORT
          break
        case 'd':
        case 'D':
          options.day = n === 2 ? TWODIGIT : NUMERIC
          break
        case 'h':
        case 'K':
          options.hour12 = true
          options.hour = n === 2 ? TWODIGIT : NUMERIC
          break
        case 'H':
        case 'k':
          options.hour12 = false
          options.hour = n === 2 ? TWODIGIT : NUMERIC
          break
        case 'm':
          options.minute = n === 2 ? TWODIGIT : NUMERIC
          break
        case 's':
        case 'S':
          options.second = n === 2 ? TWODIGIT : NUMERIC
          break
        case 'z':
        case 'Z':
        case 'v':
        case 'V':
          options.timeZoneName = n === 1 ? SHORT : LONG
          break
      }
    }
    return Object.keys(options).length ? options : undefined
  }
}


/***/ }),
/* 7 */
/***/ (function(module, exports) {

// @flow
// "lookup" algorithm http://tools.ietf.org/html/rfc4647#section-3.4
// assumes normalized language tags, and matches in a case sensitive manner
module.exports = function lookupClosestLocale (locale/*: string | string[] | void */, available/*: { [string]: any } */)/*: ?string */ {
  if (typeof locale === 'string' && available[locale]) return locale
  var locales = [].concat(locale || [])
  for (var l = 0, ll = locales.length; l < ll; ++l) {
    var current = locales[l].split('-')
    while (current.length) {
      var candidate = current.join('-')
      if (available[candidate]) return candidate
      current.pop()
    }
  }
}


/***/ }),
/* 8 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// @flow


/*:: export type Rule = 'zero' | 'one' | 'two' | 'few' | 'many' | 'other' */
var zero = 'zero', one = 'one', two = 'two', few = 'few', many = 'many', other = 'other'
var f = [
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return 0 <= n && n <= 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var n = +s
    return i === 0 || n === 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 0 ? zero
      : n === 1 ? one
      : n === 2 ? two
      : 3 <= n % 100 && n % 100 <= 10 ? few
      : 11 <= n % 100 && n % 100 <= 99 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    return i === 1 && v === 0 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n % 10 === 1 && n % 100 !== 11 ? one
      : (2 <= n % 10 && n % 10 <= 4) && (n % 100 < 12 || 14 < n % 100) ? few
      : n % 10 === 0 || (5 <= n % 10 && n % 10 <= 9) || (11 <= n % 100 && n % 100 <= 14) ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n % 10 === 1 && (n % 100 !== 11 && n % 100 !== 71 && n % 100 !== 91) ? one
      : n % 10 === 2 && (n % 100 !== 12 && n % 100 !== 72 && n % 100 !== 92) ? two
      : ((3 <= n % 10 && n % 10 <= 4) || n % 10 === 9) && ((n % 100 < 10 || 19 < n % 100) && (n % 100 < 70 || 79 < n % 100) && (n % 100 < 90 || 99 < n % 100)) ? few
      : n !== 0 && n % 1000000 === 0 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    var f = +(s + '.').split('.')[1]
    return v === 0 && i % 10 === 1 && i % 100 !== 11 || f % 10 === 1 && f % 100 !== 11 ? one
      : v === 0 && (2 <= i % 10 && i % 10 <= 4) && (i % 100 < 12 || 14 < i % 100) || (2 <= f % 10 && f % 10 <= 4) && (f % 100 < 12 || 14 < f % 100) ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    return i === 1 && v === 0 ? one
      : (2 <= i && i <= 4) && v === 0 ? few
      : v !== 0 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 0 ? zero
      : n === 1 ? one
      : n === 2 ? two
      : n === 3 ? few
      : n === 6 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var t = +('' + s).replace(/^[^.]*.?|0+$/g, '')
    var n = +s
    return n === 1 || t !== 0 && (i === 0 || i === 1) ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    var f = +(s + '.').split('.')[1]
    return v === 0 && i % 100 === 1 || f % 100 === 1 ? one
      : v === 0 && i % 100 === 2 || f % 100 === 2 ? two
      : v === 0 && (3 <= i % 100 && i % 100 <= 4) || (3 <= f % 100 && f % 100 <= 4) ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    return i === 0 || i === 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    var f = +(s + '.').split('.')[1]
    return v === 0 && (i === 1 || i === 2 || i === 3) || v === 0 && (i % 10 !== 4 && i % 10 !== 6 && i % 10 !== 9) || v !== 0 && (f % 10 !== 4 && f % 10 !== 6 && f % 10 !== 9) ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : n === 2 ? two
      : 3 <= n && n <= 6 ? few
      : 7 <= n && n <= 10 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 || n === 11 ? one
      : n === 2 || n === 12 ? two
      : ((3 <= n && n <= 10) || (13 <= n && n <= 19)) ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    return v === 0 && i % 10 === 1 ? one
      : v === 0 && i % 10 === 2 ? two
      : v === 0 && (i % 100 === 0 || i % 100 === 20 || i % 100 === 40 || i % 100 === 60 || i % 100 === 80) ? few
      : v !== 0 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    var n = +s
    return i === 1 && v === 0 ? one
      : i === 2 && v === 0 ? two
      : v === 0 && (n < 0 || 10 < n) && n % 10 === 0 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var t = +('' + s).replace(/^[^.]*.?|0+$/g, '')
    return t === 0 && i % 10 === 1 && i % 100 !== 11 || t !== 0 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : n === 2 ? two
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 0 ? zero
      : n === 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var n = +s
    return n === 0 ? zero
      : (i === 0 || i === 1) && n !== 0 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var f = +(s + '.').split('.')[1]
    var n = +s
    return n % 10 === 1 && (n % 100 < 11 || 19 < n % 100) ? one
      : (2 <= n % 10 && n % 10 <= 9) && (n % 100 < 11 || 19 < n % 100) ? few
      : f !== 0 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var v = (s + '.').split('.')[1].length
    var f = +(s + '.').split('.')[1]
    var n = +s
    return n % 10 === 0 || (11 <= n % 100 && n % 100 <= 19) || v === 2 && (11 <= f % 100 && f % 100 <= 19) ? zero
      : n % 10 === 1 && n % 100 !== 11 || v === 2 && f % 10 === 1 && f % 100 !== 11 || v !== 2 && f % 10 === 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    var f = +(s + '.').split('.')[1]
    return v === 0 && i % 10 === 1 && i % 100 !== 11 || f % 10 === 1 && f % 100 !== 11 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    var n = +s
    return i === 1 && v === 0 ? one
      : v !== 0 || n === 0 || n !== 1 && (1 <= n % 100 && n % 100 <= 19) ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : n === 0 || (2 <= n % 100 && n % 100 <= 10) ? few
      : 11 <= n % 100 && n % 100 <= 19 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    return i === 1 && v === 0 ? one
      : v === 0 && (2 <= i % 10 && i % 10 <= 4) && (i % 100 < 12 || 14 < i % 100) ? few
      : v === 0 && i !== 1 && (0 <= i % 10 && i % 10 <= 1) || v === 0 && (5 <= i % 10 && i % 10 <= 9) || v === 0 && (12 <= i % 100 && i % 100 <= 14) ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    return 0 <= i && i <= 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    return v === 0 && i % 10 === 1 && i % 100 !== 11 ? one
      : v === 0 && (2 <= i % 10 && i % 10 <= 4) && (i % 100 < 12 || 14 < i % 100) ? few
      : v === 0 && i % 10 === 0 || v === 0 && (5 <= i % 10 && i % 10 <= 9) || v === 0 && (11 <= i % 100 && i % 100 <= 14) ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var n = +s
    return i === 0 || n === 1 ? one
      : 2 <= n && n <= 10 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var f = +(s + '.').split('.')[1]
    var n = +s
    return (n === 0 || n === 1) || i === 0 && f === 1 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    var v = (s + '.').split('.')[1].length
    return v === 0 && i % 100 === 1 ? one
      : v === 0 && i % 100 === 2 ? two
      : v === 0 && (3 <= i % 100 && i % 100 <= 4) || v !== 0 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return (0 <= n && n <= 1) || (11 <= n && n <= 99) ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 || n === 5 || n === 7 || n === 8 || n === 9 || n === 10 ? one
      : n === 2 || n === 3 ? two
      : n === 4 ? few
      : n === 6 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    return (i % 10 === 1 || i % 10 === 2 || i % 10 === 5 || i % 10 === 7 || i % 10 === 8) || (i % 100 === 20 || i % 100 === 50 || i % 100 === 70 || i % 100 === 80) ? one
      : (i % 10 === 3 || i % 10 === 4) || (i % 1000 === 100 || i % 1000 === 200 || i % 1000 === 300 || i % 1000 === 400 || i % 1000 === 500 || i % 1000 === 600 || i % 1000 === 700 || i % 1000 === 800 || i % 1000 === 900) ? few
      : i === 0 || i % 10 === 6 || (i % 100 === 40 || i % 100 === 60 || i % 100 === 90) ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return (n % 10 === 2 || n % 10 === 3) && (n % 100 !== 12 && n % 100 !== 13) ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 || n === 3 ? one
      : n === 2 ? two
      : n === 4 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 0 || n === 7 || n === 8 || n === 9 ? zero
      : n === 1 ? one
      : n === 2 ? two
      : n === 3 || n === 4 ? few
      : n === 5 || n === 6 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n % 10 === 1 && n % 100 !== 11 ? one
      : n % 10 === 2 && n % 100 !== 12 ? two
      : n % 10 === 3 && n % 100 !== 13 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 || n === 11 ? one
      : n === 2 || n === 12 ? two
      : n === 3 || n === 13 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : n === 2 || n === 3 ? two
      : n === 4 ? few
      : n === 6 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 || n === 5 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 11 || n === 8 || n === 80 || n === 800 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    return i === 1 ? one
      : i === 0 || ((2 <= i % 100 && i % 100 <= 20) || i % 100 === 40 || i % 100 === 60 || i % 100 === 80) ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n % 10 === 6 || n % 10 === 9 || n % 10 === 0 && n !== 0 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var i = Math.floor(Math.abs(+s))
    return i % 10 === 1 && i % 100 !== 11 ? one
      : i % 10 === 2 && i % 100 !== 12 ? two
      : (i % 10 === 7 || i % 10 === 8) && (i % 100 !== 17 && i % 100 !== 18) ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : n === 2 || n === 3 ? two
      : n === 4 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return 1 <= n && n <= 4 ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return (n === 1 || n === 5 || (7 <= n && n <= 9)) ? one
      : n === 2 || n === 3 ? two
      : n === 4 ? few
      : n === 6 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n === 1 ? one
      : n % 10 === 4 && n % 100 !== 14 ? many
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return (n % 10 === 1 || n % 10 === 2) && (n % 100 !== 11 && n % 100 !== 12) ? one
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return (n % 10 === 6 || n % 10 === 9) || n === 10 ? few
      : other
  },
  function (s/*: string | number */)/*: Rule */ {
    var n = +s
    return n % 10 === 3 && n % 100 !== 13 ? few
      : other
  }
]

module.exports = {
  af: { cardinal: f[0] },
  ak: { cardinal: f[1] },
  am: { cardinal: f[2] },
  ar: { cardinal: f[3] },
  ars: { cardinal: f[3] },
  as: { cardinal: f[2], ordinal: f[34] },
  asa: { cardinal: f[0] },
  ast: { cardinal: f[4] },
  az: { cardinal: f[0], ordinal: f[35] },
  be: { cardinal: f[5], ordinal: f[36] },
  bem: { cardinal: f[0] },
  bez: { cardinal: f[0] },
  bg: { cardinal: f[0] },
  bh: { cardinal: f[1] },
  bn: { cardinal: f[2], ordinal: f[34] },
  br: { cardinal: f[6] },
  brx: { cardinal: f[0] },
  bs: { cardinal: f[7] },
  ca: { cardinal: f[4], ordinal: f[37] },
  ce: { cardinal: f[0] },
  cgg: { cardinal: f[0] },
  chr: { cardinal: f[0] },
  ckb: { cardinal: f[0] },
  cs: { cardinal: f[8] },
  cy: { cardinal: f[9], ordinal: f[38] },
  da: { cardinal: f[10] },
  de: { cardinal: f[4] },
  dsb: { cardinal: f[11] },
  dv: { cardinal: f[0] },
  ee: { cardinal: f[0] },
  el: { cardinal: f[0] },
  en: { cardinal: f[4], ordinal: f[39] },
  eo: { cardinal: f[0] },
  es: { cardinal: f[0] },
  et: { cardinal: f[4] },
  eu: { cardinal: f[0] },
  fa: { cardinal: f[2] },
  ff: { cardinal: f[12] },
  fi: { cardinal: f[4] },
  fil: { cardinal: f[13], ordinal: f[0] },
  fo: { cardinal: f[0] },
  fr: { cardinal: f[12], ordinal: f[0] },
  fur: { cardinal: f[0] },
  fy: { cardinal: f[4] },
  ga: { cardinal: f[14], ordinal: f[0] },
  gd: { cardinal: f[15], ordinal: f[40] },
  gl: { cardinal: f[4] },
  gsw: { cardinal: f[0] },
  gu: { cardinal: f[2], ordinal: f[41] },
  guw: { cardinal: f[1] },
  gv: { cardinal: f[16] },
  ha: { cardinal: f[0] },
  haw: { cardinal: f[0] },
  he: { cardinal: f[17] },
  hi: { cardinal: f[2], ordinal: f[41] },
  hr: { cardinal: f[7] },
  hsb: { cardinal: f[11] },
  hu: { cardinal: f[0], ordinal: f[42] },
  hy: { cardinal: f[12], ordinal: f[0] },
  ia: { cardinal: f[4] },
  io: { cardinal: f[4] },
  is: { cardinal: f[18] },
  it: { cardinal: f[4], ordinal: f[43] },
  iu: { cardinal: f[19] },
  iw: { cardinal: f[17] },
  jgo: { cardinal: f[0] },
  ji: { cardinal: f[4] },
  jmc: { cardinal: f[0] },
  ka: { cardinal: f[0], ordinal: f[44] },
  kab: { cardinal: f[12] },
  kaj: { cardinal: f[0] },
  kcg: { cardinal: f[0] },
  kk: { cardinal: f[0], ordinal: f[45] },
  kkj: { cardinal: f[0] },
  kl: { cardinal: f[0] },
  kn: { cardinal: f[2] },
  ks: { cardinal: f[0] },
  ksb: { cardinal: f[0] },
  ksh: { cardinal: f[20] },
  ku: { cardinal: f[0] },
  kw: { cardinal: f[19] },
  ky: { cardinal: f[0] },
  lag: { cardinal: f[21] },
  lb: { cardinal: f[0] },
  lg: { cardinal: f[0] },
  ln: { cardinal: f[1] },
  lt: { cardinal: f[22] },
  lv: { cardinal: f[23] },
  mas: { cardinal: f[0] },
  mg: { cardinal: f[1] },
  mgo: { cardinal: f[0] },
  mk: { cardinal: f[24], ordinal: f[46] },
  ml: { cardinal: f[0] },
  mn: { cardinal: f[0] },
  mo: { cardinal: f[25], ordinal: f[0] },
  mr: { cardinal: f[2], ordinal: f[47] },
  mt: { cardinal: f[26] },
  nah: { cardinal: f[0] },
  naq: { cardinal: f[19] },
  nb: { cardinal: f[0] },
  nd: { cardinal: f[0] },
  ne: { cardinal: f[0], ordinal: f[48] },
  nl: { cardinal: f[4] },
  nn: { cardinal: f[0] },
  nnh: { cardinal: f[0] },
  no: { cardinal: f[0] },
  nr: { cardinal: f[0] },
  nso: { cardinal: f[1] },
  ny: { cardinal: f[0] },
  nyn: { cardinal: f[0] },
  om: { cardinal: f[0] },
  or: { cardinal: f[0], ordinal: f[49] },
  os: { cardinal: f[0] },
  pa: { cardinal: f[1] },
  pap: { cardinal: f[0] },
  pl: { cardinal: f[27] },
  prg: { cardinal: f[23] },
  ps: { cardinal: f[0] },
  pt: { cardinal: f[28] },
  'pt-PT': { cardinal: f[4] },
  rm: { cardinal: f[0] },
  ro: { cardinal: f[25], ordinal: f[0] },
  rof: { cardinal: f[0] },
  ru: { cardinal: f[29] },
  rwk: { cardinal: f[0] },
  saq: { cardinal: f[0] },
  sc: { cardinal: f[4], ordinal: f[43] },
  scn: { cardinal: f[4], ordinal: f[43] },
  sd: { cardinal: f[0] },
  sdh: { cardinal: f[0] },
  se: { cardinal: f[19] },
  seh: { cardinal: f[0] },
  sh: { cardinal: f[7] },
  shi: { cardinal: f[30] },
  si: { cardinal: f[31] },
  sk: { cardinal: f[8] },
  sl: { cardinal: f[32] },
  sma: { cardinal: f[19] },
  smi: { cardinal: f[19] },
  smj: { cardinal: f[19] },
  smn: { cardinal: f[19] },
  sms: { cardinal: f[19] },
  sn: { cardinal: f[0] },
  so: { cardinal: f[0] },
  sq: { cardinal: f[0], ordinal: f[50] },
  sr: { cardinal: f[7] },
  ss: { cardinal: f[0] },
  ssy: { cardinal: f[0] },
  st: { cardinal: f[0] },
  sv: { cardinal: f[4], ordinal: f[51] },
  sw: { cardinal: f[4] },
  syr: { cardinal: f[0] },
  ta: { cardinal: f[0] },
  te: { cardinal: f[0] },
  teo: { cardinal: f[0] },
  ti: { cardinal: f[1] },
  tig: { cardinal: f[0] },
  tk: { cardinal: f[0], ordinal: f[52] },
  tl: { cardinal: f[13], ordinal: f[0] },
  tn: { cardinal: f[0] },
  tr: { cardinal: f[0] },
  ts: { cardinal: f[0] },
  tzm: { cardinal: f[33] },
  ug: { cardinal: f[0] },
  uk: { cardinal: f[29], ordinal: f[53] },
  ur: { cardinal: f[4] },
  uz: { cardinal: f[0] },
  ve: { cardinal: f[0] },
  vo: { cardinal: f[0] },
  vun: { cardinal: f[0] },
  wa: { cardinal: f[1] },
  wae: { cardinal: f[0] },
  xh: { cardinal: f[0] },
  xog: { cardinal: f[0] },
  yi: { cardinal: f[4] },
  zu: { cardinal: f[2] },
  lo: { ordinal: f[0] },
  ms: { ordinal: f[0] },
  vi: { ordinal: f[0] }
}


/***/ }),
/* 9 */
/***/ (function(module, exports) {

var g;

// This works in non-strict mode
g = (function() {
	return this;
})();

try {
	// This works if eval is allowed (see CSP)
	g = g || new Function("return this")();
} catch (e) {
	// This works if the window reference is available
	if (typeof window === "object") g = window;
}

// g can still be undefined, but nothing to do about it...
// We return undefined, instead of nothing here, so it's
// easier to handle this case. if(!global) { ...}

module.exports = g;


/***/ }),
/* 10 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// @flow


/*::
export type AST = Element[]
export type Element = string | Placeholder
export type Placeholder = Plural | Styled | Typed | Simple
export type Plural = [ string, 'plural' | 'selectordinal', number, SubMessages ]
export type Styled = [ string, string, string | SubMessages ]
export type Typed = [ string, string ]
export type Simple = [ string ]
export type SubMessages = { [string]: AST }
export type Token = [ TokenType, string ]
export type TokenType = 'text' | 'space' | 'id' | 'type' | 'style' | 'offset' | 'number' | 'selector' | 'syntax'
type Context = {|
  pattern: string,
  index: number,
  tagsType: ?string,
  tokens: ?Token[]
|}
*/

var ARG_OPN = '{'
var ARG_CLS = '}'
var ARG_SEP = ','
var NUM_ARG = '#'
var TAG_OPN = '<'
var TAG_CLS = '>'
var TAG_END = '</'
var TAG_SELF_CLS = '/>'
var ESC = '\''
var OFFSET = 'offset:'
var simpleTypes = [
  'number',
  'date',
  'time',
  'ordinal',
  'duration',
  'spellout'
]
var submTypes = [
  'plural',
  'select',
  'selectordinal'
]

/**
 * parse
 *
 * Turns this:
 *  `You have { numBananas, plural,
 *       =0 {no bananas}
 *      one {a banana}
 *    other {# bananas}
 *  } for sale`
 *
 * into this:
 *  [ "You have ", [ "numBananas", "plural", 0, {
 *       "=0": [ "no bananas" ],
 *      "one": [ "a banana" ],
 *    "other": [ [ '#' ], " bananas" ]
 *  } ], " for sale." ]
 *
 * tokens:
 *  [
 *    [ "text", "You have " ],
 *    [ "syntax", "{" ],
 *    [ "space", " " ],
 *    [ "id", "numBananas" ],
 *    [ "syntax", ", " ],
 *    [ "space", " " ],
 *    [ "type", "plural" ],
 *    [ "syntax", "," ],
 *    [ "space", "\n     " ],
 *    [ "selector", "=0" ],
 *    [ "space", " " ],
 *    [ "syntax", "{" ],
 *    [ "text", "no bananas" ],
 *    [ "syntax", "}" ],
 *    [ "space", "\n    " ],
 *    [ "selector", "one" ],
 *    [ "space", " " ],
 *    [ "syntax", "{" ],
 *    [ "text", "a banana" ],
 *    [ "syntax", "}" ],
 *    [ "space", "\n  " ],
 *    [ "selector", "other" ],
 *    [ "space", " " ],
 *    [ "syntax", "{" ],
 *    [ "syntax", "#" ],
 *    [ "text", " bananas" ],
 *    [ "syntax", "}" ],
 *    [ "space", "\n" ],
 *    [ "syntax", "}" ],
 *    [ "text", " for sale." ]
 *  ]
 **/
exports = module.exports = function parse (
  pattern/*: string */,
  options/*:: ?: { tagsType?: string, tokens?: Token[] } */
)/*: AST */ {
  return parseAST({
    pattern: String(pattern),
    index: 0,
    tagsType: (options && options.tagsType) || null,
    tokens: (options && options.tokens) || null
  }, '')
}

function parseAST (current/*: Context */, parentType/*: string */)/*: AST */ {
  var pattern = current.pattern
  var length = pattern.length
  var elements/*: AST */ = []
  var start = current.index
  var text = parseText(current, parentType)
  if (text) elements.push(text)
  if (text && current.tokens) current.tokens.push([ 'text', pattern.slice(start, current.index) ])
  while (current.index < length) {
    if (pattern[current.index] === ARG_CLS) {
      if (!parentType) throw expected(current)
      break
    }
    if (parentType && current.tagsType && pattern.slice(current.index, current.index + TAG_END.length) === TAG_END) break
    elements.push(parsePlaceholder(current))
    start = current.index
    text = parseText(current, parentType)
    if (text) elements.push(text)
    if (text && current.tokens) current.tokens.push([ 'text', pattern.slice(start, current.index) ])
  }
  return elements
}

function parseText (current/*: Context */, parentType/*: string */)/*: string */ {
  var pattern = current.pattern
  var length = pattern.length
  var isHashSpecial = (parentType === 'plural' || parentType === 'selectordinal')
  var isAngleSpecial = !!current.tagsType
  var isArgStyle = (parentType === '{style}')
  var text = ''
  while (current.index < length) {
    var char = pattern[current.index]
    if (
      char === ARG_OPN || char === ARG_CLS ||
      (isHashSpecial && char === NUM_ARG) ||
      (isAngleSpecial && char === TAG_OPN) ||
      (isArgStyle && isWhitespace(char.charCodeAt(0)))
    ) {
      break
    } else if (char === ESC) {
      char = pattern[++current.index]
      if (char === ESC) { // double is always 1 '
        text += char
        ++current.index
      } else if (
        // only when necessary
        char === ARG_OPN || char === ARG_CLS ||
        (isHashSpecial && char === NUM_ARG) ||
        (isAngleSpecial && char === TAG_OPN) ||
        isArgStyle
      ) {
        text += char
        while (++current.index < length) {
          char = pattern[current.index]
          if (char === ESC && pattern[current.index + 1] === ESC) { // double is always 1 '
            text += ESC
            ++current.index
          } else if (char === ESC) { // end of quoted
            ++current.index
            break
          } else {
            text += char
          }
        }
      } else { // lone ' is just a '
        text += ESC
        // already incremented
      }
    } else {
      text += char
      ++current.index
    }
  }
  return text
}

function isWhitespace (code/*: number */)/*: boolean */ {
  return (
    (code >= 0x09 && code <= 0x0D) ||
    code === 0x20 || code === 0x85 || code === 0xA0 || code === 0x180E ||
    (code >= 0x2000 && code <= 0x200D) ||
    code === 0x2028 || code === 0x2029 || code === 0x202F || code === 0x205F ||
    code === 0x2060 || code === 0x3000 || code === 0xFEFF
  )
}

function skipWhitespace (current/*: Context */)/*: void */ {
  var pattern = current.pattern
  var length = pattern.length
  var start = current.index
  while (current.index < length && isWhitespace(pattern.charCodeAt(current.index))) {
    ++current.index
  }
  if (start < current.index && current.tokens) {
    current.tokens.push([ 'space', current.pattern.slice(start, current.index) ])
  }
}

function parsePlaceholder (current/*: Context */)/*: Placeholder */ {
  var pattern = current.pattern
  if (pattern[current.index] === NUM_ARG) {
    if (current.tokens) current.tokens.push([ 'syntax', NUM_ARG ])
    ++current.index // move passed #
    return [ NUM_ARG ]
  }

  var tag = parseTag(current)
  if (tag) return tag

  /* istanbul ignore if should be unreachable if parseAST and parseText are right */
  if (pattern[current.index] !== ARG_OPN) throw expected(current, ARG_OPN)
  if (current.tokens) current.tokens.push([ 'syntax', ARG_OPN ])
  ++current.index // move passed {
  skipWhitespace(current)

  var id = parseId(current)
  if (!id) throw expected(current, 'placeholder id')
  if (current.tokens) current.tokens.push([ 'id', id ])
  skipWhitespace(current)

  var char = pattern[current.index]
  if (char === ARG_CLS) { // end placeholder
    if (current.tokens) current.tokens.push([ 'syntax', ARG_CLS ])
    ++current.index // move passed }
    return [ id ]
  }

  if (char !== ARG_SEP) throw expected(current, ARG_SEP + ' or ' + ARG_CLS)
  if (current.tokens) current.tokens.push([ 'syntax', ARG_SEP ])
  ++current.index // move passed ,
  skipWhitespace(current)

  var type = parseId(current)
  if (!type) throw expected(current, 'placeholder type')
  if (current.tokens) current.tokens.push([ 'type', type ])
  skipWhitespace(current)
  char = pattern[current.index]
  if (char === ARG_CLS) { // end placeholder
    if (current.tokens) current.tokens.push([ 'syntax', ARG_CLS ])
    if (type === 'plural' || type === 'selectordinal' || type === 'select') {
      throw expected(current, type + ' sub-messages')
    }
    ++current.index // move passed }
    return [ id, type ]
  }

  if (char !== ARG_SEP) throw expected(current, ARG_SEP + ' or ' + ARG_CLS)
  if (current.tokens) current.tokens.push([ 'syntax', ARG_SEP ])
  ++current.index // move passed ,
  skipWhitespace(current)

  var arg
  if (type === 'plural' || type === 'selectordinal') {
    var offset = parsePluralOffset(current)
    skipWhitespace(current)
    arg = [ id, type, offset, parseSubMessages(current, type) ]
  } else if (type === 'select') {
    arg = [ id, type, parseSubMessages(current, type) ]
  } else if (simpleTypes.indexOf(type) >= 0) {
    arg = [ id, type, parseSimpleFormat(current) ]
  } else { // custom placeholder type
    var index = current.index
    var format/*: string | SubMessages */ = parseSimpleFormat(current)
    skipWhitespace(current)
    if (pattern[current.index] === ARG_OPN) {
      current.index = index // rewind, since should have been submessages
      format = parseSubMessages(current, type)
    }
    arg = [ id, type, format ]
  }

  skipWhitespace(current)
  if (pattern[current.index] !== ARG_CLS) throw expected(current, ARG_CLS)
  if (current.tokens) current.tokens.push([ 'syntax', ARG_CLS ])
  ++current.index // move passed }
  return arg
}

function parseTag (current/*: Context */)/*: ?Placeholder */ {
  var tagsType = current.tagsType
  if (!tagsType || current.pattern[current.index] !== TAG_OPN) return

  if (current.pattern.slice(current.index, current.index + TAG_END.length) === TAG_END) {
    throw expected(current, null, 'closing tag without matching opening tag')
  }
  if (current.tokens) current.tokens.push([ 'syntax', TAG_OPN ])
  ++current.index // move passed <

  var id = parseId(current, true)
  if (!id) throw expected(current, 'placeholder id')
  if (current.tokens) current.tokens.push([ 'id', id ])
  skipWhitespace(current)

  if (current.pattern.slice(current.index, current.index + TAG_SELF_CLS.length) === TAG_SELF_CLS) {
    if (current.tokens) current.tokens.push([ 'syntax', TAG_SELF_CLS ])
    current.index += TAG_SELF_CLS.length
    return [ id, tagsType ]
  }
  if (current.pattern[current.index] !== TAG_CLS) throw expected(current, TAG_CLS)
  if (current.tokens) current.tokens.push([ 'syntax', TAG_CLS ])
  ++current.index // move passed >

  var children = parseAST(current, tagsType)

  var end = current.index
  if (current.pattern.slice(current.index, current.index + TAG_END.length) !== TAG_END) throw expected(current, TAG_END + id + TAG_CLS)
  if (current.tokens) current.tokens.push([ 'syntax', TAG_END ])
  current.index += TAG_END.length
  var closeId = parseId(current, true)
  if (closeId && current.tokens) current.tokens.push([ 'id', closeId ])
  if (id !== closeId) {
    current.index = end // rewind for better error message
    throw expected(current, TAG_END + id + TAG_CLS, TAG_END + closeId + TAG_CLS)
  }
  skipWhitespace(current)
  if (current.pattern[current.index] !== TAG_CLS) throw expected(current, TAG_CLS)
  if (current.tokens) current.tokens.push([ 'syntax', TAG_CLS ])
  ++current.index // move passed >

  return [ id, tagsType, { children: children } ]
}

function parseId (current/*: Context */, isTag/*:: ?: boolean */)/*: string */ {
  var pattern = current.pattern
  var length = pattern.length
  var id = ''
  while (current.index < length) {
    var char = pattern[current.index]
    if (
      char === ARG_OPN || char === ARG_CLS || char === ARG_SEP ||
      char === NUM_ARG || char === ESC || isWhitespace(char.charCodeAt(0)) ||
      (isTag && (char === TAG_OPN || char === TAG_CLS || char === '/'))
    ) break
    id += char
    ++current.index
  }
  return id
}

function parseSimpleFormat (current/*: Context */)/*: string */ {
  var start = current.index
  var style = parseText(current, '{style}')
  if (!style) throw expected(current, 'placeholder style name')
  if (current.tokens) current.tokens.push([ 'style', current.pattern.slice(start, current.index) ])
  return style
}

function parsePluralOffset (current/*: Context */)/*: number */ {
  var pattern = current.pattern
  var length = pattern.length
  var offset = 0
  if (pattern.slice(current.index, current.index + OFFSET.length) === OFFSET) {
    if (current.tokens) current.tokens.push([ 'offset', 'offset' ], [ 'syntax', ':' ])
    current.index += OFFSET.length // move passed offset:
    skipWhitespace(current)
    var start = current.index
    while (current.index < length && isDigit(pattern.charCodeAt(current.index))) {
      ++current.index
    }
    if (start === current.index) throw expected(current, 'offset number')
    if (current.tokens) current.tokens.push([ 'number', pattern.slice(start, current.index) ])
    offset = +pattern.slice(start, current.index)
  }
  return offset
}

function isDigit (code/*: number */)/*: boolean */ {
  return (code >= 0x30 && code <= 0x39)
}

function parseSubMessages (current/*: Context */, parentType/*: string */)/*: SubMessages */ {
  var pattern = current.pattern
  var length = pattern.length
  var options/*: SubMessages */ = {}
  while (current.index < length && pattern[current.index] !== ARG_CLS) {
    var selector = parseId(current)
    if (!selector) throw expected(current, 'sub-message selector')
    if (current.tokens) current.tokens.push([ 'selector', selector ])
    skipWhitespace(current)
    options[selector] = parseSubMessage(current, parentType)
    skipWhitespace(current)
  }
  if (!options.other && submTypes.indexOf(parentType) >= 0) {
    throw expected(current, null, null, '"other" sub-message must be specified in ' + parentType)
  }
  return options
}

function parseSubMessage (current/*: Context */, parentType/*: string */)/*: AST */ {
  if (current.pattern[current.index] !== ARG_OPN) throw expected(current, ARG_OPN + ' to start sub-message')
  if (current.tokens) current.tokens.push([ 'syntax', ARG_OPN ])
  ++current.index // move passed {
  var message = parseAST(current, parentType)
  if (current.pattern[current.index] !== ARG_CLS) throw expected(current, ARG_CLS + ' to end sub-message')
  if (current.tokens) current.tokens.push([ 'syntax', ARG_CLS ])
  ++current.index // move passed }
  return message
}

function expected (current/*: Context */, expected/*:: ?: ?string */, found/*:: ?: ?string */, message/*:: ?: string */) {
  var pattern = current.pattern
  var lines = pattern.slice(0, current.index).split(/\r?\n/)
  var offset = current.index
  var line = lines.length
  var column = lines.slice(-1)[0].length
  found = found || (
    (current.index >= pattern.length) ? 'end of message pattern'
      : (parseId(current) || pattern[current.index])
  )
  if (!message) message = errorMessage(expected, found)
  message += ' in ' + pattern.replace(/\r?\n/g, '\n')
  return new SyntaxError(message, expected, found, offset, line, column)
}

function errorMessage (expected/*: ?string */, found/* string */) {
  if (!expected) return 'Unexpected ' + found + ' found'
  return 'Expected ' + expected + ' but found ' + found
}

/**
 * SyntaxError
 *  Holds information about bad syntax found in a message pattern
 **/
function SyntaxError (message/*: string */, expected/*: ?string */, found/*: ?string */, offset/*: number */, line/*: number */, column/*: number */) {
  Error.call(this, message)
  this.name = 'SyntaxError'
  this.message = message
  this.expected = expected
  this.found = found
  this.offset = offset
  this.line = line
  this.column = column
}
SyntaxError.prototype = Object.create(Error.prototype)
exports.SyntaxError = SyntaxError


/***/ }),
/* 11 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// @flow

var formats = __webpack_require__(6)
var lookupClosestLocale = __webpack_require__(7)
var plurals = __webpack_require__(8)

/*::
import type {
  AST,
  SubMessages
} from '../format-message-parse'
type Locale = string
type Locales = Locale | Locale[]
type Placeholder = any[] // https://github.com/facebook/flow/issues/4050
export type Type = (Placeholder, Locales) => (any, ?Object) => any
export type Types = { [string]: Type }
*/

exports = module.exports = function interpret (
  ast/*: AST */,
  locale/*:: ?: Locales */,
  types/*:: ?: Types */
)/*: (args?: Object) => string */ {
  return interpretAST(ast, null, locale || 'en', types || {}, true)
}

exports.toParts = function toParts (
  ast/*: AST */,
  locale/*:: ?: Locales */,
  types/*:: ?: Types */
)/*: (args?: Object) => any[] */ {
  return interpretAST(ast, null, locale || 'en', types || {}, false)
}

function interpretAST (
  elements/*: any[] */,
  parent/*: ?Placeholder */,
  locale/*: Locales */,
  types/*: Types */,
  join/*: boolean */
)/*: Function */ {
  var parts = elements.map(function (element) {
    return interpretElement(element, parent, locale, types, join)
  })

  if (!join) {
    return function format (args) {
      return parts.reduce(function (parts, part) {
        return parts.concat(part(args))
      }, [])
    }
  }

  if (parts.length === 1) return parts[0]
  return function format (args) {
    var message = ''
    for (var e = 0; e < parts.length; ++e) {
      message += parts[e](args)
    }
    return message
  }
}

function interpretElement (
  element/*: Placeholder */,
  parent/*: ?Placeholder */,
  locale/*: Locales */,
  types/*: Types */,
  join/*: boolean */
)/*: Function */ {
  if (typeof element === 'string') {
    var value/*: string */ = element
    return function format () { return value }
  }

  var id = element[0]
  var type = element[1]

  if (parent && element[0] === '#') {
    id = parent[0]
    var offset = parent[2]
    var formatter = (types.number || defaults.number)([ id, 'number' ], locale)
    return function format (args) {
      return formatter(getArg(id, args) - offset, args)
    }
  }

  // pre-process children
  var children
  if (type === 'plural' || type === 'selectordinal') {
    children = {}
    Object.keys(element[3]).forEach(function (key) {
      children[key] = interpretAST(element[3][key], element, locale, types, join)
    })
    element = [ element[0], element[1], element[2], children ]
  } else if (element[2] && typeof element[2] === 'object') {
    children = {}
    Object.keys(element[2]).forEach(function (key) {
      children[key] = interpretAST(element[2][key], element, locale, types, join)
    })
    element = [ element[0], element[1], children ]
  }

  var getFrmt = type && (types[type] || defaults[type])
  if (getFrmt) {
    var frmt = getFrmt(element, locale)
    return function format (args) {
      return frmt(getArg(id, args), args)
    }
  }

  return join
    ? function format (args) { return String(getArg(id, args)) }
    : function format (args) { return getArg(id, args) }
}

function getArg (id/*: string */, args/*: ?Object */)/*: any */ {
  if (args && (id in args)) return args[id]
  var parts = id.split('.')
  var a = args
  for (var i = 0, ii = parts.length; a && i < ii; ++i) {
    a = a[parts[i]]
  }
  return a
}

function interpretNumber (element/*: Placeholder */, locales/*: Locales */) {
  var style = element[2]
  var options = formats.number[style] || formats.parseNumberPattern(style) || formats.number.default
  return new Intl.NumberFormat(locales, options).format
}

function interpretDuration (element/*: Placeholder */, locales/*: Locales */) {
  var style = element[2]
  var options = formats.duration[style] || formats.duration.default
  var fs = new Intl.NumberFormat(locales, options.seconds).format
  var fm = new Intl.NumberFormat(locales, options.minutes).format
  var fh = new Intl.NumberFormat(locales, options.hours).format
  var sep = /^fi$|^fi-|^da/.test(String(locales)) ? '.' : ':'

  return function (s, args) {
    s = +s
    if (!isFinite(s)) return fs(s)
    var h = ~~(s / 60 / 60) // ~~ acts much like Math.trunc
    var m = ~~(s / 60 % 60)
    var dur = (h ? (fh(Math.abs(h)) + sep) : '') +
      fm(Math.abs(m)) + sep + fs(Math.abs(s % 60))
    return s < 0 ? fh(-1).replace(fh(1), dur) : dur
  }
}

function interpretDateTime (element/*: Placeholder */, locales/*: Locales */) {
  var type = element[1]
  var style = element[2]
  var options = formats[type][style] || formats.parseDatePattern(style) || formats[type].default
  return new Intl.DateTimeFormat(locales, options).format
}

function interpretPlural (element/*: Placeholder */, locales/*: Locales */) {
  var type = element[1]
  var pluralType = type === 'selectordinal' ? 'ordinal' : 'cardinal'
  var offset = element[2]
  var children = element[3]
  var pluralRules
  if (Intl.PluralRules && Intl.PluralRules.supportedLocalesOf(locales).length > 0) {
    pluralRules = new Intl.PluralRules(locales, { type: pluralType })
  } else {
    var locale = lookupClosestLocale(locales, plurals)
    var select = (locale && plurals[locale][pluralType]) || returnOther
    pluralRules = { select: select }
  }

  return function (value, args) {
    var clause =
      children['=' + +value] ||
      children[pluralRules.select(value - offset)] ||
      children.other
    return clause(args)
  }
}

function returnOther (/*:: n:number */) { return 'other' }

function interpretSelect (element/*: Placeholder */, locales/*: Locales */) {
  var children = element[2]
  return function (value, args) {
    var clause = children[value] || children.other
    return clause(args)
  }
}

var defaults/*: Types */ = {
  number: interpretNumber,
  ordinal: interpretNumber, // TODO: support rbnf
  spellout: interpretNumber, // TODO: support rbnf
  duration: interpretDuration,
  date: interpretDateTime,
  time: interpretDateTime,
  plural: interpretPlural,
  selectordinal: interpretPlural,
  select: interpretSelect
}
exports.types = defaults


/***/ }),
/* 12 */
/***/ (function(module, exports) {

/**
 * @license     http://creativecommons.org/licenses/publicdomain Public Domain
 * @author      Koji Horaguchi <horaguchi@horaguchi.net>
 */
if (typeof window.Locale == 'undefined') {
  window.Locale = function (category, locale) {
    this._instance = true;
    this.LC_ALL = 'C';
    this.LC_COLLATE = 'C';
    this.LC_CTYPE = 'C';
    this.LC_MESSAGES = 'C';
    this.LC_MONETARY = 'C';
    this.LC_NUMERIC = 'C';
    this.LC_TIME = 'C';
    this.setlocale(category, locale);
  };
}

Locale.VERSION = '0.0.3';
Locale.EXPORT = ['LC_ALL', 'LC_COLLATE', 'LC_CTYPE', 'LC_MESSAGES', 'LC_MONETARY', 'LC_NUMERIC', 'LC_TIME'];
Locale.EXPORT_OK = ['setlocale'];
Locale.EXPORT_TAGS = {
  ':common': Locale.EXPORT,
  ':all': Locale.EXPORT.concat(Locale.EXPORT_OK)
};
Locale.prototype.TranslationLists = {};
Locale.LC_ALL = 'LC_ALL';
Locale.LC_COLLATE = 'LC_COLLATE';
Locale.LC_CTYPE = 'LC_CTYPE';
Locale.LC_MESSAGES = 'LC_MESSAGES';
Locale.LC_MONETARY = 'LC_MONETARY';
Locale.LC_NUMERIC = 'LC_NUMERIC';
Locale.LC_TIME = 'LC_TIME';

Locale.setlocale = Locale.prototype.setlocale = function (category, locale) {
  return function () {
    if (locale === null || typeof locale == 'undefined') {
      return this[category];
    }

    if (locale == '') {
      locale = (window.navigator.browserLanguage || window.navigator.language || 'C').replace(/^(.{2}).?(.{2})?.*$/, function (match, lang, terr) {
        return lang.toLowerCase() + (terr ? '_' + terr.toUpperCase() : '');
      });
    }

    switch (category) {
      case Locale.LC_ALL:
        this.LC_ALL = locale;
        this.LC_COLLATE = locale;
        this.LC_CTYPE = locale;
        this.LC_MESSAGES = locale;
        this.LC_MONETARY = locale;
        this.LC_NUMERIC = locale;
        this.LC_TIME = locale;
        break;

      case Locale.LC_COLLATE:
      case Locale.LC_CTYPE:
      case Locale.LC_MESSAGES:
      case Locale.LC_MONETARY:
      case Locale.LC_NUMERIC:
      case Locale.LC_TIME:
        this[category] = locale;
        break;

      default:
        return false;
    }

    return locale;
  }.call(this._instance ? this : arguments.callee);
};

Locale.setlocale.LC_ALL = 'C';
Locale.setlocale.LC_COLLATE = 'C';
Locale.setlocale.LC_CTYPE = 'C';
Locale.setlocale.LC_MESSAGES = 'C';
Locale.setlocale.LC_MONETARY = 'C';
Locale.setlocale.LC_NUMERIC = 'C';
Locale.setlocale.LC_TIME = 'C';
/**
 * get translation data from generic locale object (partial clone of Zend Frameworks locale data)
 * 
 * @param   type (Date, Symbol, ...)
 * @param   key  the key
 * @return  translation data
 */

Locale.getTranslationData = function (type, key) {
  var value = '';

  if (Tine.__translationData.TranslationLists[type] && Tine.__translationData.TranslationLists[type][key]) {
    value = Tine.__translationData.TranslationLists[type][key];
  }

  return value;
};
/**
 * get translation list from generic locale object (partial clone of Zend Frameworks locale data)
 * 
 * @param {String} type
 * @return {Object}
 */


Locale.getTranslationList = function (type) {
  return Tine.__translationData.TranslationLists[type];
};

/***/ }),
/* 13 */
/***/ (function(module, exports) {

/**
 * @license     http://creativecommons.org/licenses/publicdomain Public Domain
 * @author      Koji Horaguchi <horaguchi@horaguchi.net>
 */

/* We don't support dynamic inclusion of po files any longer!
if (typeof ActiveXObject != 'undefined' && typeof XMLHttpRequest == 'undefined') {
  XMLHttpRequest = function () { try { return new ActiveXObject("Msxml2.XMLHTTP");
  } catch (e) { return new ActiveXObject("Microsoft.XMLHTTP"); } };
}
*/

/**
 * @constuctor
 */
Locale.Gettext = function (locale) {
  this.locale = typeof locale == 'string' ? new Locale(Locale.LC_ALL, locale) : locale || Locale;
  this.domain = 'messages';
  this.category = Locale.LC_MESSAGES;
  this.suffix = 'po';
  this.dir = '.';
};

Locale.Gettext.prototype.bindtextdomain = function (domain, dir) {
  this.dir = dir;
  this.domain = domain;
};

Locale.Gettext.prototype.textdomain = function (domain) {
  this.domain = domain;
};

Locale.Gettext.prototype.getmsg = function (domain, category, reload) {
  var key = this._getkey(category, domain);

  return Locale.Gettext.prototype._msgs[key];
};

Locale.Gettext.prototype._msgs = {};

Locale.Gettext.prototype._getkey = function (category, domain) {
  return this.dir + '/' + category + '/' + domain; // expect category is str
};

Locale.Gettext.prototype.dcgettext = function (domain, msgid, category) {
  var msg = this.getmsg(domain, category);
  return msg ? msg.get(msgid) || msgid : msgid;
};

Locale.Gettext.prototype.dcngettext = function (domain, msgid, msgid_plural, n, category) {
  var msg = this.getmsg(domain, category);

  if (msg) {
    return (msg.get(msgid, msgid_plural) || [msgid, msgid_plural])[msg.plural(n)] || (n > 1 ? msgid_plural : msgid);
  } else {
    // fallback if cataloge is not available
    return n > 1 ? msgid_plural : msgid;
  }
};

Locale.Gettext.prototype.dgettext = function (domain, msgid) {
  return this.dcgettext(domain, msgid, this.category);
};

Locale.Gettext.prototype.dngettext = function (domain, msgid, msgid_plural, n) {
  return this.dcngettext(domain, msgid, msgid_plural, n, this.category);
};

Locale.Gettext.prototype.gettext = Locale.Gettext.prototype._ = Locale.Gettext.prototype._hidden = function (msgid) {
  return this.dcgettext(this.domain, msgid, this.category);
};

Locale.Gettext.prototype.ngettext = Locale.Gettext.prototype.n_ = Locale.Gettext.prototype.n_hidden = function (msgid, msgid_plural, n) {
  return this.dcngettext(this.domain, msgid, msgid_plural, n, this.category);
};

Locale.Gettext.prototype.gettext_noop = Locale.Gettext.prototype.N_ = function (msgid) {
  return msgid;
}; // extend object


(function () {
  for (var i in Locale.Gettext.prototype) {
    Locale.Gettext[i] = function (func) {
      return function () {
        return func.apply(Locale.Gettext, arguments);
      };
    }(Locale.Gettext.prototype[i]);
  }
})(); // Locale.Gettext.PO


if (typeof Locale.Gettext.PO == 'undefined') {
  Locale.Gettext.PO = function (object) {
    if (typeof object == 'string' || object instanceof String) {
      this.msg = Locale.Gettext.PO.po2object(object);
    } else if (object instanceof Object) {
      this.msg = object;
    } else {
      this.msg = {};
    }
  };
}

Locale.Gettext.PO.VERSION = '0.0.4';
Locale.Gettext.PO.EXPORT_OK = ['po2object', 'po2json'];

Locale.Gettext.PO.po2object = function (po) {
  return eval(Locale.Gettext.PO.po2json(po));
};

Locale.Gettext.PO.po2json = function (po) {
  var first = true,
      plural = false;
  return '({\n' + po.replace(/\r?\n/g, '\n').replace(/#.*\n/g, '').replace(/"(\n+)"/g, '').replace(/msgid "(.*?)"\nmsgid_plural "(.*?)"/g, 'msgid "$1, $2"').replace(/msg(\S+) /g, function (match, op) {
    switch (op) {
      case 'id':
        return first ? (first = false, '') : plural ? (plural = false, ']\n, ') : ', ';

      case 'str':
        return ': ';

      case 'str[0]':
        return plural = true, ': [\n  ';

      default:
        return ' ,';
    }
  }) + (plural ? ']\n})' : '\n})');
};

Locale.Gettext.PO.prototype.get = function (msgid, msgid_plural) {
  // for msgid_plural == ""
  return typeof msgid_plural != 'undefined' ? this.msg[msgid + ', ' + msgid_plural] : this.msg[msgid];
};

Locale.Gettext.PO.prototype.plural = function (n) {
  var nplurals, plural;
  eval((this.msg[''] + 'Plural-Forms: nplurals=2; plural=n != 1\n').match(/Plural-Forms:(.*)\n/)[1]);
  return plural === true ? 1 : plural === false ? 0 : plural;
}; // create dummy domain


Locale.Gettext.prototype._msgs.emptyDomain = new Locale.Gettext.PO({});

/***/ }),
/* 14 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */
// message bus
var postal = __webpack_require__(18);

__webpack_require__(46);

__webpack_require__(697);

__webpack_require__(699);

__webpack_require__(48);

__webpack_require__(47); // custom ext build


__webpack_require__(701); // include traditional stuff as defined in jsb2


__webpack_require__(1111);

__webpack_require__(1627);

__webpack_require__(1630);

__webpack_require__(1631);

__webpack_require__(1632); // UI style >= 2019


__webpack_require__(1633);

__webpack_require__(1634);

__webpack_require__(1636); // other libs


var lodash = __webpack_require__(1);

var director = __webpack_require__(1649);

__webpack_require__(1650);

__webpack_require__(1651);

__webpack_require__(1653);

module.exports = {
  director: director,
  postal: postal,
  lodash: lodash,
  _: lodash
};

/***/ }),
/* 15 */,
/* 16 */
/***/ (function(module, exports) {

/*
	MIT License http://www.opensource.org/licenses/mit-license.php
	Author Tobias Koppers @sokra
*/
// css base code, injected by the css-loader
module.exports = function(useSourceMap) {
	var list = [];

	// return the list of modules as css string
	list.toString = function toString() {
		return this.map(function (item) {
			var content = cssWithMappingToString(item, useSourceMap);
			if(item[2]) {
				return "@media " + item[2] + "{" + content + "}";
			} else {
				return content;
			}
		}).join("");
	};

	// import a list of modules into the list
	list.i = function(modules, mediaQuery) {
		if(typeof modules === "string")
			modules = [[null, modules, ""]];
		var alreadyImportedModules = {};
		for(var i = 0; i < this.length; i++) {
			var id = this[i][0];
			if(typeof id === "number")
				alreadyImportedModules[id] = true;
		}
		for(i = 0; i < modules.length; i++) {
			var item = modules[i];
			// skip already imported module
			// this implementation is not 100% perfect for weird media query combinations
			//  when a module is imported multiple times with different media queries.
			//  I hope this will never occur (Hey this way we have smaller bundles)
			if(typeof item[0] !== "number" || !alreadyImportedModules[item[0]]) {
				if(mediaQuery && !item[2]) {
					item[2] = mediaQuery;
				} else if(mediaQuery) {
					item[2] = "(" + item[2] + ") and (" + mediaQuery + ")";
				}
				list.push(item);
			}
		}
	};
	return list;
};

function cssWithMappingToString(item, useSourceMap) {
	var content = item[1] || '';
	var cssMapping = item[3];
	if (!cssMapping) {
		return content;
	}

	if (useSourceMap && typeof btoa === 'function') {
		var sourceMapping = toComment(cssMapping);
		var sourceURLs = cssMapping.sources.map(function (source) {
			return '/*# sourceURL=' + cssMapping.sourceRoot + source + ' */'
		});

		return [content].concat(sourceURLs).concat([sourceMapping]).join('\n');
	}

	return [content].join('\n');
}

// Adapted from convert-source-map (MIT)
function toComment(sourceMap) {
	// eslint-disable-next-line no-undef
	var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));
	var data = 'sourceMappingURL=data:application/json;charset=utf-8;base64,' + base64;

	return '/*# ' + data + ' */';
}


/***/ }),
/* 17 */
/***/ (function(module, exports, __webpack_require__) {

/*
	MIT License http://www.opensource.org/licenses/mit-license.php
	Author Tobias Koppers @sokra
*/

var stylesInDom = {};

var	memoize = function (fn) {
	var memo;

	return function () {
		if (typeof memo === "undefined") memo = fn.apply(this, arguments);
		return memo;
	};
};

var isOldIE = memoize(function () {
	// Test for IE <= 9 as proposed by Browserhacks
	// @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805
	// Tests for existence of standard globals is to allow style-loader
	// to operate correctly into non-standard environments
	// @see https://github.com/webpack-contrib/style-loader/issues/177
	return window && document && document.all && !window.atob;
});

var getElement = (function (fn) {
	var memo = {};

	return function(selector) {
		if (typeof memo[selector] === "undefined") {
			var styleTarget = fn.call(this, selector);
			// Special case to return head of iframe instead of iframe itself
			if (styleTarget instanceof window.HTMLIFrameElement) {
				try {
					// This will throw an exception if access to iframe is blocked
					// due to cross-origin restrictions
					styleTarget = styleTarget.contentDocument.head;
				} catch(e) {
					styleTarget = null;
				}
			}
			memo[selector] = styleTarget;
		}
		return memo[selector]
	};
})(function (target) {
	return document.querySelector(target)
});

var singleton = null;
var	singletonCounter = 0;
var	stylesInsertedAtTop = [];

var	fixUrls = __webpack_require__(40);

module.exports = function(list, options) {
	if (typeof DEBUG !== "undefined" && DEBUG) {
		if (typeof document !== "object") throw new Error("The style-loader cannot be used in a non-browser environment");
	}

	options = options || {};

	options.attrs = typeof options.attrs === "object" ? options.attrs : {};

	// Force single-tag solution on IE6-9, which has a hard limit on the # of <style>
	// tags it will allow on a page
	if (!options.singleton && typeof options.singleton !== "boolean") options.singleton = isOldIE();

	// By default, add <style> tags to the <head> element
	if (!options.insertInto) options.insertInto = "head";

	// By default, add <style> tags to the bottom of the target
	if (!options.insertAt) options.insertAt = "bottom";

	var styles = listToStyles(list, options);

	addStylesToDom(styles, options);

	return function update (newList) {
		var mayRemove = [];

		for (var i = 0; i < styles.length; i++) {
			var item = styles[i];
			var domStyle = stylesInDom[item.id];

			domStyle.refs--;
			mayRemove.push(domStyle);
		}

		if(newList) {
			var newStyles = listToStyles(newList, options);
			addStylesToDom(newStyles, options);
		}

		for (var i = 0; i < mayRemove.length; i++) {
			var domStyle = mayRemove[i];

			if(domStyle.refs === 0) {
				for (var j = 0; j < domStyle.parts.length; j++) domStyle.parts[j]();

				delete stylesInDom[domStyle.id];
			}
		}
	};
};

function addStylesToDom (styles, options) {
	for (var i = 0; i < styles.length; i++) {
		var item = styles[i];
		var domStyle = stylesInDom[item.id];

		if(domStyle) {
			domStyle.refs++;

			for(var j = 0; j < domStyle.parts.length; j++) {
				domStyle.parts[j](item.parts[j]);
			}

			for(; j < item.parts.length; j++) {
				domStyle.parts.push(addStyle(item.parts[j], options));
			}
		} else {
			var parts = [];

			for(var j = 0; j < item.parts.length; j++) {
				parts.push(addStyle(item.parts[j], options));
			}

			stylesInDom[item.id] = {id: item.id, refs: 1, parts: parts};
		}
	}
}

function listToStyles (list, options) {
	var styles = [];
	var newStyles = {};

	for (var i = 0; i < list.length; i++) {
		var item = list[i];
		var id = options.base ? item[0] + options.base : item[0];
		var css = item[1];
		var media = item[2];
		var sourceMap = item[3];
		var part = {css: css, media: media, sourceMap: sourceMap};

		if(!newStyles[id]) styles.push(newStyles[id] = {id: id, parts: [part]});
		else newStyles[id].parts.push(part);
	}

	return styles;
}

function insertStyleElement (options, style) {
	var target = getElement(options.insertInto)

	if (!target) {
		throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");
	}

	var lastStyleElementInsertedAtTop = stylesInsertedAtTop[stylesInsertedAtTop.length - 1];

	if (options.insertAt === "top") {
		if (!lastStyleElementInsertedAtTop) {
			target.insertBefore(style, target.firstChild);
		} else if (lastStyleElementInsertedAtTop.nextSibling) {
			target.insertBefore(style, lastStyleElementInsertedAtTop.nextSibling);
		} else {
			target.appendChild(style);
		}
		stylesInsertedAtTop.push(style);
	} else if (options.insertAt === "bottom") {
		target.appendChild(style);
	} else if (typeof options.insertAt === "object" && options.insertAt.before) {
		var nextSibling = getElement(options.insertInto + " " + options.insertAt.before);
		target.insertBefore(style, nextSibling);
	} else {
		throw new Error("[Style Loader]\n\n Invalid value for parameter 'insertAt' ('options.insertAt') found.\n Must be 'top', 'bottom', or Object.\n (https://github.com/webpack-contrib/style-loader#insertat)\n");
	}
}

function removeStyleElement (style) {
	if (style.parentNode === null) return false;
	style.parentNode.removeChild(style);

	var idx = stylesInsertedAtTop.indexOf(style);
	if(idx >= 0) {
		stylesInsertedAtTop.splice(idx, 1);
	}
}

function createStyleElement (options) {
	var style = document.createElement("style");

	options.attrs.type = "text/css";

	addAttrs(style, options.attrs);
	insertStyleElement(options, style);

	return style;
}

function createLinkElement (options) {
	var link = document.createElement("link");

	options.attrs.type = "text/css";
	options.attrs.rel = "stylesheet";

	addAttrs(link, options.attrs);
	insertStyleElement(options, link);

	return link;
}

function addAttrs (el, attrs) {
	Object.keys(attrs).forEach(function (key) {
		el.setAttribute(key, attrs[key]);
	});
}

function addStyle (obj, options) {
	var style, update, remove, result;

	// If a transform function was defined, run it on the css
	if (options.transform && obj.css) {
	    result = options.transform(obj.css);

	    if (result) {
	    	// If transform returns a value, use that instead of the original css.
	    	// This allows running runtime transformations on the css.
	    	obj.css = result;
	    } else {
	    	// If the transform function returns a falsy value, don't add this css.
	    	// This allows conditional loading of css
	    	return function() {
	    		// noop
	    	};
	    }
	}

	if (options.singleton) {
		var styleIndex = singletonCounter++;

		style = singleton || (singleton = createStyleElement(options));

		update = applyToSingletonTag.bind(null, style, styleIndex, false);
		remove = applyToSingletonTag.bind(null, style, styleIndex, true);

	} else if (
		obj.sourceMap &&
		typeof URL === "function" &&
		typeof URL.createObjectURL === "function" &&
		typeof URL.revokeObjectURL === "function" &&
		typeof Blob === "function" &&
		typeof btoa === "function"
	) {
		style = createLinkElement(options);
		update = updateLink.bind(null, style, options);
		remove = function () {
			removeStyleElement(style);

			if(style.href) URL.revokeObjectURL(style.href);
		};
	} else {
		style = createStyleElement(options);
		update = applyToTag.bind(null, style);
		remove = function () {
			removeStyleElement(style);
		};
	}

	update(obj);

	return function updateStyle (newObj) {
		if (newObj) {
			if (
				newObj.css === obj.css &&
				newObj.media === obj.media &&
				newObj.sourceMap === obj.sourceMap
			) {
				return;
			}

			update(obj = newObj);
		} else {
			remove();
		}
	};
}

var replaceText = (function () {
	var textStore = [];

	return function (index, replacement) {
		textStore[index] = replacement;

		return textStore.filter(Boolean).join('\n');
	};
})();

function applyToSingletonTag (style, index, remove, obj) {
	var css = remove ? "" : obj.css;

	if (style.styleSheet) {
		style.styleSheet.cssText = replaceText(index, css);
	} else {
		var cssNode = document.createTextNode(css);
		var childNodes = style.childNodes;

		if (childNodes[index]) style.removeChild(childNodes[index]);

		if (childNodes.length) {
			style.insertBefore(cssNode, childNodes[index]);
		} else {
			style.appendChild(cssNode);
		}
	}
}

function applyToTag (style, obj) {
	var css = obj.css;
	var media = obj.media;

	if(media) {
		style.setAttribute("media", media)
	}

	if(style.styleSheet) {
		style.styleSheet.cssText = css;
	} else {
		while(style.firstChild) {
			style.removeChild(style.firstChild);
		}

		style.appendChild(document.createTextNode(css));
	}
}

function updateLink (link, options, obj) {
	var css = obj.css;
	var sourceMap = obj.sourceMap;

	/*
		If convertToAbsoluteUrls isn't defined, but sourcemaps are enabled
		and there is no publicPath defined then lets turn convertToAbsoluteUrls
		on by default.  Otherwise default to the convertToAbsoluteUrls option
		directly
	*/
	var autoFixUrls = options.convertToAbsoluteUrls === undefined && sourceMap;

	if (options.convertToAbsoluteUrls || autoFixUrls) {
		css = fixUrls(css);
	}

	if (sourceMap) {
		// http://stackoverflow.com/a/26603875
		css += "\n/*# sourceMappingURL=data:application/json;base64," + btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))) + " */";
	}

	var blob = new Blob([css], { type: "text/css" });

	var oldSrc = link.href;

	link.href = URL.createObjectURL(blob);

	if(oldSrc) URL.revokeObjectURL(oldSrc);
}


/***/ }),
/* 18 */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/**
 * postal - Pub/Sub library providing wildcard subscriptions, complex message handling, etc.  Works server and client-side.
 * Author: Jim Cowart (http://ifandelse.com)
 * Version: v2.0.5
 * Url: http://github.com/postaljs/postal.js
 * License(s): MIT
 */

( function( root, factory ) {
	
	if ( true ) {
		// AMD. Register as an anonymous module.
		!(__WEBPACK_AMD_DEFINE_ARRAY__ = [ __webpack_require__(1) ], __WEBPACK_AMD_DEFINE_RESULT__ = (function( _ ) {
			return factory( _, root );
		}).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
	
	} else {}
}( this, function( _, global, undefined ) {
	var prevPostal = global && global.postal;
	var prevLodash = global && global._;
	if ( prevLodash && prevLodash !== _ ) {
		_ = _.noConflict();
	}
	var _defaultConfig = {
		DEFAULT_CHANNEL: "/",
		SYSTEM_CHANNEL: "postal",
		enableSystemMessages: true,
		cacheKeyDelimiter: "|",
		autoCompactResolver: false
	};
	var postal = {
		configuration: _.extend( {}, _defaultConfig )
	};
	var _config = postal.configuration;

	

var ChannelDefinition = function( channelName, bus ) {
	this.bus = bus;
	this.channel = channelName || _config.DEFAULT_CHANNEL;
};

ChannelDefinition.prototype.subscribe = function() {
	return this.bus.subscribe( {
		channel: this.channel,
		topic: ( arguments.length === 1 ? arguments[ 0 ].topic : arguments[ 0 ] ),
		callback: ( arguments.length === 1 ? arguments[ 0 ].callback : arguments[ 1 ] )
	} );
};

/*
    publish( envelope [, callback ] );
    publish( topic, data [, callback ] );
*/
ChannelDefinition.prototype.publish = function() {
	var envelope = {};
	var callback;
	if ( typeof arguments[ 0 ] === "string" ) {
		envelope.topic = arguments[ 0 ];
		envelope.data = arguments[ 1 ];
		callback = arguments[ 2 ];
	} else {
		envelope = arguments[ 0 ];
		callback = arguments[ 1 ];
	}
	if ( typeof envelope !== "object" ) {
		throw new Error( "The first argument to ChannelDefinition.publish should be either an envelope object or a string topic." );
	}
	envelope.headers = _.extend( envelope.headers || { resolverNoCache: _config.resolverNoCache } );
	envelope.channel = this.channel;
	this.bus.publish( envelope, callback );
};

	
var SubscriptionDefinition = function( channel, topic, callback ) {
	if ( arguments.length !== 3 ) {
		throw new Error( "You must provide a channel, topic and callback when creating a SubscriptionDefinition instance." );
	}
	if ( topic.length === 0 ) {
		throw new Error( "Topics cannot be empty" );
	}
	this.channel = channel;
	this.topic = topic;
	this.callback = callback;
	this.pipeline = [];
	this.cacheKeys = [];
	this._context = undefined;
};

var ConsecutiveDistinctPredicate = function() {
	var previous;
	return function( data ) {
		var eq = false;
		if ( typeof data === "string" ) {
			eq = data === previous;
			previous = data;
		} else {
			eq = _.isEqual( data, previous );
			previous = _.extend( {}, data );
		}
		return !eq;
	};
};

var DistinctPredicate = function DistinctPredicateFactory() {
	var previous = [];
	return function DistinctPredicate( data ) {
		var isDistinct = !_.some( previous, function( p ) {
			return _.isEqual( data, p );
		} );
		if ( isDistinct ) {
			previous.push( data );
		}
		return isDistinct;
	};
};

SubscriptionDefinition.prototype = {

	"catch": function( errorHandler ) {
		var original = this.callback;
		var safeCallback = function() {
			try {
				original.apply( this, arguments );
			} catch ( err ) {
				errorHandler( err, arguments[ 0 ] );
			}
		};
		this.callback = safeCallback;
		return this;
	},

	defer: function defer() {
		return this.delay( 0 );
	},

	disposeAfter: function disposeAfter( maxCalls ) {
		if ( typeof maxCalls !== "number" || maxCalls <= 0 ) {
			throw new Error( "The value provided to disposeAfter (maxCalls) must be a number greater than zero." );
		}
		var dispose = _.after( maxCalls, this.unsubscribe.bind( this ) );
		this.pipeline.push( function( data, env, next ) {
			next( data, env );
			dispose();
		} );
		return this;
	},

	distinct: function distinct() {
		return this.constraint( new DistinctPredicate() );
	},

	distinctUntilChanged: function distinctUntilChanged() {
		return this.constraint( new ConsecutiveDistinctPredicate() );
	},

	invokeSubscriber: function invokeSubscriber( data, env ) {
		if ( !this.inactive ) {
			var self = this;
			var pipeline = self.pipeline;
			var len = pipeline.length;
			var context = self._context;
			var idx = -1;
			var invoked = false;
			if ( !len ) {
				self.callback.call( context, data, env );
				invoked = true;
			} else {
				pipeline = pipeline.concat( [ self.callback ] );
				var step = function step( d, e ) {
					idx += 1;
					if ( idx < len ) {
						pipeline[ idx ].call( context, d, e, step );
					} else {
						self.callback.call( context, d, e );
						invoked = true;
					}
				};
				step( data, env, 0 );
			}
			return invoked;
		}
	},

	logError: function logError() {
		
		if ( console ) {
			var report;
			if ( console.warn ) {
				report = console.warn;
			} else {
				report = console.log;
			}
			this.catch( report );
		}
		return this;
	},

	once: function once() {
		return this.disposeAfter( 1 );
	},

	subscribe: function subscribe( callback ) {
		this.callback = callback;
		return this;
	},

	unsubscribe: function unsubscribe() {
		
		if ( !this.inactive ) {
			postal.unsubscribe( this );
		}
	},

	constraint: function constraint( predicate ) {
		if ( typeof predicate !== "function" ) {
			throw new Error( "Predicate constraint must be a function" );
		}
		this.pipeline.push( function( data, env, next ) {
			if ( predicate.call( this, data, env ) ) {
				next( data, env );
			}
		} );
		return this;
	},

	constraints: function constraints( predicates ) {
		var self = this;
		
		_.each( predicates, function( predicate ) {
			self.constraint( predicate );
		} );
		return self;
	},

	context: function contextSetter( context ) {
		this._context = context;
		return this;
	},

	debounce: function debounce( milliseconds, immediate ) {
		if ( typeof milliseconds !== "number" ) {
			throw new Error( "Milliseconds must be a number" );
		}

		var options = {};

		if ( !!immediate === true ) { 
			options.leading = true;
			options.trailing = false;
		}

		this.pipeline.push(
			_.debounce( function( data, env, next ) {
				next( data, env );
			},
				milliseconds,
				options
			)
		);
		return this;
	},

	delay: function delay( milliseconds ) {
		if ( typeof milliseconds !== "number" ) {
			throw new Error( "Milliseconds must be a number" );
		}
		var self = this;
		self.pipeline.push( function( data, env, next ) {
			setTimeout( function() {
				next( data, env );
			}, milliseconds );
		} );
		return this;
	},

	throttle: function throttle( milliseconds ) {
		if ( typeof milliseconds !== "number" ) {
			throw new Error( "Milliseconds must be a number" );
		}
		var fn = function( data, env, next ) {
			next( data, env );
		};
		this.pipeline.push( _.throttle( fn, milliseconds ) );
		return this;
	}
};

	


var bindingsResolver = _config.resolver = {
	cache: {},
	regex: {},
	enableCache: true,

	compare: function compare( binding, topic, headerOptions ) {
		var pattern;
		var rgx;
		var prevSegment;
		var cacheKey = topic + _config.cacheKeyDelimiter + binding;
		var result = ( this.cache[ cacheKey ] );
		var opt = headerOptions || {};
		var saveToCache = this.enableCache && !opt.resolverNoCache;
		// result is cached?
		if ( result === true ) {
			return result;
		}
		// plain string matching?
		if ( binding.indexOf( "#" ) === -1 && binding.indexOf( "*" ) === -1 ) {
			result = ( topic === binding );
			if ( saveToCache ) {
				this.cache[ cacheKey ] = result;
			}
			return result;
		}
		// ah, regex matching, then
		if ( !( rgx = this.regex[ binding ] ) ) {
			pattern = "^" + _.map( binding.split( "." ), function mapTopicBinding( segment ) {
					var res = "";
					if ( !!prevSegment ) {
						res = prevSegment !== "#" ? "\\.\\b" : "\\b";
					}
					if ( segment === "#" ) {
						res += "[\\s\\S]*";
					} else if ( segment === "*" ) {
						res += "[^.]+";
					} else {
						res += segment;
					}
					prevSegment = segment;
					return res;
				} ).join( "" ) + "$";
			rgx = this.regex[ binding ] = new RegExp( pattern );
		}
		result = rgx.test( topic );
		if ( saveToCache ) {
			this.cache[ cacheKey ] = result;
		}
		return result;
	},

	reset: function reset() {
		this.cache = {};
		this.regex = {};
	},

	purge: function( options ) {
		var self = this;
		var keyDelimiter = _config.cacheKeyDelimiter;
		var matchPredicate = function( val, key ) {
			var split = key.split( keyDelimiter );
			var topic = split[ 0 ];
			var binding = split[ 1 ];
			if ( ( typeof options.topic === "undefined" || options.topic === topic ) &&
					( typeof options.binding === "undefined" || options.binding === binding ) ) {
				delete self.cache[ key ];
			}
		};

		var compactPredicate = function( val, key ) {
			var split = key.split( keyDelimiter );
			if ( postal.getSubscribersFor( { topic: split[ 0 ] } ).length === 0 ) {
				delete self.cache[ key ];
			}
		};

		if ( typeof options === "undefined" ) {
			this.reset();
		} else {
			var handler = options.compact === true ? compactPredicate : matchPredicate;
			_.each( this.cache, handler );
		}
	}
};

	


var pubInProgress = 0;
var unSubQueue = [];
var autoCompactIndex = 0;

function clearUnSubQueue() {
	while ( unSubQueue.length ) {
		postal.unsubscribe( unSubQueue.shift() );
	}
}

function getCachePurger( subDef, key, cache ) {
	return function( sub, i, list ) {
		if ( sub === subDef ) {
			list.splice( i, 1 );
		}
		if ( list.length === 0 ) {
			delete cache[ key ];
		}
	};
}

function getCacher( topic, pubCache, cacheKey, done, envelope ) {
	var headers = envelope && envelope.headers || {};
	return function( subDef ) {
		var cache;
		if ( _config.resolver.compare( subDef.topic, topic, headers ) ) {
			if ( !headers.resolverNoCache ) {
				cache = pubCache[ cacheKey ] = ( pubCache[ cacheKey ] || [] );
				cache.push( subDef );
				subDef.cacheKeys.push( cacheKey );
			}
			if ( done ) {
				done( subDef );
			}
		}
	};
}

function getSystemMessage( kind, subDef ) {
	return {
		channel: _config.SYSTEM_CHANNEL,
		topic: "subscription." + kind,
		data: {
			event: "subscription." + kind,
			channel: subDef.channel,
			topic: subDef.topic
		}
	};
}

var sysCreatedMessage = getSystemMessage.bind( undefined, "created" );
var sysRemovedMessage = getSystemMessage.bind( undefined, "removed" );

function getPredicate( options, resolver ) {
	if ( typeof options === "function" ) {
		return options;
	} else if ( !options ) {
		return function() {
			return true;
		};
	} else {
		return function( sub ) {
			var compared = 0;
			var matched = 0;
			_.each( options, function( val, prop ) {
				compared += 1;
				if (
				// We use the bindings resolver to compare the options.topic to subDef.topic
				( prop === "topic" && resolver.compare( sub.topic, options.topic, { resolverNoCache: true } ) ) ||
						( prop === "context" && options.context === sub._context ) ||
						// Any other potential prop/value matching outside topic & context...
						( sub[ prop ] === options[ prop ] ) ) {
					matched += 1;
				}
			} );
			return compared === matched;
		};
	}
}

_.extend( postal, {
	cache: {},
	subscriptions: {},
	wireTaps: [],

	ChannelDefinition: ChannelDefinition,
	SubscriptionDefinition: SubscriptionDefinition,

	channel: function channel( channelName ) {
		return new ChannelDefinition( channelName, this );
	},

	addWireTap: function addWireTap( callback ) {
		var self = this;
		self.wireTaps.push( callback );
		return function() {
			var idx = self.wireTaps.indexOf( callback );
			if ( idx !== -1 ) {
				self.wireTaps.splice( idx, 1 );
			}
		};
	},

	noConflict: function noConflict() {
		
		if ( typeof window === "undefined" || ( typeof window !== "undefined" && "function" === "function" && __webpack_require__(45) ) ) {
			throw new Error( "noConflict can only be used in browser clients which aren't using AMD modules" );
		}
		global.postal = prevPostal;
		return this;
	},

	getSubscribersFor: function getSubscribersFor( options ) {
		var result = [];
		var self = this;
		_.each( self.subscriptions, function( channel ) {
			_.each( channel, function( subList ) {
				result = result.concat( _.filter( subList, getPredicate( options, _config.resolver ) ) );
			} );
		} );
		return result;
	},

	publish: function publish( envelope, cb ) {
		++pubInProgress;
		var channel = envelope.channel = envelope.channel || _config.DEFAULT_CHANNEL;
		var topic = envelope.topic;
		envelope.timeStamp = new Date();
		if ( this.wireTaps.length ) {
			_.each( this.wireTaps, function( tap ) {
				tap( envelope.data, envelope, pubInProgress );
			} );
		}
		var cacheKey = channel + _config.cacheKeyDelimiter + topic;
		var cache = this.cache[ cacheKey ];
		var skipped = 0;
		var activated = 0;
		if ( !cache ) {
			var cacherFn = getCacher(
				topic,
				this.cache,
				cacheKey,
				function( candidate ) {
					if ( candidate.invokeSubscriber( envelope.data, envelope ) ) {
						activated++;
					} else {
						skipped++;
					}
				},
				envelope
			);
			_.each( this.subscriptions[ channel ], function( candidates ) {
				_.each( candidates, cacherFn );
			} );
		} else {
			_.each( cache, function( subDef ) {
				if ( subDef.invokeSubscriber( envelope.data, envelope ) ) {
					activated++;
				} else {
					skipped++;
				}
			} );
		}
		if ( --pubInProgress === 0 ) {
			clearUnSubQueue();
		}
		if ( cb ) {
			cb( {
				activated: activated,
				skipped: skipped
			} );
		}
	},

	reset: function reset() {
		this.unsubscribeFor();
		_config.resolver.reset();
		this.subscriptions = {};
		this.cache = {};
	},

	subscribe: function subscribe( options ) {
		var subscriptions = this.subscriptions;
		var subDef = new SubscriptionDefinition( options.channel || _config.DEFAULT_CHANNEL, options.topic, options.callback );
		var channel = subscriptions[ subDef.channel ];
		var channelLen = subDef.channel.length;
		var subs;
		if ( !channel ) {
			channel = subscriptions[ subDef.channel ] = {};
		}
		subs = subscriptions[ subDef.channel ][ subDef.topic ];
		if ( !subs ) {
			subs = subscriptions[ subDef.channel ][ subDef.topic ] = [];
		}
		// First, add the SubscriptionDefinition to the channel list
		subs.push( subDef );
		// Next, add the SubscriptionDefinition to any relevant existing cache(s)
		var cache = this.cache;
		_.each( _.keys( cache ), function( cacheKey ) {
			if ( cacheKey.substr( 0, channelLen ) === subDef.channel ) {
				getCacher(
					cacheKey.split( _config.cacheKeyDelimiter )[1],
					cache,
					cacheKey )( subDef );
			}
		} );
		
		if ( _config.enableSystemMessages ) {
			this.publish( sysCreatedMessage( subDef ) );
		}
		return subDef;
	},

	unsubscribe: function unsubscribe() {
		var unSubLen = arguments.length;
		var unSubIdx = 0;
		var subDef;
		var channelSubs;
		var topicSubs;
		var idx;
		for ( ; unSubIdx < unSubLen; unSubIdx++ ) {
			subDef = arguments[ unSubIdx ];
			subDef.inactive = true;
			if ( pubInProgress ) {
				unSubQueue.push( subDef );
				return;
			}
			channelSubs = this.subscriptions[ subDef.channel ];
			topicSubs = channelSubs && channelSubs[ subDef.topic ];
			
			if ( topicSubs ) {
				var len = topicSubs.length;
				idx = 0;
				// remove SubscriptionDefinition from channel list
				while ( idx < len ) {
					
					if ( topicSubs[ idx ] === subDef ) {
						topicSubs.splice( idx, 1 );
						break;
					}
					idx += 1;
				}
				if ( topicSubs.length === 0 ) {
					delete channelSubs[ subDef.topic ];
					if ( !_.keys( channelSubs ).length ) {
						delete this.subscriptions[ subDef.channel ];
					}
				}
				// remove SubscriptionDefinition from postal cache
				if ( subDef.cacheKeys && subDef.cacheKeys.length ) {
					var key;
					while ( key = subDef.cacheKeys.pop() ) {
						_.each( this.cache[ key ], getCachePurger( subDef, key, this.cache ) );
					}
				}
				if ( typeof _config.resolver.purge === "function" ) {
					// check to see if relevant resolver cache entries can be purged
					var autoCompact = _config.autoCompactResolver === true ?
						0 : typeof _config.autoCompactResolver === "number" ?
							( _config.autoCompactResolver - 1 ) : false;
					if ( autoCompact >= 0 && autoCompactIndex === autoCompact ) {
						_config.resolver.purge( { compact: true } );
						autoCompactIndex = 0;
					} else if ( autoCompact >= 0 && autoCompactIndex < autoCompact ) {
						autoCompactIndex += 1;
					}
				}
			}
			if ( _config.enableSystemMessages ) {
				this.publish( sysRemovedMessage( subDef ) );
			}
		}
	},

	unsubscribeFor: function unsubscribeFor( options ) {
		var toDispose = [];
		
		if ( this.subscriptions ) {
			toDispose = this.getSubscribersFor( options );
			this.unsubscribe.apply( this, toDispose );
		}
	}
} );


	
	if ( global && Object.prototype.hasOwnProperty.call( global, "__postalReady__" ) && _.isArray( global.__postalReady__ ) ) {
		while ( global.__postalReady__.length ) {
			global.__postalReady__.shift().onReady( postal );
		}
	}
	

	return postal;
} ) );


/***/ }),
/* 19 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var util_waitFor_es6__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);
/*
 * Tine 2.0
 *
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO         allow to add user defined part to Tine.title
 */

/*global Ext, Tine, google, OpenLayers, Locale, */


var EventEmitter = __webpack_require__(24);
/** ------------------------- Ext.ux Initialisation ------------------------ **/


Ext.ux.Printer.BaseRenderer.prototype.stylesheetPath = 'Tinebase/js/ux/Printer/print.css';
/** ------------------------ Tine 2.0 Initialisation ----------------------- **/

/**
 * @class Tine
 */

Ext.namespace('Tine');
/**
 * version of Tine 2.0 javascript client version, gets set a build / release time <br>
 * <b>Supported Properties:</b>
 * <table>
 *   <tr><td><b>buildType</b></td><td> type of build</td></tr>
 *   <tr><td><b>buildDate</b></td><td> date of build</td></tr>
 *   <tr><td><b>buildRevision</b></td><td> revision of build</td></tr>
 *   <tr><td><b>codeName</b></td><td> codename of release</td></tr>
 *   <tr><td><b>packageString</b></td><td> packageString of release</td></tr>
 *   <tr><td><b>releaseTime</b></td><td> releaseTime of release</td></tr>
 * </table>
 * @type {Object}
 */

Tine.clientVersion = {};
Tine.clientVersion.buildType="DEBUG";
Tine.clientVersion.buildDate="2022-07-21 10:19:46";
Tine.clientVersion.buildRevision = '2021.11.9';
Tine.clientVersion.codeName = 'Lu';
Tine.clientVersion.packageString = '2021.11.9';
Tine.clientVersion.releaseTime = '2022-07-21 10:18:51';
Tine.__appLoader = __webpack_require__(26);
Tine.__onAllAppsLoaded = new Promise(resolve => {
  Tine.__onAllAppsLoadedResolve = resolve;
});
/**
 * returns promise that resolves when app code of given app is loaded
 *
 * @param appName
 * @return {*|Promise<never>}
 */

Tine.onAppLoaded = appName => {
  return _.get(Tine.__appLoader.appLoadedPromises, appName) || Promise.reject();
};
/**
 * returns promise that resolves when code of all user apps is loaded
 * @return {Promise<any>}
 */


Tine.onAllAppsLoaded = () => {
  return Tine.__onAllAppsLoaded;
};
/**
 * quiet logging in release mode
 */


Tine.log = Ext.ux.log;
Tine.log.setPrio(Tine.clientVersion.buildType === 'RELEASE' ? 0 : 7);
/**
 * in memory per window msg bus for sync events
 */

(() => {
  let ee = new EventEmitter();
  Tine.on = ee.on;
  Tine.emit = ee.emit;
})();

Ext.namespace('Tine.Tinebase');
/**
 * @class Tine.Tinebase.tineInit
 * @namespace Tine.Tinebase
 * @sigleton
 * static tine init functions
 */

Tine.Tinebase.tineInit = {
  /**
   * @cfg {String} getAllRegistryDataMethod
   */
  getAllRegistryDataMethod: 'Tinebase.getAllRegistryData',

  /**
   * @cfg {Boolean} stateful
   */
  stateful: true,

  /**
   * @cfg {String} jsonKeyCookieId
   */
  jsonKeyCookieId: 'TINE20JSONKEY',

  /**
   * @cfg {String} requestUrl
   */
  requestUrl: 'index.php',

  /**
   * prefix for localStorage keys
   * @type String
   */
  lsPrefix: Tine.Tinebase.common.getUrl('path') + 'Tine',
  onPreferenceChangeRegistered: false,
  initCustomJS: function initCustomJS() {
    _.each(_.get(window, 'Tine.customJS', []), function (initCustomJS) {
      initCustomJS();
    });
  },
  initWindow: function initWindow() {
    Ext.getBody().on('keydown', function (e) {
      if (e.ctrlKey && e.getKey() === e.A && !(e.getTarget('form') || e.getTarget('input') || e.getTarget('textarea'))) {
        // disable the native 'select all'
        e.preventDefault();
      } else if (e.getKey() === e.BACKSPACE && !(e.getTarget('form') || e.getTarget('input') || e.getTarget('textarea'))) {
        // disable the native 'history back'
        e.preventDefault();
      } else if (!window.isMainWindow && e.ctrlKey && e.getKey() === e.T) {
        // disable the native 'new tab' if in popup window
        e.preventDefault();
      } else if (window.isMainWindow && e.ctrlKey && (e.getKey() === e.L || e.getKey() === e.DELETE)) {
        // reload on ctrl-l
        Tine.Tinebase.common.reload({
          clearCache: true
        });
      } else if (e.ctrlKey && e.altKey && e.getKey() === e.S) {
        Ext.ux.screenshot.ux(window, {
          download: true,
          grabMouse: !e.shiftKey
        });
      } else if (window.isMainWindow) {
        // select first row of current grid panel if available
        var app = Tine.Tinebase.MainScreen ? Tine.Tinebase.MainScreen.getActiveApp() : null,
            centerPanel = app ? app.getMainScreen().getCenterPanel() : null,
            grid = centerPanel && Ext.isFunction(centerPanel.getGrid) ? centerPanel.getGrid() : null,
            sm = grid ? grid.getSelectionModel() : null;

        if (grid) {
          if (e.getKey() === e.ESC && sm) {
            sm.selectFirstRow();
            grid.getView().focusRow(0);
          } else {
            grid.fireEvent('keydown', e);
          }
        }
      }
    }); // disable generic drops

    Ext.getBody().on('dragover', function (e) {
      e.stopPropagation();
      e.preventDefault();
      e.browserEvent.dataTransfer.dropEffect = 'none';
    }, this); // generic context menu

    Ext.getBody().on('contextmenu', function (e) {
      var target = e.getTarget('a', 1, true) || e.getTarget('input[type=text]', 1, true) || e.getTarget('textarea', 1, true);

      if (target) {
        // allow native context menu for links + textareas + (text)input fields
        return;
      } // allow native context menu on second context click


      if (Tine.Tinebase.MainContextMenu.isVisible()) {
        Tine.Tinebase.MainContextMenu.hide();
        return;
      } // deny native context menu if we have an own one


      if (Tine.Tinebase.MainContextMenu.showIf(e)) {
        e.stopPropagation();
        e.preventDefault();
      }
    }, this);
    Ext.getBody().on('click', async function (e) {
      var _target$dom, _target$dom2;

      var target = e.getTarget('a', 1, true),
          href = target ? target.getAttribute('href') : '';
      const position = e.getXY(); // add menuitems for email links

      if ((target === null || target === void 0 ? void 0 : (_target$dom = target.dom) === null || _target$dom === void 0 ? void 0 : _target$dom.className) === 'tinebase-email-link' || (target === null || target === void 0 ? void 0 : (_target$dom2 = target.dom) === null || _target$dom2 === void 0 ? void 0 : _target$dom2.href.includes('mailto:'))) {
        var _target$dom3, _target$dom4;

        // disable default mailto link
        e.preventDefault(); // search Contact first

        const targetClassName = target === null || target === void 0 ? void 0 : (_target$dom3 = target.dom) === null || _target$dom3 === void 0 ? void 0 : _target$dom3.className;
        const email = Tine.Tinebase.common.findEmail(targetClassName === 'tinebase-email-link' ? target === null || target === void 0 ? void 0 : target.id : target === null || target === void 0 ? void 0 : (_target$dom4 = target.dom) === null || _target$dom4 === void 0 ? void 0 : _target$dom4.href);
        this.contextMenu = await this.getEmailContextMenu(target, email);
        this.contextMenu.showAt(position);
      }

      if (target && href && href !== '#') {
        // open internal links in same window (use router)
        if (window.isMainWindow === true) {
          if (target.getAttribute('target') === '_blank') {
            if (href.match(new RegExp('^' + window.lodash.escapeRegExp(Tine.Tinebase.common.getUrl())))) {
              target.set({
                href: decodeURI(href),
                target: "_self"
              });
            }
          }
        } else {
          e.preventDefault();

          if (e.ctrlKey || e.metaKey) {
            var win = window.open(href, '_blank', null, true);
            win.opener = null;
          } else {
            window.opener.location.href = href;
            window.close();
          }
        }
      } else {
        if (e.getTarget('.x-treegrid-col', 10, true)) {
          return;
        }

        let wavesEl = e.getTarget('.x-btn', 10, true) || e.getTarget('.x-tree-node-el', 10, true);

        if (wavesEl) {
          wavesEl.addClass('waves-effect');
          Waves.ripple(wavesEl.dom);
          wavesEl.removeClass.defer(1500, wavesEl, ['waves-effect']);
        }
      }
    }, this);
    Tine.clientVersion.assetHash = window.assetHash;
  },
  initPostal: function initPostal() {
    if (!window.postal) {
      return;
    }

    var config = postal.fedx.transports.xwindow.configure();
    postal.fedx.transports.xwindow.configure({
      localStoragePrefix: Tine.Tinebase.tineInit.lsPrefix + '.' + config.localStoragePrefix
    });
    postal.instanceId('xwindow-' + _.random(0, 1000));

    postal.configuration.promise.createDeferred = function () {
      return Promise.defer();
    };

    postal.configuration.promise.getPromise = function (dfd) {
      return dfd.promise;
    };

    postal.fedx.configure({
      filterMode: 'blacklist'
    });
    postal.fedx.signalReady();
    postal.addWireTap(function (d, e) {
      Tine.log.debug("ID: " + postal.instanceId() + " " + JSON.stringify(e, null, 4));
    });
  },
  initDebugConsole: function initDebugConsole() {
    var map = new Ext.KeyMap(Ext.getDoc(), [{
      key: [122],
      // F11
      ctrl: true,
      fn: Tine.Tinebase.common.showDebugConsole
    }]);
  },

  /**
   * Each window has exactly one viewport containing a card layout in its lifetime
   * The default card is a splash screen.
   *
   * default wait panel (picture only no string!)
   */
  initBootSplash: function initBootSplash() {
    Tine.Tinebase.viewport = new Ext.Viewport({
      layout: 'fit',
      border: false,
      items: {
        xtype: 'container',
        ref: 'tineViewportMaincardpanel',
        isWindowMainCardPanel: true,
        layout: 'card',
        border: false,
        activeItem: 0,
        items: [{
          xtype: 'container',
          border: false,
          layout: 'fit',
          width: 16,
          height: 16,
          // the content elements come from the initial html so they are displayed fastly
          contentEl: Ext.select('div[class^=tine-viewport-]')
        }]
      }
    });
  },
  initLoginPanel: function initLoginPanel() {
    if (window.isMainWindow && !Tine.loginPanel) {
      var mainCardPanel = Tine.Tinebase.viewport.tineViewportMaincardpanel;
      Tine.loginPanel = new Tine.Tinebase.LoginPanel({
        defaultUsername: Tine.Tinebase.registry.get('defaultUsername'),
        defaultPassword: Tine.Tinebase.registry.get('defaultPassword'),
        allowBrowserPasswordManager: Tine.Tinebase.registry.get('allowBrowserPasswordManager')
      });
      mainCardPanel.add(Tine.loginPanel);
    }
  },
  showLoginBox: function showLoginBox(cb, scope) {
    var mainCardPanel = Tine.Tinebase.viewport.tineViewportMaincardpanel,
        activeItem = mainCardPanel.layout.activeItem;
    mainCardPanel.layout.setActiveItem(Tine.loginPanel.id);
    Tine.loginPanel.doLayout();

    Tine.loginPanel.onLogin = function (response) {
      mainCardPanel.layout.setActiveItem(activeItem);
      cb.call(scope || window, response);
    };
  },

  async getEmailContextMenu(target, email) {
    // store click position, make sure menuItem diaplay around the link
    if (Tine.Addressbook) {
      var _contacts;

      let contacts = await Tine.Addressbook.searchContacts([{
        field: 'email',
        operator: 'in',
        value: email
      }]);
      contacts = (_contacts = contacts) === null || _contacts === void 0 ? void 0 : _contacts.results;
      this.contextMenu = new Ext.menu.Menu({
        items: []
      });

      if (contacts.length) {
        contacts.forEach(contact => {
          var _contact, _contact$data;

          contact = Tine.Tinebase.data.Record.setFromJson(contact, Tine.Addressbook.Model.Contact);
          const action_editContact = new Ext.Action({
            text: (_contact = contact) === null || _contact === void 0 ? void 0 : (_contact$data = _contact.data) === null || _contact$data === void 0 ? void 0 : _contact$data.n_fileas,
            handler: this.contactHandler.createDelegate(this, [target, contact]),
            iconCls: 'AddressbookIconCls',
            scope: this
          });
          this.contextMenu.addMenuItem(action_editContact);
        });
      }

      this.action_addContact = new Ext.Action({
        text: i18n._('Create Contact'),
        handler: this.contactHandler.createDelegate(this, [target]),
        iconCls: 'action_add',
        scope: this,
        hidden: contacts.length
      });
      this.contextMenu.addMenuItem(this.action_addContact);
    }

    this.action_copyEmailPlainText = new Ext.Action({
      text: i18n._('Copy to Clipboard'),
      handler: async function handler() {
        await navigator.clipboard.writeText(email).then(() => {// Success!
        }).catch(err => {
          console.log('Something went wrong', err);
        });
      },
      iconCls: 'action_copy',
      scope: this
    });
    this.action_comeposeEmail = new Ext.Action({
      text: i18n._('Compose Message To'),
      handler: async function handler() {
        let defaults = Tine.Felamimail.Model.Message.getDefaultData();
        defaults.to = [email];
        defaults.body = Tine.Felamimail.getSignature();
        const record = new Tine.Felamimail.Model.Message(defaults, 0);
        Tine.Felamimail.MessageEditDialog.openWindow({
          record: record
        });
      },
      iconCls: 'action_composeEmail',
      scope: this
    });
    this.contextMenu.addMenuItem(this.action_comeposeEmail);
    this.contextMenu.addMenuItem(this.action_copyEmailPlainText);
    return this.contextMenu;
  },

  contactHandler(target, record) {
    // check if addressbook app is available
    if (!Tine.Tinebase.common.hasRight('run', 'Addressbook')) {
      return;
    }

    Tine.Addressbook.ContactEditDialog.openWindow({
      record: record,
      listeners: {
        scope: this,
        'load': function load(editdlg) {
          if (!record) {
            var _target$dom5;

            const linkified = ((_target$dom5 = target.dom) === null || _target$dom5 === void 0 ? void 0 : _target$dom5.className) === 'linkified';
            const contactInfo = Ext.util.Format.htmlDecode(linkified ? target.dom.href : target.id);

            if (linkified) {
              editdlg.record.set('email', contactInfo.replace('mailto:', ''));
            } else {
              const parts = contactInfo.split(':');
              editdlg.record.set('email', parts[1]);
              editdlg.record.set('n_given', parts[2]);
              editdlg.record.set('n_family', parts[3]);
            }
          }
        }
      }
    });
  },

  renderWindow: function renderWindow() {
    Tine.log.info('renderWindow::start');
    Ext.MessageBox.hide(); // check if user is already logged in

    if (!Tine.Tinebase.registry.get('currentAccount')) {
      if (!window.isMainWindow) {
        window.close(); // just in case it didn't succeed

        return Ext.MessageBox.show({
          title: i18n._('Session Timed Out'),
          msg: i18n._('You can close this window.'),
          buttons: Ext.Msg.OK,
          icon: Ext.MessageBox.INFO,
          fn: window.close
        });
      }

      const areaLockException = Tine.Tinebase.registry.get('areaLockedException');

      if (areaLockException) {
        // login from post - user is authenticated but mfa is required
        return Tine.Tinebase.areaLocks.handleAreaLockException(areaLockException).then(() => {
          Ext.MessageBox.wait(String.format(i18n._('Login successful. Loading {0}...'), Tine.title), i18n._('Please wait!'));
          Tine.Tinebase.tineInit.initRegistry(true, Tine.Tinebase.tineInit.renderWindow, Tine.Tinebase.tineInit);
        }).catch(async error => {
          Ext.MessageBox.wait(i18n._('Logging you out...'), i18n._('Please wait!'));
          await Tine.Tinebase.logout();
          return Tine.Tinebase.common.reload({
            keepRegistry: false,
            clearCache: true
          });
        });
      }

      Tine.Tinebase.tineInit.showLoginBox(function (response) {
        Tine.log.info('tineInit::renderWindow -fetch users registry');
        Tine.Tinebase.tineInit.initRegistry(true, function () {
          if (Ext.isWebApp) {
            Tine.Tinebase.registry.set('sessionId', response.responseData.sessionId);
            Tine.Tinebase.registry.set('usercredentialcache', Tine.Tinebase.tineInit.jsonKeyCookieProvider.get('usercredentialcache'));
          }

          Tine.log.info('tineInit::renderWindow - registry fetched, render main window');
          Ext.MessageBox.hide();
          Tine.Tinebase.tineInit.checkClientVersion();
          Tine.Tinebase.tineInit.initWindowMgr();
          Tine.Tinebase.tineInit.renderWindow();
        });
      });
      return;
    } else {
      var sessionLifeTime = Tine.Tinebase.registry.get('sessionLifeTime') || 86400,
          // log out after sessionLifeTime of absence (NOTE: session is not over due to background requests)
      sessionLifeTimeObserver = new Tine.Tinebase.PresenceObserver({
        maxAbsenceTime: sessionLifeTime / 60,
        absenceCallback: function absenceCallback(lastPresence, po) {
          Tine.Tinebase.MainMenu.prototype._doLogout();
        }
      }),
          // report users presence to server
      userPresenceObserver = new Tine.Tinebase.PresenceObserver({
        maxAbsenceTime: 3,
        presenceCallback: function presenceCallback(lastPresence, po) {
          Tine.Tinebase.reportPresence(lastPresence);
        }
      });
    }

    Tine.Tinebase.router = new director.Router().init();
    Tine.Tinebase.router.configure({
      notfound: function notfound() {
        var defaultApp = Tine.Tinebase.appMgr.getDefault();

        if (defaultApp) {
          Tine.Tinebase.router.setRoute(defaultApp.getRoute());
        }
      }
    });
    var route = Tine.Tinebase.router.getRoute(),
        winConfig = Ext.ux.PopupWindowMgr.get(window);
    Tine.Tinebase.ApplicationStarter.init();
    Tine.Tinebase.appMgr.getAll(); // dispatch _after_ init resolvers/awaits

    _.defer(() => {
      if (winConfig) {
        var mainCardPanel = Tine.Tinebase.viewport.tineViewportMaincardpanel,
            card = Tine.WindowFactory.getCenterPanel(winConfig);
        mainCardPanel.add(card);
        mainCardPanel.layout.setActiveItem(card.id);
        card.doLayout();
      } else {
        Tine.Tinebase.router.dispatch('on', '/' + route.join('/'));
      }
    });
  },
  initAjax: function initAjax() {
    Ext.Ajax.url = Tine.Tinebase.tineInit.requestUrl;
    Ext.Ajax.method = 'POST';
    Ext.Ajax.defaultHeaders = {
      'X-Tine20-Request-Type': 'JSON'
    };
    Ext.Ajax.transactions = {};
    Tine.Tinebase.tineInit.jsonKeyCookieProvider = new Ext.ux.util.Cookie({
      path: String(Tine.Tinebase.common.getUrl('path')).replace(/\/$/, '')
    });
    /**
     * inspect all requests done via the ajax singleton
     *
     * - send custom headers
     * - send json key
     * - implicitly transform non jsonrpc requests
     *
     * NOTE: implicitly transformed reqeusts get their callback fn's proxied
     *       through generic response inspectors as defined below
     */

    Ext.Ajax.on('beforerequest', function (connection, options) {
      var jsonKey = Tine.Tinebase.registry && Tine.Tinebase.registry.get ? Tine.Tinebase.registry.get('jsonKey') : '',
          jsonKeyCookieId = Tine.Tinebase.tineInit.jsonKeyCookieId,
          cookieJsonKey = Tine.Tinebase.tineInit.jsonKeyCookieProvider.get(jsonKeyCookieId);

      if (cookieJsonKey) {
        Tine.Tinebase.tineInit.jsonKeyCookieProvider.clear(jsonKeyCookieId); // NOTE cookie reset is not always working in IE, so we need to check jsonKey again

        if (cookieJsonKey && cookieJsonKey != "null") {
          jsonKey = cookieJsonKey;
          Tine.Tinebase.registry.set('jsonKey', jsonKey);
        }
      }

      options.headers = options.headers || {};
      options.headers['X-Tine20-JsonKey'] = jsonKey;
      options.headers['X-Tine20-TransactionId'] = Tine.Tinebase.data.Record.generateUID(); // server might not accept outdated clients

      if (Tine.clientVersion.assetHash) {
        options.headers['X-Tine20-ClientAssetHash'] = Tine.clientVersion.assetHash;
      }

      options.url = Ext.urlAppend(options.url ? options.url : Tine.Tinebase.tineInit.requestUrl, 'transactionid=' + options.headers['X-Tine20-TransactionId']); // convert non Ext.Direct request to jsonrpc
      // - convert params
      // - convert error handling

      if (options.params && !options.isUpload) {
        var params = {};
        var def = Tine.Tinebase.registry.get('serviceMap') ? Tine.Tinebase.registry.get('serviceMap').services[options.params.method] : false;

        if (def) {
          // sort parms according to def
          for (var i = 0, p; i < def.parameters.length; i += 1) {
            p = def.parameters[i].name;
            params[p] = options.params[p];
          }
        } else {
          for (var param in options.params) {
            if (options.params.hasOwnProperty(param) && param !== 'method') {
              params[param] = options.params[param];
            }
          }
        }

        options.jsonData = Ext.encode({
          jsonrpc: '2.0',
          method: options.params.method,
          params: params,
          id: ++Ext.Direct.TID
        });
        options.cbs = {};
        options.cbs.success = options.success || null;
        options.cbs.failure = options.failure || null;
        options.cbs.callback = options.callback || null;
        options.isImplicitJsonRpc = true;
        delete options.params;
        delete options.success;
        delete options.failure;
        delete options.callback;
      }

      Ext.Ajax.transactions[options.headers['X-Tine20-TransactionId']] = {
        date: new Date(),
        json: options.jsonData
      };
    });
    /**
     * inspect completed responses => staus code == 200
     *
     * - detect resoponse errors (e.g. html from xdebug) and convert to exceptional states
     * - implicitly transform requests from JSONRPC
     *
     *  NOTE: All programatically catchable exceptions lead to successfull requests
     *        with the jsonprc protocol. For implicitly converted jsonprc requests we
     *        transform error states here and route them to the error methods defined
     *        in the request options
     *
     *  NOTE: Illegal json data responses are mapped to error code 530
     *        Empty resonses (Ext.Decode can't deal with them) are maped to 540
     *        Memory exhausted to 550
     */

    Ext.Ajax.on('requestcomplete', function (connection, response, options) {
      delete Ext.Ajax.transactions[options.headers['X-Tine20-TransactionId']]; // detect resoponse errors (e.g. html from xdebug) and convert into error response

      if (!options.isUpload && !response.responseText.match(/^([{\[])|(<\?xml)+/)) {
        var exception = {
          code: response.responseText !== "" ? 530 : 540,
          message: response.responseText !== "" ? 'illegal json data in response' : 'empty response',
          traceHTML: response.responseText,
          request: options.jsonData,
          response: response.responseText
        }; // Fatal error: Allowed memory size of n bytes exhausted (tried to allocate m bytes)

        if (response.responseText.match(/^Fatal error: Allowed memory size of /m)) {
          Ext.apply(exception, {
            code: 550,
            message: response.responseText
          });
        } // encapsulate as jsonrpc response


        var requestOptions = Ext.decode(options.jsonData);
        response.responseText = Ext.encode({
          jsonrpc: requestOptions.jsonrpc,
          id: requestOptions.id,
          error: {
            code: -32000,
            message: exception.message,
            data: exception
          }
        });
      } // strip jsonrpc fragments for non Ext.Direct requests


      if (options.isImplicitJsonRpc) {
        var jsonrpc = Ext.decode(response.responseText);

        if (jsonrpc.result) {
          response.responseText = Ext.encode(jsonrpc.result);

          if (options.cbs.success) {
            options.cbs.success.call(options.scope, response, options);
          }

          if (options.cbs.callback) {
            options.cbs.callback.call(options.scope, options, true, response);
          }
        } else {
          response.responseText = Ext.encode(jsonrpc.error);

          if (options.cbs.failure) {
            options.cbs.failure.call(options.scope, response, options);
          } else if (options.cbs.callback) {
            options.cbs.callback.call(options.scope, options, false, response);
          } else {
            var responseData = Ext.decode(response.responseText);
            exception = responseData.data ? responseData.data : responseData;
            exception.request = options.jsonData;
            exception.response = response.responseText;
            Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
          }
        }
      }
    });
    /**
     * inspect request exceptions
     *  - convert to jsonrpc compatiple exceptional states
     *  - call generic exception handler if no handler is defined in request options
     *
     * NOTE: Request exceptions are exceptional state from web-server:
     *       -> status codes != 200 : This kind of exceptions are not part of the jsonrpc protocol
     *       -> timeouts: status code 520
     */

    Ext.Ajax.on('requestexception', function (connection, response, options) {
      delete Ext.Ajax.transactions[options.headers['X-Tine20-TransactionId']]; // map connection errors to errorcode 510 and timeouts to 520

      var errorCode = response.status > 0 ? response.status : response.status === 0 ? 510 : 520; // convert into error response

      if (!options.isUpload) {
        var exception = {
          code: errorCode,
          message: 'request exception: ' + response.statusText,
          traceHTML: response.responseText,
          request: options.jsonData,
          requestHeaders: options.headers,
          openTransactions: Ext.Ajax.transactions,
          response: response.responseText
        }; // encapsulate as jsonrpc response

        var requestOptions = _.isString(options.jsonData) ? Ext.decode(options.jsonData) : options.jsonData;
        response.responseText = Ext.encode({
          jsonrpc: requestOptions.jsonrpc,
          id: requestOptions.id,
          error: {
            code: -32000,
            message: exception.message,
            data: exception
          }
        });
      } // NOTE: Tine.data.RecordProxy is implicitRPC atm.


      if (options.isImplicitJsonRpc) {
        var jsonrpc = Ext.decode(response.responseText);
        response.responseText = Ext.encode(jsonrpc.error);

        if (options.cbs.failure) {
          options.cbs.failure.call(options.scope, response, options);
        } else if (options.cbs.callback) {
          options.cbs.callback.call(options.scope, options, false, response);
        } else {
          var responseData = Ext.decode(response.responseText);
          exception = responseData.data ? responseData.data : responseData;
          Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
        }
      } else if (!options.failure && !options.callback) {
        Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
      }
    });
  },

  /**
   * init registry
   *
   * @param {Boolean} forceReload
   * @param {Function} cb
   * @param {Object} scope
   */
  initRegistry: async function initRegistry(forceReload, cb, scope) {
    Tine.Tinebase.registry = store.namespace(Tine.Tinebase.tineInit.lsPrefix + '.' + 'Tinebase.registry');
    var version = Tine.Tinebase.registry.get('version'),
        userApplications = Tine.Tinebase.registry.get('userApplications') || [];
    var reloadNeeded = !version || !userApplications || userApplications.length < 2;

    if (forceReload || reloadNeeded) {
      await Tine.Tinebase.tineInit.clearRegistry();
      Ext.Ajax.request({
        timeout: 120000,
        // 2 minutes
        params: {
          method: Tine.Tinebase.tineInit.getAllRegistryDataMethod
        },
        failure: function failure(exception) {
          if (exception.responseText.match(/"code":426/)) {
            return Tine.Tinebase.common.reload({
              keepRegistry: false,
              clearCache: true
            });
          } // if registry could not be loaded, this is mostly due to misconfiguration
          // don't send error reports for that!


          Tine.Tinebase.ExceptionHandler.handleRequestException({
            code: 503
          });
        },
        success: async function success(response, request) {
          var registryData = Ext.util.JSON.decode(response.responseText);

          if (Tine.Tinebase.tineInit.checkServerUpdateRequired(registryData)) {
            return;
          }

          for (var app in registryData) {
            if (registryData.hasOwnProperty(app)) {
              var appData = registryData[app];
              Ext.ns('Tine.' + app);
              Tine[app].registry = store.namespace(Tine.Tinebase.tineInit.lsPrefix + '.' + app + '.registry');

              for (var key in appData) {
                if (appData.hasOwnProperty(key)) {
                  if (key === 'preferences') {
                    Tine[app].preferences = store.namespace(Tine.Tinebase.tineInit.lsPrefix + '.' + app + '.preferences');

                    for (var pref in appData[key]) {
                      if (appData[key].hasOwnProperty(pref)) {
                        Tine[app].preferences.set(pref, appData[key][pref]);
                      }
                    }
                  } else {
                    Tine[app].registry.set(key, appData[key]);
                  }
                }
              }
            }
          } // TODO is this needed? is setting async, too?


          await Object(util_waitFor_es6__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(() => {
            return store.namespace(Tine.Tinebase.tineInit.lsPrefix).has('Tinebase.registry.version');
          });
          Tine.Tinebase.tineInit.onRegistryLoad().then(function () {
            Ext.util.CSS.refreshCache();

            if (Ext.isFunction(cb)) {
              cb.call(scope);
            }
          });
        }
      });
    } else {
      for (var app, i = 0; i < userApplications.length; i++) {
        app = userApplications[i].name;
        Ext.ns('Tine.' + app);
        Tine[app].registry = store.namespace(Tine.Tinebase.tineInit.lsPrefix + '.' + app + '.registry');
        Tine[app].preferences = store.namespace(Tine.Tinebase.tineInit.lsPrefix + '.' + app + '.preferences');
      }

      Tine.Tinebase.tineInit.onRegistryLoad().then(function () {
        Ext.util.CSS.refreshCache();

        if (Ext.isFunction(cb)) {
          cb.call(scope);
        }
      });
    }
  },

  /**
   * apply registry data
   */
  onRegistryLoad: function onRegistryLoad() {
    if (!Tine.Tinebase.tineInit.onPreferenceChangeRegistered && Tine.Tinebase.registry.get('preferences') && Tine.Tinebase.registry.get('currentAccount')) {
      // NOTE: safari (and maybe other slow browsers) need some time till all events from initial preferences
      //       loading are processed. so we wait a little bit until we register the listeners to not get notified
      //       about initial loading.
      (function () {
        Tine.log.info('tineInit::onRegistryLoad - register onPreferenceChange handler');
        Tine.Tinebase.preferences.on('replace', Tine.Tinebase.tineInit.onPreferenceChange);
        Tine.Tinebase.tineInit.onPreferenceChangeRegistered = true;
      }).defer(500);
    }

    Ext.util.CSS.updateRule('.tine-favicon', 'background-image', 'url(' + Tine.Tinebase.registry.get('brandingFaviconSvg') + ')');
    Tine.title = Tine.Tinebase.registry.get('brandingTitle');
    Tine.descriptoion = Tine.Tinebase.registry.get('brandingTitle');
    Tine.logo = Tine.Tinebase.registry.get('brandingLogo');
    Tine.weburl = Tine.Tinebase.registry.get('brandingWeburl');
    Tine.helpUrl = Tine.Tinebase.registry.get('brandingHelpUrl');
    Tine.shop = Tine.Tinebase.registry.get('brandingShopUrl');
    Tine.bugreportUrl = Tine.Tinebase.registry.get('brandingBugsUrl');
    Tine.installLogo = Tine.Tinebase.registry.get('installLogo') ? Tine.Tinebase.registry.get('installLogo') : Tine.Tinebase.registry.get('brandingLogo');
    Tine.websiteUrl = Tine.Tinebase.registry.get('websiteUrl') ? Tine.Tinebase.registry.get('websiteUrl') : Tine.Tinebase.registry.get('brandingWeburl');

    if (Ext.isWebApp && Tine.Tinebase.registry.get('sessionId')) {
      // restore session cookie
      Tine.Tinebase.tineInit.jsonKeyCookieProvider.set('TINE20SESSID', Tine.Tinebase.registry.get('sessionId'));
      Tine.Tinebase.tineInit.jsonKeyCookieProvider.set('usercredentialcache', Tine.Tinebase.registry.get('usercredentialcache'));
    }

    Ext.override(Ext.ux.file.Upload, {
      maxFileUploadSize: Tine.Tinebase.registry.get('maxFileUploadSize'),
      maxPostSize: Tine.Tinebase.registry.get('maxPostSize')
    });
    Tine.Tinebase.tineInit.initExtDirect();
    Ext.form.NumberField.prototype.decimalSeparator = Tine.Tinebase.registry.get('decimalSeparator');
    Ext.ux.form.NumberField.prototype.thousandSeparator = Tine.Tinebase.registry.get('thousandSeparator');
    formatMessage.setup({
      locale: Tine.Tinebase.registry.get('locale').locale || 'en'
    });
    Tine.Tinebase.tineInit.initState();

    if (Tine.Tinebase.registry.get('currentAccount')) {
      Tine.Tinebase.tineInit.initAppMgr();
    }

    Tine.Tinebase.tineInit.initUploadMgr();
    Tine.Tinebase.tineInit.initLoginPanel(); // we don't want iOS/Andorid to place stuff to some other cloud
    // we might need to add a real config for this
    // it's not clear how to detect devices w.o. local storage or clients which place
    // downloads in a cloud :-(

    Tine.Tinebase.configManager.set('downloadsAllowed', !Ext.isIOS && !Ext.isAndorid);

    var AreaLocks = __webpack_require__(27);

    Tine.Tinebase.areaLocks = new AreaLocks.AreaLocks(); // load initial js of user enabled apps
    // @TODO: move directly after login (login should return requested parts of registry)

    return Tine.__appLoader.loadAllApps(Tine.Tinebase.registry.get('userApplications')).then(function () {
      Tine.Tinebase.tineInit.initCustomJS();

      Tine.__onAllAppsLoadedResolve();
    });
  },

  /**
   * check client version and reload on demand
   */
  checkClientVersion: function checkClientVersion() {
    var serverHash = Tine.Tinebase.registry.get('version').assetHash,
        buildType = Tine.Tinebase.registry.get('version').buildType,
        clientHash = Tine.clientVersion.assetHash;

    if (clientHash && clientHash != serverHash && ['RELEASE', 'DEBUG'].indexOf(buildType) > -1) {
      Ext.MessageBox.show({
        buttons: Ext.Msg.OK,
        icon: Ext.MessageBox.WARNING,
        title: i18n._('Your Client is Outdated'),
        msg: i18n._('A new client is available, press OK to get this version'),
        fn: function fn() {
          Tine.Tinebase.common.reload({
            keepRegistry: false,
            clearCache: true
          });
        }
      });
    }
  },

  /**
   * check if server schema update is required
   *
   * @return {boolean}
   */
  checkServerUpdateRequired: function checkServerUpdateRequired(registryData) {
    if (_.get(registryData, 'Tinebase.setupRequired')) {
      const msg = i18n._('Tine 2.0 needs to be updated or is not installed yet.');

      const title = i18n._('Please wait or contact your administrator');

      Ext.MessageBox.show({
        title: title,
        msg: msg,
        buttons: false,
        closable: false,
        wait: true,
        modal: true,
        icon: Ext.MessageBox.WARNING,
        minWidth: Ext.MessageBox.minProgressWidth
      });
      window.setTimeout(() => {
        Tine.Tinebase.common.reload({
          keepRegistry: false,
          clearCache: true
        });
      }, 20000);
      return true;
    }
  },

  /**
   * remove all registry data
   */
  clearRegistry: async function clearRegistry() {
    Tine.log.info('tineInit::clearRegistry');

    if (Ext.isFunction(store.namespace)) {
      store.namespace(Tine.Tinebase.tineInit.lsPrefix).clearAll(); // FIXME need to call this twice - as the first clearAll does not clear everything
      //       we should remove/replace the store lib ...

      store.namespace(Tine.Tinebase.tineInit.lsPrefix).clearAll();
      await Object(util_waitFor_es6__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(() => {
        return !store.namespace(Tine.Tinebase.tineInit.lsPrefix).has('Tinebase.registry.version');
      });
    }
  },

  /**
   * executed when a value in Tinebase registry/preferences changed
   *
   * @param {string} key
   * @param {value} oldValue
   * @param {value} newValue
   */
  onPreferenceChange: function onPreferenceChange(key, oldValue, newValue) {
    if (Tine.Tinebase.tineInit.isReloading) {
      return;
    }

    switch (key) {
      case 'windowtype':
      case 'confirmLogout':
      case 'timezone':
      case 'locale':
        Tine.log.info('tineInit::onPreferenceChange - reload mainscreen');
        Tine.Tinebase.common.reload({
          clearCache: key == 'locale'
        });
        break;
    }
  },

  /**
   * initialise window and windowMgr (only popup atm.)
   */
  initWindowMgr: function initWindowMgr() {
    // touch UI support
    if (Ext.isTouchDevice) {
      __webpack_require__.e(/* require.ensure | Tinebase/js/hammerjs */ 41).then((function () {
        __webpack_require__(25); // global by include :-(


        Ext.apply(Ext.EventObject, {
          // NOTE: multipoint gesture events have no xy, so we need to grab it from gesture
          getXY: function getXY() {
            if (this.browserEvent && this.browserEvent.gesture && this.browserEvent.gesture.center) {
              this.xy = [this.browserEvent.gesture.center.x, this.browserEvent.gesture.center.y];
            }

            return this.xy;
          }
        });
        var mc = new Hammer.Manager(Ext.getDoc().dom, {
          domEvents: true
        }); // convert two finger taps into contextmenu clicks

        mc.add(new Hammer.Tap({
          event: 'contextmenu',
          pointers: 2
        })); // convert double taps into double clicks

        mc.add(new Hammer.Tap({
          event: 'dblclick',
          taps: 2
        })); // NOTE: document scroll only happens when soft keybord is displayed and therefore viewport scrolls.
        //       in this case, content might not be accessable
        //Ext.getDoc().on('scroll', function() {
        //
        //}, this);
      }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
    }

    Ext.getDoc().on('orientationchange', function () {
      // @TODO: iOS safari only?
      var metas = document.getElementsByTagName('meta');

      for (var i = 0; i < metas.length; i++) {
        if (metas[i].name == "viewport") {
          metas[i].content = "width=device-width, maximum-scale=1.0"; // NOTE: if we don't release the max scale here, we get wired layout effects

          metas[i].content = "width=device-width, maximum-scale=10, user-scalable=no";
        }
      } // NOTE: need to hide soft-keybord before relayouting to preserve layout


      document.activeElement.blur();
      Tine.Tinebase.viewport.doLayout.defer(500, Tine.Tinebase.viewport);
    }, this); // adjust modal windows when browser gets resized (also orientation change)

    Tine.Tinebase.viewport.on('resize', function (viewport, adjWidth, adjHeight, rawWidth, rawHeight) {
      Ext.WindowMgr.each(function (win) {
        var currSize = win.getSize(),
            normSize = win.normSize || currSize,
            maxSize = {
          width: adjWidth,
          height: adjHeight
        };
        win.setSize(Math.min(Math.max(currSize.width, normSize.width), maxSize.width), Math.min(Math.max(currSize.height, normSize.height), maxSize.height));
        win.center();
      });
    }, this, {
      buffer: 150
    }); // initialise window types

    var windowType = '';
    Ext.ux.PopupWindow.prototype.url = Tine.Tinebase.common.getUrl();

    if (Tine.Tinebase.registry && Tine.Tinebase.registry.get('preferences')) {
      // update window factory window type (required after login)
      windowType = Tine.Tinebase.registry.get('preferences').get('windowtype');
    }

    if (!windowType || windowType == 'autodetect') {
      // var browserDetection = require('browser-detection');
      windowType = Ext.supportsPopupWindows ? 'Browser' : 'Ext';
    }

    Tine.WindowFactory = new Ext.ux.WindowFactory({
      windowType: windowType
    });
  },

  /**
   * initialise state provider
   */
  initState: function initState() {
    if (Tine.Tinebase.tineInit.stateful === true) {
      if (window.isMainWindow) {
        // NOTE: IE is as always pain in the ass! cross window issues prohibit serialisation of state objects
        Ext.state.Manager.setProvider(new Tine.Tinebase.StateProvider());
      } else {
        var mainWindow = Ext.ux.PopupWindowMgr.getMainWindow();
        Ext.state.Manager = mainWindow.Ext.state.Manager;
      }
    }
  },

  /**
   * add provider to Ext.Direct based on Tine servicemap
   */
  initExtDirect: function initExtDirect() {
    var sam = Tine.Tinebase.registry.get('serviceMap');
    Ext.Direct.addProvider(Ext.apply(sam, {
      'type': 'jsonrpcprovider',
      'namespace': 'Tine',
      'url': sam.target
    }));
  },

  /**
   * initialise application manager
   */
  initAppMgr: function initAppMgr() {
    if (!window.isMainWindow) {
      // return app from main window for non-IE browsers
      Tine.Tinebase.appMgr = Ext.ux.PopupWindowMgr.getMainWindow().Tine.Tinebase.appMgr;
    } else {
      Tine.Tinebase.appMgr = new Tine.Tinebase.AppManager();
    }
  },

  /**
   * initialise upload manager
   */
  initUploadMgr: function initUploadMgr() {
    if (!window.isMainWindow) {
      Tine.Tinebase.uploadManager = Ext.ux.PopupWindowMgr.getMainWindow().Tine.Tinebase.uploadManager;
    } else {
      Tine.Tinebase.uploadManager = new Ext.ux.file.UploadManager();
      Tine.Tinebase.uploadManager.InitChannels();
    }
  },

  /**
   * config locales
   */
  initLocale: async function initLocale() {
    var _ = window.lodash,
        formatMessage = __webpack_require__(5); // NOTE: we use gettext tooling for template selection
    //       as there is almost no tooling for icu-messages out there


    formatMessage.setup({
      missingTranslation: 'ignore'
    }); // auto template selection with gettext

    window.formatMessage = function (template) {
      arguments[0] = window.i18n._hidden(template);
      return formatMessage.apply(formatMessage, arguments);
    };

    window.lodash.assign(window.formatMessage, formatMessage);

    __webpack_require__(12);

    __webpack_require__(13);

    await Object(util_waitFor_es6__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(function () {
      return Tine.__translationData.__isLoaded;
    });

    Tine.__applyExtTranslations();

    _.each(Tine.__translationData.msgs, function (msgs, category) {
      Locale.Gettext.prototype._msgs[category] = new Locale.Gettext.PO(msgs);
    });

    window.i18n = new Locale.Gettext();
    window.i18n.textdomain('Tinebase');
  }
};
Ext.onReady(async function () {
  Tine.Tinebase.tineInit.initWindow();
  Tine.Tinebase.tineInit.initPostal();
  Tine.Tinebase.tineInit.initDebugConsole();
  Tine.Tinebase.tineInit.initBootSplash();
  await Tine.Tinebase.tineInit.initLocale();
  Tine.Tinebase.tineInit.initAjax();
  Tine.Tinebase.tineInit.initRegistry(false, function () {
    Tine.Tinebase.tineInit.checkClientVersion();
    Tine.Tinebase.tineInit.initWindowMgr();
    Tine.Tinebase.tineInit.renderWindow();
  }); // TODO use await
  // await Tine.Tinebase.tineInit.initRegistry(false);
  // Tine.Tinebase.tineInit.checkClientVersion();
  // Tine.Tinebase.tineInit.initWindowMgr();
  // Tine.Tinebase.tineInit.renderWindow();
});

/***/ }),
/* 20 */,
/* 21 */,
/* 22 */
/***/ (function(module, exports) {

// shim for using process in browser
var process = module.exports = {};

// cached from whatever global is present so that test runners that stub it
// don't break things.  But we need to wrap it in a try catch in case it is
// wrapped in strict mode code which doesn't define any globals.  It's inside a
// function because try/catches deoptimize in certain engines.

var cachedSetTimeout;
var cachedClearTimeout;

function defaultSetTimout() {
    throw new Error('setTimeout has not been defined');
}
function defaultClearTimeout () {
    throw new Error('clearTimeout has not been defined');
}
(function () {
    try {
        if (typeof setTimeout === 'function') {
            cachedSetTimeout = setTimeout;
        } else {
            cachedSetTimeout = defaultSetTimout;
        }
    } catch (e) {
        cachedSetTimeout = defaultSetTimout;
    }
    try {
        if (typeof clearTimeout === 'function') {
            cachedClearTimeout = clearTimeout;
        } else {
            cachedClearTimeout = defaultClearTimeout;
        }
    } catch (e) {
        cachedClearTimeout = defaultClearTimeout;
    }
} ())
function runTimeout(fun) {
    if (cachedSetTimeout === setTimeout) {
        //normal enviroments in sane situations
        return setTimeout(fun, 0);
    }
    // if setTimeout wasn't available but was latter defined
    if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
        cachedSetTimeout = setTimeout;
        return setTimeout(fun, 0);
    }
    try {
        // when when somebody has screwed with setTimeout but no I.E. maddness
        return cachedSetTimeout(fun, 0);
    } catch(e){
        try {
            // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
            return cachedSetTimeout.call(null, fun, 0);
        } catch(e){
            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
            return cachedSetTimeout.call(this, fun, 0);
        }
    }


}
function runClearTimeout(marker) {
    if (cachedClearTimeout === clearTimeout) {
        //normal enviroments in sane situations
        return clearTimeout(marker);
    }
    // if clearTimeout wasn't available but was latter defined
    if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
        cachedClearTimeout = clearTimeout;
        return clearTimeout(marker);
    }
    try {
        // when when somebody has screwed with setTimeout but no I.E. maddness
        return cachedClearTimeout(marker);
    } catch (e){
        try {
            // When we are in I.E. but the script has been evaled so I.E. doesn't  trust the global object when called normally
            return cachedClearTimeout.call(null, marker);
        } catch (e){
            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
            // Some versions of I.E. have different rules for clearTimeout vs setTimeout
            return cachedClearTimeout.call(this, marker);
        }
    }



}
var queue = [];
var draining = false;
var currentQueue;
var queueIndex = -1;

function cleanUpNextTick() {
    if (!draining || !currentQueue) {
        return;
    }
    draining = false;
    if (currentQueue.length) {
        queue = currentQueue.concat(queue);
    } else {
        queueIndex = -1;
    }
    if (queue.length) {
        drainQueue();
    }
}

function drainQueue() {
    if (draining) {
        return;
    }
    var timeout = runTimeout(cleanUpNextTick);
    draining = true;

    var len = queue.length;
    while(len) {
        currentQueue = queue;
        queue = [];
        while (++queueIndex < len) {
            if (currentQueue) {
                currentQueue[queueIndex].run();
            }
        }
        queueIndex = -1;
        len = queue.length;
    }
    currentQueue = null;
    draining = false;
    runClearTimeout(timeout);
}

process.nextTick = function (fun) {
    var args = new Array(arguments.length - 1);
    if (arguments.length > 1) {
        for (var i = 1; i < arguments.length; i++) {
            args[i - 1] = arguments[i];
        }
    }
    queue.push(new Item(fun, args));
    if (queue.length === 1 && !draining) {
        runTimeout(drainQueue);
    }
};

// v8 likes predictible objects
function Item(fun, array) {
    this.fun = fun;
    this.array = array;
}
Item.prototype.run = function () {
    this.fun.apply(null, this.array);
};
process.title = 'browser';
process.browser = true;
process.env = {};
process.argv = [];
process.version = ''; // empty string to avoid regexp issues
process.versions = {};

function noop() {}

process.on = noop;
process.addListener = noop;
process.once = noop;
process.off = noop;
process.removeListener = noop;
process.removeAllListeners = noop;
process.emit = noop;
process.prependListener = noop;
process.prependOnceListener = noop;

process.listeners = function (name) { return [] }

process.binding = function (name) {
    throw new Error('process.binding is not supported');
};

process.cwd = function () { return '/' };
process.chdir = function (dir) {
    throw new Error('process.chdir is not supported');
};
process.umask = function() { return 0; };


/***/ }),
/* 23 */
/***/ (function(module, exports) {

module.exports = function(module) {
	if (!module.webpackPolyfill) {
		module.deprecate = function() {};
		module.paths = [];
		// module.parent = undefined by default
		if (!module.children) module.children = [];
		Object.defineProperty(module, "loaded", {
			enumerable: true,
			get: function() {
				return module.l;
			}
		});
		Object.defineProperty(module, "id", {
			enumerable: true,
			get: function() {
				return module.i;
			}
		});
		module.webpackPolyfill = 1;
	}
	return module;
};


/***/ }),
/* 24 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.



var R = typeof Reflect === 'object' ? Reflect : null
var ReflectApply = R && typeof R.apply === 'function'
  ? R.apply
  : function ReflectApply(target, receiver, args) {
    return Function.prototype.apply.call(target, receiver, args);
  }

var ReflectOwnKeys
if (R && typeof R.ownKeys === 'function') {
  ReflectOwnKeys = R.ownKeys
} else if (Object.getOwnPropertySymbols) {
  ReflectOwnKeys = function ReflectOwnKeys(target) {
    return Object.getOwnPropertyNames(target)
      .concat(Object.getOwnPropertySymbols(target));
  };
} else {
  ReflectOwnKeys = function ReflectOwnKeys(target) {
    return Object.getOwnPropertyNames(target);
  };
}

function ProcessEmitWarning(warning) {
  if (console && console.warn) console.warn(warning);
}

var NumberIsNaN = Number.isNaN || function NumberIsNaN(value) {
  return value !== value;
}

function EventEmitter() {
  EventEmitter.init.call(this);
}
module.exports = EventEmitter;

// Backwards-compat with node 0.10.x
EventEmitter.EventEmitter = EventEmitter;

EventEmitter.prototype._events = undefined;
EventEmitter.prototype._eventsCount = 0;
EventEmitter.prototype._maxListeners = undefined;

// By default EventEmitters will print a warning if more than 10 listeners are
// added to it. This is a useful default which helps finding memory leaks.
var defaultMaxListeners = 10;

function checkListener(listener) {
  if (typeof listener !== 'function') {
    throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof listener);
  }
}

Object.defineProperty(EventEmitter, 'defaultMaxListeners', {
  enumerable: true,
  get: function() {
    return defaultMaxListeners;
  },
  set: function(arg) {
    if (typeof arg !== 'number' || arg < 0 || NumberIsNaN(arg)) {
      throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + arg + '.');
    }
    defaultMaxListeners = arg;
  }
});

EventEmitter.init = function() {

  if (this._events === undefined ||
      this._events === Object.getPrototypeOf(this)._events) {
    this._events = Object.create(null);
    this._eventsCount = 0;
  }

  this._maxListeners = this._maxListeners || undefined;
};

// Obviously not all Emitters should be limited to 10. This function allows
// that to be increased. Set to zero for unlimited.
EventEmitter.prototype.setMaxListeners = function setMaxListeners(n) {
  if (typeof n !== 'number' || n < 0 || NumberIsNaN(n)) {
    throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + n + '.');
  }
  this._maxListeners = n;
  return this;
};

function _getMaxListeners(that) {
  if (that._maxListeners === undefined)
    return EventEmitter.defaultMaxListeners;
  return that._maxListeners;
}

EventEmitter.prototype.getMaxListeners = function getMaxListeners() {
  return _getMaxListeners(this);
};

EventEmitter.prototype.emit = function emit(type) {
  var args = [];
  for (var i = 1; i < arguments.length; i++) args.push(arguments[i]);
  var doError = (type === 'error');

  var events = this._events;
  if (events !== undefined)
    doError = (doError && events.error === undefined);
  else if (!doError)
    return false;

  // If there is no 'error' event listener then throw.
  if (doError) {
    var er;
    if (args.length > 0)
      er = args[0];
    if (er instanceof Error) {
      // Note: The comments on the `throw` lines are intentional, they show
      // up in Node's output if this results in an unhandled exception.
      throw er; // Unhandled 'error' event
    }
    // At least give some kind of context to the user
    var err = new Error('Unhandled error.' + (er ? ' (' + er.message + ')' : ''));
    err.context = er;
    throw err; // Unhandled 'error' event
  }

  var handler = events[type];

  if (handler === undefined)
    return false;

  if (typeof handler === 'function') {
    ReflectApply(handler, this, args);
  } else {
    var len = handler.length;
    var listeners = arrayClone(handler, len);
    for (var i = 0; i < len; ++i)
      ReflectApply(listeners[i], this, args);
  }

  return true;
};

function _addListener(target, type, listener, prepend) {
  var m;
  var events;
  var existing;

  checkListener(listener);

  events = target._events;
  if (events === undefined) {
    events = target._events = Object.create(null);
    target._eventsCount = 0;
  } else {
    // To avoid recursion in the case that type === "newListener"! Before
    // adding it to the listeners, first emit "newListener".
    if (events.newListener !== undefined) {
      target.emit('newListener', type,
                  listener.listener ? listener.listener : listener);

      // Re-assign `events` because a newListener handler could have caused the
      // this._events to be assigned to a new object
      events = target._events;
    }
    existing = events[type];
  }

  if (existing === undefined) {
    // Optimize the case of one listener. Don't need the extra array object.
    existing = events[type] = listener;
    ++target._eventsCount;
  } else {
    if (typeof existing === 'function') {
      // Adding the second element, need to change to array.
      existing = events[type] =
        prepend ? [listener, existing] : [existing, listener];
      // If we've already got an array, just append.
    } else if (prepend) {
      existing.unshift(listener);
    } else {
      existing.push(listener);
    }

    // Check for listener leak
    m = _getMaxListeners(target);
    if (m > 0 && existing.length > m && !existing.warned) {
      existing.warned = true;
      // No error code for this since it is a Warning
      // eslint-disable-next-line no-restricted-syntax
      var w = new Error('Possible EventEmitter memory leak detected. ' +
                          existing.length + ' ' + String(type) + ' listeners ' +
                          'added. Use emitter.setMaxListeners() to ' +
                          'increase limit');
      w.name = 'MaxListenersExceededWarning';
      w.emitter = target;
      w.type = type;
      w.count = existing.length;
      ProcessEmitWarning(w);
    }
  }

  return target;
}

EventEmitter.prototype.addListener = function addListener(type, listener) {
  return _addListener(this, type, listener, false);
};

EventEmitter.prototype.on = EventEmitter.prototype.addListener;

EventEmitter.prototype.prependListener =
    function prependListener(type, listener) {
      return _addListener(this, type, listener, true);
    };

function onceWrapper() {
  if (!this.fired) {
    this.target.removeListener(this.type, this.wrapFn);
    this.fired = true;
    if (arguments.length === 0)
      return this.listener.call(this.target);
    return this.listener.apply(this.target, arguments);
  }
}

function _onceWrap(target, type, listener) {
  var state = { fired: false, wrapFn: undefined, target: target, type: type, listener: listener };
  var wrapped = onceWrapper.bind(state);
  wrapped.listener = listener;
  state.wrapFn = wrapped;
  return wrapped;
}

EventEmitter.prototype.once = function once(type, listener) {
  checkListener(listener);
  this.on(type, _onceWrap(this, type, listener));
  return this;
};

EventEmitter.prototype.prependOnceListener =
    function prependOnceListener(type, listener) {
      checkListener(listener);
      this.prependListener(type, _onceWrap(this, type, listener));
      return this;
    };

// Emits a 'removeListener' event if and only if the listener was removed.
EventEmitter.prototype.removeListener =
    function removeListener(type, listener) {
      var list, events, position, i, originalListener;

      checkListener(listener);

      events = this._events;
      if (events === undefined)
        return this;

      list = events[type];
      if (list === undefined)
        return this;

      if (list === listener || list.listener === listener) {
        if (--this._eventsCount === 0)
          this._events = Object.create(null);
        else {
          delete events[type];
          if (events.removeListener)
            this.emit('removeListener', type, list.listener || listener);
        }
      } else if (typeof list !== 'function') {
        position = -1;

        for (i = list.length - 1; i >= 0; i--) {
          if (list[i] === listener || list[i].listener === listener) {
            originalListener = list[i].listener;
            position = i;
            break;
          }
        }

        if (position < 0)
          return this;

        if (position === 0)
          list.shift();
        else {
          spliceOne(list, position);
        }

        if (list.length === 1)
          events[type] = list[0];

        if (events.removeListener !== undefined)
          this.emit('removeListener', type, originalListener || listener);
      }

      return this;
    };

EventEmitter.prototype.off = EventEmitter.prototype.removeListener;

EventEmitter.prototype.removeAllListeners =
    function removeAllListeners(type) {
      var listeners, events, i;

      events = this._events;
      if (events === undefined)
        return this;

      // not listening for removeListener, no need to emit
      if (events.removeListener === undefined) {
        if (arguments.length === 0) {
          this._events = Object.create(null);
          this._eventsCount = 0;
        } else if (events[type] !== undefined) {
          if (--this._eventsCount === 0)
            this._events = Object.create(null);
          else
            delete events[type];
        }
        return this;
      }

      // emit removeListener for all listeners on all events
      if (arguments.length === 0) {
        var keys = Object.keys(events);
        var key;
        for (i = 0; i < keys.length; ++i) {
          key = keys[i];
          if (key === 'removeListener') continue;
          this.removeAllListeners(key);
        }
        this.removeAllListeners('removeListener');
        this._events = Object.create(null);
        this._eventsCount = 0;
        return this;
      }

      listeners = events[type];

      if (typeof listeners === 'function') {
        this.removeListener(type, listeners);
      } else if (listeners !== undefined) {
        // LIFO order
        for (i = listeners.length - 1; i >= 0; i--) {
          this.removeListener(type, listeners[i]);
        }
      }

      return this;
    };

function _listeners(target, type, unwrap) {
  var events = target._events;

  if (events === undefined)
    return [];

  var evlistener = events[type];
  if (evlistener === undefined)
    return [];

  if (typeof evlistener === 'function')
    return unwrap ? [evlistener.listener || evlistener] : [evlistener];

  return unwrap ?
    unwrapListeners(evlistener) : arrayClone(evlistener, evlistener.length);
}

EventEmitter.prototype.listeners = function listeners(type) {
  return _listeners(this, type, true);
};

EventEmitter.prototype.rawListeners = function rawListeners(type) {
  return _listeners(this, type, false);
};

EventEmitter.listenerCount = function(emitter, type) {
  if (typeof emitter.listenerCount === 'function') {
    return emitter.listenerCount(type);
  } else {
    return listenerCount.call(emitter, type);
  }
};

EventEmitter.prototype.listenerCount = listenerCount;
function listenerCount(type) {
  var events = this._events;

  if (events !== undefined) {
    var evlistener = events[type];

    if (typeof evlistener === 'function') {
      return 1;
    } else if (evlistener !== undefined) {
      return evlistener.length;
    }
  }

  return 0;
}

EventEmitter.prototype.eventNames = function eventNames() {
  return this._eventsCount > 0 ? ReflectOwnKeys(this._events) : [];
};

function arrayClone(arr, n) {
  var copy = new Array(n);
  for (var i = 0; i < n; ++i)
    copy[i] = arr[i];
  return copy;
}

function spliceOne(list, index) {
  for (; index + 1 < list.length; index++)
    list[index] = list[index + 1];
  list.pop();
}

function unwrapListeners(arr) {
  var ret = new Array(arr.length);
  for (var i = 0; i < ret.length; ++i) {
    ret[i] = arr[i].listener || arr[i];
  }
  return ret;
}


/***/ }),
/* 25 */,
/* 26 */
/***/ (function(module, exports, __webpack_require__) {

var _ = window.lodash,
     availableApps = {
  "ActiveSync/js/ActiveSync": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/ActiveSync/ActiveSync.jsb2",
  "Addressbook/js/Addressbook": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Addressbook/Addressbook.jsb2",
  "Admin/js/Admin": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Admin/Admin.jsb2",
  "Bookmarks/js/Bookmarks": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Bookmarks/js/Bookmarks.js",
  "Calendar/js/Calendar": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Calendar/js/Calendar.js",
  "CoreData/js/CoreData": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/CoreData/CoreData.jsb2",
  "Courses/js/Courses": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Courses/Courses.jsb2",
  "Crm/js/Crm": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Crm/Crm.jsb2",
  "EFile/js/EFile": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/EFile/js/eFile.js",
  "ExampleApplication/js/ExampleApplication": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/ExampleApplication/ExampleApplication.jsb2",
  "Felamimail/js/Felamimail": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Felamimail/Felamimail.jsb2",
  "Filemanager/js/Filemanager": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Filemanager/Filemanager.jsb2",
  "GDPR/js/GDPR": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/GDPR/js/gdpr.js",
  "HumanResources/js/HumanResources": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/HumanResources/HumanResources.jsb2",
  "Inventory/js/Inventory": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Inventory/Inventory.jsb2",
  "OnlyOfficeIntegrator/js/OnlyOfficeIntegrator": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/OnlyOfficeIntegrator/js/onlyOffice.js",
  "Phone/js/Phone": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Phone/Phone.jsb2",
  "Projects/js/Projects": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Projects/Projects.jsb2",
  "SSO/js/SSO": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/SSO/js/sso.js",
  "Sales/js/Sales": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Sales/Sales.jsb2",
  "Setup/js/Setup": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Setup/js/Setup.js",
  "SimpleFAQ/js/SimpleFAQ": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/SimpleFAQ/SimpleFAQ.jsb2",
  "Tasks/js/Tasks": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Tasks/Tasks.jsb2",
  "Timetracker/js/Timetracker": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Timetracker/Timetracker.jsb2",
  "Tinebase/js/Tinebase": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Tinebase/js/Tinebase.js",
  "UserManual/js/UserManual": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/UserManual/js/UserManual.js",
  "Voipmanager/js/Voipmanager": "/root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Voipmanager/Voipmanager.jsb2"
},
     appResolves = {},
     appLoadedPromises = {};

_.each(availableApps, function(index,key) {
  var appName = key.replace(/\/.*$/, "");
  appLoadedPromises[appName] = new Promise(function(resolve) {
    appResolves[appName] = resolve;
  });
});

module.exports = {
  loadAllApps: function(userApps) {
    var pms = _.reduce(userApps, function(p, app) {
      var appName = "ActiveSync"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | ActiveSync/js/ActiveSync */ 0).then(__webpack_require__.t.bind(null, 49, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Addressbook"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Addressbook/js/Addressbook */ 1).then(__webpack_require__.t.bind(null, 50, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Admin"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Admin/js/Admin */ 2).then(__webpack_require__.t.bind(null, 51, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Bookmarks"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Bookmarks/js/Bookmarks */ 3).then(__webpack_require__.t.bind(null, 52, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Calendar"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Calendar/js/Calendar */ 4).then(__webpack_require__.t.bind(null, 43, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "CoreData"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | CoreData/js/CoreData */ 6).then(__webpack_require__.t.bind(null, 53, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Courses"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Courses/js/Courses */ 7).then(__webpack_require__.t.bind(null, 54, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Crm"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Crm/js/Crm */ 8).then(__webpack_require__.t.bind(null, 55, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "EFile"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | EFile/js/EFile */ 9).then(__webpack_require__.bind(null, 73))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "ExampleApplication"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | ExampleApplication/js/ExampleApplication */ 10).then(__webpack_require__.t.bind(null, 56, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Felamimail"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Felamimail/js/Felamimail */ 11).then(__webpack_require__.t.bind(null, 57, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Filemanager"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Filemanager/js/Filemanager */ 12).then(__webpack_require__.t.bind(null, 58, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "GDPR"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | GDPR/js/GDPR */ 14).then(__webpack_require__.t.bind(null, 59, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "HumanResources"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | HumanResources/js/HumanResources */ 15).then(__webpack_require__.t.bind(null, 60, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Inventory"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Inventory/js/Inventory */ 16).then(__webpack_require__.t.bind(null, 61, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "OnlyOfficeIntegrator"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | OnlyOfficeIntegrator/js/OnlyOfficeIntegrator */ 17).then(__webpack_require__.t.bind(null, 62, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Phone"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Phone/js/Phone */ 18).then(__webpack_require__.t.bind(null, 63, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Projects"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Projects/js/Projects */ 19).then(__webpack_require__.t.bind(null, 64, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "SSO"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | SSO/js/SSO */ 20).then(__webpack_require__.bind(null, 65))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Sales"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Sales/js/Sales */ 24).then(__webpack_require__.t.bind(null, 66, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Setup"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Setup/js/Setup */ 25).then(__webpack_require__.t.bind(null, 67, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "SimpleFAQ"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | SimpleFAQ/js/SimpleFAQ */ 27).then(__webpack_require__.t.bind(null, 68, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Tasks"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Tasks/js/Tasks */ 28).then(__webpack_require__.t.bind(null, 69, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Timetracker"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Timetracker/js/Timetracker */ 29).then(__webpack_require__.t.bind(null, 70, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Tinebase"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Tinebase/js/Tinebase */ 33).then(__webpack_require__.t.bind(null, 14, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "UserManual"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | UserManual/js/UserManual */ 48).then(__webpack_require__.t.bind(null, 71, 7))}).then(function() {
          appResolves[appName]();
        });
      }

      var appName = "Voipmanager"; 
      if(app.name == appName) {
        return p.then(function() {return __webpack_require__.e(/* import() | Voipmanager/js/Voipmanager */ 49).then(__webpack_require__.t.bind(null, 72, 7))}).then(function() {
          appResolves[appName]();
        });
      }

    return p;
    }, Promise.resolve());
    return pms;
  },
  appLoadedPromises: appLoadedPromises
}


/***/ }),
/* 27 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXPORTS
__webpack_require__.d(__webpack_exports__, "AreaLocks", function() { return /* binding */ AreaLocks_AreaLocks; });

// CONCATENATED MODULE: ./MFA/Providers/Abstract.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */
class Abstract {
  /**
   * @config areaName
   */

  /**
   * @config mfaDevice
   */
  constructor(config) {
    _.assign(this, config);
  }

  async unlock() {}

}

/* harmony default export */ var Providers_Abstract = (Abstract);
// CONCATENATED MODULE: ./MFA/Providers/Generic.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global Tine,i18n */

class Generic_Generic extends Providers_Abstract {
  constructor(config) {
    super(config);
    this.windowTitle = i18n._('MFA secret required');
    this.questionText = formatMessage('This area is locked. To unlock it you need to provide the secret from your Multi factor authentication device {mfaDevice.device_name}.', this);
    this.passwordFieldLabel = formatMessage('Secret from {mfaDevice.device_name}', this);
  }

  unlock(opts) {
    let me = this;
    return new Promise((resolve, reject) => {
      let pwDlg = new Tine.Tinebase.widgets.dialog.PasswordDialog({
        windowTitle: me.windowTitle,
        questionText: me.questionText,
        passwordFieldLabel: me.passwordFieldLabel,
        allowEmptyPassword: false,
        hasPwGen: false,
        locked: !me.isOTP
      });
      pwDlg.openWindow();
      pwDlg.on('apply', async password => {
        try {
          const unlockMethod = this.unlockMethod || Tine.Tinebase_AreaLock.unlock;
          resolve(await unlockMethod(me.areaName, me.mfaDevice.id, password));
        } catch (e) {
          reject(e);
        }
      });
      pwDlg.on('cancel', () => {
        reject(new Error('USERABORT'));
      });
    });
  }

}

/* harmony default export */ var Providers_Generic = (Generic_Generic);
// CONCATENATED MODULE: ./MFA/Providers/UserPassword.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global Tine,i18n */

class UserPassword_UserPassword extends Providers_Generic {
  constructor(config) {
    super(config);
    this.windowTitle = i18n._('Password required');
    this.questionText = i18n._('This area is locked. To unlock it you need to provide your password.');
    this.passwordFieldLabel = i18n._('Password');
  }

}

/* harmony default export */ var Providers_UserPassword = (UserPassword_UserPassword);
// CONCATENATED MODULE: ./MFA/Providers/Pin.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global i18n */

class Pin_Pin extends Providers_Generic {
  constructor(config) {
    super(config);
    this.windowTitle = i18n._('PIN required');
    this.questionText = formatMessage('This area is locked. To unlock it you need to provide your {mfaDevice.device_name} secret.', this);
    this.passwordFieldLabel = formatMessage('{mfaDevice.device_name} secret', this);
  }

}

/* harmony default export */ var Providers_Pin = (Pin_Pin);
// CONCATENATED MODULE: ./MFA/Providers/Token.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global i18n */

class Token_Token extends Providers_Generic {
  constructor(config) {
    super(config);
    this.windowTitle = i18n._('Token required');
    this.questionText = formatMessage('This area is locked. To unlock it you need to provide your token from your {mfaDevice.device_name}.', this);
    this.passwordFieldLabel = formatMessage('Token from {mfaDevice.device_name}', this);
  }

}

/* harmony default export */ var Providers_Token = (Token_Token);
// CONCATENATED MODULE: ./MFA/Providers/Sms.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */


class Sms_Sms extends Providers_Generic {
  constructor(config) {
    super(config);
    this.isOTP = true;
    this.windowTitle = i18n._('SMS security code required');
    this.questionText = formatMessage('This area is locked. To unlock it we send a securitycode to via {mfaDevice.device_name}.', this);
    this.passwordFieldLabel = formatMessage('Security code from {mfaDevice.device_name}', this);
  }

  async unlock(opts) {
    const triggerMFAMethod = this.triggerMFAMethod || Tine.Tinebase_AreaLock.triggerMFA;
    triggerMFAMethod(this.mfaDevice.id);
    return super.unlock(opts);
  }

}

/* harmony default export */ var Providers_Sms = (Sms_Sms);
// CONCATENATED MODULE: ./MFA/Providers/YubicoOTP.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global Tine,i18n */

class YubicoOTP_YubicoOTP extends Providers_Generic {
  constructor(config) {
    super(config);
    this.windowTitle = i18n._('Yubico OTP required');
    this.questionText = i18n._('This area is locked. To unlock it you need to provide your Yubico OTP.');
    this.passwordFieldLabel = i18n._('Yubico OTP');
  }

}

/* harmony default export */ var Providers_YubicoOTP = (YubicoOTP_YubicoOTP);
// CONCATENATED MODULE: ./MFA/Providers/HTOTPAuthenticator.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */


class HTOTPAuthenticator_HTOPTAuthenticator extends Providers_Generic {
  constructor(config) {
    super(config);
    this.isOTP = true;
    this.windowTitle = i18n._('Authenticator code required');
    this.questionText = formatMessage('This area is locked. To unlock it you need to provide the code from your authenticator app {mfaDevice.device_name}.', this);
    this.passwordFieldLabel = formatMessage('Authenticator code from {mfaDevice.device_name}', this);
  }

}

/* harmony default export */ var HTOTPAuthenticator = (HTOTPAuthenticator_HTOPTAuthenticator);
// CONCATENATED MODULE: ./MFA/Providers/WebAuthn.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global Tine,i18n */

class WebAuthn_WebAuthn extends Providers_Abstract {
  constructor(config) {
    super(config); // this.windowTitle = i18n._('MFA secret required')
    // this.questionText = formatMessage('This area is locked. To unlock it you need to provide the secret from your Multi factor authentication device {mfaDevice.device_name}.', this)
    // this.passwordFieldLabel = formatMessage('Secret from {mfaDevice.device_name}', this)
  }

  async unlock(opts) {
    const rfc4648 = await __webpack_require__.e(/* import() | Tinebase/js/rfc4648 */ 47).then(__webpack_require__.bind(null, 679));
    const publicKeyOptions = await Tine.Tinebase.getWebAuthnAuthenticateOptionsForMFA(this.username, this.mfaDevice.id);
    const accountid = publicKeyOptions.extensions.userHandle;
    publicKeyOptions.challenge = rfc4648.base64url.parse(publicKeyOptions.challenge, {
      loose: true
    });

    for (let allowCredential of publicKeyOptions.allowCredentials) {
      allowCredential.id = rfc4648.base64url.parse(allowCredential.id, {
        loose: true
      });
    }

    try {
      const publicKeyCredential = await navigator.credentials.get({
        publicKey: publicKeyOptions
      }); // NOTE: publicKeyCredential is a browser object which can't be JSON.serilized

      const publicKeyData = {
        id: publicKeyCredential.id,
        type: publicKeyCredential.type,
        rawId: rfc4648.base64url.stringify(new Uint8Array(publicKeyCredential.rawId)),
        response: {
          clientDataJSON: rfc4648.base64url.stringify(new Uint8Array(publicKeyCredential.response.clientDataJSON)),
          authenticatorData: rfc4648.base64url.stringify(new Uint8Array(publicKeyCredential.response.authenticatorData)),
          signature: rfc4648.base64url.stringify(new Uint8Array(publicKeyCredential.response.signature)),
          userHandle: rfc4648.base64url.stringify(Uint8Array.from(accountid, c => c.charCodeAt(0)))
        }
      };
      const unlockMethod = this.unlockMethod || Tine.Tinebase_AreaLock.unlock;
      await unlockMethod(this.areaName, this.mfaDevice.id, JSON.stringify(publicKeyData));
    } catch (e) {
      console.error(e);
      Ext.MessageBox.show({
        icon: Ext.MessageBox.WARNING,
        buttons: Ext.MessageBox.OKCANCEL,
        title: i18n._('Error'),
        msg: i18n._("FIDO2 WebAuthn authentication failed. Try again?"),
        fn: btn => {
          if (btn === 'ok') {
            Ext.MessageBox.hide();
            return this.unlock();
          } else {
            throw new Error('USERABORT');
          }
        }
      });
    }
  }

}

/* harmony default export */ var Providers_WebAuthn = (WebAuthn_WebAuthn);
// CONCATENATED MODULE: ./AreaLocks.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/* global Ext,Tine,i18n,postal */








let providerMap = {
  Tinebase_Model_MFA_TOTPUserConfig: HTOTPAuthenticator,
  Tinebase_Model_MFA_HOTPUserConfig: HTOTPAuthenticator,
  Tinebase_Model_MFA_SmsUserConfig: Providers_Sms,
  Tinebase_Model_MFA_UserPassword: Providers_UserPassword,
  Tinebase_Model_MFA_PinUserConfig: Providers_Pin,
  Tinebase_Model_MFA_TokenUserConfig: Providers_Token,
  Tinebase_Model_MFA_YubicoOTPUserConfig: Providers_YubicoOTP,
  Tinebase_Model_MFA_WebAuthnUserConfig: Providers_WebAuthn
};

class AreaLocks_AreaLocks extends Ext.util.Observable {
  /**
   * @property {Object} areaOptions run time area options
   */

  /**
   * @property {Object} providerInstances areaName: providerInstance
   */

  /**
   * @property {Object} presenceObservers areaName: presenceObserver
   */

  /**
   * @property {Object} timers areaName: timer
   */
  constructor(config) {
    super(config);
    this.dataSafeAreaName = 'Tinebase_datasafe';
    this.LoginAreaName = 'Tinebase_login';
    this.clearClientLockState();
    this.areaOptions = {};
    this.providerInstances = {};
    this.presenceObservers = {};
    this.timers = {};
    this.addEvents(
    /**
     * @event locking
     * Fires when an area is locking async.
     * @param {AreaLocks} this
     * @param {string} areaName
     * @param {Object} lockState the output of {@link #getLockState} function
     */
    'locking',
    /**
     * @event lock
     * Fires when an area got locked.
     * @param {AreaLocks} this
     * @param {string} areaName
     * @param {Object} lockState the output of {@link #getLockState} function
     */
    'lock',
    /**
     * @event unlocking
     * Fires when an area is unlocking async.
     * @param {AreaLocks} this
     * @param {string} areaName
     * @param {Object} lockState the output of {@link #getLockState} function
     */
    'unlocking',
    /**
     * @event unlock
     * Fires when an area got unlocked.
     * @param {AreaLocks} this
     * @param {string} areaName
     * @param {Object} lockState the output of {@link #getLockState} function
     */
    'unlock',
    /**
     * @event stateChange
     * Fires when the state of a lock changes.
     * @param {AreaLocks} this
     * @param {string} areaName
     * @param {Object} lockState the output of {@link #getLockState} function
     */
    'stateChange');
    Object.assign(this, config);
  }

  async getProvider(areaName, optionOverrides) {
    const opts = this.getOptions(areaName, optionOverrides);
    const mfaDevices = opts.mfaDevices || (await Tine.Tinebase_AreaLock.getUsersMFAUserConfigs(areaName));
    let selectedDevice = mfaDevices[0];

    _.each(mfaDevices, mfaDevice => {
      mfaDevice.device_name = mfaDevice.mfa_config_id + (mfaDevice.note ? " (".concat(mfaDevice.note, ")") : '');
    });

    if (mfaDevices.length < 1) {
      throw new Error('NOVALIDMFA');
    }

    if (mfaDevices.length > 1) {
      selectedDevice = _.find(mfaDevices, {
        mfa_config_id: await Tine.widgets.dialog.MultiOptionsDialog.getOption({
          title: window.i18n._('Choose MFA Deivce'),
          questionText: window.i18n._('This area is locked. Which device should be used to unlock.'),
          height: 100 + mfaDevices.length * 30,
          allowCancel: true,
          options: _.map(mfaDevices, mfaDevice => {
            return {
              text: mfaDevice.device_name,
              name: mfaDevice.mfa_config_id
            };
          })
        })
      });
    }

    let providerClass = _.get(providerMap, _.get(selectedDevice, 'config_class'), Providers_Generic);

    const key = "".concat(areaName, ".").concat(providerClass);

    if (!this.providerInstances[key]) {
      // @TODO give areaLock or mfaDevice info or lockState into provider?
      this.providerInstances[key] = new providerClass(_.assign({
        areaName: areaName,
        mfaDevice: selectedDevice
      }, opts));
    }

    return this.providerInstances[key];
  }
  /**
   * get areaLock config
   *
   * config definition: @see Tinebase_Model_AreaLockConfig
   * [{
   *   area_name: string
   *   areas: [],                     // name of area
   *   provider_configs: [],          // array of alternative provider configs
   *   validity: 'once', '            // 'session', 'lifetime', 'presence'
   *   lifetime: seconds,             // absolute lifetime from unlock
   * }]
   *
   * @param {String} areaName
   * @return {Object}
   */


  getConfig(areaName, overrides) {
    const config = Tine.Tinebase.configManager.get('areaLocks', 'Tinebase');

    const areaConfig = _.find(_.get(config, 'records', []), {
      area_name: areaName
    }); // hack to get _user specific_ provider_configs from exception


    if (overrides && areaConfig) {
      _.assign(areaConfig, overrides);

      Tine.Tinebase.configManager.set('areaLocks', config, 'Tinebase');
    }

    return areaConfig;
  }
  /**
   * get areaLock state from registry
   *
   * [{
   *   area: 'string',
   *   expires: datetime (user timezone)
   * }]
   */


  getLockState(areaName) {
    let lockStates = Tine.Tinebase.registry.get('areaLocks');
    return _.find(lockStates, {
      area: areaName
    }) || {
      area: areaName,
      expires: '1970-01-01 01:00:00'
    };
  }
  /**
   * set areaLock state in registry
   *
   * @param {String} areaName
   * @param {Object} lockState
   */


  setLockState(areaName, lockState) {
    const lockStates = Tine.Tinebase.registry.get('areaLocks') || [];

    const oldLockSate = _.find(lockStates, {
      area: areaName
    });

    _.remove(lockStates, {
      area: areaName
    });

    lockStates.push(lockState);
    Tine.Tinebase.registry.set('areaLocks', lockStates);

    if (JSON.stringify(oldLockSate !== JSON.stringify(lockState))) {
      this.fireEvent('stateChange', this, areaName, lockState);
    }
  } // requred when page reload happend while (un)locking


  clearClientLockState() {
    const lockStates = Tine.Tinebase.registry.get('areaLocks') || [];

    _.each(lockStates, lockState => {
      delete lockState.isUnlocking;
      delete lockState.isLocking;
    });

    Tine.Tinebase.registry.set('areaLocks', lockStates);
  }

  async manageMask(areaName) {
    const options = this.getOptions(areaName); // @TODO: support array of maskEls?

    if (options.maskEl) {
      const isLocked = await this.isLocked(areaName);

      if (isLocked) {
        const lockState = this.getLockState(areaName);

        if (lockState.isUnlocking) {
          options.maskEl.mask(i18n._('Unlocking ...'), 'x-mask-loading');
        } else {
          let mask = options.maskEl.mask(i18n._('Click here to unlock this area.'), 'tb-arealocks-msg');
          mask.next().on('click', () => {
            this.unlock(areaName);
          });
        }
      } else {
        options.maskEl.unmask();
      }
    }
  }

  assertTimerRunning(areaName) {
    const conf = this.getConfig(areaName);
    const lockState = this.getLockState(areaName);
    const validity = String(_.get(conf, 'validity', 'session')).toLowerCase();
    let expires = lockState.expires;

    if (validity === 'presence') {
      if (!this.presenceObservers[areaName]) {
        this.presenceObservers[areaName] = new Tine.Tinebase.PresenceObserver({
          maxAbsenceTime: conf.lifetime,
          absenceCallback: _.bind(this.lock, this, areaName),
          presenceCallback: (lastPresenceDate, po) => {
            const lockState = this.getLockState(areaName);
            expires = new Date(lastPresenceDate.getTime() + conf.lifetime * 60000).format(Date.patterns.ISO8601Long);

            if (expires !== lockState.expires) {
              this.setLockState(areaName, _.assign(lockState, {
                expires: expires
              }));
            }
          }
        });
      } else {
        this.presenceObservers[areaName].startChecking();
      }

      expires = new Date(this.presenceObservers[areaName].getLastPresence() + conf.lifetime * 60000).format(Date.patterns.ISO8601Long);
    } else if (validity === 'lifetime') {
      if (!this.timer[areaName]) {
        const timeout = Math.min(Date.parseDate(lockState.expires, Date.patterns.ISO8601Long).getTime() - new Date().getTime(), conf.lifetime * 60000);
        this.timer[areaName] = setTimeout(_.bind(this.lock, this, areaName), timeout);
        expires = new Date(new Date().getTime() + timeout).format(Date.patterns.ISO8601Long);
      }
    }

    if (expires !== lockState.expires) {
      this.setLockState(areaName, _.assign(lockState, {
        expires: expires
      }));
    }
  } // public functions

  /**
   * lock given area
   * @param {String} areaName
   * @return {Promise<*>}
   */


  async lock(areaName) {
    const lockState = this.getLockState(areaName);
    if (lockState.isUnlocking) return;
    this.setLockState(areaName, _.assign(lockState, {
      isLocking: true
    }));
    this.fireEvent('locking', areaName, lockState);

    if (this.presenceObservers[areaName]) {
      this.presenceObservers[areaName].stopChecking();
    }

    if (this.timers[areaName]) {
      clearTimeout(this.timers[areaName]);
      delete this.timers[areaName];
    }

    this.setLockState(areaName, _.assign(lockState, await Tine.Tinebase_AreaLock.lock(areaName), {
      isLocking: false
    }));
    this.manageMask(areaName);
    postal.publish({
      channel: 'areaLocks',
      topic: [areaName, 'locked'].join('.'),
      data: lockState
    }); // auto unlock

    let options = this.getOptions(areaName);

    if (options.maskEl && options.maskEl.isVisible(true)) {
      this.unlock(areaName);
    }

    this.fireEvent('lock', this, areaName, lockState);
    return lockState.expires;
  }

  async unlock(areaName, opts) {
    const lockState = this.getLockState(areaName);
    this.manageMask(areaName);

    if ((await this.isLocked(areaName)) && !lockState.isUnlocking) {
      this.manageMask(areaName);
      this.setLockState(areaName, _.assign(lockState, {
        isUnlocking: true
      }));
      this.fireEvent('unlocking', areaName, lockState);

      try {
        const provider = await this.getProvider(areaName, opts);
        this.setLockState(areaName, _.assign(lockState, await provider.unlock(), {
          isUnlocking: false
        }));
        this.assertTimerRunning(areaName);
        this.manageMask(areaName);
        this.fireEvent('unlocked', areaName, this.getLockState(areaName));
        postal.publish({
          channel: 'areaLocks',
          topic: [areaName, 'unlocked'].join('.'),
          data: lockState
        });
      } catch (e) {
        this.setLockState(areaName, _.assign(lockState, {
          isUnlocking: false
        }));
        this.manageMask(areaName);
        return this.onMFAFail(areaName, e, opts);
      }
    }
  }

  async onMFAFail(areaName, e, opts) {
    return new Promise((resolve, reject) => {
      if (e.message === 'NOVALIDMFA') {
        Ext.MessageBox.show({
          title: window.i18n._('MFA device missing'),
          msg: window.i18n._('No matching MFA device for this area found. Configure a matching device please.'),
          icon: Ext.MessageBox.INFO,
          buttons: Ext.MessageBox.OK
        });
        return resolve();
      }

      if (e.message !== 'USERABORT') {
        Tine.log.error(e);
        Ext.MessageBox.show({
          title: window.i18n._hidden(e.message),
          msg: window.i18n._('Try again?'),
          icon: Ext.MessageBox.WARNING,
          buttons: Ext.MessageBox.YESNO,
          fn: btn => {
            if (btn === 'yes') {
              const retryMethod = _.get(opts, 'retryMethod', _.bind(this.unlock, this));

              return resolve(retryMethod(areaName, opts));
            }

            return this.onMFAFail(areaName, new Error('USERABORT'), opts).then(resolve).catch(e => reject(e));
          }
        });
      } else {
        // Note: we only reject if the USERABORTMethod is set to 'reject' as most userland code can't cope with the rejection
        const userAbortMethod = _.get(opts, 'USERABORTMethod', e => {
          return e;
        });

        if (userAbortMethod === 'reject') {
          return reject(e);
        }

        return resolve(userAbortMethod());
      }
    });
  }

  isLocked(areaName, askServer) {
    const lockState = this.getLockState(areaName);

    if (askServer) {
      return Tine.Tinebase_AreaLock.getState(areaName).then(serverData => {
        this.setLockState(areaName, _.assign(lockState, serverData));
        return this.isLocked(areaName);
      });
    }

    return lockState.expires ? Date.parseDate(lockState.expires, Date.patterns.ISO8601Long).getTime() < new Date().getTime() : true;
  }
  /**
   * returns areaNames of all areaLocks matching given selectors
   * @param {Array} areaSelectors
   * @param {Boolean} lockedOnly
   * @return {Array}
   */


  getLocks(areaSelectors, lockedOnly) {
    areaSelectors = _.isArray(areaSelectors) ? areaSelectors : [areaSelectors];

    const configs = _.get(Tine.Tinebase.configManager.get('areaLocks', 'Tinebase'), 'records', []);

    return _.compact(_.reduce(configs, (locks, conf, idx) => {
      const areaName = _.get(conf, 'area_name');

      const hasIntersection = _.intersection(_.get(conf, 'areas', []), areaSelectors).length;

      return _.concat(locks, hasIntersection && (!lockedOnly || this.isLocked(areaName)) ? areaName : []);
    }, []));
  }

  setOptions(areaName, options) {
    this.areaOptions[areaName] = options;
  }

  getOptions(areaName, overrides) {
    const opts = this.areaOptions[areaName] || {};
    return _.assign(opts, overrides || {}); // return _.assign(overrides || {}, _.pick(opts, _.keys(overrides)));
  }

  handleAreaLockException(exception) {
    const areaName = exception.area;
    const mfaDevices = exception.mfaUserConfigs;
    this.manageMask(areaName);
    return this.unlock(areaName, {
      mfaDevices,
      USERABORTMethod: 'reject'
    });
  }

}



/***/ }),
/* 28 */,
/* 29 */,
/* 30 */,
/* 31 */,
/* 32 */,
/* 33 */,
/* 34 */,
/* 35 */,
/* 36 */,
/* 37 */,
/* 38 */,
/* 39 */,
/* 40 */
/***/ (function(module, exports) {


/**
 * When source maps are enabled, `style-loader` uses a link element with a data-uri to
 * embed the css on the page. This breaks all relative urls because now they are relative to a
 * bundle instead of the current page.
 *
 * One solution is to only use full urls, but that may be impossible.
 *
 * Instead, this function "fixes" the relative urls to be absolute according to the current page location.
 *
 * A rudimentary test suite is located at `test/fixUrls.js` and can be run via the `npm test` command.
 *
 */

module.exports = function (css) {
  // get current location
  var location = typeof window !== "undefined" && window.location;

  if (!location) {
    throw new Error("fixUrls requires window.location");
  }

	// blank or null?
	if (!css || typeof css !== "string") {
	  return css;
  }

  var baseUrl = location.protocol + "//" + location.host;
  var currentDir = baseUrl + location.pathname.replace(/\/[^\/]*$/, "/");

	// convert each url(...)
	/*
	This regular expression is just a way to recursively match brackets within
	a string.

	 /url\s*\(  = Match on the word "url" with any whitespace after it and then a parens
	   (  = Start a capturing group
	     (?:  = Start a non-capturing group
	         [^)(]  = Match anything that isn't a parentheses
	         |  = OR
	         \(  = Match a start parentheses
	             (?:  = Start another non-capturing groups
	                 [^)(]+  = Match anything that isn't a parentheses
	                 |  = OR
	                 \(  = Match a start parentheses
	                     [^)(]*  = Match anything that isn't a parentheses
	                 \)  = Match a end parentheses
	             )  = End Group
              *\) = Match anything and then a close parens
          )  = Close non-capturing group
          *  = Match anything
       )  = Close capturing group
	 \)  = Match a close parens

	 /gi  = Get all matches, not the first.  Be case insensitive.
	 */
	var fixedCss = css.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi, function(fullMatch, origUrl) {
		// strip quotes (if they exist)
		var unquotedOrigUrl = origUrl
			.trim()
			.replace(/^"(.*)"$/, function(o, $1){ return $1; })
			.replace(/^'(.*)'$/, function(o, $1){ return $1; });

		// already a full url? no change
		if (/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(unquotedOrigUrl)) {
		  return fullMatch;
		}

		// convert the url to a full url
		var newUrl;

		if (unquotedOrigUrl.indexOf("//") === 0) {
		  	//TODO: should we add protocol?
			newUrl = unquotedOrigUrl;
		} else if (unquotedOrigUrl.indexOf("/") === 0) {
			// path should be relative to the base url
			newUrl = baseUrl + unquotedOrigUrl; // already starts with '/'
		} else {
			// path should be relative to current directory
			newUrl = currentDir + unquotedOrigUrl.replace(/^\.\//, ""); // Strip leading './'
		}

		// send back the fixed url(...)
		return "url(" + JSON.stringify(newUrl) + ")";
	});

	// send back the fixed css
	return fixedCss;
};


/***/ }),
/* 41 */,
/* 42 */,
/* 43 */,
/* 44 */,
/* 45 */
/***/ (function(module, exports) {

/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */
module.exports = __webpack_amd_options__;

/* WEBPACK VAR INJECTION */}.call(this, {}))

/***/ }),
/* 46 */
/***/ (function(module, exports, __webpack_require__) {

/*!
 *  * postal.federation - A base plugin for federating instances of postal.js across various boundaries.
 *  * Author: Jim Cowart (http://ifandelse.com)
 *  * Version: v0.5.5
 *  * Url: http://github.com/postaljs/postal.federation
 *  * License(s): (MIT OR GPL-2.0)
 */
(function webpackUniversalModuleDefinition(root, factory) {
	if(true)
		module.exports = factory(__webpack_require__(1), __webpack_require__(18));
	else {}
})(this, function(__WEBPACK_EXTERNAL_MODULE_1__, __WEBPACK_EXTERNAL_MODULE_2__) {
return /******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};
/******/
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/
/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId])
/******/ 			return installedModules[moduleId].exports;
/******/
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			exports: {},
/******/ 			id: moduleId,
/******/ 			loaded: false
/******/ 		};
/******/
/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ 		// Flag the module as loaded
/******/ 		module.loaded = true;
/******/
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/
/******/
/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;
/******/
/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;
/******/
/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "";
/******/
/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ function(module, exports, __webpack_require__) {

	Object.defineProperty(exports, "__esModule", {
		value: true
	});
	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	var _lodash = __webpack_require__(1);
	
	var _lodash2 = _interopRequireDefault(_lodash);
	
	var _postal = __webpack_require__(2);
	
	var _postal2 = _interopRequireDefault(_postal);
	
	__webpack_require__(3);
	
	var _packingSlips = __webpack_require__(4);
	
	var _state = __webpack_require__(5);
	
	var _handlers = __webpack_require__(6);
	
	var _filters = __webpack_require__(7);
	
	var _filters2 = _interopRequireDefault(_filters);
	
	var _FederationClient = __webpack_require__(8);
	
	var _FederationClient2 = _interopRequireDefault(_FederationClient);
	
	var fedx = _postal2["default"].fedx = {
		FederationClient: _FederationClient2["default"],
		packingSlips: _packingSlips.packingSlips,
		handlers: _handlers.handlers,
		clients: _state.state._clients,
		transports: _state.state._transports,
		filters: _filters2["default"],
		addFilter: _filters.addFilter,
		removeFilter: _filters.removeFilter,
		canSendRemote: function canSendRemote(channel, topic) {
			return (0, _filters.matchesFilter)(channel, topic, "out");
		},
		configure: _state.configure,
		getPackingSlip: _packingSlips.getPackingSlip,
		onFederatedMsg: _handlers.onFederatedMsg,
		sendMessage: function sendMessage(envelope) {
			if (!_state.state._ready) {
				_state.state._outboundQueue.push(arguments);
				return;
			}
			_lodash2["default"].forEach(this.transports, function (transport) {
				transport.sendMessage(envelope);
			});
		},
		disconnect: _state.disconnect,
		_getTransports: function _getTransports() {
			return _lodash2["default"].reduce(this.transports, function (memo, transport, name) {
				memo[name] = true;
				return memo;
			}, {});
		},
		/*
	 	signalReady( callback );
	 	signalReady( "transportName" );
	 	signalReady( "transportName", callback );
	 	signalReady( "transportName", targetInstance, callback ); <-- this is NEW
	 	signalReady( { transportNameA: targetsForA, transportNameB: targetsForB, transportC: true }, callback);
	 */
		signalReady: function signalReady(transport, target, callback) {
			if (!_state.state._ready) {
				_state.state._signalQueue.push(arguments);
				return;
			}
			var transports = this._getTransports();
			switch (arguments.length) {
				case 1:
					if (typeof transport === "function") {
						callback = transport;
					} else if (typeof transport === "string") {
						transports = {};
						transports[transport] = this.transports[transport];
						callback = _state.NO_OP;
					}
					break;
				case 2:
					if (typeof transport === "string") {
						transports = {};
						transports[transport] = this.transports[transport];
					} else {
						transports = transport;
					}
					callback = target || _state.NO_OP;
					break;
				case 3:
					transports = {};
					transports[transport] = [target];
					break;
			}
			_lodash2["default"].forEach(transports, _lodash2["default"].bind(function (targets, name) {
				targets = typeof targets === "boolean" ? [] : targets;
				this.transports[name].signalReady(targets, callback);
			}, this));
		}
	};
	
	exports["default"] = fedx;
	
	function processSignalQ(args) {
		fedx.signalReady.apply(this, args);
	}
	
	function processOutboundQ(args) {
		fedx.send.apply(this, args);
	}
	
	function processInboundQ(msg) {
		fedx.onFederatedMsg.call(this, msg);
	}
	
	_postal2["default"].addWireTap(function (data, envelope) {
		if (fedx.canSendRemote(envelope.channel, envelope.topic)) {
			fedx.sendMessage(envelope);
		}
	});
	
	_postal2["default"].subscribe({
		channel: _postal2["default"].configuration.SYSTEM_CHANNEL,
		topic: "instanceId.changed",
		callback: function callback() {
			_state.state._ready = true;
			while (_state.state._signalQueue.length) {
				processSignalQ(_state.state._signalQueue.shift());
			}
			while (_state.state._outboundQueue.length) {
				processOutboundQ(_state.state._outboundQueue.shift());
			}
			while (_state.state._inboundQueue.length) {
				processInboundQ(_state.state._inboundQueue.shift());
			}
		}
	});
	
	if (_postal2["default"].instanceId() !== undefined) {
		_state.state._ready = true;
	}
	module.exports = exports["default"];

/***/ },
/* 1 */
/***/ function(module, exports) {

	module.exports = __WEBPACK_EXTERNAL_MODULE_1__;

/***/ },
/* 2 */
/***/ function(module, exports) {

	module.exports = __WEBPACK_EXTERNAL_MODULE_2__;

/***/ },
/* 3 */
/***/ function(module, exports, __webpack_require__) {

	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	var _postal = __webpack_require__(2);
	
	var _postal2 = _interopRequireDefault(_postal);
	
	if (!_postal2["default"].createUUID) {
		_postal2["default"].createUUID = function () {
			var s = [];
			var hexDigits = "0123456789abcdef";
			for (var i = 0; i < 36; i++) {
				s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
			}
			s[14] = "4"; // bits 12-15 of the time_hi_and_version field to 0010
			/* jshint ignore:start */
			s[19] = hexDigits.substr(s[19] & 0x3 | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01
			/* jshint ignore:end */
			s[8] = s[13] = s[18] = s[23] = "-";
			return s.join("");
		};
	}
	if (!_postal2["default"].instanceId) {
		_postal2["default"].instanceId = (function () {
			var _id = undefined,
			    _oldId = undefined;
			return function (id) {
				if (id) {
					_oldId = _id;
					_id = id;
					_postal2["default"].publish({
						channel: _postal2["default"].configuration.SYSTEM_CHANNEL,
						topic: "instanceId.changed",
						data: {
							oldId: _oldId,
							newId: _id
						}
					});
				}
				return _id;
			};
		})();
	}

/***/ },
/* 4 */
/***/ function(module, exports, __webpack_require__) {

	Object.defineProperty(exports, "__esModule", {
		value: true
	});
	exports.getPackingSlip = getPackingSlip;
	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	var _postal = __webpack_require__(2);
	
	var _postal2 = _interopRequireDefault(_postal);
	
	function getPackingSlip(type /*, env */) {
		if (Object.prototype.hasOwnProperty.call(packingSlips, type)) {
			return packingSlips[type].apply(this, Array.prototype.slice.call(arguments, 1));
		}
	}
	
	var packingSlips = {
		ping: function ping() {
			return {
				type: "federation.ping",
				instanceId: _postal2["default"].instanceId(),
				timeStamp: new Date(),
				ticket: _postal2["default"].createUUID()
			};
		},
		pong: function pong(ping) {
			return {
				type: "federation.pong",
				instanceId: _postal2["default"].instanceId(),
				timeStamp: new Date(),
				pingData: {
					instanceId: ping.instanceId,
					timeStamp: ping.timeStamp,
					ticket: ping.ticket
				}
			};
		},
		message: function message(env) {
			return {
				type: "federation.message",
				instanceId: _postal2["default"].instanceId(),
				timeStamp: new Date(),
				envelope: env
			};
		},
		disconnect: function disconnect() {
			return {
				type: "federation.disconnect",
				instanceId: _postal2["default"].instanceId(),
				timeStamp: new Date()
			};
		},
		bundle: function bundle(packingSlips) {
			return {
				type: "federation.bundle",
				instanceId: _postal2["default"].instanceId(),
				timeStamp: new Date(),
				packingSlips: packingSlips
			};
		}
	};
	exports.packingSlips = packingSlips;

/***/ },
/* 5 */
/***/ function(module, exports, __webpack_require__) {

	Object.defineProperty(exports, "__esModule", {
		value: true
	});
	exports.configure = configure;
	exports.disconnect = disconnect;
	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	var _lodash = __webpack_require__(1);
	
	var _lodash2 = _interopRequireDefault(_lodash);
	
	var _defaults = {
		enabled: true,
		filterMode: "whitelist",
		filterDirection: "both"
	};
	
	var NO_OP = function NO_OP() {};
	
	exports.NO_OP = NO_OP;
	var state = {
		_clients: [],
		_transports: {},
		_ready: false,
		_inboundQueue: [],
		_outboundQueue: [],
		_signalQueue: [],
		_config: _defaults
	};
	
	exports.state = state;
	
	function configure(cfg) {
		if (cfg && cfg.filterMode && cfg.filterMode !== "blacklist" && cfg.filterMode !== "whitelist") {
			throw new Error("postal.fedx filterMode must be 'blacklist' or 'whitelist'.");
		}
		if (cfg) {
			state._config = _lodash2["default"].defaults(cfg, _defaults);
		}
		return state._config;
	}
	
	function disconnect(options) {
		options = options || {};
		var trans = state._transports;
		if (options.transport) {
			trans = {};
			trans[options.transport] = state._transports[options.transport];
		}
		_lodash2["default"].forEach(trans, function (t) {
			t.disconnect({
				target: options.target,
				instanceId: options.instanceId,
				doNotNotify: !!options.doNotNotify
			});
		});
	}

/***/ },
/* 6 */
/***/ function(module, exports, __webpack_require__) {

	Object.defineProperty(exports, "__esModule", {
		value: true
	});
	exports.onFederatedMsg = onFederatedMsg;
	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	var _packingSlips = __webpack_require__(4);
	
	var _state = __webpack_require__(5);
	
	var _filters = __webpack_require__(7);
	
	var _postal = __webpack_require__(2);
	
	var _postal2 = _interopRequireDefault(_postal);
	
	var _lodash = __webpack_require__(1);
	
	var _lodash2 = _interopRequireDefault(_lodash);
	
	var handlers = {
		"federation.ping": function federationPing(data /*, callback */) {
			data.source.setInstanceId(data.packingSlip.instanceId);
			if (data.source.handshakeComplete) {
				data.source.sendPong(data.packingSlip);
			} else {
				data.source.sendBundle([(0, _packingSlips.getPackingSlip)("pong", data.packingSlip), (0, _packingSlips.getPackingSlip)("ping")]);
			}
		},
		"federation.pong": function federationPong(data) {
			data.source.handshakeComplete = true;
			data.source.setInstanceId(data.packingSlip.instanceId);
			if (data.source.pings[data.packingSlip.pingData.ticket]) {
				data.source.pings[data.packingSlip.pingData.ticket].callback({
					ticket: data.packingSlip.pingData.ticket,
					instanceId: data.packingSlip.instanceId,
					source: data.source
				});
				data.source.pings[data.packingSlip.pingData.ticket] = undefined;
			}
			if (!_lodash2["default"].includes(_state.state._clients, data.packingSlip.instanceId)) {
				_state.state._clients.push(data.packingSlip.instanceId);
			}
			_postal2["default"].publish({
				channel: "postal.federation",
				topic: "client.federated",
				data: {
					remoteId: data.source.instanceId,
					localId: _postal2["default"].instanceId(),
					transport: data.transport
				}
			});
		},
		"federation.disconnect": function federationDisconnect(data) {
			_state.state._clients = _lodash2["default"].without(_state.state._clients, data.source.instanceId);
			(0, _state.disconnect)({
				transport: data.source.transportName,
				instanceId: data.source.instanceId,
				doNotNotify: true
			});
		},
		"federation.message": function federationMessage(data) {
			var env = data.packingSlip.envelope;
			if ((0, _filters.matchesFilter)(env.channel, env.topic, "in")) {
				env.lastSender = data.packingSlip.instanceId;
				_postal2["default"].publish(env);
			}
		},
		"federation.bundle": function federationBundle(data) {
			_lodash2["default"].forEach(data.packingSlip.packingSlips, function (slip) {
				onFederatedMsg(_lodash2["default"].extend({}, data, {
					packingSlip: slip
				}));
			});
		}
	};
	
	exports.handlers = handlers;
	
	function onFederatedMsg(data) {
		if (!_state.state._ready) {
			_state.state._inboundQueue.push(data);
			return;
		}
		if (Object.prototype.hasOwnProperty.call(handlers, data.packingSlip.type)) {
			handlers[data.packingSlip.type](data);
		} else {
			throw new Error("postal.federation does not have a message handler for '" + data.packingSlip.type + "'.");
		}
	}

/***/ },
/* 7 */
/***/ function(module, exports, __webpack_require__) {

	Object.defineProperty(exports, "__esModule", {
		value: true
	});
	exports.addFilter = addFilter;
	exports.removeFilter = removeFilter;
	exports.matchesFilter = matchesFilter;
	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	var _lodash = __webpack_require__(1);
	
	var _lodash2 = _interopRequireDefault(_lodash);
	
	var _state = __webpack_require__(5);
	
	var _postal = __webpack_require__(2);
	
	var _postal2 = _interopRequireDefault(_postal);
	
	var filters = {
		"in": {}, // jscs:ignore disallowQuotedKeysInObjects
		out: {}
	};
	
	exports["default"] = filters;
	
	function addFilter(_filters) {
		_filters = _lodash2["default"].isArray(_filters) ? _filters : [_filters];
		_lodash2["default"].forEach(_filters, function (filter) {
			filter.direction = filter.direction || _state.state._config.filterDirection;
			_lodash2["default"].forEach(filter.direction === "both" ? ["in", "out"] : [filter.direction], function (dir) {
				if (!filters[dir][filter.channel]) {
					filters[dir][filter.channel] = [filter.topic];
				} else if (!_lodash2["default"].includes(filters[dir][filter.channel], filter.topic)) {
					filters[dir][filter.channel].push(filter.topic);
				}
			});
		});
	}
	
	function removeFilter(_filters) {
		_filters = _lodash2["default"].isArray(_filters) ? _filters : [_filters];
		_lodash2["default"].forEach(_filters, function (filter) {
			filter.direction = filter.direction || _state.state._config.filterDirection;
			_lodash2["default"].forEach(filter.direction === "both" ? ["in", "out"] : [filter.direction], function (dir) {
				if (filters[dir][filter.channel] && _lodash2["default"].includes(filters[dir][filter.channel], filter.topic)) {
					filters[dir][filter.channel] = _lodash2["default"].without(filters[dir][filter.channel], filter.topic);
				}
			});
		});
	}
	
	function matchesFilter(channel, topic, direction) {
		var channelPresent = Object.prototype.hasOwnProperty.call(filters[direction], channel);
		var topicMatch = channelPresent && _lodash2["default"].some(filters[direction][channel], function (binding) {
			return _postal2["default"].configuration.resolver.compare(binding, topic);
		});
		var blacklisting = _state.state._config.filterMode === "blacklist";
		return _state.state._config.enabled && (blacklisting && (!channelPresent || channelPresent && !topicMatch) || !blacklisting && channelPresent && topicMatch);
	}

/***/ },
/* 8 */
/***/ function(module, exports, __webpack_require__) {

	Object.defineProperty(exports, "__esModule", {
		value: true
	});
	// istanbul ignore next
	
	var _createClass = (function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; })();
	
	// istanbul ignore next
	
	function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
	
	// istanbul ignore next
	
	function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
	
	var _packingSlips = __webpack_require__(4);
	
	var _handlers = __webpack_require__(6);
	
	var _state = __webpack_require__(5);
	
	var _postal = __webpack_require__(2);
	
	var _postal2 = _interopRequireDefault(_postal);
	
	var _lodash = __webpack_require__(1);
	
	var _lodash2 = _interopRequireDefault(_lodash);
	
	var FederationClient = (function () {
		function FederationClient(target, options, instanceId) {
			_classCallCheck(this, FederationClient);
	
			this.target = target;
			this.options = options || {};
			this.pings = {};
			this.instanceId = instanceId;
			this.handshakeComplete = false;
		}
	
		_createClass(FederationClient, [{
			key: "sendPing",
			value: function sendPing(callback) {
				var packingSlip = (0, _packingSlips.getPackingSlip)("ping");
				this.pings[packingSlip.ticket] = {
					ticket: packingSlip.ticket,
					callback: callback || _state.NO_OP
				};
				this.send(packingSlip);
			}
		}, {
			key: "sendPong",
			value: function sendPong(origPackingSlip) {
				this.send((0, _packingSlips.getPackingSlip)("pong", origPackingSlip));
			}
		}, {
			key: "sendBundle",
			value: function sendBundle(slips) {
				this.send((0, _packingSlips.getPackingSlip)("bundle", slips));
			}
		}, {
			key: "sendMessage",
			value: function sendMessage(envelope) {
				if (!this.handshakeComplete) {
					return;
				}
				envelope.originId = envelope.originId || _postal2["default"].instanceId();
				var env = _lodash2["default"].clone(envelope);
				if (this.instanceId && this.instanceId !== env.lastSender && (!env.knownIds || !env.knownIds.length || env.knownIds && !_lodash2["default"].includes(env.knownIds, this.instanceId))) {
					env.knownIds = (env.knownIds || []).concat(_lodash2["default"].without(_state.state._clients, this.instanceId));
					this.send((0, _packingSlips.getPackingSlip)("message", env));
				}
			}
		}, {
			key: "disconnect",
			value: function disconnect() {
				this.send((0, _packingSlips.getPackingSlip)("disconnect"));
			}
		}, {
			key: "onMessage",
			value: function onMessage(packingSlip) {
				if (this.shouldProcess()) {
					(0, _handlers.onFederatedMsg)({
						transport: this.transportName,
						packingSlip: packingSlip,
						source: this
					});
				}
			}
		}, {
			key: "shouldProcess",
			value: function shouldProcess() {
				return true;
			}
		}, {
			key: "send",
			value: function send() /* msg */{
				throw new Error("An object deriving from FederationClient must provide an implementation for 'send'.");
			}
		}, {
			key: "setInstanceId",
			value: function setInstanceId(id) {
				this.instanceId = id;
			}
		}], [{
			key: "extend",
			value: function extend(props, ctrProps) {
				function FedXClient() {
					FederationClient.apply(this, arguments);
				}
	
				FedXClient.prototype = Object.create(FederationClient.prototype);
				_lodash2["default"].extend(FedXClient.prototype, props);
				_lodash2["default"].extend(FedXClient, ctrProps);
	
				return FedXClient;
			}
		}]);
	
		return FederationClient;
	})();
	
	exports["default"] = FederationClient;
	module.exports = exports["default"];

/***/ }
/******/ ])
});
;

/***/ }),
/* 47 */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/**
 * postal.request-response - postal.js add-on that provides a request/response pattern API.
 * Author: Jim Cowart (http://ifandelse.com)
 * Version: v0.3.1
 * Url: https://github.com/postaljs/postal.request-response
 * License(s): MIT
 */
(function (root, factory) { /* istanbul ignore if  */
    if (true) {
        // AMD. Register as an anonymous module.
        !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(1), __webpack_require__(18)], __WEBPACK_AMD_DEFINE_RESULT__ = (function (_, postal) {
            return factory(_, postal, root);
        }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__)); /* istanbul ignore else */
    } else {}
}(this, function (_, postal, global, undefined) {
    var REQ_RES_CHANNEL = "postal.request-response";
    // I want this lib to be compatible with nearly any
    // promises-A-spec-compliant promise lib. For that
    // to happen, though, you have to provide a factory
    // method implementation that returns a promise
    postal.configuration.promise = {
        createDeferred: function () {
            throw new Error("You need to provide an implementation for postal.configuration.promise.createDeferred that returns a deferred/promise instance.");
        },
        getPromise: function () {
            throw new Error("You need to provide an implementation for postal.configuration.promise.getPromise that returns a promise safe for consuming APIs to use.");
        },
        fulfill: "resolve",
        fail: "reject",
    };
    /**
     * Fast UUID generator, RFC4122 version 4 compliant.
     * @author Jeff Ward (jcward.com).
     * @license MIT license
     * @link http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript/21963136#21963136
     **/
    var UUID = (function () {
        var self = {};
        var lut = [];
        for (var i = 0; i < 256; i++) {
            lut[i] = (i < 16 ? "0" : "") + (i).toString(16);
        }
        self.create = function () {
            var d0 = Math.random() * 0xffffffff | 0;
            var d1 = Math.random() * 0xffffffff | 0;
            var d2 = Math.random() * 0xffffffff | 0;
            var d3 = Math.random() * 0xffffffff | 0;
            return lut[d0 & 0xff] + lut[d0 >> 8 & 0xff] + lut[d0 >> 16 & 0xff] + lut[d0 >> 24 & 0xff] + "-" + lut[d1 & 0xff] + lut[d1 >> 8 & 0xff] + "-" + lut[d1 >> 16 & 0x0f | 0x40] + lut[d1 >> 24 & 0xff] + "-" + lut[d2 & 0x3f | 0x80] + lut[d2 >> 8 & 0xff] + "-" + lut[d2 >> 16 & 0xff] + lut[d2 >> 24 & 0xff] + lut[d3 & 0xff] + lut[d3 >> 8 & 0xff] + lut[d3 >> 16 & 0xff] + lut[d3 >> 24 & 0xff];
        };
        return self;
    })();
    postal.ChannelDefinition.prototype.request = function (options) {
        var env = options.envelope ? options.envelope : {
            topic: options.topic,
            data: options.data,
            headers: options.headers
        };
        var requestId = UUID.create();
        var replyTopic = options.replyTopic || requestId;
        var replyChannel = options.replyChannel || REQ_RES_CHANNEL;
        var timeout;
        var promise = postal.configuration.promise.createDeferred();
        env.headers = env.headers || {};
        env.headers.replyable = true;
        env.headers.requestId = requestId;
        env.headers.replyTopic = replyTopic;
        env.headers.replyChannel = replyChannel;
        var sub = postal.subscribe({
            channel: replyChannel,
            topic: replyTopic,
            callback: function (data, env) {
                if (env.headers && env.headers.isError) {
                    promise[postal.configuration.promise.fail](data);
                } else {
                    promise[postal.configuration.promise.fulfill](data);
                }
            }
        }).once();
        if (options.timeout) {
            timeout = setTimeout(function () {
                promise[postal.configuration.promise.fail](new Error("Timeout limit exceeded for request."));
            }, options.timeout);
        }
        this.publish(env);
        return postal.configuration.promise.getPromise(promise);
    };
    var oldPub = postal.publish;
    postal.publish = function (envelope) {
        if (envelope.headers && envelope.headers.replyable) {
            envelope.reply = function (err, data) {
                postal.publish({
                    channel: envelope.headers.replyChannel,
                    topic: envelope.headers.replyTopic,
                    headers: {
                        isReply: true,
                        isError: !! err,
                        requestId: envelope.headers.requestId,
                        resolverNoCache: true
                    },
                    data: err || data
                });
            };
        }
        oldPub.call(this, envelope);
    };
    return postal;
}));

/***/ }),
/* 48 */
/***/ (function(module, exports, __webpack_require__) {

/*!
 *  * postal.xwindow - postal.js/postal.federation plugin for federating instances of postal.js across unrelated window boundaries.
 *  * Author: Cornelius Weiß (http://www.metaways.de)
 *  * Version: v0.0.8
 *  * Url: http://github.com/tine20/postal.xwindow
 *  * License(s): (MIT OR GPL-2.0)
 */
(function webpackUniversalModuleDefinition(root, factory) {
	if(true)
		module.exports = factory(__webpack_require__(1), __webpack_require__(18));
	else {}
})(this, function(__WEBPACK_EXTERNAL_MODULE_1__, __WEBPACK_EXTERNAL_MODULE_2__) {
return /******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};
/******/
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/
/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId])
/******/ 			return installedModules[moduleId].exports;
/******/
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			exports: {},
/******/ 			id: moduleId,
/******/ 			loaded: false
/******/ 		};
/******/
/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ 		// Flag the module as loaded
/******/ 		module.loaded = true;
/******/
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/
/******/
/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;
/******/
/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;
/******/
/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "";
/******/
/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, exports, __webpack_require__) {

	var _ = __webpack_require__( 1 );
	var postal = __webpack_require__( 2 );
	var utils = __webpack_require__( 3 );
	var S = __webpack_require__( 4 );
	var state = S.state;
	var env = S.env;
	__webpack_require__( 5 );
	__webpack_require__( 8 );
	var XWindowClient = __webpack_require__( 10 );
	
	XWindowClient.getInstance = function( target, options, instanceId ) {
		return new XWindowClient( target, options, instanceId );
	};
	
	postal.fedx.transports.xwindow = {
		eagerSerialize: env.useEagerSerialize,
		remotes: [],
		XWindowClient: XWindowClient,
		configure: function( cfg ) {
			if ( cfg ) {
				state.config = _.defaults( _.extend( state.config, cfg ), state.defaults );
			}
			return state.config;
		},
		clearConfiguration: function() {
			state.config = _.extend( {}, state.defaults );
		},
		disconnect: function( options ) {
			options = options || {};
			var clients = options.instanceId ?
			// an instanceId value or array was provided, let's get the client proxy instances for the id(s)
			_.reduce( _.isArray( options.instanceId ) ? options.instanceId : [ options.instanceId ], _.bind( utils._memoRemoteByInstanceId, this ), [] ) :
			// Ok so we don't have instanceId(s), let's try target(s)
			options.target ?
			// Ok, so we have a targets array, we need to iterate over it and get a list of the proxy/client instances
			_.reduce( _.isArray( options.target ) ? options.target : [ options.target ], _.bind( utils._memoRemoteByTarget, this ), [] ) :
			// aww, heck - we don't have instanceId(s) or target(s), so it's ALL THE REMOTES
			this.remotes;
			if ( !options.doNotNotify ) {
				_.forEach( clients, _.bind( utils._disconnectClient, this ) );
			}
			this.remotes = _.without.apply( null, [ this.remotes ].concat( clients ) );
		},
		getTargets: function() {
			return this.tidyStorage();
		},
		sendMessage: function( env ) {
			var envelope = env;
			if ( state.config.safeSerialize ) {
				envelope = utils.safeSerialize( _.cloneDeep( env ) );
			}
			var instanceId = postal.instanceId();
	
			_.forEach( this.remotes, function( remote ) {
				if ( remote.instanceId != instanceId ) {
					remote.sendMessage( envelope );
				}
			} );
		},
		wrapForTransport: env.useEagerSerialize ? function( packingSlip ) {
			return JSON.stringify( {
				postal: true,
				packingSlip: packingSlip
			} );
		} : function( packingSlip ) {
			return {
				postal: true,
				packingSlip: packingSlip
			};
		},
		unwrapFromTransport: function( msgData ) {
			if ( typeof msgData === "string" && ( env.useEagerSerialize || msgData.indexOf( '"postal":true' ) !== -1 ) ) {
				try {
					return JSON.parse( msgData );
				} catch ( ex ) {
					return {};
				}
			} else {
				return msgData;
			}
		},
		routeMessage: function( event ) {
			var parsed = this.unwrapFromTransport( event.newValue );
	
			if ( parsed && parsed.postal ) {
				var packingSlip = parsed.packingSlip;
				var instanceId = packingSlip.instanceId;
				if ( packingSlip && instanceId != postal.instanceId() ) {
					var remote = _.find( this.remotes, function( x ) {
						return x.instanceId === instanceId;
					} );
					if ( !remote ) {
						var target = store.namespace( state.config.localStoragePrefix + "." + instanceId );
						remote = XWindowClient.getInstance( target, { origin: target.get( "targetUrl" ) }, instanceId );
						this.remotes.push( remote );
					}
	
					// origin forgery protection
					var url = utils.parseUri( event.url );
					var origin = url.protocol + "://" + url.authority;
	
					if ( remote.options.origin == origin ) {
						remote.onMessage( packingSlip );
					}
				}
			}
		},
		signalReady: function( targets, callback ) {
			var instanceId = postal.instanceId();
			var that = this;
	
			this.target = store.namespace( state.config.localStoragePrefix + "." + instanceId );
			this.target.on( "message", _.bind( this.routeMessage, this ) );
			this.keepAlive();
	
			targets = _.isArray( targets ) ? targets : [ targets ];
			targets = targets.length ? targets : this.getTargets();
			callback = callback || function() {};
	
			_.forEach( targets, _.bind( function( def ) {
				if ( def.targetId != instanceId ) {
					var remote = _.find( that.remotes, function( x ) {
						return x.instanceId === def.targetId;
					} );
					if ( !remote ) {
						remote = XWindowClient.getInstance( def.target, { origin: def.origin }, def.targetId );
						that.remotes.push( remote );
					}
					remote.sendPing( callback );
				}
			}, this ) );
		},
		keepAlive: function() {
			this.target.set( "targetUrl", env.origin );
			this.target.set( "targetTimeout", new Date().getTime() + state.config.targetTimeout );
	
			this.tidyStorage();
			this.tidyRemotes();
	
			_.delay( _.bind( this.keepAlive, this ), Math.round( state.config.targetTimeout / 2 ) );
		},
		tidyStorage: function() {
			var targetIds = _.reduce( store.namespace( state.config.localStoragePrefix ).getAll(), function( memo, targetData, id ) {
				var targetId = id.split( "." )[0];
				if ( _.indexOf( memo, targetId ) < 0 ) {
					memo.push( targetId );
				}
				return memo;
			}, [] );
	
			var now = new Date().getTime();
			return _.reduce( targetIds, function( memo, targetId ) {
				var target = store.namespace( state.config.localStoragePrefix + "." + targetId );
				if ( target.get( "targetTimeout" ) < now ) {
					target.clear();
				} else {
					memo.push( {
						targetId: targetId,
						target: target,
						origin: target.get( "targetUrl" )
					} );
				}
				return memo;
			}, [] );
		},
		tidyRemotes: function() {
			var that = this;
			_.forEach( this.remotes, function( remote ) {
				if ( _.isEmpty( remote.target.getAll() ) ) {
					that.disconnect( { target: remote.target } );
				}
			} );
		}
	};


/***/ }),
/* 1 */
/***/ (function(module, exports) {

	module.exports = __WEBPACK_EXTERNAL_MODULE_1__;

/***/ }),
/* 2 */
/***/ (function(module, exports) {

	module.exports = __WEBPACK_EXTERNAL_MODULE_2__;

/***/ }),
/* 3 */
/***/ (function(module, exports, __webpack_require__) {

	var _ = __webpack_require__( 1 );
	
	var _memoRemoteByInstanceId = function( memo, instanceId ) {
		var proxy = _.find( this.remotes, function( x ) {
			return x.instanceId === instanceId;
		} );
		if ( proxy ) {
			memo.push( proxy );
		}
		return memo;
	};
	
	var _memoRemoteByTarget = function( memo, tgt ) {
		var proxy = _.find( this.remotes, function( x ) {
			return x.target === tgt;
		} );
		if ( proxy ) {
			memo.push( proxy );
		}
		return memo;
	};
	
	var _disconnectClient = function( client ) {
		client.disconnect();
	};
	
	safeSerialize = function safeSerialize( envelope ) {
		var json = JSON.parse( JSON.stringify( envelope, function( key, value ) {
			if ( typeof value === "function" ) {
				return undefined;
			}
			return value;
		} ) );
	
		return json;
	};
	
	// parseUri 1.2.2
	// (c) Steven Levithan <stevenlevithan.com>
	// MIT License
	
	var parseUri = function( str ) {
		var o = parseUri.options;
		var m = o.parser[o.strictMode ? "strict" : "loose"].exec( str );
		var uri = {};
		var i = 14;
	
		while ( i-- ) {
			uri[o.key[i]] = m[i] || "";
		}
	
		uri[o.q.name] = {};
		uri[o.key[12]].replace( o.q.parser, function( $0, $1, $2 ) {
			if ( $1 ) {
				uri[o.q.name][$1] = $2;
			}
		} );
	
		return uri;
	};
	
	parseUri.options = {
		strictMode: false,
		key: [ "source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor" ],
		q: {
			name: "queryKey",
			parser: /(?:^|&)([^&=]*)=?([^&]*)/g
		},
		parser: {
			strict: /^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,
			loose: /^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/
		}
	};
	
	module.exports = {
		_memoRemoteByInstanceId: _memoRemoteByInstanceId,
		_memoRemoteByTarget: _memoRemoteByTarget,
		_disconnectClient: _disconnectClient,
		safeSerialize: safeSerialize,
		parseUri: parseUri
	};


/***/ }),
/* 4 */
/***/ (function(module, exports, __webpack_require__) {

	var _ = __webpack_require__( 1 );
	
	var env = {
		origin: location.origin || location.protocol + "//" + location.host,
		isWorker: ( typeof window === "undefined" ) && postMessage && location,
		// I know, I KNOW. The alternative was very expensive perf & time-wise
		// so I saved you a perf hit by checking the stinking UA. Sigh.
		// I sought the opinion of several other devs. We all traveled
		// to the far east to consult with the wisdom of a monk - turns
		// out he didn"t know JavaScript, and our passports were stolen on the
		// return trip. We stowed away aboard a freighter headed back to the
		// US and by the time we got back, no one had heard of IE 8 or 9. True story.
		useEagerSerialize: /MSIE [8,9]/.test( navigator.userAgent )
	};
	
	var defaults = {
		allowedOrigins: [ env.origin ],
		enabled: true,
		safeSerialize: false,
		localStoragePrefix: "postal.fedx.xwindow",
		targetTimeout: 60000 // 1 minute
	};
	
	var state = {
		workers: [],
		config: _.extend( {}, defaults ),
		defaults: defaults
	};
	
	module.exports = {
		state: state,
		env: env
	};


/***/ }),
/* 5 */
/***/ (function(module, exports, __webpack_require__) {

	__webpack_require__(6)(__webpack_require__(7))

/***/ }),
/* 6 */
/***/ (function(module, exports) {

	/*
		MIT License http://www.opensource.org/licenses/mit-license.php
		Author Tobias Koppers @sokra
	*/
	module.exports = function(src) {
		function log(error) {
			(typeof console !== "undefined")
			&& (console.error || console.log)("[Script Loader]", error);
		}
	
		// Check for IE =< 8
		function isIE() {
			return typeof attachEvent !== "undefined" && typeof addEventListener === "undefined";
		}
	
		try {
			if (typeof execScript !== "undefined" && isIE()) {
				execScript(src);
			} else if (typeof eval !== "undefined") {
				eval.call(null, src);
			} else {
				log("EvalError: No eval function available");
			}
		} catch (error) {
			log(error);
		}
	}


/***/ }),
/* 7 */
/***/ (function(module, exports) {

	module.exports = "/*! store2 - v2.5.11 - 2018-01-18\n* Copyright (c) 2018 Nathan Bubna; Licensed (MIT OR GPL-3.0) */\n;(function(window, define) {\n    var _ = {\n        version: \"2.5.11\",\n        areas: {},\n        apis: {},\n\n        // utilities\n        inherit: function(api, o) {\n            for (var p in api) {\n                if (!o.hasOwnProperty(p)) {\n                    o[p] = api[p];\n                }\n            }\n            return o;\n        },\n        stringify: function(d) {\n            return d === undefined || typeof d === \"function\" ? d+'' : JSON.stringify(d);\n        },\n        parse: function(s) {\n            // if it doesn't parse, return as is\n            try{ return JSON.parse(s); }catch(e){ return s; }\n        },\n\n        // extension hooks\n        fn: function(name, fn) {\n            _.storeAPI[name] = fn;\n            for (var api in _.apis) {\n                _.apis[api][name] = fn;\n            }\n        },\n        get: function(area, key){ return area.getItem(key); },\n        set: function(area, key, string){ area.setItem(key, string); },\n        remove: function(area, key){ area.removeItem(key); },\n        key: function(area, i){ return area.key(i); },\n        length: function(area){ return area.length; },\n        clear: function(area){ area.clear(); },\n\n        // core functions\n        Store: function(id, area, namespace) {\n            var store = _.inherit(_.storeAPI, function(key, data, overwrite) {\n                if (arguments.length === 0){ return store.getAll(); }\n                if (typeof data === \"function\"){ return store.transact(key, data, overwrite); }// fn=data, alt=overwrite\n                if (data !== undefined){ return store.set(key, data, overwrite); }\n                if (typeof key === \"string\" || typeof key === \"number\"){ return store.get(key); }\n                if (!key){ return store.clear(); }\n                return store.setAll(key, data);// overwrite=data, data=key\n            });\n            store._id = id;\n            try {\n                var testKey = '_safariPrivate_';\n                area.setItem(testKey, 'sucks');\n                store._area = area;\n                area.removeItem(testKey);\n            } catch (e) {}\n            if (!store._area) {\n                store._area = _.inherit(_.storageAPI, { items: {}, name: 'fake' });\n            }\n            store._ns = namespace || '';\n            if (!_.areas[id]) {\n                _.areas[id] = store._area;\n            }\n            if (!_.apis[store._ns+store._id]) {\n                _.apis[store._ns+store._id] = store;\n            }\n            return store;\n        },\n        storeAPI: {\n            // admin functions\n            area: function(id, area) {\n                var store = this[id];\n                if (!store || !store.area) {\n                    store = _.Store(id, area, this._ns);//new area-specific api in this namespace\n                    if (!this[id]){ this[id] = store; }\n                }\n                return store;\n            },\n            namespace: function(namespace, noSession) {\n                if (!namespace){\n                    return this._ns ? this._ns.substring(0,this._ns.length-1) : '';\n                }\n                var ns = namespace, store = this[ns];\n                if (!store || !store.namespace) {\n                    store = _.Store(this._id, this._area, this._ns+ns+'.');//new namespaced api\n                    if (!this[ns]){ this[ns] = store; }\n                    if (!noSession){ store.area('session', _.areas.session); }\n                }\n                return store;\n            },\n            isFake: function(){ return this._area.name === 'fake'; },\n            toString: function() {\n                return 'store'+(this._ns?'.'+this.namespace():'')+'['+this._id+']';\n            },\n\n            // storage functions\n            has: function(key) {\n                if (this._area.has) {\n                    return this._area.has(this._in(key));//extension hook\n                }\n                return !!(this._in(key) in this._area);\n            },\n            size: function(){ return this.keys().length; },\n            each: function(fn, _and) {// _and is purely for internal use (see keys())\n                for (var i=0, m=_.length(this._area); i<m; i++) {\n                    var key = this._out(_.key(this._area, i));\n                    if (key !== undefined) {\n                        if (fn.call(this, key, _and || this.get(key)) === false) {\n                            break;\n                        }\n                    }\n                    if (m > _.length(this._area)) { m--; i--; }// in case of removeItem\n                }\n                return _and || this;\n            },\n            keys: function() {\n                return this.each(function(k, list){ list.push(k); }, []);\n            },\n            get: function(key, alt) {\n                var s = _.get(this._area, this._in(key));\n                return s !== null ? _.parse(s) : alt || s;// support alt for easy default mgmt\n            },\n            getAll: function() {\n                return this.each(function(k, all){ all[k] = this.get(k); }, {});\n            },\n            transact: function(key, fn, alt) {\n                var val = this.get(key, alt),\n                    ret = fn(val);\n                this.set(key, ret === undefined ? val : ret);\n                return this;\n            },\n            set: function(key, data, overwrite) {\n                var d = this.get(key);\n                if (d != null && overwrite === false) {\n                    return data;\n                }\n                return _.set(this._area, this._in(key), _.stringify(data), overwrite) || d;\n            },\n            setAll: function(data, overwrite) {\n                var changed, val;\n                for (var key in data) {\n                    val = data[key];\n                    if (this.set(key, val, overwrite) !== val) {\n                        changed = true;\n                    }\n                }\n                return changed;\n            },\n            remove: function(key) {\n                var d = this.get(key);\n                _.remove(this._area, this._in(key));\n                return d;\n            },\n            clear: function() {\n                if (!this._ns) {\n                    _.clear(this._area);\n                } else {\n                    this.each(function(k){ _.remove(this._area, this._in(k)); }, 1);\n                }\n                return this;\n            },\n            clearAll: function() {\n                var area = this._area;\n                for (var id in _.areas) {\n                    if (_.areas.hasOwnProperty(id)) {\n                        this._area = _.areas[id];\n                        this.clear();\n                    }\n                }\n                this._area = area;\n                return this;\n            },\n\n            // internal use functions\n            _in: function(k) {\n                if (typeof k !== \"string\"){ k = _.stringify(k); }\n                return this._ns ? this._ns + k : k;\n            },\n            _out: function(k) {\n                return this._ns ?\n                    k && k.indexOf(this._ns) === 0 ?\n                        k.substring(this._ns.length) :\n                        undefined : // so each() knows to skip it\n                    k;\n            }\n        },// end _.storeAPI\n        storageAPI: {\n            length: 0,\n            has: function(k){ return this.items.hasOwnProperty(k); },\n            key: function(i) {\n                var c = 0;\n                for (var k in this.items){\n                    if (this.has(k) && i === c++) {\n                        return k;\n                    }\n                }\n            },\n            setItem: function(k, v) {\n                if (!this.has(k)) {\n                    this.length++;\n                }\n                this.items[k] = v;\n            },\n            removeItem: function(k) {\n                if (this.has(k)) {\n                    delete this.items[k];\n                    this.length--;\n                }\n            },\n            getItem: function(k){ return this.has(k) ? this.items[k] : null; },\n            clear: function(){ for (var k in this.items){ this.removeItem(k); } },\n            toString: function(){ return this.length+' items in '+this.name+'Storage'; }\n        }// end _.storageAPI\n    };\n\n    var store =\n        // safely set this up (throws error in IE10/32bit mode for local files)\n        _.Store(\"local\", (function(){try{ return localStorage; }catch(e){}})());\n    store.local = store;// for completeness\n    store._ = _;// for extenders and debuggers...\n    // safely setup store.session (throws exception in FF for file:/// urls)\n    store.area(\"session\", (function(){try{ return sessionStorage; }catch(e){}})());\n\n    if (typeof define === 'function' && define.amd !== undefined) {\n        define('store2', [], function () {\n            return store;\n        });\n    } else if (typeof module !== 'undefined' && module.exports) {\n        module.exports = store;\n    } else {\n        // expose the primary store fn to the global object and save conflicts\n        if (window.store){ _.conflict = window.store; }\n        window.store = store;\n    }\n\n})(this, this.define);\n"

/***/ }),
/* 8 */
/***/ (function(module, exports, __webpack_require__) {

	__webpack_require__(6)(__webpack_require__(9))

/***/ }),
/* 9 */
/***/ (function(module, exports) {

	module.exports = "/**\n * Copyright (c) 2013 ESHA Research\n * Dual licensed under the MIT and GPL licenses:\n *   http://www.opensource.org/licenses/mit-license.php\n *   http://www.gnu.org/licenses/gpl.html\n *\n * Makes it easy to watch for storage events by enhancing the events and\n * allowing binding to particular keys and/or namespaces.\n *\n * // listen to particular key storage events (yes, this is namespace sensitive)\n * store.on('foo', function listenToFoo(e){ console.log('foo was changed:', e); });\n * store.off('foo', listenToFoo);\n *\n * // listen to all storage events\n * store.on(function storageEvent(e){ console.log('web storage:', e); });\n * store.off(storageEvent);\n * \n * Status: ALPHA - useful, if you don't mind incomplete browser support for events\n */\n;(function(window, document, _) {\n    _.fn('on', function(key, fn) {\n        if (!fn) { fn = key; key = ''; }// shift args when needed\n        var s = this,\n            bound,\n            id = _.id(this._area);\n        if (window.addEventListener) {\n            window.addEventListener(\"storage\", bound = function(e) {\n                var k = s._out(e.key);\n                if (k && (!key || k === key)) {// must match key if listener has one\n                    var eid = _.id(e.storageArea);\n                    if (!eid || id === eid) {// must match area, if event has a known one\n                        return fn.call(s, _.event(k, s, e));\n                    }\n                }\n            }, false);\n        } else {\n            document.attachEvent(\"onstorage\", bound = function() {\n                return fn.call(s, window.event);\n            });\n        }\n        fn['_'+key+'listener'] = bound;\n        return s;\n    });\n    _.fn('off', function(key, fn) {\n        if (!fn) { fn = key; key = ''; }// shift args when needed\n        var bound = fn['_'+key+'listener'];\n        if (window.removeEventListener) {\n            window.removeEventListener(\"storage\", bound);\n        } else {\n            document.detachEvent(\"onstorage\", bound);\n        }\n        return this;\n    });\n    _.event = function(k, s, e) {\n        var event = {\n            key: k,\n            namespace: s.namespace(),\n            newValue: _.parse(e.newValue),\n            oldValue: _.parse(e.oldValue),\n            url: e.url || e.uri,\n            storageArea: e.storageArea,\n            source: e.source,\n            timeStamp: e.timeStamp,\n            originalEvent: e\n        };\n        if (_.cache) {\n            var min = _.expires(e.newValue || e.oldValue);\n            if (min) {\n                event.expires = _.when(min);\n            }\n        }\n        return event;\n    };\n    _.id = function(area) {\n        for (var id in _.areas) {\n            if (area === _.areas[id]) {\n                return id;\n            }\n        }\n    };\n})(window, document, window.store._);"

/***/ }),
/* 10 */
/***/ (function(module, exports, __webpack_require__) {

	var _ = __webpack_require__( 1 );
	var postal = __webpack_require__( 2 );
	var S = __webpack_require__( 4 );
	var state = S.state;
	var env = S.env;
	
	var XWindowClient = function() {
		postal.fedx.FederationClient.apply( this, arguments );
	};
	
	XWindowClient.prototype = _.create( postal.fedx.FederationClient.prototype, {
		constructor: XWindowClient,
	
		transportName: "xwindow",
	
		shouldProcess: function() {
			var hasDomainFilters = !!state.config.allowedOrigins.length;
			return state.config.enabled &&
					// another frame/window
				( ( this.options.origin === "*" || ( hasDomainFilters && _.includes( state.config.allowedOrigins, this.options.origin ) || !hasDomainFilters ) ) ||
					// worker
				( this.options.isWorker && _.includes( state.workers, this.target ) ) ||
					// we are in a worker
				env.isWorker );
		},
		send: function( packingSlip ) {
			if ( this.shouldProcess() ) {
				var msg = postal.fedx.transports.xwindow.wrapForTransport( packingSlip );
				this.target.set( "message", msg );
			}
		}
	} );
	
	module.exports = XWindowClient;


/***/ })
/******/ ])
});
;

/***/ }),
/* 49 */,
/* 50 */,
/* 51 */,
/* 52 */,
/* 53 */,
/* 54 */,
/* 55 */,
/* 56 */,
/* 57 */,
/* 58 */,
/* 59 */,
/* 60 */,
/* 61 */,
/* 62 */,
/* 63 */,
/* 64 */,
/* 65 */,
/* 66 */,
/* 67 */,
/* 68 */,
/* 69 */,
/* 70 */,
/* 71 */,
/* 72 */,
/* 73 */,
/* 74 */,
/* 75 */,
/* 76 */,
/* 77 */,
/* 78 */,
/* 79 */,
/* 80 */,
/* 81 */,
/* 82 */,
/* 83 */,
/* 84 */,
/* 85 */,
/* 86 */,
/* 87 */,
/* 88 */,
/* 89 */,
/* 90 */,
/* 91 */,
/* 92 */,
/* 93 */,
/* 94 */,
/* 95 */,
/* 96 */,
/* 97 */,
/* 98 */,
/* 99 */,
/* 100 */,
/* 101 */,
/* 102 */,
/* 103 */,
/* 104 */,
/* 105 */,
/* 106 */,
/* 107 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const var_export = __webpack_require__(445);
var TwingNodeType;
(function (TwingNodeType) {
    TwingNodeType["AUTO_ESCAPE"] = "auto_escape";
    TwingNodeType["BLOCK"] = "block";
    TwingNodeType["BLOCK_REFERENCE"] = "block_reference";
    TwingNodeType["BODY"] = "body";
    TwingNodeType["COMMENT"] = "comment";
    TwingNodeType["DEPRECATED"] = "deprecated";
    TwingNodeType["DO"] = "do";
    TwingNodeType["EXPRESSION_ARRAY"] = "expression_array";
    TwingNodeType["EXPRESSION_ASSIGN_NAME"] = "expression_assign_name";
    TwingNodeType["EXPRESSION_BINARY"] = "expression_binary";
    TwingNodeType["EXPRESSION_BINARY_CONCAT"] = "expression_binary_concat";
    TwingNodeType["EXPRESSION_BINARY_RANGE"] = "expression_binary_range";
    TwingNodeType["EXPRESSION_BLOCK_REFERENCE"] = "expression_block_reference";
    TwingNodeType["EXPRESSION_CONDITIONAL"] = "expression_conditional";
    TwingNodeType["EXPRESSION_CONSTANT"] = "expression_constant";
    TwingNodeType["EXPRESSION_FILTER"] = "expression_filter";
    TwingNodeType["EXPRESSION_FUNCTION"] = "expression_function";
    TwingNodeType["EXPRESSION_GET_ATTR"] = "expression_get_attr";
    TwingNodeType["EXPRESSION_METHOD_CALL"] = "expression_method_call";
    TwingNodeType["EXPRESSION_NAME"] = "expression_name";
    TwingNodeType["EXPRESSION_NULL_COALESCE"] = "expression_null_coalesce";
    TwingNodeType["EXPRESSION_PARENT"] = "expression_parent";
    TwingNodeType["EXPRESSION_TEMP_NAME"] = "expression_temp_name";
    TwingNodeType["EXPRESSION_TEST"] = "expression_test";
    TwingNodeType["EXPRESSION_UNARY"] = "expression_unary";
    TwingNodeType["EXPRESSION_UNARY_NEG"] = "expression_unary_neg";
    TwingNodeType["EXPRESSION_UNARY_POS"] = "expression_unary_pos";
    TwingNodeType["FLUSH"] = "flush";
    TwingNodeType["FOR"] = "for";
    TwingNodeType["IF"] = "if";
    TwingNodeType["IMPORT"] = "import";
    TwingNodeType["INCLUDE"] = "include";
    TwingNodeType["INLINE_PRINT"] = "inline_print";
    TwingNodeType["MACRO"] = "macro";
    TwingNodeType["MODULE"] = "module";
    TwingNodeType["PRINT"] = "print";
    TwingNodeType["PROFILER_ENTER_PROFILE"] = "profiler_enter_profile";
    TwingNodeType["PROFILER_LEAVE_PROFILE"] = "profiler_leave_profile";
    TwingNodeType["SANDBOX"] = "sandbox";
    TwingNodeType["SET"] = "set";
    TwingNodeType["SPACELESS"] = "spaceless";
    TwingNodeType["TEXT"] = "text";
    TwingNodeType["WITH"] = "with";
})(TwingNodeType = exports.TwingNodeType || (exports.TwingNodeType = {}));
class TwingNode {
    /**
     * Constructor.
     *
     * The nodes are automatically made available as properties ($this->node).
     * The attributes are automatically made available as array items ($this['name']).
     *
     * @param nodes         Map<string, TwingNode>  A map of named nodes
     * @param attributes    Map<string, {}>         A map of attributes (should not be nodes)
     * @param lineno        number                  The line number
     * @param columnno      number                  The column number
     * @param tag           string                  The tag name associated with the Nodel
     */
    constructor(nodes = new Map(), attributes = new Map(), lineno = 0, columnno = 0, tag = null) {
        this.name = null;
        this.nodes = nodes;
        this.attributes = attributes;
        this.lineno = lineno;
        this.columnno = columnno;
        this.tag = tag;
        this.type = null;
        this.types = [];
    }
    /**
     * @returns {TwingNode}
     */
    clone() {
        let result = Reflect.construct(this.constructor, []);
        for (let [name, node] of this.getNodes()) {
            result.setNode(name, node.clone());
        }
        for (let [name, node] of this.attributes) {
            if (node instanceof TwingNode) {
                node = node.clone();
            }
            result.setAttribute(name, node);
        }
        result.lineno = this.lineno;
        result.columnno = this.columnno;
        result.tag = this.tag;
        result.type = this.type;
        return result;
    }
    toString() {
        let attributes = [];
        for (let [name, value] of this.attributes) {
            let attributeRepr;
            if (value instanceof TwingNode) {
                attributeRepr = '' + value.toString();
            }
            else {
                attributeRepr = '' + var_export(value, true);
            }
            attributes.push(`${name}: ${attributeRepr.replace(/\n/g, '')}`);
        }
        attributes.push(`line: ${this.getTemplateLine()}`);
        attributes.push(`column: ${this.getTemplateColumn()}`);
        let repr = [this.constructor.name + '(' + attributes.join(', ')];
        if (this.nodes.size > 0) {
            for (let [name, node] of this.nodes) {
                let len = ('' + name).length + 4;
                let nodeRepr = [];
                for (let line of node.toString().split('\n')) {
                    nodeRepr.push(' '.repeat(len) + line);
                }
                repr.push(`  ${name}: ${nodeRepr.join('\n').trimLeft()}`);
            }
            repr.push(')');
        }
        else {
            repr[0] += ')';
        }
        return repr.join('\n');
    }
    getType() {
        return this.type;
    }
    addType(type) {
        this.types.push(type);
    }
    is(type) {
        return this.types.includes(type);
    }
    compile(compiler) {
        for (let [k, node] of this.nodes) {
            node.compile(compiler);
        }
    }
    getTemplateLine() {
        return this.lineno;
    }
    getTemplateColumn() {
        return this.columnno;
    }
    getNodeTag() {
        return this.tag;
    }
    /**
     * @returns booleqn
     */
    hasAttribute(name) {
        return this.attributes.has(name);
    }
    /**
     *
     * @param {string} name
     * @returns any
     */
    getAttribute(name) {
        if (!this.attributes.has(name)) {
            throw new Error(`Attribute "${name}" does not exist for Node "${this.constructor.name}".`);
        }
        return this.attributes.get(name);
    }
    /**
     * @param {string} name
     * @param {*} value
     */
    setAttribute(name, value) {
        this.attributes.set(name, value);
    }
    removeAttribute(name) {
        this.attributes.delete(name);
    }
    /**
     * @return bool
     */
    hasNode(name) {
        return this.nodes.has(name);
    }
    /**
     * @return TwingNode
     */
    getNode(name) {
        if (!this.nodes.has(name)) {
            throw new Error(`Node "${name}" does not exist for Node "${this.constructor.name}".`);
        }
        return this.nodes.get(name);
    }
    setNode(name, node) {
        this.nodes.set(name, node);
    }
    removeNode(name) {
        this.nodes.delete(name);
    }
    count() {
        return this.nodes.size;
    }
    setTemplateName(name) {
        this.name = name;
        for (let [k, node] of this.nodes) {
            node.setTemplateName(name);
        }
    }
    getTemplateName() {
        return this.name;
    }
    getNodes() {
        return this.nodes;
    }
}
exports.TwingNode = TwingNode;


/***/ }),
/* 108 */
/***/ (function(module, exports) {

module.exports = function escape(url) {
    if (typeof url !== 'string') {
        return url
    }
    // If url is already wrapped in quotes, remove them
    if (/^['"].*['"]$/.test(url)) {
        url = url.slice(1, -1);
    }
    // Should url be wrapped?
    // See https://drafts.csswg.org/css-values-3/#urls
    if (/["'() \t\n]/.test(url)) {
        return '"' + url.replace(/"/g, '\\"').replace(/\n/g, '\\n') + '"'
    }

    return url
}


/***/ }),
/* 109 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingToken {
    constructor(type, value, lineno, columnno) {
        this.type = type;
        this.value = value;
        this.lineno = lineno;
        this.columnno = columnno;
    }
    /**
     * Returns the constant representation (internal) of a given type.
     *
     * @param {int} type The type as an integer
     * @param {boolean} short Whether to return a short representation or not
     *
     * @returns {string} The string representation
     */
    static typeToString(type, short = false) {
        let name;
        switch (type) {
            case TwingToken.EOF_TYPE:
                name = 'EOF_TYPE';
                break;
            case TwingToken.TEXT_TYPE:
                name = 'TEXT_TYPE';
                break;
            case TwingToken.BLOCK_START_TYPE:
                name = 'BLOCK_START_TYPE';
                break;
            case TwingToken.VAR_START_TYPE:
                name = 'VAR_START_TYPE';
                break;
            case TwingToken.BLOCK_END_TYPE:
                name = 'BLOCK_END_TYPE';
                break;
            case TwingToken.VAR_END_TYPE:
                name = 'VAR_END_TYPE';
                break;
            case TwingToken.NAME_TYPE:
                name = 'NAME_TYPE';
                break;
            case TwingToken.NUMBER_TYPE:
                name = 'NUMBER_TYPE';
                break;
            case TwingToken.STRING_TYPE:
                name = 'STRING_TYPE';
                break;
            case TwingToken.OPERATOR_TYPE:
                name = 'OPERATOR_TYPE';
                break;
            case TwingToken.PUNCTUATION_TYPE:
                name = 'PUNCTUATION_TYPE';
                break;
            case TwingToken.INTERPOLATION_START_TYPE:
                name = 'INTERPOLATION_START_TYPE';
                break;
            case TwingToken.INTERPOLATION_END_TYPE:
                name = 'INTERPOLATION_END_TYPE';
                break;
            case TwingToken.COMMENT_START_TYPE:
                name = 'COMMENT_START_TYPE';
                break;
            case TwingToken.COMMENT_END_TYPE:
                name = 'COMMENT_END_TYPE';
                break;
            case TwingToken.ARROW_TYPE:
                name = 'ARROW_TYPE';
                break;
            default:
                throw new Error(`Token of type "${type}" does not exist.`);
        }
        return short ? name : 'TwingToken.' + name;
    }
    /**
     * Returns the English representation of a given type.
     *
     * @param {int} type The type as an integer
     *
     * @returns {string} The string representation
     */
    static typeToEnglish(type) {
        switch (type) {
            case TwingToken.EOF_TYPE:
                return 'end of template';
            case TwingToken.TEXT_TYPE:
                return 'text';
            case TwingToken.BLOCK_START_TYPE:
                return 'begin of statement block';
            case TwingToken.VAR_START_TYPE:
                return 'begin of print statement';
            case TwingToken.BLOCK_END_TYPE:
                return 'end of statement block';
            case TwingToken.VAR_END_TYPE:
                return 'end of print statement';
            case TwingToken.NAME_TYPE:
                return 'name';
            case TwingToken.NUMBER_TYPE:
                return 'number';
            case TwingToken.STRING_TYPE:
                return 'string';
            case TwingToken.OPERATOR_TYPE:
                return 'operator';
            case TwingToken.PUNCTUATION_TYPE:
                return 'punctuation';
            case TwingToken.INTERPOLATION_START_TYPE:
                return 'begin of string interpolation';
            case TwingToken.INTERPOLATION_END_TYPE:
                return 'end of string interpolation';
            case TwingToken.COMMENT_START_TYPE:
                return 'begin of comment statement';
            case TwingToken.COMMENT_END_TYPE:
                return 'end of comment statement';
            case TwingToken.ARROW_TYPE:
                return 'arrow function';
            default:
                throw new Error(`Token of type "${type}" does not exist.`);
        }
    }
    /**
     * Tests the current token for a type and/or a value.
     *
     * Parameters may be:
     *  * just type
     *  * type and value (or array of possible values)
     *  * just value (or array of possible values) (NAME_TYPE is used as type)
     *
     * @param {number} type
     * @param {string|Array<string>} values
     * @returns {boolean}
     */
    test(type, values = null) {
        return (this.type === type) && (values === null || (Array.isArray(values) && values.includes(this.value)) || this.value == values);
    }
    /**
     * @return int
     */
    getLine() {
        return this.lineno;
    }
    /**
     * @return int
     */
    getColumn() {
        return this.columnno;
    }
    getType() {
        return this.type;
    }
    getValue() {
        return this.value;
    }
    toString() {
        return `${TwingToken.typeToString(this.type, true)}(${this.value ? this.value : ''})`;
    }
}
exports.TwingToken = TwingToken;
TwingToken.EOF_TYPE = -1;
TwingToken.TEXT_TYPE = 0;
TwingToken.BLOCK_START_TYPE = 1;
TwingToken.VAR_START_TYPE = 2;
TwingToken.BLOCK_END_TYPE = 3;
TwingToken.VAR_END_TYPE = 4;
TwingToken.NAME_TYPE = 5;
TwingToken.NUMBER_TYPE = 6;
TwingToken.STRING_TYPE = 7;
TwingToken.OPERATOR_TYPE = 8;
TwingToken.PUNCTUATION_TYPE = 9;
TwingToken.INTERPOLATION_START_TYPE = 10;
TwingToken.INTERPOLATION_END_TYPE = 11;
TwingToken.COMMENT_START_TYPE = 12;
TwingToken.COMMENT_END_TYPE = 13;
TwingToken.ARROW_TYPE = 14;


/***/ }),
/* 110 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionBinary extends expression_1.TwingNodeExpression {
    constructor(left, right, lineno, columno) {
        let nodes = new Map();
        nodes.set('left', left);
        nodes.set('right', right);
        super(nodes, new Map(), lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_BINARY;
    }
    compile(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('left'))
            .raw(' ');
        this.operator(compiler);
        compiler
            .raw(' ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
    /**
     *
     * @param {TwingCompiler} compiler
     * @returns {TwingCompiler}
     */
    operator(compiler) {
        return compiler;
    }
}
exports.TwingNodeExpressionBinary = TwingNodeExpressionBinary;


/***/ }),
/* 111 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Base class for all token parsers.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingTokenParser {
    constructor() {
        this.TwingTokenParserInterfaceImpl = this;
    }
    setParser(parser) {
        this.parser = parser;
    }
}
exports.TwingTokenParser = TwingTokenParser;


/***/ }),
/* 112 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const error_1 = __webpack_require__(120);
const Levenshtein = __webpack_require__(447);
class TwingErrorSyntax extends error_1.TwingError {
    constructor(message, lineno = -1, source = null, previous) {
        super(message, lineno, source, previous);
        this.name = 'TwingErrorSyntax';
    }
    /**
     * Tweaks the error message to include suggestions.
     *
     * @param {string} name The original name of the item that does not exist
     * @param {Array<string>} items An array of possible items
     */
    addSuggestions(name, items) {
        let alternatives = [];
        let levenshtein = new Levenshtein();
        items.forEach(function (item) {
            levenshtein = new Levenshtein(name, item);
            if (levenshtein.distance <= (name.length / 3) || item.indexOf(name) > -1) {
                alternatives.push(item);
            }
        });
        if (alternatives.length < 1) {
            return;
        }
        alternatives.sort();
        this.appendMessage(` Did you mean "${alternatives.join(', ')}"?`);
    }
}
exports.TwingErrorSyntax = TwingErrorSyntax;


/***/ }),
/* 113 */,
/* 114 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Abstract class for all nodes that represents an expression.
 */
class TwingNodeExpression extends node_1.TwingNode {
}
exports.TwingNodeExpression = TwingNodeExpression;


/***/ }),
/* 115 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionConstant extends expression_1.TwingNodeExpression {
    constructor(value, lineno, columnno) {
        super(new Map(), new Map([['value', value]]), lineno, columnno);
        this.type = node_1.TwingNodeType.EXPRESSION_CONSTANT;
    }
    compile(compiler) {
        compiler.repr(this.getAttribute('value'));
    }
}
exports.TwingNodeExpressionConstant = TwingNodeExpressionConstant;


/***/ }),
/* 116 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {/*!
 * The buffer module from node.js, for the browser.
 *
 * @author   Feross Aboukhadijeh <http://feross.org>
 * @license  MIT
 */
/* eslint-disable no-proto */



var base64 = __webpack_require__(413)
var ieee754 = __webpack_require__(414)
var isArray = __webpack_require__(220)

exports.Buffer = Buffer
exports.SlowBuffer = SlowBuffer
exports.INSPECT_MAX_BYTES = 50

/**
 * If `Buffer.TYPED_ARRAY_SUPPORT`:
 *   === true    Use Uint8Array implementation (fastest)
 *   === false   Use Object implementation (most compatible, even IE6)
 *
 * Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+,
 * Opera 11.6+, iOS 4.2+.
 *
 * Due to various browser bugs, sometimes the Object implementation will be used even
 * when the browser supports typed arrays.
 *
 * Note:
 *
 *   - Firefox 4-29 lacks support for adding new properties to `Uint8Array` instances,
 *     See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438.
 *
 *   - Chrome 9-10 is missing the `TypedArray.prototype.subarray` function.
 *
 *   - IE10 has a broken `TypedArray.prototype.subarray` function which returns arrays of
 *     incorrect length in some situations.

 * We detect these buggy browsers and set `Buffer.TYPED_ARRAY_SUPPORT` to `false` so they
 * get the Object implementation, which is slower but behaves correctly.
 */
Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined
  ? global.TYPED_ARRAY_SUPPORT
  : typedArraySupport()

/*
 * Export kMaxLength after typed array support is determined.
 */
exports.kMaxLength = kMaxLength()

function typedArraySupport () {
  try {
    var arr = new Uint8Array(1)
    arr.__proto__ = {__proto__: Uint8Array.prototype, foo: function () { return 42 }}
    return arr.foo() === 42 && // typed array instances can be augmented
        typeof arr.subarray === 'function' && // chrome 9-10 lack `subarray`
        arr.subarray(1, 1).byteLength === 0 // ie10 has broken `subarray`
  } catch (e) {
    return false
  }
}

function kMaxLength () {
  return Buffer.TYPED_ARRAY_SUPPORT
    ? 0x7fffffff
    : 0x3fffffff
}

function createBuffer (that, length) {
  if (kMaxLength() < length) {
    throw new RangeError('Invalid typed array length')
  }
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    // Return an augmented `Uint8Array` instance, for best performance
    that = new Uint8Array(length)
    that.__proto__ = Buffer.prototype
  } else {
    // Fallback: Return an object instance of the Buffer class
    if (that === null) {
      that = new Buffer(length)
    }
    that.length = length
  }

  return that
}

/**
 * The Buffer constructor returns instances of `Uint8Array` that have their
 * prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of
 * `Uint8Array`, so the returned instances will have all the node `Buffer` methods
 * and the `Uint8Array` methods. Square bracket notation works as expected -- it
 * returns a single octet.
 *
 * The `Uint8Array` prototype remains unmodified.
 */

function Buffer (arg, encodingOrOffset, length) {
  if (!Buffer.TYPED_ARRAY_SUPPORT && !(this instanceof Buffer)) {
    return new Buffer(arg, encodingOrOffset, length)
  }

  // Common case.
  if (typeof arg === 'number') {
    if (typeof encodingOrOffset === 'string') {
      throw new Error(
        'If encoding is specified then the first argument must be a string'
      )
    }
    return allocUnsafe(this, arg)
  }
  return from(this, arg, encodingOrOffset, length)
}

Buffer.poolSize = 8192 // not used by this implementation

// TODO: Legacy, not needed anymore. Remove in next major version.
Buffer._augment = function (arr) {
  arr.__proto__ = Buffer.prototype
  return arr
}

function from (that, value, encodingOrOffset, length) {
  if (typeof value === 'number') {
    throw new TypeError('"value" argument must not be a number')
  }

  if (typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer) {
    return fromArrayBuffer(that, value, encodingOrOffset, length)
  }

  if (typeof value === 'string') {
    return fromString(that, value, encodingOrOffset)
  }

  return fromObject(that, value)
}

/**
 * Functionally equivalent to Buffer(arg, encoding) but throws a TypeError
 * if value is a number.
 * Buffer.from(str[, encoding])
 * Buffer.from(array)
 * Buffer.from(buffer)
 * Buffer.from(arrayBuffer[, byteOffset[, length]])
 **/
Buffer.from = function (value, encodingOrOffset, length) {
  return from(null, value, encodingOrOffset, length)
}

if (Buffer.TYPED_ARRAY_SUPPORT) {
  Buffer.prototype.__proto__ = Uint8Array.prototype
  Buffer.__proto__ = Uint8Array
  if (typeof Symbol !== 'undefined' && Symbol.species &&
      Buffer[Symbol.species] === Buffer) {
    // Fix subarray() in ES2016. See: https://github.com/feross/buffer/pull/97
    Object.defineProperty(Buffer, Symbol.species, {
      value: null,
      configurable: true
    })
  }
}

function assertSize (size) {
  if (typeof size !== 'number') {
    throw new TypeError('"size" argument must be a number')
  } else if (size < 0) {
    throw new RangeError('"size" argument must not be negative')
  }
}

function alloc (that, size, fill, encoding) {
  assertSize(size)
  if (size <= 0) {
    return createBuffer(that, size)
  }
  if (fill !== undefined) {
    // Only pay attention to encoding if it's a string. This
    // prevents accidentally sending in a number that would
    // be interpretted as a start offset.
    return typeof encoding === 'string'
      ? createBuffer(that, size).fill(fill, encoding)
      : createBuffer(that, size).fill(fill)
  }
  return createBuffer(that, size)
}

/**
 * Creates a new filled Buffer instance.
 * alloc(size[, fill[, encoding]])
 **/
Buffer.alloc = function (size, fill, encoding) {
  return alloc(null, size, fill, encoding)
}

function allocUnsafe (that, size) {
  assertSize(size)
  that = createBuffer(that, size < 0 ? 0 : checked(size) | 0)
  if (!Buffer.TYPED_ARRAY_SUPPORT) {
    for (var i = 0; i < size; ++i) {
      that[i] = 0
    }
  }
  return that
}

/**
 * Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance.
 * */
Buffer.allocUnsafe = function (size) {
  return allocUnsafe(null, size)
}
/**
 * Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance.
 */
Buffer.allocUnsafeSlow = function (size) {
  return allocUnsafe(null, size)
}

function fromString (that, string, encoding) {
  if (typeof encoding !== 'string' || encoding === '') {
    encoding = 'utf8'
  }

  if (!Buffer.isEncoding(encoding)) {
    throw new TypeError('"encoding" must be a valid string encoding')
  }

  var length = byteLength(string, encoding) | 0
  that = createBuffer(that, length)

  var actual = that.write(string, encoding)

  if (actual !== length) {
    // Writing a hex string, for example, that contains invalid characters will
    // cause everything after the first invalid character to be ignored. (e.g.
    // 'abxxcd' will be treated as 'ab')
    that = that.slice(0, actual)
  }

  return that
}

function fromArrayLike (that, array) {
  var length = array.length < 0 ? 0 : checked(array.length) | 0
  that = createBuffer(that, length)
  for (var i = 0; i < length; i += 1) {
    that[i] = array[i] & 255
  }
  return that
}

function fromArrayBuffer (that, array, byteOffset, length) {
  array.byteLength // this throws if `array` is not a valid ArrayBuffer

  if (byteOffset < 0 || array.byteLength < byteOffset) {
    throw new RangeError('\'offset\' is out of bounds')
  }

  if (array.byteLength < byteOffset + (length || 0)) {
    throw new RangeError('\'length\' is out of bounds')
  }

  if (byteOffset === undefined && length === undefined) {
    array = new Uint8Array(array)
  } else if (length === undefined) {
    array = new Uint8Array(array, byteOffset)
  } else {
    array = new Uint8Array(array, byteOffset, length)
  }

  if (Buffer.TYPED_ARRAY_SUPPORT) {
    // Return an augmented `Uint8Array` instance, for best performance
    that = array
    that.__proto__ = Buffer.prototype
  } else {
    // Fallback: Return an object instance of the Buffer class
    that = fromArrayLike(that, array)
  }
  return that
}

function fromObject (that, obj) {
  if (Buffer.isBuffer(obj)) {
    var len = checked(obj.length) | 0
    that = createBuffer(that, len)

    if (that.length === 0) {
      return that
    }

    obj.copy(that, 0, 0, len)
    return that
  }

  if (obj) {
    if ((typeof ArrayBuffer !== 'undefined' &&
        obj.buffer instanceof ArrayBuffer) || 'length' in obj) {
      if (typeof obj.length !== 'number' || isnan(obj.length)) {
        return createBuffer(that, 0)
      }
      return fromArrayLike(that, obj)
    }

    if (obj.type === 'Buffer' && isArray(obj.data)) {
      return fromArrayLike(that, obj.data)
    }
  }

  throw new TypeError('First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.')
}

function checked (length) {
  // Note: cannot use `length < kMaxLength()` here because that fails when
  // length is NaN (which is otherwise coerced to zero.)
  if (length >= kMaxLength()) {
    throw new RangeError('Attempt to allocate Buffer larger than maximum ' +
                         'size: 0x' + kMaxLength().toString(16) + ' bytes')
  }
  return length | 0
}

function SlowBuffer (length) {
  if (+length != length) { // eslint-disable-line eqeqeq
    length = 0
  }
  return Buffer.alloc(+length)
}

Buffer.isBuffer = function isBuffer (b) {
  return !!(b != null && b._isBuffer)
}

Buffer.compare = function compare (a, b) {
  if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) {
    throw new TypeError('Arguments must be Buffers')
  }

  if (a === b) return 0

  var x = a.length
  var y = b.length

  for (var i = 0, len = Math.min(x, y); i < len; ++i) {
    if (a[i] !== b[i]) {
      x = a[i]
      y = b[i]
      break
    }
  }

  if (x < y) return -1
  if (y < x) return 1
  return 0
}

Buffer.isEncoding = function isEncoding (encoding) {
  switch (String(encoding).toLowerCase()) {
    case 'hex':
    case 'utf8':
    case 'utf-8':
    case 'ascii':
    case 'latin1':
    case 'binary':
    case 'base64':
    case 'ucs2':
    case 'ucs-2':
    case 'utf16le':
    case 'utf-16le':
      return true
    default:
      return false
  }
}

Buffer.concat = function concat (list, length) {
  if (!isArray(list)) {
    throw new TypeError('"list" argument must be an Array of Buffers')
  }

  if (list.length === 0) {
    return Buffer.alloc(0)
  }

  var i
  if (length === undefined) {
    length = 0
    for (i = 0; i < list.length; ++i) {
      length += list[i].length
    }
  }

  var buffer = Buffer.allocUnsafe(length)
  var pos = 0
  for (i = 0; i < list.length; ++i) {
    var buf = list[i]
    if (!Buffer.isBuffer(buf)) {
      throw new TypeError('"list" argument must be an Array of Buffers')
    }
    buf.copy(buffer, pos)
    pos += buf.length
  }
  return buffer
}

function byteLength (string, encoding) {
  if (Buffer.isBuffer(string)) {
    return string.length
  }
  if (typeof ArrayBuffer !== 'undefined' && typeof ArrayBuffer.isView === 'function' &&
      (ArrayBuffer.isView(string) || string instanceof ArrayBuffer)) {
    return string.byteLength
  }
  if (typeof string !== 'string') {
    string = '' + string
  }

  var len = string.length
  if (len === 0) return 0

  // Use a for loop to avoid recursion
  var loweredCase = false
  for (;;) {
    switch (encoding) {
      case 'ascii':
      case 'latin1':
      case 'binary':
        return len
      case 'utf8':
      case 'utf-8':
      case undefined:
        return utf8ToBytes(string).length
      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return len * 2
      case 'hex':
        return len >>> 1
      case 'base64':
        return base64ToBytes(string).length
      default:
        if (loweredCase) return utf8ToBytes(string).length // assume utf8
        encoding = ('' + encoding).toLowerCase()
        loweredCase = true
    }
  }
}
Buffer.byteLength = byteLength

function slowToString (encoding, start, end) {
  var loweredCase = false

  // No need to verify that "this.length <= MAX_UINT32" since it's a read-only
  // property of a typed array.

  // This behaves neither like String nor Uint8Array in that we set start/end
  // to their upper/lower bounds if the value passed is out of range.
  // undefined is handled specially as per ECMA-262 6th Edition,
  // Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization.
  if (start === undefined || start < 0) {
    start = 0
  }
  // Return early if start > this.length. Done here to prevent potential uint32
  // coercion fail below.
  if (start > this.length) {
    return ''
  }

  if (end === undefined || end > this.length) {
    end = this.length
  }

  if (end <= 0) {
    return ''
  }

  // Force coersion to uint32. This will also coerce falsey/NaN values to 0.
  end >>>= 0
  start >>>= 0

  if (end <= start) {
    return ''
  }

  if (!encoding) encoding = 'utf8'

  while (true) {
    switch (encoding) {
      case 'hex':
        return hexSlice(this, start, end)

      case 'utf8':
      case 'utf-8':
        return utf8Slice(this, start, end)

      case 'ascii':
        return asciiSlice(this, start, end)

      case 'latin1':
      case 'binary':
        return latin1Slice(this, start, end)

      case 'base64':
        return base64Slice(this, start, end)

      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return utf16leSlice(this, start, end)

      default:
        if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding)
        encoding = (encoding + '').toLowerCase()
        loweredCase = true
    }
  }
}

// The property is used by `Buffer.isBuffer` and `is-buffer` (in Safari 5-7) to detect
// Buffer instances.
Buffer.prototype._isBuffer = true

function swap (b, n, m) {
  var i = b[n]
  b[n] = b[m]
  b[m] = i
}

Buffer.prototype.swap16 = function swap16 () {
  var len = this.length
  if (len % 2 !== 0) {
    throw new RangeError('Buffer size must be a multiple of 16-bits')
  }
  for (var i = 0; i < len; i += 2) {
    swap(this, i, i + 1)
  }
  return this
}

Buffer.prototype.swap32 = function swap32 () {
  var len = this.length
  if (len % 4 !== 0) {
    throw new RangeError('Buffer size must be a multiple of 32-bits')
  }
  for (var i = 0; i < len; i += 4) {
    swap(this, i, i + 3)
    swap(this, i + 1, i + 2)
  }
  return this
}

Buffer.prototype.swap64 = function swap64 () {
  var len = this.length
  if (len % 8 !== 0) {
    throw new RangeError('Buffer size must be a multiple of 64-bits')
  }
  for (var i = 0; i < len; i += 8) {
    swap(this, i, i + 7)
    swap(this, i + 1, i + 6)
    swap(this, i + 2, i + 5)
    swap(this, i + 3, i + 4)
  }
  return this
}

Buffer.prototype.toString = function toString () {
  var length = this.length | 0
  if (length === 0) return ''
  if (arguments.length === 0) return utf8Slice(this, 0, length)
  return slowToString.apply(this, arguments)
}

Buffer.prototype.equals = function equals (b) {
  if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer')
  if (this === b) return true
  return Buffer.compare(this, b) === 0
}

Buffer.prototype.inspect = function inspect () {
  var str = ''
  var max = exports.INSPECT_MAX_BYTES
  if (this.length > 0) {
    str = this.toString('hex', 0, max).match(/.{2}/g).join(' ')
    if (this.length > max) str += ' ... '
  }
  return '<Buffer ' + str + '>'
}

Buffer.prototype.compare = function compare (target, start, end, thisStart, thisEnd) {
  if (!Buffer.isBuffer(target)) {
    throw new TypeError('Argument must be a Buffer')
  }

  if (start === undefined) {
    start = 0
  }
  if (end === undefined) {
    end = target ? target.length : 0
  }
  if (thisStart === undefined) {
    thisStart = 0
  }
  if (thisEnd === undefined) {
    thisEnd = this.length
  }

  if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) {
    throw new RangeError('out of range index')
  }

  if (thisStart >= thisEnd && start >= end) {
    return 0
  }
  if (thisStart >= thisEnd) {
    return -1
  }
  if (start >= end) {
    return 1
  }

  start >>>= 0
  end >>>= 0
  thisStart >>>= 0
  thisEnd >>>= 0

  if (this === target) return 0

  var x = thisEnd - thisStart
  var y = end - start
  var len = Math.min(x, y)

  var thisCopy = this.slice(thisStart, thisEnd)
  var targetCopy = target.slice(start, end)

  for (var i = 0; i < len; ++i) {
    if (thisCopy[i] !== targetCopy[i]) {
      x = thisCopy[i]
      y = targetCopy[i]
      break
    }
  }

  if (x < y) return -1
  if (y < x) return 1
  return 0
}

// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`,
// OR the last index of `val` in `buffer` at offset <= `byteOffset`.
//
// Arguments:
// - buffer - a Buffer to search
// - val - a string, Buffer, or number
// - byteOffset - an index into `buffer`; will be clamped to an int32
// - encoding - an optional encoding, relevant is val is a string
// - dir - true for indexOf, false for lastIndexOf
function bidirectionalIndexOf (buffer, val, byteOffset, encoding, dir) {
  // Empty buffer means no match
  if (buffer.length === 0) return -1

  // Normalize byteOffset
  if (typeof byteOffset === 'string') {
    encoding = byteOffset
    byteOffset = 0
  } else if (byteOffset > 0x7fffffff) {
    byteOffset = 0x7fffffff
  } else if (byteOffset < -0x80000000) {
    byteOffset = -0x80000000
  }
  byteOffset = +byteOffset  // Coerce to Number.
  if (isNaN(byteOffset)) {
    // byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer
    byteOffset = dir ? 0 : (buffer.length - 1)
  }

  // Normalize byteOffset: negative offsets start from the end of the buffer
  if (byteOffset < 0) byteOffset = buffer.length + byteOffset
  if (byteOffset >= buffer.length) {
    if (dir) return -1
    else byteOffset = buffer.length - 1
  } else if (byteOffset < 0) {
    if (dir) byteOffset = 0
    else return -1
  }

  // Normalize val
  if (typeof val === 'string') {
    val = Buffer.from(val, encoding)
  }

  // Finally, search either indexOf (if dir is true) or lastIndexOf
  if (Buffer.isBuffer(val)) {
    // Special case: looking for empty string/buffer always fails
    if (val.length === 0) {
      return -1
    }
    return arrayIndexOf(buffer, val, byteOffset, encoding, dir)
  } else if (typeof val === 'number') {
    val = val & 0xFF // Search for a byte value [0-255]
    if (Buffer.TYPED_ARRAY_SUPPORT &&
        typeof Uint8Array.prototype.indexOf === 'function') {
      if (dir) {
        return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset)
      } else {
        return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset)
      }
    }
    return arrayIndexOf(buffer, [ val ], byteOffset, encoding, dir)
  }

  throw new TypeError('val must be string, number or Buffer')
}

function arrayIndexOf (arr, val, byteOffset, encoding, dir) {
  var indexSize = 1
  var arrLength = arr.length
  var valLength = val.length

  if (encoding !== undefined) {
    encoding = String(encoding).toLowerCase()
    if (encoding === 'ucs2' || encoding === 'ucs-2' ||
        encoding === 'utf16le' || encoding === 'utf-16le') {
      if (arr.length < 2 || val.length < 2) {
        return -1
      }
      indexSize = 2
      arrLength /= 2
      valLength /= 2
      byteOffset /= 2
    }
  }

  function read (buf, i) {
    if (indexSize === 1) {
      return buf[i]
    } else {
      return buf.readUInt16BE(i * indexSize)
    }
  }

  var i
  if (dir) {
    var foundIndex = -1
    for (i = byteOffset; i < arrLength; i++) {
      if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) {
        if (foundIndex === -1) foundIndex = i
        if (i - foundIndex + 1 === valLength) return foundIndex * indexSize
      } else {
        if (foundIndex !== -1) i -= i - foundIndex
        foundIndex = -1
      }
    }
  } else {
    if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength
    for (i = byteOffset; i >= 0; i--) {
      var found = true
      for (var j = 0; j < valLength; j++) {
        if (read(arr, i + j) !== read(val, j)) {
          found = false
          break
        }
      }
      if (found) return i
    }
  }

  return -1
}

Buffer.prototype.includes = function includes (val, byteOffset, encoding) {
  return this.indexOf(val, byteOffset, encoding) !== -1
}

Buffer.prototype.indexOf = function indexOf (val, byteOffset, encoding) {
  return bidirectionalIndexOf(this, val, byteOffset, encoding, true)
}

Buffer.prototype.lastIndexOf = function lastIndexOf (val, byteOffset, encoding) {
  return bidirectionalIndexOf(this, val, byteOffset, encoding, false)
}

function hexWrite (buf, string, offset, length) {
  offset = Number(offset) || 0
  var remaining = buf.length - offset
  if (!length) {
    length = remaining
  } else {
    length = Number(length)
    if (length > remaining) {
      length = remaining
    }
  }

  // must be an even number of digits
  var strLen = string.length
  if (strLen % 2 !== 0) throw new TypeError('Invalid hex string')

  if (length > strLen / 2) {
    length = strLen / 2
  }
  for (var i = 0; i < length; ++i) {
    var parsed = parseInt(string.substr(i * 2, 2), 16)
    if (isNaN(parsed)) return i
    buf[offset + i] = parsed
  }
  return i
}

function utf8Write (buf, string, offset, length) {
  return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length)
}

function asciiWrite (buf, string, offset, length) {
  return blitBuffer(asciiToBytes(string), buf, offset, length)
}

function latin1Write (buf, string, offset, length) {
  return asciiWrite(buf, string, offset, length)
}

function base64Write (buf, string, offset, length) {
  return blitBuffer(base64ToBytes(string), buf, offset, length)
}

function ucs2Write (buf, string, offset, length) {
  return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length)
}

Buffer.prototype.write = function write (string, offset, length, encoding) {
  // Buffer#write(string)
  if (offset === undefined) {
    encoding = 'utf8'
    length = this.length
    offset = 0
  // Buffer#write(string, encoding)
  } else if (length === undefined && typeof offset === 'string') {
    encoding = offset
    length = this.length
    offset = 0
  // Buffer#write(string, offset[, length][, encoding])
  } else if (isFinite(offset)) {
    offset = offset | 0
    if (isFinite(length)) {
      length = length | 0
      if (encoding === undefined) encoding = 'utf8'
    } else {
      encoding = length
      length = undefined
    }
  // legacy write(string, encoding, offset, length) - remove in v0.13
  } else {
    throw new Error(
      'Buffer.write(string, encoding, offset[, length]) is no longer supported'
    )
  }

  var remaining = this.length - offset
  if (length === undefined || length > remaining) length = remaining

  if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) {
    throw new RangeError('Attempt to write outside buffer bounds')
  }

  if (!encoding) encoding = 'utf8'

  var loweredCase = false
  for (;;) {
    switch (encoding) {
      case 'hex':
        return hexWrite(this, string, offset, length)

      case 'utf8':
      case 'utf-8':
        return utf8Write(this, string, offset, length)

      case 'ascii':
        return asciiWrite(this, string, offset, length)

      case 'latin1':
      case 'binary':
        return latin1Write(this, string, offset, length)

      case 'base64':
        // Warning: maxLength not taken into account in base64Write
        return base64Write(this, string, offset, length)

      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return ucs2Write(this, string, offset, length)

      default:
        if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding)
        encoding = ('' + encoding).toLowerCase()
        loweredCase = true
    }
  }
}

Buffer.prototype.toJSON = function toJSON () {
  return {
    type: 'Buffer',
    data: Array.prototype.slice.call(this._arr || this, 0)
  }
}

function base64Slice (buf, start, end) {
  if (start === 0 && end === buf.length) {
    return base64.fromByteArray(buf)
  } else {
    return base64.fromByteArray(buf.slice(start, end))
  }
}

function utf8Slice (buf, start, end) {
  end = Math.min(buf.length, end)
  var res = []

  var i = start
  while (i < end) {
    var firstByte = buf[i]
    var codePoint = null
    var bytesPerSequence = (firstByte > 0xEF) ? 4
      : (firstByte > 0xDF) ? 3
      : (firstByte > 0xBF) ? 2
      : 1

    if (i + bytesPerSequence <= end) {
      var secondByte, thirdByte, fourthByte, tempCodePoint

      switch (bytesPerSequence) {
        case 1:
          if (firstByte < 0x80) {
            codePoint = firstByte
          }
          break
        case 2:
          secondByte = buf[i + 1]
          if ((secondByte & 0xC0) === 0x80) {
            tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F)
            if (tempCodePoint > 0x7F) {
              codePoint = tempCodePoint
            }
          }
          break
        case 3:
          secondByte = buf[i + 1]
          thirdByte = buf[i + 2]
          if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) {
            tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F)
            if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) {
              codePoint = tempCodePoint
            }
          }
          break
        case 4:
          secondByte = buf[i + 1]
          thirdByte = buf[i + 2]
          fourthByte = buf[i + 3]
          if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) {
            tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F)
            if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) {
              codePoint = tempCodePoint
            }
          }
      }
    }

    if (codePoint === null) {
      // we did not generate a valid codePoint so insert a
      // replacement char (U+FFFD) and advance only 1 byte
      codePoint = 0xFFFD
      bytesPerSequence = 1
    } else if (codePoint > 0xFFFF) {
      // encode to utf16 (surrogate pair dance)
      codePoint -= 0x10000
      res.push(codePoint >>> 10 & 0x3FF | 0xD800)
      codePoint = 0xDC00 | codePoint & 0x3FF
    }

    res.push(codePoint)
    i += bytesPerSequence
  }

  return decodeCodePointsArray(res)
}

// Based on http://stackoverflow.com/a/22747272/680742, the browser with
// the lowest limit is Chrome, with 0x10000 args.
// We go 1 magnitude less, for safety
var MAX_ARGUMENTS_LENGTH = 0x1000

function decodeCodePointsArray (codePoints) {
  var len = codePoints.length
  if (len <= MAX_ARGUMENTS_LENGTH) {
    return String.fromCharCode.apply(String, codePoints) // avoid extra slice()
  }

  // Decode in chunks to avoid "call stack size exceeded".
  var res = ''
  var i = 0
  while (i < len) {
    res += String.fromCharCode.apply(
      String,
      codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH)
    )
  }
  return res
}

function asciiSlice (buf, start, end) {
  var ret = ''
  end = Math.min(buf.length, end)

  for (var i = start; i < end; ++i) {
    ret += String.fromCharCode(buf[i] & 0x7F)
  }
  return ret
}

function latin1Slice (buf, start, end) {
  var ret = ''
  end = Math.min(buf.length, end)

  for (var i = start; i < end; ++i) {
    ret += String.fromCharCode(buf[i])
  }
  return ret
}

function hexSlice (buf, start, end) {
  var len = buf.length

  if (!start || start < 0) start = 0
  if (!end || end < 0 || end > len) end = len

  var out = ''
  for (var i = start; i < end; ++i) {
    out += toHex(buf[i])
  }
  return out
}

function utf16leSlice (buf, start, end) {
  var bytes = buf.slice(start, end)
  var res = ''
  for (var i = 0; i < bytes.length; i += 2) {
    res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256)
  }
  return res
}

Buffer.prototype.slice = function slice (start, end) {
  var len = this.length
  start = ~~start
  end = end === undefined ? len : ~~end

  if (start < 0) {
    start += len
    if (start < 0) start = 0
  } else if (start > len) {
    start = len
  }

  if (end < 0) {
    end += len
    if (end < 0) end = 0
  } else if (end > len) {
    end = len
  }

  if (end < start) end = start

  var newBuf
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    newBuf = this.subarray(start, end)
    newBuf.__proto__ = Buffer.prototype
  } else {
    var sliceLen = end - start
    newBuf = new Buffer(sliceLen, undefined)
    for (var i = 0; i < sliceLen; ++i) {
      newBuf[i] = this[i + start]
    }
  }

  return newBuf
}

/*
 * Need to make sure that buffer isn't trying to write out of bounds.
 */
function checkOffset (offset, ext, length) {
  if ((offset % 1) !== 0 || offset < 0) throw new RangeError('offset is not uint')
  if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length')
}

Buffer.prototype.readUIntLE = function readUIntLE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) checkOffset(offset, byteLength, this.length)

  var val = this[offset]
  var mul = 1
  var i = 0
  while (++i < byteLength && (mul *= 0x100)) {
    val += this[offset + i] * mul
  }

  return val
}

Buffer.prototype.readUIntBE = function readUIntBE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) {
    checkOffset(offset, byteLength, this.length)
  }

  var val = this[offset + --byteLength]
  var mul = 1
  while (byteLength > 0 && (mul *= 0x100)) {
    val += this[offset + --byteLength] * mul
  }

  return val
}

Buffer.prototype.readUInt8 = function readUInt8 (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 1, this.length)
  return this[offset]
}

Buffer.prototype.readUInt16LE = function readUInt16LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  return this[offset] | (this[offset + 1] << 8)
}

Buffer.prototype.readUInt16BE = function readUInt16BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  return (this[offset] << 8) | this[offset + 1]
}

Buffer.prototype.readUInt32LE = function readUInt32LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return ((this[offset]) |
      (this[offset + 1] << 8) |
      (this[offset + 2] << 16)) +
      (this[offset + 3] * 0x1000000)
}

Buffer.prototype.readUInt32BE = function readUInt32BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return (this[offset] * 0x1000000) +
    ((this[offset + 1] << 16) |
    (this[offset + 2] << 8) |
    this[offset + 3])
}

Buffer.prototype.readIntLE = function readIntLE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) checkOffset(offset, byteLength, this.length)

  var val = this[offset]
  var mul = 1
  var i = 0
  while (++i < byteLength && (mul *= 0x100)) {
    val += this[offset + i] * mul
  }
  mul *= 0x80

  if (val >= mul) val -= Math.pow(2, 8 * byteLength)

  return val
}

Buffer.prototype.readIntBE = function readIntBE (offset, byteLength, noAssert) {
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) checkOffset(offset, byteLength, this.length)

  var i = byteLength
  var mul = 1
  var val = this[offset + --i]
  while (i > 0 && (mul *= 0x100)) {
    val += this[offset + --i] * mul
  }
  mul *= 0x80

  if (val >= mul) val -= Math.pow(2, 8 * byteLength)

  return val
}

Buffer.prototype.readInt8 = function readInt8 (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 1, this.length)
  if (!(this[offset] & 0x80)) return (this[offset])
  return ((0xff - this[offset] + 1) * -1)
}

Buffer.prototype.readInt16LE = function readInt16LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  var val = this[offset] | (this[offset + 1] << 8)
  return (val & 0x8000) ? val | 0xFFFF0000 : val
}

Buffer.prototype.readInt16BE = function readInt16BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 2, this.length)
  var val = this[offset + 1] | (this[offset] << 8)
  return (val & 0x8000) ? val | 0xFFFF0000 : val
}

Buffer.prototype.readInt32LE = function readInt32LE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return (this[offset]) |
    (this[offset + 1] << 8) |
    (this[offset + 2] << 16) |
    (this[offset + 3] << 24)
}

Buffer.prototype.readInt32BE = function readInt32BE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)

  return (this[offset] << 24) |
    (this[offset + 1] << 16) |
    (this[offset + 2] << 8) |
    (this[offset + 3])
}

Buffer.prototype.readFloatLE = function readFloatLE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)
  return ieee754.read(this, offset, true, 23, 4)
}

Buffer.prototype.readFloatBE = function readFloatBE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 4, this.length)
  return ieee754.read(this, offset, false, 23, 4)
}

Buffer.prototype.readDoubleLE = function readDoubleLE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 8, this.length)
  return ieee754.read(this, offset, true, 52, 8)
}

Buffer.prototype.readDoubleBE = function readDoubleBE (offset, noAssert) {
  if (!noAssert) checkOffset(offset, 8, this.length)
  return ieee754.read(this, offset, false, 52, 8)
}

function checkInt (buf, value, offset, ext, max, min) {
  if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance')
  if (value > max || value < min) throw new RangeError('"value" argument is out of bounds')
  if (offset + ext > buf.length) throw new RangeError('Index out of range')
}

Buffer.prototype.writeUIntLE = function writeUIntLE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) {
    var maxBytes = Math.pow(2, 8 * byteLength) - 1
    checkInt(this, value, offset, byteLength, maxBytes, 0)
  }

  var mul = 1
  var i = 0
  this[offset] = value & 0xFF
  while (++i < byteLength && (mul *= 0x100)) {
    this[offset + i] = (value / mul) & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeUIntBE = function writeUIntBE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  byteLength = byteLength | 0
  if (!noAssert) {
    var maxBytes = Math.pow(2, 8 * byteLength) - 1
    checkInt(this, value, offset, byteLength, maxBytes, 0)
  }

  var i = byteLength - 1
  var mul = 1
  this[offset + i] = value & 0xFF
  while (--i >= 0 && (mul *= 0x100)) {
    this[offset + i] = (value / mul) & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeUInt8 = function writeUInt8 (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0)
  if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value)
  this[offset] = (value & 0xff)
  return offset + 1
}

function objectWriteUInt16 (buf, value, offset, littleEndian) {
  if (value < 0) value = 0xffff + value + 1
  for (var i = 0, j = Math.min(buf.length - offset, 2); i < j; ++i) {
    buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>>
      (littleEndian ? i : 1 - i) * 8
  }
}

Buffer.prototype.writeUInt16LE = function writeUInt16LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value & 0xff)
    this[offset + 1] = (value >>> 8)
  } else {
    objectWriteUInt16(this, value, offset, true)
  }
  return offset + 2
}

Buffer.prototype.writeUInt16BE = function writeUInt16BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 8)
    this[offset + 1] = (value & 0xff)
  } else {
    objectWriteUInt16(this, value, offset, false)
  }
  return offset + 2
}

function objectWriteUInt32 (buf, value, offset, littleEndian) {
  if (value < 0) value = 0xffffffff + value + 1
  for (var i = 0, j = Math.min(buf.length - offset, 4); i < j; ++i) {
    buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff
  }
}

Buffer.prototype.writeUInt32LE = function writeUInt32LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset + 3] = (value >>> 24)
    this[offset + 2] = (value >>> 16)
    this[offset + 1] = (value >>> 8)
    this[offset] = (value & 0xff)
  } else {
    objectWriteUInt32(this, value, offset, true)
  }
  return offset + 4
}

Buffer.prototype.writeUInt32BE = function writeUInt32BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 24)
    this[offset + 1] = (value >>> 16)
    this[offset + 2] = (value >>> 8)
    this[offset + 3] = (value & 0xff)
  } else {
    objectWriteUInt32(this, value, offset, false)
  }
  return offset + 4
}

Buffer.prototype.writeIntLE = function writeIntLE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) {
    var limit = Math.pow(2, 8 * byteLength - 1)

    checkInt(this, value, offset, byteLength, limit - 1, -limit)
  }

  var i = 0
  var mul = 1
  var sub = 0
  this[offset] = value & 0xFF
  while (++i < byteLength && (mul *= 0x100)) {
    if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) {
      sub = 1
    }
    this[offset + i] = ((value / mul) >> 0) - sub & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeIntBE = function writeIntBE (value, offset, byteLength, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) {
    var limit = Math.pow(2, 8 * byteLength - 1)

    checkInt(this, value, offset, byteLength, limit - 1, -limit)
  }

  var i = byteLength - 1
  var mul = 1
  var sub = 0
  this[offset + i] = value & 0xFF
  while (--i >= 0 && (mul *= 0x100)) {
    if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) {
      sub = 1
    }
    this[offset + i] = ((value / mul) >> 0) - sub & 0xFF
  }

  return offset + byteLength
}

Buffer.prototype.writeInt8 = function writeInt8 (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80)
  if (!Buffer.TYPED_ARRAY_SUPPORT) value = Math.floor(value)
  if (value < 0) value = 0xff + value + 1
  this[offset] = (value & 0xff)
  return offset + 1
}

Buffer.prototype.writeInt16LE = function writeInt16LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value & 0xff)
    this[offset + 1] = (value >>> 8)
  } else {
    objectWriteUInt16(this, value, offset, true)
  }
  return offset + 2
}

Buffer.prototype.writeInt16BE = function writeInt16BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 8)
    this[offset + 1] = (value & 0xff)
  } else {
    objectWriteUInt16(this, value, offset, false)
  }
  return offset + 2
}

Buffer.prototype.writeInt32LE = function writeInt32LE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000)
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value & 0xff)
    this[offset + 1] = (value >>> 8)
    this[offset + 2] = (value >>> 16)
    this[offset + 3] = (value >>> 24)
  } else {
    objectWriteUInt32(this, value, offset, true)
  }
  return offset + 4
}

Buffer.prototype.writeInt32BE = function writeInt32BE (value, offset, noAssert) {
  value = +value
  offset = offset | 0
  if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000)
  if (value < 0) value = 0xffffffff + value + 1
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    this[offset] = (value >>> 24)
    this[offset + 1] = (value >>> 16)
    this[offset + 2] = (value >>> 8)
    this[offset + 3] = (value & 0xff)
  } else {
    objectWriteUInt32(this, value, offset, false)
  }
  return offset + 4
}

function checkIEEE754 (buf, value, offset, ext, max, min) {
  if (offset + ext > buf.length) throw new RangeError('Index out of range')
  if (offset < 0) throw new RangeError('Index out of range')
}

function writeFloat (buf, value, offset, littleEndian, noAssert) {
  if (!noAssert) {
    checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38)
  }
  ieee754.write(buf, value, offset, littleEndian, 23, 4)
  return offset + 4
}

Buffer.prototype.writeFloatLE = function writeFloatLE (value, offset, noAssert) {
  return writeFloat(this, value, offset, true, noAssert)
}

Buffer.prototype.writeFloatBE = function writeFloatBE (value, offset, noAssert) {
  return writeFloat(this, value, offset, false, noAssert)
}

function writeDouble (buf, value, offset, littleEndian, noAssert) {
  if (!noAssert) {
    checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308)
  }
  ieee754.write(buf, value, offset, littleEndian, 52, 8)
  return offset + 8
}

Buffer.prototype.writeDoubleLE = function writeDoubleLE (value, offset, noAssert) {
  return writeDouble(this, value, offset, true, noAssert)
}

Buffer.prototype.writeDoubleBE = function writeDoubleBE (value, offset, noAssert) {
  return writeDouble(this, value, offset, false, noAssert)
}

// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length)
Buffer.prototype.copy = function copy (target, targetStart, start, end) {
  if (!start) start = 0
  if (!end && end !== 0) end = this.length
  if (targetStart >= target.length) targetStart = target.length
  if (!targetStart) targetStart = 0
  if (end > 0 && end < start) end = start

  // Copy 0 bytes; we're done
  if (end === start) return 0
  if (target.length === 0 || this.length === 0) return 0

  // Fatal error conditions
  if (targetStart < 0) {
    throw new RangeError('targetStart out of bounds')
  }
  if (start < 0 || start >= this.length) throw new RangeError('sourceStart out of bounds')
  if (end < 0) throw new RangeError('sourceEnd out of bounds')

  // Are we oob?
  if (end > this.length) end = this.length
  if (target.length - targetStart < end - start) {
    end = target.length - targetStart + start
  }

  var len = end - start
  var i

  if (this === target && start < targetStart && targetStart < end) {
    // descending copy from end
    for (i = len - 1; i >= 0; --i) {
      target[i + targetStart] = this[i + start]
    }
  } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) {
    // ascending copy from start
    for (i = 0; i < len; ++i) {
      target[i + targetStart] = this[i + start]
    }
  } else {
    Uint8Array.prototype.set.call(
      target,
      this.subarray(start, start + len),
      targetStart
    )
  }

  return len
}

// Usage:
//    buffer.fill(number[, offset[, end]])
//    buffer.fill(buffer[, offset[, end]])
//    buffer.fill(string[, offset[, end]][, encoding])
Buffer.prototype.fill = function fill (val, start, end, encoding) {
  // Handle string cases:
  if (typeof val === 'string') {
    if (typeof start === 'string') {
      encoding = start
      start = 0
      end = this.length
    } else if (typeof end === 'string') {
      encoding = end
      end = this.length
    }
    if (val.length === 1) {
      var code = val.charCodeAt(0)
      if (code < 256) {
        val = code
      }
    }
    if (encoding !== undefined && typeof encoding !== 'string') {
      throw new TypeError('encoding must be a string')
    }
    if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) {
      throw new TypeError('Unknown encoding: ' + encoding)
    }
  } else if (typeof val === 'number') {
    val = val & 255
  }

  // Invalid ranges are not set to a default, so can range check early.
  if (start < 0 || this.length < start || this.length < end) {
    throw new RangeError('Out of range index')
  }

  if (end <= start) {
    return this
  }

  start = start >>> 0
  end = end === undefined ? this.length : end >>> 0

  if (!val) val = 0

  var i
  if (typeof val === 'number') {
    for (i = start; i < end; ++i) {
      this[i] = val
    }
  } else {
    var bytes = Buffer.isBuffer(val)
      ? val
      : utf8ToBytes(new Buffer(val, encoding).toString())
    var len = bytes.length
    for (i = 0; i < end - start; ++i) {
      this[i + start] = bytes[i % len]
    }
  }

  return this
}

// HELPER FUNCTIONS
// ================

var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g

function base64clean (str) {
  // Node strips out invalid characters like \n and \t from the string, base64-js does not
  str = stringtrim(str).replace(INVALID_BASE64_RE, '')
  // Node converts strings with length < 2 to ''
  if (str.length < 2) return ''
  // Node allows for non-padded base64 strings (missing trailing ===), base64-js does not
  while (str.length % 4 !== 0) {
    str = str + '='
  }
  return str
}

function stringtrim (str) {
  if (str.trim) return str.trim()
  return str.replace(/^\s+|\s+$/g, '')
}

function toHex (n) {
  if (n < 16) return '0' + n.toString(16)
  return n.toString(16)
}

function utf8ToBytes (string, units) {
  units = units || Infinity
  var codePoint
  var length = string.length
  var leadSurrogate = null
  var bytes = []

  for (var i = 0; i < length; ++i) {
    codePoint = string.charCodeAt(i)

    // is surrogate component
    if (codePoint > 0xD7FF && codePoint < 0xE000) {
      // last char was a lead
      if (!leadSurrogate) {
        // no lead yet
        if (codePoint > 0xDBFF) {
          // unexpected trail
          if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
          continue
        } else if (i + 1 === length) {
          // unpaired lead
          if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
          continue
        }

        // valid lead
        leadSurrogate = codePoint

        continue
      }

      // 2 leads in a row
      if (codePoint < 0xDC00) {
        if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
        leadSurrogate = codePoint
        continue
      }

      // valid surrogate pair
      codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000
    } else if (leadSurrogate) {
      // valid bmp char, but last char was a lead
      if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD)
    }

    leadSurrogate = null

    // encode utf8
    if (codePoint < 0x80) {
      if ((units -= 1) < 0) break
      bytes.push(codePoint)
    } else if (codePoint < 0x800) {
      if ((units -= 2) < 0) break
      bytes.push(
        codePoint >> 0x6 | 0xC0,
        codePoint & 0x3F | 0x80
      )
    } else if (codePoint < 0x10000) {
      if ((units -= 3) < 0) break
      bytes.push(
        codePoint >> 0xC | 0xE0,
        codePoint >> 0x6 & 0x3F | 0x80,
        codePoint & 0x3F | 0x80
      )
    } else if (codePoint < 0x110000) {
      if ((units -= 4) < 0) break
      bytes.push(
        codePoint >> 0x12 | 0xF0,
        codePoint >> 0xC & 0x3F | 0x80,
        codePoint >> 0x6 & 0x3F | 0x80,
        codePoint & 0x3F | 0x80
      )
    } else {
      throw new Error('Invalid code point')
    }
  }

  return bytes
}

function asciiToBytes (str) {
  var byteArray = []
  for (var i = 0; i < str.length; ++i) {
    // Node's code seems to be doing this and not & 0x7F..
    byteArray.push(str.charCodeAt(i) & 0xFF)
  }
  return byteArray
}

function utf16leToBytes (str, units) {
  var c, hi, lo
  var byteArray = []
  for (var i = 0; i < str.length; ++i) {
    if ((units -= 2) < 0) break

    c = str.charCodeAt(i)
    hi = c >> 8
    lo = c % 256
    byteArray.push(lo)
    byteArray.push(hi)
  }

  return byteArray
}

function base64ToBytes (str) {
  return base64.toByteArray(base64clean(str))
}

function blitBuffer (src, dst, offset, length) {
  for (var i = 0; i < length; ++i) {
    if ((i + offset >= dst.length) || (i >= src.length)) break
    dst[i + offset] = src[i]
  }
  return i
}

function isnan (val) {
  return val !== val // eslint-disable-line no-self-compare
}

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 117 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingExtension {
    constructor() {
        this.TwingExtensionInterfaceImpl = this;
    }
    getTokenParsers() {
        return [];
    }
    getNodeVisitors() {
        return [];
    }
    getFilters() {
        return new Map();
    }
    getTests() {
        return [];
    }
    getFunctions() {
        return new Map();
    }
    getOperators() {
        return [new Map(), new Map()];
    }
}
exports.TwingExtension = TwingExtension;


/***/ }),
/* 118 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const call_1 = __webpack_require__(159);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionTest extends call_1.TwingNodeExpressionCall {
    constructor(node, name, nodeArguments, lineno, columnno) {
        let nodes = new Map();
        nodes.set('node', node);
        if (nodeArguments !== null) {
            nodes.set('arguments', nodeArguments);
        }
        super(nodes, new Map([['name', name]]), lineno, columnno);
        this.type = node_1.TwingNodeType.EXPRESSION_TEST;
    }
    compile(compiler) {
        let name = this.getAttribute('name');
        let test = compiler.getEnvironment().getTest(name);
        this.setAttribute('name', name);
        this.setAttribute('type', 'test');
        this.setAttribute('arguments', test.getArguments());
        this.setAttribute('callable', test.getCallable());
        this.setAttribute('is_variadic', test.isVariadic());
        super.compileCallable(compiler);
    }
}
exports.TwingNodeExpressionTest = TwingNodeExpressionTest;


/***/ }),
/* 119 */
/***/ (function(module, exports) {

var core = module.exports = { version: '2.6.5' };
if (typeof __e == 'number') __e = core; // eslint-disable-line no-undef


/***/ }),
/* 120 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const source_1 = __webpack_require__(130);
/**
 * Twing base error.
 *
 * This error class and its children must only be used when
 * an error occurs during the loading of a template, when a syntax error
 * is detected in a template, or when rendering a template. Other
 * errors must use regular JavaScript error classes (like when the template
 * cache directory is not writable for instance).
 *
 * To help debugging template issues, this class tracks the original template
 * name and line where the error occurred.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingError extends Error {
    constructor(message, lineno = -1, source = null, previous) {
        super(message);
        this.rawMessage = null;
        this.sourceName = null;
        this.sourcePath = null;
        this.sourceCode = null;
        this.previous = null;
        this.name = 'TwingError';
        this.previous = previous;
        if (previous) {
            this.stack = previous.stack;
        }
        this.rawMessage = message;
        let name;
        if (source === null) {
            name = null;
        }
        else if (!(source instanceof source_1.TwingSource)) {
            name = source;
        }
        else {
            name = source.getName();
            this.sourceCode = source.getCode();
            this.sourcePath = source.getPath();
        }
        this.lineno = lineno;
        this.sourceName = name;
        this.updateRepr();
    }
    getMessage() {
        return this.message;
    }
    /**
     * Gets the raw message.
     *
     * @return string The raw message
     */
    getRawMessage() {
        return this.rawMessage;
    }
    /**
     * Gets the template line where the error occurred.
     *
     * @return int The template line
     */
    getTemplateLine() {
        return this.lineno;
    }
    /**
     * Sets the template line where the error occurred.
     *
     * @param {number} lineno The template line
     */
    setTemplateLine(lineno) {
        this.lineno = lineno;
        this.updateRepr();
    }
    /**
     * Gets the source context of the Twig template where the error occurred.
     *
     * @return TwingSource|null
     */
    getSourceContext() {
        return this.sourceName ? new source_1.TwingSource(this.sourceCode, this.sourceName, this.sourcePath) : null;
    }
    /**
     * Sets the source context of the Twig template where the error occurred.
     */
    setSourceContext(source = null) {
        if (source === null) {
            this.sourceCode = this.sourceName = this.sourcePath = null;
        }
        else {
            this.sourceCode = source.getCode();
            this.sourceName = source.getName();
            this.sourcePath = source.getPath();
        }
        this.updateRepr();
    }
    appendMessage(rawMessage) {
        this.rawMessage += rawMessage;
        this.updateRepr();
    }
    updateRepr() {
        this.message = this.rawMessage;
        let dot = false;
        if (this.message.substr(-1) === '.') {
            this.message = this.message.slice(0, -1);
            dot = true;
        }
        let questionMark = false;
        if (this.message.substr(-1) === '?') {
            this.message = this.message.slice(0, -1);
            questionMark = true;
        }
        if (this.sourceName) {
            let sourceName;
            if (typeof this.sourceName === 'string' || (typeof this.sourceName === 'object' && Reflect.has(this.sourceName, 'toString'))) {
                sourceName = `"${this.sourceName}"`;
            }
            else {
                sourceName = JSON.stringify(this.sourceName);
            }
            this.message += ` in ${sourceName}`;
        }
        if (this.lineno && this.lineno >= 0) {
            this.message += ` at line ${this.lineno}`;
        }
        if (dot) {
            this.message += '.';
        }
        if (questionMark) {
            this.message += '?';
        }
    }
}
exports.TwingError = TwingError;


/***/ }),
/* 121 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlh4AAQAIcAAAAAABAIEBATEBsjHSAYICAgEDA0ECEkIy80OjAoIDAqNDEyMzw6RyA4YCA0cDlBOylBaCJAcTBIYEA4MF1GGlBQMENDRElNU01WTElTWVBIQFBIUFFSU0JXclNcZE11S1FiUFdwV15ma1xtdWBYYGF+VHBoUGVmZW53aHZ+bnR0dCA4gCBAgCBIkDBIgDRQgzFTkTBYoEBYkEBYoEBggEVhl1JpmEdmo0BlsExwolh2rFBwsG13hGBwkHB3hmB4oGB4sEBowFBwwFB40GB4wDuCNz/Rd0CGPEWDQk+cSFGUTFC8WVepe2CRWGOLYWSJdmuZaGejWmCwVmysZWu/YHmlZneucny8ckrVZ13TbED/QGrbdnTGaH7Lc3fWdl+In0yArUeCsF+pr3eBhnqGlmaAr2eDt26Kv3WFpHaMuWe8vFOZxlCE4F2nyF6w02SFwnCIwH6XyHyX02mlwWu2yW/DgmzRkHPegnHWmm3EtGDYpn/FvXrRr3XJy5dtNZBxN7t3MYdqUv8AAJCAYIS9fqaKcKCYcLSXaqCoULCwUIbFdZHHesiRKceWW9GWTs+lU9imWe63ef//AMDAUMDAcOrCaPTYa/bhXuDmcPnjYfjldvDwcIOGhY6RjoSTnpaWloqYqIGTs5CYq5emiJqhqZelt6CggKytrai7p729vYCYwJWnxJer0pqy2Z246KOuwai2yaW41KK74IrDhIPYgZLMiZDThJvWkpzblYTLtYrbu43qnZzivaTIiKHXiaXWlbXemKzXpq/VvbDIsLTeoLDXvaLim6fvsazwtbvhpbTvtY7ByYvL15DN25jV2avA36jXy6bZ17HD2bTaxbXe1qnuybrmw7fo1Miqic+4ica1kdKuiNm0h9jAiNjGk9DYgMDIoMLbpdDIoM3nr83ns9bst9zwvu3NjezHmuLVm/bPpvTauPDggProov/wsMXGxc3S0tnay9fY2MDO7sHQ58DQ8Mrp0NPtztfu1Nryw+X0xvTgwv3s3PD4wOjo6PHx8SH5BAMAAFoALAAAAADgABAAAAj/ALUIHEiwoMGDCBMqXMiwocOHECM6fHbm4KaLFwtg3CQx4a0uXELe6kiyZEE4JlOqXMkQzg6LGzViFKgqVBqSv7gkI2dtmrBgVGqxHJrwDQwiDN+8AbIjxsAhDlvBiUW0qsIdO24YRFSgAKJNXb1yVIWG1SoaWuKoXctWrdaBtnzpw3ePGrVo0KDNumJ1JawTA43CaMGC4Q4YhQWyETIQgOPHjwXCYbNCIGTIjS9rdmx5s+bOnjEbjHNmBgxWBTFlBLuJK6ZV/+h16CEh7b/buHPPe6sFly9z+fDZixatGbNlwhYRIiigufMBnhguWKBg+kHnArRgT7jhwSuSiQfi/2jVUNYKVX3TD9SaA0aNgonCsgb77fa8ULVtz9td70a9/v7xxoU5yiBjzTXOOEMHHbngMk4SBMFywAbZlXLAAtEtZMEDCcGyAQewaAELBxuEiNADG64UhAwwVBUaAAi9GGNoBrGigxaywAADeQPJpJFGiFTQzz/zrJKffv79l6SSAt0CDDnHVGMPM8y4oQYed2zxSy9WMEdCdtpxcMBCr2zwHXcbDLRBmgjxwMN0ojR0pnp0rnSjQCzaQBAiBhhQwCRdVSAOkUYSFMc/N8zzn5L15LANN5Bo0UU5xuxyjT0L9rEFFlhkcUU4SnhZ4QALkLEQCSQsxAEHA62akAVaXP+wAKwLSQNAnAixMUQcDUnF40IvihZsZFoMyxlBz8xwQw03wOCCAwRttAkmlAwDzzylHCnQofwxGs856PCzTiMD0rIFL9C0oYYuehiBxRJTjHOElwsIMIAAHkijUCknlLIQBhgMBDBConigRSnT+asQDwBcoFArM4D2mRaTVVbsZnV2ZEYOsbDCSiwuRKCnQBthYog74HSA32hE7sbfO+m0A6463AzYhR28tOHGGnTwkYcYTEQxThEEBUBAAAcHIICpCRFAAENKDyQA0geRcCYCCxisEAIMm2iQKzigxlArK9zEkIwHoW2Q2ngWVIYDERx0sjvsmAJmQdwuWg88MWv/Ygkk3GhxxTi26LLHF5yQMgYYYYxBCiejIFH0AVQHMMCYBBPAtEIBUK1F5wdJs8AFpD+gwAD6IrSKB7EAwANCQszwQsa0G6TDCx0MpEoDEUQAgUGDDGKCBgkgdOgNyN9ASt+XVHKIQLX8QkwdT3TijzzvjDGGPNh3EsJApQQwAYylCKA5QrE47XVCDAjgb/kKHCSCB6+U8gosp2t9kAce8HDA07W72LAkhjZjwWggz4gFVQaiwFis7yHcUtQ7vNEOTTRvG7yRQjmaoAJ4jOACJ+iECk6wgRS8QwWZgUwANleQARDgfy5cSCwy8JgMLLAgHCKIDwhQPIQgQCBkAIDC9QoyhCHgoCGs+MEqAlgSQTjxiVCMoiAkQcUqWvGKkrAN8kiRjW5YsBKF2M1AZqEIFHACHnOwQCrgkYpTWKAK7+AEExEiDREgIIda8MQB9hg/g2TgAP7yAQAAeZAhiI1GWviBEKAlwMukEGNpQ+TaaCTFSj4Ri5isYloWdYh9OIIRj8DGfnijhSmUAAUetIAFVqVKEJywTpIUCCxmGaFZPjAicmgRQ1jhgFDMsSOWtGQmM5mW5P1BHZEARCCSR0otQAEDnTjFKT6hAhV8QpqfAMwvaxe7X23TKsGs5DAxWRAK+KER2lgIKjBwgnZ+wAkqQEE7tRAQADs="

/***/ }),
/* 122 */
/***/ (function(module, exports) {

// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
var global = module.exports = typeof window != 'undefined' && window.Math == Math
  ? window : typeof self != 'undefined' && self.Math == Math ? self
  // eslint-disable-next-line no-new-func
  : Function('return this')();
if (typeof __g == 'number') __g = global; // eslint-disable-line no-undef


/***/ }),
/* 123 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Default base class for compiled templates.
 *
 * This class is an implementation detail of how template compilation currently
 * works, which might change. It should never be used directly. Use twig.load()
 * instead, which returns an instance of TwingTemplateWrapper.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 *
 * @internal
 */
const runtime_1 = __webpack_require__(153);
const source_1 = __webpack_require__(130);
const error_1 = __webpack_require__(120);
const template_wrapper_1 = __webpack_require__(188);
const output_buffering_1 = __webpack_require__(131);
const iterator_to_map_1 = __webpack_require__(128);
const merge_1 = __webpack_require__(135);
const context_1 = __webpack_require__(264);
const is_map_1 = __webpack_require__(147);
class TwingTemplate {
    constructor(env) {
        this.parent = null;
        this.parents = new Map();
        this.blocks = new Map();
        this.traits = new Map();
        /**
         * @internal
         */
        this.extensions = new Map();
        this.env = env;
        this.extensions = env.getExtensions();
    }
    /**
     * @internal this method will be removed in 2.0 and is only used internally to provide an upgrade path from 1.x to 2.0
     */
    toString() {
        return this.getTemplateName();
    }
    /**
     * Returns information about the original template source code.
     *
     * @return TwingSource
     */
    getSourceContext() {
        return new source_1.TwingSource('', this.getTemplateName());
    }
    /**
     * Returns the parent template.
     *
     * @param context
     *
     * @returns TwingTemplate|TwingTemplateWrapper|false The parent template or false if there is no parent
     */
    getParent(context = {}) {
        if (this.parent !== null) {
            return this.parent;
        }
        let parent;
        try {
            parent = this.doGetParent(context);
            if (parent === false) {
                return false;
            }
            if (parent instanceof TwingTemplate || parent instanceof template_wrapper_1.TwingTemplateWrapper) {
                this.parents.set(parent.getSourceContext().getName(), parent);
            }
            if (!this.parents.has(parent)) {
                this.parents.set(parent, this.loadTemplate(parent));
            }
        }
        catch (e) {
            if (e instanceof error_1.TwingError) {
                e.setSourceContext(null);
            }
            throw e;
        }
        return this.parents.get(parent);
    }
    isTraitable() {
        return true;
    }
    /**
     * Displays a parent block.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @param {string} name The block name to display from the parent
     * @param context The context
     * @param {Map<string, TwingNodeBlock>} blocks The active set of blocks
     * @returns {string}
     *
     * @internal
     */
    displayParentBlock(name, context, blocks = new Map()) {
        let parent;
        if (this.traits.has(name)) {
            this.traits.get(name)[0].displayBlock(name, context, blocks, false);
        }
        else if ((parent = this.getParent(context)) !== false) {
            parent.displayBlock(name, context, blocks, false);
        }
        else {
            throw new runtime_1.TwingErrorRuntime(`The template has no parent and no traits defining the "${name}" block.`, -1, this.getSourceContext());
        }
    }
    /**
     * Displays a block.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @param {string} name The block name to display
     * @param context The context
     * @param {Map<string, Array<*>>} blocks The active set of blocks
     * @param {boolean} useBlocks Whether to use the active set of blocks
     *
     * @internal
     */
    displayBlock(name, context, blocks = new Map(), useBlocks = true) {
        let block;
        let template;
        let parent;
        if (useBlocks && blocks.has(name)) {
            template = blocks.get(name)[0];
            block = blocks.get(name)[1];
        }
        else if (this.blocks.has(name)) {
            template = this.blocks.get(name)[0];
            block = this.blocks.get(name)[1];
        }
        else {
            template = null;
            block = null;
        }
        if (template !== null) {
            Reflect.get(template, block).call(template, context, blocks);
        }
        else if ((parent = this.getParent(context)) !== false) {
            parent.displayBlock(name, context, merge_1.merge(this.blocks, blocks), false);
        }
        else if (blocks.has(name)) {
            throw new runtime_1.TwingErrorRuntime(`Block "${name}" should not call parent() in "${blocks.get(name)[0].getTemplateName()}" as the block does not exist in the parent template "${this.getTemplateName()}".`, -1, blocks.get(name)[0].getSourceContext());
        }
        else {
            throw new runtime_1.TwingErrorRuntime(`Block "${name}" on template "${this.getTemplateName()}" does not exist.`, -1, this.getSourceContext());
        }
    }
    /**
     * Renders a parent block.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @param {string} name The block name to display from the parent
     * @param {*} context The context
     * @param {Map<string, Array<any>>} blocks The active set of blocks
     *
     * @returns string The rendered block
     *
     * @internal
     */
    renderParentBlock(name, context, blocks = new Map()) {
        output_buffering_1.TwingOutputBuffering.obStart();
        this.displayParentBlock(name, context, blocks);
        return output_buffering_1.TwingOutputBuffering.obGetClean();
    }
    /**
     * Renders a block.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @param {string} name The block name to display
     * @param context The context
     * @param {Map<string, Array<*>>} blocks The active set of blocks
     * @param {boolean} useBlocks Whether to use the active set of blocks
     *
     * @return string The rendered block
     *
     * @internal
     */
    renderBlock(name, context, blocks = new Map(), useBlocks = true) {
        output_buffering_1.TwingOutputBuffering.obStart();
        this.displayBlock(name, context, blocks, useBlocks);
        return output_buffering_1.TwingOutputBuffering.obGetClean();
    }
    /**
     * Returns whether a block exists or not in the active context of the template.
     *
     * This method checks blocks defined in the active template
     * or defined in "used" traits or defined in parent templates.
     *
     * @param {string} name The block name
     * @param context The context
     * @param {Map<string, Array<*>>} blocks The active set of blocks
     *
     * @returns {boolean} true if the block exists, false otherwise
     */
    hasBlock(name, context, blocks = new Map()) {
        if (blocks.has(name)) {
            return blocks.get(name)[0] instanceof TwingTemplate;
        }
        if (this.blocks.has(name)) {
            return true;
        }
        let parent = this.getParent(context);
        if (parent) {
            return parent.hasBlock(name, context);
        }
        return false;
    }
    /**
     * Returns all block names in the active context of the template.
     *
     * This method checks blocks defined in the active template
     * or defined in "used" traits or defined in parent templates.
     *
     * @param context The context
     * @param {Map<string, Array<*>>} blocks The active set of blocks
     * @returns {Array<string>}
     */
    getBlockNames(context, blocks = new Map()) {
        let names = new Set([...blocks.keys(), ...this.blocks.keys()]);
        let parent = this.getParent(context);
        if (parent) {
            names = new Set([...names, ...parent.getBlockNames(context)]);
        }
        return [...names];
    }
    loadTemplate(template, templateName = null, line = null, index = null) {
        try {
            if (Array.isArray(template)) {
                return this.env.resolveTemplate(template, this.getSourceContext());
            }
            if (template instanceof TwingTemplate || template instanceof template_wrapper_1.TwingTemplateWrapper) {
                return template;
            }
            return this.env.loadTemplate(template, index, this.getSourceContext());
        }
        catch (e) {
            if (e instanceof error_1.TwingError) {
                if (!e.getSourceContext()) {
                    let source = this.getSourceContext();
                    e.setSourceContext(templateName ? new source_1.TwingSource(source.getCode(), templateName, source.getPath()) : source);
                }
                if (e.getTemplateLine() !== -1) {
                    throw e;
                }
                if (line) {
                    e.setTemplateLine(line);
                }
            }
            throw e;
        }
    }
    /**
     * Returns all blocks.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @returns {Map<string, Array<*>>} An array of blocks
     *
     * @internal
     */
    getBlocks() {
        return this.blocks;
    }
    display(context, blocks = new Map()) {
        if (context === null) {
            throw new TypeError('Argument 1 passed to TwingTemplate::display() must be an iterator, null given');
        }
        if (!is_map_1.isMap(context)) {
            context = iterator_to_map_1.iteratorToMap(context);
        }
        context = new context_1.TwingContext(this.env.mergeGlobals(context));
        this.displayWithErrorHandling(context, merge_1.merge(this.blocks, blocks));
    }
    render(context) {
        let level = output_buffering_1.TwingOutputBuffering.obGetLevel();
        output_buffering_1.TwingOutputBuffering.obStart();
        try {
            this.display(context);
        }
        catch (e) {
            while (output_buffering_1.TwingOutputBuffering.obGetLevel() > level) {
                output_buffering_1.TwingOutputBuffering.obEndClean();
            }
            throw e;
        }
        return output_buffering_1.TwingOutputBuffering.obGetClean();
    }
    doGetParent(context) {
        return false;
    }
    displayWithErrorHandling(context, blocks = new Map()) {
        try {
            this.doDisplay(context, blocks);
        }
        catch (e) {
            if (e instanceof error_1.TwingError) {
                if (!e.getSourceContext()) {
                    e.setSourceContext(this.getSourceContext());
                }
                throw e;
            }
            throw new runtime_1.TwingErrorRuntime(`An exception has been thrown during the rendering of a template ("${e.message}").`, -1, this.getSourceContext(), e);
        }
    }
    traceableMethod(method, lineno, source) {
        return function () {
            try {
                return method.apply(null, arguments);
            }
            catch (e) {
                if (e instanceof error_1.TwingError) {
                    if (e.getTemplateLine() === -1) {
                        e.setTemplateLine(lineno);
                        e.setSourceContext(source);
                    }
                }
                else {
                    e = new runtime_1.TwingErrorRuntime(`An exception has been thrown during the rendering of a template ("${e.message}").`, lineno, source, e);
                }
                throw e;
            }
        };
    }
    ;
    traceableDisplayBlock(lineno, source) {
        return this.traceableMethod(this.displayBlock.bind(this), lineno, source);
    }
    ;
    traceableDisplayParentBlock(lineno, source) {
        return this.traceableMethod(this.displayParentBlock.bind(this), lineno, source);
    }
    ;
    traceableRenderBlock(lineno, source) {
        return this.traceableMethod(this.renderBlock.bind(this), lineno, source);
    }
    traceableRenderParentBlock(lineno, source) {
        return this.traceableMethod(this.renderParentBlock.bind(this), lineno, source);
    }
    traceableHasBlock(lineno, source) {
        return this.traceableMethod(this.hasBlock.bind(this), lineno, source);
    }
}
exports.TwingTemplate = TwingTemplate;
TwingTemplate.ANY_CALL = 'any';
TwingTemplate.ARRAY_CALL = 'array';
TwingTemplate.METHOD_CALL = 'method';


/***/ }),
/* 124 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodePrint extends node_1.TwingNode {
    constructor(expr, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('expr', expr);
        super(nodes, new Map(), lineno, columnno, tag);
        this.TwingNodeOutputInterfaceImpl = this;
        this.type = node_1.TwingNodeType.PRINT;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .addSourceMapEnter(this)
            .write('Runtime.echo(')
            .subcompile(this.getNode('expr'))
            .raw(');\n')
            .addSourceMapLeave();
    }
}
exports.TwingNodePrint = TwingNodePrint;


/***/ }),
/* 125 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const error_1 = __webpack_require__(120);
/**
 * Exception thrown when a security error occurs at runtime.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingSandboxSecurityError extends error_1.TwingError {
}
exports.TwingSandboxSecurityError = TwingSandboxSecurityError;


/***/ }),
/* 126 */
/***/ (function(module, exports, __webpack_require__) {

var store = __webpack_require__(402)('wks');
var uid = __webpack_require__(380);
var Symbol = __webpack_require__(122).Symbol;
var USE_SYMBOL = typeof Symbol == 'function';

var $exports = module.exports = function (name) {
  return store[name] || (store[name] =
    USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));
};

$exports.store = store;


/***/ }),
/* 127 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(process) {/* eslint-disable node/no-deprecated-api */



var buffer = __webpack_require__(116)
var Buffer = buffer.Buffer

var safer = {}

var key

for (key in buffer) {
  if (!buffer.hasOwnProperty(key)) continue
  if (key === 'SlowBuffer' || key === 'Buffer') continue
  safer[key] = buffer[key]
}

var Safer = safer.Buffer = {}
for (key in Buffer) {
  if (!Buffer.hasOwnProperty(key)) continue
  if (key === 'allocUnsafe' || key === 'allocUnsafeSlow') continue
  Safer[key] = Buffer[key]
}

safer.Buffer.prototype = Buffer.prototype

if (!Safer.from || Safer.from === Uint8Array.from) {
  Safer.from = function (value, encodingOrOffset, length) {
    if (typeof value === 'number') {
      throw new TypeError('The "value" argument must not be of type number. Received type ' + typeof value)
    }
    if (value && typeof value.length === 'undefined') {
      throw new TypeError('The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type ' + typeof value)
    }
    return Buffer(value, encodingOrOffset, length)
  }
}

if (!Safer.alloc) {
  Safer.alloc = function (size, fill, encoding) {
    if (typeof size !== 'number') {
      throw new TypeError('The "size" argument must be of type number. Received type ' + typeof size)
    }
    if (size < 0 || size >= 2 * (1 << 30)) {
      throw new RangeError('The value "' + size + '" is invalid for option "size"')
    }
    var buf = Buffer(size)
    if (!fill || fill.length === 0) {
      buf.fill(0)
    } else if (typeof encoding === 'string') {
      buf.fill(fill, encoding)
    } else {
      buf.fill(fill)
    }
    return buf
  }
}

if (!safer.kStringMaxLength) {
  try {
    safer.kStringMaxLength = process.binding('buffer').kStringMaxLength
  } catch (e) {
    // we can't determine kStringMaxLength in environments where process.binding
    // is unsupported, so let's not set it
  }
}

if (!safer.constants) {
  safer.constants = {
    MAX_LENGTH: safer.kMaxLength
  }
  if (safer.kStringMaxLength) {
    safer.constants.MAX_STRING_LENGTH = safer.kStringMaxLength
  }
}

module.exports = safer

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(22)))

/***/ }),
/* 128 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Converts input to Map.
 *
 * @param {*} thing
 * @returns {Map<any, any>}
 */
function iteratorToMap(thing) {
    if (thing.entries) {
        return new Map(thing.entries());
    }
    else {
        let result = new Map();
        if (typeof thing[Symbol.iterator] === 'function') {
            let i = 0;
            for (let value of thing) {
                result.set(i++, value);
            }
        }
        else if (typeof thing['next'] === 'function') {
            let i = 0;
            let next;
            while ((next = thing.next()) && !next.done) {
                result.set(i++, next.value);
            }
        }
        else {
            for (let k in thing) {
                result.set(k, thing[k]);
            }
        }
        return result;
    }
}
exports.iteratorToMap = iteratorToMap;


/***/ }),
/* 129 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingBaseNodeVisitor {
    constructor() {
        this.TwingNodeVisitorInterfaceImpl = this;
    }
    /**
     * Called before child nodes are visited.
     *
     * @returns {TwingNode} The modified node
     */
    enterNode(node, env) {
        return this.doEnterNode(node, env);
    }
    /**
     * Called after child nodes are visited.
     *
     * @returns {TwingNode|false} The modified node or null if the node must be removed
     */
    leaveNode(node, env) {
        return this.doLeaveNode(node, env);
    }
}
exports.TwingBaseNodeVisitor = TwingBaseNodeVisitor;


/***/ }),
/* 130 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingSource {
    constructor(code, name, path = '') {
        this.code = code;
        this.name = name;
        this.path = path;
    }
    getCode() {
        return this.code;
    }
    getName() {
        return this.name;
    }
    getPath() {
        return this.path;
    }
}
exports.TwingSource = TwingSource;


/***/ }),
/* 131 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(process) {
Object.defineProperty(exports, "__esModule", { value: true });
const util_1 = __webpack_require__(133);
class TwingOutputHandler {
    /**
     * @param level
     * @param flags Unused, kept for backward compatibility
     */
    constructor(level, flags) {
        this.content = '';
        this.level = level;
    }
    getContent() {
        return this.content;
    }
    write(value) {
        this.content = value;
    }
    append(value) {
        this.content += value;
    }
}
exports.TwingOutputHandler = TwingOutputHandler;
class TwingOutputBuffering {
    static echo(string) {
        if (typeof string === 'boolean') {
            string = (string === true) ? '1' : '';
        }
        else if (util_1.isNullOrUndefined(string)) {
            string = '';
        }
        return TwingOutputBuffering.outputWrite(string);
    }
    /**
     * Turn on Output Buffering (specifying an optional output handler).
     *
     * @returns {boolean}
     */
    static obStart() {
        let handler = new TwingOutputHandler(TwingOutputBuffering.obGetLevel() + 1, 0);
        TwingOutputBuffering.handlers.push(handler);
        return true;
    }
    /**
     * Flush (send) contents of the output buffer. The last buffer content is sent to next buffer
     *
     * In human terms, append the top-most buffer to the second-top-most buffer and empty the top-most buffer
     *
     * ┌─────────┐    ┌─────────┐
     * │   oof   │    │         │
     * ├─────────┤    ├─────────┤
     * │   bar   │ => │  baroof │
     * ├─────────┤    ├─────────┤
     * │   foo   │    │   foo   │ => true
     * └─────────┘    └─────────┘
     *
     */
    static obFlush() {
        let active = TwingOutputBuffering.getActive();
        if (!active) {
            process.stdout.write('Failed to flush buffer: no buffer to flush.');
            return false;
        }
        TwingOutputBuffering.handlers.pop();
        TwingOutputBuffering.outputWrite(active.getContent());
        active.write('');
        TwingOutputBuffering.handlers.push(active);
        return true;
    }
    /**
     * Alias for TwingOutputBuffering.obFlush
     *
     * @returns {boolean}
     */
    static flush() {
        return TwingOutputBuffering.obFlush();
    }
    /**
     * Flush (send) the output buffer, and delete current output buffer
     *
     * In human terms: append the top-most buffer to the second-top-most buffer and remove the top-most buffer
     *
     * ┌─────────┐
     * │   oof   │
     * ├─────────┤    ┌─────────┐
     * │   bar   │ -> │  baroof │
     * ├─────────┤    ├─────────┤
     * │   foo   │    │   foo   │ => true
     * └─────────┘    └─────────┘
     *
     * @returns {boolean}
     */
    static obEndFlush() {
        if (!TwingOutputBuffering.getActive()) {
            process.stdout.write('Failed to delete and flush buffer: no buffer to delete or flush.');
            return false;
        }
        TwingOutputBuffering.obFlush();
        TwingOutputBuffering.handlers.pop();
        return true;
    }
    /**
     * Get active buffer contents, flush (send) the output buffer, and delete active output buffer
     *
     * In human terms: append the top-most buffer to the second-top-most buffer, remove the top-most buffer and returns its content
     *
     * ┌─────────┐
     * │   oof   │
     * ├─────────┤    ┌─────────┐
     * │   bar   │ -> │  baroof │
     * ├─────────┤    ├─────────┤
     * │   foo   │    │   foo   │ => oof
     * └─────────┘    └─────────┘
     *
     * @returns {string | false}
     */
    static obGetFlush() {
        let content = TwingOutputBuffering.obGetContents();
        TwingOutputBuffering.obEndFlush();
        return content;
    }
    /**
     * Clean (erase) the output buffer
     *
     * In human terms, empty the top-most buffer
     *
     * ┌─────────┐    ┌─────────┐
     * │   oof   │    │         │
     * ├─────────┤    ├─────────┤
     * │   bar   │ => │   bar   │
     * ├─────────┤    ├─────────┤
     * │   foo   │    │   foo   │ => true
     * └─────────┘    └─────────┘
     *
     */
    static obClean() {
        let active = TwingOutputBuffering.getActive();
        if (!active) {
            process.stdout.write('Failed to clean buffer: no buffer to clean.');
            return false;
        }
        active.write('');
        return true;
    }
    /**
     * Clean the output buffer, and delete active output buffer
     *
     * In human terms: clean the top-most buffer and remove the top-most buffer
     *
     * ┌─────────┐
     * │   oof   │
     * ├─────────┤    ┌─────────┐
     * │   bar   │ -> │   bar   │
     * ├─────────┤    ├─────────┤
     * │   foo   │    │   foo   │ => true
     * └─────────┘    └─────────┘
     *
     * @returns {boolean}
     */
    static obEndClean() {
        if (TwingOutputBuffering.obClean()) {
            TwingOutputBuffering.handlers.pop();
            return true;
        }
        return false;
    }
    /**
     * Get active buffer contents and delete active output buffer
     *
     * In human terms: Remove the top-most buffer and returns its content
     *
     * ┌─────────┐
     * │   oof   │
     * ├─────────┤    ┌─────────┐
     * │   bar   │ -> │   bar   │
     * ├─────────┤    ├─────────┤
     * │   foo   │    │   foo   │ => oof
     * └─────────┘    └─────────┘
     *
     * @returns {string | false}
     */
    static obGetClean() {
        let content = TwingOutputBuffering.obGetContents();
        TwingOutputBuffering.obEndClean();
        return content;
    }
    /**
     * Return the nesting level of the output buffering mechanism
     *
     * @returns {number}
     */
    static obGetLevel() {
        return TwingOutputBuffering.handlers.length;
    }
    /**
     * Return the contents of the output buffer
     *
     * @returns {string | false}
     */
    static obGetContents() {
        return TwingOutputBuffering.getActive() ? TwingOutputBuffering.getActive().getContent() : false;
    }
    /**
     * Append the string to the top-most buffer or return  the string if there is none
     *
     * @param {string} string | void
     */
    static outputWrite(string) {
        let active = TwingOutputBuffering.getActive();
        if (active) {
            active.append(string);
        }
        else {
            if (process && process.stdout) {
                process.stdout.write(string);
            }
            else {
                console.log(string);
            }
        }
    }
    static getActive() {
        if (TwingOutputBuffering.handlers.length > 0) {
            return TwingOutputBuffering.handlers[TwingOutputBuffering.handlers.length - 1];
        }
        else {
            return null;
        }
    }
}
exports.TwingOutputBuffering = TwingOutputBuffering;
TwingOutputBuffering.handlers = [];
exports.echo = TwingOutputBuffering.echo;
exports.obStart = TwingOutputBuffering.obStart;
exports.obEndClean = TwingOutputBuffering.obEndClean;
exports.obGetClean = TwingOutputBuffering.obGetClean;
exports.obGetContents = TwingOutputBuffering.obGetContents;
exports.flush = TwingOutputBuffering.flush;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(22)))

/***/ }),
/* 132 */
/***/ (function(module, exports, __webpack_require__) {

var global = __webpack_require__(122);
var core = __webpack_require__(119);
var ctx = __webpack_require__(381);
var hide = __webpack_require__(173);
var has = __webpack_require__(171);
var PROTOTYPE = 'prototype';

var $export = function (type, name, source) {
  var IS_FORCED = type & $export.F;
  var IS_GLOBAL = type & $export.G;
  var IS_STATIC = type & $export.S;
  var IS_PROTO = type & $export.P;
  var IS_BIND = type & $export.B;
  var IS_WRAP = type & $export.W;
  var exports = IS_GLOBAL ? core : core[name] || (core[name] = {});
  var expProto = exports[PROTOTYPE];
  var target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE];
  var key, own, out;
  if (IS_GLOBAL) source = name;
  for (key in source) {
    // contains in native
    own = !IS_FORCED && target && target[key] !== undefined;
    if (own && has(exports, key)) continue;
    // export native or passed
    out = own ? target[key] : source[key];
    // prevent global pollution for namespaces
    exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key]
    // bind timers to global for call from export context
    : IS_BIND && own ? ctx(out, global)
    // wrap global constructors for prevent change them in library
    : IS_WRAP && target[key] == out ? (function (C) {
      var F = function (a, b, c) {
        if (this instanceof C) {
          switch (arguments.length) {
            case 0: return new C();
            case 1: return new C(a);
            case 2: return new C(a, b);
          } return new C(a, b, c);
        } return C.apply(this, arguments);
      };
      F[PROTOTYPE] = C[PROTOTYPE];
      return F;
    // make static versions for prototype methods
    })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
    // export proto methods to core.%CONSTRUCTOR%.methods.%NAME%
    if (IS_PROTO) {
      (exports.virtual || (exports.virtual = {}))[key] = out;
      // export proto methods to core.%CONSTRUCTOR%.prototype.%NAME%
      if (type & $export.R && expProto && !expProto[key]) hide(expProto, key, out);
    }
  }
};
// type bitmap
$export.F = 1;   // forced
$export.G = 2;   // global
$export.S = 4;   // static
$export.P = 8;   // proto
$export.B = 16;  // bind
$export.W = 32;  // wrap
$export.U = 64;  // safe
$export.R = 128; // real proto method for `library`
module.exports = $export;


/***/ }),
/* 133 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.

var getOwnPropertyDescriptors = Object.getOwnPropertyDescriptors ||
  function getOwnPropertyDescriptors(obj) {
    var keys = Object.keys(obj);
    var descriptors = {};
    for (var i = 0; i < keys.length; i++) {
      descriptors[keys[i]] = Object.getOwnPropertyDescriptor(obj, keys[i]);
    }
    return descriptors;
  };

var formatRegExp = /%[sdj%]/g;
exports.format = function(f) {
  if (!isString(f)) {
    var objects = [];
    for (var i = 0; i < arguments.length; i++) {
      objects.push(inspect(arguments[i]));
    }
    return objects.join(' ');
  }

  var i = 1;
  var args = arguments;
  var len = args.length;
  var str = String(f).replace(formatRegExp, function(x) {
    if (x === '%%') return '%';
    if (i >= len) return x;
    switch (x) {
      case '%s': return String(args[i++]);
      case '%d': return Number(args[i++]);
      case '%j':
        try {
          return JSON.stringify(args[i++]);
        } catch (_) {
          return '[Circular]';
        }
      default:
        return x;
    }
  });
  for (var x = args[i]; i < len; x = args[++i]) {
    if (isNull(x) || !isObject(x)) {
      str += ' ' + x;
    } else {
      str += ' ' + inspect(x);
    }
  }
  return str;
};


// Mark that a method should not be used.
// Returns a modified function which warns once by default.
// If --no-deprecation is set, then it is a no-op.
exports.deprecate = function(fn, msg) {
  if (typeof process !== 'undefined' && process.noDeprecation === true) {
    return fn;
  }

  // Allow for deprecating things in the process of starting up.
  if (typeof process === 'undefined') {
    return function() {
      return exports.deprecate(fn, msg).apply(this, arguments);
    };
  }

  var warned = false;
  function deprecated() {
    if (!warned) {
      if (process.throwDeprecation) {
        throw new Error(msg);
      } else if (process.traceDeprecation) {
        console.trace(msg);
      } else {
        console.error(msg);
      }
      warned = true;
    }
    return fn.apply(this, arguments);
  }

  return deprecated;
};


var debugs = {};
var debugEnviron;
exports.debuglog = function(set) {
  if (isUndefined(debugEnviron))
    debugEnviron = process.env.NODE_DEBUG || '';
  set = set.toUpperCase();
  if (!debugs[set]) {
    if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
      var pid = process.pid;
      debugs[set] = function() {
        var msg = exports.format.apply(exports, arguments);
        console.error('%s %d: %s', set, pid, msg);
      };
    } else {
      debugs[set] = function() {};
    }
  }
  return debugs[set];
};


/**
 * Echos the value of a value. Trys to print the value out
 * in the best way possible given the different types.
 *
 * @param {Object} obj The object to print out.
 * @param {Object} opts Optional options object that alters the output.
 */
/* legacy: obj, showHidden, depth, colors*/
function inspect(obj, opts) {
  // default options
  var ctx = {
    seen: [],
    stylize: stylizeNoColor
  };
  // legacy...
  if (arguments.length >= 3) ctx.depth = arguments[2];
  if (arguments.length >= 4) ctx.colors = arguments[3];
  if (isBoolean(opts)) {
    // legacy...
    ctx.showHidden = opts;
  } else if (opts) {
    // got an "options" object
    exports._extend(ctx, opts);
  }
  // set default options
  if (isUndefined(ctx.showHidden)) ctx.showHidden = false;
  if (isUndefined(ctx.depth)) ctx.depth = 2;
  if (isUndefined(ctx.colors)) ctx.colors = false;
  if (isUndefined(ctx.customInspect)) ctx.customInspect = true;
  if (ctx.colors) ctx.stylize = stylizeWithColor;
  return formatValue(ctx, obj, ctx.depth);
}
exports.inspect = inspect;


// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics
inspect.colors = {
  'bold' : [1, 22],
  'italic' : [3, 23],
  'underline' : [4, 24],
  'inverse' : [7, 27],
  'white' : [37, 39],
  'grey' : [90, 39],
  'black' : [30, 39],
  'blue' : [34, 39],
  'cyan' : [36, 39],
  'green' : [32, 39],
  'magenta' : [35, 39],
  'red' : [31, 39],
  'yellow' : [33, 39]
};

// Don't use 'blue' not visible on cmd.exe
inspect.styles = {
  'special': 'cyan',
  'number': 'yellow',
  'boolean': 'yellow',
  'undefined': 'grey',
  'null': 'bold',
  'string': 'green',
  'date': 'magenta',
  // "name": intentionally not styling
  'regexp': 'red'
};


function stylizeWithColor(str, styleType) {
  var style = inspect.styles[styleType];

  if (style) {
    return '\u001b[' + inspect.colors[style][0] + 'm' + str +
           '\u001b[' + inspect.colors[style][1] + 'm';
  } else {
    return str;
  }
}


function stylizeNoColor(str, styleType) {
  return str;
}


function arrayToHash(array) {
  var hash = {};

  array.forEach(function(val, idx) {
    hash[val] = true;
  });

  return hash;
}


function formatValue(ctx, value, recurseTimes) {
  // Provide a hook for user-specified inspect functions.
  // Check that value is an object with an inspect function on it
  if (ctx.customInspect &&
      value &&
      isFunction(value.inspect) &&
      // Filter out the util module, it's inspect function is special
      value.inspect !== exports.inspect &&
      // Also filter out any prototype objects using the circular check.
      !(value.constructor && value.constructor.prototype === value)) {
    var ret = value.inspect(recurseTimes, ctx);
    if (!isString(ret)) {
      ret = formatValue(ctx, ret, recurseTimes);
    }
    return ret;
  }

  // Primitive types cannot have properties
  var primitive = formatPrimitive(ctx, value);
  if (primitive) {
    return primitive;
  }

  // Look up the keys of the object.
  var keys = Object.keys(value);
  var visibleKeys = arrayToHash(keys);

  if (ctx.showHidden) {
    keys = Object.getOwnPropertyNames(value);
  }

  // IE doesn't make error fields non-enumerable
  // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx
  if (isError(value)
      && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {
    return formatError(value);
  }

  // Some type of object without properties can be shortcutted.
  if (keys.length === 0) {
    if (isFunction(value)) {
      var name = value.name ? ': ' + value.name : '';
      return ctx.stylize('[Function' + name + ']', 'special');
    }
    if (isRegExp(value)) {
      return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
    }
    if (isDate(value)) {
      return ctx.stylize(Date.prototype.toString.call(value), 'date');
    }
    if (isError(value)) {
      return formatError(value);
    }
  }

  var base = '', array = false, braces = ['{', '}'];

  // Make Array say that they are Array
  if (isArray(value)) {
    array = true;
    braces = ['[', ']'];
  }

  // Make functions say that they are functions
  if (isFunction(value)) {
    var n = value.name ? ': ' + value.name : '';
    base = ' [Function' + n + ']';
  }

  // Make RegExps say that they are RegExps
  if (isRegExp(value)) {
    base = ' ' + RegExp.prototype.toString.call(value);
  }

  // Make dates with properties first say the date
  if (isDate(value)) {
    base = ' ' + Date.prototype.toUTCString.call(value);
  }

  // Make error with message first say the error
  if (isError(value)) {
    base = ' ' + formatError(value);
  }

  if (keys.length === 0 && (!array || value.length == 0)) {
    return braces[0] + base + braces[1];
  }

  if (recurseTimes < 0) {
    if (isRegExp(value)) {
      return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
    } else {
      return ctx.stylize('[Object]', 'special');
    }
  }

  ctx.seen.push(value);

  var output;
  if (array) {
    output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
  } else {
    output = keys.map(function(key) {
      return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
    });
  }

  ctx.seen.pop();

  return reduceToSingleString(output, base, braces);
}


function formatPrimitive(ctx, value) {
  if (isUndefined(value))
    return ctx.stylize('undefined', 'undefined');
  if (isString(value)) {
    var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '')
                                             .replace(/'/g, "\\'")
                                             .replace(/\\"/g, '"') + '\'';
    return ctx.stylize(simple, 'string');
  }
  if (isNumber(value))
    return ctx.stylize('' + value, 'number');
  if (isBoolean(value))
    return ctx.stylize('' + value, 'boolean');
  // For some reason typeof null is "object", so special case here.
  if (isNull(value))
    return ctx.stylize('null', 'null');
}


function formatError(value) {
  return '[' + Error.prototype.toString.call(value) + ']';
}


function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
  var output = [];
  for (var i = 0, l = value.length; i < l; ++i) {
    if (hasOwnProperty(value, String(i))) {
      output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
          String(i), true));
    } else {
      output.push('');
    }
  }
  keys.forEach(function(key) {
    if (!key.match(/^\d+$/)) {
      output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
          key, true));
    }
  });
  return output;
}


function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
  var name, str, desc;
  desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };
  if (desc.get) {
    if (desc.set) {
      str = ctx.stylize('[Getter/Setter]', 'special');
    } else {
      str = ctx.stylize('[Getter]', 'special');
    }
  } else {
    if (desc.set) {
      str = ctx.stylize('[Setter]', 'special');
    }
  }
  if (!hasOwnProperty(visibleKeys, key)) {
    name = '[' + key + ']';
  }
  if (!str) {
    if (ctx.seen.indexOf(desc.value) < 0) {
      if (isNull(recurseTimes)) {
        str = formatValue(ctx, desc.value, null);
      } else {
        str = formatValue(ctx, desc.value, recurseTimes - 1);
      }
      if (str.indexOf('\n') > -1) {
        if (array) {
          str = str.split('\n').map(function(line) {
            return '  ' + line;
          }).join('\n').substr(2);
        } else {
          str = '\n' + str.split('\n').map(function(line) {
            return '   ' + line;
          }).join('\n');
        }
      }
    } else {
      str = ctx.stylize('[Circular]', 'special');
    }
  }
  if (isUndefined(name)) {
    if (array && key.match(/^\d+$/)) {
      return str;
    }
    name = JSON.stringify('' + key);
    if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
      name = name.substr(1, name.length - 2);
      name = ctx.stylize(name, 'name');
    } else {
      name = name.replace(/'/g, "\\'")
                 .replace(/\\"/g, '"')
                 .replace(/(^"|"$)/g, "'");
      name = ctx.stylize(name, 'string');
    }
  }

  return name + ': ' + str;
}


function reduceToSingleString(output, base, braces) {
  var numLinesEst = 0;
  var length = output.reduce(function(prev, cur) {
    numLinesEst++;
    if (cur.indexOf('\n') >= 0) numLinesEst++;
    return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;
  }, 0);

  if (length > 60) {
    return braces[0] +
           (base === '' ? '' : base + '\n ') +
           ' ' +
           output.join(',\n  ') +
           ' ' +
           braces[1];
  }

  return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];
}


// NOTE: These type checking functions intentionally don't use `instanceof`
// because it is fragile and can be easily faked with `Object.create()`.
function isArray(ar) {
  return Array.isArray(ar);
}
exports.isArray = isArray;

function isBoolean(arg) {
  return typeof arg === 'boolean';
}
exports.isBoolean = isBoolean;

function isNull(arg) {
  return arg === null;
}
exports.isNull = isNull;

function isNullOrUndefined(arg) {
  return arg == null;
}
exports.isNullOrUndefined = isNullOrUndefined;

function isNumber(arg) {
  return typeof arg === 'number';
}
exports.isNumber = isNumber;

function isString(arg) {
  return typeof arg === 'string';
}
exports.isString = isString;

function isSymbol(arg) {
  return typeof arg === 'symbol';
}
exports.isSymbol = isSymbol;

function isUndefined(arg) {
  return arg === void 0;
}
exports.isUndefined = isUndefined;

function isRegExp(re) {
  return isObject(re) && objectToString(re) === '[object RegExp]';
}
exports.isRegExp = isRegExp;

function isObject(arg) {
  return typeof arg === 'object' && arg !== null;
}
exports.isObject = isObject;

function isDate(d) {
  return isObject(d) && objectToString(d) === '[object Date]';
}
exports.isDate = isDate;

function isError(e) {
  return isObject(e) &&
      (objectToString(e) === '[object Error]' || e instanceof Error);
}
exports.isError = isError;

function isFunction(arg) {
  return typeof arg === 'function';
}
exports.isFunction = isFunction;

function isPrimitive(arg) {
  return arg === null ||
         typeof arg === 'boolean' ||
         typeof arg === 'number' ||
         typeof arg === 'string' ||
         typeof arg === 'symbol' ||  // ES6 symbol
         typeof arg === 'undefined';
}
exports.isPrimitive = isPrimitive;

exports.isBuffer = __webpack_require__(436);

function objectToString(o) {
  return Object.prototype.toString.call(o);
}


function pad(n) {
  return n < 10 ? '0' + n.toString(10) : n.toString(10);
}


var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',
              'Oct', 'Nov', 'Dec'];

// 26 Feb 16:19:34
function timestamp() {
  var d = new Date();
  var time = [pad(d.getHours()),
              pad(d.getMinutes()),
              pad(d.getSeconds())].join(':');
  return [d.getDate(), months[d.getMonth()], time].join(' ');
}


// log is just a thin wrapper to console.log that prepends a timestamp
exports.log = function() {
  console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));
};


/**
 * Inherit the prototype methods from one constructor into another.
 *
 * The Function.prototype.inherits from lang.js rewritten as a standalone
 * function (not on Function.prototype). NOTE: If this file is to be loaded
 * during bootstrapping this function needs to be rewritten using some native
 * functions as prototype setup using normal JavaScript does not work as
 * expected during bootstrapping (see mirror.js in r114903).
 *
 * @param {function} ctor Constructor function which needs to inherit the
 *     prototype.
 * @param {function} superCtor Constructor function to inherit prototype from.
 */
exports.inherits = __webpack_require__(437);

exports._extend = function(origin, add) {
  // Don't do anything if add isn't an object
  if (!add || !isObject(add)) return origin;

  var keys = Object.keys(add);
  var i = keys.length;
  while (i--) {
    origin[keys[i]] = add[keys[i]];
  }
  return origin;
};

function hasOwnProperty(obj, prop) {
  return Object.prototype.hasOwnProperty.call(obj, prop);
}

var kCustomPromisifiedSymbol = typeof Symbol !== 'undefined' ? Symbol('util.promisify.custom') : undefined;

exports.promisify = function promisify(original) {
  if (typeof original !== 'function')
    throw new TypeError('The "original" argument must be of type Function');

  if (kCustomPromisifiedSymbol && original[kCustomPromisifiedSymbol]) {
    var fn = original[kCustomPromisifiedSymbol];
    if (typeof fn !== 'function') {
      throw new TypeError('The "util.promisify.custom" argument must be of type Function');
    }
    Object.defineProperty(fn, kCustomPromisifiedSymbol, {
      value: fn, enumerable: false, writable: false, configurable: true
    });
    return fn;
  }

  function fn() {
    var promiseResolve, promiseReject;
    var promise = new Promise(function (resolve, reject) {
      promiseResolve = resolve;
      promiseReject = reject;
    });

    var args = [];
    for (var i = 0; i < arguments.length; i++) {
      args.push(arguments[i]);
    }
    args.push(function (err, value) {
      if (err) {
        promiseReject(err);
      } else {
        promiseResolve(value);
      }
    });

    try {
      original.apply(this, args);
    } catch (err) {
      promiseReject(err);
    }

    return promise;
  }

  Object.setPrototypeOf(fn, Object.getPrototypeOf(original));

  if (kCustomPromisifiedSymbol) Object.defineProperty(fn, kCustomPromisifiedSymbol, {
    value: fn, enumerable: false, writable: false, configurable: true
  });
  return Object.defineProperties(
    fn,
    getOwnPropertyDescriptors(original)
  );
}

exports.promisify.custom = kCustomPromisifiedSymbol

function callbackifyOnRejected(reason, cb) {
  // `!reason` guard inspired by bluebird (Ref: https://goo.gl/t5IS6M).
  // Because `null` is a special error value in callbacks which means "no error
  // occurred", we error-wrap so the callback consumer can distinguish between
  // "the promise rejected with null" or "the promise fulfilled with undefined".
  if (!reason) {
    var newReason = new Error('Promise was rejected with a falsy value');
    newReason.reason = reason;
    reason = newReason;
  }
  return cb(reason);
}

function callbackify(original) {
  if (typeof original !== 'function') {
    throw new TypeError('The "original" argument must be of type Function');
  }

  // We DO NOT return the promise as it gives the user a false sense that
  // the promise is actually somehow related to the callback's execution
  // and that the callback throwing will reject the promise.
  function callbackified() {
    var args = [];
    for (var i = 0; i < arguments.length; i++) {
      args.push(arguments[i]);
    }

    var maybeCb = args.pop();
    if (typeof maybeCb !== 'function') {
      throw new TypeError('The last argument must be of type Function');
    }
    var self = this;
    var cb = function() {
      return maybeCb.apply(self, arguments);
    };
    // In true node style we process the callback on `nextTick` with all the
    // implications (stack, `uncaughtException`, `async_hooks`)
    original.apply(this, args)
      .then(function(ret) { process.nextTick(cb, null, ret) },
            function(rej) { process.nextTick(callbackifyOnRejected, rej, cb) });
  }

  Object.setPrototypeOf(callbackified, Object.getPrototypeOf(original));
  Object.defineProperties(callbackified,
                          getOwnPropertyDescriptors(original));
  return callbackified;
}
exports.callbackify = callbackify;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(22)))

/***/ }),
/* 134 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function iteratorToArray(value, useKeys = false) {
    if (Array.isArray(value)) {
        return value;
    }
    else {
        let result = [];
        if (value.entries) {
            for (let entry of value.entries()) {
                result.push(entry[1]);
            }
        }
        else if (typeof value[Symbol.iterator] === 'function') {
            for (let entry of value) {
                result.push(entry);
            }
        }
        else if (typeof value['next'] === 'function') {
            let i = 0;
            let next;
            while ((next = value.next()) && !next.done) {
                result.push(next.value);
            }
        }
        else {
            for (let k in value) {
                result.push(value[k]);
            }
        }
        return result;
    }
}
exports.iteratorToArray = iteratorToArray;


/***/ }),
/* 135 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const iterator_to_map_1 = __webpack_require__(128);
function merge(iterable1, iterable2) {
    let result = new Map();
    let index = 0;
    let map1 = iterable1 ? iterator_to_map_1.iteratorToMap(iterable1) : null;
    let map2 = iterable2 ? iterator_to_map_1.iteratorToMap(iterable2) : null;
    if (map1 === null || map2 === null) {
        return null;
    }
    for (let [key, value] of map1) {
        if (typeof key === 'number') {
            key = index++;
        }
        result.set(key, value);
    }
    for (let [key, value] of map2) {
        if (typeof key === 'number') {
            key = index++;
        }
        result.set(key, value);
    }
    if (Array.isArray(iterable1)) {
        return [...result.values()];
    }
    return result;
}
exports.merge = merge;


/***/ }),
/* 136 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const name_1 = __webpack_require__(182);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionAssignName extends name_1.TwingNodeExpressionName {
    constructor(name, lineno, columnno) {
        super(name, lineno, columnno);
        this.type = node_1.TwingNodeType.EXPRESSION_ASSIGN_NAME;
    }
    compile(compiler) {
        compiler
            .raw('context.proxy[')
            .string(this.getAttribute('name'))
            .raw(']');
    }
}
exports.TwingNodeExpressionAssignName = TwingNodeExpressionAssignName;


/***/ }),
/* 137 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function push(map, item) {
    map.set(map.size, item);
}
exports.push = push;


/***/ }),
/* 138 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionConditional extends expression_1.TwingNodeExpression {
    constructor(expr1, expr2, expr3, lineno, columnno) {
        let nodes = new Map();
        nodes.set('expr1', expr1);
        nodes.set('expr2', expr2);
        nodes.set('expr3', expr3);
        super(nodes, new Map(), lineno, columnno);
        this.type = node_1.TwingNodeType.EXPRESSION_CONDITIONAL;
        this.addType(node_1.TwingNodeType.EXPRESSION_CONDITIONAL);
    }
    compile(compiler) {
        compiler
            .raw('((')
            .subcompile(this.getNode('expr1'))
            .raw(') ? (')
            .subcompile(this.getNode('expr2'))
            .raw(') : (')
            .subcompile(this.getNode('expr3'))
            .raw('))');
    }
}
exports.TwingNodeExpressionConditional = TwingNodeExpressionConditional;


/***/ }),
/* 139 */
/***/ (function(module, exports) {

/**
Model/Type Name validator
*/

const DEFAULT_ENABLE_SCOPE = true;
const DEFAULT_ENABLE_BRACKETS = false;
const DEFAULT_ALLOW_UPPERCASE = true;
const DEFAULT_ALLOW_LOWERCASE = true;

const TYPE_NAME_REGEX = new RegExp('^(?!(?:do|if|in|for|let|new|try|var|case|else|enum|eval|false|null|this|true|void|with|break|catch|class|const|super|throw|while|yield|delete|export|import|public|return|static|switch|typeof|default|extends|finally|package|private|continue|debugger|function|arguments|interface|protected|implements|instanceof)$)'
  + '[$A-Z\_a-z\xaa\xb5\xba\xc0-\xd6\xd8-\xf6\xf8-\u02c1\u02c6-\u02d1\u02e0-\u02e4\u02ec\u02ee\u0370-\u0374'
  + '\u0376\u0377\u037a-\u037d\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481\u048a-\u0527'
  + '\u0531-\u0556\u0559\u0561-\u0587\u05d0-\u05ea\u05f0-\u05f2\u0620-\u064a\u066e\u066f\u0671-\u06d3\u06d5'
  + '\u06e5\u06e6\u06ee\u06ef\u06fa-\u06fc\u06ff\u0710\u0712-\u072f\u074d-\u07a5\u07b1\u07ca-\u07ea\u07f4\u07f5'
  + '\u07fa\u0800-\u0815\u081a\u0824\u0828\u0840-\u0858\u08a0\u08a2-\u08ac\u0904-\u0939\u093d\u0950\u0958-\u0961'
  + '\u0971-\u0977\u0979-\u097f\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bd\u09ce'
  + '\u09dc\u09dd\u09df-\u09e1\u09f0\u09f1\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35'
  + '\u0a36\u0a38\u0a39\u0a59-\u0a5c\u0a5e\u0a72-\u0a74\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2'
  + '\u0ab3\u0ab5-\u0ab9\u0abd\u0ad0\u0ae0\u0ae1\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33'
  + '\u0b35-\u0b39\u0b3d\u0b5c\u0b5d\u0b5f-\u0b61\u0b71\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a'
  + '\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4\u0ba8-\u0baa\u0bae-\u0bb9\u0bd0\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c33'
  + '\u0c35-\u0c39\u0c3d\u0c58\u0c59\u0c60\u0c61\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9'
  + '\u0cbd\u0cde\u0ce0\u0ce1\u0cf1\u0cf2\u0d05-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d\u0d4e\u0d60\u0d61\u0d7a-\u0d7f'
  + '\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb\u0dbd\u0dc0-\u0dc6\u0e01-\u0e30\u0e32\u0e33\u0e40-\u0e46\u0e81\u0e82'
  + '\u0e84\u0e87\u0e88\u0e8a\u0e8d\u0e94-\u0e97\u0e99-\u0e9f\u0ea1-\u0ea3\u0ea5\u0ea7\u0eaa\u0eab\u0ead-\u0eb0\u0eb2'
  + '\u0eb3\u0ebd\u0ec0-\u0ec4\u0ec6\u0edc-\u0edf\u0f00\u0f40-\u0f47\u0f49-\u0f6c\u0f88-\u0f8c\u1000-\u102a\u103f'
  + '\u1050-\u1055\u105a-\u105d\u1061\u1065\u1066\u106e-\u1070\u1075-\u1081\u108e\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa'
  + '\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5'
  + '\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310\u1312-\u1315\u1318-\u135a\u1380-\u138f\u13a0-\u13f4'
  + '\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f0\u1700-\u170c\u170e-\u1711\u1720-\u1731\u1740-\u1751'
  + '\u1760-\u176c\u176e-\u1770\u1780-\u17b3\u17d7\u17dc\u1820-\u1877\u1880-\u18a8\u18aa\u18b0-\u18f5\u1900-\u191c'
  + '\u1950-\u196d\u1970-\u1974\u1980-\u19ab\u19c1-\u19c7\u1a00-\u1a16\u1a20-\u1a54\u1aa7\u1b05-\u1b33\u1b45-\u1b4b'
  + '\u1b83-\u1ba0\u1bae\u1baf\u1bba-\u1be5\u1c00-\u1c23\u1c4d-\u1c4f\u1c5a-\u1c7d\u1ce9-\u1cec\u1cee-\u1cf1\u1cf5'
  + '\u1cf6\u1d00-\u1dbf\u1e00-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d'
  + '\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4'
  + '\u1ff6-\u1ffc\u2071\u207f\u2090-\u209c\u2102\u2107\u210a-\u2113\u2115\u2119-\u211d\u2124\u2126\u2128\u212a-\u212d'
  + '\u212f-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2c2e\u2c30-\u2c5e\u2c60-\u2ce4\u2ceb-\u2cee'
  + '\u2cf2\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d80-\u2d96\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6'
  + '\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u2e2f\u3005-\u3007\u3021-\u3029\u3031-\u3035'
  + '\u3038-\u303c\u3041-\u3096\u309d-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312d\u3131-\u318e\u31a0-\u31ba'
  + '\u31f0-\u31ff\u3400-\u4db5\u4e00-\u9fcc\ua000-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua61f\ua62a\ua62b\ua640-\ua66e'
  + '\ua67f-\ua697\ua6a0-\ua6ef\ua717-\ua71f\ua722-\ua788\ua78b-\ua78e\ua790-\ua793\ua7a0-\ua7aa\ua7f8-\ua801'
  + '\ua803-\ua805\ua807-\ua80a\ua80c-\ua822\ua840-\ua873\ua882-\ua8b3\ua8f2-\ua8f7\ua8fb\ua90a-\ua925\ua930-\ua946'
  + '\ua960-\ua97c\ua984-\ua9b2\ua9cf\uaa00-\uaa28\uaa40-\uaa42\uaa44-\uaa4b\uaa60-\uaa76\uaa7a\uaa80-\uaaaf\uaab1\uaab5'
  + '\uaab6\uaab9-\uaabd\uaac0\uaac2\uaadb-\uaadd\uaae0-\uaaea\uaaf2-\uaaf4\uab01-\uab06\uab09-\uab0e\uab11-\uab16'
  + '\uab20-\uab26\uab28-\uab2e\uabc0-\uabe2\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d\ufa70-\ufad9\ufb00-\ufb06'
  + '\ufb13-\ufb17\ufb1d\ufb1f-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44\ufb46-\ufbb1\ufbd3-\ufd3d'
  + '\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe70-\ufe74\ufe76-\ufefc\uff21-\uff3a\uff41-\uff5a\uff66-\uffbe\uffc2-\uffc7'
  + '\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc][$A-Z\_a-z\xaa\xb5\xba\xc0-\xd6\xd8-\xf6\xf8-\u02c1\u02c6-\u02d1\u02e0-\u02e4'
  + '\u02ec\u02ee\u0370-\u0374\u0376\u0377\u037a-\u037d\u0386\u0388-\u038a\u038c\u038e-\u03a1\u03a3-\u03f5\u03f7-\u0481'
  + '\u048a-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05d0-\u05ea\u05f0-\u05f2\u0620-\u064a\u066e\u066f\u0671-\u06d3\u06d5'
  + '\u06e5\u06e6\u06ee\u06ef\u06fa-\u06fc\u06ff\u0710\u0712-\u072f\u074d-\u07a5\u07b1\u07ca-\u07ea\u07f4\u07f5\u07fa'
  + '\u0800-\u0815\u081a\u0824\u0828\u0840-\u0858\u08a0\u08a2-\u08ac\u0904-\u0939\u093d\u0950\u0958-\u0961\u0971-\u0977'
  + '\u0979-\u097f\u0985-\u098c\u098f\u0990\u0993-\u09a8\u09aa-\u09b0\u09b2\u09b6-\u09b9\u09bd\u09ce\u09dc\u09dd'
  + '\u09df-\u09e1\u09f0\u09f1\u0a05-\u0a0a\u0a0f\u0a10\u0a13-\u0a28\u0a2a-\u0a30\u0a32\u0a33\u0a35\u0a36\u0a38\u0a39'
  + '\u0a59-\u0a5c\u0a5e\u0a72-\u0a74\u0a85-\u0a8d\u0a8f-\u0a91\u0a93-\u0aa8\u0aaa-\u0ab0\u0ab2\u0ab3\u0ab5-\u0ab9\u0abd'
  + '\u0ad0\u0ae0\u0ae1\u0b05-\u0b0c\u0b0f\u0b10\u0b13-\u0b28\u0b2a-\u0b30\u0b32\u0b33\u0b35-\u0b39\u0b3d\u0b5c\u0b5d'
  + '\u0b5f-\u0b61\u0b71\u0b83\u0b85-\u0b8a\u0b8e-\u0b90\u0b92-\u0b95\u0b99\u0b9a\u0b9c\u0b9e\u0b9f\u0ba3\u0ba4'
  + '\u0ba8-\u0baa\u0bae-\u0bb9\u0bd0\u0c05-\u0c0c\u0c0e-\u0c10\u0c12-\u0c28\u0c2a-\u0c33\u0c35-\u0c39\u0c3d\u0c58\u0c59'
  + '\u0c60\u0c61\u0c85-\u0c8c\u0c8e-\u0c90\u0c92-\u0ca8\u0caa-\u0cb3\u0cb5-\u0cb9\u0cbd\u0cde\u0ce0\u0ce1\u0cf1\u0cf2'
  + '\u0d05-\u0d0c\u0d0e-\u0d10\u0d12-\u0d3a\u0d3d\u0d4e\u0d60\u0d61\u0d7a-\u0d7f\u0d85-\u0d96\u0d9a-\u0db1\u0db3-\u0dbb'
  + '\u0dbd\u0dc0-\u0dc6\u0e01-\u0e30\u0e32\u0e33\u0e40-\u0e46\u0e81\u0e82\u0e84\u0e87\u0e88\u0e8a\u0e8d\u0e94-\u0e97'
  + '\u0e99-\u0e9f\u0ea1-\u0ea3\u0ea5\u0ea7\u0eaa\u0eab\u0ead-\u0eb0\u0eb2\u0eb3\u0ebd\u0ec0-\u0ec4\u0ec6\u0edc-\u0edf\u0f00'
  + '\u0f40-\u0f47\u0f49-\u0f6c\u0f88-\u0f8c\u1000-\u102a\u103f\u1050-\u1055\u105a-\u105d\u1061\u1065\u1066\u106e-\u1070'
  + '\u1075-\u1081\u108e\u10a0-\u10c5\u10c7\u10cd\u10d0-\u10fa\u10fc-\u1248\u124a-\u124d\u1250-\u1256\u1258\u125a-\u125d'
  + '\u1260-\u1288\u128a-\u128d\u1290-\u12b0\u12b2-\u12b5\u12b8-\u12be\u12c0\u12c2-\u12c5\u12c8-\u12d6\u12d8-\u1310'
  + '\u1312-\u1315\u1318-\u135a\u1380-\u138f\u13a0-\u13f4\u1401-\u166c\u166f-\u167f\u1681-\u169a\u16a0-\u16ea\u16ee-\u16f0'
  + '\u1700-\u170c\u170e-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176c\u176e-\u1770\u1780-\u17b3\u17d7\u17dc\u1820-\u1877'
  + '\u1880-\u18a8\u18aa\u18b0-\u18f5\u1900-\u191c\u1950-\u196d\u1970-\u1974\u1980-\u19ab\u19c1-\u19c7\u1a00-\u1a16'
  + '\u1a20-\u1a54\u1aa7\u1b05-\u1b33\u1b45-\u1b4b\u1b83-\u1ba0\u1bae\u1baf\u1bba-\u1be5\u1c00-\u1c23\u1c4d-\u1c4f'
  + '\u1c5a-\u1c7d\u1ce9-\u1cec\u1cee-\u1cf1\u1cf5\u1cf6\u1d00-\u1dbf\u1e00-\u1f15\u1f18-\u1f1d\u1f20-\u1f45\u1f48-\u1f4d'
  + '\u1f50-\u1f57\u1f59\u1f5b\u1f5d\u1f5f-\u1f7d\u1f80-\u1fb4\u1fb6-\u1fbc\u1fbe\u1fc2-\u1fc4\u1fc6-\u1fcc\u1fd0-\u1fd3'
  + '\u1fd6-\u1fdb\u1fe0-\u1fec\u1ff2-\u1ff4\u1ff6-\u1ffc\u2071\u207f\u2090-\u209c\u2102\u2107\u210a-\u2113\u2115'
  + '\u2119-\u211d\u2124\u2126\u2128\u212a-\u212d\u212f-\u2139\u213c-\u213f\u2145-\u2149\u214e\u2160-\u2188\u2c00-\u2c2e'
  + '\u2c30-\u2c5e\u2c60-\u2ce4\u2ceb-\u2cee\u2cf2\u2cf3\u2d00-\u2d25\u2d27\u2d2d\u2d30-\u2d67\u2d6f\u2d80-\u2d96'
  + '\u2da0-\u2da6\u2da8-\u2dae\u2db0-\u2db6\u2db8-\u2dbe\u2dc0-\u2dc6\u2dc8-\u2dce\u2dd0-\u2dd6\u2dd8-\u2dde\u2e2f'
  + '\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303c\u3041-\u3096\u309d-\u309f\u30a1-\u30fa\u30fc-\u30ff\u3105-\u312d'
  + '\u3131-\u318e\u31a0-\u31ba\u31f0-\u31ff\u3400-\u4db5\u4e00-\u9fcc\ua000-\ua48c\ua4d0-\ua4fd\ua500-\ua60c\ua610-\ua61f'
  + '\ua62a\ua62b\ua640-\ua66e\ua67f-\ua697\ua6a0-\ua6ef\ua717-\ua71f\ua722-\ua788\ua78b-\ua78e\ua790-\ua793\ua7a0-\ua7aa'
  + '\ua7f8-\ua801\ua803-\ua805\ua807-\ua80a\ua80c-\ua822\ua840-\ua873\ua882-\ua8b3\ua8f2-\ua8f7\ua8fb\ua90a-\ua925'
  + '\ua930-\ua946\ua960-\ua97c\ua984-\ua9b2\ua9cf\uaa00-\uaa28\uaa40-\uaa42\uaa44-\uaa4b\uaa60-\uaa76\uaa7a\uaa80-\uaaaf'
  + '\uaab1\uaab5\uaab6\uaab9-\uaabd\uaac0\uaac2\uaadb-\uaadd\uaae0-\uaaea\uaaf2-\uaaf4\uab01-\uab06\uab09-\uab0e'
  + '\uab11-\uab16\uab20-\uab26\uab28-\uab2e\uabc0-\uabe2\uac00-\ud7a3\ud7b0-\ud7c6\ud7cb-\ud7fb\uf900-\ufa6d'
  + '\ufa70-\ufad9\ufb00-\ufb06\ufb13-\ufb17\ufb1d\ufb1f-\ufb28\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40\ufb41\ufb43\ufb44'
  + '\ufb46-\ufbb1\ufbd3-\ufd3d\ufd50-\ufd8f\ufd92-\ufdc7\ufdf0-\ufdfb\ufe70-\ufe74\ufe76-\ufefc\uff21-\uff3a\uff41-\uff5a'
  + '\uff66-\uffbe\uffc2-\uffc7\uffca-\uffcf\uffd2-\uffd7\uffda-\uffdc0-9\u0300-\u036f\u0483-\u0487\u0591-\u05bd\u05bf'
  + '\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u0669\u0670\u06d6-\u06dc\u06df-\u06e4\u06e7\u06e8\u06ea-\u06ed'
  + '\u06f0-\u06f9\u0711\u0730-\u074a\u07a6-\u07b0\u07c0-\u07c9\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827'
  + '\u0829-\u082d\u0859-\u085b\u08e4-\u08fe\u0900-\u0903\u093a-\u093c\u093e-\u094f\u0951-\u0957\u0962\u0963\u0966-\u096f'
  + '\u0981-\u0983\u09bc\u09be-\u09c4\u09c7\u09c8\u09cb-\u09cd\u09d7\u09e2\u09e3\u09e6-\u09ef\u0a01-\u0a03\u0a3c'
  + '\u0a3e-\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a66-\u0a71\u0a75\u0a81-\u0a83\u0abc\u0abe-\u0ac5\u0ac7-\u0ac9'
  + '\u0acb-\u0acd\u0ae2\u0ae3\u0ae6-\u0aef\u0b01-\u0b03\u0b3c\u0b3e-\u0b44\u0b47\u0b48\u0b4b-\u0b4d\u0b56\u0b57\u0b62'
  + '\u0b63\u0b66-\u0b6f\u0b82\u0bbe-\u0bc2\u0bc6-\u0bc8\u0bca-\u0bcd\u0bd7\u0be6-\u0bef\u0c01-\u0c03\u0c3e-\u0c44'
  + '\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0c66-\u0c6f\u0c82\u0c83\u0cbc\u0cbe-\u0cc4\u0cc6-\u0cc8'
  + '\u0cca-\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0ce6-\u0cef\u0d02\u0d03\u0d3e-\u0d44\u0d46-\u0d48\u0d4a-\u0d4d\u0d57\u0d62'
  + '\u0d63\u0d66-\u0d6f\u0d82\u0d83\u0dca\u0dcf-\u0dd4\u0dd6\u0dd8-\u0ddf\u0df2\u0df3\u0e31\u0e34-\u0e3a\u0e47-\u0e4e'
  + '\u0e50-\u0e59\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0ed0-\u0ed9\u0f18\u0f19\u0f20-\u0f29\u0f35\u0f37\u0f39'
  + '\u0f3e\u0f3f\u0f71-\u0f84\u0f86\u0f87\u0f8d-\u0f97\u0f99-\u0fbc\u0fc6\u102b-\u103e\u1040-\u1049\u1056-\u1059'
  + '\u105e-\u1060\u1062-\u1064\u1067-\u106d\u1071-\u1074\u1082-\u108d\u108f-\u109d\u135d-\u135f\u1712-\u1714\u1732-\u1734'
  + '\u1752\u1753\u1772\u1773\u17b4-\u17d3\u17dd\u17e0-\u17e9\u180b-\u180d\u1810-\u1819\u18a9\u1920-\u192b\u1930-\u193b'
  + '\u1946-\u194f\u19b0-\u19c0\u19c8\u19c9\u19d0-\u19d9\u1a17-\u1a1b\u1a55-\u1a5e\u1a60-\u1a7c\u1a7f-\u1a89\u1a90-\u1a99'
  + '\u1b00-\u1b04\u1b34-\u1b44\u1b50-\u1b59\u1b6b-\u1b73\u1b80-\u1b82\u1ba1-\u1bad\u1bb0-\u1bb9\u1be6-\u1bf3\u1c24-\u1c37'
  + '\u1c40-\u1c49\u1c50-\u1c59\u1cd0-\u1cd2\u1cd4-\u1ce8\u1ced\u1cf2-\u1cf4\u1dc0-\u1de6\u1dfc-\u1dff\u200c\u200d\u203f'
  + '\u2040\u2054\u20d0-\u20dc\u20e1\u20e5-\u20f0\u2cef-\u2cf1\u2d7f\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua620-\ua629'
  + '\ua66f\ua674-\ua67d\ua69f\ua6f0\ua6f1\ua802\ua806\ua80b\ua823-\ua827\ua880\ua881\ua8b4-\ua8c4\ua8d0-\ua8d9\ua8e0-\ua8f1'
  + '\ua900-\ua909\ua926-\ua92d\ua947-\ua953\ua980-\ua983\ua9b3-\ua9c0\ua9d0-\ua9d9\uaa29-\uaa36\uaa43\uaa4c\uaa4d\uaa50-\uaa59'
  + '\uaa7b\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uaaeb-\uaaef\uaaf5\uaaf6\uabe3-\uabea\uabec\uabed\uabf0-\uabf9'
  + '\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\ufe33\ufe34\ufe4d-\ufe4f\uff10-\uff19\uff3f]*$');

const SCOPE_SEPARATOR = '.';
const BRACKET_PATTERN = /^([^\[\]]+)(?:\s*\[\s*(["']?)\s*(.*)?\s*\2\s*\])?$/;
const NUMERIC_KEY_PATTERN = /^[0-9]+$/;

var defaultOptions = {
  enableScope: DEFAULT_ENABLE_SCOPE,
  enableBrackets: DEFAULT_ENABLE_BRACKETS,
  allowUpperCase: DEFAULT_ALLOW_UPPERCASE,
  allowLowerCase: DEFAULT_ALLOW_LOWERCASE
};
var optionsKeys = Object.keys(defaultOptions);

/**
Expose function as module
*/
module.exports.isValid = validateName;

/**
Expose default settings
*/
Object.defineProperties(module.exports, {
  enableScope: {
    enumerable: true,
    configurable: false,
    get: function getEnableScope()  { return defaultOptions.enableScope; },
    set: function setEnableScope(v) { defaultOptions.enableScope = v; }
  },
  enableBrackets: {
    enumerable: true,
    configurable: false,
    get: function getEnableBrackets()  { return defaultOptions.enableBrackets; },
    set: function setEnableBrackets(v) { defaultOptions.enableBrackets = v; }
  },
  allowUpperCase: {
    enumerable: true,
    configurable: false,
    get: function getAllowUpperCase()  { return defaultOptions.allowUpperCase; },
    set: function setAllowUpCerCase(v) { defaultOptions.allowUpperCase = v; }
  },
  allowLowerCase: {
    enumerable: true,
    configurable: false,
    get: function getAllowLowerCase()  { return defaultOptions.allowLowerCase; },
    set: function setAllowLowerCase(v) { defaultOptions.allowLowerCase = v; }
  }
});

/**
Validate the given name and make sure it is valid. The value must be a valid String

@param {String} name                 the name to validate
@param {Object} options   (optional) option overrides
@return {Boolean}                    true if the val is valid, false otherwise
*/
function validateName(name, options) {
  var nameParts;
  var i;
  var iLen;
  var key;
  var keyMatch;
  var keyKey;
  var opt;

  if (options && (options.constructor.name === 'Object')) {
    opt = {};

    for (i = 0, iLen = optionsKeys.length; i < iLen; ++i) {
      key = optionsKeys[i];
      if (key in options) {
        opt[key] = options[key];
      } else {
        opt[key] = defaultOptions[key];
      }
    }
  } else {
    opt = defaultOptions;
  }

  function invalidVar(v) {
    return !TYPE_NAME_REGEX.test(v) ||
           (!opt.allowLowerCase && v.toLocaleUpperCase() != v) ||
           (!opt.allowUpperCase && v.toLocaleLowerCase() != v)
  }

  if (typeof name === 'string') {
    if (opt.enableScope) {
      nameParts = name.split(SCOPE_SEPARATOR);
    } else {
      nameParts = [name];
    }

    for (i = 0, iLen = nameParts.length; i < iLen; ++i) {
      key = nameParts[i];

      if (opt.enableBrackets) {
        keyMatch = key.match(BRACKET_PATTERN);

        if (!keyMatch ||
            invalidVar(keyMatch[1].trim()) ||
            (!keyMatch[2] && keyMatch[3] && !NUMERIC_KEY_PATTERN.test(keyKey = keyMatch[3].trim()) && invalidVar(keyKey))
           ) {

          return false;
        }
      } else if (invalidVar(key)) {

        return false;
      }
    }

    return true;
  } else {

    return false;
  }
}


/***/ }),
/* 140 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const error_1 = __webpack_require__(120);
/**
 * Exception thrown when an error occurs during template loading.
 *
 * Automatic template information guessing is always turned off as
 * if a template cannot be loaded, there is nothing to guess.
 * However, when a template is loaded from another one, then, we need
 * to find the current context and this is automatically done by
 * TwingTemplate::displayWithErrorHandling().
 *
 * This strategy makes TwingEnvironment::resolveTemplate() much faster.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingErrorLoader extends error_1.TwingError {
    constructor(message, lineno = -1, source = null) {
        super('', lineno, source);
        this.appendMessage(message);
        this.name = 'TwingErrorLoader';
    }
}
exports.TwingErrorLoader = TwingErrorLoader;


/***/ }),
/* 141 */
/***/ (function(module, exports) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

/**
 * This is a helper function for getting values from parameter/options
 * objects.
 *
 * @param args The object we are extracting values from
 * @param name The name of the property we are getting.
 * @param defaultValue An optional value to return if the property is missing
 * from the object. If this is not specified and the property is missing, an
 * error will be thrown.
 */
function getArg(aArgs, aName, aDefaultValue) {
  if (aName in aArgs) {
    return aArgs[aName];
  } else if (arguments.length === 3) {
    return aDefaultValue;
  } else {
    throw new Error('"' + aName + '" is a required argument.');
  }
}
exports.getArg = getArg;

var urlRegexp = /^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/;
var dataUrlRegexp = /^data:.+\,.+$/;

function urlParse(aUrl) {
  var match = aUrl.match(urlRegexp);
  if (!match) {
    return null;
  }
  return {
    scheme: match[1],
    auth: match[2],
    host: match[3],
    port: match[4],
    path: match[5]
  };
}
exports.urlParse = urlParse;

function urlGenerate(aParsedUrl) {
  var url = '';
  if (aParsedUrl.scheme) {
    url += aParsedUrl.scheme + ':';
  }
  url += '//';
  if (aParsedUrl.auth) {
    url += aParsedUrl.auth + '@';
  }
  if (aParsedUrl.host) {
    url += aParsedUrl.host;
  }
  if (aParsedUrl.port) {
    url += ":" + aParsedUrl.port
  }
  if (aParsedUrl.path) {
    url += aParsedUrl.path;
  }
  return url;
}
exports.urlGenerate = urlGenerate;

/**
 * Normalizes a path, or the path portion of a URL:
 *
 * - Replaces consecutive slashes with one slash.
 * - Removes unnecessary '.' parts.
 * - Removes unnecessary '<dir>/..' parts.
 *
 * Based on code in the Node.js 'path' core module.
 *
 * @param aPath The path or url to normalize.
 */
function normalize(aPath) {
  var path = aPath;
  var url = urlParse(aPath);
  if (url) {
    if (!url.path) {
      return aPath;
    }
    path = url.path;
  }
  var isAbsolute = exports.isAbsolute(path);

  var parts = path.split(/\/+/);
  for (var part, up = 0, i = parts.length - 1; i >= 0; i--) {
    part = parts[i];
    if (part === '.') {
      parts.splice(i, 1);
    } else if (part === '..') {
      up++;
    } else if (up > 0) {
      if (part === '') {
        // The first part is blank if the path is absolute. Trying to go
        // above the root is a no-op. Therefore we can remove all '..' parts
        // directly after the root.
        parts.splice(i + 1, up);
        up = 0;
      } else {
        parts.splice(i, 2);
        up--;
      }
    }
  }
  path = parts.join('/');

  if (path === '') {
    path = isAbsolute ? '/' : '.';
  }

  if (url) {
    url.path = path;
    return urlGenerate(url);
  }
  return path;
}
exports.normalize = normalize;

/**
 * Joins two paths/URLs.
 *
 * @param aRoot The root path or URL.
 * @param aPath The path or URL to be joined with the root.
 *
 * - If aPath is a URL or a data URI, aPath is returned, unless aPath is a
 *   scheme-relative URL: Then the scheme of aRoot, if any, is prepended
 *   first.
 * - Otherwise aPath is a path. If aRoot is a URL, then its path portion
 *   is updated with the result and aRoot is returned. Otherwise the result
 *   is returned.
 *   - If aPath is absolute, the result is aPath.
 *   - Otherwise the two paths are joined with a slash.
 * - Joining for example 'http://' and 'www.example.com' is also supported.
 */
function join(aRoot, aPath) {
  if (aRoot === "") {
    aRoot = ".";
  }
  if (aPath === "") {
    aPath = ".";
  }
  var aPathUrl = urlParse(aPath);
  var aRootUrl = urlParse(aRoot);
  if (aRootUrl) {
    aRoot = aRootUrl.path || '/';
  }

  // `join(foo, '//www.example.org')`
  if (aPathUrl && !aPathUrl.scheme) {
    if (aRootUrl) {
      aPathUrl.scheme = aRootUrl.scheme;
    }
    return urlGenerate(aPathUrl);
  }

  if (aPathUrl || aPath.match(dataUrlRegexp)) {
    return aPath;
  }

  // `join('http://', 'www.example.com')`
  if (aRootUrl && !aRootUrl.host && !aRootUrl.path) {
    aRootUrl.host = aPath;
    return urlGenerate(aRootUrl);
  }

  var joined = aPath.charAt(0) === '/'
    ? aPath
    : normalize(aRoot.replace(/\/+$/, '') + '/' + aPath);

  if (aRootUrl) {
    aRootUrl.path = joined;
    return urlGenerate(aRootUrl);
  }
  return joined;
}
exports.join = join;

exports.isAbsolute = function (aPath) {
  return aPath.charAt(0) === '/' || urlRegexp.test(aPath);
};

/**
 * Make a path relative to a URL or another path.
 *
 * @param aRoot The root path or URL.
 * @param aPath The path or URL to be made relative to aRoot.
 */
function relative(aRoot, aPath) {
  if (aRoot === "") {
    aRoot = ".";
  }

  aRoot = aRoot.replace(/\/$/, '');

  // It is possible for the path to be above the root. In this case, simply
  // checking whether the root is a prefix of the path won't work. Instead, we
  // need to remove components from the root one by one, until either we find
  // a prefix that fits, or we run out of components to remove.
  var level = 0;
  while (aPath.indexOf(aRoot + '/') !== 0) {
    var index = aRoot.lastIndexOf("/");
    if (index < 0) {
      return aPath;
    }

    // If the only part of the root that is left is the scheme (i.e. http://,
    // file:///, etc.), one or more slashes (/), or simply nothing at all, we
    // have exhausted all components, so the path is not relative to the root.
    aRoot = aRoot.slice(0, index);
    if (aRoot.match(/^([^\/]+:\/)?\/*$/)) {
      return aPath;
    }

    ++level;
  }

  // Make sure we add a "../" for each component we removed from the root.
  return Array(level + 1).join("../") + aPath.substr(aRoot.length + 1);
}
exports.relative = relative;

var supportsNullProto = (function () {
  var obj = Object.create(null);
  return !('__proto__' in obj);
}());

function identity (s) {
  return s;
}

/**
 * Because behavior goes wacky when you set `__proto__` on objects, we
 * have to prefix all the strings in our set with an arbitrary character.
 *
 * See https://github.com/mozilla/source-map/pull/31 and
 * https://github.com/mozilla/source-map/issues/30
 *
 * @param String aStr
 */
function toSetString(aStr) {
  if (isProtoString(aStr)) {
    return '$' + aStr;
  }

  return aStr;
}
exports.toSetString = supportsNullProto ? identity : toSetString;

function fromSetString(aStr) {
  if (isProtoString(aStr)) {
    return aStr.slice(1);
  }

  return aStr;
}
exports.fromSetString = supportsNullProto ? identity : fromSetString;

function isProtoString(s) {
  if (!s) {
    return false;
  }

  var length = s.length;

  if (length < 9 /* "__proto__".length */) {
    return false;
  }

  if (s.charCodeAt(length - 1) !== 95  /* '_' */ ||
      s.charCodeAt(length - 2) !== 95  /* '_' */ ||
      s.charCodeAt(length - 3) !== 111 /* 'o' */ ||
      s.charCodeAt(length - 4) !== 116 /* 't' */ ||
      s.charCodeAt(length - 5) !== 111 /* 'o' */ ||
      s.charCodeAt(length - 6) !== 114 /* 'r' */ ||
      s.charCodeAt(length - 7) !== 112 /* 'p' */ ||
      s.charCodeAt(length - 8) !== 95  /* '_' */ ||
      s.charCodeAt(length - 9) !== 95  /* '_' */) {
    return false;
  }

  for (var i = length - 10; i >= 0; i--) {
    if (s.charCodeAt(i) !== 36 /* '$' */) {
      return false;
    }
  }

  return true;
}

/**
 * Comparator between two mappings where the original positions are compared.
 *
 * Optionally pass in `true` as `onlyCompareGenerated` to consider two
 * mappings with the same original source/line/column, but different generated
 * line and column the same. Useful when searching for a mapping with a
 * stubbed out mapping.
 */
function compareByOriginalPositions(mappingA, mappingB, onlyCompareOriginal) {
  var cmp = strcmp(mappingA.source, mappingB.source);
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.originalLine - mappingB.originalLine;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.originalColumn - mappingB.originalColumn;
  if (cmp !== 0 || onlyCompareOriginal) {
    return cmp;
  }

  cmp = mappingA.generatedColumn - mappingB.generatedColumn;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.generatedLine - mappingB.generatedLine;
  if (cmp !== 0) {
    return cmp;
  }

  return strcmp(mappingA.name, mappingB.name);
}
exports.compareByOriginalPositions = compareByOriginalPositions;

/**
 * Comparator between two mappings with deflated source and name indices where
 * the generated positions are compared.
 *
 * Optionally pass in `true` as `onlyCompareGenerated` to consider two
 * mappings with the same generated line and column, but different
 * source/name/original line and column the same. Useful when searching for a
 * mapping with a stubbed out mapping.
 */
function compareByGeneratedPositionsDeflated(mappingA, mappingB, onlyCompareGenerated) {
  var cmp = mappingA.generatedLine - mappingB.generatedLine;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.generatedColumn - mappingB.generatedColumn;
  if (cmp !== 0 || onlyCompareGenerated) {
    return cmp;
  }

  cmp = strcmp(mappingA.source, mappingB.source);
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.originalLine - mappingB.originalLine;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.originalColumn - mappingB.originalColumn;
  if (cmp !== 0) {
    return cmp;
  }

  return strcmp(mappingA.name, mappingB.name);
}
exports.compareByGeneratedPositionsDeflated = compareByGeneratedPositionsDeflated;

function strcmp(aStr1, aStr2) {
  if (aStr1 === aStr2) {
    return 0;
  }

  if (aStr1 === null) {
    return 1; // aStr2 !== null
  }

  if (aStr2 === null) {
    return -1; // aStr1 !== null
  }

  if (aStr1 > aStr2) {
    return 1;
  }

  return -1;
}

/**
 * Comparator between two mappings with inflated source and name strings where
 * the generated positions are compared.
 */
function compareByGeneratedPositionsInflated(mappingA, mappingB) {
  var cmp = mappingA.generatedLine - mappingB.generatedLine;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.generatedColumn - mappingB.generatedColumn;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = strcmp(mappingA.source, mappingB.source);
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.originalLine - mappingB.originalLine;
  if (cmp !== 0) {
    return cmp;
  }

  cmp = mappingA.originalColumn - mappingB.originalColumn;
  if (cmp !== 0) {
    return cmp;
  }

  return strcmp(mappingA.name, mappingB.name);
}
exports.compareByGeneratedPositionsInflated = compareByGeneratedPositionsInflated;

/**
 * Strip any JSON XSSI avoidance prefix from the string (as documented
 * in the source maps specification), and then parse the string as
 * JSON.
 */
function parseSourceMapInput(str) {
  return JSON.parse(str.replace(/^\)]}'[^\n]*\n/, ''));
}
exports.parseSourceMapInput = parseSourceMapInput;

/**
 * Compute the URL of a source given the the source root, the source's
 * URL, and the source map's URL.
 */
function computeSourceURL(sourceRoot, sourceURL, sourceMapURL) {
  sourceURL = sourceURL || '';

  if (sourceRoot) {
    // This follows what Chrome does.
    if (sourceRoot[sourceRoot.length - 1] !== '/' && sourceURL[0] !== '/') {
      sourceRoot += '/';
    }
    // The spec says:
    //   Line 4: An optional source root, useful for relocating source
    //   files on a server or removing repeated values in the
    //   “sources” entry.  This value is prepended to the individual
    //   entries in the “source” field.
    sourceURL = sourceRoot + sourceURL;
  }

  // Historically, SourceMapConsumer did not take the sourceMapURL as
  // a parameter.  This mode is still somewhat supported, which is why
  // this code block is conditional.  However, it's preferable to pass
  // the source map URL to SourceMapConsumer, so that this function
  // can implement the source URL resolution algorithm as outlined in
  // the spec.  This block is basically the equivalent of:
  //    new URL(sourceURL, sourceMapURL).toString()
  // ... except it avoids using URL, which wasn't available in the
  // older releases of node still supported by this library.
  //
  // The spec says:
  //   If the sources are not absolute URLs after prepending of the
  //   “sourceRoot”, the sources are resolved relative to the
  //   SourceMap (like resolving script src in a html document).
  if (sourceMapURL) {
    var parsed = urlParse(sourceMapURL);
    if (!parsed) {
      throw new Error("sourceMapURL could not be parsed");
    }
    if (parsed.path) {
      // Strip the last path component, but keep the "/".
      var index = parsed.path.lastIndexOf('/');
      if (index >= 0) {
        parsed.path = parsed.path.substring(0, index + 1);
      }
    }
    sourceURL = join(urlGenerate(parsed), sourceURL);
  }

  return normalize(sourceURL);
}
exports.computeSourceURL = computeSourceURL;


/***/ }),
/* 142 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28.1,21c0-2-0.7-3.7-2.1-5.1s-3.1-2.1-5.1-2.1s-3.7,0.7-5.1,2.1S13.8,19,13.8,21s0.7,3.7,2.1,5.1s3.1,2.1,5.1,2.1 s3.7-0.7,5.1-2.1S28.1,22.9,28.1,21z M37.9,18.5v4.9c0,0.2-0.1,0.3-0.2,0.5c-0.1,0.2-0.3,0.3-0.4,0.3l-4.1,0.6 c-0.3,0.8-0.6,1.5-0.9,2c0.5,0.7,1.3,1.8,2.4,3c0.1,0.2,0.2,0.4,0.2,0.6s-0.1,0.4-0.2,0.5c-0.4,0.5-1.1,1.3-2.2,2.4 c-1.1,1-1.8,1.6-2.1,1.6c-0.2,0-0.4-0.1-0.6-0.2l-3-2.4c-0.6,0.3-1.3,0.6-2,0.8c-0.2,2-0.4,3.4-0.6,4.1c-0.1,0.4-0.4,0.6-0.8,0.6 h-4.9c-0.2,0-0.4-0.1-0.5-0.2c-0.2-0.1-0.2-0.3-0.3-0.5l-0.6-4.1c-0.7-0.2-1.4-0.5-2-0.8L12,34.7c-0.1,0.1-0.3,0.2-0.6,0.2 c-0.2,0-0.4-0.1-0.6-0.2C9,33,7.8,31.8,7.2,31c-0.1-0.1-0.2-0.3-0.2-0.5c0-0.2,0.1-0.3,0.2-0.5c0.2-0.3,0.6-0.8,1.1-1.5 s0.9-1.2,1.2-1.6c-0.4-0.7-0.7-1.5-0.9-2.2l-4-0.6c-0.2,0-0.3-0.1-0.5-0.3C4.1,23.7,4,23.5,4,23.4v-4.9c0-0.2,0.1-0.3,0.2-0.5 s0.3-0.3,0.4-0.3L8.7,17c0.2-0.7,0.5-1.4,0.9-2c-0.6-0.8-1.4-1.9-2.4-3C7.1,11.8,7,11.6,7,11.4c0-0.1,0.1-0.3,0.2-0.5 c0.4-0.5,1.1-1.3,2.2-2.4S11.1,7,11.4,7c0.2,0,0.4,0.1,0.6,0.2l3,2.4c0.6-0.3,1.3-0.6,2-0.8c0.2-2,0.4-3.4,0.6-4.1 C17.8,4.2,18.1,4,18.5,4h4.9c0.2,0,0.4,0.1,0.5,0.2c0.2,0.1,0.2,0.3,0.3,0.5l0.6,4.1c0.7,0.2,1.4,0.5,2,0.8l3.1-2.4 C30.1,7,30.2,7,30.5,7c0.2,0,0.4,0.1,0.6,0.2c1.9,1.8,3.1,3,3.6,3.8c0.1,0.1,0.2,0.3,0.2,0.5c0,0.2-0.1,0.3-0.2,0.5 c-0.2,0.3-0.6,0.8-1.1,1.5c-0.5,0.7-0.9,1.2-1.2,1.6c0.4,0.7,0.7,1.5,0.9,2.2l4,0.6c0.2,0,0.3,0.1,0.5,0.3 C37.8,18.2,37.9,18.4,37.9,18.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 143 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links_3_' d='M21.2,29.5c-0.2,0-0.5-0.1-0.7-0.3L7.3,16C7.1,15.8,7,15.6,7,15.4s0.1-0.5,0.3-0.7l1.4-1.4 C8.9,13.1,9.1,13,9.4,13c0.2,0,0.5,0.1,0.7,0.3l11.2,11.2l11.2-11.2c0.2-0.2,0.4-0.3,0.7-0.3s0.5,0.1,0.7,0.3l1.4,1.4 c0.2,0.2,0.3,0.4,0.3,0.7S35.2,15.8,35,16L21.8,29.2C21.6,29.4,21.4,29.5,21.2,29.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 144 */
/***/ (function(module, exports) {

function _defineProperty(obj, key, value) {
  if (key in obj) {
    Object.defineProperty(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true
    });
  } else {
    obj[key] = value;
  }

  return obj;
}

module.exports = _defineProperty;

/***/ }),
/* 145 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Executes the provided function once for each element of an iterable.
 *
 * @param {*} it An iterable
 * @param {Function} cb Function to execute for each element, taking a key and a value as arguments
 */
function each(it, cb) {
    if (it.entries) {
        for (let [k, v] of it.entries()) {
            cb(k, v);
        }
    }
    else if (typeof it[Symbol.iterator] === 'function') {
        let i = 0;
        for (let value of it) {
            cb(i++, value);
        }
    }
    else if (typeof it['next'] === 'function') {
        let i = 0;
        let next;
        while ((next = it.next()) && !next.done) {
            cb(i++, next.value);
        }
    }
    else {
        for (let k in it) {
            cb(k, it[k]);
        }
    }
}
exports.each = each;


/***/ }),
/* 146 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function iteratorToHash(value) {
    let result;
    if (value.entries) {
        result = {};
        for (let entry of value.entries()) {
            result[entry[0]] = entry[1];
        }
        return result;
    }
    else {
        result = value;
    }
    return result;
}
exports.iteratorToHash = iteratorToHash;


/***/ }),
/* 147 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function isMap(candidate) {
    return (candidate && (typeof candidate.has === 'function') && (typeof candidate.get === 'function'));
}
exports.isMap = isMap;


/***/ }),
/* 148 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Implements a no-cache strategy.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
class TwingCacheNull {
    constructor() {
        this.TwingCacheInterfaceImpl = this;
    }
    generateKey(name, className) {
        return '';
    }
    write(key, content) {
    }
    load(key) {
        return () => {
            return {};
        };
    }
    getTimestamp(key) {
        return 0;
    }
}
exports.TwingCacheNull = TwingCacheNull;


/***/ }),
/* 149 */
/***/ (function(module, exports, __webpack_require__) {

;(function (root, factory) {
	if (true) {
		// CommonJS
		module.exports = exports = factory(__webpack_require__(254));
	}
	else {}
}(this, function (CryptoJS) {

	(function (Math) {
	    // Shortcuts
	    var C = CryptoJS;
	    var C_lib = C.lib;
	    var WordArray = C_lib.WordArray;
	    var Hasher = C_lib.Hasher;
	    var C_algo = C.algo;

	    // Initialization and round constants tables
	    var H = [];
	    var K = [];

	    // Compute constants
	    (function () {
	        function isPrime(n) {
	            var sqrtN = Math.sqrt(n);
	            for (var factor = 2; factor <= sqrtN; factor++) {
	                if (!(n % factor)) {
	                    return false;
	                }
	            }

	            return true;
	        }

	        function getFractionalBits(n) {
	            return ((n - (n | 0)) * 0x100000000) | 0;
	        }

	        var n = 2;
	        var nPrime = 0;
	        while (nPrime < 64) {
	            if (isPrime(n)) {
	                if (nPrime < 8) {
	                    H[nPrime] = getFractionalBits(Math.pow(n, 1 / 2));
	                }
	                K[nPrime] = getFractionalBits(Math.pow(n, 1 / 3));

	                nPrime++;
	            }

	            n++;
	        }
	    }());

	    // Reusable object
	    var W = [];

	    /**
	     * SHA-256 hash algorithm.
	     */
	    var SHA256 = C_algo.SHA256 = Hasher.extend({
	        _doReset: function () {
	            this._hash = new WordArray.init(H.slice(0));
	        },

	        _doProcessBlock: function (M, offset) {
	            // Shortcut
	            var H = this._hash.words;

	            // Working variables
	            var a = H[0];
	            var b = H[1];
	            var c = H[2];
	            var d = H[3];
	            var e = H[4];
	            var f = H[5];
	            var g = H[6];
	            var h = H[7];

	            // Computation
	            for (var i = 0; i < 64; i++) {
	                if (i < 16) {
	                    W[i] = M[offset + i] | 0;
	                } else {
	                    var gamma0x = W[i - 15];
	                    var gamma0  = ((gamma0x << 25) | (gamma0x >>> 7))  ^
	                                  ((gamma0x << 14) | (gamma0x >>> 18)) ^
	                                   (gamma0x >>> 3);

	                    var gamma1x = W[i - 2];
	                    var gamma1  = ((gamma1x << 15) | (gamma1x >>> 17)) ^
	                                  ((gamma1x << 13) | (gamma1x >>> 19)) ^
	                                   (gamma1x >>> 10);

	                    W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16];
	                }

	                var ch  = (e & f) ^ (~e & g);
	                var maj = (a & b) ^ (a & c) ^ (b & c);

	                var sigma0 = ((a << 30) | (a >>> 2)) ^ ((a << 19) | (a >>> 13)) ^ ((a << 10) | (a >>> 22));
	                var sigma1 = ((e << 26) | (e >>> 6)) ^ ((e << 21) | (e >>> 11)) ^ ((e << 7)  | (e >>> 25));

	                var t1 = h + sigma1 + ch + K[i] + W[i];
	                var t2 = sigma0 + maj;

	                h = g;
	                g = f;
	                f = e;
	                e = (d + t1) | 0;
	                d = c;
	                c = b;
	                b = a;
	                a = (t1 + t2) | 0;
	            }

	            // Intermediate hash value
	            H[0] = (H[0] + a) | 0;
	            H[1] = (H[1] + b) | 0;
	            H[2] = (H[2] + c) | 0;
	            H[3] = (H[3] + d) | 0;
	            H[4] = (H[4] + e) | 0;
	            H[5] = (H[5] + f) | 0;
	            H[6] = (H[6] + g) | 0;
	            H[7] = (H[7] + h) | 0;
	        },

	        _doFinalize: function () {
	            // Shortcuts
	            var data = this._data;
	            var dataWords = data.words;

	            var nBitsTotal = this._nDataBytes * 8;
	            var nBitsLeft = data.sigBytes * 8;

	            // Add padding
	            dataWords[nBitsLeft >>> 5] |= 0x80 << (24 - nBitsLeft % 32);
	            dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 14] = Math.floor(nBitsTotal / 0x100000000);
	            dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 15] = nBitsTotal;
	            data.sigBytes = dataWords.length * 4;

	            // Hash final blocks
	            this._process();

	            // Return final computed hash
	            return this._hash;
	        },

	        clone: function () {
	            var clone = Hasher.clone.call(this);
	            clone._hash = this._hash.clone();

	            return clone;
	        }
	    });

	    /**
	     * Shortcut function to the hasher's object interface.
	     *
	     * @param {WordArray|string} message The message to hash.
	     *
	     * @return {WordArray} The hash.
	     *
	     * @static
	     *
	     * @example
	     *
	     *     var hash = CryptoJS.SHA256('message');
	     *     var hash = CryptoJS.SHA256(wordArray);
	     */
	    C.SHA256 = Hasher._createHelper(SHA256);

	    /**
	     * Shortcut function to the HMAC's object interface.
	     *
	     * @param {WordArray|string} message The message to hash.
	     * @param {WordArray|string} key The secret key.
	     *
	     * @return {WordArray} The HMAC.
	     *
	     * @static
	     *
	     * @example
	     *
	     *     var hmac = CryptoJS.HmacSHA256(message, key);
	     */
	    C.HmacSHA256 = Hasher._createHmacHelper(SHA256);
	}(Math));


	return CryptoJS.SHA256;

}));

/***/ }),
/* 150 */
/***/ (function(module, exports, __webpack_require__) {

;(function (root, factory) {
	if (true) {
		// CommonJS
		module.exports = exports = factory(__webpack_require__(254));
	}
	else {}
}(this, function (CryptoJS) {

	return CryptoJS.enc.Hex;

}));

/***/ }),
/* 151 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/*!
 * isobject <https://github.com/jonschlinkert/isobject>
 *
 * Copyright (c) 2014-2017, Jon Schlinkert.
 * Released under the MIT License.
 */



module.exports = function isObject(val) {
  return val != null && typeof val === 'object' && Array.isArray(val) === false;
};


/***/ }),
/* 152 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(module) {/*!
 * @name JavaScript/NodeJS Merge v1.2.1
 * @author yeikos
 * @repository https://github.com/yeikos/js.merge

 * Copyright 2014 yeikos - MIT license
 * https://raw.github.com/yeikos/js.merge/master/LICENSE
 */

;(function(isNode) {

	/**
	 * Merge one or more objects 
	 * @param bool? clone
	 * @param mixed,... arguments
	 * @return object
	 */

	var Public = function(clone) {

		return merge(clone === true, false, arguments);

	}, publicName = 'merge';

	/**
	 * Merge two or more objects recursively 
	 * @param bool? clone
	 * @param mixed,... arguments
	 * @return object
	 */

	Public.recursive = function(clone) {

		return merge(clone === true, true, arguments);

	};

	/**
	 * Clone the input removing any reference
	 * @param mixed input
	 * @return mixed
	 */

	Public.clone = function(input) {

		var output = input,
			type = typeOf(input),
			index, size;

		if (type === 'array') {

			output = [];
			size = input.length;

			for (index=0;index<size;++index)

				output[index] = Public.clone(input[index]);

		} else if (type === 'object') {

			output = {};

			for (index in input)

				output[index] = Public.clone(input[index]);

		}

		return output;

	};

	/**
	 * Merge two objects recursively
	 * @param mixed input
	 * @param mixed extend
	 * @return mixed
	 */

	function merge_recursive(base, extend) {

		if (typeOf(base) !== 'object')

			return extend;

		for (var key in extend) {

			if (typeOf(base[key]) === 'object' && typeOf(extend[key]) === 'object') {

				base[key] = merge_recursive(base[key], extend[key]);

			} else {

				base[key] = extend[key];

			}

		}

		return base;

	}

	/**
	 * Merge two or more objects
	 * @param bool clone
	 * @param bool recursive
	 * @param array argv
	 * @return object
	 */

	function merge(clone, recursive, argv) {

		var result = argv[0],
			size = argv.length;

		if (clone || typeOf(result) !== 'object')

			result = {};

		for (var index=0;index<size;++index) {

			var item = argv[index],

				type = typeOf(item);

			if (type !== 'object') continue;

			for (var key in item) {

				if (key === '__proto__') continue;

				var sitem = clone ? Public.clone(item[key]) : item[key];

				if (recursive) {

					result[key] = merge_recursive(result[key], sitem);

				} else {

					result[key] = sitem;

				}

			}

		}

		return result;

	}

	/**
	 * Get type of variable
	 * @param mixed input
	 * @return string
	 *
	 * @see http://jsperf.com/typeofvar
	 */

	function typeOf(input) {

		return ({}).toString.call(input).slice(8, -1).toLowerCase();

	}

	if (isNode) {

		module.exports = Public;

	} else {

		window[publicName] = Public;

	}

})( true && module && typeof module.exports === 'object' && module.exports);
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(23)(module)))

/***/ }),
/* 153 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const error_1 = __webpack_require__(120);
class TwingErrorRuntime extends error_1.TwingError {
    constructor(message, lineno = -1, source = null, previous) {
        super(message, lineno, source, previous);
        this.name = 'TwingErrorRuntime';
    }
}
exports.TwingErrorRuntime = TwingErrorRuntime;


/***/ }),
/* 154 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const constant_1 = __webpack_require__(115);
const node_1 = __webpack_require__(107);
const push_1 = __webpack_require__(137);
const ctype_digit_1 = __webpack_require__(449);
let array_chunk = __webpack_require__(450);
class TwingNodeExpressionArray extends expression_1.TwingNodeExpression {
    constructor(elements, lineno, columno) {
        super(elements, new Map(), lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_ARRAY;
        this.index = -1;
        for (let pair of this.getKeyValuePairs()) {
            let expression = pair.key;
            if ((expression.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) && (ctype_digit_1.ctypeDigit('' + expression.getAttribute('value'))) && (expression.getAttribute('value') > this.index)) {
                this.index = expression.getAttribute('value');
            }
        }
    }
    getKeyValuePairs() {
        let pairs = [];
        array_chunk(Array.from(this.nodes.values()), 2).forEach(function (pair) {
            pairs.push({
                key: pair[0],
                value: pair[1]
            });
        });
        return pairs;
    }
    addElement(value, key = null) {
        if (key === null) {
            this.index++;
            key = new constant_1.TwingNodeExpressionConstant(this.index, value.getTemplateLine(), value.getTemplateColumn());
        }
        push_1.push(this.nodes, key);
        push_1.push(this.nodes, value);
    }
    compile(compiler) {
        compiler.raw('[');
        let first = true;
        for (let pair of this.getKeyValuePairs()) {
            if (!first) {
                compiler.raw(', ');
            }
            first = false;
            compiler.subcompile(pair.value);
        }
        compiler.raw(']');
    }
}
exports.TwingNodeExpressionArray = TwingNodeExpressionArray;


/***/ }),
/* 155 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const unary_1 = __webpack_require__(156);
class TwingNodeExpressionUnaryNot extends unary_1.TwingNodeExpressionUnary {
    operator(compiler) {
        return compiler.raw('!');
    }
}
exports.TwingNodeExpressionUnaryNot = TwingNodeExpressionUnaryNot;


/***/ }),
/* 156 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionUnary extends expression_1.TwingNodeExpression {
    constructor(expr, lineno, columno) {
        let nodes = new Map();
        nodes.set('node', expr);
        super(nodes, new Map(), lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_UNARY;
    }
    compile(compiler) {
        compiler.raw(' ');
        this.operator(compiler);
        compiler.subcompile(this.getNode('node'));
    }
    operator(compiler) {
        return compiler;
    }
}
exports.TwingNodeExpressionUnary = TwingNodeExpressionUnary;


/***/ }),
/* 157 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Represents a body node.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingNodeBody extends node_1.TwingNode {
    constructor(nodes = new Map(), attributes = new Map(), lineno = 0, columnno = 0, tag = null) {
        super(nodes, attributes, lineno, columnno, tag);
        this.type = node_1.TwingNodeType.BODY;
    }
}
exports.TwingNodeBody = TwingNodeBody;


/***/ }),
/* 158 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const function_1 = __webpack_require__(283);
const callable_wrapper_1 = __webpack_require__(197);
const merge = __webpack_require__(152);
class TwingFunction extends callable_wrapper_1.TwingCallableWrapper {
    /**
     * Creates a template function.
     *
     * @param {string} name Name of this function
     * @param {Function} callable A callable implementing the function. If null, you need to overwrite the "expression_factory" option to customize compilation.
     * @param {TwingFunctionOptions} options Options
     */
    constructor(name, callable = null, options = {}) {
        super(name, callable);
        this.arguments = [];
        this.options = merge({
            'needs_environment': false,
            'needs_context': false,
            'needs_source': false,
            'is_variadic': false,
            'is_safe': null,
            'is_safe_callback': null,
            'expression_factory': function (name, functionArguments, line) {
                return new function_1.TwingNodeExpressionFunction(name, functionArguments, line);
            },
            'deprecated': false,
            'alternative': null
        }, options);
    }
    getExpressionFactory() {
        return this.options.expression_factory;
    }
    setArguments(arguments_) {
        this.arguments = arguments_;
    }
    getArguments() {
        return this.arguments;
    }
    needsEnvironment() {
        return this.options.needs_environment;
    }
    needsContext() {
        return this.options.needs_context;
    }
    needsSource() {
        return this.options.needs_source;
    }
    getSafe(functionArgs) {
        if (this.options.is_safe !== null) {
            return this.options.is_safe;
        }
        if (this.options.is_safe_callback) {
            return this.options.is_safe_callback(functionArgs);
        }
        return [];
    }
    isVariadic() {
        return this.options.is_variadic;
    }
    isDeprecated() {
        return this.options.deprecated ? true : false;
    }
    getDeprecatedVersion() {
        return this.options.deprecated;
    }
    getAlternative() {
        return this.options.alternative;
    }
}
exports.TwingFunction = TwingFunction;


/***/ }),
/* 159 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
const syntax_1 = __webpack_require__(112);
const constant_1 = __webpack_require__(115);
const array_1 = __webpack_require__(154);
const reflection_method_1 = __webpack_require__(284);
const array_merge = __webpack_require__(186);
const snakeCase = __webpack_require__(459);
const capitalize = __webpack_require__(286);
class TwingNodeExpressionCall extends expression_1.TwingNodeExpression {
    compileCallable(compiler) {
        let callable = this.getAttribute('callable');
        if (typeof callable === 'string' && callable.indexOf('::') < 0) {
            compiler
                .raw(callable)
                .raw('(...');
        }
        else {
            let [r, callable_] = this.reflectCallable(callable, compiler.getEnvironment());
            if (r instanceof reflection_method_1.TwingReflectionMethod && typeof callable_[0] === 'string') {
                compiler.raw(`this.env.getRuntime('${callable_[0]}').${callable_[1]}(...`);
            }
            else {
                compiler.raw(`this.env.get${capitalize(this.getAttribute('type'))}('${this.getAttribute('name')}').traceableCallable(${this.getTemplateLine()}, this.source)(...`);
            }
            ``;
        }
        this.compileArguments(compiler);
        compiler.raw(')');
    }
    compileArguments(compiler) {
        compiler.raw('[');
        let first = true;
        if (this.hasAttribute('needs_environment') && this.getAttribute('needs_environment')) {
            compiler.raw('this.env');
            first = false;
        }
        if (this.hasAttribute('needs_context') && this.getAttribute('needs_context')) {
            if (!first) {
                compiler.raw(', ');
            }
            compiler.raw('context');
            first = false;
        }
        if (this.hasAttribute('needs_source') && this.getAttribute('needs_source')) {
            if (!first) {
                compiler.raw(', ');
            }
            compiler.raw('this.source');
            first = false;
        }
        if (this.hasAttribute('arguments')) {
            for (let argument_ of this.getAttribute('arguments')) {
                if (!first) {
                    compiler.raw(', ');
                }
                compiler.string(argument_);
                first = false;
            }
        }
        if (this.hasNode('node')) {
            if (!first) {
                compiler.raw(', ');
            }
            compiler.subcompile(this.getNode('node'));
            first = false;
        }
        if (this.hasNode('arguments')) {
            let callable = this.getAttribute('callable');
            let arguments_ = this.getArguments(callable, this.getNode('arguments'), compiler.getEnvironment());
            for (let node of arguments_) {
                if (!first) {
                    compiler.raw(', ');
                }
                compiler.subcompile(node);
                first = false;
            }
        }
        compiler.raw(']');
    }
    getArguments(callable, argumentsNode, env) {
        let self = this;
        let callType = this.getAttribute('type');
        let callName = this.getAttribute('name');
        let parameters = new Map();
        let named = false;
        for (let [name, node] of argumentsNode.getNodes()) {
            if (typeof name !== 'number') {
                named = true;
                name = self.normalizeName(name);
            }
            else if (named) {
                throw new syntax_1.TwingErrorSyntax(`Positional arguments cannot be used after named arguments for ${callType} "${callName}".`, this.getTemplateLine());
            }
            parameters.set(name, node);
        }
        let isVariadic = this.hasAttribute('is_variadic') && this.getAttribute('is_variadic');
        if (!named && !isVariadic) {
            return [...parameters.values()];
        }
        let message;
        if (!callable) {
            if (named) {
                message = `Named arguments are not supported for ${callType} "${callName}".`;
            }
            else {
                message = `Arbitrary positional arguments are not supported for ${callType} "${callName}".`;
            }
            throw new Error(message);
        }
        let callableParameters = this.getCallableParameters(callable, isVariadic, env);
        let arguments_ = [];
        let names = [];
        let optionalArguments = [];
        let pos = 0;
        for (let callableParameter of callableParameters) {
            let name = '' + self.normalizeName(callableParameter.getName());
            names.push(name);
            if (parameters.has(name)) {
                if (parameters.has(pos)) {
                    throw new syntax_1.TwingErrorSyntax(`Argument "${name}" is defined twice for ${callType} "${callName}".`, this.getTemplateLine());
                }
                arguments_ = array_merge(arguments_, optionalArguments);
                arguments_.push(parameters.get(name));
                parameters.delete(name);
                optionalArguments = [];
            }
            else if (parameters.has(pos)) {
                arguments_ = array_merge(arguments_, optionalArguments);
                arguments_.push(parameters.get(pos));
                parameters.delete(pos);
                optionalArguments = [];
                ++pos;
            }
            else if (callableParameter.isDefaultValueAvailable()) {
                optionalArguments.push(new constant_1.TwingNodeExpressionConstant(callableParameter.getDefaultValue(), -1, -1));
            }
            else {
                throw new syntax_1.TwingErrorSyntax(`Value for argument "${name}" is required for ${callType} "${callName}".`, this.getTemplateLine());
            }
        }
        if (isVariadic) {
            let arbitraryArguments = new array_1.TwingNodeExpressionArray(new Map(), -1, -1);
            let resolvedKeys = [];
            for (let [key, value] of parameters) {
                if (Number.isInteger(key)) {
                    arbitraryArguments.addElement(value);
                }
                else {
                    arbitraryArguments.addElement(value, new constant_1.TwingNodeExpressionConstant(key, -1, -1));
                }
                resolvedKeys.push(key);
            }
            for (let key of resolvedKeys) {
                parameters.delete(key);
            }
            if (arbitraryArguments.count()) {
                arguments_ = array_merge(arguments_, optionalArguments);
                arguments_.push(arbitraryArguments);
            }
        }
        if (parameters.size > 0) {
            let unknownParameter = [...parameters.values()].find(function (parameter) {
                // todo: what other type of data can parameter be?
                return parameter instanceof node_1.TwingNode;
            });
            throw new syntax_1.TwingErrorSyntax(`Unknown argument${parameters.size > 1 ? 's' : ''} "${[...parameters.keys()].join('", "')}" for ${callType} "${callName}(${names.join(', ')})".`, unknownParameter ? unknownParameter.getTemplateLine() : this.getTemplateLine(), self.getTemplateName());
        }
        return arguments_;
    }
    normalizeName(name) {
        return snakeCase(name).toLowerCase();
    }
    getCallableParameters(callable, isVariadic, env) {
        let r = this.reflectCallable(callable, env)[0];
        if (!r) {
            return [];
        }
        let parameters = r.getParameters();
        if (this.hasNode('node')) {
            parameters.shift();
        }
        if (this.hasAttribute('needs_environment') && this.getAttribute('needs_environment')) {
            parameters.shift();
        }
        if (this.hasAttribute('needs_context') && this.getAttribute('needs_context')) {
            parameters.shift();
        }
        if (this.hasAttribute('needs_source') && this.getAttribute('needs_source')) {
            parameters.shift();
        }
        if (this.hasAttribute('arguments') && this.getAttribute('arguments')) {
            for (let v of this.getAttribute('arguments')) {
                parameters.shift();
            }
        }
        if (isVariadic) {
            let argument_ = parameters[parameters.length - 1];
            if (argument_ && argument_.isArray() && argument_.isDefaultValueAvailable() && (argument_.getDefaultValue().length === 0)) {
                parameters.pop();
            }
            else {
                let callableName = r.getName();
                throw new Error(`The last parameter of "${callableName}" for ${this.getAttribute('type')} "${this.getAttribute('name')}" must be an array with default value, eg. "arg = []".`);
            }
        }
        return parameters;
    }
    reflectCallable(callable, env) {
        let r;
        let name;
        let pos;
        if (Array.isArray(callable)) {
            let runtime = env.getRuntime(callable[0]);
            if (typeof runtime[callable[1]] !== 'function') {
                return [null, []];
            }
            r = new reflection_method_1.TwingReflectionMethod(runtime[callable[1]], callable[1]);
        }
        else if (typeof callable === 'object' && Reflect.has(callable, '__invoke')) {
            name = `${callable.constructor.name}::__invoke`;
            callable = Reflect.get(callable, '__invoke');
            r = new reflection_method_1.TwingReflectionMethod(callable, name);
        }
        else if (typeof callable === 'string' && ((pos = callable.indexOf('::')) > -1)) {
            let class_ = callable.substr(0, pos);
            let method = callable.substr(pos + 2);
            let runtime = env.getRuntime(class_);
            if (typeof runtime[method] !== 'function') {
                return [null, []];
            }
            r = new reflection_method_1.TwingReflectionMethod(runtime[method], callable);
            callable = [class_, method];
        }
        else {
            r = new reflection_method_1.TwingReflectionMethod(callable, name);
        }
        this.reflector = {
            r: r,
            callable: callable
        };
        return [r, callable];
    }
}
exports.TwingNodeExpressionCall = TwingNodeExpressionCall;


/***/ }),
/* 160 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
const node_1 = __webpack_require__(107);
const constant_1 = __webpack_require__(115);
const syntax_1 = __webpack_require__(112);
/**
 * Checks if a variable is defined in the active context.
 *
 * <pre>
 * {# defined works with variable names and variable attributes #}
 * {% if foo is defined %}
 *     {# ... #}
 * {% endif %}
 * </pre>
 */
class TwingNodeExpressionTestDefined extends test_1.TwingNodeExpressionTest {
    constructor(node, name, nodeArguments, lineno, columnno) {
        let changeIgnoreStrictCheck = false;
        let error = null;
        if (node.getType() === node_1.TwingNodeType.EXPRESSION_NAME) {
            node.setAttribute('is_defined_test', true);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR) {
            node.setAttribute('is_defined_test', true);
            changeIgnoreStrictCheck = true;
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_BLOCK_REFERENCE) {
            node.setAttribute('is_defined_test', true);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_FUNCTION && (node.getAttribute('name') === 'constant')) {
            node.setAttribute('is_defined_test', true);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT || node.getType() === node_1.TwingNodeType.EXPRESSION_ARRAY) {
            node = new constant_1.TwingNodeExpressionConstant(true, node.getTemplateLine(), node.getTemplateColumn());
        }
        else {
            error = 'The "defined" test only works with simple variables.';
        }
        super(node, name, nodeArguments, lineno, columnno);
        if (changeIgnoreStrictCheck) {
            this.changeIgnoreStrictCheck(node);
        }
        if (error) {
            throw new syntax_1.TwingErrorSyntax(error, this.getTemplateLine());
        }
    }
    changeIgnoreStrictCheck(node) {
        node.setAttribute('optimizable', false);
        node.setAttribute('ignore_strict_check', true);
        let exprNode = node.getNode('node');
        if (exprNode.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR) {
            this.changeIgnoreStrictCheck(exprNode);
        }
    }
    compile(compiler) {
        compiler.subcompile(this.getNode('node'));
    }
}
exports.TwingNodeExpressionTestDefined = TwingNodeExpressionTestDefined;


/***/ }),
/* 161 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
const call_1 = __webpack_require__(159);
class TwingNodeExpressionFilter extends call_1.TwingNodeExpressionCall {
    constructor(node, filterName, methodArguments, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('node', node);
        nodes.set('filter', filterName);
        nodes.set('arguments', methodArguments);
        super(nodes, new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.EXPRESSION_FILTER;
    }
    compile(compiler) {
        let name = this.getNode('filter').getAttribute('value');
        let filter = compiler.getEnvironment().getFilter(name);
        let callable = filter.getCallable();
        this.setAttribute('name', name);
        this.setAttribute('type', 'filter');
        this.setAttribute('needs_environment', filter.needsEnvironment());
        this.setAttribute('needs_context', filter.needsContext());
        this.setAttribute('needs_source', filter.needsSource());
        this.setAttribute('arguments', filter.getArguments());
        this.setAttribute('callable', callable);
        this.setAttribute('is_variadic', filter.isVariadic());
        this.compileCallable(compiler);
    }
}
exports.TwingNodeExpressionFilter = TwingNodeExpressionFilter;


/***/ }),
/* 162 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {
Object.defineProperty(exports, "__esModule", { value: true });
const iconv_1 = __webpack_require__(178);
/**
 * Marks a content as safe.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingMarkup {
    constructor(content, charset) {
        this.content = Buffer.from(content);
        this.charset = charset;
    }
    toString() {
        return this.content.toString();
    }
    count() {
        let content = iconv_1.iconv(this.charset, 'utf-8', this.content).toString();
        return content.length;
    }
    toJSON() {
        return this.content.toString();
    }
}
exports.TwingMarkup = TwingMarkup;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 163 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.9,30.8V16.7c0-0.5-0.2-1-0.6-1.4s-0.8-0.6-1.4-0.6H18.8c-0.5,0-1-0.2-1.4-0.6c-0.4-0.4-0.6-0.8-0.6-1.4v-1.3 c0-0.5-0.2-1-0.6-1.4c-0.4-0.4-0.8-0.6-1.4-0.6H8.5c-0.5,0-1,0.2-1.4,0.6S6.6,11,6.6,11.5v19.3c0,0.5,0.2,1,0.6,1.4s0.8,0.6,1.4,0.6 H33c0.5,0,1-0.2,1.4-0.6S34.9,31.4,34.9,30.8z M37.5,16.7v14.2c0,1.2-0.4,2.3-1.3,3.2c-0.9,0.9-1.9,1.3-3.2,1.3H8.5 c-1.2,0-2.3-0.4-3.2-1.3S4,32.1,4,30.8V11.5c0-1.2,0.4-2.3,1.3-3.2S7.3,7,8.5,7H15c1.2,0,2.3,0.4,3.2,1.3c0.9,0.9,1.3,1.9,1.3,3.2 v0.6H33c1.2,0,2.3,0.4,3.2,1.3C37.1,14.4,37.5,15.4,37.5,16.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 164 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhQAASAMZzACYmJllZWRzE9y3I9y3J9y7I9y7J92HW+Xfc+oWFhYiIiJiYmKGhoaampqmpqby8vILf+6Xk+aXm+6fk+abm+6jn+6nn+67n+q/n+q7o+rDo+7Po+7Pp+8nJyd/f38Xu/Mfv/Mjv/M3u+8rw/NDv+9Dy/dXw+tfx/Nfy/Nny/Nry/Nzy+93y+9/z+9zz/N70/eLi4unp6ezs7O3t7e7u7uDz++H0++P0++L1/eP2/eX1++b1++f2++T2/eX2/eb3/ef3/ej2++j3/er3/Ov3/O33/On4/er4/ev4/ev4/u/4++34/Oz5/u35/u74/O/4/O75/u/5/u/6/vLy8vH4+/L5+/P5+/D4/PD6/vH6/vL6/vL7/vP7/vT5+/X6+/X6/PT7/vb6/Pf6/PX8/vb8/vf8/vj7/Pn7/Pr7/Pj9/vj9//n9//v8/Pr9//v+//z8/Pz+//3+//7//////////////////////////////////////////////////////yH5BAEAAH8ALAAAAABAABIAAAfGgH+Cg4SFhoeIiYqLjI2Oj5CRkpOUlZaXkUxCmIcdU5yEPQgfoIQNDjCRDwqJLwIEEpEZBzuJDTMMHo8PAACJKgIYAxSPEwICNrZ/Mgs0jbwBvogoAiIXBCCNEQIQAi3KfzEJM4vQ0Ykn1SQcAiWLxhDdNcrMzorm54gpAiQaBiGLMnCLJ+CGLVy6Fino1YsVIhcCNhCowOjAsWMHgthCVeoPDgEFLDTaYaNFjRtBniTy1PGPEQQjWsoUlAXKzJs4c+rcCSkQADs="

/***/ }),
/* 165 */
/***/ (function(module, exports, __webpack_require__) {

var anObject = __webpack_require__(166);
var IE8_DOM_DEFINE = __webpack_require__(613);
var toPrimitive = __webpack_require__(405);
var dP = Object.defineProperty;

exports.f = __webpack_require__(167) ? Object.defineProperty : function defineProperty(O, P, Attributes) {
  anObject(O);
  P = toPrimitive(P, true);
  anObject(Attributes);
  if (IE8_DOM_DEFINE) try {
    return dP(O, P, Attributes);
  } catch (e) { /* empty */ }
  if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported!');
  if ('value' in Attributes) O[P] = Attributes.value;
  return O;
};


/***/ }),
/* 166 */
/***/ (function(module, exports, __webpack_require__) {

var isObject = __webpack_require__(174);
module.exports = function (it) {
  if (!isObject(it)) throw TypeError(it + ' is not an object!');
  return it;
};


/***/ }),
/* 167 */
/***/ (function(module, exports, __webpack_require__) {

// Thank's IE8 for his funny defineProperty
module.exports = !__webpack_require__(219)(function () {
  return Object.defineProperty({}, 'a', { get: function () { return 7; } }).a != 7;
});


/***/ }),
/* 168 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1167);

/***/ }),
/* 169 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M14.2,20.9c-2,0.1-3.7,0.9-5,2.4H6.7c-1,0-1.9-0.3-2.6-0.8C3.4,22.1,3,21.3,3,20.3c0-4.4,0.8-6.7,2.3-6.7 c0.1,0,0.3,0.1,0.8,0.4c0.5,0.3,1.1,0.5,1.8,0.8c0.8,0.3,1.5,0.4,2.2,0.4c0.8,0,1.7-0.1,2.5-0.4c-0.1,0.5-0.1,0.9-0.1,1.2 C12.7,17.8,13.2,19.4,14.2,20.9z M34.7,33.1c0,1.5-0.5,2.7-1.4,3.6c-0.9,0.9-2.1,1.3-3.7,1.3H13.2c-1.5,0-2.7-0.4-3.7-1.3 c-0.9-0.9-1.4-2.1-1.4-3.6c0-0.7,0-1.3,0.1-2s0.1-1.3,0.3-2.1c0.1-0.7,0.3-1.4,0.5-2s0.5-1.2,0.8-1.8c0.3-0.6,0.7-1.1,1.2-1.5 c0.4-0.4,1-0.8,1.6-1s1.3-0.4,2.1-0.4c0.1,0,0.4,0.1,0.8,0.4c0.4,0.3,0.9,0.6,1.4,0.9s1.2,0.6,2,0.9c0.8,0.3,1.7,0.4,2.5,0.4 s1.7-0.1,2.5-0.4c0.8-0.3,1.5-0.6,2-0.9c0.5-0.3,1-0.6,1.4-0.9s0.7-0.4,0.8-0.4c0.8,0,1.5,0.1,2.1,0.4s1.2,0.6,1.6,1 c0.4,0.4,0.8,0.9,1.2,1.5c0.3,0.6,0.6,1.2,0.8,1.8c0.2,0.6,0.4,1.3,0.5,2c0.1,0.7,0.2,1.4,0.3,2.1S34.7,32.5,34.7,33.1z M15.1,8.8 c0,1.3-0.5,2.5-1.4,3.4s-2.1,1.4-3.4,1.4s-2.5-0.5-3.4-1.4s-1.4-2.1-1.4-3.4s0.5-2.5,1.4-3.4S8.9,4,10.2,4s2.5,0.5,3.4,1.4 S15.1,7.5,15.1,8.8z M27.8,16.1c0,1.8-0.6,3.3-1.9,4.5c-1.3,1.3-2.8,1.9-4.5,1.9c-1.8,0-3.3-0.6-4.5-1.9c-1.3-1.3-1.9-2.8-1.9-4.5 s0.6-3.3,1.9-4.5s2.8-1.9,4.5-1.9c1.8,0,3.3,0.6,4.5,1.9C27.2,12.8,27.8,14.3,27.8,16.1z M39.8,20.3c0,1-0.4,1.7-1.1,2.2 c-0.7,0.5-1.6,0.8-2.6,0.8h-2.5c-1.3-1.5-3-2.4-5-2.4c1-1.5,1.5-3.1,1.5-4.8c0-0.4,0-0.8-0.1-1.2c0.8,0.3,1.7,0.4,2.5,0.4 c0.7,0,1.5-0.1,2.2-0.4c0.8-0.3,1.4-0.5,1.8-0.8c0.5-0.3,0.7-0.4,0.8-0.4C39,13.7,39.8,15.9,39.8,20.3z M37.4,8.8 c0,1.3-0.5,2.5-1.4,3.4c-0.9,0.9-2.1,1.4-3.4,1.4c-1.3,0-2.5-0.5-3.4-1.4c-0.9-0.9-1.4-2.1-1.4-3.4s0.5-2.5,1.4-3.4 C30.1,4.5,31.2,4,32.6,4C33.9,4,35,4.5,36,5.4C36.9,6.4,37.4,7.5,37.4,8.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 170 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28.7,31.9c0-0.3-0.1-0.6-0.3-0.8s-0.5-0.3-0.8-0.3c-0.3,0-0.6,0.1-0.8,0.3s-0.3,0.5-0.3,0.8s0.1,0.6,0.3,0.8 c0.2,0.2,0.5,0.3,0.8,0.3c0.3,0,0.6-0.1,0.8-0.3C28.6,32.5,28.7,32.3,28.7,31.9z M33.2,31.9c0-0.3-0.1-0.6-0.3-0.8s-0.5-0.3-0.8-0.3 s-0.6,0.1-0.8,0.3s-0.3,0.5-0.3,0.8s0.1,0.6,0.3,0.8c0.2,0.2,0.5,0.3,0.8,0.3s0.6-0.1,0.8-0.3C33.1,32.5,33.2,32.3,33.2,31.9z M35.5,28v5.7c0,0.5-0.2,0.9-0.5,1.2s-0.7,0.5-1.2,0.5H7.7c-0.5,0-0.9-0.2-1.2-0.5C6.2,34.5,6,34.1,6,33.6V28c0-0.5,0.2-0.9,0.5-1.2 c0.3-0.3,0.7-0.5,1.2-0.5h7.6c0.2,0.7,0.7,1.2,1.2,1.6c0.6,0.4,1.2,0.6,2,0.6H23c0.7,0,1.4-0.2,2-0.6s1-1,1.2-1.6h7.6 c0.5,0,0.9,0.2,1.2,0.5C35.3,27.1,35.5,27.5,35.5,28z M11.8,16.8c0.2-0.5,0.5-0.7,1-0.7h4.5V8.1c0-0.3,0.1-0.6,0.3-0.8 C17.9,7.1,18.2,7,18.5,7H23c0.3,0,0.6,0.1,0.8,0.3c0.2,0.2,0.3,0.5,0.3,0.8v7.9h4.5c0.5,0,0.8,0.2,1,0.7c0.2,0.5,0.1,0.9-0.2,1.2 l-7.9,7.9c-0.2,0.2-0.5,0.3-0.8,0.3s-0.6-0.1-0.8-0.3L12,18C11.6,17.6,11.6,17.2,11.8,16.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 171 */
/***/ (function(module, exports) {

var hasOwnProperty = {}.hasOwnProperty;
module.exports = function (it, key) {
  return hasOwnProperty.call(it, key);
};


/***/ }),
/* 172 */
/***/ (function(module, exports, __webpack_require__) {

// to indexed object, toObject with fallback for non-array-like ES3 strings
var IObject = __webpack_require__(1163);
var defined = __webpack_require__(379);
module.exports = function (it) {
  return IObject(defined(it));
};


/***/ }),
/* 173 */
/***/ (function(module, exports, __webpack_require__) {

var dP = __webpack_require__(165);
var createDesc = __webpack_require__(383);
module.exports = __webpack_require__(167) ? function (object, key, value) {
  return dP.f(object, key, createDesc(1, value));
} : function (object, key, value) {
  object[key] = value;
  return object;
};


/***/ }),
/* 174 */
/***/ (function(module, exports) {

module.exports = function (it) {
  return typeof it === 'object' ? it !== null : typeof it === 'function';
};


/***/ }),
/* 175 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

/**
 * Compare by conforming to PHP loose comparisons rules
 *
 * @see http://php.net/manual/en/types.comparisons.php
 * @see https://stackoverflow.com/questions/47969711/php-algorithm-loose-equality-comparison
 */
Object.defineProperty(exports, "__esModule", { value: true });
const luxon_1 = __webpack_require__(176);
function compare(firstOperand, secondOperand) {
    // array
    if (Array.isArray(firstOperand)) {
        return compareToArray(firstOperand, secondOperand);
    }
    // string
    if (typeof firstOperand === 'string') {
        return compareToString(firstOperand, secondOperand);
    }
    // number
    if (typeof firstOperand === 'number') {
        return compareToNumber(firstOperand, secondOperand);
    }
    // boolean
    if (typeof firstOperand === 'boolean') {
        return compareToBoolean(firstOperand, secondOperand);
    }
    // date
    if (firstOperand instanceof luxon_1.DateTime) {
        return compareToDateTime(firstOperand, secondOperand);
    }
    // null
    if (firstOperand === null) {
        return compareToNull(secondOperand);
    }
    // fallback to strict comparison
    return firstOperand === secondOperand;
}
exports.compare = compare;
/**
 * Compare an array to something else by conforming to PHP loose comparisons rules
 * ┌─────────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬─────────┬───────┬───────┐
 * │         │ TRUE  │ FALSE │   1   │   0   │  -1   │  "1"  │  "0"  │ "-1"  │ NULL  │ []    │ ["php"] | "php" │  ""   │
 * ├─────────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼─────────┼───────┼───────┤
 * │ []      │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ TRUE  │ TRUE  │ FALSE   │ FALSE │ FALSE |
 * │ ["php"] │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ TRUE    │ FALSE │ FALSE |
 * └─────────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴─────────┴───────┴───────┘
 */
function compareToArray(firstOperand, secondOperand) {
    if (firstOperand.length < 1) {
        return (secondOperand === false || secondOperand === null || (Array.isArray(secondOperand) && secondOperand.length < 1));
    }
    else {
        if (secondOperand === true) {
            return true;
        }
        else if (!Array.isArray(secondOperand)) {
            return false;
        }
        else if (firstOperand.length !== secondOperand.length) {
            return false;
        }
        let result = false;
        for (let i = 0; i < firstOperand.length; i++) {
            let valueItem = firstOperand[i];
            let compareItem = secondOperand[i];
            result = compare(valueItem, compareItem);
            if (!result) {
                break;
            }
        }
        return result;
    }
}
/**
 * Compare a boolean to something else by conforming to PHP loose comparisons rules
 * ┌─────────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬─────────┬───────┬───────┐
 * │         │ TRUE  │ FALSE │   1   │   0   │  -1   │  "1"  │  "0"  │ "-1"  │ NULL  │ array() │ "php" │  ""   │
 * ├─────────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼─────── ─┼───────┼───────┤
 * │ TRUE    │ TRUE  │ FALSE │ TRUE  │ FALSE │ TRUE  │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE   │ TRUE  │ FALSE │
 * │ FALSE   │ FALSE │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ TRUE  │ TRUE    │ FALSE │ TRUE  │
 * └─────────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴─────────┴───────┴───────┘
 */
function compareToBoolean(firstOperand, secondOperand) {
    if (typeof secondOperand === 'boolean') {
        return firstOperand === secondOperand;
    }
    if (typeof secondOperand === 'number') {
        return firstOperand === (secondOperand !== 0);
    }
    if (typeof secondOperand === 'string') {
        if (secondOperand.length > 1) {
            return firstOperand;
        }
        else {
            let float = parseFloat(secondOperand);
            if (!isNaN(float)) {
                return firstOperand === (float !== 0);
            }
            else {
                return firstOperand === (secondOperand.length > 0);
            }
        }
    }
    if (secondOperand === null) {
        return !firstOperand;
    }
    if (Array.isArray(secondOperand)) {
        return firstOperand === (secondOperand.length > 0);
    }
    return false;
}
/**
 * Compare a DateTime to something else by conforming to PHP loose comparisons rules
 * ┌─────────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬─────────┬───────┬───────┬───────┬───────┐
 * │         │ TRUE  │ FALSE │   1   │   0   │  -1   │  "1"  │  "0"  │ "-1"  │ NULL  │ []    │ ["php"] | "php" │  ""   │  NOW  | LATER |
 * ├─────────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼─────────┼───────┼───────┼───────┼───────┤
 * │  NOW    │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE   │ FALSE │ FALSE │ TRUE  │ FALSE │
 * │  LATER  │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE   │ FALSE │ FALSE │ FALSE │ TRUE  │
 * └─────────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴─────────┴───────┴───────┴───────┴───────┘
 */
function compareToDateTime(firstOperand, secondOperand) {
    if (secondOperand instanceof luxon_1.DateTime) {
        return firstOperand.valueOf() === secondOperand.valueOf();
    }
    return false;
}
/**
 * Compare null to something else by conforming to PHP loose comparisons rules
 * ┌─────────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬─────────┬───────┬───────┐
 * │         │ TRUE  │ FALSE │   1   │   0   │  -1   │  "1"  │  "0"  │ "-1"  │ NULL  │ []    │ ["php"] | "php" │  ""   │
 * ├─────────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼─────────┼───────┼───────┤
 * │ NULL    │ FALSE │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE │ TRUE  │ TRUE  │ FALSE   │ FALSE │ TRUE  |
 * └─────────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴─────────┴───────┴───────┘
 */
function compareToNull(value) {
    if (typeof value === 'boolean') {
        return (value === false);
    }
    if (typeof value === 'number') {
        return value === 0;
    }
    if (typeof value === 'string') {
        return value.length < 1;
    }
    if (value === null) {
        return true;
    }
    if (Array.isArray(value)) {
        return value.length < 1;
    }
    return false;
}
/**
 * Compare a number to something else by conforming to PHP loose comparisons rules
 * ┌─────────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬─────────┬───────┬───────┐
 * │         │ TRUE  │ FALSE │   1   │   0   │  -1   │  "1"  │  "0"  │ "-1"  │ NULL  │ array() │ "php" │  ""   │
 * ├─────────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼─────── ─┼───────┼───────┤
 * │ 1       │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE   │ FALSE │ FALSE │
 * │ 0       │ FALSE │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ TRUE  │ FALSE   │ TRUE  │ TRUE  │
 * │ -1      │ TRUE  │ FALSE │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE   │ FALSE │ FALSE │
 * └─────────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴─────────┴───────┴───────┘
 */
function compareToNumber(firstOperand, secondOperand) {
    if (typeof secondOperand === 'number') {
        return firstOperand === secondOperand;
    }
    if (typeof secondOperand === 'boolean') {
        return (firstOperand !== 0) === secondOperand;
    }
    if (secondOperand === null) {
        return firstOperand === 0;
    }
    if (typeof secondOperand === 'string') {
        let float = parseFloat(secondOperand);
        if (float) {
            return firstOperand === float;
        }
        else {
            return firstOperand === 0;
        }
    }
    return false;
}
/**
 * Compare a string to something else by conforming to PHP loose comparisons rules
 * ┌─────────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬───────┬─────────┬───────┬───────┐
 * │         │ TRUE  │ FALSE │   1   │   0   │  -1   │  "1"  │  "0"  │ "-1"  │ NULL  │ array() │ "php" │  ""   │
 * ├─────────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼───────┼─────── ─┼───────┼───────┤
 * │ "1"     │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE   │ FALSE │ FALSE │
 * │ "0"     │ FALSE │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE   │ FALSE │ FALSE │
 * │ "-1"    │ TRUE  │ FALSE │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE   │ FALSE │ FALSE │
 * │ ""      │ FALSE │ TRUE  │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE │ TRUE  │ FALSE   │ FALSE │ TRUE  │
 * │ "php"   │ TRUE  │ FALSE │ FALSE │ TRUE  │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE │ FALSE   │ TRUE  │ FALSE │
 * └─────────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴───────┴─────────┴───────┴───────┘
 */
function compareToString(firstOperand, secondOperand) {
    if (typeof secondOperand === 'string') {
        return firstOperand === secondOperand;
    }
    if (typeof secondOperand === 'boolean') {
        if (firstOperand.length < 1 || firstOperand === '0') {
            return !secondOperand;
        }
        return secondOperand;
    }
    if (secondOperand === null) {
        return firstOperand.length < 1;
    }
    if (typeof secondOperand === 'number') {
        let float = parseFloat(firstOperand);
        if (float) {
            return secondOperand === float;
        }
        else {
            return secondOperand === 0;
        }
    }
    return false;
}


/***/ }),
/* 176 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


Object.defineProperty(exports, '__esModule', { value: true });

function _defineProperties(target, props) {
  for (var i = 0; i < props.length; i++) {
    var descriptor = props[i];
    descriptor.enumerable = descriptor.enumerable || false;
    descriptor.configurable = true;
    if ("value" in descriptor) descriptor.writable = true;
    Object.defineProperty(target, descriptor.key, descriptor);
  }
}

function _createClass(Constructor, protoProps, staticProps) {
  if (protoProps) _defineProperties(Constructor.prototype, protoProps);
  if (staticProps) _defineProperties(Constructor, staticProps);
  return Constructor;
}

function _inheritsLoose(subClass, superClass) {
  subClass.prototype = Object.create(superClass.prototype);
  subClass.prototype.constructor = subClass;
  subClass.__proto__ = superClass;
}

function _getPrototypeOf(o) {
  _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
    return o.__proto__ || Object.getPrototypeOf(o);
  };
  return _getPrototypeOf(o);
}

function _setPrototypeOf(o, p) {
  _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
    o.__proto__ = p;
    return o;
  };

  return _setPrototypeOf(o, p);
}

function _isNativeReflectConstruct() {
  if (typeof Reflect === "undefined" || !Reflect.construct) return false;
  if (Reflect.construct.sham) return false;
  if (typeof Proxy === "function") return true;

  try {
    Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));
    return true;
  } catch (e) {
    return false;
  }
}

function _construct(Parent, args, Class) {
  if (_isNativeReflectConstruct()) {
    _construct = Reflect.construct;
  } else {
    _construct = function _construct(Parent, args, Class) {
      var a = [null];
      a.push.apply(a, args);
      var Constructor = Function.bind.apply(Parent, a);
      var instance = new Constructor();
      if (Class) _setPrototypeOf(instance, Class.prototype);
      return instance;
    };
  }

  return _construct.apply(null, arguments);
}

function _isNativeFunction(fn) {
  return Function.toString.call(fn).indexOf("[native code]") !== -1;
}

function _wrapNativeSuper(Class) {
  var _cache = typeof Map === "function" ? new Map() : undefined;

  _wrapNativeSuper = function _wrapNativeSuper(Class) {
    if (Class === null || !_isNativeFunction(Class)) return Class;

    if (typeof Class !== "function") {
      throw new TypeError("Super expression must either be null or a function");
    }

    if (typeof _cache !== "undefined") {
      if (_cache.has(Class)) return _cache.get(Class);

      _cache.set(Class, Wrapper);
    }

    function Wrapper() {
      return _construct(Class, arguments, _getPrototypeOf(this).constructor);
    }

    Wrapper.prototype = Object.create(Class.prototype, {
      constructor: {
        value: Wrapper,
        enumerable: false,
        writable: true,
        configurable: true
      }
    });
    return _setPrototypeOf(Wrapper, Class);
  };

  return _wrapNativeSuper(Class);
}

function _objectWithoutPropertiesLoose(source, excluded) {
  if (source == null) return {};
  var target = {};
  var sourceKeys = Object.keys(source);
  var key, i;

  for (i = 0; i < sourceKeys.length; i++) {
    key = sourceKeys[i];
    if (excluded.indexOf(key) >= 0) continue;
    target[key] = source[key];
  }

  return target;
}

function _unsupportedIterableToArray(o, minLen) {
  if (!o) return;
  if (typeof o === "string") return _arrayLikeToArray(o, minLen);
  var n = Object.prototype.toString.call(o).slice(8, -1);
  if (n === "Object" && o.constructor) n = o.constructor.name;
  if (n === "Map" || n === "Set") return Array.from(o);
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
}

function _arrayLikeToArray(arr, len) {
  if (len == null || len > arr.length) len = arr.length;

  for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];

  return arr2;
}

function _createForOfIteratorHelperLoose(o) {
  var i = 0;

  if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) {
    if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) return function () {
      if (i >= o.length) return {
        done: true
      };
      return {
        done: false,
        value: o[i++]
      };
    };
    throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
  }

  i = o[Symbol.iterator]();
  return i.next.bind(i);
}

// these aren't really private, but nor are they really useful to document

/**
 * @private
 */
var LuxonError = /*#__PURE__*/function (_Error) {
  _inheritsLoose(LuxonError, _Error);

  function LuxonError() {
    return _Error.apply(this, arguments) || this;
  }

  return LuxonError;
}( /*#__PURE__*/_wrapNativeSuper(Error));
/**
 * @private
 */


var InvalidDateTimeError = /*#__PURE__*/function (_LuxonError) {
  _inheritsLoose(InvalidDateTimeError, _LuxonError);

  function InvalidDateTimeError(reason) {
    return _LuxonError.call(this, "Invalid DateTime: " + reason.toMessage()) || this;
  }

  return InvalidDateTimeError;
}(LuxonError);
/**
 * @private
 */

var InvalidIntervalError = /*#__PURE__*/function (_LuxonError2) {
  _inheritsLoose(InvalidIntervalError, _LuxonError2);

  function InvalidIntervalError(reason) {
    return _LuxonError2.call(this, "Invalid Interval: " + reason.toMessage()) || this;
  }

  return InvalidIntervalError;
}(LuxonError);
/**
 * @private
 */

var InvalidDurationError = /*#__PURE__*/function (_LuxonError3) {
  _inheritsLoose(InvalidDurationError, _LuxonError3);

  function InvalidDurationError(reason) {
    return _LuxonError3.call(this, "Invalid Duration: " + reason.toMessage()) || this;
  }

  return InvalidDurationError;
}(LuxonError);
/**
 * @private
 */

var ConflictingSpecificationError = /*#__PURE__*/function (_LuxonError4) {
  _inheritsLoose(ConflictingSpecificationError, _LuxonError4);

  function ConflictingSpecificationError() {
    return _LuxonError4.apply(this, arguments) || this;
  }

  return ConflictingSpecificationError;
}(LuxonError);
/**
 * @private
 */

var InvalidUnitError = /*#__PURE__*/function (_LuxonError5) {
  _inheritsLoose(InvalidUnitError, _LuxonError5);

  function InvalidUnitError(unit) {
    return _LuxonError5.call(this, "Invalid unit " + unit) || this;
  }

  return InvalidUnitError;
}(LuxonError);
/**
 * @private
 */

var InvalidArgumentError = /*#__PURE__*/function (_LuxonError6) {
  _inheritsLoose(InvalidArgumentError, _LuxonError6);

  function InvalidArgumentError() {
    return _LuxonError6.apply(this, arguments) || this;
  }

  return InvalidArgumentError;
}(LuxonError);
/**
 * @private
 */

var ZoneIsAbstractError = /*#__PURE__*/function (_LuxonError7) {
  _inheritsLoose(ZoneIsAbstractError, _LuxonError7);

  function ZoneIsAbstractError() {
    return _LuxonError7.call(this, "Zone is an abstract class") || this;
  }

  return ZoneIsAbstractError;
}(LuxonError);

/**
 * @private
 */
var n = "numeric",
    s = "short",
    l = "long";
var DATE_SHORT = {
  year: n,
  month: n,
  day: n
};
var DATE_MED = {
  year: n,
  month: s,
  day: n
};
var DATE_FULL = {
  year: n,
  month: l,
  day: n
};
var DATE_HUGE = {
  year: n,
  month: l,
  day: n,
  weekday: l
};
var TIME_SIMPLE = {
  hour: n,
  minute: n
};
var TIME_WITH_SECONDS = {
  hour: n,
  minute: n,
  second: n
};
var TIME_WITH_SHORT_OFFSET = {
  hour: n,
  minute: n,
  second: n,
  timeZoneName: s
};
var TIME_WITH_LONG_OFFSET = {
  hour: n,
  minute: n,
  second: n,
  timeZoneName: l
};
var TIME_24_SIMPLE = {
  hour: n,
  minute: n,
  hour12: false
};
/**
 * {@link toLocaleString}; format like '09:30:23', always 24-hour.
 */

var TIME_24_WITH_SECONDS = {
  hour: n,
  minute: n,
  second: n,
  hour12: false
};
/**
 * {@link toLocaleString}; format like '09:30:23 EDT', always 24-hour.
 */

var TIME_24_WITH_SHORT_OFFSET = {
  hour: n,
  minute: n,
  second: n,
  hour12: false,
  timeZoneName: s
};
/**
 * {@link toLocaleString}; format like '09:30:23 Eastern Daylight Time', always 24-hour.
 */

var TIME_24_WITH_LONG_OFFSET = {
  hour: n,
  minute: n,
  second: n,
  hour12: false,
  timeZoneName: l
};
/**
 * {@link toLocaleString}; format like '10/14/1983, 9:30 AM'. Only 12-hour if the locale is.
 */

var DATETIME_SHORT = {
  year: n,
  month: n,
  day: n,
  hour: n,
  minute: n
};
/**
 * {@link toLocaleString}; format like '10/14/1983, 9:30:33 AM'. Only 12-hour if the locale is.
 */

var DATETIME_SHORT_WITH_SECONDS = {
  year: n,
  month: n,
  day: n,
  hour: n,
  minute: n,
  second: n
};
var DATETIME_MED = {
  year: n,
  month: s,
  day: n,
  hour: n,
  minute: n
};
var DATETIME_MED_WITH_SECONDS = {
  year: n,
  month: s,
  day: n,
  hour: n,
  minute: n,
  second: n
};
var DATETIME_MED_WITH_WEEKDAY = {
  year: n,
  month: s,
  day: n,
  weekday: s,
  hour: n,
  minute: n
};
var DATETIME_FULL = {
  year: n,
  month: l,
  day: n,
  hour: n,
  minute: n,
  timeZoneName: s
};
var DATETIME_FULL_WITH_SECONDS = {
  year: n,
  month: l,
  day: n,
  hour: n,
  minute: n,
  second: n,
  timeZoneName: s
};
var DATETIME_HUGE = {
  year: n,
  month: l,
  day: n,
  weekday: l,
  hour: n,
  minute: n,
  timeZoneName: l
};
var DATETIME_HUGE_WITH_SECONDS = {
  year: n,
  month: l,
  day: n,
  weekday: l,
  hour: n,
  minute: n,
  second: n,
  timeZoneName: l
};

/*
  This is just a junk drawer, containing anything used across multiple classes.
  Because Luxon is small(ish), this should stay small and we won't worry about splitting
  it up into, say, parsingUtil.js and basicUtil.js and so on. But they are divided up by feature area.
*/
/**
 * @private
 */
// TYPES

function isUndefined(o) {
  return typeof o === "undefined";
}
function isNumber(o) {
  return typeof o === "number";
}
function isInteger(o) {
  return typeof o === "number" && o % 1 === 0;
}
function isString(o) {
  return typeof o === "string";
}
function isDate(o) {
  return Object.prototype.toString.call(o) === "[object Date]";
} // CAPABILITIES

function hasIntl() {
  try {
    return typeof Intl !== "undefined" && Intl.DateTimeFormat;
  } catch (e) {
    return false;
  }
}
function hasFormatToParts() {
  return !isUndefined(Intl.DateTimeFormat.prototype.formatToParts);
}
function hasRelative() {
  try {
    return typeof Intl !== "undefined" && !!Intl.RelativeTimeFormat;
  } catch (e) {
    return false;
  }
} // OBJECTS AND ARRAYS

function maybeArray(thing) {
  return Array.isArray(thing) ? thing : [thing];
}
function bestBy(arr, by, compare) {
  if (arr.length === 0) {
    return undefined;
  }

  return arr.reduce(function (best, next) {
    var pair = [by(next), next];

    if (!best) {
      return pair;
    } else if (compare(best[0], pair[0]) === best[0]) {
      return best;
    } else {
      return pair;
    }
  }, null)[1];
}
function pick(obj, keys) {
  return keys.reduce(function (a, k) {
    a[k] = obj[k];
    return a;
  }, {});
}
function hasOwnProperty(obj, prop) {
  return Object.prototype.hasOwnProperty.call(obj, prop);
} // NUMBERS AND STRINGS

function integerBetween(thing, bottom, top) {
  return isInteger(thing) && thing >= bottom && thing <= top;
} // x % n but takes the sign of n instead of x

function floorMod(x, n) {
  return x - n * Math.floor(x / n);
}
function padStart(input, n) {
  if (n === void 0) {
    n = 2;
  }

  if (input.toString().length < n) {
    return ("0".repeat(n) + input).slice(-n);
  } else {
    return input.toString();
  }
}
function parseInteger(string) {
  if (isUndefined(string) || string === null || string === "") {
    return undefined;
  } else {
    return parseInt(string, 10);
  }
}
function parseMillis(fraction) {
  // Return undefined (instead of 0) in these cases, where fraction is not set
  if (isUndefined(fraction) || fraction === null || fraction === "") {
    return undefined;
  } else {
    var f = parseFloat("0." + fraction) * 1000;
    return Math.floor(f);
  }
}
function roundTo(number, digits, towardZero) {
  if (towardZero === void 0) {
    towardZero = false;
  }

  var factor = Math.pow(10, digits),
      rounder = towardZero ? Math.trunc : Math.round;
  return rounder(number * factor) / factor;
} // DATE BASICS

function isLeapYear(year) {
  return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0);
}
function daysInYear(year) {
  return isLeapYear(year) ? 366 : 365;
}
function daysInMonth(year, month) {
  var modMonth = floorMod(month - 1, 12) + 1,
      modYear = year + (month - modMonth) / 12;

  if (modMonth === 2) {
    return isLeapYear(modYear) ? 29 : 28;
  } else {
    return [31, null, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][modMonth - 1];
  }
} // covert a calendar object to a local timestamp (epoch, but with the offset baked in)

function objToLocalTS(obj) {
  var d = Date.UTC(obj.year, obj.month - 1, obj.day, obj.hour, obj.minute, obj.second, obj.millisecond); // for legacy reasons, years between 0 and 99 are interpreted as 19XX; revert that

  if (obj.year < 100 && obj.year >= 0) {
    d = new Date(d);
    d.setUTCFullYear(d.getUTCFullYear() - 1900);
  }

  return +d;
}
function weeksInWeekYear(weekYear) {
  var p1 = (weekYear + Math.floor(weekYear / 4) - Math.floor(weekYear / 100) + Math.floor(weekYear / 400)) % 7,
      last = weekYear - 1,
      p2 = (last + Math.floor(last / 4) - Math.floor(last / 100) + Math.floor(last / 400)) % 7;
  return p1 === 4 || p2 === 3 ? 53 : 52;
}
function untruncateYear(year) {
  if (year > 99) {
    return year;
  } else return year > 60 ? 1900 + year : 2000 + year;
} // PARSING

function parseZoneInfo(ts, offsetFormat, locale, timeZone) {
  if (timeZone === void 0) {
    timeZone = null;
  }

  var date = new Date(ts),
      intlOpts = {
    hour12: false,
    year: "numeric",
    month: "2-digit",
    day: "2-digit",
    hour: "2-digit",
    minute: "2-digit"
  };

  if (timeZone) {
    intlOpts.timeZone = timeZone;
  }

  var modified = Object.assign({
    timeZoneName: offsetFormat
  }, intlOpts),
      intl = hasIntl();

  if (intl && hasFormatToParts()) {
    var parsed = new Intl.DateTimeFormat(locale, modified).formatToParts(date).find(function (m) {
      return m.type.toLowerCase() === "timezonename";
    });
    return parsed ? parsed.value : null;
  } else if (intl) {
    // this probably doesn't work for all locales
    var without = new Intl.DateTimeFormat(locale, intlOpts).format(date),
        included = new Intl.DateTimeFormat(locale, modified).format(date),
        diffed = included.substring(without.length),
        trimmed = diffed.replace(/^[, \u200e]+/, "");
    return trimmed;
  } else {
    return null;
  }
} // signedOffset('-5', '30') -> -330

function signedOffset(offHourStr, offMinuteStr) {
  var offHour = parseInt(offHourStr, 10); // don't || this because we want to preserve -0

  if (Number.isNaN(offHour)) {
    offHour = 0;
  }

  var offMin = parseInt(offMinuteStr, 10) || 0,
      offMinSigned = offHour < 0 || Object.is(offHour, -0) ? -offMin : offMin;
  return offHour * 60 + offMinSigned;
} // COERCION

function asNumber(value) {
  var numericValue = Number(value);
  if (typeof value === "boolean" || value === "" || Number.isNaN(numericValue)) throw new InvalidArgumentError("Invalid unit value " + value);
  return numericValue;
}
function normalizeObject(obj, normalizer, nonUnitKeys) {
  var normalized = {};

  for (var u in obj) {
    if (hasOwnProperty(obj, u)) {
      if (nonUnitKeys.indexOf(u) >= 0) continue;
      var v = obj[u];
      if (v === undefined || v === null) continue;
      normalized[normalizer(u)] = asNumber(v);
    }
  }

  return normalized;
}
function formatOffset(offset, format) {
  var hours = Math.trunc(offset / 60),
      minutes = Math.abs(offset % 60),
      sign = hours >= 0 && !Object.is(hours, -0) ? "+" : "-",
      base = "" + sign + Math.abs(hours);

  switch (format) {
    case "short":
      return "" + sign + padStart(Math.abs(hours), 2) + ":" + padStart(minutes, 2);

    case "narrow":
      return minutes > 0 ? base + ":" + minutes : base;

    case "techie":
      return "" + sign + padStart(Math.abs(hours), 2) + padStart(minutes, 2);

    default:
      throw new RangeError("Value format " + format + " is out of range for property format");
  }
}
function timeObject(obj) {
  return pick(obj, ["hour", "minute", "second", "millisecond"]);
}
var ianaRegex = /[A-Za-z_+-]{1,256}(:?\/[A-Za-z_+-]{1,256}(\/[A-Za-z_+-]{1,256})?)?/;

function stringify(obj) {
  return JSON.stringify(obj, Object.keys(obj).sort());
}
/**
 * @private
 */


var monthsLong = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
var monthsShort = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
var monthsNarrow = ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"];
function months(length) {
  switch (length) {
    case "narrow":
      return monthsNarrow;

    case "short":
      return monthsShort;

    case "long":
      return monthsLong;

    case "numeric":
      return ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12"];

    case "2-digit":
      return ["01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12"];

    default:
      return null;
  }
}
var weekdaysLong = ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"];
var weekdaysShort = ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"];
var weekdaysNarrow = ["M", "T", "W", "T", "F", "S", "S"];
function weekdays(length) {
  switch (length) {
    case "narrow":
      return weekdaysNarrow;

    case "short":
      return weekdaysShort;

    case "long":
      return weekdaysLong;

    case "numeric":
      return ["1", "2", "3", "4", "5", "6", "7"];

    default:
      return null;
  }
}
var meridiems = ["AM", "PM"];
var erasLong = ["Before Christ", "Anno Domini"];
var erasShort = ["BC", "AD"];
var erasNarrow = ["B", "A"];
function eras(length) {
  switch (length) {
    case "narrow":
      return erasNarrow;

    case "short":
      return erasShort;

    case "long":
      return erasLong;

    default:
      return null;
  }
}
function meridiemForDateTime(dt) {
  return meridiems[dt.hour < 12 ? 0 : 1];
}
function weekdayForDateTime(dt, length) {
  return weekdays(length)[dt.weekday - 1];
}
function monthForDateTime(dt, length) {
  return months(length)[dt.month - 1];
}
function eraForDateTime(dt, length) {
  return eras(length)[dt.year < 0 ? 0 : 1];
}
function formatRelativeTime(unit, count, numeric, narrow) {
  if (numeric === void 0) {
    numeric = "always";
  }

  if (narrow === void 0) {
    narrow = false;
  }

  var units = {
    years: ["year", "yr."],
    quarters: ["quarter", "qtr."],
    months: ["month", "mo."],
    weeks: ["week", "wk."],
    days: ["day", "day", "days"],
    hours: ["hour", "hr."],
    minutes: ["minute", "min."],
    seconds: ["second", "sec."]
  };
  var lastable = ["hours", "minutes", "seconds"].indexOf(unit) === -1;

  if (numeric === "auto" && lastable) {
    var isDay = unit === "days";

    switch (count) {
      case 1:
        return isDay ? "tomorrow" : "next " + units[unit][0];

      case -1:
        return isDay ? "yesterday" : "last " + units[unit][0];

      case 0:
        return isDay ? "today" : "this " + units[unit][0];

    }
  }

  var isInPast = Object.is(count, -0) || count < 0,
      fmtValue = Math.abs(count),
      singular = fmtValue === 1,
      lilUnits = units[unit],
      fmtUnit = narrow ? singular ? lilUnits[1] : lilUnits[2] || lilUnits[1] : singular ? units[unit][0] : unit;
  return isInPast ? fmtValue + " " + fmtUnit + " ago" : "in " + fmtValue + " " + fmtUnit;
}
function formatString(knownFormat) {
  // these all have the offsets removed because we don't have access to them
  // without all the intl stuff this is backfilling
  var filtered = pick(knownFormat, ["weekday", "era", "year", "month", "day", "hour", "minute", "second", "timeZoneName", "hour12"]),
      key = stringify(filtered),
      dateTimeHuge = "EEEE, LLLL d, yyyy, h:mm a";

  switch (key) {
    case stringify(DATE_SHORT):
      return "M/d/yyyy";

    case stringify(DATE_MED):
      return "LLL d, yyyy";

    case stringify(DATE_FULL):
      return "LLLL d, yyyy";

    case stringify(DATE_HUGE):
      return "EEEE, LLLL d, yyyy";

    case stringify(TIME_SIMPLE):
      return "h:mm a";

    case stringify(TIME_WITH_SECONDS):
      return "h:mm:ss a";

    case stringify(TIME_WITH_SHORT_OFFSET):
      return "h:mm a";

    case stringify(TIME_WITH_LONG_OFFSET):
      return "h:mm a";

    case stringify(TIME_24_SIMPLE):
      return "HH:mm";

    case stringify(TIME_24_WITH_SECONDS):
      return "HH:mm:ss";

    case stringify(TIME_24_WITH_SHORT_OFFSET):
      return "HH:mm";

    case stringify(TIME_24_WITH_LONG_OFFSET):
      return "HH:mm";

    case stringify(DATETIME_SHORT):
      return "M/d/yyyy, h:mm a";

    case stringify(DATETIME_MED):
      return "LLL d, yyyy, h:mm a";

    case stringify(DATETIME_FULL):
      return "LLLL d, yyyy, h:mm a";

    case stringify(DATETIME_HUGE):
      return dateTimeHuge;

    case stringify(DATETIME_SHORT_WITH_SECONDS):
      return "M/d/yyyy, h:mm:ss a";

    case stringify(DATETIME_MED_WITH_SECONDS):
      return "LLL d, yyyy, h:mm:ss a";

    case stringify(DATETIME_MED_WITH_WEEKDAY):
      return "EEE, d LLL yyyy, h:mm a";

    case stringify(DATETIME_FULL_WITH_SECONDS):
      return "LLLL d, yyyy, h:mm:ss a";

    case stringify(DATETIME_HUGE_WITH_SECONDS):
      return "EEEE, LLLL d, yyyy, h:mm:ss a";

    default:
      return dateTimeHuge;
  }
}

function stringifyTokens(splits, tokenToString) {
  var s = "";

  for (var _iterator = _createForOfIteratorHelperLoose(splits), _step; !(_step = _iterator()).done;) {
    var token = _step.value;

    if (token.literal) {
      s += token.val;
    } else {
      s += tokenToString(token.val);
    }
  }

  return s;
}

var _macroTokenToFormatOpts = {
  D: DATE_SHORT,
  DD: DATE_MED,
  DDD: DATE_FULL,
  DDDD: DATE_HUGE,
  t: TIME_SIMPLE,
  tt: TIME_WITH_SECONDS,
  ttt: TIME_WITH_SHORT_OFFSET,
  tttt: TIME_WITH_LONG_OFFSET,
  T: TIME_24_SIMPLE,
  TT: TIME_24_WITH_SECONDS,
  TTT: TIME_24_WITH_SHORT_OFFSET,
  TTTT: TIME_24_WITH_LONG_OFFSET,
  f: DATETIME_SHORT,
  ff: DATETIME_MED,
  fff: DATETIME_FULL,
  ffff: DATETIME_HUGE,
  F: DATETIME_SHORT_WITH_SECONDS,
  FF: DATETIME_MED_WITH_SECONDS,
  FFF: DATETIME_FULL_WITH_SECONDS,
  FFFF: DATETIME_HUGE_WITH_SECONDS
};
/**
 * @private
 */

var Formatter = /*#__PURE__*/function () {
  Formatter.create = function create(locale, opts) {
    if (opts === void 0) {
      opts = {};
    }

    return new Formatter(locale, opts);
  };

  Formatter.parseFormat = function parseFormat(fmt) {
    var current = null,
        currentFull = "",
        bracketed = false;
    var splits = [];

    for (var i = 0; i < fmt.length; i++) {
      var c = fmt.charAt(i);

      if (c === "'") {
        if (currentFull.length > 0) {
          splits.push({
            literal: bracketed,
            val: currentFull
          });
        }

        current = null;
        currentFull = "";
        bracketed = !bracketed;
      } else if (bracketed) {
        currentFull += c;
      } else if (c === current) {
        currentFull += c;
      } else {
        if (currentFull.length > 0) {
          splits.push({
            literal: false,
            val: currentFull
          });
        }

        currentFull = c;
        current = c;
      }
    }

    if (currentFull.length > 0) {
      splits.push({
        literal: bracketed,
        val: currentFull
      });
    }

    return splits;
  };

  Formatter.macroTokenToFormatOpts = function macroTokenToFormatOpts(token) {
    return _macroTokenToFormatOpts[token];
  };

  function Formatter(locale, formatOpts) {
    this.opts = formatOpts;
    this.loc = locale;
    this.systemLoc = null;
  }

  var _proto = Formatter.prototype;

  _proto.formatWithSystemDefault = function formatWithSystemDefault(dt, opts) {
    if (this.systemLoc === null) {
      this.systemLoc = this.loc.redefaultToSystem();
    }

    var df = this.systemLoc.dtFormatter(dt, Object.assign({}, this.opts, opts));
    return df.format();
  };

  _proto.formatDateTime = function formatDateTime(dt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var df = this.loc.dtFormatter(dt, Object.assign({}, this.opts, opts));
    return df.format();
  };

  _proto.formatDateTimeParts = function formatDateTimeParts(dt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var df = this.loc.dtFormatter(dt, Object.assign({}, this.opts, opts));
    return df.formatToParts();
  };

  _proto.resolvedOptions = function resolvedOptions(dt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var df = this.loc.dtFormatter(dt, Object.assign({}, this.opts, opts));
    return df.resolvedOptions();
  };

  _proto.num = function num(n, p) {
    if (p === void 0) {
      p = 0;
    }

    // we get some perf out of doing this here, annoyingly
    if (this.opts.forceSimple) {
      return padStart(n, p);
    }

    var opts = Object.assign({}, this.opts);

    if (p > 0) {
      opts.padTo = p;
    }

    return this.loc.numberFormatter(opts).format(n);
  };

  _proto.formatDateTimeFromString = function formatDateTimeFromString(dt, fmt) {
    var _this = this;

    var knownEnglish = this.loc.listingMode() === "en",
        useDateTimeFormatter = this.loc.outputCalendar && this.loc.outputCalendar !== "gregory" && hasFormatToParts(),
        string = function string(opts, extract) {
      return _this.loc.extract(dt, opts, extract);
    },
        formatOffset = function formatOffset(opts) {
      if (dt.isOffsetFixed && dt.offset === 0 && opts.allowZ) {
        return "Z";
      }

      return dt.isValid ? dt.zone.formatOffset(dt.ts, opts.format) : "";
    },
        meridiem = function meridiem() {
      return knownEnglish ? meridiemForDateTime(dt) : string({
        hour: "numeric",
        hour12: true
      }, "dayperiod");
    },
        month = function month(length, standalone) {
      return knownEnglish ? monthForDateTime(dt, length) : string(standalone ? {
        month: length
      } : {
        month: length,
        day: "numeric"
      }, "month");
    },
        weekday = function weekday(length, standalone) {
      return knownEnglish ? weekdayForDateTime(dt, length) : string(standalone ? {
        weekday: length
      } : {
        weekday: length,
        month: "long",
        day: "numeric"
      }, "weekday");
    },
        maybeMacro = function maybeMacro(token) {
      var formatOpts = Formatter.macroTokenToFormatOpts(token);

      if (formatOpts) {
        return _this.formatWithSystemDefault(dt, formatOpts);
      } else {
        return token;
      }
    },
        era = function era(length) {
      return knownEnglish ? eraForDateTime(dt, length) : string({
        era: length
      }, "era");
    },
        tokenToString = function tokenToString(token) {
      // Where possible: http://cldr.unicode.org/translation/date-time#TOC-Stand-Alone-vs.-Format-Styles
      switch (token) {
        // ms
        case "S":
          return _this.num(dt.millisecond);

        case "u": // falls through

        case "SSS":
          return _this.num(dt.millisecond, 3);
        // seconds

        case "s":
          return _this.num(dt.second);

        case "ss":
          return _this.num(dt.second, 2);
        // minutes

        case "m":
          return _this.num(dt.minute);

        case "mm":
          return _this.num(dt.minute, 2);
        // hours

        case "h":
          return _this.num(dt.hour % 12 === 0 ? 12 : dt.hour % 12);

        case "hh":
          return _this.num(dt.hour % 12 === 0 ? 12 : dt.hour % 12, 2);

        case "H":
          return _this.num(dt.hour);

        case "HH":
          return _this.num(dt.hour, 2);
        // offset

        case "Z":
          // like +6
          return formatOffset({
            format: "narrow",
            allowZ: _this.opts.allowZ
          });

        case "ZZ":
          // like +06:00
          return formatOffset({
            format: "short",
            allowZ: _this.opts.allowZ
          });

        case "ZZZ":
          // like +0600
          return formatOffset({
            format: "techie",
            allowZ: _this.opts.allowZ
          });

        case "ZZZZ":
          // like EST
          return dt.zone.offsetName(dt.ts, {
            format: "short",
            locale: _this.loc.locale
          });

        case "ZZZZZ":
          // like Eastern Standard Time
          return dt.zone.offsetName(dt.ts, {
            format: "long",
            locale: _this.loc.locale
          });
        // zone

        case "z":
          // like America/New_York
          return dt.zoneName;
        // meridiems

        case "a":
          return meridiem();
        // dates

        case "d":
          return useDateTimeFormatter ? string({
            day: "numeric"
          }, "day") : _this.num(dt.day);

        case "dd":
          return useDateTimeFormatter ? string({
            day: "2-digit"
          }, "day") : _this.num(dt.day, 2);
        // weekdays - standalone

        case "c":
          // like 1
          return _this.num(dt.weekday);

        case "ccc":
          // like 'Tues'
          return weekday("short", true);

        case "cccc":
          // like 'Tuesday'
          return weekday("long", true);

        case "ccccc":
          // like 'T'
          return weekday("narrow", true);
        // weekdays - format

        case "E":
          // like 1
          return _this.num(dt.weekday);

        case "EEE":
          // like 'Tues'
          return weekday("short", false);

        case "EEEE":
          // like 'Tuesday'
          return weekday("long", false);

        case "EEEEE":
          // like 'T'
          return weekday("narrow", false);
        // months - standalone

        case "L":
          // like 1
          return useDateTimeFormatter ? string({
            month: "numeric",
            day: "numeric"
          }, "month") : _this.num(dt.month);

        case "LL":
          // like 01, doesn't seem to work
          return useDateTimeFormatter ? string({
            month: "2-digit",
            day: "numeric"
          }, "month") : _this.num(dt.month, 2);

        case "LLL":
          // like Jan
          return month("short", true);

        case "LLLL":
          // like January
          return month("long", true);

        case "LLLLL":
          // like J
          return month("narrow", true);
        // months - format

        case "M":
          // like 1
          return useDateTimeFormatter ? string({
            month: "numeric"
          }, "month") : _this.num(dt.month);

        case "MM":
          // like 01
          return useDateTimeFormatter ? string({
            month: "2-digit"
          }, "month") : _this.num(dt.month, 2);

        case "MMM":
          // like Jan
          return month("short", false);

        case "MMMM":
          // like January
          return month("long", false);

        case "MMMMM":
          // like J
          return month("narrow", false);
        // years

        case "y":
          // like 2014
          return useDateTimeFormatter ? string({
            year: "numeric"
          }, "year") : _this.num(dt.year);

        case "yy":
          // like 14
          return useDateTimeFormatter ? string({
            year: "2-digit"
          }, "year") : _this.num(dt.year.toString().slice(-2), 2);

        case "yyyy":
          // like 0012
          return useDateTimeFormatter ? string({
            year: "numeric"
          }, "year") : _this.num(dt.year, 4);

        case "yyyyyy":
          // like 000012
          return useDateTimeFormatter ? string({
            year: "numeric"
          }, "year") : _this.num(dt.year, 6);
        // eras

        case "G":
          // like AD
          return era("short");

        case "GG":
          // like Anno Domini
          return era("long");

        case "GGGGG":
          return era("narrow");

        case "kk":
          return _this.num(dt.weekYear.toString().slice(-2), 2);

        case "kkkk":
          return _this.num(dt.weekYear, 4);

        case "W":
          return _this.num(dt.weekNumber);

        case "WW":
          return _this.num(dt.weekNumber, 2);

        case "o":
          return _this.num(dt.ordinal);

        case "ooo":
          return _this.num(dt.ordinal, 3);

        case "q":
          // like 1
          return _this.num(dt.quarter);

        case "qq":
          // like 01
          return _this.num(dt.quarter, 2);

        case "X":
          return _this.num(Math.floor(dt.ts / 1000));

        case "x":
          return _this.num(dt.ts);

        default:
          return maybeMacro(token);
      }
    };

    return stringifyTokens(Formatter.parseFormat(fmt), tokenToString);
  };

  _proto.formatDurationFromString = function formatDurationFromString(dur, fmt) {
    var _this2 = this;

    var tokenToField = function tokenToField(token) {
      switch (token[0]) {
        case "S":
          return "millisecond";

        case "s":
          return "second";

        case "m":
          return "minute";

        case "h":
          return "hour";

        case "d":
          return "day";

        case "M":
          return "month";

        case "y":
          return "year";

        default:
          return null;
      }
    },
        tokenToString = function tokenToString(lildur) {
      return function (token) {
        var mapped = tokenToField(token);

        if (mapped) {
          return _this2.num(lildur.get(mapped), token.length);
        } else {
          return token;
        }
      };
    },
        tokens = Formatter.parseFormat(fmt),
        realTokens = tokens.reduce(function (found, _ref) {
      var literal = _ref.literal,
          val = _ref.val;
      return literal ? found : found.concat(val);
    }, []),
        collapsed = dur.shiftTo.apply(dur, realTokens.map(tokenToField).filter(function (t) {
      return t;
    }));

    return stringifyTokens(tokens, tokenToString(collapsed));
  };

  return Formatter;
}();

var Invalid = /*#__PURE__*/function () {
  function Invalid(reason, explanation) {
    this.reason = reason;
    this.explanation = explanation;
  }

  var _proto = Invalid.prototype;

  _proto.toMessage = function toMessage() {
    if (this.explanation) {
      return this.reason + ": " + this.explanation;
    } else {
      return this.reason;
    }
  };

  return Invalid;
}();

/**
 * @interface
 */

var Zone = /*#__PURE__*/function () {
  function Zone() {}

  var _proto = Zone.prototype;

  /**
   * Returns the offset's common name (such as EST) at the specified timestamp
   * @abstract
   * @param {number} ts - Epoch milliseconds for which to get the name
   * @param {Object} opts - Options to affect the format
   * @param {string} opts.format - What style of offset to return. Accepts 'long' or 'short'.
   * @param {string} opts.locale - What locale to return the offset name in.
   * @return {string}
   */
  _proto.offsetName = function offsetName(ts, opts) {
    throw new ZoneIsAbstractError();
  }
  /**
   * Returns the offset's value as a string
   * @abstract
   * @param {number} ts - Epoch milliseconds for which to get the offset
   * @param {string} format - What style of offset to return.
   *                          Accepts 'narrow', 'short', or 'techie'. Returning '+6', '+06:00', or '+0600' respectively
   * @return {string}
   */
  ;

  _proto.formatOffset = function formatOffset(ts, format) {
    throw new ZoneIsAbstractError();
  }
  /**
   * Return the offset in minutes for this zone at the specified timestamp.
   * @abstract
   * @param {number} ts - Epoch milliseconds for which to compute the offset
   * @return {number}
   */
  ;

  _proto.offset = function offset(ts) {
    throw new ZoneIsAbstractError();
  }
  /**
   * Return whether this Zone is equal to another zone
   * @abstract
   * @param {Zone} otherZone - the zone to compare
   * @return {boolean}
   */
  ;

  _proto.equals = function equals(otherZone) {
    throw new ZoneIsAbstractError();
  }
  /**
   * Return whether this Zone is valid.
   * @abstract
   * @type {boolean}
   */
  ;

  _createClass(Zone, [{
    key: "type",

    /**
     * The type of zone
     * @abstract
     * @type {string}
     */
    get: function get() {
      throw new ZoneIsAbstractError();
    }
    /**
     * The name of this zone.
     * @abstract
     * @type {string}
     */

  }, {
    key: "name",
    get: function get() {
      throw new ZoneIsAbstractError();
    }
    /**
     * Returns whether the offset is known to be fixed for the whole year.
     * @abstract
     * @type {boolean}
     */

  }, {
    key: "universal",
    get: function get() {
      throw new ZoneIsAbstractError();
    }
  }, {
    key: "isValid",
    get: function get() {
      throw new ZoneIsAbstractError();
    }
  }]);

  return Zone;
}();

var singleton = null;
/**
 * Represents the local zone for this Javascript environment.
 * @implements {Zone}
 */

var LocalZone = /*#__PURE__*/function (_Zone) {
  _inheritsLoose(LocalZone, _Zone);

  function LocalZone() {
    return _Zone.apply(this, arguments) || this;
  }

  var _proto = LocalZone.prototype;

  /** @override **/
  _proto.offsetName = function offsetName(ts, _ref) {
    var format = _ref.format,
        locale = _ref.locale;
    return parseZoneInfo(ts, format, locale);
  }
  /** @override **/
  ;

  _proto.formatOffset = function formatOffset$1(ts, format) {
    return formatOffset(this.offset(ts), format);
  }
  /** @override **/
  ;

  _proto.offset = function offset(ts) {
    return -new Date(ts).getTimezoneOffset();
  }
  /** @override **/
  ;

  _proto.equals = function equals(otherZone) {
    return otherZone.type === "local";
  }
  /** @override **/
  ;

  _createClass(LocalZone, [{
    key: "type",

    /** @override **/
    get: function get() {
      return "local";
    }
    /** @override **/

  }, {
    key: "name",
    get: function get() {
      if (hasIntl()) {
        return new Intl.DateTimeFormat().resolvedOptions().timeZone;
      } else return "local";
    }
    /** @override **/

  }, {
    key: "universal",
    get: function get() {
      return false;
    }
  }, {
    key: "isValid",
    get: function get() {
      return true;
    }
  }], [{
    key: "instance",

    /**
     * Get a singleton instance of the local zone
     * @return {LocalZone}
     */
    get: function get() {
      if (singleton === null) {
        singleton = new LocalZone();
      }

      return singleton;
    }
  }]);

  return LocalZone;
}(Zone);

var matchingRegex = RegExp("^" + ianaRegex.source + "$");
var dtfCache = {};

function makeDTF(zone) {
  if (!dtfCache[zone]) {
    dtfCache[zone] = new Intl.DateTimeFormat("en-US", {
      hour12: false,
      timeZone: zone,
      year: "numeric",
      month: "2-digit",
      day: "2-digit",
      hour: "2-digit",
      minute: "2-digit",
      second: "2-digit"
    });
  }

  return dtfCache[zone];
}

var typeToPos = {
  year: 0,
  month: 1,
  day: 2,
  hour: 3,
  minute: 4,
  second: 5
};

function hackyOffset(dtf, date) {
  var formatted = dtf.format(date).replace(/\u200E/g, ""),
      parsed = /(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(formatted),
      fMonth = parsed[1],
      fDay = parsed[2],
      fYear = parsed[3],
      fHour = parsed[4],
      fMinute = parsed[5],
      fSecond = parsed[6];
  return [fYear, fMonth, fDay, fHour, fMinute, fSecond];
}

function partsOffset(dtf, date) {
  var formatted = dtf.formatToParts(date),
      filled = [];

  for (var i = 0; i < formatted.length; i++) {
    var _formatted$i = formatted[i],
        type = _formatted$i.type,
        value = _formatted$i.value,
        pos = typeToPos[type];

    if (!isUndefined(pos)) {
      filled[pos] = parseInt(value, 10);
    }
  }

  return filled;
}

var ianaZoneCache = {};
/**
 * A zone identified by an IANA identifier, like America/New_York
 * @implements {Zone}
 */

var IANAZone = /*#__PURE__*/function (_Zone) {
  _inheritsLoose(IANAZone, _Zone);

  /**
   * @param {string} name - Zone name
   * @return {IANAZone}
   */
  IANAZone.create = function create(name) {
    if (!ianaZoneCache[name]) {
      ianaZoneCache[name] = new IANAZone(name);
    }

    return ianaZoneCache[name];
  }
  /**
   * Reset local caches. Should only be necessary in testing scenarios.
   * @return {void}
   */
  ;

  IANAZone.resetCache = function resetCache() {
    ianaZoneCache = {};
    dtfCache = {};
  }
  /**
   * Returns whether the provided string is a valid specifier. This only checks the string's format, not that the specifier identifies a known zone; see isValidZone for that.
   * @param {string} s - The string to check validity on
   * @example IANAZone.isValidSpecifier("America/New_York") //=> true
   * @example IANAZone.isValidSpecifier("Fantasia/Castle") //=> true
   * @example IANAZone.isValidSpecifier("Sport~~blorp") //=> false
   * @return {boolean}
   */
  ;

  IANAZone.isValidSpecifier = function isValidSpecifier(s) {
    return !!(s && s.match(matchingRegex));
  }
  /**
   * Returns whether the provided string identifies a real zone
   * @param {string} zone - The string to check
   * @example IANAZone.isValidZone("America/New_York") //=> true
   * @example IANAZone.isValidZone("Fantasia/Castle") //=> false
   * @example IANAZone.isValidZone("Sport~~blorp") //=> false
   * @return {boolean}
   */
  ;

  IANAZone.isValidZone = function isValidZone(zone) {
    try {
      new Intl.DateTimeFormat("en-US", {
        timeZone: zone
      }).format();
      return true;
    } catch (e) {
      return false;
    }
  } // Etc/GMT+8 -> -480

  /** @ignore */
  ;

  IANAZone.parseGMTOffset = function parseGMTOffset(specifier) {
    if (specifier) {
      var match = specifier.match(/^Etc\/GMT([+-]\d{1,2})$/i);

      if (match) {
        return -60 * parseInt(match[1]);
      }
    }

    return null;
  };

  function IANAZone(name) {
    var _this;

    _this = _Zone.call(this) || this;
    /** @private **/

    _this.zoneName = name;
    /** @private **/

    _this.valid = IANAZone.isValidZone(name);
    return _this;
  }
  /** @override **/


  var _proto = IANAZone.prototype;

  /** @override **/
  _proto.offsetName = function offsetName(ts, _ref) {
    var format = _ref.format,
        locale = _ref.locale;
    return parseZoneInfo(ts, format, locale, this.name);
  }
  /** @override **/
  ;

  _proto.formatOffset = function formatOffset$1(ts, format) {
    return formatOffset(this.offset(ts), format);
  }
  /** @override **/
  ;

  _proto.offset = function offset(ts) {
    var date = new Date(ts),
        dtf = makeDTF(this.name),
        _ref2 = dtf.formatToParts ? partsOffset(dtf, date) : hackyOffset(dtf, date),
        year = _ref2[0],
        month = _ref2[1],
        day = _ref2[2],
        hour = _ref2[3],
        minute = _ref2[4],
        second = _ref2[5],
        adjustedHour = hour === 24 ? 0 : hour;

    var asUTC = objToLocalTS({
      year: year,
      month: month,
      day: day,
      hour: adjustedHour,
      minute: minute,
      second: second,
      millisecond: 0
    });
    var asTS = +date;
    var over = asTS % 1000;
    asTS -= over >= 0 ? over : 1000 + over;
    return (asUTC - asTS) / (60 * 1000);
  }
  /** @override **/
  ;

  _proto.equals = function equals(otherZone) {
    return otherZone.type === "iana" && otherZone.name === this.name;
  }
  /** @override **/
  ;

  _createClass(IANAZone, [{
    key: "type",
    get: function get() {
      return "iana";
    }
    /** @override **/

  }, {
    key: "name",
    get: function get() {
      return this.zoneName;
    }
    /** @override **/

  }, {
    key: "universal",
    get: function get() {
      return false;
    }
  }, {
    key: "isValid",
    get: function get() {
      return this.valid;
    }
  }]);

  return IANAZone;
}(Zone);

var singleton$1 = null;
/**
 * A zone with a fixed offset (meaning no DST)
 * @implements {Zone}
 */

var FixedOffsetZone = /*#__PURE__*/function (_Zone) {
  _inheritsLoose(FixedOffsetZone, _Zone);

  /**
   * Get an instance with a specified offset
   * @param {number} offset - The offset in minutes
   * @return {FixedOffsetZone}
   */
  FixedOffsetZone.instance = function instance(offset) {
    return offset === 0 ? FixedOffsetZone.utcInstance : new FixedOffsetZone(offset);
  }
  /**
   * Get an instance of FixedOffsetZone from a UTC offset string, like "UTC+6"
   * @param {string} s - The offset string to parse
   * @example FixedOffsetZone.parseSpecifier("UTC+6")
   * @example FixedOffsetZone.parseSpecifier("UTC+06")
   * @example FixedOffsetZone.parseSpecifier("UTC-6:00")
   * @return {FixedOffsetZone}
   */
  ;

  FixedOffsetZone.parseSpecifier = function parseSpecifier(s) {
    if (s) {
      var r = s.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);

      if (r) {
        return new FixedOffsetZone(signedOffset(r[1], r[2]));
      }
    }

    return null;
  };

  _createClass(FixedOffsetZone, null, [{
    key: "utcInstance",

    /**
     * Get a singleton instance of UTC
     * @return {FixedOffsetZone}
     */
    get: function get() {
      if (singleton$1 === null) {
        singleton$1 = new FixedOffsetZone(0);
      }

      return singleton$1;
    }
  }]);

  function FixedOffsetZone(offset) {
    var _this;

    _this = _Zone.call(this) || this;
    /** @private **/

    _this.fixed = offset;
    return _this;
  }
  /** @override **/


  var _proto = FixedOffsetZone.prototype;

  /** @override **/
  _proto.offsetName = function offsetName() {
    return this.name;
  }
  /** @override **/
  ;

  _proto.formatOffset = function formatOffset$1(ts, format) {
    return formatOffset(this.fixed, format);
  }
  /** @override **/
  ;

  /** @override **/
  _proto.offset = function offset() {
    return this.fixed;
  }
  /** @override **/
  ;

  _proto.equals = function equals(otherZone) {
    return otherZone.type === "fixed" && otherZone.fixed === this.fixed;
  }
  /** @override **/
  ;

  _createClass(FixedOffsetZone, [{
    key: "type",
    get: function get() {
      return "fixed";
    }
    /** @override **/

  }, {
    key: "name",
    get: function get() {
      return this.fixed === 0 ? "UTC" : "UTC" + formatOffset(this.fixed, "narrow");
    }
  }, {
    key: "universal",
    get: function get() {
      return true;
    }
  }, {
    key: "isValid",
    get: function get() {
      return true;
    }
  }]);

  return FixedOffsetZone;
}(Zone);

/**
 * A zone that failed to parse. You should never need to instantiate this.
 * @implements {Zone}
 */

var InvalidZone = /*#__PURE__*/function (_Zone) {
  _inheritsLoose(InvalidZone, _Zone);

  function InvalidZone(zoneName) {
    var _this;

    _this = _Zone.call(this) || this;
    /**  @private */

    _this.zoneName = zoneName;
    return _this;
  }
  /** @override **/


  var _proto = InvalidZone.prototype;

  /** @override **/
  _proto.offsetName = function offsetName() {
    return null;
  }
  /** @override **/
  ;

  _proto.formatOffset = function formatOffset() {
    return "";
  }
  /** @override **/
  ;

  _proto.offset = function offset() {
    return NaN;
  }
  /** @override **/
  ;

  _proto.equals = function equals() {
    return false;
  }
  /** @override **/
  ;

  _createClass(InvalidZone, [{
    key: "type",
    get: function get() {
      return "invalid";
    }
    /** @override **/

  }, {
    key: "name",
    get: function get() {
      return this.zoneName;
    }
    /** @override **/

  }, {
    key: "universal",
    get: function get() {
      return false;
    }
  }, {
    key: "isValid",
    get: function get() {
      return false;
    }
  }]);

  return InvalidZone;
}(Zone);

/**
 * @private
 */
function normalizeZone(input, defaultZone) {
  var offset;

  if (isUndefined(input) || input === null) {
    return defaultZone;
  } else if (input instanceof Zone) {
    return input;
  } else if (isString(input)) {
    var lowered = input.toLowerCase();
    if (lowered === "local") return defaultZone;else if (lowered === "utc" || lowered === "gmt") return FixedOffsetZone.utcInstance;else if ((offset = IANAZone.parseGMTOffset(input)) != null) {
      // handle Etc/GMT-4, which V8 chokes on
      return FixedOffsetZone.instance(offset);
    } else if (IANAZone.isValidSpecifier(lowered)) return IANAZone.create(input);else return FixedOffsetZone.parseSpecifier(lowered) || new InvalidZone(input);
  } else if (isNumber(input)) {
    return FixedOffsetZone.instance(input);
  } else if (typeof input === "object" && input.offset && typeof input.offset === "number") {
    // This is dumb, but the instanceof check above doesn't seem to really work
    // so we're duck checking it
    return input;
  } else {
    return new InvalidZone(input);
  }
}

var now = function now() {
  return Date.now();
},
    defaultZone = null,
    // not setting this directly to LocalZone.instance bc loading order issues
defaultLocale = null,
    defaultNumberingSystem = null,
    defaultOutputCalendar = null,
    throwOnInvalid = false;
/**
 * Settings contains static getters and setters that control Luxon's overall behavior. Luxon is a simple library with few options, but the ones it does have live here.
 */


var Settings = /*#__PURE__*/function () {
  function Settings() {}

  /**
   * Reset Luxon's global caches. Should only be necessary in testing scenarios.
   * @return {void}
   */
  Settings.resetCaches = function resetCaches() {
    Locale.resetCache();
    IANAZone.resetCache();
  };

  _createClass(Settings, null, [{
    key: "now",

    /**
     * Get the callback for returning the current timestamp.
     * @type {function}
     */
    get: function get() {
      return now;
    }
    /**
     * Set the callback for returning the current timestamp.
     * The function should return a number, which will be interpreted as an Epoch millisecond count
     * @type {function}
     * @example Settings.now = () => Date.now() + 3000 // pretend it is 3 seconds in the future
     * @example Settings.now = () => 0 // always pretend it's Jan 1, 1970 at midnight in UTC time
     */
    ,
    set: function set(n) {
      now = n;
    }
    /**
     * Get the default time zone to create DateTimes in.
     * @type {string}
     */

  }, {
    key: "defaultZoneName",
    get: function get() {
      return Settings.defaultZone.name;
    }
    /**
     * Set the default time zone to create DateTimes in. Does not affect existing instances.
     * @type {string}
     */
    ,
    set: function set(z) {
      if (!z) {
        defaultZone = null;
      } else {
        defaultZone = normalizeZone(z);
      }
    }
    /**
     * Get the default time zone object to create DateTimes in. Does not affect existing instances.
     * @type {Zone}
     */

  }, {
    key: "defaultZone",
    get: function get() {
      return defaultZone || LocalZone.instance;
    }
    /**
     * Get the default locale to create DateTimes with. Does not affect existing instances.
     * @type {string}
     */

  }, {
    key: "defaultLocale",
    get: function get() {
      return defaultLocale;
    }
    /**
     * Set the default locale to create DateTimes with. Does not affect existing instances.
     * @type {string}
     */
    ,
    set: function set(locale) {
      defaultLocale = locale;
    }
    /**
     * Get the default numbering system to create DateTimes with. Does not affect existing instances.
     * @type {string}
     */

  }, {
    key: "defaultNumberingSystem",
    get: function get() {
      return defaultNumberingSystem;
    }
    /**
     * Set the default numbering system to create DateTimes with. Does not affect existing instances.
     * @type {string}
     */
    ,
    set: function set(numberingSystem) {
      defaultNumberingSystem = numberingSystem;
    }
    /**
     * Get the default output calendar to create DateTimes with. Does not affect existing instances.
     * @type {string}
     */

  }, {
    key: "defaultOutputCalendar",
    get: function get() {
      return defaultOutputCalendar;
    }
    /**
     * Set the default output calendar to create DateTimes with. Does not affect existing instances.
     * @type {string}
     */
    ,
    set: function set(outputCalendar) {
      defaultOutputCalendar = outputCalendar;
    }
    /**
     * Get whether Luxon will throw when it encounters invalid DateTimes, Durations, or Intervals
     * @type {boolean}
     */

  }, {
    key: "throwOnInvalid",
    get: function get() {
      return throwOnInvalid;
    }
    /**
     * Set whether Luxon will throw when it encounters invalid DateTimes, Durations, or Intervals
     * @type {boolean}
     */
    ,
    set: function set(t) {
      throwOnInvalid = t;
    }
  }]);

  return Settings;
}();

var intlDTCache = {};

function getCachedDTF(locString, opts) {
  if (opts === void 0) {
    opts = {};
  }

  var key = JSON.stringify([locString, opts]);
  var dtf = intlDTCache[key];

  if (!dtf) {
    dtf = new Intl.DateTimeFormat(locString, opts);
    intlDTCache[key] = dtf;
  }

  return dtf;
}

var intlNumCache = {};

function getCachedINF(locString, opts) {
  if (opts === void 0) {
    opts = {};
  }

  var key = JSON.stringify([locString, opts]);
  var inf = intlNumCache[key];

  if (!inf) {
    inf = new Intl.NumberFormat(locString, opts);
    intlNumCache[key] = inf;
  }

  return inf;
}

var intlRelCache = {};

function getCachedRTF(locString, opts) {
  if (opts === void 0) {
    opts = {};
  }

  var _opts = opts,
      base = _opts.base,
      cacheKeyOpts = _objectWithoutPropertiesLoose(_opts, ["base"]); // exclude `base` from the options


  var key = JSON.stringify([locString, cacheKeyOpts]);
  var inf = intlRelCache[key];

  if (!inf) {
    inf = new Intl.RelativeTimeFormat(locString, opts);
    intlRelCache[key] = inf;
  }

  return inf;
}

var sysLocaleCache = null;

function systemLocale() {
  if (sysLocaleCache) {
    return sysLocaleCache;
  } else if (hasIntl()) {
    var computedSys = new Intl.DateTimeFormat().resolvedOptions().locale; // node sometimes defaults to "und". Override that because that is dumb

    sysLocaleCache = !computedSys || computedSys === "und" ? "en-US" : computedSys;
    return sysLocaleCache;
  } else {
    sysLocaleCache = "en-US";
    return sysLocaleCache;
  }
}

function parseLocaleString(localeStr) {
  // I really want to avoid writing a BCP 47 parser
  // see, e.g. https://github.com/wooorm/bcp-47
  // Instead, we'll do this:
  // a) if the string has no -u extensions, just leave it alone
  // b) if it does, use Intl to resolve everything
  // c) if Intl fails, try again without the -u
  var uIndex = localeStr.indexOf("-u-");

  if (uIndex === -1) {
    return [localeStr];
  } else {
    var options;
    var smaller = localeStr.substring(0, uIndex);

    try {
      options = getCachedDTF(localeStr).resolvedOptions();
    } catch (e) {
      options = getCachedDTF(smaller).resolvedOptions();
    }

    var _options = options,
        numberingSystem = _options.numberingSystem,
        calendar = _options.calendar; // return the smaller one so that we can append the calendar and numbering overrides to it

    return [smaller, numberingSystem, calendar];
  }
}

function intlConfigString(localeStr, numberingSystem, outputCalendar) {
  if (hasIntl()) {
    if (outputCalendar || numberingSystem) {
      localeStr += "-u";

      if (outputCalendar) {
        localeStr += "-ca-" + outputCalendar;
      }

      if (numberingSystem) {
        localeStr += "-nu-" + numberingSystem;
      }

      return localeStr;
    } else {
      return localeStr;
    }
  } else {
    return [];
  }
}

function mapMonths(f) {
  var ms = [];

  for (var i = 1; i <= 12; i++) {
    var dt = DateTime.utc(2016, i, 1);
    ms.push(f(dt));
  }

  return ms;
}

function mapWeekdays(f) {
  var ms = [];

  for (var i = 1; i <= 7; i++) {
    var dt = DateTime.utc(2016, 11, 13 + i);
    ms.push(f(dt));
  }

  return ms;
}

function listStuff(loc, length, defaultOK, englishFn, intlFn) {
  var mode = loc.listingMode(defaultOK);

  if (mode === "error") {
    return null;
  } else if (mode === "en") {
    return englishFn(length);
  } else {
    return intlFn(length);
  }
}

function supportsFastNumbers(loc) {
  if (loc.numberingSystem && loc.numberingSystem !== "latn") {
    return false;
  } else {
    return loc.numberingSystem === "latn" || !loc.locale || loc.locale.startsWith("en") || hasIntl() && new Intl.DateTimeFormat(loc.intl).resolvedOptions().numberingSystem === "latn";
  }
}
/**
 * @private
 */


var PolyNumberFormatter = /*#__PURE__*/function () {
  function PolyNumberFormatter(intl, forceSimple, opts) {
    this.padTo = opts.padTo || 0;
    this.floor = opts.floor || false;

    if (!forceSimple && hasIntl()) {
      var intlOpts = {
        useGrouping: false
      };
      if (opts.padTo > 0) intlOpts.minimumIntegerDigits = opts.padTo;
      this.inf = getCachedINF(intl, intlOpts);
    }
  }

  var _proto = PolyNumberFormatter.prototype;

  _proto.format = function format(i) {
    if (this.inf) {
      var fixed = this.floor ? Math.floor(i) : i;
      return this.inf.format(fixed);
    } else {
      // to match the browser's numberformatter defaults
      var _fixed = this.floor ? Math.floor(i) : roundTo(i, 3);

      return padStart(_fixed, this.padTo);
    }
  };

  return PolyNumberFormatter;
}();
/**
 * @private
 */


var PolyDateFormatter = /*#__PURE__*/function () {
  function PolyDateFormatter(dt, intl, opts) {
    this.opts = opts;
    this.hasIntl = hasIntl();
    var z;

    if (dt.zone.universal && this.hasIntl) {
      // Chromium doesn't support fixed-offset zones like Etc/GMT+8 in its formatter,
      // See https://bugs.chromium.org/p/chromium/issues/detail?id=364374.
      // So we have to make do. Two cases:
      // 1. The format options tell us to show the zone. We can't do that, so the best
      // we can do is format the date in UTC.
      // 2. The format options don't tell us to show the zone. Then we can adjust them
      // the time and tell the formatter to show it to us in UTC, so that the time is right
      // and the bad zone doesn't show up.
      // We can clean all this up when Chrome fixes this.
      z = "UTC";

      if (opts.timeZoneName) {
        this.dt = dt;
      } else {
        this.dt = dt.offset === 0 ? dt : DateTime.fromMillis(dt.ts + dt.offset * 60 * 1000);
      }
    } else if (dt.zone.type === "local") {
      this.dt = dt;
    } else {
      this.dt = dt;
      z = dt.zone.name;
    }

    if (this.hasIntl) {
      var intlOpts = Object.assign({}, this.opts);

      if (z) {
        intlOpts.timeZone = z;
      }

      this.dtf = getCachedDTF(intl, intlOpts);
    }
  }

  var _proto2 = PolyDateFormatter.prototype;

  _proto2.format = function format() {
    if (this.hasIntl) {
      return this.dtf.format(this.dt.toJSDate());
    } else {
      var tokenFormat = formatString(this.opts),
          loc = Locale.create("en-US");
      return Formatter.create(loc).formatDateTimeFromString(this.dt, tokenFormat);
    }
  };

  _proto2.formatToParts = function formatToParts() {
    if (this.hasIntl && hasFormatToParts()) {
      return this.dtf.formatToParts(this.dt.toJSDate());
    } else {
      // This is kind of a cop out. We actually could do this for English. However, we couldn't do it for intl strings
      // and IMO it's too weird to have an uncanny valley like that
      return [];
    }
  };

  _proto2.resolvedOptions = function resolvedOptions() {
    if (this.hasIntl) {
      return this.dtf.resolvedOptions();
    } else {
      return {
        locale: "en-US",
        numberingSystem: "latn",
        outputCalendar: "gregory"
      };
    }
  };

  return PolyDateFormatter;
}();
/**
 * @private
 */


var PolyRelFormatter = /*#__PURE__*/function () {
  function PolyRelFormatter(intl, isEnglish, opts) {
    this.opts = Object.assign({
      style: "long"
    }, opts);

    if (!isEnglish && hasRelative()) {
      this.rtf = getCachedRTF(intl, opts);
    }
  }

  var _proto3 = PolyRelFormatter.prototype;

  _proto3.format = function format(count, unit) {
    if (this.rtf) {
      return this.rtf.format(count, unit);
    } else {
      return formatRelativeTime(unit, count, this.opts.numeric, this.opts.style !== "long");
    }
  };

  _proto3.formatToParts = function formatToParts(count, unit) {
    if (this.rtf) {
      return this.rtf.formatToParts(count, unit);
    } else {
      return [];
    }
  };

  return PolyRelFormatter;
}();
/**
 * @private
 */


var Locale = /*#__PURE__*/function () {
  Locale.fromOpts = function fromOpts(opts) {
    return Locale.create(opts.locale, opts.numberingSystem, opts.outputCalendar, opts.defaultToEN);
  };

  Locale.create = function create(locale, numberingSystem, outputCalendar, defaultToEN) {
    if (defaultToEN === void 0) {
      defaultToEN = false;
    }

    var specifiedLocale = locale || Settings.defaultLocale,
        // the system locale is useful for human readable strings but annoying for parsing/formatting known formats
    localeR = specifiedLocale || (defaultToEN ? "en-US" : systemLocale()),
        numberingSystemR = numberingSystem || Settings.defaultNumberingSystem,
        outputCalendarR = outputCalendar || Settings.defaultOutputCalendar;
    return new Locale(localeR, numberingSystemR, outputCalendarR, specifiedLocale);
  };

  Locale.resetCache = function resetCache() {
    sysLocaleCache = null;
    intlDTCache = {};
    intlNumCache = {};
    intlRelCache = {};
  };

  Locale.fromObject = function fromObject(_temp) {
    var _ref = _temp === void 0 ? {} : _temp,
        locale = _ref.locale,
        numberingSystem = _ref.numberingSystem,
        outputCalendar = _ref.outputCalendar;

    return Locale.create(locale, numberingSystem, outputCalendar);
  };

  function Locale(locale, numbering, outputCalendar, specifiedLocale) {
    var _parseLocaleString = parseLocaleString(locale),
        parsedLocale = _parseLocaleString[0],
        parsedNumberingSystem = _parseLocaleString[1],
        parsedOutputCalendar = _parseLocaleString[2];

    this.locale = parsedLocale;
    this.numberingSystem = numbering || parsedNumberingSystem || null;
    this.outputCalendar = outputCalendar || parsedOutputCalendar || null;
    this.intl = intlConfigString(this.locale, this.numberingSystem, this.outputCalendar);
    this.weekdaysCache = {
      format: {},
      standalone: {}
    };
    this.monthsCache = {
      format: {},
      standalone: {}
    };
    this.meridiemCache = null;
    this.eraCache = {};
    this.specifiedLocale = specifiedLocale;
    this.fastNumbersCached = null;
  }

  var _proto4 = Locale.prototype;

  _proto4.listingMode = function listingMode(defaultOK) {
    if (defaultOK === void 0) {
      defaultOK = true;
    }

    var intl = hasIntl(),
        hasFTP = intl && hasFormatToParts(),
        isActuallyEn = this.isEnglish(),
        hasNoWeirdness = (this.numberingSystem === null || this.numberingSystem === "latn") && (this.outputCalendar === null || this.outputCalendar === "gregory");

    if (!hasFTP && !(isActuallyEn && hasNoWeirdness) && !defaultOK) {
      return "error";
    } else if (!hasFTP || isActuallyEn && hasNoWeirdness) {
      return "en";
    } else {
      return "intl";
    }
  };

  _proto4.clone = function clone(alts) {
    if (!alts || Object.getOwnPropertyNames(alts).length === 0) {
      return this;
    } else {
      return Locale.create(alts.locale || this.specifiedLocale, alts.numberingSystem || this.numberingSystem, alts.outputCalendar || this.outputCalendar, alts.defaultToEN || false);
    }
  };

  _proto4.redefaultToEN = function redefaultToEN(alts) {
    if (alts === void 0) {
      alts = {};
    }

    return this.clone(Object.assign({}, alts, {
      defaultToEN: true
    }));
  };

  _proto4.redefaultToSystem = function redefaultToSystem(alts) {
    if (alts === void 0) {
      alts = {};
    }

    return this.clone(Object.assign({}, alts, {
      defaultToEN: false
    }));
  };

  _proto4.months = function months$1(length, format, defaultOK) {
    var _this = this;

    if (format === void 0) {
      format = false;
    }

    if (defaultOK === void 0) {
      defaultOK = true;
    }

    return listStuff(this, length, defaultOK, months, function () {
      var intl = format ? {
        month: length,
        day: "numeric"
      } : {
        month: length
      },
          formatStr = format ? "format" : "standalone";

      if (!_this.monthsCache[formatStr][length]) {
        _this.monthsCache[formatStr][length] = mapMonths(function (dt) {
          return _this.extract(dt, intl, "month");
        });
      }

      return _this.monthsCache[formatStr][length];
    });
  };

  _proto4.weekdays = function weekdays$1(length, format, defaultOK) {
    var _this2 = this;

    if (format === void 0) {
      format = false;
    }

    if (defaultOK === void 0) {
      defaultOK = true;
    }

    return listStuff(this, length, defaultOK, weekdays, function () {
      var intl = format ? {
        weekday: length,
        year: "numeric",
        month: "long",
        day: "numeric"
      } : {
        weekday: length
      },
          formatStr = format ? "format" : "standalone";

      if (!_this2.weekdaysCache[formatStr][length]) {
        _this2.weekdaysCache[formatStr][length] = mapWeekdays(function (dt) {
          return _this2.extract(dt, intl, "weekday");
        });
      }

      return _this2.weekdaysCache[formatStr][length];
    });
  };

  _proto4.meridiems = function meridiems$1(defaultOK) {
    var _this3 = this;

    if (defaultOK === void 0) {
      defaultOK = true;
    }

    return listStuff(this, undefined, defaultOK, function () {
      return meridiems;
    }, function () {
      // In theory there could be aribitrary day periods. We're gonna assume there are exactly two
      // for AM and PM. This is probably wrong, but it's makes parsing way easier.
      if (!_this3.meridiemCache) {
        var intl = {
          hour: "numeric",
          hour12: true
        };
        _this3.meridiemCache = [DateTime.utc(2016, 11, 13, 9), DateTime.utc(2016, 11, 13, 19)].map(function (dt) {
          return _this3.extract(dt, intl, "dayperiod");
        });
      }

      return _this3.meridiemCache;
    });
  };

  _proto4.eras = function eras$1(length, defaultOK) {
    var _this4 = this;

    if (defaultOK === void 0) {
      defaultOK = true;
    }

    return listStuff(this, length, defaultOK, eras, function () {
      var intl = {
        era: length
      }; // This is utter bullshit. Different calendars are going to define eras totally differently. What I need is the minimum set of dates
      // to definitely enumerate them.

      if (!_this4.eraCache[length]) {
        _this4.eraCache[length] = [DateTime.utc(-40, 1, 1), DateTime.utc(2017, 1, 1)].map(function (dt) {
          return _this4.extract(dt, intl, "era");
        });
      }

      return _this4.eraCache[length];
    });
  };

  _proto4.extract = function extract(dt, intlOpts, field) {
    var df = this.dtFormatter(dt, intlOpts),
        results = df.formatToParts(),
        matching = results.find(function (m) {
      return m.type.toLowerCase() === field;
    });
    return matching ? matching.value : null;
  };

  _proto4.numberFormatter = function numberFormatter(opts) {
    if (opts === void 0) {
      opts = {};
    }

    // this forcesimple option is never used (the only caller short-circuits on it, but it seems safer to leave)
    // (in contrast, the rest of the condition is used heavily)
    return new PolyNumberFormatter(this.intl, opts.forceSimple || this.fastNumbers, opts);
  };

  _proto4.dtFormatter = function dtFormatter(dt, intlOpts) {
    if (intlOpts === void 0) {
      intlOpts = {};
    }

    return new PolyDateFormatter(dt, this.intl, intlOpts);
  };

  _proto4.relFormatter = function relFormatter(opts) {
    if (opts === void 0) {
      opts = {};
    }

    return new PolyRelFormatter(this.intl, this.isEnglish(), opts);
  };

  _proto4.isEnglish = function isEnglish() {
    return this.locale === "en" || this.locale.toLowerCase() === "en-us" || hasIntl() && new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us");
  };

  _proto4.equals = function equals(other) {
    return this.locale === other.locale && this.numberingSystem === other.numberingSystem && this.outputCalendar === other.outputCalendar;
  };

  _createClass(Locale, [{
    key: "fastNumbers",
    get: function get() {
      if (this.fastNumbersCached == null) {
        this.fastNumbersCached = supportsFastNumbers(this);
      }

      return this.fastNumbersCached;
    }
  }]);

  return Locale;
}();

/*
 * This file handles parsing for well-specified formats. Here's how it works:
 * Two things go into parsing: a regex to match with and an extractor to take apart the groups in the match.
 * An extractor is just a function that takes a regex match array and returns a { year: ..., month: ... } object
 * parse() does the work of executing the regex and applying the extractor. It takes multiple regex/extractor pairs to try in sequence.
 * Extractors can take a "cursor" representing the offset in the match to look at. This makes it easy to combine extractors.
 * combineExtractors() does the work of combining them, keeping track of the cursor through multiple extractions.
 * Some extractions are super dumb and simpleParse and fromStrings help DRY them.
 */

function combineRegexes() {
  for (var _len = arguments.length, regexes = new Array(_len), _key = 0; _key < _len; _key++) {
    regexes[_key] = arguments[_key];
  }

  var full = regexes.reduce(function (f, r) {
    return f + r.source;
  }, "");
  return RegExp("^" + full + "$");
}

function combineExtractors() {
  for (var _len2 = arguments.length, extractors = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
    extractors[_key2] = arguments[_key2];
  }

  return function (m) {
    return extractors.reduce(function (_ref, ex) {
      var mergedVals = _ref[0],
          mergedZone = _ref[1],
          cursor = _ref[2];

      var _ex = ex(m, cursor),
          val = _ex[0],
          zone = _ex[1],
          next = _ex[2];

      return [Object.assign(mergedVals, val), mergedZone || zone, next];
    }, [{}, null, 1]).slice(0, 2);
  };
}

function parse(s) {
  if (s == null) {
    return [null, null];
  }

  for (var _len3 = arguments.length, patterns = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
    patterns[_key3 - 1] = arguments[_key3];
  }

  for (var _i = 0, _patterns = patterns; _i < _patterns.length; _i++) {
    var _patterns$_i = _patterns[_i],
        regex = _patterns$_i[0],
        extractor = _patterns$_i[1];
    var m = regex.exec(s);

    if (m) {
      return extractor(m);
    }
  }

  return [null, null];
}

function simpleParse() {
  for (var _len4 = arguments.length, keys = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
    keys[_key4] = arguments[_key4];
  }

  return function (match, cursor) {
    var ret = {};
    var i;

    for (i = 0; i < keys.length; i++) {
      ret[keys[i]] = parseInteger(match[cursor + i]);
    }

    return [ret, null, cursor + i];
  };
} // ISO and SQL parsing


var offsetRegex = /(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,
    isoTimeBaseRegex = /(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,9}))?)?)?/,
    isoTimeRegex = RegExp("" + isoTimeBaseRegex.source + offsetRegex.source + "?"),
    isoTimeExtensionRegex = RegExp("(?:T" + isoTimeRegex.source + ")?"),
    isoYmdRegex = /([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,
    isoWeekRegex = /(\d{4})-?W(\d\d)(?:-?(\d))?/,
    isoOrdinalRegex = /(\d{4})-?(\d{3})/,
    extractISOWeekData = simpleParse("weekYear", "weekNumber", "weekDay"),
    extractISOOrdinalData = simpleParse("year", "ordinal"),
    sqlYmdRegex = /(\d{4})-(\d\d)-(\d\d)/,
    // dumbed-down version of the ISO one
sqlTimeRegex = RegExp(isoTimeBaseRegex.source + " ?(?:" + offsetRegex.source + "|(" + ianaRegex.source + "))?"),
    sqlTimeExtensionRegex = RegExp("(?: " + sqlTimeRegex.source + ")?");

function int(match, pos, fallback) {
  var m = match[pos];
  return isUndefined(m) ? fallback : parseInteger(m);
}

function extractISOYmd(match, cursor) {
  var item = {
    year: int(match, cursor),
    month: int(match, cursor + 1, 1),
    day: int(match, cursor + 2, 1)
  };
  return [item, null, cursor + 3];
}

function extractISOTime(match, cursor) {
  var item = {
    hour: int(match, cursor, 0),
    minute: int(match, cursor + 1, 0),
    second: int(match, cursor + 2, 0),
    millisecond: parseMillis(match[cursor + 3])
  };
  return [item, null, cursor + 4];
}

function extractISOOffset(match, cursor) {
  var local = !match[cursor] && !match[cursor + 1],
      fullOffset = signedOffset(match[cursor + 1], match[cursor + 2]),
      zone = local ? null : FixedOffsetZone.instance(fullOffset);
  return [{}, zone, cursor + 3];
}

function extractIANAZone(match, cursor) {
  var zone = match[cursor] ? IANAZone.create(match[cursor]) : null;
  return [{}, zone, cursor + 1];
} // ISO duration parsing


var isoDuration = /^-?P(?:(?:(-?\d{1,9})Y)?(?:(-?\d{1,9})M)?(?:(-?\d{1,9})W)?(?:(-?\d{1,9})D)?(?:T(?:(-?\d{1,9})H)?(?:(-?\d{1,9})M)?(?:(-?\d{1,9})(?:[.,](-?\d{1,9}))?S)?)?)$/;

function extractISODuration(match) {
  var s = match[0],
      yearStr = match[1],
      monthStr = match[2],
      weekStr = match[3],
      dayStr = match[4],
      hourStr = match[5],
      minuteStr = match[6],
      secondStr = match[7],
      millisecondsStr = match[8];
  var hasNegativePrefix = s[0] === "-";

  var maybeNegate = function maybeNegate(num) {
    return num && hasNegativePrefix ? -num : num;
  };

  return [{
    years: maybeNegate(parseInteger(yearStr)),
    months: maybeNegate(parseInteger(monthStr)),
    weeks: maybeNegate(parseInteger(weekStr)),
    days: maybeNegate(parseInteger(dayStr)),
    hours: maybeNegate(parseInteger(hourStr)),
    minutes: maybeNegate(parseInteger(minuteStr)),
    seconds: maybeNegate(parseInteger(secondStr)),
    milliseconds: maybeNegate(parseMillis(millisecondsStr))
  }];
} // These are a little braindead. EDT *should* tell us that we're in, say, America/New_York
// and not just that we're in -240 *right now*. But since I don't think these are used that often
// I'm just going to ignore that


var obsOffsets = {
  GMT: 0,
  EDT: -4 * 60,
  EST: -5 * 60,
  CDT: -5 * 60,
  CST: -6 * 60,
  MDT: -6 * 60,
  MST: -7 * 60,
  PDT: -7 * 60,
  PST: -8 * 60
};

function fromStrings(weekdayStr, yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr) {
  var result = {
    year: yearStr.length === 2 ? untruncateYear(parseInteger(yearStr)) : parseInteger(yearStr),
    month: monthsShort.indexOf(monthStr) + 1,
    day: parseInteger(dayStr),
    hour: parseInteger(hourStr),
    minute: parseInteger(minuteStr)
  };
  if (secondStr) result.second = parseInteger(secondStr);

  if (weekdayStr) {
    result.weekday = weekdayStr.length > 3 ? weekdaysLong.indexOf(weekdayStr) + 1 : weekdaysShort.indexOf(weekdayStr) + 1;
  }

  return result;
} // RFC 2822/5322


var rfc2822 = /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;

function extractRFC2822(match) {
  var weekdayStr = match[1],
      dayStr = match[2],
      monthStr = match[3],
      yearStr = match[4],
      hourStr = match[5],
      minuteStr = match[6],
      secondStr = match[7],
      obsOffset = match[8],
      milOffset = match[9],
      offHourStr = match[10],
      offMinuteStr = match[11],
      result = fromStrings(weekdayStr, yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr);
  var offset;

  if (obsOffset) {
    offset = obsOffsets[obsOffset];
  } else if (milOffset) {
    offset = 0;
  } else {
    offset = signedOffset(offHourStr, offMinuteStr);
  }

  return [result, new FixedOffsetZone(offset)];
}

function preprocessRFC2822(s) {
  // Remove comments and folding whitespace and replace multiple-spaces with a single space
  return s.replace(/\([^)]*\)|[\n\t]/g, " ").replace(/(\s\s+)/g, " ").trim();
} // http date


var rfc1123 = /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,
    rfc850 = /^(Monday|Tuesday|Wedsday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,
    ascii = /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;

function extractRFC1123Or850(match) {
  var weekdayStr = match[1],
      dayStr = match[2],
      monthStr = match[3],
      yearStr = match[4],
      hourStr = match[5],
      minuteStr = match[6],
      secondStr = match[7],
      result = fromStrings(weekdayStr, yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr);
  return [result, FixedOffsetZone.utcInstance];
}

function extractASCII(match) {
  var weekdayStr = match[1],
      monthStr = match[2],
      dayStr = match[3],
      hourStr = match[4],
      minuteStr = match[5],
      secondStr = match[6],
      yearStr = match[7],
      result = fromStrings(weekdayStr, yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr);
  return [result, FixedOffsetZone.utcInstance];
}

var isoYmdWithTimeExtensionRegex = combineRegexes(isoYmdRegex, isoTimeExtensionRegex);
var isoWeekWithTimeExtensionRegex = combineRegexes(isoWeekRegex, isoTimeExtensionRegex);
var isoOrdinalWithTimeExtensionRegex = combineRegexes(isoOrdinalRegex, isoTimeExtensionRegex);
var isoTimeCombinedRegex = combineRegexes(isoTimeRegex);
var extractISOYmdTimeAndOffset = combineExtractors(extractISOYmd, extractISOTime, extractISOOffset);
var extractISOWeekTimeAndOffset = combineExtractors(extractISOWeekData, extractISOTime, extractISOOffset);
var extractISOOrdinalDataAndTime = combineExtractors(extractISOOrdinalData, extractISOTime);
var extractISOTimeAndOffset = combineExtractors(extractISOTime, extractISOOffset);
/**
 * @private
 */

function parseISODate(s) {
  return parse(s, [isoYmdWithTimeExtensionRegex, extractISOYmdTimeAndOffset], [isoWeekWithTimeExtensionRegex, extractISOWeekTimeAndOffset], [isoOrdinalWithTimeExtensionRegex, extractISOOrdinalDataAndTime], [isoTimeCombinedRegex, extractISOTimeAndOffset]);
}
function parseRFC2822Date(s) {
  return parse(preprocessRFC2822(s), [rfc2822, extractRFC2822]);
}
function parseHTTPDate(s) {
  return parse(s, [rfc1123, extractRFC1123Or850], [rfc850, extractRFC1123Or850], [ascii, extractASCII]);
}
function parseISODuration(s) {
  return parse(s, [isoDuration, extractISODuration]);
}
var sqlYmdWithTimeExtensionRegex = combineRegexes(sqlYmdRegex, sqlTimeExtensionRegex);
var sqlTimeCombinedRegex = combineRegexes(sqlTimeRegex);
var extractISOYmdTimeOffsetAndIANAZone = combineExtractors(extractISOYmd, extractISOTime, extractISOOffset, extractIANAZone);
var extractISOTimeOffsetAndIANAZone = combineExtractors(extractISOTime, extractISOOffset, extractIANAZone);
function parseSQL(s) {
  return parse(s, [sqlYmdWithTimeExtensionRegex, extractISOYmdTimeOffsetAndIANAZone], [sqlTimeCombinedRegex, extractISOTimeOffsetAndIANAZone]);
}

var INVALID = "Invalid Duration"; // unit conversion constants

var lowOrderMatrix = {
  weeks: {
    days: 7,
    hours: 7 * 24,
    minutes: 7 * 24 * 60,
    seconds: 7 * 24 * 60 * 60,
    milliseconds: 7 * 24 * 60 * 60 * 1000
  },
  days: {
    hours: 24,
    minutes: 24 * 60,
    seconds: 24 * 60 * 60,
    milliseconds: 24 * 60 * 60 * 1000
  },
  hours: {
    minutes: 60,
    seconds: 60 * 60,
    milliseconds: 60 * 60 * 1000
  },
  minutes: {
    seconds: 60,
    milliseconds: 60 * 1000
  },
  seconds: {
    milliseconds: 1000
  }
},
    casualMatrix = Object.assign({
  years: {
    months: 12,
    weeks: 52,
    days: 365,
    hours: 365 * 24,
    minutes: 365 * 24 * 60,
    seconds: 365 * 24 * 60 * 60,
    milliseconds: 365 * 24 * 60 * 60 * 1000
  },
  quarters: {
    months: 3,
    weeks: 13,
    days: 91,
    hours: 91 * 24,
    minutes: 91 * 24 * 60,
    milliseconds: 91 * 24 * 60 * 60 * 1000
  },
  months: {
    weeks: 4,
    days: 30,
    hours: 30 * 24,
    minutes: 30 * 24 * 60,
    seconds: 30 * 24 * 60 * 60,
    milliseconds: 30 * 24 * 60 * 60 * 1000
  }
}, lowOrderMatrix),
    daysInYearAccurate = 146097.0 / 400,
    daysInMonthAccurate = 146097.0 / 4800,
    accurateMatrix = Object.assign({
  years: {
    months: 12,
    weeks: daysInYearAccurate / 7,
    days: daysInYearAccurate,
    hours: daysInYearAccurate * 24,
    minutes: daysInYearAccurate * 24 * 60,
    seconds: daysInYearAccurate * 24 * 60 * 60,
    milliseconds: daysInYearAccurate * 24 * 60 * 60 * 1000
  },
  quarters: {
    months: 3,
    weeks: daysInYearAccurate / 28,
    days: daysInYearAccurate / 4,
    hours: daysInYearAccurate * 24 / 4,
    minutes: daysInYearAccurate * 24 * 60 / 4,
    seconds: daysInYearAccurate * 24 * 60 * 60 / 4,
    milliseconds: daysInYearAccurate * 24 * 60 * 60 * 1000 / 4
  },
  months: {
    weeks: daysInMonthAccurate / 7,
    days: daysInMonthAccurate,
    hours: daysInMonthAccurate * 24,
    minutes: daysInMonthAccurate * 24 * 60,
    seconds: daysInMonthAccurate * 24 * 60 * 60,
    milliseconds: daysInMonthAccurate * 24 * 60 * 60 * 1000
  }
}, lowOrderMatrix); // units ordered by size

var orderedUnits = ["years", "quarters", "months", "weeks", "days", "hours", "minutes", "seconds", "milliseconds"];
var reverseUnits = orderedUnits.slice(0).reverse(); // clone really means "create another instance just like this one, but with these changes"

function clone(dur, alts, clear) {
  if (clear === void 0) {
    clear = false;
  }

  // deep merge for vals
  var conf = {
    values: clear ? alts.values : Object.assign({}, dur.values, alts.values || {}),
    loc: dur.loc.clone(alts.loc),
    conversionAccuracy: alts.conversionAccuracy || dur.conversionAccuracy
  };
  return new Duration(conf);
}

function antiTrunc(n) {
  return n < 0 ? Math.floor(n) : Math.ceil(n);
} // NB: mutates parameters


function convert(matrix, fromMap, fromUnit, toMap, toUnit) {
  var conv = matrix[toUnit][fromUnit],
      raw = fromMap[fromUnit] / conv,
      sameSign = Math.sign(raw) === Math.sign(toMap[toUnit]),
      // ok, so this is wild, but see the matrix in the tests
  added = !sameSign && toMap[toUnit] !== 0 && Math.abs(raw) <= 1 ? antiTrunc(raw) : Math.trunc(raw);
  toMap[toUnit] += added;
  fromMap[fromUnit] -= added * conv;
} // NB: mutates parameters


function normalizeValues(matrix, vals) {
  reverseUnits.reduce(function (previous, current) {
    if (!isUndefined(vals[current])) {
      if (previous) {
        convert(matrix, vals, previous, vals, current);
      }

      return current;
    } else {
      return previous;
    }
  }, null);
}
/**
 * A Duration object represents a period of time, like "2 months" or "1 day, 1 hour". Conceptually, it's just a map of units to their quantities, accompanied by some additional configuration and methods for creating, parsing, interrogating, transforming, and formatting them. They can be used on their own or in conjunction with other Luxon types; for example, you can use {@link DateTime.plus} to add a Duration object to a DateTime, producing another DateTime.
 *
 * Here is a brief overview of commonly used methods and getters in Duration:
 *
 * * **Creation** To create a Duration, use {@link Duration.fromMillis}, {@link Duration.fromObject}, or {@link Duration.fromISO}.
 * * **Unit values** See the {@link Duration.years}, {@link Duration.months}, {@link Duration.weeks}, {@link Duration.days}, {@link Duration.hours}, {@link Duration.minutes}, {@link Duration.seconds}, {@link Duration.milliseconds} accessors.
 * * **Configuration** See  {@link Duration.locale} and {@link Duration.numberingSystem} accessors.
 * * **Transformation** To create new Durations out of old ones use {@link Duration.plus}, {@link Duration.minus}, {@link Duration.normalize}, {@link Duration.set}, {@link Duration.reconfigure}, {@link Duration.shiftTo}, and {@link Duration.negate}.
 * * **Output** To convert the Duration into other representations, see {@link Duration.as}, {@link Duration.toISO}, {@link Duration.toFormat}, and {@link Duration.toJSON}
 *
 * There's are more methods documented below. In addition, for more information on subtler topics like internationalization and validity, see the external documentation.
 */


var Duration = /*#__PURE__*/function () {
  /**
   * @private
   */
  function Duration(config) {
    var accurate = config.conversionAccuracy === "longterm" || false;
    /**
     * @access private
     */

    this.values = config.values;
    /**
     * @access private
     */

    this.loc = config.loc || Locale.create();
    /**
     * @access private
     */

    this.conversionAccuracy = accurate ? "longterm" : "casual";
    /**
     * @access private
     */

    this.invalid = config.invalid || null;
    /**
     * @access private
     */

    this.matrix = accurate ? accurateMatrix : casualMatrix;
    /**
     * @access private
     */

    this.isLuxonDuration = true;
  }
  /**
   * Create Duration from a number of milliseconds.
   * @param {number} count of milliseconds
   * @param {Object} opts - options for parsing
   * @param {string} [opts.locale='en-US'] - the locale to use
   * @param {string} opts.numberingSystem - the numbering system to use
   * @param {string} [opts.conversionAccuracy='casual'] - the conversion system to use
   * @return {Duration}
   */


  Duration.fromMillis = function fromMillis(count, opts) {
    return Duration.fromObject(Object.assign({
      milliseconds: count
    }, opts));
  }
  /**
   * Create a Duration from a Javascript object with keys like 'years' and 'hours.
   * If this object is empty then a zero milliseconds duration is returned.
   * @param {Object} obj - the object to create the DateTime from
   * @param {number} obj.years
   * @param {number} obj.quarters
   * @param {number} obj.months
   * @param {number} obj.weeks
   * @param {number} obj.days
   * @param {number} obj.hours
   * @param {number} obj.minutes
   * @param {number} obj.seconds
   * @param {number} obj.milliseconds
   * @param {string} [obj.locale='en-US'] - the locale to use
   * @param {string} obj.numberingSystem - the numbering system to use
   * @param {string} [obj.conversionAccuracy='casual'] - the conversion system to use
   * @return {Duration}
   */
  ;

  Duration.fromObject = function fromObject(obj) {
    if (obj == null || typeof obj !== "object") {
      throw new InvalidArgumentError("Duration.fromObject: argument expected to be an object, got " + (obj === null ? "null" : typeof obj));
    }

    return new Duration({
      values: normalizeObject(obj, Duration.normalizeUnit, ["locale", "numberingSystem", "conversionAccuracy", "zone" // a bit of debt; it's super inconvenient internally not to be able to blindly pass this
      ]),
      loc: Locale.fromObject(obj),
      conversionAccuracy: obj.conversionAccuracy
    });
  }
  /**
   * Create a Duration from an ISO 8601 duration string.
   * @param {string} text - text to parse
   * @param {Object} opts - options for parsing
   * @param {string} [opts.locale='en-US'] - the locale to use
   * @param {string} opts.numberingSystem - the numbering system to use
   * @param {string} [opts.conversionAccuracy='casual'] - the conversion system to use
   * @see https://en.wikipedia.org/wiki/ISO_8601#Durations
   * @example Duration.fromISO('P3Y6M1W4DT12H30M5S').toObject() //=> { years: 3, months: 6, weeks: 1, days: 4, hours: 12, minutes: 30, seconds: 5 }
   * @example Duration.fromISO('PT23H').toObject() //=> { hours: 23 }
   * @example Duration.fromISO('P5Y3M').toObject() //=> { years: 5, months: 3 }
   * @return {Duration}
   */
  ;

  Duration.fromISO = function fromISO(text, opts) {
    var _parseISODuration = parseISODuration(text),
        parsed = _parseISODuration[0];

    if (parsed) {
      var obj = Object.assign(parsed, opts);
      return Duration.fromObject(obj);
    } else {
      return Duration.invalid("unparsable", "the input \"" + text + "\" can't be parsed as ISO 8601");
    }
  }
  /**
   * Create an invalid Duration.
   * @param {string} reason - simple string of why this datetime is invalid. Should not contain parameters or anything else data-dependent
   * @param {string} [explanation=null] - longer explanation, may include parameters and other useful debugging information
   * @return {Duration}
   */
  ;

  Duration.invalid = function invalid(reason, explanation) {
    if (explanation === void 0) {
      explanation = null;
    }

    if (!reason) {
      throw new InvalidArgumentError("need to specify a reason the Duration is invalid");
    }

    var invalid = reason instanceof Invalid ? reason : new Invalid(reason, explanation);

    if (Settings.throwOnInvalid) {
      throw new InvalidDurationError(invalid);
    } else {
      return new Duration({
        invalid: invalid
      });
    }
  }
  /**
   * @private
   */
  ;

  Duration.normalizeUnit = function normalizeUnit(unit) {
    var normalized = {
      year: "years",
      years: "years",
      quarter: "quarters",
      quarters: "quarters",
      month: "months",
      months: "months",
      week: "weeks",
      weeks: "weeks",
      day: "days",
      days: "days",
      hour: "hours",
      hours: "hours",
      minute: "minutes",
      minutes: "minutes",
      second: "seconds",
      seconds: "seconds",
      millisecond: "milliseconds",
      milliseconds: "milliseconds"
    }[unit ? unit.toLowerCase() : unit];
    if (!normalized) throw new InvalidUnitError(unit);
    return normalized;
  }
  /**
   * Check if an object is a Duration. Works across context boundaries
   * @param {object} o
   * @return {boolean}
   */
  ;

  Duration.isDuration = function isDuration(o) {
    return o && o.isLuxonDuration || false;
  }
  /**
   * Get  the locale of a Duration, such 'en-GB'
   * @type {string}
   */
  ;

  var _proto = Duration.prototype;

  /**
   * Returns a string representation of this Duration formatted according to the specified format string. You may use these tokens:
   * * `S` for milliseconds
   * * `s` for seconds
   * * `m` for minutes
   * * `h` for hours
   * * `d` for days
   * * `M` for months
   * * `y` for years
   * Notes:
   * * Add padding by repeating the token, e.g. "yy" pads the years to two digits, "hhhh" pads the hours out to four digits
   * * The duration will be converted to the set of units in the format string using {@link Duration.shiftTo} and the Durations's conversion accuracy setting.
   * @param {string} fmt - the format string
   * @param {Object} opts - options
   * @param {boolean} [opts.floor=true] - floor numerical values
   * @example Duration.fromObject({ years: 1, days: 6, seconds: 2 }).toFormat("y d s") //=> "1 6 2"
   * @example Duration.fromObject({ years: 1, days: 6, seconds: 2 }).toFormat("yy dd sss") //=> "01 06 002"
   * @example Duration.fromObject({ years: 1, days: 6, seconds: 2 }).toFormat("M S") //=> "12 518402000"
   * @return {string}
   */
  _proto.toFormat = function toFormat(fmt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    // reverse-compat since 1.2; we always round down now, never up, and we do it by default
    var fmtOpts = Object.assign({}, opts, {
      floor: opts.round !== false && opts.floor !== false
    });
    return this.isValid ? Formatter.create(this.loc, fmtOpts).formatDurationFromString(this, fmt) : INVALID;
  }
  /**
   * Returns a Javascript object with this Duration's values.
   * @param opts - options for generating the object
   * @param {boolean} [opts.includeConfig=false] - include configuration attributes in the output
   * @example Duration.fromObject({ years: 1, days: 6, seconds: 2 }).toObject() //=> { years: 1, days: 6, seconds: 2 }
   * @return {Object}
   */
  ;

  _proto.toObject = function toObject(opts) {
    if (opts === void 0) {
      opts = {};
    }

    if (!this.isValid) return {};
    var base = Object.assign({}, this.values);

    if (opts.includeConfig) {
      base.conversionAccuracy = this.conversionAccuracy;
      base.numberingSystem = this.loc.numberingSystem;
      base.locale = this.loc.locale;
    }

    return base;
  }
  /**
   * Returns an ISO 8601-compliant string representation of this Duration.
   * @see https://en.wikipedia.org/wiki/ISO_8601#Durations
   * @example Duration.fromObject({ years: 3, seconds: 45 }).toISO() //=> 'P3YT45S'
   * @example Duration.fromObject({ months: 4, seconds: 45 }).toISO() //=> 'P4MT45S'
   * @example Duration.fromObject({ months: 5 }).toISO() //=> 'P5M'
   * @example Duration.fromObject({ minutes: 5 }).toISO() //=> 'PT5M'
   * @example Duration.fromObject({ milliseconds: 6 }).toISO() //=> 'PT0.006S'
   * @return {string}
   */
  ;

  _proto.toISO = function toISO() {
    // we could use the formatter, but this is an easier way to get the minimum string
    if (!this.isValid) return null;
    var s = "P";
    if (this.years !== 0) s += this.years + "Y";
    if (this.months !== 0 || this.quarters !== 0) s += this.months + this.quarters * 3 + "M";
    if (this.weeks !== 0) s += this.weeks + "W";
    if (this.days !== 0) s += this.days + "D";
    if (this.hours !== 0 || this.minutes !== 0 || this.seconds !== 0 || this.milliseconds !== 0) s += "T";
    if (this.hours !== 0) s += this.hours + "H";
    if (this.minutes !== 0) s += this.minutes + "M";
    if (this.seconds !== 0 || this.milliseconds !== 0) // this will handle "floating point madness" by removing extra decimal places
      // https://stackoverflow.com/questions/588004/is-floating-point-math-broken
      s += roundTo(this.seconds + this.milliseconds / 1000, 3) + "S";
    if (s === "P") s += "T0S";
    return s;
  }
  /**
   * Returns an ISO 8601 representation of this Duration appropriate for use in JSON.
   * @return {string}
   */
  ;

  _proto.toJSON = function toJSON() {
    return this.toISO();
  }
  /**
   * Returns an ISO 8601 representation of this Duration appropriate for use in debugging.
   * @return {string}
   */
  ;

  _proto.toString = function toString() {
    return this.toISO();
  }
  /**
   * Returns an milliseconds value of this Duration.
   * @return {number}
   */
  ;

  _proto.valueOf = function valueOf() {
    return this.as("milliseconds");
  }
  /**
   * Make this Duration longer by the specified amount. Return a newly-constructed Duration.
   * @param {Duration|Object|number} duration - The amount to add. Either a Luxon Duration, a number of milliseconds, the object argument to Duration.fromObject()
   * @return {Duration}
   */
  ;

  _proto.plus = function plus(duration) {
    if (!this.isValid) return this;
    var dur = friendlyDuration(duration),
        result = {};

    for (var _iterator = _createForOfIteratorHelperLoose(orderedUnits), _step; !(_step = _iterator()).done;) {
      var k = _step.value;

      if (hasOwnProperty(dur.values, k) || hasOwnProperty(this.values, k)) {
        result[k] = dur.get(k) + this.get(k);
      }
    }

    return clone(this, {
      values: result
    }, true);
  }
  /**
   * Make this Duration shorter by the specified amount. Return a newly-constructed Duration.
   * @param {Duration|Object|number} duration - The amount to subtract. Either a Luxon Duration, a number of milliseconds, the object argument to Duration.fromObject()
   * @return {Duration}
   */
  ;

  _proto.minus = function minus(duration) {
    if (!this.isValid) return this;
    var dur = friendlyDuration(duration);
    return this.plus(dur.negate());
  }
  /**
   * Scale this Duration by the specified amount. Return a newly-constructed Duration.
   * @param {function} fn - The function to apply to each unit. Arity is 1 or 2: the value of the unit and, optionally, the unit name. Must return a number.
   * @example Duration.fromObject({ hours: 1, minutes: 30 }).mapUnit(x => x * 2) //=> { hours: 2, minutes: 60 }
   * @example Duration.fromObject({ hours: 1, minutes: 30 }).mapUnit((x, u) => u === "hour" ? x * 2 : x) //=> { hours: 2, minutes: 30 }
   * @return {Duration}
   */
  ;

  _proto.mapUnits = function mapUnits(fn) {
    if (!this.isValid) return this;
    var result = {};

    for (var _i = 0, _Object$keys = Object.keys(this.values); _i < _Object$keys.length; _i++) {
      var k = _Object$keys[_i];
      result[k] = asNumber(fn(this.values[k], k));
    }

    return clone(this, {
      values: result
    }, true);
  }
  /**
   * Get the value of unit.
   * @param {string} unit - a unit such as 'minute' or 'day'
   * @example Duration.fromObject({years: 2, days: 3}).years //=> 2
   * @example Duration.fromObject({years: 2, days: 3}).months //=> 0
   * @example Duration.fromObject({years: 2, days: 3}).days //=> 3
   * @return {number}
   */
  ;

  _proto.get = function get(unit) {
    return this[Duration.normalizeUnit(unit)];
  }
  /**
   * "Set" the values of specified units. Return a newly-constructed Duration.
   * @param {Object} values - a mapping of units to numbers
   * @example dur.set({ years: 2017 })
   * @example dur.set({ hours: 8, minutes: 30 })
   * @return {Duration}
   */
  ;

  _proto.set = function set(values) {
    if (!this.isValid) return this;
    var mixed = Object.assign(this.values, normalizeObject(values, Duration.normalizeUnit, []));
    return clone(this, {
      values: mixed
    });
  }
  /**
   * "Set" the locale and/or numberingSystem.  Returns a newly-constructed Duration.
   * @example dur.reconfigure({ locale: 'en-GB' })
   * @return {Duration}
   */
  ;

  _proto.reconfigure = function reconfigure(_temp) {
    var _ref = _temp === void 0 ? {} : _temp,
        locale = _ref.locale,
        numberingSystem = _ref.numberingSystem,
        conversionAccuracy = _ref.conversionAccuracy;

    var loc = this.loc.clone({
      locale: locale,
      numberingSystem: numberingSystem
    }),
        opts = {
      loc: loc
    };

    if (conversionAccuracy) {
      opts.conversionAccuracy = conversionAccuracy;
    }

    return clone(this, opts);
  }
  /**
   * Return the length of the duration in the specified unit.
   * @param {string} unit - a unit such as 'minutes' or 'days'
   * @example Duration.fromObject({years: 1}).as('days') //=> 365
   * @example Duration.fromObject({years: 1}).as('months') //=> 12
   * @example Duration.fromObject({hours: 60}).as('days') //=> 2.5
   * @return {number}
   */
  ;

  _proto.as = function as(unit) {
    return this.isValid ? this.shiftTo(unit).get(unit) : NaN;
  }
  /**
   * Reduce this Duration to its canonical representation in its current units.
   * @example Duration.fromObject({ years: 2, days: 5000 }).normalize().toObject() //=> { years: 15, days: 255 }
   * @example Duration.fromObject({ hours: 12, minutes: -45 }).normalize().toObject() //=> { hours: 11, minutes: 15 }
   * @return {Duration}
   */
  ;

  _proto.normalize = function normalize() {
    if (!this.isValid) return this;
    var vals = this.toObject();
    normalizeValues(this.matrix, vals);
    return clone(this, {
      values: vals
    }, true);
  }
  /**
   * Convert this Duration into its representation in a different set of units.
   * @example Duration.fromObject({ hours: 1, seconds: 30 }).shiftTo('minutes', 'milliseconds').toObject() //=> { minutes: 60, milliseconds: 30000 }
   * @return {Duration}
   */
  ;

  _proto.shiftTo = function shiftTo() {
    for (var _len = arguments.length, units = new Array(_len), _key = 0; _key < _len; _key++) {
      units[_key] = arguments[_key];
    }

    if (!this.isValid) return this;

    if (units.length === 0) {
      return this;
    }

    units = units.map(function (u) {
      return Duration.normalizeUnit(u);
    });
    var built = {},
        accumulated = {},
        vals = this.toObject();
    var lastUnit;
    normalizeValues(this.matrix, vals);

    for (var _iterator2 = _createForOfIteratorHelperLoose(orderedUnits), _step2; !(_step2 = _iterator2()).done;) {
      var k = _step2.value;

      if (units.indexOf(k) >= 0) {
        lastUnit = k;
        var own = 0; // anything we haven't boiled down yet should get boiled to this unit

        for (var ak in accumulated) {
          own += this.matrix[ak][k] * accumulated[ak];
          accumulated[ak] = 0;
        } // plus anything that's already in this unit


        if (isNumber(vals[k])) {
          own += vals[k];
        }

        var i = Math.trunc(own);
        built[k] = i;
        accumulated[k] = own - i; // we'd like to absorb these fractions in another unit
        // plus anything further down the chain that should be rolled up in to this

        for (var down in vals) {
          if (orderedUnits.indexOf(down) > orderedUnits.indexOf(k)) {
            convert(this.matrix, vals, down, built, k);
          }
        } // otherwise, keep it in the wings to boil it later

      } else if (isNumber(vals[k])) {
        accumulated[k] = vals[k];
      }
    } // anything leftover becomes the decimal for the last unit
    // lastUnit must be defined since units is not empty


    for (var key in accumulated) {
      if (accumulated[key] !== 0) {
        built[lastUnit] += key === lastUnit ? accumulated[key] : accumulated[key] / this.matrix[lastUnit][key];
      }
    }

    return clone(this, {
      values: built
    }, true).normalize();
  }
  /**
   * Return the negative of this Duration.
   * @example Duration.fromObject({ hours: 1, seconds: 30 }).negate().toObject() //=> { hours: -1, seconds: -30 }
   * @return {Duration}
   */
  ;

  _proto.negate = function negate() {
    if (!this.isValid) return this;
    var negated = {};

    for (var _i2 = 0, _Object$keys2 = Object.keys(this.values); _i2 < _Object$keys2.length; _i2++) {
      var k = _Object$keys2[_i2];
      negated[k] = -this.values[k];
    }

    return clone(this, {
      values: negated
    }, true);
  }
  /**
   * Get the years.
   * @type {number}
   */
  ;

  /**
   * Equality check
   * Two Durations are equal iff they have the same units and the same values for each unit.
   * @param {Duration} other
   * @return {boolean}
   */
  _proto.equals = function equals(other) {
    if (!this.isValid || !other.isValid) {
      return false;
    }

    if (!this.loc.equals(other.loc)) {
      return false;
    }

    for (var _iterator3 = _createForOfIteratorHelperLoose(orderedUnits), _step3; !(_step3 = _iterator3()).done;) {
      var u = _step3.value;

      if (this.values[u] !== other.values[u]) {
        return false;
      }
    }

    return true;
  };

  _createClass(Duration, [{
    key: "locale",
    get: function get() {
      return this.isValid ? this.loc.locale : null;
    }
    /**
     * Get the numbering system of a Duration, such 'beng'. The numbering system is used when formatting the Duration
     *
     * @type {string}
     */

  }, {
    key: "numberingSystem",
    get: function get() {
      return this.isValid ? this.loc.numberingSystem : null;
    }
  }, {
    key: "years",
    get: function get() {
      return this.isValid ? this.values.years || 0 : NaN;
    }
    /**
     * Get the quarters.
     * @type {number}
     */

  }, {
    key: "quarters",
    get: function get() {
      return this.isValid ? this.values.quarters || 0 : NaN;
    }
    /**
     * Get the months.
     * @type {number}
     */

  }, {
    key: "months",
    get: function get() {
      return this.isValid ? this.values.months || 0 : NaN;
    }
    /**
     * Get the weeks
     * @type {number}
     */

  }, {
    key: "weeks",
    get: function get() {
      return this.isValid ? this.values.weeks || 0 : NaN;
    }
    /**
     * Get the days.
     * @type {number}
     */

  }, {
    key: "days",
    get: function get() {
      return this.isValid ? this.values.days || 0 : NaN;
    }
    /**
     * Get the hours.
     * @type {number}
     */

  }, {
    key: "hours",
    get: function get() {
      return this.isValid ? this.values.hours || 0 : NaN;
    }
    /**
     * Get the minutes.
     * @type {number}
     */

  }, {
    key: "minutes",
    get: function get() {
      return this.isValid ? this.values.minutes || 0 : NaN;
    }
    /**
     * Get the seconds.
     * @return {number}
     */

  }, {
    key: "seconds",
    get: function get() {
      return this.isValid ? this.values.seconds || 0 : NaN;
    }
    /**
     * Get the milliseconds.
     * @return {number}
     */

  }, {
    key: "milliseconds",
    get: function get() {
      return this.isValid ? this.values.milliseconds || 0 : NaN;
    }
    /**
     * Returns whether the Duration is invalid. Invalid durations are returned by diff operations
     * on invalid DateTimes or Intervals.
     * @return {boolean}
     */

  }, {
    key: "isValid",
    get: function get() {
      return this.invalid === null;
    }
    /**
     * Returns an error code if this Duration became invalid, or null if the Duration is valid
     * @return {string}
     */

  }, {
    key: "invalidReason",
    get: function get() {
      return this.invalid ? this.invalid.reason : null;
    }
    /**
     * Returns an explanation of why this Duration became invalid, or null if the Duration is valid
     * @type {string}
     */

  }, {
    key: "invalidExplanation",
    get: function get() {
      return this.invalid ? this.invalid.explanation : null;
    }
  }]);

  return Duration;
}();
function friendlyDuration(durationish) {
  if (isNumber(durationish)) {
    return Duration.fromMillis(durationish);
  } else if (Duration.isDuration(durationish)) {
    return durationish;
  } else if (typeof durationish === "object") {
    return Duration.fromObject(durationish);
  } else {
    throw new InvalidArgumentError("Unknown duration argument " + durationish + " of type " + typeof durationish);
  }
}

var INVALID$1 = "Invalid Interval"; // checks if the start is equal to or before the end

function validateStartEnd(start, end) {
  if (!start || !start.isValid) {
    return Interval.invalid("missing or invalid start");
  } else if (!end || !end.isValid) {
    return Interval.invalid("missing or invalid end");
  } else if (end < start) {
    return Interval.invalid("end before start", "The end of an interval must be after its start, but you had start=" + start.toISO() + " and end=" + end.toISO());
  } else {
    return null;
  }
}
/**
 * An Interval object represents a half-open interval of time, where each endpoint is a {@link DateTime}. Conceptually, it's a container for those two endpoints, accompanied by methods for creating, parsing, interrogating, comparing, transforming, and formatting them.
 *
 * Here is a brief overview of the most commonly used methods and getters in Interval:
 *
 * * **Creation** To create an Interval, use {@link fromDateTimes}, {@link after}, {@link before}, or {@link fromISO}.
 * * **Accessors** Use {@link start} and {@link end} to get the start and end.
 * * **Interrogation** To analyze the Interval, use {@link count}, {@link length}, {@link hasSame}, {@link contains}, {@link isAfter}, or {@link isBefore}.
 * * **Transformation** To create other Intervals out of this one, use {@link set}, {@link splitAt}, {@link splitBy}, {@link divideEqually}, {@link merge}, {@link xor}, {@link union}, {@link intersection}, or {@link difference}.
 * * **Comparison** To compare this Interval to another one, use {@link equals}, {@link overlaps}, {@link abutsStart}, {@link abutsEnd}, {@link engulfs}
 * * **Output** To convert the Interval into other representations, see {@link toString}, {@link toISO}, {@link toISODate}, {@link toISOTime}, {@link toFormat}, and {@link toDuration}.
 */


var Interval = /*#__PURE__*/function () {
  /**
   * @private
   */
  function Interval(config) {
    /**
     * @access private
     */
    this.s = config.start;
    /**
     * @access private
     */

    this.e = config.end;
    /**
     * @access private
     */

    this.invalid = config.invalid || null;
    /**
     * @access private
     */

    this.isLuxonInterval = true;
  }
  /**
   * Create an invalid Interval.
   * @param {string} reason - simple string of why this Interval is invalid. Should not contain parameters or anything else data-dependent
   * @param {string} [explanation=null] - longer explanation, may include parameters and other useful debugging information
   * @return {Interval}
   */


  Interval.invalid = function invalid(reason, explanation) {
    if (explanation === void 0) {
      explanation = null;
    }

    if (!reason) {
      throw new InvalidArgumentError("need to specify a reason the Interval is invalid");
    }

    var invalid = reason instanceof Invalid ? reason : new Invalid(reason, explanation);

    if (Settings.throwOnInvalid) {
      throw new InvalidIntervalError(invalid);
    } else {
      return new Interval({
        invalid: invalid
      });
    }
  }
  /**
   * Create an Interval from a start DateTime and an end DateTime. Inclusive of the start but not the end.
   * @param {DateTime|Date|Object} start
   * @param {DateTime|Date|Object} end
   * @return {Interval}
   */
  ;

  Interval.fromDateTimes = function fromDateTimes(start, end) {
    var builtStart = friendlyDateTime(start),
        builtEnd = friendlyDateTime(end);
    var validateError = validateStartEnd(builtStart, builtEnd);

    if (validateError == null) {
      return new Interval({
        start: builtStart,
        end: builtEnd
      });
    } else {
      return validateError;
    }
  }
  /**
   * Create an Interval from a start DateTime and a Duration to extend to.
   * @param {DateTime|Date|Object} start
   * @param {Duration|Object|number} duration - the length of the Interval.
   * @return {Interval}
   */
  ;

  Interval.after = function after(start, duration) {
    var dur = friendlyDuration(duration),
        dt = friendlyDateTime(start);
    return Interval.fromDateTimes(dt, dt.plus(dur));
  }
  /**
   * Create an Interval from an end DateTime and a Duration to extend backwards to.
   * @param {DateTime|Date|Object} end
   * @param {Duration|Object|number} duration - the length of the Interval.
   * @return {Interval}
   */
  ;

  Interval.before = function before(end, duration) {
    var dur = friendlyDuration(duration),
        dt = friendlyDateTime(end);
    return Interval.fromDateTimes(dt.minus(dur), dt);
  }
  /**
   * Create an Interval from an ISO 8601 string.
   * Accepts `<start>/<end>`, `<start>/<duration>`, and `<duration>/<end>` formats.
   * @param {string} text - the ISO string to parse
   * @param {Object} [opts] - options to pass {@link DateTime.fromISO} and optionally {@link Duration.fromISO}
   * @see https://en.wikipedia.org/wiki/ISO_8601#Time_intervals
   * @return {Interval}
   */
  ;

  Interval.fromISO = function fromISO(text, opts) {
    var _split = (text || "").split("/", 2),
        s = _split[0],
        e = _split[1];

    if (s && e) {
      var start = DateTime.fromISO(s, opts),
          end = DateTime.fromISO(e, opts);

      if (start.isValid && end.isValid) {
        return Interval.fromDateTimes(start, end);
      }

      if (start.isValid) {
        var dur = Duration.fromISO(e, opts);

        if (dur.isValid) {
          return Interval.after(start, dur);
        }
      } else if (end.isValid) {
        var _dur = Duration.fromISO(s, opts);

        if (_dur.isValid) {
          return Interval.before(end, _dur);
        }
      }
    }

    return Interval.invalid("unparsable", "the input \"" + text + "\" can't be parsed as ISO 8601");
  }
  /**
   * Check if an object is an Interval. Works across context boundaries
   * @param {object} o
   * @return {boolean}
   */
  ;

  Interval.isInterval = function isInterval(o) {
    return o && o.isLuxonInterval || false;
  }
  /**
   * Returns the start of the Interval
   * @type {DateTime}
   */
  ;

  var _proto = Interval.prototype;

  /**
   * Returns the length of the Interval in the specified unit.
   * @param {string} unit - the unit (such as 'hours' or 'days') to return the length in.
   * @return {number}
   */
  _proto.length = function length(unit) {
    if (unit === void 0) {
      unit = "milliseconds";
    }

    return this.isValid ? this.toDuration.apply(this, [unit]).get(unit) : NaN;
  }
  /**
   * Returns the count of minutes, hours, days, months, or years included in the Interval, even in part.
   * Unlike {@link length} this counts sections of the calendar, not periods of time, e.g. specifying 'day'
   * asks 'what dates are included in this interval?', not 'how many days long is this interval?'
   * @param {string} [unit='milliseconds'] - the unit of time to count.
   * @return {number}
   */
  ;

  _proto.count = function count(unit) {
    if (unit === void 0) {
      unit = "milliseconds";
    }

    if (!this.isValid) return NaN;
    var start = this.start.startOf(unit),
        end = this.end.startOf(unit);
    return Math.floor(end.diff(start, unit).get(unit)) + 1;
  }
  /**
   * Returns whether this Interval's start and end are both in the same unit of time
   * @param {string} unit - the unit of time to check sameness on
   * @return {boolean}
   */
  ;

  _proto.hasSame = function hasSame(unit) {
    return this.isValid ? this.e.minus(1).hasSame(this.s, unit) : false;
  }
  /**
   * Return whether this Interval has the same start and end DateTimes.
   * @return {boolean}
   */
  ;

  _proto.isEmpty = function isEmpty() {
    return this.s.valueOf() === this.e.valueOf();
  }
  /**
   * Return whether this Interval's start is after the specified DateTime.
   * @param {DateTime} dateTime
   * @return {boolean}
   */
  ;

  _proto.isAfter = function isAfter(dateTime) {
    if (!this.isValid) return false;
    return this.s > dateTime;
  }
  /**
   * Return whether this Interval's end is before the specified DateTime.
   * @param {DateTime} dateTime
   * @return {boolean}
   */
  ;

  _proto.isBefore = function isBefore(dateTime) {
    if (!this.isValid) return false;
    return this.e <= dateTime;
  }
  /**
   * Return whether this Interval contains the specified DateTime.
   * @param {DateTime} dateTime
   * @return {boolean}
   */
  ;

  _proto.contains = function contains(dateTime) {
    if (!this.isValid) return false;
    return this.s <= dateTime && this.e > dateTime;
  }
  /**
   * "Sets" the start and/or end dates. Returns a newly-constructed Interval.
   * @param {Object} values - the values to set
   * @param {DateTime} values.start - the starting DateTime
   * @param {DateTime} values.end - the ending DateTime
   * @return {Interval}
   */
  ;

  _proto.set = function set(_temp) {
    var _ref = _temp === void 0 ? {} : _temp,
        start = _ref.start,
        end = _ref.end;

    if (!this.isValid) return this;
    return Interval.fromDateTimes(start || this.s, end || this.e);
  }
  /**
   * Split this Interval at each of the specified DateTimes
   * @param {...[DateTime]} dateTimes - the unit of time to count.
   * @return {[Interval]}
   */
  ;

  _proto.splitAt = function splitAt() {
    var _this = this;

    if (!this.isValid) return [];

    for (var _len = arguments.length, dateTimes = new Array(_len), _key = 0; _key < _len; _key++) {
      dateTimes[_key] = arguments[_key];
    }

    var sorted = dateTimes.map(friendlyDateTime).filter(function (d) {
      return _this.contains(d);
    }).sort(),
        results = [];
    var s = this.s,
        i = 0;

    while (s < this.e) {
      var added = sorted[i] || this.e,
          next = +added > +this.e ? this.e : added;
      results.push(Interval.fromDateTimes(s, next));
      s = next;
      i += 1;
    }

    return results;
  }
  /**
   * Split this Interval into smaller Intervals, each of the specified length.
   * Left over time is grouped into a smaller interval
   * @param {Duration|Object|number} duration - The length of each resulting interval.
   * @return {[Interval]}
   */
  ;

  _proto.splitBy = function splitBy(duration) {
    var dur = friendlyDuration(duration);

    if (!this.isValid || !dur.isValid || dur.as("milliseconds") === 0) {
      return [];
    }

    var s = this.s,
        added,
        next;
    var results = [];

    while (s < this.e) {
      added = s.plus(dur);
      next = +added > +this.e ? this.e : added;
      results.push(Interval.fromDateTimes(s, next));
      s = next;
    }

    return results;
  }
  /**
   * Split this Interval into the specified number of smaller intervals.
   * @param {number} numberOfParts - The number of Intervals to divide the Interval into.
   * @return {[Interval]}
   */
  ;

  _proto.divideEqually = function divideEqually(numberOfParts) {
    if (!this.isValid) return [];
    return this.splitBy(this.length() / numberOfParts).slice(0, numberOfParts);
  }
  /**
   * Return whether this Interval overlaps with the specified Interval
   * @param {Interval} other
   * @return {boolean}
   */
  ;

  _proto.overlaps = function overlaps(other) {
    return this.e > other.s && this.s < other.e;
  }
  /**
   * Return whether this Interval's end is adjacent to the specified Interval's start.
   * @param {Interval} other
   * @return {boolean}
   */
  ;

  _proto.abutsStart = function abutsStart(other) {
    if (!this.isValid) return false;
    return +this.e === +other.s;
  }
  /**
   * Return whether this Interval's start is adjacent to the specified Interval's end.
   * @param {Interval} other
   * @return {boolean}
   */
  ;

  _proto.abutsEnd = function abutsEnd(other) {
    if (!this.isValid) return false;
    return +other.e === +this.s;
  }
  /**
   * Return whether this Interval engulfs the start and end of the specified Interval.
   * @param {Interval} other
   * @return {boolean}
   */
  ;

  _proto.engulfs = function engulfs(other) {
    if (!this.isValid) return false;
    return this.s <= other.s && this.e >= other.e;
  }
  /**
   * Return whether this Interval has the same start and end as the specified Interval.
   * @param {Interval} other
   * @return {boolean}
   */
  ;

  _proto.equals = function equals(other) {
    if (!this.isValid || !other.isValid) {
      return false;
    }

    return this.s.equals(other.s) && this.e.equals(other.e);
  }
  /**
   * Return an Interval representing the intersection of this Interval and the specified Interval.
   * Specifically, the resulting Interval has the maximum start time and the minimum end time of the two Intervals.
   * Returns null if the intersection is empty, meaning, the intervals don't intersect.
   * @param {Interval} other
   * @return {Interval}
   */
  ;

  _proto.intersection = function intersection(other) {
    if (!this.isValid) return this;
    var s = this.s > other.s ? this.s : other.s,
        e = this.e < other.e ? this.e : other.e;

    if (s > e) {
      return null;
    } else {
      return Interval.fromDateTimes(s, e);
    }
  }
  /**
   * Return an Interval representing the union of this Interval and the specified Interval.
   * Specifically, the resulting Interval has the minimum start time and the maximum end time of the two Intervals.
   * @param {Interval} other
   * @return {Interval}
   */
  ;

  _proto.union = function union(other) {
    if (!this.isValid) return this;
    var s = this.s < other.s ? this.s : other.s,
        e = this.e > other.e ? this.e : other.e;
    return Interval.fromDateTimes(s, e);
  }
  /**
   * Merge an array of Intervals into a equivalent minimal set of Intervals.
   * Combines overlapping and adjacent Intervals.
   * @param {[Interval]} intervals
   * @return {[Interval]}
   */
  ;

  Interval.merge = function merge(intervals) {
    var _intervals$sort$reduc = intervals.sort(function (a, b) {
      return a.s - b.s;
    }).reduce(function (_ref2, item) {
      var sofar = _ref2[0],
          current = _ref2[1];

      if (!current) {
        return [sofar, item];
      } else if (current.overlaps(item) || current.abutsStart(item)) {
        return [sofar, current.union(item)];
      } else {
        return [sofar.concat([current]), item];
      }
    }, [[], null]),
        found = _intervals$sort$reduc[0],
        final = _intervals$sort$reduc[1];

    if (final) {
      found.push(final);
    }

    return found;
  }
  /**
   * Return an array of Intervals representing the spans of time that only appear in one of the specified Intervals.
   * @param {[Interval]} intervals
   * @return {[Interval]}
   */
  ;

  Interval.xor = function xor(intervals) {
    var _Array$prototype;

    var start = null,
        currentCount = 0;

    var results = [],
        ends = intervals.map(function (i) {
      return [{
        time: i.s,
        type: "s"
      }, {
        time: i.e,
        type: "e"
      }];
    }),
        flattened = (_Array$prototype = Array.prototype).concat.apply(_Array$prototype, ends),
        arr = flattened.sort(function (a, b) {
      return a.time - b.time;
    });

    for (var _iterator = _createForOfIteratorHelperLoose(arr), _step; !(_step = _iterator()).done;) {
      var i = _step.value;
      currentCount += i.type === "s" ? 1 : -1;

      if (currentCount === 1) {
        start = i.time;
      } else {
        if (start && +start !== +i.time) {
          results.push(Interval.fromDateTimes(start, i.time));
        }

        start = null;
      }
    }

    return Interval.merge(results);
  }
  /**
   * Return an Interval representing the span of time in this Interval that doesn't overlap with any of the specified Intervals.
   * @param {...Interval} intervals
   * @return {[Interval]}
   */
  ;

  _proto.difference = function difference() {
    var _this2 = this;

    for (var _len2 = arguments.length, intervals = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
      intervals[_key2] = arguments[_key2];
    }

    return Interval.xor([this].concat(intervals)).map(function (i) {
      return _this2.intersection(i);
    }).filter(function (i) {
      return i && !i.isEmpty();
    });
  }
  /**
   * Returns a string representation of this Interval appropriate for debugging.
   * @return {string}
   */
  ;

  _proto.toString = function toString() {
    if (!this.isValid) return INVALID$1;
    return "[" + this.s.toISO() + " \u2013 " + this.e.toISO() + ")";
  }
  /**
   * Returns an ISO 8601-compliant string representation of this Interval.
   * @see https://en.wikipedia.org/wiki/ISO_8601#Time_intervals
   * @param {Object} opts - The same options as {@link DateTime.toISO}
   * @return {string}
   */
  ;

  _proto.toISO = function toISO(opts) {
    if (!this.isValid) return INVALID$1;
    return this.s.toISO(opts) + "/" + this.e.toISO(opts);
  }
  /**
   * Returns an ISO 8601-compliant string representation of date of this Interval.
   * The time components are ignored.
   * @see https://en.wikipedia.org/wiki/ISO_8601#Time_intervals
   * @return {string}
   */
  ;

  _proto.toISODate = function toISODate() {
    if (!this.isValid) return INVALID$1;
    return this.s.toISODate() + "/" + this.e.toISODate();
  }
  /**
   * Returns an ISO 8601-compliant string representation of time of this Interval.
   * The date components are ignored.
   * @see https://en.wikipedia.org/wiki/ISO_8601#Time_intervals
   * @param {Object} opts - The same options as {@link DateTime.toISO}
   * @return {string}
   */
  ;

  _proto.toISOTime = function toISOTime(opts) {
    if (!this.isValid) return INVALID$1;
    return this.s.toISOTime(opts) + "/" + this.e.toISOTime(opts);
  }
  /**
   * Returns a string representation of this Interval formatted according to the specified format string.
   * @param {string} dateFormat - the format string. This string formats the start and end time. See {@link DateTime.toFormat} for details.
   * @param {Object} opts - options
   * @param {string} [opts.separator =  ' – '] - a separator to place between the start and end representations
   * @return {string}
   */
  ;

  _proto.toFormat = function toFormat(dateFormat, _temp2) {
    var _ref3 = _temp2 === void 0 ? {} : _temp2,
        _ref3$separator = _ref3.separator,
        separator = _ref3$separator === void 0 ? " – " : _ref3$separator;

    if (!this.isValid) return INVALID$1;
    return "" + this.s.toFormat(dateFormat) + separator + this.e.toFormat(dateFormat);
  }
  /**
   * Return a Duration representing the time spanned by this interval.
   * @param {string|string[]} [unit=['milliseconds']] - the unit or units (such as 'hours' or 'days') to include in the duration.
   * @param {Object} opts - options that affect the creation of the Duration
   * @param {string} [opts.conversionAccuracy='casual'] - the conversion system to use
   * @example Interval.fromDateTimes(dt1, dt2).toDuration().toObject() //=> { milliseconds: 88489257 }
   * @example Interval.fromDateTimes(dt1, dt2).toDuration('days').toObject() //=> { days: 1.0241812152777778 }
   * @example Interval.fromDateTimes(dt1, dt2).toDuration(['hours', 'minutes']).toObject() //=> { hours: 24, minutes: 34.82095 }
   * @example Interval.fromDateTimes(dt1, dt2).toDuration(['hours', 'minutes', 'seconds']).toObject() //=> { hours: 24, minutes: 34, seconds: 49.257 }
   * @example Interval.fromDateTimes(dt1, dt2).toDuration('seconds').toObject() //=> { seconds: 88489.257 }
   * @return {Duration}
   */
  ;

  _proto.toDuration = function toDuration(unit, opts) {
    if (!this.isValid) {
      return Duration.invalid(this.invalidReason);
    }

    return this.e.diff(this.s, unit, opts);
  }
  /**
   * Run mapFn on the interval start and end, returning a new Interval from the resulting DateTimes
   * @param {function} mapFn
   * @return {Interval}
   * @example Interval.fromDateTimes(dt1, dt2).mapEndpoints(endpoint => endpoint.toUTC())
   * @example Interval.fromDateTimes(dt1, dt2).mapEndpoints(endpoint => endpoint.plus({ hours: 2 }))
   */
  ;

  _proto.mapEndpoints = function mapEndpoints(mapFn) {
    return Interval.fromDateTimes(mapFn(this.s), mapFn(this.e));
  };

  _createClass(Interval, [{
    key: "start",
    get: function get() {
      return this.isValid ? this.s : null;
    }
    /**
     * Returns the end of the Interval
     * @type {DateTime}
     */

  }, {
    key: "end",
    get: function get() {
      return this.isValid ? this.e : null;
    }
    /**
     * Returns whether this Interval's end is at least its start, meaning that the Interval isn't 'backwards'.
     * @type {boolean}
     */

  }, {
    key: "isValid",
    get: function get() {
      return this.invalidReason === null;
    }
    /**
     * Returns an error code if this Interval is invalid, or null if the Interval is valid
     * @type {string}
     */

  }, {
    key: "invalidReason",
    get: function get() {
      return this.invalid ? this.invalid.reason : null;
    }
    /**
     * Returns an explanation of why this Interval became invalid, or null if the Interval is valid
     * @type {string}
     */

  }, {
    key: "invalidExplanation",
    get: function get() {
      return this.invalid ? this.invalid.explanation : null;
    }
  }]);

  return Interval;
}();

/**
 * The Info class contains static methods for retrieving general time and date related data. For example, it has methods for finding out if a time zone has a DST, for listing the months in any supported locale, and for discovering which of Luxon features are available in the current environment.
 */

var Info = /*#__PURE__*/function () {
  function Info() {}

  /**
   * Return whether the specified zone contains a DST.
   * @param {string|Zone} [zone='local'] - Zone to check. Defaults to the environment's local zone.
   * @return {boolean}
   */
  Info.hasDST = function hasDST(zone) {
    if (zone === void 0) {
      zone = Settings.defaultZone;
    }

    var proto = DateTime.local().setZone(zone).set({
      month: 12
    });
    return !zone.universal && proto.offset !== proto.set({
      month: 6
    }).offset;
  }
  /**
   * Return whether the specified zone is a valid IANA specifier.
   * @param {string} zone - Zone to check
   * @return {boolean}
   */
  ;

  Info.isValidIANAZone = function isValidIANAZone(zone) {
    return IANAZone.isValidSpecifier(zone) && IANAZone.isValidZone(zone);
  }
  /**
   * Converts the input into a {@link Zone} instance.
   *
   * * If `input` is already a Zone instance, it is returned unchanged.
   * * If `input` is a string containing a valid time zone name, a Zone instance
   *   with that name is returned.
   * * If `input` is a string that doesn't refer to a known time zone, a Zone
   *   instance with {@link Zone.isValid} == false is returned.
   * * If `input is a number, a Zone instance with the specified fixed offset
   *   in minutes is returned.
   * * If `input` is `null` or `undefined`, the default zone is returned.
   * @param {string|Zone|number} [input] - the value to be converted
   * @return {Zone}
   */
  ;

  Info.normalizeZone = function normalizeZone$1(input) {
    return normalizeZone(input, Settings.defaultZone);
  }
  /**
   * Return an array of standalone month names.
   * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat
   * @param {string} [length='long'] - the length of the month representation, such as "numeric", "2-digit", "narrow", "short", "long"
   * @param {Object} opts - options
   * @param {string} [opts.locale] - the locale code
   * @param {string} [opts.numberingSystem=null] - the numbering system
   * @param {string} [opts.outputCalendar='gregory'] - the calendar
   * @example Info.months()[0] //=> 'January'
   * @example Info.months('short')[0] //=> 'Jan'
   * @example Info.months('numeric')[0] //=> '1'
   * @example Info.months('short', { locale: 'fr-CA' } )[0] //=> 'janv.'
   * @example Info.months('numeric', { locale: 'ar' })[0] //=> '١'
   * @example Info.months('long', { outputCalendar: 'islamic' })[0] //=> 'Rabiʻ I'
   * @return {[string]}
   */
  ;

  Info.months = function months(length, _temp) {
    if (length === void 0) {
      length = "long";
    }

    var _ref = _temp === void 0 ? {} : _temp,
        _ref$locale = _ref.locale,
        locale = _ref$locale === void 0 ? null : _ref$locale,
        _ref$numberingSystem = _ref.numberingSystem,
        numberingSystem = _ref$numberingSystem === void 0 ? null : _ref$numberingSystem,
        _ref$outputCalendar = _ref.outputCalendar,
        outputCalendar = _ref$outputCalendar === void 0 ? "gregory" : _ref$outputCalendar;

    return Locale.create(locale, numberingSystem, outputCalendar).months(length);
  }
  /**
   * Return an array of format month names.
   * Format months differ from standalone months in that they're meant to appear next to the day of the month. In some languages, that
   * changes the string.
   * See {@link months}
   * @param {string} [length='long'] - the length of the month representation, such as "numeric", "2-digit", "narrow", "short", "long"
   * @param {Object} opts - options
   * @param {string} [opts.locale] - the locale code
   * @param {string} [opts.numberingSystem=null] - the numbering system
   * @param {string} [opts.outputCalendar='gregory'] - the calendar
   * @return {[string]}
   */
  ;

  Info.monthsFormat = function monthsFormat(length, _temp2) {
    if (length === void 0) {
      length = "long";
    }

    var _ref2 = _temp2 === void 0 ? {} : _temp2,
        _ref2$locale = _ref2.locale,
        locale = _ref2$locale === void 0 ? null : _ref2$locale,
        _ref2$numberingSystem = _ref2.numberingSystem,
        numberingSystem = _ref2$numberingSystem === void 0 ? null : _ref2$numberingSystem,
        _ref2$outputCalendar = _ref2.outputCalendar,
        outputCalendar = _ref2$outputCalendar === void 0 ? "gregory" : _ref2$outputCalendar;

    return Locale.create(locale, numberingSystem, outputCalendar).months(length, true);
  }
  /**
   * Return an array of standalone week names.
   * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat
   * @param {string} [length='long'] - the length of the month representation, such as "narrow", "short", "long".
   * @param {Object} opts - options
   * @param {string} [opts.locale] - the locale code
   * @param {string} [opts.numberingSystem=null] - the numbering system
   * @example Info.weekdays()[0] //=> 'Monday'
   * @example Info.weekdays('short')[0] //=> 'Mon'
   * @example Info.weekdays('short', { locale: 'fr-CA' })[0] //=> 'lun.'
   * @example Info.weekdays('short', { locale: 'ar' })[0] //=> 'الاثنين'
   * @return {[string]}
   */
  ;

  Info.weekdays = function weekdays(length, _temp3) {
    if (length === void 0) {
      length = "long";
    }

    var _ref3 = _temp3 === void 0 ? {} : _temp3,
        _ref3$locale = _ref3.locale,
        locale = _ref3$locale === void 0 ? null : _ref3$locale,
        _ref3$numberingSystem = _ref3.numberingSystem,
        numberingSystem = _ref3$numberingSystem === void 0 ? null : _ref3$numberingSystem;

    return Locale.create(locale, numberingSystem, null).weekdays(length);
  }
  /**
   * Return an array of format week names.
   * Format weekdays differ from standalone weekdays in that they're meant to appear next to more date information. In some languages, that
   * changes the string.
   * See {@link weekdays}
   * @param {string} [length='long'] - the length of the month representation, such as "narrow", "short", "long".
   * @param {Object} opts - options
   * @param {string} [opts.locale=null] - the locale code
   * @param {string} [opts.numberingSystem=null] - the numbering system
   * @return {[string]}
   */
  ;

  Info.weekdaysFormat = function weekdaysFormat(length, _temp4) {
    if (length === void 0) {
      length = "long";
    }

    var _ref4 = _temp4 === void 0 ? {} : _temp4,
        _ref4$locale = _ref4.locale,
        locale = _ref4$locale === void 0 ? null : _ref4$locale,
        _ref4$numberingSystem = _ref4.numberingSystem,
        numberingSystem = _ref4$numberingSystem === void 0 ? null : _ref4$numberingSystem;

    return Locale.create(locale, numberingSystem, null).weekdays(length, true);
  }
  /**
   * Return an array of meridiems.
   * @param {Object} opts - options
   * @param {string} [opts.locale] - the locale code
   * @example Info.meridiems() //=> [ 'AM', 'PM' ]
   * @example Info.meridiems({ locale: 'my' }) //=> [ 'နံနက်', 'ညနေ' ]
   * @return {[string]}
   */
  ;

  Info.meridiems = function meridiems(_temp5) {
    var _ref5 = _temp5 === void 0 ? {} : _temp5,
        _ref5$locale = _ref5.locale,
        locale = _ref5$locale === void 0 ? null : _ref5$locale;

    return Locale.create(locale).meridiems();
  }
  /**
   * Return an array of eras, such as ['BC', 'AD']. The locale can be specified, but the calendar system is always Gregorian.
   * @param {string} [length='short'] - the length of the era representation, such as "short" or "long".
   * @param {Object} opts - options
   * @param {string} [opts.locale] - the locale code
   * @example Info.eras() //=> [ 'BC', 'AD' ]
   * @example Info.eras('long') //=> [ 'Before Christ', 'Anno Domini' ]
   * @example Info.eras('long', { locale: 'fr' }) //=> [ 'avant Jésus-Christ', 'après Jésus-Christ' ]
   * @return {[string]}
   */
  ;

  Info.eras = function eras(length, _temp6) {
    if (length === void 0) {
      length = "short";
    }

    var _ref6 = _temp6 === void 0 ? {} : _temp6,
        _ref6$locale = _ref6.locale,
        locale = _ref6$locale === void 0 ? null : _ref6$locale;

    return Locale.create(locale, null, "gregory").eras(length);
  }
  /**
   * Return the set of available features in this environment.
   * Some features of Luxon are not available in all environments. For example, on older browsers, timezone support is not available. Use this function to figure out if that's the case.
   * Keys:
   * * `zones`: whether this environment supports IANA timezones
   * * `intlTokens`: whether this environment supports internationalized token-based formatting/parsing
   * * `intl`: whether this environment supports general internationalization
   * * `relative`: whether this environment supports relative time formatting
   * @example Info.features() //=> { intl: true, intlTokens: false, zones: true, relative: false }
   * @return {Object}
   */
  ;

  Info.features = function features() {
    var intl = false,
        intlTokens = false,
        zones = false,
        relative = false;

    if (hasIntl()) {
      intl = true;
      intlTokens = hasFormatToParts();
      relative = hasRelative();

      try {
        zones = new Intl.DateTimeFormat("en", {
          timeZone: "America/New_York"
        }).resolvedOptions().timeZone === "America/New_York";
      } catch (e) {
        zones = false;
      }
    }

    return {
      intl: intl,
      intlTokens: intlTokens,
      zones: zones,
      relative: relative
    };
  };

  return Info;
}();

function dayDiff(earlier, later) {
  var utcDayStart = function utcDayStart(dt) {
    return dt.toUTC(0, {
      keepLocalTime: true
    }).startOf("day").valueOf();
  },
      ms = utcDayStart(later) - utcDayStart(earlier);

  return Math.floor(Duration.fromMillis(ms).as("days"));
}

function highOrderDiffs(cursor, later, units) {
  var differs = [["years", function (a, b) {
    return b.year - a.year;
  }], ["months", function (a, b) {
    return b.month - a.month + (b.year - a.year) * 12;
  }], ["weeks", function (a, b) {
    var days = dayDiff(a, b);
    return (days - days % 7) / 7;
  }], ["days", dayDiff]];
  var results = {};
  var lowestOrder, highWater;

  for (var _i = 0, _differs = differs; _i < _differs.length; _i++) {
    var _differs$_i = _differs[_i],
        unit = _differs$_i[0],
        differ = _differs$_i[1];

    if (units.indexOf(unit) >= 0) {
      var _cursor$plus;

      lowestOrder = unit;
      var delta = differ(cursor, later);
      highWater = cursor.plus((_cursor$plus = {}, _cursor$plus[unit] = delta, _cursor$plus));

      if (highWater > later) {
        var _cursor$plus2;

        cursor = cursor.plus((_cursor$plus2 = {}, _cursor$plus2[unit] = delta - 1, _cursor$plus2));
        delta -= 1;
      } else {
        cursor = highWater;
      }

      results[unit] = delta;
    }
  }

  return [cursor, results, highWater, lowestOrder];
}

function _diff (earlier, later, units, opts) {
  var _highOrderDiffs = highOrderDiffs(earlier, later, units),
      cursor = _highOrderDiffs[0],
      results = _highOrderDiffs[1],
      highWater = _highOrderDiffs[2],
      lowestOrder = _highOrderDiffs[3];

  var remainingMillis = later - cursor;
  var lowerOrderUnits = units.filter(function (u) {
    return ["hours", "minutes", "seconds", "milliseconds"].indexOf(u) >= 0;
  });

  if (lowerOrderUnits.length === 0) {
    if (highWater < later) {
      var _cursor$plus3;

      highWater = cursor.plus((_cursor$plus3 = {}, _cursor$plus3[lowestOrder] = 1, _cursor$plus3));
    }

    if (highWater !== cursor) {
      results[lowestOrder] = (results[lowestOrder] || 0) + remainingMillis / (highWater - cursor);
    }
  }

  var duration = Duration.fromObject(Object.assign(results, opts));

  if (lowerOrderUnits.length > 0) {
    var _Duration$fromMillis;

    return (_Duration$fromMillis = Duration.fromMillis(remainingMillis, opts)).shiftTo.apply(_Duration$fromMillis, lowerOrderUnits).plus(duration);
  } else {
    return duration;
  }
}

var numberingSystems = {
  arab: "[\u0660-\u0669]",
  arabext: "[\u06F0-\u06F9]",
  bali: "[\u1B50-\u1B59]",
  beng: "[\u09E6-\u09EF]",
  deva: "[\u0966-\u096F]",
  fullwide: "[\uFF10-\uFF19]",
  gujr: "[\u0AE6-\u0AEF]",
  hanidec: "[〇|一|二|三|四|五|六|七|八|九]",
  khmr: "[\u17E0-\u17E9]",
  knda: "[\u0CE6-\u0CEF]",
  laoo: "[\u0ED0-\u0ED9]",
  limb: "[\u1946-\u194F]",
  mlym: "[\u0D66-\u0D6F]",
  mong: "[\u1810-\u1819]",
  mymr: "[\u1040-\u1049]",
  orya: "[\u0B66-\u0B6F]",
  tamldec: "[\u0BE6-\u0BEF]",
  telu: "[\u0C66-\u0C6F]",
  thai: "[\u0E50-\u0E59]",
  tibt: "[\u0F20-\u0F29]",
  latn: "\\d"
};
var numberingSystemsUTF16 = {
  arab: [1632, 1641],
  arabext: [1776, 1785],
  bali: [6992, 7001],
  beng: [2534, 2543],
  deva: [2406, 2415],
  fullwide: [65296, 65303],
  gujr: [2790, 2799],
  khmr: [6112, 6121],
  knda: [3302, 3311],
  laoo: [3792, 3801],
  limb: [6470, 6479],
  mlym: [3430, 3439],
  mong: [6160, 6169],
  mymr: [4160, 4169],
  orya: [2918, 2927],
  tamldec: [3046, 3055],
  telu: [3174, 3183],
  thai: [3664, 3673],
  tibt: [3872, 3881]
}; // eslint-disable-next-line

var hanidecChars = numberingSystems.hanidec.replace(/[\[|\]]/g, "").split("");
function parseDigits(str) {
  var value = parseInt(str, 10);

  if (isNaN(value)) {
    value = "";

    for (var i = 0; i < str.length; i++) {
      var code = str.charCodeAt(i);

      if (str[i].search(numberingSystems.hanidec) !== -1) {
        value += hanidecChars.indexOf(str[i]);
      } else {
        for (var key in numberingSystemsUTF16) {
          var _numberingSystemsUTF = numberingSystemsUTF16[key],
              min = _numberingSystemsUTF[0],
              max = _numberingSystemsUTF[1];

          if (code >= min && code <= max) {
            value += code - min;
          }
        }
      }
    }

    return parseInt(value, 10);
  } else {
    return value;
  }
}
function digitRegex(_ref, append) {
  var numberingSystem = _ref.numberingSystem;

  if (append === void 0) {
    append = "";
  }

  return new RegExp("" + numberingSystems[numberingSystem || "latn"] + append);
}

var MISSING_FTP = "missing Intl.DateTimeFormat.formatToParts support";

function intUnit(regex, post) {
  if (post === void 0) {
    post = function post(i) {
      return i;
    };
  }

  return {
    regex: regex,
    deser: function deser(_ref) {
      var s = _ref[0];
      return post(parseDigits(s));
    }
  };
}

function fixListRegex(s) {
  // make dots optional and also make them literal
  return s.replace(/\./, "\\.?");
}

function stripInsensitivities(s) {
  return s.replace(/\./, "").toLowerCase();
}

function oneOf(strings, startIndex) {
  if (strings === null) {
    return null;
  } else {
    return {
      regex: RegExp(strings.map(fixListRegex).join("|")),
      deser: function deser(_ref2) {
        var s = _ref2[0];
        return strings.findIndex(function (i) {
          return stripInsensitivities(s) === stripInsensitivities(i);
        }) + startIndex;
      }
    };
  }
}

function offset(regex, groups) {
  return {
    regex: regex,
    deser: function deser(_ref3) {
      var h = _ref3[1],
          m = _ref3[2];
      return signedOffset(h, m);
    },
    groups: groups
  };
}

function simple(regex) {
  return {
    regex: regex,
    deser: function deser(_ref4) {
      var s = _ref4[0];
      return s;
    }
  };
}

function escapeToken(value) {
  // eslint-disable-next-line no-useless-escape
  return value.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g, "\\$&");
}

function unitForToken(token, loc) {
  var one = digitRegex(loc),
      two = digitRegex(loc, "{2}"),
      three = digitRegex(loc, "{3}"),
      four = digitRegex(loc, "{4}"),
      six = digitRegex(loc, "{6}"),
      oneOrTwo = digitRegex(loc, "{1,2}"),
      oneToThree = digitRegex(loc, "{1,3}"),
      oneToSix = digitRegex(loc, "{1,6}"),
      oneToNine = digitRegex(loc, "{1,9}"),
      twoToFour = digitRegex(loc, "{2,4}"),
      fourToSix = digitRegex(loc, "{4,6}"),
      literal = function literal(t) {
    return {
      regex: RegExp(escapeToken(t.val)),
      deser: function deser(_ref5) {
        var s = _ref5[0];
        return s;
      },
      literal: true
    };
  },
      unitate = function unitate(t) {
    if (token.literal) {
      return literal(t);
    }

    switch (t.val) {
      // era
      case "G":
        return oneOf(loc.eras("short", false), 0);

      case "GG":
        return oneOf(loc.eras("long", false), 0);
      // years

      case "y":
        return intUnit(oneToSix);

      case "yy":
        return intUnit(twoToFour, untruncateYear);

      case "yyyy":
        return intUnit(four);

      case "yyyyy":
        return intUnit(fourToSix);

      case "yyyyyy":
        return intUnit(six);
      // months

      case "M":
        return intUnit(oneOrTwo);

      case "MM":
        return intUnit(two);

      case "MMM":
        return oneOf(loc.months("short", true, false), 1);

      case "MMMM":
        return oneOf(loc.months("long", true, false), 1);

      case "L":
        return intUnit(oneOrTwo);

      case "LL":
        return intUnit(two);

      case "LLL":
        return oneOf(loc.months("short", false, false), 1);

      case "LLLL":
        return oneOf(loc.months("long", false, false), 1);
      // dates

      case "d":
        return intUnit(oneOrTwo);

      case "dd":
        return intUnit(two);
      // ordinals

      case "o":
        return intUnit(oneToThree);

      case "ooo":
        return intUnit(three);
      // time

      case "HH":
        return intUnit(two);

      case "H":
        return intUnit(oneOrTwo);

      case "hh":
        return intUnit(two);

      case "h":
        return intUnit(oneOrTwo);

      case "mm":
        return intUnit(two);

      case "m":
        return intUnit(oneOrTwo);

      case "q":
        return intUnit(oneOrTwo);

      case "qq":
        return intUnit(two);

      case "s":
        return intUnit(oneOrTwo);

      case "ss":
        return intUnit(two);

      case "S":
        return intUnit(oneToThree);

      case "SSS":
        return intUnit(three);

      case "u":
        return simple(oneToNine);
      // meridiem

      case "a":
        return oneOf(loc.meridiems(), 0);
      // weekYear (k)

      case "kkkk":
        return intUnit(four);

      case "kk":
        return intUnit(twoToFour, untruncateYear);
      // weekNumber (W)

      case "W":
        return intUnit(oneOrTwo);

      case "WW":
        return intUnit(two);
      // weekdays

      case "E":
      case "c":
        return intUnit(one);

      case "EEE":
        return oneOf(loc.weekdays("short", false, false), 1);

      case "EEEE":
        return oneOf(loc.weekdays("long", false, false), 1);

      case "ccc":
        return oneOf(loc.weekdays("short", true, false), 1);

      case "cccc":
        return oneOf(loc.weekdays("long", true, false), 1);
      // offset/zone

      case "Z":
      case "ZZ":
        return offset(new RegExp("([+-]" + oneOrTwo.source + ")(?::(" + two.source + "))?"), 2);

      case "ZZZ":
        return offset(new RegExp("([+-]" + oneOrTwo.source + ")(" + two.source + ")?"), 2);
      // we don't support ZZZZ (PST) or ZZZZZ (Pacific Standard Time) in parsing
      // because we don't have any way to figure out what they are

      case "z":
        return simple(/[a-z_+-/]{1,256}?/i);

      default:
        return literal(t);
    }
  };

  var unit = unitate(token) || {
    invalidReason: MISSING_FTP
  };
  unit.token = token;
  return unit;
}

var partTypeStyleToTokenVal = {
  year: {
    "2-digit": "yy",
    numeric: "yyyyy"
  },
  month: {
    numeric: "M",
    "2-digit": "MM",
    short: "MMM",
    long: "MMMM"
  },
  day: {
    numeric: "d",
    "2-digit": "dd"
  },
  weekday: {
    short: "EEE",
    long: "EEEE"
  },
  dayperiod: "a",
  dayPeriod: "a",
  hour: {
    numeric: "h",
    "2-digit": "hh"
  },
  minute: {
    numeric: "m",
    "2-digit": "mm"
  },
  second: {
    numeric: "s",
    "2-digit": "ss"
  }
};

function tokenForPart(part, locale, formatOpts) {
  var type = part.type,
      value = part.value;

  if (type === "literal") {
    return {
      literal: true,
      val: value
    };
  }

  var style = formatOpts[type];
  var val = partTypeStyleToTokenVal[type];

  if (typeof val === "object") {
    val = val[style];
  }

  if (val) {
    return {
      literal: false,
      val: val
    };
  }

  return undefined;
}

function buildRegex(units) {
  var re = units.map(function (u) {
    return u.regex;
  }).reduce(function (f, r) {
    return f + "(" + r.source + ")";
  }, "");
  return ["^" + re + "$", units];
}

function match(input, regex, handlers) {
  var matches = input.match(regex);

  if (matches) {
    var all = {};
    var matchIndex = 1;

    for (var i in handlers) {
      if (hasOwnProperty(handlers, i)) {
        var h = handlers[i],
            groups = h.groups ? h.groups + 1 : 1;

        if (!h.literal && h.token) {
          all[h.token.val[0]] = h.deser(matches.slice(matchIndex, matchIndex + groups));
        }

        matchIndex += groups;
      }
    }

    return [matches, all];
  } else {
    return [matches, {}];
  }
}

function dateTimeFromMatches(matches) {
  var toField = function toField(token) {
    switch (token) {
      case "S":
        return "millisecond";

      case "s":
        return "second";

      case "m":
        return "minute";

      case "h":
      case "H":
        return "hour";

      case "d":
        return "day";

      case "o":
        return "ordinal";

      case "L":
      case "M":
        return "month";

      case "y":
        return "year";

      case "E":
      case "c":
        return "weekday";

      case "W":
        return "weekNumber";

      case "k":
        return "weekYear";

      case "q":
        return "quarter";

      default:
        return null;
    }
  };

  var zone;

  if (!isUndefined(matches.Z)) {
    zone = new FixedOffsetZone(matches.Z);
  } else if (!isUndefined(matches.z)) {
    zone = IANAZone.create(matches.z);
  } else {
    zone = null;
  }

  if (!isUndefined(matches.q)) {
    matches.M = (matches.q - 1) * 3 + 1;
  }

  if (!isUndefined(matches.h)) {
    if (matches.h < 12 && matches.a === 1) {
      matches.h += 12;
    } else if (matches.h === 12 && matches.a === 0) {
      matches.h = 0;
    }
  }

  if (matches.G === 0 && matches.y) {
    matches.y = -matches.y;
  }

  if (!isUndefined(matches.u)) {
    matches.S = parseMillis(matches.u);
  }

  var vals = Object.keys(matches).reduce(function (r, k) {
    var f = toField(k);

    if (f) {
      r[f] = matches[k];
    }

    return r;
  }, {});
  return [vals, zone];
}

var dummyDateTimeCache = null;

function getDummyDateTime() {
  if (!dummyDateTimeCache) {
    dummyDateTimeCache = DateTime.fromMillis(1555555555555);
  }

  return dummyDateTimeCache;
}

function maybeExpandMacroToken(token, locale) {
  if (token.literal) {
    return token;
  }

  var formatOpts = Formatter.macroTokenToFormatOpts(token.val);

  if (!formatOpts) {
    return token;
  }

  var formatter = Formatter.create(locale, formatOpts);
  var parts = formatter.formatDateTimeParts(getDummyDateTime());
  var tokens = parts.map(function (p) {
    return tokenForPart(p, locale, formatOpts);
  });

  if (tokens.includes(undefined)) {
    return token;
  }

  return tokens;
}

function expandMacroTokens(tokens, locale) {
  var _Array$prototype;

  return (_Array$prototype = Array.prototype).concat.apply(_Array$prototype, tokens.map(function (t) {
    return maybeExpandMacroToken(t, locale);
  }));
}
/**
 * @private
 */


function explainFromTokens(locale, input, format) {
  var tokens = expandMacroTokens(Formatter.parseFormat(format), locale),
      units = tokens.map(function (t) {
    return unitForToken(t, locale);
  }),
      disqualifyingUnit = units.find(function (t) {
    return t.invalidReason;
  });

  if (disqualifyingUnit) {
    return {
      input: input,
      tokens: tokens,
      invalidReason: disqualifyingUnit.invalidReason
    };
  } else {
    var _buildRegex = buildRegex(units),
        regexString = _buildRegex[0],
        handlers = _buildRegex[1],
        regex = RegExp(regexString, "i"),
        _match = match(input, regex, handlers),
        rawMatches = _match[0],
        matches = _match[1],
        _ref6 = matches ? dateTimeFromMatches(matches) : [null, null],
        result = _ref6[0],
        zone = _ref6[1];

    if (hasOwnProperty(matches, "a") && hasOwnProperty(matches, "H")) {
      throw new ConflictingSpecificationError("Can't include meridiem when specifying 24-hour format");
    }

    return {
      input: input,
      tokens: tokens,
      regex: regex,
      rawMatches: rawMatches,
      matches: matches,
      result: result,
      zone: zone
    };
  }
}
function parseFromTokens(locale, input, format) {
  var _explainFromTokens = explainFromTokens(locale, input, format),
      result = _explainFromTokens.result,
      zone = _explainFromTokens.zone,
      invalidReason = _explainFromTokens.invalidReason;

  return [result, zone, invalidReason];
}

var nonLeapLadder = [0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334],
    leapLadder = [0, 31, 60, 91, 121, 152, 182, 213, 244, 274, 305, 335];

function unitOutOfRange(unit, value) {
  return new Invalid("unit out of range", "you specified " + value + " (of type " + typeof value + ") as a " + unit + ", which is invalid");
}

function dayOfWeek(year, month, day) {
  var js = new Date(Date.UTC(year, month - 1, day)).getUTCDay();
  return js === 0 ? 7 : js;
}

function computeOrdinal(year, month, day) {
  return day + (isLeapYear(year) ? leapLadder : nonLeapLadder)[month - 1];
}

function uncomputeOrdinal(year, ordinal) {
  var table = isLeapYear(year) ? leapLadder : nonLeapLadder,
      month0 = table.findIndex(function (i) {
    return i < ordinal;
  }),
      day = ordinal - table[month0];
  return {
    month: month0 + 1,
    day: day
  };
}
/**
 * @private
 */


function gregorianToWeek(gregObj) {
  var year = gregObj.year,
      month = gregObj.month,
      day = gregObj.day,
      ordinal = computeOrdinal(year, month, day),
      weekday = dayOfWeek(year, month, day);
  var weekNumber = Math.floor((ordinal - weekday + 10) / 7),
      weekYear;

  if (weekNumber < 1) {
    weekYear = year - 1;
    weekNumber = weeksInWeekYear(weekYear);
  } else if (weekNumber > weeksInWeekYear(year)) {
    weekYear = year + 1;
    weekNumber = 1;
  } else {
    weekYear = year;
  }

  return Object.assign({
    weekYear: weekYear,
    weekNumber: weekNumber,
    weekday: weekday
  }, timeObject(gregObj));
}
function weekToGregorian(weekData) {
  var weekYear = weekData.weekYear,
      weekNumber = weekData.weekNumber,
      weekday = weekData.weekday,
      weekdayOfJan4 = dayOfWeek(weekYear, 1, 4),
      yearInDays = daysInYear(weekYear);
  var ordinal = weekNumber * 7 + weekday - weekdayOfJan4 - 3,
      year;

  if (ordinal < 1) {
    year = weekYear - 1;
    ordinal += daysInYear(year);
  } else if (ordinal > yearInDays) {
    year = weekYear + 1;
    ordinal -= daysInYear(weekYear);
  } else {
    year = weekYear;
  }

  var _uncomputeOrdinal = uncomputeOrdinal(year, ordinal),
      month = _uncomputeOrdinal.month,
      day = _uncomputeOrdinal.day;

  return Object.assign({
    year: year,
    month: month,
    day: day
  }, timeObject(weekData));
}
function gregorianToOrdinal(gregData) {
  var year = gregData.year,
      month = gregData.month,
      day = gregData.day,
      ordinal = computeOrdinal(year, month, day);
  return Object.assign({
    year: year,
    ordinal: ordinal
  }, timeObject(gregData));
}
function ordinalToGregorian(ordinalData) {
  var year = ordinalData.year,
      ordinal = ordinalData.ordinal,
      _uncomputeOrdinal2 = uncomputeOrdinal(year, ordinal),
      month = _uncomputeOrdinal2.month,
      day = _uncomputeOrdinal2.day;

  return Object.assign({
    year: year,
    month: month,
    day: day
  }, timeObject(ordinalData));
}
function hasInvalidWeekData(obj) {
  var validYear = isInteger(obj.weekYear),
      validWeek = integerBetween(obj.weekNumber, 1, weeksInWeekYear(obj.weekYear)),
      validWeekday = integerBetween(obj.weekday, 1, 7);

  if (!validYear) {
    return unitOutOfRange("weekYear", obj.weekYear);
  } else if (!validWeek) {
    return unitOutOfRange("week", obj.week);
  } else if (!validWeekday) {
    return unitOutOfRange("weekday", obj.weekday);
  } else return false;
}
function hasInvalidOrdinalData(obj) {
  var validYear = isInteger(obj.year),
      validOrdinal = integerBetween(obj.ordinal, 1, daysInYear(obj.year));

  if (!validYear) {
    return unitOutOfRange("year", obj.year);
  } else if (!validOrdinal) {
    return unitOutOfRange("ordinal", obj.ordinal);
  } else return false;
}
function hasInvalidGregorianData(obj) {
  var validYear = isInteger(obj.year),
      validMonth = integerBetween(obj.month, 1, 12),
      validDay = integerBetween(obj.day, 1, daysInMonth(obj.year, obj.month));

  if (!validYear) {
    return unitOutOfRange("year", obj.year);
  } else if (!validMonth) {
    return unitOutOfRange("month", obj.month);
  } else if (!validDay) {
    return unitOutOfRange("day", obj.day);
  } else return false;
}
function hasInvalidTimeData(obj) {
  var hour = obj.hour,
      minute = obj.minute,
      second = obj.second,
      millisecond = obj.millisecond;
  var validHour = integerBetween(hour, 0, 23) || hour === 24 && minute === 0 && second === 0 && millisecond === 0,
      validMinute = integerBetween(minute, 0, 59),
      validSecond = integerBetween(second, 0, 59),
      validMillisecond = integerBetween(millisecond, 0, 999);

  if (!validHour) {
    return unitOutOfRange("hour", hour);
  } else if (!validMinute) {
    return unitOutOfRange("minute", minute);
  } else if (!validSecond) {
    return unitOutOfRange("second", second);
  } else if (!validMillisecond) {
    return unitOutOfRange("millisecond", millisecond);
  } else return false;
}

var INVALID$2 = "Invalid DateTime";
var MAX_DATE = 8.64e15;

function unsupportedZone(zone) {
  return new Invalid("unsupported zone", "the zone \"" + zone.name + "\" is not supported");
} // we cache week data on the DT object and this intermediates the cache


function possiblyCachedWeekData(dt) {
  if (dt.weekData === null) {
    dt.weekData = gregorianToWeek(dt.c);
  }

  return dt.weekData;
} // clone really means, "make a new object with these modifications". all "setters" really use this
// to create a new object while only changing some of the properties


function clone$1(inst, alts) {
  var current = {
    ts: inst.ts,
    zone: inst.zone,
    c: inst.c,
    o: inst.o,
    loc: inst.loc,
    invalid: inst.invalid
  };
  return new DateTime(Object.assign({}, current, alts, {
    old: current
  }));
} // find the right offset a given local time. The o input is our guess, which determines which
// offset we'll pick in ambiguous cases (e.g. there are two 3 AMs b/c Fallback DST)


function fixOffset(localTS, o, tz) {
  // Our UTC time is just a guess because our offset is just a guess
  var utcGuess = localTS - o * 60 * 1000; // Test whether the zone matches the offset for this ts

  var o2 = tz.offset(utcGuess); // If so, offset didn't change and we're done

  if (o === o2) {
    return [utcGuess, o];
  } // If not, change the ts by the difference in the offset


  utcGuess -= (o2 - o) * 60 * 1000; // If that gives us the local time we want, we're done

  var o3 = tz.offset(utcGuess);

  if (o2 === o3) {
    return [utcGuess, o2];
  } // If it's different, we're in a hole time. The offset has changed, but the we don't adjust the time


  return [localTS - Math.min(o2, o3) * 60 * 1000, Math.max(o2, o3)];
} // convert an epoch timestamp into a calendar object with the given offset


function tsToObj(ts, offset) {
  ts += offset * 60 * 1000;
  var d = new Date(ts);
  return {
    year: d.getUTCFullYear(),
    month: d.getUTCMonth() + 1,
    day: d.getUTCDate(),
    hour: d.getUTCHours(),
    minute: d.getUTCMinutes(),
    second: d.getUTCSeconds(),
    millisecond: d.getUTCMilliseconds()
  };
} // convert a calendar object to a epoch timestamp


function objToTS(obj, offset, zone) {
  return fixOffset(objToLocalTS(obj), offset, zone);
} // create a new DT instance by adding a duration, adjusting for DSTs


function adjustTime(inst, dur) {
  var _dur;

  var keys = Object.keys(dur.values);

  if (keys.indexOf("milliseconds") === -1) {
    keys.push("milliseconds");
  }

  dur = (_dur = dur).shiftTo.apply(_dur, keys);
  var oPre = inst.o,
      year = inst.c.year + dur.years,
      month = inst.c.month + dur.months + dur.quarters * 3,
      c = Object.assign({}, inst.c, {
    year: year,
    month: month,
    day: Math.min(inst.c.day, daysInMonth(year, month)) + dur.days + dur.weeks * 7
  }),
      millisToAdd = Duration.fromObject({
    hours: dur.hours,
    minutes: dur.minutes,
    seconds: dur.seconds,
    milliseconds: dur.milliseconds
  }).as("milliseconds"),
      localTS = objToLocalTS(c);

  var _fixOffset = fixOffset(localTS, oPre, inst.zone),
      ts = _fixOffset[0],
      o = _fixOffset[1];

  if (millisToAdd !== 0) {
    ts += millisToAdd; // that could have changed the offset by going over a DST, but we want to keep the ts the same

    o = inst.zone.offset(ts);
  }

  return {
    ts: ts,
    o: o
  };
} // helper useful in turning the results of parsing into real dates
// by handling the zone options


function parseDataToDateTime(parsed, parsedZone, opts, format, text) {
  var setZone = opts.setZone,
      zone = opts.zone;

  if (parsed && Object.keys(parsed).length !== 0) {
    var interpretationZone = parsedZone || zone,
        inst = DateTime.fromObject(Object.assign(parsed, opts, {
      zone: interpretationZone,
      // setZone is a valid option in the calling methods, but not in fromObject
      setZone: undefined
    }));
    return setZone ? inst : inst.setZone(zone);
  } else {
    return DateTime.invalid(new Invalid("unparsable", "the input \"" + text + "\" can't be parsed as " + format));
  }
} // if you want to output a technical format (e.g. RFC 2822), this helper
// helps handle the details


function toTechFormat(dt, format, allowZ) {
  if (allowZ === void 0) {
    allowZ = true;
  }

  return dt.isValid ? Formatter.create(Locale.create("en-US"), {
    allowZ: allowZ,
    forceSimple: true
  }).formatDateTimeFromString(dt, format) : null;
} // technical time formats (e.g. the time part of ISO 8601), take some options
// and this commonizes their handling


function toTechTimeFormat(dt, _ref) {
  var _ref$suppressSeconds = _ref.suppressSeconds,
      suppressSeconds = _ref$suppressSeconds === void 0 ? false : _ref$suppressSeconds,
      _ref$suppressMillisec = _ref.suppressMilliseconds,
      suppressMilliseconds = _ref$suppressMillisec === void 0 ? false : _ref$suppressMillisec,
      includeOffset = _ref.includeOffset,
      _ref$includeZone = _ref.includeZone,
      includeZone = _ref$includeZone === void 0 ? false : _ref$includeZone,
      _ref$spaceZone = _ref.spaceZone,
      spaceZone = _ref$spaceZone === void 0 ? false : _ref$spaceZone,
      _ref$format = _ref.format,
      format = _ref$format === void 0 ? "extended" : _ref$format;
  var fmt = format === "basic" ? "HHmm" : "HH:mm";

  if (!suppressSeconds || dt.second !== 0 || dt.millisecond !== 0) {
    fmt += format === "basic" ? "ss" : ":ss";

    if (!suppressMilliseconds || dt.millisecond !== 0) {
      fmt += ".SSS";
    }
  }

  if ((includeZone || includeOffset) && spaceZone) {
    fmt += " ";
  }

  if (includeZone) {
    fmt += "z";
  } else if (includeOffset) {
    fmt += format === "basic" ? "ZZZ" : "ZZ";
  }

  return toTechFormat(dt, fmt);
} // defaults for unspecified units in the supported calendars


var defaultUnitValues = {
  month: 1,
  day: 1,
  hour: 0,
  minute: 0,
  second: 0,
  millisecond: 0
},
    defaultWeekUnitValues = {
  weekNumber: 1,
  weekday: 1,
  hour: 0,
  minute: 0,
  second: 0,
  millisecond: 0
},
    defaultOrdinalUnitValues = {
  ordinal: 1,
  hour: 0,
  minute: 0,
  second: 0,
  millisecond: 0
}; // Units in the supported calendars, sorted by bigness

var orderedUnits$1 = ["year", "month", "day", "hour", "minute", "second", "millisecond"],
    orderedWeekUnits = ["weekYear", "weekNumber", "weekday", "hour", "minute", "second", "millisecond"],
    orderedOrdinalUnits = ["year", "ordinal", "hour", "minute", "second", "millisecond"]; // standardize case and plurality in units

function normalizeUnit(unit) {
  var normalized = {
    year: "year",
    years: "year",
    month: "month",
    months: "month",
    day: "day",
    days: "day",
    hour: "hour",
    hours: "hour",
    minute: "minute",
    minutes: "minute",
    quarter: "quarter",
    quarters: "quarter",
    second: "second",
    seconds: "second",
    millisecond: "millisecond",
    milliseconds: "millisecond",
    weekday: "weekday",
    weekdays: "weekday",
    weeknumber: "weekNumber",
    weeksnumber: "weekNumber",
    weeknumbers: "weekNumber",
    weekyear: "weekYear",
    weekyears: "weekYear",
    ordinal: "ordinal"
  }[unit.toLowerCase()];
  if (!normalized) throw new InvalidUnitError(unit);
  return normalized;
} // this is a dumbed down version of fromObject() that runs about 60% faster
// but doesn't do any validation, makes a bunch of assumptions about what units
// are present, and so on.


function quickDT(obj, zone) {
  // assume we have the higher-order units
  for (var _iterator = _createForOfIteratorHelperLoose(orderedUnits$1), _step; !(_step = _iterator()).done;) {
    var u = _step.value;

    if (isUndefined(obj[u])) {
      obj[u] = defaultUnitValues[u];
    }
  }

  var invalid = hasInvalidGregorianData(obj) || hasInvalidTimeData(obj);

  if (invalid) {
    return DateTime.invalid(invalid);
  }

  var tsNow = Settings.now(),
      offsetProvis = zone.offset(tsNow),
      _objToTS = objToTS(obj, offsetProvis, zone),
      ts = _objToTS[0],
      o = _objToTS[1];

  return new DateTime({
    ts: ts,
    zone: zone,
    o: o
  });
}

function diffRelative(start, end, opts) {
  var round = isUndefined(opts.round) ? true : opts.round,
      format = function format(c, unit) {
    c = roundTo(c, round || opts.calendary ? 0 : 2, true);
    var formatter = end.loc.clone(opts).relFormatter(opts);
    return formatter.format(c, unit);
  },
      differ = function differ(unit) {
    if (opts.calendary) {
      if (!end.hasSame(start, unit)) {
        return end.startOf(unit).diff(start.startOf(unit), unit).get(unit);
      } else return 0;
    } else {
      return end.diff(start, unit).get(unit);
    }
  };

  if (opts.unit) {
    return format(differ(opts.unit), opts.unit);
  }

  for (var _iterator2 = _createForOfIteratorHelperLoose(opts.units), _step2; !(_step2 = _iterator2()).done;) {
    var unit = _step2.value;
    var count = differ(unit);

    if (Math.abs(count) >= 1) {
      return format(count, unit);
    }
  }

  return format(0, opts.units[opts.units.length - 1]);
}
/**
 * A DateTime is an immutable data structure representing a specific date and time and accompanying methods. It contains class and instance methods for creating, parsing, interrogating, transforming, and formatting them.
 *
 * A DateTime comprises of:
 * * A timestamp. Each DateTime instance refers to a specific millisecond of the Unix epoch.
 * * A time zone. Each instance is considered in the context of a specific zone (by default the local system's zone).
 * * Configuration properties that effect how output strings are formatted, such as `locale`, `numberingSystem`, and `outputCalendar`.
 *
 * Here is a brief overview of the most commonly used functionality it provides:
 *
 * * **Creation**: To create a DateTime from its components, use one of its factory class methods: {@link local}, {@link utc}, and (most flexibly) {@link fromObject}. To create one from a standard string format, use {@link fromISO}, {@link fromHTTP}, and {@link fromRFC2822}. To create one from a custom string format, use {@link fromFormat}. To create one from a native JS date, use {@link fromJSDate}.
 * * **Gregorian calendar and time**: To examine the Gregorian properties of a DateTime individually (i.e as opposed to collectively through {@link toObject}), use the {@link year}, {@link month},
 * {@link day}, {@link hour}, {@link minute}, {@link second}, {@link millisecond} accessors.
 * * **Week calendar**: For ISO week calendar attributes, see the {@link weekYear}, {@link weekNumber}, and {@link weekday} accessors.
 * * **Configuration** See the {@link locale} and {@link numberingSystem} accessors.
 * * **Transformation**: To transform the DateTime into other DateTimes, use {@link set}, {@link reconfigure}, {@link setZone}, {@link setLocale}, {@link plus}, {@link minus}, {@link endOf}, {@link startOf}, {@link toUTC}, and {@link toLocal}.
 * * **Output**: To convert the DateTime to other representations, use the {@link toRelative}, {@link toRelativeCalendar}, {@link toJSON}, {@link toISO}, {@link toHTTP}, {@link toObject}, {@link toRFC2822}, {@link toString}, {@link toLocaleString}, {@link toFormat}, {@link toMillis} and {@link toJSDate}.
 *
 * There's plenty others documented below. In addition, for more information on subtler topics like internationalization, time zones, alternative calendars, validity, and so on, see the external documentation.
 */


var DateTime = /*#__PURE__*/function () {
  /**
   * @access private
   */
  function DateTime(config) {
    var zone = config.zone || Settings.defaultZone;
    var invalid = config.invalid || (Number.isNaN(config.ts) ? new Invalid("invalid input") : null) || (!zone.isValid ? unsupportedZone(zone) : null);
    /**
     * @access private
     */

    this.ts = isUndefined(config.ts) ? Settings.now() : config.ts;
    var c = null,
        o = null;

    if (!invalid) {
      var unchanged = config.old && config.old.ts === this.ts && config.old.zone.equals(zone);

      if (unchanged) {
        var _ref2 = [config.old.c, config.old.o];
        c = _ref2[0];
        o = _ref2[1];
      } else {
        var ot = zone.offset(this.ts);
        c = tsToObj(this.ts, ot);
        invalid = Number.isNaN(c.year) ? new Invalid("invalid input") : null;
        c = invalid ? null : c;
        o = invalid ? null : ot;
      }
    }
    /**
     * @access private
     */


    this._zone = zone;
    /**
     * @access private
     */

    this.loc = config.loc || Locale.create();
    /**
     * @access private
     */

    this.invalid = invalid;
    /**
     * @access private
     */

    this.weekData = null;
    /**
     * @access private
     */

    this.c = c;
    /**
     * @access private
     */

    this.o = o;
    /**
     * @access private
     */

    this.isLuxonDateTime = true;
  } // CONSTRUCT

  /**
   * Create a local DateTime
   * @param {number} [year] - The calendar year. If omitted (as in, call `local()` with no arguments), the current time will be used
   * @param {number} [month=1] - The month, 1-indexed
   * @param {number} [day=1] - The day of the month
   * @param {number} [hour=0] - The hour of the day, in 24-hour time
   * @param {number} [minute=0] - The minute of the hour, meaning a number between 0 and 59
   * @param {number} [second=0] - The second of the minute, meaning a number between 0 and 59
   * @param {number} [millisecond=0] - The millisecond of the second, meaning a number between 0 and 999
   * @example DateTime.local()                            //~> now
   * @example DateTime.local(2017)                        //~> 2017-01-01T00:00:00
   * @example DateTime.local(2017, 3)                     //~> 2017-03-01T00:00:00
   * @example DateTime.local(2017, 3, 12)                 //~> 2017-03-12T00:00:00
   * @example DateTime.local(2017, 3, 12, 5)              //~> 2017-03-12T05:00:00
   * @example DateTime.local(2017, 3, 12, 5, 45)          //~> 2017-03-12T05:45:00
   * @example DateTime.local(2017, 3, 12, 5, 45, 10)      //~> 2017-03-12T05:45:10
   * @example DateTime.local(2017, 3, 12, 5, 45, 10, 765) //~> 2017-03-12T05:45:10.765
   * @return {DateTime}
   */


  DateTime.local = function local(year, month, day, hour, minute, second, millisecond) {
    if (isUndefined(year)) {
      return new DateTime({
        ts: Settings.now()
      });
    } else {
      return quickDT({
        year: year,
        month: month,
        day: day,
        hour: hour,
        minute: minute,
        second: second,
        millisecond: millisecond
      }, Settings.defaultZone);
    }
  }
  /**
   * Create a DateTime in UTC
   * @param {number} [year] - The calendar year. If omitted (as in, call `utc()` with no arguments), the current time will be used
   * @param {number} [month=1] - The month, 1-indexed
   * @param {number} [day=1] - The day of the month
   * @param {number} [hour=0] - The hour of the day, in 24-hour time
   * @param {number} [minute=0] - The minute of the hour, meaning a number between 0 and 59
   * @param {number} [second=0] - The second of the minute, meaning a number between 0 and 59
   * @param {number} [millisecond=0] - The millisecond of the second, meaning a number between 0 and 999
   * @example DateTime.utc()                            //~> now
   * @example DateTime.utc(2017)                        //~> 2017-01-01T00:00:00Z
   * @example DateTime.utc(2017, 3)                     //~> 2017-03-01T00:00:00Z
   * @example DateTime.utc(2017, 3, 12)                 //~> 2017-03-12T00:00:00Z
   * @example DateTime.utc(2017, 3, 12, 5)              //~> 2017-03-12T05:00:00Z
   * @example DateTime.utc(2017, 3, 12, 5, 45)          //~> 2017-03-12T05:45:00Z
   * @example DateTime.utc(2017, 3, 12, 5, 45, 10)      //~> 2017-03-12T05:45:10Z
   * @example DateTime.utc(2017, 3, 12, 5, 45, 10, 765) //~> 2017-03-12T05:45:10.765Z
   * @return {DateTime}
   */
  ;

  DateTime.utc = function utc(year, month, day, hour, minute, second, millisecond) {
    if (isUndefined(year)) {
      return new DateTime({
        ts: Settings.now(),
        zone: FixedOffsetZone.utcInstance
      });
    } else {
      return quickDT({
        year: year,
        month: month,
        day: day,
        hour: hour,
        minute: minute,
        second: second,
        millisecond: millisecond
      }, FixedOffsetZone.utcInstance);
    }
  }
  /**
   * Create a DateTime from a Javascript Date object. Uses the default zone.
   * @param {Date} date - a Javascript Date object
   * @param {Object} options - configuration options for the DateTime
   * @param {string|Zone} [options.zone='local'] - the zone to place the DateTime into
   * @return {DateTime}
   */
  ;

  DateTime.fromJSDate = function fromJSDate(date, options) {
    if (options === void 0) {
      options = {};
    }

    var ts = isDate(date) ? date.valueOf() : NaN;

    if (Number.isNaN(ts)) {
      return DateTime.invalid("invalid input");
    }

    var zoneToUse = normalizeZone(options.zone, Settings.defaultZone);

    if (!zoneToUse.isValid) {
      return DateTime.invalid(unsupportedZone(zoneToUse));
    }

    return new DateTime({
      ts: ts,
      zone: zoneToUse,
      loc: Locale.fromObject(options)
    });
  }
  /**
   * Create a DateTime from a number of milliseconds since the epoch (meaning since 1 January 1970 00:00:00 UTC). Uses the default zone.
   * @param {number} milliseconds - a number of milliseconds since 1970 UTC
   * @param {Object} options - configuration options for the DateTime
   * @param {string|Zone} [options.zone='local'] - the zone to place the DateTime into
   * @param {string} [options.locale] - a locale to set on the resulting DateTime instance
   * @param {string} options.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @param {string} options.numberingSystem - the numbering system to set on the resulting DateTime instance
   * @return {DateTime}
   */
  ;

  DateTime.fromMillis = function fromMillis(milliseconds, options) {
    if (options === void 0) {
      options = {};
    }

    if (!isNumber(milliseconds)) {
      throw new InvalidArgumentError("fromMillis requires a numerical input, but received a " + typeof milliseconds + " with value " + milliseconds);
    } else if (milliseconds < -MAX_DATE || milliseconds > MAX_DATE) {
      // this isn't perfect because because we can still end up out of range because of additional shifting, but it's a start
      return DateTime.invalid("Timestamp out of range");
    } else {
      return new DateTime({
        ts: milliseconds,
        zone: normalizeZone(options.zone, Settings.defaultZone),
        loc: Locale.fromObject(options)
      });
    }
  }
  /**
   * Create a DateTime from a number of seconds since the epoch (meaning since 1 January 1970 00:00:00 UTC). Uses the default zone.
   * @param {number} seconds - a number of seconds since 1970 UTC
   * @param {Object} options - configuration options for the DateTime
   * @param {string|Zone} [options.zone='local'] - the zone to place the DateTime into
   * @param {string} [options.locale] - a locale to set on the resulting DateTime instance
   * @param {string} options.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @param {string} options.numberingSystem - the numbering system to set on the resulting DateTime instance
   * @return {DateTime}
   */
  ;

  DateTime.fromSeconds = function fromSeconds(seconds, options) {
    if (options === void 0) {
      options = {};
    }

    if (!isNumber(seconds)) {
      throw new InvalidArgumentError("fromSeconds requires a numerical input");
    } else {
      return new DateTime({
        ts: seconds * 1000,
        zone: normalizeZone(options.zone, Settings.defaultZone),
        loc: Locale.fromObject(options)
      });
    }
  }
  /**
   * Create a DateTime from a Javascript object with keys like 'year' and 'hour' with reasonable defaults.
   * @param {Object} obj - the object to create the DateTime from
   * @param {number} obj.year - a year, such as 1987
   * @param {number} obj.month - a month, 1-12
   * @param {number} obj.day - a day of the month, 1-31, depending on the month
   * @param {number} obj.ordinal - day of the year, 1-365 or 366
   * @param {number} obj.weekYear - an ISO week year
   * @param {number} obj.weekNumber - an ISO week number, between 1 and 52 or 53, depending on the year
   * @param {number} obj.weekday - an ISO weekday, 1-7, where 1 is Monday and 7 is Sunday
   * @param {number} obj.hour - hour of the day, 0-23
   * @param {number} obj.minute - minute of the hour, 0-59
   * @param {number} obj.second - second of the minute, 0-59
   * @param {number} obj.millisecond - millisecond of the second, 0-999
   * @param {string|Zone} [obj.zone='local'] - interpret the numbers in the context of a particular zone. Can take any value taken as the first argument to setZone()
   * @param {string} [obj.locale='system's locale'] - a locale to set on the resulting DateTime instance
   * @param {string} obj.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @param {string} obj.numberingSystem - the numbering system to set on the resulting DateTime instance
   * @example DateTime.fromObject({ year: 1982, month: 5, day: 25}).toISODate() //=> '1982-05-25'
   * @example DateTime.fromObject({ year: 1982 }).toISODate() //=> '1982-01-01'
   * @example DateTime.fromObject({ hour: 10, minute: 26, second: 6 }) //~> today at 10:26:06
   * @example DateTime.fromObject({ hour: 10, minute: 26, second: 6, zone: 'utc' }),
   * @example DateTime.fromObject({ hour: 10, minute: 26, second: 6, zone: 'local' })
   * @example DateTime.fromObject({ hour: 10, minute: 26, second: 6, zone: 'America/New_York' })
   * @example DateTime.fromObject({ weekYear: 2016, weekNumber: 2, weekday: 3 }).toISODate() //=> '2016-01-13'
   * @return {DateTime}
   */
  ;

  DateTime.fromObject = function fromObject(obj) {
    var zoneToUse = normalizeZone(obj.zone, Settings.defaultZone);

    if (!zoneToUse.isValid) {
      return DateTime.invalid(unsupportedZone(zoneToUse));
    }

    var tsNow = Settings.now(),
        offsetProvis = zoneToUse.offset(tsNow),
        normalized = normalizeObject(obj, normalizeUnit, ["zone", "locale", "outputCalendar", "numberingSystem"]),
        containsOrdinal = !isUndefined(normalized.ordinal),
        containsGregorYear = !isUndefined(normalized.year),
        containsGregorMD = !isUndefined(normalized.month) || !isUndefined(normalized.day),
        containsGregor = containsGregorYear || containsGregorMD,
        definiteWeekDef = normalized.weekYear || normalized.weekNumber,
        loc = Locale.fromObject(obj); // cases:
    // just a weekday -> this week's instance of that weekday, no worries
    // (gregorian data or ordinal) + (weekYear or weekNumber) -> error
    // (gregorian month or day) + ordinal -> error
    // otherwise just use weeks or ordinals or gregorian, depending on what's specified

    if ((containsGregor || containsOrdinal) && definiteWeekDef) {
      throw new ConflictingSpecificationError("Can't mix weekYear/weekNumber units with year/month/day or ordinals");
    }

    if (containsGregorMD && containsOrdinal) {
      throw new ConflictingSpecificationError("Can't mix ordinal dates with month/day");
    }

    var useWeekData = definiteWeekDef || normalized.weekday && !containsGregor; // configure ourselves to deal with gregorian dates or week stuff

    var units,
        defaultValues,
        objNow = tsToObj(tsNow, offsetProvis);

    if (useWeekData) {
      units = orderedWeekUnits;
      defaultValues = defaultWeekUnitValues;
      objNow = gregorianToWeek(objNow);
    } else if (containsOrdinal) {
      units = orderedOrdinalUnits;
      defaultValues = defaultOrdinalUnitValues;
      objNow = gregorianToOrdinal(objNow);
    } else {
      units = orderedUnits$1;
      defaultValues = defaultUnitValues;
    } // set default values for missing stuff


    var foundFirst = false;

    for (var _iterator3 = _createForOfIteratorHelperLoose(units), _step3; !(_step3 = _iterator3()).done;) {
      var u = _step3.value;
      var v = normalized[u];

      if (!isUndefined(v)) {
        foundFirst = true;
      } else if (foundFirst) {
        normalized[u] = defaultValues[u];
      } else {
        normalized[u] = objNow[u];
      }
    } // make sure the values we have are in range


    var higherOrderInvalid = useWeekData ? hasInvalidWeekData(normalized) : containsOrdinal ? hasInvalidOrdinalData(normalized) : hasInvalidGregorianData(normalized),
        invalid = higherOrderInvalid || hasInvalidTimeData(normalized);

    if (invalid) {
      return DateTime.invalid(invalid);
    } // compute the actual time


    var gregorian = useWeekData ? weekToGregorian(normalized) : containsOrdinal ? ordinalToGregorian(normalized) : normalized,
        _objToTS2 = objToTS(gregorian, offsetProvis, zoneToUse),
        tsFinal = _objToTS2[0],
        offsetFinal = _objToTS2[1],
        inst = new DateTime({
      ts: tsFinal,
      zone: zoneToUse,
      o: offsetFinal,
      loc: loc
    }); // gregorian data + weekday serves only to validate


    if (normalized.weekday && containsGregor && obj.weekday !== inst.weekday) {
      return DateTime.invalid("mismatched weekday", "you can't specify both a weekday of " + normalized.weekday + " and a date of " + inst.toISO());
    }

    return inst;
  }
  /**
   * Create a DateTime from an ISO 8601 string
   * @param {string} text - the ISO string
   * @param {Object} opts - options to affect the creation
   * @param {string|Zone} [opts.zone='local'] - use this zone if no offset is specified in the input string itself. Will also convert the time to this zone
   * @param {boolean} [opts.setZone=false] - override the zone with a fixed-offset zone specified in the string itself, if it specifies one
   * @param {string} [opts.locale='system's locale'] - a locale to set on the resulting DateTime instance
   * @param {string} opts.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @param {string} opts.numberingSystem - the numbering system to set on the resulting DateTime instance
   * @example DateTime.fromISO('2016-05-25T09:08:34.123')
   * @example DateTime.fromISO('2016-05-25T09:08:34.123+06:00')
   * @example DateTime.fromISO('2016-05-25T09:08:34.123+06:00', {setZone: true})
   * @example DateTime.fromISO('2016-05-25T09:08:34.123', {zone: 'utc'})
   * @example DateTime.fromISO('2016-W05-4')
   * @return {DateTime}
   */
  ;

  DateTime.fromISO = function fromISO(text, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var _parseISODate = parseISODate(text),
        vals = _parseISODate[0],
        parsedZone = _parseISODate[1];

    return parseDataToDateTime(vals, parsedZone, opts, "ISO 8601", text);
  }
  /**
   * Create a DateTime from an RFC 2822 string
   * @param {string} text - the RFC 2822 string
   * @param {Object} opts - options to affect the creation
   * @param {string|Zone} [opts.zone='local'] - convert the time to this zone. Since the offset is always specified in the string itself, this has no effect on the interpretation of string, merely the zone the resulting DateTime is expressed in.
   * @param {boolean} [opts.setZone=false] - override the zone with a fixed-offset zone specified in the string itself, if it specifies one
   * @param {string} [opts.locale='system's locale'] - a locale to set on the resulting DateTime instance
   * @param {string} opts.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @param {string} opts.numberingSystem - the numbering system to set on the resulting DateTime instance
   * @example DateTime.fromRFC2822('25 Nov 2016 13:23:12 GMT')
   * @example DateTime.fromRFC2822('Fri, 25 Nov 2016 13:23:12 +0600')
   * @example DateTime.fromRFC2822('25 Nov 2016 13:23 Z')
   * @return {DateTime}
   */
  ;

  DateTime.fromRFC2822 = function fromRFC2822(text, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var _parseRFC2822Date = parseRFC2822Date(text),
        vals = _parseRFC2822Date[0],
        parsedZone = _parseRFC2822Date[1];

    return parseDataToDateTime(vals, parsedZone, opts, "RFC 2822", text);
  }
  /**
   * Create a DateTime from an HTTP header date
   * @see https://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.3.1
   * @param {string} text - the HTTP header date
   * @param {Object} opts - options to affect the creation
   * @param {string|Zone} [opts.zone='local'] - convert the time to this zone. Since HTTP dates are always in UTC, this has no effect on the interpretation of string, merely the zone the resulting DateTime is expressed in.
   * @param {boolean} [opts.setZone=false] - override the zone with the fixed-offset zone specified in the string. For HTTP dates, this is always UTC, so this option is equivalent to setting the `zone` option to 'utc', but this option is included for consistency with similar methods.
   * @param {string} [opts.locale='system's locale'] - a locale to set on the resulting DateTime instance
   * @param {string} opts.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @param {string} opts.numberingSystem - the numbering system to set on the resulting DateTime instance
   * @example DateTime.fromHTTP('Sun, 06 Nov 1994 08:49:37 GMT')
   * @example DateTime.fromHTTP('Sunday, 06-Nov-94 08:49:37 GMT')
   * @example DateTime.fromHTTP('Sun Nov  6 08:49:37 1994')
   * @return {DateTime}
   */
  ;

  DateTime.fromHTTP = function fromHTTP(text, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var _parseHTTPDate = parseHTTPDate(text),
        vals = _parseHTTPDate[0],
        parsedZone = _parseHTTPDate[1];

    return parseDataToDateTime(vals, parsedZone, opts, "HTTP", opts);
  }
  /**
   * Create a DateTime from an input string and format string.
   * Defaults to en-US if no locale has been specified, regardless of the system's locale.
   * @see https://moment.github.io/luxon/docs/manual/parsing.html#table-of-tokens
   * @param {string} text - the string to parse
   * @param {string} fmt - the format the string is expected to be in (see the link below for the formats)
   * @param {Object} opts - options to affect the creation
   * @param {string|Zone} [opts.zone='local'] - use this zone if no offset is specified in the input string itself. Will also convert the DateTime to this zone
   * @param {boolean} [opts.setZone=false] - override the zone with a zone specified in the string itself, if it specifies one
   * @param {string} [opts.locale='en-US'] - a locale string to use when parsing. Will also set the DateTime to this locale
   * @param {string} opts.numberingSystem - the numbering system to use when parsing. Will also set the resulting DateTime to this numbering system
   * @param {string} opts.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @return {DateTime}
   */
  ;

  DateTime.fromFormat = function fromFormat(text, fmt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    if (isUndefined(text) || isUndefined(fmt)) {
      throw new InvalidArgumentError("fromFormat requires an input string and a format");
    }

    var _opts = opts,
        _opts$locale = _opts.locale,
        locale = _opts$locale === void 0 ? null : _opts$locale,
        _opts$numberingSystem = _opts.numberingSystem,
        numberingSystem = _opts$numberingSystem === void 0 ? null : _opts$numberingSystem,
        localeToUse = Locale.fromOpts({
      locale: locale,
      numberingSystem: numberingSystem,
      defaultToEN: true
    }),
        _parseFromTokens = parseFromTokens(localeToUse, text, fmt),
        vals = _parseFromTokens[0],
        parsedZone = _parseFromTokens[1],
        invalid = _parseFromTokens[2];

    if (invalid) {
      return DateTime.invalid(invalid);
    } else {
      return parseDataToDateTime(vals, parsedZone, opts, "format " + fmt, text);
    }
  }
  /**
   * @deprecated use fromFormat instead
   */
  ;

  DateTime.fromString = function fromString(text, fmt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    return DateTime.fromFormat(text, fmt, opts);
  }
  /**
   * Create a DateTime from a SQL date, time, or datetime
   * Defaults to en-US if no locale has been specified, regardless of the system's locale
   * @param {string} text - the string to parse
   * @param {Object} opts - options to affect the creation
   * @param {string|Zone} [opts.zone='local'] - use this zone if no offset is specified in the input string itself. Will also convert the DateTime to this zone
   * @param {boolean} [opts.setZone=false] - override the zone with a zone specified in the string itself, if it specifies one
   * @param {string} [opts.locale='en-US'] - a locale string to use when parsing. Will also set the DateTime to this locale
   * @param {string} opts.numberingSystem - the numbering system to use when parsing. Will also set the resulting DateTime to this numbering system
   * @param {string} opts.outputCalendar - the output calendar to set on the resulting DateTime instance
   * @example DateTime.fromSQL('2017-05-15')
   * @example DateTime.fromSQL('2017-05-15 09:12:34')
   * @example DateTime.fromSQL('2017-05-15 09:12:34.342')
   * @example DateTime.fromSQL('2017-05-15 09:12:34.342+06:00')
   * @example DateTime.fromSQL('2017-05-15 09:12:34.342 America/Los_Angeles')
   * @example DateTime.fromSQL('2017-05-15 09:12:34.342 America/Los_Angeles', { setZone: true })
   * @example DateTime.fromSQL('2017-05-15 09:12:34.342', { zone: 'America/Los_Angeles' })
   * @example DateTime.fromSQL('09:12:34.342')
   * @return {DateTime}
   */
  ;

  DateTime.fromSQL = function fromSQL(text, opts) {
    if (opts === void 0) {
      opts = {};
    }

    var _parseSQL = parseSQL(text),
        vals = _parseSQL[0],
        parsedZone = _parseSQL[1];

    return parseDataToDateTime(vals, parsedZone, opts, "SQL", text);
  }
  /**
   * Create an invalid DateTime.
   * @param {string} reason - simple string of why this DateTime is invalid. Should not contain parameters or anything else data-dependent
   * @param {string} [explanation=null] - longer explanation, may include parameters and other useful debugging information
   * @return {DateTime}
   */
  ;

  DateTime.invalid = function invalid(reason, explanation) {
    if (explanation === void 0) {
      explanation = null;
    }

    if (!reason) {
      throw new InvalidArgumentError("need to specify a reason the DateTime is invalid");
    }

    var invalid = reason instanceof Invalid ? reason : new Invalid(reason, explanation);

    if (Settings.throwOnInvalid) {
      throw new InvalidDateTimeError(invalid);
    } else {
      return new DateTime({
        invalid: invalid
      });
    }
  }
  /**
   * Check if an object is a DateTime. Works across context boundaries
   * @param {object} o
   * @return {boolean}
   */
  ;

  DateTime.isDateTime = function isDateTime(o) {
    return o && o.isLuxonDateTime || false;
  } // INFO

  /**
   * Get the value of unit.
   * @param {string} unit - a unit such as 'minute' or 'day'
   * @example DateTime.local(2017, 7, 4).get('month'); //=> 7
   * @example DateTime.local(2017, 7, 4).get('day'); //=> 4
   * @return {number}
   */
  ;

  var _proto = DateTime.prototype;

  _proto.get = function get(unit) {
    return this[unit];
  }
  /**
   * Returns whether the DateTime is valid. Invalid DateTimes occur when:
   * * The DateTime was created from invalid calendar information, such as the 13th month or February 30
   * * The DateTime was created by an operation on another invalid date
   * @type {boolean}
   */
  ;

  /**
   * Returns the resolved Intl options for this DateTime.
   * This is useful in understanding the behavior of formatting methods
   * @param {Object} opts - the same options as toLocaleString
   * @return {Object}
   */
  _proto.resolvedLocaleOpts = function resolvedLocaleOpts(opts) {
    if (opts === void 0) {
      opts = {};
    }

    var _Formatter$create$res = Formatter.create(this.loc.clone(opts), opts).resolvedOptions(this),
        locale = _Formatter$create$res.locale,
        numberingSystem = _Formatter$create$res.numberingSystem,
        calendar = _Formatter$create$res.calendar;

    return {
      locale: locale,
      numberingSystem: numberingSystem,
      outputCalendar: calendar
    };
  } // TRANSFORM

  /**
   * "Set" the DateTime's zone to UTC. Returns a newly-constructed DateTime.
   *
   * Equivalent to {@link setZone}('utc')
   * @param {number} [offset=0] - optionally, an offset from UTC in minutes
   * @param {Object} [opts={}] - options to pass to `setZone()`
   * @return {DateTime}
   */
  ;

  _proto.toUTC = function toUTC(offset, opts) {
    if (offset === void 0) {
      offset = 0;
    }

    if (opts === void 0) {
      opts = {};
    }

    return this.setZone(FixedOffsetZone.instance(offset), opts);
  }
  /**
   * "Set" the DateTime's zone to the host's local zone. Returns a newly-constructed DateTime.
   *
   * Equivalent to `setZone('local')`
   * @return {DateTime}
   */
  ;

  _proto.toLocal = function toLocal() {
    return this.setZone(Settings.defaultZone);
  }
  /**
   * "Set" the DateTime's zone to specified zone. Returns a newly-constructed DateTime.
   *
   * By default, the setter keeps the underlying time the same (as in, the same timestamp), but the new instance will report different local times and consider DSTs when making computations, as with {@link plus}. You may wish to use {@link toLocal} and {@link toUTC} which provide simple convenience wrappers for commonly used zones.
   * @param {string|Zone} [zone='local'] - a zone identifier. As a string, that can be any IANA zone supported by the host environment, or a fixed-offset name of the form 'UTC+3', or the strings 'local' or 'utc'. You may also supply an instance of a {@link Zone} class.
   * @param {Object} opts - options
   * @param {boolean} [opts.keepLocalTime=false] - If true, adjust the underlying time so that the local time stays the same, but in the target zone. You should rarely need this.
   * @return {DateTime}
   */
  ;

  _proto.setZone = function setZone(zone, _temp) {
    var _ref3 = _temp === void 0 ? {} : _temp,
        _ref3$keepLocalTime = _ref3.keepLocalTime,
        keepLocalTime = _ref3$keepLocalTime === void 0 ? false : _ref3$keepLocalTime,
        _ref3$keepCalendarTim = _ref3.keepCalendarTime,
        keepCalendarTime = _ref3$keepCalendarTim === void 0 ? false : _ref3$keepCalendarTim;

    zone = normalizeZone(zone, Settings.defaultZone);

    if (zone.equals(this.zone)) {
      return this;
    } else if (!zone.isValid) {
      return DateTime.invalid(unsupportedZone(zone));
    } else {
      var newTS = this.ts;

      if (keepLocalTime || keepCalendarTime) {
        var offsetGuess = zone.offset(this.ts);
        var asObj = this.toObject();

        var _objToTS3 = objToTS(asObj, offsetGuess, zone);

        newTS = _objToTS3[0];
      }

      return clone$1(this, {
        ts: newTS,
        zone: zone
      });
    }
  }
  /**
   * "Set" the locale, numberingSystem, or outputCalendar. Returns a newly-constructed DateTime.
   * @param {Object} properties - the properties to set
   * @example DateTime.local(2017, 5, 25).reconfigure({ locale: 'en-GB' })
   * @return {DateTime}
   */
  ;

  _proto.reconfigure = function reconfigure(_temp2) {
    var _ref4 = _temp2 === void 0 ? {} : _temp2,
        locale = _ref4.locale,
        numberingSystem = _ref4.numberingSystem,
        outputCalendar = _ref4.outputCalendar;

    var loc = this.loc.clone({
      locale: locale,
      numberingSystem: numberingSystem,
      outputCalendar: outputCalendar
    });
    return clone$1(this, {
      loc: loc
    });
  }
  /**
   * "Set" the locale. Returns a newly-constructed DateTime.
   * Just a convenient alias for reconfigure({ locale })
   * @example DateTime.local(2017, 5, 25).setLocale('en-GB')
   * @return {DateTime}
   */
  ;

  _proto.setLocale = function setLocale(locale) {
    return this.reconfigure({
      locale: locale
    });
  }
  /**
   * "Set" the values of specified units. Returns a newly-constructed DateTime.
   * You can only set units with this method; for "setting" metadata, see {@link reconfigure} and {@link setZone}.
   * @param {Object} values - a mapping of units to numbers
   * @example dt.set({ year: 2017 })
   * @example dt.set({ hour: 8, minute: 30 })
   * @example dt.set({ weekday: 5 })
   * @example dt.set({ year: 2005, ordinal: 234 })
   * @return {DateTime}
   */
  ;

  _proto.set = function set(values) {
    if (!this.isValid) return this;
    var normalized = normalizeObject(values, normalizeUnit, []),
        settingWeekStuff = !isUndefined(normalized.weekYear) || !isUndefined(normalized.weekNumber) || !isUndefined(normalized.weekday);
    var mixed;

    if (settingWeekStuff) {
      mixed = weekToGregorian(Object.assign(gregorianToWeek(this.c), normalized));
    } else if (!isUndefined(normalized.ordinal)) {
      mixed = ordinalToGregorian(Object.assign(gregorianToOrdinal(this.c), normalized));
    } else {
      mixed = Object.assign(this.toObject(), normalized); // if we didn't set the day but we ended up on an overflow date,
      // use the last day of the right month

      if (isUndefined(normalized.day)) {
        mixed.day = Math.min(daysInMonth(mixed.year, mixed.month), mixed.day);
      }
    }

    var _objToTS4 = objToTS(mixed, this.o, this.zone),
        ts = _objToTS4[0],
        o = _objToTS4[1];

    return clone$1(this, {
      ts: ts,
      o: o
    });
  }
  /**
   * Add a period of time to this DateTime and return the resulting DateTime
   *
   * Adding hours, minutes, seconds, or milliseconds increases the timestamp by the right number of milliseconds. Adding days, months, or years shifts the calendar, accounting for DSTs and leap years along the way. Thus, `dt.plus({ hours: 24 })` may result in a different time than `dt.plus({ days: 1 })` if there's a DST shift in between.
   * @param {Duration|Object|number} duration - The amount to add. Either a Luxon Duration, a number of milliseconds, the object argument to Duration.fromObject()
   * @example DateTime.local().plus(123) //~> in 123 milliseconds
   * @example DateTime.local().plus({ minutes: 15 }) //~> in 15 minutes
   * @example DateTime.local().plus({ days: 1 }) //~> this time tomorrow
   * @example DateTime.local().plus({ days: -1 }) //~> this time yesterday
   * @example DateTime.local().plus({ hours: 3, minutes: 13 }) //~> in 3 hr, 13 min
   * @example DateTime.local().plus(Duration.fromObject({ hours: 3, minutes: 13 })) //~> in 3 hr, 13 min
   * @return {DateTime}
   */
  ;

  _proto.plus = function plus(duration) {
    if (!this.isValid) return this;
    var dur = friendlyDuration(duration);
    return clone$1(this, adjustTime(this, dur));
  }
  /**
   * Subtract a period of time to this DateTime and return the resulting DateTime
   * See {@link plus}
   * @param {Duration|Object|number} duration - The amount to subtract. Either a Luxon Duration, a number of milliseconds, the object argument to Duration.fromObject()
   @return {DateTime}
  */
  ;

  _proto.minus = function minus(duration) {
    if (!this.isValid) return this;
    var dur = friendlyDuration(duration).negate();
    return clone$1(this, adjustTime(this, dur));
  }
  /**
   * "Set" this DateTime to the beginning of a unit of time.
   * @param {string} unit - The unit to go to the beginning of. Can be 'year', 'quarter', 'month', 'week', 'day', 'hour', 'minute', 'second', or 'millisecond'.
   * @example DateTime.local(2014, 3, 3).startOf('month').toISODate(); //=> '2014-03-01'
   * @example DateTime.local(2014, 3, 3).startOf('year').toISODate(); //=> '2014-01-01'
   * @example DateTime.local(2014, 3, 3, 5, 30).startOf('day').toISOTime(); //=> '00:00.000-05:00'
   * @example DateTime.local(2014, 3, 3, 5, 30).startOf('hour').toISOTime(); //=> '05:00:00.000-05:00'
   * @return {DateTime}
   */
  ;

  _proto.startOf = function startOf(unit) {
    if (!this.isValid) return this;
    var o = {},
        normalizedUnit = Duration.normalizeUnit(unit);

    switch (normalizedUnit) {
      case "years":
        o.month = 1;
      // falls through

      case "quarters":
      case "months":
        o.day = 1;
      // falls through

      case "weeks":
      case "days":
        o.hour = 0;
      // falls through

      case "hours":
        o.minute = 0;
      // falls through

      case "minutes":
        o.second = 0;
      // falls through

      case "seconds":
        o.millisecond = 0;
        break;
      // no default, invalid units throw in normalizeUnit()
    }

    if (normalizedUnit === "weeks") {
      o.weekday = 1;
    }

    if (normalizedUnit === "quarters") {
      var q = Math.ceil(this.month / 3);
      o.month = (q - 1) * 3 + 1;
    }

    return this.set(o);
  }
  /**
   * "Set" this DateTime to the end (meaning the last millisecond) of a unit of time
   * @param {string} unit - The unit to go to the end of. Can be 'year', 'month', 'day', 'hour', 'minute', 'second', or 'millisecond'.
   * @example DateTime.local(2014, 3, 3).endOf('month').toISO(); //=> '2014-03-31T23:59:59.999-05:00'
   * @example DateTime.local(2014, 3, 3).endOf('year').toISO(); //=> '2014-12-31T23:59:59.999-05:00'
   * @example DateTime.local(2014, 3, 3, 5, 30).endOf('day').toISO(); //=> '2014-03-03T23:59:59.999-05:00'
   * @example DateTime.local(2014, 3, 3, 5, 30).endOf('hour').toISO(); //=> '2014-03-03T05:59:59.999-05:00'
   * @return {DateTime}
   */
  ;

  _proto.endOf = function endOf(unit) {
    var _this$plus;

    return this.isValid ? this.plus((_this$plus = {}, _this$plus[unit] = 1, _this$plus)).startOf(unit).minus(1) : this;
  } // OUTPUT

  /**
   * Returns a string representation of this DateTime formatted according to the specified format string.
   * **You may not want this.** See {@link toLocaleString} for a more flexible formatting tool. For a table of tokens and their interpretations, see [here](https://moment.github.io/luxon/docs/manual/formatting.html#table-of-tokens).
   * Defaults to en-US if no locale has been specified, regardless of the system's locale.
   * @see https://moment.github.io/luxon/docs/manual/formatting.html#table-of-tokens
   * @param {string} fmt - the format string
   * @param {Object} opts - opts to override the configuration options
   * @example DateTime.local().toFormat('yyyy LLL dd') //=> '2017 Apr 22'
   * @example DateTime.local().setLocale('fr').toFormat('yyyy LLL dd') //=> '2017 avr. 22'
   * @example DateTime.local().toFormat('yyyy LLL dd', { locale: "fr" }) //=> '2017 avr. 22'
   * @example DateTime.local().toFormat("HH 'hours and' mm 'minutes'") //=> '20 hours and 55 minutes'
   * @return {string}
   */
  ;

  _proto.toFormat = function toFormat(fmt, opts) {
    if (opts === void 0) {
      opts = {};
    }

    return this.isValid ? Formatter.create(this.loc.redefaultToEN(opts)).formatDateTimeFromString(this, fmt) : INVALID$2;
  }
  /**
   * Returns a localized string representing this date. Accepts the same options as the Intl.DateTimeFormat constructor and any presets defined by Luxon, such as `DateTime.DATE_FULL` or `DateTime.TIME_SIMPLE`.
   * The exact behavior of this method is browser-specific, but in general it will return an appropriate representation
   * of the DateTime in the assigned locale.
   * Defaults to the system's locale if no locale has been specified
   * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat
   * @param opts {Object} - Intl.DateTimeFormat constructor options and configuration options
   * @example DateTime.local().toLocaleString(); //=> 4/20/2017
   * @example DateTime.local().setLocale('en-gb').toLocaleString(); //=> '20/04/2017'
   * @example DateTime.local().toLocaleString({ locale: 'en-gb' }); //=> '20/04/2017'
   * @example DateTime.local().toLocaleString(DateTime.DATE_FULL); //=> 'April 20, 2017'
   * @example DateTime.local().toLocaleString(DateTime.TIME_SIMPLE); //=> '11:32 AM'
   * @example DateTime.local().toLocaleString(DateTime.DATETIME_SHORT); //=> '4/20/2017, 11:32 AM'
   * @example DateTime.local().toLocaleString({ weekday: 'long', month: 'long', day: '2-digit' }); //=> 'Thursday, April 20'
   * @example DateTime.local().toLocaleString({ weekday: 'short', month: 'short', day: '2-digit', hour: '2-digit', minute: '2-digit' }); //=> 'Thu, Apr 20, 11:27 AM'
   * @example DateTime.local().toLocaleString({ hour: '2-digit', minute: '2-digit', hour12: false }); //=> '11:32'
   * @return {string}
   */
  ;

  _proto.toLocaleString = function toLocaleString(opts) {
    if (opts === void 0) {
      opts = DATE_SHORT;
    }

    return this.isValid ? Formatter.create(this.loc.clone(opts), opts).formatDateTime(this) : INVALID$2;
  }
  /**
   * Returns an array of format "parts", meaning individual tokens along with metadata. This is allows callers to post-process individual sections of the formatted output.
   * Defaults to the system's locale if no locale has been specified
   * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DateTimeFormat/formatToParts
   * @param opts {Object} - Intl.DateTimeFormat constructor options, same as `toLocaleString`.
   * @example DateTime.local().toLocaleParts(); //=> [
   *                                   //=>   { type: 'day', value: '25' },
   *                                   //=>   { type: 'literal', value: '/' },
   *                                   //=>   { type: 'month', value: '05' },
   *                                   //=>   { type: 'literal', value: '/' },
   *                                   //=>   { type: 'year', value: '1982' }
   *                                   //=> ]
   */
  ;

  _proto.toLocaleParts = function toLocaleParts(opts) {
    if (opts === void 0) {
      opts = {};
    }

    return this.isValid ? Formatter.create(this.loc.clone(opts), opts).formatDateTimeParts(this) : [];
  }
  /**
   * Returns an ISO 8601-compliant string representation of this DateTime
   * @param {Object} opts - options
   * @param {boolean} [opts.suppressMilliseconds=false] - exclude milliseconds from the format if they're 0
   * @param {boolean} [opts.suppressSeconds=false] - exclude seconds from the format if they're 0
   * @param {boolean} [opts.includeOffset=true] - include the offset, such as 'Z' or '-04:00'
   * @param {string} [opts.format='extended'] - choose between the basic and extended format
   * @example DateTime.utc(1982, 5, 25).toISO() //=> '1982-05-25T00:00:00.000Z'
   * @example DateTime.local().toISO() //=> '2017-04-22T20:47:05.335-04:00'
   * @example DateTime.local().toISO({ includeOffset: false }) //=> '2017-04-22T20:47:05.335'
   * @example DateTime.local().toISO({ format: 'basic' }) //=> '20170422T204705.335-0400'
   * @return {string}
   */
  ;

  _proto.toISO = function toISO(opts) {
    if (opts === void 0) {
      opts = {};
    }

    if (!this.isValid) {
      return null;
    }

    return this.toISODate(opts) + "T" + this.toISOTime(opts);
  }
  /**
   * Returns an ISO 8601-compliant string representation of this DateTime's date component
   * @param {Object} opts - options
   * @param {string} [opts.format='extended'] - choose between the basic and extended format
   * @example DateTime.utc(1982, 5, 25).toISODate() //=> '1982-05-25'
   * @example DateTime.utc(1982, 5, 25).toISODate({ format: 'basic' }) //=> '19820525'
   * @return {string}
   */
  ;

  _proto.toISODate = function toISODate(_temp3) {
    var _ref5 = _temp3 === void 0 ? {} : _temp3,
        _ref5$format = _ref5.format,
        format = _ref5$format === void 0 ? "extended" : _ref5$format;

    var fmt = format === "basic" ? "yyyyMMdd" : "yyyy-MM-dd";

    if (this.year > 9999) {
      fmt = "+" + fmt;
    }

    return toTechFormat(this, fmt);
  }
  /**
   * Returns an ISO 8601-compliant string representation of this DateTime's week date
   * @example DateTime.utc(1982, 5, 25).toISOWeekDate() //=> '1982-W21-2'
   * @return {string}
   */
  ;

  _proto.toISOWeekDate = function toISOWeekDate() {
    return toTechFormat(this, "kkkk-'W'WW-c");
  }
  /**
   * Returns an ISO 8601-compliant string representation of this DateTime's time component
   * @param {Object} opts - options
   * @param {boolean} [opts.suppressMilliseconds=false] - exclude milliseconds from the format if they're 0
   * @param {boolean} [opts.suppressSeconds=false] - exclude seconds from the format if they're 0
   * @param {boolean} [opts.includeOffset=true] - include the offset, such as 'Z' or '-04:00'
   * @param {string} [opts.format='extended'] - choose between the basic and extended format
   * @example DateTime.utc().set({ hour: 7, minute: 34 }).toISOTime() //=> '07:34:19.361Z'
   * @example DateTime.utc().set({ hour: 7, minute: 34, seconds: 0, milliseconds: 0 }).toISOTime({ suppressSeconds: true }) //=> '07:34Z'
   * @example DateTime.utc().set({ hour: 7, minute: 34 }).toISOTime({ format: 'basic' }) //=> '073419.361Z'
   * @return {string}
   */
  ;

  _proto.toISOTime = function toISOTime(_temp4) {
    var _ref6 = _temp4 === void 0 ? {} : _temp4,
        _ref6$suppressMillise = _ref6.suppressMilliseconds,
        suppressMilliseconds = _ref6$suppressMillise === void 0 ? false : _ref6$suppressMillise,
        _ref6$suppressSeconds = _ref6.suppressSeconds,
        suppressSeconds = _ref6$suppressSeconds === void 0 ? false : _ref6$suppressSeconds,
        _ref6$includeOffset = _ref6.includeOffset,
        includeOffset = _ref6$includeOffset === void 0 ? true : _ref6$includeOffset,
        _ref6$format = _ref6.format,
        format = _ref6$format === void 0 ? "extended" : _ref6$format;

    return toTechTimeFormat(this, {
      suppressSeconds: suppressSeconds,
      suppressMilliseconds: suppressMilliseconds,
      includeOffset: includeOffset,
      format: format
    });
  }
  /**
   * Returns an RFC 2822-compatible string representation of this DateTime, always in UTC
   * @example DateTime.utc(2014, 7, 13).toRFC2822() //=> 'Sun, 13 Jul 2014 00:00:00 +0000'
   * @example DateTime.local(2014, 7, 13).toRFC2822() //=> 'Sun, 13 Jul 2014 00:00:00 -0400'
   * @return {string}
   */
  ;

  _proto.toRFC2822 = function toRFC2822() {
    return toTechFormat(this, "EEE, dd LLL yyyy HH:mm:ss ZZZ", false);
  }
  /**
   * Returns a string representation of this DateTime appropriate for use in HTTP headers.
   * Specifically, the string conforms to RFC 1123.
   * @see https://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.3.1
   * @example DateTime.utc(2014, 7, 13).toHTTP() //=> 'Sun, 13 Jul 2014 00:00:00 GMT'
   * @example DateTime.utc(2014, 7, 13, 19).toHTTP() //=> 'Sun, 13 Jul 2014 19:00:00 GMT'
   * @return {string}
   */
  ;

  _proto.toHTTP = function toHTTP() {
    return toTechFormat(this.toUTC(), "EEE, dd LLL yyyy HH:mm:ss 'GMT'");
  }
  /**
   * Returns a string representation of this DateTime appropriate for use in SQL Date
   * @example DateTime.utc(2014, 7, 13).toSQLDate() //=> '2014-07-13'
   * @return {string}
   */
  ;

  _proto.toSQLDate = function toSQLDate() {
    return toTechFormat(this, "yyyy-MM-dd");
  }
  /**
   * Returns a string representation of this DateTime appropriate for use in SQL Time
   * @param {Object} opts - options
   * @param {boolean} [opts.includeZone=false] - include the zone, such as 'America/New_York'. Overrides includeOffset.
   * @param {boolean} [opts.includeOffset=true] - include the offset, such as 'Z' or '-04:00'
   * @example DateTime.utc().toSQL() //=> '05:15:16.345'
   * @example DateTime.local().toSQL() //=> '05:15:16.345 -04:00'
   * @example DateTime.local().toSQL({ includeOffset: false }) //=> '05:15:16.345'
   * @example DateTime.local().toSQL({ includeZone: false }) //=> '05:15:16.345 America/New_York'
   * @return {string}
   */
  ;

  _proto.toSQLTime = function toSQLTime(_temp5) {
    var _ref7 = _temp5 === void 0 ? {} : _temp5,
        _ref7$includeOffset = _ref7.includeOffset,
        includeOffset = _ref7$includeOffset === void 0 ? true : _ref7$includeOffset,
        _ref7$includeZone = _ref7.includeZone,
        includeZone = _ref7$includeZone === void 0 ? false : _ref7$includeZone;

    return toTechTimeFormat(this, {
      includeOffset: includeOffset,
      includeZone: includeZone,
      spaceZone: true
    });
  }
  /**
   * Returns a string representation of this DateTime appropriate for use in SQL DateTime
   * @param {Object} opts - options
   * @param {boolean} [opts.includeZone=false] - include the zone, such as 'America/New_York'. Overrides includeOffset.
   * @param {boolean} [opts.includeOffset=true] - include the offset, such as 'Z' or '-04:00'
   * @example DateTime.utc(2014, 7, 13).toSQL() //=> '2014-07-13 00:00:00.000 Z'
   * @example DateTime.local(2014, 7, 13).toSQL() //=> '2014-07-13 00:00:00.000 -04:00'
   * @example DateTime.local(2014, 7, 13).toSQL({ includeOffset: false }) //=> '2014-07-13 00:00:00.000'
   * @example DateTime.local(2014, 7, 13).toSQL({ includeZone: true }) //=> '2014-07-13 00:00:00.000 America/New_York'
   * @return {string}
   */
  ;

  _proto.toSQL = function toSQL(opts) {
    if (opts === void 0) {
      opts = {};
    }

    if (!this.isValid) {
      return null;
    }

    return this.toSQLDate() + " " + this.toSQLTime(opts);
  }
  /**
   * Returns a string representation of this DateTime appropriate for debugging
   * @return {string}
   */
  ;

  _proto.toString = function toString() {
    return this.isValid ? this.toISO() : INVALID$2;
  }
  /**
   * Returns the epoch milliseconds of this DateTime. Alias of {@link toMillis}
   * @return {number}
   */
  ;

  _proto.valueOf = function valueOf() {
    return this.toMillis();
  }
  /**
   * Returns the epoch milliseconds of this DateTime.
   * @return {number}
   */
  ;

  _proto.toMillis = function toMillis() {
    return this.isValid ? this.ts : NaN;
  }
  /**
   * Returns the epoch seconds of this DateTime.
   * @return {number}
   */
  ;

  _proto.toSeconds = function toSeconds() {
    return this.isValid ? this.ts / 1000 : NaN;
  }
  /**
   * Returns an ISO 8601 representation of this DateTime appropriate for use in JSON.
   * @return {string}
   */
  ;

  _proto.toJSON = function toJSON() {
    return this.toISO();
  }
  /**
   * Returns a BSON serializable equivalent to this DateTime.
   * @return {Date}
   */
  ;

  _proto.toBSON = function toBSON() {
    return this.toJSDate();
  }
  /**
   * Returns a Javascript object with this DateTime's year, month, day, and so on.
   * @param opts - options for generating the object
   * @param {boolean} [opts.includeConfig=false] - include configuration attributes in the output
   * @example DateTime.local().toObject() //=> { year: 2017, month: 4, day: 22, hour: 20, minute: 49, second: 42, millisecond: 268 }
   * @return {Object}
   */
  ;

  _proto.toObject = function toObject(opts) {
    if (opts === void 0) {
      opts = {};
    }

    if (!this.isValid) return {};
    var base = Object.assign({}, this.c);

    if (opts.includeConfig) {
      base.outputCalendar = this.outputCalendar;
      base.numberingSystem = this.loc.numberingSystem;
      base.locale = this.loc.locale;
    }

    return base;
  }
  /**
   * Returns a Javascript Date equivalent to this DateTime.
   * @return {Date}
   */
  ;

  _proto.toJSDate = function toJSDate() {
    return new Date(this.isValid ? this.ts : NaN);
  } // COMPARE

  /**
   * Return the difference between two DateTimes as a Duration.
   * @param {DateTime} otherDateTime - the DateTime to compare this one to
   * @param {string|string[]} [unit=['milliseconds']] - the unit or array of units (such as 'hours' or 'days') to include in the duration.
   * @param {Object} opts - options that affect the creation of the Duration
   * @param {string} [opts.conversionAccuracy='casual'] - the conversion system to use
   * @example
   * var i1 = DateTime.fromISO('1982-05-25T09:45'),
   *     i2 = DateTime.fromISO('1983-10-14T10:30');
   * i2.diff(i1).toObject() //=> { milliseconds: 43807500000 }
   * i2.diff(i1, 'hours').toObject() //=> { hours: 12168.75 }
   * i2.diff(i1, ['months', 'days']).toObject() //=> { months: 16, days: 19.03125 }
   * i2.diff(i1, ['months', 'days', 'hours']).toObject() //=> { months: 16, days: 19, hours: 0.75 }
   * @return {Duration}
   */
  ;

  _proto.diff = function diff(otherDateTime, unit, opts) {
    if (unit === void 0) {
      unit = "milliseconds";
    }

    if (opts === void 0) {
      opts = {};
    }

    if (!this.isValid || !otherDateTime.isValid) {
      return Duration.invalid(this.invalid || otherDateTime.invalid, "created by diffing an invalid DateTime");
    }

    var durOpts = Object.assign({
      locale: this.locale,
      numberingSystem: this.numberingSystem
    }, opts);

    var units = maybeArray(unit).map(Duration.normalizeUnit),
        otherIsLater = otherDateTime.valueOf() > this.valueOf(),
        earlier = otherIsLater ? this : otherDateTime,
        later = otherIsLater ? otherDateTime : this,
        diffed = _diff(earlier, later, units, durOpts);

    return otherIsLater ? diffed.negate() : diffed;
  }
  /**
   * Return the difference between this DateTime and right now.
   * See {@link diff}
   * @param {string|string[]} [unit=['milliseconds']] - the unit or units units (such as 'hours' or 'days') to include in the duration
   * @param {Object} opts - options that affect the creation of the Duration
   * @param {string} [opts.conversionAccuracy='casual'] - the conversion system to use
   * @return {Duration}
   */
  ;

  _proto.diffNow = function diffNow(unit, opts) {
    if (unit === void 0) {
      unit = "milliseconds";
    }

    if (opts === void 0) {
      opts = {};
    }

    return this.diff(DateTime.local(), unit, opts);
  }
  /**
   * Return an Interval spanning between this DateTime and another DateTime
   * @param {DateTime} otherDateTime - the other end point of the Interval
   * @return {Interval}
   */
  ;

  _proto.until = function until(otherDateTime) {
    return this.isValid ? Interval.fromDateTimes(this, otherDateTime) : this;
  }
  /**
   * Return whether this DateTime is in the same unit of time as another DateTime
   * @param {DateTime} otherDateTime - the other DateTime
   * @param {string} unit - the unit of time to check sameness on
   * @example DateTime.local().hasSame(otherDT, 'day'); //~> true if both the same calendar day
   * @return {boolean}
   */
  ;

  _proto.hasSame = function hasSame(otherDateTime, unit) {
    if (!this.isValid) return false;

    if (unit === "millisecond") {
      return this.valueOf() === otherDateTime.valueOf();
    } else {
      var inputMs = otherDateTime.valueOf();
      return this.startOf(unit) <= inputMs && inputMs <= this.endOf(unit);
    }
  }
  /**
   * Equality check
   * Two DateTimes are equal iff they represent the same millisecond, have the same zone and location, and are both valid.
   * To compare just the millisecond values, use `+dt1 === +dt2`.
   * @param {DateTime} other - the other DateTime
   * @return {boolean}
   */
  ;

  _proto.equals = function equals(other) {
    return this.isValid && other.isValid && this.valueOf() === other.valueOf() && this.zone.equals(other.zone) && this.loc.equals(other.loc);
  }
  /**
   * Returns a string representation of a this time relative to now, such as "in two days". Can only internationalize if your
   * platform supports Intl.RelativeTimeFormat. Rounds down by default.
   * @param {Object} options - options that affect the output
   * @param {DateTime} [options.base=DateTime.local()] - the DateTime to use as the basis to which this time is compared. Defaults to now.
   * @param {string} [options.style="long"] - the style of units, must be "long", "short", or "narrow"
   * @param {string} options.unit - use a specific unit; if omitted, the method will pick the unit. Use one of "years", "quarters", "months", "weeks", "days", "hours", "minutes", or "seconds"
   * @param {boolean} [options.round=true] - whether to round the numbers in the output.
   * @param {boolean} [options.padding=0] - padding in milliseconds. This allows you to round up the result if it fits inside the threshold. Don't use in combination with {round: false} because the decimal output will include the padding.
   * @param {string} options.locale - override the locale of this DateTime
   * @param {string} options.numberingSystem - override the numberingSystem of this DateTime. The Intl system may choose not to honor this
   * @example DateTime.local().plus({ days: 1 }).toRelative() //=> "in 1 day"
   * @example DateTime.local().setLocale("es").toRelative({ days: 1 }) //=> "dentro de 1 día"
   * @example DateTime.local().plus({ days: 1 }).toRelative({ locale: "fr" }) //=> "dans 23 heures"
   * @example DateTime.local().minus({ days: 2 }).toRelative() //=> "2 days ago"
   * @example DateTime.local().minus({ days: 2 }).toRelative({ unit: "hours" }) //=> "48 hours ago"
   * @example DateTime.local().minus({ hours: 36 }).toRelative({ round: false }) //=> "1.5 days ago"
   */
  ;

  _proto.toRelative = function toRelative(options) {
    if (options === void 0) {
      options = {};
    }

    if (!this.isValid) return null;
    var base = options.base || DateTime.fromObject({
      zone: this.zone
    }),
        padding = options.padding ? this < base ? -options.padding : options.padding : 0;
    return diffRelative(base, this.plus(padding), Object.assign(options, {
      numeric: "always",
      units: ["years", "months", "days", "hours", "minutes", "seconds"]
    }));
  }
  /**
   * Returns a string representation of this date relative to today, such as "yesterday" or "next month".
   * Only internationalizes on platforms that supports Intl.RelativeTimeFormat.
   * @param {Object} options - options that affect the output
   * @param {DateTime} [options.base=DateTime.local()] - the DateTime to use as the basis to which this time is compared. Defaults to now.
   * @param {string} options.locale - override the locale of this DateTime
   * @param {string} options.unit - use a specific unit; if omitted, the method will pick the unit. Use one of "years", "quarters", "months", "weeks", or "days"
   * @param {string} options.numberingSystem - override the numberingSystem of this DateTime. The Intl system may choose not to honor this
   * @example DateTime.local().plus({ days: 1 }).toRelativeCalendar() //=> "tomorrow"
   * @example DateTime.local().setLocale("es").plus({ days: 1 }).toRelative() //=> ""mañana"
   * @example DateTime.local().plus({ days: 1 }).toRelativeCalendar({ locale: "fr" }) //=> "demain"
   * @example DateTime.local().minus({ days: 2 }).toRelativeCalendar() //=> "2 days ago"
   */
  ;

  _proto.toRelativeCalendar = function toRelativeCalendar(options) {
    if (options === void 0) {
      options = {};
    }

    if (!this.isValid) return null;
    return diffRelative(options.base || DateTime.fromObject({
      zone: this.zone
    }), this, Object.assign(options, {
      numeric: "auto",
      units: ["years", "months", "days"],
      calendary: true
    }));
  }
  /**
   * Return the min of several date times
   * @param {...DateTime} dateTimes - the DateTimes from which to choose the minimum
   * @return {DateTime} the min DateTime, or undefined if called with no argument
   */
  ;

  DateTime.min = function min() {
    for (var _len = arguments.length, dateTimes = new Array(_len), _key = 0; _key < _len; _key++) {
      dateTimes[_key] = arguments[_key];
    }

    if (!dateTimes.every(DateTime.isDateTime)) {
      throw new InvalidArgumentError("min requires all arguments be DateTimes");
    }

    return bestBy(dateTimes, function (i) {
      return i.valueOf();
    }, Math.min);
  }
  /**
   * Return the max of several date times
   * @param {...DateTime} dateTimes - the DateTimes from which to choose the maximum
   * @return {DateTime} the max DateTime, or undefined if called with no argument
   */
  ;

  DateTime.max = function max() {
    for (var _len2 = arguments.length, dateTimes = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
      dateTimes[_key2] = arguments[_key2];
    }

    if (!dateTimes.every(DateTime.isDateTime)) {
      throw new InvalidArgumentError("max requires all arguments be DateTimes");
    }

    return bestBy(dateTimes, function (i) {
      return i.valueOf();
    }, Math.max);
  } // MISC

  /**
   * Explain how a string would be parsed by fromFormat()
   * @param {string} text - the string to parse
   * @param {string} fmt - the format the string is expected to be in (see description)
   * @param {Object} options - options taken by fromFormat()
   * @return {Object}
   */
  ;

  DateTime.fromFormatExplain = function fromFormatExplain(text, fmt, options) {
    if (options === void 0) {
      options = {};
    }

    var _options = options,
        _options$locale = _options.locale,
        locale = _options$locale === void 0 ? null : _options$locale,
        _options$numberingSys = _options.numberingSystem,
        numberingSystem = _options$numberingSys === void 0 ? null : _options$numberingSys,
        localeToUse = Locale.fromOpts({
      locale: locale,
      numberingSystem: numberingSystem,
      defaultToEN: true
    });
    return explainFromTokens(localeToUse, text, fmt);
  }
  /**
   * @deprecated use fromFormatExplain instead
   */
  ;

  DateTime.fromStringExplain = function fromStringExplain(text, fmt, options) {
    if (options === void 0) {
      options = {};
    }

    return DateTime.fromFormatExplain(text, fmt, options);
  } // FORMAT PRESETS

  /**
   * {@link toLocaleString} format like 10/14/1983
   * @type {Object}
   */
  ;

  _createClass(DateTime, [{
    key: "isValid",
    get: function get() {
      return this.invalid === null;
    }
    /**
     * Returns an error code if this DateTime is invalid, or null if the DateTime is valid
     * @type {string}
     */

  }, {
    key: "invalidReason",
    get: function get() {
      return this.invalid ? this.invalid.reason : null;
    }
    /**
     * Returns an explanation of why this DateTime became invalid, or null if the DateTime is valid
     * @type {string}
     */

  }, {
    key: "invalidExplanation",
    get: function get() {
      return this.invalid ? this.invalid.explanation : null;
    }
    /**
     * Get the locale of a DateTime, such 'en-GB'. The locale is used when formatting the DateTime
     *
     * @type {string}
     */

  }, {
    key: "locale",
    get: function get() {
      return this.isValid ? this.loc.locale : null;
    }
    /**
     * Get the numbering system of a DateTime, such 'beng'. The numbering system is used when formatting the DateTime
     *
     * @type {string}
     */

  }, {
    key: "numberingSystem",
    get: function get() {
      return this.isValid ? this.loc.numberingSystem : null;
    }
    /**
     * Get the output calendar of a DateTime, such 'islamic'. The output calendar is used when formatting the DateTime
     *
     * @type {string}
     */

  }, {
    key: "outputCalendar",
    get: function get() {
      return this.isValid ? this.loc.outputCalendar : null;
    }
    /**
     * Get the time zone associated with this DateTime.
     * @type {Zone}
     */

  }, {
    key: "zone",
    get: function get() {
      return this._zone;
    }
    /**
     * Get the name of the time zone.
     * @type {string}
     */

  }, {
    key: "zoneName",
    get: function get() {
      return this.isValid ? this.zone.name : null;
    }
    /**
     * Get the year
     * @example DateTime.local(2017, 5, 25).year //=> 2017
     * @type {number}
     */

  }, {
    key: "year",
    get: function get() {
      return this.isValid ? this.c.year : NaN;
    }
    /**
     * Get the quarter
     * @example DateTime.local(2017, 5, 25).quarter //=> 2
     * @type {number}
     */

  }, {
    key: "quarter",
    get: function get() {
      return this.isValid ? Math.ceil(this.c.month / 3) : NaN;
    }
    /**
     * Get the month (1-12).
     * @example DateTime.local(2017, 5, 25).month //=> 5
     * @type {number}
     */

  }, {
    key: "month",
    get: function get() {
      return this.isValid ? this.c.month : NaN;
    }
    /**
     * Get the day of the month (1-30ish).
     * @example DateTime.local(2017, 5, 25).day //=> 25
     * @type {number}
     */

  }, {
    key: "day",
    get: function get() {
      return this.isValid ? this.c.day : NaN;
    }
    /**
     * Get the hour of the day (0-23).
     * @example DateTime.local(2017, 5, 25, 9).hour //=> 9
     * @type {number}
     */

  }, {
    key: "hour",
    get: function get() {
      return this.isValid ? this.c.hour : NaN;
    }
    /**
     * Get the minute of the hour (0-59).
     * @example DateTime.local(2017, 5, 25, 9, 30).minute //=> 30
     * @type {number}
     */

  }, {
    key: "minute",
    get: function get() {
      return this.isValid ? this.c.minute : NaN;
    }
    /**
     * Get the second of the minute (0-59).
     * @example DateTime.local(2017, 5, 25, 9, 30, 52).second //=> 52
     * @type {number}
     */

  }, {
    key: "second",
    get: function get() {
      return this.isValid ? this.c.second : NaN;
    }
    /**
     * Get the millisecond of the second (0-999).
     * @example DateTime.local(2017, 5, 25, 9, 30, 52, 654).millisecond //=> 654
     * @type {number}
     */

  }, {
    key: "millisecond",
    get: function get() {
      return this.isValid ? this.c.millisecond : NaN;
    }
    /**
     * Get the week year
     * @see https://en.wikipedia.org/wiki/ISO_week_date
     * @example DateTime.local(2014, 11, 31).weekYear //=> 2015
     * @type {number}
     */

  }, {
    key: "weekYear",
    get: function get() {
      return this.isValid ? possiblyCachedWeekData(this).weekYear : NaN;
    }
    /**
     * Get the week number of the week year (1-52ish).
     * @see https://en.wikipedia.org/wiki/ISO_week_date
     * @example DateTime.local(2017, 5, 25).weekNumber //=> 21
     * @type {number}
     */

  }, {
    key: "weekNumber",
    get: function get() {
      return this.isValid ? possiblyCachedWeekData(this).weekNumber : NaN;
    }
    /**
     * Get the day of the week.
     * 1 is Monday and 7 is Sunday
     * @see https://en.wikipedia.org/wiki/ISO_week_date
     * @example DateTime.local(2014, 11, 31).weekday //=> 4
     * @type {number}
     */

  }, {
    key: "weekday",
    get: function get() {
      return this.isValid ? possiblyCachedWeekData(this).weekday : NaN;
    }
    /**
     * Get the ordinal (meaning the day of the year)
     * @example DateTime.local(2017, 5, 25).ordinal //=> 145
     * @type {number|DateTime}
     */

  }, {
    key: "ordinal",
    get: function get() {
      return this.isValid ? gregorianToOrdinal(this.c).ordinal : NaN;
    }
    /**
     * Get the human readable short month name, such as 'Oct'.
     * Defaults to the system's locale if no locale has been specified
     * @example DateTime.local(2017, 10, 30).monthShort //=> Oct
     * @type {string}
     */

  }, {
    key: "monthShort",
    get: function get() {
      return this.isValid ? Info.months("short", {
        locale: this.locale
      })[this.month - 1] : null;
    }
    /**
     * Get the human readable long month name, such as 'October'.
     * Defaults to the system's locale if no locale has been specified
     * @example DateTime.local(2017, 10, 30).monthLong //=> October
     * @type {string}
     */

  }, {
    key: "monthLong",
    get: function get() {
      return this.isValid ? Info.months("long", {
        locale: this.locale
      })[this.month - 1] : null;
    }
    /**
     * Get the human readable short weekday, such as 'Mon'.
     * Defaults to the system's locale if no locale has been specified
     * @example DateTime.local(2017, 10, 30).weekdayShort //=> Mon
     * @type {string}
     */

  }, {
    key: "weekdayShort",
    get: function get() {
      return this.isValid ? Info.weekdays("short", {
        locale: this.locale
      })[this.weekday - 1] : null;
    }
    /**
     * Get the human readable long weekday, such as 'Monday'.
     * Defaults to the system's locale if no locale has been specified
     * @example DateTime.local(2017, 10, 30).weekdayLong //=> Monday
     * @type {string}
     */

  }, {
    key: "weekdayLong",
    get: function get() {
      return this.isValid ? Info.weekdays("long", {
        locale: this.locale
      })[this.weekday - 1] : null;
    }
    /**
     * Get the UTC offset of this DateTime in minutes
     * @example DateTime.local().offset //=> -240
     * @example DateTime.utc().offset //=> 0
     * @type {number}
     */

  }, {
    key: "offset",
    get: function get() {
      return this.isValid ? +this.o : NaN;
    }
    /**
     * Get the short human name for the zone's current offset, for example "EST" or "EDT".
     * Defaults to the system's locale if no locale has been specified
     * @type {string}
     */

  }, {
    key: "offsetNameShort",
    get: function get() {
      if (this.isValid) {
        return this.zone.offsetName(this.ts, {
          format: "short",
          locale: this.locale
        });
      } else {
        return null;
      }
    }
    /**
     * Get the long human name for the zone's current offset, for example "Eastern Standard Time" or "Eastern Daylight Time".
     * Defaults to the system's locale if no locale has been specified
     * @type {string}
     */

  }, {
    key: "offsetNameLong",
    get: function get() {
      if (this.isValid) {
        return this.zone.offsetName(this.ts, {
          format: "long",
          locale: this.locale
        });
      } else {
        return null;
      }
    }
    /**
     * Get whether this zone's offset ever changes, as in a DST.
     * @type {boolean}
     */

  }, {
    key: "isOffsetFixed",
    get: function get() {
      return this.isValid ? this.zone.universal : null;
    }
    /**
     * Get whether the DateTime is in a DST.
     * @type {boolean}
     */

  }, {
    key: "isInDST",
    get: function get() {
      if (this.isOffsetFixed) {
        return false;
      } else {
        return this.offset > this.set({
          month: 1
        }).offset || this.offset > this.set({
          month: 5
        }).offset;
      }
    }
    /**
     * Returns true if this DateTime is in a leap year, false otherwise
     * @example DateTime.local(2016).isInLeapYear //=> true
     * @example DateTime.local(2013).isInLeapYear //=> false
     * @type {boolean}
     */

  }, {
    key: "isInLeapYear",
    get: function get() {
      return isLeapYear(this.year);
    }
    /**
     * Returns the number of days in this DateTime's month
     * @example DateTime.local(2016, 2).daysInMonth //=> 29
     * @example DateTime.local(2016, 3).daysInMonth //=> 31
     * @type {number}
     */

  }, {
    key: "daysInMonth",
    get: function get() {
      return daysInMonth(this.year, this.month);
    }
    /**
     * Returns the number of days in this DateTime's year
     * @example DateTime.local(2016).daysInYear //=> 366
     * @example DateTime.local(2013).daysInYear //=> 365
     * @type {number}
     */

  }, {
    key: "daysInYear",
    get: function get() {
      return this.isValid ? daysInYear(this.year) : NaN;
    }
    /**
     * Returns the number of weeks in this DateTime's year
     * @see https://en.wikipedia.org/wiki/ISO_week_date
     * @example DateTime.local(2004).weeksInWeekYear //=> 53
     * @example DateTime.local(2013).weeksInWeekYear //=> 52
     * @type {number}
     */

  }, {
    key: "weeksInWeekYear",
    get: function get() {
      return this.isValid ? weeksInWeekYear(this.weekYear) : NaN;
    }
  }], [{
    key: "DATE_SHORT",
    get: function get() {
      return DATE_SHORT;
    }
    /**
     * {@link toLocaleString} format like 'Oct 14, 1983'
     * @type {Object}
     */

  }, {
    key: "DATE_MED",
    get: function get() {
      return DATE_MED;
    }
    /**
     * {@link toLocaleString} format like 'October 14, 1983'
     * @type {Object}
     */

  }, {
    key: "DATE_FULL",
    get: function get() {
      return DATE_FULL;
    }
    /**
     * {@link toLocaleString} format like 'Tuesday, October 14, 1983'
     * @type {Object}
     */

  }, {
    key: "DATE_HUGE",
    get: function get() {
      return DATE_HUGE;
    }
    /**
     * {@link toLocaleString} format like '09:30 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "TIME_SIMPLE",
    get: function get() {
      return TIME_SIMPLE;
    }
    /**
     * {@link toLocaleString} format like '09:30:23 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "TIME_WITH_SECONDS",
    get: function get() {
      return TIME_WITH_SECONDS;
    }
    /**
     * {@link toLocaleString} format like '09:30:23 AM EDT'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "TIME_WITH_SHORT_OFFSET",
    get: function get() {
      return TIME_WITH_SHORT_OFFSET;
    }
    /**
     * {@link toLocaleString} format like '09:30:23 AM Eastern Daylight Time'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "TIME_WITH_LONG_OFFSET",
    get: function get() {
      return TIME_WITH_LONG_OFFSET;
    }
    /**
     * {@link toLocaleString} format like '09:30', always 24-hour.
     * @type {Object}
     */

  }, {
    key: "TIME_24_SIMPLE",
    get: function get() {
      return TIME_24_SIMPLE;
    }
    /**
     * {@link toLocaleString} format like '09:30:23', always 24-hour.
     * @type {Object}
     */

  }, {
    key: "TIME_24_WITH_SECONDS",
    get: function get() {
      return TIME_24_WITH_SECONDS;
    }
    /**
     * {@link toLocaleString} format like '09:30:23 EDT', always 24-hour.
     * @type {Object}
     */

  }, {
    key: "TIME_24_WITH_SHORT_OFFSET",
    get: function get() {
      return TIME_24_WITH_SHORT_OFFSET;
    }
    /**
     * {@link toLocaleString} format like '09:30:23 Eastern Daylight Time', always 24-hour.
     * @type {Object}
     */

  }, {
    key: "TIME_24_WITH_LONG_OFFSET",
    get: function get() {
      return TIME_24_WITH_LONG_OFFSET;
    }
    /**
     * {@link toLocaleString} format like '10/14/1983, 9:30 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_SHORT",
    get: function get() {
      return DATETIME_SHORT;
    }
    /**
     * {@link toLocaleString} format like '10/14/1983, 9:30:33 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_SHORT_WITH_SECONDS",
    get: function get() {
      return DATETIME_SHORT_WITH_SECONDS;
    }
    /**
     * {@link toLocaleString} format like 'Oct 14, 1983, 9:30 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_MED",
    get: function get() {
      return DATETIME_MED;
    }
    /**
     * {@link toLocaleString} format like 'Oct 14, 1983, 9:30:33 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_MED_WITH_SECONDS",
    get: function get() {
      return DATETIME_MED_WITH_SECONDS;
    }
    /**
     * {@link toLocaleString} format like 'Fri, 14 Oct 1983, 9:30 AM'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_MED_WITH_WEEKDAY",
    get: function get() {
      return DATETIME_MED_WITH_WEEKDAY;
    }
    /**
     * {@link toLocaleString} format like 'October 14, 1983, 9:30 AM EDT'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_FULL",
    get: function get() {
      return DATETIME_FULL;
    }
    /**
     * {@link toLocaleString} format like 'October 14, 1983, 9:30:33 AM EDT'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_FULL_WITH_SECONDS",
    get: function get() {
      return DATETIME_FULL_WITH_SECONDS;
    }
    /**
     * {@link toLocaleString} format like 'Friday, October 14, 1983, 9:30 AM Eastern Daylight Time'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_HUGE",
    get: function get() {
      return DATETIME_HUGE;
    }
    /**
     * {@link toLocaleString} format like 'Friday, October 14, 1983, 9:30:33 AM Eastern Daylight Time'. Only 12-hour if the locale is.
     * @type {Object}
     */

  }, {
    key: "DATETIME_HUGE_WITH_SECONDS",
    get: function get() {
      return DATETIME_HUGE_WITH_SECONDS;
    }
  }]);

  return DateTime;
}();
function friendlyDateTime(dateTimeish) {
  if (DateTime.isDateTime(dateTimeish)) {
    return dateTimeish;
  } else if (dateTimeish && dateTimeish.valueOf && isNumber(dateTimeish.valueOf())) {
    return DateTime.fromJSDate(dateTimeish);
  } else if (dateTimeish && typeof dateTimeish === "object") {
    return DateTime.fromObject(dateTimeish);
  } else {
    throw new InvalidArgumentError("Unknown datetime argument: " + dateTimeish + ", of type " + typeof dateTimeish);
  }
}

exports.DateTime = DateTime;
exports.Duration = Duration;
exports.FixedOffsetZone = FixedOffsetZone;
exports.IANAZone = IANAZone;
exports.Info = Info;
exports.Interval = Interval;
exports.InvalidZone = InvalidZone;
exports.LocalZone = LocalZone;
exports.Settings = Settings;
exports.Zone = Zone;
//# sourceMappingURL=luxon.js.map


/***/ }),
/* 177 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Count all elements in an object.
 *
 * @param {*} countable
 * @returns {number}
 */
function count(countable) {
    if (typeof countable === 'object') {
        if (Reflect.has(countable, 'length')) {
            return countable.length;
        }
        else if (Reflect.has(countable, 'size')) {
            return countable.size;
        }
        else {
            return Object.keys(countable).length;
        }
    }
    return 0;
}
exports.count = count;


/***/ }),
/* 178 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const iconvLite = __webpack_require__(416);
/**
 * Internationalization conversion: convert buffer to requested character encoding
 *
 * @param {string} inCharset The input charset.
 * @param {string} outCharset The output charset.
 * @param {Buffer} buffer The buffer to be converted.
 *
 * @returns {Buffer} the converted buffer or false on failure.
 */
function iconv(inCharset, outCharset, buffer) {
    let str = iconvLite.decode(buffer, inCharset);
    buffer = iconvLite.encode(str, outCharset);
    return buffer;
}
exports.iconv = iconv;


/***/ }),
/* 179 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"0\",\"\\u0000\",127,\"€\"],[\"8140\",\"丂丄丅丆丏丒丗丟丠両丣並丩丮丯丱丳丵丷丼乀乁乂乄乆乊乑乕乗乚乛乢乣乤乥乧乨乪\",5,\"乲乴\",9,\"乿\",6,\"亇亊\"],[\"8180\",\"亐亖亗亙亜亝亞亣亪亯亰亱亴亶亷亸亹亼亽亾仈仌仏仐仒仚仛仜仠仢仦仧仩仭仮仯仱仴仸仹仺仼仾伀伂\",6,\"伋伌伒\",4,\"伜伝伡伣伨伩伬伭伮伱伳伵伷伹伻伾\",4,\"佄佅佇\",5,\"佒佔佖佡佢佦佨佪佫佭佮佱佲併佷佸佹佺佽侀侁侂侅來侇侊侌侎侐侒侓侕侖侘侙侚侜侞侟価侢\"],[\"8240\",\"侤侫侭侰\",4,\"侶\",8,\"俀俁係俆俇俈俉俋俌俍俒\",4,\"俙俛俠俢俤俥俧俫俬俰俲俴俵俶俷俹俻俼俽俿\",11],[\"8280\",\"個倎倐們倓倕倖倗倛倝倞倠倢倣値倧倫倯\",10,\"倻倽倿偀偁偂偄偅偆偉偊偋偍偐\",4,\"偖偗偘偙偛偝\",7,\"偦\",5,\"偭\",8,\"偸偹偺偼偽傁傂傃傄傆傇傉傊傋傌傎\",20,\"傤傦傪傫傭\",4,\"傳\",6,\"傼\"],[\"8340\",\"傽\",17,\"僐\",5,\"僗僘僙僛\",10,\"僨僩僪僫僯僰僱僲僴僶\",4,\"僼\",9,\"儈\"],[\"8380\",\"儉儊儌\",5,\"儓\",13,\"儢\",28,\"兂兇兊兌兎兏児兒兓兗兘兙兛兝\",4,\"兣兤兦內兩兪兯兲兺兾兿冃冄円冇冊冋冎冏冐冑冓冔冘冚冝冞冟冡冣冦\",4,\"冭冮冴冸冹冺冾冿凁凂凃凅凈凊凍凎凐凒\",5],[\"8440\",\"凘凙凚凜凞凟凢凣凥\",5,\"凬凮凱凲凴凷凾刄刅刉刋刌刏刐刓刔刕刜刞刟刡刢刣別刦刧刪刬刯刱刲刴刵刼刾剄\",5,\"剋剎剏剒剓剕剗剘\"],[\"8480\",\"剙剚剛剝剟剠剢剣剤剦剨剫剬剭剮剰剱剳\",9,\"剾劀劃\",4,\"劉\",6,\"劑劒劔\",6,\"劜劤劥劦劧劮劯劰労\",9,\"勀勁勂勄勅勆勈勊勌勍勎勏勑勓勔動勗務\",5,\"勠勡勢勣勥\",10,\"勱\",7,\"勻勼勽匁匂匃匄匇匉匊匋匌匎\"],[\"8540\",\"匑匒匓匔匘匛匜匞匟匢匤匥匧匨匩匫匬匭匯\",9,\"匼匽區卂卄卆卋卌卍卐協単卙卛卝卥卨卪卬卭卲卶卹卻卼卽卾厀厁厃厇厈厊厎厏\"],[\"8580\",\"厐\",4,\"厖厗厙厛厜厞厠厡厤厧厪厫厬厭厯\",6,\"厷厸厹厺厼厽厾叀參\",4,\"収叏叐叒叓叕叚叜叝叞叡叢叧叴叺叾叿吀吂吅吇吋吔吘吙吚吜吢吤吥吪吰吳吶吷吺吽吿呁呂呄呅呇呉呌呍呎呏呑呚呝\",4,\"呣呥呧呩\",7,\"呴呹呺呾呿咁咃咅咇咈咉咊咍咑咓咗咘咜咞咟咠咡\"],[\"8640\",\"咢咥咮咰咲咵咶咷咹咺咼咾哃哅哊哋哖哘哛哠\",4,\"哫哬哯哰哱哴\",5,\"哻哾唀唂唃唄唅唈唊\",4,\"唒唓唕\",5,\"唜唝唞唟唡唥唦\"],[\"8680\",\"唨唩唫唭唲唴唵唶唸唹唺唻唽啀啂啅啇啈啋\",4,\"啑啒啓啔啗\",4,\"啝啞啟啠啢啣啨啩啫啯\",5,\"啹啺啽啿喅喆喌喍喎喐喒喓喕喖喗喚喛喞喠\",6,\"喨\",8,\"喲喴営喸喺喼喿\",4,\"嗆嗇嗈嗊嗋嗎嗏嗐嗕嗗\",4,\"嗞嗠嗢嗧嗩嗭嗮嗰嗱嗴嗶嗸\",4,\"嗿嘂嘃嘄嘅\"],[\"8740\",\"嘆嘇嘊嘋嘍嘐\",7,\"嘙嘚嘜嘝嘠嘡嘢嘥嘦嘨嘩嘪嘫嘮嘯嘰嘳嘵嘷嘸嘺嘼嘽嘾噀\",11,\"噏\",4,\"噕噖噚噛噝\",4],[\"8780\",\"噣噥噦噧噭噮噯噰噲噳噴噵噷噸噹噺噽\",7,\"嚇\",6,\"嚐嚑嚒嚔\",14,\"嚤\",10,\"嚰\",6,\"嚸嚹嚺嚻嚽\",12,\"囋\",8,\"囕囖囘囙囜団囥\",5,\"囬囮囯囲図囶囷囸囻囼圀圁圂圅圇國\",6],[\"8840\",\"園\",9,\"圝圞圠圡圢圤圥圦圧圫圱圲圴\",4,\"圼圽圿坁坃坄坅坆坈坉坋坒\",4,\"坘坙坢坣坥坧坬坮坰坱坲坴坵坸坹坺坽坾坿垀\"],[\"8880\",\"垁垇垈垉垊垍\",4,\"垔\",6,\"垜垝垞垟垥垨垪垬垯垰垱垳垵垶垷垹\",8,\"埄\",6,\"埌埍埐埑埓埖埗埛埜埞埡埢埣埥\",7,\"埮埰埱埲埳埵埶執埻埼埾埿堁堃堄堅堈堉堊堌堎堏堐堒堓堔堖堗堘堚堛堜堝堟堢堣堥\",4,\"堫\",4,\"報堲堳場堶\",7],[\"8940\",\"堾\",5,\"塅\",6,\"塎塏塐塒塓塕塖塗塙\",4,\"塟\",5,\"塦\",4,\"塭\",16,\"塿墂墄墆墇墈墊墋墌\"],[\"8980\",\"墍\",4,\"墔\",4,\"墛墜墝墠\",7,\"墪\",17,\"墽墾墿壀壂壃壄壆\",10,\"壒壓壔壖\",13,\"壥\",5,\"壭壯壱売壴壵壷壸壺\",7,\"夃夅夆夈\",4,\"夎夐夑夒夓夗夘夛夝夞夠夡夢夣夦夨夬夰夲夳夵夶夻\"],[\"8a40\",\"夽夾夿奀奃奅奆奊奌奍奐奒奓奙奛\",4,\"奡奣奤奦\",12,\"奵奷奺奻奼奾奿妀妅妉妋妌妎妏妐妑妔妕妘妚妛妜妝妟妠妡妢妦\"],[\"8a80\",\"妧妬妭妰妱妳\",5,\"妺妼妽妿\",6,\"姇姈姉姌姍姎姏姕姖姙姛姞\",4,\"姤姦姧姩姪姫姭\",11,\"姺姼姽姾娀娂娊娋娍娎娏娐娒娔娕娖娗娙娚娛娝娞娡娢娤娦娧娨娪\",6,\"娳娵娷\",4,\"娽娾娿婁\",4,\"婇婈婋\",9,\"婖婗婘婙婛\",5],[\"8b40\",\"婡婣婤婥婦婨婩婫\",8,\"婸婹婻婼婽婾媀\",17,\"媓\",6,\"媜\",13,\"媫媬\"],[\"8b80\",\"媭\",4,\"媴媶媷媹\",4,\"媿嫀嫃\",5,\"嫊嫋嫍\",4,\"嫓嫕嫗嫙嫚嫛嫝嫞嫟嫢嫤嫥嫧嫨嫪嫬\",4,\"嫲\",22,\"嬊\",11,\"嬘\",25,\"嬳嬵嬶嬸\",7,\"孁\",6],[\"8c40\",\"孈\",7,\"孒孖孞孠孡孧孨孫孭孮孯孲孴孶孷學孹孻孼孾孿宂宆宊宍宎宐宑宒宔宖実宧宨宩宬宭宮宯宱宲宷宺宻宼寀寁寃寈寉寊寋寍寎寏\"],[\"8c80\",\"寑寔\",8,\"寠寢寣實寧審\",4,\"寯寱\",6,\"寽対尀専尃尅將專尋尌對導尐尒尓尗尙尛尞尟尠尡尣尦尨尩尪尫尭尮尯尰尲尳尵尶尷屃屄屆屇屌屍屒屓屔屖屗屘屚屛屜屝屟屢層屧\",6,\"屰屲\",6,\"屻屼屽屾岀岃\",4,\"岉岊岋岎岏岒岓岕岝\",4,\"岤\",4],[\"8d40\",\"岪岮岯岰岲岴岶岹岺岻岼岾峀峂峃峅\",5,\"峌\",5,\"峓\",5,\"峚\",6,\"峢峣峧峩峫峬峮峯峱\",9,\"峼\",4],[\"8d80\",\"崁崄崅崈\",5,\"崏\",4,\"崕崗崘崙崚崜崝崟\",4,\"崥崨崪崫崬崯\",4,\"崵\",7,\"崿\",7,\"嵈嵉嵍\",10,\"嵙嵚嵜嵞\",10,\"嵪嵭嵮嵰嵱嵲嵳嵵\",12,\"嶃\",21,\"嶚嶛嶜嶞嶟嶠\"],[\"8e40\",\"嶡\",21,\"嶸\",12,\"巆\",6,\"巎\",12,\"巜巟巠巣巤巪巬巭\"],[\"8e80\",\"巰巵巶巸\",4,\"巿帀帄帇帉帊帋帍帎帒帓帗帞\",7,\"帨\",4,\"帯帰帲\",4,\"帹帺帾帿幀幁幃幆\",5,\"幍\",6,\"幖\",4,\"幜幝幟幠幣\",14,\"幵幷幹幾庁庂広庅庈庉庌庍庎庒庘庛庝庡庢庣庤庨\",4,\"庮\",4,\"庴庺庻庼庽庿\",6],[\"8f40\",\"廆廇廈廋\",5,\"廔廕廗廘廙廚廜\",11,\"廩廫\",8,\"廵廸廹廻廼廽弅弆弇弉弌弍弎弐弒弔弖弙弚弜弝弞弡弢弣弤\"],[\"8f80\",\"弨弫弬弮弰弲\",6,\"弻弽弾弿彁\",14,\"彑彔彙彚彛彜彞彟彠彣彥彧彨彫彮彯彲彴彵彶彸彺彽彾彿徃徆徍徎徏徑従徔徖徚徛徝從徟徠徢\",5,\"復徫徬徯\",5,\"徶徸徹徺徻徾\",4,\"忇忈忊忋忎忓忔忕忚忛応忞忟忢忣忥忦忨忩忬忯忰忲忳忴忶忷忹忺忼怇\"],[\"9040\",\"怈怉怋怌怐怑怓怗怘怚怞怟怢怣怤怬怭怮怰\",4,\"怶\",4,\"怽怾恀恄\",6,\"恌恎恏恑恓恔恖恗恘恛恜恞恟恠恡恥恦恮恱恲恴恵恷恾悀\"],[\"9080\",\"悁悂悅悆悇悈悊悋悎悏悐悑悓悕悗悘悙悜悞悡悢悤悥悧悩悪悮悰悳悵悶悷悹悺悽\",7,\"惇惈惉惌\",4,\"惒惓惔惖惗惙惛惞惡\",4,\"惪惱惲惵惷惸惻\",4,\"愂愃愄愅愇愊愋愌愐\",4,\"愖愗愘愙愛愜愝愞愡愢愥愨愩愪愬\",18,\"慀\",6],[\"9140\",\"慇慉態慍慏慐慒慓慔慖\",6,\"慞慟慠慡慣慤慥慦慩\",6,\"慱慲慳慴慶慸\",18,\"憌憍憏\",4,\"憕\"],[\"9180\",\"憖\",6,\"憞\",8,\"憪憫憭\",9,\"憸\",5,\"憿懀懁懃\",4,\"應懌\",4,\"懓懕\",16,\"懧\",13,\"懶\",8,\"戀\",5,\"戇戉戓戔戙戜戝戞戠戣戦戧戨戩戫戭戯戰戱戲戵戶戸\",4,\"扂扄扅扆扊\"],[\"9240\",\"扏扐払扖扗扙扚扜\",6,\"扤扥扨扱扲扴扵扷扸扺扻扽抁抂抃抅抆抇抈抋\",5,\"抔抙抜抝択抣抦抧抩抪抭抮抯抰抲抳抴抶抷抸抺抾拀拁\"],[\"9280\",\"拃拋拏拑拕拝拞拠拡拤拪拫拰拲拵拸拹拺拻挀挃挄挅挆挊挋挌挍挏挐挒挓挔挕挗挘挙挜挦挧挩挬挭挮挰挱挳\",5,\"挻挼挾挿捀捁捄捇捈捊捑捒捓捔捖\",7,\"捠捤捥捦捨捪捫捬捯捰捲捳捴捵捸捹捼捽捾捿掁掃掄掅掆掋掍掑掓掔掕掗掙\",6,\"採掤掦掫掯掱掲掵掶掹掻掽掿揀\"],[\"9340\",\"揁揂揃揅揇揈揊揋揌揑揓揔揕揗\",6,\"揟揢揤\",4,\"揫揬揮揯揰揱揳揵揷揹揺揻揼揾搃搄搆\",4,\"損搎搑搒搕\",5,\"搝搟搢搣搤\"],[\"9380\",\"搥搧搨搩搫搮\",5,\"搵\",4,\"搻搼搾摀摂摃摉摋\",6,\"摓摕摖摗摙\",4,\"摟\",7,\"摨摪摫摬摮\",9,\"摻\",6,\"撃撆撈\",8,\"撓撔撗撘撚撛撜撝撟\",4,\"撥撦撧撨撪撫撯撱撲撳撴撶撹撻撽撾撿擁擃擄擆\",6,\"擏擑擓擔擕擖擙據\"],[\"9440\",\"擛擜擝擟擠擡擣擥擧\",24,\"攁\",7,\"攊\",7,\"攓\",4,\"攙\",8],[\"9480\",\"攢攣攤攦\",4,\"攬攭攰攱攲攳攷攺攼攽敀\",4,\"敆敇敊敋敍敎敐敒敓敔敗敘敚敜敟敠敡敤敥敧敨敩敪敭敮敯敱敳敵敶數\",14,\"斈斉斊斍斎斏斒斔斕斖斘斚斝斞斠斢斣斦斨斪斬斮斱\",7,\"斺斻斾斿旀旂旇旈旉旊旍旐旑旓旔旕旘\",7,\"旡旣旤旪旫\"],[\"9540\",\"旲旳旴旵旸旹旻\",4,\"昁昄昅昇昈昉昋昍昐昑昒昖昗昘昚昛昜昞昡昢昣昤昦昩昪昫昬昮昰昲昳昷\",4,\"昽昿晀時晄\",6,\"晍晎晐晑晘\"],[\"9580\",\"晙晛晜晝晞晠晢晣晥晧晩\",4,\"晱晲晳晵晸晹晻晼晽晿暀暁暃暅暆暈暉暊暋暍暎暏暐暒暓暔暕暘\",4,\"暞\",8,\"暩\",4,\"暯\",4,\"暵暶暷暸暺暻暼暽暿\",25,\"曚曞\",7,\"曧曨曪\",5,\"曱曵曶書曺曻曽朁朂會\"],[\"9640\",\"朄朅朆朇朌朎朏朑朒朓朖朘朙朚朜朞朠\",5,\"朧朩朮朰朲朳朶朷朸朹朻朼朾朿杁杄杅杇杊杋杍杒杔杕杗\",4,\"杝杢杣杤杦杧杫杬杮東杴杶\"],[\"9680\",\"杸杹杺杻杽枀枂枃枅枆枈枊枌枍枎枏枑枒枓枔枖枙枛枟枠枡枤枦枩枬枮枱枲枴枹\",7,\"柂柅\",9,\"柕柖柗柛柟柡柣柤柦柧柨柪柫柭柮柲柵\",7,\"柾栁栂栃栄栆栍栐栒栔栕栘\",4,\"栞栟栠栢\",6,\"栫\",6,\"栴栵栶栺栻栿桇桋桍桏桒桖\",5],[\"9740\",\"桜桝桞桟桪桬\",7,\"桵桸\",8,\"梂梄梇\",7,\"梐梑梒梔梕梖梘\",9,\"梣梤梥梩梪梫梬梮梱梲梴梶梷梸\"],[\"9780\",\"梹\",6,\"棁棃\",5,\"棊棌棎棏棐棑棓棔棖棗棙棛\",4,\"棡棢棤\",9,\"棯棲棳棴棶棷棸棻棽棾棿椀椂椃椄椆\",4,\"椌椏椑椓\",11,\"椡椢椣椥\",7,\"椮椯椱椲椳椵椶椷椸椺椻椼椾楀楁楃\",16,\"楕楖楘楙楛楜楟\"],[\"9840\",\"楡楢楤楥楧楨楩楪楬業楯楰楲\",4,\"楺楻楽楾楿榁榃榅榊榋榌榎\",5,\"榖榗榙榚榝\",9,\"榩榪榬榮榯榰榲榳榵榶榸榹榺榼榽\"],[\"9880\",\"榾榿槀槂\",7,\"構槍槏槑槒槓槕\",5,\"槜槝槞槡\",11,\"槮槯槰槱槳\",9,\"槾樀\",9,\"樋\",11,\"標\",5,\"樠樢\",5,\"権樫樬樭樮樰樲樳樴樶\",6,\"樿\",4,\"橅橆橈\",7,\"橑\",6,\"橚\"],[\"9940\",\"橜\",4,\"橢橣橤橦\",10,\"橲\",6,\"橺橻橽橾橿檁檂檃檅\",8,\"檏檒\",4,\"檘\",7,\"檡\",5],[\"9980\",\"檧檨檪檭\",114,\"欥欦欨\",6],[\"9a40\",\"欯欰欱欳欴欵欶欸欻欼欽欿歀歁歂歄歅歈歊歋歍\",11,\"歚\",7,\"歨歩歫\",13,\"歺歽歾歿殀殅殈\"],[\"9a80\",\"殌殎殏殐殑殔殕殗殘殙殜\",4,\"殢\",7,\"殫\",7,\"殶殸\",6,\"毀毃毄毆\",4,\"毌毎毐毑毘毚毜\",4,\"毢\",7,\"毬毭毮毰毱毲毴毶毷毸毺毻毼毾\",6,\"氈\",4,\"氎氒気氜氝氞氠氣氥氫氬氭氱氳氶氷氹氺氻氼氾氿汃汄汅汈汋\",4,\"汑汒汓汖汘\"],[\"9b40\",\"汙汚汢汣汥汦汧汫\",4,\"汱汳汵汷汸決汻汼汿沀沄沇沊沋沍沎沑沒沕沖沗沘沚沜沝沞沠沢沨沬沯沰沴沵沶沷沺泀況泂泃泆泇泈泋泍泎泏泑泒泘\"],[\"9b80\",\"泙泚泜泝泟泤泦泧泩泬泭泲泴泹泿洀洂洃洅洆洈洉洊洍洏洐洑洓洔洕洖洘洜洝洟\",5,\"洦洨洩洬洭洯洰洴洶洷洸洺洿浀浂浄浉浌浐浕浖浗浘浛浝浟浡浢浤浥浧浨浫浬浭浰浱浲浳浵浶浹浺浻浽\",4,\"涃涄涆涇涊涋涍涏涐涒涖\",4,\"涜涢涥涬涭涰涱涳涴涶涷涹\",5,\"淁淂淃淈淉淊\"],[\"9c40\",\"淍淎淏淐淒淓淔淕淗淚淛淜淟淢淣淥淧淨淩淪淭淯淰淲淴淵淶淸淺淽\",7,\"渆渇済渉渋渏渒渓渕渘渙減渜渞渟渢渦渧渨渪測渮渰渱渳渵\"],[\"9c80\",\"渶渷渹渻\",7,\"湅\",7,\"湏湐湑湒湕湗湙湚湜湝湞湠\",10,\"湬湭湯\",14,\"満溁溂溄溇溈溊\",4,\"溑\",6,\"溙溚溛溝溞溠溡溣溤溦溨溩溫溬溭溮溰溳溵溸溹溼溾溿滀滃滄滅滆滈滉滊滌滍滎滐滒滖滘滙滛滜滝滣滧滪\",5],[\"9d40\",\"滰滱滲滳滵滶滷滸滺\",7,\"漃漄漅漇漈漊\",4,\"漐漑漒漖\",9,\"漡漢漣漥漦漧漨漬漮漰漲漴漵漷\",6,\"漿潀潁潂\"],[\"9d80\",\"潃潄潅潈潉潊潌潎\",9,\"潙潚潛潝潟潠潡潣潤潥潧\",5,\"潯潰潱潳潵潶潷潹潻潽\",6,\"澅澆澇澊澋澏\",12,\"澝澞澟澠澢\",4,\"澨\",10,\"澴澵澷澸澺\",5,\"濁濃\",5,\"濊\",6,\"濓\",10,\"濟濢濣濤濥\"],[\"9e40\",\"濦\",7,\"濰\",32,\"瀒\",7,\"瀜\",6,\"瀤\",6],[\"9e80\",\"瀫\",9,\"瀶瀷瀸瀺\",17,\"灍灎灐\",13,\"灟\",11,\"灮灱灲灳灴灷灹灺灻災炁炂炃炄炆炇炈炋炌炍炏炐炑炓炗炘炚炛炞\",12,\"炰炲炴炵炶為炾炿烄烅烆烇烉烋\",12,\"烚\"],[\"9f40\",\"烜烝烞烠烡烢烣烥烪烮烰\",6,\"烸烺烻烼烾\",10,\"焋\",4,\"焑焒焔焗焛\",10,\"焧\",7,\"焲焳焴\"],[\"9f80\",\"焵焷\",13,\"煆煇煈煉煋煍煏\",12,\"煝煟\",4,\"煥煩\",4,\"煯煰煱煴煵煶煷煹煻煼煾\",5,\"熅\",4,\"熋熌熍熎熐熑熒熓熕熖熗熚\",4,\"熡\",6,\"熩熪熫熭\",5,\"熴熶熷熸熺\",8,\"燄\",9,\"燏\",4],[\"a040\",\"燖\",9,\"燡燢燣燤燦燨\",5,\"燯\",9,\"燺\",11,\"爇\",19],[\"a080\",\"爛爜爞\",9,\"爩爫爭爮爯爲爳爴爺爼爾牀\",6,\"牉牊牋牎牏牐牑牓牔牕牗牘牚牜牞牠牣牤牥牨牪牫牬牭牰牱牳牴牶牷牸牻牼牽犂犃犅\",4,\"犌犎犐犑犓\",11,\"犠\",11,\"犮犱犲犳犵犺\",6,\"狅狆狇狉狊狋狌狏狑狓狔狕狖狘狚狛\"],[\"a1a1\",\"　、。·ˉˇ¨〃々—～‖…‘’“”〔〕〈\",7,\"〖〗【】±×÷∶∧∨∑∏∪∩∈∷√⊥∥∠⌒⊙∫∮≡≌≈∽∝≠≮≯≤≥∞∵∴♂♀°′″℃＄¤￠￡‰§№☆★○●◎◇◆□■△▲※→←↑↓〓\"],[\"a2a1\",\"ⅰ\",9],[\"a2b1\",\"⒈\",19,\"⑴\",19,\"①\",9],[\"a2e5\",\"㈠\",9],[\"a2f1\",\"Ⅰ\",11],[\"a3a1\",\"！＂＃￥％\",88,\"￣\"],[\"a4a1\",\"ぁ\",82],[\"a5a1\",\"ァ\",85],[\"a6a1\",\"Α\",16,\"Σ\",6],[\"a6c1\",\"α\",16,\"σ\",6],[\"a6e0\",\"︵︶︹︺︿﹀︽︾﹁﹂﹃﹄\"],[\"a6ee\",\"︻︼︷︸︱\"],[\"a6f4\",\"︳︴\"],[\"a7a1\",\"А\",5,\"ЁЖ\",25],[\"a7d1\",\"а\",5,\"ёж\",25],[\"a840\",\"ˊˋ˙–―‥‵℅℉↖↗↘↙∕∟∣≒≦≧⊿═\",35,\"▁\",6],[\"a880\",\"█\",7,\"▓▔▕▼▽◢◣◤◥☉⊕〒〝〞\"],[\"a8a1\",\"āáǎàēéěèīíǐìōóǒòūúǔùǖǘǚǜüêɑ\"],[\"a8bd\",\"ńň\"],[\"a8c0\",\"ɡ\"],[\"a8c5\",\"ㄅ\",36],[\"a940\",\"〡\",8,\"㊣㎎㎏㎜㎝㎞㎡㏄㏎㏑㏒㏕︰￢￤\"],[\"a959\",\"℡㈱\"],[\"a95c\",\"‐\"],[\"a960\",\"ー゛゜ヽヾ〆ゝゞ﹉\",9,\"﹔﹕﹖﹗﹙\",8],[\"a980\",\"﹢\",4,\"﹨﹩﹪﹫\"],[\"a996\",\"〇\"],[\"a9a4\",\"─\",75],[\"aa40\",\"狜狝狟狢\",5,\"狪狫狵狶狹狽狾狿猀猂猄\",5,\"猋猌猍猏猐猑猒猔猘猙猚猟猠猣猤猦猧猨猭猯猰猲猳猵猶猺猻猼猽獀\",8],[\"aa80\",\"獉獊獋獌獎獏獑獓獔獕獖獘\",7,\"獡\",10,\"獮獰獱\"],[\"ab40\",\"獲\",11,\"獿\",4,\"玅玆玈玊玌玍玏玐玒玓玔玕玗玘玙玚玜玝玞玠玡玣\",5,\"玪玬玭玱玴玵玶玸玹玼玽玾玿珁珃\",4],[\"ab80\",\"珋珌珎珒\",6,\"珚珛珜珝珟珡珢珣珤珦珨珪珫珬珮珯珰珱珳\",4],[\"ac40\",\"珸\",10,\"琄琇琈琋琌琍琎琑\",8,\"琜\",5,\"琣琤琧琩琫琭琯琱琲琷\",4,\"琽琾琿瑀瑂\",11],[\"ac80\",\"瑎\",6,\"瑖瑘瑝瑠\",12,\"瑮瑯瑱\",4,\"瑸瑹瑺\"],[\"ad40\",\"瑻瑼瑽瑿璂璄璅璆璈璉璊璌璍璏璑\",10,\"璝璟\",7,\"璪\",15,\"璻\",12],[\"ad80\",\"瓈\",9,\"瓓\",8,\"瓝瓟瓡瓥瓧\",6,\"瓰瓱瓲\"],[\"ae40\",\"瓳瓵瓸\",6,\"甀甁甂甃甅\",7,\"甎甐甒甔甕甖甗甛甝甞甠\",4,\"甦甧甪甮甴甶甹甼甽甿畁畂畃畄畆畇畉畊畍畐畑畒畓畕畖畗畘\"],[\"ae80\",\"畝\",7,\"畧畨畩畫\",6,\"畳畵當畷畺\",4,\"疀疁疂疄疅疇\"],[\"af40\",\"疈疉疊疌疍疎疐疓疕疘疛疜疞疢疦\",4,\"疭疶疷疺疻疿痀痁痆痋痌痎痏痐痑痓痗痙痚痜痝痟痠痡痥痩痬痭痮痯痲痳痵痶痷痸痺痻痽痾瘂瘄瘆瘇\"],[\"af80\",\"瘈瘉瘋瘍瘎瘏瘑瘒瘓瘔瘖瘚瘜瘝瘞瘡瘣瘧瘨瘬瘮瘯瘱瘲瘶瘷瘹瘺瘻瘽癁療癄\"],[\"b040\",\"癅\",6,\"癎\",5,\"癕癗\",4,\"癝癟癠癡癢癤\",6,\"癬癭癮癰\",7,\"癹発發癿皀皁皃皅皉皊皌皍皏皐皒皔皕皗皘皚皛\"],[\"b080\",\"皜\",7,\"皥\",8,\"皯皰皳皵\",9,\"盀盁盃啊阿埃挨哎唉哀皑癌蔼矮艾碍爱隘鞍氨安俺按暗岸胺案肮昂盎凹敖熬翱袄傲奥懊澳芭捌扒叭吧笆八疤巴拔跋靶把耙坝霸罢爸白柏百摆佰败拜稗斑班搬扳般颁板版扮拌伴瓣半办绊邦帮梆榜膀绑棒磅蚌镑傍谤苞胞包褒剥\"],[\"b140\",\"盄盇盉盋盌盓盕盙盚盜盝盞盠\",4,\"盦\",7,\"盰盳盵盶盷盺盻盽盿眀眂眃眅眆眊県眎\",10,\"眛眜眝眞眡眣眤眥眧眪眫\"],[\"b180\",\"眬眮眰\",4,\"眹眻眽眾眿睂睄睅睆睈\",7,\"睒\",7,\"睜薄雹保堡饱宝抱报暴豹鲍爆杯碑悲卑北辈背贝钡倍狈备惫焙被奔苯本笨崩绷甭泵蹦迸逼鼻比鄙笔彼碧蓖蔽毕毙毖币庇痹闭敝弊必辟壁臂避陛鞭边编贬扁便变卞辨辩辫遍标彪膘表鳖憋别瘪彬斌濒滨宾摈兵冰柄丙秉饼炳\"],[\"b240\",\"睝睞睟睠睤睧睩睪睭\",11,\"睺睻睼瞁瞂瞃瞆\",5,\"瞏瞐瞓\",11,\"瞡瞣瞤瞦瞨瞫瞭瞮瞯瞱瞲瞴瞶\",4],[\"b280\",\"瞼瞾矀\",12,\"矎\",8,\"矘矙矚矝\",4,\"矤病并玻菠播拨钵波博勃搏铂箔伯帛舶脖膊渤泊驳捕卜哺补埠不布步簿部怖擦猜裁材才财睬踩采彩菜蔡餐参蚕残惭惨灿苍舱仓沧藏操糙槽曹草厕策侧册测层蹭插叉茬茶查碴搽察岔差诧拆柴豺搀掺蝉馋谗缠铲产阐颤昌猖\"],[\"b340\",\"矦矨矪矯矰矱矲矴矵矷矹矺矻矼砃\",5,\"砊砋砎砏砐砓砕砙砛砞砠砡砢砤砨砪砫砮砯砱砲砳砵砶砽砿硁硂硃硄硆硈硉硊硋硍硏硑硓硔硘硙硚\"],[\"b380\",\"硛硜硞\",11,\"硯\",7,\"硸硹硺硻硽\",6,\"场尝常长偿肠厂敞畅唱倡超抄钞朝嘲潮巢吵炒车扯撤掣彻澈郴臣辰尘晨忱沉陈趁衬撑称城橙成呈乘程惩澄诚承逞骋秤吃痴持匙池迟弛驰耻齿侈尺赤翅斥炽充冲虫崇宠抽酬畴踌稠愁筹仇绸瞅丑臭初出橱厨躇锄雏滁除楚\"],[\"b440\",\"碄碅碆碈碊碋碏碐碒碔碕碖碙碝碞碠碢碤碦碨\",7,\"碵碶碷碸確碻碼碽碿磀磂磃磄磆磇磈磌磍磎磏磑磒磓磖磗磘磚\",9],[\"b480\",\"磤磥磦磧磩磪磫磭\",4,\"磳磵磶磸磹磻\",5,\"礂礃礄礆\",6,\"础储矗搐触处揣川穿椽传船喘串疮窗幢床闯创吹炊捶锤垂春椿醇唇淳纯蠢戳绰疵茨磁雌辞慈瓷词此刺赐次聪葱囱匆从丛凑粗醋簇促蹿篡窜摧崔催脆瘁粹淬翠村存寸磋撮搓措挫错搭达答瘩打大呆歹傣戴带殆代贷袋待逮\"],[\"b540\",\"礍\",5,\"礔\",9,\"礟\",4,\"礥\",14,\"礵\",4,\"礽礿祂祃祄祅祇祊\",8,\"祔祕祘祙祡祣\"],[\"b580\",\"祤祦祩祪祫祬祮祰\",6,\"祹祻\",4,\"禂禃禆禇禈禉禋禌禍禎禐禑禒怠耽担丹单郸掸胆旦氮但惮淡诞弹蛋当挡党荡档刀捣蹈倒岛祷导到稻悼道盗德得的蹬灯登等瞪凳邓堤低滴迪敌笛狄涤翟嫡抵底地蒂第帝弟递缔颠掂滇碘点典靛垫电佃甸店惦奠淀殿碉叼雕凋刁掉吊钓调跌爹碟蝶迭谍叠\"],[\"b640\",\"禓\",6,\"禛\",11,\"禨\",10,\"禴\",4,\"禼禿秂秄秅秇秈秊秌秎秏秐秓秔秖秗秙\",5,\"秠秡秢秥秨秪\"],[\"b680\",\"秬秮秱\",6,\"秹秺秼秾秿稁稄稅稇稈稉稊稌稏\",4,\"稕稖稘稙稛稜丁盯叮钉顶鼎锭定订丢东冬董懂动栋侗恫冻洞兜抖斗陡豆逗痘都督毒犊独读堵睹赌杜镀肚度渡妒端短锻段断缎堆兑队对墩吨蹲敦顿囤钝盾遁掇哆多夺垛躲朵跺舵剁惰堕蛾峨鹅俄额讹娥恶厄扼遏鄂饿恩而儿耳尔饵洱二\"],[\"b740\",\"稝稟稡稢稤\",14,\"稴稵稶稸稺稾穀\",5,\"穇\",9,\"穒\",4,\"穘\",16],[\"b780\",\"穩\",6,\"穱穲穳穵穻穼穽穾窂窅窇窉窊窋窌窎窏窐窓窔窙窚窛窞窡窢贰发罚筏伐乏阀法珐藩帆番翻樊矾钒繁凡烦反返范贩犯饭泛坊芳方肪房防妨仿访纺放菲非啡飞肥匪诽吠肺废沸费芬酚吩氛分纷坟焚汾粉奋份忿愤粪丰封枫蜂峰锋风疯烽逢冯缝讽奉凤佛否夫敷肤孵扶拂辐幅氟符伏俘服\"],[\"b840\",\"窣窤窧窩窪窫窮\",4,\"窴\",10,\"竀\",10,\"竌\",9,\"竗竘竚竛竜竝竡竢竤竧\",5,\"竮竰竱竲竳\"],[\"b880\",\"竴\",4,\"竻竼竾笀笁笂笅笇笉笌笍笎笐笒笓笖笗笘笚笜笝笟笡笢笣笧笩笭浮涪福袱弗甫抚辅俯釜斧脯腑府腐赴副覆赋复傅付阜父腹负富讣附妇缚咐噶嘎该改概钙盖溉干甘杆柑竿肝赶感秆敢赣冈刚钢缸肛纲岗港杠篙皋高膏羔糕搞镐稿告哥歌搁戈鸽胳疙割革葛格蛤阁隔铬个各给根跟耕更庚羹\"],[\"b940\",\"笯笰笲笴笵笶笷笹笻笽笿\",5,\"筆筈筊筍筎筓筕筗筙筜筞筟筡筣\",10,\"筯筰筳筴筶筸筺筼筽筿箁箂箃箄箆\",6,\"箎箏\"],[\"b980\",\"箑箒箓箖箘箙箚箛箞箟箠箣箤箥箮箯箰箲箳箵箶箷箹\",7,\"篂篃範埂耿梗工攻功恭龚供躬公宫弓巩汞拱贡共钩勾沟苟狗垢构购够辜菇咕箍估沽孤姑鼓古蛊骨谷股故顾固雇刮瓜剐寡挂褂乖拐怪棺关官冠观管馆罐惯灌贯光广逛瑰规圭硅归龟闺轨鬼诡癸桂柜跪贵刽辊滚棍锅郭国果裹过哈\"],[\"ba40\",\"篅篈築篊篋篍篎篏篐篒篔\",4,\"篛篜篞篟篠篢篣篤篧篨篩篫篬篭篯篰篲\",4,\"篸篹篺篻篽篿\",7,\"簈簉簊簍簎簐\",5,\"簗簘簙\"],[\"ba80\",\"簚\",4,\"簠\",5,\"簨簩簫\",12,\"簹\",5,\"籂骸孩海氦亥害骇酣憨邯韩含涵寒函喊罕翰撼捍旱憾悍焊汗汉夯杭航壕嚎豪毫郝好耗号浩呵喝荷菏核禾和何合盒貉阂河涸赫褐鹤贺嘿黑痕很狠恨哼亨横衡恒轰哄烘虹鸿洪宏弘红喉侯猴吼厚候后呼乎忽瑚壶葫胡蝴狐糊湖\"],[\"bb40\",\"籃\",9,\"籎\",36,\"籵\",5,\"籾\",9],[\"bb80\",\"粈粊\",6,\"粓粔粖粙粚粛粠粡粣粦粧粨粩粫粬粭粯粰粴\",4,\"粺粻弧虎唬护互沪户花哗华猾滑画划化话槐徊怀淮坏欢环桓还缓换患唤痪豢焕涣宦幻荒慌黄磺蝗簧皇凰惶煌晃幌恍谎灰挥辉徽恢蛔回毁悔慧卉惠晦贿秽会烩汇讳诲绘荤昏婚魂浑混豁活伙火获或惑霍货祸击圾基机畸稽积箕\"],[\"bc40\",\"粿糀糂糃糄糆糉糋糎\",6,\"糘糚糛糝糞糡\",6,\"糩\",5,\"糰\",7,\"糹糺糼\",13,\"紋\",5],[\"bc80\",\"紑\",14,\"紡紣紤紥紦紨紩紪紬紭紮細\",6,\"肌饥迹激讥鸡姬绩缉吉极棘辑籍集及急疾汲即嫉级挤几脊己蓟技冀季伎祭剂悸济寄寂计记既忌际妓继纪嘉枷夹佳家加荚颊贾甲钾假稼价架驾嫁歼监坚尖笺间煎兼肩艰奸缄茧检柬碱硷拣捡简俭剪减荐槛鉴践贱见键箭件\"],[\"bd40\",\"紷\",54,\"絯\",7],[\"bd80\",\"絸\",32,\"健舰剑饯渐溅涧建僵姜将浆江疆蒋桨奖讲匠酱降蕉椒礁焦胶交郊浇骄娇嚼搅铰矫侥脚狡角饺缴绞剿教酵轿较叫窖揭接皆秸街阶截劫节桔杰捷睫竭洁结解姐戒藉芥界借介疥诫届巾筋斤金今津襟紧锦仅谨进靳晋禁近烬浸\"],[\"be40\",\"継\",12,\"綧\",6,\"綯\",42],[\"be80\",\"線\",32,\"尽劲荆兢茎睛晶鲸京惊精粳经井警景颈静境敬镜径痉靖竟竞净炯窘揪究纠玖韭久灸九酒厩救旧臼舅咎就疚鞠拘狙疽居驹菊局咀矩举沮聚拒据巨具距踞锯俱句惧炬剧捐鹃娟倦眷卷绢撅攫抉掘倔爵觉决诀绝均菌钧军君峻\"],[\"bf40\",\"緻\",62],[\"bf80\",\"縺縼\",4,\"繂\",4,\"繈\",21,\"俊竣浚郡骏喀咖卡咯开揩楷凯慨刊堪勘坎砍看康慷糠扛抗亢炕考拷烤靠坷苛柯棵磕颗科壳咳可渴克刻客课肯啃垦恳坑吭空恐孔控抠口扣寇枯哭窟苦酷库裤夸垮挎跨胯块筷侩快宽款匡筐狂框矿眶旷况亏盔岿窥葵奎魁傀\"],[\"c040\",\"繞\",35,\"纃\",23,\"纜纝纞\"],[\"c080\",\"纮纴纻纼绖绤绬绹缊缐缞缷缹缻\",6,\"罃罆\",9,\"罒罓馈愧溃坤昆捆困括扩廓阔垃拉喇蜡腊辣啦莱来赖蓝婪栏拦篮阑兰澜谰揽览懒缆烂滥琅榔狼廊郎朗浪捞劳牢老佬姥酪烙涝勒乐雷镭蕾磊累儡垒擂肋类泪棱楞冷厘梨犁黎篱狸离漓理李里鲤礼莉荔吏栗丽厉励砾历利傈例俐\"],[\"c140\",\"罖罙罛罜罝罞罠罣\",4,\"罫罬罭罯罰罳罵罶罷罸罺罻罼罽罿羀羂\",7,\"羋羍羏\",4,\"羕\",4,\"羛羜羠羢羣羥羦羨\",6,\"羱\"],[\"c180\",\"羳\",4,\"羺羻羾翀翂翃翄翆翇翈翉翋翍翏\",4,\"翖翗翙\",5,\"翢翣痢立粒沥隶力璃哩俩联莲连镰廉怜涟帘敛脸链恋炼练粮凉梁粱良两辆量晾亮谅撩聊僚疗燎寥辽潦了撂镣廖料列裂烈劣猎琳林磷霖临邻鳞淋凛赁吝拎玲菱零龄铃伶羚凌灵陵岭领另令溜琉榴硫馏留刘瘤流柳六龙聋咙笼窿\"],[\"c240\",\"翤翧翨翪翫翬翭翯翲翴\",6,\"翽翾翿耂耇耈耉耊耎耏耑耓耚耛耝耞耟耡耣耤耫\",5,\"耲耴耹耺耼耾聀聁聄聅聇聈聉聎聏聐聑聓聕聖聗\"],[\"c280\",\"聙聛\",13,\"聫\",5,\"聲\",11,\"隆垄拢陇楼娄搂篓漏陋芦卢颅庐炉掳卤虏鲁麓碌露路赂鹿潞禄录陆戮驴吕铝侣旅履屡缕虑氯律率滤绿峦挛孪滦卵乱掠略抡轮伦仑沦纶论萝螺罗逻锣箩骡裸落洛骆络妈麻玛码蚂马骂嘛吗埋买麦卖迈脉瞒馒蛮满蔓曼慢漫\"],[\"c340\",\"聾肁肂肅肈肊肍\",5,\"肔肕肗肙肞肣肦肧肨肬肰肳肵肶肸肹肻胅胇\",4,\"胏\",6,\"胘胟胠胢胣胦胮胵胷胹胻胾胿脀脁脃脄脅脇脈脋\"],[\"c380\",\"脌脕脗脙脛脜脝脟\",12,\"脭脮脰脳脴脵脷脹\",4,\"脿谩芒茫盲氓忙莽猫茅锚毛矛铆卯茂冒帽貌贸么玫枚梅酶霉煤没眉媒镁每美昧寐妹媚门闷们萌蒙檬盟锰猛梦孟眯醚靡糜迷谜弥米秘觅泌蜜密幂棉眠绵冕免勉娩缅面苗描瞄藐秒渺庙妙蔑灭民抿皿敏悯闽明螟鸣铭名命谬摸\"],[\"c440\",\"腀\",5,\"腇腉腍腎腏腒腖腗腘腛\",4,\"腡腢腣腤腦腨腪腫腬腯腲腳腵腶腷腸膁膃\",4,\"膉膋膌膍膎膐膒\",5,\"膙膚膞\",4,\"膤膥\"],[\"c480\",\"膧膩膫\",7,\"膴\",5,\"膼膽膾膿臄臅臇臈臉臋臍\",6,\"摹蘑模膜磨摩魔抹末莫墨默沫漠寞陌谋牟某拇牡亩姆母墓暮幕募慕木目睦牧穆拿哪呐钠那娜纳氖乃奶耐奈南男难囊挠脑恼闹淖呢馁内嫩能妮霓倪泥尼拟你匿腻逆溺蔫拈年碾撵捻念娘酿鸟尿捏聂孽啮镊镍涅您柠狞凝宁\"],[\"c540\",\"臔\",14,\"臤臥臦臨臩臫臮\",4,\"臵\",5,\"臽臿舃與\",4,\"舎舏舑舓舕\",5,\"舝舠舤舥舦舧舩舮舲舺舼舽舿\"],[\"c580\",\"艀艁艂艃艅艆艈艊艌艍艎艐\",7,\"艙艛艜艝艞艠\",7,\"艩拧泞牛扭钮纽脓浓农弄奴努怒女暖虐疟挪懦糯诺哦欧鸥殴藕呕偶沤啪趴爬帕怕琶拍排牌徘湃派攀潘盘磐盼畔判叛乓庞旁耪胖抛咆刨炮袍跑泡呸胚培裴赔陪配佩沛喷盆砰抨烹澎彭蓬棚硼篷膨朋鹏捧碰坯砒霹批披劈琵毗\"],[\"c640\",\"艪艫艬艭艱艵艶艷艸艻艼芀芁芃芅芆芇芉芌芐芓芔芕芖芚芛芞芠芢芣芧芲芵芶芺芻芼芿苀苂苃苅苆苉苐苖苙苚苝苢苧苨苩苪苬苭苮苰苲苳苵苶苸\"],[\"c680\",\"苺苼\",4,\"茊茋茍茐茒茓茖茘茙茝\",9,\"茩茪茮茰茲茷茻茽啤脾疲皮匹痞僻屁譬篇偏片骗飘漂瓢票撇瞥拼频贫品聘乒坪苹萍平凭瓶评屏坡泼颇婆破魄迫粕剖扑铺仆莆葡菩蒲埔朴圃普浦谱曝瀑期欺栖戚妻七凄漆柒沏其棋奇歧畦崎脐齐旗祈祁骑起岂乞企启契砌器气迄弃汽泣讫掐\"],[\"c740\",\"茾茿荁荂荄荅荈荊\",4,\"荓荕\",4,\"荝荢荰\",6,\"荹荺荾\",6,\"莇莈莊莋莌莍莏莐莑莔莕莖莗莙莚莝莟莡\",6,\"莬莭莮\"],[\"c780\",\"莯莵莻莾莿菂菃菄菆菈菉菋菍菎菐菑菒菓菕菗菙菚菛菞菢菣菤菦菧菨菫菬菭恰洽牵扦钎铅千迁签仟谦乾黔钱钳前潜遣浅谴堑嵌欠歉枪呛腔羌墙蔷强抢橇锹敲悄桥瞧乔侨巧鞘撬翘峭俏窍切茄且怯窃钦侵亲秦琴勤芹擒禽寝沁青轻氢倾卿清擎晴氰情顷请庆琼穷秋丘邱球求囚酋泅趋区蛆曲躯屈驱渠\"],[\"c840\",\"菮華菳\",4,\"菺菻菼菾菿萀萂萅萇萈萉萊萐萒\",5,\"萙萚萛萞\",5,\"萩\",7,\"萲\",5,\"萹萺萻萾\",7,\"葇葈葉\"],[\"c880\",\"葊\",6,\"葒\",4,\"葘葝葞葟葠葢葤\",4,\"葪葮葯葰葲葴葷葹葻葼取娶龋趣去圈颧权醛泉全痊拳犬券劝缺炔瘸却鹊榷确雀裙群然燃冉染瓤壤攘嚷让饶扰绕惹热壬仁人忍韧任认刃妊纫扔仍日戎茸蓉荣融熔溶容绒冗揉柔肉茹蠕儒孺如辱乳汝入褥软阮蕊瑞锐闰润若弱撒洒萨腮鳃塞赛三叁\"],[\"c940\",\"葽\",4,\"蒃蒄蒅蒆蒊蒍蒏\",7,\"蒘蒚蒛蒝蒞蒟蒠蒢\",12,\"蒰蒱蒳蒵蒶蒷蒻蒼蒾蓀蓂蓃蓅蓆蓇蓈蓋蓌蓎蓏蓒蓔蓕蓗\"],[\"c980\",\"蓘\",4,\"蓞蓡蓢蓤蓧\",4,\"蓭蓮蓯蓱\",10,\"蓽蓾蔀蔁蔂伞散桑嗓丧搔骚扫嫂瑟色涩森僧莎砂杀刹沙纱傻啥煞筛晒珊苫杉山删煽衫闪陕擅赡膳善汕扇缮墒伤商赏晌上尚裳梢捎稍烧芍勺韶少哨邵绍奢赊蛇舌舍赦摄射慑涉社设砷申呻伸身深娠绅神沈审婶甚肾慎渗声生甥牲升绳\"],[\"ca40\",\"蔃\",8,\"蔍蔎蔏蔐蔒蔔蔕蔖蔘蔙蔛蔜蔝蔞蔠蔢\",8,\"蔭\",9,\"蔾\",4,\"蕄蕅蕆蕇蕋\",10],[\"ca80\",\"蕗蕘蕚蕛蕜蕝蕟\",4,\"蕥蕦蕧蕩\",8,\"蕳蕵蕶蕷蕸蕼蕽蕿薀薁省盛剩胜圣师失狮施湿诗尸虱十石拾时什食蚀实识史矢使屎驶始式示士世柿事拭誓逝势是嗜噬适仕侍释饰氏市恃室视试收手首守寿授售受瘦兽蔬枢梳殊抒输叔舒淑疏书赎孰熟薯暑曙署蜀黍鼠属术述树束戍竖墅庶数漱\"],[\"cb40\",\"薂薃薆薈\",6,\"薐\",10,\"薝\",6,\"薥薦薧薩薫薬薭薱\",5,\"薸薺\",6,\"藂\",6,\"藊\",4,\"藑藒\"],[\"cb80\",\"藔藖\",5,\"藝\",6,\"藥藦藧藨藪\",14,\"恕刷耍摔衰甩帅栓拴霜双爽谁水睡税吮瞬顺舜说硕朔烁斯撕嘶思私司丝死肆寺嗣四伺似饲巳松耸怂颂送宋讼诵搜艘擞嗽苏酥俗素速粟僳塑溯宿诉肃酸蒜算虽隋随绥髓碎岁穗遂隧祟孙损笋蓑梭唆缩琐索锁所塌他它她塔\"],[\"cc40\",\"藹藺藼藽藾蘀\",4,\"蘆\",10,\"蘒蘓蘔蘕蘗\",15,\"蘨蘪\",13,\"蘹蘺蘻蘽蘾蘿虀\"],[\"cc80\",\"虁\",11,\"虒虓處\",4,\"虛虜虝號虠虡虣\",7,\"獭挞蹋踏胎苔抬台泰酞太态汰坍摊贪瘫滩坛檀痰潭谭谈坦毯袒碳探叹炭汤塘搪堂棠膛唐糖倘躺淌趟烫掏涛滔绦萄桃逃淘陶讨套特藤腾疼誊梯剔踢锑提题蹄啼体替嚏惕涕剃屉天添填田甜恬舔腆挑条迢眺跳贴铁帖厅听烃\"],[\"cd40\",\"虭虯虰虲\",6,\"蚃\",6,\"蚎\",4,\"蚔蚖\",5,\"蚞\",4,\"蚥蚦蚫蚭蚮蚲蚳蚷蚸蚹蚻\",4,\"蛁蛂蛃蛅蛈蛌蛍蛒蛓蛕蛖蛗蛚蛜\"],[\"cd80\",\"蛝蛠蛡蛢蛣蛥蛦蛧蛨蛪蛫蛬蛯蛵蛶蛷蛺蛻蛼蛽蛿蜁蜄蜅蜆蜋蜌蜎蜏蜐蜑蜔蜖汀廷停亭庭挺艇通桐酮瞳同铜彤童桶捅筒统痛偷投头透凸秃突图徒途涂屠土吐兔湍团推颓腿蜕褪退吞屯臀拖托脱鸵陀驮驼椭妥拓唾挖哇蛙洼娃瓦袜歪外豌弯湾玩顽丸烷完碗挽晚皖惋宛婉万腕汪王亡枉网往旺望忘妄威\"],[\"ce40\",\"蜙蜛蜝蜟蜠蜤蜦蜧蜨蜪蜫蜬蜭蜯蜰蜲蜳蜵蜶蜸蜹蜺蜼蜽蝀\",6,\"蝊蝋蝍蝏蝐蝑蝒蝔蝕蝖蝘蝚\",5,\"蝡蝢蝦\",7,\"蝯蝱蝲蝳蝵\"],[\"ce80\",\"蝷蝸蝹蝺蝿螀螁螄螆螇螉螊螌螎\",4,\"螔螕螖螘\",6,\"螠\",4,\"巍微危韦违桅围唯惟为潍维苇萎委伟伪尾纬未蔚味畏胃喂魏位渭谓尉慰卫瘟温蚊文闻纹吻稳紊问嗡翁瓮挝蜗涡窝我斡卧握沃巫呜钨乌污诬屋无芜梧吾吴毋武五捂午舞伍侮坞戊雾晤物勿务悟误昔熙析西硒矽晰嘻吸锡牺\"],[\"cf40\",\"螥螦螧螩螪螮螰螱螲螴螶螷螸螹螻螼螾螿蟁\",4,\"蟇蟈蟉蟌\",4,\"蟔\",6,\"蟜蟝蟞蟟蟡蟢蟣蟤蟦蟧蟨蟩蟫蟬蟭蟯\",9],[\"cf80\",\"蟺蟻蟼蟽蟿蠀蠁蠂蠄\",5,\"蠋\",7,\"蠔蠗蠘蠙蠚蠜\",4,\"蠣稀息希悉膝夕惜熄烯溪汐犀檄袭席习媳喜铣洗系隙戏细瞎虾匣霞辖暇峡侠狭下厦夏吓掀锨先仙鲜纤咸贤衔舷闲涎弦嫌显险现献县腺馅羡宪陷限线相厢镶香箱襄湘乡翔祥详想响享项巷橡像向象萧硝霄削哮嚣销消宵淆晓\"],[\"d040\",\"蠤\",13,\"蠳\",5,\"蠺蠻蠽蠾蠿衁衂衃衆\",5,\"衎\",5,\"衕衖衘衚\",6,\"衦衧衪衭衯衱衳衴衵衶衸衹衺\"],[\"d080\",\"衻衼袀袃袆袇袉袊袌袎袏袐袑袓袔袕袗\",4,\"袝\",4,\"袣袥\",5,\"小孝校肖啸笑效楔些歇蝎鞋协挟携邪斜胁谐写械卸蟹懈泄泻谢屑薪芯锌欣辛新忻心信衅星腥猩惺兴刑型形邢行醒幸杏性姓兄凶胸匈汹雄熊休修羞朽嗅锈秀袖绣墟戌需虚嘘须徐许蓄酗叙旭序畜恤絮婿绪续轩喧宣悬旋玄\"],[\"d140\",\"袬袮袯袰袲\",4,\"袸袹袺袻袽袾袿裀裃裄裇裈裊裋裌裍裏裐裑裓裖裗裚\",4,\"裠裡裦裧裩\",6,\"裲裵裶裷裺裻製裿褀褁褃\",5],[\"d180\",\"褉褋\",4,\"褑褔\",4,\"褜\",4,\"褢褣褤褦褧褨褩褬褭褮褯褱褲褳褵褷选癣眩绚靴薛学穴雪血勋熏循旬询寻驯巡殉汛训讯逊迅压押鸦鸭呀丫芽牙蚜崖衙涯雅哑亚讶焉咽阉烟淹盐严研蜒岩延言颜阎炎沿奄掩眼衍演艳堰燕厌砚雁唁彦焰宴谚验殃央鸯秧杨扬佯疡羊洋阳氧仰痒养样漾邀腰妖瑶\"],[\"d240\",\"褸\",8,\"襂襃襅\",24,\"襠\",5,\"襧\",19,\"襼\"],[\"d280\",\"襽襾覀覂覄覅覇\",26,\"摇尧遥窑谣姚咬舀药要耀椰噎耶爷野冶也页掖业叶曳腋夜液一壹医揖铱依伊衣颐夷遗移仪胰疑沂宜姨彝椅蚁倚已乙矣以艺抑易邑屹亿役臆逸肄疫亦裔意毅忆义益溢诣议谊译异翼翌绎茵荫因殷音阴姻吟银淫寅饮尹引隐\"],[\"d340\",\"覢\",30,\"觃觍觓觔觕觗觘觙觛觝觟觠觡觢觤觧觨觩觪觬觭觮觰觱觲觴\",6],[\"d380\",\"觻\",4,\"訁\",5,\"計\",21,\"印英樱婴鹰应缨莹萤营荧蝇迎赢盈影颖硬映哟拥佣臃痈庸雍踊蛹咏泳涌永恿勇用幽优悠忧尤由邮铀犹油游酉有友右佑釉诱又幼迂淤于盂榆虞愚舆余俞逾鱼愉渝渔隅予娱雨与屿禹宇语羽玉域芋郁吁遇喻峪御愈欲狱育誉\"],[\"d440\",\"訞\",31,\"訿\",8,\"詉\",21],[\"d480\",\"詟\",25,\"詺\",6,\"浴寓裕预豫驭鸳渊冤元垣袁原援辕园员圆猿源缘远苑愿怨院曰约越跃钥岳粤月悦阅耘云郧匀陨允运蕴酝晕韵孕匝砸杂栽哉灾宰载再在咱攒暂赞赃脏葬遭糟凿藻枣早澡蚤躁噪造皂灶燥责择则泽贼怎增憎曾赠扎喳渣札轧\"],[\"d540\",\"誁\",7,\"誋\",7,\"誔\",46],[\"d580\",\"諃\",32,\"铡闸眨栅榨咋乍炸诈摘斋宅窄债寨瞻毡詹粘沾盏斩辗崭展蘸栈占战站湛绽樟章彰漳张掌涨杖丈帐账仗胀瘴障招昭找沼赵照罩兆肇召遮折哲蛰辙者锗蔗这浙珍斟真甄砧臻贞针侦枕疹诊震振镇阵蒸挣睁征狰争怔整拯正政\"],[\"d640\",\"諤\",34,\"謈\",27],[\"d680\",\"謤謥謧\",30,\"帧症郑证芝枝支吱蜘知肢脂汁之织职直植殖执值侄址指止趾只旨纸志挚掷至致置帜峙制智秩稚质炙痔滞治窒中盅忠钟衷终种肿重仲众舟周州洲诌粥轴肘帚咒皱宙昼骤珠株蛛朱猪诸诛逐竹烛煮拄瞩嘱主著柱助蛀贮铸筑\"],[\"d740\",\"譆\",31,\"譧\",4,\"譭\",25],[\"d780\",\"讇\",24,\"讬讱讻诇诐诪谉谞住注祝驻抓爪拽专砖转撰赚篆桩庄装妆撞壮状椎锥追赘坠缀谆准捉拙卓桌琢茁酌啄着灼浊兹咨资姿滋淄孜紫仔籽滓子自渍字鬃棕踪宗综总纵邹走奏揍租足卒族祖诅阻组钻纂嘴醉最罪尊遵昨左佐柞做作坐座\"],[\"d840\",\"谸\",8,\"豂豃豄豅豈豊豋豍\",7,\"豖豗豘豙豛\",5,\"豣\",6,\"豬\",6,\"豴豵豶豷豻\",6,\"貃貄貆貇\"],[\"d880\",\"貈貋貍\",6,\"貕貖貗貙\",20,\"亍丌兀丐廿卅丕亘丞鬲孬噩丨禺丿匕乇夭爻卮氐囟胤馗毓睾鼗丶亟鼐乜乩亓芈孛啬嘏仄厍厝厣厥厮靥赝匚叵匦匮匾赜卦卣刂刈刎刭刳刿剀剌剞剡剜蒯剽劂劁劐劓冂罔亻仃仉仂仨仡仫仞伛仳伢佤仵伥伧伉伫佞佧攸佚佝\"],[\"d940\",\"貮\",62],[\"d980\",\"賭\",32,\"佟佗伲伽佶佴侑侉侃侏佾佻侪佼侬侔俦俨俪俅俚俣俜俑俟俸倩偌俳倬倏倮倭俾倜倌倥倨偾偃偕偈偎偬偻傥傧傩傺僖儆僭僬僦僮儇儋仝氽佘佥俎龠汆籴兮巽黉馘冁夔勹匍訇匐凫夙兕亠兖亳衮袤亵脔裒禀嬴蠃羸冫冱冽冼\"],[\"da40\",\"贎\",14,\"贠赑赒赗赟赥赨赩赪赬赮赯赱赲赸\",8,\"趂趃趆趇趈趉趌\",4,\"趒趓趕\",9,\"趠趡\"],[\"da80\",\"趢趤\",12,\"趲趶趷趹趻趽跀跁跂跅跇跈跉跊跍跐跒跓跔凇冖冢冥讠讦讧讪讴讵讷诂诃诋诏诎诒诓诔诖诘诙诜诟诠诤诨诩诮诰诳诶诹诼诿谀谂谄谇谌谏谑谒谔谕谖谙谛谘谝谟谠谡谥谧谪谫谮谯谲谳谵谶卩卺阝阢阡阱阪阽阼陂陉陔陟陧陬陲陴隈隍隗隰邗邛邝邙邬邡邴邳邶邺\"],[\"db40\",\"跕跘跙跜跠跡跢跥跦跧跩跭跮跰跱跲跴跶跼跾\",6,\"踆踇踈踋踍踎踐踑踒踓踕\",7,\"踠踡踤\",4,\"踫踭踰踲踳踴踶踷踸踻踼踾\"],[\"db80\",\"踿蹃蹅蹆蹌\",4,\"蹓\",5,\"蹚\",11,\"蹧蹨蹪蹫蹮蹱邸邰郏郅邾郐郄郇郓郦郢郜郗郛郫郯郾鄄鄢鄞鄣鄱鄯鄹酃酆刍奂劢劬劭劾哿勐勖勰叟燮矍廴凵凼鬯厶弁畚巯坌垩垡塾墼壅壑圩圬圪圳圹圮圯坜圻坂坩垅坫垆坼坻坨坭坶坳垭垤垌垲埏垧垴垓垠埕埘埚埙埒垸埴埯埸埤埝\"],[\"dc40\",\"蹳蹵蹷\",4,\"蹽蹾躀躂躃躄躆躈\",6,\"躑躒躓躕\",6,\"躝躟\",11,\"躭躮躰躱躳\",6,\"躻\",7],[\"dc80\",\"軃\",10,\"軏\",21,\"堋堍埽埭堀堞堙塄堠塥塬墁墉墚墀馨鼙懿艹艽艿芏芊芨芄芎芑芗芙芫芸芾芰苈苊苣芘芷芮苋苌苁芩芴芡芪芟苄苎芤苡茉苷苤茏茇苜苴苒苘茌苻苓茑茚茆茔茕苠苕茜荑荛荜茈莒茼茴茱莛荞茯荏荇荃荟荀茗荠茭茺茳荦荥\"],[\"dd40\",\"軥\",62],[\"dd80\",\"輤\",32,\"荨茛荩荬荪荭荮莰荸莳莴莠莪莓莜莅荼莶莩荽莸荻莘莞莨莺莼菁萁菥菘堇萘萋菝菽菖萜萸萑萆菔菟萏萃菸菹菪菅菀萦菰菡葜葑葚葙葳蒇蒈葺蒉葸萼葆葩葶蒌蒎萱葭蓁蓍蓐蓦蒽蓓蓊蒿蒺蓠蒡蒹蒴蒗蓥蓣蔌甍蔸蓰蔹蔟蔺\"],[\"de40\",\"轅\",32,\"轪辀辌辒辝辠辡辢辤辥辦辧辪辬辭辮辯農辳辴辵辷辸辺辻込辿迀迃迆\"],[\"de80\",\"迉\",4,\"迏迒迖迗迚迠迡迣迧迬迯迱迲迴迵迶迺迻迼迾迿逇逈逌逎逓逕逘蕖蔻蓿蓼蕙蕈蕨蕤蕞蕺瞢蕃蕲蕻薤薨薇薏蕹薮薜薅薹薷薰藓藁藜藿蘧蘅蘩蘖蘼廾弈夼奁耷奕奚奘匏尢尥尬尴扌扪抟抻拊拚拗拮挢拶挹捋捃掭揶捱捺掎掴捭掬掊捩掮掼揲揸揠揿揄揞揎摒揆掾摅摁搋搛搠搌搦搡摞撄摭撖\"],[\"df40\",\"這逜連逤逥逧\",5,\"逰\",4,\"逷逹逺逽逿遀遃遅遆遈\",4,\"過達違遖遙遚遜\",5,\"遤遦遧適遪遫遬遯\",4,\"遶\",6,\"遾邁\"],[\"df80\",\"還邅邆邇邉邊邌\",4,\"邒邔邖邘邚邜邞邟邠邤邥邧邨邩邫邭邲邷邼邽邿郀摺撷撸撙撺擀擐擗擤擢攉攥攮弋忒甙弑卟叱叽叩叨叻吒吖吆呋呒呓呔呖呃吡呗呙吣吲咂咔呷呱呤咚咛咄呶呦咝哐咭哂咴哒咧咦哓哔呲咣哕咻咿哌哙哚哜咩咪咤哝哏哞唛哧唠哽唔哳唢唣唏唑唧唪啧喏喵啉啭啁啕唿啐唼\"],[\"e040\",\"郂郃郆郈郉郋郌郍郒郔郕郖郘郙郚郞郟郠郣郤郥郩郪郬郮郰郱郲郳郵郶郷郹郺郻郼郿鄀鄁鄃鄅\",19,\"鄚鄛鄜\"],[\"e080\",\"鄝鄟鄠鄡鄤\",10,\"鄰鄲\",6,\"鄺\",8,\"酄唷啖啵啶啷唳唰啜喋嗒喃喱喹喈喁喟啾嗖喑啻嗟喽喾喔喙嗪嗷嗉嘟嗑嗫嗬嗔嗦嗝嗄嗯嗥嗲嗳嗌嗍嗨嗵嗤辔嘞嘈嘌嘁嘤嘣嗾嘀嘧嘭噘嘹噗嘬噍噢噙噜噌噔嚆噤噱噫噻噼嚅嚓嚯囔囗囝囡囵囫囹囿圄圊圉圜帏帙帔帑帱帻帼\"],[\"e140\",\"酅酇酈酑酓酔酕酖酘酙酛酜酟酠酦酧酨酫酭酳酺酻酼醀\",4,\"醆醈醊醎醏醓\",6,\"醜\",5,\"醤\",5,\"醫醬醰醱醲醳醶醷醸醹醻\"],[\"e180\",\"醼\",10,\"釈釋釐釒\",9,\"針\",8,\"帷幄幔幛幞幡岌屺岍岐岖岈岘岙岑岚岜岵岢岽岬岫岱岣峁岷峄峒峤峋峥崂崃崧崦崮崤崞崆崛嵘崾崴崽嵬嵛嵯嵝嵫嵋嵊嵩嵴嶂嶙嶝豳嶷巅彳彷徂徇徉後徕徙徜徨徭徵徼衢彡犭犰犴犷犸狃狁狎狍狒狨狯狩狲狴狷猁狳猃狺\"],[\"e240\",\"釦\",62],[\"e280\",\"鈥\",32,\"狻猗猓猡猊猞猝猕猢猹猥猬猸猱獐獍獗獠獬獯獾舛夥飧夤夂饣饧\",5,\"饴饷饽馀馄馇馊馍馐馑馓馔馕庀庑庋庖庥庠庹庵庾庳赓廒廑廛廨廪膺忄忉忖忏怃忮怄忡忤忾怅怆忪忭忸怙怵怦怛怏怍怩怫怊怿怡恸恹恻恺恂\"],[\"e340\",\"鉆\",45,\"鉵\",16],[\"e380\",\"銆\",7,\"銏\",24,\"恪恽悖悚悭悝悃悒悌悛惬悻悱惝惘惆惚悴愠愦愕愣惴愀愎愫慊慵憬憔憧憷懔懵忝隳闩闫闱闳闵闶闼闾阃阄阆阈阊阋阌阍阏阒阕阖阗阙阚丬爿戕氵汔汜汊沣沅沐沔沌汨汩汴汶沆沩泐泔沭泷泸泱泗沲泠泖泺泫泮沱泓泯泾\"],[\"e440\",\"銨\",5,\"銯\",24,\"鋉\",31],[\"e480\",\"鋩\",32,\"洹洧洌浃浈洇洄洙洎洫浍洮洵洚浏浒浔洳涑浯涞涠浞涓涔浜浠浼浣渚淇淅淞渎涿淠渑淦淝淙渖涫渌涮渫湮湎湫溲湟溆湓湔渲渥湄滟溱溘滠漭滢溥溧溽溻溷滗溴滏溏滂溟潢潆潇漤漕滹漯漶潋潴漪漉漩澉澍澌潸潲潼潺濑\"],[\"e540\",\"錊\",51,\"錿\",10],[\"e580\",\"鍊\",31,\"鍫濉澧澹澶濂濡濮濞濠濯瀚瀣瀛瀹瀵灏灞宀宄宕宓宥宸甯骞搴寤寮褰寰蹇謇辶迓迕迥迮迤迩迦迳迨逅逄逋逦逑逍逖逡逵逶逭逯遄遑遒遐遨遘遢遛暹遴遽邂邈邃邋彐彗彖彘尻咫屐屙孱屣屦羼弪弩弭艴弼鬻屮妁妃妍妩妪妣\"],[\"e640\",\"鍬\",34,\"鎐\",27],[\"e680\",\"鎬\",29,\"鏋鏌鏍妗姊妫妞妤姒妲妯姗妾娅娆姝娈姣姘姹娌娉娲娴娑娣娓婀婧婊婕娼婢婵胬媪媛婷婺媾嫫媲嫒嫔媸嫠嫣嫱嫖嫦嫘嫜嬉嬗嬖嬲嬷孀尕尜孚孥孳孑孓孢驵驷驸驺驿驽骀骁骅骈骊骐骒骓骖骘骛骜骝骟骠骢骣骥骧纟纡纣纥纨纩\"],[\"e740\",\"鏎\",7,\"鏗\",54],[\"e780\",\"鐎\",32,\"纭纰纾绀绁绂绉绋绌绐绔绗绛绠绡绨绫绮绯绱绲缍绶绺绻绾缁缂缃缇缈缋缌缏缑缒缗缙缜缛缟缡\",6,\"缪缫缬缭缯\",4,\"缵幺畿巛甾邕玎玑玮玢玟珏珂珑玷玳珀珉珈珥珙顼琊珩珧珞玺珲琏琪瑛琦琥琨琰琮琬\"],[\"e840\",\"鐯\",14,\"鐿\",43,\"鑬鑭鑮鑯\"],[\"e880\",\"鑰\",20,\"钑钖钘铇铏铓铔铚铦铻锜锠琛琚瑁瑜瑗瑕瑙瑷瑭瑾璜璎璀璁璇璋璞璨璩璐璧瓒璺韪韫韬杌杓杞杈杩枥枇杪杳枘枧杵枨枞枭枋杷杼柰栉柘栊柩枰栌柙枵柚枳柝栀柃枸柢栎柁柽栲栳桠桡桎桢桄桤梃栝桕桦桁桧桀栾桊桉栩梵梏桴桷梓桫棂楮棼椟椠棹\"],[\"e940\",\"锧锳锽镃镈镋镕镚镠镮镴镵長\",7,\"門\",42],[\"e980\",\"閫\",32,\"椤棰椋椁楗棣椐楱椹楠楂楝榄楫榀榘楸椴槌榇榈槎榉楦楣楹榛榧榻榫榭槔榱槁槊槟榕槠榍槿樯槭樗樘橥槲橄樾檠橐橛樵檎橹樽樨橘橼檑檐檩檗檫猷獒殁殂殇殄殒殓殍殚殛殡殪轫轭轱轲轳轵轶轸轷轹轺轼轾辁辂辄辇辋\"],[\"ea40\",\"闌\",27,\"闬闿阇阓阘阛阞阠阣\",6,\"阫阬阭阯阰阷阸阹阺阾陁陃陊陎陏陑陒陓陖陗\"],[\"ea80\",\"陘陙陚陜陝陞陠陣陥陦陫陭\",4,\"陳陸\",12,\"隇隉隊辍辎辏辘辚軎戋戗戛戟戢戡戥戤戬臧瓯瓴瓿甏甑甓攴旮旯旰昊昙杲昃昕昀炅曷昝昴昱昶昵耆晟晔晁晏晖晡晗晷暄暌暧暝暾曛曜曦曩贲贳贶贻贽赀赅赆赈赉赇赍赕赙觇觊觋觌觎觏觐觑牮犟牝牦牯牾牿犄犋犍犏犒挈挲掰\"],[\"eb40\",\"隌階隑隒隓隕隖隚際隝\",9,\"隨\",7,\"隱隲隴隵隷隸隺隻隿雂雃雈雊雋雐雑雓雔雖\",9,\"雡\",6,\"雫\"],[\"eb80\",\"雬雭雮雰雱雲雴雵雸雺電雼雽雿霂霃霅霊霋霌霐霑霒霔霕霗\",4,\"霝霟霠搿擘耄毪毳毽毵毹氅氇氆氍氕氘氙氚氡氩氤氪氲攵敕敫牍牒牖爰虢刖肟肜肓肼朊肽肱肫肭肴肷胧胨胩胪胛胂胄胙胍胗朐胝胫胱胴胭脍脎胲胼朕脒豚脶脞脬脘脲腈腌腓腴腙腚腱腠腩腼腽腭腧塍媵膈膂膑滕膣膪臌朦臊膻\"],[\"ec40\",\"霡\",8,\"霫霬霮霯霱霳\",4,\"霺霻霼霽霿\",18,\"靔靕靗靘靚靜靝靟靣靤靦靧靨靪\",7],[\"ec80\",\"靲靵靷\",4,\"靽\",7,\"鞆\",4,\"鞌鞎鞏鞐鞓鞕鞖鞗鞙\",4,\"臁膦欤欷欹歃歆歙飑飒飓飕飙飚殳彀毂觳斐齑斓於旆旄旃旌旎旒旖炀炜炖炝炻烀炷炫炱烨烊焐焓焖焯焱煳煜煨煅煲煊煸煺熘熳熵熨熠燠燔燧燹爝爨灬焘煦熹戾戽扃扈扉礻祀祆祉祛祜祓祚祢祗祠祯祧祺禅禊禚禧禳忑忐\"],[\"ed40\",\"鞞鞟鞡鞢鞤\",6,\"鞬鞮鞰鞱鞳鞵\",46],[\"ed80\",\"韤韥韨韮\",4,\"韴韷\",23,\"怼恝恚恧恁恙恣悫愆愍慝憩憝懋懑戆肀聿沓泶淼矶矸砀砉砗砘砑斫砭砜砝砹砺砻砟砼砥砬砣砩硎硭硖硗砦硐硇硌硪碛碓碚碇碜碡碣碲碹碥磔磙磉磬磲礅磴礓礤礞礴龛黹黻黼盱眄眍盹眇眈眚眢眙眭眦眵眸睐睑睇睃睚睨\"],[\"ee40\",\"頏\",62],[\"ee80\",\"顎\",32,\"睢睥睿瞍睽瞀瞌瞑瞟瞠瞰瞵瞽町畀畎畋畈畛畲畹疃罘罡罟詈罨罴罱罹羁罾盍盥蠲钅钆钇钋钊钌钍钏钐钔钗钕钚钛钜钣钤钫钪钭钬钯钰钲钴钶\",4,\"钼钽钿铄铈\",6,\"铐铑铒铕铖铗铙铘铛铞铟铠铢铤铥铧铨铪\"],[\"ef40\",\"顯\",5,\"颋颎颒颕颙颣風\",37,\"飏飐飔飖飗飛飜飝飠\",4],[\"ef80\",\"飥飦飩\",30,\"铩铫铮铯铳铴铵铷铹铼铽铿锃锂锆锇锉锊锍锎锏锒\",4,\"锘锛锝锞锟锢锪锫锩锬锱锲锴锶锷锸锼锾锿镂锵镄镅镆镉镌镎镏镒镓镔镖镗镘镙镛镞镟镝镡镢镤\",8,\"镯镱镲镳锺矧矬雉秕秭秣秫稆嵇稃稂稞稔\"],[\"f040\",\"餈\",4,\"餎餏餑\",28,\"餯\",26],[\"f080\",\"饊\",9,\"饖\",12,\"饤饦饳饸饹饻饾馂馃馉稹稷穑黏馥穰皈皎皓皙皤瓞瓠甬鸠鸢鸨\",4,\"鸲鸱鸶鸸鸷鸹鸺鸾鹁鹂鹄鹆鹇鹈鹉鹋鹌鹎鹑鹕鹗鹚鹛鹜鹞鹣鹦\",6,\"鹱鹭鹳疒疔疖疠疝疬疣疳疴疸痄疱疰痃痂痖痍痣痨痦痤痫痧瘃痱痼痿瘐瘀瘅瘌瘗瘊瘥瘘瘕瘙\"],[\"f140\",\"馌馎馚\",10,\"馦馧馩\",47],[\"f180\",\"駙\",32,\"瘛瘼瘢瘠癀瘭瘰瘿瘵癃瘾瘳癍癞癔癜癖癫癯翊竦穸穹窀窆窈窕窦窠窬窨窭窳衤衩衲衽衿袂袢裆袷袼裉裢裎裣裥裱褚裼裨裾裰褡褙褓褛褊褴褫褶襁襦襻疋胥皲皴矜耒耔耖耜耠耢耥耦耧耩耨耱耋耵聃聆聍聒聩聱覃顸颀颃\"],[\"f240\",\"駺\",62],[\"f280\",\"騹\",32,\"颉颌颍颏颔颚颛颞颟颡颢颥颦虍虔虬虮虿虺虼虻蚨蚍蚋蚬蚝蚧蚣蚪蚓蚩蚶蛄蚵蛎蚰蚺蚱蚯蛉蛏蚴蛩蛱蛲蛭蛳蛐蜓蛞蛴蛟蛘蛑蜃蜇蛸蜈蜊蜍蜉蜣蜻蜞蜥蜮蜚蜾蝈蜴蜱蜩蜷蜿螂蜢蝽蝾蝻蝠蝰蝌蝮螋蝓蝣蝼蝤蝙蝥螓螯螨蟒\"],[\"f340\",\"驚\",17,\"驲骃骉骍骎骔骕骙骦骩\",6,\"骲骳骴骵骹骻骽骾骿髃髄髆\",4,\"髍髎髏髐髒體髕髖髗髙髚髛髜\"],[\"f380\",\"髝髞髠髢髣髤髥髧髨髩髪髬髮髰\",8,\"髺髼\",6,\"鬄鬅鬆蟆螈螅螭螗螃螫蟥螬螵螳蟋蟓螽蟑蟀蟊蟛蟪蟠蟮蠖蠓蟾蠊蠛蠡蠹蠼缶罂罄罅舐竺竽笈笃笄笕笊笫笏筇笸笪笙笮笱笠笥笤笳笾笞筘筚筅筵筌筝筠筮筻筢筲筱箐箦箧箸箬箝箨箅箪箜箢箫箴篑篁篌篝篚篥篦篪簌篾篼簏簖簋\"],[\"f440\",\"鬇鬉\",5,\"鬐鬑鬒鬔\",10,\"鬠鬡鬢鬤\",10,\"鬰鬱鬳\",7,\"鬽鬾鬿魀魆魊魋魌魎魐魒魓魕\",5],[\"f480\",\"魛\",32,\"簟簪簦簸籁籀臾舁舂舄臬衄舡舢舣舭舯舨舫舸舻舳舴舾艄艉艋艏艚艟艨衾袅袈裘裟襞羝羟羧羯羰羲籼敉粑粝粜粞粢粲粼粽糁糇糌糍糈糅糗糨艮暨羿翎翕翥翡翦翩翮翳糸絷綦綮繇纛麸麴赳趄趔趑趱赧赭豇豉酊酐酎酏酤\"],[\"f540\",\"魼\",62],[\"f580\",\"鮻\",32,\"酢酡酰酩酯酽酾酲酴酹醌醅醐醍醑醢醣醪醭醮醯醵醴醺豕鹾趸跫踅蹙蹩趵趿趼趺跄跖跗跚跞跎跏跛跆跬跷跸跣跹跻跤踉跽踔踝踟踬踮踣踯踺蹀踹踵踽踱蹉蹁蹂蹑蹒蹊蹰蹶蹼蹯蹴躅躏躔躐躜躞豸貂貊貅貘貔斛觖觞觚觜\"],[\"f640\",\"鯜\",62],[\"f680\",\"鰛\",32,\"觥觫觯訾謦靓雩雳雯霆霁霈霏霎霪霭霰霾龀龃龅\",5,\"龌黾鼋鼍隹隼隽雎雒瞿雠銎銮鋈錾鍪鏊鎏鐾鑫鱿鲂鲅鲆鲇鲈稣鲋鲎鲐鲑鲒鲔鲕鲚鲛鲞\",5,\"鲥\",4,\"鲫鲭鲮鲰\",7,\"鲺鲻鲼鲽鳄鳅鳆鳇鳊鳋\"],[\"f740\",\"鰼\",62],[\"f780\",\"鱻鱽鱾鲀鲃鲄鲉鲊鲌鲏鲓鲖鲗鲘鲙鲝鲪鲬鲯鲹鲾\",4,\"鳈鳉鳑鳒鳚鳛鳠鳡鳌\",4,\"鳓鳔鳕鳗鳘鳙鳜鳝鳟鳢靼鞅鞑鞒鞔鞯鞫鞣鞲鞴骱骰骷鹘骶骺骼髁髀髅髂髋髌髑魅魃魇魉魈魍魑飨餍餮饕饔髟髡髦髯髫髻髭髹鬈鬏鬓鬟鬣麽麾縻麂麇麈麋麒鏖麝麟黛黜黝黠黟黢黩黧黥黪黯鼢鼬鼯鼹鼷鼽鼾齄\"],[\"f840\",\"鳣\",62],[\"f880\",\"鴢\",32],[\"f940\",\"鵃\",62],[\"f980\",\"鶂\",32],[\"fa40\",\"鶣\",62],[\"fa80\",\"鷢\",32],[\"fb40\",\"鸃\",27,\"鸤鸧鸮鸰鸴鸻鸼鹀鹍鹐鹒鹓鹔鹖鹙鹝鹟鹠鹡鹢鹥鹮鹯鹲鹴\",9,\"麀\"],[\"fb80\",\"麁麃麄麅麆麉麊麌\",5,\"麔\",8,\"麞麠\",5,\"麧麨麩麪\"],[\"fc40\",\"麫\",8,\"麵麶麷麹麺麼麿\",4,\"黅黆黇黈黊黋黌黐黒黓黕黖黗黙黚點黡黣黤黦黨黫黬黭黮黰\",8,\"黺黽黿\",6],[\"fc80\",\"鼆\",4,\"鼌鼏鼑鼒鼔鼕鼖鼘鼚\",5,\"鼡鼣\",8,\"鼭鼮鼰鼱\"],[\"fd40\",\"鼲\",4,\"鼸鼺鼼鼿\",4,\"齅\",10,\"齒\",38],[\"fd80\",\"齹\",5,\"龁龂龍\",11,\"龜龝龞龡\",4,\"郎凉秊裏隣\"],[\"fe40\",\"兀嗀﨎﨏﨑﨓﨔礼﨟蘒﨡﨣﨤﨧﨨﨩\"]]");

/***/ }),
/* 180 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 *
 * @param value
 * @returns {boolean}
 */
const util_1 = __webpack_require__(133);
/**
 * Check that an obejct is traversable in the sense of PHP,
 * i.e. implements PHP Traversable interface
 *
 * @param value
 * @returns {boolean}
 */
function isTraversable(value) {
    if (!util_1.isNullOrUndefined(value)) {
        if (typeof value === 'string') {
            return false;
        }
        if (typeof value['entries'] === 'function') {
            return true;
        }
        if ((typeof value[Symbol.iterator] === 'function') || (typeof value['next'] === 'function')) {
            return true;
        }
    }
    return false;
}
exports.isTraversable = isTraversable;


/***/ }),
/* 181 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Sort a map by key
 *
 * @param {Map<*, *>} map
 * @param {Function} handler
 */
function ksort(map, handler = undefined) {
    let sortedMap = new Map();
    let sortedKeys = [...map.keys()].sort(handler);
    for (let key of sortedKeys) {
        sortedMap.set(key, map.get(key));
    }
    map.clear();
    for (let [key, value] of sortedMap) {
        map.set(key, value);
    }
}
exports.ksort = ksort;


/***/ }),
/* 182 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionName extends expression_1.TwingNodeExpression {
    constructor(name, lineno, columnno) {
        let attributes = new Map();
        attributes.set('name', name);
        attributes.set('is_defined_test', false);
        attributes.set('ignore_strict_check', false);
        attributes.set('always_defined', false);
        super(new Map(), attributes, lineno, columnno);
        this.specialVars = new Map([
            ['_self', 'this.getTemplateName()'],
            ['_context', 'context'],
            ['_charset', 'this.env.getCharset()']
        ]);
        this.type = node_1.TwingNodeType.EXPRESSION_NAME;
    }
    compile(compiler) {
        let name = this.getAttribute('name');
        compiler.addDebugInfo(this);
        if (this.getAttribute('is_defined_test')) {
            if (this.isSpecial()) {
                compiler.repr(true);
            }
            else {
                compiler.raw('(context.has(').repr(name).raw('))');
            }
        }
        else if (this.isSpecial()) {
            compiler.raw(this.specialVars.get(name));
        }
        else if (this.getAttribute('always_defined')) {
            compiler
                .raw('context.get(')
                .string(name)
                .raw(')');
        }
        else {
            if (this.getAttribute('ignore_strict_check') || !compiler.getEnvironment().isStrictVariables()) {
                compiler
                    .raw('(context.has(')
                    .string(name)
                    .raw(') ? context.get(')
                    .string(name)
                    .raw(') : null)');
            }
            else {
                compiler
                    .raw('(context.has(')
                    .string(name)
                    .raw(') ? context.get(')
                    .string(name)
                    .raw(') : (() => { throw new Runtime.TwingErrorRuntime(\'Variable ')
                    .string(name)
                    .raw(' does not exist.\', ')
                    .repr(this.lineno)
                    .raw(', this.source); })()')
                    .raw(')');
            }
        }
    }
    isSpecial() {
        return this.specialVars.has(this.getAttribute('name'));
    }
    isSimple() {
        return !this.isSpecial() && !this.getAttribute('is_defined_test');
    }
}
exports.TwingNodeExpressionName = TwingNodeExpressionName;


/***/ }),
/* 183 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeIf extends node_1.TwingNode {
    constructor(tests, elseNode, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('tests', tests);
        if (elseNode) {
            nodes.set('else', elseNode);
        }
        super(nodes, new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.IF;
    }
    compile(compiler) {
        compiler.addDebugInfo(this);
        let count = this.getNode('tests').getNodes().size;
        for (let i = 0; i < count; i += 2) {
            if (i > 0) {
                compiler
                    .outdent()
                    .write('}\n')
                    .write('else if (');
            }
            else {
                compiler
                    .write('if (');
            }
            compiler
                .subcompile(this.getNode('tests').getNode(i))
                .raw(") {\n")
                .indent()
                .subcompile(this.getNode('tests').getNode(i + 1));
        }
        if (this.hasNode('else')) {
            compiler
                .outdent()
                .write("}\n")
                .write("else {\n")
                .indent()
                .subcompile(this.getNode('else'));
        }
        compiler
            .outdent()
            .write("}\n");
    }
}
exports.TwingNodeIf = TwingNodeIf;


/***/ }),
/* 184 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer, process) {
Object.defineProperty(exports, "__esModule", { value: true });
const token_1 = __webpack_require__(109);
const node_1 = __webpack_require__(107);
const constant_1 = __webpack_require__(115);
const syntax_1 = __webpack_require__(112);
const lexer_1 = __webpack_require__(185);
const name_1 = __webpack_require__(182);
const concat_1 = __webpack_require__(187);
const get_attr_1 = __webpack_require__(263);
const method_call_1 = __webpack_require__(265);
const array_1 = __webpack_require__(154);
const conditional_1 = __webpack_require__(138);
const template_1 = __webpack_require__(123);
const assign_name_1 = __webpack_require__(136);
const parent_1 = __webpack_require__(266);
const block_reference_1 = __webpack_require__(189);
const hash_1 = __webpack_require__(267);
const not_1 = __webpack_require__(155);
const push_1 = __webpack_require__(137);
const arrow_function_1 = __webpack_require__(451);
/**
 * Parses expressions.
 *
 * This parser implements a "Precedence climbing" algorithm.
 *
 * @see https://www.engr.mun.ca/~theo/Misc/exp_parsing.htm
 * @see https://en.wikipedia.org/wiki/Operator-precedence_parser
 *
 * @author Fabien Potencier <fabien@symfony.com>
 * @author Eric MORAND <eric.morand@gmail.com>
 *
 * @internal
 */
class TwingExpressionParser {
    constructor(parser, env) {
        this.parser = parser;
        this.env = env;
        this.unaryOperators = env.getUnaryOperators();
        this.binaryOperators = env.getBinaryOperators();
    }
    parseExpression(precedence = 0, allowArrow = false) {
        if (allowArrow) {
            let arrow = this.parseArrow();
            if (arrow) {
                return arrow;
            }
        }
        let expr = this.getPrimary();
        let token = this.parser.getCurrentToken();
        while (this.isBinary(token) && this.binaryOperators.get(token.getValue()).precedence >= precedence) {
            let op = this.binaryOperators.get(token.getValue());
            this.parser.getStream().next();
            if (token.getValue() === 'is not') {
                expr = this.parseNotTestExpression(expr);
            }
            else if (token.getValue() === 'is') {
                expr = this.parseTestExpression(expr);
            }
            else if (op.callable) {
                expr = op.callable.call(this.parser, expr);
            }
            else {
                let expr1 = this.parseExpression(op.associativity === TwingExpressionParser.OPERATOR_LEFT ? op.precedence + 1 : op.precedence);
                let opFactory = op.factory;
                expr = opFactory(expr, expr1, token.getLine());
            }
            token = this.parser.getCurrentToken();
        }
        if (precedence === 0) {
            return this.parseConditionalExpression(expr);
        }
        return expr;
    }
    /**
     * @return TwingNodeExpressionArrowFunction|null
     */
    parseArrow() {
        let stream = this.parser.getStream();
        let token;
        let line;
        let column;
        let names;
        // short array syntax (one argument, no parentheses)?
        if (stream.look(1).test(token_1.TwingToken.ARROW_TYPE)) {
            line = stream.getCurrent().getLine();
            column = stream.getCurrent().getColumn();
            token = stream.expect(token_1.TwingToken.NAME_TYPE);
            names = new Map([[0, new assign_name_1.TwingNodeExpressionAssignName(token.getValue(), token.getLine(), token.getColumn())]]);
            stream.expect(token_1.TwingToken.ARROW_TYPE);
            return new arrow_function_1.TwingNodeExpressionArrowFunction(this.parseExpression(0), new node_1.TwingNode(names), line, column);
        }
        // first, determine if we are parsing an arrow function by finding => (long form)
        let i = 0;
        if (!stream.look(i).test(token_1.TwingToken.PUNCTUATION_TYPE, '(')) {
            return null;
        }
        ++i;
        while (true) {
            // variable name
            ++i;
            if (!stream.look(i).test(token_1.TwingToken.PUNCTUATION_TYPE, ',')) {
                break;
            }
            ++i;
        }
        if (!stream.look(i).test(token_1.TwingToken.PUNCTUATION_TYPE, ')')) {
            return null;
        }
        ++i;
        if (!stream.look(i).test(token_1.TwingToken.ARROW_TYPE)) {
            return null;
        }
        // yes, let's parse it properly
        token = stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, '(');
        line = token.getLine();
        column = token.getColumn();
        names = new Map();
        i = 0;
        while (true) {
            token = this.parser.getCurrentToken();
            if (!token.test(token_1.TwingToken.NAME_TYPE)) {
                throw new syntax_1.TwingErrorSyntax(`Unexpected token "${token_1.TwingToken.typeToEnglish(token.getType())}" of value "${token.getValue()}".`, token.getLine(), stream.getSourceContext());
            }
            names.set(i++, new assign_name_1.TwingNodeExpressionAssignName(token.getValue(), token.getLine(), token.getColumn()));
            stream.next();
            if (!stream.nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ',')) {
                break;
            }
        }
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ')');
        stream.expect(token_1.TwingToken.ARROW_TYPE);
        return new arrow_function_1.TwingNodeExpressionArrowFunction(this.parseExpression(0), new node_1.TwingNode(names), line, column);
    }
    getPrimary() {
        let token = this.parser.getCurrentToken();
        if (this.isUnary(token)) {
            let operator = this.unaryOperators.get(token.getValue());
            this.parser.getStream().next();
            let expr = this.parseExpression(operator.precedence);
            return this.parsePostfixExpression(operator.factory(expr, token.getLine()));
        }
        else if (token.test(token_1.TwingToken.PUNCTUATION_TYPE, '(')) {
            this.parser.getStream().next();
            let expr = this.parseExpression();
            this.parser.getStream().expect(token_1.TwingToken.PUNCTUATION_TYPE, ')', 'An opened parenthesis is not properly closed');
            return this.parsePostfixExpression(expr);
        }
        return this.parsePrimaryExpression();
    }
    parsePrimaryExpression() {
        let token = this.parser.getCurrentToken();
        let node;
        switch (token.getType()) {
            case token_1.TwingToken.NAME_TYPE:
                this.parser.getStream().next();
                switch (token.getValue()) {
                    case 'true':
                    case 'TRUE':
                        node = new constant_1.TwingNodeExpressionConstant(true, token.getLine(), token.getColumn());
                        break;
                    case 'false':
                    case 'FALSE':
                        node = new constant_1.TwingNodeExpressionConstant(false, token.getLine(), token.getColumn());
                        break;
                    case 'none':
                    case 'NONE':
                    case 'null':
                    case 'NULL':
                        node = new constant_1.TwingNodeExpressionConstant(null, token.getLine(), token.getColumn());
                        break;
                    default:
                        if ('(' === this.parser.getCurrentToken().getValue()) {
                            node = this.getFunctionNode(token.getValue(), token.getLine(), token.getColumn());
                        }
                        else {
                            node = new name_1.TwingNodeExpressionName(token.getValue(), token.getLine(), token.getColumn());
                        }
                }
                break;
            case token_1.TwingToken.NUMBER_TYPE:
                this.parser.getStream().next();
                node = new constant_1.TwingNodeExpressionConstant(token.getValue(), token.getLine(), token.getColumn());
                break;
            case token_1.TwingToken.STRING_TYPE:
            case token_1.TwingToken.INTERPOLATION_START_TYPE:
                node = this.parseStringExpression();
                break;
            case token_1.TwingToken.OPERATOR_TYPE:
                let match = lexer_1.TwingLexer.REGEX_NAME.exec(token.getValue());
                if (match !== null && match[0] === token.getValue()) {
                    // in this context, string operators are variable names
                    this.parser.getStream().next();
                    node = new name_1.TwingNodeExpressionName(token.getValue(), token.getLine(), token.getColumn());
                    break;
                }
                else if (this.unaryOperators.has(token.getValue())) {
                    let op = this.unaryOperators.get(token.getValue());
                    //
                    // ref = new ReflectionClass(class);
                    // negClass = 'Twig_Node_Expression_Unary_Neg';
                    // posClass = 'Twig_Node_Expression_Unary_Pos';
                    //
                    // if (!(in_array(ref.getTemplateName(), array(negClass, posClass)) || ref.isSubclassOf(negClass) || ref.isSubclassOf(posClass))) {
                    //     throw new Twig_Error_Syntax(sprintf('Unexpected unary operator "%s".', token.getValue()), token.getLine(), this.parser.getStream().getSourceContext());
                    // }
                    //
                    this.parser.getStream().next();
                    let expr = this.parsePrimaryExpression();
                    node = op.factory(expr, token.getLine());
                    break;
                }
            default:
                if (token.test(token_1.TwingToken.PUNCTUATION_TYPE, '[')) {
                    node = this.parseArrayExpression();
                }
                else if (token.test(token_1.TwingToken.PUNCTUATION_TYPE, '{')) {
                    node = this.parseHashExpression();
                }
                else if (token.test(token_1.TwingToken.OPERATOR_TYPE, '=') && (this.parser.getStream().look(-1).getValue() === '==' || this.parser.getStream().look(-1).getValue() === '!=')) {
                    throw new syntax_1.TwingErrorSyntax(`Unexpected operator of value "${token.getValue()}". Did you try to use "===" or "!==" for strict comparison? Use "is same as(value)" instead.`, token.getLine(), this.parser.getStream().getSourceContext());
                }
                else {
                    throw new syntax_1.TwingErrorSyntax(`Unexpected token "${token_1.TwingToken.typeToEnglish(token.getType())}" of value "${token.getValue()}".`, token.getLine(), this.parser.getStream().getSourceContext());
                }
        }
        return this.parsePostfixExpression(node);
    }
    getFunctionNode(name, line, column) {
        switch (name) {
            case 'parent':
                this.parseArguments();
                if (!this.parser.getBlockStack().length) {
                    throw new syntax_1.TwingErrorSyntax('Calling "parent" outside a block is forbidden.', line, this.parser.getStream().getSourceContext());
                }
                if (!this.parser.getParent() && !this.parser.hasTraits()) {
                    throw new syntax_1.TwingErrorSyntax('Calling "parent" on a template that does not extend nor "use" another template is forbidden.', line, this.parser.getStream().getSourceContext());
                }
                return new parent_1.TwingNodeExpressionParent(this.parser.peekBlockStack(), line);
            case 'block':
                let blockArgs = this.parseArguments();
                if (blockArgs.getNodes().size < 1) {
                    throw new syntax_1.TwingErrorSyntax('The "block" function takes one argument (the block name).', line, this.parser.getStream().getSourceContext());
                }
                return new block_reference_1.TwingNodeExpressionBlockReference(blockArgs.getNode(0), blockArgs.getNodes().size > 1 ? blockArgs.getNode(1) : null, line, column);
            case 'attribute':
                let attributeArgs = this.parseArguments();
                if (attributeArgs.getNodes().size < 2) {
                    throw new syntax_1.TwingErrorSyntax('The "attribute" function takes at least two arguments (the variable and the attributes).', line, this.parser.getStream().getSourceContext());
                }
                return new get_attr_1.TwingNodeExpressionGetAttr(attributeArgs.getNode(0), attributeArgs.getNode(1), attributeArgs.getNodes().size > 2 ? attributeArgs.getNode(2) : null, template_1.TwingTemplate.ANY_CALL, line, column);
            default:
                let alias = this.parser.getImportedSymbol('function', name);
                if (alias) {
                    let functionArguments = new array_1.TwingNodeExpressionArray(new Map(), line, column);
                    this.parseArguments().getNodes().forEach(function (n, name) {
                        functionArguments.addElement(n);
                    });
                    let node = new method_call_1.TwingNodeExpressionMethodCall(alias.node, alias.name, functionArguments, line, column);
                    node.setAttribute('safe', true);
                    return node;
                }
                let aliasArguments = this.parseArguments(true);
                let aliasFactory = this.getFunctionExpressionFactory(name, line, column);
                return aliasFactory(name, aliasArguments, line, column);
        }
    }
    parseStringExpression() {
        let stream = this.parser.getStream();
        let nodes = [];
        // a string cannot be followed by another string in a single expression
        let nextCanBeString = true;
        let token;
        while (true) {
            if (nextCanBeString && (token = stream.nextIf(token_1.TwingToken.STRING_TYPE))) {
                nodes.push(new constant_1.TwingNodeExpressionConstant(token.getValue(), token.getLine(), token.getColumn()));
                nextCanBeString = false;
            }
            else if (stream.nextIf(token_1.TwingToken.INTERPOLATION_START_TYPE)) {
                nodes.push(this.parseExpression());
                stream.expect(token_1.TwingToken.INTERPOLATION_END_TYPE);
                nextCanBeString = true;
            }
            else {
                break;
            }
        }
        let expr = nodes.shift();
        nodes.forEach(function (node) {
            expr = new concat_1.TwingNodeExpressionBinaryConcat(expr, node, node.getTemplateLine(), node.getTemplateColumn());
        });
        return expr;
    }
    parseArrayExpression() {
        let stream = this.parser.getStream();
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, '[', 'An array element was expected');
        let node = new array_1.TwingNodeExpressionArray(new Map(), stream.getCurrent().getLine(), stream.getCurrent().getColumn());
        let first = true;
        while (!stream.test(token_1.TwingToken.PUNCTUATION_TYPE, ']')) {
            if (!first) {
                stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ',', 'An array element must be followed by a comma');
                // trailing ,?
                if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, ']')) {
                    break;
                }
            }
            first = false;
            node.addElement(this.parseExpression());
        }
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ']', 'An opened array is not properly closed');
        return node;
    }
    parseHashExpression() {
        let stream = this.parser.getStream();
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, '{', 'A hash element was expected');
        let node = new hash_1.TwingNodeExpressionHash(new Map(), stream.getCurrent().getLine(), stream.getCurrent().getColumn());
        let first = true;
        while (!stream.test(token_1.TwingToken.PUNCTUATION_TYPE, '}')) {
            if (!first) {
                stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ',', 'A hash value must be followed by a comma');
                // trailing ,?
                if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, '}')) {
                    break;
                }
            }
            first = false;
            // a hash key can be:
            //
            //  * a number -- 12
            //  * a string -- 'a'
            //  * a name, which is equivalent to a string -- a
            //  * an expression, which must be enclosed in parentheses -- (1 + 2)
            let token;
            let key;
            if ((token = stream.nextIf(token_1.TwingToken.STRING_TYPE)) || (token = stream.nextIf(token_1.TwingToken.NAME_TYPE)) || (token = stream.nextIf(token_1.TwingToken.NUMBER_TYPE))) {
                key = new constant_1.TwingNodeExpressionConstant(token.getValue(), token.getLine(), token.getColumn());
            }
            else if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, '(')) {
                key = this.parseExpression();
            }
            else {
                let current = stream.getCurrent();
                throw new syntax_1.TwingErrorSyntax(`A hash key must be a quoted string, a number, a name, or an expression enclosed in parentheses (unexpected token "${token_1.TwingToken.typeToEnglish(current.getType())}" of value "${current.getValue()}".`, current.getLine(), stream.getSourceContext());
            }
            stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ':', 'A hash key must be followed by a colon (:)');
            let value = this.parseExpression();
            node.addElement(value, key);
        }
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, '}', 'An opened hash is not properly closed');
        return node;
    }
    parseSubscriptExpression(node) {
        let stream = this.parser.getStream();
        let token = stream.next();
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let arguments_ = new array_1.TwingNodeExpressionArray(new Map(), lineno, columnno);
        let arg;
        let type = template_1.TwingTemplate.ANY_CALL;
        if (token.getValue() === '.') {
            token = stream.next();
            let match = lexer_1.TwingLexer.REGEX_NAME.exec(token.getValue());
            if ((token.getType() === token_1.TwingToken.NAME_TYPE) || (token.getType() === token_1.TwingToken.NUMBER_TYPE) || (token.getType() === token_1.TwingToken.OPERATOR_TYPE && (match !== null))) {
                arg = new constant_1.TwingNodeExpressionConstant(token.getValue(), lineno, columnno);
                if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, '(')) {
                    type = template_1.TwingTemplate.METHOD_CALL;
                    let node = this.parseArguments();
                    node.getNodes().forEach(function (n, k) {
                        arguments_.addElement(n);
                    });
                }
            }
            else {
                throw new syntax_1.TwingErrorSyntax('Expected name or number.', lineno, stream.getSourceContext());
            }
            if ((node.getType() === node_1.TwingNodeType.EXPRESSION_NAME) && this.parser.getImportedSymbol('template', node.getAttribute('name'))) {
                const varValidator = __webpack_require__(139);
                let name = arg.getAttribute('value');
                if (!varValidator.isValid(name)) {
                    name = Buffer.from(name).toString('hex');
                }
                node = new method_call_1.TwingNodeExpressionMethodCall(node, 'macro_' + name, arguments_, lineno, columnno);
                node.setAttribute('safe', true);
                return node;
            }
        }
        else {
            type = template_1.TwingTemplate.ARRAY_CALL;
            // slice?
            let slice = false;
            if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, ':')) {
                slice = true;
                arg = new constant_1.TwingNodeExpressionConstant(0, token.getLine(), token.getColumn());
            }
            else {
                arg = this.parseExpression();
            }
            if (stream.nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ':')) {
                slice = true;
            }
            if (slice) {
                let length;
                if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, ']')) {
                    length = new constant_1.TwingNodeExpressionConstant(null, token.getLine(), token.getColumn());
                }
                else {
                    length = this.parseExpression();
                }
                let factory = this.getFilterExpressionFactory('slice', token.getLine(), token.getColumn());
                let filterArguments = new node_1.TwingNode(new Map([[0, arg], [1, length]]));
                let filter = factory.call(this, node, new constant_1.TwingNodeExpressionConstant('slice', token.getLine(), token.getColumn()), filterArguments, token.getLine(), token.getColumn());
                stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ']');
                return filter;
            }
            stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ']');
        }
        return new get_attr_1.TwingNodeExpressionGetAttr(node, arg, arguments_, type, lineno, columnno);
    }
    parsePostfixExpression(node) {
        while (true) {
            let token = this.parser.getCurrentToken();
            if (token.getType() === token_1.TwingToken.PUNCTUATION_TYPE) {
                if ('.' == token.getValue() || '[' == token.getValue()) {
                    node = this.parseSubscriptExpression(node);
                }
                else if ('|' == token.getValue()) {
                    node = this.parseFilterExpression(node);
                }
                else {
                    break;
                }
            }
            else {
                break;
            }
        }
        return node;
    }
    parseTestExpression(node) {
        let stream = this.parser.getStream();
        let name;
        let test;
        [name, test] = this.getTest(node.getTemplateLine());
        let nodeFactory = test.getNodeFactory();
        let testArguments = null;
        if (stream.test(token_1.TwingToken.PUNCTUATION_TYPE, '(')) {
            testArguments = this.parser.getExpressionParser().parseArguments(true);
        }
        return nodeFactory.call(this, node, name, testArguments, this.parser.getCurrentToken().getLine());
    }
    parseNotTestExpression(node) {
        return new not_1.TwingNodeExpressionUnaryNot(this.parseTestExpression(node), this.parser.getCurrentToken().getLine(), this.parser.getCurrentToken().getColumn());
    }
    parseConditionalExpression(expr) {
        let expr2;
        let expr3;
        while (this.parser.getStream().nextIf(token_1.TwingToken.PUNCTUATION_TYPE, '?')) {
            if (!this.parser.getStream().nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ':')) {
                expr2 = this.parseExpression();
                if (this.parser.getStream().nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ':')) {
                    expr3 = this.parseExpression();
                }
                else {
                    expr3 = new constant_1.TwingNodeExpressionConstant('', this.parser.getCurrentToken().getLine(), this.parser.getCurrentToken().getColumn());
                }
            }
            else {
                expr2 = expr;
                expr3 = this.parseExpression();
            }
            expr = new conditional_1.TwingNodeExpressionConditional(expr, expr2, expr3, this.parser.getCurrentToken().getLine(), this.parser.getCurrentToken().getColumn());
        }
        return expr;
    }
    parseFilterExpression(node) {
        this.parser.getStream().next();
        return this.parseFilterExpressionRaw(node);
    }
    parseFilterExpressionRaw(node, tag = null) {
        while (true) {
            let token = this.parser.getStream().expect(token_1.TwingToken.NAME_TYPE);
            let name = new constant_1.TwingNodeExpressionConstant(token.getValue(), token.getLine(), token.getColumn());
            let methodArguments;
            if (!this.parser.getStream().test(token_1.TwingToken.PUNCTUATION_TYPE, '(')) {
                methodArguments = new node_1.TwingNode();
            }
            else {
                methodArguments = this.parseArguments(true, false, true);
            }
            let factory = this.getFilterExpressionFactory('' + name.getAttribute('value'), token.getLine(), token.getColumn());
            node = factory.call(this, node, name, methodArguments, token.getLine(), tag);
            if (!this.parser.getStream().test(token_1.TwingToken.PUNCTUATION_TYPE, '|')) {
                break;
            }
            this.parser.getStream().next();
        }
        return node;
    }
    /**
     * Parses arguments.
     *
     * @param namedArguments {boolean} Whether to allow named arguments or not
     * @param definition {boolean} Whether we are parsing arguments for a function definition
     * @param allowArrow {boolean}
     *
     * @return TwingNode
     *
     * @throws TwingErrorSyntax
     */
    parseArguments(namedArguments = false, definition = false, allowArrow = false) {
        let parsedArguments = new Map();
        let stream = this.parser.getStream();
        let value;
        let token;
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, '(', 'A list of arguments must begin with an opening parenthesis');
        while (!stream.test(token_1.TwingToken.PUNCTUATION_TYPE, ')')) {
            if (parsedArguments.size > 0) {
                stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ',', 'Arguments must be separated by a comma');
            }
            if (definition) {
                token = stream.expect(token_1.TwingToken.NAME_TYPE, null, 'An argument must be a name');
                value = new name_1.TwingNodeExpressionName(token.getValue(), this.parser.getCurrentToken().getLine(), this.parser.getCurrentToken().getColumn());
            }
            else {
                value = this.parseExpression(0, allowArrow);
            }
            let name = null;
            if (namedArguments && (token = stream.nextIf(token_1.TwingToken.OPERATOR_TYPE, '='))) {
                if (value.getType() !== node_1.TwingNodeType.EXPRESSION_NAME) {
                    throw new syntax_1.TwingErrorSyntax(`A parameter name must be a string, "${value.constructor.name}" given.`, token.getLine(), stream.getSourceContext());
                }
                name = value.getAttribute('name');
                if (definition) {
                    value = this.parsePrimaryExpression();
                    if (!this.checkConstantExpression(value)) {
                        throw new syntax_1.TwingErrorSyntax(`A default value for an argument must be a constant (a boolean, a string, a number, or an array).`, token.getLine(), stream.getSourceContext());
                    }
                }
                else {
                    value = this.parseExpression(0, allowArrow);
                }
            }
            if (definition) {
                if (null === name) {
                    name = value.getAttribute('name');
                    value = new constant_1.TwingNodeExpressionConstant(null, this.parser.getCurrentToken().getLine(), this.parser.getCurrentToken().getColumn());
                }
                parsedArguments.set(name, value);
            }
            else {
                if (null === name) {
                    push_1.push(parsedArguments, value);
                }
                else {
                    parsedArguments.set(name, value);
                }
            }
        }
        stream.expect(token_1.TwingToken.PUNCTUATION_TYPE, ')', 'A list of arguments must be closed by a parenthesis');
        return new node_1.TwingNode(parsedArguments);
    }
    parseAssignmentExpression() {
        let stream = this.parser.getStream();
        let targets = new Map();
        while (true) {
            let token = this.parser.getCurrentToken();
            if (stream.test(token_1.TwingToken.OPERATOR_TYPE) && lexer_1.TwingLexer.REGEX_NAME.exec(token.getValue())) {
                // in this context, string operators are variable names
                this.parser.getStream().next();
            }
            else {
                stream.expect(token_1.TwingToken.NAME_TYPE, null, 'Only variables can be assigned to');
            }
            let value = token.getValue();
            if (['true', 'false', 'none', 'null'].indexOf(value.toLowerCase()) > -1) {
                throw new syntax_1.TwingErrorSyntax(`You cannot assign a value to "${value}".`, token.getLine(), stream.getSourceContext());
            }
            push_1.push(targets, new assign_name_1.TwingNodeExpressionAssignName(value, token.getLine(), token.getColumn()));
            if (!stream.nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ',')) {
                break;
            }
        }
        return new node_1.TwingNode(targets);
    }
    parseMultitargetExpression() {
        let targets = new Map();
        while (true) {
            push_1.push(targets, this.parseExpression());
            if (!this.parser.getStream().nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ',')) {
                break;
            }
        }
        return new node_1.TwingNode(targets);
    }
    // checks that the node only contains "constant" elements
    checkConstantExpression(node) {
        let self = this;
        if (!(node.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT || node.getType() === node_1.TwingNodeType.EXPRESSION_ARRAY || node.getType() === node_1.TwingNodeType.EXPRESSION_UNARY_NEG || node.getType() === node_1.TwingNodeType.EXPRESSION_UNARY_POS)) {
            return false;
        }
        for (let [k, n] of node.getNodes()) {
            if (!self.checkConstantExpression(n)) {
                return false;
            }
        }
        return true;
    }
    isUnary(token) {
        return token.test(token_1.TwingToken.OPERATOR_TYPE) && this.unaryOperators.has(token.getValue());
    }
    isBinary(token) {
        return token.test(token_1.TwingToken.OPERATOR_TYPE) && this.binaryOperators.has(token.getValue());
    }
    getTest(line) {
        let stream = this.parser.getStream();
        let name = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
        let test = this.env.getTest(name);
        if (test) {
            return [name, test];
        }
        if (stream.test(token_1.TwingToken.NAME_TYPE)) {
            // try 2-words tests
            name = name + ' ' + this.parser.getCurrentToken().getValue();
            let test = this.env.getTest(name);
            if (test) {
                stream.next();
                return [name, test];
            }
        }
        let e = new syntax_1.TwingErrorSyntax(`Unknown "${name}" test.`, line, stream.getSourceContext());
        e.addSuggestions(name, [...this.env.getTests().keys()]);
        throw e;
    }
    getFunctionExpressionFactory(name, line, column) {
        let function_ = this.env.getFunction(name);
        if (!function_) {
            let e = new syntax_1.TwingErrorSyntax(`Unknown "${name}" function.`, line, this.parser.getStream().getSourceContext());
            e.addSuggestions(name, Array.from(this.env.getFunctions().keys()));
            throw e;
        }
        if (function_.isDeprecated()) {
            let message = `Twing Function "${function_.getName()}" is deprecated`;
            if (typeof function_.getDeprecatedVersion() !== 'boolean') {
                message += ` since version ${function_.getDeprecatedVersion()}`;
            }
            if (function_.getAlternative()) {
                message += `. Use "${function_.getAlternative()}" instead`;
            }
            let src = this.parser.getStream().getSourceContext();
            message += ` in ${src.getPath() ? src.getPath() : src.getName()} at line ${line}.`;
            process.stdout.write(message);
        }
        return function_.getExpressionFactory();
    }
    getFilterExpressionFactory(name, line, column) {
        let filter = this.env.getFilter(name);
        if (!filter) {
            let e = new syntax_1.TwingErrorSyntax(`Unknown "${name}" filter.`, line, this.parser.getStream().getSourceContext());
            e.addSuggestions(name, Array.from(this.env.getFilters().keys()));
            throw e;
        }
        if (filter.isDeprecated()) {
            let message = `Twing Filter "${filter.getName()}" is deprecated`;
            if (typeof filter.getDeprecatedVersion() !== 'boolean') {
                message += ` since version ${filter.getDeprecatedVersion()}`;
            }
            if (filter.getAlternative()) {
                message += `. Use "${filter.getAlternative()}" instead`;
            }
            let src = this.parser.getStream().getSourceContext();
            message += ` in ${src.getPath() ? src.getPath() : src.getName()} at line ${line}.`;
            process.stdout.write(message);
        }
        return filter.getExpressionFactory();
    }
}
exports.TwingExpressionParser = TwingExpressionParser;
// @todo: should be a separate enum
TwingExpressionParser.OPERATOR_LEFT = 'OPERATOR_LEFT';
TwingExpressionParser.OPERATOR_RIGHT = 'OPERATOR_RIGHT';

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer, __webpack_require__(22)))

/***/ }),
/* 185 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Lexes a template string.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
const token_1 = __webpack_require__(109);
const token_stream_1 = __webpack_require__(261);
const syntax_1 = __webpack_require__(112);
let preg_quote = __webpack_require__(448);
let rtrim = __webpack_require__(262);
let merge = __webpack_require__(152);
let safeCChars = ['b', 'f', 'n', 'r', 't', 'v', '0', '\'', '"', '\\'];
let stripcslashes = function (string) {
    return string.replace(/\\(.)/g, function (match, char) {
        if (safeCChars.includes(char)) {
            return new Function('return "' + match + '"')();
        }
        else {
            return char;
        }
    });
};
class TwingLexer {
    constructor(env, options = {}) {
        this.env = env;
        this.options = merge({
            interpolation: ['#{', '}'],
            tag_block: ['{%', '%}'],
            tag_comment: ['{#', '#}'],
            tag_variable: ['{{', '}}'],
            whitespace_trim: '-',
            whitespace_line_trim: '~',
            whitespace_line_chars: ' \\t\\0\\x0B',
        }, options);
        this.regexes = {
            interpolation_end: new RegExp('^\\s*' + this.options.interpolation[1]),
            interpolation_start: new RegExp('^' + this.options.interpolation[0] + '\\s*'),
            lex_block: new RegExp('^\\s*' +
                '(?:' +
                this.options.whitespace_trim + this.options.tag_block[1] + '\\s*\\n?' +
                '|' +
                this.options.whitespace_line_trim + this.options.tag_block[1] + '[' + this.options.whitespace_line_chars + ']*' +
                '|' +
                this.options.tag_block[1] + '\\n?' +
                ')'),
            lex_block_line: new RegExp('^\\s*line\\s+(\\d+)\\s*' + this.options.tag_block[1]),
            lex_block_raw: new RegExp('^\\s*' +
                'verbatim' +
                '\\s*' +
                '(?:' +
                this.options.whitespace_trim + this.options.tag_block[1] + '\\s*' +
                '|' +
                this.options.whitespace_line_trim + this.options.tag_block[1] + '[' + this.options.whitespace_line_chars + ']*' +
                '|' +
                this.options.tag_block[1] +
                ')'),
            lex_comment: new RegExp('(?:' +
                this.options.whitespace_trim + this.options.tag_comment[1] + '\\s*' +
                '|' +
                this.options.whitespace_line_trim + this.options.tag_comment[1] + '[' + this.options.whitespace_line_chars + ']*' +
                '|' +
                this.options.tag_comment[1] + '\\n?' +
                ')'),
            lex_raw_data: new RegExp(this.options.tag_block[0] +
                '(' +
                this.options.whitespace_trim +
                '|' +
                this.options.whitespace_line_trim +
                ')?\\s*' +
                '(?:endverbatim)' +
                '\\s*' +
                '(?:' +
                this.options.whitespace_trim + this.options.tag_block[1] + '\\s*' +
                '|' +
                this.options.whitespace_line_trim + this.options.tag_block[1] + '[' + this.options.whitespace_line_chars + ']*' +
                '|' +
                this.options.tag_block[1] +
                ')'),
            lex_tokens_start: new RegExp('(' +
                this.options.tag_variable[0] + '|' +
                this.options.tag_block[0] + '|' +
                this.options.tag_comment[0] +
                ')(' +
                this.options.whitespace_trim +
                '|' +
                this.options.whitespace_line_trim +
                ')?', 'g'),
            lex_var: new RegExp('^\\s*' +
                '(?:' +
                this.options.whitespace_trim + this.options.tag_variable[1] + '\\s*' +
                '|' +
                this.options.whitespace_line_trim + this.options.tag_variable[1] + '[' + this.options.whitespace_line_chars + ']*' +
                '|' +
                this.options.tag_variable[1] +
                ')'),
            operator: this.getOperatorRegEx()
        };
    }
    tokenize(source) {
        this.source = source;
        // in PHP str_replace returns an empty string if called on a non-string object
        if (typeof source.getCode() !== 'string') {
            this.code = '';
        }
        else {
            this.code = source.getCode().replace(/\r\n|\r/g, '\n');
        }
        this.cursor = 0;
        this.end = this.code.length;
        this.lineno = 1;
        this.columnno = 1;
        this.tokens = [];
        this.state = TwingLexer.STATE_DATA;
        this.states = [];
        this.brackets = [];
        this.position = -1;
        this.positions = [];
        // find all token starts in one go
        let match;
        while ((match = this.regexes.lex_tokens_start.exec(this.code)) !== null) {
            this.positions.push(match);
        }
        while (this.cursor < this.end) {
            // dispatch to the lexing functions depending on the current state
            // https://stackoverflow.com/questions/45197320/typescript-switch-statement-throws-not-comparable-to-type-error
            switch (+this.state) {
                case TwingLexer.STATE_DATA:
                    this.lexData();
                    break;
                case TwingLexer.STATE_BLOCK:
                    this.lexBlock();
                    break;
                case TwingLexer.STATE_VAR:
                    this.lexVar();
                    break;
                case TwingLexer.STATE_STRING:
                    this.lexString();
                    break;
                case TwingLexer.STATE_INTERPOLATION:
                    this.lexInterpolation();
                    break;
            }
        }
        this.pushToken(token_1.TwingToken.EOF_TYPE);
        if (this.brackets.length > 0) {
            let bracket = this.brackets.pop();
            let expect = bracket.value;
            let lineno = bracket.line;
            throw new syntax_1.TwingErrorSyntax(`Unclosed "${expect}".`, lineno, this.source);
        }
        return new token_stream_1.TwingTokenStream(this.tokens, this.source);
    }
    lexData() {
        // if no matches are left we return the rest of the template as simple text token
        if (this.position === (this.positions.length - 1)) {
            let text = this.code.substring(this.cursor);
            this.pushToken(token_1.TwingToken.TEXT_TYPE, text);
            this.moveCursor(text);
            this.moveCoordinates(text);
            return;
        }
        // Find the first token after the current cursor
        let position = this.positions[++this.position];
        while (position.index < this.cursor) {
            if (this.position == (this.positions.length - 1)) {
                return;
            }
            position = this.positions[++this.position];
        }
        // push the template text first
        let text;
        let textContent;
        text = textContent = this.code.substr(this.cursor, position.index - this.cursor);
        if (this.positions[this.position][2]) {
            if (this.positions[this.position][2] === this.options.whitespace_trim) {
                // whitespace_trim detected ({%-, {{- or {#-)
                text = rtrim(text);
            }
            else {
                // whitespace_line_trim detected ({%~, {{~ or {#~)
                text = rtrim(text, this.options.whitespace_line_chars);
            }
        }
        this.pushToken(token_1.TwingToken.TEXT_TYPE, text);
        this.moveCoordinates(textContent);
        this.moveCursor(textContent + position[0]);
        switch (position[1]) {
            case this.options.tag_comment[0]:
                this.pushToken(token_1.TwingToken.COMMENT_START_TYPE);
                this.moveCoordinates(position[0]);
                this.lexComment();
                break;
            case this.options.tag_block[0]:
                // raw data?
                let match;
                if ((match = this.regexes.lex_block_raw.exec(this.code.substring(this.cursor))) !== null) {
                    this.moveCursor(match[0]);
                    this.moveCoordinates(position[0] + match[0]);
                    this.lexRawData();
                }
                // {% line \d+ %}
                else if ((match = this.regexes.lex_block_line.exec(this.code.substring(this.cursor))) !== null) {
                    this.moveCursor(match[0]);
                    this.moveCoordinates(position[0] + match[0]);
                    this.lineno = parseInt(match[1]);
                }
                else {
                    this.pushToken(token_1.TwingToken.BLOCK_START_TYPE);
                    this.moveCoordinates(position[0]);
                    this.pushState(TwingLexer.STATE_BLOCK);
                    this.currentVarBlockLine = this.lineno;
                }
                break;
            case this.options.tag_variable[0]:
                this.pushToken(token_1.TwingToken.VAR_START_TYPE);
                this.moveCoordinates(position[0]);
                this.pushState(TwingLexer.STATE_VAR);
                this.currentVarBlockLine = this.lineno;
                break;
        }
    }
    lexBlock() {
        let string = this.code.substring(this.cursor);
        let match;
        if ((this.brackets.length < 1) && ((match = this.regexes.lex_block.exec(string)) !== null)) {
            this.pushToken(token_1.TwingToken.BLOCK_END_TYPE);
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
            this.popState();
        }
        else {
            this.lexExpression();
        }
    }
    lexVar() {
        let match;
        if ((this.brackets.length < 1) && ((match = this.regexes.lex_var.exec(this.code.substring(this.cursor))) !== null)) {
            let text = this.handleLeadingLineFeeds(match[0]);
            this.pushToken(token_1.TwingToken.VAR_END_TYPE);
            this.moveCursor(text);
            this.moveCoordinates(text);
            this.popState();
        }
        else {
            this.lexExpression();
        }
    }
    lexExpression() {
        let match;
        let candidate = this.code.substring(this.cursor);
        let punctuationCandidate;
        // whitespace
        if ((match = /^\s+/.exec(candidate)) !== null) {
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
            if (this.cursor >= this.end) {
                throw new syntax_1.TwingErrorSyntax(`Unclosed "${this.state === TwingLexer.STATE_BLOCK ? 'block' : 'variable'}".`, this.currentVarBlockLine, this.source);
            }
        }
        candidate = this.code.substring(this.cursor);
        punctuationCandidate = candidate.substr(0, 1);
        // arrow function
        if (this.code[this.cursor] === '=' && this.code[this.cursor + 1] === '>') {
            this.pushToken(token_1.TwingToken.ARROW_TYPE, '=>');
            this.moveCursor('=>');
            this.moveCoordinates('=>');
        }
        // operators
        else if ((match = this.regexes.operator.exec(candidate)) !== null) {
            let tokenValue = match[0].replace(/\s+/, ' ');
            this.pushToken(token_1.TwingToken.OPERATOR_TYPE, tokenValue);
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
        }
        // names
        else if ((match = TwingLexer.REGEX_NAME.exec(candidate)) !== null) {
            this.pushToken(token_1.TwingToken.NAME_TYPE, match[0]);
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
        }
        // numbers
        else if ((match = TwingLexer.REGEX_NUMBER.exec(candidate)) !== null) {
            this.pushToken(token_1.TwingToken.NUMBER_TYPE, Number(match[0]));
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
        }
        // punctuation
        else if (TwingLexer.PUNCTUATION.indexOf(punctuationCandidate) > -1) {
            // opening bracket
            if ('([{'.indexOf(punctuationCandidate) > -1) {
                this.brackets.push({
                    value: punctuationCandidate,
                    line: this.lineno
                });
            }
            // closing bracket
            else if (')]}'.indexOf(punctuationCandidate) > -1) {
                if (this.brackets.length < 1) {
                    throw new syntax_1.TwingErrorSyntax(`Unexpected "${punctuationCandidate}".`, this.lineno, this.source);
                }
                let bracket = this.brackets.pop();
                let lineno = bracket.line;
                let expect = bracket.value
                    .replace('(', ')')
                    .replace('[', ']')
                    .replace('{', '}');
                if (punctuationCandidate != expect) {
                    throw new syntax_1.TwingErrorSyntax(`Unclosed "${expect}".`, lineno, this.source);
                }
            }
            this.pushToken(token_1.TwingToken.PUNCTUATION_TYPE, punctuationCandidate);
            this.cursor++;
            this.columnno++;
        }
        // strings
        else if ((match = TwingLexer.REGEX_STRING.exec(candidate)) !== null) {
            this.pushToken(token_1.TwingToken.STRING_TYPE, stripcslashes(match[0].slice(1, -1)));
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
        }
        // opening double quoted string
        else if ((match = TwingLexer.REGEX_DQ_STRING_DELIM.exec(candidate)) !== null) {
            this.brackets.push({
                value: '"',
                line: this.lineno
            });
            this.pushState(TwingLexer.STATE_STRING);
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
        }
        // unlexable
        else {
            throw new syntax_1.TwingErrorSyntax(`Unexpected character "${candidate}" in "${this.code}".`, this.lineno, this.source);
        }
    }
    lexRawData() {
        let match = this.regexes.lex_raw_data.exec(this.code.substring(this.cursor));
        if (!match) {
            throw new syntax_1.TwingErrorSyntax('Unexpected end of file: Unclosed "verbatim" block.', this.lineno, this.source);
        }
        let text = this.code.substr(this.cursor, match.index);
        this.moveCursor(text + match[0]);
        if (match[1]) {
            if (match[1] === this.options.whitespace_trim) {
                // whitespace_trim detected ({%-, {{- or {#-)
                text = rtrim(text);
            }
            else {
                // whitespace_line_trim detected ({%~, {{~ or {#~)
                // don't trim \r and \n
                text = rtrim(text, " \t\0\x0B");
            }
        }
        this.pushToken(token_1.TwingToken.TEXT_TYPE, text);
        this.moveCoordinates(text + match[0]);
    }
    lexComment() {
        let match = this.regexes.lex_comment.exec(this.code.substring(this.cursor));
        if (!match) {
            throw new syntax_1.TwingErrorSyntax('Unclosed comment.', this.lineno, this.source);
        }
        let text = this.code.substr(this.cursor, match.index);
        this.pushToken(token_1.TwingToken.TEXT_TYPE, text);
        this.moveCursor(text);
        this.moveCoordinates(text);
        this.pushToken(token_1.TwingToken.COMMENT_END_TYPE);
        this.moveCursor(match[0]);
        this.moveCoordinates(match[0]);
    }
    lexString() {
        let match;
        if ((match = this.regexes.interpolation_start.exec(this.code.substring(this.cursor))) !== null) {
            this.brackets.push({
                value: this.options.interpolation[0],
                line: this.lineno
            });
            this.pushToken(token_1.TwingToken.INTERPOLATION_START_TYPE);
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
            this.pushState(TwingLexer.STATE_INTERPOLATION);
        }
        else if (((match = TwingLexer.REGEX_DQ_STRING_PART.exec(this.code.substring(this.cursor))) !== null) && (match[0].length > 0)) {
            this.pushToken(token_1.TwingToken.STRING_TYPE, stripcslashes(match[0]));
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
        }
        // unit: else path not coverable
        // else if ((TwingLexer.REGEX_DQ_STRING_DELIM.exec(this.code.substring(this.cursor))) !== null) {
        else {
            let { value: expect, line: lineno } = this.brackets.pop();
            // unit: if path not coverable
            // if (this.code[this.cursor] != '"') {
            //     throw new TwingErrorSyntax(`Unclsosed "%${expect}".`, lineno, this.source);
            // }
            this.popState();
            this.cursor++;
            this.columnno++;
        }
    }
    lexInterpolation() {
        let match;
        let bracket = this.brackets[this.brackets.length - 1];
        if (this.options.interpolation[0] === bracket.value && (match = this.regexes.interpolation_end.exec(this.code.substring(this.cursor))) !== null) {
            this.brackets.pop();
            this.pushToken(token_1.TwingToken.INTERPOLATION_END_TYPE);
            this.moveCursor(match[0]);
            this.moveCoordinates(match[0]);
            this.popState();
        }
        else {
            this.lexExpression();
        }
    }
    handleLeadingLineFeeds(text) {
        let match = /^\n+/.exec(text);
        if (match) {
            let lineno = this.lineno;
            this.moveCoordinates(match[0]);
            let lineCount = this.lineno - lineno;
            this.cursor += lineCount;
            text = text.substring(lineCount);
        }
        return text;
    }
    moveCursor(text) {
        this.cursor += text.length;
    }
    moveCoordinates(text) {
        this.columnno += text.length;
        let lines = text.split('\n');
        let lineCount = lines.length - 1;
        if (lineCount > 0) {
            this.lineno += lineCount;
            this.columnno = 1 + lines[lineCount].length;
        }
    }
    getOperatorRegEx() {
        let operators = Array.from([
            ...['='],
            ...this.env.getUnaryOperators().keys(),
            ...this.env.getBinaryOperators().keys()
        ]);
        operators.sort(function (a, b) {
            return a.length > b.length ? -1 : 1;
        });
        let patterns = [];
        operators.forEach(function (operator) {
            let length = operator.length;
            let pattern;
            // an operator that ends with a character must be followed by
            // a whitespace or a parenthesis
            if (new RegExp('[A-Za-z]').test(operator[length - 1])) {
                pattern = preg_quote(operator, '/') + '(?=[\\s()])';
            }
            else {
                pattern = preg_quote(operator, '/');
            }
            // an operator with a space can be any amount of whitespaces
            pattern = pattern.replace(/\s+/, '\\s+');
            patterns.push('^' + pattern);
        });
        return new RegExp(patterns.join('|'));
    }
    ;
    pushToken(type, value = null) {
        if ((token_1.TwingToken.TEXT_TYPE === type) && (value.length < 1)) {
            return;
        }
        this.tokens.push(new token_1.TwingToken(type, value, this.lineno, this.columnno));
    }
    pushState(state) {
        this.states.push(this.state);
        this.state = state;
    }
    /**
     * @return TwingLexerState
     */
    popState() {
        // unit: if path not coverable
        // if (this.states.length === 0) {
        //     throw new Error('Cannot pop state without a previous state.');
        // }
        this.state = this.states.pop();
    }
}
exports.TwingLexer = TwingLexer;
TwingLexer.STATE_DATA = 0;
TwingLexer.STATE_BLOCK = 1;
TwingLexer.STATE_VAR = 2;
TwingLexer.STATE_STRING = 3;
TwingLexer.STATE_INTERPOLATION = 4;
TwingLexer.REGEX_NAME = /^[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*/;
TwingLexer.REGEX_NUMBER = /^[0-9]+(?:\.[0-9]+)?/;
TwingLexer.REGEX_STRING = /^"([^#"\\]*(?:\\.[^#"\\]*)*)"|^'([^'\\]*(?:\\.[^'\\]*)*)'/;
TwingLexer.REGEX_DQ_STRING_DELIM = /^"/;
TwingLexer.REGEX_DQ_STRING_PART = /^[^#"\\]*(?:(?:\\\\.|#(?!{))[^#"\\]*)*/;
TwingLexer.PUNCTUATION = '()[]{}?:.,|';


/***/ }),
/* 186 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function array_merge() {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/array_merge/
  // original by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: Nate
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  //    input by: josh
  //   example 1: var $arr1 = {"color": "red", 0: 2, 1: 4}
  //   example 1: var $arr2 = {0: "a", 1: "b", "color": "green", "shape": "trapezoid", 2: 4}
  //   example 1: array_merge($arr1, $arr2)
  //   returns 1: {"color": "green", 0: 2, 1: 4, 2: "a", 3: "b", "shape": "trapezoid", 4: 4}
  //   example 2: var $arr1 = []
  //   example 2: var $arr2 = {1: "data"}
  //   example 2: array_merge($arr1, $arr2)
  //   returns 2: {0: "data"}

  var args = Array.prototype.slice.call(arguments);
  var argl = args.length;
  var arg;
  var retObj = {};
  var k = '';
  var argil = 0;
  var j = 0;
  var i = 0;
  var ct = 0;
  var toStr = Object.prototype.toString;
  var retArr = true;

  for (i = 0; i < argl; i++) {
    if (toStr.call(args[i]) !== '[object Array]') {
      retArr = false;
      break;
    }
  }

  if (retArr) {
    retArr = [];
    for (i = 0; i < argl; i++) {
      retArr = retArr.concat(args[i]);
    }
    return retArr;
  }

  for (i = 0, ct = 0; i < argl; i++) {
    arg = args[i];
    if (toStr.call(arg) === '[object Array]') {
      for (j = 0, argil = arg.length; j < argil; j++) {
        retObj[ct++] = arg[j];
      }
    } else {
      for (k in arg) {
        if (arg.hasOwnProperty(k)) {
          if (parseInt(k, 10) + '' === k) {
            retObj[ct++] = arg[k];
          } else {
            retObj[k] = arg[k];
          }
        }
      }
    }
  }

  return retObj;
};
//# sourceMappingURL=array_merge.js.map

/***/ }),
/* 187 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionBinaryConcat extends binary_1.TwingNodeExpressionBinary {
    constructor(left, right, lineno, columno) {
        super(left, right, lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_BINARY_CONCAT;
    }
    operator(compiler) {
        return compiler.raw('+');
    }
}
exports.TwingNodeExpressionBinaryConcat = TwingNodeExpressionBinaryConcat;


/***/ }),
/* 188 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const iterator_to_map_1 = __webpack_require__(128);
const output_buffering_1 = __webpack_require__(131);
class TwingTemplateWrapper {
    /**
     * This method is for internal use only and should never be called
     * directly (use TwingEnvironment::load() instead).
     *
     * @internal
     */
    constructor(env, template) {
        this.env = env;
        this.template = template;
    }
    /**
     * Renders the template.
     *
     * @param {*} context A hash of parameters to pass to the template
     *
     * @returns {string} The rendered template
     */
    render(context = {}) {
        return this.template.render(context);
    }
    /**
     * Checks if a block is defined.
     *
     * @param {string} name The block name
     * @param {*} context A hash of parameters to pass to the template
     *
     * @returns {boolean}
     */
    hasBlock(name, context = {}) {
        return this.template.hasBlock(name, context);
    }
    /**
     * Returns defined block names in the template.
     *
     * @param {*} context A hash of parameters to pass to the template
     *
     * @returns {Array<string>} An array of defined template block names
     */
    getBlockNames(context = {}) {
        return this.template.getBlockNames(context);
    }
    /**
     * Renders a template block.
     *
     * @param {string} name The block name to render
     * @param {*} context A hash of parameters to pass to the template
     *
     * @returns {string} The rendered block
     */
    renderBlock(name, context = {}) {
        if (!(context instanceof Map)) {
            context = iterator_to_map_1.iteratorToMap(context);
        }
        context = this.env.mergeGlobals(context);
        let level = output_buffering_1.TwingOutputBuffering.obGetLevel();
        output_buffering_1.TwingOutputBuffering.obStart();
        try {
            this.template.displayBlock(name, context);
        }
        catch (e) {
            while (output_buffering_1.TwingOutputBuffering.obGetLevel() > level) {
                output_buffering_1.TwingOutputBuffering.obEndClean();
            }
            throw e;
        }
        return output_buffering_1.TwingOutputBuffering.obGetClean();
    }
    /**
     * Displays a template block.
     *
     * @param {string} name The block name to render
     * @param {*} context A hash of parameters to pass to the template
     */
    displayBlock(name, context = {}) {
        if (!(context instanceof Map)) {
            context = iterator_to_map_1.iteratorToMap(context);
        }
        return this.template.displayBlock(name, this.env.mergeGlobals(context));
    }
    /**
     *
     * @returns {TwingSource}
     */
    getSourceContext() {
        return this.template.getSourceContext();
    }
    traceableDisplayBlock(lineno, source) {
        return this.template.traceableMethod(this.displayBlock.bind(this), lineno, source);
    }
    ;
    traceableDisplayParentBlock(lineno, source) {
        return this.template.traceableDisplayParentBlock(lineno, source);
    }
    ;
    traceableRenderBlock(lineno, source) {
        return this.template.traceableMethod(this.renderBlock.bind(this), lineno, source);
    }
    traceableRenderParentBlock(lineno, source) {
        return this.template.traceableRenderParentBlock(lineno, source);
    }
    traceableHasBlock(lineno, source) {
        return this.template.traceableHasBlock(lineno, source);
    }
}
exports.TwingTemplateWrapper = TwingTemplateWrapper;


/***/ }),
/* 189 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionBlockReference extends expression_1.TwingNodeExpression {
    constructor(name, template, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('name', name);
        if (template) {
            nodes.set('template', template);
        }
        let attributes = new Map([
            ['is_defined_test', false],
            ['output', false]
        ]);
        super(nodes, attributes, lineno, columnno, tag);
        this.type = node_1.TwingNodeType.EXPRESSION_BLOCK_REFERENCE;
    }
    compile(compiler) {
        if (this.getAttribute('is_defined_test')) {
            this.compileTemplateCall(compiler, 'traceableHasBlock');
        }
        else {
            if (this.getAttribute('output')) {
                compiler.addDebugInfo(this);
                this
                    .compileTemplateCall(compiler, `traceableDisplayBlock`)
                    .raw(";\n");
            }
            else {
                this.compileTemplateCall(compiler, 'traceableRenderBlock');
            }
        }
    }
    compileTemplateCall(compiler, method) {
        if (!this.hasNode('template')) {
            compiler.write('this');
        }
        else {
            compiler
                .write('this.loadTemplate(')
                .subcompile(this.getNode('template'))
                .raw(', ')
                .repr(this.getTemplateName())
                .raw(', ')
                .repr(this.getTemplateLine())
                .raw(')');
        }
        compiler.raw(`.${method}(${this.getTemplateLine()}, this.source)`);
        this.compileBlockArguments(compiler);
        return compiler;
    }
    compileBlockArguments(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('name'))
            .raw(', context');
        if (!this.hasNode('template')) {
            compiler.raw(', blocks');
        }
        return compiler.raw(')');
    }
}
exports.TwingNodeExpressionBlockReference = TwingNodeExpressionBlockReference;


/***/ }),
/* 190 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryAnd extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('!!');
        super.compile(compiler);
    }
    operator(compiler) {
        return compiler.raw('&&');
    }
}
exports.TwingNodeExpressionBinaryAnd = TwingNodeExpressionBinaryAnd;


/***/ }),
/* 191 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Represents an import node.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
const node_1 = __webpack_require__(107);
class TwingNodeImport extends node_1.TwingNode {
    constructor(expr, varName, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('expr', expr);
        nodes.set('var', varName);
        super(nodes, new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.IMPORT;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .subcompile(this.getNode('var'), false)
            .raw(' = ');
        if (this.getNode('expr').getType() === node_1.TwingNodeType.EXPRESSION_NAME && this.getNode('expr').getAttribute('name') === '_self') {
            compiler.raw('this');
        }
        else {
            compiler
                .raw('this.loadTemplate(')
                .subcompile(this.getNode('expr'))
                .raw(', ')
                .repr(this.getTemplateName())
                .raw(', ')
                .repr(this.getTemplateLine())
                .raw(')');
        }
        compiler.raw(";\n");
    }
}
exports.TwingNodeImport = TwingNodeImport;


/***/ }),
/* 192 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
const constant_1 = __webpack_require__(115);
class TwingNodeSet extends node_1.TwingNode {
    constructor(capture, names, values, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('names', names);
        nodes.set('values', values);
        let attributes = new Map();
        attributes.set('capture', capture);
        attributes.set('safe', false);
        super(nodes, attributes, lineno, columnno, tag);
        this.type = node_1.TwingNodeType.SET;
        this.TwingNodeCaptureInterfaceImpl = this;
        /*
         * Optimizes the node when capture is used for a large block of text.
         *
         * {% set foo %}foo{% endset %} is compiled to $context['foo'] = new Twig_Markup("foo");
         */
        if (this.getAttribute('capture')) {
            this.setAttribute('safe', true);
            let values = this.getNode('values');
            if (values.getType() === node_1.TwingNodeType.TEXT) {
                this.setNode('values', new constant_1.TwingNodeExpressionConstant(values.getAttribute('data'), values.getTemplateLine(), values.getTemplateColumn()));
                this.setAttribute('capture', false);
            }
        }
    }
    compile(compiler) {
        compiler.addDebugInfo(this);
        if (this.getNode('names').getNodes().size > 1) {
            compiler.write('[');
            for (let [idx, node] of this.getNode('names').getNodes()) {
                if (idx > 0) {
                    compiler.raw(', ');
                }
                compiler
                    .subcompile(node);
            }
            compiler.raw(']');
        }
        else {
            if (this.getAttribute('capture')) {
                compiler
                    .write("Runtime.obStart();\n")
                    .subcompile(this.getNode('values'));
            }
            compiler.subcompile(this.getNode('names'), false);
            if (this.getAttribute('capture')) {
                compiler
                    .raw(" = (() => {let tmp = Runtime.obGetClean(); return tmp === '' ? '' : new Runtime.TwingMarkup(tmp, this.env.getCharset());})()");
            }
        }
        if (!this.getAttribute('capture')) {
            compiler.raw(' = ');
            if (this.getNode('names').getNodes().size > 1) {
                compiler.raw('[');
                for (let [idx, value] of this.getNode('values').getNodes()) {
                    if (idx > 0) {
                        compiler.raw(', ');
                    }
                    compiler
                        .subcompile(value);
                }
                compiler.raw(']');
            }
            else {
                if (this.getAttribute('safe')) {
                    compiler
                        .raw("(() => {let tmp = ")
                        .subcompile(this.getNode('values'))
                        .raw("; return tmp === '' ? '' : new Runtime.TwingMarkup(tmp, this.env.getCharset());})()");
                }
                else {
                    compiler.subcompile(this.getNode('values'));
                }
            }
        }
        compiler.raw(';\n');
    }
}
exports.TwingNodeSet = TwingNodeSet;


/***/ }),
/* 193 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeBlock extends node_1.TwingNode {
    constructor(name, body, lineno, columnno, tag = null) {
        super(new Map([['body', body]]), new Map([['name', name]]), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.BLOCK;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write(`block_${this.getAttribute('name')}(context, blocks = new Map()) {\n`)
            .indent();
        compiler
            .subcompile(this.getNode('body'))
            .outdent()
            .write("}\n\n");
    }
}
exports.TwingNodeBlock = TwingNodeBlock;


/***/ }),
/* 194 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const include_1 = __webpack_require__(195);
class TwingTokenParserInclude extends token_parser_1.TwingTokenParser {
    parse(token) {
        let expr = this.parser.getExpressionParser().parseExpression();
        let parsedArguments = this.parseArguments();
        return new include_1.TwingNodeInclude(expr, parsedArguments.variables, parsedArguments.only, parsedArguments.ignoreMissing, token.getLine(), token.getColumn(), this.getTag());
    }
    getTag() {
        return 'include';
    }
    /**
     *
     * @returns {{variables: TwingNodeExpression; only: boolean; ignoreMissing: boolean}}
     */
    parseArguments() {
        let stream = this.parser.getStream();
        let ignoreMissing = false;
        if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'ignore')) {
            stream.expect(token_1.TwingToken.NAME_TYPE, 'missing');
            ignoreMissing = true;
        }
        let variables = null;
        if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'with')) {
            variables = this.parser.getExpressionParser().parseExpression();
        }
        let only = false;
        if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'only')) {
            only = true;
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        return {
            variables: variables,
            only: only,
            ignoreMissing: ignoreMissing
        };
    }
}
exports.TwingTokenParserInclude = TwingTokenParserInclude;


/***/ }),
/* 195 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeInclude extends node_1.TwingNode {
    constructor(expr, variables, only, ignoreMissing, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('expr', expr);
        if (variables !== null) {
            nodes.set('variables', variables);
        }
        super(nodes, new Map([['only', only], ['ignore_missing', ignoreMissing]]), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.INCLUDE;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this);
        if (this.getAttribute('ignore_missing')) {
            compiler
                .write('(() => {\n')
                .indent()
                .write('let template = null;\n')
                .write('try {\n')
                .indent()
                .write('template = ');
            this.addGetTemplate(compiler);
            compiler
                .raw(';\n')
                .outdent()
                .write('}\n')
                .write('catch (e) {\n')
                .indent()
                .write('if (e instanceof Runtime.TwingErrorLoader) {\n')
                .indent()
                .write('// ignore missing template\n')
                .outdent()
                .write('}\n')
                .write('else {\n')
                .indent()
                .write('throw e;\n')
                .outdent()
                .write('}\n')
                .outdent()
                .write('}\n')
                .write('if (template) {\n')
                .indent()
                .write('template.display(');
            this.addTemplateArguments(compiler);
            compiler
                .raw(');\n')
                .outdent()
                .write('}\n')
                .outdent()
                .write('})();\n');
        }
        else {
            this.addGetTemplate(compiler);
            compiler.raw('.display(');
            this.addTemplateArguments(compiler);
            compiler.raw(');\n');
        }
    }
    addGetTemplate(compiler) {
        compiler
            .write('this.loadTemplate(')
            .subcompile(this.getNode('expr'))
            .raw(', ')
            .repr(this.getTemplateName())
            .raw(', ')
            .repr(this.getTemplateLine())
            .raw(')');
    }
    addTemplateArguments(compiler) {
        if (!this.hasNode('variables')) {
            compiler.raw(this.getAttribute('only') === false ? 'context' : 'new Map()');
        }
        else if (this.getAttribute('only') === false) {
            compiler
                .raw('Runtime.merge(context, ')
                .subcompile(this.getNode('variables'))
                .raw(')');
        }
        else {
            compiler.subcompile(this.getNode('variables'));
        }
    }
}
exports.TwingNodeInclude = TwingNodeInclude;


/***/ }),
/* 196 */
/***/ (function(module, exports) {

var toString = Object.prototype.toString;

module.exports = function kindOf(val) {
  if (val === void 0) return 'undefined';
  if (val === null) return 'null';

  var type = typeof val;
  if (type === 'boolean') return 'boolean';
  if (type === 'string') return 'string';
  if (type === 'number') return 'number';
  if (type === 'symbol') return 'symbol';
  if (type === 'function') {
    return isGeneratorFn(val) ? 'generatorfunction' : 'function';
  }

  if (isArray(val)) return 'array';
  if (isBuffer(val)) return 'buffer';
  if (isArguments(val)) return 'arguments';
  if (isDate(val)) return 'date';
  if (isError(val)) return 'error';
  if (isRegexp(val)) return 'regexp';

  switch (ctorName(val)) {
    case 'Symbol': return 'symbol';
    case 'Promise': return 'promise';

    // Set, Map, WeakSet, WeakMap
    case 'WeakMap': return 'weakmap';
    case 'WeakSet': return 'weakset';
    case 'Map': return 'map';
    case 'Set': return 'set';

    // 8-bit typed arrays
    case 'Int8Array': return 'int8array';
    case 'Uint8Array': return 'uint8array';
    case 'Uint8ClampedArray': return 'uint8clampedarray';

    // 16-bit typed arrays
    case 'Int16Array': return 'int16array';
    case 'Uint16Array': return 'uint16array';

    // 32-bit typed arrays
    case 'Int32Array': return 'int32array';
    case 'Uint32Array': return 'uint32array';
    case 'Float32Array': return 'float32array';
    case 'Float64Array': return 'float64array';
  }

  if (isGeneratorObj(val)) {
    return 'generator';
  }

  // Non-plain objects
  type = toString.call(val);
  switch (type) {
    case '[object Object]': return 'object';
    // iterators
    case '[object Map Iterator]': return 'mapiterator';
    case '[object Set Iterator]': return 'setiterator';
    case '[object String Iterator]': return 'stringiterator';
    case '[object Array Iterator]': return 'arrayiterator';
  }

  // other
  return type.slice(8, -1).toLowerCase().replace(/\s/g, '');
};

function ctorName(val) {
  return typeof val.constructor === 'function' ? val.constructor.name : null;
}

function isArray(val) {
  if (Array.isArray) return Array.isArray(val);
  return val instanceof Array;
}

function isError(val) {
  return val instanceof Error || (typeof val.message === 'string' && val.constructor && typeof val.constructor.stackTraceLimit === 'number');
}

function isDate(val) {
  if (val instanceof Date) return true;
  return typeof val.toDateString === 'function'
    && typeof val.getDate === 'function'
    && typeof val.setDate === 'function';
}

function isRegexp(val) {
  if (val instanceof RegExp) return true;
  return typeof val.flags === 'string'
    && typeof val.ignoreCase === 'boolean'
    && typeof val.multiline === 'boolean'
    && typeof val.global === 'boolean';
}

function isGeneratorFn(name, val) {
  return ctorName(name) === 'GeneratorFunction';
}

function isGeneratorObj(val) {
  return typeof val.throw === 'function'
    && typeof val.return === 'function'
    && typeof val.next === 'function';
}

function isArguments(val) {
  try {
    if (typeof val.length === 'number' && typeof val.callee === 'function') {
      return true;
    }
  } catch (err) {
    if (err.message.indexOf('callee') !== -1) {
      return true;
    }
  }
  return false;
}

/**
 * If you need to support Safari 5-7 (8-10 yr-old browser),
 * take a look at https://github.com/feross/is-buffer
 */

function isBuffer(val) {
  if (val.constructor && typeof val.constructor.isBuffer === 'function') {
    return val.constructor.isBuffer(val);
  }
  return false;
}


/***/ }),
/* 197 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const error_1 = __webpack_require__(120);
class TwingCallableWrapper {
    constructor(name, callable) {
        this.name = name;
        this.callable = callable;
    }
    getName() {
        return this.name;
    }
    /**
     * @returns {Function}
     */
    getCallable() {
        return this.callable;
    }
    /**
     * Returns the traceable callable.
     *
     * @param {number} lineno
     * @param {TwingSource} source
     * @return {Function}
     */
    traceableCallable(lineno, source) {
        let callable = this.callable;
        return function () {
            try {
                return callable.apply(null, arguments);
            }
            catch (e) {
                if (e instanceof error_1.TwingError) {
                    if (e.getTemplateLine() === -1) {
                        e.setTemplateLine(lineno);
                        e.setSourceContext(source);
                    }
                }
                throw e;
            }
        };
    }
}
exports.TwingCallableWrapper = TwingCallableWrapper;


/***/ }),
/* 198 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryDiv extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('/');
    }
}
exports.TwingNodeExpressionBinaryDiv = TwingNodeExpressionBinaryDiv;


/***/ }),
/* 199 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Represents a do node.
 *
 * The do tag works exactly like the regular variable expression ({{ ... }}) just that it doesn't print anything:
 * {% do 1 + 2 %}
 *
 * @author Fabien Potencier <fabien@symfony.com>
 * @author Eric Morand <eric.morand@gmail.com>
 */
class TwingNodeDo extends node_1.TwingNode {
    constructor(expr, lineno, columnno, tag = null) {
        super(new Map([['expr', expr]]), new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.DO;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .subcompile(this.getNode('expr'), true)
            .raw(";\n");
    }
}
exports.TwingNodeDo = TwingNodeDo;


/***/ }),
/* 200 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
class TwingNodeExpressionTestNull extends test_1.TwingNodeExpressionTest {
    compile(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('node'))
            .raw(' === null)');
    }
}
exports.TwingNodeExpressionTestNull = TwingNodeExpressionTestNull;


/***/ }),
/* 201 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const filter_1 = __webpack_require__(161);
const callable_wrapper_1 = __webpack_require__(197);
let merge = __webpack_require__(152);
class TwingFilter extends callable_wrapper_1.TwingCallableWrapper {
    constructor(name, callable, options = {}) {
        super(name, callable);
        this.methodArguments = [];
        this.options = merge({
            'needs_environment': false,
            'needs_context': false,
            'needs_source': false,
            'is_variadic': false,
            'is_safe': null,
            'is_safe_callback': null,
            'pre_escape': null,
            'preserves_safety': null,
            'expression_factory': function (node, filterName, methodArguments, lineno, columnno, tag = null) {
                return new filter_1.TwingNodeExpressionFilter(node, filterName, methodArguments, lineno, columnno, tag);
            },
            'deprecated': false,
            'alternative': null,
        }, options);
    }
    /**
     *
     * @returns {Function}
     */
    getExpressionFactory() {
        return this.options.expression_factory;
    }
    setArguments(someArguments) {
        this.methodArguments = someArguments;
    }
    getArguments() {
        return this.methodArguments;
    }
    needsEnvironment() {
        return this.options.needs_environment;
    }
    needsContext() {
        return this.options.needs_context;
    }
    needsSource() {
        return this.options.needs_source;
    }
    /**
     *
     * @param {TwingNode} filterArgs
     * @returns boolean
     */
    getSafe(filterArgs) {
        if (this.options.is_safe) {
            return this.options.is_safe;
        }
        if (this.options.is_safe_callback) {
            return this.options.is_safe_callback.call(this, filterArgs);
        }
    }
    getPreservesSafety() {
        return this.options.preserves_safety;
    }
    getPreEscape() {
        return this.options.pre_escape;
    }
    isVariadic() {
        return this.options.is_variadic;
    }
    isDeprecated() {
        return this.options.deprecated;
    }
    /**
     *
     * @returns {string}
     */
    getDeprecatedVersion() {
        return this.options.deprecated;
    }
    /**
     *
     * @returns {TwingFilter}
     */
    getAlternative() {
        return this.options.alternative;
    }
}
exports.TwingFilter = TwingFilter;


/***/ }),
/* 202 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const locutusRange = __webpack_require__(465);
function range(low, high, step) {
    return locutusRange(low, high, step);
}
exports.range = range;


/***/ }),
/* 203 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function first(map) {
    return Array.from(map.values())[0];
}
exports.first = first;


/***/ }),
/* 204 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const source_map_1 = __webpack_require__(466);
class TwingSourceMapNode {
    /**
     * TwingSourceMapNode constructor
     *
     * @param {number} line 0-based
     * @param {number} column 0-based
     * @param {TwingSource} source
     * @param {string} name
     */
    constructor(line, column, source, name) {
        this._name = name;
        this._source = source;
        this._line = line;
        this._column = column;
        this._content = null;
        this._parent = null;
        this._children = [];
    }
    get name() {
        return this._name;
    }
    get source() {
        return this._source;
    }
    get line() {
        return this._line;
    }
    get column() {
        return this._column;
    }
    get content() {
        return this._content;
    }
    get parent() {
        return this._parent;
    }
    get children() {
        return this._children;
    }
    set content(content) {
        this._content = content;
    }
    addChild(child) {
        child._parent = this;
        this._children.push(child);
    }
    toSourceNode() {
        let chunks = null;
        if (this._children.length === 0) {
            chunks = this._content;
        }
        // source-map@6 types are faulty, we have to force-type chunks as any
        let sourceNode = new source_map_1.SourceNode(this._line, this._column, this._source.getPath(), chunks, this._name);
        sourceNode.setSourceContent(this._source.getPath(), this._source.getCode());
        for (let child of this._children) {
            sourceNode.add(child.toSourceNode());
        }
        return sourceNode;
    }
}
exports.TwingSourceMapNode = TwingSourceMapNode;


/***/ }),
/* 205 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const ksort_1 = __webpack_require__(181);
const push_1 = __webpack_require__(137);
class TwingNodeTraverser {
    /**
     *
     * @param {TwingEnvironment} env
     * @param {Array<TwingNodeVisitorInterface>} visitors
     */
    constructor(env, visitors = []) {
        this.visitors = new Map();
        let self = this;
        this.env = env;
        for (let visitor of visitors) {
            self.addVisitor(visitor);
        }
    }
    addVisitor(visitor) {
        if (!this.visitors.has(visitor.getPriority())) {
            this.visitors.set(visitor.getPriority(), new Map());
        }
        push_1.push(this.visitors.get(visitor.getPriority()), visitor);
    }
    /**
     * Traverses a node and calls the registered visitors.
     *
     * @return TwingNode
     */
    traverse(node) {
        let self = this;
        let result = node;
        ksort_1.ksort(this.visitors);
        for (let [index, visitors] of this.visitors) {
            for (let [index, visitor] of visitors) {
                result = self.traverseForVisitor(visitor, node);
            }
        }
        return result;
    }
    traverseForVisitor(visitor, node) {
        let self = this;
        node = visitor.TwingNodeVisitorInterfaceImpl.enterNode(node, this.env);
        for (let [k, n] of node.getNodes()) {
            let m = self.traverseForVisitor(visitor, n);
            if (m) {
                if (m !== n) {
                    node.setNode(k, m);
                }
            }
            else {
                node.removeNode(k);
            }
        }
        return visitor.TwingNodeVisitorInterfaceImpl.leaveNode(node, this.env);
    }
}
exports.TwingNodeTraverser = TwingNodeTraverser;


/***/ }),
/* 206 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(process) {
Object.defineProperty(exports, "__esModule", { value: true });
const unserialize = __webpack_require__(511);
const serialize = __webpack_require__(512);
class TwingProfilerProfile {
    constructor(template = 'main', type = TwingProfilerProfile.ROOT, name = 'main') {
        this.starts = new Map();
        this.ends = new Map();
        this.profiles = [];
        this[Symbol.iterator] = this.profiles[Symbol.iterator];
        this.template = template;
        this.type = type;
        this.name = (name.indexOf('__internal_') === 0) ? 'INTERNAL' : name;
        this.enter();
    }
    static unserialize(data) {
        let result = new TwingProfilerProfile();
        let resultData = unserialize(data);
        result.template = resultData.template;
        result.name = resultData.name;
        result.type = resultData.type;
        result.starts = new Map(resultData.starts);
        result.ends = new Map(resultData.ends);
        result.profiles = [];
        for (let profileData of resultData.profiles) {
            let profile = new TwingProfilerProfile(profileData.template, profileData.type, profileData.name);
            result.profiles.push(profile);
        }
        return result;
    }
    getTemplate() {
        return this.template;
    }
    getType() {
        return this.type;
    }
    getName() {
        return this.name;
    }
    isRoot() {
        return this.type === TwingProfilerProfile.ROOT;
    }
    isTemplate() {
        return this.type === TwingProfilerProfile.TEMPLATE;
    }
    isBlock() {
        return this.type === TwingProfilerProfile.BLOCK;
    }
    isMacro() {
        return this.type === TwingProfilerProfile.MACRO;
    }
    getProfiles() {
        return this.profiles;
    }
    addProfile(profile) {
        this.profiles.push(profile);
    }
    /**
     * Returns the duration in microseconds.
     *
     * @return int
     */
    getDuration() {
        if (this.isRoot() && this.profiles.length > 0) {
            // for the root node with children, duration is the sum of all child durations
            let duration = 0;
            for (let profile of this.profiles) {
                duration += profile.getDuration();
            }
            return duration;
        }
        return this.ends.has('wt') && this.starts.has('wt') ? this.ends.get('wt') - this.starts.get('wt') : 0;
    }
    /**
     * Returns the memory usage in bytes.
     *
     * @return int
     */
    getMemoryUsage() {
        return this.ends.has('mu') && this.starts.has('mu') ? this.ends.get('mu') - this.starts.get('mu') : 0;
    }
    /**
     * Returns the peak memory usage in bytes.
     *
     * @return int
     */
    getPeakMemoryUsage() {
        return this.ends.has('pmu') && this.starts.has('pmu') ? this.ends.get('pmu') - this.starts.get('pmu') : 0;
    }
    /**
     * Starts the profiling.
     */
    enter() {
        let memoryUsage = process.memoryUsage();
        this.starts = new Map([
            ['wt', new Date().getTime()],
            ['mu', memoryUsage.rss],
            ['pmu', memoryUsage.rss],
        ]);
    }
    /**
     * Stops the profiling.
     */
    leave() {
        let memoryUsage = process.memoryUsage();
        this.ends = new Map([
            ['wt', new Date().getTime()],
            ['mu', memoryUsage.rss],
            ['pmu', memoryUsage.rss],
        ]);
    }
    reset() {
        this.profiles = [];
        this.starts = new Map();
        this.ends = new Map();
        this.enter();
    }
}
exports.TwingProfilerProfile = TwingProfilerProfile;
TwingProfilerProfile.ROOT = 'ROOT';
TwingProfilerProfile.BLOCK = 'block';
TwingProfilerProfile.TEMPLATE = 'template';
TwingProfilerProfile.MACRO = 'macro';

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(22)))

/***/ }),
/* 207 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const security_error_1 = __webpack_require__(125);
/**
 * Exception thrown when a not allowed filter is used in a template.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingSandboxSecurityNotAllowedFilterError extends security_error_1.TwingSandboxSecurityError {
    constructor(message, functionName, lineno = -1, filename = null) {
        super(message, lineno, filename);
        this.filterName = functionName;
        this.name = 'TwingSandboxSecurityNotAllowedFilterError';
    }
    getFilterName() {
        return this.filterName;
    }
}
exports.TwingSandboxSecurityNotAllowedFilterError = TwingSandboxSecurityNotAllowedFilterError;


/***/ }),
/* 208 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const security_error_1 = __webpack_require__(125);
class TwingSandboxSecurityNotAllowedFunctionError extends security_error_1.TwingSandboxSecurityError {
    constructor(message, functionName, lineno = -1, filename = null) {
        super(message, lineno, filename);
        this.functionName = functionName;
        this.name = 'TwingSandboxSecurityNotAllowedFunctionError';
    }
    getFunctionName() {
        return this.functionName;
    }
}
exports.TwingSandboxSecurityNotAllowedFunctionError = TwingSandboxSecurityNotAllowedFunctionError;


/***/ }),
/* 209 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const security_error_1 = __webpack_require__(125);
class TwingSandboxSecurityNotAllowedTagError extends security_error_1.TwingSandboxSecurityError {
    constructor(message, functionName, lineno = -1, filename = null) {
        super(message, lineno, filename);
        this.tagName = functionName;
        this.name = 'TwingSandboxSecurityNotAllowedTagError';
    }
    getTagName() {
        return this.tagName;
    }
}
exports.TwingSandboxSecurityNotAllowedTagError = TwingSandboxSecurityNotAllowedTagError;


/***/ }),
/* 210 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Noop implementation of TwingLoaderInterface.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingLoaderNull {
    exists(name, from) {
        return false;
    }
    getCacheKey(name, from) {
        return null;
    }
    getSourceContext(name, from) {
        return null;
    }
    isFresh(name, time, from) {
        return true;
    }
    resolve(name, from) {
        return null;
    }
}
exports.TwingLoaderNull = TwingLoaderNull;


/***/ }),
/* 211 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingProfilerDumperBase {
    dump(profile) {
        return this.dumpProfile(profile);
    }
    dumpProfile(profile, prefix = '', sibling = false) {
        let start;
        if (profile.isRoot()) {
            this.root = profile.getDuration();
            start = profile.getName();
        }
        else {
            if (profile.isTemplate()) {
                start = this.formatTemplate(profile, prefix);
            }
            else {
                start = this.formatNonTemplate(profile, prefix);
            }
            prefix += sibling ? '│ ' : '  ';
        }
        let percent = this.root ? profile.getDuration() / this.root * 100 : 0;
        let str;
        if (profile.getDuration() * 1000 < 1) {
            str = start + '\n';
        }
        else {
            str = `${start} ${this.formatTime(profile, percent)}\n`;
        }
        let nCount = profile.getProfiles().length;
        let i = 0;
        for (let p of profile.getProfiles()) {
            str += this.dumpProfile(p, prefix, i + 1 !== nCount);
            i++;
        }
        return str;
    }
}
exports.TwingProfilerDumperBase = TwingProfilerDumperBase;


/***/ }),
/* 212 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M37.6,32.4v-16c-0.4,0.5-1.4,1.2-2,1.6c-3.8,2.8-6.8,5-9,6.8c-0.7,0.6-1.3,1-1.8,1.3s-1.1,0.6-1.8,1 c-0.8,0.3-1.5,0.5-2.2,0.5h0c-0.7,0-1.4-0.2-2.2-0.5c-0.8-0.3-1.4-0.7-1.8-1s-1-0.8-1.8-1.3c-2.2-1.8-5.2-4-9-6.8 c-0.5-0.4-1.5-1.2-2-1.6v16c0,0.2,0.1,0.3,0.2,0.5C4.5,32.9,4.7,33,4.8,33h32.1c0.2,0,0.3-0.1,0.5-0.2S37.6,32.5,37.6,32.4z M37.6,11v-0.7l0,0l-0.1-0.5l-0.1-0.2l-0.2-0.2l-0.3-0.1H4.8c-0.2,0-0.3,0.1-0.5,0.2C4.2,9.7,4.2,9.8,4.2,10c0,2.3,1.6,4.5,3.6,6.1 c2.7,2.1,5.5,4.3,8.5,6.5c0.1,0.1,0.3,0.3,0.7,0.6s0.7,0.6,1,0.8c0.2,0.2,0.6,0.4,0.9,0.6c0.4,0.3,0.7,0.4,1.1,0.6 c0.3,0.1,0.6,0.2,0.9,0.2h0c0.3,0,0.6-0.1,0.9-0.2c0.3-0.1,0.7-0.3,1.1-0.6c0.4-0.3,0.7-0.5,0.9-0.6c0.2-0.2,0.6-0.4,1-0.8 s0.7-0.5,0.7-0.6c2.9-2.3,5.7-4.4,8.5-6.5c0.8-0.6,2.1-1.7,2.7-2.7S37.6,11.8,37.6,11z M39.8,10.2v21.9c0,0.9-0.3,1.6-1,2.3 c-0.7,0.6-1.5,0.9-2.4,0.9h-31c-0.9,0-1.7-0.3-2.4-0.9S2,33,2,32.1V10.2c0-0.9,0.3-1.6,1-2.3S4.4,7,5.4,7h31c0.9,0,1.7,0.3,2.4,0.9 C39.5,8.6,39.8,9.3,39.8,10.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 213 */,
/* 214 */,
/* 215 */,
/* 216 */,
/* 217 */,
/* 218 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgA4AIcAAMnZ7cra7cra7svb7szb7s3c7s3c787d7s7d787e7s7e78/e78/f8NDe8NDf8NHf8NDg8NDh8NHh8NLg8NLg8dLh8NPh8dTh8tXi8tbj8tbj89fk89jk89nl89nl9Nrm9PD1+gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACADgAAAhlAEGA+EDwgwcPHTpw4LCh4QYNGjJIzIChIoYLFyxotEChI4UJEx6IfNCgZIMFCxCoRGCgpYECBQjIJDBggAABAQIA2AkAps8CBw4kGJpAgQKUDJIycOAAAoQIUCNIkFChqtWrAQEAOw=="

/***/ }),
/* 219 */
/***/ (function(module, exports) {

module.exports = function (exec) {
  try {
    return !!exec();
  } catch (e) {
    return true;
  }
};


/***/ }),
/* 220 */
/***/ (function(module, exports) {

var toString = {}.toString;

module.exports = Array.isArray || function (arr) {
  return toString.call(arr) == '[object Array]';
};


/***/ }),
/* 221 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links_1_' d='M29.5,21.2c0-0.2-0.1-0.5-0.3-0.7L16,7.3C15.8,7.1,15.6,7,15.4,7s-0.5,0.1-0.7,0.3l-1.4,1.4 C13.1,8.9,13,9.1,13,9.4c0,0.2,0.1,0.5,0.3,0.7l11.2,11.2L13.3,32.3C13.1,32.5,13,32.7,13,33c0,0.2,0.1,0.5,0.3,0.7l1.4,1.4 c0.2,0.2,0.4,0.3,0.7,0.3s0.5-0.1,0.7-0.3l13.2-13.2C29.4,21.6,29.5,21.4,29.5,21.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 222 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.7,30.4c0-0.2-0.1-0.3-0.2-0.5L23.3,18.8c0.4-1,0.7-2.2,0.7-3.3c0-2.3-0.9-4.4-2.5-6c-1.6-1.6-3.7-2.5-6-2.5 c-2.3,0-4.4,0.9-6,2.5c-3.3,3.3-3.3,8.7,0,12c1.6,1.6,3.7,2.5,6,2.5c1.2,0,2.3-0.2,3.3-0.7l3.7,3.7c0.2,0.2,0.4,0.2,0.6,0.2l2-0.1 l-0.1,2c0,0.2,0.1,0.4,0.2,0.6c0.1,0.2,0.4,0.2,0.6,0.2l2-0.1l-0.1,2c0,0.2,0.1,0.4,0.2,0.6c0.2,0.2,0.3,0.2,0.6,0.2l2-0.1l-0.1,2 c0,0.2,0.1,0.4,0.2,0.6c0.1,0.1,0.3,0.2,0.5,0.2c0,0,0.1,0,0.1,0l3.1-0.3c0.4,0,0.7-0.4,0.7-0.8L34.7,30.4z M14.4,14.5 c-0.9,0.9-2.5,0.9-3.4,0c-0.9-0.9-0.9-2.5,0-3.4c0.9-0.9,2.5-0.9,3.4,0C15.4,12,15.4,13.5,14.4,14.5L14.4,14.5z M32,30.7 c-0.1,0.1-0.3,0.2-0.4,0.2c-0.1,0-0.3-0.1-0.4-0.2l-9.5-9.5c0.3-0.3,0.5-0.6,0.7-0.9l9.6,9.6C32.3,30.1,32.3,30.5,32,30.7L32,30.7z M32,30.7'/%3E %3C/svg%3E\""

/***/ }),
/* 223 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.6,21c0-2.6-0.7-5.1-2-7.3s-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3s-2,4.7-2,7.3s0.7,5.1,2,7.3 s3.1,4,5.3,5.3s4.7,2,7.3,2s5.1-0.7,7.3-2s4-3.1,5.3-5.3S35.6,23.6,35.6,21z M38,21c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2 C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3c-2.6-1.5-4.7-3.6-6.2-6.2S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2 S17.9,4,21,4c3.1,0,5.9,0.8,8.5,2.3s4.7,3.6,6.2,6.2C37.2,15.1,38,17.9,38,21z M26.3,27.9v1.8c0,0.2-0.1,0.5-0.2,0.6 c-0.2,0.2-0.4,0.3-0.6,0.3h-8.7c-0.2,0-0.4-0.1-0.6-0.3c-0.2-0.2-0.2-0.4-0.2-0.6v-1.8c0-0.2,0.1-0.5,0.2-0.6 c0.2-0.2,0.4-0.3,0.6-0.3h2.7v-5.5h-2.7c-0.2,0-0.4-0.1-0.6-0.3C16.1,21,16,20.8,16,20.6v-1.8c0-0.2,0.1-0.5,0.2-0.6 c0.2-0.2,0.4-0.3,0.6-0.3h5.8c0.2,0,0.4,0.1,0.6,0.3s0.2,0.4,0.2,0.6V27h2.1c0.2,0,0.4,0.1,0.6,0.3C26.2,27.4,26.3,27.6,26.3,27.9z M23.4,12.3v1.9c0,0.2-0.1,0.5-0.2,0.6c-0.2,0.2-0.4,0.3-0.6,0.3h-2.2c-0.2,0-0.4-0.1-0.6-0.3c-0.2-0.2-0.2-0.4-0.2-0.6v-1.9 c0-0.2,0.1-0.5,0.2-0.6c0.2-0.2,0.4-0.3,0.6-0.3h2.2c0.2,0,0.4,0.1,0.6,0.3C23.3,11.9,23.4,12.1,23.4,12.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 224 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.6,21c0-2.6-0.7-5.1-2-7.3s-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3s-2,4.7-2,7.3s0.7,5.1,2,7.3 s3.1,4,5.3,5.3s4.7,2,7.3,2s5.1-0.7,7.3-2s4-3.1,5.3-5.3S35.6,23.6,35.6,21z M38,21c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2 C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3c-2.6-1.5-4.7-3.6-6.2-6.2S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2 S17.9,4,21,4c3.1,0,5.9,0.8,8.5,2.3s4.7,3.6,6.2,6.2C37.2,15.1,38,17.9,38,21z M21.7,30.8h-1.4c-0.2,0-0.4-0.1-0.5-0.2 c-0.1-0.1-0.2-0.3-0.2-0.5v-7.7h-7.7c-0.2,0-0.4-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5v-1.4c0-0.2,0.1-0.4,0.2-0.5 c0.1-0.1,0.3-0.2,0.5-0.2h7.7v-7.7c0-0.2,0.1-0.4,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h1.4c0.2,0,0.4,0.1,0.5,0.2 c0.1,0.1,0.2,0.3,0.2,0.5v7.7h7.7c0.2,0,0.4,0.1,0.5,0.2c0.1,0.1,0.2,0.3,0.2,0.5v1.4c0,0.2-0.1,0.4-0.2,0.5s-0.3,0.2-0.5,0.2h-7.7 v7.7c0,0.2-0.1,0.4-0.2,0.5S21.9,30.8,21.7,30.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 225 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M21.2,4c-2.3,0-4.3,0.8-6,2.5s-2.5,3.7-2.5,6s0.8,4.3,2.5,6s3.7,2.5,6,2.5s4.3-0.8,6-2.5s2.5-3.7,2.5-6s-0.8-4.3-2.5-6 S23.5,4,21.2,4z M30.6,38c1.3,0,2.4-0.5,3.3-1.6s1.4-2.3,1.4-3.8c0-3.5-0.6-6.3-1.7-8.3s-2.8-3.1-5-3.2c-2.1,1.9-4.6,2.8-7.4,2.8 s-5.3-0.9-7.4-2.8c-2.2,0.1-3.8,1.2-5,3.2S7,29,7,32.5c0,1.5,0.5,2.8,1.4,3.8s2,1.6,3.3,1.6H30.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 226 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M19.9,28.4L7.5,16C7.2,15.7,7,15.3,7,14.8c0-0.5,0.2-0.9,0.5-1.2C7.9,13.2,8.3,13,8.8,13h24.8c0.5,0,0.9,0.2,1.2,0.5 c0.4,0.4,0.5,0.8,0.5,1.2c0,0.5-0.2,0.9-0.5,1.2L22.4,28.4c-0.4,0.4-0.8,0.5-1.2,0.5C20.7,28.9,20.3,28.8,19.9,28.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 227 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.9,33.1l-1.8,1.8c-0.3,0.3-0.6,0.4-0.9,0.4c-0.3,0-0.6-0.1-0.9-0.4L21.2,24.8L11.1,34.9c-0.3,0.3-0.6,0.4-0.9,0.4 c-0.3,0-0.6-0.1-0.9-0.4l-1.8-1.8C7.1,32.8,7,32.5,7,32.2c0-0.3,0.1-0.6,0.4-0.9l10.1-10.1L7.4,11.1C7.1,10.8,7,10.5,7,10.2 c0-0.3,0.1-0.6,0.4-0.9l1.8-1.8C9.5,7.1,9.8,7,10.2,7c0.3,0,0.6,0.1,0.9,0.4l10.1,10.1L31.2,7.4C31.5,7.1,31.8,7,32.2,7 c0.3,0,0.6,0.1,0.9,0.4l1.8,1.8c0.3,0.3,0.4,0.6,0.4,0.9c0,0.3-0.1,0.6-0.4,0.9L24.8,21.2l10.1,10.1c0.3,0.3,0.4,0.6,0.4,0.9 C35.3,32.5,35.2,32.8,34.9,33.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 228 */,
/* 229 */,
/* 230 */
/***/ (function(module, exports) {

/*
	MIT License http://www.opensource.org/licenses/mit-license.php
	Author Tobias Koppers @sokra
*/
module.exports = function(src) {
	function log(error) {
		(typeof console !== "undefined")
		&& (console.error || console.log)("[Script Loader]", error);
	}

	// Check for IE =< 8
	function isIE() {
		return typeof attachEvent !== "undefined" && typeof addEventListener === "undefined";
	}

	try {
		if (typeof execScript !== "undefined" && isIE()) {
			execScript(src);
		} else if (typeof eval !== "undefined") {
			eval.call(null, src);
		} else {
			log("EvalError: No eval function available");
		}
	} catch (error) {
		log(error);
	}
}


/***/ }),
/* 231 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQABAID/AMDAwAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=="

/***/ }),
/* 232 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgAYAIcAANDQ0Ovs7uzt7+3u8O7v8e/w8vDx8/Hy9Pn5+QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACABgAAAghABEIHEiwYMEDCA8YWMiwgMMCBAgMmDhAgIAAGAMAABAQADs="

/***/ }),
/* 233 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgAWAIcAAKrM9tno++vz/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACABYAAAgUAAUIHEiwoIAACBMqXMhwIQAAAQEAOw=="

/***/ }),
/* 234 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhGAACAIcAANDQ0Ovs7uzt7+3u8O7v8e/w8vDx8/Hy9Pn5+QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAYAAIAAAgiABEIHEjwwAEDCAsUIDBggIAAAQAQnIjAIEIDChk6hAggIAA7"

/***/ }),
/* 235 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQBEAIcAAMfY7cjY7cjZ7cnZ7crZ7cva7svb7szb7szc7s3c7s7d7s7e7s7e78/e78/f8NDf8NHf8NLf8NDg8NDh8NHh8NLh8NPg8dPi8dPj8dPj8tTh8dXi8dTj8tbi8tfj8tTk8tXk8tXk89Xl89bl89bm9Nfn9djk8tnl89rl89vm89zn9Njo9d7o9e3y+AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABAEQAAAhGAFuwUJECxQkTHjps0GAhAgQAECEGmBhAwICLBApoNHAAgccEIBUsWMCggQMHDyRMmEChgssLFzBk4PDhA4gQIkaQKLEiIAA7"

/***/ }),
/* 236 */
/***/ (function(module, exports, __webpack_require__) {

// 19.1.2.14 / 15.2.3.14 Object.keys(O)
var $keys = __webpack_require__(611);
var enumBugKeys = __webpack_require__(403);

module.exports = Object.keys || function keys(O) {
  return $keys(O, enumBugKeys);
};


/***/ }),
/* 237 */
/***/ (function(module, exports) {

var toString = {}.toString;

module.exports = function (it) {
  return toString.call(it).slice(8, -1);
};


/***/ }),
/* 238 */
/***/ (function(module, exports) {

module.exports = true;


/***/ }),
/* 239 */
/***/ (function(module, exports) {

module.exports = {};


/***/ }),
/* 240 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
var abs_1 = __webpack_require__(241);
exports.abs = abs_1.abs;
var compare_1 = __webpack_require__(175);
exports.compare = compare_1.compare;
var count_1 = __webpack_require__(177);
exports.count = count_1.count;
var each_1 = __webpack_require__(145);
exports.each = each_1.each;
var examine_object_1 = __webpack_require__(242);
exports.examineObject = examine_object_1.examineObject;
var format_duration_1 = __webpack_require__(243);
exports.formatDuration = format_duration_1.formatDuration;
var format_date_time_1 = __webpack_require__(244);
exports.formatDateTime = format_date_time_1.formatDateTime;
var iconv_1 = __webpack_require__(178);
exports.iconv = iconv_1.iconv;
var is_countable_1 = __webpack_require__(247);
exports.isCountable = is_countable_1.isCountable;
var is_traversable_1 = __webpack_require__(180);
exports.isTraversable = is_traversable_1.isTraversable;
var iterator_to_array_1 = __webpack_require__(134);
exports.iteratorToArray = iterator_to_array_1.iteratorToArray;
var iterator_to_hash_1 = __webpack_require__(146);
exports.iteratorToHash = iterator_to_hash_1.iteratorToHash;
var iterator_to_map_1 = __webpack_require__(128);
exports.iteratorToMap = iterator_to_map_1.iteratorToMap;
var json_encode_1 = __webpack_require__(248);
exports.jsonEncode = json_encode_1.jsonEncode;
var max_1 = __webpack_require__(249);
exports.max = max_1.max;
var min_1 = __webpack_require__(250);
exports.min = min_1.min;
var regex_parser_1 = __webpack_require__(251);
exports.regexParser = regex_parser_1.regexParser;
var relative_date_1 = __webpack_require__(252);
exports.relativeDate = relative_date_1.relativeDate;
var base_node_visitor_1 = __webpack_require__(129);
exports.TwingBaseNodeVisitor = base_node_visitor_1.TwingBaseNodeVisitor;
var null_1 = __webpack_require__(148);
exports.TwingCacheFilesystem = null_1.TwingCacheNull;
var null_2 = __webpack_require__(148);
exports.TwingCacheNull = null_2.TwingCacheNull;
var compiler_1 = __webpack_require__(253);
exports.TwingCompiler = compiler_1.TwingCompiler;
var browser_1 = __webpack_require__(443);
exports.TwingEnvironment = browser_1.TwingEnvironmentBrowser;
var loader_1 = __webpack_require__(140);
exports.TwingErrorLoader = loader_1.TwingErrorLoader;
var runtime_1 = __webpack_require__(153);
exports.TwingErrorRuntime = runtime_1.TwingErrorRuntime;
var syntax_1 = __webpack_require__(112);
exports.TwingErrorSyntax = syntax_1.TwingErrorSyntax;
var error_1 = __webpack_require__(120);
exports.TwingError = error_1.TwingError;
var expression_parser_1 = __webpack_require__(184);
exports.TwingExpressionParser = expression_parser_1.TwingExpressionParser;
var core_1 = __webpack_require__(257);
exports.TwingExtensionCore = core_1.TwingExtensionCore;
var debug_1 = __webpack_require__(513);
exports.TwingExtensionDebug = debug_1.TwingExtensionDebug;
var escaper_1 = __webpack_require__(343);
exports.TwingExtensionEscaper = escaper_1.TwingExtensionEscaper;
var optimizer_1 = __webpack_require__(352);
exports.TwingExtensionOptimizer = optimizer_1.TwingExtensionOptimizer;
var profiler_1 = __webpack_require__(514);
exports.TwingExtensionProfiler = profiler_1.TwingExtensionProfiler;
var sandbox_1 = __webpack_require__(515);
exports.TwingExtensionSandbox = sandbox_1.TwingExtensionSandbox;
var extension_set_1 = __webpack_require__(255);
exports.TwingExtensionSet = extension_set_1.TwingExtensionSet;
var staging_1 = __webpack_require__(256);
exports.TwingExtensionStaging = staging_1.TwingExtensionStaging;
var string_loader_1 = __webpack_require__(517);
exports.TwingExtensionStringLoader = string_loader_1.TwingExtensionStringLoader;
var extension_1 = __webpack_require__(117);
exports.TwingExtension = extension_1.TwingExtension;
var factory_runtime_loader_1 = __webpack_require__(518);
exports.TwingFactoryRuntimeLoader = factory_runtime_loader_1.TwingFactoryRuntimeLoader;
var file_extension_escaping_strategy_1 = __webpack_require__(348);
exports.TwingFileExtensionEscapingStrategy = file_extension_escaping_strategy_1.TwingFileExtensionEscapingStrategy;
var filter_1 = __webpack_require__(201);
exports.TwingFilter = filter_1.TwingFilter;
var function_1 = __webpack_require__(158);
exports.TwingFunction = function_1.TwingFunction;
var lexer_1 = __webpack_require__(185);
exports.TwingLexer = lexer_1.TwingLexer;
var array_1 = __webpack_require__(350);
exports.TwingLoaderArray = array_1.TwingLoaderArray;
var chain_1 = __webpack_require__(351);
exports.TwingLoaderChain = chain_1.TwingLoaderChain;
var null_3 = __webpack_require__(210);
exports.TwingLoaderFilesystem = null_3.TwingLoaderNull;
var null_4 = __webpack_require__(210);
exports.TwingLoaderNull = null_4.TwingLoaderNull;
var null_5 = __webpack_require__(210);
exports.TwingLoaderRelativeFilesystem = null_5.TwingLoaderNull;
var markup_1 = __webpack_require__(162);
exports.TwingMarkup = markup_1.TwingMarkup;
var auto_escape_1 = __webpack_require__(347);
exports.TwingNodeAutoEscape = auto_escape_1.TwingNodeAutoEscape;
var block_reference_1 = __webpack_require__(276);
exports.TwingNodeBlockReference = block_reference_1.TwingNodeBlockReference;
var block_1 = __webpack_require__(193);
exports.TwingNodeBlock = block_1.TwingNodeBlock;
var body_1 = __webpack_require__(157);
exports.TwingNodeBody = body_1.TwingNodeBody;
var check_security_1 = __webpack_require__(362);
exports.TwingNodeCheckSecurity = check_security_1.TwingNodeCheckSecurity;
var do_1 = __webpack_require__(199);
exports.TwingNodeDo = do_1.TwingNodeDo;
var deprecated_1 = __webpack_require__(333);
exports.TwingNodeDeprecated = deprecated_1.TwingNodeDeprecated;
var embed_1 = __webpack_require__(296);
exports.TwingNodeEmbed = embed_1.TwingNodeEmbed;
var array_2 = __webpack_require__(154);
exports.TwingNodeExpressionArray = array_2.TwingNodeExpressionArray;
var assign_name_1 = __webpack_require__(136);
exports.TwingNodeExpressionAssignName = assign_name_1.TwingNodeExpressionAssignName;
var add_1 = __webpack_require__(293);
exports.TwingNodeExpressionBinaryAdd = add_1.TwingNodeExpressionBinaryAdd;
var and_1 = __webpack_require__(190);
exports.TwingNodeExpressionBinaryAnd = and_1.TwingNodeExpressionBinaryAnd;
var bitwise_and_1 = __webpack_require__(308);
exports.TwingNodeExpressionBinaryBitwiseAnd = bitwise_and_1.TwingNodeExpressionBinaryBitwiseAnd;
var bitwise_or_1 = __webpack_require__(306);
exports.TwingNodeExpressionBinaryBitwiseOr = bitwise_or_1.TwingNodeExpressionBinaryBitwiseOr;
var bitwise_xor_1 = __webpack_require__(307);
exports.TwingNodeExpressionBinaryBitwiseXor = bitwise_xor_1.TwingNodeExpressionBinaryBitwiseXor;
var concat_1 = __webpack_require__(187);
exports.TwingNodeExpressionBinaryConcat = concat_1.TwingNodeExpressionBinaryConcat;
var div_1 = __webpack_require__(198);
exports.TwingNodeExpressionBinaryDiv = div_1.TwingNodeExpressionBinaryDiv;
var ends_with_1 = __webpack_require__(321);
exports.TwingNodeExpressionBinaryEndsWith = ends_with_1.TwingNodeExpressionBinaryEndsWith;
var equal_1 = __webpack_require__(303);
exports.TwingNodeExpressionBinaryEqual = equal_1.TwingNodeExpressionBinaryEqual;
var floor_div_1 = __webpack_require__(290);
exports.TwingNodeExpressionBinaryFloorDiv = floor_div_1.TwingNodeExpressionBinaryFloorDiv;
var greater_equal_1 = __webpack_require__(309);
exports.TwingNodeExpressionBinaryGreaterEqual = greater_equal_1.TwingNodeExpressionBinaryGreaterEqual;
var greater_1 = __webpack_require__(277);
exports.TwingNodeExpressionBinaryGreater = greater_1.TwingNodeExpressionBinaryGreater;
var in_1 = __webpack_require__(272);
exports.TwingNodeExpressionBinaryIn = in_1.TwingNodeExpressionBinaryIn;
var less_equal_1 = __webpack_require__(310);
exports.TwingNodeExpressionBinaryLessEqual = less_equal_1.TwingNodeExpressionBinaryLessEqual;
var less_1 = __webpack_require__(278);
exports.TwingNodeExpressionBinaryLess = less_1.TwingNodeExpressionBinaryLess;
var matches_1 = __webpack_require__(319);
exports.TwingNodeExpressionBinaryMatches = matches_1.TwingNodeExpressionBinaryMatches;
var mod_1 = __webpack_require__(291);
exports.TwingNodeExpressionBinaryMod = mod_1.TwingNodeExpressionBinaryMod;
var mul_1 = __webpack_require__(289);
exports.TwingNodeExpressionBinaryMul = mul_1.TwingNodeExpressionBinaryMul;
var not_equal_1 = __webpack_require__(304);
exports.TwingNodeExpressionBinaryNotEqual = not_equal_1.TwingNodeExpressionBinaryNotEqual;
var not_in_1 = __webpack_require__(311);
exports.TwingNodeExpressionBinaryNotIn = not_in_1.TwingNodeExpressionBinaryNotIn;
var or_1 = __webpack_require__(305);
exports.TwingNodeExpressionBinaryOr = or_1.TwingNodeExpressionBinaryOr;
var power_1 = __webpack_require__(313);
exports.TwingNodeExpressionBinaryPower = power_1.TwingNodeExpressionBinaryPower;
var range_1 = __webpack_require__(298);
exports.TwingNodeExpressionBinaryRange = range_1.TwingNodeExpressionBinaryRange;
var starts_with_1 = __webpack_require__(320);
exports.TwingNodeExpressionBinaryStartsWith = starts_with_1.TwingNodeExpressionBinaryStartsWith;
var sub_1 = __webpack_require__(292);
exports.TwingNodeExpressionBinarySub = sub_1.TwingNodeExpressionBinarySub;
var binary_1 = __webpack_require__(110);
exports.TwingNodeExpressionBinary = binary_1.TwingNodeExpressionBinary;
var block_reference_2 = __webpack_require__(189);
exports.TwingNodeExpressionBlockReference = block_reference_2.TwingNodeExpressionBlockReference;
var call_1 = __webpack_require__(159);
exports.TwingNodeExpressionCall = call_1.TwingNodeExpressionCall;
var conditional_1 = __webpack_require__(138);
exports.TwingNodeExpressionConditional = conditional_1.TwingNodeExpressionConditional;
var constant_1 = __webpack_require__(115);
exports.TwingNodeExpressionConstant = constant_1.TwingNodeExpressionConstant;
var default_1 = __webpack_require__(322);
exports.TwingNodeExpressionFilterDefault = default_1.TwingNodeExpressionFilterDefault;
var filter_2 = __webpack_require__(161);
exports.TwingNodeExpressionFilter = filter_2.TwingNodeExpressionFilter;
var function_2 = __webpack_require__(283);
exports.TwingNodeExpressionFunction = function_2.TwingNodeExpressionFunction;
var get_attr_1 = __webpack_require__(263);
exports.TwingNodeExpressionGetAttr = get_attr_1.TwingNodeExpressionGetAttr;
var hash_1 = __webpack_require__(267);
exports.TwingNodeExpressionHash = hash_1.TwingNodeExpressionHash;
var method_call_1 = __webpack_require__(265);
exports.TwingNodeExpressionMethodCall = method_call_1.TwingNodeExpressionMethodCall;
var name_1 = __webpack_require__(182);
exports.TwingNodeExpressionName = name_1.TwingNodeExpressionName;
var null_coalesce_1 = __webpack_require__(312);
exports.TwingNodeExpressionNullCoalesce = null_coalesce_1.TwingNodeExpressionNullCoalesce;
var parent_1 = __webpack_require__(266);
exports.TwingNodeExpressionParent = parent_1.TwingNodeExpressionParent;
var constant_2 = __webpack_require__(316);
exports.TwingNodeExpressionTestConstant = constant_2.TwingNodeExpressionTestConstant;
var defined_1 = __webpack_require__(160);
exports.TwingNodeExpressionTestDefined = defined_1.TwingNodeExpressionTestDefined;
var divisible_by_1 = __webpack_require__(318);
exports.TwingNodeExpressionTestDivisibleBy = divisible_by_1.TwingNodeExpressionTestDivisibleBy;
var even_1 = __webpack_require__(323);
exports.TwingNodeExpressionTestEven = even_1.TwingNodeExpressionTestEven;
var null_6 = __webpack_require__(200);
exports.TwingNodeExpressionTestNull = null_6.TwingNodeExpressionTestNull;
var odd_1 = __webpack_require__(315);
exports.TwingNodeExpressionTestOdd = odd_1.TwingNodeExpressionTestOdd;
var same_as_1 = __webpack_require__(314);
exports.TwingNodeExpressionTestSameAs = same_as_1.TwingNodeExpressionTestSameAs;
var test_1 = __webpack_require__(118);
exports.TwingNodeExpressionTest = test_1.TwingNodeExpressionTest;
var neg_1 = __webpack_require__(281);
exports.TwingNodeExpressionUnaryNeg = neg_1.TwingNodeExpressionUnaryNeg;
var not_1 = __webpack_require__(155);
exports.TwingNodeExpressionUnaryNot = not_1.TwingNodeExpressionUnaryNot;
var pos_1 = __webpack_require__(282);
exports.TwingNodeExpressionUnaryPos = pos_1.TwingNodeExpressionUnaryPos;
var unary_1 = __webpack_require__(156);
exports.TwingNodeExpressionUnary = unary_1.TwingNodeExpressionUnary;
var expression_1 = __webpack_require__(114);
exports.TwingNodeExpression = expression_1.TwingNodeExpression;
var flush_1 = __webpack_require__(302);
exports.TwingNodeFlush = flush_1.TwingNodeFlush;
var for_loop_1 = __webpack_require__(260);
exports.TwingNodeForLoop = for_loop_1.TwingNodeForLoop;
var for_1 = __webpack_require__(259);
exports.TwingNodeFor = for_1.TwingNodeFor;
var if_1 = __webpack_require__(183);
exports.TwingNodeIf = if_1.TwingNodeIf;
var import_1 = __webpack_require__(191);
exports.TwingNodeImport = import_1.TwingNodeImport;
var include_1 = __webpack_require__(195);
exports.TwingNodeInclude = include_1.TwingNodeInclude;
var macro_1 = __webpack_require__(271);
exports.TwingNodeMacro = macro_1.TwingNodeMacro;
var module_1 = __webpack_require__(341);
exports.TwingNodeModule = module_1.TwingNodeModule;
var print_1 = __webpack_require__(124);
exports.TwingNodePrint = print_1.TwingNodePrint;
var sandboxed_print_1 = __webpack_require__(519);
exports.TwingNodeSandboxedPrint = sandboxed_print_1.TwingNodeSandboxedPrint;
var sandbox_2 = __webpack_require__(360);
exports.TwingNodeSandbox = sandbox_2.TwingNodeSandbox;
var set_1 = __webpack_require__(192);
exports.TwingNodeSet = set_1.TwingNodeSet;
var spaceless_1 = __webpack_require__(288);
exports.TwingNodeSpaceless = spaceless_1.TwingNodeSpaceless;
var text_1 = __webpack_require__(340);
exports.TwingNodeText = text_1.TwingNodeText;
var node_traverser_1 = __webpack_require__(205);
exports.TwingNodeTraverser = node_traverser_1.TwingNodeTraverser;
var node_1 = __webpack_require__(107);
exports.TwingNodeType = node_1.TwingNodeType;
var escaper_2 = __webpack_require__(344);
exports.TwingNodeVisitorEscaper = escaper_2.TwingNodeVisitorEscaper;
var optimizer_2 = __webpack_require__(353);
exports.TwingNodeVisitorOptimizer = optimizer_2.TwingNodeVisitorOptimizer;
var safe_analysis_1 = __webpack_require__(345);
exports.TwingNodeVisitorSafeAnalysis = safe_analysis_1.TwingNodeVisitorSafeAnalysis;
var sandbox_3 = __webpack_require__(361);
exports.TwingNodeVisitorSandbox = sandbox_3.TwingNodeVisitorSandbox;
var with_1 = __webpack_require__(280);
exports.TwingNodeWith = with_1.TwingNodeWith;
var node_2 = __webpack_require__(107);
exports.TwingNode = node_2.TwingNode;
var output_buffering_1 = __webpack_require__(131);
exports.TwingOutputBuffering = output_buffering_1.TwingOutputBuffering;
exports.TwingOutputHandler = output_buffering_1.TwingOutputHandler;
var parser_1 = __webpack_require__(339);
exports.TwingParser = parser_1.TwingParser;
var enter_profile_1 = __webpack_require__(357);
exports.TwingProfilerNodeEnterProfile = enter_profile_1.TwingProfilerNodeEnterProfile;
var leave_profile_1 = __webpack_require__(358);
exports.TwingProfilerNodeLeaveProfile = leave_profile_1.TwingProfilerNodeLeaveProfile;
var profiler_2 = __webpack_require__(356);
exports.TwingProfilerNodeVisitorProfiler = profiler_2.TwingProfilerNodeVisitorProfiler;
var profile_1 = __webpack_require__(206);
exports.TwingProfilerProfile = profile_1.TwingProfilerProfile;
var range_2 = __webpack_require__(202);
exports.range = range_2.range;
var reflection_method_1 = __webpack_require__(284);
exports.TwingReflectionMethod = reflection_method_1.TwingReflectionMethod;
var reflection_parameter_1 = __webpack_require__(285);
exports.TwingReflectionParameter = reflection_parameter_1.TwingReflectionParameter;
var security_error_1 = __webpack_require__(125);
exports.TwingSandboxSecurityError = security_error_1.TwingSandboxSecurityError;
var security_not_allowed_filter_error_1 = __webpack_require__(207);
exports.TwingSandboxSecurityNotAllowedFilterError = security_not_allowed_filter_error_1.TwingSandboxSecurityNotAllowedFilterError;
var security_not_allowed_function_error_1 = __webpack_require__(208);
exports.TwingSandboxSecurityNotAllowedFunctionError = security_not_allowed_function_error_1.TwingSandboxSecurityNotAllowedFunctionError;
var security_not_allowed_method_error_1 = __webpack_require__(363);
exports.TwingSandboxSecurityNotAllowedMethodError = security_not_allowed_method_error_1.TwingSandboxSecurityNotAllowedMethodError;
var security_not_allowed_property_error_1 = __webpack_require__(364);
exports.TwingSandboxSecurityNotAllowedPropertyError = security_not_allowed_property_error_1.TwingSandboxSecurityNotAllowedPropertyError;
var security_not_allowed_tag_error_1 = __webpack_require__(209);
exports.TwingSandboxSecurityNotAllowedTagError = security_not_allowed_tag_error_1.TwingSandboxSecurityNotAllowedTagError;
var security_policy_1 = __webpack_require__(520);
exports.TwingSandboxSecurityPolicy = security_policy_1.TwingSandboxSecurityPolicy;
var source_1 = __webpack_require__(130);
exports.TwingSource = source_1.TwingSource;
var node_3 = __webpack_require__(204);
exports.TwingSourceMapNode = node_3.TwingSourceMapNode;
var spaceless_2 = __webpack_require__(329);
exports.TwingSourceMapNodeSpaceless = spaceless_2.TwingSourceMapNodeSpaceless;
var template_wrapper_1 = __webpack_require__(188);
exports.TwingTemplateWrapper = template_wrapper_1.TwingTemplateWrapper;
var template_1 = __webpack_require__(123);
exports.TwingTemplate = template_1.TwingTemplate;
var test_2 = __webpack_require__(317);
exports.TwingTest = test_2.TwingTest;
var token_1 = __webpack_require__(109);
exports.TwingToken = token_1.TwingToken;
var auto_escape_2 = __webpack_require__(346);
exports.TwingTokenParserAutoEscape = auto_escape_2.TwingTokenParserAutoEscape;
var block_2 = __webpack_require__(275);
exports.TwingTokenParserBlock = block_2.TwingTokenParserBlock;
var do_2 = __webpack_require__(300);
exports.TwingTokenParserDo = do_2.TwingTokenParserDo;
var embed_2 = __webpack_require__(295);
exports.TwingTokenParserEmbed = embed_2.TwingTokenParserEmbed;
var extends_1 = __webpack_require__(268);
exports.TwingTokenParserExtends = extends_1.TwingTokenParserExtends;
var filter_3 = __webpack_require__(297);
exports.TwingTokenParserFilter = filter_3.TwingTokenParserFilter;
var flush_2 = __webpack_require__(301);
exports.TwingTokenParserFlush = flush_2.TwingTokenParserFlush;
var for_2 = __webpack_require__(258);
exports.TwingTokenParserFor = for_2.TwingTokenParserFor;
var from_1 = __webpack_require__(269);
exports.TwingTokenParserFrom = from_1.TwingTokenParserFrom;
var if_2 = __webpack_require__(273);
exports.TwingTokenParserIf = if_2.TwingTokenParserIf;
var import_2 = __webpack_require__(299);
exports.TwingTokenParserImport = import_2.TwingTokenParserImport;
var include_2 = __webpack_require__(194);
exports.TwingTokenParserInclude = include_2.TwingTokenParserInclude;
var macro_2 = __webpack_require__(270);
exports.TwingTokenParserMacro = macro_2.TwingTokenParserMacro;
var sandbox_4 = __webpack_require__(359);
exports.TwingTokenParserSandbox = sandbox_4.TwingTokenParserSandbox;
var set_2 = __webpack_require__(274);
exports.TwingTokenParserSet = set_2.TwingTokenParserSet;
var spaceless_3 = __webpack_require__(287);
exports.TwingTokenParserSpaceless = spaceless_3.TwingTokenParserSpaceless;
var use_1 = __webpack_require__(294);
exports.TwingTokenParserUse = use_1.TwingTokenParserUse;
var with_2 = __webpack_require__(279);
exports.TwingTokenParserWith = with_2.TwingTokenParserWith;
var token_parser_1 = __webpack_require__(111);
exports.TwingTokenParser = token_parser_1.TwingTokenParser;
var token_stream_1 = __webpack_require__(261);
exports.TwingTokenStream = token_stream_1.TwingTokenStream;
var var_dump_1 = __webpack_require__(355);
exports.varDump = var_dump_1.varDump;
var base_1 = __webpack_require__(211);
exports.TwingProfilerDumperBase = base_1.TwingProfilerDumperBase;
var blackfire_1 = __webpack_require__(521);
exports.TwingProfilerDumperBlackfire = blackfire_1.TwingProfilerDumperBlackfire;
var html_1 = __webpack_require__(522);
exports.TwingProfilerDumperHtml = html_1.TwingProfilerDumperHtml;
var text_2 = __webpack_require__(523);
exports.TwingProfilerDumperText = text_2.TwingProfilerDumperText;
var asort_1 = __webpack_require__(327);
exports.asort = asort_1.asort;
var chunk_1 = __webpack_require__(324);
exports.chunk = chunk_1.chunk;
var clone_1 = __webpack_require__(354);
exports.clone = clone_1.clone;
var fill_1 = __webpack_require__(325);
exports.fill = fill_1.fill;
var first_1 = __webpack_require__(203);
exports.first = first_1.first;
var includes_1 = __webpack_require__(524);
exports.includes = includes_1.includes;
var ksort_1 = __webpack_require__(181);
exports.ksort = ksort_1.ksort;
var merge_1 = __webpack_require__(135);
exports.merge = merge_1.merge;
var push_1 = __webpack_require__(137);
exports.push = push_1.push;
var reverse_1 = __webpack_require__(328);
exports.reverse = reverse_1.reverse;
var slice_1 = __webpack_require__(326);
exports.slice = slice_1.slice;


/***/ }),
/* 241 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Return the absolute value of a number.
 *
 * @param {number} x
 * @returns {number}
 */
function abs(x) {
    return Math.abs(x);
}
exports.abs = abs;


/***/ }),
/* 242 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function examineObject(object) {
    let properties = [];
    if (object) {
        for (let property of Object.getOwnPropertyNames(object)) {
            properties.push(property);
        }
        let prototype = Object.getPrototypeOf(object);
        properties = properties.concat(examineObject(prototype));
    }
    return properties;
}
exports.examineObject = examineObject;


/***/ }),
/* 243 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const pad = __webpack_require__(409);
const padStart = function (value, length, padString) {
    let result = '' + value;
    result = pad(length, result, padString);
    return result;
};
/**
 *
 * @param {"luxon".luxon.Duration} duration
 * @param {string} format
 * @returns {string} The formatted interval.
 */
function formatDuration(duration, format) {
    let result;
    result = format.replace(/%([YyMmDdaHhIiSsFfRr])/g, function (match, token) {
        let result;
        let isNegative = false;
        if (duration.as('milliseconds') < 0) {
            isNegative = true;
            duration = duration.negate();
        }
        switch (token) {
            case 'Y': {
                // 	Years, numeric, at least 2 digits with leading 0
                result = padStart(duration.years, 2, '0');
                break;
            }
            case 'y': {
                // Years, numeric
                result = duration.years;
                break;
            }
            case 'M': {
                // Months, numeric, at least 2 digits with leading 0
                result = padStart(duration.months, 2, '0');
                break;
            }
            case 'm': {
                // Months, numeric
                result = duration.months;
                break;
            }
            case 'D': {
                // Days, numeric, at least 2 digits with leading 0
                result = padStart(duration.days, 2, '0');
                break;
            }
            case 'd':
            case 'a': {
                // Days, numeric
                // Total number of days as a result of a DateTime::diff() or (unknown) otherwise
                result = duration.days;
                break;
            }
            case 'H': {
                // Hours, numeric, at least 2 digits with leading 0
                result = padStart(duration.hours, 2, '0');
                break;
            }
            case 'h': {
                // Hours, numeric
                result = duration.hours;
                break;
            }
            case 'I': {
                // Minutes, numeric, at least 2 digits with leading 0
                result = padStart(duration.minutes, 2, '0');
                break;
            }
            case 'i': {
                // 	Minutes, numeric
                result = duration.minutes;
                break;
            }
            case 'S': {
                // 	Seconds, numeric, at least 2 digits with leading 0
                result = padStart(duration.seconds, 2, '0');
                break;
            }
            case 's': {
                // Seconds, numeric
                result = duration.seconds;
                break;
            }
            case 'F': {
                // Microseconds, numeric, at least 6 digits with leading 0
                result = padStart(duration.milliseconds * 1000, 6, '0');
                break;
            }
            case 'f': {
                // Microseconds, numeric
                result = duration.milliseconds * 1000;
                break;
            }
            case 'R': {
                // Sign "-" when negative, "+" when positive
                result = isNegative ? '-' : '+';
                break;
            }
            case 'r': {
                // Sign "-" when negative, empty when positive
                result = isNegative ? '-' : '';
                break;
            }
        }
        return result;
    });
    return result;
}
exports.formatDuration = formatDuration;


/***/ }),
/* 244 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * For the formats reference, @see https://secure.php.net/manual/en/function.date.php
 */
const formatters = {
    d: (dateTime) => {
        /**
         * Day of the month, 2 digits with leading zeros
         */
        return dateTime.toFormat('dd');
    },
    D: (dateTime) => {
        /**
         * A textual representation of a day, three letters
         */
        return dateTime.weekdayShort;
    },
    j: (dateTime) => {
        /**
         * Day of the month without leading zeros
         */
        return dateTime.day;
    },
    l: (dateTime) => {
        /**
         * A full textual representation of the day of the week
         */
        return dateTime.weekdayLong;
    },
    N: (dateTime) => {
        /**
         * ISO-8601 numeric representation of the day of the week (starting from 1)
         */
        return dateTime.weekday;
    },
    S: (dateTime) => {
        /**
         * English ordinal suffix for the day of the month, 2 characters
         */
        const day = dateTime.day;
        if ((day >= 10) && (day <= 20)) {
            return 'th';
        }
        switch (day % 10) {
            case 1:
                return 'st';
            case 2:
                return 'nd';
            case 3:
                return 'rd';
            default:
                return 'th';
        }
    },
    w: (dateTime) => {
        /**
         * Numeric representation of the day of the week (starting from 0)
         */
        return dateTime.weekday - 1;
    },
    z: (dateTime) => {
        /**
         * The day of the year (starting from 0)
         */
        return dateTime.ordinal - 1;
    },
    L: (dateTime) => {
        /**
         * Whether it's a leap year
         */
        return dateTime.isInLeapYear ? 1 : 0;
    },
    o: (dateTime) => {
        /**
         * ISO-8601 week-numbering year. This has the same value as Y, except that if the ISO week number (W) belongs to the previous or next year, that year is used instead.
         */
        return formatters.Y(dateTime);
    },
    W: (dateTime) => {
        /**
         * ISO-8601 week number of year, weeks starting on Monday
         */
        return dateTime.toFormat('WW');
    },
    F: (dateTime) => {
        /**
         * A full textual representation of a month, such as January or March
         */
        return dateTime.toFormat('LLLL');
    },
    m: (dateTime) => {
        /**
         * Numeric representation of a month, with leading zeros
         */
        return dateTime.toFormat('LL');
    },
    M: (dateTime) => {
        /**
         * A short textual representation of a month, three letters
         */
        return dateTime.toFormat('LLL');
    },
    n: (dateTime) => {
        /**
         * Numeric representation of a month, without leading zero
         */
        return dateTime.toFormat('L');
    },
    t: (dateTime) => {
        /**
         * Number of days in the given month
         */
        return dateTime.daysInMonth;
    },
    Y: (dateTime) => {
        /**
         * A full numeric representation of a year, 4 digits
         */
        return dateTime.toFormat('yyyy');
    },
    y: (dateTime) => {
        /**
         * A two digit representation of a year
         */
        return dateTime.toFormat('yy');
    },
    a: (dateTime) => {
        /**
         * Lowercase Ante meridiem and Post meridiem
         */
        return formatters.A(dateTime).toLowerCase();
    },
    A: (dateTime) => {
        /**
         * Uppercase Ante meridiem and Post meridiem
         */
        return dateTime.toFormat('a');
    },
    B: (dateTime) => {
        /**
         * Swatch Internet time
         */
        return Math.floor((dateTime.second + (dateTime.minute * 60) + (dateTime.hour * 3600)) / 86.4);
    },
    g: (dateTime) => {
        /**
         * 12-hour format of an hour without leading zeros
         */
        return dateTime.toFormat('h');
    },
    G: (dateTime) => {
        /**
         * 24-hour format of an hour without leading zeros
         */
        return dateTime.toFormat('H');
    },
    h: (dateTime) => {
        /**
         * 12-hour format of an hour with leading zeros
         */
        return dateTime.toFormat('hh');
    },
    H: (dateTime) => {
        /**
         * 24-hour format of an hour with leading zeros
         */
        return dateTime.toFormat('HH');
    },
    i: (dateTime) => {
        /**
         * Minutes with leading zeros
         */
        return dateTime.toFormat('mm');
    },
    s: (dateTime) => {
        /**
         * Seconds, with leading zeros
         */
        return dateTime.toFormat('ss');
    },
    u: (dateTime) => {
        /**
         * Microseconds
         */
        return dateTime.millisecond * 1000;
    },
    v: (dateTime) => {
        /**
         * Milliseconds
         */
        return dateTime.millisecond;
    },
    e: (dateTime) => {
        /**
         * Timezone identifier
         */
        return dateTime.toFormat('z');
    },
    I: (dateTime) => {
        /**
         * Whether or not the date is in daylight saving time
         */
        return dateTime.isInDST ? 1 : 0;
    },
    O: (dateTime) => {
        /**
         * Difference to Greenwich time (GMT) in hours
         */
        return dateTime.toFormat('ZZZ');
    },
    P: (dateTime) => {
        /**
         * Difference to Greenwich time (GMT) with colon between hours and minutes
         */
        return dateTime.toFormat('ZZ');
    },
    T: (dateTime) => {
        /**
         * Timezone abbreviation
         */
        return dateTime.toFormat('ZZZZ');
    },
    Z: (dateTime) => {
        /**
         * Timezone offset in seconds. The offset for timezones west of UTC is always negative, and for those east of UTC is always positive.
         */
        return dateTime.offset * 60;
    },
    c: (dateTime) => {
        /**
         * ISO 8601 date
         */
        return formatDateTime(dateTime, 'Y-m-d') + 'T' + formatDateTime(dateTime, 'H:i:s') + formatters.P(dateTime);
    },
    r: (dateTime) => {
        /**
         * RFC 2822 formatted date
         */
        return formatDateTime(dateTime, 'D, d M Y H:i:s ') + formatters.O(dateTime);
    },
    U: (dateTime) => {
        /**
         * Seconds since the Unix Epoch (January 1 1970 00:00:00 GMT)
         */
        return Math.floor(dateTime.toMillis() / 1000);
    }
};
const regExp = new RegExp(`[${Object.keys(formatters).join("")}]`, 'g');
function formatDateTime(date, format) {
    return format.replace(regExp, (m) => {
        return formatters[m](date);
    });
}
exports.formatDateTime = formatDateTime;


/***/ }),
/* 245 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"a140\",\"\",62],[\"a180\",\"\",32],[\"a240\",\"\",62],[\"a280\",\"\",32],[\"a2ab\",\"\",5],[\"a2e3\",\"€\"],[\"a2ef\",\"\"],[\"a2fd\",\"\"],[\"a340\",\"\",62],[\"a380\",\"\",31,\"　\"],[\"a440\",\"\",62],[\"a480\",\"\",32],[\"a4f4\",\"\",10],[\"a540\",\"\",62],[\"a580\",\"\",32],[\"a5f7\",\"\",7],[\"a640\",\"\",62],[\"a680\",\"\",32],[\"a6b9\",\"\",7],[\"a6d9\",\"\",6],[\"a6ec\",\"\"],[\"a6f3\",\"\"],[\"a6f6\",\"\",8],[\"a740\",\"\",62],[\"a780\",\"\",32],[\"a7c2\",\"\",14],[\"a7f2\",\"\",12],[\"a896\",\"\",10],[\"a8bc\",\"\"],[\"a8bf\",\"ǹ\"],[\"a8c1\",\"\"],[\"a8ea\",\"\",20],[\"a958\",\"\"],[\"a95b\",\"\"],[\"a95d\",\"\"],[\"a989\",\"〾⿰\",11],[\"a997\",\"\",12],[\"a9f0\",\"\",14],[\"aaa1\",\"\",93],[\"aba1\",\"\",93],[\"aca1\",\"\",93],[\"ada1\",\"\",93],[\"aea1\",\"\",93],[\"afa1\",\"\",93],[\"d7fa\",\"\",4],[\"f8a1\",\"\",93],[\"f9a1\",\"\",93],[\"faa1\",\"\",93],[\"fba1\",\"\",93],[\"fca1\",\"\",93],[\"fda1\",\"\",93],[\"fe50\",\"⺁⺄㑳㑇⺈⺋㖞㘚㘎⺌⺗㥮㤘㧏㧟㩳㧐㭎㱮㳠⺧⺪䁖䅟⺮䌷⺳⺶⺷䎱䎬⺻䏝䓖䙡䙌\"],[\"fe80\",\"䜣䜩䝼䞍⻊䥇䥺䥽䦂䦃䦅䦆䦟䦛䦷䦶䲣䲟䲠䲡䱷䲢䴓\",6,\"䶮\",93]]");

/***/ }),
/* 246 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"0\",\"\\u0000\",127],[\"a140\",\"　，、。．‧；：？！︰…‥﹐﹑﹒·﹔﹕﹖﹗｜–︱—︳╴︴﹏（）︵︶｛｝︷︸〔〕︹︺【】︻︼《》︽︾〈〉︿﹀「」﹁﹂『』﹃﹄﹙﹚\"],[\"a1a1\",\"﹛﹜﹝﹞‘’“”〝〞‵′＃＆＊※§〃○●△▲◎☆★◇◆□■▽▼㊣℅¯￣＿ˍ﹉﹊﹍﹎﹋﹌﹟﹠﹡＋－×÷±√＜＞＝≦≧≠∞≒≡﹢\",4,\"～∩∪⊥∠∟⊿㏒㏑∫∮∵∴♀♂⊕⊙↑↓←→↖↗↙↘∥∣／\"],[\"a240\",\"＼∕﹨＄￥〒￠￡％＠℃℉﹩﹪﹫㏕㎜㎝㎞㏎㎡㎎㎏㏄°兙兛兞兝兡兣嗧瓩糎▁\",7,\"▏▎▍▌▋▊▉┼┴┬┤├▔─│▕┌┐└┘╭\"],[\"a2a1\",\"╮╰╯═╞╪╡◢◣◥◤╱╲╳０\",9,\"Ⅰ\",9,\"〡\",8,\"十卄卅Ａ\",25,\"ａ\",21],[\"a340\",\"ｗｘｙｚΑ\",16,\"Σ\",6,\"α\",16,\"σ\",6,\"ㄅ\",10],[\"a3a1\",\"ㄐ\",25,\"˙ˉˊˇˋ\"],[\"a3e1\",\"€\"],[\"a440\",\"一乙丁七乃九了二人儿入八几刀刁力匕十卜又三下丈上丫丸凡久么也乞于亡兀刃勺千叉口土士夕大女子孑孓寸小尢尸山川工己已巳巾干廾弋弓才\"],[\"a4a1\",\"丑丐不中丰丹之尹予云井互五亢仁什仃仆仇仍今介仄元允內六兮公冗凶分切刈勻勾勿化匹午升卅卞厄友及反壬天夫太夭孔少尤尺屯巴幻廿弔引心戈戶手扎支文斗斤方日曰月木欠止歹毋比毛氏水火爪父爻片牙牛犬王丙\"],[\"a540\",\"世丕且丘主乍乏乎以付仔仕他仗代令仙仞充兄冉冊冬凹出凸刊加功包匆北匝仟半卉卡占卯卮去可古右召叮叩叨叼司叵叫另只史叱台句叭叻四囚外\"],[\"a5a1\",\"央失奴奶孕它尼巨巧左市布平幼弁弘弗必戊打扔扒扑斥旦朮本未末札正母民氐永汁汀氾犯玄玉瓜瓦甘生用甩田由甲申疋白皮皿目矛矢石示禾穴立丞丟乒乓乩亙交亦亥仿伉伙伊伕伍伐休伏仲件任仰仳份企伋光兇兆先全\"],[\"a640\",\"共再冰列刑划刎刖劣匈匡匠印危吉吏同吊吐吁吋各向名合吃后吆吒因回囝圳地在圭圬圯圩夙多夷夸妄奸妃好她如妁字存宇守宅安寺尖屹州帆并年\"],[\"a6a1\",\"式弛忙忖戎戌戍成扣扛托收早旨旬旭曲曳有朽朴朱朵次此死氖汝汗汙江池汐汕污汛汍汎灰牟牝百竹米糸缶羊羽老考而耒耳聿肉肋肌臣自至臼舌舛舟艮色艾虫血行衣西阡串亨位住佇佗佞伴佛何估佐佑伽伺伸佃佔似但佣\"],[\"a740\",\"作你伯低伶余佝佈佚兌克免兵冶冷別判利刪刨劫助努劬匣即卵吝吭吞吾否呎吧呆呃吳呈呂君吩告吹吻吸吮吵吶吠吼呀吱含吟听囪困囤囫坊坑址坍\"],[\"a7a1\",\"均坎圾坐坏圻壯夾妝妒妨妞妣妙妖妍妤妓妊妥孝孜孚孛完宋宏尬局屁尿尾岐岑岔岌巫希序庇床廷弄弟彤形彷役忘忌志忍忱快忸忪戒我抄抗抖技扶抉扭把扼找批扳抒扯折扮投抓抑抆改攻攸旱更束李杏材村杜杖杞杉杆杠\"],[\"a840\",\"杓杗步每求汞沙沁沈沉沅沛汪決沐汰沌汨沖沒汽沃汲汾汴沆汶沍沔沘沂灶灼災灸牢牡牠狄狂玖甬甫男甸皂盯矣私秀禿究系罕肖肓肝肘肛肚育良芒\"],[\"a8a1\",\"芋芍見角言谷豆豕貝赤走足身車辛辰迂迆迅迄巡邑邢邪邦那酉釆里防阮阱阪阬並乖乳事些亞享京佯依侍佳使佬供例來侃佰併侈佩佻侖佾侏侑佺兔兒兕兩具其典冽函刻券刷刺到刮制剁劾劻卒協卓卑卦卷卸卹取叔受味呵\"],[\"a940\",\"咖呸咕咀呻呷咄咒咆呼咐呱呶和咚呢周咋命咎固垃坷坪坩坡坦坤坼夜奉奇奈奄奔妾妻委妹妮姑姆姐姍始姓姊妯妳姒姅孟孤季宗定官宜宙宛尚屈居\"],[\"a9a1\",\"屆岷岡岸岩岫岱岳帘帚帖帕帛帑幸庚店府底庖延弦弧弩往征彿彼忝忠忽念忿怏怔怯怵怖怪怕怡性怩怫怛或戕房戾所承拉拌拄抿拂抹拒招披拓拔拋拈抨抽押拐拙拇拍抵拚抱拘拖拗拆抬拎放斧於旺昔易昌昆昂明昀昏昕昊\"],[\"aa40\",\"昇服朋杭枋枕東果杳杷枇枝林杯杰板枉松析杵枚枓杼杪杲欣武歧歿氓氛泣注泳沱泌泥河沽沾沼波沫法泓沸泄油況沮泗泅泱沿治泡泛泊沬泯泜泖泠\"],[\"aaa1\",\"炕炎炒炊炙爬爭爸版牧物狀狎狙狗狐玩玨玟玫玥甽疝疙疚的盂盲直知矽社祀祁秉秈空穹竺糾罔羌羋者肺肥肢肱股肫肩肴肪肯臥臾舍芳芝芙芭芽芟芹花芬芥芯芸芣芰芾芷虎虱初表軋迎返近邵邸邱邶采金長門阜陀阿阻附\"],[\"ab40\",\"陂隹雨青非亟亭亮信侵侯便俠俑俏保促侶俘俟俊俗侮俐俄係俚俎俞侷兗冒冑冠剎剃削前剌剋則勇勉勃勁匍南卻厚叛咬哀咨哎哉咸咦咳哇哂咽咪品\"],[\"aba1\",\"哄哈咯咫咱咻咩咧咿囿垂型垠垣垢城垮垓奕契奏奎奐姜姘姿姣姨娃姥姪姚姦威姻孩宣宦室客宥封屎屏屍屋峙峒巷帝帥帟幽庠度建弈弭彥很待徊律徇後徉怒思怠急怎怨恍恰恨恢恆恃恬恫恪恤扁拜挖按拼拭持拮拽指拱拷\"],[\"ac40\",\"拯括拾拴挑挂政故斫施既春昭映昧是星昨昱昤曷柿染柱柔某柬架枯柵柩柯柄柑枴柚查枸柏柞柳枰柙柢柝柒歪殃殆段毒毗氟泉洋洲洪流津洌洱洞洗\"],[\"aca1\",\"活洽派洶洛泵洹洧洸洩洮洵洎洫炫為炳炬炯炭炸炮炤爰牲牯牴狩狠狡玷珊玻玲珍珀玳甚甭畏界畎畋疫疤疥疢疣癸皆皇皈盈盆盃盅省盹相眉看盾盼眇矜砂研砌砍祆祉祈祇禹禺科秒秋穿突竿竽籽紂紅紀紉紇約紆缸美羿耄\"],[\"ad40\",\"耐耍耑耶胖胥胚胃胄背胡胛胎胞胤胝致舢苧范茅苣苛苦茄若茂茉苒苗英茁苜苔苑苞苓苟苯茆虐虹虻虺衍衫要觔計訂訃貞負赴赳趴軍軌述迦迢迪迥\"],[\"ada1\",\"迭迫迤迨郊郎郁郃酋酊重閂限陋陌降面革韋韭音頁風飛食首香乘亳倌倍倣俯倦倥俸倩倖倆值借倚倒們俺倀倔倨俱倡個候倘俳修倭倪俾倫倉兼冤冥冢凍凌准凋剖剜剔剛剝匪卿原厝叟哨唐唁唷哼哥哲唆哺唔哩哭員唉哮哪\"],[\"ae40\",\"哦唧唇哽唏圃圄埂埔埋埃堉夏套奘奚娑娘娜娟娛娓姬娠娣娩娥娌娉孫屘宰害家宴宮宵容宸射屑展屐峭峽峻峪峨峰島崁峴差席師庫庭座弱徒徑徐恙\"],[\"aea1\",\"恣恥恐恕恭恩息悄悟悚悍悔悌悅悖扇拳挈拿捎挾振捕捂捆捏捉挺捐挽挪挫挨捍捌效敉料旁旅時晉晏晃晒晌晅晁書朔朕朗校核案框桓根桂桔栩梳栗桌桑栽柴桐桀格桃株桅栓栘桁殊殉殷氣氧氨氦氤泰浪涕消涇浦浸海浙涓\"],[\"af40\",\"浬涉浮浚浴浩涌涊浹涅浥涔烊烘烤烙烈烏爹特狼狹狽狸狷玆班琉珮珠珪珞畔畝畜畚留疾病症疲疳疽疼疹痂疸皋皰益盍盎眩真眠眨矩砰砧砸砝破砷\"],[\"afa1\",\"砥砭砠砟砲祕祐祠祟祖神祝祗祚秤秣秧租秦秩秘窄窈站笆笑粉紡紗紋紊素索純紐紕級紜納紙紛缺罟羔翅翁耆耘耕耙耗耽耿胱脂胰脅胭胴脆胸胳脈能脊胼胯臭臬舀舐航舫舨般芻茫荒荔荊茸荐草茵茴荏茲茹茶茗荀茱茨荃\"],[\"b040\",\"虔蚊蚪蚓蚤蚩蚌蚣蚜衰衷袁袂衽衹記訐討訌訕訊託訓訖訏訑豈豺豹財貢起躬軒軔軏辱送逆迷退迺迴逃追逅迸邕郡郝郢酒配酌釘針釗釜釙閃院陣陡\"],[\"b0a1\",\"陛陝除陘陞隻飢馬骨高鬥鬲鬼乾偺偽停假偃偌做偉健偶偎偕偵側偷偏倏偯偭兜冕凰剪副勒務勘動匐匏匙匿區匾參曼商啪啦啄啞啡啃啊唱啖問啕唯啤唸售啜唬啣唳啁啗圈國圉域堅堊堆埠埤基堂堵執培夠奢娶婁婉婦婪婀\"],[\"b140\",\"娼婢婚婆婊孰寇寅寄寂宿密尉專將屠屜屝崇崆崎崛崖崢崑崩崔崙崤崧崗巢常帶帳帷康庸庶庵庾張強彗彬彩彫得徙從徘御徠徜恿患悉悠您惋悴惦悽\"],[\"b1a1\",\"情悻悵惜悼惘惕惆惟悸惚惇戚戛扈掠控捲掖探接捷捧掘措捱掩掉掃掛捫推掄授掙採掬排掏掀捻捩捨捺敝敖救教敗啟敏敘敕敔斜斛斬族旋旌旎晝晚晤晨晦晞曹勗望梁梯梢梓梵桿桶梱梧梗械梃棄梭梆梅梔條梨梟梡梂欲殺\"],[\"b240\",\"毫毬氫涎涼淳淙液淡淌淤添淺清淇淋涯淑涮淞淹涸混淵淅淒渚涵淚淫淘淪深淮淨淆淄涪淬涿淦烹焉焊烽烯爽牽犁猜猛猖猓猙率琅琊球理現琍瓠瓶\"],[\"b2a1\",\"瓷甜產略畦畢異疏痔痕疵痊痍皎盔盒盛眷眾眼眶眸眺硫硃硎祥票祭移窒窕笠笨笛第符笙笞笮粒粗粕絆絃統紮紹紼絀細紳組累終紲紱缽羞羚翌翎習耜聊聆脯脖脣脫脩脰脤舂舵舷舶船莎莞莘荸莢莖莽莫莒莊莓莉莠荷荻荼\"],[\"b340\",\"莆莧處彪蛇蛀蚶蛄蚵蛆蛋蚱蚯蛉術袞袈被袒袖袍袋覓規訪訝訣訥許設訟訛訢豉豚販責貫貨貪貧赧赦趾趺軛軟這逍通逗連速逝逐逕逞造透逢逖逛途\"],[\"b3a1\",\"部郭都酗野釵釦釣釧釭釩閉陪陵陳陸陰陴陶陷陬雀雪雩章竟頂頃魚鳥鹵鹿麥麻傢傍傅備傑傀傖傘傚最凱割剴創剩勞勝勛博厥啻喀喧啼喊喝喘喂喜喪喔喇喋喃喳單喟唾喲喚喻喬喱啾喉喫喙圍堯堪場堤堰報堡堝堠壹壺奠\"],[\"b440\",\"婷媚婿媒媛媧孳孱寒富寓寐尊尋就嵌嵐崴嵇巽幅帽幀幃幾廊廁廂廄弼彭復循徨惑惡悲悶惠愜愣惺愕惰惻惴慨惱愎惶愉愀愒戟扉掣掌描揀揩揉揆揍\"],[\"b4a1\",\"插揣提握揖揭揮捶援揪換摒揚揹敞敦敢散斑斐斯普晰晴晶景暑智晾晷曾替期朝棺棕棠棘棗椅棟棵森棧棹棒棲棣棋棍植椒椎棉棚楮棻款欺欽殘殖殼毯氮氯氬港游湔渡渲湧湊渠渥渣減湛湘渤湖湮渭渦湯渴湍渺測湃渝渾滋\"],[\"b540\",\"溉渙湎湣湄湲湩湟焙焚焦焰無然煮焜牌犄犀猶猥猴猩琺琪琳琢琥琵琶琴琯琛琦琨甥甦畫番痢痛痣痙痘痞痠登發皖皓皴盜睏短硝硬硯稍稈程稅稀窘\"],[\"b5a1\",\"窗窖童竣等策筆筐筒答筍筋筏筑粟粥絞結絨絕紫絮絲絡給絢絰絳善翔翕耋聒肅腕腔腋腑腎脹腆脾腌腓腴舒舜菩萃菸萍菠菅萋菁華菱菴著萊菰萌菌菽菲菊萸萎萄菜萇菔菟虛蛟蛙蛭蛔蛛蛤蛐蛞街裁裂袱覃視註詠評詞証詁\"],[\"b640\",\"詔詛詐詆訴診訶詖象貂貯貼貳貽賁費賀貴買貶貿貸越超趁跎距跋跚跑跌跛跆軻軸軼辜逮逵週逸進逶鄂郵鄉郾酣酥量鈔鈕鈣鈉鈞鈍鈐鈇鈑閔閏開閑\"],[\"b6a1\",\"間閒閎隊階隋陽隅隆隍陲隄雁雅雄集雇雯雲韌項順須飧飪飯飩飲飭馮馭黃黍黑亂傭債傲傳僅傾催傷傻傯僇剿剷剽募勦勤勢勣匯嗟嗨嗓嗦嗎嗜嗇嗑嗣嗤嗯嗚嗡嗅嗆嗥嗉園圓塞塑塘塗塚塔填塌塭塊塢塒塋奧嫁嫉嫌媾媽媼\"],[\"b740\",\"媳嫂媲嵩嵯幌幹廉廈弒彙徬微愚意慈感想愛惹愁愈慎慌慄慍愾愴愧愍愆愷戡戢搓搾搞搪搭搽搬搏搜搔損搶搖搗搆敬斟新暗暉暇暈暖暄暘暍會榔業\"],[\"b7a1\",\"楚楷楠楔極椰概楊楨楫楞楓楹榆楝楣楛歇歲毀殿毓毽溢溯滓溶滂源溝滇滅溥溘溼溺溫滑準溜滄滔溪溧溴煎煙煩煤煉照煜煬煦煌煥煞煆煨煖爺牒猷獅猿猾瑯瑚瑕瑟瑞瑁琿瑙瑛瑜當畸瘀痰瘁痲痱痺痿痴痳盞盟睛睫睦睞督\"],[\"b840\",\"睹睪睬睜睥睨睢矮碎碰碗碘碌碉硼碑碓硿祺祿禁萬禽稜稚稠稔稟稞窟窠筷節筠筮筧粱粳粵經絹綑綁綏絛置罩罪署義羨群聖聘肆肄腱腰腸腥腮腳腫\"],[\"b8a1\",\"腹腺腦舅艇蒂葷落萱葵葦葫葉葬葛萼萵葡董葩葭葆虞虜號蛹蜓蜈蜇蜀蛾蛻蜂蜃蜆蜊衙裟裔裙補裘裝裡裊裕裒覜解詫該詳試詩詰誇詼詣誠話誅詭詢詮詬詹詻訾詨豢貊貉賊資賈賄貲賃賂賅跡跟跨路跳跺跪跤跦躲較載軾輊\"],[\"b940\",\"辟農運遊道遂達逼違遐遇遏過遍遑逾遁鄒鄗酬酪酩釉鈷鉗鈸鈽鉀鈾鉛鉋鉤鉑鈴鉉鉍鉅鈹鈿鉚閘隘隔隕雍雋雉雊雷電雹零靖靴靶預頑頓頊頒頌飼飴\"],[\"b9a1\",\"飽飾馳馱馴髡鳩麂鼎鼓鼠僧僮僥僖僭僚僕像僑僱僎僩兢凳劃劂匱厭嗾嘀嘛嘗嗽嘔嘆嘉嘍嘎嗷嘖嘟嘈嘐嗶團圖塵塾境墓墊塹墅塽壽夥夢夤奪奩嫡嫦嫩嫗嫖嫘嫣孵寞寧寡寥實寨寢寤察對屢嶄嶇幛幣幕幗幔廓廖弊彆彰徹慇\"],[\"ba40\",\"愿態慷慢慣慟慚慘慵截撇摘摔撤摸摟摺摑摧搴摭摻敲斡旗旖暢暨暝榜榨榕槁榮槓構榛榷榻榫榴槐槍榭槌榦槃榣歉歌氳漳演滾漓滴漩漾漠漬漏漂漢\"],[\"baa1\",\"滿滯漆漱漸漲漣漕漫漯澈漪滬漁滲滌滷熔熙煽熊熄熒爾犒犖獄獐瑤瑣瑪瑰瑭甄疑瘧瘍瘋瘉瘓盡監瞄睽睿睡磁碟碧碳碩碣禎福禍種稱窪窩竭端管箕箋筵算箝箔箏箸箇箄粹粽精綻綰綜綽綾綠緊綴網綱綺綢綿綵綸維緒緇綬\"],[\"bb40\",\"罰翠翡翟聞聚肇腐膀膏膈膊腿膂臧臺與舔舞艋蓉蒿蓆蓄蒙蒞蒲蒜蓋蒸蓀蓓蒐蒼蓑蓊蜿蜜蜻蜢蜥蜴蜘蝕蜷蜩裳褂裴裹裸製裨褚裯誦誌語誣認誡誓誤\"],[\"bba1\",\"說誥誨誘誑誚誧豪貍貌賓賑賒赫趙趕跼輔輒輕輓辣遠遘遜遣遙遞遢遝遛鄙鄘鄞酵酸酷酴鉸銀銅銘銖鉻銓銜銨鉼銑閡閨閩閣閥閤隙障際雌雒需靼鞅韶頗領颯颱餃餅餌餉駁骯骰髦魁魂鳴鳶鳳麼鼻齊億儀僻僵價儂儈儉儅凜\"],[\"bc40\",\"劇劈劉劍劊勰厲嘮嘻嘹嘲嘿嘴嘩噓噎噗噴嘶嘯嘰墀墟增墳墜墮墩墦奭嬉嫻嬋嫵嬌嬈寮寬審寫層履嶝嶔幢幟幡廢廚廟廝廣廠彈影德徵慶慧慮慝慕憂\"],[\"bca1\",\"慼慰慫慾憧憐憫憎憬憚憤憔憮戮摩摯摹撞撲撈撐撰撥撓撕撩撒撮播撫撚撬撙撢撳敵敷數暮暫暴暱樣樟槨樁樞標槽模樓樊槳樂樅槭樑歐歎殤毅毆漿潼澄潑潦潔澆潭潛潸潮澎潺潰潤澗潘滕潯潠潟熟熬熱熨牖犛獎獗瑩璋璃\"],[\"bd40\",\"瑾璀畿瘠瘩瘟瘤瘦瘡瘢皚皺盤瞎瞇瞌瞑瞋磋磅確磊碾磕碼磐稿稼穀稽稷稻窯窮箭箱範箴篆篇篁箠篌糊締練緯緻緘緬緝編緣線緞緩綞緙緲緹罵罷羯\"],[\"bda1\",\"翩耦膛膜膝膠膚膘蔗蔽蔚蓮蔬蔭蔓蔑蔣蔡蔔蓬蔥蓿蔆螂蝴蝶蝠蝦蝸蝨蝙蝗蝌蝓衛衝褐複褒褓褕褊誼諒談諄誕請諸課諉諂調誰論諍誶誹諛豌豎豬賠賞賦賤賬賭賢賣賜質賡赭趟趣踫踐踝踢踏踩踟踡踞躺輝輛輟輩輦輪輜輞\"],[\"be40\",\"輥適遮遨遭遷鄰鄭鄧鄱醇醉醋醃鋅銻銷鋪銬鋤鋁銳銼鋒鋇鋰銲閭閱霄霆震霉靠鞍鞋鞏頡頫頜颳養餓餒餘駝駐駟駛駑駕駒駙骷髮髯鬧魅魄魷魯鴆鴉\"],[\"bea1\",\"鴃麩麾黎墨齒儒儘儔儐儕冀冪凝劑劓勳噙噫噹噩噤噸噪器噥噱噯噬噢噶壁墾壇壅奮嬝嬴學寰導彊憲憑憩憊懍憶憾懊懈戰擅擁擋撻撼據擄擇擂操撿擒擔撾整曆曉暹曄曇暸樽樸樺橙橫橘樹橄橢橡橋橇樵機橈歙歷氅濂澱澡\"],[\"bf40\",\"濃澤濁澧澳激澹澶澦澠澴熾燉燐燒燈燕熹燎燙燜燃燄獨璜璣璘璟璞瓢甌甍瘴瘸瘺盧盥瞠瞞瞟瞥磨磚磬磧禦積穎穆穌穋窺篙簑築篤篛篡篩篦糕糖縊\"],[\"bfa1\",\"縑縈縛縣縞縝縉縐罹羲翰翱翮耨膳膩膨臻興艘艙蕊蕙蕈蕨蕩蕃蕉蕭蕪蕞螃螟螞螢融衡褪褲褥褫褡親覦諦諺諫諱謀諜諧諮諾謁謂諷諭諳諶諼豫豭貓賴蹄踱踴蹂踹踵輻輯輸輳辨辦遵遴選遲遼遺鄴醒錠錶鋸錳錯錢鋼錫錄錚\"],[\"c040\",\"錐錦錡錕錮錙閻隧隨險雕霎霑霖霍霓霏靛靜靦鞘頰頸頻頷頭頹頤餐館餞餛餡餚駭駢駱骸骼髻髭鬨鮑鴕鴣鴦鴨鴒鴛默黔龍龜優償儡儲勵嚎嚀嚐嚅嚇\"],[\"c0a1\",\"嚏壕壓壑壎嬰嬪嬤孺尷屨嶼嶺嶽嶸幫彌徽應懂懇懦懋戲戴擎擊擘擠擰擦擬擱擢擭斂斃曙曖檀檔檄檢檜櫛檣橾檗檐檠歜殮毚氈濘濱濟濠濛濤濫濯澀濬濡濩濕濮濰燧營燮燦燥燭燬燴燠爵牆獰獲璩環璦璨癆療癌盪瞳瞪瞰瞬\"],[\"c140\",\"瞧瞭矯磷磺磴磯礁禧禪穗窿簇簍篾篷簌篠糠糜糞糢糟糙糝縮績繆縷縲繃縫總縱繅繁縴縹繈縵縿縯罄翳翼聱聲聰聯聳臆臃膺臂臀膿膽臉膾臨舉艱薪\"],[\"c1a1\",\"薄蕾薜薑薔薯薛薇薨薊虧蟀蟑螳蟒蟆螫螻螺蟈蟋褻褶襄褸褽覬謎謗謙講謊謠謝謄謐豁谿豳賺賽購賸賻趨蹉蹋蹈蹊轄輾轂轅輿避遽還邁邂邀鄹醣醞醜鍍鎂錨鍵鍊鍥鍋錘鍾鍬鍛鍰鍚鍔闊闋闌闈闆隱隸雖霜霞鞠韓顆颶餵騁\"],[\"c240\",\"駿鮮鮫鮪鮭鴻鴿麋黏點黜黝黛鼾齋叢嚕嚮壙壘嬸彝懣戳擴擲擾攆擺擻擷斷曜朦檳檬櫃檻檸櫂檮檯歟歸殯瀉瀋濾瀆濺瀑瀏燻燼燾燸獷獵璧璿甕癖癘\"],[\"c2a1\",\"癒瞽瞿瞻瞼礎禮穡穢穠竄竅簫簧簪簞簣簡糧織繕繞繚繡繒繙罈翹翻職聶臍臏舊藏薩藍藐藉薰薺薹薦蟯蟬蟲蟠覆覲觴謨謹謬謫豐贅蹙蹣蹦蹤蹟蹕軀轉轍邇邃邈醫醬釐鎔鎊鎖鎢鎳鎮鎬鎰鎘鎚鎗闔闖闐闕離雜雙雛雞霤鞣鞦\"],[\"c340\",\"鞭韹額顏題顎顓颺餾餿餽餮馥騎髁鬃鬆魏魎魍鯊鯉鯽鯈鯀鵑鵝鵠黠鼕鼬儳嚥壞壟壢寵龐廬懲懷懶懵攀攏曠曝櫥櫝櫚櫓瀛瀟瀨瀚瀝瀕瀘爆爍牘犢獸\"],[\"c3a1\",\"獺璽瓊瓣疇疆癟癡矇礙禱穫穩簾簿簸簽簷籀繫繭繹繩繪羅繳羶羹羸臘藩藝藪藕藤藥藷蟻蠅蠍蟹蟾襠襟襖襞譁譜識證譚譎譏譆譙贈贊蹼蹲躇蹶蹬蹺蹴轔轎辭邊邋醱醮鏡鏑鏟鏃鏈鏜鏝鏖鏢鏍鏘鏤鏗鏨關隴難霪霧靡韜韻類\"],[\"c440\",\"願顛颼饅饉騖騙鬍鯨鯧鯖鯛鶉鵡鵲鵪鵬麒麗麓麴勸嚨嚷嚶嚴嚼壤孀孃孽寶巉懸懺攘攔攙曦朧櫬瀾瀰瀲爐獻瓏癢癥礦礪礬礫竇競籌籃籍糯糰辮繽繼\"],[\"c4a1\",\"纂罌耀臚艦藻藹蘑藺蘆蘋蘇蘊蠔蠕襤覺觸議譬警譯譟譫贏贍躉躁躅躂醴釋鐘鐃鏽闡霰飄饒饑馨騫騰騷騵鰓鰍鹹麵黨鼯齟齣齡儷儸囁囀囂夔屬巍懼懾攝攜斕曩櫻欄櫺殲灌爛犧瓖瓔癩矓籐纏續羼蘗蘭蘚蠣蠢蠡蠟襪襬覽譴\"],[\"c540\",\"護譽贓躊躍躋轟辯醺鐮鐳鐵鐺鐸鐲鐫闢霸霹露響顧顥饗驅驃驀騾髏魔魑鰭鰥鶯鶴鷂鶸麝黯鼙齜齦齧儼儻囈囊囉孿巔巒彎懿攤權歡灑灘玀瓤疊癮癬\"],[\"c5a1\",\"禳籠籟聾聽臟襲襯觼讀贖贗躑躓轡酈鑄鑑鑒霽霾韃韁顫饕驕驍髒鬚鱉鰱鰾鰻鷓鷗鼴齬齪龔囌巖戀攣攫攪曬欐瓚竊籤籣籥纓纖纔臢蘸蘿蠱變邐邏鑣鑠鑤靨顯饜驚驛驗髓體髑鱔鱗鱖鷥麟黴囑壩攬灞癱癲矗罐羈蠶蠹衢讓讒\"],[\"c640\",\"讖艷贛釀鑪靂靈靄韆顰驟鬢魘鱟鷹鷺鹼鹽鼇齷齲廳欖灣籬籮蠻觀躡釁鑲鑰顱饞髖鬣黌灤矚讚鑷韉驢驥纜讜躪釅鑽鑾鑼鱷鱸黷豔鑿鸚爨驪鬱鸛鸞籲\"],[\"c940\",\"乂乜凵匚厂万丌乇亍囗兀屮彳丏冇与丮亓仂仉仈冘勼卬厹圠夃夬尐巿旡殳毌气爿丱丼仨仜仩仡仝仚刌匜卌圢圣夗夯宁宄尒尻屴屳帄庀庂忉戉扐氕\"],[\"c9a1\",\"氶汃氿氻犮犰玊禸肊阞伎优伬仵伔仱伀价伈伝伂伅伢伓伄仴伒冱刓刉刐劦匢匟卍厊吇囡囟圮圪圴夼妀奼妅奻奾奷奿孖尕尥屼屺屻屾巟幵庄异弚彴忕忔忏扜扞扤扡扦扢扙扠扚扥旯旮朾朹朸朻机朿朼朳氘汆汒汜汏汊汔汋\"],[\"ca40\",\"汌灱牞犴犵玎甪癿穵网艸艼芀艽艿虍襾邙邗邘邛邔阢阤阠阣佖伻佢佉体佤伾佧佒佟佁佘伭伳伿佡冏冹刜刞刡劭劮匉卣卲厎厏吰吷吪呔呅吙吜吥吘\"],[\"caa1\",\"吽呏呁吨吤呇囮囧囥坁坅坌坉坋坒夆奀妦妘妠妗妎妢妐妏妧妡宎宒尨尪岍岏岈岋岉岒岊岆岓岕巠帊帎庋庉庌庈庍弅弝彸彶忒忑忐忭忨忮忳忡忤忣忺忯忷忻怀忴戺抃抌抎抏抔抇扱扻扺扰抁抈扷扽扲扴攷旰旴旳旲旵杅杇\"],[\"cb40\",\"杙杕杌杈杝杍杚杋毐氙氚汸汧汫沄沋沏汱汯汩沚汭沇沕沜汦汳汥汻沎灴灺牣犿犽狃狆狁犺狅玕玗玓玔玒町甹疔疕皁礽耴肕肙肐肒肜芐芏芅芎芑芓\"],[\"cba1\",\"芊芃芄豸迉辿邟邡邥邞邧邠阰阨阯阭丳侘佼侅佽侀侇佶佴侉侄佷佌侗佪侚佹侁佸侐侜侔侞侒侂侕佫佮冞冼冾刵刲刳剆刱劼匊匋匼厒厔咇呿咁咑咂咈呫呺呾呥呬呴呦咍呯呡呠咘呣呧呤囷囹坯坲坭坫坱坰坶垀坵坻坳坴坢\"],[\"cc40\",\"坨坽夌奅妵妺姏姎妲姌姁妶妼姃姖妱妽姀姈妴姇孢孥宓宕屄屇岮岤岠岵岯岨岬岟岣岭岢岪岧岝岥岶岰岦帗帔帙弨弢弣弤彔徂彾彽忞忥怭怦怙怲怋\"],[\"cca1\",\"怴怊怗怳怚怞怬怢怍怐怮怓怑怌怉怜戔戽抭抴拑抾抪抶拊抮抳抯抻抩抰抸攽斨斻昉旼昄昒昈旻昃昋昍昅旽昑昐曶朊枅杬枎枒杶杻枘枆构杴枍枌杺枟枑枙枃杽极杸杹枔欥殀歾毞氝沓泬泫泮泙沶泔沭泧沷泐泂沺泃泆泭泲\"],[\"cd40\",\"泒泝沴沊沝沀泞泀洰泍泇沰泹泏泩泑炔炘炅炓炆炄炑炖炂炚炃牪狖狋狘狉狜狒狔狚狌狑玤玡玭玦玢玠玬玝瓝瓨甿畀甾疌疘皯盳盱盰盵矸矼矹矻矺\"],[\"cda1\",\"矷祂礿秅穸穻竻籵糽耵肏肮肣肸肵肭舠芠苀芫芚芘芛芵芧芮芼芞芺芴芨芡芩苂芤苃芶芢虰虯虭虮豖迒迋迓迍迖迕迗邲邴邯邳邰阹阽阼阺陃俍俅俓侲俉俋俁俔俜俙侻侳俛俇俖侺俀侹俬剄剉勀勂匽卼厗厖厙厘咺咡咭咥哏\"],[\"ce40\",\"哃茍咷咮哖咶哅哆咠呰咼咢咾呲哞咰垵垞垟垤垌垗垝垛垔垘垏垙垥垚垕壴复奓姡姞姮娀姱姝姺姽姼姶姤姲姷姛姩姳姵姠姾姴姭宨屌峐峘峌峗峋峛\"],[\"cea1\",\"峞峚峉峇峊峖峓峔峏峈峆峎峟峸巹帡帢帣帠帤庰庤庢庛庣庥弇弮彖徆怷怹恔恲恞恅恓恇恉恛恌恀恂恟怤恄恘恦恮扂扃拏挍挋拵挎挃拫拹挏挌拸拶挀挓挔拺挕拻拰敁敃斪斿昶昡昲昵昜昦昢昳昫昺昝昴昹昮朏朐柁柲柈枺\"],[\"cf40\",\"柜枻柸柘柀枷柅柫柤柟枵柍枳柷柶柮柣柂枹柎柧柰枲柼柆柭柌枮柦柛柺柉柊柃柪柋欨殂殄殶毖毘毠氠氡洨洴洭洟洼洿洒洊泚洳洄洙洺洚洑洀洝浂\"],[\"cfa1\",\"洁洘洷洃洏浀洇洠洬洈洢洉洐炷炟炾炱炰炡炴炵炩牁牉牊牬牰牳牮狊狤狨狫狟狪狦狣玅珌珂珈珅玹玶玵玴珫玿珇玾珃珆玸珋瓬瓮甮畇畈疧疪癹盄眈眃眄眅眊盷盻盺矧矨砆砑砒砅砐砏砎砉砃砓祊祌祋祅祄秕种秏秖秎窀\"],[\"d040\",\"穾竑笀笁籺籸籹籿粀粁紃紈紁罘羑羍羾耇耎耏耔耷胘胇胠胑胈胂胐胅胣胙胜胊胕胉胏胗胦胍臿舡芔苙苾苹茇苨茀苕茺苫苖苴苬苡苲苵茌苻苶苰苪\"],[\"d0a1\",\"苤苠苺苳苭虷虴虼虳衁衎衧衪衩觓訄訇赲迣迡迮迠郱邽邿郕郅邾郇郋郈釔釓陔陏陑陓陊陎倞倅倇倓倢倰倛俵俴倳倷倬俶俷倗倜倠倧倵倯倱倎党冔冓凊凄凅凈凎剡剚剒剞剟剕剢勍匎厞唦哢唗唒哧哳哤唚哿唄唈哫唑唅哱\"],[\"d140\",\"唊哻哷哸哠唎唃唋圁圂埌堲埕埒垺埆垽垼垸垶垿埇埐垹埁夎奊娙娖娭娮娕娏娗娊娞娳孬宧宭宬尃屖屔峬峿峮峱峷崀峹帩帨庨庮庪庬弳弰彧恝恚恧\"],[\"d1a1\",\"恁悢悈悀悒悁悝悃悕悛悗悇悜悎戙扆拲挐捖挬捄捅挶捃揤挹捋捊挼挩捁挴捘捔捙挭捇挳捚捑挸捗捀捈敊敆旆旃旄旂晊晟晇晑朒朓栟栚桉栲栳栻桋桏栖栱栜栵栫栭栯桎桄栴栝栒栔栦栨栮桍栺栥栠欬欯欭欱欴歭肂殈毦毤\"],[\"d240\",\"毨毣毢毧氥浺浣浤浶洍浡涒浘浢浭浯涑涍淯浿涆浞浧浠涗浰浼浟涂涘洯浨涋浾涀涄洖涃浻浽浵涐烜烓烑烝烋缹烢烗烒烞烠烔烍烅烆烇烚烎烡牂牸\"],[\"d2a1\",\"牷牶猀狺狴狾狶狳狻猁珓珙珥珖玼珧珣珩珜珒珛珔珝珚珗珘珨瓞瓟瓴瓵甡畛畟疰痁疻痄痀疿疶疺皊盉眝眛眐眓眒眣眑眕眙眚眢眧砣砬砢砵砯砨砮砫砡砩砳砪砱祔祛祏祜祓祒祑秫秬秠秮秭秪秜秞秝窆窉窅窋窌窊窇竘笐\"],[\"d340\",\"笄笓笅笏笈笊笎笉笒粄粑粊粌粈粍粅紞紝紑紎紘紖紓紟紒紏紌罜罡罞罠罝罛羖羒翃翂翀耖耾耹胺胲胹胵脁胻脀舁舯舥茳茭荄茙荑茥荖茿荁茦茜茢\"],[\"d3a1\",\"荂荎茛茪茈茼荍茖茤茠茷茯茩荇荅荌荓茞茬荋茧荈虓虒蚢蚨蚖蚍蚑蚞蚇蚗蚆蚋蚚蚅蚥蚙蚡蚧蚕蚘蚎蚝蚐蚔衃衄衭衵衶衲袀衱衿衯袃衾衴衼訒豇豗豻貤貣赶赸趵趷趶軑軓迾迵适迿迻逄迼迶郖郠郙郚郣郟郥郘郛郗郜郤酐\"],[\"d440\",\"酎酏釕釢釚陜陟隼飣髟鬯乿偰偪偡偞偠偓偋偝偲偈偍偁偛偊偢倕偅偟偩偫偣偤偆偀偮偳偗偑凐剫剭剬剮勖勓匭厜啵啶唼啍啐唴唪啑啢唶唵唰啒啅\"],[\"d4a1\",\"唌唲啥啎唹啈唭唻啀啋圊圇埻堔埢埶埜埴堀埭埽堈埸堋埳埏堇埮埣埲埥埬埡堎埼堐埧堁堌埱埩埰堍堄奜婠婘婕婧婞娸娵婭婐婟婥婬婓婤婗婃婝婒婄婛婈媎娾婍娹婌婰婩婇婑婖婂婜孲孮寁寀屙崞崋崝崚崠崌崨崍崦崥崏\"],[\"d540\",\"崰崒崣崟崮帾帴庱庴庹庲庳弶弸徛徖徟悊悐悆悾悰悺惓惔惏惤惙惝惈悱惛悷惊悿惃惍惀挲捥掊掂捽掽掞掭掝掗掫掎捯掇掐据掯捵掜捭掮捼掤挻掟\"],[\"d5a1\",\"捸掅掁掑掍捰敓旍晥晡晛晙晜晢朘桹梇梐梜桭桮梮梫楖桯梣梬梩桵桴梲梏桷梒桼桫桲梪梀桱桾梛梖梋梠梉梤桸桻梑梌梊桽欶欳欷欸殑殏殍殎殌氪淀涫涴涳湴涬淩淢涷淶淔渀淈淠淟淖涾淥淜淝淛淴淊涽淭淰涺淕淂淏淉\"],[\"d640\",\"淐淲淓淽淗淍淣涻烺焍烷焗烴焌烰焄烳焐烼烿焆焓焀烸烶焋焂焎牾牻牼牿猝猗猇猑猘猊猈狿猏猞玈珶珸珵琄琁珽琇琀珺珼珿琌琋珴琈畤畣痎痒痏\"],[\"d6a1\",\"痋痌痑痐皏皉盓眹眯眭眱眲眴眳眽眥眻眵硈硒硉硍硊硌砦硅硐祤祧祩祪祣祫祡离秺秸秶秷窏窔窐笵筇笴笥笰笢笤笳笘笪笝笱笫笭笯笲笸笚笣粔粘粖粣紵紽紸紶紺絅紬紩絁絇紾紿絊紻紨罣羕羜羝羛翊翋翍翐翑翇翏翉耟\"],[\"d740\",\"耞耛聇聃聈脘脥脙脛脭脟脬脞脡脕脧脝脢舑舸舳舺舴舲艴莐莣莨莍荺荳莤荴莏莁莕莙荵莔莩荽莃莌莝莛莪莋荾莥莯莈莗莰荿莦莇莮荶莚虙虖蚿蚷\"],[\"d7a1\",\"蛂蛁蛅蚺蚰蛈蚹蚳蚸蛌蚴蚻蚼蛃蚽蚾衒袉袕袨袢袪袚袑袡袟袘袧袙袛袗袤袬袌袓袎覂觖觙觕訰訧訬訞谹谻豜豝豽貥赽赻赹趼跂趹趿跁軘軞軝軜軗軠軡逤逋逑逜逌逡郯郪郰郴郲郳郔郫郬郩酖酘酚酓酕釬釴釱釳釸釤釹釪\"],[\"d840\",\"釫釷釨釮镺閆閈陼陭陫陱陯隿靪頄飥馗傛傕傔傞傋傣傃傌傎傝偨傜傒傂傇兟凔匒匑厤厧喑喨喥喭啷噅喢喓喈喏喵喁喣喒喤啽喌喦啿喕喡喎圌堩堷\"],[\"d8a1\",\"堙堞堧堣堨埵塈堥堜堛堳堿堶堮堹堸堭堬堻奡媯媔媟婺媢媞婸媦婼媥媬媕媮娷媄媊媗媃媋媩婻婽媌媜媏媓媝寪寍寋寔寑寊寎尌尰崷嵃嵫嵁嵋崿崵嵑嵎嵕崳崺嵒崽崱嵙嵂崹嵉崸崼崲崶嵀嵅幄幁彘徦徥徫惉悹惌惢惎惄愔\"],[\"d940\",\"惲愊愖愅惵愓惸惼惾惁愃愘愝愐惿愄愋扊掔掱掰揎揥揨揯揃撝揳揊揠揶揕揲揵摡揟掾揝揜揄揘揓揂揇揌揋揈揰揗揙攲敧敪敤敜敨敥斌斝斞斮旐旒\"],[\"d9a1\",\"晼晬晻暀晱晹晪晲朁椌棓椄棜椪棬棪棱椏棖棷棫棤棶椓椐棳棡椇棌椈楰梴椑棯棆椔棸棐棽棼棨椋椊椗棎棈棝棞棦棴棑椆棔棩椕椥棇欹欻欿欼殔殗殙殕殽毰毲毳氰淼湆湇渟湉溈渼渽湅湢渫渿湁湝湳渜渳湋湀湑渻渃渮湞\"],[\"da40\",\"湨湜湡渱渨湠湱湫渹渢渰湓湥渧湸湤湷湕湹湒湦渵渶湚焠焞焯烻焮焱焣焥焢焲焟焨焺焛牋牚犈犉犆犅犋猒猋猰猢猱猳猧猲猭猦猣猵猌琮琬琰琫琖\"],[\"daa1\",\"琚琡琭琱琤琣琝琩琠琲瓻甯畯畬痧痚痡痦痝痟痤痗皕皒盚睆睇睄睍睅睊睎睋睌矞矬硠硤硥硜硭硱硪确硰硩硨硞硢祴祳祲祰稂稊稃稌稄窙竦竤筊笻筄筈筌筎筀筘筅粢粞粨粡絘絯絣絓絖絧絪絏絭絜絫絒絔絩絑絟絎缾缿罥\"],[\"db40\",\"罦羢羠羡翗聑聏聐胾胔腃腊腒腏腇脽腍脺臦臮臷臸臹舄舼舽舿艵茻菏菹萣菀菨萒菧菤菼菶萐菆菈菫菣莿萁菝菥菘菿菡菋菎菖菵菉萉萏菞萑萆菂菳\"],[\"dba1\",\"菕菺菇菑菪萓菃菬菮菄菻菗菢萛菛菾蛘蛢蛦蛓蛣蛚蛪蛝蛫蛜蛬蛩蛗蛨蛑衈衖衕袺裗袹袸裀袾袶袼袷袽袲褁裉覕覘覗觝觚觛詎詍訹詙詀詗詘詄詅詒詈詑詊詌詏豟貁貀貺貾貰貹貵趄趀趉跘跓跍跇跖跜跏跕跙跈跗跅軯軷軺\"],[\"dc40\",\"軹軦軮軥軵軧軨軶軫軱軬軴軩逭逴逯鄆鄬鄄郿郼鄈郹郻鄁鄀鄇鄅鄃酡酤酟酢酠鈁鈊鈥鈃鈚鈦鈏鈌鈀鈒釿釽鈆鈄鈧鈂鈜鈤鈙鈗鈅鈖镻閍閌閐隇陾隈\"],[\"dca1\",\"隉隃隀雂雈雃雱雰靬靰靮頇颩飫鳦黹亃亄亶傽傿僆傮僄僊傴僈僂傰僁傺傱僋僉傶傸凗剺剸剻剼嗃嗛嗌嗐嗋嗊嗝嗀嗔嗄嗩喿嗒喍嗏嗕嗢嗖嗈嗲嗍嗙嗂圔塓塨塤塏塍塉塯塕塎塝塙塥塛堽塣塱壼嫇嫄嫋媺媸媱媵媰媿嫈媻嫆\"],[\"dd40\",\"媷嫀嫊媴媶嫍媹媐寖寘寙尟尳嵱嵣嵊嵥嵲嵬嵞嵨嵧嵢巰幏幎幊幍幋廅廌廆廋廇彀徯徭惷慉慊愫慅愶愲愮慆愯慏愩慀戠酨戣戥戤揅揱揫搐搒搉搠搤\"],[\"dda1\",\"搳摃搟搕搘搹搷搢搣搌搦搰搨摁搵搯搊搚摀搥搧搋揧搛搮搡搎敯斒旓暆暌暕暐暋暊暙暔晸朠楦楟椸楎楢楱椿楅楪椹楂楗楙楺楈楉椵楬椳椽楥棰楸椴楩楀楯楄楶楘楁楴楌椻楋椷楜楏楑椲楒椯楻椼歆歅歃歂歈歁殛嗀毻毼\"],[\"de40\",\"毹毷毸溛滖滈溏滀溟溓溔溠溱溹滆滒溽滁溞滉溷溰滍溦滏溲溾滃滜滘溙溒溎溍溤溡溿溳滐滊溗溮溣煇煔煒煣煠煁煝煢煲煸煪煡煂煘煃煋煰煟煐煓\"],[\"dea1\",\"煄煍煚牏犍犌犑犐犎猼獂猻猺獀獊獉瑄瑊瑋瑒瑑瑗瑀瑏瑐瑎瑂瑆瑍瑔瓡瓿瓾瓽甝畹畷榃痯瘏瘃痷痾痼痹痸瘐痻痶痭痵痽皙皵盝睕睟睠睒睖睚睩睧睔睙睭矠碇碚碔碏碄碕碅碆碡碃硹碙碀碖硻祼禂祽祹稑稘稙稒稗稕稢稓\"],[\"df40\",\"稛稐窣窢窞竫筦筤筭筴筩筲筥筳筱筰筡筸筶筣粲粴粯綈綆綀綍絿綅絺綎絻綃絼綌綔綄絽綒罭罫罧罨罬羦羥羧翛翜耡腤腠腷腜腩腛腢腲朡腞腶腧腯\"],[\"dfa1\",\"腄腡舝艉艄艀艂艅蓱萿葖葶葹蒏蒍葥葑葀蒆葧萰葍葽葚葙葴葳葝蔇葞萷萺萴葺葃葸萲葅萩菙葋萯葂萭葟葰萹葎葌葒葯蓅蒎萻葇萶萳葨葾葄萫葠葔葮葐蜋蜄蛷蜌蛺蛖蛵蝍蛸蜎蜉蜁蛶蜍蜅裖裋裍裎裞裛裚裌裐覅覛觟觥觤\"],[\"e040\",\"觡觠觢觜触詶誆詿詡訿詷誂誄詵誃誁詴詺谼豋豊豥豤豦貆貄貅賌赨赩趑趌趎趏趍趓趔趐趒跰跠跬跱跮跐跩跣跢跧跲跫跴輆軿輁輀輅輇輈輂輋遒逿\"],[\"e0a1\",\"遄遉逽鄐鄍鄏鄑鄖鄔鄋鄎酮酯鉈鉒鈰鈺鉦鈳鉥鉞銃鈮鉊鉆鉭鉬鉏鉠鉧鉯鈶鉡鉰鈱鉔鉣鉐鉲鉎鉓鉌鉖鈲閟閜閞閛隒隓隑隗雎雺雽雸雵靳靷靸靲頏頍頎颬飶飹馯馲馰馵骭骫魛鳪鳭鳧麀黽僦僔僗僨僳僛僪僝僤僓僬僰僯僣僠\"],[\"e140\",\"凘劀劁勩勫匰厬嘧嘕嘌嘒嗼嘏嘜嘁嘓嘂嗺嘝嘄嗿嗹墉塼墐墘墆墁塿塴墋塺墇墑墎塶墂墈塻墔墏壾奫嫜嫮嫥嫕嫪嫚嫭嫫嫳嫢嫠嫛嫬嫞嫝嫙嫨嫟孷寠\"],[\"e1a1\",\"寣屣嶂嶀嵽嶆嵺嶁嵷嶊嶉嶈嵾嵼嶍嵹嵿幘幙幓廘廑廗廎廜廕廙廒廔彄彃彯徶愬愨慁慞慱慳慒慓慲慬憀慴慔慺慛慥愻慪慡慖戩戧戫搫摍摛摝摴摶摲摳摽摵摦撦摎撂摞摜摋摓摠摐摿搿摬摫摙摥摷敳斠暡暠暟朅朄朢榱榶槉\"],[\"e240\",\"榠槎榖榰榬榼榑榙榎榧榍榩榾榯榿槄榽榤槔榹槊榚槏榳榓榪榡榞槙榗榐槂榵榥槆歊歍歋殞殟殠毃毄毾滎滵滱漃漥滸漷滻漮漉潎漙漚漧漘漻漒滭漊\"],[\"e2a1\",\"漶潳滹滮漭潀漰漼漵滫漇漎潃漅滽滶漹漜滼漺漟漍漞漈漡熇熐熉熀熅熂熏煻熆熁熗牄牓犗犕犓獃獍獑獌瑢瑳瑱瑵瑲瑧瑮甀甂甃畽疐瘖瘈瘌瘕瘑瘊瘔皸瞁睼瞅瞂睮瞀睯睾瞃碲碪碴碭碨硾碫碞碥碠碬碢碤禘禊禋禖禕禔禓\"],[\"e340\",\"禗禈禒禐稫穊稰稯稨稦窨窫窬竮箈箜箊箑箐箖箍箌箛箎箅箘劄箙箤箂粻粿粼粺綧綷緂綣綪緁緀緅綝緎緄緆緋緌綯綹綖綼綟綦綮綩綡緉罳翢翣翥翞\"],[\"e3a1\",\"耤聝聜膉膆膃膇膍膌膋舕蒗蒤蒡蒟蒺蓎蓂蒬蒮蒫蒹蒴蓁蓍蒪蒚蒱蓐蒝蒧蒻蒢蒔蓇蓌蒛蒩蒯蒨蓖蒘蒶蓏蒠蓗蓔蓒蓛蒰蒑虡蜳蜣蜨蝫蝀蜮蜞蜡蜙蜛蝃蜬蝁蜾蝆蜠蜲蜪蜭蜼蜒蜺蜱蜵蝂蜦蜧蜸蜤蜚蜰蜑裷裧裱裲裺裾裮裼裶裻\"],[\"e440\",\"裰裬裫覝覡覟覞觩觫觨誫誙誋誒誏誖谽豨豩賕賏賗趖踉踂跿踍跽踊踃踇踆踅跾踀踄輐輑輎輍鄣鄜鄠鄢鄟鄝鄚鄤鄡鄛酺酲酹酳銥銤鉶銛鉺銠銔銪銍\"],[\"e4a1\",\"銦銚銫鉹銗鉿銣鋮銎銂銕銢鉽銈銡銊銆銌銙銧鉾銇銩銝銋鈭隞隡雿靘靽靺靾鞃鞀鞂靻鞄鞁靿韎韍頖颭颮餂餀餇馝馜駃馹馻馺駂馽駇骱髣髧鬾鬿魠魡魟鳱鳲鳵麧僿儃儰僸儆儇僶僾儋儌僽儊劋劌勱勯噈噂噌嘵噁噊噉噆噘\"],[\"e540\",\"噚噀嘳嘽嘬嘾嘸嘪嘺圚墫墝墱墠墣墯墬墥墡壿嫿嫴嫽嫷嫶嬃嫸嬂嫹嬁嬇嬅嬏屧嶙嶗嶟嶒嶢嶓嶕嶠嶜嶡嶚嶞幩幝幠幜緳廛廞廡彉徲憋憃慹憱憰憢憉\"],[\"e5a1\",\"憛憓憯憭憟憒憪憡憍慦憳戭摮摰撖撠撅撗撜撏撋撊撌撣撟摨撱撘敶敺敹敻斲斳暵暰暩暲暷暪暯樀樆樗槥槸樕槱槤樠槿槬槢樛樝槾樧槲槮樔槷槧橀樈槦槻樍槼槫樉樄樘樥樏槶樦樇槴樖歑殥殣殢殦氁氀毿氂潁漦潾澇濆澒\"],[\"e640\",\"澍澉澌潢潏澅潚澖潶潬澂潕潲潒潐潗澔澓潝漀潡潫潽潧澐潓澋潩潿澕潣潷潪潻熲熯熛熰熠熚熩熵熝熥熞熤熡熪熜熧熳犘犚獘獒獞獟獠獝獛獡獚獙\"],[\"e6a1\",\"獢璇璉璊璆璁瑽璅璈瑼瑹甈甇畾瘥瘞瘙瘝瘜瘣瘚瘨瘛皜皝皞皛瞍瞏瞉瞈磍碻磏磌磑磎磔磈磃磄磉禚禡禠禜禢禛歶稹窲窴窳箷篋箾箬篎箯箹篊箵糅糈糌糋緷緛緪緧緗緡縃緺緦緶緱緰緮緟罶羬羰羭翭翫翪翬翦翨聤聧膣膟\"],[\"e740\",\"膞膕膢膙膗舖艏艓艒艐艎艑蔤蔻蔏蔀蔩蔎蔉蔍蔟蔊蔧蔜蓻蔫蓺蔈蔌蓴蔪蓲蔕蓷蓫蓳蓼蔒蓪蓩蔖蓾蔨蔝蔮蔂蓽蔞蓶蔱蔦蓧蓨蓰蓯蓹蔘蔠蔰蔋蔙蔯虢\"],[\"e7a1\",\"蝖蝣蝤蝷蟡蝳蝘蝔蝛蝒蝡蝚蝑蝞蝭蝪蝐蝎蝟蝝蝯蝬蝺蝮蝜蝥蝏蝻蝵蝢蝧蝩衚褅褌褔褋褗褘褙褆褖褑褎褉覢覤覣觭觰觬諏諆誸諓諑諔諕誻諗誾諀諅諘諃誺誽諙谾豍貏賥賟賙賨賚賝賧趠趜趡趛踠踣踥踤踮踕踛踖踑踙踦踧\"],[\"e840\",\"踔踒踘踓踜踗踚輬輤輘輚輠輣輖輗遳遰遯遧遫鄯鄫鄩鄪鄲鄦鄮醅醆醊醁醂醄醀鋐鋃鋄鋀鋙銶鋏鋱鋟鋘鋩鋗鋝鋌鋯鋂鋨鋊鋈鋎鋦鋍鋕鋉鋠鋞鋧鋑鋓\"],[\"e8a1\",\"銵鋡鋆銴镼閬閫閮閰隤隢雓霅霈霂靚鞊鞎鞈韐韏頞頝頦頩頨頠頛頧颲餈飺餑餔餖餗餕駜駍駏駓駔駎駉駖駘駋駗駌骳髬髫髳髲髱魆魃魧魴魱魦魶魵魰魨魤魬鳼鳺鳽鳿鳷鴇鴀鳹鳻鴈鴅鴄麃黓鼏鼐儜儓儗儚儑凞匴叡噰噠噮\"],[\"e940\",\"噳噦噣噭噲噞噷圜圛壈墽壉墿墺壂墼壆嬗嬙嬛嬡嬔嬓嬐嬖嬨嬚嬠嬞寯嶬嶱嶩嶧嶵嶰嶮嶪嶨嶲嶭嶯嶴幧幨幦幯廩廧廦廨廥彋徼憝憨憖懅憴懆懁懌憺\"],[\"e9a1\",\"憿憸憌擗擖擐擏擉撽撉擃擛擳擙攳敿敼斢曈暾曀曊曋曏暽暻暺曌朣樴橦橉橧樲橨樾橝橭橶橛橑樨橚樻樿橁橪橤橐橏橔橯橩橠樼橞橖橕橍橎橆歕歔歖殧殪殫毈毇氄氃氆澭濋澣濇澼濎濈潞濄澽澞濊澨瀄澥澮澺澬澪濏澿澸\"],[\"ea40\",\"澢濉澫濍澯澲澰燅燂熿熸燖燀燁燋燔燊燇燏熽燘熼燆燚燛犝犞獩獦獧獬獥獫獪瑿璚璠璔璒璕璡甋疀瘯瘭瘱瘽瘳瘼瘵瘲瘰皻盦瞚瞝瞡瞜瞛瞢瞣瞕瞙\"],[\"eaa1\",\"瞗磝磩磥磪磞磣磛磡磢磭磟磠禤穄穈穇窶窸窵窱窷篞篣篧篝篕篥篚篨篹篔篪篢篜篫篘篟糒糔糗糐糑縒縡縗縌縟縠縓縎縜縕縚縢縋縏縖縍縔縥縤罃罻罼罺羱翯耪耩聬膱膦膮膹膵膫膰膬膴膲膷膧臲艕艖艗蕖蕅蕫蕍蕓蕡蕘\"],[\"eb40\",\"蕀蕆蕤蕁蕢蕄蕑蕇蕣蔾蕛蕱蕎蕮蕵蕕蕧蕠薌蕦蕝蕔蕥蕬虣虥虤螛螏螗螓螒螈螁螖螘蝹螇螣螅螐螑螝螄螔螜螚螉褞褦褰褭褮褧褱褢褩褣褯褬褟觱諠\"],[\"eba1\",\"諢諲諴諵諝謔諤諟諰諈諞諡諨諿諯諻貑貒貐賵賮賱賰賳赬赮趥趧踳踾踸蹀蹅踶踼踽蹁踰踿躽輶輮輵輲輹輷輴遶遹遻邆郺鄳鄵鄶醓醐醑醍醏錧錞錈錟錆錏鍺錸錼錛錣錒錁鍆錭錎錍鋋錝鋺錥錓鋹鋷錴錂錤鋿錩錹錵錪錔錌\"],[\"ec40\",\"錋鋾錉錀鋻錖閼闍閾閹閺閶閿閵閽隩雔霋霒霐鞙鞗鞔韰韸頵頯頲餤餟餧餩馞駮駬駥駤駰駣駪駩駧骹骿骴骻髶髺髹髷鬳鮀鮅鮇魼魾魻鮂鮓鮒鮐魺鮕\"],[\"eca1\",\"魽鮈鴥鴗鴠鴞鴔鴩鴝鴘鴢鴐鴙鴟麈麆麇麮麭黕黖黺鼒鼽儦儥儢儤儠儩勴嚓嚌嚍嚆嚄嚃噾嚂噿嚁壖壔壏壒嬭嬥嬲嬣嬬嬧嬦嬯嬮孻寱寲嶷幬幪徾徻懃憵憼懧懠懥懤懨懞擯擩擣擫擤擨斁斀斶旚曒檍檖檁檥檉檟檛檡檞檇檓檎\"],[\"ed40\",\"檕檃檨檤檑橿檦檚檅檌檒歛殭氉濌澩濴濔濣濜濭濧濦濞濲濝濢濨燡燱燨燲燤燰燢獳獮獯璗璲璫璐璪璭璱璥璯甐甑甒甏疄癃癈癉癇皤盩瞵瞫瞲瞷瞶\"],[\"eda1\",\"瞴瞱瞨矰磳磽礂磻磼磲礅磹磾礄禫禨穜穛穖穘穔穚窾竀竁簅簏篲簀篿篻簎篴簋篳簂簉簃簁篸篽簆篰篱簐簊糨縭縼繂縳顈縸縪繉繀繇縩繌縰縻縶繄縺罅罿罾罽翴翲耬膻臄臌臊臅臇膼臩艛艚艜薃薀薏薧薕薠薋薣蕻薤薚薞\"],[\"ee40\",\"蕷蕼薉薡蕺蕸蕗薎薖薆薍薙薝薁薢薂薈薅蕹蕶薘薐薟虨螾螪螭蟅螰螬螹螵螼螮蟉蟃蟂蟌螷螯蟄蟊螴螶螿螸螽蟞螲褵褳褼褾襁襒褷襂覭覯覮觲觳謞\"],[\"eea1\",\"謘謖謑謅謋謢謏謒謕謇謍謈謆謜謓謚豏豰豲豱豯貕貔賹赯蹎蹍蹓蹐蹌蹇轃轀邅遾鄸醚醢醛醙醟醡醝醠鎡鎃鎯鍤鍖鍇鍼鍘鍜鍶鍉鍐鍑鍠鍭鎏鍌鍪鍹鍗鍕鍒鍏鍱鍷鍻鍡鍞鍣鍧鎀鍎鍙闇闀闉闃闅閷隮隰隬霠霟霘霝霙鞚鞡鞜\"],[\"ef40\",\"鞞鞝韕韔韱顁顄顊顉顅顃餥餫餬餪餳餲餯餭餱餰馘馣馡騂駺駴駷駹駸駶駻駽駾駼騃骾髾髽鬁髼魈鮚鮨鮞鮛鮦鮡鮥鮤鮆鮢鮠鮯鴳鵁鵧鴶鴮鴯鴱鴸鴰\"],[\"efa1\",\"鵅鵂鵃鴾鴷鵀鴽翵鴭麊麉麍麰黈黚黻黿鼤鼣鼢齔龠儱儭儮嚘嚜嚗嚚嚝嚙奰嬼屩屪巀幭幮懘懟懭懮懱懪懰懫懖懩擿攄擽擸攁攃擼斔旛曚曛曘櫅檹檽櫡櫆檺檶檷櫇檴檭歞毉氋瀇瀌瀍瀁瀅瀔瀎濿瀀濻瀦濼濷瀊爁燿燹爃燽獶\"],[\"f040\",\"璸瓀璵瓁璾璶璻瓂甔甓癜癤癙癐癓癗癚皦皽盬矂瞺磿礌礓礔礉礐礒礑禭禬穟簜簩簙簠簟簭簝簦簨簢簥簰繜繐繖繣繘繢繟繑繠繗繓羵羳翷翸聵臑臒\"],[\"f0a1\",\"臐艟艞薴藆藀藃藂薳薵薽藇藄薿藋藎藈藅薱薶藒蘤薸薷薾虩蟧蟦蟢蟛蟫蟪蟥蟟蟳蟤蟔蟜蟓蟭蟘蟣螤蟗蟙蠁蟴蟨蟝襓襋襏襌襆襐襑襉謪謧謣謳謰謵譇謯謼謾謱謥謷謦謶謮謤謻謽謺豂豵貙貘貗賾贄贂贀蹜蹢蹠蹗蹖蹞蹥蹧\"],[\"f140\",\"蹛蹚蹡蹝蹩蹔轆轇轈轋鄨鄺鄻鄾醨醥醧醯醪鎵鎌鎒鎷鎛鎝鎉鎧鎎鎪鎞鎦鎕鎈鎙鎟鎍鎱鎑鎲鎤鎨鎴鎣鎥闒闓闑隳雗雚巂雟雘雝霣霢霥鞬鞮鞨鞫鞤鞪\"],[\"f1a1\",\"鞢鞥韗韙韖韘韺顐顑顒颸饁餼餺騏騋騉騍騄騑騊騅騇騆髀髜鬈鬄鬅鬩鬵魊魌魋鯇鯆鯃鮿鯁鮵鮸鯓鮶鯄鮹鮽鵜鵓鵏鵊鵛鵋鵙鵖鵌鵗鵒鵔鵟鵘鵚麎麌黟鼁鼀鼖鼥鼫鼪鼩鼨齌齕儴儵劖勷厴嚫嚭嚦嚧嚪嚬壚壝壛夒嬽嬾嬿巃幰\"],[\"f240\",\"徿懻攇攐攍攉攌攎斄旞旝曞櫧櫠櫌櫑櫙櫋櫟櫜櫐櫫櫏櫍櫞歠殰氌瀙瀧瀠瀖瀫瀡瀢瀣瀩瀗瀤瀜瀪爌爊爇爂爅犥犦犤犣犡瓋瓅璷瓃甖癠矉矊矄矱礝礛\"],[\"f2a1\",\"礡礜礗礞禰穧穨簳簼簹簬簻糬糪繶繵繸繰繷繯繺繲繴繨罋罊羃羆羷翽翾聸臗臕艤艡艣藫藱藭藙藡藨藚藗藬藲藸藘藟藣藜藑藰藦藯藞藢蠀蟺蠃蟶蟷蠉蠌蠋蠆蟼蠈蟿蠊蠂襢襚襛襗襡襜襘襝襙覈覷覶觶譐譈譊譀譓譖譔譋譕\"],[\"f340\",\"譑譂譒譗豃豷豶貚贆贇贉趬趪趭趫蹭蹸蹳蹪蹯蹻軂轒轑轏轐轓辴酀鄿醰醭鏞鏇鏏鏂鏚鏐鏹鏬鏌鏙鎩鏦鏊鏔鏮鏣鏕鏄鏎鏀鏒鏧镽闚闛雡霩霫霬霨霦\"],[\"f3a1\",\"鞳鞷鞶韝韞韟顜顙顝顗颿颽颻颾饈饇饃馦馧騚騕騥騝騤騛騢騠騧騣騞騜騔髂鬋鬊鬎鬌鬷鯪鯫鯠鯞鯤鯦鯢鯰鯔鯗鯬鯜鯙鯥鯕鯡鯚鵷鶁鶊鶄鶈鵱鶀鵸鶆鶋鶌鵽鵫鵴鵵鵰鵩鶅鵳鵻鶂鵯鵹鵿鶇鵨麔麑黀黼鼭齀齁齍齖齗齘匷嚲\"],[\"f440\",\"嚵嚳壣孅巆巇廮廯忀忁懹攗攖攕攓旟曨曣曤櫳櫰櫪櫨櫹櫱櫮櫯瀼瀵瀯瀷瀴瀱灂瀸瀿瀺瀹灀瀻瀳灁爓爔犨獽獼璺皫皪皾盭矌矎矏矍矲礥礣礧礨礤礩\"],[\"f4a1\",\"禲穮穬穭竷籉籈籊籇籅糮繻繾纁纀羺翿聹臛臙舋艨艩蘢藿蘁藾蘛蘀藶蘄蘉蘅蘌藽蠙蠐蠑蠗蠓蠖襣襦覹觷譠譪譝譨譣譥譧譭趮躆躈躄轙轖轗轕轘轚邍酃酁醷醵醲醳鐋鐓鏻鐠鐏鐔鏾鐕鐐鐨鐙鐍鏵鐀鏷鐇鐎鐖鐒鏺鐉鏸鐊鏿\"],[\"f540\",\"鏼鐌鏶鐑鐆闞闠闟霮霯鞹鞻韽韾顠顢顣顟飁飂饐饎饙饌饋饓騲騴騱騬騪騶騩騮騸騭髇髊髆鬐鬒鬑鰋鰈鯷鰅鰒鯸鱀鰇鰎鰆鰗鰔鰉鶟鶙鶤鶝鶒鶘鶐鶛\"],[\"f5a1\",\"鶠鶔鶜鶪鶗鶡鶚鶢鶨鶞鶣鶿鶩鶖鶦鶧麙麛麚黥黤黧黦鼰鼮齛齠齞齝齙龑儺儹劘劗囃嚽嚾孈孇巋巏廱懽攛欂櫼欃櫸欀灃灄灊灈灉灅灆爝爚爙獾甗癪矐礭礱礯籔籓糲纊纇纈纋纆纍罍羻耰臝蘘蘪蘦蘟蘣蘜蘙蘧蘮蘡蘠蘩蘞蘥\"],[\"f640\",\"蠩蠝蠛蠠蠤蠜蠫衊襭襩襮襫觺譹譸譅譺譻贐贔趯躎躌轞轛轝酆酄酅醹鐿鐻鐶鐩鐽鐼鐰鐹鐪鐷鐬鑀鐱闥闤闣霵霺鞿韡顤飉飆飀饘饖騹騽驆驄驂驁騺\"],[\"f6a1\",\"騿髍鬕鬗鬘鬖鬺魒鰫鰝鰜鰬鰣鰨鰩鰤鰡鶷鶶鶼鷁鷇鷊鷏鶾鷅鷃鶻鶵鷎鶹鶺鶬鷈鶱鶭鷌鶳鷍鶲鹺麜黫黮黭鼛鼘鼚鼱齎齥齤龒亹囆囅囋奱孋孌巕巑廲攡攠攦攢欋欈欉氍灕灖灗灒爞爟犩獿瓘瓕瓙瓗癭皭礵禴穰穱籗籜籙籛籚\"],[\"f740\",\"糴糱纑罏羇臞艫蘴蘵蘳蘬蘲蘶蠬蠨蠦蠪蠥襱覿覾觻譾讄讂讆讅譿贕躕躔躚躒躐躖躗轠轢酇鑌鑐鑊鑋鑏鑇鑅鑈鑉鑆霿韣顪顩飋饔饛驎驓驔驌驏驈驊\"],[\"f7a1\",\"驉驒驐髐鬙鬫鬻魖魕鱆鱈鰿鱄鰹鰳鱁鰼鰷鰴鰲鰽鰶鷛鷒鷞鷚鷋鷐鷜鷑鷟鷩鷙鷘鷖鷵鷕鷝麶黰鼵鼳鼲齂齫龕龢儽劙壨壧奲孍巘蠯彏戁戃戄攩攥斖曫欑欒欏毊灛灚爢玂玁玃癰矔籧籦纕艬蘺虀蘹蘼蘱蘻蘾蠰蠲蠮蠳襶襴襳觾\"],[\"f840\",\"讌讎讋讈豅贙躘轤轣醼鑢鑕鑝鑗鑞韄韅頀驖驙鬞鬟鬠鱒鱘鱐鱊鱍鱋鱕鱙鱌鱎鷻鷷鷯鷣鷫鷸鷤鷶鷡鷮鷦鷲鷰鷢鷬鷴鷳鷨鷭黂黐黲黳鼆鼜鼸鼷鼶齃齏\"],[\"f8a1\",\"齱齰齮齯囓囍孎屭攭曭曮欓灟灡灝灠爣瓛瓥矕礸禷禶籪纗羉艭虃蠸蠷蠵衋讔讕躞躟躠躝醾醽釂鑫鑨鑩雥靆靃靇韇韥驞髕魙鱣鱧鱦鱢鱞鱠鸂鷾鸇鸃鸆鸅鸀鸁鸉鷿鷽鸄麠鼞齆齴齵齶囔攮斸欘欙欗欚灢爦犪矘矙礹籩籫糶纚\"],[\"f940\",\"纘纛纙臠臡虆虇虈襹襺襼襻觿讘讙躥躤躣鑮鑭鑯鑱鑳靉顲饟鱨鱮鱭鸋鸍鸐鸏鸒鸑麡黵鼉齇齸齻齺齹圞灦籯蠼趲躦釃鑴鑸鑶鑵驠鱴鱳鱱鱵鸔鸓黶鼊\"],[\"f9a1\",\"龤灨灥糷虪蠾蠽蠿讞貜躩軉靋顳顴飌饡馫驤驦驧鬤鸕鸗齈戇欞爧虌躨钂钀钁驩驨鬮鸙爩虋讟钃鱹麷癵驫鱺鸝灩灪麤齾齉龘碁銹裏墻恒粧嫺╔╦╗╠╬╣╚╩╝╒╤╕╞╪╡╘╧╛╓╥╖╟╫╢╙╨╜║═╭╮╰╯▓\"]]");

/***/ }),
/* 247 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function isCountable(thing) {
    return (typeof thing === 'object');
}
exports.isCountable = isCountable;


/***/ }),
/* 248 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const iterator_to_hash_1 = __webpack_require__(146);
const is_map_1 = __webpack_require__(147);
const is_pure_array_1 = __webpack_require__(438);
const iterator_to_array_1 = __webpack_require__(134);
const phpJsonEncode = __webpack_require__(439);
function jsonEncode(value) {
    if (is_map_1.isMap(value)) {
        if (is_pure_array_1.isPureArray(value)) {
            value = iterator_to_array_1.iteratorToArray(value);
        }
        else {
            value = iterator_to_hash_1.iteratorToHash(value);
        }
    }
    return phpJsonEncode(value);
}
exports.jsonEncode = jsonEncode;


/***/ }),
/* 249 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const iterator_to_array_1 = __webpack_require__(134);
function max(...things) {
    if (things.length === 1) {
        things = things[0];
    }
    let array = iterator_to_array_1.iteratorToArray(things);
    array.sort((a, b) => {
        return a < b ? 1 : -1;
    });
    return array[0];
}
exports.max = max;


/***/ }),
/* 250 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const iterator_to_array_1 = __webpack_require__(134);
function min(...things) {
    if (things.length === 1) {
        things = things[0];
    }
    let array = iterator_to_array_1.iteratorToArray(things);
    array.sort();
    return array[0];
}
exports.min = min;


/***/ }),
/* 251 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const parser = __webpack_require__(440);
/**
 *
 * @param {string} input
 * @returns {RegExp}
 */
function regexParser(input) {
    return parser(input);
}
exports.regexParser = regexParser;


/***/ }),
/* 252 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const luxon_1 = __webpack_require__(176);
// modifyDate
function relativeDate(date) {
    let result = null;
    let regExp = /^([-|\+])([0-9]+?)(\s*)([a-z]*)/g;
    let matches = regExp.exec(date);
    if (matches) {
        result = luxon_1.DateTime.local();
        let sign = matches[1];
        let count = parseInt(matches[2]);
        let unit = matches[4];
        switch (unit) {
            case 'year':
                unit = 'years';
                break;
            case 'month':
                unit = 'months';
                break;
            case 'day':
                unit = 'days';
                break;
            case 'hour':
                unit = 'hours';
                break;
            case 'minute':
                unit = 'minutes';
                break;
            case 'second':
                unit = 'seconds';
                break;
        }
        let duration = {};
        duration[unit] = (sign === '-' ? -count : count);
        result = result.plus(duration);
    }
    else {
        result = luxon_1.DateTime.invalid(`Failed to parse relative date "${date}".`);
    }
    return result;
}
exports.relativeDate = relativeDate;


/***/ }),
/* 253 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const util_1 = __webpack_require__(133);
const ksort_1 = __webpack_require__(181);
const substr_count = __webpack_require__(441);
const addcslashes = __webpack_require__(442);
const sha256 = __webpack_require__(149);
const hex = __webpack_require__(150);
class TwingCompiler {
    constructor(env) {
        this.varNameSalt = 0;
        this.env = env;
    }
    /**
     * Returns the environment instance related to this compiler.
     *
     * @returns TwingEnvironment
     */
    getEnvironment() {
        return this.env;
    }
    getSource() {
        return this.source;
    }
    compile(node, indentation = 0) {
        this.lastLine = null;
        this.source = '';
        this.debugInfo = new Map();
        this.sourceOffset = 0;
        // source code starts at 1 (as we then increment it when we encounter new lines)
        this.sourceLine = 1;
        this.indentation = indentation;
        this.varNameSalt = 0;
        this.subcompile(node);
        return this;
    }
    subcompile(node, raw = true) {
        if (raw === false) {
            this.source += ' '.repeat(this.indentation * 4);
        }
        node.compile(this);
        return this;
    }
    /**
     *
     * @param string
     * @returns
     */
    raw(string) {
        this.source += string;
        return this;
    }
    /**
     * Writes a string to the compiled code by adding indentation.
     *
     * @returns {TwingCompiler}
     */
    write(...strings) {
        for (let string of strings) {
            this.source += ' '.repeat(this.indentation * 4) + string;
        }
        return this;
    }
    /**
     * Adds a quoted string to the compiled code.
     *
     * @param {string} value The string
     *
     * @returns {TwingCompiler}
     */
    string(value) {
        if (!util_1.isNullOrUndefined(value)) {
            if (typeof value === 'string') {
                value = '`' + addcslashes(value, "\0\t\\`").replace(/\${/g, '\\${') + '`';
            }
        }
        else {
            value = '``';
        }
        this.source += value;
        return this;
    }
    repr(value) {
        if (typeof value === 'number') {
            // if (false !== $locale = setlocale(LC_NUMERIC, '0')) {
            //     setlocale(LC_NUMERIC, 'C');
            // }
            this.raw(value);
            // if (false !== $locale) {
            //     setlocale(LC_NUMERIC, $locale);
            // }
        }
        else if (value === null) {
            this.raw('null');
        }
        else if (typeof value === 'boolean') {
            this.raw(value ? 'true' : 'false');
        }
        else if (Array.isArray(value)) {
            this.raw('[');
            let first = true;
            for (let v of value) {
                if (!first) {
                    this.raw(', ');
                }
                first = false;
                this.repr(v);
            }
            this.raw(']');
        }
        else if (value instanceof Map) {
            this.raw('new Map([');
            let first = true;
            for (let [k, v] of value) {
                if (!first) {
                    this.raw(', ');
                }
                first = false;
                this
                    .raw('[')
                    .repr(k)
                    .raw(', ')
                    .repr(v)
                    .raw(']');
            }
            this.raw('])');
        }
        else if (typeof value === 'object') {
            this.raw('{');
            let first = true;
            for (let k in value) {
                if (!first) {
                    this.raw(', ');
                }
                first = false;
                this
                    .raw(`"${k}"`)
                    .raw(': ')
                    .repr(value[k]);
            }
            this.raw('}');
        }
        else if (value === undefined) {
            this.raw('');
        }
        else {
            this.string(value);
        }
        return this;
    }
    /**
     * Adds debugging information.
     *
     * @returns TwingCompiler
     */
    addDebugInfo(node) {
        if (node.getTemplateLine() != this.lastLine) {
            this.write(`// line ${node.getTemplateLine()}, column ${node.getTemplateColumn()}\n`);
            this.sourceLine += substr_count(this.source, "\n", this.sourceOffset);
            this.sourceOffset = this.source.length;
            this.debugInfo.set(this.sourceLine, {
                line: node.getTemplateLine(),
                column: node.getTemplateColumn()
            });
            this.lastLine = node.getTemplateLine();
        }
        return this;
    }
    getDebugInfo() {
        ksort_1.ksort(this.debugInfo);
        return this.debugInfo;
    }
    /**
     * Adds source-map enter call.
     *
     * @returns TwingCompiler
     */
    addSourceMapEnter(node, ctor = null) {
        if (this.getEnvironment().isSourceMap()) {
            this
                .write('this.env.enterSourceMapBlock(')
                .raw(node.getTemplateLine())
                .raw(', ')
                .raw(node.getTemplateColumn())
                .raw(', ')
                .string(node.getType())
                .raw(', ')
                .raw('this.getSourceContext(), ');
            if (ctor) {
                this.raw(ctor);
            }
            else {
                this.raw(`this.extensions.get('TwingExtensionCore').getSourceMapNodeConstructor('${node.getType()}')`);
            }
            this.raw(');\n');
        }
        return this;
    }
    /**
     * Adds source-map leave call.
     *
     * @returns TwingCompiler
     */
    addSourceMapLeave() {
        if (this.getEnvironment().isSourceMap()) {
            this
                .write('this.env.leaveSourceMapBlock();\n');
        }
        return this;
    }
    /**
     * Indents the generated code.
     *
     * @param {number} step The number of indentation to add
     *
     * @returns TwingCompiler
     */
    indent(step = 1) {
        this.indentation += step;
        return this;
    }
    /**
     * Outdents the generated code.
     *
     * @param {number} step The number of indentation to remove
     *
     * @return TwingCompiler
     *
     * @throws Error When trying to outdent too much so the indentation would become negative
     */
    outdent(step = 1) {
        // can't outdent by more steps than the current indentation level
        if (this.indentation < step) {
            throw new Error('Unable to call outdent() as the indentation would become negative.');
        }
        this.indentation -= step;
        return this;
    }
    getVarName(prefix = '__internal_') {
        return `${prefix}${hex.stringify(sha256('TwingCompiler::getVarName' + this.varNameSalt++))}`;
    }
}
exports.TwingCompiler = TwingCompiler;


/***/ }),
/* 254 */
/***/ (function(module, exports, __webpack_require__) {

;(function (root, factory) {
	if (true) {
		// CommonJS
		module.exports = exports = factory();
	}
	else {}
}(this, function () {

	/**
	 * CryptoJS core components.
	 */
	var CryptoJS = CryptoJS || (function (Math, undefined) {
	    /*
	     * Local polyfil of Object.create
	     */
	    var create = Object.create || (function () {
	        function F() {};

	        return function (obj) {
	            var subtype;

	            F.prototype = obj;

	            subtype = new F();

	            F.prototype = null;

	            return subtype;
	        };
	    }())

	    /**
	     * CryptoJS namespace.
	     */
	    var C = {};

	    /**
	     * Library namespace.
	     */
	    var C_lib = C.lib = {};

	    /**
	     * Base object for prototypal inheritance.
	     */
	    var Base = C_lib.Base = (function () {


	        return {
	            /**
	             * Creates a new object that inherits from this object.
	             *
	             * @param {Object} overrides Properties to copy into the new object.
	             *
	             * @return {Object} The new object.
	             *
	             * @static
	             *
	             * @example
	             *
	             *     var MyType = CryptoJS.lib.Base.extend({
	             *         field: 'value',
	             *
	             *         method: function () {
	             *         }
	             *     });
	             */
	            extend: function (overrides) {
	                // Spawn
	                var subtype = create(this);

	                // Augment
	                if (overrides) {
	                    subtype.mixIn(overrides);
	                }

	                // Create default initializer
	                if (!subtype.hasOwnProperty('init') || this.init === subtype.init) {
	                    subtype.init = function () {
	                        subtype.$super.init.apply(this, arguments);
	                    };
	                }

	                // Initializer's prototype is the subtype object
	                subtype.init.prototype = subtype;

	                // Reference supertype
	                subtype.$super = this;

	                return subtype;
	            },

	            /**
	             * Extends this object and runs the init method.
	             * Arguments to create() will be passed to init().
	             *
	             * @return {Object} The new object.
	             *
	             * @static
	             *
	             * @example
	             *
	             *     var instance = MyType.create();
	             */
	            create: function () {
	                var instance = this.extend();
	                instance.init.apply(instance, arguments);

	                return instance;
	            },

	            /**
	             * Initializes a newly created object.
	             * Override this method to add some logic when your objects are created.
	             *
	             * @example
	             *
	             *     var MyType = CryptoJS.lib.Base.extend({
	             *         init: function () {
	             *             // ...
	             *         }
	             *     });
	             */
	            init: function () {
	            },

	            /**
	             * Copies properties into this object.
	             *
	             * @param {Object} properties The properties to mix in.
	             *
	             * @example
	             *
	             *     MyType.mixIn({
	             *         field: 'value'
	             *     });
	             */
	            mixIn: function (properties) {
	                for (var propertyName in properties) {
	                    if (properties.hasOwnProperty(propertyName)) {
	                        this[propertyName] = properties[propertyName];
	                    }
	                }

	                // IE won't copy toString using the loop above
	                if (properties.hasOwnProperty('toString')) {
	                    this.toString = properties.toString;
	                }
	            },

	            /**
	             * Creates a copy of this object.
	             *
	             * @return {Object} The clone.
	             *
	             * @example
	             *
	             *     var clone = instance.clone();
	             */
	            clone: function () {
	                return this.init.prototype.extend(this);
	            }
	        };
	    }());

	    /**
	     * An array of 32-bit words.
	     *
	     * @property {Array} words The array of 32-bit words.
	     * @property {number} sigBytes The number of significant bytes in this word array.
	     */
	    var WordArray = C_lib.WordArray = Base.extend({
	        /**
	         * Initializes a newly created word array.
	         *
	         * @param {Array} words (Optional) An array of 32-bit words.
	         * @param {number} sigBytes (Optional) The number of significant bytes in the words.
	         *
	         * @example
	         *
	         *     var wordArray = CryptoJS.lib.WordArray.create();
	         *     var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607]);
	         *     var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6);
	         */
	        init: function (words, sigBytes) {
	            words = this.words = words || [];

	            if (sigBytes != undefined) {
	                this.sigBytes = sigBytes;
	            } else {
	                this.sigBytes = words.length * 4;
	            }
	        },

	        /**
	         * Converts this word array to a string.
	         *
	         * @param {Encoder} encoder (Optional) The encoding strategy to use. Default: CryptoJS.enc.Hex
	         *
	         * @return {string} The stringified word array.
	         *
	         * @example
	         *
	         *     var string = wordArray + '';
	         *     var string = wordArray.toString();
	         *     var string = wordArray.toString(CryptoJS.enc.Utf8);
	         */
	        toString: function (encoder) {
	            return (encoder || Hex).stringify(this);
	        },

	        /**
	         * Concatenates a word array to this word array.
	         *
	         * @param {WordArray} wordArray The word array to append.
	         *
	         * @return {WordArray} This word array.
	         *
	         * @example
	         *
	         *     wordArray1.concat(wordArray2);
	         */
	        concat: function (wordArray) {
	            // Shortcuts
	            var thisWords = this.words;
	            var thatWords = wordArray.words;
	            var thisSigBytes = this.sigBytes;
	            var thatSigBytes = wordArray.sigBytes;

	            // Clamp excess bits
	            this.clamp();

	            // Concat
	            if (thisSigBytes % 4) {
	                // Copy one byte at a time
	                for (var i = 0; i < thatSigBytes; i++) {
	                    var thatByte = (thatWords[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;
	                    thisWords[(thisSigBytes + i) >>> 2] |= thatByte << (24 - ((thisSigBytes + i) % 4) * 8);
	                }
	            } else {
	                // Copy one word at a time
	                for (var i = 0; i < thatSigBytes; i += 4) {
	                    thisWords[(thisSigBytes + i) >>> 2] = thatWords[i >>> 2];
	                }
	            }
	            this.sigBytes += thatSigBytes;

	            // Chainable
	            return this;
	        },

	        /**
	         * Removes insignificant bits.
	         *
	         * @example
	         *
	         *     wordArray.clamp();
	         */
	        clamp: function () {
	            // Shortcuts
	            var words = this.words;
	            var sigBytes = this.sigBytes;

	            // Clamp
	            words[sigBytes >>> 2] &= 0xffffffff << (32 - (sigBytes % 4) * 8);
	            words.length = Math.ceil(sigBytes / 4);
	        },

	        /**
	         * Creates a copy of this word array.
	         *
	         * @return {WordArray} The clone.
	         *
	         * @example
	         *
	         *     var clone = wordArray.clone();
	         */
	        clone: function () {
	            var clone = Base.clone.call(this);
	            clone.words = this.words.slice(0);

	            return clone;
	        },

	        /**
	         * Creates a word array filled with random bytes.
	         *
	         * @param {number} nBytes The number of random bytes to generate.
	         *
	         * @return {WordArray} The random word array.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var wordArray = CryptoJS.lib.WordArray.random(16);
	         */
	        random: function (nBytes) {
	            var words = [];

	            var r = (function (m_w) {
	                var m_w = m_w;
	                var m_z = 0x3ade68b1;
	                var mask = 0xffffffff;

	                return function () {
	                    m_z = (0x9069 * (m_z & 0xFFFF) + (m_z >> 0x10)) & mask;
	                    m_w = (0x4650 * (m_w & 0xFFFF) + (m_w >> 0x10)) & mask;
	                    var result = ((m_z << 0x10) + m_w) & mask;
	                    result /= 0x100000000;
	                    result += 0.5;
	                    return result * (Math.random() > .5 ? 1 : -1);
	                }
	            });

	            for (var i = 0, rcache; i < nBytes; i += 4) {
	                var _r = r((rcache || Math.random()) * 0x100000000);

	                rcache = _r() * 0x3ade67b7;
	                words.push((_r() * 0x100000000) | 0);
	            }

	            return new WordArray.init(words, nBytes);
	        }
	    });

	    /**
	     * Encoder namespace.
	     */
	    var C_enc = C.enc = {};

	    /**
	     * Hex encoding strategy.
	     */
	    var Hex = C_enc.Hex = {
	        /**
	         * Converts a word array to a hex string.
	         *
	         * @param {WordArray} wordArray The word array.
	         *
	         * @return {string} The hex string.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var hexString = CryptoJS.enc.Hex.stringify(wordArray);
	         */
	        stringify: function (wordArray) {
	            // Shortcuts
	            var words = wordArray.words;
	            var sigBytes = wordArray.sigBytes;

	            // Convert
	            var hexChars = [];
	            for (var i = 0; i < sigBytes; i++) {
	                var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;
	                hexChars.push((bite >>> 4).toString(16));
	                hexChars.push((bite & 0x0f).toString(16));
	            }

	            return hexChars.join('');
	        },

	        /**
	         * Converts a hex string to a word array.
	         *
	         * @param {string} hexStr The hex string.
	         *
	         * @return {WordArray} The word array.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var wordArray = CryptoJS.enc.Hex.parse(hexString);
	         */
	        parse: function (hexStr) {
	            // Shortcut
	            var hexStrLength = hexStr.length;

	            // Convert
	            var words = [];
	            for (var i = 0; i < hexStrLength; i += 2) {
	                words[i >>> 3] |= parseInt(hexStr.substr(i, 2), 16) << (24 - (i % 8) * 4);
	            }

	            return new WordArray.init(words, hexStrLength / 2);
	        }
	    };

	    /**
	     * Latin1 encoding strategy.
	     */
	    var Latin1 = C_enc.Latin1 = {
	        /**
	         * Converts a word array to a Latin1 string.
	         *
	         * @param {WordArray} wordArray The word array.
	         *
	         * @return {string} The Latin1 string.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);
	         */
	        stringify: function (wordArray) {
	            // Shortcuts
	            var words = wordArray.words;
	            var sigBytes = wordArray.sigBytes;

	            // Convert
	            var latin1Chars = [];
	            for (var i = 0; i < sigBytes; i++) {
	                var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;
	                latin1Chars.push(String.fromCharCode(bite));
	            }

	            return latin1Chars.join('');
	        },

	        /**
	         * Converts a Latin1 string to a word array.
	         *
	         * @param {string} latin1Str The Latin1 string.
	         *
	         * @return {WordArray} The word array.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var wordArray = CryptoJS.enc.Latin1.parse(latin1String);
	         */
	        parse: function (latin1Str) {
	            // Shortcut
	            var latin1StrLength = latin1Str.length;

	            // Convert
	            var words = [];
	            for (var i = 0; i < latin1StrLength; i++) {
	                words[i >>> 2] |= (latin1Str.charCodeAt(i) & 0xff) << (24 - (i % 4) * 8);
	            }

	            return new WordArray.init(words, latin1StrLength);
	        }
	    };

	    /**
	     * UTF-8 encoding strategy.
	     */
	    var Utf8 = C_enc.Utf8 = {
	        /**
	         * Converts a word array to a UTF-8 string.
	         *
	         * @param {WordArray} wordArray The word array.
	         *
	         * @return {string} The UTF-8 string.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var utf8String = CryptoJS.enc.Utf8.stringify(wordArray);
	         */
	        stringify: function (wordArray) {
	            try {
	                return decodeURIComponent(escape(Latin1.stringify(wordArray)));
	            } catch (e) {
	                throw new Error('Malformed UTF-8 data');
	            }
	        },

	        /**
	         * Converts a UTF-8 string to a word array.
	         *
	         * @param {string} utf8Str The UTF-8 string.
	         *
	         * @return {WordArray} The word array.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var wordArray = CryptoJS.enc.Utf8.parse(utf8String);
	         */
	        parse: function (utf8Str) {
	            return Latin1.parse(unescape(encodeURIComponent(utf8Str)));
	        }
	    };

	    /**
	     * Abstract buffered block algorithm template.
	     *
	     * The property blockSize must be implemented in a concrete subtype.
	     *
	     * @property {number} _minBufferSize The number of blocks that should be kept unprocessed in the buffer. Default: 0
	     */
	    var BufferedBlockAlgorithm = C_lib.BufferedBlockAlgorithm = Base.extend({
	        /**
	         * Resets this block algorithm's data buffer to its initial state.
	         *
	         * @example
	         *
	         *     bufferedBlockAlgorithm.reset();
	         */
	        reset: function () {
	            // Initial values
	            this._data = new WordArray.init();
	            this._nDataBytes = 0;
	        },

	        /**
	         * Adds new data to this block algorithm's buffer.
	         *
	         * @param {WordArray|string} data The data to append. Strings are converted to a WordArray using UTF-8.
	         *
	         * @example
	         *
	         *     bufferedBlockAlgorithm._append('data');
	         *     bufferedBlockAlgorithm._append(wordArray);
	         */
	        _append: function (data) {
	            // Convert string to WordArray, else assume WordArray already
	            if (typeof data == 'string') {
	                data = Utf8.parse(data);
	            }

	            // Append
	            this._data.concat(data);
	            this._nDataBytes += data.sigBytes;
	        },

	        /**
	         * Processes available data blocks.
	         *
	         * This method invokes _doProcessBlock(offset), which must be implemented by a concrete subtype.
	         *
	         * @param {boolean} doFlush Whether all blocks and partial blocks should be processed.
	         *
	         * @return {WordArray} The processed data.
	         *
	         * @example
	         *
	         *     var processedData = bufferedBlockAlgorithm._process();
	         *     var processedData = bufferedBlockAlgorithm._process(!!'flush');
	         */
	        _process: function (doFlush) {
	            // Shortcuts
	            var data = this._data;
	            var dataWords = data.words;
	            var dataSigBytes = data.sigBytes;
	            var blockSize = this.blockSize;
	            var blockSizeBytes = blockSize * 4;

	            // Count blocks ready
	            var nBlocksReady = dataSigBytes / blockSizeBytes;
	            if (doFlush) {
	                // Round up to include partial blocks
	                nBlocksReady = Math.ceil(nBlocksReady);
	            } else {
	                // Round down to include only full blocks,
	                // less the number of blocks that must remain in the buffer
	                nBlocksReady = Math.max((nBlocksReady | 0) - this._minBufferSize, 0);
	            }

	            // Count words ready
	            var nWordsReady = nBlocksReady * blockSize;

	            // Count bytes ready
	            var nBytesReady = Math.min(nWordsReady * 4, dataSigBytes);

	            // Process blocks
	            if (nWordsReady) {
	                for (var offset = 0; offset < nWordsReady; offset += blockSize) {
	                    // Perform concrete-algorithm logic
	                    this._doProcessBlock(dataWords, offset);
	                }

	                // Remove processed words
	                var processedWords = dataWords.splice(0, nWordsReady);
	                data.sigBytes -= nBytesReady;
	            }

	            // Return processed words
	            return new WordArray.init(processedWords, nBytesReady);
	        },

	        /**
	         * Creates a copy of this object.
	         *
	         * @return {Object} The clone.
	         *
	         * @example
	         *
	         *     var clone = bufferedBlockAlgorithm.clone();
	         */
	        clone: function () {
	            var clone = Base.clone.call(this);
	            clone._data = this._data.clone();

	            return clone;
	        },

	        _minBufferSize: 0
	    });

	    /**
	     * Abstract hasher template.
	     *
	     * @property {number} blockSize The number of 32-bit words this hasher operates on. Default: 16 (512 bits)
	     */
	    var Hasher = C_lib.Hasher = BufferedBlockAlgorithm.extend({
	        /**
	         * Configuration options.
	         */
	        cfg: Base.extend(),

	        /**
	         * Initializes a newly created hasher.
	         *
	         * @param {Object} cfg (Optional) The configuration options to use for this hash computation.
	         *
	         * @example
	         *
	         *     var hasher = CryptoJS.algo.SHA256.create();
	         */
	        init: function (cfg) {
	            // Apply config defaults
	            this.cfg = this.cfg.extend(cfg);

	            // Set initial values
	            this.reset();
	        },

	        /**
	         * Resets this hasher to its initial state.
	         *
	         * @example
	         *
	         *     hasher.reset();
	         */
	        reset: function () {
	            // Reset data buffer
	            BufferedBlockAlgorithm.reset.call(this);

	            // Perform concrete-hasher logic
	            this._doReset();
	        },

	        /**
	         * Updates this hasher with a message.
	         *
	         * @param {WordArray|string} messageUpdate The message to append.
	         *
	         * @return {Hasher} This hasher.
	         *
	         * @example
	         *
	         *     hasher.update('message');
	         *     hasher.update(wordArray);
	         */
	        update: function (messageUpdate) {
	            // Append
	            this._append(messageUpdate);

	            // Update the hash
	            this._process();

	            // Chainable
	            return this;
	        },

	        /**
	         * Finalizes the hash computation.
	         * Note that the finalize operation is effectively a destructive, read-once operation.
	         *
	         * @param {WordArray|string} messageUpdate (Optional) A final message update.
	         *
	         * @return {WordArray} The hash.
	         *
	         * @example
	         *
	         *     var hash = hasher.finalize();
	         *     var hash = hasher.finalize('message');
	         *     var hash = hasher.finalize(wordArray);
	         */
	        finalize: function (messageUpdate) {
	            // Final message update
	            if (messageUpdate) {
	                this._append(messageUpdate);
	            }

	            // Perform concrete-hasher logic
	            var hash = this._doFinalize();

	            return hash;
	        },

	        blockSize: 512/32,

	        /**
	         * Creates a shortcut function to a hasher's object interface.
	         *
	         * @param {Hasher} hasher The hasher to create a helper for.
	         *
	         * @return {Function} The shortcut function.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256);
	         */
	        _createHelper: function (hasher) {
	            return function (message, cfg) {
	                return new hasher.init(cfg).finalize(message);
	            };
	        },

	        /**
	         * Creates a shortcut function to the HMAC's object interface.
	         *
	         * @param {Hasher} hasher The hasher to use in this HMAC helper.
	         *
	         * @return {Function} The shortcut function.
	         *
	         * @static
	         *
	         * @example
	         *
	         *     var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256);
	         */
	        _createHmacHelper: function (hasher) {
	            return function (message, key) {
	                return new C_algo.HMAC.init(hasher, key).finalize(message);
	            };
	        }
	    });

	    /**
	     * Algorithm namespace.
	     */
	    var C_algo = C.algo = {};

	    return C;
	}(Math));


	return CryptoJS;

}));

/***/ }),
/* 255 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const staging_1 = __webpack_require__(256);
const merge_1 = __webpack_require__(135);
const isObject = __webpack_require__(151);
class TwingExtensionSet {
    constructor() {
        this.initialized = false;
        this.runtimeInitialized = false;
        this.functionCallbacks = [];
        this.filterCallbacks = [];
        this.staging = new staging_1.TwingExtensionStaging();
        this.extensions = new Map();
        this.parsers = [];
    }
    /**
     * Initializes the runtime environment.
     */
    initRuntime(env) {
        if (this.runtimeInitialized) {
            return;
        }
        this.runtimeInitialized = true;
        for (let [name, extension] of this.extensions) {
            let candidate = extension;
            if (candidate.TwingExtensionInitRuntimeInterfaceImpl) {
                candidate.TwingExtensionInitRuntimeInterfaceImpl.initRuntime(env);
            }
        }
    }
    hasExtension(name) {
        return this.extensions.has(name);
    }
    getExtension(name) {
        return this.extensions.get(name);
    }
    /**
     * Registers an array of extensions.
     *
     * @param {Array<TwingExtensionInterface>} extensions An array of extensions
     */
    setExtensions(extensions) {
        for (let extension of extensions) {
            this.addExtension(extension);
        }
    }
    /**
     * Returns all registered extensions.
     *
     * @return Map<string, TwingExtensionInterface> A hash of extensions
     */
    getExtensions() {
        return this.extensions;
    }
    getSignature() {
        return JSON.stringify([...this.extensions.keys()]);
    }
    isInitialized() {
        return this.initialized || this.runtimeInitialized;
    }
    getNodeVisitors() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.visitors;
    }
    getTokenParsers() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.parsers;
    }
    getGlobals() {
        if (this.globals !== undefined) {
            return this.globals;
        }
        let globals = new Map();
        for (let [name, extension] of this.getExtensions()) {
            let candidate = extension;
            if (!candidate.TwingExtensionGlobalsInterfaceImpl) {
                continue;
            }
            let extGlobals = candidate.TwingExtensionGlobalsInterfaceImpl.getGlobals();
            if (!(extGlobals instanceof Map)) {
                throw new Error(`"${extension.constructor.name}[TwingExtensionGlobalsInterface].getGlobals()" must return a Map of globals.`);
            }
            globals = merge_1.merge(globals, extGlobals);
        }
        if (this.initialized) {
            this.globals = globals;
        }
        return globals;
    }
    /**
     * Registers an extension.
     *
     * @param {TwingExtensionInterface} extension A TwingExtensionInterface instance
     * @param {String} name An optional name the extension will be registered as
     */
    addExtension(extension, name = null) {
        if (!name) {
            name = extension.constructor.name;
        }
        if (this.initialized) {
            throw new Error(`Unable to register extension "${name}" as extensions have already been initialized.`);
        }
        if (this.extensions.has(name)) {
            throw new Error(`Unable to register extension "${name}" as it is already registered.`);
        }
        this.extensions.set(name, extension);
    }
    addTokenParser(parser) {
        if (this.initialized) {
            throw new Error('Unable to add a token parser as extensions have already been initialized.');
        }
        this.staging.addTokenParser(parser);
    }
    /**
     * Gets the registered unary Operators.
     *
     * @return Map<string, TwingOperator> A map of unary operator definitions
     */
    getUnaryOperators() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.unaryOperators;
    }
    /**
     * Gets the registered binary Operators.
     *
     * @return Map<string, TwingOperator> A map of binary operators
     */
    getBinaryOperators() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.binaryOperators;
    }
    addFunction(twingFunction) {
        if (this.initialized) {
            throw new Error(`Unable to add function "${twingFunction.getName()}" as extensions have already been initialized.`);
        }
        this.staging.addFunction(twingFunction);
    }
    getFunctions() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.functions;
    }
    /**
     * Get a function by name.
     *
     * @param {string} name         function name
     * @returns {TwingFunction}     A TwingFunction instance or null if the function does not exist
     */
    getFunction(name) {
        if (!this.initialized) {
            this.initExtensions();
        }
        if (this.functions.has(name)) {
            return this.functions.get(name);
        }
        for (let [pattern, twingFunction] of this.functions) {
            let count = 0;
            pattern = pattern.replace(/\*/g, function (match, value) {
                count++;
                return '(.*?)';
            });
            if (count) {
                let regExp = new RegExp('^' + pattern + '$', 'g');
                let match = regExp.exec(name);
                let matches = [];
                if (match) {
                    for (let i = 1; i <= count; i++) {
                        matches.push(match[i]);
                    }
                    twingFunction.setArguments(matches);
                    return twingFunction;
                }
            }
        }
        for (let callback of this.functionCallbacks) {
            let function_ = callback(name);
            if (function_ !== false) {
                return function_;
            }
        }
        return null;
    }
    registerUndefinedFunctionCallback(callable) {
        this.functionCallbacks.push(callable);
    }
    addFilter(filter) {
        if (this.initialized) {
            throw new Error(`Unable to add filter "${filter.getName()}" as extensions have already been initialized.`);
        }
        this.staging.addFilter(filter);
    }
    getFilters() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.filters;
    }
    /**
     * Get a filter by name.
     *
     * Subclasses may override this method and load filters differently;
     * so no list of filters is available.
     *
     * @param string name The filter name
     *
     * @return Twig_Filter|false A Twig_Filter instance or false if the filter does not exist
     */
    getFilter(name) {
        if (!this.initialized) {
            this.initExtensions();
        }
        if (this.filters.has(name)) {
            return this.filters.get(name);
        }
        let filter;
        let pattern;
        for ([pattern, filter] of this.filters) {
            let count = 0;
            pattern = pattern.replace(/\*/g, function (match, value) {
                count++;
                return '(.*?)';
            });
            if (count) {
                let regExp = new RegExp('^' + pattern + '$', 'g');
                let match = regExp.exec(name);
                let matches = [];
                if (match) {
                    for (let i = 1; i <= count; i++) {
                        matches.push(match[i]);
                    }
                    filter.setArguments(matches);
                    return filter;
                }
            }
        }
        for (let callback of this.filterCallbacks) {
            let filter = callback.call(name);
            if (filter !== false) {
                return filter;
            }
        }
        return null;
    }
    registerUndefinedFilterCallback(callable) {
        this.filterCallbacks.push(callable);
    }
    addNodeVisitor(visitor) {
        if (this.initialized) {
            throw new Error('Unable to add a node visitor as extensions have already been initialized.');
        }
        this.staging.addNodeVisitor(visitor);
    }
    addTest(test) {
        if (this.initialized) {
            throw new Error(`Unable to add test "${test.getName()}" as extensions have already been initialized.`);
        }
        this.staging.addTest(test);
    }
    /**
     *
     * @returns {Map<string, TwingTest>}
     */
    getTests() {
        if (!this.initialized) {
            this.initExtensions();
        }
        return this.tests;
    }
    /**
     * Gets a test by name.
     *
     * @param {string} name The test name
     * @returns {TwingTest} A TwingTest instance or null if the test does not exist
     */
    getTest(name) {
        if (!this.initialized) {
            this.initExtensions();
        }
        if (this.tests.has(name)) {
            return this.tests.get(name);
        }
        let test;
        let pattern;
        for ([pattern, test] of this.tests) {
            let count = 0;
            pattern = pattern.replace(/\*/g, function (match, value) {
                count++;
                return '(.*?)';
            });
            if (count) {
                let regExp = new RegExp('^' + pattern + '$', 'g');
                let match = regExp.exec(name);
                let matches = [];
                if (match) {
                    for (let i = 1; i <= count; i++) {
                        matches.push(match[i]);
                    }
                    test.setArguments(matches);
                    return test;
                }
            }
        }
        return null;
    }
    initExtensions() {
        this.parsers = [];
        this.filters = new Map();
        this.functions = new Map();
        this.tests = new Map();
        this.visitors = [];
        this.unaryOperators = new Map();
        this.binaryOperators = new Map();
        for (let [key, extension] of this.extensions) {
            this.initExtension(extension);
        }
        this.initExtension(this.staging);
        // Done at the end only, so that an exception during initialization does not mark the environment as initialized when catching the exception
        this.initialized = true;
    }
    initExtension(extension) {
        // filters
        // BC, @see https://github.com/ericmorand/twing/issues/218
        if (Array.isArray(extension.getFilters())) {
            for (let [key, filter] of extension.getFilters().entries()) {
                this.filters.set(filter.getName(), filter);
            }
        }
        else {
            for (let [key, filter] of extension.getFilters()) {
                this.filters.set(filter.getName(), filter);
            }
        }
        // functions
        // BC, @see https://github.com/ericmorand/twing/issues/218
        if (Array.isArray(extension.getFunctions())) {
            for (let [key, function_] of extension.getFunctions().entries()) {
                this.functions.set(function_.getName(), function_);
            }
        }
        else {
            for (let [key, function_] of extension.getFunctions()) {
                this.functions.set(function_.getName(), function_);
            }
        }
        // tests
        for (let test of extension.getTests()) {
            this.tests.set(test.getName(), test);
        }
        // token parsers
        for (let parser of extension.getTokenParsers()) {
            // if (!parser instanceof Twig_TokenParserInterface) {
            //     throw new Error('getTokenParsers() must return an array of Twig_TokenParserInterface.');
            // }
            this.parsers.push(parser);
        }
        // node visitors
        for (let visitor of extension.getNodeVisitors()) {
            this.visitors.push(visitor);
        }
        // operators
        let operators = extension.getOperators();
        if (operators) {
            if (!Array.isArray(operators)) {
                throw new Error(`"${extension.constructor.name}.getOperators()" must return an array with operators, got "${isObject(operators) ? operators.constructor.name : typeof operators}".`);
            }
            if (operators.length !== 2) {
                throw new Error(`"${extension.constructor.name}.getOperators()" must return an array of 2 elements, got ${operators.length}.`);
            }
            this.unaryOperators = new Map([...this.unaryOperators, ...operators[0]]);
            this.binaryOperators = new Map([...this.binaryOperators, ...operators[1]]);
        }
    }
}
exports.TwingExtensionSet = TwingExtensionSet;


/***/ }),
/* 256 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
class TwingExtensionStaging extends extension_1.TwingExtension {
    constructor() {
        super(...arguments);
        this.functions = new Map();
        this.filters = new Map();
        this.visitors = [];
        this.tokenParsers = new Map();
        this.tests = [];
    }
    addFunction(twingFunction) {
        if (this.functions.has(twingFunction.getName())) {
            throw new Error(`Function "${twingFunction.getName()}" is already registered.`);
        }
        this.functions.set(twingFunction.getName(), twingFunction);
    }
    getFunctions() {
        return this.functions;
    }
    addFilter(filter) {
        if (this.filters.has(filter.getName())) {
            throw new Error(`Filter "${filter.getName()}" is already registered.`);
        }
        this.filters.set(filter.getName(), filter);
    }
    getFilters() {
        return this.filters;
    }
    addNodeVisitor(visitor) {
        this.visitors.push(visitor);
    }
    getNodeVisitors() {
        return this.visitors;
    }
    addTokenParser(parser) {
        if (this.tokenParsers.has(parser.getTag())) {
            throw new Error(`Tag "${parser.getTag()}" is already registered.`);
        }
        this.tokenParsers.set(parser.getTag(), parser);
    }
    getTokenParsers() {
        return Array.from(this.tokenParsers.values());
    }
    addTest(test) {
        this.tests.push(test);
    }
    getTests() {
        return this.tests;
    }
}
exports.TwingExtensionStaging = TwingExtensionStaging;


/***/ }),
/* 257 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {
Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const for_1 = __webpack_require__(258);
const expression_parser_1 = __webpack_require__(184);
const and_1 = __webpack_require__(190);
const extends_1 = __webpack_require__(268);
const from_1 = __webpack_require__(269);
const macro_1 = __webpack_require__(270);
const node_1 = __webpack_require__(107);
const in_1 = __webpack_require__(272);
const if_1 = __webpack_require__(273);
const set_1 = __webpack_require__(274);
const block_1 = __webpack_require__(275);
const greater_1 = __webpack_require__(277);
const less_1 = __webpack_require__(278);
const include_1 = __webpack_require__(194);
const with_1 = __webpack_require__(279);
const not_1 = __webpack_require__(155);
const neg_1 = __webpack_require__(281);
const pos_1 = __webpack_require__(282);
const function_1 = __webpack_require__(158);
const spaceless_1 = __webpack_require__(287);
const concat_1 = __webpack_require__(187);
const mul_1 = __webpack_require__(289);
const div_1 = __webpack_require__(198);
const floor_div_1 = __webpack_require__(290);
const mod_1 = __webpack_require__(291);
const sub_1 = __webpack_require__(292);
const add_1 = __webpack_require__(293);
const use_1 = __webpack_require__(294);
const embed_1 = __webpack_require__(295);
const filter_1 = __webpack_require__(297);
const range_1 = __webpack_require__(298);
const import_1 = __webpack_require__(299);
const do_1 = __webpack_require__(300);
const flush_1 = __webpack_require__(301);
const equal_1 = __webpack_require__(303);
const not_equal_1 = __webpack_require__(304);
const or_1 = __webpack_require__(305);
const bitwise_or_1 = __webpack_require__(306);
const bitwise_xor_1 = __webpack_require__(307);
const bitwise_and_1 = __webpack_require__(308);
const greater_equal_1 = __webpack_require__(309);
const less_equal_1 = __webpack_require__(310);
const not_in_1 = __webpack_require__(311);
const null_coalesce_1 = __webpack_require__(312);
const power_1 = __webpack_require__(313);
const same_as_1 = __webpack_require__(314);
const defined_1 = __webpack_require__(160);
const odd_1 = __webpack_require__(315);
const constant_1 = __webpack_require__(316);
const test_1 = __webpack_require__(317);
const divisible_by_1 = __webpack_require__(318);
const matches_1 = __webpack_require__(319);
const starts_with_1 = __webpack_require__(320);
const ends_with_1 = __webpack_require__(321);
const filter_2 = __webpack_require__(201);
const luxon_1 = __webpack_require__(176);
const constant_2 = __webpack_require__(115);
const default_1 = __webpack_require__(322);
const null_1 = __webpack_require__(200);
const even_1 = __webpack_require__(323);
const min_1 = __webpack_require__(250);
const max_1 = __webpack_require__(249);
const is_traversable_1 = __webpack_require__(180);
const abs_1 = __webpack_require__(241);
const json_encode_1 = __webpack_require__(248);
const iconv_1 = __webpack_require__(178);
const runtime_1 = __webpack_require__(153);
const iterator_to_array_1 = __webpack_require__(134);
const format_date_time_1 = __webpack_require__(244);
const format_duration_1 = __webpack_require__(243);
const iterator_to_hash_1 = __webpack_require__(146);
const util_1 = __webpack_require__(133);
const iterator_to_map_1 = __webpack_require__(128);
const compare_1 = __webpack_require__(175);
const loader_1 = __webpack_require__(140);
const template_1 = __webpack_require__(123);
const range_2 = __webpack_require__(202);
const relative_date_1 = __webpack_require__(252);
const examine_object_1 = __webpack_require__(242);
const chunk_1 = __webpack_require__(324);
const fill_1 = __webpack_require__(325);
const merge_1 = __webpack_require__(135);
const slice_1 = __webpack_require__(326);
const asort_1 = __webpack_require__(327);
const reverse_1 = __webpack_require__(328);
const first_1 = __webpack_require__(203);
const markup_1 = __webpack_require__(162);
const is_map_1 = __webpack_require__(147);
const spaceless_2 = __webpack_require__(329);
const node_2 = __webpack_require__(204);
const deprecated_1 = __webpack_require__(473);
const apply_1 = __webpack_require__(474);
const sprintf = __webpack_require__(476);
const nl2br = __webpack_require__(477);
const strip_tags = __webpack_require__(478);
const mt_rand = __webpack_require__(335);
const array_rand = __webpack_require__(479);
const runes = __webpack_require__(480);
const isFloat = __webpack_require__(481);
const isBool = __webpack_require__(482);
const capitalize = __webpack_require__(286);
const strtr = __webpack_require__(483);
const round = __webpack_require__(489);
const ceil = __webpack_require__(490);
const floor = __webpack_require__(491);
const isPlainObject = __webpack_require__(336);
const bin2hex = __webpack_require__(492);
const strlen = __webpack_require__(493).getBinarySize;
const ltrim = __webpack_require__(337);
const rawurlencode = __webpack_require__(338);
const htmlspecialchars = __webpack_require__(495);
const array_merge = __webpack_require__(186);
const locutusOrd = __webpack_require__(496);
const isObject = __webpack_require__(151);
class TwingExtensionCore extends extension_1.TwingExtension {
    constructor() {
        super(...arguments);
        this.dateFormats = ['F j, Y H:i', '%d days'];
        this.numberFormat = [0, '.', ','];
        this.timezone = null;
        this.escapers = new Map();
    }
    /**
     * Defines a new escaper to be used via the escape filter.
     *
     * @param {string} strategy     The strategy name that should be used as a strategy in the escape call
     * @param {Function} callable   A valid PHP callable
     */
    setEscaper(strategy, callable) {
        this.escapers.set(strategy, callable);
    }
    /**
     * Gets all defined escapers.
     *
     * @returns {Map<string, Function>}
     */
    getEscapers() {
        return this.escapers;
    }
    /**
     * Sets the default format to be used by the date filter.
     *
     * @param {string} format The default date format string
     * @param {string} dateIntervalFormat The default date interval format string
     */
    setDateFormat(format = null, dateIntervalFormat = null) {
        if (format !== null) {
            this.dateFormats[0] = format;
        }
        if (dateIntervalFormat !== null) {
            this.dateFormats[1] = dateIntervalFormat;
        }
    }
    /**
     * Gets the default format to be used by the date filter.
     *
     * @return array The default date format string and the default date interval format string
     */
    getDateFormat() {
        return this.dateFormats;
    }
    /**
     * Sets the default timezone to be used by the date filter.
     *
     * @param {string} timezone The default timezone string or a TwingDateTimeZone object
     */
    setTimezone(timezone) {
        this.timezone = timezone;
    }
    /**
     * Gets the default timezone to be used by the date filter.
     *
     * @returns {string} The default timezone currently in use
     */
    getTimezone() {
        if (this.timezone === null) {
            this.timezone = luxon_1.Settings.defaultZoneName;
        }
        return this.timezone;
    }
    /**
     * Sets the default format to be used by the number_format filter.
     *
     * @param {number} decimal the number of decimal places to use
     * @param {string} decimalPoint the character(s) to use for the decimal point
     * @param {string} thousandSep  the character(s) to use for the thousands separator
     */
    setNumberFormat(decimal, decimalPoint, thousandSep) {
        this.numberFormat = [decimal, decimalPoint, thousandSep];
    }
    /**
     * Get the default format used by the number_format filter.
     *
     * @return array The arguments for number_format()
     */
    getNumberFormat() {
        return this.numberFormat;
    }
    getTokenParsers() {
        return [
            new for_1.TwingTokenParserFor(),
            new if_1.TwingTokenParserIf(),
            new extends_1.TwingTokenParserExtends(),
            new include_1.TwingTokenParserInclude(),
            new block_1.TwingTokenParserBlock(),
            new use_1.TwingTokenParserUse(),
            new filter_1.TwingTokenParserFilter(),
            new macro_1.TwingTokenParserMacro(),
            new import_1.TwingTokenParserImport(),
            new from_1.TwingTokenParserFrom(),
            new set_1.TwingTokenParserSet(),
            new spaceless_1.TwingTokenParserSpaceless(),
            new flush_1.TwingTokenParserFlush(),
            new do_1.TwingTokenParserDo(),
            new embed_1.TwingTokenParserEmbed(),
            new with_1.TwingTokenParserWith(),
            new deprecated_1.TwingTokenParserDeprecated(),
            new apply_1.TwingTokenParserApply()
        ];
    }
    getFilters() {
        let i = 0;
        return new Map([
            // formatting filters
            [i++, new filter_2.TwingFilter('date', twingDateFormatFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('date_modify', twingDateModifyFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('format', sprintf)],
            [i++, new filter_2.TwingFilter('replace', twingReplaceFilter)],
            [i++, new filter_2.TwingFilter('number_format', twingNumberFormatFilter, {
                    needs_environment: true
                })],
            [i++, new filter_2.TwingFilter('abs', abs_1.abs)],
            [i++, new filter_2.TwingFilter('round', twingRound)],
            // encoding
            [i++, new filter_2.TwingFilter('url_encode', twingUrlencodeFilter)],
            [i++, new filter_2.TwingFilter('json_encode', json_encode_1.jsonEncode)],
            [i++, new filter_2.TwingFilter('convert_encoding', twingConvertEncoding, {
                    pre_escape: 'html',
                    is_safe: ['html']
                })],
            // string filters
            [i++, new filter_2.TwingFilter('title', twingTitleStringFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('capitalize', twingCapitalizeStringFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('upper', twingUpperFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('lower', twingLowerFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('striptags', strip_tags)],
            [i++, new filter_2.TwingFilter('trim', twingTrimFilter)],
            [i++, new filter_2.TwingFilter('nl2br', nl2br, {
                    pre_escape: 'html',
                    is_safe: ['html']
                })],
            [i++, new filter_2.TwingFilter('spaceless', twingSpacelessFilter, {
                    is_safe: ['html']
                })],
            // array helpers
            [i++, new filter_2.TwingFilter('join', twingJoinFilter)],
            [i++, new filter_2.TwingFilter('split', twingSplitFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('sort', twingSortFilter)],
            [i++, new filter_2.TwingFilter('merge', twingArrayMerge)],
            [i++, new filter_2.TwingFilter('batch', twingArrayBatch)],
            [i++, new filter_2.TwingFilter('column', twingColumnFilter)],
            [i++, new filter_2.TwingFilter('filter', twingFilterFilter)],
            [i++, new filter_2.TwingFilter('map', twingFilterMap)],
            [i++, new filter_2.TwingFilter('reduce', twingFilterReduce)],
            // string/array filters
            [i++, new filter_2.TwingFilter('reverse', twingReverseFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('length', twingLengthFilter, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('slice', twingSlice, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('first', twingFirst, { needs_environment: true })],
            [i++, new filter_2.TwingFilter('last', twingLast, { needs_environment: true })],
            // iteration and runtime
            [i++, new filter_2.TwingFilter('default', twingDefaultFilter, {
                    expression_factory: function (node, filterName, methodArguments, lineno, columnno, tag) {
                        return new default_1.TwingNodeExpressionFilterDefault(node, filterName, methodArguments, lineno, columnno, tag);
                    }
                })],
            [i++, new filter_2.TwingFilter('keys', twingGetArrayKeysFilter)],
            // escaping
            [i++, new filter_2.TwingFilter('escape', twingEscapeFilter, {
                    needs_environment: true,
                    is_safe_callback: twingEscapeFilterIsSafe
                })],
            [i++, new filter_2.TwingFilter('e', twingEscapeFilter, {
                    needs_environment: true,
                    is_safe_callback: twingEscapeFilterIsSafe
                })]
        ]);
    }
    getFunctions() {
        let i = 0;
        return new Map([
            [i++, new function_1.TwingFunction('max', max_1.max)],
            [i++, new function_1.TwingFunction('min', min_1.min)],
            [i++, new function_1.TwingFunction('range', range_2.range)],
            [i++, new function_1.TwingFunction('constant', twingConstant, { needs_environment: true })],
            [i++, new function_1.TwingFunction('cycle', twingCycle)],
            [i++, new function_1.TwingFunction('random', twingRandom, { needs_environment: true })],
            [i++, new function_1.TwingFunction('date', twingDateConverter, { needs_environment: true })],
            [i++, new function_1.TwingFunction('include', twingInclude, {
                    needs_context: true,
                    needs_environment: true,
                    needs_source: true,
                    is_safe: ['all']
                })],
            [i++, new function_1.TwingFunction('source', twingSource, {
                    needs_environment: true,
                    needs_source: true,
                    is_safe: ['all']
                })],
        ]);
    }
    getTests() {
        return [
            new test_1.TwingTest('even', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new even_1.TwingNodeExpressionTestEven(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('odd', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new odd_1.TwingNodeExpressionTestOdd(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('defined', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new defined_1.TwingNodeExpressionTestDefined(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('same as', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new same_as_1.TwingNodeExpressionTestSameAs(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('none', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new null_1.TwingNodeExpressionTestNull(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('null', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new null_1.TwingNodeExpressionTestNull(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('divisible by', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new divisible_by_1.TwingNodeExpressionTestDivisibleBy(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('constant', null, {
                node_factory: function (node, name, nodeArguments, lineno, columnno) {
                    return new constant_1.TwingNodeExpressionTestConstant(node, name, nodeArguments, lineno, columnno);
                }
            }),
            new test_1.TwingTest('empty', twingTestEmpty),
            new test_1.TwingTest('iterable', twingTestIterable)
        ];
    }
    getOperators() {
        return [
            new Map([
                ['not', {
                        precedence: 50,
                        factory: function (expr, lineno, columnno) {
                            return new not_1.TwingNodeExpressionUnaryNot(expr, lineno, columnno);
                        }
                    }],
                ['-', {
                        precedence: 500,
                        factory: function (expr, lineno, columnno) {
                            return new neg_1.TwingNodeExpressionUnaryNeg(expr, lineno, columnno);
                        }
                    }],
                ['+', {
                        precedence: 500,
                        factory: function (expr, lineno, columnno) {
                            return new pos_1.TwingNodeExpressionUnaryPos(expr, lineno, columnno);
                        }
                    }]
            ]),
            new Map([
                ['or', {
                        precedence: 10,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new or_1.TwingNodeExpressionBinaryOr(left, right, lineno, columnno);
                        }
                    }],
                ['and', {
                        precedence: 15,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new and_1.TwingNodeExpressionBinaryAnd(left, right, lineno, columnno);
                        }
                    }],
                ['b-or', {
                        precedence: 16,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new bitwise_or_1.TwingNodeExpressionBinaryBitwiseOr(left, right, lineno, columnno);
                        }
                    }],
                ['b-xor', {
                        precedence: 17,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new bitwise_xor_1.TwingNodeExpressionBinaryBitwiseXor(left, right, lineno, columnno);
                        }
                    }],
                ['b-and', {
                        precedence: 18,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new bitwise_and_1.TwingNodeExpressionBinaryBitwiseAnd(left, right, lineno, columnno);
                        }
                    }],
                ['==', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new equal_1.TwingNodeExpressionBinaryEqual(left, right, lineno, columnno);
                        }
                    }],
                ['!=', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new not_equal_1.TwingNodeExpressionBinaryNotEqual(left, right, lineno, columnno);
                        }
                    }],
                ['<', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new less_1.TwingNodeExpressionBinaryLess(left, right, lineno, columnno);
                        }
                    }],
                ['>', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new greater_1.TwingNodeExpressionBinaryGreater(left, right, lineno, columnno);
                        }
                    }],
                ['>=', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new greater_equal_1.TwingNodeExpressionBinaryGreaterEqual(left, right, lineno, columnno);
                        }
                    }],
                ['<=', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new less_equal_1.TwingNodeExpressionBinaryLessEqual(left, right, lineno, columnno);
                        }
                    }],
                ['not in', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new not_in_1.TwingNodeExpressionBinaryNotIn(left, right, lineno, columnno);
                        }
                    }],
                ['in', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new in_1.TwingNodeExpressionBinaryIn(left, right, lineno, columnno);
                        }
                    }],
                ['matches', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new matches_1.TwingNodeExpressionBinaryMatches(left, right, lineno, columnno);
                        }
                    }],
                ['starts with', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new starts_with_1.TwingNodeExpressionBinaryStartsWith(left, right, lineno, columnno);
                        }
                    }],
                ['ends with', {
                        precedence: 20,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new ends_with_1.TwingNodeExpressionBinaryEndsWith(left, right, lineno, columnno);
                        }
                    }],
                ['..', {
                        precedence: 25,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new range_1.TwingNodeExpressionBinaryRange(left, right, lineno, columnno);
                        }
                    }],
                ['+', {
                        precedence: 30,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new add_1.TwingNodeExpressionBinaryAdd(left, right, lineno, columnno);
                        }
                    }],
                ['-', {
                        precedence: 30,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new sub_1.TwingNodeExpressionBinarySub(left, right, lineno, columnno);
                        }
                    }],
                ['~', {
                        precedence: 40,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new concat_1.TwingNodeExpressionBinaryConcat(left, right, lineno, columnno);
                        }
                    }],
                ['*', {
                        precedence: 60,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new mul_1.TwingNodeExpressionBinaryMul(left, right, lineno, columnno);
                        }
                    }],
                ['/', {
                        precedence: 60,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new div_1.TwingNodeExpressionBinaryDiv(left, right, lineno, columnno);
                        }
                    }],
                ['//', {
                        precedence: 60,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new floor_div_1.TwingNodeExpressionBinaryFloorDiv(left, right, lineno, columnno);
                        }
                    }],
                ['%', {
                        precedence: 60,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: function (left, right, lineno, columnno) {
                            return new mod_1.TwingNodeExpressionBinaryMod(left, right, lineno, columnno);
                        }
                    }],
                ['is', {
                        precedence: 100,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: null
                    }],
                ['is not', {
                        precedence: 100,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_LEFT,
                        factory: null
                    }],
                ['**', {
                        precedence: 200,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_RIGHT,
                        factory: function (left, right, lineno, columnno) {
                            return new power_1.TwingNodeExpressionBinaryPower(left, right, lineno, columnno);
                        }
                    }],
                ['??', {
                        precedence: 300,
                        associativity: expression_parser_1.TwingExpressionParser.OPERATOR_RIGHT,
                        factory: function (left, right, lineno, columnno) {
                            return new null_coalesce_1.TwingNodeExpressionNullCoalesce(left, right, lineno, columnno);
                        }
                    }]
            ])
        ];
    }
    /**
     * @param {TwingNodeType} type
     * @returns {TwingSourceMapNodeConstructor}
     */
    getSourceMapNodeConstructor(type) {
        switch (type) {
            case node_1.TwingNodeType.SPACELESS: {
                return spaceless_2.TwingSourceMapNodeSpaceless;
            }
            default: {
                return node_2.TwingSourceMapNode;
            }
        }
    }
}
exports.TwingExtensionCore = TwingExtensionCore;
/**
 * Cycles over a value.
 *
 * @param {Array} values
 * @param {number} position The cycle position
 *
 * @returns {string} The next value in the cycle
 */
function twingCycle(values, position) {
    if (!Array.isArray(values)) {
        return values;
    }
    return values[position % values.length];
}
exports.twingCycle = twingCycle;
/**
 * Returns a random value depending on the supplied parameter type:
 * - a random item from a Traversable or array
 * - a random character from a string
 * - a random integer between 0 and the integer parameter.
 *
 * @param {TwingEnvironment} env
 * @param {*} values The values to pick a random item from
 * @param {number} max Maximum value used when values is an integer
 * @throws TwingErrorRuntime when values is an empty array (does not apply to an empty string which is returned as is)
 *
 * @returns {*} A random value from the given sequence
 */
function twingRandom(env, values = null, max = null) {
    if (values === null) {
        return max === null ? mt_rand() : mt_rand(0, max);
    }
    if (typeof values === 'number') {
        let min;
        if (max === null) {
            if (values < 0) {
                max = 0;
                min = values;
            }
            else {
                max = values;
                min = 0;
            }
        }
        else {
            min = values;
        }
        return mt_rand(min, max);
    }
    if (typeof values === 'string') {
        values = Buffer.from(values);
    }
    if (Buffer.isBuffer(values)) {
        if (values.toString() === '') {
            return '';
        }
        let charset = env.getCharset();
        if (charset !== 'UTF-8') {
            values = iconv_1.iconv(charset, 'UTF-8', values);
        }
        // unicode split
        values = runes(values.toString());
        if (charset !== 'UTF-8') {
            values = values.map(function (value) {
                return iconv_1.iconv('UTF-8', charset, Buffer.from(value));
            });
        }
    }
    else if (is_traversable_1.isTraversable(values)) {
        values = iterator_to_array_1.iteratorToArray(values);
    }
    if (!Array.isArray(values)) {
        return values;
    }
    if (values.length < 1) {
        throw new runtime_1.TwingErrorRuntime('The random function cannot pick from an empty array.');
    }
    return values[array_rand(values, 1)];
}
exports.twingRandom = twingRandom;
/**
 * Converts a date to the given format.
 *
 * <pre>
 *   {{ post.published_at|date("m/d/Y") }}
 * </pre>
 *
 * @param {TwingEnvironment} env
 * @param {DateTime|Duration|string} date A date
 * @param {string|null} format The target format, null to use the default
 * @param {string|null|false} timezone The target timezone, null to use the default, false to leave unchanged
 *
 * @return string The formatted date
 */
function twingDateFormatFilter(env, date, format = null, timezone = null) {
    if (format === null) {
        let coreExtension = env.getExtension('TwingExtensionCore');
        let formats = coreExtension.getDateFormat();
        format = date instanceof luxon_1.Duration ? formats[1] : formats[0];
    }
    date = twingDateConverter(env, date, timezone);
    if (date instanceof luxon_1.Duration) {
        return format_duration_1.formatDuration(date, format);
    }
    return format_date_time_1.formatDateTime(date, format);
}
exports.twingDateFormatFilter = twingDateFormatFilter;
/**
 * Returns a new date object modified.
 *
 * <pre>
 *   {{ post.published_at|date_modify("-1day")|date("m/d/Y") }}
 * </pre>
 *
 * @param {TwingEnvironment} env
 * @param {DateTime|Duration|string} date A date
 * @param {string} modifier A modifier string
 *
 * @returns {DateTime} A new date object
 */
function twingDateModifyFilter(env, date, modifier) {
    let dateTime = twingDateConverter(env, date);
    let regExp = new RegExp(/(\+|-)([0-9])(.*)/);
    let parts = regExp.exec(modifier);
    let operator = parts[1];
    let operand = Number.parseInt(parts[2]);
    let unit = parts[3].trim();
    let duration = {};
    duration[unit] = operator === '-' ? -operand : operand;
    dateTime = dateTime.plus(duration);
    return dateTime;
}
exports.twingDateModifyFilter = twingDateModifyFilter;
/**
 * Converts an input to a DateTime instance.
 *
 * <pre>
 *    {% if date(user.created_at) < date('+2days') %}
 *      {# do something #}
 *    {% endif %}
 * </pre>
 *
 * @param {TwingEnvironment} env
 * @param {Date | DateTime | Duration | number | string} date A date or null to use the current time
 * @param {string | null | false} timezone The target timezone, null to use the default, false to leave unchanged
 *
 * @returns {DateTime} A DateTime instance
 */
function twingDateConverter(env, date, timezone = null) {
    let result;
    let coreExtension = env.getExtension('TwingExtensionCore');
    // determine the timezone
    if (timezone !== false) {
        if (timezone === null) {
            timezone = coreExtension.getTimezone();
        }
    }
    if (date instanceof luxon_1.DateTime) {
        if (timezone !== false) {
            date = date.setZone(timezone);
        }
        return date;
    }
    if (date instanceof luxon_1.Duration) {
        return date;
    }
    let parsedUtcOffset = 0;
    if (!date) {
        result = luxon_1.DateTime.local();
    }
    else if (date instanceof Date) {
        result = luxon_1.DateTime.fromJSDate(date);
    }
    else if (typeof date === 'string') {
        if (date === 'now') {
            result = luxon_1.DateTime.local();
        }
        else {
            result = luxon_1.DateTime.fromISO(date, { setZone: true });
            if (!result.isValid) {
                result = luxon_1.DateTime.fromRFC2822(date, { setZone: true });
            }
            if (!result.isValid) {
                result = luxon_1.DateTime.fromSQL(date, { setZone: true });
            }
            if (result.isValid) {
                parsedUtcOffset = result.offset;
            }
            else {
                result = relative_date_1.relativeDate(date);
            }
        }
    }
    else if (typeof date === 'number') {
        // date is PHP timestamp - i.e. in seconds
        let ts = date * 1000;
        // timestamp are UTC by definition
        result = luxon_1.DateTime.fromMillis(ts, {
            setZone: false
        });
    }
    if (!result || !result.isValid) {
        throw new runtime_1.TwingErrorRuntime(`Failed to parse date "${date}".`);
    }
    if (timezone !== false) {
        result = result.setZone(timezone);
    }
    else {
        if (parsedUtcOffset) {
            // explicit UTC offset
            result = result.setZone(`UTC+${parsedUtcOffset / 60}`);
        }
    }
    Reflect.set(result, 'format', function (format) {
        return format_date_time_1.formatDateTime(this, format);
    });
    return result;
}
exports.twingDateConverter = twingDateConverter;
/**
 * Replaces strings within a string.
 *
 * @param {string} str  String to replace in
 * @param {Array<string>|Map<string, string>} from Replace values
 *
 * @returns {string}
 */
function twingReplaceFilter(str, from) {
    if (is_traversable_1.isTraversable(from)) {
        from = iterator_to_hash_1.iteratorToHash(from);
    }
    else if (typeof from !== 'object') {
        throw new runtime_1.TwingErrorRuntime(`The "replace" filter expects an hash or "Iterable" as replace values, got "${typeof from}".`);
    }
    return strtr(str, from);
}
exports.twingReplaceFilter = twingReplaceFilter;
/**
 * Rounds a number.
 *
 * @param value The value to round
 * @param {number} precision The rounding precision
 * @param {string} method The method to use for rounding
 *
 * @returns int|float The rounded number
 */
function twingRound(value, precision = 0, method = 'common') {
    if (method === 'common') {
        return round(value, precision);
    }
    if (method !== 'ceil' && method !== 'floor') {
        throw new runtime_1.TwingErrorRuntime('The round filter only supports the "common", "ceil", and "floor" methods.');
    }
    let intermediateValue = value * Math.pow(10, precision);
    let intermediateDivider = Math.pow(10, precision);
    switch (method) {
        case 'ceil':
            return ceil(intermediateValue) / intermediateDivider;
        default:
            return floor(intermediateValue) / intermediateDivider;
    }
}
exports.twingRound = twingRound;
/**
 * Number format filter.
 *
 * All of the formatting options can be left null, in that case the defaults will
 * be used.  Supplying any of the parameters will override the defaults set in the
 * environment object.
 *
 * @param {TwingEnvironment} env
 * @param {*} number A float/int/string of the number to format
 * @param {number} decimal the number of decimal points to display
 * @param {string} decimalPoint the character(s) to use for the decimal point
 * @param {string} thousandSep the character(s) to use for the thousands separator
 *
 * @returns string The formatted number
 */
function twingNumberFormatFilter(env, number, decimal, decimalPoint, thousandSep) {
    const number_format = __webpack_require__(497);
    let coreExtension = env.getExtension('TwingExtensionCore');
    let defaults = coreExtension.getNumberFormat();
    if (util_1.isNullOrUndefined(decimal)) {
        decimal = defaults[0];
    }
    if (util_1.isNullOrUndefined(decimalPoint)) {
        decimalPoint = defaults[1];
    }
    if (util_1.isNullOrUndefined(thousandSep)) {
        thousandSep = defaults[2];
    }
    return number_format(number, decimal, decimalPoint, thousandSep);
}
exports.twingNumberFormatFilter = twingNumberFormatFilter;
/**
 * URL encodes (RFC 3986) a string as a path segment or a hash as a query string.
 *
 * @param {string|{}} url A URL or a hash of query parameters
 *
 * @returns {string} The URL encoded value
 */
function twingUrlencodeFilter(url) {
    const http_build_query = __webpack_require__(498);
    if (typeof url !== 'string') {
        if (is_traversable_1.isTraversable(url)) {
            url = iterator_to_hash_1.iteratorToHash(url);
        }
        let builtUrl = http_build_query(url, '', '&');
        return builtUrl.replace(/\+/g, '%20');
    }
    return encodeURIComponent(url);
}
exports.twingUrlencodeFilter = twingUrlencodeFilter;
/**
 * Merges an array with another one.
 *
 * <pre>
 *  {% set items = { 'apple': 'fruit', 'orange': 'fruit' } %}
 *
 *  {% set items = items|merge({ 'peugeot': 'car' }) %}
 *
 *  {# items now contains { 'apple': 'fruit', 'orange': 'fruit', 'peugeot': 'car' } #}
 * </pre>
 *
 * @param {*} arr1 An array
 * @param {*} arr2 An array
 *
 * @return array The merged array
 */
function twingArrayMerge(arr1, arr2) {
    if (util_1.isNullOrUndefined(arr1) || (!is_traversable_1.isTraversable(arr1) && (typeof arr1 !== 'object'))) {
        throw new runtime_1.TwingErrorRuntime(`The merge filter only works with arrays or "Traversable", got "${!util_1.isNullOrUndefined(arr1) ? typeof arr1 : arr1}" as first argument.`);
    }
    if (util_1.isNullOrUndefined(arr2) || (!is_traversable_1.isTraversable(arr2) && (typeof arr2 !== 'object'))) {
        throw new runtime_1.TwingErrorRuntime(`The merge filter only works with arrays or "Traversable", got "${!util_1.isNullOrUndefined(arr2) ? typeof arr2 : arr2}" as second argument.`);
    }
    return merge_1.merge(arr1, arr2);
}
exports.twingArrayMerge = twingArrayMerge;
/**
 * Slices a variable.
 *
 * @param {TwingEnvironment} env
 * @param item A variable
 * @param {number} start Start of the slice
 * @param {number} length Size of the slice
 * @param {boolean} preserveKeys Whether to preserve key or not (when the input is an object)
 *
 * @returns The sliced variable
 */
function twingSlice(env, item, start, length = null, preserveKeys = false) {
    if (is_traversable_1.isTraversable(item)) {
        let iterableItem = iterator_to_map_1.iteratorToMap(item);
        if (length === null) {
            length = iterableItem.size - start;
        }
        return slice_1.slice(iterableItem, start, length, preserveKeys);
    }
    item = '' + (item ? item : '');
    if (length === null) {
        length = item.length - start;
    }
    return item.substr(start, length);
}
exports.twingSlice = twingSlice;
/**
 * Returns the first element of the item.
 *
 * @param {TwingEnvironment} env
 * @param {*} item A variable
 *
 * @returns {*} The first element of the item
 */
function twingFirst(env, item) {
    let elements = twingSlice(env, item, 0, 1, false);
    return typeof elements === 'string' ? elements : first_1.first(elements);
}
exports.twingFirst = twingFirst;
/**
 * Returns the last element of the item.
 *
 * @param {TwingEnvironment} env
 * @param item A variable
 *
 * @returns The last element of the item
 */
function twingLast(env, item) {
    let elements = twingSlice(env, item, -1, 1, false);
    return typeof elements === 'string' ? elements : first_1.first(elements);
}
exports.twingLast = twingLast;
/**
 * Joins the values to a string.
 *
 * The separator between elements is an empty string per default, you can define it with the optional parameter.
 *
 * <pre>
 *  {{ [1, 2, 3]|join('|') }}
 *  {# returns 1|2|3 #}
 *
 *  {{ [1, 2, 3]|join }}
 *  {# returns 123 #}
 * </pre>
 *
 * @param {Array<*>} value An array
 * @param {string} glue The separator
 * @param {string | null} and The separator for the last pair
 *
 * @returns {string} The concatenated string
 */
function twingJoinFilter(value, glue = '', and = null) {
    if (util_1.isNullOrUndefined(value)) {
        return '';
    }
    if (is_traversable_1.isTraversable(value)) {
        value = iterator_to_array_1.iteratorToArray(value, false);
        // this is ugly but we have to ensure that each element of the array is rendered as PHP would render it
        // this is mainly useful for booleans that are not rendered the same way in PHP and JavaScript
        let safeValue = value.map(function (item) {
            if (typeof item === 'boolean') {
                return (item === true) ? '1' : '';
            }
            return item;
        });
        if (and === null || and === glue) {
            return safeValue.join(glue);
        }
        if (safeValue.length === 1) {
            return safeValue[0];
        }
        return safeValue.slice(0, -1).join(glue) + and + safeValue[safeValue.length - 1];
    }
    return '';
}
exports.twingJoinFilter = twingJoinFilter;
/**
 * Splits the string into an array.
 *
 * <pre>
 *  {{ "one,two,three"|split(',') }}
 *  {# returns [one, two, three] #}
 *
 *  {{ "one,two,three,four,five"|split(',', 3) }}
 *  {# returns [one, two, "three,four,five"] #}
 *
 *  {{ "123"|split('') }}
 *  {# returns [1, 2, 3] #}
 *
 *  {{ "aabbcc"|split('', 2) }}
 *  {# returns [aa, bb, cc] #}
 * </pre>
 *
 * @param {TwingEnvironment} env
 * @param {string} value A string
 * @param {string} delimiter The delimiter
 * @param {number} limit The limit
 *
 * @returns {Array<string>} The split string as an array
 */
function twingSplitFilter(env, value, delimiter, limit) {
    const explode = __webpack_require__(500);
    if (delimiter) {
        return !limit ? explode(delimiter, value) : explode(delimiter, value, limit);
    }
    if (!limit || limit <= 1) {
        return value.match(/.{1,1}/ug);
    }
    let length = value.length;
    if (length < limit) {
        return [value];
    }
    let r = [];
    for (let i = 0; i < length; i += limit) {
        r.push(value.substr(i, limit));
    }
    return r;
}
exports.twingSplitFilter = twingSplitFilter;
// The '_default' filter is used internally to avoid using the ternary operator
// which costs a lot for big contexts (before PHP 5.4). So, on average,
// a function call is cheaper.
/**
 * @internal
 */
function twingDefaultFilter(value, defaultValue = '') {
    if (twingTestEmpty(value)) {
        return defaultValue;
    }
    return value;
}
exports.twingDefaultFilter = twingDefaultFilter;
/**
 * Returns the keys for the given array.
 *
 * It is useful when you want to iterate over the keys of an array:
 *
 * <pre>
 *  {% for key in array|keys %}
 *      {# ... #}
 *  {% endfor %}
 * </pre>
 *
 * @param {Array<*>} array An array
 *
 * @returns {Array<*>} The keys
 */
function twingGetArrayKeysFilter(array) {
    let traversable;
    if (util_1.isNullOrUndefined(array)) {
        traversable = new Map();
    }
    else {
        traversable = iterator_to_map_1.iteratorToMap(array);
    }
    return [...traversable.keys()];
}
exports.twingGetArrayKeysFilter = twingGetArrayKeysFilter;
/**
 * Reverses a variable.
 *
 * @param {TwingEnvironment} env
 * @param {string | Map<*, *>} item A traversable instance, or a string
 * @param {boolean} preserveKeys Whether to preserve key or not
 *
 * @returns The reversed input
 */
function twingReverseFilter(env, item, preserveKeys = false) {
    if (typeof item === 'string') {
        let esrever = __webpack_require__(501);
        return esrever.reverse(item);
    }
    else {
        return reverse_1.reverse(iterator_to_map_1.iteratorToMap(item), preserveKeys);
    }
}
exports.twingReverseFilter = twingReverseFilter;
/**
 * Sorts an array.
 *
 * @param {Array<*>} array
 *
 * @returns {Map<*,*>}
 */
function twingSortFilter(array) {
    if (!is_traversable_1.isTraversable(array) && !Array.isArray(array)) {
        throw new runtime_1.TwingErrorRuntime(`The sort filter only works with iterables, got "${typeof array}".`);
    }
    let map = iterator_to_map_1.iteratorToMap(array);
    asort_1.asort(map);
    return map;
}
exports.twingSortFilter = twingSortFilter;
/**
 * @internal
 */
function twingInFilter(value, compare) {
    let result = false;
    if (value instanceof markup_1.TwingMarkup) {
        value = value.toString();
    }
    if (Array.isArray(compare)) {
        for (let item of compare) {
            if (compare_1.compare(item, value)) {
                result = true;
                break;
            }
        }
    }
    else if (typeof compare === 'string' && (typeof value === 'string' || typeof value === 'number')) {
        result = (value === '' || compare.includes('' + value));
    }
    else if (is_traversable_1.isTraversable(compare)) {
        for (let item of iterator_to_array_1.iteratorToArray(compare)) {
            if (compare_1.compare(item, value)) {
                result = true;
                break;
            }
        }
    }
    else if (typeof compare === 'object') {
        for (let key in compare) {
            if (compare_1.compare(compare[key], value)) {
                result = true;
                break;
            }
        }
    }
    return result;
}
exports.twingInFilter = twingInFilter;
/**
 * Returns a trimmed string.
 *
 * @returns {string}
 *
 * @throws TwingErrorRuntime When an invalid trimming side is used (not a string or not 'left', 'right', or 'both')
 */
function twingTrimFilter(string, characterMask = null, side = 'both') {
    const trim = __webpack_require__(502);
    const ltrim = __webpack_require__(337);
    const rtrim = __webpack_require__(262);
    if (characterMask === null) {
        characterMask = " \t\n\r\0\x0B";
    }
    switch (side) {
        case 'both':
            return trim(string, characterMask);
        case 'left':
            return ltrim(string, characterMask);
        case 'right':
            return rtrim(string, characterMask);
        default:
            throw new runtime_1.TwingErrorRuntime('Trimming side must be "left", "right" or "both".');
    }
}
exports.twingTrimFilter = twingTrimFilter;
/**
 * Removes whitespaces between HTML tags.
 *
 * @return string
 */
function twingSpacelessFilter(content) {
    return content.toString().replace(/>\s+</g, '><').trim();
}
exports.twingSpacelessFilter = twingSpacelessFilter;
/**
 * Escapes a string.
 *
 * @param {TwingEnvironment} env
 * @param {*} string The value to be escaped
 * @param {string} strategy The escaping strategy
 * @param {string} charset The charset
 * @param {boolean} autoescape Whether the function is called by the auto-escaping feature (true) or by the developer (false)
 *
 * @returns {string}
 */
function twingEscapeFilter(env, string, strategy = 'html', charset = null, autoescape = false) {
    if (autoescape && string && string instanceof markup_1.TwingMarkup) {
        return string;
    }
    if (typeof string !== 'string') {
        if (string && (typeof string === 'object') && Reflect.has(string, 'toString')) {
            string = '' + string;
        }
        else if (['html', 'js', 'css', 'html_attr', 'url'].includes(strategy)) {
            return string;
        }
    }
    if (string === '') {
        return '';
    }
    if (charset === null) {
        charset = env.getCharset();
    }
    let regExp = /^[.\s\S]/u;
    switch (strategy) {
        case 'html':
            return htmlspecialchars(string);
        case 'js':
            // escape all non-alphanumeric characters
            // into their \x or \uHHHH representations
            // if (charset !== 'UTF-8') {
            //     string = iconv(charset, 'UTF-8', string).toString();
            // }
            // unit: no test case for this
            // if ((strlen(string) === 0) ? false : !regExp.test(string)) {
            //     throw new TwingErrorRuntime('The string to escape is not a valid UTF-8 string.');
            // }
            string = string.replace(/[^a-zA-Z0-9,\._]/ug, function (matches) {
                let char = matches;
                /**
                 * A few characters have short escape sequences in JSON and JavaScript.
                 * Escape sequences supported only by JavaScript, not JSON, are ommitted.
                 * \" is also supported but omitted, because the resulting string is not HTML safe.
                 */
                let shortMap = new Map([
                    ['\\', '\\\\'],
                    ['/', '\\/'],
                    ["\x08", '\\b'],
                    ["\x0C", '\\f'],
                    ["\x0A", '\\n'],
                    ["\x0D", '\\r'],
                    ["\x09", '\\t'],
                ]);
                if (shortMap.has(char)) {
                    return shortMap.get(char);
                }
                // \uHHHH
                char = bin2hex(char).toUpperCase();
                if (strlen(char) <= 4) {
                    return sprintf('\\u%04s', char);
                }
                return sprintf('\\u%04s\\u%04s', char.substr(0, 4), char.substr(4, 4));
            });
            // if (charset !== 'UTF-8') {
            //     string = iconv('UTF-8', charset, string).toString();
            // }
            return string;
        case 'css':
            // if (charset !== 'UTF-8') {
            //     string = iconv(charset, 'UTF-8', string).toString();
            // }
            // unit: no test case for this
            // if ((strlen(string) === 0) ? false : !regExp.test(string)) {
            //     throw new TwingErrorRuntime('The string to escape is not a valid UTF-8 string.');
            // }
            string = string.replace(/[^a-zA-Z0-9]/ug, function (matches) {
                let char = matches;
                // \xHH
                if (strlen(char) === 1) {
                    let hex = ltrim(bin2hex(char).toUpperCase(), '0');
                    if (strlen(hex) === 0) {
                        hex = '0';
                    }
                    return '\\' + hex + ' ';
                }
                // \uHHHH
                return '\\' + ltrim(bin2hex(char).toUpperCase(), '0') + ' ';
            });
            // if (charset !== 'UTF-8') {
            //     string = iconv('UTF-8', charset, string).toString();
            // }
            return string;
        case 'html_attr':
            // if (charset !== 'UTF-8') {
            //     string = iconv(charset, 'UTF-8', string).toString();
            // }
            // unit: no test case for this
            // if ((strlen(string) === 0) ? false : !regExp.test(string)) {
            //     throw new TwingErrorRuntime('The string to escape is not a valid UTF-8 string.');
            // }
            string = string.replace(/[^a-zA-Z0-9,\.\-_]/ug, function (matches) {
                /**
                 * This function is adapted from code coming from Zend Framework.
                 *
                 * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
                 * @license   http://framework.zend.com/license/new-bsd New BSD License
                 */
                /*
                 * While HTML supports far more named entities, the lowest common denominator
                 * has become HTML5's XML Serialisation which is restricted to the those named
                 * entities that XML supports. Using HTML entities would result in this error:
                 *     XML Parsing Error: undefined entity
                 */
                let entityMap = new Map([
                    [34, 'quot'],
                    [38, 'amp'],
                    [60, 'lt'],
                    [62, 'gt'] /* greater-than sign */
                ]);
                let chr = matches;
                let ord = locutusOrd(chr);
                /*
                 * The following replaces characters undefined in HTML with the
                 * hex entity for the Unicode replacement character.
                 */
                if ((ord <= 0x1f && chr != "\t" && chr != "\n" && chr != "\r") || (ord >= 0x7f && ord <= 0x9f)) {
                    return '&#xFFFD;';
                }
                /*
                 * Check if the current character to escape has a name entity we should
                 * replace it with while grabbing the hex value of the character.
                 */
                let int = chr.codePointAt(0);
                if (entityMap.has(int)) {
                    return `&${entityMap.get(int)};`;
                }
                let hex = int.toString(16).toUpperCase();
                if (hex.length === 1 || hex.length === 3) {
                    hex = '0' + hex;
                }
                /*
                 * Per OWASP recommendations, we'll use hex entities for any other
                 * characters where a named entity does not exist.
                 */
                return `&#x${hex};`;
            });
            // if (charset !== 'UTF-8') {
            //     string = iconv('UTF-8', charset, string).toString();
            // }
            return string;
        case 'url':
            return rawurlencode(string);
        default:
            let coreExtension = env.getExtension('TwingExtensionCore');
            let escapers = coreExtension.getEscapers();
            if (escapers.has(strategy)) {
                return escapers.get(strategy)(env, string, charset);
            }
            let validStrategies = array_merge(['html', 'js', 'url', 'css', 'html_attr'], [...escapers.keys()]);
            throw new runtime_1.TwingErrorRuntime(`Invalid escaping strategy "${strategy}" (valid ones: ${validStrategies.join(', ')}).`);
    }
}
exports.twingEscapeFilter = twingEscapeFilter;
/**
 * @internal
 */
function twingEscapeFilterIsSafe(filterArgs) {
    if (filterArgs.getNodes().size > 0) {
        let result = [];
        filterArgs.getNodes().forEach(function (arg) {
            if (arg instanceof constant_2.TwingNodeExpressionConstant) {
                result = [arg.getAttribute('value')];
            }
        });
        return result;
    }
    else {
        return ['html'];
    }
}
exports.twingEscapeFilterIsSafe = twingEscapeFilterIsSafe;
function twingConvertEncoding(string, to, from) {
    return iconv_1.iconv(from, to, Buffer.from(string));
}
exports.twingConvertEncoding = twingConvertEncoding;
/**
 * Returns the length of a variable.
 *
 * @param {TwingEnvironment} env A TwingEnvironment instance
 * @param thing A variable
 *
 * @returns {number} The length of the value
 */
function twingLengthFilter(env, thing) {
    if (util_1.isNullOrUndefined(thing)) {
        return 0;
    }
    if (thing.length) {
        return thing.length;
    }
    if (thing.size) {
        return thing.size;
    }
    if (thing.toString && (typeof thing.toString === 'function')) {
        return thing.toString().length;
    }
    return 1;
}
exports.twingLengthFilter = twingLengthFilter;
/**
 * Converts a string to uppercase.
 *
 * @param {TwingEnvironment} env
 * @param {string | TwingMarkup} string A string
 *
 * @returns {string} The uppercased string
 */
function twingUpperFilter(env, string) {
    // todo: use charset
    if (typeof string !== 'string') {
        string = string.toString();
    }
    return string.toUpperCase();
}
exports.twingUpperFilter = twingUpperFilter;
/**
 * Converts a string to lowercase.
 *
 * @param {TwingEnvironment} env
 * @param {string} string A string
 *
 * @returns {string} The lowercased string
 */
function twingLowerFilter(env, string) {
    // todo: use charset
    return (typeof string === 'string') ? string.toLowerCase() : string;
}
exports.twingLowerFilter = twingLowerFilter;
/**
 * Returns a titlecased string.
 *
 * @param {TwingEnvironment} env
 * @param {string | TwingMarkup} string A string
 *
 * @returns {string} The titlecased string
 */
function twingTitleStringFilter(env, string) {
    const ucwords = __webpack_require__(503);
    return ucwords(string.toString().toLowerCase());
}
exports.twingTitleStringFilter = twingTitleStringFilter;
/**
 * Returns a capitalized string.
 *
 * @param {TwingEnvironment} env
 * @param {string} string A string
 *
 * @returns {string} The capitalized string
 */
function twingCapitalizeStringFilter(env, string) {
    return capitalize(string);
}
exports.twingCapitalizeStringFilter = twingCapitalizeStringFilter;
/**
 * @internal
 */
function twingEnsureTraversable(seq) {
    if (is_traversable_1.isTraversable(seq) || isPlainObject(seq)) {
        return seq;
    }
    return [];
}
exports.twingEnsureTraversable = twingEnsureTraversable;
/**
 * Checks if a variable is empty.
 *
 * <pre>
 * {# evaluates to true if the foo variable is null, false, or the empty string #}
 * {% if foo is empty %}
 *     {# ... #}
 * {% endif %}
 * </pre>
 *
 * @param value A variable
 *
 * @returns {boolean} true if the value is empty, false otherwise
 */
function twingTestEmpty(value) {
    if (value === null || value === undefined) {
        return true;
    }
    if (typeof value[Symbol.iterator] === 'function') {
        return value[Symbol.iterator]().next().done === true;
    }
    if (typeof value === 'object' && value.toString && typeof value.toString === 'function') {
        return value.toString().length < 1;
    }
    return value === false;
}
exports.twingTestEmpty = twingTestEmpty;
/**
 * Checks if a variable is traversable.
 *
 * <pre>
 * {# evaluates to true if the foo variable is an array or a traversable object #}
 * {% if foo is iterable %}
 *     {# ... #}
 * {% endif %}
 * </pre>
 *
 * @param value A variable
 *
 * @return {boolean} true if the value is traversable
 */
function twingTestIterable(value) {
    // in PHP a string is not traversable
    if (typeof value === 'string') {
        return false;
    }
    if (typeof value[Symbol.iterator] === 'function') {
        return true;
    }
    // in PHP objects are not iterable so we have to ensure that the test reflects that
    return false;
}
exports.twingTestIterable = twingTestIterable;
/**
 * Renders a template.
 *
 * @param {TwingEnvironment} env
 * @param {Map<*,*>} context
 * @param {TwingSource} source
 * @param {string|Array<string>} template The template to render or an array of templates to try consecutively
 * @param variables The variables to pass to the template
 * @param {boolean} withContext
 * @param {boolean} ignoreMissing Whether to ignore missing templates or not
 * @param {boolean} sandboxed Whether to sandbox the template or not
 *
 * @returns {string} The rendered template
 */
function twingInclude(env, context, source, template, variables = {}, withContext = true, ignoreMissing = false, sandboxed = false) {
    let alreadySandboxed = false;
    let sandbox = null;
    variables = iterator_to_map_1.iteratorToMap(variables);
    if (withContext) {
        variables = merge_1.merge(context, variables);
    }
    let isSandboxed = sandboxed && env.hasExtension('TwingExtensionSandbox');
    if (isSandboxed) {
        sandbox = env.getExtension('TwingExtensionSandbox');
        if (!(alreadySandboxed = sandbox.isSandboxed())) {
            sandbox.enableSandbox();
        }
    }
    let loaded = null;
    try {
        loaded = env.resolveTemplate(template, source);
    }
    catch (e) {
        if (e instanceof loader_1.TwingErrorLoader) {
            if (!ignoreMissing) {
                if (sandbox && !alreadySandboxed) {
                    sandbox.disableSandbox();
                }
                throw e;
            }
        }
        else {
            if (sandbox && !alreadySandboxed) {
                sandbox.disableSandbox();
            }
            throw e;
        }
    }
    let result;
    try {
        result = loaded ? loaded.render(variables) : '';
    }
    finally {
        if (sandbox && !alreadySandboxed) {
            sandbox.disableSandbox();
        }
    }
    return result;
}
exports.twingInclude = twingInclude;
/**
 * Returns a template content without rendering it.
 *
 * @param {TwingEnvironment} env
 * @param {TwingSource} source
 * @param {string} name The template name
 * @param {boolean} ignoreMissing Whether to ignore missing templates or not
 *
 * @return string The template source
 */
function twingSource(env, source, name, ignoreMissing = false) {
    let loader = env.getLoader();
    try {
        return loader.getSourceContext(name, source).getCode();
    }
    catch (e) {
        if (e instanceof loader_1.TwingErrorLoader) {
            if (!ignoreMissing) {
                throw e;
            }
        }
        else {
            throw e;
        }
    }
    return null;
}
exports.twingSource = twingSource;
/**
 * Provides the ability to get constants from instances as well as class/global constants.
 *
 * Constant function makes no sense in JavaScript. To emulate the expected behavior, it is assumed that
 * so-called constants are keys of the TwingEnvironment.globals property.
 *
 * @param {TwingEnvironment} env The environment
 * @param {string} constant The name of the constant
 * @param object The object to get the constant from
 *
 * @returns {string}
 */
function twingConstant(env, constant, object) {
    let globals = env.getGlobals();
    let bucket;
    if (object && typeof object === 'object') {
        let className = object.constructor.name;
        bucket = globals.get(className);
    }
    else {
        bucket = globals;
    }
    return bucket.get(constant);
}
exports.twingConstant = twingConstant;
/**
 * Batches item.
 *
 * @param {Array} items An array of items
 * @param {number} size  The size of the batch
 * @param {any} fill A value used to fill missing items
 * @param {boolean} preserveKeys
 *
 * @returns Array<any>
 */
function twingArrayBatch(items, size, fill = null, preserveKeys = true) {
    if (util_1.isNullOrUndefined(items)) {
        return [];
    }
    let chunks = chunk_1.chunk(items, size, preserveKeys);
    if (fill !== null && chunks.length) {
        let last = chunks.length - 1;
        let lastChunk = chunks[last];
        fill_1.fill(lastChunk, size, fill);
    }
    return chunks;
}
exports.twingArrayBatch = twingArrayBatch;
/**
 * Returns the attribute value for a given array/object.
 *
 * @param {TwingEnvironment} env
 * @param {*} object The object or array from where to get the item
 * @param {*} item The item to get from the array or object
 * @param {Array<*>} _arguments An array of arguments to pass if the item is an object method
 * @param {string} type The type of attribute (@see Twig_Template constants)
 * @param {boolean} isDefinedTest Whether this is only a defined check
 * @param {boolean} ignoreStrictCheck Whether to ignore the strict attribute check or not
 * @param {boolean} sandboxed
 *
 * @returns mixed The attribute value, or a Boolean when $isDefinedTest is true, or null when the attribute is not set and $ignoreStrictCheck is true
 *
 * @throws TwingErrorRuntime if the attribute does not exist and Twig is running in strict mode and $isDefinedTest is false
 *
 * @internal
 */
function twingGetAttribute(env, object, item, _arguments = [], type = template_1.TwingTemplate.ANY_CALL, isDefinedTest = false, ignoreStrictCheck = false, sandboxed = false) {
    let message;
    // ANY_CALL or ARRAY_CALL
    if (type !== template_1.TwingTemplate.METHOD_CALL) {
        let arrayItem;
        if (isBool(item)) {
            arrayItem = item ? 1 : 0;
        }
        else if (isFloat(item)) {
            arrayItem = parseInt(item);
        }
        else {
            arrayItem = item;
        }
        if (object) {
            if (Array.isArray(object) && (typeof object[arrayItem] !== 'undefined')) {
                if (isDefinedTest) {
                    return true;
                }
                return object[arrayItem];
            }
            else if (is_map_1.isMap(object) && object.has(arrayItem)) {
                if (isDefinedTest) {
                    return true;
                }
                return object.get(item);
            }
            else if (isPlainObject(object) && Reflect.has(object, arrayItem) && (typeof Reflect.get(object, arrayItem) !== 'function')) {
                if (isDefinedTest) {
                    return true;
                }
                return Reflect.get(object, item);
            }
        }
        if ((type === template_1.TwingTemplate.ARRAY_CALL) || (Array.isArray(object)) || (object instanceof Map) || (object === null) || (typeof object !== 'object')) {
            if (isDefinedTest) {
                return false;
            }
            if (ignoreStrictCheck || !env.isStrictVariables()) {
                return;
            }
            if (Array.isArray(object)) {
                // object is an array
                if (object.length < 1) {
                    message = `Index "${arrayItem}" is out of bounds as the array is empty.`;
                }
                else {
                    message = `Index "${arrayItem}" is out of bounds for array [${object}].`;
                }
            }
            else if (is_map_1.isMap(object)) {
                // object is a map
                message = `Impossible to access a key ("${item}") on a ${typeof object} variable ("${object.toString()}").`;
            }
            else if (type === template_1.TwingTemplate.ARRAY_CALL) {
                // object is another kind of object
                if (object === null) {
                    message = `Impossible to access a key ("${item}") on a null variable.`;
                }
                else {
                    message = `Impossible to access a key ("${item}") on a ${typeof object} variable ("${object.toString()}").`;
                }
            }
            else if (object === null) {
                // object is null
                message = `Impossible to access an attribute ("${item}") on a null variable.`;
            }
            else {
                // object is a primitive
                message = `Impossible to access an attribute ("${item}") on a ${typeof object} variable ("${object}").`;
            }
            throw new runtime_1.TwingErrorRuntime(message);
        }
    }
    // ANY_CALL or METHOD_CALL
    if ((object === null) || (!isObject(object))) {
        // object is a primitive
        if (isDefinedTest) {
            return false;
        }
        if (ignoreStrictCheck || !env.isStrictVariables()) {
            return;
        }
        if (object === null) {
            message = `Impossible to invoke a method ("${item}") on a null variable.`;
        }
        else if (Array.isArray(object)) {
            message = `Impossible to invoke a method ("${item}") on an array.`;
        }
        else {
            message = `Impossible to invoke a method ("${item}") on a ${typeof object} variable ("${object}").`;
        }
        throw new runtime_1.TwingErrorRuntime(message);
    }
    if (object instanceof template_1.TwingTemplate) {
        throw new runtime_1.TwingErrorRuntime('Accessing TwingTemplate attributes is forbidden.');
    }
    // object property
    if (type !== template_1.TwingTemplate.METHOD_CALL) {
        if (Reflect.has(object, item) && (typeof object[item] !== 'function')) {
            if (isDefinedTest) {
                return true;
            }
            if (sandboxed) {
                let extension = env.getExtension('TwingExtensionSandbox');
                extension.checkPropertyAllowed(object, item);
            }
            return object[item];
        }
    }
    // object method
    // precedence: getXxx() > isXxx() > hasXxx()
    let methods = [];
    for (let property of examine_object_1.examineObject(object)) {
        let candidate = object[property];
        if (typeof candidate === 'function') {
            methods.push(property);
        }
    }
    methods.sort();
    let lcMethods = methods.map((method) => {
        return method.toLowerCase();
    });
    let candidates = new Map();
    for (let i = 0; i < methods.length; i++) {
        let method = methods[i];
        let lcName = lcMethods[i];
        candidates.set(method, method);
        candidates.set(lcName, method);
        let name;
        if (lcName[0] === 'g' && lcName.indexOf('get') === 0) {
            name = method.substr(3);
            lcName = lcName.substr(3);
        }
        else if (lcName[0] === 'i' && lcName.indexOf('is') === 0) {
            name = method.substr(2);
            lcName = lcName.substr(2);
        }
        else if (lcName[0] === 'h' && lcName.indexOf('has') === 0) {
            name = method.substr(3);
            lcName = lcName.substr(3);
            if (lcMethods.includes('is' + lcName)) {
                continue;
            }
        }
        else {
            continue;
        }
        // skip get() and is() methods (in which case, name is empty)
        if (name) {
            if (!candidates.has(name)) {
                candidates.set(name, method);
            }
            if (!candidates.has(lcName)) {
                candidates.set(lcName, method);
            }
        }
    }
    let itemAsString = item;
    let method = null;
    let lcItem;
    if (candidates.has(item)) {
        method = candidates.get(item);
    }
    else if (candidates.has(lcItem = itemAsString.toLowerCase())) {
        method = candidates.get(lcItem);
    }
    else {
        if (isDefinedTest) {
            return false;
        }
        if (ignoreStrictCheck || !env.isStrictVariables()) {
            return;
        }
        throw new runtime_1.TwingErrorRuntime(`Neither the property "${item}" nor one of the methods ${item}()" or "get${item}()"/"is${item}()"/"has${item}()" exist and have public access in class "${object.constructor.name}".`);
    }
    if (isDefinedTest) {
        return true;
    }
    if (sandboxed) {
        let extension = env.getExtension('TwingExtensionSandbox');
        extension.checkMethodAllowed(object, method);
    }
    return Reflect.get(object, method).apply(object, _arguments);
}
exports.twingGetAttribute = twingGetAttribute;
/**
 * Return the values from a single column in the input array.
 *
 * <pre>
 *  {% set items = [{ 'fruit' : 'apple'}, {'fruit' : 'orange' }] %}
 *
 *  {% set fruits = items|column('fruit') %}
 *
 *  {# fruits now contains ['apple', 'orange'] #}
 * </pre>
 *
 * @param {*} thing An iterable
 * @param {*} columnKey The column key
 *
 * @return Array<any> The array of values
 */
function twingColumnFilter(thing, columnKey) {
    let map;
    if (!is_traversable_1.isTraversable(thing) || isPlainObject(thing)) {
        throw new runtime_1.TwingErrorRuntime(`The column filter only works with arrays or "Traversable", got "${typeof thing}" as first argument.`);
    }
    else {
        map = iterator_to_map_1.iteratorToMap(thing);
    }
    let result = [];
    for (let value of map.values()) {
        let valueAsMap = iterator_to_map_1.iteratorToMap(value);
        for (let [key, value] of valueAsMap) {
            if (key === columnKey) {
                result.push(value);
            }
        }
    }
    return result;
}
exports.twingColumnFilter = twingColumnFilter;
function twingFilterFilter(map, callback) {
    let result = new Map();
    map = iterator_to_map_1.iteratorToMap(map);
    for (let [k, v] of map) {
        if (callback(v)) {
            result.set(k, v);
        }
    }
    return result;
}
exports.twingFilterFilter = twingFilterFilter;
function twingFilterMap(map, callback) {
    let result = new Map();
    map = iterator_to_map_1.iteratorToMap(map);
    for (let [k, v] of map) {
        v = callback(v);
        result.set(k, v);
    }
    return result;
}
exports.twingFilterMap = twingFilterMap;
function twingFilterReduce(map, callback, initial = null) {
    map = iterator_to_map_1.iteratorToMap(map);
    let values = Array.from(map.values());
    return values.reduce((previousValue, currentValue) => {
        return callback(previousValue, currentValue);
    }, initial);
}
exports.twingFilterReduce = twingFilterReduce;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 258 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Loops over each item of a sequence.
 *
 * <pre>
 * <ul>
 *  {% for user in users %}
 *    <li>{{ user.username|e }}</li>
 *  {% endfor %}
 * </ul>
 * </pre>
 */
const token_parser_1 = __webpack_require__(111);
const node_1 = __webpack_require__(107);
const token_1 = __webpack_require__(109);
const syntax_1 = __webpack_require__(112);
const assign_name_1 = __webpack_require__(136);
const for_1 = __webpack_require__(259);
class TwingTokenParserFor extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let stream = this.parser.getStream();
        let targets = this.parser.getExpressionParser().parseAssignmentExpression();
        stream.expect(token_1.TwingToken.OPERATOR_TYPE, 'in');
        let seq = this.parser.getExpressionParser().parseExpression();
        let ifexpr = null;
        if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'if')) {
            console.error('Using an "if" condition on "for" tag is deprecated since Twig 2.10.0, use a "filter" filter or an "if" condition inside the "for" body instead (if your condition depends on a variable updated inside the loop).');
            ifexpr = this.parser.getExpressionParser().parseExpression();
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideForFork]);
        let elseToken;
        if (stream.next().getValue() == 'else') {
            stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
            elseToken = this.parser.subparse([this, this.decideForEnd], true);
        }
        else {
            elseToken = null;
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let keyTarget;
        let valueTarget;
        if ((targets.getNodes().size) > 1) {
            keyTarget = targets.getNode(0);
            keyTarget = new assign_name_1.TwingNodeExpressionAssignName(keyTarget.getAttribute('name'), keyTarget.getTemplateLine(), keyTarget.getTemplateColumn());
            valueTarget = targets.getNode(1);
            valueTarget = new assign_name_1.TwingNodeExpressionAssignName(valueTarget.getAttribute('name'), valueTarget.getTemplateLine(), valueTarget.getTemplateColumn());
        }
        else {
            keyTarget = new assign_name_1.TwingNodeExpressionAssignName('_key', lineno, columnno);
            valueTarget = targets.getNode(0);
            valueTarget = new assign_name_1.TwingNodeExpressionAssignName(valueTarget.getAttribute('name'), valueTarget.getTemplateLine(), valueTarget.getTemplateColumn());
        }
        if (ifexpr) {
            this.checkLoopUsageCondition(stream, ifexpr);
            this.checkLoopUsageBody(stream, body);
        }
        return new for_1.TwingNodeFor(keyTarget, valueTarget, seq, ifexpr, body, elseToken, lineno, columnno, this.getTag());
    }
    decideForFork(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, ['else', 'endfor']);
    }
    decideForEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endfor');
    }
    // the loop variable cannot be used in the condition
    checkLoopUsageCondition(stream, node) {
        let self = this;
        if ((node.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR) && (node.getNode('node').getType() === node_1.TwingNodeType.EXPRESSION_NAME) && (node.getNode('node').getAttribute('name') === 'loop')) {
            throw new syntax_1.TwingErrorSyntax('The "loop" variable cannot be used in a looping condition.', node.getTemplateLine(), stream.getSourceContext());
        }
        node.getNodes().forEach(function (n) {
            self.checkLoopUsageCondition(stream, n);
        });
    }
    // check usage of non-defined loop-items
    getTag() {
        return 'for';
    }
    // it does not catch all problems (for instance when a for is included into another or when the variable is used in an include)
    checkLoopUsageBody(stream, node) {
        if ((node.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR) && (node.getNode('node').getType() === node_1.TwingNodeType.EXPRESSION_NAME) && (node.getNode('node').getAttribute('name') === 'loop')) {
            let attribute = node.getNode('attribute');
            if ((attribute.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) && (['length', 'revindex0', 'revindex', 'last'].indexOf(attribute.getAttribute('value')) > -1)) {
                throw new syntax_1.TwingErrorSyntax(`The "loop.${attribute.getAttribute('value')}" variable is not defined when looping with a condition.`, node.getTemplateLine(), stream.getSourceContext());
            }
        }
        // should check for parent.loop.XXX usage
        if (node.getType() === node_1.TwingNodeType.FOR) {
            return;
        }
        for (let [k, n] of node.getNodes()) {
            this.checkLoopUsageBody(stream, n);
        }
    }
}
exports.TwingTokenParserFor = TwingTokenParserFor;


/***/ }),
/* 259 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
const for_loop_1 = __webpack_require__(260);
const if_1 = __webpack_require__(183);
class TwingNodeFor extends node_1.TwingNode {
    constructor(keyTarget, valueTarget, seq, ifexpr, body, elseNode, lineno, columnno, tag = null) {
        let loop = new for_loop_1.TwingNodeForLoop(lineno, columnno, tag);
        let bodyNodes = new Map();
        let i = 0;
        bodyNodes.set(i++, body);
        bodyNodes.set(i++, loop);
        body = new node_1.TwingNode(bodyNodes);
        if (ifexpr) {
            let ifNodes = new Map();
            let i = 0;
            ifNodes.set(i++, ifexpr);
            ifNodes.set(i++, body);
            body = new if_1.TwingNodeIf(new node_1.TwingNode(ifNodes), null, lineno, columnno, tag);
        }
        let nodes = new Map();
        nodes.set('key_target', keyTarget);
        nodes.set('value_target', valueTarget);
        nodes.set('seq', seq);
        nodes.set('body', body);
        if (elseNode) {
            nodes.set('else', elseNode);
        }
        let attributes = new Map();
        attributes.set('with_loop', true);
        attributes.set('ifexpr', ifexpr !== null);
        super(nodes, attributes, lineno, columnno, tag);
        this.type = node_1.TwingNodeType.FOR;
        this.loop = loop;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write("context.set('_parent', context.clone());\n\n")
            .write('(() => {\n')
            .indent()
            .write('let c = Runtime.twingEnsureTraversable(')
            .subcompile(this.getNode('seq'))
            .raw(");\n\n")
            .write('if (c === context) {\n')
            .indent()
            .write("context.set('_seq', context.clone());\n")
            .outdent()
            .write("}\n")
            .write("else {\n")
            .indent()
            .write("context.set('_seq', c);\n")
            .outdent()
            .write("}\n")
            .outdent()
            .write("})();\n\n");
        if (this.hasNode('else')) {
            compiler.write("context.set('_iterated', false);\n");
        }
        if (this.getAttribute('with_loop')) {
            compiler
                .write("context.set('loop', new Map([\n")
                .write("  ['parent', context.get('_parent')],\n")
                .write("  ['index0', 0],\n")
                .write("  ['index', 1],\n")
                .write("  ['first', true]\n")
                .write("]));\n");
            if (!this.getAttribute('ifexpr')) {
                compiler
                    .write("if (Array.isArray(context.get('_seq')) || (typeof context.get('_seq') === 'object' && Runtime.isCountable(context.get('_seq')))) {\n")
                    .indent()
                    .write("let length = Runtime.count(context.get('_seq'));\n")
                    .write("let loop = context.get('loop');\n")
                    .write("loop.set('revindex0', length - 1);\n")
                    .write("loop.set('revindex', length);\n")
                    .write("loop.set('length', length);\n")
                    .write("loop.set('last', (length === 1));\n")
                    .outdent()
                    .write("}\n");
            }
        }
        this.loop.setAttribute('else', this.hasNode('else'));
        this.loop.setAttribute('with_loop', this.getAttribute('with_loop'));
        this.loop.setAttribute('ifexpr', this.getAttribute('ifexpr'));
        compiler
            .write("Runtime.each.bind(this)(context.get('_seq'), (__key__, __value__) => {\n")
            .indent()
            .subcompile(this.getNode('key_target'), false)
            .raw(' = __key__;\n')
            .subcompile(this.getNode('value_target'), false)
            .raw(' = __value__;\n')
            .subcompile(this.getNode('body'))
            .outdent()
            .write("});\n");
        if (this.hasNode('else')) {
            compiler
                .write("if (context.get('_iterated') === false) {\n")
                .indent()
                .subcompile(this.getNode('else'))
                .outdent()
                .write("}\n");
        }
        compiler
            .write("(() => {\n")
            .indent()
            .write(`let parent = context.get('_parent');\n`);
        // remove some "private" loop variables (needed for nested loops)
        compiler
            .write('context.delete(\'_seq\');\n')
            .write('context.delete(\'_iterated\');\n')
            .write('context.delete(\'' + this.getNode('key_target').getAttribute('name') + '\');\n')
            .write('context.delete(\'' + this.getNode('value_target').getAttribute('name') + '\');\n')
            .write('context.delete(\'_parent\');\n')
            .write('context.delete(\'loop\');\n');
        // keep the values set in the inner context for variables defined in the outer context
        compiler
            .write(`for (let [k, v] of parent) {\n`)
            .indent()
            .write('if (!context.has(k)) {\n')
            .indent()
            .write(`context.set(k, v);\n`)
            .outdent()
            .write('}\n')
            .outdent()
            .write('}\n');
        compiler
            .outdent()
            .write("})();\n");
    }
}
exports.TwingNodeFor = TwingNodeFor;


/***/ }),
/* 260 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeForLoop extends node_1.TwingNode {
    constructor(lineno, columnno, tag = null) {
        let attributes = new Map();
        attributes.set('with_loop', false);
        attributes.set('ifexpr', false);
        attributes.set('else', false);
        super(new Map(), attributes, lineno, columnno, tag);
    }
    compile(compiler) {
        if (this.getAttribute('else')) {
            compiler.write("context.set('_iterated',  true);\n");
        }
        if (this.getAttribute('with_loop')) {
            compiler
                .write("(() => {\n")
                .indent()
                .write("let loop = context.get('loop');\n")
                .write("loop.set('index0', loop.get('index0') + 1);\n")
                .write("loop.set('index', loop.get('index') + 1);\n")
                .write("loop.set('first', false);\n");
            if (!this.getAttribute('ifexpr')) {
                compiler
                    .write("if (loop.has('length')) {\n")
                    .indent()
                    .write("loop.set('revindex0', loop.get('revindex0') - 1);\n")
                    .write("loop.set('revindex', loop.get('revindex') - 1);\n")
                    .write("loop.set('last', loop.get('revindex0') === 0);\n")
                    .outdent()
                    .write("}\n");
            }
            compiler
                .outdent()
                .write("})();\n");
        }
    }
}
exports.TwingNodeForLoop = TwingNodeForLoop;


/***/ }),
/* 261 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_1 = __webpack_require__(109);
const source_1 = __webpack_require__(130);
const syntax_1 = __webpack_require__(112);
const array_merge = __webpack_require__(186);
class TwingTokenStream {
    constructor(tokens, source = null) {
        this.current = 0;
        this.tokens = tokens;
        this.source = source ? source : new source_1.TwingSource('', '');
    }
    toString() {
        return this.tokens.map(function (token) {
            return token.toString();
        }).join('\n');
    }
    injectTokens(tokens) {
        this.tokens = array_merge(this.tokens.slice(0, this.current), tokens, this.tokens.slice(this.current));
    }
    /**
     * Sets the pointer to the next token and returns the old one.
     *
     * @return TwingToken
     */
    next() {
        this.current++;
        if (this.current >= this.tokens.length) {
            throw new syntax_1.TwingErrorSyntax('Unexpected end of template.', this.tokens[this.current - 1].getLine(), this.source);
        }
        return this.tokens[this.current - 1];
    }
    /**
     * Tests a token, sets the pointer to the next one and returns it or throws a syntax error.
     *
     * @return TwingToken|null The next token if the condition is true, null otherwise
     */
    nextIf(primary, secondary = null) {
        if (this.tokens[this.current].test(primary, secondary)) {
            return this.next();
        }
        return null;
    }
    /**
     * Tests a token and returns it or throws a syntax error.
     *
     * @return TwingToken
     */
    expect(type, value = null, message = null) {
        let token = this.tokens[this.current];
        if (!token.test(type, value)) {
            let line = token.getLine();
            throw new syntax_1.TwingErrorSyntax(`${message ? message + '. ' : ''}Unexpected token "${token_1.TwingToken.typeToEnglish(token.getType())}" of value "${token.getValue()}" ("${token_1.TwingToken.typeToEnglish(type)}" expected${value ? ` with value "${value}"` : ''}).`, line, this.source);
        }
        this.next();
        return token;
    }
    /**
     * Looks at the next token.
     *
     * @param number {number}
     *
     * @return TwingToken
     */
    look(number = 1) {
        let index = this.current + number;
        if (index >= this.tokens.length) {
            throw new syntax_1.TwingErrorSyntax('Unexpected end of template.', this.tokens[this.current + number - 1].getLine(), this.source);
        }
        return this.tokens[index];
    }
    /**
     * Tests the active token.
     *
     * @return bool
     */
    test(primary, secondary = null) {
        return this.tokens[this.current].test(primary, secondary);
    }
    /**
     * Checks if end of stream was reached.
     *
     * @return bool
     */
    isEOF() {
        return this.tokens[this.current].getType() === token_1.TwingToken.EOF_TYPE;
    }
    /**
     * @return TwingToken
     */
    getCurrent() {
        return this.tokens[this.current];
    }
    /**
     * Gets the source associated with this stream.
     *
     * @return TwingSource
     *
     * @internal
     */
    getSourceContext() {
        return this.source;
    }
}
exports.TwingTokenStream = TwingTokenStream;


/***/ }),
/* 262 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function rtrim(str, charlist) {
  //  discuss at: http://locutus.io/php/rtrim/
  // original by: Kevin van Zonneveld (http://kvz.io)
  //    input by: Erkekjetter
  //    input by: rem
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  //   example 1: rtrim('    Kevin van Zonneveld    ')
  //   returns 1: '    Kevin van Zonneveld'

  charlist = !charlist ? ' \\s\xA0' : (charlist + '').replace(/([[\]().?/*{}+$^:])/g, '\\$1');

  var re = new RegExp('[' + charlist + ']+$', 'g');

  return (str + '').replace(re, '');
};
//# sourceMappingURL=rtrim.js.map

/***/ }),
/* 263 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const template_1 = __webpack_require__(123);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionGetAttr extends expression_1.TwingNodeExpression {
    constructor(node, attribute, methodArguments, type, lineno, columnno) {
        let nodes = new Map();
        nodes.set('node', node);
        nodes.set('attribute', attribute);
        if (methodArguments) {
            nodes.set('arguments', methodArguments);
        }
        let nodeAttributes = new Map();
        nodeAttributes.set('type', type);
        nodeAttributes.set('is_defined_test', false);
        nodeAttributes.set('ignore_strict_check', false);
        nodeAttributes.set('optimizable', true);
        super(nodes, nodeAttributes, lineno, columnno);
        this.type = node_1.TwingNodeType.EXPRESSION_GET_ATTR;
    }
    compile(compiler) {
        let env = compiler.getEnvironment();
        // optimize array, hash and Map calls
        if (this.getAttribute('optimizable')
            && (!env.isStrictVariables() || this.getAttribute('ignore_strict_check'))
            && !this.getAttribute('is_defined_test')
            && template_1.TwingTemplate.ARRAY_CALL === this.getAttribute('type')) {
            let var_ = compiler.getVarName();
            compiler
                .raw('(() => {let ' + var_ + ' = ')
                .subcompile(this.getNode('node'))
                .raw('; return Runtime.isMap(')
                .raw(var_)
                .raw(') ? (')
                .raw(var_)
                .raw('.has(')
                .subcompile(this.getNode('attribute'))
                .raw(') ? ')
                .raw(var_)
                .raw('.get(')
                .subcompile(this.getNode('attribute'))
                .raw(') : null) : (Array.isArray(')
                .raw(var_)
                .raw(') || Runtime.isPlainObject(')
                .raw(var_)
                .raw(') ? ')
                .raw(var_)
                .raw('[')
                .subcompile(this.getNode('attribute'))
                .raw('] : null);})()');
            return;
        }
        compiler.raw(`this.traceableMethod(Runtime.twingGetAttribute, ${this.getTemplateLine()}, this.source)(this.env, `);
        if (this.getAttribute('ignore_strict_check')) {
            this.getNode('node').setAttribute('ignore_strict_check', true);
        }
        compiler.subcompile(this.getNode('node'));
        compiler.raw(', ').subcompile(this.getNode('attribute'));
        // only generate optional arguments when needed (to make generated code more readable)
        let needFifth = env.hasExtension('TwingExtensionSandbox');
        let needFourth = needFifth || this.getAttribute('ignore_strict_check');
        let needThird = needFourth || this.getAttribute('is_defined_test');
        let needSecond = needThird || this.getAttribute('type') !== template_1.TwingTemplate.ANY_CALL;
        let needFirst = needSecond || this.hasNode('arguments');
        if (needFirst) {
            if (this.hasNode('arguments')) {
                compiler.raw(', ').subcompile(this.getNode('arguments'));
            }
            else {
                compiler.raw(', []');
            }
        }
        if (needSecond) {
            compiler.raw(', ').repr(this.getAttribute('type'));
        }
        if (needThird) {
            compiler.raw(', ').repr(this.getAttribute('is_defined_test'));
        }
        if (needFourth) {
            compiler.raw(', ').repr(this.getAttribute('ignore_strict_check'));
        }
        if (needFifth) {
            compiler.raw(', ').repr(env.hasExtension('TwingExtensionSandbox'));
        }
        compiler.raw(')');
    }
    ;
}
exports.TwingNodeExpressionGetAttr = TwingNodeExpressionGetAttr;


/***/ }),
/* 264 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingContext {
    constructor(container) {
        this._container = container;
        this._proxy = new Proxy(this._container, {
            set: (target, key, value, receiver) => {
                target.set(key, value);
                return true;
            },
            get(target, key, receiver) {
                return target.get(key);
            }
        });
    }
    get proxy() {
        return this._proxy;
    }
    [Symbol.iterator]() {
        return this._container.entries();
    }
    entries() {
        return this._container.entries();
    }
    has(key) {
        return this._container.has(key);
    }
    set(key, value) {
        this._container.set(key, value);
        return this;
    }
    get(key) {
        return this._container.get(key);
    }
    delete(key) {
        return this._container.delete(key);
    }
    clone() {
        let clonedContainer = new Map();
        for (let [key, value] of this._container) {
            clonedContainer.set(key, value);
        }
        return new TwingContext(clonedContainer);
    }
}
exports.TwingContext = TwingContext;


/***/ }),
/* 265 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionMethodCall extends expression_1.TwingNodeExpression {
    constructor(node, method, methodArguments, lineno, columnno) {
        let nodes = new Map();
        nodes.set('node', node);
        nodes.set('arguments', methodArguments);
        let attributes = new Map();
        attributes.set('method', method);
        attributes.set('safe', false);
        super(nodes, attributes, lineno, columnno);
        this.type = node_1.TwingNodeType.EXPRESSION_METHOD_CALL;
    }
    compile(compiler) {
        compiler
            .subcompile(this.getNode('node'))
            .raw('.')
            .raw(this.getAttribute('method'))
            .raw('(');
        let first = true;
        let argumentsNode = this.getNode('arguments');
        for (let pair of argumentsNode.getKeyValuePairs()) {
            if (!first) {
                compiler.raw(', ');
            }
            first = false;
            compiler.subcompile(pair['value']);
        }
        compiler.raw(')');
    }
}
exports.TwingNodeExpressionMethodCall = TwingNodeExpressionMethodCall;


/***/ }),
/* 266 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {
Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionParent extends expression_1.TwingNodeExpression {
    constructor(name, lineno) {
        let attributes = new Map();
        attributes.set('output', false);
        attributes.set('name', name);
        super(new Map(), attributes, lineno);
        this.type = node_1.TwingNodeType.EXPRESSION_PARENT;
    }
    compile(compiler) {
        let name = this.getAttribute('name');
        const varValidator = __webpack_require__(139);
        if (!varValidator.isValid(name)) {
            name = Buffer.from(name).toString('hex');
        }
        if (this.getAttribute('output')) {
            compiler
                .addDebugInfo(this)
                .write(`this.traceableDisplayParentBlock(${this.getTemplateLine()}, this.source)(`)
                .string(name)
                .raw(", context, blocks);\n");
        }
        else {
            compiler
                .raw(`this.traceableRenderParentBlock(${this.getTemplateLine()}, this.source)(`)
                .string(name)
                .raw(', context, blocks)');
        }
    }
}
exports.TwingNodeExpressionParent = TwingNodeExpressionParent;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 267 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const array_1 = __webpack_require__(154);
class TwingNodeExpressionHash extends array_1.TwingNodeExpressionArray {
    compile(compiler) {
        compiler
            .raw('new Map([');
        let first = true;
        for (let pair of this.getKeyValuePairs()) {
            if (!first) {
                compiler.raw(', ');
            }
            first = false;
            compiler
                .raw('[')
                .subcompile(pair.key)
                .raw(', ')
                .subcompile(pair.value)
                .raw(']');
        }
        compiler.raw('])');
    }
}
exports.TwingNodeExpressionHash = TwingNodeExpressionHash;


/***/ }),
/* 268 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Loops over each item of a sequence.
 *
 * <pre>
 * <ul>
 *  {% for user in users %}
 *    <li>{{ user.username|e }}</li>
 *  {% endfor %}
 * </ul>
 * </pre>
 */
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const syntax_1 = __webpack_require__(112);
class TwingTokenParserExtends extends token_parser_1.TwingTokenParser {
    parse(token) {
        let stream = this.parser.getStream();
        if (!this.parser.isMainScope()) {
            throw new syntax_1.TwingErrorSyntax('Cannot extend from a block.', token.getLine(), stream.getSourceContext());
        }
        if (this.parser.getParent() !== null) {
            throw new syntax_1.TwingErrorSyntax('Multiple extends tags are forbidden.', token.getLine(), stream.getSourceContext());
        }
        this.parser.setParent(this.parser.getExpressionParser().parseExpression());
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        return null;
    }
    getTag() {
        return 'extends';
    }
}
exports.TwingTokenParserExtends = TwingTokenParserExtends;


/***/ }),
/* 269 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const import_1 = __webpack_require__(191);
const assign_name_1 = __webpack_require__(136);
/**
 * Imports macros.
 *
 * <pre>
 *   {% from 'forms.html' import forms %}
 * </pre>
 */
class TwingTokenParserFrom extends token_parser_1.TwingTokenParser {
    parse(token) {
        let macro = this.parser.getExpressionParser().parseExpression();
        let stream = this.parser.getStream();
        stream.expect(token_1.TwingToken.NAME_TYPE, 'import');
        let targets = new Map();
        do {
            let name = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
            let alias = name;
            if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'as')) {
                alias = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
            }
            targets.set(name, alias);
            if (!stream.nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ',')) {
                break;
            }
        } while (true);
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let node = new import_1.TwingNodeImport(macro, new assign_name_1.TwingNodeExpressionAssignName(this.parser.getVarName(), token.getLine(), token.getColumn()), token.getLine(), token.getColumn(), this.getTag());
        for (let [name, alias] of targets) {
            this.parser.addImportedSymbol('function', alias, `macro_${name}`, node.getNode('var'));
        }
        return node;
    }
    getTag() {
        return 'from';
    }
}
exports.TwingTokenParserFrom = TwingTokenParserFrom;


/***/ }),
/* 270 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {
Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Defines a macro.
 *
 * <pre>
 * {% macro input(name, value, type, size) %}
 *    <input type="{{ type|default('text') }}" name="{{ name }}" value="{{ value|e }}" size="{{ size|default(20) }}" />
 * {% endmacro %}
 * </pre>
 */
const token_1 = __webpack_require__(109);
const token_parser_1 = __webpack_require__(111);
const syntax_1 = __webpack_require__(112);
const body_1 = __webpack_require__(157);
const macro_1 = __webpack_require__(271);
const varValidator = __webpack_require__(139);
class TwingTokenParserMacro extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let stream = this.parser.getStream();
        let name = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
        let safeName = name;
        if (!varValidator.isValid(name)) {
            safeName = Buffer.from(name).toString('hex');
        }
        let macroArguments = this.parser.getExpressionParser().parseArguments(true, true);
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        this.parser.pushLocalScope();
        let body = this.parser.subparse([this, this.decideBlockEnd], true);
        if (token = stream.nextIf(token_1.TwingToken.NAME_TYPE)) {
            let value = token.getValue();
            if (value != name) {
                throw new syntax_1.TwingErrorSyntax(`Expected endmacro for macro "${name}" (but "${value}" given).`, stream.getCurrent().getLine(), stream.getSourceContext());
            }
        }
        this.parser.popLocalScope();
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let nodes = new Map([
            [0, body]
        ]);
        this.parser.setMacro(name, new macro_1.TwingNodeMacro(safeName, new body_1.TwingNodeBody(nodes), macroArguments, lineno, columnno, this.getTag()));
        return null;
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endmacro');
    }
    getTag() {
        return 'macro';
    }
}
exports.TwingTokenParserMacro = TwingTokenParserMacro;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 271 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Represents a macro node.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
const node_1 = __webpack_require__(107);
const syntax_1 = __webpack_require__(112);
class TwingNodeMacro extends node_1.TwingNode {
    constructor(name, body, macroArguments, lineno, columnno, tag = null) {
        for (let [argumentName, macroArgument] of macroArguments.getNodes()) {
            if (argumentName === TwingNodeMacro.VARARGS_NAME) {
                throw new syntax_1.TwingErrorSyntax(`The argument "${TwingNodeMacro.VARARGS_NAME}" in macro "${name}" cannot be defined because the variable "${TwingNodeMacro.VARARGS_NAME}" is reserved for arbitrary arguments.`, macroArgument.getTemplateLine());
            }
        }
        let nodes = new Map();
        nodes.set('body', body);
        nodes.set('arguments', macroArguments);
        super(nodes, new Map([['name', name]]), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.MACRO;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write(`macro_${this.getAttribute('name')}(`);
        let count = this.getNode('arguments').getNodes().size;
        let pos = 0;
        for (let [name, default_] of this.getNode('arguments').getNodes()) {
            compiler
                .raw('__' + name + '__ = ')
                .subcompile(default_);
            if (++pos < count) {
                compiler.raw(', ');
            }
        }
        if (count) {
            compiler.raw(', ');
        }
        compiler
            .raw('...__varargs__')
            .raw(") {\n")
            .indent();
        compiler
            .write("let context = new Runtime.TwingContext(this.env.mergeGlobals(new Map([\n")
            .indent();
        let first = true;
        for (let [name, default_] of this.getNode('arguments').getNodes()) {
            if (!first) {
                compiler.raw(',\n');
            }
            first = false;
            compiler
                .write('[')
                .string(name)
                .raw(', __' + name + '__]');
        }
        if (!first) {
            compiler.raw(',\n');
        }
        compiler
            .write('[')
            .string(TwingNodeMacro.VARARGS_NAME)
            .raw(', ');
        compiler
            .raw("\__varargs__]\n")
            .outdent()
            .write("])));\n\n")
            .write("let blocks = new Map();\n")
            .write('let result;\n')
            .write('let error;\n\n')
            .write("Runtime.obStart();\n")
            .write("try {\n")
            .indent()
            .subcompile(this.getNode('body'))
            .raw("\n")
            .write('let tmp = Runtime.obGetContents();\n')
            .write("result = (tmp === '') ? '' : new Runtime.TwingMarkup(tmp, this.env.getCharset());\n")
            .outdent()
            .write("}\n")
            .write('catch (e) {\n')
            .indent()
            .write('error = e;\n')
            .outdent()
            .write('}\n\n')
            .write("Runtime.obEndClean();\n\n")
            .write('if (error) {\n')
            .indent()
            .write('throw error;\n')
            .outdent()
            .write('}\n')
            .write('return result;\n')
            .outdent()
            .write("}\n\n");
    }
}
exports.TwingNodeMacro = TwingNodeMacro;
TwingNodeMacro.VARARGS_NAME = 'varargs';


/***/ }),
/* 272 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryIn extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('Runtime.twingInFilter(')
            .subcompile(this.getNode('left'))
            .raw(', ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryIn = TwingNodeExpressionBinaryIn;


/***/ }),
/* 273 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Tests a condition.
 *
 * <pre>
 * {% if users %}
 *  <ul>
 *    {% for user in users %}
 *      <li>{{ user.username|e }}</li>
 *    {% endfor %}
 *  </ul>
 * {% endif %}
 * </pre>
 */
const token_parser_1 = __webpack_require__(111);
const node_1 = __webpack_require__(107);
const token_1 = __webpack_require__(109);
const if_1 = __webpack_require__(183);
class TwingTokenParserIf extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let expr = this.parser.getExpressionParser().parseExpression();
        let stream = this.parser.getStream();
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let index = 0;
        let body = this.parser.subparse([this, this.decideIfFork]);
        let tests = new Map([
            [index++, expr],
            [index++, body]
        ]);
        let elseNode = null;
        let end = false;
        while (!end) {
            switch (stream.next().getValue()) {
                case 'else':
                    stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
                    elseNode = this.parser.subparse([this, this.decideIfEnd]);
                    break;
                case 'elseif':
                    expr = this.parser.getExpressionParser().parseExpression();
                    stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
                    body = this.parser.subparse([this, this.decideIfFork]);
                    tests.set(index++, expr);
                    tests.set(index++, body);
                    break;
                case 'endif':
                    end = true;
                    break;
            }
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new if_1.TwingNodeIf(new node_1.TwingNode(tests), elseNode, lineno, columnno, this.getTag());
    }
    decideIfFork(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, ['elseif', 'else', 'endif']);
    }
    decideIfEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endif');
    }
    getTag() {
        return 'if';
    }
}
exports.TwingTokenParserIf = TwingTokenParserIf;


/***/ }),
/* 274 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Loops over each item of a sequence.
 *
 * <pre>
 * <ul>
 *  {% for user in users %}
 *    <li>{{ user.username|e }}</li>
 *  {% endfor %}
 * </ul>
 * </pre>
 */
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const syntax_1 = __webpack_require__(112);
const set_1 = __webpack_require__(192);
class TwingTokenParserSet extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let stream = this.parser.getStream();
        let names = this.parser.getExpressionParser().parseAssignmentExpression();
        let capture = false;
        let values;
        if (stream.nextIf(token_1.TwingToken.OPERATOR_TYPE, '=')) {
            values = this.parser.getExpressionParser().parseMultitargetExpression();
            stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
            if (names.getNodes().size !== values.getNodes().size) {
                throw new syntax_1.TwingErrorSyntax('When using set, you must have the same number of variables and assignments.', stream.getCurrent().getLine(), stream.getSourceContext());
            }
        }
        else {
            capture = true;
            if (names.getNodes().size > 1) {
                throw new syntax_1.TwingErrorSyntax('When using set with a block, you cannot have a multi-target.', stream.getCurrent().getLine(), stream.getSourceContext());
            }
            stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
            values = this.parser.subparse([this, this.decideBlockEnd], true);
            stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        }
        return new set_1.TwingNodeSet(capture, names, values, lineno, columnno, this.getTag());
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endset');
    }
    getTag() {
        return 'set';
    }
}
exports.TwingTokenParserSet = TwingTokenParserSet;


/***/ }),
/* 275 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {
Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const node_1 = __webpack_require__(107);
const syntax_1 = __webpack_require__(112);
const block_1 = __webpack_require__(193);
const print_1 = __webpack_require__(124);
const block_reference_1 = __webpack_require__(276);
/**
 * Marks a section of a template as being reusable.
 *
 * <pre>
 *  {% block head %}
 *    <link rel="stylesheet" href="style.css" />
 *    <title>{% block title %}{% endblock %} - My Webpage</title>
 *  {% endblock %}
 * </pre>
 */
const varValidator = __webpack_require__(139);
class TwingTokenParserBlock extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let stream = this.parser.getStream();
        let name = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
        let safeName = name;
        if (!varValidator.isValid(name)) {
            safeName = Buffer.from(name).toString('hex');
        }
        if (this.parser.hasBlock(name)) {
            throw new syntax_1.TwingErrorSyntax(`The block '${name}' has already been defined line ${this.parser.getBlock(name).getTemplateLine()}.`, stream.getCurrent().getLine(), stream.getSourceContext());
        }
        let block = new block_1.TwingNodeBlock(safeName, new node_1.TwingNode(new Map()), lineno, columnno);
        this.parser.setBlock(name, block);
        this.parser.pushLocalScope();
        this.parser.pushBlockStack(name);
        let body;
        if (stream.nextIf(token_1.TwingToken.BLOCK_END_TYPE)) {
            body = this.parser.subparse([this, this.decideBlockEnd], true);
            let token = stream.nextIf(token_1.TwingToken.NAME_TYPE);
            if (token) {
                let value = token.getValue();
                if (value != name) {
                    throw new syntax_1.TwingErrorSyntax(`Expected endblock for block "${name}" (but "${value}" given).`, stream.getCurrent().getLine(), stream.getSourceContext());
                }
            }
        }
        else {
            let nodes = new Map();
            nodes.set(0, new print_1.TwingNodePrint(this.parser.getExpressionParser().parseExpression(), lineno, columnno));
            body = new node_1.TwingNode(nodes);
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        block.setNode('body', body);
        this.parser.popBlockStack();
        this.parser.popLocalScope();
        return new block_reference_1.TwingNodeBlockReference(name, lineno, columnno, this.getTag());
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endblock');
    }
    getTag() {
        return 'block';
    }
}
exports.TwingTokenParserBlock = TwingTokenParserBlock;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 276 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Represents a block call node.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
class TwingNodeBlockReference extends node_1.TwingNode {
    constructor(name, lineno, columnno, tag = null) {
        super(new Map(), new Map([['name', name]]), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.BLOCK_REFERENCE;
        this.TwingNodeOutputInterfaceImpl = this;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write(`this.traceableDisplayBlock(${this.getTemplateLine()}, this.source)('${this.getAttribute('name')}', context, blocks);\n`);
    }
}
exports.TwingNodeBlockReference = TwingNodeBlockReference;


/***/ }),
/* 277 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryGreater extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('>');
    }
}
exports.TwingNodeExpressionBinaryGreater = TwingNodeExpressionBinaryGreater;


/***/ }),
/* 278 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryLess extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('<');
    }
}
exports.TwingNodeExpressionBinaryLess = TwingNodeExpressionBinaryLess;


/***/ }),
/* 279 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const with_1 = __webpack_require__(280);
class TwingTokenParserWith extends token_parser_1.TwingTokenParser {
    parse(token) {
        let stream = this.parser.getStream();
        let variables = null;
        let only = false;
        if (!stream.test(token_1.TwingToken.BLOCK_END_TYPE)) {
            variables = this.parser.getExpressionParser().parseExpression();
            only = stream.nextIf(token_1.TwingToken.NAME_TYPE, 'only') !== null;
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideWithEnd], true);
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new with_1.TwingNodeWith(body, variables, only, token.getLine(), token.getColumn(), this.getTag());
    }
    decideWithEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endwith');
    }
    getTag() {
        return 'with';
    }
}
exports.TwingTokenParserWith = TwingTokenParserWith;


/***/ }),
/* 280 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeWith extends node_1.TwingNode {
    constructor(body, variables, only, lineno, columnno, tag = null) {
        let nodes = new Map();
        nodes.set('body', body);
        if (variables) {
            nodes.set('variables', variables);
        }
        super(nodes, new Map([['only', only]]), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.WITH;
    }
    compile(compiler) {
        compiler.addDebugInfo(this);
        if (this.hasNode('variables')) {
            let varsName = compiler.getVarName();
            compiler
                .write(`let ${varsName} = `)
                .subcompile(this.getNode('variables'))
                .raw(";\n")
                .write(`if (typeof (${varsName}) !== 'object') {\n`)
                .indent()
                .write('throw new Runtime.TwingErrorRuntime(\'Variables passed to the "with" tag must be a hash.\', ')
                .repr(this.getTemplateLine())
                .raw(", this.source);\n")
                .outdent()
                .write("}\n");
            if (this.getAttribute('only')) {
                compiler.write("context = new Map([['_parent', context]]);\n");
            }
            else {
                compiler.write("context.set('_parent', context.clone());\n");
            }
            compiler.write(`context = new Runtime.TwingContext(this.env.mergeGlobals(Runtime.merge(context, Runtime.iteratorToMap(${varsName}))));\n`);
        }
        else {
            compiler.write("context.set('_parent', context.clone());\n");
        }
        compiler
            .subcompile(this.getNode('body'))
            .write("context = context.get('_parent');\n");
    }
}
exports.TwingNodeWith = TwingNodeWith;


/***/ }),
/* 281 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const unary_1 = __webpack_require__(156);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionUnaryNeg extends unary_1.TwingNodeExpressionUnary {
    constructor(expr, lineno, columno) {
        super(expr, lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_UNARY_NEG;
    }
    operator(compiler) {
        return compiler.raw('-');
    }
}
exports.TwingNodeExpressionUnaryNeg = TwingNodeExpressionUnaryNeg;


/***/ }),
/* 282 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const unary_1 = __webpack_require__(156);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionUnaryPos extends unary_1.TwingNodeExpressionUnary {
    constructor(expr, lineno, columno) {
        super(expr, lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_UNARY_POS;
    }
    operator(compiler) {
        return compiler.raw('+');
    }
}
exports.TwingNodeExpressionUnaryPos = TwingNodeExpressionUnaryPos;


/***/ }),
/* 283 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
const call_1 = __webpack_require__(159);
class TwingNodeExpressionFunction extends call_1.TwingNodeExpressionCall {
    constructor(name, functionArguments, lineno) {
        let nodes = new Map([
            ['arguments', functionArguments]
        ]);
        let attributes = new Map();
        attributes.set('name', name);
        attributes.set('is_defined_test', false);
        super(nodes, attributes, lineno);
        this.type = node_1.TwingNodeType.EXPRESSION_FUNCTION;
    }
    compile(compiler) {
        let name = this.getAttribute('name');
        let function_ = compiler.getEnvironment().getFunction(name);
        this.setAttribute('name', name);
        this.setAttribute('type', 'function');
        this.setAttribute('needs_environment', function_.needsEnvironment());
        this.setAttribute('needs_context', function_.needsContext());
        this.setAttribute('needs_source', function_.needsSource());
        this.setAttribute('arguments', function_.getArguments());
        let callable = function_.getCallable();
        this.setAttribute('callable', callable);
        this.setAttribute('is_variadic', function_.isVariadic());
        this.compileCallable(compiler);
    }
}
exports.TwingNodeExpressionFunction = TwingNodeExpressionFunction;


/***/ }),
/* 284 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {
Object.defineProperty(exports, "__esModule", { value: true });
const reflection_parameter_1 = __webpack_require__(285);
// @see https://github.com/ericmorand/twing/issues/284
const parseFunction = __webpack_require__(452);
class TwingReflectionMethod {
    constructor(callable, name) {
        this.name = name;
        let parser = parseFunction();
        if (typeof callable === 'string') {
            callable = Reflect.get(global, callable);
        }
        this.callable = callable;
        try {
            let functionDefinition = parser.parse(this.callable);
            // name
            if (this.name === undefined) {
                this.name = functionDefinition.name;
            }
            // args
            this.parameters = [];
            for (let k in functionDefinition.defaults) {
                // @see https://github.com/rollup/rollup/wiki/Troubleshooting#avoiding-eval
                let defaultValue = new Function(`return (${functionDefinition.defaults[k]});`)();
                let reflectionParameter = new reflection_parameter_1.TwingReflectionParameter(k, defaultValue);
                this.parameters.push(reflectionParameter);
            }
            // second pass to find optional parameters
            for (let [i, parameter] of this.parameters.entries()) {
                // a parameter is optional if it has a default value and all subsequent parameters also have one
                let tail = this.parameters.slice(i);
                parameter.setOptional(tail.every(function (element) {
                    return element.isDefaultValueAvailable();
                }));
            }
        }
        catch (e) {
            throw new Error(`Method "${callable}" is not parsable (${e}).`);
        }
    }
    getName() {
        return this.name;
    }
    getParameters() {
        return this.parameters;
    }
}
exports.TwingReflectionMethod = TwingReflectionMethod;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 285 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
class TwingReflectionParameter {
    constructor(name, defaultValue) {
        this.optional = false;
        this.name = name;
        this.defaultValue = defaultValue;
    }
    isDefaultValueAvailable() {
        return (this.defaultValue !== undefined);
    }
    getName() {
        return this.name;
    }
    getDefaultValue() {
        return this.defaultValue;
    }
    isArray() {
        // type hinting, used by PHP to support that function, does not exist in JavaScript
        // if we have a default value, we test its type against Array
        // else we return true since any parameter can potentially be an array
        if (this.isDefaultValueAvailable()) {
            return Array.isArray(this.getDefaultValue());
        }
        return true;
    }
    isOptional() {
        return this.optional;
    }
    setOptional(flag) {
        this.optional = flag;
    }
}
exports.TwingReflectionParameter = TwingReflectionParameter;


/***/ }),
/* 286 */
/***/ (function(module, exports) {

module.exports = function (string) {
  return string.charAt(0).toUpperCase() + string.substring(1);
}

module.exports.words = function (string) {
  return string.replace(/(^|[^a-zA-Z\u00C0-\u017F'])([a-zA-Z\u00C0-\u017F])/g, function (m) {
    return m.toUpperCase()
  })
}


/***/ }),
/* 287 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Loops over each item of a sequence.
 *
 * <pre>
 * <ul>
 *  {% for user in users %}
 *    <li>{{ user.username|e }}</li>
 *  {% endfor %}
 * </ul>
 * </pre>
 */
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const spaceless_1 = __webpack_require__(288);
class TwingTokenParserSpaceless extends token_parser_1.TwingTokenParser {
    parse(token) {
        console.error('The "spaceless" tag is deprecated since Twig 2.7, use the "spaceless" filter instead.');
        let lineno = token.getLine();
        let columnno = token.getColumn();
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideSpacelessEnd], true);
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new spaceless_1.TwingNodeSpaceless(body, lineno, columnno, this.getTag());
    }
    decideSpacelessEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endspaceless');
    }
    getTag() {
        return 'spaceless';
    }
}
exports.TwingTokenParserSpaceless = TwingTokenParserSpaceless;


/***/ }),
/* 288 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeSpaceless extends node_1.TwingNode {
    constructor(body, lineno, columnno, tag = 'spaceless') {
        let nodes = new Map();
        nodes.set('body', body);
        super(nodes, new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.SPACELESS;
        this.TwingNodeOutputInterfaceImpl = this;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .addSourceMapEnter(this)
            .write("Runtime.obStart();\n")
            .subcompile(this.getNode('body'))
            .write("Runtime.echo(Runtime.obGetClean().replace(/>\\s+</g, '><').trim());\n")
            .addSourceMapLeave();
    }
}
exports.TwingNodeSpaceless = TwingNodeSpaceless;


/***/ }),
/* 289 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryMul extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('*');
    }
}
exports.TwingNodeExpressionBinaryMul = TwingNodeExpressionBinaryMul;


/***/ }),
/* 290 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const div_1 = __webpack_require__(198);
class TwingNodeExpressionBinaryFloorDiv extends div_1.TwingNodeExpressionBinaryDiv {
    compile(compiler) {
        compiler.raw('Math.floor(');
        super.compile(compiler);
        compiler.raw(')');
    }
    operator(compiler) {
        return compiler.raw('/');
    }
}
exports.TwingNodeExpressionBinaryFloorDiv = TwingNodeExpressionBinaryFloorDiv;


/***/ }),
/* 291 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryMod extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('%');
    }
}
exports.TwingNodeExpressionBinaryMod = TwingNodeExpressionBinaryMod;


/***/ }),
/* 292 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinarySub extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('-');
    }
}
exports.TwingNodeExpressionBinarySub = TwingNodeExpressionBinarySub;


/***/ }),
/* 293 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryAdd extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('+');
    }
}
exports.TwingNodeExpressionBinaryAdd = TwingNodeExpressionBinaryAdd;


/***/ }),
/* 294 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const syntax_1 = __webpack_require__(112);
const constant_1 = __webpack_require__(115);
const node_1 = __webpack_require__(107);
class TwingTokenParserUse extends token_parser_1.TwingTokenParser {
    parse(token) {
        let template = this.parser.getExpressionParser().parseExpression();
        let stream = this.parser.getStream();
        if (template.getType() !== node_1.TwingNodeType.EXPRESSION_CONSTANT) {
            throw new syntax_1.TwingErrorSyntax('The template references in a "use" statement must be a string.', stream.getCurrent().getLine(), stream.getSourceContext());
        }
        let targets = new Map();
        if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'with')) {
            do {
                let name = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
                let alias = name;
                if (stream.nextIf(token_1.TwingToken.NAME_TYPE, 'as')) {
                    alias = stream.expect(token_1.TwingToken.NAME_TYPE).getValue();
                }
                targets.set(name, new constant_1.TwingNodeExpressionConstant(alias, token.getLine(), token.getColumn()));
                if (!stream.nextIf(token_1.TwingToken.PUNCTUATION_TYPE, ',')) {
                    break;
                }
            } while (true);
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        this.parser.addTrait(new node_1.TwingNode(new Map([['template', template], ['targets', new node_1.TwingNode(targets)]])));
        return new node_1.TwingNode();
    }
    getTag() {
        return 'use';
    }
}
exports.TwingTokenParserUse = TwingTokenParserUse;


/***/ }),
/* 295 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_1 = __webpack_require__(109);
const include_1 = __webpack_require__(194);
const embed_1 = __webpack_require__(296);
const node_1 = __webpack_require__(107);
class TwingTokenParserEmbed extends include_1.TwingTokenParserInclude {
    parse(token) {
        let stream = this.parser.getStream();
        let parent = this.parser.getExpressionParser().parseExpression();
        let embedArguments = this.parseArguments();
        let variables = embedArguments.variables;
        let only = embedArguments.only;
        let ignoreMissing = embedArguments.ignoreMissing;
        let parentToken;
        let fakeParentToken;
        parentToken = fakeParentToken = new token_1.TwingToken(token_1.TwingToken.STRING_TYPE, '__parent__', token.getLine(), token.getColumn());
        if (parent.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) {
            parentToken = new token_1.TwingToken(token_1.TwingToken.STRING_TYPE, parent.getAttribute('value'), token.getLine(), token.getColumn());
        }
        else if (parent.getType() === node_1.TwingNodeType.EXPRESSION_NAME) {
            parentToken = new token_1.TwingToken(token_1.TwingToken.NAME_TYPE, parent.getAttribute('name'), token.getLine(), token.getColumn());
        }
        // inject a fake parent to make the parent() function work
        stream.injectTokens([
            new token_1.TwingToken(token_1.TwingToken.BLOCK_START_TYPE, '', token.getLine(), token.getColumn()),
            new token_1.TwingToken(token_1.TwingToken.NAME_TYPE, 'extends', token.getLine(), token.getColumn()),
            parentToken,
            new token_1.TwingToken(token_1.TwingToken.BLOCK_END_TYPE, '', token.getLine(), token.getColumn()),
        ]);
        let module = this.parser.parse(stream, [this, this.decideBlockEnd], true);
        // override the parent with the correct one
        if (fakeParentToken === parentToken) {
            module.setNode('parent', parent);
        }
        this.parser.embedTemplate(module);
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new embed_1.TwingNodeEmbed(module.getTemplateName(), module.getAttribute('index'), variables, only, ignoreMissing, token.getLine(), token.getColumn(), this.getTag());
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endembed');
    }
    getTag() {
        return 'embed';
    }
}
exports.TwingTokenParserEmbed = TwingTokenParserEmbed;


/***/ }),
/* 296 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const include_1 = __webpack_require__(195);
const constant_1 = __webpack_require__(115);
class TwingNodeEmbed extends include_1.TwingNodeInclude {
    // we don't inject the module to avoid node visitors to traverse it twice (as it will be already visited in the main module)
    constructor(name, index, variables, only, ignoreMissing, lineno, columnno, tag) {
        super(new constant_1.TwingNodeExpressionConstant('not_used', lineno, columnno), variables, only, ignoreMissing, lineno, columnno, tag);
        this.setAttribute('name', name);
        this.setAttribute('index', index);
    }
    addGetTemplate(compiler) {
        compiler
            .raw('this.loadTemplate(')
            .string(this.getAttribute('name'))
            .raw(', ')
            .repr(this.getTemplateName())
            .raw(', ')
            .repr(this.getTemplateLine())
            .raw(', ')
            .string(this.getAttribute('index'))
            .raw(')');
    }
}
exports.TwingNodeEmbed = TwingNodeEmbed;


/***/ }),
/* 297 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const block_reference_1 = __webpack_require__(189);
const constant_1 = __webpack_require__(115);
const block_1 = __webpack_require__(193);
const print_1 = __webpack_require__(124);
/**
 * Filters a section of a template by applying filters.
 *
 * <pre>
 * {% filter upper %}
 *  This text becomes uppercase
 * {% endfilter %}
 * </pre>
 */
class TwingTokenParserFilter extends token_parser_1.TwingTokenParser {
    parse(token) {
        console.error('The "filter" tag is deprecated since Twig 2.9, use the "apply" tag instead.');
        let name = this.parser.getVarName();
        let ref = new block_reference_1.TwingNodeExpressionBlockReference(new constant_1.TwingNodeExpressionConstant(name, token.getLine(), token.getColumn()), null, token.getLine(), token.getColumn(), this.getTag());
        let filter = this.parser.getExpressionParser().parseFilterExpressionRaw(ref, this.getTag());
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideBlockEnd], true);
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        let block = new block_1.TwingNodeBlock(name, body, token.getLine(), token.getColumn());
        this.parser.setBlock(name, block);
        return new print_1.TwingNodePrint(filter, token.getLine(), token.getColumn(), this.getTag());
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endfilter');
    }
    getTag() {
        return 'filter';
    }
}
exports.TwingTokenParserFilter = TwingTokenParserFilter;


/***/ }),
/* 298 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionBinaryRange extends binary_1.TwingNodeExpressionBinary {
    constructor(left, right, lineno, columno) {
        super(left, right, lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_BINARY_RANGE;
    }
    compile(compiler) {
        compiler
            .raw('Runtime.range(')
            .subcompile(this.getNode('left'))
            .raw(', ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryRange = TwingNodeExpressionBinaryRange;


/***/ }),
/* 299 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const assign_name_1 = __webpack_require__(136);
const import_1 = __webpack_require__(191);
class TwingTokenParserImport extends token_parser_1.TwingTokenParser {
    parse(token) {
        let macro = this.parser.getExpressionParser().parseExpression();
        this.parser.getStream().expect(token_1.TwingToken.NAME_TYPE, 'as');
        // template alias
        let var_ = new assign_name_1.TwingNodeExpressionAssignName(this.parser.getStream().expect(token_1.TwingToken.NAME_TYPE).getValue(), token.getLine(), token.getColumn());
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        this.parser.addImportedSymbol('template', var_.getAttribute('name'));
        return new import_1.TwingNodeImport(macro, var_, token.getLine(), token.getColumn(), this.getTag());
    }
    getTag() {
        return 'import';
    }
}
exports.TwingTokenParserImport = TwingTokenParserImport;


/***/ }),
/* 300 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const do_1 = __webpack_require__(199);
class TwingTokenParserDo extends token_parser_1.TwingTokenParser {
    parse(token) {
        let expr = this.parser.getExpressionParser().parseExpression();
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new do_1.TwingNodeDo(expr, token.getLine(), token.getColumn(), this.getTag());
    }
    getTag() {
        return 'do';
    }
}
exports.TwingTokenParserDo = TwingTokenParserDo;


/***/ }),
/* 301 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const flush_1 = __webpack_require__(302);
class TwingTokenParserFlush extends token_parser_1.TwingTokenParser {
    parse(token) {
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new flush_1.TwingNodeFlush(token.getLine(), token.getColumn(), this.getTag());
    }
    getTag() {
        return 'flush';
    }
}
exports.TwingTokenParserFlush = TwingTokenParserFlush;


/***/ }),
/* 302 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeFlush extends node_1.TwingNode {
    constructor(lineno, columnno, tag) {
        super(new Map(), new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.FLUSH;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write("Runtime.flush();\n");
    }
}
exports.TwingNodeFlush = TwingNodeFlush;


/***/ }),
/* 303 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryEqual extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('Runtime.compare(')
            .subcompile(this.getNode('left'))
            .raw(', ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryEqual = TwingNodeExpressionBinaryEqual;


/***/ }),
/* 304 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryNotEqual extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('!Runtime.compare(')
            .subcompile(this.getNode('left'))
            .raw(', ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryNotEqual = TwingNodeExpressionBinaryNotEqual;


/***/ }),
/* 305 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryOr extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('!!');
        super.compile(compiler);
    }
    operator(compiler) {
        return compiler.raw('||');
    }
}
exports.TwingNodeExpressionBinaryOr = TwingNodeExpressionBinaryOr;


/***/ }),
/* 306 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryBitwiseOr extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('|');
    }
}
exports.TwingNodeExpressionBinaryBitwiseOr = TwingNodeExpressionBinaryBitwiseOr;


/***/ }),
/* 307 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryBitwiseXor extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('^');
    }
}
exports.TwingNodeExpressionBinaryBitwiseXor = TwingNodeExpressionBinaryBitwiseXor;


/***/ }),
/* 308 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryBitwiseAnd extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('&');
    }
}
exports.TwingNodeExpressionBinaryBitwiseAnd = TwingNodeExpressionBinaryBitwiseAnd;


/***/ }),
/* 309 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryGreaterEqual extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('>=');
    }
}
exports.TwingNodeExpressionBinaryGreaterEqual = TwingNodeExpressionBinaryGreaterEqual;


/***/ }),
/* 310 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryLessEqual extends binary_1.TwingNodeExpressionBinary {
    operator(compiler) {
        return compiler.raw('<=');
    }
}
exports.TwingNodeExpressionBinaryLessEqual = TwingNodeExpressionBinaryLessEqual;


/***/ }),
/* 311 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryNotIn extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('!Runtime.twingInFilter(')
            .subcompile(this.getNode('left'))
            .raw(', ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryNotIn = TwingNodeExpressionBinaryNotIn;


/***/ }),
/* 312 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const conditional_1 = __webpack_require__(138);
const defined_1 = __webpack_require__(160);
const not_1 = __webpack_require__(155);
const null_1 = __webpack_require__(200);
const node_1 = __webpack_require__(107);
const and_1 = __webpack_require__(190);
class TwingNodeExpressionNullCoalesce extends conditional_1.TwingNodeExpressionConditional {
    constructor(left, right, lineno, columno) {
        let test = new and_1.TwingNodeExpressionBinaryAnd(new defined_1.TwingNodeExpressionTestDefined(left.clone(), 'defined', new node_1.TwingNode(), left.getTemplateLine(), left.getTemplateColumn()), new not_1.TwingNodeExpressionUnaryNot(new null_1.TwingNodeExpressionTestNull(left, 'null', new node_1.TwingNode(), left.getTemplateLine(), left.getTemplateColumn()), left.getTemplateLine(), left.getTemplateColumn()), left.getTemplateLine(), left.getTemplateColumn());
        super(test, left, right, lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_NULL_COALESCE;
        this.addType(node_1.TwingNodeType.EXPRESSION_NULL_COALESCE);
    }
    compile(compiler) {
        if (this.getNode('expr2').getType() === node_1.TwingNodeType.EXPRESSION_NAME) {
            this.getNode('expr2').setAttribute('always_defined', true);
        }
        return super.compile(compiler);
    }
}
exports.TwingNodeExpressionNullCoalesce = TwingNodeExpressionNullCoalesce;


/***/ }),
/* 313 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryPower extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('Math.pow(')
            .subcompile(this.getNode('left'))
            .raw(', ')
            .subcompile(this.getNode('right'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryPower = TwingNodeExpressionBinaryPower;


/***/ }),
/* 314 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
class TwingNodeExpressionTestSameAs extends test_1.TwingNodeExpressionTest {
    compile(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('node'))
            .raw(' === ')
            .subcompile(this.getNode('arguments').getNode(0))
            .raw(')');
    }
}
exports.TwingNodeExpressionTestSameAs = TwingNodeExpressionTestSameAs;


/***/ }),
/* 315 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
class TwingNodeExpressionTestOdd extends test_1.TwingNodeExpressionTest {
    compile(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('node'))
            .raw(' % 2 == 1')
            .raw(')');
    }
}
exports.TwingNodeExpressionTestOdd = TwingNodeExpressionTestOdd;


/***/ }),
/* 316 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
/**
 * Checks if a variable is the exact same value as a constant.
 *
 * <pre>
 *  {% if post.status is constant('Post::PUBLISHED') %}
 *    the status attribute is exactly the same as Post::PUBLISHED
 *  {% endif %}
 * </pre>
 *
 * Global or class constants make no sense in JavaScript. To emulate the expected behavior, it is assumed that
 * so-called constants are keys of the TwingEnvironment::globals property.
 */
class TwingNodeExpressionTestConstant extends test_1.TwingNodeExpressionTest {
    compile(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('node'))
            .raw(' === Runtime.twingConstant(this.env, ')
            .subcompile(this.getNode('arguments').getNode(0));
        if (this.getNode('arguments').hasNode(1)) {
            compiler
                .raw(', ')
                .subcompile(this.getNode('arguments').getNode(1));
        }
        compiler
            .raw('))');
    }
}
exports.TwingNodeExpressionTestConstant = TwingNodeExpressionTestConstant;


/***/ }),
/* 317 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
const callable_wrapper_1 = __webpack_require__(197);
const merge = __webpack_require__(152);
class TwingTest extends callable_wrapper_1.TwingCallableWrapper {
    /**
     * Creates a template test.
     *
     * @param {string} name Name of this test
     * @param {Function} callable A callable implementing the test. If null, you need to overwrite the "node_class" option to customize compilation.
     * @param {TwingTestOptions} options Options
     */
    constructor(name, callable = null, options = {}) {
        super(name, callable);
        this.methodArguments = [];
        this.options = merge({
            is_variadic: false,
            node_factory: function (node, name, nodeArguments, lineno, columnno) {
                return new test_1.TwingNodeExpressionTest(node, name, nodeArguments, lineno, columnno);
            },
            deprecated: false,
            alternative: null,
        }, options);
    }
    getNodeFactory() {
        return this.options.node_factory;
    }
    setArguments(someArguments) {
        this.methodArguments = someArguments;
    }
    getArguments() {
        return this.methodArguments;
    }
    isVariadic() {
        return this.options.is_variadic;
    }
    isDeprecated() {
        return this.options.deprecated ? true : false;
    }
    getDeprecatedVersion() {
        return this.options.deprecated;
    }
    getAlternative() {
        return this.options.alternative;
    }
}
exports.TwingTest = TwingTest;


/***/ }),
/* 318 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
/**
 * Checks if a variable is divisible by a number.
 *
 * <pre>
 *  {% if loop.index is divisible by(3) %}
 * </pre>
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
class TwingNodeExpressionTestDivisibleBy extends test_1.TwingNodeExpressionTest {
    compile(compiler) {
        compiler
            .raw('(0 == ')
            .subcompile(this.getNode('node'))
            .raw(' % ')
            .subcompile(this.getNode('arguments').getNode(0))
            .raw(')');
    }
}
exports.TwingNodeExpressionTestDivisibleBy = TwingNodeExpressionTestDivisibleBy;


/***/ }),
/* 319 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryMatches extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('Runtime.regexParser(')
            .subcompile(this.getNode('right'))
            .raw(').test(')
            .subcompile(this.getNode('left'))
            .raw(')');
    }
}
exports.TwingNodeExpressionBinaryMatches = TwingNodeExpressionBinaryMatches;


/***/ }),
/* 320 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryStartsWith extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('(() => {')
            .raw(`let left = `)
            .subcompile(this.getNode('left'))
            .raw('; ')
            .raw(`let right = `)
            .subcompile(this.getNode('right'))
            .raw('; ')
            .raw(`return typeof left === 'string' && typeof right === 'string' && (right.length < 1 || left.startsWith(right));`)
            .raw('})()');
    }
}
exports.TwingNodeExpressionBinaryStartsWith = TwingNodeExpressionBinaryStartsWith;


/***/ }),
/* 321 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const binary_1 = __webpack_require__(110);
class TwingNodeExpressionBinaryEndsWith extends binary_1.TwingNodeExpressionBinary {
    compile(compiler) {
        compiler
            .raw('(() => {')
            .raw(`let left = `)
            .subcompile(this.getNode('left'))
            .raw('; ')
            .raw(`let right = `)
            .subcompile(this.getNode('right'))
            .raw('; ')
            .raw(`return typeof left === 'string' && typeof right === 'string' && (right.length < 1 || left.endsWith(right));`)
            .raw('})()');
    }
}
exports.TwingNodeExpressionBinaryEndsWith = TwingNodeExpressionBinaryEndsWith;


/***/ }),
/* 322 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const filter_1 = __webpack_require__(161);
const node_1 = __webpack_require__(107);
const constant_1 = __webpack_require__(115);
const defined_1 = __webpack_require__(160);
const conditional_1 = __webpack_require__(138);
class TwingNodeExpressionFilterDefault extends filter_1.TwingNodeExpressionFilter {
    constructor(node, filterName, methodArguments, lineno, columnno, tag = null) {
        let defaultNode = new filter_1.TwingNodeExpressionFilter(node, new constant_1.TwingNodeExpressionConstant('default', node.getTemplateLine(), node.getTemplateColumn()), methodArguments, node.getTemplateLine(), node.getTemplateColumn());
        if (filterName.getAttribute('value') === 'default' && (node.getType() === node_1.TwingNodeType.EXPRESSION_NAME || node.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR)) {
            let test = new defined_1.TwingNodeExpressionTestDefined(node.clone(), 'defined', new node_1.TwingNode(), node.getTemplateLine(), node.getTemplateColumn());
            let falseNode = methodArguments.getNodes().size ? methodArguments.getNode(0) : new constant_1.TwingNodeExpressionConstant('', node.getTemplateLine(), node.getTemplateColumn());
            node = new conditional_1.TwingNodeExpressionConditional(test, defaultNode, falseNode, node.getTemplateLine(), node.getTemplateColumn());
        }
        else {
            node = defaultNode;
        }
        super(node, filterName, methodArguments, lineno, columnno, tag);
    }
    compile(compiler) {
        compiler.subcompile(this.getNode('node'));
    }
}
exports.TwingNodeExpressionFilterDefault = TwingNodeExpressionFilterDefault;


/***/ }),
/* 323 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const test_1 = __webpack_require__(118);
class TwingNodeExpressionTestEven extends test_1.TwingNodeExpressionTest {
    compile(compiler) {
        compiler
            .raw('(')
            .subcompile(this.getNode('node'))
            .raw(' % 2 == 0')
            .raw(')');
    }
}
exports.TwingNodeExpressionTestEven = TwingNodeExpressionTestEven;


/***/ }),
/* 324 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const each_1 = __webpack_require__(145);
/**
 * Split an hash into chunks.
 *
 * @param {*} hash
 * @param {number} size
 * @param {boolean} preserveKeys
 * @returns {Array<Map<any, any>>}
 */
function chunk(hash, size, preserveKeys = false) {
    let result = [];
    let count = 0;
    let currentMap;
    each_1.each(hash, (key, value) => {
        if (!currentMap) {
            currentMap = new Map();
            result.push(currentMap);
        }
        currentMap.set(preserveKeys ? key : count, value);
        count++;
        if (count >= size) {
            count = 0;
            currentMap = null;
        }
    });
    return result;
}
exports.chunk = chunk;


/***/ }),
/* 325 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Fill map with value until map's size is size.
 *
 * @param {Map<*, *>} map
 * @param {number} size
 * @param {any} value
 */
function fill(map, size, value) {
    if (size > map.size) {
        let delta = size - map.size;
        // resolve the greatest numeric key
        let greatestNumericKey = NaN;
        for (let key of map.keys()) {
            let keyAsNumber = Number(key);
            if (Number.isInteger(keyAsNumber)) {
                if (Number.isNaN(greatestNumericKey) || keyAsNumber > greatestNumericKey) {
                    greatestNumericKey = keyAsNumber;
                }
            }
        }
        let start = Number.isNaN(greatestNumericKey) ? 0 : greatestNumericKey + 1;
        for (let i = start; i < start + delta; i++) {
            map.set(i, value);
        }
    }
}
exports.fill = fill;


/***/ }),
/* 326 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const util_1 = __webpack_require__(133);
function slice(map, start, length, preserveKeys = false) {
    let result = new Map();
    let index = 0;
    let keyIndex = 0;
    if (start < 0) {
        start = map.size + start;
    }
    for (let [key, value] of map) {
        if ((index >= start) && (index < start + length)) {
            let newKey;
            // Note that array_slice() will reorder and reset the ***numeric*** array indices by default. [...]
            // see http://php.net/manual/en/function.array-slice.php
            if (util_1.isNumber(key)) {
                newKey = preserveKeys ? key : keyIndex;
                keyIndex++;
            }
            else {
                newKey = key;
            }
            result.set(newKey, value);
        }
        if (index >= start + length) {
            break;
        }
        index++;
    }
    return result;
}
exports.slice = slice;


/***/ }),
/* 327 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Sort a map and maintain index association.
 *
 * @param {Map<*, *>} map
 * @param {Function} handler
 * @returns {Map<* ,*>}
 */
function asort(map, handler = undefined) {
    let sortedMap = new Map();
    let keys = [].fill(null, 0, map.size);
    let sortedValues = [...map.values()].sort(handler);
    for (let [key, value] of map) {
        let index = sortedValues.indexOf(value);
        keys[index] = key;
    }
    for (let key of keys) {
        sortedMap.set(key, map.get(key));
    }
    map.clear();
    for (let [key, value] of sortedMap) {
        map.set(key, value);
    }
}
exports.asort = asort;


/***/ }),
/* 328 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Reverse a map
 *
 * @param {Map<* ,*>} map
 * @param {boolean} preserveKeys
 *
 * @returns Map
 */
function reverse(map, preserveKeys = false) {
    let result = new Map();
    let keys = [...map.keys()];
    let index = 0;
    for (let i = (keys.length - 1); i >= 0; i--) {
        let key = keys[i];
        result.set(preserveKeys ? key : index, map.get(key));
        index++;
    }
    return result;
}
exports.reverse = reverse;


/***/ }),
/* 329 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(204);
class TwingSourceMapNodeSpaceless extends node_1.TwingSourceMapNode {
    /**
     * TwingSourceMapNodeSpaceless constructor
     *
     * @param {number} line 0-based
     * @param {number} column 0-based
     * @param {TwingSource} source
     */
    constructor(line, column, source) {
        super(line, column, source, 'spaceless');
    }
    toSourceNode() {
        let flattenedChildren = [];
        let flattenChildren = (node) => {
            for (let child of node.children) {
                flattenedChildren.push(child);
                flattenChildren(child);
            }
        };
        flattenChildren(this);
        let tagCloseRegex = />\s*$/;
        let tagOpenRegex = /^\s*</;
        let emptyRegex = /^\s*$/;
        let leadingChildrenToTrim = [];
        let trailingChildrenToTrim = [];
        let i;
        let done;
        i = 0;
        done = false;
        while (!done && i < flattenedChildren.length) {
            let child = flattenedChildren[i];
            leadingChildrenToTrim.push(child);
            done = !emptyRegex.test(child.content);
            i++;
        }
        i = flattenedChildren.length - 1;
        done = false;
        while (!done && i >= 0) {
            let child = flattenedChildren[i];
            trailingChildrenToTrim.push(child);
            done = !emptyRegex.test(child.content);
            i--;
        }
        for (let child of leadingChildrenToTrim) {
            child.content = child.content.trimLeft();
        }
        for (let child of trailingChildrenToTrim) {
            child.content = child.content.trimRight();
        }
        let closeTagNode = null;
        let toEmptyNodes = [];
        for (let child of flattenedChildren) {
            if (!emptyRegex.test(child.content)) {
                child.content = child.content.replace(/>\s+</g, '><');
                if (closeTagNode) {
                    if (tagOpenRegex.test(child.content)) {
                        closeTagNode.content = closeTagNode.content.replace(/\s+$/, '');
                        child.content = child.content.replace(/^\s+/, '');
                        for (let node of toEmptyNodes) {
                            node.content = '';
                        }
                    }
                    closeTagNode = null;
                }
                if (tagCloseRegex.test(child.content)) {
                    closeTagNode = child;
                    toEmptyNodes.splice(0);
                }
            }
            else {
                if (closeTagNode) {
                    toEmptyNodes.push(child);
                }
            }
        }
        return super.toSourceNode();
    }
}
exports.TwingSourceMapNodeSpaceless = TwingSourceMapNodeSpaceless;


/***/ }),
/* 330 */
/***/ (function(module, exports, __webpack_require__) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

var base64VLQ = __webpack_require__(331);
var util = __webpack_require__(141);
var ArraySet = __webpack_require__(332).ArraySet;
var MappingList = __webpack_require__(468).MappingList;

/**
 * An instance of the SourceMapGenerator represents a source map which is
 * being built incrementally. You may pass an object with the following
 * properties:
 *
 *   - file: The filename of the generated source.
 *   - sourceRoot: A root for all relative URLs in this source map.
 */
function SourceMapGenerator(aArgs) {
  if (!aArgs) {
    aArgs = {};
  }
  this._file = util.getArg(aArgs, 'file', null);
  this._sourceRoot = util.getArg(aArgs, 'sourceRoot', null);
  this._skipValidation = util.getArg(aArgs, 'skipValidation', false);
  this._sources = new ArraySet();
  this._names = new ArraySet();
  this._mappings = new MappingList();
  this._sourcesContents = null;
}

SourceMapGenerator.prototype._version = 3;

/**
 * Creates a new SourceMapGenerator based on a SourceMapConsumer
 *
 * @param aSourceMapConsumer The SourceMap.
 */
SourceMapGenerator.fromSourceMap =
  function SourceMapGenerator_fromSourceMap(aSourceMapConsumer) {
    var sourceRoot = aSourceMapConsumer.sourceRoot;
    var generator = new SourceMapGenerator({
      file: aSourceMapConsumer.file,
      sourceRoot: sourceRoot
    });
    aSourceMapConsumer.eachMapping(function (mapping) {
      var newMapping = {
        generated: {
          line: mapping.generatedLine,
          column: mapping.generatedColumn
        }
      };

      if (mapping.source != null) {
        newMapping.source = mapping.source;
        if (sourceRoot != null) {
          newMapping.source = util.relative(sourceRoot, newMapping.source);
        }

        newMapping.original = {
          line: mapping.originalLine,
          column: mapping.originalColumn
        };

        if (mapping.name != null) {
          newMapping.name = mapping.name;
        }
      }

      generator.addMapping(newMapping);
    });
    aSourceMapConsumer.sources.forEach(function (sourceFile) {
      var sourceRelative = sourceFile;
      if (sourceRoot !== null) {
        sourceRelative = util.relative(sourceRoot, sourceFile);
      }

      if (!generator._sources.has(sourceRelative)) {
        generator._sources.add(sourceRelative);
      }

      var content = aSourceMapConsumer.sourceContentFor(sourceFile);
      if (content != null) {
        generator.setSourceContent(sourceFile, content);
      }
    });
    return generator;
  };

/**
 * Add a single mapping from original source line and column to the generated
 * source's line and column for this source map being created. The mapping
 * object should have the following properties:
 *
 *   - generated: An object with the generated line and column positions.
 *   - original: An object with the original line and column positions.
 *   - source: The original source file (relative to the sourceRoot).
 *   - name: An optional original token name for this mapping.
 */
SourceMapGenerator.prototype.addMapping =
  function SourceMapGenerator_addMapping(aArgs) {
    var generated = util.getArg(aArgs, 'generated');
    var original = util.getArg(aArgs, 'original', null);
    var source = util.getArg(aArgs, 'source', null);
    var name = util.getArg(aArgs, 'name', null);

    if (!this._skipValidation) {
      this._validateMapping(generated, original, source, name);
    }

    if (source != null) {
      source = String(source);
      if (!this._sources.has(source)) {
        this._sources.add(source);
      }
    }

    if (name != null) {
      name = String(name);
      if (!this._names.has(name)) {
        this._names.add(name);
      }
    }

    this._mappings.add({
      generatedLine: generated.line,
      generatedColumn: generated.column,
      originalLine: original != null && original.line,
      originalColumn: original != null && original.column,
      source: source,
      name: name
    });
  };

/**
 * Set the source content for a source file.
 */
SourceMapGenerator.prototype.setSourceContent =
  function SourceMapGenerator_setSourceContent(aSourceFile, aSourceContent) {
    var source = aSourceFile;
    if (this._sourceRoot != null) {
      source = util.relative(this._sourceRoot, source);
    }

    if (aSourceContent != null) {
      // Add the source content to the _sourcesContents map.
      // Create a new _sourcesContents map if the property is null.
      if (!this._sourcesContents) {
        this._sourcesContents = Object.create(null);
      }
      this._sourcesContents[util.toSetString(source)] = aSourceContent;
    } else if (this._sourcesContents) {
      // Remove the source file from the _sourcesContents map.
      // If the _sourcesContents map is empty, set the property to null.
      delete this._sourcesContents[util.toSetString(source)];
      if (Object.keys(this._sourcesContents).length === 0) {
        this._sourcesContents = null;
      }
    }
  };

/**
 * Applies the mappings of a sub-source-map for a specific source file to the
 * source map being generated. Each mapping to the supplied source file is
 * rewritten using the supplied source map. Note: The resolution for the
 * resulting mappings is the minimium of this map and the supplied map.
 *
 * @param aSourceMapConsumer The source map to be applied.
 * @param aSourceFile Optional. The filename of the source file.
 *        If omitted, SourceMapConsumer's file property will be used.
 * @param aSourceMapPath Optional. The dirname of the path to the source map
 *        to be applied. If relative, it is relative to the SourceMapConsumer.
 *        This parameter is needed when the two source maps aren't in the same
 *        directory, and the source map to be applied contains relative source
 *        paths. If so, those relative source paths need to be rewritten
 *        relative to the SourceMapGenerator.
 */
SourceMapGenerator.prototype.applySourceMap =
  function SourceMapGenerator_applySourceMap(aSourceMapConsumer, aSourceFile, aSourceMapPath) {
    var sourceFile = aSourceFile;
    // If aSourceFile is omitted, we will use the file property of the SourceMap
    if (aSourceFile == null) {
      if (aSourceMapConsumer.file == null) {
        throw new Error(
          'SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, ' +
          'or the source map\'s "file" property. Both were omitted.'
        );
      }
      sourceFile = aSourceMapConsumer.file;
    }
    var sourceRoot = this._sourceRoot;
    // Make "sourceFile" relative if an absolute Url is passed.
    if (sourceRoot != null) {
      sourceFile = util.relative(sourceRoot, sourceFile);
    }
    // Applying the SourceMap can add and remove items from the sources and
    // the names array.
    var newSources = new ArraySet();
    var newNames = new ArraySet();

    // Find mappings for the "sourceFile"
    this._mappings.unsortedForEach(function (mapping) {
      if (mapping.source === sourceFile && mapping.originalLine != null) {
        // Check if it can be mapped by the source map, then update the mapping.
        var original = aSourceMapConsumer.originalPositionFor({
          line: mapping.originalLine,
          column: mapping.originalColumn
        });
        if (original.source != null) {
          // Copy mapping
          mapping.source = original.source;
          if (aSourceMapPath != null) {
            mapping.source = util.join(aSourceMapPath, mapping.source)
          }
          if (sourceRoot != null) {
            mapping.source = util.relative(sourceRoot, mapping.source);
          }
          mapping.originalLine = original.line;
          mapping.originalColumn = original.column;
          if (original.name != null) {
            mapping.name = original.name;
          }
        }
      }

      var source = mapping.source;
      if (source != null && !newSources.has(source)) {
        newSources.add(source);
      }

      var name = mapping.name;
      if (name != null && !newNames.has(name)) {
        newNames.add(name);
      }

    }, this);
    this._sources = newSources;
    this._names = newNames;

    // Copy sourcesContents of applied map.
    aSourceMapConsumer.sources.forEach(function (sourceFile) {
      var content = aSourceMapConsumer.sourceContentFor(sourceFile);
      if (content != null) {
        if (aSourceMapPath != null) {
          sourceFile = util.join(aSourceMapPath, sourceFile);
        }
        if (sourceRoot != null) {
          sourceFile = util.relative(sourceRoot, sourceFile);
        }
        this.setSourceContent(sourceFile, content);
      }
    }, this);
  };

/**
 * A mapping can have one of the three levels of data:
 *
 *   1. Just the generated position.
 *   2. The Generated position, original position, and original source.
 *   3. Generated and original position, original source, as well as a name
 *      token.
 *
 * To maintain consistency, we validate that any new mapping being added falls
 * in to one of these categories.
 */
SourceMapGenerator.prototype._validateMapping =
  function SourceMapGenerator_validateMapping(aGenerated, aOriginal, aSource,
                                              aName) {
    // When aOriginal is truthy but has empty values for .line and .column,
    // it is most likely a programmer error. In this case we throw a very
    // specific error message to try to guide them the right way.
    // For example: https://github.com/Polymer/polymer-bundler/pull/519
    if (aOriginal && typeof aOriginal.line !== 'number' && typeof aOriginal.column !== 'number') {
        throw new Error(
            'original.line and original.column are not numbers -- you probably meant to omit ' +
            'the original mapping entirely and only map the generated position. If so, pass ' +
            'null for the original mapping instead of an object with empty or null values.'
        );
    }

    if (aGenerated && 'line' in aGenerated && 'column' in aGenerated
        && aGenerated.line > 0 && aGenerated.column >= 0
        && !aOriginal && !aSource && !aName) {
      // Case 1.
      return;
    }
    else if (aGenerated && 'line' in aGenerated && 'column' in aGenerated
             && aOriginal && 'line' in aOriginal && 'column' in aOriginal
             && aGenerated.line > 0 && aGenerated.column >= 0
             && aOriginal.line > 0 && aOriginal.column >= 0
             && aSource) {
      // Cases 2 and 3.
      return;
    }
    else {
      throw new Error('Invalid mapping: ' + JSON.stringify({
        generated: aGenerated,
        source: aSource,
        original: aOriginal,
        name: aName
      }));
    }
  };

/**
 * Serialize the accumulated mappings in to the stream of base 64 VLQs
 * specified by the source map format.
 */
SourceMapGenerator.prototype._serializeMappings =
  function SourceMapGenerator_serializeMappings() {
    var previousGeneratedColumn = 0;
    var previousGeneratedLine = 1;
    var previousOriginalColumn = 0;
    var previousOriginalLine = 0;
    var previousName = 0;
    var previousSource = 0;
    var result = '';
    var next;
    var mapping;
    var nameIdx;
    var sourceIdx;

    var mappings = this._mappings.toArray();
    for (var i = 0, len = mappings.length; i < len; i++) {
      mapping = mappings[i];
      next = ''

      if (mapping.generatedLine !== previousGeneratedLine) {
        previousGeneratedColumn = 0;
        while (mapping.generatedLine !== previousGeneratedLine) {
          next += ';';
          previousGeneratedLine++;
        }
      }
      else {
        if (i > 0) {
          if (!util.compareByGeneratedPositionsInflated(mapping, mappings[i - 1])) {
            continue;
          }
          next += ',';
        }
      }

      next += base64VLQ.encode(mapping.generatedColumn
                                 - previousGeneratedColumn);
      previousGeneratedColumn = mapping.generatedColumn;

      if (mapping.source != null) {
        sourceIdx = this._sources.indexOf(mapping.source);
        next += base64VLQ.encode(sourceIdx - previousSource);
        previousSource = sourceIdx;

        // lines are stored 0-based in SourceMap spec version 3
        next += base64VLQ.encode(mapping.originalLine - 1
                                   - previousOriginalLine);
        previousOriginalLine = mapping.originalLine - 1;

        next += base64VLQ.encode(mapping.originalColumn
                                   - previousOriginalColumn);
        previousOriginalColumn = mapping.originalColumn;

        if (mapping.name != null) {
          nameIdx = this._names.indexOf(mapping.name);
          next += base64VLQ.encode(nameIdx - previousName);
          previousName = nameIdx;
        }
      }

      result += next;
    }

    return result;
  };

SourceMapGenerator.prototype._generateSourcesContent =
  function SourceMapGenerator_generateSourcesContent(aSources, aSourceRoot) {
    return aSources.map(function (source) {
      if (!this._sourcesContents) {
        return null;
      }
      if (aSourceRoot != null) {
        source = util.relative(aSourceRoot, source);
      }
      var key = util.toSetString(source);
      return Object.prototype.hasOwnProperty.call(this._sourcesContents, key)
        ? this._sourcesContents[key]
        : null;
    }, this);
  };

/**
 * Externalize the source map.
 */
SourceMapGenerator.prototype.toJSON =
  function SourceMapGenerator_toJSON() {
    var map = {
      version: this._version,
      sources: this._sources.toArray(),
      names: this._names.toArray(),
      mappings: this._serializeMappings()
    };
    if (this._file != null) {
      map.file = this._file;
    }
    if (this._sourceRoot != null) {
      map.sourceRoot = this._sourceRoot;
    }
    if (this._sourcesContents) {
      map.sourcesContent = this._generateSourcesContent(map.sources, map.sourceRoot);
    }

    return map;
  };

/**
 * Render the source map being generated to a string.
 */
SourceMapGenerator.prototype.toString =
  function SourceMapGenerator_toString() {
    return JSON.stringify(this.toJSON());
  };

exports.SourceMapGenerator = SourceMapGenerator;


/***/ }),
/* 331 */
/***/ (function(module, exports, __webpack_require__) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 *
 * Based on the Base 64 VLQ implementation in Closure Compiler:
 * https://code.google.com/p/closure-compiler/source/browse/trunk/src/com/google/debugging/sourcemap/Base64VLQ.java
 *
 * Copyright 2011 The Closure Compiler Authors. All rights reserved.
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are
 * met:
 *
 *  * Redistributions of source code must retain the above copyright
 *    notice, this list of conditions and the following disclaimer.
 *  * Redistributions in binary form must reproduce the above
 *    copyright notice, this list of conditions and the following
 *    disclaimer in the documentation and/or other materials provided
 *    with the distribution.
 *  * Neither the name of Google Inc. nor the names of its
 *    contributors may be used to endorse or promote products derived
 *    from this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

var base64 = __webpack_require__(467);

// A single base 64 digit can contain 6 bits of data. For the base 64 variable
// length quantities we use in the source map spec, the first bit is the sign,
// the next four bits are the actual value, and the 6th bit is the
// continuation bit. The continuation bit tells us whether there are more
// digits in this value following this digit.
//
//   Continuation
//   |    Sign
//   |    |
//   V    V
//   101011

var VLQ_BASE_SHIFT = 5;

// binary: 100000
var VLQ_BASE = 1 << VLQ_BASE_SHIFT;

// binary: 011111
var VLQ_BASE_MASK = VLQ_BASE - 1;

// binary: 100000
var VLQ_CONTINUATION_BIT = VLQ_BASE;

/**
 * Converts from a two-complement value to a value where the sign bit is
 * placed in the least significant bit.  For example, as decimals:
 *   1 becomes 2 (10 binary), -1 becomes 3 (11 binary)
 *   2 becomes 4 (100 binary), -2 becomes 5 (101 binary)
 */
function toVLQSigned(aValue) {
  return aValue < 0
    ? ((-aValue) << 1) + 1
    : (aValue << 1) + 0;
}

/**
 * Converts to a two-complement value from a value where the sign bit is
 * placed in the least significant bit.  For example, as decimals:
 *   2 (10 binary) becomes 1, 3 (11 binary) becomes -1
 *   4 (100 binary) becomes 2, 5 (101 binary) becomes -2
 */
function fromVLQSigned(aValue) {
  var isNegative = (aValue & 1) === 1;
  var shifted = aValue >> 1;
  return isNegative
    ? -shifted
    : shifted;
}

/**
 * Returns the base 64 VLQ encoded value.
 */
exports.encode = function base64VLQ_encode(aValue) {
  var encoded = "";
  var digit;

  var vlq = toVLQSigned(aValue);

  do {
    digit = vlq & VLQ_BASE_MASK;
    vlq >>>= VLQ_BASE_SHIFT;
    if (vlq > 0) {
      // There are still more digits in this value, so we must make sure the
      // continuation bit is marked.
      digit |= VLQ_CONTINUATION_BIT;
    }
    encoded += base64.encode(digit);
  } while (vlq > 0);

  return encoded;
};

/**
 * Decodes the next base 64 VLQ value from the given string and returns the
 * value and the rest of the string via the out parameter.
 */
exports.decode = function base64VLQ_decode(aStr, aIndex, aOutParam) {
  var strLen = aStr.length;
  var result = 0;
  var shift = 0;
  var continuation, digit;

  do {
    if (aIndex >= strLen) {
      throw new Error("Expected more digits in base 64 VLQ value.");
    }

    digit = base64.decode(aStr.charCodeAt(aIndex++));
    if (digit === -1) {
      throw new Error("Invalid base64 digit: " + aStr.charAt(aIndex - 1));
    }

    continuation = !!(digit & VLQ_CONTINUATION_BIT);
    digit &= VLQ_BASE_MASK;
    result = result + (digit << shift);
    shift += VLQ_BASE_SHIFT;
  } while (continuation);

  aOutParam.value = fromVLQSigned(result);
  aOutParam.rest = aIndex;
};


/***/ }),
/* 332 */
/***/ (function(module, exports, __webpack_require__) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

var util = __webpack_require__(141);
var has = Object.prototype.hasOwnProperty;
var hasNativeMap = typeof Map !== "undefined";

/**
 * A data structure which is a combination of an array and a set. Adding a new
 * member is O(1), testing for membership is O(1), and finding the index of an
 * element is O(1). Removing elements from the set is not supported. Only
 * strings are supported for membership.
 */
function ArraySet() {
  this._array = [];
  this._set = hasNativeMap ? new Map() : Object.create(null);
}

/**
 * Static method for creating ArraySet instances from an existing array.
 */
ArraySet.fromArray = function ArraySet_fromArray(aArray, aAllowDuplicates) {
  var set = new ArraySet();
  for (var i = 0, len = aArray.length; i < len; i++) {
    set.add(aArray[i], aAllowDuplicates);
  }
  return set;
};

/**
 * Return how many unique items are in this ArraySet. If duplicates have been
 * added, than those do not count towards the size.
 *
 * @returns Number
 */
ArraySet.prototype.size = function ArraySet_size() {
  return hasNativeMap ? this._set.size : Object.getOwnPropertyNames(this._set).length;
};

/**
 * Add the given string to this set.
 *
 * @param String aStr
 */
ArraySet.prototype.add = function ArraySet_add(aStr, aAllowDuplicates) {
  var sStr = hasNativeMap ? aStr : util.toSetString(aStr);
  var isDuplicate = hasNativeMap ? this.has(aStr) : has.call(this._set, sStr);
  var idx = this._array.length;
  if (!isDuplicate || aAllowDuplicates) {
    this._array.push(aStr);
  }
  if (!isDuplicate) {
    if (hasNativeMap) {
      this._set.set(aStr, idx);
    } else {
      this._set[sStr] = idx;
    }
  }
};

/**
 * Is the given string a member of this set?
 *
 * @param String aStr
 */
ArraySet.prototype.has = function ArraySet_has(aStr) {
  if (hasNativeMap) {
    return this._set.has(aStr);
  } else {
    var sStr = util.toSetString(aStr);
    return has.call(this._set, sStr);
  }
};

/**
 * What is the index of the given string in the array?
 *
 * @param String aStr
 */
ArraySet.prototype.indexOf = function ArraySet_indexOf(aStr) {
  if (hasNativeMap) {
    var idx = this._set.get(aStr);
    if (idx >= 0) {
        return idx;
    }
  } else {
    var sStr = util.toSetString(aStr);
    if (has.call(this._set, sStr)) {
      return this._set[sStr];
    }
  }

  throw new Error('"' + aStr + '" is not in the set.');
};

/**
 * What is the element at the given index?
 *
 * @param Number aIdx
 */
ArraySet.prototype.at = function ArraySet_at(aIdx) {
  if (aIdx >= 0 && aIdx < this._array.length) {
    return this._array[aIdx];
  }
  throw new Error('No element indexed by ' + aIdx);
};

/**
 * Returns the array representation of this set (which has the proper indices
 * indicated by indexOf). Note that this is a copy of the internal array used
 * for storing the members so that no one can mess with internal state.
 */
ArraySet.prototype.toArray = function ArraySet_toArray() {
  return this._array.slice();
};

exports.ArraySet = ArraySet;


/***/ }),
/* 333 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Represents a deprecated node.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
const node_1 = __webpack_require__(107);
class TwingNodeDeprecated extends node_1.TwingNode {
    constructor(expr, lineno, columnno, tag = null) {
        super(new Map([['expr', expr]]), new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.DEPRECATED;
    }
    compile(compiler) {
        compiler.addDebugInfo(this);
        let expr = this.getNode('expr');
        if (expr.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) {
            compiler
                .write('console.error(')
                .subcompile(expr);
        }
        else {
            let varName = compiler.getVarName();
            compiler
                .write(`let ${varName} = `)
                .subcompile(expr)
                .raw(';\n')
                .write(`console.error(${varName}`);
        }
        compiler
            .raw(' + ')
            .string(` ("${this.getTemplateName()}" at line ${this.getTemplateLine()})`)
            .raw(');\n');
    }
}
exports.TwingNodeDeprecated = TwingNodeDeprecated;


/***/ }),
/* 334 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function _phpCastString(value) {
  // original by: Rafał Kukawski
  //   example 1: _phpCastString(true)
  //   returns 1: '1'
  //   example 2: _phpCastString(false)
  //   returns 2: ''
  //   example 3: _phpCastString('foo')
  //   returns 3: 'foo'
  //   example 4: _phpCastString(0/0)
  //   returns 4: 'NAN'
  //   example 5: _phpCastString(1/0)
  //   returns 5: 'INF'
  //   example 6: _phpCastString(-1/0)
  //   returns 6: '-INF'
  //   example 7: _phpCastString(null)
  //   returns 7: ''
  //   example 8: _phpCastString(undefined)
  //   returns 8: ''
  //   example 9: _phpCastString([])
  //   returns 9: 'Array'
  //   example 10: _phpCastString({})
  //   returns 10: 'Object'
  //   example 11: _phpCastString(0)
  //   returns 11: '0'
  //   example 12: _phpCastString(1)
  //   returns 12: '1'
  //   example 13: _phpCastString(3.14)
  //   returns 13: '3.14'

  var type = typeof value === 'undefined' ? 'undefined' : _typeof(value);

  switch (type) {
    case 'boolean':
      return value ? '1' : '';
    case 'string':
      return value;
    case 'number':
      if (isNaN(value)) {
        return 'NAN';
      }

      if (!isFinite(value)) {
        return (value < 0 ? '-' : '') + 'INF';
      }

      return value + '';
    case 'undefined':
      return '';
    case 'object':
      if (Array.isArray(value)) {
        return 'Array';
      }

      if (value !== null) {
        return 'Object';
      }

      return '';
    case 'function':
    // fall through
    default:
      throw new Error('Unsupported value type');
  }
};
//# sourceMappingURL=_phpCastString.js.map

/***/ }),
/* 335 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function mt_rand(min, max) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/mt_rand/
  // original by: Onno Marsman (https://twitter.com/onnomarsman)
  // improved by: Brett Zamir (http://brett-zamir.me)
  //    input by: Kongo
  //   example 1: mt_rand(1, 1)
  //   returns 1: 1

  var argc = arguments.length;
  if (argc === 0) {
    min = 0;
    max = 2147483647;
  } else if (argc === 1) {
    throw new Error('Warning: mt_rand() expects exactly 2 parameters, 1 given');
  } else {
    min = parseInt(min, 10);
    max = parseInt(max, 10);
  }
  return Math.floor(Math.random() * (max - min + 1)) + min;
};
//# sourceMappingURL=mt_rand.js.map

/***/ }),
/* 336 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/*!
 * is-plain-object <https://github.com/jonschlinkert/is-plain-object>
 *
 * Copyright (c) 2014-2017, Jon Schlinkert.
 * Released under the MIT License.
 */



var isObject = __webpack_require__(151);

function isObjectObject(o) {
  return isObject(o) === true
    && Object.prototype.toString.call(o) === '[object Object]';
}

module.exports = function isPlainObject(o) {
  var ctor,prot;

  if (isObjectObject(o) === false) return false;

  // If has modified constructor
  ctor = o.constructor;
  if (typeof ctor !== 'function') return false;

  // If has modified prototype
  prot = ctor.prototype;
  if (isObjectObject(prot) === false) return false;

  // If constructor does not have an Object-specific method
  if (prot.hasOwnProperty('isPrototypeOf') === false) {
    return false;
  }

  // Most likely a plain Object
  return true;
};


/***/ }),
/* 337 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function ltrim(str, charlist) {
  //  discuss at: http://locutus.io/php/ltrim/
  // original by: Kevin van Zonneveld (http://kvz.io)
  //    input by: Erkekjetter
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  //   example 1: ltrim('    Kevin van Zonneveld    ')
  //   returns 1: 'Kevin van Zonneveld    '

  charlist = !charlist ? ' \\s\xA0' : (charlist + '').replace(/([[\]().?/*{}+$^:])/g, '$1');

  var re = new RegExp('^[' + charlist + ']+', 'g');

  return (str + '').replace(re, '');
};
//# sourceMappingURL=ltrim.js.map

/***/ }),
/* 338 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function rawurlencode(str) {
  //       discuss at: http://locutus.io/php/rawurlencode/
  //      original by: Brett Zamir (http://brett-zamir.me)
  //         input by: travc
  //         input by: Brett Zamir (http://brett-zamir.me)
  //         input by: Michael Grier
  //         input by: Ratheous
  //      bugfixed by: Kevin van Zonneveld (http://kvz.io)
  //      bugfixed by: Brett Zamir (http://brett-zamir.me)
  //      bugfixed by: Joris
  // reimplemented by: Brett Zamir (http://brett-zamir.me)
  // reimplemented by: Brett Zamir (http://brett-zamir.me)
  //           note 1: This reflects PHP 5.3/6.0+ behavior
  //           note 1: Please be aware that this function expects \
  //           note 1: to encode into UTF-8 encoded strings, as found on
  //           note 1: pages served as UTF-8
  //        example 1: rawurlencode('Kevin van Zonneveld!')
  //        returns 1: 'Kevin%20van%20Zonneveld%21'
  //        example 2: rawurlencode('http://kvz.io/')
  //        returns 2: 'http%3A%2F%2Fkvz.io%2F'
  //        example 3: rawurlencode('http://www.google.nl/search?q=Locutus&ie=utf-8')
  //        returns 3: 'http%3A%2F%2Fwww.google.nl%2Fsearch%3Fq%3DLocutus%26ie%3Dutf-8'

  str = str + '';

  // Tilde should be allowed unescaped in future versions of PHP (as reflected below),
  // but if you want to reflect current
  // PHP behavior, you would need to add ".replace(/~/g, '%7E');" to the following.
  return encodeURIComponent(str).replace(/!/g, '%21').replace(/'/g, '%27').replace(/\(/g, '%28').replace(/\)/g, '%29').replace(/\*/g, '%2A');
};
//# sourceMappingURL=rawurlencode.js.map

/***/ }),
/* 339 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_parser_1 = __webpack_require__(184);
const syntax_1 = __webpack_require__(112);
const node_1 = __webpack_require__(107);
const token_1 = __webpack_require__(109);
const text_1 = __webpack_require__(340);
const print_1 = __webpack_require__(124);
const body_1 = __webpack_require__(157);
const module_1 = __webpack_require__(341);
const node_traverser_1 = __webpack_require__(205);
const token_parser_1 = __webpack_require__(111);
const first_1 = __webpack_require__(203);
const push_1 = __webpack_require__(137);
const comment_1 = __webpack_require__(504);
const ctype_space_1 = __webpack_require__(342);
const mt_rand = __webpack_require__(335);
const sha256 = __webpack_require__(149);
const hex = __webpack_require__(150);
class TwingParserStackEntry {
    constructor(stream, parent = null, blocks, blockStack, macros, importedSymbols, traits, embeddedTemplates) {
        this.stream = stream;
        this.parent = parent;
        this.blocks = blocks;
        this.blockStack = blockStack;
        this.macros = macros;
        this.importedSymbols = importedSymbols;
        this.traits = traits;
        this.embeddedTemplates = embeddedTemplates;
    }
}
class TwingParser {
    constructor(env) {
        this.stack = [];
        this.handlers = null;
        this.expressionParser = null;
        this.embeddedTemplates = [];
        this.varNameSalt = 0;
        this.env = env;
    }
    getVarName(prefix = '__internal_') {
        return `${prefix}${hex.stringify(sha256('TwingParser::getVarName' + this.stream.getSourceContext().getCode() + this.varNameSalt++))}`;
    }
    parse(stream, test = null, dropNeedle = false) {
        this.stack.push(new TwingParserStackEntry(this.stream, this.parent, this.blocks, this.blockStack, this.macros, this.importedSymbols, this.traits, this.embeddedTemplates));
        // tag handlers
        if (this.handlers === null) {
            this.handlers = new Map();
            for (let handler of this.env.getTokenParsers()) {
                handler.setParser(this);
                this.handlers.set(handler.getTag(), handler);
            }
        }
        // node visitors
        if (!this.visitors) {
            this.visitors = this.env.getNodeVisitors();
        }
        if (this.expressionParser === null) {
            this.expressionParser = new expression_parser_1.TwingExpressionParser(this, this.env);
        }
        this.stream = stream;
        this.parent = null;
        this.blocks = new Map();
        this.macros = new Map();
        this.traits = new Map();
        this.blockStack = [];
        this.importedSymbols = [new Map()];
        this.embeddedTemplates = [];
        this.varNameSalt = 0;
        let body;
        try {
            body = this.subparse(test, dropNeedle);
            if (this.parent !== null && (body = this.filterBodyNodes(body)) === null) {
                body = new node_1.TwingNode();
            }
        }
        catch (e) {
            if (e instanceof syntax_1.TwingErrorSyntax) {
                if (!e.getSourceContext()) {
                    e.setSourceContext(this.stream.getSourceContext());
                }
            }
            throw e;
        }
        let nodes = new Map();
        nodes.set(0, body);
        let node = new module_1.TwingNodeModule(new body_1.TwingNodeBody(nodes), this.parent, new node_1.TwingNode(this.blocks), new node_1.TwingNode(this.macros), new node_1.TwingNode(this.traits), this.embeddedTemplates, stream.getSourceContext());
        let traverser = new node_traverser_1.TwingNodeTraverser(this.env, this.visitors);
        node = traverser.traverse(node);
        // restore previous stack so previous parse() call can resume working
        let key;
        let stack = this.stack.pop();
        this.stream = stack.stream;
        this.parent = stack.parent;
        this.blocks = stack.blocks;
        this.blockStack = stack.blockStack;
        this.macros = stack.macros;
        this.importedSymbols = stack.importedSymbols;
        this.traits = stack.traits;
        this.embeddedTemplates = stack.embeddedTemplates;
        return node;
    }
    getExpressionParser() {
        return this.expressionParser;
    }
    getParent() {
        return this.parent;
    }
    setParent(parent) {
        this.parent = parent;
    }
    subparse(test, dropNeedle = false) {
        let lineno = this.getCurrentToken().getLine();
        let rv = new Map();
        let i = 0;
        let token;
        while (!this.stream.isEOF()) {
            switch (this.getCurrentToken().getType()) {
                case token_1.TwingToken.TEXT_TYPE:
                    token = this.stream.next();
                    rv.set(i++, new text_1.TwingNodeText(token.getValue(), token.getLine(), token.getColumn()));
                    break;
                case token_1.TwingToken.VAR_START_TYPE:
                    token = this.stream.next();
                    let expression = this.expressionParser.parseExpression();
                    this.stream.expect(token_1.TwingToken.VAR_END_TYPE);
                    rv.set(i++, new print_1.TwingNodePrint(expression, token.getLine(), token.getColumn()));
                    break;
                case token_1.TwingToken.BLOCK_START_TYPE:
                    this.stream.next();
                    token = this.getCurrentToken();
                    if (token.getType() !== token_1.TwingToken.NAME_TYPE) {
                        throw new syntax_1.TwingErrorSyntax('A block must start with a tag name.', token.getLine(), this.stream.getSourceContext());
                    }
                    if (test !== null && test[1](token)) {
                        if (dropNeedle) {
                            this.stream.next();
                        }
                        if (rv.size === 1) {
                            return first_1.first(rv);
                        }
                        return new node_1.TwingNode(rv, new Map(), lineno);
                    }
                    if (!this.handlers.has(token.getValue())) {
                        let e;
                        if (test !== null) {
                            e = new syntax_1.TwingErrorSyntax(`Unexpected "${token.getValue()}" tag`, token.getLine(), this.stream.getSourceContext());
                            if (Array.isArray(test) && (test.length > 1) && (test[0] instanceof token_parser_1.TwingTokenParser)) {
                                e.appendMessage(` (expecting closing tag for the "${test[0].getTag()}" tag defined near line ${lineno}).`);
                            }
                        }
                        else {
                            e = new syntax_1.TwingErrorSyntax(`Unknown "${token.getValue()}" tag.`, token.getLine(), this.stream.getSourceContext());
                            e.addSuggestions(token.getValue(), Array.from(this.env.getTags().keys()));
                        }
                        throw e;
                    }
                    this.stream.next();
                    let subparser = this.handlers.get(token.getValue());
                    let node = subparser.parse(token);
                    if (node !== null) {
                        rv.set(i++, node);
                    }
                    break;
                case token_1.TwingToken.COMMENT_START_TYPE:
                    this.stream.next();
                    token = this.stream.expect(token_1.TwingToken.TEXT_TYPE);
                    this.stream.expect(token_1.TwingToken.COMMENT_END_TYPE);
                    rv.set(i++, new comment_1.TwingNodeComment(token.getValue(), token.getLine(), token.getColumn()));
                    break;
                default:
                    throw new syntax_1.TwingErrorSyntax('Lexer or parser ended up in unsupported state.', this.getCurrentToken().getLine(), this.stream.getSourceContext());
            }
        }
        if (rv.size === 1) {
            return first_1.first(rv);
        }
        return new node_1.TwingNode(rv, new Map(), lineno);
    }
    getBlockStack() {
        return this.blockStack;
    }
    peekBlockStack() {
        return this.blockStack[this.blockStack.length - 1];
    }
    popBlockStack() {
        this.blockStack.pop();
    }
    pushBlockStack(name) {
        this.blockStack.push(name);
    }
    hasBlock(name) {
        return this.blocks.has(name);
    }
    getBlock(name) {
        return this.blocks.get(name);
    }
    setBlock(name, value) {
        let bodyNodes = new Map();
        bodyNodes.set(0, value);
        this.blocks.set(name, new body_1.TwingNodeBody(bodyNodes, new Map(), value.getTemplateLine()));
    }
    addTrait(trait) {
        push_1.push(this.traits, trait);
    }
    hasTraits() {
        return this.traits.size > 0;
    }
    embedTemplate(template) {
        template.setIndex(mt_rand());
        this.embeddedTemplates.push(template);
    }
    /**
     * @return {TwingToken}
     */
    getCurrentToken() {
        return this.stream.getCurrent();
    }
    /**
     *
     * @return {TwingTokenStream}
     */
    getStream() {
        return this.stream;
    }
    addImportedSymbol(type, alias, name = null, node = null) {
        let localScope = this.importedSymbols[0];
        if (!localScope.has(type)) {
            localScope.set(type, new Map());
        }
        let localScopeType = localScope.get(type);
        localScopeType.set(alias, { name: name, node: node });
    }
    getImportedSymbol(type, alias) {
        let result = null;
        this.importedSymbols.forEach(function (importedSymbol) {
            if (importedSymbol.has(type)) {
                let importedSymbolType = importedSymbol.get(type);
                if (importedSymbolType.has(alias)) {
                    result = importedSymbolType.get(alias);
                }
            }
        });
        return result;
    }
    hasMacro(name) {
        return this.macros.has(name);
    }
    setMacro(name, node) {
        this.macros.set(name, node);
    }
    isMainScope() {
        return this.importedSymbols.length === 1;
    }
    pushLocalScope() {
        this.importedSymbols.unshift(new Map());
    }
    popLocalScope() {
        this.importedSymbols.shift();
    }
    /**
     *
     * @param node
     * @param nested {boolean}
     * @returns {TwingNode}
     */
    filterBodyNodes(node, nested = false) {
        // check that the body does not contain non-empty output nodes
        if ((node.getType() === node_1.TwingNodeType.TEXT && !ctype_space_1.ctypeSpace(node.getAttribute('data'))) ||
            ((node.getType() !== node_1.TwingNodeType.TEXT) && (node.getType() !== node_1.TwingNodeType.BLOCK_REFERENCE) && (node.TwingNodeOutputInterfaceImpl) && (node.getType() !== node_1.TwingNodeType.SPACELESS))) {
            let nodeData = node.getAttribute('data');
            if (nodeData.indexOf(String.fromCharCode(0xEF, 0xBB, 0xBF)) > -1) {
                let trailingData = nodeData.substring(3);
                if (trailingData === '' || ctype_space_1.ctypeSpace(trailingData)) {
                    // bypass empty nodes starting with a BOM
                    return null;
                }
            }
            throw new syntax_1.TwingErrorSyntax(`A template that extends another one cannot include content outside Twig blocks. Did you forget to put the content inside a {% block %} tag?`, node.getTemplateLine(), this.stream.getSourceContext());
        }
        // bypass nodes that "capture" the output
        if (node.TwingNodeCaptureInterfaceImpl) {
            // a "block" tag in such a node will serve as a block definition AND be displayed in place as well
            return node;
        }
        // to be removed completely in Twig 3.0
        if (!nested && (node.getType() === node_1.TwingNodeType.SPACELESS)) {
            console.error(`Using the spaceless tag at the root level of a child template in "${this.stream.getSourceContext().getName()}" at line ${node.getTemplateLine()} is deprecated since Twig 2.5.0 and will become a syntax error in Twig 3.0.`);
        }
        // "block" tags that are not captured (see above) are only used for defining
        // the content of the block. In such a case, nesting it does not work as
        // expected as the definition is not part of the default template code flow.
        if (nested && (node.getType() === node_1.TwingNodeType.BLOCK_REFERENCE)) {
            console.error(`Nesting a block definition under a non-capturing node in "${this.stream.getSourceContext().getName()}" at line ${node.getTemplateLine()} is deprecated since Twig 2.5.0 and will become a syntax error in Twig 3.0.`);
            return null;
        }
        if (node.TwingNodeOutputInterfaceImpl && (node.getType() !== node_1.TwingNodeType.SPACELESS)) {
            return null;
        }
        // here, nested means "being at the root level of a child template"
        // we need to discard the wrapping "TwingNode" for the "body" node
        nested = nested || (node.getType() !== null);
        for (let [k, n] of node.getNodes()) {
            if (n !== null && (this.filterBodyNodes(n, nested) === null)) {
                node.removeNode(k);
            }
        }
        return node;
    }
}
exports.TwingParser = TwingParser;


/***/ }),
/* 340 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeText extends node_1.TwingNode {
    constructor(data, lineno, columnno) {
        super(new Map(), new Map([['data', data]]), lineno, columnno);
        this.type = node_1.TwingNodeType.TEXT;
        this.TwingNodeOutputInterfaceImpl = this;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .addSourceMapEnter(this)
            .write('Runtime.echo(')
            .string(this.getAttribute('data'))
            .raw(");\n")
            .addSourceMapLeave();
    }
}
exports.TwingNodeText = TwingNodeText;


/***/ }),
/* 341 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {
Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Represents a module node.
 */
class TwingNodeModule extends node_1.TwingNode {
    constructor(body, parent, blocks, macros, traits, embeddedTemplates, source) {
        let nodes = new Map();
        nodes.set('body', body);
        nodes.set('blocks', blocks);
        nodes.set('macros', macros);
        nodes.set('traits', traits);
        nodes.set('display_start', new node_1.TwingNode());
        nodes.set('display_end', new node_1.TwingNode());
        nodes.set('constructor_start', new node_1.TwingNode());
        nodes.set('constructor_end', new node_1.TwingNode());
        nodes.set('class_end', new node_1.TwingNode());
        if (parent !== null) {
            nodes.set('parent', parent);
        }
        // embedded templates are set as attributes so that they are only visited once by the visitors
        let attributes = new Map();
        attributes.set('index', null);
        attributes.set('embedded_templates', embeddedTemplates);
        super(nodes, attributes, 1, 1);
        this.type = node_1.TwingNodeType.MODULE;
        this.source = source;
        // populate the template name of all node children
        this.setTemplateName(this.source.getName());
    }
    setIndex(index) {
        this.setAttribute('index', index);
    }
    compile(compiler) {
        if (!this.getAttribute('index')) {
            compiler
                .write('module.exports = (Runtime) => {\n')
                .indent()
                .write('let templates = {};\n');
        }
        this.compileTemplate(compiler);
        for (let template of this.getAttribute('embedded_templates')) {
            compiler.subcompile(template);
        }
        if (!this.getAttribute('index')) {
            compiler
                .write('return templates;\n')
                .outdent()
                .write('};');
        }
    }
    compileTemplate(compiler) {
        this.compileClassHeader(compiler);
        this.compileConstructor(compiler);
        this.compileGetParent(compiler);
        this.compileDisplay(compiler);
        compiler.subcompile(this.getNode('blocks'));
        this.compileMacros(compiler);
        this.compileGetTemplateName(compiler);
        this.compileIsTraitable(compiler);
        this.compileDebugInfo(compiler);
        this.compileGetSourceContext(compiler);
        this.compileClassfooter(compiler);
    }
    compileGetParent(compiler) {
        if (!this.hasNode('parent')) {
            return;
        }
        let parent = this.getNode('parent');
        compiler
            .write("doGetParent(context) {\n")
            .indent()
            .addDebugInfo(parent)
            .write('return ');
        if (parent.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) {
            compiler.subcompile(parent);
        }
        else {
            compiler
                .raw('this.loadTemplate(')
                .subcompile(parent)
                .raw(', ')
                .repr(this.source.getName())
                .raw(', ')
                .repr(parent.getTemplateLine())
                .raw(')');
        }
        compiler
            .raw(";\n")
            .outdent()
            .write("}\n\n");
    }
    compileClassHeader(compiler) {
        let templateClass = compiler.getEnvironment().getTemplateClass(this.source.getName(), this.getAttribute('index'));
        compiler
            .write("\n\n")
            .write('/* ' + this.source.getName() + ' */\n')
            .write('templates.')
            .raw(`${templateClass} = class ${templateClass} extends Runtime.${compiler.getEnvironment().getBaseTemplateClass()} `)
            .raw('{\n')
            .indent();
    }
    compileConstructor(compiler) {
        compiler
            .write('constructor(env) {\n')
            .indent()
            .subcompile(this.getNode('constructor_start'))
            .write('super(env);\n\n')
            .write("this.source = this.getSourceContext();\n\n");
        // parent
        if (!this.hasNode('parent')) {
            compiler.write("this.parent = false;\n\n");
        }
        let countTraits = this.getNode('traits').getNodes().size;
        if (countTraits) {
            // traits
            for (let [i, trait] of this.getNode('traits').getNodes()) {
                let node = trait.getNode('template');
                compiler
                    .write(`let _trait_${i} = this.loadTemplate(`)
                    .subcompile(node)
                    .raw(', ')
                    .repr(node.getTemplateName())
                    .raw(', ')
                    .repr(node.getTemplateLine())
                    .raw(");\n");
                compiler
                    .addDebugInfo(trait.getNode('template'))
                    .write(`if (!_trait_${i}.isTraitable()) {\n`)
                    .indent()
                    .write('throw new Runtime.TwingErrorRuntime(\'Template "+')
                    .subcompile(trait.getNode('template'))
                    .raw('+" cannot be used as a trait.\', ')
                    .repr(node.getTemplateLine())
                    .raw(", this.source);\n")
                    .outdent()
                    .write('}\n')
                    .write(`let _trait_${i}_blocks = Runtime.clone(_trait_${i}.getBlocks());\n\n`);
                for (let [key, value] of trait.getNode('targets').getNodes()) {
                    compiler
                        .write(`if (!_trait_${i}_blocks.has(`)
                        .string(key)
                        .raw(")) {\n")
                        .indent()
                        .write('throw new Runtime.TwingErrorRuntime(\'Block ')
                        .string(key)
                        .raw(' is not defined in trait ')
                        .subcompile(trait.getNode('template'))
                        .raw('.\', ')
                        .repr(value.getTemplateLine())
                        .raw(', this.source);\n')
                        .outdent()
                        .write('}\n\n')
                        .write(`_trait_${i}_blocks.set(`)
                        .subcompile(value)
                        .raw(`, _trait_${i}_blocks.get(`)
                        .string(key)
                        .raw(`)); _trait_${i}_blocks.delete(`)
                        .string(key)
                        .raw(');\n\n');
                }
            }
            if (countTraits > 1) {
                for (let i = 0; i < countTraits; ++i) {
                    compiler
                        .write(`this.traits = Runtime.merge(this.traits, _trait_${i}_blocks);\n`);
                }
            }
            else {
                compiler
                    .write("this.traits = Runtime.clone(_trait_0_blocks);\n\n");
            }
            compiler
                .write("this.blocks = Runtime.merge(this.traits, new Map([\n")
                .indent();
        }
        else {
            compiler
                .write("this.blocks = new Map([\n");
        }
        // blocks
        compiler
            .indent();
        let count = this.getNode('blocks').getNodes().size;
        for (let [name, node] of this.getNode('blocks').getNodes()) {
            count--;
            let safeName = name;
            const varValidator = __webpack_require__(139);
            if (!varValidator.isValid(name)) {
                safeName = Buffer.from(name).toString('hex');
            }
            compiler
                .write(`['${name}', [this, 'block_${safeName}']]`);
            if (count > 0) {
                compiler.raw(',');
            }
            compiler.raw('\n');
        }
        compiler
            .outdent()
            .write("])");
        if (countTraits) {
            compiler
                .write("\n")
                .outdent()
                .write(")");
        }
        compiler.raw(';\n');
        compiler
            .subcompile(this.getNode('constructor_end'))
            .outdent()
            .write('}\n\n');
    }
    compileMacros(compiler) {
        compiler.subcompile(this.getNode('macros'));
    }
    compileDisplay(compiler) {
        compiler
            .write("doDisplay(context, blocks = new Map()) {\n")
            .indent()
            .addSourceMapEnter(this)
            .subcompile(this.getNode('display_start'))
            .subcompile(this.getNode('body'));
        if (this.hasNode('parent')) {
            let parent = this.getNode('parent');
            compiler.addDebugInfo(parent);
            if (parent.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) {
                compiler
                    .write('this.parent = this.loadTemplate(')
                    .subcompile(parent)
                    .raw(', ')
                    .repr(this.source.getName())
                    .raw(', ')
                    .repr(parent.getTemplateLine())
                    .raw(");\n");
                compiler.write('this.parent');
            }
            else {
                compiler.write('this.getParent(context)');
            }
            compiler.raw(".display(context, Runtime.merge(this.blocks, blocks));\n");
        }
        compiler
            .subcompile(this.getNode('display_end'))
            .addSourceMapLeave()
            .outdent()
            .write("}\n\n");
    }
    compileGetTemplateName(compiler) {
        compiler
            .write("getTemplateName() {\n")
            .indent()
            .write('return ')
            .repr(this.source.getName())
            .raw(";\n")
            .outdent()
            .write("}\n\n");
    }
    compileIsTraitable(compiler) {
        // A template can be used as a trait if:
        //   * it has no parent
        //   * it has no macros
        //   * it has no body
        //
        // Put another way, a template can be used as a trait if it
        // only contains blocks and use statements.
        let traitable = !this.hasNode('parent') && (this.getNode('macros').getNodes().size === 0);
        if (traitable) {
            let nodes;
            if (this.getNode('body').getType() === node_1.TwingNodeType.BODY) {
                nodes = this.getNode('body').getNode(0);
            }
            else {
                nodes = this.getNode('body');
            }
            if (!nodes.getNodes().size) {
                let n = new Map();
                n.set(0, nodes);
                nodes = new node_1.TwingNode(n);
            }
            for (let [idx, node] of nodes.getNodes()) {
                if (!node.getNodes().size) {
                    continue;
                }
                // unit: this block is not coverable; how can node be of type TEXT and have children nodes?
                // if (node.getType() === TwingNodeType.TEXT && ctype_space(node.getAttribute('data'))) {
                //     continue;
                // }
                // unit: this block is not coverable; how can node be of type BLOCK_REFERENCE and have children nodes?
                // if (node.getType() === TwingNodeType.BLOCK_REFERENCE) {
                //     continue;
                // }
                traitable = false;
                break;
            }
        }
        if (traitable) {
            return;
        }
        compiler
            .write("isTraitable() {\n")
            .indent()
            // unit: something is really wrong here
            // .write(`return ${traitable ? 'true' : 'false'};\n`)
            .write('return false;\n')
            .outdent()
            .write("}\n\n");
    }
    compileDebugInfo(compiler) {
        compiler
            .write("getDebugInfo() {\n")
            .indent()
            .write('return ')
            // @see https://github.com/Microsoft/TypeScript/issues/11152
            .repr(new Map(Array.from(compiler.getDebugInfo()).reverse()))
            .raw(';\n')
            .outdent()
            .write("}\n\n");
    }
    compileGetSourceContext(compiler) {
        compiler
            .write("getSourceContext() {\n")
            .indent()
            .write('return new Runtime.TwingSource(')
            .string(compiler.getEnvironment().isDebug() || compiler.getEnvironment().isSourceMap() ? this.source.getCode() : '')
            .raw(', ')
            .string(this.source.getName())
            .raw(', ')
            .string(this.source.getPath())
            .raw(");\n")
            .outdent()
            .write("}\n");
    }
    compileClassfooter(compiler) {
        compiler
            .subcompile(this.getNode('class_end'))
            .outdent()
            .write('};\n\n');
    }
}
exports.TwingNodeModule = TwingNodeModule;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 342 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Check whether a string consists of whitespace character(s) only.
 *
 * @param {string} value
 * @return boolean
 */
function ctypeSpace(value) {
    let regExp = /^[ \r\n\t\f\v]+$/;
    return regExp.test(value);
}
exports.ctypeSpace = ctypeSpace;


/***/ }),
/* 343 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const escaper_1 = __webpack_require__(344);
const auto_escape_1 = __webpack_require__(346);
const file_extension_escaping_strategy_1 = __webpack_require__(348);
const filter_1 = __webpack_require__(201);
class TwingExtensionEscaper extends extension_1.TwingExtension {
    /**
     * @param {string} defaultStrategy An escaping strategy
     */
    constructor(defaultStrategy = 'html') {
        super();
        this.setDefaultStrategy(defaultStrategy);
    }
    getTokenParsers() {
        return [
            new auto_escape_1.TwingTokenParserAutoEscape()
        ];
    }
    getNodeVisitors() {
        return [
            new escaper_1.TwingNodeVisitorEscaper()
        ];
    }
    getFilters() {
        return new Map([
            [0, new filter_1.TwingFilter('raw', twingRawFilter, {
                    is_safe: ['all']
                })],
        ]);
    }
    /**
     * Sets the default strategy to use when not defined by the user.
     *
     * The strategy can be a valid PHP callback that takes the template
     * name as an argument and returns the strategy to use.
     *
     * @param {string|boolean|Function} defaultStrategy An escaping strategy
     */
    setDefaultStrategy(defaultStrategy) {
        if (defaultStrategy === 'name') {
            defaultStrategy = file_extension_escaping_strategy_1.TwingFileExtensionEscapingStrategy.guess;
        }
        this.defaultStrategy = defaultStrategy;
    }
    /**
     * Gets the default strategy to use when not defined by the user.
     *
     * @param {string|boolean} name The template name
     *
     * @returns {string|false} The default strategy to use for the template
     */
    getDefaultStrategy(name) {
        let result;
        // disable string callables to avoid calling a function named html or js,
        // or any other upcoming escaping strategy
        if (typeof this.defaultStrategy === 'function') {
            return this.defaultStrategy(name);
        }
        result = this.defaultStrategy;
        return result;
    }
}
exports.TwingExtensionEscaper = TwingExtensionEscaper;
/**
 * Marks a variable as being safe.
 *
 * @param {string} string A variable
 *
 * @return string
 */
function twingRawFilter(string) {
    return string;
}
exports.twingRawFilter = twingRawFilter;


/***/ }),
/* 344 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_node_visitor_1 = __webpack_require__(129);
const node_1 = __webpack_require__(107);
const safe_analysis_1 = __webpack_require__(345);
const node_traverser_1 = __webpack_require__(205);
const constant_1 = __webpack_require__(115);
const filter_1 = __webpack_require__(161);
const print_1 = __webpack_require__(124);
const do_1 = __webpack_require__(199);
const conditional_1 = __webpack_require__(138);
const inline_print_1 = __webpack_require__(506);
class TwingNodeVisitorEscaper extends base_node_visitor_1.TwingBaseNodeVisitor {
    constructor() {
        super();
        this.statusStack = [];
        this.blocks = new Map();
        this.defaultStrategy = false;
        this.safeVars = [];
        this.TwingNodeVisitorInterfaceImpl = this;
        this.safeAnalysis = new safe_analysis_1.TwingNodeVisitorSafeAnalysis();
    }
    doEnterNode(node, env) {
        if (node.getType() === node_1.TwingNodeType.MODULE) {
            if (env.hasExtension('TwingExtensionEscaper')) {
                this.defaultStrategy = env.getExtension('TwingExtensionEscaper').getDefaultStrategy(node.getTemplateName());
            }
            this.safeVars = [];
            this.blocks = new Map();
        }
        else if (node.getType() === node_1.TwingNodeType.AUTO_ESCAPE) {
            this.statusStack.push(node.getAttribute('value'));
        }
        else if (node.getType() === node_1.TwingNodeType.BLOCK) {
            this.statusStack.push(this.blocks.has(node.getAttribute('name')) ? this.blocks.get(node.getAttribute('name')) : this.needEscaping());
        }
        else if (node.getType() === node_1.TwingNodeType.IMPORT) {
            this.safeVars.push(node.getNode('var').getAttribute('name'));
        }
        return node;
    }
    doLeaveNode(node, env) {
        if (node.getType() === node_1.TwingNodeType.MODULE) {
            this.defaultStrategy = false;
            this.safeVars = [];
            this.blocks = new Map();
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_FILTER) {
            return this.preEscapeFilterNode(node, env);
        }
        else if (node.getType() === node_1.TwingNodeType.PRINT) {
            let type = this.needEscaping();
            if (type !== false) {
                let expression = node.getNode('expr');
                if (expression.is(node_1.TwingNodeType.EXPRESSION_CONDITIONAL) && this.shouldUnwrapConditional(expression, env, type)) {
                    return new do_1.TwingNodeDo(this.unwrapConditional(expression, env, type), expression.getTemplateLine(), expression.getTemplateColumn());
                }
                return this.escapePrintNode(node, env, type);
            }
        }
        if (node.getType() === node_1.TwingNodeType.AUTO_ESCAPE || node.getType() === node_1.TwingNodeType.BLOCK) {
            this.statusStack.pop();
        }
        else if (node.getType() === node_1.TwingNodeType.BLOCK_REFERENCE) {
            this.blocks.set(node.getAttribute('name'), this.needEscaping());
        }
        return node;
    }
    shouldUnwrapConditional(expression, env, type) {
        let expr2Safe = this.isSafeFor(type, expression.getNode('expr2'), env);
        let expr3Safe = this.isSafeFor(type, expression.getNode('expr3'), env);
        return expr2Safe !== expr3Safe;
    }
    unwrapConditional(expression, env, type) {
        // convert "echo a ? b : c" to "a ? echo b : echo c" recursively
        let expr2 = expression.getNode('expr2');
        if (expr2.is(node_1.TwingNodeType.EXPRESSION_CONDITIONAL) && this.shouldUnwrapConditional(expr2, env, type)) {
            expr2 = this.unwrapConditional(expr2, env, type);
        }
        else {
            expr2 = this.escapeInlinePrintNode(new inline_print_1.TwingNodeInlinePrint(expr2, expr2.getTemplateLine(), expr2.getTemplateColumn()), env, type);
        }
        let expr3 = expression.getNode('expr3');
        if (expr3.is(node_1.TwingNodeType.EXPRESSION_CONDITIONAL) && this.shouldUnwrapConditional(expr3, env, type)) {
            expr3 = this.unwrapConditional(expr3, env, type);
        }
        else {
            expr3 = this.escapeInlinePrintNode(new inline_print_1.TwingNodeInlinePrint(expr3, expr3.getTemplateLine(), expr3.getTemplateColumn()), env, type);
        }
        return new conditional_1.TwingNodeExpressionConditional(expression.getNode('expr1'), expr2, expr3, expression.getTemplateLine(), expression.getTemplateColumn());
    }
    escapeInlinePrintNode(node, env, type) {
        let expression = node.getNode('node');
        if (this.isSafeFor(type, expression, env)) {
            return node;
        }
        return new inline_print_1.TwingNodeInlinePrint(this.getEscaperFilter(type, expression), node.getTemplateLine(), node.getTemplateColumn());
    }
    escapePrintNode(node, env, type) {
        let expression = node.getNode('expr');
        if (this.isSafeFor(type, expression, env)) {
            return node;
        }
        return new print_1.TwingNodePrint(this.getEscaperFilter(type, expression), node.getTemplateLine(), node.getTemplateColumn());
    }
    preEscapeFilterNode(filter, env) {
        let name = filter.getNode('filter').getAttribute('value');
        let type = env.getFilter(name).getPreEscape();
        if (type === null) {
            return filter;
        }
        let node = filter.getNode('node');
        if (this.isSafeFor(type, node, env)) {
            return filter;
        }
        filter.setNode('node', this.getEscaperFilter(type, node));
        return filter;
    }
    isSafeFor(type, expression, env) {
        let safe = this.safeAnalysis.getSafe(expression);
        if (!safe) {
            if (!this.traverser) {
                this.traverser = new node_traverser_1.TwingNodeTraverser(env, [this.safeAnalysis]);
            }
            this.safeAnalysis.setSafeVars(this.safeVars);
            this.traverser.traverse(expression);
            safe = this.safeAnalysis.getSafe(expression);
        }
        return (safe.includes(type)) || (safe.includes('all'));
    }
    /**
     * @returns string | Function | false
     */
    needEscaping() {
        if (this.statusStack.length) {
            return this.statusStack[this.statusStack.length - 1];
        }
        return this.defaultStrategy ? this.defaultStrategy : false;
    }
    getEscaperFilter(type, node) {
        let line = node.getTemplateLine();
        let column = node.getTemplateColumn();
        let nodes = new Map();
        let name = new constant_1.TwingNodeExpressionConstant('escape', line, column);
        let i = 0;
        nodes.set(i++, new constant_1.TwingNodeExpressionConstant(type, line, column));
        nodes.set(i++, new constant_1.TwingNodeExpressionConstant(null, line, column));
        nodes.set(i++, new constant_1.TwingNodeExpressionConstant(true, line, column));
        let nodeArgs = new node_1.TwingNode(nodes);
        return new filter_1.TwingNodeExpressionFilter(node, name, nodeArgs, line, column);
    }
    getPriority() {
        return 0;
    }
}
exports.TwingNodeVisitorEscaper = TwingNodeVisitorEscaper;


/***/ }),
/* 345 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_node_visitor_1 = __webpack_require__(129);
const node_1 = __webpack_require__(107);
const objectHash = __webpack_require__(505);
class TwingNodeVisitorSafeAnalysis extends base_node_visitor_1.TwingBaseNodeVisitor {
    constructor() {
        super();
        this.data = new Map();
        this.safeVars = [];
        this.TwingNodeVisitorInterfaceImpl = this;
    }
    setSafeVars(safeVars) {
        this.safeVars = safeVars;
    }
    /**
     *
     * @param {TwingNode} node
     * @returns {Array<string>}
     */
    getSafe(node) {
        let hash = objectHash(node);
        if (!this.data.has(hash)) {
            return;
        }
        let bucket = this.data.get(hash).find(function (bucket) {
            if (bucket.key === node) {
                if (bucket.value.includes('html_attr')) {
                    bucket.value.push('html');
                }
                return true;
            }
        });
        return bucket ? bucket.value : null;
    }
    setSafe(node, safe) {
        let hash = objectHash(node);
        let bucket = null;
        if (this.data.has(hash)) {
            bucket = this.data.get(hash).find(function (bucket) {
                if (bucket.key === node) {
                    bucket.value = safe;
                    return true;
                }
            });
        }
        if (!bucket) {
            if (!this.data.has(hash)) {
                this.data.set(hash, []);
            }
            this.data.get(hash).push({
                key: node,
                value: safe
            });
        }
    }
    doEnterNode(node, env) {
        return node;
    }
    doLeaveNode(node, env) {
        if (node.getType() === node_1.TwingNodeType.EXPRESSION_CONSTANT) {
            // constants are marked safe for all
            this.setSafe(node, ['all']);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_BLOCK_REFERENCE) {
            // blocks are safe by definition
            this.setSafe(node, ['all']);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_PARENT) {
            // parent block is safe by definition
            this.setSafe(node, ['all']);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_CONDITIONAL) {
            // intersect safeness of both operands
            let safe = this.intersectSafe(this.getSafe(node.getNode('expr2')), this.getSafe(node.getNode('expr3')));
            this.setSafe(node, safe);
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_FILTER) {
            // filter expression is safe when the filter is safe
            let name = node.getNode('filter').getAttribute('value');
            let filterArgs = node.getNode('arguments');
            let filter = env.getFilter(name);
            if (filter) {
                let safe = filter.getSafe(filterArgs);
                if (!safe) {
                    safe = this.intersectSafe(this.getSafe(node.getNode('node')), filter.getPreservesSafety());
                }
                this.setSafe(node, safe);
            }
            else {
                this.setSafe(node, []);
            }
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_FUNCTION) {
            // function expression is safe when the function is safe
            let name = node.getAttribute('name');
            let functionArgs = node.getNode('arguments');
            let functionNode = env.getFunction(name);
            if (functionNode) {
                this.setSafe(node, functionNode.getSafe(functionArgs));
            }
            else {
                this.setSafe(node, []);
            }
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_METHOD_CALL) {
            if (node.getAttribute('safe')) {
                this.setSafe(node, ['all']);
            }
            else {
                this.setSafe(node, []);
            }
        }
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR && node.getNode('node').getType() === node_1.TwingNodeType.EXPRESSION_NAME) {
            let name = node.getNode('node').getAttribute('name');
            if (this.safeVars.includes(name)) {
                this.setSafe(node, ['all']);
            }
            else {
                this.setSafe(node, []);
            }
        }
        else {
            this.setSafe(node, []);
        }
        return node;
    }
    intersectSafe(a, b) {
        if (a === null || b === null) {
            return [];
        }
        if (a.includes('all')) {
            return b;
        }
        if (b.includes('all')) {
            return a;
        }
        // array_intersect
        return a.filter(function (n) {
            return b.includes(n);
        });
    }
    getPriority() {
        return 0;
    }
}
exports.TwingNodeVisitorSafeAnalysis = TwingNodeVisitorSafeAnalysis;


/***/ }),
/* 346 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Marks a section of a template to be escaped or not.
 */
const token_parser_1 = __webpack_require__(111);
const node_1 = __webpack_require__(107);
const token_1 = __webpack_require__(109);
const syntax_1 = __webpack_require__(112);
const auto_escape_1 = __webpack_require__(347);
class TwingTokenParserAutoEscape extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columnno = token.getColumn();
        let stream = this.parser.getStream();
        let value;
        if (stream.test(token_1.TwingToken.BLOCK_END_TYPE)) {
            value = 'html';
        }
        else {
            let expr = this.parser.getExpressionParser().parseExpression();
            if (expr.getType() !== node_1.TwingNodeType.EXPRESSION_CONSTANT) {
                throw new syntax_1.TwingErrorSyntax('An escaping strategy must be a string or false.', stream.getCurrent().getLine(), stream.getSourceContext());
            }
            value = expr.getAttribute('value');
        }
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideBlockEnd], true);
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new auto_escape_1.TwingNodeAutoEscape(value, body, lineno, columnno, this.getTag());
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endautoescape');
    }
    getTag() {
        return 'autoescape';
    }
}
exports.TwingTokenParserAutoEscape = TwingTokenParserAutoEscape;


/***/ }),
/* 347 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Represents an autoescape node.
 *
 * The value is the escaping strategy (can be html, js, ...)
 *
 * The true value is equivalent to html.
 *
 * If autoescaping is disabled, then the value is false.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
class TwingNodeAutoEscape extends node_1.TwingNode {
    constructor(value, body, lineno, columnno, tag = 'autoescape') {
        super(new Map([['body', body]]), new Map([['value', value]]), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.AUTO_ESCAPE;
    }
    compile(compiler) {
        compiler.subcompile(this.getNode('body'));
    }
}
exports.TwingNodeAutoEscape = TwingNodeAutoEscape;


/***/ }),
/* 348 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const path = __webpack_require__(349);
class TwingFileExtensionEscapingStrategy {
    /**
     * Guesses the best autoescaping strategy based on the file name.
     *
     * @param {string} name The template name
     *
     * @return string | Function | false The escaping strategy to use or false to disable
     */
    static guess(name) {
        let extension = path.extname(name);
        if (extension === '.twig') {
            name = path.basename(name, extension);
            extension = path.extname(name);
        }
        switch (extension) {
            case '.js':
                return 'js';
            case '.css':
                return 'css';
            case '.txt':
                return false;
            default:
                return 'html';
        }
    }
}
exports.TwingFileExtensionEscapingStrategy = TwingFileExtensionEscapingStrategy;


/***/ }),
/* 349 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(process) {// .dirname, .basename, and .extname methods are extracted from Node.js v8.11.1,
// backported and transplited with Babel, with backwards-compat fixes

// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.

// resolves . and .. elements in a path array with directory names there
// must be no slashes, empty elements, or device names (c:\) in the array
// (so also no leading and trailing slashes - it does not distinguish
// relative and absolute paths)
function normalizeArray(parts, allowAboveRoot) {
  // if the path tries to go above the root, `up` ends up > 0
  var up = 0;
  for (var i = parts.length - 1; i >= 0; i--) {
    var last = parts[i];
    if (last === '.') {
      parts.splice(i, 1);
    } else if (last === '..') {
      parts.splice(i, 1);
      up++;
    } else if (up) {
      parts.splice(i, 1);
      up--;
    }
  }

  // if the path is allowed to go above the root, restore leading ..s
  if (allowAboveRoot) {
    for (; up--; up) {
      parts.unshift('..');
    }
  }

  return parts;
}

// path.resolve([from ...], to)
// posix version
exports.resolve = function() {
  var resolvedPath = '',
      resolvedAbsolute = false;

  for (var i = arguments.length - 1; i >= -1 && !resolvedAbsolute; i--) {
    var path = (i >= 0) ? arguments[i] : process.cwd();

    // Skip empty and invalid entries
    if (typeof path !== 'string') {
      throw new TypeError('Arguments to path.resolve must be strings');
    } else if (!path) {
      continue;
    }

    resolvedPath = path + '/' + resolvedPath;
    resolvedAbsolute = path.charAt(0) === '/';
  }

  // At this point the path should be resolved to a full absolute path, but
  // handle relative paths to be safe (might happen when process.cwd() fails)

  // Normalize the path
  resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) {
    return !!p;
  }), !resolvedAbsolute).join('/');

  return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.';
};

// path.normalize(path)
// posix version
exports.normalize = function(path) {
  var isAbsolute = exports.isAbsolute(path),
      trailingSlash = substr(path, -1) === '/';

  // Normalize the path
  path = normalizeArray(filter(path.split('/'), function(p) {
    return !!p;
  }), !isAbsolute).join('/');

  if (!path && !isAbsolute) {
    path = '.';
  }
  if (path && trailingSlash) {
    path += '/';
  }

  return (isAbsolute ? '/' : '') + path;
};

// posix version
exports.isAbsolute = function(path) {
  return path.charAt(0) === '/';
};

// posix version
exports.join = function() {
  var paths = Array.prototype.slice.call(arguments, 0);
  return exports.normalize(filter(paths, function(p, index) {
    if (typeof p !== 'string') {
      throw new TypeError('Arguments to path.join must be strings');
    }
    return p;
  }).join('/'));
};


// path.relative(from, to)
// posix version
exports.relative = function(from, to) {
  from = exports.resolve(from).substr(1);
  to = exports.resolve(to).substr(1);

  function trim(arr) {
    var start = 0;
    for (; start < arr.length; start++) {
      if (arr[start] !== '') break;
    }

    var end = arr.length - 1;
    for (; end >= 0; end--) {
      if (arr[end] !== '') break;
    }

    if (start > end) return [];
    return arr.slice(start, end - start + 1);
  }

  var fromParts = trim(from.split('/'));
  var toParts = trim(to.split('/'));

  var length = Math.min(fromParts.length, toParts.length);
  var samePartsLength = length;
  for (var i = 0; i < length; i++) {
    if (fromParts[i] !== toParts[i]) {
      samePartsLength = i;
      break;
    }
  }

  var outputParts = [];
  for (var i = samePartsLength; i < fromParts.length; i++) {
    outputParts.push('..');
  }

  outputParts = outputParts.concat(toParts.slice(samePartsLength));

  return outputParts.join('/');
};

exports.sep = '/';
exports.delimiter = ':';

exports.dirname = function (path) {
  if (typeof path !== 'string') path = path + '';
  if (path.length === 0) return '.';
  var code = path.charCodeAt(0);
  var hasRoot = code === 47 /*/*/;
  var end = -1;
  var matchedSlash = true;
  for (var i = path.length - 1; i >= 1; --i) {
    code = path.charCodeAt(i);
    if (code === 47 /*/*/) {
        if (!matchedSlash) {
          end = i;
          break;
        }
      } else {
      // We saw the first non-path separator
      matchedSlash = false;
    }
  }

  if (end === -1) return hasRoot ? '/' : '.';
  if (hasRoot && end === 1) {
    // return '//';
    // Backwards-compat fix:
    return '/';
  }
  return path.slice(0, end);
};

function basename(path) {
  if (typeof path !== 'string') path = path + '';

  var start = 0;
  var end = -1;
  var matchedSlash = true;
  var i;

  for (i = path.length - 1; i >= 0; --i) {
    if (path.charCodeAt(i) === 47 /*/*/) {
        // If we reached a path separator that was not part of a set of path
        // separators at the end of the string, stop now
        if (!matchedSlash) {
          start = i + 1;
          break;
        }
      } else if (end === -1) {
      // We saw the first non-path separator, mark this as the end of our
      // path component
      matchedSlash = false;
      end = i + 1;
    }
  }

  if (end === -1) return '';
  return path.slice(start, end);
}

// Uses a mixed approach for backwards-compatibility, as ext behavior changed
// in new Node.js versions, so only basename() above is backported here
exports.basename = function (path, ext) {
  var f = basename(path);
  if (ext && f.substr(-1 * ext.length) === ext) {
    f = f.substr(0, f.length - ext.length);
  }
  return f;
};

exports.extname = function (path) {
  if (typeof path !== 'string') path = path + '';
  var startDot = -1;
  var startPart = 0;
  var end = -1;
  var matchedSlash = true;
  // Track the state of characters (if any) we see before our first dot and
  // after any path separator we find
  var preDotState = 0;
  for (var i = path.length - 1; i >= 0; --i) {
    var code = path.charCodeAt(i);
    if (code === 47 /*/*/) {
        // If we reached a path separator that was not part of a set of path
        // separators at the end of the string, stop now
        if (!matchedSlash) {
          startPart = i + 1;
          break;
        }
        continue;
      }
    if (end === -1) {
      // We saw the first non-path separator, mark this as the end of our
      // extension
      matchedSlash = false;
      end = i + 1;
    }
    if (code === 46 /*.*/) {
        // If this is our first dot, mark it as the start of our extension
        if (startDot === -1)
          startDot = i;
        else if (preDotState !== 1)
          preDotState = 1;
    } else if (startDot !== -1) {
      // We saw a non-dot and non-path separator before our dot, so we should
      // have a good chance at having a non-empty extension
      preDotState = -1;
    }
  }

  if (startDot === -1 || end === -1 ||
      // We saw a non-dot character immediately before the dot
      preDotState === 0 ||
      // The (right-most) trimmed path component is exactly '..'
      preDotState === 1 && startDot === end - 1 && startDot === startPart + 1) {
    return '';
  }
  return path.slice(startDot, end);
};

function filter (xs, f) {
    if (xs.filter) return xs.filter(f);
    var res = [];
    for (var i = 0; i < xs.length; i++) {
        if (f(xs[i], i, xs)) res.push(xs[i]);
    }
    return res;
}

// String.prototype.substr - negative index don't work in IE8
var substr = 'ab'.substr(-1) === 'b'
    ? function (str, start, len) { return str.substr(start, len) }
    : function (str, start, len) {
        if (start < 0) start = str.length + start;
        return str.substr(start, len);
    }
;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(22)))

/***/ }),
/* 350 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const source_1 = __webpack_require__(130);
const loader_1 = __webpack_require__(140);
/**
 * Loads template from the filesystem.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingLoaderArray {
    constructor(templates) {
        this.TwingLoaderInterfaceImpl = this;
        let map = new Map();
        if (Array.isArray(templates)) {
            let i = 0;
            for (let template of templates) {
                map.set(i++, template);
            }
        }
        else if (typeof templates[Symbol.iterator] === 'function') {
            for (let [name, template] of templates) {
                map.set(name, template);
            }
        }
        else if (typeof templates === 'object') {
            for (let name in templates) {
                map.set(name, templates[name]);
            }
        }
        this.templates = map;
    }
    setTemplate(name, template) {
        this.templates.set(name, template);
    }
    getSourceContext(name) {
        if (!this.exists(name)) {
            throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined.`);
        }
        return new source_1.TwingSource(this.templates.get(name), name);
    }
    exists(name) {
        return this.templates.has(name);
    }
    getCacheKey(name) {
        if (!this.exists(name)) {
            throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined.`);
        }
        return name + ':' + this.templates.get(name);
    }
    isFresh(name, time) {
        if (!this.exists(name)) {
            throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined.`);
        }
        return true;
    }
    resolve(name) {
        return name;
    }
}
exports.TwingLoaderArray = TwingLoaderArray;


/***/ }),
/* 351 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const loader_1 = __webpack_require__(140);
/**
 * Loads templates from other loaders.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingLoaderChain {
    /**
     * @param {Array<TwingLoaderInterface>} loaders
     */
    constructor(loaders = []) {
        this.hasSourceCache = new Map();
        this.loaders = [];
        this.TwingLoaderInterfaceImpl = this;
        for (let loader of loaders) {
            this.addLoader(loader);
        }
    }
    addLoader(loader) {
        this.loaders.push(loader);
        this.hasSourceCache = new Map();
    }
    /**
     * @return TwingLoaderInterface[]
     */
    getLoaders() {
        return this.loaders;
    }
    getSourceContext(name, from) {
        let exceptions = [];
        for (let loader of this.loaders) {
            if (!loader.exists(name, from)) {
                continue;
            }
            try {
                return loader.getSourceContext(name, from);
            }
            catch (e) {
                if (e instanceof loader_1.TwingErrorLoader) {
                    exceptions.push(e.message);
                }
            }
        }
        throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined${exceptions.length ? ' (' + exceptions.join(', ') + ')' : ''}.`);
    }
    exists(name, from) {
        if (this.hasSourceCache.has(name)) {
            return this.hasSourceCache.get(name);
        }
        for (let loader of this.loaders) {
            if (loader.exists(name, from)) {
                this.hasSourceCache.set(name, true);
                return true;
            }
        }
        this.hasSourceCache.set(name, false);
        return false;
    }
    getCacheKey(name, from) {
        let exceptions = [];
        for (let loader of this.loaders) {
            if (!loader.exists(name, from)) {
                continue;
            }
            try {
                return loader.getCacheKey(name, from);
            }
            catch (e) {
                if (e instanceof loader_1.TwingErrorLoader) {
                    exceptions.push(loader.constructor.name + ': ' + e.message);
                }
            }
        }
        throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined${exceptions.length ? ' (' + exceptions.join(', ') + ')' : ''}.`);
    }
    isFresh(name, time, from) {
        let exceptions = [];
        for (let loader of this.loaders) {
            if (!loader.exists(name, from)) {
                continue;
            }
            try {
                return loader.isFresh(name, time, from);
            }
            catch (e) {
                if (e instanceof loader_1.TwingErrorLoader) {
                    exceptions.push(loader.constructor.name + ': ' + e.message);
                }
            }
        }
        throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined${exceptions.length ? ' (' + exceptions.join(', ') + ')' : ''}.`);
    }
    resolve(name, from) {
        let exceptions = [];
        for (let loader of this.loaders) {
            if (!loader.exists(name, from)) {
                continue;
            }
            try {
                return loader.resolve(name, from);
            }
            catch (e) {
                if (e instanceof loader_1.TwingErrorLoader) {
                    exceptions.push(loader.constructor.name + ': ' + e.message);
                }
            }
        }
        throw new loader_1.TwingErrorLoader(`Template "${name}" is not defined${exceptions.length ? ' (' + exceptions.join(', ') + ')' : ''}.`);
    }
}
exports.TwingLoaderChain = TwingLoaderChain;


/***/ }),
/* 352 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const optimizer_1 = __webpack_require__(353);
class TwingExtensionOptimizer extends extension_1.TwingExtension {
    constructor(optimizers = -1) {
        super();
        this.optimizers = optimizers;
    }
    getNodeVisitors() {
        return [
            new optimizer_1.TwingNodeVisitorOptimizer(this.optimizers)
        ];
    }
}
exports.TwingExtensionOptimizer = TwingExtensionOptimizer;


/***/ }),
/* 353 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_node_visitor_1 = __webpack_require__(129);
const node_1 = __webpack_require__(107);
const isInteger = __webpack_require__(507);
/**
 * TwingNodeVisitorOptimizer tries to optimizes the AST.
 *
 * This visitor is always the last registered one.
 *
 * You can configure which optimizations you want to activate via the
 * optimizer mode.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingNodeVisitorOptimizer extends base_node_visitor_1.TwingBaseNodeVisitor {
    /**
     * @param {number} optimizers The optimizer mode
     */
    constructor(optimizers = -1) {
        super();
        this.loops = [];
        this.loopsTargets = [];
        this.TwingNodeVisitorInterfaceImpl = this;
        if (!isInteger(optimizers) || optimizers > (TwingNodeVisitorOptimizer.OPTIMIZE_FOR | TwingNodeVisitorOptimizer.OPTIMIZE_RAW_FILTER | TwingNodeVisitorOptimizer.OPTIMIZE_VAR_ACCESS)) {
            throw new Error(`Optimizer mode "${optimizers}" is not valid.`);
        }
        this.optimizers = optimizers;
    }
    doEnterNode(node, env) {
        if (TwingNodeVisitorOptimizer.OPTIMIZE_FOR === (TwingNodeVisitorOptimizer.OPTIMIZE_FOR & this.optimizers)) {
            this.enterOptimizeFor(node, env);
        }
        return node;
    }
    doLeaveNode(node, env) {
        if (TwingNodeVisitorOptimizer.OPTIMIZE_FOR === (TwingNodeVisitorOptimizer.OPTIMIZE_FOR & this.optimizers)) {
            this.leaveOptimizeFor(node, env);
        }
        if (TwingNodeVisitorOptimizer.OPTIMIZE_RAW_FILTER === (TwingNodeVisitorOptimizer.OPTIMIZE_RAW_FILTER & this.optimizers)) {
            node = this.optimizeRawFilter(node, env);
        }
        node = this.optimizePrintNode(node, env);
        return node;
    }
    /**
     * Optimizes print nodes.
     *
     * It replaces:
     *
     *   * "echo this.render(Parent)Block()" with "this.display(Parent)Block()"
     *
     * @returns {TwingNode}
     */
    optimizePrintNode(node, env) {
        if (node.getType() !== node_1.TwingNodeType.PRINT) {
            return node;
        }
        let exprNode = node.getNode('expr');
        if (exprNode.getType() === node_1.TwingNodeType.EXPRESSION_BLOCK_REFERENCE ||
            exprNode.getType() === node_1.TwingNodeType.EXPRESSION_PARENT) {
            exprNode.setAttribute('output', true);
            return exprNode;
        }
        return node;
    }
    /**
     * Removes "raw" filters.
     *
     * @returns {TwingNode}
     */
    optimizeRawFilter(node, env) {
        if (node.getType() === node_1.TwingNodeType.EXPRESSION_FILTER && node.getNode('filter').getAttribute('value') === 'raw') {
            return node.getNode('node');
        }
        return node;
    }
    /**
     * Optimizes "for" tag by removing the "loop" variable creation whenever possible.
     */
    enterOptimizeFor(node, env) {
        if (node.getType() === node_1.TwingNodeType.FOR) {
            // disable the loop variable by default
            node.setAttribute('with_loop', false);
            this.loops.unshift(node);
            this.loopsTargets.unshift(node.getNode('value_target').getAttribute('name'));
            this.loopsTargets.unshift(node.getNode('key_target').getAttribute('name'));
        }
        else if (this.loops.length < 1) {
            // we are outside a loop
            return;
        }
        // when do we need to add the loop variable back?
        // the loop variable is referenced for the active loop
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_NAME && node.getAttribute('name') === 'loop') {
            node.setAttribute('always_defined', true);
            this.addLoopToCurrent();
        }
        // optimize access to loop targets
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_NAME && this.loopsTargets.includes(node.getAttribute('name'))) {
            node.setAttribute('always_defined', true);
        }
        // block reference
        else if (node.getType() === node_1.TwingNodeType.BLOCK_REFERENCE || node.getType() === node_1.TwingNodeType.EXPRESSION_BLOCK_REFERENCE) {
            this.addLoopToCurrent();
        }
        // include without the only attribute
        else if (node.getType() === node_1.TwingNodeType.INCLUDE && !node.getAttribute('only')) {
            this.addLoopToAll();
        }
        // include function without the with_context=false parameter
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_FUNCTION && node.getAttribute('name') === 'include' && (!node.getNode('arguments').hasNode('with_context') || node.getNode('arguments').getNode('with_context').getAttribute('value') !== false)) {
            this.addLoopToAll();
        }
        // the loop variable is referenced via an attribute
        else if (node.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR && (node.getNode('attribute').getType() !== node_1.TwingNodeType.EXPRESSION_CONSTANT || node.getNode('attribute').getAttribute('value') === 'parent') && (this.loops[0].getAttribute('with_loop') === true || (node.getNode('node').getType() === node_1.TwingNodeType.EXPRESSION_NAME && node.getNode('node').getAttribute('name') === 'loop'))) {
            this.addLoopToAll();
        }
    }
    /**
     * Optimizes "for" tag by removing the "loop" variable creation whenever possible.
     */
    leaveOptimizeFor(node, env) {
        if (node.getType() === node_1.TwingNodeType.FOR) {
            this.loops.shift();
            this.loopsTargets.shift();
            this.loopsTargets.shift();
        }
    }
    addLoopToCurrent() {
        this.loops[0].setAttribute('with_loop', true);
    }
    addLoopToAll() {
        for (let loop of this.loops) {
            loop.setAttribute('with_loop', true);
        }
    }
    getPriority() {
        return 255;
    }
}
exports.TwingNodeVisitorOptimizer = TwingNodeVisitorOptimizer;
TwingNodeVisitorOptimizer.OPTIMIZE_ALL = -1;
TwingNodeVisitorOptimizer.OPTIMIZE_NONE = 0;
TwingNodeVisitorOptimizer.OPTIMIZE_FOR = 2;
TwingNodeVisitorOptimizer.OPTIMIZE_RAW_FILTER = 4;
// obsolete, does not do anything
TwingNodeVisitorOptimizer.OPTIMIZE_VAR_ACCESS = 8;


/***/ }),
/* 354 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Clone a map.
 *
 * @param {Map<*, *>} map
 * @returns {Map<*, *>}
 */
function clone(map) {
    let result = new Map();
    for (let [key, value] of map) {
        result.set(key, value);
    }
    return result;
}
exports.clone = clone;


/***/ }),
/* 355 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const output_buffering_1 = __webpack_require__(131);
const is_traversable_1 = __webpack_require__(180);
const iterator_to_hash_1 = __webpack_require__(146);
const count_1 = __webpack_require__(177);
/**
 * Adapted from https://github.com/kvz/locutus/blob/master/src/php/var/var_dump.js
 */
function varDump(...args) {
    let padChar = ' ';
    let padVal = 4;
    let lgth = 0;
    let getInnerVal = function _getInnerVal(val) {
        let result = '';
        if (val === null || typeof val === 'undefined') {
            result = 'NULL';
        }
        else if (typeof val === 'boolean') {
            result = 'bool(' + val + ')';
        }
        else if (typeof val === 'number') {
            if (parseFloat('' + val) === parseInt('' + val, 10)) {
                result = 'int(' + val + ')';
            }
            else {
                result = 'float(' + val + ')';
            }
        }
        else if (typeof val === 'function') {
            result = 'object(Closure) (0) {}';
        }
        else {
            result = 'string(' + val.length + ') "' + val + '"';
        }
        return result;
    };
    let formatArray = function _formatArray(obj, curDepth, padVal, padChar) {
        if (is_traversable_1.isTraversable(obj)) {
            obj = iterator_to_hash_1.iteratorToHash(obj);
        }
        if (curDepth > 0) {
            curDepth++;
        }
        let baseCount = padVal * (curDepth - 1);
        let thickCount = padVal * (curDepth + 1);
        let basePad = padChar.repeat(baseCount > 0 ? baseCount : 0);
        let thickPad = padChar.repeat(thickCount);
        let str = '';
        let val;
        if (typeof obj === 'object' && obj !== null) {
            lgth = count_1.count(obj);
            str += 'array(' + lgth + ') {\n';
            for (let key in obj) {
                let objVal = obj[key];
                if ((typeof objVal === 'object') && (objVal !== null) && !(objVal instanceof Date)) {
                    str += thickPad;
                    str += '[';
                    str += key;
                    str += '] =>\n';
                    str += thickPad;
                    str += formatArray(objVal, curDepth + 1, padVal, padChar);
                }
                else {
                    val = getInnerVal(objVal);
                    str += thickPad;
                    str += '[';
                    str += key;
                    str += '] =>\n';
                    str += thickPad;
                    str += val;
                    str += '\n';
                }
            }
            str += basePad + '}\n';
        }
        else {
            str = getInnerVal(obj) + '\n';
        }
        return str;
    };
    let output = [];
    for (let arg of args) {
        output.push(formatArray(arg, 0, padVal, padChar));
    }
    output_buffering_1.echo(output.join(''));
}
exports.varDump = varDump;


/***/ }),
/* 356 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_node_visitor_1 = __webpack_require__(129);
const node_1 = __webpack_require__(107);
const profile_1 = __webpack_require__(206);
const body_1 = __webpack_require__(157);
const enter_profile_1 = __webpack_require__(357);
const leave_profile_1 = __webpack_require__(358);
const sha256 = __webpack_require__(149);
const hex = __webpack_require__(150);
class TwingProfilerNodeVisitorProfiler extends base_node_visitor_1.TwingBaseNodeVisitor {
    constructor(extensionName) {
        super();
        this.extensionName = extensionName;
    }
    doEnterNode(node, env) {
        return node;
    }
    doLeaveNode(node, env) {
        if (node.getType() === node_1.TwingNodeType.MODULE) {
            let varName = this.getVarName();
            let displayStartNodes = new Map();
            let i = 0;
            displayStartNodes.set(i++, new enter_profile_1.TwingProfilerNodeEnterProfile(this.extensionName, profile_1.TwingProfilerProfile.TEMPLATE, node.getTemplateName(), varName));
            displayStartNodes.set(i++, node.getNode('display_start'));
            node.setNode('display_start', new node_1.TwingNode(displayStartNodes));
            let displayEndNodes = new Map();
            i = 0;
            displayEndNodes.set(i++, new leave_profile_1.TwingProfilerNodeLeaveProfile(varName));
            displayEndNodes.set(i++, node.getNode('display_end'));
            node.setNode('display_end', new node_1.TwingNode(displayEndNodes));
        }
        else if (node.getType() === node_1.TwingNodeType.BLOCK) {
            let varName = this.getVarName();
            let bodyNodes = new Map();
            let i = 0;
            bodyNodes.set(i++, new enter_profile_1.TwingProfilerNodeEnterProfile(this.extensionName, profile_1.TwingProfilerProfile.BLOCK, node.getAttribute('name'), varName));
            bodyNodes.set(i++, node.getNode('body'));
            bodyNodes.set(i++, new leave_profile_1.TwingProfilerNodeLeaveProfile(varName));
            node.setNode('body', new body_1.TwingNodeBody(bodyNodes));
        }
        else if (node.getType() === node_1.TwingNodeType.MACRO) {
            let varName = this.getVarName();
            let bodyNodes = new Map();
            let i = 0;
            bodyNodes.set(i++, new enter_profile_1.TwingProfilerNodeEnterProfile(this.extensionName, profile_1.TwingProfilerProfile.MACRO, node.getAttribute('name'), varName));
            bodyNodes.set(i++, node.getNode('body'));
            bodyNodes.set(i++, new leave_profile_1.TwingProfilerNodeLeaveProfile(varName));
            node.setNode('body', new body_1.TwingNodeBody(bodyNodes));
        }
        return node;
    }
    getVarName() {
        return `__internal_${hex.stringify(sha256(this.extensionName))}`;
    }
    getPriority() {
        return 0;
    }
}
exports.TwingProfilerNodeVisitorProfiler = TwingProfilerNodeVisitorProfiler;


/***/ }),
/* 357 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Represents a profile enter node.
 *
 * @author Fabien Potencier <fabien@symfony.com>
 */
class TwingProfilerNodeEnterProfile extends node_1.TwingNode {
    constructor(extensionName, type, name, varName) {
        super(new Map(), new Map([['extension_name', extensionName], ['name', name], ['type', type], ['var_name', varName]]));
        this.type = node_1.TwingNodeType.PROFILER_ENTER_PROFILE;
    }
    compile(compiler) {
        compiler
            .write(`let ${this.getAttribute('var_name')} = this.extensions.get(`)
            .repr(this.getAttribute('extension_name'))
            .raw(");\n")
            .write(`let ${this.getAttribute('var_name') + 'Prof'} = new Runtime.TwingProfilerProfile(this.getTemplateName(), `)
            .repr(this.getAttribute('type'))
            .raw(', ')
            .repr(this.getAttribute('name'))
            .raw(');\n')
            .write(`${this.getAttribute('var_name')}.enter(${this.getAttribute('var_name') + 'Prof'});\n\n`);
    }
}
exports.TwingProfilerNodeEnterProfile = TwingProfilerNodeEnterProfile;


/***/ }),
/* 358 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingProfilerNodeLeaveProfile extends node_1.TwingNode {
    constructor(varName) {
        super(new Map(), new Map([['var_name', varName]]));
        this.type = node_1.TwingNodeType.PROFILER_LEAVE_PROFILE;
    }
    compile(compiler) {
        compiler
            .write("\n")
            .write(`${this.getAttribute('var_name')}.leave(${this.getAttribute('var_name') + 'Prof'});\n\n`);
    }
}
exports.TwingProfilerNodeLeaveProfile = TwingProfilerNodeLeaveProfile;


/***/ }),
/* 359 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const syntax_1 = __webpack_require__(112);
const sandbox_1 = __webpack_require__(360);
const node_1 = __webpack_require__(107);
const ctype_space_1 = __webpack_require__(342);
class TwingTokenParserSandbox extends token_parser_1.TwingTokenParser {
    parse(token) {
        let stream = this.parser.getStream();
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideBlockEnd], true);
        stream.expect(token_1.TwingToken.BLOCK_END_TYPE);
        // in a sandbox tag, only include tags are allowed
        if (body.getType() !== node_1.TwingNodeType.INCLUDE) {
            body.getNodes().forEach(function (node) {
                if (!(node.getType() === node_1.TwingNodeType.TEXT && ctype_space_1.ctypeSpace(node.getAttribute('data')))) {
                    if (node.getType() !== node_1.TwingNodeType.INCLUDE) {
                        throw new syntax_1.TwingErrorSyntax('Only "include" tags are allowed within a "sandbox" section.', node.getTemplateLine(), stream.getSourceContext());
                    }
                }
            });
        }
        return new sandbox_1.TwingNodeSandbox(body, token.getLine(), token.getColumn(), this.getTag());
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endsandbox');
    }
    getTag() {
        return 'sandbox';
    }
}
exports.TwingTokenParserSandbox = TwingTokenParserSandbox;


/***/ }),
/* 360 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeSandbox extends node_1.TwingNode {
    constructor(body, lineno, columnno, tag = null) {
        super(new Map([['body', body]]), new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.SANDBOX;
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write("(")
            .raw("() => {\n")
            .indent()
            .write('let alreadySandboxed = this.sandbox.isSandboxed();\n')
            .write("if (!alreadySandboxed) {\n")
            .indent()
            .write("this.sandbox.enableSandbox();\n")
            .outdent()
            .write("}\n")
            .subcompile(this.getNode('body'))
            .write("if (!alreadySandboxed) {\n")
            .indent()
            .write("this.sandbox.disableSandbox();\n")
            .outdent()
            .write("}\n")
            .outdent()
            .write("})();\n");
    }
}
exports.TwingNodeSandbox = TwingNodeSandbox;


/***/ }),
/* 361 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_node_visitor_1 = __webpack_require__(129);
const node_1 = __webpack_require__(107);
const check_security_1 = __webpack_require__(362);
const check_to_string_1 = __webpack_require__(516);
class TwingNodeVisitorSandbox extends base_node_visitor_1.TwingBaseNodeVisitor {
    constructor() {
        super();
        this.inAModule = false;
        this.TwingNodeVisitorInterfaceImpl = this;
    }
    doEnterNode(node, env) {
        if (node.getType() === node_1.TwingNodeType.MODULE) {
            this.inAModule = true;
            this.tags = new Map();
            this.filters = new Map();
            this.functions = new Map();
            return node;
        }
        else if (this.inAModule) {
            // look for tags
            if (node.getNodeTag() && !(this.tags.has(node.getNodeTag()))) {
                this.tags.set(node.getNodeTag(), node);
            }
            // look for filters
            if (node.getType() === node_1.TwingNodeType.EXPRESSION_FILTER && !this.filters.has(node.getNode('filter').getAttribute('value'))) {
                this.filters.set(node.getNode('filter').getAttribute('value'), node);
            }
            // look for functions
            if (node.getType() === node_1.TwingNodeType.EXPRESSION_FUNCTION && !this.functions.has(node.getAttribute('name'))) {
                this.functions.set(node.getAttribute('name'), node);
            }
            // the .. operator is equivalent to the range() function
            if (node.getType() === node_1.TwingNodeType.EXPRESSION_BINARY_RANGE && !(this.functions.has('range'))) {
                this.functions.set('range', node);
            }
            // wrap print to check toString() calls
            if (node.getType() === node_1.TwingNodeType.PRINT) {
                this.needsToStringWrap = true;
                this.wrapNode(node, 'expr');
            }
            if (node.getType() === node_1.TwingNodeType.SET && !node.getAttribute('capture')) {
                this.needsToStringWrap = true;
            }
            // wrap outer nodes that can implicitly call toString()
            if (this.needsToStringWrap) {
                if (node.getType() === node_1.TwingNodeType.EXPRESSION_BINARY_CONCAT) {
                    this.wrapNode(node, 'left');
                    this.wrapNode(node, 'right');
                }
                if (node.getType() === node_1.TwingNodeType.EXPRESSION_FILTER) {
                    this.wrapNode(node, 'node');
                    this.wrapArrayNode(node, 'arguments');
                }
                if (node.getType() === node_1.TwingNodeType.EXPRESSION_FUNCTION) {
                    this.wrapArrayNode(node, 'arguments');
                }
            }
        }
        return node;
    }
    doLeaveNode(node, env) {
        if (node.getType() === node_1.TwingNodeType.MODULE) {
            this.inAModule = false;
            let nodes = new Map();
            let i = 0;
            nodes.set(i++, new check_security_1.TwingNodeCheckSecurity(this.filters, this.tags, this.functions));
            nodes.set(i++, node.getNode('display_start'));
            node.setNode('constructor_end', new node_1.TwingNode(nodes));
        }
        else if (this.inAModule) {
            if (node.getType() === node_1.TwingNodeType.PRINT || node.getType() === node_1.TwingNodeType.SET) {
                this.needsToStringWrap = false;
            }
        }
        return node;
    }
    wrapNode(node, name) {
        let expr = node.getNode(name);
        if (expr.getType() === node_1.TwingNodeType.EXPRESSION_NAME || expr.getType() === node_1.TwingNodeType.EXPRESSION_GET_ATTR) {
            node.setNode(name, new check_to_string_1.TwingNodeCheckToString(expr));
        }
    }
    wrapArrayNode(node, name) {
        let args = node.getNode(name);
        for (let [name] of args.getNodes()) {
            this.wrapNode(args, name);
        }
    }
    getPriority() {
        return 0;
    }
}
exports.TwingNodeVisitorSandbox = TwingNodeVisitorSandbox;


/***/ }),
/* 362 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeCheckSecurity extends node_1.TwingNode {
    constructor(usedFilters, usedTags, usedFunctions) {
        super();
        this.usedFilters = usedFilters;
        this.usedTags = usedTags;
        this.usedFunctions = usedFunctions;
    }
    compile(compiler) {
        let tags = new Map();
        for (let [name, node] of this.usedTags) {
            if (typeof node === 'string') {
                tags.set(node, null);
            }
            else {
                tags.set(name, node.getTemplateLine());
            }
        }
        let filters = new Map();
        for (let [name, node] of this.usedFilters) {
            if (typeof node === 'string') {
                filters.set(node, null);
            }
            else {
                filters.set(name, node.getTemplateLine());
            }
        }
        let functions = new Map();
        for (let [name, node] of this.usedFunctions) {
            if (typeof node === 'string') {
                functions.set(node, null);
            }
            else {
                functions.set(name, node.getTemplateLine());
            }
        }
        compiler
            .write("this.sandbox = this.env.getExtension('TwingExtensionSandbox');\n")
            .write('let tags = ').repr(tags).raw(";\n")
            .write('let filters = ').repr(filters).raw(";\n")
            .write('let functions = ').repr(functions).raw(";\n\n")
            .write("try {\n")
            .indent()
            .write("this.sandbox.checkSecurity(\n")
            .indent()
            .write(!tags.size ? "[],\n" : "['" + [...tags.keys()].join('\', \'') + "'],\n")
            .write(!filters.size ? "[],\n" : "['" + [...filters.keys()].join('\', \'') + "'],\n")
            .write(!functions.size ? "[]\n" : "['" + [...functions.keys()].join('\', \'') + "']\n")
            .outdent()
            .write(");\n")
            .outdent()
            .write("}\n")
            .write("catch (e) {\n")
            .indent()
            .write("if (e instanceof Runtime.TwingSandboxSecurityError) {\n")
            .indent()
            .write("e.setSourceContext(this.source);\n\n")
            .write("if (e instanceof Runtime.TwingSandboxSecurityNotAllowedTagError && tags.has(e.getTagName())) {\n")
            .indent()
            .write("e.setTemplateLine(tags.get(e.getTagName()));\n")
            .outdent()
            .write("}\n")
            .write("else if (e instanceof Runtime.TwingSandboxSecurityNotAllowedFilterError && filters.has(e.getFilterName())) {\n")
            .indent()
            .write("e.setTemplateLine(filters.get(e.getFilterName()));\n")
            .outdent()
            .write("}\n")
            .write("else if (e instanceof Runtime.TwingSandboxSecurityNotAllowedFunctionError && functions.has(e.getFunctionName())) {\n")
            .indent()
            .write("e.setTemplateLine(functions.get(e.getFunctionName()));\n")
            .outdent()
            .write("}\n")
            .outdent()
            .write('}\n\n')
            .write("throw e;\n")
            .outdent()
            .write("}\n\n");
    }
}
exports.TwingNodeCheckSecurity = TwingNodeCheckSecurity;


/***/ }),
/* 363 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const security_error_1 = __webpack_require__(125);
class TwingSandboxSecurityNotAllowedMethodError extends security_error_1.TwingSandboxSecurityError {
    constructor(message, className, methodName, lineno = -1, filename = null) {
        super(message, lineno, filename);
        this.className = className;
        this.methodName = methodName;
        this.name = 'TwingSandboxSecurityNotAllowedMethodError';
    }
    getClassName() {
        return this.className;
    }
    getMethodName() {
        return this.methodName;
    }
}
exports.TwingSandboxSecurityNotAllowedMethodError = TwingSandboxSecurityNotAllowedMethodError;


/***/ }),
/* 364 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const security_error_1 = __webpack_require__(125);
/**
 * Exception thrown when a not allowed class property is used in a template.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingSandboxSecurityNotAllowedPropertyError extends security_error_1.TwingSandboxSecurityError {
    constructor(message, className, propertyName, lineno = -1, filename = null) {
        super(message, lineno, filename);
        this.className = className;
        this.propertyName = propertyName;
        this.name = 'TwingSandboxSecurityNotAllowedPropertyError';
    }
    getClassName() {
        return this.className;
    }
    getPropertyName() {
        return this.propertyName;
    }
}
exports.TwingSandboxSecurityNotAllowedPropertyError = TwingSandboxSecurityNotAllowedPropertyError;


/***/ }),
/* 365 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M26.8,33.8v1.1c0,0.2-0.1,0.3-0.2,0.4c-0.1,0.1-0.3,0.1-0.4,0.1H15.6c-0.2,0-0.3,0-0.4-0.1C15,35.1,15,35,15,34.8v-1.1 c0-0.2,0.1-0.3,0.2-0.4c0.1-0.1,0.3-0.1,0.4-0.1h10.6c0.2,0,0.3,0,0.4,0.1C26.7,33.5,26.8,33.6,26.8,33.8z M37.4,29.3V9.8 c0-0.1-0.1-0.3-0.2-0.4c-0.1-0.1-0.3-0.2-0.4-0.2H5c-0.2,0-0.3,0.1-0.4,0.2S4.4,9.7,4.4,9.8v19.5c0,0.1,0.1,0.3,0.2,0.4 c0.1,0.1,0.3,0.2,0.4,0.2h31.9c0.2,0,0.3-0.1,0.4-0.2C37.4,29.6,37.4,29.5,37.4,29.3z M39.8,9.6v20c0,0.7-0.3,1.3-0.9,1.9 c-0.6,0.5-1.3,0.8-2.1,0.8H5c-0.8,0-1.5-0.3-2.1-0.8S2,30.3,2,29.6v-20c0-0.7,0.3-1.3,0.9-1.9S4.1,7,5,7h31.9c0.8,0,1.5,0.3,2.1,0.8 C39.5,8.3,39.8,8.9,39.8,9.6z M15.4,25.2l-0.7,0.6c-0.1,0.1-0.2,0.1-0.3,0.1c-0.1,0-0.2,0-0.3-0.1l-6.7-6c-0.1-0.1-0.1-0.2-0.1-0.3 c0-0.1,0-0.2,0.1-0.3l6.7-6c0.1-0.1,0.2-0.1,0.3-0.1c0.1,0,0.2,0,0.3,0.1l0.7,0.6c0.1,0.1,0.1,0.2,0.1,0.3s0,0.2-0.1,0.3l-5.7,5 l5.7,5c0.1,0.1,0.1,0.2,0.1,0.3C15.6,25,15.5,25.1,15.4,25.2z M23.9,11.5l-5.4,16.6c0,0.1-0.1,0.2-0.2,0.3c-0.1,0.1-0.2,0.1-0.3,0 l-0.9-0.2c-0.1,0-0.2-0.1-0.3-0.2c-0.1-0.1-0.1-0.2,0-0.3l5.4-16.6c0-0.1,0.1-0.2,0.2-0.3c0.1-0.1,0.2-0.1,0.3,0l0.9,0.2 c0.1,0,0.2,0.1,0.3,0.2C24,11.3,24,11.4,23.9,11.5z M33.4,19.9l-6.7,6c-0.1,0.1-0.2,0.1-0.3,0.1s-0.2,0-0.3-0.1l-0.7-0.6 c-0.1-0.1-0.1-0.2-0.1-0.3c0-0.1,0-0.2,0.1-0.3l5.7-5l-5.7-5c-0.1-0.1-0.1-0.2-0.1-0.3s0-0.2,0.1-0.3l0.7-0.6 c0.1-0.1,0.2-0.1,0.3-0.1s0.2,0,0.3,0.1l6.7,6c0.1,0.1,0.1,0.2,0.1,0.3C33.6,19.7,33.5,19.8,33.4,19.9z'/%3E %3C/svg%3E\""

/***/ }),
/* 366 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='5 5 32.5 32.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='27.5' height='27.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23000000;%7D %3C/style%3E %3Cpath id='hook' class='st0' d='M29.5,17.6L18.6,28.5c-0.2,0.2-0.5,0.3-0.8,0.3c-0.3,0-0.6-0.1-0.8-0.3l-5.4-5.4 c-0.2-0.2-0.3-0.5-0.3-0.8c0-0.3,0.1-0.6,0.3-0.8l0.8-0.8c0.2-0.2,0.5-0.3,0.8-0.3s0.6,0.1,0.8,0.3l3.8,3.8l9.3-9.3 c0.2-0.2,0.5-0.3,0.8-0.3c0.3,0,0.6,0.1,0.8,0.3l0.8,0.8c0.2,0.2,0.3,0.5,0.3,0.8C29.8,17.1,29.7,17.4,29.5,17.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 367 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Icon_Phone' d='M35.3,29.4c0,0.4-0.1,0.8-0.2,1.4c-0.1,0.6-0.3,1-0.4,1.4c-0.3,0.7-1.1,1.4-2.5,2.1c-1.3,0.7-2.5,1-3.7,1 c-0.4,0-0.7,0-1.1-0.1s-0.7-0.1-1.2-0.3s-0.7-0.2-0.9-0.3c-0.2-0.1-0.6-0.2-1.1-0.4s-0.9-0.3-1-0.4c-1.3-0.5-2.5-1-3.5-1.7 c-1.7-1.1-3.5-2.5-5.3-4.3c-1.8-1.8-3.3-3.6-4.3-5.3c-0.6-1-1.2-2.2-1.7-3.5c0-0.1-0.2-0.4-0.4-1c-0.2-0.5-0.3-0.9-0.4-1.1 S7.4,16.5,7.3,16c-0.1-0.4-0.2-0.8-0.3-1.2C7,14.5,7,14.2,7,13.8c0-1.2,0.3-2.5,1-3.7c0.8-1.4,1.5-2.2,2.1-2.5 c0.3-0.1,0.8-0.3,1.4-0.4S12.6,7,13,7c0.2,0,0.3,0,0.4,0.1c0.2,0.1,0.6,0.6,1.1,1.5c0.1,0.3,0.3,0.6,0.6,1.1 c0.3,0.5,0.5,0.9,0.7,1.3c0.2,0.4,0.4,0.7,0.6,1.1c0,0.1,0.2,0.2,0.4,0.5c0.2,0.3,0.3,0.5,0.4,0.7s0.1,0.4,0.1,0.6 c0,0.3-0.2,0.6-0.6,1c-0.4,0.4-0.8,0.8-1.2,1.1s-0.9,0.7-1.2,1.1c-0.4,0.4-0.6,0.7-0.6,0.9c0,0.1,0,0.3,0.1,0.5 c0.1,0.2,0.1,0.3,0.2,0.4s0.1,0.3,0.3,0.5c0.1,0.2,0.2,0.4,0.2,0.4c1,1.8,2.2,3.4,3.5,4.7c1.3,1.3,2.9,2.5,4.7,3.5 c0,0,0.2,0.1,0.4,0.2c0.2,0.1,0.4,0.2,0.5,0.3s0.2,0.1,0.4,0.2c0.2,0.1,0.3,0.1,0.5,0.1c0.2,0,0.6-0.2,0.9-0.6 c0.4-0.4,0.7-0.8,1.1-1.2c0.3-0.4,0.7-0.9,1.1-1.2c0.4-0.4,0.7-0.6,1-0.6c0.2,0,0.4,0,0.6,0.1s0.4,0.2,0.7,0.4s0.4,0.3,0.5,0.4 c0.3,0.2,0.7,0.4,1.1,0.6c0.4,0.2,0.8,0.4,1.3,0.7c0.5,0.3,0.8,0.5,1.1,0.6c0.9,0.5,1.4,0.8,1.5,1.1C35.3,29.1,35.3,29.2,35.3,29.4z '/%3E %3C/svg%3E\""

/***/ }),
/* 368 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M5.2,21.9h6c0.1,2.2,0.4,4.3,0.8,6.2c-1.4,0.5-2.7,1.1-3.8,1.8C6.4,27.7,5.4,24.9,5.2,21.9z M8.1,11.5 c1.1,0.7,2.4,1.3,3.8,1.8c-0.5,2-0.7,4.1-0.8,6.2h-6C5.4,16.5,6.4,13.8,8.1,11.5z M36.9,19.5h-6c-0.1-2.2-0.4-4.3-0.8-6.2 c1.4-0.5,2.7-1.1,3.8-1.8C35.7,13.8,36.7,16.5,36.9,19.5z M34,30c-1.1-0.7-2.4-1.3-3.8-1.8c0.5-2,0.7-4.1,0.8-6.3h6 C36.7,24.9,35.7,27.7,34,30z M19.9,26.7c-2,0.1-3.9,0.3-5.6,0.8c-0.4-1.7-0.6-3.6-0.7-5.6h6.4V26.7z M19.9,29.1v7.3 c-2.5-0.9-4.1-4.2-5-6.7C16.4,29.4,18.1,29.2,19.9,29.1z M22.2,36.4v-7.3c1.7,0.1,3.4,0.3,5,0.7C26.4,32.3,24.7,35.5,22.2,36.4z M22.2,26.7v-4.8h6.4c-0.1,2-0.3,3.8-0.7,5.6C26.1,27.1,24.2,26.8,22.2,26.7z M28.6,19.5h-6.4v-4.8c2-0.1,3.9-0.3,5.6-0.8 C28.3,15.7,28.5,17.6,28.6,19.5z M22.2,12.3V5c2.5,0.9,4.1,4.2,5,6.7C25.7,12,24,12.3,22.2,12.3z M19.9,5v7.3 c-1.7-0.1-3.4-0.3-5-0.7C15.7,9.2,17.4,5.9,19.9,5z M19.9,14.7v4.8h-6.4c0.1-2,0.3-3.8,0.7-5.6C16,14.4,17.9,14.6,19.9,14.7z M9.6,31.8c0.9-0.5,1.9-1,2.9-1.4c0.6,1.7,1.4,3.5,2.5,5C13,34.7,11.2,33.4,9.6,31.8z M27,35.5c1.1-1.5,1.9-3.3,2.5-5 c1.1,0.4,2.1,0.8,2.9,1.4C30.9,33.4,29.1,34.7,27,35.5z M32.5,9.6c-0.9,0.5-1.9,1-2.9,1.4c-0.6-1.7-1.4-3.5-2.5-5 C29.1,6.8,30.9,8,32.5,9.6z M15.1,5.9c-1.1,1.5-1.9,3.3-2.5,5c-1.1-0.4-2.1-0.8-2.9-1.4C11.2,8,13,6.8,15.1,5.9z'/%3E %3C/svg%3E\""

/***/ }),
/* 369 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23FFFFFF;%7D .st1%7Bfill:%2304BAEE;%7D %3C/style%3E %3Cpath class='st0' d='M34.2,14.5h-27v21.3h27V14.5z'/%3E %3Cpath class='st1' d='M27.5,22.8h-6.1v6.1h6.1V22.8z'/%3E %3Cpath d='M7.4,35.6h5.5v-5.5H7.4V35.6z M14.1,35.6h6.1v-5.5h-6.1V35.6z M7.4,28.9h5.5v-6.1H7.4V28.9z M14.1,28.9h6.1v-6.1h-6.1V28.9z M7.4,21.6h5.5v-5.5H7.4V21.6z M21.4,35.6h6.1v-5.5h-6.1V35.6z M14.1,21.6h6.1v-5.5h-6.1V21.6z M28.7,35.6h5.5v-5.5h-5.5V35.6z M21.4,28.9h6.1v-6.1h-6.1V28.9z M14.7,12.5V7c0-0.2-0.1-0.3-0.2-0.4s-0.3-0.2-0.4-0.2h-1.2c-0.2,0-0.3,0.1-0.4,0.2 c-0.1,0.1-0.2,0.3-0.2,0.4v5.5c0,0.2,0.1,0.3,0.2,0.4c0.1,0.1,0.3,0.2,0.4,0.2h1.2c0.2,0,0.3-0.1,0.4-0.2 C14.7,12.8,14.7,12.7,14.7,12.5z M28.7,28.9h5.5v-6.1h-5.5V28.9z M21.4,21.6h6.1v-5.5h-6.1V21.6z M28.7,21.6h5.5v-5.5h-5.5V21.6z M29.3,12.5V7c0-0.2-0.1-0.3-0.2-0.4s-0.3-0.2-0.4-0.2h-1.2c-0.2,0-0.3,0.1-0.4,0.2S26.9,6.9,26.9,7v5.5c0,0.2,0.1,0.3,0.2,0.4 c0.1,0.1,0.3,0.2,0.4,0.2h1.2c0.2,0,0.3-0.1,0.4-0.2C29.2,12.8,29.3,12.7,29.3,12.5z M36.6,11.3v24.3c0,0.7-0.2,1.2-0.7,1.7 c-0.5,0.5-1.1,0.7-1.7,0.7H7.4c-0.7,0-1.2-0.2-1.7-0.7C5.2,36.8,5,36.2,5,35.6V11.3c0-0.7,0.2-1.2,0.7-1.7c0.5-0.5,1.1-0.7,1.7-0.7 h2.4V7c0-0.8,0.3-1.6,0.9-2.1S12.1,4,12.9,4h1.2c0.8,0,1.6,0.3,2.1,0.9c0.6,0.6,0.9,1.3,0.9,2.1v1.8h7.3V7c0-0.8,0.3-1.6,0.9-2.1 C25.9,4.3,26.6,4,27.5,4h1.2c0.8,0,1.6,0.3,2.1,0.9s0.9,1.3,0.9,2.1v1.8h2.4c0.7,0,1.2,0.2,1.7,0.7C36.3,10.1,36.6,10.6,36.6,11.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 370 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M12.5,19.5v-4.4c0-2.4,0.8-4.4,2.5-6.1c1.7-1.7,3.5-2.5,5.9-2.5s4,0.8,5.7,2.5c1.4,1.4,2.2,3,2.5,4.9 c0.1,0.8,2.7,0.4,2.5-0.6c-0.3-2.3-1.3-4.3-3.1-6.1C26.4,5.1,23.9,4,20.9,4s-5.5,1.1-7.6,3.2s-3.2,4.7-3.2,7.6v4.6H9.3 c-0.6,0-1.2,0.2-1.6,0.7c-0.5,0.5-0.7,1-0.7,1.6v13.9c0,0.6,0.2,1.2,0.7,1.6s1,0.7,1.6,0.7h23.2c0.6,0,1.2-0.2,1.6-0.7 c0.5-0.5,0.7-1,0.7-1.6V21.8c0-0.6-0.2-1.2-0.7-1.6c-0.5-0.5-1-0.7-1.6-0.7L12.5,19.5z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 371 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Icon_Passwort' d='M12.5,19.5h16.7v-4.4c0-2.4-0.8-4.4-2.5-6.1c-1.7-1.7-3.3-2.5-5.7-2.5S16.7,7.3,15,9s-2.5,3.7-2.5,6.1 V19.5z M34.8,21.8v13.9c0,0.6-0.2,1.2-0.7,1.6c-0.5,0.5-1,0.7-1.6,0.7H9.3c-0.6,0-1.2-0.2-1.6-0.7c-0.5-0.5-0.7-1-0.7-1.6V21.8 c0-0.6,0.2-1.2,0.7-1.6c0.5-0.5,1-0.7,1.6-0.7h0.8v-4.6c0-3,1.1-5.5,3.2-7.6S17.9,4,20.9,4s5.5,1.1,7.6,3.2s3.2,4.7,3.2,7.6v4.6h0.8 c0.6,0,1.2,0.2,1.6,0.7C34.6,20.6,34.8,21.1,34.8,21.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 372 */,
/* 373 */,
/* 374 */,
/* 375 */,
/* 376 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQALMMAKqooJGOhp2bk7e1rZ2bkre1rJCPhqqon8PBudDOxXd1bISCef///wAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQFAAAMACwAAAAAEAAQAAAET5DJyYyhmAZ7sxQEs1nMsmACGJKmSaVEOLXnK1PuBADepCiMg/DQ+/2GRI8RKOxJfpTCIJNIYArS6aRajWYZCASDa41Ow+Fx2YMWOyfpTAQAIfkEBQAADAAsAAAAABAAEAAABE6QyckEoZgKe7MEQMUxhoEd6FFdQWlOqTq15SlT9VQM3rQsjMKO5/n9hANixgjc9SQ/CgKRUSgw0ynFapVmGYkEg3v1gsPibg8tfk7CnggAIfkEBQAADAAsAAAAABAAEAAABE2QycnOoZjaA/IsRWV1goCBoMiUJTW8A0XMBPZmM4Ug3hQEjN2uZygahDyP0RBMEpmTRCKzWGCkUkq1SsFOFQrG1tr9gsPc3jnco4A9EQAh+QQFAAAMACwAAAAAEAAQAAAETpDJyUqhmFqbJ0LMIA7McWDfF5LmAVApOLUvLFMmlSTdJAiM3a73+wl5HYKSEET2lBSFIhMIYKRSimFriGIZiwWD2/WCw+Jt7xxeU9qZCAAh+QQFAAAMACwAAAAAEAAQAAAETZDJyRCimFqbZ0rVxgwF9n3hSJbeSQ2rCWIkpSjddBzMfee7nQ/XCfJ+OQYAQFksMgQBxumkEKLSCfVpMDCugqyW2w18xZmuwZycdDsRACH5BAUAAAwALAAAAAAQABAAAARNkMnJUqKYWpunUtXGIAj2feFIlt5JrWybkdSydNNQMLaND7pC79YBFnY+HENHMRgyhwPGaQhQotGm00oQMLBSLYPQ9QIASrLAq5x0OxEAIfkEBQAADAAsAAAAABAAEAAABE2QycmUopham+da1cYkCfZ94UiW3kmtbJuRlGF0E4Iwto3rut6tA9wFAjiJjkIgZAYDTLNJgUIpgqyAcTgwCuACJssAdL3gpLmbpLAzEQA7"

/***/ }),
/* 377 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlh6AMsAYcAAED/QID/gLfI187a58LY8NDc6Ofu9+jv9+rx+ezy+u70+u/1+vH2+/P3+/j7/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAADoAywBAAj/AAMUEEBQQICDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypcuXMF8WFFAgwAABBnIaiMmzp8+fQIMKHUq0qNGjSJMqXcoUpk4DAm7mJEC1qdWrWLNq3cq1q9evYMOKFUmVQE6CBsoSGMu2rdu3cOPKnUu3rt2HaqHiVHu3r9+/gAMLHky4sNW8aPkaXsy4sePHkCNL5op4b9nJmDNr3sy5s2fIldNe/ky6tOnTqFOrZhla8erXsGPLnk0bdFm9oqvW3s27t+/fwI+2Hh28uPHjyJMrXzhc9/Ln0KNLnz65+Vrq2LNr3879q/Xu4MOL/x9PXuX38ujTq1/P/jz79/Djy0fufr79+/jzf66vv7///wD2xV+ABBZo4IGH3ZYYcQg26OCDELY0YIQUVmjhhRFNiOGGHHaIoIYehijiiPGBSOKJKKaonYkqtujii8CxCOOMNNZ4mow25qjjjo7hyOOPQAZJl49CFmnkkVsRieSSTDYplJJORinllCdBSeWVWGZpkZVadunll1x+KeaYUYZJ5ploBmlmmmy2OeOabsYp54hwzmnnnRXWieeefBaoZ5+ABnrfn4IWamh6hB6q6KLbJcroo5Au52iklFbq26SWZqrpa5hu6umnnnUK6qik2kYVbq6VquqqnCpomXOsxv8q636u5nbdrLjmWl2tqerq66+EiQrssMQmFVqxyCbrF27KNussXMw+K+20XkVL7bXYMmVtttx2K9S23oYrrkvgjmvuuSSVi+667GqkbrvwxgvRu/LWa28A9N6rL7v57uvvuP3+KzC3AQ9s8LQFH6ywsgkv7PCwDT8sca4RT2wxqxVfrPGoGW/ssaYdfyxypCGPbLKiJZ+scqApr+wyni2/LHOcMc9sM5o136zzlznv7DOWPf8sdJRBD200kkUfrXSQSS/ttI5NPy31jFFPbbWKVV+t9YhZb+01h11/LXaFYY9ttoNln612gWmv7bZ/bb8t931xz203fHXfrXd6ee//7bd4ff8t+HaBD274dIUfrvhyiS/uuHGNPy65b5FPbjltlV+u+WuZb+75aZ1/LrpnoY9uemaln646ZKmv7vpirb8uu2Cxz257X7Xfrvtcue/uu1u9/y58WMEPbzxXxR+v/FXJL++8Us0/L31R0U9vPVDVX699TNlv7z1L3X8v/knhj2++SOWfr35H6a/vPkbtvy//RPHPb79D9d+vf0L5779///67HwADOL8BEvB9Bjzg+hKowPMxsIHjeyAEvyfBCW6vgha8HgYzOL0NcvB5Hvzg8kIowuORsITDOyEKf6fCFe6uhS68HQxjOLsZ0vB1Nrzh6nKow9PxsIej+yEQ/z8nxCFurohGvBwSkzi5JTLxcU584uKiKMXDUbGKg7siFv+mxS3urYtevBsYwzi3MZLxbWY849rSqMazsbGNY3sjHL8mxzlurY52vBoe8zi1PfLxaX7849ICKcijEbKQQzskIn+myEXurJGOvBkkIzmzSVLyZZa85MoyqcmTcbKTI/skKD8mylFurJSmvBgqUzmxVbLyYa585cJiKcuD0bKWA7slLv+ly13uq5e+vBcwg1mvYRIzXsY8ZruSqcx1MbOZ53omNAGGlmkGUJrW9BY2s0mwanJTgN78ZgHDKU4EkrOcCzwnOh2oznVGsJ3upCA843nBedJTg/a8Zwfzqf9PEPKznyP8J0BNKNCBprCgBmUhQhP6woUyVIYOfWgNIypRHFK0oju8KEZ9qNGNBrGjHiUiSEN6xJGSVIkmPWkTU6pSKLK0pVN8KUytKNOZZrGmNuUiTnP6xZ3yVIw+/WkZgypUNBK1qGs8KlLdqNSlxrGpTqUjVKN6x6lSVY9WvWofs6pVQHK1q4P8KlgNKdaxJrKsZmUkWtP6yLWyVZJufWsl4ypXTNK1rpu8K149qde9hrKvfiUlYAN7ysESVpWGPWwrE6tYWDK2sbN8LGRtKdnJ5rKyluUlZjP7y81yVpie/WwxQytaZJK2tMs8LWqdqdrVRrO1rqUmTmKb1Nl40paptr3tU3OrW6nytrdV/S1wsSrc4W61uMb1KnKTG9blMpeszn3uWaMrXbVSt7ptvS524ard7c61u961K3jDm9fxkpev5j3vX9OrXsGyt72FfS98ESvf+S62vvZ1LE52kl+bnUUqOumvyp4SFZvMRMAnm8kAAhAQADs="

/***/ }),
/* 378 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCAAgAIcAAMDAwMPDw8TExMXFxcbGxsnJycvLy8zMzM7Ozs/Pz9DQ0NHR0dLS0tPT09XV1dbW1tfX19jY2NnZ2dzc3N3d3d7e3uDg4OHh4eLi4uPj4+Tk5OXl5ebm5ufn5+np6erq6uvr6+zs7O3t7e7u7u/v7/Dw8PHx8fLy8vPz8/T09PX19fb29vf39/j4+Pn5+fv7+/z8/P39/f7+/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAED/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAIcALAAAAAAIACAAAAjKAA8JHEhwIIoRHgaqAGEBggKBKTg8OBAhxCEWHhw4mMHxUIkJCjh2/MAgg8gZhzgYgHGy4EAPI1AUVADBAggVA0NEOPCgQwqBIjV6YHHoZIIJJoqKxMDgg1KOLwxwOCSiwoATI7KOIKEBwYMVWlV4kCCAgoqsh0hsaABAxgoQAkNcWBAAwQaBJkJkiKCgAEGEGyy4LKE16wkCFURoZfEAgQYSWVVQECDBw8IVMgA02EDi0AYEARZcsHiogIIIGUIkPWRhA8y/JVwGBAA7"

/***/ }),
/* 379 */
/***/ (function(module, exports) {

// 7.2.1 RequireObjectCoercible(argument)
module.exports = function (it) {
  if (it == undefined) throw TypeError("Can't call method on  " + it);
  return it;
};


/***/ }),
/* 380 */
/***/ (function(module, exports) {

var id = 0;
var px = Math.random();
module.exports = function (key) {
  return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
};


/***/ }),
/* 381 */
/***/ (function(module, exports, __webpack_require__) {

// optional / simple context binding
var aFunction = __webpack_require__(382);
module.exports = function (fn, that, length) {
  aFunction(fn);
  if (that === undefined) return fn;
  switch (length) {
    case 1: return function (a) {
      return fn.call(that, a);
    };
    case 2: return function (a, b) {
      return fn.call(that, a, b);
    };
    case 3: return function (a, b, c) {
      return fn.call(that, a, b, c);
    };
  }
  return function (/* ...args */) {
    return fn.apply(that, arguments);
  };
};


/***/ }),
/* 382 */
/***/ (function(module, exports) {

module.exports = function (it) {
  if (typeof it != 'function') throw TypeError(it + ' is not a function!');
  return it;
};


/***/ }),
/* 383 */
/***/ (function(module, exports) {

module.exports = function (bitmap, value) {
  return {
    enumerable: !(bitmap & 1),
    configurable: !(bitmap & 2),
    writable: !(bitmap & 4),
    value: value
  };
};


/***/ }),
/* 384 */
/***/ (function(module, exports, __webpack_require__) {

var def = __webpack_require__(165).f;
var has = __webpack_require__(171);
var TAG = __webpack_require__(126)('toStringTag');

module.exports = function (it, tag, stat) {
  if (it && !has(it = stat ? it : it.prototype, TAG)) def(it, TAG, { configurable: true, value: tag });
};


/***/ }),
/* 385 */
/***/ (function(module, exports) {

exports.f = {}.propertyIsEnumerable;


/***/ }),
/* 386 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M22.2,38h-2.4c-0.4,0-0.6-0.1-0.9-0.3c-0.2-0.2-0.3-0.5-0.3-0.9V23.4H5.2c-0.4,0-0.6-0.1-0.9-0.3C4.1,22.8,4,22.6,4,22.2 v-2.4c0-0.4,0.1-0.6,0.3-0.9c0.2-0.2,0.5-0.3,0.9-0.3h13.3V5.2c0-0.4,0.1-0.6,0.3-0.9C19.1,4.1,19.4,4,19.8,4h2.4 c0.4,0,0.6,0.1,0.9,0.3c0.2,0.2,0.3,0.5,0.3,0.9v13.3h13.3c0.4,0,0.6,0.1,0.9,0.3c0.2,0.2,0.3,0.5,0.3,0.9v2.4 c0,0.4-0.1,0.6-0.3,0.9s-0.5,0.3-0.9,0.3H23.4v13.3c0,0.4-0.1,0.6-0.3,0.9S22.6,38,22.2,38z'/%3E %3C/svg%3E\""

/***/ }),
/* 387 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='5 5 32.5 32.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='27.5' height='27.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23000000;%7D %3C/style%3E %3Cpath id='red_x5F_cross_x5F_big_1_' class='st0' d='M28.7,27.5l-1.2,1.2c-0.2,0.2-0.4,0.2-0.6,0.2s-0.4-0.1-0.6-0.2l-5-5l-5,5 c-0.2,0.2-0.4,0.2-0.6,0.2s-0.4-0.1-0.6-0.2l-1.2-1.2c-0.2-0.2-0.2-0.4-0.2-0.6s0.1-0.4,0.2-0.6l5-5l-5-5c-0.2-0.2-0.2-0.4-0.2-0.6 s0.1-0.4,0.2-0.6l1.2-1.2c0.2-0.2,0.4-0.2,0.6-0.2s0.4,0.1,0.6,0.2l5,5l5-5c0.2-0.2,0.4-0.2,0.6-0.2s0.4,0.1,0.6,0.2l1.2,1.2 c0.2,0.2,0.2,0.4,0.2,0.6s-0.1,0.4-0.2,0.6l-5,5l5,5c0.2,0.2,0.2,0.4,0.2,0.6S28.9,27.3,28.7,27.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 388 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M27.8,35.6H3.5V6.4h14.6v7.9c0,0.5,0.2,0.9,0.5,1.3c0.4,0.4,0.8,0.5,1.3,0.5h7.9v2h2.4v-3.8c0-0.5-0.1-1.1-0.4-1.7 c-0.3-0.6-0.6-1.1-0.9-1.4L23,5.3c-0.4-0.4-0.8-0.7-1.4-0.9C21,4.1,20.4,4,19.9,4h-17C2.4,4,1.9,4.2,1.6,4.5 C1.2,4.9,1.1,5.3,1.1,5.8v30.4c0,0.5,0.2,0.9,0.5,1.3S2.4,38,2.9,38h25.5c0.5,0,0.9-0.2,1.3-0.5s0.5-0.8,0.5-1.3v-3.1h-2.4V35.6z M20.5,6.6c0.4,0.1,0.6,0.3,0.8,0.4l5.9,5.9c0.2,0.2,0.3,0.4,0.4,0.8h-7.1V6.6z M26.7,29.9l2-1.8l-2.3-2.6l-2,1.8l0,0.9l1.6,0.1 l-0.1,1.6L26.7,29.9z M34.4,18.7c-0.2-0.2-0.3-0.2-0.5,0l-6,5.4c-0.2,0.2-0.2,0.4,0,0.5c0.2,0.2,0.3,0.2,0.5,0l6-5.4 C34.5,19,34.5,18.9,34.4,18.7z M34.2,16.3l4.4,4.9L27.2,31.5l-4.7-0.2l0.2-4.7L34.2,16.3z M41.3,18.8l-1.6,1.4l-4.4-4.9l1.6-1.4 c0.3-0.3,0.7-0.4,1.1-0.4c0.4,0,0.8,0.2,1.1,0.5l2.3,2.6c0.3,0.3,0.4,0.7,0.4,1.1C41.8,18.2,41.6,18.6,41.3,18.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 389 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links' d='M13,21.2c0-0.2,0.1-0.5,0.3-0.7L26.5,7.3C26.7,7.1,26.9,7,27.2,7c0.2,0,0.5,0.1,0.7,0.3l1.4,1.4 c0.2,0.2,0.3,0.4,0.3,0.7c0,0.2-0.1,0.5-0.3,0.7L18.1,21.2l11.2,11.2c0.2,0.2,0.3,0.4,0.3,0.7c0,0.2-0.1,0.5-0.3,0.7l-1.4,1.4 c-0.2,0.2-0.4,0.3-0.7,0.3c-0.2,0-0.5-0.1-0.7-0.3L13.3,21.8C13.1,21.6,13,21.4,13,21.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 390 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M20.9,25.5c0,0.8-0.2,1.4-0.7,2s-1,0.8-1.7,0.8H9.1c-0.7,0-1.2-0.3-1.7-0.8s-0.7-1.2-0.7-2s0.1-1.5,0.2-2.2s0.3-1.3,0.5-1.9 C7.7,20.8,8,20.3,8.5,20c0.5-0.4,1.1-0.5,1.8-0.5c0.1,0,0.3,0.2,0.6,0.3s0.5,0.3,0.7,0.4s0.4,0.2,0.7,0.3c0.3,0.1,0.5,0.2,0.8,0.3 c0.3,0.1,0.5,0.1,0.8,0.1s0.5,0,0.8-0.1s0.5-0.1,0.8-0.3c0.3-0.1,0.5-0.2,0.7-0.3c0.2-0.1,0.4-0.2,0.7-0.4c0.3-0.2,0.5-0.3,0.6-0.3 c0.7,0,1.3,0.2,1.8,0.5c0.5,0.4,0.9,0.8,1.1,1.4c0.3,0.6,0.4,1.2,0.5,1.9C20.8,24,20.9,24.7,20.9,25.5z M18,15.9 c0,1.2-0.4,2.1-1.2,3c-0.8,0.8-1.8,1.2-3,1.2s-2.1-0.4-3-1.2s-1.2-1.8-1.2-3s0.4-2.1,1.2-3c0.8-0.8,1.8-1.2,3-1.2s2.1,0.4,3,1.2 C17.6,13.8,18,14.8,18,15.9z M37.4,32.4V10c0-0.2-0.1-0.3-0.2-0.4c-0.1-0.1-0.3-0.2-0.4-0.2H5c-0.2,0-0.3,0.1-0.4,0.2 C4.4,9.7,4.4,9.8,4.4,10v22.4c0,0.2,0.1,0.3,0.2,0.4C4.7,32.9,4.8,33,5,33h6.5v-1.8c0-0.2,0.1-0.3,0.2-0.4c0.1-0.1,0.3-0.2,0.4-0.2 h1.2c0.2,0,0.3,0.1,0.4,0.2c0.1,0.1,0.2,0.3,0.2,0.4V33H28v-1.8c0-0.2,0.1-0.3,0.2-0.4s0.3-0.2,0.4-0.2h1.2c0.2,0,0.3,0.1,0.4,0.2 s0.2,0.3,0.2,0.4V33h6.5c0.2,0,0.3-0.1,0.4-0.2C37.4,32.7,37.4,32.6,37.4,32.4z M39.8,10v22.4c0,0.8-0.3,1.5-0.9,2.1 c-0.6,0.6-1.3,0.9-2.1,0.9H5c-0.8,0-1.5-0.3-2.1-0.9C2.3,33.9,2,33.2,2,32.4V10c0-0.8,0.3-1.5,0.9-2.1S4.1,7,5,7h31.9 c0.8,0,1.5,0.3,2.1,0.9C39.5,8.4,39.8,9.1,39.8,10z M23.4,21.1c-0.1-0.1-0.2-0.3-0.2-0.4v-1.2c0-0.2,0.1-0.3,0.2-0.4 s0.3-0.2,0.4-0.2h4.3v-4.3c0-0.2,0.1-0.3,0.2-0.4s0.3-0.2,0.4-0.2h1.2c0.2,0,0.3,0.1,0.4,0.2s0.2,0.3,0.2,0.4v4.3h4.3 c0.2,0,0.3,0.1,0.4,0.2s0.2,0.3,0.2,0.4v1.2c0,0.2-0.1,0.3-0.2,0.4s-0.3,0.2-0.4,0.2h-4.3v4.3c0,0.2-0.1,0.3-0.2,0.4 s-0.3,0.2-0.4,0.2h-1.2c-0.2,0-0.3-0.1-0.4-0.2s-0.2-0.3-0.2-0.4v-4.3h-4.3C23.7,21.2,23.5,21.2,23.4,21.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 391 */,
/* 392 */,
/* 393 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQASAIcAAN7j5vDz8/P19fX39/f5+fn7+/z8/f3+/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABABIAAAgQAAEEEDCAQAEDBxAoXMgwIAA7"

/***/ }),
/* 394 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAsAYcAAID/gLfI18LY8OPr9QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAAABACwBAAgrAAMMEECwoMGDCBMqXHgQgMOHECNKnEixosWLGDNq3Mixo8ePIENuHBAgIAA7"

/***/ }),
/* 395 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64, "

/***/ }),
/* 396 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhIwAFAIcAAENDRUD/QNHR0ezs7AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAjAAUAAAg1AAMIDCCgoMGDCBMmHMhQwICHECNCBCCx4kMBDAlarAig40aJGAU6/Dixo0eSFwkqXMmyZUAAOw=="

/***/ }),
/* 397 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhIwAFAIcAAENDRUD/QNHR0ezs7AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAjAAUAAAg1AAUIHEiwoMGDBwMIGMCwocOGACJGfEiRoYAAGBdWfChx48OLGDN6dAhgZEOQITMiXLkyZUAAOw=="

/***/ }),
/* 398 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAgAIcAAMHBwcjIyNvb2+Tk5Ozs7O7u7u/v7/Dw8PHx8fPz8/T09PX19fb29vf39/j4+Pn5+fr6+vz8/P39/f7+/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABACAAAAgkABkMCCCBgkEKBRIWYABAAAEKEyREgPDAQQMGCxQkQHDAQIGAADs="

/***/ }),
/* 399 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1161);

/***/ }),
/* 400 */
/***/ (function(module, exports) {

// 7.1.4 ToInteger
var ceil = Math.ceil;
var floor = Math.floor;
module.exports = function (it) {
  return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
};


/***/ }),
/* 401 */
/***/ (function(module, exports, __webpack_require__) {

var shared = __webpack_require__(402)('keys');
var uid = __webpack_require__(380);
module.exports = function (key) {
  return shared[key] || (shared[key] = uid(key));
};


/***/ }),
/* 402 */
/***/ (function(module, exports, __webpack_require__) {

var core = __webpack_require__(119);
var global = __webpack_require__(122);
var SHARED = '__core-js_shared__';
var store = global[SHARED] || (global[SHARED] = {});

(module.exports = function (key, value) {
  return store[key] || (store[key] = value !== undefined ? value : {});
})('versions', []).push({
  version: core.version,
  mode: __webpack_require__(238) ? 'pure' : 'global',
  copyright: '© 2019 Denis Pushkarev (zloirock.ru)'
});


/***/ }),
/* 403 */
/***/ (function(module, exports) {

// IE 8- don't enum bug keys
module.exports = (
  'constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf'
).split(',');


/***/ }),
/* 404 */
/***/ (function(module, exports, __webpack_require__) {

var isObject = __webpack_require__(174);
var document = __webpack_require__(122).document;
// typeof document.createElement is 'object' in old IE
var is = isObject(document) && isObject(document.createElement);
module.exports = function (it) {
  return is ? document.createElement(it) : {};
};


/***/ }),
/* 405 */
/***/ (function(module, exports, __webpack_require__) {

// 7.1.1 ToPrimitive(input [, PreferredType])
var isObject = __webpack_require__(174);
// instead of the ES6 spec version, we didn't implement @@toPrimitive case
// and the second argument - flag - preferred type is a string
module.exports = function (it, S) {
  if (!isObject(it)) return it;
  var fn, val;
  if (S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
  if (typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it))) return val;
  if (!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it))) return val;
  throw TypeError("Can't convert object to primitive value");
};


/***/ }),
/* 406 */
/***/ (function(module, exports, __webpack_require__) {

var global = __webpack_require__(122);
var core = __webpack_require__(119);
var LIBRARY = __webpack_require__(238);
var wksExt = __webpack_require__(615);
var defineProperty = __webpack_require__(165).f;
module.exports = function (name) {
  var $Symbol = core.Symbol || (core.Symbol = LIBRARY ? {} : global.Symbol || {});
  if (name.charAt(0) != '_' && !(name in $Symbol)) defineProperty($Symbol, name, { value: wksExt.f(name) });
};


/***/ }),
/* 407 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

// 25.4.1.5 NewPromiseCapability(C)
var aFunction = __webpack_require__(382);

function PromiseCapability(C) {
  var resolve, reject;
  this.promise = new C(function ($$resolve, $$reject) {
    if (resolve !== undefined || reject !== undefined) throw TypeError('Bad Promise constructor');
    resolve = $$resolve;
    reject = $$reject;
  });
  this.resolve = aFunction(resolve);
  this.reject = aFunction(reject);
}

module.exports.f = function (C) {
  return new PromiseCapability(C);
};


/***/ }),
/* 408 */
/***/ (function(module, exports) {

Ext.ns('Ext.ux');
/**
 * plugin to insert additional registered items into a container
 *
 * @namespace   Ext.ux
 * @class       Ext.ux.ItemRegistry
 * @autor       Cornelius Weiss <c.weiss@metaways.de>
 * @license     BSD, MIT and GPL
 *
 * @example
// register 'additional item' for myDialog
Ext.ux.ItemRegistry.registerItem('myDialog', 'add-item-xtype', 20);

// in myDialog use itemRegistyPlugin
myDialog = Ext.extend(Ext.Container, {
    ...
    plugins: [{
        ptype: 'ux.itemregistry',
        key:   'myDialog'
    }]
})
 */

Ext.ux.ItemRegistry = function (config) {
  Ext.apply(this, config);
};
/**
 * @static
 * @private
 */


Ext.ux.ItemRegistry.itemMap = {};
Ext.ux.ItemRegistry.AUTO_ID = 1;
/**
 * registers an item for a given key
 * @static
 * 
 * @param {String|Ext.Component|Object} key
 * @param {String/Constructor/Object} item
 * @param {Number} pos (optional)
 */

Ext.ux.ItemRegistry.registerItem = function (key, item, pos) {
  var _ = window.lodash;

  if (_.isString(key)) {
    if (!Ext.ux.ItemRegistry.itemMap.hasOwnProperty(key)) {
      Ext.ux.ItemRegistry.itemMap[key] = [];
    }

    Ext.ux.ItemRegistry.itemMap[key].push({
      item: item,
      pos: pos
    });
  } else {
    // initialised component
    var dynKey = 'Ext.ux.ItemRegistry-' + ++Ext.ux.ItemRegistry.AUTO_ID,
        plugin = new Ext.ux.ItemRegistry({
      key: dynKey
    });
    Ext.ux.ItemRegistry.registerItem(dynKey, item, pos);
    key.plugins = key.plugins || [];
    key.plugins.push(plugin);

    if (_.get(key, 'items.items')) {
      plugin.init(key);
    }
  }
};

Ext.ux.ItemRegistry.prototype = {
  /**
   * @cfg {String} key
   * key the items are registered under. If no key is given, the itemId
   * of the component will be used
   */
  key: null,
  init: function init(cmp) {
    this.cmp = cmp;

    if (!this.key) {
      this.key = cmp.getItemId();
    } // give static item pos to existing items


    this.cmp.items.each(function (item, idx) {
      if (!item.hasOwnProperty('registerdItemPos')) {
        item.registerdItemPos = idx * 10;
      }
    }, this);
    var regItems = Ext.ux.ItemRegistry.itemMap[this.key] || [];
    Ext.each(regItems, function (reg) {
      // key hat / -> find item defined by first part and register item,regItem,possuffix -> return
      var path = String(reg.pos).split('/');

      if (path.length > 1) {
        var idx = +path.shift(),
            item = this.cmp.items.get(idx);

        if (item) {
          // console.info(path.join('/'))
          Ext.ux.ItemRegistry.registerItem(this.cmp.items.get(idx), reg.item, path.join('/'));
        } else {
          console.warn('cannot register for path - ' + path.join('/'));
        }

        return;
      }

      var addItem = this.getItem(reg),
          addPos = null;

      if (!addItem) {
        console.warn('item not found');
        return;
      } // insert item 


      this.cmp.items.each(function (item, idx) {
        if (addItem.registerdItemPos < item.registerdItemPos) {
          this.cmp.insert(idx, addItem);
          addPos = idx;
          return false;
        }

        return true;
      }, this);

      if (!Ext.isNumber(addPos)) {
        this.cmp.add(addItem);
      }
    }, this);
  },
  getItem: function getItem(reg) {
    var def = reg.item,
        item;

    if (typeof def === 'function') {
      try {
        item = new def(this.config);
      } catch (error) {
        console.error('Ext.ux.ItemRegistry::getItem failed to create');
        console.error(error);
        return;
      }
    } else {
      if (Ext.isString(def)) {
        def = {
          xtype: def
        };
      }

      item = this.cmp.lookupComponent(def);
    }

    item.registerdItemPos = reg.pos ? reg.pos : this.cmp.items.length * 10;
    return item;
  }
};
Ext.ComponentMgr.registerPlugin('ux.itemregistry', Ext.ux.ItemRegistry);
/* test - uncomment to run
if (! window.lodash) {
    window.lodash = _;
}

Ext.onReady(function() {
    var testWin = new Ext.Window({
        width: 640,
        height: 480,
        layout: 'fit',
        title: 'ux.itemregistry test',
        items: [{
            xtype: 'tabpanel',
            activeTab: 0,
            border: false,
            defaults: {border: false},
            itemId: 'testWin',
            plugins: ['ux.itemregistry'],
            items: [{
                title: 'basepanel',
                html: 'basepanel'
            }, {
                title: 'no pos',
                html: 'no pos'
            }, {
                title: 'pos 50',
                html: 'pos 50',
                registerdItemPos: 50
            }]
        }]
    });
    testWin.show();

    Ext.ux.ItemRegistry.registerItem(testWin.items.get(0), {
        xtype: 'panel',
        title: 'key-cmp',
        html: 'register item in an existing component'
    }, 80);
});

itemRegTestPanel20 = Ext.extend(Ext.Panel, {
    title: 'add panel pos 20',
    html: 'add panel pos 20',

    initComponent: function() {
        // example how to hook in owner
        this.on('added', function(me, owner, pos) {
            owner.on('tabchange', function() {
                console.log('tabchange');
            })
        }),

        itemRegTestPanel20.superclass.initComponent.call(this);
    }
});
Ext.ux.ItemRegistry.registerItem('testWin', itemRegTestPanel20, 20);

itemRegTestPanel60 = {
    xtype: 'panel',
    title: 'add panel pos 60',
    items: [{items: [{html: 'add panel pos 60'}]}]
};
Ext.ux.ItemRegistry.registerItem('testWin', itemRegTestPanel60, 60);
Ext.ux.ItemRegistry.registerItem(itemRegTestPanel60, {html: 'registered in component config'}, 20);
Ext.ux.ItemRegistry.registerItem('testWin', {html: 'registered with path position '}, '4/0/20');
*/

/***/ }),
/* 409 */
/***/ (function(module, exports, __webpack_require__) {

// Generated by CoffeeScript 2.4.0
var wcwidth;

wcwidth = __webpack_require__(410);

module.exports = function(text, length, options) {
  var escapecolor, invert, pad, padlength, textnocolors;
  if (options == null) {
    options = {};
  }
  invert = typeof text === 'number';
  if (invert) {
    [length, text] = [text, length];
  }
  if (typeof options === 'string') {
    options = {
      char: options
    };
  }
  if (options.char == null) {
    options.char = ' ';
  }
  if (options.strip == null) {
    options.strip = false;
  }
  if (typeof text !== 'string') {
    text = text.toString();
  }
  textnocolors = null;
  pad = '';
  if (options.colors) {
    escapecolor = /\x1B\[(?:[0-9]{1,2}(?:;[0-9]{1,2})?)?[m|K]/g;
    textnocolors = text.replace(escapecolor, '');
  }
  padlength = options.fixed_width ? length - (textnocolors || text).length : length - wcwidth.config(options.wcwidth_options)(textnocolors || text);
  if (padlength < 0) {
    if (options.strip) {
      if (invert) {
        return text.substr(length * -1);
      } else {
        return text.substr(0, length);
      }
    }
    return text;
  }
  pad += options.char.repeat(padlength);
  if (invert) {
    return pad + text;
  } else {
    return text + pad;
  }
};


/***/ }),
/* 410 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var defaults = __webpack_require__(411)
var combining = __webpack_require__(415)

var DEFAULTS = {
  nul: 0,
  control: 0
}

module.exports = function wcwidth(str) {
  return wcswidth(str, DEFAULTS)
}

module.exports.config = function(opts) {
  opts = defaults(opts || {}, DEFAULTS)
  return function wcwidth(str) {
    return wcswidth(str, opts)
  }
}

/*
 *  The following functions define the column width of an ISO 10646
 *  character as follows:
 *  - The null character (U+0000) has a column width of 0.
 *  - Other C0/C1 control characters and DEL will lead to a return value
 *    of -1.
 *  - Non-spacing and enclosing combining characters (general category
 *    code Mn or Me in the
 *    Unicode database) have a column width of 0.
 *  - SOFT HYPHEN (U+00AD) has a column width of 1.
 *  - Other format characters (general category code Cf in the Unicode
 *    database) and ZERO WIDTH
 *    SPACE (U+200B) have a column width of 0.
 *  - Hangul Jamo medial vowels and final consonants (U+1160-U+11FF)
 *    have a column width of 0.
 *  - Spacing characters in the East Asian Wide (W) or East Asian
 *    Full-width (F) category as
 *    defined in Unicode Technical Report #11 have a column width of 2.
 *  - All remaining characters (including all printable ISO 8859-1 and
 *    WGL4 characters, Unicode control characters, etc.) have a column
 *    width of 1.
 *  This implementation assumes that characters are encoded in ISO 10646.
*/

function wcswidth(str, opts) {
  if (typeof str !== 'string') return wcwidth(str, opts)

  var s = 0
  for (var i = 0; i < str.length; i++) {
    var n = wcwidth(str.charCodeAt(i), opts)
    if (n < 0) return -1
    s += n
  }

  return s
}

function wcwidth(ucs, opts) {
  // test for 8-bit control characters
  if (ucs === 0) return opts.nul
  if (ucs < 32 || (ucs >= 0x7f && ucs < 0xa0)) return opts.control

  // binary search in table of non-spacing characters
  if (bisearch(ucs)) return 0

  // if we arrive here, ucs is not a combining or C0/C1 control character
  return 1 +
      (ucs >= 0x1100 &&
       (ucs <= 0x115f ||                       // Hangul Jamo init. consonants
        ucs == 0x2329 || ucs == 0x232a ||
        (ucs >= 0x2e80 && ucs <= 0xa4cf &&
         ucs != 0x303f) ||                     // CJK ... Yi
        (ucs >= 0xac00 && ucs <= 0xd7a3) ||    // Hangul Syllables
        (ucs >= 0xf900 && ucs <= 0xfaff) ||    // CJK Compatibility Ideographs
        (ucs >= 0xfe10 && ucs <= 0xfe19) ||    // Vertical forms
        (ucs >= 0xfe30 && ucs <= 0xfe6f) ||    // CJK Compatibility Forms
        (ucs >= 0xff00 && ucs <= 0xff60) ||    // Fullwidth Forms
        (ucs >= 0xffe0 && ucs <= 0xffe6) ||
        (ucs >= 0x20000 && ucs <= 0x2fffd) ||
        (ucs >= 0x30000 && ucs <= 0x3fffd)));
}

function bisearch(ucs) {
  var min = 0
  var max = combining.length - 1
  var mid

  if (ucs < combining[0][0] || ucs > combining[max][1]) return false

  while (max >= min) {
    mid = Math.floor((min + max) / 2)
    if (ucs > combining[mid][1]) min = mid + 1
    else if (ucs < combining[mid][0]) max = mid - 1
    else return true
  }

  return false
}


/***/ }),
/* 411 */
/***/ (function(module, exports, __webpack_require__) {

var clone = __webpack_require__(412);

module.exports = function(options, defaults) {
  options = options || {};

  Object.keys(defaults).forEach(function(key) {
    if (typeof options[key] === 'undefined') {
      options[key] = clone(defaults[key]);
    }
  });

  return options;
};

/***/ }),
/* 412 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(Buffer) {var clone = (function() {
'use strict';

/**
 * Clones (copies) an Object using deep copying.
 *
 * This function supports circular references by default, but if you are certain
 * there are no circular references in your object, you can save some CPU time
 * by calling clone(obj, false).
 *
 * Caution: if `circular` is false and `parent` contains circular references,
 * your program may enter an infinite loop and crash.
 *
 * @param `parent` - the object to be cloned
 * @param `circular` - set to true if the object to be cloned may contain
 *    circular references. (optional - true by default)
 * @param `depth` - set to a number if the object is only to be cloned to
 *    a particular depth. (optional - defaults to Infinity)
 * @param `prototype` - sets the prototype to be used when cloning an object.
 *    (optional - defaults to parent prototype).
*/
function clone(parent, circular, depth, prototype) {
  var filter;
  if (typeof circular === 'object') {
    depth = circular.depth;
    prototype = circular.prototype;
    filter = circular.filter;
    circular = circular.circular
  }
  // maintain two arrays for circular references, where corresponding parents
  // and children have the same index
  var allParents = [];
  var allChildren = [];

  var useBuffer = typeof Buffer != 'undefined';

  if (typeof circular == 'undefined')
    circular = true;

  if (typeof depth == 'undefined')
    depth = Infinity;

  // recurse this function so we don't reset allParents and allChildren
  function _clone(parent, depth) {
    // cloning null always returns null
    if (parent === null)
      return null;

    if (depth == 0)
      return parent;

    var child;
    var proto;
    if (typeof parent != 'object') {
      return parent;
    }

    if (clone.__isArray(parent)) {
      child = [];
    } else if (clone.__isRegExp(parent)) {
      child = new RegExp(parent.source, __getRegExpFlags(parent));
      if (parent.lastIndex) child.lastIndex = parent.lastIndex;
    } else if (clone.__isDate(parent)) {
      child = new Date(parent.getTime());
    } else if (useBuffer && Buffer.isBuffer(parent)) {
      if (Buffer.allocUnsafe) {
        // Node.js >= 4.5.0
        child = Buffer.allocUnsafe(parent.length);
      } else {
        // Older Node.js versions
        child = new Buffer(parent.length);
      }
      parent.copy(child);
      return child;
    } else {
      if (typeof prototype == 'undefined') {
        proto = Object.getPrototypeOf(parent);
        child = Object.create(proto);
      }
      else {
        child = Object.create(prototype);
        proto = prototype;
      }
    }

    if (circular) {
      var index = allParents.indexOf(parent);

      if (index != -1) {
        return allChildren[index];
      }
      allParents.push(parent);
      allChildren.push(child);
    }

    for (var i in parent) {
      var attrs;
      if (proto) {
        attrs = Object.getOwnPropertyDescriptor(proto, i);
      }

      if (attrs && attrs.set == null) {
        continue;
      }
      child[i] = _clone(parent[i], depth - 1);
    }

    return child;
  }

  return _clone(parent, depth);
}

/**
 * Simple flat clone using prototype, accepts only objects, usefull for property
 * override on FLAT configuration object (no nested props).
 *
 * USE WITH CAUTION! This may not behave as you wish if you do not know how this
 * works.
 */
clone.clonePrototype = function clonePrototype(parent) {
  if (parent === null)
    return null;

  var c = function () {};
  c.prototype = parent;
  return new c();
};

// private utility functions

function __objToStr(o) {
  return Object.prototype.toString.call(o);
};
clone.__objToStr = __objToStr;

function __isDate(o) {
  return typeof o === 'object' && __objToStr(o) === '[object Date]';
};
clone.__isDate = __isDate;

function __isArray(o) {
  return typeof o === 'object' && __objToStr(o) === '[object Array]';
};
clone.__isArray = __isArray;

function __isRegExp(o) {
  return typeof o === 'object' && __objToStr(o) === '[object RegExp]';
};
clone.__isRegExp = __isRegExp;

function __getRegExpFlags(re) {
  var flags = '';
  if (re.global) flags += 'g';
  if (re.ignoreCase) flags += 'i';
  if (re.multiline) flags += 'm';
  return flags;
};
clone.__getRegExpFlags = __getRegExpFlags;

return clone;
})();

if ( true && module.exports) {
  module.exports = clone;
}

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 413 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


exports.byteLength = byteLength
exports.toByteArray = toByteArray
exports.fromByteArray = fromByteArray

var lookup = []
var revLookup = []
var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array

var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'
for (var i = 0, len = code.length; i < len; ++i) {
  lookup[i] = code[i]
  revLookup[code.charCodeAt(i)] = i
}

// Support decoding URL-safe base64 strings, as Node.js does.
// See: https://en.wikipedia.org/wiki/Base64#URL_applications
revLookup['-'.charCodeAt(0)] = 62
revLookup['_'.charCodeAt(0)] = 63

function getLens (b64) {
  var len = b64.length

  if (len % 4 > 0) {
    throw new Error('Invalid string. Length must be a multiple of 4')
  }

  // Trim off extra bytes after placeholder bytes are found
  // See: https://github.com/beatgammit/base64-js/issues/42
  var validLen = b64.indexOf('=')
  if (validLen === -1) validLen = len

  var placeHoldersLen = validLen === len
    ? 0
    : 4 - (validLen % 4)

  return [validLen, placeHoldersLen]
}

// base64 is 4/3 + up to two characters of the original data
function byteLength (b64) {
  var lens = getLens(b64)
  var validLen = lens[0]
  var placeHoldersLen = lens[1]
  return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
}

function _byteLength (b64, validLen, placeHoldersLen) {
  return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen
}

function toByteArray (b64) {
  var tmp
  var lens = getLens(b64)
  var validLen = lens[0]
  var placeHoldersLen = lens[1]

  var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen))

  var curByte = 0

  // if there are placeholders, only get up to the last complete 4 chars
  var len = placeHoldersLen > 0
    ? validLen - 4
    : validLen

  for (var i = 0; i < len; i += 4) {
    tmp =
      (revLookup[b64.charCodeAt(i)] << 18) |
      (revLookup[b64.charCodeAt(i + 1)] << 12) |
      (revLookup[b64.charCodeAt(i + 2)] << 6) |
      revLookup[b64.charCodeAt(i + 3)]
    arr[curByte++] = (tmp >> 16) & 0xFF
    arr[curByte++] = (tmp >> 8) & 0xFF
    arr[curByte++] = tmp & 0xFF
  }

  if (placeHoldersLen === 2) {
    tmp =
      (revLookup[b64.charCodeAt(i)] << 2) |
      (revLookup[b64.charCodeAt(i + 1)] >> 4)
    arr[curByte++] = tmp & 0xFF
  }

  if (placeHoldersLen === 1) {
    tmp =
      (revLookup[b64.charCodeAt(i)] << 10) |
      (revLookup[b64.charCodeAt(i + 1)] << 4) |
      (revLookup[b64.charCodeAt(i + 2)] >> 2)
    arr[curByte++] = (tmp >> 8) & 0xFF
    arr[curByte++] = tmp & 0xFF
  }

  return arr
}

function tripletToBase64 (num) {
  return lookup[num >> 18 & 0x3F] +
    lookup[num >> 12 & 0x3F] +
    lookup[num >> 6 & 0x3F] +
    lookup[num & 0x3F]
}

function encodeChunk (uint8, start, end) {
  var tmp
  var output = []
  for (var i = start; i < end; i += 3) {
    tmp =
      ((uint8[i] << 16) & 0xFF0000) +
      ((uint8[i + 1] << 8) & 0xFF00) +
      (uint8[i + 2] & 0xFF)
    output.push(tripletToBase64(tmp))
  }
  return output.join('')
}

function fromByteArray (uint8) {
  var tmp
  var len = uint8.length
  var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes
  var parts = []
  var maxChunkLength = 16383 // must be multiple of 3

  // go through the array every three bytes, we'll deal with trailing stuff later
  for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) {
    parts.push(encodeChunk(
      uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength)
    ))
  }

  // pad the end with zeros, but make sure to not forget the extra bytes
  if (extraBytes === 1) {
    tmp = uint8[len - 1]
    parts.push(
      lookup[tmp >> 2] +
      lookup[(tmp << 4) & 0x3F] +
      '=='
    )
  } else if (extraBytes === 2) {
    tmp = (uint8[len - 2] << 8) + uint8[len - 1]
    parts.push(
      lookup[tmp >> 10] +
      lookup[(tmp >> 4) & 0x3F] +
      lookup[(tmp << 2) & 0x3F] +
      '='
    )
  }

  return parts.join('')
}


/***/ }),
/* 414 */
/***/ (function(module, exports) {

exports.read = function (buffer, offset, isLE, mLen, nBytes) {
  var e, m
  var eLen = (nBytes * 8) - mLen - 1
  var eMax = (1 << eLen) - 1
  var eBias = eMax >> 1
  var nBits = -7
  var i = isLE ? (nBytes - 1) : 0
  var d = isLE ? -1 : 1
  var s = buffer[offset + i]

  i += d

  e = s & ((1 << (-nBits)) - 1)
  s >>= (-nBits)
  nBits += eLen
  for (; nBits > 0; e = (e * 256) + buffer[offset + i], i += d, nBits -= 8) {}

  m = e & ((1 << (-nBits)) - 1)
  e >>= (-nBits)
  nBits += mLen
  for (; nBits > 0; m = (m * 256) + buffer[offset + i], i += d, nBits -= 8) {}

  if (e === 0) {
    e = 1 - eBias
  } else if (e === eMax) {
    return m ? NaN : ((s ? -1 : 1) * Infinity)
  } else {
    m = m + Math.pow(2, mLen)
    e = e - eBias
  }
  return (s ? -1 : 1) * m * Math.pow(2, e - mLen)
}

exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
  var e, m, c
  var eLen = (nBytes * 8) - mLen - 1
  var eMax = (1 << eLen) - 1
  var eBias = eMax >> 1
  var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0)
  var i = isLE ? 0 : (nBytes - 1)
  var d = isLE ? 1 : -1
  var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0

  value = Math.abs(value)

  if (isNaN(value) || value === Infinity) {
    m = isNaN(value) ? 1 : 0
    e = eMax
  } else {
    e = Math.floor(Math.log(value) / Math.LN2)
    if (value * (c = Math.pow(2, -e)) < 1) {
      e--
      c *= 2
    }
    if (e + eBias >= 1) {
      value += rt / c
    } else {
      value += rt * Math.pow(2, 1 - eBias)
    }
    if (value * c >= 2) {
      e++
      c /= 2
    }

    if (e + eBias >= eMax) {
      m = 0
      e = eMax
    } else if (e + eBias >= 1) {
      m = ((value * c) - 1) * Math.pow(2, mLen)
      e = e + eBias
    } else {
      m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen)
      e = 0
    }
  }

  for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}

  e = (e << mLen) | m
  eLen += mLen
  for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}

  buffer[offset + i - d] |= s * 128
}


/***/ }),
/* 415 */
/***/ (function(module, exports) {

module.exports = [
    [ 0x0300, 0x036F ], [ 0x0483, 0x0486 ], [ 0x0488, 0x0489 ],
    [ 0x0591, 0x05BD ], [ 0x05BF, 0x05BF ], [ 0x05C1, 0x05C2 ],
    [ 0x05C4, 0x05C5 ], [ 0x05C7, 0x05C7 ], [ 0x0600, 0x0603 ],
    [ 0x0610, 0x0615 ], [ 0x064B, 0x065E ], [ 0x0670, 0x0670 ],
    [ 0x06D6, 0x06E4 ], [ 0x06E7, 0x06E8 ], [ 0x06EA, 0x06ED ],
    [ 0x070F, 0x070F ], [ 0x0711, 0x0711 ], [ 0x0730, 0x074A ],
    [ 0x07A6, 0x07B0 ], [ 0x07EB, 0x07F3 ], [ 0x0901, 0x0902 ],
    [ 0x093C, 0x093C ], [ 0x0941, 0x0948 ], [ 0x094D, 0x094D ],
    [ 0x0951, 0x0954 ], [ 0x0962, 0x0963 ], [ 0x0981, 0x0981 ],
    [ 0x09BC, 0x09BC ], [ 0x09C1, 0x09C4 ], [ 0x09CD, 0x09CD ],
    [ 0x09E2, 0x09E3 ], [ 0x0A01, 0x0A02 ], [ 0x0A3C, 0x0A3C ],
    [ 0x0A41, 0x0A42 ], [ 0x0A47, 0x0A48 ], [ 0x0A4B, 0x0A4D ],
    [ 0x0A70, 0x0A71 ], [ 0x0A81, 0x0A82 ], [ 0x0ABC, 0x0ABC ],
    [ 0x0AC1, 0x0AC5 ], [ 0x0AC7, 0x0AC8 ], [ 0x0ACD, 0x0ACD ],
    [ 0x0AE2, 0x0AE3 ], [ 0x0B01, 0x0B01 ], [ 0x0B3C, 0x0B3C ],
    [ 0x0B3F, 0x0B3F ], [ 0x0B41, 0x0B43 ], [ 0x0B4D, 0x0B4D ],
    [ 0x0B56, 0x0B56 ], [ 0x0B82, 0x0B82 ], [ 0x0BC0, 0x0BC0 ],
    [ 0x0BCD, 0x0BCD ], [ 0x0C3E, 0x0C40 ], [ 0x0C46, 0x0C48 ],
    [ 0x0C4A, 0x0C4D ], [ 0x0C55, 0x0C56 ], [ 0x0CBC, 0x0CBC ],
    [ 0x0CBF, 0x0CBF ], [ 0x0CC6, 0x0CC6 ], [ 0x0CCC, 0x0CCD ],
    [ 0x0CE2, 0x0CE3 ], [ 0x0D41, 0x0D43 ], [ 0x0D4D, 0x0D4D ],
    [ 0x0DCA, 0x0DCA ], [ 0x0DD2, 0x0DD4 ], [ 0x0DD6, 0x0DD6 ],
    [ 0x0E31, 0x0E31 ], [ 0x0E34, 0x0E3A ], [ 0x0E47, 0x0E4E ],
    [ 0x0EB1, 0x0EB1 ], [ 0x0EB4, 0x0EB9 ], [ 0x0EBB, 0x0EBC ],
    [ 0x0EC8, 0x0ECD ], [ 0x0F18, 0x0F19 ], [ 0x0F35, 0x0F35 ],
    [ 0x0F37, 0x0F37 ], [ 0x0F39, 0x0F39 ], [ 0x0F71, 0x0F7E ],
    [ 0x0F80, 0x0F84 ], [ 0x0F86, 0x0F87 ], [ 0x0F90, 0x0F97 ],
    [ 0x0F99, 0x0FBC ], [ 0x0FC6, 0x0FC6 ], [ 0x102D, 0x1030 ],
    [ 0x1032, 0x1032 ], [ 0x1036, 0x1037 ], [ 0x1039, 0x1039 ],
    [ 0x1058, 0x1059 ], [ 0x1160, 0x11FF ], [ 0x135F, 0x135F ],
    [ 0x1712, 0x1714 ], [ 0x1732, 0x1734 ], [ 0x1752, 0x1753 ],
    [ 0x1772, 0x1773 ], [ 0x17B4, 0x17B5 ], [ 0x17B7, 0x17BD ],
    [ 0x17C6, 0x17C6 ], [ 0x17C9, 0x17D3 ], [ 0x17DD, 0x17DD ],
    [ 0x180B, 0x180D ], [ 0x18A9, 0x18A9 ], [ 0x1920, 0x1922 ],
    [ 0x1927, 0x1928 ], [ 0x1932, 0x1932 ], [ 0x1939, 0x193B ],
    [ 0x1A17, 0x1A18 ], [ 0x1B00, 0x1B03 ], [ 0x1B34, 0x1B34 ],
    [ 0x1B36, 0x1B3A ], [ 0x1B3C, 0x1B3C ], [ 0x1B42, 0x1B42 ],
    [ 0x1B6B, 0x1B73 ], [ 0x1DC0, 0x1DCA ], [ 0x1DFE, 0x1DFF ],
    [ 0x200B, 0x200F ], [ 0x202A, 0x202E ], [ 0x2060, 0x2063 ],
    [ 0x206A, 0x206F ], [ 0x20D0, 0x20EF ], [ 0x302A, 0x302F ],
    [ 0x3099, 0x309A ], [ 0xA806, 0xA806 ], [ 0xA80B, 0xA80B ],
    [ 0xA825, 0xA826 ], [ 0xFB1E, 0xFB1E ], [ 0xFE00, 0xFE0F ],
    [ 0xFE20, 0xFE23 ], [ 0xFEFF, 0xFEFF ], [ 0xFFF9, 0xFFFB ],
    [ 0x10A01, 0x10A03 ], [ 0x10A05, 0x10A06 ], [ 0x10A0C, 0x10A0F ],
    [ 0x10A38, 0x10A3A ], [ 0x10A3F, 0x10A3F ], [ 0x1D167, 0x1D169 ],
    [ 0x1D173, 0x1D182 ], [ 0x1D185, 0x1D18B ], [ 0x1D1AA, 0x1D1AD ],
    [ 0x1D242, 0x1D244 ], [ 0xE0001, 0xE0001 ], [ 0xE0020, 0xE007F ],
    [ 0xE0100, 0xE01EF ]
]


/***/ }),
/* 416 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(process) {

// Some environments don't have global Buffer (e.g. React Native).
// Solution would be installing npm modules "buffer" and "stream" explicitly.
var Buffer = __webpack_require__(127).Buffer;

var bomHandling = __webpack_require__(417),
    iconv = module.exports;

// All codecs and aliases are kept here, keyed by encoding name/alias.
// They are lazy loaded in `iconv.getCodec` from `encodings/index.js`.
iconv.encodings = null;

// Characters emitted in case of error.
iconv.defaultCharUnicode = '�';
iconv.defaultCharSingleByte = '?';

// Public API.
iconv.encode = function encode(str, encoding, options) {
    str = "" + (str || ""); // Ensure string.

    var encoder = iconv.getEncoder(encoding, options);

    var res = encoder.write(str);
    var trail = encoder.end();
    
    return (trail && trail.length > 0) ? Buffer.concat([res, trail]) : res;
}

iconv.decode = function decode(buf, encoding, options) {
    if (typeof buf === 'string') {
        if (!iconv.skipDecodeWarning) {
            console.error('Iconv-lite warning: decode()-ing strings is deprecated. Refer to https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding');
            iconv.skipDecodeWarning = true;
        }

        buf = Buffer.from("" + (buf || ""), "binary"); // Ensure buffer.
    }

    var decoder = iconv.getDecoder(encoding, options);

    var res = decoder.write(buf);
    var trail = decoder.end();

    return trail ? (res + trail) : res;
}

iconv.encodingExists = function encodingExists(enc) {
    try {
        iconv.getCodec(enc);
        return true;
    } catch (e) {
        return false;
    }
}

// Legacy aliases to convert functions
iconv.toEncoding = iconv.encode;
iconv.fromEncoding = iconv.decode;

// Search for a codec in iconv.encodings. Cache codec data in iconv._codecDataCache.
iconv._codecDataCache = {};
iconv.getCodec = function getCodec(encoding) {
    if (!iconv.encodings)
        iconv.encodings = __webpack_require__(418); // Lazy load all encoding definitions.
    
    // Canonicalize encoding name: strip all non-alphanumeric chars and appended year.
    var enc = iconv._canonicalizeEncoding(encoding);

    // Traverse iconv.encodings to find actual codec.
    var codecOptions = {};
    while (true) {
        var codec = iconv._codecDataCache[enc];
        if (codec)
            return codec;

        var codecDef = iconv.encodings[enc];

        switch (typeof codecDef) {
            case "string": // Direct alias to other encoding.
                enc = codecDef;
                break;

            case "object": // Alias with options. Can be layered.
                for (var key in codecDef)
                    codecOptions[key] = codecDef[key];

                if (!codecOptions.encodingName)
                    codecOptions.encodingName = enc;
                
                enc = codecDef.type;
                break;

            case "function": // Codec itself.
                if (!codecOptions.encodingName)
                    codecOptions.encodingName = enc;

                // The codec function must load all tables and return object with .encoder and .decoder methods.
                // It'll be called only once (for each different options object).
                codec = new codecDef(codecOptions, iconv);

                iconv._codecDataCache[codecOptions.encodingName] = codec; // Save it to be reused later.
                return codec;

            default:
                throw new Error("Encoding not recognized: '" + encoding + "' (searched as: '"+enc+"')");
        }
    }
}

iconv._canonicalizeEncoding = function(encoding) {
    // Canonicalize encoding name: strip all non-alphanumeric chars and appended year.
    return (''+encoding).toLowerCase().replace(/:\d{4}$|[^0-9a-z]/g, "");
}

iconv.getEncoder = function getEncoder(encoding, options) {
    var codec = iconv.getCodec(encoding),
        encoder = new codec.encoder(options, codec);

    if (codec.bomAware && options && options.addBOM)
        encoder = new bomHandling.PrependBOM(encoder, options);

    return encoder;
}

iconv.getDecoder = function getDecoder(encoding, options) {
    var codec = iconv.getCodec(encoding),
        decoder = new codec.decoder(options, codec);

    if (codec.bomAware && !(options && options.stripBOM === false))
        decoder = new bomHandling.StripBOM(decoder, options);

    return decoder;
}


// Load extensions in Node. All of them are omitted in Browserify build via 'browser' field in package.json.
var nodeVer = typeof process !== 'undefined' && process.versions && process.versions.node;
if (nodeVer) {

    // Load streaming support in Node v0.10+
    var nodeVerArr = nodeVer.split(".").map(Number);
    if (nodeVerArr[0] > 0 || nodeVerArr[1] >= 10) {
        __webpack_require__(434)(iconv);
    }

    // Load Node primitive extensions.
    __webpack_require__(435)(iconv);
}

if (false) {}

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(22)))

/***/ }),
/* 417 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var BOMChar = '\uFEFF';

exports.PrependBOM = PrependBOMWrapper
function PrependBOMWrapper(encoder, options) {
    this.encoder = encoder;
    this.addBOM = true;
}

PrependBOMWrapper.prototype.write = function(str) {
    if (this.addBOM) {
        str = BOMChar + str;
        this.addBOM = false;
    }

    return this.encoder.write(str);
}

PrependBOMWrapper.prototype.end = function() {
    return this.encoder.end();
}


//------------------------------------------------------------------------------

exports.StripBOM = StripBOMWrapper;
function StripBOMWrapper(decoder, options) {
    this.decoder = decoder;
    this.pass = false;
    this.options = options || {};
}

StripBOMWrapper.prototype.write = function(buf) {
    var res = this.decoder.write(buf);
    if (this.pass || !res)
        return res;

    if (res[0] === BOMChar) {
        res = res.slice(1);
        if (typeof this.options.stripBOM === 'function')
            this.options.stripBOM();
    }

    this.pass = true;
    return res;
}

StripBOMWrapper.prototype.end = function() {
    return this.decoder.end();
}



/***/ }),
/* 418 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


// Update this array if you add/rename/remove files in this directory.
// We support Browserify by skipping automatic module discovery and requiring modules directly.
var modules = [
    __webpack_require__(419),
    __webpack_require__(422),
    __webpack_require__(423),
    __webpack_require__(424),
    __webpack_require__(425),
    __webpack_require__(426),
    __webpack_require__(427),
    __webpack_require__(428),
];

// Put all encoding/alias/codec definitions to single object and export it. 
for (var i = 0; i < modules.length; i++) {
    var module = modules[i];
    for (var enc in module)
        if (Object.prototype.hasOwnProperty.call(module, enc))
            exports[enc] = module[enc];
}


/***/ }),
/* 419 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var Buffer = __webpack_require__(127).Buffer;

// Export Node.js internal encodings.

module.exports = {
    // Encodings
    utf8:   { type: "_internal", bomAware: true},
    cesu8:  { type: "_internal", bomAware: true},
    unicode11utf8: "utf8",

    ucs2:   { type: "_internal", bomAware: true},
    utf16le: "ucs2",

    binary: { type: "_internal" },
    base64: { type: "_internal" },
    hex:    { type: "_internal" },

    // Codec.
    _internal: InternalCodec,
};

//------------------------------------------------------------------------------

function InternalCodec(codecOptions, iconv) {
    this.enc = codecOptions.encodingName;
    this.bomAware = codecOptions.bomAware;

    if (this.enc === "base64")
        this.encoder = InternalEncoderBase64;
    else if (this.enc === "cesu8") {
        this.enc = "utf8"; // Use utf8 for decoding.
        this.encoder = InternalEncoderCesu8;

        // Add decoder for versions of Node not supporting CESU-8
        if (Buffer.from('eda0bdedb2a9', 'hex').toString() !== '💩') {
            this.decoder = InternalDecoderCesu8;
            this.defaultCharUnicode = iconv.defaultCharUnicode;
        }
    }
}

InternalCodec.prototype.encoder = InternalEncoder;
InternalCodec.prototype.decoder = InternalDecoder;

//------------------------------------------------------------------------------

// We use node.js internal decoder. Its signature is the same as ours.
var StringDecoder = __webpack_require__(420).StringDecoder;

if (!StringDecoder.prototype.end) // Node v0.8 doesn't have this method.
    StringDecoder.prototype.end = function() {};


function InternalDecoder(options, codec) {
    StringDecoder.call(this, codec.enc);
}

InternalDecoder.prototype = StringDecoder.prototype;


//------------------------------------------------------------------------------
// Encoder is mostly trivial

function InternalEncoder(options, codec) {
    this.enc = codec.enc;
}

InternalEncoder.prototype.write = function(str) {
    return Buffer.from(str, this.enc);
}

InternalEncoder.prototype.end = function() {
}


//------------------------------------------------------------------------------
// Except base64 encoder, which must keep its state.

function InternalEncoderBase64(options, codec) {
    this.prevStr = '';
}

InternalEncoderBase64.prototype.write = function(str) {
    str = this.prevStr + str;
    var completeQuads = str.length - (str.length % 4);
    this.prevStr = str.slice(completeQuads);
    str = str.slice(0, completeQuads);

    return Buffer.from(str, "base64");
}

InternalEncoderBase64.prototype.end = function() {
    return Buffer.from(this.prevStr, "base64");
}


//------------------------------------------------------------------------------
// CESU-8 encoder is also special.

function InternalEncoderCesu8(options, codec) {
}

InternalEncoderCesu8.prototype.write = function(str) {
    var buf = Buffer.alloc(str.length * 3), bufIdx = 0;
    for (var i = 0; i < str.length; i++) {
        var charCode = str.charCodeAt(i);
        // Naive implementation, but it works because CESU-8 is especially easy
        // to convert from UTF-16 (which all JS strings are encoded in).
        if (charCode < 0x80)
            buf[bufIdx++] = charCode;
        else if (charCode < 0x800) {
            buf[bufIdx++] = 0xC0 + (charCode >>> 6);
            buf[bufIdx++] = 0x80 + (charCode & 0x3f);
        }
        else { // charCode will always be < 0x10000 in javascript.
            buf[bufIdx++] = 0xE0 + (charCode >>> 12);
            buf[bufIdx++] = 0x80 + ((charCode >>> 6) & 0x3f);
            buf[bufIdx++] = 0x80 + (charCode & 0x3f);
        }
    }
    return buf.slice(0, bufIdx);
}

InternalEncoderCesu8.prototype.end = function() {
}

//------------------------------------------------------------------------------
// CESU-8 decoder is not implemented in Node v4.0+

function InternalDecoderCesu8(options, codec) {
    this.acc = 0;
    this.contBytes = 0;
    this.accBytes = 0;
    this.defaultCharUnicode = codec.defaultCharUnicode;
}

InternalDecoderCesu8.prototype.write = function(buf) {
    var acc = this.acc, contBytes = this.contBytes, accBytes = this.accBytes, 
        res = '';
    for (var i = 0; i < buf.length; i++) {
        var curByte = buf[i];
        if ((curByte & 0xC0) !== 0x80) { // Leading byte
            if (contBytes > 0) { // Previous code is invalid
                res += this.defaultCharUnicode;
                contBytes = 0;
            }

            if (curByte < 0x80) { // Single-byte code
                res += String.fromCharCode(curByte);
            } else if (curByte < 0xE0) { // Two-byte code
                acc = curByte & 0x1F;
                contBytes = 1; accBytes = 1;
            } else if (curByte < 0xF0) { // Three-byte code
                acc = curByte & 0x0F;
                contBytes = 2; accBytes = 1;
            } else { // Four or more are not supported for CESU-8.
                res += this.defaultCharUnicode;
            }
        } else { // Continuation byte
            if (contBytes > 0) { // We're waiting for it.
                acc = (acc << 6) | (curByte & 0x3f);
                contBytes--; accBytes++;
                if (contBytes === 0) {
                    // Check for overlong encoding, but support Modified UTF-8 (encoding NULL as C0 80)
                    if (accBytes === 2 && acc < 0x80 && acc > 0)
                        res += this.defaultCharUnicode;
                    else if (accBytes === 3 && acc < 0x800)
                        res += this.defaultCharUnicode;
                    else
                        // Actually add character.
                        res += String.fromCharCode(acc);
                }
            } else { // Unexpected continuation byte
                res += this.defaultCharUnicode;
            }
        }
    }
    this.acc = acc; this.contBytes = contBytes; this.accBytes = accBytes;
    return res;
}

InternalDecoderCesu8.prototype.end = function() {
    var res = 0;
    if (this.contBytes > 0)
        res += this.defaultCharUnicode;
    return res;
}


/***/ }),
/* 420 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the
// "Software"), to deal in the Software without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Software, and to permit
// persons to whom the Software is furnished to do so, subject to the
// following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.



/*<replacement>*/

var Buffer = __webpack_require__(421).Buffer;
/*</replacement>*/

var isEncoding = Buffer.isEncoding || function (encoding) {
  encoding = '' + encoding;
  switch (encoding && encoding.toLowerCase()) {
    case 'hex':case 'utf8':case 'utf-8':case 'ascii':case 'binary':case 'base64':case 'ucs2':case 'ucs-2':case 'utf16le':case 'utf-16le':case 'raw':
      return true;
    default:
      return false;
  }
};

function _normalizeEncoding(enc) {
  if (!enc) return 'utf8';
  var retried;
  while (true) {
    switch (enc) {
      case 'utf8':
      case 'utf-8':
        return 'utf8';
      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return 'utf16le';
      case 'latin1':
      case 'binary':
        return 'latin1';
      case 'base64':
      case 'ascii':
      case 'hex':
        return enc;
      default:
        if (retried) return; // undefined
        enc = ('' + enc).toLowerCase();
        retried = true;
    }
  }
};

// Do not cache `Buffer.isEncoding` when checking encoding names as some
// modules monkey-patch it to support additional encodings
function normalizeEncoding(enc) {
  var nenc = _normalizeEncoding(enc);
  if (typeof nenc !== 'string' && (Buffer.isEncoding === isEncoding || !isEncoding(enc))) throw new Error('Unknown encoding: ' + enc);
  return nenc || enc;
}

// StringDecoder provides an interface for efficiently splitting a series of
// buffers into a series of JS strings without breaking apart multi-byte
// characters.
exports.StringDecoder = StringDecoder;
function StringDecoder(encoding) {
  this.encoding = normalizeEncoding(encoding);
  var nb;
  switch (this.encoding) {
    case 'utf16le':
      this.text = utf16Text;
      this.end = utf16End;
      nb = 4;
      break;
    case 'utf8':
      this.fillLast = utf8FillLast;
      nb = 4;
      break;
    case 'base64':
      this.text = base64Text;
      this.end = base64End;
      nb = 3;
      break;
    default:
      this.write = simpleWrite;
      this.end = simpleEnd;
      return;
  }
  this.lastNeed = 0;
  this.lastTotal = 0;
  this.lastChar = Buffer.allocUnsafe(nb);
}

StringDecoder.prototype.write = function (buf) {
  if (buf.length === 0) return '';
  var r;
  var i;
  if (this.lastNeed) {
    r = this.fillLast(buf);
    if (r === undefined) return '';
    i = this.lastNeed;
    this.lastNeed = 0;
  } else {
    i = 0;
  }
  if (i < buf.length) return r ? r + this.text(buf, i) : this.text(buf, i);
  return r || '';
};

StringDecoder.prototype.end = utf8End;

// Returns only complete characters in a Buffer
StringDecoder.prototype.text = utf8Text;

// Attempts to complete a partial non-UTF-8 character using bytes from a Buffer
StringDecoder.prototype.fillLast = function (buf) {
  if (this.lastNeed <= buf.length) {
    buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed);
    return this.lastChar.toString(this.encoding, 0, this.lastTotal);
  }
  buf.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, buf.length);
  this.lastNeed -= buf.length;
};

// Checks the type of a UTF-8 byte, whether it's ASCII, a leading byte, or a
// continuation byte. If an invalid byte is detected, -2 is returned.
function utf8CheckByte(byte) {
  if (byte <= 0x7F) return 0;else if (byte >> 5 === 0x06) return 2;else if (byte >> 4 === 0x0E) return 3;else if (byte >> 3 === 0x1E) return 4;
  return byte >> 6 === 0x02 ? -1 : -2;
}

// Checks at most 3 bytes at the end of a Buffer in order to detect an
// incomplete multi-byte UTF-8 character. The total number of bytes (2, 3, or 4)
// needed to complete the UTF-8 character (if applicable) are returned.
function utf8CheckIncomplete(self, buf, i) {
  var j = buf.length - 1;
  if (j < i) return 0;
  var nb = utf8CheckByte(buf[j]);
  if (nb >= 0) {
    if (nb > 0) self.lastNeed = nb - 1;
    return nb;
  }
  if (--j < i || nb === -2) return 0;
  nb = utf8CheckByte(buf[j]);
  if (nb >= 0) {
    if (nb > 0) self.lastNeed = nb - 2;
    return nb;
  }
  if (--j < i || nb === -2) return 0;
  nb = utf8CheckByte(buf[j]);
  if (nb >= 0) {
    if (nb > 0) {
      if (nb === 2) nb = 0;else self.lastNeed = nb - 3;
    }
    return nb;
  }
  return 0;
}

// Validates as many continuation bytes for a multi-byte UTF-8 character as
// needed or are available. If we see a non-continuation byte where we expect
// one, we "replace" the validated continuation bytes we've seen so far with
// a single UTF-8 replacement character ('\ufffd'), to match v8's UTF-8 decoding
// behavior. The continuation byte check is included three times in the case
// where all of the continuation bytes for a character exist in the same buffer.
// It is also done this way as a slight performance increase instead of using a
// loop.
function utf8CheckExtraBytes(self, buf, p) {
  if ((buf[0] & 0xC0) !== 0x80) {
    self.lastNeed = 0;
    return '\ufffd';
  }
  if (self.lastNeed > 1 && buf.length > 1) {
    if ((buf[1] & 0xC0) !== 0x80) {
      self.lastNeed = 1;
      return '\ufffd';
    }
    if (self.lastNeed > 2 && buf.length > 2) {
      if ((buf[2] & 0xC0) !== 0x80) {
        self.lastNeed = 2;
        return '\ufffd';
      }
    }
  }
}

// Attempts to complete a multi-byte UTF-8 character using bytes from a Buffer.
function utf8FillLast(buf) {
  var p = this.lastTotal - this.lastNeed;
  var r = utf8CheckExtraBytes(this, buf, p);
  if (r !== undefined) return r;
  if (this.lastNeed <= buf.length) {
    buf.copy(this.lastChar, p, 0, this.lastNeed);
    return this.lastChar.toString(this.encoding, 0, this.lastTotal);
  }
  buf.copy(this.lastChar, p, 0, buf.length);
  this.lastNeed -= buf.length;
}

// Returns all complete UTF-8 characters in a Buffer. If the Buffer ended on a
// partial character, the character's bytes are buffered until the required
// number of bytes are available.
function utf8Text(buf, i) {
  var total = utf8CheckIncomplete(this, buf, i);
  if (!this.lastNeed) return buf.toString('utf8', i);
  this.lastTotal = total;
  var end = buf.length - (total - this.lastNeed);
  buf.copy(this.lastChar, 0, end);
  return buf.toString('utf8', i, end);
}

// For UTF-8, a replacement character is added when ending on a partial
// character.
function utf8End(buf) {
  var r = buf && buf.length ? this.write(buf) : '';
  if (this.lastNeed) return r + '\ufffd';
  return r;
}

// UTF-16LE typically needs two bytes per character, but even if we have an even
// number of bytes available, we need to check if we end on a leading/high
// surrogate. In that case, we need to wait for the next two bytes in order to
// decode the last character properly.
function utf16Text(buf, i) {
  if ((buf.length - i) % 2 === 0) {
    var r = buf.toString('utf16le', i);
    if (r) {
      var c = r.charCodeAt(r.length - 1);
      if (c >= 0xD800 && c <= 0xDBFF) {
        this.lastNeed = 2;
        this.lastTotal = 4;
        this.lastChar[0] = buf[buf.length - 2];
        this.lastChar[1] = buf[buf.length - 1];
        return r.slice(0, -1);
      }
    }
    return r;
  }
  this.lastNeed = 1;
  this.lastTotal = 2;
  this.lastChar[0] = buf[buf.length - 1];
  return buf.toString('utf16le', i, buf.length - 1);
}

// For UTF-16LE we do not explicitly append special replacement characters if we
// end on a partial character, we simply let v8 handle that.
function utf16End(buf) {
  var r = buf && buf.length ? this.write(buf) : '';
  if (this.lastNeed) {
    var end = this.lastTotal - this.lastNeed;
    return r + this.lastChar.toString('utf16le', 0, end);
  }
  return r;
}

function base64Text(buf, i) {
  var n = (buf.length - i) % 3;
  if (n === 0) return buf.toString('base64', i);
  this.lastNeed = 3 - n;
  this.lastTotal = 3;
  if (n === 1) {
    this.lastChar[0] = buf[buf.length - 1];
  } else {
    this.lastChar[0] = buf[buf.length - 2];
    this.lastChar[1] = buf[buf.length - 1];
  }
  return buf.toString('base64', i, buf.length - n);
}

function base64End(buf) {
  var r = buf && buf.length ? this.write(buf) : '';
  if (this.lastNeed) return r + this.lastChar.toString('base64', 0, 3 - this.lastNeed);
  return r;
}

// Pass bytes on through for single-byte encodings (e.g. ascii, latin1, hex)
function simpleWrite(buf) {
  return buf.toString(this.encoding);
}

function simpleEnd(buf) {
  return buf && buf.length ? this.write(buf) : '';
}

/***/ }),
/* 421 */
/***/ (function(module, exports, __webpack_require__) {

/* eslint-disable node/no-deprecated-api */
var buffer = __webpack_require__(116)
var Buffer = buffer.Buffer

// alternative to using Object.keys for old browsers
function copyProps (src, dst) {
  for (var key in src) {
    dst[key] = src[key]
  }
}
if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) {
  module.exports = buffer
} else {
  // Copy properties from require('buffer')
  copyProps(buffer, exports)
  exports.Buffer = SafeBuffer
}

function SafeBuffer (arg, encodingOrOffset, length) {
  return Buffer(arg, encodingOrOffset, length)
}

// Copy static methods from Buffer
copyProps(Buffer, SafeBuffer)

SafeBuffer.from = function (arg, encodingOrOffset, length) {
  if (typeof arg === 'number') {
    throw new TypeError('Argument must not be a number')
  }
  return Buffer(arg, encodingOrOffset, length)
}

SafeBuffer.alloc = function (size, fill, encoding) {
  if (typeof size !== 'number') {
    throw new TypeError('Argument must be a number')
  }
  var buf = Buffer(size)
  if (fill !== undefined) {
    if (typeof encoding === 'string') {
      buf.fill(fill, encoding)
    } else {
      buf.fill(fill)
    }
  } else {
    buf.fill(0)
  }
  return buf
}

SafeBuffer.allocUnsafe = function (size) {
  if (typeof size !== 'number') {
    throw new TypeError('Argument must be a number')
  }
  return Buffer(size)
}

SafeBuffer.allocUnsafeSlow = function (size) {
  if (typeof size !== 'number') {
    throw new TypeError('Argument must be a number')
  }
  return buffer.SlowBuffer(size)
}


/***/ }),
/* 422 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var Buffer = __webpack_require__(127).Buffer;

// Note: UTF16-LE (or UCS2) codec is Node.js native. See encodings/internal.js

// == UTF16-BE codec. ==========================================================

exports.utf16be = Utf16BECodec;
function Utf16BECodec() {
}

Utf16BECodec.prototype.encoder = Utf16BEEncoder;
Utf16BECodec.prototype.decoder = Utf16BEDecoder;
Utf16BECodec.prototype.bomAware = true;


// -- Encoding

function Utf16BEEncoder() {
}

Utf16BEEncoder.prototype.write = function(str) {
    var buf = Buffer.from(str, 'ucs2');
    for (var i = 0; i < buf.length; i += 2) {
        var tmp = buf[i]; buf[i] = buf[i+1]; buf[i+1] = tmp;
    }
    return buf;
}

Utf16BEEncoder.prototype.end = function() {
}


// -- Decoding

function Utf16BEDecoder() {
    this.overflowByte = -1;
}

Utf16BEDecoder.prototype.write = function(buf) {
    if (buf.length == 0)
        return '';

    var buf2 = Buffer.alloc(buf.length + 1),
        i = 0, j = 0;

    if (this.overflowByte !== -1) {
        buf2[0] = buf[0];
        buf2[1] = this.overflowByte;
        i = 1; j = 2;
    }

    for (; i < buf.length-1; i += 2, j+= 2) {
        buf2[j] = buf[i+1];
        buf2[j+1] = buf[i];
    }

    this.overflowByte = (i == buf.length-1) ? buf[buf.length-1] : -1;

    return buf2.slice(0, j).toString('ucs2');
}

Utf16BEDecoder.prototype.end = function() {
}


// == UTF-16 codec =============================================================
// Decoder chooses automatically from UTF-16LE and UTF-16BE using BOM and space-based heuristic.
// Defaults to UTF-16LE, as it's prevalent and default in Node.
// http://en.wikipedia.org/wiki/UTF-16 and http://encoding.spec.whatwg.org/#utf-16le
// Decoder default can be changed: iconv.decode(buf, 'utf16', {defaultEncoding: 'utf-16be'});

// Encoder uses UTF-16LE and prepends BOM (which can be overridden with addBOM: false).

exports.utf16 = Utf16Codec;
function Utf16Codec(codecOptions, iconv) {
    this.iconv = iconv;
}

Utf16Codec.prototype.encoder = Utf16Encoder;
Utf16Codec.prototype.decoder = Utf16Decoder;


// -- Encoding (pass-through)

function Utf16Encoder(options, codec) {
    options = options || {};
    if (options.addBOM === undefined)
        options.addBOM = true;
    this.encoder = codec.iconv.getEncoder('utf-16le', options);
}

Utf16Encoder.prototype.write = function(str) {
    return this.encoder.write(str);
}

Utf16Encoder.prototype.end = function() {
    return this.encoder.end();
}


// -- Decoding

function Utf16Decoder(options, codec) {
    this.decoder = null;
    this.initialBytes = [];
    this.initialBytesLen = 0;

    this.options = options || {};
    this.iconv = codec.iconv;
}

Utf16Decoder.prototype.write = function(buf) {
    if (!this.decoder) {
        // Codec is not chosen yet. Accumulate initial bytes.
        this.initialBytes.push(buf);
        this.initialBytesLen += buf.length;
        
        if (this.initialBytesLen < 16) // We need more bytes to use space heuristic (see below)
            return '';

        // We have enough bytes -> detect endianness.
        var buf = Buffer.concat(this.initialBytes),
            encoding = detectEncoding(buf, this.options.defaultEncoding);
        this.decoder = this.iconv.getDecoder(encoding, this.options);
        this.initialBytes.length = this.initialBytesLen = 0;
    }

    return this.decoder.write(buf);
}

Utf16Decoder.prototype.end = function() {
    if (!this.decoder) {
        var buf = Buffer.concat(this.initialBytes),
            encoding = detectEncoding(buf, this.options.defaultEncoding);
        this.decoder = this.iconv.getDecoder(encoding, this.options);

        var res = this.decoder.write(buf),
            trail = this.decoder.end();

        return trail ? (res + trail) : res;
    }
    return this.decoder.end();
}

function detectEncoding(buf, defaultEncoding) {
    var enc = defaultEncoding || 'utf-16le';

    if (buf.length >= 2) {
        // Check BOM.
        if (buf[0] == 0xFE && buf[1] == 0xFF) // UTF-16BE BOM
            enc = 'utf-16be';
        else if (buf[0] == 0xFF && buf[1] == 0xFE) // UTF-16LE BOM
            enc = 'utf-16le';
        else {
            // No BOM found. Try to deduce encoding from initial content.
            // Most of the time, the content has ASCII chars (U+00**), but the opposite (U+**00) is uncommon.
            // So, we count ASCII as if it was LE or BE, and decide from that.
            var asciiCharsLE = 0, asciiCharsBE = 0, // Counts of chars in both positions
                _len = Math.min(buf.length - (buf.length % 2), 64); // Len is always even.

            for (var i = 0; i < _len; i += 2) {
                if (buf[i] === 0 && buf[i+1] !== 0) asciiCharsBE++;
                if (buf[i] !== 0 && buf[i+1] === 0) asciiCharsLE++;
            }

            if (asciiCharsBE > asciiCharsLE)
                enc = 'utf-16be';
            else if (asciiCharsBE < asciiCharsLE)
                enc = 'utf-16le';
        }
    }

    return enc;
}




/***/ }),
/* 423 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var Buffer = __webpack_require__(127).Buffer;

// UTF-7 codec, according to https://tools.ietf.org/html/rfc2152
// See also below a UTF-7-IMAP codec, according to http://tools.ietf.org/html/rfc3501#section-5.1.3

exports.utf7 = Utf7Codec;
exports.unicode11utf7 = 'utf7'; // Alias UNICODE-1-1-UTF-7
function Utf7Codec(codecOptions, iconv) {
    this.iconv = iconv;
};

Utf7Codec.prototype.encoder = Utf7Encoder;
Utf7Codec.prototype.decoder = Utf7Decoder;
Utf7Codec.prototype.bomAware = true;


// -- Encoding

var nonDirectChars = /[^A-Za-z0-9'\(\),-\.\/:\? \n\r\t]+/g;

function Utf7Encoder(options, codec) {
    this.iconv = codec.iconv;
}

Utf7Encoder.prototype.write = function(str) {
    // Naive implementation.
    // Non-direct chars are encoded as "+<base64>-"; single "+" char is encoded as "+-".
    return Buffer.from(str.replace(nonDirectChars, function(chunk) {
        return "+" + (chunk === '+' ? '' : 
            this.iconv.encode(chunk, 'utf16-be').toString('base64').replace(/=+$/, '')) 
            + "-";
    }.bind(this)));
}

Utf7Encoder.prototype.end = function() {
}


// -- Decoding

function Utf7Decoder(options, codec) {
    this.iconv = codec.iconv;
    this.inBase64 = false;
    this.base64Accum = '';
}

var base64Regex = /[A-Za-z0-9\/+]/;
var base64Chars = [];
for (var i = 0; i < 256; i++)
    base64Chars[i] = base64Regex.test(String.fromCharCode(i));

var plusChar = '+'.charCodeAt(0), 
    minusChar = '-'.charCodeAt(0),
    andChar = '&'.charCodeAt(0);

Utf7Decoder.prototype.write = function(buf) {
    var res = "", lastI = 0,
        inBase64 = this.inBase64,
        base64Accum = this.base64Accum;

    // The decoder is more involved as we must handle chunks in stream.

    for (var i = 0; i < buf.length; i++) {
        if (!inBase64) { // We're in direct mode.
            // Write direct chars until '+'
            if (buf[i] == plusChar) {
                res += this.iconv.decode(buf.slice(lastI, i), "ascii"); // Write direct chars.
                lastI = i+1;
                inBase64 = true;
            }
        } else { // We decode base64.
            if (!base64Chars[buf[i]]) { // Base64 ended.
                if (i == lastI && buf[i] == minusChar) {// "+-" -> "+"
                    res += "+";
                } else {
                    var b64str = base64Accum + buf.slice(lastI, i).toString();
                    res += this.iconv.decode(Buffer.from(b64str, 'base64'), "utf16-be");
                }

                if (buf[i] != minusChar) // Minus is absorbed after base64.
                    i--;

                lastI = i+1;
                inBase64 = false;
                base64Accum = '';
            }
        }
    }

    if (!inBase64) {
        res += this.iconv.decode(buf.slice(lastI), "ascii"); // Write direct chars.
    } else {
        var b64str = base64Accum + buf.slice(lastI).toString();

        var canBeDecoded = b64str.length - (b64str.length % 8); // Minimal chunk: 2 quads -> 2x3 bytes -> 3 chars.
        base64Accum = b64str.slice(canBeDecoded); // The rest will be decoded in future.
        b64str = b64str.slice(0, canBeDecoded);

        res += this.iconv.decode(Buffer.from(b64str, 'base64'), "utf16-be");
    }

    this.inBase64 = inBase64;
    this.base64Accum = base64Accum;

    return res;
}

Utf7Decoder.prototype.end = function() {
    var res = "";
    if (this.inBase64 && this.base64Accum.length > 0)
        res = this.iconv.decode(Buffer.from(this.base64Accum, 'base64'), "utf16-be");

    this.inBase64 = false;
    this.base64Accum = '';
    return res;
}


// UTF-7-IMAP codec.
// RFC3501 Sec. 5.1.3 Modified UTF-7 (http://tools.ietf.org/html/rfc3501#section-5.1.3)
// Differences:
//  * Base64 part is started by "&" instead of "+"
//  * Direct characters are 0x20-0x7E, except "&" (0x26)
//  * In Base64, "," is used instead of "/"
//  * Base64 must not be used to represent direct characters.
//  * No implicit shift back from Base64 (should always end with '-')
//  * String must end in non-shifted position.
//  * "-&" while in base64 is not allowed.


exports.utf7imap = Utf7IMAPCodec;
function Utf7IMAPCodec(codecOptions, iconv) {
    this.iconv = iconv;
};

Utf7IMAPCodec.prototype.encoder = Utf7IMAPEncoder;
Utf7IMAPCodec.prototype.decoder = Utf7IMAPDecoder;
Utf7IMAPCodec.prototype.bomAware = true;


// -- Encoding

function Utf7IMAPEncoder(options, codec) {
    this.iconv = codec.iconv;
    this.inBase64 = false;
    this.base64Accum = Buffer.alloc(6);
    this.base64AccumIdx = 0;
}

Utf7IMAPEncoder.prototype.write = function(str) {
    var inBase64 = this.inBase64,
        base64Accum = this.base64Accum,
        base64AccumIdx = this.base64AccumIdx,
        buf = Buffer.alloc(str.length*5 + 10), bufIdx = 0;

    for (var i = 0; i < str.length; i++) {
        var uChar = str.charCodeAt(i);
        if (0x20 <= uChar && uChar <= 0x7E) { // Direct character or '&'.
            if (inBase64) {
                if (base64AccumIdx > 0) {
                    bufIdx += buf.write(base64Accum.slice(0, base64AccumIdx).toString('base64').replace(/\//g, ',').replace(/=+$/, ''), bufIdx);
                    base64AccumIdx = 0;
                }

                buf[bufIdx++] = minusChar; // Write '-', then go to direct mode.
                inBase64 = false;
            }

            if (!inBase64) {
                buf[bufIdx++] = uChar; // Write direct character

                if (uChar === andChar)  // Ampersand -> '&-'
                    buf[bufIdx++] = minusChar;
            }

        } else { // Non-direct character
            if (!inBase64) {
                buf[bufIdx++] = andChar; // Write '&', then go to base64 mode.
                inBase64 = true;
            }
            if (inBase64) {
                base64Accum[base64AccumIdx++] = uChar >> 8;
                base64Accum[base64AccumIdx++] = uChar & 0xFF;

                if (base64AccumIdx == base64Accum.length) {
                    bufIdx += buf.write(base64Accum.toString('base64').replace(/\//g, ','), bufIdx);
                    base64AccumIdx = 0;
                }
            }
        }
    }

    this.inBase64 = inBase64;
    this.base64AccumIdx = base64AccumIdx;

    return buf.slice(0, bufIdx);
}

Utf7IMAPEncoder.prototype.end = function() {
    var buf = Buffer.alloc(10), bufIdx = 0;
    if (this.inBase64) {
        if (this.base64AccumIdx > 0) {
            bufIdx += buf.write(this.base64Accum.slice(0, this.base64AccumIdx).toString('base64').replace(/\//g, ',').replace(/=+$/, ''), bufIdx);
            this.base64AccumIdx = 0;
        }

        buf[bufIdx++] = minusChar; // Write '-', then go to direct mode.
        this.inBase64 = false;
    }

    return buf.slice(0, bufIdx);
}


// -- Decoding

function Utf7IMAPDecoder(options, codec) {
    this.iconv = codec.iconv;
    this.inBase64 = false;
    this.base64Accum = '';
}

var base64IMAPChars = base64Chars.slice();
base64IMAPChars[','.charCodeAt(0)] = true;

Utf7IMAPDecoder.prototype.write = function(buf) {
    var res = "", lastI = 0,
        inBase64 = this.inBase64,
        base64Accum = this.base64Accum;

    // The decoder is more involved as we must handle chunks in stream.
    // It is forgiving, closer to standard UTF-7 (for example, '-' is optional at the end).

    for (var i = 0; i < buf.length; i++) {
        if (!inBase64) { // We're in direct mode.
            // Write direct chars until '&'
            if (buf[i] == andChar) {
                res += this.iconv.decode(buf.slice(lastI, i), "ascii"); // Write direct chars.
                lastI = i+1;
                inBase64 = true;
            }
        } else { // We decode base64.
            if (!base64IMAPChars[buf[i]]) { // Base64 ended.
                if (i == lastI && buf[i] == minusChar) { // "&-" -> "&"
                    res += "&";
                } else {
                    var b64str = base64Accum + buf.slice(lastI, i).toString().replace(/,/g, '/');
                    res += this.iconv.decode(Buffer.from(b64str, 'base64'), "utf16-be");
                }

                if (buf[i] != minusChar) // Minus may be absorbed after base64.
                    i--;

                lastI = i+1;
                inBase64 = false;
                base64Accum = '';
            }
        }
    }

    if (!inBase64) {
        res += this.iconv.decode(buf.slice(lastI), "ascii"); // Write direct chars.
    } else {
        var b64str = base64Accum + buf.slice(lastI).toString().replace(/,/g, '/');

        var canBeDecoded = b64str.length - (b64str.length % 8); // Minimal chunk: 2 quads -> 2x3 bytes -> 3 chars.
        base64Accum = b64str.slice(canBeDecoded); // The rest will be decoded in future.
        b64str = b64str.slice(0, canBeDecoded);

        res += this.iconv.decode(Buffer.from(b64str, 'base64'), "utf16-be");
    }

    this.inBase64 = inBase64;
    this.base64Accum = base64Accum;

    return res;
}

Utf7IMAPDecoder.prototype.end = function() {
    var res = "";
    if (this.inBase64 && this.base64Accum.length > 0)
        res = this.iconv.decode(Buffer.from(this.base64Accum, 'base64'), "utf16-be");

    this.inBase64 = false;
    this.base64Accum = '';
    return res;
}




/***/ }),
/* 424 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var Buffer = __webpack_require__(127).Buffer;

// Single-byte codec. Needs a 'chars' string parameter that contains 256 or 128 chars that
// correspond to encoded bytes (if 128 - then lower half is ASCII). 

exports._sbcs = SBCSCodec;
function SBCSCodec(codecOptions, iconv) {
    if (!codecOptions)
        throw new Error("SBCS codec is called without the data.")
    
    // Prepare char buffer for decoding.
    if (!codecOptions.chars || (codecOptions.chars.length !== 128 && codecOptions.chars.length !== 256))
        throw new Error("Encoding '"+codecOptions.type+"' has incorrect 'chars' (must be of len 128 or 256)");
    
    if (codecOptions.chars.length === 128) {
        var asciiString = "";
        for (var i = 0; i < 128; i++)
            asciiString += String.fromCharCode(i);
        codecOptions.chars = asciiString + codecOptions.chars;
    }

    this.decodeBuf = Buffer.from(codecOptions.chars, 'ucs2');
    
    // Encoding buffer.
    var encodeBuf = Buffer.alloc(65536, iconv.defaultCharSingleByte.charCodeAt(0));

    for (var i = 0; i < codecOptions.chars.length; i++)
        encodeBuf[codecOptions.chars.charCodeAt(i)] = i;

    this.encodeBuf = encodeBuf;
}

SBCSCodec.prototype.encoder = SBCSEncoder;
SBCSCodec.prototype.decoder = SBCSDecoder;


function SBCSEncoder(options, codec) {
    this.encodeBuf = codec.encodeBuf;
}

SBCSEncoder.prototype.write = function(str) {
    var buf = Buffer.alloc(str.length);
    for (var i = 0; i < str.length; i++)
        buf[i] = this.encodeBuf[str.charCodeAt(i)];
    
    return buf;
}

SBCSEncoder.prototype.end = function() {
}


function SBCSDecoder(options, codec) {
    this.decodeBuf = codec.decodeBuf;
}

SBCSDecoder.prototype.write = function(buf) {
    // Strings are immutable in JS -> we use ucs2 buffer to speed up computations.
    var decodeBuf = this.decodeBuf;
    var newBuf = Buffer.alloc(buf.length*2);
    var idx1 = 0, idx2 = 0;
    for (var i = 0; i < buf.length; i++) {
        idx1 = buf[i]*2; idx2 = i*2;
        newBuf[idx2] = decodeBuf[idx1];
        newBuf[idx2+1] = decodeBuf[idx1+1];
    }
    return newBuf.toString('ucs2');
}

SBCSDecoder.prototype.end = function() {
}


/***/ }),
/* 425 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


// Manually added data to be used by sbcs codec in addition to generated one.

module.exports = {
    // Not supported by iconv, not sure why.
    "10029": "maccenteuro",
    "maccenteuro": {
        "type": "_sbcs",
        "chars": "ÄĀāÉĄÖÜáąČäčĆćéŹźĎíďĒēĖóėôöõúĚěü†°Ę£§•¶ß®©™ę¨≠ģĮįĪ≤≥īĶ∂∑łĻļĽľĹĺŅņŃ¬√ńŇ∆«»… ňŐÕőŌ–—“”‘’÷◊ōŔŕŘ‹›řŖŗŠ‚„šŚśÁŤťÍŽžŪÓÔūŮÚůŰűŲųÝýķŻŁżĢˇ"
    },

    "808": "cp808",
    "ibm808": "cp808",
    "cp808": {
        "type": "_sbcs",
        "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№€■ "
    },

    "mik": {
        "type": "_sbcs",
        "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя└┴┬├─┼╣║╚╔╩╦╠═╬┐░▒▓│┤№§╗╝┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
    },

    // Aliases of generated encodings.
    "ascii8bit": "ascii",
    "usascii": "ascii",
    "ansix34": "ascii",
    "ansix341968": "ascii",
    "ansix341986": "ascii",
    "csascii": "ascii",
    "cp367": "ascii",
    "ibm367": "ascii",
    "isoir6": "ascii",
    "iso646us": "ascii",
    "iso646irv": "ascii",
    "us": "ascii",

    "latin1": "iso88591",
    "latin2": "iso88592",
    "latin3": "iso88593",
    "latin4": "iso88594",
    "latin5": "iso88599",
    "latin6": "iso885910",
    "latin7": "iso885913",
    "latin8": "iso885914",
    "latin9": "iso885915",
    "latin10": "iso885916",

    "csisolatin1": "iso88591",
    "csisolatin2": "iso88592",
    "csisolatin3": "iso88593",
    "csisolatin4": "iso88594",
    "csisolatincyrillic": "iso88595",
    "csisolatinarabic": "iso88596",
    "csisolatingreek" : "iso88597",
    "csisolatinhebrew": "iso88598",
    "csisolatin5": "iso88599",
    "csisolatin6": "iso885910",

    "l1": "iso88591",
    "l2": "iso88592",
    "l3": "iso88593",
    "l4": "iso88594",
    "l5": "iso88599",
    "l6": "iso885910",
    "l7": "iso885913",
    "l8": "iso885914",
    "l9": "iso885915",
    "l10": "iso885916",

    "isoir14": "iso646jp",
    "isoir57": "iso646cn",
    "isoir100": "iso88591",
    "isoir101": "iso88592",
    "isoir109": "iso88593",
    "isoir110": "iso88594",
    "isoir144": "iso88595",
    "isoir127": "iso88596",
    "isoir126": "iso88597",
    "isoir138": "iso88598",
    "isoir148": "iso88599",
    "isoir157": "iso885910",
    "isoir166": "tis620",
    "isoir179": "iso885913",
    "isoir199": "iso885914",
    "isoir203": "iso885915",
    "isoir226": "iso885916",

    "cp819": "iso88591",
    "ibm819": "iso88591",

    "cyrillic": "iso88595",

    "arabic": "iso88596",
    "arabic8": "iso88596",
    "ecma114": "iso88596",
    "asmo708": "iso88596",

    "greek" : "iso88597",
    "greek8" : "iso88597",
    "ecma118" : "iso88597",
    "elot928" : "iso88597",

    "hebrew": "iso88598",
    "hebrew8": "iso88598",

    "turkish": "iso88599",
    "turkish8": "iso88599",

    "thai": "iso885911",
    "thai8": "iso885911",

    "celtic": "iso885914",
    "celtic8": "iso885914",
    "isoceltic": "iso885914",

    "tis6200": "tis620",
    "tis62025291": "tis620",
    "tis62025330": "tis620",

    "10000": "macroman",
    "10006": "macgreek",
    "10007": "maccyrillic",
    "10079": "maciceland",
    "10081": "macturkish",

    "cspc8codepage437": "cp437",
    "cspc775baltic": "cp775",
    "cspc850multilingual": "cp850",
    "cspcp852": "cp852",
    "cspc862latinhebrew": "cp862",
    "cpgr": "cp869",

    "msee": "cp1250",
    "mscyrl": "cp1251",
    "msansi": "cp1252",
    "msgreek": "cp1253",
    "msturk": "cp1254",
    "mshebr": "cp1255",
    "msarab": "cp1256",
    "winbaltrim": "cp1257",

    "cp20866": "koi8r",
    "20866": "koi8r",
    "ibm878": "koi8r",
    "cskoi8r": "koi8r",

    "cp21866": "koi8u",
    "21866": "koi8u",
    "ibm1168": "koi8u",

    "strk10482002": "rk1048",

    "tcvn5712": "tcvn",
    "tcvn57121": "tcvn",

    "gb198880": "iso646cn",
    "cn": "iso646cn",

    "csiso14jisc6220ro": "iso646jp",
    "jisc62201969ro": "iso646jp",
    "jp": "iso646jp",

    "cshproman8": "hproman8",
    "r8": "hproman8",
    "roman8": "hproman8",
    "xroman8": "hproman8",
    "ibm1051": "hproman8",

    "mac": "macintosh",
    "csmacintosh": "macintosh",
};



/***/ }),
/* 426 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


// Generated data for sbcs codec. Don't edit manually. Regenerate using generation/gen-sbcs.js script.
module.exports = {
  "437": "cp437",
  "737": "cp737",
  "775": "cp775",
  "850": "cp850",
  "852": "cp852",
  "855": "cp855",
  "856": "cp856",
  "857": "cp857",
  "858": "cp858",
  "860": "cp860",
  "861": "cp861",
  "862": "cp862",
  "863": "cp863",
  "864": "cp864",
  "865": "cp865",
  "866": "cp866",
  "869": "cp869",
  "874": "windows874",
  "922": "cp922",
  "1046": "cp1046",
  "1124": "cp1124",
  "1125": "cp1125",
  "1129": "cp1129",
  "1133": "cp1133",
  "1161": "cp1161",
  "1162": "cp1162",
  "1163": "cp1163",
  "1250": "windows1250",
  "1251": "windows1251",
  "1252": "windows1252",
  "1253": "windows1253",
  "1254": "windows1254",
  "1255": "windows1255",
  "1256": "windows1256",
  "1257": "windows1257",
  "1258": "windows1258",
  "28591": "iso88591",
  "28592": "iso88592",
  "28593": "iso88593",
  "28594": "iso88594",
  "28595": "iso88595",
  "28596": "iso88596",
  "28597": "iso88597",
  "28598": "iso88598",
  "28599": "iso88599",
  "28600": "iso885910",
  "28601": "iso885911",
  "28603": "iso885913",
  "28604": "iso885914",
  "28605": "iso885915",
  "28606": "iso885916",
  "windows874": {
    "type": "_sbcs",
    "chars": "€����…�����������‘’“”•–—�������� กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"
  },
  "win874": "windows874",
  "cp874": "windows874",
  "windows1250": {
    "type": "_sbcs",
    "chars": "€�‚�„…†‡�‰Š‹ŚŤŽŹ�‘’“”•–—�™š›śťžź ˇ˘Ł¤Ą¦§¨©Ş«¬­®Ż°±˛ł´µ¶·¸ąş»Ľ˝ľżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎĐŃŇÓÔŐÖ×ŘŮÚŰÜÝŢßŕáâăäĺćçčéęëěíîďđńňóôőö÷řůúűüýţ˙"
  },
  "win1250": "windows1250",
  "cp1250": "windows1250",
  "windows1251": {
    "type": "_sbcs",
    "chars": "ЂЃ‚ѓ„…†‡€‰Љ‹ЊЌЋЏђ‘’“”•–—�™љ›њќћџ ЎўЈ¤Ґ¦§Ё©Є«¬­®Ї°±Ііґµ¶·ё№є»јЅѕїАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"
  },
  "win1251": "windows1251",
  "cp1251": "windows1251",
  "windows1252": {
    "type": "_sbcs",
    "chars": "€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"
  },
  "win1252": "windows1252",
  "cp1252": "windows1252",
  "windows1253": {
    "type": "_sbcs",
    "chars": "€�‚ƒ„…†‡�‰�‹�����‘’“”•–—�™�›���� ΅Ά£¤¥¦§¨©�«¬­®―°±²³΄µ¶·ΈΉΊ»Ό½ΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ�ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώ�"
  },
  "win1253": "windows1253",
  "cp1253": "windows1253",
  "windows1254": {
    "type": "_sbcs",
    "chars": "€�‚ƒ„…†‡ˆ‰Š‹Œ����‘’“”•–—˜™š›œ��Ÿ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖ×ØÙÚÛÜİŞßàáâãäåæçèéêëìíîïğñòóôõö÷øùúûüışÿ"
  },
  "win1254": "windows1254",
  "cp1254": "windows1254",
  "windows1255": {
    "type": "_sbcs",
    "chars": "€�‚ƒ„…†‡ˆ‰�‹�����‘’“”•–—˜™�›���� ¡¢£₪¥¦§¨©×«¬­®¯°±²³´µ¶·¸¹÷»¼½¾¿ְֱֲֳִֵֶַָֹֺֻּֽ־ֿ׀ׁׂ׃װױײ׳״�������אבגדהוזחטיךכלםמןנסעףפץצקרשת��‎‏�"
  },
  "win1255": "windows1255",
  "cp1255": "windows1255",
  "windows1256": {
    "type": "_sbcs",
    "chars": "€پ‚ƒ„…†‡ˆ‰ٹ‹Œچژڈگ‘’“”•–—ک™ڑ›œ‌‍ں ،¢£¤¥¦§¨©ھ«¬­®¯°±²³´µ¶·¸¹؛»¼½¾؟ہءآأؤإئابةتثجحخدذرزسشصض×طظعغـفقكàلâمنهوçèéêëىيîïًٌٍَôُِ÷ّùْûü‎‏ے"
  },
  "win1256": "windows1256",
  "cp1256": "windows1256",
  "windows1257": {
    "type": "_sbcs",
    "chars": "€�‚�„…†‡�‰�‹�¨ˇ¸�‘’“”•–—�™�›�¯˛� �¢£¤�¦§Ø©Ŗ«¬­®Æ°±²³´µ¶·ø¹ŗ»¼½¾æĄĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠŃŅÓŌÕÖ×ŲŁŚŪÜŻŽßąįāćäåęēčéźėģķīļšńņóōõö÷ųłśūüżž˙"
  },
  "win1257": "windows1257",
  "cp1257": "windows1257",
  "windows1258": {
    "type": "_sbcs",
    "chars": "€�‚ƒ„…†‡ˆ‰�‹Œ����‘’“”•–—˜™�›œ��Ÿ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ"
  },
  "win1258": "windows1258",
  "cp1258": "windows1258",
  "iso88591": {
    "type": "_sbcs",
    "chars": " ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"
  },
  "cp28591": "iso88591",
  "iso88592": {
    "type": "_sbcs",
    "chars": " Ą˘Ł¤ĽŚ§¨ŠŞŤŹ­ŽŻ°ą˛ł´ľśˇ¸šşťź˝žżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎĐŃŇÓÔŐÖ×ŘŮÚŰÜÝŢßŕáâăäĺćçčéęëěíîďđńňóôőö÷řůúűüýţ˙"
  },
  "cp28592": "iso88592",
  "iso88593": {
    "type": "_sbcs",
    "chars": " Ħ˘£¤�Ĥ§¨İŞĞĴ­�Ż°ħ²³´µĥ·¸ışğĵ½�żÀÁÂ�ÄĊĈÇÈÉÊËÌÍÎÏ�ÑÒÓÔĠÖ×ĜÙÚÛÜŬŜßàáâ�äċĉçèéêëìíîï�ñòóôġö÷ĝùúûüŭŝ˙"
  },
  "cp28593": "iso88593",
  "iso88594": {
    "type": "_sbcs",
    "chars": " ĄĸŖ¤ĨĻ§¨ŠĒĢŦ­Ž¯°ą˛ŗ´ĩļˇ¸šēģŧŊžŋĀÁÂÃÄÅÆĮČÉĘËĖÍÎĪĐŅŌĶÔÕÖ×ØŲÚÛÜŨŪßāáâãäåæįčéęëėíîīđņōķôõö÷øųúûüũū˙"
  },
  "cp28594": "iso88594",
  "iso88595": {
    "type": "_sbcs",
    "chars": " ЁЂЃЄЅІЇЈЉЊЋЌ­ЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя№ёђѓєѕіїјљњћќ§ўџ"
  },
  "cp28595": "iso88595",
  "iso88596": {
    "type": "_sbcs",
    "chars": " ���¤�������،­�������������؛���؟�ءآأؤإئابةتثجحخدذرزسشصضطظعغ�����ـفقكلمنهوىيًٌٍَُِّْ�������������"
  },
  "cp28596": "iso88596",
  "iso88597": {
    "type": "_sbcs",
    "chars": " ‘’£€₯¦§¨©ͺ«¬­�―°±²³΄΅Ά·ΈΉΊ»Ό½ΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ�ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώ�"
  },
  "cp28597": "iso88597",
  "iso88598": {
    "type": "_sbcs",
    "chars": " �¢£¤¥¦§¨©×«¬­®¯°±²³´µ¶·¸¹÷»¼½¾��������������������������������‗אבגדהוזחטיךכלםמןנסעףפץצקרשת��‎‏�"
  },
  "cp28598": "iso88598",
  "iso88599": {
    "type": "_sbcs",
    "chars": " ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖ×ØÙÚÛÜİŞßàáâãäåæçèéêëìíîïğñòóôõö÷øùúûüışÿ"
  },
  "cp28599": "iso88599",
  "iso885910": {
    "type": "_sbcs",
    "chars": " ĄĒĢĪĨĶ§ĻĐŠŦŽ­ŪŊ°ąēģīĩķ·ļđšŧž―ūŋĀÁÂÃÄÅÆĮČÉĘËĖÍÎÏÐŅŌÓÔÕÖŨØŲÚÛÜÝÞßāáâãäåæįčéęëėíîïðņōóôõöũøųúûüýþĸ"
  },
  "cp28600": "iso885910",
  "iso885911": {
    "type": "_sbcs",
    "chars": " กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"
  },
  "cp28601": "iso885911",
  "iso885913": {
    "type": "_sbcs",
    "chars": " ”¢£¤„¦§Ø©Ŗ«¬­®Æ°±²³“µ¶·ø¹ŗ»¼½¾æĄĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠŃŅÓŌÕÖ×ŲŁŚŪÜŻŽßąįāćäåęēčéźėģķīļšńņóōõö÷ųłśūüżž’"
  },
  "cp28603": "iso885913",
  "iso885914": {
    "type": "_sbcs",
    "chars": " Ḃḃ£ĊċḊ§Ẁ©ẂḋỲ­®ŸḞḟĠġṀṁ¶ṖẁṗẃṠỳẄẅṡÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏŴÑÒÓÔÕÖṪØÙÚÛÜÝŶßàáâãäåæçèéêëìíîïŵñòóôõöṫøùúûüýŷÿ"
  },
  "cp28604": "iso885914",
  "iso885915": {
    "type": "_sbcs",
    "chars": " ¡¢£€¥Š§š©ª«¬­®¯°±²³Žµ¶·ž¹º»ŒœŸ¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"
  },
  "cp28605": "iso885915",
  "iso885916": {
    "type": "_sbcs",
    "chars": " ĄąŁ€„Š§š©Ș«Ź­źŻ°±ČłŽ”¶·žčș»ŒœŸżÀÁÂĂÄĆÆÇÈÉÊËÌÍÎÏĐŃÒÓÔŐÖŚŰÙÚÛÜĘȚßàáâăäćæçèéêëìíîïđńòóôőöśűùúûüęțÿ"
  },
  "cp28606": "iso885916",
  "cp437": {
    "type": "_sbcs",
    "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñÑªº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
  },
  "ibm437": "cp437",
  "csibm437": "cp437",
  "cp737": {
    "type": "_sbcs",
    "chars": "ΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩαβγδεζηθικλμνξοπρσςτυφχψ░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀ωάέήϊίόύϋώΆΈΉΊΌΎΏ±≥≤ΪΫ÷≈°∙·√ⁿ²■ "
  },
  "ibm737": "cp737",
  "csibm737": "cp737",
  "cp775": {
    "type": "_sbcs",
    "chars": "ĆüéāäģåćłēŖŗīŹÄÅÉæÆōöĢ¢ŚśÖÜø£Ø×¤ĀĪóŻżź”¦©®¬½¼Ł«»░▒▓│┤ĄČĘĖ╣║╗╝ĮŠ┐└┴┬├─┼ŲŪ╚╔╩╦╠═╬Žąčęėįšųūž┘┌█▄▌▐▀ÓßŌŃõÕµńĶķĻļņĒŅ’­±“¾¶§÷„°∙·¹³²■ "
  },
  "ibm775": "cp775",
  "csibm775": "cp775",
  "cp850": {
    "type": "_sbcs",
    "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø×ƒáíóúñÑªº¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ðÐÊËÈıÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµþÞÚÛÙýÝ¯´­±‗¾¶§÷¸°¨·¹³²■ "
  },
  "ibm850": "cp850",
  "csibm850": "cp850",
  "cp852": {
    "type": "_sbcs",
    "chars": "ÇüéâäůćçłëŐőîŹÄĆÉĹĺôöĽľŚśÖÜŤťŁ×čáíóúĄąŽžĘę¬źČş«»░▒▓│┤ÁÂĚŞ╣║╗╝Żż┐└┴┬├─┼Ăă╚╔╩╦╠═╬¤đĐĎËďŇÍÎě┘┌█▄ŢŮ▀ÓßÔŃńňŠšŔÚŕŰýÝţ´­˝˛ˇ˘§÷¸°¨˙űŘř■ "
  },
  "ibm852": "cp852",
  "csibm852": "cp852",
  "cp855": {
    "type": "_sbcs",
    "chars": "ђЂѓЃёЁєЄѕЅіІїЇјЈљЉњЊћЋќЌўЎџЏюЮъЪаАбБцЦдДеЕфФгГ«»░▒▓│┤хХиИ╣║╗╝йЙ┐└┴┬├─┼кК╚╔╩╦╠═╬¤лЛмМнНоОп┘┌█▄Пя▀ЯрРсСтТуУжЖвВьЬ№­ыЫзЗшШэЭщЩчЧ§■ "
  },
  "ibm855": "cp855",
  "csibm855": "cp855",
  "cp856": {
    "type": "_sbcs",
    "chars": "אבגדהוזחטיךכלםמןנסעףפץצקרשת�£�×����������®¬½¼�«»░▒▓│┤���©╣║╗╝¢¥┐└┴┬├─┼��╚╔╩╦╠═╬¤���������┘┌█▄¦�▀������µ�������¯´­±‗¾¶§÷¸°¨·¹³²■ "
  },
  "ibm856": "cp856",
  "csibm856": "cp856",
  "cp857": {
    "type": "_sbcs",
    "chars": "ÇüéâäàåçêëèïîıÄÅÉæÆôöòûùİÖÜø£ØŞşáíóúñÑĞğ¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ºªÊËÈ�ÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµ�×ÚÛÙìÿ¯´­±�¾¶§÷¸°¨·¹³²■ "
  },
  "ibm857": "cp857",
  "csibm857": "cp857",
  "cp858": {
    "type": "_sbcs",
    "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø×ƒáíóúñÑªº¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ðÐÊËÈ€ÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµþÞÚÛÙýÝ¯´­±‗¾¶§÷¸°¨·¹³²■ "
  },
  "ibm858": "cp858",
  "csibm858": "cp858",
  "cp860": {
    "type": "_sbcs",
    "chars": "ÇüéâãàÁçêÊèÍÔìÃÂÉÀÈôõòÚùÌÕÜ¢£Ù₧ÓáíóúñÑªº¿Ò¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
  },
  "ibm860": "cp860",
  "csibm860": "cp860",
  "cp861": {
    "type": "_sbcs",
    "chars": "ÇüéâäàåçêëèÐðÞÄÅÉæÆôöþûÝýÖÜø£Ø₧ƒáíóúÁÍÓÚ¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
  },
  "ibm861": "cp861",
  "csibm861": "cp861",
  "cp862": {
    "type": "_sbcs",
    "chars": "אבגדהוזחטיךכלםמןנסעףפץצקרשת¢£¥₧ƒáíóúñÑªº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
  },
  "ibm862": "cp862",
  "csibm862": "cp862",
  "cp863": {
    "type": "_sbcs",
    "chars": "ÇüéâÂà¶çêëèïî‗À§ÉÈÊôËÏûù¤ÔÜ¢£ÙÛƒ¦´óú¨¸³¯Î⌐¬½¼¾«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
  },
  "ibm863": "cp863",
  "csibm863": "cp863",
  "cp864": {
    "type": "_sbcs",
    "chars": "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#$٪&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~°·∙√▒─│┼┤┬├┴┐┌└┘β∞φ±½¼≈«»ﻷﻸ��ﻻﻼ� ­ﺂ£¤ﺄ��ﺎﺏﺕﺙ،ﺝﺡﺥ٠١٢٣٤٥٦٧٨٩ﻑ؛ﺱﺵﺹ؟¢ﺀﺁﺃﺅﻊﺋﺍﺑﺓﺗﺛﺟﺣﺧﺩﺫﺭﺯﺳﺷﺻﺿﻁﻅﻋﻏ¦¬÷×ﻉـﻓﻗﻛﻟﻣﻧﻫﻭﻯﻳﺽﻌﻎﻍﻡﹽّﻥﻩﻬﻰﻲﻐﻕﻵﻶﻝﻙﻱ■�"
  },
  "ibm864": "cp864",
  "csibm864": "cp864",
  "cp865": {
    "type": "_sbcs",
    "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø₧ƒáíóúñÑªº¿⌐¬½¼¡«¤░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
  },
  "ibm865": "cp865",
  "csibm865": "cp865",
  "cp866": {
    "type": "_sbcs",
    "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№¤■ "
  },
  "ibm866": "cp866",
  "csibm866": "cp866",
  "cp869": {
    "type": "_sbcs",
    "chars": "������Ά�·¬¦‘’Έ―ΉΊΪΌ��ΎΫ©Ώ²³ά£έήίϊΐόύΑΒΓΔΕΖΗ½ΘΙ«»░▒▓│┤ΚΛΜΝ╣║╗╝ΞΟ┐└┴┬├─┼ΠΡ╚╔╩╦╠═╬ΣΤΥΦΧΨΩαβγ┘┌█▄δε▀ζηθικλμνξοπρσςτ΄­±υφχ§ψ΅°¨ωϋΰώ■ "
  },
  "ibm869": "cp869",
  "csibm869": "cp869",
  "cp922": {
    "type": "_sbcs",
    "chars": " ¡¢£¤¥¦§¨©ª«¬­®‾°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏŠÑÒÓÔÕÖ×ØÙÚÛÜÝŽßàáâãäåæçèéêëìíîïšñòóôõö÷øùúûüýžÿ"
  },
  "ibm922": "cp922",
  "csibm922": "cp922",
  "cp1046": {
    "type": "_sbcs",
    "chars": "ﺈ×÷ﹱ■│─┐┌└┘ﹹﹻﹽﹿﹷﺊﻰﻳﻲﻎﻏﻐﻶﻸﻺﻼ ¤ﺋﺑﺗﺛﺟﺣ،­ﺧﺳ٠١٢٣٤٥٦٧٨٩ﺷ؛ﺻﺿﻊ؟ﻋءآأؤإئابةتثجحخدذرزسشصضطﻇعغﻌﺂﺄﺎﻓـفقكلمنهوىيًٌٍَُِّْﻗﻛﻟﻵﻷﻹﻻﻣﻧﻬﻩ�"
  },
  "ibm1046": "cp1046",
  "csibm1046": "cp1046",
  "cp1124": {
    "type": "_sbcs",
    "chars": " ЁЂҐЄЅІЇЈЉЊЋЌ­ЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя№ёђґєѕіїјљњћќ§ўџ"
  },
  "ibm1124": "cp1124",
  "csibm1124": "cp1124",
  "cp1125": {
    "type": "_sbcs",
    "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёҐґЄєІіЇї·√№¤■ "
  },
  "ibm1125": "cp1125",
  "csibm1125": "cp1125",
  "cp1129": {
    "type": "_sbcs",
    "chars": " ¡¢£¤¥¦§œ©ª«¬­®¯°±²³Ÿµ¶·Œ¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ"
  },
  "ibm1129": "cp1129",
  "csibm1129": "cp1129",
  "cp1133": {
    "type": "_sbcs",
    "chars": " ກຂຄງຈສຊຍດຕຖທນບປຜຝພຟມຢຣລວຫອຮ���ຯະາຳິີຶືຸູຼັົຽ���ເແໂໃໄ່້໊໋໌ໍໆ�ໜໝ₭����������������໐໑໒໓໔໕໖໗໘໙��¢¬¦�"
  },
  "ibm1133": "cp1133",
  "csibm1133": "cp1133",
  "cp1161": {
    "type": "_sbcs",
    "chars": "��������������������������������่กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู้๊๋€฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛¢¬¦ "
  },
  "ibm1161": "cp1161",
  "csibm1161": "cp1161",
  "cp1162": {
    "type": "_sbcs",
    "chars": "€…‘’“”•–— กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"
  },
  "ibm1162": "cp1162",
  "csibm1162": "cp1162",
  "cp1163": {
    "type": "_sbcs",
    "chars": " ¡¢£€¥¦§œ©ª«¬­®¯°±²³Ÿµ¶·Œ¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ"
  },
  "ibm1163": "cp1163",
  "csibm1163": "cp1163",
  "maccroatian": {
    "type": "_sbcs",
    "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®Š™´¨≠ŽØ∞±≤≥∆µ∂∑∏š∫ªºΩžø¿¡¬√ƒ≈Ć«Č… ÀÃÕŒœĐ—“”‘’÷◊�©⁄¤‹›Æ»–·‚„‰ÂćÁčÈÍÎÏÌÓÔđÒÚÛÙıˆ˜¯πË˚¸Êæˇ"
  },
  "maccyrillic": {
    "type": "_sbcs",
    "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ†°¢£§•¶І®©™Ђђ≠Ѓѓ∞±≤≥іµ∂ЈЄєЇїЉљЊњјЅ¬√ƒ≈∆«»… ЋћЌќѕ–—“”‘’÷„ЎўЏџ№Ёёяабвгдежзийклмнопрстуфхцчшщъыьэю¤"
  },
  "macgreek": {
    "type": "_sbcs",
    "chars": "Ä¹²É³ÖÜ΅àâä΄¨çéèêë£™îï•½‰ôö¦­ùûü†ΓΔΘΛΞΠß®©ΣΪ§≠°·Α±≤≥¥ΒΕΖΗΙΚΜΦΫΨΩάΝ¬ΟΡ≈Τ«»… ΥΧΆΈœ–―“”‘’÷ΉΊΌΎέήίόΏύαβψδεφγηιξκλμνοπώρστθωςχυζϊϋΐΰ�"
  },
  "maciceland": {
    "type": "_sbcs",
    "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûüÝ°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤ÐðÞþý·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"
  },
  "macroman": {
    "type": "_sbcs",
    "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›ﬁﬂ‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"
  },
  "macromania": {
    "type": "_sbcs",
    "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ĂŞ∞±≤≥¥µ∂∑∏π∫ªºΩăş¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›Ţţ‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"
  },
  "macthai": {
    "type": "_sbcs",
    "chars": "«»…“”�•‘’� กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู﻿​–—฿เแโใไๅๆ็่้๊๋์ํ™๏๐๑๒๓๔๕๖๗๘๙®©����"
  },
  "macturkish": {
    "type": "_sbcs",
    "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸĞğİıŞş‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙ�ˆ˜¯˘˙˚¸˝˛ˇ"
  },
  "macukraine": {
    "type": "_sbcs",
    "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ†°Ґ£§•¶І®©™Ђђ≠Ѓѓ∞±≤≥іµґЈЄєЇїЉљЊњјЅ¬√ƒ≈∆«»… ЋћЌќѕ–—“”‘’÷„ЎўЏџ№Ёёяабвгдежзийклмнопрстуфхцчшщъыьэю¤"
  },
  "koi8r": {
    "type": "_sbcs",
    "chars": "─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ё╓╔╕╖╗╘╙╚╛╜╝╞╟╠╡Ё╢╣╤╥╦╧╨╩╪╫╬©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"
  },
  "koi8u": {
    "type": "_sbcs",
    "chars": "─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ёє╔ії╗╘╙╚╛ґ╝╞╟╠╡ЁЄ╣ІЇ╦╧╨╩╪Ґ╬©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"
  },
  "koi8ru": {
    "type": "_sbcs",
    "chars": "─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ёє╔ії╗╘╙╚╛ґў╞╟╠╡ЁЄ╣ІЇ╦╧╨╩╪ҐЎ©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"
  },
  "koi8t": {
    "type": "_sbcs",
    "chars": "қғ‚Ғ„…†‡�‰ҳ‹ҲҷҶ�Қ‘’“”•–—�™�›�����ӯӮё¤ӣ¦§���«¬­®�°±²Ё�Ӣ¶·�№�»���©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ"
  },
  "armscii8": {
    "type": "_sbcs",
    "chars": " �և։)(»«—.՝,-֊…՜՛՞ԱաԲբԳգԴդԵեԶզԷէԸըԹթԺժԻիԼլԽխԾծԿկՀհՁձՂղՃճՄմՅյՆնՇշՈոՉչՊպՋջՌռՍսՎվՏտՐրՑցՒւՓփՔքՕօՖֆ՚�"
  },
  "rk1048": {
    "type": "_sbcs",
    "chars": "ЂЃ‚ѓ„…†‡€‰Љ‹ЊҚҺЏђ‘’“”•–—�™љ›њқһџ ҰұӘ¤Ө¦§Ё©Ғ«¬­®Ү°±Ііөµ¶·ё№ғ»әҢңүАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"
  },
  "tcvn": {
    "type": "_sbcs",
    "chars": "\u0000ÚỤ\u0003ỪỬỮ\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010ỨỰỲỶỸÝỴ\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ÀẢÃÁẠẶẬÈẺẼÉẸỆÌỈĨÍỊÒỎÕÓỌỘỜỞỠỚỢÙỦŨ ĂÂÊÔƠƯĐăâêôơưđẶ̀̀̉̃́àảãáạẲằẳẵắẴẮẦẨẪẤỀặầẩẫấậèỂẻẽéẹềểễếệìỉỄẾỒĩíịòỔỏõóọồổỗốộờởỡớợùỖủũúụừửữứựỳỷỹýỵỐ"
  },
  "georgianacademy": {
    "type": "_sbcs",
    "chars": "‚ƒ„…†‡ˆ‰Š‹Œ‘’“”•–—˜™š›œŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿აბგდევზთიკლმნოპჟრსტუფქღყშჩცძწჭხჯჰჱჲჳჴჵჶçèéêëìíîïðñòóôõö÷øùúûüýþÿ"
  },
  "georgianps": {
    "type": "_sbcs",
    "chars": "‚ƒ„…†‡ˆ‰Š‹Œ‘’“”•–—˜™š›œŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿აბგდევზჱთიკლმნჲოპჟრსტჳუფქღყშჩცძწჭხჴჯჰჵæçèéêëìíîïðñòóôõö÷øùúûüýþÿ"
  },
  "pt154": {
    "type": "_sbcs",
    "chars": "ҖҒӮғ„…ҶҮҲүҠӢҢҚҺҸҗ‘’“”•–—ҳҷҡӣңқһҹ ЎўЈӨҘҰ§Ё©Ә«¬ӯ®Ҝ°ұІіҙө¶·ё№ә»јҪҫҝАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"
  },
  "viscii": {
    "type": "_sbcs",
    "chars": "\u0000\u0001Ẳ\u0003\u0004ẴẪ\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013Ỷ\u0015\u0016\u0017\u0018Ỹ\u001a\u001b\u001c\u001dỴ\u001f !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ẠẮẰẶẤẦẨẬẼẸẾỀỂỄỆỐỒỔỖỘỢỚỜỞỊỎỌỈỦŨỤỲÕắằặấầẩậẽẹếềểễệốồổỗỠƠộờởịỰỨỪỬơớƯÀÁÂÃẢĂẳẵÈÉÊẺÌÍĨỳĐứÒÓÔạỷừửÙÚỹỵÝỡưàáâãảăữẫèéêẻìíĩỉđựòóôõỏọụùúũủýợỮ"
  },
  "iso646cn": {
    "type": "_sbcs",
    "chars": "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#¥%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}‾��������������������������������������������������������������������������������������������������������������������������������"
  },
  "iso646jp": {
    "type": "_sbcs",
    "chars": "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[¥]^_`abcdefghijklmnopqrstuvwxyz{|}‾��������������������������������������������������������������������������������������������������������������������������������"
  },
  "hproman8": {
    "type": "_sbcs",
    "chars": " ÀÂÈÊËÎÏ´ˋˆ¨˜ÙÛ₤¯Ýý°ÇçÑñ¡¿¤£¥§ƒ¢âêôûáéóúàèòùäëöüÅîØÆåíøæÄìÖÜÉïßÔÁÃãÐðÍÌÓÒÕõŠšÚŸÿÞþ·µ¶¾—¼½ªº«■»±�"
  },
  "macintosh": {
    "type": "_sbcs",
    "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›ﬁﬂ‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ"
  },
  "ascii": {
    "type": "_sbcs",
    "chars": "��������������������������������������������������������������������������������������������������������������������������������"
  },
  "tis620": {
    "type": "_sbcs",
    "chars": "���������������������������������กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����"
  }
}

/***/ }),
/* 427 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var Buffer = __webpack_require__(127).Buffer;

// Multibyte codec. In this scheme, a character is represented by 1 or more bytes.
// Our codec supports UTF-16 surrogates, extensions for GB18030 and unicode sequences.
// To save memory and loading time, we read table files only when requested.

exports._dbcs = DBCSCodec;

var UNASSIGNED = -1,
    GB18030_CODE = -2,
    SEQ_START  = -10,
    NODE_START = -1000,
    UNASSIGNED_NODE = new Array(0x100),
    DEF_CHAR = -1;

for (var i = 0; i < 0x100; i++)
    UNASSIGNED_NODE[i] = UNASSIGNED;


// Class DBCSCodec reads and initializes mapping tables.
function DBCSCodec(codecOptions, iconv) {
    this.encodingName = codecOptions.encodingName;
    if (!codecOptions)
        throw new Error("DBCS codec is called without the data.")
    if (!codecOptions.table)
        throw new Error("Encoding '" + this.encodingName + "' has no data.");

    // Load tables.
    var mappingTable = codecOptions.table();


    // Decode tables: MBCS -> Unicode.

    // decodeTables is a trie, encoded as an array of arrays of integers. Internal arrays are trie nodes and all have len = 256.
    // Trie root is decodeTables[0].
    // Values: >=  0 -> unicode character code. can be > 0xFFFF
    //         == UNASSIGNED -> unknown/unassigned sequence.
    //         == GB18030_CODE -> this is the end of a GB18030 4-byte sequence.
    //         <= NODE_START -> index of the next node in our trie to process next byte.
    //         <= SEQ_START  -> index of the start of a character code sequence, in decodeTableSeq.
    this.decodeTables = [];
    this.decodeTables[0] = UNASSIGNED_NODE.slice(0); // Create root node.

    // Sometimes a MBCS char corresponds to a sequence of unicode chars. We store them as arrays of integers here. 
    this.decodeTableSeq = [];

    // Actual mapping tables consist of chunks. Use them to fill up decode tables.
    for (var i = 0; i < mappingTable.length; i++)
        this._addDecodeChunk(mappingTable[i]);

    this.defaultCharUnicode = iconv.defaultCharUnicode;

    
    // Encode tables: Unicode -> DBCS.

    // `encodeTable` is array mapping from unicode char to encoded char. All its values are integers for performance.
    // Because it can be sparse, it is represented as array of buckets by 256 chars each. Bucket can be null.
    // Values: >=  0 -> it is a normal char. Write the value (if <=256 then 1 byte, if <=65536 then 2 bytes, etc.).
    //         == UNASSIGNED -> no conversion found. Output a default char.
    //         <= SEQ_START  -> it's an index in encodeTableSeq, see below. The character starts a sequence.
    this.encodeTable = [];
    
    // `encodeTableSeq` is used when a sequence of unicode characters is encoded as a single code. We use a tree of
    // objects where keys correspond to characters in sequence and leafs are the encoded dbcs values. A special DEF_CHAR key
    // means end of sequence (needed when one sequence is a strict subsequence of another).
    // Objects are kept separately from encodeTable to increase performance.
    this.encodeTableSeq = [];

    // Some chars can be decoded, but need not be encoded.
    var skipEncodeChars = {};
    if (codecOptions.encodeSkipVals)
        for (var i = 0; i < codecOptions.encodeSkipVals.length; i++) {
            var val = codecOptions.encodeSkipVals[i];
            if (typeof val === 'number')
                skipEncodeChars[val] = true;
            else
                for (var j = val.from; j <= val.to; j++)
                    skipEncodeChars[j] = true;
        }
        
    // Use decode trie to recursively fill out encode tables.
    this._fillEncodeTable(0, 0, skipEncodeChars);

    // Add more encoding pairs when needed.
    if (codecOptions.encodeAdd) {
        for (var uChar in codecOptions.encodeAdd)
            if (Object.prototype.hasOwnProperty.call(codecOptions.encodeAdd, uChar))
                this._setEncodeChar(uChar.charCodeAt(0), codecOptions.encodeAdd[uChar]);
    }

    this.defCharSB  = this.encodeTable[0][iconv.defaultCharSingleByte.charCodeAt(0)];
    if (this.defCharSB === UNASSIGNED) this.defCharSB = this.encodeTable[0]['?'];
    if (this.defCharSB === UNASSIGNED) this.defCharSB = "?".charCodeAt(0);


    // Load & create GB18030 tables when needed.
    if (typeof codecOptions.gb18030 === 'function') {
        this.gb18030 = codecOptions.gb18030(); // Load GB18030 ranges.

        // Add GB18030 decode tables.
        var thirdByteNodeIdx = this.decodeTables.length;
        var thirdByteNode = this.decodeTables[thirdByteNodeIdx] = UNASSIGNED_NODE.slice(0);

        var fourthByteNodeIdx = this.decodeTables.length;
        var fourthByteNode = this.decodeTables[fourthByteNodeIdx] = UNASSIGNED_NODE.slice(0);

        for (var i = 0x81; i <= 0xFE; i++) {
            var secondByteNodeIdx = NODE_START - this.decodeTables[0][i];
            var secondByteNode = this.decodeTables[secondByteNodeIdx];
            for (var j = 0x30; j <= 0x39; j++)
                secondByteNode[j] = NODE_START - thirdByteNodeIdx;
        }
        for (var i = 0x81; i <= 0xFE; i++)
            thirdByteNode[i] = NODE_START - fourthByteNodeIdx;
        for (var i = 0x30; i <= 0x39; i++)
            fourthByteNode[i] = GB18030_CODE
    }        
}

DBCSCodec.prototype.encoder = DBCSEncoder;
DBCSCodec.prototype.decoder = DBCSDecoder;

// Decoder helpers
DBCSCodec.prototype._getDecodeTrieNode = function(addr) {
    var bytes = [];
    for (; addr > 0; addr >>= 8)
        bytes.push(addr & 0xFF);
    if (bytes.length == 0)
        bytes.push(0);

    var node = this.decodeTables[0];
    for (var i = bytes.length-1; i > 0; i--) { // Traverse nodes deeper into the trie.
        var val = node[bytes[i]];

        if (val == UNASSIGNED) { // Create new node.
            node[bytes[i]] = NODE_START - this.decodeTables.length;
            this.decodeTables.push(node = UNASSIGNED_NODE.slice(0));
        }
        else if (val <= NODE_START) { // Existing node.
            node = this.decodeTables[NODE_START - val];
        }
        else
            throw new Error("Overwrite byte in " + this.encodingName + ", addr: " + addr.toString(16));
    }
    return node;
}


DBCSCodec.prototype._addDecodeChunk = function(chunk) {
    // First element of chunk is the hex mbcs code where we start.
    var curAddr = parseInt(chunk[0], 16);

    // Choose the decoding node where we'll write our chars.
    var writeTable = this._getDecodeTrieNode(curAddr);
    curAddr = curAddr & 0xFF;

    // Write all other elements of the chunk to the table.
    for (var k = 1; k < chunk.length; k++) {
        var part = chunk[k];
        if (typeof part === "string") { // String, write as-is.
            for (var l = 0; l < part.length;) {
                var code = part.charCodeAt(l++);
                if (0xD800 <= code && code < 0xDC00) { // Decode surrogate
                    var codeTrail = part.charCodeAt(l++);
                    if (0xDC00 <= codeTrail && codeTrail < 0xE000)
                        writeTable[curAddr++] = 0x10000 + (code - 0xD800) * 0x400 + (codeTrail - 0xDC00);
                    else
                        throw new Error("Incorrect surrogate pair in "  + this.encodingName + " at chunk " + chunk[0]);
                }
                else if (0x0FF0 < code && code <= 0x0FFF) { // Character sequence (our own encoding used)
                    var len = 0xFFF - code + 2;
                    var seq = [];
                    for (var m = 0; m < len; m++)
                        seq.push(part.charCodeAt(l++)); // Simple variation: don't support surrogates or subsequences in seq.

                    writeTable[curAddr++] = SEQ_START - this.decodeTableSeq.length;
                    this.decodeTableSeq.push(seq);
                }
                else
                    writeTable[curAddr++] = code; // Basic char
            }
        } 
        else if (typeof part === "number") { // Integer, meaning increasing sequence starting with prev character.
            var charCode = writeTable[curAddr - 1] + 1;
            for (var l = 0; l < part; l++)
                writeTable[curAddr++] = charCode++;
        }
        else
            throw new Error("Incorrect type '" + typeof part + "' given in "  + this.encodingName + " at chunk " + chunk[0]);
    }
    if (curAddr > 0xFF)
        throw new Error("Incorrect chunk in "  + this.encodingName + " at addr " + chunk[0] + ": too long" + curAddr);
}

// Encoder helpers
DBCSCodec.prototype._getEncodeBucket = function(uCode) {
    var high = uCode >> 8; // This could be > 0xFF because of astral characters.
    if (this.encodeTable[high] === undefined)
        this.encodeTable[high] = UNASSIGNED_NODE.slice(0); // Create bucket on demand.
    return this.encodeTable[high];
}

DBCSCodec.prototype._setEncodeChar = function(uCode, dbcsCode) {
    var bucket = this._getEncodeBucket(uCode);
    var low = uCode & 0xFF;
    if (bucket[low] <= SEQ_START)
        this.encodeTableSeq[SEQ_START-bucket[low]][DEF_CHAR] = dbcsCode; // There's already a sequence, set a single-char subsequence of it.
    else if (bucket[low] == UNASSIGNED)
        bucket[low] = dbcsCode;
}

DBCSCodec.prototype._setEncodeSequence = function(seq, dbcsCode) {
    
    // Get the root of character tree according to first character of the sequence.
    var uCode = seq[0];
    var bucket = this._getEncodeBucket(uCode);
    var low = uCode & 0xFF;

    var node;
    if (bucket[low] <= SEQ_START) {
        // There's already a sequence with  - use it.
        node = this.encodeTableSeq[SEQ_START-bucket[low]];
    }
    else {
        // There was no sequence object - allocate a new one.
        node = {};
        if (bucket[low] !== UNASSIGNED) node[DEF_CHAR] = bucket[low]; // If a char was set before - make it a single-char subsequence.
        bucket[low] = SEQ_START - this.encodeTableSeq.length;
        this.encodeTableSeq.push(node);
    }

    // Traverse the character tree, allocating new nodes as needed.
    for (var j = 1; j < seq.length-1; j++) {
        var oldVal = node[uCode];
        if (typeof oldVal === 'object')
            node = oldVal;
        else {
            node = node[uCode] = {}
            if (oldVal !== undefined)
                node[DEF_CHAR] = oldVal
        }
    }

    // Set the leaf to given dbcsCode.
    uCode = seq[seq.length-1];
    node[uCode] = dbcsCode;
}

DBCSCodec.prototype._fillEncodeTable = function(nodeIdx, prefix, skipEncodeChars) {
    var node = this.decodeTables[nodeIdx];
    for (var i = 0; i < 0x100; i++) {
        var uCode = node[i];
        var mbCode = prefix + i;
        if (skipEncodeChars[mbCode])
            continue;

        if (uCode >= 0)
            this._setEncodeChar(uCode, mbCode);
        else if (uCode <= NODE_START)
            this._fillEncodeTable(NODE_START - uCode, mbCode << 8, skipEncodeChars);
        else if (uCode <= SEQ_START)
            this._setEncodeSequence(this.decodeTableSeq[SEQ_START - uCode], mbCode);
    }
}



// == Encoder ==================================================================

function DBCSEncoder(options, codec) {
    // Encoder state
    this.leadSurrogate = -1;
    this.seqObj = undefined;
    
    // Static data
    this.encodeTable = codec.encodeTable;
    this.encodeTableSeq = codec.encodeTableSeq;
    this.defaultCharSingleByte = codec.defCharSB;
    this.gb18030 = codec.gb18030;
}

DBCSEncoder.prototype.write = function(str) {
    var newBuf = Buffer.alloc(str.length * (this.gb18030 ? 4 : 3)),
        leadSurrogate = this.leadSurrogate,
        seqObj = this.seqObj, nextChar = -1,
        i = 0, j = 0;

    while (true) {
        // 0. Get next character.
        if (nextChar === -1) {
            if (i == str.length) break;
            var uCode = str.charCodeAt(i++);
        }
        else {
            var uCode = nextChar;
            nextChar = -1;    
        }

        // 1. Handle surrogates.
        if (0xD800 <= uCode && uCode < 0xE000) { // Char is one of surrogates.
            if (uCode < 0xDC00) { // We've got lead surrogate.
                if (leadSurrogate === -1) {
                    leadSurrogate = uCode;
                    continue;
                } else {
                    leadSurrogate = uCode;
                    // Double lead surrogate found.
                    uCode = UNASSIGNED;
                }
            } else { // We've got trail surrogate.
                if (leadSurrogate !== -1) {
                    uCode = 0x10000 + (leadSurrogate - 0xD800) * 0x400 + (uCode - 0xDC00);
                    leadSurrogate = -1;
                } else {
                    // Incomplete surrogate pair - only trail surrogate found.
                    uCode = UNASSIGNED;
                }
                
            }
        }
        else if (leadSurrogate !== -1) {
            // Incomplete surrogate pair - only lead surrogate found.
            nextChar = uCode; uCode = UNASSIGNED; // Write an error, then current char.
            leadSurrogate = -1;
        }

        // 2. Convert uCode character.
        var dbcsCode = UNASSIGNED;
        if (seqObj !== undefined && uCode != UNASSIGNED) { // We are in the middle of the sequence
            var resCode = seqObj[uCode];
            if (typeof resCode === 'object') { // Sequence continues.
                seqObj = resCode;
                continue;

            } else if (typeof resCode == 'number') { // Sequence finished. Write it.
                dbcsCode = resCode;

            } else if (resCode == undefined) { // Current character is not part of the sequence.

                // Try default character for this sequence
                resCode = seqObj[DEF_CHAR];
                if (resCode !== undefined) {
                    dbcsCode = resCode; // Found. Write it.
                    nextChar = uCode; // Current character will be written too in the next iteration.

                } else {
                    // TODO: What if we have no default? (resCode == undefined)
                    // Then, we should write first char of the sequence as-is and try the rest recursively.
                    // Didn't do it for now because no encoding has this situation yet.
                    // Currently, just skip the sequence and write current char.
                }
            }
            seqObj = undefined;
        }
        else if (uCode >= 0) {  // Regular character
            var subtable = this.encodeTable[uCode >> 8];
            if (subtable !== undefined)
                dbcsCode = subtable[uCode & 0xFF];
            
            if (dbcsCode <= SEQ_START) { // Sequence start
                seqObj = this.encodeTableSeq[SEQ_START-dbcsCode];
                continue;
            }

            if (dbcsCode == UNASSIGNED && this.gb18030) {
                // Use GB18030 algorithm to find character(s) to write.
                var idx = findIdx(this.gb18030.uChars, uCode);
                if (idx != -1) {
                    var dbcsCode = this.gb18030.gbChars[idx] + (uCode - this.gb18030.uChars[idx]);
                    newBuf[j++] = 0x81 + Math.floor(dbcsCode / 12600); dbcsCode = dbcsCode % 12600;
                    newBuf[j++] = 0x30 + Math.floor(dbcsCode / 1260); dbcsCode = dbcsCode % 1260;
                    newBuf[j++] = 0x81 + Math.floor(dbcsCode / 10); dbcsCode = dbcsCode % 10;
                    newBuf[j++] = 0x30 + dbcsCode;
                    continue;
                }
            }
        }

        // 3. Write dbcsCode character.
        if (dbcsCode === UNASSIGNED)
            dbcsCode = this.defaultCharSingleByte;
        
        if (dbcsCode < 0x100) {
            newBuf[j++] = dbcsCode;
        }
        else if (dbcsCode < 0x10000) {
            newBuf[j++] = dbcsCode >> 8;   // high byte
            newBuf[j++] = dbcsCode & 0xFF; // low byte
        }
        else {
            newBuf[j++] = dbcsCode >> 16;
            newBuf[j++] = (dbcsCode >> 8) & 0xFF;
            newBuf[j++] = dbcsCode & 0xFF;
        }
    }

    this.seqObj = seqObj;
    this.leadSurrogate = leadSurrogate;
    return newBuf.slice(0, j);
}

DBCSEncoder.prototype.end = function() {
    if (this.leadSurrogate === -1 && this.seqObj === undefined)
        return; // All clean. Most often case.

    var newBuf = Buffer.alloc(10), j = 0;

    if (this.seqObj) { // We're in the sequence.
        var dbcsCode = this.seqObj[DEF_CHAR];
        if (dbcsCode !== undefined) { // Write beginning of the sequence.
            if (dbcsCode < 0x100) {
                newBuf[j++] = dbcsCode;
            }
            else {
                newBuf[j++] = dbcsCode >> 8;   // high byte
                newBuf[j++] = dbcsCode & 0xFF; // low byte
            }
        } else {
            // See todo above.
        }
        this.seqObj = undefined;
    }

    if (this.leadSurrogate !== -1) {
        // Incomplete surrogate pair - only lead surrogate found.
        newBuf[j++] = this.defaultCharSingleByte;
        this.leadSurrogate = -1;
    }
    
    return newBuf.slice(0, j);
}

// Export for testing
DBCSEncoder.prototype.findIdx = findIdx;


// == Decoder ==================================================================

function DBCSDecoder(options, codec) {
    // Decoder state
    this.nodeIdx = 0;
    this.prevBuf = Buffer.alloc(0);

    // Static data
    this.decodeTables = codec.decodeTables;
    this.decodeTableSeq = codec.decodeTableSeq;
    this.defaultCharUnicode = codec.defaultCharUnicode;
    this.gb18030 = codec.gb18030;
}

DBCSDecoder.prototype.write = function(buf) {
    var newBuf = Buffer.alloc(buf.length*2),
        nodeIdx = this.nodeIdx, 
        prevBuf = this.prevBuf, prevBufOffset = this.prevBuf.length,
        seqStart = -this.prevBuf.length, // idx of the start of current parsed sequence.
        uCode;

    if (prevBufOffset > 0) // Make prev buf overlap a little to make it easier to slice later.
        prevBuf = Buffer.concat([prevBuf, buf.slice(0, 10)]);
    
    for (var i = 0, j = 0; i < buf.length; i++) {
        var curByte = (i >= 0) ? buf[i] : prevBuf[i + prevBufOffset];

        // Lookup in current trie node.
        var uCode = this.decodeTables[nodeIdx][curByte];

        if (uCode >= 0) { 
            // Normal character, just use it.
        }
        else if (uCode === UNASSIGNED) { // Unknown char.
            // TODO: Callback with seq.
            //var curSeq = (seqStart >= 0) ? buf.slice(seqStart, i+1) : prevBuf.slice(seqStart + prevBufOffset, i+1 + prevBufOffset);
            i = seqStart; // Try to parse again, after skipping first byte of the sequence ('i' will be incremented by 'for' cycle).
            uCode = this.defaultCharUnicode.charCodeAt(0);
        }
        else if (uCode === GB18030_CODE) {
            var curSeq = (seqStart >= 0) ? buf.slice(seqStart, i+1) : prevBuf.slice(seqStart + prevBufOffset, i+1 + prevBufOffset);
            var ptr = (curSeq[0]-0x81)*12600 + (curSeq[1]-0x30)*1260 + (curSeq[2]-0x81)*10 + (curSeq[3]-0x30);
            var idx = findIdx(this.gb18030.gbChars, ptr);
            uCode = this.gb18030.uChars[idx] + ptr - this.gb18030.gbChars[idx];
        }
        else if (uCode <= NODE_START) { // Go to next trie node.
            nodeIdx = NODE_START - uCode;
            continue;
        }
        else if (uCode <= SEQ_START) { // Output a sequence of chars.
            var seq = this.decodeTableSeq[SEQ_START - uCode];
            for (var k = 0; k < seq.length - 1; k++) {
                uCode = seq[k];
                newBuf[j++] = uCode & 0xFF;
                newBuf[j++] = uCode >> 8;
            }
            uCode = seq[seq.length-1];
        }
        else
            throw new Error("iconv-lite internal error: invalid decoding table value " + uCode + " at " + nodeIdx + "/" + curByte);

        // Write the character to buffer, handling higher planes using surrogate pair.
        if (uCode > 0xFFFF) { 
            uCode -= 0x10000;
            var uCodeLead = 0xD800 + Math.floor(uCode / 0x400);
            newBuf[j++] = uCodeLead & 0xFF;
            newBuf[j++] = uCodeLead >> 8;

            uCode = 0xDC00 + uCode % 0x400;
        }
        newBuf[j++] = uCode & 0xFF;
        newBuf[j++] = uCode >> 8;

        // Reset trie node.
        nodeIdx = 0; seqStart = i+1;
    }

    this.nodeIdx = nodeIdx;
    this.prevBuf = (seqStart >= 0) ? buf.slice(seqStart) : prevBuf.slice(seqStart + prevBufOffset);
    return newBuf.slice(0, j).toString('ucs2');
}

DBCSDecoder.prototype.end = function() {
    var ret = '';

    // Try to parse all remaining chars.
    while (this.prevBuf.length > 0) {
        // Skip 1 character in the buffer.
        ret += this.defaultCharUnicode;
        var buf = this.prevBuf.slice(1);

        // Parse remaining as usual.
        this.prevBuf = Buffer.alloc(0);
        this.nodeIdx = 0;
        if (buf.length > 0)
            ret += this.write(buf);
    }

    this.nodeIdx = 0;
    return ret;
}

// Binary search for GB18030. Returns largest i such that table[i] <= val.
function findIdx(table, val) {
    if (table[0] > val)
        return -1;

    var l = 0, r = table.length;
    while (l < r-1) { // always table[l] <= val < table[r]
        var mid = l + Math.floor((r-l+1)/2);
        if (table[mid] <= val)
            l = mid;
        else
            r = mid;
    }
    return l;
}



/***/ }),
/* 428 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


// Description of supported double byte encodings and aliases.
// Tables are not require()-d until they are needed to speed up library load.
// require()-s are direct to support Browserify.

module.exports = {
    
    // == Japanese/ShiftJIS ====================================================
    // All japanese encodings are based on JIS X set of standards:
    // JIS X 0201 - Single-byte encoding of ASCII + ¥ + Kana chars at 0xA1-0xDF.
    // JIS X 0208 - Main set of 6879 characters, placed in 94x94 plane, to be encoded by 2 bytes. 
    //              Has several variations in 1978, 1983, 1990 and 1997.
    // JIS X 0212 - Supplementary plane of 6067 chars in 94x94 plane. 1990. Effectively dead.
    // JIS X 0213 - Extension and modern replacement of 0208 and 0212. Total chars: 11233.
    //              2 planes, first is superset of 0208, second - revised 0212.
    //              Introduced in 2000, revised 2004. Some characters are in Unicode Plane 2 (0x2xxxx)

    // Byte encodings are:
    //  * Shift_JIS: Compatible with 0201, uses not defined chars in top half as lead bytes for double-byte
    //               encoding of 0208. Lead byte ranges: 0x81-0x9F, 0xE0-0xEF; Trail byte ranges: 0x40-0x7E, 0x80-0x9E, 0x9F-0xFC.
    //               Windows CP932 is a superset of Shift_JIS. Some companies added more chars, notably KDDI.
    //  * EUC-JP:    Up to 3 bytes per character. Used mostly on *nixes.
    //               0x00-0x7F       - lower part of 0201
    //               0x8E, 0xA1-0xDF - upper part of 0201
    //               (0xA1-0xFE)x2   - 0208 plane (94x94).
    //               0x8F, (0xA1-0xFE)x2 - 0212 plane (94x94).
    //  * JIS X 208: 7-bit, direct encoding of 0208. Byte ranges: 0x21-0x7E (94 values). Uncommon.
    //               Used as-is in ISO2022 family.
    //  * ISO2022-JP: Stateful encoding, with escape sequences to switch between ASCII, 
    //                0201-1976 Roman, 0208-1978, 0208-1983.
    //  * ISO2022-JP-1: Adds esc seq for 0212-1990.
    //  * ISO2022-JP-2: Adds esc seq for GB2313-1980, KSX1001-1992, ISO8859-1, ISO8859-7.
    //  * ISO2022-JP-3: Adds esc seq for 0201-1976 Kana set, 0213-2000 Planes 1, 2.
    //  * ISO2022-JP-2004: Adds 0213-2004 Plane 1.
    //
    // After JIS X 0213 appeared, Shift_JIS-2004, EUC-JISX0213 and ISO2022-JP-2004 followed, with just changing the planes.
    //
    // Overall, it seems that it's a mess :( http://www8.plala.or.jp/tkubota1/unicode-symbols-map2.html

    'shiftjis': {
        type: '_dbcs',
        table: function() { return __webpack_require__(429) },
        encodeAdd: {'\u00a5': 0x5C, '\u203E': 0x7E},
        encodeSkipVals: [{from: 0xED40, to: 0xF940}],
    },
    'csshiftjis': 'shiftjis',
    'mskanji': 'shiftjis',
    'sjis': 'shiftjis',
    'windows31j': 'shiftjis',
    'ms31j': 'shiftjis',
    'xsjis': 'shiftjis',
    'windows932': 'shiftjis',
    'ms932': 'shiftjis',
    '932': 'shiftjis',
    'cp932': 'shiftjis',

    'eucjp': {
        type: '_dbcs',
        table: function() { return __webpack_require__(430) },
        encodeAdd: {'\u00a5': 0x5C, '\u203E': 0x7E},
    },

    // TODO: KDDI extension to Shift_JIS
    // TODO: IBM CCSID 942 = CP932, but F0-F9 custom chars and other char changes.
    // TODO: IBM CCSID 943 = Shift_JIS = CP932 with original Shift_JIS lower 128 chars.


    // == Chinese/GBK ==========================================================
    // http://en.wikipedia.org/wiki/GBK
    // We mostly implement W3C recommendation: https://www.w3.org/TR/encoding/#gbk-encoder

    // Oldest GB2312 (1981, ~7600 chars) is a subset of CP936
    'gb2312': 'cp936',
    'gb231280': 'cp936',
    'gb23121980': 'cp936',
    'csgb2312': 'cp936',
    'csiso58gb231280': 'cp936',
    'euccn': 'cp936',

    // Microsoft's CP936 is a subset and approximation of GBK.
    'windows936': 'cp936',
    'ms936': 'cp936',
    '936': 'cp936',
    'cp936': {
        type: '_dbcs',
        table: function() { return __webpack_require__(179) },
    },

    // GBK (~22000 chars) is an extension of CP936 that added user-mapped chars and some other.
    'gbk': {
        type: '_dbcs',
        table: function() { return __webpack_require__(179).concat(__webpack_require__(245)) },
    },
    'xgbk': 'gbk',
    'isoir58': 'gbk',

    // GB18030 is an algorithmic extension of GBK.
    // Main source: https://www.w3.org/TR/encoding/#gbk-encoder
    // http://icu-project.org/docs/papers/gb18030.html
    // http://source.icu-project.org/repos/icu/data/trunk/charset/data/xml/gb-18030-2000.xml
    // http://www.khngai.com/chinese/charmap/tblgbk.php?page=0
    'gb18030': {
        type: '_dbcs',
        table: function() { return __webpack_require__(179).concat(__webpack_require__(245)) },
        gb18030: function() { return __webpack_require__(431) },
        encodeSkipVals: [0x80],
        encodeAdd: {'€': 0xA2E3},
    },

    'chinese': 'gb18030',


    // == Korean ===============================================================
    // EUC-KR, KS_C_5601 and KS X 1001 are exactly the same.
    'windows949': 'cp949',
    'ms949': 'cp949',
    '949': 'cp949',
    'cp949': {
        type: '_dbcs',
        table: function() { return __webpack_require__(432) },
    },

    'cseuckr': 'cp949',
    'csksc56011987': 'cp949',
    'euckr': 'cp949',
    'isoir149': 'cp949',
    'korean': 'cp949',
    'ksc56011987': 'cp949',
    'ksc56011989': 'cp949',
    'ksc5601': 'cp949',


    // == Big5/Taiwan/Hong Kong ================================================
    // There are lots of tables for Big5 and cp950. Please see the following links for history:
    // http://moztw.org/docs/big5/  http://www.haible.de/bruno/charsets/conversion-tables/Big5.html
    // Variations, in roughly number of defined chars:
    //  * Windows CP 950: Microsoft variant of Big5. Canonical: http://www.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP950.TXT
    //  * Windows CP 951: Microsoft variant of Big5-HKSCS-2001. Seems to be never public. http://me.abelcheung.org/articles/research/what-is-cp951/
    //  * Big5-2003 (Taiwan standard) almost superset of cp950.
    //  * Unicode-at-on (UAO) / Mozilla 1.8. Falling out of use on the Web. Not supported by other browsers.
    //  * Big5-HKSCS (-2001, -2004, -2008). Hong Kong standard. 
    //    many unicode code points moved from PUA to Supplementary plane (U+2XXXX) over the years.
    //    Plus, it has 4 combining sequences.
    //    Seems that Mozilla refused to support it for 10 yrs. https://bugzilla.mozilla.org/show_bug.cgi?id=162431 https://bugzilla.mozilla.org/show_bug.cgi?id=310299
    //    because big5-hkscs is the only encoding to include astral characters in non-algorithmic way.
    //    Implementations are not consistent within browsers; sometimes labeled as just big5.
    //    MS Internet Explorer switches from big5 to big5-hkscs when a patch applied.
    //    Great discussion & recap of what's going on https://bugzilla.mozilla.org/show_bug.cgi?id=912470#c31
    //    In the encoder, it might make sense to support encoding old PUA mappings to Big5 bytes seq-s.
    //    Official spec: http://www.ogcio.gov.hk/en/business/tech_promotion/ccli/terms/doc/2003cmp_2008.txt
    //                   http://www.ogcio.gov.hk/tc/business/tech_promotion/ccli/terms/doc/hkscs-2008-big5-iso.txt
    // 
    // Current understanding of how to deal with Big5(-HKSCS) is in the Encoding Standard, http://encoding.spec.whatwg.org/#big5-encoder
    // Unicode mapping (http://www.unicode.org/Public/MAPPINGS/OBSOLETE/EASTASIA/OTHER/BIG5.TXT) is said to be wrong.

    'windows950': 'cp950',
    'ms950': 'cp950',
    '950': 'cp950',
    'cp950': {
        type: '_dbcs',
        table: function() { return __webpack_require__(246) },
    },

    // Big5 has many variations and is an extension of cp950. We use Encoding Standard's as a consensus.
    'big5': 'big5hkscs',
    'big5hkscs': {
        type: '_dbcs',
        table: function() { return __webpack_require__(246).concat(__webpack_require__(433)) },
        encodeSkipVals: [0xa2cc],
    },

    'cnbig5': 'big5hkscs',
    'csbig5': 'big5hkscs',
    'xxbig5': 'big5hkscs',
};


/***/ }),
/* 429 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"0\",\"\\u0000\",128],[\"a1\",\"｡\",62],[\"8140\",\"　、。，．・：；？！゛゜´｀¨＾￣＿ヽヾゝゞ〃仝々〆〇ー―‐／＼～∥｜…‥‘’“”（）〔〕［］｛｝〈\",9,\"＋－±×\"],[\"8180\",\"÷＝≠＜＞≦≧∞∴♂♀°′″℃￥＄￠￡％＃＆＊＠§☆★○●◎◇◆□■△▲▽▼※〒→←↑↓〓\"],[\"81b8\",\"∈∋⊆⊇⊂⊃∪∩\"],[\"81c8\",\"∧∨￢⇒⇔∀∃\"],[\"81da\",\"∠⊥⌒∂∇≡≒≪≫√∽∝∵∫∬\"],[\"81f0\",\"Å‰♯♭♪†‡¶\"],[\"81fc\",\"◯\"],[\"824f\",\"０\",9],[\"8260\",\"Ａ\",25],[\"8281\",\"ａ\",25],[\"829f\",\"ぁ\",82],[\"8340\",\"ァ\",62],[\"8380\",\"ム\",22],[\"839f\",\"Α\",16,\"Σ\",6],[\"83bf\",\"α\",16,\"σ\",6],[\"8440\",\"А\",5,\"ЁЖ\",25],[\"8470\",\"а\",5,\"ёж\",7],[\"8480\",\"о\",17],[\"849f\",\"─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂\"],[\"8740\",\"①\",19,\"Ⅰ\",9],[\"875f\",\"㍉㌔㌢㍍㌘㌧㌃㌶㍑㍗㌍㌦㌣㌫㍊㌻㎜㎝㎞㎎㎏㏄㎡\"],[\"877e\",\"㍻\"],[\"8780\",\"〝〟№㏍℡㊤\",4,\"㈱㈲㈹㍾㍽㍼≒≡∫∮∑√⊥∠∟⊿∵∩∪\"],[\"889f\",\"亜唖娃阿哀愛挨姶逢葵茜穐悪握渥旭葦芦鯵梓圧斡扱宛姐虻飴絢綾鮎或粟袷安庵按暗案闇鞍杏以伊位依偉囲夷委威尉惟意慰易椅為畏異移維緯胃萎衣謂違遺医井亥域育郁磯一壱溢逸稲茨芋鰯允印咽員因姻引飲淫胤蔭\"],[\"8940\",\"院陰隠韻吋右宇烏羽迂雨卯鵜窺丑碓臼渦嘘唄欝蔚鰻姥厩浦瓜閏噂云運雲荏餌叡営嬰影映曳栄永泳洩瑛盈穎頴英衛詠鋭液疫益駅悦謁越閲榎厭円\"],[\"8980\",\"園堰奄宴延怨掩援沿演炎焔煙燕猿縁艶苑薗遠鉛鴛塩於汚甥凹央奥往応押旺横欧殴王翁襖鴬鴎黄岡沖荻億屋憶臆桶牡乙俺卸恩温穏音下化仮何伽価佳加可嘉夏嫁家寡科暇果架歌河火珂禍禾稼箇花苛茄荷華菓蝦課嘩貨迦過霞蚊俄峨我牙画臥芽蛾賀雅餓駕介会解回塊壊廻快怪悔恢懐戒拐改\"],[\"8a40\",\"魁晦械海灰界皆絵芥蟹開階貝凱劾外咳害崖慨概涯碍蓋街該鎧骸浬馨蛙垣柿蛎鈎劃嚇各廓拡撹格核殻獲確穫覚角赫較郭閣隔革学岳楽額顎掛笠樫\"],[\"8a80\",\"橿梶鰍潟割喝恰括活渇滑葛褐轄且鰹叶椛樺鞄株兜竃蒲釜鎌噛鴨栢茅萱粥刈苅瓦乾侃冠寒刊勘勧巻喚堪姦完官寛干幹患感慣憾換敢柑桓棺款歓汗漢澗潅環甘監看竿管簡緩缶翰肝艦莞観諌貫還鑑間閑関陥韓館舘丸含岸巌玩癌眼岩翫贋雁頑顔願企伎危喜器基奇嬉寄岐希幾忌揮机旗既期棋棄\"],[\"8b40\",\"機帰毅気汽畿祈季稀紀徽規記貴起軌輝飢騎鬼亀偽儀妓宜戯技擬欺犠疑祇義蟻誼議掬菊鞠吉吃喫桔橘詰砧杵黍却客脚虐逆丘久仇休及吸宮弓急救\"],[\"8b80\",\"朽求汲泣灸球究窮笈級糾給旧牛去居巨拒拠挙渠虚許距鋸漁禦魚亨享京供侠僑兇競共凶協匡卿叫喬境峡強彊怯恐恭挟教橋況狂狭矯胸脅興蕎郷鏡響饗驚仰凝尭暁業局曲極玉桐粁僅勤均巾錦斤欣欽琴禁禽筋緊芹菌衿襟謹近金吟銀九倶句区狗玖矩苦躯駆駈駒具愚虞喰空偶寓遇隅串櫛釧屑屈\"],[\"8c40\",\"掘窟沓靴轡窪熊隈粂栗繰桑鍬勲君薫訓群軍郡卦袈祁係傾刑兄啓圭珪型契形径恵慶慧憩掲携敬景桂渓畦稽系経継繋罫茎荊蛍計詣警軽頚鶏芸迎鯨\"],[\"8c80\",\"劇戟撃激隙桁傑欠決潔穴結血訣月件倹倦健兼券剣喧圏堅嫌建憲懸拳捲検権牽犬献研硯絹県肩見謙賢軒遣鍵険顕験鹸元原厳幻弦減源玄現絃舷言諺限乎個古呼固姑孤己庫弧戸故枯湖狐糊袴股胡菰虎誇跨鈷雇顧鼓五互伍午呉吾娯後御悟梧檎瑚碁語誤護醐乞鯉交佼侯候倖光公功効勾厚口向\"],[\"8d40\",\"后喉坑垢好孔孝宏工巧巷幸広庚康弘恒慌抗拘控攻昂晃更杭校梗構江洪浩港溝甲皇硬稿糠紅紘絞綱耕考肯肱腔膏航荒行衡講貢購郊酵鉱砿鋼閤降\"],[\"8d80\",\"項香高鴻剛劫号合壕拷濠豪轟麹克刻告国穀酷鵠黒獄漉腰甑忽惚骨狛込此頃今困坤墾婚恨懇昏昆根梱混痕紺艮魂些佐叉唆嵯左差査沙瑳砂詐鎖裟坐座挫債催再最哉塞妻宰彩才採栽歳済災采犀砕砦祭斎細菜裁載際剤在材罪財冴坂阪堺榊肴咲崎埼碕鷺作削咋搾昨朔柵窄策索錯桜鮭笹匙冊刷\"],[\"8e40\",\"察拶撮擦札殺薩雑皐鯖捌錆鮫皿晒三傘参山惨撒散桟燦珊産算纂蚕讃賛酸餐斬暫残仕仔伺使刺司史嗣四士始姉姿子屍市師志思指支孜斯施旨枝止\"],[\"8e80\",\"死氏獅祉私糸紙紫肢脂至視詞詩試誌諮資賜雌飼歯事似侍児字寺慈持時次滋治爾璽痔磁示而耳自蒔辞汐鹿式識鴫竺軸宍雫七叱執失嫉室悉湿漆疾質実蔀篠偲柴芝屡蕊縞舎写射捨赦斜煮社紗者謝車遮蛇邪借勺尺杓灼爵酌釈錫若寂弱惹主取守手朱殊狩珠種腫趣酒首儒受呪寿授樹綬需囚収周\"],[\"8f40\",\"宗就州修愁拾洲秀秋終繍習臭舟蒐衆襲讐蹴輯週酋酬集醜什住充十従戎柔汁渋獣縦重銃叔夙宿淑祝縮粛塾熟出術述俊峻春瞬竣舜駿准循旬楯殉淳\"],[\"8f80\",\"準潤盾純巡遵醇順処初所暑曙渚庶緒署書薯藷諸助叙女序徐恕鋤除傷償勝匠升召哨商唱嘗奨妾娼宵将小少尚庄床廠彰承抄招掌捷昇昌昭晶松梢樟樵沼消渉湘焼焦照症省硝礁祥称章笑粧紹肖菖蒋蕉衝裳訟証詔詳象賞醤鉦鍾鐘障鞘上丈丞乗冗剰城場壌嬢常情擾条杖浄状畳穣蒸譲醸錠嘱埴飾\"],[\"9040\",\"拭植殖燭織職色触食蝕辱尻伸信侵唇娠寝審心慎振新晋森榛浸深申疹真神秦紳臣芯薪親診身辛進針震人仁刃塵壬尋甚尽腎訊迅陣靭笥諏須酢図厨\"],[\"9080\",\"逗吹垂帥推水炊睡粋翠衰遂酔錐錘随瑞髄崇嵩数枢趨雛据杉椙菅頗雀裾澄摺寸世瀬畝是凄制勢姓征性成政整星晴棲栖正清牲生盛精聖声製西誠誓請逝醒青静斉税脆隻席惜戚斥昔析石積籍績脊責赤跡蹟碩切拙接摂折設窃節説雪絶舌蝉仙先千占宣専尖川戦扇撰栓栴泉浅洗染潜煎煽旋穿箭線\"],[\"9140\",\"繊羨腺舛船薦詮賎践選遷銭銑閃鮮前善漸然全禅繕膳糎噌塑岨措曾曽楚狙疏疎礎祖租粗素組蘇訴阻遡鼠僧創双叢倉喪壮奏爽宋層匝惣想捜掃挿掻\"],[\"9180\",\"操早曹巣槍槽漕燥争痩相窓糟総綜聡草荘葬蒼藻装走送遭鎗霜騒像増憎臓蔵贈造促側則即息捉束測足速俗属賊族続卒袖其揃存孫尊損村遜他多太汰詑唾堕妥惰打柁舵楕陀駄騨体堆対耐岱帯待怠態戴替泰滞胎腿苔袋貸退逮隊黛鯛代台大第醍題鷹滝瀧卓啄宅托択拓沢濯琢託鐸濁諾茸凧蛸只\"],[\"9240\",\"叩但達辰奪脱巽竪辿棚谷狸鱈樽誰丹単嘆坦担探旦歎淡湛炭短端箪綻耽胆蛋誕鍛団壇弾断暖檀段男談値知地弛恥智池痴稚置致蜘遅馳築畜竹筑蓄\"],[\"9280\",\"逐秩窒茶嫡着中仲宙忠抽昼柱注虫衷註酎鋳駐樗瀦猪苧著貯丁兆凋喋寵帖帳庁弔張彫徴懲挑暢朝潮牒町眺聴脹腸蝶調諜超跳銚長頂鳥勅捗直朕沈珍賃鎮陳津墜椎槌追鎚痛通塚栂掴槻佃漬柘辻蔦綴鍔椿潰坪壷嬬紬爪吊釣鶴亭低停偵剃貞呈堤定帝底庭廷弟悌抵挺提梯汀碇禎程締艇訂諦蹄逓\"],[\"9340\",\"邸鄭釘鼎泥摘擢敵滴的笛適鏑溺哲徹撤轍迭鉄典填天展店添纏甜貼転顛点伝殿澱田電兎吐堵塗妬屠徒斗杜渡登菟賭途都鍍砥砺努度土奴怒倒党冬\"],[\"9380\",\"凍刀唐塔塘套宕島嶋悼投搭東桃梼棟盗淘湯涛灯燈当痘祷等答筒糖統到董蕩藤討謄豆踏逃透鐙陶頭騰闘働動同堂導憧撞洞瞳童胴萄道銅峠鴇匿得徳涜特督禿篤毒独読栃橡凸突椴届鳶苫寅酉瀞噸屯惇敦沌豚遁頓呑曇鈍奈那内乍凪薙謎灘捺鍋楢馴縄畷南楠軟難汝二尼弐迩匂賑肉虹廿日乳入\"],[\"9440\",\"如尿韮任妊忍認濡禰祢寧葱猫熱年念捻撚燃粘乃廼之埜嚢悩濃納能脳膿農覗蚤巴把播覇杷波派琶破婆罵芭馬俳廃拝排敗杯盃牌背肺輩配倍培媒梅\"],[\"9480\",\"楳煤狽買売賠陪這蝿秤矧萩伯剥博拍柏泊白箔粕舶薄迫曝漠爆縛莫駁麦函箱硲箸肇筈櫨幡肌畑畠八鉢溌発醗髪伐罰抜筏閥鳩噺塙蛤隼伴判半反叛帆搬斑板氾汎版犯班畔繁般藩販範釆煩頒飯挽晩番盤磐蕃蛮匪卑否妃庇彼悲扉批披斐比泌疲皮碑秘緋罷肥被誹費避非飛樋簸備尾微枇毘琵眉美\"],[\"9540\",\"鼻柊稗匹疋髭彦膝菱肘弼必畢筆逼桧姫媛紐百謬俵彪標氷漂瓢票表評豹廟描病秒苗錨鋲蒜蛭鰭品彬斌浜瀕貧賓頻敏瓶不付埠夫婦富冨布府怖扶敷\"],[\"9580\",\"斧普浮父符腐膚芙譜負賦赴阜附侮撫武舞葡蕪部封楓風葺蕗伏副復幅服福腹複覆淵弗払沸仏物鮒分吻噴墳憤扮焚奮粉糞紛雰文聞丙併兵塀幣平弊柄並蔽閉陛米頁僻壁癖碧別瞥蔑箆偏変片篇編辺返遍便勉娩弁鞭保舗鋪圃捕歩甫補輔穂募墓慕戊暮母簿菩倣俸包呆報奉宝峰峯崩庖抱捧放方朋\"],[\"9640\",\"法泡烹砲縫胞芳萌蓬蜂褒訪豊邦鋒飽鳳鵬乏亡傍剖坊妨帽忘忙房暴望某棒冒紡肪膨謀貌貿鉾防吠頬北僕卜墨撲朴牧睦穆釦勃没殆堀幌奔本翻凡盆\"],[\"9680\",\"摩磨魔麻埋妹昧枚毎哩槙幕膜枕鮪柾鱒桝亦俣又抹末沫迄侭繭麿万慢満漫蔓味未魅巳箕岬密蜜湊蓑稔脈妙粍民眠務夢無牟矛霧鵡椋婿娘冥名命明盟迷銘鳴姪牝滅免棉綿緬面麺摸模茂妄孟毛猛盲網耗蒙儲木黙目杢勿餅尤戻籾貰問悶紋門匁也冶夜爺耶野弥矢厄役約薬訳躍靖柳薮鑓愉愈油癒\"],[\"9740\",\"諭輸唯佑優勇友宥幽悠憂揖有柚湧涌猶猷由祐裕誘遊邑郵雄融夕予余与誉輿預傭幼妖容庸揚揺擁曜楊様洋溶熔用窯羊耀葉蓉要謡踊遥陽養慾抑欲\"],[\"9780\",\"沃浴翌翼淀羅螺裸来莱頼雷洛絡落酪乱卵嵐欄濫藍蘭覧利吏履李梨理璃痢裏裡里離陸律率立葎掠略劉流溜琉留硫粒隆竜龍侶慮旅虜了亮僚両凌寮料梁涼猟療瞭稜糧良諒遼量陵領力緑倫厘林淋燐琳臨輪隣鱗麟瑠塁涙累類令伶例冷励嶺怜玲礼苓鈴隷零霊麗齢暦歴列劣烈裂廉恋憐漣煉簾練聯\"],[\"9840\",\"蓮連錬呂魯櫓炉賂路露労婁廊弄朗楼榔浪漏牢狼篭老聾蝋郎六麓禄肋録論倭和話歪賄脇惑枠鷲亙亘鰐詫藁蕨椀湾碗腕\"],[\"989f\",\"弌丐丕个丱丶丼丿乂乖乘亂亅豫亊舒弍于亞亟亠亢亰亳亶从仍仄仆仂仗仞仭仟价伉佚估佛佝佗佇佶侈侏侘佻佩佰侑佯來侖儘俔俟俎俘俛俑俚俐俤俥倚倨倔倪倥倅伜俶倡倩倬俾俯們倆偃假會偕偐偈做偖偬偸傀傚傅傴傲\"],[\"9940\",\"僉僊傳僂僖僞僥僭僣僮價僵儉儁儂儖儕儔儚儡儺儷儼儻儿兀兒兌兔兢竸兩兪兮冀冂囘册冉冏冑冓冕冖冤冦冢冩冪冫决冱冲冰况冽凅凉凛几處凩凭\"],[\"9980\",\"凰凵凾刄刋刔刎刧刪刮刳刹剏剄剋剌剞剔剪剴剩剳剿剽劍劔劒剱劈劑辨辧劬劭劼劵勁勍勗勞勣勦飭勠勳勵勸勹匆匈甸匍匐匏匕匚匣匯匱匳匸區卆卅丗卉卍凖卞卩卮夘卻卷厂厖厠厦厥厮厰厶參簒雙叟曼燮叮叨叭叺吁吽呀听吭吼吮吶吩吝呎咏呵咎呟呱呷呰咒呻咀呶咄咐咆哇咢咸咥咬哄哈咨\"],[\"9a40\",\"咫哂咤咾咼哘哥哦唏唔哽哮哭哺哢唹啀啣啌售啜啅啖啗唸唳啝喙喀咯喊喟啻啾喘喞單啼喃喩喇喨嗚嗅嗟嗄嗜嗤嗔嘔嗷嘖嗾嗽嘛嗹噎噐營嘴嘶嘲嘸\"],[\"9a80\",\"噫噤嘯噬噪嚆嚀嚊嚠嚔嚏嚥嚮嚶嚴囂嚼囁囃囀囈囎囑囓囗囮囹圀囿圄圉圈國圍圓團圖嗇圜圦圷圸坎圻址坏坩埀垈坡坿垉垓垠垳垤垪垰埃埆埔埒埓堊埖埣堋堙堝塲堡塢塋塰毀塒堽塹墅墹墟墫墺壞墻墸墮壅壓壑壗壙壘壥壜壤壟壯壺壹壻壼壽夂夊夐夛梦夥夬夭夲夸夾竒奕奐奎奚奘奢奠奧奬奩\"],[\"9b40\",\"奸妁妝佞侫妣妲姆姨姜妍姙姚娥娟娑娜娉娚婀婬婉娵娶婢婪媚媼媾嫋嫂媽嫣嫗嫦嫩嫖嫺嫻嬌嬋嬖嬲嫐嬪嬶嬾孃孅孀孑孕孚孛孥孩孰孳孵學斈孺宀\"],[\"9b80\",\"它宦宸寃寇寉寔寐寤實寢寞寥寫寰寶寳尅將專對尓尠尢尨尸尹屁屆屎屓屐屏孱屬屮乢屶屹岌岑岔妛岫岻岶岼岷峅岾峇峙峩峽峺峭嶌峪崋崕崗嵜崟崛崑崔崢崚崙崘嵌嵒嵎嵋嵬嵳嵶嶇嶄嶂嶢嶝嶬嶮嶽嶐嶷嶼巉巍巓巒巖巛巫已巵帋帚帙帑帛帶帷幄幃幀幎幗幔幟幢幤幇幵并幺麼广庠廁廂廈廐廏\"],[\"9c40\",\"廖廣廝廚廛廢廡廨廩廬廱廳廰廴廸廾弃弉彝彜弋弑弖弩弭弸彁彈彌彎弯彑彖彗彙彡彭彳彷徃徂彿徊很徑徇從徙徘徠徨徭徼忖忻忤忸忱忝悳忿怡恠\"],[\"9c80\",\"怙怐怩怎怱怛怕怫怦怏怺恚恁恪恷恟恊恆恍恣恃恤恂恬恫恙悁悍惧悃悚悄悛悖悗悒悧悋惡悸惠惓悴忰悽惆悵惘慍愕愆惶惷愀惴惺愃愡惻惱愍愎慇愾愨愧慊愿愼愬愴愽慂慄慳慷慘慙慚慫慴慯慥慱慟慝慓慵憙憖憇憬憔憚憊憑憫憮懌懊應懷懈懃懆憺懋罹懍懦懣懶懺懴懿懽懼懾戀戈戉戍戌戔戛\"],[\"9d40\",\"戞戡截戮戰戲戳扁扎扞扣扛扠扨扼抂抉找抒抓抖拔抃抔拗拑抻拏拿拆擔拈拜拌拊拂拇抛拉挌拮拱挧挂挈拯拵捐挾捍搜捏掖掎掀掫捶掣掏掉掟掵捫\"],[\"9d80\",\"捩掾揩揀揆揣揉插揶揄搖搴搆搓搦搶攝搗搨搏摧摯摶摎攪撕撓撥撩撈撼據擒擅擇撻擘擂擱擧舉擠擡抬擣擯攬擶擴擲擺攀擽攘攜攅攤攣攫攴攵攷收攸畋效敖敕敍敘敞敝敲數斂斃變斛斟斫斷旃旆旁旄旌旒旛旙无旡旱杲昊昃旻杳昵昶昴昜晏晄晉晁晞晝晤晧晨晟晢晰暃暈暎暉暄暘暝曁暹曉暾暼\"],[\"9e40\",\"曄暸曖曚曠昿曦曩曰曵曷朏朖朞朦朧霸朮朿朶杁朸朷杆杞杠杙杣杤枉杰枩杼杪枌枋枦枡枅枷柯枴柬枳柩枸柤柞柝柢柮枹柎柆柧檜栞框栩桀桍栲桎\"],[\"9e80\",\"梳栫桙档桷桿梟梏梭梔條梛梃檮梹桴梵梠梺椏梍桾椁棊椈棘椢椦棡椌棍棔棧棕椶椒椄棗棣椥棹棠棯椨椪椚椣椡棆楹楷楜楸楫楔楾楮椹楴椽楙椰楡楞楝榁楪榲榮槐榿槁槓榾槎寨槊槝榻槃榧樮榑榠榜榕榴槞槨樂樛槿權槹槲槧樅榱樞槭樔槫樊樒櫁樣樓橄樌橲樶橸橇橢橙橦橈樸樢檐檍檠檄檢檣\"],[\"9f40\",\"檗蘗檻櫃櫂檸檳檬櫞櫑櫟檪櫚櫪櫻欅蘖櫺欒欖鬱欟欸欷盜欹飮歇歃歉歐歙歔歛歟歡歸歹歿殀殄殃殍殘殕殞殤殪殫殯殲殱殳殷殼毆毋毓毟毬毫毳毯\"],[\"9f80\",\"麾氈氓气氛氤氣汞汕汢汪沂沍沚沁沛汾汨汳沒沐泄泱泓沽泗泅泝沮沱沾沺泛泯泙泪洟衍洶洫洽洸洙洵洳洒洌浣涓浤浚浹浙涎涕濤涅淹渕渊涵淇淦涸淆淬淞淌淨淒淅淺淙淤淕淪淮渭湮渮渙湲湟渾渣湫渫湶湍渟湃渺湎渤滿渝游溂溪溘滉溷滓溽溯滄溲滔滕溏溥滂溟潁漑灌滬滸滾漿滲漱滯漲滌\"],[\"e040\",\"漾漓滷澆潺潸澁澀潯潛濳潭澂潼潘澎澑濂潦澳澣澡澤澹濆澪濟濕濬濔濘濱濮濛瀉瀋濺瀑瀁瀏濾瀛瀚潴瀝瀘瀟瀰瀾瀲灑灣炙炒炯烱炬炸炳炮烟烋烝\"],[\"e080\",\"烙焉烽焜焙煥煕熈煦煢煌煖煬熏燻熄熕熨熬燗熹熾燒燉燔燎燠燬燧燵燼燹燿爍爐爛爨爭爬爰爲爻爼爿牀牆牋牘牴牾犂犁犇犒犖犢犧犹犲狃狆狄狎狒狢狠狡狹狷倏猗猊猜猖猝猴猯猩猥猾獎獏默獗獪獨獰獸獵獻獺珈玳珎玻珀珥珮珞璢琅瑯琥珸琲琺瑕琿瑟瑙瑁瑜瑩瑰瑣瑪瑶瑾璋璞璧瓊瓏瓔珱\"],[\"e140\",\"瓠瓣瓧瓩瓮瓲瓰瓱瓸瓷甄甃甅甌甎甍甕甓甞甦甬甼畄畍畊畉畛畆畚畩畤畧畫畭畸當疆疇畴疊疉疂疔疚疝疥疣痂疳痃疵疽疸疼疱痍痊痒痙痣痞痾痿\"],[\"e180\",\"痼瘁痰痺痲痳瘋瘍瘉瘟瘧瘠瘡瘢瘤瘴瘰瘻癇癈癆癜癘癡癢癨癩癪癧癬癰癲癶癸發皀皃皈皋皎皖皓皙皚皰皴皸皹皺盂盍盖盒盞盡盥盧盪蘯盻眈眇眄眩眤眞眥眦眛眷眸睇睚睨睫睛睥睿睾睹瞎瞋瞑瞠瞞瞰瞶瞹瞿瞼瞽瞻矇矍矗矚矜矣矮矼砌砒礦砠礪硅碎硴碆硼碚碌碣碵碪碯磑磆磋磔碾碼磅磊磬\"],[\"e240\",\"磧磚磽磴礇礒礑礙礬礫祀祠祗祟祚祕祓祺祿禊禝禧齋禪禮禳禹禺秉秕秧秬秡秣稈稍稘稙稠稟禀稱稻稾稷穃穗穉穡穢穩龝穰穹穽窈窗窕窘窖窩竈窰\"],[\"e280\",\"窶竅竄窿邃竇竊竍竏竕竓站竚竝竡竢竦竭竰笂笏笊笆笳笘笙笞笵笨笶筐筺笄筍笋筌筅筵筥筴筧筰筱筬筮箝箘箟箍箜箚箋箒箏筝箙篋篁篌篏箴篆篝篩簑簔篦篥籠簀簇簓篳篷簗簍篶簣簧簪簟簷簫簽籌籃籔籏籀籐籘籟籤籖籥籬籵粃粐粤粭粢粫粡粨粳粲粱粮粹粽糀糅糂糘糒糜糢鬻糯糲糴糶糺紆\"],[\"e340\",\"紂紜紕紊絅絋紮紲紿紵絆絳絖絎絲絨絮絏絣經綉絛綏絽綛綺綮綣綵緇綽綫總綢綯緜綸綟綰緘緝緤緞緻緲緡縅縊縣縡縒縱縟縉縋縢繆繦縻縵縹繃縷\"],[\"e380\",\"縲縺繧繝繖繞繙繚繹繪繩繼繻纃緕繽辮繿纈纉續纒纐纓纔纖纎纛纜缸缺罅罌罍罎罐网罕罔罘罟罠罨罩罧罸羂羆羃羈羇羌羔羞羝羚羣羯羲羹羮羶羸譱翅翆翊翕翔翡翦翩翳翹飜耆耄耋耒耘耙耜耡耨耿耻聊聆聒聘聚聟聢聨聳聲聰聶聹聽聿肄肆肅肛肓肚肭冐肬胛胥胙胝胄胚胖脉胯胱脛脩脣脯腋\"],[\"e440\",\"隋腆脾腓腑胼腱腮腥腦腴膃膈膊膀膂膠膕膤膣腟膓膩膰膵膾膸膽臀臂膺臉臍臑臙臘臈臚臟臠臧臺臻臾舁舂舅與舊舍舐舖舩舫舸舳艀艙艘艝艚艟艤\"],[\"e480\",\"艢艨艪艫舮艱艷艸艾芍芒芫芟芻芬苡苣苟苒苴苳苺莓范苻苹苞茆苜茉苙茵茴茖茲茱荀茹荐荅茯茫茗茘莅莚莪莟莢莖茣莎莇莊荼莵荳荵莠莉莨菴萓菫菎菽萃菘萋菁菷萇菠菲萍萢萠莽萸蔆菻葭萪萼蕚蒄葷葫蒭葮蒂葩葆萬葯葹萵蓊葢蒹蒿蒟蓙蓍蒻蓚蓐蓁蓆蓖蒡蔡蓿蓴蔗蔘蔬蔟蔕蔔蓼蕀蕣蕘蕈\"],[\"e540\",\"蕁蘂蕋蕕薀薤薈薑薊薨蕭薔薛藪薇薜蕷蕾薐藉薺藏薹藐藕藝藥藜藹蘊蘓蘋藾藺蘆蘢蘚蘰蘿虍乕虔號虧虱蚓蚣蚩蚪蚋蚌蚶蚯蛄蛆蚰蛉蠣蚫蛔蛞蛩蛬\"],[\"e580\",\"蛟蛛蛯蜒蜆蜈蜀蜃蛻蜑蜉蜍蛹蜊蜴蜿蜷蜻蜥蜩蜚蝠蝟蝸蝌蝎蝴蝗蝨蝮蝙蝓蝣蝪蠅螢螟螂螯蟋螽蟀蟐雖螫蟄螳蟇蟆螻蟯蟲蟠蠏蠍蟾蟶蟷蠎蟒蠑蠖蠕蠢蠡蠱蠶蠹蠧蠻衄衂衒衙衞衢衫袁衾袞衵衽袵衲袂袗袒袮袙袢袍袤袰袿袱裃裄裔裘裙裝裹褂裼裴裨裲褄褌褊褓襃褞褥褪褫襁襄褻褶褸襌褝襠襞\"],[\"e640\",\"襦襤襭襪襯襴襷襾覃覈覊覓覘覡覩覦覬覯覲覺覽覿觀觚觜觝觧觴觸訃訖訐訌訛訝訥訶詁詛詒詆詈詼詭詬詢誅誂誄誨誡誑誥誦誚誣諄諍諂諚諫諳諧\"],[\"e680\",\"諤諱謔諠諢諷諞諛謌謇謚諡謖謐謗謠謳鞫謦謫謾謨譁譌譏譎證譖譛譚譫譟譬譯譴譽讀讌讎讒讓讖讙讚谺豁谿豈豌豎豐豕豢豬豸豺貂貉貅貊貍貎貔豼貘戝貭貪貽貲貳貮貶賈賁賤賣賚賽賺賻贄贅贊贇贏贍贐齎贓賍贔贖赧赭赱赳趁趙跂趾趺跏跚跖跌跛跋跪跫跟跣跼踈踉跿踝踞踐踟蹂踵踰踴蹊\"],[\"e740\",\"蹇蹉蹌蹐蹈蹙蹤蹠踪蹣蹕蹶蹲蹼躁躇躅躄躋躊躓躑躔躙躪躡躬躰軆躱躾軅軈軋軛軣軼軻軫軾輊輅輕輒輙輓輜輟輛輌輦輳輻輹轅轂輾轌轉轆轎轗轜\"],[\"e780\",\"轢轣轤辜辟辣辭辯辷迚迥迢迪迯邇迴逅迹迺逑逕逡逍逞逖逋逧逶逵逹迸遏遐遑遒逎遉逾遖遘遞遨遯遶隨遲邂遽邁邀邊邉邏邨邯邱邵郢郤扈郛鄂鄒鄙鄲鄰酊酖酘酣酥酩酳酲醋醉醂醢醫醯醪醵醴醺釀釁釉釋釐釖釟釡釛釼釵釶鈞釿鈔鈬鈕鈑鉞鉗鉅鉉鉤鉈銕鈿鉋鉐銜銖銓銛鉚鋏銹銷鋩錏鋺鍄錮\"],[\"e840\",\"錙錢錚錣錺錵錻鍜鍠鍼鍮鍖鎰鎬鎭鎔鎹鏖鏗鏨鏥鏘鏃鏝鏐鏈鏤鐚鐔鐓鐃鐇鐐鐶鐫鐵鐡鐺鑁鑒鑄鑛鑠鑢鑞鑪鈩鑰鑵鑷鑽鑚鑼鑾钁鑿閂閇閊閔閖閘閙\"],[\"e880\",\"閠閨閧閭閼閻閹閾闊濶闃闍闌闕闔闖關闡闥闢阡阨阮阯陂陌陏陋陷陜陞陝陟陦陲陬隍隘隕隗險隧隱隲隰隴隶隸隹雎雋雉雍襍雜霍雕雹霄霆霈霓霎霑霏霖霙霤霪霰霹霽霾靄靆靈靂靉靜靠靤靦靨勒靫靱靹鞅靼鞁靺鞆鞋鞏鞐鞜鞨鞦鞣鞳鞴韃韆韈韋韜韭齏韲竟韶韵頏頌頸頤頡頷頽顆顏顋顫顯顰\"],[\"e940\",\"顱顴顳颪颯颱颶飄飃飆飩飫餃餉餒餔餘餡餝餞餤餠餬餮餽餾饂饉饅饐饋饑饒饌饕馗馘馥馭馮馼駟駛駝駘駑駭駮駱駲駻駸騁騏騅駢騙騫騷驅驂驀驃\"],[\"e980\",\"騾驕驍驛驗驟驢驥驤驩驫驪骭骰骼髀髏髑髓體髞髟髢髣髦髯髫髮髴髱髷髻鬆鬘鬚鬟鬢鬣鬥鬧鬨鬩鬪鬮鬯鬲魄魃魏魍魎魑魘魴鮓鮃鮑鮖鮗鮟鮠鮨鮴鯀鯊鮹鯆鯏鯑鯒鯣鯢鯤鯔鯡鰺鯲鯱鯰鰕鰔鰉鰓鰌鰆鰈鰒鰊鰄鰮鰛鰥鰤鰡鰰鱇鰲鱆鰾鱚鱠鱧鱶鱸鳧鳬鳰鴉鴈鳫鴃鴆鴪鴦鶯鴣鴟鵄鴕鴒鵁鴿鴾鵆鵈\"],[\"ea40\",\"鵝鵞鵤鵑鵐鵙鵲鶉鶇鶫鵯鵺鶚鶤鶩鶲鷄鷁鶻鶸鶺鷆鷏鷂鷙鷓鷸鷦鷭鷯鷽鸚鸛鸞鹵鹹鹽麁麈麋麌麒麕麑麝麥麩麸麪麭靡黌黎黏黐黔黜點黝黠黥黨黯\"],[\"ea80\",\"黴黶黷黹黻黼黽鼇鼈皷鼕鼡鼬鼾齊齒齔齣齟齠齡齦齧齬齪齷齲齶龕龜龠堯槇遙瑤凜熙\"],[\"ed40\",\"纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏\"],[\"ed80\",\"塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱\"],[\"ee40\",\"犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙\"],[\"ee80\",\"蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑\"],[\"eeef\",\"ⅰ\",9,\"￢￤＇＂\"],[\"f040\",\"\",62],[\"f080\",\"\",124],[\"f140\",\"\",62],[\"f180\",\"\",124],[\"f240\",\"\",62],[\"f280\",\"\",124],[\"f340\",\"\",62],[\"f380\",\"\",124],[\"f440\",\"\",62],[\"f480\",\"\",124],[\"f540\",\"\",62],[\"f580\",\"\",124],[\"f640\",\"\",62],[\"f680\",\"\",124],[\"f740\",\"\",62],[\"f780\",\"\",124],[\"f840\",\"\",62],[\"f880\",\"\",124],[\"f940\",\"\"],[\"fa40\",\"ⅰ\",9,\"Ⅰ\",9,\"￢￤＇＂㈱№℡∵纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊\"],[\"fa80\",\"兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯\"],[\"fb40\",\"涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神\"],[\"fb80\",\"祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙\"],[\"fc40\",\"髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑\"]]");

/***/ }),
/* 430 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"0\",\"\\u0000\",127],[\"8ea1\",\"｡\",62],[\"a1a1\",\"　、。，．・：；？！゛゜´｀¨＾￣＿ヽヾゝゞ〃仝々〆〇ー―‐／＼～∥｜…‥‘’“”（）〔〕［］｛｝〈\",9,\"＋－±×÷＝≠＜＞≦≧∞∴♂♀°′″℃￥＄￠￡％＃＆＊＠§☆★○●◎◇\"],[\"a2a1\",\"◆□■△▲▽▼※〒→←↑↓〓\"],[\"a2ba\",\"∈∋⊆⊇⊂⊃∪∩\"],[\"a2ca\",\"∧∨￢⇒⇔∀∃\"],[\"a2dc\",\"∠⊥⌒∂∇≡≒≪≫√∽∝∵∫∬\"],[\"a2f2\",\"Å‰♯♭♪†‡¶\"],[\"a2fe\",\"◯\"],[\"a3b0\",\"０\",9],[\"a3c1\",\"Ａ\",25],[\"a3e1\",\"ａ\",25],[\"a4a1\",\"ぁ\",82],[\"a5a1\",\"ァ\",85],[\"a6a1\",\"Α\",16,\"Σ\",6],[\"a6c1\",\"α\",16,\"σ\",6],[\"a7a1\",\"А\",5,\"ЁЖ\",25],[\"a7d1\",\"а\",5,\"ёж\",25],[\"a8a1\",\"─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂\"],[\"ada1\",\"①\",19,\"Ⅰ\",9],[\"adc0\",\"㍉㌔㌢㍍㌘㌧㌃㌶㍑㍗㌍㌦㌣㌫㍊㌻㎜㎝㎞㎎㎏㏄㎡\"],[\"addf\",\"㍻〝〟№㏍℡㊤\",4,\"㈱㈲㈹㍾㍽㍼≒≡∫∮∑√⊥∠∟⊿∵∩∪\"],[\"b0a1\",\"亜唖娃阿哀愛挨姶逢葵茜穐悪握渥旭葦芦鯵梓圧斡扱宛姐虻飴絢綾鮎或粟袷安庵按暗案闇鞍杏以伊位依偉囲夷委威尉惟意慰易椅為畏異移維緯胃萎衣謂違遺医井亥域育郁磯一壱溢逸稲茨芋鰯允印咽員因姻引飲淫胤蔭\"],[\"b1a1\",\"院陰隠韻吋右宇烏羽迂雨卯鵜窺丑碓臼渦嘘唄欝蔚鰻姥厩浦瓜閏噂云運雲荏餌叡営嬰影映曳栄永泳洩瑛盈穎頴英衛詠鋭液疫益駅悦謁越閲榎厭円園堰奄宴延怨掩援沿演炎焔煙燕猿縁艶苑薗遠鉛鴛塩於汚甥凹央奥往応\"],[\"b2a1\",\"押旺横欧殴王翁襖鴬鴎黄岡沖荻億屋憶臆桶牡乙俺卸恩温穏音下化仮何伽価佳加可嘉夏嫁家寡科暇果架歌河火珂禍禾稼箇花苛茄荷華菓蝦課嘩貨迦過霞蚊俄峨我牙画臥芽蛾賀雅餓駕介会解回塊壊廻快怪悔恢懐戒拐改\"],[\"b3a1\",\"魁晦械海灰界皆絵芥蟹開階貝凱劾外咳害崖慨概涯碍蓋街該鎧骸浬馨蛙垣柿蛎鈎劃嚇各廓拡撹格核殻獲確穫覚角赫較郭閣隔革学岳楽額顎掛笠樫橿梶鰍潟割喝恰括活渇滑葛褐轄且鰹叶椛樺鞄株兜竃蒲釜鎌噛鴨栢茅萱\"],[\"b4a1\",\"粥刈苅瓦乾侃冠寒刊勘勧巻喚堪姦完官寛干幹患感慣憾換敢柑桓棺款歓汗漢澗潅環甘監看竿管簡緩缶翰肝艦莞観諌貫還鑑間閑関陥韓館舘丸含岸巌玩癌眼岩翫贋雁頑顔願企伎危喜器基奇嬉寄岐希幾忌揮机旗既期棋棄\"],[\"b5a1\",\"機帰毅気汽畿祈季稀紀徽規記貴起軌輝飢騎鬼亀偽儀妓宜戯技擬欺犠疑祇義蟻誼議掬菊鞠吉吃喫桔橘詰砧杵黍却客脚虐逆丘久仇休及吸宮弓急救朽求汲泣灸球究窮笈級糾給旧牛去居巨拒拠挙渠虚許距鋸漁禦魚亨享京\"],[\"b6a1\",\"供侠僑兇競共凶協匡卿叫喬境峡強彊怯恐恭挟教橋況狂狭矯胸脅興蕎郷鏡響饗驚仰凝尭暁業局曲極玉桐粁僅勤均巾錦斤欣欽琴禁禽筋緊芹菌衿襟謹近金吟銀九倶句区狗玖矩苦躯駆駈駒具愚虞喰空偶寓遇隅串櫛釧屑屈\"],[\"b7a1\",\"掘窟沓靴轡窪熊隈粂栗繰桑鍬勲君薫訓群軍郡卦袈祁係傾刑兄啓圭珪型契形径恵慶慧憩掲携敬景桂渓畦稽系経継繋罫茎荊蛍計詣警軽頚鶏芸迎鯨劇戟撃激隙桁傑欠決潔穴結血訣月件倹倦健兼券剣喧圏堅嫌建憲懸拳捲\"],[\"b8a1\",\"検権牽犬献研硯絹県肩見謙賢軒遣鍵険顕験鹸元原厳幻弦減源玄現絃舷言諺限乎個古呼固姑孤己庫弧戸故枯湖狐糊袴股胡菰虎誇跨鈷雇顧鼓五互伍午呉吾娯後御悟梧檎瑚碁語誤護醐乞鯉交佼侯候倖光公功効勾厚口向\"],[\"b9a1\",\"后喉坑垢好孔孝宏工巧巷幸広庚康弘恒慌抗拘控攻昂晃更杭校梗構江洪浩港溝甲皇硬稿糠紅紘絞綱耕考肯肱腔膏航荒行衡講貢購郊酵鉱砿鋼閤降項香高鴻剛劫号合壕拷濠豪轟麹克刻告国穀酷鵠黒獄漉腰甑忽惚骨狛込\"],[\"baa1\",\"此頃今困坤墾婚恨懇昏昆根梱混痕紺艮魂些佐叉唆嵯左差査沙瑳砂詐鎖裟坐座挫債催再最哉塞妻宰彩才採栽歳済災采犀砕砦祭斎細菜裁載際剤在材罪財冴坂阪堺榊肴咲崎埼碕鷺作削咋搾昨朔柵窄策索錯桜鮭笹匙冊刷\"],[\"bba1\",\"察拶撮擦札殺薩雑皐鯖捌錆鮫皿晒三傘参山惨撒散桟燦珊産算纂蚕讃賛酸餐斬暫残仕仔伺使刺司史嗣四士始姉姿子屍市師志思指支孜斯施旨枝止死氏獅祉私糸紙紫肢脂至視詞詩試誌諮資賜雌飼歯事似侍児字寺慈持時\"],[\"bca1\",\"次滋治爾璽痔磁示而耳自蒔辞汐鹿式識鴫竺軸宍雫七叱執失嫉室悉湿漆疾質実蔀篠偲柴芝屡蕊縞舎写射捨赦斜煮社紗者謝車遮蛇邪借勺尺杓灼爵酌釈錫若寂弱惹主取守手朱殊狩珠種腫趣酒首儒受呪寿授樹綬需囚収周\"],[\"bda1\",\"宗就州修愁拾洲秀秋終繍習臭舟蒐衆襲讐蹴輯週酋酬集醜什住充十従戎柔汁渋獣縦重銃叔夙宿淑祝縮粛塾熟出術述俊峻春瞬竣舜駿准循旬楯殉淳準潤盾純巡遵醇順処初所暑曙渚庶緒署書薯藷諸助叙女序徐恕鋤除傷償\"],[\"bea1\",\"勝匠升召哨商唱嘗奨妾娼宵将小少尚庄床廠彰承抄招掌捷昇昌昭晶松梢樟樵沼消渉湘焼焦照症省硝礁祥称章笑粧紹肖菖蒋蕉衝裳訟証詔詳象賞醤鉦鍾鐘障鞘上丈丞乗冗剰城場壌嬢常情擾条杖浄状畳穣蒸譲醸錠嘱埴飾\"],[\"bfa1\",\"拭植殖燭織職色触食蝕辱尻伸信侵唇娠寝審心慎振新晋森榛浸深申疹真神秦紳臣芯薪親診身辛進針震人仁刃塵壬尋甚尽腎訊迅陣靭笥諏須酢図厨逗吹垂帥推水炊睡粋翠衰遂酔錐錘随瑞髄崇嵩数枢趨雛据杉椙菅頗雀裾\"],[\"c0a1\",\"澄摺寸世瀬畝是凄制勢姓征性成政整星晴棲栖正清牲生盛精聖声製西誠誓請逝醒青静斉税脆隻席惜戚斥昔析石積籍績脊責赤跡蹟碩切拙接摂折設窃節説雪絶舌蝉仙先千占宣専尖川戦扇撰栓栴泉浅洗染潜煎煽旋穿箭線\"],[\"c1a1\",\"繊羨腺舛船薦詮賎践選遷銭銑閃鮮前善漸然全禅繕膳糎噌塑岨措曾曽楚狙疏疎礎祖租粗素組蘇訴阻遡鼠僧創双叢倉喪壮奏爽宋層匝惣想捜掃挿掻操早曹巣槍槽漕燥争痩相窓糟総綜聡草荘葬蒼藻装走送遭鎗霜騒像増憎\"],[\"c2a1\",\"臓蔵贈造促側則即息捉束測足速俗属賊族続卒袖其揃存孫尊損村遜他多太汰詑唾堕妥惰打柁舵楕陀駄騨体堆対耐岱帯待怠態戴替泰滞胎腿苔袋貸退逮隊黛鯛代台大第醍題鷹滝瀧卓啄宅托択拓沢濯琢託鐸濁諾茸凧蛸只\"],[\"c3a1\",\"叩但達辰奪脱巽竪辿棚谷狸鱈樽誰丹単嘆坦担探旦歎淡湛炭短端箪綻耽胆蛋誕鍛団壇弾断暖檀段男談値知地弛恥智池痴稚置致蜘遅馳築畜竹筑蓄逐秩窒茶嫡着中仲宙忠抽昼柱注虫衷註酎鋳駐樗瀦猪苧著貯丁兆凋喋寵\"],[\"c4a1\",\"帖帳庁弔張彫徴懲挑暢朝潮牒町眺聴脹腸蝶調諜超跳銚長頂鳥勅捗直朕沈珍賃鎮陳津墜椎槌追鎚痛通塚栂掴槻佃漬柘辻蔦綴鍔椿潰坪壷嬬紬爪吊釣鶴亭低停偵剃貞呈堤定帝底庭廷弟悌抵挺提梯汀碇禎程締艇訂諦蹄逓\"],[\"c5a1\",\"邸鄭釘鼎泥摘擢敵滴的笛適鏑溺哲徹撤轍迭鉄典填天展店添纏甜貼転顛点伝殿澱田電兎吐堵塗妬屠徒斗杜渡登菟賭途都鍍砥砺努度土奴怒倒党冬凍刀唐塔塘套宕島嶋悼投搭東桃梼棟盗淘湯涛灯燈当痘祷等答筒糖統到\"],[\"c6a1\",\"董蕩藤討謄豆踏逃透鐙陶頭騰闘働動同堂導憧撞洞瞳童胴萄道銅峠鴇匿得徳涜特督禿篤毒独読栃橡凸突椴届鳶苫寅酉瀞噸屯惇敦沌豚遁頓呑曇鈍奈那内乍凪薙謎灘捺鍋楢馴縄畷南楠軟難汝二尼弐迩匂賑肉虹廿日乳入\"],[\"c7a1\",\"如尿韮任妊忍認濡禰祢寧葱猫熱年念捻撚燃粘乃廼之埜嚢悩濃納能脳膿農覗蚤巴把播覇杷波派琶破婆罵芭馬俳廃拝排敗杯盃牌背肺輩配倍培媒梅楳煤狽買売賠陪這蝿秤矧萩伯剥博拍柏泊白箔粕舶薄迫曝漠爆縛莫駁麦\"],[\"c8a1\",\"函箱硲箸肇筈櫨幡肌畑畠八鉢溌発醗髪伐罰抜筏閥鳩噺塙蛤隼伴判半反叛帆搬斑板氾汎版犯班畔繁般藩販範釆煩頒飯挽晩番盤磐蕃蛮匪卑否妃庇彼悲扉批披斐比泌疲皮碑秘緋罷肥被誹費避非飛樋簸備尾微枇毘琵眉美\"],[\"c9a1\",\"鼻柊稗匹疋髭彦膝菱肘弼必畢筆逼桧姫媛紐百謬俵彪標氷漂瓢票表評豹廟描病秒苗錨鋲蒜蛭鰭品彬斌浜瀕貧賓頻敏瓶不付埠夫婦富冨布府怖扶敷斧普浮父符腐膚芙譜負賦赴阜附侮撫武舞葡蕪部封楓風葺蕗伏副復幅服\"],[\"caa1\",\"福腹複覆淵弗払沸仏物鮒分吻噴墳憤扮焚奮粉糞紛雰文聞丙併兵塀幣平弊柄並蔽閉陛米頁僻壁癖碧別瞥蔑箆偏変片篇編辺返遍便勉娩弁鞭保舗鋪圃捕歩甫補輔穂募墓慕戊暮母簿菩倣俸包呆報奉宝峰峯崩庖抱捧放方朋\"],[\"cba1\",\"法泡烹砲縫胞芳萌蓬蜂褒訪豊邦鋒飽鳳鵬乏亡傍剖坊妨帽忘忙房暴望某棒冒紡肪膨謀貌貿鉾防吠頬北僕卜墨撲朴牧睦穆釦勃没殆堀幌奔本翻凡盆摩磨魔麻埋妹昧枚毎哩槙幕膜枕鮪柾鱒桝亦俣又抹末沫迄侭繭麿万慢満\"],[\"cca1\",\"漫蔓味未魅巳箕岬密蜜湊蓑稔脈妙粍民眠務夢無牟矛霧鵡椋婿娘冥名命明盟迷銘鳴姪牝滅免棉綿緬面麺摸模茂妄孟毛猛盲網耗蒙儲木黙目杢勿餅尤戻籾貰問悶紋門匁也冶夜爺耶野弥矢厄役約薬訳躍靖柳薮鑓愉愈油癒\"],[\"cda1\",\"諭輸唯佑優勇友宥幽悠憂揖有柚湧涌猶猷由祐裕誘遊邑郵雄融夕予余与誉輿預傭幼妖容庸揚揺擁曜楊様洋溶熔用窯羊耀葉蓉要謡踊遥陽養慾抑欲沃浴翌翼淀羅螺裸来莱頼雷洛絡落酪乱卵嵐欄濫藍蘭覧利吏履李梨理璃\"],[\"cea1\",\"痢裏裡里離陸律率立葎掠略劉流溜琉留硫粒隆竜龍侶慮旅虜了亮僚両凌寮料梁涼猟療瞭稜糧良諒遼量陵領力緑倫厘林淋燐琳臨輪隣鱗麟瑠塁涙累類令伶例冷励嶺怜玲礼苓鈴隷零霊麗齢暦歴列劣烈裂廉恋憐漣煉簾練聯\"],[\"cfa1\",\"蓮連錬呂魯櫓炉賂路露労婁廊弄朗楼榔浪漏牢狼篭老聾蝋郎六麓禄肋録論倭和話歪賄脇惑枠鷲亙亘鰐詫藁蕨椀湾碗腕\"],[\"d0a1\",\"弌丐丕个丱丶丼丿乂乖乘亂亅豫亊舒弍于亞亟亠亢亰亳亶从仍仄仆仂仗仞仭仟价伉佚估佛佝佗佇佶侈侏侘佻佩佰侑佯來侖儘俔俟俎俘俛俑俚俐俤俥倚倨倔倪倥倅伜俶倡倩倬俾俯們倆偃假會偕偐偈做偖偬偸傀傚傅傴傲\"],[\"d1a1\",\"僉僊傳僂僖僞僥僭僣僮價僵儉儁儂儖儕儔儚儡儺儷儼儻儿兀兒兌兔兢竸兩兪兮冀冂囘册冉冏冑冓冕冖冤冦冢冩冪冫决冱冲冰况冽凅凉凛几處凩凭凰凵凾刄刋刔刎刧刪刮刳刹剏剄剋剌剞剔剪剴剩剳剿剽劍劔劒剱劈劑辨\"],[\"d2a1\",\"辧劬劭劼劵勁勍勗勞勣勦飭勠勳勵勸勹匆匈甸匍匐匏匕匚匣匯匱匳匸區卆卅丗卉卍凖卞卩卮夘卻卷厂厖厠厦厥厮厰厶參簒雙叟曼燮叮叨叭叺吁吽呀听吭吼吮吶吩吝呎咏呵咎呟呱呷呰咒呻咀呶咄咐咆哇咢咸咥咬哄哈咨\"],[\"d3a1\",\"咫哂咤咾咼哘哥哦唏唔哽哮哭哺哢唹啀啣啌售啜啅啖啗唸唳啝喙喀咯喊喟啻啾喘喞單啼喃喩喇喨嗚嗅嗟嗄嗜嗤嗔嘔嗷嘖嗾嗽嘛嗹噎噐營嘴嘶嘲嘸噫噤嘯噬噪嚆嚀嚊嚠嚔嚏嚥嚮嚶嚴囂嚼囁囃囀囈囎囑囓囗囮囹圀囿圄圉\"],[\"d4a1\",\"圈國圍圓團圖嗇圜圦圷圸坎圻址坏坩埀垈坡坿垉垓垠垳垤垪垰埃埆埔埒埓堊埖埣堋堙堝塲堡塢塋塰毀塒堽塹墅墹墟墫墺壞墻墸墮壅壓壑壗壙壘壥壜壤壟壯壺壹壻壼壽夂夊夐夛梦夥夬夭夲夸夾竒奕奐奎奚奘奢奠奧奬奩\"],[\"d5a1\",\"奸妁妝佞侫妣妲姆姨姜妍姙姚娥娟娑娜娉娚婀婬婉娵娶婢婪媚媼媾嫋嫂媽嫣嫗嫦嫩嫖嫺嫻嬌嬋嬖嬲嫐嬪嬶嬾孃孅孀孑孕孚孛孥孩孰孳孵學斈孺宀它宦宸寃寇寉寔寐寤實寢寞寥寫寰寶寳尅將專對尓尠尢尨尸尹屁屆屎屓\"],[\"d6a1\",\"屐屏孱屬屮乢屶屹岌岑岔妛岫岻岶岼岷峅岾峇峙峩峽峺峭嶌峪崋崕崗嵜崟崛崑崔崢崚崙崘嵌嵒嵎嵋嵬嵳嵶嶇嶄嶂嶢嶝嶬嶮嶽嶐嶷嶼巉巍巓巒巖巛巫已巵帋帚帙帑帛帶帷幄幃幀幎幗幔幟幢幤幇幵并幺麼广庠廁廂廈廐廏\"],[\"d7a1\",\"廖廣廝廚廛廢廡廨廩廬廱廳廰廴廸廾弃弉彝彜弋弑弖弩弭弸彁彈彌彎弯彑彖彗彙彡彭彳彷徃徂彿徊很徑徇從徙徘徠徨徭徼忖忻忤忸忱忝悳忿怡恠怙怐怩怎怱怛怕怫怦怏怺恚恁恪恷恟恊恆恍恣恃恤恂恬恫恙悁悍惧悃悚\"],[\"d8a1\",\"悄悛悖悗悒悧悋惡悸惠惓悴忰悽惆悵惘慍愕愆惶惷愀惴惺愃愡惻惱愍愎慇愾愨愧慊愿愼愬愴愽慂慄慳慷慘慙慚慫慴慯慥慱慟慝慓慵憙憖憇憬憔憚憊憑憫憮懌懊應懷懈懃懆憺懋罹懍懦懣懶懺懴懿懽懼懾戀戈戉戍戌戔戛\"],[\"d9a1\",\"戞戡截戮戰戲戳扁扎扞扣扛扠扨扼抂抉找抒抓抖拔抃抔拗拑抻拏拿拆擔拈拜拌拊拂拇抛拉挌拮拱挧挂挈拯拵捐挾捍搜捏掖掎掀掫捶掣掏掉掟掵捫捩掾揩揀揆揣揉插揶揄搖搴搆搓搦搶攝搗搨搏摧摯摶摎攪撕撓撥撩撈撼\"],[\"daa1\",\"據擒擅擇撻擘擂擱擧舉擠擡抬擣擯攬擶擴擲擺攀擽攘攜攅攤攣攫攴攵攷收攸畋效敖敕敍敘敞敝敲數斂斃變斛斟斫斷旃旆旁旄旌旒旛旙无旡旱杲昊昃旻杳昵昶昴昜晏晄晉晁晞晝晤晧晨晟晢晰暃暈暎暉暄暘暝曁暹曉暾暼\"],[\"dba1\",\"曄暸曖曚曠昿曦曩曰曵曷朏朖朞朦朧霸朮朿朶杁朸朷杆杞杠杙杣杤枉杰枩杼杪枌枋枦枡枅枷柯枴柬枳柩枸柤柞柝柢柮枹柎柆柧檜栞框栩桀桍栲桎梳栫桙档桷桿梟梏梭梔條梛梃檮梹桴梵梠梺椏梍桾椁棊椈棘椢椦棡椌棍\"],[\"dca1\",\"棔棧棕椶椒椄棗棣椥棹棠棯椨椪椚椣椡棆楹楷楜楸楫楔楾楮椹楴椽楙椰楡楞楝榁楪榲榮槐榿槁槓榾槎寨槊槝榻槃榧樮榑榠榜榕榴槞槨樂樛槿權槹槲槧樅榱樞槭樔槫樊樒櫁樣樓橄樌橲樶橸橇橢橙橦橈樸樢檐檍檠檄檢檣\"],[\"dda1\",\"檗蘗檻櫃櫂檸檳檬櫞櫑櫟檪櫚櫪櫻欅蘖櫺欒欖鬱欟欸欷盜欹飮歇歃歉歐歙歔歛歟歡歸歹歿殀殄殃殍殘殕殞殤殪殫殯殲殱殳殷殼毆毋毓毟毬毫毳毯麾氈氓气氛氤氣汞汕汢汪沂沍沚沁沛汾汨汳沒沐泄泱泓沽泗泅泝沮沱沾\"],[\"dea1\",\"沺泛泯泙泪洟衍洶洫洽洸洙洵洳洒洌浣涓浤浚浹浙涎涕濤涅淹渕渊涵淇淦涸淆淬淞淌淨淒淅淺淙淤淕淪淮渭湮渮渙湲湟渾渣湫渫湶湍渟湃渺湎渤滿渝游溂溪溘滉溷滓溽溯滄溲滔滕溏溥滂溟潁漑灌滬滸滾漿滲漱滯漲滌\"],[\"dfa1\",\"漾漓滷澆潺潸澁澀潯潛濳潭澂潼潘澎澑濂潦澳澣澡澤澹濆澪濟濕濬濔濘濱濮濛瀉瀋濺瀑瀁瀏濾瀛瀚潴瀝瀘瀟瀰瀾瀲灑灣炙炒炯烱炬炸炳炮烟烋烝烙焉烽焜焙煥煕熈煦煢煌煖煬熏燻熄熕熨熬燗熹熾燒燉燔燎燠燬燧燵燼\"],[\"e0a1\",\"燹燿爍爐爛爨爭爬爰爲爻爼爿牀牆牋牘牴牾犂犁犇犒犖犢犧犹犲狃狆狄狎狒狢狠狡狹狷倏猗猊猜猖猝猴猯猩猥猾獎獏默獗獪獨獰獸獵獻獺珈玳珎玻珀珥珮珞璢琅瑯琥珸琲琺瑕琿瑟瑙瑁瑜瑩瑰瑣瑪瑶瑾璋璞璧瓊瓏瓔珱\"],[\"e1a1\",\"瓠瓣瓧瓩瓮瓲瓰瓱瓸瓷甄甃甅甌甎甍甕甓甞甦甬甼畄畍畊畉畛畆畚畩畤畧畫畭畸當疆疇畴疊疉疂疔疚疝疥疣痂疳痃疵疽疸疼疱痍痊痒痙痣痞痾痿痼瘁痰痺痲痳瘋瘍瘉瘟瘧瘠瘡瘢瘤瘴瘰瘻癇癈癆癜癘癡癢癨癩癪癧癬癰\"],[\"e2a1\",\"癲癶癸發皀皃皈皋皎皖皓皙皚皰皴皸皹皺盂盍盖盒盞盡盥盧盪蘯盻眈眇眄眩眤眞眥眦眛眷眸睇睚睨睫睛睥睿睾睹瞎瞋瞑瞠瞞瞰瞶瞹瞿瞼瞽瞻矇矍矗矚矜矣矮矼砌砒礦砠礪硅碎硴碆硼碚碌碣碵碪碯磑磆磋磔碾碼磅磊磬\"],[\"e3a1\",\"磧磚磽磴礇礒礑礙礬礫祀祠祗祟祚祕祓祺祿禊禝禧齋禪禮禳禹禺秉秕秧秬秡秣稈稍稘稙稠稟禀稱稻稾稷穃穗穉穡穢穩龝穰穹穽窈窗窕窘窖窩竈窰窶竅竄窿邃竇竊竍竏竕竓站竚竝竡竢竦竭竰笂笏笊笆笳笘笙笞笵笨笶筐\"],[\"e4a1\",\"筺笄筍笋筌筅筵筥筴筧筰筱筬筮箝箘箟箍箜箚箋箒箏筝箙篋篁篌篏箴篆篝篩簑簔篦篥籠簀簇簓篳篷簗簍篶簣簧簪簟簷簫簽籌籃籔籏籀籐籘籟籤籖籥籬籵粃粐粤粭粢粫粡粨粳粲粱粮粹粽糀糅糂糘糒糜糢鬻糯糲糴糶糺紆\"],[\"e5a1\",\"紂紜紕紊絅絋紮紲紿紵絆絳絖絎絲絨絮絏絣經綉絛綏絽綛綺綮綣綵緇綽綫總綢綯緜綸綟綰緘緝緤緞緻緲緡縅縊縣縡縒縱縟縉縋縢繆繦縻縵縹繃縷縲縺繧繝繖繞繙繚繹繪繩繼繻纃緕繽辮繿纈纉續纒纐纓纔纖纎纛纜缸缺\"],[\"e6a1\",\"罅罌罍罎罐网罕罔罘罟罠罨罩罧罸羂羆羃羈羇羌羔羞羝羚羣羯羲羹羮羶羸譱翅翆翊翕翔翡翦翩翳翹飜耆耄耋耒耘耙耜耡耨耿耻聊聆聒聘聚聟聢聨聳聲聰聶聹聽聿肄肆肅肛肓肚肭冐肬胛胥胙胝胄胚胖脉胯胱脛脩脣脯腋\"],[\"e7a1\",\"隋腆脾腓腑胼腱腮腥腦腴膃膈膊膀膂膠膕膤膣腟膓膩膰膵膾膸膽臀臂膺臉臍臑臙臘臈臚臟臠臧臺臻臾舁舂舅與舊舍舐舖舩舫舸舳艀艙艘艝艚艟艤艢艨艪艫舮艱艷艸艾芍芒芫芟芻芬苡苣苟苒苴苳苺莓范苻苹苞茆苜茉苙\"],[\"e8a1\",\"茵茴茖茲茱荀茹荐荅茯茫茗茘莅莚莪莟莢莖茣莎莇莊荼莵荳荵莠莉莨菴萓菫菎菽萃菘萋菁菷萇菠菲萍萢萠莽萸蔆菻葭萪萼蕚蒄葷葫蒭葮蒂葩葆萬葯葹萵蓊葢蒹蒿蒟蓙蓍蒻蓚蓐蓁蓆蓖蒡蔡蓿蓴蔗蔘蔬蔟蔕蔔蓼蕀蕣蕘蕈\"],[\"e9a1\",\"蕁蘂蕋蕕薀薤薈薑薊薨蕭薔薛藪薇薜蕷蕾薐藉薺藏薹藐藕藝藥藜藹蘊蘓蘋藾藺蘆蘢蘚蘰蘿虍乕虔號虧虱蚓蚣蚩蚪蚋蚌蚶蚯蛄蛆蚰蛉蠣蚫蛔蛞蛩蛬蛟蛛蛯蜒蜆蜈蜀蜃蛻蜑蜉蜍蛹蜊蜴蜿蜷蜻蜥蜩蜚蝠蝟蝸蝌蝎蝴蝗蝨蝮蝙\"],[\"eaa1\",\"蝓蝣蝪蠅螢螟螂螯蟋螽蟀蟐雖螫蟄螳蟇蟆螻蟯蟲蟠蠏蠍蟾蟶蟷蠎蟒蠑蠖蠕蠢蠡蠱蠶蠹蠧蠻衄衂衒衙衞衢衫袁衾袞衵衽袵衲袂袗袒袮袙袢袍袤袰袿袱裃裄裔裘裙裝裹褂裼裴裨裲褄褌褊褓襃褞褥褪褫襁襄褻褶褸襌褝襠襞\"],[\"eba1\",\"襦襤襭襪襯襴襷襾覃覈覊覓覘覡覩覦覬覯覲覺覽覿觀觚觜觝觧觴觸訃訖訐訌訛訝訥訶詁詛詒詆詈詼詭詬詢誅誂誄誨誡誑誥誦誚誣諄諍諂諚諫諳諧諤諱謔諠諢諷諞諛謌謇謚諡謖謐謗謠謳鞫謦謫謾謨譁譌譏譎證譖譛譚譫\"],[\"eca1\",\"譟譬譯譴譽讀讌讎讒讓讖讙讚谺豁谿豈豌豎豐豕豢豬豸豺貂貉貅貊貍貎貔豼貘戝貭貪貽貲貳貮貶賈賁賤賣賚賽賺賻贄贅贊贇贏贍贐齎贓賍贔贖赧赭赱赳趁趙跂趾趺跏跚跖跌跛跋跪跫跟跣跼踈踉跿踝踞踐踟蹂踵踰踴蹊\"],[\"eda1\",\"蹇蹉蹌蹐蹈蹙蹤蹠踪蹣蹕蹶蹲蹼躁躇躅躄躋躊躓躑躔躙躪躡躬躰軆躱躾軅軈軋軛軣軼軻軫軾輊輅輕輒輙輓輜輟輛輌輦輳輻輹轅轂輾轌轉轆轎轗轜轢轣轤辜辟辣辭辯辷迚迥迢迪迯邇迴逅迹迺逑逕逡逍逞逖逋逧逶逵逹迸\"],[\"eea1\",\"遏遐遑遒逎遉逾遖遘遞遨遯遶隨遲邂遽邁邀邊邉邏邨邯邱邵郢郤扈郛鄂鄒鄙鄲鄰酊酖酘酣酥酩酳酲醋醉醂醢醫醯醪醵醴醺釀釁釉釋釐釖釟釡釛釼釵釶鈞釿鈔鈬鈕鈑鉞鉗鉅鉉鉤鉈銕鈿鉋鉐銜銖銓銛鉚鋏銹銷鋩錏鋺鍄錮\"],[\"efa1\",\"錙錢錚錣錺錵錻鍜鍠鍼鍮鍖鎰鎬鎭鎔鎹鏖鏗鏨鏥鏘鏃鏝鏐鏈鏤鐚鐔鐓鐃鐇鐐鐶鐫鐵鐡鐺鑁鑒鑄鑛鑠鑢鑞鑪鈩鑰鑵鑷鑽鑚鑼鑾钁鑿閂閇閊閔閖閘閙閠閨閧閭閼閻閹閾闊濶闃闍闌闕闔闖關闡闥闢阡阨阮阯陂陌陏陋陷陜陞\"],[\"f0a1\",\"陝陟陦陲陬隍隘隕隗險隧隱隲隰隴隶隸隹雎雋雉雍襍雜霍雕雹霄霆霈霓霎霑霏霖霙霤霪霰霹霽霾靄靆靈靂靉靜靠靤靦靨勒靫靱靹鞅靼鞁靺鞆鞋鞏鞐鞜鞨鞦鞣鞳鞴韃韆韈韋韜韭齏韲竟韶韵頏頌頸頤頡頷頽顆顏顋顫顯顰\"],[\"f1a1\",\"顱顴顳颪颯颱颶飄飃飆飩飫餃餉餒餔餘餡餝餞餤餠餬餮餽餾饂饉饅饐饋饑饒饌饕馗馘馥馭馮馼駟駛駝駘駑駭駮駱駲駻駸騁騏騅駢騙騫騷驅驂驀驃騾驕驍驛驗驟驢驥驤驩驫驪骭骰骼髀髏髑髓體髞髟髢髣髦髯髫髮髴髱髷\"],[\"f2a1\",\"髻鬆鬘鬚鬟鬢鬣鬥鬧鬨鬩鬪鬮鬯鬲魄魃魏魍魎魑魘魴鮓鮃鮑鮖鮗鮟鮠鮨鮴鯀鯊鮹鯆鯏鯑鯒鯣鯢鯤鯔鯡鰺鯲鯱鯰鰕鰔鰉鰓鰌鰆鰈鰒鰊鰄鰮鰛鰥鰤鰡鰰鱇鰲鱆鰾鱚鱠鱧鱶鱸鳧鳬鳰鴉鴈鳫鴃鴆鴪鴦鶯鴣鴟鵄鴕鴒鵁鴿鴾鵆鵈\"],[\"f3a1\",\"鵝鵞鵤鵑鵐鵙鵲鶉鶇鶫鵯鵺鶚鶤鶩鶲鷄鷁鶻鶸鶺鷆鷏鷂鷙鷓鷸鷦鷭鷯鷽鸚鸛鸞鹵鹹鹽麁麈麋麌麒麕麑麝麥麩麸麪麭靡黌黎黏黐黔黜點黝黠黥黨黯黴黶黷黹黻黼黽鼇鼈皷鼕鼡鼬鼾齊齒齔齣齟齠齡齦齧齬齪齷齲齶龕龜龠\"],[\"f4a1\",\"堯槇遙瑤凜熙\"],[\"f9a1\",\"纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德\"],[\"faa1\",\"忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱\"],[\"fba1\",\"犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚\"],[\"fca1\",\"釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑\"],[\"fcf1\",\"ⅰ\",9,\"￢￤＇＂\"],[\"8fa2af\",\"˘ˇ¸˙˝¯˛˚～΄΅\"],[\"8fa2c2\",\"¡¦¿\"],[\"8fa2eb\",\"ºª©®™¤№\"],[\"8fa6e1\",\"ΆΈΉΊΪ\"],[\"8fa6e7\",\"Ό\"],[\"8fa6e9\",\"ΎΫ\"],[\"8fa6ec\",\"Ώ\"],[\"8fa6f1\",\"άέήίϊΐόςύϋΰώ\"],[\"8fa7c2\",\"Ђ\",10,\"ЎЏ\"],[\"8fa7f2\",\"ђ\",10,\"ўџ\"],[\"8fa9a1\",\"ÆĐ\"],[\"8fa9a4\",\"Ħ\"],[\"8fa9a6\",\"Ĳ\"],[\"8fa9a8\",\"ŁĿ\"],[\"8fa9ab\",\"ŊØŒ\"],[\"8fa9af\",\"ŦÞ\"],[\"8fa9c1\",\"æđðħıĳĸłŀŉŋøœßŧþ\"],[\"8faaa1\",\"ÁÀÄÂĂǍĀĄÅÃĆĈČÇĊĎÉÈËÊĚĖĒĘ\"],[\"8faaba\",\"ĜĞĢĠĤÍÌÏÎǏİĪĮĨĴĶĹĽĻŃŇŅÑÓÒÖÔǑŐŌÕŔŘŖŚŜŠŞŤŢÚÙÜÛŬǓŰŪŲŮŨǗǛǙǕŴÝŸŶŹŽŻ\"],[\"8faba1\",\"áàäâăǎāąåãćĉčçċďéèëêěėēęǵĝğ\"],[\"8fabbd\",\"ġĥíìïîǐ\"],[\"8fabc5\",\"īįĩĵķĺľļńňņñóòöôǒőōõŕřŗśŝšşťţúùüûŭǔűūųůũǘǜǚǖŵýÿŷźžż\"],[\"8fb0a1\",\"丂丄丅丌丒丟丣两丨丫丮丯丰丵乀乁乄乇乑乚乜乣乨乩乴乵乹乿亍亖亗亝亯亹仃仐仚仛仠仡仢仨仯仱仳仵份仾仿伀伂伃伈伋伌伒伕伖众伙伮伱你伳伵伷伹伻伾佀佂佈佉佋佌佒佔佖佘佟佣佪佬佮佱佷佸佹佺佽佾侁侂侄\"],[\"8fb1a1\",\"侅侉侊侌侎侐侒侓侔侗侙侚侞侟侲侷侹侻侼侽侾俀俁俅俆俈俉俋俌俍俏俒俜俠俢俰俲俼俽俿倀倁倄倇倊倌倎倐倓倗倘倛倜倝倞倢倧倮倰倲倳倵偀偁偂偅偆偊偌偎偑偒偓偗偙偟偠偢偣偦偧偪偭偰偱倻傁傃傄傆傊傎傏傐\"],[\"8fb2a1\",\"傒傓傔傖傛傜傞\",4,\"傪傯傰傹傺傽僀僃僄僇僌僎僐僓僔僘僜僝僟僢僤僦僨僩僯僱僶僺僾儃儆儇儈儋儌儍儎僲儐儗儙儛儜儝儞儣儧儨儬儭儯儱儳儴儵儸儹兂兊兏兓兕兗兘兟兤兦兾冃冄冋冎冘冝冡冣冭冸冺冼冾冿凂\"],[\"8fb3a1\",\"凈减凑凒凓凕凘凞凢凥凮凲凳凴凷刁刂刅划刓刕刖刘刢刨刱刲刵刼剅剉剕剗剘剚剜剟剠剡剦剮剷剸剹劀劂劅劊劌劓劕劖劗劘劚劜劤劥劦劧劯劰劶劷劸劺劻劽勀勄勆勈勌勏勑勔勖勛勜勡勥勨勩勪勬勰勱勴勶勷匀匃匊匋\"],[\"8fb4a1\",\"匌匑匓匘匛匜匞匟匥匧匨匩匫匬匭匰匲匵匼匽匾卂卌卋卙卛卡卣卥卬卭卲卹卾厃厇厈厎厓厔厙厝厡厤厪厫厯厲厴厵厷厸厺厽叀叅叏叒叓叕叚叝叞叠另叧叵吂吓吚吡吧吨吪启吱吴吵呃呄呇呍呏呞呢呤呦呧呩呫呭呮呴呿\"],[\"8fb5a1\",\"咁咃咅咈咉咍咑咕咖咜咟咡咦咧咩咪咭咮咱咷咹咺咻咿哆哊响哎哠哪哬哯哶哼哾哿唀唁唅唈唉唌唍唎唕唪唫唲唵唶唻唼唽啁啇啉啊啍啐啑啘啚啛啞啠啡啤啦啿喁喂喆喈喎喏喑喒喓喔喗喣喤喭喲喿嗁嗃嗆嗉嗋嗌嗎嗑嗒\"],[\"8fb6a1\",\"嗓嗗嗘嗛嗞嗢嗩嗶嗿嘅嘈嘊嘍\",5,\"嘙嘬嘰嘳嘵嘷嘹嘻嘼嘽嘿噀噁噃噄噆噉噋噍噏噔噞噠噡噢噣噦噩噭噯噱噲噵嚄嚅嚈嚋嚌嚕嚙嚚嚝嚞嚟嚦嚧嚨嚩嚫嚬嚭嚱嚳嚷嚾囅囉囊囋囏囐囌囍囙囜囝囟囡囤\",4,\"囱囫园\"],[\"8fb7a1\",\"囶囷圁圂圇圊圌圑圕圚圛圝圠圢圣圤圥圩圪圬圮圯圳圴圽圾圿坅坆坌坍坒坢坥坧坨坫坭\",4,\"坳坴坵坷坹坺坻坼坾垁垃垌垔垗垙垚垜垝垞垟垡垕垧垨垩垬垸垽埇埈埌埏埕埝埞埤埦埧埩埭埰埵埶埸埽埾埿堃堄堈堉埡\"],[\"8fb8a1\",\"堌堍堛堞堟堠堦堧堭堲堹堿塉塌塍塏塐塕塟塡塤塧塨塸塼塿墀墁墇墈墉墊墌墍墏墐墔墖墝墠墡墢墦墩墱墲壄墼壂壈壍壎壐壒壔壖壚壝壡壢壩壳夅夆夋夌夒夓夔虁夝夡夣夤夨夯夰夳夵夶夿奃奆奒奓奙奛奝奞奟奡奣奫奭\"],[\"8fb9a1\",\"奯奲奵奶她奻奼妋妌妎妒妕妗妟妤妧妭妮妯妰妳妷妺妼姁姃姄姈姊姍姒姝姞姟姣姤姧姮姯姱姲姴姷娀娄娌娍娎娒娓娞娣娤娧娨娪娭娰婄婅婇婈婌婐婕婞婣婥婧婭婷婺婻婾媋媐媓媖媙媜媞媟媠媢媧媬媱媲媳媵媸媺媻媿\"],[\"8fbaa1\",\"嫄嫆嫈嫏嫚嫜嫠嫥嫪嫮嫵嫶嫽嬀嬁嬈嬗嬴嬙嬛嬝嬡嬥嬭嬸孁孋孌孒孖孞孨孮孯孼孽孾孿宁宄宆宊宎宐宑宓宔宖宨宩宬宭宯宱宲宷宺宼寀寁寍寏寖\",4,\"寠寯寱寴寽尌尗尞尟尣尦尩尫尬尮尰尲尵尶屙屚屜屢屣屧屨屩\"],[\"8fbba1\",\"屭屰屴屵屺屻屼屽岇岈岊岏岒岝岟岠岢岣岦岪岲岴岵岺峉峋峒峝峗峮峱峲峴崁崆崍崒崫崣崤崦崧崱崴崹崽崿嵂嵃嵆嵈嵕嵑嵙嵊嵟嵠嵡嵢嵤嵪嵭嵰嵹嵺嵾嵿嶁嶃嶈嶊嶒嶓嶔嶕嶙嶛嶟嶠嶧嶫嶰嶴嶸嶹巃巇巋巐巎巘巙巠巤\"],[\"8fbca1\",\"巩巸巹帀帇帍帒帔帕帘帟帠帮帨帲帵帾幋幐幉幑幖幘幛幜幞幨幪\",4,\"幰庀庋庎庢庤庥庨庪庬庱庳庽庾庿廆廌廋廎廑廒廔廕廜廞廥廫异弆弇弈弎弙弜弝弡弢弣弤弨弫弬弮弰弴弶弻弽弿彀彄彅彇彍彐彔彘彛彠彣彤彧\"],[\"8fbda1\",\"彯彲彴彵彸彺彽彾徉徍徏徖徜徝徢徧徫徤徬徯徰徱徸忄忇忈忉忋忐\",4,\"忞忡忢忨忩忪忬忭忮忯忲忳忶忺忼怇怊怍怓怔怗怘怚怟怤怭怳怵恀恇恈恉恌恑恔恖恗恝恡恧恱恾恿悂悆悈悊悎悑悓悕悘悝悞悢悤悥您悰悱悷\"],[\"8fbea1\",\"悻悾惂惄惈惉惊惋惎惏惔惕惙惛惝惞惢惥惲惵惸惼惽愂愇愊愌愐\",4,\"愖愗愙愜愞愢愪愫愰愱愵愶愷愹慁慅慆慉慞慠慬慲慸慻慼慿憀憁憃憄憋憍憒憓憗憘憜憝憟憠憥憨憪憭憸憹憼懀懁懂懎懏懕懜懝懞懟懡懢懧懩懥\"],[\"8fbfa1\",\"懬懭懯戁戃戄戇戓戕戜戠戢戣戧戩戫戹戽扂扃扄扆扌扐扑扒扔扖扚扜扤扭扯扳扺扽抍抎抏抐抦抨抳抶抷抺抾抿拄拎拕拖拚拪拲拴拼拽挃挄挊挋挍挐挓挖挘挩挪挭挵挶挹挼捁捂捃捄捆捊捋捎捒捓捔捘捛捥捦捬捭捱捴捵\"],[\"8fc0a1\",\"捸捼捽捿掂掄掇掊掐掔掕掙掚掞掤掦掭掮掯掽揁揅揈揎揑揓揔揕揜揠揥揪揬揲揳揵揸揹搉搊搐搒搔搘搞搠搢搤搥搩搪搯搰搵搽搿摋摏摑摒摓摔摚摛摜摝摟摠摡摣摭摳摴摻摽撅撇撏撐撑撘撙撛撝撟撡撣撦撨撬撳撽撾撿\"],[\"8fc1a1\",\"擄擉擊擋擌擎擐擑擕擗擤擥擩擪擭擰擵擷擻擿攁攄攈攉攊攏攓攔攖攙攛攞攟攢攦攩攮攱攺攼攽敃敇敉敐敒敔敟敠敧敫敺敽斁斅斊斒斕斘斝斠斣斦斮斲斳斴斿旂旈旉旎旐旔旖旘旟旰旲旴旵旹旾旿昀昄昈昉昍昑昒昕昖昝\"],[\"8fc2a1\",\"昞昡昢昣昤昦昩昪昫昬昮昰昱昳昹昷晀晅晆晊晌晑晎晗晘晙晛晜晠晡曻晪晫晬晾晳晵晿晷晸晹晻暀晼暋暌暍暐暒暙暚暛暜暟暠暤暭暱暲暵暻暿曀曂曃曈曌曎曏曔曛曟曨曫曬曮曺朅朇朎朓朙朜朠朢朳朾杅杇杈杌杔杕杝\"],[\"8fc3a1\",\"杦杬杮杴杶杻极构枎枏枑枓枖枘枙枛枰枱枲枵枻枼枽柹柀柂柃柅柈柉柒柗柙柜柡柦柰柲柶柷桒栔栙栝栟栨栧栬栭栯栰栱栳栻栿桄桅桊桌桕桗桘桛桫桮\",4,\"桵桹桺桻桼梂梄梆梈梖梘梚梜梡梣梥梩梪梮梲梻棅棈棌棏\"],[\"8fc4a1\",\"棐棑棓棖棙棜棝棥棨棪棫棬棭棰棱棵棶棻棼棽椆椉椊椐椑椓椖椗椱椳椵椸椻楂楅楉楎楗楛楣楤楥楦楨楩楬楰楱楲楺楻楿榀榍榒榖榘榡榥榦榨榫榭榯榷榸榺榼槅槈槑槖槗槢槥槮槯槱槳槵槾樀樁樃樏樑樕樚樝樠樤樨樰樲\"],[\"8fc5a1\",\"樴樷樻樾樿橅橆橉橊橎橐橑橒橕橖橛橤橧橪橱橳橾檁檃檆檇檉檋檑檛檝檞檟檥檫檯檰檱檴檽檾檿櫆櫉櫈櫌櫐櫔櫕櫖櫜櫝櫤櫧櫬櫰櫱櫲櫼櫽欂欃欆欇欉欏欐欑欗欛欞欤欨欫欬欯欵欶欻欿歆歊歍歒歖歘歝歠歧歫歮歰歵歽\"],[\"8fc6a1\",\"歾殂殅殗殛殟殠殢殣殨殩殬殭殮殰殸殹殽殾毃毄毉毌毖毚毡毣毦毧毮毱毷毹毿氂氄氅氉氍氎氐氒氙氟氦氧氨氬氮氳氵氶氺氻氿汊汋汍汏汒汔汙汛汜汫汭汯汴汶汸汹汻沅沆沇沉沔沕沗沘沜沟沰沲沴泂泆泍泏泐泑泒泔泖\"],[\"8fc7a1\",\"泚泜泠泧泩泫泬泮泲泴洄洇洊洎洏洑洓洚洦洧洨汧洮洯洱洹洼洿浗浞浟浡浥浧浯浰浼涂涇涑涒涔涖涗涘涪涬涴涷涹涽涿淄淈淊淎淏淖淛淝淟淠淢淥淩淯淰淴淶淼渀渄渞渢渧渲渶渹渻渼湄湅湈湉湋湏湑湒湓湔湗湜湝湞\"],[\"8fc8a1\",\"湢湣湨湳湻湽溍溓溙溠溧溭溮溱溳溻溿滀滁滃滇滈滊滍滎滏滫滭滮滹滻滽漄漈漊漌漍漖漘漚漛漦漩漪漯漰漳漶漻漼漭潏潑潒潓潗潙潚潝潞潡潢潨潬潽潾澃澇澈澋澌澍澐澒澓澔澖澚澟澠澥澦澧澨澮澯澰澵澶澼濅濇濈濊\"],[\"8fc9a1\",\"濚濞濨濩濰濵濹濼濽瀀瀅瀆瀇瀍瀗瀠瀣瀯瀴瀷瀹瀼灃灄灈灉灊灋灔灕灝灞灎灤灥灬灮灵灶灾炁炅炆炔\",4,\"炛炤炫炰炱炴炷烊烑烓烔烕烖烘烜烤烺焃\",4,\"焋焌焏焞焠焫焭焯焰焱焸煁煅煆煇煊煋煐煒煗煚煜煞煠\"],[\"8fcaa1\",\"煨煹熀熅熇熌熒熚熛熠熢熯熰熲熳熺熿燀燁燄燋燌燓燖燙燚燜燸燾爀爇爈爉爓爗爚爝爟爤爫爯爴爸爹牁牂牃牅牎牏牐牓牕牖牚牜牞牠牣牨牫牮牯牱牷牸牻牼牿犄犉犍犎犓犛犨犭犮犱犴犾狁狇狉狌狕狖狘狟狥狳狴狺狻\"],[\"8fcba1\",\"狾猂猄猅猇猋猍猒猓猘猙猞猢猤猧猨猬猱猲猵猺猻猽獃獍獐獒獖獘獝獞獟獠獦獧獩獫獬獮獯獱獷獹獼玀玁玃玅玆玎玐玓玕玗玘玜玞玟玠玢玥玦玪玫玭玵玷玹玼玽玿珅珆珉珋珌珏珒珓珖珙珝珡珣珦珧珩珴珵珷珹珺珻珽\"],[\"8fcca1\",\"珿琀琁琄琇琊琑琚琛琤琦琨\",9,\"琹瑀瑃瑄瑆瑇瑋瑍瑑瑒瑗瑝瑢瑦瑧瑨瑫瑭瑮瑱瑲璀璁璅璆璇璉璏璐璑璒璘璙璚璜璟璠璡璣璦璨璩璪璫璮璯璱璲璵璹璻璿瓈瓉瓌瓐瓓瓘瓚瓛瓞瓟瓤瓨瓪瓫瓯瓴瓺瓻瓼瓿甆\"],[\"8fcda1\",\"甒甖甗甠甡甤甧甩甪甯甶甹甽甾甿畀畃畇畈畎畐畒畗畞畟畡畯畱畹\",5,\"疁疅疐疒疓疕疙疜疢疤疴疺疿痀痁痄痆痌痎痏痗痜痟痠痡痤痧痬痮痯痱痹瘀瘂瘃瘄瘇瘈瘊瘌瘏瘒瘓瘕瘖瘙瘛瘜瘝瘞瘣瘥瘦瘩瘭瘲瘳瘵瘸瘹\"],[\"8fcea1\",\"瘺瘼癊癀癁癃癄癅癉癋癕癙癟癤癥癭癮癯癱癴皁皅皌皍皕皛皜皝皟皠皢\",6,\"皪皭皽盁盅盉盋盌盎盔盙盠盦盨盬盰盱盶盹盼眀眆眊眎眒眔眕眗眙眚眜眢眨眭眮眯眴眵眶眹眽眾睂睅睆睊睍睎睏睒睖睗睜睞睟睠睢\"],[\"8fcfa1\",\"睤睧睪睬睰睲睳睴睺睽瞀瞄瞌瞍瞔瞕瞖瞚瞟瞢瞧瞪瞮瞯瞱瞵瞾矃矉矑矒矕矙矞矟矠矤矦矪矬矰矱矴矸矻砅砆砉砍砎砑砝砡砢砣砭砮砰砵砷硃硄硇硈硌硎硒硜硞硠硡硣硤硨硪确硺硾碊碏碔碘碡碝碞碟碤碨碬碭碰碱碲碳\"],[\"8fd0a1\",\"碻碽碿磇磈磉磌磎磒磓磕磖磤磛磟磠磡磦磪磲磳礀磶磷磺磻磿礆礌礐礚礜礞礟礠礥礧礩礭礱礴礵礻礽礿祄祅祆祊祋祏祑祔祘祛祜祧祩祫祲祹祻祼祾禋禌禑禓禔禕禖禘禛禜禡禨禩禫禯禱禴禸离秂秄秇秈秊秏秔秖秚秝秞\"],[\"8fd1a1\",\"秠秢秥秪秫秭秱秸秼稂稃稇稉稊稌稑稕稛稞稡稧稫稭稯稰稴稵稸稹稺穄穅穇穈穌穕穖穙穜穝穟穠穥穧穪穭穵穸穾窀窂窅窆窊窋窐窑窔窞窠窣窬窳窵窹窻窼竆竉竌竎竑竛竨竩竫竬竱竴竻竽竾笇笔笟笣笧笩笪笫笭笮笯笰\"],[\"8fd2a1\",\"笱笴笽笿筀筁筇筎筕筠筤筦筩筪筭筯筲筳筷箄箉箎箐箑箖箛箞箠箥箬箯箰箲箵箶箺箻箼箽篂篅篈篊篔篖篗篙篚篛篨篪篲篴篵篸篹篺篼篾簁簂簃簄簆簉簋簌簎簏簙簛簠簥簦簨簬簱簳簴簶簹簺籆籊籕籑籒籓籙\",5],[\"8fd3a1\",\"籡籣籧籩籭籮籰籲籹籼籽粆粇粏粔粞粠粦粰粶粷粺粻粼粿糄糇糈糉糍糏糓糔糕糗糙糚糝糦糩糫糵紃紇紈紉紏紑紒紓紖紝紞紣紦紪紭紱紼紽紾絀絁絇絈絍絑絓絗絙絚絜絝絥絧絪絰絸絺絻絿綁綂綃綅綆綈綋綌綍綑綖綗綝\"],[\"8fd4a1\",\"綞綦綧綪綳綶綷綹緂\",4,\"緌緍緎緗緙縀緢緥緦緪緫緭緱緵緶緹緺縈縐縑縕縗縜縝縠縧縨縬縭縯縳縶縿繄繅繇繎繐繒繘繟繡繢繥繫繮繯繳繸繾纁纆纇纊纍纑纕纘纚纝纞缼缻缽缾缿罃罄罇罏罒罓罛罜罝罡罣罤罥罦罭\"],[\"8fd5a1\",\"罱罽罾罿羀羋羍羏羐羑羖羗羜羡羢羦羪羭羴羼羿翀翃翈翎翏翛翟翣翥翨翬翮翯翲翺翽翾翿耇耈耊耍耎耏耑耓耔耖耝耞耟耠耤耦耬耮耰耴耵耷耹耺耼耾聀聄聠聤聦聭聱聵肁肈肎肜肞肦肧肫肸肹胈胍胏胒胔胕胗胘胠胭胮\"],[\"8fd6a1\",\"胰胲胳胶胹胺胾脃脋脖脗脘脜脞脠脤脧脬脰脵脺脼腅腇腊腌腒腗腠腡腧腨腩腭腯腷膁膐膄膅膆膋膎膖膘膛膞膢膮膲膴膻臋臃臅臊臎臏臕臗臛臝臞臡臤臫臬臰臱臲臵臶臸臹臽臿舀舃舏舓舔舙舚舝舡舢舨舲舴舺艃艄艅艆\"],[\"8fd7a1\",\"艋艎艏艑艖艜艠艣艧艭艴艻艽艿芀芁芃芄芇芉芊芎芑芔芖芘芚芛芠芡芣芤芧芨芩芪芮芰芲芴芷芺芼芾芿苆苐苕苚苠苢苤苨苪苭苯苶苷苽苾茀茁茇茈茊茋荔茛茝茞茟茡茢茬茭茮茰茳茷茺茼茽荂荃荄荇荍荎荑荕荖荗荰荸\"],[\"8fd8a1\",\"荽荿莀莂莄莆莍莒莔莕莘莙莛莜莝莦莧莩莬莾莿菀菇菉菏菐菑菔菝荓菨菪菶菸菹菼萁萆萊萏萑萕萙莭萯萹葅葇葈葊葍葏葑葒葖葘葙葚葜葠葤葥葧葪葰葳葴葶葸葼葽蒁蒅蒒蒓蒕蒞蒦蒨蒩蒪蒯蒱蒴蒺蒽蒾蓀蓂蓇蓈蓌蓏蓓\"],[\"8fd9a1\",\"蓜蓧蓪蓯蓰蓱蓲蓷蔲蓺蓻蓽蔂蔃蔇蔌蔎蔐蔜蔞蔢蔣蔤蔥蔧蔪蔫蔯蔳蔴蔶蔿蕆蕏\",4,\"蕖蕙蕜\",6,\"蕤蕫蕯蕹蕺蕻蕽蕿薁薅薆薉薋薌薏薓薘薝薟薠薢薥薧薴薶薷薸薼薽薾薿藂藇藊藋藎薭藘藚藟藠藦藨藭藳藶藼\"],[\"8fdaa1\",\"藿蘀蘄蘅蘍蘎蘐蘑蘒蘘蘙蘛蘞蘡蘧蘩蘶蘸蘺蘼蘽虀虂虆虒虓虖虗虘虙虝虠\",4,\"虩虬虯虵虶虷虺蚍蚑蚖蚘蚚蚜蚡蚦蚧蚨蚭蚱蚳蚴蚵蚷蚸蚹蚿蛀蛁蛃蛅蛑蛒蛕蛗蛚蛜蛠蛣蛥蛧蚈蛺蛼蛽蜄蜅蜇蜋蜎蜏蜐蜓蜔蜙蜞蜟蜡蜣\"],[\"8fdba1\",\"蜨蜮蜯蜱蜲蜹蜺蜼蜽蜾蝀蝃蝅蝍蝘蝝蝡蝤蝥蝯蝱蝲蝻螃\",6,\"螋螌螐螓螕螗螘螙螞螠螣螧螬螭螮螱螵螾螿蟁蟈蟉蟊蟎蟕蟖蟙蟚蟜蟟蟢蟣蟤蟪蟫蟭蟱蟳蟸蟺蟿蠁蠃蠆蠉蠊蠋蠐蠙蠒蠓蠔蠘蠚蠛蠜蠞蠟蠨蠭蠮蠰蠲蠵\"],[\"8fdca1\",\"蠺蠼衁衃衅衈衉衊衋衎衑衕衖衘衚衜衟衠衤衩衱衹衻袀袘袚袛袜袟袠袨袪袺袽袾裀裊\",4,\"裑裒裓裛裞裧裯裰裱裵裷褁褆褍褎褏褕褖褘褙褚褜褠褦褧褨褰褱褲褵褹褺褾襀襂襅襆襉襏襒襗襚襛襜襡襢襣襫襮襰襳襵襺\"],[\"8fdda1\",\"襻襼襽覉覍覐覔覕覛覜覟覠覥覰覴覵覶覷覼觔\",4,\"觥觩觫觭觱觳觶觹觽觿訄訅訇訏訑訒訔訕訞訠訢訤訦訫訬訯訵訷訽訾詀詃詅詇詉詍詎詓詖詗詘詜詝詡詥詧詵詶詷詹詺詻詾詿誀誃誆誋誏誐誒誖誗誙誟誧誩誮誯誳\"],[\"8fdea1\",\"誶誷誻誾諃諆諈諉諊諑諓諔諕諗諝諟諬諰諴諵諶諼諿謅謆謋謑謜謞謟謊謭謰謷謼譂\",4,\"譈譒譓譔譙譍譞譣譭譶譸譹譼譾讁讄讅讋讍讏讔讕讜讞讟谸谹谽谾豅豇豉豋豏豑豓豔豗豘豛豝豙豣豤豦豨豩豭豳豵豶豻豾貆\"],[\"8fdfa1\",\"貇貋貐貒貓貙貛貜貤貹貺賅賆賉賋賏賖賕賙賝賡賨賬賯賰賲賵賷賸賾賿贁贃贉贒贗贛赥赩赬赮赿趂趄趈趍趐趑趕趞趟趠趦趫趬趯趲趵趷趹趻跀跅跆跇跈跊跎跑跔跕跗跙跤跥跧跬跰趼跱跲跴跽踁踄踅踆踋踑踔踖踠踡踢\"],[\"8fe0a1\",\"踣踦踧踱踳踶踷踸踹踽蹀蹁蹋蹍蹎蹏蹔蹛蹜蹝蹞蹡蹢蹩蹬蹭蹯蹰蹱蹹蹺蹻躂躃躉躐躒躕躚躛躝躞躢躧躩躭躮躳躵躺躻軀軁軃軄軇軏軑軔軜軨軮軰軱軷軹軺軭輀輂輇輈輏輐輖輗輘輞輠輡輣輥輧輨輬輭輮輴輵輶輷輺轀轁\"],[\"8fe1a1\",\"轃轇轏轑\",4,\"轘轝轞轥辝辠辡辤辥辦辵辶辸达迀迁迆迊迋迍运迒迓迕迠迣迤迨迮迱迵迶迻迾适逄逈逌逘逛逨逩逯逪逬逭逳逴逷逿遃遄遌遛遝遢遦遧遬遰遴遹邅邈邋邌邎邐邕邗邘邙邛邠邡邢邥邰邲邳邴邶邽郌邾郃\"],[\"8fe2a1\",\"郄郅郇郈郕郗郘郙郜郝郟郥郒郶郫郯郰郴郾郿鄀鄄鄅鄆鄈鄍鄐鄔鄖鄗鄘鄚鄜鄞鄠鄥鄢鄣鄧鄩鄮鄯鄱鄴鄶鄷鄹鄺鄼鄽酃酇酈酏酓酗酙酚酛酡酤酧酭酴酹酺酻醁醃醅醆醊醎醑醓醔醕醘醞醡醦醨醬醭醮醰醱醲醳醶醻醼醽醿\"],[\"8fe3a1\",\"釂釃釅釓釔釗釙釚釞釤釥釩釪釬\",5,\"釷釹釻釽鈀鈁鈄鈅鈆鈇鈉鈊鈌鈐鈒鈓鈖鈘鈜鈝鈣鈤鈥鈦鈨鈮鈯鈰鈳鈵鈶鈸鈹鈺鈼鈾鉀鉂鉃鉆鉇鉊鉍鉎鉏鉑鉘鉙鉜鉝鉠鉡鉥鉧鉨鉩鉮鉯鉰鉵\",4,\"鉻鉼鉽鉿銈銉銊銍銎銒銗\"],[\"8fe4a1\",\"銙銟銠銤銥銧銨銫銯銲銶銸銺銻銼銽銿\",4,\"鋅鋆鋇鋈鋋鋌鋍鋎鋐鋓鋕鋗鋘鋙鋜鋝鋟鋠鋡鋣鋥鋧鋨鋬鋮鋰鋹鋻鋿錀錂錈錍錑錔錕錜錝錞錟錡錤錥錧錩錪錳錴錶錷鍇鍈鍉鍐鍑鍒鍕鍗鍘鍚鍞鍤鍥鍧鍩鍪鍭鍯鍰鍱鍳鍴鍶\"],[\"8fe5a1\",\"鍺鍽鍿鎀鎁鎂鎈鎊鎋鎍鎏鎒鎕鎘鎛鎞鎡鎣鎤鎦鎨鎫鎴鎵鎶鎺鎩鏁鏄鏅鏆鏇鏉\",4,\"鏓鏙鏜鏞鏟鏢鏦鏧鏹鏷鏸鏺鏻鏽鐁鐂鐄鐈鐉鐍鐎鐏鐕鐖鐗鐟鐮鐯鐱鐲鐳鐴鐻鐿鐽鑃鑅鑈鑊鑌鑕鑙鑜鑟鑡鑣鑨鑫鑭鑮鑯鑱鑲钄钃镸镹\"],[\"8fe6a1\",\"镾閄閈閌閍閎閝閞閟閡閦閩閫閬閴閶閺閽閿闆闈闉闋闐闑闒闓闙闚闝闞闟闠闤闦阝阞阢阤阥阦阬阱阳阷阸阹阺阼阽陁陒陔陖陗陘陡陮陴陻陼陾陿隁隂隃隄隉隑隖隚隝隟隤隥隦隩隮隯隳隺雊雒嶲雘雚雝雞雟雩雯雱雺霂\"],[\"8fe7a1\",\"霃霅霉霚霛霝霡霢霣霨霱霳靁靃靊靎靏靕靗靘靚靛靣靧靪靮靳靶靷靸靻靽靿鞀鞉鞕鞖鞗鞙鞚鞞鞟鞢鞬鞮鞱鞲鞵鞶鞸鞹鞺鞼鞾鞿韁韄韅韇韉韊韌韍韎韐韑韔韗韘韙韝韞韠韛韡韤韯韱韴韷韸韺頇頊頙頍頎頔頖頜頞頠頣頦\"],[\"8fe8a1\",\"頫頮頯頰頲頳頵頥頾顄顇顊顑顒顓顖顗顙顚顢顣顥顦顪顬颫颭颮颰颴颷颸颺颻颿飂飅飈飌飡飣飥飦飧飪飳飶餂餇餈餑餕餖餗餚餛餜餟餢餦餧餫餱\",4,\"餹餺餻餼饀饁饆饇饈饍饎饔饘饙饛饜饞饟饠馛馝馟馦馰馱馲馵\"],[\"8fe9a1\",\"馹馺馽馿駃駉駓駔駙駚駜駞駧駪駫駬駰駴駵駹駽駾騂騃騄騋騌騐騑騖騞騠騢騣騤騧騭騮騳騵騶騸驇驁驄驊驋驌驎驑驔驖驝骪骬骮骯骲骴骵骶骹骻骾骿髁髃髆髈髎髐髒髕髖髗髛髜髠髤髥髧髩髬髲髳髵髹髺髽髿\",4],[\"8feaa1\",\"鬄鬅鬈鬉鬋鬌鬍鬎鬐鬒鬖鬙鬛鬜鬠鬦鬫鬭鬳鬴鬵鬷鬹鬺鬽魈魋魌魕魖魗魛魞魡魣魥魦魨魪\",4,\"魳魵魷魸魹魿鮀鮄鮅鮆鮇鮉鮊鮋鮍鮏鮐鮔鮚鮝鮞鮦鮧鮩鮬鮰鮱鮲鮷鮸鮻鮼鮾鮿鯁鯇鯈鯎鯐鯗鯘鯝鯟鯥鯧鯪鯫鯯鯳鯷鯸\"],[\"8feba1\",\"鯹鯺鯽鯿鰀鰂鰋鰏鰑鰖鰘鰙鰚鰜鰞鰢鰣鰦\",4,\"鰱鰵鰶鰷鰽鱁鱃鱄鱅鱉鱊鱎鱏鱐鱓鱔鱖鱘鱛鱝鱞鱟鱣鱩鱪鱜鱫鱨鱮鱰鱲鱵鱷鱻鳦鳲鳷鳹鴋鴂鴑鴗鴘鴜鴝鴞鴯鴰鴲鴳鴴鴺鴼鵅鴽鵂鵃鵇鵊鵓鵔鵟鵣鵢鵥鵩鵪鵫鵰鵶鵷鵻\"],[\"8feca1\",\"鵼鵾鶃鶄鶆鶊鶍鶎鶒鶓鶕鶖鶗鶘鶡鶪鶬鶮鶱鶵鶹鶼鶿鷃鷇鷉鷊鷔鷕鷖鷗鷚鷞鷟鷠鷥鷧鷩鷫鷮鷰鷳鷴鷾鸊鸂鸇鸎鸐鸑鸒鸕鸖鸙鸜鸝鹺鹻鹼麀麂麃麄麅麇麎麏麖麘麛麞麤麨麬麮麯麰麳麴麵黆黈黋黕黟黤黧黬黭黮黰黱黲黵\"],[\"8feda1\",\"黸黿鼂鼃鼉鼏鼐鼑鼒鼔鼖鼗鼙鼚鼛鼟鼢鼦鼪鼫鼯鼱鼲鼴鼷鼹鼺鼼鼽鼿齁齃\",4,\"齓齕齖齗齘齚齝齞齨齩齭\",4,\"齳齵齺齽龏龐龑龒龔龖龗龞龡龢龣龥\"]]");

/***/ }),
/* 431 */
/***/ (function(module) {

module.exports = JSON.parse("{\"uChars\":[128,165,169,178,184,216,226,235,238,244,248,251,253,258,276,284,300,325,329,334,364,463,465,467,469,471,473,475,477,506,594,610,712,716,730,930,938,962,970,1026,1104,1106,8209,8215,8218,8222,8231,8241,8244,8246,8252,8365,8452,8454,8458,8471,8482,8556,8570,8596,8602,8713,8720,8722,8726,8731,8737,8740,8742,8748,8751,8760,8766,8777,8781,8787,8802,8808,8816,8854,8858,8870,8896,8979,9322,9372,9548,9588,9616,9622,9634,9652,9662,9672,9676,9680,9702,9735,9738,9793,9795,11906,11909,11913,11917,11928,11944,11947,11951,11956,11960,11964,11979,12284,12292,12312,12319,12330,12351,12436,12447,12535,12543,12586,12842,12850,12964,13200,13215,13218,13253,13263,13267,13270,13384,13428,13727,13839,13851,14617,14703,14801,14816,14964,15183,15471,15585,16471,16736,17208,17325,17330,17374,17623,17997,18018,18212,18218,18301,18318,18760,18811,18814,18820,18823,18844,18848,18872,19576,19620,19738,19887,40870,59244,59336,59367,59413,59417,59423,59431,59437,59443,59452,59460,59478,59493,63789,63866,63894,63976,63986,64016,64018,64021,64025,64034,64037,64042,65074,65093,65107,65112,65127,65132,65375,65510,65536],\"gbChars\":[0,36,38,45,50,81,89,95,96,100,103,104,105,109,126,133,148,172,175,179,208,306,307,308,309,310,311,312,313,341,428,443,544,545,558,741,742,749,750,805,819,820,7922,7924,7925,7927,7934,7943,7944,7945,7950,8062,8148,8149,8152,8164,8174,8236,8240,8262,8264,8374,8380,8381,8384,8388,8390,8392,8393,8394,8396,8401,8406,8416,8419,8424,8437,8439,8445,8482,8485,8496,8521,8603,8936,8946,9046,9050,9063,9066,9076,9092,9100,9108,9111,9113,9131,9162,9164,9218,9219,11329,11331,11334,11336,11346,11361,11363,11366,11370,11372,11375,11389,11682,11686,11687,11692,11694,11714,11716,11723,11725,11730,11736,11982,11989,12102,12336,12348,12350,12384,12393,12395,12397,12510,12553,12851,12962,12973,13738,13823,13919,13933,14080,14298,14585,14698,15583,15847,16318,16434,16438,16481,16729,17102,17122,17315,17320,17402,17418,17859,17909,17911,17915,17916,17936,17939,17961,18664,18703,18814,18962,19043,33469,33470,33471,33484,33485,33490,33497,33501,33505,33513,33520,33536,33550,37845,37921,37948,38029,38038,38064,38065,38066,38069,38075,38076,38078,39108,39109,39113,39114,39115,39116,39265,39394,189000]}");

/***/ }),
/* 432 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"0\",\"\\u0000\",127],[\"8141\",\"갂갃갅갆갋\",4,\"갘갞갟갡갢갣갥\",6,\"갮갲갳갴\"],[\"8161\",\"갵갶갷갺갻갽갾갿걁\",9,\"걌걎\",5,\"걕\"],[\"8181\",\"걖걗걙걚걛걝\",18,\"걲걳걵걶걹걻\",4,\"겂겇겈겍겎겏겑겒겓겕\",6,\"겞겢\",5,\"겫겭겮겱\",6,\"겺겾겿곀곂곃곅곆곇곉곊곋곍\",7,\"곖곘\",7,\"곢곣곥곦곩곫곭곮곲곴곷\",4,\"곾곿괁괂괃괅괇\",4,\"괎괐괒괓\"],[\"8241\",\"괔괕괖괗괙괚괛괝괞괟괡\",7,\"괪괫괮\",5],[\"8261\",\"괶괷괹괺괻괽\",6,\"굆굈굊\",5,\"굑굒굓굕굖굗\"],[\"8281\",\"굙\",7,\"굢굤\",7,\"굮굯굱굲굷굸굹굺굾궀궃\",4,\"궊궋궍궎궏궑\",10,\"궞\",5,\"궥\",17,\"궸\",7,\"귂귃귅귆귇귉\",6,\"귒귔\",7,\"귝귞귟귡귢귣귥\",18],[\"8341\",\"귺귻귽귾긂\",5,\"긊긌긎\",5,\"긕\",7],[\"8361\",\"긝\",18,\"긲긳긵긶긹긻긼\"],[\"8381\",\"긽긾긿깂깄깇깈깉깋깏깑깒깓깕깗\",4,\"깞깢깣깤깦깧깪깫깭깮깯깱\",6,\"깺깾\",5,\"꺆\",5,\"꺍\",46,\"꺿껁껂껃껅\",6,\"껎껒\",5,\"껚껛껝\",8],[\"8441\",\"껦껧껩껪껬껮\",5,\"껵껶껷껹껺껻껽\",8],[\"8461\",\"꼆꼉꼊꼋꼌꼎꼏꼑\",18],[\"8481\",\"꼤\",7,\"꼮꼯꼱꼳꼵\",6,\"꼾꽀꽄꽅꽆꽇꽊\",5,\"꽑\",10,\"꽞\",5,\"꽦\",18,\"꽺\",5,\"꾁꾂꾃꾅꾆꾇꾉\",6,\"꾒꾓꾔꾖\",5,\"꾝\",26,\"꾺꾻꾽꾾\"],[\"8541\",\"꾿꿁\",5,\"꿊꿌꿏\",4,\"꿕\",6,\"꿝\",4],[\"8561\",\"꿢\",5,\"꿪\",5,\"꿲꿳꿵꿶꿷꿹\",6,\"뀂뀃\"],[\"8581\",\"뀅\",6,\"뀍뀎뀏뀑뀒뀓뀕\",6,\"뀞\",9,\"뀩\",26,\"끆끇끉끋끍끏끐끑끒끖끘끚끛끜끞\",29,\"끾끿낁낂낃낅\",6,\"낎낐낒\",5,\"낛낝낞낣낤\"],[\"8641\",\"낥낦낧낪낰낲낶낷낹낺낻낽\",6,\"냆냊\",5,\"냒\"],[\"8661\",\"냓냕냖냗냙\",6,\"냡냢냣냤냦\",10],[\"8681\",\"냱\",22,\"넊넍넎넏넑넔넕넖넗넚넞\",4,\"넦넧넩넪넫넭\",6,\"넶넺\",5,\"녂녃녅녆녇녉\",6,\"녒녓녖녗녙녚녛녝녞녟녡\",22,\"녺녻녽녾녿놁놃\",4,\"놊놌놎놏놐놑놕놖놗놙놚놛놝\"],[\"8741\",\"놞\",9,\"놩\",15],[\"8761\",\"놹\",18,\"뇍뇎뇏뇑뇒뇓뇕\"],[\"8781\",\"뇖\",5,\"뇞뇠\",7,\"뇪뇫뇭뇮뇯뇱\",7,\"뇺뇼뇾\",5,\"눆눇눉눊눍\",6,\"눖눘눚\",5,\"눡\",18,\"눵\",6,\"눽\",26,\"뉙뉚뉛뉝뉞뉟뉡\",6,\"뉪\",4],[\"8841\",\"뉯\",4,\"뉶\",5,\"뉽\",6,\"늆늇늈늊\",4],[\"8861\",\"늏늒늓늕늖늗늛\",4,\"늢늤늧늨늩늫늭늮늯늱늲늳늵늶늷\"],[\"8881\",\"늸\",15,\"닊닋닍닎닏닑닓\",4,\"닚닜닞닟닠닡닣닧닩닪닰닱닲닶닼닽닾댂댃댅댆댇댉\",6,\"댒댖\",5,\"댝\",54,\"덗덙덚덝덠덡덢덣\"],[\"8941\",\"덦덨덪덬덭덯덲덳덵덶덷덹\",6,\"뎂뎆\",5,\"뎍\"],[\"8961\",\"뎎뎏뎑뎒뎓뎕\",10,\"뎢\",5,\"뎩뎪뎫뎭\"],[\"8981\",\"뎮\",21,\"돆돇돉돊돍돏돑돒돓돖돘돚돜돞돟돡돢돣돥돦돧돩\",18,\"돽\",18,\"됑\",6,\"됙됚됛됝됞됟됡\",6,\"됪됬\",7,\"됵\",15],[\"8a41\",\"둅\",10,\"둒둓둕둖둗둙\",6,\"둢둤둦\"],[\"8a61\",\"둧\",4,\"둭\",18,\"뒁뒂\"],[\"8a81\",\"뒃\",4,\"뒉\",19,\"뒞\",5,\"뒥뒦뒧뒩뒪뒫뒭\",7,\"뒶뒸뒺\",5,\"듁듂듃듅듆듇듉\",6,\"듑듒듓듔듖\",5,\"듞듟듡듢듥듧\",4,\"듮듰듲\",5,\"듹\",26,\"딖딗딙딚딝\"],[\"8b41\",\"딞\",5,\"딦딫\",4,\"딲딳딵딶딷딹\",6,\"땂땆\"],[\"8b61\",\"땇땈땉땊땎땏땑땒땓땕\",6,\"땞땢\",8],[\"8b81\",\"땫\",52,\"떢떣떥떦떧떩떬떭떮떯떲떶\",4,\"떾떿뗁뗂뗃뗅\",6,\"뗎뗒\",5,\"뗙\",18,\"뗭\",18],[\"8c41\",\"똀\",15,\"똒똓똕똖똗똙\",4],[\"8c61\",\"똞\",6,\"똦\",5,\"똭\",6,\"똵\",5],[\"8c81\",\"똻\",12,\"뙉\",26,\"뙥뙦뙧뙩\",50,\"뚞뚟뚡뚢뚣뚥\",5,\"뚭뚮뚯뚰뚲\",16],[\"8d41\",\"뛃\",16,\"뛕\",8],[\"8d61\",\"뛞\",17,\"뛱뛲뛳뛵뛶뛷뛹뛺\"],[\"8d81\",\"뛻\",4,\"뜂뜃뜄뜆\",33,\"뜪뜫뜭뜮뜱\",6,\"뜺뜼\",7,\"띅띆띇띉띊띋띍\",6,\"띖\",9,\"띡띢띣띥띦띧띩\",6,\"띲띴띶\",5,\"띾띿랁랂랃랅\",6,\"랎랓랔랕랚랛랝랞\"],[\"8e41\",\"랟랡\",6,\"랪랮\",5,\"랶랷랹\",8],[\"8e61\",\"럂\",4,\"럈럊\",19],[\"8e81\",\"럞\",13,\"럮럯럱럲럳럵\",6,\"럾렂\",4,\"렊렋렍렎렏렑\",6,\"렚렜렞\",5,\"렦렧렩렪렫렭\",6,\"렶렺\",5,\"롁롂롃롅\",11,\"롒롔\",7,\"롞롟롡롢롣롥\",6,\"롮롰롲\",5,\"롹롺롻롽\",7],[\"8f41\",\"뢅\",7,\"뢎\",17],[\"8f61\",\"뢠\",7,\"뢩\",6,\"뢱뢲뢳뢵뢶뢷뢹\",4],[\"8f81\",\"뢾뢿룂룄룆\",5,\"룍룎룏룑룒룓룕\",7,\"룞룠룢\",5,\"룪룫룭룮룯룱\",6,\"룺룼룾\",5,\"뤅\",18,\"뤙\",6,\"뤡\",26,\"뤾뤿륁륂륃륅\",6,\"륍륎륐륒\",5],[\"9041\",\"륚륛륝륞륟륡\",6,\"륪륬륮\",5,\"륶륷륹륺륻륽\"],[\"9061\",\"륾\",5,\"릆릈릋릌릏\",15],[\"9081\",\"릟\",12,\"릮릯릱릲릳릵\",6,\"릾맀맂\",5,\"맊맋맍맓\",4,\"맚맜맟맠맢맦맧맩맪맫맭\",6,\"맶맻\",4,\"먂\",5,\"먉\",11,\"먖\",33,\"먺먻먽먾먿멁멃멄멅멆\"],[\"9141\",\"멇멊멌멏멐멑멒멖멗멙멚멛멝\",6,\"멦멪\",5],[\"9161\",\"멲멳멵멶멷멹\",9,\"몆몈몉몊몋몍\",5],[\"9181\",\"몓\",20,\"몪몭몮몯몱몳\",4,\"몺몼몾\",5,\"뫅뫆뫇뫉\",14,\"뫚\",33,\"뫽뫾뫿묁묂묃묅\",7,\"묎묐묒\",5,\"묙묚묛묝묞묟묡\",6],[\"9241\",\"묨묪묬\",7,\"묷묹묺묿\",4,\"뭆뭈뭊뭋뭌뭎뭑뭒\"],[\"9261\",\"뭓뭕뭖뭗뭙\",7,\"뭢뭤\",7,\"뭭\",4],[\"9281\",\"뭲\",21,\"뮉뮊뮋뮍뮎뮏뮑\",18,\"뮥뮦뮧뮩뮪뮫뮭\",6,\"뮵뮶뮸\",7,\"믁믂믃믅믆믇믉\",6,\"믑믒믔\",35,\"믺믻믽믾밁\"],[\"9341\",\"밃\",4,\"밊밎밐밒밓밙밚밠밡밢밣밦밨밪밫밬밮밯밲밳밵\"],[\"9361\",\"밶밷밹\",6,\"뱂뱆뱇뱈뱊뱋뱎뱏뱑\",8],[\"9381\",\"뱚뱛뱜뱞\",37,\"벆벇벉벊벍벏\",4,\"벖벘벛\",4,\"벢벣벥벦벩\",6,\"벲벶\",5,\"벾벿볁볂볃볅\",7,\"볎볒볓볔볖볗볙볚볛볝\",22,\"볷볹볺볻볽\"],[\"9441\",\"볾\",5,\"봆봈봊\",5,\"봑봒봓봕\",8],[\"9461\",\"봞\",5,\"봥\",6,\"봭\",12],[\"9481\",\"봺\",5,\"뵁\",6,\"뵊뵋뵍뵎뵏뵑\",6,\"뵚\",9,\"뵥뵦뵧뵩\",22,\"붂붃붅붆붋\",4,\"붒붔붖붗붘붛붝\",6,\"붥\",10,\"붱\",6,\"붹\",24],[\"9541\",\"뷒뷓뷖뷗뷙뷚뷛뷝\",11,\"뷪\",5,\"뷱\"],[\"9561\",\"뷲뷳뷵뷶뷷뷹\",6,\"븁븂븄븆\",5,\"븎븏븑븒븓\"],[\"9581\",\"븕\",6,\"븞븠\",35,\"빆빇빉빊빋빍빏\",4,\"빖빘빜빝빞빟빢빣빥빦빧빩빫\",4,\"빲빶\",4,\"빾빿뺁뺂뺃뺅\",6,\"뺎뺒\",5,\"뺚\",13,\"뺩\",14],[\"9641\",\"뺸\",23,\"뻒뻓\"],[\"9661\",\"뻕뻖뻙\",6,\"뻡뻢뻦\",5,\"뻭\",8],[\"9681\",\"뻶\",10,\"뼂\",5,\"뼊\",13,\"뼚뼞\",33,\"뽂뽃뽅뽆뽇뽉\",6,\"뽒뽓뽔뽖\",44],[\"9741\",\"뾃\",16,\"뾕\",8],[\"9761\",\"뾞\",17,\"뾱\",7],[\"9781\",\"뾹\",11,\"뿆\",5,\"뿎뿏뿑뿒뿓뿕\",6,\"뿝뿞뿠뿢\",89,\"쀽쀾쀿\"],[\"9841\",\"쁀\",16,\"쁒\",5,\"쁙쁚쁛\"],[\"9861\",\"쁝쁞쁟쁡\",6,\"쁪\",15],[\"9881\",\"쁺\",21,\"삒삓삕삖삗삙\",6,\"삢삤삦\",5,\"삮삱삲삷\",4,\"삾샂샃샄샆샇샊샋샍샎샏샑\",6,\"샚샞\",5,\"샦샧샩샪샫샭\",6,\"샶샸샺\",5,\"섁섂섃섅섆섇섉\",6,\"섑섒섓섔섖\",5,\"섡섢섥섨섩섪섫섮\"],[\"9941\",\"섲섳섴섵섷섺섻섽섾섿셁\",6,\"셊셎\",5,\"셖셗\"],[\"9961\",\"셙셚셛셝\",6,\"셦셪\",5,\"셱셲셳셵셶셷셹셺셻\"],[\"9981\",\"셼\",8,\"솆\",5,\"솏솑솒솓솕솗\",4,\"솞솠솢솣솤솦솧솪솫솭솮솯솱\",11,\"솾\",5,\"쇅쇆쇇쇉쇊쇋쇍\",6,\"쇕쇖쇙\",6,\"쇡쇢쇣쇥쇦쇧쇩\",6,\"쇲쇴\",7,\"쇾쇿숁숂숃숅\",6,\"숎숐숒\",5,\"숚숛숝숞숡숢숣\"],[\"9a41\",\"숤숥숦숧숪숬숮숰숳숵\",16],[\"9a61\",\"쉆쉇쉉\",6,\"쉒쉓쉕쉖쉗쉙\",6,\"쉡쉢쉣쉤쉦\"],[\"9a81\",\"쉧\",4,\"쉮쉯쉱쉲쉳쉵\",6,\"쉾슀슂\",5,\"슊\",5,\"슑\",6,\"슙슚슜슞\",5,\"슦슧슩슪슫슮\",5,\"슶슸슺\",33,\"싞싟싡싢싥\",5,\"싮싰싲싳싴싵싷싺싽싾싿쌁\",6,\"쌊쌋쌎쌏\"],[\"9b41\",\"쌐쌑쌒쌖쌗쌙쌚쌛쌝\",6,\"쌦쌧쌪\",8],[\"9b61\",\"쌳\",17,\"썆\",7],[\"9b81\",\"썎\",25,\"썪썫썭썮썯썱썳\",4,\"썺썻썾\",5,\"쎅쎆쎇쎉쎊쎋쎍\",50,\"쏁\",22,\"쏚\"],[\"9c41\",\"쏛쏝쏞쏡쏣\",4,\"쏪쏫쏬쏮\",5,\"쏶쏷쏹\",5],[\"9c61\",\"쏿\",8,\"쐉\",6,\"쐑\",9],[\"9c81\",\"쐛\",8,\"쐥\",6,\"쐭쐮쐯쐱쐲쐳쐵\",6,\"쐾\",9,\"쑉\",26,\"쑦쑧쑩쑪쑫쑭\",6,\"쑶쑷쑸쑺\",5,\"쒁\",18,\"쒕\",6,\"쒝\",12],[\"9d41\",\"쒪\",13,\"쒹쒺쒻쒽\",8],[\"9d61\",\"쓆\",25],[\"9d81\",\"쓠\",8,\"쓪\",5,\"쓲쓳쓵쓶쓷쓹쓻쓼쓽쓾씂\",9,\"씍씎씏씑씒씓씕\",6,\"씝\",10,\"씪씫씭씮씯씱\",6,\"씺씼씾\",5,\"앆앇앋앏앐앑앒앖앚앛앜앟앢앣앥앦앧앩\",6,\"앲앶\",5,\"앾앿얁얂얃얅얆얈얉얊얋얎얐얒얓얔\"],[\"9e41\",\"얖얙얚얛얝얞얟얡\",7,\"얪\",9,\"얶\"],[\"9e61\",\"얷얺얿\",4,\"엋엍엏엒엓엕엖엗엙\",6,\"엢엤엦엧\"],[\"9e81\",\"엨엩엪엫엯엱엲엳엵엸엹엺엻옂옃옄옉옊옋옍옎옏옑\",6,\"옚옝\",6,\"옦옧옩옪옫옯옱옲옶옸옺옼옽옾옿왂왃왅왆왇왉\",6,\"왒왖\",5,\"왞왟왡\",10,\"왭왮왰왲\",5,\"왺왻왽왾왿욁\",6,\"욊욌욎\",5,\"욖욗욙욚욛욝\",6,\"욦\"],[\"9f41\",\"욨욪\",5,\"욲욳욵욶욷욻\",4,\"웂웄웆\",5,\"웎\"],[\"9f61\",\"웏웑웒웓웕\",6,\"웞웟웢\",5,\"웪웫웭웮웯웱웲\"],[\"9f81\",\"웳\",4,\"웺웻웼웾\",5,\"윆윇윉윊윋윍\",6,\"윖윘윚\",5,\"윢윣윥윦윧윩\",6,\"윲윴윶윸윹윺윻윾윿읁읂읃읅\",4,\"읋읎읐읙읚읛읝읞읟읡\",6,\"읩읪읬\",7,\"읶읷읹읺읻읿잀잁잂잆잋잌잍잏잒잓잕잙잛\",4,\"잢잧\",4,\"잮잯잱잲잳잵잶잷\"],[\"a041\",\"잸잹잺잻잾쟂\",5,\"쟊쟋쟍쟏쟑\",6,\"쟙쟚쟛쟜\"],[\"a061\",\"쟞\",5,\"쟥쟦쟧쟩쟪쟫쟭\",13],[\"a081\",\"쟻\",4,\"젂젃젅젆젇젉젋\",4,\"젒젔젗\",4,\"젞젟젡젢젣젥\",6,\"젮젰젲\",5,\"젹젺젻젽젾젿졁\",6,\"졊졋졎\",5,\"졕\",26,\"졲졳졵졶졷졹졻\",4,\"좂좄좈좉좊좎\",5,\"좕\",7,\"좞좠좢좣좤\"],[\"a141\",\"좥좦좧좩\",18,\"좾좿죀죁\"],[\"a161\",\"죂죃죅죆죇죉죊죋죍\",6,\"죖죘죚\",5,\"죢죣죥\"],[\"a181\",\"죦\",14,\"죶\",5,\"죾죿줁줂줃줇\",4,\"줎　、。·‥…¨〃­―∥＼∼‘’“”〔〕〈\",9,\"±×÷≠≤≥∞∴°′″℃Å￠￡￥♂♀∠⊥⌒∂∇≡≒§※☆★○●◎◇◆□■△▲▽▼→←↑↓↔〓≪≫√∽∝∵∫∬∈∋⊆⊇⊂⊃∪∩∧∨￢\"],[\"a241\",\"줐줒\",5,\"줙\",18],[\"a261\",\"줭\",6,\"줵\",18],[\"a281\",\"쥈\",7,\"쥒쥓쥕쥖쥗쥙\",6,\"쥢쥤\",7,\"쥭쥮쥯⇒⇔∀∃´～ˇ˘˝˚˙¸˛¡¿ː∮∑∏¤℉‰◁◀▷▶♤♠♡♥♧♣⊙◈▣◐◑▒▤▥▨▧▦▩♨☏☎☜☞¶†‡↕↗↙↖↘♭♩♪♬㉿㈜№㏇™㏂㏘℡€®\"],[\"a341\",\"쥱쥲쥳쥵\",6,\"쥽\",10,\"즊즋즍즎즏\"],[\"a361\",\"즑\",6,\"즚즜즞\",16],[\"a381\",\"즯\",16,\"짂짃짅짆짉짋\",4,\"짒짔짗짘짛！\",58,\"￦］\",32,\"￣\"],[\"a441\",\"짞짟짡짣짥짦짨짩짪짫짮짲\",5,\"짺짻짽짾짿쨁쨂쨃쨄\"],[\"a461\",\"쨅쨆쨇쨊쨎\",5,\"쨕쨖쨗쨙\",12],[\"a481\",\"쨦쨧쨨쨪\",28,\"ㄱ\",93],[\"a541\",\"쩇\",4,\"쩎쩏쩑쩒쩓쩕\",6,\"쩞쩢\",5,\"쩩쩪\"],[\"a561\",\"쩫\",17,\"쩾\",5,\"쪅쪆\"],[\"a581\",\"쪇\",16,\"쪙\",14,\"ⅰ\",9],[\"a5b0\",\"Ⅰ\",9],[\"a5c1\",\"Α\",16,\"Σ\",6],[\"a5e1\",\"α\",16,\"σ\",6],[\"a641\",\"쪨\",19,\"쪾쪿쫁쫂쫃쫅\"],[\"a661\",\"쫆\",5,\"쫎쫐쫒쫔쫕쫖쫗쫚\",5,\"쫡\",6],[\"a681\",\"쫨쫩쫪쫫쫭\",6,\"쫵\",18,\"쬉쬊─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂┒┑┚┙┖┕┎┍┞┟┡┢┦┧┩┪┭┮┱┲┵┶┹┺┽┾╀╁╃\",7],[\"a741\",\"쬋\",4,\"쬑쬒쬓쬕쬖쬗쬙\",6,\"쬢\",7],[\"a761\",\"쬪\",22,\"쭂쭃쭄\"],[\"a781\",\"쭅쭆쭇쭊쭋쭍쭎쭏쭑\",6,\"쭚쭛쭜쭞\",5,\"쭥\",7,\"㎕㎖㎗ℓ㎘㏄㎣㎤㎥㎦㎙\",9,\"㏊㎍㎎㎏㏏㎈㎉㏈㎧㎨㎰\",9,\"㎀\",4,\"㎺\",5,\"㎐\",4,\"Ω㏀㏁㎊㎋㎌㏖㏅㎭㎮㎯㏛㎩㎪㎫㎬㏝㏐㏓㏃㏉㏜㏆\"],[\"a841\",\"쭭\",10,\"쭺\",14],[\"a861\",\"쮉\",18,\"쮝\",6],[\"a881\",\"쮤\",19,\"쮹\",11,\"ÆÐªĦ\"],[\"a8a6\",\"Ĳ\"],[\"a8a8\",\"ĿŁØŒºÞŦŊ\"],[\"a8b1\",\"㉠\",27,\"ⓐ\",25,\"①\",14,\"½⅓⅔¼¾⅛⅜⅝⅞\"],[\"a941\",\"쯅\",14,\"쯕\",10],[\"a961\",\"쯠쯡쯢쯣쯥쯦쯨쯪\",18],[\"a981\",\"쯽\",14,\"찎찏찑찒찓찕\",6,\"찞찟찠찣찤æđðħıĳĸŀłøœßþŧŋŉ㈀\",27,\"⒜\",25,\"⑴\",14,\"¹²³⁴ⁿ₁₂₃₄\"],[\"aa41\",\"찥찦찪찫찭찯찱\",6,\"찺찿\",4,\"챆챇챉챊챋챍챎\"],[\"aa61\",\"챏\",4,\"챖챚\",5,\"챡챢챣챥챧챩\",6,\"챱챲\"],[\"aa81\",\"챳챴챶\",29,\"ぁ\",82],[\"ab41\",\"첔첕첖첗첚첛첝첞첟첡\",6,\"첪첮\",5,\"첶첷첹\"],[\"ab61\",\"첺첻첽\",6,\"쳆쳈쳊\",5,\"쳑쳒쳓쳕\",5],[\"ab81\",\"쳛\",8,\"쳥\",6,\"쳭쳮쳯쳱\",12,\"ァ\",85],[\"ac41\",\"쳾쳿촀촂\",5,\"촊촋촍촎촏촑\",6,\"촚촜촞촟촠\"],[\"ac61\",\"촡촢촣촥촦촧촩촪촫촭\",11,\"촺\",4],[\"ac81\",\"촿\",28,\"쵝쵞쵟А\",5,\"ЁЖ\",25],[\"acd1\",\"а\",5,\"ёж\",25],[\"ad41\",\"쵡쵢쵣쵥\",6,\"쵮쵰쵲\",5,\"쵹\",7],[\"ad61\",\"춁\",6,\"춉\",10,\"춖춗춙춚춛춝춞춟\"],[\"ad81\",\"춠춡춢춣춦춨춪\",5,\"춱\",18,\"췅\"],[\"ae41\",\"췆\",5,\"췍췎췏췑\",16],[\"ae61\",\"췢\",5,\"췩췪췫췭췮췯췱\",6,\"췺췼췾\",4],[\"ae81\",\"츃츅츆츇츉츊츋츍\",6,\"츕츖츗츘츚\",5,\"츢츣츥츦츧츩츪츫\"],[\"af41\",\"츬츭츮츯츲츴츶\",19],[\"af61\",\"칊\",13,\"칚칛칝칞칢\",5,\"칪칬\"],[\"af81\",\"칮\",5,\"칶칷칹칺칻칽\",6,\"캆캈캊\",5,\"캒캓캕캖캗캙\"],[\"b041\",\"캚\",5,\"캢캦\",5,\"캮\",12],[\"b061\",\"캻\",5,\"컂\",19],[\"b081\",\"컖\",13,\"컦컧컩컪컭\",6,\"컶컺\",5,\"가각간갇갈갉갊감\",7,\"같\",4,\"갠갤갬갭갯갰갱갸갹갼걀걋걍걔걘걜거걱건걷걸걺검겁것겄겅겆겉겊겋게겐겔겜겝겟겠겡겨격겪견겯결겸겹겻겼경곁계곈곌곕곗고곡곤곧골곪곬곯곰곱곳공곶과곽관괄괆\"],[\"b141\",\"켂켃켅켆켇켉\",6,\"켒켔켖\",5,\"켝켞켟켡켢켣\"],[\"b161\",\"켥\",6,\"켮켲\",5,\"켹\",11],[\"b181\",\"콅\",14,\"콖콗콙콚콛콝\",6,\"콦콨콪콫콬괌괍괏광괘괜괠괩괬괭괴괵괸괼굄굅굇굉교굔굘굡굣구국군굳굴굵굶굻굼굽굿궁궂궈궉권궐궜궝궤궷귀귁귄귈귐귑귓규균귤그극근귿글긁금급긋긍긔기긱긴긷길긺김깁깃깅깆깊까깍깎깐깔깖깜깝깟깠깡깥깨깩깬깰깸\"],[\"b241\",\"콭콮콯콲콳콵콶콷콹\",6,\"쾁쾂쾃쾄쾆\",5,\"쾍\"],[\"b261\",\"쾎\",18,\"쾢\",5,\"쾩\"],[\"b281\",\"쾪\",5,\"쾱\",18,\"쿅\",6,\"깹깻깼깽꺄꺅꺌꺼꺽꺾껀껄껌껍껏껐껑께껙껜껨껫껭껴껸껼꼇꼈꼍꼐꼬꼭꼰꼲꼴꼼꼽꼿꽁꽂꽃꽈꽉꽐꽜꽝꽤꽥꽹꾀꾄꾈꾐꾑꾕꾜꾸꾹꾼꿀꿇꿈꿉꿋꿍꿎꿔꿜꿨꿩꿰꿱꿴꿸뀀뀁뀄뀌뀐뀔뀜뀝뀨끄끅끈끊끌끎끓끔끕끗끙\"],[\"b341\",\"쿌\",19,\"쿢쿣쿥쿦쿧쿩\"],[\"b361\",\"쿪\",5,\"쿲쿴쿶\",5,\"쿽쿾쿿퀁퀂퀃퀅\",5],[\"b381\",\"퀋\",5,\"퀒\",5,\"퀙\",19,\"끝끼끽낀낄낌낍낏낑나낙낚난낟날낡낢남납낫\",4,\"낱낳내낵낸낼냄냅냇냈냉냐냑냔냘냠냥너넉넋넌널넒넓넘넙넛넜넝넣네넥넨넬넴넵넷넸넹녀녁년녈념녑녔녕녘녜녠노녹논놀놂놈놉놋농높놓놔놘놜놨뇌뇐뇔뇜뇝\"],[\"b441\",\"퀮\",5,\"퀶퀷퀹퀺퀻퀽\",6,\"큆큈큊\",5],[\"b461\",\"큑큒큓큕큖큗큙\",6,\"큡\",10,\"큮큯\"],[\"b481\",\"큱큲큳큵\",6,\"큾큿킀킂\",18,\"뇟뇨뇩뇬뇰뇹뇻뇽누눅눈눋눌눔눕눗눙눠눴눼뉘뉜뉠뉨뉩뉴뉵뉼늄늅늉느늑는늘늙늚늠늡늣능늦늪늬늰늴니닉닌닐닒님닙닛닝닢다닥닦단닫\",4,\"닳담답닷\",4,\"닿대댁댄댈댐댑댓댔댕댜더덕덖던덛덜덞덟덤덥\"],[\"b541\",\"킕\",14,\"킦킧킩킪킫킭\",5],[\"b561\",\"킳킶킸킺\",5,\"탂탃탅탆탇탊\",5,\"탒탖\",4],[\"b581\",\"탛탞탟탡탢탣탥\",6,\"탮탲\",5,\"탹\",11,\"덧덩덫덮데덱덴델뎀뎁뎃뎄뎅뎌뎐뎔뎠뎡뎨뎬도독돈돋돌돎돐돔돕돗동돛돝돠돤돨돼됐되된될됨됩됫됴두둑둔둘둠둡둣둥둬뒀뒈뒝뒤뒨뒬뒵뒷뒹듀듄듈듐듕드득든듣들듦듬듭듯등듸디딕딘딛딜딤딥딧딨딩딪따딱딴딸\"],[\"b641\",\"턅\",7,\"턎\",17],[\"b661\",\"턠\",15,\"턲턳턵턶턷턹턻턼턽턾\"],[\"b681\",\"턿텂텆\",5,\"텎텏텑텒텓텕\",6,\"텞텠텢\",5,\"텩텪텫텭땀땁땃땄땅땋때땍땐땔땜땝땟땠땡떠떡떤떨떪떫떰떱떳떴떵떻떼떽뗀뗄뗌뗍뗏뗐뗑뗘뗬또똑똔똘똥똬똴뙈뙤뙨뚜뚝뚠뚤뚫뚬뚱뛔뛰뛴뛸뜀뜁뜅뜨뜩뜬뜯뜰뜸뜹뜻띄띈띌띔띕띠띤띨띰띱띳띵라락란랄람랍랏랐랑랒랖랗\"],[\"b741\",\"텮\",13,\"텽\",6,\"톅톆톇톉톊\"],[\"b761\",\"톋\",20,\"톢톣톥톦톧\"],[\"b781\",\"톩\",6,\"톲톴톶톷톸톹톻톽톾톿퇁\",14,\"래랙랜랠램랩랫랬랭랴략랸럇량러럭런럴럼럽럿렀렁렇레렉렌렐렘렙렛렝려력련렬렴렵렷렸령례롄롑롓로록론롤롬롭롯롱롸롼뢍뢨뢰뢴뢸룀룁룃룅료룐룔룝룟룡루룩룬룰룸룹룻룽뤄뤘뤠뤼뤽륀륄륌륏륑류륙륜률륨륩\"],[\"b841\",\"퇐\",7,\"퇙\",17],[\"b861\",\"퇫\",8,\"퇵퇶퇷퇹\",13],[\"b881\",\"툈툊\",5,\"툑\",24,\"륫륭르륵른를름릅릇릉릊릍릎리릭린릴림립릿링마막만많\",4,\"맘맙맛망맞맡맣매맥맨맬맴맵맷맸맹맺먀먁먈먕머먹먼멀멂멈멉멋멍멎멓메멕멘멜멤멥멧멨멩며멱면멸몃몄명몇몌모목몫몬몰몲몸몹못몽뫄뫈뫘뫙뫼\"],[\"b941\",\"툪툫툮툯툱툲툳툵\",6,\"툾퉀퉂\",5,\"퉉퉊퉋퉌\"],[\"b961\",\"퉍\",14,\"퉝\",6,\"퉥퉦퉧퉨\"],[\"b981\",\"퉩\",22,\"튂튃튅튆튇튉튊튋튌묀묄묍묏묑묘묜묠묩묫무묵묶문묻물묽묾뭄뭅뭇뭉뭍뭏뭐뭔뭘뭡뭣뭬뮈뮌뮐뮤뮨뮬뮴뮷므믄믈믐믓미믹민믿밀밂밈밉밋밌밍및밑바\",4,\"받\",4,\"밤밥밧방밭배백밴밸뱀뱁뱃뱄뱅뱉뱌뱍뱐뱝버벅번벋벌벎범법벗\"],[\"ba41\",\"튍튎튏튒튓튔튖\",5,\"튝튞튟튡튢튣튥\",6,\"튭\"],[\"ba61\",\"튮튯튰튲\",5,\"튺튻튽튾틁틃\",4,\"틊틌\",5],[\"ba81\",\"틒틓틕틖틗틙틚틛틝\",6,\"틦\",9,\"틲틳틵틶틷틹틺벙벚베벡벤벧벨벰벱벳벴벵벼벽변별볍볏볐병볕볘볜보복볶본볼봄봅봇봉봐봔봤봬뵀뵈뵉뵌뵐뵘뵙뵤뵨부북분붇불붉붊붐붑붓붕붙붚붜붤붰붸뷔뷕뷘뷜뷩뷰뷴뷸븀븃븅브븍븐블븜븝븟비빅빈빌빎빔빕빗빙빚빛빠빡빤\"],[\"bb41\",\"틻\",4,\"팂팄팆\",5,\"팏팑팒팓팕팗\",4,\"팞팢팣\"],[\"bb61\",\"팤팦팧팪팫팭팮팯팱\",6,\"팺팾\",5,\"퍆퍇퍈퍉\"],[\"bb81\",\"퍊\",31,\"빨빪빰빱빳빴빵빻빼빽뺀뺄뺌뺍뺏뺐뺑뺘뺙뺨뻐뻑뻔뻗뻘뻠뻣뻤뻥뻬뼁뼈뼉뼘뼙뼛뼜뼝뽀뽁뽄뽈뽐뽑뽕뾔뾰뿅뿌뿍뿐뿔뿜뿟뿡쀼쁑쁘쁜쁠쁨쁩삐삑삔삘삠삡삣삥사삭삯산삳살삵삶삼삽삿샀상샅새색샌샐샘샙샛샜생샤\"],[\"bc41\",\"퍪\",17,\"퍾퍿펁펂펃펅펆펇\"],[\"bc61\",\"펈펉펊펋펎펒\",5,\"펚펛펝펞펟펡\",6,\"펪펬펮\"],[\"bc81\",\"펯\",4,\"펵펶펷펹펺펻펽\",6,\"폆폇폊\",5,\"폑\",5,\"샥샨샬샴샵샷샹섀섄섈섐섕서\",4,\"섣설섦섧섬섭섯섰성섶세섹센셀셈셉셋셌셍셔셕션셜셤셥셧셨셩셰셴셸솅소속솎손솔솖솜솝솟송솥솨솩솬솰솽쇄쇈쇌쇔쇗쇘쇠쇤쇨쇰쇱쇳쇼쇽숀숄숌숍숏숑수숙순숟술숨숩숫숭\"],[\"bd41\",\"폗폙\",7,\"폢폤\",7,\"폮폯폱폲폳폵폶폷\"],[\"bd61\",\"폸폹폺폻폾퐀퐂\",5,\"퐉\",13],[\"bd81\",\"퐗\",5,\"퐞\",25,\"숯숱숲숴쉈쉐쉑쉔쉘쉠쉥쉬쉭쉰쉴쉼쉽쉿슁슈슉슐슘슛슝스슥슨슬슭슴습슷승시식신싣실싫심십싯싱싶싸싹싻싼쌀쌈쌉쌌쌍쌓쌔쌕쌘쌜쌤쌥쌨쌩썅써썩썬썰썲썸썹썼썽쎄쎈쎌쏀쏘쏙쏜쏟쏠쏢쏨쏩쏭쏴쏵쏸쐈쐐쐤쐬쐰\"],[\"be41\",\"퐸\",7,\"푁푂푃푅\",14],[\"be61\",\"푔\",7,\"푝푞푟푡푢푣푥\",7,\"푮푰푱푲\"],[\"be81\",\"푳\",4,\"푺푻푽푾풁풃\",4,\"풊풌풎\",5,\"풕\",8,\"쐴쐼쐽쑈쑤쑥쑨쑬쑴쑵쑹쒀쒔쒜쒸쒼쓩쓰쓱쓴쓸쓺쓿씀씁씌씐씔씜씨씩씬씰씸씹씻씽아악안앉않알앍앎앓암압앗았앙앝앞애액앤앨앰앱앳앴앵야약얀얄얇얌얍얏양얕얗얘얜얠얩어억언얹얻얼얽얾엄\",6,\"엌엎\"],[\"bf41\",\"풞\",10,\"풪\",14],[\"bf61\",\"풹\",18,\"퓍퓎퓏퓑퓒퓓퓕\"],[\"bf81\",\"퓖\",5,\"퓝퓞퓠\",7,\"퓩퓪퓫퓭퓮퓯퓱\",6,\"퓹퓺퓼에엑엔엘엠엡엣엥여역엮연열엶엷염\",5,\"옅옆옇예옌옐옘옙옛옜오옥온올옭옮옰옳옴옵옷옹옻와왁완왈왐왑왓왔왕왜왝왠왬왯왱외왹왼욀욈욉욋욍요욕욘욜욤욥욧용우욱운울욹욺움웁웃웅워웍원월웜웝웠웡웨\"],[\"c041\",\"퓾\",5,\"픅픆픇픉픊픋픍\",6,\"픖픘\",5],[\"c061\",\"픞\",25],[\"c081\",\"픸픹픺픻픾픿핁핂핃핅\",6,\"핎핐핒\",5,\"핚핛핝핞핟핡핢핣웩웬웰웸웹웽위윅윈윌윔윕윗윙유육윤율윰윱윳융윷으윽은을읊음읍읏응\",7,\"읜읠읨읫이익인일읽읾잃임입잇있잉잊잎자작잔잖잗잘잚잠잡잣잤장잦재잭잰잴잼잽잿쟀쟁쟈쟉쟌쟎쟐쟘쟝쟤쟨쟬저적전절젊\"],[\"c141\",\"핤핦핧핪핬핮\",5,\"핶핷핹핺핻핽\",6,\"햆햊햋\"],[\"c161\",\"햌햍햎햏햑\",19,\"햦햧\"],[\"c181\",\"햨\",31,\"점접젓정젖제젝젠젤젬젭젯젱져젼졀졈졉졌졍졔조족존졸졺좀좁좃종좆좇좋좌좍좔좝좟좡좨좼좽죄죈죌죔죕죗죙죠죡죤죵주죽준줄줅줆줌줍줏중줘줬줴쥐쥑쥔쥘쥠쥡쥣쥬쥰쥴쥼즈즉즌즐즘즙즛증지직진짇질짊짐집짓\"],[\"c241\",\"헊헋헍헎헏헑헓\",4,\"헚헜헞\",5,\"헦헧헩헪헫헭헮\"],[\"c261\",\"헯\",4,\"헶헸헺\",5,\"혂혃혅혆혇혉\",6,\"혒\"],[\"c281\",\"혖\",5,\"혝혞혟혡혢혣혥\",7,\"혮\",9,\"혺혻징짖짙짚짜짝짠짢짤짧짬짭짯짰짱째짹짼쨀쨈쨉쨋쨌쨍쨔쨘쨩쩌쩍쩐쩔쩜쩝쩟쩠쩡쩨쩽쪄쪘쪼쪽쫀쫄쫌쫍쫏쫑쫓쫘쫙쫠쫬쫴쬈쬐쬔쬘쬠쬡쭁쭈쭉쭌쭐쭘쭙쭝쭤쭸쭹쮜쮸쯔쯤쯧쯩찌찍찐찔찜찝찡찢찧차착찬찮찰참찹찻\"],[\"c341\",\"혽혾혿홁홂홃홄홆홇홊홌홎홏홐홒홓홖홗홙홚홛홝\",4],[\"c361\",\"홢\",4,\"홨홪\",5,\"홲홳홵\",11],[\"c381\",\"횁횂횄횆\",5,\"횎횏횑횒횓횕\",7,\"횞횠횢\",5,\"횩횪찼창찾채책챈챌챔챕챗챘챙챠챤챦챨챰챵처척천철첨첩첫첬청체첵첸첼쳄쳅쳇쳉쳐쳔쳤쳬쳰촁초촉촌촐촘촙촛총촤촨촬촹최쵠쵤쵬쵭쵯쵱쵸춈추축춘출춤춥춧충춰췄췌췐취췬췰췸췹췻췽츄츈츌츔츙츠측츤츨츰츱츳층\"],[\"c441\",\"횫횭횮횯횱\",7,\"횺횼\",7,\"훆훇훉훊훋\"],[\"c461\",\"훍훎훏훐훒훓훕훖훘훚\",5,\"훡훢훣훥훦훧훩\",4],[\"c481\",\"훮훯훱훲훳훴훶\",5,\"훾훿휁휂휃휅\",11,\"휒휓휔치칙친칟칠칡침칩칫칭카칵칸칼캄캅캇캉캐캑캔캘캠캡캣캤캥캬캭컁커컥컨컫컬컴컵컷컸컹케켁켄켈켐켑켓켕켜켠켤켬켭켯켰켱켸코콕콘콜콤콥콧콩콰콱콴콸쾀쾅쾌쾡쾨쾰쿄쿠쿡쿤쿨쿰쿱쿳쿵쿼퀀퀄퀑퀘퀭퀴퀵퀸퀼\"],[\"c541\",\"휕휖휗휚휛휝휞휟휡\",6,\"휪휬휮\",5,\"휶휷휹\"],[\"c561\",\"휺휻휽\",6,\"흅흆흈흊\",5,\"흒흓흕흚\",4],[\"c581\",\"흟흢흤흦흧흨흪흫흭흮흯흱흲흳흵\",6,\"흾흿힀힂\",5,\"힊힋큄큅큇큉큐큔큘큠크큭큰클큼큽킁키킥킨킬킴킵킷킹타탁탄탈탉탐탑탓탔탕태택탠탤탬탭탯탰탱탸턍터턱턴털턺텀텁텃텄텅테텍텐텔템텝텟텡텨텬텼톄톈토톡톤톨톰톱톳통톺톼퇀퇘퇴퇸툇툉툐투툭툰툴툼툽툿퉁퉈퉜\"],[\"c641\",\"힍힎힏힑\",6,\"힚힜힞\",5],[\"c6a1\",\"퉤튀튁튄튈튐튑튕튜튠튤튬튱트특튼튿틀틂틈틉틋틔틘틜틤틥티틱틴틸팀팁팃팅파팍팎판팔팖팜팝팟팠팡팥패팩팬팰팸팹팻팼팽퍄퍅퍼퍽펀펄펌펍펏펐펑페펙펜펠펨펩펫펭펴편펼폄폅폈평폐폘폡폣포폭폰폴폼폽폿퐁\"],[\"c7a1\",\"퐈퐝푀푄표푠푤푭푯푸푹푼푿풀풂품풉풋풍풔풩퓌퓐퓔퓜퓟퓨퓬퓰퓸퓻퓽프픈플픔픕픗피픽핀필핌핍핏핑하학한할핥함합핫항해핵핸핼햄햅햇했행햐향허헉헌헐헒험헙헛헝헤헥헨헬헴헵헷헹혀혁현혈혐협혓혔형혜혠\"],[\"c8a1\",\"혤혭호혹혼홀홅홈홉홋홍홑화확환활홧황홰홱홴횃횅회획횐횔횝횟횡효횬횰횹횻후훅훈훌훑훔훗훙훠훤훨훰훵훼훽휀휄휑휘휙휜휠휨휩휫휭휴휵휸휼흄흇흉흐흑흔흖흗흘흙흠흡흣흥흩희흰흴흼흽힁히힉힌힐힘힙힛힝\"],[\"caa1\",\"伽佳假價加可呵哥嘉嫁家暇架枷柯歌珂痂稼苛茄街袈訶賈跏軻迦駕刻却各恪慤殼珏脚覺角閣侃刊墾奸姦干幹懇揀杆柬桿澗癎看磵稈竿簡肝艮艱諫間乫喝曷渴碣竭葛褐蝎鞨勘坎堪嵌感憾戡敢柑橄減甘疳監瞰紺邯鑑鑒龕\"],[\"cba1\",\"匣岬甲胛鉀閘剛堈姜岡崗康强彊慷江畺疆糠絳綱羌腔舡薑襁講鋼降鱇介价個凱塏愷愾慨改槪漑疥皆盖箇芥蓋豈鎧開喀客坑更粳羹醵倨去居巨拒据據擧渠炬祛距踞車遽鉅鋸乾件健巾建愆楗腱虔蹇鍵騫乞傑杰桀儉劍劒檢\"],[\"cca1\",\"瞼鈐黔劫怯迲偈憩揭擊格檄激膈覡隔堅牽犬甄絹繭肩見譴遣鵑抉決潔結缺訣兼慊箝謙鉗鎌京俓倞傾儆勁勍卿坰境庚徑慶憬擎敬景暻更梗涇炅烱璟璥瓊痙硬磬竟競絅經耕耿脛莖警輕逕鏡頃頸驚鯨係啓堺契季屆悸戒桂械\"],[\"cda1\",\"棨溪界癸磎稽系繫繼計誡谿階鷄古叩告呱固姑孤尻庫拷攷故敲暠枯槁沽痼皐睾稿羔考股膏苦苽菰藁蠱袴誥賈辜錮雇顧高鼓哭斛曲梏穀谷鵠困坤崑昆梱棍滾琨袞鯤汨滑骨供公共功孔工恐恭拱控攻珙空蚣貢鞏串寡戈果瓜\"],[\"cea1\",\"科菓誇課跨過鍋顆廓槨藿郭串冠官寬慣棺款灌琯瓘管罐菅觀貫關館刮恝括适侊光匡壙廣曠洸炚狂珖筐胱鑛卦掛罫乖傀塊壞怪愧拐槐魁宏紘肱轟交僑咬喬嬌嶠巧攪敎校橋狡皎矯絞翹膠蕎蛟較轎郊餃驕鮫丘久九仇俱具勾\"],[\"cfa1\",\"區口句咎嘔坵垢寇嶇廐懼拘救枸柩構歐毆毬求溝灸狗玖球瞿矩究絿耉臼舅舊苟衢謳購軀逑邱鉤銶駒驅鳩鷗龜國局菊鞠鞫麴君窘群裙軍郡堀屈掘窟宮弓穹窮芎躬倦券勸卷圈拳捲權淃眷厥獗蕨蹶闕机櫃潰詭軌饋句晷歸貴\"],[\"d0a1\",\"鬼龜叫圭奎揆槻珪硅窺竅糾葵規赳逵閨勻均畇筠菌鈞龜橘克剋劇戟棘極隙僅劤勤懃斤根槿瑾筋芹菫覲謹近饉契今妗擒昑檎琴禁禽芩衾衿襟金錦伋及急扱汲級給亘兢矜肯企伎其冀嗜器圻基埼夔奇妓寄岐崎己幾忌技旗旣\"],[\"d1a1\",\"朞期杞棋棄機欺氣汽沂淇玘琦琪璂璣畸畿碁磯祁祇祈祺箕紀綺羈耆耭肌記譏豈起錡錤飢饑騎騏驥麒緊佶吉拮桔金喫儺喇奈娜懦懶拏拿癩\",5,\"那樂\",4,\"諾酪駱亂卵暖欄煖爛蘭難鸞捏捺南嵐枏楠湳濫男藍襤拉\"],[\"d2a1\",\"納臘蠟衲囊娘廊\",4,\"乃來內奈柰耐冷女年撚秊念恬拈捻寧寗努勞奴弩怒擄櫓爐瑙盧\",5,\"駑魯\",10,\"濃籠聾膿農惱牢磊腦賂雷尿壘\",7,\"嫩訥杻紐勒\",5,\"能菱陵尼泥匿溺多茶\"],[\"d3a1\",\"丹亶但單團壇彖斷旦檀段湍短端簞緞蛋袒鄲鍛撻澾獺疸達啖坍憺擔曇淡湛潭澹痰聃膽蕁覃談譚錟沓畓答踏遝唐堂塘幢戇撞棠當糖螳黨代垈坮大對岱帶待戴擡玳臺袋貸隊黛宅德悳倒刀到圖堵塗導屠島嶋度徒悼挑掉搗桃\"],[\"d4a1\",\"棹櫂淘渡滔濤燾盜睹禱稻萄覩賭跳蹈逃途道都鍍陶韜毒瀆牘犢獨督禿篤纛讀墩惇敦旽暾沌焞燉豚頓乭突仝冬凍動同憧東桐棟洞潼疼瞳童胴董銅兜斗杜枓痘竇荳讀豆逗頭屯臀芚遁遯鈍得嶝橙燈登等藤謄鄧騰喇懶拏癩羅\"],[\"d5a1\",\"蘿螺裸邏樂洛烙珞絡落諾酪駱丹亂卵欄欒瀾爛蘭鸞剌辣嵐擥攬欖濫籃纜藍襤覽拉臘蠟廊朗浪狼琅瑯螂郞來崍徠萊冷掠略亮倆兩凉梁樑粮粱糧良諒輛量侶儷勵呂廬慮戾旅櫚濾礪藜蠣閭驢驪麗黎力曆歷瀝礫轢靂憐戀攣漣\"],[\"d6a1\",\"煉璉練聯蓮輦連鍊冽列劣洌烈裂廉斂殮濂簾獵令伶囹寧岺嶺怜玲笭羚翎聆逞鈴零靈領齡例澧禮醴隷勞怒撈擄櫓潞瀘爐盧老蘆虜路輅露魯鷺鹵碌祿綠菉錄鹿麓論壟弄朧瀧瓏籠聾儡瀨牢磊賂賚賴雷了僚寮廖料燎療瞭聊蓼\"],[\"d7a1\",\"遼鬧龍壘婁屢樓淚漏瘻累縷蔞褸鏤陋劉旒柳榴流溜瀏琉瑠留瘤硫謬類六戮陸侖倫崙淪綸輪律慄栗率隆勒肋凜凌楞稜綾菱陵俚利厘吏唎履悧李梨浬犁狸理璃異痢籬罹羸莉裏裡里釐離鯉吝潾燐璘藺躪隣鱗麟林淋琳臨霖砬\"],[\"d8a1\",\"立笠粒摩瑪痲碼磨馬魔麻寞幕漠膜莫邈万卍娩巒彎慢挽晩曼滿漫灣瞞萬蔓蠻輓饅鰻唜抹末沫茉襪靺亡妄忘忙望網罔芒茫莽輞邙埋妹媒寐昧枚梅每煤罵買賣邁魅脈貊陌驀麥孟氓猛盲盟萌冪覓免冕勉棉沔眄眠綿緬面麵滅\"],[\"d9a1\",\"蔑冥名命明暝椧溟皿瞑茗蓂螟酩銘鳴袂侮冒募姆帽慕摸摹暮某模母毛牟牡瑁眸矛耗芼茅謀謨貌木沐牧目睦穆鶩歿沒夢朦蒙卯墓妙廟描昴杳渺猫竗苗錨務巫憮懋戊拇撫无楙武毋無珷畝繆舞茂蕪誣貿霧鵡墨默們刎吻問文\"],[\"daa1\",\"汶紊紋聞蚊門雯勿沕物味媚尾嵋彌微未梶楣渼湄眉米美薇謎迷靡黴岷悶愍憫敏旻旼民泯玟珉緡閔密蜜謐剝博拍搏撲朴樸泊珀璞箔粕縛膊舶薄迫雹駁伴半反叛拌搬攀斑槃泮潘班畔瘢盤盼磐磻礬絆般蟠返頒飯勃拔撥渤潑\"],[\"dba1\",\"發跋醱鉢髮魃倣傍坊妨尨幇彷房放方旁昉枋榜滂磅紡肪膀舫芳蒡蚌訪謗邦防龐倍俳北培徘拜排杯湃焙盃背胚裴裵褙賠輩配陪伯佰帛柏栢白百魄幡樊煩燔番磻繁蕃藩飜伐筏罰閥凡帆梵氾汎泛犯範范法琺僻劈壁擘檗璧癖\"],[\"dca1\",\"碧蘗闢霹便卞弁變辨辯邊別瞥鱉鼈丙倂兵屛幷昞昺柄棅炳甁病秉竝輧餠騈保堡報寶普步洑湺潽珤甫菩補褓譜輔伏僕匐卜宓復服福腹茯蔔複覆輹輻馥鰒本乶俸奉封峯峰捧棒烽熢琫縫蓬蜂逢鋒鳳不付俯傅剖副否咐埠夫婦\"],[\"dda1\",\"孚孵富府復扶敷斧浮溥父符簿缶腐腑膚艀芙莩訃負賦賻赴趺部釜阜附駙鳧北分吩噴墳奔奮忿憤扮昐汾焚盆粉糞紛芬賁雰不佛弗彿拂崩朋棚硼繃鵬丕備匕匪卑妃婢庇悲憊扉批斐枇榧比毖毗毘沸泌琵痺砒碑秕秘粃緋翡肥\"],[\"dea1\",\"脾臂菲蜚裨誹譬費鄙非飛鼻嚬嬪彬斌檳殯浜濱瀕牝玭貧賓頻憑氷聘騁乍事些仕伺似使俟僿史司唆嗣四士奢娑寫寺射巳師徙思捨斜斯柶査梭死沙泗渣瀉獅砂社祀祠私篩紗絲肆舍莎蓑蛇裟詐詞謝賜赦辭邪飼駟麝削數朔索\"],[\"dfa1\",\"傘刪山散汕珊産疝算蒜酸霰乷撒殺煞薩三參杉森渗芟蔘衫揷澁鈒颯上傷像償商喪嘗孀尙峠常床庠廂想桑橡湘爽牀狀相祥箱翔裳觴詳象賞霜塞璽賽嗇塞穡索色牲生甥省笙墅壻嶼序庶徐恕抒捿敍暑曙書栖棲犀瑞筮絮緖署\"],[\"e0a1\",\"胥舒薯西誓逝鋤黍鼠夕奭席惜昔晳析汐淅潟石碩蓆釋錫仙僊先善嬋宣扇敾旋渲煽琁瑄璇璿癬禪線繕羨腺膳船蘚蟬詵跣選銑鐥饍鮮卨屑楔泄洩渫舌薛褻設說雪齧剡暹殲纖蟾贍閃陝攝涉燮葉城姓宬性惺成星晟猩珹盛省筬\"],[\"e1a1\",\"聖聲腥誠醒世勢歲洗稅笹細說貰召嘯塑宵小少巢所掃搔昭梳沼消溯瀟炤燒甦疏疎瘙笑篠簫素紹蔬蕭蘇訴逍遡邵銷韶騷俗屬束涑粟續謖贖速孫巽損蓀遜飡率宋悚松淞訟誦送頌刷殺灑碎鎖衰釗修受嗽囚垂壽嫂守岫峀帥愁\"],[\"e2a1\",\"戍手授搜收數樹殊水洙漱燧狩獸琇璲瘦睡秀穗竪粹綏綬繡羞脩茱蒐蓚藪袖誰讐輸遂邃酬銖銹隋隧隨雖需須首髓鬚叔塾夙孰宿淑潚熟琡璹肅菽巡徇循恂旬栒楯橓殉洵淳珣盾瞬筍純脣舜荀蓴蕣詢諄醇錞順馴戌術述鉥崇崧\"],[\"e3a1\",\"嵩瑟膝蝨濕拾習褶襲丞乘僧勝升承昇繩蠅陞侍匙嘶始媤尸屎屍市弑恃施是時枾柴猜矢示翅蒔蓍視試詩諡豕豺埴寔式息拭植殖湜熄篒蝕識軾食飾伸侁信呻娠宸愼新晨燼申神紳腎臣莘薪藎蜃訊身辛辰迅失室實悉審尋心沁\"],[\"e4a1\",\"沈深瀋甚芯諶什十拾雙氏亞俄兒啞娥峨我牙芽莪蛾衙訝阿雅餓鴉鵝堊岳嶽幄惡愕握樂渥鄂鍔顎鰐齷安岸按晏案眼雁鞍顔鮟斡謁軋閼唵岩巖庵暗癌菴闇壓押狎鴨仰央怏昻殃秧鴦厓哀埃崖愛曖涯碍艾隘靄厄扼掖液縊腋額\"],[\"e5a1\",\"櫻罌鶯鸚也倻冶夜惹揶椰爺耶若野弱掠略約若葯蒻藥躍亮佯兩凉壤孃恙揚攘敭暘梁楊樣洋瀁煬痒瘍禳穰糧羊良襄諒讓釀陽量養圄御於漁瘀禦語馭魚齬億憶抑檍臆偃堰彦焉言諺孼蘖俺儼嚴奄掩淹嶪業円予余勵呂女如廬\"],[\"e6a1\",\"旅歟汝濾璵礖礪與艅茹輿轝閭餘驪麗黎亦力域役易曆歷疫繹譯轢逆驛嚥堧姸娟宴年延憐戀捐挻撚椽沇沿涎涓淵演漣烟然煙煉燃燕璉硏硯秊筵緣練縯聯衍軟輦蓮連鉛鍊鳶列劣咽悅涅烈熱裂說閱厭廉念捻染殮炎焰琰艶苒\"],[\"e7a1\",\"簾閻髥鹽曄獵燁葉令囹塋寧嶺嶸影怜映暎楹榮永泳渶潁濚瀛瀯煐營獰玲瑛瑩瓔盈穎纓羚聆英詠迎鈴鍈零霙靈領乂倪例刈叡曳汭濊猊睿穢芮藝蘂禮裔詣譽豫醴銳隸霓預五伍俉傲午吾吳嗚塢墺奧娛寤悟惡懊敖旿晤梧汚澳\"],[\"e8a1\",\"烏熬獒筽蜈誤鰲鼇屋沃獄玉鈺溫瑥瘟穩縕蘊兀壅擁瓮甕癰翁邕雍饔渦瓦窩窪臥蛙蝸訛婉完宛梡椀浣玩琓琬碗緩翫脘腕莞豌阮頑曰往旺枉汪王倭娃歪矮外嵬巍猥畏了僚僥凹堯夭妖姚寥寮尿嶢拗搖撓擾料曜樂橈燎燿瑤療\"],[\"e9a1\",\"窈窯繇繞耀腰蓼蟯要謠遙遼邀饒慾欲浴縟褥辱俑傭冗勇埇墉容庸慂榕涌湧溶熔瑢用甬聳茸蓉踊鎔鏞龍于佑偶優又友右宇寓尤愚憂旴牛玗瑀盂祐禑禹紆羽芋藕虞迂遇郵釪隅雨雩勖彧旭昱栯煜稶郁頊云暈橒殞澐熉耘芸蕓\"],[\"eaa1\",\"運隕雲韻蔚鬱亐熊雄元原員圓園垣媛嫄寃怨愿援沅洹湲源爰猿瑗苑袁轅遠阮院願鴛月越鉞位偉僞危圍委威尉慰暐渭爲瑋緯胃萎葦蔿蝟衛褘謂違韋魏乳侑儒兪劉唯喩孺宥幼幽庾悠惟愈愉揄攸有杻柔柚柳楡楢油洧流游溜\"],[\"eba1\",\"濡猶猷琉瑜由留癒硫紐維臾萸裕誘諛諭踰蹂遊逾遺酉釉鍮類六堉戮毓肉育陸倫允奫尹崙淪潤玧胤贇輪鈗閏律慄栗率聿戎瀜絨融隆垠恩慇殷誾銀隱乙吟淫蔭陰音飮揖泣邑凝應膺鷹依倚儀宜意懿擬椅毅疑矣義艤薏蟻衣誼\"],[\"eca1\",\"議醫二以伊利吏夷姨履已弛彛怡易李梨泥爾珥理異痍痢移罹而耳肄苡荑裏裡貽貳邇里離飴餌匿溺瀷益翊翌翼謚人仁刃印吝咽因姻寅引忍湮燐璘絪茵藺蚓認隣靭靷鱗麟一佚佾壹日溢逸鎰馹任壬妊姙恁林淋稔臨荏賃入卄\"],[\"eda1\",\"立笠粒仍剩孕芿仔刺咨姉姿子字孜恣慈滋炙煮玆瓷疵磁紫者自茨蔗藉諮資雌作勺嚼斫昨灼炸爵綽芍酌雀鵲孱棧殘潺盞岑暫潛箴簪蠶雜丈仗匠場墻壯奬將帳庄張掌暲杖樟檣欌漿牆狀獐璋章粧腸臟臧莊葬蔣薔藏裝贓醬長\"],[\"eea1\",\"障再哉在宰才材栽梓渽滓災縡裁財載齋齎爭箏諍錚佇低儲咀姐底抵杵楮樗沮渚狙猪疽箸紵苧菹著藷詛貯躇這邸雎齟勣吊嫡寂摘敵滴狄炙的積笛籍績翟荻謫賊赤跡蹟迪迹適鏑佃佺傳全典前剪塡塼奠專展廛悛戰栓殿氈澱\"],[\"efa1\",\"煎琠田甸畑癲筌箋箭篆纏詮輾轉鈿銓錢鐫電顚顫餞切截折浙癤竊節絶占岾店漸点粘霑鮎點接摺蝶丁井亭停偵呈姃定幀庭廷征情挺政整旌晶晸柾楨檉正汀淀淨渟湞瀞炡玎珽町睛碇禎程穽精綎艇訂諪貞鄭酊釘鉦鋌錠霆靖\"],[\"f0a1\",\"靜頂鼎制劑啼堤帝弟悌提梯濟祭第臍薺製諸蹄醍除際霽題齊俎兆凋助嘲弔彫措操早晁曺曹朝條棗槽漕潮照燥爪璪眺祖祚租稠窕粗糟組繰肇藻蚤詔調趙躁造遭釣阻雕鳥族簇足鏃存尊卒拙猝倧宗從悰慫棕淙琮種終綜縱腫\"],[\"f1a1\",\"踪踵鍾鐘佐坐左座挫罪主住侏做姝胄呪周嗾奏宙州廚晝朱柱株注洲湊澍炷珠疇籌紂紬綢舟蛛註誅走躊輳週酎酒鑄駐竹粥俊儁准埈寯峻晙樽浚準濬焌畯竣蠢逡遵雋駿茁中仲衆重卽櫛楫汁葺增憎曾拯烝甑症繒蒸證贈之只\"],[\"f2a1\",\"咫地址志持指摯支旨智枝枳止池沚漬知砥祉祗紙肢脂至芝芷蜘誌識贄趾遲直稙稷織職唇嗔塵振搢晉晋桭榛殄津溱珍瑨璡畛疹盡眞瞋秦縉縝臻蔯袗診賑軫辰進鎭陣陳震侄叱姪嫉帙桎瓆疾秩窒膣蛭質跌迭斟朕什執潗緝輯\"],[\"f3a1\",\"鏶集徵懲澄且侘借叉嗟嵯差次此磋箚茶蹉車遮捉搾着窄錯鑿齪撰澯燦璨瓚竄簒纂粲纘讚贊鑽餐饌刹察擦札紮僭參塹慘慙懺斬站讒讖倉倡創唱娼廠彰愴敞昌昶暢槍滄漲猖瘡窓脹艙菖蒼債埰寀寨彩採砦綵菜蔡采釵冊柵策\"],[\"f4a1\",\"責凄妻悽處倜刺剔尺慽戚拓擲斥滌瘠脊蹠陟隻仟千喘天川擅泉淺玔穿舛薦賤踐遷釧闡阡韆凸哲喆徹撤澈綴輟轍鐵僉尖沾添甛瞻簽籤詹諂堞妾帖捷牒疊睫諜貼輒廳晴淸聽菁請靑鯖切剃替涕滯締諦逮遞體初剿哨憔抄招梢\"],[\"f5a1\",\"椒楚樵炒焦硝礁礎秒稍肖艸苕草蕉貂超酢醋醮促囑燭矗蜀觸寸忖村邨叢塚寵悤憁摠總聰蔥銃撮催崔最墜抽推椎楸樞湫皺秋芻萩諏趨追鄒酋醜錐錘鎚雛騶鰍丑畜祝竺筑築縮蓄蹙蹴軸逐春椿瑃出朮黜充忠沖蟲衝衷悴膵萃\"],[\"f6a1\",\"贅取吹嘴娶就炊翠聚脆臭趣醉驟鷲側仄厠惻測層侈値嗤峙幟恥梔治淄熾痔痴癡稚穉緇緻置致蚩輜雉馳齒則勅飭親七柒漆侵寢枕沈浸琛砧針鍼蟄秤稱快他咤唾墮妥惰打拖朶楕舵陀馱駝倬卓啄坼度托拓擢晫柝濁濯琢琸託\"],[\"f7a1\",\"鐸呑嘆坦彈憚歎灘炭綻誕奪脫探眈耽貪塔搭榻宕帑湯糖蕩兌台太怠態殆汰泰笞胎苔跆邰颱宅擇澤撑攄兎吐土討慟桶洞痛筒統通堆槌腿褪退頹偸套妬投透鬪慝特闖坡婆巴把播擺杷波派爬琶破罷芭跛頗判坂板版瓣販辦鈑\"],[\"f8a1\",\"阪八叭捌佩唄悖敗沛浿牌狽稗覇貝彭澎烹膨愎便偏扁片篇編翩遍鞭騙貶坪平枰萍評吠嬖幣廢弊斃肺蔽閉陛佈包匍匏咆哺圃布怖抛抱捕暴泡浦疱砲胞脯苞葡蒲袍褒逋鋪飽鮑幅暴曝瀑爆輻俵剽彪慓杓標漂瓢票表豹飇飄驃\"],[\"f9a1\",\"品稟楓諷豊風馮彼披疲皮被避陂匹弼必泌珌畢疋筆苾馝乏逼下何厦夏廈昰河瑕荷蝦賀遐霞鰕壑學虐謔鶴寒恨悍旱汗漢澣瀚罕翰閑閒限韓割轄函含咸啣喊檻涵緘艦銜陷鹹合哈盒蛤閤闔陜亢伉姮嫦巷恒抗杭桁沆港缸肛航\"],[\"faa1\",\"行降項亥偕咳垓奚孩害懈楷海瀣蟹解該諧邂駭骸劾核倖幸杏荇行享向嚮珦鄕響餉饗香噓墟虛許憲櫶獻軒歇險驗奕爀赫革俔峴弦懸晛泫炫玄玹現眩睍絃絢縣舷衒見賢鉉顯孑穴血頁嫌俠協夾峽挾浹狹脅脇莢鋏頰亨兄刑型\"],[\"fba1\",\"形泂滎瀅灐炯熒珩瑩荊螢衡逈邢鎣馨兮彗惠慧暳蕙蹊醯鞋乎互呼壕壺好岵弧戶扈昊晧毫浩淏湖滸澔濠濩灝狐琥瑚瓠皓祜糊縞胡芦葫蒿虎號蝴護豪鎬頀顥惑或酷婚昏混渾琿魂忽惚笏哄弘汞泓洪烘紅虹訌鴻化和嬅樺火畵\"],[\"fca1\",\"禍禾花華話譁貨靴廓擴攫確碻穫丸喚奐宦幻患換歡晥桓渙煥環紈還驩鰥活滑猾豁闊凰幌徨恍惶愰慌晃晄榥況湟滉潢煌璜皇篁簧荒蝗遑隍黃匯回廻徊恢悔懷晦會檜淮澮灰獪繪膾茴蛔誨賄劃獲宖橫鐄哮嚆孝效斅曉梟涍淆\"],[\"fda1\",\"爻肴酵驍侯候厚后吼喉嗅帿後朽煦珝逅勛勳塤壎焄熏燻薰訓暈薨喧暄煊萱卉喙毁彙徽揮暉煇諱輝麾休携烋畦虧恤譎鷸兇凶匈洶胸黑昕欣炘痕吃屹紇訖欠欽歆吸恰洽翕興僖凞喜噫囍姬嬉希憙憘戱晞曦熙熹熺犧禧稀羲詰\"]]");

/***/ }),
/* 433 */
/***/ (function(module) {

module.exports = JSON.parse("[[\"8740\",\"䏰䰲䘃䖦䕸𧉧䵷䖳𧲱䳢𧳅㮕䜶䝄䱇䱀𤊿𣘗𧍒𦺋𧃒䱗𪍑䝏䗚䲅𧱬䴇䪤䚡𦬣爥𥩔𡩣𣸆𣽡晍囻\"],[\"8767\",\"綕夝𨮹㷴霴𧯯寛𡵞媤㘥𩺰嫑宷峼杮薓𩥅瑡璝㡵𡵓𣚞𦀡㻬\"],[\"87a1\",\"𥣞㫵竼龗𤅡𨤍𣇪𠪊𣉞䌊蒄龖鐯䤰蘓墖靊鈘秐稲晠権袝瑌篅枂稬剏遆㓦珄𥶹瓆鿇垳䤯呌䄱𣚎堘穲𧭥讏䚮𦺈䆁𥶙箮𢒼鿈𢓁𢓉𢓌鿉蔄𣖻䂴鿊䓡𪷿拁灮鿋\"],[\"8840\",\"㇀\",4,\"𠄌㇅𠃑𠃍㇆㇇𠃋𡿨㇈𠃊㇉㇊㇋㇌𠄎㇍㇎ĀÁǍÀĒÉĚÈŌÓǑÒ࿿Ê̄Ế࿿Ê̌ỀÊāáǎàɑēéěèīíǐìōóǒòūúǔùǖǘǚ\"],[\"88a1\",\"ǜü࿿ê̄ế࿿ê̌ềêɡ⏚⏛\"],[\"8940\",\"𪎩𡅅\"],[\"8943\",\"攊\"],[\"8946\",\"丽滝鵎釟\"],[\"894c\",\"𧜵撑会伨侨兖兴农凤务动医华发变团声处备夲头学实実岚庆总斉柾栄桥济炼电纤纬纺织经统缆缷艺苏药视设询车轧轮\"],[\"89a1\",\"琑糼緍楆竉刧\"],[\"89ab\",\"醌碸酞肼\"],[\"89b0\",\"贋胶𠧧\"],[\"89b5\",\"肟黇䳍鷉鸌䰾𩷶𧀎鸊𪄳㗁\"],[\"89c1\",\"溚舾甙\"],[\"89c5\",\"䤑马骏龙禇𨑬𡷊𠗐𢫦两亁亀亇亿仫伷㑌侽㹈倃傈㑽㒓㒥円夅凛凼刅争剹劐匧㗇厩㕑厰㕓参吣㕭㕲㚁咓咣咴咹哐哯唘唣唨㖘唿㖥㖿嗗㗅\"],[\"8a40\",\"𧶄唥\"],[\"8a43\",\"𠱂𠴕𥄫喐𢳆㧬𠍁蹆𤶸𩓥䁓𨂾睺𢰸㨴䟕𨅝𦧲𤷪擝𠵼𠾴𠳕𡃴撍蹾𠺖𠰋𠽤𢲩𨉖𤓓\"],[\"8a64\",\"𠵆𩩍𨃩䟴𤺧𢳂骲㩧𩗴㿭㔆𥋇𩟔𧣈𢵄鵮頕\"],[\"8a76\",\"䏙𦂥撴哣𢵌𢯊𡁷㧻𡁯\"],[\"8aa1\",\"𦛚𦜖𧦠擪𥁒𠱃蹨𢆡𨭌𠜱\"],[\"8aac\",\"䠋𠆩㿺塳𢶍\"],[\"8ab2\",\"𤗈𠓼𦂗𠽌𠶖啹䂻䎺\"],[\"8abb\",\"䪴𢩦𡂝膪飵𠶜捹㧾𢝵跀嚡摼㹃\"],[\"8ac9\",\"𪘁𠸉𢫏𢳉\"],[\"8ace\",\"𡃈𣧂㦒㨆𨊛㕸𥹉𢃇噒𠼱𢲲𩜠㒼氽𤸻\"],[\"8adf\",\"𧕴𢺋𢈈𪙛𨳍𠹺𠰴𦠜羓𡃏𢠃𢤹㗻𥇣𠺌𠾍𠺪㾓𠼰𠵇𡅏𠹌\"],[\"8af6\",\"𠺫𠮩𠵈𡃀𡄽㿹𢚖搲𠾭\"],[\"8b40\",\"𣏴𧘹𢯎𠵾𠵿𢱑𢱕㨘𠺘𡃇𠼮𪘲𦭐𨳒𨶙𨳊閪哌苄喹\"],[\"8b55\",\"𩻃鰦骶𧝞𢷮煀腭胬尜𦕲脴㞗卟𨂽醶𠻺𠸏𠹷𠻻㗝𤷫㘉𠳖嚯𢞵𡃉𠸐𠹸𡁸𡅈𨈇𡑕𠹹𤹐𢶤婔𡀝𡀞𡃵𡃶垜𠸑\"],[\"8ba1\",\"𧚔𨋍𠾵𠹻𥅾㜃𠾶𡆀𥋘𪊽𤧚𡠺𤅷𨉼墙剨㘚𥜽箲孨䠀䬬鼧䧧鰟鮍𥭴𣄽嗻㗲嚉丨夂𡯁屮靑𠂆乛亻㔾尣彑忄㣺扌攵歺氵氺灬爫丬犭𤣩罒礻糹罓𦉪㓁\"],[\"8bde\",\"𦍋耂肀𦘒𦥑卝衤见𧢲讠贝钅镸长门𨸏韦页风飞饣𩠐鱼鸟黄歯龜丷𠂇阝户钢\"],[\"8c40\",\"倻淾𩱳龦㷉袏𤅎灷峵䬠𥇍㕙𥴰愢𨨲辧釶熑朙玺𣊁𪄇㲋𡦀䬐磤琂冮𨜏䀉橣𪊺䈣蘏𠩯稪𩥇𨫪靕灍匤𢁾鏴盙𨧣龧矝亣俰傼丯众龨吴綋墒壐𡶶庒庙忂𢜒斋\"],[\"8ca1\",\"𣏹椙橃𣱣泿\"],[\"8ca7\",\"爀𤔅玌㻛𤨓嬕璹讃𥲤𥚕窓篬糃繬苸薗龩袐龪躹龫迏蕟駠鈡龬𨶹𡐿䁱䊢娚\"],[\"8cc9\",\"顨杫䉶圽\"],[\"8cce\",\"藖𤥻芿𧄍䲁𦵴嵻𦬕𦾾龭龮宖龯曧繛湗秊㶈䓃𣉖𢞖䎚䔶\"],[\"8ce6\",\"峕𣬚諹屸㴒𣕑嵸龲煗䕘𤃬𡸣䱷㥸㑊𠆤𦱁諌侴𠈹妿腬顖𩣺弻\"],[\"8d40\",\"𠮟\"],[\"8d42\",\"𢇁𨥭䄂䚻𩁹㼇龳𪆵䃸㟖䛷𦱆䅼𨚲𧏿䕭㣔𥒚䕡䔛䶉䱻䵶䗪㿈𤬏㙡䓞䒽䇭崾嵈嵖㷼㠏嶤嶹㠠㠸幂庽弥徃㤈㤔㤿㥍惗愽峥㦉憷憹懏㦸戬抐拥挘㧸嚱\"],[\"8da1\",\"㨃揢揻搇摚㩋擀崕嘡龟㪗斆㪽旿晓㫲暒㬢朖㭂枤栀㭘桊梄㭲㭱㭻椉楃牜楤榟榅㮼槖㯝橥橴橱檂㯬檙㯲檫檵櫔櫶殁毁毪汵沪㳋洂洆洦涁㳯涤涱渕渘温溆𨧀溻滢滚齿滨滩漤漴㵆𣽁澁澾㵪㵵熷岙㶊瀬㶑灐灔灯灿炉𠌥䏁㗱𠻘\"],[\"8e40\",\"𣻗垾𦻓焾𥟠㙎榢𨯩孴穉𥣡𩓙穥穽𥦬窻窰竂竃燑𦒍䇊竚竝竪䇯咲𥰁笋筕笩𥌎𥳾箢筯莜𥮴𦱿篐萡箒箸𥴠㶭𥱥蒒篺簆簵𥳁籄粃𤢂粦晽𤕸糉糇糦籴糳糵糎\"],[\"8ea1\",\"繧䔝𦹄絝𦻖璍綉綫焵綳緒𤁗𦀩緤㴓緵𡟹緥𨍭縝𦄡𦅚繮纒䌫鑬縧罀罁罇礶𦋐駡羗𦍑羣𡙡𠁨䕜𣝦䔃𨌺翺𦒉者耈耝耨耯𪂇𦳃耻耼聡𢜔䦉𦘦𣷣𦛨朥肧𨩈脇脚墰𢛶汿𦒘𤾸擧𡒊舘𡡞橓𤩥𤪕䑺舩𠬍𦩒𣵾俹𡓽蓢荢𦬊𤦧𣔰𡝳𣷸芪椛芳䇛\"],[\"8f40\",\"蕋苐茚𠸖𡞴㛁𣅽𣕚艻苢茘𣺋𦶣𦬅𦮗𣗎㶿茝嗬莅䔋𦶥莬菁菓㑾𦻔橗蕚㒖𦹂𢻯葘𥯤葱㷓䓤檧葊𣲵祘蒨𦮖𦹷𦹃蓞萏莑䒠蒓蓤𥲑䉀𥳀䕃蔴嫲𦺙䔧蕳䔖枿蘖\"],[\"8fa1\",\"𨘥𨘻藁𧂈蘂𡖂𧃍䕫䕪蘨㙈𡢢号𧎚虾蝱𪃸蟮𢰧螱蟚蠏噡虬桖䘏衅衆𧗠𣶹𧗤衞袜䙛袴袵揁装睷𧜏覇覊覦覩覧覼𨨥觧𧤤𧪽誜瞓釾誐𧩙竩𧬺𣾏䜓𧬸煼謌謟𥐰𥕥謿譌譍誩𤩺讐讛誯𡛟䘕衏貛𧵔𧶏貫㜥𧵓賖𧶘𧶽贒贃𡤐賛灜贑𤳉㻐起\"],[\"9040\",\"趩𨀂𡀔𤦊㭼𨆼𧄌竧躭躶軃鋔輙輭𨍥𨐒辥錃𪊟𠩐辳䤪𨧞𨔽𣶻廸𣉢迹𪀔𨚼𨔁𢌥㦀𦻗逷𨔼𧪾遡𨕬𨘋邨𨜓郄𨛦邮都酧㫰醩釄粬𨤳𡺉鈎沟鉁鉢𥖹銹𨫆𣲛𨬌𥗛\"],[\"90a1\",\"𠴱錬鍫𨫡𨯫炏嫃𨫢𨫥䥥鉄𨯬𨰹𨯿鍳鑛躼閅閦鐦閠濶䊹𢙺𨛘𡉼𣸮䧟氜陻隖䅬隣𦻕懚隶磵𨫠隽双䦡𦲸𠉴𦐐𩂯𩃥𤫑𡤕𣌊霱虂霶䨏䔽䖅𤫩灵孁霛靜𩇕靗孊𩇫靟鐥僐𣂷𣂼鞉鞟鞱鞾韀韒韠𥑬韮琜𩐳響韵𩐝𧥺䫑頴頳顋顦㬎𧅵㵑𠘰𤅜\"],[\"9140\",\"𥜆飊颷飈飇䫿𦴧𡛓喰飡飦飬鍸餹𤨩䭲𩡗𩤅駵騌騻騐驘𥜥㛄𩂱𩯕髠髢𩬅髴䰎鬔鬭𨘀倴鬴𦦨㣃𣁽魐魀𩴾婅𡡣鮎𤉋鰂鯿鰌𩹨鷔𩾷𪆒𪆫𪃡𪄣𪇟鵾鶃𪄴鸎梈\"],[\"91a1\",\"鷄𢅛𪆓𪈠𡤻𪈳鴹𪂹𪊴麐麕麞麢䴴麪麯𤍤黁㭠㧥㴝伲㞾𨰫鼂鼈䮖鐤𦶢鼗鼖鼹嚟嚊齅馸𩂋韲葿齢齩竜龎爖䮾𤥵𤦻煷𤧸𤍈𤩑玞𨯚𡣺禟𨥾𨸶鍩鏳𨩄鋬鎁鏋𨥬𤒹爗㻫睲穃烐𤑳𤏸煾𡟯炣𡢾𣖙㻇𡢅𥐯𡟸㜢𡛻𡠹㛡𡝴𡣑𥽋㜣𡛀坛𤨥𡏾𡊨\"],[\"9240\",\"𡏆𡒶蔃𣚦蔃葕𤦔𧅥𣸱𥕜𣻻𧁒䓴𣛮𩦝𦼦柹㜳㰕㷧塬𡤢栐䁗𣜿𤃡𤂋𤄏𦰡哋嚞𦚱嚒𠿟𠮨𠸍鏆𨬓鎜仸儫㠙𤐶亼𠑥𠍿佋侊𥙑婨𠆫𠏋㦙𠌊𠐔㐵伩𠋀𨺳𠉵諚𠈌亘\"],[\"92a1\",\"働儍侢伃𤨎𣺊佂倮偬傁俌俥偘僼兙兛兝兞湶𣖕𣸹𣺿浲𡢄𣺉冨凃𠗠䓝𠒣𠒒𠒑赺𨪜𠜎剙劤𠡳勡鍮䙺熌𤎌𠰠𤦬𡃤槑𠸝瑹㻞璙琔瑖玘䮎𤪼𤂍叐㖄爏𤃉喴𠍅响𠯆圝鉝雴鍦埝垍坿㘾壋媙𨩆𡛺𡝯𡜐娬妸銏婾嫏娒𥥆𡧳𡡡𤊕㛵洅瑃娡𥺃\"],[\"9340\",\"媁𨯗𠐓鏠璌𡌃焅䥲鐈𨧻鎽㞠尞岞幞幈𡦖𡥼𣫮廍孏𡤃𡤄㜁𡢠㛝𡛾㛓脪𨩇𡶺𣑲𨦨弌弎𡤧𡞫婫𡜻孄蘔𧗽衠恾𢡠𢘫忛㺸𢖯𢖾𩂈𦽳懀𠀾𠁆𢘛憙憘恵𢲛𢴇𤛔𩅍\"],[\"93a1\",\"摱𤙥𢭪㨩𢬢𣑐𩣪𢹸挷𪑛撶挱揑𤧣𢵧护𢲡搻敫楲㯴𣂎𣊭𤦉𣊫唍𣋠𡣙𩐿曎𣊉𣆳㫠䆐𥖄𨬢𥖏𡛼𥕛𥐥磮𣄃𡠪𣈴㑤𣈏𣆂𤋉暎𦴤晫䮓昰𧡰𡷫晣𣋒𣋡昞𥡲㣑𣠺𣞼㮙𣞢𣏾瓐㮖枏𤘪梶栞㯄檾㡣𣟕𤒇樳橒櫉欅𡤒攑梘橌㯗橺歗𣿀𣲚鎠鋲𨯪𨫋\"],[\"9440\",\"銉𨀞𨧜鑧涥漋𤧬浧𣽿㶏渄𤀼娽渊塇洤硂焻𤌚𤉶烱牐犇犔𤞏𤜥兹𤪤𠗫瑺𣻸𣙟𤩊𤤗𥿡㼆㺱𤫟𨰣𣼵悧㻳瓌琼鎇琷䒟𦷪䕑疃㽣𤳙𤴆㽘畕癳𪗆㬙瑨𨫌𤦫𤦎㫻\"],[\"94a1\",\"㷍𤩎㻿𤧅𤣳釺圲鍂𨫣𡡤僟𥈡𥇧睸𣈲眎眏睻𤚗𣞁㩞𤣰琸璛㺿𤪺𤫇䃈𤪖𦆮錇𥖁砞碍碈磒珐祙𧝁𥛣䄎禛蒖禥樭𣻺稺秴䅮𡛦䄲鈵秱𠵌𤦌𠊙𣶺𡝮㖗啫㕰㚪𠇔𠰍竢婙𢛵𥪯𥪜娍𠉛磰娪𥯆竾䇹籝籭䈑𥮳𥺼𥺦糍𤧹𡞰粎籼粮檲緜縇緓罎𦉡\"],[\"9540\",\"𦅜𧭈綗𥺂䉪𦭵𠤖柖𠁎𣗏埄𦐒𦏸𤥢翝笧𠠬𥫩𥵃笌𥸎駦虅驣樜𣐿㧢𤧷𦖭騟𦖠蒀𧄧𦳑䓪脷䐂胆脉腂𦞴飃𦩂艢艥𦩑葓𦶧蘐𧈛媆䅿𡡀嬫𡢡嫤𡣘蚠蜨𣶏蠭𧐢娂\"],[\"95a1\",\"衮佅袇袿裦襥襍𥚃襔𧞅𧞄𨯵𨯙𨮜𨧹㺭蒣䛵䛏㟲訽訜𩑈彍鈫𤊄旔焩烄𡡅鵭貟賩𧷜妚矃姰䍮㛔踪躧𤰉輰轊䋴汘澻𢌡䢛潹溋𡟚鯩㚵𤤯邻邗啱䤆醻鐄𨩋䁢𨫼鐧𨰝𨰻蓥訫閙閧閗閖𨴴瑅㻂𤣿𤩂𤏪㻧𣈥随𨻧𨹦𨹥㻌𤧭𤩸𣿮琒瑫㻼靁𩂰\"],[\"9640\",\"桇䨝𩂓𥟟靝鍨𨦉𨰦𨬯𦎾銺嬑譩䤼珹𤈛鞛靱餸𠼦巁𨯅𤪲頟𩓚鋶𩗗釥䓀𨭐𤩧𨭤飜𨩅㼀鈪䤥萔餻饍𧬆㷽馛䭯馪驜𨭥𥣈檏騡嫾騯𩣱䮐𩥈馼䮽䮗鍽塲𡌂堢𤦸\"],[\"96a1\",\"𡓨硄𢜟𣶸棅㵽鑘㤧慐𢞁𢥫愇鱏鱓鱻鰵鰐魿鯏𩸭鮟𪇵𪃾鴡䲮𤄄鸘䲰鴌𪆴𪃭𪃳𩤯鶥蒽𦸒𦿟𦮂藼䔳𦶤𦺄𦷰萠藮𦸀𣟗𦁤秢𣖜𣙀䤭𤧞㵢鏛銾鍈𠊿碹鉷鑍俤㑀遤𥕝砽硔碶硋𡝗𣇉𤥁㚚佲濚濙瀞瀞吔𤆵垻壳垊鴖埗焴㒯𤆬燫𦱀𤾗嬨𡞵𨩉\"],[\"9740\",\"愌嫎娋䊼𤒈㜬䭻𨧼鎻鎸𡣖𠼝葲𦳀𡐓𤋺𢰦𤏁妔𣶷𦝁綨𦅛𦂤𤦹𤦋𨧺鋥珢㻩璴𨭣𡢟㻡𤪳櫘珳珻㻖𤨾𤪔𡟙𤩦𠎧𡐤𤧥瑈𤤖炥𤥶銄珦鍟𠓾錱𨫎𨨖鎆𨯧𥗕䤵𨪂煫\"],[\"97a1\",\"𤥃𠳿嚤𠘚𠯫𠲸唂秄𡟺緾𡛂𤩐𡡒䔮鐁㜊𨫀𤦭妰𡢿𡢃𧒄媡㛢𣵛㚰鉟婹𨪁𡡢鍴㳍𠪴䪖㦊僴㵩㵌𡎜煵䋻𨈘渏𩃤䓫浗𧹏灧沯㳖𣿭𣸭渂漌㵯𠏵畑㚼㓈䚀㻚䡱姄鉮䤾轁𨰜𦯀堒埈㛖𡑒烾𤍢𤩱𢿣𡊰𢎽梹楧𡎘𣓥𧯴𣛟𨪃𣟖𣏺𤲟樚𣚭𦲷萾䓟䓎\"],[\"9840\",\"𦴦𦵑𦲂𦿞漗𧄉茽𡜺菭𦲀𧁓𡟛妉媂𡞳婡婱𡤅𤇼㜭姯𡜼㛇熎鎐暚𤊥婮娫𤊓樫𣻹𧜶𤑛𤋊焝𤉙𨧡侰𦴨峂𤓎𧹍𤎽樌𤉖𡌄炦焳𤏩㶥泟勇𤩏繥姫崯㷳彜𤩝𡟟綤萦\"],[\"98a1\",\"咅𣫺𣌀𠈔坾𠣕𠘙㿥𡾞𪊶瀃𩅛嵰玏糓𨩙𩐠俈翧狍猐𧫴猸猹𥛶獁獈㺩𧬘遬燵𤣲珡臶㻊県㻑沢国琙琞琟㻢㻰㻴㻺瓓㼎㽓畂畭畲疍㽼痈痜㿀癍㿗癴㿜発𤽜熈嘣覀塩䀝睃䀹条䁅㗛瞘䁪䁯属瞾矋売砘点砜䂨砹硇硑硦葈𥔵礳栃礲䄃\"],[\"9940\",\"䄉禑禙辻稆込䅧窑䆲窼艹䇄竏竛䇏両筢筬筻簒簛䉠䉺类粜䊌粸䊔糭输烀𠳏総緔緐緽羮羴犟䎗耠耥笹耮耱联㷌垴炠肷胩䏭脌猪脎脒畠脔䐁㬹腖腙腚\"],[\"99a1\",\"䐓堺腼膄䐥膓䐭膥埯臁臤艔䒏芦艶苊苘苿䒰荗险榊萅烵葤惣蒈䔄蒾蓡蓸蔐蔸蕒䔻蕯蕰藠䕷虲蚒蚲蛯际螋䘆䘗袮裿褤襇覑𧥧訩訸誔誴豑賔賲贜䞘塟跃䟭仮踺嗘坔蹱嗵躰䠷軎転軤軭軲辷迁迊迌逳駄䢭飠鈓䤞鈨鉘鉫銱銮銿\"],[\"9a40\",\"鋣鋫鋳鋴鋽鍃鎄鎭䥅䥑麿鐗匁鐝鐭鐾䥪鑔鑹锭関䦧间阳䧥枠䨤靀䨵鞲韂噔䫤惨颹䬙飱塄餎餙冴餜餷饂饝饢䭰駅䮝騼鬏窃魩鮁鯝鯱鯴䱭鰠㝯𡯂鵉鰺\"],[\"9aa1\",\"黾噐鶓鶽鷀鷼银辶鹻麬麱麽黆铜黢黱黸竈齄𠂔𠊷𠎠椚铃妬𠓗塀铁㞹𠗕𠘕𠙶𡚺块煳𠫂𠫍𠮿呪吆𠯋咞𠯻𠰻𠱓𠱥𠱼惧𠲍噺𠲵𠳝𠳭𠵯𠶲𠷈楕鰯螥𠸄𠸎𠻗𠾐𠼭𠹳尠𠾼帋𡁜𡁏𡁶朞𡁻𡂈𡂖㙇𡂿𡃓𡄯𡄻卤蒭𡋣𡍵𡌶讁𡕷𡘙𡟃𡟇乸炻𡠭𡥪\"],[\"9b40\",\"𡨭𡩅𡰪𡱰𡲬𡻈拃𡻕𡼕熘桕𢁅槩㛈𢉼𢏗𢏺𢜪𢡱𢥏苽𢥧𢦓𢫕覥𢫨辠𢬎鞸𢬿顇骽𢱌\"],[\"9b62\",\"𢲈𢲷𥯨𢴈𢴒𢶷𢶕𢹂𢽴𢿌𣀳𣁦𣌟𣏞徱晈暿𧩹𣕧𣗳爁𤦺矗𣘚𣜖纇𠍆墵朎\"],[\"9ba1\",\"椘𣪧𧙗𥿢𣸑𣺹𧗾𢂚䣐䪸𤄙𨪚𤋮𤌍𤀻𤌴𤎖𤩅𠗊凒𠘑妟𡺨㮾𣳿𤐄𤓖垈𤙴㦛𤜯𨗨𩧉㝢𢇃譞𨭎駖𤠒𤣻𤨕爉𤫀𠱸奥𤺥𤾆𠝹軚𥀬劏圿煱𥊙𥐙𣽊𤪧喼𥑆𥑮𦭒釔㑳𥔿𧘲𥕞䜘𥕢𥕦𥟇𤤿𥡝偦㓻𣏌惞𥤃䝼𨥈𥪮𥮉𥰆𡶐垡煑澶𦄂𧰒遖𦆲𤾚譢𦐂𦑊\"],[\"9c40\",\"嵛𦯷輶𦒄𡤜諪𤧶𦒈𣿯𦔒䯀𦖿𦚵𢜛鑥𥟡憕娧晉侻嚹𤔡𦛼乪𤤴陖涏𦲽㘘襷𦞙𦡮𦐑𦡞營𦣇筂𩃀𠨑𦤦鄄𦤹穅鷰𦧺騦𦨭㙟𦑩𠀡禃𦨴𦭛崬𣔙菏𦮝䛐𦲤画补𦶮墶\"],[\"9ca1\",\"㜜𢖍𧁋𧇍㱔𧊀𧊅銁𢅺𧊋錰𧋦𤧐氹钟𧑐𠻸蠧裵𢤦𨑳𡞱溸𤨪𡠠㦤㚹尐秣䔿暶𩲭𩢤襃𧟌𧡘囖䃟𡘊㦡𣜯𨃨𡏅熭荦𧧝𩆨婧䲷𧂯𨦫𧧽𧨊𧬋𧵦𤅺筃祾𨀉澵𪋟樃𨌘厢𦸇鎿栶靝𨅯𨀣𦦵𡏭𣈯𨁈嶅𨰰𨂃圕頣𨥉嶫𤦈斾槕叒𤪥𣾁㰑朶𨂐𨃴𨄮𡾡𨅏\"],[\"9d40\",\"𨆉𨆯𨈚𨌆𨌯𨎊㗊𨑨𨚪䣺揦𨥖砈鉕𨦸䏲𨧧䏟𨧨𨭆𨯔姸𨰉輋𨿅𩃬筑𩄐𩄼㷷𩅞𤫊运犏嚋𩓧𩗩𩖰𩖸𩜲𩣑𩥉𩥪𩧃𩨨𩬎𩵚𩶛纟𩻸𩼣䲤镇𪊓熢𪋿䶑递𪗋䶜𠲜达嗁\"],[\"9da1\",\"辺𢒰边𤪓䔉繿潖檱仪㓤𨬬𧢝㜺躀𡟵𨀤𨭬𨮙𧨾𦚯㷫𧙕𣲷𥘵𥥖亚𥺁𦉘嚿𠹭踎孭𣺈𤲞揞拐𡟶𡡻攰嘭𥱊吚𥌑㷆𩶘䱽嘢嘞罉𥻘奵𣵀蝰东𠿪𠵉𣚺脗鵞贘瘻鱅癎瞹鍅吲腈苷嘥脲萘肽嗪祢噃吖𠺝㗎嘅嗱曱𨋢㘭甴嗰喺咗啲𠱁𠲖廐𥅈𠹶𢱢\"],[\"9e40\",\"𠺢麫絚嗞𡁵抝靭咔賍燶酶揼掹揾啩𢭃鱲𢺳冚㓟𠶧冧呍唞唓癦踭𦢊疱肶蠄螆裇膶萜𡃁䓬猄𤜆宐茋𦢓噻𢛴𧴯𤆣𧵳𦻐𧊶酰𡇙鈈𣳼𪚩𠺬𠻹牦𡲢䝎𤿂𧿹𠿫䃺\"],[\"9ea1\",\"鱝攟𢶠䣳𤟠𩵼𠿬𠸊恢𧖣𠿭\"],[\"9ead\",\"𦁈𡆇熣纎鵐业丄㕷嬍沲卧㚬㧜卽㚥𤘘墚𤭮舭呋垪𥪕𠥹\"],[\"9ec5\",\"㩒𢑥獴𩺬䴉鯭𣳾𩼰䱛𤾩𩖞𩿞葜𣶶𧊲𦞳𣜠挮紥𣻷𣸬㨪逈勌㹴㙺䗩𠒎癀嫰𠺶硺𧼮墧䂿噼鮋嵴癔𪐴麅䳡痹㟻愙𣃚𤏲\"],[\"9ef5\",\"噝𡊩垧𤥣𩸆刴𧂮㖭汊鵼\"],[\"9f40\",\"籖鬹埞𡝬屓擓𩓐𦌵𧅤蚭𠴨𦴢𤫢𠵱\"],[\"9f4f\",\"凾𡼏嶎霃𡷑麁遌笟鬂峑箣扨挵髿篏鬪籾鬮籂粆鰕篼鬉鼗鰛𤤾齚啳寃俽麘俲剠㸆勑坧偖妷帒韈鶫轜呩鞴饀鞺匬愰\"],[\"9fa1\",\"椬叚鰊鴂䰻陁榀傦畆𡝭駚剳\"],[\"9fae\",\"酙隁酜\"],[\"9fb2\",\"酑𨺗捿𦴣櫊嘑醎畺抅𠏼獏籰𥰡𣳽\"],[\"9fc1\",\"𤤙盖鮝个𠳔莾衂\"],[\"9fc9\",\"届槀僭坺刟巵从氱𠇲伹咜哚劚趂㗾弌㗳\"],[\"9fdb\",\"歒酼龥鮗頮颴骺麨麄煺笔\"],[\"9fe7\",\"毺蠘罸\"],[\"9feb\",\"嘠𪙊蹷齓\"],[\"9ff0\",\"跔蹏鸜踁抂𨍽踨蹵竓𤩷稾磘泪詧瘇\"],[\"a040\",\"𨩚鼦泎蟖痃𪊲硓咢贌狢獱謭猂瓱賫𤪻蘯徺袠䒷\"],[\"a055\",\"𡠻𦸅\"],[\"a058\",\"詾𢔛\"],[\"a05b\",\"惽癧髗鵄鍮鮏蟵\"],[\"a063\",\"蠏賷猬霡鮰㗖犲䰇籑饊𦅙慙䰄麖慽\"],[\"a073\",\"坟慯抦戹拎㩜懢厪𣏵捤栂㗒\"],[\"a0a1\",\"嵗𨯂迚𨸹\"],[\"a0a6\",\"僙𡵆礆匲阸𠼻䁥\"],[\"a0ae\",\"矾\"],[\"a0b0\",\"糂𥼚糚稭聦聣絍甅瓲覔舚朌聢𧒆聛瓰脃眤覉𦟌畓𦻑螩蟎臈螌詉貭譃眫瓸蓚㘵榲趦\"],[\"a0d4\",\"覩瑨涹蟁𤀑瓧㷛煶悤憜㳑煢恷\"],[\"a0e2\",\"罱𨬭牐惩䭾删㰘𣳇𥻗𧙖𥔱𡥄𡋾𩤃𦷜𧂭峁𦆭𨨏𣙷𠃮𦡆𤼎䕢嬟𦍌齐麦𦉫\"],[\"a3c0\",\"␀\",31,\"␡\"],[\"c6a1\",\"①\",9,\"⑴\",9,\"ⅰ\",9,\"丶丿亅亠冂冖冫勹匸卩厶夊宀巛⼳广廴彐彡攴无疒癶辵隶¨ˆヽヾゝゞ〃仝々〆〇ー［］✽ぁ\",23],[\"c740\",\"す\",58,\"ァアィイ\"],[\"c7a1\",\"ゥ\",81,\"А\",5,\"ЁЖ\",4],[\"c840\",\"Л\",26,\"ёж\",25,\"⇧↸↹㇏𠃌乚𠂊刂䒑\"],[\"c8a1\",\"龰冈龱𧘇\"],[\"c8cd\",\"￢￤＇＂㈱№℡゛゜⺀⺄⺆⺇⺈⺊⺌⺍⺕⺜⺝⺥⺧⺪⺬⺮⺶⺼⺾⻆⻊⻌⻍⻏⻖⻗⻞⻣\"],[\"c8f5\",\"ʃɐɛɔɵœøŋʊɪ\"],[\"f9fe\",\"￭\"],[\"fa40\",\"𠕇鋛𠗟𣿅蕌䊵珯况㙉𤥂𨧤鍄𡧛苮𣳈砼杄拟𤤳𨦪𠊠𦮳𡌅侫𢓭倈𦴩𧪄𣘀𤪱𢔓倩𠍾徤𠎀𠍇滛𠐟偽儁㑺儎顬㝃萖𤦤𠒇兠𣎴兪𠯿𢃼𠋥𢔰𠖎𣈳𡦃宂蝽𠖳𣲙冲冸\"],[\"faa1\",\"鴴凉减凑㳜凓𤪦决凢卂凭菍椾𣜭彻刋刦刼劵剗劔効勅簕蕂勠蘍𦬓包𨫞啉滙𣾀𠥔𣿬匳卄𠯢泋𡜦栛珕恊㺪㣌𡛨燝䒢卭却𨚫卾卿𡖖𡘓矦厓𨪛厠厫厮玧𥝲㽙玜叁叅汉义埾叙㪫𠮏叠𣿫𢶣叶𠱷吓灹唫晗浛呭𦭓𠵴啝咏咤䞦𡜍𠻝㶴𠵍\"],[\"fb40\",\"𨦼𢚘啇䳭启琗喆喩嘅𡣗𤀺䕒𤐵暳𡂴嘷曍𣊊暤暭噍噏磱囱鞇叾圀囯园𨭦㘣𡉏坆𤆥汮炋坂㚱𦱾埦𡐖堃𡑔𤍣堦𤯵塜墪㕡壠壜𡈼壻寿坃𪅐𤉸鏓㖡够梦㛃湙\"],[\"fba1\",\"𡘾娤啓𡚒蔅姉𠵎𦲁𦴪𡟜姙𡟻𡞲𦶦浱𡠨𡛕姹𦹅媫婣㛦𤦩婷㜈媖瑥嫓𦾡𢕔㶅𡤑㜲𡚸広勐孶斈孼𧨎䀄䡝𠈄寕慠𡨴𥧌𠖥寳宝䴐尅𡭄尓珎尔𡲥𦬨屉䣝岅峩峯嶋𡷹𡸷崐崘嵆𡺤岺巗苼㠭𤤁𢁉𢅳芇㠶㯂帮檊幵幺𤒼𠳓厦亷廐厨𡝱帉廴𨒂\"],[\"fc40\",\"廹廻㢠廼栾鐛弍𠇁弢㫞䢮𡌺强𦢈𢏐彘𢑱彣鞽𦹮彲鍀𨨶徧嶶㵟𥉐𡽪𧃸𢙨釖𠊞𨨩怱暅𡡷㥣㷇㘹垐𢞴祱㹀悞悤悳𤦂𤦏𧩓璤僡媠慤萤慂慈𦻒憁凴𠙖憇宪𣾷\"],[\"fca1\",\"𢡟懓𨮝𩥝懐㤲𢦀𢣁怣慜攞掋𠄘担𡝰拕𢸍捬𤧟㨗搸揸𡎎𡟼撐澊𢸶頔𤂌𥜝擡擥鑻㩦携㩗敍漖𤨨𤨣斅敭敟𣁾斵𤥀䬷旑䃘𡠩无旣忟𣐀昘𣇷𣇸晄𣆤𣆥晋𠹵晧𥇦晳晴𡸽𣈱𨗴𣇈𥌓矅𢣷馤朂𤎜𤨡㬫槺𣟂杞杧杢𤇍𩃭柗䓩栢湐鈼栁𣏦𦶠桝\"],[\"fd40\",\"𣑯槡樋𨫟楳棃𣗍椁椀㴲㨁𣘼㮀枬楡𨩊䋼椶榘㮡𠏉荣傐槹𣙙𢄪橅𣜃檝㯳枱櫈𩆜㰍欝𠤣惞欵歴𢟍溵𣫛𠎵𡥘㝀吡𣭚毡𣻼毜氷𢒋𤣱𦭑汚舦汹𣶼䓅𣶽𤆤𤤌𤤀\"],[\"fda1\",\"𣳉㛥㳫𠴲鮃𣇹𢒑羏样𦴥𦶡𦷫涖浜湼漄𤥿𤂅𦹲蔳𦽴凇沜渝萮𨬡港𣸯瑓𣾂秌湏媑𣁋濸㜍澝𣸰滺𡒗𤀽䕕鏰潄潜㵎潴𩅰㴻澟𤅄濓𤂑𤅕𤀹𣿰𣾴𤄿凟𤅖𤅗𤅀𦇝灋灾炧炁烌烕烖烟䄄㷨熴熖𤉷焫煅媈煊煮岜𤍥煏鍢𤋁焬𤑚𤨧𤨢熺𨯨炽爎\"],[\"fe40\",\"鑂爕夑鑃爤鍁𥘅爮牀𤥴梽牕牗㹕𣁄栍漽犂猪猫𤠣𨠫䣭𨠄猨献珏玪𠰺𦨮珉瑉𤇢𡛧𤨤昣㛅𤦷𤦍𤧻珷琕椃𤨦琹𠗃㻗瑜𢢭瑠𨺲瑇珤瑶莹瑬㜰瑴鏱樬璂䥓𤪌\"],[\"fea1\",\"𤅟𤩹𨮏孆𨰃𡢞瓈𡦈甎瓩甞𨻙𡩋寗𨺬鎅畍畊畧畮𤾂㼄𤴓疎瑝疞疴瘂瘬癑癏癯癶𦏵皐臯㟸𦤑𦤎皡皥皷盌𦾟葢𥂝𥅽𡸜眞眦着撯𥈠睘𣊬瞯𨥤𨥨𡛁矴砉𡍶𤨒棊碯磇磓隥礮𥗠磗礴碱𧘌辸袄𨬫𦂃𢘜禆褀椂禀𥡗禝𧬹礼禩渪𧄦㺨秆𩄍秔\"]]");

/***/ }),
/* 434 */
/***/ (function(module, exports) {

/* (ignored) */

/***/ }),
/* 435 */
/***/ (function(module, exports) {

/* (ignored) */

/***/ }),
/* 436 */
/***/ (function(module, exports) {

module.exports = function isBuffer(arg) {
  return arg && typeof arg === 'object'
    && typeof arg.copy === 'function'
    && typeof arg.fill === 'function'
    && typeof arg.readUInt8 === 'function';
}

/***/ }),
/* 437 */
/***/ (function(module, exports) {

if (typeof Object.create === 'function') {
  // implementation from standard node.js 'util' module
  module.exports = function inherits(ctor, superCtor) {
    ctor.super_ = superCtor
    ctor.prototype = Object.create(superCtor.prototype, {
      constructor: {
        value: ctor,
        enumerable: false,
        writable: true,
        configurable: true
      }
    });
  };
} else {
  // old school shim for old browsers
  module.exports = function inherits(ctor, superCtor) {
    ctor.super_ = superCtor
    var TempCtor = function () {}
    TempCtor.prototype = superCtor.prototype
    ctor.prototype = new TempCtor()
    ctor.prototype.constructor = ctor
  }
}


/***/ }),
/* 438 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * In Twig, a hash is considered a pure array, i.e. a non-keyed array, if its keys form a (xn = n) sequence -i.e. 0,1,2,3,4...
 *
 * @param map
 */
function isPureArray(map) {
    let result = true;
    let keys = Array.from(map.keys());
    let i = 0;
    while (result && (i < keys.length)) {
        let key = keys[i];
        result = (Number(key) === i);
        i++;
    }
    return result;
}
exports.isPureArray = isPureArray;


/***/ }),
/* 439 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function json_encode(mixedVal) {
  // eslint-disable-line camelcase
  //       discuss at: http://phpjs.org/functions/json_encode/
  //      original by: Public Domain (http://www.json.org/json2.js)
  // reimplemented by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
  //      improved by: Michael White
  //         input by: felix
  //      bugfixed by: Brett Zamir (http://brett-zamir.me)
  //        example 1: json_encode('Kevin')
  //        returns 1: '"Kevin"'

  /*
    http://www.JSON.org/json2.js
    2008-11-19
    Public Domain.
    NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK.
    See http://www.JSON.org/js.html
  */

  var $global = typeof window !== 'undefined' ? window : global;
  $global.$locutus = $global.$locutus || {};
  var $locutus = $global.$locutus;
  $locutus.php = $locutus.php || {};

  var json = $global.JSON;
  var retVal;
  try {
    if ((typeof json === 'undefined' ? 'undefined' : _typeof(json)) === 'object' && typeof json.stringify === 'function') {
      // Errors will not be caught here if our own equivalent to resource
      retVal = json.stringify(mixedVal);
      if (retVal === undefined) {
        throw new SyntaxError('json_encode');
      }
      return retVal;
    }

    var value = mixedVal;

    var quote = function quote(string) {
      var escapeChars = ['\0-\x1F', '\x7F-\x9F', '\xAD', '\u0600-\u0604', '\u070F', '\u17B4', '\u17B5', '\u200C-\u200F', '\u2028-\u202F', '\u2060-\u206F', '\uFEFF', '\uFFF0-\uFFFF'].join('');
      var escapable = new RegExp('[\\"' + escapeChars + ']', 'g');
      var meta = {
        // table of character substitutions
        '\b': '\\b',
        '\t': '\\t',
        '\n': '\\n',
        '\f': '\\f',
        '\r': '\\r',
        '"': '\\"',
        '\\': '\\\\'
      };

      escapable.lastIndex = 0;
      return escapable.test(string) ? '"' + string.replace(escapable, function (a) {
        var c = meta[a];
        return typeof c === 'string' ? c : '\\u' + ('0000' + a.charCodeAt(0).toString(16)).slice(-4);
      }) + '"' : '"' + string + '"';
    };

    var _str = function _str(key, holder) {
      var gap = '';
      var indent = '    ';
      // The loop counter.
      var i = 0;
      // The member key.
      var k = '';
      // The member value.
      var v = '';
      var length = 0;
      var mind = gap;
      var partial = [];
      var value = holder[key];

      // If the value has a toJSON method, call it to obtain a replacement value.
      if (value && (typeof value === 'undefined' ? 'undefined' : _typeof(value)) === 'object' && typeof value.toJSON === 'function') {
        value = value.toJSON(key);
      }

      // What happens next depends on the value's type.
      switch (typeof value === 'undefined' ? 'undefined' : _typeof(value)) {
        case 'string':
          return quote(value);

        case 'number':
          // JSON numbers must be finite. Encode non-finite numbers as null.
          return isFinite(value) ? String(value) : 'null';

        case 'boolean':
        case 'null':
          // If the value is a boolean or null, convert it to a string. Note:
          // typeof null does not produce 'null'. The case is included here in
          // the remote chance that this gets fixed someday.
          return String(value);

        case 'object':
          // If the type is 'object', we might be dealing with an object or an array or
          // null.
          // Due to a specification blunder in ECMAScript, typeof null is 'object',
          // so watch out for that case.
          if (!value) {
            return 'null';
          }

          // Make an array to hold the partial results of stringifying this object value.
          gap += indent;
          partial = [];

          // Is the value an array?
          if (Object.prototype.toString.apply(value) === '[object Array]') {
            // The value is an array. Stringify every element. Use null as a placeholder
            // for non-JSON values.
            length = value.length;
            for (i = 0; i < length; i += 1) {
              partial[i] = _str(i, value) || 'null';
            }

            // Join all of the elements together, separated with commas, and wrap them in
            // brackets.
            v = partial.length === 0 ? '[]' : gap ? '[\n' + gap + partial.join(',\n' + gap) + '\n' + mind + ']' : '[' + partial.join(',') + ']';
            gap = mind;
            return v;
          }

          // Iterate through all of the keys in the object.
          for (k in value) {
            if (Object.hasOwnProperty.call(value, k)) {
              v = _str(k, value);
              if (v) {
                partial.push(quote(k) + (gap ? ': ' : ':') + v);
              }
            }
          }

          // Join all of the member texts together, separated with commas,
          // and wrap them in braces.
          v = partial.length === 0 ? '{}' : gap ? '{\n' + gap + partial.join(',\n' + gap) + '\n' + mind + '}' : '{' + partial.join(',') + '}';
          gap = mind;
          return v;
        case 'undefined':
        case 'function':
        default:
          throw new SyntaxError('json_encode');
      }
    };

    // Make a fake root object containing our value under the key of ''.
    // Return the result of stringifying the value.
    return _str('', {
      '': value
    });
  } catch (err) {
    // @todo: ensure error handling above throws a SyntaxError in all cases where it could
    // (i.e., when the JSON global is not available and there is an error)
    if (!(err instanceof SyntaxError)) {
      throw new Error('Unexpected error type in json_encode()');
    }
    // usable by json_last_error()
    $locutus.php.last_error_json = 4;
    return null;
  }
};
//# sourceMappingURL=json_encode.js.map
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 440 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


/**
 * RegexParser
 * Parses a string input.
 *
 * @name RegexParser
 * @function
 * @param {String} input The string input that should be parsed as regular
 * expression.
 * @return {RegExp} The parsed regular expression.
 */
var RegexParser = module.exports = function (input) {

    // Validate input
    if (typeof input !== "string") {
        throw new Error("Invalid input. Input must be a string");
    }

    // Parse input
    var m = input.match(/(\/?)(.+)\1([a-z]*)/i);

    // Invalid flags
    if (m[3] && !/^(?!.*?(.).*?\1)[gmixXsuUAJ]+$/.test(m[3])) {
        return RegExp(input);
    }

    // Create the regular expression
    return new RegExp(m[2], m[3]);
};

/***/ }),
/* 441 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function substr_count(haystack, needle, offset, length) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/substr_count/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // improved by: Brett Zamir (http://brett-zamir.me)
  // improved by: Thomas
  //   example 1: substr_count('Kevin van Zonneveld', 'e')
  //   returns 1: 3
  //   example 2: substr_count('Kevin van Zonneveld', 'K', 1)
  //   returns 2: 0
  //   example 3: substr_count('Kevin van Zonneveld', 'Z', 0, 10)
  //   returns 3: false

  var cnt = 0;

  haystack += '';
  needle += '';
  if (isNaN(offset)) {
    offset = 0;
  }
  if (isNaN(length)) {
    length = 0;
  }
  if (needle.length === 0) {
    return false;
  }
  offset--;

  while ((offset = haystack.indexOf(needle, offset + 1)) !== -1) {
    if (length > 0 && offset + needle.length > length) {
      return false;
    }
    cnt++;
  }

  return cnt;
};
//# sourceMappingURL=substr_count.js.map

/***/ }),
/* 442 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function addcslashes(str, charlist) {
  //  discuss at: http://locutus.io/php/addcslashes/
  // original by: Brett Zamir (http://brett-zamir.me)
  //      note 1: We show double backslashes in the return value example
  //      note 1: code below because a JavaScript string will not
  //      note 1: render them as backslashes otherwise
  //   example 1: addcslashes('foo[ ]', 'A..z'); // Escape all ASCII within capital A to lower z range, including square brackets
  //   returns 1: "\\f\\o\\o\\[ \\]"
  //   example 2: addcslashes("zoo['.']", 'z..A'); // Only escape z, period, and A here since not a lower-to-higher range
  //   returns 2: "\\zoo['\\.']"
  //   _example 3: addcslashes("@a\u0000\u0010\u00A9", "\0..\37!@\177..\377"); // Escape as octals those specified and less than 32 (0x20) or greater than 126 (0x7E), but not otherwise
  //   _returns 3: '\\@a\\000\\020\\302\\251'
  //   _example 4: addcslashes("\u0020\u007E", "\40..\175"); // Those between 32 (0x20 or 040) and 126 (0x7E or 0176) decimal value will be backslashed if specified (not octalized)
  //   _returns 4: '\\ ~'
  //   _example 5: addcslashes("\r\u0007\n", '\0..\37'); // Recognize C escape sequences if specified
  //   _returns 5: "\\r\\a\\n"
  //   _example 6: addcslashes("\r\u0007\n", '\0'); // Do not recognize C escape sequences if not specified
  //   _returns 6: "\r\u0007\n"

  var target = '';
  var chrs = [];
  var i = 0;
  var j = 0;
  var c = '';
  var next = '';
  var rangeBegin = '';
  var rangeEnd = '';
  var chr = '';
  var begin = 0;
  var end = 0;
  var octalLength = 0;
  var postOctalPos = 0;
  var cca = 0;
  var escHexGrp = [];
  var encoded = '';
  var percentHex = /%([\dA-Fa-f]+)/g;

  var _pad = function _pad(n, c) {
    if ((n = n + '').length < c) {
      return new Array(++c - n.length).join('0') + n;
    }
    return n;
  };

  for (i = 0; i < charlist.length; i++) {
    c = charlist.charAt(i);
    next = charlist.charAt(i + 1);
    if (c === '\\' && next && /\d/.test(next)) {
      // Octal
      rangeBegin = charlist.slice(i + 1).match(/^\d+/)[0];
      octalLength = rangeBegin.length;
      postOctalPos = i + octalLength + 1;
      if (charlist.charAt(postOctalPos) + charlist.charAt(postOctalPos + 1) === '..') {
        // Octal begins range
        begin = rangeBegin.charCodeAt(0);
        if (/\\\d/.test(charlist.charAt(postOctalPos + 2) + charlist.charAt(postOctalPos + 3))) {
          // Range ends with octal
          rangeEnd = charlist.slice(postOctalPos + 3).match(/^\d+/)[0];
          // Skip range end backslash
          i += 1;
        } else if (charlist.charAt(postOctalPos + 2)) {
          // Range ends with character
          rangeEnd = charlist.charAt(postOctalPos + 2);
        } else {
          throw new Error('Range with no end point');
        }
        end = rangeEnd.charCodeAt(0);
        if (end > begin) {
          // Treat as a range
          for (j = begin; j <= end; j++) {
            chrs.push(String.fromCharCode(j));
          }
        } else {
          // Supposed to treat period, begin and end as individual characters only, not a range
          chrs.push('.', rangeBegin, rangeEnd);
        }
        // Skip dots and range end (already skipped range end backslash if present)
        i += rangeEnd.length + 2;
      } else {
        // Octal is by itself
        chr = String.fromCharCode(parseInt(rangeBegin, 8));
        chrs.push(chr);
      }
      // Skip range begin
      i += octalLength;
    } else if (next + charlist.charAt(i + 2) === '..') {
      // Character begins range
      rangeBegin = c;
      begin = rangeBegin.charCodeAt(0);
      if (/\\\d/.test(charlist.charAt(i + 3) + charlist.charAt(i + 4))) {
        // Range ends with octal
        rangeEnd = charlist.slice(i + 4).match(/^\d+/)[0];
        // Skip range end backslash
        i += 1;
      } else if (charlist.charAt(i + 3)) {
        // Range ends with character
        rangeEnd = charlist.charAt(i + 3);
      } else {
        throw new Error('Range with no end point');
      }
      end = rangeEnd.charCodeAt(0);
      if (end > begin) {
        // Treat as a range
        for (j = begin; j <= end; j++) {
          chrs.push(String.fromCharCode(j));
        }
      } else {
        // Supposed to treat period, begin and end as individual characters only, not a range
        chrs.push('.', rangeBegin, rangeEnd);
      }
      // Skip dots and range end (already skipped range end backslash if present)
      i += rangeEnd.length + 2;
    } else {
      // Character is by itself
      chrs.push(c);
    }
  }

  for (i = 0; i < str.length; i++) {
    c = str.charAt(i);
    if (chrs.indexOf(c) !== -1) {
      target += '\\';
      cca = c.charCodeAt(0);
      if (cca < 32 || cca > 126) {
        // Needs special escaping
        switch (c) {
          case '\n':
            target += 'n';
            break;
          case '\t':
            target += 't';
            break;
          case '\r':
            target += 'r';
            break;
          case '\x07':
            target += 'a';
            break;
          case '\v':
            target += 'v';
            break;
          case '\b':
            target += 'b';
            break;
          case '\f':
            target += 'f';
            break;
          default:
            // target += _pad(cca.toString(8), 3);break; // Sufficient for UTF-16
            encoded = encodeURIComponent(c);

            // 3-length-padded UTF-8 octets
            if ((escHexGrp = percentHex.exec(encoded)) !== null) {
              // already added a slash above:
              target += _pad(parseInt(escHexGrp[1], 16).toString(8), 3);
            }
            while ((escHexGrp = percentHex.exec(encoded)) !== null) {
              target += '\\' + _pad(parseInt(escHexGrp[1], 16).toString(8), 3);
            }
            break;
        }
      } else {
        // Perform regular backslashed escaping
        target += c;
      }
    } else {
      // Just add the character unescaped
      target += c;
    }
  }

  return target;
};
//# sourceMappingURL=addcslashes.js.map

/***/ }),
/* 443 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const environment_1 = __webpack_require__(444);
const null_1 = __webpack_require__(148);
class TwingEnvironmentBrowser extends environment_1.TwingEnvironment {
    cacheFromString(cache) {
        return new null_1.TwingCacheNull();
    }
}
exports.TwingEnvironmentBrowser = TwingEnvironmentBrowser;


/***/ }),
/* 444 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_set_1 = __webpack_require__(255);
const core_1 = __webpack_require__(257);
const lexer_1 = __webpack_require__(185);
const parser_1 = __webpack_require__(339);
const source_1 = __webpack_require__(130);
const loader_1 = __webpack_require__(140);
const syntax_1 = __webpack_require__(112);
const escaper_1 = __webpack_require__(343);
const template_1 = __webpack_require__(123);
const error_1 = __webpack_require__(120);
const template_wrapper_1 = __webpack_require__(188);
const array_1 = __webpack_require__(350);
const chain_1 = __webpack_require__(351);
const optimizer_1 = __webpack_require__(352);
const compiler_1 = __webpack_require__(253);
const null_1 = __webpack_require__(148);
const runtime_1 = __webpack_require__(153);
const merge_1 = __webpack_require__(135);
const events_1 = __webpack_require__(24);
const output_buffering_1 = __webpack_require__(131);
const clone_1 = __webpack_require__(354);
const compare_1 = __webpack_require__(175);
const count_1 = __webpack_require__(177);
const each_1 = __webpack_require__(145);
const is_countable_1 = __webpack_require__(247);
const is_map_1 = __webpack_require__(147);
const is_plain_object_1 = __webpack_require__(510);
const iterator_to_map_1 = __webpack_require__(128);
const regex_parser_1 = __webpack_require__(251);
const markup_1 = __webpack_require__(162);
const range_1 = __webpack_require__(202);
const profile_1 = __webpack_require__(206);
const security_error_1 = __webpack_require__(125);
const security_not_allowed_filter_error_1 = __webpack_require__(207);
const security_not_allowed_function_error_1 = __webpack_require__(208);
const security_not_allowed_tag_error_1 = __webpack_require__(209);
const context_1 = __webpack_require__(264);
const path = __webpack_require__(349);
const sha256 = __webpack_require__(149);
const hex = __webpack_require__(150);
exports.VERSION = '2.3.7';
/**
 * Stores the Twing configuration.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingEnvironment extends events_1.EventEmitter {
    /**
     * Constructor.
     *
     * @param {TwingLoaderInterface} loader
     * @param {TwingEnvironmentOptions} options
     */
    constructor(loader, options = null) {
        super();
        this.loader = null;
        this.globals = new Map();
        this.loadedTemplates = new Map();
        this.templateClassPrefix = '__TwingTemplate_';
        this.extensionSet = null;
        this.runtimeLoaders = [];
        this.runtimes = new Map();
        this.setLoader(loader);
        options = Object.assign({}, {
            debug: false,
            charset: 'UTF-8',
            base_template_class: 'TwingTemplate',
            strict_variables: false,
            autoescape: 'html',
            cache: false,
            auto_reload: null,
            optimizations: -1,
            source_map: false
        }, options);
        this.debug = options.debug;
        this.setCharset(options.charset);
        this.baseTemplateClass = options.base_template_class;
        this.autoReload = options.auto_reload === null ? this.debug : options.auto_reload;
        this.strictVariables = options.strict_variables;
        this.setCache(options.cache);
        this.extensionSet = new extension_set_1.TwingExtensionSet();
        this.sourceMap = options.source_map;
        this.autoescape = options.autoescape;
        this.addExtension(new core_1.TwingExtensionCore(), 'TwingExtensionCore');
        this.addExtension(new escaper_1.TwingExtensionEscaper(options.autoescape), 'TwingExtensionEscaper');
        this.addExtension(new optimizer_1.TwingExtensionOptimizer(options.optimizations), 'TwingExtensionOptimizer');
        this.setTemplateRuntime({
            clone: clone_1.clone,
            compare: compare_1.compare,
            count: count_1.count,
            each: each_1.each,
            isCountable: is_countable_1.isCountable,
            isMap: is_map_1.isMap,
            isPlainObject: is_plain_object_1.isPlainObject,
            iteratorToMap: iterator_to_map_1.iteratorToMap,
            merge: merge_1.merge,
            regexParser: regex_parser_1.regexParser,
            TwingErrorLoader: loader_1.TwingErrorLoader,
            TwingErrorRuntime: runtime_1.TwingErrorRuntime,
            twingArrayMerge: core_1.twingArrayMerge,
            twingConstant: core_1.twingConstant,
            twingEnsureTraversable: core_1.twingEnsureTraversable,
            twingGetAttribute: core_1.twingGetAttribute,
            twingInFilter: core_1.twingInFilter,
            TwingMarkup: markup_1.TwingMarkup,
            echo: output_buffering_1.echo,
            flush: output_buffering_1.flush,
            obEndClean: output_buffering_1.obEndClean,
            obGetClean: output_buffering_1.obGetClean,
            obGetContents: output_buffering_1.obGetContents,
            obStart: output_buffering_1.obStart,
            range: range_1.range,
            TwingSandboxSecurityError: security_error_1.TwingSandboxSecurityError,
            TwingSandboxSecurityNotAllowedFilterError: security_not_allowed_filter_error_1.TwingSandboxSecurityNotAllowedFilterError,
            TwingSandboxSecurityNotAllowedFunctionError: security_not_allowed_function_error_1.TwingSandboxSecurityNotAllowedFunctionError,
            TwingSandboxSecurityNotAllowedTagError: security_not_allowed_tag_error_1.TwingSandboxSecurityNotAllowedTagError,
            TwingSource: source_1.TwingSource,
            TwingTemplate: template_1.TwingTemplate,
            TwingProfilerProfile: profile_1.TwingProfilerProfile,
            TwingContext: context_1.TwingContext
        });
    }
    /**
     * Gets the base template class for compiled templates.
     *
     * @returns {string} The base template class name
     */
    getBaseTemplateClass() {
        return this.baseTemplateClass;
    }
    /**
     * Sets the base template class for compiled templates.
     *
     * @param {string} templateClass The base template class name
     */
    setBaseTemplateClass(templateClass) {
        this.baseTemplateClass = templateClass;
        this.updateOptionsHash();
    }
    /**
     * Enables debugging mode.
     */
    enableDebug() {
        this.debug = true;
        this.updateOptionsHash();
    }
    /**
     * Disables debugging mode.
     */
    disableDebug() {
        this.debug = false;
        this.updateOptionsHash();
    }
    /**
     * Checks if debug mode is enabled.
     *
     * @returns {boolean} true if debug mode is enabled, false otherwise
     */
    isDebug() {
        return this.debug;
    }
    /**
     * Enables the auto_reload option.
     */
    enableAutoReload() {
        this.autoReload = true;
    }
    /**
     * Disables the auto_reload option.
     */
    disableAutoReload() {
        this.autoReload = false;
    }
    /**
     * Checks if the auto_reload option is enabled.
     *
     * @returns {boolean} true if auto_reload is enabled, false otherwise
     */
    isAutoReload() {
        return this.autoReload;
    }
    /**
     * Enables the strict_variables option.
     */
    enableStrictVariables() {
        this.strictVariables = true;
        this.updateOptionsHash();
    }
    /**
     * Disables the strict_variables option.
     */
    disableStrictVariables() {
        this.strictVariables = false;
        this.updateOptionsHash();
    }
    /**
     * Checks if the strict_variables option is enabled.
     *
     * @returns {boolean} true if strict_variables is enabled, false otherwise
     */
    isStrictVariables() {
        return this.strictVariables;
    }
    /**
     * Gets the active cache implementation.
     *
     * @param {boolean} original Whether to return the original cache option or the real cache instance
     *
     * @returns {TwingCacheInterface|string|false} A TwingCacheInterface implementation,
     *                                                an absolute path to the compiled templates,
     *                                                or false to disable cache
     */
    getCache(original = true) {
        return original ? this.originalCache : this.cache;
    }
    /**
     * Sets the active cache implementation.
     *
     * @param {TwingCacheInterface|string|false} cache A TwingCacheInterface implementation, a string or false to disable cache
     */
    setCache(cache) {
        if (typeof cache === 'string') {
            this.originalCache = cache;
            this.cache = this.cacheFromString(cache);
        }
        else if (cache === false) {
            this.originalCache = cache;
            this.cache = new null_1.TwingCacheNull();
        }
        else if (cache.TwingCacheInterfaceImpl) {
            this.originalCache = this.cache = cache;
        }
        else {
            throw new Error(`Cache can only be a string, false or a TwingCacheInterface implementation.`);
        }
    }
    setTemplateRuntime(runtime) {
        this.templateRuntime = runtime;
    }
    getTemplateRuntime() {
        return this.templateRuntime;
    }
    /**
     * Gets the template class associated with the given string.
     *
     * The generated template class is based on the following parameters:
     *
     *  * The cache key for the given template;
     *  * The currently enabled extensions;
     *  * Twing version;
     *  * Options with what environment was created.
     *
     * @param {string} name The name for which to calculate the template class name
     * @param {number|null} index The index if it is an embedded template
     * @param {TwingSource} from The source that initiated the template loading
     *
     * @return string The template class name
     */
    getTemplateClass(name, index = null, from = null) {
        let key = this.getLoader().getCacheKey(name, from) + this.optionsHash;
        return this.templateClassPrefix + hex.stringify(sha256(key)) + (index === null ? '' : '_' + index);
    }
    /**
     * Checks if the source_map option is enabled.
     *
     * @returns {boolean} true if source_map is enabled, false otherwise
     */
    isSourceMap() {
        return this.sourceMap;
    }
    /**
     * Renders a template.
     *
     * @param {string} name The template name
     * @param {{}} context An array of parameters to pass to the template
     * @returns {Promise<string>}
     */
    render(name, context = {}) {
        return this.loadTemplate(name).render(context);
    }
    /**
     * Displays a template.
     *
     * @param {string} name The template name
     * @param {{}} context An array of parameters to pass to the template
     *
     * @throws TwingErrorLoader  When the template cannot be found
     * @throws TwingErrorSyntax  When an error occurred during compilation
     * @throws TwingErrorRuntime When an error occurred during rendering
     */
    display(name, context = {}) {
        this.loadTemplate(name).display(context);
    }
    /**
     * Loads a template.
     *
     * @param {string | TwingTemplateWrapper | TwingTemplate} name The template name
     *
     * @throws {TwingErrorLoader}  When the template cannot be found
     * @throws {TwingErrorRuntime} When a previously generated cache is corrupted
     * @throws {TwingErrorSyntax}  When an error occurred during compilation
     *
     * @returns {TwingTemplateWrapper}
     */
    load(name) {
        if (name instanceof template_wrapper_1.TwingTemplateWrapper) {
            return name;
        }
        if (name instanceof template_1.TwingTemplate) {
            return new template_wrapper_1.TwingTemplateWrapper(this, name);
        }
        return new template_wrapper_1.TwingTemplateWrapper(this, this.loadTemplate(name));
    }
    /**
     * Loads a template internal representation.
     *
     * This method is for internal use only and should never be called
     * directly.
     *
     * @param {string} name  The template name
     * @param {number} index The index if it is an embedded template
     * @param {TwingSource} from The source that initiated the template loading
     *
     * @returns {TwingTemplate} A template instance representing the given template name
     *
     * @throws {TwingErrorLoader}  When the template cannot be found
     * @throws {TwingErrorRuntime} When a previously generated cache is corrupted
     * @throws {TwingErrorSyntax}  When an error occurred during compilation
     *
     * @internal
     */
    loadTemplate(name, index = null, from = null) {
        this.emit('template', name, from);
        let cls = this.getTemplateClass(name, null, from);
        let mainCls = cls;
        if (index !== null) {
            cls = `${cls}_${index}`;
        }
        if (this.loadedTemplates.has(cls)) {
            return this.loadedTemplates.get(cls);
        }
        let cache = this.cache;
        let key = cache.generateKey(name, mainCls);
        let templates = {};
        let runtime = this.getTemplateRuntime();
        if (!this.isAutoReload() || this.isTemplateFresh(name, cache.getTimestamp(key), from)) {
            templates = cache.load(key)(runtime);
        }
        if (!templates[cls]) {
            let source = this.getLoader().getSourceContext(name, from);
            let content = this.compileSource(source);
            cache.write(key, content);
            templates = cache.load(key)(runtime);
            if (!templates[cls]) {
                templates = new Function(`let module = {
    exports: undefined
};

${content}

return module.exports;

`)()(runtime);
                if (!templates[cls]) {
                    throw new runtime_1.TwingErrorRuntime(`Failed to load Twig template "${name}", index "${index}": cache is corrupted.`, -1, source);
                }
            }
        }
        // to be removed in 3.0
        this.extensionSet.initRuntime(this);
        let mainTemplate;
        for (let key in templates) {
            let Tpl = templates[key];
            let template = new Tpl(this);
            if (key === mainCls) {
                key = cls;
                mainTemplate = template;
            }
            this.loadedTemplates.set(key, template);
        }
        return mainTemplate;
    }
    /**
     * Creates a template from source.
     *
     * This method should not be used as a generic way to load templates.
     *
     * @param {string} template The template name
     * @param {string} name An optional name for the template to be used in error messages
     *
     * @returns {TwingTemplate} A template instance representing the given template name
     *
     * @throws TwingErrorLoader When the template cannot be found
     * @throws TwingErrorSyntax When an error occurred during compilation
     */
    createTemplate(template, name = null) {
        let result;
        let hash = hex.stringify(sha256(template));
        if (name !== null) {
            name = `${name} (string template ${hash})`;
        }
        else {
            name = `__string_template__${hash}`;
        }
        let current = this.getLoader();
        let loader = new chain_1.TwingLoaderChain([
            current,
            new array_1.TwingLoaderArray(new Map([[name, template]])),
        ]);
        this.setLoader(loader);
        result = this.loadTemplate(name);
        return result;
    }
    /**
     * Returns true if the template is still fresh.
     *
     * @param {string} name The template name
     * @param {number} time The last modification time of the cached template
     * @param {TwingSource} from The source that initiated the template loading
     *
     * @returns {boolean} true if the template is fresh, false otherwise
     */
    isTemplateFresh(name, time, from) {
        return this.getLoader().isFresh(name, time, from);
    }
    /**
     * Tries to load a template consecutively from an array.
     *
     * Similar to loadTemplate() but it also accepts instances of TwingTemplate and
     * TwingTemplateWrapper, and an array of templates where each is tried to be loaded.
     *
     * @param {string|TwingTemplate|TwingTemplateWrapper|Array<string|TwingTemplate>} names A template or an array of templates to try consecutively
     *
     * @returns {TwingTemplate|TwingTemplateWrapper}
     *
     * @throws {TwingErrorLoader} When none of the templates can be found
     * @throws {TwingErrorSyntax} When an error occurred during compilation
     */
    resolveTemplate(names, source = null) {
        let self = this;
        let namesArray;
        if (!Array.isArray(names)) {
            namesArray = [names];
        }
        else {
            namesArray = names;
        }
        let error = null;
        for (let name of namesArray) {
            if (name instanceof template_1.TwingTemplate) {
                return name;
            }
            if (name instanceof template_wrapper_1.TwingTemplateWrapper) {
                return name;
            }
            try {
                return self.loadTemplate(name, null, source);
            }
            catch (e) {
                if (e instanceof loader_1.TwingErrorLoader) {
                    error = e;
                }
                else {
                    throw e;
                }
            }
        }
        if (namesArray.length === 1) {
            throw error;
        }
        throw new loader_1.TwingErrorLoader(`Unable to find one of the following templates: "${namesArray.join(', ')}".`);
    }
    setLexer(lexer) {
        this.lexer = lexer;
    }
    /**
     * Tokenizes a source code.
     *
     * @param {TwingSource} source The source to tokenize
     * @returns {TwingTokenStream}
     *
     * @throws {TwingErrorSyntax} When the code is syntactically wrong
     */
    tokenize(source) {
        if (!this.lexer) {
            this.lexer = new lexer_1.TwingLexer(this);
        }
        return this.lexer.tokenize(source);
    }
    setParser(parser) {
        this.parser = parser;
    }
    /**
     * Converts a token stream to a template.
     *
     * @param {TwingTokenStream} stream
     * @returns {TwingNodeModule}
     *
     * @throws {TwingErrorSyntax} When the token stream is syntactically or semantically wrong
     */
    parse(stream) {
        if (!this.parser) {
            this.parser = new parser_1.TwingParser(this);
        }
        return this.parser.parse(stream);
    }
    /**
     * Compiles a node and returns its compiled templates.
     *
     * @returns { Map<number, TwingTemplate> } The compiled templates
     */
    compile(node) {
        let compiler = new compiler_1.TwingCompiler(this);
        return compiler.compile(node).getSource();
    }
    /**
     *
     * @param {TwingSource} source
     * @returns {Map<number, TwingTemplate> }
     */
    compileSource(source) {
        try {
            return this.compile(this.parse(this.tokenize(source)));
        }
        catch (e) {
            if (e instanceof error_1.TwingError) {
                throw e;
            }
            else {
                throw new syntax_1.TwingErrorSyntax(`An exception has been thrown during the compilation of a template ("${e.message}").`, -1, source);
            }
        }
    }
    setLoader(loader) {
        this.loader = loader;
    }
    /**
     * Gets the Loader instance.
     *
     * @return TwingLoaderInterface
     */
    getLoader() {
        return this.loader;
    }
    /**
     * Sets the default template charset.
     *
     * @param {string} charset The default charset
     */
    setCharset(charset) {
        this.charset = charset;
    }
    /**
     * Gets the default template charset.
     *
     * @return {string} The default charset
     */
    getCharset() {
        return this.charset;
    }
    /**
     * Returns true if the given extension is registered.
     *
     * @param {string} name
     * @returns {boolean}
     */
    hasExtension(name) {
        return this.extensionSet.hasExtension(name);
    }
    /**
     * Adds a runtime loader.
     */
    addRuntimeLoader(loader) {
        this.runtimeLoaders.push(loader);
    }
    /**
     * Gets an extension by name.
     *
     * @param {string} name
     * @returns {TwingExtensionInterface}
     */
    getExtension(name) {
        return this.extensionSet.getExtension(name);
    }
    /**
     * Returns the runtime implementation of a Twig element (filter/function/test).
     *
     * @param {string} class_ A runtime class name
     *
     * @returns {{}} The runtime implementation
     *
     * @throws TwingErrorRuntime When the runtime cannot be found
     */
    getRuntime(class_) {
        if (this.runtimes.has(class_)) {
            return this.runtimes.get(class_);
        }
        for (let loader of this.runtimeLoaders) {
            let runtime = loader.load(class_);
            if (runtime !== null) {
                this.runtimes.set(class_, runtime);
                return runtime;
            }
        }
        throw new runtime_1.TwingErrorRuntime(`Unable to load the "${class_}" runtime.`);
    }
    /**
     *
     * @param {TwingExtensionInterface} extension
     * @param {string} name
     */
    addExtension(extension, name = null) {
        this.extensionSet.addExtension(extension, name);
        this.updateOptionsHash();
    }
    /**
     * Registers an array of extensions.
     *
     * @param {Array<TwingExtensionInterface>} extensions An array of extensions
     */
    setExtensions(extensions) {
        this.extensionSet.setExtensions(extensions);
        this.updateOptionsHash();
    }
    /**
     * Returns all registered extensions.
     *
     * @returns Map<string, TwingExtensionInterface> A hash of extensions (keys are for internal usage only and should not be relied on)
     */
    getExtensions() {
        return this.extensionSet.getExtensions();
    }
    addTokenParser(parser) {
        this.extensionSet.addTokenParser(parser);
    }
    /**
     * Gets the registered Token Parsers.
     *
     * @returns {Array<TwingTokenParserInterface>}
     *
     * @internal
     */
    getTokenParsers() {
        return this.extensionSet.getTokenParsers();
    }
    /**
     * Gets registered tags.
     *
     * @return Map<string, TwingTokenParserInterface>
     *
     * @internal
     */
    getTags() {
        let tags = new Map();
        this.getTokenParsers().forEach(function (parser) {
            tags.set(parser.getTag(), parser);
        });
        return tags;
    }
    addNodeVisitor(visitor) {
        this.extensionSet.addNodeVisitor(visitor);
    }
    /**
     * Gets the registered Node Visitors.
     *
     * @returns {Array<TwingNodeVisitorInterface>}
     *
     * @internal
     */
    getNodeVisitors() {
        return this.extensionSet.getNodeVisitors();
    }
    addFilter(filter) {
        this.extensionSet.addFilter(filter);
    }
    /**
     * Get a filter by name.
     *
     * Subclasses may override this method and load filters differently;
     * so no list of filters is available.
     *
     * @param string name The filter name
     *
     * @return Twig_Filter|false A Twig_Filter instance or null if the filter does not exist
     *
     * @internal
     */
    getFilter(name) {
        return this.extensionSet.getFilter(name);
    }
    registerUndefinedFilterCallback(callable) {
        this.extensionSet.registerUndefinedFilterCallback(callable);
    }
    /**
     * Gets the registered Filters.
     *
     * Be warned that this method cannot return filters defined with registerUndefinedFilterCallback.
     *
     * @return Twig_Filter[]
     *
     * @see registerUndefinedFilterCallback
     *
     * @internal
     */
    getFilters() {
        return this.extensionSet.getFilters();
    }
    /**
     * Registers a Test.
     *
     * @param {TwingTest} test
     */
    addTest(test) {
        this.extensionSet.addTest(test);
    }
    /**
     * Gets the registered Tests.
     *
     * @returns {Map<string, TwingTest>}
     */
    getTests() {
        return this.extensionSet.getTests();
    }
    /**
     * Gets a test by name.
     *
     * @param {string} name The test name
     * @returns {TwingTest} A TwingTest instance or null if the test does not exist
     */
    getTest(name) {
        return this.extensionSet.getTest(name);
    }
    addFunction(aFunction) {
        this.extensionSet.addFunction(aFunction);
    }
    /**
     * Get a function by name.
     *
     * Subclasses may override this method and load functions differently;
     * so no list of functions is available.
     *
     * @param {string} name function name
     *
     * @returns {TwingFunction} A TwingFunction instance or null if the function does not exist
     *
     * @internal
     */
    getFunction(name) {
        return this.extensionSet.getFunction(name);
    }
    registerUndefinedFunctionCallback(callable) {
        this.extensionSet.registerUndefinedFunctionCallback(callable);
    }
    /**
     * Gets registered functions.
     *
     * Be warned that this method cannot return functions defined with registerUndefinedFunctionCallback.
     *
     * @return Twig_Function[]
     *
     * @see registerUndefinedFunctionCallback
     *
     * @internal
     */
    getFunctions() {
        return this.extensionSet.getFunctions();
    }
    /**
     * Registers a Global.
     *
     * New globals can be added before compiling or rendering a template;
     * but after, you can only update existing globals.
     *
     * @param {string} name The global name
     * @param {*} value The global value
     */
    addGlobal(name, value) {
        if (this.extensionSet.isInitialized() && !this.getGlobals().has(name)) {
            throw new Error(`Unable to add global "${name}" as the runtime or the extensions have already been initialized.`);
        }
        if (this.resolvedGlobals) {
            this.resolvedGlobals.set(name, value);
        }
        else {
            this.globals.set(name, value);
        }
    }
    /**
     * Gets the registered Globals.
     *
     * @return array An array of globals
     *
     * @internal
     */
    getGlobals() {
        if (this.extensionSet.isInitialized()) {
            if (!this.resolvedGlobals) {
                this.resolvedGlobals = merge_1.merge(this.extensionSet.getGlobals(), this.globals);
            }
            return this.resolvedGlobals;
        }
        return merge_1.merge(this.extensionSet.getGlobals(), this.globals);
    }
    /**
     * Merges a context with the defined globals.
     *
     * @param {Map<*, *>} context
     * @returns {Map<*, *>}
     */
    mergeGlobals(context) {
        // we don't use Twing merge as the context being generally
        // bigger than globals, this code is faster.
        for (let [key, value] of this.getGlobals()) {
            if (!context.has(key)) {
                context.set(key, value);
            }
        }
        return context;
    }
    /**
     * Gets the registered unary Operators.
     *
     * @return Map<string, TwingOperator> A map of unary operators
     *
     * @internal
     */
    getUnaryOperators() {
        return this.extensionSet.getUnaryOperators();
    }
    /**
     * Gets the registered binary Operators.
     *
     * @return Map<string, TwingOperator> An array of binary operators
     *
     * @internal
     */
    getBinaryOperators() {
        return this.extensionSet.getBinaryOperators();
    }
    updateOptionsHash() {
        this.optionsHash = [
            this.extensionSet.getSignature(),
            exports.VERSION,
            this.debug,
            this.baseTemplateClass,
            this.strictVariables,
            this.sourceMap,
            typeof this.autoescape === 'function' ? 'function' : this.autoescape
        ].join(':');
    }
    /**
     * @param {number} line 0-based
     * @param {number} column 1-based
     * @param {string} name
     * @param {TwingSource} source
     * @param {TwingSourceMapNodeConstructor} ctor
     */
    enterSourceMapBlock(line, column, name, source, ctor) {
        output_buffering_1.TwingOutputBuffering.obStart();
        let sourcePath = path.relative('.', source.getPath());
        if (typeof this.sourceMap === 'string') {
            sourcePath = path.join(this.sourceMap, sourcePath);
        }
        source = new source_1.TwingSource(source.getCode(), source.getName(), sourcePath);
        let node = new ctor(line, column - 1, source, name);
        if (this.sourceMapNode) {
            this.sourceMapNode.addChild(node);
        }
        this.sourceMapNode = node;
    }
    leaveSourceMapBlock() {
        this.sourceMapNode.content = output_buffering_1.TwingOutputBuffering.obGetFlush();
        let parent = this.sourceMapNode.parent;
        if (parent) {
            this.sourceMapNode = parent;
        }
    }
    getSourceMap() {
        let sourceMap = null;
        if (this.isSourceMap() && this.sourceMapNode) {
            let sourceNode = this.sourceMapNode.toSourceNode();
            let codeAndMap = sourceNode.toStringWithSourceMap();
            sourceMap = codeAndMap.map.toString();
        }
        return sourceMap;
    }
}
exports.TwingEnvironment = TwingEnvironment;


/***/ }),
/* 445 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function var_export(mixedExpression, boolReturn) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/var_export/
  // original by: Philip Peterson
  // improved by: johnrembo
  // improved by: Brett Zamir (http://brett-zamir.me)
  //    input by: Brian Tafoya (http://www.premasolutions.com/)
  //    input by: Hans Henrik (http://hanshenrik.tk/)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  //   example 1: var_export(null)
  //   returns 1: null
  //   example 2: var_export({0: 'Kevin', 1: 'van', 2: 'Zonneveld'}, true)
  //   returns 2: "array (\n  0 => 'Kevin',\n  1 => 'van',\n  2 => 'Zonneveld'\n)"
  //   example 3: var data = 'Kevin'
  //   example 3: var_export(data, true)
  //   returns 3: "'Kevin'"

  var echo = __webpack_require__(446);
  var retstr = '';
  var iret = '';
  var value;
  var cnt = 0;
  var x = [];
  var i = 0;
  var funcParts = [];
  // We use the last argument (not part of PHP) to pass in
  // our indentation level
  var idtLevel = arguments[2] || 2;
  var innerIndent = '';
  var outerIndent = '';
  var getFuncName = function getFuncName(fn) {
    var name = /\W*function\s+([\w$]+)\s*\(/.exec(fn);
    if (!name) {
      return '(Anonymous)';
    }
    return name[1];
  };

  var _makeIndent = function _makeIndent(idtLevel) {
    return new Array(idtLevel + 1).join(' ');
  };
  var __getType = function __getType(inp) {
    var i = 0;
    var match;
    var types;
    var cons;
    var type = typeof inp === 'undefined' ? 'undefined' : _typeof(inp);
    if (type === 'object' && inp && inp.constructor && getFuncName(inp.constructor) === 'LOCUTUS_Resource') {
      return 'resource';
    }
    if (type === 'function') {
      return 'function';
    }
    if (type === 'object' && !inp) {
      // Should this be just null?
      return 'null';
    }
    if (type === 'object') {
      if (!inp.constructor) {
        return 'object';
      }
      cons = inp.constructor.toString();
      match = cons.match(/(\w+)\(/);
      if (match) {
        cons = match[1].toLowerCase();
      }
      types = ['boolean', 'number', 'string', 'array'];
      for (i = 0; i < types.length; i++) {
        if (cons === types[i]) {
          type = types[i];
          break;
        }
      }
    }
    return type;
  };
  var type = __getType(mixedExpression);

  if (type === null) {
    retstr = 'NULL';
  } else if (type === 'array' || type === 'object') {
    outerIndent = _makeIndent(idtLevel - 2);
    innerIndent = _makeIndent(idtLevel);
    for (i in mixedExpression) {
      value = var_export(mixedExpression[i], 1, idtLevel + 2);
      value = typeof value === 'string' ? value.replace(/</g, '&lt;').replace(/>/g, '&gt;') : value;
      x[cnt++] = innerIndent + i + ' => ' + (__getType(mixedExpression[i]) === 'array' ? '\n' : '') + value;
    }
    iret = x.join(',\n');
    retstr = outerIndent + 'array (\n' + iret + '\n' + outerIndent + ')';
  } else if (type === 'function') {
    funcParts = mixedExpression.toString().match(/function .*?\((.*?)\) \{([\s\S]*)\}/);

    // For lambda functions, var_export() outputs such as the following:
    // '\000lambda_1'. Since it will probably not be a common use to
    // expect this (unhelpful) form, we'll use another PHP-exportable
    // construct, create_function() (though dollar signs must be on the
    // variables in JavaScript); if using instead in JavaScript and you
    // are using the namespaced version, note that create_function() will
    // not be available as a global
    retstr = "create_function ('" + funcParts[1] + "', '" + funcParts[2].replace(new RegExp("'", 'g'), "\\'") + "')";
  } else if (type === 'resource') {
    // Resources treated as null for var_export
    retstr = 'NULL';
  } else {
    retstr = typeof mixedExpression !== 'string' ? mixedExpression : "'" + mixedExpression.replace(/(["'])/g, '\\$1').replace(/\0/g, '\\0') + "'";
  }

  if (!boolReturn) {
    echo(retstr);
    return null;
  }

  return retstr;
};
//# sourceMappingURL=var_export.js.map

/***/ }),
/* 446 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function echo() {
  //  discuss at: http://locutus.io/php/echo/
  // original by: Philip Peterson
  // improved by: echo is bad
  // improved by: Nate
  // improved by: Brett Zamir (http://brett-zamir.me)
  // improved by: Brett Zamir (http://brett-zamir.me)
  // improved by: Brett Zamir (http://brett-zamir.me)
  //  revised by: Der Simon (http://innerdom.sourceforge.net/)
  // bugfixed by: Eugene Bulkin (http://doubleaw.com/)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: EdorFaus
  //      note 1: In 1.3.2 and earlier, this function wrote to the body of the document when it
  //      note 1: was called in webbrowsers, in addition to supporting XUL.
  //      note 1: This involved >100 lines of boilerplate to do this in a safe way.
  //      note 1: Since I can't imageine a complelling use-case for this, and XUL is deprecated
  //      note 1: I have removed this behavior in favor of just calling `console.log`
  //      note 2: You'll see functions depends on `echo` instead of `console.log` as we'll want
  //      note 2: to have 1 contact point to interface with the outside world, so that it's easy
  //      note 2: to support other ways of printing output.
  //  revised by: Kevin van Zonneveld (http://kvz.io)
  //    input by: JB
  //   example 1: echo('Hello world')
  //   returns 1: undefined

  var args = Array.prototype.slice.call(arguments);
  return console.log(args.join(' '));
};
//# sourceMappingURL=echo.js.map

/***/ }),
/* 447 */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_RESULT__;(function(root, factory){
  if (true) {
    !(__WEBPACK_AMD_DEFINE_RESULT__ = (function(){
      return factory(root);
    }).call(exports, __webpack_require__, exports, module),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
  } else {}
}(this, function(root){

  function forEach( array, fn ) { var i, length
    i = -1
    length = array.length
    while ( ++i < length )
      fn( array[ i ], i, array )
  }

  function map( array, fn ) { var result
    result = Array( array.length )
    forEach( array, function ( val, i, array ) {
      result[i] = fn( val, i, array )
    })
    return result
  }

  function reduce( array, fn, accumulator ) {
    forEach( array, function( val, i, array ) {
      accumulator = fn( val, i, array )
    })
    return accumulator
  }

  // Levenshtein distance
  function Levenshtein( str_m, str_n ) { var previous, current, matrix
    // Constructor
    matrix = this._matrix = []

    // Sanity checks
    if ( str_m == str_n )
      return this.distance = 0
    else if ( str_m == '' )
      return this.distance = str_n.length
    else if ( str_n == '' )
      return this.distance = str_m.length
    else {
      // Danger Will Robinson
      previous = [ 0 ]
      forEach( str_m, function( v, i ) { i++, previous[ i ] = i } )

      matrix[0] = previous
      forEach( str_n, function( n_val, n_idx ) {
        current = [ ++n_idx ]
        forEach( str_m, function( m_val, m_idx ) {
          m_idx++
          if ( str_m.charAt( m_idx - 1 ) == str_n.charAt( n_idx - 1 ) )
            current[ m_idx ] = previous[ m_idx - 1 ]
          else
            current[ m_idx ] = Math.min
              ( previous[ m_idx ]     + 1   // Deletion
              , current[  m_idx - 1 ] + 1   // Insertion
              , previous[ m_idx - 1 ] + 1   // Subtraction
              )
        })
        previous = current
        matrix[ matrix.length ] = previous
      })

      return this.distance = current[ current.length - 1 ]
    }
  }

  Levenshtein.prototype.toString = Levenshtein.prototype.inspect = function inspect ( no_print ) { var matrix, max, buff, sep, rows
    matrix = this.getMatrix()
    max = reduce( matrix,function( m, o ) {
      return Math.max( m, reduce( o, Math.max, 0 ) )
    }, 0 )
    buff = Array( ( max + '' ).length ).join( ' ' )

    sep = []
    while ( sep.length < (matrix[0] && matrix[0].length || 0) )
      sep[ sep.length ] = Array( buff.length + 1 ).join( '-' )
    sep = sep.join( '-+' ) + '-'

    rows = map( matrix, function( row ) { var cells
      cells = map( row, function( cell ) {
        return ( buff + cell ).slice( - buff.length )
      })
      return cells.join( ' |' ) + ' '
    })

    return rows.join( "\n" + sep + "\n" )
  }

  Levenshtein.prototype.getMatrix = function () {
    return this._matrix.slice()
  }

  Levenshtein.prototype.valueOf = function() {
    return this.distance
  }

  return Levenshtein

}));


/***/ }),
/* 448 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function preg_quote(str, delimiter) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/preg_quote/
  // original by: booeyOH
  // improved by: Ates Goral (http://magnetiq.com)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  //   example 1: preg_quote("$40")
  //   returns 1: '\\$40'
  //   example 2: preg_quote("*RRRING* Hello?")
  //   returns 2: '\\*RRRING\\* Hello\\?'
  //   example 3: preg_quote("\\.+*?[^]$(){}=!<>|:")
  //   returns 3: '\\\\\\.\\+\\*\\?\\[\\^\\]\\$\\(\\)\\{\\}\\=\\!\\<\\>\\|\\:'

  return (str + '').replace(new RegExp('[.\\\\+*?\\[\\^\\]$(){}=!<>|:\\' + (delimiter || '') + '-]', 'g'), '\\$&');
};
//# sourceMappingURL=preg_quote.js.map

/***/ }),
/* 449 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Check whether a string consists of numerical character(s) only.
 *
 * @param {string} value
 * @return boolean
 */
function ctypeDigit(value) {
    let regExp = /^\d+$/;
    return regExp.test(value);
}
exports.ctypeDigit = ctypeDigit;


/***/ }),
/* 450 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function array_chunk(input, size, preserveKeys) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/array_chunk/
  // original by: Carlos R. L. Rodrigues (http://www.jsfromhell.com)
  // improved by: Brett Zamir (http://brett-zamir.me)
  //      note 1: Important note: Per the ECMAScript specification,
  //      note 1: objects may not always iterate in a predictable order
  //   example 1: array_chunk(['Kevin', 'van', 'Zonneveld'], 2)
  //   returns 1: [['Kevin', 'van'], ['Zonneveld']]
  //   example 2: array_chunk(['Kevin', 'van', 'Zonneveld'], 2, true)
  //   returns 2: [{0:'Kevin', 1:'van'}, {2: 'Zonneveld'}]
  //   example 3: array_chunk({1:'Kevin', 2:'van', 3:'Zonneveld'}, 2)
  //   returns 3: [['Kevin', 'van'], ['Zonneveld']]
  //   example 4: array_chunk({1:'Kevin', 2:'van', 3:'Zonneveld'}, 2, true)
  //   returns 4: [{1: 'Kevin', 2: 'van'}, {3: 'Zonneveld'}]

  var x;
  var p = '';
  var i = 0;
  var c = -1;
  var l = input.length || 0;
  var n = [];

  if (size < 1) {
    return null;
  }

  if (Object.prototype.toString.call(input) === '[object Array]') {
    if (preserveKeys) {
      while (i < l) {
        (x = i % size) ? n[c][i] = input[i] : n[++c] = {};n[c][i] = input[i];
        i++;
      }
    } else {
      while (i < l) {
        (x = i % size) ? n[c][x] = input[i] : n[++c] = [input[i]];
        i++;
      }
    }
  } else {
    if (preserveKeys) {
      for (p in input) {
        if (input.hasOwnProperty(p)) {
          (x = i % size) ? n[c][p] = input[p] : n[++c] = {};n[c][p] = input[p];
          i++;
        }
      }
    } else {
      for (p in input) {
        if (input.hasOwnProperty(p)) {
          (x = i % size) ? n[c][x] = input[p] : n[++c] = [input[p]];
          i++;
        }
      }
    }
  }

  return n;
};
//# sourceMappingURL=array_chunk.js.map

/***/ }),
/* 451 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
/**
 * Represents an arrow function.
 */
class TwingNodeExpressionArrowFunction extends expression_1.TwingNodeExpression {
    constructor(expr, names, lineno, columnno, tag = null) {
        let nodes = new Map([
            ['expr', expr],
            ['names', names]
        ]);
        super(nodes, new Map(), lineno, columnno, tag);
    }
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .raw('(');
        let i = 0;
        for (let [k, name] of this.getNode('names').getNodes()) {
            if (i > 0) {
                compiler.raw(', ');
            }
            compiler
                .raw('$__')
                .raw(name.getAttribute('name'))
                .raw('__');
            i++;
        }
        compiler
            .raw(') => {');
        for (let [k, name] of this.getNode('names').getNodes()) {
            compiler
                .raw('context.proxy[\'')
                .raw(name.getAttribute('name'))
                .raw('\'] = $__')
                .raw(name.getAttribute('name'))
                .raw('__; ');
        }
        compiler
            .raw('return ')
            .subcompile(this.getNode('expr'))
            .raw(';}');
    }
}
exports.TwingNodeExpressionArrowFunction = TwingNodeExpressionArrowFunction;


/***/ }),
/* 452 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/**
 * @author Charlike Mike Reagent <open.source.charlike@gmail.com>
 * @copyright 2016-present @tunnckoCore/team and contributors
 * @license MIT
 */


function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }

var arrayify = _interopDefault(__webpack_require__(453));
var babylon = _interopDefault(__webpack_require__(454));
var define = _interopDefault(__webpack_require__(455));

/*!
 * parse-function <https://github.com/tunnckoCore/parse-function>
 *
 * Copyright (c) 2017 Charlike Mike Reagent <open.source.charlike@gmail.com> (https://i.am.charlike.online)
 * Released under the MIT license.
 */

/* eslint-disable jsdoc/require-param-description */
const utils = {};
utils.define = define;
utils.arrayify = arrayify;
/**
 * > Create default result object,
 * and normalize incoming arguments.
 *
 * @param  {Function|String} code
 * @return {Object} result
 * @private
 */

utils.setDefaults = function setDefaults(code) {
  const result = {
    name: null,
    body: '',
    args: [],
    params: ''
  };

  if (typeof code === 'function') {
    code = code.toString('utf8');
  }

  if (typeof code !== 'string') {
    code = ''; // makes result.isValid === false
  }

  return utils.setHiddenDefaults(result, code);
};
/**
 * > Create hidden properties into
 * the result object.
 *
 * @param  {Object} result
 * @param  {Function|String} code
 * @return {Object} result
 * @private
 */


utils.setHiddenDefaults = function setHiddenDefaults(result, code) {
  utils.define(result, 'defaults', {});
  utils.define(result, 'value', code);
  utils.define(result, 'isValid', code.length > 0);
  utils.define(result, 'isArrow', false);
  utils.define(result, 'isAsync', false);
  utils.define(result, 'isNamed', false);
  utils.define(result, 'isAnonymous', false);
  utils.define(result, 'isGenerator', false);
  utils.define(result, 'isExpression', false);
  return result;
};
/**
 * > Get needed AST tree, depending on what
 * parse method is used.
 *
 * @param  {Object} result
 * @param  {Object} opts
 * @return {Object} node
 * @private
 */


utils.getNode = function getNode(result, opts) {
  if (typeof opts.parse === 'function') {
    result.value = `(${result.value})`;
    const ast = opts.parse(result.value, opts);
    const body = ast.program && ast.program.body || ast.body;
    return body[0].expression;
  }

  return babylon.parseExpression(result.value, opts);
};

/*!
 * parse-function <https://github.com/tunnckoCore/parse-function>
 *
 * Copyright (c) 2017 Charlike Mike Reagent <open.source.charlike@gmail.com> (https://i.am.charlike.online)
 * Released under the MIT license.
 */

/* eslint-disable jsdoc/require-param-description, jsdoc/check-param-names */

/**
 * > Micro plugin to get the raw body, without the
 * surrounding curly braces. It also preserves
 * the whitespaces and newlines - they are original.
 *
 * @param  {Object} node
 * @param  {Object} result
 * @return {Object} result
 * @private
 */
var body = (app => (node, result) => {
  result.body = result.value.slice(node.body.start, node.body.end);
  const openCurly = result.body.charCodeAt(0) === 123;
  const closeCurly = result.body.charCodeAt(result.body.length - 1) === 125;

  if (openCurly && closeCurly) {
    result.body = result.body.slice(1, -1);
  }

  return result;
});

/*!
 * parse-function <https://github.com/tunnckoCore/parse-function>
 *
 * Copyright (c) 2017 Charlike Mike Reagent <open.source.charlike@gmail.com> (https://i.am.charlike.online)
 * Released under the MIT license.
 */

/* eslint-disable jsdoc/require-param-description, jsdoc/check-param-names */

/**
 * > Set couple of hidden properties and
 * the name of the given function to
 * the returned result object. Notice that
 * if function is called "anonymous" then
 * the `result.isAnonymous` would be `false`, because
 * in reality it is named function. It would be `true`
 * only when function is really anonymous and don't have
 * any name.
 *
 * @param  {Object} node
 * @param  {Object} result
 * @return {Object} result
 * @private
 */
var props = (app => (node, result) => {
  app.define(result, 'isArrow', node.type.startsWith('Arrow'));
  app.define(result, 'isAsync', node.async || false);
  app.define(result, 'isGenerator', node.generator || false);
  app.define(result, 'isExpression', node.expression || false);
  app.define(result, 'isAnonymous', node.id === null);
  app.define(result, 'isNamed', !result.isAnonymous); // if real anonymous -> set to null,
  // notice that you can name you function `anonymous`, haha
  // and it won't be "real" anonymous, so `isAnonymous` will be `false`

  result.name = result.isAnonymous ? null : node.id.name;
  return result;
});

/*!
 * parse-function <https://github.com/tunnckoCore/parse-function>
 *
 * Copyright (c) 2017 Charlike Mike Reagent <open.source.charlike@gmail.com> (https://i.am.charlike.online)
 * Released under the MIT license.
 */

/* eslint-disable jsdoc/require-param-description, jsdoc/check-param-names */

/**
 * > Micro plugin to visit each of the params
 * in the given function and collect them into
 * an `result.args` array and `result.params` string.
 *
 * @param  {Object} node
 * @param  {Object} result
 * @return {Object} result
 * @private
 */
var params = (app => (node, result) => {
  if (!node.params.length) {
    return result;
  }

  node.params.forEach(param => {
    const defaultArgsName = param.type === 'AssignmentPattern' && param.left && param.left.name;
    const restArgName = param.type === 'RestElement' && param.argument && param.argument.name;
    const name = param.name || defaultArgsName || restArgName;
    result.args.push(name);

    if (param.right && param.right.type === 'SequenceExpression') {
      let lastExpression = param.right.expressions.pop();
      result.defaults[name] = result.value.slice(lastExpression.start, lastExpression.end);
    } else {
      result.defaults[name] = param.right ? result.value.slice(param.right.start, param.right.end) : undefined;
    }
  });
  result.params = result.args.join(', ');
  return result;
});

/*!
 * parse-function <https://github.com/tunnckoCore/parse-function>
 *
 * Copyright (c) 2017 Charlike Mike Reagent <open.source.charlike@gmail.com> (https://i.am.charlike.online)
 * Released under the MIT license.
 */

/* eslint-disable jsdoc/require-param-description, jsdoc/check-param-names */
/**
 * > Default plugin that handles regular functions,
 * arrow functions, generator functions
 * and ES6 object method notation.
 *
 * @param  {Object} node
 * @param  {Object} result
 * @return {Object} resul
 * @private
 */

var initial = (app => (node, result) => {
  const isFn = node.type.endsWith('FunctionExpression');
  const isMethod = node.type === 'ObjectExpression';
  /* istanbul ignore next */

  if (!isFn && !isMethod) {
    return;
  }

  node = isMethod ? node.properties[0] : node;
  node.id = isMethod ? node.key : node.id; // babylon node.properties[0] is `ObjectMethod` that has `params` and `body`;
  // acorn node.properties[0] is `Property` that has `value`;

  if (node.type === 'Property') {
    const id = node.key;
    node = node.value;
    node.id = id;
  }

  result = props(app)(node, result);
  result = params(app)(node, result);
  result = body(app)(node, result);
  return result;
});

/*!
 * parse-function <https://github.com/tunnckoCore/parse-function>
 *
 * Copyright (c) 2017 Charlike Mike Reagent <open.source.charlike@gmail.com> (https://i.am.charlike.online)
 * Released under the MIT license.
 */

/**
 * Utilities
 */
/**
 * Core plugins
 */

/**
 * > Initializes with optional `opts` object which is passed directly
 * to the desired parser and returns an object
 * with `.use` and `.parse` methods. The default parse which
 * is used is [babylon][]'s `.parseExpression` method from `v7`.
 *
 * ```js
 * const parseFunction = require('parse-function')
 *
 * const app = parseFunction({
 *   ecmaVersion: 2017
 * })
 *
 * const fixtureFn = (a, b, c) => {
 *   a = b + c
 *   return a + 2
 * }
 *
 * const result = app.parse(fixtureFn)
 * console.log(result)
 *
 * // see more
 * console.log(result.name) // => null
 * console.log(result.isNamed) // => false
 * console.log(result.isArrow) // => true
 * console.log(result.isAnonymous) // => true
 *
 * // array of names of the arguments
 * console.log(result.args) // => ['a', 'b', 'c']
 *
 * // comma-separated names of the arguments
 * console.log(result.params) // => 'a, b, c'
 * ```
 *
 * @param  {Object} `opts` optional, merged with options passed to `.parse` method
 * @return {Object} `app` object with `.use` and `.parse` methods
 * @name   parseFunction
 * @api public
 */

function parseFunction(opts) {
  const plugins = [];
  const app = {
    /**
     * > Parse a given `code` and returns a `result` object
     * with useful properties - such as `name`, `body` and `args`.
     * By default it uses Babylon parser, but you can switch it by
     * passing `options.parse` - for example `options.parse: acorn.parse`.
     * In the below example will show how to use `acorn` parser, instead
     * of the default one.
     *
     * ```js
     * const acorn = require('acorn')
     * const parseFn = require('parse-function')
     * const app = parseFn()
     *
     * const fn = function foo (bar, baz) { return bar * baz }
     * const result = app.parse(fn, {
     *   parse: acorn.parse,
     *   ecmaVersion: 2017
     * })
     *
     * console.log(result.name) // => 'foo'
     * console.log(result.args) // => ['bar', 'baz']
     * console.log(result.body) // => ' return bar * baz '
     * console.log(result.isNamed) // => true
     * console.log(result.isArrow) // => false
     * console.log(result.isAnonymous) // => false
     * console.log(result.isGenerator) // => false
     * ```
     *
     * @param  {Function|String} `code` any kind of function or string to be parsed
     * @param  {Object} `options` directly passed to the parser - babylon, acorn, espree
     * @param  {Function} `options.parse` by default `babylon.parseExpression`,
     *                                    all `options` are passed as second argument
     *                                    to that provided function
     * @return {Object} `result` see [result section](#result) for more info
     * @name   .parse
     * @api public
     */
    parse(code, options) {
      let result = utils.setDefaults(code);

      if (!result.isValid) {
        return result;
      }

      opts = Object.assign({}, opts, options);
      const isFunction = result.value.startsWith('function');
      const isAsyncFn = result.value.startsWith('async function');
      const isAsync = result.value.startsWith('async');
      const isArrow = result.value.includes('=>');
      const isAsyncArrow = isAsync && isArrow; // eslint-disable-next-line no-useless-escape

      const isMethod = /^\*?.+\([\s\S\w\W]*\)\s*\{/i.test(result.value);

      if (!(isFunction || isAsyncFn || isAsyncArrow) && isMethod) {
        result.value = `{ ${result.value} }`;
      }

      let node = utils.getNode(result, opts);
      return plugins.reduce((res, fn) => fn(node, res) || res, result);
    },

    /**
     * > Add a plugin `fn` function for extending the API or working on the
     * AST nodes. The `fn` is immediately invoked and passed
     * with `app` argument which is instance of `parseFunction()` call.
     * That `fn` may return another function that
     * accepts `(node, result)` signature, where `node` is an AST node
     * and `result` is an object which will be returned [result](#result)
     * from the `.parse` method. This retuned function is called on each
     * node only when `.parse` method is called.
     *
     * _See [Plugins Architecture](#plugins-architecture) section._
     *
     * ```js
     * // plugin extending the `app`
     * app.use((app) => {
     *   app.define(app, 'hello', (place) => `Hello ${place}!`)
     * })
     *
     * const hi = app.hello('World')
     * console.log(hi) // => 'Hello World!'
     *
     * // or plugin that works on AST nodes
     * app.use((app) => (node, result) => {
     *   if (node.type === 'ArrowFunctionExpression') {
     *     result.thatIsArrow = true
     *   }
     *   return result
     * })
     *
     * const result = app.parse((a, b) => (a + b + 123))
     * console.log(result.name) // => null
     * console.log(result.isArrow) // => true
     * console.log(result.thatIsArrow) // => true
     *
     * const result = app.parse(function foo () { return 123 })
     * console.log(result.name) // => 'foo'
     * console.log(result.isArrow) // => false
     * console.log(result.thatIsArrow) // => undefined
     * ```
     *
     * @param  {Function} `fn` plugin to be called
     * @return {Object} `app` instance for chaining
     * @name   .use
     * @api public
     */
    use(fn) {
      const ret = fn(app);

      if (typeof ret === 'function') {
        plugins.push(ret);
      }

      return app;
    },

    /**
     * > Define a non-enumerable property on an object. Just
     * a convenience mirror of the [define-property][] library,
     * so check out its docs. Useful to be used in plugins.
     *
     * ```js
     * const parseFunction = require('parse-function')
     * const app = parseFunction()
     *
     * // use it like `define-property` lib
     * const obj = {}
     * app.define(obj, 'hi', 'world')
     * console.log(obj) // => { hi: 'world' }
     *
     * // or define a custom plugin that adds `.foo` property
     * // to the end result, returned from `app.parse`
     * app.use((app) => {
     *   return (node, result) => {
     *     // this function is called
     *     // only when `.parse` is called
     *
     *     app.define(result, 'foo', 123)
     *
     *     return result
     *   }
     * })
     *
     * // fixture function to be parsed
     * const asyncFn = async (qux) => {
     *   const bar = await Promise.resolve(qux)
     *   return bar
     * }
     *
     * const result = app.parse(asyncFn)
     *
     * console.log(result.name) // => null
     * console.log(result.foo) // => 123
     * console.log(result.args) // => ['qux']
     *
     * console.log(result.isAsync) // => true
     * console.log(result.isArrow) // => true
     * console.log(result.isNamed) // => false
     * console.log(result.isAnonymous) // => true
     * ```
     *
     * @param  {Object} `obj` the object on which to define the property
     * @param  {String} `prop` the name of the property to be defined or modified
     * @param  {Any} `val` the descriptor for the property being defined or modified
     * @return {Object} `obj` the passed object, but modified
     * @name   .define
     * @api public
     */
    define: utils.define
  };
  app.use(initial);
  return app;
}

module.exports = parseFunction;


/***/ }),
/* 453 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

module.exports = function (val) {
	if (val === null || val === undefined) {
		return [];
	}

	return Array.isArray(val) ? val : [val];
};


/***/ }),
/* 454 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


Object.defineProperty(exports, '__esModule', { value: true });

function _AwaitValue(value) {
  this.wrapped = value;
}

function _AsyncGenerator(gen) {
  var front, back;

  function send(key, arg) {
    return new Promise(function (resolve, reject) {
      var request = {
        key: key,
        arg: arg,
        resolve: resolve,
        reject: reject,
        next: null
      };

      if (back) {
        back = back.next = request;
      } else {
        front = back = request;
        resume(key, arg);
      }
    });
  }

  function resume(key, arg) {
    try {
      var result = gen[key](arg);
      var value = result.value;
      var wrappedAwait = value instanceof _AwaitValue;
      Promise.resolve(wrappedAwait ? value.wrapped : value).then(function (arg) {
        if (wrappedAwait) {
          resume("next", arg);
          return;
        }

        settle(result.done ? "return" : "normal", arg);
      }, function (err) {
        resume("throw", err);
      });
    } catch (err) {
      settle("throw", err);
    }
  }

  function settle(type, value) {
    switch (type) {
      case "return":
        front.resolve({
          value: value,
          done: true
        });
        break;

      case "throw":
        front.reject(value);
        break;

      default:
        front.resolve({
          value: value,
          done: false
        });
        break;
    }

    front = front.next;

    if (front) {
      resume(front.key, front.arg);
    } else {
      back = null;
    }
  }

  this._invoke = send;

  if (typeof gen.return !== "function") {
    this.return = undefined;
  }
}

if (typeof Symbol === "function" && Symbol.asyncIterator) {
  _AsyncGenerator.prototype[Symbol.asyncIterator] = function () {
    return this;
  };
}

_AsyncGenerator.prototype.next = function (arg) {
  return this._invoke("next", arg);
};

_AsyncGenerator.prototype.throw = function (arg) {
  return this._invoke("throw", arg);
};

_AsyncGenerator.prototype.return = function (arg) {
  return this._invoke("return", arg);
};

function _inheritsLoose(subClass, superClass) {
  subClass.prototype.__proto__ = superClass && superClass.prototype;
  subClass.__proto__ = superClass;
}

var defaultOptions = {
  sourceType: "script",
  sourceFilename: undefined,
  startLine: 1,
  allowAwaitOutsideFunction: false,
  allowReturnOutsideFunction: false,
  allowImportExportEverywhere: false,
  allowSuperOutsideMethod: false,
  plugins: [],
  strictMode: null,
  ranges: false,
  tokens: false
};
function getOptions(opts) {
  var options = {};

  for (var key in defaultOptions) {
    options[key] = opts && opts[key] != null ? opts[key] : defaultOptions[key];
  }

  return options;
}

var beforeExpr = true;
var startsExpr = true;
var isLoop = true;
var isAssign = true;
var prefix = true;
var postfix = true;
var TokenType = function TokenType(label, conf) {
  if (conf === void 0) {
    conf = {};
  }

  this.label = label;
  this.keyword = conf.keyword;
  this.beforeExpr = !!conf.beforeExpr;
  this.startsExpr = !!conf.startsExpr;
  this.rightAssociative = !!conf.rightAssociative;
  this.isLoop = !!conf.isLoop;
  this.isAssign = !!conf.isAssign;
  this.prefix = !!conf.prefix;
  this.postfix = !!conf.postfix;
  this.binop = conf.binop === 0 ? 0 : conf.binop || null;
  this.updateContext = null;
};

var KeywordTokenType = function (_TokenType) {
  function KeywordTokenType(name, options) {
    if (options === void 0) {
      options = {};
    }

    options.keyword = name;
    return _TokenType.call(this, name, options) || this;
  }

  _inheritsLoose(KeywordTokenType, _TokenType);

  return KeywordTokenType;
}(TokenType);

var BinopTokenType = function (_TokenType2) {
  function BinopTokenType(name, prec) {
    return _TokenType2.call(this, name, {
      beforeExpr: beforeExpr,
      binop: prec
    }) || this;
  }

  _inheritsLoose(BinopTokenType, _TokenType2);

  return BinopTokenType;
}(TokenType);
var types = {
  num: new TokenType("num", {
    startsExpr: startsExpr
  }),
  bigint: new TokenType("bigint", {
    startsExpr: startsExpr
  }),
  regexp: new TokenType("regexp", {
    startsExpr: startsExpr
  }),
  string: new TokenType("string", {
    startsExpr: startsExpr
  }),
  name: new TokenType("name", {
    startsExpr: startsExpr
  }),
  eof: new TokenType("eof"),
  bracketL: new TokenType("[", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  bracketR: new TokenType("]"),
  braceL: new TokenType("{", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  braceBarL: new TokenType("{|", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  braceR: new TokenType("}"),
  braceBarR: new TokenType("|}"),
  parenL: new TokenType("(", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  parenR: new TokenType(")"),
  comma: new TokenType(",", {
    beforeExpr: beforeExpr
  }),
  semi: new TokenType(";", {
    beforeExpr: beforeExpr
  }),
  colon: new TokenType(":", {
    beforeExpr: beforeExpr
  }),
  doubleColon: new TokenType("::", {
    beforeExpr: beforeExpr
  }),
  dot: new TokenType("."),
  question: new TokenType("?", {
    beforeExpr: beforeExpr
  }),
  questionDot: new TokenType("?."),
  arrow: new TokenType("=>", {
    beforeExpr: beforeExpr
  }),
  template: new TokenType("template"),
  ellipsis: new TokenType("...", {
    beforeExpr: beforeExpr
  }),
  backQuote: new TokenType("`", {
    startsExpr: startsExpr
  }),
  dollarBraceL: new TokenType("${", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  at: new TokenType("@"),
  hash: new TokenType("#"),
  eq: new TokenType("=", {
    beforeExpr: beforeExpr,
    isAssign: isAssign
  }),
  assign: new TokenType("_=", {
    beforeExpr: beforeExpr,
    isAssign: isAssign
  }),
  incDec: new TokenType("++/--", {
    prefix: prefix,
    postfix: postfix,
    startsExpr: startsExpr
  }),
  bang: new TokenType("!", {
    beforeExpr: beforeExpr,
    prefix: prefix,
    startsExpr: startsExpr
  }),
  tilde: new TokenType("~", {
    beforeExpr: beforeExpr,
    prefix: prefix,
    startsExpr: startsExpr
  }),
  pipeline: new BinopTokenType("|>", 0),
  nullishCoalescing: new BinopTokenType("??", 1),
  logicalOR: new BinopTokenType("||", 1),
  logicalAND: new BinopTokenType("&&", 2),
  bitwiseOR: new BinopTokenType("|", 3),
  bitwiseXOR: new BinopTokenType("^", 4),
  bitwiseAND: new BinopTokenType("&", 5),
  equality: new BinopTokenType("==/!=", 6),
  relational: new BinopTokenType("</>", 7),
  bitShift: new BinopTokenType("<</>>", 8),
  plusMin: new TokenType("+/-", {
    beforeExpr: beforeExpr,
    binop: 9,
    prefix: prefix,
    startsExpr: startsExpr
  }),
  modulo: new BinopTokenType("%", 10),
  star: new BinopTokenType("*", 10),
  slash: new BinopTokenType("/", 10),
  exponent: new TokenType("**", {
    beforeExpr: beforeExpr,
    binop: 11,
    rightAssociative: true
  })
};
var keywords = {
  break: new KeywordTokenType("break"),
  case: new KeywordTokenType("case", {
    beforeExpr: beforeExpr
  }),
  catch: new KeywordTokenType("catch"),
  continue: new KeywordTokenType("continue"),
  debugger: new KeywordTokenType("debugger"),
  default: new KeywordTokenType("default", {
    beforeExpr: beforeExpr
  }),
  do: new KeywordTokenType("do", {
    isLoop: isLoop,
    beforeExpr: beforeExpr
  }),
  else: new KeywordTokenType("else", {
    beforeExpr: beforeExpr
  }),
  finally: new KeywordTokenType("finally"),
  for: new KeywordTokenType("for", {
    isLoop: isLoop
  }),
  function: new KeywordTokenType("function", {
    startsExpr: startsExpr
  }),
  if: new KeywordTokenType("if"),
  return: new KeywordTokenType("return", {
    beforeExpr: beforeExpr
  }),
  switch: new KeywordTokenType("switch"),
  throw: new KeywordTokenType("throw", {
    beforeExpr: beforeExpr,
    prefix: prefix,
    startsExpr: startsExpr
  }),
  try: new KeywordTokenType("try"),
  var: new KeywordTokenType("var"),
  let: new KeywordTokenType("let"),
  const: new KeywordTokenType("const"),
  while: new KeywordTokenType("while", {
    isLoop: isLoop
  }),
  with: new KeywordTokenType("with"),
  new: new KeywordTokenType("new", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  this: new KeywordTokenType("this", {
    startsExpr: startsExpr
  }),
  super: new KeywordTokenType("super", {
    startsExpr: startsExpr
  }),
  class: new KeywordTokenType("class"),
  extends: new KeywordTokenType("extends", {
    beforeExpr: beforeExpr
  }),
  export: new KeywordTokenType("export"),
  import: new KeywordTokenType("import", {
    startsExpr: startsExpr
  }),
  yield: new KeywordTokenType("yield", {
    beforeExpr: beforeExpr,
    startsExpr: startsExpr
  }),
  null: new KeywordTokenType("null", {
    startsExpr: startsExpr
  }),
  true: new KeywordTokenType("true", {
    startsExpr: startsExpr
  }),
  false: new KeywordTokenType("false", {
    startsExpr: startsExpr
  }),
  in: new KeywordTokenType("in", {
    beforeExpr: beforeExpr,
    binop: 7
  }),
  instanceof: new KeywordTokenType("instanceof", {
    beforeExpr: beforeExpr,
    binop: 7
  }),
  typeof: new KeywordTokenType("typeof", {
    beforeExpr: beforeExpr,
    prefix: prefix,
    startsExpr: startsExpr
  }),
  void: new KeywordTokenType("void", {
    beforeExpr: beforeExpr,
    prefix: prefix,
    startsExpr: startsExpr
  }),
  delete: new KeywordTokenType("delete", {
    beforeExpr: beforeExpr,
    prefix: prefix,
    startsExpr: startsExpr
  })
};
Object.keys(keywords).forEach(function (name) {
  types["_" + name] = keywords[name];
});

function makePredicate(words) {
  var wordsArr = words.split(" ");
  return function (str) {
    return wordsArr.indexOf(str) >= 0;
  };
}

var reservedWords = {
  "6": makePredicate("enum await"),
  strict: makePredicate("implements interface let package private protected public static yield"),
  strictBind: makePredicate("eval arguments")
};
var isKeyword = makePredicate("break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this let const class extends export import yield super");
var nonASCIIidentifierStartChars = "\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2118-\u211D\u2124\u2126\u2128\u212A-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309B-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC";
var nonASCIIidentifierChars = "\u200C\u200D\xB7\u0300-\u036F\u0387\u0483-\u0487\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u0669\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u06F0-\u06F9\u0711\u0730-\u074A\u07A6-\u07B0\u07C0-\u07C9\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D4-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0966-\u096F\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09E6-\u09EF\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A66-\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AE6-\u0AEF\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B66-\u0B6F\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C66-\u0C6F\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0CE6-\u0CEF\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D66-\u0D6F\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0E50-\u0E59\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0ED0-\u0ED9\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1040-\u1049\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F-\u109D\u135D-\u135F\u1369-\u1371\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u18A9\u1920-\u192B\u1930-\u193B\u1946-\u194F\u19D0-\u19DA\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AB0-\u1ABD\u1B00-\u1B04\u1B34-\u1B44\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BB0-\u1BB9\u1BE6-\u1BF3\u1C24-\u1C37\u1C40-\u1C49\u1C50-\u1C59\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u203F\u2040\u2054\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA620-\uA629\uA66F\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F1\uA900-\uA909\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9D0-\uA9D9\uA9E5\uA9F0-\uA9F9\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA50-\uAA59\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uABF0-\uABF9\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFF10-\uFF19\uFF3F";
var nonASCIIidentifierStart = new RegExp("[" + nonASCIIidentifierStartChars + "]");
var nonASCIIidentifier = new RegExp("[" + nonASCIIidentifierStartChars + nonASCIIidentifierChars + "]");
nonASCIIidentifierStartChars = nonASCIIidentifierChars = null;
var astralIdentifierStartCodes = [0, 11, 2, 25, 2, 18, 2, 1, 2, 14, 3, 13, 35, 122, 70, 52, 268, 28, 4, 48, 48, 31, 14, 29, 6, 37, 11, 29, 3, 35, 5, 7, 2, 4, 43, 157, 19, 35, 5, 35, 5, 39, 9, 51, 157, 310, 10, 21, 11, 7, 153, 5, 3, 0, 2, 43, 2, 1, 4, 0, 3, 22, 11, 22, 10, 30, 66, 18, 2, 1, 11, 21, 11, 25, 71, 55, 7, 1, 65, 0, 16, 3, 2, 2, 2, 26, 45, 28, 4, 28, 36, 7, 2, 27, 28, 53, 11, 21, 11, 18, 14, 17, 111, 72, 56, 50, 14, 50, 785, 52, 76, 44, 33, 24, 27, 35, 42, 34, 4, 0, 13, 47, 15, 3, 22, 0, 2, 0, 36, 17, 2, 24, 85, 6, 2, 0, 2, 3, 2, 14, 2, 9, 8, 46, 39, 7, 3, 1, 3, 21, 2, 6, 2, 1, 2, 4, 4, 0, 19, 0, 13, 4, 159, 52, 19, 3, 54, 47, 21, 1, 2, 0, 185, 46, 42, 3, 37, 47, 21, 0, 60, 42, 86, 25, 391, 63, 32, 0, 257, 0, 11, 39, 8, 0, 22, 0, 12, 39, 3, 3, 55, 56, 264, 8, 2, 36, 18, 0, 50, 29, 113, 6, 2, 1, 2, 37, 22, 0, 698, 921, 103, 110, 18, 195, 2749, 1070, 4050, 582, 8634, 568, 8, 30, 114, 29, 19, 47, 17, 3, 32, 20, 6, 18, 881, 68, 12, 0, 67, 12, 65, 1, 31, 6124, 20, 754, 9486, 286, 82, 395, 2309, 106, 6, 12, 4, 8, 8, 9, 5991, 84, 2, 70, 2, 1, 3, 0, 3, 1, 3, 3, 2, 11, 2, 0, 2, 6, 2, 64, 2, 3, 3, 7, 2, 6, 2, 27, 2, 3, 2, 4, 2, 0, 4, 6, 2, 339, 3, 24, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 30, 2, 24, 2, 7, 4149, 196, 60, 67, 1213, 3, 2, 26, 2, 1, 2, 0, 3, 0, 2, 9, 2, 3, 2, 0, 2, 0, 7, 0, 5, 0, 2, 0, 2, 0, 2, 2, 2, 1, 2, 0, 3, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 1, 2, 0, 3, 3, 2, 6, 2, 3, 2, 3, 2, 0, 2, 9, 2, 16, 6, 2, 2, 4, 2, 16, 4421, 42710, 42, 4148, 12, 221, 3, 5761, 15, 7472, 3104, 541];
var astralIdentifierCodes = [509, 0, 227, 0, 150, 4, 294, 9, 1368, 2, 2, 1, 6, 3, 41, 2, 5, 0, 166, 1, 1306, 2, 54, 14, 32, 9, 16, 3, 46, 10, 54, 9, 7, 2, 37, 13, 2, 9, 52, 0, 13, 2, 49, 13, 10, 2, 4, 9, 83, 11, 7, 0, 161, 11, 6, 9, 7, 3, 57, 0, 2, 6, 3, 1, 3, 2, 10, 0, 11, 1, 3, 6, 4, 4, 193, 17, 10, 9, 87, 19, 13, 9, 214, 6, 3, 8, 28, 1, 83, 16, 16, 9, 82, 12, 9, 9, 84, 14, 5, 9, 423, 9, 280, 9, 41, 6, 2, 3, 9, 0, 10, 10, 47, 15, 406, 7, 2, 7, 17, 9, 57, 21, 2, 13, 123, 5, 4, 0, 2, 1, 2, 6, 2, 0, 9, 9, 19719, 9, 135, 4, 60, 6, 26, 9, 1016, 45, 17, 3, 19723, 1, 5319, 4, 4, 5, 9, 7, 3, 6, 31, 3, 149, 2, 1418, 49, 513, 54, 5, 49, 9, 0, 15, 0, 23, 4, 2, 14, 1361, 6, 2, 16, 3, 6, 2, 1, 2, 4, 2214, 6, 110, 6, 6, 9, 792487, 239];

function isInAstralSet(code, set) {
  var pos = 0x10000;

  for (var i = 0; i < set.length; i += 2) {
    pos += set[i];
    if (pos > code) return false;
    pos += set[i + 1];
    if (pos >= code) return true;
  }

  return false;
}

function isIdentifierStart(code) {
  if (code < 65) return code === 36;
  if (code < 91) return true;
  if (code < 97) return code === 95;
  if (code < 123) return true;

  if (code <= 0xffff) {
    return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code));
  }

  return isInAstralSet(code, astralIdentifierStartCodes);
}
function isIteratorStart(current, next) {
  return current === 64 && next === 64;
}
function isIdentifierChar(code) {
  if (code < 48) return code === 36;
  if (code < 58) return true;
  if (code < 65) return false;
  if (code < 91) return true;
  if (code < 97) return code === 95;
  if (code < 123) return true;

  if (code <= 0xffff) {
    return code >= 0xaa && nonASCIIidentifier.test(String.fromCharCode(code));
  }

  return isInAstralSet(code, astralIdentifierStartCodes) || isInAstralSet(code, astralIdentifierCodes);
}

var lineBreak = /\r\n?|\n|\u2028|\u2029/;
var lineBreakG = new RegExp(lineBreak.source, "g");
function isNewLine(code) {
  return code === 10 || code === 13 || code === 0x2028 || code === 0x2029;
}
var nonASCIIwhitespace = /[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/;

var TokContext = function TokContext(token, isExpr, preserveSpace, override) {
  this.token = token;
  this.isExpr = !!isExpr;
  this.preserveSpace = !!preserveSpace;
  this.override = override;
};
var types$1 = {
  braceStatement: new TokContext("{", false),
  braceExpression: new TokContext("{", true),
  templateQuasi: new TokContext("${", true),
  parenStatement: new TokContext("(", false),
  parenExpression: new TokContext("(", true),
  template: new TokContext("`", true, true, function (p) {
    return p.readTmplToken();
  }),
  functionExpression: new TokContext("function", true)
};

types.parenR.updateContext = types.braceR.updateContext = function () {
  if (this.state.context.length === 1) {
    this.state.exprAllowed = true;
    return;
  }

  var out = this.state.context.pop();

  if (out === types$1.braceStatement && this.curContext() === types$1.functionExpression) {
    this.state.context.pop();
    this.state.exprAllowed = false;
  } else if (out === types$1.templateQuasi) {
    this.state.exprAllowed = true;
  } else {
    this.state.exprAllowed = !out.isExpr;
  }
};

types.name.updateContext = function (prevType) {
  if (this.state.value === "of" && this.curContext() === types$1.parenStatement) {
    this.state.exprAllowed = !prevType.beforeExpr;
    return;
  }

  this.state.exprAllowed = false;

  if (prevType === types._let || prevType === types._const || prevType === types._var) {
    if (lineBreak.test(this.input.slice(this.state.end))) {
      this.state.exprAllowed = true;
    }
  }

  if (this.state.isIterator) {
    this.state.isIterator = false;
  }
};

types.braceL.updateContext = function (prevType) {
  this.state.context.push(this.braceIsBlock(prevType) ? types$1.braceStatement : types$1.braceExpression);
  this.state.exprAllowed = true;
};

types.dollarBraceL.updateContext = function () {
  this.state.context.push(types$1.templateQuasi);
  this.state.exprAllowed = true;
};

types.parenL.updateContext = function (prevType) {
  var statementParens = prevType === types._if || prevType === types._for || prevType === types._with || prevType === types._while;
  this.state.context.push(statementParens ? types$1.parenStatement : types$1.parenExpression);
  this.state.exprAllowed = true;
};

types.incDec.updateContext = function () {};

types._function.updateContext = function (prevType) {
  if (this.state.exprAllowed && !this.braceIsBlock(prevType)) {
    this.state.context.push(types$1.functionExpression);
  }

  this.state.exprAllowed = false;
};

types.backQuote.updateContext = function () {
  if (this.curContext() === types$1.template) {
    this.state.context.pop();
  } else {
    this.state.context.push(types$1.template);
  }

  this.state.exprAllowed = false;
};

var Position = function Position(line, col) {
  this.line = line;
  this.column = col;
};
var SourceLocation = function SourceLocation(start, end) {
  this.start = start;
  this.end = end;
};
function getLineInfo(input, offset) {
  for (var line = 1, cur = 0;;) {
    lineBreakG.lastIndex = cur;
    var match = lineBreakG.exec(input);

    if (match && match.index < offset) {
      ++line;
      cur = match.index + match[0].length;
    } else {
      return new Position(line, offset - cur);
    }
  }

  throw new Error("Unreachable");
}

var BaseParser = function () {
  function BaseParser() {
    this.sawUnambiguousESM = false;
  }

  var _proto = BaseParser.prototype;

  _proto.isReservedWord = function isReservedWord(word) {
    if (word === "await") {
      return this.inModule;
    } else {
      return reservedWords[6](word);
    }
  };

  _proto.hasPlugin = function hasPlugin(name) {
    return !!this.plugins[name];
  };

  return BaseParser;
}();

function last(stack) {
  return stack[stack.length - 1];
}

var CommentsParser = function (_BaseParser) {
  function CommentsParser() {
    return _BaseParser.apply(this, arguments) || this;
  }

  var _proto = CommentsParser.prototype;

  _proto.addComment = function addComment(comment) {
    if (this.filename) comment.loc.filename = this.filename;
    this.state.trailingComments.push(comment);
    this.state.leadingComments.push(comment);
  };

  _proto.processComment = function processComment(node) {
    if (node.type === "Program" && node.body.length > 0) return;
    var stack = this.state.commentStack;
    var firstChild, lastChild, trailingComments, i, j;

    if (this.state.trailingComments.length > 0) {
      if (this.state.trailingComments[0].start >= node.end) {
        trailingComments = this.state.trailingComments;
        this.state.trailingComments = [];
      } else {
        this.state.trailingComments.length = 0;
      }
    } else if (stack.length > 0) {
      var lastInStack = last(stack);

      if (lastInStack.trailingComments && lastInStack.trailingComments[0].start >= node.end) {
        trailingComments = lastInStack.trailingComments;
        delete lastInStack.trailingComments;
      }
    }

    if (stack.length > 0 && last(stack).start >= node.start) {
      firstChild = stack.pop();
    }

    while (stack.length > 0 && last(stack).start >= node.start) {
      lastChild = stack.pop();
    }

    if (!lastChild && firstChild) lastChild = firstChild;

    if (firstChild && this.state.leadingComments.length > 0) {
      var lastComment = last(this.state.leadingComments);

      if (firstChild.type === "ObjectProperty") {
        if (lastComment.start >= node.start) {
          if (this.state.commentPreviousNode) {
            for (j = 0; j < this.state.leadingComments.length; j++) {
              if (this.state.leadingComments[j].end < this.state.commentPreviousNode.end) {
                this.state.leadingComments.splice(j, 1);
                j--;
              }
            }

            if (this.state.leadingComments.length > 0) {
              firstChild.trailingComments = this.state.leadingComments;
              this.state.leadingComments = [];
            }
          }
        }
      } else if (node.type === "CallExpression" && node.arguments && node.arguments.length) {
        var lastArg = last(node.arguments);

        if (lastArg && lastComment.start >= lastArg.start && lastComment.end <= node.end) {
          if (this.state.commentPreviousNode) {
            if (this.state.leadingComments.length > 0) {
              lastArg.trailingComments = this.state.leadingComments;
              this.state.leadingComments = [];
            }
          }
        }
      }
    }

    if (lastChild) {
      if (lastChild.leadingComments) {
        if (lastChild !== node && lastChild.leadingComments.length > 0 && last(lastChild.leadingComments).end <= node.start) {
          node.leadingComments = lastChild.leadingComments;
          delete lastChild.leadingComments;
        } else {
          for (i = lastChild.leadingComments.length - 2; i >= 0; --i) {
            if (lastChild.leadingComments[i].end <= node.start) {
              node.leadingComments = lastChild.leadingComments.splice(0, i + 1);
              break;
            }
          }
        }
      }
    } else if (this.state.leadingComments.length > 0) {
      if (last(this.state.leadingComments).end <= node.start) {
        if (this.state.commentPreviousNode) {
          for (j = 0; j < this.state.leadingComments.length; j++) {
            if (this.state.leadingComments[j].end < this.state.commentPreviousNode.end) {
              this.state.leadingComments.splice(j, 1);
              j--;
            }
          }
        }

        if (this.state.leadingComments.length > 0) {
          node.leadingComments = this.state.leadingComments;
          this.state.leadingComments = [];
        }
      } else {
        for (i = 0; i < this.state.leadingComments.length; i++) {
          if (this.state.leadingComments[i].end > node.start) {
            break;
          }
        }

        var leadingComments = this.state.leadingComments.slice(0, i);

        if (leadingComments.length) {
          node.leadingComments = leadingComments;
        }

        trailingComments = this.state.leadingComments.slice(i);

        if (trailingComments.length === 0) {
          trailingComments = null;
        }
      }
    }

    this.state.commentPreviousNode = node;

    if (trailingComments) {
      if (trailingComments.length && trailingComments[0].start >= node.start && last(trailingComments).end <= node.end) {
        node.innerComments = trailingComments;
      } else {
        node.trailingComments = trailingComments;
      }
    }

    stack.push(node);
  };

  _inheritsLoose(CommentsParser, _BaseParser);

  return CommentsParser;
}(BaseParser);

var LocationParser = function (_CommentsParser) {
  function LocationParser() {
    return _CommentsParser.apply(this, arguments) || this;
  }

  var _proto = LocationParser.prototype;

  _proto.raise = function raise(pos, message, _temp) {
    var _ref = _temp === void 0 ? {} : _temp,
        missingPluginNames = _ref.missingPluginNames,
        code = _ref.code;

    var loc = getLineInfo(this.input, pos);
    message += " (" + loc.line + ":" + loc.column + ")";
    var err = new SyntaxError(message);
    err.pos = pos;
    err.loc = loc;

    if (missingPluginNames) {
      err.missingPlugin = missingPluginNames;
    }

    if (code !== undefined) {
      err.code = code;
    }

    throw err;
  };

  _inheritsLoose(LocationParser, _CommentsParser);

  return LocationParser;
}(CommentsParser);

var State = function () {
  function State() {}

  var _proto = State.prototype;

  _proto.init = function init(options, input) {
    this.strict = options.strictMode === false ? false : options.sourceType === "module";
    this.input = input;
    this.potentialArrowAt = -1;
    this.noArrowAt = [];
    this.noArrowParamsConversionAt = [];
    this.inMethod = false;
    this.inFunction = false;
    this.inParameters = false;
    this.maybeInArrowParameters = false;
    this.inGenerator = false;
    this.inAsync = false;
    this.inPropertyName = false;
    this.inType = false;
    this.inClassProperty = false;
    this.noAnonFunctionType = false;
    this.hasFlowComment = false;
    this.isIterator = false;
    this.classLevel = 0;
    this.labels = [];
    this.decoratorStack = [[]];
    this.yieldInPossibleArrowParameters = null;
    this.tokens = [];
    this.comments = [];
    this.trailingComments = [];
    this.leadingComments = [];
    this.commentStack = [];
    this.commentPreviousNode = null;
    this.pos = this.lineStart = 0;
    this.curLine = options.startLine;
    this.type = types.eof;
    this.value = null;
    this.start = this.end = this.pos;
    this.startLoc = this.endLoc = this.curPosition();
    this.lastTokEndLoc = this.lastTokStartLoc = null;
    this.lastTokStart = this.lastTokEnd = this.pos;
    this.context = [types$1.braceStatement];
    this.exprAllowed = true;
    this.containsEsc = this.containsOctal = false;
    this.octalPosition = null;
    this.invalidTemplateEscapePosition = null;
    this.exportedIdentifiers = [];
  };

  _proto.curPosition = function curPosition() {
    return new Position(this.curLine, this.pos - this.lineStart);
  };

  _proto.clone = function clone(skipArrays) {
    var _this = this;

    var state = new State();
    Object.keys(this).forEach(function (key) {
      var val = _this[key];

      if ((!skipArrays || key === "context") && Array.isArray(val)) {
        val = val.slice();
      }

      state[key] = val;
    });
    return state;
  };

  return State;
}();

var _isDigit = function isDigit(code) {
  return code >= 48 && code <= 57;
};

var VALID_REGEX_FLAGS = "gmsiyu";
var forbiddenNumericSeparatorSiblings = {
  decBinOct: [46, 66, 69, 79, 95, 98, 101, 111],
  hex: [46, 88, 95, 120]
};
var allowedNumericSeparatorSiblings = {};
allowedNumericSeparatorSiblings.bin = [48, 49];
allowedNumericSeparatorSiblings.oct = allowedNumericSeparatorSiblings.bin.concat([50, 51, 52, 53, 54, 55]);
allowedNumericSeparatorSiblings.dec = allowedNumericSeparatorSiblings.oct.concat([56, 57]);
allowedNumericSeparatorSiblings.hex = allowedNumericSeparatorSiblings.dec.concat([65, 66, 67, 68, 69, 70, 97, 98, 99, 100, 101, 102]);
var Token = function Token(state) {
  this.type = state.type;
  this.value = state.value;
  this.start = state.start;
  this.end = state.end;
  this.loc = new SourceLocation(state.startLoc, state.endLoc);
};

function codePointToString(code) {
  if (code <= 0xffff) {
    return String.fromCharCode(code);
  } else {
    return String.fromCharCode((code - 0x10000 >> 10) + 0xd800, (code - 0x10000 & 1023) + 0xdc00);
  }
}

var Tokenizer = function (_LocationParser) {
  function Tokenizer(options, input) {
    var _this;

    _this = _LocationParser.call(this) || this;
    _this.state = new State();

    _this.state.init(options, input);

    _this.isLookahead = false;
    return _this;
  }

  var _proto = Tokenizer.prototype;

  _proto.next = function next() {
    if (this.options.tokens && !this.isLookahead) {
      this.state.tokens.push(new Token(this.state));
    }

    this.state.lastTokEnd = this.state.end;
    this.state.lastTokStart = this.state.start;
    this.state.lastTokEndLoc = this.state.endLoc;
    this.state.lastTokStartLoc = this.state.startLoc;
    this.nextToken();
  };

  _proto.eat = function eat(type) {
    if (this.match(type)) {
      this.next();
      return true;
    } else {
      return false;
    }
  };

  _proto.match = function match(type) {
    return this.state.type === type;
  };

  _proto.isKeyword = function isKeyword$$1(word) {
    return isKeyword(word);
  };

  _proto.lookahead = function lookahead() {
    var old = this.state;
    this.state = old.clone(true);
    this.isLookahead = true;
    this.next();
    this.isLookahead = false;
    var curr = this.state;
    this.state = old;
    return curr;
  };

  _proto.setStrict = function setStrict(strict) {
    this.state.strict = strict;
    if (!this.match(types.num) && !this.match(types.string)) return;
    this.state.pos = this.state.start;

    while (this.state.pos < this.state.lineStart) {
      this.state.lineStart = this.input.lastIndexOf("\n", this.state.lineStart - 2) + 1;
      --this.state.curLine;
    }

    this.nextToken();
  };

  _proto.curContext = function curContext() {
    return this.state.context[this.state.context.length - 1];
  };

  _proto.nextToken = function nextToken() {
    var curContext = this.curContext();
    if (!curContext || !curContext.preserveSpace) this.skipSpace();
    this.state.containsOctal = false;
    this.state.octalPosition = null;
    this.state.start = this.state.pos;
    this.state.startLoc = this.state.curPosition();

    if (this.state.pos >= this.input.length) {
      this.finishToken(types.eof);
      return;
    }

    if (curContext.override) {
      curContext.override(this);
    } else {
      this.readToken(this.fullCharCodeAtPos());
    }
  };

  _proto.readToken = function readToken(code) {
    if (isIdentifierStart(code) || code === 92) {
      this.readWord();
    } else {
      this.getTokenFromCode(code);
    }
  };

  _proto.fullCharCodeAtPos = function fullCharCodeAtPos() {
    var code = this.input.charCodeAt(this.state.pos);
    if (code <= 0xd7ff || code >= 0xe000) return code;
    var next = this.input.charCodeAt(this.state.pos + 1);
    return (code << 10) + next - 0x35fdc00;
  };

  _proto.pushComment = function pushComment(block, text, start, end, startLoc, endLoc) {
    var comment = {
      type: block ? "CommentBlock" : "CommentLine",
      value: text,
      start: start,
      end: end,
      loc: new SourceLocation(startLoc, endLoc)
    };

    if (!this.isLookahead) {
      if (this.options.tokens) this.state.tokens.push(comment);
      this.state.comments.push(comment);
      this.addComment(comment);
    }
  };

  _proto.skipBlockComment = function skipBlockComment() {
    var startLoc = this.state.curPosition();
    var start = this.state.pos;
    var end = this.input.indexOf("*/", this.state.pos += 2);
    if (end === -1) this.raise(this.state.pos - 2, "Unterminated comment");
    this.state.pos = end + 2;
    lineBreakG.lastIndex = start;
    var match;

    while ((match = lineBreakG.exec(this.input)) && match.index < this.state.pos) {
      ++this.state.curLine;
      this.state.lineStart = match.index + match[0].length;
    }

    this.pushComment(true, this.input.slice(start + 2, end), start, this.state.pos, startLoc, this.state.curPosition());
  };

  _proto.skipLineComment = function skipLineComment(startSkip) {
    var start = this.state.pos;
    var startLoc = this.state.curPosition();
    var ch = this.input.charCodeAt(this.state.pos += startSkip);

    if (this.state.pos < this.input.length) {
      while (ch !== 10 && ch !== 13 && ch !== 8232 && ch !== 8233 && ++this.state.pos < this.input.length) {
        ch = this.input.charCodeAt(this.state.pos);
      }
    }

    this.pushComment(false, this.input.slice(start + startSkip, this.state.pos), start, this.state.pos, startLoc, this.state.curPosition());
  };

  _proto.skipSpace = function skipSpace() {
    loop: while (this.state.pos < this.input.length) {
      var ch = this.input.charCodeAt(this.state.pos);

      switch (ch) {
        case 32:
        case 160:
          ++this.state.pos;
          break;

        case 13:
          if (this.input.charCodeAt(this.state.pos + 1) === 10) {
            ++this.state.pos;
          }

        case 10:
        case 8232:
        case 8233:
          ++this.state.pos;
          ++this.state.curLine;
          this.state.lineStart = this.state.pos;
          break;

        case 47:
          switch (this.input.charCodeAt(this.state.pos + 1)) {
            case 42:
              this.skipBlockComment();
              break;

            case 47:
              this.skipLineComment(2);
              break;

            default:
              break loop;
          }

          break;

        default:
          if (ch > 8 && ch < 14 || ch >= 5760 && nonASCIIwhitespace.test(String.fromCharCode(ch))) {
            ++this.state.pos;
          } else {
            break loop;
          }

      }
    }
  };

  _proto.finishToken = function finishToken(type, val) {
    this.state.end = this.state.pos;
    this.state.endLoc = this.state.curPosition();
    var prevType = this.state.type;
    this.state.type = type;
    this.state.value = val;
    this.updateContext(prevType);
  };

  _proto.readToken_dot = function readToken_dot() {
    var next = this.input.charCodeAt(this.state.pos + 1);

    if (next >= 48 && next <= 57) {
      this.readNumber(true);
      return;
    }

    var next2 = this.input.charCodeAt(this.state.pos + 2);

    if (next === 46 && next2 === 46) {
      this.state.pos += 3;
      this.finishToken(types.ellipsis);
    } else {
      ++this.state.pos;
      this.finishToken(types.dot);
    }
  };

  _proto.readToken_slash = function readToken_slash() {
    if (this.state.exprAllowed) {
      ++this.state.pos;
      this.readRegexp();
      return;
    }

    var next = this.input.charCodeAt(this.state.pos + 1);

    if (next === 61) {
      this.finishOp(types.assign, 2);
    } else {
      this.finishOp(types.slash, 1);
    }
  };

  _proto.readToken_mult_modulo = function readToken_mult_modulo(code) {
    var type = code === 42 ? types.star : types.modulo;
    var width = 1;
    var next = this.input.charCodeAt(this.state.pos + 1);
    var exprAllowed = this.state.exprAllowed;

    if (code === 42 && next === 42) {
      width++;
      next = this.input.charCodeAt(this.state.pos + 2);
      type = types.exponent;
    }

    if (next === 61 && !exprAllowed) {
      width++;
      type = types.assign;
    }

    this.finishOp(type, width);
  };

  _proto.readToken_pipe_amp = function readToken_pipe_amp(code) {
    var next = this.input.charCodeAt(this.state.pos + 1);

    if (next === code) {
      if (this.input.charCodeAt(this.state.pos + 2) === 61) {
        this.finishOp(types.assign, 3);
      } else {
        this.finishOp(code === 124 ? types.logicalOR : types.logicalAND, 2);
      }

      return;
    }

    if (code === 124) {
      if (next === 62) {
        this.finishOp(types.pipeline, 2);
        return;
      } else if (next === 125 && this.hasPlugin("flow")) {
        this.finishOp(types.braceBarR, 2);
        return;
      }
    }

    if (next === 61) {
      this.finishOp(types.assign, 2);
      return;
    }

    this.finishOp(code === 124 ? types.bitwiseOR : types.bitwiseAND, 1);
  };

  _proto.readToken_caret = function readToken_caret() {
    var next = this.input.charCodeAt(this.state.pos + 1);

    if (next === 61) {
      this.finishOp(types.assign, 2);
    } else {
      this.finishOp(types.bitwiseXOR, 1);
    }
  };

  _proto.readToken_plus_min = function readToken_plus_min(code) {
    var next = this.input.charCodeAt(this.state.pos + 1);

    if (next === code) {
      if (next === 45 && !this.inModule && this.input.charCodeAt(this.state.pos + 2) === 62 && lineBreak.test(this.input.slice(this.state.lastTokEnd, this.state.pos))) {
        this.skipLineComment(3);
        this.skipSpace();
        this.nextToken();
        return;
      }

      this.finishOp(types.incDec, 2);
      return;
    }

    if (next === 61) {
      this.finishOp(types.assign, 2);
    } else {
      this.finishOp(types.plusMin, 1);
    }
  };

  _proto.readToken_lt_gt = function readToken_lt_gt(code) {
    var next = this.input.charCodeAt(this.state.pos + 1);
    var size = 1;

    if (next === code) {
      size = code === 62 && this.input.charCodeAt(this.state.pos + 2) === 62 ? 3 : 2;

      if (this.input.charCodeAt(this.state.pos + size) === 61) {
        this.finishOp(types.assign, size + 1);
        return;
      }

      this.finishOp(types.bitShift, size);
      return;
    }

    if (next === 33 && code === 60 && !this.inModule && this.input.charCodeAt(this.state.pos + 2) === 45 && this.input.charCodeAt(this.state.pos + 3) === 45) {
      this.skipLineComment(4);
      this.skipSpace();
      this.nextToken();
      return;
    }

    if (next === 61) {
      size = 2;
    }

    this.finishOp(types.relational, size);
  };

  _proto.readToken_eq_excl = function readToken_eq_excl(code) {
    var next = this.input.charCodeAt(this.state.pos + 1);

    if (next === 61) {
      this.finishOp(types.equality, this.input.charCodeAt(this.state.pos + 2) === 61 ? 3 : 2);
      return;
    }

    if (code === 61 && next === 62) {
      this.state.pos += 2;
      this.finishToken(types.arrow);
      return;
    }

    this.finishOp(code === 61 ? types.eq : types.bang, 1);
  };

  _proto.readToken_question = function readToken_question() {
    var next = this.input.charCodeAt(this.state.pos + 1);
    var next2 = this.input.charCodeAt(this.state.pos + 2);

    if (next === 63) {
      if (next2 === 61) {
        this.finishOp(types.assign, 3);
      } else {
        this.finishOp(types.nullishCoalescing, 2);
      }
    } else if (next === 46 && !(next2 >= 48 && next2 <= 57)) {
      this.state.pos += 2;
      this.finishToken(types.questionDot);
    } else {
      ++this.state.pos;
      this.finishToken(types.question);
    }
  };

  _proto.getTokenFromCode = function getTokenFromCode(code) {
    switch (code) {
      case 35:
        if ((this.hasPlugin("classPrivateProperties") || this.hasPlugin("classPrivateMethods")) && this.state.classLevel > 0) {
          ++this.state.pos;
          this.finishToken(types.hash);
          return;
        } else {
          this.raise(this.state.pos, "Unexpected character '" + codePointToString(code) + "'");
        }

      case 46:
        this.readToken_dot();
        return;

      case 40:
        ++this.state.pos;
        this.finishToken(types.parenL);
        return;

      case 41:
        ++this.state.pos;
        this.finishToken(types.parenR);
        return;

      case 59:
        ++this.state.pos;
        this.finishToken(types.semi);
        return;

      case 44:
        ++this.state.pos;
        this.finishToken(types.comma);
        return;

      case 91:
        ++this.state.pos;
        this.finishToken(types.bracketL);
        return;

      case 93:
        ++this.state.pos;
        this.finishToken(types.bracketR);
        return;

      case 123:
        if (this.hasPlugin("flow") && this.input.charCodeAt(this.state.pos + 1) === 124) {
          this.finishOp(types.braceBarL, 2);
        } else {
          ++this.state.pos;
          this.finishToken(types.braceL);
        }

        return;

      case 125:
        ++this.state.pos;
        this.finishToken(types.braceR);
        return;

      case 58:
        if (this.hasPlugin("functionBind") && this.input.charCodeAt(this.state.pos + 1) === 58) {
          this.finishOp(types.doubleColon, 2);
        } else {
          ++this.state.pos;
          this.finishToken(types.colon);
        }

        return;

      case 63:
        this.readToken_question();
        return;

      case 64:
        ++this.state.pos;
        this.finishToken(types.at);
        return;

      case 96:
        ++this.state.pos;
        this.finishToken(types.backQuote);
        return;

      case 48:
        {
          var next = this.input.charCodeAt(this.state.pos + 1);

          if (next === 120 || next === 88) {
            this.readRadixNumber(16);
            return;
          }

          if (next === 111 || next === 79) {
            this.readRadixNumber(8);
            return;
          }

          if (next === 98 || next === 66) {
            this.readRadixNumber(2);
            return;
          }
        }

      case 49:
      case 50:
      case 51:
      case 52:
      case 53:
      case 54:
      case 55:
      case 56:
      case 57:
        this.readNumber(false);
        return;

      case 34:
      case 39:
        this.readString(code);
        return;

      case 47:
        this.readToken_slash();
        return;

      case 37:
      case 42:
        this.readToken_mult_modulo(code);
        return;

      case 124:
      case 38:
        this.readToken_pipe_amp(code);
        return;

      case 94:
        this.readToken_caret();
        return;

      case 43:
      case 45:
        this.readToken_plus_min(code);
        return;

      case 60:
      case 62:
        this.readToken_lt_gt(code);
        return;

      case 61:
      case 33:
        this.readToken_eq_excl(code);
        return;

      case 126:
        this.finishOp(types.tilde, 1);
        return;
    }

    this.raise(this.state.pos, "Unexpected character '" + codePointToString(code) + "'");
  };

  _proto.finishOp = function finishOp(type, size) {
    var str = this.input.slice(this.state.pos, this.state.pos + size);
    this.state.pos += size;
    this.finishToken(type, str);
  };

  _proto.readRegexp = function readRegexp() {
    var start = this.state.pos;
    var escaped, inClass;

    for (;;) {
      if (this.state.pos >= this.input.length) {
        this.raise(start, "Unterminated regular expression");
      }

      var ch = this.input.charAt(this.state.pos);

      if (lineBreak.test(ch)) {
        this.raise(start, "Unterminated regular expression");
      }

      if (escaped) {
        escaped = false;
      } else {
        if (ch === "[") {
          inClass = true;
        } else if (ch === "]" && inClass) {
          inClass = false;
        } else if (ch === "/" && !inClass) {
          break;
        }

        escaped = ch === "\\";
      }

      ++this.state.pos;
    }

    var content = this.input.slice(start, this.state.pos);
    ++this.state.pos;
    var mods = "";

    while (this.state.pos < this.input.length) {
      var char = this.input[this.state.pos];
      var charCode = this.fullCharCodeAtPos();

      if (VALID_REGEX_FLAGS.indexOf(char) > -1) {
        if (mods.indexOf(char) > -1) {
          this.raise(this.state.pos + 1, "Duplicate regular expression flag");
        }

        ++this.state.pos;
        mods += char;
      } else if (isIdentifierChar(charCode) || charCode === 92) {
        this.raise(this.state.pos + 1, "Invalid regular expression flag");
      } else {
        break;
      }
    }

    this.finishToken(types.regexp, {
      pattern: content,
      flags: mods
    });
  };

  _proto.readInt = function readInt(radix, len) {
    var start = this.state.pos;
    var forbiddenSiblings = radix === 16 ? forbiddenNumericSeparatorSiblings.hex : forbiddenNumericSeparatorSiblings.decBinOct;
    var allowedSiblings = radix === 16 ? allowedNumericSeparatorSiblings.hex : radix === 10 ? allowedNumericSeparatorSiblings.dec : radix === 8 ? allowedNumericSeparatorSiblings.oct : allowedNumericSeparatorSiblings.bin;
    var total = 0;

    for (var i = 0, e = len == null ? Infinity : len; i < e; ++i) {
      var code = this.input.charCodeAt(this.state.pos);
      var val = void 0;

      if (this.hasPlugin("numericSeparator")) {
        var prev = this.input.charCodeAt(this.state.pos - 1);
        var next = this.input.charCodeAt(this.state.pos + 1);

        if (code === 95) {
          if (allowedSiblings.indexOf(next) === -1) {
            this.raise(this.state.pos, "Invalid or unexpected token");
          }

          if (forbiddenSiblings.indexOf(prev) > -1 || forbiddenSiblings.indexOf(next) > -1 || Number.isNaN(next)) {
            this.raise(this.state.pos, "Invalid or unexpected token");
          }

          ++this.state.pos;
          continue;
        }
      }

      if (code >= 97) {
        val = code - 97 + 10;
      } else if (code >= 65) {
        val = code - 65 + 10;
      } else if (_isDigit(code)) {
        val = code - 48;
      } else {
        val = Infinity;
      }

      if (val >= radix) break;
      ++this.state.pos;
      total = total * radix + val;
    }

    if (this.state.pos === start || len != null && this.state.pos - start !== len) {
      return null;
    }

    return total;
  };

  _proto.readRadixNumber = function readRadixNumber(radix) {
    var start = this.state.pos;
    var isBigInt = false;
    this.state.pos += 2;
    var val = this.readInt(radix);

    if (val == null) {
      this.raise(this.state.start + 2, "Expected number in radix " + radix);
    }

    if (this.hasPlugin("bigInt")) {
      if (this.input.charCodeAt(this.state.pos) === 110) {
        ++this.state.pos;
        isBigInt = true;
      }
    }

    if (isIdentifierStart(this.fullCharCodeAtPos())) {
      this.raise(this.state.pos, "Identifier directly after number");
    }

    if (isBigInt) {
      var str = this.input.slice(start, this.state.pos).replace(/[_n]/g, "");
      this.finishToken(types.bigint, str);
      return;
    }

    this.finishToken(types.num, val);
  };

  _proto.readNumber = function readNumber(startsWithDot) {
    var start = this.state.pos;
    var octal = this.input.charCodeAt(start) === 48;
    var isFloat = false;
    var isBigInt = false;

    if (!startsWithDot && this.readInt(10) === null) {
      this.raise(start, "Invalid number");
    }

    if (octal && this.state.pos == start + 1) octal = false;
    var next = this.input.charCodeAt(this.state.pos);

    if (next === 46 && !octal) {
      ++this.state.pos;
      this.readInt(10);
      isFloat = true;
      next = this.input.charCodeAt(this.state.pos);
    }

    if ((next === 69 || next === 101) && !octal) {
      next = this.input.charCodeAt(++this.state.pos);

      if (next === 43 || next === 45) {
        ++this.state.pos;
      }

      if (this.readInt(10) === null) this.raise(start, "Invalid number");
      isFloat = true;
      next = this.input.charCodeAt(this.state.pos);
    }

    if (this.hasPlugin("bigInt")) {
      if (next === 110) {
        if (isFloat || octal) this.raise(start, "Invalid BigIntLiteral");
        ++this.state.pos;
        isBigInt = true;
      }
    }

    if (isIdentifierStart(this.fullCharCodeAtPos())) {
      this.raise(this.state.pos, "Identifier directly after number");
    }

    var str = this.input.slice(start, this.state.pos).replace(/[_n]/g, "");

    if (isBigInt) {
      this.finishToken(types.bigint, str);
      return;
    }

    var val;

    if (isFloat) {
      val = parseFloat(str);
    } else if (!octal || str.length === 1) {
      val = parseInt(str, 10);
    } else if (this.state.strict) {
      this.raise(start, "Invalid number");
    } else if (/[89]/.test(str)) {
      val = parseInt(str, 10);
    } else {
      val = parseInt(str, 8);
    }

    this.finishToken(types.num, val);
  };

  _proto.readCodePoint = function readCodePoint(throwOnInvalid) {
    var ch = this.input.charCodeAt(this.state.pos);
    var code;

    if (ch === 123) {
      var codePos = ++this.state.pos;
      code = this.readHexChar(this.input.indexOf("}", this.state.pos) - this.state.pos, throwOnInvalid);
      ++this.state.pos;

      if (code === null) {
        --this.state.invalidTemplateEscapePosition;
      } else if (code > 0x10ffff) {
        if (throwOnInvalid) {
          this.raise(codePos, "Code point out of bounds");
        } else {
          this.state.invalidTemplateEscapePosition = codePos - 2;
          return null;
        }
      }
    } else {
      code = this.readHexChar(4, throwOnInvalid);
    }

    return code;
  };

  _proto.readString = function readString(quote) {
    var out = "",
        chunkStart = ++this.state.pos;

    for (;;) {
      if (this.state.pos >= this.input.length) {
        this.raise(this.state.start, "Unterminated string constant");
      }

      var ch = this.input.charCodeAt(this.state.pos);
      if (ch === quote) break;

      if (ch === 92) {
        out += this.input.slice(chunkStart, this.state.pos);
        out += this.readEscapedChar(false);
        chunkStart = this.state.pos;
      } else {
        if (isNewLine(ch)) {
          this.raise(this.state.start, "Unterminated string constant");
        }

        ++this.state.pos;
      }
    }

    out += this.input.slice(chunkStart, this.state.pos++);
    this.finishToken(types.string, out);
  };

  _proto.readTmplToken = function readTmplToken() {
    var out = "",
        chunkStart = this.state.pos,
        containsInvalid = false;

    for (;;) {
      if (this.state.pos >= this.input.length) {
        this.raise(this.state.start, "Unterminated template");
      }

      var ch = this.input.charCodeAt(this.state.pos);

      if (ch === 96 || ch === 36 && this.input.charCodeAt(this.state.pos + 1) === 123) {
        if (this.state.pos === this.state.start && this.match(types.template)) {
          if (ch === 36) {
            this.state.pos += 2;
            this.finishToken(types.dollarBraceL);
            return;
          } else {
            ++this.state.pos;
            this.finishToken(types.backQuote);
            return;
          }
        }

        out += this.input.slice(chunkStart, this.state.pos);
        this.finishToken(types.template, containsInvalid ? null : out);
        return;
      }

      if (ch === 92) {
        out += this.input.slice(chunkStart, this.state.pos);
        var escaped = this.readEscapedChar(true);

        if (escaped === null) {
          containsInvalid = true;
        } else {
          out += escaped;
        }

        chunkStart = this.state.pos;
      } else if (isNewLine(ch)) {
        out += this.input.slice(chunkStart, this.state.pos);
        ++this.state.pos;

        switch (ch) {
          case 13:
            if (this.input.charCodeAt(this.state.pos) === 10) {
              ++this.state.pos;
            }

          case 10:
            out += "\n";
            break;

          default:
            out += String.fromCharCode(ch);
            break;
        }

        ++this.state.curLine;
        this.state.lineStart = this.state.pos;
        chunkStart = this.state.pos;
      } else {
        ++this.state.pos;
      }
    }
  };

  _proto.readEscapedChar = function readEscapedChar(inTemplate) {
    var throwOnInvalid = !inTemplate;
    var ch = this.input.charCodeAt(++this.state.pos);
    ++this.state.pos;

    switch (ch) {
      case 110:
        return "\n";

      case 114:
        return "\r";

      case 120:
        {
          var code = this.readHexChar(2, throwOnInvalid);
          return code === null ? null : String.fromCharCode(code);
        }

      case 117:
        {
          var _code = this.readCodePoint(throwOnInvalid);

          return _code === null ? null : codePointToString(_code);
        }

      case 116:
        return "\t";

      case 98:
        return "\b";

      case 118:
        return "\x0B";

      case 102:
        return "\f";

      case 13:
        if (this.input.charCodeAt(this.state.pos) === 10) {
          ++this.state.pos;
        }

      case 10:
        this.state.lineStart = this.state.pos;
        ++this.state.curLine;
        return "";

      default:
        if (ch >= 48 && ch <= 55) {
          var codePos = this.state.pos - 1;
          var octalStr = this.input.substr(this.state.pos - 1, 3).match(/^[0-7]+/)[0];
          var octal = parseInt(octalStr, 8);

          if (octal > 255) {
            octalStr = octalStr.slice(0, -1);
            octal = parseInt(octalStr, 8);
          }

          if (octal > 0) {
            if (inTemplate) {
              this.state.invalidTemplateEscapePosition = codePos;
              return null;
            } else if (this.state.strict) {
              this.raise(codePos, "Octal literal in strict mode");
            } else if (!this.state.containsOctal) {
              this.state.containsOctal = true;
              this.state.octalPosition = codePos;
            }
          }

          this.state.pos += octalStr.length - 1;
          return String.fromCharCode(octal);
        }

        return String.fromCharCode(ch);
    }
  };

  _proto.readHexChar = function readHexChar(len, throwOnInvalid) {
    var codePos = this.state.pos;
    var n = this.readInt(16, len);

    if (n === null) {
      if (throwOnInvalid) {
        this.raise(codePos, "Bad character escape sequence");
      } else {
        this.state.pos = codePos - 1;
        this.state.invalidTemplateEscapePosition = codePos - 1;
      }
    }

    return n;
  };

  _proto.readWord1 = function readWord1() {
    this.state.containsEsc = false;
    var word = "",
        first = true,
        chunkStart = this.state.pos;

    while (this.state.pos < this.input.length) {
      var ch = this.fullCharCodeAtPos();

      if (isIdentifierChar(ch)) {
        this.state.pos += ch <= 0xffff ? 1 : 2;
      } else if (this.state.isIterator && ch === 64) {
        this.state.pos += 1;
      } else if (ch === 92) {
        this.state.containsEsc = true;
        word += this.input.slice(chunkStart, this.state.pos);
        var escStart = this.state.pos;

        if (this.input.charCodeAt(++this.state.pos) !== 117) {
          this.raise(this.state.pos, "Expecting Unicode escape sequence \\uXXXX");
        }

        ++this.state.pos;
        var esc = this.readCodePoint(true);

        if (!(first ? isIdentifierStart : isIdentifierChar)(esc, true)) {
          this.raise(escStart, "Invalid Unicode escape");
        }

        word += codePointToString(esc);
        chunkStart = this.state.pos;
      } else {
        break;
      }

      first = false;
    }

    return word + this.input.slice(chunkStart, this.state.pos);
  };

  _proto.isIterator = function isIterator(word) {
    return word === "@@iterator" || word === "@@asyncIterator";
  };

  _proto.readWord = function readWord() {
    var word = this.readWord1();
    var type = types.name;

    if (this.isKeyword(word)) {
      if (this.state.containsEsc) {
        this.raise(this.state.pos, "Escape sequence in keyword " + word);
      }

      type = keywords[word];
    }

    if (this.state.isIterator && (!this.isIterator(word) || !this.state.inType)) {
      this.raise(this.state.pos, "Invalid identifier " + word);
    }

    this.finishToken(type, word);
  };

  _proto.braceIsBlock = function braceIsBlock(prevType) {
    if (prevType === types.colon) {
      var parent = this.curContext();

      if (parent === types$1.braceStatement || parent === types$1.braceExpression) {
        return !parent.isExpr;
      }
    }

    if (prevType === types._return) {
      return lineBreak.test(this.input.slice(this.state.lastTokEnd, this.state.start));
    }

    if (prevType === types._else || prevType === types.semi || prevType === types.eof || prevType === types.parenR) {
      return true;
    }

    if (prevType === types.braceL) {
      return this.curContext() === types$1.braceStatement;
    }

    if (prevType === types.relational) {
      return true;
    }

    return !this.state.exprAllowed;
  };

  _proto.updateContext = function updateContext(prevType) {
    var type = this.state.type;
    var update;

    if (type.keyword && (prevType === types.dot || prevType === types.questionDot)) {
      this.state.exprAllowed = false;
    } else if (update = type.updateContext) {
      update.call(this, prevType);
    } else {
      this.state.exprAllowed = type.beforeExpr;
    }
  };

  _inheritsLoose(Tokenizer, _LocationParser);

  return Tokenizer;
}(LocationParser);

var UtilParser = function (_Tokenizer) {
  function UtilParser() {
    return _Tokenizer.apply(this, arguments) || this;
  }

  var _proto = UtilParser.prototype;

  _proto.addExtra = function addExtra(node, key, val) {
    if (!node) return;
    var extra = node.extra = node.extra || {};
    extra[key] = val;
  };

  _proto.isRelational = function isRelational(op) {
    return this.match(types.relational) && this.state.value === op;
  };

  _proto.expectRelational = function expectRelational(op) {
    if (this.isRelational(op)) {
      this.next();
    } else {
      this.unexpected(null, types.relational);
    }
  };

  _proto.eatRelational = function eatRelational(op) {
    if (this.isRelational(op)) {
      this.next();
      return true;
    }

    return false;
  };

  _proto.isContextual = function isContextual(name) {
    return this.match(types.name) && this.state.value === name && !this.state.containsEsc;
  };

  _proto.isLookaheadContextual = function isLookaheadContextual(name) {
    var l = this.lookahead();
    return l.type === types.name && l.value === name;
  };

  _proto.eatContextual = function eatContextual(name) {
    return this.isContextual(name) && this.eat(types.name);
  };

  _proto.expectContextual = function expectContextual(name, message) {
    if (!this.eatContextual(name)) this.unexpected(null, message);
  };

  _proto.canInsertSemicolon = function canInsertSemicolon() {
    return this.match(types.eof) || this.match(types.braceR) || this.hasPrecedingLineBreak();
  };

  _proto.hasPrecedingLineBreak = function hasPrecedingLineBreak() {
    return lineBreak.test(this.input.slice(this.state.lastTokEnd, this.state.start));
  };

  _proto.isLineTerminator = function isLineTerminator() {
    return this.eat(types.semi) || this.canInsertSemicolon();
  };

  _proto.semicolon = function semicolon() {
    if (!this.isLineTerminator()) this.unexpected(null, types.semi);
  };

  _proto.expect = function expect(type, pos) {
    this.eat(type) || this.unexpected(pos, type);
  };

  _proto.unexpected = function unexpected(pos, messageOrType) {
    if (messageOrType === void 0) {
      messageOrType = "Unexpected token";
    }

    if (typeof messageOrType !== "string") {
      messageOrType = "Unexpected token, expected \"" + messageOrType.label + "\"";
    }

    throw this.raise(pos != null ? pos : this.state.start, messageOrType);
  };

  _proto.expectPlugin = function expectPlugin(name, pos) {
    if (!this.hasPlugin(name)) {
      throw this.raise(pos != null ? pos : this.state.start, "This experimental syntax requires enabling the parser plugin: '" + name + "'", {
        missingPluginNames: [name]
      });
    }

    return true;
  };

  _proto.expectOnePlugin = function expectOnePlugin(names, pos) {
    var _this = this;

    if (!names.some(function (n) {
      return _this.hasPlugin(n);
    })) {
      throw this.raise(pos != null ? pos : this.state.start, "This experimental syntax requires enabling one of the following parser plugin(s): '" + names.join(", ") + "'", {
        missingPluginNames: names
      });
    }
  };

  _inheritsLoose(UtilParser, _Tokenizer);

  return UtilParser;
}(Tokenizer);

var commentKeys = ["leadingComments", "trailingComments", "innerComments"];

var Node = function () {
  function Node(parser, pos, loc) {
    this.type = "";
    this.start = pos;
    this.end = 0;
    this.loc = new SourceLocation(loc);
    if (parser && parser.options.ranges) this.range = [pos, 0];
    if (parser && parser.filename) this.loc.filename = parser.filename;
  }

  var _proto = Node.prototype;

  _proto.__clone = function __clone() {
    var _this = this;

    var node2 = new Node();
    Object.keys(this).forEach(function (key) {
      if (commentKeys.indexOf(key) < 0) {
        node2[key] = _this[key];
      }
    });
    return node2;
  };

  return Node;
}();

var NodeUtils = function (_UtilParser) {
  function NodeUtils() {
    return _UtilParser.apply(this, arguments) || this;
  }

  var _proto2 = NodeUtils.prototype;

  _proto2.startNode = function startNode() {
    return new Node(this, this.state.start, this.state.startLoc);
  };

  _proto2.startNodeAt = function startNodeAt(pos, loc) {
    return new Node(this, pos, loc);
  };

  _proto2.startNodeAtNode = function startNodeAtNode(type) {
    return this.startNodeAt(type.start, type.loc.start);
  };

  _proto2.finishNode = function finishNode(node, type) {
    return this.finishNodeAt(node, type, this.state.lastTokEnd, this.state.lastTokEndLoc);
  };

  _proto2.finishNodeAt = function finishNodeAt(node, type, pos, loc) {
    node.type = type;
    node.end = pos;
    node.loc.end = loc;
    if (this.options.ranges) node.range[1] = pos;
    this.processComment(node);
    return node;
  };

  _proto2.resetStartLocationFromNode = function resetStartLocationFromNode(node, locationNode) {
    node.start = locationNode.start;
    node.loc.start = locationNode.loc.start;
    if (this.options.ranges) node.range[0] = locationNode.range[0];
  };

  _inheritsLoose(NodeUtils, _UtilParser);

  return NodeUtils;
}(UtilParser);

var LValParser = function (_NodeUtils) {
  function LValParser() {
    return _NodeUtils.apply(this, arguments) || this;
  }

  var _proto = LValParser.prototype;

  _proto.toAssignable = function toAssignable(node, isBinding, contextDescription) {
    if (node) {
      switch (node.type) {
        case "Identifier":
        case "ObjectPattern":
        case "ArrayPattern":
        case "AssignmentPattern":
          break;

        case "ObjectExpression":
          node.type = "ObjectPattern";

          for (var index = 0; index < node.properties.length; index++) {
            var prop = node.properties[index];
            var isLast = index === node.properties.length - 1;
            this.toAssignableObjectExpressionProp(prop, isBinding, isLast);
          }

          break;

        case "ObjectProperty":
          this.toAssignable(node.value, isBinding, contextDescription);
          break;

        case "SpreadElement":
          {
            this.checkToRestConversion(node);
            node.type = "RestElement";
            var arg = node.argument;
            this.toAssignable(arg, isBinding, contextDescription);
            break;
          }

        case "ArrayExpression":
          node.type = "ArrayPattern";
          this.toAssignableList(node.elements, isBinding, contextDescription);
          break;

        case "AssignmentExpression":
          if (node.operator === "=") {
            node.type = "AssignmentPattern";
            delete node.operator;
          } else {
            this.raise(node.left.end, "Only '=' operator can be used for specifying default value.");
          }

          break;

        case "MemberExpression":
          if (!isBinding) break;

        default:
          {
            var message = "Invalid left-hand side" + (contextDescription ? " in " + contextDescription : "expression");
            this.raise(node.start, message);
          }
      }
    }

    return node;
  };

  _proto.toAssignableObjectExpressionProp = function toAssignableObjectExpressionProp(prop, isBinding, isLast) {
    if (prop.type === "ObjectMethod") {
      var error = prop.kind === "get" || prop.kind === "set" ? "Object pattern can't contain getter or setter" : "Object pattern can't contain methods";
      this.raise(prop.key.start, error);
    } else if (prop.type === "SpreadElement" && !isLast) {
      this.raise(prop.start, "The rest element has to be the last element when destructuring");
    } else {
      this.toAssignable(prop, isBinding, "object destructuring pattern");
    }
  };

  _proto.toAssignableList = function toAssignableList(exprList, isBinding, contextDescription) {
    var end = exprList.length;

    if (end) {
      var last = exprList[end - 1];

      if (last && last.type === "RestElement") {
        --end;
      } else if (last && last.type === "SpreadElement") {
        last.type = "RestElement";
        var arg = last.argument;
        this.toAssignable(arg, isBinding, contextDescription);

        if (["Identifier", "MemberExpression", "ArrayPattern", "ObjectPattern"].indexOf(arg.type) === -1) {
          this.unexpected(arg.start);
        }

        --end;
      }
    }

    for (var i = 0; i < end; i++) {
      var elt = exprList[i];

      if (elt && elt.type === "SpreadElement") {
        this.raise(elt.start, "The rest element has to be the last element when destructuring");
      }

      if (elt) this.toAssignable(elt, isBinding, contextDescription);
    }

    return exprList;
  };

  _proto.toReferencedList = function toReferencedList(exprList) {
    return exprList;
  };

  _proto.parseSpread = function parseSpread(refShorthandDefaultPos, refNeedsArrowPos) {
    var node = this.startNode();
    this.next();
    node.argument = this.parseMaybeAssign(false, refShorthandDefaultPos, undefined, refNeedsArrowPos);
    return this.finishNode(node, "SpreadElement");
  };

  _proto.parseRest = function parseRest() {
    var node = this.startNode();
    this.next();
    node.argument = this.parseBindingAtom();
    return this.finishNode(node, "RestElement");
  };

  _proto.shouldAllowYieldIdentifier = function shouldAllowYieldIdentifier() {
    return this.match(types._yield) && !this.state.strict && !this.state.inGenerator;
  };

  _proto.parseBindingIdentifier = function parseBindingIdentifier() {
    return this.parseIdentifier(this.shouldAllowYieldIdentifier());
  };

  _proto.parseBindingAtom = function parseBindingAtom() {
    switch (this.state.type) {
      case types._yield:
      case types.name:
        return this.parseBindingIdentifier();

      case types.bracketL:
        {
          var node = this.startNode();
          this.next();
          node.elements = this.parseBindingList(types.bracketR, true);
          return this.finishNode(node, "ArrayPattern");
        }

      case types.braceL:
        return this.parseObj(true);

      default:
        throw this.unexpected();
    }
  };

  _proto.parseBindingList = function parseBindingList(close, allowEmpty, allowModifiers) {
    var elts = [];
    var first = true;

    while (!this.eat(close)) {
      if (first) {
        first = false;
      } else {
        this.expect(types.comma);
      }

      if (allowEmpty && this.match(types.comma)) {
        elts.push(null);
      } else if (this.eat(close)) {
        break;
      } else if (this.match(types.ellipsis)) {
        elts.push(this.parseAssignableListItemTypes(this.parseRest()));
        this.expect(close);
        break;
      } else {
        var decorators = [];

        if (this.match(types.at) && this.hasPlugin("decorators")) {
          this.raise(this.state.start, "Stage 2 decorators cannot be used to decorate parameters");
        }

        while (this.match(types.at)) {
          decorators.push(this.parseDecorator());
        }

        elts.push(this.parseAssignableListItem(allowModifiers, decorators));
      }
    }

    return elts;
  };

  _proto.parseAssignableListItem = function parseAssignableListItem(allowModifiers, decorators) {
    var left = this.parseMaybeDefault();
    this.parseAssignableListItemTypes(left);
    var elt = this.parseMaybeDefault(left.start, left.loc.start, left);

    if (decorators.length) {
      left.decorators = decorators;
    }

    return elt;
  };

  _proto.parseAssignableListItemTypes = function parseAssignableListItemTypes(param) {
    return param;
  };

  _proto.parseMaybeDefault = function parseMaybeDefault(startPos, startLoc, left) {
    startLoc = startLoc || this.state.startLoc;
    startPos = startPos || this.state.start;
    left = left || this.parseBindingAtom();
    if (!this.eat(types.eq)) return left;
    var node = this.startNodeAt(startPos, startLoc);
    node.left = left;
    node.right = this.parseMaybeAssign();
    return this.finishNode(node, "AssignmentPattern");
  };

  _proto.checkLVal = function checkLVal(expr, isBinding, checkClashes, contextDescription) {
    switch (expr.type) {
      case "Identifier":
        this.checkReservedWord(expr.name, expr.start, false, true);

        if (checkClashes) {
          var _key = "_" + expr.name;

          if (checkClashes[_key]) {
            this.raise(expr.start, "Argument name clash in strict mode");
          } else {
            checkClashes[_key] = true;
          }
        }

        break;

      case "MemberExpression":
        if (isBinding) this.raise(expr.start, "Binding member expression");
        break;

      case "ObjectPattern":
        for (var _i2 = 0, _expr$properties2 = expr.properties; _i2 < _expr$properties2.length; _i2++) {
          var prop = _expr$properties2[_i2];
          if (prop.type === "ObjectProperty") prop = prop.value;
          this.checkLVal(prop, isBinding, checkClashes, "object destructuring pattern");
        }

        break;

      case "ArrayPattern":
        for (var _i4 = 0, _expr$elements2 = expr.elements; _i4 < _expr$elements2.length; _i4++) {
          var elem = _expr$elements2[_i4];

          if (elem) {
            this.checkLVal(elem, isBinding, checkClashes, "array destructuring pattern");
          }
        }

        break;

      case "AssignmentPattern":
        this.checkLVal(expr.left, isBinding, checkClashes, "assignment pattern");
        break;

      case "RestElement":
        this.checkLVal(expr.argument, isBinding, checkClashes, "rest element");
        break;

      default:
        {
          var message = (isBinding ? "Binding invalid" : "Invalid") + " left-hand side" + (contextDescription ? " in " + contextDescription : "expression");
          this.raise(expr.start, message);
        }
    }
  };

  _proto.checkToRestConversion = function checkToRestConversion(node) {
    var validArgumentTypes = ["Identifier", "MemberExpression"];

    if (validArgumentTypes.indexOf(node.argument.type) !== -1) {
      return;
    }

    this.raise(node.argument.start, "Invalid rest operator's argument");
  };

  _inheritsLoose(LValParser, _NodeUtils);

  return LValParser;
}(NodeUtils);

var ExpressionParser = function (_LValParser) {
  function ExpressionParser() {
    return _LValParser.apply(this, arguments) || this;
  }

  var _proto = ExpressionParser.prototype;

  _proto.checkPropClash = function checkPropClash(prop, propHash) {
    if (prop.computed || prop.kind) return;
    var key = prop.key;
    var name = key.type === "Identifier" ? key.name : String(key.value);

    if (name === "__proto__") {
      if (propHash.proto) {
        this.raise(key.start, "Redefinition of __proto__ property");
      }

      propHash.proto = true;
    }
  };

  _proto.getExpression = function getExpression() {
    this.nextToken();
    var expr = this.parseExpression();

    if (!this.match(types.eof)) {
      this.unexpected();
    }

    expr.comments = this.state.comments;
    return expr;
  };

  _proto.parseExpression = function parseExpression(noIn, refShorthandDefaultPos) {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    var expr = this.parseMaybeAssign(noIn, refShorthandDefaultPos);

    if (this.match(types.comma)) {
      var _node = this.startNodeAt(startPos, startLoc);

      _node.expressions = [expr];

      while (this.eat(types.comma)) {
        _node.expressions.push(this.parseMaybeAssign(noIn, refShorthandDefaultPos));
      }

      this.toReferencedList(_node.expressions);
      return this.finishNode(_node, "SequenceExpression");
    }

    return expr;
  };

  _proto.parseMaybeAssign = function parseMaybeAssign(noIn, refShorthandDefaultPos, afterLeftParse, refNeedsArrowPos) {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;

    if (this.match(types._yield) && this.state.inGenerator) {
      var _left = this.parseYield();

      if (afterLeftParse) {
        _left = afterLeftParse.call(this, _left, startPos, startLoc);
      }

      return _left;
    }

    var failOnShorthandAssign;

    if (refShorthandDefaultPos) {
      failOnShorthandAssign = false;
    } else {
      refShorthandDefaultPos = {
        start: 0
      };
      failOnShorthandAssign = true;
    }

    if (this.match(types.parenL) || this.match(types.name) || this.match(types._yield)) {
      this.state.potentialArrowAt = this.state.start;
    }

    var left = this.parseMaybeConditional(noIn, refShorthandDefaultPos, refNeedsArrowPos);

    if (afterLeftParse) {
      left = afterLeftParse.call(this, left, startPos, startLoc);
    }

    if (this.state.type.isAssign) {
      var _node2 = this.startNodeAt(startPos, startLoc);

      var operator = this.state.value;
      _node2.operator = operator;

      if (operator === "??=") {
        this.expectPlugin("nullishCoalescingOperator");
        this.expectPlugin("logicalAssignment");
      }

      if (operator === "||=" || operator === "&&=") {
        this.expectPlugin("logicalAssignment");
      }

      _node2.left = this.match(types.eq) ? this.toAssignable(left, undefined, "assignment expression") : left;
      refShorthandDefaultPos.start = 0;
      this.checkLVal(left, undefined, undefined, "assignment expression");

      if (left.extra && left.extra.parenthesized) {
        var errorMsg;

        if (left.type === "ObjectPattern") {
          errorMsg = "`({a}) = 0` use `({a} = 0)`";
        } else if (left.type === "ArrayPattern") {
          errorMsg = "`([a]) = 0` use `([a] = 0)`";
        }

        if (errorMsg) {
          this.raise(left.start, "You're trying to assign to a parenthesized expression, eg. instead of " + errorMsg);
        }
      }

      this.next();
      _node2.right = this.parseMaybeAssign(noIn);
      return this.finishNode(_node2, "AssignmentExpression");
    } else if (failOnShorthandAssign && refShorthandDefaultPos.start) {
      this.unexpected(refShorthandDefaultPos.start);
    }

    return left;
  };

  _proto.parseMaybeConditional = function parseMaybeConditional(noIn, refShorthandDefaultPos, refNeedsArrowPos) {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    var potentialArrowAt = this.state.potentialArrowAt;
    var expr = this.parseExprOps(noIn, refShorthandDefaultPos);

    if (expr.type === "ArrowFunctionExpression" && expr.start === potentialArrowAt) {
      return expr;
    }

    if (refShorthandDefaultPos && refShorthandDefaultPos.start) return expr;
    return this.parseConditional(expr, noIn, startPos, startLoc, refNeedsArrowPos);
  };

  _proto.parseConditional = function parseConditional(expr, noIn, startPos, startLoc, refNeedsArrowPos) {
    if (this.eat(types.question)) {
      var _node3 = this.startNodeAt(startPos, startLoc);

      _node3.test = expr;
      _node3.consequent = this.parseMaybeAssign();
      this.expect(types.colon);
      _node3.alternate = this.parseMaybeAssign(noIn);
      return this.finishNode(_node3, "ConditionalExpression");
    }

    return expr;
  };

  _proto.parseExprOps = function parseExprOps(noIn, refShorthandDefaultPos) {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    var potentialArrowAt = this.state.potentialArrowAt;
    var expr = this.parseMaybeUnary(refShorthandDefaultPos);

    if (expr.type === "ArrowFunctionExpression" && expr.start === potentialArrowAt) {
      return expr;
    }

    if (refShorthandDefaultPos && refShorthandDefaultPos.start) {
      return expr;
    }

    return this.parseExprOp(expr, startPos, startLoc, -1, noIn);
  };

  _proto.parseExprOp = function parseExprOp(left, leftStartPos, leftStartLoc, minPrec, noIn) {
    var prec = this.state.type.binop;

    if (prec != null && (!noIn || !this.match(types._in))) {
      if (prec > minPrec) {
        var _node4 = this.startNodeAt(leftStartPos, leftStartLoc);

        var operator = this.state.value;
        _node4.left = left;
        _node4.operator = operator;

        if (operator === "**" && left.type === "UnaryExpression" && left.extra && !left.extra.parenthesizedArgument && !left.extra.parenthesized) {
          this.raise(left.argument.start, "Illegal expression. Wrap left hand side or entire exponentiation in parentheses.");
        }

        var op = this.state.type;

        if (op === types.nullishCoalescing) {
          this.expectPlugin("nullishCoalescingOperator");
        } else if (op === types.pipeline) {
          this.expectPlugin("pipelineOperator");
        }

        this.next();
        var startPos = this.state.start;
        var startLoc = this.state.startLoc;

        if (op === types.pipeline) {
          if (this.match(types.name) && this.state.value === "await" && this.state.inAsync) {
            throw this.raise(this.state.start, "Unexpected \"await\" after pipeline body; await must have parentheses in minimal proposal");
          }
        }

        _node4.right = this.parseExprOp(this.parseMaybeUnary(), startPos, startLoc, op.rightAssociative ? prec - 1 : prec, noIn);
        this.finishNode(_node4, op === types.logicalOR || op === types.logicalAND || op === types.nullishCoalescing ? "LogicalExpression" : "BinaryExpression");
        return this.parseExprOp(_node4, leftStartPos, leftStartLoc, minPrec, noIn);
      }
    }

    return left;
  };

  _proto.parseMaybeUnary = function parseMaybeUnary(refShorthandDefaultPos) {
    if (this.state.type.prefix) {
      var _node5 = this.startNode();

      var update = this.match(types.incDec);
      _node5.operator = this.state.value;
      _node5.prefix = true;

      if (_node5.operator === "throw") {
        this.expectPlugin("throwExpressions");
      }

      this.next();
      var argType = this.state.type;
      _node5.argument = this.parseMaybeUnary();
      this.addExtra(_node5, "parenthesizedArgument", argType === types.parenL && (!_node5.argument.extra || !_node5.argument.extra.parenthesized));

      if (refShorthandDefaultPos && refShorthandDefaultPos.start) {
        this.unexpected(refShorthandDefaultPos.start);
      }

      if (update) {
        this.checkLVal(_node5.argument, undefined, undefined, "prefix operation");
      } else if (this.state.strict && _node5.operator === "delete") {
        var arg = _node5.argument;

        if (arg.type === "Identifier") {
          this.raise(_node5.start, "Deleting local variable in strict mode");
        } else if (arg.type === "MemberExpression" && arg.property.type === "PrivateName") {
          this.raise(_node5.start, "Deleting a private field is not allowed");
        }
      }

      return this.finishNode(_node5, update ? "UpdateExpression" : "UnaryExpression");
    }

    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    var expr = this.parseExprSubscripts(refShorthandDefaultPos);
    if (refShorthandDefaultPos && refShorthandDefaultPos.start) return expr;

    while (this.state.type.postfix && !this.canInsertSemicolon()) {
      var _node6 = this.startNodeAt(startPos, startLoc);

      _node6.operator = this.state.value;
      _node6.prefix = false;
      _node6.argument = expr;
      this.checkLVal(expr, undefined, undefined, "postfix operation");
      this.next();
      expr = this.finishNode(_node6, "UpdateExpression");
    }

    return expr;
  };

  _proto.parseExprSubscripts = function parseExprSubscripts(refShorthandDefaultPos) {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    var potentialArrowAt = this.state.potentialArrowAt;
    var expr = this.parseExprAtom(refShorthandDefaultPos);

    if (expr.type === "ArrowFunctionExpression" && expr.start === potentialArrowAt) {
      return expr;
    }

    if (refShorthandDefaultPos && refShorthandDefaultPos.start) {
      return expr;
    }

    return this.parseSubscripts(expr, startPos, startLoc);
  };

  _proto.parseSubscripts = function parseSubscripts(base, startPos, startLoc, noCalls) {
    var state = {
      optionalChainMember: false,
      stop: false
    };

    do {
      base = this.parseSubscript(base, startPos, startLoc, noCalls, state);
    } while (!state.stop);

    return base;
  };

  _proto.parseSubscript = function parseSubscript(base, startPos, startLoc, noCalls, state) {
    if (!noCalls && this.eat(types.doubleColon)) {
      var _node7 = this.startNodeAt(startPos, startLoc);

      _node7.object = base;
      _node7.callee = this.parseNoCallExpr();
      state.stop = true;
      return this.parseSubscripts(this.finishNode(_node7, "BindExpression"), startPos, startLoc, noCalls);
    } else if (this.match(types.questionDot)) {
      this.expectPlugin("optionalChaining");
      state.optionalChainMember = true;

      if (noCalls && this.lookahead().type == types.parenL) {
        state.stop = true;
        return base;
      }

      this.next();

      var _node8 = this.startNodeAt(startPos, startLoc);

      if (this.eat(types.bracketL)) {
        _node8.object = base;
        _node8.property = this.parseExpression();
        _node8.computed = true;
        _node8.optional = true;
        this.expect(types.bracketR);
        return this.finishNode(_node8, "OptionalMemberExpression");
      } else if (this.eat(types.parenL)) {
        var possibleAsync = this.atPossibleAsync(base);
        _node8.callee = base;
        _node8.arguments = this.parseCallExpressionArguments(types.parenR, possibleAsync);
        _node8.optional = true;
        return this.finishNode(_node8, "OptionalCallExpression");
      } else {
        _node8.object = base;
        _node8.property = this.parseIdentifier(true);
        _node8.computed = false;
        _node8.optional = true;
        return this.finishNode(_node8, "OptionalMemberExpression");
      }
    } else if (this.eat(types.dot)) {
      var _node9 = this.startNodeAt(startPos, startLoc);

      _node9.object = base;
      _node9.property = this.parseMaybePrivateName();
      _node9.computed = false;

      if (state.optionalChainMember) {
        _node9.optional = false;
        return this.finishNode(_node9, "OptionalMemberExpression");
      }

      return this.finishNode(_node9, "MemberExpression");
    } else if (this.eat(types.bracketL)) {
      var _node10 = this.startNodeAt(startPos, startLoc);

      _node10.object = base;
      _node10.property = this.parseExpression();
      _node10.computed = true;
      this.expect(types.bracketR);

      if (state.optionalChainMember) {
        _node10.optional = false;
        return this.finishNode(_node10, "OptionalMemberExpression");
      }

      return this.finishNode(_node10, "MemberExpression");
    } else if (!noCalls && this.match(types.parenL)) {
      var _possibleAsync = this.atPossibleAsync(base);

      this.next();

      var _node11 = this.startNodeAt(startPos, startLoc);

      _node11.callee = base;
      var refTrailingCommaPos = {
        start: -1
      };
      _node11.arguments = this.parseCallExpressionArguments(types.parenR, _possibleAsync, refTrailingCommaPos);

      if (!state.optionalChainMember) {
        this.finishCallExpression(_node11);
      } else {
        this.finishOptionalCallExpression(_node11);
      }

      if (_possibleAsync && this.shouldParseAsyncArrow()) {
        state.stop = true;

        if (refTrailingCommaPos.start > -1) {
          this.raise(refTrailingCommaPos.start, "A trailing comma is not permitted after the rest element");
        }

        return this.parseAsyncArrowFromCallExpression(this.startNodeAt(startPos, startLoc), _node11);
      } else {
        this.toReferencedList(_node11.arguments);
      }

      return _node11;
    } else if (this.match(types.backQuote)) {
      var _node12 = this.startNodeAt(startPos, startLoc);

      _node12.tag = base;
      _node12.quasi = this.parseTemplate(true);

      if (state.optionalChainMember) {
        this.raise(startPos, "Tagged Template Literals are not allowed in optionalChain");
      }

      return this.finishNode(_node12, "TaggedTemplateExpression");
    } else {
      state.stop = true;
      return base;
    }
  };

  _proto.atPossibleAsync = function atPossibleAsync(base) {
    return !this.state.containsEsc && this.state.potentialArrowAt === base.start && base.type === "Identifier" && base.name === "async" && !this.canInsertSemicolon();
  };

  _proto.finishCallExpression = function finishCallExpression(node) {
    if (node.callee.type === "Import") {
      if (node.arguments.length !== 1) {
        this.raise(node.start, "import() requires exactly one argument");
      }

      var importArg = node.arguments[0];

      if (importArg && importArg.type === "SpreadElement") {
        this.raise(importArg.start, "... is not allowed in import()");
      }
    }

    return this.finishNode(node, "CallExpression");
  };

  _proto.finishOptionalCallExpression = function finishOptionalCallExpression(node) {
    if (node.callee.type === "Import") {
      if (node.arguments.length !== 1) {
        this.raise(node.start, "import() requires exactly one argument");
      }

      var importArg = node.arguments[0];

      if (importArg && importArg.type === "SpreadElement") {
        this.raise(importArg.start, "... is not allowed in import()");
      }
    }

    return this.finishNode(node, "OptionalCallExpression");
  };

  _proto.parseCallExpressionArguments = function parseCallExpressionArguments(close, possibleAsyncArrow, refTrailingCommaPos) {
    var elts = [];
    var innerParenStart;
    var first = true;

    while (!this.eat(close)) {
      if (first) {
        first = false;
      } else {
        this.expect(types.comma);
        if (this.eat(close)) break;
      }

      if (this.match(types.parenL) && !innerParenStart) {
        innerParenStart = this.state.start;
      }

      elts.push(this.parseExprListItem(false, possibleAsyncArrow ? {
        start: 0
      } : undefined, possibleAsyncArrow ? {
        start: 0
      } : undefined, possibleAsyncArrow ? refTrailingCommaPos : undefined));
    }

    if (possibleAsyncArrow && innerParenStart && this.shouldParseAsyncArrow()) {
      this.unexpected();
    }

    return elts;
  };

  _proto.shouldParseAsyncArrow = function shouldParseAsyncArrow() {
    return this.match(types.arrow);
  };

  _proto.parseAsyncArrowFromCallExpression = function parseAsyncArrowFromCallExpression(node, call) {
    var oldYield = this.state.yieldInPossibleArrowParameters;
    this.state.yieldInPossibleArrowParameters = null;
    this.expect(types.arrow);
    this.parseArrowExpression(node, call.arguments, true);
    this.state.yieldInPossibleArrowParameters = oldYield;
    return node;
  };

  _proto.parseNoCallExpr = function parseNoCallExpr() {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    return this.parseSubscripts(this.parseExprAtom(), startPos, startLoc, true);
  };

  _proto.parseExprAtom = function parseExprAtom(refShorthandDefaultPos) {
    var canBeArrow = this.state.potentialArrowAt === this.state.start;
    var node;

    switch (this.state.type) {
      case types._super:
        if (!this.state.inMethod && !this.state.inClassProperty && !this.options.allowSuperOutsideMethod) {
          this.raise(this.state.start, "super is only allowed in object methods and classes");
        }

        node = this.startNode();
        this.next();

        if (!this.match(types.parenL) && !this.match(types.bracketL) && !this.match(types.dot)) {
          this.unexpected();
        }

        if (this.match(types.parenL) && this.state.inMethod !== "constructor" && !this.options.allowSuperOutsideMethod) {
          this.raise(node.start, "super() is only valid inside a class constructor. " + "Make sure the method name is spelled exactly as 'constructor'.");
        }

        return this.finishNode(node, "Super");

      case types._import:
        if (this.lookahead().type === types.dot) {
          return this.parseImportMetaProperty();
        }

        this.expectPlugin("dynamicImport");
        node = this.startNode();
        this.next();

        if (!this.match(types.parenL)) {
          this.unexpected(null, types.parenL);
        }

        return this.finishNode(node, "Import");

      case types._this:
        node = this.startNode();
        this.next();
        return this.finishNode(node, "ThisExpression");

      case types._yield:
        if (this.state.inGenerator) this.unexpected();

      case types.name:
        {
          node = this.startNode();
          var allowAwait = this.state.value === "await" && (this.state.inAsync || !this.state.inFunction && this.options.allowAwaitOutsideFunction);
          var containsEsc = this.state.containsEsc;
          var allowYield = this.shouldAllowYieldIdentifier();
          var id = this.parseIdentifier(allowAwait || allowYield);

          if (id.name === "await") {
            if (this.state.inAsync || this.inModule || !this.state.inFunction && this.options.allowAwaitOutsideFunction) {
              return this.parseAwait(node);
            }
          } else if (!containsEsc && id.name === "async" && this.match(types._function) && !this.canInsertSemicolon()) {
            this.next();
            return this.parseFunction(node, false, false, true);
          } else if (canBeArrow && id.name === "async" && this.match(types.name)) {
            var oldYield = this.state.yieldInPossibleArrowParameters;
            this.state.yieldInPossibleArrowParameters = null;
            var params = [this.parseIdentifier()];
            this.expect(types.arrow);
            this.parseArrowExpression(node, params, true);
            this.state.yieldInPossibleArrowParameters = oldYield;
            return node;
          }

          if (canBeArrow && !this.canInsertSemicolon() && this.eat(types.arrow)) {
            var _oldYield = this.state.yieldInPossibleArrowParameters;
            this.state.yieldInPossibleArrowParameters = null;
            this.parseArrowExpression(node, [id]);
            this.state.yieldInPossibleArrowParameters = _oldYield;
            return node;
          }

          return id;
        }

      case types._do:
        {
          this.expectPlugin("doExpressions");

          var _node13 = this.startNode();

          this.next();
          var oldInFunction = this.state.inFunction;
          var oldLabels = this.state.labels;
          this.state.labels = [];
          this.state.inFunction = false;
          _node13.body = this.parseBlock(false);
          this.state.inFunction = oldInFunction;
          this.state.labels = oldLabels;
          return this.finishNode(_node13, "DoExpression");
        }

      case types.regexp:
        {
          var value = this.state.value;
          node = this.parseLiteral(value.value, "RegExpLiteral");
          node.pattern = value.pattern;
          node.flags = value.flags;
          return node;
        }

      case types.num:
        return this.parseLiteral(this.state.value, "NumericLiteral");

      case types.bigint:
        return this.parseLiteral(this.state.value, "BigIntLiteral");

      case types.string:
        return this.parseLiteral(this.state.value, "StringLiteral");

      case types._null:
        node = this.startNode();
        this.next();
        return this.finishNode(node, "NullLiteral");

      case types._true:
      case types._false:
        return this.parseBooleanLiteral();

      case types.parenL:
        return this.parseParenAndDistinguishExpression(canBeArrow);

      case types.bracketL:
        node = this.startNode();
        this.next();
        node.elements = this.parseExprList(types.bracketR, true, refShorthandDefaultPos);
        this.toReferencedList(node.elements);
        return this.finishNode(node, "ArrayExpression");

      case types.braceL:
        return this.parseObj(false, refShorthandDefaultPos);

      case types._function:
        return this.parseFunctionExpression();

      case types.at:
        this.parseDecorators();

      case types._class:
        node = this.startNode();
        this.takeDecorators(node);
        return this.parseClass(node, false);

      case types._new:
        return this.parseNew();

      case types.backQuote:
        return this.parseTemplate(false);

      case types.doubleColon:
        {
          node = this.startNode();
          this.next();
          node.object = null;
          var callee = node.callee = this.parseNoCallExpr();

          if (callee.type === "MemberExpression") {
            return this.finishNode(node, "BindExpression");
          } else {
            throw this.raise(callee.start, "Binding should be performed on object property.");
          }
        }

      default:
        throw this.unexpected();
    }
  };

  _proto.parseBooleanLiteral = function parseBooleanLiteral() {
    var node = this.startNode();
    node.value = this.match(types._true);
    this.next();
    return this.finishNode(node, "BooleanLiteral");
  };

  _proto.parseMaybePrivateName = function parseMaybePrivateName() {
    var isPrivate = this.match(types.hash);

    if (isPrivate) {
      this.expectOnePlugin(["classPrivateProperties", "classPrivateMethods"]);

      var _node14 = this.startNode();

      this.next();
      _node14.id = this.parseIdentifier(true);
      return this.finishNode(_node14, "PrivateName");
    } else {
      return this.parseIdentifier(true);
    }
  };

  _proto.parseFunctionExpression = function parseFunctionExpression() {
    var node = this.startNode();
    var meta = this.parseIdentifier(true);

    if (this.state.inGenerator && this.eat(types.dot)) {
      return this.parseMetaProperty(node, meta, "sent");
    }

    return this.parseFunction(node, false);
  };

  _proto.parseMetaProperty = function parseMetaProperty(node, meta, propertyName) {
    node.meta = meta;

    if (meta.name === "function" && propertyName === "sent") {
      if (this.isContextual(propertyName)) {
        this.expectPlugin("functionSent");
      } else if (!this.hasPlugin("functionSent")) {
        this.unexpected();
      }
    }

    var containsEsc = this.state.containsEsc;
    node.property = this.parseIdentifier(true);

    if (node.property.name !== propertyName || containsEsc) {
      this.raise(node.property.start, "The only valid meta property for " + meta.name + " is " + meta.name + "." + propertyName);
    }

    return this.finishNode(node, "MetaProperty");
  };

  _proto.parseImportMetaProperty = function parseImportMetaProperty() {
    var node = this.startNode();
    var id = this.parseIdentifier(true);
    this.expect(types.dot);

    if (id.name === "import") {
      if (this.isContextual("meta")) {
        this.expectPlugin("importMeta");
      } else if (!this.hasPlugin("importMeta")) {
        this.raise(id.start, "Dynamic imports require a parameter: import('a.js').then");
      }
    }

    if (!this.inModule) {
      this.raise(id.start, "import.meta may appear only with 'sourceType: \"module\"'", {
        code: "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED"
      });
    }

    this.sawUnambiguousESM = true;
    return this.parseMetaProperty(node, id, "meta");
  };

  _proto.parseLiteral = function parseLiteral(value, type, startPos, startLoc) {
    startPos = startPos || this.state.start;
    startLoc = startLoc || this.state.startLoc;
    var node = this.startNodeAt(startPos, startLoc);
    this.addExtra(node, "rawValue", value);
    this.addExtra(node, "raw", this.input.slice(startPos, this.state.end));
    node.value = value;
    this.next();
    return this.finishNode(node, type);
  };

  _proto.parseParenExpression = function parseParenExpression() {
    this.expect(types.parenL);
    var val = this.parseExpression();
    this.expect(types.parenR);
    return val;
  };

  _proto.parseParenAndDistinguishExpression = function parseParenAndDistinguishExpression(canBeArrow) {
    var startPos = this.state.start;
    var startLoc = this.state.startLoc;
    var val;
    this.expect(types.parenL);
    var oldMaybeInArrowParameters = this.state.maybeInArrowParameters;
    var oldYield = this.state.yieldInPossibleArrowParameters;
    this.state.maybeInArrowParameters = true;
    this.state.yieldInPossibleArrowParameters = null;
    var innerStartPos = this.state.start;
    var innerStartLoc = this.state.startLoc;
    var exprList = [];
    var refShorthandDefaultPos = {
      start: 0
    };
    var refNeedsArrowPos = {
      start: 0
    };
    var first = true;
    var spreadStart;
    var optionalCommaStart;

    while (!this.match(types.parenR)) {
      if (first) {
        first = false;
      } else {
        this.expect(types.comma, refNeedsArrowPos.start || null);

        if (this.match(types.parenR)) {
          optionalCommaStart = this.state.start;
          break;
        }
      }

      if (this.match(types.ellipsis)) {
        var spreadNodeStartPos = this.state.start;
        var spreadNodeStartLoc = this.state.startLoc;
        spreadStart = this.state.start;
        exprList.push(this.parseParenItem(this.parseRest(), spreadNodeStartPos, spreadNodeStartLoc));

        if (this.match(types.comma) && this.lookahead().type === types.parenR) {
          this.raise(this.state.start, "A trailing comma is not permitted after the rest element");
        }

        break;
      } else {
        exprList.push(this.parseMaybeAssign(false, refShorthandDefaultPos, this.parseParenItem, refNeedsArrowPos));
      }
    }

    var innerEndPos = this.state.start;
    var innerEndLoc = this.state.startLoc;
    this.expect(types.parenR);
    this.state.maybeInArrowParameters = oldMaybeInArrowParameters;
    var arrowNode = this.startNodeAt(startPos, startLoc);

    if (canBeArrow && this.shouldParseArrow() && (arrowNode = this.parseArrow(arrowNode))) {
      for (var _i2 = 0; _i2 < exprList.length; _i2++) {
        var param = exprList[_i2];

        if (param.extra && param.extra.parenthesized) {
          this.unexpected(param.extra.parenStart);
        }
      }

      this.parseArrowExpression(arrowNode, exprList);
      this.state.yieldInPossibleArrowParameters = oldYield;
      return arrowNode;
    }

    this.state.yieldInPossibleArrowParameters = oldYield;

    if (!exprList.length) {
      this.unexpected(this.state.lastTokStart);
    }

    if (optionalCommaStart) this.unexpected(optionalCommaStart);
    if (spreadStart) this.unexpected(spreadStart);

    if (refShorthandDefaultPos.start) {
      this.unexpected(refShorthandDefaultPos.start);
    }

    if (refNeedsArrowPos.start) this.unexpected(refNeedsArrowPos.start);

    if (exprList.length > 1) {
      val = this.startNodeAt(innerStartPos, innerStartLoc);
      val.expressions = exprList;
      this.toReferencedList(val.expressions);
      this.finishNodeAt(val, "SequenceExpression", innerEndPos, innerEndLoc);
    } else {
      val = exprList[0];
    }

    this.addExtra(val, "parenthesized", true);
    this.addExtra(val, "parenStart", startPos);
    return val;
  };

  _proto.shouldParseArrow = function shouldParseArrow() {
    return !this.canInsertSemicolon();
  };

  _proto.parseArrow = function parseArrow(node) {
    if (this.eat(types.arrow)) {
      return node;
    }
  };

  _proto.parseParenItem = function parseParenItem(node, startPos, startLoc) {
    return node;
  };

  _proto.parseNew = function parseNew() {
    var node = this.startNode();
    var meta = this.parseIdentifier(true);

    if (this.eat(types.dot)) {
      var metaProp = this.parseMetaProperty(node, meta, "target");

      if (!this.state.inFunction && !this.state.inClassProperty) {
        var error = "new.target can only be used in functions";

        if (this.hasPlugin("classProperties")) {
          error += " or class properties";
        }

        this.raise(metaProp.start, error);
      }

      return metaProp;
    }

    node.callee = this.parseNoCallExpr();

    if (node.callee.type === "OptionalMemberExpression" || node.callee.type === "OptionalCallExpression") {
      this.raise(this.state.lastTokEnd, "constructors in/after an Optional Chain are not allowed");
    }

    if (this.eat(types.questionDot)) {
      this.raise(this.state.start, "constructors in/after an Optional Chain are not allowed");
    }

    this.parseNewArguments(node);
    return this.finishNode(node, "NewExpression");
  };

  _proto.parseNewArguments = function parseNewArguments(node) {
    if (this.eat(types.parenL)) {
      var args = this.parseExprList(types.parenR);
      this.toReferencedList(args);
      node.arguments = args;
    } else {
      node.arguments = [];
    }
  };

  _proto.parseTemplateElement = function parseTemplateElement(isTagged) {
    var elem = this.startNode();

    if (this.state.value === null) {
      if (!isTagged) {
        this.raise(this.state.invalidTemplateEscapePosition || 0, "Invalid escape sequence in template");
      } else {
        this.state.invalidTemplateEscapePosition = null;
      }
    }

    elem.value = {
      raw: this.input.slice(this.state.start, this.state.end).replace(/\r\n?/g, "\n"),
      cooked: this.state.value
    };
    this.next();
    elem.tail = this.match(types.backQuote);
    return this.finishNode(elem, "TemplateElement");
  };

  _proto.parseTemplate = function parseTemplate(isTagged) {
    var node = this.startNode();
    this.next();
    node.expressions = [];
    var curElt = this.parseTemplateElement(isTagged);
    node.quasis = [curElt];

    while (!curElt.tail) {
      this.expect(types.dollarBraceL);
      node.expressions.push(this.parseExpression());
      this.expect(types.braceR);
      node.quasis.push(curElt = this.parseTemplateElement(isTagged));
    }

    this.next();
    return this.finishNode(node, "TemplateLiteral");
  };

  _proto.parseObj = function parseObj(isPattern, refShorthandDefaultPos) {
    var decorators = [];
    var propHash = Object.create(null);
    var first = true;
    var node = this.startNode();
    node.properties = [];
    this.next();
    var firstRestLocation = null;

    while (!this.eat(types.braceR)) {
      if (first) {
        first = false;
      } else {
        this.expect(types.comma);
        if (this.eat(types.braceR)) break;
      }

      if (this.match(types.at)) {
        if (this.hasPlugin("decorators")) {
          this.raise(this.state.start, "Stage 2 decorators disallow object literal property decorators");
        } else {
          while (this.match(types.at)) {
            decorators.push(this.parseDecorator());
          }
        }
      }

      var prop = this.startNode(),
          isGenerator = false,
          _isAsync = false,
          startPos = void 0,
          startLoc = void 0;

      if (decorators.length) {
        prop.decorators = decorators;
        decorators = [];
      }

      if (this.match(types.ellipsis)) {
        this.expectPlugin("objectRestSpread");
        prop = this.parseSpread(isPattern ? {
          start: 0
        } : undefined);

        if (isPattern) {
          this.toAssignable(prop, true, "object pattern");
        }

        node.properties.push(prop);

        if (isPattern) {
          var position = this.state.start;

          if (firstRestLocation !== null) {
            this.unexpected(firstRestLocation, "Cannot have multiple rest elements when destructuring");
          } else if (this.eat(types.braceR)) {
            break;
          } else if (this.match(types.comma) && this.lookahead().type === types.braceR) {
            this.unexpected(position, "A trailing comma is not permitted after the rest element");
          } else {
            firstRestLocation = position;
            continue;
          }
        } else {
          continue;
        }
      }

      prop.method = false;

      if (isPattern || refShorthandDefaultPos) {
        startPos = this.state.start;
        startLoc = this.state.startLoc;
      }

      if (!isPattern) {
        isGenerator = this.eat(types.star);
      }

      var containsEsc = this.state.containsEsc;

      if (!isPattern && this.isContextual("async")) {
        if (isGenerator) this.unexpected();
        var asyncId = this.parseIdentifier();

        if (this.match(types.colon) || this.match(types.parenL) || this.match(types.braceR) || this.match(types.eq) || this.match(types.comma)) {
          prop.key = asyncId;
          prop.computed = false;
        } else {
          _isAsync = true;

          if (this.match(types.star)) {
            this.expectPlugin("asyncGenerators");
            this.next();
            isGenerator = true;
          }

          this.parsePropertyName(prop);
        }
      } else {
        this.parsePropertyName(prop);
      }

      this.parseObjPropValue(prop, startPos, startLoc, isGenerator, _isAsync, isPattern, refShorthandDefaultPos, containsEsc);
      this.checkPropClash(prop, propHash);

      if (prop.shorthand) {
        this.addExtra(prop, "shorthand", true);
      }

      node.properties.push(prop);
    }

    if (firstRestLocation !== null) {
      this.unexpected(firstRestLocation, "The rest element has to be the last element when destructuring");
    }

    if (decorators.length) {
      this.raise(this.state.start, "You have trailing decorators with no property");
    }

    return this.finishNode(node, isPattern ? "ObjectPattern" : "ObjectExpression");
  };

  _proto.isGetterOrSetterMethod = function isGetterOrSetterMethod(prop, isPattern) {
    return !isPattern && !prop.computed && prop.key.type === "Identifier" && (prop.key.name === "get" || prop.key.name === "set") && (this.match(types.string) || this.match(types.num) || this.match(types.bracketL) || this.match(types.name) || !!this.state.type.keyword);
  };

  _proto.checkGetterSetterParams = function checkGetterSetterParams(method) {
    var paramCount = method.kind === "get" ? 0 : 1;
    var start = method.start;

    if (method.params.length !== paramCount) {
      if (method.kind === "get") {
        this.raise(start, "getter must not have any formal parameters");
      } else {
        this.raise(start, "setter must have exactly one formal parameter");
      }
    }

    if (method.kind === "set" && method.params[0].type === "RestElement") {
      this.raise(start, "setter function argument must not be a rest parameter");
    }
  };

  _proto.parseObjectMethod = function parseObjectMethod(prop, isGenerator, isAsync, isPattern, containsEsc) {
    if (isAsync || isGenerator || this.match(types.parenL)) {
      if (isPattern) this.unexpected();
      prop.kind = "method";
      prop.method = true;
      return this.parseMethod(prop, isGenerator, isAsync, false, "ObjectMethod");
    }

    if (!containsEsc && this.isGetterOrSetterMethod(prop, isPattern)) {
      if (isGenerator || isAsync) this.unexpected();
      prop.kind = prop.key.name;
      this.parsePropertyName(prop);
      this.parseMethod(prop, false, false, false, "ObjectMethod");
      this.checkGetterSetterParams(prop);
      return prop;
    }
  };

  _proto.parseObjectProperty = function parseObjectProperty(prop, startPos, startLoc, isPattern, refShorthandDefaultPos) {
    prop.shorthand = false;

    if (this.eat(types.colon)) {
      prop.value = isPattern ? this.parseMaybeDefault(this.state.start, this.state.startLoc) : this.parseMaybeAssign(false, refShorthandDefaultPos);
      return this.finishNode(prop, "ObjectProperty");
    }

    if (!prop.computed && prop.key.type === "Identifier") {
      this.checkReservedWord(prop.key.name, prop.key.start, true, true);

      if (isPattern) {
        prop.value = this.parseMaybeDefault(startPos, startLoc, prop.key.__clone());
      } else if (this.match(types.eq) && refShorthandDefaultPos) {
        if (!refShorthandDefaultPos.start) {
          refShorthandDefaultPos.start = this.state.start;
        }

        prop.value = this.parseMaybeDefault(startPos, startLoc, prop.key.__clone());
      } else {
        prop.value = prop.key.__clone();
      }

      prop.shorthand = true;
      return this.finishNode(prop, "ObjectProperty");
    }
  };

  _proto.parseObjPropValue = function parseObjPropValue(prop, startPos, startLoc, isGenerator, isAsync, isPattern, refShorthandDefaultPos, containsEsc) {
    var node = this.parseObjectMethod(prop, isGenerator, isAsync, isPattern, containsEsc) || this.parseObjectProperty(prop, startPos, startLoc, isPattern, refShorthandDefaultPos);
    if (!node) this.unexpected();
    return node;
  };

  _proto.parsePropertyName = function parsePropertyName(prop) {
    if (this.eat(types.bracketL)) {
      prop.computed = true;
      prop.key = this.parseMaybeAssign();
      this.expect(types.bracketR);
    } else {
      var oldInPropertyName = this.state.inPropertyName;
      this.state.inPropertyName = true;
      prop.key = this.match(types.num) || this.match(types.string) ? this.parseExprAtom() : this.parseMaybePrivateName();

      if (prop.key.type !== "PrivateName") {
        prop.computed = false;
      }

      this.state.inPropertyName = oldInPropertyName;
    }

    return prop.key;
  };

  _proto.initFunction = function initFunction(node, isAsync) {
    node.id = null;
    node.generator = false;
    node.async = !!isAsync;
  };

  _proto.parseMethod = function parseMethod(node, isGenerator, isAsync, isConstructor, type) {
    var oldInFunc = this.state.inFunction;
    var oldInMethod = this.state.inMethod;
    var oldInGenerator = this.state.inGenerator;
    this.state.inFunction = true;
    this.state.inMethod = node.kind || true;
    this.state.inGenerator = isGenerator;
    this.initFunction(node, isAsync);
    node.generator = !!isGenerator;
    var allowModifiers = isConstructor;
    this.parseFunctionParams(node, allowModifiers);
    this.parseFunctionBodyAndFinish(node, type);
    this.state.inFunction = oldInFunc;
    this.state.inMethod = oldInMethod;
    this.state.inGenerator = oldInGenerator;
    return node;
  };

  _proto.parseArrowExpression = function parseArrowExpression(node, params, isAsync) {
    if (this.state.yieldInPossibleArrowParameters) {
      this.raise(this.state.yieldInPossibleArrowParameters.start, "yield is not allowed in the parameters of an arrow function" + " inside a generator");
    }

    var oldInFunc = this.state.inFunction;
    this.state.inFunction = true;
    this.initFunction(node, isAsync);
    if (params) this.setArrowFunctionParameters(node, params);
    var oldInGenerator = this.state.inGenerator;
    var oldMaybeInArrowParameters = this.state.maybeInArrowParameters;
    this.state.inGenerator = false;
    this.state.maybeInArrowParameters = false;
    this.parseFunctionBody(node, true);
    this.state.inGenerator = oldInGenerator;
    this.state.inFunction = oldInFunc;
    this.state.maybeInArrowParameters = oldMaybeInArrowParameters;
    return this.finishNode(node, "ArrowFunctionExpression");
  };

  _proto.setArrowFunctionParameters = function setArrowFunctionParameters(node, params) {
    node.params = this.toAssignableList(params, true, "arrow function parameters");
  };

  _proto.isStrictBody = function isStrictBody(node) {
    var isBlockStatement = node.body.type === "BlockStatement";

    if (isBlockStatement && node.body.directives.length) {
      for (var _i4 = 0, _node$body$directives2 = node.body.directives; _i4 < _node$body$directives2.length; _i4++) {
        var directive = _node$body$directives2[_i4];

        if (directive.value.value === "use strict") {
          return true;
        }
      }
    }

    return false;
  };

  _proto.parseFunctionBodyAndFinish = function parseFunctionBodyAndFinish(node, type, allowExpressionBody) {
    this.parseFunctionBody(node, allowExpressionBody);
    this.finishNode(node, type);
  };

  _proto.parseFunctionBody = function parseFunctionBody(node, allowExpression) {
    var isExpression = allowExpression && !this.match(types.braceL);
    var oldInParameters = this.state.inParameters;
    var oldInAsync = this.state.inAsync;
    this.state.inParameters = false;
    this.state.inAsync = node.async;

    if (isExpression) {
      node.body = this.parseMaybeAssign();
    } else {
      var oldInGen = this.state.inGenerator;
      var oldInFunc = this.state.inFunction;
      var oldLabels = this.state.labels;
      this.state.inGenerator = node.generator;
      this.state.inFunction = true;
      this.state.labels = [];
      node.body = this.parseBlock(true);
      this.state.inFunction = oldInFunc;
      this.state.inGenerator = oldInGen;
      this.state.labels = oldLabels;
    }

    this.state.inAsync = oldInAsync;
    this.checkFunctionNameAndParams(node, allowExpression);
    this.state.inParameters = oldInParameters;
  };

  _proto.checkFunctionNameAndParams = function checkFunctionNameAndParams(node, isArrowFunction) {
    var isStrict = this.isStrictBody(node);
    var checkLVal = this.state.strict || isStrict || isArrowFunction;
    var oldStrict = this.state.strict;
    if (isStrict) this.state.strict = isStrict;

    if (checkLVal) {
      var nameHash = Object.create(null);

      if (node.id) {
        this.checkLVal(node.id, true, undefined, "function name");
      }

      for (var _i6 = 0, _node$params2 = node.params; _i6 < _node$params2.length; _i6++) {
        var param = _node$params2[_i6];

        if (isStrict && param.type !== "Identifier") {
          this.raise(param.start, "Non-simple parameter in strict mode");
        }

        this.checkLVal(param, true, nameHash, "function parameter list");
      }
    }

    this.state.strict = oldStrict;
  };

  _proto.parseExprList = function parseExprList(close, allowEmpty, refShorthandDefaultPos) {
    var elts = [];
    var first = true;

    while (!this.eat(close)) {
      if (first) {
        first = false;
      } else {
        this.expect(types.comma);
        if (this.eat(close)) break;
      }

      elts.push(this.parseExprListItem(allowEmpty, refShorthandDefaultPos));
    }

    return elts;
  };

  _proto.parseExprListItem = function parseExprListItem(allowEmpty, refShorthandDefaultPos, refNeedsArrowPos, refTrailingCommaPos) {
    var elt;

    if (allowEmpty && this.match(types.comma)) {
      elt = null;
    } else if (this.match(types.ellipsis)) {
      var spreadNodeStartPos = this.state.start;
      var spreadNodeStartLoc = this.state.startLoc;
      elt = this.parseParenItem(this.parseSpread(refShorthandDefaultPos, refNeedsArrowPos), spreadNodeStartPos, spreadNodeStartLoc);

      if (refTrailingCommaPos && this.match(types.comma)) {
        refTrailingCommaPos.start = this.state.start;
      }
    } else {
      elt = this.parseMaybeAssign(false, refShorthandDefaultPos, this.parseParenItem, refNeedsArrowPos);
    }

    return elt;
  };

  _proto.parseIdentifier = function parseIdentifier(liberal) {
    var node = this.startNode();
    var name = this.parseIdentifierName(node.start, liberal);
    node.name = name;
    node.loc.identifierName = name;
    return this.finishNode(node, "Identifier");
  };

  _proto.parseIdentifierName = function parseIdentifierName(pos, liberal) {
    if (!liberal) {
      this.checkReservedWord(this.state.value, this.state.start, !!this.state.type.keyword, false);
    }

    var name;

    if (this.match(types.name)) {
      name = this.state.value;
    } else if (this.state.type.keyword) {
      name = this.state.type.keyword;
    } else {
      throw this.unexpected();
    }

    if (!liberal && name === "await" && this.state.inAsync) {
      this.raise(pos, "invalid use of await inside of an async function");
    }

    this.next();
    return name;
  };

  _proto.checkReservedWord = function checkReservedWord(word, startLoc, checkKeywords, isBinding) {
    if (this.state.strict && (reservedWords.strict(word) || isBinding && reservedWords.strictBind(word))) {
      this.raise(startLoc, word + " is a reserved word in strict mode");
    }

    if (this.state.inGenerator && word === "yield") {
      this.raise(startLoc, "yield is a reserved word inside generator functions");
    }

    if (this.state.inClassProperty && word === "arguments") {
      this.raise(startLoc, "'arguments' is not allowed in class field initializer");
    }

    if (this.isReservedWord(word) || checkKeywords && this.isKeyword(word)) {
      this.raise(startLoc, word + " is a reserved word");
    }
  };

  _proto.parseAwait = function parseAwait(node) {
    if (!this.state.inAsync && (this.state.inFunction || !this.options.allowAwaitOutsideFunction)) {
      this.unexpected();
    }

    if (this.match(types.star)) {
      this.raise(node.start, "await* has been removed from the async functions proposal. Use Promise.all() instead.");
    }

    node.argument = this.parseMaybeUnary();
    return this.finishNode(node, "AwaitExpression");
  };

  _proto.parseYield = function parseYield() {
    var node = this.startNode();

    if (this.state.inParameters) {
      this.raise(node.start, "yield is not allowed in generator parameters");
    }

    if (this.state.maybeInArrowParameters && !this.state.yieldInPossibleArrowParameters) {
      this.state.yieldInPossibleArrowParameters = node;
    }

    this.next();

    if (this.match(types.semi) || this.canInsertSemicolon() || !this.match(types.star) && !this.state.type.startsExpr) {
      node.delegate = false;
      node.argument = null;
    } else {
      node.delegate = this.eat(types.star);
      node.argument = this.parseMaybeAssign();
    }

    return this.finishNode(node, "YieldExpression");
  };

  _inheritsLoose(ExpressionParser, _LValParser);

  return ExpressionParser;
}(LValParser);

var empty = [];
var loopLabel = {
  kind: "loop"
};
var switchLabel = {
  kind: "switch"
};

var StatementParser = function (_ExpressionParser) {
  function StatementParser() {
    return _ExpressionParser.apply(this, arguments) || this;
  }

  var _proto = StatementParser.prototype;

  _proto.parseTopLevel = function parseTopLevel(file, program) {
    program.sourceType = this.options.sourceType;
    this.parseBlockBody(program, true, true, types.eof);
    file.program = this.finishNode(program, "Program");
    file.comments = this.state.comments;
    if (this.options.tokens) file.tokens = this.state.tokens;
    return this.finishNode(file, "File");
  };

  _proto.stmtToDirective = function stmtToDirective(stmt) {
    var expr = stmt.expression;
    var directiveLiteral = this.startNodeAt(expr.start, expr.loc.start);
    var directive = this.startNodeAt(stmt.start, stmt.loc.start);
    var raw = this.input.slice(expr.start, expr.end);
    var val = directiveLiteral.value = raw.slice(1, -1);
    this.addExtra(directiveLiteral, "raw", raw);
    this.addExtra(directiveLiteral, "rawValue", val);
    directive.value = this.finishNodeAt(directiveLiteral, "DirectiveLiteral", expr.end, expr.loc.end);
    return this.finishNodeAt(directive, "Directive", stmt.end, stmt.loc.end);
  };

  _proto.parseStatement = function parseStatement(declaration, topLevel) {
    if (this.match(types.at)) {
      this.parseDecorators(true);
    }

    return this.parseStatementContent(declaration, topLevel);
  };

  _proto.parseStatementContent = function parseStatementContent(declaration, topLevel) {
    var starttype = this.state.type;
    var node = this.startNode();

    switch (starttype) {
      case types._break:
      case types._continue:
        return this.parseBreakContinueStatement(node, starttype.keyword);

      case types._debugger:
        return this.parseDebuggerStatement(node);

      case types._do:
        return this.parseDoStatement(node);

      case types._for:
        return this.parseForStatement(node);

      case types._function:
        if (this.lookahead().type === types.dot) break;
        if (!declaration) this.unexpected();
        return this.parseFunctionStatement(node);

      case types._class:
        if (!declaration) this.unexpected();
        return this.parseClass(node, true);

      case types._if:
        return this.parseIfStatement(node);

      case types._return:
        return this.parseReturnStatement(node);

      case types._switch:
        return this.parseSwitchStatement(node);

      case types._throw:
        return this.parseThrowStatement(node);

      case types._try:
        return this.parseTryStatement(node);

      case types._let:
      case types._const:
        if (!declaration) this.unexpected();

      case types._var:
        return this.parseVarStatement(node, starttype);

      case types._while:
        return this.parseWhileStatement(node);

      case types._with:
        return this.parseWithStatement(node);

      case types.braceL:
        return this.parseBlock();

      case types.semi:
        return this.parseEmptyStatement(node);

      case types._export:
      case types._import:
        {
          var nextToken = this.lookahead();

          if (nextToken.type === types.parenL || nextToken.type === types.dot) {
            break;
          }

          if (!this.options.allowImportExportEverywhere && !topLevel) {
            this.raise(this.state.start, "'import' and 'export' may only appear at the top level");
          }

          this.next();
          var result;

          if (starttype == types._import) {
            result = this.parseImport(node);

            if (result.type === "ImportDeclaration" && (!result.importKind || result.importKind === "value")) {
              this.sawUnambiguousESM = true;
            }
          } else {
            result = this.parseExport(node);

            if (result.type === "ExportNamedDeclaration" && (!result.exportKind || result.exportKind === "value") || result.type === "ExportAllDeclaration" && (!result.exportKind || result.exportKind === "value") || result.type === "ExportDefaultDeclaration") {
              this.sawUnambiguousESM = true;
            }
          }

          this.assertModuleNodeAllowed(node);
          return result;
        }

      case types.name:
        if (this.isContextual("async")) {
          var state = this.state.clone();
          this.next();

          if (this.match(types._function) && !this.canInsertSemicolon()) {
            this.expect(types._function);
            return this.parseFunction(node, true, false, true);
          } else {
            this.state = state;
          }
        }

    }

    var maybeName = this.state.value;
    var expr = this.parseExpression();

    if (starttype === types.name && expr.type === "Identifier" && this.eat(types.colon)) {
      return this.parseLabeledStatement(node, maybeName, expr);
    } else {
      return this.parseExpressionStatement(node, expr);
    }
  };

  _proto.assertModuleNodeAllowed = function assertModuleNodeAllowed(node) {
    if (!this.options.allowImportExportEverywhere && !this.inModule) {
      this.raise(node.start, "'import' and 'export' may appear only with 'sourceType: \"module\"'", {
        code: "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED"
      });
    }
  };

  _proto.takeDecorators = function takeDecorators(node) {
    var decorators = this.state.decoratorStack[this.state.decoratorStack.length - 1];

    if (decorators.length) {
      node.decorators = decorators;
      this.resetStartLocationFromNode(node, decorators[0]);
      this.state.decoratorStack[this.state.decoratorStack.length - 1] = [];
    }
  };

  _proto.canHaveLeadingDecorator = function canHaveLeadingDecorator() {
    return this.match(types._class);
  };

  _proto.parseDecorators = function parseDecorators(allowExport) {
    if (this.hasPlugin("decorators")) {
      allowExport = false;
    }

    var currentContextDecorators = this.state.decoratorStack[this.state.decoratorStack.length - 1];

    while (this.match(types.at)) {
      var decorator = this.parseDecorator();
      currentContextDecorators.push(decorator);
    }

    if (this.match(types._export)) {
      if (allowExport) {
        return;
      } else {
        this.raise(this.state.start, "Using the export keyword between a decorator and a class is not allowed. " + "Please use `export @dec class` instead");
      }
    }

    if (!this.canHaveLeadingDecorator()) {
      this.raise(this.state.start, "Leading decorators must be attached to a class declaration");
    }
  };

  _proto.parseDecorator = function parseDecorator() {
    this.expectOnePlugin(["decorators-legacy", "decorators"]);
    var node = this.startNode();
    this.next();

    if (this.hasPlugin("decorators")) {
      this.state.decoratorStack.push([]);

      if (this.eat(types.parenL)) {
        node.callee = this.parseExpression();
        this.expect(types.parenR);
      } else {
        var startPos = this.state.start;
        var startLoc = this.state.startLoc;
        var expr = this.parseIdentifier(false);

        while (this.eat(types.dot)) {
          var _node = this.startNodeAt(startPos, startLoc);

          _node.object = expr;
          _node.property = this.parseIdentifier(true);
          _node.computed = false;
          expr = this.finishNode(_node, "MemberExpression");
        }

        node.callee = expr;
      }

      if (this.eat(types.parenL)) {
        node.arguments = this.parseCallExpressionArguments(types.parenR, false);
        this.toReferencedList(node.arguments);
      }

      this.state.decoratorStack.pop();
    } else {
      node.callee = this.parseMaybeAssign();
    }

    return this.finishNode(node, "Decorator");
  };

  _proto.parseBreakContinueStatement = function parseBreakContinueStatement(node, keyword) {
    var isBreak = keyword === "break";
    this.next();

    if (this.isLineTerminator()) {
      node.label = null;
    } else if (!this.match(types.name)) {
      this.unexpected();
    } else {
      node.label = this.parseIdentifier();
      this.semicolon();
    }

    var i;

    for (i = 0; i < this.state.labels.length; ++i) {
      var lab = this.state.labels[i];

      if (node.label == null || lab.name === node.label.name) {
        if (lab.kind != null && (isBreak || lab.kind === "loop")) break;
        if (node.label && isBreak) break;
      }
    }

    if (i === this.state.labels.length) {
      this.raise(node.start, "Unsyntactic " + keyword);
    }

    return this.finishNode(node, isBreak ? "BreakStatement" : "ContinueStatement");
  };

  _proto.parseDebuggerStatement = function parseDebuggerStatement(node) {
    this.next();
    this.semicolon();
    return this.finishNode(node, "DebuggerStatement");
  };

  _proto.parseDoStatement = function parseDoStatement(node) {
    this.next();
    this.state.labels.push(loopLabel);
    node.body = this.parseStatement(false);
    this.state.labels.pop();
    this.expect(types._while);
    node.test = this.parseParenExpression();
    this.eat(types.semi);
    return this.finishNode(node, "DoWhileStatement");
  };

  _proto.parseForStatement = function parseForStatement(node) {
    this.next();
    this.state.labels.push(loopLabel);
    var forAwait = false;

    if (this.state.inAsync && this.isContextual("await")) {
      this.expectPlugin("asyncGenerators");
      forAwait = true;
      this.next();
    }

    this.expect(types.parenL);

    if (this.match(types.semi)) {
      if (forAwait) {
        this.unexpected();
      }

      return this.parseFor(node, null);
    }

    if (this.match(types._var) || this.match(types._let) || this.match(types._const)) {
      var _init = this.startNode();

      var varKind = this.state.type;
      this.next();
      this.parseVar(_init, true, varKind);
      this.finishNode(_init, "VariableDeclaration");

      if (this.match(types._in) || this.isContextual("of")) {
        if (_init.declarations.length === 1) {
          var declaration = _init.declarations[0];
          var isForInInitializer = varKind === types._var && declaration.init && declaration.id.type != "ObjectPattern" && declaration.id.type != "ArrayPattern" && !this.isContextual("of");

          if (this.state.strict && isForInInitializer) {
            this.raise(this.state.start, "for-in initializer in strict mode");
          } else if (isForInInitializer || !declaration.init) {
            return this.parseForIn(node, _init, forAwait);
          }
        }
      }

      if (forAwait) {
        this.unexpected();
      }

      return this.parseFor(node, _init);
    }

    var refShorthandDefaultPos = {
      start: 0
    };
    var init = this.parseExpression(true, refShorthandDefaultPos);

    if (this.match(types._in) || this.isContextual("of")) {
      var description = this.isContextual("of") ? "for-of statement" : "for-in statement";
      this.toAssignable(init, undefined, description);
      this.checkLVal(init, undefined, undefined, description);
      return this.parseForIn(node, init, forAwait);
    } else if (refShorthandDefaultPos.start) {
      this.unexpected(refShorthandDefaultPos.start);
    }

    if (forAwait) {
      this.unexpected();
    }

    return this.parseFor(node, init);
  };

  _proto.parseFunctionStatement = function parseFunctionStatement(node) {
    this.next();
    return this.parseFunction(node, true);
  };

  _proto.parseIfStatement = function parseIfStatement(node) {
    this.next();
    node.test = this.parseParenExpression();
    node.consequent = this.parseStatement(false);
    node.alternate = this.eat(types._else) ? this.parseStatement(false) : null;
    return this.finishNode(node, "IfStatement");
  };

  _proto.parseReturnStatement = function parseReturnStatement(node) {
    if (!this.state.inFunction && !this.options.allowReturnOutsideFunction) {
      this.raise(this.state.start, "'return' outside of function");
    }

    this.next();

    if (this.isLineTerminator()) {
      node.argument = null;
    } else {
      node.argument = this.parseExpression();
      this.semicolon();
    }

    return this.finishNode(node, "ReturnStatement");
  };

  _proto.parseSwitchStatement = function parseSwitchStatement(node) {
    this.next();
    node.discriminant = this.parseParenExpression();
    var cases = node.cases = [];
    this.expect(types.braceL);
    this.state.labels.push(switchLabel);
    var cur;

    for (var sawDefault; !this.match(types.braceR);) {
      if (this.match(types._case) || this.match(types._default)) {
        var isCase = this.match(types._case);
        if (cur) this.finishNode(cur, "SwitchCase");
        cases.push(cur = this.startNode());
        cur.consequent = [];
        this.next();

        if (isCase) {
          cur.test = this.parseExpression();
        } else {
          if (sawDefault) {
            this.raise(this.state.lastTokStart, "Multiple default clauses");
          }

          sawDefault = true;
          cur.test = null;
        }

        this.expect(types.colon);
      } else {
        if (cur) {
          cur.consequent.push(this.parseStatement(true));
        } else {
          this.unexpected();
        }
      }
    }

    if (cur) this.finishNode(cur, "SwitchCase");
    this.next();
    this.state.labels.pop();
    return this.finishNode(node, "SwitchStatement");
  };

  _proto.parseThrowStatement = function parseThrowStatement(node) {
    this.next();

    if (lineBreak.test(this.input.slice(this.state.lastTokEnd, this.state.start))) {
      this.raise(this.state.lastTokEnd, "Illegal newline after throw");
    }

    node.argument = this.parseExpression();
    this.semicolon();
    return this.finishNode(node, "ThrowStatement");
  };

  _proto.parseTryStatement = function parseTryStatement(node) {
    this.next();
    node.block = this.parseBlock();
    node.handler = null;

    if (this.match(types._catch)) {
      var clause = this.startNode();
      this.next();

      if (this.match(types.parenL)) {
        this.expect(types.parenL);
        clause.param = this.parseBindingAtom();
        var clashes = Object.create(null);
        this.checkLVal(clause.param, true, clashes, "catch clause");
        this.expect(types.parenR);
      } else {
        this.expectPlugin("optionalCatchBinding");
        clause.param = null;
      }

      clause.body = this.parseBlock();
      node.handler = this.finishNode(clause, "CatchClause");
    }

    node.guardedHandlers = empty;
    node.finalizer = this.eat(types._finally) ? this.parseBlock() : null;

    if (!node.handler && !node.finalizer) {
      this.raise(node.start, "Missing catch or finally clause");
    }

    return this.finishNode(node, "TryStatement");
  };

  _proto.parseVarStatement = function parseVarStatement(node, kind) {
    this.next();
    this.parseVar(node, false, kind);
    this.semicolon();
    return this.finishNode(node, "VariableDeclaration");
  };

  _proto.parseWhileStatement = function parseWhileStatement(node) {
    this.next();
    node.test = this.parseParenExpression();
    this.state.labels.push(loopLabel);
    node.body = this.parseStatement(false);
    this.state.labels.pop();
    return this.finishNode(node, "WhileStatement");
  };

  _proto.parseWithStatement = function parseWithStatement(node) {
    if (this.state.strict) {
      this.raise(this.state.start, "'with' in strict mode");
    }

    this.next();
    node.object = this.parseParenExpression();
    node.body = this.parseStatement(false);
    return this.finishNode(node, "WithStatement");
  };

  _proto.parseEmptyStatement = function parseEmptyStatement(node) {
    this.next();
    return this.finishNode(node, "EmptyStatement");
  };

  _proto.parseLabeledStatement = function parseLabeledStatement(node, maybeName, expr) {
    for (var _i2 = 0, _this$state$labels2 = this.state.labels; _i2 < _this$state$labels2.length; _i2++) {
      var label = _this$state$labels2[_i2];

      if (label.name === maybeName) {
        this.raise(expr.start, "Label '" + maybeName + "' is already declared");
      }
    }

    var kind = this.state.type.isLoop ? "loop" : this.match(types._switch) ? "switch" : null;

    for (var i = this.state.labels.length - 1; i >= 0; i--) {
      var _label = this.state.labels[i];

      if (_label.statementStart === node.start) {
        _label.statementStart = this.state.start;
        _label.kind = kind;
      } else {
        break;
      }
    }

    this.state.labels.push({
      name: maybeName,
      kind: kind,
      statementStart: this.state.start
    });
    node.body = this.parseStatement(true);

    if (node.body.type == "ClassDeclaration" || node.body.type == "VariableDeclaration" && node.body.kind !== "var" || node.body.type == "FunctionDeclaration" && (this.state.strict || node.body.generator || node.body.async)) {
      this.raise(node.body.start, "Invalid labeled declaration");
    }

    this.state.labels.pop();
    node.label = expr;
    return this.finishNode(node, "LabeledStatement");
  };

  _proto.parseExpressionStatement = function parseExpressionStatement(node, expr) {
    node.expression = expr;
    this.semicolon();
    return this.finishNode(node, "ExpressionStatement");
  };

  _proto.parseBlock = function parseBlock(allowDirectives) {
    var node = this.startNode();
    this.expect(types.braceL);
    this.parseBlockBody(node, allowDirectives, false, types.braceR);
    return this.finishNode(node, "BlockStatement");
  };

  _proto.isValidDirective = function isValidDirective(stmt) {
    return stmt.type === "ExpressionStatement" && stmt.expression.type === "StringLiteral" && !stmt.expression.extra.parenthesized;
  };

  _proto.parseBlockBody = function parseBlockBody(node, allowDirectives, topLevel, end) {
    var body = node.body = [];
    var directives = node.directives = [];
    this.parseBlockOrModuleBlockBody(body, allowDirectives ? directives : undefined, topLevel, end);
  };

  _proto.parseBlockOrModuleBlockBody = function parseBlockOrModuleBlockBody(body, directives, topLevel, end) {
    var parsedNonDirective = false;
    var oldStrict;
    var octalPosition;

    while (!this.eat(end)) {
      if (!parsedNonDirective && this.state.containsOctal && !octalPosition) {
        octalPosition = this.state.octalPosition;
      }

      var stmt = this.parseStatement(true, topLevel);

      if (directives && !parsedNonDirective && this.isValidDirective(stmt)) {
        var directive = this.stmtToDirective(stmt);
        directives.push(directive);

        if (oldStrict === undefined && directive.value.value === "use strict") {
          oldStrict = this.state.strict;
          this.setStrict(true);

          if (octalPosition) {
            this.raise(octalPosition, "Octal literal in strict mode");
          }
        }

        continue;
      }

      parsedNonDirective = true;
      body.push(stmt);
    }

    if (oldStrict === false) {
      this.setStrict(false);
    }
  };

  _proto.parseFor = function parseFor(node, init) {
    node.init = init;
    this.expect(types.semi);
    node.test = this.match(types.semi) ? null : this.parseExpression();
    this.expect(types.semi);
    node.update = this.match(types.parenR) ? null : this.parseExpression();
    this.expect(types.parenR);
    node.body = this.parseStatement(false);
    this.state.labels.pop();
    return this.finishNode(node, "ForStatement");
  };

  _proto.parseForIn = function parseForIn(node, init, forAwait) {
    var type = this.match(types._in) ? "ForInStatement" : "ForOfStatement";

    if (forAwait) {
      this.eatContextual("of");
    } else {
      this.next();
    }

    if (type === "ForOfStatement") {
      node.await = !!forAwait;
    }

    node.left = init;
    node.right = this.parseExpression();
    this.expect(types.parenR);
    node.body = this.parseStatement(false);
    this.state.labels.pop();
    return this.finishNode(node, type);
  };

  _proto.parseVar = function parseVar(node, isFor, kind) {
    var declarations = node.declarations = [];
    node.kind = kind.keyword;

    for (;;) {
      var decl = this.startNode();
      this.parseVarHead(decl);

      if (this.eat(types.eq)) {
        decl.init = this.parseMaybeAssign(isFor);
      } else {
        if (kind === types._const && !(this.match(types._in) || this.isContextual("of"))) {
          if (!this.hasPlugin("typescript")) {
            this.unexpected();
          }
        } else if (decl.id.type !== "Identifier" && !(isFor && (this.match(types._in) || this.isContextual("of")))) {
          this.raise(this.state.lastTokEnd, "Complex binding patterns require an initialization value");
        }

        decl.init = null;
      }

      declarations.push(this.finishNode(decl, "VariableDeclarator"));
      if (!this.eat(types.comma)) break;
    }

    return node;
  };

  _proto.parseVarHead = function parseVarHead(decl) {
    decl.id = this.parseBindingAtom();
    this.checkLVal(decl.id, true, undefined, "variable declaration");
  };

  _proto.parseFunction = function parseFunction(node, isStatement, allowExpressionBody, isAsync, optionalId) {
    var oldInFunc = this.state.inFunction;
    var oldInMethod = this.state.inMethod;
    var oldInGenerator = this.state.inGenerator;
    var oldInClassProperty = this.state.inClassProperty;
    this.state.inFunction = true;
    this.state.inMethod = false;
    this.state.inClassProperty = false;
    this.initFunction(node, isAsync);

    if (this.match(types.star)) {
      if (node.async) {
        this.expectPlugin("asyncGenerators");
      }

      node.generator = true;
      this.next();
    }

    if (isStatement && !optionalId && !this.match(types.name) && !this.match(types._yield)) {
      this.unexpected();
    }

    if (!isStatement) this.state.inGenerator = node.generator;

    if (this.match(types.name) || this.match(types._yield)) {
      node.id = this.parseBindingIdentifier();
    }

    if (isStatement) this.state.inGenerator = node.generator;
    this.parseFunctionParams(node);
    this.parseFunctionBodyAndFinish(node, isStatement ? "FunctionDeclaration" : "FunctionExpression", allowExpressionBody);
    this.state.inFunction = oldInFunc;
    this.state.inMethod = oldInMethod;
    this.state.inGenerator = oldInGenerator;
    this.state.inClassProperty = oldInClassProperty;
    return node;
  };

  _proto.parseFunctionParams = function parseFunctionParams(node, allowModifiers) {
    var oldInParameters = this.state.inParameters;
    this.state.inParameters = true;
    this.expect(types.parenL);
    node.params = this.parseBindingList(types.parenR, false, allowModifiers);
    this.state.inParameters = oldInParameters;
  };

  _proto.parseClass = function parseClass(node, isStatement, optionalId) {
    this.next();
    this.takeDecorators(node);
    this.parseClassId(node, isStatement, optionalId);
    this.parseClassSuper(node);
    this.parseClassBody(node);
    return this.finishNode(node, isStatement ? "ClassDeclaration" : "ClassExpression");
  };

  _proto.isClassProperty = function isClassProperty() {
    return this.match(types.eq) || this.match(types.semi) || this.match(types.braceR);
  };

  _proto.isClassMethod = function isClassMethod() {
    return this.match(types.parenL);
  };

  _proto.isNonstaticConstructor = function isNonstaticConstructor(method) {
    return !method.computed && !method.static && (method.key.name === "constructor" || method.key.value === "constructor");
  };

  _proto.parseClassBody = function parseClassBody(node) {
    var oldStrict = this.state.strict;
    this.state.strict = true;
    this.state.classLevel++;
    var state = {
      hadConstructor: false
    };
    var decorators = [];
    var classBody = this.startNode();
    classBody.body = [];
    this.expect(types.braceL);

    while (!this.eat(types.braceR)) {
      if (this.eat(types.semi)) {
        if (decorators.length > 0) {
          this.raise(this.state.lastTokEnd, "Decorators must not be followed by a semicolon");
        }

        continue;
      }

      if (this.match(types.at)) {
        decorators.push(this.parseDecorator());
        continue;
      }

      var member = this.startNode();

      if (decorators.length) {
        member.decorators = decorators;
        this.resetStartLocationFromNode(member, decorators[0]);
        decorators = [];
      }

      this.parseClassMember(classBody, member, state);

      if (member.kind === "constructor" && member.decorators && member.decorators.length > 0) {
        this.raise(member.start, "Decorators can't be used with a constructor. Did you mean '@dec class { ... }'?");
      }
    }

    if (decorators.length) {
      this.raise(this.state.start, "You have trailing decorators with no method");
    }

    node.body = this.finishNode(classBody, "ClassBody");
    this.state.classLevel--;
    this.state.strict = oldStrict;
  };

  _proto.parseClassMember = function parseClassMember(classBody, member, state) {
    var isStatic = false;
    var containsEsc = this.state.containsEsc;

    if (this.match(types.name) && this.state.value === "static") {
      var key = this.parseIdentifier(true);

      if (this.isClassMethod()) {
        var method = member;
        method.kind = "method";
        method.computed = false;
        method.key = key;
        method.static = false;
        this.pushClassMethod(classBody, method, false, false, false);
        return;
      } else if (this.isClassProperty()) {
        var prop = member;
        prop.computed = false;
        prop.key = key;
        prop.static = false;
        classBody.body.push(this.parseClassProperty(prop));
        return;
      } else if (containsEsc) {
        throw this.unexpected();
      }

      isStatic = true;
    }

    this.parseClassMemberWithIsStatic(classBody, member, state, isStatic);
  };

  _proto.parseClassMemberWithIsStatic = function parseClassMemberWithIsStatic(classBody, member, state, isStatic) {
    var publicMethod = member;
    var privateMethod = member;
    var publicProp = member;
    var privateProp = member;
    var method = publicMethod;
    var publicMember = publicMethod;
    member.static = isStatic;

    if (this.eat(types.star)) {
      method.kind = "method";
      this.parseClassPropertyName(method);

      if (method.key.type === "PrivateName") {
        this.pushClassPrivateMethod(classBody, privateMethod, true, false);
        return;
      }

      if (this.isNonstaticConstructor(publicMethod)) {
        this.raise(publicMethod.key.start, "Constructor can't be a generator");
      }

      this.pushClassMethod(classBody, publicMethod, true, false, false);
      return;
    }

    var key = this.parseClassPropertyName(member);
    var isPrivate = key.type === "PrivateName";
    var isSimple = key.type === "Identifier";
    this.parsePostMemberNameModifiers(publicMember);

    if (this.isClassMethod()) {
      method.kind = "method";

      if (isPrivate) {
        this.pushClassPrivateMethod(classBody, privateMethod, false, false);
        return;
      }

      var isConstructor = this.isNonstaticConstructor(publicMethod);

      if (isConstructor) {
        publicMethod.kind = "constructor";

        if (publicMethod.decorators) {
          this.raise(publicMethod.start, "You can't attach decorators to a class constructor");
        }

        if (state.hadConstructor && !this.hasPlugin("typescript")) {
          this.raise(key.start, "Duplicate constructor in the same class");
        }

        state.hadConstructor = true;
      }

      this.pushClassMethod(classBody, publicMethod, false, false, isConstructor);
    } else if (this.isClassProperty()) {
      if (isPrivate) {
        this.pushClassPrivateProperty(classBody, privateProp);
      } else {
        this.pushClassProperty(classBody, publicProp);
      }
    } else if (isSimple && key.name === "async" && !this.isLineTerminator()) {
      var isGenerator = this.match(types.star);

      if (isGenerator) {
        this.expectPlugin("asyncGenerators");
        this.next();
      }

      method.kind = "method";
      this.parseClassPropertyName(method);

      if (method.key.type === "PrivateName") {
        this.pushClassPrivateMethod(classBody, privateMethod, isGenerator, true);
      } else {
        if (this.isNonstaticConstructor(publicMethod)) {
          this.raise(publicMethod.key.start, "Constructor can't be an async function");
        }

        this.pushClassMethod(classBody, publicMethod, isGenerator, true, false);
      }
    } else if (isSimple && (key.name === "get" || key.name === "set") && !(this.isLineTerminator() && this.match(types.star))) {
      method.kind = key.name;
      this.parseClassPropertyName(publicMethod);

      if (method.key.type === "PrivateName") {
        this.pushClassPrivateMethod(classBody, privateMethod, false, false);
      } else {
        if (this.isNonstaticConstructor(publicMethod)) {
          this.raise(publicMethod.key.start, "Constructor can't have get/set modifier");
        }

        this.pushClassMethod(classBody, publicMethod, false, false, false);
      }

      this.checkGetterSetterParams(publicMethod);
    } else if (this.isLineTerminator()) {
      if (isPrivate) {
        this.pushClassPrivateProperty(classBody, privateProp);
      } else {
        this.pushClassProperty(classBody, publicProp);
      }
    } else {
      this.unexpected();
    }
  };

  _proto.parseClassPropertyName = function parseClassPropertyName(member) {
    var key = this.parsePropertyName(member);

    if (!member.computed && member.static && (key.name === "prototype" || key.value === "prototype")) {
      this.raise(key.start, "Classes may not have static property named prototype");
    }

    if (key.type === "PrivateName" && key.id.name === "constructor") {
      this.raise(key.start, "Classes may not have a private field named '#constructor'");
    }

    return key;
  };

  _proto.pushClassProperty = function pushClassProperty(classBody, prop) {
    if (this.isNonstaticConstructor(prop)) {
      this.raise(prop.key.start, "Classes may not have a non-static field named 'constructor'");
    }

    classBody.body.push(this.parseClassProperty(prop));
  };

  _proto.pushClassPrivateProperty = function pushClassPrivateProperty(classBody, prop) {
    this.expectPlugin("classPrivateProperties", prop.key.start);
    classBody.body.push(this.parseClassPrivateProperty(prop));
  };

  _proto.pushClassMethod = function pushClassMethod(classBody, method, isGenerator, isAsync, isConstructor) {
    classBody.body.push(this.parseMethod(method, isGenerator, isAsync, isConstructor, "ClassMethod"));
  };

  _proto.pushClassPrivateMethod = function pushClassPrivateMethod(classBody, method, isGenerator, isAsync) {
    this.expectPlugin("classPrivateMethods", method.key.start);
    classBody.body.push(this.parseMethod(method, isGenerator, isAsync, false, "ClassPrivateMethod"));
  };

  _proto.parsePostMemberNameModifiers = function parsePostMemberNameModifiers(methodOrProp) {};

  _proto.parseAccessModifier = function parseAccessModifier() {
    return undefined;
  };

  _proto.parseClassPrivateProperty = function parseClassPrivateProperty(node) {
    var oldInMethod = this.state.inMethod;
    this.state.inMethod = false;
    this.state.inClassProperty = true;
    node.value = this.eat(types.eq) ? this.parseMaybeAssign() : null;
    this.semicolon();
    this.state.inClassProperty = false;
    this.state.inMethod = oldInMethod;
    return this.finishNode(node, "ClassPrivateProperty");
  };

  _proto.parseClassProperty = function parseClassProperty(node) {
    if (!node.typeAnnotation) {
      this.expectPlugin("classProperties");
    }

    var oldInMethod = this.state.inMethod;
    this.state.inMethod = false;
    this.state.inClassProperty = true;

    if (this.match(types.eq)) {
      this.expectPlugin("classProperties");
      this.next();
      node.value = this.parseMaybeAssign();
    } else {
      node.value = null;
    }

    this.semicolon();
    this.state.inClassProperty = false;
    this.state.inMethod = oldInMethod;
    return this.finishNode(node, "ClassProperty");
  };

  _proto.parseClassId = function parseClassId(node, isStatement, optionalId) {
    if (this.match(types.name)) {
      node.id = this.parseIdentifier();
    } else {
      if (optionalId || !isStatement) {
        node.id = null;
      } else {
        this.unexpected(null, "A class name is required");
      }
    }
  };

  _proto.parseClassSuper = function parseClassSuper(node) {
    node.superClass = this.eat(types._extends) ? this.parseExprSubscripts() : null;
  };

  _proto.parseExport = function parseExport(node) {
    if (this.shouldParseExportStar()) {
      this.parseExportStar(node);
      if (node.type === "ExportAllDeclaration") return node;
    } else if (this.isExportDefaultSpecifier()) {
      this.expectPlugin("exportDefaultFrom");
      var specifier = this.startNode();
      specifier.exported = this.parseIdentifier(true);
      var specifiers = [this.finishNode(specifier, "ExportDefaultSpecifier")];
      node.specifiers = specifiers;

      if (this.match(types.comma) && this.lookahead().type === types.star) {
        this.expect(types.comma);

        var _specifier = this.startNode();

        this.expect(types.star);
        this.expectContextual("as");
        _specifier.exported = this.parseIdentifier();
        specifiers.push(this.finishNode(_specifier, "ExportNamespaceSpecifier"));
      } else {
        this.parseExportSpecifiersMaybe(node);
      }

      this.parseExportFrom(node, true);
    } else if (this.eat(types._default)) {
      node.declaration = this.parseExportDefaultExpression();
      this.checkExport(node, true, true);
      return this.finishNode(node, "ExportDefaultDeclaration");
    } else if (this.shouldParseExportDeclaration()) {
      if (this.isContextual("async")) {
        var next = this.lookahead();

        if (next.type !== types._function) {
          this.unexpected(next.start, "Unexpected token, expected \"function\"");
        }
      }

      node.specifiers = [];
      node.source = null;
      node.declaration = this.parseExportDeclaration(node);
    } else {
      node.declaration = null;
      node.specifiers = this.parseExportSpecifiers();
      this.parseExportFrom(node);
    }

    this.checkExport(node, true);
    return this.finishNode(node, "ExportNamedDeclaration");
  };

  _proto.parseExportDefaultExpression = function parseExportDefaultExpression() {
    var expr = this.startNode();

    if (this.eat(types._function)) {
      return this.parseFunction(expr, true, false, false, true);
    } else if (this.isContextual("async") && this.lookahead().type === types._function) {
      this.eatContextual("async");
      this.eat(types._function);
      return this.parseFunction(expr, true, false, true, true);
    } else if (this.match(types._class)) {
      return this.parseClass(expr, true, true);
    } else if (this.match(types.at)) {
      this.parseDecorators(false);
      return this.parseClass(expr, true, true);
    } else if (this.match(types._let) || this.match(types._const) || this.match(types._var)) {
      return this.raise(this.state.start, "Only expressions, functions or classes are allowed as the `default` export.");
    } else {
      var res = this.parseMaybeAssign();
      this.semicolon();
      return res;
    }
  };

  _proto.parseExportDeclaration = function parseExportDeclaration(node) {
    return this.parseStatement(true);
  };

  _proto.isExportDefaultSpecifier = function isExportDefaultSpecifier() {
    if (this.match(types.name)) {
      return this.state.value !== "async";
    }

    if (!this.match(types._default)) {
      return false;
    }

    var lookahead = this.lookahead();
    return lookahead.type === types.comma || lookahead.type === types.name && lookahead.value === "from";
  };

  _proto.parseExportSpecifiersMaybe = function parseExportSpecifiersMaybe(node) {
    if (this.eat(types.comma)) {
      node.specifiers = node.specifiers.concat(this.parseExportSpecifiers());
    }
  };

  _proto.parseExportFrom = function parseExportFrom(node, expect) {
    if (this.eatContextual("from")) {
      node.source = this.match(types.string) ? this.parseExprAtom() : this.unexpected();
      this.checkExport(node);
    } else {
      if (expect) {
        this.unexpected();
      } else {
        node.source = null;
      }
    }

    this.semicolon();
  };

  _proto.shouldParseExportStar = function shouldParseExportStar() {
    return this.match(types.star);
  };

  _proto.parseExportStar = function parseExportStar(node) {
    this.expect(types.star);

    if (this.isContextual("as")) {
      this.parseExportNamespace(node);
    } else {
      this.parseExportFrom(node, true);
      this.finishNode(node, "ExportAllDeclaration");
    }
  };

  _proto.parseExportNamespace = function parseExportNamespace(node) {
    this.expectPlugin("exportNamespaceFrom");
    var specifier = this.startNodeAt(this.state.lastTokStart, this.state.lastTokStartLoc);
    this.next();
    specifier.exported = this.parseIdentifier(true);
    node.specifiers = [this.finishNode(specifier, "ExportNamespaceSpecifier")];
    this.parseExportSpecifiersMaybe(node);
    this.parseExportFrom(node, true);
  };

  _proto.shouldParseExportDeclaration = function shouldParseExportDeclaration() {
    return this.state.type.keyword === "var" || this.state.type.keyword === "const" || this.state.type.keyword === "let" || this.state.type.keyword === "function" || this.state.type.keyword === "class" || this.isContextual("async") || this.match(types.at) && this.expectPlugin("decorators");
  };

  _proto.checkExport = function checkExport(node, checkNames, isDefault) {
    if (checkNames) {
      if (isDefault) {
        this.checkDuplicateExports(node, "default");
      } else if (node.specifiers && node.specifiers.length) {
        for (var _i4 = 0, _node$specifiers2 = node.specifiers; _i4 < _node$specifiers2.length; _i4++) {
          var specifier = _node$specifiers2[_i4];
          this.checkDuplicateExports(specifier, specifier.exported.name);
        }
      } else if (node.declaration) {
        if (node.declaration.type === "FunctionDeclaration" || node.declaration.type === "ClassDeclaration") {
          var id = node.declaration.id;
          if (!id) throw new Error("Assertion failure");
          this.checkDuplicateExports(node, id.name);
        } else if (node.declaration.type === "VariableDeclaration") {
          for (var _i6 = 0, _node$declaration$dec2 = node.declaration.declarations; _i6 < _node$declaration$dec2.length; _i6++) {
            var declaration = _node$declaration$dec2[_i6];
            this.checkDeclaration(declaration.id);
          }
        }
      }
    }

    var currentContextDecorators = this.state.decoratorStack[this.state.decoratorStack.length - 1];

    if (currentContextDecorators.length) {
      var isClass = node.declaration && (node.declaration.type === "ClassDeclaration" || node.declaration.type === "ClassExpression");

      if (!node.declaration || !isClass) {
        throw this.raise(node.start, "You can only use decorators on an export when exporting a class");
      }

      this.takeDecorators(node.declaration);
    }
  };

  _proto.checkDeclaration = function checkDeclaration(node) {
    if (node.type === "ObjectPattern") {
      for (var _i8 = 0, _node$properties2 = node.properties; _i8 < _node$properties2.length; _i8++) {
        var prop = _node$properties2[_i8];
        this.checkDeclaration(prop);
      }
    } else if (node.type === "ArrayPattern") {
      for (var _i10 = 0, _node$elements2 = node.elements; _i10 < _node$elements2.length; _i10++) {
        var elem = _node$elements2[_i10];

        if (elem) {
          this.checkDeclaration(elem);
        }
      }
    } else if (node.type === "ObjectProperty") {
      this.checkDeclaration(node.value);
    } else if (node.type === "RestElement") {
      this.checkDeclaration(node.argument);
    } else if (node.type === "Identifier") {
      this.checkDuplicateExports(node, node.name);
    }
  };

  _proto.checkDuplicateExports = function checkDuplicateExports(node, name) {
    if (this.state.exportedIdentifiers.indexOf(name) > -1) {
      this.raiseDuplicateExportError(node, name);
    }

    this.state.exportedIdentifiers.push(name);
  };

  _proto.raiseDuplicateExportError = function raiseDuplicateExportError(node, name) {
    throw this.raise(node.start, name === "default" ? "Only one default export allowed per module." : "`" + name + "` has already been exported. Exported identifiers must be unique.");
  };

  _proto.parseExportSpecifiers = function parseExportSpecifiers() {
    var nodes = [];
    var first = true;
    var needsFrom;
    this.expect(types.braceL);

    while (!this.eat(types.braceR)) {
      if (first) {
        first = false;
      } else {
        this.expect(types.comma);
        if (this.eat(types.braceR)) break;
      }

      var isDefault = this.match(types._default);
      if (isDefault && !needsFrom) needsFrom = true;
      var node = this.startNode();
      node.local = this.parseIdentifier(isDefault);
      node.exported = this.eatContextual("as") ? this.parseIdentifier(true) : node.local.__clone();
      nodes.push(this.finishNode(node, "ExportSpecifier"));
    }

    if (needsFrom && !this.isContextual("from")) {
      this.unexpected();
    }

    return nodes;
  };

  _proto.parseImport = function parseImport(node) {
    if (this.match(types.string)) {
      node.specifiers = [];
      node.source = this.parseExprAtom();
    } else {
      node.specifiers = [];
      this.parseImportSpecifiers(node);
      this.expectContextual("from");
      node.source = this.match(types.string) ? this.parseExprAtom() : this.unexpected();
    }

    this.semicolon();
    return this.finishNode(node, "ImportDeclaration");
  };

  _proto.shouldParseDefaultImport = function shouldParseDefaultImport(node) {
    return this.match(types.name);
  };

  _proto.parseImportSpecifierLocal = function parseImportSpecifierLocal(node, specifier, type, contextDescription) {
    specifier.local = this.parseIdentifier();
    this.checkLVal(specifier.local, true, undefined, contextDescription);
    node.specifiers.push(this.finishNode(specifier, type));
  };

  _proto.parseImportSpecifiers = function parseImportSpecifiers(node) {
    var first = true;

    if (this.shouldParseDefaultImport(node)) {
      this.parseImportSpecifierLocal(node, this.startNode(), "ImportDefaultSpecifier", "default import specifier");
      if (!this.eat(types.comma)) return;
    }

    if (this.match(types.star)) {
      var specifier = this.startNode();
      this.next();
      this.expectContextual("as");
      this.parseImportSpecifierLocal(node, specifier, "ImportNamespaceSpecifier", "import namespace specifier");
      return;
    }

    this.expect(types.braceL);

    while (!this.eat(types.braceR)) {
      if (first) {
        first = false;
      } else {
        if (this.eat(types.colon)) {
          this.unexpected(null, "ES2015 named imports do not destructure. " + "Use another statement for destructuring after the import.");
        }

        this.expect(types.comma);
        if (this.eat(types.braceR)) break;
      }

      this.parseImportSpecifier(node);
    }
  };

  _proto.parseImportSpecifier = function parseImportSpecifier(node) {
    var specifier = this.startNode();
    specifier.imported = this.parseIdentifier(true);

    if (this.eatContextual("as")) {
      specifier.local = this.parseIdentifier();
    } else {
      this.checkReservedWord(specifier.imported.name, specifier.start, true, true);
      specifier.local = specifier.imported.__clone();
    }

    this.checkLVal(specifier.local, true, undefined, "import specifier");
    node.specifiers.push(this.finishNode(specifier, "ImportSpecifier"));
  };

  _inheritsLoose(StatementParser, _ExpressionParser);

  return StatementParser;
}(ExpressionParser);

var plugins = {};

var Parser = function (_StatementParser) {
  function Parser(options, input) {
    var _this;

    options = getOptions(options);
    _this = _StatementParser.call(this, options, input) || this;
    _this.options = options;
    _this.inModule = _this.options.sourceType === "module";
    _this.input = input;
    _this.plugins = pluginsMap(_this.options.plugins);
    _this.filename = options.sourceFilename;

    if (_this.state.pos === 0 && _this.input[0] === "#" && _this.input[1] === "!") {
      _this.skipLineComment(2);
    }

    return _this;
  }

  var _proto = Parser.prototype;

  _proto.parse = function parse() {
    var file = this.startNode();
    var program = this.startNode();
    this.nextToken();
    return this.parseTopLevel(file, program);
  };

  _inheritsLoose(Parser, _StatementParser);

  return Parser;
}(StatementParser);

function pluginsMap(pluginList) {
  var pluginMap = {};

  for (var _i2 = 0; _i2 < pluginList.length; _i2++) {
    var _name = pluginList[_i2];
    pluginMap[_name] = true;
  }

  return pluginMap;
}

function isSimpleProperty(node) {
  return node != null && node.type === "Property" && node.kind === "init" && node.method === false;
}

var estreePlugin = (function (superClass) {
  return function (_superClass) {
    function _class() {
      return _superClass.apply(this, arguments) || this;
    }

    var _proto = _class.prototype;

    _proto.estreeParseRegExpLiteral = function estreeParseRegExpLiteral(_ref) {
      var pattern = _ref.pattern,
          flags = _ref.flags;
      var regex = null;

      try {
        regex = new RegExp(pattern, flags);
      } catch (e) {}

      var node = this.estreeParseLiteral(regex);
      node.regex = {
        pattern: pattern,
        flags: flags
      };
      return node;
    };

    _proto.estreeParseLiteral = function estreeParseLiteral(value) {
      return this.parseLiteral(value, "Literal");
    };

    _proto.directiveToStmt = function directiveToStmt(directive) {
      var directiveLiteral = directive.value;
      var stmt = this.startNodeAt(directive.start, directive.loc.start);
      var expression = this.startNodeAt(directiveLiteral.start, directiveLiteral.loc.start);
      expression.value = directiveLiteral.value;
      expression.raw = directiveLiteral.extra.raw;
      stmt.expression = this.finishNodeAt(expression, "Literal", directiveLiteral.end, directiveLiteral.loc.end);
      stmt.directive = directiveLiteral.extra.raw.slice(1, -1);
      return this.finishNodeAt(stmt, "ExpressionStatement", directive.end, directive.loc.end);
    };

    _proto.initFunction = function initFunction(node, isAsync) {
      _superClass.prototype.initFunction.call(this, node, isAsync);

      node.expression = false;
    };

    _proto.checkDeclaration = function checkDeclaration(node) {
      if (isSimpleProperty(node)) {
        this.checkDeclaration(node.value);
      } else {
        _superClass.prototype.checkDeclaration.call(this, node);
      }
    };

    _proto.checkGetterSetterParams = function checkGetterSetterParams(method) {
      var prop = method;
      var paramCount = prop.kind === "get" ? 0 : 1;
      var start = prop.start;

      if (prop.value.params.length !== paramCount) {
        if (prop.kind === "get") {
          this.raise(start, "getter must not have any formal parameters");
        } else {
          this.raise(start, "setter must have exactly one formal parameter");
        }
      }

      if (prop.kind === "set" && prop.value.params[0].type === "RestElement") {
        this.raise(start, "setter function argument must not be a rest parameter");
      }
    };

    _proto.checkLVal = function checkLVal(expr, isBinding, checkClashes, contextDescription) {
      var _this = this;

      switch (expr.type) {
        case "ObjectPattern":
          expr.properties.forEach(function (prop) {
            _this.checkLVal(prop.type === "Property" ? prop.value : prop, isBinding, checkClashes, "object destructuring pattern");
          });
          break;

        default:
          _superClass.prototype.checkLVal.call(this, expr, isBinding, checkClashes, contextDescription);

      }
    };

    _proto.checkPropClash = function checkPropClash(prop, propHash) {
      if (prop.computed || !isSimpleProperty(prop)) return;
      var key = prop.key;
      var name = key.type === "Identifier" ? key.name : String(key.value);

      if (name === "__proto__") {
        if (propHash.proto) {
          this.raise(key.start, "Redefinition of __proto__ property");
        }

        propHash.proto = true;
      }
    };

    _proto.isStrictBody = function isStrictBody(node) {
      var isBlockStatement = node.body.type === "BlockStatement";

      if (isBlockStatement && node.body.body.length > 0) {
        for (var _i2 = 0, _node$body$body2 = node.body.body; _i2 < _node$body$body2.length; _i2++) {
          var directive = _node$body$body2[_i2];

          if (directive.type === "ExpressionStatement" && directive.expression.type === "Literal") {
            if (directive.expression.value === "use strict") return true;
          } else {
            break;
          }
        }
      }

      return false;
    };

    _proto.isValidDirective = function isValidDirective(stmt) {
      return stmt.type === "ExpressionStatement" && stmt.expression.type === "Literal" && typeof stmt.expression.value === "string" && (!stmt.expression.extra || !stmt.expression.extra.parenthesized);
    };

    _proto.stmtToDirective = function stmtToDirective(stmt) {
      var directive = _superClass.prototype.stmtToDirective.call(this, stmt);

      var value = stmt.expression.value;
      directive.value.value = value;
      return directive;
    };

    _proto.parseBlockBody = function parseBlockBody(node, allowDirectives, topLevel, end) {
      var _this2 = this;

      _superClass.prototype.parseBlockBody.call(this, node, allowDirectives, topLevel, end);

      var directiveStatements = node.directives.map(function (d) {
        return _this2.directiveToStmt(d);
      });
      node.body = directiveStatements.concat(node.body);
      delete node.directives;
    };

    _proto.pushClassMethod = function pushClassMethod(classBody, method, isGenerator, isAsync, isConstructor) {
      this.parseMethod(method, isGenerator, isAsync, isConstructor, "MethodDefinition");

      if (method.typeParameters) {
        method.value.typeParameters = method.typeParameters;
        delete method.typeParameters;
      }

      classBody.body.push(method);
    };

    _proto.parseExprAtom = function parseExprAtom(refShorthandDefaultPos) {
      switch (this.state.type) {
        case types.regexp:
          return this.estreeParseRegExpLiteral(this.state.value);

        case types.num:
        case types.string:
          return this.estreeParseLiteral(this.state.value);

        case types._null:
          return this.estreeParseLiteral(null);

        case types._true:
          return this.estreeParseLiteral(true);

        case types._false:
          return this.estreeParseLiteral(false);

        default:
          return _superClass.prototype.parseExprAtom.call(this, refShorthandDefaultPos);
      }
    };

    _proto.parseLiteral = function parseLiteral(value, type, startPos, startLoc) {
      var node = _superClass.prototype.parseLiteral.call(this, value, type, startPos, startLoc);

      node.raw = node.extra.raw;
      delete node.extra;
      return node;
    };

    _proto.parseFunctionBody = function parseFunctionBody(node, allowExpression) {
      _superClass.prototype.parseFunctionBody.call(this, node, allowExpression);

      node.expression = node.body.type !== "BlockStatement";
    };

    _proto.parseMethod = function parseMethod(node, isGenerator, isAsync, isConstructor, type) {
      var funcNode = this.startNode();
      funcNode.kind = node.kind;
      funcNode = _superClass.prototype.parseMethod.call(this, funcNode, isGenerator, isAsync, isConstructor, "FunctionExpression");
      delete funcNode.kind;
      node.value = funcNode;
      return this.finishNode(node, type);
    };

    _proto.parseObjectMethod = function parseObjectMethod(prop, isGenerator, isAsync, isPattern, containsEsc) {
      var node = _superClass.prototype.parseObjectMethod.call(this, prop, isGenerator, isAsync, isPattern, containsEsc);

      if (node) {
        node.type = "Property";
        if (node.kind === "method") node.kind = "init";
        node.shorthand = false;
      }

      return node;
    };

    _proto.parseObjectProperty = function parseObjectProperty(prop, startPos, startLoc, isPattern, refShorthandDefaultPos) {
      var node = _superClass.prototype.parseObjectProperty.call(this, prop, startPos, startLoc, isPattern, refShorthandDefaultPos);

      if (node) {
        node.kind = "init";
        node.type = "Property";
      }

      return node;
    };

    _proto.toAssignable = function toAssignable(node, isBinding, contextDescription) {
      if (isSimpleProperty(node)) {
        this.toAssignable(node.value, isBinding, contextDescription);
        return node;
      }

      return _superClass.prototype.toAssignable.call(this, node, isBinding, contextDescription);
    };

    _proto.toAssignableObjectExpressionProp = function toAssignableObjectExpressionProp(prop, isBinding, isLast) {
      if (prop.kind === "get" || prop.kind === "set") {
        this.raise(prop.key.start, "Object pattern can't contain getter or setter");
      } else if (prop.method) {
        this.raise(prop.key.start, "Object pattern can't contain methods");
      } else {
        _superClass.prototype.toAssignableObjectExpressionProp.call(this, prop, isBinding, isLast);
      }
    };

    _inheritsLoose(_class, _superClass);

    return _class;
  }(superClass);
});

var primitiveTypes = ["any", "bool", "boolean", "empty", "false", "mixed", "null", "number", "static", "string", "true", "typeof", "void"];

function isEsModuleType(bodyElement) {
  return bodyElement.type === "DeclareExportAllDeclaration" || bodyElement.type === "DeclareExportDeclaration" && (!bodyElement.declaration || bodyElement.declaration.type !== "TypeAlias" && bodyElement.declaration.type !== "InterfaceDeclaration");
}

function hasTypeImportKind(node) {
  return node.importKind === "type" || node.importKind === "typeof";
}

function isMaybeDefaultImport(state) {
  return (state.type === types.name || !!state.type.keyword) && state.value !== "from";
}

var exportSuggestions = {
  const: "declare export var",
  let: "declare export var",
  type: "export type",
  interface: "export interface"
};

function partition(list, test) {
  var list1 = [];
  var list2 = [];

  for (var i = 0; i < list.length; i++) {
    (test(list[i], i, list) ? list1 : list2).push(list[i]);
  }

  return [list1, list2];
}

var flowPlugin = (function (superClass) {
  return function (_superClass) {
    function _class() {
      return _superClass.apply(this, arguments) || this;
    }

    var _proto = _class.prototype;

    _proto.flowParseTypeInitialiser = function flowParseTypeInitialiser(tok) {
      var oldInType = this.state.inType;
      this.state.inType = true;
      this.expect(tok || types.colon);
      var type = this.flowParseType();
      this.state.inType = oldInType;
      return type;
    };

    _proto.flowParsePredicate = function flowParsePredicate() {
      var node = this.startNode();
      var moduloLoc = this.state.startLoc;
      var moduloPos = this.state.start;
      this.expect(types.modulo);
      var checksLoc = this.state.startLoc;
      this.expectContextual("checks");

      if (moduloLoc.line !== checksLoc.line || moduloLoc.column !== checksLoc.column - 1) {
        this.raise(moduloPos, "Spaces between ´%´ and ´checks´ are not allowed here.");
      }

      if (this.eat(types.parenL)) {
        node.value = this.parseExpression();
        this.expect(types.parenR);
        return this.finishNode(node, "DeclaredPredicate");
      } else {
        return this.finishNode(node, "InferredPredicate");
      }
    };

    _proto.flowParseTypeAndPredicateInitialiser = function flowParseTypeAndPredicateInitialiser() {
      var oldInType = this.state.inType;
      this.state.inType = true;
      this.expect(types.colon);
      var type = null;
      var predicate = null;

      if (this.match(types.modulo)) {
        this.state.inType = oldInType;
        predicate = this.flowParsePredicate();
      } else {
        type = this.flowParseType();
        this.state.inType = oldInType;

        if (this.match(types.modulo)) {
          predicate = this.flowParsePredicate();
        }
      }

      return [type, predicate];
    };

    _proto.flowParseDeclareClass = function flowParseDeclareClass(node) {
      this.next();
      this.flowParseInterfaceish(node, true);
      return this.finishNode(node, "DeclareClass");
    };

    _proto.flowParseDeclareFunction = function flowParseDeclareFunction(node) {
      this.next();
      var id = node.id = this.parseIdentifier();
      var typeNode = this.startNode();
      var typeContainer = this.startNode();

      if (this.isRelational("<")) {
        typeNode.typeParameters = this.flowParseTypeParameterDeclaration();
      } else {
        typeNode.typeParameters = null;
      }

      this.expect(types.parenL);
      var tmp = this.flowParseFunctionTypeParams();
      typeNode.params = tmp.params;
      typeNode.rest = tmp.rest;
      this.expect(types.parenR);

      var _this$flowParseTypeAn = this.flowParseTypeAndPredicateInitialiser();

      typeNode.returnType = _this$flowParseTypeAn[0];
      node.predicate = _this$flowParseTypeAn[1];
      typeContainer.typeAnnotation = this.finishNode(typeNode, "FunctionTypeAnnotation");
      id.typeAnnotation = this.finishNode(typeContainer, "TypeAnnotation");
      this.finishNode(id, id.type);
      this.semicolon();
      return this.finishNode(node, "DeclareFunction");
    };

    _proto.flowParseDeclare = function flowParseDeclare(node, insideModule) {
      if (this.match(types._class)) {
        return this.flowParseDeclareClass(node);
      } else if (this.match(types._function)) {
        return this.flowParseDeclareFunction(node);
      } else if (this.match(types._var)) {
        return this.flowParseDeclareVariable(node);
      } else if (this.isContextual("module")) {
        if (this.lookahead().type === types.dot) {
          return this.flowParseDeclareModuleExports(node);
        } else {
          if (insideModule) {
            this.unexpected(null, "`declare module` cannot be used inside another `declare module`");
          }

          return this.flowParseDeclareModule(node);
        }
      } else if (this.isContextual("type")) {
        return this.flowParseDeclareTypeAlias(node);
      } else if (this.isContextual("opaque")) {
        return this.flowParseDeclareOpaqueType(node);
      } else if (this.isContextual("interface")) {
        return this.flowParseDeclareInterface(node);
      } else if (this.match(types._export)) {
        return this.flowParseDeclareExportDeclaration(node, insideModule);
      } else {
        throw this.unexpected();
      }
    };

    _proto.flowParseDeclareVariable = function flowParseDeclareVariable(node) {
      this.next();
      node.id = this.flowParseTypeAnnotatableIdentifier(true);
      this.semicolon();
      return this.finishNode(node, "DeclareVariable");
    };

    _proto.flowParseDeclareModule = function flowParseDeclareModule(node) {
      var _this = this;

      this.next();

      if (this.match(types.string)) {
        node.id = this.parseExprAtom();
      } else {
        node.id = this.parseIdentifier();
      }

      var bodyNode = node.body = this.startNode();
      var body = bodyNode.body = [];
      this.expect(types.braceL);

      while (!this.match(types.braceR)) {
        var _bodyNode = this.startNode();

        if (this.match(types._import)) {
          var lookahead = this.lookahead();

          if (lookahead.value !== "type" && lookahead.value !== "typeof") {
            this.unexpected(null, "Imports within a `declare module` body must always be `import type` or `import typeof`");
          }

          this.next();
          this.parseImport(_bodyNode);
        } else {
          this.expectContextual("declare", "Only declares and type imports are allowed inside declare module");
          _bodyNode = this.flowParseDeclare(_bodyNode, true);
        }

        body.push(_bodyNode);
      }

      this.expect(types.braceR);
      this.finishNode(bodyNode, "BlockStatement");
      var kind = null;
      var hasModuleExport = false;
      var errorMessage = "Found both `declare module.exports` and `declare export` in the same module. " + "Modules can only have 1 since they are either an ES module or they are a CommonJS module";
      body.forEach(function (bodyElement) {
        if (isEsModuleType(bodyElement)) {
          if (kind === "CommonJS") {
            _this.unexpected(bodyElement.start, errorMessage);
          }

          kind = "ES";
        } else if (bodyElement.type === "DeclareModuleExports") {
          if (hasModuleExport) {
            _this.unexpected(bodyElement.start, "Duplicate `declare module.exports` statement");
          }

          if (kind === "ES") _this.unexpected(bodyElement.start, errorMessage);
          kind = "CommonJS";
          hasModuleExport = true;
        }
      });
      node.kind = kind || "CommonJS";
      return this.finishNode(node, "DeclareModule");
    };

    _proto.flowParseDeclareExportDeclaration = function flowParseDeclareExportDeclaration(node, insideModule) {
      this.expect(types._export);

      if (this.eat(types._default)) {
        if (this.match(types._function) || this.match(types._class)) {
          node.declaration = this.flowParseDeclare(this.startNode());
        } else {
          node.declaration = this.flowParseType();
          this.semicolon();
        }

        node.default = true;
        return this.finishNode(node, "DeclareExportDeclaration");
      } else {
        if (this.match(types._const) || this.match(types._let) || (this.isContextual("type") || this.isContextual("interface")) && !insideModule) {
          var label = this.state.value;
          var suggestion = exportSuggestions[label];
          this.unexpected(this.state.start, "`declare export " + label + "` is not supported. Use `" + suggestion + "` instead");
        }

        if (this.match(types._var) || this.match(types._function) || this.match(types._class) || this.isContextual("opaque")) {
            node.declaration = this.flowParseDeclare(this.startNode());
            node.default = false;
            return this.finishNode(node, "DeclareExportDeclaration");
          } else if (this.match(types.star) || this.match(types.braceL) || this.isContextual("interface") || this.isContextual("type") || this.isContextual("opaque")) {
            node = this.parseExport(node);

            if (node.type === "ExportNamedDeclaration") {
              node.type = "ExportDeclaration";
              node.default = false;
              delete node.exportKind;
            }

            node.type = "Declare" + node.type;
            return node;
          }
      }

      throw this.unexpected();
    };

    _proto.flowParseDeclareModuleExports = function flowParseDeclareModuleExports(node) {
      this.expectContextual("module");
      this.expect(types.dot);
      this.expectContextual("exports");
      node.typeAnnotation = this.flowParseTypeAnnotation();
      this.semicolon();
      return this.finishNode(node, "DeclareModuleExports");
    };

    _proto.flowParseDeclareTypeAlias = function flowParseDeclareTypeAlias(node) {
      this.next();
      this.flowParseTypeAlias(node);
      return this.finishNode(node, "DeclareTypeAlias");
    };

    _proto.flowParseDeclareOpaqueType = function flowParseDeclareOpaqueType(node) {
      this.next();
      this.flowParseOpaqueType(node, true);
      return this.finishNode(node, "DeclareOpaqueType");
    };

    _proto.flowParseDeclareInterface = function flowParseDeclareInterface(node) {
      this.next();
      this.flowParseInterfaceish(node);
      return this.finishNode(node, "DeclareInterface");
    };

    _proto.flowParseInterfaceish = function flowParseInterfaceish(node, isClass) {
      node.id = this.flowParseRestrictedIdentifier(!isClass);

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterDeclaration();
      } else {
        node.typeParameters = null;
      }

      node.extends = [];
      node.implements = [];
      node.mixins = [];

      if (this.eat(types._extends)) {
        do {
          node.extends.push(this.flowParseInterfaceExtends());
        } while (!isClass && this.eat(types.comma));
      }

      if (this.isContextual("mixins")) {
        this.next();

        do {
          node.mixins.push(this.flowParseInterfaceExtends());
        } while (this.eat(types.comma));
      }

      if (this.isContextual("implements")) {
        this.next();

        do {
          node.implements.push(this.flowParseInterfaceExtends());
        } while (this.eat(types.comma));
      }

      node.body = this.flowParseObjectType(true, false, false);
    };

    _proto.flowParseInterfaceExtends = function flowParseInterfaceExtends() {
      var node = this.startNode();
      node.id = this.flowParseQualifiedTypeIdentifier();

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterInstantiation();
      } else {
        node.typeParameters = null;
      }

      return this.finishNode(node, "InterfaceExtends");
    };

    _proto.flowParseInterface = function flowParseInterface(node) {
      this.flowParseInterfaceish(node);
      return this.finishNode(node, "InterfaceDeclaration");
    };

    _proto.checkReservedType = function checkReservedType(word, startLoc) {
      if (primitiveTypes.indexOf(word) > -1) {
        this.raise(startLoc, "Cannot overwrite primitive type " + word);
      }
    };

    _proto.flowParseRestrictedIdentifier = function flowParseRestrictedIdentifier(liberal) {
      this.checkReservedType(this.state.value, this.state.start);
      return this.parseIdentifier(liberal);
    };

    _proto.flowParseTypeAlias = function flowParseTypeAlias(node) {
      node.id = this.flowParseRestrictedIdentifier();

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterDeclaration();
      } else {
        node.typeParameters = null;
      }

      node.right = this.flowParseTypeInitialiser(types.eq);
      this.semicolon();
      return this.finishNode(node, "TypeAlias");
    };

    _proto.flowParseOpaqueType = function flowParseOpaqueType(node, declare) {
      this.expectContextual("type");
      node.id = this.flowParseRestrictedIdentifier(true);

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterDeclaration();
      } else {
        node.typeParameters = null;
      }

      node.supertype = null;

      if (this.match(types.colon)) {
        node.supertype = this.flowParseTypeInitialiser(types.colon);
      }

      node.impltype = null;

      if (!declare) {
        node.impltype = this.flowParseTypeInitialiser(types.eq);
      }

      this.semicolon();
      return this.finishNode(node, "OpaqueType");
    };

    _proto.flowParseTypeParameter = function flowParseTypeParameter(allowDefault, requireDefault) {
      if (allowDefault === void 0) {
        allowDefault = true;
      }

      if (requireDefault === void 0) {
        requireDefault = false;
      }

      if (!allowDefault && requireDefault) {
        throw new Error("Cannot disallow a default value (`allowDefault`) while also requiring it (`requireDefault`).");
      }

      var nodeStart = this.state.start;
      var node = this.startNode();
      var variance = this.flowParseVariance();
      var ident = this.flowParseTypeAnnotatableIdentifier();
      node.name = ident.name;
      node.variance = variance;
      node.bound = ident.typeAnnotation;

      if (this.match(types.eq)) {
        if (allowDefault) {
          this.eat(types.eq);
          node.default = this.flowParseType();
        } else {
          this.unexpected();
        }
      } else {
        if (requireDefault) {
          this.unexpected(nodeStart, "Type parameter declaration needs a default, since a preceding type parameter declaration has a default.");
        }
      }

      return this.finishNode(node, "TypeParameter");
    };

    _proto.flowParseTypeParameterDeclaration = function flowParseTypeParameterDeclaration(allowDefault) {
      if (allowDefault === void 0) {
        allowDefault = true;
      }

      var oldInType = this.state.inType;
      var node = this.startNode();
      node.params = [];
      this.state.inType = true;

      if (this.isRelational("<") || this.match(types.jsxTagStart)) {
        this.next();
      } else {
        this.unexpected();
      }

      var defaultRequired = false;

      do {
        var typeParameter = this.flowParseTypeParameter(allowDefault, defaultRequired);
        node.params.push(typeParameter);

        if (typeParameter.default) {
          defaultRequired = true;
        }

        if (!this.isRelational(">")) {
          this.expect(types.comma);
        }
      } while (!this.isRelational(">"));

      this.expectRelational(">");
      this.state.inType = oldInType;
      return this.finishNode(node, "TypeParameterDeclaration");
    };

    _proto.flowParseTypeParameterInstantiation = function flowParseTypeParameterInstantiation() {
      var node = this.startNode();
      var oldInType = this.state.inType;
      node.params = [];
      this.state.inType = true;
      this.expectRelational("<");

      while (!this.isRelational(">")) {
        node.params.push(this.flowParseType());

        if (!this.isRelational(">")) {
          this.expect(types.comma);
        }
      }

      this.expectRelational(">");
      this.state.inType = oldInType;
      return this.finishNode(node, "TypeParameterInstantiation");
    };

    _proto.flowParseObjectPropertyKey = function flowParseObjectPropertyKey() {
      return this.match(types.num) || this.match(types.string) ? this.parseExprAtom() : this.parseIdentifier(true);
    };

    _proto.flowParseObjectTypeIndexer = function flowParseObjectTypeIndexer(node, isStatic, variance) {
      node.static = isStatic;
      this.expect(types.bracketL);

      if (this.lookahead().type === types.colon) {
        node.id = this.flowParseObjectPropertyKey();
        node.key = this.flowParseTypeInitialiser();
      } else {
        node.id = null;
        node.key = this.flowParseType();
      }

      this.expect(types.bracketR);
      node.value = this.flowParseTypeInitialiser();
      node.variance = variance;
      return this.finishNode(node, "ObjectTypeIndexer");
    };

    _proto.flowParseObjectTypeMethodish = function flowParseObjectTypeMethodish(node) {
      node.params = [];
      node.rest = null;
      node.typeParameters = null;

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterDeclaration(false);
      }

      this.expect(types.parenL);

      while (!this.match(types.parenR) && !this.match(types.ellipsis)) {
        node.params.push(this.flowParseFunctionTypeParam());

        if (!this.match(types.parenR)) {
          this.expect(types.comma);
        }
      }

      if (this.eat(types.ellipsis)) {
        node.rest = this.flowParseFunctionTypeParam();
      }

      this.expect(types.parenR);
      node.returnType = this.flowParseTypeInitialiser();
      return this.finishNode(node, "FunctionTypeAnnotation");
    };

    _proto.flowParseObjectTypeCallProperty = function flowParseObjectTypeCallProperty(node, isStatic) {
      var valueNode = this.startNode();
      node.static = isStatic;
      node.value = this.flowParseObjectTypeMethodish(valueNode);
      return this.finishNode(node, "ObjectTypeCallProperty");
    };

    _proto.flowParseObjectType = function flowParseObjectType(allowStatic, allowExact, allowSpread) {
      var oldInType = this.state.inType;
      this.state.inType = true;
      var nodeStart = this.startNode();
      nodeStart.callProperties = [];
      nodeStart.properties = [];
      nodeStart.indexers = [];
      var endDelim;
      var exact;

      if (allowExact && this.match(types.braceBarL)) {
        this.expect(types.braceBarL);
        endDelim = types.braceBarR;
        exact = true;
      } else {
        this.expect(types.braceL);
        endDelim = types.braceR;
        exact = false;
      }

      nodeStart.exact = exact;

      while (!this.match(endDelim)) {
        var isStatic = false;
        var node = this.startNode();

        if (allowStatic && this.isContextual("static")) {
          var lookahead = this.lookahead();

          if (lookahead.type !== types.colon && lookahead.type !== types.question) {
            this.next();
            isStatic = true;
          }
        }

        var variance = this.flowParseVariance();

        if (this.match(types.bracketL)) {
          nodeStart.indexers.push(this.flowParseObjectTypeIndexer(node, isStatic, variance));
        } else if (this.match(types.parenL) || this.isRelational("<")) {
          if (variance) {
            this.unexpected(variance.start);
          }

          nodeStart.callProperties.push(this.flowParseObjectTypeCallProperty(node, isStatic));
        } else {
          var kind = "init";

          if (this.isContextual("get") || this.isContextual("set")) {
            var _lookahead = this.lookahead();

            if (_lookahead.type === types.name || _lookahead.type === types.string || _lookahead.type === types.num) {
              kind = this.state.value;
              this.next();
            }
          }

          nodeStart.properties.push(this.flowParseObjectTypeProperty(node, isStatic, variance, kind, allowSpread));
        }

        this.flowObjectTypeSemicolon();
      }

      this.expect(endDelim);
      var out = this.finishNode(nodeStart, "ObjectTypeAnnotation");
      this.state.inType = oldInType;
      return out;
    };

    _proto.flowParseObjectTypeProperty = function flowParseObjectTypeProperty(node, isStatic, variance, kind, allowSpread) {
      if (this.match(types.ellipsis)) {
        if (!allowSpread) {
          this.unexpected(null, "Spread operator cannot appear in class or interface definitions");
        }

        if (variance) {
          this.unexpected(variance.start, "Spread properties cannot have variance");
        }

        this.expect(types.ellipsis);
        node.argument = this.flowParseType();
        return this.finishNode(node, "ObjectTypeSpreadProperty");
      } else {
        node.key = this.flowParseObjectPropertyKey();
        node.static = isStatic;
        node.kind = kind;
        var optional = false;

        if (this.isRelational("<") || this.match(types.parenL)) {
          node.method = true;

          if (variance) {
            this.unexpected(variance.start);
          }

          node.value = this.flowParseObjectTypeMethodish(this.startNodeAt(node.start, node.loc.start));

          if (kind === "get" || kind === "set") {
            this.flowCheckGetterSetterParams(node);
          }
        } else {
          if (kind !== "init") this.unexpected();
          node.method = false;

          if (this.eat(types.question)) {
            optional = true;
          }

          node.value = this.flowParseTypeInitialiser();
          node.variance = variance;
        }

        node.optional = optional;
        return this.finishNode(node, "ObjectTypeProperty");
      }
    };

    _proto.flowCheckGetterSetterParams = function flowCheckGetterSetterParams(property) {
      var paramCount = property.kind === "get" ? 0 : 1;
      var start = property.start;
      var length = property.value.params.length + (property.value.rest ? 1 : 0);

      if (length !== paramCount) {
        if (property.kind === "get") {
          this.raise(start, "getter must not have any formal parameters");
        } else {
          this.raise(start, "setter must have exactly one formal parameter");
        }
      }

      if (property.kind === "set" && property.value.rest) {
        this.raise(start, "setter function argument must not be a rest parameter");
      }
    };

    _proto.flowObjectTypeSemicolon = function flowObjectTypeSemicolon() {
      if (!this.eat(types.semi) && !this.eat(types.comma) && !this.match(types.braceR) && !this.match(types.braceBarR)) {
        this.unexpected();
      }
    };

    _proto.flowParseQualifiedTypeIdentifier = function flowParseQualifiedTypeIdentifier(startPos, startLoc, id) {
      startPos = startPos || this.state.start;
      startLoc = startLoc || this.state.startLoc;
      var node = id || this.parseIdentifier();

      while (this.eat(types.dot)) {
        var node2 = this.startNodeAt(startPos, startLoc);
        node2.qualification = node;
        node2.id = this.parseIdentifier();
        node = this.finishNode(node2, "QualifiedTypeIdentifier");
      }

      return node;
    };

    _proto.flowParseGenericType = function flowParseGenericType(startPos, startLoc, id) {
      var node = this.startNodeAt(startPos, startLoc);
      node.typeParameters = null;
      node.id = this.flowParseQualifiedTypeIdentifier(startPos, startLoc, id);

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterInstantiation();
      }

      return this.finishNode(node, "GenericTypeAnnotation");
    };

    _proto.flowParseTypeofType = function flowParseTypeofType() {
      var node = this.startNode();
      this.expect(types._typeof);
      node.argument = this.flowParsePrimaryType();
      return this.finishNode(node, "TypeofTypeAnnotation");
    };

    _proto.flowParseTupleType = function flowParseTupleType() {
      var node = this.startNode();
      node.types = [];
      this.expect(types.bracketL);

      while (this.state.pos < this.input.length && !this.match(types.bracketR)) {
        node.types.push(this.flowParseType());
        if (this.match(types.bracketR)) break;
        this.expect(types.comma);
      }

      this.expect(types.bracketR);
      return this.finishNode(node, "TupleTypeAnnotation");
    };

    _proto.flowParseFunctionTypeParam = function flowParseFunctionTypeParam() {
      var name = null;
      var optional = false;
      var typeAnnotation = null;
      var node = this.startNode();
      var lh = this.lookahead();

      if (lh.type === types.colon || lh.type === types.question) {
        name = this.parseIdentifier();

        if (this.eat(types.question)) {
          optional = true;
        }

        typeAnnotation = this.flowParseTypeInitialiser();
      } else {
        typeAnnotation = this.flowParseType();
      }

      node.name = name;
      node.optional = optional;
      node.typeAnnotation = typeAnnotation;
      return this.finishNode(node, "FunctionTypeParam");
    };

    _proto.reinterpretTypeAsFunctionTypeParam = function reinterpretTypeAsFunctionTypeParam(type) {
      var node = this.startNodeAt(type.start, type.loc.start);
      node.name = null;
      node.optional = false;
      node.typeAnnotation = type;
      return this.finishNode(node, "FunctionTypeParam");
    };

    _proto.flowParseFunctionTypeParams = function flowParseFunctionTypeParams(params) {
      if (params === void 0) {
        params = [];
      }

      var rest = null;

      while (!this.match(types.parenR) && !this.match(types.ellipsis)) {
        params.push(this.flowParseFunctionTypeParam());

        if (!this.match(types.parenR)) {
          this.expect(types.comma);
        }
      }

      if (this.eat(types.ellipsis)) {
        rest = this.flowParseFunctionTypeParam();
      }

      return {
        params: params,
        rest: rest
      };
    };

    _proto.flowIdentToTypeAnnotation = function flowIdentToTypeAnnotation(startPos, startLoc, node, id) {
      switch (id.name) {
        case "any":
          return this.finishNode(node, "AnyTypeAnnotation");

        case "void":
          return this.finishNode(node, "VoidTypeAnnotation");

        case "bool":
        case "boolean":
          return this.finishNode(node, "BooleanTypeAnnotation");

        case "mixed":
          return this.finishNode(node, "MixedTypeAnnotation");

        case "empty":
          return this.finishNode(node, "EmptyTypeAnnotation");

        case "number":
          return this.finishNode(node, "NumberTypeAnnotation");

        case "string":
          return this.finishNode(node, "StringTypeAnnotation");

        default:
          return this.flowParseGenericType(startPos, startLoc, id);
      }
    };

    _proto.flowParsePrimaryType = function flowParsePrimaryType() {
      var startPos = this.state.start;
      var startLoc = this.state.startLoc;
      var node = this.startNode();
      var tmp;
      var type;
      var isGroupedType = false;
      var oldNoAnonFunctionType = this.state.noAnonFunctionType;

      switch (this.state.type) {
        case types.name:
          return this.flowIdentToTypeAnnotation(startPos, startLoc, node, this.parseIdentifier());

        case types.braceL:
          return this.flowParseObjectType(false, false, true);

        case types.braceBarL:
          return this.flowParseObjectType(false, true, true);

        case types.bracketL:
          return this.flowParseTupleType();

        case types.relational:
          if (this.state.value === "<") {
            node.typeParameters = this.flowParseTypeParameterDeclaration(false);
            this.expect(types.parenL);
            tmp = this.flowParseFunctionTypeParams();
            node.params = tmp.params;
            node.rest = tmp.rest;
            this.expect(types.parenR);
            this.expect(types.arrow);
            node.returnType = this.flowParseType();
            return this.finishNode(node, "FunctionTypeAnnotation");
          }

          break;

        case types.parenL:
          this.next();

          if (!this.match(types.parenR) && !this.match(types.ellipsis)) {
            if (this.match(types.name)) {
              var token = this.lookahead().type;
              isGroupedType = token !== types.question && token !== types.colon;
            } else {
              isGroupedType = true;
            }
          }

          if (isGroupedType) {
            this.state.noAnonFunctionType = false;
            type = this.flowParseType();
            this.state.noAnonFunctionType = oldNoAnonFunctionType;

            if (this.state.noAnonFunctionType || !(this.match(types.comma) || this.match(types.parenR) && this.lookahead().type === types.arrow)) {
              this.expect(types.parenR);
              return type;
            } else {
              this.eat(types.comma);
            }
          }

          if (type) {
            tmp = this.flowParseFunctionTypeParams([this.reinterpretTypeAsFunctionTypeParam(type)]);
          } else {
            tmp = this.flowParseFunctionTypeParams();
          }

          node.params = tmp.params;
          node.rest = tmp.rest;
          this.expect(types.parenR);
          this.expect(types.arrow);
          node.returnType = this.flowParseType();
          node.typeParameters = null;
          return this.finishNode(node, "FunctionTypeAnnotation");

        case types.string:
          return this.parseLiteral(this.state.value, "StringLiteralTypeAnnotation");

        case types._true:
        case types._false:
          node.value = this.match(types._true);
          this.next();
          return this.finishNode(node, "BooleanLiteralTypeAnnotation");

        case types.plusMin:
          if (this.state.value === "-") {
            this.next();

            if (!this.match(types.num)) {
              this.unexpected(null, "Unexpected token, expected \"number\"");
            }

            return this.parseLiteral(-this.state.value, "NumberLiteralTypeAnnotation", node.start, node.loc.start);
          }

          this.unexpected();

        case types.num:
          return this.parseLiteral(this.state.value, "NumberLiteralTypeAnnotation");

        case types._null:
          this.next();
          return this.finishNode(node, "NullLiteralTypeAnnotation");

        case types._this:
          this.next();
          return this.finishNode(node, "ThisTypeAnnotation");

        case types.star:
          this.next();
          return this.finishNode(node, "ExistsTypeAnnotation");

        default:
          if (this.state.type.keyword === "typeof") {
            return this.flowParseTypeofType();
          }

      }

      throw this.unexpected();
    };

    _proto.flowParsePostfixType = function flowParsePostfixType() {
      var startPos = this.state.start,
          startLoc = this.state.startLoc;
      var type = this.flowParsePrimaryType();

      while (!this.canInsertSemicolon() && this.match(types.bracketL)) {
        var node = this.startNodeAt(startPos, startLoc);
        node.elementType = type;
        this.expect(types.bracketL);
        this.expect(types.bracketR);
        type = this.finishNode(node, "ArrayTypeAnnotation");
      }

      return type;
    };

    _proto.flowParsePrefixType = function flowParsePrefixType() {
      var node = this.startNode();

      if (this.eat(types.question)) {
        node.typeAnnotation = this.flowParsePrefixType();
        return this.finishNode(node, "NullableTypeAnnotation");
      } else {
        return this.flowParsePostfixType();
      }
    };

    _proto.flowParseAnonFunctionWithoutParens = function flowParseAnonFunctionWithoutParens() {
      var param = this.flowParsePrefixType();

      if (!this.state.noAnonFunctionType && this.eat(types.arrow)) {
        var node = this.startNodeAt(param.start, param.loc.start);
        node.params = [this.reinterpretTypeAsFunctionTypeParam(param)];
        node.rest = null;
        node.returnType = this.flowParseType();
        node.typeParameters = null;
        return this.finishNode(node, "FunctionTypeAnnotation");
      }

      return param;
    };

    _proto.flowParseIntersectionType = function flowParseIntersectionType() {
      var node = this.startNode();
      this.eat(types.bitwiseAND);
      var type = this.flowParseAnonFunctionWithoutParens();
      node.types = [type];

      while (this.eat(types.bitwiseAND)) {
        node.types.push(this.flowParseAnonFunctionWithoutParens());
      }

      return node.types.length === 1 ? type : this.finishNode(node, "IntersectionTypeAnnotation");
    };

    _proto.flowParseUnionType = function flowParseUnionType() {
      var node = this.startNode();
      this.eat(types.bitwiseOR);
      var type = this.flowParseIntersectionType();
      node.types = [type];

      while (this.eat(types.bitwiseOR)) {
        node.types.push(this.flowParseIntersectionType());
      }

      return node.types.length === 1 ? type : this.finishNode(node, "UnionTypeAnnotation");
    };

    _proto.flowParseType = function flowParseType() {
      var oldInType = this.state.inType;
      this.state.inType = true;
      var type = this.flowParseUnionType();
      this.state.inType = oldInType;
      this.state.exprAllowed = this.state.exprAllowed || this.state.noAnonFunctionType;
      return type;
    };

    _proto.flowParseTypeAnnotation = function flowParseTypeAnnotation() {
      var node = this.startNode();
      node.typeAnnotation = this.flowParseTypeInitialiser();
      return this.finishNode(node, "TypeAnnotation");
    };

    _proto.flowParseTypeAnnotatableIdentifier = function flowParseTypeAnnotatableIdentifier(allowPrimitiveOverride) {
      var ident = allowPrimitiveOverride ? this.parseIdentifier() : this.flowParseRestrictedIdentifier();

      if (this.match(types.colon)) {
        ident.typeAnnotation = this.flowParseTypeAnnotation();
        this.finishNode(ident, ident.type);
      }

      return ident;
    };

    _proto.typeCastToParameter = function typeCastToParameter(node) {
      node.expression.typeAnnotation = node.typeAnnotation;
      return this.finishNodeAt(node.expression, node.expression.type, node.typeAnnotation.end, node.typeAnnotation.loc.end);
    };

    _proto.flowParseVariance = function flowParseVariance() {
      var variance = null;

      if (this.match(types.plusMin)) {
        variance = this.startNode();

        if (this.state.value === "+") {
          variance.kind = "plus";
        } else {
          variance.kind = "minus";
        }

        this.next();
        this.finishNode(variance, "Variance");
      }

      return variance;
    };

    _proto.parseFunctionBody = function parseFunctionBody(node, allowExpressionBody) {
      var _this2 = this;

      if (allowExpressionBody) {
        return this.forwardNoArrowParamsConversionAt(node, function () {
          return _superClass.prototype.parseFunctionBody.call(_this2, node, true);
        });
      }

      return _superClass.prototype.parseFunctionBody.call(this, node, false);
    };

    _proto.parseFunctionBodyAndFinish = function parseFunctionBodyAndFinish(node, type, allowExpressionBody) {
      if (!allowExpressionBody && this.match(types.colon)) {
        var typeNode = this.startNode();

        var _this$flowParseTypeAn2 = this.flowParseTypeAndPredicateInitialiser();

        typeNode.typeAnnotation = _this$flowParseTypeAn2[0];
        node.predicate = _this$flowParseTypeAn2[1];
        node.returnType = typeNode.typeAnnotation ? this.finishNode(typeNode, "TypeAnnotation") : null;
      }

      _superClass.prototype.parseFunctionBodyAndFinish.call(this, node, type, allowExpressionBody);
    };

    _proto.parseStatement = function parseStatement(declaration, topLevel) {
      if (this.state.strict && this.match(types.name) && this.state.value === "interface") {
        var node = this.startNode();
        this.next();
        return this.flowParseInterface(node);
      } else {
        return _superClass.prototype.parseStatement.call(this, declaration, topLevel);
      }
    };

    _proto.parseExpressionStatement = function parseExpressionStatement(node, expr) {
      if (expr.type === "Identifier") {
        if (expr.name === "declare") {
          if (this.match(types._class) || this.match(types.name) || this.match(types._function) || this.match(types._var) || this.match(types._export)) {
            return this.flowParseDeclare(node);
          }
        } else if (this.match(types.name)) {
          if (expr.name === "interface") {
            return this.flowParseInterface(node);
          } else if (expr.name === "type") {
            return this.flowParseTypeAlias(node);
          } else if (expr.name === "opaque") {
            return this.flowParseOpaqueType(node, false);
          }
        }
      }

      return _superClass.prototype.parseExpressionStatement.call(this, node, expr);
    };

    _proto.shouldParseExportDeclaration = function shouldParseExportDeclaration() {
      return this.isContextual("type") || this.isContextual("interface") || this.isContextual("opaque") || _superClass.prototype.shouldParseExportDeclaration.call(this);
    };

    _proto.isExportDefaultSpecifier = function isExportDefaultSpecifier() {
      if (this.match(types.name) && (this.state.value === "type" || this.state.value === "interface" || this.state.value == "opaque")) {
        return false;
      }

      return _superClass.prototype.isExportDefaultSpecifier.call(this);
    };

    _proto.parseConditional = function parseConditional(expr, noIn, startPos, startLoc, refNeedsArrowPos) {
      var _this3 = this;

      if (!this.match(types.question)) return expr;

      if (refNeedsArrowPos) {
        var _state = this.state.clone();

        try {
          return _superClass.prototype.parseConditional.call(this, expr, noIn, startPos, startLoc);
        } catch (err) {
          if (err instanceof SyntaxError) {
            this.state = _state;
            refNeedsArrowPos.start = err.pos || this.state.start;
            return expr;
          } else {
            throw err;
          }
        }
      }

      this.expect(types.question);
      var state = this.state.clone();
      var originalNoArrowAt = this.state.noArrowAt;
      var node = this.startNodeAt(startPos, startLoc);

      var _this$tryParseConditi = this.tryParseConditionalConsequent(),
          consequent = _this$tryParseConditi.consequent,
          failed = _this$tryParseConditi.failed;

      var _this$getArrowLikeExp = this.getArrowLikeExpressions(consequent),
          valid = _this$getArrowLikeExp[0],
          invalid = _this$getArrowLikeExp[1];

      if (failed || invalid.length > 0) {
        var noArrowAt = originalNoArrowAt.concat();

        if (invalid.length > 0) {
          this.state = state;
          this.state.noArrowAt = noArrowAt;

          for (var i = 0; i < invalid.length; i++) {
            noArrowAt.push(invalid[i].start);
          }

          var _this$tryParseConditi2 = this.tryParseConditionalConsequent();

          consequent = _this$tryParseConditi2.consequent;
          failed = _this$tryParseConditi2.failed;

          var _this$getArrowLikeExp2 = this.getArrowLikeExpressions(consequent);

          valid = _this$getArrowLikeExp2[0];
          invalid = _this$getArrowLikeExp2[1];
        }

        if (failed && valid.length > 1) {
          this.raise(state.start, "Ambiguous expression: wrap the arrow functions in parentheses to disambiguate.");
        }

        if (failed && valid.length === 1) {
          this.state = state;
          this.state.noArrowAt = noArrowAt.concat(valid[0].start);

          var _this$tryParseConditi3 = this.tryParseConditionalConsequent();

          consequent = _this$tryParseConditi3.consequent;
          failed = _this$tryParseConditi3.failed;
        }

        this.getArrowLikeExpressions(consequent, true);
      }

      this.state.noArrowAt = originalNoArrowAt;
      this.expect(types.colon);
      node.test = expr;
      node.consequent = consequent;
      node.alternate = this.forwardNoArrowParamsConversionAt(node, function () {
        return _this3.parseMaybeAssign(noIn, undefined, undefined, undefined);
      });
      return this.finishNode(node, "ConditionalExpression");
    };

    _proto.tryParseConditionalConsequent = function tryParseConditionalConsequent() {
      this.state.noArrowParamsConversionAt.push(this.state.start);
      var consequent = this.parseMaybeAssign();
      var failed = !this.match(types.colon);
      this.state.noArrowParamsConversionAt.pop();
      return {
        consequent: consequent,
        failed: failed
      };
    };

    _proto.getArrowLikeExpressions = function getArrowLikeExpressions(node, disallowInvalid) {
      var _this4 = this;

      var stack = [node];
      var arrows = [];

      while (stack.length !== 0) {
        var _node = stack.pop();

        if (_node.type === "ArrowFunctionExpression") {
          if (_node.typeParameters || !_node.returnType) {
            this.toAssignableList(_node.params, true, "arrow function parameters");

            _superClass.prototype.checkFunctionNameAndParams.call(this, _node, true);
          } else {
            arrows.push(_node);
          }

          stack.push(_node.body);
        } else if (_node.type === "ConditionalExpression") {
          stack.push(_node.consequent);
          stack.push(_node.alternate);
        }
      }

      if (disallowInvalid) {
        for (var i = 0; i < arrows.length; i++) {
          this.toAssignableList(node.params, true, "arrow function parameters");
        }

        return [arrows, []];
      }

      return partition(arrows, function (node) {
        try {
          _this4.toAssignableList(node.params, true, "arrow function parameters");

          return true;
        } catch (err) {
          return false;
        }
      });
    };

    _proto.forwardNoArrowParamsConversionAt = function forwardNoArrowParamsConversionAt(node, parse) {
      var result;

      if (this.state.noArrowParamsConversionAt.indexOf(node.start) !== -1) {
        this.state.noArrowParamsConversionAt.push(this.state.start);
        result = parse();
        this.state.noArrowParamsConversionAt.pop();
      } else {
        result = parse();
      }

      return result;
    };

    _proto.parseParenItem = function parseParenItem(node, startPos, startLoc) {
      node = _superClass.prototype.parseParenItem.call(this, node, startPos, startLoc);

      if (this.eat(types.question)) {
        node.optional = true;
      }

      if (this.match(types.colon)) {
        var typeCastNode = this.startNodeAt(startPos, startLoc);
        typeCastNode.expression = node;
        typeCastNode.typeAnnotation = this.flowParseTypeAnnotation();
        return this.finishNode(typeCastNode, "TypeCastExpression");
      }

      return node;
    };

    _proto.assertModuleNodeAllowed = function assertModuleNodeAllowed(node) {
      if (node.type === "ImportDeclaration" && (node.importKind === "type" || node.importKind === "typeof") || node.type === "ExportNamedDeclaration" && node.exportKind === "type" || node.type === "ExportAllDeclaration" && node.exportKind === "type") {
        return;
      }

      _superClass.prototype.assertModuleNodeAllowed.call(this, node);
    };

    _proto.parseExport = function parseExport(node) {
      node = _superClass.prototype.parseExport.call(this, node);

      if (node.type === "ExportNamedDeclaration" || node.type === "ExportAllDeclaration") {
        node.exportKind = node.exportKind || "value";
      }

      return node;
    };

    _proto.parseExportDeclaration = function parseExportDeclaration(node) {
      if (this.isContextual("type")) {
        node.exportKind = "type";
        var declarationNode = this.startNode();
        this.next();

        if (this.match(types.braceL)) {
          node.specifiers = this.parseExportSpecifiers();
          this.parseExportFrom(node);
          return null;
        } else {
          return this.flowParseTypeAlias(declarationNode);
        }
      } else if (this.isContextual("opaque")) {
        node.exportKind = "type";

        var _declarationNode = this.startNode();

        this.next();
        return this.flowParseOpaqueType(_declarationNode, false);
      } else if (this.isContextual("interface")) {
        node.exportKind = "type";

        var _declarationNode2 = this.startNode();

        this.next();
        return this.flowParseInterface(_declarationNode2);
      } else {
        return _superClass.prototype.parseExportDeclaration.call(this, node);
      }
    };

    _proto.shouldParseExportStar = function shouldParseExportStar() {
      return _superClass.prototype.shouldParseExportStar.call(this) || this.isContextual("type") && this.lookahead().type === types.star;
    };

    _proto.parseExportStar = function parseExportStar(node) {
      if (this.eatContextual("type")) {
        node.exportKind = "type";
      }

      return _superClass.prototype.parseExportStar.call(this, node);
    };

    _proto.parseExportNamespace = function parseExportNamespace(node) {
      if (node.exportKind === "type") {
        this.unexpected();
      }

      return _superClass.prototype.parseExportNamespace.call(this, node);
    };

    _proto.parseClassId = function parseClassId(node, isStatement, optionalId) {
      _superClass.prototype.parseClassId.call(this, node, isStatement, optionalId);

      if (this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterDeclaration();
      }
    };

    _proto.isKeyword = function isKeyword$$1(name) {
      if (this.state.inType && name === "void") {
        return false;
      } else {
        return _superClass.prototype.isKeyword.call(this, name);
      }
    };

    _proto.readToken = function readToken(code) {
      var next = this.input.charCodeAt(this.state.pos + 1);

      if (this.state.inType && (code === 62 || code === 60)) {
        return this.finishOp(types.relational, 1);
      } else if (isIteratorStart(code, next)) {
        this.state.isIterator = true;
        return _superClass.prototype.readWord.call(this);
      } else {
        return _superClass.prototype.readToken.call(this, code);
      }
    };

    _proto.toAssignable = function toAssignable(node, isBinding, contextDescription) {
      if (node.type === "TypeCastExpression") {
        return _superClass.prototype.toAssignable.call(this, this.typeCastToParameter(node), isBinding, contextDescription);
      } else {
        return _superClass.prototype.toAssignable.call(this, node, isBinding, contextDescription);
      }
    };

    _proto.toAssignableList = function toAssignableList(exprList, isBinding, contextDescription) {
      for (var i = 0; i < exprList.length; i++) {
        var expr = exprList[i];

        if (expr && expr.type === "TypeCastExpression") {
          exprList[i] = this.typeCastToParameter(expr);
        }
      }

      return _superClass.prototype.toAssignableList.call(this, exprList, isBinding, contextDescription);
    };

    _proto.toReferencedList = function toReferencedList(exprList) {
      for (var i = 0; i < exprList.length; i++) {
        var expr = exprList[i];

        if (expr && expr._exprListItem && expr.type === "TypeCastExpression") {
          this.raise(expr.start, "Unexpected type cast");
        }
      }

      return exprList;
    };

    _proto.parseExprListItem = function parseExprListItem(allowEmpty, refShorthandDefaultPos, refNeedsArrowPos) {
      var container = this.startNode();

      var node = _superClass.prototype.parseExprListItem.call(this, allowEmpty, refShorthandDefaultPos, refNeedsArrowPos);

      if (this.match(types.colon)) {
        container._exprListItem = true;
        container.expression = node;
        container.typeAnnotation = this.flowParseTypeAnnotation();
        return this.finishNode(container, "TypeCastExpression");
      } else {
        return node;
      }
    };

    _proto.checkLVal = function checkLVal(expr, isBinding, checkClashes, contextDescription) {
      if (expr.type !== "TypeCastExpression") {
        return _superClass.prototype.checkLVal.call(this, expr, isBinding, checkClashes, contextDescription);
      }
    };

    _proto.parseClassProperty = function parseClassProperty(node) {
      if (this.match(types.colon)) {
        node.typeAnnotation = this.flowParseTypeAnnotation();
      }

      return _superClass.prototype.parseClassProperty.call(this, node);
    };

    _proto.isClassMethod = function isClassMethod() {
      return this.isRelational("<") || _superClass.prototype.isClassMethod.call(this);
    };

    _proto.isClassProperty = function isClassProperty() {
      return this.match(types.colon) || _superClass.prototype.isClassProperty.call(this);
    };

    _proto.isNonstaticConstructor = function isNonstaticConstructor(method) {
      return !this.match(types.colon) && _superClass.prototype.isNonstaticConstructor.call(this, method);
    };

    _proto.pushClassMethod = function pushClassMethod(classBody, method, isGenerator, isAsync, isConstructor) {
      if (method.variance) {
        this.unexpected(method.variance.start);
      }

      delete method.variance;

      if (this.isRelational("<")) {
        method.typeParameters = this.flowParseTypeParameterDeclaration(false);
      }

      _superClass.prototype.pushClassMethod.call(this, classBody, method, isGenerator, isAsync, isConstructor);
    };

    _proto.pushClassPrivateMethod = function pushClassPrivateMethod(classBody, method, isGenerator, isAsync) {
      if (method.variance) {
        this.unexpected(method.variance.start);
      }

      delete method.variance;

      if (this.isRelational("<")) {
        method.typeParameters = this.flowParseTypeParameterDeclaration();
      }

      _superClass.prototype.pushClassPrivateMethod.call(this, classBody, method, isGenerator, isAsync);
    };

    _proto.parseClassSuper = function parseClassSuper(node) {
      _superClass.prototype.parseClassSuper.call(this, node);

      if (node.superClass && this.isRelational("<")) {
        node.superTypeParameters = this.flowParseTypeParameterInstantiation();
      }

      if (this.isContextual("implements")) {
        this.next();
        var implemented = node.implements = [];

        do {
          var _node2 = this.startNode();

          _node2.id = this.flowParseRestrictedIdentifier(true);

          if (this.isRelational("<")) {
            _node2.typeParameters = this.flowParseTypeParameterInstantiation();
          } else {
            _node2.typeParameters = null;
          }

          implemented.push(this.finishNode(_node2, "ClassImplements"));
        } while (this.eat(types.comma));
      }
    };

    _proto.parsePropertyName = function parsePropertyName(node) {
      var variance = this.flowParseVariance();

      var key = _superClass.prototype.parsePropertyName.call(this, node);

      node.variance = variance;
      return key;
    };

    _proto.parseObjPropValue = function parseObjPropValue(prop, startPos, startLoc, isGenerator, isAsync, isPattern, refShorthandDefaultPos, containsEsc) {
      if (prop.variance) {
        this.unexpected(prop.variance.start);
      }

      delete prop.variance;
      var typeParameters;

      if (this.isRelational("<")) {
        typeParameters = this.flowParseTypeParameterDeclaration(false);
        if (!this.match(types.parenL)) this.unexpected();
      }

      _superClass.prototype.parseObjPropValue.call(this, prop, startPos, startLoc, isGenerator, isAsync, isPattern, refShorthandDefaultPos, containsEsc);

      if (typeParameters) {
        (prop.value || prop).typeParameters = typeParameters;
      }
    };

    _proto.parseAssignableListItemTypes = function parseAssignableListItemTypes(param) {
      if (this.eat(types.question)) {
        if (param.type !== "Identifier") {
          throw this.raise(param.start, "A binding pattern parameter cannot be optional in an implementation signature.");
        }

        param.optional = true;
      }

      if (this.match(types.colon)) {
        param.typeAnnotation = this.flowParseTypeAnnotation();
      }

      this.finishNode(param, param.type);
      return param;
    };

    _proto.parseMaybeDefault = function parseMaybeDefault(startPos, startLoc, left) {
      var node = _superClass.prototype.parseMaybeDefault.call(this, startPos, startLoc, left);

      if (node.type === "AssignmentPattern" && node.typeAnnotation && node.right.start < node.typeAnnotation.start) {
        this.raise(node.typeAnnotation.start, "Type annotations must come before default assignments, " + "e.g. instead of `age = 25: number` use `age: number = 25`");
      }

      return node;
    };

    _proto.shouldParseDefaultImport = function shouldParseDefaultImport(node) {
      if (!hasTypeImportKind(node)) {
        return _superClass.prototype.shouldParseDefaultImport.call(this, node);
      }

      return isMaybeDefaultImport(this.state);
    };

    _proto.parseImportSpecifierLocal = function parseImportSpecifierLocal(node, specifier, type, contextDescription) {
      specifier.local = hasTypeImportKind(node) ? this.flowParseRestrictedIdentifier(true) : this.parseIdentifier();
      this.checkLVal(specifier.local, true, undefined, contextDescription);
      node.specifiers.push(this.finishNode(specifier, type));
    };

    _proto.parseImportSpecifiers = function parseImportSpecifiers(node) {
      node.importKind = "value";
      var kind = null;

      if (this.match(types._typeof)) {
        kind = "typeof";
      } else if (this.isContextual("type")) {
        kind = "type";
      }

      if (kind) {
        var lh = this.lookahead();

        if (kind === "type" && lh.type === types.star) {
          this.unexpected(lh.start);
        }

        if (isMaybeDefaultImport(lh) || lh.type === types.braceL || lh.type === types.star) {
          this.next();
          node.importKind = kind;
        }
      }

      _superClass.prototype.parseImportSpecifiers.call(this, node);
    };

    _proto.parseImportSpecifier = function parseImportSpecifier(node) {
      var specifier = this.startNode();
      var firstIdentLoc = this.state.start;
      var firstIdent = this.parseIdentifier(true);
      var specifierTypeKind = null;

      if (firstIdent.name === "type") {
        specifierTypeKind = "type";
      } else if (firstIdent.name === "typeof") {
        specifierTypeKind = "typeof";
      }

      var isBinding = false;

      if (this.isContextual("as") && !this.isLookaheadContextual("as")) {
        var as_ident = this.parseIdentifier(true);

        if (specifierTypeKind !== null && !this.match(types.name) && !this.state.type.keyword) {
          specifier.imported = as_ident;
          specifier.importKind = specifierTypeKind;
          specifier.local = as_ident.__clone();
        } else {
          specifier.imported = firstIdent;
          specifier.importKind = null;
          specifier.local = this.parseIdentifier();
        }
      } else if (specifierTypeKind !== null && (this.match(types.name) || this.state.type.keyword)) {
        specifier.imported = this.parseIdentifier(true);
        specifier.importKind = specifierTypeKind;

        if (this.eatContextual("as")) {
          specifier.local = this.parseIdentifier();
        } else {
          isBinding = true;
          specifier.local = specifier.imported.__clone();
        }
      } else {
        isBinding = true;
        specifier.imported = firstIdent;
        specifier.importKind = null;
        specifier.local = specifier.imported.__clone();
      }

      var nodeIsTypeImport = hasTypeImportKind(node);
      var specifierIsTypeImport = hasTypeImportKind(specifier);

      if (nodeIsTypeImport && specifierIsTypeImport) {
        this.raise(firstIdentLoc, "The `type` and `typeof` keywords on named imports can only be used on regular " + "`import` statements. It cannot be used with `import type` or `import typeof` statements");
      }

      if (nodeIsTypeImport || specifierIsTypeImport) {
        this.checkReservedType(specifier.local.name, specifier.local.start);
      }

      if (isBinding && !nodeIsTypeImport && !specifierIsTypeImport) {
        this.checkReservedWord(specifier.local.name, specifier.start, true, true);
      }

      this.checkLVal(specifier.local, true, undefined, "import specifier");
      node.specifiers.push(this.finishNode(specifier, "ImportSpecifier"));
    };

    _proto.parseFunctionParams = function parseFunctionParams(node) {
      var kind = node.kind;

      if (kind !== "get" && kind !== "set" && this.isRelational("<")) {
        node.typeParameters = this.flowParseTypeParameterDeclaration(false);
      }

      _superClass.prototype.parseFunctionParams.call(this, node);
    };

    _proto.parseVarHead = function parseVarHead(decl) {
      _superClass.prototype.parseVarHead.call(this, decl);

      if (this.match(types.colon)) {
        decl.id.typeAnnotation = this.flowParseTypeAnnotation();
        this.finishNode(decl.id, decl.id.type);
      }
    };

    _proto.parseAsyncArrowFromCallExpression = function parseAsyncArrowFromCallExpression(node, call) {
      if (this.match(types.colon)) {
        var oldNoAnonFunctionType = this.state.noAnonFunctionType;
        this.state.noAnonFunctionType = true;
        node.returnType = this.flowParseTypeAnnotation();
        this.state.noAnonFunctionType = oldNoAnonFunctionType;
      }

      return _superClass.prototype.parseAsyncArrowFromCallExpression.call(this, node, call);
    };

    _proto.shouldParseAsyncArrow = function shouldParseAsyncArrow() {
      return this.match(types.colon) || _superClass.prototype.shouldParseAsyncArrow.call(this);
    };

    _proto.parseMaybeAssign = function parseMaybeAssign(noIn, refShorthandDefaultPos, afterLeftParse, refNeedsArrowPos) {
      var _this5 = this;

      var jsxError = null;

      if (types.jsxTagStart && this.match(types.jsxTagStart)) {
        var state = this.state.clone();

        try {
          return _superClass.prototype.parseMaybeAssign.call(this, noIn, refShorthandDefaultPos, afterLeftParse, refNeedsArrowPos);
        } catch (err) {
          if (err instanceof SyntaxError) {
            this.state = state;
            this.state.context.length -= 2;
            jsxError = err;
          } else {
            throw err;
          }
        }
      }

      if (jsxError != null || this.isRelational("<")) {
        var arrowExpression;
        var typeParameters;

        try {
          typeParameters = this.flowParseTypeParameterDeclaration();
          arrowExpression = this.forwardNoArrowParamsConversionAt(typeParameters, function () {
            return _superClass.prototype.parseMaybeAssign.call(_this5, noIn, refShorthandDefaultPos, afterLeftParse, refNeedsArrowPos);
          });
          arrowExpression.typeParameters = typeParameters;
          this.resetStartLocationFromNode(arrowExpression, typeParameters);
        } catch (err) {
          throw jsxError || err;
        }

        if (arrowExpression.type === "ArrowFunctionExpression") {
          return arrowExpression;
        } else if (jsxError != null) {
          throw jsxError;
        } else {
          this.raise(typeParameters.start, "Expected an arrow function after this type parameter declaration");
        }
      }

      return _superClass.prototype.parseMaybeAssign.call(this, noIn, refShorthandDefaultPos, afterLeftParse, refNeedsArrowPos);
    };

    _proto.parseArrow = function parseArrow(node) {
      if (this.match(types.colon)) {
        var state = this.state.clone();

        try {
          var oldNoAnonFunctionType = this.state.noAnonFunctionType;
          this.state.noAnonFunctionType = true;
          var typeNode = this.startNode();

          var _this$flowParseTypeAn3 = this.flowParseTypeAndPredicateInitialiser();

          typeNode.typeAnnotation = _this$flowParseTypeAn3[0];
          node.predicate = _this$flowParseTypeAn3[1];
          this.state.noAnonFunctionType = oldNoAnonFunctionType;
          if (this.canInsertSemicolon()) this.unexpected();
          if (!this.match(types.arrow)) this.unexpected();
          node.returnType = typeNode.typeAnnotation ? this.finishNode(typeNode, "TypeAnnotation") : null;
        } catch (err) {
          if (err instanceof SyntaxError) {
            this.state = state;
          } else {
            throw err;
          }
        }
      }

      return _superClass.prototype.parseArrow.call(this, node);
    };

    _proto.shouldParseArrow = function shouldParseArrow() {
      return this.match(types.colon) || _superClass.prototype.shouldParseArrow.call(this);
    };

    _proto.setArrowFunctionParameters = function setArrowFunctionParameters(node, params) {
      if (this.state.noArrowParamsConversionAt.indexOf(node.start) !== -1) {
        node.params = params;
      } else {
        _superClass.prototype.setArrowFunctionParameters.call(this, node, params);
      }
    };

    _proto.checkFunctionNameAndParams = function checkFunctionNameAndParams(node, isArrowFunction) {
      if (isArrowFunction && this.state.noArrowParamsConversionAt.indexOf(node.start) !== -1) {
        return;
      }

      return _superClass.prototype.checkFunctionNameAndParams.call(this, node, isArrowFunction);
    };

    _proto.parseParenAndDistinguishExpression = function parseParenAndDistinguishExpression(canBeArrow) {
      return _superClass.prototype.parseParenAndDistinguishExpression.call(this, canBeArrow && this.state.noArrowAt.indexOf(this.state.start) === -1);
    };

    _proto.parseSubscripts = function parseSubscripts(base, startPos, startLoc, noCalls) {
      if (base.type === "Identifier" && base.name === "async" && this.state.noArrowAt.indexOf(startPos) !== -1) {
        this.next();
        var node = this.startNodeAt(startPos, startLoc);
        node.callee = base;
        node.arguments = this.parseCallExpressionArguments(types.parenR, false);
        base = this.finishNode(node, "CallExpression");
      } else if (base.type === "Identifier" && base.name === "async" && this.isRelational("<")) {
        var state = this.state.clone();
        var error;

        try {
          var _node3 = this.parseAsyncArrowWithTypeParameters(startPos, startLoc);

          if (_node3) return _node3;
        } catch (e) {
          error = e;
        }

        this.state = state;

        try {
          return _superClass.prototype.parseSubscripts.call(this, base, startPos, startLoc, noCalls);
        } catch (e) {
          throw error || e;
        }
      }

      return _superClass.prototype.parseSubscripts.call(this, base, startPos, startLoc, noCalls);
    };

    _proto.parseAsyncArrowWithTypeParameters = function parseAsyncArrowWithTypeParameters(startPos, startLoc) {
      var node = this.startNodeAt(startPos, startLoc);
      this.parseFunctionParams(node);
      if (!this.parseArrow(node)) return;
      return this.parseArrowExpression(node, undefined, true);
    };

    _proto.readToken_mult_modulo = function readToken_mult_modulo(code) {
      var next = this.input.charCodeAt(this.state.pos + 1);

      if (code === 42 && next === 47 && this.state.hasFlowComment) {
        this.state.hasFlowComment = false;
        this.state.pos += 2;
        this.nextToken();
        return;
      }

      _superClass.prototype.readToken_mult_modulo.call(this, code);
    };

    _proto.skipBlockComment = function skipBlockComment() {
      if (this.hasPlugin("flow") && this.hasPlugin("flowComments") && this.skipFlowComment()) {
        this.hasFlowCommentCompletion();
        this.state.pos += this.skipFlowComment();
        this.state.hasFlowComment = true;
        return;
      }

      var end;

      if (this.hasPlugin("flow") && this.state.hasFlowComment) {
        end = this.input.indexOf("*-/", this.state.pos += 2);
        if (end === -1) this.raise(this.state.pos - 2, "Unterminated comment");
        this.state.pos = end + 3;
        return;
      }

      _superClass.prototype.skipBlockComment.call(this);
    };

    _proto.skipFlowComment = function skipFlowComment() {
      var ch2 = this.input.charCodeAt(this.state.pos + 2);
      var ch3 = this.input.charCodeAt(this.state.pos + 3);

      if (ch2 === 58 && ch3 === 58) {
        return 4;
      }

      if (this.input.slice(this.state.pos + 2, 14) === "flow-include") {
        return 14;
      }

      if (ch2 === 58 && ch3 !== 58 && 2) {
        return 2;
      }

      return false;
    };

    _proto.hasFlowCommentCompletion = function hasFlowCommentCompletion() {
      var end = this.input.indexOf("*/", this.state.pos);

      if (end === -1) {
        this.raise(this.state.pos, "Unterminated comment");
      }
    };

    _inheritsLoose(_class, _superClass);

    return _class;
  }(superClass);
});

var entities = {
  quot: "\"",
  amp: "&",
  apos: "'",
  lt: "<",
  gt: ">",
  nbsp: "\xA0",
  iexcl: "\xA1",
  cent: "\xA2",
  pound: "\xA3",
  curren: "\xA4",
  yen: "\xA5",
  brvbar: "\xA6",
  sect: "\xA7",
  uml: "\xA8",
  copy: "\xA9",
  ordf: "\xAA",
  laquo: "\xAB",
  not: "\xAC",
  shy: "\xAD",
  reg: "\xAE",
  macr: "\xAF",
  deg: "\xB0",
  plusmn: "\xB1",
  sup2: "\xB2",
  sup3: "\xB3",
  acute: "\xB4",
  micro: "\xB5",
  para: "\xB6",
  middot: "\xB7",
  cedil: "\xB8",
  sup1: "\xB9",
  ordm: "\xBA",
  raquo: "\xBB",
  frac14: "\xBC",
  frac12: "\xBD",
  frac34: "\xBE",
  iquest: "\xBF",
  Agrave: "\xC0",
  Aacute: "\xC1",
  Acirc: "\xC2",
  Atilde: "\xC3",
  Auml: "\xC4",
  Aring: "\xC5",
  AElig: "\xC6",
  Ccedil: "\xC7",
  Egrave: "\xC8",
  Eacute: "\xC9",
  Ecirc: "\xCA",
  Euml: "\xCB",
  Igrave: "\xCC",
  Iacute: "\xCD",
  Icirc: "\xCE",
  Iuml: "\xCF",
  ETH: "\xD0",
  Ntilde: "\xD1",
  Ograve: "\xD2",
  Oacute: "\xD3",
  Ocirc: "\xD4",
  Otilde: "\xD5",
  Ouml: "\xD6",
  times: "\xD7",
  Oslash: "\xD8",
  Ugrave: "\xD9",
  Uacute: "\xDA",
  Ucirc: "\xDB",
  Uuml: "\xDC",
  Yacute: "\xDD",
  THORN: "\xDE",
  szlig: "\xDF",
  agrave: "\xE0",
  aacute: "\xE1",
  acirc: "\xE2",
  atilde: "\xE3",
  auml: "\xE4",
  aring: "\xE5",
  aelig: "\xE6",
  ccedil: "\xE7",
  egrave: "\xE8",
  eacute: "\xE9",
  ecirc: "\xEA",
  euml: "\xEB",
  igrave: "\xEC",
  iacute: "\xED",
  icirc: "\xEE",
  iuml: "\xEF",
  eth: "\xF0",
  ntilde: "\xF1",
  ograve: "\xF2",
  oacute: "\xF3",
  ocirc: "\xF4",
  otilde: "\xF5",
  ouml: "\xF6",
  divide: "\xF7",
  oslash: "\xF8",
  ugrave: "\xF9",
  uacute: "\xFA",
  ucirc: "\xFB",
  uuml: "\xFC",
  yacute: "\xFD",
  thorn: "\xFE",
  yuml: "\xFF",
  OElig: "\u0152",
  oelig: "\u0153",
  Scaron: "\u0160",
  scaron: "\u0161",
  Yuml: "\u0178",
  fnof: "\u0192",
  circ: "\u02C6",
  tilde: "\u02DC",
  Alpha: "\u0391",
  Beta: "\u0392",
  Gamma: "\u0393",
  Delta: "\u0394",
  Epsilon: "\u0395",
  Zeta: "\u0396",
  Eta: "\u0397",
  Theta: "\u0398",
  Iota: "\u0399",
  Kappa: "\u039A",
  Lambda: "\u039B",
  Mu: "\u039C",
  Nu: "\u039D",
  Xi: "\u039E",
  Omicron: "\u039F",
  Pi: "\u03A0",
  Rho: "\u03A1",
  Sigma: "\u03A3",
  Tau: "\u03A4",
  Upsilon: "\u03A5",
  Phi: "\u03A6",
  Chi: "\u03A7",
  Psi: "\u03A8",
  Omega: "\u03A9",
  alpha: "\u03B1",
  beta: "\u03B2",
  gamma: "\u03B3",
  delta: "\u03B4",
  epsilon: "\u03B5",
  zeta: "\u03B6",
  eta: "\u03B7",
  theta: "\u03B8",
  iota: "\u03B9",
  kappa: "\u03BA",
  lambda: "\u03BB",
  mu: "\u03BC",
  nu: "\u03BD",
  xi: "\u03BE",
  omicron: "\u03BF",
  pi: "\u03C0",
  rho: "\u03C1",
  sigmaf: "\u03C2",
  sigma: "\u03C3",
  tau: "\u03C4",
  upsilon: "\u03C5",
  phi: "\u03C6",
  chi: "\u03C7",
  psi: "\u03C8",
  omega: "\u03C9",
  thetasym: "\u03D1",
  upsih: "\u03D2",
  piv: "\u03D6",
  ensp: "\u2002",
  emsp: "\u2003",
  thinsp: "\u2009",
  zwnj: "\u200C",
  zwj: "\u200D",
  lrm: "\u200E",
  rlm: "\u200F",
  ndash: "\u2013",
  mdash: "\u2014",
  lsquo: "\u2018",
  rsquo: "\u2019",
  sbquo: "\u201A",
  ldquo: "\u201C",
  rdquo: "\u201D",
  bdquo: "\u201E",
  dagger: "\u2020",
  Dagger: "\u2021",
  bull: "\u2022",
  hellip: "\u2026",
  permil: "\u2030",
  prime: "\u2032",
  Prime: "\u2033",
  lsaquo: "\u2039",
  rsaquo: "\u203A",
  oline: "\u203E",
  frasl: "\u2044",
  euro: "\u20AC",
  image: "\u2111",
  weierp: "\u2118",
  real: "\u211C",
  trade: "\u2122",
  alefsym: "\u2135",
  larr: "\u2190",
  uarr: "\u2191",
  rarr: "\u2192",
  darr: "\u2193",
  harr: "\u2194",
  crarr: "\u21B5",
  lArr: "\u21D0",
  uArr: "\u21D1",
  rArr: "\u21D2",
  dArr: "\u21D3",
  hArr: "\u21D4",
  forall: "\u2200",
  part: "\u2202",
  exist: "\u2203",
  empty: "\u2205",
  nabla: "\u2207",
  isin: "\u2208",
  notin: "\u2209",
  ni: "\u220B",
  prod: "\u220F",
  sum: "\u2211",
  minus: "\u2212",
  lowast: "\u2217",
  radic: "\u221A",
  prop: "\u221D",
  infin: "\u221E",
  ang: "\u2220",
  and: "\u2227",
  or: "\u2228",
  cap: "\u2229",
  cup: "\u222A",
  int: "\u222B",
  there4: "\u2234",
  sim: "\u223C",
  cong: "\u2245",
  asymp: "\u2248",
  ne: "\u2260",
  equiv: "\u2261",
  le: "\u2264",
  ge: "\u2265",
  sub: "\u2282",
  sup: "\u2283",
  nsub: "\u2284",
  sube: "\u2286",
  supe: "\u2287",
  oplus: "\u2295",
  otimes: "\u2297",
  perp: "\u22A5",
  sdot: "\u22C5",
  lceil: "\u2308",
  rceil: "\u2309",
  lfloor: "\u230A",
  rfloor: "\u230B",
  lang: "\u2329",
  rang: "\u232A",
  loz: "\u25CA",
  spades: "\u2660",
  clubs: "\u2663",
  hearts: "\u2665",
  diams: "\u2666"
};

var HEX_NUMBER = /^[\da-fA-F]+$/;
var DECIMAL_NUMBER = /^\d+$/;
types$1.j_oTag = new TokContext("<tag", false);
types$1.j_cTag = new TokContext("</tag", false);
types$1.j_expr = new TokContext("<tag>...</tag>", true, true);
types.jsxName = new TokenType("jsxName");
types.jsxText = new TokenType("jsxText", {
  beforeExpr: true
});
types.jsxTagStart = new TokenType("jsxTagStart", {
  startsExpr: true
});
types.jsxTagEnd = new TokenType("jsxTagEnd");

types.jsxTagStart.updateContext = function () {
  this.state.context.push(types$1.j_expr);
  this.state.context.push(types$1.j_oTag);
  this.state.exprAllowed = false;
};

types.jsxTagEnd.updateContext = function (prevType) {
  var out = this.state.context.pop();

  if (out === types$1.j_oTag && prevType === types.slash || out === types$1.j_cTag) {
    this.state.context.pop();
    this.state.exprAllowed = this.curContext() === types$1.j_expr;
  } else {
    this.state.exprAllowed = true;
  }
};

function isFragment(object) {
  return object ? object.type === "JSXOpeningFragment" || object.type === "JSXClosingFragment" : false;
}

function getQualifiedJSXName(object) {
  if (object.type === "JSXIdentifier") {
    return object.name;
  }

  if (object.type === "JSXNamespacedName") {
    return object.namespace.name + ":" + object.name.name;
  }

  if (object.type === "JSXMemberExpression") {
    return getQualifiedJSXName(object.object) + "." + getQualifiedJSXName(object.property);
  }

  throw new Error("Node had unexpected type: " + object.type);
}

var jsxPlugin = (function (superClass) {
  return function (_superClass) {
    function _class() {
      return _superClass.apply(this, arguments) || this;
    }

    var _proto = _class.prototype;

    _proto.jsxReadToken = function jsxReadToken() {
      var out = "";
      var chunkStart = this.state.pos;

      for (;;) {
        if (this.state.pos >= this.input.length) {
          this.raise(this.state.start, "Unterminated JSX contents");
        }

        var ch = this.input.charCodeAt(this.state.pos);

        switch (ch) {
          case 60:
          case 123:
            if (this.state.pos === this.state.start) {
              if (ch === 60 && this.state.exprAllowed) {
                ++this.state.pos;
                return this.finishToken(types.jsxTagStart);
              }

              return this.getTokenFromCode(ch);
            }

            out += this.input.slice(chunkStart, this.state.pos);
            return this.finishToken(types.jsxText, out);

          case 38:
            out += this.input.slice(chunkStart, this.state.pos);
            out += this.jsxReadEntity();
            chunkStart = this.state.pos;
            break;

          default:
            if (isNewLine(ch)) {
              out += this.input.slice(chunkStart, this.state.pos);
              out += this.jsxReadNewLine(true);
              chunkStart = this.state.pos;
            } else {
              ++this.state.pos;
            }

        }
      }
    };

    _proto.jsxReadNewLine = function jsxReadNewLine(normalizeCRLF) {
      var ch = this.input.charCodeAt(this.state.pos);
      var out;
      ++this.state.pos;

      if (ch === 13 && this.input.charCodeAt(this.state.pos) === 10) {
        ++this.state.pos;
        out = normalizeCRLF ? "\n" : "\r\n";
      } else {
        out = String.fromCharCode(ch);
      }

      ++this.state.curLine;
      this.state.lineStart = this.state.pos;
      return out;
    };

    _proto.jsxReadString = function jsxReadString(quote) {
      var out = "";
      var chunkStart = ++this.state.pos;

      for (;;) {
        if (this.state.pos >= this.input.length) {
          this.raise(this.state.start, "Unterminated string constant");
        }

        var ch = this.input.charCodeAt(this.state.pos);
        if (ch === quote) break;

        if (ch === 38) {
          out += this.input.slice(chunkStart, this.state.pos);
          out += this.jsxReadEntity();
          chunkStart = this.state.pos;
        } else if (isNewLine(ch)) {
          out += this.input.slice(chunkStart, this.state.pos);
          out += this.jsxReadNewLine(false);
          chunkStart = this.state.pos;
        } else {
          ++this.state.pos;
        }
      }

      out += this.input.slice(chunkStart, this.state.pos++);
      return this.finishToken(types.string, out);
    };

    _proto.jsxReadEntity = function jsxReadEntity() {
      var str = "";
      var count = 0;
      var entity;
      var ch = this.input[this.state.pos];
      var startPos = ++this.state.pos;

      while (this.state.pos < this.input.length && count++ < 10) {
        ch = this.input[this.state.pos++];

        if (ch === ";") {
          if (str[0] === "#") {
            if (str[1] === "x") {
              str = str.substr(2);

              if (HEX_NUMBER.test(str)) {
                entity = String.fromCodePoint(parseInt(str, 16));
              }
            } else {
              str = str.substr(1);

              if (DECIMAL_NUMBER.test(str)) {
                entity = String.fromCodePoint(parseInt(str, 10));
              }
            }
          } else {
            entity = entities[str];
          }

          break;
        }

        str += ch;
      }

      if (!entity) {
        this.state.pos = startPos;
        return "&";
      }

      return entity;
    };

    _proto.jsxReadWord = function jsxReadWord() {
      var ch;
      var start = this.state.pos;

      do {
        ch = this.input.charCodeAt(++this.state.pos);
      } while (isIdentifierChar(ch) || ch === 45);

      return this.finishToken(types.jsxName, this.input.slice(start, this.state.pos));
    };

    _proto.jsxParseIdentifier = function jsxParseIdentifier() {
      var node = this.startNode();

      if (this.match(types.jsxName)) {
        node.name = this.state.value;
      } else if (this.state.type.keyword) {
        node.name = this.state.type.keyword;
      } else {
        this.unexpected();
      }

      this.next();
      return this.finishNode(node, "JSXIdentifier");
    };

    _proto.jsxParseNamespacedName = function jsxParseNamespacedName() {
      var startPos = this.state.start;
      var startLoc = this.state.startLoc;
      var name = this.jsxParseIdentifier();
      if (!this.eat(types.colon)) return name;
      var node = this.startNodeAt(startPos, startLoc);
      node.namespace = name;
      node.name = this.jsxParseIdentifier();
      return this.finishNode(node, "JSXNamespacedName");
    };

    _proto.jsxParseElementName = function jsxParseElementName() {
      var startPos = this.state.start;
      var startLoc = this.state.startLoc;
      var node = this.jsxParseNamespacedName();

      while (this.eat(types.dot)) {
        var newNode = this.startNodeAt(startPos, startLoc);
        newNode.object = node;
        newNode.property = this.jsxParseIdentifier();
        node = this.finishNode(newNode, "JSXMemberExpression");
      }

      return node;
    };

    _proto.jsxParseAttributeValue = function jsxParseAttributeValue() {
      var node;

      switch (this.state.type) {
        case types.braceL:
          node = this.jsxParseExpressionContainer();

          if (node.expression.type === "JSXEmptyExpression") {
            throw this.raise(node.start, "JSX attributes must only be assigned a non-empty expression");
          } else {
            return node;
          }

        case types.jsxTagStart:
        case types.string:
          return this.parseExprAtom();

        default:
          throw this.raise(this.state.start, "JSX value should be either an expression or a quoted JSX text");
      }
    };

    _proto.jsxParseEmptyExpression = function jsxParseEmptyExpression() {
      var node = this.startNodeAt(this.state.lastTokEnd, this.state.lastTokEndLoc);
      return this.finishNodeAt(node, "JSXEmptyExpression", this.state.start, this.state.startLoc);
    };

    _proto.jsxParseSpreadChild = function jsxParseSpreadChild() {
      var node = this.startNode();
      this.expect(types.braceL);
      this.expect(types.ellipsis);
      node.expression = this.parseExpression();
      this.expect(types.braceR);
      return this.finishNode(node, "JSXSpreadChild");
    };

    _proto.jsxParseExpressionContainer = function jsxParseExpressionContainer() {
      var node = this.startNode();
      this.next();

      if (this.match(types.braceR)) {
        node.expression = this.jsxParseEmptyExpression();
      } else {
        node.expression = this.parseExpression();
      }

      this.expect(types.braceR);
      return this.finishNode(node, "JSXExpressionContainer");
    };

    _proto.jsxParseAttribute = function jsxParseAttribute() {
      var node = this.startNode();

      if (this.eat(types.braceL)) {
        this.expect(types.ellipsis);
        node.argument = this.parseMaybeAssign();
        this.expect(types.braceR);
        return this.finishNode(node, "JSXSpreadAttribute");
      }

      node.name = this.jsxParseNamespacedName();
      node.value = this.eat(types.eq) ? this.jsxParseAttributeValue() : null;
      return this.finishNode(node, "JSXAttribute");
    };

    _proto.jsxParseOpeningElementAt = function jsxParseOpeningElementAt(startPos, startLoc) {
      var node = this.startNodeAt(startPos, startLoc);

      if (this.match(types.jsxTagEnd)) {
        this.expect(types.jsxTagEnd);
        return this.finishNode(node, "JSXOpeningFragment");
      }

      node.attributes = [];
      node.name = this.jsxParseElementName();

      while (!this.match(types.slash) && !this.match(types.jsxTagEnd)) {
        node.attributes.push(this.jsxParseAttribute());
      }

      node.selfClosing = this.eat(types.slash);
      this.expect(types.jsxTagEnd);
      return this.finishNode(node, "JSXOpeningElement");
    };

    _proto.jsxParseClosingElementAt = function jsxParseClosingElementAt(startPos, startLoc) {
      var node = this.startNodeAt(startPos, startLoc);

      if (this.match(types.jsxTagEnd)) {
        this.expect(types.jsxTagEnd);
        return this.finishNode(node, "JSXClosingFragment");
      }

      node.name = this.jsxParseElementName();
      this.expect(types.jsxTagEnd);
      return this.finishNode(node, "JSXClosingElement");
    };

    _proto.jsxParseElementAt = function jsxParseElementAt(startPos, startLoc) {
      var node = this.startNodeAt(startPos, startLoc);
      var children = [];
      var openingElement = this.jsxParseOpeningElementAt(startPos, startLoc);
      var closingElement = null;

      if (!openingElement.selfClosing) {
        contents: for (;;) {
          switch (this.state.type) {
            case types.jsxTagStart:
              startPos = this.state.start;
              startLoc = this.state.startLoc;
              this.next();

              if (this.eat(types.slash)) {
                closingElement = this.jsxParseClosingElementAt(startPos, startLoc);
                break contents;
              }

              children.push(this.jsxParseElementAt(startPos, startLoc));
              break;

            case types.jsxText:
              children.push(this.parseExprAtom());
              break;

            case types.braceL:
              if (this.lookahead().type === types.ellipsis) {
                children.push(this.jsxParseSpreadChild());
              } else {
                children.push(this.jsxParseExpressionContainer());
              }

              break;

            default:
              throw this.unexpected();
          }
        }

        if (isFragment(openingElement) && !isFragment(closingElement)) {
          this.raise(closingElement.start, "Expected corresponding JSX closing tag for <>");
        } else if (!isFragment(openingElement) && isFragment(closingElement)) {
          this.raise(closingElement.start, "Expected corresponding JSX closing tag for <" + getQualifiedJSXName(openingElement.name) + ">");
        } else if (!isFragment(openingElement) && !isFragment(closingElement)) {
          if (getQualifiedJSXName(closingElement.name) !== getQualifiedJSXName(openingElement.name)) {
            this.raise(closingElement.start, "Expected corresponding JSX closing tag for <" + getQualifiedJSXName(openingElement.name) + ">");
          }
        }
      }

      if (isFragment(openingElement)) {
        node.openingFragment = openingElement;
        node.closingFragment = closingElement;
      } else {
        node.openingElement = openingElement;
        node.closingElement = closingElement;
      }

      node.children = children;

      if (this.match(types.relational) && this.state.value === "<") {
        this.raise(this.state.start, "Adjacent JSX elements must be wrapped in an enclosing tag. " + "Did you want a JSX fragment <>...</>?");
      }

      return isFragment(openingElement) ? this.finishNode(node, "JSXFragment") : this.finishNode(node, "JSXElement");
    };

    _proto.jsxParseElement = function jsxParseElement() {
      var startPos = this.state.start;
      var startLoc = this.state.startLoc;
      this.next();
      return this.jsxParseElementAt(startPos, startLoc);
    };

    _proto.parseExprAtom = function parseExprAtom(refShortHandDefaultPos) {
      if (this.match(types.jsxText)) {
        return this.parseLiteral(this.state.value, "JSXText");
      } else if (this.match(types.jsxTagStart)) {
        return this.jsxParseElement();
      } else {
        return _superClass.prototype.parseExprAtom.call(this, refShortHandDefaultPos);
      }
    };

    _proto.readToken = function readToken(code) {
      if (this.state.inPropertyName) return _superClass.prototype.readToken.call(this, code);
      var context = this.curContext();

      if (context === types$1.j_expr) {
        return this.jsxReadToken();
      }

      if (context === types$1.j_oTag || context === types$1.j_cTag) {
        if (isIdentifierStart(code)) {
          return this.jsxReadWord();
        }

        if (code === 62) {
          ++this.state.pos;
          return this.finishToken(types.jsxTagEnd);
        }

        if ((code === 34 || code === 39) && context === types$1.j_oTag) {
          return this.jsxReadString(code);
        }
      }

      if (code === 60 && this.state.exprAllowed) {
        ++this.state.pos;
        return this.finishToken(types.jsxTagStart);
      }

      return _superClass.prototype.readToken.call(this, code);
    };

    _proto.updateContext = function updateContext(prevType) {
      if (this.match(types.braceL)) {
        var curContext = this.curContext();

        if (curContext === types$1.j_oTag) {
          this.state.context.push(types$1.braceExpression);
        } else if (curContext === types$1.j_expr) {
          this.state.context.push(types$1.templateQuasi);
        } else {
          _superClass.prototype.updateContext.call(this, prevType);
        }

        this.state.exprAllowed = true;
      } else if (this.match(types.slash) && prevType === types.jsxTagStart) {
        this.state.context.length -= 2;
        this.state.context.push(types$1.j_cTag);
        this.state.exprAllowed = false;
      } else {
        return _superClass.prototype.updateContext.call(this, prevType);
      }
    };

    _inheritsLoose(_class, _superClass);

    return _class;
  }(superClass);
});

function nonNull(x) {
  if (x == null) {
    throw new Error("Unexpected " + x + " value.");
  }

  return x;
}

function assert(x) {
  if (!x) {
    throw new Error("Assert fail");
  }
}

function keywordTypeFromName(value) {
  switch (value) {
    case "any":
      return "TSAnyKeyword";

    case "boolean":
      return "TSBooleanKeyword";

    case "never":
      return "TSNeverKeyword";

    case "number":
      return "TSNumberKeyword";

    case "object":
      return "TSObjectKeyword";

    case "string":
      return "TSStringKeyword";

    case "symbol":
      return "TSSymbolKeyword";

    case "undefined":
      return "TSUndefinedKeyword";

    default:
      return undefined;
  }
}

var typescriptPlugin = (function (superClass) {
  return function (_superClass) {
    function _class() {
      return _superClass.apply(this, arguments) || this;
    }

    var _proto = _class.prototype;

    _proto.tsIsIdentifier = function tsIsIdentifier() {
      return this.match(types.name);
    };

    _proto.tsNextTokenCanFollowModifier = function tsNextTokenCanFollowModifier() {
      this.next();
      return !this.hasPrecedingLineBreak() && !this.match(types.parenL) && !this.match(types.colon) && !this.match(types.eq) && !this.match(types.question);
    };

    _proto.tsParseModifier = function tsParseModifier(allowedModifiers) {
      if (!this.match(types.name)) {
        return undefined;
      }

      var modifier = this.state.value;

      if (allowedModifiers.indexOf(modifier) !== -1 && this.tsTryParse(this.tsNextTokenCanFollowModifier.bind(this))) {
        return modifier;
      }

      return undefined;
    };

    _proto.tsIsListTerminator = function tsIsListTerminator(kind) {
      switch (kind) {
        case "EnumMembers":
        case "TypeMembers":
          return this.match(types.braceR);

        case "HeritageClauseElement":
          return this.match(types.braceL);

        case "TupleElementTypes":
          return this.match(types.bracketR);

        case "TypeParametersOrArguments":
          return this.isRelational(">");
      }

      throw new Error("Unreachable");
    };

    _proto.tsParseList = function tsParseList(kind, parseElement) {
      var result = [];

      while (!this.tsIsListTerminator(kind)) {
        result.push(parseElement());
      }

      return result;
    };

    _proto.tsParseDelimitedList = function tsParseDelimitedList(kind, parseElement) {
      return nonNull(this.tsParseDelimitedListWorker(kind, parseElement, true));
    };

    _proto.tsTryParseDelimitedList = function tsTryParseDelimitedList(kind, parseElement) {
      return this.tsParseDelimitedListWorker(kind, parseElement, false);
    };

    _proto.tsParseDelimitedListWorker = function tsParseDelimitedListWorker(kind, parseElement, expectSuccess) {
      var result = [];

      while (true) {
        if (this.tsIsListTerminator(kind)) {
          break;
        }

        var element = parseElement();

        if (element == null) {
          return undefined;
        }

        result.push(element);

        if (this.eat(types.comma)) {
          continue;
        }

        if (this.tsIsListTerminator(kind)) {
          break;
        }

        if (expectSuccess) {
          this.expect(types.comma);
        }

        return undefined;
      }

      return result;
    };

    _proto.tsParseBracketedList = function tsParseBracketedList(kind, parseElement, bracket, skipFirstToken) {
      if (!skipFirstToken) {
        if (bracket) {
          this.expect(types.bracketL);
        } else {
          this.expectRelational("<");
        }
      }

      var result = this.tsParseDelimitedList(kind, parseElement);

      if (bracket) {
        this.expect(types.bracketR);
      } else {
        this.expectRelational(">");
      }

      return result;
    };

    _proto.tsParseEntityName = function tsParseEntityName(allowReservedWords) {
      var entity = this.parseIdentifier();

      while (this.eat(types.dot)) {
        var node = this.startNodeAtNode(entity);
        node.left = entity;
        node.right = this.parseIdentifier(allowReservedWords);
        entity = this.finishNode(node, "TSQualifiedName");
      }

      return entity;
    };

    _proto.tsParseTypeReference = function tsParseTypeReference() {
      var node = this.startNode();
      node.typeName = this.tsParseEntityName(false);

      if (!this.hasPrecedingLineBreak() && this.isRelational("<")) {
        node.typeParameters = this.tsParseTypeArguments();
      }

      return this.finishNode(node, "TSTypeReference");
    };

    _proto.tsParseThisTypePredicate = function tsParseThisTypePredicate(lhs) {
      this.next();
      var node = this.startNode();
      node.parameterName = lhs;
      node.typeAnnotation = this.tsParseTypeAnnotation(false);
      return this.finishNode(node, "TSTypePredicate");
    };

    _proto.tsParseThisTypeNode = function tsParseThisTypeNode() {
      var node = this.startNode();
      this.next();
      return this.finishNode(node, "TSThisType");
    };

    _proto.tsParseTypeQuery = function tsParseTypeQuery() {
      var node = this.startNode();
      this.expect(types._typeof);
      node.exprName = this.tsParseEntityName(true);
      return this.finishNode(node, "TSTypeQuery");
    };

    _proto.tsParseTypeParameter = function tsParseTypeParameter() {
      var node = this.startNode();
      node.name = this.parseIdentifierName(node.start);
      node.constraint = this.tsEatThenParseType(types._extends);
      node.default = this.tsEatThenParseType(types.eq);
      return this.finishNode(node, "TSTypeParameter");
    };

    _proto.tsTryParseTypeParameters = function tsTryParseTypeParameters() {
      if (this.isRelational("<")) {
        return this.tsParseTypeParameters();
      }
    };

    _proto.tsParseTypeParameters = function tsParseTypeParameters() {
      var node = this.startNode();

      if (this.isRelational("<") || this.match(types.jsxTagStart)) {
        this.next();
      } else {
        this.unexpected();
      }

      node.params = this.tsParseBracketedList("TypeParametersOrArguments", this.tsParseTypeParameter.bind(this), false, true);
      return this.finishNode(node, "TSTypeParameterDeclaration");
    };

    _proto.tsFillSignature = function tsFillSignature(returnToken, signature) {
      var returnTokenRequired = returnToken === types.arrow;
      signature.typeParameters = this.tsTryParseTypeParameters();
      this.expect(types.parenL);
      signature.parameters = this.tsParseBindingListForSignature();

      if (returnTokenRequired) {
        signature.typeAnnotation = this.tsParseTypeOrTypePredicateAnnotation(returnToken);
      } else if (this.match(returnToken)) {
        signature.typeAnnotation = this.tsParseTypeOrTypePredicateAnnotation(returnToken);
      }
    };

    _proto.tsParseBindingListForSignature = function tsParseBindingListForSignature() {
      var _this = this;

      return this.parseBindingList(types.parenR).map(function (pattern) {
        if (pattern.type !== "Identifier" && pattern.type !== "RestElement") {
          throw _this.unexpected(pattern.start, "Name in a signature must be an Identifier.");
        }

        return pattern;
      });
    };

    _proto.tsParseTypeMemberSemicolon = function tsParseTypeMemberSemicolon() {
      if (!this.eat(types.comma)) {
        this.semicolon();
      }
    };

    _proto.tsParseSignatureMember = function tsParseSignatureMember(kind) {
      var node = this.startNode();

      if (kind === "TSConstructSignatureDeclaration") {
        this.expect(types._new);
      }

      this.tsFillSignature(types.colon, node);
      this.tsParseTypeMemberSemicolon();
      return this.finishNode(node, kind);
    };

    _proto.tsIsUnambiguouslyIndexSignature = function tsIsUnambiguouslyIndexSignature() {
      this.next();
      return this.eat(types.name) && this.match(types.colon);
    };

    _proto.tsTryParseIndexSignature = function tsTryParseIndexSignature(node) {
      if (!(this.match(types.bracketL) && this.tsLookAhead(this.tsIsUnambiguouslyIndexSignature.bind(this)))) {
        return undefined;
      }

      this.expect(types.bracketL);
      var id = this.parseIdentifier();
      this.expect(types.colon);
      id.typeAnnotation = this.tsParseTypeAnnotation(false);
      this.expect(types.bracketR);
      node.parameters = [id];
      var type = this.tsTryParseTypeAnnotation();
      if (type) node.typeAnnotation = type;
      this.tsParseTypeMemberSemicolon();
      return this.finishNode(node, "TSIndexSignature");
    };

    _proto.tsParsePropertyOrMethodSignature = function tsParsePropertyOrMethodSignature(node, readonly) {
      this.parsePropertyName(node);
      if (this.eat(types.question)) node.optional = true;
      var nodeAny = node;

      if (!readonly && (this.match(types.parenL) || this.isRelational("<"))) {
        var method = nodeAny;
        this.tsFillSignature(types.colon, method);
        this.tsParseTypeMemberSemicolon();
        return this.finishNode(method, "TSMethodSignature");
      } else {
        var property = nodeAny;
        if (readonly) property.readonly = true;
        var type = this.tsTryParseTypeAnnotation();
        if (type) property.typeAnnotation = type;
        this.tsParseTypeMemberSemicolon();
        return this.finishNode(property, "TSPropertySignature");
      }
    };

    _proto.tsParseTypeMember = function tsParseTypeMember() {
      if (this.match(types.parenL) || this.isRelational("<")) {
        return this.tsParseSignatureMember("TSCallSignatureDeclaration");
      }

      if (this.match(types._new) && this.tsLookAhead(this.tsIsStartOfConstructSignature.bind(this))) {
        return this.tsParseSignatureMember("TSConstructSignatureDeclaration");
      }

      var node = this.startNode();
      var readonly = !!this.tsParseModifier(["readonly"]);
      var idx = this.tsTryParseIndexSignature(node);

      if (idx) {
        if (readonly) node.readonly = true;
        return idx;
      }

      return this.tsParsePropertyOrMethodSignature(node, readonly);
    };

    _proto.tsIsStartOfConstructSignature = function tsIsStartOfConstructSignature() {
      this.next();
      return this.match(types.parenL) || this.isRelational("<");
    };

    _proto.tsParseTypeLiteral = function tsParseTypeLiteral() {
      var node = this.startNode();
      node.members = this.tsParseObjectTypeMembers();
      return this.finishNode(node, "TSTypeLiteral");
    };

    _proto.tsParseObjectTypeMembers = function tsParseObjectTypeMembers() {
      this.expect(types.braceL);
      var members = this.tsParseList("TypeMembers", this.tsParseTypeMember.bind(this));
      this.expect(types.braceR);
      return members;
    };

    _proto.tsIsStartOfMappedType = function tsIsStartOfMappedType() {
      this.next();

      if (this.eat(types.plusMin)) {
        return this.isContextual("readonly");
      }

      if (this.isContextual("readonly")) {
        this.next();
      }

      if (!this.match(types.bracketL)) {
        return false;
      }

      this.next();

      if (!this.tsIsIdentifier()) {
        return false;
      }

      this.next();
      return this.match(types._in);
    };

    _proto.tsParseMappedTypeParameter = function tsParseMappedTypeParameter() {
      var node = this.startNode();
      node.name = this.parseIdentifierName(node.start);
      node.constraint = this.tsExpectThenParseType(types._in);
      return this.finishNode(node, "TSTypeParameter");
    };

    _proto.tsParseMappedType = function tsParseMappedType() {
      var node = this.startNode();
      this.expect(types.braceL);

      if (this.match(types.plusMin)) {
        node.readonly = this.state.value;
        this.next();
        this.expectContextual("readonly");
      } else if (this.eatContextual("readonly")) {
        node.readonly = true;
      }

      this.expect(types.bracketL);
      node.typeParameter = this.tsParseMappedTypeParameter();
      this.expect(types.bracketR);

      if (this.match(types.plusMin)) {
        node.optional = this.state.value;
        this.next();
        this.expect(types.question);
      } else if (this.eat(types.question)) {
        node.optional = true;
      }

      node.typeAnnotation = this.tsTryParseType();
      this.semicolon();
      this.expect(types.braceR);
      return this.finishNode(node, "TSMappedType");
    };

    _proto.tsParseTupleType = function tsParseTupleType() {
      var node = this.startNode();
      node.elementTypes = this.tsParseBracketedList("TupleElementTypes", this.tsParseType.bind(this), true, false);
      return this.finishNode(node, "TSTupleType");
    };

    _proto.tsParseParenthesizedType = function tsParseParenthesizedType() {
      var node = this.startNode();
      this.expect(types.parenL);
      node.typeAnnotation = this.tsParseType();
      this.expect(types.parenR);
      return this.finishNode(node, "TSParenthesizedType");
    };

    _proto.tsParseFunctionOrConstructorType = function tsParseFunctionOrConstructorType(type) {
      var node = this.startNode();

      if (type === "TSConstructorType") {
        this.expect(types._new);
      }

      this.tsFillSignature(types.arrow, node);
      return this.finishNode(node, type);
    };

    _proto.tsParseLiteralTypeNode = function tsParseLiteralTypeNode() {
      var _this2 = this;

      var node = this.startNode();

      node.literal = function () {
        switch (_this2.state.type) {
          case types.num:
            return _this2.parseLiteral(_this2.state.value, "NumericLiteral");

          case types.string:
            return _this2.parseLiteral(_this2.state.value, "StringLiteral");

          case types._true:
          case types._false:
            return _this2.parseBooleanLiteral();

          default:
            throw _this2.unexpected();
        }
      }();

      return this.finishNode(node, "TSLiteralType");
    };

    _proto.tsParseNonArrayType = function tsParseNonArrayType() {
      switch (this.state.type) {
        case types.name:
        case types._void:
        case types._null:
          {
            var type = this.match(types._void) ? "TSVoidKeyword" : this.match(types._null) ? "TSNullKeyword" : keywordTypeFromName(this.state.value);

            if (type !== undefined && this.lookahead().type !== types.dot) {
              var node = this.startNode();
              this.next();
              return this.finishNode(node, type);
            }

            return this.tsParseTypeReference();
          }

        case types.string:
        case types.num:
        case types._true:
        case types._false:
          return this.tsParseLiteralTypeNode();

        case types.plusMin:
          if (this.state.value === "-") {
            var _node = this.startNode();

            this.next();

            if (!this.match(types.num)) {
              throw this.unexpected();
            }

            _node.literal = this.parseLiteral(-this.state.value, "NumericLiteral", _node.start, _node.loc.start);
            return this.finishNode(_node, "TSLiteralType");
          }

          break;

        case types._this:
          {
            var thisKeyword = this.tsParseThisTypeNode();

            if (this.isContextual("is") && !this.hasPrecedingLineBreak()) {
              return this.tsParseThisTypePredicate(thisKeyword);
            } else {
              return thisKeyword;
            }
          }

        case types._typeof:
          return this.tsParseTypeQuery();

        case types.braceL:
          return this.tsLookAhead(this.tsIsStartOfMappedType.bind(this)) ? this.tsParseMappedType() : this.tsParseTypeLiteral();

        case types.bracketL:
          return this.tsParseTupleType();

        case types.parenL:
          return this.tsParseParenthesizedType();
      }

      throw this.unexpected();
    };

    _proto.tsParseArrayTypeOrHigher = function tsParseArrayTypeOrHigher() {
      var type = this.tsParseNonArrayType();

      while (!this.hasPrecedingLineBreak() && this.eat(types.bracketL)) {
        if (this.match(types.bracketR)) {
          var node = this.startNodeAtNode(type);
          node.elementType = type;
          this.expect(types.bracketR);
          type = this.finishNode(node, "TSArrayType");
        } else {
          var _node2 = this.startNodeAtNode(type);

          _node2.objectType = type;
          _node2.indexType = this.tsParseType();
          this.expect(types.bracketR);
          type = this.finishNode(_node2, "TSIndexedAccessType");
        }
      }

      return type;
    };

    _proto.tsParseTypeOperator = function tsParseTypeOperator(operator) {
      var node = this.startNode();
      this.expectContextual(operator);
      node.operator = operator;
      node.typeAnnotation = this.tsParseTypeOperatorOrHigher();
      return this.finishNode(node, "TSTypeOperator");
    };

    _proto.tsParseInferType = function tsParseInferType() {
      var node = this.startNode();
      this.expectContextual("infer");
      var typeParameter = this.startNode();
      typeParameter.name = this.parseIdentifierName(typeParameter.start);
      node.typeParameter = this.finishNode(typeParameter, "TypeParameter");
      return this.finishNode(node, "TSInferType");
    };

    _proto.tsParseTypeOperatorOrHigher = function tsParseTypeOperatorOrHigher() {
      var _this3 = this;

      var operator = ["keyof", "unique"].find(function (kw) {
        return _this3.isContextual(kw);
      });
      return operator ? this.tsParseTypeOperator(operator) : this.isContextual("infer") ? this.tsParseInferType() : this.tsParseArrayTypeOrHigher();
    };

    _proto.tsParseUnionOrIntersectionType = function tsParseUnionOrIntersectionType(kind, parseConstituentType, operator) {
      this.eat(operator);
      var type = parseConstituentType();

      if (this.match(operator)) {
        var types$$1 = [type];

        while (this.eat(operator)) {
          types$$1.push(parseConstituentType());
        }

        var node = this.startNodeAtNode(type);
        node.types = types$$1;
        type = this.finishNode(node, kind);
      }

      return type;
    };

    _proto.tsParseIntersectionTypeOrHigher = function tsParseIntersectionTypeOrHigher() {
      return this.tsParseUnionOrIntersectionType("TSIntersectionType", this.tsParseTypeOperatorOrHigher.bind(this), types.bitwiseAND);
    };

    _proto.tsParseUnionTypeOrHigher = function tsParseUnionTypeOrHigher() {
      return this.tsParseUnionOrIntersectionType("TSUnionType", this.tsParseIntersectionTypeOrHigher.bind(this), types.bitwiseOR);
    };

    _proto.tsIsStartOfFunctionType = function tsIsStartOfFunctionType() {
      if (this.isRelational("<")) {
        return true;
      }

      return this.match(types.parenL) && this.tsLookAhead(this.tsIsUnambiguouslyStartOfFunctionType.bind(this));
    };

    _proto.tsSkipParameterStart = function tsSkipParameterStart() {
      if (this.match(types.name) || this.match(types._this)) {
        this.next();
        return true;
      }

      return false;
    };

    _proto.tsIsUnambiguouslyStartOfFunctionType = function tsIsUnambiguouslyStartOfFunctionType() {
      this.next();

      if (this.match(types.parenR) || this.match(types.ellipsis)) {
        return true;
      }

      if (this.tsSkipParameterStart()) {
        if (this.match(types.colon) || this.match(types.comma) || this.match(types.question) || this.match(types.eq)) {
          return true;
        }

        if (this.match(types.parenR)) {
          this.next();

          if (this.match(types.arrow)) {
            return true;
          }
        }
      }

      return false;
    };

    _proto.tsParseTypeOrTypePredicateAnnotation = function tsParseTypeOrTypePredicateAnnotation(returnToken) {
      var _this4 = this;

      return this.tsInType(function () {
        var t = _this4.startNode();

        _this4.expect(returnToken);

        var typePredicateVariable = _this4.tsIsIdentifier() && _this4.tsTryParse(_this4.tsParseTypePredicatePrefix.bind(_this4));

        if (!typePredicateVariable) {
          return _this4.tsParseTypeAnnotation(false, t);
        }

        var type = _this4.tsParseTypeAnnotation(false);

        var node = _this4.startNodeAtNode(typePredicateVariable);

        node.parameterName = typePredicateVariable;
        node.typeAnnotation = type;
        t.typeAnnotation = _this4.finishNode(node, "TSTypePredicate");
        return _this4.finishNode(t, "TSTypeAnnotation");
      });
    };

    _proto.tsTryParseTypeOrTypePredicateAnnotation = function tsTryParseTypeOrTypePredicateAnnotation() {
      return this.match(types.colon) ? this.tsParseTypeOrTypePredicateAnnotation(types.colon) : undefined;
    };

    _proto.tsTryParseTypeAnnotation = function tsTryParseTypeAnnotation() {
      return this.match(types.colon) ? this.tsParseTypeAnnotation() : undefined;
    };

    _proto.tsTryParseType = function tsTryParseType() {
      return this.tsEatThenParseType(types.colon);
    };

    _proto.tsParseTypePredicatePrefix = function tsParseTypePredicatePrefix() {
      var id = this.parseIdentifier();

      if (this.isContextual("is") && !this.hasPrecedingLineBreak()) {
        this.next();
        return id;
      }
    };

    _proto.tsParseTypeAnnotation = function tsParseTypeAnnotation(eatColon, t) {
      var _this5 = this;

      if (eatColon === void 0) {
        eatColon = true;
      }

      if (t === void 0) {
        t = this.startNode();
      }

      this.tsInType(function () {
        if (eatColon) _this5.expect(types.colon);
        t.typeAnnotation = _this5.tsParseType();
      });
      return this.finishNode(t, "TSTypeAnnotation");
    };

    _proto.tsParseType = function tsParseType() {
      assert(this.state.inType);
      var type = this.tsParseNonConditionalType();

      if (this.hasPrecedingLineBreak() || !this.eat(types._extends)) {
        return type;
      }

      var node = this.startNodeAtNode(type);
      node.checkType = type;
      node.extendsType = this.tsParseNonConditionalType();
      this.expect(types.question);
      node.trueType = this.tsParseType();
      this.expect(types.colon);
      node.falseType = this.tsParseType();
      return this.finishNode(node, "TSConditionalType");
    };

    _proto.tsParseNonConditionalType = function tsParseNonConditionalType() {
      if (this.tsIsStartOfFunctionType()) {
        return this.tsParseFunctionOrConstructorType("TSFunctionType");
      }

      if (this.match(types._new)) {
        return this.tsParseFunctionOrConstructorType("TSConstructorType");
      }

      return this.tsParseUnionTypeOrHigher();
    };

    _proto.tsParseTypeAssertion = function tsParseTypeAssertion() {
      var _this6 = this;

      var node = this.startNode();
      node.typeAnnotation = this.tsInType(function () {
        return _this6.tsParseType();
      });
      this.expectRelational(">");
      node.expression = this.parseMaybeUnary();
      return this.finishNode(node, "TSTypeAssertion");
    };

    _proto.tsTryParseTypeArgumentsInExpression = function tsTryParseTypeArgumentsInExpression() {
      var _this7 = this;

      return this.tsTryParseAndCatch(function () {
        var res = _this7.tsParseTypeArguments();

        _this7.expect(types.parenL);

        return res;
      });
    };

    _proto.tsParseHeritageClause = function tsParseHeritageClause() {
      return this.tsParseDelimitedList("HeritageClauseElement", this.tsParseExpressionWithTypeArguments.bind(this));
    };

    _proto.tsParseExpressionWithTypeArguments = function tsParseExpressionWithTypeArguments() {
      var node = this.startNode();
      node.expression = this.tsParseEntityName(false);

      if (this.isRelational("<")) {
        node.typeParameters = this.tsParseTypeArguments();
      }

      return this.finishNode(node, "TSExpressionWithTypeArguments");
    };

    _proto.tsParseInterfaceDeclaration = function tsParseInterfaceDeclaration(node) {
      node.id = this.parseIdentifier();
      node.typeParameters = this.tsTryParseTypeParameters();

      if (this.eat(types._extends)) {
        node.extends = this.tsParseHeritageClause();
      }

      var body = this.startNode();
      body.body = this.tsParseObjectTypeMembers();
      node.body = this.finishNode(body, "TSInterfaceBody");
      return this.finishNode(node, "TSInterfaceDeclaration");
    };

    _proto.tsParseTypeAliasDeclaration = function tsParseTypeAliasDeclaration(node) {
      node.id = this.parseIdentifier();
      node.typeParameters = this.tsTryParseTypeParameters();
      node.typeAnnotation = this.tsExpectThenParseType(types.eq);
      this.semicolon();
      return this.finishNode(node, "TSTypeAliasDeclaration");
    };

    _proto.tsInType = function tsInType(cb) {
      var oldInType = this.state.inType;
      this.state.inType = true;

      try {
        return cb();
      } finally {
        this.state.inType = oldInType;
      }
    };

    _proto.tsEatThenParseType = function tsEatThenParseType(token) {
      return !this.match(token) ? undefined : this.tsNextThenParseType();
    };

    _proto.tsExpectThenParseType = function tsExpectThenParseType(token) {
      var _this8 = this;

      return this.tsDoThenParseType(function () {
        return _this8.expect(token);
      });
    };

    _proto.tsNextThenParseType = function tsNextThenParseType() {
      var _this9 = this;

      return this.tsDoThenParseType(function () {
        return _this9.next();
      });
    };

    _proto.tsDoThenParseType = function tsDoThenParseType(cb) {
      var _this10 = this;

      return this.tsInType(function () {
        cb();
        return _this10.tsParseType();
      });
    };

    _proto.tsParseEnumMember = function tsParseEnumMember() {
      var node = this.startNode();
      node.id = this.match(types.string) ? this.parseLiteral(this.state.value, "StringLiteral") : this.parseIdentifier(true);

      if (this.eat(types.eq)) {
        node.initializer = this.parseMaybeAssign();
      }

      return this.finishNode(node, "TSEnumMember");
    };

    _proto.tsParseEnumDeclaration = function tsParseEnumDeclaration(node, isConst) {
      if (isConst) node.const = true;
      node.id = this.parseIdentifier();
      this.expect(types.braceL);
      node.members = this.tsParseDelimitedList("EnumMembers", this.tsParseEnumMember.bind(this));
      this.expect(types.braceR);
      return this.finishNode(node, "TSEnumDeclaration");
    };

    _proto.tsParseModuleBlock = function tsParseModuleBlock() {
      var node = this.startNode();
      this.expect(types.braceL);
      this.parseBlockOrModuleBlockBody(node.body = [], undefined, true, types.braceR);
      return this.finishNode(node, "TSModuleBlock");
    };

    _proto.tsParseModuleOrNamespaceDeclaration = function tsParseModuleOrNamespaceDeclaration(node) {
      node.id = this.parseIdentifier();

      if (this.eat(types.dot)) {
        var inner = this.startNode();
        this.tsParseModuleOrNamespaceDeclaration(inner);
        node.body = inner;
      } else {
        node.body = this.tsParseModuleBlock();
      }

      return this.finishNode(node, "TSModuleDeclaration");
    };

    _proto.tsParseAmbientExternalModuleDeclaration = function tsParseAmbientExternalModuleDeclaration(node) {
      if (this.isContextual("global")) {
        node.global = true;
        node.id = this.parseIdentifier();
      } else if (this.match(types.string)) {
        node.id = this.parseExprAtom();
      } else {
        this.unexpected();
      }

      if (this.match(types.braceL)) {
        node.body = this.tsParseModuleBlock();
      } else {
        this.semicolon();
      }

      return this.finishNode(node, "TSModuleDeclaration");
    };

    _proto.tsParseImportEqualsDeclaration = function tsParseImportEqualsDeclaration(node, isExport) {
      node.isExport = isExport || false;
      node.id = this.parseIdentifier();
      this.expect(types.eq);
      node.moduleReference = this.tsParseModuleReference();
      this.semicolon();
      return this.finishNode(node, "TSImportEqualsDeclaration");
    };

    _proto.tsIsExternalModuleReference = function tsIsExternalModuleReference() {
      return this.isContextual("require") && this.lookahead().type === types.parenL;
    };

    _proto.tsParseModuleReference = function tsParseModuleReference() {
      return this.tsIsExternalModuleReference() ? this.tsParseExternalModuleReference() : this.tsParseEntityName(false);
    };

    _proto.tsParseExternalModuleReference = function tsParseExternalModuleReference() {
      var node = this.startNode();
      this.expectContextual("require");
      this.expect(types.parenL);

      if (!this.match(types.string)) {
        throw this.unexpected();
      }

      node.expression = this.parseLiteral(this.state.value, "StringLiteral");
      this.expect(types.parenR);
      return this.finishNode(node, "TSExternalModuleReference");
    };

    _proto.tsLookAhead = function tsLookAhead(f) {
      var state = this.state.clone();
      var res = f();
      this.state = state;
      return res;
    };

    _proto.tsTryParseAndCatch = function tsTryParseAndCatch(f) {
      var state = this.state.clone();

      try {
        return f();
      } catch (e) {
        if (e instanceof SyntaxError) {
          this.state = state;
          return undefined;
        }

        throw e;
      }
    };

    _proto.tsTryParse = function tsTryParse(f) {
      var state = this.state.clone();
      var result = f();

      if (result !== undefined && result !== false) {
        return result;
      } else {
        this.state = state;
        return undefined;
      }
    };

    _proto.nodeWithSamePosition = function nodeWithSamePosition(original, type) {
      var node = this.startNodeAtNode(original);
      node.type = type;
      node.end = original.end;
      node.loc.end = original.loc.end;

      if (original.leadingComments) {
        node.leadingComments = original.leadingComments;
      }

      if (original.trailingComments) {
        node.trailingComments = original.trailingComments;
      }

      if (original.innerComments) node.innerComments = original.innerComments;
      return node;
    };

    _proto.tsTryParseDeclare = function tsTryParseDeclare(nany) {
      switch (this.state.type) {
        case types._function:
          this.next();
          return this.parseFunction(nany, true);

        case types._class:
          return this.parseClass(nany, true, false);

        case types._const:
          if (this.match(types._const) && this.isLookaheadContextual("enum")) {
            this.expect(types._const);
            this.expectContextual("enum");
            return this.tsParseEnumDeclaration(nany, true);
          }

        case types._var:
        case types._let:
          return this.parseVarStatement(nany, this.state.type);

        case types.name:
          {
            var value = this.state.value;

            if (value === "global") {
              return this.tsParseAmbientExternalModuleDeclaration(nany);
            } else {
              return this.tsParseDeclaration(nany, value, true);
            }
          }
      }
    };

    _proto.tsTryParseExportDeclaration = function tsTryParseExportDeclaration() {
      return this.tsParseDeclaration(this.startNode(), this.state.value, true);
    };

    _proto.tsParseExpressionStatement = function tsParseExpressionStatement(node, expr) {
      switch (expr.name) {
        case "declare":
          {
            var declaration = this.tsTryParseDeclare(node);

            if (declaration) {
              declaration.declare = true;
              return declaration;
            }

            break;
          }

        case "global":
          if (this.match(types.braceL)) {
            var mod = node;
            mod.global = true;
            mod.id = expr;
            mod.body = this.tsParseModuleBlock();
            return this.finishNode(mod, "TSModuleDeclaration");
          }

          break;

        default:
          return this.tsParseDeclaration(node, expr.name, false);
      }
    };

    _proto.tsParseDeclaration = function tsParseDeclaration(node, value, next) {
      switch (value) {
        case "abstract":
          if (next || this.match(types._class)) {
            var cls = node;
            cls.abstract = true;
            if (next) this.next();
            return this.parseClass(cls, true, false);
          }

          break;

        case "enum":
          if (next || this.match(types.name)) {
            if (next) this.next();
            return this.tsParseEnumDeclaration(node, false);
          }

          break;

        case "interface":
          if (next || this.match(types.name)) {
            if (next) this.next();
            return this.tsParseInterfaceDeclaration(node);
          }

          break;

        case "module":
          if (next) this.next();

          if (this.match(types.string)) {
            return this.tsParseAmbientExternalModuleDeclaration(node);
          } else if (next || this.match(types.name)) {
            return this.tsParseModuleOrNamespaceDeclaration(node);
          }

          break;

        case "namespace":
          if (next || this.match(types.name)) {
            if (next) this.next();
            return this.tsParseModuleOrNamespaceDeclaration(node);
          }

          break;

        case "type":
          if (next || this.match(types.name)) {
            if (next) this.next();
            return this.tsParseTypeAliasDeclaration(node);
          }

          break;
      }
    };

    _proto.tsTryParseGenericAsyncArrowFunction = function tsTryParseGenericAsyncArrowFunction(startPos, startLoc) {
      var _this11 = this;

      var res = this.tsTryParseAndCatch(function () {
        var node = _this11.startNodeAt(startPos, startLoc);

        node.typeParameters = _this11.tsParseTypeParameters();

        _superClass.prototype.parseFunctionParams.call(_this11, node);

        node.returnType = _this11.tsTryParseTypeOrTypePredicateAnnotation();

        _this11.expect(types.arrow);

        return node;
      });

      if (!res) {
        return undefined;
      }

      res.id = null;
      res.generator = false;
      res.expression = true;
      res.async = true;
      this.parseFunctionBody(res, true);
      return this.finishNode(res, "ArrowFunctionExpression");
    };

    _proto.tsParseTypeArguments = function tsParseTypeArguments() {
      var _this12 = this;

      var node = this.startNode();
      node.params = this.tsInType(function () {
        _this12.expectRelational("<");

        return _this12.tsParseDelimitedList("TypeParametersOrArguments", _this12.tsParseType.bind(_this12));
      });
      this.expectRelational(">");
      return this.finishNode(node, "TSTypeParameterInstantiation");
    };

    _proto.tsIsDeclarationStart = function tsIsDeclarationStart() {
      if (this.match(types.name)) {
        switch (this.state.value) {
          case "abstract":
          case "declare":
          case "enum":
          case "interface":
          case "module":
          case "namespace":
          case "type":
            return true;
        }
      }

      return false;
    };

    _proto.isExportDefaultSpecifier = function isExportDefaultSpecifier() {
      if (this.tsIsDeclarationStart()) return false;
      return _superClass.prototype.isExportDefaultSpecifier.call(this);
    };

    _proto.parseAssignableListItem = function parseAssignableListItem(allowModifiers, decorators) {
      var accessibility;
      var readonly = false;

      if (allowModifiers) {
        accessibility = this.parseAccessModifier();
        readonly = !!this.tsParseModifier(["readonly"]);
      }

      var left = this.parseMaybeDefault();
      this.parseAssignableListItemTypes(left);
      var elt = this.parseMaybeDefault(left.start, left.loc.start, left);

      if (accessibility || readonly) {
        var pp = this.startNodeAtNode(elt);

        if (decorators.length) {
          pp.decorators = decorators;
        }

        if (accessibility) pp.accessibility = accessibility;
        if (readonly) pp.readonly = readonly;

        if (elt.type !== "Identifier" && elt.type !== "AssignmentPattern") {
          throw this.raise(pp.start, "A parameter property may not be declared using a binding pattern.");
        }

        pp.parameter = elt;
        return this.finishNode(pp, "TSParameterProperty");
      } else {
        if (decorators.length) {
          left.decorators = decorators;
        }

        return elt;
      }
    };

    _proto.parseFunctionBodyAndFinish = function parseFunctionBodyAndFinish(node, type, allowExpressionBody) {
      if (!allowExpressionBody && this.match(types.colon)) {
        node.returnType = this.tsParseTypeOrTypePredicateAnnotation(types.colon);
      }

      var bodilessType = type === "FunctionDeclaration" ? "TSDeclareFunction" : type === "ClassMethod" ? "TSDeclareMethod" : undefined;

      if (bodilessType && !this.match(types.braceL) && this.isLineTerminator()) {
        this.finishNode(node, bodilessType);
        return;
      }

      _superClass.prototype.parseFunctionBodyAndFinish.call(this, node, type, allowExpressionBody);
    };

    _proto.parseSubscript = function parseSubscript(base, startPos, startLoc, noCalls, state) {
      if (!this.hasPrecedingLineBreak() && this.eat(types.bang)) {
        var nonNullExpression = this.startNodeAt(startPos, startLoc);
        nonNullExpression.expression = base;
        return this.finishNode(nonNullExpression, "TSNonNullExpression");
      }

      if (!noCalls && this.isRelational("<")) {
        if (this.atPossibleAsync(base)) {
          var asyncArrowFn = this.tsTryParseGenericAsyncArrowFunction(startPos, startLoc);

          if (asyncArrowFn) {
            return asyncArrowFn;
          }
        }

        var node = this.startNodeAt(startPos, startLoc);
        node.callee = base;
        var typeArguments = this.tsTryParseTypeArgumentsInExpression();

        if (typeArguments) {
          node.arguments = this.parseCallExpressionArguments(types.parenR, false);
          node.typeParameters = typeArguments;
          return this.finishCallExpression(node);
        }
      }

      return _superClass.prototype.parseSubscript.call(this, base, startPos, startLoc, noCalls, state);
    };

    _proto.parseNewArguments = function parseNewArguments(node) {
      var _this13 = this;

      if (this.isRelational("<")) {
        var typeParameters = this.tsTryParseAndCatch(function () {
          var args = _this13.tsParseTypeArguments();

          if (!_this13.match(types.parenL)) _this13.unexpected();
          return args;
        });

        if (typeParameters) {
          node.typeParameters = typeParameters;
        }
      }

      _superClass.prototype.parseNewArguments.call(this, node);
    };

    _proto.parseExprOp = function parseExprOp(left, leftStartPos, leftStartLoc, minPrec, noIn) {
      if (nonNull(types._in.binop) > minPrec && !this.hasPrecedingLineBreak() && this.isContextual("as")) {
        var node = this.startNodeAt(leftStartPos, leftStartLoc);
        node.expression = left;
        node.typeAnnotation = this.tsNextThenParseType();
        this.finishNode(node, "TSAsExpression");
        return this.parseExprOp(node, leftStartPos, leftStartLoc, minPrec, noIn);
      }

      return _superClass.prototype.parseExprOp.call(this, left, leftStartPos, leftStartLoc, minPrec, noIn);
    };

    _proto.checkReservedWord = function checkReservedWord(word, startLoc, checkKeywords, isBinding) {};

    _proto.checkDuplicateExports = function checkDuplicateExports() {};

    _proto.parseImport = function parseImport(node) {
      if (this.match(types.name) && this.lookahead().type === types.eq) {
        return this.tsParseImportEqualsDeclaration(node);
      }

      return _superClass.prototype.parseImport.call(this, node);
    };

    _proto.parseExport = function parseExport(node) {
      if (this.match(types._import)) {
        this.expect(types._import);
        return this.tsParseImportEqualsDeclaration(node, true);
      } else if (this.eat(types.eq)) {
        var assign = node;
        assign.expression = this.parseExpression();
        this.semicolon();
        return this.finishNode(assign, "TSExportAssignment");
      } else if (this.eatContextual("as")) {
        var decl = node;
        this.expectContextual("namespace");
        decl.id = this.parseIdentifier();
        this.semicolon();
        return this.finishNode(decl, "TSNamespaceExportDeclaration");
      } else {
        return _superClass.prototype.parseExport.call(this, node);
      }
    };

    _proto.isAbstractClass = function isAbstractClass() {
      return this.isContextual("abstract") && this.lookahead().type === types._class;
    };

    _proto.parseExportDefaultExpression = function parseExportDefaultExpression() {
      if (this.isAbstractClass()) {
        var cls = this.startNode();
        this.next();
        this.parseClass(cls, true, true);
        cls.abstract = true;
        return cls;
      }

      return _superClass.prototype.parseExportDefaultExpression.call(this);
    };

    _proto.parseStatementContent = function parseStatementContent(declaration, topLevel) {
      if (this.state.type === types._const) {
        var ahead = this.lookahead();

        if (ahead.type === types.name && ahead.value === "enum") {
          var node = this.startNode();
          this.expect(types._const);
          this.expectContextual("enum");
          return this.tsParseEnumDeclaration(node, true);
        }
      }

      return _superClass.prototype.parseStatementContent.call(this, declaration, topLevel);
    };

    _proto.parseAccessModifier = function parseAccessModifier() {
      return this.tsParseModifier(["public", "protected", "private"]);
    };

    _proto.parseClassMember = function parseClassMember(classBody, member, state) {
      var accessibility = this.parseAccessModifier();
      if (accessibility) member.accessibility = accessibility;

      _superClass.prototype.parseClassMember.call(this, classBody, member, state);
    };

    _proto.parseClassMemberWithIsStatic = function parseClassMemberWithIsStatic(classBody, member, state, isStatic) {
      var methodOrProp = member;
      var prop = member;
      var propOrIdx = member;
      var abstract = false,
          readonly = false;
      var mod = this.tsParseModifier(["abstract", "readonly"]);

      switch (mod) {
        case "readonly":
          readonly = true;
          abstract = !!this.tsParseModifier(["abstract"]);
          break;

        case "abstract":
          abstract = true;
          readonly = !!this.tsParseModifier(["readonly"]);
          break;
      }

      if (abstract) methodOrProp.abstract = true;
      if (readonly) propOrIdx.readonly = true;

      if (!abstract && !isStatic && !methodOrProp.accessibility) {
        var idx = this.tsTryParseIndexSignature(member);

        if (idx) {
          classBody.body.push(idx);
          return;
        }
      }

      if (readonly) {
        methodOrProp.static = isStatic;
        this.parseClassPropertyName(prop);
        this.parsePostMemberNameModifiers(methodOrProp);
        this.pushClassProperty(classBody, prop);
        return;
      }

      _superClass.prototype.parseClassMemberWithIsStatic.call(this, classBody, member, state, isStatic);
    };

    _proto.parsePostMemberNameModifiers = function parsePostMemberNameModifiers(methodOrProp) {
      var optional = this.eat(types.question);
      if (optional) methodOrProp.optional = true;
    };

    _proto.parseExpressionStatement = function parseExpressionStatement(node, expr) {
      var decl = expr.type === "Identifier" ? this.tsParseExpressionStatement(node, expr) : undefined;
      return decl || _superClass.prototype.parseExpressionStatement.call(this, node, expr);
    };

    _proto.shouldParseExportDeclaration = function shouldParseExportDeclaration() {
      if (this.tsIsDeclarationStart()) return true;
      return _superClass.prototype.shouldParseExportDeclaration.call(this);
    };

    _proto.parseConditional = function parseConditional(expr, noIn, startPos, startLoc, refNeedsArrowPos) {
      if (!refNeedsArrowPos || !this.match(types.question)) {
        return _superClass.prototype.parseConditional.call(this, expr, noIn, startPos, startLoc, refNeedsArrowPos);
      }

      var state = this.state.clone();

      try {
        return _superClass.prototype.parseConditional.call(this, expr, noIn, startPos, startLoc);
      } catch (err) {
        if (!(err instanceof SyntaxError)) {
          throw err;
        }

        this.state = state;
        refNeedsArrowPos.start = err.pos || this.state.start;
        return expr;
      }
    };

    _proto.parseParenItem = function parseParenItem(node, startPos, startLoc) {
      node = _superClass.prototype.parseParenItem.call(this, node, startPos, startLoc);

      if (this.eat(types.question)) {
        node.optional = true;
      }

      if (this.match(types.colon)) {
        var typeCastNode = this.startNodeAt(startPos, startLoc);
        typeCastNode.expression = node;
        typeCastNode.typeAnnotation = this.tsParseTypeAnnotation();
        return this.finishNode(typeCastNode, "TSTypeCastExpression");
      }

      return node;
    };

    _proto.parseExportDeclaration = function parseExportDeclaration(node) {
      var isDeclare = this.eatContextual("declare");
      var declaration;

      if (this.match(types.name)) {
        declaration = this.tsTryParseExportDeclaration();
      }

      if (!declaration) {
        declaration = _superClass.prototype.parseExportDeclaration.call(this, node);
      }

      if (declaration && isDeclare) {
        declaration.declare = true;
      }

      return declaration;
    };

    _proto.parseClassId = function parseClassId(node, isStatement, optionalId) {
      if ((!isStatement || optionalId) && this.isContextual("implements")) {
        return;
      }

      _superClass.prototype.parseClassId.apply(this, arguments);

      var typeParameters = this.tsTryParseTypeParameters();
      if (typeParameters) node.typeParameters = typeParameters;
    };

    _proto.parseClassProperty = function parseClassProperty(node) {
      if (!node.optional && this.eat(types.bang)) {
        node.definite = true;
      }

      var type = this.tsTryParseTypeAnnotation();
      if (type) node.typeAnnotation = type;
      return _superClass.prototype.parseClassProperty.call(this, node);
    };

    _proto.pushClassMethod = function pushClassMethod(classBody, method, isGenerator, isAsync, isConstructor) {
      var typeParameters = this.tsTryParseTypeParameters();
      if (typeParameters) method.typeParameters = typeParameters;

      _superClass.prototype.pushClassMethod.call(this, classBody, method, isGenerator, isAsync, isConstructor);
    };

    _proto.pushClassPrivateMethod = function pushClassPrivateMethod(classBody, method, isGenerator, isAsync) {
      var typeParameters = this.tsTryParseTypeParameters();
      if (typeParameters) method.typeParameters = typeParameters;

      _superClass.prototype.pushClassPrivateMethod.call(this, classBody, method, isGenerator, isAsync);
    };

    _proto.parseClassSuper = function parseClassSuper(node) {
      _superClass.prototype.parseClassSuper.call(this, node);

      if (node.superClass && this.isRelational("<")) {
        node.superTypeParameters = this.tsParseTypeArguments();
      }

      if (this.eatContextual("implements")) {
        node.implements = this.tsParseHeritageClause();
      }
    };

    _proto.parseObjPropValue = function parseObjPropValue(prop) {
      var _superClass$prototype;

      if (this.isRelational("<")) {
        throw new Error("TODO");
      }

      for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
        args[_key - 1] = arguments[_key];
      }

      (_superClass$prototype = _superClass.prototype.parseObjPropValue).call.apply(_superClass$prototype, [this, prop].concat(args));
    };

    _proto.parseFunctionParams = function parseFunctionParams(node, allowModifiers) {
      var typeParameters = this.tsTryParseTypeParameters();
      if (typeParameters) node.typeParameters = typeParameters;

      _superClass.prototype.parseFunctionParams.call(this, node, allowModifiers);
    };

    _proto.parseVarHead = function parseVarHead(decl) {
      _superClass.prototype.parseVarHead.call(this, decl);

      if (decl.id.type === "Identifier" && this.eat(types.bang)) {
        decl.definite = true;
      }

      var type = this.tsTryParseTypeAnnotation();

      if (type) {
        decl.id.typeAnnotation = type;
        this.finishNode(decl.id, decl.id.type);
      }
    };

    _proto.parseAsyncArrowFromCallExpression = function parseAsyncArrowFromCallExpression(node, call) {
      if (this.match(types.colon)) {
        node.returnType = this.tsParseTypeAnnotation();
      }

      return _superClass.prototype.parseAsyncArrowFromCallExpression.call(this, node, call);
    };

    _proto.parseMaybeAssign = function parseMaybeAssign() {
      var jsxError;

      for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
        args[_key2] = arguments[_key2];
      }

      if (this.match(types.jsxTagStart)) {
        var context = this.curContext();
        assert(context === types$1.j_oTag);
        assert(this.state.context[this.state.context.length - 2] === types$1.j_expr);

        var _state = this.state.clone();

        try {
          var _superClass$prototype2;

          return (_superClass$prototype2 = _superClass.prototype.parseMaybeAssign).call.apply(_superClass$prototype2, [this].concat(args));
        } catch (err) {
          if (!(err instanceof SyntaxError)) {
            throw err;
          }

          this.state = _state;
          assert(this.curContext() === types$1.j_oTag);
          this.state.context.pop();
          assert(this.curContext() === types$1.j_expr);
          this.state.context.pop();
          jsxError = err;
        }
      }

      if (jsxError === undefined && !this.isRelational("<")) {
        var _superClass$prototype3;

        return (_superClass$prototype3 = _superClass.prototype.parseMaybeAssign).call.apply(_superClass$prototype3, [this].concat(args));
      }

      var arrowExpression;
      var typeParameters;
      var state = this.state.clone();

      try {
        var _superClass$prototype4;

        typeParameters = this.tsParseTypeParameters();
        arrowExpression = (_superClass$prototype4 = _superClass.prototype.parseMaybeAssign).call.apply(_superClass$prototype4, [this].concat(args));

        if (arrowExpression.type !== "ArrowFunctionExpression") {
          this.unexpected();
        }
      } catch (err) {
        var _superClass$prototype5;

        if (!(err instanceof SyntaxError)) {
          throw err;
        }

        if (jsxError) {
          throw jsxError;
        }

        assert(!this.hasPlugin("jsx"));
        this.state = state;
        return (_superClass$prototype5 = _superClass.prototype.parseMaybeAssign).call.apply(_superClass$prototype5, [this].concat(args));
      }

      if (typeParameters && typeParameters.params.length !== 0) {
        this.resetStartLocationFromNode(arrowExpression, typeParameters.params[0]);
      }

      arrowExpression.typeParameters = typeParameters;
      return arrowExpression;
    };

    _proto.parseMaybeUnary = function parseMaybeUnary(refShorthandDefaultPos) {
      if (!this.hasPlugin("jsx") && this.eatRelational("<")) {
        return this.tsParseTypeAssertion();
      } else {
        return _superClass.prototype.parseMaybeUnary.call(this, refShorthandDefaultPos);
      }
    };

    _proto.parseArrow = function parseArrow(node) {
      if (this.match(types.colon)) {
        var state = this.state.clone();

        try {
          var returnType = this.tsParseTypeOrTypePredicateAnnotation(types.colon);
          if (this.canInsertSemicolon()) this.unexpected();
          if (!this.match(types.arrow)) this.unexpected();
          node.returnType = returnType;
        } catch (err) {
          if (err instanceof SyntaxError) {
            this.state = state;
          } else {
            throw err;
          }
        }
      }

      return _superClass.prototype.parseArrow.call(this, node);
    };

    _proto.parseAssignableListItemTypes = function parseAssignableListItemTypes(param) {
      if (this.eat(types.question)) {
        if (param.type !== "Identifier") {
          throw this.raise(param.start, "A binding pattern parameter cannot be optional in an implementation signature.");
        }

        param.optional = true;
      }

      var type = this.tsTryParseTypeAnnotation();
      if (type) param.typeAnnotation = type;
      return this.finishNode(param, param.type);
    };

    _proto.toAssignable = function toAssignable(node, isBinding, contextDescription) {
      switch (node.type) {
        case "TSTypeCastExpression":
          return _superClass.prototype.toAssignable.call(this, this.typeCastToParameter(node), isBinding, contextDescription);

        case "TSParameterProperty":
          return _superClass.prototype.toAssignable.call(this, node, isBinding, contextDescription);

        case "TSAsExpression":
        case "TSNonNullExpression":
        case "TSTypeAssertion":
          node.expression = this.toAssignable(node.expression, isBinding, contextDescription);
          return node;

        default:
          return _superClass.prototype.toAssignable.call(this, node, isBinding, contextDescription);
      }
    };

    _proto.checkLVal = function checkLVal(expr, isBinding, checkClashes, contextDescription) {
      switch (expr.type) {
        case "TSTypeCastExpression":
          return;

        case "TSParameterProperty":
          this.checkLVal(expr.parameter, isBinding, checkClashes, "parameter property");
          return;

        case "TSAsExpression":
        case "TSNonNullExpression":
        case "TSTypeAssertion":
          this.checkLVal(expr.expression, isBinding, checkClashes, contextDescription);
          return;

        default:
          _superClass.prototype.checkLVal.call(this, expr, isBinding, checkClashes, contextDescription);

          return;
      }
    };

    _proto.parseBindingAtom = function parseBindingAtom() {
      switch (this.state.type) {
        case types._this:
          return this.parseIdentifier(true);

        default:
          return _superClass.prototype.parseBindingAtom.call(this);
      }
    };

    _proto.isClassMethod = function isClassMethod() {
      return this.isRelational("<") || _superClass.prototype.isClassMethod.call(this);
    };

    _proto.isClassProperty = function isClassProperty() {
      return this.match(types.bang) || this.match(types.colon) || _superClass.prototype.isClassProperty.call(this);
    };

    _proto.parseMaybeDefault = function parseMaybeDefault() {
      var _superClass$prototype6;

      for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
        args[_key3] = arguments[_key3];
      }

      var node = (_superClass$prototype6 = _superClass.prototype.parseMaybeDefault).call.apply(_superClass$prototype6, [this].concat(args));

      if (node.type === "AssignmentPattern" && node.typeAnnotation && node.right.start < node.typeAnnotation.start) {
        this.raise(node.typeAnnotation.start, "Type annotations must come before default assignments, " + "e.g. instead of `age = 25: number` use `age: number = 25`");
      }

      return node;
    };

    _proto.readToken = function readToken(code) {
      if (this.state.inType && (code === 62 || code === 60)) {
        return this.finishOp(types.relational, 1);
      } else {
        return _superClass.prototype.readToken.call(this, code);
      }
    };

    _proto.toAssignableList = function toAssignableList(exprList, isBinding, contextDescription) {
      for (var i = 0; i < exprList.length; i++) {
        var expr = exprList[i];

        if (expr && expr.type === "TSTypeCastExpression") {
          exprList[i] = this.typeCastToParameter(expr);
        }
      }

      return _superClass.prototype.toAssignableList.call(this, exprList, isBinding, contextDescription);
    };

    _proto.typeCastToParameter = function typeCastToParameter(node) {
      node.expression.typeAnnotation = node.typeAnnotation;
      return this.finishNodeAt(node.expression, node.expression.type, node.typeAnnotation.end, node.typeAnnotation.loc.end);
    };

    _proto.toReferencedList = function toReferencedList(exprList) {
      for (var i = 0; i < exprList.length; i++) {
        var expr = exprList[i];

        if (expr && expr._exprListItem && expr.type === "TsTypeCastExpression") {
          this.raise(expr.start, "Did not expect a type annotation here.");
        }
      }

      return exprList;
    };

    _proto.shouldParseArrow = function shouldParseArrow() {
      return this.match(types.colon) || _superClass.prototype.shouldParseArrow.call(this);
    };

    _proto.shouldParseAsyncArrow = function shouldParseAsyncArrow() {
      return this.match(types.colon) || _superClass.prototype.shouldParseAsyncArrow.call(this);
    };

    _proto.canHaveLeadingDecorator = function canHaveLeadingDecorator() {
      return _superClass.prototype.canHaveLeadingDecorator.call(this) || this.isAbstractClass();
    };

    _inheritsLoose(_class, _superClass);

    return _class;
  }(superClass);
});

plugins.estree = estreePlugin;
plugins.flow = flowPlugin;
plugins.jsx = jsxPlugin;
plugins.typescript = typescriptPlugin;
function parse(input, options) {
  if (options && options.sourceType === "unambiguous") {
    options = Object.assign({}, options);

    try {
      options.sourceType = "module";
      var parser = getParser(options, input);
      var ast = parser.parse();
      if (!parser.sawUnambiguousESM) ast.program.sourceType = "script";
      return ast;
    } catch (moduleError) {
      try {
        options.sourceType = "script";
        return getParser(options, input).parse();
      } catch (scriptError) {}

      throw moduleError;
    }
  } else {
    return getParser(options, input).parse();
  }
}
function parseExpression(input, options) {
  var parser = getParser(options, input);

  if (parser.options.strictMode) {
    parser.state.strict = true;
  }

  return parser.getExpression();
}
function getParser(options, input) {
  var cls = options && options.plugins ? getParserClass(options.plugins) : Parser;
  return new cls(options, input);
}

var parserClassCache = {};

function getParserClass(pluginsFromOptions) {
  if (pluginsFromOptions.indexOf("decorators-legacy") >= 0 && pluginsFromOptions.indexOf("decorators") >= 0) {
    throw new Error("Cannot use decorators and decorators2 plugin together");
  }

  var pluginList = pluginsFromOptions.filter(function (p) {
    return p === "estree" || p === "flow" || p === "jsx" || p === "typescript";
  });

  if (pluginList.indexOf("flow") >= 0) {
    pluginList = pluginList.filter(function (plugin) {
      return plugin !== "flow";
    });
    pluginList.push("flow");
  }

  if (pluginList.indexOf("flow") >= 0 && pluginList.indexOf("typescript") >= 0) {
    throw new Error("Cannot combine flow and typescript plugins.");
  }

  if (pluginList.indexOf("typescript") >= 0) {
    pluginList = pluginList.filter(function (plugin) {
      return plugin !== "typescript";
    });
    pluginList.push("typescript");
  }

  if (pluginList.indexOf("estree") >= 0) {
    pluginList = pluginList.filter(function (plugin) {
      return plugin !== "estree";
    });
    pluginList.unshift("estree");
  }

  var key = pluginList.join("/");
  var cls = parserClassCache[key];

  if (!cls) {
    cls = Parser;

    for (var _i2 = 0, _pluginList2 = pluginList; _i2 < _pluginList2.length; _i2++) {
      var plugin = _pluginList2[_i2];
      cls = plugins[plugin](cls);
    }

    parserClassCache[key] = cls;
  }

  return cls;
}

exports.parse = parse;
exports.parseExpression = parseExpression;
exports.tokTypes = types;


/***/ }),
/* 455 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/*!
 * define-property <https://github.com/jonschlinkert/define-property>
 *
 * Copyright (c) 2015-2018, Jon Schlinkert.
 * Released under the MIT License.
 */



var isobject = __webpack_require__(151);
var isDescriptor = __webpack_require__(456);
var define = (typeof Reflect !== 'undefined' && Reflect.defineProperty)
  ? Reflect.defineProperty
  : Object.defineProperty;

module.exports = function defineProperty(obj, key, val) {
  if (!isobject(obj) && typeof obj !== 'function' && !Array.isArray(obj)) {
    throw new TypeError('expected an object, function, or array');
  }

  if (typeof key !== 'string') {
    throw new TypeError('expected "key" to be a string');
  }

  if (isDescriptor(val)) {
    define(obj, key, val);
    return obj;
  }

  define(obj, key, {
    configurable: true,
    enumerable: false,
    writable: true,
    value: val
  });

  return obj;
};


/***/ }),
/* 456 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/*!
 * is-descriptor <https://github.com/jonschlinkert/is-descriptor>
 *
 * Copyright (c) 2015-2017, Jon Schlinkert.
 * Released under the MIT License.
 */



var typeOf = __webpack_require__(196);
var isAccessor = __webpack_require__(457);
var isData = __webpack_require__(458);

module.exports = function isDescriptor(obj, key) {
  if (typeOf(obj) !== 'object') {
    return false;
  }
  if ('get' in obj) {
    return isAccessor(obj, key);
  }
  return isData(obj, key);
};


/***/ }),
/* 457 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/*!
 * is-accessor-descriptor <https://github.com/jonschlinkert/is-accessor-descriptor>
 *
 * Copyright (c) 2015-2017, Jon Schlinkert.
 * Released under the MIT License.
 */



var typeOf = __webpack_require__(196);

// accessor descriptor properties
var accessor = {
  get: 'function',
  set: 'function',
  configurable: 'boolean',
  enumerable: 'boolean'
};

function isAccessorDescriptor(obj, prop) {
  if (typeof prop === 'string') {
    var val = Object.getOwnPropertyDescriptor(obj, prop);
    return typeof val !== 'undefined';
  }

  if (typeOf(obj) !== 'object') {
    return false;
  }

  if (has(obj, 'value') || has(obj, 'writable')) {
    return false;
  }

  if (!has(obj, 'get') || typeof obj.get !== 'function') {
    return false;
  }

  // tldr: it's valid to have "set" be undefined
  // "set" might be undefined if `Object.getOwnPropertyDescriptor`
  // was used to get the value, and only `get` was defined by the user
  if (has(obj, 'set') && typeof obj[key] !== 'function' && typeof obj[key] !== 'undefined') {
    return false;
  }

  for (var key in obj) {
    if (!accessor.hasOwnProperty(key)) {
      continue;
    }

    if (typeOf(obj[key]) === accessor[key]) {
      continue;
    }

    if (typeof obj[key] !== 'undefined') {
      return false;
    }
  }
  return true;
}

function has(obj, key) {
  return {}.hasOwnProperty.call(obj, key);
}

/**
 * Expose `isAccessorDescriptor`
 */

module.exports = isAccessorDescriptor;


/***/ }),
/* 458 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/*!
 * is-data-descriptor <https://github.com/jonschlinkert/is-data-descriptor>
 *
 * Copyright (c) 2015-2017, Jon Schlinkert.
 * Released under the MIT License.
 */



var typeOf = __webpack_require__(196);

module.exports = function isDataDescriptor(obj, prop) {
  // data descriptor properties
  var data = {
    configurable: 'boolean',
    enumerable: 'boolean',
    writable: 'boolean'
  };

  if (typeOf(obj) !== 'object') {
    return false;
  }

  if (typeof prop === 'string') {
    var val = Object.getOwnPropertyDescriptor(obj, prop);
    return typeof val !== 'undefined';
  }

  if (!('value' in obj) && !('writable' in obj)) {
    return false;
  }

  for (var key in obj) {
    if (key === 'value') continue;

    if (!data.hasOwnProperty(key)) {
      continue;
    }

    if (typeOf(obj[key]) === data[key]) {
      continue;
    }

    if (typeof obj[key] !== 'undefined') {
      return false;
    }
  }
  return true;
};


/***/ }),
/* 459 */
/***/ (function(module, exports, __webpack_require__) {

var noCase = __webpack_require__(460)

/**
 * Snake case a string.
 *
 * @param  {string} value
 * @param  {string} [locale]
 * @return {string}
 */
module.exports = function (value, locale) {
  return noCase(value, locale, '_')
}


/***/ }),
/* 460 */
/***/ (function(module, exports, __webpack_require__) {

var lowerCase = __webpack_require__(461)

var NON_WORD_REGEXP = __webpack_require__(462)
var CAMEL_CASE_REGEXP = __webpack_require__(463)
var CAMEL_CASE_UPPER_REGEXP = __webpack_require__(464)

/**
 * Sentence case a string.
 *
 * @param  {string} str
 * @param  {string} locale
 * @param  {string} replacement
 * @return {string}
 */
module.exports = function (str, locale, replacement) {
  if (str == null) {
    return ''
  }

  replacement = typeof replacement !== 'string' ? ' ' : replacement

  function replace (match, index, value) {
    if (index === 0 || index === (value.length - match.length)) {
      return ''
    }

    return replacement
  }

  str = String(str)
    // Support camel case ("camelCase" -> "camel Case").
    .replace(CAMEL_CASE_REGEXP, '$1 $2')
    // Support odd camel case ("CAMELCase" -> "CAMEL Case").
    .replace(CAMEL_CASE_UPPER_REGEXP, '$1 $2')
    // Remove all non-word characters and replace with a single space.
    .replace(NON_WORD_REGEXP, replace)

  // Lower case the entire string.
  return lowerCase(str, locale)
}


/***/ }),
/* 461 */
/***/ (function(module, exports) {

/**
 * Special language-specific overrides.
 *
 * Source: ftp://ftp.unicode.org/Public/UCD/latest/ucd/SpecialCasing.txt
 *
 * @type {Object}
 */
var LANGUAGES = {
  tr: {
    regexp: /\u0130|\u0049|\u0049\u0307/g,
    map: {
      '\u0130': '\u0069',
      '\u0049': '\u0131',
      '\u0049\u0307': '\u0069'
    }
  },
  az: {
    regexp: /[\u0130]/g,
    map: {
      '\u0130': '\u0069',
      '\u0049': '\u0131',
      '\u0049\u0307': '\u0069'
    }
  },
  lt: {
    regexp: /[\u0049\u004A\u012E\u00CC\u00CD\u0128]/g,
    map: {
      '\u0049': '\u0069\u0307',
      '\u004A': '\u006A\u0307',
      '\u012E': '\u012F\u0307',
      '\u00CC': '\u0069\u0307\u0300',
      '\u00CD': '\u0069\u0307\u0301',
      '\u0128': '\u0069\u0307\u0303'
    }
  }
}

/**
 * Lowercase a string.
 *
 * @param  {String} str
 * @return {String}
 */
module.exports = function (str, locale) {
  var lang = LANGUAGES[locale]

  str = str == null ? '' : String(str)

  if (lang) {
    str = str.replace(lang.regexp, function (m) { return lang.map[m] })
  }

  return str.toLowerCase()
}


/***/ }),
/* 462 */
/***/ (function(module, exports) {

module.exports = /[^A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AD\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC0-9\xB2\xB3\xB9\xBC-\xBE\u0660-\u0669\u06F0-\u06F9\u07C0-\u07C9\u0966-\u096F\u09E6-\u09EF\u09F4-\u09F9\u0A66-\u0A6F\u0AE6-\u0AEF\u0B66-\u0B6F\u0B72-\u0B77\u0BE6-\u0BF2\u0C66-\u0C6F\u0C78-\u0C7E\u0CE6-\u0CEF\u0D66-\u0D75\u0DE6-\u0DEF\u0E50-\u0E59\u0ED0-\u0ED9\u0F20-\u0F33\u1040-\u1049\u1090-\u1099\u1369-\u137C\u16EE-\u16F0\u17E0-\u17E9\u17F0-\u17F9\u1810-\u1819\u1946-\u194F\u19D0-\u19DA\u1A80-\u1A89\u1A90-\u1A99\u1B50-\u1B59\u1BB0-\u1BB9\u1C40-\u1C49\u1C50-\u1C59\u2070\u2074-\u2079\u2080-\u2089\u2150-\u2182\u2185-\u2189\u2460-\u249B\u24EA-\u24FF\u2776-\u2793\u2CFD\u3007\u3021-\u3029\u3038-\u303A\u3192-\u3195\u3220-\u3229\u3248-\u324F\u3251-\u325F\u3280-\u3289\u32B1-\u32BF\uA620-\uA629\uA6E6-\uA6EF\uA830-\uA835\uA8D0-\uA8D9\uA900-\uA909\uA9D0-\uA9D9\uA9F0-\uA9F9\uAA50-\uAA59\uABF0-\uABF9\uFF10-\uFF19]+/g


/***/ }),
/* 463 */
/***/ (function(module, exports) {

module.exports = /([a-z\xB5\xDF-\xF6\xF8-\xFF\u0101\u0103\u0105\u0107\u0109\u010B\u010D\u010F\u0111\u0113\u0115\u0117\u0119\u011B\u011D\u011F\u0121\u0123\u0125\u0127\u0129\u012B\u012D\u012F\u0131\u0133\u0135\u0137\u0138\u013A\u013C\u013E\u0140\u0142\u0144\u0146\u0148\u0149\u014B\u014D\u014F\u0151\u0153\u0155\u0157\u0159\u015B\u015D\u015F\u0161\u0163\u0165\u0167\u0169\u016B\u016D\u016F\u0171\u0173\u0175\u0177\u017A\u017C\u017E-\u0180\u0183\u0185\u0188\u018C\u018D\u0192\u0195\u0199-\u019B\u019E\u01A1\u01A3\u01A5\u01A8\u01AA\u01AB\u01AD\u01B0\u01B4\u01B6\u01B9\u01BA\u01BD-\u01BF\u01C6\u01C9\u01CC\u01CE\u01D0\u01D2\u01D4\u01D6\u01D8\u01DA\u01DC\u01DD\u01DF\u01E1\u01E3\u01E5\u01E7\u01E9\u01EB\u01ED\u01EF\u01F0\u01F3\u01F5\u01F9\u01FB\u01FD\u01FF\u0201\u0203\u0205\u0207\u0209\u020B\u020D\u020F\u0211\u0213\u0215\u0217\u0219\u021B\u021D\u021F\u0221\u0223\u0225\u0227\u0229\u022B\u022D\u022F\u0231\u0233-\u0239\u023C\u023F\u0240\u0242\u0247\u0249\u024B\u024D\u024F-\u0293\u0295-\u02AF\u0371\u0373\u0377\u037B-\u037D\u0390\u03AC-\u03CE\u03D0\u03D1\u03D5-\u03D7\u03D9\u03DB\u03DD\u03DF\u03E1\u03E3\u03E5\u03E7\u03E9\u03EB\u03ED\u03EF-\u03F3\u03F5\u03F8\u03FB\u03FC\u0430-\u045F\u0461\u0463\u0465\u0467\u0469\u046B\u046D\u046F\u0471\u0473\u0475\u0477\u0479\u047B\u047D\u047F\u0481\u048B\u048D\u048F\u0491\u0493\u0495\u0497\u0499\u049B\u049D\u049F\u04A1\u04A3\u04A5\u04A7\u04A9\u04AB\u04AD\u04AF\u04B1\u04B3\u04B5\u04B7\u04B9\u04BB\u04BD\u04BF\u04C2\u04C4\u04C6\u04C8\u04CA\u04CC\u04CE\u04CF\u04D1\u04D3\u04D5\u04D7\u04D9\u04DB\u04DD\u04DF\u04E1\u04E3\u04E5\u04E7\u04E9\u04EB\u04ED\u04EF\u04F1\u04F3\u04F5\u04F7\u04F9\u04FB\u04FD\u04FF\u0501\u0503\u0505\u0507\u0509\u050B\u050D\u050F\u0511\u0513\u0515\u0517\u0519\u051B\u051D\u051F\u0521\u0523\u0525\u0527\u0529\u052B\u052D\u052F\u0561-\u0587\u13F8-\u13FD\u1D00-\u1D2B\u1D6B-\u1D77\u1D79-\u1D9A\u1E01\u1E03\u1E05\u1E07\u1E09\u1E0B\u1E0D\u1E0F\u1E11\u1E13\u1E15\u1E17\u1E19\u1E1B\u1E1D\u1E1F\u1E21\u1E23\u1E25\u1E27\u1E29\u1E2B\u1E2D\u1E2F\u1E31\u1E33\u1E35\u1E37\u1E39\u1E3B\u1E3D\u1E3F\u1E41\u1E43\u1E45\u1E47\u1E49\u1E4B\u1E4D\u1E4F\u1E51\u1E53\u1E55\u1E57\u1E59\u1E5B\u1E5D\u1E5F\u1E61\u1E63\u1E65\u1E67\u1E69\u1E6B\u1E6D\u1E6F\u1E71\u1E73\u1E75\u1E77\u1E79\u1E7B\u1E7D\u1E7F\u1E81\u1E83\u1E85\u1E87\u1E89\u1E8B\u1E8D\u1E8F\u1E91\u1E93\u1E95-\u1E9D\u1E9F\u1EA1\u1EA3\u1EA5\u1EA7\u1EA9\u1EAB\u1EAD\u1EAF\u1EB1\u1EB3\u1EB5\u1EB7\u1EB9\u1EBB\u1EBD\u1EBF\u1EC1\u1EC3\u1EC5\u1EC7\u1EC9\u1ECB\u1ECD\u1ECF\u1ED1\u1ED3\u1ED5\u1ED7\u1ED9\u1EDB\u1EDD\u1EDF\u1EE1\u1EE3\u1EE5\u1EE7\u1EE9\u1EEB\u1EED\u1EEF\u1EF1\u1EF3\u1EF5\u1EF7\u1EF9\u1EFB\u1EFD\u1EFF-\u1F07\u1F10-\u1F15\u1F20-\u1F27\u1F30-\u1F37\u1F40-\u1F45\u1F50-\u1F57\u1F60-\u1F67\u1F70-\u1F7D\u1F80-\u1F87\u1F90-\u1F97\u1FA0-\u1FA7\u1FB0-\u1FB4\u1FB6\u1FB7\u1FBE\u1FC2-\u1FC4\u1FC6\u1FC7\u1FD0-\u1FD3\u1FD6\u1FD7\u1FE0-\u1FE7\u1FF2-\u1FF4\u1FF6\u1FF7\u210A\u210E\u210F\u2113\u212F\u2134\u2139\u213C\u213D\u2146-\u2149\u214E\u2184\u2C30-\u2C5E\u2C61\u2C65\u2C66\u2C68\u2C6A\u2C6C\u2C71\u2C73\u2C74\u2C76-\u2C7B\u2C81\u2C83\u2C85\u2C87\u2C89\u2C8B\u2C8D\u2C8F\u2C91\u2C93\u2C95\u2C97\u2C99\u2C9B\u2C9D\u2C9F\u2CA1\u2CA3\u2CA5\u2CA7\u2CA9\u2CAB\u2CAD\u2CAF\u2CB1\u2CB3\u2CB5\u2CB7\u2CB9\u2CBB\u2CBD\u2CBF\u2CC1\u2CC3\u2CC5\u2CC7\u2CC9\u2CCB\u2CCD\u2CCF\u2CD1\u2CD3\u2CD5\u2CD7\u2CD9\u2CDB\u2CDD\u2CDF\u2CE1\u2CE3\u2CE4\u2CEC\u2CEE\u2CF3\u2D00-\u2D25\u2D27\u2D2D\uA641\uA643\uA645\uA647\uA649\uA64B\uA64D\uA64F\uA651\uA653\uA655\uA657\uA659\uA65B\uA65D\uA65F\uA661\uA663\uA665\uA667\uA669\uA66B\uA66D\uA681\uA683\uA685\uA687\uA689\uA68B\uA68D\uA68F\uA691\uA693\uA695\uA697\uA699\uA69B\uA723\uA725\uA727\uA729\uA72B\uA72D\uA72F-\uA731\uA733\uA735\uA737\uA739\uA73B\uA73D\uA73F\uA741\uA743\uA745\uA747\uA749\uA74B\uA74D\uA74F\uA751\uA753\uA755\uA757\uA759\uA75B\uA75D\uA75F\uA761\uA763\uA765\uA767\uA769\uA76B\uA76D\uA76F\uA771-\uA778\uA77A\uA77C\uA77F\uA781\uA783\uA785\uA787\uA78C\uA78E\uA791\uA793-\uA795\uA797\uA799\uA79B\uA79D\uA79F\uA7A1\uA7A3\uA7A5\uA7A7\uA7A9\uA7B5\uA7B7\uA7FA\uAB30-\uAB5A\uAB60-\uAB65\uAB70-\uABBF\uFB00-\uFB06\uFB13-\uFB17\uFF41-\uFF5A0-9\xB2\xB3\xB9\xBC-\xBE\u0660-\u0669\u06F0-\u06F9\u07C0-\u07C9\u0966-\u096F\u09E6-\u09EF\u09F4-\u09F9\u0A66-\u0A6F\u0AE6-\u0AEF\u0B66-\u0B6F\u0B72-\u0B77\u0BE6-\u0BF2\u0C66-\u0C6F\u0C78-\u0C7E\u0CE6-\u0CEF\u0D66-\u0D75\u0DE6-\u0DEF\u0E50-\u0E59\u0ED0-\u0ED9\u0F20-\u0F33\u1040-\u1049\u1090-\u1099\u1369-\u137C\u16EE-\u16F0\u17E0-\u17E9\u17F0-\u17F9\u1810-\u1819\u1946-\u194F\u19D0-\u19DA\u1A80-\u1A89\u1A90-\u1A99\u1B50-\u1B59\u1BB0-\u1BB9\u1C40-\u1C49\u1C50-\u1C59\u2070\u2074-\u2079\u2080-\u2089\u2150-\u2182\u2185-\u2189\u2460-\u249B\u24EA-\u24FF\u2776-\u2793\u2CFD\u3007\u3021-\u3029\u3038-\u303A\u3192-\u3195\u3220-\u3229\u3248-\u324F\u3251-\u325F\u3280-\u3289\u32B1-\u32BF\uA620-\uA629\uA6E6-\uA6EF\uA830-\uA835\uA8D0-\uA8D9\uA900-\uA909\uA9D0-\uA9D9\uA9F0-\uA9F9\uAA50-\uAA59\uABF0-\uABF9\uFF10-\uFF19])([A-Z\xC0-\xD6\xD8-\xDE\u0100\u0102\u0104\u0106\u0108\u010A\u010C\u010E\u0110\u0112\u0114\u0116\u0118\u011A\u011C\u011E\u0120\u0122\u0124\u0126\u0128\u012A\u012C\u012E\u0130\u0132\u0134\u0136\u0139\u013B\u013D\u013F\u0141\u0143\u0145\u0147\u014A\u014C\u014E\u0150\u0152\u0154\u0156\u0158\u015A\u015C\u015E\u0160\u0162\u0164\u0166\u0168\u016A\u016C\u016E\u0170\u0172\u0174\u0176\u0178\u0179\u017B\u017D\u0181\u0182\u0184\u0186\u0187\u0189-\u018B\u018E-\u0191\u0193\u0194\u0196-\u0198\u019C\u019D\u019F\u01A0\u01A2\u01A4\u01A6\u01A7\u01A9\u01AC\u01AE\u01AF\u01B1-\u01B3\u01B5\u01B7\u01B8\u01BC\u01C4\u01C7\u01CA\u01CD\u01CF\u01D1\u01D3\u01D5\u01D7\u01D9\u01DB\u01DE\u01E0\u01E2\u01E4\u01E6\u01E8\u01EA\u01EC\u01EE\u01F1\u01F4\u01F6-\u01F8\u01FA\u01FC\u01FE\u0200\u0202\u0204\u0206\u0208\u020A\u020C\u020E\u0210\u0212\u0214\u0216\u0218\u021A\u021C\u021E\u0220\u0222\u0224\u0226\u0228\u022A\u022C\u022E\u0230\u0232\u023A\u023B\u023D\u023E\u0241\u0243-\u0246\u0248\u024A\u024C\u024E\u0370\u0372\u0376\u037F\u0386\u0388-\u038A\u038C\u038E\u038F\u0391-\u03A1\u03A3-\u03AB\u03CF\u03D2-\u03D4\u03D8\u03DA\u03DC\u03DE\u03E0\u03E2\u03E4\u03E6\u03E8\u03EA\u03EC\u03EE\u03F4\u03F7\u03F9\u03FA\u03FD-\u042F\u0460\u0462\u0464\u0466\u0468\u046A\u046C\u046E\u0470\u0472\u0474\u0476\u0478\u047A\u047C\u047E\u0480\u048A\u048C\u048E\u0490\u0492\u0494\u0496\u0498\u049A\u049C\u049E\u04A0\u04A2\u04A4\u04A6\u04A8\u04AA\u04AC\u04AE\u04B0\u04B2\u04B4\u04B6\u04B8\u04BA\u04BC\u04BE\u04C0\u04C1\u04C3\u04C5\u04C7\u04C9\u04CB\u04CD\u04D0\u04D2\u04D4\u04D6\u04D8\u04DA\u04DC\u04DE\u04E0\u04E2\u04E4\u04E6\u04E8\u04EA\u04EC\u04EE\u04F0\u04F2\u04F4\u04F6\u04F8\u04FA\u04FC\u04FE\u0500\u0502\u0504\u0506\u0508\u050A\u050C\u050E\u0510\u0512\u0514\u0516\u0518\u051A\u051C\u051E\u0520\u0522\u0524\u0526\u0528\u052A\u052C\u052E\u0531-\u0556\u10A0-\u10C5\u10C7\u10CD\u13A0-\u13F5\u1E00\u1E02\u1E04\u1E06\u1E08\u1E0A\u1E0C\u1E0E\u1E10\u1E12\u1E14\u1E16\u1E18\u1E1A\u1E1C\u1E1E\u1E20\u1E22\u1E24\u1E26\u1E28\u1E2A\u1E2C\u1E2E\u1E30\u1E32\u1E34\u1E36\u1E38\u1E3A\u1E3C\u1E3E\u1E40\u1E42\u1E44\u1E46\u1E48\u1E4A\u1E4C\u1E4E\u1E50\u1E52\u1E54\u1E56\u1E58\u1E5A\u1E5C\u1E5E\u1E60\u1E62\u1E64\u1E66\u1E68\u1E6A\u1E6C\u1E6E\u1E70\u1E72\u1E74\u1E76\u1E78\u1E7A\u1E7C\u1E7E\u1E80\u1E82\u1E84\u1E86\u1E88\u1E8A\u1E8C\u1E8E\u1E90\u1E92\u1E94\u1E9E\u1EA0\u1EA2\u1EA4\u1EA6\u1EA8\u1EAA\u1EAC\u1EAE\u1EB0\u1EB2\u1EB4\u1EB6\u1EB8\u1EBA\u1EBC\u1EBE\u1EC0\u1EC2\u1EC4\u1EC6\u1EC8\u1ECA\u1ECC\u1ECE\u1ED0\u1ED2\u1ED4\u1ED6\u1ED8\u1EDA\u1EDC\u1EDE\u1EE0\u1EE2\u1EE4\u1EE6\u1EE8\u1EEA\u1EEC\u1EEE\u1EF0\u1EF2\u1EF4\u1EF6\u1EF8\u1EFA\u1EFC\u1EFE\u1F08-\u1F0F\u1F18-\u1F1D\u1F28-\u1F2F\u1F38-\u1F3F\u1F48-\u1F4D\u1F59\u1F5B\u1F5D\u1F5F\u1F68-\u1F6F\u1FB8-\u1FBB\u1FC8-\u1FCB\u1FD8-\u1FDB\u1FE8-\u1FEC\u1FF8-\u1FFB\u2102\u2107\u210B-\u210D\u2110-\u2112\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u2130-\u2133\u213E\u213F\u2145\u2183\u2C00-\u2C2E\u2C60\u2C62-\u2C64\u2C67\u2C69\u2C6B\u2C6D-\u2C70\u2C72\u2C75\u2C7E-\u2C80\u2C82\u2C84\u2C86\u2C88\u2C8A\u2C8C\u2C8E\u2C90\u2C92\u2C94\u2C96\u2C98\u2C9A\u2C9C\u2C9E\u2CA0\u2CA2\u2CA4\u2CA6\u2CA8\u2CAA\u2CAC\u2CAE\u2CB0\u2CB2\u2CB4\u2CB6\u2CB8\u2CBA\u2CBC\u2CBE\u2CC0\u2CC2\u2CC4\u2CC6\u2CC8\u2CCA\u2CCC\u2CCE\u2CD0\u2CD2\u2CD4\u2CD6\u2CD8\u2CDA\u2CDC\u2CDE\u2CE0\u2CE2\u2CEB\u2CED\u2CF2\uA640\uA642\uA644\uA646\uA648\uA64A\uA64C\uA64E\uA650\uA652\uA654\uA656\uA658\uA65A\uA65C\uA65E\uA660\uA662\uA664\uA666\uA668\uA66A\uA66C\uA680\uA682\uA684\uA686\uA688\uA68A\uA68C\uA68E\uA690\uA692\uA694\uA696\uA698\uA69A\uA722\uA724\uA726\uA728\uA72A\uA72C\uA72E\uA732\uA734\uA736\uA738\uA73A\uA73C\uA73E\uA740\uA742\uA744\uA746\uA748\uA74A\uA74C\uA74E\uA750\uA752\uA754\uA756\uA758\uA75A\uA75C\uA75E\uA760\uA762\uA764\uA766\uA768\uA76A\uA76C\uA76E\uA779\uA77B\uA77D\uA77E\uA780\uA782\uA784\uA786\uA78B\uA78D\uA790\uA792\uA796\uA798\uA79A\uA79C\uA79E\uA7A0\uA7A2\uA7A4\uA7A6\uA7A8\uA7AA-\uA7AD\uA7B0-\uA7B4\uA7B6\uFF21-\uFF3A])/g


/***/ }),
/* 464 */
/***/ (function(module, exports) {

module.exports = /([A-Z\xC0-\xD6\xD8-\xDE\u0100\u0102\u0104\u0106\u0108\u010A\u010C\u010E\u0110\u0112\u0114\u0116\u0118\u011A\u011C\u011E\u0120\u0122\u0124\u0126\u0128\u012A\u012C\u012E\u0130\u0132\u0134\u0136\u0139\u013B\u013D\u013F\u0141\u0143\u0145\u0147\u014A\u014C\u014E\u0150\u0152\u0154\u0156\u0158\u015A\u015C\u015E\u0160\u0162\u0164\u0166\u0168\u016A\u016C\u016E\u0170\u0172\u0174\u0176\u0178\u0179\u017B\u017D\u0181\u0182\u0184\u0186\u0187\u0189-\u018B\u018E-\u0191\u0193\u0194\u0196-\u0198\u019C\u019D\u019F\u01A0\u01A2\u01A4\u01A6\u01A7\u01A9\u01AC\u01AE\u01AF\u01B1-\u01B3\u01B5\u01B7\u01B8\u01BC\u01C4\u01C7\u01CA\u01CD\u01CF\u01D1\u01D3\u01D5\u01D7\u01D9\u01DB\u01DE\u01E0\u01E2\u01E4\u01E6\u01E8\u01EA\u01EC\u01EE\u01F1\u01F4\u01F6-\u01F8\u01FA\u01FC\u01FE\u0200\u0202\u0204\u0206\u0208\u020A\u020C\u020E\u0210\u0212\u0214\u0216\u0218\u021A\u021C\u021E\u0220\u0222\u0224\u0226\u0228\u022A\u022C\u022E\u0230\u0232\u023A\u023B\u023D\u023E\u0241\u0243-\u0246\u0248\u024A\u024C\u024E\u0370\u0372\u0376\u037F\u0386\u0388-\u038A\u038C\u038E\u038F\u0391-\u03A1\u03A3-\u03AB\u03CF\u03D2-\u03D4\u03D8\u03DA\u03DC\u03DE\u03E0\u03E2\u03E4\u03E6\u03E8\u03EA\u03EC\u03EE\u03F4\u03F7\u03F9\u03FA\u03FD-\u042F\u0460\u0462\u0464\u0466\u0468\u046A\u046C\u046E\u0470\u0472\u0474\u0476\u0478\u047A\u047C\u047E\u0480\u048A\u048C\u048E\u0490\u0492\u0494\u0496\u0498\u049A\u049C\u049E\u04A0\u04A2\u04A4\u04A6\u04A8\u04AA\u04AC\u04AE\u04B0\u04B2\u04B4\u04B6\u04B8\u04BA\u04BC\u04BE\u04C0\u04C1\u04C3\u04C5\u04C7\u04C9\u04CB\u04CD\u04D0\u04D2\u04D4\u04D6\u04D8\u04DA\u04DC\u04DE\u04E0\u04E2\u04E4\u04E6\u04E8\u04EA\u04EC\u04EE\u04F0\u04F2\u04F4\u04F6\u04F8\u04FA\u04FC\u04FE\u0500\u0502\u0504\u0506\u0508\u050A\u050C\u050E\u0510\u0512\u0514\u0516\u0518\u051A\u051C\u051E\u0520\u0522\u0524\u0526\u0528\u052A\u052C\u052E\u0531-\u0556\u10A0-\u10C5\u10C7\u10CD\u13A0-\u13F5\u1E00\u1E02\u1E04\u1E06\u1E08\u1E0A\u1E0C\u1E0E\u1E10\u1E12\u1E14\u1E16\u1E18\u1E1A\u1E1C\u1E1E\u1E20\u1E22\u1E24\u1E26\u1E28\u1E2A\u1E2C\u1E2E\u1E30\u1E32\u1E34\u1E36\u1E38\u1E3A\u1E3C\u1E3E\u1E40\u1E42\u1E44\u1E46\u1E48\u1E4A\u1E4C\u1E4E\u1E50\u1E52\u1E54\u1E56\u1E58\u1E5A\u1E5C\u1E5E\u1E60\u1E62\u1E64\u1E66\u1E68\u1E6A\u1E6C\u1E6E\u1E70\u1E72\u1E74\u1E76\u1E78\u1E7A\u1E7C\u1E7E\u1E80\u1E82\u1E84\u1E86\u1E88\u1E8A\u1E8C\u1E8E\u1E90\u1E92\u1E94\u1E9E\u1EA0\u1EA2\u1EA4\u1EA6\u1EA8\u1EAA\u1EAC\u1EAE\u1EB0\u1EB2\u1EB4\u1EB6\u1EB8\u1EBA\u1EBC\u1EBE\u1EC0\u1EC2\u1EC4\u1EC6\u1EC8\u1ECA\u1ECC\u1ECE\u1ED0\u1ED2\u1ED4\u1ED6\u1ED8\u1EDA\u1EDC\u1EDE\u1EE0\u1EE2\u1EE4\u1EE6\u1EE8\u1EEA\u1EEC\u1EEE\u1EF0\u1EF2\u1EF4\u1EF6\u1EF8\u1EFA\u1EFC\u1EFE\u1F08-\u1F0F\u1F18-\u1F1D\u1F28-\u1F2F\u1F38-\u1F3F\u1F48-\u1F4D\u1F59\u1F5B\u1F5D\u1F5F\u1F68-\u1F6F\u1FB8-\u1FBB\u1FC8-\u1FCB\u1FD8-\u1FDB\u1FE8-\u1FEC\u1FF8-\u1FFB\u2102\u2107\u210B-\u210D\u2110-\u2112\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u2130-\u2133\u213E\u213F\u2145\u2183\u2C00-\u2C2E\u2C60\u2C62-\u2C64\u2C67\u2C69\u2C6B\u2C6D-\u2C70\u2C72\u2C75\u2C7E-\u2C80\u2C82\u2C84\u2C86\u2C88\u2C8A\u2C8C\u2C8E\u2C90\u2C92\u2C94\u2C96\u2C98\u2C9A\u2C9C\u2C9E\u2CA0\u2CA2\u2CA4\u2CA6\u2CA8\u2CAA\u2CAC\u2CAE\u2CB0\u2CB2\u2CB4\u2CB6\u2CB8\u2CBA\u2CBC\u2CBE\u2CC0\u2CC2\u2CC4\u2CC6\u2CC8\u2CCA\u2CCC\u2CCE\u2CD0\u2CD2\u2CD4\u2CD6\u2CD8\u2CDA\u2CDC\u2CDE\u2CE0\u2CE2\u2CEB\u2CED\u2CF2\uA640\uA642\uA644\uA646\uA648\uA64A\uA64C\uA64E\uA650\uA652\uA654\uA656\uA658\uA65A\uA65C\uA65E\uA660\uA662\uA664\uA666\uA668\uA66A\uA66C\uA680\uA682\uA684\uA686\uA688\uA68A\uA68C\uA68E\uA690\uA692\uA694\uA696\uA698\uA69A\uA722\uA724\uA726\uA728\uA72A\uA72C\uA72E\uA732\uA734\uA736\uA738\uA73A\uA73C\uA73E\uA740\uA742\uA744\uA746\uA748\uA74A\uA74C\uA74E\uA750\uA752\uA754\uA756\uA758\uA75A\uA75C\uA75E\uA760\uA762\uA764\uA766\uA768\uA76A\uA76C\uA76E\uA779\uA77B\uA77D\uA77E\uA780\uA782\uA784\uA786\uA78B\uA78D\uA790\uA792\uA796\uA798\uA79A\uA79C\uA79E\uA7A0\uA7A2\uA7A4\uA7A6\uA7A8\uA7AA-\uA7AD\uA7B0-\uA7B4\uA7B6\uFF21-\uFF3A])([A-Z\xC0-\xD6\xD8-\xDE\u0100\u0102\u0104\u0106\u0108\u010A\u010C\u010E\u0110\u0112\u0114\u0116\u0118\u011A\u011C\u011E\u0120\u0122\u0124\u0126\u0128\u012A\u012C\u012E\u0130\u0132\u0134\u0136\u0139\u013B\u013D\u013F\u0141\u0143\u0145\u0147\u014A\u014C\u014E\u0150\u0152\u0154\u0156\u0158\u015A\u015C\u015E\u0160\u0162\u0164\u0166\u0168\u016A\u016C\u016E\u0170\u0172\u0174\u0176\u0178\u0179\u017B\u017D\u0181\u0182\u0184\u0186\u0187\u0189-\u018B\u018E-\u0191\u0193\u0194\u0196-\u0198\u019C\u019D\u019F\u01A0\u01A2\u01A4\u01A6\u01A7\u01A9\u01AC\u01AE\u01AF\u01B1-\u01B3\u01B5\u01B7\u01B8\u01BC\u01C4\u01C7\u01CA\u01CD\u01CF\u01D1\u01D3\u01D5\u01D7\u01D9\u01DB\u01DE\u01E0\u01E2\u01E4\u01E6\u01E8\u01EA\u01EC\u01EE\u01F1\u01F4\u01F6-\u01F8\u01FA\u01FC\u01FE\u0200\u0202\u0204\u0206\u0208\u020A\u020C\u020E\u0210\u0212\u0214\u0216\u0218\u021A\u021C\u021E\u0220\u0222\u0224\u0226\u0228\u022A\u022C\u022E\u0230\u0232\u023A\u023B\u023D\u023E\u0241\u0243-\u0246\u0248\u024A\u024C\u024E\u0370\u0372\u0376\u037F\u0386\u0388-\u038A\u038C\u038E\u038F\u0391-\u03A1\u03A3-\u03AB\u03CF\u03D2-\u03D4\u03D8\u03DA\u03DC\u03DE\u03E0\u03E2\u03E4\u03E6\u03E8\u03EA\u03EC\u03EE\u03F4\u03F7\u03F9\u03FA\u03FD-\u042F\u0460\u0462\u0464\u0466\u0468\u046A\u046C\u046E\u0470\u0472\u0474\u0476\u0478\u047A\u047C\u047E\u0480\u048A\u048C\u048E\u0490\u0492\u0494\u0496\u0498\u049A\u049C\u049E\u04A0\u04A2\u04A4\u04A6\u04A8\u04AA\u04AC\u04AE\u04B0\u04B2\u04B4\u04B6\u04B8\u04BA\u04BC\u04BE\u04C0\u04C1\u04C3\u04C5\u04C7\u04C9\u04CB\u04CD\u04D0\u04D2\u04D4\u04D6\u04D8\u04DA\u04DC\u04DE\u04E0\u04E2\u04E4\u04E6\u04E8\u04EA\u04EC\u04EE\u04F0\u04F2\u04F4\u04F6\u04F8\u04FA\u04FC\u04FE\u0500\u0502\u0504\u0506\u0508\u050A\u050C\u050E\u0510\u0512\u0514\u0516\u0518\u051A\u051C\u051E\u0520\u0522\u0524\u0526\u0528\u052A\u052C\u052E\u0531-\u0556\u10A0-\u10C5\u10C7\u10CD\u13A0-\u13F5\u1E00\u1E02\u1E04\u1E06\u1E08\u1E0A\u1E0C\u1E0E\u1E10\u1E12\u1E14\u1E16\u1E18\u1E1A\u1E1C\u1E1E\u1E20\u1E22\u1E24\u1E26\u1E28\u1E2A\u1E2C\u1E2E\u1E30\u1E32\u1E34\u1E36\u1E38\u1E3A\u1E3C\u1E3E\u1E40\u1E42\u1E44\u1E46\u1E48\u1E4A\u1E4C\u1E4E\u1E50\u1E52\u1E54\u1E56\u1E58\u1E5A\u1E5C\u1E5E\u1E60\u1E62\u1E64\u1E66\u1E68\u1E6A\u1E6C\u1E6E\u1E70\u1E72\u1E74\u1E76\u1E78\u1E7A\u1E7C\u1E7E\u1E80\u1E82\u1E84\u1E86\u1E88\u1E8A\u1E8C\u1E8E\u1E90\u1E92\u1E94\u1E9E\u1EA0\u1EA2\u1EA4\u1EA6\u1EA8\u1EAA\u1EAC\u1EAE\u1EB0\u1EB2\u1EB4\u1EB6\u1EB8\u1EBA\u1EBC\u1EBE\u1EC0\u1EC2\u1EC4\u1EC6\u1EC8\u1ECA\u1ECC\u1ECE\u1ED0\u1ED2\u1ED4\u1ED6\u1ED8\u1EDA\u1EDC\u1EDE\u1EE0\u1EE2\u1EE4\u1EE6\u1EE8\u1EEA\u1EEC\u1EEE\u1EF0\u1EF2\u1EF4\u1EF6\u1EF8\u1EFA\u1EFC\u1EFE\u1F08-\u1F0F\u1F18-\u1F1D\u1F28-\u1F2F\u1F38-\u1F3F\u1F48-\u1F4D\u1F59\u1F5B\u1F5D\u1F5F\u1F68-\u1F6F\u1FB8-\u1FBB\u1FC8-\u1FCB\u1FD8-\u1FDB\u1FE8-\u1FEC\u1FF8-\u1FFB\u2102\u2107\u210B-\u210D\u2110-\u2112\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u2130-\u2133\u213E\u213F\u2145\u2183\u2C00-\u2C2E\u2C60\u2C62-\u2C64\u2C67\u2C69\u2C6B\u2C6D-\u2C70\u2C72\u2C75\u2C7E-\u2C80\u2C82\u2C84\u2C86\u2C88\u2C8A\u2C8C\u2C8E\u2C90\u2C92\u2C94\u2C96\u2C98\u2C9A\u2C9C\u2C9E\u2CA0\u2CA2\u2CA4\u2CA6\u2CA8\u2CAA\u2CAC\u2CAE\u2CB0\u2CB2\u2CB4\u2CB6\u2CB8\u2CBA\u2CBC\u2CBE\u2CC0\u2CC2\u2CC4\u2CC6\u2CC8\u2CCA\u2CCC\u2CCE\u2CD0\u2CD2\u2CD4\u2CD6\u2CD8\u2CDA\u2CDC\u2CDE\u2CE0\u2CE2\u2CEB\u2CED\u2CF2\uA640\uA642\uA644\uA646\uA648\uA64A\uA64C\uA64E\uA650\uA652\uA654\uA656\uA658\uA65A\uA65C\uA65E\uA660\uA662\uA664\uA666\uA668\uA66A\uA66C\uA680\uA682\uA684\uA686\uA688\uA68A\uA68C\uA68E\uA690\uA692\uA694\uA696\uA698\uA69A\uA722\uA724\uA726\uA728\uA72A\uA72C\uA72E\uA732\uA734\uA736\uA738\uA73A\uA73C\uA73E\uA740\uA742\uA744\uA746\uA748\uA74A\uA74C\uA74E\uA750\uA752\uA754\uA756\uA758\uA75A\uA75C\uA75E\uA760\uA762\uA764\uA766\uA768\uA76A\uA76C\uA76E\uA779\uA77B\uA77D\uA77E\uA780\uA782\uA784\uA786\uA78B\uA78D\uA790\uA792\uA796\uA798\uA79A\uA79C\uA79E\uA7A0\uA7A2\uA7A4\uA7A6\uA7A8\uA7AA-\uA7AD\uA7B0-\uA7B4\uA7B6\uFF21-\uFF3A][a-z\xB5\xDF-\xF6\xF8-\xFF\u0101\u0103\u0105\u0107\u0109\u010B\u010D\u010F\u0111\u0113\u0115\u0117\u0119\u011B\u011D\u011F\u0121\u0123\u0125\u0127\u0129\u012B\u012D\u012F\u0131\u0133\u0135\u0137\u0138\u013A\u013C\u013E\u0140\u0142\u0144\u0146\u0148\u0149\u014B\u014D\u014F\u0151\u0153\u0155\u0157\u0159\u015B\u015D\u015F\u0161\u0163\u0165\u0167\u0169\u016B\u016D\u016F\u0171\u0173\u0175\u0177\u017A\u017C\u017E-\u0180\u0183\u0185\u0188\u018C\u018D\u0192\u0195\u0199-\u019B\u019E\u01A1\u01A3\u01A5\u01A8\u01AA\u01AB\u01AD\u01B0\u01B4\u01B6\u01B9\u01BA\u01BD-\u01BF\u01C6\u01C9\u01CC\u01CE\u01D0\u01D2\u01D4\u01D6\u01D8\u01DA\u01DC\u01DD\u01DF\u01E1\u01E3\u01E5\u01E7\u01E9\u01EB\u01ED\u01EF\u01F0\u01F3\u01F5\u01F9\u01FB\u01FD\u01FF\u0201\u0203\u0205\u0207\u0209\u020B\u020D\u020F\u0211\u0213\u0215\u0217\u0219\u021B\u021D\u021F\u0221\u0223\u0225\u0227\u0229\u022B\u022D\u022F\u0231\u0233-\u0239\u023C\u023F\u0240\u0242\u0247\u0249\u024B\u024D\u024F-\u0293\u0295-\u02AF\u0371\u0373\u0377\u037B-\u037D\u0390\u03AC-\u03CE\u03D0\u03D1\u03D5-\u03D7\u03D9\u03DB\u03DD\u03DF\u03E1\u03E3\u03E5\u03E7\u03E9\u03EB\u03ED\u03EF-\u03F3\u03F5\u03F8\u03FB\u03FC\u0430-\u045F\u0461\u0463\u0465\u0467\u0469\u046B\u046D\u046F\u0471\u0473\u0475\u0477\u0479\u047B\u047D\u047F\u0481\u048B\u048D\u048F\u0491\u0493\u0495\u0497\u0499\u049B\u049D\u049F\u04A1\u04A3\u04A5\u04A7\u04A9\u04AB\u04AD\u04AF\u04B1\u04B3\u04B5\u04B7\u04B9\u04BB\u04BD\u04BF\u04C2\u04C4\u04C6\u04C8\u04CA\u04CC\u04CE\u04CF\u04D1\u04D3\u04D5\u04D7\u04D9\u04DB\u04DD\u04DF\u04E1\u04E3\u04E5\u04E7\u04E9\u04EB\u04ED\u04EF\u04F1\u04F3\u04F5\u04F7\u04F9\u04FB\u04FD\u04FF\u0501\u0503\u0505\u0507\u0509\u050B\u050D\u050F\u0511\u0513\u0515\u0517\u0519\u051B\u051D\u051F\u0521\u0523\u0525\u0527\u0529\u052B\u052D\u052F\u0561-\u0587\u13F8-\u13FD\u1D00-\u1D2B\u1D6B-\u1D77\u1D79-\u1D9A\u1E01\u1E03\u1E05\u1E07\u1E09\u1E0B\u1E0D\u1E0F\u1E11\u1E13\u1E15\u1E17\u1E19\u1E1B\u1E1D\u1E1F\u1E21\u1E23\u1E25\u1E27\u1E29\u1E2B\u1E2D\u1E2F\u1E31\u1E33\u1E35\u1E37\u1E39\u1E3B\u1E3D\u1E3F\u1E41\u1E43\u1E45\u1E47\u1E49\u1E4B\u1E4D\u1E4F\u1E51\u1E53\u1E55\u1E57\u1E59\u1E5B\u1E5D\u1E5F\u1E61\u1E63\u1E65\u1E67\u1E69\u1E6B\u1E6D\u1E6F\u1E71\u1E73\u1E75\u1E77\u1E79\u1E7B\u1E7D\u1E7F\u1E81\u1E83\u1E85\u1E87\u1E89\u1E8B\u1E8D\u1E8F\u1E91\u1E93\u1E95-\u1E9D\u1E9F\u1EA1\u1EA3\u1EA5\u1EA7\u1EA9\u1EAB\u1EAD\u1EAF\u1EB1\u1EB3\u1EB5\u1EB7\u1EB9\u1EBB\u1EBD\u1EBF\u1EC1\u1EC3\u1EC5\u1EC7\u1EC9\u1ECB\u1ECD\u1ECF\u1ED1\u1ED3\u1ED5\u1ED7\u1ED9\u1EDB\u1EDD\u1EDF\u1EE1\u1EE3\u1EE5\u1EE7\u1EE9\u1EEB\u1EED\u1EEF\u1EF1\u1EF3\u1EF5\u1EF7\u1EF9\u1EFB\u1EFD\u1EFF-\u1F07\u1F10-\u1F15\u1F20-\u1F27\u1F30-\u1F37\u1F40-\u1F45\u1F50-\u1F57\u1F60-\u1F67\u1F70-\u1F7D\u1F80-\u1F87\u1F90-\u1F97\u1FA0-\u1FA7\u1FB0-\u1FB4\u1FB6\u1FB7\u1FBE\u1FC2-\u1FC4\u1FC6\u1FC7\u1FD0-\u1FD3\u1FD6\u1FD7\u1FE0-\u1FE7\u1FF2-\u1FF4\u1FF6\u1FF7\u210A\u210E\u210F\u2113\u212F\u2134\u2139\u213C\u213D\u2146-\u2149\u214E\u2184\u2C30-\u2C5E\u2C61\u2C65\u2C66\u2C68\u2C6A\u2C6C\u2C71\u2C73\u2C74\u2C76-\u2C7B\u2C81\u2C83\u2C85\u2C87\u2C89\u2C8B\u2C8D\u2C8F\u2C91\u2C93\u2C95\u2C97\u2C99\u2C9B\u2C9D\u2C9F\u2CA1\u2CA3\u2CA5\u2CA7\u2CA9\u2CAB\u2CAD\u2CAF\u2CB1\u2CB3\u2CB5\u2CB7\u2CB9\u2CBB\u2CBD\u2CBF\u2CC1\u2CC3\u2CC5\u2CC7\u2CC9\u2CCB\u2CCD\u2CCF\u2CD1\u2CD3\u2CD5\u2CD7\u2CD9\u2CDB\u2CDD\u2CDF\u2CE1\u2CE3\u2CE4\u2CEC\u2CEE\u2CF3\u2D00-\u2D25\u2D27\u2D2D\uA641\uA643\uA645\uA647\uA649\uA64B\uA64D\uA64F\uA651\uA653\uA655\uA657\uA659\uA65B\uA65D\uA65F\uA661\uA663\uA665\uA667\uA669\uA66B\uA66D\uA681\uA683\uA685\uA687\uA689\uA68B\uA68D\uA68F\uA691\uA693\uA695\uA697\uA699\uA69B\uA723\uA725\uA727\uA729\uA72B\uA72D\uA72F-\uA731\uA733\uA735\uA737\uA739\uA73B\uA73D\uA73F\uA741\uA743\uA745\uA747\uA749\uA74B\uA74D\uA74F\uA751\uA753\uA755\uA757\uA759\uA75B\uA75D\uA75F\uA761\uA763\uA765\uA767\uA769\uA76B\uA76D\uA76F\uA771-\uA778\uA77A\uA77C\uA77F\uA781\uA783\uA785\uA787\uA78C\uA78E\uA791\uA793-\uA795\uA797\uA799\uA79B\uA79D\uA79F\uA7A1\uA7A3\uA7A5\uA7A7\uA7A9\uA7B5\uA7B7\uA7FA\uAB30-\uAB5A\uAB60-\uAB65\uAB70-\uABBF\uFB00-\uFB06\uFB13-\uFB17\uFF41-\uFF5A])/g


/***/ }),
/* 465 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function range(low, high, step) {
  //  discuss at: http://locutus.io/php/range/
  // original by: Waldo Malqui Silva (http://waldo.malqui.info)
  //   example 1: range ( 0, 12 )
  //   returns 1: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]
  //   example 2: range( 0, 100, 10 )
  //   returns 2: [0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100]
  //   example 3: range( 'a', 'i' )
  //   returns 3: ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i']
  //   example 4: range( 'c', 'a' )
  //   returns 4: ['c', 'b', 'a']

  var matrix = [];
  var iVal;
  var endval;
  var plus;
  var walker = step || 1;
  var chars = false;

  if (!isNaN(low) && !isNaN(high)) {
    iVal = low;
    endval = high;
  } else if (isNaN(low) && isNaN(high)) {
    chars = true;
    iVal = low.charCodeAt(0);
    endval = high.charCodeAt(0);
  } else {
    iVal = isNaN(low) ? 0 : low;
    endval = isNaN(high) ? 0 : high;
  }

  plus = !(iVal > endval);
  if (plus) {
    while (iVal <= endval) {
      matrix.push(chars ? String.fromCharCode(iVal) : iVal);
      iVal += walker;
    }
  } else {
    while (iVal >= endval) {
      matrix.push(chars ? String.fromCharCode(iVal) : iVal);
      iVal -= walker;
    }
  }

  return matrix;
};
//# sourceMappingURL=range.js.map

/***/ }),
/* 466 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Copyright 2009-2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE.txt or:
 * http://opensource.org/licenses/BSD-3-Clause
 */
exports.SourceMapGenerator = __webpack_require__(330).SourceMapGenerator;
exports.SourceMapConsumer = __webpack_require__(469).SourceMapConsumer;
exports.SourceNode = __webpack_require__(472).SourceNode;


/***/ }),
/* 467 */
/***/ (function(module, exports) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

var intToCharMap = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'.split('');

/**
 * Encode an integer in the range of 0 to 63 to a single base 64 digit.
 */
exports.encode = function (number) {
  if (0 <= number && number < intToCharMap.length) {
    return intToCharMap[number];
  }
  throw new TypeError("Must be between 0 and 63: " + number);
};

/**
 * Decode a single base 64 character code digit to an integer. Returns -1 on
 * failure.
 */
exports.decode = function (charCode) {
  var bigA = 65;     // 'A'
  var bigZ = 90;     // 'Z'

  var littleA = 97;  // 'a'
  var littleZ = 122; // 'z'

  var zero = 48;     // '0'
  var nine = 57;     // '9'

  var plus = 43;     // '+'
  var slash = 47;    // '/'

  var littleOffset = 26;
  var numberOffset = 52;

  // 0 - 25: ABCDEFGHIJKLMNOPQRSTUVWXYZ
  if (bigA <= charCode && charCode <= bigZ) {
    return (charCode - bigA);
  }

  // 26 - 51: abcdefghijklmnopqrstuvwxyz
  if (littleA <= charCode && charCode <= littleZ) {
    return (charCode - littleA + littleOffset);
  }

  // 52 - 61: 0123456789
  if (zero <= charCode && charCode <= nine) {
    return (charCode - zero + numberOffset);
  }

  // 62: +
  if (charCode == plus) {
    return 62;
  }

  // 63: /
  if (charCode == slash) {
    return 63;
  }

  // Invalid base64 digit.
  return -1;
};


/***/ }),
/* 468 */
/***/ (function(module, exports, __webpack_require__) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2014 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

var util = __webpack_require__(141);

/**
 * Determine whether mappingB is after mappingA with respect to generated
 * position.
 */
function generatedPositionAfter(mappingA, mappingB) {
  // Optimized for most common case
  var lineA = mappingA.generatedLine;
  var lineB = mappingB.generatedLine;
  var columnA = mappingA.generatedColumn;
  var columnB = mappingB.generatedColumn;
  return lineB > lineA || lineB == lineA && columnB >= columnA ||
         util.compareByGeneratedPositionsInflated(mappingA, mappingB) <= 0;
}

/**
 * A data structure to provide a sorted view of accumulated mappings in a
 * performance conscious manner. It trades a neglibable overhead in general
 * case for a large speedup in case of mappings being added in order.
 */
function MappingList() {
  this._array = [];
  this._sorted = true;
  // Serves as infimum
  this._last = {generatedLine: -1, generatedColumn: 0};
}

/**
 * Iterate through internal items. This method takes the same arguments that
 * `Array.prototype.forEach` takes.
 *
 * NOTE: The order of the mappings is NOT guaranteed.
 */
MappingList.prototype.unsortedForEach =
  function MappingList_forEach(aCallback, aThisArg) {
    this._array.forEach(aCallback, aThisArg);
  };

/**
 * Add the given source mapping.
 *
 * @param Object aMapping
 */
MappingList.prototype.add = function MappingList_add(aMapping) {
  if (generatedPositionAfter(this._last, aMapping)) {
    this._last = aMapping;
    this._array.push(aMapping);
  } else {
    this._sorted = false;
    this._array.push(aMapping);
  }
};

/**
 * Returns the flat, sorted array of mappings. The mappings are sorted by
 * generated position.
 *
 * WARNING: This method returns internal data without copying, for
 * performance. The return value must NOT be mutated, and should be treated as
 * an immutable borrow. If you want to take ownership, you must make your own
 * copy.
 */
MappingList.prototype.toArray = function MappingList_toArray() {
  if (!this._sorted) {
    this._array.sort(util.compareByGeneratedPositionsInflated);
    this._sorted = true;
  }
  return this._array;
};

exports.MappingList = MappingList;


/***/ }),
/* 469 */
/***/ (function(module, exports, __webpack_require__) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

var util = __webpack_require__(141);
var binarySearch = __webpack_require__(470);
var ArraySet = __webpack_require__(332).ArraySet;
var base64VLQ = __webpack_require__(331);
var quickSort = __webpack_require__(471).quickSort;

function SourceMapConsumer(aSourceMap, aSourceMapURL) {
  var sourceMap = aSourceMap;
  if (typeof aSourceMap === 'string') {
    sourceMap = util.parseSourceMapInput(aSourceMap);
  }

  return sourceMap.sections != null
    ? new IndexedSourceMapConsumer(sourceMap, aSourceMapURL)
    : new BasicSourceMapConsumer(sourceMap, aSourceMapURL);
}

SourceMapConsumer.fromSourceMap = function(aSourceMap, aSourceMapURL) {
  return BasicSourceMapConsumer.fromSourceMap(aSourceMap, aSourceMapURL);
}

/**
 * The version of the source mapping spec that we are consuming.
 */
SourceMapConsumer.prototype._version = 3;

// `__generatedMappings` and `__originalMappings` are arrays that hold the
// parsed mapping coordinates from the source map's "mappings" attribute. They
// are lazily instantiated, accessed via the `_generatedMappings` and
// `_originalMappings` getters respectively, and we only parse the mappings
// and create these arrays once queried for a source location. We jump through
// these hoops because there can be many thousands of mappings, and parsing
// them is expensive, so we only want to do it if we must.
//
// Each object in the arrays is of the form:
//
//     {
//       generatedLine: The line number in the generated code,
//       generatedColumn: The column number in the generated code,
//       source: The path to the original source file that generated this
//               chunk of code,
//       originalLine: The line number in the original source that
//                     corresponds to this chunk of generated code,
//       originalColumn: The column number in the original source that
//                       corresponds to this chunk of generated code,
//       name: The name of the original symbol which generated this chunk of
//             code.
//     }
//
// All properties except for `generatedLine` and `generatedColumn` can be
// `null`.
//
// `_generatedMappings` is ordered by the generated positions.
//
// `_originalMappings` is ordered by the original positions.

SourceMapConsumer.prototype.__generatedMappings = null;
Object.defineProperty(SourceMapConsumer.prototype, '_generatedMappings', {
  configurable: true,
  enumerable: true,
  get: function () {
    if (!this.__generatedMappings) {
      this._parseMappings(this._mappings, this.sourceRoot);
    }

    return this.__generatedMappings;
  }
});

SourceMapConsumer.prototype.__originalMappings = null;
Object.defineProperty(SourceMapConsumer.prototype, '_originalMappings', {
  configurable: true,
  enumerable: true,
  get: function () {
    if (!this.__originalMappings) {
      this._parseMappings(this._mappings, this.sourceRoot);
    }

    return this.__originalMappings;
  }
});

SourceMapConsumer.prototype._charIsMappingSeparator =
  function SourceMapConsumer_charIsMappingSeparator(aStr, index) {
    var c = aStr.charAt(index);
    return c === ";" || c === ",";
  };

/**
 * Parse the mappings in a string in to a data structure which we can easily
 * query (the ordered arrays in the `this.__generatedMappings` and
 * `this.__originalMappings` properties).
 */
SourceMapConsumer.prototype._parseMappings =
  function SourceMapConsumer_parseMappings(aStr, aSourceRoot) {
    throw new Error("Subclasses must implement _parseMappings");
  };

SourceMapConsumer.GENERATED_ORDER = 1;
SourceMapConsumer.ORIGINAL_ORDER = 2;

SourceMapConsumer.GREATEST_LOWER_BOUND = 1;
SourceMapConsumer.LEAST_UPPER_BOUND = 2;

/**
 * Iterate over each mapping between an original source/line/column and a
 * generated line/column in this source map.
 *
 * @param Function aCallback
 *        The function that is called with each mapping.
 * @param Object aContext
 *        Optional. If specified, this object will be the value of `this` every
 *        time that `aCallback` is called.
 * @param aOrder
 *        Either `SourceMapConsumer.GENERATED_ORDER` or
 *        `SourceMapConsumer.ORIGINAL_ORDER`. Specifies whether you want to
 *        iterate over the mappings sorted by the generated file's line/column
 *        order or the original's source/line/column order, respectively. Defaults to
 *        `SourceMapConsumer.GENERATED_ORDER`.
 */
SourceMapConsumer.prototype.eachMapping =
  function SourceMapConsumer_eachMapping(aCallback, aContext, aOrder) {
    var context = aContext || null;
    var order = aOrder || SourceMapConsumer.GENERATED_ORDER;

    var mappings;
    switch (order) {
    case SourceMapConsumer.GENERATED_ORDER:
      mappings = this._generatedMappings;
      break;
    case SourceMapConsumer.ORIGINAL_ORDER:
      mappings = this._originalMappings;
      break;
    default:
      throw new Error("Unknown order of iteration.");
    }

    var sourceRoot = this.sourceRoot;
    mappings.map(function (mapping) {
      var source = mapping.source === null ? null : this._sources.at(mapping.source);
      source = util.computeSourceURL(sourceRoot, source, this._sourceMapURL);
      return {
        source: source,
        generatedLine: mapping.generatedLine,
        generatedColumn: mapping.generatedColumn,
        originalLine: mapping.originalLine,
        originalColumn: mapping.originalColumn,
        name: mapping.name === null ? null : this._names.at(mapping.name)
      };
    }, this).forEach(aCallback, context);
  };

/**
 * Returns all generated line and column information for the original source,
 * line, and column provided. If no column is provided, returns all mappings
 * corresponding to a either the line we are searching for or the next
 * closest line that has any mappings. Otherwise, returns all mappings
 * corresponding to the given line and either the column we are searching for
 * or the next closest column that has any offsets.
 *
 * The only argument is an object with the following properties:
 *
 *   - source: The filename of the original source.
 *   - line: The line number in the original source.  The line number is 1-based.
 *   - column: Optional. the column number in the original source.
 *    The column number is 0-based.
 *
 * and an array of objects is returned, each with the following properties:
 *
 *   - line: The line number in the generated source, or null.  The
 *    line number is 1-based.
 *   - column: The column number in the generated source, or null.
 *    The column number is 0-based.
 */
SourceMapConsumer.prototype.allGeneratedPositionsFor =
  function SourceMapConsumer_allGeneratedPositionsFor(aArgs) {
    var line = util.getArg(aArgs, 'line');

    // When there is no exact match, BasicSourceMapConsumer.prototype._findMapping
    // returns the index of the closest mapping less than the needle. By
    // setting needle.originalColumn to 0, we thus find the last mapping for
    // the given line, provided such a mapping exists.
    var needle = {
      source: util.getArg(aArgs, 'source'),
      originalLine: line,
      originalColumn: util.getArg(aArgs, 'column', 0)
    };

    needle.source = this._findSourceIndex(needle.source);
    if (needle.source < 0) {
      return [];
    }

    var mappings = [];

    var index = this._findMapping(needle,
                                  this._originalMappings,
                                  "originalLine",
                                  "originalColumn",
                                  util.compareByOriginalPositions,
                                  binarySearch.LEAST_UPPER_BOUND);
    if (index >= 0) {
      var mapping = this._originalMappings[index];

      if (aArgs.column === undefined) {
        var originalLine = mapping.originalLine;

        // Iterate until either we run out of mappings, or we run into
        // a mapping for a different line than the one we found. Since
        // mappings are sorted, this is guaranteed to find all mappings for
        // the line we found.
        while (mapping && mapping.originalLine === originalLine) {
          mappings.push({
            line: util.getArg(mapping, 'generatedLine', null),
            column: util.getArg(mapping, 'generatedColumn', null),
            lastColumn: util.getArg(mapping, 'lastGeneratedColumn', null)
          });

          mapping = this._originalMappings[++index];
        }
      } else {
        var originalColumn = mapping.originalColumn;

        // Iterate until either we run out of mappings, or we run into
        // a mapping for a different line than the one we were searching for.
        // Since mappings are sorted, this is guaranteed to find all mappings for
        // the line we are searching for.
        while (mapping &&
               mapping.originalLine === line &&
               mapping.originalColumn == originalColumn) {
          mappings.push({
            line: util.getArg(mapping, 'generatedLine', null),
            column: util.getArg(mapping, 'generatedColumn', null),
            lastColumn: util.getArg(mapping, 'lastGeneratedColumn', null)
          });

          mapping = this._originalMappings[++index];
        }
      }
    }

    return mappings;
  };

exports.SourceMapConsumer = SourceMapConsumer;

/**
 * A BasicSourceMapConsumer instance represents a parsed source map which we can
 * query for information about the original file positions by giving it a file
 * position in the generated source.
 *
 * The first parameter is the raw source map (either as a JSON string, or
 * already parsed to an object). According to the spec, source maps have the
 * following attributes:
 *
 *   - version: Which version of the source map spec this map is following.
 *   - sources: An array of URLs to the original source files.
 *   - names: An array of identifiers which can be referrenced by individual mappings.
 *   - sourceRoot: Optional. The URL root from which all sources are relative.
 *   - sourcesContent: Optional. An array of contents of the original source files.
 *   - mappings: A string of base64 VLQs which contain the actual mappings.
 *   - file: Optional. The generated file this source map is associated with.
 *
 * Here is an example source map, taken from the source map spec[0]:
 *
 *     {
 *       version : 3,
 *       file: "out.js",
 *       sourceRoot : "",
 *       sources: ["foo.js", "bar.js"],
 *       names: ["src", "maps", "are", "fun"],
 *       mappings: "AA,AB;;ABCDE;"
 *     }
 *
 * The second parameter, if given, is a string whose value is the URL
 * at which the source map was found.  This URL is used to compute the
 * sources array.
 *
 * [0]: https://docs.google.com/document/d/1U1RGAehQwRypUTovF1KRlpiOFze0b-_2gc6fAH0KY0k/edit?pli=1#
 */
function BasicSourceMapConsumer(aSourceMap, aSourceMapURL) {
  var sourceMap = aSourceMap;
  if (typeof aSourceMap === 'string') {
    sourceMap = util.parseSourceMapInput(aSourceMap);
  }

  var version = util.getArg(sourceMap, 'version');
  var sources = util.getArg(sourceMap, 'sources');
  // Sass 3.3 leaves out the 'names' array, so we deviate from the spec (which
  // requires the array) to play nice here.
  var names = util.getArg(sourceMap, 'names', []);
  var sourceRoot = util.getArg(sourceMap, 'sourceRoot', null);
  var sourcesContent = util.getArg(sourceMap, 'sourcesContent', null);
  var mappings = util.getArg(sourceMap, 'mappings');
  var file = util.getArg(sourceMap, 'file', null);

  // Once again, Sass deviates from the spec and supplies the version as a
  // string rather than a number, so we use loose equality checking here.
  if (version != this._version) {
    throw new Error('Unsupported version: ' + version);
  }

  if (sourceRoot) {
    sourceRoot = util.normalize(sourceRoot);
  }

  sources = sources
    .map(String)
    // Some source maps produce relative source paths like "./foo.js" instead of
    // "foo.js".  Normalize these first so that future comparisons will succeed.
    // See bugzil.la/1090768.
    .map(util.normalize)
    // Always ensure that absolute sources are internally stored relative to
    // the source root, if the source root is absolute. Not doing this would
    // be particularly problematic when the source root is a prefix of the
    // source (valid, but why??). See github issue #199 and bugzil.la/1188982.
    .map(function (source) {
      return sourceRoot && util.isAbsolute(sourceRoot) && util.isAbsolute(source)
        ? util.relative(sourceRoot, source)
        : source;
    });

  // Pass `true` below to allow duplicate names and sources. While source maps
  // are intended to be compressed and deduplicated, the TypeScript compiler
  // sometimes generates source maps with duplicates in them. See Github issue
  // #72 and bugzil.la/889492.
  this._names = ArraySet.fromArray(names.map(String), true);
  this._sources = ArraySet.fromArray(sources, true);

  this._absoluteSources = this._sources.toArray().map(function (s) {
    return util.computeSourceURL(sourceRoot, s, aSourceMapURL);
  });

  this.sourceRoot = sourceRoot;
  this.sourcesContent = sourcesContent;
  this._mappings = mappings;
  this._sourceMapURL = aSourceMapURL;
  this.file = file;
}

BasicSourceMapConsumer.prototype = Object.create(SourceMapConsumer.prototype);
BasicSourceMapConsumer.prototype.consumer = SourceMapConsumer;

/**
 * Utility function to find the index of a source.  Returns -1 if not
 * found.
 */
BasicSourceMapConsumer.prototype._findSourceIndex = function(aSource) {
  var relativeSource = aSource;
  if (this.sourceRoot != null) {
    relativeSource = util.relative(this.sourceRoot, relativeSource);
  }

  if (this._sources.has(relativeSource)) {
    return this._sources.indexOf(relativeSource);
  }

  // Maybe aSource is an absolute URL as returned by |sources|.  In
  // this case we can't simply undo the transform.
  var i;
  for (i = 0; i < this._absoluteSources.length; ++i) {
    if (this._absoluteSources[i] == aSource) {
      return i;
    }
  }

  return -1;
};

/**
 * Create a BasicSourceMapConsumer from a SourceMapGenerator.
 *
 * @param SourceMapGenerator aSourceMap
 *        The source map that will be consumed.
 * @param String aSourceMapURL
 *        The URL at which the source map can be found (optional)
 * @returns BasicSourceMapConsumer
 */
BasicSourceMapConsumer.fromSourceMap =
  function SourceMapConsumer_fromSourceMap(aSourceMap, aSourceMapURL) {
    var smc = Object.create(BasicSourceMapConsumer.prototype);

    var names = smc._names = ArraySet.fromArray(aSourceMap._names.toArray(), true);
    var sources = smc._sources = ArraySet.fromArray(aSourceMap._sources.toArray(), true);
    smc.sourceRoot = aSourceMap._sourceRoot;
    smc.sourcesContent = aSourceMap._generateSourcesContent(smc._sources.toArray(),
                                                            smc.sourceRoot);
    smc.file = aSourceMap._file;
    smc._sourceMapURL = aSourceMapURL;
    smc._absoluteSources = smc._sources.toArray().map(function (s) {
      return util.computeSourceURL(smc.sourceRoot, s, aSourceMapURL);
    });

    // Because we are modifying the entries (by converting string sources and
    // names to indices into the sources and names ArraySets), we have to make
    // a copy of the entry or else bad things happen. Shared mutable state
    // strikes again! See github issue #191.

    var generatedMappings = aSourceMap._mappings.toArray().slice();
    var destGeneratedMappings = smc.__generatedMappings = [];
    var destOriginalMappings = smc.__originalMappings = [];

    for (var i = 0, length = generatedMappings.length; i < length; i++) {
      var srcMapping = generatedMappings[i];
      var destMapping = new Mapping;
      destMapping.generatedLine = srcMapping.generatedLine;
      destMapping.generatedColumn = srcMapping.generatedColumn;

      if (srcMapping.source) {
        destMapping.source = sources.indexOf(srcMapping.source);
        destMapping.originalLine = srcMapping.originalLine;
        destMapping.originalColumn = srcMapping.originalColumn;

        if (srcMapping.name) {
          destMapping.name = names.indexOf(srcMapping.name);
        }

        destOriginalMappings.push(destMapping);
      }

      destGeneratedMappings.push(destMapping);
    }

    quickSort(smc.__originalMappings, util.compareByOriginalPositions);

    return smc;
  };

/**
 * The version of the source mapping spec that we are consuming.
 */
BasicSourceMapConsumer.prototype._version = 3;

/**
 * The list of original sources.
 */
Object.defineProperty(BasicSourceMapConsumer.prototype, 'sources', {
  get: function () {
    return this._absoluteSources.slice();
  }
});

/**
 * Provide the JIT with a nice shape / hidden class.
 */
function Mapping() {
  this.generatedLine = 0;
  this.generatedColumn = 0;
  this.source = null;
  this.originalLine = null;
  this.originalColumn = null;
  this.name = null;
}

/**
 * Parse the mappings in a string in to a data structure which we can easily
 * query (the ordered arrays in the `this.__generatedMappings` and
 * `this.__originalMappings` properties).
 */
BasicSourceMapConsumer.prototype._parseMappings =
  function SourceMapConsumer_parseMappings(aStr, aSourceRoot) {
    var generatedLine = 1;
    var previousGeneratedColumn = 0;
    var previousOriginalLine = 0;
    var previousOriginalColumn = 0;
    var previousSource = 0;
    var previousName = 0;
    var length = aStr.length;
    var index = 0;
    var cachedSegments = {};
    var temp = {};
    var originalMappings = [];
    var generatedMappings = [];
    var mapping, str, segment, end, value;

    while (index < length) {
      if (aStr.charAt(index) === ';') {
        generatedLine++;
        index++;
        previousGeneratedColumn = 0;
      }
      else if (aStr.charAt(index) === ',') {
        index++;
      }
      else {
        mapping = new Mapping();
        mapping.generatedLine = generatedLine;

        // Because each offset is encoded relative to the previous one,
        // many segments often have the same encoding. We can exploit this
        // fact by caching the parsed variable length fields of each segment,
        // allowing us to avoid a second parse if we encounter the same
        // segment again.
        for (end = index; end < length; end++) {
          if (this._charIsMappingSeparator(aStr, end)) {
            break;
          }
        }
        str = aStr.slice(index, end);

        segment = cachedSegments[str];
        if (segment) {
          index += str.length;
        } else {
          segment = [];
          while (index < end) {
            base64VLQ.decode(aStr, index, temp);
            value = temp.value;
            index = temp.rest;
            segment.push(value);
          }

          if (segment.length === 2) {
            throw new Error('Found a source, but no line and column');
          }

          if (segment.length === 3) {
            throw new Error('Found a source and line, but no column');
          }

          cachedSegments[str] = segment;
        }

        // Generated column.
        mapping.generatedColumn = previousGeneratedColumn + segment[0];
        previousGeneratedColumn = mapping.generatedColumn;

        if (segment.length > 1) {
          // Original source.
          mapping.source = previousSource + segment[1];
          previousSource += segment[1];

          // Original line.
          mapping.originalLine = previousOriginalLine + segment[2];
          previousOriginalLine = mapping.originalLine;
          // Lines are stored 0-based
          mapping.originalLine += 1;

          // Original column.
          mapping.originalColumn = previousOriginalColumn + segment[3];
          previousOriginalColumn = mapping.originalColumn;

          if (segment.length > 4) {
            // Original name.
            mapping.name = previousName + segment[4];
            previousName += segment[4];
          }
        }

        generatedMappings.push(mapping);
        if (typeof mapping.originalLine === 'number') {
          originalMappings.push(mapping);
        }
      }
    }

    quickSort(generatedMappings, util.compareByGeneratedPositionsDeflated);
    this.__generatedMappings = generatedMappings;

    quickSort(originalMappings, util.compareByOriginalPositions);
    this.__originalMappings = originalMappings;
  };

/**
 * Find the mapping that best matches the hypothetical "needle" mapping that
 * we are searching for in the given "haystack" of mappings.
 */
BasicSourceMapConsumer.prototype._findMapping =
  function SourceMapConsumer_findMapping(aNeedle, aMappings, aLineName,
                                         aColumnName, aComparator, aBias) {
    // To return the position we are searching for, we must first find the
    // mapping for the given position and then return the opposite position it
    // points to. Because the mappings are sorted, we can use binary search to
    // find the best mapping.

    if (aNeedle[aLineName] <= 0) {
      throw new TypeError('Line must be greater than or equal to 1, got '
                          + aNeedle[aLineName]);
    }
    if (aNeedle[aColumnName] < 0) {
      throw new TypeError('Column must be greater than or equal to 0, got '
                          + aNeedle[aColumnName]);
    }

    return binarySearch.search(aNeedle, aMappings, aComparator, aBias);
  };

/**
 * Compute the last column for each generated mapping. The last column is
 * inclusive.
 */
BasicSourceMapConsumer.prototype.computeColumnSpans =
  function SourceMapConsumer_computeColumnSpans() {
    for (var index = 0; index < this._generatedMappings.length; ++index) {
      var mapping = this._generatedMappings[index];

      // Mappings do not contain a field for the last generated columnt. We
      // can come up with an optimistic estimate, however, by assuming that
      // mappings are contiguous (i.e. given two consecutive mappings, the
      // first mapping ends where the second one starts).
      if (index + 1 < this._generatedMappings.length) {
        var nextMapping = this._generatedMappings[index + 1];

        if (mapping.generatedLine === nextMapping.generatedLine) {
          mapping.lastGeneratedColumn = nextMapping.generatedColumn - 1;
          continue;
        }
      }

      // The last mapping for each line spans the entire line.
      mapping.lastGeneratedColumn = Infinity;
    }
  };

/**
 * Returns the original source, line, and column information for the generated
 * source's line and column positions provided. The only argument is an object
 * with the following properties:
 *
 *   - line: The line number in the generated source.  The line number
 *     is 1-based.
 *   - column: The column number in the generated source.  The column
 *     number is 0-based.
 *   - bias: Either 'SourceMapConsumer.GREATEST_LOWER_BOUND' or
 *     'SourceMapConsumer.LEAST_UPPER_BOUND'. Specifies whether to return the
 *     closest element that is smaller than or greater than the one we are
 *     searching for, respectively, if the exact element cannot be found.
 *     Defaults to 'SourceMapConsumer.GREATEST_LOWER_BOUND'.
 *
 * and an object is returned with the following properties:
 *
 *   - source: The original source file, or null.
 *   - line: The line number in the original source, or null.  The
 *     line number is 1-based.
 *   - column: The column number in the original source, or null.  The
 *     column number is 0-based.
 *   - name: The original identifier, or null.
 */
BasicSourceMapConsumer.prototype.originalPositionFor =
  function SourceMapConsumer_originalPositionFor(aArgs) {
    var needle = {
      generatedLine: util.getArg(aArgs, 'line'),
      generatedColumn: util.getArg(aArgs, 'column')
    };

    var index = this._findMapping(
      needle,
      this._generatedMappings,
      "generatedLine",
      "generatedColumn",
      util.compareByGeneratedPositionsDeflated,
      util.getArg(aArgs, 'bias', SourceMapConsumer.GREATEST_LOWER_BOUND)
    );

    if (index >= 0) {
      var mapping = this._generatedMappings[index];

      if (mapping.generatedLine === needle.generatedLine) {
        var source = util.getArg(mapping, 'source', null);
        if (source !== null) {
          source = this._sources.at(source);
          source = util.computeSourceURL(this.sourceRoot, source, this._sourceMapURL);
        }
        var name = util.getArg(mapping, 'name', null);
        if (name !== null) {
          name = this._names.at(name);
        }
        return {
          source: source,
          line: util.getArg(mapping, 'originalLine', null),
          column: util.getArg(mapping, 'originalColumn', null),
          name: name
        };
      }
    }

    return {
      source: null,
      line: null,
      column: null,
      name: null
    };
  };

/**
 * Return true if we have the source content for every source in the source
 * map, false otherwise.
 */
BasicSourceMapConsumer.prototype.hasContentsOfAllSources =
  function BasicSourceMapConsumer_hasContentsOfAllSources() {
    if (!this.sourcesContent) {
      return false;
    }
    return this.sourcesContent.length >= this._sources.size() &&
      !this.sourcesContent.some(function (sc) { return sc == null; });
  };

/**
 * Returns the original source content. The only argument is the url of the
 * original source file. Returns null if no original source content is
 * available.
 */
BasicSourceMapConsumer.prototype.sourceContentFor =
  function SourceMapConsumer_sourceContentFor(aSource, nullOnMissing) {
    if (!this.sourcesContent) {
      return null;
    }

    var index = this._findSourceIndex(aSource);
    if (index >= 0) {
      return this.sourcesContent[index];
    }

    var relativeSource = aSource;
    if (this.sourceRoot != null) {
      relativeSource = util.relative(this.sourceRoot, relativeSource);
    }

    var url;
    if (this.sourceRoot != null
        && (url = util.urlParse(this.sourceRoot))) {
      // XXX: file:// URIs and absolute paths lead to unexpected behavior for
      // many users. We can help them out when they expect file:// URIs to
      // behave like it would if they were running a local HTTP server. See
      // https://bugzilla.mozilla.org/show_bug.cgi?id=885597.
      var fileUriAbsPath = relativeSource.replace(/^file:\/\//, "");
      if (url.scheme == "file"
          && this._sources.has(fileUriAbsPath)) {
        return this.sourcesContent[this._sources.indexOf(fileUriAbsPath)]
      }

      if ((!url.path || url.path == "/")
          && this._sources.has("/" + relativeSource)) {
        return this.sourcesContent[this._sources.indexOf("/" + relativeSource)];
      }
    }

    // This function is used recursively from
    // IndexedSourceMapConsumer.prototype.sourceContentFor. In that case, we
    // don't want to throw if we can't find the source - we just want to
    // return null, so we provide a flag to exit gracefully.
    if (nullOnMissing) {
      return null;
    }
    else {
      throw new Error('"' + relativeSource + '" is not in the SourceMap.');
    }
  };

/**
 * Returns the generated line and column information for the original source,
 * line, and column positions provided. The only argument is an object with
 * the following properties:
 *
 *   - source: The filename of the original source.
 *   - line: The line number in the original source.  The line number
 *     is 1-based.
 *   - column: The column number in the original source.  The column
 *     number is 0-based.
 *   - bias: Either 'SourceMapConsumer.GREATEST_LOWER_BOUND' or
 *     'SourceMapConsumer.LEAST_UPPER_BOUND'. Specifies whether to return the
 *     closest element that is smaller than or greater than the one we are
 *     searching for, respectively, if the exact element cannot be found.
 *     Defaults to 'SourceMapConsumer.GREATEST_LOWER_BOUND'.
 *
 * and an object is returned with the following properties:
 *
 *   - line: The line number in the generated source, or null.  The
 *     line number is 1-based.
 *   - column: The column number in the generated source, or null.
 *     The column number is 0-based.
 */
BasicSourceMapConsumer.prototype.generatedPositionFor =
  function SourceMapConsumer_generatedPositionFor(aArgs) {
    var source = util.getArg(aArgs, 'source');
    source = this._findSourceIndex(source);
    if (source < 0) {
      return {
        line: null,
        column: null,
        lastColumn: null
      };
    }

    var needle = {
      source: source,
      originalLine: util.getArg(aArgs, 'line'),
      originalColumn: util.getArg(aArgs, 'column')
    };

    var index = this._findMapping(
      needle,
      this._originalMappings,
      "originalLine",
      "originalColumn",
      util.compareByOriginalPositions,
      util.getArg(aArgs, 'bias', SourceMapConsumer.GREATEST_LOWER_BOUND)
    );

    if (index >= 0) {
      var mapping = this._originalMappings[index];

      if (mapping.source === needle.source) {
        return {
          line: util.getArg(mapping, 'generatedLine', null),
          column: util.getArg(mapping, 'generatedColumn', null),
          lastColumn: util.getArg(mapping, 'lastGeneratedColumn', null)
        };
      }
    }

    return {
      line: null,
      column: null,
      lastColumn: null
    };
  };

exports.BasicSourceMapConsumer = BasicSourceMapConsumer;

/**
 * An IndexedSourceMapConsumer instance represents a parsed source map which
 * we can query for information. It differs from BasicSourceMapConsumer in
 * that it takes "indexed" source maps (i.e. ones with a "sections" field) as
 * input.
 *
 * The first parameter is a raw source map (either as a JSON string, or already
 * parsed to an object). According to the spec for indexed source maps, they
 * have the following attributes:
 *
 *   - version: Which version of the source map spec this map is following.
 *   - file: Optional. The generated file this source map is associated with.
 *   - sections: A list of section definitions.
 *
 * Each value under the "sections" field has two fields:
 *   - offset: The offset into the original specified at which this section
 *       begins to apply, defined as an object with a "line" and "column"
 *       field.
 *   - map: A source map definition. This source map could also be indexed,
 *       but doesn't have to be.
 *
 * Instead of the "map" field, it's also possible to have a "url" field
 * specifying a URL to retrieve a source map from, but that's currently
 * unsupported.
 *
 * Here's an example source map, taken from the source map spec[0], but
 * modified to omit a section which uses the "url" field.
 *
 *  {
 *    version : 3,
 *    file: "app.js",
 *    sections: [{
 *      offset: {line:100, column:10},
 *      map: {
 *        version : 3,
 *        file: "section.js",
 *        sources: ["foo.js", "bar.js"],
 *        names: ["src", "maps", "are", "fun"],
 *        mappings: "AAAA,E;;ABCDE;"
 *      }
 *    }],
 *  }
 *
 * The second parameter, if given, is a string whose value is the URL
 * at which the source map was found.  This URL is used to compute the
 * sources array.
 *
 * [0]: https://docs.google.com/document/d/1U1RGAehQwRypUTovF1KRlpiOFze0b-_2gc6fAH0KY0k/edit#heading=h.535es3xeprgt
 */
function IndexedSourceMapConsumer(aSourceMap, aSourceMapURL) {
  var sourceMap = aSourceMap;
  if (typeof aSourceMap === 'string') {
    sourceMap = util.parseSourceMapInput(aSourceMap);
  }

  var version = util.getArg(sourceMap, 'version');
  var sections = util.getArg(sourceMap, 'sections');

  if (version != this._version) {
    throw new Error('Unsupported version: ' + version);
  }

  this._sources = new ArraySet();
  this._names = new ArraySet();

  var lastOffset = {
    line: -1,
    column: 0
  };
  this._sections = sections.map(function (s) {
    if (s.url) {
      // The url field will require support for asynchronicity.
      // See https://github.com/mozilla/source-map/issues/16
      throw new Error('Support for url field in sections not implemented.');
    }
    var offset = util.getArg(s, 'offset');
    var offsetLine = util.getArg(offset, 'line');
    var offsetColumn = util.getArg(offset, 'column');

    if (offsetLine < lastOffset.line ||
        (offsetLine === lastOffset.line && offsetColumn < lastOffset.column)) {
      throw new Error('Section offsets must be ordered and non-overlapping.');
    }
    lastOffset = offset;

    return {
      generatedOffset: {
        // The offset fields are 0-based, but we use 1-based indices when
        // encoding/decoding from VLQ.
        generatedLine: offsetLine + 1,
        generatedColumn: offsetColumn + 1
      },
      consumer: new SourceMapConsumer(util.getArg(s, 'map'), aSourceMapURL)
    }
  });
}

IndexedSourceMapConsumer.prototype = Object.create(SourceMapConsumer.prototype);
IndexedSourceMapConsumer.prototype.constructor = SourceMapConsumer;

/**
 * The version of the source mapping spec that we are consuming.
 */
IndexedSourceMapConsumer.prototype._version = 3;

/**
 * The list of original sources.
 */
Object.defineProperty(IndexedSourceMapConsumer.prototype, 'sources', {
  get: function () {
    var sources = [];
    for (var i = 0; i < this._sections.length; i++) {
      for (var j = 0; j < this._sections[i].consumer.sources.length; j++) {
        sources.push(this._sections[i].consumer.sources[j]);
      }
    }
    return sources;
  }
});

/**
 * Returns the original source, line, and column information for the generated
 * source's line and column positions provided. The only argument is an object
 * with the following properties:
 *
 *   - line: The line number in the generated source.  The line number
 *     is 1-based.
 *   - column: The column number in the generated source.  The column
 *     number is 0-based.
 *
 * and an object is returned with the following properties:
 *
 *   - source: The original source file, or null.
 *   - line: The line number in the original source, or null.  The
 *     line number is 1-based.
 *   - column: The column number in the original source, or null.  The
 *     column number is 0-based.
 *   - name: The original identifier, or null.
 */
IndexedSourceMapConsumer.prototype.originalPositionFor =
  function IndexedSourceMapConsumer_originalPositionFor(aArgs) {
    var needle = {
      generatedLine: util.getArg(aArgs, 'line'),
      generatedColumn: util.getArg(aArgs, 'column')
    };

    // Find the section containing the generated position we're trying to map
    // to an original position.
    var sectionIndex = binarySearch.search(needle, this._sections,
      function(needle, section) {
        var cmp = needle.generatedLine - section.generatedOffset.generatedLine;
        if (cmp) {
          return cmp;
        }

        return (needle.generatedColumn -
                section.generatedOffset.generatedColumn);
      });
    var section = this._sections[sectionIndex];

    if (!section) {
      return {
        source: null,
        line: null,
        column: null,
        name: null
      };
    }

    return section.consumer.originalPositionFor({
      line: needle.generatedLine -
        (section.generatedOffset.generatedLine - 1),
      column: needle.generatedColumn -
        (section.generatedOffset.generatedLine === needle.generatedLine
         ? section.generatedOffset.generatedColumn - 1
         : 0),
      bias: aArgs.bias
    });
  };

/**
 * Return true if we have the source content for every source in the source
 * map, false otherwise.
 */
IndexedSourceMapConsumer.prototype.hasContentsOfAllSources =
  function IndexedSourceMapConsumer_hasContentsOfAllSources() {
    return this._sections.every(function (s) {
      return s.consumer.hasContentsOfAllSources();
    });
  };

/**
 * Returns the original source content. The only argument is the url of the
 * original source file. Returns null if no original source content is
 * available.
 */
IndexedSourceMapConsumer.prototype.sourceContentFor =
  function IndexedSourceMapConsumer_sourceContentFor(aSource, nullOnMissing) {
    for (var i = 0; i < this._sections.length; i++) {
      var section = this._sections[i];

      var content = section.consumer.sourceContentFor(aSource, true);
      if (content) {
        return content;
      }
    }
    if (nullOnMissing) {
      return null;
    }
    else {
      throw new Error('"' + aSource + '" is not in the SourceMap.');
    }
  };

/**
 * Returns the generated line and column information for the original source,
 * line, and column positions provided. The only argument is an object with
 * the following properties:
 *
 *   - source: The filename of the original source.
 *   - line: The line number in the original source.  The line number
 *     is 1-based.
 *   - column: The column number in the original source.  The column
 *     number is 0-based.
 *
 * and an object is returned with the following properties:
 *
 *   - line: The line number in the generated source, or null.  The
 *     line number is 1-based. 
 *   - column: The column number in the generated source, or null.
 *     The column number is 0-based.
 */
IndexedSourceMapConsumer.prototype.generatedPositionFor =
  function IndexedSourceMapConsumer_generatedPositionFor(aArgs) {
    for (var i = 0; i < this._sections.length; i++) {
      var section = this._sections[i];

      // Only consider this section if the requested source is in the list of
      // sources of the consumer.
      if (section.consumer._findSourceIndex(util.getArg(aArgs, 'source')) === -1) {
        continue;
      }
      var generatedPosition = section.consumer.generatedPositionFor(aArgs);
      if (generatedPosition) {
        var ret = {
          line: generatedPosition.line +
            (section.generatedOffset.generatedLine - 1),
          column: generatedPosition.column +
            (section.generatedOffset.generatedLine === generatedPosition.line
             ? section.generatedOffset.generatedColumn - 1
             : 0)
        };
        return ret;
      }
    }

    return {
      line: null,
      column: null
    };
  };

/**
 * Parse the mappings in a string in to a data structure which we can easily
 * query (the ordered arrays in the `this.__generatedMappings` and
 * `this.__originalMappings` properties).
 */
IndexedSourceMapConsumer.prototype._parseMappings =
  function IndexedSourceMapConsumer_parseMappings(aStr, aSourceRoot) {
    this.__generatedMappings = [];
    this.__originalMappings = [];
    for (var i = 0; i < this._sections.length; i++) {
      var section = this._sections[i];
      var sectionMappings = section.consumer._generatedMappings;
      for (var j = 0; j < sectionMappings.length; j++) {
        var mapping = sectionMappings[j];

        var source = section.consumer._sources.at(mapping.source);
        source = util.computeSourceURL(section.consumer.sourceRoot, source, this._sourceMapURL);
        this._sources.add(source);
        source = this._sources.indexOf(source);

        var name = null;
        if (mapping.name) {
          name = section.consumer._names.at(mapping.name);
          this._names.add(name);
          name = this._names.indexOf(name);
        }

        // The mappings coming from the consumer for the section have
        // generated positions relative to the start of the section, so we
        // need to offset them to be relative to the start of the concatenated
        // generated file.
        var adjustedMapping = {
          source: source,
          generatedLine: mapping.generatedLine +
            (section.generatedOffset.generatedLine - 1),
          generatedColumn: mapping.generatedColumn +
            (section.generatedOffset.generatedLine === mapping.generatedLine
            ? section.generatedOffset.generatedColumn - 1
            : 0),
          originalLine: mapping.originalLine,
          originalColumn: mapping.originalColumn,
          name: name
        };

        this.__generatedMappings.push(adjustedMapping);
        if (typeof adjustedMapping.originalLine === 'number') {
          this.__originalMappings.push(adjustedMapping);
        }
      }
    }

    quickSort(this.__generatedMappings, util.compareByGeneratedPositionsDeflated);
    quickSort(this.__originalMappings, util.compareByOriginalPositions);
  };

exports.IndexedSourceMapConsumer = IndexedSourceMapConsumer;


/***/ }),
/* 470 */
/***/ (function(module, exports) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

exports.GREATEST_LOWER_BOUND = 1;
exports.LEAST_UPPER_BOUND = 2;

/**
 * Recursive implementation of binary search.
 *
 * @param aLow Indices here and lower do not contain the needle.
 * @param aHigh Indices here and higher do not contain the needle.
 * @param aNeedle The element being searched for.
 * @param aHaystack The non-empty array being searched.
 * @param aCompare Function which takes two elements and returns -1, 0, or 1.
 * @param aBias Either 'binarySearch.GREATEST_LOWER_BOUND' or
 *     'binarySearch.LEAST_UPPER_BOUND'. Specifies whether to return the
 *     closest element that is smaller than or greater than the one we are
 *     searching for, respectively, if the exact element cannot be found.
 */
function recursiveSearch(aLow, aHigh, aNeedle, aHaystack, aCompare, aBias) {
  // This function terminates when one of the following is true:
  //
  //   1. We find the exact element we are looking for.
  //
  //   2. We did not find the exact element, but we can return the index of
  //      the next-closest element.
  //
  //   3. We did not find the exact element, and there is no next-closest
  //      element than the one we are searching for, so we return -1.
  var mid = Math.floor((aHigh - aLow) / 2) + aLow;
  var cmp = aCompare(aNeedle, aHaystack[mid], true);
  if (cmp === 0) {
    // Found the element we are looking for.
    return mid;
  }
  else if (cmp > 0) {
    // Our needle is greater than aHaystack[mid].
    if (aHigh - mid > 1) {
      // The element is in the upper half.
      return recursiveSearch(mid, aHigh, aNeedle, aHaystack, aCompare, aBias);
    }

    // The exact needle element was not found in this haystack. Determine if
    // we are in termination case (3) or (2) and return the appropriate thing.
    if (aBias == exports.LEAST_UPPER_BOUND) {
      return aHigh < aHaystack.length ? aHigh : -1;
    } else {
      return mid;
    }
  }
  else {
    // Our needle is less than aHaystack[mid].
    if (mid - aLow > 1) {
      // The element is in the lower half.
      return recursiveSearch(aLow, mid, aNeedle, aHaystack, aCompare, aBias);
    }

    // we are in termination case (3) or (2) and return the appropriate thing.
    if (aBias == exports.LEAST_UPPER_BOUND) {
      return mid;
    } else {
      return aLow < 0 ? -1 : aLow;
    }
  }
}

/**
 * This is an implementation of binary search which will always try and return
 * the index of the closest element if there is no exact hit. This is because
 * mappings between original and generated line/col pairs are single points,
 * and there is an implicit region between each of them, so a miss just means
 * that you aren't on the very start of a region.
 *
 * @param aNeedle The element you are looking for.
 * @param aHaystack The array that is being searched.
 * @param aCompare A function which takes the needle and an element in the
 *     array and returns -1, 0, or 1 depending on whether the needle is less
 *     than, equal to, or greater than the element, respectively.
 * @param aBias Either 'binarySearch.GREATEST_LOWER_BOUND' or
 *     'binarySearch.LEAST_UPPER_BOUND'. Specifies whether to return the
 *     closest element that is smaller than or greater than the one we are
 *     searching for, respectively, if the exact element cannot be found.
 *     Defaults to 'binarySearch.GREATEST_LOWER_BOUND'.
 */
exports.search = function search(aNeedle, aHaystack, aCompare, aBias) {
  if (aHaystack.length === 0) {
    return -1;
  }

  var index = recursiveSearch(-1, aHaystack.length, aNeedle, aHaystack,
                              aCompare, aBias || exports.GREATEST_LOWER_BOUND);
  if (index < 0) {
    return -1;
  }

  // We have found either the exact element, or the next-closest element than
  // the one we are searching for. However, there may be more than one such
  // element. Make sure we always return the smallest of these.
  while (index - 1 >= 0) {
    if (aCompare(aHaystack[index], aHaystack[index - 1], true) !== 0) {
      break;
    }
    --index;
  }

  return index;
};


/***/ }),
/* 471 */
/***/ (function(module, exports) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

// It turns out that some (most?) JavaScript engines don't self-host
// `Array.prototype.sort`. This makes sense because C++ will likely remain
// faster than JS when doing raw CPU-intensive sorting. However, when using a
// custom comparator function, calling back and forth between the VM's C++ and
// JIT'd JS is rather slow *and* loses JIT type information, resulting in
// worse generated code for the comparator function than would be optimal. In
// fact, when sorting with a comparator, these costs outweigh the benefits of
// sorting in C++. By using our own JS-implemented Quick Sort (below), we get
// a ~3500ms mean speed-up in `bench/bench.html`.

/**
 * Swap the elements indexed by `x` and `y` in the array `ary`.
 *
 * @param {Array} ary
 *        The array.
 * @param {Number} x
 *        The index of the first item.
 * @param {Number} y
 *        The index of the second item.
 */
function swap(ary, x, y) {
  var temp = ary[x];
  ary[x] = ary[y];
  ary[y] = temp;
}

/**
 * Returns a random integer within the range `low .. high` inclusive.
 *
 * @param {Number} low
 *        The lower bound on the range.
 * @param {Number} high
 *        The upper bound on the range.
 */
function randomIntInRange(low, high) {
  return Math.round(low + (Math.random() * (high - low)));
}

/**
 * The Quick Sort algorithm.
 *
 * @param {Array} ary
 *        An array to sort.
 * @param {function} comparator
 *        Function to use to compare two items.
 * @param {Number} p
 *        Start index of the array
 * @param {Number} r
 *        End index of the array
 */
function doQuickSort(ary, comparator, p, r) {
  // If our lower bound is less than our upper bound, we (1) partition the
  // array into two pieces and (2) recurse on each half. If it is not, this is
  // the empty array and our base case.

  if (p < r) {
    // (1) Partitioning.
    //
    // The partitioning chooses a pivot between `p` and `r` and moves all
    // elements that are less than or equal to the pivot to the before it, and
    // all the elements that are greater than it after it. The effect is that
    // once partition is done, the pivot is in the exact place it will be when
    // the array is put in sorted order, and it will not need to be moved
    // again. This runs in O(n) time.

    // Always choose a random pivot so that an input array which is reverse
    // sorted does not cause O(n^2) running time.
    var pivotIndex = randomIntInRange(p, r);
    var i = p - 1;

    swap(ary, pivotIndex, r);
    var pivot = ary[r];

    // Immediately after `j` is incremented in this loop, the following hold
    // true:
    //
    //   * Every element in `ary[p .. i]` is less than or equal to the pivot.
    //
    //   * Every element in `ary[i+1 .. j-1]` is greater than the pivot.
    for (var j = p; j < r; j++) {
      if (comparator(ary[j], pivot) <= 0) {
        i += 1;
        swap(ary, i, j);
      }
    }

    swap(ary, i + 1, j);
    var q = i + 1;

    // (2) Recurse on each half.

    doQuickSort(ary, comparator, p, q - 1);
    doQuickSort(ary, comparator, q + 1, r);
  }
}

/**
 * Sort the given array in-place with the given comparator function.
 *
 * @param {Array} ary
 *        An array to sort.
 * @param {function} comparator
 *        Function to use to compare two items.
 */
exports.quickSort = function (ary, comparator) {
  doQuickSort(ary, comparator, 0, ary.length - 1);
};


/***/ }),
/* 472 */
/***/ (function(module, exports, __webpack_require__) {

/* -*- Mode: js; js-indent-level: 2; -*- */
/*
 * Copyright 2011 Mozilla Foundation and contributors
 * Licensed under the New BSD license. See LICENSE or:
 * http://opensource.org/licenses/BSD-3-Clause
 */

var SourceMapGenerator = __webpack_require__(330).SourceMapGenerator;
var util = __webpack_require__(141);

// Matches a Windows-style `\r\n` newline or a `\n` newline used by all other
// operating systems these days (capturing the result).
var REGEX_NEWLINE = /(\r?\n)/;

// Newline character code for charCodeAt() comparisons
var NEWLINE_CODE = 10;

// Private symbol for identifying `SourceNode`s when multiple versions of
// the source-map library are loaded. This MUST NOT CHANGE across
// versions!
var isSourceNode = "$$$isSourceNode$$$";

/**
 * SourceNodes provide a way to abstract over interpolating/concatenating
 * snippets of generated JavaScript source code while maintaining the line and
 * column information associated with the original source code.
 *
 * @param aLine The original line number.
 * @param aColumn The original column number.
 * @param aSource The original source's filename.
 * @param aChunks Optional. An array of strings which are snippets of
 *        generated JS, or other SourceNodes.
 * @param aName The original identifier.
 */
function SourceNode(aLine, aColumn, aSource, aChunks, aName) {
  this.children = [];
  this.sourceContents = {};
  this.line = aLine == null ? null : aLine;
  this.column = aColumn == null ? null : aColumn;
  this.source = aSource == null ? null : aSource;
  this.name = aName == null ? null : aName;
  this[isSourceNode] = true;
  if (aChunks != null) this.add(aChunks);
}

/**
 * Creates a SourceNode from generated code and a SourceMapConsumer.
 *
 * @param aGeneratedCode The generated code
 * @param aSourceMapConsumer The SourceMap for the generated code
 * @param aRelativePath Optional. The path that relative sources in the
 *        SourceMapConsumer should be relative to.
 */
SourceNode.fromStringWithSourceMap =
  function SourceNode_fromStringWithSourceMap(aGeneratedCode, aSourceMapConsumer, aRelativePath) {
    // The SourceNode we want to fill with the generated code
    // and the SourceMap
    var node = new SourceNode();

    // All even indices of this array are one line of the generated code,
    // while all odd indices are the newlines between two adjacent lines
    // (since `REGEX_NEWLINE` captures its match).
    // Processed fragments are accessed by calling `shiftNextLine`.
    var remainingLines = aGeneratedCode.split(REGEX_NEWLINE);
    var remainingLinesIndex = 0;
    var shiftNextLine = function() {
      var lineContents = getNextLine();
      // The last line of a file might not have a newline.
      var newLine = getNextLine() || "";
      return lineContents + newLine;

      function getNextLine() {
        return remainingLinesIndex < remainingLines.length ?
            remainingLines[remainingLinesIndex++] : undefined;
      }
    };

    // We need to remember the position of "remainingLines"
    var lastGeneratedLine = 1, lastGeneratedColumn = 0;

    // The generate SourceNodes we need a code range.
    // To extract it current and last mapping is used.
    // Here we store the last mapping.
    var lastMapping = null;

    aSourceMapConsumer.eachMapping(function (mapping) {
      if (lastMapping !== null) {
        // We add the code from "lastMapping" to "mapping":
        // First check if there is a new line in between.
        if (lastGeneratedLine < mapping.generatedLine) {
          // Associate first line with "lastMapping"
          addMappingWithCode(lastMapping, shiftNextLine());
          lastGeneratedLine++;
          lastGeneratedColumn = 0;
          // The remaining code is added without mapping
        } else {
          // There is no new line in between.
          // Associate the code between "lastGeneratedColumn" and
          // "mapping.generatedColumn" with "lastMapping"
          var nextLine = remainingLines[remainingLinesIndex] || '';
          var code = nextLine.substr(0, mapping.generatedColumn -
                                        lastGeneratedColumn);
          remainingLines[remainingLinesIndex] = nextLine.substr(mapping.generatedColumn -
                                              lastGeneratedColumn);
          lastGeneratedColumn = mapping.generatedColumn;
          addMappingWithCode(lastMapping, code);
          // No more remaining code, continue
          lastMapping = mapping;
          return;
        }
      }
      // We add the generated code until the first mapping
      // to the SourceNode without any mapping.
      // Each line is added as separate string.
      while (lastGeneratedLine < mapping.generatedLine) {
        node.add(shiftNextLine());
        lastGeneratedLine++;
      }
      if (lastGeneratedColumn < mapping.generatedColumn) {
        var nextLine = remainingLines[remainingLinesIndex] || '';
        node.add(nextLine.substr(0, mapping.generatedColumn));
        remainingLines[remainingLinesIndex] = nextLine.substr(mapping.generatedColumn);
        lastGeneratedColumn = mapping.generatedColumn;
      }
      lastMapping = mapping;
    }, this);
    // We have processed all mappings.
    if (remainingLinesIndex < remainingLines.length) {
      if (lastMapping) {
        // Associate the remaining code in the current line with "lastMapping"
        addMappingWithCode(lastMapping, shiftNextLine());
      }
      // and add the remaining lines without any mapping
      node.add(remainingLines.splice(remainingLinesIndex).join(""));
    }

    // Copy sourcesContent into SourceNode
    aSourceMapConsumer.sources.forEach(function (sourceFile) {
      var content = aSourceMapConsumer.sourceContentFor(sourceFile);
      if (content != null) {
        if (aRelativePath != null) {
          sourceFile = util.join(aRelativePath, sourceFile);
        }
        node.setSourceContent(sourceFile, content);
      }
    });

    return node;

    function addMappingWithCode(mapping, code) {
      if (mapping === null || mapping.source === undefined) {
        node.add(code);
      } else {
        var source = aRelativePath
          ? util.join(aRelativePath, mapping.source)
          : mapping.source;
        node.add(new SourceNode(mapping.originalLine,
                                mapping.originalColumn,
                                source,
                                code,
                                mapping.name));
      }
    }
  };

/**
 * Add a chunk of generated JS to this source node.
 *
 * @param aChunk A string snippet of generated JS code, another instance of
 *        SourceNode, or an array where each member is one of those things.
 */
SourceNode.prototype.add = function SourceNode_add(aChunk) {
  if (Array.isArray(aChunk)) {
    aChunk.forEach(function (chunk) {
      this.add(chunk);
    }, this);
  }
  else if (aChunk[isSourceNode] || typeof aChunk === "string") {
    if (aChunk) {
      this.children.push(aChunk);
    }
  }
  else {
    throw new TypeError(
      "Expected a SourceNode, string, or an array of SourceNodes and strings. Got " + aChunk
    );
  }
  return this;
};

/**
 * Add a chunk of generated JS to the beginning of this source node.
 *
 * @param aChunk A string snippet of generated JS code, another instance of
 *        SourceNode, or an array where each member is one of those things.
 */
SourceNode.prototype.prepend = function SourceNode_prepend(aChunk) {
  if (Array.isArray(aChunk)) {
    for (var i = aChunk.length-1; i >= 0; i--) {
      this.prepend(aChunk[i]);
    }
  }
  else if (aChunk[isSourceNode] || typeof aChunk === "string") {
    this.children.unshift(aChunk);
  }
  else {
    throw new TypeError(
      "Expected a SourceNode, string, or an array of SourceNodes and strings. Got " + aChunk
    );
  }
  return this;
};

/**
 * Walk over the tree of JS snippets in this node and its children. The
 * walking function is called once for each snippet of JS and is passed that
 * snippet and the its original associated source's line/column location.
 *
 * @param aFn The traversal function.
 */
SourceNode.prototype.walk = function SourceNode_walk(aFn) {
  var chunk;
  for (var i = 0, len = this.children.length; i < len; i++) {
    chunk = this.children[i];
    if (chunk[isSourceNode]) {
      chunk.walk(aFn);
    }
    else {
      if (chunk !== '') {
        aFn(chunk, { source: this.source,
                     line: this.line,
                     column: this.column,
                     name: this.name });
      }
    }
  }
};

/**
 * Like `String.prototype.join` except for SourceNodes. Inserts `aStr` between
 * each of `this.children`.
 *
 * @param aSep The separator.
 */
SourceNode.prototype.join = function SourceNode_join(aSep) {
  var newChildren;
  var i;
  var len = this.children.length;
  if (len > 0) {
    newChildren = [];
    for (i = 0; i < len-1; i++) {
      newChildren.push(this.children[i]);
      newChildren.push(aSep);
    }
    newChildren.push(this.children[i]);
    this.children = newChildren;
  }
  return this;
};

/**
 * Call String.prototype.replace on the very right-most source snippet. Useful
 * for trimming whitespace from the end of a source node, etc.
 *
 * @param aPattern The pattern to replace.
 * @param aReplacement The thing to replace the pattern with.
 */
SourceNode.prototype.replaceRight = function SourceNode_replaceRight(aPattern, aReplacement) {
  var lastChild = this.children[this.children.length - 1];
  if (lastChild[isSourceNode]) {
    lastChild.replaceRight(aPattern, aReplacement);
  }
  else if (typeof lastChild === 'string') {
    this.children[this.children.length - 1] = lastChild.replace(aPattern, aReplacement);
  }
  else {
    this.children.push(''.replace(aPattern, aReplacement));
  }
  return this;
};

/**
 * Set the source content for a source file. This will be added to the SourceMapGenerator
 * in the sourcesContent field.
 *
 * @param aSourceFile The filename of the source file
 * @param aSourceContent The content of the source file
 */
SourceNode.prototype.setSourceContent =
  function SourceNode_setSourceContent(aSourceFile, aSourceContent) {
    this.sourceContents[util.toSetString(aSourceFile)] = aSourceContent;
  };

/**
 * Walk over the tree of SourceNodes. The walking function is called for each
 * source file content and is passed the filename and source content.
 *
 * @param aFn The traversal function.
 */
SourceNode.prototype.walkSourceContents =
  function SourceNode_walkSourceContents(aFn) {
    for (var i = 0, len = this.children.length; i < len; i++) {
      if (this.children[i][isSourceNode]) {
        this.children[i].walkSourceContents(aFn);
      }
    }

    var sources = Object.keys(this.sourceContents);
    for (var i = 0, len = sources.length; i < len; i++) {
      aFn(util.fromSetString(sources[i]), this.sourceContents[sources[i]]);
    }
  };

/**
 * Return the string representation of this source node. Walks over the tree
 * and concatenates all the various snippets together to one string.
 */
SourceNode.prototype.toString = function SourceNode_toString() {
  var str = "";
  this.walk(function (chunk) {
    str += chunk;
  });
  return str;
};

/**
 * Returns the string representation of this source node along with a source
 * map.
 */
SourceNode.prototype.toStringWithSourceMap = function SourceNode_toStringWithSourceMap(aArgs) {
  var generated = {
    code: "",
    line: 1,
    column: 0
  };
  var map = new SourceMapGenerator(aArgs);
  var sourceMappingActive = false;
  var lastOriginalSource = null;
  var lastOriginalLine = null;
  var lastOriginalColumn = null;
  var lastOriginalName = null;
  this.walk(function (chunk, original) {
    generated.code += chunk;
    if (original.source !== null
        && original.line !== null
        && original.column !== null) {
      if(lastOriginalSource !== original.source
         || lastOriginalLine !== original.line
         || lastOriginalColumn !== original.column
         || lastOriginalName !== original.name) {
        map.addMapping({
          source: original.source,
          original: {
            line: original.line,
            column: original.column
          },
          generated: {
            line: generated.line,
            column: generated.column
          },
          name: original.name
        });
      }
      lastOriginalSource = original.source;
      lastOriginalLine = original.line;
      lastOriginalColumn = original.column;
      lastOriginalName = original.name;
      sourceMappingActive = true;
    } else if (sourceMappingActive) {
      map.addMapping({
        generated: {
          line: generated.line,
          column: generated.column
        }
      });
      lastOriginalSource = null;
      sourceMappingActive = false;
    }
    for (var idx = 0, length = chunk.length; idx < length; idx++) {
      if (chunk.charCodeAt(idx) === NEWLINE_CODE) {
        generated.line++;
        generated.column = 0;
        // Mappings end at eol
        if (idx + 1 === length) {
          lastOriginalSource = null;
          sourceMappingActive = false;
        } else if (sourceMappingActive) {
          map.addMapping({
            source: original.source,
            original: {
              line: original.line,
              column: original.column
            },
            generated: {
              line: generated.line,
              column: generated.column
            },
            name: original.name
          });
        }
      } else {
        generated.column++;
      }
    }
  });
  this.walkSourceContents(function (sourceFile, sourceContent) {
    map.setSourceContent(sourceFile, sourceContent);
  });

  return { code: generated.code, map: map };
};

exports.SourceNode = SourceNode;


/***/ }),
/* 473 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const token_1 = __webpack_require__(109);
const deprecated_1 = __webpack_require__(333);
/**
 * Deprecates a section of a template.
 *
 * <pre>
 * {% deprecated 'The "base.twig" template is deprecated, use "layout.twig" instead.' %}
 *
 * {% extends 'layout.html.twig' %}
 * </pre>
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingTokenParserDeprecated extends token_parser_1.TwingTokenParser {
    parse(token) {
        let expr = this.parser.getExpressionParser().parseExpression();
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        return new deprecated_1.TwingNodeDeprecated(expr, token.getLine(), token.getColumn(), this.getTag());
    }
    getTag() {
        return 'deprecated';
    }
}
exports.TwingTokenParserDeprecated = TwingTokenParserDeprecated;


/***/ }),
/* 474 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const token_parser_1 = __webpack_require__(111);
const node_1 = __webpack_require__(107);
const token_1 = __webpack_require__(109);
const print_1 = __webpack_require__(124);
const set_1 = __webpack_require__(192);
const temp_name_1 = __webpack_require__(475);
/**
 * Applies filters on a section of a template.
 *
 *   {% apply upper %}
 *      This text becomes uppercase
 *   {% endapply %}
 */
class TwingTokenParserApply extends token_parser_1.TwingTokenParser {
    parse(token) {
        let lineno = token.getLine();
        let columno = token.getColumn();
        let name = this.parser.getVarName();
        let ref;
        ref = new temp_name_1.TwingNodeExpressionTempName(name, false, lineno, columno);
        ref.setAttribute('always_defined', true);
        let filter = this.parser.getExpressionParser().parseFilterExpressionRaw(ref, this.getTag());
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        let body = this.parser.subparse([this, this.decideBlockEnd], true);
        this.parser.getStream().expect(token_1.TwingToken.BLOCK_END_TYPE);
        let nodes = new Map();
        ref = new temp_name_1.TwingNodeExpressionTempName(name, true, lineno, columno);
        nodes.set(0, new set_1.TwingNodeSet(true, ref, body, lineno, columno, this.getTag()));
        nodes.set(1, new print_1.TwingNodePrint(filter, lineno, columno, this.getTag()));
        return new node_1.TwingNode(nodes);
    }
    decideBlockEnd(token) {
        return token.test(token_1.TwingToken.NAME_TYPE, 'endapply');
    }
    getTag() {
        return 'apply';
    }
}
exports.TwingTokenParserApply = TwingTokenParserApply;


/***/ }),
/* 475 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const expression_1 = __webpack_require__(114);
const node_1 = __webpack_require__(107);
class TwingNodeExpressionTempName extends expression_1.TwingNodeExpression {
    constructor(name, declaration, lineno, columno) {
        let attributes = new Map();
        attributes.set('name', name);
        attributes.set('declaration', declaration);
        super(new Map(), attributes, lineno, columno);
        this.type = node_1.TwingNodeType.EXPRESSION_TEMP_NAME;
    }
    compile(compiler) {
        compiler
            .raw(`${this.getAttribute('declaration') ? 'let ' : ''}$_`)
            .raw(this.getAttribute('name'))
            .raw('_');
    }
}
exports.TwingNodeExpressionTempName = TwingNodeExpressionTempName;


/***/ }),
/* 476 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function sprintf() {
  //  discuss at: http://locutus.io/php/sprintf/
  // original by: Ash Searle (http://hexmen.com/blog/)
  // improved by: Michael White (http://getsprink.com)
  // improved by: Jack
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Dj
  // improved by: Allidylls
  //    input by: Paulo Freitas
  //    input by: Brett Zamir (http://brett-zamir.me)
  // improved by: Rafał Kukawski (http://kukawski.pl)
  //   example 1: sprintf("%01.2f", 123.1)
  //   returns 1: '123.10'
  //   example 2: sprintf("[%10s]", 'monkey')
  //   returns 2: '[    monkey]'
  //   example 3: sprintf("[%'#10s]", 'monkey')
  //   returns 3: '[####monkey]'
  //   example 4: sprintf("%d", 123456789012345)
  //   returns 4: '123456789012345'
  //   example 5: sprintf('%-03s', 'E')
  //   returns 5: 'E00'
  //   example 6: sprintf('%+010d', 9)
  //   returns 6: '+000000009'
  //   example 7: sprintf('%+0\'@10d', 9)
  //   returns 7: '@@@@@@@@+9'
  //   example 8: sprintf('%.f', 3.14)
  //   returns 8: '3.140000'
  //   example 9: sprintf('%% %2$d', 1, 2)
  //   returns 9: '% 2'

  var regex = /%%|%(?:(\d+)\$)?((?:[-+#0 ]|'[\s\S])*)(\d+)?(?:\.(\d*))?([\s\S])/g;
  var args = arguments;
  var i = 0;
  var format = args[i++];

  var _pad = function _pad(str, len, chr, leftJustify) {
    if (!chr) {
      chr = ' ';
    }
    var padding = str.length >= len ? '' : new Array(1 + len - str.length >>> 0).join(chr);
    return leftJustify ? str + padding : padding + str;
  };

  var justify = function justify(value, prefix, leftJustify, minWidth, padChar) {
    var diff = minWidth - value.length;
    if (diff > 0) {
      // when padding with zeros
      // on the left side
      // keep sign (+ or -) in front
      if (!leftJustify && padChar === '0') {
        value = [value.slice(0, prefix.length), _pad('', diff, '0', true), value.slice(prefix.length)].join('');
      } else {
        value = _pad(value, minWidth, padChar, leftJustify);
      }
    }
    return value;
  };

  var _formatBaseX = function _formatBaseX(value, base, leftJustify, minWidth, precision, padChar) {
    // Note: casts negative numbers to positive ones
    var number = value >>> 0;
    value = _pad(number.toString(base), precision || 0, '0', false);
    return justify(value, '', leftJustify, minWidth, padChar);
  };

  // _formatString()
  var _formatString = function _formatString(value, leftJustify, minWidth, precision, customPadChar) {
    if (precision !== null && precision !== undefined) {
      value = value.slice(0, precision);
    }
    return justify(value, '', leftJustify, minWidth, customPadChar);
  };

  // doFormat()
  var doFormat = function doFormat(substring, argIndex, modifiers, minWidth, precision, specifier) {
    var number, prefix, method, textTransform, value;

    if (substring === '%%') {
      return '%';
    }

    // parse modifiers
    var padChar = ' '; // pad with spaces by default
    var leftJustify = false;
    var positiveNumberPrefix = '';
    var j, l;

    for (j = 0, l = modifiers.length; j < l; j++) {
      switch (modifiers.charAt(j)) {
        case ' ':
        case '0':
          padChar = modifiers.charAt(j);
          break;
        case '+':
          positiveNumberPrefix = '+';
          break;
        case '-':
          leftJustify = true;
          break;
        case "'":
          if (j + 1 < l) {
            padChar = modifiers.charAt(j + 1);
            j++;
          }
          break;
      }
    }

    if (!minWidth) {
      minWidth = 0;
    } else {
      minWidth = +minWidth;
    }

    if (!isFinite(minWidth)) {
      throw new Error('Width must be finite');
    }

    if (!precision) {
      precision = specifier === 'd' ? 0 : 'fFeE'.indexOf(specifier) > -1 ? 6 : undefined;
    } else {
      precision = +precision;
    }

    if (argIndex && +argIndex === 0) {
      throw new Error('Argument number must be greater than zero');
    }

    if (argIndex && +argIndex >= args.length) {
      throw new Error('Too few arguments');
    }

    value = argIndex ? args[+argIndex] : args[i++];

    switch (specifier) {
      case '%':
        return '%';
      case 's':
        return _formatString(value + '', leftJustify, minWidth, precision, padChar);
      case 'c':
        return _formatString(String.fromCharCode(+value), leftJustify, minWidth, precision, padChar);
      case 'b':
        return _formatBaseX(value, 2, leftJustify, minWidth, precision, padChar);
      case 'o':
        return _formatBaseX(value, 8, leftJustify, minWidth, precision, padChar);
      case 'x':
        return _formatBaseX(value, 16, leftJustify, minWidth, precision, padChar);
      case 'X':
        return _formatBaseX(value, 16, leftJustify, minWidth, precision, padChar).toUpperCase();
      case 'u':
        return _formatBaseX(value, 10, leftJustify, minWidth, precision, padChar);
      case 'i':
      case 'd':
        number = +value || 0;
        // Plain Math.round doesn't just truncate
        number = Math.round(number - number % 1);
        prefix = number < 0 ? '-' : positiveNumberPrefix;
        value = prefix + _pad(String(Math.abs(number)), precision, '0', false);

        if (leftJustify && padChar === '0') {
          // can't right-pad 0s on integers
          padChar = ' ';
        }
        return justify(value, prefix, leftJustify, minWidth, padChar);
      case 'e':
      case 'E':
      case 'f': // @todo: Should handle locales (as per setlocale)
      case 'F':
      case 'g':
      case 'G':
        number = +value;
        prefix = number < 0 ? '-' : positiveNumberPrefix;
        method = ['toExponential', 'toFixed', 'toPrecision']['efg'.indexOf(specifier.toLowerCase())];
        textTransform = ['toString', 'toUpperCase']['eEfFgG'.indexOf(specifier) % 2];
        value = prefix + Math.abs(number)[method](precision);
        return justify(value, prefix, leftJustify, minWidth, padChar)[textTransform]();
      default:
        // unknown specifier, consume that char and return empty
        return '';
    }
  };

  try {
    return format.replace(regex, doFormat);
  } catch (err) {
    return false;
  }
};
//# sourceMappingURL=sprintf.js.map

/***/ }),
/* 477 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function nl2br(str, isXhtml) {
  //  discuss at: http://locutus.io/php/nl2br/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Philip Peterson
  // improved by: Onno Marsman (https://twitter.com/onnomarsman)
  // improved by: Atli Þór
  // improved by: Brett Zamir (http://brett-zamir.me)
  // improved by: Maximusya
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Reynier de la Rosa (http://scriptinside.blogspot.com.es/)
  //    input by: Brett Zamir (http://brett-zamir.me)
  //   example 1: nl2br('Kevin\nvan\nZonneveld')
  //   returns 1: 'Kevin<br />\nvan<br />\nZonneveld'
  //   example 2: nl2br("\nOne\nTwo\n\nThree\n", false)
  //   returns 2: '<br>\nOne<br>\nTwo<br>\n<br>\nThree<br>\n'
  //   example 3: nl2br("\nOne\nTwo\n\nThree\n", true)
  //   returns 3: '<br />\nOne<br />\nTwo<br />\n<br />\nThree<br />\n'
  //   example 4: nl2br(null)
  //   returns 4: ''

  // Some latest browsers when str is null return and unexpected null value
  if (typeof str === 'undefined' || str === null) {
    return '';
  }

  // Adjust comment to avoid issue on locutus.io display
  var breakTag = isXhtml || typeof isXhtml === 'undefined' ? '<br ' + '/>' : '<br>';

  return (str + '').replace(/(\r\n|\n\r|\r|\n)/g, breakTag + '$1');
};
//# sourceMappingURL=nl2br.js.map

/***/ }),
/* 478 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function strip_tags(input, allowed) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/strip_tags/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Luke Godfrey
  // improved by: Kevin van Zonneveld (http://kvz.io)
  //    input by: Pul
  //    input by: Alex
  //    input by: Marc Palau
  //    input by: Brett Zamir (http://brett-zamir.me)
  //    input by: Bobby Drake
  //    input by: Evertjan Garretsen
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Eric Nagel
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Tomasz Wesolowski
  // bugfixed by: Tymon Sturgeon (https://scryptonite.com)
  // bugfixed by: Tim de Koning (https://www.kingsquare.nl)
  //  revised by: Rafał Kukawski (http://blog.kukawski.pl)
  //   example 1: strip_tags('<p>Kevin</p> <br /><b>van</b> <i>Zonneveld</i>', '<i><b>')
  //   returns 1: 'Kevin <b>van</b> <i>Zonneveld</i>'
  //   example 2: strip_tags('<p>Kevin <img src="someimage.png" onmouseover="someFunction()">van <i>Zonneveld</i></p>', '<p>')
  //   returns 2: '<p>Kevin van Zonneveld</p>'
  //   example 3: strip_tags("<a href='http://kvz.io'>Kevin van Zonneveld</a>", "<a>")
  //   returns 3: "<a href='http://kvz.io'>Kevin van Zonneveld</a>"
  //   example 4: strip_tags('1 < 5 5 > 1')
  //   returns 4: '1 < 5 5 > 1'
  //   example 5: strip_tags('1 <br/> 1')
  //   returns 5: '1  1'
  //   example 6: strip_tags('1 <br/> 1', '<br>')
  //   returns 6: '1 <br/> 1'
  //   example 7: strip_tags('1 <br/> 1', '<br><br/>')
  //   returns 7: '1 <br/> 1'
  //   example 8: strip_tags('<i>hello</i> <<foo>script>world<</foo>/script>')
  //   returns 8: 'hello world'
  //   example 9: strip_tags(4)
  //   returns 9: '4'

  var _phpCastString = __webpack_require__(334);

  // making sure the allowed arg is a string containing only tags in lowercase (<a><b><c>)
  allowed = (((allowed || '') + '').toLowerCase().match(/<[a-z][a-z0-9]*>/g) || []).join('');

  var tags = /<\/?([a-z0-9]*)\b[^>]*>?/gi;
  var commentsAndPhpTags = /<!--[\s\S]*?-->|<\?(?:php)?[\s\S]*?\?>/gi;

  var after = _phpCastString(input);
  // removes tha '<' char at the end of the string to replicate PHP's behaviour
  after = after.substring(after.length - 1) === '<' ? after.substring(0, after.length - 1) : after;

  // recursively remove tags to ensure that the returned string doesn't contain forbidden tags after previous passes (e.g. '<<bait/>switch/>')
  while (true) {
    var before = after;
    after = before.replace(commentsAndPhpTags, '').replace(tags, function ($0, $1) {
      return allowed.indexOf('<' + $1.toLowerCase() + '>') > -1 ? $0 : '';
    });

    // return once no more tags are removed
    if (before === after) {
      return after;
    }
  }
};
//# sourceMappingURL=strip_tags.js.map

/***/ }),
/* 479 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function array_rand(array, num) {
  // eslint-disable-line camelcase
  //       discuss at: http://locutus.io/php/array_rand/
  //      original by: Waldo Malqui Silva (http://waldo.malqui.info)
  // reimplemented by: Rafał Kukawski
  //        example 1: array_rand( ['Kevin'], 1 )
  //        returns 1: '0'

  // By using Object.keys we support both, arrays and objects
  // which phpjs wants to support
  var keys = Object.keys(array);

  if (typeof num === 'undefined' || num === null) {
    num = 1;
  } else {
    num = +num;
  }

  if (isNaN(num) || num < 1 || num > keys.length) {
    return null;
  }

  // shuffle the array of keys
  for (var i = keys.length - 1; i > 0; i--) {
    var j = Math.floor(Math.random() * (i + 1)); // 0 ≤ j ≤ i

    var tmp = keys[j];
    keys[j] = keys[i];
    keys[i] = tmp;
  }

  return num === 1 ? keys[0] : keys.slice(0, num);
};
//# sourceMappingURL=array_rand.js.map

/***/ }),
/* 480 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


const HIGH_SURROGATE_START = 0xd800
const HIGH_SURROGATE_END = 0xdbff

const LOW_SURROGATE_START = 0xdc00

const REGIONAL_INDICATOR_START = 0x1f1e6
const REGIONAL_INDICATOR_END = 0x1f1ff

const FITZPATRICK_MODIFIER_START = 0x1f3fb
const FITZPATRICK_MODIFIER_END = 0x1f3ff

const VARIATION_MODIFIER_START = 0xfe00
const VARIATION_MODIFIER_END = 0xfe0f

const DIACRITICAL_MARKS_START = 0x20d0
const DIACRITICAL_MARKS_END = 0x20ff

const ZWJ = 0x200d

const GRAPHEMS = [
  0x0308, // ( ◌̈ ) COMBINING DIAERESIS
  0x0937, // ( ष ) DEVANAGARI LETTER SSA
  0x0937, // ( ष ) DEVANAGARI LETTER SSA
  0x093F, // ( ि ) DEVANAGARI VOWEL SIGN I
  0x093F, // ( ि ) DEVANAGARI VOWEL SIGN I
  0x0BA8, // ( ந ) TAMIL LETTER NA
  0x0BBF, // ( ி ) TAMIL VOWEL SIGN I
  0x0BCD, // ( ◌்) TAMIL SIGN VIRAMA
  0x0E31, // ( ◌ั ) THAI CHARACTER MAI HAN-AKAT
  0x0E33, // ( ำ ) THAI CHARACTER SARA AM
  0x0E40, // ( เ ) THAI CHARACTER SARA E
  0x0E49, // ( เ ) THAI CHARACTER MAI THO
  0x1100, // ( ᄀ ) HANGUL CHOSEONG KIYEOK
  0x1161, // ( ᅡ ) HANGUL JUNGSEONG A
  0x11A8 // ( ᆨ ) HANGUL JONGSEONG KIYEOK
]

function runes (string) {
  if (typeof string !== 'string') {
    throw new Error('string cannot be undefined or null')
  }
  const result = []
  let i = 0
  let increment = 0
  while (i < string.length) {
    increment += nextUnits(i + increment, string)
    if (isGraphem(string[i + increment])) {
      increment++
    }
    if (isVariationSelector(string[i + increment])) {
      increment++
    }
    if (isDiacriticalMark(string[i + increment])) {
      increment++
    }
    if (isZeroWidthJoiner(string[i + increment])) {
      increment++
      continue
    }
    result.push(string.substring(i, i + increment))
    i += increment
    increment = 0
  }
  return result
}

// Decide how many code units make up the current character.
// BMP characters: 1 code unit
// Non-BMP characters (represented by surrogate pairs): 2 code units
// Emoji with skin-tone modifiers: 4 code units (2 code points)
// Country flags: 4 code units (2 code points)
// Variations: 2 code units
function nextUnits (i, string) {
  const current = string[i]
  // If we don't have a value that is part of a surrogate pair, or we're at
  // the end, only take the value at i
  if (!isFirstOfSurrogatePair(current) || i === string.length - 1) {
    return 1
  }

  const currentPair = current + string[i + 1]
  let nextPair = string.substring(i + 2, i + 5)

  // Country flags are comprised of two regional indicator symbols,
  // each represented by a surrogate pair.
  // See http://emojipedia.org/flags/
  // If both pairs are regional indicator symbols, take 4
  if (isRegionalIndicator(currentPair) && isRegionalIndicator(nextPair)) {
    return 4
  }

  // If the next pair make a Fitzpatrick skin tone
  // modifier, take 4
  // See http://emojipedia.org/modifiers/
  // Technically, only some code points are meant to be
  // combined with the skin tone modifiers. This function
  // does not check the current pair to see if it is
  // one of them.
  if (isFitzpatrickModifier(nextPair)) {
    return 4
  }
  return 2
}

function isFirstOfSurrogatePair (string) {
  return string && betweenInclusive(string[0].charCodeAt(0), HIGH_SURROGATE_START, HIGH_SURROGATE_END)
}

function isRegionalIndicator (string) {
  return betweenInclusive(codePointFromSurrogatePair(string), REGIONAL_INDICATOR_START, REGIONAL_INDICATOR_END)
}

function isFitzpatrickModifier (string) {
  return betweenInclusive(codePointFromSurrogatePair(string), FITZPATRICK_MODIFIER_START, FITZPATRICK_MODIFIER_END)
}

function isVariationSelector (string) {
  return typeof string === 'string' && betweenInclusive(string.charCodeAt(0), VARIATION_MODIFIER_START, VARIATION_MODIFIER_END)
}

function isDiacriticalMark (string) {
  return typeof string === 'string' && betweenInclusive(string.charCodeAt(0), DIACRITICAL_MARKS_START, DIACRITICAL_MARKS_END)
}

function isGraphem (string) {
  return typeof string === 'string' && GRAPHEMS.indexOf(string.charCodeAt(0)) !== -1
}

function isZeroWidthJoiner (string) {
  return typeof string === 'string' && string.charCodeAt(0) === ZWJ
}

function codePointFromSurrogatePair (pair) {
  const highOffset = pair.charCodeAt(0) - HIGH_SURROGATE_START
  const lowOffset = pair.charCodeAt(1) - LOW_SURROGATE_START
  return (highOffset << 10) + lowOffset + 0x10000
}

function betweenInclusive (value, lower, upper) {
  return value >= lower && value <= upper
}

function substring (string, start, width) {
  const chars = runes(string)
  if (start === undefined) {
    return string
  }
  if (start >= chars.length) {
    return ''
  }
  const rest = chars.length - start
  const stringWidth = width === undefined ? rest : width
  let endIndex = start + stringWidth
  if (endIndex > (start + rest)) {
    endIndex = undefined
  }
  return chars.slice(start, endIndex).join('')
}

module.exports = runes
module.exports.substr = substring


/***/ }),
/* 481 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function is_float(mixedVar) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/is_float/
  // original by: Paulo Freitas
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // improved by: WebDevHobo (http://webdevhobo.blogspot.com/)
  // improved by: Rafał Kukawski (http://blog.kukawski.pl)
  //      note 1: 1.0 is simplified to 1 before it can be accessed by the function, this makes
  //      note 1: it different from the PHP implementation. We can't fix this unfortunately.
  //   example 1: is_float(186.31)
  //   returns 1: true

  return +mixedVar === mixedVar && (!isFinite(mixedVar) || !!(mixedVar % 1));
};
//# sourceMappingURL=is_float.js.map

/***/ }),
/* 482 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function is_bool(mixedVar) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/is_bool/
  // original by: Onno Marsman (https://twitter.com/onnomarsman)
  // improved by: CoursesWeb (http://www.coursesweb.net/)
  //   example 1: is_bool(false)
  //   returns 1: true
  //   example 2: is_bool(0)
  //   returns 2: false

  return mixedVar === true || mixedVar === false; // Faster (in FF) than type checking
};
//# sourceMappingURL=is_bool.js.map

/***/ }),
/* 483 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function strtr(str, trFrom, trTo) {
  //  discuss at: http://locutus.io/php/strtr/
  // original by: Brett Zamir (http://brett-zamir.me)
  //    input by: uestla
  //    input by: Alan C
  //    input by: Taras Bogach
  //    input by: jpfle
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  //   example 1: var $trans = {'hello' : 'hi', 'hi' : 'hello'}
  //   example 1: strtr('hi all, I said hello', $trans)
  //   returns 1: 'hello all, I said hi'
  //   example 2: strtr('äaabaåccasdeöoo', 'äåö','aao')
  //   returns 2: 'aaabaaccasdeooo'
  //   example 3: strtr('ääääääää', 'ä', 'a')
  //   returns 3: 'aaaaaaaa'
  //   example 4: strtr('http', 'pthxyz','xyzpth')
  //   returns 4: 'zyyx'
  //   example 5: strtr('zyyx', 'pthxyz','xyzpth')
  //   returns 5: 'http'
  //   example 6: strtr('aa', {'a':1,'aa':2})
  //   returns 6: '2'

  var krsort = __webpack_require__(484);
  var iniSet = __webpack_require__(488);

  var fr = '';
  var i = 0;
  var j = 0;
  var lenStr = 0;
  var lenFrom = 0;
  var sortByReference = false;
  var fromTypeStr = '';
  var toTypeStr = '';
  var istr = '';
  var tmpFrom = [];
  var tmpTo = [];
  var ret = '';
  var match = false;

  // Received replace_pairs?
  // Convert to normal trFrom->trTo chars
  if ((typeof trFrom === 'undefined' ? 'undefined' : _typeof(trFrom)) === 'object') {
    // Not thread-safe; temporarily set to true
    // @todo: Don't rely on ini here, use internal krsort instead
    sortByReference = iniSet('locutus.sortByReference', false);
    trFrom = krsort(trFrom);
    iniSet('locutus.sortByReference', sortByReference);

    for (fr in trFrom) {
      if (trFrom.hasOwnProperty(fr)) {
        tmpFrom.push(fr);
        tmpTo.push(trFrom[fr]);
      }
    }

    trFrom = tmpFrom;
    trTo = tmpTo;
  }

  // Walk through subject and replace chars when needed
  lenStr = str.length;
  lenFrom = trFrom.length;
  fromTypeStr = typeof trFrom === 'string';
  toTypeStr = typeof trTo === 'string';

  for (i = 0; i < lenStr; i++) {
    match = false;
    if (fromTypeStr) {
      istr = str.charAt(i);
      for (j = 0; j < lenFrom; j++) {
        if (istr === trFrom.charAt(j)) {
          match = true;
          break;
        }
      }
    } else {
      for (j = 0; j < lenFrom; j++) {
        if (str.substr(i, trFrom[j].length) === trFrom[j]) {
          match = true;
          // Fast forward
          i = i + trFrom[j].length - 1;
          break;
        }
      }
    }
    if (match) {
      ret += toTypeStr ? trTo.charAt(j) : trTo[j];
    } else {
      ret += str.charAt(i);
    }
  }

  return ret;
};
//# sourceMappingURL=strtr.js.map

/***/ }),
/* 484 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

module.exports = function krsort(inputArr, sortFlags) {
  //  discuss at: http://locutus.io/php/krsort/
  // original by: GeekFG (http://geekfg.blogspot.com)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: pseudaria (https://github.com/pseudaria)
  //      note 1: The examples are correct, this is a new way
  //      note 1: This function deviates from PHP in returning a copy of the array instead
  //      note 1: of acting by reference and returning true; this was necessary because
  //      note 1: IE does not allow deleting and re-adding of properties without caching
  //      note 1: of property position; you can set the ini of "locutus.sortByReference" to true to
  //      note 1: get the PHP behavior, but use this only if you are in an environment
  //      note 1: such as Firefox extensions where for-in iteration order is fixed and true
  //      note 1: property deletion is supported. Note that we intend to implement the PHP
  //      note 1: behavior by default if IE ever does allow it; only gives shallow copy since
  //      note 1: is by reference in PHP anyways
  //      note 1: Since JS objects' keys are always strings, and (the
  //      note 1: default) SORT_REGULAR flag distinguishes by key type,
  //      note 1: if the content is a numeric string, we treat the
  //      note 1: "original type" as numeric.
  //   example 1: var $data = {d: 'lemon', a: 'orange', b: 'banana', c: 'apple'}
  //   example 1: krsort($data)
  //   example 1: var $result = $data
  //   returns 1: {d: 'lemon', c: 'apple', b: 'banana', a: 'orange'}
  //   example 2: ini_set('locutus.sortByReference', true)
  //   example 2: var $data = {2: 'van', 3: 'Zonneveld', 1: 'Kevin'}
  //   example 2: krsort($data)
  //   example 2: var $result = $data
  //   returns 2: {3: 'Zonneveld', 2: 'van', 1: 'Kevin'}

  var i18nlgd = __webpack_require__(485);
  var strnatcmp = __webpack_require__(486);

  var tmpArr = {};
  var keys = [];
  var sorter;
  var i;
  var k;
  var sortByReference = false;
  var populateArr = {};

  var $global = typeof window !== 'undefined' ? window : global;
  $global.$locutus = $global.$locutus || {};
  var $locutus = $global.$locutus;
  $locutus.php = $locutus.php || {};
  $locutus.php.locales = $locutus.php.locales || {};

  switch (sortFlags) {
    case 'SORT_STRING':
      // compare items as strings
      sorter = function sorter(a, b) {
        return strnatcmp(b, a);
      };
      break;
    case 'SORT_LOCALE_STRING':
      // compare items as strings, based on the current locale
      // (set with i18n_loc_set_default() as of PHP6)
      var loc = i18nlgd();
      sorter = $locutus.locales[loc].sorting;
      break;
    case 'SORT_NUMERIC':
      // compare items numerically
      sorter = function sorter(a, b) {
        return b - a;
      };
      break;
    case 'SORT_REGULAR':
    default:
      // compare items normally (don't change types)
      sorter = function sorter(b, a) {
        var aFloat = parseFloat(a);
        var bFloat = parseFloat(b);
        var aNumeric = aFloat + '' === a;
        var bNumeric = bFloat + '' === b;
        if (aNumeric && bNumeric) {
          return aFloat > bFloat ? 1 : aFloat < bFloat ? -1 : 0;
        } else if (aNumeric && !bNumeric) {
          return 1;
        } else if (!aNumeric && bNumeric) {
          return -1;
        }
        return a > b ? 1 : a < b ? -1 : 0;
      };
      break;
  }

  // Make a list of key names
  for (k in inputArr) {
    if (inputArr.hasOwnProperty(k)) {
      keys.push(k);
    }
  }
  keys.sort(sorter);

  var iniVal = ( true ? __webpack_require__(487)('locutus.sortByReference') : undefined) || 'on';
  sortByReference = iniVal === 'on';
  populateArr = sortByReference ? inputArr : populateArr;

  // Rebuild array with sorted key names
  for (i = 0; i < keys.length; i++) {
    k = keys[i];
    tmpArr[k] = inputArr[k];
    if (sortByReference) {
      delete inputArr[k];
    }
  }
  for (i in tmpArr) {
    if (tmpArr.hasOwnProperty(i)) {
      populateArr[i] = tmpArr[i];
    }
  }

  return sortByReference || populateArr;
};
//# sourceMappingURL=krsort.js.map
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 485 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

module.exports = function i18n_loc_get_default() {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/i18n_loc_get_default/
  // original by: Brett Zamir (http://brett-zamir.me)
  //      note 1: Renamed in PHP6 from locale_get_default(). Not listed yet at php.net.
  //      note 1: List of locales at <http://demo.icu-project.org/icu-bin/locexp>
  //      note 1: To be usable with sort() if it is passed the `SORT_LOCALE_STRING`
  //      note 1: sorting flag: http://php.net/manual/en/function.sort.php
  //   example 1: i18n_loc_get_default()
  //   returns 1: 'en_US_POSIX'
  //   example 2: i18n_loc_set_default('pt_PT')
  //   example 2: i18n_loc_get_default()
  //   returns 2: 'pt_PT'

  var $global = typeof window !== 'undefined' ? window : global;
  $global.$locutus = $global.$locutus || {};
  var $locutus = $global.$locutus;
  $locutus.php = $locutus.php || {};
  $locutus.php.locales = $locutus.php.locales || {};

  return $locutus.php.locale_default || 'en_US_POSIX';
};
//# sourceMappingURL=i18n_loc_get_default.js.map
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 486 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function strnatcmp(a, b) {
  //       discuss at: http://locutus.io/php/strnatcmp/
  //      original by: Martijn Wieringa
  //      improved by: Michael White (http://getsprink.com)
  //      improved by: Jack
  //      bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // reimplemented by: Rafał Kukawski
  //        example 1: strnatcmp('abc', 'abc')
  //        returns 1: 0
  //        example 2: strnatcmp('a', 'b')
  //        returns 2: -1
  //        example 3: strnatcmp('10', '1')
  //        returns 3: 1
  //        example 4: strnatcmp('0000abc', '0abc')
  //        returns 4: 0
  //        example 5: strnatcmp('1239', '12345')
  //        returns 5: -1
  //        example 6: strnatcmp('t01239', 't012345')
  //        returns 6: 1
  //        example 7: strnatcmp('0A', '5N')
  //        returns 7: -1

  var _phpCastString = __webpack_require__(334);

  var leadingZeros = /^0+(?=\d)/;
  var whitespace = /^\s/;
  var digit = /^\d/;

  if (arguments.length !== 2) {
    return null;
  }

  a = _phpCastString(a);
  b = _phpCastString(b);

  if (!a.length || !b.length) {
    return a.length - b.length;
  }

  var i = 0;
  var j = 0;

  a = a.replace(leadingZeros, '');
  b = b.replace(leadingZeros, '');

  while (i < a.length && j < b.length) {
    // skip consecutive whitespace
    while (whitespace.test(a.charAt(i))) {
      i++;
    }while (whitespace.test(b.charAt(j))) {
      j++;
    }var ac = a.charAt(i);
    var bc = b.charAt(j);
    var aIsDigit = digit.test(ac);
    var bIsDigit = digit.test(bc);

    if (aIsDigit && bIsDigit) {
      var bias = 0;
      var fractional = ac === '0' || bc === '0';

      do {
        if (!aIsDigit) {
          return -1;
        } else if (!bIsDigit) {
          return 1;
        } else if (ac < bc) {
          if (!bias) {
            bias = -1;
          }

          if (fractional) {
            return -1;
          }
        } else if (ac > bc) {
          if (!bias) {
            bias = 1;
          }

          if (fractional) {
            return 1;
          }
        }

        ac = a.charAt(++i);
        bc = b.charAt(++j);

        aIsDigit = digit.test(ac);
        bIsDigit = digit.test(bc);
      } while (aIsDigit || bIsDigit);

      if (!fractional && bias) {
        return bias;
      }

      continue;
    }

    if (!ac || !bc) {
      continue;
    } else if (ac < bc) {
      return -1;
    } else if (ac > bc) {
      return 1;
    }

    i++;
    j++;
  }

  var iBeforeStrEnd = i < a.length;
  var jBeforeStrEnd = j < b.length;

  // Check which string ended first
  // return -1 if a, 1 if b, 0 otherwise
  return (iBeforeStrEnd > jBeforeStrEnd) - (iBeforeStrEnd < jBeforeStrEnd);
};
//# sourceMappingURL=strnatcmp.js.map

/***/ }),
/* 487 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

module.exports = function ini_get(varname) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/ini_get/
  // original by: Brett Zamir (http://brett-zamir.me)
  //      note 1: The ini values must be set by ini_set or manually within an ini file
  //   example 1: ini_set('date.timezone', 'Asia/Hong_Kong')
  //   example 1: ini_get('date.timezone')
  //   returns 1: 'Asia/Hong_Kong'

  var $global = typeof window !== 'undefined' ? window : global;
  $global.$locutus = $global.$locutus || {};
  var $locutus = $global.$locutus;
  $locutus.php = $locutus.php || {};
  $locutus.php.ini = $locutus.php.ini || {};

  if ($locutus.php.ini[varname] && $locutus.php.ini[varname].local_value !== undefined) {
    if ($locutus.php.ini[varname].local_value === null) {
      return '';
    }
    return $locutus.php.ini[varname].local_value;
  }

  return '';
};
//# sourceMappingURL=ini_get.js.map
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 488 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

module.exports = function ini_set(varname, newvalue) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/ini_set/
  // original by: Brett Zamir (http://brett-zamir.me)
  //      note 1: This will not set a global_value or access level for the ini item
  //   example 1: ini_set('date.timezone', 'Asia/Hong_Kong')
  //   example 1: ini_set('date.timezone', 'America/Chicago')
  //   returns 1: 'Asia/Hong_Kong'

  var $global = typeof window !== 'undefined' ? window : global;
  $global.$locutus = $global.$locutus || {};
  var $locutus = $global.$locutus;
  $locutus.php = $locutus.php || {};
  $locutus.php.ini = $locutus.php.ini || {};

  $locutus.php.ini = $locutus.php.ini || {};
  $locutus.php.ini[varname] = $locutus.php.ini[varname] || {};

  var oldval = $locutus.php.ini[varname].local_value;

  var lowerStr = (newvalue + '').toLowerCase().trim();
  if (newvalue === true || lowerStr === 'on' || lowerStr === '1') {
    newvalue = 'on';
  }
  if (newvalue === false || lowerStr === 'off' || lowerStr === '0') {
    newvalue = 'off';
  }

  var _setArr = function _setArr(oldval) {
    // Although these are set individually, they are all accumulated
    if (typeof oldval === 'undefined') {
      $locutus.ini[varname].local_value = [];
    }
    $locutus.ini[varname].local_value.push(newvalue);
  };

  switch (varname) {
    case 'extension':
      _setArr(oldval, newvalue);
      break;
    default:
      $locutus.php.ini[varname].local_value = newvalue;
      break;
  }

  return oldval;
};
//# sourceMappingURL=ini_set.js.map
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 489 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function round(value, precision, mode) {
  //  discuss at: http://locutus.io/php/round/
  // original by: Philip Peterson
  //  revised by: Onno Marsman (https://twitter.com/onnomarsman)
  //  revised by: T.Wild
  //  revised by: Rafał Kukawski (http://blog.kukawski.pl)
  //    input by: Greenseed
  //    input by: meo
  //    input by: William
  //    input by: Josep Sanz (http://www.ws3.es/)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  //      note 1: Great work. Ideas for improvement:
  //      note 1: - code more compliant with developer guidelines
  //      note 1: - for implementing PHP constant arguments look at
  //      note 1: the pathinfo() function, it offers the greatest
  //      note 1: flexibility & compatibility possible
  //   example 1: round(1241757, -3)
  //   returns 1: 1242000
  //   example 2: round(3.6)
  //   returns 2: 4
  //   example 3: round(2.835, 2)
  //   returns 3: 2.84
  //   example 4: round(1.1749999999999, 2)
  //   returns 4: 1.17
  //   example 5: round(58551.799999999996, 2)
  //   returns 5: 58551.8

  var m, f, isHalf, sgn; // helper variables
  // making sure precision is integer
  precision |= 0;
  m = Math.pow(10, precision);
  value *= m;
  // sign of the number
  sgn = value > 0 | -(value < 0);
  isHalf = value % 1 === 0.5 * sgn;
  f = Math.floor(value);

  if (isHalf) {
    switch (mode) {
      case 'PHP_ROUND_HALF_DOWN':
        // rounds .5 toward zero
        value = f + (sgn < 0);
        break;
      case 'PHP_ROUND_HALF_EVEN':
        // rouds .5 towards the next even integer
        value = f + f % 2 * sgn;
        break;
      case 'PHP_ROUND_HALF_ODD':
        // rounds .5 towards the next odd integer
        value = f + !(f % 2);
        break;
      default:
        // rounds .5 away from zero
        value = f + (sgn > 0);
    }
  }

  return (isHalf ? value : Math.round(value)) / m;
};
//# sourceMappingURL=round.js.map

/***/ }),
/* 490 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function ceil(value) {
  //  discuss at: http://locutus.io/php/ceil/
  // original by: Onno Marsman (https://twitter.com/onnomarsman)
  //   example 1: ceil(8723321.4)
  //   returns 1: 8723322

  return Math.ceil(value);
};
//# sourceMappingURL=ceil.js.map

/***/ }),
/* 491 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function floor(value) {
  //  discuss at: http://locutus.io/php/floor/
  // original by: Onno Marsman (https://twitter.com/onnomarsman)
  //   example 1: floor(8723321.4)
  //   returns 1: 8723321

  return Math.floor(value);
};
//# sourceMappingURL=floor.js.map

/***/ }),
/* 492 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function bin2hex(s) {
  //  discuss at: http://locutus.io/php/bin2hex/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // bugfixed by: Linuxworld
  // improved by: ntoniazzi (http://locutus.io/php/bin2hex:361#comment_177616)
  //   example 1: bin2hex('Kev')
  //   returns 1: '4b6576'
  //   example 2: bin2hex(String.fromCharCode(0x00))
  //   returns 2: '00'

  var i;
  var l;
  var o = '';
  var n;

  s += '';

  for (i = 0, l = s.length; i < l; i++) {
    n = s.charCodeAt(i).toString(16);
    o += n.length < 2 ? '0' + n : n;
  }

  return o;
};
//# sourceMappingURL=bin2hex.js.map

/***/ }),
/* 493 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = __webpack_require__(494);


/***/ }),
/* 494 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(Buffer) {/*
 * Utilities for truncating text fields to fit into some Oracle tables.
 * Truncate must be done binary-wise on an UTF-8 string.
 * Ex. a 4000 chars UTF-8 french string may takes ~4200 bytes (depending on content)
 *
 * Note : even if default, we explicitely specify «utf8» since it's a requirement.
 */


var _ = __webpack_require__(1);

var DEFAULT_TRUNCATE_STRING = '...';
var DEFAULT_TRUNCATE_STRING_BINARY_SIZE = Buffer.byteLength(DEFAULT_TRUNCATE_STRING, 'utf8');

module.exports = {
  getBinarySize: getBinarySize,
  truncateToBinarySize: truncateToBinarySize,
  truncateFieldsToBinarySize: truncateFieldsToBinarySize,
  truncateToCharLength: truncateToCharLength,
};

/* Return size, in bytes, of the given UTF-8 string.

 * @param [String] string
 * @return [Number] size of the string in bytes
 */
function getBinarySize(string) {
  return Buffer.byteLength(string || '', 'utf8');
}

/*
 * Get a copy of the given UTF-8 string truncated to a max *binary* size.
 * Avoid truncating in the middle of an UTF-8 char.
 * If truncated, the returned string will have a trailing "...",
 * still respecting the max binary size.
 *
 * Note : desired binary size must be at last 3.
 * Note : the returned string size may be smaller than desired size due to UTF-8 wide chars.
 *
 * @param [String] string
 * @param [Number] binaryMaxSize - the max size we should enforce
 * @param [function()] truncateCallback - if provided, function to be called when a truncating occur.
 *                   Useful for ex. displaying a warning.
 */
function truncateToBinarySize(string, binaryMaxSize, truncateCallback) {
  string = string || '';
  if(getBinarySize(string) <= binaryMaxSize) return string; // OK


  // we'll use buffer.write to truncate,
  // since it doesn't overflow neither write partial UTF-8 characters.
  var truncatingBuffer = new Buffer(binaryMaxSize - DEFAULT_TRUNCATE_STRING_BINARY_SIZE);
  var writtenBinaryLength = truncatingBuffer.write(string, 'utf8');
  var truncatedString = truncatingBuffer.toString('utf8', 0, writtenBinaryLength) + DEFAULT_TRUNCATE_STRING;

  if(truncateCallback) truncateCallback(binaryMaxSize, string, truncatedString);

  return truncatedString;
}

/*
 * On the given object, apply truncateToBinarySize to all members
 * for whom a binary max size is provided.
 * Useful to quickly truncate a model.
 * @see truncateToBinarySize
 *
 * @param [Object]
 * @param [Object] maxSizes - a hash {<member name>: <max binary size>}
 * @param [function(field, actualSize, maxSize)] truncateCallback
 *                   if provided, function to be called when a truncating occur.
 */
function truncateFieldsToBinarySize(model, maxSizes, truncateCallback) {
  return _.transform(
    model,
    function (result, value, key) {
      if(_.includes(Object.keys(maxSizes), key))  {
        var callback = function(binaryMaxSize, string, truncatedString) {
          if(truncateCallback) truncateCallback(binaryMaxSize, string, truncatedString, key);
        };
        value = truncateToBinarySize(value, maxSizes[key], callback);
      }
      result[key] = value;
    }
  );
}

/*
 * Get a copy of the givenstring truncated to a max length.
 * If truncated, the returned string will have a trailing "...",
 * still respecting the max length.
 *
 * Note : desired length must be at last 3.
 *
 * @param [String] string
 * @param [Number] maxLength - the max length we should enforce
 * @param [function()] truncateCallback - if provided, function to be called when a truncating occur.
 *                   Useful for ex. displaying a warning.
 */
function truncateToCharLength(string, maxLength, truncateCallback) {
  string = string || '';
  if(string.length <= maxLength) return string; // OK

  var truncatedString = string.slice(0, maxLength-DEFAULT_TRUNCATE_STRING.length) + DEFAULT_TRUNCATE_STRING;

  if(truncateCallback) truncateCallback(maxLength, string, truncatedString);

  return truncatedString;
}

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(116).Buffer))

/***/ }),
/* 495 */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function(global, factory) {
    if (true) {
        // AMD
        !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
				__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
				(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
    } else {}
})(this, function() {
    'use strict';

    return function(str) {
        if (str == null) return '';

        return String(str).
            replace(/&/g, '&amp;').
            replace(/</g, '&lt;').
            replace(/>/g, '&gt;').
            replace(/"/g, '&quot;').
            replace(/'/g, '&#039;');
    };
});


/***/ }),
/* 496 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function ord(string) {
  //  discuss at: http://locutus.io/php/ord/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // improved by: Brett Zamir (http://brett-zamir.me)
  //    input by: incidence
  //   example 1: ord('K')
  //   returns 1: 75
  //   example 2: ord('\uD800\uDC00'); // surrogate pair to create a single Unicode character
  //   returns 2: 65536

  var str = string + '';
  var code = str.charCodeAt(0);

  if (code >= 0xD800 && code <= 0xDBFF) {
    // High surrogate (could change last hex to 0xDB7F to treat
    // high private surrogates as single characters)
    var hi = code;
    if (str.length === 1) {
      // This is just a high surrogate with no following low surrogate,
      // so we return its value;
      return code;
      // we could also throw an error as it is not a complete character,
      // but someone may want to know
    }
    var low = str.charCodeAt(1);
    return (hi - 0xD800) * 0x400 + (low - 0xDC00) + 0x10000;
  }
  if (code >= 0xDC00 && code <= 0xDFFF) {
    // Low surrogate
    // This is just a low surrogate with no preceding high surrogate,
    // so we return its value;
    return code;
    // we could also throw an error as it is not a complete character,
    // but someone may want to know
  }

  return code;
};
//# sourceMappingURL=ord.js.map

/***/ }),
/* 497 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function number_format(number, decimals, decPoint, thousandsSep) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/number_format/
  // original by: Jonas Raoni Soares Silva (http://www.jsfromhell.com)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: davook
  // improved by: Brett Zamir (http://brett-zamir.me)
  // improved by: Brett Zamir (http://brett-zamir.me)
  // improved by: Theriault (https://github.com/Theriault)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Michael White (http://getsprink.com)
  // bugfixed by: Benjamin Lupton
  // bugfixed by: Allan Jensen (http://www.winternet.no)
  // bugfixed by: Howard Yeend
  // bugfixed by: Diogo Resende
  // bugfixed by: Rival
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  //  revised by: Jonas Raoni Soares Silva (http://www.jsfromhell.com)
  //  revised by: Luke Smith (http://lucassmith.name)
  //    input by: Kheang Hok Chin (http://www.distantia.ca/)
  //    input by: Jay Klehr
  //    input by: Amir Habibi (http://www.residence-mixte.com/)
  //    input by: Amirouche
  //   example 1: number_format(1234.56)
  //   returns 1: '1,235'
  //   example 2: number_format(1234.56, 2, ',', ' ')
  //   returns 2: '1 234,56'
  //   example 3: number_format(1234.5678, 2, '.', '')
  //   returns 3: '1234.57'
  //   example 4: number_format(67, 2, ',', '.')
  //   returns 4: '67,00'
  //   example 5: number_format(1000)
  //   returns 5: '1,000'
  //   example 6: number_format(67.311, 2)
  //   returns 6: '67.31'
  //   example 7: number_format(1000.55, 1)
  //   returns 7: '1,000.6'
  //   example 8: number_format(67000, 5, ',', '.')
  //   returns 8: '67.000,00000'
  //   example 9: number_format(0.9, 0)
  //   returns 9: '1'
  //  example 10: number_format('1.20', 2)
  //  returns 10: '1.20'
  //  example 11: number_format('1.20', 4)
  //  returns 11: '1.2000'
  //  example 12: number_format('1.2000', 3)
  //  returns 12: '1.200'
  //  example 13: number_format('1 000,50', 2, '.', ' ')
  //  returns 13: '100 050.00'
  //  example 14: number_format(1e-8, 8, '.', '')
  //  returns 14: '0.00000001'

  number = (number + '').replace(/[^0-9+\-Ee.]/g, '');
  var n = !isFinite(+number) ? 0 : +number;
  var prec = !isFinite(+decimals) ? 0 : Math.abs(decimals);
  var sep = typeof thousandsSep === 'undefined' ? ',' : thousandsSep;
  var dec = typeof decPoint === 'undefined' ? '.' : decPoint;
  var s = '';

  var toFixedFix = function toFixedFix(n, prec) {
    if (('' + n).indexOf('e') === -1) {
      return +(Math.round(n + 'e+' + prec) + 'e-' + prec);
    } else {
      var arr = ('' + n).split('e');
      var sig = '';
      if (+arr[1] + prec > 0) {
        sig = '+';
      }
      return (+(Math.round(+arr[0] + 'e' + sig + (+arr[1] + prec)) + 'e-' + prec)).toFixed(prec);
    }
  };

  // @todo: for IE parseFloat(0.55).toFixed(0) = 0;
  s = (prec ? toFixedFix(n, prec).toString() : '' + Math.round(n)).split('.');
  if (s[0].length > 3) {
    s[0] = s[0].replace(/\B(?=(?:\d{3})+(?!\d))/g, sep);
  }
  if ((s[1] || '').length < prec) {
    s[1] = s[1] || '';
    s[1] += new Array(prec - s[1].length + 1).join('0');
  }

  return s.join(dec);
};
//# sourceMappingURL=number_format.js.map

/***/ }),
/* 498 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function http_build_query(formdata, numericPrefix, argSeparator, encType) {
  // eslint-disable-line camelcase
  //  discuss at: http://locutus.io/php/http_build_query/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Legaev Andrey
  // improved by: Michael White (http://getsprink.com)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Brett Zamir (http://brett-zamir.me)
  //  revised by: stag019
  //    input by: Dreamer
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: MIO_KODUKI (http://mio-koduki.blogspot.com/)
  // improved by: Will Rowe
  //      note 1: If the value is null, key and value are skipped in the
  //      note 1: http_build_query of PHP while in locutus they are not.
  //   example 1: http_build_query({foo: 'bar', php: 'hypertext processor', baz: 'boom', cow: 'milk'}, '', '&amp;')
  //   returns 1: 'foo=bar&amp;php=hypertext+processor&amp;baz=boom&amp;cow=milk'
  //   example 2: http_build_query({'php': 'hypertext processor', 0: 'foo', 1: 'bar', 2: 'baz', 3: 'boom', 'cow': 'milk'}, 'myvar_')
  //   returns 2: 'myvar_0=foo&myvar_1=bar&myvar_2=baz&myvar_3=boom&php=hypertext+processor&cow=milk'
  //   example 3: http_build_query({foo: 'bar', php: 'hypertext processor', baz: 'boom', cow: 'milk'}, '', '&amp;', 'PHP_QUERY_RFC3986')
  //   returns 3: 'foo=bar&amp;php=hypertext%20processor&amp;baz=boom&amp;cow=milk'

  var encodeFunc;

  switch (encType) {
    case 'PHP_QUERY_RFC3986':
      encodeFunc = __webpack_require__(338);
      break;

    case 'PHP_QUERY_RFC1738':
    default:
      encodeFunc = __webpack_require__(499);
      break;
  }

  var value;
  var key;
  var tmp = [];

  var _httpBuildQueryHelper = function _httpBuildQueryHelper(key, val, argSeparator) {
    var k;
    var tmp = [];
    if (val === true) {
      val = '1';
    } else if (val === false) {
      val = '0';
    }
    if (val !== null) {
      if ((typeof val === 'undefined' ? 'undefined' : _typeof(val)) === 'object') {
        for (k in val) {
          if (val[k] !== null) {
            tmp.push(_httpBuildQueryHelper(key + '[' + k + ']', val[k], argSeparator));
          }
        }
        return tmp.join(argSeparator);
      } else if (typeof val !== 'function') {
        return encodeFunc(key) + '=' + encodeFunc(val);
      } else {
        throw new Error('There was an error processing for http_build_query().');
      }
    } else {
      return '';
    }
  };

  if (!argSeparator) {
    argSeparator = '&';
  }
  for (key in formdata) {
    value = formdata[key];
    if (numericPrefix && !isNaN(key)) {
      key = String(numericPrefix) + key;
    }
    var query = _httpBuildQueryHelper(key, value, argSeparator);
    if (query !== '') {
      tmp.push(query);
    }
  }

  return tmp.join(argSeparator);
};
//# sourceMappingURL=http_build_query.js.map

/***/ }),
/* 499 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function urlencode(str) {
  //       discuss at: http://locutus.io/php/urlencode/
  //      original by: Philip Peterson
  //      improved by: Kevin van Zonneveld (http://kvz.io)
  //      improved by: Kevin van Zonneveld (http://kvz.io)
  //      improved by: Brett Zamir (http://brett-zamir.me)
  //      improved by: Lars Fischer
  //      improved by: Waldo Malqui Silva (https://fayr.us/waldo/)
  //         input by: AJ
  //         input by: travc
  //         input by: Brett Zamir (http://brett-zamir.me)
  //         input by: Ratheous
  //      bugfixed by: Kevin van Zonneveld (http://kvz.io)
  //      bugfixed by: Kevin van Zonneveld (http://kvz.io)
  //      bugfixed by: Joris
  // reimplemented by: Brett Zamir (http://brett-zamir.me)
  // reimplemented by: Brett Zamir (http://brett-zamir.me)
  //           note 1: This reflects PHP 5.3/6.0+ behavior
  //           note 1: Please be aware that this function
  //           note 1: expects to encode into UTF-8 encoded strings, as found on
  //           note 1: pages served as UTF-8
  //        example 1: urlencode('Kevin van Zonneveld!')
  //        returns 1: 'Kevin+van+Zonneveld%21'
  //        example 2: urlencode('http://kvz.io/')
  //        returns 2: 'http%3A%2F%2Fkvz.io%2F'
  //        example 3: urlencode('http://www.google.nl/search?q=Locutus&ie=utf-8')
  //        returns 3: 'http%3A%2F%2Fwww.google.nl%2Fsearch%3Fq%3DLocutus%26ie%3Dutf-8'

  str = str + '';

  return encodeURIComponent(str).replace(/!/g, '%21').replace(/'/g, '%27').replace(/\(/g, '%28').replace(/\)/g, '%29').replace(/\*/g, '%2A').replace(/~/g, '%7E').replace(/%20/g, '+');
};
//# sourceMappingURL=urlencode.js.map

/***/ }),
/* 500 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function explode(delimiter, string, limit) {
  //  discuss at: http://locutus.io/php/explode/
  // original by: Kevin van Zonneveld (http://kvz.io)
  //   example 1: explode(' ', 'Kevin van Zonneveld')
  //   returns 1: [ 'Kevin', 'van', 'Zonneveld' ]

  if (arguments.length < 2 || typeof delimiter === 'undefined' || typeof string === 'undefined') {
    return null;
  }
  if (delimiter === '' || delimiter === false || delimiter === null) {
    return false;
  }
  if (typeof delimiter === 'function' || (typeof delimiter === 'undefined' ? 'undefined' : _typeof(delimiter)) === 'object' || typeof string === 'function' || (typeof string === 'undefined' ? 'undefined' : _typeof(string)) === 'object') {
    return {
      0: ''
    };
  }
  if (delimiter === true) {
    delimiter = '1';
  }

  // Here we go...
  delimiter += '';
  string += '';

  var s = string.split(delimiter);

  if (typeof limit === 'undefined') return s;

  // Support for limit
  if (limit === 0) limit = 1;

  // Positive limit
  if (limit > 0) {
    if (limit >= s.length) {
      return s;
    }
    return s.slice(0, limit - 1).concat([s.slice(limit - 1).join(delimiter)]);
  }

  // Negative limit
  if (-limit >= s.length) {
    return [];
  }

  s.splice(s.length + limit);
  return s;
};
//# sourceMappingURL=explode.js.map

/***/ }),
/* 501 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(module, global) {var __WEBPACK_AMD_DEFINE_RESULT__;/*! https://mths.be/esrever v0.2.0 by @mathias */
;(function(root) {

	// Detect free variables `exports`
	var freeExports =  true && exports;

	// Detect free variable `module`
	var freeModule =  true && module &&
		module.exports == freeExports && module;

	// Detect free variable `global`, from Node.js or Browserified code,
	// and use it as `root`
	var freeGlobal = typeof global == 'object' && global;
	if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal) {
		root = freeGlobal;
	}

	/*--------------------------------------------------------------------------*/

	var regexSymbolWithCombiningMarks = /([\0-\u02FF\u0370-\u1AAF\u1B00-\u1DBF\u1E00-\u20CF\u2100-\uD7FF\uE000-\uFE1F\uFE30-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])([\u0300-\u036F\u1AB0-\u1AFF\u1DC0-\u1DFF\u20D0-\u20FF\uFE20-\uFE2F]+)/g;
	var regexSurrogatePair = /([\uD800-\uDBFF])([\uDC00-\uDFFF])/g;

	var reverse = function(string) {
		// Step 1: deal with combining marks and astral symbols (surrogate pairs)
		string = string
			// Swap symbols with their combining marks so the combining marks go first
			.replace(regexSymbolWithCombiningMarks, function($0, $1, $2) {
				// Reverse the combining marks so they will end up in the same order
				// later on (after another round of reversing)
				return reverse($2) + $1;
			})
			// Swap high and low surrogates so the low surrogates go first
			.replace(regexSurrogatePair, '$2$1');
		// Step 2: reverse the code units in the string
		var result = '';
		var index = string.length;
		while (index--) {
			result += string.charAt(index);
		}
		return result;
	};

	/*--------------------------------------------------------------------------*/

	var esrever = {
		'version': '0.2.0',
		'reverse': reverse
	};

	// Some AMD build optimizers, like r.js, check for specific condition patterns
	// like the following:
	if (
		true
	) {
		!(__WEBPACK_AMD_DEFINE_RESULT__ = (function() {
			return esrever;
		}).call(exports, __webpack_require__, exports, module),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
	}	else { var key; }

}(this));

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(23)(module), __webpack_require__(9)))

/***/ }),
/* 502 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function trim(str, charlist) {
  //  discuss at: http://locutus.io/php/trim/
  // original by: Kevin van Zonneveld (http://kvz.io)
  // improved by: mdsjack (http://www.mdsjack.bo.it)
  // improved by: Alexander Ermolaev (http://snippets.dzone.com/user/AlexanderErmolaev)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Steven Levithan (http://blog.stevenlevithan.com)
  // improved by: Jack
  //    input by: Erkekjetter
  //    input by: DxGx
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  //   example 1: trim('    Kevin van Zonneveld    ')
  //   returns 1: 'Kevin van Zonneveld'
  //   example 2: trim('Hello World', 'Hdle')
  //   returns 2: 'o Wor'
  //   example 3: trim(16, 1)
  //   returns 3: '6'

  var whitespace = [' ', '\n', '\r', '\t', '\f', '\x0b', '\xa0', '\u2000', '\u2001', '\u2002', '\u2003', '\u2004', '\u2005', '\u2006', '\u2007', '\u2008', '\u2009', '\u200A', '\u200B', '\u2028', '\u2029', '\u3000'].join('');
  var l = 0;
  var i = 0;
  str += '';

  if (charlist) {
    whitespace = (charlist + '').replace(/([[\]().?/*{}+$^:])/g, '$1');
  }

  l = str.length;
  for (i = 0; i < l; i++) {
    if (whitespace.indexOf(str.charAt(i)) === -1) {
      str = str.substring(i);
      break;
    }
  }

  l = str.length;
  for (i = l - 1; i >= 0; i--) {
    if (whitespace.indexOf(str.charAt(i)) === -1) {
      str = str.substring(0, i + 1);
      break;
    }
  }

  return whitespace.indexOf(str.charAt(0)) === -1 ? str : '';
};
//# sourceMappingURL=trim.js.map

/***/ }),
/* 503 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


module.exports = function ucwords(str) {
  //  discuss at: http://locutus.io/php/ucwords/
  // original by: Jonas Raoni Soares Silva (http://www.jsfromhell.com)
  // improved by: Waldo Malqui Silva (http://waldo.malqui.info)
  // improved by: Robin
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Onno Marsman (https://twitter.com/onnomarsman)
  // bugfixed by: Cetvertacov Alexandr (https://github.com/cetver)
  //    input by: James (http://www.james-bell.co.uk/)
  //   example 1: ucwords('kevin van  zonneveld')
  //   returns 1: 'Kevin Van  Zonneveld'
  //   example 2: ucwords('HELLO WORLD')
  //   returns 2: 'HELLO WORLD'
  //   example 3: ucwords('у мэри был маленький ягненок и она его очень любила')
  //   returns 3: 'У Мэри Был Маленький Ягненок И Она Его Очень Любила'
  //   example 4: ucwords('τάχιστη αλώπηξ βαφής ψημένη γη, δρασκελίζει υπέρ νωθρού κυνός')
  //   returns 4: 'Τάχιστη Αλώπηξ Βαφής Ψημένη Γη, Δρασκελίζει Υπέρ Νωθρού Κυνός'

  return (str + '').replace(/^(.)|\s+(.)/g, function ($1) {
    return $1.toUpperCase();
  });
};
//# sourceMappingURL=ucwords.js.map

/***/ }),
/* 504 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeComment extends node_1.TwingNode {
    constructor(data, lineno, columnno) {
        super(new Map(), new Map([['data', data]]), lineno, columnno);
        this.type = node_1.TwingNodeType.COMMENT;
    }
    compile(compiler) {
        // noop
    }
}
exports.TwingNodeComment = TwingNodeComment;


/***/ }),
/* 505 */
/***/ (function(module, exports, __webpack_require__) {

var require;var require;!function(e){if(true)module.exports=e();else { var t; }}(function(){return function e(t,n,r){function o(u,a){if(!n[u]){if(!t[u]){var f="function"==typeof require&&require;if(!a&&f)return require(u,!0);if(i)return i(u,!0);throw new Error("Cannot find module '"+u+"'")}var s=n[u]={exports:{}};t[u][0].call(s.exports,function(e){var n=t[u][1][e];return o(n?n:e)},s,s.exports,e,t,n,r)}return n[u].exports}for(var i="function"==typeof require&&require,u=0;u<r.length;u++)o(r[u]);return o}({1:[function(e,t,n){(function(r,o,i,u,a,f,s,c,l){"use strict";function d(e,t){return t=h(e,t),g(e,t)}function h(e,t){if(t=t||{},t.algorithm=t.algorithm||"sha1",t.encoding=t.encoding||"hex",t.excludeValues=!!t.excludeValues,t.algorithm=t.algorithm.toLowerCase(),t.encoding=t.encoding.toLowerCase(),t.ignoreUnknown=t.ignoreUnknown===!0,t.respectType=t.respectType!==!1,t.respectFunctionNames=t.respectFunctionNames!==!1,t.respectFunctionProperties=t.respectFunctionProperties!==!1,t.unorderedArrays=t.unorderedArrays===!0,t.unorderedSets=t.unorderedSets!==!1,t.unorderedObjects=t.unorderedObjects!==!1,t.replacer=t.replacer||void 0,t.excludeKeys=t.excludeKeys||void 0,"undefined"==typeof e)throw new Error("Object argument required.");for(var n=0;n<v.length;++n)v[n].toLowerCase()===t.algorithm.toLowerCase()&&(t.algorithm=v[n]);if(v.indexOf(t.algorithm)===-1)throw new Error('Algorithm "'+t.algorithm+'"  not supported. supported values: '+v.join(", "));if(m.indexOf(t.encoding)===-1&&"passthrough"!==t.algorithm)throw new Error('Encoding "'+t.encoding+'"  not supported. supported values: '+m.join(", "));return t}function p(e){if("function"!=typeof e)return!1;var t=/^function\s+\w*\s*\(\s*\)\s*{\s+\[native code\]\s+}$/i;return null!=t.exec(Function.prototype.toString.call(e))}function g(e,t){var n;n="passthrough"!==t.algorithm?b.createHash(t.algorithm):new w,"undefined"==typeof n.write&&(n.write=n.update,n.end=n.update);var r=y(t,n);if(r.dispatch(e),n.update||n.end(""),n.digest)return n.digest("buffer"===t.encoding?void 0:t.encoding);var o=n.read();return"buffer"===t.encoding?o:o.toString(t.encoding)}function y(e,t,n){n=n||[];var r=function(e){return t.update?t.update(e,"utf8"):t.write(e,"utf8")};return{dispatch:function(t){e.replacer&&(t=e.replacer(t));var n=typeof t;return null===t&&(n="null"),this["_"+n](t)},_object:function(t){var o=/\[object (.*)\]/i,u=Object.prototype.toString.call(t),a=o.exec(u);a=a?a[1]:"unknown:["+u+"]",a=a.toLowerCase();var f=null;if((f=n.indexOf(t))>=0)return this.dispatch("[CIRCULAR:"+f+"]");if(n.push(t),"undefined"!=typeof i&&i.isBuffer&&i.isBuffer(t))return r("buffer:"),r(t);if("object"===a||"function"===a){var s=Object.keys(t);e.unorderedObjects&&(s=s.sort()),e.respectType===!1||p(t)||s.splice(0,0,"prototype","__proto__","constructor"),e.excludeKeys&&(s=s.filter(function(t){return!e.excludeKeys(t)})),r("object:"+s.length+":");var c=this;return s.forEach(function(n){c.dispatch(n),r(":"),e.excludeValues||c.dispatch(t[n]),r(",")})}if(!this["_"+a]){if(e.ignoreUnknown)return r("["+a+"]");throw new Error('Unknown object type "'+a+'"')}this["_"+a](t)},_array:function(t,o){o="undefined"!=typeof o?o:e.unorderedArrays!==!1;var i=this;if(r("array:"+t.length+":"),!o||t.length<=1)return t.forEach(function(e){return i.dispatch(e)});var u=[],a=t.map(function(t){var r=new w,o=n.slice(),i=y(e,r,o);return i.dispatch(t),u=u.concat(o.slice(n.length)),r.read().toString()});return n=n.concat(u),a.sort(),this._array(a,!1)},_date:function(e){return r("date:"+e.toJSON())},_symbol:function(e){return r("symbol:"+e.toString())},_error:function(e){return r("error:"+e.toString())},_boolean:function(e){return r("bool:"+e.toString())},_string:function(e){r("string:"+e.length+":"),r(e.toString())},_function:function(t){r("fn:"),p(t)?this.dispatch("[native]"):this.dispatch(t.toString()),e.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(t.name)),e.respectFunctionProperties&&this._object(t)},_number:function(e){return r("number:"+e.toString())},_xml:function(e){return r("xml:"+e.toString())},_null:function(){return r("Null")},_undefined:function(){return r("Undefined")},_regexp:function(e){return r("regex:"+e.toString())},_uint8array:function(e){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(e))},_uint8clampedarray:function(e){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(e))},_int8array:function(e){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(e))},_uint16array:function(e){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(e))},_int16array:function(e){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(e))},_uint32array:function(e){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(e))},_int32array:function(e){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(e))},_float32array:function(e){return r("float32array:"),this.dispatch(Array.prototype.slice.call(e))},_float64array:function(e){return r("float64array:"),this.dispatch(Array.prototype.slice.call(e))},_arraybuffer:function(e){return r("arraybuffer:"),this.dispatch(new Uint8Array(e))},_url:function(e){return r("url:"+e.toString(),"utf8")},_map:function(t){r("map:");var n=Array.from(t);return this._array(n,e.unorderedSets!==!1)},_set:function(t){r("set:");var n=Array.from(t);return this._array(n,e.unorderedSets!==!1)},_blob:function(){if(e.ignoreUnknown)return r("[blob]");throw Error('Hashing Blob objects is currently not supported\n(see https://github.com/puleos/object-hash/issues/26)\nUse "options.replacer" or "options.ignoreUnknown"\n')},_domwindow:function(){return r("domwindow")},_process:function(){return r("process")},_timer:function(){return r("timer")},_pipe:function(){return r("pipe")},_tcp:function(){return r("tcp")},_udp:function(){return r("udp")},_tty:function(){return r("tty")},_statwatcher:function(){return r("statwatcher")},_securecontext:function(){return r("securecontext")},_connection:function(){return r("connection")},_zlib:function(){return r("zlib")},_context:function(){return r("context")},_nodescript:function(){return r("nodescript")},_httpparser:function(){return r("httpparser")},_dataview:function(){return r("dataview")},_signal:function(){return r("signal")},_fsevent:function(){return r("fsevent")},_tlswrap:function(){return r("tlswrap")}}}function w(){return{buf:"",write:function(e){this.buf+=e},end:function(e){this.buf+=e},read:function(){return this.buf}}}var b=e("crypto");n=t.exports=d,n.sha1=function(e){return d(e)},n.keys=function(e){return d(e,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},n.MD5=function(e){return d(e,{algorithm:"md5",encoding:"hex"})},n.keysMD5=function(e){return d(e,{algorithm:"md5",encoding:"hex",excludeValues:!0})};var v=b.getHashes?b.getHashes().slice():["sha1","md5"];v.push("passthrough");var m=["buffer","hex","binary","base64"];n.writeToStream=function(e,t,n){return"undefined"==typeof n&&(n=t,t={}),t=h(e,t),y(t,n).dispatch(e)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_e8180ef5.js","/")},{buffer:3,crypto:5,lYpoI2:10}],2:[function(e,t,n){(function(e,t,r,o,i,u,a,f,s){var c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(e){"use strict";function t(e){var t=e.charCodeAt(0);return t===i||t===l?62:t===u||t===d?63:t<a?-1:t<a+10?t-a+26+26:t<s+26?t-s:t<f+26?t-f+26:void 0}function n(e){function n(e){s[l++]=e}var r,i,u,a,f,s;if(e.length%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var c=e.length;f="="===e.charAt(c-2)?2:"="===e.charAt(c-1)?1:0,s=new o(3*e.length/4-f),u=f>0?e.length-4:e.length;var l=0;for(r=0,i=0;r<u;r+=4,i+=3)a=t(e.charAt(r))<<18|t(e.charAt(r+1))<<12|t(e.charAt(r+2))<<6|t(e.charAt(r+3)),n((16711680&a)>>16),n((65280&a)>>8),n(255&a);return 2===f?(a=t(e.charAt(r))<<2|t(e.charAt(r+1))>>4,n(255&a)):1===f&&(a=t(e.charAt(r))<<10|t(e.charAt(r+1))<<4|t(e.charAt(r+2))>>2,n(a>>8&255),n(255&a)),s}function r(e){function t(e){return c.charAt(e)}function n(e){return t(e>>18&63)+t(e>>12&63)+t(e>>6&63)+t(63&e)}var r,o,i,u=e.length%3,a="";for(r=0,i=e.length-u;r<i;r+=3)o=(e[r]<<16)+(e[r+1]<<8)+e[r+2],a+=n(o);switch(u){case 1:o=e[e.length-1],a+=t(o>>2),a+=t(o<<4&63),a+="==";break;case 2:o=(e[e.length-2]<<8)+e[e.length-1],a+=t(o>>10),a+=t(o>>4&63),a+=t(o<<2&63),a+="="}return a}var o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="+".charCodeAt(0),u="/".charCodeAt(0),a="0".charCodeAt(0),f="a".charCodeAt(0),s="A".charCodeAt(0),l="-".charCodeAt(0),d="_".charCodeAt(0);e.toByteArray=n,e.fromByteArray=r}("undefined"==typeof n?this.base64js={}:n)}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:10}],3:[function(e,t,n){(function(t,r,o,i,u,a,f,s,c){function o(e,t,n){if(!(this instanceof o))return new o(e,t,n);var r=typeof e;if("base64"===t&&"string"===r)for(e=N(e);e.length%4!==0;)e+="=";var i;if("number"===r)i=F(e);else if("string"===r)i=o.byteLength(e,t);else{if("object"!==r)throw new Error("First argument needs to be a number, array or string.");i=F(e.length)}var u;o._useTypedArrays?u=o._augment(new Uint8Array(i)):(u=this,u.length=i,u._isBuffer=!0);var a;if(o._useTypedArrays&&"number"==typeof e.byteLength)u._set(e);else if(O(e))for(a=0;a<i;a++)o.isBuffer(e)?u[a]=e.readUInt8(a):u[a]=e[a];else if("string"===r)u.write(e,0,t);else if("number"===r&&!o._useTypedArrays&&!n)for(a=0;a<i;a++)u[a]=0;return u}function l(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;var u=t.length;$(u%2===0,"Invalid hex string"),r>u/2&&(r=u/2);for(var a=0;a<r;a++){var f=parseInt(t.substr(2*a,2),16);$(!isNaN(f),"Invalid hex string"),e[n+a]=f}return o._charsWritten=2*a,a}function d(e,t,n,r){var i=o._charsWritten=W(V(t),e,n,r);return i}function h(e,t,n,r){var i=o._charsWritten=W(q(t),e,n,r);return i}function p(e,t,n,r){return h(e,t,n,r)}function g(e,t,n,r){var i=o._charsWritten=W(R(t),e,n,r);return i}function y(e,t,n,r){var i=o._charsWritten=W(P(t),e,n,r);return i}function w(e,t,n){return 0===t&&n===e.length?G.fromByteArray(e):G.fromByteArray(e.slice(t,n))}function b(e,t,n){var r="",o="";n=Math.min(e.length,n);for(var i=t;i<n;i++)e[i]<=127?(r+=J(o)+String.fromCharCode(e[i]),o=""):o+="%"+e[i].toString(16);return r+J(o)}function v(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;o++)r+=String.fromCharCode(e[o]);return r}function m(e,t,n){return v(e,t,n)}function _(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;i++)o+=H(e[i]);return o}function E(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function I(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+1<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i;return n?(i=e[t],t+1<o&&(i|=e[t+1]<<8)):(i=e[t]<<8,t+1<o&&(i|=e[t+1])),i}}function A(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+3<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i;return n?(t+2<o&&(i=e[t+2]<<16),t+1<o&&(i|=e[t+1]<<8),i|=e[t],t+3<o&&(i+=e[t+3]<<24>>>0)):(t+1<o&&(i=e[t+1]<<16),t+2<o&&(i|=e[t+2]<<8),t+3<o&&(i|=e[t+3]),i+=e[t]<<24>>>0),i}}function B(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+1<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i=I(e,t,n,!0),u=32768&i;return u?(65535-i+1)*-1:i}}function L(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+3<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i=A(e,t,n,!0),u=2147483648&i;return u?(4294967295-i+1)*-1:i}}function U(e,t,n,r){return r||($("boolean"==typeof n,"missing or invalid endian"),$(t+3<e.length,"Trying to read beyond buffer length")),Q.read(e,t,n,23,4)}function x(e,t,n,r){return r||($("boolean"==typeof n,"missing or invalid endian"),$(t+7<e.length,"Trying to read beyond buffer length")),Q.read(e,t,n,52,8)}function S(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+1<e.length,"trying to write beyond buffer length"),K(t,65535));var i=e.length;if(!(n>=i))for(var u=0,a=Math.min(i-n,2);u<a;u++)e[n+u]=(t&255<<8*(r?u:1-u))>>>8*(r?u:1-u)}function j(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+3<e.length,"trying to write beyond buffer length"),K(t,4294967295));var i=e.length;if(!(n>=i))for(var u=0,a=Math.min(i-n,4);u<a;u++)e[n+u]=t>>>8*(r?u:3-u)&255}function C(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+1<e.length,"Trying to write beyond buffer length"),z(t,32767,-32768));var i=e.length;n>=i||(t>=0?S(e,t,n,r,o):S(e,65535+t+1,n,r,o))}function k(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+3<e.length,"Trying to write beyond buffer length"),z(t,2147483647,-2147483648));var i=e.length;n>=i||(t>=0?j(e,t,n,r,o):j(e,4294967295+t+1,n,r,o))}function T(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+3<e.length,"Trying to write beyond buffer length"),X(t,3.4028234663852886e38,-3.4028234663852886e38));var i=e.length;n>=i||Q.write(e,t,n,r,23,4)}function M(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+7<e.length,"Trying to write beyond buffer length"),X(t,1.7976931348623157e308,-1.7976931348623157e308));var i=e.length;n>=i||Q.write(e,t,n,r,52,8)}function N(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Y(e,t,n){return"number"!=typeof e?n:(e=~~e,e>=t?t:e>=0?e:(e+=t,e>=0?e:0))}function F(e){return e=~~Math.ceil(+e),e<0?0:e}function D(e){return(Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)})(e)}function O(e){return D(e)||o.isBuffer(e)||e&&"object"==typeof e&&"number"==typeof e.length}function H(e){return e<16?"0"+e.toString(16):e.toString(16)}function V(e){for(var t=[],n=0;n<e.length;n++){var r=e.charCodeAt(n);if(r<=127)t.push(e.charCodeAt(n));else{var o=n;r>=55296&&r<=57343&&n++;for(var i=encodeURIComponent(e.slice(o,n+1)).substr(1).split("%"),u=0;u<i.length;u++)t.push(parseInt(i[u],16))}}return t}function q(e){for(var t=[],n=0;n<e.length;n++)t.push(255&e.charCodeAt(n));return t}function P(e){for(var t,n,r,o=[],i=0;i<e.length;i++)t=e.charCodeAt(i),n=t>>8,r=t%256,o.push(r),o.push(n);return o}function R(e){return G.toByteArray(e)}function W(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);o++)t[o+n]=e[o];return o}function J(e){try{return decodeURIComponent(e)}catch(t){return String.fromCharCode(65533)}}function K(e,t){$("number"==typeof e,"cannot write a non-number as a number"),$(e>=0,"specified a negative value for writing an unsigned value"),$(e<=t,"value is larger than maximum value for type"),$(Math.floor(e)===e,"value has a fractional component")}function z(e,t,n){$("number"==typeof e,"cannot write a non-number as a number"),$(e<=t,"value larger than maximum allowed value"),$(e>=n,"value smaller than minimum allowed value"),$(Math.floor(e)===e,"value has a fractional component")}function X(e,t,n){$("number"==typeof e,"cannot write a non-number as a number"),$(e<=t,"value larger than maximum allowed value"),$(e>=n,"value smaller than minimum allowed value")}function $(e,t){if(!e)throw new Error(t||"Failed assertion")}var G=e("base64-js"),Q=e("ieee754");n.Buffer=o,n.SlowBuffer=o,n.INSPECT_MAX_BYTES=50,o.poolSize=8192,o._useTypedArrays=function(){try{var e=new ArrayBuffer(0),t=new Uint8Array(e);return t.foo=function(){return 42},42===t.foo()&&"function"==typeof t.subarray}catch(n){return!1}}(),o.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.isBuffer=function(e){return!(null===e||void 0===e||!e._isBuffer)},o.byteLength=function(e,t){var n;switch(e+="",t||"utf8"){case"hex":n=e.length/2;break;case"utf8":case"utf-8":n=V(e).length;break;case"ascii":case"binary":case"raw":n=e.length;break;case"base64":n=R(e).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":n=2*e.length;break;default:throw new Error("Unknown encoding")}return n},o.concat=function(e,t){if($(D(e),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===e.length)return new o(0);if(1===e.length)return e[0];var n;if("number"!=typeof t)for(t=0,n=0;n<e.length;n++)t+=e[n].length;var r=new o(t),i=0;for(n=0;n<e.length;n++){var u=e[n];u.copy(r,i),i+=u.length}return r},o.prototype.write=function(e,t,n,r){if(isFinite(t))isFinite(n)||(r=n,n=void 0);else{var o=r;r=t,t=n,n=o}t=Number(t)||0;var i=this.length-t;n?(n=Number(n),n>i&&(n=i)):n=i,r=String(r||"utf8").toLowerCase();var u;switch(r){case"hex":u=l(this,e,t,n);break;case"utf8":case"utf-8":u=d(this,e,t,n);break;case"ascii":u=h(this,e,t,n);break;case"binary":u=p(this,e,t,n);break;case"base64":u=g(this,e,t,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":u=y(this,e,t,n);break;default:throw new Error("Unknown encoding")}return u},o.prototype.toString=function(e,t,n){var r=this;if(e=String(e||"utf8").toLowerCase(),t=Number(t)||0,n=void 0!==n?Number(n):n=r.length,n===t)return"";var o;switch(e){case"hex":o=_(r,t,n);break;case"utf8":case"utf-8":o=b(r,t,n);break;case"ascii":o=v(r,t,n);break;case"binary":o=m(r,t,n);break;case"base64":o=w(r,t,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":o=E(r,t,n);break;default:throw new Error("Unknown encoding")}return o},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},o.prototype.copy=function(e,t,n,r){var i=this;if(n||(n=0),r||0===r||(r=this.length),t||(t=0),r!==n&&0!==e.length&&0!==i.length){$(r>=n,"sourceEnd < sourceStart"),$(t>=0&&t<e.length,"targetStart out of bounds"),$(n>=0&&n<i.length,"sourceStart out of bounds"),$(r>=0&&r<=i.length,"sourceEnd out of bounds"),r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var u=r-n;if(u<100||!o._useTypedArrays)for(var a=0;a<u;a++)e[a+t]=this[a+n];else e._set(this.subarray(n,n+u),t)}},o.prototype.slice=function(e,t){var n=this.length;if(e=Y(e,n,0),t=Y(t,n,n),o._useTypedArrays)return o._augment(this.subarray(e,t));for(var r=t-e,i=new o(r,(void 0),(!0)),u=0;u<r;u++)i[u]=this[u+e];return i},o.prototype.get=function(e){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(e)},o.prototype.set=function(e,t){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(e,t)},o.prototype.readUInt8=function(e,t){if(t||($(void 0!==e&&null!==e,"missing offset"),$(e<this.length,"Trying to read beyond buffer length")),!(e>=this.length))return this[e]},o.prototype.readUInt16LE=function(e,t){return I(this,e,!0,t)},o.prototype.readUInt16BE=function(e,t){return I(this,e,!1,t)},o.prototype.readUInt32LE=function(e,t){return A(this,e,!0,t)},o.prototype.readUInt32BE=function(e,t){return A(this,e,!1,t)},o.prototype.readInt8=function(e,t){if(t||($(void 0!==e&&null!==e,"missing offset"),$(e<this.length,"Trying to read beyond buffer length")),!(e>=this.length)){var n=128&this[e];return n?(255-this[e]+1)*-1:this[e]}},o.prototype.readInt16LE=function(e,t){return B(this,e,!0,t)},o.prototype.readInt16BE=function(e,t){return B(this,e,!1,t)},o.prototype.readInt32LE=function(e,t){return L(this,e,!0,t)},o.prototype.readInt32BE=function(e,t){return L(this,e,!1,t)},o.prototype.readFloatLE=function(e,t){return U(this,e,!0,t)},o.prototype.readFloatBE=function(e,t){return U(this,e,!1,t)},o.prototype.readDoubleLE=function(e,t){return x(this,e,!0,t)},o.prototype.readDoubleBE=function(e,t){return x(this,e,!1,t)},o.prototype.writeUInt8=function(e,t,n){n||($(void 0!==e&&null!==e,"missing value"),$(void 0!==t&&null!==t,"missing offset"),$(t<this.length,"trying to write beyond buffer length"),K(e,255)),t>=this.length||(this[t]=e)},o.prototype.writeUInt16LE=function(e,t,n){S(this,e,t,!0,n)},o.prototype.writeUInt16BE=function(e,t,n){S(this,e,t,!1,n)},o.prototype.writeUInt32LE=function(e,t,n){j(this,e,t,!0,n)},o.prototype.writeUInt32BE=function(e,t,n){j(this,e,t,!1,n)},o.prototype.writeInt8=function(e,t,n){n||($(void 0!==e&&null!==e,"missing value"),$(void 0!==t&&null!==t,"missing offset"),$(t<this.length,"Trying to write beyond buffer length"),z(e,127,-128)),t>=this.length||(e>=0?this.writeUInt8(e,t,n):this.writeUInt8(255+e+1,t,n))},o.prototype.writeInt16LE=function(e,t,n){C(this,e,t,!0,n)},o.prototype.writeInt16BE=function(e,t,n){C(this,e,t,!1,n)},o.prototype.writeInt32LE=function(e,t,n){k(this,e,t,!0,n)},o.prototype.writeInt32BE=function(e,t,n){k(this,e,t,!1,n)},o.prototype.writeFloatLE=function(e,t,n){T(this,e,t,!0,n)},o.prototype.writeFloatBE=function(e,t,n){T(this,e,t,!1,n)},o.prototype.writeDoubleLE=function(e,t,n){M(this,e,t,!0,n)},o.prototype.writeDoubleBE=function(e,t,n){M(this,e,t,!1,n)},o.prototype.fill=function(e,t,n){if(e||(e=0),t||(t=0),n||(n=this.length),"string"==typeof e&&(e=e.charCodeAt(0)),$("number"==typeof e&&!isNaN(e),"value is not a number"),$(n>=t,"end < start"),n!==t&&0!==this.length){$(t>=0&&t<this.length,"start out of bounds"),$(n>=0&&n<=this.length,"end out of bounds");for(var r=t;r<n;r++)this[r]=e}},o.prototype.inspect=function(){for(var e=[],t=this.length,r=0;r<t;r++)if(e[r]=H(this[r]),r===n.INSPECT_MAX_BYTES){e[r+1]="...";break}return"<Buffer "+e.join(" ")+">"},o.prototype.toArrayBuffer=function(){if("undefined"!=typeof Uint8Array){if(o._useTypedArrays)return new o(this).buffer;for(var e=new Uint8Array(this.length),t=0,n=e.length;t<n;t+=1)e[t]=this[t];return e.buffer}throw new Error("Buffer.toArrayBuffer not supported in this browser")};var Z=o.prototype;o._augment=function(e){return e._isBuffer=!0,e._get=e.get,e._set=e.set,e.get=Z.get,e.set=Z.set,e.write=Z.write,e.toString=Z.toString,e.toLocaleString=Z.toString,e.toJSON=Z.toJSON,e.copy=Z.copy,e.slice=Z.slice,e.readUInt8=Z.readUInt8,e.readUInt16LE=Z.readUInt16LE,e.readUInt16BE=Z.readUInt16BE,e.readUInt32LE=Z.readUInt32LE,e.readUInt32BE=Z.readUInt32BE,e.readInt8=Z.readInt8,e.readInt16LE=Z.readInt16LE,e.readInt16BE=Z.readInt16BE,e.readInt32LE=Z.readInt32LE,e.readInt32BE=Z.readInt32BE,e.readFloatLE=Z.readFloatLE,e.readFloatBE=Z.readFloatBE,e.readDoubleLE=Z.readDoubleLE,e.readDoubleBE=Z.readDoubleBE,e.writeUInt8=Z.writeUInt8,e.writeUInt16LE=Z.writeUInt16LE,e.writeUInt16BE=Z.writeUInt16BE,e.writeUInt32LE=Z.writeUInt32LE,e.writeUInt32BE=Z.writeUInt32BE,e.writeInt8=Z.writeInt8,e.writeInt16LE=Z.writeInt16LE,e.writeInt16BE=Z.writeInt16BE,e.writeInt32LE=Z.writeInt32LE,e.writeInt32BE=Z.writeInt32BE,e.writeFloatLE=Z.writeFloatLE,e.writeFloatBE=Z.writeFloatBE,e.writeDoubleLE=Z.writeDoubleLE,e.writeDoubleBE=Z.writeDoubleBE,e.fill=Z.fill,e.inspect=Z.inspect,e.toArrayBuffer=Z.toArrayBuffer,e}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:11,lYpoI2:10}],4:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){function l(e,t){if(e.length%p!==0){var n=e.length+(p-e.length%p);e=o.concat([e,g],n)}for(var r=[],i=t?e.readInt32BE:e.readInt32LE,u=0;u<e.length;u+=p)r.push(i.call(e,u));return r}function d(e,t,n){for(var r=new o(t),i=n?r.writeInt32BE:r.writeInt32LE,u=0;u<e.length;u++)i.call(r,e[u],4*u,!0);return r}function h(e,t,n,r){o.isBuffer(e)||(e=new o(e));var i=t(l(e,r),e.length*y);return d(i,n,r)}var o=e("buffer").Buffer,p=4,g=new o(p);g.fill(0);var y=8;t.exports={hash:h}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/helpers.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],5:[function(e,t,n){(function(t,r,o,i,u,a,f,s,c){function l(e,t,n){o.isBuffer(t)||(t=new o(t)),o.isBuffer(n)||(n=new o(n)),t.length>m?t=e(t):t.length<m&&(t=o.concat([t,_],m));for(var r=new o(m),i=new o(m),u=0;u<m;u++)r[u]=54^t[u],i[u]=92^t[u];var a=e(o.concat([r,n]));return e(o.concat([i,a]))}function d(e,t){e=e||"sha1";var n=v[e],r=[],i=0;return n||h("algorithm:",e,"is not yet supported"),{update:function(e){return o.isBuffer(e)||(e=new o(e)),r.push(e),i+=e.length,this},digest:function(e){var i=o.concat(r),u=t?l(n,t,i):n(i);return r=null,e?u.toString(e):u}}}function h(){var e=[].slice.call(arguments).join(" ");throw new Error([e,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join("\n"))}function p(e,t){for(var n in e)t(e[n],n)}var o=e("buffer").Buffer,g=e("./sha"),y=e("./sha256"),w=e("./rng"),b=e("./md5"),v={sha1:g,sha256:y,md5:b},m=64,_=new o(m);_.fill(0),n.createHash=function(e){return d(e)},n.createHmac=function(e,t){return d(e,t)},n.randomBytes=function(e,t){if(!t||!t.call)return new o(w(e));try{t.call(this,void 0,new o(w(e)))}catch(n){t(n)}},p(["createCredentials","createCipher","createCipheriv","createDecipher","createDecipheriv","createSign","createVerify","createDiffieHellman","pbkdf2"],function(e){n[e]=function(){h("sorry,",e,"is not implemented yet")}})}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/index.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./md5":6,"./rng":7,"./sha":8,"./sha256":9,buffer:3,lYpoI2:10}],6:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){function l(e,t){e[t>>5]|=128<<t%32,e[(t+64>>>9<<4)+14]=t;for(var n=1732584193,r=-271733879,o=-1732584194,i=271733878,u=0;u<e.length;u+=16){var a=n,f=r,s=o,c=i;n=h(n,r,o,i,e[u+0],7,-680876936),i=h(i,n,r,o,e[u+1],12,-389564586),o=h(o,i,n,r,e[u+2],17,606105819),r=h(r,o,i,n,e[u+3],22,-1044525330),n=h(n,r,o,i,e[u+4],7,-176418897),i=h(i,n,r,o,e[u+5],12,1200080426),o=h(o,i,n,r,e[u+6],17,-1473231341),r=h(r,o,i,n,e[u+7],22,-45705983),n=h(n,r,o,i,e[u+8],7,1770035416),i=h(i,n,r,o,e[u+9],12,-1958414417),o=h(o,i,n,r,e[u+10],17,-42063),r=h(r,o,i,n,e[u+11],22,-1990404162),n=h(n,r,o,i,e[u+12],7,1804603682),i=h(i,n,r,o,e[u+13],12,-40341101),o=h(o,i,n,r,e[u+14],17,-1502002290),r=h(r,o,i,n,e[u+15],22,1236535329),n=p(n,r,o,i,e[u+1],5,-165796510),i=p(i,n,r,o,e[u+6],9,-1069501632),o=p(o,i,n,r,e[u+11],14,643717713),r=p(r,o,i,n,e[u+0],20,-373897302),n=p(n,r,o,i,e[u+5],5,-701558691),i=p(i,n,r,o,e[u+10],9,38016083),o=p(o,i,n,r,e[u+15],14,-660478335),r=p(r,o,i,n,e[u+4],20,-405537848),n=p(n,r,o,i,e[u+9],5,568446438),i=p(i,n,r,o,e[u+14],9,-1019803690),o=p(o,i,n,r,e[u+3],14,-187363961),r=p(r,o,i,n,e[u+8],20,1163531501),n=p(n,r,o,i,e[u+13],5,-1444681467),i=p(i,n,r,o,e[u+2],9,-51403784),o=p(o,i,n,r,e[u+7],14,1735328473),r=p(r,o,i,n,e[u+12],20,-1926607734),n=g(n,r,o,i,e[u+5],4,-378558),i=g(i,n,r,o,e[u+8],11,-2022574463),o=g(o,i,n,r,e[u+11],16,1839030562),r=g(r,o,i,n,e[u+14],23,-35309556),n=g(n,r,o,i,e[u+1],4,-1530992060),i=g(i,n,r,o,e[u+4],11,1272893353),o=g(o,i,n,r,e[u+7],16,-155497632),r=g(r,o,i,n,e[u+10],23,-1094730640),n=g(n,r,o,i,e[u+13],4,681279174),i=g(i,n,r,o,e[u+0],11,-358537222),o=g(o,i,n,r,e[u+3],16,-722521979),r=g(r,o,i,n,e[u+6],23,76029189),n=g(n,r,o,i,e[u+9],4,-640364487),i=g(i,n,r,o,e[u+12],11,-421815835),o=g(o,i,n,r,e[u+15],16,530742520),r=g(r,o,i,n,e[u+2],23,-995338651),n=y(n,r,o,i,e[u+0],6,-198630844),i=y(i,n,r,o,e[u+7],10,1126891415),o=y(o,i,n,r,e[u+14],15,-1416354905),r=y(r,o,i,n,e[u+5],21,-57434055),n=y(n,r,o,i,e[u+12],6,1700485571),i=y(i,n,r,o,e[u+3],10,-1894986606),o=y(o,i,n,r,e[u+10],15,-1051523),r=y(r,o,i,n,e[u+1],21,-2054922799),n=y(n,r,o,i,e[u+8],6,1873313359),i=y(i,n,r,o,e[u+15],10,-30611744),o=y(o,i,n,r,e[u+6],15,-1560198380),r=y(r,o,i,n,e[u+13],21,1309151649),n=y(n,r,o,i,e[u+4],6,-145523070),i=y(i,n,r,o,e[u+11],10,-1120210379),o=y(o,i,n,r,e[u+2],15,718787259),r=y(r,o,i,n,e[u+9],21,-343485551),n=w(n,a),r=w(r,f),o=w(o,s),i=w(i,c)}return Array(n,r,o,i)}function d(e,t,n,r,o,i){return w(b(w(w(t,e),w(r,i)),o),n)}function h(e,t,n,r,o,i,u){return d(t&n|~t&r,e,t,o,i,u)}function p(e,t,n,r,o,i,u){return d(t&r|n&~r,e,t,o,i,u)}function g(e,t,n,r,o,i,u){return d(t^n^r,e,t,o,i,u)}function y(e,t,n,r,o,i,u){return d(n^(t|~r),e,t,o,i,u)}function w(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n}function b(e,t){return e<<t|e>>>32-t}var v=e("./helpers");t.exports=function(e){return v.hash(e,l,16)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],7:[function(e,t,n){(function(e,n,r,o,i,u,a,f,s){!function(){var e,n,r=this;e=function(e){for(var t,t,n=new Array(e),r=0;r<e;r++)0==(3&r)&&(t=4294967296*Math.random()),n[r]=t>>>((3&r)<<3)&255;return n},r.crypto&&crypto.getRandomValues&&(n=function(e){var t=new Uint8Array(e);return crypto.getRandomValues(t),t}),t.exports=n||e}()}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],8:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){function l(e,t){e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var n=Array(80),r=1732584193,o=-271733879,i=-1732584194,u=271733878,a=-1009589776,f=0;f<e.length;f+=16){for(var s=r,c=o,l=i,y=u,w=a,b=0;b<80;b++){b<16?n[b]=e[f+b]:n[b]=g(n[b-3]^n[b-8]^n[b-14]^n[b-16],1);var v=p(p(g(r,5),d(b,o,i,u)),p(p(a,n[b]),h(b)));a=u,u=i,i=g(o,30),o=r,r=v}r=p(r,s),o=p(o,c),i=p(i,l),u=p(u,y),a=p(a,w)}return Array(r,o,i,u,a)}function d(e,t,n,r){return e<20?t&n|~t&r:e<40?t^n^r:e<60?t&n|t&r|n&r:t^n^r}function h(e){return e<20?1518500249:e<40?1859775393:e<60?-1894007588:-899497514}function p(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n}function g(e,t){return e<<t|e>>>32-t}var y=e("./helpers");t.exports=function(e){return y.hash(e,l,20,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],9:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){var l=e("./helpers"),d=function(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n},h=function(e,t){return e>>>t|e<<32-t},p=function(e,t){return e>>>t},g=function(e,t,n){return e&t^~e&n},y=function(e,t,n){return e&t^e&n^t&n},w=function(e){return h(e,2)^h(e,13)^h(e,22);
},b=function(e){return h(e,6)^h(e,11)^h(e,25)},v=function(e){return h(e,7)^h(e,18)^p(e,3)},m=function(e){return h(e,17)^h(e,19)^p(e,10)},_=function(e,t){var n,r,o,i,u,a,f,s,c,l,h,p,_=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),E=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),I=new Array(64);e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var c=0;c<e.length;c+=16){n=E[0],r=E[1],o=E[2],i=E[3],u=E[4],a=E[5],f=E[6],s=E[7];for(var l=0;l<64;l++)l<16?I[l]=e[l+c]:I[l]=d(d(d(m(I[l-2]),I[l-7]),v(I[l-15])),I[l-16]),h=d(d(d(d(s,b(u)),g(u,a,f)),_[l]),I[l]),p=d(w(n),y(n,r,o)),s=f,f=a,a=u,u=d(i,h),i=o,o=r,r=n,n=d(h,p);E[0]=d(n,E[0]),E[1]=d(r,E[1]),E[2]=d(o,E[2]),E[3]=d(i,E[3]),E[4]=d(u,E[4]),E[5]=d(a,E[5]),E[6]=d(f,E[6]),E[7]=d(s,E[7])}return E};t.exports=function(e){return l.hash(e,_,32,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],10:[function(e,t,n){(function(e,n,r,o,i,u,a,f,s){function c(){}var e=t.exports={};e.nextTick=function(){var e="undefined"!=typeof window&&window.setImmediate,t="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(e)return function(e){return window.setImmediate(e)};if(t){var n=[];return window.addEventListener("message",function(e){var t=e.source;if((t===window||null===t)&&"process-tick"===e.data&&(e.stopPropagation(),n.length>0)){var r=n.shift();r()}},!0),function(e){n.push(e),window.postMessage("process-tick","*")}}return function(e){setTimeout(e,0)}}(),e.title="browser",e.browser=!0,e.env={},e.argv=[],e.on=c,e.addListener=c,e.once=c,e.off=c,e.removeListener=c,e.removeAllListeners=c,e.emit=c,e.binding=function(e){throw new Error("process.binding is not supported")},e.cwd=function(){return"/"},e.chdir=function(e){throw new Error("process.chdir is not supported")}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/process/browser.js","/node_modules/gulp-browserify/node_modules/process")},{buffer:3,lYpoI2:10}],11:[function(e,t,n){(function(e,t,r,o,i,u,a,f,s){n.read=function(e,t,n,r,o){var i,u,a=8*o-r-1,f=(1<<a)-1,s=f>>1,c=-7,l=n?o-1:0,d=n?-1:1,h=e[t+l];for(l+=d,i=h&(1<<-c)-1,h>>=-c,c+=a;c>0;i=256*i+e[t+l],l+=d,c-=8);for(u=i&(1<<-c)-1,i>>=-c,c+=r;c>0;u=256*u+e[t+l],l+=d,c-=8);if(0===i)i=1-s;else{if(i===f)return u?NaN:(h?-1:1)*(1/0);u+=Math.pow(2,r),i-=s}return(h?-1:1)*u*Math.pow(2,i-r)},n.write=function(e,t,n,r,o,i){var u,a,f,s=8*i-o-1,c=(1<<s)-1,l=c>>1,d=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=r?0:i-1,p=r?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,u=c):(u=Math.floor(Math.log(t)/Math.LN2),t*(f=Math.pow(2,-u))<1&&(u--,f*=2),t+=u+l>=1?d/f:d*Math.pow(2,1-l),t*f>=2&&(u++,f/=2),u+l>=c?(a=0,u=c):u+l>=1?(a=(t*f-1)*Math.pow(2,o),u+=l):(a=t*Math.pow(2,l-1)*Math.pow(2,o),u=0));o>=8;e[n+h]=255&a,h+=p,a/=256,o-=8);for(u=u<<o|a,s+=o;s>0;e[n+h]=255&u,h+=p,u/=256,s-=8);e[n+h-p]|=128*g}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/ieee754/index.js","/node_modules/ieee754")},{buffer:3,lYpoI2:10}]},{},[1])(1)});

/***/ }),
/* 506 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
class TwingNodeInlinePrint extends node_1.TwingNode {
    constructor(node, lineno, columnno, tag = null) {
        super(new Map([['node', node]]), new Map(), lineno, columnno, tag);
        this.type = node_1.TwingNodeType.INLINE_PRINT;
    }
    compile(compiler) {
        compiler
            .raw('Runtime.echo(')
            .subcompile(this.getNode('node'))
            .raw(')');
    }
}
exports.TwingNodeInlinePrint = TwingNodeInlinePrint;


/***/ }),
/* 507 */
/***/ (function(module, exports, __webpack_require__) {

// https://github.com/paulmillr/es6-shim
// http://people.mozilla.org/~jorendorff/es6-draft.html#sec-number.isinteger
var isFinite = __webpack_require__(508);
module.exports = Number.isInteger || function(val) {
  return typeof val === "number" &&
    isFinite(val) &&
    Math.floor(val) === val;
};


/***/ }),
/* 508 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var numberIsNan = __webpack_require__(509);

module.exports = Number.isFinite || function (val) {
	return !(typeof val !== 'number' || numberIsNan(val) || val === Infinity || val === -Infinity);
};


/***/ }),
/* 509 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

module.exports = Number.isNaN || function (x) {
	return x !== x;
};


/***/ }),
/* 510 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const _isPlainObject = __webpack_require__(336);
function isPlainObject(thing) {
    return _isPlainObject(thing);
}
exports.isPlainObject = isPlainObject;


/***/ }),
/* 511 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

module.exports = function unserialize(data) {
  //  discuss at: http://locutus.io/php/unserialize/
  // original by: Arpad Ray (mailto:arpad@php.net)
  // improved by: Pedro Tainha (http://www.pedrotainha.com)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Kevin van Zonneveld (http://kvz.io)
  // improved by: Chris
  // improved by: James
  // improved by: Le Torbi
  // improved by: Eli Skeggs
  // bugfixed by: dptr1988
  // bugfixed by: Kevin van Zonneveld (http://kvz.io)
  // bugfixed by: Brett Zamir (http://brett-zamir.me)
  // bugfixed by: philippsimon (https://github.com/philippsimon/)
  //  revised by: d3x
  //    input by: Brett Zamir (http://brett-zamir.me)
  //    input by: Martin (http://www.erlenwiese.de/)
  //    input by: kilops
  //    input by: Jaroslaw Czarniak
  //    input by: lovasoa (https://github.com/lovasoa/)
  //      note 1: We feel the main purpose of this function should be
  //      note 1: to ease the transport of data between php & js
  //      note 1: Aiming for PHP-compatibility, we have to translate objects to arrays
  //   example 1: unserialize('a:3:{i:0;s:5:"Kevin";i:1;s:3:"van";i:2;s:9:"Zonneveld";}')
  //   returns 1: ['Kevin', 'van', 'Zonneveld']
  //   example 2: unserialize('a:2:{s:9:"firstName";s:5:"Kevin";s:7:"midName";s:3:"van";}')
  //   returns 2: {firstName: 'Kevin', midName: 'van'}
  //   example 3: unserialize('a:3:{s:2:"ü";s:2:"ü";s:3:"四";s:3:"四";s:4:"𠜎";s:4:"𠜎";}')
  //   returns 3: {'ü': 'ü', '四': '四', '𠜎': '𠜎'}

  var $global = typeof window !== 'undefined' ? window : global;

  var utf8Overhead = function utf8Overhead(str) {
    var s = str.length;
    for (var i = str.length - 1; i >= 0; i--) {
      var code = str.charCodeAt(i);
      if (code > 0x7f && code <= 0x7ff) {
        s++;
      } else if (code > 0x7ff && code <= 0xffff) {
        s += 2;
      }
      // trail surrogate
      if (code >= 0xDC00 && code <= 0xDFFF) {
        i--;
      }
    }
    return s - 1;
  };
  var error = function error(type, msg, filename, line) {
    throw new $global[type](msg, filename, line);
  };
  var readUntil = function readUntil(data, offset, stopchr) {
    var i = 2;
    var buf = [];
    var chr = data.slice(offset, offset + 1);

    while (chr !== stopchr) {
      if (i + offset > data.length) {
        error('Error', 'Invalid');
      }
      buf.push(chr);
      chr = data.slice(offset + (i - 1), offset + i);
      i += 1;
    }
    return [buf.length, buf.join('')];
  };
  var readChrs = function readChrs(data, offset, length) {
    var i, chr, buf;

    buf = [];
    for (i = 0; i < length; i++) {
      chr = data.slice(offset + (i - 1), offset + i);
      buf.push(chr);
      length -= utf8Overhead(chr);
    }
    return [buf.length, buf.join('')];
  };
  function _unserialize(data, offset) {
    var dtype;
    var dataoffset;
    var keyandchrs;
    var keys;
    var contig;
    var length;
    var array;
    var readdata;
    var readData;
    var ccount;
    var stringlength;
    var i;
    var key;
    var kprops;
    var kchrs;
    var vprops;
    var vchrs;
    var value;
    var chrs = 0;
    var typeconvert = function typeconvert(x) {
      return x;
    };

    if (!offset) {
      offset = 0;
    }
    dtype = data.slice(offset, offset + 1).toLowerCase();

    dataoffset = offset + 2;

    switch (dtype) {
      case 'i':
        typeconvert = function typeconvert(x) {
          return parseInt(x, 10);
        };
        readData = readUntil(data, dataoffset, ';');
        chrs = readData[0];
        readdata = readData[1];
        dataoffset += chrs + 1;
        break;
      case 'b':
        typeconvert = function typeconvert(x) {
          return parseInt(x, 10) !== 0;
        };
        readData = readUntil(data, dataoffset, ';');
        chrs = readData[0];
        readdata = readData[1];
        dataoffset += chrs + 1;
        break;
      case 'd':
        typeconvert = function typeconvert(x) {
          return parseFloat(x);
        };
        readData = readUntil(data, dataoffset, ';');
        chrs = readData[0];
        readdata = readData[1];
        dataoffset += chrs + 1;
        break;
      case 'n':
        readdata = null;
        break;
      case 's':
        ccount = readUntil(data, dataoffset, ':');
        chrs = ccount[0];
        stringlength = ccount[1];
        dataoffset += chrs + 2;

        readData = readChrs(data, dataoffset + 1, parseInt(stringlength, 10));
        chrs = readData[0];
        readdata = readData[1];
        dataoffset += chrs + 2;
        if (chrs !== parseInt(stringlength, 10) && chrs !== readdata.length) {
          error('SyntaxError', 'String length mismatch');
        }
        break;
      case 'a':
        readdata = {};

        keyandchrs = readUntil(data, dataoffset, ':');
        chrs = keyandchrs[0];
        keys = keyandchrs[1];
        dataoffset += chrs + 2;

        length = parseInt(keys, 10);
        contig = true;

        for (i = 0; i < length; i++) {
          kprops = _unserialize(data, dataoffset);
          kchrs = kprops[1];
          key = kprops[2];
          dataoffset += kchrs;

          vprops = _unserialize(data, dataoffset);
          vchrs = vprops[1];
          value = vprops[2];
          dataoffset += vchrs;

          if (key !== i) {
            contig = false;
          }

          readdata[key] = value;
        }

        if (contig) {
          array = new Array(length);
          for (i = 0; i < length; i++) {
            array[i] = readdata[i];
          }
          readdata = array;
        }

        dataoffset += 1;
        break;
      default:
        error('SyntaxError', 'Unknown / Unhandled data type(s): ' + dtype);
        break;
    }
    return [dtype, dataoffset - offset, typeconvert(readdata)];
  }

  return _unserialize(data + '', 0)[2];
};
//# sourceMappingURL=unserialize.js.map
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 512 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };

module.exports = function serialize(mixedValue) {
  //  discuss at: http://locutus.io/php/serialize/
  // original by: Arpad Ray (mailto:arpad@php.net)
  // improved by: Dino
  // improved by: Le Torbi (http://www.letorbi.de/)
  // improved by: Kevin van Zonneveld (http://kvz.io/)
  // bugfixed by: Andrej Pavlovic
  // bugfixed by: Garagoth
  // bugfixed by: Russell Walker (http://www.nbill.co.uk/)
  // bugfixed by: Jamie Beck (http://www.terabit.ca/)
  // bugfixed by: Kevin van Zonneveld (http://kvz.io/)
  // bugfixed by: Ben (http://benblume.co.uk/)
  // bugfixed by: Codestar (http://codestarlive.com/)
  // bugfixed by: idjem (https://github.com/idjem)
  //    input by: DtTvB (http://dt.in.th/2008-09-16.string-length-in-bytes.html)
  //    input by: Martin (http://www.erlenwiese.de/)
  //      note 1: We feel the main purpose of this function should be to ease
  //      note 1: the transport of data between php & js
  //      note 1: Aiming for PHP-compatibility, we have to translate objects to arrays
  //   example 1: serialize(['Kevin', 'van', 'Zonneveld'])
  //   returns 1: 'a:3:{i:0;s:5:"Kevin";i:1;s:3:"van";i:2;s:9:"Zonneveld";}'
  //   example 2: serialize({firstName: 'Kevin', midName: 'van'})
  //   returns 2: 'a:2:{s:9:"firstName";s:5:"Kevin";s:7:"midName";s:3:"van";}'
  //   example 3: serialize( {'ü': 'ü', '四': '四', '𠜎': '𠜎'})
  //   returns 3: 'a:3:{s:2:"ü";s:2:"ü";s:3:"四";s:3:"四";s:4:"𠜎";s:4:"𠜎";}'

  var val, key, okey;
  var ktype = '';
  var vals = '';
  var count = 0;

  var _utf8Size = function _utf8Size(str) {
    return ~-encodeURI(str).split(/%..|./).length;
  };

  var _getType = function _getType(inp) {
    var match;
    var key;
    var cons;
    var types;
    var type = typeof inp === 'undefined' ? 'undefined' : _typeof(inp);

    if (type === 'object' && !inp) {
      return 'null';
    }

    if (type === 'object') {
      if (!inp.constructor) {
        return 'object';
      }
      cons = inp.constructor.toString();
      match = cons.match(/(\w+)\(/);
      if (match) {
        cons = match[1].toLowerCase();
      }
      types = ['boolean', 'number', 'string', 'array'];
      for (key in types) {
        if (cons === types[key]) {
          type = types[key];
          break;
        }
      }
    }
    return type;
  };

  var type = _getType(mixedValue);

  switch (type) {
    case 'function':
      val = '';
      break;
    case 'boolean':
      val = 'b:' + (mixedValue ? '1' : '0');
      break;
    case 'number':
      val = (Math.round(mixedValue) === mixedValue ? 'i' : 'd') + ':' + mixedValue;
      break;
    case 'string':
      val = 's:' + _utf8Size(mixedValue) + ':"' + mixedValue + '"';
      break;
    case 'array':
    case 'object':
      val = 'a';
      /*
      if (type === 'object') {
        var objname = mixedValue.constructor.toString().match(/(\w+)\(\)/);
        if (objname === undefined) {
          return;
        }
        objname[1] = serialize(objname[1]);
        val = 'O' + objname[1].substring(1, objname[1].length - 1);
      }
      */

      for (key in mixedValue) {
        if (mixedValue.hasOwnProperty(key)) {
          ktype = _getType(mixedValue[key]);
          if (ktype === 'function') {
            continue;
          }

          okey = key.match(/^[0-9]+$/) ? parseInt(key, 10) : key;
          vals += serialize(okey) + serialize(mixedValue[key]);
          count++;
        }
      }
      val += ':' + count + ':{' + vals + '}';
      break;
    case 'undefined':
    default:
      // Fall-through
      // if the JS object has a property which contains a null value,
      // the string cannot be unserialized by PHP
      val = 'N';
      break;
  }
  if (type !== 'object' && type !== 'array') {
    val += ';';
  }

  return val;
};
//# sourceMappingURL=serialize.js.map

/***/ }),
/* 513 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const function_1 = __webpack_require__(158);
const var_dump_1 = __webpack_require__(355);
const output_buffering_1 = __webpack_require__(131);
const each_1 = __webpack_require__(145);
const template_1 = __webpack_require__(123);
class TwingExtensionDebug extends extension_1.TwingExtension {
    getFunctions() {
        return new Map([
            [0, new function_1.TwingFunction('dump', twingVarDump, {
                    is_safe: ['html'],
                    needs_context: true,
                    needs_environment: true
                })],
        ]);
    }
}
exports.TwingExtensionDebug = TwingExtensionDebug;
function twingVarDump(env, context, ...vars) {
    if (!env.isDebug()) {
        return null;
    }
    output_buffering_1.TwingOutputBuffering.obStart();
    if (vars.length < 1) {
        let vars_ = new Map();
        each_1.each(context, (key, value) => {
            if (!(value instanceof template_1.TwingTemplate)) {
                vars_.set(key, value);
            }
        });
        var_dump_1.varDump(vars_);
    }
    else {
        var_dump_1.varDump(...vars);
    }
    return output_buffering_1.TwingOutputBuffering.obGetClean();
}
exports.twingVarDump = twingVarDump;


/***/ }),
/* 514 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const profiler_1 = __webpack_require__(356);
class TwingExtensionProfiler extends extension_1.TwingExtension {
    constructor(profile) {
        super();
        this.actives = [];
        this.actives.push(profile);
    }
    enter(profile) {
        this.actives[0].addProfile(profile);
        this.actives.unshift(profile);
    }
    leave(profile) {
        profile.leave();
        this.actives.shift();
        if (this.actives.length === 1) {
            this.actives[0].leave();
        }
    }
    getNodeVisitors() {
        return [new profiler_1.TwingProfilerNodeVisitorProfiler('TwingExtensionProfiler')];
    }
}
exports.TwingExtensionProfiler = TwingExtensionProfiler;
TwingExtensionProfiler.context = new Map();


/***/ }),
/* 515 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const sandbox_1 = __webpack_require__(359);
const sandbox_2 = __webpack_require__(361);
class TwingExtensionSandbox extends extension_1.TwingExtension {
    constructor(policy, sandboxed = false) {
        super();
        this.policy = policy;
        this.sandboxedGlobally = sandboxed;
    }
    getTokenParsers() {
        return [
            new sandbox_1.TwingTokenParserSandbox()
        ];
    }
    getNodeVisitors() {
        return [
            new sandbox_2.TwingNodeVisitorSandbox()
        ];
    }
    enableSandbox() {
        this.sandboxed = true;
    }
    disableSandbox() {
        this.sandboxed = false;
    }
    isSandboxed() {
        return this.sandboxedGlobally || this.sandboxed;
    }
    isSandboxedGlobally() {
        return this.sandboxedGlobally;
    }
    setSecurityPolicy(policy) {
        this.policy = policy;
    }
    getSecurityPolicy() {
        return this.policy;
    }
    checkSecurity(tags, filters, functions) {
        if (this.isSandboxed()) {
            this.policy.checkSecurity(tags, filters, functions);
        }
    }
    checkMethodAllowed(obj, method) {
        if (this.isSandboxed()) {
            this.policy.checkMethodAllowed(obj, method);
        }
    }
    checkPropertyAllowed(obj, method) {
        if (this.isSandboxed()) {
            this.policy.checkPropertyAllowed(obj, method);
        }
    }
    ensureToStringAllowed(obj) {
        if (this.isSandboxed() && typeof obj === 'object') {
            this.policy.checkMethodAllowed(obj, 'toString');
        }
        return obj;
    }
}
exports.TwingExtensionSandbox = TwingExtensionSandbox;


/***/ }),
/* 516 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const node_1 = __webpack_require__(107);
/**
 * Checks if casting an expression to toString() is allowed by the sandbox.
 *
 * For instance, when there is a simple Print statement, like {{ article }},
 * and if the sandbox is enabled, we need to check that the toString()
 * method is allowed if 'article' is an object. The same goes for {{ article|upper }}
 * or {{ random(article) }}.
 */
class TwingNodeCheckToString extends node_1.TwingNode {
    constructor(expression) {
        super(new Map([['expr', expression]]), new Map(), expression.getTemplateLine(), expression.getTemplateColumn());
    }
    compile(compiler) {
        compiler
            .raw('this.sandbox.ensureToStringAllowed(')
            .subcompile(this.getNode('expr'))
            .raw(')');
    }
}
exports.TwingNodeCheckToString = TwingNodeCheckToString;


/***/ }),
/* 517 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const extension_1 = __webpack_require__(117);
const function_1 = __webpack_require__(158);
class TwingExtensionStringLoader extends extension_1.TwingExtension {
    getFunctions() {
        return new Map([
            [0, new function_1.TwingFunction('template_from_string', twingTemplateFromString, { needs_environment: true })],
        ]);
    }
}
exports.TwingExtensionStringLoader = TwingExtensionStringLoader;
/**
 * Loads a template from a string.
 *
 * <pre>
 * {{ include(template_from_string("Hello {{ name }}")) }}
 * </pre>
 *
 * @param {TwingEnvironment} env A TwingEnvironment instance
 * @param {string} template A template as a string or object implementing toString()
 * @param {string} name An optional name for the template to be used in error messages
 *
 * @returns TwingTemplate
 */
function twingTemplateFromString(env, template, name = null) {
    return env.createTemplate(template, name);
}
exports.twingTemplateFromString = twingTemplateFromString;


/***/ }),
/* 518 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * Lazy loads the runtime implementations for a Twig element.
 *
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingFactoryRuntimeLoader {
    constructor(map = new Map()) {
        this.TwingRuntimeLoaderInterfaceImpl = this;
        this.map = map;
    }
    load(class_) {
        if (this.map.has(class_)) {
            let runtimeFactory = this.map.get(class_);
            return runtimeFactory();
        }
    }
}
exports.TwingFactoryRuntimeLoader = TwingFactoryRuntimeLoader;


/***/ }),
/* 519 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const print_1 = __webpack_require__(124);
class TwingNodeSandboxedPrint extends print_1.TwingNodePrint {
    compile(compiler) {
        compiler
            .addDebugInfo(this)
            .write('Runtime.echo(this.extensions.get(\'TwingExtensionSandbox\').ensureToStringAllowed(')
            .subcompile(this.getNode('expr'))
            .raw("));\n");
    }
}
exports.TwingNodeSandboxedPrint = TwingNodeSandboxedPrint;


/***/ }),
/* 520 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const security_not_allowed_filter_error_1 = __webpack_require__(207);
const security_not_allowed_tag_error_1 = __webpack_require__(209);
const security_not_allowed_function_error_1 = __webpack_require__(208);
const security_not_allowed_property_error_1 = __webpack_require__(364);
const security_not_allowed_method_error_1 = __webpack_require__(363);
const template_1 = __webpack_require__(123);
const markup_1 = __webpack_require__(162);
class TwingSandboxSecurityPolicy {
    constructor(allowedTags = [], allowedFilters = [], allowedMethods = new Map(), allowedProperties = new Map(), allowedFunctions = []) {
        this.TwingSandboxSecurityPolicyInterfaceImpl = this;
        this.allowedTags = allowedTags;
        this.allowedFilters = allowedFilters;
        this.setAllowedMethods(allowedMethods);
        this.allowedProperties = allowedProperties;
        this.allowedFunctions = allowedFunctions;
    }
    setAllowedTags(tags) {
        this.allowedTags = tags;
    }
    setAllowedFilters(filters) {
        this.allowedFilters = filters;
    }
    setAllowedMethods(methods) {
        this.allowedMethods = new Map();
        for (let [class_, m] of methods) {
            this.allowedMethods.set(class_, (Array.isArray(m) ? m : [m]).map(function (item) {
                return item.toLowerCase();
            }));
        }
    }
    setAllowedProperties(properties) {
        this.allowedProperties = properties;
    }
    setAllowedFunctions(functions) {
        this.allowedFunctions = functions;
    }
    checkSecurity(tags, filters, functions) {
        let self = this;
        tags.forEach(function (tag) {
            if (!self.allowedTags.includes(tag)) {
                throw new security_not_allowed_tag_error_1.TwingSandboxSecurityNotAllowedTagError(`Tag "${tag}" is not allowed.`, tag);
            }
        });
        filters.forEach(function (filter) {
            if (!self.allowedFilters.includes(filter)) {
                throw new security_not_allowed_filter_error_1.TwingSandboxSecurityNotAllowedFilterError(`Filter "${filter}" is not allowed.`, filter);
            }
        });
        functions.forEach(function (function_) {
            if (!self.allowedFunctions.includes(function_)) {
                throw new security_not_allowed_function_error_1.TwingSandboxSecurityNotAllowedFunctionError(`Function "${function_}" is not allowed.`, function_);
            }
        });
    }
    checkMethodAllowed(obj, method) {
        if (obj instanceof template_1.TwingTemplate || obj instanceof markup_1.TwingMarkup) {
            return;
        }
        let allowed = false;
        let checkableMethod = method.toLowerCase();
        for (let [class_, methods] of this.allowedMethods) {
            if (obj instanceof class_) {
                allowed = methods.includes(checkableMethod);
                break;
            }
        }
        if (!allowed) {
            let class_ = obj.constructor.name;
            throw new security_not_allowed_method_error_1.TwingSandboxSecurityNotAllowedMethodError(`Calling "${method}" method on a "${class_}" object is not allowed.`, class_, method);
        }
    }
    checkPropertyAllowed(obj, property) {
        let allowed = false;
        for (let [class_, properties] of this.allowedProperties) {
            if (obj instanceof class_) {
                allowed = (Array.isArray(properties) ? properties : [properties]).includes(property);
                break;
            }
        }
        if (!allowed) {
            let class_ = obj.constructor.name;
            throw new security_not_allowed_property_error_1.TwingSandboxSecurityNotAllowedPropertyError(`Calling "${property}" property on a "${class_}" object is not allowed.`, class_, property);
        }
    }
}
exports.TwingSandboxSecurityPolicy = TwingSandboxSecurityPolicy;


/***/ }),
/* 521 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
/**
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingProfilerDumperBlackfire {
    dump(profile) {
        let data = new Map();
        this.dumpProfile('main()', profile, data);
        this.dumpChildren('main()', profile, data);
        let start = `${new Date().getTime() / 1000}`;
        let str = `file-format: BlackfireProbe
cost-dimensions: wt mu pmu
request-start: ${start}

`;
        for (let [name, values] of data) {
            str += `${name}//${values['ct']} ${values['wt']} ${values['mu']} ${values['pmu']}\n`;
        }
        return str;
    }
    dumpChildren(parent, profile, data) {
        let name;
        for (let p of profile.getProfiles()) {
            if (p.isTemplate()) {
                name = p.getTemplate();
            }
            else {
                name = `${p.getTemplate()}::${p.getType()}(${p.getName()})`;
            }
            this.dumpProfile(`${parent}==>${name}`, p, data);
            this.dumpChildren(name, p, data);
        }
    }
    dumpProfile(edge, profile, data) {
        if (data.has(edge)) {
            let edgeObject = data.get(edge);
            edgeObject['ct'] += 1;
            edgeObject['wt'] += Math.floor(profile.getDuration() * 1000000);
            edgeObject['mu'] += profile.getMemoryUsage();
            edgeObject['pmu'] += profile.getPeakMemoryUsage();
        }
        else {
            data.set(edge, {
                'ct': 1,
                'wt': Math.floor(profile.getDuration() * 1000000),
                'mu': profile.getMemoryUsage(),
                'pmu': profile.getPeakMemoryUsage(),
            });
        }
    }
}
exports.TwingProfilerDumperBlackfire = TwingProfilerDumperBlackfire;


/***/ }),
/* 522 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_1 = __webpack_require__(211);
/**
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingProfilerDumperHtml extends base_1.TwingProfilerDumperBase {
    dump(profile) {
        return '<pre>' + super.dump(profile) + '</pre>';
    }
    formatTemplate(profile, prefix) {
        return `${prefix}└ <span style="background-color: ${TwingProfilerDumperHtml.colors['template']}">${profile.getTemplate()}</span>`;
    }
    formatNonTemplate(profile, prefix) {
        let color = TwingProfilerDumperHtml.colors[profile.getType()];
        return `${prefix}└ ${profile.getTemplate()}::${profile.getType()}(<span style="background-color: ${color}">${profile.getName()}</span>)`;
    }
    formatTime(profile, percent) {
        let color = TwingProfilerDumperHtml.colors['big'];
        return `<span style="color: ${color}">${(profile.getDuration() * 1000).toFixed(2)}ms/${percent}%</span>`;
    }
}
exports.TwingProfilerDumperHtml = TwingProfilerDumperHtml;
TwingProfilerDumperHtml.colors = {
    block: '#dfd',
    macro: '#ddf',
    template: '#ffd',
    big: '#d44'
};


/***/ }),
/* 523 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const base_1 = __webpack_require__(211);
/**
 * @author Eric MORAND <eric.morand@gmail.com>
 */
class TwingProfilerDumperText extends base_1.TwingProfilerDumperBase {
    formatTemplate(profile, prefix) {
        return `${prefix}└ ${profile.getTemplate()}`;
    }
    formatNonTemplate(profile, prefix) {
        return `${prefix}└ ${profile.getTemplate()}::${profile.getType()}(${profile.getName()})`;
    }
    formatTime(profile, percent) {
        return `${(profile.getDuration() * 1000).toFixed(2)}ms/${percent}%`;
    }
}
exports.TwingProfilerDumperText = TwingProfilerDumperText;


/***/ }),
/* 524 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
function includes(map, thing) {
    for (let [key, value] of map) {
        if (value === thing) {
            return true;
        }
    }
    return false;
}
exports.includes = includes;


/***/ }),
/* 525 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
var intl_1 = __webpack_require__(526);
exports.TwingExtensionIntl = intl_1.TwingExtensionIntl;


/***/ }),
/* 526 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

Object.defineProperty(exports, "__esModule", { value: true });
const twing_1 = __webpack_require__(240);
const formats = __webpack_require__(6);
class TwingExtensionIntl extends twing_1.TwingExtension {
    constructor(content) {
        super();
        if (!Intl.DateTimeFormat) {
            throw new Error('intl (https://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Global_Objects/Intl) is needed to use intl-based filters.');
        }
    }
    getFilters() {
        return new Map([
            [0, new twing_1.TwingFilter('localizeddate', TwingExtensionIntl.localizeddate, { needs_environment: true })],
        ]);
    }
    static getLocale(locale) {
        return locale ? locale : navigator.language;
    }
    // we need some help as js intl is not yet ready
    // @see https://github.com/tc39/proposal-intl-datetime-style
    static localizeddate(env, date, dateFormat = 'medium', timeFormat = 'medium', locale = null, timezone = null, format = null, calendar = 'gregorian') {
        var options = {};
        if (timezone) {
            Object.assign(options, {
                timeZone: timezone,
                timeZoneName: 'short'
            });
        }
        if (dateFormat) {
            Object.assign(options, formats.date[dateFormat] || formats.parseDatePattern(dateFormat) || formats.date.default);
        }
        if (timeFormat) {
            Object.assign(options, formats.time[timeFormat] || formats.parseDatePattern(timeFormat) || formats.time.default);
        }
        return new Intl.DateTimeFormat(TwingExtensionIntl.getLocale(locale), options).format(date);
    }
    static localizednumber(number, style = 'decimal', type = 'default', locale = null) {
        // @TODO implement me
    }
    static localizedcurrency(number, $currency = null, $locale = null) {
        // @TODO implement me
    }
}
exports.TwingExtensionIntl = TwingExtensionIntl;


/***/ }),
/* 527 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
var EventEmitter = __webpack_require__(24);

Ext.ns('Tine.Tinebase');
/**
 * <p>Abstract base class for all Tine applications</p>
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.Application
 * @extends     Ext.util.Observable
 * @consturctor
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.Application = function (config) {
  config = config || {};
  Ext.apply(this, config);
  Tine.Tinebase.Application.superclass.constructor.call(this);
  this.hasMainScreen = Ext.isBoolean(this.hasMainScreen) ? this.hasMainScreen : this.getMainScreen != Tine.Tinebase.Application.prototype.getMainScreen || typeof Tine[this.appName].MainScreen === 'function';
  this.i18n = new Locale.Gettext();
  this.i18n.textdomain(this.appName);
  /**
   * in memory msg bus for sync events
   */

  (() => {
    let ee = new EventEmitter();
    this.on = ee.on;
    this.emit = ee.emit;
  })();

  this.init();

  if (Tine.CoreData && Tine.CoreData.Manager) {
    Tine.log.debug('Tine.Tinebase.Application - register core data for ' + this.appName);
    this.registerCoreData.defer(500, this);
  }

  this.initAutoHooks();
  this.initRoutes();
};

Ext.extend(Tine.Tinebase.Application, Ext.util.Observable, {
  /**
   * @cfg {String} appName
   * untranslated application name (required)
   */
  appName: null,

  /**
   * @cfg {Boolean} hasMainScreen
   */
  hasMainScreen: null,

  /**
   * @cfg {Object} routes
   */
  routes: null,

  /**
   * @cfg {String} defaultRoute
   */
  defaultRoute: 'mainscreen',

  /**
   * @property {Locale.gettext} i18n
   */
  i18n: null,

  /**
   * returns title of this application
   * 
   * @return {String}
   */
  getTitle: function getTitle() {
    return this.i18n._(this.appName);
  },
  formatMessage: function (_formatMessage) {
    function formatMessage(_x) {
      return _formatMessage.apply(this, arguments);
    }

    formatMessage.toString = function () {
      return _formatMessage.toString();
    };

    return formatMessage;
  }(function (template) {
    arguments[0] = this.i18n._hidden(template);
    return formatMessage.apply(formatMessage, arguments);
  }),

  /**
   * returns iconCls of this application
   * 
   * @param {String} target
   * @return {String}
   */
  getIconCls: function getIconCls(target) {
    return 'ApplicationIconCls ' + this.appName + 'IconCls';
  },

  /**
   * returns the mainscreen of this application
   * 
   * @return {Tine.widgets.app.MainScreen}
   */
  getMainScreen: function getMainScreen() {
    if (this.hasMainScreen && !this.mainScreen) {
      this.mainScreen = new Tine[this.appName].MainScreen({
        app: this
      });
    }

    return this.mainScreen;
  },

  /**
   * returns registry of this app
   * 
   * @return {Ext.util.MixedCollection}
   */
  getRegistry: function getRegistry() {
    return Tine[this.appName].registry;
  },

  /**
   * returns true if a specific feature is enabled for this application
   * 
   * @param {String} featureName
   * @return {Boolean}
   */
  featureEnabled: function featureEnabled(featureName) {
    var featureConfig = Tine[this.appName].registry.get("config").features,
        result = featureConfig && featureConfig.value[featureName];

    if (result == undefined) {
      // check defaults if key is missing
      result = featureConfig && featureConfig.definition && featureConfig.definition['default'] && featureConfig.definition['default'][featureName];
    }

    return result;
  },

  /**
   * template function for subclasses to initialize application
   */
  init: Ext.emptyFn,

  /**
   * template function for subclasses to register app core data
   */
  registerCoreData: Ext.emptyFn,

  /**
   * init some auto hooks
   */
  initAutoHooks: function initAutoHooks() {
    if (this.addButtonText) {
      Ext.ux.ItemRegistry.registerItem('Tine.widgets.grid.GridPanel.addButton', {
        text: this.i18n._hidden(this.addButtonText),
        iconCls: this.getIconCls(),
        scope: this,
        handler: function handler() {
          var ms = this.getMainScreen(),
              cp = ms.getCenterPanel();
          cp.onEditInNewWindow.call(cp, {});
        }
      });
    }
  },
  initRoutes: function initRoutes() {
    var route, action;

    if (this.routes) {
      for (route in this.routes) {
        if (this.routes.hasOwnProperty(route)) {
          action = this.routes[route];

          if (Ext.isString(action) && Ext.isFunction(this[action])) {
            action = this[action].createDelegate(this);
          }

          if (route[0] != '/') {
            route = '/' + this.appName + '/' + route;
          }

          Tine.Tinebase.router.on(route, action);
        }
      }
    } // default mainscreen route


    if (!this.routes || !this.routes['']) {
      var me = this;
      Tine.Tinebase.router.on('/' + this.appName, function () {
        Tine.Tinebase.MainScreenPanel.show(me);
      });
    }
  },

  /**
   * @param {String} action
   * @param {Array} params
   */
  dispatchRoute: function dispatchRoute(action, params) {
    var route, methodName, paramNames;

    if (this.routes) {
      for (route in this.routes) {
        if (this.routes.hasOwnProperty(route)) {
          paramNames = route.split('/');

          if (action == paramNames.shift()) {
            methodName = this.routes[route].action;
            break;
          }
        }
      }
    }

    if (methodName) {
      // @TODO validate parameters according to docs
      return this[methodName].apply(this, params);
    }

    Ext.MessageBox.show(Ext.apply(defaults, {
      title: i18n._('Not Supported'),
      msg: i18n._('Your request is not supported by this version.'),
      fn: function fn() {
        Tine.Tinebase.common.reload();
      }
    }));
  },

  /**
   * get route for this app
   * @return {string}
   */
  getRoute() {
    return '/' + this.appName;
  },

  /**
   * template function for subclasses is called before app activation. Return false to cancel activation
   */
  onBeforeActivate: Ext.emptyFn,

  /**
   * template function for subclasses is called after app activation.
   */
  onActivate: Ext.emptyFn,

  /**
   * template function for subclasses is called before app deactivation. Return false to cancel deactivation
   */
  onBeforeDeActivate: Ext.emptyFn,

  /**
   * template function for subclasses is called after app deactivation.
   */
  onDeActivate: Ext.emptyFn
});

Tine.Tinebase.featureEnabled = function (featureName) {
  // need to create a "dummy" app to call featureEnabled()
  var tinebaseApp = new Tine.Tinebase.Application({
    appName: 'Tinebase'
  });
  return tinebaseApp.featureEnabled(featureName);
};

/***/ }),
/* 528 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2011-2015 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * Container Grants grid
 * 
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.GrantsDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.container.GrantsGrid = Ext.extend(Tine.widgets.account.PickerGridPanel, {
  /**
   * @cfg {Array} data of Tine.Tinebase.Model.Container
   * Container to manage grants for
   */
  grantContainer: null,

  /**
   * @cfg {Boolean}
   * always show the admin grant (default: false)
   */
  alwaysShowAdminGrant: false,

  /**
   * Tine.widgets.account.PickerGridPanel config values
   */
  selectType: 'both',
  selectTypeDefault: 'group',
  selectRole: true,
  hasAccountPrefix: true,

  /**
   * canonical name
   * @cfg {String} canonicalName
   */
  canonicalName: 'GrantsGrid',
  readGrantTitle: 'Read',
  // i18n._('Read')
  readGrantDescription: 'The grant to read records of this container',
  // i18n._('The grant to read records of this container')
  addGrantTitle: 'Add',
  // i18n._('Add')
  addGrantDescription: 'The grant to add records to this container',
  // i18n._('The grant to add records to this container')
  editGrantTitle: 'Edit',
  // i18n._('Edit')
  editGrantDescription: 'The grant to edit records in this container',
  // i18n._('The grant to edit records in this container')
  deleteGrantTitle: 'Delete',
  // i18n._('Delete')
  deleteGrantDescription: 'The grant to delete records in this container',
  // i18n._('The grant to delete records in this container')
  exportGrantTitle: 'Export',
  // i18n._('Export')
  exportGrantDescription: 'The grant to export records from this container',
  // i18n._('The grant to export records from this container')
  syncGrantTitle: 'Sync',
  // i18n._('Sync')
  syncGrantDescription: 'The grant to synchronise records with this container',
  // i18n._('The grant to synchronise records with this container')
  adminGrantTitle: 'Admin',
  // i18n._('Admin')
  adminGrantDescription: 'The grant to administrate this container',
  // i18n._('The grant to administrate this container')

  /**
   * @private
   */
  initComponent: function initComponent() {
    if (!this.recordDefaults) {
      this.recordDefaults = {
        readGrant: true,
        exportGrant: true,
        syncGrant: true
      };
    }

    if (!this.recordClass) {
      this.recordClass = Tine.Tinebase.container.getGrantsModel(this.grantContainer);
    }

    if (!this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
    }

    this.initColumns();

    if (!this.store) {
      this.store = new Ext.data.JsonStore({
        root: 'results',
        totalProperty: 'totalcount',
        id: 'account_id',
        fields: this.recordClass
      });
    }

    Tine.widgets.container.GrantsGrid.superclass.initComponent.call(this);
    this.getStore().on('update', this.onStoreUpdate, this);
    this.getStore().on('load', function (store) {
      store.each(function (r) {
        this.onStoreUpdate(store, r);
      }, this);
    }, this);
  },
  onStoreUpdate: function onStoreUpdate(store, record, operation) {
    if (this.alwaysShowAdminGrant || this.grantContainer && this.grantContainer.type == 'shared') {
      if (record.get('adminGrant')) {
        // set all grants and mask other checkboxes
        Ext.each(this.getColumnModel().columns, function (col, colIdx) {
          var matches;

          if (col.dataIndex && (matches = col.dataIndex.match(/^([a-z]+)Grant$/)) && matches[1] != 'admin') {
            record.set(col.dataIndex, true);
          }
        }, this);
      } else {// make sure grants are not masked
      }
    }
  },

  /**
   * init grid columns
   */
  initColumns: function initColumns() {
    var _ = window.lodash,
        me = this,
        getTranslation = function getTranslation(string) {
      var translation = me.app.i18n._hidden(string);

      return translation != string ? translation : window.i18n._hidden(string);
    },
        grants = _.reduce(this.recordClass.getFieldNames(), function (grants, name) {
      var isGrant = name.match(/(.+)Grant$/),
          grant = isGrant ? isGrant[1] : false;

      if (grant && ['freebusy', 'private', 'download', 'publish', 'admin'].indexOf(grant) < 0) {
        grants.push(grant);
      }

      return grants;
    }, []); // manage runtime depended grants
    // NOTE: this could also be solved withe the useGrant method!


    if (this.grantContainer) {
      grants = Tine.widgets.container.GrantsManager.getByContainer(this.grantContainer);
    }

    if (this.recordClass.hasField('adminGrant') && (this.alwaysShowAdminGrant || me.grantContainer && me.grantContainer.type == 'shared')) {
      grants.push('admin');
    }

    this.configColumns = [];
    Ext.each(grants, function (grant) {
      var header = getTranslation(this[grant + 'GrantTitle']);
      this.configColumns.push(new Ext.ux.grid.CheckColumn({
        id: grant,
        header: String(header).replace(/\s+/, '<br>'),
        tooltip: '<b>' + header + '</b><br>' + getTranslation(this[grant + 'GrantDescription']),
        dataIndex: grant + 'Grant',
        width: 55,
        onBeforeCheck: this.onBeforeCheck.createDelegate(this)
      }));
    }, this);
  },
  useGrant: function useGrant(grant, use) {
    var cm = this.getColumnModel(),
        findFn = function findFn(o) {
      return o.id == grant;
    },
        current = lodash.find(cm.config, findFn),
        config = lodash.find(this.configColumns, findFn); // apparently config might be empty for shared folders


    if (!config) {
      return;
    }

    if (use && !current) {
      cm.setConfig(cm.config.push(config));
    } else if (!use && current) {
      cm.setConfig(lodash.filter(cm.config, lodash.negate(findFn)));
    }
  },
  onBeforeCheck: function onBeforeCheck(checkbox, record) {
    return !this.readOnly;
  }
});
/**
 * grants by model registry
 *
 * @type {{defaultGrants, getByContainer, register}}
 */

Tine.widgets.container.GrantsManager = function () {
  /**
   * contains Array of grants or a function that returns the grants depending on some condition
   *
   * @type {Object}
   */
  var grantsForModels = {};
  return {
    /**
     * default grants
     *
     * @return Array
     */
    defaultGrants: function defaultGrants(container) {
      var _ = window.lodash,
          modelName = container.model,
          grantsModelName = modelName + 'Grants',
          grantsModel = Tine.Tinebase.data.RecordMgr.get(grantsModelName);
      return grantsModel ? _.reduce(grantsModel.getFieldNames(), function (grants, fieldName) {
        var match = String(fieldName).match(/(.+)Grant$/);
        return grants.concat(match ? match[1] : []);
      }, []) : ['read', 'add', 'edit', 'delete', 'export', 'sync'];
    },

    /**
     * get container grants for specific container
     *
     * @param {Tine.Tinebase.Model.Container} container
     * @return Array
     */
    getByContainer: function getByContainer(container) {
      var modelName = container.model || container,
          grants = grantsForModels[modelName] ? Ext.isFunction(grantsForModels[modelName]) ? grantsForModels[modelName](container) : grantsForModels[modelName] : this.defaultGrants(container);
      return grants;
    },

    /**
     * register grants or grants function for given model
     *
     * @param {Record/String} modelName
     * @param {Array|Function} grants
     */
    register: function register(modelName, grantsOrFunction) {
      grantsForModels[modelName] = grantsOrFunction;
    }
  };
}();

/***/ }),
/* 529 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets');
/**
 * @namespace   Tine.widgets
 * @class       Tine.widgets.MainScreen
 * @extends     Ext.Panel
 *
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.widgets.MainScreen = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   * instance of the app object (required)
   */
  app: null,

  /**
   * @cfg {String} activeContentType
   */
  activeContentType: null,

  /**
   * @cfg {Array} contentTypes
   */
  contentTypes: null,

  /**
   * @cfg {String} centerPanelClassName
   * name of centerpanel class name suffix in namespace of this app (defaults to GridPanel)
   * the class name will be expanded to Tine[this.appName][contentType + this.centerPanelClassNameSuffix]
   */
  centerPanelClassNameSuffix: 'GridPanel',

  /**
   * @cfg {Bool} useModuleTreePanel
   * use modulePanel (defaults to null -> autodetection)
   */
  useModuleTreePanel: null,

  /**
   * @cfg {Number} northHeight
   */
  northHeight: 44,

  /**
   * @cfg {Number} westWidth
   */
  westWidth: 200,
  layout: 'border',
  border: false,
  stateful: true,
  initComponent: function initComponent() {
    var registeredContentTypes = _.get(Tine.widgets.MainScreen.registerContentType, 'registry.' + this.app.appName, []);

    this.contentTypes = (this.contentTypes || []).concat(registeredContentTypes);
    this.useModuleTreePanel = Ext.isArray(this.contentTypes) && this.contentTypes.length > 1;
    this.initLayout();
    this.initMessageBus();

    if (this.cls) {
      this.cls = this.cls + ' ' + 't-app-' + this.app.appName.toLowerCase();
    } else {
      this.cls = 't-app-' + this.app.appName.toLowerCase();
    }

    this.stateId = this.app.appName + '-mainScreen';
    Tine.widgets.MainScreen.superclass.initComponent.apply(this, arguments);
  },
  onDestroy: function onDestroy() {
    _.each(this.postalSubscriptions, subscription => {
      subscription.unsubscribe();
    });

    return this.supr().onDestroy.call(this);
  },
  initMessageBus: function initMessageBus() {
    this.postalSubscriptions = [];

    _.each(Tine.Tinebase.areaLocks.getLocks(this.app.appName), areaLock => {
      this.postalSubscriptions.push(postal.subscribe({
        channel: "areaLocks",
        topic: areaLock + '.*',
        callback: this.onAreaLockChange.createDelegate(this)
      }));
    });
  },
  onAreaLockChange: function onAreaLockChange(data, e) {
    var topic = e.topic,
        locked = !!Tine.Tinebase.areaLocks.getLocks(this.app.appName, true).length,
        cp = this.getCenterPanel(),
        grid = cp ? cp.getGrid() : null,
        store = grid.getStore(); // shouldn't this be done by the gird itself?

    if (locked) {
      store.removeAll(); // @TODO: quit bg refresh task?
    } else {
      store.reload();
    }
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    if (this.app) {
      return ['', this.app.name, 'MainScreen'].join(Tine.Tinebase.CanonicalPath.separator);
    }
  },
  getState: function getState() {
    return {
      westWidth: this.westRegionPanel.getWidth(),
      northHeight: this.northCardPanel.getHeight()
    };
  },
  applyState: function applyState(state) {
    this.westRegionPanel.setWidth(state.westWidth);

    if (state.northHeight > 0) {
      // NOTE: in some wired cases the state is 0 - and the user has no option to resize it
      this.northCardPanel.setHeight(state.northHeight);
    }
  },

  /**
   * @private
   */
  initLayout: function initLayout() {
    this.items = [{
      ref: 'northCardPanel',
      cls: 'tine-mainscreen-centerpanel-north',
      region: 'north',
      layout: 'card',
      activeItem: 0,
      height: this.northHeight,
      border: false,
      items: []
    }, {
      ref: 'centerCardPanel',
      cls: 'tine-mainscreen-centerpanel-center',
      region: 'center',
      animate: true,
      border: false,
      layout: 'card',
      activeItem: 0,
      defaults: {
        hideMode: 'offsets'
      },
      items: []
    }, {
      ref: 'westRegionPanel',
      cls: 'tine-mainscreen-centerpanel-west',
      region: 'west',
      //id: 'west',
      stateful: false,
      split: true,
      width: this.westWidth,
      minSize: 100,
      border: false,
      collapsible: true,
      collapseMode: 'mini',
      header: false,
      layout: 'fit',
      listeners: {
        scope: this,
        resize: this.saveState,
        afterrender: function afterrender() {
          // add to scrollmanager
          if (arguments[0] && arguments[0].hasOwnProperty('body')) {
            Ext.dd.ScrollManager.register(arguments[0].body);
          }
        }
      },
      autoScroll: true,
      tbar: [{
        buttonAlign: 'center'
      }],
      items: [{
        ref: '../moduleCardPanel',
        cls: 'tine-mainscreen-centerpanel-west-modules',
        border: false,
        autoScroll: false,
        autoHeight: true,
        style: {
          width: '100%'
        },
        layout: 'card',
        activeItem: 0,
        items: []
      }, {
        ref: '../westCardPanel',
        cls: 'tine-mainscreen-centerpanel-west-treecards',
        border: false,
        style: {
          width: '100%'
        },
        autoScroll: false,
        layout: 'card',
        activeItem: 0,
        items: []
      }]
    }];
  },
  afterRender: function afterRender() {
    Tine.widgets.MainScreen.superclass.afterRender.call(this);

    _.each(Tine.Tinebase.areaLocks.getLocks(this.app.appName), areaLock => {
      Tine.Tinebase.areaLocks.setOptions(areaLock, {
        maskEl: this.getEl()
      });
      Tine.Tinebase.areaLocks.unlock(areaLock);
    });

    this.setActiveContentType(this.activeContentType);
  },

  /**
   * returns active content type
   * 
   * @return {String}
   */
  getActiveContentType: function getActiveContentType() {
    return this.activeContentType ? this.activeContentType : '';
  },
  getContentTypeDefinition: function getContentTypeDefinition(contentType) {
    var _ = window.lodash;
    return _.find(this.contentTypes, {
      contentType: contentType
    }) || _.find(this.contentTypes, {
      model: contentType
    }) || _.find(this.contentTypes, {
      modelName: contentType
    });
  },

  /**
   * get center panel for given contentType
   * 
   * @param {String} contentType
   * @return {Ext.Panel}
   */
  getCenterPanel: function getCenterPanel(contentType) {
    contentType = contentType || this.getActiveContentType();
    var def = this.getContentTypeDefinition(contentType) || {},
        suffix = def && def.xtype ? '' : this.centerPanelClassNameSuffix;

    if (!this[contentType + suffix]) {
      try {
        this[contentType + suffix] = def && def.xtype ? Ext.create(def) : new Tine[def.appName || this.app.appName][contentType + suffix]({
          app: def.appName ? Tine.Tinebase.appMgr.get(def.appName) : this.app,
          plugins: (() => {
            const wp = this.getWestPanel();
            return wp && wp.getFilterPlugin ? [wp.getFilterPlugin(contentType)] : [];
          })()
        });

        if (this[contentType + suffix].cls) {
          this[contentType + suffix].cls = this[contentType + suffix].cls + ' t-contenttype-' + contentType.toLowerCase();
        } else {
          this[contentType + suffix].cls = 't-contenttype-' + contentType.toLowerCase();
        }
      } catch (e) {
        Tine.log.error('Could not create centerPanel "Tine.' + this.app.appName + '.' + contentType + suffix + '"');
        Tine.log.error(e.stack ? e.stack : e);
        this[contentType + suffix] = new Ext.Panel({
          html: 'ERROR'
        });
      }
    }

    return this[contentType + suffix];
  },

  /**
   * get north panel for given contentType
   * 
   * @param {String} contentType
   * @return {Ext.Panel}
   */
  getNorthPanel: function getNorthPanel(contentType) {
    contentType = contentType || this.getActiveContentType();

    if (!this[contentType + 'ActionToolbar']) {
      try {
        var cp = this.getCenterPanel(contentType);

        if (Ext.isFunction(cp.getActionToolbar)) {
          this[contentType + 'ActionToolbar'] = cp.getActionToolbar();

          if (this[contentType + 'ActionToolbar'].cls) {
            this[contentType + 'ActionToolbar'].cls = this[contentType + 'ActionToolbar'].cls + ' t-contenttype-' + contentType.toLowerCase();
          } else {
            this[contentType + 'ActionToolbar'].cls = 't-contenttype-' + contentType.toLowerCase();
          }
        }
      } catch (e) {
        Tine.log.error('Could not create northPanel');
        Tine.log.error(e.stack ? e.stack : e);
        this[contentType + 'ActionToolbar'] = new Ext.Panel({
          html: 'ERROR'
        });
      }
    }

    return this[contentType + 'ActionToolbar'];
  },

  /**
   * get module tree panel
   * 
   * @return {Ext.Panel}
   */
  getModuleTreePanel: function getModuleTreePanel() {
    if (!this.moduleTreePanel) {
      if (this.useModuleTreePanel) {
        this.moduleTreePanel = new Tine.widgets.ContentTypeTreePanel({
          app: this.app,
          contentTypes: this.contentTypes,
          contentType: this.getActiveContentType()
        });
        var me = this;
        this.moduleTreePanel.on('click', function (node, event) {
          // NOTE: 'this' is moduleTreePanel here (no scope provided)
          if (node != this.lastClickedNode) {
            this.lastClickedNode = node;
            this.fireEvent('selectionchange');
          } else if (me.getWestPanel().hasFavoritesPanel) {
            // select default favorite
            // NOTE: a lot of models don't have a default favorite defined...
            me.getWestPanel().getFavoritesPanel().selectDefault();
          }
        });
      } else {
        this.moduleTreePanel = new Ext.Panel({
          html: '',
          border: false,
          frame: false
        });
      }
    }

    return this.moduleTreePanel;
  },

  /**
   * get panel for westCardPanel region of given contentType
   *
   * NOTE: do not confuse this with westRegionPanel!
   * 
   * @return {Ext.Panel}
   */
  getWestPanel: function getWestPanel(contentType) {
    contentType = contentType || this.getActiveContentType();

    var _ = window.lodash,
        def = this.getContentTypeDefinition(contentType),
        app = _.get(def, 'app', this.app),
        wpName = _.upperFirst(contentType + 'WestPanel');

    if (!this[wpName]) {
      var wpconfig = {
        app: app,
        contentTypes: this.contentTypes,
        contentType: contentType,
        listeners: {
          scope: this,
          // clear gird selection on favorite change, module change, container change?
          selectionchange: function selectionchange() {
            var cp = this.getCenterPanel();

            if (cp) {
              try {
                var grid = cp.getGrid();

                if (grid) {
                  var sm = grid.getSelectionModel();

                  if (sm) {
                    sm.clearSelections();
                    cp.actionUpdater.updateActions(sm);
                  }
                }
              } catch (e) {// do nothing - no grid
              }
            }
          }
        }
      };

      try {
        if (Tine[app.name].hasOwnProperty(wpName)) {
          this[wpName] = new Tine[app.appName][wpName](wpconfig);
        } else {
          this[wpName] = new Tine.widgets.mainscreen.WestPanel(wpconfig);
        }
      } catch (e) {
        Tine.log.error('Could not create westPanel');
        Tine.log.error(e.stack ? e.stack : e);
        this[wpName] = new Ext.Panel({
          html: 'ERROR'
        });
      }
    }

    return this[wpName];
  },

  /**
   * shows center panel in mainscreen
   */
  showCenterPanel: function showCenterPanel() {
    this.setActiveContentPanel(this.getCenterPanel(this.getActiveContentType()), true);
  },

  /**
   * shows module tree panel in mainscreen
   */
  showModuleTreePanel: function showModuleTreePanel() {
    this.setActiveModulePanel(this.getModuleTreePanel(), true);
  },

  /**
   * shows west panel in mainscreen
   */
  showWestCardPanel: function showWestCardPanel() {
    // add save favorites button to toolbar if favoritesPanel exists
    var westPanel = this.getWestPanel(),
        favoritesPanel = westPanel.hasFavoritesPanel ? westPanel.getFavoritesPanel() : false,
        westPanelToolbar = this.westRegionPanel.getTopToolbar();
    westPanelToolbar.removeAll();

    if (favoritesPanel) {
      westPanelToolbar.addButton({
        xtype: 'button',
        text: i18n._('Save current view as favorite'),
        iconCls: 'action_saveFilter',
        scope: this,
        handler: function handler() {
          favoritesPanel.saveFilter.call(favoritesPanel);
        }
      }); // westPanelToolbar.show();
      // flat design

      westPanelToolbar.hide();
    } else {
      westPanelToolbar.hide();
    }

    westPanelToolbar.doLayout();
    this.setActiveTreePanel(westPanel, true);
  },

  /**
   * shows north panel in mainscreen
   */
  showNorthPanel: function showNorthPanel() {
    this.setActiveToolbar(this.getNorthPanel(this.getActiveContentType()), true);
  },

  /**
   * sets the active content type
   *
   * @param {String} contentType to activate
   */
  setActiveContentType: function setActiveContentType(contentType) {
    if (contentType === null) {
      // use first valid content type
      if (this.contentTypes && this.contentTypes.length > 0) {
        contentType = this.contentTypes[0].modelName;
      }
    }

    this.activeContentType = contentType;
    this.showWestCardPanel();
    this.showCenterPanel();
    this.showNorthPanel();
    this.showModuleTreePanel();
  },

  /**
   * sets the active content panel
   *
   * @param {Ext.Panel} item Panel to activate
   * @param {Bool} keep keep panel
   */
  setActiveContentPanel: function setActiveContentPanel(panel, keep) {
    Ext.ux.layout.CardLayout.helper.setActiveCardPanelItem(this.centerCardPanel, panel, keep);
  },

  /**
   * sets the active tree panel
   *
   * @param {Ext.Panel} panel Panel to activate
   * @param {Bool} keep keep panel
   */
  setActiveTreePanel: function setActiveTreePanel(panel, keep) {
    Ext.ux.layout.CardLayout.helper.setActiveCardPanelItem(this.westCardPanel, panel, keep);
  },

  /**
   * sets the active module tree panel
   *
   * @param {Ext.Panel} panel Panel to activate
   * @param {Bool} keep keep panel
   */
  setActiveModulePanel: function setActiveModulePanel(panel, keep) {
    Ext.ux.layout.CardLayout.helper.setActiveCardPanelItem(this.moduleCardPanel, panel, keep);
  },

  /**
   * sets item
   *
   * @param {Ext.Toolbar} panel toolbar to activate
   * @param {Bool} keep keep panel
   */
  setActiveToolbar: function setActiveToolbar(panel, keep) {
    if (panel) {
      if (!this.northCardPanel.isVisible()) {
        this.northCardPanel.show();
        this.northCardPanel.ownerCt.doLayout();
        panel.show(); // Nasty resize prob!
      }

      Ext.ux.layout.CardLayout.helper.setActiveCardPanelItem(this.northCardPanel, panel, keep);
    } else {
      this.northCardPanel.hide();
      this.northCardPanel.ownerCt.doLayout();
    }
  },

  /**
   * gets the currently displayed toolbar
   *
   * @return {Ext.Toolbar}
   */
  getActiveToolbar: function getActiveToolbar() {
    var northPanel = this.northCardPanel;

    if (northPanel.layout.activeItem && northPanel.layout.activeItem.el) {
      return northPanel.layout.activeItem.el;
    } else {
      return false;
    }
  }
});
/**
 * content type registry
 *
 * @param {String} appName
 * @param {Collection} contentType
 *   contentType:   {String|Object|Model}
 *   text:          {String}
 *   group:         {String} (optional)
 *   xtype:         {String} (optional)
 */

Tine.widgets.MainScreen.registerContentType = function (appName, contentType) {
  var registeredContentTypes = _.get(Tine.widgets.MainScreen.registerContentType, 'registry.' + appName, []);

  if (_.isFunction(contentType.getMeta)) {
    contentType = {
      appName: contentType.getMeta('appName'),
      modelName: contentType.getMeta('modelName')
    };
  }

  registeredContentTypes.push(contentType);

  _.set(Tine.widgets.MainScreen.registerContentType, 'registry.' + appName, registeredContentTypes);
};

/***/ }),
/* 530 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath id='copy-to-clipboard' d='M 29.225 6.31 C 28.405 5.842 27.585 5.374 26.763 5.14 C 26.414 4.202 25.826 3.266 25.006 2.678 C 23.951 1.625 22.545 1.038 21.021 1.038 C 19.616 1.038 18.092 1.625 17.037 2.561 C 16.334 3.266 15.747 4.085 15.279 5.024 C 14.46 5.257 13.639 5.608 12.817 6.195 L 9.537 6.195 C 7.544 6.31 5.787 7.953 5.787 10.061 L 5.787 37.015 C 5.787 39.126 7.544 40.883 9.654 40.883 L 32.507 40.883 C 34.616 40.883 36.373 39.126 36.373 37.015 L 36.373 10.061 C 36.373 7.953 34.616 6.195 32.507 6.195 L 29.225 6.195 Z M 17.859 6.781 C 17.859 6.663 17.974 6.429 17.974 6.31 C 18.443 4.906 19.616 3.968 21.138 3.968 C 22.545 3.968 23.834 5.024 24.302 6.31 C 24.302 6.429 24.42 6.663 24.42 6.781 C 24.537 7.132 24.77 7.484 25.123 7.601 C 26.53 7.953 27.585 8.538 28.288 9.125 C 28.405 9.243 28.522 9.358 28.64 9.476 C 29.109 10.061 28.757 10.766 28.053 10.766 L 14.225 10.766 C 13.52 10.766 13.17 9.945 13.639 9.476 C 13.756 9.358 13.873 9.243 13.989 9.125 C 14.694 8.421 15.865 7.953 17.155 7.601 C 17.507 7.484 17.74 7.132 17.859 6.781 L 17.859 6.781 Z M 33.562 10.061 L 33.562 37.015 C 33.562 37.602 33.092 38.072 32.507 38.072 L 9.654 38.072 C 9.069 38.072 8.599 37.602 8.599 37.015 L 8.599 10.061 C 8.599 9.476 9.069 9.006 9.654 9.006 L 10.709 9.006 C 10.709 9.125 10.591 9.243 10.591 9.476 C 10.474 10.18 10.591 10.766 10.943 11.468 C 11.178 12.054 11.646 12.641 12.232 12.992 C 12.817 13.345 13.52 13.578 14.225 13.578 L 27.935 13.578 C 28.64 13.578 29.342 13.345 29.927 12.992 C 30.514 12.641 30.866 12.054 31.218 11.468 C 31.451 10.883 31.569 10.18 31.569 9.476 C 31.569 9.358 31.569 9.243 31.451 9.006 L 32.507 9.006 C 33.092 9.125 33.562 9.476 33.562 10.061 L 33.562 10.061 Z M 33.562 10.061 M 21.021 8.186 C 21.841 8.186 22.428 7.601 22.428 6.781 C 22.428 6.547 22.428 6.429 22.312 6.31 C 22.194 5.725 21.725 5.374 21.021 5.374 C 20.436 5.374 19.85 5.725 19.733 6.31 C 19.616 6.429 19.616 6.663 19.616 6.781 C 19.616 7.601 20.319 8.186 21.021 8.186 L 21.021 8.186 Z M 21.021 8.186 M 15.279 19.906 C 15.513 19.671 15.747 19.553 15.982 19.553 L 23.366 19.553 C 23.598 19.553 23.951 19.671 24.068 19.906 C 24.302 20.139 24.302 20.375 24.42 20.609 L 24.42 21.43 C 24.42 21.664 24.302 22.015 24.068 22.133 C 23.834 22.368 23.598 22.484 23.366 22.484 L 20.085 22.484 L 27.467 29.866 C 27.701 30.102 27.701 30.336 27.701 30.571 C 27.701 30.805 27.585 31.038 27.349 31.273 L 26.646 31.977 C 26.414 32.211 26.178 32.328 25.945 32.328 C 25.71 32.328 25.475 32.211 25.241 32.095 L 17.859 24.711 L 17.859 27.992 C 17.859 28.226 17.74 28.461 17.507 28.695 C 17.271 28.93 17.037 29.048 16.804 29.048 L 15.982 29.048 C 15.747 29.048 15.396 28.93 15.279 28.695 C 15.045 28.461 14.929 28.226 14.929 27.992 L 14.929 20.609 C 14.929 20.375 15.045 20.139 15.279 19.906 Z' style=''/%3E %3C/svg%3E\""

/***/ }),
/* 531 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='item_x5F_move' d='M14,5.3c0.4-0.4,0.8-0.7,1.4-0.9C16,4.1,16.6,4,17.1,4h17c0.5,0,0.9,0.2,1.3,0.5 c0.4,0.4,0.5,0.8,0.5,1.3v30.3c0,0.5-0.2,0.9-0.5,1.3C35,37.8,34.6,38,34.1,38H8.6c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3 V14.3c0-0.5,0.1-1.1,0.4-1.7C7.4,12,7.7,11.6,8,11.2L14,5.3z M15.7,7l-5.9,5.9c-0.2,0.2-0.3,0.4-0.4,0.8h7.1V6.6 C16.1,6.7,15.8,6.8,15.7,7z M33.5,35.6V6.4H18.9v7.9c0,0.5-0.2,0.9-0.5,1.3c-0.4,0.4-0.8,0.5-1.3,0.5H9.2v19.4H33.5z M16.7,20.5 c0.2-0.2,0.4-0.3,0.6-0.3h6.3c0.2,0,0.5,0.1,0.6,0.3c0.2,0.2,0.2,0.4,0.3,0.6v0.7c0,0.2-0.1,0.5-0.3,0.6c-0.2,0.2-0.4,0.3-0.6,0.3 h-2.8l6.3,6.3c0.2,0.2,0.2,0.4,0.2,0.6c0,0.2-0.1,0.4-0.3,0.6l-0.6,0.6c-0.2,0.2-0.4,0.3-0.6,0.3c-0.2,0-0.4-0.1-0.6-0.2l-6.3-6.3 l0,2.8c0,0.2-0.1,0.4-0.3,0.6c-0.2,0.2-0.4,0.3-0.6,0.3h-0.7c-0.2,0-0.5-0.1-0.6-0.3c-0.2-0.2-0.3-0.4-0.3-0.6v-6.3 C16.4,20.9,16.5,20.7,16.7,20.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 532 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.2,24.1 M37.4,32.4V10c0-0.2-0.1-0.3-0.2-0.4c-0.1-0.1-0.3-0.2-0.4-0.2H5c-0.2,0-0.3,0.1-0.4,0.2C4.4,9.7,4.4,9.8,4.4,10 v22.4c0,0.2,0.1,0.3,0.2,0.4C4.7,32.9,4.8,33,5,33h6.5v-1.8c0-0.2,0.1-0.3,0.2-0.4c0.1-0.1,0.3-0.2,0.4-0.2h1.2 c0.2,0,0.3,0.1,0.4,0.2c0.1,0.1,0.2,0.3,0.2,0.4V33H28v-1.8c0-0.2,0.1-0.3,0.2-0.4c0.1-0.1,0.3-0.2,0.4-0.2h1.2 c0.2,0,0.3,0.1,0.4,0.2c0.1,0.1,0.2,0.3,0.2,0.4V33h6.5c0.2,0,0.3-0.1,0.4-0.2C37.4,32.7,37.4,32.6,37.4,32.4z M39.8,10v22.4 c0,0.8-0.3,1.5-0.9,2.1c-0.6,0.6-1.3,0.9-2.1,0.9H5c-0.8,0-1.5-0.3-2.1-0.9C2.3,33.9,2,33.2,2,32.4V10c0-0.8,0.3-1.5,0.9-2.1 S4.1,7,5,7h31.9c0.8,0,1.5,0.3,2.1,0.9C39.5,8.4,39.8,9.1,39.8,10z M28.3,26.8L27.1,28c-0.2,0.2-0.4,0.2-0.6,0.2s-0.4-0.1-0.6-0.2 l-5-5l-5,5c-0.2,0.2-0.4,0.2-0.6,0.2s-0.4-0.1-0.6-0.2l-1.2-1.2c-0.2-0.2-0.2-0.4-0.2-0.6c0-0.2,0.1-0.4,0.2-0.6l5-5l-5-5 c-0.2-0.2-0.2-0.4-0.2-0.6s0.1-0.4,0.2-0.6l1.2-1.2c0.2-0.2,0.4-0.2,0.6-0.2s0.4,0.1,0.6,0.2l5,5l5-5c0.2-0.2,0.4-0.2,0.6-0.2 s0.4,0.1,0.6,0.2l1.2,1.2c0.2,0.2,0.2,0.4,0.2,0.6s-0.1,0.4-0.2,0.6l-5,5l5,5c0.2,0.2,0.2,0.4,0.2,0.6 C28.6,26.4,28.5,26.6,28.3,26.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 533 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.6,21c0-2.6-0.7-5.1-2-7.3s-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3s-2,4.7-2,7.3s0.7,5.1,2,7.3 s3.1,4,5.3,5.3s4.7,2,7.3,2s5.1-0.7,7.3-2s4-3.1,5.3-5.3S35.6,23.6,35.6,21z M38,21c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2 C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3c-2.6-1.5-4.7-3.6-6.2-6.2S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2 S17.9,4,21,4c3.1,0,5.9,0.8,8.5,2.3s4.7,3.6,6.2,6.2C37.2,15.1,38,17.9,38,21z M22.7,26.2v2.9c0,0.2-0.1,0.3-0.2,0.4 c-0.1,0.1-0.2,0.2-0.4,0.2h-2.9c-0.2,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.2-0.2-0.2-0.4v-2.9c0-0.2,0.1-0.3,0.2-0.4 c0.1-0.1,0.2-0.2,0.4-0.2h2.9c0.2,0,0.3,0.1,0.4,0.2C22.7,25.9,22.7,26,22.7,26.2z M27.3,17.3c0,0.6-0.1,1.1-0.3,1.6 s-0.5,0.9-0.8,1.2c-0.4,0.3-0.7,0.6-0.9,0.8c-0.3,0.2-0.6,0.4-1.1,0.6c-0.4,0.2-0.7,0.4-0.8,0.5c-0.2,0.1-0.3,0.3-0.5,0.4 c-0.1,0.2-0.2,0.3-0.2,0.5v0.6c0,0.2-0.1,0.3-0.2,0.4c-0.1,0.1-0.2,0.2-0.4,0.2h-2.9c-0.2,0-0.3-0.1-0.4-0.2 c-0.1-0.1-0.2-0.2-0.2-0.4v-1.2c0-0.4,0.1-0.8,0.2-1.2s0.3-0.6,0.4-0.9c0.2-0.2,0.4-0.4,0.7-0.6c0.3-0.2,0.6-0.4,0.7-0.5 s0.5-0.2,0.8-0.4c0.6-0.3,1.1-0.6,1.3-0.8c0.3-0.2,0.4-0.5,0.4-0.9c0-0.5-0.3-0.9-0.8-1.3c-0.5-0.4-1.1-0.5-1.7-0.5 c-0.7,0-1.2,0.2-1.7,0.5c-0.3,0.2-0.8,0.7-1.4,1.5c-0.1,0.1-0.3,0.2-0.4,0.2c-0.1,0-0.2,0-0.3-0.1L14.9,16c-0.1-0.1-0.2-0.2-0.2-0.4 c0-0.2,0-0.3,0.1-0.4c1.5-2.3,3.5-3.4,6.3-3.4c1.5,0,3,0.5,4.3,1.6S27.3,15.8,27.3,17.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 534 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38.5,33.1H41v3.1c0,0.5-0.2,0.9-0.5,1.3S39.6,38,39.1,38H13.6c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3v-3.1h2.4v2.5h24.3 V33.1z M41,14.3v18.8h-2.4v-17h-7.9c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3V6.4H14.2v11.7h-2.4V5.8c0-0.5,0.2-0.9,0.5-1.3 C12.7,4.2,13.1,4,13.6,4h17c0.5,0,1.1,0.1,1.7,0.4c0.6,0.3,1.1,0.6,1.4,0.9l5.9,5.9c0.4,0.4,0.7,0.8,0.9,1.4 C40.8,13.3,41,13.8,41,14.3z M38.4,13.7c-0.1-0.4-0.3-0.6-0.4-0.8L32,7c-0.2-0.2-0.4-0.3-0.8-0.4v7.1H38.4z M23.3,25.3 c0,0.3-0.1,0.5-0.3,0.7l-5.2,5.2c-0.2,0.2-0.4,0.3-0.7,0.3c-0.3,0-0.5-0.1-0.7-0.3l-0.6-0.6c-0.2-0.2-0.3-0.4-0.3-0.7 s0.1-0.5,0.3-0.7l2.3-2.3H2.9c-0.3,0-0.5-0.1-0.7-0.3C2.1,26.3,2,26.1,2,25.8v-1c0-0.3,0.1-0.5,0.3-0.7c0.2-0.2,0.4-0.3,0.7-0.3 h15.2l-2.3-2.3c-0.2-0.2-0.3-0.4-0.3-0.7s0.1-0.5,0.3-0.7l0.6-0.6c0.2-0.2,0.4-0.3,0.7-0.3c0.3,0,0.5,0.1,0.7,0.3l5.2,5.2 C23.2,24.7,23.3,25,23.3,25.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 535 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cg%3E %3Cpath d='M34,13.4c-0.2-1.7-1-3.3-2.4-4.4l-0.8-0.6C29.7,7.5,28.3,7,26.8,7c-2,0-3.8,0.9-5,2.4L9.9,24.1c-1.1,1.3-1.6,3-1.4,4.8 c0.2,1.7,1,3.3,2.4,4.4l0.8,0.6c1.1,0.9,2.6,1.4,4.1,1.4c0.2,0,0.5,0,0.7,0c1.7-0.2,3.3-1,4.3-2.3c0,0,0,0,8-9.9 c1.4-1.8,1.2-4.4-0.6-5.8l-0.4-0.3C27,16.3,26.1,16,25.1,16c-1.3,0-2.4,0.6-3.2,1.5l-8,9.9c-0.5,0.6-0.4,1.6,0.2,2.1 c0.3,0.2,0.6,0.3,0.9,0.3c0.5,0,0.9-0.2,1.2-0.6l8-9.9c0.2-0.3,0.5-0.4,0.9-0.4c0.3,0,0.5,0.1,0.7,0.2l0.4,0.3 c0.2,0.2,0.4,0.4,0.4,0.7c0,0.3-0.1,0.6-0.2,0.8l-8,9.9c-0.7,0.8-1.6,1.3-2.7,1.3c-0.8,0-1.6-0.3-2.2-0.8l-0.8-0.6 c-0.7-0.6-1.2-1.4-1.3-2.3c-0.1-0.9,0.2-1.8,0.8-2.5l11.9-14.7c0.7-0.8,1.6-1.3,2.7-1.3c0.8,0,1.6,0.3,2.2,0.8l0.8,0.6 c1.5,1.2,1.7,3.4,0.5,4.9C30,16.6,29.9,17,30,17.4c0,0.4,0.2,0.8,0.6,1c0.3,0.2,0.6,0.3,0.9,0.3c0.5,0,0.9-0.2,1.2-0.6 C33.7,16.8,34.2,15.1,34,13.4L34,13.4z M34,13.4'/%3E %3C/g%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 536 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.8,21.3c0-2.1-0.5-4-1.6-5.8c-1-1.8-2.4-3.2-4.2-4.2c-1.8-1-3.7-1.6-5.8-1.6s-4,0.5-5.8,1.6s-3.2,2.4-4.2,4.2 s-1.6,3.7-1.6,5.8s0.5,4,1.6,5.8c1,1.8,2.4,3.2,4.2,4.2c1.8,1,3.7,1.6,5.8,1.6s4-0.5,5.8-1.6c1.8-1,3.2-2.4,4.2-4.2 C32.3,25.3,32.8,23.4,32.8,21.3z M35.4,21.3c0,2.6-0.6,4.9-1.9,7.1c-1.3,2.2-3,3.9-5.2,5.2c-2.2,1.3-4.5,1.9-7.1,1.9 s-4.9-0.6-7.1-1.9c-2.2-1.3-3.9-3-5.2-5.2s-1.9-4.5-1.9-7.1s0.6-4.9,1.9-7.1s3-3.9,5.2-5.2s4.5-1.9,7.1-1.9s4.9,0.6,7.1,1.9 s3.9,3,5.2,5.2C34.8,16.3,35.4,18.7,35.4,21.3z M30.4,29.1l-1.2,1.2c-0.2,0.2-0.4,0.2-0.6,0.2c-0.2,0-0.4-0.1-0.6-0.2l-6.7-6.7l-7,7 c-0.2,0.2-0.4,0.2-0.6,0.2c-0.2,0-0.4-0.1-0.6-0.2l-1.2-1.2c-0.2-0.2-0.2-0.4-0.2-0.6c0-0.2,0.1-0.4,0.2-0.6l7-7l-7.1-7 c-0.2-0.2-0.2-0.4-0.2-0.6s0.1-0.4,0.2-0.6l1.2-1.2c0.2-0.2,0.4-0.2,0.6-0.2s0.4,0.1,0.6,0.2l7,7l8.2-8.2c0.2-0.2,0.4-0.2,0.6-0.2 s0.4,0.1,0.6,0.2l1.2,1.2c0.2,0.2,0.2,0.4,0.2,0.6s-0.1,0.4-0.2,0.6l-8.2,8.2l6.7,6.7c0.2,0.2,0.2,0.4,0.2,0.6 C30.6,28.8,30.5,29,30.4,29.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 537 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M29.5,13.6c1.3,0,2.5-0.5,3.4-1.4s1.4-2.1,1.4-3.4c0-1.3-0.5-2.4-1.4-3.4c-1-0.9-2.1-1.4-3.4-1.4c-1.4,0-2.5,0.5-3.4,1.4 s-1.4,2.1-1.4,3.4c0,1.3,0.5,2.5,1.4,3.4S28.2,13.6,29.5,13.6z M27.3,6.6c0.6-0.6,1.3-0.9,2.2-0.9c0.9,0,1.6,0.3,2.2,0.9 c0.6,0.7,0.9,1.4,0.9,2.2c0,0.9-0.3,1.6-0.9,2.2c-0.6,0.6-1.4,0.9-2.2,0.9c-0.9,0-1.6-0.3-2.2-0.9c-0.6-0.6-0.9-1.4-0.9-2.2 C26.4,8,26.7,7.2,27.3,6.6z M31.5,31.1c0.1,0.7,0.1,1.4,0.1,2c0,1.5-0.5,2.7-1.4,3.6S28.1,38,26.5,38H10.1c-1.5,0-2.7-0.4-3.7-1.3 C5.5,35.8,5,34.6,5,33.1c0-0.7,0-1.3,0.1-2c0.1-0.7,0.1-1.3,0.3-2.1c0.1-0.7,0.3-1.4,0.5-2s0.5-1.2,0.8-1.8s0.7-1.1,1.2-1.5 c0.4-0.4,1-0.8,1.6-1c0.6-0.2,1.3-0.4,2.1-0.4c0.1,0,0.4,0.1,0.8,0.4s0.9,0.6,1.4,0.9c0.5,0.3,1.2,0.6,2,0.9 c0.8,0.3,1.7,0.4,2.5,0.4s1.7-0.1,2.5-0.4c0.8-0.3,1.5-0.6,2-0.9s1-0.6,1.4-0.9c0.4-0.3,0.7-0.4,0.8-0.4c0.8,0,1.5,0.1,2.1,0.4 s1.2,0.6,1.6,1c0.4,0.4,0.8,0.9,1.2,1.5c0.3,0.6,0.6,1.2,0.8,1.8c0.2,0.6,0.4,1.3,0.5,2C31.3,29.7,31.4,30.4,31.5,31.1z M13.8,20.6 c-1.3-1.3-1.9-2.8-1.9-4.5s0.6-3.3,1.9-4.5c1.3-1.2,2.8-1.9,4.5-1.9c1.8,0,3.3,0.6,4.5,1.9c1.3,1.2,1.9,2.7,1.9,4.5 s-0.6,3.3-1.9,4.5c-1.3,1.3-2.8,1.9-4.5,1.9C16.5,22.5,15,21.9,13.8,20.6z M34.2,13.7c-0.1,0-0.3,0.1-0.8,0.4 c-0.4,0.3-1,0.5-1.8,0.8c-0.7,0.3-1.5,0.4-2.2,0.4c-0.8,0-1.7-0.1-2.5-0.4c0.1,0.4,0.1,0.8,0.1,1.2c0,1.7-0.5,3.3-1.5,4.8 c2,0,3.7,0.9,5,2.4H33c1,0,1.9-0.3,2.6-0.8c0.7-0.5,1.1-1.2,1.1-2.2C36.7,15.9,35.9,13.7,34.2,13.7z M34.4,21.3 c-0.5,0.3-1.1,0.5-1.7,0.5H31c-0.9-1-2-1.6-3.3-1.6c0.7-1,1-2,1-3.2c0-0.3,0-0.5-0.1-0.8c0.5,0.2,1.1,0.3,1.6,0.3 c0.5,0,1-0.1,1.5-0.3c0.5-0.2,0.9-0.3,1.2-0.5c0.3-0.2,0.5-0.3,0.5-0.3c1.1,0,1.6,1.5,1.6,4.4C35.1,20.5,34.9,21,34.4,21.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 538 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M9.8,18.1H7.2V8.1c0-0.5,0.4-0.8,1-0.8h7.6c0.3,0,0.7,0.2,0.8,0.4l1.4,2h17c0.5,0,1,0.4,1,0.8v7.7h-2.8v-5.8H9.8V18.1z M38,19.3c-0.1-0.1-0.3-0.2-0.5-0.2h-9.1l3,2.8h2.9c0.2,0,0.4,0.1,0.5,0.2c0.1,0.1,0.2,0.3,0.2,0.5L33,31.8 c-0.1,0.3-0.3,0.5-0.7,0.5l-21.5,0c-0.3,0-0.6-0.2-0.7-0.5l-1.8-9.2c0-0.2,0-0.3,0.2-0.5C8.6,22,8.8,21.9,9,21.9h3.8l2.9-2.8h-10 c-0.2,0-0.4,0.1-0.5,0.2C5,19.4,5,19.6,5,19.8l2.7,14.4c0.1,0.3,0.3,0.5,0.7,0.5h26.3c0.4,0,0.6-0.2,0.7-0.5l2.7-14.4 C38.2,19.6,38.1,19.4,38,19.3z M29.1,22.1l-6.2-6.2c-0.2-0.2-0.4-0.3-0.6-0.3s-0.5,0.1-0.6,0.3l-6.2,6.2c-0.3,0.3-0.4,0.6-0.2,1 c0.2,0.4,0.4,0.6,0.8,0.6h3.6v6.2c0,0.2,0.1,0.4,0.3,0.6c0.2,0.2,0.4,0.3,0.6,0.3H24c0.2,0,0.4-0.1,0.6-0.3c0.2-0.2,0.3-0.4,0.3-0.6 v-6.2h3.6c0.4,0,0.7-0.2,0.8-0.6C29.4,22.7,29.3,22.4,29.1,22.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 539 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M37.4,19.1H5.7c-0.2,0-0.4,0.1-0.5,0.2C5,19.4,5,19.6,5,19.8l2.7,14.4c0.1,0.3,0.3,0.5,0.7,0.5h26.3c0.4,0,0.6-0.2,0.7-0.5 l2.7-14.4c0-0.2,0-0.3-0.2-0.5C37.8,19.2,37.7,19.1,37.4,19.1z M33,31.8c-0.1,0.3-0.3,0.5-0.7,0.5l-21.5,0c-0.3,0-0.6-0.2-0.7-0.5 l-1.8-9.2c0-0.2,0-0.3,0.2-0.5C8.6,22,8.8,21.9,9,21.9h25.2c0.2,0,0.4,0.1,0.5,0.2c0.1,0.1,0.2,0.3,0.2,0.5L33,31.8z M9.8,18.1H7.2 V8.1c0-0.5,0.4-0.8,1-0.8h7.6c0.3,0,0.7,0.2,0.8,0.4l1.4,2h17c0.5,0,1,0.4,1,0.8v7.7h-2.8v-5.8H9.8V18.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 540 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.6,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.5,38,34,38H8.5 c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.6,4.2,8,4,8.5,4h17c0.5,0,1.1,0.1,1.7,0.4 c0.6,0.3,1.1,0.6,1.4,0.9L34.6,11.2z M26.1,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.9,7C26.8,6.8,26.5,6.7,26.1,6.6z M33.4,35.6 V16.2h-7.9c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3V6.4H9.1v29.2H33.4z'/%3E %3Cpath id='spreadsheet_neu' d='M30.7,22.8H19.3v-8.6c0-0.4-0.4-0.8-0.8-0.8h-6.6c-0.4,0-0.8,0.4-0.8,0.8v14.1c0,0.4,0.4,0.8,0.8,0.8 h5.8V33c0,0.4,0.4,0.8,0.8,0.8h5.2c0.4,0,0.8-0.4,0.8-0.8v-4h5.4v3.2h-2.2c-0.4,0-0.8,0.4-0.8,0.8c0,0.4,0.4,0.8,0.8,0.8h3 c0.4,0,0.8-0.4,0.8-0.8v-9.5C31.5,23.1,31.1,22.8,30.7,22.8z M12.6,22.8v-3.1h5v3.1H12.6z M17.7,15V18h-5V15H17.7z M17.7,29.1v-1.6 h-5v-3.1h5c0,0,0,0,0,0v3.1h6.8v1.6H17.7z M24.5,27.5v-3.1h5.4v3.1H24.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 541 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M35.8,7.9C35.2,7.3,34.5,7,33.7,7H9C8.1,7,7.4,7.3,6.9,7.9C6.3,8.4,6,9.1,6,10v22.4c0,0.8,0.3,1.5,0.9,2.1 C7.4,35,8.1,35.3,9,35.3h24.8c0.8,0,1.5-0.3,2.1-0.9c0.6-0.6,0.9-1.3,0.9-2.1V10C36.7,9.1,36.4,8.4,35.8,7.9L35.8,7.9z M20.2,33H9 c-0.2,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.2-0.3-0.2-0.4V11.7h11.8V33z M34.3,32.4c0,0.2-0.1,0.3-0.2,0.4C34,32.9,33.9,33,33.7,33H22.5 V11.7h11.8V32.4z M34.3,32.4'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 542 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.6,21c0-2.6-0.7-5.1-2-7.3s-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3s-2,4.7-2,7.3s0.7,5.1,2,7.3 s3.1,4,5.3,5.3s4.7,2,7.3,2s5.1-0.7,7.3-2s4-3.1,5.3-5.3S35.6,23.6,35.6,21z M38,21c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2 C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3c-2.6-1.5-4.7-3.6-6.2-6.2S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2 S17.9,4,21,4c3.1,0,5.9,0.8,8.5,2.3s4.7,3.6,6.2,6.2C37.2,15.1,38,17.9,38,21z M19.6,22.4h-7.7c-0.2,0-0.4-0.1-0.5-0.2 c-0.1-0.1-0.2-0.3-0.2-0.5v-1.4c0-0.2,0.1-0.4,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h7.7h10.5c0.2,0,0.4,0.1,0.5,0.2 c0.1,0.1,0.2,0.3,0.2,0.5v1.4c0,0.2-0.1,0.4-0.2,0.5s-0.3,0.2-0.5,0.2H19.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 543 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M25.5,20.2l-3.4-3.4l3.7-3.7l3.4,3.4L25.5,20.2z M10.4,35.3l13.8-13.8l-3.4-3.4L7,32L10.4,35.3z M17.9,10v1.5h-1.5v1.3h1.5 v1.5h1.3v-1.5h1.5v-1.3h-1.5V10H17.9z M30.6,7v1.5H29v1.3h1.5v1.5h1.3V9.8h1.5V8.5h-1.5V7H30.6z M35.5,16.4H34v-1.5h-1.3v1.5h-1.5 v1.3h1.5v1.5H34v-1.5h1.5V16.4z M35.5,16.4'/%3E %3C/svg%3E\""

/***/ }),
/* 544 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M21.1,27.9c-1,0-1.9,0.9-1.9,1.9c0,1,0.9,1.9,1.9,1.9c1,0,1.9-0.9,1.9-1.9C23.1,28.7,22.2,27.9,21.1,27.9L21.1,27.9z M21.1,27.9 M38.8,34.6c1.2-2.1,1.2-4.5,0-6.6l-12-20.7C25.7,5.3,23.6,4,21.2,4s-4.5,1.2-5.7,3.3l-12,20.7c-1.2,2.1-1.2,4.6,0,6.6 c1.2,2,3.3,3.3,5.7,3.3h23.9C35.5,38,37.6,36.7,38.8,34.6L38.8,34.6z M36.2,33.1c-0.7,1.1-1.8,1.8-3.2,1.8H9.2 c-1.3,0-2.5-0.7-3.1-1.8c-0.7-1.1-0.7-2.5,0-3.6L18,8.8C18.7,7.7,19.8,7,21.2,7c1.3,0,2.5,0.7,3.1,1.8l12,20.7 C36.9,30.7,36.9,32,36.2,33.1L36.2,33.1z M36.2,33.1 M20.7,14.5c-0.9,0.3-1.5,1.1-1.5,2.1c0,0.6,0.1,1.2,0.1,1.8 c0.1,2.3,0.3,4.6,0.4,6.8c0,0.8,0.6,1.3,1.4,1.3s1.4-0.6,1.4-1.4c0-0.5,0-0.9,0-1.4c0.1-1.5,0.2-2.9,0.3-4.4c0-1,0.1-1.9,0.2-2.9 c0-0.3,0-0.6-0.2-1C22.5,14.7,21.6,14.3,20.7,14.5L20.7,14.5z M20.7,14.5'/%3E %3C/svg%3E\""

/***/ }),
/* 545 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links_2_' d='M21.2,13c-0.2,0-0.5,0.1-0.7,0.3L7.3,26.5C7.1,26.7,7,26.9,7,27.2c0,0.2,0.1,0.5,0.3,0.7l1.4,1.4 c0.2,0.2,0.4,0.3,0.7,0.3c0.2,0,0.5-0.1,0.7-0.3l11.2-11.2l11.2,11.2c0.2,0.2,0.4,0.3,0.7,0.3s0.5-0.1,0.7-0.3l1.4-1.4 c0.2-0.2,0.3-0.4,0.3-0.7c0-0.2-0.1-0.5-0.3-0.7L21.8,13.3C21.6,13.1,21.4,13,21.2,13z'/%3E %3C/svg%3E\""

/***/ }),
/* 546 */,
/* 547 */,
/* 548 */,
/* 549 */,
/* 550 */,
/* 551 */,
/* 552 */,
/* 553 */,
/* 554 */,
/* 555 */,
/* 556 */,
/* 557 */,
/* 558 */,
/* 559 */,
/* 560 */,
/* 561 */,
/* 562 */,
/* 563 */,
/* 564 */,
/* 565 */,
/* 566 */,
/* 567 */,
/* 568 */,
/* 569 */,
/* 570 */,
/* 571 */,
/* 572 */,
/* 573 */,
/* 574 */,
/* 575 */,
/* 576 */,
/* 577 */,
/* 578 */,
/* 579 */,
/* 580 */,
/* 581 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ getTwingEnv; });

// EXTERNAL MODULE: ./node_modules/twing/browser.js
var browser = __webpack_require__(240);

// EXTERNAL MODULE: ./node_modules/twing-intl/browser.js
var twing_intl_browser = __webpack_require__(525);

// CONCATENATED MODULE: ./util/transliterate.js
/*
 * borrowed from https://github.com/annexare/toURI/blob/master/lib/toURI.js
 * @license MIT
 *
 * NOTE: this is just an ultraslim transliterate implementation for practical purpuses in client
 *       if you need mor exact transliteration do it on server side!
 */
const pairs = {
  // Cyrillic
  'а': 'a',
  'б': 'b',
  'в': 'v',
  'г': 'g',
  'д': 'd',
  'е': 'e',
  'ё': 'yo',
  'ж': 'zh',
  'з': 'z',
  'и': 'y',
  'й': 'j',
  'кс': 'x',
  'к': 'k',
  'л': 'l',
  'м': 'm',
  'н': 'n',
  'о': 'o',
  'п': 'p',
  'р': 'r',
  'с': 's',
  'т': 't',
  'у': 'u',
  'ф': 'f',
  'х': 'h',
  'ц': 'ts',
  'ч': 'ch',
  'ш': 'sh',
  'щ': 'shch',
  'ъ': '',
  'ы': 'y',
  'ь': '',
  'э': 'e',
  // Part is done as: http://zakon4.rada.gov.ua/laws/show/55-2010-%D0%BF
  // But don't agree with "Гг | Hh", nobody talks like that.
  '^ю': 'yu',
  '\\s+ю': ' yu',
  'ю': 'iu',
  '^я': 'ya',
  '\\s+я': ' ya',
  'я': 'ia',
  '^є': 'ye',
  '\\s+є': ' ye',
  'є': 'ie',
  'і': 'i',
  '^ї': 'yi',
  '\\s+ї': ' yi',
  'ї': 'i',
  'ґ': 'gh',
  // Symbols & Accents
  '\\.': '_',
  '&': 'and',
  '∞': 'infinity',
  '♥': 'love',
  'ä|æ|ǽ': 'ae',
  'ö|œ': 'oe',
  'ü': 'ue',
  'à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª': 'a',
  'ç|ć|ĉ|ċ|č': 'c',
  'ð|ď|đ': 'd',
  'è|é|ê|ë|ē|ĕ|ė|ę|ě': 'e',
  'ĝ|ğ|ġ|ģ': 'g',
  'ĥ|ħ': 'h',
  'ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı': '',
  'ĵ': 'j',
  'ķ': 'k',
  'ĺ|ļ|ľ|ŀ|ł': 'l',
  'ñ|ń|ņ|ň|ŉ': 'n',
  'ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º': 'o',
  'ŕ|ŗ|ř': 'r',
  'ś|ŝ|ş|š|ſ': 's',
  'ţ|ť|ŧ': 't',
  'ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ': 'u',
  'ý|ÿ|ŷ': 'y',
  'ŵ': 'w',
  'ź|ż|ž': 'z',
  'ß': 'ss',
  'ĳ': 'ij',
  'ƒ': 'f',
  // Currencies
  '\\$': 'USD',
  '€': 'EUR',
  '£': 'GBP',
  '₴': 'UAH',
  '¢': 'cent'
};
const isRU = /ы|ъ|э|ё|ъ|(\s|^)и|жь|чь|шь|иа|ие|ии|ио|иу|аи|еи|ои|уи|цк|ец(\s|$)/;
const isUA = /є|i|ї|ґ|зьк|ськ|цьк|ць(\s|$)|(нн|тт|чч)[юя]/;

const strtr = (string, pairs) => {
  // Just like this:
  // http://php.net/manual/en/function.strtr.php
  let str = string;

  for (var key in pairs) if (pairs.hasOwnProperty(key)) {
    str = str.replace(new RegExp(key, 'g'), pairs[key]);
  }

  return str;
};

const transliterate = text => {
  pairs['и'] = text.search(isRU) !== -1 && text.search(isUA) === -1 ? 'i' : 'y';
  return strtr(text, pairs);
};

/* harmony default export */ var util_transliterate = (transliterate);
// CONCATENATED MODULE: ./twingEnv.es6.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2019 Metaways Infosystems GmbH (http://www.metaways.de)
 */



let twingEnv;
function getTwingEnv() {
  if (!twingEnv) {
    let loader = new browser["TwingLoaderArray"]([]);
    twingEnv = new browser["TwingEnvironment"](loader, {
      autoescape: false
    });
    twingEnv.addGlobal('app', {
      branding: _.filter(Tine.Tinebase.registry.getAll(), function (v, k) {
        return k.match(/^branding/);
      }),
      user: {
        locale: Tine.Tinebase.registry.get('locale').locale || 'en',
        timezone: Tine.Tinebase.registry.get('timeZone') || 'UTC'
      }
    });
    twingEnv.addExtension(new twing_intl_browser["TwingExtensionIntl"]());
    twingEnv.addFilter(new browser["TwingFilter"]('removeSpace', function (string) {
      return string.replaceAll(' ', '');
    }));
    twingEnv.addFilter(new browser["TwingFilter"]('transliterate', function (string) {
      return util_transliterate(string);
    }));
  }

  return twingEnv;
}

/***/ }),
/* 582 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAqAIcAAKLG9KTH9KfJ9anK9avM9a7N9rDP9rLQ9rXR97fT97rU+LzW+L7X+Nvb28HZ+cXb+cjd+czg+s/i+tLk+tbm+trp+9/s++Tk5Ozs7OPv/Ojy/Pb29v39/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABACoAAAgwADdcAMBBg0ENDhI62ACgAQYNGSxUoEBhgoQIEB44ABBAwAACBQwcQJBAwQIGDgICADs="

/***/ }),
/* 583 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCwALAIcAAFR6r0D/QFuAs2KGuGiLvG+RwI2y45m76Mfb88/k+9Ln/Nbp/uHz/+j2//D5//T6//f8//v9/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAALAAsAAAhdAAMEOECw4AGBAyUoXCjh4AEJDBA4mIiAQcMDERAUKOBgI4IIBCE0IECSZAMIBB8wYDCg5coHBBkkEECTZgIGMQ0AAKBgpwGcBxgsMLCgKFGcA1cqXXlQoMGCAgMCADs="

/***/ }),
/* 584 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAADAIcAAAD/AP8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAAALAAAAAAEAAMAAAgMAAMAGAhAoMCCAAICADs="

/***/ }),
/* 585 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAED/QMJLMsNNNMVPNsNUPcxVPMZXQcddRs5dTNBZQcxiTM5kTtVgR9FjTNFhUNRkUthwWd5wWd1wXd18b919b+FdUuJfU+NhVOViVeZlVudnV+NmW+RnXOdsXehpWOpsWetuWulvX+F0XOVyWep2XexwW+5zXO92XfB4X/F6X+BzYO57Yel9aPN8YPN+YemCau2BaeyBbO6DbuOEdeaIeOqHfeuJfeqNe+yLf+ySf/KAZfSAYvWBYvWCY/SEZ/WEaveGbPaJa/iGbfONdvWOd/eMdfqOd/qUfN6hleWOg+eQhOeRheySiO2SieyYie2flfGTgvCXg/GXhPSZhPCfjvGdkOGkl+Onmu6glfihiPiiifijivOmkfSmkvGlmfGom/Gon/Kpn+uvovOvpvSsofWwo/ezoPezpPC0qPi0oPi2ofi1pfm5pvq8qPu9qfi+sfq/sv3DtfrZ0////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAAAQABAAAAjBAAEIHEiwoME4R4D8IPLG4EAjMrqkScOFBQyHQqS42RIkiJY2OUYULBLFTY8ec+a4aMHmhoiBcGKY5LEjZQoUJ9ZIECNwCJcsO1amPGGiBBQnEASuUOOjxc2UJUB8CPElgUASZnTgNCFnzgcPGjp4KSDwBZUpRUFUGaMhAwYbSxYIRKPijFQPKTFcsBDGgZWBEWiUaduEiYUKYSgYKMhgBhkcHDbUADMhgMMGD5RgeZIEAQGHAq8oGCDgABLQqAkGBAA7"

/***/ }),
/* 586 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDgBIAIcAAAAAAKrI8cLa9tru/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAIALAAAAAAOAEgAAAiGAAUEGCCgoMGDBQciXCiQIMODCh8ajCixYcWEDitSlLjxYUeGHxeGRDgSYkaOJz2mBLlSZEuSL01etHix5MSYN2faxKgTJ8+aPmlqDLpTKMqeSAsCWLpUpkGmMBECcJl0aNWjQK+q1MqSK9WsYK2GxSq2LNmzW8emNbsWbVe1b9nGdftVYkAAOw=="

/***/ }),
/* 587 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhyAAOAIcAAAAAAMTExMLa9v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAIALAAAAADIAA4AAAhfAAUIHEiwoMGDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypcuXMGPKnEmzpk2GAHLmvMmzJ0edPoMKrQhgqNGjSJMqXcq0qdOnUKN2DAgAOw=="

/***/ }),
/* 588 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhyAAOAKEAAAAAAKrI8e/4/wAAACH5BAEKAAMALAAAAADIAA4AQAJcnI+py+0Po5y02ouz3hp4DobiSJbmiabqyrapAMfyTNf2jef6zvf+DwziXMSi8YhMKpeRgPMJjUqn1Kr1is1qt9yu92tlisfksvmMTpM8bLX7vQHA5/S6/Y5/FwAAOw=="

/***/ }),
/* 589 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlh6AMBAIcAAID/gLfI1+Pr9QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAADoAwEAAAg6AAMIAECwoMGDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypUuEAgIEBAA7"

/***/ }),
/* 590 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAACRIkChNli1TnjNZpjhgrz9otx1m9S9kzy9l0yxm2DBiyDFq2zhu3D5z2z913SRq8ixx7jRy6D5++URvwEJt1Ep1yE970Eh630574UD/QFOA1lOE3VWF3liH30+K9k+J/VGD4VeH4FaE6VmK4l+L4F+M4WCM5GWP62mR42iU5WuT62+W7G2Z5mec+2ma/2ic+XGa536f7oKg54Wu/42r8Iiu/5a076G+8KK9/6W//6rE7wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAABkALAAAAAAQABAAAAhIADMIHEiwoMGDCDPASGiQBQmGBFPgeAgxgwkcNShUHGHjRQuNDEHQaAEhwQCGF2CUBADRAYgELCEyoBAT4oKaEBNU3MmzJ8GAADs="

/***/ }),
/* 591 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAACRIkChNli1TnjNZpjhgrz9otx1m9S9kzy9l0yxm2DBiyDFq2zhu3D5z2z913SRq8ixx7jRy6D5++URvwEJt1Ep1yE970Eh630574UD/QFOA1lOE3VWF3liH30+K9k+J/VGD4VeH4FaE6VmK4l+L4F+M4WCM5GWP62mR42iU5WuT62+W7G2Z5mec+2ma/2ic+XGa536f7oKg54Wu/42r8Iiu/5a076G+8KK9/6W//6rE7wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAABkALAAAAAAQABAAAAhMADMIHEiwoMGDCAuGSFiQhAaGA0vksAAxQ4ccLipA5JBjxocJDDfgqPFCQgGIDVp4gECg4oEIDwZUzKDAgICZGRAEwJkBAM+fQA0GBAA7"

/***/ }),
/* 592 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAGdnZ3h4eED/QIeHh4uLi46Ojo+Pj5KSkpSUlJmZmaGhoaenp6ioqKqqqrGxsbW1tbe3t7m5ucnJycvLy9HR0dvb2wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAIALAAAAAAQABAAAAhIAAUIHEiwoMGDCAVASGjwAQOGBB1UeAhRQIMKEwpUXEAhQgSNDBVIiHBgQACGCSCUBAARgYIBLCEaKBATIoGaEAdU3MmzJ8GAADs="

/***/ }),
/* 593 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAGdnZ2xsbHJycnh4eH9/f0D/QIODg4WFhYaGhouLi42NjY6OjpKSkpOTk5mZmZ6enp+fn6GhoaOjo6SkpKioqKmpqbi4uLm5ucvLy9vb293d3QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAUALAAAAAAQABAAAAhMAAsIHEiwoMGDCAtOSFiQwgOGAytocACxwAQNFhpAlKABQwUFDCNkwHABAgKIDS5QYECg4oEGCwZULGAggYCZBRAEwFkAAM+fQA0GBAA7"

/***/ }),
/* 594 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlh0AcKAIcAAHas8sPa+cre+tDj/Nbo/d3s/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAADQBwoAAAj/AAsIHEiwoMGDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypcuXMGPKnEmzps2bOHPq3Mmzp8+XBIIKHUq0qNGjSJMqXcq0qdOnUKNKnUq1qtWrWLNq3cq1q9evYMOKHUu2rNmzaNOqXSsUAICgbuG+JRCXrd27ePPq3cu3r9+/gAMLHky4sGGuAxIrXsy4sePHkCNLnky5suXLmDNr3sy5s+fPoEOLHk26tOnTqFOrXs26tevXsGPLnq3YrYEBtnEDuJ2btu/fwIMLH068uPHjyJMrX868ufPRAqJLn069uvXr2LNr3869u/fv4MOL/x9Pvrz58+jTq1/Pvr379/Djy59Pv779+/jz698/3YCB6P4B+J8AAfJn4IEIJqjgggw26OCDEEYo4YQUVmjhegFkqOGGHHbo4YcghijiiCSWaOKJKKao4oostujiizDGKOOMNNZo44045qjjjjz26OOPQAYp5JBEFmnkkUgmqeSSTDbp5JNQRinllFRWaeWVWGap5ZZcdunll2CGKeaYZJZp5plopqnmmmy26eabcMYp55x01mnnnXjmqeeefPbp55+ABirooIQWauihiCaq6KKMNuroo5BGKumklFZq6aWYZqrpppx26umnoIYq6qiklmrqqaimquqqrLbq6quwxgOKZUAAOw=="

/***/ }),
/* 595 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAKAIcAAMAAAP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAKAAoAAAgdAAEIFBigYMGBAAwaHKhwYcKGByFKnEixosWJAQEAOw=="

/***/ }),
/* 596 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAED/QI6Pj66zua+0urK3vLS5vbi7v7u+wby/wsHDxcLExsbHyMrLzMzNzcvP1c3R1s3R19TU1dTV1tDT2NDU2dLV2tTX29XY3Njb3tvb3Nrc39vd39zd3t3f4eDh4eDh4+Hi4uHi4+Lj5OPk5eTl5eXm5ubm5ubn5+jo6Onp6enp6urq6urr6+vr7Ovs7Ozs7O3t7e/v7/Dw8PLy8vT09PX19fb29gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAAAQABAAAAiKAAEIHEiwoMGDBQMoXMhw4cAANCJKnEgjwEMaAjJqHFDgQMWLAhyIdDDhwoYEHwVCDOngQQUMHUQsSAlgJQQKFjaEKIGiAU2IBC5o+IDiBQwYEn7SMNCBxIoYM6JyUIpgRAoYM2jUoAFCqYKrMmjYGGtCKYMIGTycYOGihQqlFClaVNmw7lyECAMCADs="

/***/ }),
/* 597 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAENZkkRZkkZblEdclUhdlkhelklel0pfl0tgmFZpnV1woWBypGN1pWR2pWZ3p21+qkD/QHaGq46Pj4uZu4yZupCdva6zuZ2nwKOuyK+4z7C50be/1bm/0LrB1bzD1sbIysXJzcrLzMnM0MvP1c3P0cnP3czQ1s3R1tXV1tXY3NXZ3dra29vc3Nzd3s/U4tzf5N7g4d/i5d7h6d/i6eHi4uDi5ubm5ufn6Onp6uvr7Ozt7e3u7urs8O3u8fLz9PLz9vT09PX19fb29vj4+Pn5+fj5+gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAABAALAAAAAAQABAAAAicACEIHEiwoMGDBSUoXMhw4UAJQCJKBDKEiBAgEh4CscCRo4gLEV4EySgQooURKE30SACAgxCSEEyiPFEjQ4AGNzBqtKAiRgofCgR4YKGzJBAQJTDs6ECAwRAURWMCgfFAgAsHBzYIaREVIgkZAwocWFAECI2uQD7wmGAAgQaLNtCGWDGDQoUfOnLgQBsxCJEhQSbCbEhYIcLDEAICADs="

/***/ }),
/* 598 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAED/QFaG5WWV82qZ9XGd9Xei9n2n+Iuq6oSr+Yuw+pC1+5a5/Jq9/Z/A/qLC/8DAwNDg8ODg8ODo8PDw8PDw//D4///4/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAAAQABAAAAhyAAEIHEiwoMGDBQ8oXMhwYQCBBxw0YLBAQQIEBgoQGCDgIYCGIBV6dHChpEmTFSpQGHkh5EIJLE+WTElBAkyBJB88uKBTJ88HEWLKnKmSpUuFNwGQHErTJkufPXfqDIpTpgWVEyREgDAygNevYL8iHBsQADs="

/***/ }),
/* 599 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAsAYcAAJm76KvH7LjP7rrQ7rzS773T77/U8MHV8MLW8MTY8cbZ8cja8snb8svd883e88/f89Dg9NLh9NTi9NXk9dfl9djm9trn9t/o9uTr9vP3+/j7/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABACwBAAhIAAFksGChAoUJEiJAeOAggIABBAoYOIAggYIFDBo42Mixo8ePIEOKHEmypMmTKD1eWMmypcuXMGPKnEmzps2bOHPKxMBTA4CAADs="

/***/ }),
/* 600 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDAABAIcAAJm76N/o9vj7/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAMAAEAAAgMAAEICECwIEEBAAICADs="

/***/ }),
/* 601 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAEsCAMAAAA8ZYmdAAAAB3RJTUUH2AsHFCMEelWFngAAAAlwSFlzAAAewgAAHsIBbtB1PgAAAARnQU1BAACxjwv8YQUAAAAPUExURY6kwePp7c7Z58zY5+bq7TZNJ7MAAAAoSURBVHjaY2AAAxYQYGAGgVGSBJIJBEbJUXKUHCVHySFGMoIApAIEAJi/DKmCWNPhAAAAAElFTkSuQmCC"

/***/ }),
/* 602 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAEsCAMAAADXUjKeAAAAB3RJTUUH2AsHFCMH41zUJAAAAAlwSFlzAAAewQAAHsEBw2lUUwAAAARnQU1BAACxjwv8YQUAAAASUExURfDw8IigvqO0yurt7czZ6Obp7R8WhkIAAAABdFJOUwBA5thmAAAALElEQVR42u3WURUAIAzDwHZj/i3TPWSQ/JyFSN7kmiTPSQDwPQ0AEKqT3ixc2QQYefSBx54AAAAASUVORK5CYII="

/***/ }),
/* 603 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAEsCAMAAADXUjKeAAAALHRFWHRDcmVhdGlvbiBUaW1lAFdlZCAyNSBBcHIgMjAwNyAwMjo0NDoxNiAtMDgwMKcuQjMAAAAHdElNRQfYCwcUIwaUW+SyAAAACXBIWXMAAB7BAAAewQHDaVRTAAAABGdBTUEAALGPC/xhBQAAABJQTFRF8PDwiKC+6u3to7TKzNno5untLuyqiAAAAAF0Uk5TAEDm2GYAAAAsSURBVHja7dbBEQAgDITASzT9tyyOZQifbYHULRlalU0jIkItIt/TxB68WTi/0hfjs9KDYwAAAABJRU5ErkJggg=="

/***/ }),
/* 604 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAFCAMAAABGpP0dAAAAB3RJTUUH2AsHFCEUVdT3eAAAAAlwSFlzAAAewgAAHsIBbtB1PgAAAARnQU1BAACxjwv8YQUAAAAJUExURY6kwePp7c3Z6J/ECzwAAAASSURBVHjaY2BgZIICRgYGMjgAC64AWxzNSM4AAAAASUVORK5CYII="

/***/ }),
/* 605 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAuAIcAANnn+OTt9+bu9+nw+Ovx+O7z+PD0+fP2+fX3+fj5+vr6+gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABAC4AAAgYABUoSIDggIECBAYICACgocOHECNKlBgQADs="

/***/ }),
/* 606 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBQAjAIcAAENDRUD/QNHR0ezs7AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAFACMAAAhEAAMIDCBgoICCBAcUFDBAIcOGBxs6lBgR4sOJFilerIixY0UAEQGAFCBy5ACRHzmq3MhSo8uMMD1uTKhQIEOEBHESDAgAOw=="

/***/ }),
/* 607 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBQAjAIcAAENDRUD/QNHR0ezs7AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAFACMAAAhFAAUEGBhAgMCBAgYcTKiw4ICHBh8qZDhRYkSIFC9WxGgxo0cAGAGANCgSAMmRAkBuXKmxpceOMDnKZMlQYMKFBwsSDBAQADs="

/***/ }),
/* 608 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');

Tine.widgets.grid.attachmentRenderer = function (value, metadata, record) {
  var _ = window.lodash,
      result = '';

  if (_.isArray(value) && value.length) {
    result = '<div class="action_attach tine-grid-row-action-icon" />';
  }

  return result;
};

/***/ }),
/* 609 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');

Tine.widgets.grid.imageRenderer = function (value, metadata, record) {
  var _ = window.lodash,
      result = '',
      style = String(value).match(/icon-set/) ? 'background-image: url(' + value + ') !important;' : '';

  if (value) {
    result = '<div class="action_image tine-grid-row-action-icon" style="' + style + '" ext:qtip="' + Ext.util.Format.htmlEncode('<div style="width:300px; height:300px;"><img src="' + String(value).replace(/width=\d+/, 'width=290').replace(/height=\d+/, 'height=300') + '" /></div>') + '"/>';
  }

  return result;
};

/***/ }),
/* 610 */
/***/ (function(module, exports, __webpack_require__) {

// 7.1.13 ToObject(argument)
var defined = __webpack_require__(379);
module.exports = function (it) {
  return Object(defined(it));
};


/***/ }),
/* 611 */
/***/ (function(module, exports, __webpack_require__) {

var has = __webpack_require__(171);
var toIObject = __webpack_require__(172);
var arrayIndexOf = __webpack_require__(1164)(false);
var IE_PROTO = __webpack_require__(401)('IE_PROTO');

module.exports = function (object, names) {
  var O = toIObject(object);
  var i = 0;
  var result = [];
  var key;
  for (key in O) if (key != IE_PROTO) has(O, key) && result.push(key);
  // Don't enum bug & hidden keys
  while (names.length > i) if (has(O, key = names[i++])) {
    ~arrayIndexOf(result, key) || result.push(key);
  }
  return result;
};


/***/ }),
/* 612 */
/***/ (function(module, exports, __webpack_require__) {

// 7.1.15 ToLength
var toInteger = __webpack_require__(400);
var min = Math.min;
module.exports = function (it) {
  return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
};


/***/ }),
/* 613 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = !__webpack_require__(167) && !__webpack_require__(219)(function () {
  return Object.defineProperty(__webpack_require__(404)('div'), 'a', { get: function () { return 7; } }).a != 7;
});


/***/ }),
/* 614 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(173);


/***/ }),
/* 615 */
/***/ (function(module, exports, __webpack_require__) {

exports.f = __webpack_require__(126);


/***/ }),
/* 616 */
/***/ (function(module, exports) {

exports.f = Object.getOwnPropertySymbols;


/***/ }),
/* 617 */
/***/ (function(module, exports, __webpack_require__) {

// 7.2.2 IsArray(argument)
var cof = __webpack_require__(237);
module.exports = Array.isArray || function isArray(arg) {
  return cof(arg) == 'Array';
};


/***/ }),
/* 618 */
/***/ (function(module, exports, __webpack_require__) {

// 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
var anObject = __webpack_require__(166);
var dPs = __webpack_require__(1174);
var enumBugKeys = __webpack_require__(403);
var IE_PROTO = __webpack_require__(401)('IE_PROTO');
var Empty = function () { /* empty */ };
var PROTOTYPE = 'prototype';

// Create object with fake `null` prototype: use iframe Object with cleared prototype
var createDict = function () {
  // Thrash, waste and sodomy: IE GC bug
  var iframe = __webpack_require__(404)('iframe');
  var i = enumBugKeys.length;
  var lt = '<';
  var gt = '>';
  var iframeDocument;
  iframe.style.display = 'none';
  __webpack_require__(619).appendChild(iframe);
  iframe.src = 'javascript:'; // eslint-disable-line no-script-url
  // createDict = iframe.contentWindow.Object;
  // html.removeChild(iframe);
  iframeDocument = iframe.contentWindow.document;
  iframeDocument.open();
  iframeDocument.write(lt + 'script' + gt + 'document.F=Object' + lt + '/script' + gt);
  iframeDocument.close();
  createDict = iframeDocument.F;
  while (i--) delete createDict[PROTOTYPE][enumBugKeys[i]];
  return createDict();
};

module.exports = Object.create || function create(O, Properties) {
  var result;
  if (O !== null) {
    Empty[PROTOTYPE] = anObject(O);
    result = new Empty();
    Empty[PROTOTYPE] = null;
    // add "__proto__" for Object.getPrototypeOf polyfill
    result[IE_PROTO] = O;
  } else result = createDict();
  return Properties === undefined ? result : dPs(result, Properties);
};


/***/ }),
/* 619 */
/***/ (function(module, exports, __webpack_require__) {

var document = __webpack_require__(122).document;
module.exports = document && document.documentElement;


/***/ }),
/* 620 */
/***/ (function(module, exports, __webpack_require__) {

// 19.1.2.7 / 15.2.3.4 Object.getOwnPropertyNames(O)
var $keys = __webpack_require__(611);
var hiddenKeys = __webpack_require__(403).concat('length', 'prototype');

exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
  return $keys(O, hiddenKeys);
};


/***/ }),
/* 621 */
/***/ (function(module, exports) {



/***/ }),
/* 622 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1179);

/***/ }),
/* 623 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var LIBRARY = __webpack_require__(238);
var $export = __webpack_require__(132);
var redefine = __webpack_require__(614);
var hide = __webpack_require__(173);
var Iterators = __webpack_require__(239);
var $iterCreate = __webpack_require__(1182);
var setToStringTag = __webpack_require__(384);
var getPrototypeOf = __webpack_require__(1183);
var ITERATOR = __webpack_require__(126)('iterator');
var BUGGY = !([].keys && 'next' in [].keys()); // Safari has buggy iterators w/o `next`
var FF_ITERATOR = '@@iterator';
var KEYS = 'keys';
var VALUES = 'values';

var returnThis = function () { return this; };

module.exports = function (Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED) {
  $iterCreate(Constructor, NAME, next);
  var getMethod = function (kind) {
    if (!BUGGY && kind in proto) return proto[kind];
    switch (kind) {
      case KEYS: return function keys() { return new Constructor(this, kind); };
      case VALUES: return function values() { return new Constructor(this, kind); };
    } return function entries() { return new Constructor(this, kind); };
  };
  var TAG = NAME + ' Iterator';
  var DEF_VALUES = DEFAULT == VALUES;
  var VALUES_BUG = false;
  var proto = Base.prototype;
  var $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT];
  var $default = $native || getMethod(DEFAULT);
  var $entries = DEFAULT ? !DEF_VALUES ? $default : getMethod('entries') : undefined;
  var $anyNative = NAME == 'Array' ? proto.entries || $native : $native;
  var methods, key, IteratorPrototype;
  // Fix native
  if ($anyNative) {
    IteratorPrototype = getPrototypeOf($anyNative.call(new Base()));
    if (IteratorPrototype !== Object.prototype && IteratorPrototype.next) {
      // Set @@toStringTag to native iterators
      setToStringTag(IteratorPrototype, TAG, true);
      // fix for some old engines
      if (!LIBRARY && typeof IteratorPrototype[ITERATOR] != 'function') hide(IteratorPrototype, ITERATOR, returnThis);
    }
  }
  // fix Array#{values, @@iterator}.name in V8 / FF
  if (DEF_VALUES && $native && $native.name !== VALUES) {
    VALUES_BUG = true;
    $default = function values() { return $native.call(this); };
  }
  // Define iterator
  if ((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])) {
    hide(proto, ITERATOR, $default);
  }
  // Plug for library
  Iterators[NAME] = $default;
  Iterators[TAG] = returnThis;
  if (DEFAULT) {
    methods = {
      values: DEF_VALUES ? $default : getMethod(VALUES),
      keys: IS_SET ? $default : getMethod(KEYS),
      entries: $entries
    };
    if (FORCED) for (key in methods) {
      if (!(key in proto)) redefine(proto, key, methods[key]);
    } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
  }
  return methods;
};


/***/ }),
/* 624 */
/***/ (function(module, exports, __webpack_require__) {

// getting tag from 19.1.3.6 Object.prototype.toString()
var cof = __webpack_require__(237);
var TAG = __webpack_require__(126)('toStringTag');
// ES3 wrong here
var ARG = cof(function () { return arguments; }()) == 'Arguments';

// fallback for IE11 Script Access Denied error
var tryGet = function (it, key) {
  try {
    return it[key];
  } catch (e) { /* empty */ }
};

module.exports = function (it) {
  var O, T, B;
  return it === undefined ? 'Undefined' : it === null ? 'Null'
    // @@toStringTag case
    : typeof (T = tryGet(O = Object(it), TAG)) == 'string' ? T
    // builtinTag case
    : ARG ? cof(O)
    // ES3 arguments fallback
    : (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;
};


/***/ }),
/* 625 */
/***/ (function(module, exports, __webpack_require__) {

// 7.3.20 SpeciesConstructor(O, defaultConstructor)
var anObject = __webpack_require__(166);
var aFunction = __webpack_require__(382);
var SPECIES = __webpack_require__(126)('species');
module.exports = function (O, D) {
  var C = anObject(O).constructor;
  var S;
  return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S);
};


/***/ }),
/* 626 */
/***/ (function(module, exports, __webpack_require__) {

var ctx = __webpack_require__(381);
var invoke = __webpack_require__(1194);
var html = __webpack_require__(619);
var cel = __webpack_require__(404);
var global = __webpack_require__(122);
var process = global.process;
var setTask = global.setImmediate;
var clearTask = global.clearImmediate;
var MessageChannel = global.MessageChannel;
var Dispatch = global.Dispatch;
var counter = 0;
var queue = {};
var ONREADYSTATECHANGE = 'onreadystatechange';
var defer, channel, port;
var run = function () {
  var id = +this;
  // eslint-disable-next-line no-prototype-builtins
  if (queue.hasOwnProperty(id)) {
    var fn = queue[id];
    delete queue[id];
    fn();
  }
};
var listener = function (event) {
  run.call(event.data);
};
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
if (!setTask || !clearTask) {
  setTask = function setImmediate(fn) {
    var args = [];
    var i = 1;
    while (arguments.length > i) args.push(arguments[i++]);
    queue[++counter] = function () {
      // eslint-disable-next-line no-new-func
      invoke(typeof fn == 'function' ? fn : Function(fn), args);
    };
    defer(counter);
    return counter;
  };
  clearTask = function clearImmediate(id) {
    delete queue[id];
  };
  // Node.js 0.8-
  if (__webpack_require__(237)(process) == 'process') {
    defer = function (id) {
      process.nextTick(ctx(run, id, 1));
    };
  // Sphere (JS game engine) Dispatch API
  } else if (Dispatch && Dispatch.now) {
    defer = function (id) {
      Dispatch.now(ctx(run, id, 1));
    };
  // Browsers with MessageChannel, includes WebWorkers
  } else if (MessageChannel) {
    channel = new MessageChannel();
    port = channel.port2;
    channel.port1.onmessage = listener;
    defer = ctx(port.postMessage, port, 1);
  // Browsers with postMessage, skip WebWorkers
  // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
  } else if (global.addEventListener && typeof postMessage == 'function' && !global.importScripts) {
    defer = function (id) {
      global.postMessage(id + '', '*');
    };
    global.addEventListener('message', listener, false);
  // IE8-
  } else if (ONREADYSTATECHANGE in cel('script')) {
    defer = function (id) {
      html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function () {
        html.removeChild(this);
        run.call(id);
      };
    };
  // Rest old browsers
  } else {
    defer = function (id) {
      setTimeout(ctx(run, id, 1), 0);
    };
  }
}
module.exports = {
  set: setTask,
  clear: clearTask
};


/***/ }),
/* 627 */
/***/ (function(module, exports) {

module.exports = function (exec) {
  try {
    return { e: false, v: exec() };
  } catch (e) {
    return { e: true, v: e };
  }
};


/***/ }),
/* 628 */
/***/ (function(module, exports, __webpack_require__) {

var anObject = __webpack_require__(166);
var isObject = __webpack_require__(174);
var newPromiseCapability = __webpack_require__(407);

module.exports = function (C, x) {
  anObject(C);
  if (isObject(x) && x.constructor === C) return x;
  var promiseCapability = newPromiseCapability.f(C);
  var resolve = promiseCapability.resolve;
  resolve(x);
  return promiseCapability.promise;
};


/***/ }),
/* 629 */
/***/ (function(module, exports) {

module.exports = '\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003' +
  '\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';


/***/ }),
/* 630 */
/***/ (function(module, exports) {

/**
 * Global Names
 */

var globals = /\b(Array|Date|Object|Math|JSON)\b/g;

/**
 * Return immediate identifiers parsed from `str`.
 *
 * @param {String} str
 * @param {String|Function} map function or prefix
 * @return {Array}
 * @api public
 */

module.exports = function(str, fn){
  var p = unique(props(str));
  if (fn && 'string' == typeof fn) fn = prefixed(fn);
  if (fn) return map(str, p, fn);
  return p;
};

/**
 * Return immediate identifiers in `str`.
 *
 * @param {String} str
 * @return {Array}
 * @api private
 */

function props(str) {
  return str
    .replace(/\.\w+|\w+ *\(|"[^"]*"|'[^']*'|\/([^/]+)\//g, '')
    .replace(globals, '')
    .match(/[a-zA-Z_]\w*/g)
    || [];
}

/**
 * Return `str` with `props` mapped with `fn`.
 *
 * @param {String} str
 * @param {Array} props
 * @param {Function} fn
 * @return {String}
 * @api private
 */

function map(str, props, fn) {
  var re = /\.\w+|\w+ *\(|"[^"]*"|'[^']*'|\/([^/]+)\/|[a-zA-Z_]\w*/g;
  return str.replace(re, function(_){
    if ('(' == _[_.length - 1]) return fn(_);
    if (!~props.indexOf(_)) return _;
    return fn(_);
  });
}

/**
 * Return unique array.
 *
 * @param {Array} arr
 * @return {Array}
 * @api private
 */

function unique(arr) {
  var ret = [];

  for (var i = 0; i < arr.length; i++) {
    if (~ret.indexOf(arr[i])) continue;
    ret.push(arr[i]);
  }

  return ret;
}

/**
 * Map with prefix `str`.
 */

function prefixed(str) {
  return function(_){
    return str + _;
  };
}


/***/ }),
/* 631 */
/***/ (function(module, exports) {

/* global Tine.Tinebase.Model.ImportExportDefinition */
Ext.ns('Tine.Tinebase.Model');
Tine.Tinebase.Model.ImportExportDefinitionMixin = {
  statics: {
    /**
     * get definition by id
     * 
     * @param {String|Tine.Tinebase.Application} app
     * @param {String} id
     * @return {Tine.Tinebase.Model.ImportExportDefinition}
     */
    get: function get(app, id) {
      app = _.isString(app) ? Tine.Tinebase.appMgr.get(app) : app;

      const allDefinitions = _.get(app.getRegistry().get('exportDefinitions'), 'results', []);

      const definition = _.find(allDefinitions, {
        id: id
      });

      return Tine.Tinebase.data.Record.setFromJson(definition, Tine.Tinebase.Model.ImportExportDefinition);
    }
  },

  /**
   * check if defined options are missing
   * 
   * @return {Boolean}
   */
  optionsMissing: function optionsMissing(options) {
    return _.reduce(_.get(this, 'data.plugin_options_definition', {}), (result, optionDef, name) => {
      const value = _.get(options, name, _.get(this, 'data.plugin_options_json.' + name));

      const allowEmpty = _.get(optionDef, 'allowEmpty', false);

      return result || !value && !allowEmpty;
    }, false);
  }
};

/***/ }),
/* 632 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2020 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.file');
/**
 * @TODO: what if user has no download right?
 *          - device might not have download/local grant (concept in the pipe) -> can be handled by downloadPlugin
 *          - user has no right for particular content (dest mode) -> needs to be handled by calling class
 *              -> have a flag for this? systemOnly?
 */

Tine.Tinebase.widgets.file.SelectionDialog = Ext.extend(Tine.Tinebase.dialog.Dialog, {
  /**
   * @cfg {String} mode one of source|target
   */
  mode: 'source',

  /**
   * @cfg {String} locationTypesEnabled list of enabled plugins
   */
  locationTypesEnabled: 'fm_node,local',

  /**
   * @cfg {Boolean} allowMultiple
   * allow to select multiple fiels at once (source mode only)
   */
  allowMultiple: true,

  /**
   * @cfg {String|RegExp}
   * A constraint allows to alter the selection behaviour of the picker, for example only allow to select files.
   * By default, file and folder are allowed to be selected, the concrete implementation needs to define it's purpose
   */
  constraint: null,

  /**
   * @cfg {String} initialPath
   * initial filemanager path
   */
  initialPath: null,

  /**
   * @cfg {String} fileName
   * @property {String} fileName
   * (initial) fileName
   */
  fileName: null,

  /**
   * @cfg {Object} pluginConfig
   * config to pass to specific plugin
   * {<pluginName>: {...}}
   */
  pluginConfig: null,

  /**
   * @cfg {String} windowTitle
   * translated window title
   */
  windowTitle: null,
  // private
  windowNamePrefix: 'Tinebase.widgets.file.SelectionDialog',
  windowWidth: 1024,
  windowHeight: 500,
  layout: 'border',
  border: false,
  initComponent: function initComponent() {
    this.locationPlugins = [];
    this.locationTypesEnabled = _.map(_.split(this.locationTypesEnabled, ','), _.trim);
    this.allowMultiple = this.mode === 'source' ? this.allowMultiple : false;

    const localIdx = _.indexOf(this.locationTypesEnabled, 'local');

    if (localIdx >= 0) {
      this.locationTypesEnabled[localIdx] = _.indexOf(['source', 'src'], this.mode) >= 0 ? 'upload' : 'download';
    } // init locationType plugins


    this.locationTypesEnabled = _.filter(this.locationTypesEnabled, type => {
      if (!Tine.Tinebase.widgets.file.LocationTypePluginFactory.isRegistered(type)) {
        Tine.log.warn("no LocationTypePlugin for \"".concat(type, "\" registered"));
        return false;
      }

      Tine.Tinebase.widgets.file.LocationTypePluginFactory.create(type, _.get(this.pluginConfig, type, {})).then(plugin => {
        this.addLocationPlugin(plugin);
      });
      return true;
    });
    this.initLayout();
    this.windowTitle = this.windowTitle || (this.constraint === 'file' ? this.allowMultiple ? i18n._('Select files') : i18n._('Select file') : this.constraint === 'folder' ? this.allowMultiple ? i18n._('Select folders') : i18n._('Select folder') : this.allowMultiple ? i18n._('Select items') : i18n._('Select item'));
    this.window.setTitle(this.windowTitle);
    this.stateId = 'widgets.file.SelectionDialog.defaultLocation';
    Tine.Tinebase.widgets.file.SelectionDialog.superclass.initComponent.call(this);
    this.defaultLocationType = _.indexOf(this.locationTypesEnabled, this.defaultLocationType) >= 0 ? this.defaultLocationType : this.locationTypesEnabled[0];
  },
  getEventData: function getEventData() {
    const fileList = this.activePlace.getFileList();

    _.each(fileList, file => {
      _.defaults(file, {
        mode: this.mode,
        type: this.activePlace.locationType,
        file_name: this.fileName
      });
    });

    return this.allowMultiple ? fileList : _.get(fileList, '[0]');
  },
  onButtonApply: async function onButtonApply() {
    if ((await this.activePlace.validateSelection()) === false) {
      return;
    }

    this.saveState();
    return Tine.Tinebase.widgets.file.SelectionDialog.superclass.onButtonApply.apply(this, arguments);
  },
  // note, locationPlugins are added async!
  addLocationPlugin: function addLocationPlugin(locationPlugin) {
    this.locationPlugins.push(locationPlugin);
    locationPlugin.treeNode = new Ext.tree.TreeNode({
      text: locationPlugin.name,
      iconCls: locationPlugin.iconCls
    });
    locationPlugin.index = this.locationTypesEnabled.indexOf(locationPlugin.plugin);
    let nodeInserted = false;

    _.each(this.locationPlugins, p => {
      if (p.index > locationPlugin.index) {
        this.getPluginSelectionTree().getRootNode().insertBefore(locationPlugin.treeNode, p.treeNode);
        nodeInserted = true;
      }
    });

    if (!nodeInserted) {
      this.getPluginSelectionTree().getRootNode().appendChild(locationPlugin.treeNode);
    }

    if (locationPlugin.locationType === this.defaultLocationType) {
      locationPlugin.treeNode.select();
    }
  },
  onTreeSelectionChange: async function onTreeSelectionChange(sm, node) {
    // this.ensureSelected(node);
    const locationPlugin = _.find(this.locationPlugins, {
      treeNode: node
    });

    locationPlugin.manageButtonApply(this.buttonApply);
    const async = await __webpack_require__.e(/* import() | Tinebase/js/async */ 37).then(__webpack_require__.bind(null, 2657));
    await async.map(['pluginPanel', 'targetForm', 'optionsForm'], async area => {
      const cardPanel = _.get(this, area);

      const pluginArea = await locationPlugin.getSelectionDialogArea(area, this);

      if (pluginArea && !pluginArea.disabled) {
        if (cardPanel.items.indexOf(pluginArea) < 0) {
          _.get(this, area).add(pluginArea);
        }

        cardPanel.layout.setActiveItem(pluginArea.id);
        cardPanel.show();

        if (_.indexOf(['north', 'south'], cardPanel.region) >= 0) {
          const height = pluginArea.getHeight();
          this[area].setHeight(height);
          cardPanel.setHeight(height);
        }

        cardPanel.doLayout();
      } else {
        cardPanel.hide();
      }
    }); // manage pluginSelection

    if (locationPlugin.locationType === 'fm_node') {
      locationPlugin.pluginPanel.westPanel.getPortalColumn().insert(0, this.getPluginSelectionTree());
      this.westPanel.hide();
    } else {
      this.westPanel.show();
      this.westPanel.insert(0, this.getPluginSelectionTree());
    }

    this.activePlace = locationPlugin;
    this.doLayout();
  },
  // // so odd!
  // ensureSelected: function(node) {
  //     if (! node.getUI().rendered) {
  //         return this.ensureSelected.defer(100, this, [node]);
  //     }
  //     const sm = node.getOwnerTree().getSelectionModel();
  //     sm.suspendEvents()
  //     node.select();
  //     sm.resumeEvents();
  // },
  getPluginSelectionTree: function getPluginSelectionTree() {
    if (!this.pluginSelectionTree) {
      this.pluginSelectionTree = Ext.create({
        xtype: 'treepanel',
        border: false,
        title: window.i18n._('Places'),
        baseCls: 'ux-arrowcollapse',
        collapsible: true,
        rootVisible: false,
        root: new Ext.tree.TreeNode({
          expanded: true,
          leaf: false,
          id: 'root'
        })
      });
      this.pluginSelectionTree.getSelectionModel().on('selectionchange', this.onTreeSelectionChange, this);
    }

    return this.pluginSelectionTree;
  },
  initLayout: function initLayout() {
    this.defaults = {
      border: false
    };
    this.items = [{
      ref: 'targetForm',
      region: 'north',
      layout: 'card',
      hidden: this.mode === 'source'
    }, {
      ref: 'westPanel',
      region: 'west',
      width: 150,
      items: this.getPluginSelectionTree()
    }, {
      ref: 'pluginPanel',
      region: 'center',
      layout: 'card'
    }, {
      ref: 'optionsForm',
      region: 'south',
      layout: 'card',
      hidden: true
    }];
  },
  getState: function getState() {
    return {
      defaultLocationType: this.activePlace.locationType
    };
  }
});

Tine.Tinebase.widgets.file.SelectionDialog.openWindow = function (config) {
  const constructor = 'Tine.Tinebase.widgets.file.SelectionDialog';
  const prototype = eval(constructor).prototype; // we might need to jsonDecode first :-(

  const windowId = _.get(config, 'windowId') || _.get(config, 'record.id') || Ext.id();
  return Tine.WindowFactory.getWindow({
    width: prototype.windowWidth,
    height: prototype.windowHeight,
    name: prototype.windowNamePrefix + id,
    contentPanelConstructor: constructor,
    contentPanelConstructorConfig: config
  });
};

/***/ }),
/* 633 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
__webpack_require__(1354);

Ext.ns('Tine.widgets.grid');
/**
 * Picker GridPanel
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.PickerGridPanel
 * @extends     Ext.grid.GridPanel
 * 
 * <p>Picker GridPanel</p>
 * <p><pre>
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.grid.PickerGridPanel
 */

Tine.widgets.grid.PickerGridPanel = Ext.extend(Ext.grid.EditorGridPanel, {
  /**
   * @cfg {Class} editDialogClass (optional)
   * editDialogClass having a static openWindow method
   */
  editDialogClass: null,

  /**
   * @cfg {Object} editDialogConfig (optional)
   */
  editDialogConfig: null,

  /**
   * @cfg {bool}
   * enable bottom toolbar
   */
  enableBbar: true,

  /**
   * @cfg {bool}
   * enable top toolbar (with search combo)
   */
  enableTbar: true,

  /**
   * store to hold records
   * 
   * @type Ext.data.Store
   * @property store
   */
  store: null,

  /**
   * record class
   * @cfg {Tine.Tinebase.data.Record} recordClass
   */
  recordClass: null,

  /**
   * defaults for new records of this.recordClass
   * @cfg {Object} recordClass
   */
  recordDefaults: null,

  /**
   * record class
   * @cfg {Tine.Tinebase.data.Record} recordClass
   */
  searchRecordClass: null,

  /**
   * search combo config
   * @cfg {} searchComboConfig
   */
  searchComboConfig: null,

  /**
   * is the row selected after adding?
   * @type Boolean
   */
  selectRowAfterAdd: true,

  /**
   * is the row highlighted after adding?
   * @type Boolean
   */
  highlightRowAfterAdd: false,

  /**
   * @type Ext.Menu
   * @property contextMenu
   */
  contextMenu: null,

  /**
   * @cfg {Array} contextMenuItems
   * additional items for contextMenu
   */
  contextMenuItems: null,

  /**
   * @cfg {Array} Array of column's config objects where the config options are in
   */
  configColumns: null,

  /**
   * @cfg {Bool} readOnly
   */
  readOnly: false,

  /**
   * @cfg {Bool} allowCreateNew
   * allow to create new records (local mode only atm.!)
   */
  allowCreateNew: false,

  /**
   * config spec for additionalFilters - passed to RecordPicker
   *
   * @type: {object} e.g.
   * additionalFilterConfig: {config: { 'name': 'configName', 'appName': 'myApp'}}
   * additionalFilterConfig: {preference: {'appName': 'myApp', 'name': 'preferenceName}}
   * additionalFilterConfig: {favorite: {'appName': 'myApp', 'id': 'favoriteId', 'name': 'optionallyuseaname'}}
   */
  additionalFilterSpec: null,
  cls: 'x-wdgt-pickergrid',

  /**
   * @private
   */
  initComponent: function initComponent() {
    if (this.disabled) {
      this.disabled = false;
      this.readOnly = true;
    }

    this.contextMenuItems = this.contextMenuItems !== null ? this.contextMenuItems : [];
    this.configColumns = this.configColumns !== null ? this.configColumns : [];
    this.searchComboConfig = this.searchComboConfig || {};
    this.searchComboConfig.additionalFilterSpec = this.additionalFilterSpec;
    this.labelField = this.labelField ? this.labelField : this.recordClass && this.recordClass.getMeta ? this.recordClass.getMeta('titleProperty') : null;
    this.recordName = this.recordName ? this.recordName : this.recordClass && this.recordClass.getRecordName ? this.recordClass.getRecordName() || _('Record') : _('Record');

    if (String(this.labelField).match(/{/)) {
      this.labelField = this.labelField.match(/(?:{{\s*)(\w+)/)[1];
    }

    this.autoExpandColumn = this.autoExpandColumn ? this.autoExpandColumn : this.labelField;
    this.initStore();
    this.initGrid();
    this.initActionsAndToolbars();
    this.on('afterrender', this.onAfterRender, this);
    this.on('rowdblclick', this.onRowDblClick, this);
    Tine.widgets.grid.PickerGridPanel.superclass.initComponent.call(this);
  },
  onAfterRender: function onAfterRender() {
    this.setReadOnly(this.readOnly);
  },
  setReadOnly: function setReadOnly(readOnly) {
    this.readOnly = readOnly;
    var _ = window.lodash;
    var tbar = this.getTopToolbar();

    if (tbar) {
      this.getTopToolbar().items.each(function (item) {
        if (Ext.isFunction(item.setDisabled)) {
          item.setDisabled(readOnly);
        } else if (item) {
          item.disabled = readOnly;
        }
      }, this);
      tbar[readOnly ? 'hide' : 'show']();
    }

    var bbar = this.getBottomToolbar();

    if (bbar) {
      bbar[readOnly ? 'hide' : 'show']();
    }

    if (_.get(this, 'actionRemove.setDisabled')) {
      this.actionRemove.setDisabled(readOnly);
    } // pickerCombos doesn´t show


    this.doLayout();
  },

  /**
   * init store
   * @private
   */
  initStore: function initStore() {
    if (!this.store) {
      this.store = new Ext.data.SimpleStore({
        sortInfo: this.defaultSortInfo || {
          field: this.labelField,
          order: 'DESC'
        },
        fields: this.recordClass
      });
    } // focus+select new record


    this.store.on('add', this.focusAndSelect, this);
    this.store.on('beforeload', this.showLoadMask, this);
    this.store.on('load', this.hideLoadMask, this);
  },
  focusAndSelect: function focusAndSelect(store, records, index) {
    (function () {
      if (this.rendered) {
        if (this.selectRowAfterAdd) {
          this.getView().focusRow(index);
          this.getSelectionModel().selectRow(index);
        } else if (this.highlightRowAfterAdd && records.length === 1) {
          // some eyecandy
          var row = this.getView().getRow(index);
          Ext.fly(row).highlight();
        }
      }
    }).defer(300, this);
  },

  /**
   * init actions and toolbars
   */
  initActionsAndToolbars: function initActionsAndToolbars() {
    this.actionCreate = new Ext.Action({
      text: String.format(i18n._('Create {0}'), this.recordName),
      hidden: !this.recordClass || !this.allowCreateNew,
      scope: this,
      handler: this.onCreate,
      iconCls: 'action_add'
    });
    this.actionRemove = new Ext.Action({
      text: String.format(i18n._('Remove {0}'), this.recordName),
      disabled: true,
      scope: this,
      handler: this.onRemove,
      iconCls: 'action_delete',
      actionUpdater: this.actionRemoveUpdater
    }); // init actions

    this.actionUpdater = new Tine.widgets.ActionUpdater({
      recordClass: this.recordClass,
      evalGrants: this.evalGrants
    });
    this.actionUpdater.addActions([this.actionCreate, this.actionRemove]);
    this.selModel.on('selectionchange', function (sm) {
      this.actionUpdater.updateActions(sm);
    }, this);
    var contextItems = [this.actionCreate, this.actionRemove];
    this.contextMenu = new Ext.menu.Menu({
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-MainContextMenu'
      }],
      items: contextItems.concat(this.contextMenuItems)
    }); // removes temporarily added items

    this.contextMenu.on('hide', function () {
      if (this.contextMenu.hasOwnProperty('tempItems') && this.contextMenu.tempItems.length) {
        Ext.each(this.contextMenu.tempItems, function (item) {
          this.contextMenu.remove(item.itemId);
        }, this);
      }

      this.contextMenu.tempItems = [];
    }, this);

    if (this.enableBbar) {
      this.bbar = new Ext.Toolbar({
        items: [this.actionCreate, this.actionRemove].concat(this.contextMenuItems)
      });
    }

    if (this.enableTbar) {
      this.initTbar();
    }
  },

  /**
   * init top toolbar
   */
  initTbar: function initTbar() {
    this.tbar = new Ext.Toolbar({
      items: [this.getSearchCombo()],
      listeners: {
        scope: this,
        resize: this.onTbarResize
      }
    });
  },
  onTbarResize: function onTbarResize(tbar) {
    if (tbar.items.getCount() == 1) {
      var combo = tbar.items.get(0),
          gridWidth = this.getGridEl().getWidth(),
          offsetWidth = combo.getEl() ? combo.getEl().getLeft() - this.getGridEl().getLeft() : 0;

      if (tbar.items.getCount() == 1) {
        tbar.items.get(0).setWidth(gridWidth - offsetWidth);
      }
    }
  },

  /**
   * init grid (column/selection model, ctx menu, ...)
   */
  initGrid: function initGrid() {
    this.colModel = this.getColumnModel();
    this.selModel = new Ext.grid.RowSelectionModel({
      multiSelect: true
    }); // remove non-plugin config columns

    var nonPluginColumns = [];

    for (var i = 0; i < this.configColumns.length; i++) {
      if (!this.configColumns[i].init || typeof this.configColumns[i].init != 'function') {
        nonPluginColumns.push(this.configColumns[i]);
      }
    }

    for (var i = 0; i < nonPluginColumns.length; i++) {
      this.configColumns.remove(nonPluginColumns[i]);
    }

    this.plugins = this.configColumns;
    this.plugins.push(new Ext.ux.grid.GridViewMenuPlugin({})); // on selectionchange handler

    this.selModel.on('selectionchange', function (sm) {
      var rowCount = sm.getCount();
      this.actionRemove.setDisabled(this.readOnly || rowCount == 0);
    }, this); // on rowcontextmenu handler

    this.on('rowcontextmenu', this.onRowContextMenu.createDelegate(this), this);
    this.viewConfig = {
      autoFill: true,
      forceFit: true
    };
  },

  /**
   * take columns property if defined, otherwise create columns from record class propery
   * @return {}
   */
  getColumnModel: function getColumnModel() {
    var _ = window.lodash,
        me = this;

    if (!this.colModel) {
      if (!this.columns) {
        var labelColumn = {
          id: this.labelField,
          header: this.recordClass.getRecordsName(),
          dataIndex: this.labelField,
          renderer: this.labelRenderer ? this.labelRenderer : function (v, m, r) {
            return Ext.util.Format.htmlEncode(Ext.isFunction(r.getTitle) ? r.getTitle() : v);
          }
        };
        this.columns = [labelColumn];
      } else {
        // convert string cols
        _.each(me.columns, function (col, idx) {
          if (_.isString(col)) {
            var config = Tine.widgets.grid.ColumnManager.get(me.recordClass.getMeta('appName'), me.recordClass.getMeta('modelName'), col, 'editDialog');

            if (config) {
              me.columns[idx] = config;
            }
          }
        });

        _.remove(me.columns, _.isString);
      }

      this.colModel = new Ext.grid.ColumnModel({
        defaults: {
          sortable: false
        },
        columns: this.columns
      });
    }

    return this.colModel;
  },

  /**
   * that's the context menu handler
   * @param {} grid
   * @param {} row
   * @param {} e
   */
  onRowContextMenu: function onRowContextMenu(grid, row, e) {
    e.stopEvent();
    this.fireEvent('beforecontextmenu', grid, row, e);
    var selModel = grid.getSelectionModel();

    if (!selModel.isSelected(row)) {
      selModel.selectRow(row);
    }

    this.contextMenu.showAt(e.getXY());
  },

  /**
   * @return {Tine.Tinebase.widgets.form.RecordPickerComboBox|this.searchComboClass}
   */
  getSearchCombo: function getSearchCombo() {
    if (!this.searchCombo) {
      var recordClass = this.searchRecordClass !== null ? this.searchRecordClass : this.recordClass,
          appName = recordClass.getMeta('appName'); //model = recordClass.getModel();

      this.searchCombo = Tine.widgets.form.RecordPickerManager.get(appName, recordClass, Ext.apply({
        blurOnSelect: true,
        listeners: {
          scope: this,
          select: this.onAddRecordFromCombo
        }
      }, this.searchComboConfig));
    }

    return this.searchCombo;
  },

  /**
   * Is called when a record gets selected in the picker combo
   * 
   * @param {Ext.form.ComboBox} picker
   * @param {Record} recordToAdd
   */
  onAddRecordFromCombo: function onAddRecordFromCombo(picker, recordToAdd) {
    // sometimes there are no record data given
    if (!recordToAdd) {
      return;
    }

    var record = new this.recordClass(Ext.applyIf(recordToAdd.data, this.recordDefaults || {}), recordToAdd.id); // check if already in

    if (!this.store.getById(record.id)) {
      this.store.add([record]);
      this.fireEvent('add', this, [record]);
    }

    picker.reset();
  },
  onCreate: function onCreate() {
    const record = Tine.Tinebase.data.Record.setFromJson(Ext.apply(this.recordClass.getDefaultData(), this.recordDefaults || {}), this.recordClass);
    const editDialogClass = this.editDialogClass || Tine.widgets.dialog.EditDialog.getConstructor(this.recordClass);
    editDialogClass.openWindow(_.assign({
      record: Ext.encode(record.data),
      recordId: record.getId(),
      listeners: {
        update: recordData => {
          const record = Tine.Tinebase.data.Record.setFromJson(recordData, this.recordClass);
          this.store.add(record);
        }
      }
    }, this.editDialogConfig || {}));
  },

  /**
   * remove handler
   * 
   * @param {} button
   * @param {} event
   */
  onRemove: function onRemove(button, event) {
    var selectedRows = this.getSelectionModel().getSelections();

    for (var i = 0; i < selectedRows.length; ++i) {
      this.store.remove(selectedRows[i]);
    }
  },

  /**
   * key down handler
   * @private
   */
  onKeyDown: function onKeyDown(e) {
    // no keys for quickadds etc.
    if (e.getTarget('input') || e.getTarget('textarea')) return;

    switch (e.getKey()) {
      case e.A:
        // select all records
        this.getSelectionModel().selectAll(true);
        e.preventDefault();
        break;

      case e.DELETE:
        // delete selected record(s)
        this.onRemove();
        break;
    }
  },
  showLoadMask: function showLoadMask() {
    var me = this;
    return me.afterIsRendered().then(function () {
      if (!me.loadMask) {
        me.loadMask = new Ext.LoadMask(me.getEl(), {
          msg: String.format(i18n._('Loading {0} ...'), me.recordClass.getRecordsName())
        });
      }

      me.loadMask.show.defer(100, me.loadMask);
    });
  },
  hideLoadMask: function hideLoadMask() {
    if (this.loadMask) {
      this.loadMask.hide.defer(100, this.loadMask);
    }

    return Promise.resolve();
  },
  setValue: function setValue(recordsdata) {
    var me = this,
        selectRowAfterAdd = me.selectRowAfterAdd,
        highlightRowAfterAdd = me.highlightRowAfterAdd;
    me.highlightRowAfterAdd = false;
    me.selectRowAfterAdd = false;
    me.store.clearData();

    _.each(recordsdata, function (recordData) {
      var record = Tine.Tinebase.data.Record.setFromJson(recordData, me.recordClass);
      me.store.addSorted(record);
    });

    (function () {
      me.highlightRowAfterAdd = highlightRowAfterAdd;
      me.selectRowAfterAdd = selectRowAfterAdd;
    }).defer(300, me);
  },
  getValue: function getValue() {
    var me = this,
        data = [];
    Tine.Tinebase.common.assertComparable(data);
    me.store.each(function (record) {
      data.push(record.data);
    });
    return data;
  },

  /* needed for isFormField cycle */
  markInvalid: Ext.form.Field.prototype.markInvalid,
  clearInvalid: Ext.form.Field.prototype.clearInvalid,
  getMessageHandler: Ext.form.Field.prototype.getMessageHandler,
  getName: Ext.form.Field.prototype.getName,
  validate: function validate() {
    return true;
  },
  // NOTE: picker picks independed records - so lets support to open them w.o. restirctions
  // NO: it might also pick / create /edit depended records - how to detect this?
  onRowDblClick: function onRowDblClick(grid, row, col) {
    var me = this,
        editDialogClass = this.editDialogClass || Tine.widgets.dialog.EditDialog.getConstructor(me.recordClass),
        record = me.store.getAt(row);

    if (editDialogClass) {
      editDialogClass.openWindow(_.assign({
        record: record,
        recordId: record.getId(),
        listeners: {
          scope: me,
          'update': function update(updatedRecord) {
            if (!updatedRecord.data) {
              updatedRecord = Tine.Tinebase.data.Record.setFromJson(updatedRecord, me.recordClass);
            }

            var idx = me.store.indexOfId(updatedRecord.id),
                isSelected = me.getSelectionModel().isSelected(idx);
            me.getStore().removeAt(idx);
            me.getStore().insert(idx, [updatedRecord]);

            if (isSelected) {
              me.getSelectionModel().selectRow(idx, true);
            }

            me.fireEvent('update', this, updatedRecord);
          }
        }
      }, this.editDialogConfig || {}));
    }
  }
});
Ext.reg('wdgt.pickergrid', Tine.widgets.grid.PickerGridPanel);

/***/ }),
/* 634 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license      http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author       Michael Spahn <m.spahn@metaways.de>
 * @copyright    Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.form');
/**
 * FileSelectionArea - no upload, just selection here atm.
 *
 * @namespace   Tine.widgets.form
 * @class       Tine.widgets.form.FileSelectionArea
 * @extends     Ext.Button
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.form.FileSelectionArea = Ext.extend(Tine.widgets.form.FileUploadButton, {
  cls: 'tw-FileSelectionArea',
  multiple: true,

  /**
   * init this upload button
   */
  initComponent: function initComponent() {
    this.events = [
    /**
     * @event fileSelected
     * Fires when a file was selected
     * @param {FileList}
     */
    'fileSelected'];
    Tine.widgets.form.FileSelectionArea.superclass.initComponent.call(this);
  },
  // bye bye layout probs.
  doAutoWidth: Ext.emptyFn,

  /**
   * called when a file got selected
   *
   * @param {ux.BrowsePlugin} fileSelector
   * @param {Ext.EventObject} event
   */
  onFileSelect: function onFileSelect(fileSelector, event) {
    this.fileList = fileSelector.getFileList();
    this.fireEvent('fileSelected', this.fileList);
  }
});
Ext.reg('tw.uploadarea', Tine.widgets.form.FileSelectionArea);

/***/ }),
/* 635 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.1.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23FFFFFF;%7D .st1%7Bfill:%23020203;%7D %3C/style%3E %3Cpath class='st0' d='M38.3,21.3c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2c-2.6,1.5-5.5,2.3-8.5,2.3c-3.1,0-5.9-0.8-8.5-2.3 c-2.6-1.5-4.7-3.6-6.2-6.2s-2.3-5.5-2.3-8.5c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2s5.5-2.3,8.5-2.3c3.1,0,5.9,0.8,8.5,2.3 s4.7,3.6,6.2,6.2C37.5,15.3,38.3,18.2,38.3,21.3z'/%3E %3Cpath class='st1' d='M35.8,21.3c0-2.6-0.7-5.1-2-7.3c-1.3-2.2-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3 s-2,4.7-2,7.3s0.7,5.1,2,7.3s3.1,4,5.3,5.3c2.2,1.3,4.7,2,7.3,2s5.1-0.7,7.3-2c2.2-1.3,4-3.1,5.3-5.3C35.2,26.3,35.8,23.9,35.8,21.3 z M38.3,21.3c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2c-2.6,1.5-5.5,2.3-8.5,2.3c-3.1,0-5.9-0.8-8.5-2.3 c-2.6-1.5-4.7-3.6-6.2-6.2s-2.3-5.5-2.3-8.5c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2s5.5-2.3,8.5-2.3c3.1,0,5.9,0.8,8.5,2.3 s4.7,3.6,6.2,6.2C37.5,15.3,38.3,18.2,38.3,21.3z M23.7,11.8 M21.4,17.7c-0.8,0-1.4,0.6-1.4,1.3v9.5c0,0.7,0.6,1.3,1.4,1.3 c0.8,0,1.4-0.6,1.4-1.3V19C22.8,18.3,22.2,17.7,21.4,17.7L21.4,17.7z M21.4,17.7 M19.5,14.4c0-1,0.8-1.9,1.9-1.9s1.9,0.8,1.9,1.9 s-0.8,1.9-1.9,1.9S19.5,15.4,19.5,14.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 636 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.1.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23FFFFFF;%7D .st1%7Bfill:%23020203;%7D %3C/style%3E %3Cpath class='st0' d='M38.3,21.3c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2c-2.6,1.5-5.5,2.3-8.5,2.3c-3.1,0-5.9-0.8-8.5-2.3 c-2.6-1.5-4.7-3.6-6.2-6.2s-2.3-5.5-2.3-8.5c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2s5.5-2.3,8.5-2.3c3.1,0,5.9,0.8,8.5,2.3 s4.7,3.6,6.2,6.2C37.5,15.3,38.3,18.2,38.3,21.3z'/%3E %3Cpath class='st1' d='M35.8,21.3c0-2.6-0.7-5.1-2-7.3c-1.3-2.2-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3 s-2,4.7-2,7.3s0.7,5.1,2,7.3s3.1,4,5.3,5.3c2.2,1.3,4.7,2,7.3,2s5.1-0.7,7.3-2c2.2-1.3,4-3.1,5.3-5.3C35.2,26.3,35.8,23.9,35.8,21.3 z M38.3,21.3c0,3.1-0.8,5.9-2.3,8.5c-1.5,2.6-3.6,4.7-6.2,6.2c-2.6,1.5-5.5,2.3-8.5,2.3c-3.1,0-5.9-0.8-8.5-2.3 c-2.6-1.5-4.7-3.6-6.2-6.2s-2.3-5.5-2.3-8.5c0-3.1,0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2s5.5-2.3,8.5-2.3c3.1,0,5.9,0.8,8.5,2.3 s4.7,3.6,6.2,6.2C37.5,15.3,38.3,18.2,38.3,21.3z M23,26.4v2.9c0,0.2-0.1,0.3-0.2,0.4c-0.1,0.1-0.2,0.2-0.4,0.2h-2.9 c-0.2,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.2-0.2-0.2-0.4v-2.9c0-0.2,0.1-0.3,0.2-0.4c0.1-0.1,0.2-0.2,0.4-0.2h2.9c0.2,0,0.3,0.1,0.4,0.2 C22.9,26.1,23,26.3,23,26.4z M27.6,17.5c0,0.6-0.1,1.1-0.3,1.6s-0.5,0.9-0.8,1.2c-0.4,0.3-0.7,0.6-0.9,0.8c-0.3,0.2-0.6,0.4-1.1,0.6 c-0.4,0.2-0.7,0.4-0.8,0.5c-0.2,0.1-0.3,0.3-0.5,0.4C23,22.9,23,23.1,23,23.3v0.6c0,0.2-0.1,0.3-0.2,0.4c-0.1,0.1-0.2,0.2-0.4,0.2 h-2.9c-0.2,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.2-0.2-0.2-0.4v-1.2c0-0.4,0.1-0.8,0.2-1.2s0.3-0.6,0.4-0.9c0.2-0.2,0.4-0.4,0.7-0.6 c0.3-0.2,0.6-0.4,0.7-0.5s0.5-0.2,0.8-0.4c0.6-0.3,1.1-0.6,1.3-0.8c0.3-0.2,0.4-0.5,0.4-0.9c0-0.5-0.3-0.9-0.8-1.3 c-0.5-0.4-1.1-0.5-1.7-0.5c-0.7,0-1.2,0.2-1.7,0.5c-0.3,0.2-0.8,0.7-1.4,1.5c-0.1,0.1-0.3,0.2-0.4,0.2c-0.1,0-0.2,0-0.3-0.1 l-1.9-1.5c-0.1-0.1-0.2-0.2-0.2-0.4c0-0.2,0-0.3,0.1-0.4c1.5-2.3,3.5-3.4,6.3-3.4c1.5,0,3,0.5,4.3,1.6S27.6,16,27.6,17.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 637 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.0.6, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23FFFFFF;%7D .st1%7Bfill:%23020203;%7D %3C/style%3E %3Cpath class='st0' d='M21,27.9c-1,0-1.9,0.9-1.9,1.9c0,1,0.9,1.9,1.9,1.9s1.9-0.9,1.9-1.9C23,28.7,22.1,27.9,21,27.9L21,27.9z M36.1,33.2c-0.7,1.1-1.8,1.8-3.2,1.8H9c-1.3,0-2.5-0.7-3.1-1.8c-0.7-1.1-0.7-2.5,0-3.6L17.8,8.8C18.6,7.7,19.7,7,21.1,7 c1.3,0,2.5,0.7,3.1,1.8l12,20.8C36.8,30.8,36.8,32.1,36.1,33.2L36.1,33.2z'/%3E %3Cpath class='st1' d='M21,27.9c-1,0-1.9,0.9-1.9,1.9c0,1,0.9,1.9,1.9,1.9s1.9-0.9,1.9-1.9C23,28.7,22.1,27.9,21,27.9L21,27.9z M38.7,34.7c1.2-2.1,1.2-4.5,0-6.6l-12-20.8c-1.1-2-3.2-3.3-5.6-3.3s-4.5,1.2-5.7,3.3L3.3,28c-1.2,2.1-1.2,4.6,0,6.6 C4.5,36.7,6.6,38,9,38h24C35.4,38.1,37.5,36.8,38.7,34.7L38.7,34.7z M36.1,33.2c-0.7,1.1-1.8,1.8-3.2,1.8H9c-1.3,0-2.5-0.7-3.1-1.8 c-0.7-1.1-0.7-2.5,0-3.6L17.8,8.8C18.6,7.7,19.7,7,21.1,7c1.3,0,2.5,0.7,3.1,1.8l12,20.8C36.8,30.8,36.8,32.1,36.1,33.2L36.1,33.2z M20.6,14.5c-0.9,0.3-1.5,1.1-1.5,2.1c0,0.6,0.1,1.2,0.1,1.8c0.1,2.3,0.3,4.6,0.4,6.8c0,0.8,0.6,1.3,1.4,1.3s1.4-0.6,1.4-1.4 c0-0.5,0-0.9,0-1.4c0.1-1.5,0.2-2.9,0.3-4.4c0-1,0.1-1.9,0.2-2.9c0-0.3,0-0.6-0.2-1C22.4,14.7,21.5,14.3,20.6,14.5L20.6,14.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 638 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.9,33.1l-1.8,1.8c-0.3,0.3-0.6,0.4-0.9,0.4c-0.3,0-0.6-0.1-0.9-0.4L21.2,24.8L11.1,34.9c-0.3,0.3-0.6,0.4-0.9,0.4 c-0.3,0-0.6-0.1-0.9-0.4l-1.8-1.8C7.1,32.8,7,32.5,7,32.2c0-0.3,0.1-0.6,0.4-0.9l10.1-10.1L7.4,11.1C7.1,10.8,7,10.5,7,10.2 c0-0.3,0.1-0.6,0.4-0.9l1.8-1.8C9.5,7.1,9.8,7,10.2,7c0.3,0,0.6,0.1,0.9,0.4l10.1,10.1L31.2,7.4C31.5,7.1,31.8,7,32.2,7 c0.3,0,0.6,0.1,0.9,0.4l1.8,1.8c0.3,0.3,0.4,0.6,0.4,0.9c0,0.3-0.1,0.6-0.4,0.9L24.8,21.2l10.1,10.1c0.3,0.3,0.4,0.6,0.4,0.9 C35.3,32.5,35.2,32.8,34.9,33.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 639 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M39.6,7.9c-0.3-0.3-0.7-0.5-1.2-0.5h-9.9V5.6c0-0.5-0.2-0.8-0.5-1.2S27.4,4,27,4H11.6c-0.5,0-1,0.1-1.5,0.3 c-0.5,0.2-1,0.5-1.3,0.8l-5.3,5.3c-0.3,0.3-0.6,0.8-0.8,1.3c-0.2,0.5-0.3,1-0.3,1.5V33c0,0.5,0.2,0.8,0.5,1.2s0.7,0.5,1.2,0.5h9.9 v1.7c0,0.5,0.2,0.8,0.5,1.2S15,38,15.5,38h23c0.5,0,0.8-0.2,1.2-0.5s0.5-0.7,0.5-1.2V9C40.1,8.6,39.9,8.2,39.6,7.9z M5,12.1l5.4-5.4 c0.1-0.1,0.4-0.3,0.7-0.4v6.4H4.6C4.8,12.4,4.9,12.2,5,12.1z M15,13.9c-0.3,0.3-0.6,0.8-0.8,1.3c-0.2,0.5-0.3,1-0.3,1.5v15.8H4.5V15 h7.1c0.5,0,0.8-0.2,1.2-0.5s0.5-0.7,0.5-1.2V6.2h13.1v1.2h-3.3c-0.5,0-1,0.1-1.5,0.3c-0.5,0.2-1,0.5-1.3,0.8L15,13.9z M22.6,9.7v6.4 h-6.4c0.1-0.3,0.2-0.6,0.4-0.7l5.4-5.4C22.1,9.9,22.3,9.8,22.6,9.7z M38,35.8H16V18.3h7.1c0.5,0,0.8-0.2,1.2-0.5s0.5-0.7,0.5-1.2 V9.5H38V35.8z'/%3E %3Cpath d='M26.4,20.7c0.1-0.1,0.3-0.2,0.4-0.2h1.2c0.2,0,0.3,0.1,0.4,0.2s0.2,0.3,0.2,0.4v4.3h4.3c0.2,0,0.3,0.1,0.4,0.2 s0.2,0.3,0.2,0.4v1.2c0,0.2-0.1,0.3-0.2,0.4s-0.3,0.2-0.4,0.2h-4.3V32c0,0.2-0.1,0.3-0.2,0.4s-0.3,0.2-0.4,0.2h-1.2 c-0.2,0-0.3-0.1-0.4-0.2s-0.2-0.3-0.2-0.4v-4.3H22c-0.2,0-0.3-0.1-0.4-0.2s-0.2-0.3-0.2-0.4V26c0-0.2,0.1-0.3,0.2-0.4 s0.3-0.2,0.4-0.2h4.3v-4.3C26.3,20.9,26.3,20.8,26.4,20.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 640 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.3,9.4v8.3c0,0.3-0.1,0.6-0.4,0.8c-0.2,0.2-0.5,0.4-0.8,0.4h-8.3c-0.5,0-0.9-0.2-1.1-0.7c-0.2-0.5-0.1-0.9,0.3-1.3 l2.5-2.5c-1.8-1.7-4-2.5-6.4-2.5c-1.3,0-2.5,0.2-3.7,0.7c-1.2,0.5-2.2,1.2-3,2c-0.8,0.8-1.5,1.9-2,3c-0.5,1.2-0.7,2.4-0.7,3.7 s0.2,2.5,0.7,3.7c0.5,1.2,1.2,2.2,2,3c0.8,0.8,1.9,1.5,3,2c1.2,0.5,2.4,0.7,3.7,0.7c1.5,0,2.8-0.3,4.1-1c1.3-0.6,2.4-1.5,3.3-2.7 c0.1-0.1,0.2-0.2,0.4-0.2c0.2,0,0.3,0.1,0.5,0.2l2.5,2.5c0.1,0.1,0.2,0.2,0.2,0.4s0,0.3-0.1,0.4c-1.3,1.6-3,2.9-4.9,3.8 c-1.9,0.9-3.9,1.3-6,1.3c-1.9,0-3.7-0.4-5.5-1.1s-3.3-1.8-4.5-3c-1.3-1.3-2.3-2.8-3-4.5S7,23.1,7,21.2s0.4-3.7,1.1-5.5 s1.8-3.3,3-4.5s2.8-2.3,4.5-3S19.2,7,21.2,7c1.8,0,3.6,0.3,5.2,1c1.7,0.7,3.2,1.6,4.5,2.9l2.4-2.4c0.4-0.4,0.8-0.5,1.3-0.3 C35.1,8.5,35.3,8.8,35.3,9.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 641 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38.4,7H3.7C3,7,2.5,7.5,2.5,8.2V34c0,0.7,0.5,1.2,1.2,1.2h34.7c0.7,0,1.2-0.5,1.2-1.2V8.2C39.6,7.5,39.1,7,38.4,7z M37.2,9.4v21.3L29.1,25l-7.8,4.9L15.7,19L4.9,27.7V9.4H37.2z M22.2,15.7c0-2.2,1.8-4.1,4.1-4.1s4.1,1.8,4.1,4.1s-1.8,4.1-4.1,4.1 C24,19.8,22.2,18,22.2,15.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 642 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.7,18c0,0.3-0.2,0.5-0.5,0.9l-6.5,6.3l1.5,8.9c0,0.1,0,0.2,0,0.4c0,0.3-0.1,0.5-0.2,0.6c-0.1,0.2-0.3,0.3-0.5,0.3 c-0.2,0-0.5-0.1-0.7-0.2l-8-4.2l-8,4.2c-0.3,0.1-0.5,0.2-0.7,0.2c-0.3,0-0.4-0.1-0.6-0.3c-0.1-0.2-0.2-0.4-0.2-0.6 c0-0.1,0-0.2,0-0.4l1.5-8.9l-6.5-6.3C6.1,18.5,6,18.2,6,18c0-0.4,0.3-0.7,1-0.8l9-1.3l4-8.1C20.2,7.2,20.5,7,20.9,7s0.6,0.2,0.9,0.7 l4,8.1l9,1.3C35.4,17.3,35.7,17.5,35.7,18z'/%3E %3C/svg%3E\""

/***/ }),
/* 643 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.8,10.3L14.1,8l-1.3,1.6l2.7,2.2L16.8,10.3z M29.6,9.6L28.3,8l-2.7,2.2l1.3,1.6L29.6,9.6z M25.1,8.4l-1.3-1.5l-1.5,1.4V4 h-2v4.2l-1.5-1.4l-1.3,1.5l3.9,3.4L25.1,8.4z'/%3E %3Cpath d='M15.6,24.7c-1.5,0.1-2.9,0.7-3.9,1.9H9.8c-0.8,0-1.5-0.2-2-0.6C7.3,25.7,7,25.1,7,24.3c0-3.4,0.6-5.2,1.8-5.2 c0.1,0,0.2,0.1,0.6,0.3s0.9,0.4,1.4,0.6c0.6,0.2,1.2,0.3,1.7,0.3c0.6,0,1.3-0.1,1.9-0.3c-0.1,0.4-0.1,0.7-0.1,0.9 C14.5,22.3,14.9,23.6,15.6,24.7z M31.5,34.2c0,1.2-0.4,2.1-1.1,2.8c-0.7,0.7-1.6,1-2.9,1H14.9c-1.2,0-2.1-0.3-2.9-1 c-0.7-0.7-1.1-1.6-1.1-2.8c0-0.5,0-1,0.1-1.5s0.1-1,0.2-1.6c0.1-0.5,0.2-1.1,0.4-1.5c0.2-0.5,0.4-0.9,0.6-1.4 c0.2-0.5,0.5-0.9,0.9-1.2c0.3-0.3,0.8-0.6,1.2-0.8c0.5-0.2,1-0.3,1.6-0.3c0.1,0,0.3,0.1,0.6,0.3c0.3,0.2,0.7,0.5,1.1,0.7 c0.4,0.2,0.9,0.5,1.5,0.7s1.3,0.3,1.9,0.3s1.3-0.1,1.9-0.3s1.2-0.5,1.5-0.7c0.4-0.2,0.8-0.5,1.1-0.7c0.3-0.2,0.5-0.3,0.6-0.3 c0.6,0,1.2,0.1,1.6,0.3c0.5,0.2,0.9,0.5,1.2,0.8c0.3,0.3,0.6,0.7,0.9,1.2c0.2,0.5,0.5,0.9,0.6,1.4c0.2,0.5,0.3,1,0.4,1.5 s0.2,1.1,0.2,1.6S31.5,33.7,31.5,34.2z M16.3,15.4c0,1-0.4,1.9-1.1,2.6s-1.6,1.1-2.6,1.1S10.7,18.7,10,18c-0.7-0.7-1.1-1.6-1.1-2.6 s0.4-1.9,1.1-2.6c0.7-0.7,1.5-1.1,2.6-1.1s1.9,0.4,2.6,1.1C15.9,13.5,16.3,14.4,16.3,15.4z M26.1,21c0,1.4-0.5,2.6-1.5,3.5 c-1,1-2.2,1.5-3.5,1.5c-1.4,0-2.6-0.5-3.5-1.5c-1-1-1.5-2.2-1.5-3.5s0.5-2.6,1.5-3.5c1-0.9,2.2-1.5,3.5-1.5c1.4,0,2.6,0.5,3.5,1.5 C25.7,18.5,26.1,19.6,26.1,21z M35.4,24.3c0,0.8-0.3,1.3-0.9,1.7c-0.5,0.4-1.2,0.6-2,0.6h-1.9c-1-1.2-2.3-1.9-3.9-1.9 c0.8-1.2,1.2-2.4,1.2-3.7c0-0.3,0-0.6-0.1-0.9c0.6,0.2,1.3,0.3,1.9,0.3c0.5,0,1.2-0.1,1.7-0.3c0.6-0.2,1.1-0.4,1.4-0.6 c0.4-0.2,0.5-0.3,0.6-0.3C34.8,19.2,35.4,20.9,35.4,24.3z M33.6,15.4c0,1-0.4,1.9-1.1,2.6s-1.6,1.1-2.6,1.1c-1,0-1.9-0.4-2.6-1.1 c-0.7-0.7-1.1-1.6-1.1-2.6s0.4-1.9,1.1-2.6c0.7-0.7,1.5-1.1,2.6-1.1c1,0,1.9,0.4,2.6,1.1C33.2,13.5,33.6,14.4,33.6,15.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 644 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.0.6, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.1,20.1c-0.2,0.5-0.2,1-0.2,1.6c0,3,2.4,5.4,5.4,5.4c3,0,5.4-2.4,5.4-5.4s-2.4-5.4-5.4-5.4c-1.4,0-2.7,0.6-3.7,1.5l2.6,3 L16.1,20.1z M16.1,20.1'/%3E %3Cpath d='M41.7,20.8c-0.1-0.1-2.1-2.7-5.7-5.3c-4.7-3.5-9.8-5.3-14.8-5.3c-5,0-10.1,1.8-14.8,5.3c-3.5,2.6-5.6,5.2-5.7,5.3L0,21.7 l0.7,0.9c0.1,0.1,2.1,2.7,5.7,5.3c4.7,3.5,9.8,5.3,14.8,5.3c5,0,10.1-1.8,14.8-5.3c3.5-2.6,5.6-5.2,5.7-5.3l0.7-0.9L41.7,20.8z M21.2,29.8c-4.4,0-8.1-3.6-8.1-8.1c0-0.7,0.1-1.4,0.3-2l-1.8-0.3c-0.2,0.7-0.3,1.5-0.3,2.3c0,2.9,1.2,5.5,3.2,7.3 C12,28,9.8,26.7,8.2,25.6c-2-1.5-3.5-2.9-4.4-3.9c0.9-0.9,2.4-2.4,4.4-3.9c1.6-1.2,3.8-2.5,6.3-3.4l1.2,1.4c1.4-1.3,3.4-2.2,5.5-2.2 c4.4,0,8.1,3.6,8.1,8.1S25.7,29.8,21.2,29.8L21.2,29.8z M34.2,25.6C32.6,26.7,30.5,28,28,29c2-1.8,3.2-4.4,3.2-7.3 c0-2.9-1.2-5.5-3.2-7.3c2.5,0.9,4.7,2.2,6.3,3.4c2,1.5,3.5,2.9,4.4,3.9C37.7,22.6,36.2,24.1,34.2,25.6L34.2,25.6z M34.2,25.6'/%3E %3C/svg%3E\""

/***/ }),
/* 645 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAqCAIAAAD9HKYrAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKxEJbYcpXff5nwl/AV/1s+X48/Pf14L7iJIEyXYFHBPjgwsz0TKUcz5IJhGLc5o9H/LcL//wd0yLESWK5WCoU41EScY5EmozzMqUiiUKSKcUl0v9k4t8s+wM+3zUAsGo+AXuRLahdYwP2SycQWHTA4vcAAPK7b8HUKAgDgGiD4c93/+8//UegJQCAZkmScQAAXkQkLlTKsz/HCAAARKCBKrBBG/TBGCzABhzBBdzBC/xgNoRCJMTCQhBCCmSAHHJgKayCQiiGzbAdKmAv1EAdNMBRaIaTcA4uwlW4Dj1wD/phCJ7BKLyBCQRByAgTYSHaiAFiilgjjggXmYX4IcFIBBKLJCDJiBRRIkuRNUgxUopUIFVIHfI9cgI5h1xGupE7yAAygvyGvEcxlIGyUT3UDLVDuag3GoRGogvQZHQxmo8WoJvQcrQaPYw2oefQq2gP2o8+Q8cwwOgYBzPEbDAuxsNCsTgsCZNjy7EirAyrxhqwVqwDu4n1Y8+xdwQSgUXACTYEd0IgYR5BSFhMWE7YSKggHCQ0EdoJNwkDhFHCJyKTqEu0JroR+cQYYjIxh1hILCPWEo8TLxB7iEPENyQSiUMyJ7mQAkmxpFTSEtJG0m5SI+ksqZs0SBojk8naZGuyBzmULCAryIXkneTD5DPkG+Qh8lsKnWJAcaT4U+IoUspqShnlEOU05QZlmDJBVaOaUt2ooVQRNY9aQq2htlKvUYeoEzR1mjnNgxZJS6WtopXTGmgXaPdpr+h0uhHdlR5Ol9BX0svpR+iX6AP0dwwNhhWDx4hnKBmbGAcYZxl3GK+YTKYZ04sZx1QwNzHrmOeZD5lvVVgqtip8FZHKCpVKlSaVGyovVKmqpqreqgtV81XLVI+pXlN9rkZVM1PjqQnUlqtVqp1Q61MbU2epO6iHqmeob1Q/pH5Z/YkGWcNMw09DpFGgsV/jvMYgC2MZs3gsIWsNq4Z1gTXEJrHN2Xx2KruY/R27iz2qqaE5QzNKM1ezUvOUZj8H45hx+Jx0TgnnKKeX836K3hTvKeIpG6Y0TLkxZVxrqpaXllirSKtRq0frvTau7aedpr1Fu1n7gQ5Bx0onXCdHZ4/OBZ3nU9lT3acKpxZNPTr1ri6qa6UbobtEd79up+6Ynr5egJ5Mb6feeb3n+hx9L/1U/W36p/VHDFgGswwkBtsMzhg8xTVxbzwdL8fb8VFDXcNAQ6VhlWGX4YSRudE8o9VGjUYPjGnGXOMk423GbcajJgYmISZLTepN7ppSTbmmKaY7TDtMx83MzaLN1pk1mz0x1zLnm+eb15vft2BaeFostqi2uGVJsuRaplnutrxuhVo5WaVYVVpds0atna0l1rutu6cRp7lOk06rntZnw7Dxtsm2qbcZsOXYBtuutm22fWFnYhdnt8Wuw+6TvZN9un2N/T0HDYfZDqsdWh1+c7RyFDpWOt6azpzuP33F9JbpL2dYzxDP2DPjthPLKcRpnVOb00dnF2e5c4PziIuJS4LLLpc+Lpsbxt3IveRKdPVxXeF60vWdm7Obwu2o26/uNu5p7ofcn8w0nymeWTNz0MPIQ+BR5dE/C5+VMGvfrH5PQ0+BZ7XnIy9jL5FXrdewt6V3qvdh7xc+9j5yn+M+4zw33jLeWV/MN8C3yLfLT8Nvnl+F30N/I/9k/3r/0QCngCUBZwOJgUGBWwL7+Hp8Ib+OPzrbZfay2e1BjKC5QRVBj4KtguXBrSFoyOyQrSH355jOkc5pDoVQfujW0Adh5mGLw34MJ4WHhVeGP45wiFga0TGXNXfR3ENz30T6RJZE3ptnMU85ry1KNSo+qi5qPNo3ujS6P8YuZlnM1VidWElsSxw5LiquNm5svt/87fOH4p3iC+N7F5gvyF1weaHOwvSFpxapLhIsOpZATIhOOJTwQRAqqBaMJfITdyWOCnnCHcJnIi/RNtGI2ENcKh5O8kgqTXqS7JG8NXkkxTOlLOW5hCepkLxMDUzdmzqeFpp2IG0yPTq9MYOSkZBxQqohTZO2Z+pn5mZ2y6xlhbL+xW6Lty8elQfJa7OQrAVZLQq2QqboVFoo1yoHsmdlV2a/zYnKOZarnivN7cyzytuQN5zvn//tEsIS4ZK2pYZLVy0dWOa9rGo5sjxxedsK4xUFK4ZWBqw8uIq2Km3VT6vtV5eufr0mek1rgV7ByoLBtQFr6wtVCuWFfevc1+1dT1gvWd+1YfqGnRs+FYmKrhTbF5cVf9go3HjlG4dvyr+Z3JS0qavEuWTPZtJm6ebeLZ5bDpaql+aXDm4N2dq0Dd9WtO319kXbL5fNKNu7g7ZDuaO/PLi8ZafJzs07P1SkVPRU+lQ27tLdtWHX+G7R7ht7vPY07NXbW7z3/T7JvttVAVVN1WbVZftJ+7P3P66Jqun4lvttXa1ObXHtxwPSA/0HIw6217nU1R3SPVRSj9Yr60cOxx++/p3vdy0NNg1VjZzG4iNwRHnk6fcJ3/ceDTradox7rOEH0x92HWcdL2pCmvKaRptTmvtbYlu6T8w+0dbq3nr8R9sfD5w0PFl5SvNUyWna6YLTk2fyz4ydlZ19fi753GDborZ752PO32oPb++6EHTh0kX/i+c7vDvOXPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAEZ0FNQQAAsY58+1GTAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAABOSURBVHjadMM5EsQgDADB+f9XbRACXeEGrI/EXdVUFe9ZRWaRmfeIaxAReATuu7lj9lxmrLXPf50L1cnQiQxFROkyaH3QunC2/Tj7198Ak5R3b/RypocAAAAASUVORK5CYII="

/***/ }),
/* 646 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_6.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='20.352941' inkscape:cx='10.821939' inkscape:cy='21.048437' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccs'/%3E %3C/svg%3E\""

/***/ }),
/* 647 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAPcAALW4yPv8/pyiqrTJ4rbL5M3k/8zj/svh/cvi/bvQ6brP6LnN5rbK48vh/Mrg+7rO58nd9sve9cLU6sTV6c/g9MfX6s/e8Mva7LvG06uzvbe+x6arscff+8Xd+cng+sfe+LnO5rjN5bfM5M3f9Mzc7tHh89Pi8rrG07vG0r7J1aSstdLg7tXj8dTi8MDHzrvCybrByKClqr3Cx52hpairrqaprJOUlfz9/tfY2dbX2NXW136t2bq/w5ufoqaqraCkp8XJzMPHysLS3cjY48bW4bK7waOqr6uyt5qgpKeqrKSnqa/Q5LDQ5K/P463M4KvK3rHQ5K/O4srb5sna5bPByrLAybXDzK21urvDyK7Q467O4a3N4N3z/9Xp9MHS3MTV37W+w7S9wqOqrqWqra7R49/0/+H1/9fq9Nrs9eHx+cLKzquxtKKmqNPV1tHT1NDS0+P2/+b3/+P0/N/w9+j5/8vZ3s/c4cnR1MXN0Or6/+n5/uf3/MzZ3cTKzKqtrquvsMvP0MTNz5SWlpOUlP/wV/7vV+3XX/jVJuvVX/HFAO3BAu69AO69AunGP9+qANynANahANakANOhAdakAtOsLtKrLtOeAMyZAMiVANOeAcmWAcaTAtSqML+TKL6UKruQKayRTK6STq+EIqyCIq2DI6uCI7OSXbWTXvHx8fDw8O/v7+7u7u3t7ezs7Orq6ujo6Obm5uXl5eTk5OPj4+Hh4d7e3t3d3dzc3Nvb29ra2tnZ2djY2NfX19bW1tXV1dTU1NPT09LS0tHR0dDQ0M/Pz87Ozs3NzczMzMnJycjIyMfHx8bGxsXFxcLCwrq6urKysq+vr62traurq6mpqaenp6SkpJWVlQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAZgAYAEAI/wABCBxIsKDAHQgTKlzIsKHDhxAjSmzIquKsW9AqVnTWbJZGABFCSri1IWTIDM0kmNwhpaWXWz5atjzSzIvMHSZHljSJUmXIHWWCdrm1JmjQMM26GGXpEqZMKTRtttwBrOqpRpw8kRLViZKhUFWBAUhA9mrWrV2/kk2wY4lbs1q5eg3lNsuOtXDRzl27o4DfvHK/+i3Q9i3WuGnpLrGbqnGqZbWkBQtWLZgxx6kAmNhsQkOtGhhOzAjmgrMJpi2L1FJChUqPYFie7jDtGbRo0qZ30NlNR00tP3XqsAl2hzcd1FJUs3YNW7au56YOLYqEyZKjRIRAPdcFYIH36NOrX//P7n3BjizowVO3jh0Uervl1YtvX37Hgfvy2We/f+B8eunrjeceejsIY+CBCCYozFhrNeggX1BEKOGEFNr14IV8DabhhhruQOGHE9qFyogjpuJLMsgEkwqJIwLAwosvtpACDC+g0AKMLyInxRRWhAFGFVM8JcUOOLIgI402FrlDHkwyqYcdgeDBhx5NMqkjjz4CKeQOq3QZyy3RdNklNcTEIiYAFKRZwS00pJmmAMRU4CZqQtySxFNIECPETW6u2aabcMqZ5g5wFIrGLX8UWqgYxKChKJ124qnnTbZUGh0jkmiSySOKFAJKpbYAMMCol2a6aaegjDrADmS0WqqmnHr/2qpdqr56qqeq7tDBrrbGCsquHbDq6iGYworqrDv0oqx6l0AioLK9MJgAs862x9d71Ar43l1kZWstWX355W12g/mXxbgD2qXgugdKi6GDHoIIooXvPhguh/gSJu+8BbK7rrv1grvvh/QGnGG++MY7sIR23eDwwxBHfAMAAVRs8cUYB6CjkBzvkPHHFnsM8scbcywbi6soQ8stuMByzCosugjjCjKs3DIQK+CI3BA82AxLEEPIhiPNPuOsc5V79OEzIHtUuXPPLP8c9E2qVN3KL8u8UrUr1uzSStWqAFDC2Ba4scwFY5NgQw4WjF0CakO8scwXLRExiA5TD+l22Wen/71222PvEMfgcrSxzByDpyEIDnIMHgfcctMthd143ySmLLdMI+YqzzAjy5kjhD7BLTGEHroKzExgOmov/fCUEcxINaTpo5duOuqqh76DGbyfccsYvPN+BTNnBM/6La7LBLvsO7TiPFyljPJJJYiE4nwrAECgPfTSUx+K9hCgxv301d8E/vjeg78DF+yjXz37XIh/WPTkh3JTLviDN8kmmQiIfy4AIIAA9cc/AQmQAOYiYP/as60DKtCAAtwBByb4wPZMkAMJlM7+FpidbfHig+j6IC+kha5r/Wc6zdIWgdZSQnANBl3lwhaAUshAAv3ihui64S9IOMNqZceE5+qhCqsL1kK2vFCI7YnhCSNBww4SaDLBEMYwiFGMY1ixGMMYhjAmIy0FPCAEImCAGEUAggcoAFxMSGMTorAFJzzhjU7QQhSawISCeRGMYmQAGc3oQr8YAAEO8MAHBumBBiDAAH7ZQRqZsMY2vvEJcZxjHfvlrwQBLGAKWxgUCmYwIyKMQ5lcmLoqaclOQkiTEeKkwe71yXKhMpWUJKWBLlmvUA5MlZhs5YZsuS+7BAQAOw=="

/***/ }),
/* 648 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAPcAAMzMzbW4yKGipKCho/v8/tvc3sbJzrTJ4rbL5M3k/8zj/svh/cvi/bvQ6brP6LnN5rbK48vh/Mrg+7rO58nd9sve9cLU6sTV6c/g9MfX6s7d7664xK+0urO4vs3S2Mff+8Xd+cng+sfe+LnO5rjN5bfM5Mze883f9M3d79Hh89Pi8sfV5NDd677H0cLIz8/f8MbU4tLg7tDe7NXj8dPh77/J07S5vq+0ubK2uszP0svO0cXIy9bY2qChovz9/t3e39rb3NjZ2tfY2dbX2H6t2c/U2M3S1snO0q6ytcLS3cjY48bW4bfDy6u1vL/Gy6yytquxtcnP06/Q5LDQ5K/P463M4KvK3rHQ5K/O4srb5sna5cjZ5MbX4r/P2b7O2K7Q467O4a3N4N3z/9Xp9MHS3MjZ48fY4sXW4LbCybK3urG2ua6ztrm+wbe8v7S5vLO4u67R49/0/+H1/+D0/tfq9Nrs9cvR1La6vLG1t8vP0crO0KKkpdrc3dja2+P2/+b3/+P0/OLz+7rFyuLz+svS1bq/wdXa3NTZ2+j5/9rq79np7ur6/+j4/ef3/OX0+dTa3NTX2NPW19LV1s7Z3MzX2uT0+MzNzfX19fLy8vHx8fDw8O/v7+7u7u3t7ezs7Ovr6+bm5uXl5eTk5OPj4+Li4uHh4eDg4N/f397e3t3d3dra2tnZ2djY2NfX19bW1tXV1dTU1NPT09LS0tHR0dDQ0M/Pz87Ozs3NzczMzMLCwsHBwcDAwL+/v76+vr29vby8vLu7u7q6urm5ubi4uLe3t7Ozs7KysrGxsbCwsK+vr66urq2traysrKurq6qqqqmpqaioqKenp6ampqOjo5+fn56enp2dnZycnAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAZgAYAEAI/wADCBxIsKBAIggTKlzIsKHDhxAjSmzYqeKoUb8qatzYKUCFjxZGdfhIsmQFIllSkhn1JqXLl1mIkAw50mRJInFyjhnFJqfPn3FQqmQJEyaRWEibweK1zFo1ZrtORUMaK0CDq81iMbVGjRkvU9GuNiAipazSXk277gJb9gsRsUp5MePq9RQ0sUQS6I27rNrTqNH0JiBrdmnfv2yluNXEWJMtUb5KkRI2q1VjTQFUaFbhYpQNGCs4zPKwWYXQlE5GpfHSBcqsKC+JlHYh6nPo0aWJINqNiNCoQooStZH1iDei01mciFLD+snr2KuiPztV61eyYbpcYYIWfVWAB+Cfmf+iZZ1Y9u3gHxD5wl589WTmtUdj7za9eFq+kGF/lSlaeiILBHjfL8iY98p2AS6wXnvj5WcgJvOxR8QsFFZo4YWzWCXWhhzidcWHIIYoolsdloiXYCimiCIRIrYYoluZxBjjJrG40sosnMgYYwAz9NgjDTUYUUQLMfjYI3JZbMFEFHagoYRRRs4ApJBERknEIlhiycgkhxhCSSNZYomkkkc0+WRsnKQZyijDpJnmLriE4mYAGNSZwSg41FnnBgZkoOdpSYyCx0tN7JCES0ToeWeeevLpZ51E+CFpHaPcIamkguRRx6WACkqooYimIup9w+jHiyyaSCNqKgEc4KozptT/Uuowp6bq6gFEwKHrfcIUWKs0urp163SyHkNML7L0dysRIDTLq6/JRtMsCLnuOl6pxPwaLBGudAsrfsYEkwt/0HTrioYNfPtLuLrwF9ZVC36hbjHBZJcJNPS9ddW89ZJ7ol6wVkdvu/cKFm8zsf5C77j35ovhwxWiayKHLLroIokTd5iXihzrVbHFI04I8cMSZwwvyC1ibPK/Hav4McofuuXDzDTXbLMPARCg884890wAkkUZ5fPQOxNBNNFAB42ojp7EAgorqFyyyic68uijDDk8HTUPLBiJ3BJ6gLLKKZdEckZsRmKt9SVcex2mI5KIHXUflYT5tQ5yXwLJ2Yhu/+L3J6jc8onfnkwztd+bBJDC4hoUAAAKi78wgBAaLJ7CaWbwgQsXKZXRwxBmIGp5449HLgDllhPxx+qB/GDJIKsDskcQgaz+B+ZAbN7556GnRISborDpZpqdDB/ACchfMMoNyDdvQvMnnLYSEjBpEVvzyjMP/fPNEyHH93SM4sb35M9BvhzSj7JG9bF54v5Zc1nzDC+oROO+JwFQoH9czFxzzfypiIb+KHAa/lnjf/SLBqIGyL9ryK8X9RsgEcRAQQM+MIAUFEMBtRK/Z/QigIhShQjd8wtlECMXsOiPCFURAAS40D3AWAZ2UigNFyIgXjA0IQr7ky8b5tA8NLQhEf8+QMTpkGcZBuoPET+Aw/HEMInSyFcrpjigYgiDYdGYYivQ9S1fDMwVmZAGXuhTxX6FMV9i6aIxrsgfMcJLMOKZhcKuCMbAeIw+sJLjwtyVL1j48T7AGJi7/AgLdBlxjuOC0BgZJDBhEAxfEhILsQIpLn+9US8k3GN/DEZG6iiskjyUkCxGOQta1MIWuEilLWhBi1mMEl0OmAAJSgCBWpZgBBNwALymwEsqYCEMVbCCMKsABixQYQoqi+UsawmBW+bykglQAAMkEAIRWDMEEWCAAjzGyyn4EpjCtAIxjYlMkY3sQiUz2ctgprKVjaVlHFsnytxyTgylM2PyBFk7V7YbMXiuCGYvMmc9KXTPieXTYvtUpz9TdNCLESEgADs="

/***/ }),
/* 649 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M31.2,29.1c4.5-6.1,3.9-14.7-1.7-20C23.4,3.4,13.9,3.7,8.1,9.7c-5.7,6.1-5.5,15.6,0.6,21.4c5.6,5.3,14.3,5.5,20.1,0.7 M10.6,29.1c-4.9-4.7-5.2-12.5-0.5-17.5c4.7-4.9,12.5-5.2,17.5-0.5c4.9,4.7,5.2,12.5,0.5,17.5C23.4,33.6,15.6,33.8,10.6,29.1z M31.2,29.1l7.2,6.8c0.4,0.3,0.5,0.8,0.6,1.2c0,0.5-0.2,0.9-0.5,1.3S37.7,39,37.2,39c-0.5,0-0.9-0.2-1.3-0.5l-7.2-6.8'/%3E %3C/svg%3E\""

/***/ }),
/* 650 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M31.6,30.6c-0.3,0.3-0.8,0.5-1.3,0.5H12.8c-0.5,0-0.9-0.2-1.3-0.5c-0.3-0.3-0.5-0.8-0.5-1.3c0-0.5,0.2-0.9,0.5-1.3L29,10.5 c0.3-0.3,0.8-0.5,1.3-0.5c0.5,0,0.9,0.2,1.3,0.5c0.3,0.3,0.5,0.8,0.5,1.3v17.5C32.1,29.8,31.9,30.2,31.6,30.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 651 */,
/* 652 */,
/* 653 */,
/* 654 */,
/* 655 */,
/* 656 */,
/* 657 */,
/* 658 */,
/* 659 */,
/* 660 */,
/* 661 */,
/* 662 */,
/* 663 */,
/* 664 */,
/* 665 */,
/* 666 */,
/* 667 */,
/* 668 */,
/* 669 */,
/* 670 */,
/* 671 */,
/* 672 */,
/* 673 */,
/* 674 */,
/* 675 */,
/* 676 */,
/* 677 */,
/* 678 */,
/* 679 */,
/* 680 */,
/* 681 */,
/* 682 */,
/* 683 */,
/* 684 */,
/* 685 */,
/* 686 */,
/* 687 */,
/* 688 */,
/* 689 */,
/* 690 */,
/* 691 */,
/* 692 */,
/* 693 */,
/* 694 */,
/* 695 */,
/* 696 */,
/* 697 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(230)(__webpack_require__(698))

/***/ }),
/* 698 */
/***/ (function(module, exports) {

module.exports = "/*! store2 - v2.11.2 - 2020-05-11\n* Copyright (c) 2020 Nathan Bubna; Licensed (MIT OR GPL-3.0) */\n;(function(window, define) {\n    var _ = {\n        version: \"2.11.2\",\n        areas: {},\n        apis: {},\n\n        // utilities\n        inherit: function(api, o) {\n            for (var p in api) {\n                if (!o.hasOwnProperty(p)) {\n                    Object.defineProperty(o, p, Object.getOwnPropertyDescriptor(api, p));\n                }\n            }\n            return o;\n        },\n        stringify: function(d) {\n            return d === undefined || typeof d === \"function\" ? d+'' : JSON.stringify(d);\n        },\n        parse: function(s, fn) {\n            // if it doesn't parse, return as is\n            try{ return JSON.parse(s,fn||_.revive); }catch(e){ return s; }\n        },\n\n        // extension hooks\n        fn: function(name, fn) {\n            _.storeAPI[name] = fn;\n            for (var api in _.apis) {\n                _.apis[api][name] = fn;\n            }\n        },\n        get: function(area, key){ return area.getItem(key); },\n        set: function(area, key, string){ area.setItem(key, string); },\n        remove: function(area, key){ area.removeItem(key); },\n        key: function(area, i){ return area.key(i); },\n        length: function(area){ return area.length; },\n        clear: function(area){ area.clear(); },\n\n        // core functions\n        Store: function(id, area, namespace) {\n            var store = _.inherit(_.storeAPI, function(key, data, overwrite) {\n                if (arguments.length === 0){ return store.getAll(); }\n                if (typeof data === \"function\"){ return store.transact(key, data, overwrite); }// fn=data, alt=overwrite\n                if (data !== undefined){ return store.set(key, data, overwrite); }\n                if (typeof key === \"string\" || typeof key === \"number\"){ return store.get(key); }\n                if (typeof key === \"function\"){ return store.each(key); }\n                if (!key){ return store.clear(); }\n                return store.setAll(key, data);// overwrite=data, data=key\n            });\n            store._id = id;\n            try {\n                var testKey = '_-bad-_';\n                area.setItem(testKey, 'wolf');\n                store._area = area;\n                area.removeItem(testKey);\n            } catch (e) {}\n            if (!store._area) {\n                store._area = _.storage('fake');\n            }\n            store._ns = namespace || '';\n            if (!_.areas[id]) {\n                _.areas[id] = store._area;\n            }\n            if (!_.apis[store._ns+store._id]) {\n                _.apis[store._ns+store._id] = store;\n            }\n            return store;\n        },\n        storeAPI: {\n            // admin functions\n            area: function(id, area) {\n                var store = this[id];\n                if (!store || !store.area) {\n                    store = _.Store(id, area, this._ns);//new area-specific api in this namespace\n                    if (!this[id]){ this[id] = store; }\n                }\n                return store;\n            },\n            namespace: function(namespace, singleArea) {\n                if (!namespace){\n                    return this._ns ? this._ns.substring(0,this._ns.length-1) : '';\n                }\n                var ns = namespace, store = this[ns];\n                if (!store || !store.namespace) {\n                    store = _.Store(this._id, this._area, this._ns+ns+'.');//new namespaced api\n                    if (!this[ns]){ this[ns] = store; }\n                    if (!singleArea) {\n                        for (var name in _.areas) {\n                            store.area(name, _.areas[name]);\n                        }\n                    }\n                }\n                return store;\n            },\n            isFake: function(){ return this._area.name === 'fake'; },\n            toString: function() {\n                return 'store'+(this._ns?'.'+this.namespace():'')+'['+this._id+']';\n            },\n\n            // storage functions\n            has: function(key) {\n                if (this._area.has) {\n                    return this._area.has(this._in(key));//extension hook\n                }\n                return !!(this._in(key) in this._area);\n            },\n            size: function(){ return this.keys().length; },\n            each: function(fn, fill) {// fill is used by keys(fillList) and getAll(fillList))\n                for (var i=0, m=_.length(this._area); i<m; i++) {\n                    var key = this._out(_.key(this._area, i));\n                    if (key !== undefined) {\n                        if (fn.call(this, key, this.get(key), fill) === false) {\n                            break;\n                        }\n                    }\n                    if (m > _.length(this._area)) { m--; i--; }// in case of removeItem\n                }\n                return fill || this;\n            },\n            keys: function(fillList) {\n                return this.each(function(k, v, list){ list.push(k); }, fillList || []);\n            },\n            get: function(key, alt) {\n                var s = _.get(this._area, this._in(key)),\n                    fn;\n                if (typeof alt === \"function\") {\n                    fn = alt;\n                    alt = null;\n                }\n                return s !== null ? _.parse(s, fn) :\n                    alt != null ? alt : s;\n            },\n            getAll: function(fillObj) {\n                return this.each(function(k, v, all){ all[k] = v; }, fillObj || {});\n            },\n            transact: function(key, fn, alt) {\n                var val = this.get(key, alt),\n                    ret = fn(val);\n                this.set(key, ret === undefined ? val : ret);\n                return this;\n            },\n            set: function(key, data, overwrite) {\n                var d = this.get(key);\n                if (d != null && overwrite === false) {\n                    return data;\n                }\n                return _.set(this._area, this._in(key), _.stringify(data), overwrite) || d;\n            },\n            setAll: function(data, overwrite) {\n                var changed, val;\n                for (var key in data) {\n                    val = data[key];\n                    if (this.set(key, val, overwrite) !== val) {\n                        changed = true;\n                    }\n                }\n                return changed;\n            },\n            add: function(key, data) {\n                var d = this.get(key);\n                if (d instanceof Array) {\n                    data = d.concat(data);\n                } else if (d !== null) {\n                    var type = typeof d;\n                    if (type === typeof data && type === 'object') {\n                        for (var k in data) {\n                            d[k] = data[k];\n                        }\n                        data = d;\n                    } else {\n                        data = d + data;\n                    }\n                }\n                _.set(this._area, this._in(key), _.stringify(data));\n                return data;\n            },\n            remove: function(key, alt) {\n                var d = this.get(key, alt);\n                _.remove(this._area, this._in(key));\n                return d;\n            },\n            clear: function() {\n                if (!this._ns) {\n                    _.clear(this._area);\n                } else {\n                    this.each(function(k){ _.remove(this._area, this._in(k)); }, 1);\n                }\n                return this;\n            },\n            clearAll: function() {\n                var area = this._area;\n                for (var id in _.areas) {\n                    if (_.areas.hasOwnProperty(id)) {\n                        this._area = _.areas[id];\n                        this.clear();\n                    }\n                }\n                this._area = area;\n                return this;\n            },\n\n            // internal use functions\n            _in: function(k) {\n                if (typeof k !== \"string\"){ k = _.stringify(k); }\n                return this._ns ? this._ns + k : k;\n            },\n            _out: function(k) {\n                return this._ns ?\n                    k && k.indexOf(this._ns) === 0 ?\n                        k.substring(this._ns.length) :\n                        undefined : // so each() knows to skip it\n                    k;\n            }\n        },// end _.storeAPI\n        storage: function(name) {\n            return _.inherit(_.storageAPI, { items: {}, name: name });\n        },\n        storageAPI: {\n            length: 0,\n            has: function(k){ return this.items.hasOwnProperty(k); },\n            key: function(i) {\n                var c = 0;\n                for (var k in this.items){\n                    if (this.has(k) && i === c++) {\n                        return k;\n                    }\n                }\n            },\n            setItem: function(k, v) {\n                if (!this.has(k)) {\n                    this.length++;\n                }\n                this.items[k] = v;\n            },\n            removeItem: function(k) {\n                if (this.has(k)) {\n                    delete this.items[k];\n                    this.length--;\n                }\n            },\n            getItem: function(k){ return this.has(k) ? this.items[k] : null; },\n            clear: function(){ for (var k in this.items){ this.removeItem(k); } }\n        }// end _.storageAPI\n    };\n\n    var store =\n        // safely set this up (throws error in IE10/32bit mode for local files)\n        _.Store(\"local\", (function(){try{ return localStorage; }catch(e){}})());\n    store.local = store;// for completeness\n    store._ = _;// for extenders and debuggers...\n    // safely setup store.session (throws exception in FF for file:/// urls)\n    store.area(\"session\", (function(){try{ return sessionStorage; }catch(e){}})());\n    store.area(\"page\", _.storage(\"page\"));\n\n    if (typeof define === 'function' && define.amd !== undefined) {\n        define('store2', [], function () {\n            return store;\n        });\n    } else if (typeof module !== 'undefined' && module.exports) {\n        module.exports = store;\n    } else {\n        // expose the primary store fn to the global object and save conflicts\n        if (window.store){ _.conflict = window.store; }\n        window.store = store;\n    }\n\n})(this, this && this.define);\n"

/***/ }),
/* 699 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(230)(__webpack_require__(700))

/***/ }),
/* 700 */
/***/ (function(module, exports) {

module.exports = "/**\n * Copyright (c) 2013 ESHA Research\n * Dual licensed under the MIT and GPL licenses:\n *   http://www.opensource.org/licenses/mit-license.php\n *   http://www.gnu.org/licenses/gpl.html\n *\n * Makes it easy to watch for storage events by enhancing the events and\n * allowing binding to particular keys and/or namespaces.\n *\n * // listen to particular key storage events (yes, this is namespace sensitive)\n * store.on('foo', function listenToFoo(e){ console.log('foo was changed:', e); });\n * store.off('foo', listenToFoo);\n *\n * // listen to all storage events\n * store.on(function storageEvent(e){ console.log('web storage:', e); });\n * store.off(storageEvent);\n * \n * Status: ALPHA - useful, if you don't mind incomplete browser support for events\n */\n;(function(window, document, _) {\n    _.fn('on', function(key, fn) {\n        if (!fn) { fn = key; key = ''; }// shift args when needed\n        var s = this,\n            bound,\n            id = _.id(this._area);\n        if (window.addEventListener) {\n            window.addEventListener(\"storage\", bound = function(e) {\n                var k = s._out(e.key);\n                if (k && (!key || k === key)) {// must match key if listener has one\n                    var eid = _.id(e.storageArea);\n                    if (!eid || id === eid) {// must match area, if event has a known one\n                        return fn.call(s, _.event(k, s, e));\n                    }\n                }\n            }, false);\n        } else {\n            document.attachEvent(\"onstorage\", bound = function() {\n                return fn.call(s, window.event);\n            });\n        }\n        fn['_'+key+'listener'] = bound;\n        return s;\n    });\n    _.fn('off', function(key, fn) {\n        if (!fn) { fn = key; key = ''; }// shift args when needed\n        var bound = fn['_'+key+'listener'];\n        if (window.removeEventListener) {\n            window.removeEventListener(\"storage\", bound);\n        } else {\n            document.detachEvent(\"onstorage\", bound);\n        }\n        return this;\n    });\n    _.event = function(k, s, e) {\n        var event = {\n            key: k,\n            namespace: s.namespace(),\n            newValue: _.parse(e.newValue),\n            oldValue: _.parse(e.oldValue),\n            url: e.url || e.uri,\n            storageArea: e.storageArea,\n            source: e.source,\n            timeStamp: e.timeStamp,\n            originalEvent: e\n        };\n        if (_.cache) {\n            var min = _.expires(e.newValue || e.oldValue);\n            if (min) {\n                event.expires = _.when(min);\n            }\n        }\n        return event;\n    };\n    _.id = function(area) {\n        for (var id in _.areas) {\n            if (area === _.areas[id]) {\n                return id;\n            }\n        }\n    };\n})(window, document, window.store._);"

/***/ }),
/* 701 */
/***/ (function(module, exports, __webpack_require__) {

// custom ext definition

/* pkg: Ext Base (adapter/ext/ext-base.js)*/
__webpack_require__(702);

__webpack_require__(703);

__webpack_require__(704);

__webpack_require__(705);
/* pkg: Ext Foundation (pkgs/ext-foundation.js)*/


__webpack_require__(706);

__webpack_require__(707);

__webpack_require__(708);

__webpack_require__(709);

__webpack_require__(710);

__webpack_require__(711);

__webpack_require__(712);

__webpack_require__(713);

__webpack_require__(714);

__webpack_require__(715);

__webpack_require__(716);

__webpack_require__(717);

__webpack_require__(718);

__webpack_require__(719);

__webpack_require__(720);

__webpack_require__(721);

__webpack_require__(722);

__webpack_require__(723);

__webpack_require__(724);

__webpack_require__(725);

__webpack_require__(726);

__webpack_require__(727);

__webpack_require__(728);

__webpack_require__(729);

__webpack_require__(730);

__webpack_require__(731);

__webpack_require__(732);

__webpack_require__(733);

__webpack_require__(734);

__webpack_require__(735);

__webpack_require__(736);

__webpack_require__(737);

__webpack_require__(738);

__webpack_require__(739);

__webpack_require__(740);

__webpack_require__(741);

__webpack_require__(742);

__webpack_require__(743);

__webpack_require__(744);

__webpack_require__(745);

__webpack_require__(746);

__webpack_require__(747);

__webpack_require__(748);

__webpack_require__(749);
/* pkg: Component Foundation (pkgs/cmp-foundation.js)*/


__webpack_require__(750);

__webpack_require__(751);

__webpack_require__(752);

__webpack_require__(753);

__webpack_require__(754);

__webpack_require__(755);

__webpack_require__(756);

__webpack_require__(757);

__webpack_require__(758);

__webpack_require__(759);

__webpack_require__(760);

__webpack_require__(761);

__webpack_require__(762);

__webpack_require__(763);

__webpack_require__(764);

__webpack_require__(765);

__webpack_require__(766);

__webpack_require__(767);

__webpack_require__(768);

__webpack_require__(769);

__webpack_require__(770);

__webpack_require__(771);

__webpack_require__(772);

__webpack_require__(773);

__webpack_require__(774);

__webpack_require__(775);

__webpack_require__(776);

__webpack_require__(777);

__webpack_require__(778);

__webpack_require__(779);
/* pkg: Drag Drop (pkgs/ext-dd.js)*/


__webpack_require__(780);

__webpack_require__(781);

__webpack_require__(782);

__webpack_require__(783);

__webpack_require__(784);

__webpack_require__(785);

__webpack_require__(786);

__webpack_require__(787);

__webpack_require__(788);

__webpack_require__(789);
/* pkg: Data Foundation (pkgs/data-foundation.js)*/


__webpack_require__(790);

__webpack_require__(791);

__webpack_require__(792);

__webpack_require__(793);

__webpack_require__(794);

__webpack_require__(795);

__webpack_require__(796);

__webpack_require__(797);

__webpack_require__(798);

__webpack_require__(799);

__webpack_require__(800);

__webpack_require__(801);

__webpack_require__(802);

__webpack_require__(803);
/* pkg: Data - Json (pkgs/data-json.js)*/


__webpack_require__(804);

__webpack_require__(805);

__webpack_require__(806);

__webpack_require__(807);

__webpack_require__(808);
/* pkg: Data - XML (pkgs/data-xml.js)*/


__webpack_require__(809);

__webpack_require__(810);

__webpack_require__(811);
/* pkg: Data - GroupingStore (pkgs/data-grouping.js)*/


__webpack_require__(812);
/* pkg: Direct (pkgs/direct.js)*/


__webpack_require__(813);

__webpack_require__(814);

__webpack_require__(815);

__webpack_require__(816);

__webpack_require__(817);

__webpack_require__(818);

__webpack_require__(819);

__webpack_require__(820);

__webpack_require__(821);
/* pkg: Resizable (pkgs/resizable.js)*/


__webpack_require__(822);
/* pkg: Window (pkgs/window.js)*/


__webpack_require__(823);

__webpack_require__(824);

__webpack_require__(825);

__webpack_require__(826);
/* pkg: State (pkgs/state.js)*/


__webpack_require__(827);

__webpack_require__(828);

__webpack_require__(829);
/* pkg: Data and ListViews (pkgs/data-list-views.js)*/


__webpack_require__(830);

__webpack_require__(831);

__webpack_require__(832);

__webpack_require__(833);

__webpack_require__(834);
/* pkg: TabPanel (pkgs/pkg-tabs.js)*/


__webpack_require__(835);
/* pkg: Buttons (pkgs/pkg-buttons.js)*/


__webpack_require__(836);

__webpack_require__(837);

__webpack_require__(838);
/* pkg: Toolbars (pkgs/pkg-toolbars.js)*/


__webpack_require__(839);

__webpack_require__(840);

__webpack_require__(841);
/* pkg: History (pkgs/pkg-history.js)*/


__webpack_require__(842);
/* pkg: Tooltips (pkgs/pkg-tips.js)*/


__webpack_require__(843);

__webpack_require__(844);

__webpack_require__(845);

__webpack_require__(846);
/* pkg: Trees (pkgs/pkg-tree.js)*/


__webpack_require__(847);

__webpack_require__(848);

__webpack_require__(849);

__webpack_require__(850);

__webpack_require__(851);

__webpack_require__(852);

__webpack_require__(853);

__webpack_require__(854);

__webpack_require__(855);

__webpack_require__(856);

__webpack_require__(857);

__webpack_require__(858);

__webpack_require__(859);
/* pkg: Menu (pkgs/pkg-menu.js)*/


__webpack_require__(860);

__webpack_require__(861);

__webpack_require__(862);

__webpack_require__(863);

__webpack_require__(864);

__webpack_require__(865);

__webpack_require__(866);

__webpack_require__(867);

__webpack_require__(868);
/* pkg: Forms (pkgs/pkg-forms.js)*/


__webpack_require__(869);

__webpack_require__(870);

__webpack_require__(871);

__webpack_require__(872);

__webpack_require__(873);

__webpack_require__(874);

__webpack_require__(875);

__webpack_require__(876);

__webpack_require__(877);

__webpack_require__(878);

__webpack_require__(879);

__webpack_require__(880);

__webpack_require__(881);

__webpack_require__(882);

__webpack_require__(883);

__webpack_require__(884);

__webpack_require__(885);

__webpack_require__(886);

__webpack_require__(887);

__webpack_require__(888);

__webpack_require__(889);
/* pkg: Grid Foundation (pkgs/pkg-grid-foundation.js)*/


__webpack_require__(890);

__webpack_require__(891);

__webpack_require__(892);

__webpack_require__(893);

__webpack_require__(894);

__webpack_require__(895);

__webpack_require__(896);

__webpack_require__(897);

__webpack_require__(898);

__webpack_require__(899);

__webpack_require__(900);
/* pkg: Grid Editor (pkgs/pkg-grid-editor.js)*/


__webpack_require__(901);

__webpack_require__(902);

__webpack_require__(903);
/* pkg: Grid - Property Grid (pkgs/pkg-grid-property.js)*/


__webpack_require__(904);
/* pkg: Grid - GroupingView (pkgs/pkg-grid-grouping.js)*/


__webpack_require__(905);
/* pkg: Ext All CSS No theme (resources/css/ext-all-notheme.css)*/


__webpack_require__(906);

__webpack_require__(908);

__webpack_require__(910);

__webpack_require__(912);

__webpack_require__(914);

__webpack_require__(916);

__webpack_require__(918);

__webpack_require__(920);

__webpack_require__(922);

__webpack_require__(924);

__webpack_require__(926);

__webpack_require__(928);

__webpack_require__(930);

__webpack_require__(932);

__webpack_require__(934);

__webpack_require__(936);

__webpack_require__(938);

__webpack_require__(940);

__webpack_require__(942);

__webpack_require__(944);

__webpack_require__(946);

__webpack_require__(948);

__webpack_require__(950);

__webpack_require__(952);

__webpack_require__(954);
/* pkg: Ext Blue Theme (resources/css/xtheme-blue.css)*/


__webpack_require__(956);

__webpack_require__(961);

__webpack_require__(974);

__webpack_require__(981);

__webpack_require__(987);

__webpack_require__(997);

__webpack_require__(1004);

__webpack_require__(1026);

__webpack_require__(1031);

__webpack_require__(1052);

__webpack_require__(1058);

__webpack_require__(1064);

__webpack_require__(1070);

__webpack_require__(1077);

__webpack_require__(1080);

__webpack_require__(1084);

__webpack_require__(1086);

__webpack_require__(1088);

__webpack_require__(1090);

__webpack_require__(1092);

__webpack_require__(1096);

__webpack_require__(1099);

__webpack_require__(1105);

/***/ }),
/* 702 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
// for old browsers
window.undefined = window.undefined;
/**
 * @class Ext
 * Ext core utilities and functions.
 * @singleton
 */

Ext = {
  /**
   * The version of the framework
   * @type String
   */
  version: '3.1.1~custom'
};
/**
 * Copies all the properties of config to obj.
 * @param {Object} obj The receiver of the properties
 * @param {Object} config The source of the properties
 * @param {Object} defaults A different object that will also be applied for default values
 * @return {Object} returns obj
 * @member Ext apply
 */

Ext.apply = function (o, c, defaults) {
  // no "this" reference for friendly out of scope calls
  if (defaults) {
    Ext.apply(o, defaults);
  }

  if (o && c && typeof c == 'object') {
    for (var p in c) {
      o[p] = c[p];
    }
  }

  return o;
};

(function () {
  var idSeed = 0,
      toString = Object.prototype.toString,
      ua = navigator.userAgent.toLowerCase(),
      check = function check(r) {
    return r.test(ua);
  },
      docMode = document.documentMode,
      DOC = document,
      isStrict = DOC.compatMode == "CSS1Compat",
      isOpera = check(/opera/),
      isChrome = check(/\bchrome\b/),
      isWebKit = check(/webkit/),
      isSafari = !isChrome && check(/safari/),
      isSafari2 = isSafari && check(/applewebkit\/4/),
      // unique to Safari 2
  isSafari3 = isSafari && check(/version\/3/),
      isSafari4 = isSafari && check(/version\/4/),
      isIE = !isOpera && check(/msie/),
      isIE7 = isIE && check(/msie 7/),
      isIE8 = isIE && check(/msie 8/),
      isIE6 = isIE && !isIE7 && !isIE8,
      isIE10 = check(/msie 10/) && docMode != 7 && docMode != 8 && docMode != 9 || docMode == 10,
      isIE11 = check(/trident\/7\.0/) && docMode != 7 && docMode != 8 && docMode != 9 && docMode != 10 || docMode == 11,
      isNewIE = Ext.isIE9 || isIE10 || isIE11,
      isEdge = check(/edge/),
      isGecko = !isWebKit && check(/gecko/),
      isGecko2 = isGecko && check(/rv:1\.8/),
      isGecko3 = isGecko && check(/rv:1\.9/),
      isBorderBox = isIE && !isStrict,
      isWindows = check(/windows|win32/),
      isMac = check(/macintosh|mac os x/),
      isAir = check(/adobeair/),
      isLinux = check(/linux/),
      isSecure = /^https/i.test(window.location.protocol),
      isIOS = check(/ipad/) || check(/iphone/),
      isAndroid = check(/android/),
      isTouchDevice = // @see http://www.stucox.com/blog/you-cant-detect-a-touchscreen/
  'ontouchstart' in window // works on most browsers
  || navigator.maxTouchPoints,
      // works on IE10/11 and Surface
  isWebApp = // @see https://stackoverflow.com/questions/17989777/detect-if-ios-is-using-webapp/40932301#40932301
  window.navigator.standalone == true || // iOS safari
  window.matchMedia('(display-mode: standalone)').matches,
      // android chrome
  // NOTE: some browsers require user interaction (like click events)
  //       for focus to work (e.g. iOS dosn't show keyborad)
  supportsUserFocus = !(isTouchDevice && !isWebApp),
      isThenable = function isThenable(v) {
    return !!v && typeof v.then === 'function';
  }; // remove css image flicker


  if (isIE6) {
    try {
      DOC.execCommand("BackgroundImageCache", false, true);
    } catch (e) {}
  }

  Ext.apply(Ext, {
    /**
     * URL to a blank file used by Ext when in secure mode for iframe src and onReady src to prevent
     * the IE insecure content warning (<tt>'about:blank'</tt>, except for IE in secure mode, which is <tt>'javascript:""'</tt>).
     * @type String
     */
    SSL_SECURE_URL: isSecure && isIE ? 'javascript:""' : 'about:blank',

    /**
     * True if the browser is in strict (standards-compliant) mode, as opposed to quirks mode
     * @type Boolean
     */
    isStrict: isStrict,

    /**
     * True if the page is running over SSL
     * @type Boolean
     */
    isSecure: isSecure,

    /**
     * True when the document is fully initialized and ready for action
     * @type Boolean
     */
    isReady: false,

    /**
     * True if the {@link Ext.Fx} Class is available
     * @type Boolean
     * @property enableFx
     */

    /**
     * True to automatically uncache orphaned Ext.Elements periodically (defaults to true)
     * @type Boolean
     */
    enableGarbageCollector: true,

    /**
     * True to automatically purge event listeners during garbageCollection (defaults to false).
     * @type Boolean
     */
    enableListenerCollection: false,

    /**
     * EXPERIMENTAL - True to cascade listener removal to child elements when an element is removed.
     * Currently not optimized for performance.
     * @type Boolean
     */
    enableNestedListenerRemoval: false,

    /**
     * Indicates whether to use native browser parsing for JSON methods.
     * This option is ignored if the browser does not support native JSON methods.
     * <b>Note: Native JSON methods will not work with objects that have functions.
     * Also, property names must be quoted, otherwise the data will not parse.</b> (Defaults to false)
     * @type Boolean
     */
    USE_NATIVE_JSON: false,

    /**
     * Copies all the properties of config to obj if they don't already exist.
     * @param {Object} obj The receiver of the properties
     * @param {Object} config The source of the properties
     * @return {Object} returns obj
     */
    applyIf: function applyIf(o, c) {
      if (o) {
        for (var p in c) {
          if (!Ext.isDefined(o[p])) {
            o[p] = c[p];
          }
        }
      }

      return o;
    },

    /**
     * Generates unique ids. If the element already has an id, it is unchanged
     * @param {Mixed} el (optional) The element to generate an id for
     * @param {String} prefix (optional) Id prefix (defaults "ext-gen")
     * @return {String} The generated Id.
     */
    id: function id(el, prefix) {
      el = Ext.getDom(el, true) || {};

      if (!el.id) {
        el.id = (prefix || "ext-gen") + ++idSeed;
      }

      return el.id;
    },

    /**
     * <p>Extends one class to create a subclass and optionally overrides members with the passed literal. This method
     * also adds the function "override()" to the subclass that can be used to override members of the class.</p>
     * For example, to create a subclass of Ext GridPanel:
     * <pre><code>
    MyGridPanel = Ext.extend(Ext.grid.GridPanel, {
    constructor: function(config) {
    //      Create configuration for this Grid.
    var store = new Ext.data.Store({...});
    var colModel = new Ext.grid.ColumnModel({...});
    //      Create a new config object containing our computed properties
    //      *plus* whatever was in the config parameter.
    config = Ext.apply({
        store: store,
        colModel: colModel
    }, config);
     MyGridPanel.superclass.constructor.call(this, config);
    //      Your postprocessing here
    },
    yourMethod: function() {
    // etc.
    }
    });
    </code></pre>
     *
     * <p>This function also supports a 3-argument call in which the subclass's constructor is
     * passed as an argument. In this form, the parameters are as follows:</p>
     * <div class="mdetail-params"><ul>
     * <li><code>subclass</code> : Function <div class="sub-desc">The subclass constructor.</div></li>
     * <li><code>superclass</code> : Function <div class="sub-desc">The constructor of class being extended</div></li>
     * <li><code>overrides</code> : Object <div class="sub-desc">A literal with members which are copied into the subclass's
     * prototype, and are therefore shared among all instances of the new class.</div></li>
     * </ul></div>
     *
     * @param {Function} superclass The constructor of class being extended.
     * @param {Object} overrides <p>A literal with members which are copied into the subclass's
     * prototype, and are therefore shared between all instances of the new class.</p>
     * <p>This may contain a special member named <tt><b>constructor</b></tt>. This is used
     * to define the constructor of the new class, and is returned. If this property is
     * <i>not</i> specified, a constructor is generated and returned which just calls the
     * superclass's constructor passing on its parameters.</p>
     * <p><b>It is essential that you call the superclass constructor in any provided constructor. See example code.</b></p>
     * @return {Function} The subclass constructor from the <code>overrides</code> parameter, or a generated one if not provided.
     */
    extend: function () {
      // inline overrides
      var io = function io(o) {
        for (var m in o) {
          this[m] = o[m];
        }
      };

      var oc = Object.prototype.constructor;
      return function (sb, sp, overrides) {
        if (Ext.isObject(sp)) {
          overrides = sp;
          sp = sb;
          sb = overrides.constructor != oc ? overrides.constructor : function () {
            sp.apply(this, arguments);
          };
        }

        var F = function F() {},
            sbp,
            spp = sp.prototype;

        F.prototype = spp;
        sbp = sb.prototype = new F();
        sbp.constructor = sb;
        sb.superclass = spp;

        if (spp.constructor == oc) {
          spp.constructor = sp;
        }

        sb.override = function (o) {
          Ext.override(sb, o);
        };

        sbp.superclass = sbp.supr = function () {
          return spp;
        };

        sbp.override = io;
        Ext.override(sb, overrides);

        if (sbp && sbp.inheritableStatics) {
          Ext.apply(sb, sbp.inheritableStatics);
        }

        if (overrides && overrides.statics) {
          Ext.apply(sb, overrides.statics);
        }

        sb.extend = function (o) {
          return Ext.extend(sb, o);
        };

        return sb;
      };
    }(),

    /**
     * Adds a list of functions to the prototype of an existing class, overwriting any existing methods with the same name.
     * Usage:<pre><code>
    Ext.override(MyClass, {
    newMethod1: function(){
    // etc.
    },
    newMethod2: function(foo){
    // etc.
    }
    });
    </code></pre>
     * @param {Object} origclass The class to override
     * @param {Object} overrides The list of functions to add to origClass.  This should be specified as an object literal
     * containing one or more methods.
     * @method override
     */
    override: function override(origclass, overrides) {
      if (overrides) {
        var p = origclass.prototype;
        Ext.apply(p, overrides);

        if (Ext.isIE && overrides.hasOwnProperty('toString')) {
          p.toString = overrides.toString;
        }
      }
    },

    /**
     * Creates namespaces to be used for scoping variables and classes so that they are not global.
     * Specifying the last node of a namespace implicitly creates all other nodes. Usage:
     * <pre><code>
    Ext.namespace('Company', 'Company.data');
    Ext.namespace('Company.data'); // equivalent and preferable to above syntax
    Company.Widget = function() { ... }
    Company.data.CustomStore = function(config) { ... }
    </code></pre>
     * @param {String} namespace1
     * @param {String} namespace2
     * @param {String} etc
     * @return {Object} The namespace object. (If multiple arguments are passed, this will be the last namespace created)
     * @method namespace
     */
    namespace: function namespace() {
      var o, d;
      Ext.each(arguments, function (v) {
        d = v.split(".");
        o = window[d[0]] = window[d[0]] || {};
        Ext.each(d.slice(1), function (v2) {
          o = o[v2] = o[v2] || {};
        });
      });
      return o;
    },

    /**
     * Takes an object and converts it to an encoded URL. e.g. Ext.urlEncode({foo: 1, bar: 2}); would return "foo=1&bar=2".  Optionally, property values can be arrays, instead of keys and the resulting string that's returned will contain a name/value pair for each array value.
     * @param {Object} o
     * @param {String} pre (optional) A prefix to add to the url encoded string
     * @return {String}
     */
    urlEncode: function urlEncode(o, pre) {
      var empty,
          buf = [],
          e = encodeURIComponent;
      Ext.iterate(o, function (key, item) {
        empty = Ext.isEmpty(item);
        Ext.each(empty ? key : item, function (val) {
          buf.push('&', e(key), '=', !Ext.isEmpty(val) && (val != key || !empty) ? Ext.isDate(val) ? Ext.encode(val).replace(/"/g, '') : e(val) : '');
        });
      });

      if (!pre) {
        buf.shift();
        pre = '';
      }

      return pre + buf.join('');
    },

    /**
     * Takes an encoded URL and and converts it to an object. Example: <pre><code>
    Ext.urlDecode("foo=1&bar=2"); // returns {foo: "1", bar: "2"}
    Ext.urlDecode("foo=1&bar=2&bar=3&bar=4", false); // returns {foo: "1", bar: ["2", "3", "4"]}
    </code></pre>
     * @param {String} string
     * @param {Boolean} overwrite (optional) Items of the same name will overwrite previous values instead of creating an an array (Defaults to false).
     * @return {Object} A literal with members
     */
    urlDecode: function urlDecode(string, overwrite) {
      if (Ext.isEmpty(string)) {
        return {};
      }

      var obj = {},
          pairs = string.split('&'),
          d = decodeURIComponent,
          name,
          value;
      Ext.each(pairs, function (pair) {
        pair = pair.split('=');
        name = d(pair[0]);
        value = d(pair[1]);
        obj[name] = overwrite || !obj[name] ? value : [].concat(obj[name]).concat(value);
      });
      return obj;
    },

    /**
     * Appends content to the query string of a URL, handling logic for whether to place
     * a question mark or ampersand.
     * @param {String} url The URL to append to.
     * @param {String} s The content to append to the URL.
     * @return (String) The resulting URL
     */
    urlAppend: function urlAppend(url, s) {
      if (!Ext.isEmpty(s)) {
        return url + (url.indexOf('?') === -1 ? '?' : '&') + s;
      }

      return url;
    },

    /**
     * Converts any iterable (numeric indices and a length property) into a true array
     * Don't use this on strings. IE doesn't support "abc"[0] which this implementation depends on.
     * For strings, use this instead: "abc".match(/./g) => [a,b,c];
     * @param {Iterable} the iterable object to be turned into a true Array.
     * @return (Array) array
     */
    toArray: function () {
      return isIE ? function (a, i, j, res) {
        res = [];

        for (var x = 0, len = a.length; x < len; x++) {
          res.push(a[x]);
        }

        return res.slice(i || 0, j || res.length);
      } : function (a, i, j) {
        return Array.prototype.slice.call(a, i || 0, j || a.length);
      };
    }(),
    isIterable: function isIterable(v) {
      //check for array or arguments
      if (Ext.isArray(v) || v.callee) {
        return true;
      } //check for node list type


      if (/NodeList|HTMLCollection/.test(toString.call(v))) {
        return true;
      } //NodeList has an item and length property
      //IXMLDOMNodeList has nextNode method, needs to be checked first.


      return (typeof v.nextNode != 'undefined' || v.item) && Ext.isNumber(v.length);
    },

    /**
     * Iterates an array calling the supplied function.
     * @param {Array/NodeList/Mixed} array The array to be iterated. If this
     * argument is not really an array, the supplied function is called once.
     * @param {Function} fn The function to be called with each item. If the
     * supplied function returns false, iteration stops and this method returns
     * the current <code>index</code>. This function is called with
     * the following arguments:
     * <div class="mdetail-params"><ul>
     * <li><code>item</code> : <i>Mixed</i>
     * <div class="sub-desc">The item at the current <code>index</code>
     * in the passed <code>array</code></div></li>
     * <li><code>index</code> : <i>Number</i>
     * <div class="sub-desc">The current index within the array</div></li>
     * <li><code>allItems</code> : <i>Array</i>
     * <div class="sub-desc">The <code>array</code> passed as the first
     * argument to <code>Ext.each</code>.</div></li>
     * </ul></div>
     * @param {Object} scope The scope (<code>this</code> reference) in which the specified function is executed.
     * Defaults to the <code>item</code> at the current <code>index</code>
     * within the passed <code>array</code>.
     * @return See description for the fn parameter.
     */
    each: function each(array, fn, scope) {
      if (Ext.isEmpty(array, true)) {
        return;
      }

      if (!Ext.isIterable(array) || Ext.isPrimitive(array)) {
        array = [array];
      }

      for (var i = 0, len = array.length; i < len; i++) {
        if (fn.call(scope || array[i], array[i], i, array) === false) {
          return i;
        }

        ;
      }
    },

    /**
     * Iterates either the elements in an array, or each of the properties in an object.
     * <b>Note</b>: If you are only iterating arrays, it is better to call {@link #each}.
     * @param {Object/Array} object The object or array to be iterated
     * @param {Function} fn The function to be called for each iteration.
     * The iteration will stop if the supplied function returns false, or
     * all array elements / object properties have been covered. The signature
     * varies depending on the type of object being interated:
     * <div class="mdetail-params"><ul>
     * <li>Arrays : <tt>(Object item, Number index, Array allItems)</tt>
     * <div class="sub-desc">
     * When iterating an array, the supplied function is called with each item.</div></li>
     * <li>Objects : <tt>(String key, Object value, Object)</tt>
     * <div class="sub-desc">
     * When iterating an object, the supplied function is called with each key-value pair in
     * the object, and the iterated object</div></li>
     * </ul></div>
     * @param {Object} scope The scope (<code>this</code> reference) in which the specified function is executed. Defaults to
     * the <code>object</code> being iterated.
     */
    iterate: function iterate(obj, fn, scope) {
      if (Ext.isEmpty(obj)) {
        return;
      }

      if (Ext.isIterable(obj)) {
        Ext.each(obj, fn, scope);
        return;
      } else if (Ext.isObject(obj)) {
        for (var prop in obj) {
          if (obj.hasOwnProperty(prop)) {
            if (fn.call(scope || obj, prop, obj[prop], obj) === false) {
              return;
            }

            ;
          }
        }
      }
    },

    /**
     * Return the dom node for the passed String (id), dom node, or Ext.Element.
     * Optional 'strict' flag is needed for IE since it can return 'name' and
     * 'id' elements by using getElementById.
     * Here are some examples:
     * <pre><code>
    // gets dom node based on id
    var elDom = Ext.getDom('elId');
    // gets dom node based on the dom node
    var elDom1 = Ext.getDom(elDom);
    // If we don&#39;t know if we are working with an
    // Ext.Element or a dom node use Ext.getDom
    function(el){
    var dom = Ext.getDom(el);
    // do something with the dom node
    }
     * </code></pre>
     * <b>Note</b>: the dom node to be found actually needs to exist (be rendered, etc)
     * when this method is called to be successful.
     * @param {Mixed} el
     * @return HTMLElement
     */
    getDom: function getDom(el, strict) {
      if (!el || !DOC) {
        return null;
      }

      if (el.dom) {
        return el.dom;
      } else {
        if (Ext.isString(el)) {
          var e = DOC.getElementById(el); // IE returns elements with the 'name' and 'id' attribute.
          // we do a strict check to return the element with only the id attribute

          if (e && isIE && strict) {
            if (el == e.getAttribute('id')) {
              return e;
            } else {
              return null;
            }
          }

          return e;
        } else {
          return el;
        }
      }
    },

    /**
     * Returns the current document body as an {@link Ext.Element}.
     * @return Ext.Element The document body
     */
    getBody: function getBody() {
      return Ext.get(DOC.body || DOC.documentElement);
    },

    /**
     * Removes a DOM node from the document.
     */

    /**
     * <p>Removes this element from the document, removes all DOM event listeners, and deletes the cache reference.
     * All DOM event listeners are removed from this element. If {@link Ext#enableNestedListenerRemoval} is
     * <code>true</code>, then DOM event listeners are also removed from all child nodes. The body node
     * will be ignored if passed in.</p>
     * @param {HTMLElement} node The node to remove
     */
    removeNode: isIE && !isIE8 ? function () {
      var d;
      return function (n) {
        if (n && n.tagName != 'BODY') {
          Ext.enableNestedListenerRemoval ? Ext.EventManager.purgeElement(n, true) : Ext.EventManager.removeAll(n);
          d = d || DOC.createElement('div');
          d.appendChild(n);
          d.innerHTML = '';
          delete Ext.elCache[n.id];
        }
      };
    }() : function (n) {
      if (n && n.parentNode && n.tagName != 'BODY') {
        Ext.enableNestedListenerRemoval ? Ext.EventManager.purgeElement(n, true) : Ext.EventManager.removeAll(n);
        n.parentNode.removeChild(n);
        delete Ext.elCache[n.id];
      }
    },

    /**
     * <p>Returns true if the passed value is empty.</p>
     * <p>The value is deemed to be empty if it is<div class="mdetail-params"><ul>
     * <li>null</li>
     * <li>undefined</li>
     * <li>an empty array</li>
     * <li>a zero length string (Unless the <tt>allowBlank</tt> parameter is <tt>true</tt>)</li>
     * </ul></div>
     * @param {Mixed} value The value to test
     * @param {Boolean} allowBlank (optional) true to allow empty strings (defaults to false)
     * @return {Boolean}
     */
    isEmpty: function isEmpty(v, allowBlank) {
      return v === null || v === undefined || Ext.isArray(v) && !v.length || (!allowBlank ? v === '' : false);
    },

    /**
     * Returns true if the passed value is a JavaScript array, otherwise false.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isArray: function isArray(v) {
      return toString.apply(v) === '[object Array]';
    },

    /**
     * Returns true if the passed object is a JavaScript date object, otherwise false.
     * @param {Object} object The object to test
     * @return {Boolean}
     */
    isDate: function isDate(v) {
      return toString.apply(v) === '[object Date]';
    },

    /**
     * Returns true if the passed value is a JavaScript Object, otherwise false.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isObject: function isObject(v) {
      return !!v && Object.prototype.toString.call(v) === '[object Object]';
    },

    /**
     * Returns true if the passed value is a JavaScript 'primitive', a string, number or boolean.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isPrimitive: function isPrimitive(v) {
      return Ext.isString(v) || Ext.isNumber(v) || Ext.isBoolean(v);
    },

    /**
     * Returns true if the passed value is a JavaScript Function, otherwise false.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isFunction: function isFunction(v) {
      return _.isFunction(v); // cope with async functions
    },

    /**
     * Returns true if the passed value is a number. Returns false for non-finite numbers.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isNumber: function isNumber(v) {
      return typeof v === 'number' && isFinite(v);
    },

    /**
     * Returns true if the passed value is a string.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isString: function isString(v) {
      return typeof v === 'string';
    },

    /**
     * Returns true if the passed value is a boolean.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isBoolean: function isBoolean(v) {
      return typeof v === 'boolean';
    },

    /**
     * Returns true if the passed value is an HTMLElement
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isElement: function isElement(v) {
      return !!v && v.tagName;
    },

    /**
     * Returns true if the passed value is not undefined.
     * @param {Mixed} value The value to test
     * @return {Boolean}
     */
    isDefined: function isDefined(v) {
      return typeof v !== 'undefined';
    },

    /**
     * True if the detected browser is Opera.
     * @type Boolean
     */
    isOpera: isOpera,

    /**
     * True if the detected browser uses WebKit.
     * @type Boolean
     */
    isWebKit: isWebKit,

    /**
     * True if the detected browser is Chrome.
     * @type Boolean
     */
    isChrome: isChrome,

    /**
     * True if the detected browser is Safari.
     * @type Boolean
     */
    isSafari: isSafari,

    /**
     * True if the detected browser is Safari 3.x.
     * @type Boolean
     */
    isSafari3: isSafari3,

    /**
     * True if the detected browser is Safari 4.x.
     * @type Boolean
     */
    isSafari4: isSafari4,

    /**
     * True if the detected browser is Safari 2.x.
     * @type Boolean
     */
    isSafari2: isSafari2,

    /**
     * True if the detected browser is Internet Explorer.
     * @type Boolean
     */
    isIE: isIE,

    /**
     * True if the detected browser is Internet Explorer 6.x.
     * @type Boolean
     */
    isIE6: isIE6,

    /**
     * True if the detected browser is Internet Explorer 7.x.
     * @type Boolean
     */
    isIE7: isIE7,

    /**
     * True if the detected browser is Internet Explorer 8.x.
     * @type Boolean
     */
    isIE8: isIE8,

    /**
     * True if the detected browser uses the Gecko layout engine (e.g. Mozilla, Firefox).
     * @type Boolean
     */
    isGecko: isGecko,

    /**
     * True if the detected browser uses a pre-Gecko 1.9 layout engine (e.g. Firefox 2.x).
     * @type Boolean
     */
    isGecko2: isGecko2,

    /**
     * True if the detected browser uses a Gecko 1.9+ layout engine (e.g. Firefox 3.x).
     * @type Boolean
     */
    isGecko3: isGecko3,

    /**
     * True if the detected browser is Internet Explorer running in non-strict mode.
     * @type Boolean
     */
    isBorderBox: isBorderBox,

    /**
     * True if the detected platform is Linux.
     * @type Boolean
     */
    isLinux: isLinux,

    /**
     * True if the detected platform is Windows.
     * @type Boolean
     */
    isWindows: isWindows,

    /**
     * True if the detected platform is Mac OS.
     * @type Boolean
     */
    isMac: isMac,

    /**
     * True if the detected platform is Adobe Air.
     * @type Boolean
     */
    isAir: isAir,
    isIE10: isIE10,
    isIE11: isIE11,
    isNewIE: isNewIE,
    isEdge: isEdge,
    isIOS: isIOS,
    isAndroid: isAndroid,
    isTouchDevice: isTouchDevice,
    isWebApp: isWebApp,
    supportsUserFocus: supportsUserFocus,
    supportsPopupWindows: !isIOS && !isAndroid,
    isThenable: isThenable,
    isPromise: isThenable
  });
  /**
   * Creates namespaces to be used for scoping variables and classes so that they are not global.
   * Specifying the last node of a namespace implicitly creates all other nodes. Usage:
   * <pre><code>
  Ext.namespace('Company', 'Company.data');
  Ext.namespace('Company.data'); // equivalent and preferable to above syntax
  Company.Widget = function() { ... }
  Company.data.CustomStore = function(config) { ... }
  </code></pre>
   * @param {String} namespace1
   * @param {String} namespace2
   * @param {String} etc
   * @return {Object} The namespace object. (If multiple arguments are passed, this will be the last namespace created)
   * @method ns
   */

  Ext.ns = Ext.namespace;
})();

Ext.ns("Ext.util", "Ext.lib", "Ext.data");
Ext.elCache = {};
/**
 * @class Function
 * These functions are available on every Function object (any JavaScript function).
 */

Ext.apply(Function.prototype, {
  /**
  * Creates an interceptor function. The passed function is called before the original one. If it returns false,
  * the original one is not called. The resulting function returns the results of the original function.
  * The passed function is called with the parameters of the original function. Example usage:
  * <pre><code>
  var sayHi = function(name){
  alert('Hi, ' + name);
  }
  sayHi('Fred'); // alerts "Hi, Fred"
  // create a new function that validates input without
  // directly modifying the original function:
  var sayHiToFriend = sayHi.createInterceptor(function(name){
  return name == 'Brian';
  });
  sayHiToFriend('Fred');  // no alert
  sayHiToFriend('Brian'); // alerts "Hi, Brian"
  </code></pre>
  * @param {Function} fcn The function to call before the original
  * @param {Object} scope (optional) The scope (<code><b>this</b></code> reference) in which the passed function is executed.
  * <b>If omitted, defaults to the scope in which the original function is called or the browser window.</b>
  * @return {Function} The new function
  */
  createInterceptor: function createInterceptor(fcn, scope) {
    var method = this;
    return !Ext.isFunction(fcn) ? this : function () {
      var me = this,
          args = arguments;
      fcn.target = me;
      fcn.method = method;
      return fcn.apply(scope || me || window, args) !== false ? method.apply(me || window, args) : null;
    };
  },

  /**
  * Creates a callback that passes arguments[0], arguments[1], arguments[2], ...
  * Call directly on any function. Example: <code>myFunction.createCallback(arg1, arg2)</code>
  * Will create a function that is bound to those 2 args. <b>If a specific scope is required in the
  * callback, use {@link #createDelegate} instead.</b> The function returned by createCallback always
  * executes in the window scope.
  * <p>This method is required when you want to pass arguments to a callback function.  If no arguments
  * are needed, you can simply pass a reference to the function as a callback (e.g., callback: myFn).
  * However, if you tried to pass a function with arguments (e.g., callback: myFn(arg1, arg2)) the function
  * would simply execute immediately when the code is parsed. Example usage:
  * <pre><code>
  var sayHi = function(name){
  alert('Hi, ' + name);
  }
  // clicking the button alerts "Hi, Fred"
  new Ext.Button({
  text: 'Say Hi',
  renderTo: Ext.getBody(),
  handler: sayHi.createCallback('Fred')
  });
  </code></pre>
  * @return {Function} The new function
  */
  createCallback: function createCallback()
  /*args...*/
  {
    // make args available, in function below
    var args = arguments,
        method = this;
    return function () {
      return method.apply(window, args);
    };
  },

  /**
   * Creates a delegate (callback) that sets the scope to obj.
   * Call directly on any function. Example: <code>this.myFunction.createDelegate(this, [arg1, arg2])</code>
   * Will create a function that is automatically scoped to obj so that the <tt>this</tt> variable inside the
   * callback points to obj. Example usage:
   * <pre><code>
  var sayHi = function(name){
  // Note this use of "this.text" here.  This function expects to
  // execute within a scope that contains a text property.  In this
  // example, the "this" variable is pointing to the btn object that
  // was passed in createDelegate below.
  alert('Hi, ' + name + '. You clicked the "' + this.text + '" button.');
  }
  var btn = new Ext.Button({
  text: 'Say Hi',
  renderTo: Ext.getBody()
  });
  // This callback will execute in the scope of the
  // button instance. Clicking the button alerts
  // "Hi, Fred. You clicked the "Say Hi" button."
  btn.on('click', sayHi.createDelegate(btn, ['Fred']));
  </code></pre>
   * @param {Object} scope (optional) The scope (<code><b>this</b></code> reference) in which the function is executed.
   * <b>If omitted, defaults to the browser window.</b>
   * @param {Array} args (optional) Overrides arguments for the call. (Defaults to the arguments passed by the caller)
   * @param {Boolean/Number} appendArgs (optional) if True args are appended to call args instead of overriding,
   * if a number the args are inserted at the specified position
   * @return {Function} The new function
   */
  createDelegate: function createDelegate(obj, args, appendArgs) {
    var method = this;
    return function () {
      var callArgs = args || arguments;

      if (appendArgs === true) {
        callArgs = Array.prototype.slice.call(arguments, 0);
        callArgs = callArgs.concat(args);
      } else if (Ext.isNumber(appendArgs)) {
        callArgs = Array.prototype.slice.call(arguments, 0); // copy arguments first

        var applyArgs = [appendArgs, 0].concat(args); // create method call params

        Array.prototype.splice.apply(callArgs, applyArgs); // splice them in
      }

      return method.apply(obj || window, callArgs);
    };
  },

  /**
   * Calls this function after the number of millseconds specified, optionally in a specific scope. Example usage:
   * <pre><code>
  var sayHi = function(name){
  alert('Hi, ' + name);
  }
  // executes immediately:
  sayHi('Fred');
  // executes after 2 seconds:
  sayHi.defer(2000, this, ['Fred']);
  // this syntax is sometimes useful for deferring
  // execution of an anonymous function:
  (function(){
  alert('Anonymous');
  }).defer(100);
  </code></pre>
   * @param {Number} millis The number of milliseconds for the setTimeout call (if less than or equal to 0 the function is executed immediately)
   * @param {Object} scope (optional) The scope (<code><b>this</b></code> reference) in which the function is executed.
   * <b>If omitted, defaults to the browser window.</b>
   * @param {Array} args (optional) Overrides arguments for the call. (Defaults to the arguments passed by the caller)
   * @param {Boolean/Number} appendArgs (optional) if True args are appended to call args instead of overriding,
   * if a number the args are inserted at the specified position
   * @return {Number} The timeout id that can be used with clearTimeout
   */
  defer: function defer(millis, obj, args, appendArgs) {
    var fn = this.createDelegate(obj, args, appendArgs);

    if (millis > 0) {
      return setTimeout(fn, millis);
    }

    fn();
    return 0;
  }
});
/**
 * @class String
 * These functions are available on every String object.
 */

Ext.applyIf(String, {
  /**
   * Allows you to define a tokenized string and pass an arbitrary number of arguments to replace the tokens.  Each
   * token must be unique, and must increment in the format {0}, {1}, etc.  Example usage:
   * <pre><code>
  var cls = 'my-class', text = 'Some text';
  var s = String.format('&lt;div class="{0}">{1}&lt;/div>', cls, text);
  // s now contains the string: '&lt;div class="my-class">Some text&lt;/div>'
   * </code></pre>
   * @param {String} string The tokenized string to be formatted
   * @param {String} value1 The value to replace token {0}
   * @param {String} value2 Etc...
   * @return {String} The formatted string
   * @static
   */
  format: function format(_format) {
    var args = Ext.toArray(arguments, 1);
    return _format.replace(/\{(\d+)\}/g, function (m, i) {
      return args[i];
    });
  }
});
/**
 * @class Array
 */

Ext.applyIf(Array.prototype, {
  /**
   * Checks whether or not the specified object exists in the array.
   * @param {Object} o The object to check for
   * @param {Number} from (Optional) The index at which to begin the search
   * @return {Number} The index of o in the array (or -1 if it is not found)
   */
  indexOf: function indexOf(o, from) {
    var len = this.length;
    from = from || 0;
    from += from < 0 ? len : 0;

    for (; from < len; ++from) {
      if (this[from] === o) {
        return from;
      }
    }

    return -1;
  },

  /**
   * Removes the specified object from the array.  If the object is not found nothing happens.
   * @param {Object} o The object to remove
   * @return {Array} this array
   */
  remove: function remove(o) {
    var index = this.indexOf(o);

    if (index != -1) {
      this.splice(index, 1);
    }

    return this;
  }
});

/***/ }),
/* 703 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext
 */
Ext.ns("Ext.grid", "Ext.list", "Ext.dd", "Ext.tree", "Ext.form", "Ext.menu", "Ext.state", "Ext.layout", "Ext.app", "Ext.ux", "Ext.chart", "Ext.direct");
/**
 * Namespace alloted for extensions to the framework.
 * @property ux
 * @type Object
 */

Ext.apply(Ext, function () {
  var E = Ext,
      idSeed = 0,
      scrollWidth = null;
  return {
    /**
    * A reusable empty function
    * @property
    * @type Function
    */
    emptyFn: function emptyFn() {},

    /**
     * URL to a 1x1 transparent gif image used by Ext to create inline icons with CSS background images. 
     * In older versions of IE, this defaults to "http://extjs.com/s.gif" and you should change this to a URL on your server.
     * For other browsers it uses an inline data URL.
     * @type String
     */
    BLANK_IMAGE_URL: Ext.isIE6 || Ext.isIE7 || Ext.isAir ? 'http:/' + '/extjs.com/s.gif' : 'data:image/gif;base64,R0lGODlhAQABAID/AMDAwAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==',
    extendX: function extendX(supr, fn) {
      return Ext.extend(supr, fn(supr.prototype));
    },

    /**
     * Returns the current HTML document object as an {@link Ext.Element}.
     * @return Ext.Element The document
     */
    getDoc: function getDoc() {
      return Ext.get(document);
    },

    /**
     * Utility method for validating that a value is numeric, returning the specified default value if it is not.
     * @param {Mixed} value Should be a number, but any type will be handled appropriately
     * @param {Number} defaultValue The value to return if the original value is non-numeric
     * @return {Number} Value, if numeric, else defaultValue
     */
    num: function num(v, defaultValue) {
      v = Number(Ext.isEmpty(v) || Ext.isArray(v) || Ext.isBoolean(v) || Ext.isString(v) && v.trim().length == 0 ? NaN : v);
      return isNaN(v) ? defaultValue : v;
    },

    /**
     * <p>Utility method for returning a default value if the passed value is empty.</p>
     * <p>The value is deemed to be empty if it is<div class="mdetail-params"><ul>
     * <li>null</li>
     * <li>undefined</li>
     * <li>an empty array</li>
     * <li>a zero length string (Unless the <tt>allowBlank</tt> parameter is <tt>true</tt>)</li>
     * </ul></div>
     * @param {Mixed} value The value to test
     * @param {Mixed} defaultValue The value to return if the original value is empty
     * @param {Boolean} allowBlank (optional) true to allow zero length strings to qualify as non-empty (defaults to false)
     * @return {Mixed} value, if non-empty, else defaultValue
     */
    value: function value(v, defaultValue, allowBlank) {
      return Ext.isEmpty(v, allowBlank) ? defaultValue : v;
    },

    /**
     * Escapes the passed string for use in a regular expression
     * @param {String} str
     * @return {String}
     */
    escapeRe: function escapeRe(s) {
      return s.replace(/([-.*+?^${}()|[\]\/\\])/g, "\\$1");
    },
    sequence: function sequence(o, name, fn, scope) {
      o[name] = o[name].createSequence(fn, scope);
    },

    /**
     * Applies event listeners to elements by selectors when the document is ready.
     * The event name is specified with an <tt>&#64;</tt> suffix.
     * <pre><code>
    Ext.addBehaviors({
    // add a listener for click on all anchors in element with id foo
    '#foo a&#64;click' : function(e, t){
    // do something
    },
     // add the same listener to multiple selectors (separated by comma BEFORE the &#64;)
    '#foo a, #bar span.some-class&#64;mouseover' : function(){
    // do something
    }
    });
     * </code></pre> 
     * @param {Object} obj The list of behaviors to apply
     */
    addBehaviors: function addBehaviors(o) {
      if (!Ext.isReady) {
        Ext.onReady(function () {
          Ext.addBehaviors(o);
        });
      } else {
        var cache = {},
            // simple cache for applying multiple behaviors to same selector does query multiple times
        parts,
            b,
            s;

        for (b in o) {
          if ((parts = b.split('@'))[1]) {
            // for Object prototype breakers
            s = parts[0];

            if (!cache[s]) {
              cache[s] = Ext.select(s);
            }

            cache[s].on(parts[1], o[b]);
          }
        }

        cache = null;
      }
    },

    /**
     * Utility method for getting the width of the browser scrollbar. This can differ depending on
     * operating system settings, such as the theme or font size.
     * @param {Boolean} force (optional) true to force a recalculation of the value.
     * @return {Number} The width of the scrollbar.
     */
    getScrollBarWidth: function getScrollBarWidth(force) {
      if (!Ext.isReady) {
        return 0;
      }

      if (force === true || scrollWidth === null) {
        // Append our div, do our calculation and then remove it
        var div = Ext.getBody().createChild('<div class="x-hide-offsets" style="width:100px;height:50px;overflow:hidden;"><div style="height:200px;"></div></div>'),
            child = div.child('div', true);
        var w1 = child.offsetWidth;
        div.setStyle('overflow', Ext.isWebKit || Ext.isGecko ? 'auto' : 'scroll');
        var w2 = child.offsetWidth;
        div.remove(); // Need to add 2 to ensure we leave enough space

        scrollWidth = w1 - w2 + 2;
      }

      return scrollWidth;
    },
    // deprecated
    combine: function combine() {
      var as = arguments,
          l = as.length,
          r = [];

      for (var i = 0; i < l; i++) {
        var a = as[i];

        if (Ext.isArray(a)) {
          r = r.concat(a);
        } else if (a.length !== undefined && !a.substr) {
          r = r.concat(Array.prototype.slice.call(a, 0));
        } else {
          r.push(a);
        }
      }

      return r;
    },

    /**
     * Copies a set of named properties fom the source object to the destination object.
     * <p>example:<pre><code>
    ImageComponent = Ext.extend(Ext.BoxComponent, {
    initComponent: function() {
    this.autoEl = { tag: 'img' };
    MyComponent.superclass.initComponent.apply(this, arguments);
    this.initialBox = Ext.copyTo({}, this.initialConfig, 'x,y,width,height');
    }
    });
     * </code></pre> 
     * @param {Object} The destination object.
     * @param {Object} The source object.
     * @param {Array/String} Either an Array of property names, or a comma-delimited list
     * of property names to copy.
     * @return {Object} The modified object.
    */
    copyTo: function copyTo(dest, source, names) {
      if (Ext.isString(names)) {
        names = names.split(/[,;\s]/);
      }

      Ext.each(names, function (name) {
        if (source.hasOwnProperty(name)) {
          dest[name] = source[name];
        }
      }, this);
      return dest;
    },

    /**
     * Attempts to destroy any objects passed to it by removing all event listeners, removing them from the
     * DOM (if applicable) and calling their destroy functions (if available).  This method is primarily
     * intended for arguments of type {@link Ext.Element} and {@link Ext.Component}, but any subclass of
     * {@link Ext.util.Observable} can be passed in.  Any number of elements and/or components can be
     * passed into this function in a single call as separate arguments.
     * @param {Mixed} arg1 An {@link Ext.Element}, {@link Ext.Component}, or an Array of either of these to destroy
     * @param {Mixed} arg2 (optional)
     * @param {Mixed} etc... (optional)
     */
    destroy: function destroy() {
      Ext.each(arguments, function (arg) {
        if (arg) {
          if (Ext.isArray(arg)) {
            this.destroy.apply(this, arg);
          } else if (Ext.isFunction(arg.destroy)) {
            arg.destroy();
          } else if (arg.dom) {
            arg.remove();
          }
        }
      }, this);
    },

    /**
     * Attempts to destroy and then remove a set of named properties of the passed object.
     * @param {Object} o The object (most likely a Component) who's properties you wish to destroy.
     * @param {Mixed} arg1 The name of the property to destroy and remove from the object.
     * @param {Mixed} etc... More property names to destroy and remove.
     */
    destroyMembers: function destroyMembers(o, arg1, arg2, etc) {
      for (var i = 1, a = arguments, len = a.length; i < len; i++) {
        Ext.destroy(o[a[i]]);
        delete o[a[i]];
      }
    },

    /**
     * Creates a copy of the passed Array with falsy values removed.
     * @param {Array/NodeList} arr The Array from which to remove falsy values.
     * @return {Array} The new, compressed Array.
     */
    clean: function clean(arr) {
      var ret = [];
      Ext.each(arr, function (v) {
        if (!!v) {
          ret.push(v);
        }
      });
      return ret;
    },

    /**
     * Creates a copy of the passed Array, filtered to contain only unique values.
     * @param {Array} arr The Array to filter
     * @return {Array} The new Array containing unique values.
     */
    unique: function unique(arr) {
      var ret = [],
          collect = {};
      Ext.each(arr, function (v) {
        if (!collect[v]) {
          ret.push(v);
        }

        collect[v] = true;
      });
      return ret;
    },

    /**
     * Recursively flattens into 1-d Array. Injects Arrays inline.
     * @param {Array} arr The array to flatten
     * @return {Array} The new, flattened array.
     */
    flatten: function flatten(arr) {
      var worker = [];

      function rFlatten(a) {
        Ext.each(a, function (v) {
          if (Ext.isArray(v)) {
            rFlatten(v);
          } else {
            worker.push(v);
          }
        });
        return worker;
      }

      return rFlatten(arr);
    },

    /**
     * Returns the minimum value in the Array.
     * @param {Array|NodeList} arr The Array from which to select the minimum value.
     * @param {Function} comp (optional) a function to perform the comparision which determines minimization.
     *                   If omitted the "<" operator will be used. Note: gt = 1; eq = 0; lt = -1
     * @return {Object} The minimum value in the Array.
     */
    min: function min(arr, comp) {
      var ret = arr[0];

      comp = comp || function (a, b) {
        return a < b ? -1 : 1;
      };

      Ext.each(arr, function (v) {
        ret = comp(ret, v) == -1 ? ret : v;
      });
      return ret;
    },

    /**
     * Returns the maximum value in the Array
     * @param {Array|NodeList} arr The Array from which to select the maximum value.
     * @param {Function} comp (optional) a function to perform the comparision which determines maximization.
     *                   If omitted the ">" operator will be used. Note: gt = 1; eq = 0; lt = -1
     * @return {Object} The maximum value in the Array.
     */
    max: function max(arr, comp) {
      var ret = arr[0];

      comp = comp || function (a, b) {
        return a > b ? 1 : -1;
      };

      Ext.each(arr, function (v) {
        ret = comp(ret, v) == 1 ? ret : v;
      });
      return ret;
    },

    /**
     * Calculates the mean of the Array
     * @param {Array} arr The Array to calculate the mean value of.
     * @return {Number} The mean.
     */
    mean: function mean(arr) {
      return arr.length > 0 ? Ext.sum(arr) / arr.length : undefined;
    },

    /**
     * Calculates the sum of the Array
     * @param {Array} arr The Array to calculate the sum value of.
     * @return {Number} The sum.
     */
    sum: function sum(arr) {
      var ret = 0;
      Ext.each(arr, function (v) {
        ret += v;
      });
      return ret;
    },

    /**
     * Partitions the set into two sets: a true set and a false set.
     * Example: 
     * Example2: 
     * <pre><code>
    // Example 1:
    Ext.partition([true, false, true, true, false]); // [[true, true, true], [false, false]]
    // Example 2:
    Ext.partition(
    Ext.query("p"),
    function(val){
    return val.className == "class1"
    }
    );
    // true are those paragraph elements with a className of "class1",
    // false set are those that do not have that className.
     * </code></pre>
     * @param {Array|NodeList} arr The array to partition
     * @param {Function} truth (optional) a function to determine truth.  If this is omitted the element
     *                   itself must be able to be evaluated for its truthfulness.
     * @return {Array} [true<Array>,false<Array>]
     */
    partition: function partition(arr, truth) {
      var ret = [[], []];
      Ext.each(arr, function (v, i, a) {
        ret[truth && truth(v, i, a) || !truth && v ? 0 : 1].push(v);
      });
      return ret;
    },

    /**
     * Invokes a method on each item in an Array.
     * <pre><code>
    // Example:
    Ext.invoke(Ext.query("p"), "getAttribute", "id");
    // [el1.getAttribute("id"), el2.getAttribute("id"), ..., elN.getAttribute("id")]
     * </code></pre>
     * @param {Array|NodeList} arr The Array of items to invoke the method on.
     * @param {String} methodName The method name to invoke.
     * @param {Anything} ... Arguments to send into the method invocation.
     * @return {Array} The results of invoking the method on each item in the array.
     */
    invoke: function invoke(arr, methodName) {
      var ret = [],
          args = Array.prototype.slice.call(arguments, 2);
      Ext.each(arr, function (v, i) {
        if (v && Ext.isFunction(v[methodName])) {
          ret.push(v[methodName].apply(v, args));
        } else {
          ret.push(undefined);
        }
      });
      return ret;
    },

    /**
     * Plucks the value of a property from each item in the Array
     * <pre><code>
    // Example:
    Ext.pluck(Ext.query("p"), "className"); // [el1.className, el2.className, ..., elN.className]
     * </code></pre>
     * @param {Array|NodeList} arr The Array of items to pluck the value from.
     * @param {String} prop The property name to pluck from each element.
     * @return {Array} The value from each item in the Array.
     */
    pluck: function pluck(arr, prop) {
      var ret = [];
      Ext.each(arr, function (v) {
        ret.push(v[prop]);
      });
      return ret;
    },

    /**
     * <p>Zips N sets together.</p>
     * <pre><code>
    // Example 1:
    Ext.zip([1,2,3],[4,5,6]); // [[1,4],[2,5],[3,6]]
    // Example 2:
    Ext.zip(
    [ "+", "-", "+"],
    [  12,  10,  22],
    [  43,  15,  96],
    function(a, b, c){
    return "$" + a + "" + b + "." + c
    }
    ); // ["$+12.43", "$-10.15", "$+22.96"]
     * </code></pre>
     * @param {Arrays|NodeLists} arr This argument may be repeated. Array(s) to contribute values.
     * @param {Function} zipper (optional) The last item in the argument list. This will drive how the items are zipped together.
     * @return {Array} The zipped set.
     */
    zip: function zip() {
      var parts = Ext.partition(arguments, function (val) {
        return !Ext.isFunction(val);
      }),
          arrs = parts[0],
          fn = parts[1][0],
          len = Ext.max(Ext.pluck(arrs, "length")),
          ret = [];

      for (var i = 0; i < len; i++) {
        ret[i] = [];

        if (fn) {
          ret[i] = fn.apply(fn, Ext.pluck(arrs, i));
        } else {
          for (var j = 0, aLen = arrs.length; j < aLen; j++) {
            ret[i].push(arrs[j][i]);
          }
        }
      }

      return ret;
    },

    /**
     * This is shorthand reference to {@link Ext.ComponentMgr#get}.
     * Looks up an existing {@link Ext.Component Component} by {@link Ext.Component#id id}
     * @param {String} id The component {@link Ext.Component#id id}
     * @return Ext.Component The Component, <tt>undefined</tt> if not found, or <tt>null</tt> if a
     * Class was found.
    */
    getCmp: function getCmp(id) {
      return Ext.ComponentMgr.get(id);
    },

    /**
     * By default, Ext intelligently decides whether floating elements should be shimmed. If you are using flash,
     * you may want to set this to true.
     * @type Boolean
     */
    useShims: E.isIE6 || E.isMac && E.isGecko2,
    // inpired by a similar function in mootools library

    /**
     * Returns the type of object that is passed in. If the object passed in is null or undefined it
     * return false otherwise it returns one of the following values:<div class="mdetail-params"><ul>
     * <li><b>string</b>: If the object passed is a string</li>
     * <li><b>number</b>: If the object passed is a number</li>
     * <li><b>boolean</b>: If the object passed is a boolean value</li>
     * <li><b>date</b>: If the object passed is a Date object</li>
     * <li><b>function</b>: If the object passed is a function reference</li>
     * <li><b>object</b>: If the object passed is an object</li>
     * <li><b>array</b>: If the object passed is an array</li>
     * <li><b>regexp</b>: If the object passed is a regular expression</li>
     * <li><b>element</b>: If the object passed is a DOM Element</li>
     * <li><b>nodelist</b>: If the object passed is a DOM NodeList</li>
     * <li><b>textnode</b>: If the object passed is a DOM text node and contains something other than whitespace</li>
     * <li><b>whitespace</b>: If the object passed is a DOM text node and contains only whitespace</li>
     * </ul></div>
     * @param {Mixed} object
     * @return {String}
     */
    type: function type(o) {
      if (o === undefined || o === null) {
        return false;
      }

      if (o.htmlElement) {
        return 'element';
      }

      var t = typeof o;

      if (t == 'object' && o.nodeName) {
        switch (o.nodeType) {
          case 1:
            return 'element';

          case 3:
            return /\S/.test(o.nodeValue) ? 'textnode' : 'whitespace';
        }
      }

      if (t == 'object' || t == 'function') {
        switch (o.constructor) {
          case Array:
            return 'array';

          case RegExp:
            return 'regexp';

          case Date:
            return 'date';
        }

        if (Ext.isNumber(o.length) && Ext.isFunction(o.item)) {
          return 'nodelist';
        }
      }

      return t;
    },
    intercept: function intercept(o, name, fn, scope) {
      o[name] = o[name].createInterceptor(fn, scope);
    },
    // internal
    callback: function callback(cb, scope, args, delay) {
      if (Ext.isFunction(cb)) {
        if (delay) {
          cb.defer(delay, scope, args || []);
        } else {
          cb.apply(scope, args || []);
        }
      }
    }
  };
}());
/**
 * @class Function
 * These functions are available on every Function object (any JavaScript function).
 */

Ext.apply(Function.prototype, {
  /**
   * Create a combined function call sequence of the original function + the passed function.
   * The resulting function returns the results of the original function.
   * The passed fcn is called with the parameters of the original function. Example usage:
   * <pre><code>
  var sayHi = function(name){
  alert('Hi, ' + name);
  }
  sayHi('Fred'); // alerts "Hi, Fred"
  var sayGoodbye = sayHi.createSequence(function(name){
  alert('Bye, ' + name);
  });
  sayGoodbye('Fred'); // both alerts show
  </code></pre>
   * @param {Function} fcn The function to sequence
   * @param {Object} scope (optional) The scope (<code><b>this</b></code> reference) in which the passed function is executed.
   * <b>If omitted, defaults to the scope in which the original function is called or the browser window.</b>
   * @return {Function} The new function
   */
  createSequence: function createSequence(fcn, scope) {
    var method = this;
    return !Ext.isFunction(fcn) ? this : function () {
      var retval = method.apply(this || window, arguments);
      fcn.apply(scope || this || window, arguments);
      return retval;
    };
  }
});
/**
 * @class String
 * These functions are available as static methods on the JavaScript String object.
 */

Ext.applyIf(String, {
  /**
   * Escapes the passed string for ' and \
   * @param {String} string The string to escape
   * @return {String} The escaped string
   * @static
   */
  escape: function escape(string) {
    return string.replace(/('|\\)/g, "\\$1");
  },

  /**
   * Pads the left side of a string with a specified character.  This is especially useful
   * for normalizing number and date strings.  Example usage:
   * <pre><code>
  var s = String.leftPad('123', 5, '0');
  // s now contains the string: '00123'
   * </code></pre>
   * @param {String} string The original string
   * @param {Number} size The total length of the output string
   * @param {String} char (optional) The character with which to pad the original string (defaults to empty string " ")
   * @return {String} The padded string
   * @static
   */
  leftPad: function leftPad(val, size, ch) {
    var result = String(val);

    if (!ch) {
      ch = " ";
    }

    while (result.length < size) {
      result = ch + result;
    }

    return result;
  }
});
/**
 * Utility function that allows you to easily switch a string between two alternating values.  The passed value
 * is compared to the current string, and if they are equal, the other value that was passed in is returned.  If
 * they are already different, the first value passed in is returned.  Note that this method returns the new value
 * but does not change the current string.
 * <pre><code>
// alternate sort directions
sort = sort.toggle('ASC', 'DESC');

// instead of conditional logic:
sort = (sort == 'ASC' ? 'DESC' : 'ASC');
</code></pre>
 * @param {String} value The value to compare to the current string
 * @param {String} other The new value to use if the string already equals the first value passed in
 * @return {String} The new value
 */

String.prototype.toggle = function (value, other) {
  return this == value ? other : value;
};
/**
 * Trims whitespace from either end of a string, leaving spaces within the string intact.  Example:
 * <pre><code>
var s = '  foo bar  ';
alert('-' + s + '-');         //alerts "- foo bar -"
alert('-' + s.trim() + '-');  //alerts "-foo bar-"
</code></pre>
 * @return {String} The trimmed string
 */


String.prototype.trim = function () {
  var re = /^\s+|\s+$/g;
  return function () {
    return this.replace(re, "");
  };
}(); // here to prevent dependency on Date.js

/**
 Returns the number of milliseconds between this date and date
 @param {Date} date (optional) Defaults to now
 @return {Number} The diff in milliseconds
 @member Date getElapsed
 */


Date.prototype.getElapsed = function (date) {
  return Math.abs((date || new Date()).getTime() - this.getTime());
};
/**
 * @class Number
 */


Ext.applyIf(Number.prototype, {
  /**
   * Checks whether or not the current number is within a desired range.  If the number is already within the
   * range it is returned, otherwise the min or max value is returned depending on which side of the range is
   * exceeded.  Note that this method returns the constrained value but does not change the current number.
   * @param {Number} min The minimum number in the range
   * @param {Number} max The maximum number in the range
   * @return {Number} The constrained value if outside the range, otherwise the current value
   */
  constrain: function constrain(min, max) {
    return Math.min(Math.max(this, min), max);
  }
});

/***/ }),
/* 704 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.TaskRunner
 * Provides the ability to execute one or more arbitrary tasks in a multithreaded
 * manner.  Generally, you can use the singleton {@link Ext.TaskMgr} instead, but
 * if needed, you can create separate instances of TaskRunner.  Any number of
 * separate tasks can be started at any time and will run independently of each
 * other. Example usage:
 * <pre><code>
// Start a simple clock task that updates a div once per second
var updateClock = function(){
    Ext.fly('clock').update(new Date().format('g:i:s A'));
} 
var task = {
    run: updateClock,
    interval: 1000 //1 second
}
var runner = new Ext.util.TaskRunner();
runner.start(task);

// equivalent using TaskMgr
Ext.TaskMgr.start({
    run: updateClock,
    interval: 1000
});

 * </code></pre>
 * Also see {@link Ext.util.DelayedTask}. 
 * 
 * @constructor
 * @param {Number} interval (optional) The minimum precision in milliseconds supported by this TaskRunner instance
 * (defaults to 10)
 */
Ext.util.TaskRunner = function (interval) {
  interval = interval || 10;

  var tasks = [],
      removeQueue = [],
      id = 0,
      running = false,
      // private
  stopThread = function stopThread() {
    running = false;
    clearInterval(id);
    id = 0;
  },
      // private
  startThread = function startThread() {
    if (!running) {
      running = true;
      id = setInterval(runTasks, interval);
    }
  },
      // private
  removeTask = function removeTask(t) {
    removeQueue.push(t);

    if (t.onStop) {
      t.onStop.apply(t.scope || t);
    }
  },
      // private
  runTasks = function runTasks() {
    var rqLen = removeQueue.length,
        now = new Date().getTime();

    if (rqLen > 0) {
      for (var i = 0; i < rqLen; i++) {
        tasks.remove(removeQueue[i]);
      }

      removeQueue = [];

      if (tasks.length < 1) {
        stopThread();
        return;
      }
    }

    for (var i = 0, t, itime, rt, len = tasks.length; i < len; ++i) {
      t = tasks[i];
      itime = now - t.taskRunTime;

      if (t.interval <= itime) {
        rt = t.run.apply(t.scope || t, t.args || [++t.taskRunCount]);
        t.taskRunTime = now;

        if (rt === false || t.taskRunCount === t.repeat) {
          removeTask(t);
          return;
        }
      }

      if (t.duration && t.duration <= now - t.taskStartTime) {
        removeTask(t);
      }
    }
  };
  /**
   * Starts a new task.
   * @method start
   * @param {Object} task A config object that supports the following properties:<ul>
   * <li><code>run</code> : Function<div class="sub-desc">The function to execute each time the task is run. The
   * function will be called at each interval and passed the <code>args</code> argument if specified.  If a
   * particular scope is required, be sure to specify it using the <code>scope</code> argument.</div></li>
   * <li><code>interval</code> : Number<div class="sub-desc">The frequency in milliseconds with which the task
   * should be executed.</div></li>
   * <li><code>args</code> : Array<div class="sub-desc">(optional) An array of arguments to be passed to the function
   * specified by <code>run</code>.</div></li>
   * <li><code>scope</code> : Object<div class="sub-desc">(optional) The scope (<tt>this</tt> reference) in which to execute the
   * <code>run</code> function. Defaults to the task config object.</div></li>
   * <li><code>duration</code> : Number<div class="sub-desc">(optional) The length of time in milliseconds to execute
   * the task before stopping automatically (defaults to indefinite).</div></li>
   * <li><code>repeat</code> : Number<div class="sub-desc">(optional) The number of times to execute the task before
   * stopping automatically (defaults to indefinite).</div></li>
   * </ul>
   * @return {Object} The task
   */


  this.start = function (task) {
    tasks.push(task);
    task.taskStartTime = new Date().getTime();
    task.taskRunTime = 0;
    task.taskRunCount = 0;
    startThread();
    return task;
  };
  /**
   * Stops an existing running task.
   * @method stop
   * @param {Object} task The task to stop
   * @return {Object} The task
   */


  this.stop = function (task) {
    removeTask(task);
    return task;
  };
  /**
   * Stops all tasks that are currently running.
   * @method stopAll
   */


  this.stopAll = function () {
    stopThread();

    for (var i = 0, len = tasks.length; i < len; i++) {
      if (tasks[i].onStop) {
        tasks[i].onStop();
      }
    }

    tasks = [];
    removeQueue = [];
  };
};
/**
 * @class Ext.TaskMgr
 * @extends Ext.util.TaskRunner
 * A static {@link Ext.util.TaskRunner} instance that can be used to start and stop arbitrary tasks.  See
 * {@link Ext.util.TaskRunner} for supported methods and task config properties.
 * <pre><code>
// Start a simple clock task that updates a div once per second
var task = {
    run: function(){
        Ext.fly('clock').update(new Date().format('g:i:s A'));
    },
    interval: 1000 //1 second
}
Ext.TaskMgr.start(task);
</code></pre>
 * @singleton
 */


Ext.TaskMgr = new Ext.util.TaskRunner();

/***/ }),
/* 705 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
// NOTE: this adapter can't be build individually as begin/end files have invalid syntax!
(function () {
  var libFlyweight;

  function fly(el) {
    if (!libFlyweight) {
      libFlyweight = new Ext.Element.Flyweight();
    }

    libFlyweight.dom = el;
    return libFlyweight;
  } // require('./core/ext-base-dom');


  (function () {
    var doc = document,
        isCSS1 = doc.compatMode == "CSS1Compat",
        MAX = Math.max,
        ROUND = Math.round,
        PARSEINT = parseInt;
    Ext.lib.Dom = {
      isAncestor: function isAncestor(p, c) {
        var ret = false;
        p = Ext.getDom(p);
        c = Ext.getDom(c);

        if (p && c) {
          if (p.contains) {
            return p.contains(c);
          } else if (p.compareDocumentPosition) {
            return !!(p.compareDocumentPosition(c) & 16);
          } else {
            while (c = c.parentNode) {
              ret = c == p || ret;
            }
          }
        }

        return ret;
      },
      getViewWidth: function getViewWidth(full) {
        return full ? this.getDocumentWidth() : this.getViewportWidth();
      },
      getViewHeight: function getViewHeight(full) {
        return full ? this.getDocumentHeight() : this.getViewportHeight();
      },
      getDocumentHeight: function getDocumentHeight() {
        return MAX(!isCSS1 ? doc.body.scrollHeight : doc.documentElement.scrollHeight, this.getViewportHeight());
      },
      getDocumentWidth: function getDocumentWidth() {
        return MAX(!isCSS1 ? doc.body.scrollWidth : doc.documentElement.scrollWidth, this.getViewportWidth());
      },
      getViewportHeight: function getViewportHeight() {
        return Ext.isIE ? Ext.isStrict ? doc.documentElement.clientHeight : doc.body.clientHeight : self.innerHeight;
      },
      getViewportWidth: function getViewportWidth() {
        return !Ext.isStrict && !Ext.isOpera ? doc.body.clientWidth : Ext.isIE ? doc.documentElement.clientWidth : self.innerWidth;
      },
      getY: function getY(el) {
        return this.getXY(el)[1];
      },
      getX: function getX(el) {
        return this.getXY(el)[0];
      },
      getXY: function getXY(el) {
        var p,
            pe,
            b,
            bt,
            bl,
            dbd,
            x = 0,
            y = 0,
            scroll,
            hasAbsolute,
            bd = doc.body || doc.documentElement,
            ret = [0, 0];
        el = Ext.getDom(el);

        if (el != bd) {
          if (el.getBoundingClientRect) {
            b = el.getBoundingClientRect();
            scroll = fly(document).getScroll();
            ret = [ROUND(b.left + scroll.left), ROUND(b.top + scroll.top)];
          } else {
            p = el;
            hasAbsolute = fly(el).isStyle("position", "absolute");

            while (p) {
              pe = fly(p);
              x += p.offsetLeft;
              y += p.offsetTop;
              hasAbsolute = hasAbsolute || pe.isStyle("position", "absolute");

              if (Ext.isGecko) {
                y += bt = PARSEINT(pe.getStyle("borderTopWidth"), 10) || 0;
                x += bl = PARSEINT(pe.getStyle("borderLeftWidth"), 10) || 0;

                if (p != el && !pe.isStyle('overflow', 'visible')) {
                  x += bl;
                  y += bt;
                }
              }

              p = p.offsetParent;
            }

            if (Ext.isSafari && hasAbsolute) {
              x -= bd.offsetLeft;
              y -= bd.offsetTop;
            }

            if (Ext.isGecko && !hasAbsolute) {
              dbd = fly(bd);
              x += PARSEINT(dbd.getStyle("borderLeftWidth"), 10) || 0;
              y += PARSEINT(dbd.getStyle("borderTopWidth"), 10) || 0;
            }

            p = el.parentNode;

            while (p && p != bd) {
              if (!Ext.isOpera || p.tagName != 'TR' && !fly(p).isStyle("display", "inline")) {
                x -= p.scrollLeft;
                y -= p.scrollTop;
              }

              p = p.parentNode;
            }

            ret = [x, y];
          }
        }

        return ret;
      },
      setXY: function setXY(el, xy) {
        (el = Ext.fly(el, '_setXY')).position();
        var pts = el.translatePoints(xy),
            style = el.dom.style,
            pos;

        for (pos in pts) {
          if (!isNaN(pts[pos])) style[pos] = pts[pos] + "px";
        }
      },
      setX: function setX(el, x) {
        this.setXY(el, [x, false]);
      },
      setY: function setY(el, y) {
        this.setXY(el, [false, y]);
      }
    };
  })(); // require('./ext-base-dom-more');


  Ext.lib.Dom.getRegion = function (el) {
    return Ext.lib.Region.getRegion(el);
  }; // require('./core/ext-base-event');


  Ext.lib.Event = function () {
    var loadComplete = false,
        unloadListeners = {},
        retryCount = 0,
        onAvailStack = [],
        _interval,
        locked = false,
        win = window,
        doc = document,
        // constants
    POLL_RETRYS = 200,
        POLL_INTERVAL = 20,
        EL = 0,
        TYPE = 0,
        FN = 1,
        WFN = 2,
        OBJ = 2,
        ADJ_SCOPE = 3,
        SCROLLLEFT = 'scrollLeft',
        SCROLLTOP = 'scrollTop',
        UNLOAD = 'unload',
        MOUSEOVER = 'mouseover',
        MOUSEOUT = 'mouseout',
        // private
    doAdd = function () {
      var ret;

      if (win.addEventListener) {
        ret = function ret(el, eventName, fn, capture) {
          if (eventName == 'mouseenter') {
            fn = fn.createInterceptor(checkRelatedTarget);
            el.addEventListener(MOUSEOVER, fn, capture);
          } else if (eventName == 'mouseleave') {
            fn = fn.createInterceptor(checkRelatedTarget);
            el.addEventListener(MOUSEOUT, fn, capture);
          } else {
            el.addEventListener(eventName, fn, capture);
          }

          return fn;
        };
      } else if (win.attachEvent) {
        ret = function ret(el, eventName, fn, capture) {
          el.attachEvent("on" + eventName, fn);
          return fn;
        };
      } else {
        ret = function ret() {};
      }

      return ret;
    }(),
        // private
    doRemove = function () {
      var ret;

      if (win.removeEventListener) {
        ret = function ret(el, eventName, fn, capture) {
          if (eventName == 'mouseenter') {
            eventName = MOUSEOVER;
          } else if (eventName == 'mouseleave') {
            eventName = MOUSEOUT;
          }

          el.removeEventListener(eventName, fn, capture);
        };
      } else if (win.detachEvent) {
        ret = function ret(el, eventName, fn) {
          el.detachEvent("on" + eventName, fn);
        };
      } else {
        ret = function ret() {};
      }

      return ret;
    }();

    function checkRelatedTarget(e) {
      return !elContains(e.currentTarget, pub.getRelatedTarget(e));
    }

    function elContains(parent, child) {
      if (parent && parent.firstChild) {
        while (child) {
          if (child === parent) {
            return true;
          }

          child = child.parentNode;

          if (child && child.nodeType != 1) {
            child = null;
          }
        }
      }

      return false;
    } // private


    function _tryPreloadAttach() {
      var ret = false,
          notAvail = [],
          element,
          i,
          len,
          v,
          tryAgain = !loadComplete || retryCount > 0;

      if (!locked) {
        locked = true;

        for (i = 0, len = onAvailStack.length; i < len; i++) {
          v = onAvailStack[i];

          if (v && (element = doc.getElementById(v.id))) {
            if (!v.checkReady || loadComplete || element.nextSibling || doc && doc.body) {
              element = v.override ? v.override === true ? v.obj : v.override : element;
              v.fn.call(element, v.obj);
              onAvailStack.remove(v);
            } else {
              notAvail.push(v);
            }
          }
        }

        retryCount = notAvail.length === 0 ? 0 : retryCount - 1;

        if (tryAgain) {
          startInterval();
        } else {
          clearInterval(_interval);
          _interval = null;
        }

        ret = !(locked = false);
      }

      return ret;
    } // private


    function startInterval() {
      if (!_interval) {
        var callback = function callback() {
          _tryPreloadAttach();
        };

        _interval = setInterval(callback, POLL_INTERVAL);
      }
    } // private


    function getScroll() {
      var dd = doc.documentElement,
          db = doc.body;

      if (dd && (dd[SCROLLTOP] || dd[SCROLLLEFT])) {
        return [dd[SCROLLLEFT], dd[SCROLLTOP]];
      } else if (db) {
        return [db[SCROLLLEFT], db[SCROLLTOP]];
      } else {
        return [0, 0];
      }
    } // private


    function getPageCoord(ev, xy) {
      ev = ev.browserEvent || ev;
      var coord = ev['page' + xy];

      if (!coord && coord !== 0) {
        coord = ev['client' + xy] || 0;

        if (Ext.isIE) {
          coord += getScroll()[xy == "X" ? 0 : 1];
        }
      }

      return coord;
    }

    var pub = {
      extAdapter: true,
      onAvailable: function onAvailable(p_id, p_fn, p_obj, p_override) {
        onAvailStack.push({
          id: p_id,
          fn: p_fn,
          obj: p_obj,
          override: p_override,
          checkReady: false
        });
        retryCount = POLL_RETRYS;
        startInterval();
      },
      // This function should ALWAYS be called from Ext.EventManager
      addListener: function addListener(el, eventName, fn) {
        el = Ext.getDom(el);

        if (el && fn) {
          if (eventName == UNLOAD) {
            if (unloadListeners[el.id] === undefined) {
              unloadListeners[el.id] = [];
            }

            unloadListeners[el.id].push([eventName, fn]);
            return fn;
          }

          return doAdd(el, eventName, fn, false);
        }

        return false;
      },
      // This function should ALWAYS be called from Ext.EventManager
      removeListener: function removeListener(el, eventName, fn) {
        el = Ext.getDom(el);
        var i, len, li, lis;

        if (el && fn) {
          if (eventName == UNLOAD) {
            if ((lis = unloadListeners[el.id]) !== undefined) {
              for (i = 0, len = lis.length; i < len; i++) {
                if ((li = lis[i]) && li[TYPE] == eventName && li[FN] == fn) {
                  unloadListeners[el.id].splice(i, 1);
                }
              }
            }

            return;
          }

          doRemove(el, eventName, fn, false);
        }
      },
      getTarget: function getTarget(ev) {
        ev = ev.browserEvent || ev;
        return this.resolveTextNode(ev.target || ev.srcElement);
      },
      resolveTextNode: Ext.isGecko ? function (node) {
        if (!node) {
          return;
        } // work around firefox bug, https://bugzilla.mozilla.org/show_bug.cgi?id=101197


        var s = HTMLElement.prototype.toString.call(node);

        if (s == '[xpconnect wrapped native prototype]' || s == '[object XULElement]') {
          return;
        }

        return node.nodeType == 3 ? node.parentNode : node;
      } : function (node) {
        return node && node.nodeType == 3 ? node.parentNode : node;
      },
      getRelatedTarget: function getRelatedTarget(ev) {
        ev = ev.browserEvent || ev;
        return this.resolveTextNode(ev.relatedTarget || (ev.type == MOUSEOUT ? ev.toElement : ev.type == MOUSEOVER ? ev.fromElement : null));
      },
      getPageX: function getPageX(ev) {
        return getPageCoord(ev, "X");
      },
      getPageY: function getPageY(ev) {
        return getPageCoord(ev, "Y");
      },
      getXY: function getXY(ev) {
        return [this.getPageX(ev), this.getPageY(ev)];
      },
      stopEvent: function stopEvent(ev) {
        this.stopPropagation(ev);
        this.preventDefault(ev);
      },
      stopPropagation: function stopPropagation(ev) {
        ev = ev.browserEvent || ev;

        if (ev.stopPropagation) {
          ev.stopPropagation();
        } else {
          ev.cancelBubble = true;
        }
      },
      preventDefault: function preventDefault(ev) {
        ev = ev.browserEvent || ev;

        if (ev.preventDefault) {
          ev.preventDefault();
        } else {
          ev.returnValue = false;
        }
      },
      getEvent: function getEvent(e) {
        e = e || win.event;

        if (!e) {
          var c = this.getEvent.caller;

          while (c) {
            e = c.arguments[0];

            if (e && Event == e.constructor) {
              break;
            }

            c = c.caller;
          }
        }

        return e;
      },
      getCharCode: function getCharCode(ev) {
        ev = ev.browserEvent || ev;
        return ev.charCode || ev.keyCode || 0;
      },
      //clearCache: function() {},
      // deprecated, call from EventManager
      getListeners: function getListeners(el, eventName) {
        Ext.EventManager.getListeners(el, eventName);
      },
      // deprecated, call from EventManager
      purgeElement: function purgeElement(el, recurse, eventName) {
        Ext.EventManager.purgeElement(el, recurse, eventName);
      },
      _load: function _load(e) {
        loadComplete = true;
        var EU = Ext.lib.Event;

        if (Ext.isIE && e !== true) {
          // IE8 complains that _load is null or not an object
          // so lets remove self via arguments.callee
          doRemove(win, "load", arguments.callee);
        }
      },
      _unload: function _unload(e) {
        var EU = Ext.lib.Event,
            i,
            j,
            l,
            v,
            ul,
            id,
            len,
            index,
            scope;

        for (id in unloadListeners) {
          ul = unloadListeners[id];

          for (i = 0, len = ul.length; i < len; i++) {
            v = ul[i];

            if (v) {
              try {
                scope = v[ADJ_SCOPE] ? v[ADJ_SCOPE] === true ? v[OBJ] : v[ADJ_SCOPE] : win;
                v[FN].call(scope, EU.getEvent(e), v[OBJ]);
              } catch (ex) {}
            }
          }
        }

        ;
        unloadListeners = null;

        Ext.EventManager._unload();

        doRemove(win, UNLOAD, EU._unload);
      }
    }; // Initialize stuff.

    pub.on = pub.addListener;
    pub.un = pub.removeListener;

    if (doc && doc.body) {
      pub._load(true);
    } else {
      doAdd(win, "load", pub._load);
    }

    doAdd(win, UNLOAD, pub._unload);

    _tryPreloadAttach();

    return pub;
  }(); // require('./core/ext-base-ajax');

  /*
  * Portions of this file are based on pieces of Yahoo User Interface Library
  * Copyright (c) 2007, Yahoo! Inc. All rights reserved.
  * YUI licensed under the BSD License:
  * http://developer.yahoo.net/yui/license.txt
  */


  Ext.lib.Ajax = function () {
    var activeX = ['MSXML2.XMLHTTP.3.0', 'MSXML2.XMLHTTP', 'Microsoft.XMLHTTP'],
        CONTENTTYPE = 'Content-Type'; // private

    function setHeader(o) {
      var conn = o.conn,
          prop;

      function setTheHeaders(conn, headers) {
        for (prop in headers) {
          if (headers.hasOwnProperty(prop)) {
            conn.setRequestHeader(prop, headers[prop]);
          }
        }
      }

      if (pub.defaultHeaders) {
        setTheHeaders(conn, pub.defaultHeaders);
      }

      if (pub.headers) {
        setTheHeaders(conn, pub.headers);
        delete pub.headers;
      }
    } // private


    function createExceptionObject(tId, callbackArg, isAbort, isTimeout) {
      return {
        tId: tId,
        status: isAbort ? -1 : 0,
        statusText: isAbort ? 'transaction aborted' : 'communication failure',
        isAbort: isAbort,
        isTimeout: isTimeout,
        argument: callbackArg
      };
    } // private


    function initHeader(label, value) {
      (pub.headers = pub.headers || {})[label] = value;
    } // private


    function createResponseObject(o, callbackArg) {
      var headerObj = {},
          headerStr,
          conn = o.conn,
          t,
          s;

      try {
        headerStr = o.conn.getAllResponseHeaders();
        Ext.each(headerStr.replace(/\r\n/g, '\n').split('\n'), function (v) {
          t = v.indexOf(':');

          if (t >= 0) {
            s = v.substr(0, t).toLowerCase();

            if (v.charAt(t + 1) == ' ') {
              ++t;
            }

            headerObj[s] = v.substr(t + 1);
          }
        });
      } catch (e) {}

      return {
        tId: o.tId,
        status: conn.status,
        statusText: conn.statusText,
        getResponseHeader: function getResponseHeader(header) {
          return headerObj[header.toLowerCase()];
        },
        getAllResponseHeaders: function getAllResponseHeaders() {
          return headerStr;
        },
        responseText: conn.responseText,
        responseXML: conn.responseXML,
        argument: callbackArg
      };
    } // private


    function releaseObject(o) {
      o.conn = null;
      o = null;
    } // private


    function handleTransactionResponse(o, callback, isAbort, isTimeout) {
      if (!callback) {
        releaseObject(o);
        return;
      }

      var httpStatus, responseObject;

      try {
        if (o.conn.status !== undefined && o.conn.status != 0) {
          httpStatus = o.conn.status;
        } else {
          httpStatus = 13030;
        }
      } catch (e) {
        httpStatus = 13030;
      }

      if (httpStatus >= 200 && httpStatus < 300 || Ext.isIE && httpStatus == 1223) {
        responseObject = createResponseObject(o, callback.argument);

        if (callback.success) {
          if (!callback.scope) {
            callback.success(responseObject);
          } else {
            callback.success.apply(callback.scope, [responseObject]);
          }
        }
      } else {
        switch (httpStatus) {
          case 12002:
          case 12029:
          case 12030:
          case 12031:
          case 12152:
          case 13030:
            responseObject = createExceptionObject(o.tId, callback.argument, isAbort ? isAbort : false, isTimeout);

            if (callback.failure) {
              if (!callback.scope) {
                callback.failure(responseObject);
              } else {
                callback.failure.apply(callback.scope, [responseObject]);
              }
            }

            break;

          default:
            responseObject = createResponseObject(o, callback.argument);

            if (callback.failure) {
              if (!callback.scope) {
                callback.failure(responseObject);
              } else {
                callback.failure.apply(callback.scope, [responseObject]);
              }
            }

        }
      }

      releaseObject(o);
      responseObject = null;
    } // private


    function handleReadyState(o, callback) {
      callback = callback || {};
      var conn = o.conn,
          tId = o.tId,
          poll = pub.poll,
          cbTimeout = callback.timeout || null;

      if (cbTimeout) {
        pub.timeout[tId] = setTimeout(function () {
          pub.abort(o, callback, true);
        }, cbTimeout);
      }

      poll[tId] = setInterval(function () {
        if (conn && conn.readyState == 4) {
          clearInterval(poll[tId]);
          poll[tId] = null;

          if (cbTimeout) {
            clearTimeout(pub.timeout[tId]);
            pub.timeout[tId] = null;
          }

          handleTransactionResponse(o, callback);
        }
      }, pub.pollInterval);
    } // private


    function asyncRequest(method, uri, callback, postData) {
      var o = getConnectionObject() || null;

      if (o) {
        o.conn.open(method, uri, true);

        if (pub.useDefaultXhrHeader) {
          initHeader('X-Requested-With', pub.defaultXhrHeader);
        }

        if (postData && pub.useDefaultHeader && (!pub.headers || !pub.headers[CONTENTTYPE])) {
          initHeader(CONTENTTYPE, pub.defaultPostHeader);
        }

        if (pub.defaultHeaders || pub.headers) {
          setHeader(o);
        }

        handleReadyState(o, callback);
        o.conn.send(postData || null);
      }

      return o;
    } // private


    function getConnectionObject() {
      var o;

      try {
        if (o = createXhrObject(pub.transactionId)) {
          pub.transactionId++;
        }
      } catch (e) {} finally {
        return o;
      }
    } // private


    function createXhrObject(transactionId) {
      var http;

      try {
        http = new XMLHttpRequest();
      } catch (e) {
        for (var i = 0; i < activeX.length; ++i) {
          try {
            http = new ActiveXObject(activeX[i]);
            break;
          } catch (e) {}
        }
      } finally {
        return {
          conn: http,
          tId: transactionId
        };
      }
    }

    var pub = {
      request: function request(method, uri, cb, data, options) {
        if (options) {
          var me = this,
              xmlData = options.xmlData,
              jsonData = options.jsonData,
              hs;
          Ext.applyIf(me, options);

          if (xmlData || jsonData) {
            hs = me.headers;

            if (!hs || !hs[CONTENTTYPE]) {
              initHeader(CONTENTTYPE, xmlData ? 'text/xml' : 'application/json');
            }

            data = xmlData || (!Ext.isPrimitive(jsonData) ? Ext.encode(jsonData) : jsonData);
          }
        }

        return asyncRequest(method || options.method || "POST", uri, cb, data);
      },
      serializeForm: function serializeForm(form) {
        var fElements = form.elements || (document.forms[form] || Ext.getDom(form)).elements,
            hasSubmit = false,
            encoder = encodeURIComponent,
            element,
            options,
            name,
            val,
            data = '',
            type;
        Ext.each(fElements, function (element) {
          name = element.name;
          type = element.type;

          if (!element.disabled && name) {
            if (/select-(one|multiple)/i.test(type)) {
              Ext.each(element.options, function (opt) {
                if (opt.selected) {
                  data += String.format("{0}={1}&", encoder(name), encoder((opt.hasAttribute ? opt.hasAttribute('value') : opt.getAttribute('value') !== null) ? opt.value : opt.text));
                }
              });
            } else if (!/file|undefined|reset|button/i.test(type)) {
              if (!(/radio|checkbox/i.test(type) && !element.checked) && !(type == 'submit' && hasSubmit)) {
                data += encoder(name) + '=' + encoder(element.value) + '&';
                hasSubmit = /submit/i.test(type);
              }
            }
          }
        });
        return data.substr(0, data.length - 1);
      },
      useDefaultHeader: true,
      defaultPostHeader: 'application/x-www-form-urlencoded; charset=UTF-8',
      useDefaultXhrHeader: true,
      defaultXhrHeader: 'XMLHttpRequest',
      poll: {},
      timeout: {},
      pollInterval: 50,
      transactionId: 0,
      //  This is never called - Is it worth exposing this?
      //          setProgId : function(id) {
      //              activeX.unshift(id);
      //          },
      //  This is never called - Is it worth exposing this?
      //          setDefaultPostHeader : function(b) {
      //              this.useDefaultHeader = b;
      //          },
      //  This is never called - Is it worth exposing this?
      //          setDefaultXhrHeader : function(b) {
      //              this.useDefaultXhrHeader = b;
      //          },
      //  This is never called - Is it worth exposing this?
      //          setPollingInterval : function(i) {
      //              if (typeof i == 'number' && isFinite(i)) {
      //                  this.pollInterval = i;
      //              }
      //          },
      //  This is never called - Is it worth exposing this?
      //          resetDefaultHeaders : function() {
      //              this.defaultHeaders = null;
      //          },
      abort: function abort(o, callback, isTimeout) {
        var me = this,
            tId = o.tId,
            isAbort = false;

        if (me.isCallInProgress(o)) {
          o.conn.abort();
          clearInterval(me.poll[tId]);
          me.poll[tId] = null;
          clearTimeout(pub.timeout[tId]);
          me.timeout[tId] = null;
          handleTransactionResponse(o, callback, isAbort = true, isTimeout);
        }

        return isAbort;
      },
      isCallInProgress: function isCallInProgress(o) {
        // if there is a connection and readyState is not 0 or 4
        return o.conn && !{
          0: true,
          4: true
        }[o.conn.readyState];
      }
    };
    return pub;
  }(); // require('./core/ext-base-region');


  Ext.lib.Region = function (t, r, b, l) {
    var me = this;
    me.top = t;
    me[1] = t;
    me.right = r;
    me.bottom = b;
    me.left = l;
    me[0] = l;
  };

  Ext.lib.Region.prototype = {
    contains: function contains(region) {
      var me = this;
      return region.left >= me.left && region.right <= me.right && region.top >= me.top && region.bottom <= me.bottom;
    },
    getArea: function getArea() {
      var me = this;
      return (me.bottom - me.top) * (me.right - me.left);
    },
    intersect: function intersect(region) {
      var me = this,
          t = Math.max(me.top, region.top),
          r = Math.min(me.right, region.right),
          b = Math.min(me.bottom, region.bottom),
          l = Math.max(me.left, region.left);

      if (b >= t && r >= l) {
        return new Ext.lib.Region(t, r, b, l);
      }
    },
    union: function union(region) {
      var me = this,
          t = Math.min(me.top, region.top),
          r = Math.max(me.right, region.right),
          b = Math.max(me.bottom, region.bottom),
          l = Math.min(me.left, region.left);
      return new Ext.lib.Region(t, r, b, l);
    },
    constrainTo: function constrainTo(r) {
      var me = this;
      me.top = me.top.constrain(r.top, r.bottom);
      me.bottom = me.bottom.constrain(r.top, r.bottom);
      me.left = me.left.constrain(r.left, r.right);
      me.right = me.right.constrain(r.left, r.right);
      return me;
    },
    adjust: function adjust(t, l, b, r) {
      var me = this;
      me.top += t;
      me.left += l;
      me.right += r;
      me.bottom += b;
      return me;
    }
  };

  Ext.lib.Region.getRegion = function (el) {
    var p = Ext.lib.Dom.getXY(el),
        t = p[1],
        r = p[0] + el.offsetWidth,
        b = p[1] + el.offsetHeight,
        l = p[0];
    return new Ext.lib.Region(t, r, b, l);
  }; // require('./core/ext-base-point');


  Ext.lib.Point = function (x, y) {
    if (Ext.isArray(x)) {
      y = x[1];
      x = x[0];
    }

    var me = this;
    me.x = me.right = me.left = me[0] = x;
    me.y = me.top = me.bottom = me[1] = y;
  };

  Ext.lib.Point.prototype = new Ext.lib.Region(); // require('./core/ext-base-anim');

  (function () {
    var EXTLIB = Ext.lib,
        noNegatives = /width|height|opacity|padding/i,
        offsetAttribute = /^((width|height)|(top|left))$/,
        defaultUnit = /width|height|top$|bottom$|left$|right$/i,
        offsetUnit = /\d+(em|%|en|ex|pt|in|cm|mm|pc)$/i,
        isset = function isset(v) {
      return typeof v !== 'undefined';
    },
        now = function now() {
      return new Date();
    };

    EXTLIB.Anim = {
      motion: function motion(el, args, duration, easing, cb, scope) {
        return this.run(el, args, duration, easing, cb, scope, Ext.lib.Motion);
      },
      run: function run(el, args, duration, easing, cb, scope, type) {
        type = type || Ext.lib.AnimBase;

        if (typeof easing == "string") {
          easing = Ext.lib.Easing[easing];
        }

        var anim = new type(el, args, duration, easing);
        anim.animateX(function () {
          if (Ext.isFunction(cb)) {
            cb.call(scope);
          }
        });
        return anim;
      }
    };

    EXTLIB.AnimBase = function (el, attributes, duration, method) {
      if (el) {
        this.init(el, attributes, duration, method);
      }
    };

    EXTLIB.AnimBase.prototype = {
      doMethod: function doMethod(attr, start, end) {
        var me = this;
        return me.method(me.curFrame, start, end - start, me.totalFrames);
      },
      setAttr: function setAttr(attr, val, unit) {
        if (noNegatives.test(attr) && val < 0) {
          val = 0;
        }

        Ext.fly(this.el, '_anim').setStyle(attr, val + unit);
      },
      getAttr: function getAttr(attr) {
        var el = Ext.fly(this.el),
            val = el.getStyle(attr),
            a = offsetAttribute.exec(attr) || [];

        if (val !== 'auto' && !offsetUnit.test(val)) {
          return parseFloat(val);
        }

        return !!a[2] || el.getStyle('position') == 'absolute' && !!a[3] ? el.dom['offset' + a[0].charAt(0).toUpperCase() + a[0].substr(1)] : 0;
      },
      getDefaultUnit: function getDefaultUnit(attr) {
        return defaultUnit.test(attr) ? 'px' : '';
      },
      animateX: function animateX(callback, scope) {
        var me = this,
            f = function f() {
          me.onComplete.removeListener(f);

          if (Ext.isFunction(callback)) {
            callback.call(scope || me, me);
          }
        };

        me.onComplete.addListener(f, me);
        me.animate();
      },
      setRunAttr: function setRunAttr(attr) {
        var me = this,
            a = this.attributes[attr],
            to = a.to,
            by = a.by,
            from = a.from,
            unit = a.unit,
            ra = this.runAttrs[attr] = {},
            end;

        if (!isset(to) && !isset(by)) {
          return false;
        }

        var start = isset(from) ? from : me.getAttr(attr);

        if (isset(to)) {
          end = to;
        } else if (isset(by)) {
          if (Ext.isArray(start)) {
            end = [];

            for (var i = 0, len = start.length; i < len; i++) {
              end[i] = start[i] + by[i];
            }
          } else {
            end = start + by;
          }
        }

        Ext.apply(ra, {
          start: start,
          end: end,
          unit: isset(unit) ? unit : me.getDefaultUnit(attr)
        });
      },
      init: function init(el, attributes, duration, method) {
        var me = this,
            actualFrames = 0,
            mgr = EXTLIB.AnimMgr;
        Ext.apply(me, {
          isAnimated: false,
          startTime: null,
          el: Ext.getDom(el),
          attributes: attributes || {},
          duration: duration || 1,
          method: method || EXTLIB.Easing.easeNone,
          useSec: true,
          curFrame: 0,
          totalFrames: mgr.fps,
          runAttrs: {},
          animate: function animate() {
            var me = this,
                d = me.duration;

            if (me.isAnimated) {
              return false;
            }

            me.curFrame = 0;
            me.totalFrames = me.useSec ? Math.ceil(mgr.fps * d) : d;
            mgr.registerElement(me);
          },
          stop: function stop(finish) {
            var me = this;

            if (finish) {
              me.curFrame = me.totalFrames;

              me._onTween.fire();
            }

            mgr.stop(me);
          }
        });

        var onStart = function onStart() {
          var me = this,
              attr;
          me.onStart.fire();
          me.runAttrs = {};

          for (attr in this.attributes) {
            this.setRunAttr(attr);
          }

          me.isAnimated = true;
          me.startTime = now();
          actualFrames = 0;
        };

        var onTween = function onTween() {
          var me = this;
          me.onTween.fire({
            duration: now() - me.startTime,
            curFrame: me.curFrame
          });
          var ra = me.runAttrs;

          for (var attr in ra) {
            this.setAttr(attr, me.doMethod(attr, ra[attr].start, ra[attr].end), ra[attr].unit);
          }

          ++actualFrames;
        };

        var onComplete = function onComplete() {
          var me = this,
              actual = (now() - me.startTime) / 1000,
              data = {
            duration: actual,
            frames: actualFrames,
            fps: actualFrames / actual
          };
          me.isAnimated = false;
          actualFrames = 0;
          me.onComplete.fire(data);
        };

        me.onStart = new Ext.util.Event(me);
        me.onTween = new Ext.util.Event(me);
        me.onComplete = new Ext.util.Event(me);
        (me._onStart = new Ext.util.Event(me)).addListener(onStart);
        (me._onTween = new Ext.util.Event(me)).addListener(onTween);
        (me._onComplete = new Ext.util.Event(me)).addListener(onComplete);
      }
    };
    Ext.lib.AnimMgr = new function () {
      var me = this,
          thread = null,
          queue = [],
          tweenCount = 0;
      Ext.apply(me, {
        fps: 1000,
        delay: 1,
        registerElement: function registerElement(tween) {
          queue.push(tween);
          ++tweenCount;

          tween._onStart.fire();

          me.start();
        },
        unRegister: function unRegister(tween, index) {
          tween._onComplete.fire();

          index = index || getIndex(tween);

          if (index != -1) {
            queue.splice(index, 1);
          }

          if (--tweenCount <= 0) {
            me.stop();
          }
        },
        start: function start() {
          if (thread === null) {
            thread = setInterval(me.run, me.delay);
          }
        },
        stop: function stop(tween) {
          if (!tween) {
            clearInterval(thread);

            for (var i = 0, len = queue.length; i < len; ++i) {
              if (queue[0].isAnimated) {
                me.unRegister(queue[0], 0);
              }
            }

            queue = [];
            thread = null;
            tweenCount = 0;
          } else {
            me.unRegister(tween);
          }
        },
        run: function run() {
          var tf, i, len, tween;

          for (i = 0, len = queue.length; i < len; i++) {
            tween = queue[i];

            if (tween && tween.isAnimated) {
              tf = tween.totalFrames;

              if (tween.curFrame < tf || tf === null) {
                ++tween.curFrame;

                if (tween.useSec) {
                  correctFrame(tween);
                }

                tween._onTween.fire();
              } else {
                me.stop(tween);
              }
            }
          }
        }
      });

      var getIndex = function getIndex(anim) {
        var i, len;

        for (i = 0, len = queue.length; i < len; i++) {
          if (queue[i] === anim) {
            return i;
          }
        }

        return -1;
      };

      var correctFrame = function correctFrame(tween) {
        var frames = tween.totalFrames,
            frame = tween.curFrame,
            duration = tween.duration,
            expected = frame * duration * 1000 / frames,
            elapsed = now() - tween.startTime,
            tweak = 0;

        if (elapsed < duration * 1000) {
          tweak = Math.round((elapsed / expected - 1) * frame);
        } else {
          tweak = frames - (frame + 1);
        }

        if (tweak > 0 && isFinite(tweak)) {
          if (tween.curFrame + tweak >= frames) {
            tweak = frames - (frame + 1);
          }

          tween.curFrame += tweak;
        }
      };
    }();
    EXTLIB.Bezier = new function () {
      this.getPosition = function (points, t) {
        var n = points.length,
            tmp = [],
            c = 1 - t,
            i,
            j;

        for (i = 0; i < n; ++i) {
          tmp[i] = [points[i][0], points[i][1]];
        }

        for (j = 1; j < n; ++j) {
          for (i = 0; i < n - j; ++i) {
            tmp[i][0] = c * tmp[i][0] + t * tmp[parseInt(i + 1, 10)][0];
            tmp[i][1] = c * tmp[i][1] + t * tmp[parseInt(i + 1, 10)][1];
          }
        }

        return [tmp[0][0], tmp[0][1]];
      };
    }();
    EXTLIB.Easing = {
      easeNone: function easeNone(t, b, c, d) {
        return c * t / d + b;
      },
      easeIn: function easeIn(t, b, c, d) {
        return c * (t /= d) * t + b;
      },
      easeOut: function easeOut(t, b, c, d) {
        return -c * (t /= d) * (t - 2) + b;
      }
    };

    (function () {
      EXTLIB.Motion = function (el, attributes, duration, method) {
        if (el) {
          EXTLIB.Motion.superclass.constructor.call(this, el, attributes, duration, method);
        }
      };

      Ext.extend(EXTLIB.Motion, Ext.lib.AnimBase);
      var superclass = EXTLIB.Motion.superclass,
          proto = EXTLIB.Motion.prototype,
          pointsRe = /^points$/i;
      Ext.apply(EXTLIB.Motion.prototype, {
        setAttr: function setAttr(attr, val, unit) {
          var me = this,
              setAttr = superclass.setAttr;

          if (pointsRe.test(attr)) {
            unit = unit || 'px';
            setAttr.call(me, 'left', val[0], unit);
            setAttr.call(me, 'top', val[1], unit);
          } else {
            setAttr.call(me, attr, val, unit);
          }
        },
        getAttr: function getAttr(attr) {
          var me = this,
              getAttr = superclass.getAttr;
          return pointsRe.test(attr) ? [getAttr.call(me, 'left'), getAttr.call(me, 'top')] : getAttr.call(me, attr);
        },
        doMethod: function doMethod(attr, start, end) {
          var me = this;
          return pointsRe.test(attr) ? EXTLIB.Bezier.getPosition(me.runAttrs[attr], me.method(me.curFrame, 0, 100, me.totalFrames) / 100) : superclass.doMethod.call(me, attr, start, end);
        },
        setRunAttr: function setRunAttr(attr) {
          if (pointsRe.test(attr)) {
            var me = this,
                el = this.el,
                points = this.attributes.points,
                control = points.control || [],
                from = points.from,
                to = points.to,
                by = points.by,
                DOM = EXTLIB.Dom,
                start,
                i,
                end,
                len,
                ra;

            if (control.length > 0 && !Ext.isArray(control[0])) {
              control = [control];
            } else {
              /*
              var tmp = [];
              for (i = 0,len = control.length; i < len; ++i) {
                  tmp[i] = control[i];
              }
              control = tmp;
              */
            }

            Ext.fly(el, '_anim').position();
            DOM.setXY(el, isset(from) ? from : DOM.getXY(el));
            start = me.getAttr('points');

            if (isset(to)) {
              end = translateValues.call(me, to, start);

              for (i = 0, len = control.length; i < len; ++i) {
                control[i] = translateValues.call(me, control[i], start);
              }
            } else if (isset(by)) {
              end = [start[0] + by[0], start[1] + by[1]];

              for (i = 0, len = control.length; i < len; ++i) {
                control[i] = [start[0] + control[i][0], start[1] + control[i][1]];
              }
            }

            ra = this.runAttrs[attr] = [start];

            if (control.length > 0) {
              ra = ra.concat(control);
            }

            ra[ra.length] = end;
          } else {
            superclass.setRunAttr.call(this, attr);
          }
        }
      });

      var translateValues = function translateValues(val, start) {
        var pageXY = EXTLIB.Dom.getXY(this.el);
        return [val[0] - pageXY[0] + start[0], val[1] - pageXY[1] + start[1]];
      };
    })();
  })(); // require('./core/ext-base-anim-extra');
  // Easing functions


  (function () {
    // shortcuts to aid compression
    var abs = Math.abs,
        pi = Math.PI,
        asin = Math.asin,
        pow = Math.pow,
        sin = Math.sin,
        EXTLIB = Ext.lib;
    Ext.apply(EXTLIB.Easing, {
      easeBoth: function easeBoth(t, b, c, d) {
        return (t /= d / 2) < 1 ? c / 2 * t * t + b : -c / 2 * (--t * (t - 2) - 1) + b;
      },
      easeInStrong: function easeInStrong(t, b, c, d) {
        return c * (t /= d) * t * t * t + b;
      },
      easeOutStrong: function easeOutStrong(t, b, c, d) {
        return -c * ((t = t / d - 1) * t * t * t - 1) + b;
      },
      easeBothStrong: function easeBothStrong(t, b, c, d) {
        return (t /= d / 2) < 1 ? c / 2 * t * t * t * t + b : -c / 2 * ((t -= 2) * t * t * t - 2) + b;
      },
      elasticIn: function elasticIn(t, b, c, d, a, p) {
        if (t == 0 || (t /= d) == 1) {
          return t == 0 ? b : b + c;
        }

        p = p || d * .3;
        var s;

        if (a >= abs(c)) {
          s = p / (2 * pi) * asin(c / a);
        } else {
          a = c;
          s = p / 4;
        }

        return -(a * pow(2, 10 * (t -= 1)) * sin((t * d - s) * (2 * pi) / p)) + b;
      },
      elasticOut: function elasticOut(t, b, c, d, a, p) {
        if (t == 0 || (t /= d) == 1) {
          return t == 0 ? b : b + c;
        }

        p = p || d * .3;
        var s;

        if (a >= abs(c)) {
          s = p / (2 * pi) * asin(c / a);
        } else {
          a = c;
          s = p / 4;
        }

        return a * pow(2, -10 * t) * sin((t * d - s) * (2 * pi) / p) + c + b;
      },
      elasticBoth: function elasticBoth(t, b, c, d, a, p) {
        if (t == 0 || (t /= d / 2) == 2) {
          return t == 0 ? b : b + c;
        }

        p = p || d * (.3 * 1.5);
        var s;

        if (a >= abs(c)) {
          s = p / (2 * pi) * asin(c / a);
        } else {
          a = c;
          s = p / 4;
        }

        return t < 1 ? -.5 * (a * pow(2, 10 * (t -= 1)) * sin((t * d - s) * (2 * pi) / p)) + b : a * pow(2, -10 * (t -= 1)) * sin((t * d - s) * (2 * pi) / p) * .5 + c + b;
      },
      backIn: function backIn(t, b, c, d, s) {
        s = s || 1.70158;
        return c * (t /= d) * t * ((s + 1) * t - s) + b;
      },
      backOut: function backOut(t, b, c, d, s) {
        if (!s) {
          s = 1.70158;
        }

        return c * ((t = t / d - 1) * t * ((s + 1) * t + s) + 1) + b;
      },
      backBoth: function backBoth(t, b, c, d, s) {
        s = s || 1.70158;
        return (t /= d / 2) < 1 ? c / 2 * (t * t * (((s *= 1.525) + 1) * t - s)) + b : c / 2 * ((t -= 2) * t * (((s *= 1.525) + 1) * t + s) + 2) + b;
      },
      bounceIn: function bounceIn(t, b, c, d) {
        return c - EXTLIB.Easing.bounceOut(d - t, 0, c, d) + b;
      },
      bounceOut: function bounceOut(t, b, c, d) {
        if ((t /= d) < 1 / 2.75) {
          return c * (7.5625 * t * t) + b;
        } else if (t < 2 / 2.75) {
          return c * (7.5625 * (t -= 1.5 / 2.75) * t + .75) + b;
        } else if (t < 2.5 / 2.75) {
          return c * (7.5625 * (t -= 2.25 / 2.75) * t + .9375) + b;
        }

        return c * (7.5625 * (t -= 2.625 / 2.75) * t + .984375) + b;
      },
      bounceBoth: function bounceBoth(t, b, c, d) {
        return t < d / 2 ? EXTLIB.Easing.bounceIn(t * 2, 0, c, d) * .5 + b : EXTLIB.Easing.bounceOut(t * 2 - d, 0, c, d) * .5 + c * .5 + b;
      }
    });
  })();

  (function () {
    var EXTLIB = Ext.lib; // Color Animation

    EXTLIB.Anim.color = function (el, args, duration, easing, cb, scope) {
      return EXTLIB.Anim.run(el, args, duration, easing, cb, scope, EXTLIB.ColorAnim);
    };

    EXTLIB.ColorAnim = function (el, attributes, duration, method) {
      EXTLIB.ColorAnim.superclass.constructor.call(this, el, attributes, duration, method);
    };

    Ext.extend(EXTLIB.ColorAnim, EXTLIB.AnimBase);

    var superclass = EXTLIB.ColorAnim.superclass,
        colorRE = /color$/i,
        transparentRE = /^transparent|rgba\(0, 0, 0, 0\)$/,
        rgbRE = /^rgb\(([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\)$/i,
        hexRE = /^#?([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})$/i,
        hex3RE = /^#?([0-9A-F]{1})([0-9A-F]{1})([0-9A-F]{1})$/i,
        isset = function isset(v) {
      return typeof v !== 'undefined';
    }; // private


    function parseColor(s) {
      var pi = parseInt,
          base,
          out = null,
          c;

      if (s.length == 3) {
        return s;
      }

      Ext.each([hexRE, rgbRE, hex3RE], function (re, idx) {
        base = idx % 2 == 0 ? 16 : 10;
        c = re.exec(s);

        if (c && c.length == 4) {
          out = [pi(c[1], base), pi(c[2], base), pi(c[3], base)];
          return false;
        }
      });
      return out;
    }

    Ext.apply(EXTLIB.ColorAnim.prototype, {
      getAttr: function getAttr(attr) {
        var me = this,
            el = me.el,
            val;

        if (colorRE.test(attr)) {
          while (el && transparentRE.test(val = Ext.fly(el).getStyle(attr))) {
            el = el.parentNode;
            val = "fff";
          }
        } else {
          val = superclass.getAttr.call(me, attr);
        }

        return val;
      },
      doMethod: function doMethod(attr, start, end) {
        var me = this,
            val,
            floor = Math.floor,
            i,
            len,
            v;

        if (colorRE.test(attr)) {
          val = [];

          for (i = 0, len = start.length; i < len; i++) {
            v = start[i];
            val[i] = superclass.doMethod.call(me, attr, v, end[i]);
          }

          val = 'rgb(' + floor(val[0]) + ',' + floor(val[1]) + ',' + floor(val[2]) + ')';
        } else {
          val = superclass.doMethod.call(me, attr, start, end);
        }

        return val;
      },
      setRunAttr: function setRunAttr(attr) {
        var me = this,
            a = me.attributes[attr],
            to = a.to,
            by = a.by,
            ra;
        superclass.setRunAttr.call(me, attr);
        ra = me.runAttrs[attr];

        if (colorRE.test(attr)) {
          var start = parseColor(ra.start),
              end = parseColor(ra.end);

          if (!isset(to) && isset(by)) {
            end = parseColor(by);

            for (var i = 0, len = start.length; i < len; i++) {
              end[i] = start[i] + end[i];
            }
          }

          ra.start = start;
          ra.end = end;
        }
      }
    });
  })();

  (function () {
    // Scroll Animation
    var EXTLIB = Ext.lib;

    EXTLIB.Anim.scroll = function (el, args, duration, easing, cb, scope) {
      return EXTLIB.Anim.run(el, args, duration, easing, cb, scope, EXTLIB.Scroll);
    };

    EXTLIB.Scroll = function (el, attributes, duration, method) {
      if (el) {
        EXTLIB.Scroll.superclass.constructor.call(this, el, attributes, duration, method);
      }
    };

    Ext.extend(EXTLIB.Scroll, EXTLIB.ColorAnim);
    var superclass = EXTLIB.Scroll.superclass,
        SCROLL = 'scroll';
    Ext.apply(EXTLIB.Scroll.prototype, {
      doMethod: function doMethod(attr, start, end) {
        var val,
            me = this,
            curFrame = me.curFrame,
            totalFrames = me.totalFrames;

        if (attr == SCROLL) {
          val = [me.method(curFrame, start[0], end[0] - start[0], totalFrames), me.method(curFrame, start[1], end[1] - start[1], totalFrames)];
        } else {
          val = superclass.doMethod.call(me, attr, start, end);
        }

        return val;
      },
      getAttr: function getAttr(attr) {
        var me = this;

        if (attr == SCROLL) {
          return [me.el.scrollLeft, me.el.scrollTop];
        } else {
          return superclass.getAttr.call(me, attr);
        }
      },
      setAttr: function setAttr(attr, val, unit) {
        var me = this;

        if (attr == SCROLL) {
          me.el.scrollLeft = val[0];
          me.el.scrollTop = val[1];
        } else {
          superclass.setAttr.call(me, attr, val, unit);
        }
      }
    });
  })();

  if (Ext.isIE) {
    function fnCleanUp() {
      var p = Function.prototype;
      delete p.createSequence;
      delete p.defer;
      delete p.createDelegate;
      delete p.createCallback;
      delete p.createInterceptor;
      window.detachEvent("onunload", fnCleanUp);
    }

    window.attachEvent("onunload", fnCleanUp);
  }
})();

/***/ }),
/* 706 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.DomHelper
 * <p>The DomHelper class provides a layer of abstraction from DOM and transparently supports creating
 * elements via DOM or using HTML fragments. It also has the ability to create HTML fragment templates
 * from your DOM building code.</p>
 *
 * <p><b><u>DomHelper element specification object</u></b></p>
 * <p>A specification object is used when creating elements. Attributes of this object
 * are assumed to be element attributes, except for 4 special attributes:
 * <div class="mdetail-params"><ul>
 * <li><b><tt>tag</tt></b> : <div class="sub-desc">The tag name of the element</div></li>
 * <li><b><tt>children</tt></b> : or <tt>cn</tt><div class="sub-desc">An array of the
 * same kind of element definition objects to be created and appended. These can be nested
 * as deep as you want.</div></li>
 * <li><b><tt>cls</tt></b> : <div class="sub-desc">The class attribute of the element.
 * This will end up being either the "class" attribute on a HTML fragment or className
 * for a DOM node, depending on whether DomHelper is using fragments or DOM.</div></li>
 * <li><b><tt>html</tt></b> : <div class="sub-desc">The innerHTML for the element</div></li>
 * </ul></div></p>
 *
 * <p><b><u>Insertion methods</u></b></p>
 * <p>Commonly used insertion methods:
 * <div class="mdetail-params"><ul>
 * <li><b><tt>{@link #append}</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>{@link #insertBefore}</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>{@link #insertAfter}</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>{@link #overwrite}</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>{@link #createTemplate}</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>{@link #insertHtml}</tt></b> : <div class="sub-desc"></div></li>
 * </ul></div></p>
 *
 * <p><b><u>Example</u></b></p>
 * <p>This is an example, where an unordered list with 3 children items is appended to an existing
 * element with id <tt>'my-div'</tt>:<br>
 <pre><code>
var dh = Ext.DomHelper; // create shorthand alias
// specification object
var spec = {
    id: 'my-ul',
    tag: 'ul',
    cls: 'my-list',
    // append children after creating
    children: [     // may also specify 'cn' instead of 'children'
        {tag: 'li', id: 'item0', html: 'List Item 0'},
        {tag: 'li', id: 'item1', html: 'List Item 1'},
        {tag: 'li', id: 'item2', html: 'List Item 2'}
    ]
};
var list = dh.append(
    'my-div', // the context element 'my-div' can either be the id or the actual node
    spec      // the specification object
);
 </code></pre></p>
 * <p>Element creation specification parameters in this class may also be passed as an Array of
 * specification objects. This can be used to insert multiple sibling nodes into an existing
 * container very efficiently. For example, to add more list items to the example above:<pre><code>
dh.append('my-ul', [
    {tag: 'li', id: 'item3', html: 'List Item 3'},
    {tag: 'li', id: 'item4', html: 'List Item 4'}
]);
 * </code></pre></p>
 *
 * <p><b><u>Templating</u></b></p>
 * <p>The real power is in the built-in templating. Instead of creating or appending any elements,
 * <tt>{@link #createTemplate}</tt> returns a Template object which can be used over and over to
 * insert new elements. Revisiting the example above, we could utilize templating this time:
 * <pre><code>
// create the node
var list = dh.append('my-div', {tag: 'ul', cls: 'my-list'});
// get template
var tpl = dh.createTemplate({tag: 'li', id: 'item{0}', html: 'List Item {0}'});

for(var i = 0; i < 5, i++){
    tpl.append(list, [i]); // use template to append to the actual node
}
 * </code></pre></p>
 * <p>An example using a template:<pre><code>
var html = '<a id="{0}" href="{1}" class="nav">{2}</a>';

var tpl = new Ext.DomHelper.createTemplate(html);
tpl.append('blog-roll', ['link1', 'http://www.jackslocum.com/', "Jack&#39;s Site"]);
tpl.append('blog-roll', ['link2', 'http://www.dustindiaz.com/', "Dustin&#39;s Site"]);
 * </code></pre></p>
 *
 * <p>The same example using named parameters:<pre><code>
var html = '<a id="{id}" href="{url}" class="nav">{text}</a>';

var tpl = new Ext.DomHelper.createTemplate(html);
tpl.append('blog-roll', {
    id: 'link1',
    url: 'http://www.jackslocum.com/',
    text: "Jack&#39;s Site"
});
tpl.append('blog-roll', {
    id: 'link2',
    url: 'http://www.dustindiaz.com/',
    text: "Dustin&#39;s Site"
});
 * </code></pre></p>
 *
 * <p><b><u>Compiling Templates</u></b></p>
 * <p>Templates are applied using regular expressions. The performance is great, but if
 * you are adding a bunch of DOM elements using the same template, you can increase
 * performance even further by {@link Ext.Template#compile "compiling"} the template.
 * The way "{@link Ext.Template#compile compile()}" works is the template is parsed and
 * broken up at the different variable points and a dynamic function is created and eval'ed.
 * The generated function performs string concatenation of these parts and the passed
 * variables instead of using regular expressions.
 * <pre><code>
var html = '<a id="{id}" href="{url}" class="nav">{text}</a>';

var tpl = new Ext.DomHelper.createTemplate(html);
tpl.compile();

//... use template like normal
 * </code></pre></p>
 *
 * <p><b><u>Performance Boost</u></b></p>
 * <p>DomHelper will transparently create HTML fragments when it can. Using HTML fragments instead
 * of DOM can significantly boost performance.</p>
 * <p>Element creation specification parameters may also be strings. If {@link #useDom} is <tt>false</tt>,
 * then the string is used as innerHTML. If {@link #useDom} is <tt>true</tt>, a string specification
 * results in the creation of a text node. Usage:</p>
 * <pre><code>
Ext.DomHelper.useDom = true; // force it to use DOM; reduces performance
 * </code></pre>
 * @singleton
 */
Ext.DomHelper = function () {
  var tempTableEl = null,
      emptyTags = /^(?:br|frame|hr|img|input|link|meta|range|spacer|wbr|area|param|col)$/i,
      tableRe = /^table|tbody|tr|td$/i,
      pub,
      // kill repeat to save bytes
  afterbegin = 'afterbegin',
      afterend = 'afterend',
      beforebegin = 'beforebegin',
      beforeend = 'beforeend',
      ts = '<table>',
      te = '</table>',
      tbs = ts + '<tbody>',
      tbe = '</tbody>' + te,
      trs = tbs + '<tr>',
      tre = '</tr>' + tbe; // private

  function doInsert(el, o, returnElement, pos, sibling, append) {
    var newNode = pub.insertHtml(pos, Ext.getDom(el), createHtml(o));
    return returnElement ? Ext.get(newNode, true) : newNode;
  } // build as innerHTML where available


  function createHtml(o) {
    var b = '',
        attr,
        val,
        key,
        keyVal,
        cn;

    if (Ext.isString(o)) {
      b = o;
    } else if (Ext.isArray(o)) {
      for (var i = 0; i < o.length; i++) {
        if (o[i]) {
          b += createHtml(o[i]);
        }
      }

      ;
    } else {
      b += '<' + (o.tag = o.tag || 'div');
      Ext.iterate(o, function (attr, val) {
        if (!/tag|children|cn|html$/i.test(attr)) {
          if (Ext.isObject(val)) {
            b += ' ' + attr + '="';
            Ext.iterate(val, function (key, keyVal) {
              b += key + ':' + keyVal + ';';
            });
            b += '"';
          } else {
            b += ' ' + ({
              cls: 'class',
              htmlFor: 'for'
            }[attr] || attr) + '="' + val + '"';
          }
        }
      }); // Now either just close the tag or try to add children and close the tag.

      if (emptyTags.test(o.tag)) {
        b += '/>';
      } else {
        b += '>';

        if (cn = o.children || o.cn) {
          b += createHtml(cn);
        } else if (o.html) {
          b += o.html;
        }

        b += '</' + o.tag + '>';
      }
    }

    return b;
  }

  function ieTable(depth, s, h, e) {
    tempTableEl.innerHTML = [s, h, e].join('');
    var i = -1,
        el = tempTableEl,
        ns;

    while (++i < depth) {
      el = el.firstChild;
    } //      If the result is multiple siblings, then encapsulate them into one fragment.


    if (ns = el.nextSibling) {
      var df = document.createDocumentFragment();

      while (el) {
        ns = el.nextSibling;
        df.appendChild(el);
        el = ns;
      }

      el = df;
    }

    return el;
  }
  /**
   * @ignore
   * Nasty code for IE's broken table implementation
   */


  function insertIntoTable(tag, where, el, html) {
    var node, before;
    tempTableEl = tempTableEl || document.createElement('div');

    if (tag == 'td' && (where == afterbegin || where == beforeend) || !/td|tr|tbody/i.test(tag) && (where == beforebegin || where == afterend)) {
      return;
    }

    before = where == beforebegin ? el : where == afterend ? el.nextSibling : where == afterbegin ? el.firstChild : null;

    if (where == beforebegin || where == afterend) {
      el = el.parentNode;
    }

    if (tag == 'td' || tag == 'tr' && (where == beforeend || where == afterbegin)) {
      node = ieTable(4, trs, html, tre);
    } else if (tag == 'tbody' && (where == beforeend || where == afterbegin) || tag == 'tr' && (where == beforebegin || where == afterend)) {
      node = ieTable(3, tbs, html, tbe);
    } else {
      node = ieTable(2, ts, html, te);
    }

    el.insertBefore(node, before);
    return node;
  }

  pub = {
    /**
     * Returns the markup for the passed Element(s) config.
     * @param {Object} o The DOM object spec (and children)
     * @return {String}
     */
    markup: function markup(o) {
      return createHtml(o);
    },

    /**
     * Applies a style specification to an element.
     * @param {String/HTMLElement} el The element to apply styles to
     * @param {String/Object/Function} styles A style specification string e.g. 'width:100px', or object in the form {width:'100px'}, or
     * a function which returns such a specification.
     */
    applyStyles: function applyStyles(el, styles) {
      if (styles) {
        var i = 0,
            len,
            style;
        el = Ext.fly(el);

        if (Ext.isFunction(styles)) {
          styles = styles.call();
        }

        if (Ext.isString(styles)) {
          styles = styles.trim().split(/\s*(?::|;)\s*/);

          for (len = styles.length; i < len;) {
            el.setStyle(styles[i++], styles[i++]);
          }
        } else if (Ext.isObject(styles)) {
          el.setStyle(styles);
        }
      }
    },

    /**
     * Inserts an HTML fragment into the DOM.
     * @param {String} where Where to insert the html in relation to el - beforeBegin, afterBegin, beforeEnd, afterEnd.
     * @param {HTMLElement} el The context element
     * @param {String} html The HTML fragment
     * @return {HTMLElement} The new node
     */
    insertHtml: function insertHtml(where, el, html) {
      var hash = {},
          hashVal,
          setStart,
          range,
          frag,
          rangeEl,
          rs;
      where = where.toLowerCase(); // add these here because they are used in both branches of the condition.

      hash[beforebegin] = ['BeforeBegin', 'previousSibling'];
      hash[afterend] = ['AfterEnd', 'nextSibling'];

      if (el.insertAdjacentHTML) {
        if (tableRe.test(el.tagName) && (rs = insertIntoTable(el.tagName.toLowerCase(), where, el, html))) {
          return rs;
        } // add these two to the hash.


        hash[afterbegin] = ['AfterBegin', 'firstChild'];
        hash[beforeend] = ['BeforeEnd', 'lastChild'];

        if (hashVal = hash[where]) {
          el.insertAdjacentHTML(hashVal[0], html);
          return el[hashVal[1]];
        }
      } else {
        range = el.ownerDocument.createRange();
        setStart = 'setStart' + (/end/i.test(where) ? 'After' : 'Before');

        if (hash[where]) {
          range[setStart](el);
          frag = range.createContextualFragment(html);
          el.parentNode.insertBefore(frag, where == beforebegin ? el : el.nextSibling);
          return el[(where == beforebegin ? 'previous' : 'next') + 'Sibling'];
        } else {
          rangeEl = (where == afterbegin ? 'first' : 'last') + 'Child';

          if (el.firstChild) {
            range[setStart](el[rangeEl]);
            frag = range.createContextualFragment(html);

            if (where == afterbegin) {
              el.insertBefore(frag, el.firstChild);
            } else {
              el.appendChild(frag);
            }
          } else {
            el.innerHTML = html;
          }

          return el[rangeEl];
        }
      }

      throw 'Illegal insertion point -> "' + where + '"';
    },

    /**
     * Creates new DOM element(s) and inserts them before el.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
     */
    insertBefore: function insertBefore(el, o, returnElement) {
      return doInsert(el, o, returnElement, beforebegin);
    },

    /**
     * Creates new DOM element(s) and inserts them after el.
     * @param {Mixed} el The context element
     * @param {Object} o The DOM object spec (and children)
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
     */
    insertAfter: function insertAfter(el, o, returnElement) {
      return doInsert(el, o, returnElement, afterend, 'nextSibling');
    },

    /**
     * Creates new DOM element(s) and inserts them as the first child of el.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
     */
    insertFirst: function insertFirst(el, o, returnElement) {
      return doInsert(el, o, returnElement, afterbegin, 'firstChild');
    },

    /**
     * Creates new DOM element(s) and appends them to el.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
     */
    append: function append(el, o, returnElement) {
      return doInsert(el, o, returnElement, beforeend, '', true);
    },

    /**
     * Creates new DOM element(s) and overwrites the contents of el with them.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
     */
    overwrite: function overwrite(el, o, returnElement) {
      el = Ext.getDom(el);
      el.innerHTML = createHtml(o);
      return returnElement ? Ext.get(el.firstChild) : el.firstChild;
    },
    createHtml: createHtml
  };
  return pub;
}();

/***/ }),
/* 707 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.DomHelper
 */
Ext.apply(Ext.DomHelper, function () {
  var pub,
      afterbegin = 'afterbegin',
      afterend = 'afterend',
      beforebegin = 'beforebegin',
      beforeend = 'beforeend'; // private

  function doInsert(el, o, returnElement, pos, sibling, append) {
    el = Ext.getDom(el);
    var newNode;

    if (pub.useDom) {
      newNode = createDom(o, null);

      if (append) {
        el.appendChild(newNode);
      } else {
        (sibling == 'firstChild' ? el : el.parentNode).insertBefore(newNode, el[sibling] || el);
      }
    } else {
      newNode = Ext.DomHelper.insertHtml(pos, el, Ext.DomHelper.createHtml(o));
    }

    return returnElement ? Ext.get(newNode, true) : newNode;
  } // build as dom

  /** @ignore */


  function createDom(o, parentNode) {
    var el,
        doc = document,
        useSet,
        attr,
        val,
        cn;

    if (Ext.isArray(o)) {
      // Allow Arrays of siblings to be inserted
      el = doc.createDocumentFragment(); // in one shot using a DocumentFragment

      Ext.each(o, function (v) {
        createDom(v, el);
      });
    } else if (Ext.isString(o)) {
      // Allow a string as a child spec.
      el = doc.createTextNode(o);
    } else {
      el = doc.createElement(o.tag || 'div');
      useSet = !!el.setAttribute; // In IE some elements don't have setAttribute

      Ext.iterate(o, function (attr, val) {
        if (!/tag|children|cn|html|style/.test(attr)) {
          if (attr == 'cls') {
            el.className = val;
          } else {
            if (useSet) {
              el.setAttribute(attr, val);
            } else {
              el[attr] = val;
            }
          }
        }
      });
      Ext.DomHelper.applyStyles(el, o.style);

      if (cn = o.children || o.cn) {
        createDom(cn, el);
      } else if (o.html) {
        el.innerHTML = o.html;
      }
    }

    if (parentNode) {
      parentNode.appendChild(el);
    }

    return el;
  }

  pub = {
    /**
        * Creates a new Ext.Template from the DOM object spec.
        * @param {Object} o The DOM object spec (and children)
        * @return {Ext.Template} The new template
        */
    createTemplate: function createTemplate(o) {
      var html = Ext.DomHelper.createHtml(o);
      return new Ext.Template(html);
    },

    /** True to force the use of DOM instead of html fragments @type Boolean */
    useDom: false,

    /**
     * Creates new DOM element(s) and inserts them before el.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
        * @hide (repeat)
     */
    insertBefore: function insertBefore(el, o, returnElement) {
      return doInsert(el, o, returnElement, beforebegin);
    },

    /**
     * Creates new DOM element(s) and inserts them after el.
     * @param {Mixed} el The context element
     * @param {Object} o The DOM object spec (and children)
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
        * @hide (repeat)
     */
    insertAfter: function insertAfter(el, o, returnElement) {
      return doInsert(el, o, returnElement, afterend, 'nextSibling');
    },

    /**
     * Creates new DOM element(s) and inserts them as the first child of el.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
        * @hide (repeat)
     */
    insertFirst: function insertFirst(el, o, returnElement) {
      return doInsert(el, o, returnElement, afterbegin, 'firstChild');
    },

    /**
     * Creates new DOM element(s) and appends them to el.
     * @param {Mixed} el The context element
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @param {Boolean} returnElement (optional) true to return a Ext.Element
     * @return {HTMLElement/Ext.Element} The new node
        * @hide (repeat)
     */
    append: function append(el, o, returnElement) {
      return doInsert(el, o, returnElement, beforeend, '', true);
    },

    /**
     * Creates new DOM element(s) without inserting them to the document.
     * @param {Object/String} o The DOM object spec (and children) or raw HTML blob
     * @return {HTMLElement} The new uninserted node
     */
    createDom: createDom
  };
  return pub;
}());

/***/ }),
/* 708 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Template
 * <p>Represents an HTML fragment template. Templates may be {@link #compile precompiled}
 * for greater performance.</p>
 * <p>For example usage {@link #Template see the constructor}.</p>
 * 
 * @constructor
 * An instance of this class may be created by passing to the constructor either
 * a single argument, or multiple arguments:
 * <div class="mdetail-params"><ul>
 * <li><b>single argument</b> : String/Array
 * <div class="sub-desc">
 * The single argument may be either a String or an Array:<ul>
 * <li><tt>String</tt> : </li><pre><code>
var t = new Ext.Template("&lt;div>Hello {0}.&lt;/div>");
t.{@link #append}('some-element', ['foo']);
 * </code></pre>
 * <li><tt>Array</tt> : </li>
 * An Array will be combined with <code>join('')</code>.
<pre><code>
var t = new Ext.Template([
    '&lt;div name="{id}"&gt;',
        '&lt;span class="{cls}"&gt;{name:trim} {value:ellipsis(10)}&lt;/span&gt;',
    '&lt;/div&gt;',
]);
t.{@link #compile}();
t.{@link #append}('some-element', {id: 'myid', cls: 'myclass', name: 'foo', value: 'bar'});
</code></pre>
 * </ul></div></li>
 * <li><b>multiple arguments</b> : String, Object, Array, ...
 * <div class="sub-desc">
 * Multiple arguments will be combined with <code>join('')</code>.
 * <pre><code>
var t = new Ext.Template(
    '&lt;div name="{id}"&gt;',
        '&lt;span class="{cls}"&gt;{name} {value}&lt;/span&gt;',
    '&lt;/div&gt;',
    // a configuration object:
    {
        compiled: true,      // {@link #compile} immediately
        disableFormats: true // See Notes below.
    } 
);
 * </code></pre>
 * <p><b>Notes</b>:</p>
 * <div class="mdetail-params"><ul>
 * <li>Formatting and <code>disableFormats</code> are not applicable for Ext Core.</li>
 * <li>For a list of available format functions, see {@link Ext.util.Format}.</li>
 * <li><code>disableFormats</code> reduces <code>{@link #apply}</code> time
 * when no formatting is required.</li>
 * </ul></div>
 * </div></li>
 * </ul></div>
 * @param {Mixed} config
 */
Ext.Template = function (html) {
  var me = this,
      a = arguments,
      buf = [];

  if (Ext.isArray(html)) {
    html = html.join("");
  } else if (a.length > 1) {
    Ext.each(a, function (v) {
      if (Ext.isObject(v)) {
        Ext.apply(me, v);
      } else {
        buf.push(v);
      }
    });
    html = buf.join('');
  }
  /**@private*/


  me.html = html;
  /**
   * @cfg {Boolean} compiled Specify <tt>true</tt> to compile the template
   * immediately (see <code>{@link #compile}</code>).
   * Defaults to <tt>false</tt>.
   */

  if (me.compiled) {
    me.compile();
  }
};

Ext.Template.prototype = {
  /**
   * @cfg {RegExp} re The regular expression used to match template variables.
   * Defaults to:<pre><code>
   * re : /\{([\w-]+)\}/g                                     // for Ext Core
   * re : /\{([\w-]+)(?:\:([\w\.]*)(?:\((.*?)?\))?)?\}/g      // for Ext JS
   * </code></pre>
   */
  re: /\{([\w-]+)\}/g,

  /**
   * See <code>{@link #re}</code>.
   * @type RegExp
   * @property re
   */

  /**
   * Returns an HTML fragment of this template with the specified <code>values</code> applied.
   * @param {Object/Array} values
   * The template values. Can be an array if the params are numeric (i.e. <code>{0}</code>)
   * or an object (i.e. <code>{foo: 'bar'}</code>).
   * @return {String} The HTML fragment
   */
  applyTemplate: function applyTemplate(values) {
    var me = this;
    return me.compiled ? me.compiled(values) : me.html.replace(me.re, function (m, name) {
      return values[name] !== undefined ? values[name] : "";
    });
  },

  /**
   * Sets the HTML used as the template and optionally compiles it.
   * @param {String} html
   * @param {Boolean} compile (optional) True to compile the template (defaults to undefined)
   * @return {Ext.Template} this
   */
  set: function set(html, compile) {
    var me = this;
    me.html = html;
    me.compiled = null;
    return compile ? me.compile() : me;
  },

  /**
   * Compiles the template into an internal function, eliminating the RegEx overhead.
   * @return {Ext.Template} this
   */
  compile: function compile() {
    var me = this,
        sep = Ext.isGecko ? "+" : ",";

    function fn(m, name) {
      name = "values['" + name + "']";
      return "'" + sep + '(' + name + " == undefined ? '' : " + name + ')' + sep + "'";
    }

    eval("this.compiled = function(values){ return " + (Ext.isGecko ? "'" : "['") + me.html.replace(/\\/g, '\\\\').replace(/(\r\n|\n)/g, '\\n').replace(/'/g, "\\'").replace(this.re, fn) + (Ext.isGecko ? "';};" : "'].join('');};"));
    return me;
  },

  /**
   * Applies the supplied values to the template and inserts the new node(s) as the first child of el.
   * @param {Mixed} el The context element
   * @param {Object/Array} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
   * @param {Boolean} returnElement (optional) true to return a Ext.Element (defaults to undefined)
   * @return {HTMLElement/Ext.Element} The new node or Element
   */
  insertFirst: function insertFirst(el, values, returnElement) {
    return this.doInsert('afterBegin', el, values, returnElement);
  },

  /**
   * Applies the supplied values to the template and inserts the new node(s) before el.
   * @param {Mixed} el The context element
   * @param {Object/Array} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
   * @param {Boolean} returnElement (optional) true to return a Ext.Element (defaults to undefined)
   * @return {HTMLElement/Ext.Element} The new node or Element
   */
  insertBefore: function insertBefore(el, values, returnElement) {
    return this.doInsert('beforeBegin', el, values, returnElement);
  },

  /**
   * Applies the supplied values to the template and inserts the new node(s) after el.
   * @param {Mixed} el The context element
   * @param {Object/Array} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
   * @param {Boolean} returnElement (optional) true to return a Ext.Element (defaults to undefined)
   * @return {HTMLElement/Ext.Element} The new node or Element
   */
  insertAfter: function insertAfter(el, values, returnElement) {
    return this.doInsert('afterEnd', el, values, returnElement);
  },

  /**
   * Applies the supplied <code>values</code> to the template and appends
   * the new node(s) to the specified <code>el</code>.
   * <p>For example usage {@link #Template see the constructor}.</p>
   * @param {Mixed} el The context element
   * @param {Object/Array} values
   * The template values. Can be an array if the params are numeric (i.e. <code>{0}</code>)
   * or an object (i.e. <code>{foo: 'bar'}</code>).
   * @param {Boolean} returnElement (optional) true to return an Ext.Element (defaults to undefined)
   * @return {HTMLElement/Ext.Element} The new node or Element
   */
  append: function append(el, values, returnElement) {
    return this.doInsert('beforeEnd', el, values, returnElement);
  },
  doInsert: function doInsert(where, el, values, returnEl) {
    el = Ext.getDom(el);
    var newNode = Ext.DomHelper.insertHtml(where, el, this.applyTemplate(values));
    return returnEl ? Ext.get(newNode, true) : newNode;
  },

  /**
   * Applies the supplied values to the template and overwrites the content of el with the new node(s).
   * @param {Mixed} el The context element
   * @param {Object/Array} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
   * @param {Boolean} returnElement (optional) true to return a Ext.Element (defaults to undefined)
   * @return {HTMLElement/Ext.Element} The new node or Element
   */
  overwrite: function overwrite(el, values, returnElement) {
    el = Ext.getDom(el);
    el.innerHTML = this.applyTemplate(values);
    return returnElement ? Ext.get(el.firstChild, true) : el.firstChild;
  }
};
/**
 * Alias for {@link #applyTemplate}
 * Returns an HTML fragment of this template with the specified <code>values</code> applied.
 * @param {Object/Array} values
 * The template values. Can be an array if the params are numeric (i.e. <code>{0}</code>)
 * or an object (i.e. <code>{foo: 'bar'}</code>).
 * @return {String} The HTML fragment
 * @member Ext.Template
 * @method apply
 */

Ext.Template.prototype.apply = Ext.Template.prototype.applyTemplate;
/**
 * Creates a template from the passed element's value (<i>display:none</i> textarea, preferred) or innerHTML.
 * @param {String/HTMLElement} el A DOM element or its id
 * @param {Object} config A configuration object
 * @return {Ext.Template} The created template
 * @static
 */

Ext.Template.from = function (el, config) {
  el = Ext.getDom(el);
  return new Ext.Template(el.value || el.innerHTML, config || '');
};

/***/ }),
/* 709 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Template
 */
Ext.apply(Ext.Template.prototype, {
  /**
   * @cfg {Boolean} disableFormats Specify <tt>true</tt> to disable format
   * functions in the template. If the template does not contain
   * {@link Ext.util.Format format functions}, setting <code>disableFormats</code>
   * to true will reduce <code>{@link #apply}</code> time. Defaults to <tt>false</tt>.
   * <pre><code>
  var t = new Ext.Template(
  '&lt;div name="{id}"&gt;',
      '&lt;span class="{cls}"&gt;{name} {value}&lt;/span&gt;',
  '&lt;/div&gt;',
  {
      compiled: true,      // {@link #compile} immediately
      disableFormats: true // reduce <code>{@link #apply}</code> time since no formatting
  }    
  );
   * </code></pre>
   * For a list of available format functions, see {@link Ext.util.Format}.
   */
  disableFormats: false,

  /**
   * See <code>{@link #disableFormats}</code>.
   * @type Boolean
   * @property disableFormats
   */

  /**
   * The regular expression used to match template variables
   * @type RegExp
   * @property
   * @hide repeat doc
   */
  re: /\{([\w-]+)(?:\:([\w\.]*)(?:\((.*?)?\))?)?\}/g,

  /**
   * Returns an HTML fragment of this template with the specified values applied.
   * @param {Object/Array} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
   * @return {String} The HTML fragment
   * @hide repeat doc
   */
  applyTemplate: function applyTemplate(values) {
    var me = this,
        useF = me.disableFormats !== true,
        fm = Ext.util.Format,
        tpl = me;

    if (me.compiled) {
      return me.compiled(values);
    }

    function fn(m, name, format, args) {
      if (format && useF) {
        if (format.substr(0, 5) == "this.") {
          return tpl.call(format.substr(5), values[name], values);
        } else {
          if (args) {
            // quoted values are required for strings in compiled templates,
            // but for non compiled we need to strip them
            // quoted reversed for jsmin
            var re = /^\s*['"](.*)["']\s*$/;
            args = args.split(',');

            for (var i = 0, len = args.length; i < len; i++) {
              args[i] = args[i].replace(re, "$1");
            }

            args = [values[name]].concat(args);
          } else {
            args = [values[name]];
          }

          return fm[format].apply(fm, args);
        }
      } else {
        return values[name] !== undefined ? values[name] : "";
      }
    }

    return me.html.replace(me.re, fn);
  },

  /**
   * Compiles the template into an internal function, eliminating the RegEx overhead.
   * @return {Ext.Template} this
   * @hide repeat doc
   */
  compile: function compile() {
    var me = this,
        fm = Ext.util.Format,
        useF = me.disableFormats !== true,
        sep = Ext.isGecko ? "+" : ",",
        body;

    function fn(m, name, format, args) {
      if (format && useF) {
        args = args ? ',' + args : "";

        if (format.substr(0, 5) != "this.") {
          format = "fm." + format + '(';
        } else {
          format = 'this.call("' + format.substr(5) + '", ';
          args = ", values";
        }
      } else {
        args = '';
        format = "(values['" + name + "'] == undefined ? '' : ";
      }

      return "'" + sep + format + "values['" + name + "']" + args + ")" + sep + "'";
    } // branched to use + in gecko and [].join() in others


    if (Ext.isGecko) {
      body = "this.compiled = function(values){ return '" + me.html.replace(/\\/g, '\\\\').replace(/(\r\n|\n)/g, '\\n').replace(/'/g, "\\'").replace(this.re, fn) + "';};";
    } else {
      body = ["this.compiled = function(values){ return ['"];
      body.push(me.html.replace(/\\/g, '\\\\').replace(/(\r\n|\n)/g, '\\n').replace(/'/g, "\\'").replace(this.re, fn));
      body.push("'].join('');};");
      body = body.join('');
    }

    eval(body);
    return me;
  },
  // private function used to call members
  call: function call(fnName, value, allValues) {
    return this[fnName](value, allValues);
  }
});
Ext.Template.prototype.apply = Ext.Template.prototype.applyTemplate;

/***/ }),
/* 710 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/*
 * This is code is also distributed under MIT license for use
 * with jQuery and prototype JavaScript libraries.
 */

/**
 * @class Ext.DomQuery
Provides high performance selector/xpath processing by compiling queries into reusable functions. New pseudo classes and matchers can be plugged. It works on HTML and XML documents (if a content node is passed in).
<p>
DomQuery supports most of the <a href="http://www.w3.org/TR/2005/WD-css3-selectors-20051215/#selectors">CSS3 selectors spec</a>, along with some custom selectors and basic XPath.</p>

<p>
All selectors, attribute filters and pseudos below can be combined infinitely in any order. For example "div.foo:nth-child(odd)[@foo=bar].bar:first" would be a perfectly valid selector. Node filters are processed in the order in which they appear, which allows you to optimize your queries for your document structure.
</p>
<h4>Element Selectors:</h4>
<ul class="list">
    <li> <b>*</b> any element</li>
    <li> <b>E</b> an element with the tag E</li>
    <li> <b>E F</b> All descendent elements of E that have the tag F</li>
    <li> <b>E > F</b> or <b>E/F</b> all direct children elements of E that have the tag F</li>
    <li> <b>E + F</b> all elements with the tag F that are immediately preceded by an element with the tag E</li>
    <li> <b>E ~ F</b> all elements with the tag F that are preceded by a sibling element with the tag E</li>
</ul>
<h4>Attribute Selectors:</h4>
<p>The use of &#64; and quotes are optional. For example, div[&#64;foo='bar'] is also a valid attribute selector.</p>
<ul class="list">
    <li> <b>E[foo]</b> has an attribute "foo"</li>
    <li> <b>E[foo=bar]</b> has an attribute "foo" that equals "bar"</li>
    <li> <b>E[foo^=bar]</b> has an attribute "foo" that starts with "bar"</li>
    <li> <b>E[foo$=bar]</b> has an attribute "foo" that ends with "bar"</li>
    <li> <b>E[foo*=bar]</b> has an attribute "foo" that contains the substring "bar"</li>
    <li> <b>E[foo%=2]</b> has an attribute "foo" that is evenly divisible by 2</li>
    <li> <b>E[foo!=bar]</b> has an attribute "foo" that does not equal "bar"</li>
</ul>
<h4>Pseudo Classes:</h4>
<ul class="list">
    <li> <b>E:first-child</b> E is the first child of its parent</li>
    <li> <b>E:last-child</b> E is the last child of its parent</li>
    <li> <b>E:nth-child(<i>n</i>)</b> E is the <i>n</i>th child of its parent (1 based as per the spec)</li>
    <li> <b>E:nth-child(odd)</b> E is an odd child of its parent</li>
    <li> <b>E:nth-child(even)</b> E is an even child of its parent</li>
    <li> <b>E:only-child</b> E is the only child of its parent</li>
    <li> <b>E:checked</b> E is an element that is has a checked attribute that is true (e.g. a radio or checkbox) </li>
    <li> <b>E:first</b> the first E in the resultset</li>
    <li> <b>E:last</b> the last E in the resultset</li>
    <li> <b>E:nth(<i>n</i>)</b> the <i>n</i>th E in the resultset (1 based)</li>
    <li> <b>E:odd</b> shortcut for :nth-child(odd)</li>
    <li> <b>E:even</b> shortcut for :nth-child(even)</li>
    <li> <b>E:contains(foo)</b> E's innerHTML contains the substring "foo"</li>
    <li> <b>E:nodeValue(foo)</b> E contains a textNode with a nodeValue that equals "foo"</li>
    <li> <b>E:not(S)</b> an E element that does not match simple selector S</li>
    <li> <b>E:has(S)</b> an E element that has a descendent that matches simple selector S</li>
    <li> <b>E:next(S)</b> an E element whose next sibling matches simple selector S</li>
    <li> <b>E:prev(S)</b> an E element whose previous sibling matches simple selector S</li>
    <li> <b>E:any(S1|S2|S2)</b> an E element which matches any of the simple selectors S1, S2 or S3//\\</li>
</ul>
<h4>CSS Value Selectors:</h4>
<ul class="list">
    <li> <b>E{display=none}</b> css value "display" that equals "none"</li>
    <li> <b>E{display^=none}</b> css value "display" that starts with "none"</li>
    <li> <b>E{display$=none}</b> css value "display" that ends with "none"</li>
    <li> <b>E{display*=none}</b> css value "display" that contains the substring "none"</li>
    <li> <b>E{display%=2}</b> css value "display" that is evenly divisible by 2</li>
    <li> <b>E{display!=none}</b> css value "display" that does not equal "none"</li>
</ul>
 * @singleton
 */
Ext.DomQuery = function () {
  var cache = {},
      simpleCache = {},
      valueCache = {},
      nonSpace = /\S/,
      trimRe = /^\s+|\s+$/g,
      tplRe = /\{(\d+)\}/g,
      modeRe = /^(\s?[\/>+~]\s?|\s|$)/,
      tagTokenRe = /^(#)?([\w-\*]+)/,
      nthRe = /(\d*)n\+?(\d*)/,
      nthRe2 = /\D/,
      // This is for IE MSXML which does not support expandos.
  // IE runs the same speed using setAttribute, however FF slows way down
  // and Safari completely fails so they need to continue to use expandos.
  isIE = window.ActiveXObject ? true : false,
      key = 30803; // this eval is stop the compressor from
  // renaming the variable to something shorter

  eval("var batch = 30803;"); // Retrieve the child node from a particular
  // parent at the specified index.

  function child(parent, index) {
    var i = 0,
        n = parent.firstChild;

    while (n) {
      if (n.nodeType == 1) {
        if (++i == index) {
          return n;
        }
      }

      n = n.nextSibling;
    }

    return null;
  } // retrieve the next element node


  function _next(n) {
    while ((n = n.nextSibling) && n.nodeType != 1);

    return n;
  } // retrieve the previous element node 


  function _prev(n) {
    while ((n = n.previousSibling) && n.nodeType != 1);

    return n;
  } // Mark each child node with a nodeIndex skipping and
  // removing empty text nodes.


  function children(parent) {
    var n = parent.firstChild,
        nodeIndex = -1,
        nextNode;

    while (n) {
      nextNode = n.nextSibling; // clean worthless empty nodes.

      if (n.nodeType == 3 && !nonSpace.test(n.nodeValue)) {
        parent.removeChild(n);
      } else {
        // add an expando nodeIndex
        n.nodeIndex = ++nodeIndex;
      }

      n = nextNode;
    }

    return this;
  } // nodeSet - array of nodes
  // cls - CSS Class


  function byClassName(nodeSet, cls) {
    if (!cls) {
      return nodeSet;
    }

    var result = [],
        ri = -1;

    for (var i = 0, ci; ci = nodeSet[i]; i++) {
      if ((' ' + ci.className + ' ').indexOf(cls) != -1) {
        result[++ri] = ci;
      }
    }

    return result;
  }

  ;

  function attrValue(n, attr) {
    // if its an array, use the first node.
    if (!n.tagName && typeof n.length != "undefined") {
      n = n[0];
    }

    if (!n) {
      return null;
    }

    if (attr == "for") {
      return n.htmlFor;
    }

    if (attr == "class" || attr == "className") {
      return n.className;
    }

    return n.getAttribute(attr) || n[attr];
  }

  ; // ns - nodes
  // mode - false, /, >, +, ~
  // tagName - defaults to "*"

  function getNodes(ns, mode, tagName) {
    var result = [],
        ri = -1,
        cs;

    if (!ns) {
      return result;
    }

    tagName = tagName || "*"; // convert to array

    if (typeof ns.getElementsByTagName != "undefined") {
      ns = [ns];
    } // no mode specified, grab all elements by tagName
    // at any depth


    if (!mode) {
      for (var i = 0, ni; ni = ns[i]; i++) {
        cs = ni.getElementsByTagName(tagName);

        for (var j = 0, ci; ci = cs[j]; j++) {
          result[++ri] = ci;
        }
      } // Direct Child mode (/ or >)
      // E > F or E/F all direct children elements of E that have the tag 	

    } else if (mode == "/" || mode == ">") {
      var utag = tagName.toUpperCase();

      for (var i = 0, ni, cn; ni = ns[i]; i++) {
        cn = ni.childNodes;

        for (var j = 0, cj; cj = cn[j]; j++) {
          if (cj.nodeName == utag || cj.nodeName == tagName || tagName == '*') {
            result[++ri] = cj;
          }
        }
      } // Immediately Preceding mode (+)
      // E + F all elements with the tag F that are immediately preceded by an element with the tag E

    } else if (mode == "+") {
      var utag = tagName.toUpperCase();

      for (var i = 0, n; n = ns[i]; i++) {
        while ((n = n.nextSibling) && n.nodeType != 1);

        if (n && (n.nodeName == utag || n.nodeName == tagName || tagName == '*')) {
          result[++ri] = n;
        }
      } // Sibling mode (~)
      // E ~ F all elements with the tag F that are preceded by a sibling element with the tag E

    } else if (mode == "~") {
      var utag = tagName.toUpperCase();

      for (var i = 0, n; n = ns[i]; i++) {
        while (n = n.nextSibling) {
          if (n.nodeName == utag || n.nodeName == tagName || tagName == '*') {
            result[++ri] = n;
          }
        }
      }
    }

    return result;
  }

  function concat(a, b) {
    if (b.slice) {
      return a.concat(b);
    }

    for (var i = 0, l = b.length; i < l; i++) {
      a[a.length] = b[i];
    }

    return a;
  }

  function byTag(cs, tagName) {
    if (cs.tagName || cs == document) {
      cs = [cs];
    }

    if (!tagName) {
      return cs;
    }

    var result = [],
        ri = -1;
    tagName = tagName.toLowerCase();

    for (var i = 0, ci; ci = cs[i]; i++) {
      if (ci.nodeType == 1 && ci.tagName.toLowerCase() == tagName) {
        result[++ri] = ci;
      }
    }

    return result;
  }

  function byId(cs, id) {
    if (cs.tagName || cs == document) {
      cs = [cs];
    }

    if (!id) {
      return cs;
    }

    var result = [],
        ri = -1;

    for (var i = 0, ci; ci = cs[i]; i++) {
      if (ci && ci.id == id) {
        result[++ri] = ci;
        return result;
      }
    }

    return result;
  } // operators are =, !=, ^=, $=, *=, %=, |= and ~=
  // custom can be "{"


  function byAttribute(cs, attr, value, op, custom) {
    var result = [],
        ri = -1,
        useGetStyle = custom == "{",
        fn = Ext.DomQuery.operators[op],
        a,
        innerHTML;

    for (var i = 0, ci; ci = cs[i]; i++) {
      // skip non-element nodes.
      if (ci.nodeType != 1) {
        continue;
      }

      innerHTML = ci.innerHTML; // we only need to change the property names if we're dealing with html nodes, not XML

      if (innerHTML !== null && innerHTML !== undefined) {
        if (useGetStyle) {
          a = Ext.DomQuery.getStyle(ci, attr);
        } else if (attr == "class" || attr == "className") {
          a = ci.className;
        } else if (attr == "for") {
          a = ci.htmlFor;
        } else if (attr == "href") {
          // getAttribute href bug
          // http://www.glennjones.net/Post/809/getAttributehrefbug.htm
          a = ci.getAttribute("href", 2);
        } else {
          a = ci.getAttribute(attr);
        }
      } else {
        a = ci.getAttribute(attr);
      }

      if (fn && fn(a, value) || !fn && a) {
        result[++ri] = ci;
      }
    }

    return result;
  }

  function byPseudo(cs, name, value) {
    return Ext.DomQuery.pseudos[name](cs, value);
  }

  function nodupIEXml(cs) {
    var d = ++key,
        r;
    cs[0].setAttribute("_nodup", d);
    r = [cs[0]];

    for (var i = 1, len = cs.length; i < len; i++) {
      var c = cs[i];

      if (!c.getAttribute("_nodup") != d) {
        c.setAttribute("_nodup", d);
        r[r.length] = c;
      }
    }

    for (var i = 0, len = cs.length; i < len; i++) {
      cs[i].removeAttribute("_nodup");
    }

    return r;
  }

  function nodup(cs) {
    if (!cs) {
      return [];
    }

    var len = cs.length,
        c,
        i,
        r = cs,
        cj,
        ri = -1;

    if (!len || typeof cs.nodeType != "undefined" || len == 1) {
      return cs;
    }

    if (isIE && typeof cs[0].selectSingleNode != "undefined") {
      return nodupIEXml(cs);
    }

    var d = ++key;
    cs[0]._nodup = d;

    for (i = 1; c = cs[i]; i++) {
      if (c._nodup != d) {
        c._nodup = d;
      } else {
        r = [];

        for (var j = 0; j < i; j++) {
          r[++ri] = cs[j];
        }

        for (j = i + 1; cj = cs[j]; j++) {
          if (cj._nodup != d) {
            cj._nodup = d;
            r[++ri] = cj;
          }
        }

        return r;
      }
    }

    return r;
  }

  function quickDiffIEXml(c1, c2) {
    var d = ++key,
        r = [];

    for (var i = 0, len = c1.length; i < len; i++) {
      c1[i].setAttribute("_qdiff", d);
    }

    for (var i = 0, len = c2.length; i < len; i++) {
      if (c2[i].getAttribute("_qdiff") != d) {
        r[r.length] = c2[i];
      }
    }

    for (var i = 0, len = c1.length; i < len; i++) {
      c1[i].removeAttribute("_qdiff");
    }

    return r;
  }

  function quickDiff(c1, c2) {
    var len1 = c1.length,
        d = ++key,
        r = [];

    if (!len1) {
      return c2;
    }

    if (isIE && typeof c1[0].selectSingleNode != "undefined") {
      return quickDiffIEXml(c1, c2);
    }

    for (var i = 0; i < len1; i++) {
      c1[i]._qdiff = d;
    }

    for (var i = 0, len = c2.length; i < len; i++) {
      if (c2[i]._qdiff != d) {
        r[r.length] = c2[i];
      }
    }

    return r;
  }

  function quickId(ns, mode, root, id) {
    if (ns == root) {
      var d = root.ownerDocument || root;
      return d.getElementById(id);
    }

    ns = getNodes(ns, mode, "*");
    return byId(ns, id);
  }

  return {
    getStyle: function getStyle(el, name) {
      return Ext.fly(el).getStyle(name);
    },

    /**
     * Compiles a selector/xpath query into a reusable function. The returned function
     * takes one parameter "root" (optional), which is the context node from where the query should start.
     * @param {String} selector The selector/xpath query
     * @param {String} type (optional) Either "select" (the default) or "simple" for a simple selector match
     * @return {Function}
     */
    compile: function compile(path, type) {
      type = type || "select"; // setup fn preamble

      var fn = ["var f = function(root){\n var mode; ++batch; var n = root || document;\n"],
          mode,
          lastPath,
          matchers = Ext.DomQuery.matchers,
          matchersLn = matchers.length,
          modeMatch,
          // accept leading mode switch
      lmode = path.match(modeRe);

      if (lmode && lmode[1]) {
        fn[fn.length] = 'mode="' + lmode[1].replace(trimRe, "") + '";';
        path = path.replace(lmode[1], "");
      } // strip leading slashes


      while (path.substr(0, 1) == "/") {
        path = path.substr(1);
      }

      while (path && lastPath != path) {
        lastPath = path;
        var tokenMatch = path.match(tagTokenRe);

        if (type == "select") {
          if (tokenMatch) {
            // ID Selector
            if (tokenMatch[1] == "#") {
              fn[fn.length] = 'n = quickId(n, mode, root, "' + tokenMatch[2] + '");';
            } else {
              fn[fn.length] = 'n = getNodes(n, mode, "' + tokenMatch[2] + '");';
            }

            path = path.replace(tokenMatch[0], "");
          } else if (path.substr(0, 1) != '@') {
            fn[fn.length] = 'n = getNodes(n, mode, "*");';
          } // type of "simple"

        } else {
          if (tokenMatch) {
            if (tokenMatch[1] == "#") {
              fn[fn.length] = 'n = byId(n, "' + tokenMatch[2] + '");';
            } else {
              fn[fn.length] = 'n = byTag(n, "' + tokenMatch[2] + '");';
            }

            path = path.replace(tokenMatch[0], "");
          }
        }

        while (!(modeMatch = path.match(modeRe))) {
          var matched = false;

          for (var j = 0; j < matchersLn; j++) {
            var t = matchers[j];
            var m = path.match(t.re);

            if (m) {
              fn[fn.length] = t.select.replace(tplRe, function (x, i) {
                return m[i];
              });
              path = path.replace(m[0], "");
              matched = true;
              break;
            }
          } // prevent infinite loop on bad selector


          if (!matched) {
            throw 'Error parsing selector, parsing failed at "' + path + '"';
          }
        }

        if (modeMatch[1]) {
          fn[fn.length] = 'mode="' + modeMatch[1].replace(trimRe, "") + '";';
          path = path.replace(modeMatch[1], "");
        }
      } // close fn out


      fn[fn.length] = "return nodup(n);\n}"; // eval fn and return it

      eval(fn.join(""));
      return f;
    },

    /**
     * Selects a group of elements.
     * @param {String} selector The selector/xpath query (can be a comma separated list of selectors)
     * @param {Node/String} root (optional) The start of the query (defaults to document).
     * @return {Array} An Array of DOM elements which match the selector. If there are
     * no matches, and empty Array is returned.
     */
    jsSelect: function jsSelect(path, root, type) {
      // set root to doc if not specified.
      root = root || document;

      if (typeof root == "string") {
        root = document.getElementById(root);
      }

      var paths = path.split(","),
          results = []; // loop over each selector

      for (var i = 0, len = paths.length; i < len; i++) {
        var subPath = paths[i].replace(trimRe, ""); // compile and place in cache

        if (!cache[subPath]) {
          cache[subPath] = Ext.DomQuery.compile(subPath);

          if (!cache[subPath]) {
            throw subPath + " is not a valid selector";
          }
        }

        var result = cache[subPath](root);

        if (result && result != document) {
          results = results.concat(result);
        }
      } // if there were multiple selectors, make sure dups
      // are eliminated


      if (paths.length > 1) {
        return nodup(results);
      }

      return results;
    },
    isXml: function isXml(el) {
      var docEl = (el ? el.ownerDocument || el : 0).documentElement;
      return docEl ? docEl.nodeName !== "HTML" : false;
    },
    select: document.querySelectorAll ? function (path, root, type) {
      root = root || document;

      if (!Ext.DomQuery.isXml(root)) {
        try {
          var cs = root.querySelectorAll(path);
          return Ext.toArray(cs);
        } catch (ex) {}
      }

      return Ext.DomQuery.jsSelect.call(this, path, root, type);
    } : function (path, root, type) {
      return Ext.DomQuery.jsSelect.call(this, path, root, type);
    },

    /**
     * Selects a single element.
     * @param {String} selector The selector/xpath query
     * @param {Node} root (optional) The start of the query (defaults to document).
     * @return {Element} The DOM element which matched the selector.
     */
    selectNode: function selectNode(path, root) {
      return Ext.DomQuery.select(path, root)[0];
    },

    /**
     * Selects the value of a node, optionally replacing null with the defaultValue.
     * @param {String} selector The selector/xpath query
     * @param {Node} root (optional) The start of the query (defaults to document).
     * @param {String} defaultValue
     * @return {String}
     */
    selectValue: function selectValue(path, root, defaultValue) {
      path = path.replace(trimRe, "");

      if (!valueCache[path]) {
        valueCache[path] = Ext.DomQuery.compile(path, "select");
      }

      var n = valueCache[path](root),
          v;
      n = n[0] ? n[0] : n; // overcome a limitation of maximum textnode size
      // Rumored to potentially crash IE6 but has not been confirmed.
      // http://reference.sitepoint.com/javascript/Node/normalize
      // https://developer.mozilla.org/En/DOM/Node.normalize	    

      if (typeof n.normalize == 'function') n.normalize();
      v = n && n.firstChild ? n.firstChild.nodeValue : null;
      return v === null || v === undefined || v === '' ? defaultValue : v;
    },

    /**
     * Selects the value of a node, parsing integers and floats. Returns the defaultValue, or 0 if none is specified.
     * @param {String} selector The selector/xpath query
     * @param {Node} root (optional) The start of the query (defaults to document).
     * @param {Number} defaultValue
     * @return {Number}
     */
    selectNumber: function selectNumber(path, root, defaultValue) {
      var v = Ext.DomQuery.selectValue(path, root, defaultValue || 0);
      return parseFloat(v);
    },

    /**
     * Returns true if the passed element(s) match the passed simple selector (e.g. div.some-class or span:first-child)
     * @param {String/HTMLElement/Array} el An element id, element or array of elements
     * @param {String} selector The simple selector to test
     * @return {Boolean}
     */
    is: function is(el, ss) {
      if (typeof el == "string") {
        el = document.getElementById(el);
      }

      var isArray = Ext.isArray(el),
          result = Ext.DomQuery.filter(isArray ? el : [el], ss);
      return isArray ? result.length == el.length : result.length > 0;
    },

    /**
     * Filters an array of elements to only include matches of a simple selector (e.g. div.some-class or span:first-child)
     * @param {Array} el An array of elements to filter
     * @param {String} selector The simple selector to test
     * @param {Boolean} nonMatches If true, it returns the elements that DON'T match
     * the selector instead of the ones that match
     * @return {Array} An Array of DOM elements which match the selector. If there are
     * no matches, and empty Array is returned.
     */
    filter: function filter(els, ss, nonMatches) {
      ss = ss.replace(trimRe, "");

      if (!simpleCache[ss]) {
        simpleCache[ss] = Ext.DomQuery.compile(ss, "simple");
      }

      var result = simpleCache[ss](els);
      return nonMatches ? quickDiff(result, els) : result;
    },

    /**
     * Collection of matching regular expressions and code snippets.
     * Each capture group within () will be replace the {} in the select
     * statement as specified by their index.
     */
    matchers: [{
      re: /^\.([\w-]+)/,
      select: 'n = byClassName(n, " {1} ");'
    }, {
      re: /^\:([\w-]+)(?:\(((?:[^\s>\/]*|.*?))\))?/,
      select: 'n = byPseudo(n, "{1}", "{2}");'
    }, {
      re: /^(?:([\[\{])(?:@)?([\w-]+)\s?(?:(=|.=)\s?['"]?(.*?)["']?)?[\]\}])/,
      select: 'n = byAttribute(n, "{2}", "{4}", "{3}", "{1}");'
    }, {
      re: /^#([\w-]+)/,
      select: 'n = byId(n, "{1}");'
    }, {
      re: /^@([\w-]+)/,
      select: 'return {firstChild:{nodeValue:attrValue(n, "{1}")}};'
    }],

    /**
     * Collection of operator comparison functions. The default operators are =, !=, ^=, $=, *=, %=, |= and ~=.
     * New operators can be added as long as the match the format <i>c</i>= where <i>c</i> is any character other than space, &gt; &lt;.
     */
    operators: {
      "=": function _(a, v) {
        return a == v;
      },
      "!=": function _(a, v) {
        return a != v;
      },
      "^=": function _(a, v) {
        return a && a.substr(0, v.length) == v;
      },
      "$=": function $(a, v) {
        return a && a.substr(a.length - v.length) == v;
      },
      "*=": function _(a, v) {
        return a && a.indexOf(v) !== -1;
      },
      "%=": function _(a, v) {
        return a % v == 0;
      },
      "|=": function _(a, v) {
        return a && (a == v || a.substr(0, v.length + 1) == v + '-');
      },
      "~=": function _(a, v) {
        return a && (' ' + a + ' ').indexOf(' ' + v + ' ') != -1;
      }
    },

    /**
     * <p>Object hash of "pseudo class" filter functions which are used when filtering selections. Each function is passed
     * two parameters:</p><div class="mdetail-params"><ul>
     * <li><b>c</b> : Array<div class="sub-desc">An Array of DOM elements to filter.</div></li>
     * <li><b>v</b> : String<div class="sub-desc">The argument (if any) supplied in the selector.</div></li>
     * </ul></div>
     * <p>A filter function returns an Array of DOM elements which conform to the pseudo class.</p>
     * <p>In addition to the provided pseudo classes listed above such as <code>first-child</code> and <code>nth-child</code>,
     * developers may add additional, custom psuedo class filters to select elements according to application-specific requirements.</p>
     * <p>For example, to filter <code>&lt;a></code> elements to only return links to <i>external</i> resources:</p>
     * <code><pre>
    Ext.DomQuery.pseudos.external = function(c, v){
    var r = [], ri = -1;
    for(var i = 0, ci; ci = c[i]; i++){
    //      Include in result set only if it's a link to an external resource
    if(ci.hostname != location.hostname){
        r[++ri] = ci;
    }
    }
    return r;
    };</pre></code>
     * Then external links could be gathered with the following statement:<code><pre>
    var externalLinks = Ext.select("a:external");
    </code></pre>
     */
    pseudos: {
      "first-child": function firstChild(c) {
        var r = [],
            ri = -1,
            n;

        for (var i = 0, ci; ci = n = c[i]; i++) {
          while ((n = n.previousSibling) && n.nodeType != 1);

          if (!n) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "last-child": function lastChild(c) {
        var r = [],
            ri = -1,
            n;

        for (var i = 0, ci; ci = n = c[i]; i++) {
          while ((n = n.nextSibling) && n.nodeType != 1);

          if (!n) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "nth-child": function nthChild(c, a) {
        var r = [],
            ri = -1,
            m = nthRe.exec(a == "even" && "2n" || a == "odd" && "2n+1" || !nthRe2.test(a) && "n+" + a || a),
            f = (m[1] || 1) - 0,
            l = m[2] - 0;

        for (var i = 0, n; n = c[i]; i++) {
          var pn = n.parentNode;

          if (batch != pn._batch) {
            var j = 0;

            for (var cn = pn.firstChild; cn; cn = cn.nextSibling) {
              if (cn.nodeType == 1) {
                cn.nodeIndex = ++j;
              }
            }

            pn._batch = batch;
          }

          if (f == 1) {
            if (l == 0 || n.nodeIndex == l) {
              r[++ri] = n;
            }
          } else if ((n.nodeIndex + l) % f == 0) {
            r[++ri] = n;
          }
        }

        return r;
      },
      "only-child": function onlyChild(c) {
        var r = [],
            ri = -1;
        ;

        for (var i = 0, ci; ci = c[i]; i++) {
          if (!_prev(ci) && !_next(ci)) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "empty": function empty(c) {
        var r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          var cns = ci.childNodes,
              j = 0,
              cn,
              empty = true;

          while (cn = cns[j]) {
            ++j;

            if (cn.nodeType == 1 || cn.nodeType == 3) {
              empty = false;
              break;
            }
          }

          if (empty) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "contains": function contains(c, v) {
        var r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          if ((ci.textContent || ci.innerText || '').indexOf(v) != -1) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "nodeValue": function nodeValue(c, v) {
        var r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          if (ci.firstChild && ci.firstChild.nodeValue == v) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "checked": function checked(c) {
        var r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          if (ci.checked == true) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "not": function not(c, ss) {
        return Ext.DomQuery.filter(c, ss, true);
      },
      "any": function any(c, selectors) {
        var ss = selectors.split('|'),
            r = [],
            ri = -1,
            s;

        for (var i = 0, ci; ci = c[i]; i++) {
          for (var j = 0; s = ss[j]; j++) {
            if (Ext.DomQuery.is(ci, s)) {
              r[++ri] = ci;
              break;
            }
          }
        }

        return r;
      },
      "odd": function odd(c) {
        return this["nth-child"](c, "odd");
      },
      "even": function even(c) {
        return this["nth-child"](c, "even");
      },
      "nth": function nth(c, a) {
        return c[a - 1] || [];
      },
      "first": function first(c) {
        return c[0] || [];
      },
      "last": function last(c) {
        return c[c.length - 1] || [];
      },
      "has": function has(c, ss) {
        var s = Ext.DomQuery.select,
            r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          if (s(ss, ci).length > 0) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "next": function next(c, ss) {
        var is = Ext.DomQuery.is,
            r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          var n = _next(ci);

          if (n && is(n, ss)) {
            r[++ri] = ci;
          }
        }

        return r;
      },
      "prev": function prev(c, ss) {
        var is = Ext.DomQuery.is,
            r = [],
            ri = -1;

        for (var i = 0, ci; ci = c[i]; i++) {
          var n = _prev(ci);

          if (n && is(n, ss)) {
            r[++ri] = ci;
          }
        }

        return r;
      }
    }
  };
}();
/**
 * Selects an array of DOM nodes by CSS/XPath selector. Shorthand of {@link Ext.DomQuery#select}
 * @param {String} path The selector/xpath query
 * @param {Node} root (optional) The start of the query (defaults to document).
 * @return {Array}
 * @member Ext
 * @method query
 */


Ext.query = Ext.DomQuery.select;

/***/ }),
/* 711 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.DelayedTask
 * <p> The DelayedTask class provides a convenient way to "buffer" the execution of a method,
 * performing setTimeout where a new timeout cancels the old timeout. When called, the
 * task will wait the specified time period before executing. If durng that time period,
 * the task is called again, the original call will be cancelled. This continues so that
 * the function is only called a single time for each iteration.</p>
 * <p>This method is especially useful for things like detecting whether a user has finished
 * typing in a text field. An example would be performing validation on a keypress. You can
 * use this class to buffer the keypress events for a certain number of milliseconds, and
 * perform only if they stop for that amount of time.  Usage:</p><pre><code>
var task = new Ext.util.DelayedTask(function(){
    alert(Ext.getDom('myInputField').value.length);
});
// Wait 500ms before calling our function. If the user presses another key 
// during that 500ms, it will be cancelled and we'll wait another 500ms.
Ext.get('myInputField').on('keypress', function(){
    task.{@link #delay}(500); 
});
 * </code></pre> 
 * <p>Note that we are using a DelayedTask here to illustrate a point. The configuration
 * option <tt>buffer</tt> for {@link Ext.util.Observable#addListener addListener/on} will
 * also setup a delayed task for you to buffer events.</p> 
 * @constructor The parameters to this constructor serve as defaults and are not required.
 * @param {Function} fn (optional) The default function to call.
 * @param {Object} scope The default scope (The <code><b>this</b></code> reference) in which the
 * function is called. If not specified, <code>this</code> will refer to the browser window.
 * @param {Array} args (optional) The default Array of arguments.
 */
Ext.util.DelayedTask = function (fn, scope, args) {
  var me = this,
      id,
      call = function call() {
    clearInterval(id);
    id = null;
    fn.apply(scope, args || []);
  };
  /**
   * Cancels any pending timeout and queues a new one
   * @param {Number} delay The milliseconds to delay
   * @param {Function} newFn (optional) Overrides function passed to constructor
   * @param {Object} newScope (optional) Overrides scope passed to constructor. Remember that if no scope
   * is specified, <code>this</code> will refer to the browser window.
   * @param {Array} newArgs (optional) Overrides args passed to constructor
   */


  me.delay = function (delay, newFn, newScope, newArgs) {
    me.cancel();
    fn = newFn || fn;
    scope = newScope || scope;
    args = newArgs || args;
    id = setInterval(call, delay);
  };
  /**
   * Cancel the last queued timeout
   */


  me.cancel = function () {
    if (id) {
      clearInterval(id);
      id = null;
    }
  };
};

/***/ }),
/* 712 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
(function () {
  var EXTUTIL = Ext.util,
      TOARRAY = Ext.toArray,
      EACH = Ext.each,
      ISOBJECT = Ext.isObject,
      TRUE = true,
      FALSE = false;
  /**
   * @class Ext.util.Observable
   * Base class that provides a common interface for publishing events. Subclasses are expected to
   * to have a property "events" with all the events defined, and, optionally, a property "listeners"
   * with configured listeners defined.<br>
   * For example:
   * <pre><code>
  Employee = Ext.extend(Ext.util.Observable, {
      constructor: function(config){
          this.name = config.name;
          this.addEvents({
              "fired" : true,
              "quit" : true
          });
  
          // Copy configured listeners into *this* object so that the base class&#39;s
          // constructor will add them.
          this.listeners = config.listeners;
  
          // Call our superclass constructor to complete construction process.
          Employee.superclass.constructor.call(config)
      }
  });
  </code></pre>
   * This could then be used like this:<pre><code>
  var newEmployee = new Employee({
      name: employeeName,
      listeners: {
          quit: function() {
              // By default, "this" will be the object that fired the event.
              alert(this.name + " has quit!");
          }
      }
  });
  </code></pre>
   */

  EXTUTIL.Observable = function () {
    /**
     * @cfg {Object} listeners (optional) <p>A config object containing one or more event handlers to be added to this
     * object during initialization.  This should be a valid listeners config object as specified in the
     * {@link #addListener} example for attaching multiple handlers at once.</p>
     * <br><p><b><u>DOM events from ExtJs {@link Ext.Component Components}</u></b></p>
     * <br><p>While <i>some</i> ExtJs Component classes export selected DOM events (e.g. "click", "mouseover" etc), this
     * is usually only done when extra value can be added. For example the {@link Ext.DataView DataView}'s
     * <b><code>{@link Ext.DataView#click click}</code></b> event passing the node clicked on. To access DOM
     * events directly from a Component's HTMLElement, listeners must be added to the <i>{@link Ext.Component#getEl Element}</i> after the Component
     * has been rendered. A plugin can simplify this step:<pre><code>
    // Plugin is configured with a listeners config object.
    // The Component is appended to the argument list of all handler functions.
    Ext.DomObserver = Ext.extend(Object, {
    constructor: function(config) {
        this.listeners = config.listeners ? config.listeners : config;
    },
     // Component passes itself into plugin&#39;s init method
    init: function(c) {
        var p, l = this.listeners;
        for (p in l) {
            if (Ext.isFunction(l[p])) {
                l[p] = this.createHandler(l[p], c);
            } else {
                l[p].fn = this.createHandler(l[p].fn, c);
            }
        }
         // Add the listeners to the Element immediately following the render call
        c.render = c.render.{@link Function#createSequence createSequence}(function() {
            var e = c.getEl();
            if (e) {
                e.on(l);
            }
        });
    },
     createHandler: function(fn, c) {
        return function(e) {
            fn.call(this, e, c);
        };
    }
    });
    var combo = new Ext.form.ComboBox({
     // Collapse combo when its element is clicked on
    plugins: [ new Ext.DomObserver({
        click: function(evt, comp) {
            comp.collapse();
        }
    })],
    store: myStore,
    typeAhead: true,
    mode: 'local',
    triggerAction: 'all'
    });
     * </code></pre></p>
     */
    var me = this,
        e = me.events;

    if (me.listeners) {
      me.on(me.listeners);
      delete me.listeners;
    }

    me.events = e || {};
  };

  EXTUTIL.Observable.prototype = {
    // private
    filterOptRe: /^(?:scope|delay|buffer|single)$/,

    /**
     * <p>Fires the specified event with the passed parameters (minus the event name).</p>
     * <p>An event may be set to bubble up an Observable parent hierarchy (See {@link Ext.Component#getBubbleTarget})
     * by calling {@link #enableBubble}.</p>
     * @param {String} eventName The name of the event to fire.
     * @param {Object...} args Variable number of parameters are passed to handlers.
     * @return {Boolean} returns false if any of the handlers return false otherwise it returns true.
     */
    fireEvent: function fireEvent() {
      var a = TOARRAY(arguments),
          ename = a[0].toLowerCase(),
          me = this,
          ret = TRUE,
          ce = me.events[ename],
          q,
          c;

      if (me.eventsSuspended === TRUE) {
        if (q = me.eventQueue) {
          q.push(a);
        }
      } else if (ISOBJECT(ce) && ce.bubble) {
        if (ce.fire.apply(ce, a.slice(1)) === FALSE) {
          return FALSE;
        }

        c = me.getBubbleTarget && me.getBubbleTarget();

        if (c && c.enableBubble) {
          if (!c.events[ename] || !Ext.isObject(c.events[ename]) || !c.events[ename].bubble) {
            c.enableBubble(ename);
          }

          return c.fireEvent.apply(c, a);
        }
      } else {
        if (ISOBJECT(ce)) {
          a.shift();
          ret = ce.fire.apply(ce, a);
        }
      }

      return ret;
    },
    fireAsyncEvent: async function fireAsyncEvent() {
      const r = this.fireEvent.apply(this, arguments);
      return !r || r === true ? Promise.resolve() : Ext.isFunction(r.then) ? r : Promise.reject();
    },

    /**
     * Appends an event handler to this object.
     * @param {String}   eventName The name of the event to listen for.
     * @param {Function} handler The method the event invokes.
     * @param {Object}   scope (optional) The scope (<code><b>this</b></code> reference) in which the handler function is executed.
     * <b>If omitted, defaults to the object which fired the event.</b>
     * @param {Object}   options (optional) An object containing handler configuration.
     * properties. This may contain any of the following properties:<ul>
     * <li><b>scope</b> : Object<div class="sub-desc">The scope (<code><b>this</b></code> reference) in which the handler function is executed.
     * <b>If omitted, defaults to the object which fired the event.</b></div></li>
     * <li><b>delay</b> : Number<div class="sub-desc">The number of milliseconds to delay the invocation of the handler after the event fires.</div></li>
     * <li><b>single</b> : Boolean<div class="sub-desc">True to add a handler to handle just the next firing of the event, and then remove itself.</div></li>
     * <li><b>buffer</b> : Number<div class="sub-desc">Causes the handler to be scheduled to run in an {@link Ext.util.DelayedTask} delayed
     * by the specified number of milliseconds. If the event fires again within that time, the original
     * handler is <em>not</em> invoked, but the new handler is scheduled in its place.</div></li>
     * <li><b>target</b> : Observable<div class="sub-desc">Only call the handler if the event was fired on the target Observable, <i>not</i>
     * if the event was bubbled up from a child Observable.</div></li>
     * </ul><br>
     * <p>
     * <b>Combining Options</b><br>
     * Using the options argument, it is possible to combine different types of listeners:<br>
     * <br>
     * A delayed, one-time listener.
     * <pre><code>
    myDataView.on('click', this.onClick, this, {
    single: true,
    delay: 100
    });</code></pre>
     * <p>
     * <b>Attaching multiple handlers in 1 call</b><br>
     * The method also allows for a single argument to be passed which is a config object containing properties
     * which specify multiple handlers.
     * <p>
     * <pre><code>
    myGridPanel.on({
    'click' : {
    fn: this.onClick,
    scope: this,
    delay: 100
    },
    'mouseover' : {
    fn: this.onMouseOver,
    scope: this
    },
    'mouseout' : {
    fn: this.onMouseOut,
    scope: this
    }
    });</code></pre>
    * <p>
    * Or a shorthand syntax:<br>
    * <pre><code>
    myGridPanel.on({
    'click' : this.onClick,
    'mouseover' : this.onMouseOver,
    'mouseout' : this.onMouseOut,
    scope: this
    });</code></pre>
     */
    addListener: function addListener(eventName, fn, scope, o) {
      var me = this,
          e,
          oe,
          isF,
          ce;

      if (ISOBJECT(eventName)) {
        o = eventName;

        for (e in o) {
          oe = o[e];

          if (!me.filterOptRe.test(e)) {
            me.addListener(e, oe.fn || oe, oe.scope || o.scope, oe.fn ? oe : o);
          }
        }
      } else {
        eventName = eventName.toLowerCase();
        ce = me.events[eventName] || TRUE;

        if (Ext.isBoolean(ce)) {
          me.events[eventName] = ce = new EXTUTIL.Event(me, eventName);
        }

        ce.addListener(fn, scope, ISOBJECT(o) ? o : {});
      }
    },

    /**
     * Removes an event handler.
     * @param {String}   eventName The type of event the handler was associated with.
     * @param {Function} handler   The handler to remove. <b>This must be a reference to the function passed into the {@link #addListener} call.</b>
     * @param {Object}   scope     (optional) The scope originally specified for the handler.
     */
    removeListener: function removeListener(eventName, fn, scope) {
      var ce = this.events[eventName.toLowerCase()];

      if (ISOBJECT(ce)) {
        ce.removeListener(fn, scope);
      }
    },

    /**
     * Removes all listeners for this object
     */
    purgeListeners: function purgeListeners() {
      var events = this.events,
          evt,
          key;

      for (key in events) {
        evt = events[key];

        if (ISOBJECT(evt)) {
          evt.clearListeners();
        }
      }
    },

    /**
     * Adds the specified events to the list of events which this Observable may fire.
     * @param {Object|String} o Either an object with event names as properties with a value of <code>true</code>
     * or the first event name string if multiple event names are being passed as separate parameters.
     * @param {string} Optional. Event name if multiple event names are being passed as separate parameters.
     * Usage:<pre><code>
    this.addEvents('storeloaded', 'storecleared');
    </code></pre>
     */
    addEvents: function addEvents(o) {
      var me = this;
      me.events = me.events || {};

      if (Ext.isString(o)) {
        var a = arguments,
            i = a.length;

        while (i--) {
          me.events[a[i]] = me.events[a[i]] || TRUE;
        }
      } else {
        Ext.applyIf(me.events, o);
      }
    },

    /**
     * Checks to see if this object has any listeners for a specified event
     * @param {String} eventName The name of the event to check for
     * @return {Boolean} True if the event is being listened for, else false
     */
    hasListener: function hasListener(eventName) {
      var e = this.events[eventName];
      return ISOBJECT(e) && e.listeners.length > 0;
    },

    /**
     * Suspend the firing of all events. (see {@link #resumeEvents})
     * @param {Boolean} queueSuspended Pass as true to queue up suspended events to be fired
     * after the {@link #resumeEvents} call instead of discarding all suspended events;
     */
    suspendEvents: function suspendEvents(queueSuspended) {
      this.eventsSuspended = TRUE;

      if (queueSuspended && !this.eventQueue) {
        this.eventQueue = [];
      }
    },

    /**
     * Resume firing events. (see {@link #suspendEvents})
     * If events were suspended using the <tt><b>queueSuspended</b></tt> parameter, then all
     * events fired during event suspension will be sent to any listeners now.
     */
    resumeEvents: function resumeEvents() {
      var me = this,
          queued = me.eventQueue || [];
      me.eventsSuspended = FALSE;
      delete me.eventQueue;
      EACH(queued, function (e) {
        me.fireEvent.apply(me, e);
      });
    }
  };
  var OBSERVABLE = EXTUTIL.Observable.prototype;
  /**
   * Appends an event handler to this object (shorthand for {@link #addListener}.)
   * @param {String}   eventName     The type of event to listen for
   * @param {Function} handler       The method the event invokes
   * @param {Object}   scope         (optional) The scope (<code><b>this</b></code> reference) in which the handler function is executed.
   * <b>If omitted, defaults to the object which fired the event.</b>
   * @param {Object}   options       (optional) An object containing handler configuration.
   * @method
   */

  OBSERVABLE.on = OBSERVABLE.addListener;
  /**
   * Removes an event handler (shorthand for {@link #removeListener}.)
   * @param {String}   eventName     The type of event the handler was associated with.
   * @param {Function} handler       The handler to remove. <b>This must be a reference to the function passed into the {@link #addListener} call.</b>
   * @param {Object}   scope         (optional) The scope originally specified for the handler.
   * @method
   */

  OBSERVABLE.un = OBSERVABLE.removeListener;
  /**
   * Removes <b>all</b> added captures from the Observable.
   * @param {Observable} o The Observable to release
   * @static
   */

  EXTUTIL.Observable.releaseCapture = function (o) {
    o.fireEvent = OBSERVABLE.fireEvent;
  };

  function createTargeted(h, o, scope) {
    return function () {
      if (o.target == arguments[0]) {
        h.apply(scope, TOARRAY(arguments));
      }
    };
  }

  ;

  function createBuffered(h, o, l, scope) {
    l.task = new EXTUTIL.DelayedTask();
    return function () {
      l.task.delay(o.buffer, h, scope, TOARRAY(arguments));
    };
  }

  ;

  function createSingle(h, e, fn, scope) {
    return function () {
      e.removeListener(fn, scope);
      return h.apply(scope, arguments);
    };
  }

  ;

  function createDelayed(h, o, l, scope) {
    return function () {
      var task = new EXTUTIL.DelayedTask();

      if (!l.tasks) {
        l.tasks = [];
      }

      l.tasks.push(task);
      task.delay(o.delay || 10, h, scope, TOARRAY(arguments));
    };
  }

  ;

  EXTUTIL.Event = function (obj, name) {
    this.name = name;
    this.obj = obj;
    this.listeners = [];
    this.isAsync = null;
  };

  EXTUTIL.Event.prototype = {
    addListener: function addListener(fn, scope, options) {
      var me = this,
          l;
      scope = scope || me.obj;

      if (!me.isListening(fn, scope)) {
        l = me.createListener(fn, scope, options);

        if (fn && fn.constructor.name === "AsyncFunction" && !Ext.isBoolean(me.isAsync)) {
          me.isAsync = true;
        }

        if (me.firing) {
          // if we are currently firing this event, don't disturb the listener loop
          me.listeners = me.listeners.slice(0);
        }

        me.listeners.push(l);
      }
    },
    createListener: function createListener(fn, scope, o) {
      o = o || {}, scope = scope || this.obj;
      var l = {
        fn: fn,
        scope: scope,
        options: o
      },
          h = fn;

      if (o.target) {
        h = createTargeted(h, o, scope);
      }

      if (o.delay) {
        h = createDelayed(h, o, l, scope);
      }

      if (o.single) {
        h = createSingle(h, this, fn, scope);
      }

      if (o.buffer) {
        h = createBuffered(h, o, l, scope);
      }

      l.fireFn = h;
      return l;
    },
    findListener: function findListener(fn, scope) {
      var list = this.listeners,
          i = list.length,
          l,
          s;

      while (i--) {
        l = list[i];

        if (l) {
          s = l.scope;

          if (l.fn == fn && (s == scope || s == this.obj)) {
            return i;
          }
        }
      }

      return -1;
    },
    isListening: function isListening(fn, scope) {
      return this.findListener(fn, scope) != -1;
    },
    removeListener: function removeListener(fn, scope) {
      var index,
          l,
          k,
          me = this,
          ret = FALSE;

      if ((index = me.findListener(fn, scope)) != -1) {
        if (me.firing) {
          me.listeners = me.listeners.slice(0);
        }

        l = me.listeners[index];

        if (l.task) {
          l.task.cancel();
          delete l.task;
        }

        k = l.tasks && l.tasks.length;

        if (k) {
          while (k--) {
            l.tasks[k].cancel();
          }

          delete l.tasks;
        }

        me.listeners.splice(index, 1);
        ret = TRUE;
      }

      return ret;
    },
    // Iterate to stop any buffered/delayed events
    clearListeners: function clearListeners() {
      var me = this,
          l = me.listeners,
          i = l.length;

      while (i--) {
        me.removeListener(l[i].fn, l[i].scope);
      }
    },
    fire: function fire() {
      var me = this,
          args = TOARRAY(arguments),
          listeners = me.listeners,
          len = listeners.length,
          i = 0,
          l,
          r,
          pms = [];

      if (len > 0) {
        me.firing = TRUE;

        for (; i < len; i++) {
          l = listeners[i];

          if (l) {
            r = l.fireFn.apply(l.scope || me.obj || window, args);

            if (r === FALSE) {
              if (!me.isAsync) {
                return me.firing = FALSE;
              }

              r = Promise.reject(l.name + ' returned false');
            }

            if (r && Ext.isFunction(r.then)) {
              pms.push(r);
            }
          }
        }
      }

      me.firing = FALSE;
      return pms.length || me.isAsync ? Promise.all(pms) : TRUE;
    }
  };
})();

/***/ }),
/* 713 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.Observable
 */
Ext.apply(Ext.util.Observable.prototype, function () {
  // this is considered experimental (along with beforeMethod, afterMethod, removeMethodListener?)
  // allows for easier interceptor and sequences, including cancelling and overwriting the return value of the call
  // private
  function getMethodEvent(method) {
    var e = (this.methodEvents = this.methodEvents || {})[method],
        returnValue,
        v,
        cancel,
        obj = this;

    if (!e) {
      this.methodEvents[method] = e = {};
      e.originalFn = this[method];
      e.methodName = method;
      e.before = [];
      e.after = [];

      var makeCall = function makeCall(fn, scope, args) {
        if (!Ext.isEmpty(v = fn.apply(scope || obj, args))) {
          if (Ext.isObject(v)) {
            returnValue = !Ext.isEmpty(v.returnValue) ? v.returnValue : v;
            cancel = !!v.cancel;
          } else if (v === false) {
            cancel = true;
          } else {
            returnValue = v;
          }
        }
      };

      this[method] = function () {
        var args = Ext.toArray(arguments);
        returnValue = v = undefined;
        cancel = false;
        Ext.each(e.before, function (b) {
          makeCall(b.fn, b.scope, args);

          if (cancel) {
            return returnValue;
          }
        });

        if (!Ext.isEmpty(v = e.originalFn.apply(obj, args))) {
          returnValue = v;
        }

        Ext.each(e.after, function (a) {
          makeCall(a.fn, a.scope, args);

          if (cancel) {
            return returnValue;
          }
        });
        return returnValue;
      };
    }

    return e;
  }

  return {
    // these are considered experimental
    // allows for easier interceptor and sequences, including cancelling and overwriting the return value of the call
    // adds an 'interceptor' called before the original method
    beforeMethod: function beforeMethod(method, fn, scope) {
      getMethodEvent.call(this, method).before.push({
        fn: fn,
        scope: scope
      });
    },
    // adds a 'sequence' called after the original method
    afterMethod: function afterMethod(method, fn, scope) {
      getMethodEvent.call(this, method).after.push({
        fn: fn,
        scope: scope
      });
    },
    removeMethodListener: function removeMethodListener(method, fn, scope) {
      var e = getMethodEvent.call(this, method),
          found = false;
      Ext.each(e.before, function (b, i, arr) {
        if (b.fn == fn && b.scope == scope) {
          arr.splice(i, 1);
          found = true;
          return false;
        }
      });

      if (!found) {
        Ext.each(e.after, function (a, i, arr) {
          if (a.fn == fn && a.scope == scope) {
            arr.splice(i, 1);
            return false;
          }
        });
      }
    },

    /**
     * Relays selected events from the specified Observable as if the events were fired by <tt><b>this</b></tt>.
     * @param {Object} o The Observable whose events this object is to relay.
     * @param {Array} events Array of event names to relay.
     */
    relayEvents: function relayEvents(o, events) {
      var me = this;

      function createHandler(ename) {
        return function () {
          return me.fireEvent.apply(me, [ename].concat(Ext.toArray(arguments)));
        };
      }

      Ext.each(events, function (ename) {
        me.events[ename] = me.events[ename] || true;
        o.on(ename, createHandler(ename), me);
      });
    },

    /**
     * <p>Enables events fired by this Observable to bubble up an owner hierarchy by calling
     * <code>this.getBubbleTarget()</code> if present. There is no implementation in the Observable base class.</p>
     * <p>This is commonly used by Ext.Components to bubble events to owner Containers. See {@link Ext.Component.getBubbleTarget}. The default
     * implementation in Ext.Component returns the Component's immediate owner. But if a known target is required, this can be overridden to
     * access the required target more quickly.</p>
     * <p>Example:</p><pre><code>
    Ext.override(Ext.form.Field, {
    //  Add functionality to Field&#39;s initComponent to enable the change event to bubble
    initComponent : Ext.form.Field.prototype.initComponent.createSequence(function() {
    this.enableBubble('change');
    }),
    //  We know that we want Field&#39;s events to bubble directly to the FormPanel.
    getBubbleTarget : function() {
    if (!this.formPanel) {
        this.formPanel = this.findParentByType('form');
    }
    return this.formPanel;
    }
    });
    var myForm = new Ext.formPanel({
    title: 'User Details',
    items: [{
    ...
    }],
    listeners: {
    change: function() {
        // Title goes red if form has been modified.
        myForm.header.setStyle('color', 'red');
    }
    }
    });
    </code></pre>
     * @param {String/Array} events The event name to bubble, or an Array of event names.
     */
    enableBubble: function enableBubble(events) {
      var me = this;

      if (!Ext.isEmpty(events)) {
        events = Ext.isArray(events) ? events : Ext.toArray(arguments);
        Ext.each(events, function (ename) {
          ename = ename.toLowerCase();
          var ce = me.events[ename] || true;

          if (Ext.isBoolean(ce)) {
            ce = new Ext.util.Event(me, ename);
            me.events[ename] = ce;
          }

          ce.bubble = true;
        });
      }
    }
  };
}());
/**
 * Starts capture on the specified Observable. All events will be passed
 * to the supplied function with the event name + standard signature of the event
 * <b>before</b> the event is fired. If the supplied function returns false,
 * the event will not fire.
 * @param {Observable} o The Observable to capture events from.
 * @param {Function} fn The function to call when an event is fired.
 * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the Observable firing the event.
 * @static
 */

Ext.util.Observable.capture = function (o, fn, scope) {
  o.fireEvent = o.fireEvent.createInterceptor(fn, scope);
};
/**
 * Sets observability on the passed class constructor.<p>
 * <p>This makes any event fired on any instance of the passed class also fire a single event through
 * the <i>class</i> allowing for central handling of events on many instances at once.</p>
 * <p>Usage:</p><pre><code>
Ext.util.Observable.observeClass(Ext.data.Connection);
Ext.data.Connection.on('beforerequest', function(con, options) {
    console.log('Ajax request made to ' + options.url);
});</code></pre>
 * @param {Function} c The class constructor to make observable.
 * @param {Object} listeners An object containing a series of listeners to add. See {@link #addListener}. 
 * @static
 */


Ext.util.Observable.observeClass = function (c, listeners) {
  if (c) {
    if (!c.fireEvent) {
      Ext.apply(c, new Ext.util.Observable());
      Ext.util.Observable.capture(c.prototype, c.fireEvent, c);
    }

    if (Ext.isObject(listeners)) {
      c.on(listeners);
    }

    return c;
  }
};

/***/ }),
/* 714 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.EventManager
 * Registers event handlers that want to receive a normalized EventObject instead of the standard browser event and provides
 * several useful events directly.
 * See {@link Ext.EventObject} for more details on normalized event objects.
 * @singleton
 */
Ext.EventManager = function () {
  var docReadyEvent,
      docReadyProcId,
      docReadyState = false,
      E = Ext.lib.Event,
      D = Ext.lib.Dom,
      DOC = document,
      WINDOW = window,
      IEDEFERED = "ie-deferred-loader",
      DOMCONTENTLOADED = "DOMContentLoaded",
      propRe = /^(?:scope|delay|buffer|single|stopEvent|preventDefault|stopPropagation|normalized|args|delegate)$/,

  /*
   * This cache is used to hold special js objects, the document and window, that don't have an id. We need to keep
   * a reference to them so we can look them up at a later point.
   */
  specialElCache = [];

  function getId(el) {
    var id = false,
        i = 0,
        len = specialElCache.length,
        id = false,
        skip = false,
        o;

    if (el) {
      if (el.getElementById || el.navigator) {
        // look up the id
        for (; i < len; ++i) {
          o = specialElCache[i];

          if (o.el === el) {
            id = o.id;
            break;
          }
        }

        if (!id) {
          // for browsers that support it, ensure that give the el the same id
          id = Ext.id(el);
          specialElCache.push({
            id: id,
            el: el
          });
          skip = true;
        }
      } else {
        id = Ext.id(el);
      }

      if (!Ext.elCache[id]) {
        Ext.Element.addToCache(new Ext.Element(el), id);

        if (skip) {
          Ext.elCache[id].skipGC = true;
        }
      }
    }

    return id;
  }

  ; /// There is some jquery work around stuff here that isn't needed in Ext Core.

  function addListener(el, ename, fn, task, wrap, scope) {
    el = Ext.getDom(el);
    var id = getId(el),
        es = Ext.elCache[id].events,
        wfn;
    wfn = E.on(el, ename, wrap);
    es[ename] = es[ename] || [];
    /* 0 = Original Function,
       1 = Event Manager Wrapped Function,
       2 = Scope,
       3 = Adapter Wrapped Function,
       4 = Buffered Task
    */

    es[ename].push([fn, wrap, scope, wfn, task]); // this is a workaround for jQuery and should somehow be removed from Ext Core in the future
    // without breaking ExtJS.
    // workaround for jQuery

    if (el.addEventListener && ename == "mousewheel") {
      var args = ["DOMMouseScroll", wrap, false];
      el.addEventListener.apply(el, args);
      Ext.EventManager.addListener(WINDOW, 'unload', function () {
        el.removeEventListener.apply(el, args);
      });
    } // fix stopped mousedowns on the document


    if (el == DOC && ename == "mousedown") {
      Ext.EventManager.stoppedMouseDownEvent.addListener(wrap);
    }
  }

  ;

  function fireDocReady() {
    if (!docReadyState) {
      Ext.isReady = docReadyState = true;

      if (docReadyProcId) {
        clearInterval(docReadyProcId);
      }

      if (Ext.isGecko || Ext.isOpera) {
        DOC.removeEventListener(DOMCONTENTLOADED, fireDocReady, false);
      }

      if (Ext.isIE) {
        var defer = DOC.getElementById(IEDEFERED);

        if (defer) {
          defer.onreadystatechange = null;
          defer.parentNode.removeChild(defer);
        }
      }

      if (docReadyEvent) {
        docReadyEvent.fire();
        docReadyEvent.listeners = []; // clearListeners no longer compatible.  Force single: true?
      }
    }
  }

  ;

  function initDocReady() {
    var COMPLETE = "complete";
    docReadyEvent = new Ext.util.Event();

    if (Ext.isGecko || Ext.isOpera) {
      DOC.addEventListener(DOMCONTENTLOADED, fireDocReady, false);
    } else if (Ext.isIE) {
      DOC.write("<s" + 'cript id=' + IEDEFERED + ' defer="defer" src="Tinebase/js/empty.js"></s' + "cript>");

      DOC.getElementById(IEDEFERED).onreadystatechange = function () {
        if (this.readyState == COMPLETE) {
          fireDocReady();
        }
      };
    } else if (Ext.isWebKit) {
      docReadyProcId = setInterval(function () {
        if (DOC.readyState == COMPLETE) {
          fireDocReady();
        }
      }, 10);
    } // no matter what, make sure it fires on load


    E.on(WINDOW, "load", fireDocReady);
  }

  ;

  function createTargeted(h, o) {
    return function () {
      var args = Ext.toArray(arguments);

      if (o.target == Ext.EventObject.setEvent(args[0]).target) {
        h.apply(this, args);
      }
    };
  }

  ;

  function createBuffered(h, o, task) {
    return function (e) {
      // create new event object impl so new events don't wipe out properties
      task.delay(o.buffer, h, null, [new Ext.EventObjectImpl(e)]);
    };
  }

  ;

  function createSingle(h, el, ename, fn, scope) {
    return function (e) {
      Ext.EventManager.removeListener(el, ename, fn, scope);
      h(e);
    };
  }

  ;

  function createDelayed(h, o, fn) {
    return function (e) {
      var task = new Ext.util.DelayedTask(h);

      if (!fn.tasks) {
        fn.tasks = [];
      }

      fn.tasks.push(task);
      task.delay(o.delay || 10, h, null, [new Ext.EventObjectImpl(e)]);
    };
  }

  ;

  function listen(element, ename, opt, fn, scope) {
    var o = !Ext.isObject(opt) ? {} : opt,
        el = Ext.getDom(element),
        task;
    fn = fn || o.fn;
    scope = scope || o.scope;

    if (!el) {
      throw "Error listening for \"" + ename + '\". Element "' + element + '" doesn\'t exist.';
    }

    function h(e) {
      // prevent errors while unload occurring
      if (!Ext) {
        // !window[xname]){  ==> can't we do this?
        return;
      }

      e = Ext.EventObject.setEvent(e);
      var t;

      if (o.delegate) {
        if (!(t = e.getTarget(o.delegate, el))) {
          return;
        }
      } else {
        t = e.target;
      }

      if (o.stopEvent) {
        e.stopEvent();
      }

      if (o.preventDefault) {
        e.preventDefault();
      }

      if (o.stopPropagation) {
        e.stopPropagation();
      }

      if (o.normalized) {
        e = e.browserEvent;
      }

      fn.call(scope || el, e, t, o);
    }

    ;

    if (o.target) {
      h = createTargeted(h, o);
    }

    if (o.delay) {
      h = createDelayed(h, o, fn);
    }

    if (o.single) {
      h = createSingle(h, el, ename, fn, scope);
    }

    if (o.buffer) {
      task = new Ext.util.DelayedTask(h);
      h = createBuffered(h, o, task);
    }

    addListener(el, ename, fn, task, h, scope);
    return h;
  }

  ;
  var pub = {
    /**
     * Appends an event handler to an element.  The shorthand version {@link #on} is equivalent.  Typically you will
     * use {@link Ext.Element#addListener} directly on an Element in favor of calling this version.
     * @param {String/HTMLElement} el The html element or id to assign the event handler to.
     * @param {String} eventName The name of the event to listen for.
     * @param {Function} handler The handler function the event invokes. This function is passed
     * the following parameters:<ul>
     * <li>evt : EventObject<div class="sub-desc">The {@link Ext.EventObject EventObject} describing the event.</div></li>
     * <li>t : Element<div class="sub-desc">The {@link Ext.Element Element} which was the target of the event.
     * Note that this may be filtered by using the <tt>delegate</tt> option.</div></li>
     * <li>o : Object<div class="sub-desc">The options object from the addListener call.</div></li>
     * </ul>
     * @param {Object} scope (optional) The scope (<b><code>this</code></b> reference) in which the handler function is executed. <b>Defaults to the Element</b>.
     * @param {Object} options (optional) An object containing handler configuration properties.
     * This may contain any of the following properties:<ul>
     * <li>scope : Object<div class="sub-desc">The scope (<b><code>this</code></b> reference) in which the handler function is executed. <b>Defaults to the Element</b>.</div></li>
     * <li>delegate : String<div class="sub-desc">A simple selector to filter the target or look for a descendant of the target</div></li>
     * <li>stopEvent : Boolean<div class="sub-desc">True to stop the event. That is stop propagation, and prevent the default action.</div></li>
     * <li>preventDefault : Boolean<div class="sub-desc">True to prevent the default action</div></li>
     * <li>stopPropagation : Boolean<div class="sub-desc">True to prevent event propagation</div></li>
     * <li>normalized : Boolean<div class="sub-desc">False to pass a browser event to the handler function instead of an Ext.EventObject</div></li>
     * <li>delay : Number<div class="sub-desc">The number of milliseconds to delay the invocation of the handler after te event fires.</div></li>
     * <li>single : Boolean<div class="sub-desc">True to add a handler to handle just the next firing of the event, and then remove itself.</div></li>
     * <li>buffer : Number<div class="sub-desc">Causes the handler to be scheduled to run in an {@link Ext.util.DelayedTask} delayed
     * by the specified number of milliseconds. If the event fires again within that time, the original
     * handler is <em>not</em> invoked, but the new handler is scheduled in its place.</div></li>
     * <li>target : Element<div class="sub-desc">Only call the handler if the event was fired on the target Element, <i>not</i> if the event was bubbled up from a child node.</div></li>
     * </ul><br>
     * <p>See {@link Ext.Element#addListener} for examples of how to use these options.</p>
     */
    addListener: function addListener(element, eventName, fn, scope, options) {
      if (Ext.isObject(eventName)) {
        var o = eventName,
            e,
            val;

        for (e in o) {
          val = o[e];

          if (!propRe.test(e)) {
            if (Ext.isFunction(val)) {
              // shared options
              listen(element, e, o, val, o.scope);
            } else {
              // individual options
              listen(element, e, val);
            }
          }
        }
      } else {
        listen(element, eventName, options, fn, scope);
      }
    },

    /**
     * Removes an event handler from an element.  The shorthand version {@link #un} is equivalent.  Typically
     * you will use {@link Ext.Element#removeListener} directly on an Element in favor of calling this version.
     * @param {String/HTMLElement} el The id or html element from which to remove the listener.
     * @param {String} eventName The name of the event.
     * @param {Function} fn The handler function to remove. <b>This must be a reference to the function passed into the {@link #addListener} call.</b>
     * @param {Object} scope If a scope (<b><code>this</code></b> reference) was specified when the listener was added,
     * then this must refer to the same object.
     */
    removeListener: function removeListener(el, eventName, fn, scope) {
      el = Ext.getDom(el);
      var id = getId(el),
          f = el && Ext.elCache[id].events[eventName] || [],
          wrap,
          i,
          l,
          k,
          len,
          fnc;

      for (i = 0, len = f.length; i < len; i++) {
        /* 0 = Original Function,
           1 = Event Manager Wrapped Function,
           2 = Scope,
           3 = Adapter Wrapped Function,
           4 = Buffered Task
        */
        if (Ext.isArray(fnc = f[i]) && fnc[0] == fn && (!scope || fnc[2] == scope)) {
          if (fnc[4]) {
            fnc[4].cancel();
          }

          k = fn.tasks && fn.tasks.length;

          if (k) {
            while (k--) {
              fn.tasks[k].cancel();
            }

            delete fn.tasks;
          }

          wrap = fnc[1];
          E.un(el, eventName, E.extAdapter ? fnc[3] : wrap); // jQuery workaround that should be removed from Ext Core

          if (wrap && el.addEventListener && eventName == "mousewheel") {
            el.removeEventListener("DOMMouseScroll", wrap, false);
          } // fix stopped mousedowns on the document


          if (wrap && el == DOC && eventName == "mousedown") {
            Ext.EventManager.stoppedMouseDownEvent.removeListener(wrap);
          }

          f.splice(i, 1);

          if (f.length === 0) {
            delete Ext.elCache[id].events[eventName];
          }

          for (k in Ext.elCache[id].events) {
            return false;
          }

          Ext.elCache[id].events = {};
          return false;
        }
      }
    },

    /**
     * Removes all event handers from an element.  Typically you will use {@link Ext.Element#removeAllListeners}
     * directly on an Element in favor of calling this version.
     * @param {String/HTMLElement} el The id or html element from which to remove all event handlers.
     */
    removeAll: function removeAll(el) {
      el = Ext.getDom(el);
      var id = getId(el),
          ec = Ext.elCache[id] || {},
          es = ec.events || {},
          f,
          i,
          len,
          ename,
          fn,
          k,
          wrap;

      for (ename in es) {
        if (es.hasOwnProperty(ename)) {
          f = es[ename];
          /* 0 = Original Function,
             1 = Event Manager Wrapped Function,
             2 = Scope,
             3 = Adapter Wrapped Function,
             4 = Buffered Task
          */

          for (i = 0, len = f.length; i < len; i++) {
            fn = f[i];

            if (fn[4]) {
              fn[4].cancel();
            }

            if (fn[0].tasks && (k = fn[0].tasks.length)) {
              while (k--) {
                fn[0].tasks[k].cancel();
              }

              delete fn.tasks;
            }

            wrap = fn[1];
            E.un(el, ename, E.extAdapter ? fn[3] : wrap); // jQuery workaround that should be removed from Ext Core

            if (el.addEventListener && wrap && ename == "mousewheel") {
              el.removeEventListener("DOMMouseScroll", wrap, false);
            } // fix stopped mousedowns on the document


            if (wrap && el == DOC && ename == "mousedown") {
              Ext.EventManager.stoppedMouseDownEvent.removeListener(wrap);
            }
          }
        }
      }

      if (Ext.elCache[id]) {
        Ext.elCache[id].events = {};
      }
    },
    getListeners: function getListeners(el, eventName) {
      el = Ext.getDom(el);
      var id = getId(el),
          ec = Ext.elCache[id] || {},
          es = ec.events || {},
          results = [];

      if (es && es[eventName]) {
        return es[eventName];
      } else {
        return null;
      }
    },
    purgeElement: function purgeElement(el, recurse, eventName) {
      el = Ext.getDom(el);
      var id = getId(el),
          ec = Ext.elCache[id] || {},
          es = ec.events || {},
          i,
          f,
          len;

      if (eventName) {
        if (es && es.hasOwnProperty(eventName)) {
          f = es[eventName];

          for (i = 0, len = f.length; i < len; i++) {
            Ext.EventManager.removeListener(el, eventName, f[i][0]);
          }
        }
      } else {
        Ext.EventManager.removeAll(el);
      }

      if (recurse && el && el.childNodes) {
        for (i = 0, len = el.childNodes.length; i < len; i++) {
          Ext.EventManager.purgeElement(el.childNodes[i], recurse, eventName);
        }
      }
    },
    _unload: function _unload() {
      var el;

      for (el in Ext.elCache) {
        Ext.EventManager.removeAll(el);
      }

      delete Ext.elCache;
      delete Ext.Element._flyweights;
    },

    /**
     * Adds a listener to be notified when the document is ready (before onload and before images are loaded). Can be
     * accessed shorthanded as Ext.onReady().
     * @param {Function} fn The method the event invokes.
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the handler function executes. Defaults to the browser window.
     * @param {boolean} options (optional) Options object as passed to {@link Ext.Element#addListener}. It is recommended that the options
     * <code>{single: true}</code> be used so that the handler is removed on first invocation.
     */
    onDocumentReady: function onDocumentReady(fn, scope, options) {
      if (docReadyState) {
        // if it already fired
        docReadyEvent.addListener(fn, scope, options);
        docReadyEvent.fire();
        docReadyEvent.listeners = []; // clearListeners no longer compatible.  Force single: true?
      } else {
        if (!docReadyEvent) initDocReady();
        options = options || {};
        options.delay = options.delay || 1;
        docReadyEvent.addListener(fn, scope, options);
      }
    }
  };
  /**
  * Appends an event handler to an element.  Shorthand for {@link #addListener}.
  * @param {String/HTMLElement} el The html element or id to assign the event handler to
  * @param {String} eventName The name of the event to listen for.
  * @param {Function} handler The handler function the event invokes.
  * @param {Object} scope (optional) (<code>this</code> reference) in which the handler function executes. <b>Defaults to the Element</b>.
  * @param {Object} options (optional) An object containing standard {@link #addListener} options
  * @member Ext.EventManager
  * @method on
  */

  pub.on = pub.addListener;
  /**
   * Removes an event handler from an element.  Shorthand for {@link #removeListener}.
   * @param {String/HTMLElement} el The id or html element from which to remove the listener.
   * @param {String} eventName The name of the event.
   * @param {Function} fn The handler function to remove. <b>This must be a reference to the function passed into the {@link #on} call.</b>
   * @param {Object} scope If a scope (<b><code>this</code></b> reference) was specified when the listener was added,
   * then this must refer to the same object.
   * @member Ext.EventManager
   * @method un
   */

  pub.un = pub.removeListener;
  pub.stoppedMouseDownEvent = new Ext.util.Event();
  return pub;
}();
/**
  * Adds a listener to be notified when the document is ready (before onload and before images are loaded). Shorthand of {@link Ext.EventManager#onDocumentReady}.
  * @param {Function} fn The method the event invokes.
  * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the handler function executes. Defaults to the browser window.
  * @param {boolean} options (optional) Options object as passed to {@link Ext.Element#addListener}. It is recommended that the options
  * <code>{single: true}</code> be used so that the handler is removed on first invocation.
  * @member Ext
  * @method onReady
 */


Ext.onReady = Ext.EventManager.onDocumentReady; //Initialize doc classes

(function () {
  var initExtCss = function initExtCss() {
    // find the body element
    var bd = document.body || document.getElementsByTagName('body')[0];

    if (!bd) {
      return false;
    }

    var cls = [' ', Ext.isIE ? "ext-ie " + (Ext.isIE6 ? 'ext-ie6' : Ext.isIE7 ? 'ext-ie7' : 'ext-ie8') : Ext.isGecko ? "ext-gecko " + (Ext.isGecko2 ? 'ext-gecko2' : 'ext-gecko3') : Ext.isOpera ? "ext-opera" : Ext.isWebKit ? "ext-webkit" : ""];

    if (Ext.isSafari) {
      cls.push("ext-safari " + (Ext.isSafari2 ? 'ext-safari2' : Ext.isSafari3 ? 'ext-safari3' : 'ext-safari4'));
    } else if (Ext.isChrome) {
      cls.push("ext-chrome");
    }

    if (Ext.isMac) {
      cls.push("ext-mac");
    }

    if (Ext.isLinux) {
      cls.push("ext-linux");
    }

    if (Ext.isStrict || Ext.isBorderBox) {
      // add to the parent to allow for selectors like ".ext-strict .ext-ie"
      var p = bd.parentNode;

      if (p) {
        p.className += Ext.isStrict ? ' ext-strict' : ' ext-border-box';
      }
    }

    bd.className += cls.join(' ');
    return true;
  };

  if (!initExtCss()) {
    Ext.onReady(initExtCss);
  }
})();
/**
 * @class Ext.EventObject
 * Just as {@link Ext.Element} wraps around a native DOM node, Ext.EventObject
 * wraps the browser's native event-object normalizing cross-browser differences,
 * such as which mouse button is clicked, keys pressed, mechanisms to stop
 * event-propagation along with a method to prevent default actions from taking place.
 * <p>For example:</p>
 * <pre><code>
function handleClick(e, t){ // e is not a standard event object, it is a Ext.EventObject
    e.preventDefault();
    var target = e.getTarget(); // same as t (the target HTMLElement)
    ...
}
var myDiv = {@link Ext#get Ext.get}("myDiv");  // get reference to an {@link Ext.Element}
myDiv.on(         // 'on' is shorthand for addListener
    "click",      // perform an action on click of myDiv
    handleClick   // reference to the action handler
);
// other methods to do the same:
Ext.EventManager.on("myDiv", 'click', handleClick);
Ext.EventManager.addListener("myDiv", 'click', handleClick);
 </code></pre>
 * @singleton
 */


Ext.EventObject = function () {
  var E = Ext.lib.Event,
      // safari keypress events for special keys return bad keycodes
  safariKeys = {
    3: 13,
    // enter
    63234: 37,
    // left
    63235: 39,
    // right
    63232: 38,
    // up
    63233: 40,
    // down
    63276: 33,
    // page up
    63277: 34,
    // page down
    63272: 46,
    // delete
    63273: 36,
    // home
    63275: 35 // end

  },
      // normalize button clicks
  btnMap = Ext.isIE ? {
    1: 0,
    4: 1,
    2: 2
  } : Ext.isWebKit ? {
    1: 0,
    2: 1,
    3: 2
  } : {
    0: 0,
    1: 1,
    2: 2
  };

  Ext.EventObjectImpl = function (e) {
    if (e) {
      this.setEvent(e.browserEvent || e);
    }
  };

  Ext.EventObjectImpl.prototype = {
    /** @private */
    setEvent: function setEvent(e) {
      var me = this;

      if (e == me || e && e.browserEvent) {
        // already wrapped
        return e;
      }

      me.browserEvent = e;

      if (e) {
        // normalize buttons
        me.button = e.button ? btnMap[e.button] : e.which ? e.which - 1 : -1;

        if (e.type == 'click' && me.button == -1) {
          me.button = 0;
        }

        me.type = e.type;
        me.shiftKey = e.shiftKey; // mac metaKey behaves like ctrlKey

        me.ctrlKey = e.ctrlKey || e.metaKey || false;
        me.altKey = e.altKey; // in getKey these will be normalized for the mac

        me.keyCode = e.keyCode;
        me.charCode = e.charCode; // cache the target for the delayed and or buffered events

        me.target = E.getTarget(e); // same for XY

        me.xy = E.getXY(e);
      } else {
        me.button = -1;
        me.shiftKey = false;
        me.ctrlKey = false;
        me.altKey = false;
        me.keyCode = 0;
        me.charCode = 0;
        me.target = null;
        me.xy = [0, 0];
      }

      return me;
    },

    /**
     * Stop the event (preventDefault and stopPropagation)
     */
    stopEvent: function stopEvent() {
      var me = this;

      if (me.browserEvent) {
        if (me.browserEvent.type == 'mousedown') {
          Ext.EventManager.stoppedMouseDownEvent.fire(me);
        }

        E.stopEvent(me.browserEvent);
      }
    },

    /**
     * Prevents the browsers default handling of the event.
     */
    preventDefault: function preventDefault() {
      if (this.browserEvent) {
        E.preventDefault(this.browserEvent);
      }
    },

    /**
     * Cancels bubbling of the event.
     */
    stopPropagation: function stopPropagation() {
      var me = this;

      if (me.browserEvent) {
        if (me.browserEvent.type == 'mousedown') {
          Ext.EventManager.stoppedMouseDownEvent.fire(me);
        }

        E.stopPropagation(me.browserEvent);
      }
    },

    /**
     * Gets the character code for the event.
     * @return {Number}
     */
    getCharCode: function getCharCode() {
      return this.charCode || this.keyCode;
    },

    /**
     * Returns a normalized keyCode for the event.
     * @return {Number} The key code
     */
    getKey: function getKey() {
      return this.normalizeKey(this.keyCode || this.charCode);
    },
    // private
    normalizeKey: function normalizeKey(k) {
      return Ext.isSafari ? safariKeys[k] || k : k;
    },

    /**
     * Gets the x coordinate of the event.
     * @return {Number}
     */
    getPageX: function getPageX() {
      return this.xy[0];
    },

    /**
     * Gets the y coordinate of the event.
     * @return {Number}
     */
    getPageY: function getPageY() {
      return this.xy[1];
    },

    /**
     * Gets the page coordinates of the event.
     * @return {Array} The xy values like [x, y]
     */
    getXY: function getXY() {
      return this.xy;
    },

    /**
     * Gets the target for the event.
     * @param {String} selector (optional) A simple selector to filter the target or look for an ancestor of the target
     * @param {Number/Mixed} maxDepth (optional) The max depth to
            search as a number or element (defaults to 10 || document.body)
     * @param {Boolean} returnEl (optional) True to return a Ext.Element object instead of DOM node
     * @return {HTMLelement}
     */
    getTarget: function getTarget(selector, maxDepth, returnEl) {
      return selector ? Ext.fly(this.target).findParent(selector, maxDepth, returnEl) : returnEl ? Ext.get(this.target) : this.target;
    },

    /**
     * Gets the related target.
     * @return {HTMLElement}
     */
    getRelatedTarget: function getRelatedTarget() {
      return this.browserEvent ? E.getRelatedTarget(this.browserEvent) : null;
    },

    /**
     * Normalizes mouse wheel delta across browsers
     * @return {Number} The delta
     */
    getWheelDelta: function getWheelDelta() {
      var e = this.browserEvent;
      var delta = 0;

      if (e.wheelDelta) {
        /* IE/Opera. */
        delta = e.wheelDelta / 120;
      } else if (e.detail) {
        /* Mozilla case. */
        delta = -e.detail / 3;
      }

      return delta;
    },

    /**
    * Returns true if the target of this event is a child of el.  Unless the allowEl parameter is set, it will return false if if the target is el.
    * Example usage:<pre><code>
    // Handle click on any child of an element
    Ext.getBody().on('click', function(e){
        if(e.within('some-el')){
            alert('Clicked on a child of some-el!');
        }
    });
      // Handle click directly on an element, ignoring clicks on child nodes
    Ext.getBody().on('click', function(e,t){
        if((t.id == 'some-el') && !e.within(t, true)){
            alert('Clicked directly on some-el!');
        }
    });
    </code></pre>
     * @param {Mixed} el The id, DOM element or Ext.Element to check
     * @param {Boolean} related (optional) true to test if the related target is within el instead of the target
     * @param {Boolean} allowEl {optional} true to also check if the passed element is the target or related target
     * @return {Boolean}
     */
    within: function within(el, related, allowEl) {
      if (el) {
        var t = this[related ? "getRelatedTarget" : "getTarget"]();
        return t && ((allowEl ? t == Ext.getDom(el) : false) || Ext.fly(el).contains(t));
      }

      return false;
    }
  };
  return new Ext.EventObjectImpl();
}();

/***/ }),
/* 715 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
* @class Ext.EventManager
*/
Ext.apply(Ext.EventManager, function () {
  var resizeEvent,
      resizeTask,
      textEvent,
      textSize,
      D = Ext.lib.Dom,
      propRe = /^(?:scope|delay|buffer|single|stopEvent|preventDefault|stopPropagation|normalized|args|delegate)$/,
      curWidth = 0,
      curHeight = 0,
      // note 1: IE fires ONLY the keydown event on specialkey autorepeat
  // note 2: Safari < 3.1, Gecko (Mac/Linux) & Opera fire only the keypress event on specialkey autorepeat
  // (research done by @Jan Wolter at http://unixpapa.com/js/key.html)
  useKeydown = true;
  return {
    // private
    doResizeEvent: function doResizeEvent() {
      var h = D.getViewHeight(),
          w = D.getViewWidth(); //whacky problem in IE where the resize event will fire even though the w/h are the same.

      if (curHeight != h || curWidth != w) {
        resizeEvent.fire(curWidth = w, curHeight = h);
      }
    },

    /**
     * Adds a listener to be notified when the browser window is resized and provides resize event buffering (100 milliseconds),
     * passes new viewport width and height to handlers.
     * @param {Function} fn      The handler function the window resize event invokes.
     * @param {Object}   scope   The scope (<code>this</code> reference) in which the handler function executes. Defaults to the browser window.
     * @param {boolean}  options Options object as passed to {@link Ext.Element#addListener}
     */
    onWindowResize: function onWindowResize(fn, scope, options) {
      if (!resizeEvent) {
        resizeEvent = new Ext.util.Event();
        resizeTask = new Ext.util.DelayedTask(this.doResizeEvent);
        Ext.EventManager.on(window, "resize", this.fireWindowResize, this);
      }

      resizeEvent.addListener(fn, scope, options);
    },
    // exposed only to allow manual firing
    fireWindowResize: function fireWindowResize() {
      if (resizeEvent) {
        resizeTask.delay(100);
      }
    },

    /**
     * Adds a listener to be notified when the user changes the active text size. Handler gets called with 2 params, the old size and the new size.
     * @param {Function} fn      The function the event invokes.
     * @param {Object}   scope   The scope (<code>this</code> reference) in which the handler function executes. Defaults to the browser window.
     * @param {boolean}  options Options object as passed to {@link Ext.Element#addListener}
     */
    onTextResize: function onTextResize(fn, scope, options) {
      if (!textEvent) {
        textEvent = new Ext.util.Event();
        var textEl = new Ext.Element(document.createElement('div'));
        textEl.dom.className = 'x-text-resize';
        textEl.dom.innerHTML = 'X';
        textEl.appendTo(document.body);
        textSize = textEl.dom.offsetHeight;
        setInterval(function () {
          if (textEl.dom.offsetHeight != textSize) {
            textEvent.fire(textSize, textSize = textEl.dom.offsetHeight);
          }
        }, this.textResizeInterval);
      }

      textEvent.addListener(fn, scope, options);
    },

    /**
     * Removes the passed window resize listener.
     * @param {Function} fn        The method the event invokes
     * @param {Object}   scope    The scope of handler
     */
    removeResizeListener: function removeResizeListener(fn, scope) {
      if (resizeEvent) {
        resizeEvent.removeListener(fn, scope);
      }
    },
    // private
    fireResize: function fireResize() {
      if (resizeEvent) {
        resizeEvent.fire(D.getViewWidth(), D.getViewHeight());
      }
    },

    /**
    * The frequency, in milliseconds, to check for text resize events (defaults to 50)
    */
    textResizeInterval: 50,

    /**
     * Url used for onDocumentReady with using SSL (defaults to Ext.SSL_SECURE_URL)
     */
    ieDeferSrc: false,
    // protected for use inside the framework
    // detects whether we should use keydown or keypress based on the browser.
    useKeydown: useKeydown
  };
}());
Ext.EventManager.on = Ext.EventManager.addListener;
Ext.apply(Ext.EventObjectImpl.prototype, {
  /** Key constant @type Number */
  BACKSPACE: 8,

  /** Key constant @type Number */
  TAB: 9,

  /** Key constant @type Number */
  NUM_CENTER: 12,

  /** Key constant @type Number */
  ENTER: 13,

  /** Key constant @type Number */
  RETURN: 13,

  /** Key constant @type Number */
  SHIFT: 16,

  /** Key constant @type Number */
  CTRL: 17,
  CONTROL: 17,
  // legacy

  /** Key constant @type Number */
  ALT: 18,

  /** Key constant @type Number */
  PAUSE: 19,

  /** Key constant @type Number */
  CAPS_LOCK: 20,

  /** Key constant @type Number */
  ESC: 27,

  /** Key constant @type Number */
  SPACE: 32,

  /** Key constant @type Number */
  PAGE_UP: 33,
  PAGEUP: 33,
  // legacy

  /** Key constant @type Number */
  PAGE_DOWN: 34,
  PAGEDOWN: 34,
  // legacy

  /** Key constant @type Number */
  END: 35,

  /** Key constant @type Number */
  HOME: 36,

  /** Key constant @type Number */
  LEFT: 37,

  /** Key constant @type Number */
  UP: 38,

  /** Key constant @type Number */
  RIGHT: 39,

  /** Key constant @type Number */
  DOWN: 40,

  /** Key constant @type Number */
  PRINT_SCREEN: 44,

  /** Key constant @type Number */
  INSERT: 45,

  /** Key constant @type Number */
  DELETE: 46,

  /** Key constant @type Number */
  ZERO: 48,

  /** Key constant @type Number */
  ONE: 49,

  /** Key constant @type Number */
  TWO: 50,

  /** Key constant @type Number */
  THREE: 51,

  /** Key constant @type Number */
  FOUR: 52,

  /** Key constant @type Number */
  FIVE: 53,

  /** Key constant @type Number */
  SIX: 54,

  /** Key constant @type Number */
  SEVEN: 55,

  /** Key constant @type Number */
  EIGHT: 56,

  /** Key constant @type Number */
  NINE: 57,

  /** Key constant @type Number */
  A: 65,

  /** Key constant @type Number */
  B: 66,

  /** Key constant @type Number */
  C: 67,

  /** Key constant @type Number */
  D: 68,

  /** Key constant @type Number */
  E: 69,

  /** Key constant @type Number */
  F: 70,

  /** Key constant @type Number */
  G: 71,

  /** Key constant @type Number */
  H: 72,

  /** Key constant @type Number */
  I: 73,

  /** Key constant @type Number */
  J: 74,

  /** Key constant @type Number */
  K: 75,

  /** Key constant @type Number */
  L: 76,

  /** Key constant @type Number */
  M: 77,

  /** Key constant @type Number */
  N: 78,

  /** Key constant @type Number */
  O: 79,

  /** Key constant @type Number */
  P: 80,

  /** Key constant @type Number */
  Q: 81,

  /** Key constant @type Number */
  R: 82,

  /** Key constant @type Number */
  S: 83,

  /** Key constant @type Number */
  T: 84,

  /** Key constant @type Number */
  U: 85,

  /** Key constant @type Number */
  V: 86,

  /** Key constant @type Number */
  W: 87,

  /** Key constant @type Number */
  X: 88,

  /** Key constant @type Number */
  Y: 89,

  /** Key constant @type Number */
  Z: 90,

  /** Key constant @type Number */
  CONTEXT_MENU: 93,

  /** Key constant @type Number */
  NUM_ZERO: 96,

  /** Key constant @type Number */
  NUM_ONE: 97,

  /** Key constant @type Number */
  NUM_TWO: 98,

  /** Key constant @type Number */
  NUM_THREE: 99,

  /** Key constant @type Number */
  NUM_FOUR: 100,

  /** Key constant @type Number */
  NUM_FIVE: 101,

  /** Key constant @type Number */
  NUM_SIX: 102,

  /** Key constant @type Number */
  NUM_SEVEN: 103,

  /** Key constant @type Number */
  NUM_EIGHT: 104,

  /** Key constant @type Number */
  NUM_NINE: 105,

  /** Key constant @type Number */
  NUM_MULTIPLY: 106,

  /** Key constant @type Number */
  NUM_PLUS: 107,

  /** Key constant @type Number */
  NUM_MINUS: 109,

  /** Key constant @type Number */
  NUM_PERIOD: 110,

  /** Key constant @type Number */
  NUM_DIVISION: 111,

  /** Key constant @type Number */
  F1: 112,

  /** Key constant @type Number */
  F2: 113,

  /** Key constant @type Number */
  F3: 114,

  /** Key constant @type Number */
  F4: 115,

  /** Key constant @type Number */
  F5: 116,

  /** Key constant @type Number */
  F6: 117,

  /** Key constant @type Number */
  F7: 118,

  /** Key constant @type Number */
  F8: 119,

  /** Key constant @type Number */
  F9: 120,

  /** Key constant @type Number */
  F10: 121,

  /** Key constant @type Number */
  F11: 122,

  /** Key constant @type Number */
  F12: 123,

  /** @private */
  isNavKeyPress: function isNavKeyPress() {
    var me = this,
        k = this.normalizeKey(me.keyCode);
    return k >= 33 && k <= 40 || // Page Up/Down, End, Home, Left, Up, Right, Down
    k == me.RETURN || k == me.TAB || k == me.ESC;
  },
  isSpecialKey: function isSpecialKey() {
    var k = this.normalizeKey(this.keyCode);
    return this.type == 'keypress' && this.ctrlKey || this.isNavKeyPress() || k == this.BACKSPACE || // Backspace
    k >= 16 && k <= 20 || // Shift, Ctrl, Alt, Pause, Caps Lock
    k >= 44 && k <= 45; // Print Screen, Insert
  },
  getPoint: function getPoint() {
    return new Ext.lib.Point(this.xy[0], this.xy[1]);
  },

  /**
   * Returns true if the control, meta, shift or alt key was pressed during this event.
   * @return {Boolean}
   */
  hasModifier: function hasModifier() {
    return this.ctrlKey || this.altKey || this.shiftKey;
  }
});

/***/ }),
/* 716 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 * <p>Encapsulates a DOM element, adding simple DOM manipulation facilities, normalizing for browser differences.</p>
 * <p>All instances of this class inherit the methods of {@link Ext.Fx} making visual effects easily available to all DOM elements.</p>
 * <p>Note that the events documented in this class are not Ext events, they encapsulate browser events. To
 * access the underlying browser event, see {@link Ext.EventObject#browserEvent}. Some older
 * browsers may not support the full range of events. Which events are supported is beyond the control of ExtJs.</p>
 * Usage:<br>
<pre><code>
// by id
var el = Ext.get("my-div");

// by DOM element reference
var el = Ext.get(myDivElement);
</code></pre>
 * <b>Animations</b><br />
 * <p>When an element is manipulated, by default there is no animation.</p>
 * <pre><code>
var el = Ext.get("my-div");

// no animation
el.setWidth(100);
 * </code></pre>
 * <p>Many of the functions for manipulating an element have an optional "animate" parameter.  This
 * parameter can be specified as boolean (<tt>true</tt>) for default animation effects.</p>
 * <pre><code>
// default animation
el.setWidth(100, true);
 * </code></pre>
 *
 * <p>To configure the effects, an object literal with animation options to use as the Element animation
 * configuration object can also be specified. Note that the supported Element animation configuration
 * options are a subset of the {@link Ext.Fx} animation options specific to Fx effects.  The supported
 * Element animation configuration options are:</p>
<pre>
Option    Default   Description
--------- --------  ---------------------------------------------
{@link Ext.Fx#duration duration}  .35       The duration of the animation in seconds
{@link Ext.Fx#easing easing}    easeOut   The easing method
{@link Ext.Fx#callback callback}  none      A function to execute when the anim completes
{@link Ext.Fx#scope scope}     this      The scope (this) of the callback function
</pre>
 *
 * <pre><code>
// Element animation options object
var opt = {
    {@link Ext.Fx#duration duration}: 1,
    {@link Ext.Fx#easing easing}: 'elasticIn',
    {@link Ext.Fx#callback callback}: this.foo,
    {@link Ext.Fx#scope scope}: this
};
// animation with some options set
el.setWidth(100, opt);
 * </code></pre>
 * <p>The Element animation object being used for the animation will be set on the options
 * object as "anim", which allows you to stop or manipulate the animation. Here is an example:</p>
 * <pre><code>
// using the "anim" property to get the Anim object
if(opt.anim.isAnimated()){
    opt.anim.stop();
}
 * </code></pre>
 * <p>Also see the <tt>{@link #animate}</tt> method for another animation technique.</p>
 * <p><b> Composite (Collections of) Elements</b></p>
 * <p>For working with collections of Elements, see {@link Ext.CompositeElement}</p>
 * @constructor Create a new Element directly.
 * @param {String/HTMLElement} element
 * @param {Boolean} forceNew (optional) By default the constructor checks to see if there is already an instance of this element in the cache and if there is it returns the same instance. This will skip that check (useful for extending this class).
 */
(function () {
  var DOC = document;

  Ext.Element = function (element, forceNew) {
    var dom = typeof element == "string" ? DOC.getElementById(element) : element,
        id;
    if (!dom) return null;
    id = dom.id;

    if (!forceNew && id && Ext.elCache[id]) {
      // element object already exists
      return Ext.elCache[id].el;
    }
    /**
     * The DOM element
     * @type HTMLElement
     */


    this.dom = dom;
    /**
     * The DOM element ID
     * @type String
     */

    this.id = id || Ext.id(dom);
  };

  var D = Ext.lib.Dom,
      DH = Ext.DomHelper,
      E = Ext.lib.Event,
      A = Ext.lib.Anim,
      El = Ext.Element,
      EC = Ext.elCache;
  El.prototype = {
    /**
     * Sets the passed attributes as attributes of this element (a style attribute can be a string, object or function)
     * @param {Object} o The object with the attributes
     * @param {Boolean} useSet (optional) false to override the default setAttribute to use expandos.
     * @return {Ext.Element} this
     */
    set: function set(o, useSet) {
      var el = this.dom,
          attr,
          val,
          useSet = useSet !== false && !!el.setAttribute;

      for (attr in o) {
        if (o.hasOwnProperty(attr)) {
          val = o[attr];

          if (attr == 'style') {
            DH.applyStyles(el, val);
          } else if (attr == 'cls') {
            el.className = val;
          } else if (useSet) {
            el.setAttribute(attr, val);
          } else {
            el[attr] = val;
          }
        }
      }

      return this;
    },
    //  Mouse events

    /**
     * @event click
     * Fires when a mouse click is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event contextmenu
     * Fires when a right click is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event dblclick
     * Fires when a mouse double click is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mousedown
     * Fires when a mousedown is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mouseup
     * Fires when a mouseup is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mouseover
     * Fires when a mouseover is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mousemove
     * Fires when a mousemove is detected with the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mouseout
     * Fires when a mouseout is detected with the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mouseenter
     * Fires when the mouse enters the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event mouseleave
     * Fires when the mouse leaves the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */
    //  Keyboard events

    /**
     * @event keypress
     * Fires when a keypress is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event keydown
     * Fires when a keydown is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event keyup
     * Fires when a keyup is detected within the element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */
    //  HTML frame/object events

    /**
     * @event load
     * Fires when the user agent finishes loading all content within the element. Only supported by window, frames, objects and images.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event unload
     * Fires when the user agent removes all content from a window or frame. For elements, it fires when the target element or any of its content has been removed.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event abort
     * Fires when an object/image is stopped from loading before completely loaded.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event error
     * Fires when an object/image/frame cannot be loaded properly.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event resize
     * Fires when a document view is resized.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event scroll
     * Fires when a document view is scrolled.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */
    //  Form events

    /**
     * @event select
     * Fires when a user selects some text in a text field, including input and textarea.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event change
     * Fires when a control loses the input focus and its value has been modified since gaining focus.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event submit
     * Fires when a form is submitted.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event reset
     * Fires when a form is reset.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event focus
     * Fires when an element receives focus either via the pointing device or by tab navigation.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event blur
     * Fires when an element loses focus either via the pointing device or by tabbing navigation.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */
    //  User Interface events

    /**
     * @event DOMFocusIn
     * Where supported. Similar to HTML focus event, but can be applied to any focusable element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMFocusOut
     * Where supported. Similar to HTML blur event, but can be applied to any focusable element.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMActivate
     * Where supported. Fires when an element is activated, for instance, through a mouse click or a keypress.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */
    //  DOM Mutation events

    /**
     * @event DOMSubtreeModified
     * Where supported. Fires when the subtree is modified.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMNodeInserted
     * Where supported. Fires when a node has been added as a child of another node.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMNodeRemoved
     * Where supported. Fires when a descendant node of the element is removed.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMNodeRemovedFromDocument
     * Where supported. Fires when a node is being removed from a document.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMNodeInsertedIntoDocument
     * Where supported. Fires when a node is being inserted into a document.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMAttrModified
     * Where supported. Fires when an attribute has been modified.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * @event DOMCharacterDataModified
     * Where supported. Fires when the character data has been modified.
     * @param {Ext.EventObject} e The {@link Ext.EventObject} encapsulating the DOM event.
     * @param {HtmlElement} t The target of the event.
     * @param {Object} o The options configuration passed to the {@link #addListener} call.
     */

    /**
     * The default unit to append to CSS values where a unit isn't provided (defaults to px).
     * @type String
     */
    defaultUnit: "px",

    /**
     * Returns true if this element matches the passed simple selector (e.g. div.some-class or span:first-child)
     * @param {String} selector The simple selector to test
     * @return {Boolean} True if this element matches the selector, else false
     */
    is: function is(simpleSelector) {
      return Ext.DomQuery.is(this.dom, simpleSelector);
    },

    /**
     * Tries to focus the element. Any exceptions are caught and ignored.
     * @param {Number} defer (optional) Milliseconds to defer the focus
     * @return {Ext.Element} this
     */
    focus: function focus(defer,
    /* private */
    dom) {
      var me = this,
          dom = dom || me.dom;

      try {
        if (Number(defer)) {
          me.focus.defer(defer, null, [null, dom]);
        } else {
          dom.focus();
        }
      } catch (e) {}

      return me;
    },

    /**
     * Tries to blur the element. Any exceptions are caught and ignored.
     * @return {Ext.Element} this
     */
    blur: function blur() {
      try {
        this.dom.blur();
      } catch (e) {}

      return this;
    },

    /**
     * Returns the value of the "value" attribute
     * @param {Boolean} asNumber true to parse the value as a number
     * @return {String/Number}
     */
    getValue: function getValue(asNumber) {
      var val = this.dom ? this.dom.value : undefined;
      return asNumber ? parseInt(val, 10) : val;
    },

    /**
     * Appends an event handler to this element.  The shorthand version {@link #on} is equivalent.
     * @param {String} eventName The name of event to handle.
     * @param {Function} fn The handler function the event invokes. This function is passed
     * the following parameters:<ul>
     * <li><b>evt</b> : EventObject<div class="sub-desc">The {@link Ext.EventObject EventObject} describing the event.</div></li>
     * <li><b>el</b> : HtmlElement<div class="sub-desc">The DOM element which was the target of the event.
     * Note that this may be filtered by using the <tt>delegate</tt> option.</div></li>
     * <li><b>o</b> : Object<div class="sub-desc">The options object from the addListener call.</div></li>
     * </ul>
     * @param {Object} scope (optional) The scope (<code><b>this</b></code> reference) in which the handler function is executed.
     * <b>If omitted, defaults to this Element.</b>.
     * @param {Object} options (optional) An object containing handler configuration properties.
     * This may contain any of the following properties:<ul>
     * <li><b>scope</b> Object : <div class="sub-desc">The scope (<code><b>this</b></code> reference) in which the handler function is executed.
     * <b>If omitted, defaults to this Element.</b></div></li>
     * <li><b>delegate</b> String: <div class="sub-desc">A simple selector to filter the target or look for a descendant of the target. See below for additional details.</div></li>
     * <li><b>stopEvent</b> Boolean: <div class="sub-desc">True to stop the event. That is stop propagation, and prevent the default action.</div></li>
     * <li><b>preventDefault</b> Boolean: <div class="sub-desc">True to prevent the default action</div></li>
     * <li><b>stopPropagation</b> Boolean: <div class="sub-desc">True to prevent event propagation</div></li>
     * <li><b>normalized</b> Boolean: <div class="sub-desc">False to pass a browser event to the handler function instead of an Ext.EventObject</div></li>
     * <li><b>target</b> Ext.Element: <div class="sub-desc">Only call the handler if the event was fired on the target Element, <i>not</i> if the event was bubbled up from a child node.</div></li>
     * <li><b>delay</b> Number: <div class="sub-desc">The number of milliseconds to delay the invocation of the handler after the event fires.</div></li>
     * <li><b>single</b> Boolean: <div class="sub-desc">True to add a handler to handle just the next firing of the event, and then remove itself.</div></li>
     * <li><b>buffer</b> Number: <div class="sub-desc">Causes the handler to be scheduled to run in an {@link Ext.util.DelayedTask} delayed
     * by the specified number of milliseconds. If the event fires again within that time, the original
     * handler is <em>not</em> invoked, but the new handler is scheduled in its place.</div></li>
     * </ul><br>
     * <p>
     * <b>Combining Options</b><br>
     * In the following examples, the shorthand form {@link #on} is used rather than the more verbose
     * addListener.  The two are equivalent.  Using the options argument, it is possible to combine different
     * types of listeners:<br>
     * <br>
     * A delayed, one-time listener that auto stops the event and adds a custom argument (forumId) to the
     * options object. The options object is available as the third parameter in the handler function.<div style="margin: 5px 20px 20px;">
     * Code:<pre><code>
    el.on('click', this.onClick, this, {
    single: true,
    delay: 100,
    stopEvent : true,
    forumId: 4
    });</code></pre></p>
     * <p>
     * <b>Attaching multiple handlers in 1 call</b><br>
     * The method also allows for a single argument to be passed which is a config object containing properties
     * which specify multiple handlers.</p>
     * <p>
     * Code:<pre><code>
    el.on({
    'click' : {
        fn: this.onClick,
        scope: this,
        delay: 100
    },
    'mouseover' : {
        fn: this.onMouseOver,
        scope: this
    },
    'mouseout' : {
        fn: this.onMouseOut,
        scope: this
    }
    });</code></pre>
     * <p>
     * Or a shorthand syntax:<br>
     * Code:<pre><code></p>
    el.on({
    'click' : this.onClick,
    'mouseover' : this.onMouseOver,
    'mouseout' : this.onMouseOut,
    scope: this
    });
     * </code></pre></p>
     * <p><b>delegate</b></p>
     * <p>This is a configuration option that you can pass along when registering a handler for
     * an event to assist with event delegation. Event delegation is a technique that is used to
     * reduce memory consumption and prevent exposure to memory-leaks. By registering an event
     * for a container element as opposed to each element within a container. By setting this
     * configuration option to a simple selector, the target element will be filtered to look for
     * a descendant of the target.
     * For example:<pre><code>
    // using this markup:
    &lt;div id='elId'>
    &lt;p id='p1'>paragraph one&lt;/p>
    &lt;p id='p2' class='clickable'>paragraph two&lt;/p>
    &lt;p id='p3'>paragraph three&lt;/p>
    &lt;/div>
    // utilize event delegation to registering just one handler on the container element:
    el = Ext.get('elId');
    el.on(
    'click',
    function(e,t) {
        // handle click
        console.info(t.id); // 'p2'
    },
    this,
    {
        // filter the target element to be a descendant with the class 'clickable'
        delegate: '.clickable'
    }
    );
     * </code></pre></p>
     * @return {Ext.Element} this
     */
    addListener: function addListener(eventName, fn, scope, options) {
      Ext.EventManager.on(this.dom, eventName, fn, scope || this, options);
      return this;
    },

    /**
     * Removes an event handler from this element.  The shorthand version {@link #un} is equivalent.
     * <b>Note</b>: if a <i>scope</i> was explicitly specified when {@link #addListener adding} the
     * listener, the same scope must be specified here.
     * Example:
     * <pre><code>
    el.removeListener('click', this.handlerFn);
    // or
    el.un('click', this.handlerFn);
    </code></pre>
     * @param {String} eventName The name of the event from which to remove the handler.
     * @param {Function} fn The handler function to remove. <b>This must be a reference to the function passed into the {@link #addListener} call.</b>
     * @param {Object} scope If a scope (<b><code>this</code></b> reference) was specified when the listener was added,
     * then this must refer to the same object.
     * @return {Ext.Element} this
     */
    removeListener: function removeListener(eventName, fn, scope) {
      Ext.EventManager.removeListener(this.dom, eventName, fn, scope || this);
      return this;
    },

    /**
     * Removes all previous added listeners from this element
     * @return {Ext.Element} this
     */
    removeAllListeners: function removeAllListeners() {
      Ext.EventManager.removeAll(this.dom);
      return this;
    },

    /**
     * Recursively removes all previous added listeners from this element and its children
     * @return {Ext.Element} this
     */
    purgeAllListeners: function purgeAllListeners() {
      Ext.EventManager.purgeElement(this, true);
      return this;
    },

    /**
     * @private Test if size has a unit, otherwise appends the default
     */
    addUnits: function addUnits(size) {
      if (size === "" || size == "auto" || size === undefined) {
        size = size || '';
      } else if (!isNaN(size) || !unitPattern.test(size)) {
        size = size + (this.defaultUnit || 'px');
      }

      return size;
    },

    /**
     * <p>Updates the <a href="http://developer.mozilla.org/en/DOM/element.innerHTML">innerHTML</a> of this Element
     * from a specified URL. Note that this is subject to the <a href="http://en.wikipedia.org/wiki/Same_origin_policy">Same Origin Policy</a></p>
     * <p>Updating innerHTML of an element will <b>not</b> execute embedded <tt>&lt;script></tt> elements. This is a browser restriction.</p>
     * @param {Mixed} options. Either a sring containing the URL from which to load the HTML, or an {@link Ext.Ajax#request} options object specifying
     * exactly how to request the HTML.
     * @return {Ext.Element} this
     */
    load: function load(url, params, cb) {
      Ext.Ajax.request(Ext.apply({
        params: params,
        url: url.url || url,
        callback: cb,
        el: this.dom,
        indicatorText: url.indicatorText || ''
      }, Ext.isObject(url) ? url : {}));
      return this;
    },

    /**
     * Tests various css rules/browsers to determine if this element uses a border box
     * @return {Boolean}
     */
    isBorderBox: function isBorderBox() {
      var _this$dom;

      return noBoxAdjust[(((_this$dom = this.dom) === null || _this$dom === void 0 ? void 0 : _this$dom.tagName) || "").toLowerCase()] || Ext.isBorderBox;
    },

    /**
     * <p>Removes this element's dom reference.  Note that event and cache removal is handled at {@link Ext#removeNode}</p>
     */
    remove: function remove() {
      var me = this,
          dom = me.dom;

      if (dom) {
        delete me.dom;
        Ext.removeNode(dom);
      }
    },

    /**
     * Sets up event handlers to call the passed functions when the mouse is moved into and out of the Element.
     * @param {Function} overFn The function to call when the mouse enters the Element.
     * @param {Function} outFn The function to call when the mouse leaves the Element.
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the functions are executed. Defaults to the Element's DOM element.
     * @param {Object} options (optional) Options for the listener. See {@link Ext.util.Observable#addListener the <tt>options</tt> parameter}.
     * @return {Ext.Element} this
     */
    hover: function hover(overFn, outFn, scope, options) {
      var me = this;
      me.on('mouseenter', overFn, scope || me.dom, options);
      me.on('mouseleave', outFn, scope || me.dom, options);
      return me;
    },

    /**
     * Returns true if this element is an ancestor of the passed element
     * @param {HTMLElement/String} el The element to check
     * @return {Boolean} True if this element is an ancestor of el, else false
     */
    contains: function contains(el) {
      return !el ? false : Ext.lib.Dom.isAncestor(this.dom, el.dom ? el.dom : el);
    },

    /**
     * Returns the value of a namespaced attribute from the element's underlying DOM node.
     * @param {String} namespace The namespace in which to look for the attribute
     * @param {String} name The attribute name
     * @return {String} The attribute value
     * @deprecated
     */
    getAttributeNS: function getAttributeNS(ns, name) {
      return this.getAttribute(name, ns);
    },

    /**
     * Returns the value of an attribute from the element's underlying DOM node.
     * @param {String} name The attribute name
     * @param {String} namespace (optional) The namespace in which to look for the attribute
     * @return {String} The attribute value
     */
    getAttribute: Ext.isIE6 || Ext.isIE7 || Ext.isIE8 ? function (name, ns) {
      var d = this.dom,
          type = typeof d[ns + ":" + name];

      if (['undefined', 'unknown'].indexOf(type) == -1) {
        return d[ns + ":" + name];
      }

      return d[name];
    } : function (name, ns) {
      var d = this.dom;
      return d.getAttributeNS(ns, name) || d.getAttribute(ns + ":" + name) || d.getAttribute(name) || d[name];
    },

    /**
    * Update the innerHTML of this element
    * @param {String} html The new HTML
    * @return {Ext.Element} this
     */
    update: function update(html) {
      if (this.dom) {
        this.dom.innerHTML = html;
      }

      return this;
    }
  };
  var ep = El.prototype;

  El.addMethods = function (o) {
    Ext.apply(ep, o);
  };
  /**
   * Appends an event handler (shorthand for {@link #addListener}).
   * @param {String} eventName The name of event to handle.
   * @param {Function} fn The handler function the event invokes.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the handler function is executed.
   * @param {Object} options (optional) An object containing standard {@link #addListener} options
   * @member Ext.Element
   * @method on
   */


  ep.on = ep.addListener;
  /**
   * Removes an event handler from this element (see {@link #removeListener} for additional notes).
   * @param {String} eventName The name of the event from which to remove the handler.
   * @param {Function} fn The handler function to remove. <b>This must be a reference to the function passed into the {@link #addListener} call.</b>
   * @param {Object} scope If a scope (<b><code>this</code></b> reference) was specified when the listener was added,
   * then this must refer to the same object.
   * @return {Ext.Element} this
   * @member Ext.Element
   * @method un
   */

  ep.un = ep.removeListener;
  /**
   * true to automatically adjust width and height settings for box-model issues (default to true)
   */

  ep.autoBoxAdjust = true; // private

  var unitPattern = /\d+(px|em|%|en|ex|pt|in|cm|mm|pc)$/i,
      docEl;
  /**
   * @private
   */

  /**
   * Retrieves Ext.Element objects.
   * <p><b>This method does not retrieve {@link Ext.Component Component}s.</b> This method
   * retrieves Ext.Element objects which encapsulate DOM elements. To retrieve a Component by
   * its ID, use {@link Ext.ComponentMgr#get}.</p>
   * <p>Uses simple caching to consistently return the same object. Automatically fixes if an
   * object was recreated with the same id via AJAX or DOM.</p>
   * @param {Mixed} el The id of the node, a DOM Node or an existing Element.
   * @return {Element} The Element object (or null if no matching element was found)
   * @static
   * @member Ext.Element
   * @method get
   */

  El.get = function (el) {
    var ex, elm, id;

    if (!el) {
      return null;
    }

    if (typeof el == "string") {
      // element id
      if (!(elm = DOC.getElementById(el))) {
        return null;
      }

      if (EC[el] && EC[el].el) {
        ex = EC[el].el;
        ex.dom = elm;
      } else {
        ex = El.addToCache(new El(elm));
      }

      return ex;
    } else if (el.tagName) {
      // dom element
      if (!(id = el.id)) {
        id = Ext.id(el);
      }

      if (EC[id] && EC[id].el) {
        ex = EC[id].el;
        ex.dom = el;
      } else {
        ex = El.addToCache(new El(el));
      }

      return ex;
    } else if (el instanceof El) {
      if (el != docEl) {
        el.dom = DOC.getElementById(el.id) || el.dom; // refresh dom element in case no longer valid,
        // catch case where it hasn't been appended
      }

      return el;
    } else if (el.isComposite) {
      return el;
    } else if (Ext.isArray(el)) {
      return El.select(el);
    } else if (el == DOC) {
      // create a bogus element object representing the document object
      if (!docEl) {
        var f = function f() {};

        f.prototype = El.prototype;
        docEl = new f();
        docEl.dom = DOC;
      }

      return docEl;
    }

    return null;
  };

  El.addToCache = function (el, id) {
    id = id || el.id;
    EC[id] = {
      el: el,
      data: {},
      events: {}
    };
    return el;
  }; // private method for getting and setting element data


  El.data = function (el, key, value) {
    el = El.get(el);

    if (!el) {
      return null;
    }

    var c = EC[el.id].data;

    if (arguments.length == 2) {
      return c[key];
    } else {
      return c[key] = value;
    }
  }; // private
  // Garbage collection - uncache elements/purge listeners on orphaned elements
  // so we don't hold a reference and cause the browser to retain them


  function garbageCollect() {
    if (!Ext.enableGarbageCollector) {
      clearInterval(El.collectorThreadId);
    } else {
      var eid, el, d, o;

      for (eid in EC) {
        o = EC[eid];

        if (o.skipGC) {
          continue;
        }

        el = o.el;
        d = el.dom; // -------------------------------------------------------
        // Determining what is garbage:
        // -------------------------------------------------------
        // !d
        // dom node is null, definitely garbage
        // -------------------------------------------------------
        // !d.parentNode
        // no parentNode == direct orphan, definitely garbage
        // -------------------------------------------------------
        // !d.offsetParent && !document.getElementById(eid)
        // display none elements have no offsetParent so we will
        // also try to look it up by it's id. However, check
        // offsetParent first so we don't do unneeded lookups.
        // This enables collection of elements that are not orphans
        // directly, but somewhere up the line they have an orphan
        // parent.
        // -------------------------------------------------------

        if (!d || !d.parentNode || !d.offsetParent && !DOC.getElementById(eid)) {
          if (Ext.enableListenerCollection) {
            Ext.EventManager.removeAll(d);
          }

          delete EC[eid];
        }
      } // Cleanup IE Object leaks


      if (Ext.isIE) {
        var t = {};

        for (eid in EC) {
          t[eid] = EC[eid];
        }

        EC = Ext.elCache = t;
      }
    }
  }

  El.collectorThreadId = setInterval(garbageCollect, 30000);

  var flyFn = function flyFn() {};

  flyFn.prototype = El.prototype; // dom is optional

  El.Flyweight = function (dom) {
    this.dom = dom;
  };

  El.Flyweight.prototype = new flyFn();
  El.Flyweight.prototype.isFlyweight = true;
  El._flyweights = {};
  /**
   * <p>Gets the globally shared flyweight Element, with the passed node as the active element. Do not store a reference to this element -
   * the dom node can be overwritten by other code. Shorthand of {@link Ext.Element#fly}</p>
   * <p>Use this to make one-time references to DOM elements which are not going to be accessed again either by
   * application code, or by Ext's classes. If accessing an element which will be processed regularly, then {@link Ext#get}
   * will be more appropriate to take advantage of the caching provided by the Ext.Element class.</p>
   * @param {String/HTMLElement} el The dom node or id
   * @param {String} named (optional) Allows for creation of named reusable flyweights to prevent conflicts
   * (e.g. internally Ext uses "_global")
   * @return {Element} The shared Element object (or null if no matching element was found)
   * @member Ext.Element
   * @method fly
   */

  El.fly = function (el, named) {
    var ret = null;
    named = named || '_global';

    if (el = Ext.getDom(el)) {
      (El._flyweights[named] = El._flyweights[named] || new El.Flyweight()).dom = el;
      ret = El._flyweights[named];
    }

    return ret;
  };
  /**
   * Retrieves Ext.Element objects.
   * <p><b>This method does not retrieve {@link Ext.Component Component}s.</b> This method
   * retrieves Ext.Element objects which encapsulate DOM elements. To retrieve a Component by
   * its ID, use {@link Ext.ComponentMgr#get}.</p>
   * <p>Uses simple caching to consistently return the same object. Automatically fixes if an
   * object was recreated with the same id via AJAX or DOM.</p>
   * Shorthand of {@link Ext.Element#get}
   * @param {Mixed} el The id of the node, a DOM Node or an existing Element.
   * @return {Element} The Element object (or null if no matching element was found)
   * @member Ext
   * @method get
   */


  Ext.get = El.get;
  /**
   * <p>Gets the globally shared flyweight Element, with the passed node as the active element. Do not store a reference to this element -
   * the dom node can be overwritten by other code. Shorthand of {@link Ext.Element#fly}</p>
   * <p>Use this to make one-time references to DOM elements which are not going to be accessed again either by
   * application code, or by Ext's classes. If accessing an element which will be processed regularly, then {@link Ext#get}
   * will be more appropriate to take advantage of the caching provided by the Ext.Element class.</p>
   * @param {String/HTMLElement} el The dom node or id
   * @param {String} named (optional) Allows for creation of named reusable flyweights to prevent conflicts
   * (e.g. internally Ext uses "_global")
   * @return {Element} The shared Element object (or null if no matching element was found)
   * @member Ext
   * @method fly
   */

  Ext.fly = El.fly; // speedy lookup for elements never to box adjust

  var noBoxAdjust = Ext.isStrict ? {
    select: 1
  } : {
    input: 1,
    select: 1,
    textarea: 1
  };

  if (Ext.isIE || Ext.isGecko) {
    noBoxAdjust['button'] = 1;
  }
})();

/***/ }),
/* 717 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Stops the specified event(s) from bubbling and optionally prevents the default action
   * @param {String/Array} eventName an event / array of events to stop from bubbling
   * @param {Boolean} preventDefault (optional) true to prevent the default action too
   * @return {Ext.Element} this
   */
  swallowEvent: function swallowEvent(eventName, preventDefault) {
    var me = this;

    function fn(e) {
      e.stopPropagation();

      if (preventDefault) {
        e.preventDefault();
      }
    }

    if (Ext.isArray(eventName)) {
      Ext.each(eventName, function (e) {
        me.on(e, fn);
      });
      return me;
    }

    me.on(eventName, fn);
    return me;
  },

  /**
   * Create an event handler on this element such that when the event fires and is handled by this element,
   * it will be relayed to another object (i.e., fired again as if it originated from that object instead).
   * @param {String} eventName The type of event to relay
   * @param {Object} object Any object that extends {@link Ext.util.Observable} that will provide the context
   * for firing the relayed event
   */
  relayEvent: function relayEvent(eventName, observable) {
    this.on(eventName, function (e) {
      observable.fireEvent(eventName, e);
    });
  },

  /**
   * Removes worthless text nodes
   * @param {Boolean} forceReclean (optional) By default the element
   * keeps track if it has been cleaned already so
   * you can call this over and over. However, if you update the element and
   * need to force a reclean, you can pass true.
   */
  clean: function clean(forceReclean) {
    var me = this,
        dom = me.dom,
        n = dom.firstChild,
        ni = -1;

    if (Ext.Element.data(dom, 'isCleaned') && forceReclean !== true) {
      return me;
    }

    while (n) {
      var nx = n.nextSibling;

      if (n.nodeType == 3 && !/\S/.test(n.nodeValue)) {
        dom.removeChild(n);
      } else {
        n.nodeIndex = ++ni;
      }

      n = nx;
    }

    Ext.Element.data(dom, 'isCleaned', true);
    return me;
  },

  /**
   * Direct access to the Updater {@link Ext.Updater#update} method. The method takes the same object
   * parameter as {@link Ext.Updater#update}
   * @return {Ext.Element} this
   */
  load: function load() {
    var um = this.getUpdater();
    um.update.apply(um, arguments);
    return this;
  },

  /**
  * Gets this element's {@link Ext.Updater Updater}
  * @return {Ext.Updater} The Updater
  */
  getUpdater: function getUpdater() {
    return this.updateManager || (this.updateManager = new Ext.Updater(this));
  },

  /**
  * Update the innerHTML of this element, optionally searching for and processing scripts
  * @param {String} html The new HTML
  * @param {Boolean} loadScripts (optional) True to look for and process scripts (defaults to false)
  * @param {Function} callback (optional) For async script loading you can be notified when the update completes
  * @return {Ext.Element} this
   */
  update: function update(html, loadScripts, callback) {
    if (!this.dom) {
      return this;
    }

    html = html || "";

    if (loadScripts !== true) {
      this.dom.innerHTML = html;

      if (Ext.isFunction(callback)) {
        callback();
      }

      return this;
    }

    var id = Ext.id(),
        dom = this.dom;
    html += '<span id="' + id + '"></span>';
    Ext.lib.Event.onAvailable(id, function () {
      var DOC = document,
          hd = DOC.getElementsByTagName("head")[0],
          re = /(?:<script([^>]*)?>)((\n|\r|.)*?)(?:<\/script>)/ig,
          srcRe = /\ssrc=([\'\"])(.*?)\1/i,
          typeRe = /\stype=([\'\"])(.*?)\1/i,
          match,
          attrs,
          srcMatch,
          typeMatch,
          el,
          s;

      while (match = re.exec(html)) {
        attrs = match[1];
        srcMatch = attrs ? attrs.match(srcRe) : false;

        if (srcMatch && srcMatch[2]) {
          s = DOC.createElement("script");
          s.src = srcMatch[2];
          typeMatch = attrs.match(typeRe);

          if (typeMatch && typeMatch[2]) {
            s.type = typeMatch[2];
          }

          hd.appendChild(s);
        } else if (match[2] && match[2].length > 0) {
          if (window.execScript) {
            window.execScript(match[2]);
          } else {
            window.eval(match[2]);
          }
        }
      }

      el = DOC.getElementById(id);

      if (el) {
        Ext.removeNode(el);
      }

      if (Ext.isFunction(callback)) {
        callback();
      }
    });
    dom.innerHTML = html.replace(/(?:<script.*?>)((\n|\r|.)*?)(?:<\/script>)/ig, "");
    return this;
  },
  // inherit docs, overridden so we can add removeAnchor
  removeAllListeners: function removeAllListeners() {
    this.removeAnchor();
    Ext.EventManager.removeAll(this.dom);
    return this;
  },

  /**
   * Creates a proxy element of this element
   * @param {String/Object} config The class name of the proxy element or a DomHelper config object
   * @param {String/HTMLElement} renderTo (optional) The element or element id to render the proxy to (defaults to document.body)
   * @param {Boolean} matchBox (optional) True to align and size the proxy to this element now (defaults to false)
   * @return {Ext.Element} The new proxy element
   */
  createProxy: function createProxy(config, renderTo, matchBox) {
    config = Ext.isObject(config) ? config : {
      tag: "div",
      cls: config
    };
    var me = this,
        proxy = renderTo ? Ext.DomHelper.append(renderTo, config, true) : Ext.DomHelper.insertBefore(me.dom, config, true);

    if (matchBox && me.setBox && me.getBox) {
      // check to make sure Element.position.js is loaded
      proxy.setBox(me.getBox());
    }

    return proxy;
  }
});
Ext.Element.prototype.getUpdateManager = Ext.Element.prototype.getUpdater;

/***/ }),
/* 718 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Gets the x,y coordinates specified by the anchor position on the element.
   * @param {String} anchor (optional) The specified anchor position (defaults to "c").  See {@link #alignTo}
   * for details on supported anchor positions.
   * @param {Boolean} local (optional) True to get the local (element top/left-relative) anchor position instead
   * of page coordinates
   * @param {Object} size (optional) An object containing the size to use for calculating anchor position
   * {width: (target width), height: (target height)} (defaults to the element's current size)
   * @return {Array} [x, y] An array containing the element's x and y coordinates
   */
  getAnchorXY: function getAnchorXY(anchor, local, s) {
    //Passing a different size is useful for pre-calculating anchors,
    //especially for anchored animations that change the el size.
    anchor = (anchor || "tl").toLowerCase();
    s = s || {};
    var me = this,
        vp = me.dom == document.body || me.dom == document,
        w = s.width || vp ? Ext.lib.Dom.getViewWidth() : me.getWidth(),
        h = s.height || vp ? Ext.lib.Dom.getViewHeight() : me.getHeight(),
        xy,
        r = Math.round,
        o = me.getXY(),
        scroll = me.getScroll(),
        extraX = vp ? scroll.left : !local ? o[0] : 0,
        extraY = vp ? scroll.top : !local ? o[1] : 0,
        hash = {
      c: [r(w * 0.5), r(h * 0.5)],
      t: [r(w * 0.5), 0],
      l: [0, r(h * 0.5)],
      r: [w, r(h * 0.5)],
      b: [r(w * 0.5), h],
      tl: [0, 0],
      bl: [0, h],
      br: [w, h],
      tr: [w, 0]
    };
    xy = hash[anchor];
    return [xy[0] + extraX, xy[1] + extraY];
  },

  /**
   * Anchors an element to another element and realigns it when the window is resized.
   * @param {Mixed} element The element to align to.
   * @param {String} position The position to align to.
   * @param {Array} offsets (optional) Offset the positioning by [x, y]
   * @param {Boolean/Object} animate (optional) True for the default animation or a standard Element animation config object
   * @param {Boolean/Number} monitorScroll (optional) True to monitor body scroll and reposition. If this parameter
   * is a number, it is used as the buffer delay (defaults to 50ms).
   * @param {Function} callback The function to call after the animation finishes
   * @return {Ext.Element} this
   */
  anchorTo: function anchorTo(el, alignment, offsets, animate, monitorScroll, callback) {
    var me = this,
        dom = me.dom,
        scroll = !Ext.isEmpty(monitorScroll),
        action = function action() {
      Ext.fly(dom).alignTo(el, alignment, offsets, animate);
      Ext.callback(callback, Ext.fly(dom));
    },
        anchor = this.getAnchor(); // previous listener anchor, remove it


    this.removeAnchor();
    Ext.apply(anchor, {
      fn: action,
      scroll: scroll
    });
    Ext.EventManager.onWindowResize(action, null);

    if (scroll) {
      Ext.EventManager.on(window, 'scroll', action, null, {
        buffer: !isNaN(monitorScroll) ? monitorScroll : 50
      });
    }

    action.call(me); // align immediately

    return me;
  },

  /**
   * Remove any anchor to this element. See {@link #anchorTo}.
   * @return {Ext.Element} this
   */
  removeAnchor: function removeAnchor() {
    var me = this,
        anchor = this.getAnchor();

    if (anchor && anchor.fn) {
      Ext.EventManager.removeResizeListener(anchor.fn);

      if (anchor.scroll) {
        Ext.EventManager.un(window, 'scroll', anchor.fn);
      }

      delete anchor.fn;
    }

    return me;
  },
  // private
  getAnchor: function getAnchor() {
    var data = Ext.Element.data,
        dom = this.dom;

    if (!dom) {
      return;
    }

    var anchor = data(dom, '_anchor');

    if (!anchor) {
      anchor = data(dom, '_anchor', {});
    }

    return anchor;
  },

  /**
   * Gets the x,y coordinates to align this element with another element. See {@link #alignTo} for more info on the
   * supported position values.
   * @param {Mixed} element The element to align to.
   * @param {String} position (optional, defaults to "tl-bl?") The position to align to.
   * @param {Array} offsets (optional) Offset the positioning by [x, y]
   * @return {Array} [x, y]
   */
  getAlignToXY: function getAlignToXY(el, p, o) {
    el = Ext.get(el);

    if (!el || !el.dom) {
      throw "Element.alignToXY with an element that doesn't exist";
    }

    o = o || [0, 0];
    p = (!p || p == "?" ? "tl-bl?" : !/-/.test(p) && p !== "" ? "tl-" + p : p || "tl-bl").toLowerCase();
    var me = this,
        d = me.dom,
        a1,
        a2,
        x,
        y,
        //constrain the aligned el to viewport if necessary
    w,
        h,
        r,
        dw = Ext.lib.Dom.getViewWidth() - 10,
        // 10px of margin for ie
    dh = Ext.lib.Dom.getViewHeight() - 10,
        // 10px of margin for ie
    p1y,
        p1x,
        p2y,
        p2x,
        swapY,
        swapX,
        doc = document,
        docElement = doc.documentElement,
        docBody = doc.body,
        scrollX = (docElement.scrollLeft || docBody.scrollLeft || 0) + 5,
        scrollY = (docElement.scrollTop || docBody.scrollTop || 0) + 5,
        c = false,
        //constrain to viewport
    p1 = "",
        p2 = "",
        m = p.match(/^([a-z]+)-([a-z]+)(\?)?$/);

    if (!m) {
      throw "Element.alignTo with an invalid alignment " + p;
    }

    p1 = m[1];
    p2 = m[2];
    c = !!m[3]; //Subtract the aligned el's internal xy from the target's offset xy
    //plus custom offset to get the aligned el's new offset xy

    a1 = me.getAnchorXY(p1, true);
    a2 = el.getAnchorXY(p2, false);
    x = a2[0] - a1[0] + o[0];
    y = a2[1] - a1[1] + o[1];

    if (c) {
      w = me.getWidth();
      h = me.getHeight();
      r = el.getRegion(); //If we are at a viewport boundary and the aligned el is anchored on a target border that is
      //perpendicular to the vp border, allow the aligned el to slide on that border,
      //otherwise swap the aligned el to the opposite border of the target.

      p1y = p1.charAt(0);
      p1x = p1.charAt(p1.length - 1);
      p2y = p2.charAt(0);
      p2x = p2.charAt(p2.length - 1);
      swapY = p1y == "t" && p2y == "b" || p1y == "b" && p2y == "t";
      swapX = p1x == "r" && p2x == "l" || p1x == "l" && p2x == "r";

      if (x + w > dw + scrollX) {
        x = swapX ? r.left - w : dw + scrollX - w;
      }

      if (x < scrollX) {
        x = swapX ? r.right : scrollX;
      }

      if (y + h > dh + scrollY) {
        y = swapY ? r.top - h : dh + scrollY - h;
      }

      if (y < scrollY) {
        y = swapY ? r.bottom : scrollY;
      }
    }

    return [x, y];
  },

  /**
   * Aligns this element with another element relative to the specified anchor points. If the other element is the
   * document it aligns it to the viewport.
   * The position parameter is optional, and can be specified in any one of the following formats:
   * <ul>
   *   <li><b>Blank</b>: Defaults to aligning the element's top-left corner to the target's bottom-left corner ("tl-bl").</li>
   *   <li><b>One anchor (deprecated)</b>: The passed anchor position is used as the target element's anchor point.
   *       The element being aligned will position its top-left corner (tl) to that point.  <i>This method has been
   *       deprecated in favor of the newer two anchor syntax below</i>.</li>
   *   <li><b>Two anchors</b>: If two values from the table below are passed separated by a dash, the first value is used as the
   *       element's anchor point, and the second value is used as the target's anchor point.</li>
   * </ul>
   * In addition to the anchor points, the position parameter also supports the "?" character.  If "?" is passed at the end of
   * the position string, the element will attempt to align as specified, but the position will be adjusted to constrain to
   * the viewport if necessary.  Note that the element being aligned might be swapped to align to a different position than
   * that specified in order to enforce the viewport constraints.
   * Following are all of the supported anchor positions:
  <pre>
  Value  Description
  -----  -----------------------------
  tl     The top left corner (default)
  t      The center of the top edge
  tr     The top right corner
  l      The center of the left edge
  c      In the center of the element
  r      The center of the right edge
  bl     The bottom left corner
  b      The center of the bottom edge
  br     The bottom right corner
  </pre>
  Example Usage:
  <pre><code>
  // align el to other-el using the default positioning ("tl-bl", non-constrained)
  el.alignTo("other-el");
  // align the top left corner of el with the top right corner of other-el (constrained to viewport)
  el.alignTo("other-el", "tr?");
  // align the bottom right corner of el with the center left edge of other-el
  el.alignTo("other-el", "br-l?");
  // align the center of el with the bottom left corner of other-el and
  // adjust the x position by -6 pixels (and the y position by 0)
  el.alignTo("other-el", "c-bl", [-6, 0]);
  </code></pre>
   * @param {Mixed} element The element to align to.
   * @param {String} position (optional, defaults to "tl-bl?") The position to align to.
   * @param {Array} offsets (optional) Offset the positioning by [x, y]
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Ext.Element} this
   */
  alignTo: function alignTo(element, position, offsets, animate) {
    var me = this;
    return me.setXY(me.getAlignToXY(element, position, offsets), me.preanim && !!animate ? me.preanim(arguments, 3) : false);
  },
  // private ==>  used outside of core
  adjustForConstraints: function adjustForConstraints(xy, parent, offsets) {
    return this.getConstrainToXY(parent || document, false, offsets, xy) || xy;
  },
  // private ==>  used outside of core
  getConstrainToXY: function (el, local, offsets, proposedXY) {
    var os = {
      top: 0,
      left: 0,
      bottom: 0,
      right: 0
    };
    return function (el, local, offsets, proposedXY) {
      el = Ext.get(el);
      offsets = offsets ? Ext.applyIf(offsets, os) : os;
      var vw,
          vh,
          vx = 0,
          vy = 0;

      if (el.dom == document.body || el.dom == document) {
        vw = Ext.lib.Dom.getViewWidth();
        vh = Ext.lib.Dom.getViewHeight();
      } else {
        vw = el.dom.clientWidth;
        vh = el.dom.clientHeight;

        if (!local) {
          var vxy = el.getXY();
          vx = vxy[0];
          vy = vxy[1];
        }
      }

      var s = el.getScroll();
      vx += offsets.left + s.left;
      vy += offsets.top + s.top;
      vw -= offsets.right;
      vh -= offsets.bottom;
      var vr = vx + vw;
      var vb = vy + vh;
      var xy = proposedXY || (!local ? this.getXY() : [this.getLeft(true), this.getTop(true)]);
      var x = xy[0],
          y = xy[1];
      var w = this.dom.offsetWidth,
          h = this.dom.offsetHeight; // only move it if it needs it

      var moved = false; // first validate right/bottom

      if (x + w > vr) {
        x = vr - w;
        moved = true;
      }

      if (y + h > vb) {
        y = vb - h;
        moved = true;
      } // then make sure top/left isn't negative


      if (x < vx) {
        x = vx;
        moved = true;
      }

      if (y < vy) {
        y = vy;
        moved = true;
      }

      return moved ? [x, y] : false;
    };
  }(),
  //         el = Ext.get(el);
  //         offsets = Ext.applyIf(offsets || {}, {top : 0, left : 0, bottom : 0, right : 0});
  //         var	me = this,
  //         	doc = document,
  //         	s = el.getScroll(),
  //         	vxy = el.getXY(),
  //         	vx = offsets.left + s.left, 
  //         	vy = offsets.top + s.top,            	
  //         	vw = -offsets.right, 
  //         	vh = -offsets.bottom, 
  //         	vr,
  //         	vb,
  //         	xy = proposedXY || (!local ? me.getXY() : [me.getLeft(true), me.getTop(true)]),
  //         	x = xy[0],
  //         	y = xy[1],
  //         	w = me.dom.offsetWidth, h = me.dom.offsetHeight,
  //         	moved = false; // only move it if it needs it
  //       
  //         	
  //         if(el.dom == doc.body || el.dom == doc){
  //             vw += Ext.lib.Dom.getViewWidth();
  //             vh += Ext.lib.Dom.getViewHeight();
  //         }else{
  //             vw += el.dom.clientWidth;
  //             vh += el.dom.clientHeight;
  //             if(!local){                    
  //                 vx += vxy[0];
  //                 vy += vxy[1];
  //             }
  //         }
  //         // first validate right/bottom
  //         if(x + w > vx + vw){
  //             x = vx + vw - w;
  //             moved = true;
  //         }
  //         if(y + h > vy + vh){
  //             y = vy + vh - h;
  //             moved = true;
  //         }
  //         // then make sure top/left isn't negative
  //         if(x < vx){
  //             x = vx;
  //             moved = true;
  //         }
  //         if(y < vy){
  //             y = vy;
  //             moved = true;
  //         }
  //         return moved ? [x, y] : false;
  //    },

  /**
  * Calculates the x, y to center this element on the screen
  * @return {Array} The x, y values [x, y]
  */
  getCenterXY: function getCenterXY() {
    return this.getAlignToXY(document, 'c-c');
  },

  /**
  * Centers the Element in either the viewport, or another Element.
  * @param {Mixed} centerIn (optional) The element in which to center the element.
  */
  center: function center(centerIn) {
    return this.alignTo(centerIn || document, 'c-c');
  }
});

/***/ }),
/* 719 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods(function () {
  var PARENTNODE = 'parentNode',
      NEXTSIBLING = 'nextSibling',
      PREVIOUSSIBLING = 'previousSibling',
      DQ = Ext.DomQuery,
      GET = Ext.get;
  return {
    /**
        * Looks at this node and then at parent nodes for a match of the passed simple selector (e.g. div.some-class or span:first-child)
        * @param {String} selector The simple selector to test
        * @param {Number/Mixed} maxDepth (optional) The max depth to search as a number or element (defaults to 50 || document.body)
        * @param {Boolean} returnEl (optional) True to return a Ext.Element object instead of DOM node
        * @return {HTMLElement} The matching DOM node (or null if no match was found)
        */
    findParent: function findParent(simpleSelector, maxDepth, returnEl) {
      var p = this.dom,
          b = document.body,
          depth = 0,
          stopEl;

      if (Ext.isGecko && Object.prototype.toString.call(p) == '[object XULElement]') {
        return null;
      }

      maxDepth = maxDepth || 50;

      if (isNaN(maxDepth)) {
        stopEl = Ext.getDom(maxDepth);
        maxDepth = Number.MAX_VALUE;
      }

      while (p && p.nodeType == 1 && depth < maxDepth && p != b && p != stopEl) {
        if (DQ.is(p, simpleSelector)) {
          return returnEl ? GET(p) : p;
        }

        depth++;
        p = p.parentNode;
      }

      return null;
    },

    /**
     * Looks at parent nodes for a match of the passed simple selector (e.g. div.some-class or span:first-child)
     * @param {String} selector The simple selector to test
     * @param {Number/Mixed} maxDepth (optional) The max depth to
            search as a number or element (defaults to 10 || document.body)
     * @param {Boolean} returnEl (optional) True to return a Ext.Element object instead of DOM node
     * @return {HTMLElement} The matching DOM node (or null if no match was found)
     */
    findParentNode: function findParentNode(simpleSelector, maxDepth, returnEl) {
      var p = Ext.fly(this.dom.parentNode, '_internal');
      return p ? p.findParent(simpleSelector, maxDepth, returnEl) : null;
    },

    /**
     * Walks up the dom looking for a parent node that matches the passed simple selector (e.g. div.some-class or span:first-child).
     * This is a shortcut for findParentNode() that always returns an Ext.Element.
     * @param {String} selector The simple selector to test
     * @param {Number/Mixed} maxDepth (optional) The max depth to
            search as a number or element (defaults to 10 || document.body)
     * @return {Ext.Element} The matching DOM node (or null if no match was found)
     */
    up: function up(simpleSelector, maxDepth) {
      return this.findParentNode(simpleSelector, maxDepth, true);
    },

    /**
     * Creates a {@link Ext.CompositeElement} for child nodes based on the passed CSS selector (the selector should not contain an id).
     * @param {String} selector The CSS selector
     * @return {CompositeElement/CompositeElementLite} The composite element
     */
    select: function select(selector) {
      return Ext.Element.select(selector, this.dom);
    },

    /**
     * Selects child nodes based on the passed CSS selector (the selector should not contain an id).
     * @param {String} selector The CSS selector
     * @return {Array} An array of the matched nodes
     */
    query: function query(selector) {
      return DQ.select(selector, this.dom);
    },

    /**
     * Selects a single child at any depth below this element based on the passed CSS selector (the selector should not contain an id).
     * @param {String} selector The CSS selector
     * @param {Boolean} returnDom (optional) True to return the DOM node instead of Ext.Element (defaults to false)
     * @return {HTMLElement/Ext.Element} The child Ext.Element (or DOM node if returnDom = true)
     */
    child: function child(selector, returnDom) {
      var n = DQ.selectNode(selector, this.dom);
      return returnDom ? n : GET(n);
    },

    /**
     * Selects a single *direct* child based on the passed CSS selector (the selector should not contain an id).
     * @param {String} selector The CSS selector
     * @param {Boolean} returnDom (optional) True to return the DOM node instead of Ext.Element (defaults to false)
     * @return {HTMLElement/Ext.Element} The child Ext.Element (or DOM node if returnDom = true)
     */
    down: function down(selector, returnDom) {
      var n = DQ.selectNode(" > " + selector, this.dom);
      return returnDom ? n : GET(n);
    },

    /**
       * Gets the parent node for this element, optionally chaining up trying to match a selector
       * @param {String} selector (optional) Find a parent node that matches the passed simple selector
       * @param {Boolean} returnDom (optional) True to return a raw dom node instead of an Ext.Element
       * @return {Ext.Element/HTMLElement} The parent node or null
    */
    parent: function parent(selector, returnDom) {
      return this.matchNode(PARENTNODE, PARENTNODE, selector, returnDom);
    },

    /**
    * Gets the next sibling, skipping text nodes
    * @param {String} selector (optional) Find the next sibling that matches the passed simple selector
    * @param {Boolean} returnDom (optional) True to return a raw dom node instead of an Ext.Element
    * @return {Ext.Element/HTMLElement} The next sibling or null
    */
    next: function next(selector, returnDom) {
      return this.matchNode(NEXTSIBLING, NEXTSIBLING, selector, returnDom);
    },

    /**
     * Gets the previous sibling, skipping text nodes
     * @param {String} selector (optional) Find the previous sibling that matches the passed simple selector
     * @param {Boolean} returnDom (optional) True to return a raw dom node instead of an Ext.Element
     * @return {Ext.Element/HTMLElement} The previous sibling or null
    */
    prev: function prev(selector, returnDom) {
      return this.matchNode(PREVIOUSSIBLING, PREVIOUSSIBLING, selector, returnDom);
    },

    /**
     * Gets the first child, skipping text nodes
     * @param {String} selector (optional) Find the next sibling that matches the passed simple selector
     * @param {Boolean} returnDom (optional) True to return a raw dom node instead of an Ext.Element
     * @return {Ext.Element/HTMLElement} The first child or null
    */
    first: function first(selector, returnDom) {
      return this.matchNode(NEXTSIBLING, 'firstChild', selector, returnDom);
    },

    /**
     * Gets the last child, skipping text nodes
     * @param {String} selector (optional) Find the previous sibling that matches the passed simple selector
     * @param {Boolean} returnDom (optional) True to return a raw dom node instead of an Ext.Element
     * @return {Ext.Element/HTMLElement} The last child or null
    */
    last: function last(selector, returnDom) {
      return this.matchNode(PREVIOUSSIBLING, 'lastChild', selector, returnDom);
    },
    matchNode: function matchNode(dir, start, selector, returnDom) {
      var n = this.dom[start];

      while (n) {
        if (n.nodeType == 1 && (!selector || DQ.is(n, selector))) {
          return !returnDom ? GET(n) : n;
        }

        n = n[dir];
      }

      return null;
    }
  };
}());

/***/ }),
/* 720 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Creates a {@link Ext.CompositeElement} for child nodes based on the passed CSS selector (the selector should not contain an id).
   * @param {String} selector The CSS selector
   * @param {Boolean} unique (optional) True to create a unique Ext.Element for each child (defaults to false, which creates a single shared flyweight object)
   * @return {CompositeElement/CompositeElementLite} The composite element
   */
  select: function select(selector, unique) {
    return Ext.Element.select(selector, unique, this.dom);
  }
});

/***/ }),
/* 721 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods(function () {
  var GETDOM = Ext.getDom,
      GET = Ext.get,
      DH = Ext.DomHelper;
  return {
    /**
     * Appends the passed element(s) to this element
     * @param {String/HTMLElement/Array/Element/CompositeElement} el
     * @return {Ext.Element} this
     */
    appendChild: function appendChild(el) {
      return GET(el).appendTo(this);
    },

    /**
     * Appends this element to the passed element
     * @param {Mixed} el The new parent element
     * @return {Ext.Element} this
     */
    appendTo: function appendTo(el) {
      GETDOM(el).appendChild(this.dom);
      return this;
    },

    /**
     * Inserts this element before the passed element in the DOM
     * @param {Mixed} el The element before which this element will be inserted
     * @return {Ext.Element} this
     */
    insertBefore: function insertBefore(el) {
      (el = GETDOM(el)).parentNode.insertBefore(this.dom, el);
      return this;
    },

    /**
     * Inserts this element after the passed element in the DOM
     * @param {Mixed} el The element to insert after
     * @return {Ext.Element} this
     */
    insertAfter: function insertAfter(el) {
      (el = GETDOM(el)).parentNode.insertBefore(this.dom, el.nextSibling);
      return this;
    },

    /**
     * Inserts (or creates) an element (or DomHelper config) as the first child of this element
     * @param {Mixed/Object} el The id or element to insert or a DomHelper config to create and insert
     * @return {Ext.Element} The new child
     */
    insertFirst: function insertFirst(el, returnDom) {
      el = el || {};

      if (el.nodeType || el.dom || typeof el == 'string') {
        // element
        el = GETDOM(el);
        this.dom.insertBefore(el, this.dom.firstChild);
        return !returnDom ? GET(el) : el;
      } else {
        // dh config
        return this.createChild(el, this.dom.firstChild, returnDom);
      }
    },

    /**
     * Replaces the passed element with this element
     * @param {Mixed} el The element to replace
     * @return {Ext.Element} this
     */
    replace: function replace(el) {
      el = GET(el);
      this.insertBefore(el);
      el.remove();
      return this;
    },

    /**
     * Replaces this element with the passed element
     * @param {Mixed/Object} el The new element or a DomHelper config of an element to create
     * @return {Ext.Element} this
     */
    replaceWith: function replaceWith(el) {
      var me = this;

      if (el.nodeType || el.dom || typeof el == 'string') {
        el = GETDOM(el);
        me.dom.parentNode.insertBefore(el, me.dom);
      } else {
        el = DH.insertBefore(me.dom, el);
      }

      delete Ext.elCache[me.id];
      Ext.removeNode(me.dom);
      me.id = Ext.id(me.dom = el);
      Ext.Element.addToCache(me.isFlyweight ? new Ext.Element(me.dom) : me);
      return me;
    },

    /**
     * Creates the passed DomHelper config and appends it to this element or optionally inserts it before the passed child element.
     * @param {Object} config DomHelper element config object.  If no tag is specified (e.g., {tag:'input'}) then a div will be
     * automatically generated with the specified attributes.
     * @param {HTMLElement} insertBefore (optional) a child element of this element
     * @param {Boolean} returnDom (optional) true to return the dom node instead of creating an Element
     * @return {Ext.Element} The new child element
     */
    createChild: function createChild(config, insertBefore, returnDom) {
      config = config || {
        tag: 'div'
      };
      return insertBefore ? DH.insertBefore(insertBefore, config, returnDom !== true) : DH[!this.dom.firstChild ? 'overwrite' : 'append'](this.dom, config, returnDom !== true);
    },

    /**
     * Creates and wraps this element with another element
     * @param {Object} config (optional) DomHelper element config object for the wrapper element or null for an empty div
     * @param {Boolean} returnDom (optional) True to return the raw DOM element instead of Ext.Element
     * @return {HTMLElement/Element} The newly created wrapper element
     */
    wrap: function wrap(config, returnDom) {
      var newEl = DH.insertBefore(this.dom, config || {
        tag: "div"
      }, !returnDom);
      newEl.dom ? newEl.dom.appendChild(this.dom) : newEl.appendChild(this.dom);
      return newEl;
    },

    /**
     * Inserts an html fragment into this element
     * @param {String} where Where to insert the html in relation to this element - beforeBegin, afterBegin, beforeEnd, afterEnd.
     * @param {String} html The HTML fragment
     * @param {Boolean} returnEl (optional) True to return an Ext.Element (defaults to false)
     * @return {HTMLElement/Ext.Element} The inserted node (or nearest related if more than 1 inserted)
     */
    insertHtml: function insertHtml(where, html, returnEl) {
      var el = DH.insertHtml(where, this.dom, html);
      return returnEl ? Ext.get(el) : el;
    }
  };
}());

/***/ }),
/* 722 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.apply(Ext.Element.prototype, function () {
  var GETDOM = Ext.getDom,
      GET = Ext.get,
      DH = Ext.DomHelper;
  return {
    /**
        * Inserts (or creates) the passed element (or DomHelper config) as a sibling of this element
        * @param {Mixed/Object/Array} el The id, element to insert or a DomHelper config to create and insert *or* an array of any of those.
        * @param {String} where (optional) 'before' or 'after' defaults to before
        * @param {Boolean} returnDom (optional) True to return the raw DOM element instead of Ext.Element
        * @return {Ext.Element} The inserted Element. If an array is passed, the last inserted element is returned.
        */
    insertSibling: function insertSibling(el, where, returnDom) {
      var me = this,
          rt,
          isAfter = (where || 'before').toLowerCase() == 'after',
          insertEl;

      if (Ext.isArray(el)) {
        insertEl = me;
        Ext.each(el, function (e) {
          rt = Ext.fly(insertEl, '_internal').insertSibling(e, where, returnDom);

          if (isAfter) {
            insertEl = rt;
          }
        });
        return rt;
      }

      el = el || {};

      if (el.nodeType || el.dom) {
        rt = me.dom.parentNode.insertBefore(GETDOM(el), isAfter ? me.dom.nextSibling : me.dom);

        if (!returnDom) {
          rt = GET(rt);
        }
      } else {
        if (isAfter && !me.dom.nextSibling) {
          rt = DH.append(me.dom.parentNode, el, !returnDom);
        } else {
          rt = DH[isAfter ? 'insertAfter' : 'insertBefore'](me.dom, el, !returnDom);
        }
      }

      return rt;
    }
  };
}());

/***/ }),
/* 723 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods(function () {
  // local style camelizing for speed
  var propCache = {},
      camelRe = /(-[a-z])/gi,
      classReCache = {},
      view = document.defaultView,
      propFloat = Ext.isIE ? 'styleFloat' : 'cssFloat',
      opacityRe = /alpha\(opacity=(.*)\)/i,
      trimRe = /^\s+|\s+$/g,
      EL = Ext.Element,
      PADDING = "padding",
      MARGIN = "margin",
      BORDER = "border",
      LEFT = "-left",
      RIGHT = "-right",
      TOP = "-top",
      BOTTOM = "-bottom",
      WIDTH = "-width",
      MATH = Math,
      HIDDEN = 'hidden',
      ISCLIPPED = 'isClipped',
      OVERFLOW = 'overflow',
      OVERFLOWX = 'overflow-x',
      OVERFLOWY = 'overflow-y',
      ORIGINALCLIP = 'originalClip',
      // special markup used throughout Ext when box wrapping elements
  borders = {
    l: BORDER + LEFT + WIDTH,
    r: BORDER + RIGHT + WIDTH,
    t: BORDER + TOP + WIDTH,
    b: BORDER + BOTTOM + WIDTH
  },
      paddings = {
    l: PADDING + LEFT,
    r: PADDING + RIGHT,
    t: PADDING + TOP,
    b: PADDING + BOTTOM
  },
      margins = {
    l: MARGIN + LEFT,
    r: MARGIN + RIGHT,
    t: MARGIN + TOP,
    b: MARGIN + BOTTOM
  },
      data = Ext.Element.data; // private

  function camelFn(m, a) {
    return a.charAt(1).toUpperCase();
  }

  function chkCache(prop) {
    return propCache[prop] || (propCache[prop] = prop == 'float' ? propFloat : prop.replace(camelRe, camelFn));
  }

  return {
    // private  ==> used by Fx
    adjustWidth: function adjustWidth(width) {
      var me = this;
      var isNum = Ext.isNumber(width);

      if (isNum && me.autoBoxAdjust && !me.isBorderBox()) {
        width -= me.getBorderWidth("lr") + me.getPadding("lr");
      }

      return isNum && width < 0 ? 0 : width;
    },
    // private   ==> used by Fx
    adjustHeight: function adjustHeight(height) {
      var me = this;
      var isNum = Ext.isNumber(height);

      if (isNum && me.autoBoxAdjust && !me.isBorderBox()) {
        height -= me.getBorderWidth("tb") + me.getPadding("tb");
      }

      return isNum && height < 0 ? 0 : height;
    },

    /**
     * Adds one or more CSS classes to the element. Duplicate classes are automatically filtered out.
     * @param {String/Array} className The CSS class to add, or an array of classes
     * @return {Ext.Element} this
     */
    addClass: function addClass(className) {
      var me = this,
          i,
          len,
          v;
      className = Ext.isArray(className) ? className : [className];

      for (i = 0, len = className.length; i < len; i++) {
        v = className[i];

        if (v) {
          me.dom.className += !me.hasClass(v) && v ? " " + v : "";
        }

        ;
      }

      ;
      return me;
    },

    /**
     * Adds one or more CSS classes to this element and removes the same class(es) from all siblings.
     * @param {String/Array} className The CSS class to add, or an array of classes
     * @return {Ext.Element} this
     */
    radioClass: function radioClass(className) {
      var cn = this.dom.parentNode.childNodes,
          v;
      className = Ext.isArray(className) ? className : [className];

      for (var i = 0, len = cn.length; i < len; i++) {
        v = cn[i];

        if (v && v.nodeType == 1) {
          Ext.fly(v, '_internal').removeClass(className);
        }
      }

      ;
      return this.addClass(className);
    },

    /**
     * Removes one or more CSS classes from the element.
     * @param {String/Array} className The CSS class to remove, or an array of classes
     * @return {Ext.Element} this
     */
    removeClass: function removeClass(className) {
      var me = this,
          v;
      className = Ext.isArray(className) ? className : [className];

      if (me.dom && me.dom.className) {
        for (var i = 0, len = className.length; i < len; i++) {
          v = className[i];

          if (v) {
            me.dom.className = me.dom.className.replace(classReCache[v] = classReCache[v] || new RegExp('(?:^|\\s+)' + v + '(?:\\s+|$)', "g"), " ");
          }
        }

        ;
      }

      return me;
    },

    /**
     * Toggles the specified CSS class on this element (removes it if it already exists, otherwise adds it).
     * @param {String} className The CSS class to toggle
     * @return {Ext.Element} this
     */
    toggleClass: function toggleClass(className) {
      return this.hasClass(className) ? this.removeClass(className) : this.addClass(className);
    },

    /**
     * Checks if the specified CSS class exists on this element's DOM node.
     * @param {String} className The CSS class to check for
     * @return {Boolean} True if the class exists, else false
     */
    hasClass: function hasClass(className) {
      return className && (' ' + this.dom.className + ' ').indexOf(' ' + className + ' ') != -1;
    },

    /**
     * Replaces a CSS class on the element with another.  If the old name does not exist, the new name will simply be added.
     * @param {String} oldClassName The CSS class to replace
     * @param {String} newClassName The replacement CSS class
     * @return {Ext.Element} this
     */
    replaceClass: function replaceClass(oldClassName, newClassName) {
      return this.removeClass(oldClassName).addClass(newClassName);
    },
    isStyle: function isStyle(style, val) {
      return this.getStyle(style) == val;
    },

    /**
     * Normalizes currentStyle and computedStyle.
     * @param {String} property The style property whose value is returned.
     * @return {String} The current value of the style property for this element.
     */
    getStyle: function () {
      return view && view.getComputedStyle ? function (prop) {
        var el = this.dom,
            v,
            cs,
            out,
            display,
            wk = Ext.isWebKit,
            display;

        if (!el || el == document) {
          return null;
        }

        prop = chkCache(prop); // Fix bug caused by this: https://bugs.webkit.org/show_bug.cgi?id=13343

        if (wk && /marginRight/.test(prop)) {
          display = this.getStyle('display');
          el.style.display = 'inline-block';
        }

        out = (v = el.style[prop]) ? v : (cs = view.getComputedStyle(el, "")) ? cs[prop] : null; // Webkit returns rgb values for transparent.

        if (wk) {
          if (out == 'rgba(0, 0, 0, 0)') {
            out = 'transparent';
          } else if (display) {
            el.style.display = display;
          }
        }

        return out;
      } : function (prop) {
        var el = this.dom,
            m,
            cs;
        if (el == document) return null;

        if (prop == 'opacity') {
          if (el.style.filter.match) {
            if (m = el.style.filter.match(opacityRe)) {
              var fv = parseFloat(m[1]);

              if (!isNaN(fv)) {
                return fv ? fv / 100 : 0;
              }
            }
          }

          return 1;
        }

        prop = chkCache(prop);
        return el.style[prop] || ((cs = el.currentStyle) ? cs[prop] : null);
      };
    }(),

    /**
     * Return the CSS color for the specified CSS attribute. rgb, 3 digit (like #fff) and valid values
     * are convert to standard 6 digit hex color.
     * @param {String} attr The css attribute
     * @param {String} defaultValue The default value to use when a valid color isn't found
     * @param {String} prefix (optional) defaults to #. Use an empty string when working with
     * color anims.
     */
    getColor: function getColor(attr, defaultValue, prefix) {
      var v = this.getStyle(attr),
          color = Ext.isDefined(prefix) ? prefix : '#',
          h;

      if (!v || /transparent|inherit/.test(v)) {
        return defaultValue;
      }

      if (/^r/.test(v)) {
        Ext.each(v.slice(4, v.length - 1).split(','), function (s) {
          h = parseInt(s, 10);
          color += (h < 16 ? '0' : '') + h.toString(16);
        });
      } else {
        v = v.replace('#', '');
        color += v.length == 3 ? v.replace(/^(\w)(\w)(\w)$/, '$1$1$2$2$3$3') : v;
      }

      return color.length > 5 ? color.toLowerCase() : defaultValue;
    },

    /**
     * Wrapper for setting style properties, also takes single object parameter of multiple styles.
     * @param {String/Object} property The style property to be set, or an object of multiple styles.
     * @param {String} value (optional) The value to apply to the given property, or null if an object was passed.
     * @return {Ext.Element} this
     */
    setStyle: function setStyle(prop, value) {
      var tmp, style, camel;

      if (!Ext.isObject(prop)) {
        tmp = {};
        tmp[prop] = value;
        prop = tmp;
      }

      for (style in prop) {
        value = prop[style];
        style == 'opacity' ? this.setOpacity(value) : this.dom.style[chkCache(style)] = value;
      }

      return this;
    },

    /**
     * Set the opacity of the element
     * @param {Float} opacity The new opacity. 0 = transparent, .5 = 50% visibile, 1 = fully visible, etc
     * @param {Boolean/Object} animate (optional) a standard Element animation config object or <tt>true</tt> for
     * the default animation (<tt>{duration: .35, easing: 'easeIn'}</tt>)
     * @return {Ext.Element} this
     */
    setOpacity: function setOpacity(opacity, animate) {
      var me = this,
          s = me.dom.style;

      if (!animate || !me.anim) {
        if (Ext.isIE) {
          var opac = opacity < 1 ? 'alpha(opacity=' + opacity * 100 + ')' : '',
              val = s.filter.replace(opacityRe, '').replace(trimRe, '');
          s.zoom = 1;
          s.filter = val + (val.length > 0 ? ' ' : '') + opac;
        } else {
          s.opacity = opacity;
        }
      } else {
        me.anim({
          opacity: {
            to: opacity
          }
        }, me.preanim(arguments, 1), null, .35, 'easeIn');
      }

      return me;
    },

    /**
     * Clears any opacity settings from this element. Required in some cases for IE.
     * @return {Ext.Element} this
     */
    clearOpacity: function clearOpacity() {
      var style = this.dom.style;

      if (Ext.isIE) {
        if (!Ext.isEmpty(style.filter)) {
          style.filter = style.filter.replace(opacityRe, '').replace(trimRe, '');
        }
      } else {
        style.opacity = style['-moz-opacity'] = style['-khtml-opacity'] = '';
      }

      return this;
    },

    /**
     * Returns the offset height of the element
     * @param {Boolean} contentHeight (optional) true to get the height minus borders and padding
     * @return {Number} The element's height
     */
    getHeight: function getHeight(contentHeight) {
      var me = this,
          dom = me.dom,
          hidden = Ext.isIE && me.isStyle('display', 'none'),
          h = MATH.max(dom.offsetHeight, hidden ? 0 : dom.clientHeight) || 0;
      h = !contentHeight ? h : h - me.getBorderWidth("tb") - me.getPadding("tb");
      return h < 0 ? 0 : h;
    },

    /**
     * Returns the offset width of the element
     * @param {Boolean} contentWidth (optional) true to get the width minus borders and padding
     * @return {Number} The element's width
     */
    getWidth: function getWidth(contentWidth) {
      var me = this,
          dom = me.dom,
          hidden = Ext.isIE && me.isStyle('display', 'none'),
          w = MATH.max(dom === null || dom === void 0 ? void 0 : dom.offsetWidth, hidden ? 0 : dom === null || dom === void 0 ? void 0 : dom.clientWidth) || 0;
      w = !contentWidth ? w : w - me.getBorderWidth("lr") - me.getPadding("lr");
      return w < 0 ? 0 : w;
    },

    /**
     * Set the width of this Element.
     * @param {Mixed} width The new width. This may be one of:<div class="mdetail-params"><ul>
     * <li>A Number specifying the new width in this Element's {@link #defaultUnit}s (by default, pixels).</li>
     * <li>A String used to set the CSS width style. Animation may <b>not</b> be used.
     * </ul></div>
     * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setWidth: function setWidth(width, animate) {
      var _me$dom;

      var me = this;
      if (!(me === null || me === void 0 ? void 0 : (_me$dom = me.dom) === null || _me$dom === void 0 ? void 0 : _me$dom.style)) return me;
      width = me.adjustWidth(width);
      !animate || !me.anim ? me.dom.style.width = me.addUnits(width) : me.anim({
        width: {
          to: width
        }
      }, me.preanim(arguments, 1));
      return me;
    },

    /**
     * Set the height of this Element.
     * <pre><code>
    // change the height to 200px and animate with default configuration
    Ext.fly('elementId').setHeight(200, true);
    // change the height to 150px and animate with a custom configuration
    Ext.fly('elId').setHeight(150, {
    duration : .5, // animation will have a duration of .5 seconds
    // will change the content to "finished"
    callback: function(){ this.{@link #update}("finished"); }
    });
     * </code></pre>
     * @param {Mixed} height The new height. This may be one of:<div class="mdetail-params"><ul>
     * <li>A Number specifying the new height in this Element's {@link #defaultUnit}s (by default, pixels.)</li>
     * <li>A String used to set the CSS height style. Animation may <b>not</b> be used.</li>
     * </ul></div>
     * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setHeight: function setHeight(height, animate) {
      var me = this;
      height = me.adjustHeight(height);
      !animate || !me.anim ? me.dom.style.height = me.addUnits(height) : me.anim({
        height: {
          to: height
        }
      }, me.preanim(arguments, 1));
      return me;
    },

    /**
     * Gets the width of the border(s) for the specified side(s)
     * @param {String} side Can be t, l, r, b or any combination of those to add multiple values. For example,
     * passing <tt>'lr'</tt> would get the border <b><u>l</u></b>eft width + the border <b><u>r</u></b>ight width.
     * @return {Number} The width of the sides passed added together
     */
    getBorderWidth: function getBorderWidth(side) {
      return this.addStyles(side, borders);
    },

    /**
     * Gets the width of the padding(s) for the specified side(s)
     * @param {String} side Can be t, l, r, b or any combination of those to add multiple values. For example,
     * passing <tt>'lr'</tt> would get the padding <b><u>l</u></b>eft + the padding <b><u>r</u></b>ight.
     * @return {Number} The padding of the sides passed added together
     */
    getPadding: function getPadding(side) {
      return this.addStyles(side, paddings);
    },

    /**
     *  Store the current overflow setting and clip overflow on the element - use <tt>{@link #unclip}</tt> to remove
     * @return {Ext.Element} this
     */
    clip: function clip() {
      var me = this,
          dom = me.dom;

      if (!data(dom, ISCLIPPED)) {
        data(dom, ISCLIPPED, true);
        data(dom, ORIGINALCLIP, {
          o: me.getStyle(OVERFLOW),
          x: me.getStyle(OVERFLOWX),
          y: me.getStyle(OVERFLOWY)
        });
        me.setStyle(OVERFLOW, HIDDEN);
        me.setStyle(OVERFLOWX, HIDDEN);
        me.setStyle(OVERFLOWY, HIDDEN);
      }

      return me;
    },

    /**
     *  Return clipping (overflow) to original clipping before <tt>{@link #clip}</tt> was called
     * @return {Ext.Element} this
     */
    unclip: function unclip() {
      var me = this,
          dom = me.dom;

      if (data(dom, ISCLIPPED)) {
        data(dom, ISCLIPPED, false);
        var o = data(dom, ORIGINALCLIP);

        if (o.o) {
          me.setStyle(OVERFLOW, o.o);
        }

        if (o.x) {
          me.setStyle(OVERFLOWX, o.x);
        }

        if (o.y) {
          me.setStyle(OVERFLOWY, o.y);
        }
      }

      return me;
    },
    // private
    addStyles: function addStyles(sides, styles) {
      var val = 0,
          m = sides.match(/\w/g),
          s;

      for (var i = 0, len = m.length; i < len; i++) {
        s = m[i] && parseInt(this.getStyle(styles[m[i]]), 10);

        if (s) {
          val += MATH.abs(s);
        }
      }

      return val;
    },
    margins: margins
  };
}());

/***/ }),
/* 724 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
// special markup used throughout Ext when box wrapping elements
Ext.Element.boxMarkup = '<div class="{0}-tl"><div class="{0}-tr"><div class="{0}-tc"></div></div></div><div class="{0}-ml"><div class="{0}-mr"><div class="{0}-mc"></div></div></div><div class="{0}-bl"><div class="{0}-br"><div class="{0}-bc"></div></div></div>';
Ext.Element.addMethods(function () {
  var INTERNAL = "_internal",
      pxMatch = /(\d+\.?\d+)px/;
  return {
    /**
     * More flexible version of {@link #setStyle} for setting style properties.
     * @param {String/Object/Function} styles A style specification string, e.g. "width:100px", or object in the form {width:"100px"}, or
     * a function which returns such a specification.
     * @return {Ext.Element} this
     */
    applyStyles: function applyStyles(style) {
      Ext.DomHelper.applyStyles(this.dom, style);
      return this;
    },

    /**
     * Returns an object with properties matching the styles requested.
     * For example, el.getStyles('color', 'font-size', 'width') might return
     * {'color': '#FFFFFF', 'font-size': '13px', 'width': '100px'}.
     * @param {String} style1 A style name
     * @param {String} style2 A style name
     * @param {String} etc.
     * @return {Object} The style object
     */
    getStyles: function getStyles() {
      var ret = {};
      Ext.each(arguments, function (v) {
        ret[v] = this.getStyle(v);
      }, this);
      return ret;
    },
    // private  ==> used by ext full
    setOverflow: function setOverflow(v) {
      var dom = this.dom;

      if (v == 'auto' && Ext.isMac && Ext.isGecko2) {
        // work around stupid FF 2.0/Mac scroll bar bug
        dom.style.overflow = 'hidden';
        (function () {
          dom.style.overflow = 'auto';
        }).defer(1);
      } else {
        dom.style.overflow = v;
      }
    },

    /**
     * <p>Wraps the specified element with a special 9 element markup/CSS block that renders by default as
     * a gray container with a gradient background, rounded corners and a 4-way shadow.</p>
     * <p>This special markup is used throughout Ext when box wrapping elements ({@link Ext.Button},
     * {@link Ext.Panel} when <tt>{@link Ext.Panel#frame frame=true}</tt>, {@link Ext.Window}).  The markup
     * is of this form:</p>
     * <pre><code>
    Ext.Element.boxMarkup =
    &#39;&lt;div class="{0}-tl">&lt;div class="{0}-tr">&lt;div class="{0}-tc">&lt;/div>&lt;/div>&lt;/div>
    &lt;div class="{0}-ml">&lt;div class="{0}-mr">&lt;div class="{0}-mc">&lt;/div>&lt;/div>&lt;/div>
    &lt;div class="{0}-bl">&lt;div class="{0}-br">&lt;div class="{0}-bc">&lt;/div>&lt;/div>&lt;/div>&#39;;
     * </code></pre>
     * <p>Example usage:</p>
     * <pre><code>
    // Basic box wrap
    Ext.get("foo").boxWrap();
    // You can also add a custom class and use CSS inheritance rules to customize the box look.
    // 'x-box-blue' is a built-in alternative -- look at the related CSS definitions as an example
    // for how to create a custom box wrap style.
    Ext.get("foo").boxWrap().addClass("x-box-blue");
     * </code></pre>
     * @param {String} class (optional) A base CSS class to apply to the containing wrapper element
     * (defaults to <tt>'x-box'</tt>). Note that there are a number of CSS rules that are dependent on
     * this name to make the overall effect work, so if you supply an alternate base class, make sure you
     * also supply all of the necessary rules.
     * @return {Ext.Element} The outermost wrapping element of the created box structure.
     */
    boxWrap: function boxWrap(cls) {
      cls = cls || 'x-box';
      var el = Ext.get(this.insertHtml("beforeBegin", "<div class='" + cls + "'>" + String.format(Ext.Element.boxMarkup, cls) + "</div>")); //String.format('<div class="{0}">'+Ext.Element.boxMarkup+'</div>', cls)));

      Ext.DomQuery.selectNode('.' + cls + '-mc', el.dom).appendChild(this.dom);
      return el;
    },

    /**
     * Set the size of this Element. If animation is true, both width and height will be animated concurrently.
     * @param {Mixed} width The new width. This may be one of:<div class="mdetail-params"><ul>
     * <li>A Number specifying the new width in this Element's {@link #defaultUnit}s (by default, pixels).</li>
     * <li>A String used to set the CSS width style. Animation may <b>not</b> be used.
     * <li>A size object in the format <code>{width: widthValue, height: heightValue}</code>.</li>
     * </ul></div>
     * @param {Mixed} height The new height. This may be one of:<div class="mdetail-params"><ul>
     * <li>A Number specifying the new height in this Element's {@link #defaultUnit}s (by default, pixels).</li>
     * <li>A String used to set the CSS height style. Animation may <b>not</b> be used.</li>
     * </ul></div>
     * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setSize: function setSize(width, height, animate) {
      var me = this;

      if (Ext.isObject(width)) {
        // in case of object from getSize()
        height = width.height;
        width = width.width;
      }

      width = me.adjustWidth(width);
      height = me.adjustHeight(height);

      if (!animate || !me.anim) {
        me.dom.style.width = me.addUnits(width);
        me.dom.style.height = me.addUnits(height);
      } else {
        me.anim({
          width: {
            to: width
          },
          height: {
            to: height
          }
        }, me.preanim(arguments, 2));
      }

      return me;
    },

    /**
     * Returns either the offsetHeight or the height of this element based on CSS height adjusted by padding or borders
     * when needed to simulate offsetHeight when offsets aren't available. This may not work on display:none elements
     * if a height has not been set using CSS.
     * @return {Number}
     */
    getComputedHeight: function getComputedHeight() {
      var me = this,
          h = Math.max(me.dom.offsetHeight, me.dom.clientHeight);

      if (!h) {
        h = parseFloat(me.getStyle('height')) || 0;

        if (!me.isBorderBox()) {
          h += me.getFrameWidth('tb');
        }
      }

      return h;
    },

    /**
     * Returns either the offsetWidth or the width of this element based on CSS width adjusted by padding or borders
     * when needed to simulate offsetWidth when offsets aren't available. This may not work on display:none elements
     * if a width has not been set using CSS.
     * @return {Number}
     */
    getComputedWidth: function getComputedWidth() {
      var w = Math.max(this.dom.offsetWidth, this.dom.clientWidth);

      if (!w) {
        w = parseFloat(this.getStyle('width')) || 0;

        if (!this.isBorderBox()) {
          w += this.getFrameWidth('lr');
        }
      }

      return w;
    },

    /**
     * Returns the sum width of the padding and borders for the passed "sides". See getBorderWidth()
     for more information about the sides.
     * @param {String} sides
     * @return {Number}
     */
    getFrameWidth: function getFrameWidth(sides, onlyContentBox) {
      return onlyContentBox && this.isBorderBox() ? 0 : this.getPadding(sides) + this.getBorderWidth(sides);
    },

    /**
     * Sets up event handlers to add and remove a css class when the mouse is over this element
     * @param {String} className
     * @return {Ext.Element} this
     */
    addClassOnOver: function addClassOnOver(className) {
      this.hover(function () {
        Ext.fly(this, INTERNAL).addClass(className);
      }, function () {
        Ext.fly(this, INTERNAL).removeClass(className);
      });
      return this;
    },

    /**
     * Sets up event handlers to add and remove a css class when this element has the focus
     * @param {String} className
     * @return {Ext.Element} this
     */
    addClassOnFocus: function addClassOnFocus(className) {
      this.on("focus", function () {
        Ext.fly(this, INTERNAL).addClass(className);
      }, this.dom);
      this.on("blur", function () {
        Ext.fly(this, INTERNAL).removeClass(className);
      }, this.dom);
      return this;
    },

    /**
     * Sets up event handlers to add and remove a css class when the mouse is down and then up on this element (a click effect)
     * @param {String} className
     * @return {Ext.Element} this
     */
    addClassOnClick: function addClassOnClick(className) {
      var dom = this.dom;
      this.on("mousedown", function () {
        Ext.fly(dom, INTERNAL).addClass(className);

        var d = Ext.getDoc(),
            fn = function fn() {
          Ext.fly(dom, INTERNAL).removeClass(className);
          d.removeListener("mouseup", fn);
        };

        d.on("mouseup", fn);
      });
      return this;
    },

    /**
     * <p>Returns the dimensions of the element available to lay content out in.<p>
     * <p>If the element (or any ancestor element) has CSS style <code>display : none</code>, the dimensions will be zero.</p>
     * example:<pre><code>
    var vpSize = Ext.getBody().getViewSize();
      // all Windows created afterwards will have a default value of 90% height and 95% width
    Ext.Window.override({
        width: vpSize.width * 0.9,
        height: vpSize.height * 0.95
    });
    // To handle window resizing you would have to hook onto onWindowResize.
    * </code></pre>
    *
    * getViewSize utilizes clientHeight/clientWidth which excludes sizing of scrollbars.
    * To obtain the size including scrollbars, use getStyleSize
    *
    * Sizing of the document body is handled at the adapter level which handles special cases for IE and strict modes, etc.
    */
    getViewSize: function getViewSize() {
      var doc = document,
          d = this.dom,
          isDoc = d == doc || d == doc.body; // If the body, use Ext.lib.Dom

      if (isDoc) {
        var extdom = Ext.lib.Dom;
        return {
          width: extdom.getViewWidth(),
          height: extdom.getViewHeight()
        }; // Else use clientHeight/clientWidth
      } else {
        return {
          width: d.clientWidth,
          height: d.clientHeight
        };
      }
    },

    /**
    * <p>Returns the dimensions of the element available to lay content out in.<p>
    *
    * getStyleSize utilizes prefers style sizing if present, otherwise it chooses the larger of offsetHeight/clientHeight and offsetWidth/clientWidth.
    * To obtain the size excluding scrollbars, use getViewSize
    *
    * Sizing of the document body is handled at the adapter level which handles special cases for IE and strict modes, etc.
    */
    getStyleSize: function getStyleSize() {
      var me = this,
          w,
          h,
          doc = document,
          d = this.dom,
          isDoc = d == doc || d == doc.body,
          s = d.style; // If the body, use Ext.lib.Dom

      if (isDoc) {
        var extdom = Ext.lib.Dom;
        return {
          width: extdom.getViewWidth(),
          height: extdom.getViewHeight()
        };
      } // Use Styles if they are set


      if (s.width && s.width != 'auto') {
        w = parseFloat(s.width);

        if (me.isBorderBox()) {
          w -= me.getFrameWidth('lr');
        }
      } // Use Styles if they are set


      if (s.height && s.height != 'auto') {
        h = parseFloat(s.height);

        if (me.isBorderBox()) {
          h -= me.getFrameWidth('tb');
        }
      } // Use getWidth/getHeight if style not set.


      return {
        width: w || me.getWidth(true),
        height: h || me.getHeight(true)
      };
    },

    /**
     * Returns the size of the element.
     * @param {Boolean} contentSize (optional) true to get the width/size minus borders and padding
     * @return {Object} An object containing the element's size {width: (element width), height: (element height)}
     */
    getSize: function getSize(contentSize) {
      return {
        width: this.getWidth(contentSize),
        height: this.getHeight(contentSize)
      };
    },

    /**
     * Forces the browser to repaint this element
     * @return {Ext.Element} this
     */
    repaint: function repaint() {
      var dom = this.dom;
      this.addClass("x-repaint");
      setTimeout(function () {
        Ext.fly(dom).removeClass("x-repaint");
      }, 1);
      return this;
    },

    /**
     * Disables text selection for this element (normalized across browsers)
     * @return {Ext.Element} this
     */
    unselectable: function unselectable() {
      this.dom.unselectable = "on";
      return this.swallowEvent("selectstart", true).applyStyles("-moz-user-select:none;-khtml-user-select:none;").addClass("x-unselectable");
    },

    /**
     * Returns an object with properties top, left, right and bottom representing the margins of this element unless sides is passed,
     * then it returns the calculated width of the sides (see getPadding)
     * @param {String} sides (optional) Any combination of l, r, t, b to get the sum of those sides
     * @return {Object/Number}
     */
    getMargins: function getMargins(side) {
      var me = this,
          key,
          hash = {
        t: "top",
        l: "left",
        r: "right",
        b: "bottom"
      },
          o = {};

      if (!side) {
        for (key in me.margins) {
          o[hash[key]] = parseFloat(me.getStyle(me.margins[key])) || 0;
        }

        return o;
      } else {
        return me.addStyles.call(me, side, me.margins);
      }
    }
  };
}());

/***/ }),
/* 725 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
(function () {
  var D = Ext.lib.Dom,
      LEFT = "left",
      RIGHT = "right",
      TOP = "top",
      BOTTOM = "bottom",
      POSITION = "position",
      STATIC = "static",
      RELATIVE = "relative",
      AUTO = "auto",
      ZINDEX = "z-index";
  Ext.Element.addMethods({
    /**
         * Gets the current X position of the element based on page coordinates.  Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
         * @return {Number} The X position of the element
         */
    getX: function getX() {
      return D.getX(this.dom);
    },

    /**
      * Gets the current Y position of the element based on page coordinates.  Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
      * @return {Number} The Y position of the element
      */
    getY: function getY() {
      return D.getY(this.dom);
    },

    /**
      * Gets the current position of the element based on page coordinates.  Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
      * @return {Array} The XY position of the element
      */
    getXY: function getXY() {
      return D.getXY(this.dom);
    },

    /**
      * Returns the offsets of this element from the passed element. Both element must be part of the DOM tree and not have display:none to have page coordinates.
      * @param {Mixed} element The element to get the offsets from.
      * @return {Array} The XY page offsets (e.g. [100, -200])
      */
    getOffsetsTo: function getOffsetsTo(el) {
      var o = this.getXY(),
          e = Ext.fly(el, '_internal').getXY();
      return [o[0] - e[0], o[1] - e[1]];
    },

    /**
     * Sets the X position of the element based on page coordinates.  Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
     * @param {Number} The X position of the element
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setX: function setX(x, animate) {
      return this.setXY([x, this.getY()], this.animTest(arguments, animate, 1));
    },

    /**
     * Sets the Y position of the element based on page coordinates.  Element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
     * @param {Number} The Y position of the element
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setY: function setY(y, animate) {
      return this.setXY([this.getX(), y], this.animTest(arguments, animate, 1));
    },

    /**
     * Sets the element's left position directly using CSS style (instead of {@link #setX}).
     * @param {String} left The left CSS property value
     * @return {Ext.Element} this
     */
    setLeft: function setLeft(left) {
      this.setStyle(LEFT, this.addUnits(left));
      return this;
    },

    /**
     * Sets the element's top position directly using CSS style (instead of {@link #setY}).
     * @param {String} top The top CSS property value
     * @return {Ext.Element} this
     */
    setTop: function setTop(top) {
      this.setStyle(TOP, this.addUnits(top));
      return this;
    },

    /**
     * Sets the element's CSS right style.
     * @param {String} right The right CSS property value
     * @return {Ext.Element} this
     */
    setRight: function setRight(right) {
      this.setStyle(RIGHT, this.addUnits(right));
      return this;
    },

    /**
     * Sets the element's CSS bottom style.
     * @param {String} bottom The bottom CSS property value
     * @return {Ext.Element} this
     */
    setBottom: function setBottom(bottom) {
      this.setStyle(BOTTOM, this.addUnits(bottom));
      return this;
    },

    /**
     * Sets the position of the element in page coordinates, regardless of how the element is positioned.
     * The element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
     * @param {Array} pos Contains X & Y [x, y] values for new position (coordinates are page-based)
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setXY: function setXY(pos, animate) {
      var me = this;

      if (!animate || !me.anim) {
        D.setXY(me.dom, pos);
      } else {
        me.anim({
          points: {
            to: pos
          }
        }, me.preanim(arguments, 1), 'motion');
      }

      return me;
    },

    /**
     * Sets the position of the element in page coordinates, regardless of how the element is positioned.
     * The element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
     * @param {Number} x X value for new position (coordinates are page-based)
     * @param {Number} y Y value for new position (coordinates are page-based)
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setLocation: function setLocation(x, y, animate) {
      return this.setXY([x, y], this.animTest(arguments, animate, 2));
    },

    /**
     * Sets the position of the element in page coordinates, regardless of how the element is positioned.
     * The element must be part of the DOM tree to have page coordinates (display:none or elements not appended return false).
     * @param {Number} x X value for new position (coordinates are page-based)
     * @param {Number} y Y value for new position (coordinates are page-based)
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    moveTo: function moveTo(x, y, animate) {
      return this.setXY([x, y], this.animTest(arguments, animate, 2));
    },

    /**
     * Gets the left X coordinate
     * @param {Boolean} local True to get the local css position instead of page coordinate
     * @return {Number}
     */
    getLeft: function getLeft(local) {
      return !local ? this.getX() : parseInt(this.getStyle(LEFT), 10) || 0;
    },

    /**
     * Gets the right X coordinate of the element (element X position + element width)
     * @param {Boolean} local True to get the local css position instead of page coordinate
     * @return {Number}
     */
    getRight: function getRight(local) {
      var me = this;
      return !local ? me.getX() + me.getWidth() : me.getLeft(true) + me.getWidth() || 0;
    },

    /**
     * Gets the top Y coordinate
     * @param {Boolean} local True to get the local css position instead of page coordinate
     * @return {Number}
     */
    getTop: function getTop(local) {
      return !local ? this.getY() : parseInt(this.getStyle(TOP), 10) || 0;
    },

    /**
     * Gets the bottom Y coordinate of the element (element Y position + element height)
     * @param {Boolean} local True to get the local css position instead of page coordinate
     * @return {Number}
     */
    getBottom: function getBottom(local) {
      var me = this;
      return !local ? me.getY() + me.getHeight() : me.getTop(true) + me.getHeight() || 0;
    },

    /**
    * Initializes positioning on this element. If a desired position is not passed, it will make the
    * the element positioned relative IF it is not already positioned.
    * @param {String} pos (optional) Positioning to use "relative", "absolute" or "fixed"
    * @param {Number} zIndex (optional) The zIndex to apply
    * @param {Number} x (optional) Set the page X position
    * @param {Number} y (optional) Set the page Y position
    */
    position: function position(pos, zIndex, x, y) {
      var me = this;

      if (!pos && me.isStyle(POSITION, STATIC)) {
        me.setStyle(POSITION, RELATIVE);
      } else if (pos) {
        me.setStyle(POSITION, pos);
      }

      if (zIndex) {
        me.setStyle(ZINDEX, zIndex);
      }

      if (x || y) me.setXY([x || false, y || false]);
    },

    /**
    * Clear positioning back to the default when the document was loaded
    * @param {String} value (optional) The value to use for the left,right,top,bottom, defaults to '' (empty string). You could use 'auto'.
    * @return {Ext.Element} this
     */
    clearPositioning: function clearPositioning(value) {
      value = value || '';
      this.setStyle({
        left: value,
        right: value,
        top: value,
        bottom: value,
        "z-index": "",
        position: STATIC
      });
      return this;
    },

    /**
    * Gets an object with all CSS positioning properties. Useful along with setPostioning to get
    * snapshot before performing an update and then restoring the element.
    * @return {Object}
    */
    getPositioning: function getPositioning() {
      var l = this.getStyle(LEFT);
      var t = this.getStyle(TOP);
      return {
        "position": this.getStyle(POSITION),
        "left": l,
        "right": l ? "" : this.getStyle(RIGHT),
        "top": t,
        "bottom": t ? "" : this.getStyle(BOTTOM),
        "z-index": this.getStyle(ZINDEX)
      };
    },

    /**
    * Set positioning with an object returned by getPositioning().
    * @param {Object} posCfg
    * @return {Ext.Element} this
     */
    setPositioning: function setPositioning(pc) {
      var me = this,
          style = me.dom.style;
      me.setStyle(pc);

      if (pc.right == AUTO) {
        style.right = "";
      }

      if (pc.bottom == AUTO) {
        style.bottom = "";
      }

      return me;
    },

    /**
     * Translates the passed page coordinates into left/top css values for this element
     * @param {Number/Array} x The page x or an array containing [x, y]
     * @param {Number} y (optional) The page y, required if x is not an array
     * @return {Object} An object with left and top properties. e.g. {left: (value), top: (value)}
     */
    translatePoints: function translatePoints(x, y) {
      y = isNaN(x[1]) ? y : x[1];
      x = isNaN(x[0]) ? x : x[0];
      var me = this,
          relative = me.isStyle(POSITION, RELATIVE),
          o = me.getXY(),
          l = parseInt(me.getStyle(LEFT), 10),
          t = parseInt(me.getStyle(TOP), 10);
      l = !isNaN(l) ? l : relative ? 0 : me.dom.offsetLeft;
      t = !isNaN(t) ? t : relative ? 0 : me.dom.offsetTop;
      return {
        left: x - o[0] + l,
        top: y - o[1] + t
      };
    },
    animTest: function animTest(args, animate, i) {
      return !!animate && this.preanim ? this.preanim(args, i) : false;
    }
  });
})();

/***/ }),
/* 726 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Sets the element's box. Use getBox() on another element to get a box obj. If animate is true then width, height, x and y will be animated concurrently.
   * @param {Object} box The box to fill {x, y, width, height}
   * @param {Boolean} adjust (optional) Whether to adjust for box-model issues automatically
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Ext.Element} this
   */
  setBox: function setBox(box, adjust, animate) {
    var me = this,
        w = box.width,
        h = box.height;

    if (adjust && !me.autoBoxAdjust && !me.isBorderBox()) {
      w -= me.getBorderWidth("lr") + me.getPadding("lr");
      h -= me.getBorderWidth("tb") + me.getPadding("tb");
    }

    me.setBounds(box.x, box.y, w, h, me.animTest.call(me, arguments, animate, 2));
    return me;
  },

  /**
   * Return an object defining the area of this Element which can be passed to {@link #setBox} to
   * set another Element's size/location to match this element.
   * @param {Boolean} contentBox (optional) If true a box for the content of the element is returned.
   * @param {Boolean} local (optional) If true the element's left and top are returned instead of page x/y.
   * @return {Object} box An object in the format<pre><code>
  {
  x: &lt;Element's X position>,
  y: &lt;Element's Y position>,
  width: &lt;Element's width>,
  height: &lt;Element's height>,
  bottom: &lt;Element's lower bound>,
  right: &lt;Element's rightmost bound>
  }
  </code></pre>
   * The returned object may also be addressed as an Array where index 0 contains the X position
   * and index 1 contains the Y position. So the result may also be used for {@link #setXY}
   */
  getBox: function getBox(contentBox, local) {
    var me = this,
        xy,
        left,
        top,
        getBorderWidth = me.getBorderWidth,
        getPadding = me.getPadding,
        l,
        r,
        t,
        b;

    if (!local) {
      xy = me.getXY();
    } else {
      left = parseInt(me.getStyle("left"), 10) || 0;
      top = parseInt(me.getStyle("top"), 10) || 0;
      xy = [left, top];
    }

    var el = me.dom,
        w = el.offsetWidth,
        h = el.offsetHeight,
        bx;

    if (!contentBox) {
      bx = {
        x: xy[0],
        y: xy[1],
        0: xy[0],
        1: xy[1],
        width: w,
        height: h
      };
    } else {
      l = getBorderWidth.call(me, "l") + getPadding.call(me, "l");
      r = getBorderWidth.call(me, "r") + getPadding.call(me, "r");
      t = getBorderWidth.call(me, "t") + getPadding.call(me, "t");
      b = getBorderWidth.call(me, "b") + getPadding.call(me, "b");
      bx = {
        x: xy[0] + l,
        y: xy[1] + t,
        0: xy[0] + l,
        1: xy[1] + t,
        width: w - (l + r),
        height: h - (t + b)
      };
    }

    bx.right = bx.x + bx.width;
    bx.bottom = bx.y + bx.height;
    return bx;
  },

  /**
   * Move this element relative to its current position.
   * @param {String} direction Possible values are: "l" (or "left"), "r" (or "right"), "t" (or "top", or "up"), "b" (or "bottom", or "down").
   * @param {Number} distance How far to move the element in pixels
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Ext.Element} this
   */
  move: function move(direction, distance, animate) {
    var me = this,
        xy = me.getXY(),
        x = xy[0],
        y = xy[1],
        left = [x - distance, y],
        right = [x + distance, y],
        top = [x, y - distance],
        bottom = [x, y + distance],
        hash = {
      l: left,
      left: left,
      r: right,
      right: right,
      t: top,
      top: top,
      up: top,
      b: bottom,
      bottom: bottom,
      down: bottom
    };
    direction = direction.toLowerCase();
    me.moveTo(hash[direction][0], hash[direction][1], me.animTest.call(me, arguments, animate, 2));
  },

  /**
   * Quick set left and top adding default units
   * @param {String} left The left CSS property value
   * @param {String} top The top CSS property value
   * @return {Ext.Element} this
   */
  setLeftTop: function setLeftTop(left, top) {
    var me = this,
        style = me.dom.style;
    style.left = me.addUnits(left);
    style.top = me.addUnits(top);
    return me;
  },

  /**
   * Returns the region of the given element.
   * The element must be part of the DOM tree to have a region (display:none or elements not appended return false).
   * @return {Region} A Ext.lib.Region containing "top, left, bottom, right" member data.
   */
  getRegion: function getRegion() {
    return Ext.lib.Dom.getRegion(this.dom);
  },

  /**
   * Sets the element's position and size in one shot. If animation is true then width, height, x and y will be animated concurrently.
   * @param {Number} x X value for new position (coordinates are page-based)
   * @param {Number} y Y value for new position (coordinates are page-based)
   * @param {Mixed} width The new width. This may be one of:<div class="mdetail-params"><ul>
   * <li>A Number specifying the new width in this Element's {@link #defaultUnit}s (by default, pixels)</li>
   * <li>A String used to set the CSS width style. Animation may <b>not</b> be used.
   * </ul></div>
   * @param {Mixed} height The new height. This may be one of:<div class="mdetail-params"><ul>
   * <li>A Number specifying the new height in this Element's {@link #defaultUnit}s (by default, pixels)</li>
   * <li>A String used to set the CSS height style. Animation may <b>not</b> be used.</li>
   * </ul></div>
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Ext.Element} this
   */
  setBounds: function setBounds(x, y, width, height, animate) {
    var me = this;

    if (!animate || !me.anim) {
      me.setSize(width, height);
      me.setLocation(x, y);
    } else {
      me.anim({
        points: {
          to: [x, y]
        },
        width: {
          to: me.adjustWidth(width)
        },
        height: {
          to: me.adjustHeight(height)
        }
      }, me.preanim(arguments, 4), 'motion');
    }

    return me;
  },

  /**
   * Sets the element's position and size the specified region. If animation is true then width, height, x and y will be animated concurrently.
   * @param {Ext.lib.Region} region The region to fill
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Ext.Element} this
   */
  setRegion: function setRegion(region, animate) {
    return this.setBounds(region.left, region.top, region.right - region.left, region.bottom - region.top, this.animTest.call(this, arguments, animate, 1));
  }
});

/***/ }),
/* 727 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Returns true if this element is scrollable.
   * @return {Boolean}
   */
  isScrollable: function isScrollable() {
    var dom = this.dom;
    return dom.scrollHeight > dom.clientHeight || dom.scrollWidth > dom.clientWidth;
  },

  /**
   * Scrolls this element the specified scroll point. It does NOT do bounds checking so if you scroll to a weird value it will try to do it. For auto bounds checking, use scroll().
   * @param {String} side Either "left" for scrollLeft values or "top" for scrollTop values.
   * @param {Number} value The new scroll value.
   * @return {Element} this
   */
  scrollTo: function scrollTo(side, value) {
    this.dom["scroll" + (/top/i.test(side) ? "Top" : "Left")] = value;
    return this;
  },

  /**
   * Returns the current scroll position of the element.
   * @return {Object} An object containing the scroll position in the format {left: (scrollLeft), top: (scrollTop)}
   */
  getScroll: function getScroll() {
    var d = this.dom,
        doc = document,
        body = doc.body,
        docElement = doc.documentElement,
        l,
        t,
        ret;

    if (d == doc || d == body) {
      if (Ext.isIE && Ext.isStrict) {
        l = docElement.scrollLeft;
        t = docElement.scrollTop;
      } else {
        l = window.pageXOffset;
        t = window.pageYOffset;
      }

      ret = {
        left: l || (body ? body.scrollLeft : 0),
        top: t || (body ? body.scrollTop : 0)
      };
    } else {
      ret = {
        left: d.scrollLeft,
        top: d.scrollTop
      };
    }

    return ret;
  }
});

/***/ }),
/* 728 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Scrolls this element the specified scroll point. It does NOT do bounds checking so if you scroll to a weird value it will try to do it. For auto bounds checking, use scroll().
   * @param {String} side Either "left" for scrollLeft values or "top" for scrollTop values.
   * @param {Number} value The new scroll value
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Element} this
   */
  scrollTo: function scrollTo(side, value, animate) {
    var top = /top/i.test(side),
        //check if we're scrolling top or left
    me = this,
        dom = me.dom,
        prop;

    if (!animate || !me.anim) {
      prop = 'scroll' + (top ? 'Top' : 'Left'), // just setting the value, so grab the direction
      dom[prop] = value;
    } else {
      prop = 'scroll' + (top ? 'Left' : 'Top'), // if scrolling top, we need to grab scrollLeft, if left, scrollTop
      me.anim({
        scroll: {
          to: top ? [dom[prop], value] : [value, dom[prop]]
        }
      }, me.preanim(arguments, 2), 'scroll');
    }

    return me;
  },

  /**
   * Scrolls this element into view within the passed container.
   * @param {Mixed} container (optional) The container element to scroll (defaults to document.body).  Should be a
   * string (id), dom node, or Ext.Element.
   * @param {Boolean} hscroll (optional) False to disable horizontal scroll (defaults to true)
   * @return {Ext.Element} this
   */
  scrollIntoView: function scrollIntoView(container, hscroll) {
    var c = Ext.getDom(container) || Ext.getBody().dom,
        el = this.dom,
        o = this.getOffsetsTo(c),
        l = o[0] + c.scrollLeft,
        t = o[1] + c.scrollTop,
        b = t + el.offsetHeight,
        r = l + el.offsetWidth,
        ch = c.clientHeight,
        ct = parseInt(c.scrollTop, 10),
        cl = parseInt(c.scrollLeft, 10),
        cb = ct + ch,
        cr = cl + c.clientWidth;

    if (el.offsetHeight > ch || t < ct) {
      c.scrollTop = t;
    } else if (b > cb) {
      c.scrollTop = b - ch;
    }

    c.scrollTop = c.scrollTop; // corrects IE, other browsers will ignore

    if (hscroll !== false) {
      if (el.offsetWidth > c.clientWidth || l < cl) {
        c.scrollLeft = l;
      } else if (r > cr) {
        c.scrollLeft = r - c.clientWidth;
      }

      c.scrollLeft = c.scrollLeft;
    }

    return this;
  },
  // private
  scrollChildIntoView: function scrollChildIntoView(child, hscroll) {
    Ext.fly(child, '_scrollChildIntoView').scrollIntoView(this, hscroll);
  },

  /**
   * Scrolls this element the specified direction. Does bounds checking to make sure the scroll is
   * within this element's scrollable range.
   * @param {String} direction Possible values are: "l" (or "left"), "r" (or "right"), "t" (or "top", or "up"), "b" (or "bottom", or "down").
   * @param {Number} distance How far to scroll the element in pixels
   * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
   * @return {Boolean} Returns true if a scroll was triggered or false if the element
   * was scrolled as far as it could go.
   */
  scroll: function scroll(direction, distance, animate) {
    if (!this.isScrollable()) {
      return;
    }

    var el = this.dom,
        l = el.scrollLeft,
        t = el.scrollTop,
        w = el.scrollWidth,
        h = el.scrollHeight,
        cw = el.clientWidth,
        ch = el.clientHeight,
        scrolled = false,
        v,
        hash = {
      l: Math.min(l + distance, w - cw),
      r: v = Math.max(l - distance, 0),
      t: Math.max(t - distance, 0),
      b: Math.min(t + distance, h - ch)
    };
    hash.d = hash.b;
    hash.u = hash.t;
    direction = direction.substr(0, 1);

    if ((v = hash[direction]) > -1) {
      scrolled = true;
      this.scrollTo(direction == 'l' || direction == 'r' ? 'left' : 'top', v, this.preanim(arguments, 2));
    }

    return scrolled;
  }
});

/***/ }),
/* 729 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */

/**
 * Visibility mode constant for use with {@link #setVisibilityMode}. Use visibility to hide element
 * @static
 * @type Number
 */
Ext.Element.VISIBILITY = 1;
/**
 * Visibility mode constant for use with {@link #setVisibilityMode}. Use display to hide element
 * @static
 * @type Number
 */

Ext.Element.DISPLAY = 2;
Ext.Element.addMethods(function () {
  var VISIBILITY = "visibility",
      DISPLAY = "display",
      HIDDEN = "hidden",
      NONE = "none",
      ORIGINALDISPLAY = 'originalDisplay',
      VISMODE = 'visibilityMode',
      ELDISPLAY = Ext.Element.DISPLAY,
      data = Ext.Element.data,
      getDisplay = function getDisplay(dom) {
    var d = data(dom, ORIGINALDISPLAY);

    if (d === undefined) {
      data(dom, ORIGINALDISPLAY, d = '');
    }

    return d;
  },
      getVisMode = function getVisMode(dom) {
    var m = data(dom, VISMODE);

    if (m === undefined) {
      data(dom, VISMODE, m = 1);
    }

    return m;
  };

  return {
    /**
     * The element's default display mode  (defaults to "")
     * @type String
     */
    originalDisplay: "",
    visibilityMode: 1,

    /**
     * Sets the element's visibility mode. When setVisible() is called it
     * will use this to determine whether to set the visibility or the display property.
     * @param {Number} visMode Ext.Element.VISIBILITY or Ext.Element.DISPLAY
     * @return {Ext.Element} this
     */
    setVisibilityMode: function setVisibilityMode(visMode) {
      data(this.dom, VISMODE, visMode);
      return this;
    },

    /**
     * Perform custom animation on this element.
     * <div><ul class="mdetail-params">
     * <li><u>Animation Properties</u></li>
     * 
     * <p>The Animation Control Object enables gradual transitions for any member of an
     * element's style object that takes a numeric value including but not limited to
     * these properties:</p><div><ul class="mdetail-params">
     * <li><tt>bottom, top, left, right</tt></li>
     * <li><tt>height, width</tt></li>
     * <li><tt>margin, padding</tt></li>
     * <li><tt>borderWidth</tt></li>
     * <li><tt>opacity</tt></li>
     * <li><tt>fontSize</tt></li>
     * <li><tt>lineHeight</tt></li>
     * </ul></div>
     * 
     * 
     * <li><u>Animation Property Attributes</u></li>
     * 
     * <p>Each Animation Property is a config object with optional properties:</p>
     * <div><ul class="mdetail-params">
     * <li><tt>by</tt>*  : relative change - start at current value, change by this value</li>
     * <li><tt>from</tt> : ignore current value, start from this value</li>
     * <li><tt>to</tt>*  : start at current value, go to this value</li>
     * <li><tt>unit</tt> : any allowable unit specification</li>
     * <p>* do not specify both <tt>to</tt> and <tt>by</tt> for an animation property</p>
     * </ul></div>
     * 
     * <li><u>Animation Types</u></li>
     * 
     * <p>The supported animation types:</p><div><ul class="mdetail-params">
     * <li><tt>'run'</tt> : Default
     * <pre><code>
    var el = Ext.get('complexEl');
    el.animate(
    // animation control object
    {
    borderWidth: {to: 3, from: 0},
    opacity: {to: .3, from: 1},
    height: {to: 50, from: el.getHeight()},
    width: {to: 300, from: el.getWidth()},
    top  : {by: - 100, unit: 'px'},
    },
    0.35,      // animation duration
    null,      // callback
    'easeOut', // easing method
    'run'      // animation type ('run','color','motion','scroll')    
    );
     * </code></pre>
     * </li>
     * <li><tt>'color'</tt>
     * <p>Animates transition of background, text, or border colors.</p>
     * <pre><code>
    el.animate(
    // animation control object
    {
    color: { to: '#06e' },
    backgroundColor: { to: '#e06' }
    },
    0.35,      // animation duration
    null,      // callback
    'easeOut', // easing method
    'color'    // animation type ('run','color','motion','scroll')    
    );
     * </code></pre> 
     * </li>
     * 
     * <li><tt>'motion'</tt>
     * <p>Animates the motion of an element to/from specific points using optional bezier
     * way points during transit.</p>
     * <pre><code>
    el.animate(
    // animation control object
    {
    borderWidth: {to: 3, from: 0},
    opacity: {to: .3, from: 1},
    height: {to: 50, from: el.getHeight()},
    width: {to: 300, from: el.getWidth()},
    top  : {by: - 100, unit: 'px'},
    points: {
        to: [50, 100],  // go to this point
        control: [      // optional bezier way points
            [ 600, 800],
            [-100, 200]
        ]
    }
    },
    3000,      // animation duration (milliseconds!)
    null,      // callback
    'easeOut', // easing method
    'motion'   // animation type ('run','color','motion','scroll')    
    );
     * </code></pre> 
     * </li>
     * <li><tt>'scroll'</tt>
     * <p>Animate horizontal or vertical scrolling of an overflowing page element.</p>
     * <pre><code>
    el.animate(
    // animation control object
    {
    scroll: {to: [400, 300]}
    },
    0.35,      // animation duration
    null,      // callback
    'easeOut', // easing method
    'scroll'   // animation type ('run','color','motion','scroll')    
    );
     * </code></pre> 
     * </li>
     * </ul></div>
     * 
     * </ul></div>
     * 
     * @param {Object} args The animation control args
     * @param {Float} duration (optional) How long the animation lasts in seconds (defaults to <tt>.35</tt>)
     * @param {Function} onComplete (optional) Function to call when animation completes
     * @param {String} easing (optional) {@link Ext.Fx#easing} method to use (defaults to <tt>'easeOut'</tt>)
     * @param {String} animType (optional) <tt>'run'</tt> is the default. Can also be <tt>'color'</tt>,
     * <tt>'motion'</tt>, or <tt>'scroll'</tt>
     * @return {Ext.Element} this
     */
    animate: function animate(args, duration, onComplete, easing, animType) {
      this.anim(args, {
        duration: duration,
        callback: onComplete,
        easing: easing
      }, animType);
      return this;
    },

    /*
     * @private Internal animation call
     */
    anim: function anim(args, opt, animType, defaultDur, defaultEase, cb) {
      animType = animType || 'run';
      opt = opt || {};
      var me = this,
          anim = Ext.lib.Anim[animType](me.dom, args, opt.duration || defaultDur || .35, opt.easing || defaultEase || 'easeOut', function () {
        if (cb) cb.call(me);
        if (opt.callback) opt.callback.call(opt.scope || me, me, opt);
      }, me);
      opt.anim = anim;
      return anim;
    },
    // private legacy anim prep
    preanim: function preanim(a, i) {
      return !a[i] ? false : Ext.isObject(a[i]) ? a[i] : {
        duration: a[i + 1],
        callback: a[i + 2],
        easing: a[i + 3]
      };
    },

    /**
     * Checks whether the element is currently visible using both visibility and display properties.         
     * @return {Boolean} True if the element is currently visible, else false
     */
    isVisible: function isVisible() {
      return !this.isStyle(VISIBILITY, HIDDEN) && !this.isStyle(DISPLAY, NONE);
    },

    /**
     * Sets the visibility of the element (see details). If the visibilityMode is set to Element.DISPLAY, it will use
     * the display property to hide the element, otherwise it uses visibility. The default is to hide and show using the visibility property.
     * @param {Boolean} visible Whether the element is visible
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    setVisible: function setVisible(visible, animate) {
      var me = this,
          dom = me.dom,
          isDisplay = getVisMode(this.dom) == ELDISPLAY;

      if (!animate || !me.anim) {
        if (isDisplay) {
          me.setDisplayed(visible);
        } else {
          me.fixDisplay();
          dom.style.visibility = visible ? "visible" : HIDDEN;
        }
      } else {
        // closure for composites            
        if (visible) {
          me.setOpacity(.01);
          me.setVisible(true);
        }

        me.anim({
          opacity: {
            to: visible ? 1 : 0
          }
        }, me.preanim(arguments, 1), null, .35, 'easeIn', function () {
          if (!visible) {
            dom.style[isDisplay ? DISPLAY : VISIBILITY] = isDisplay ? NONE : HIDDEN;
            Ext.fly(dom).setOpacity(1);
          }
        });
      }

      return me;
    },

    /**
     * Toggles the element's visibility or display, depending on visibility mode.
     * @param {Boolean/Object} animate (optional) True for the default animation, or a standard Element animation config object
     * @return {Ext.Element} this
     */
    toggle: function toggle(animate) {
      var me = this;
      me.setVisible(!me.isVisible(), me.preanim(arguments, 0));
      return me;
    },

    /**
     * Sets the CSS display property. Uses originalDisplay if the specified value is a boolean true.
     * @param {Mixed} value Boolean value to display the element using its default display, or a string to set the display directly.
     * @return {Ext.Element} this
     */
    setDisplayed: function setDisplayed(value) {
      if (typeof value == "boolean") {
        value = value ? getDisplay(this.dom) : NONE;
      }

      this.setStyle(DISPLAY, value);
      return this;
    },
    // private
    fixDisplay: function fixDisplay() {
      var me = this;

      if (me.isStyle(DISPLAY, NONE)) {
        me.setStyle(VISIBILITY, HIDDEN);
        me.setStyle(DISPLAY, getDisplay(this.dom)); // first try reverting to default

        if (me.isStyle(DISPLAY, NONE)) {
          // if that fails, default to block
          me.setStyle(DISPLAY, "block");
        }
      }
    },

    /**
     * Hide this element - Uses display mode to determine whether to use "display" or "visibility". See {@link #setVisible}.
     * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
     * @return {Ext.Element} this
     */
    hide: function hide(animate) {
      this.setVisible(false, this.preanim(arguments, 0));
      return this;
    },

    /**
    * Show this element - Uses display mode to determine whether to use "display" or "visibility". See {@link #setVisible}.
    * @param {Boolean/Object} animate (optional) true for the default animation or a standard Element animation config object
     * @return {Ext.Element} this
     */
    show: function show(animate) {
      this.setVisible(true, this.preanim(arguments, 0));
      return this;
    }
  };
}());

/***/ }),
/* 730 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods(function () {
  var VISIBILITY = "visibility",
      DISPLAY = "display",
      HIDDEN = "hidden",
      NONE = "none",
      XMASKED = "x-masked",
      XMASKEDRELATIVE = "x-masked-relative",
      data = Ext.Element.data;
  return {
    /**
        * Checks whether the element is currently visible using both visibility and display properties.
        * @param {Boolean} deep (optional) True to walk the dom and see if parent elements are hidden (defaults to false)
        * @return {Boolean} True if the element is currently visible, else false
        */
    isVisible: function isVisible(deep) {
      var vis = !this.isStyle(VISIBILITY, HIDDEN) && !this.isStyle(DISPLAY, NONE),
          p = this.dom.parentNode;

      if (deep !== true || !vis) {
        return vis;
      }

      while (p && !/^body/i.test(p.tagName)) {
        if (!Ext.fly(p, '_isVisible').isVisible()) {
          return false;
        }

        p = p.parentNode;
      }

      return true;
    },

    /**
     * Returns true if display is not "none"
     * @return {Boolean}
     */
    isDisplayed: function isDisplayed() {
      return !this.isStyle(DISPLAY, NONE);
    },

    /**
        * Convenience method for setVisibilityMode(Element.DISPLAY)
        * @param {String} display (optional) What to set display to when visible
        * @return {Ext.Element} this
        */
    enableDisplayMode: function enableDisplayMode(display) {
      this.setVisibilityMode(Ext.Element.DISPLAY);

      if (!Ext.isEmpty(display)) {
        data(this.dom, 'originalDisplay', display);
      }

      return this;
    },

    /**
        * Puts a mask over this element to disable user interaction. Requires core.css.
        * This method can only be applied to elements which accept child nodes.
        * @param {String} msg (optional) A message to display in the mask
        * @param {String} msgCls (optional) A css class to apply to the msg element
        * @return {Element} The mask element
        */
    mask: function mask(msg, msgCls) {
      var me = this,
          dom = me.dom,
          dh = Ext.DomHelper,
          EXTELMASKMSG = "ext-el-mask-msg",
          el,
          mask;

      if (me.getStyle("position") == "static") {
        me.addClass(XMASKEDRELATIVE);
      }

      if (el = data(dom, 'maskMsg')) {
        el.remove();
      }

      if (el = data(dom, 'mask')) {
        el.remove();
      }

      mask = dh.append(dom, {
        cls: "ext-el-mask"
      }, true);
      data(dom, 'mask', mask);
      me.addClass(XMASKED);
      mask.setDisplayed(true);

      if (typeof msg == 'string') {
        var mm = dh.append(dom, {
          cls: EXTELMASKMSG,
          cn: [{
            tag: 'div'
          }, {
            tag: 'div',
            cls: 'ext-el-mask-wait x-mask-wait'
          }]
        }, true);
        data(dom, 'maskMsg', mm);
        mm.dom.className = msgCls ? EXTELMASKMSG + " " + msgCls : EXTELMASKMSG;
        mm.dom.firstChild.innerHTML = msg;
        mm.setDisplayed(true);
        mm.center(me);
      }

      if (Ext.isIE && !(Ext.isIE7 && Ext.isStrict) && me.getStyle('height') == 'auto') {
        // ie will not expand full height automatically
        mask.setSize(undefined, me.getHeight());
      }

      return mask;
    },

    /**
     * Removes a previously applied mask.
     */
    unmask: function unmask() {
      var me = this,
          dom = me.dom,
          mask = data(dom, 'mask'),
          maskMsg = data(dom, 'maskMsg');

      if (mask) {
        if (maskMsg) {
          maskMsg.remove();
          data(dom, 'maskMsg', undefined);
        }

        mask.remove();
        data(dom, 'mask', undefined);
      }

      me.removeClass([XMASKED, XMASKEDRELATIVE]);
    },

    /**
     * Returns true if this element is masked
     * @return {Boolean}
     */
    isMasked: function isMasked() {
      var m = data(this.dom, 'mask');
      return m && m.isVisible();
    },

    /**
     * Creates an iframe shim for this element to keep selects and other windowed objects from
     * showing through.
     * @return {Ext.Element} The new shim element
     */
    createShim: function createShim() {
      var el = document.createElement('iframe'),
          shim;
      el.frameBorder = '0';
      el.className = 'ext-shim';
      el.src = Ext.SSL_SECURE_URL;
      shim = Ext.get(this.dom.parentNode.insertBefore(el, this.dom));
      shim.autoBoxAdjust = false;
      return shim;
    }
  };
}());

/***/ }),
/* 731 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Convenience method for constructing a KeyMap
   * @param {Number/Array/Object/String} key Either a string with the keys to listen for, the numeric key code, array of key codes or an object with the following options:
   * <code>{key: (number or array), shift: (true/false), ctrl: (true/false), alt: (true/false)}</code>
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the specified function is executed. Defaults to this Element.
   * @return {Ext.KeyMap} The KeyMap created
   */
  addKeyListener: function addKeyListener(key, fn, scope) {
    var config;

    if (!Ext.isObject(key) || Ext.isArray(key)) {
      config = {
        key: key,
        fn: fn,
        scope: scope
      };
    } else {
      config = {
        key: key.key,
        shift: key.shift,
        ctrl: key.ctrl,
        alt: key.alt,
        fn: fn,
        scope: scope
      };
    }

    return new Ext.KeyMap(this, config);
  },

  /**
   * Creates a KeyMap for this element
   * @param {Object} config The KeyMap config. See {@link Ext.KeyMap} for more details
   * @return {Ext.KeyMap} The KeyMap created
   */
  addKeyMap: function addKeyMap(config) {
    return new Ext.KeyMap(this, config);
  }
});

/***/ }),
/* 732 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
(function () {
  // contants
  var NULL = null,
      UNDEFINED = undefined,
      TRUE = true,
      FALSE = false,
      SETX = "setX",
      SETY = "setY",
      SETXY = "setXY",
      LEFT = "left",
      BOTTOM = "bottom",
      TOP = "top",
      RIGHT = "right",
      HEIGHT = "height",
      WIDTH = "width",
      POINTS = "points",
      HIDDEN = "hidden",
      ABSOLUTE = "absolute",
      VISIBLE = "visible",
      MOTION = "motion",
      POSITION = "position",
      EASEOUT = "easeOut",

  /*
   * Use a light flyweight here since we are using so many callbacks and are always assured a DOM element
   */
  flyEl = new Ext.Element.Flyweight(),
      queues = {},
      getObject = function getObject(o) {
    return o || {};
  },
      fly = function fly(dom) {
    flyEl.dom = dom;
    flyEl.id = Ext.id(dom);
    return flyEl;
  },

  /*
   * Queueing now stored outside of the element due to closure issues
   */
  getQueue = function getQueue(id) {
    if (!queues[id]) {
      queues[id] = [];
    }

    return queues[id];
  },
      setQueue = function setQueue(id, value) {
    queues[id] = value;
  }; //Notifies Element that fx methods are available


  Ext.enableFx = TRUE;
  /**
   * @class Ext.Fx
   * <p>A class to provide basic animation and visual effects support.  <b>Note:</b> This class is automatically applied
   * to the {@link Ext.Element} interface when included, so all effects calls should be performed via {@link Ext.Element}.
   * Conversely, since the effects are not actually defined in {@link Ext.Element}, Ext.Fx <b>must</b> be
   * {@link Ext#enableFx included} in order for the Element effects to work.</p><br/>
   * 
   * <p><b><u>Method Chaining</u></b></p>
   * <p>It is important to note that although the Fx methods and many non-Fx Element methods support "method chaining" in that
   * they return the Element object itself as the method return value, it is not always possible to mix the two in a single
   * method chain.  The Fx methods use an internal effects queue so that each effect can be properly timed and sequenced.
   * Non-Fx methods, on the other hand, have no such internal queueing and will always execute immediately.  For this reason,
   * while it may be possible to mix certain Fx and non-Fx method calls in a single chain, it may not always provide the
   * expected results and should be done with care.  Also see <tt>{@link #callback}</tt>.</p><br/>
   *
   * <p><b><u>Anchor Options for Motion Effects</u></b></p>
   * <p>Motion effects support 8-way anchoring, meaning that you can choose one of 8 different anchor points on the Element
   * that will serve as either the start or end point of the animation.  Following are all of the supported anchor positions:</p>
  <pre>
  Value  Description
  -----  -----------------------------
  tl     The top left corner
  t      The center of the top edge
  tr     The top right corner
  l      The center of the left edge
  r      The center of the right edge
  bl     The bottom left corner
  b      The center of the bottom edge
  br     The bottom right corner
  </pre>
   * <b>Note</b>: some Fx methods accept specific custom config parameters.  The options shown in the Config Options
   * section below are common options that can be passed to any Fx method unless otherwise noted.</b>
   * 
   * @cfg {Function} callback A function called when the effect is finished.  Note that effects are queued internally by the
   * Fx class, so a callback is not required to specify another effect -- effects can simply be chained together
   * and called in sequence (see note for <b><u>Method Chaining</u></b> above), for example:<pre><code>
   * el.slideIn().highlight();
   * </code></pre>
   * The callback is intended for any additional code that should run once a particular effect has completed. The Element
   * being operated upon is passed as the first parameter.
   * 
   * @cfg {Object} scope The scope (<code>this</code> reference) in which the <tt>{@link #callback}</tt> function is executed. Defaults to the browser window.
   * 
   * @cfg {String} easing A valid Ext.lib.Easing value for the effect:</p><div class="mdetail-params"><ul>
   * <li><b><tt>backBoth</tt></b></li>
   * <li><b><tt>backIn</tt></b></li>
   * <li><b><tt>backOut</tt></b></li>
   * <li><b><tt>bounceBoth</tt></b></li>
   * <li><b><tt>bounceIn</tt></b></li>
   * <li><b><tt>bounceOut</tt></b></li>
   * <li><b><tt>easeBoth</tt></b></li>
   * <li><b><tt>easeBothStrong</tt></b></li>
   * <li><b><tt>easeIn</tt></b></li>
   * <li><b><tt>easeInStrong</tt></b></li>
   * <li><b><tt>easeNone</tt></b></li>
   * <li><b><tt>easeOut</tt></b></li>
   * <li><b><tt>easeOutStrong</tt></b></li>
   * <li><b><tt>elasticBoth</tt></b></li>
   * <li><b><tt>elasticIn</tt></b></li>
   * <li><b><tt>elasticOut</tt></b></li>
   * </ul></div>
   *
   * @cfg {String} afterCls A css class to apply after the effect
   * @cfg {Number} duration The length of time (in seconds) that the effect should last
   * 
   * @cfg {Number} endOpacity Only applicable for {@link #fadeIn} or {@link #fadeOut}, a number between
   * <tt>0</tt> and <tt>1</tt> inclusive to configure the ending opacity value.
   *  
   * @cfg {Boolean} remove Whether the Element should be removed from the DOM and destroyed after the effect finishes
   * @cfg {Boolean} useDisplay Whether to use the <i>display</i> CSS property instead of <i>visibility</i> when hiding Elements (only applies to 
   * effects that end with the element being visually hidden, ignored otherwise)
   * @cfg {String/Object/Function} afterStyle A style specification string, e.g. <tt>"width:100px"</tt>, or an object
   * in the form <tt>{width:"100px"}</tt>, or a function which returns such a specification that will be applied to the
   * Element after the effect finishes.
   * @cfg {Boolean} block Whether the effect should block other effects from queueing while it runs
   * @cfg {Boolean} concurrent Whether to allow subsequently-queued effects to run at the same time as the current effect, or to ensure that they run in sequence
   * @cfg {Boolean} stopFx Whether preceding effects should be stopped and removed before running current effect (only applies to non blocking effects)
   */

  Ext.Fx = {
    // private - calls the function taking arguments from the argHash based on the key.  Returns the return value of the function.
    //           this is useful for replacing switch statements (for example).
    switchStatements: function switchStatements(key, fn, argHash) {
      return fn.apply(this, argHash[key]);
    },

    /**
     * Slides the element into view.  An anchor point can be optionally passed to set the point of
     * origin for the slide effect.  This function automatically handles wrapping the element with
     * a fixed-size container if needed.  See the Fx class overview for valid anchor point options.
     * Usage:
     *<pre><code>
    // default: slide the element in from the top
    el.slideIn();
    // custom: slide the element in from the right with a 2-second duration
    el.slideIn('r', { duration: 2 });
    // common config options shown with default values
    el.slideIn('t', {
    easing: 'easeOut',
    duration: .5
    });
    </code></pre>
     * @param {String} anchor (optional) One of the valid Fx anchor positions (defaults to top: 't')
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    slideIn: function slideIn(anchor, o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          st = dom.style,
          xy,
          r,
          b,
          wrap,
          after,
          st,
          args,
          pt,
          bw,
          bh;
      anchor = anchor || "t";
      me.queueFx(o, function () {
        xy = fly(dom).getXY(); // fix display to visibility

        fly(dom).fixDisplay(); // restore values after effect

        r = fly(dom).getFxRestore();
        b = {
          x: xy[0],
          y: xy[1],
          0: xy[0],
          1: xy[1],
          width: dom.offsetWidth,
          height: dom.offsetHeight
        };
        b.right = b.x + b.width;
        b.bottom = b.y + b.height; // fixed size for slide

        fly(dom).setWidth(b.width).setHeight(b.height); // wrap if needed

        wrap = fly(dom).fxWrap(r.pos, o, HIDDEN);
        st.visibility = VISIBLE;
        st.position = ABSOLUTE; // clear out temp styles after slide and unwrap

        function after() {
          fly(dom).fxUnwrap(wrap, r.pos, o);
          st.width = r.width;
          st.height = r.height;
          fly(dom).afterFx(o);
        } // time to calculate the positions        


        pt = {
          to: [b.x, b.y]
        };
        bw = {
          to: b.width
        };
        bh = {
          to: b.height
        };

        function argCalc(wrap, style, ww, wh, sXY, sXYval, s1, s2, w, h, p) {
          var ret = {};
          fly(wrap).setWidth(ww).setHeight(wh);

          if (fly(wrap)[sXY]) {
            fly(wrap)[sXY](sXYval);
          }

          style[s1] = style[s2] = "0";

          if (w) {
            ret.width = w;
          }

          ;

          if (h) {
            ret.height = h;
          }

          if (p) {
            ret.points = p;
          }

          return ret;
        }

        ;
        args = fly(dom).switchStatements(anchor.toLowerCase(), argCalc, {
          t: [wrap, st, b.width, 0, NULL, NULL, LEFT, BOTTOM, NULL, bh, NULL],
          l: [wrap, st, 0, b.height, NULL, NULL, RIGHT, TOP, bw, NULL, NULL],
          r: [wrap, st, b.width, b.height, SETX, b.right, LEFT, TOP, NULL, NULL, pt],
          b: [wrap, st, b.width, b.height, SETY, b.bottom, LEFT, TOP, NULL, bh, pt],
          tl: [wrap, st, 0, 0, NULL, NULL, RIGHT, BOTTOM, bw, bh, pt],
          bl: [wrap, st, 0, 0, SETY, b.y + b.height, RIGHT, TOP, bw, bh, pt],
          br: [wrap, st, 0, 0, SETXY, [b.right, b.bottom], LEFT, TOP, bw, bh, pt],
          tr: [wrap, st, 0, 0, SETX, b.x + b.width, LEFT, BOTTOM, bw, bh, pt]
        });
        st.visibility = VISIBLE;
        fly(wrap).show();
        arguments.callee.anim = fly(wrap).fxanim(args, o, MOTION, .5, EASEOUT, after);
      });
      return me;
    },

    /**
     * Slides the element out of view.  An anchor point can be optionally passed to set the end point
     * for the slide effect.  When the effect is completed, the element will be hidden (visibility = 
     * 'hidden') but block elements will still take up space in the document.  The element must be removed
     * from the DOM using the 'remove' config option if desired.  This function automatically handles 
     * wrapping the element with a fixed-size container if needed.  See the Fx class overview for valid anchor point options.
     * Usage:
     *<pre><code>
    // default: slide the element out to the top
    el.slideOut();
    // custom: slide the element out to the right with a 2-second duration
    el.slideOut('r', { duration: 2 });
    // common config options shown with default values
    el.slideOut('t', {
    easing: 'easeOut',
    duration: .5,
    remove: false,
    useDisplay: false
    });
    </code></pre>
     * @param {String} anchor (optional) One of the valid Fx anchor positions (defaults to top: 't')
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    slideOut: function slideOut(anchor, o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          st = dom.style,
          xy = me.getXY(),
          wrap,
          r,
          b,
          a,
          zero = {
        to: 0
      };
      anchor = anchor || "t";
      me.queueFx(o, function () {
        // restore values after effect
        r = fly(dom).getFxRestore();
        b = {
          x: xy[0],
          y: xy[1],
          0: xy[0],
          1: xy[1],
          width: dom.offsetWidth,
          height: dom.offsetHeight
        };
        b.right = b.x + b.width;
        b.bottom = b.y + b.height; // fixed size for slide   

        fly(dom).setWidth(b.width).setHeight(b.height); // wrap if needed

        wrap = fly(dom).fxWrap(r.pos, o, VISIBLE);
        st.visibility = VISIBLE;
        st.position = ABSOLUTE;
        fly(wrap).setWidth(b.width).setHeight(b.height);

        function after() {
          o.useDisplay ? fly(dom).setDisplayed(FALSE) : fly(dom).hide();
          fly(dom).fxUnwrap(wrap, r.pos, o);
          st.width = r.width;
          st.height = r.height;
          fly(dom).afterFx(o);
        }

        function argCalc(style, s1, s2, p1, v1, p2, v2, p3, v3) {
          var ret = {};
          style[s1] = style[s2] = "0";
          ret[p1] = v1;

          if (p2) {
            ret[p2] = v2;
          }

          if (p3) {
            ret[p3] = v3;
          }

          return ret;
        }

        ;
        a = fly(dom).switchStatements(anchor.toLowerCase(), argCalc, {
          t: [st, LEFT, BOTTOM, HEIGHT, zero],
          l: [st, RIGHT, TOP, WIDTH, zero],
          r: [st, LEFT, TOP, WIDTH, zero, POINTS, {
            to: [b.right, b.y]
          }],
          b: [st, LEFT, TOP, HEIGHT, zero, POINTS, {
            to: [b.x, b.bottom]
          }],
          tl: [st, RIGHT, BOTTOM, WIDTH, zero, HEIGHT, zero],
          bl: [st, RIGHT, TOP, WIDTH, zero, HEIGHT, zero, POINTS, {
            to: [b.x, b.bottom]
          }],
          br: [st, LEFT, TOP, WIDTH, zero, HEIGHT, zero, POINTS, {
            to: [b.x + b.width, b.bottom]
          }],
          tr: [st, LEFT, BOTTOM, WIDTH, zero, HEIGHT, zero, POINTS, {
            to: [b.right, b.y]
          }]
        });
        arguments.callee.anim = fly(wrap).fxanim(a, o, MOTION, .5, EASEOUT, after);
      });
      return me;
    },

    /**
     * Fades the element out while slowly expanding it in all directions.  When the effect is completed, the 
     * element will be hidden (visibility = 'hidden') but block elements will still take up space in the document. 
     * The element must be removed from the DOM using the 'remove' config option if desired.
     * Usage:
     *<pre><code>
    // default
    el.puff();
    // common config options shown with default values
    el.puff({
    easing: 'easeOut',
    duration: .5,
    remove: false,
    useDisplay: false
    });
    </code></pre>
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    puff: function puff(o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          st = dom.style,
          width,
          height,
          r;
      me.queueFx(o, function () {
        width = fly(dom).getWidth();
        height = fly(dom).getHeight();
        fly(dom).clearOpacity();
        fly(dom).show(); // restore values after effect

        r = fly(dom).getFxRestore();

        function after() {
          o.useDisplay ? fly(dom).setDisplayed(FALSE) : fly(dom).hide();
          fly(dom).clearOpacity();
          fly(dom).setPositioning(r.pos);
          st.width = r.width;
          st.height = r.height;
          st.fontSize = '';
          fly(dom).afterFx(o);
        }

        arguments.callee.anim = fly(dom).fxanim({
          width: {
            to: fly(dom).adjustWidth(width * 2)
          },
          height: {
            to: fly(dom).adjustHeight(height * 2)
          },
          points: {
            by: [-width * .5, -height * .5]
          },
          opacity: {
            to: 0
          },
          fontSize: {
            to: 200,
            unit: "%"
          }
        }, o, MOTION, .5, EASEOUT, after);
      });
      return me;
    },

    /**
     * Blinks the element as if it was clicked and then collapses on its center (similar to switching off a television).
     * When the effect is completed, the element will be hidden (visibility = 'hidden') but block elements will still 
     * take up space in the document. The element must be removed from the DOM using the 'remove' config option if desired.
     * Usage:
     *<pre><code>
    // default
    el.switchOff();
    // all config options shown with default values
    el.switchOff({
    easing: 'easeIn',
    duration: .3,
    remove: false,
    useDisplay: false
    });
    </code></pre>
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    switchOff: function switchOff(o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          st = dom.style,
          r;
      me.queueFx(o, function () {
        fly(dom).clearOpacity();
        fly(dom).clip(); // restore values after effect

        r = fly(dom).getFxRestore();

        function after() {
          o.useDisplay ? fly(dom).setDisplayed(FALSE) : fly(dom).hide();
          fly(dom).clearOpacity();
          fly(dom).setPositioning(r.pos);
          st.width = r.width;
          st.height = r.height;
          fly(dom).afterFx(o);
        }

        ;
        fly(dom).fxanim({
          opacity: {
            to: 0.3
          }
        }, NULL, NULL, .1, NULL, function () {
          fly(dom).clearOpacity();
          (function () {
            fly(dom).fxanim({
              height: {
                to: 1
              },
              points: {
                by: [0, fly(dom).getHeight() * .5]
              }
            }, o, MOTION, 0.3, 'easeIn', after);
          }).defer(100);
        });
      });
      return me;
    },

    /**
     * Highlights the Element by setting a color (applies to the background-color by default, but can be
     * changed using the "attr" config option) and then fading back to the original color. If no original
     * color is available, you should provide the "endColor" config option which will be cleared after the animation.
     * Usage:
    <pre><code>
    // default: highlight background to yellow
    el.highlight();
    // custom: highlight foreground text to blue for 2 seconds
    el.highlight("0000ff", { attr: 'color', duration: 2 });
    // common config options shown with default values
    el.highlight("ffff9c", {
    attr: "background-color", //can be any valid CSS property (attribute) that supports a color value
    endColor: (current color) or "ffffff",
    easing: 'easeIn',
    duration: 1
    });
    </code></pre>
     * @param {String} color (optional) The highlight color. Should be a 6 char hex color without the leading # (defaults to yellow: 'ffff9c')
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    highlight: function highlight(color, o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          attr = o.attr || "backgroundColor",
          a = {},
          restore;
      me.queueFx(o, function () {
        fly(dom).clearOpacity();
        fly(dom).show();

        function after() {
          dom.style[attr] = restore;
          fly(dom).afterFx(o);
        }

        restore = dom.style[attr];
        a[attr] = {
          from: color || "ffff9c",
          to: o.endColor || fly(dom).getColor(attr) || "ffffff"
        };
        arguments.callee.anim = fly(dom).fxanim(a, o, 'color', 1, 'easeIn', after);
      });
      return me;
    },

    /**
     * Shows a ripple of exploding, attenuating borders to draw attention to an Element.
     * Usage:
    <pre><code>
    // default: a single light blue ripple
    el.frame();
    // custom: 3 red ripples lasting 3 seconds total
    el.frame("ff0000", 3, { duration: 3 });
    // common config options shown with default values
    el.frame("C3DAF9", 1, {
     duration: 1 //duration of each individual ripple.
     // Note: Easing is not configurable and will be ignored if included
    });
    </code></pre>
     * @param {String} color (optional) The color of the border.  Should be a 6 char hex color without the leading # (defaults to light blue: 'C3DAF9').
     * @param {Number} count (optional) The number of ripples to display (defaults to 1)
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    frame: function frame(color, count, o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          proxy,
          active;
      me.queueFx(o, function () {
        color = color || '#C3DAF9';

        if (color.length == 6) {
          color = '#' + color;
        }

        count = count || 1;
        fly(dom).show();

        var xy = fly(dom).getXY(),
            b = {
          x: xy[0],
          y: xy[1],
          0: xy[0],
          1: xy[1],
          width: dom.offsetWidth,
          height: dom.offsetHeight
        },
            queue = function queue() {
          proxy = fly(document.body || document.documentElement).createChild({
            style: {
              position: ABSOLUTE,
              'z-index': 35000,
              // yee haw
              border: '0px solid ' + color
            }
          });
          return proxy.queueFx({}, animFn);
        };

        arguments.callee.anim = {
          isAnimated: true,
          stop: function stop() {
            count = 0;
            proxy.stopFx();
          }
        };

        function animFn() {
          var scale = Ext.isBorderBox ? 2 : 1;
          active = proxy.anim({
            top: {
              from: b.y,
              to: b.y - 20
            },
            left: {
              from: b.x,
              to: b.x - 20
            },
            borderWidth: {
              from: 0,
              to: 10
            },
            opacity: {
              from: 1,
              to: 0
            },
            height: {
              from: b.height,
              to: b.height + 20 * scale
            },
            width: {
              from: b.width,
              to: b.width + 20 * scale
            }
          }, {
            duration: o.duration || 1,
            callback: function callback() {
              proxy.remove();
              --count > 0 ? queue() : fly(dom).afterFx(o);
            }
          });
          arguments.callee.anim = {
            isAnimated: true,
            stop: function stop() {
              active.stop();
            }
          };
        }

        ;
        queue();
      });
      return me;
    },

    /**
     * Creates a pause before any subsequent queued effects begin.  If there are
     * no effects queued after the pause it will have no effect.
     * Usage:
    <pre><code>
    el.pause(1);
    </code></pre>
     * @param {Number} seconds The length of time to pause (in seconds)
     * @return {Ext.Element} The Element
     */
    pause: function pause(seconds) {
      var dom = this.dom,
          t;
      this.queueFx({}, function () {
        t = setTimeout(function () {
          fly(dom).afterFx({});
        }, seconds * 1000);
        arguments.callee.anim = {
          isAnimated: true,
          stop: function stop() {
            clearTimeout(t);
            fly(dom).afterFx({});
          }
        };
      });
      return this;
    },

    /**
     * Fade an element in (from transparent to opaque).  The ending opacity can be specified
     * using the <tt>{@link #endOpacity}</tt> config option.
     * Usage:
    <pre><code>
    // default: fade in from opacity 0 to 100%
    el.fadeIn();
    // custom: fade in from opacity 0 to 75% over 2 seconds
    el.fadeIn({ endOpacity: .75, duration: 2});
    // common config options shown with default values
    el.fadeIn({
     endOpacity: 1, //can be any value between 0 and 1 (e.g. .5)
     easing: 'easeOut',
     duration: .5
    });
    </code></pre>
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    fadeIn: function fadeIn(o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          to = o.endOpacity || 1;
      me.queueFx(o, function () {
        fly(dom).setOpacity(0);
        fly(dom).fixDisplay();
        dom.style.visibility = VISIBLE;
        arguments.callee.anim = fly(dom).fxanim({
          opacity: {
            to: to
          }
        }, o, NULL, .5, EASEOUT, function () {
          if (to == 1) {
            fly(dom).clearOpacity();
          }

          fly(dom).afterFx(o);
        });
      });
      return me;
    },

    /**
     * Fade an element out (from opaque to transparent).  The ending opacity can be specified
     * using the <tt>{@link #endOpacity}</tt> config option.  Note that IE may require
     * <tt>{@link #useDisplay}:true</tt> in order to redisplay correctly.
     * Usage:
    <pre><code>
    // default: fade out from the element's current opacity to 0
    el.fadeOut();
    // custom: fade out from the element's current opacity to 25% over 2 seconds
    el.fadeOut({ endOpacity: .25, duration: 2});
    // common config options shown with default values
    el.fadeOut({
     endOpacity: 0, //can be any value between 0 and 1 (e.g. .5)
     easing: 'easeOut',
     duration: .5,
     remove: false,
     useDisplay: false
    });
    </code></pre>
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    fadeOut: function fadeOut(o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          style = dom.style,
          to = o.endOpacity || 0;
      me.queueFx(o, function () {
        arguments.callee.anim = fly(dom).fxanim({
          opacity: {
            to: to
          }
        }, o, NULL, .5, EASEOUT, function () {
          if (to == 0) {
            Ext.Element.data(dom, 'visibilityMode') == Ext.Element.DISPLAY || o.useDisplay ? style.display = "none" : style.visibility = HIDDEN;
            fly(dom).clearOpacity();
          }

          fly(dom).afterFx(o);
        });
      });
      return me;
    },

    /**
     * Animates the transition of an element's dimensions from a starting height/width
     * to an ending height/width.  This method is a convenience implementation of {@link shift}.
     * Usage:
    <pre><code>
    // change height and width to 100x100 pixels
    el.scale(100, 100);
    // common config options shown with default values.  The height and width will default to
    // the element&#39;s existing values if passed as null.
    el.scale(
     [element&#39;s width],
     [element&#39;s height], {
         easing: 'easeOut',
         duration: .35
     }
    );
    </code></pre>
     * @param {Number} width  The new width (pass undefined to keep the original width)
     * @param {Number} height  The new height (pass undefined to keep the original height)
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    scale: function scale(w, h, o) {
      this.shift(Ext.apply({}, o, {
        width: w,
        height: h
      }));
      return this;
    },

    /**
     * Animates the transition of any combination of an element's dimensions, xy position and/or opacity.
     * Any of these properties not specified in the config object will not be changed.  This effect 
     * requires that at least one new dimension, position or opacity setting must be passed in on
     * the config object in order for the function to have any effect.
     * Usage:
    <pre><code>
    // slide the element horizontally to x position 200 while changing the height and opacity
    el.shift({ x: 200, height: 50, opacity: .8 });
    // common config options shown with default values.
    el.shift({
     width: [element&#39;s width],
     height: [element&#39;s height],
     x: [element&#39;s x position],
     y: [element&#39;s y position],
     opacity: [element&#39;s opacity],
     easing: 'easeOut',
     duration: .35
    });
    </code></pre>
     * @param {Object} options  Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    shift: function shift(o) {
      o = getObject(o);
      var dom = this.dom,
          a = {};
      this.queueFx(o, function () {
        for (var prop in o) {
          if (o[prop] != UNDEFINED) {
            a[prop] = {
              to: o[prop]
            };
          }
        }

        a.width ? a.width.to = fly(dom).adjustWidth(o.width) : a;
        a.height ? a.height.to = fly(dom).adjustWidth(o.height) : a;

        if (a.x || a.y || a.xy) {
          a.points = a.xy || {
            to: [a.x ? a.x.to : fly(dom).getX(), a.y ? a.y.to : fly(dom).getY()]
          };
        }

        arguments.callee.anim = fly(dom).fxanim(a, o, MOTION, .35, EASEOUT, function () {
          fly(dom).afterFx(o);
        });
      });
      return this;
    },

    /**
     * Slides the element while fading it out of view.  An anchor point can be optionally passed to set the 
     * ending point of the effect.
     * Usage:
     *<pre><code>
    // default: slide the element downward while fading out
    el.ghost();
    // custom: slide the element out to the right with a 2-second duration
    el.ghost('r', { duration: 2 });
    // common config options shown with default values
    el.ghost('b', {
    easing: 'easeOut',
    duration: .5,
    remove: false,
    useDisplay: false
    });
    </code></pre>
     * @param {String} anchor (optional) One of the valid Fx anchor positions (defaults to bottom: 'b')
     * @param {Object} options (optional) Object literal with any of the Fx config options
     * @return {Ext.Element} The Element
     */
    ghost: function ghost(anchor, o) {
      o = getObject(o);
      var me = this,
          dom = me.dom,
          st = dom.style,
          a = {
        opacity: {
          to: 0
        },
        points: {}
      },
          pt = a.points,
          r,
          w,
          h;
      anchor = anchor || "b";
      me.queueFx(o, function () {
        // restore values after effect
        r = fly(dom).getFxRestore();
        w = fly(dom).getWidth();
        h = fly(dom).getHeight();

        function after() {
          o.useDisplay ? fly(dom).setDisplayed(FALSE) : fly(dom).hide();
          fly(dom).clearOpacity();
          fly(dom).setPositioning(r.pos);
          st.width = r.width;
          st.height = r.height;
          fly(dom).afterFx(o);
        }

        pt.by = fly(dom).switchStatements(anchor.toLowerCase(), function (v1, v2) {
          return [v1, v2];
        }, {
          t: [0, -h],
          l: [-w, 0],
          r: [w, 0],
          b: [0, h],
          tl: [-w, -h],
          bl: [-w, h],
          br: [w, h],
          tr: [w, -h]
        });
        arguments.callee.anim = fly(dom).fxanim(a, o, MOTION, .5, EASEOUT, after);
      });
      return me;
    },

    /**
     * Ensures that all effects queued after syncFx is called on the element are
     * run concurrently.  This is the opposite of {@link #sequenceFx}.
     * @return {Ext.Element} The Element
     */
    syncFx: function syncFx() {
      var me = this;
      me.fxDefaults = Ext.apply(me.fxDefaults || {}, {
        block: FALSE,
        concurrent: TRUE,
        stopFx: FALSE
      });
      return me;
    },

    /**
     * Ensures that all effects queued after sequenceFx is called on the element are
     * run in sequence.  This is the opposite of {@link #syncFx}.
     * @return {Ext.Element} The Element
     */
    sequenceFx: function sequenceFx() {
      var me = this;
      me.fxDefaults = Ext.apply(me.fxDefaults || {}, {
        block: FALSE,
        concurrent: FALSE,
        stopFx: FALSE
      });
      return me;
    },

    /* @private */
    nextFx: function nextFx() {
      var ef = getQueue(this.dom.id)[0];

      if (ef) {
        ef.call(this);
      }
    },

    /**
     * Returns true if the element has any effects actively running or queued, else returns false.
     * @return {Boolean} True if element has active effects, else false
     */
    hasActiveFx: function hasActiveFx() {
      return getQueue(this.dom.id)[0];
    },

    /**
     * Stops any running effects and clears the element's internal effects queue if it contains
     * any additional effects that haven't started yet.
     * @return {Ext.Element} The Element
     */
    stopFx: function stopFx(finish) {
      var me = this,
          id = me.dom.id;

      if (me.hasActiveFx()) {
        var cur = getQueue(id)[0];

        if (cur && cur.anim) {
          if (cur.anim.isAnimated) {
            setQueue(id, [cur]); //clear

            cur.anim.stop(finish !== undefined ? finish : TRUE);
          } else {
            setQueue(id, []);
          }
        }
      }

      return me;
    },

    /* @private */
    beforeFx: function beforeFx(o) {
      if (this.hasActiveFx() && !o.concurrent) {
        if (o.stopFx) {
          this.stopFx();
          return TRUE;
        }

        return FALSE;
      }

      return TRUE;
    },

    /**
     * Returns true if the element is currently blocking so that no other effect can be queued
     * until this effect is finished, else returns false if blocking is not set.  This is commonly
     * used to ensure that an effect initiated by a user action runs to completion prior to the
     * same effect being restarted (e.g., firing only one effect even if the user clicks several times).
     * @return {Boolean} True if blocking, else false
     */
    hasFxBlock: function hasFxBlock() {
      var q = getQueue(this.dom.id);
      return q && q[0] && q[0].block;
    },

    /* @private */
    queueFx: function queueFx(o, fn) {
      var me = fly(this.dom);

      if (!me.hasFxBlock()) {
        Ext.applyIf(o, me.fxDefaults);

        if (!o.concurrent) {
          var run = me.beforeFx(o);
          fn.block = o.block;
          getQueue(me.dom.id).push(fn);

          if (run) {
            me.nextFx();
          }
        } else {
          fn.call(me);
        }
      }

      return me;
    },

    /* @private */
    fxWrap: function fxWrap(pos, o, vis) {
      var dom = this.dom,
          wrap,
          wrapXY;

      if (!o.wrap || !(wrap = Ext.getDom(o.wrap))) {
        if (o.fixPosition) {
          wrapXY = fly(dom).getXY();
        }

        var div = document.createElement("div");
        div.style.visibility = vis;
        wrap = dom.parentNode.insertBefore(div, dom);
        fly(wrap).setPositioning(pos);

        if (fly(wrap).isStyle(POSITION, "static")) {
          fly(wrap).position("relative");
        }

        fly(dom).clearPositioning('auto');
        fly(wrap).clip();
        wrap.appendChild(dom);

        if (wrapXY) {
          fly(wrap).setXY(wrapXY);
        }
      }

      return wrap;
    },

    /* @private */
    fxUnwrap: function fxUnwrap(wrap, pos, o) {
      var dom = this.dom;
      fly(dom).clearPositioning();
      fly(dom).setPositioning(pos);

      if (!o.wrap) {
        var pn = fly(wrap).dom.parentNode;
        pn.insertBefore(dom, wrap);
        fly(wrap).remove();
      }
    },

    /* @private */
    getFxRestore: function getFxRestore() {
      var st = this.dom.style;
      return {
        pos: this.getPositioning(),
        width: st.width,
        height: st.height
      };
    },

    /* @private */
    afterFx: function afterFx(o) {
      var dom = this.dom,
          id = dom.id;

      if (o.afterStyle) {
        fly(dom).setStyle(o.afterStyle);
      }

      if (o.afterCls) {
        fly(dom).addClass(o.afterCls);
      }

      if (o.remove == TRUE) {
        fly(dom).remove();
      }

      if (o.callback) {
        o.callback.call(o.scope, fly(dom));
      }

      if (!o.concurrent) {
        getQueue(id).shift();
        fly(dom).nextFx();
      }
    },

    /* @private */
    fxanim: function fxanim(args, opt, animType, defaultDur, defaultEase, cb) {
      animType = animType || 'run';
      opt = opt || {};
      var anim = Ext.lib.Anim[animType](this.dom, args, opt.duration || defaultDur || .35, opt.easing || defaultEase || EASEOUT, cb, this);
      opt.anim = anim;
      return anim;
    }
  }; // backwards compat

  Ext.Fx.resize = Ext.Fx.scale; //When included, Ext.Fx is automatically applied to Element so that all basic
  //effects are available directly via the Element API

  Ext.Element.addMethods(Ext.Fx);
})();

/***/ }),
/* 733 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.CompositeElementLite
 * <p>This class encapsulates a <i>collection</i> of DOM elements, providing methods to filter
 * members, or to perform collective actions upon the whole set.</p>
 * <p>Although they are not listed, this class supports all of the methods of {@link Ext.Element} and
 * {@link Ext.Fx}. The methods from these classes will be performed on all the elements in this collection.</p>
 * Example:<pre><code>
var els = Ext.select("#some-el div.some-class");
// or select directly from an existing element
var el = Ext.get('some-el');
el.select('div.some-class');

els.setWidth(100); // all elements become 100 width
els.hide(true); // all elements fade out and hide
// or
els.setWidth(100).hide(true);
</code>
 */
Ext.CompositeElementLite = function (els, root) {
  /**
   * <p>The Array of DOM elements which this CompositeElement encapsulates. Read-only.</p>
   * <p>This will not <i>usually</i> be accessed in developers' code, but developers wishing
   * to augment the capabilities of the CompositeElementLite class may use it when adding
   * methods to the class.</p>
   * <p>For example to add the <code>nextAll</code> method to the class to <b>add</b> all
   * following siblings of selected elements, the code would be</p><code><pre>
  Ext.override(Ext.CompositeElementLite, {
  nextAll: function() {
      var els = this.elements, i, l = els.length, n, r = [], ri = -1;
  //      Loop through all elements in this Composite, accumulating
  //      an Array of all siblings.
      for (i = 0; i < l; i++) {
          for (n = els[i].nextSibling; n; n = n.nextSibling) {
              r[++ri] = n;
          }
      }
  //      Add all found siblings to this Composite
      return this.add(r);
  }
  });</pre></code>
   * @type Array
   * @property elements
   */
  this.elements = [];
  this.add(els, root);
  this.el = new Ext.Element.Flyweight();
};

Ext.CompositeElementLite.prototype = {
  isComposite: true,
  // private
  getElement: function getElement(el) {
    // Set the shared flyweight dom property to the current element
    var e = this.el;
    e.dom = el;
    e.id = el.id;
    return e;
  },
  // private
  transformElement: function transformElement(el) {
    return Ext.getDom(el);
  },

  /**
   * Returns the number of elements in this Composite.
   * @return Number
   */
  getCount: function getCount() {
    return this.elements.length;
  },

  /**
   * Adds elements to this Composite object.
   * @param {Mixed} els Either an Array of DOM elements to add, or another Composite object who's elements should be added.
   * @return {CompositeElement} This Composite object.
   */
  add: function add(els, root) {
    var me = this,
        elements = me.elements;

    if (!els) {
      return this;
    }

    if (Ext.isString(els)) {
      els = Ext.Element.selectorFunction(els, root);
    } else if (els.isComposite) {
      els = els.elements;
    } else if (!Ext.isIterable(els)) {
      els = [els];
    }

    for (var i = 0, len = els.length; i < len; ++i) {
      elements.push(me.transformElement(els[i]));
    }

    return me;
  },
  invoke: function invoke(fn, args) {
    var me = this,
        els = me.elements,
        len = els.length,
        e,
        i;

    for (i = 0; i < len; i++) {
      e = els[i];

      if (e) {
        Ext.Element.prototype[fn].apply(me.getElement(e), args);
      }
    }

    return me;
  },

  /**
   * Returns a flyweight Element of the dom element object at the specified index
   * @param {Number} index
   * @return {Ext.Element}
   */
  item: function item(index) {
    var me = this,
        el = me.elements[index],
        out = null;

    if (el) {
      out = me.getElement(el);
    }

    return out;
  },
  // fixes scope with flyweight
  addListener: function addListener(eventName, handler, scope, opt) {
    var els = this.elements,
        len = els.length,
        i,
        e;

    for (i = 0; i < len; i++) {
      e = els[i];

      if (e) {
        Ext.EventManager.on(e, eventName, handler, scope || e, opt);
      }
    }

    return this;
  },

  /**
   * <p>Calls the passed function for each element in this composite.</p>
   * @param {Function} fn The function to call. The function is passed the following parameters:<ul>
   * <li><b>el</b> : Element<div class="sub-desc">The current Element in the iteration.
   * <b>This is the flyweight (shared) Ext.Element instance, so if you require a
   * a reference to the dom node, use el.dom.</b></div></li>
   * <li><b>c</b> : Composite<div class="sub-desc">This Composite object.</div></li>
   * <li><b>idx</b> : Number<div class="sub-desc">The zero-based index in the iteration.</div></li>
   * </ul>
   * @param {Object} scope (optional) The scope (<i>this</i> reference) in which the function is executed. (defaults to the Element)
   * @return {CompositeElement} this
   */
  each: function each(fn, scope) {
    var me = this,
        els = me.elements,
        len = els.length,
        i,
        e;

    for (i = 0; i < len; i++) {
      e = els[i];

      if (e) {
        e = this.getElement(e);

        if (fn.call(scope || e, e, me, i) === false) {
          break;
        }
      }
    }

    return me;
  },

  /**
  * Clears this Composite and adds the elements passed.
  * @param {Mixed} els Either an array of DOM elements, or another Composite from which to fill this Composite.
  * @return {CompositeElement} this
  */
  fill: function fill(els) {
    var me = this;
    me.elements = [];
    me.add(els);
    return me;
  },

  /**
   * Filters this composite to only elements that match the passed selector.
   * @param {String/Function} selector A string CSS selector or a comparison function.
   * The comparison function will be called with the following arguments:<ul>
   * <li><code>el</code> : Ext.Element<div class="sub-desc">The current DOM element.</div></li>
   * <li><code>index</code> : Number<div class="sub-desc">The current index within the collection.</div></li>
   * </ul>
   * @return {CompositeElement} this
   */
  filter: function filter(selector) {
    var els = [],
        me = this,
        elements = me.elements,
        fn = Ext.isFunction(selector) ? selector : function (el) {
      return el.is(selector);
    };
    me.each(function (el, self, i) {
      if (fn(el, i) !== false) {
        els[els.length] = me.transformElement(el);
      }
    });
    me.elements = els;
    return me;
  },

  /**
   * Find the index of the passed element within the composite collection.
   * @param el {Mixed} The id of an element, or an Ext.Element, or an HtmlElement to find within the composite collection.
   * @return Number The index of the passed Ext.Element in the composite collection, or -1 if not found.
   */
  indexOf: function indexOf(el) {
    return this.elements.indexOf(this.transformElement(el));
  },

  /**
  * Replaces the specified element with the passed element.
  * @param {Mixed} el The id of an element, the Element itself, the index of the element in this composite
  * to replace.
  * @param {Mixed} replacement The id of an element or the Element itself.
  * @param {Boolean} domReplace (Optional) True to remove and replace the element in the document too.
  * @return {CompositeElement} this
  */
  replaceElement: function replaceElement(el, replacement, domReplace) {
    var index = !isNaN(el) ? el : this.indexOf(el),
        d;

    if (index > -1) {
      replacement = Ext.getDom(replacement);

      if (domReplace) {
        d = this.elements[index];
        d.parentNode.insertBefore(replacement, d);
        Ext.removeNode(d);
      }

      this.elements.splice(index, 1, replacement);
    }

    return this;
  },

  /**
   * Removes all elements.
   */
  clear: function clear() {
    this.elements = [];
  }
};
Ext.CompositeElementLite.prototype.on = Ext.CompositeElementLite.prototype.addListener;

(function () {
  var fnName,
      ElProto = Ext.Element.prototype,
      CelProto = Ext.CompositeElementLite.prototype;

  for (fnName in ElProto) {
    if (Ext.isFunction(ElProto[fnName])) {
      (function (fnName) {
        CelProto[fnName] = CelProto[fnName] || function () {
          return this.invoke(fnName, arguments);
        };
      }).call(CelProto, fnName);
    }
  }
})();

if (Ext.DomQuery) {
  Ext.Element.selectorFunction = Ext.DomQuery.select;
}
/**
 * Selects elements based on the passed CSS selector to enable {@link Ext.Element Element} methods
 * to be applied to many related elements in one statement through the returned {@link Ext.CompositeElement CompositeElement} or
 * {@link Ext.CompositeElementLite CompositeElementLite} object.
 * @param {String/Array} selector The CSS selector or an array of elements
 * @param {HTMLElement/String} root (optional) The root element of the query or id of the root
 * @return {CompositeElementLite/CompositeElement}
 * @member Ext.Element
 * @method select
 */


Ext.Element.select = function (selector, root) {
  var els;

  if (typeof selector == "string") {
    els = Ext.Element.selectorFunction(selector, root);
  } else if (selector.length !== undefined) {
    els = selector;
  } else {
    throw "Invalid selector";
  }

  return new Ext.CompositeElementLite(els);
};
/**
 * Selects elements based on the passed CSS selector to enable {@link Ext.Element Element} methods
 * to be applied to many related elements in one statement through the returned {@link Ext.CompositeElement CompositeElement} or
 * {@link Ext.CompositeElementLite CompositeElementLite} object.
 * @param {String/Array} selector The CSS selector or an array of elements
 * @param {HTMLElement/String} root (optional) The root element of the query or id of the root
 * @return {CompositeElementLite/CompositeElement}
 * @member Ext
 * @method select
 */


Ext.select = Ext.Element.select;

/***/ }),
/* 734 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.CompositeElementLite
 */
Ext.apply(Ext.CompositeElementLite.prototype, {
  addElements: function addElements(els, root) {
    if (!els) {
      return this;
    }

    if (typeof els == "string") {
      els = Ext.Element.selectorFunction(els, root);
    }

    var yels = this.elements;
    Ext.each(els, function (e) {
      yels.push(Ext.get(e));
    });
    return this;
  },

  /**
   * Returns the first Element
   * @return {Ext.Element}
   */
  first: function first() {
    return this.item(0);
  },

  /**
   * Returns the last Element
   * @return {Ext.Element}
   */
  last: function last() {
    return this.item(this.getCount() - 1);
  },

  /**
   * Returns true if this composite contains the passed element
   * @param el {Mixed} The id of an element, or an Ext.Element, or an HtmlElement to find within the composite collection.
   * @return Boolean
   */
  contains: function contains(el) {
    return this.indexOf(el) != -1;
  },

  /**
  * Removes the specified element(s).
  * @param {Mixed} el The id of an element, the Element itself, the index of the element in this composite
  * or an array of any of those.
  * @param {Boolean} removeDom (optional) True to also remove the element from the document
  * @return {CompositeElement} this
  */
  removeElement: function removeElement(keys, removeDom) {
    var me = this,
        els = this.elements,
        el;
    Ext.each(keys, function (val) {
      if (el = els[val] || els[val = me.indexOf(val)]) {
        if (removeDom) {
          if (el.dom) {
            el.remove();
          } else {
            Ext.removeNode(el);
          }
        }

        els.splice(val, 1);
      }
    });
    return this;
  }
});

/***/ }),
/* 735 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.CompositeElement
 * @extends Ext.CompositeElementLite
 * <p>This class encapsulates a <i>collection</i> of DOM elements, providing methods to filter
 * members, or to perform collective actions upon the whole set.</p>
 * <p>Although they are not listed, this class supports all of the methods of {@link Ext.Element} and
 * {@link Ext.Fx}. The methods from these classes will be performed on all the elements in this collection.</p>
 * <p>All methods return <i>this</i> and can be chained.</p>
 * Usage:
<pre><code>
var els = Ext.select("#some-el div.some-class", true);
// or select directly from an existing element
var el = Ext.get('some-el');
el.select('div.some-class', true);

els.setWidth(100); // all elements become 100 width
els.hide(true); // all elements fade out and hide
// or
els.setWidth(100).hide(true);
</code></pre>
 */
Ext.CompositeElement = function (els, root) {
  this.elements = [];
  this.add(els, root);
};

Ext.extend(Ext.CompositeElement, Ext.CompositeElementLite, {
  // private
  getElement: function getElement(el) {
    // In this case just return it, since we already have a reference to it
    return el;
  },
  // private
  transformElement: function transformElement(el) {
    return Ext.get(el);
  }
  /**
  * Adds elements to this composite.
  * @param {String/Array} els A string CSS selector, an array of elements or an element
  * @return {CompositeElement} this
  */

  /**
   * Returns the Element object at the specified index
   * @param {Number} index
   * @return {Ext.Element}
   */

  /**
   * Iterates each <code>element</code> in this <code>composite</code>
   * calling the supplied function using {@link Ext#each}.
   * @param {Function} fn The function to be called with each
   * <code>element</code>. If the supplied function returns <tt>false</tt>,
   * iteration stops. This function is called with the following arguments:
   * <div class="mdetail-params"><ul>
   * <li><code>element</code> : <i>Ext.Element</i><div class="sub-desc">The element at the current <code>index</code>
   * in the <code>composite</code></div></li>
   * <li><code>composite</code> : <i>Object</i> <div class="sub-desc">This composite.</div></li>
   * <li><code>index</code> : <i>Number</i> <div class="sub-desc">The current index within the <code>composite</code> </div></li>
   * </ul></div>
   * @param {Object} scope (optional) The scope (<code><this</code> reference) in which the specified function is executed.
   * Defaults to the <code>element</code> at the current <code>index</code>
   * within the composite.
   * @return {CompositeElement} this
   */

});
/**
 * Selects elements based on the passed CSS selector to enable {@link Ext.Element Element} methods
 * to be applied to many related elements in one statement through the returned {@link Ext.CompositeElement CompositeElement} or
 * {@link Ext.CompositeElementLite CompositeElementLite} object.
 * @param {String/Array} selector The CSS selector or an array of elements
 * @param {Boolean} unique (optional) true to create a unique Ext.Element for each element (defaults to a shared flyweight object)
 * @param {HTMLElement/String} root (optional) The root element of the query or id of the root
 * @return {CompositeElementLite/CompositeElement}
 * @member Ext.Element
 * @method select
 */

Ext.Element.select = function (selector, unique, root) {
  var els;

  if (typeof selector == "string") {
    els = Ext.Element.selectorFunction(selector, root);
  } else if (selector.length !== undefined) {
    els = selector;
  } else {
    throw "Invalid selector";
  }

  return unique === true ? new Ext.CompositeElement(els) : new Ext.CompositeElementLite(els);
};
/**
 * Selects elements based on the passed CSS selector to enable {@link Ext.Element Element} methods
 * to be applied to many related elements in one statement through the returned {@link Ext.CompositeElement CompositeElement} or
 * {@link Ext.CompositeElementLite CompositeElementLite} object.
 * @param {String/Array} selector The CSS selector or an array of elements
 * @param {Boolean} unique (optional) true to create a unique Ext.Element for each element (defaults to a shared flyweight object)
 * @param {HTMLElement/String} root (optional) The root element of the query or id of the root
 * @return {CompositeElementLite/CompositeElement}
 * @member Ext.Element
 * @method select
 */


Ext.select = Ext.Element.select;

/***/ }),
/* 736 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
(function () {
  var BEFOREREQUEST = "beforerequest",
      REQUESTCOMPLETE = "requestcomplete",
      REQUESTEXCEPTION = "requestexception",
      UNDEFINED = undefined,
      LOAD = 'load',
      POST = 'POST',
      GET = 'GET',
      WINDOW = window;
  /**
   * @class Ext.data.Connection
   * @extends Ext.util.Observable
   * <p>The class encapsulates a connection to the page's originating domain, allowing requests to be made
   * either to a configured URL, or to a URL specified at request time.</p>
   * <p>Requests made by this class are asynchronous, and will return immediately. No data from
   * the server will be available to the statement immediately following the {@link #request} call.
   * To process returned data, use a
   * <a href="#request-option-success" ext:member="request-option-success" ext:cls="Ext.data.Connection">success callback</a>
   * in the request options object,
   * or an {@link #requestcomplete event listener}.</p>
   * <p><h3>File Uploads</h3><a href="#request-option-isUpload" ext:member="request-option-isUpload" ext:cls="Ext.data.Connection">File uploads</a> are not performed using normal "Ajax" techniques, that
   * is they are <b>not</b> performed using XMLHttpRequests. Instead the form is submitted in the standard
   * manner with the DOM <tt>&lt;form></tt> element temporarily modified to have its
   * <a href="http://www.w3.org/TR/REC-html40/present/frames.html#adef-target">target</a> set to refer
   * to a dynamically generated, hidden <tt>&lt;iframe></tt> which is inserted into the document
   * but removed after the return data has been gathered.</p>
   * <p>The server response is parsed by the browser to create the document for the IFRAME. If the
   * server is using JSON to send the return object, then the
   * <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.17">Content-Type</a> header
   * must be set to "text/html" in order to tell the browser to insert the text unchanged into the document body.</p>
   * <p>Characters which are significant to an HTML parser must be sent as HTML entities, so encode
   * "&lt;" as "&amp;lt;", "&amp;" as "&amp;amp;" etc.</p>
   * <p>The response text is retrieved from the document, and a fake XMLHttpRequest object
   * is created containing a <tt>responseText</tt> property in order to conform to the
   * requirements of event handlers and callbacks.</p>
   * <p>Be aware that file upload packets are sent with the content type <a href="http://www.faqs.org/rfcs/rfc2388.html">multipart/form</a>
   * and some server technologies (notably JEE) may require some custom processing in order to
   * retrieve parameter names and parameter values from the packet content.</p>
   * @constructor
   * @param {Object} config a configuration object.
   */

  Ext.data.Connection = function (config) {
    Ext.apply(this, config);
    this.addEvents(
    /**
     * @event beforerequest
     * Fires before a network request is made to retrieve a data object.
     * @param {Connection} conn This Connection object.
     * @param {Object} options The options config object passed to the {@link #request} method.
     */
    BEFOREREQUEST,
    /**
     * @event requestcomplete
     * Fires if the request was successfully completed.
     * @param {Connection} conn This Connection object.
     * @param {Object} response The XHR object containing the response data.
     * See <a href="http://www.w3.org/TR/XMLHttpRequest/">The XMLHttpRequest Object</a>
     * for details.
     * @param {Object} options The options config object passed to the {@link #request} method.
     */
    REQUESTCOMPLETE,
    /**
     * @event requestexception
     * Fires if an error HTTP status was returned from the server.
     * See <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html">HTTP Status Code Definitions</a>
     * for details of HTTP status codes.
     * @param {Connection} conn This Connection object.
     * @param {Object} response The XHR object containing the response data.
     * See <a href="http://www.w3.org/TR/XMLHttpRequest/">The XMLHttpRequest Object</a>
     * for details.
     * @param {Object} options The options config object passed to the {@link #request} method.
     */
    REQUESTEXCEPTION);
    Ext.data.Connection.superclass.constructor.call(this);
  };

  Ext.extend(Ext.data.Connection, Ext.util.Observable, {
    /**
     * @cfg {String} url (Optional) <p>The default URL to be used for requests to the server. Defaults to undefined.</p>
     * <p>The <code>url</code> config may be a function which <i>returns</i> the URL to use for the Ajax request. The scope
     * (<code><b>this</b></code> reference) of the function is the <code>scope</code> option passed to the {@link #request} method.</p>
     */

    /**
     * @cfg {Object} extraParams (Optional) An object containing properties which are used as
     * extra parameters to each request made by this object. (defaults to undefined)
     */

    /**
     * @cfg {Object} defaultHeaders (Optional) An object containing request headers which are added
     *  to each request made by this object. (defaults to undefined)
     */

    /**
     * @cfg {String} method (Optional) The default HTTP method to be used for requests.
     * (defaults to undefined; if not set, but {@link #request} params are present, POST will be used;
     * otherwise, GET will be used.)
     */

    /**
     * @cfg {Number} timeout (Optional) The timeout in milliseconds to be used for requests. (defaults to 30000)
     */
    timeout: 30000,

    /**
     * @cfg {Boolean} autoAbort (Optional) Whether this request should abort any pending requests. (defaults to false)
     * @type Boolean
     */
    autoAbort: false,

    /**
     * @cfg {Boolean} disableCaching (Optional) True to add a unique cache-buster param to GET requests. (defaults to true)
     * @type Boolean
     */
    disableCaching: true,

    /**
     * @cfg {String} disableCachingParam (Optional) Change the parameter which is sent went disabling caching
     * through a cache buster. Defaults to '_dc'
     * @type String
     */
    disableCachingParam: '_dc',

    /**
     * <p>Sends an HTTP request to a remote server.</p>
     * <p><b>Important:</b> Ajax server requests are asynchronous, and this call will
     * return before the response has been received. Process any returned data
     * in a callback function.</p>
     * <pre><code>
    Ext.Ajax.request({
    url: 'ajax_demo/sample.json',
    success: function(response, opts) {
    var obj = Ext.decode(response.responseText);
    console.dir(obj);
    },
    failure: function(response, opts) {
    console.log('server-side failure with status code ' + response.status);
    }
    });
     * </code></pre>
     * <p>To execute a callback function in the correct scope, use the <tt>scope</tt> option.</p>
     * @param {Object} options An object which may contain the following properties:<ul>
     * <li><b>url</b> : String/Function (Optional)<div class="sub-desc">The URL to
     * which to send the request, or a function to call which returns a URL string. The scope of the
     * function is specified by the <tt>scope</tt> option. Defaults to the configured
     * <tt>{@link #url}</tt>.</div></li>
     * <li><b>params</b> : Object/String/Function (Optional)<div class="sub-desc">
     * An object containing properties which are used as parameters to the
     * request, a url encoded string or a function to call to get either. The scope of the function
     * is specified by the <tt>scope</tt> option.</div></li>
     * <li><b>method</b> : String (Optional)<div class="sub-desc">The HTTP method to use
     * for the request. Defaults to the configured method, or if no method was configured,
     * "GET" if no parameters are being sent, and "POST" if parameters are being sent.  Note that
     * the method name is case-sensitive and should be all caps.</div></li>
     * <li><b>callback</b> : Function (Optional)<div class="sub-desc">The
     * function to be called upon receipt of the HTTP response. The callback is
     * called regardless of success or failure and is passed the following
     * parameters:<ul>
     * <li><b>options</b> : Object<div class="sub-desc">The parameter to the request call.</div></li>
     * <li><b>success</b> : Boolean<div class="sub-desc">True if the request succeeded.</div></li>
     * <li><b>response</b> : Object<div class="sub-desc">The XMLHttpRequest object containing the response data.
     * See <a href="http://www.w3.org/TR/XMLHttpRequest/">http://www.w3.org/TR/XMLHttpRequest/</a> for details about
     * accessing elements of the response.</div></li>
     * </ul></div></li>
     * <li><a id="request-option-success"></a><b>success</b> : Function (Optional)<div class="sub-desc">The function
     * to be called upon success of the request. The callback is passed the following
     * parameters:<ul>
     * <li><b>response</b> : Object<div class="sub-desc">The XMLHttpRequest object containing the response data.</div></li>
     * <li><b>options</b> : Object<div class="sub-desc">The parameter to the request call.</div></li>
     * </ul></div></li>
     * <li><b>failure</b> : Function (Optional)<div class="sub-desc">The function
     * to be called upon failure of the request. The callback is passed the
     * following parameters:<ul>
     * <li><b>response</b> : Object<div class="sub-desc">The XMLHttpRequest object containing the response data.</div></li>
     * <li><b>options</b> : Object<div class="sub-desc">The parameter to the request call.</div></li>
     * </ul></div></li>
     * <li><b>scope</b> : Object (Optional)<div class="sub-desc">The scope in
     * which to execute the callbacks: The "this" object for the callback function. If the <tt>url</tt>, or <tt>params</tt> options were
     * specified as functions from which to draw values, then this also serves as the scope for those function calls.
     * Defaults to the browser window.</div></li>
     * <li><b>timeout</b> : Number (Optional)<div class="sub-desc">The timeout in milliseconds to be used for this request. Defaults to 30 seconds.</div></li>
     * <li><b>form</b> : Element/HTMLElement/String (Optional)<div class="sub-desc">The <tt>&lt;form&gt;</tt>
     * Element or the id of the <tt>&lt;form&gt;</tt> to pull parameters from.</div></li>
     * <li><a id="request-option-isUpload"></a><b>isUpload</b> : Boolean (Optional)<div class="sub-desc"><b>Only meaningful when used
     * with the <tt>form</tt> option</b>.
     * <p>True if the form object is a file upload (will be set automatically if the form was
     * configured with <b><tt>enctype</tt></b> "multipart/form-data").</p>
     * <p>File uploads are not performed using normal "Ajax" techniques, that is they are <b>not</b>
     * performed using XMLHttpRequests. Instead the form is submitted in the standard manner with the
     * DOM <tt>&lt;form></tt> element temporarily modified to have its
     * <a href="http://www.w3.org/TR/REC-html40/present/frames.html#adef-target">target</a> set to refer
     * to a dynamically generated, hidden <tt>&lt;iframe></tt> which is inserted into the document
     * but removed after the return data has been gathered.</p>
     * <p>The server response is parsed by the browser to create the document for the IFRAME. If the
     * server is using JSON to send the return object, then the
     * <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.17">Content-Type</a> header
     * must be set to "text/html" in order to tell the browser to insert the text unchanged into the document body.</p>
     * <p>The response text is retrieved from the document, and a fake XMLHttpRequest object
     * is created containing a <tt>responseText</tt> property in order to conform to the
     * requirements of event handlers and callbacks.</p>
     * <p>Be aware that file upload packets are sent with the content type <a href="http://www.faqs.org/rfcs/rfc2388.html">multipart/form</a>
     * and some server technologies (notably JEE) may require some custom processing in order to
     * retrieve parameter names and parameter values from the packet content.</p>
     * </div></li>
     * <li><b>headers</b> : Object (Optional)<div class="sub-desc">Request
     * headers to set for the request.</div></li>
     * <li><b>xmlData</b> : Object (Optional)<div class="sub-desc">XML document
     * to use for the post. Note: This will be used instead of params for the post
     * data. Any params will be appended to the URL.</div></li>
     * <li><b>jsonData</b> : Object/String (Optional)<div class="sub-desc">JSON
     * data to use as the post. Note: This will be used instead of params for the post
     * data. Any params will be appended to the URL.</div></li>
     * <li><b>disableCaching</b> : Boolean (Optional)<div class="sub-desc">True
     * to add a unique cache-buster param to GET requests.</div></li>
     * </ul></p>
     * <p>The options object may also contain any other property which might be needed to perform
     * postprocessing in a callback because it is passed to callback functions.</p>
     * @return {Number} transactionId The id of the server transaction. This may be used
     * to cancel the request.
     */
    request: function request(o) {
      var me = this;

      if (me.fireEvent(BEFOREREQUEST, me, o)) {
        if (o.el) {
          if (!Ext.isEmpty(o.indicatorText)) {
            me.indicatorText = '<div class="loading-indicator">' + o.indicatorText + "</div>";
          }

          if (me.indicatorText) {
            Ext.getDom(o.el).innerHTML = me.indicatorText;
          }

          o.success = (Ext.isFunction(o.success) ? o.success : function () {}).createInterceptor(function (response) {
            Ext.getDom(o.el).innerHTML = response.responseText;
          });
        }

        var p = o.params,
            url = o.url || me.url,
            method,
            cb = {
          success: me.handleResponse,
          failure: me.handleFailure,
          scope: me,
          argument: {
            options: o
          },
          timeout: o.timeout || me.timeout
        },
            form,
            serForm;

        if (Ext.isFunction(p)) {
          p = p.call(o.scope || WINDOW, o);
        }

        p = Ext.urlEncode(me.extraParams, Ext.isObject(p) ? Ext.urlEncode(p) : p);

        if (Ext.isFunction(url)) {
          url = url.call(o.scope || WINDOW, o);
        }

        if (form = Ext.getDom(o.form)) {
          url = url || form.action;

          if (o.isUpload || /multipart\/form-data/i.test(form.getAttribute("enctype"))) {
            return me.doFormUpload.call(me, o, p, url);
          }

          serForm = Ext.lib.Ajax.serializeForm(form);
          p = p ? p + '&' + serForm : serForm;
        }

        method = o.method || me.method || (p || o.xmlData || o.jsonData ? POST : GET);

        if (method === GET && me.disableCaching && o.disableCaching !== false || o.disableCaching === true) {
          var dcp = o.disableCachingParam || me.disableCachingParam;
          url = Ext.urlAppend(url, dcp + '=' + new Date().getTime());
        }

        o.headers = Ext.apply(o.headers || {}, me.defaultHeaders || {});

        if (o.autoAbort === true || me.autoAbort) {
          me.abort();
        }

        if ((method == GET || o.xmlData || o.jsonData) && p) {
          url = Ext.urlAppend(url, p);
          p = '';
        }

        return me.transId = Ext.lib.Ajax.request(method, url, cb, p, o);
      } else {
        return o.callback ? o.callback.apply(o.scope, [o, UNDEFINED, UNDEFINED]) : null;
      }
    },

    /**
     * Determine whether this object has a request outstanding.
     * @param {Number} transactionId (Optional) defaults to the last transaction
     * @return {Boolean} True if there is an outstanding request.
     */
    isLoading: function isLoading(transId) {
      return transId ? Ext.lib.Ajax.isCallInProgress(transId) : !!this.transId;
    },

    /**
     * Aborts any outstanding request.
     * @param {Number} transactionId (Optional) defaults to the last transaction
     */
    abort: function abort(transId) {
      if (transId || this.isLoading()) {
        Ext.lib.Ajax.abort(transId || this.transId);
      }
    },
    // private
    handleResponse: function handleResponse(response) {
      this.transId = false;
      var options = response.argument.options;
      response.argument = options ? options.argument : null;
      this.fireEvent(REQUESTCOMPLETE, this, response, options);

      if (options.success) {
        options.success.call(options.scope, response, options);
      }

      if (options.callback) {
        options.callback.call(options.scope, options, true, response);
      }
    },
    // private
    handleFailure: function handleFailure(response, e) {
      this.transId = false;
      var options = response.argument.options;
      response.argument = options ? options.argument : null;
      this.fireEvent(REQUESTEXCEPTION, this, response, options, e);

      if (options.failure) {
        options.failure.call(options.scope, response, options);
      }

      if (options.callback) {
        options.callback.call(options.scope, options, false, response);
      }
    },
    // private
    doFormUpload: function doFormUpload(o, ps, url) {
      var id = Ext.id(),
          doc = document,
          frame = doc.createElement('iframe'),
          form = Ext.getDom(o.form),
          hiddens = [],
          hd,
          encoding = 'multipart/form-data',
          buf = {
        target: form.target,
        method: form.method,
        encoding: form.encoding,
        enctype: form.enctype,
        action: form.action
      };
      Ext.fly(frame).set({
        id: id,
        name: id,
        cls: 'x-hidden'
      });
      doc.body.appendChild(frame); //Reset the Frame to neutral domain

      Ext.fly(frame).set({
        src: Ext.SSL_SECURE_URL
      }); // This is required so that IE doesn't pop the response up in a new window.

      if (Ext.isIE) {
        document.frames[id].name = id;
      }

      Ext.fly(form).set({
        target: id,
        method: POST,
        enctype: encoding,
        encoding: encoding,
        action: url || buf.action
      }); // add dynamic params

      Ext.iterate(Ext.urlDecode(ps, false), function (k, v) {
        hd = doc.createElement('input');
        Ext.fly(hd).set({
          type: 'hidden',
          value: v,
          name: k
        });
        form.appendChild(hd);
        hiddens.push(hd);
      });

      function cb() {
        var me = this,
            // bogus response object
        r = {
          responseText: '',
          responseXML: null,
          argument: o.argument
        },
            doc,
            firstChild;

        try {
          doc = frame.contentWindow.document || frame.contentDocument || WINDOW.frames[id].document;

          if (doc) {
            if (doc.body) {
              if (/textarea/i.test((firstChild = doc.body.firstChild || {}).tagName)) {
                // json response wrapped in textarea
                r.responseText = firstChild.value;
              } else {
                r.responseText = doc.body.innerHTML;
              }
            } //in IE the document may still have a body even if returns XML.


            r.responseXML = doc.XMLDocument || doc;
          }
        } catch (e) {}

        Ext.EventManager.removeListener(frame, LOAD, cb, me);
        me.fireEvent(REQUESTCOMPLETE, me, r, o);

        function runCallback(fn, scope, args) {
          if (Ext.isFunction(fn)) {
            fn.apply(scope, args);
          }
        }

        runCallback(o.success, o.scope, [r, o]);
        runCallback(o.callback, o.scope, [o, true, r]);

        if (!me.debugUploads) {
          setTimeout(function () {
            Ext.removeNode(frame);
          }, 100);
        }
      }

      Ext.EventManager.on(frame, LOAD, cb, this);
      form.submit();
      Ext.fly(form).set(buf);
      Ext.each(hiddens, function (h) {
        Ext.removeNode(h);
      });
    }
  });
})();
/**
 * @class Ext.Ajax
 * @extends Ext.data.Connection
 * <p>The global Ajax request class that provides a simple way to make Ajax requests
 * with maximum flexibility.</p>
 * <p>Since Ext.Ajax is a singleton, you can set common properties/events for it once
 * and override them at the request function level only if necessary.</p>
 * <p>Common <b>Properties</b> you may want to set are:<div class="mdetail-params"><ul>
 * <li><b><tt>{@link #method}</tt></b><p class="sub-desc"></p></li>
 * <li><b><tt>{@link #extraParams}</tt></b><p class="sub-desc"></p></li>
 * <li><b><tt>{@link #url}</tt></b><p class="sub-desc"></p></li>
 * </ul></div>
 * <pre><code>
// Default headers to pass in every request
Ext.Ajax.defaultHeaders = {
    'Powered-By': 'Ext'
};
 * </code></pre>
 * </p>
 * <p>Common <b>Events</b> you may want to set are:<div class="mdetail-params"><ul>
 * <li><b><tt>{@link Ext.data.Connection#beforerequest beforerequest}</tt></b><p class="sub-desc"></p></li>
 * <li><b><tt>{@link Ext.data.Connection#requestcomplete requestcomplete}</tt></b><p class="sub-desc"></p></li>
 * <li><b><tt>{@link Ext.data.Connection#requestexception requestexception}</tt></b><p class="sub-desc"></p></li>
 * </ul></div>
 * <pre><code>
// Example: show a spinner during all Ajax requests
Ext.Ajax.on('beforerequest', this.showSpinner, this);
Ext.Ajax.on('requestcomplete', this.hideSpinner, this);
Ext.Ajax.on('requestexception', this.hideSpinner, this);
 * </code></pre>
 * </p>
 * <p>An example request:</p>
 * <pre><code>
// Basic request
Ext.Ajax.{@link Ext.data.Connection#request request}({
   url: 'foo.php',
   success: someFn,
   failure: otherFn,
   headers: {
       'my-header': 'foo'
   },
   params: { foo: 'bar' }
});

// Simple ajax form submission
Ext.Ajax.{@link Ext.data.Connection#request request}({
    form: 'some-form',
    params: 'foo=bar'
});
 * </code></pre>
 * </p>
 * @singleton
 */


Ext.Ajax = new Ext.data.Connection({
  /**
   * @cfg {String} url @hide
   */

  /**
   * @cfg {Object} extraParams @hide
   */

  /**
   * @cfg {Object} defaultHeaders @hide
   */

  /**
   * @cfg {String} method (Optional) @hide
   */

  /**
   * @cfg {Number} timeout (Optional) @hide
   */

  /**
   * @cfg {Boolean} autoAbort (Optional) @hide
   */

  /**
   * @cfg {Boolean} disableCaching (Optional) @hide
   */

  /**
   * @property  disableCaching
   * True to add a unique cache-buster param to GET requests. (defaults to true)
   * @type Boolean
   */

  /**
   * @property  url
   * The default URL to be used for requests to the server. (defaults to undefined)
   * If the server receives all requests through one URL, setting this once is easier than
   * entering it on every request.
   * @type String
   */

  /**
   * @property  extraParams
   * An object containing properties which are used as extra parameters to each request made
   * by this object (defaults to undefined). Session information and other data that you need
   * to pass with each request are commonly put here.
   * @type Object
   */

  /**
   * @property  defaultHeaders
   * An object containing request headers which are added to each request made by this object
   * (defaults to undefined).
   * @type Object
   */

  /**
   * @property  method
   * The default HTTP method to be used for requests. Note that this is case-sensitive and
   * should be all caps (defaults to undefined; if not set but params are present will use
   * <tt>"POST"</tt>, otherwise will use <tt>"GET"</tt>.)
   * @type String
   */

  /**
   * @property  timeout
   * The timeout in milliseconds to be used for requests. (defaults to 30000)
   * @type Number
   */

  /**
   * @property  autoAbort
   * Whether a new request should abort any pending requests. (defaults to false)
   * @type Boolean
   */
  autoAbort: false,

  /**
   * Serialize the passed form into a url encoded string
   * @param {String/HTMLElement} form
   * @return {String}
   */
  serializeForm: function serializeForm(form) {
    return Ext.lib.Ajax.serializeForm(form);
  }
});

/***/ }),
/* 737 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Updater
 * @extends Ext.util.Observable
 * Provides AJAX-style update capabilities for Element objects.  Updater can be used to {@link #update}
 * an {@link Ext.Element} once, or you can use {@link #startAutoRefresh} to set up an auto-updating
 * {@link Ext.Element Element} on a specific interval.<br><br>
 * Usage:<br>
 * <pre><code>
 * var el = Ext.get("foo"); // Get Ext.Element object
 * var mgr = el.getUpdater();
 * mgr.update({
        url: "http://myserver.com/index.php",
        params: {
            param1: "foo",
            param2: "bar"
        }
 * });
 * ...
 * mgr.formUpdate("myFormId", "http://myserver.com/index.php");
 * <br>
 * // or directly (returns the same Updater instance)
 * var mgr = new Ext.Updater("myElementId");
 * mgr.startAutoRefresh(60, "http://myserver.com/index.php");
 * mgr.on("update", myFcnNeedsToKnow);
 * <br>
 * // short handed call directly from the element object
 * Ext.get("foo").load({
        url: "bar.php",
        scripts: true,
        params: "param1=foo&amp;param2=bar",
        text: "Loading Foo..."
 * });
 * </code></pre>
 * @constructor
 * Create new Updater directly.
 * @param {Mixed} el The element to update
 * @param {Boolean} forceNew (optional) By default the constructor checks to see if the passed element already
 * has an Updater and if it does it returns the same instance. This will skip that check (useful for extending this class).
 */
Ext.UpdateManager = Ext.Updater = Ext.extend(Ext.util.Observable, function () {
  var BEFOREUPDATE = "beforeupdate",
      UPDATE = "update",
      FAILURE = "failure"; // private

  function processSuccess(response) {
    var me = this;
    me.transaction = null;

    if (response.argument.form && response.argument.reset) {
      try {
        // put in try/catch since some older FF releases had problems with this
        response.argument.form.reset();
      } catch (e) {}
    }

    if (me.loadScripts) {
      me.renderer.render(me.el, response, me, updateComplete.createDelegate(me, [response]));
    } else {
      me.renderer.render(me.el, response, me);
      updateComplete.call(me, response);
    }
  } // private


  function updateComplete(response, type, success) {
    this.fireEvent(type || UPDATE, this.el, response);

    if (Ext.isFunction(response.argument.callback)) {
      response.argument.callback.call(response.argument.scope, this.el, Ext.isEmpty(success) ? true : false, response, response.argument.options);
    }
  } // private


  function processFailure(response) {
    updateComplete.call(this, response, FAILURE, !!(this.transaction = null));
  }

  return {
    constructor: function constructor(el, forceNew) {
      var me = this;
      el = Ext.get(el);

      if (!forceNew && el.updateManager) {
        return el.updateManager;
      }
      /**
       * The Element object
       * @type Ext.Element
       */


      me.el = el;
      /**
       * Cached url to use for refreshes. Overwritten every time update() is called unless "discardUrl" param is set to true.
       * @type String
       */

      me.defaultUrl = null;
      me.addEvents(
      /**
       * @event beforeupdate
       * Fired before an update is made, return false from your handler and the update is cancelled.
       * @param {Ext.Element} el
       * @param {String/Object/Function} url
       * @param {String/Object} params
       */
      BEFOREUPDATE,
      /**
       * @event update
       * Fired after successful update is made.
       * @param {Ext.Element} el
       * @param {Object} oResponseObject The response Object
       */
      UPDATE,
      /**
       * @event failure
       * Fired on update failure.
       * @param {Ext.Element} el
       * @param {Object} oResponseObject The response Object
       */
      FAILURE);
      Ext.apply(me, Ext.Updater.defaults);
      /**
       * Blank page URL to use with SSL file uploads (defaults to {@link Ext.Updater.defaults#sslBlankUrl}).
       * @property sslBlankUrl
       * @type String
       */

      /**
       * Whether to append unique parameter on get request to disable caching (defaults to {@link Ext.Updater.defaults#disableCaching}).
       * @property disableCaching
       * @type Boolean
       */

      /**
       * Text for loading indicator (defaults to {@link Ext.Updater.defaults#indicatorText}).
       * @property indicatorText
       * @type String
       */

      /**
       * Whether to show indicatorText when loading (defaults to {@link Ext.Updater.defaults#showLoadIndicator}).
       * @property showLoadIndicator
       * @type String
       */

      /**
       * Timeout for requests or form posts in seconds (defaults to {@link Ext.Updater.defaults#timeout}).
       * @property timeout
       * @type Number
       */

      /**
       * True to process scripts in the output (defaults to {@link Ext.Updater.defaults#loadScripts}).
       * @property loadScripts
       * @type Boolean
       */

      /**
       * Transaction object of the current executing transaction, or null if there is no active transaction.
       */

      me.transaction = null;
      /**
       * Delegate for refresh() prebound to "this", use myUpdater.refreshDelegate.createCallback(arg1, arg2) to bind arguments
       * @type Function
       */

      me.refreshDelegate = me.refresh.createDelegate(me);
      /**
       * Delegate for update() prebound to "this", use myUpdater.updateDelegate.createCallback(arg1, arg2) to bind arguments
       * @type Function
       */

      me.updateDelegate = me.update.createDelegate(me);
      /**
       * Delegate for formUpdate() prebound to "this", use myUpdater.formUpdateDelegate.createCallback(arg1, arg2) to bind arguments
       * @type Function
       */

      me.formUpdateDelegate = (me.formUpdate || function () {}).createDelegate(me);
      /**
       * The renderer for this Updater (defaults to {@link Ext.Updater.BasicRenderer}).
       */


      me.renderer = me.renderer || me.getDefaultRenderer();
      Ext.Updater.superclass.constructor.call(me);
    },

    /**
        * Sets the content renderer for this Updater. See {@link Ext.Updater.BasicRenderer#render} for more details.
        * @param {Object} renderer The object implementing the render() method
        */
    setRenderer: function setRenderer(renderer) {
      this.renderer = renderer;
    },

    /**
     * Returns the current content renderer for this Updater. See {@link Ext.Updater.BasicRenderer#render} for more details.
     * @return {Object}
     */
    getRenderer: function getRenderer() {
      return this.renderer;
    },

    /**
     * This is an overrideable method which returns a reference to a default
     * renderer class if none is specified when creating the Ext.Updater.
     * Defaults to {@link Ext.Updater.BasicRenderer}
     */
    getDefaultRenderer: function getDefaultRenderer() {
      return new Ext.Updater.BasicRenderer();
    },

    /**
     * Sets the default URL used for updates.
     * @param {String/Function} defaultUrl The url or a function to call to get the url
     */
    setDefaultUrl: function setDefaultUrl(defaultUrl) {
      this.defaultUrl = defaultUrl;
    },

    /**
     * Get the Element this Updater is bound to
     * @return {Ext.Element} The element
     */
    getEl: function getEl() {
      return this.el;
    },

    /**
        * Performs an <b>asynchronous</b> request, updating this element with the response.
        * If params are specified it uses POST, otherwise it uses GET.<br><br>
        * <b>Note:</b> Due to the asynchronous nature of remote server requests, the Element
        * will not have been fully updated when the function returns. To post-process the returned
        * data, use the callback option, or an <b><code>update</code></b> event handler.
        * @param {Object} options A config object containing any of the following options:<ul>
        * <li>url : <b>String/Function</b><p class="sub-desc">The URL to request or a function which
        * <i>returns</i> the URL (defaults to the value of {@link Ext.Ajax#url} if not specified).</p></li>
        * <li>method : <b>String</b><p class="sub-desc">The HTTP method to
        * use. Defaults to POST if the <code>params</code> argument is present, otherwise GET.</p></li>
        * <li>params : <b>String/Object/Function</b><p class="sub-desc">The
        * parameters to pass to the server (defaults to none). These may be specified as a url-encoded
        * string, or as an object containing properties which represent parameters,
        * or as a function, which returns such an object.</p></li>
        * <li>scripts : <b>Boolean</b><p class="sub-desc">If <code>true</code>
        * any &lt;script&gt; tags embedded in the response text will be extracted
        * and executed (defaults to {@link Ext.Updater.defaults#loadScripts}). If this option is specified,
        * the callback will be called <i>after</i> the execution of the scripts.</p></li>
        * <li>callback : <b>Function</b><p class="sub-desc">A function to
        * be called when the response from the server arrives. The following
        * parameters are passed:<ul>
        * <li><b>el</b> : Ext.Element<p class="sub-desc">The Element being updated.</p></li>
        * <li><b>success</b> : Boolean<p class="sub-desc">True for success, false for failure.</p></li>
        * <li><b>response</b> : XMLHttpRequest<p class="sub-desc">The XMLHttpRequest which processed the update.</p></li>
        * <li><b>options</b> : Object<p class="sub-desc">The config object passed to the update call.</p></li></ul>
        * </p></li>
        * <li>scope : <b>Object</b><p class="sub-desc">The scope in which
        * to execute the callback (The callback's <code>this</code> reference.) If the
        * <code>params</code> argument is a function, this scope is used for that function also.</p></li>
        * <li>discardUrl : <b>Boolean</b><p class="sub-desc">By default, the URL of this request becomes
        * the default URL for this Updater object, and will be subsequently used in {@link #refresh}
        * calls.  To bypass this behavior, pass <code>discardUrl:true</code> (defaults to false).</p></li>
        * <li>timeout : <b>Number</b><p class="sub-desc">The number of seconds to wait for a response before
        * timing out (defaults to {@link Ext.Updater.defaults#timeout}).</p></li>
        * <li>text : <b>String</b><p class="sub-desc">The text to use as the innerHTML of the
        * {@link Ext.Updater.defaults#indicatorText} div (defaults to 'Loading...').  To replace the entire div, not
        * just the text, override {@link Ext.Updater.defaults#indicatorText} directly.</p></li>
        * <li>nocache : <b>Boolean</b><p class="sub-desc">Only needed for GET
        * requests, this option causes an extra, auto-generated parameter to be appended to the request
        * to defeat caching (defaults to {@link Ext.Updater.defaults#disableCaching}).</p></li></ul>
        * <p>
        * For example:
    <pre><code>
    um.update({
       url: "your-url.php",
       params: {param1: "foo", param2: "bar"}, // or a URL encoded string
       callback: yourFunction,
       scope: yourObject, //(optional scope)
       discardUrl: true,
       nocache: true,
       text: "Loading...",
       timeout: 60,
       scripts: false // Save time by avoiding RegExp execution.
    });
    </code></pre>
        */
    update: function update(url, params, callback, discardUrl) {
      var me = this,
          cfg,
          callerScope;

      if (me.fireEvent(BEFOREUPDATE, me.el, url, params) !== false) {
        if (Ext.isObject(url)) {
          // must be config object
          cfg = url;
          url = cfg.url;
          params = params || cfg.params;
          callback = callback || cfg.callback;
          discardUrl = discardUrl || cfg.discardUrl;
          callerScope = cfg.scope;

          if (!Ext.isEmpty(cfg.nocache)) {
            me.disableCaching = cfg.nocache;
          }

          ;

          if (!Ext.isEmpty(cfg.text)) {
            me.indicatorText = '<div class="loading-indicator">' + cfg.text + "</div>";
          }

          ;

          if (!Ext.isEmpty(cfg.scripts)) {
            me.loadScripts = cfg.scripts;
          }

          ;

          if (!Ext.isEmpty(cfg.timeout)) {
            me.timeout = cfg.timeout;
          }

          ;
        }

        me.showLoading();

        if (!discardUrl) {
          me.defaultUrl = url;
        }

        if (Ext.isFunction(url)) {
          url = url.call(me);
        }

        var o = Ext.apply({}, {
          url: url,
          params: Ext.isFunction(params) && callerScope ? params.createDelegate(callerScope) : params,
          success: processSuccess,
          failure: processFailure,
          scope: me,
          callback: undefined,
          timeout: me.timeout * 1000,
          disableCaching: me.disableCaching,
          argument: {
            "options": cfg,
            "url": url,
            "form": null,
            "callback": callback,
            "scope": callerScope || window,
            "params": params
          }
        }, cfg);
        me.transaction = Ext.Ajax.request(o);
      }
    },

    /**
        * <p>Performs an asynchronous form post, updating this element with the response. If the form has the attribute
        * enctype="<a href="http://www.faqs.org/rfcs/rfc2388.html">multipart/form-data</a>", it assumes it's a file upload.
        * Uses this.sslBlankUrl for SSL file uploads to prevent IE security warning.</p>
        * <p>File uploads are not performed using normal "Ajax" techniques, that is they are <b>not</b>
        * performed using XMLHttpRequests. Instead the form is submitted in the standard manner with the
        * DOM <code>&lt;form></code> element temporarily modified to have its
        * <a href="http://www.w3.org/TR/REC-html40/present/frames.html#adef-target">target</a> set to refer
        * to a dynamically generated, hidden <code>&lt;iframe></code> which is inserted into the document
        * but removed after the return data has been gathered.</p>
        * <p>Be aware that file upload packets, sent with the content type <a href="http://www.faqs.org/rfcs/rfc2388.html">multipart/form-data</a>
        * and some server technologies (notably JEE) may require some custom processing in order to
        * retrieve parameter names and parameter values from the packet content.</p>
        * @param {String/HTMLElement} form The form Id or form element
        * @param {String} url (optional) The url to pass the form to. If omitted the action attribute on the form will be used.
        * @param {Boolean} reset (optional) Whether to try to reset the form after the update
        * @param {Function} callback (optional) Callback when transaction is complete. The following
        * parameters are passed:<ul>
        * <li><b>el</b> : Ext.Element<p class="sub-desc">The Element being updated.</p></li>
        * <li><b>success</b> : Boolean<p class="sub-desc">True for success, false for failure.</p></li>
        * <li><b>response</b> : XMLHttpRequest<p class="sub-desc">The XMLHttpRequest which processed the update.</p></li></ul>
        */
    formUpdate: function formUpdate(form, url, reset, callback) {
      var me = this;

      if (me.fireEvent(BEFOREUPDATE, me.el, form, url) !== false) {
        if (Ext.isFunction(url)) {
          url = url.call(me);
        }

        form = Ext.getDom(form);
        me.transaction = Ext.Ajax.request({
          form: form,
          url: url,
          success: processSuccess,
          failure: processFailure,
          scope: me,
          timeout: me.timeout * 1000,
          argument: {
            "url": url,
            "form": form,
            "callback": callback,
            "reset": reset
          }
        });
        me.showLoading.defer(1, me);
      }
    },

    /**
     * Set this element to auto refresh.  Can be canceled by calling {@link #stopAutoRefresh}.
     * @param {Number} interval How often to update (in seconds).
     * @param {String/Object/Function} url (optional) The url for this request, a config object in the same format
     * supported by {@link #load}, or a function to call to get the url (defaults to the last used url).  Note that while
     * the url used in a load call can be reused by this method, other load config options will not be reused and must be
     * sepcified as part of a config object passed as this paramter if needed.
     * @param {String/Object} params (optional) The parameters to pass as either a url encoded string
     * "&param1=1&param2=2" or as an object {param1: 1, param2: 2}
     * @param {Function} callback (optional) Callback when transaction is complete - called with signature (oElement, bSuccess)
     * @param {Boolean} refreshNow (optional) Whether to execute the refresh now, or wait the interval
     */
    startAutoRefresh: function startAutoRefresh(interval, url, params, callback, refreshNow) {
      var me = this;

      if (refreshNow) {
        me.update(url || me.defaultUrl, params, callback, true);
      }

      if (me.autoRefreshProcId) {
        clearInterval(me.autoRefreshProcId);
      }

      me.autoRefreshProcId = setInterval(me.update.createDelegate(me, [url || me.defaultUrl, params, callback, true]), interval * 1000);
    },

    /**
     * Stop auto refresh on this element.
     */
    stopAutoRefresh: function stopAutoRefresh() {
      if (this.autoRefreshProcId) {
        clearInterval(this.autoRefreshProcId);
        delete this.autoRefreshProcId;
      }
    },

    /**
     * Returns true if the Updater is currently set to auto refresh its content (see {@link #startAutoRefresh}), otherwise false.
     */
    isAutoRefreshing: function isAutoRefreshing() {
      return !!this.autoRefreshProcId;
    },

    /**
     * Display the element's "loading" state. By default, the element is updated with {@link #indicatorText}. This
     * method may be overridden to perform a custom action while this Updater is actively updating its contents.
     */
    showLoading: function showLoading() {
      if (this.showLoadIndicator) {
        this.el.dom.innerHTML = this.indicatorText;
      }
    },

    /**
     * Aborts the currently executing transaction, if any.
     */
    abort: function abort() {
      if (this.transaction) {
        Ext.Ajax.abort(this.transaction);
      }
    },

    /**
     * Returns true if an update is in progress, otherwise false.
     * @return {Boolean}
     */
    isUpdating: function isUpdating() {
      return this.transaction ? Ext.Ajax.isLoading(this.transaction) : false;
    },

    /**
     * Refresh the element with the last used url or defaultUrl. If there is no url, it returns immediately
     * @param {Function} callback (optional) Callback when transaction is complete - called with signature (oElement, bSuccess)
     */
    refresh: function refresh(callback) {
      if (this.defaultUrl) {
        this.update(this.defaultUrl, null, callback, true);
      }
    }
  };
}());
/**
 * @class Ext.Updater.defaults
 * The defaults collection enables customizing the default properties of Updater
 */

Ext.Updater.defaults = {
  /**
    * Timeout for requests or form posts in seconds (defaults to 30 seconds).
    * @type Number
    */
  timeout: 30,

  /**
   * True to append a unique parameter to GET requests to disable caching (defaults to false).
   * @type Boolean
   */
  disableCaching: false,

  /**
   * Whether or not to show {@link #indicatorText} during loading (defaults to true).
   * @type Boolean
   */
  showLoadIndicator: true,

  /**
   * Text for loading indicator (defaults to '&lt;div class="loading-indicator"&gt;Loading...&lt;/div&gt;').
   * @type String
   */
  indicatorText: '<div class="loading-indicator">Loading...</div>',

  /**
  * True to process scripts by default (defaults to false).
  * @type Boolean
  */
  loadScripts: false,

  /**
  * Blank page URL to use with SSL file uploads (defaults to {@link Ext#SSL_SECURE_URL} if set, or "javascript:false").
  * @type String
  */
  sslBlankUrl: Ext.SSL_SECURE_URL
};
/**
 * Static convenience method. <b>This method is deprecated in favor of el.load({url:'foo.php', ...})</b>.
 * Usage:
 * <pre><code>Ext.Updater.updateElement("my-div", "stuff.php");</code></pre>
 * @param {Mixed} el The element to update
 * @param {String} url The url
 * @param {String/Object} params (optional) Url encoded param string or an object of name/value pairs
 * @param {Object} options (optional) A config object with any of the Updater properties you want to set - for
 * example: {disableCaching:true, indicatorText: "Loading data..."}
 * @static
 * @deprecated
 * @member Ext.Updater
 */

Ext.Updater.updateElement = function (el, url, params, options) {
  var um = Ext.get(el).getUpdater();
  Ext.apply(um, options);
  um.update(url, params, options ? options.callback : null);
};
/**
 * @class Ext.Updater.BasicRenderer
 * <p>This class is a base class implementing a simple render method which updates an element using results from an Ajax request.</p>
 * <p>The BasicRenderer updates the element's innerHTML with the responseText. To perform a custom render (i.e. XML or JSON processing),
 * create an object with a conforming {@link #render} method and pass it to setRenderer on the Updater.</p>
 */


Ext.Updater.BasicRenderer = function () {};

Ext.Updater.BasicRenderer.prototype = {
  /**
   * This method is called when an Ajax response is received, and an Element needs updating.
   * @param {Ext.Element} el The element being rendered
   * @param {Object} xhr The XMLHttpRequest object
   * @param {Updater} updateManager The calling update manager
   * @param {Function} callback A callback that will need to be called if loadScripts is true on the Updater
   */
  render: function render(el, response, updateManager, callback) {
    el.update(response.responseText, updateManager.loadScripts, callback);
  }
};

/***/ }),
/* 738 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Date
 *
 * The date parsing and formatting syntax contains a subset of
 * <a href="http://www.php.net/date">PHP's date() function</a>, and the formats that are
 * supported will provide results equivalent to their PHP versions.
 *
 * The following is a list of all currently supported formats:
 * <pre>
Format  Description                                                               Example returned values
------  -----------------------------------------------------------------------   -----------------------
  d     Day of the month, 2 digits with leading zeros                             01 to 31
  D     A short textual representation of the day of the week                     Mon to Sun
  j     Day of the month without leading zeros                                    1 to 31
  l     A full textual representation of the day of the week                      Sunday to Saturday
  N     ISO-8601 numeric representation of the day of the week                    1 (for Monday) through 7 (for Sunday)
  S     English ordinal suffix for the day of the month, 2 characters             st, nd, rd or th. Works well with j
  w     Numeric representation of the day of the week                             0 (for Sunday) to 6 (for Saturday)
  z     The day of the year (starting from 0)                                     0 to 364 (365 in leap years)
  W     ISO-8601 week number of year, weeks starting on Monday                    01 to 53
  F     A full textual representation of a month, such as January or March        January to December
  m     Numeric representation of a month, with leading zeros                     01 to 12
  M     A short textual representation of a month                                 Jan to Dec
  n     Numeric representation of a month, without leading zeros                  1 to 12
  t     Number of days in the given month                                         28 to 31
  L     Whether it's a leap year                                                  1 if it is a leap year, 0 otherwise.
  o     ISO-8601 year number (identical to (Y), but if the ISO week number (W)    Examples: 1998 or 2004
        belongs to the previous or next year, that year is used instead)
  Y     A full numeric representation of a year, 4 digits                         Examples: 1999 or 2003
  y     A two digit representation of a year                                      Examples: 99 or 03
  a     Lowercase Ante meridiem and Post meridiem                                 am or pm
  A     Uppercase Ante meridiem and Post meridiem                                 AM or PM
  g     12-hour format of an hour without leading zeros                           1 to 12
  G     24-hour format of an hour without leading zeros                           0 to 23
  h     12-hour format of an hour with leading zeros                              01 to 12
  H     24-hour format of an hour with leading zeros                              00 to 23
  i     Minutes, with leading zeros                                               00 to 59
  s     Seconds, with leading zeros                                               00 to 59
  u     Decimal fraction of a second                                              Examples:
        (minimum 1 digit, arbitrary number of digits allowed)                     001 (i.e. 0.001s) or
                                                                                  100 (i.e. 0.100s) or
                                                                                  999 (i.e. 0.999s) or
                                                                                  999876543210 (i.e. 0.999876543210s)
  O     Difference to Greenwich time (GMT) in hours and minutes                   Example: +1030
  P     Difference to Greenwich time (GMT) with colon between hours and minutes   Example: -08:00
  T     Timezone abbreviation of the machine running the code                     Examples: EST, MDT, PDT ...
  Z     Timezone offset in seconds (negative if west of UTC, positive if east)    -43200 to 50400
  c     ISO 8601 date
        Notes:                                                                    Examples:
        1) If unspecified, the month / day defaults to the current month / day,   1991 or
           the time defaults to midnight, while the timezone defaults to the      1992-10 or
           browser's timezone. If a time is specified, it must include both hours 1993-09-20 or
           and minutes. The "T" delimiter, seconds, milliseconds and timezone     1994-08-19T16:20+01:00 or
           are optional.                                                          1995-07-18T17:21:28-02:00 or
        2) The decimal fraction of a second, if specified, must contain at        1996-06-17T18:22:29.98765+03:00 or
           least 1 digit (there is no limit to the maximum number                 1997-05-16T19:23:30,12345-0400 or
           of digits allowed), and may be delimited by either a '.' or a ','      1998-04-15T20:24:31.2468Z or
        Refer to the examples on the right for the various levels of              1999-03-14T20:24:32Z or
        date-time granularity which are supported, or see                         2000-02-13T21:25:33
        http://www.w3.org/TR/NOTE-datetime for more info.                         2001-01-12 22:26:34
  U     Seconds since the Unix Epoch (January 1 1970 00:00:00 GMT)                1193432466 or -2138434463
  M$    Microsoft AJAX serialized dates                                           \/Date(1238606590509)\/ (i.e. UTC milliseconds since epoch) or
                                                                                  \/Date(1238606590509+0800)\/
</pre>
 *
 * Example usage (note that you must escape format specifiers with '\\' to render them as character literals):
 * <pre><code>
// Sample date:
// 'Wed Jan 10 2007 15:05:01 GMT-0600 (Central Standard Time)'

var dt = new Date('1/10/2007 03:05:01 PM GMT-0600');
document.write(dt.format('Y-m-d'));                           // 2007-01-10
document.write(dt.format('F j, Y, g:i a'));                   // January 10, 2007, 3:05 pm
document.write(dt.format('l, \\t\\he jS \\of F Y h:i:s A'));  // Wednesday, the 10th of January 2007 03:05:01 PM
</code></pre>
 *
 * Here are some standard date/time patterns that you might find helpful.  They
 * are not part of the source of Date.js, but to use them you can simply copy this
 * block of code into any script that is included after Date.js and they will also become
 * globally available on the Date object.  Feel free to add or remove patterns as needed in your code.
 * <pre><code>
Date.patterns = {
    ISO8601Long:"Y-m-d H:i:s",
    ISO8601Short:"Y-m-d",
    ShortDate: "n/j/Y",
    LongDate: "l, F d, Y",
    FullDateTime: "l, F d, Y g:i:s A",
    MonthDay: "F d",
    ShortTime: "g:i A",
    LongTime: "g:i:s A",
    SortableDateTime: "Y-m-d\\TH:i:s",
    UniversalSortableDateTime: "Y-m-d H:i:sO",
    YearMonth: "F, Y"
};
</code></pre>
 *
 * Example usage:
 * <pre><code>
var dt = new Date();
document.write(dt.format(Date.patterns.ShortDate));
</code></pre>
 * <p>Developer-written, custom formats may be used by supplying both a formatting and a parsing function
 * which perform to specialized requirements. The functions are stored in {@link #parseFunctions} and {@link #formatFunctions}.</p>
 */

/*
 * Most of the date-formatting functions below are the excellent work of Baron Schwartz.
 * (see http://www.xaprb.com/blog/2005/12/12/javascript-closures-for-runtime-efficiency/)
 * They generate precompiled functions from format patterns instead of parsing and
 * processing each pattern every time a date is formatted. These functions are available
 * on every Date object.
 */
(function () {
  /**
   * Global flag which determines if strict date parsing should be used.
   * Strict date parsing will not roll-over invalid dates, which is the
   * default behaviour of javascript Date objects.
   * (see {@link #parseDate} for more information)
   * Defaults to <tt>false</tt>.
   * @static
   * @type Boolean
  */
  Date.useStrict = false; // create private copy of Ext's String.format() method
  // - to remove unnecessary dependency
  // - to resolve namespace conflict with M$-Ajax's implementation

  function xf(format) {
    var args = Array.prototype.slice.call(arguments, 1);
    return format.replace(/\{(\d+)\}/g, function (m, i) {
      return args[i];
    });
  } // private


  Date.formatCodeToRegex = function (character, currentGroup) {
    // Note: currentGroup - position in regex result array (see notes for Date.parseCodes below)
    var p = Date.parseCodes[character];

    if (p) {
      p = typeof p == 'function' ? p() : p;
      Date.parseCodes[character] = p; // reassign function result to prevent repeated execution
    }

    return p ? Ext.applyIf({
      c: p.c ? xf(p.c, currentGroup || "{0}") : p.c
    }, p) : {
      g: 0,
      c: null,
      s: Ext.escapeRe(character) // treat unrecognised characters as literals

    };
  }; // private shorthand for Date.formatCodeToRegex since we'll be using it fairly often


  var $f = Date.formatCodeToRegex;
  Ext.apply(Date, {
    /**
     * <p>An object hash in which each property is a date parsing function. The property name is the
     * format string which that function parses.</p>
     * <p>This object is automatically populated with date parsing functions as
     * date formats are requested for Ext standard formatting strings.</p>
     * <p>Custom parsing functions may be inserted into this object, keyed by a name which from then on
     * may be used as a format string to {@link #parseDate}.<p>
     * <p>Example:</p><pre><code>
    Date.parseFunctions['x-date-format'] = myDateParser;
    </code></pre>
     * <p>A parsing function should return a Date object, and is passed the following parameters:<div class="mdetail-params"><ul>
     * <li><code>date</code> : String<div class="sub-desc">The date string to parse.</div></li>
     * <li><code>strict</code> : Boolean<div class="sub-desc">True to validate date strings while parsing
     * (i.e. prevent javascript Date "rollover") (The default must be false).
     * Invalid date strings should return null when parsed.</div></li>
     * </ul></div></p>
     * <p>To enable Dates to also be <i>formatted</i> according to that format, a corresponding
     * formatting function must be placed into the {@link #formatFunctions} property.
     * @property parseFunctions
     * @static
     * @type Object
     */
    parseFunctions: {
      "M$": function M$(input, strict) {
        // note: the timezone offset is ignored since the M$ Ajax server sends
        // a UTC milliseconds-since-Unix-epoch value (negative values are allowed)
        var re = new RegExp('\\/Date\\(([-+])?(\\d+)(?:[+-]\\d{4})?\\)\\/');
        var r = (input || '').match(re);
        return r ? new Date(((r[1] || '') + r[2]) * 1) : null;
      }
    },
    parseRegexes: [],

    /**
     * <p>An object hash in which each property is a date formatting function. The property name is the
     * format string which corresponds to the produced formatted date string.</p>
     * <p>This object is automatically populated with date formatting functions as
     * date formats are requested for Ext standard formatting strings.</p>
     * <p>Custom formatting functions may be inserted into this object, keyed by a name which from then on
     * may be used as a format string to {@link #format}. Example:</p><pre><code>
    Date.formatFunctions['x-date-format'] = myDateFormatter;
    </code></pre>
     * <p>A formatting function should return a string repesentation of the passed Date object:<div class="mdetail-params"><ul>
     * <li><code>date</code> : Date<div class="sub-desc">The Date to format.</div></li>
     * </ul></div></p>
     * <p>To enable date strings to also be <i>parsed</i> according to that format, a corresponding
     * parsing function must be placed into the {@link #parseFunctions} property.
     * @property formatFunctions
     * @static
     * @type Object
     */
    formatFunctions: {
      "M$": function M$() {
        // UTC milliseconds since Unix epoch (M$-AJAX serialized date format (MRSF))
        return '\\/Date(' + this.getTime() + ')\\/';
      }
    },
    y2kYear: 50,

    /**
     * Date interval constant
     * @static
     * @type String
     */
    MILLI: "ms",

    /**
     * Date interval constant
     * @static
     * @type String
     */
    SECOND: "s",

    /**
     * Date interval constant
     * @static
     * @type String
     */
    MINUTE: "mi",

    /** Date interval constant
     * @static
     * @type String
     */
    HOUR: "h",

    /**
     * Date interval constant
     * @static
     * @type String
     */
    DAY: "d",

    /**
     * Date interval constant
     * @static
     * @type String
     */
    MONTH: "mo",

    /**
     * Date interval constant
     * @static
     * @type String
     */
    YEAR: "y",

    /**
     * <p>An object hash containing default date values used during date parsing.</p>
     * <p>The following properties are available:<div class="mdetail-params"><ul>
     * <li><code>y</code> : Number<div class="sub-desc">The default year value. (defaults to undefined)</div></li>
     * <li><code>m</code> : Number<div class="sub-desc">The default 1-based month value. (defaults to undefined)</div></li>
     * <li><code>d</code> : Number<div class="sub-desc">The default day value. (defaults to undefined)</div></li>
     * <li><code>h</code> : Number<div class="sub-desc">The default hour value. (defaults to undefined)</div></li>
     * <li><code>i</code> : Number<div class="sub-desc">The default minute value. (defaults to undefined)</div></li>
     * <li><code>s</code> : Number<div class="sub-desc">The default second value. (defaults to undefined)</div></li>
     * <li><code>ms</code> : Number<div class="sub-desc">The default millisecond value. (defaults to undefined)</div></li>
     * </ul></div></p>
     * <p>Override these properties to customize the default date values used by the {@link #parseDate} method.</p>
     * <p><b>Note: In countries which experience Daylight Saving Time (i.e. DST), the <tt>h</tt>, <tt>i</tt>, <tt>s</tt>
     * and <tt>ms</tt> properties may coincide with the exact time in which DST takes effect.
     * It is the responsiblity of the developer to account for this.</b></p>
     * Example Usage:
     * <pre><code>
    // set default day value to the first day of the month
    Date.defaults.d = 1;
    // parse a February date string containing only year and month values.
    // setting the default day value to 1 prevents weird date rollover issues
    // when attempting to parse the following date string on, for example, March 31st 2009.
    Date.parseDate('2009-02', 'Y-m'); // returns a Date object representing February 1st 2009
    </code></pre>
     * @property defaults
     * @static
     * @type Object
     */
    defaults: {},

    /**
     * An array of textual day names.
     * Override these values for international dates.
     * Example:
     * <pre><code>
    Date.dayNames = [
    'SundayInYourLang',
    'MondayInYourLang',
    ...
    ];
    </code></pre>
     * @type Array
     * @static
     */
    dayNames: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],

    /**
     * An array of textual month names.
     * Override these values for international dates.
     * Example:
     * <pre><code>
    Date.monthNames = [
    'JanInYourLang',
    'FebInYourLang',
    ...
    ];
    </code></pre>
     * @type Array
     * @static
     */
    monthNames: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],

    /**
     * An object hash of zero-based javascript month numbers (with short month names as keys. note: keys are case-sensitive).
     * Override these values for international dates.
     * Example:
     * <pre><code>
    Date.monthNumbers = {
    'ShortJanNameInYourLang':0,
    'ShortFebNameInYourLang':1,
    ...
    };
    </code></pre>
     * @type Object
     * @static
     */
    monthNumbers: {
      Jan: 0,
      Feb: 1,
      Mar: 2,
      Apr: 3,
      May: 4,
      Jun: 5,
      Jul: 6,
      Aug: 7,
      Sep: 8,
      Oct: 9,
      Nov: 10,
      Dec: 11
    },

    /**
     * Get the short month name for the given month number.
     * Override this function for international dates.
     * @param {Number} month A zero-based javascript month number.
     * @return {String} The short month name.
     * @static
     */
    getShortMonthName: function getShortMonthName(month) {
      return Date.monthNames[month].substring(0, 3);
    },

    /**
     * Get the short day name for the given day number.
     * Override this function for international dates.
     * @param {Number} day A zero-based javascript day number.
     * @return {String} The short day name.
     * @static
     */
    getShortDayName: function getShortDayName(day) {
      return Date.dayNames[day].substring(0, 3);
    },

    /**
     * Get the zero-based javascript month number for the given short/full month name.
     * Override this function for international dates.
     * @param {String} name The short/full month name.
     * @return {Number} The zero-based javascript month number.
     * @static
     */
    getMonthNumber: function getMonthNumber(name) {
      // handle camel casing for english month names (since the keys for the Date.monthNumbers hash are case sensitive)
      return Date.monthNumbers[name.substring(0, 1).toUpperCase() + name.substring(1, 3).toLowerCase()];
    },

    /**
     * The base format-code to formatting-function hashmap used by the {@link #format} method.
     * Formatting functions are strings (or functions which return strings) which
     * will return the appropriate value when evaluated in the context of the Date object
     * from which the {@link #format} method is called.
     * Add to / override these mappings for custom date formatting.
     * Note: Date.format() treats characters as literals if an appropriate mapping cannot be found.
     * Example:
     * <pre><code>
    Date.formatCodes.x = "String.leftPad(this.getDate(), 2, '0')";
    (new Date()).format("X"); // returns the current day of the month
    </code></pre>
     * @type Object
     * @static
     */
    formatCodes: {
      d: "String.leftPad(this.getDate(), 2, '0')",
      D: "Date.getShortDayName(this.getDay())",
      // get localised short day name
      j: "this.getDate()",
      l: "Date.dayNames[this.getDay()]",
      N: "(this.getDay() ? this.getDay() : 7)",
      S: "this.getSuffix()",
      w: "this.getDay()",
      z: "this.getDayOfYear()",
      W: "String.leftPad(this.getWeekOfYear(), 2, '0')",
      F: "Date.monthNames[this.getMonth()]",
      m: "String.leftPad(this.getMonth() + 1, 2, '0')",
      M: "Date.getShortMonthName(this.getMonth())",
      // get localised short month name
      n: "(this.getMonth() + 1)",
      t: "this.getDaysInMonth()",
      L: "(this.isLeapYear() ? 1 : 0)",
      o: "(this.getFullYear() + (this.getWeekOfYear() == 1 && this.getMonth() > 0 ? +1 : (this.getWeekOfYear() >= 52 && this.getMonth() < 11 ? -1 : 0)))",
      Y: "this.getFullYear()",
      y: "('' + this.getFullYear()).substring(2, 4)",
      a: "(this.getHours() < 12 ? 'am' : 'pm')",
      A: "(this.getHours() < 12 ? 'AM' : 'PM')",
      g: "((this.getHours() % 12) ? this.getHours() % 12 : 12)",
      G: "this.getHours()",
      h: "String.leftPad((this.getHours() % 12) ? this.getHours() % 12 : 12, 2, '0')",
      H: "String.leftPad(this.getHours(), 2, '0')",
      i: "String.leftPad(this.getMinutes(), 2, '0')",
      s: "String.leftPad(this.getSeconds(), 2, '0')",
      u: "String.leftPad(this.getMilliseconds(), 3, '0')",
      O: "this.getGMTOffset()",
      P: "this.getGMTOffset(true)",
      T: "this.getTimezone()",
      Z: "(this.getTimezoneOffset() * -60)",
      c: function c() {
        // ISO-8601 -- GMT format
        for (var c = "Y-m-dTH:i:sP", code = [], i = 0, l = c.length; i < l; ++i) {
          var e = c.charAt(i);
          code.push(e == "T" ? "'T'" : Date.getFormatCode(e)); // treat T as a character literal
        }

        return code.join(" + ");
      },

      /*
      c: function() { // ISO-8601 -- UTC format
          return [
            "this.getUTCFullYear()", "'-'",
            "String.leftPad(this.getUTCMonth() + 1, 2, '0')", "'-'",
            "String.leftPad(this.getUTCDate(), 2, '0')",
            "'T'",
            "String.leftPad(this.getUTCHours(), 2, '0')", "':'",
            "String.leftPad(this.getUTCMinutes(), 2, '0')", "':'",
            "String.leftPad(this.getUTCSeconds(), 2, '0')",
            "'Z'"
          ].join(" + ");
      },
      */
      U: "Math.round(this.getTime() / 1000)"
    },

    /**
     * Checks if the passed Date parameters will cause a javascript Date "rollover".
     * @param {Number} year 4-digit year
     * @param {Number} month 1-based month-of-year
     * @param {Number} day Day of month
     * @param {Number} hour (optional) Hour
     * @param {Number} minute (optional) Minute
     * @param {Number} second (optional) Second
     * @param {Number} millisecond (optional) Millisecond
     * @return {Boolean} true if the passed parameters do not cause a Date "rollover", false otherwise.
     * @static
     */
    isValid: function isValid(y, m, d, h, i, s, ms) {
      // setup defaults
      h = h || 0;
      i = i || 0;
      s = s || 0;
      ms = ms || 0;
      var dt = new Date(y, m - 1, d, h, i, s, ms);
      return y == dt.getFullYear() && m == dt.getMonth() + 1 && d == dt.getDate() && h == dt.getHours() && i == dt.getMinutes() && s == dt.getSeconds() && ms == dt.getMilliseconds();
    },

    /**
     * Parses the passed string using the specified date format.
     * Note that this function expects normal calendar dates, meaning that months are 1-based (i.e. 1 = January).
     * The {@link #defaults} hash will be used for any date value (i.e. year, month, day, hour, minute, second or millisecond)
     * which cannot be found in the passed string. If a corresponding default date value has not been specified in the {@link #defaults} hash,
     * the current date's year, month, day or DST-adjusted zero-hour time value will be used instead.
     * Keep in mind that the input date string must precisely match the specified format string
     * in order for the parse operation to be successful (failed parse operations return a null value).
     * <p>Example:</p><pre><code>
    //dt = Fri May 25 2007 (current date)
    var dt = new Date();
    //dt = Thu May 25 2006 (today&#39;s month/day in 2006)
    dt = Date.parseDate("2006", "Y");
    //dt = Sun Jan 15 2006 (all date parts specified)
    dt = Date.parseDate("2006-01-15", "Y-m-d");
    //dt = Sun Jan 15 2006 15:20:01
    dt = Date.parseDate("2006-01-15 3:20:01 PM", "Y-m-d g:i:s A");
    // attempt to parse Sun Feb 29 2006 03:20:01 in strict mode
    dt = Date.parseDate("2006-02-29 03:20:01", "Y-m-d H:i:s", true); // returns null
    </code></pre>
     * @param {String} input The raw date string.
     * @param {String} format The expected date string format.
     * @param {Boolean} strict (optional) True to validate date strings while parsing (i.e. prevents javascript Date "rollover")
                        (defaults to false). Invalid date strings will return null when parsed.
     * @return {Date} The parsed Date.
     * @static
     */
    parseDate: function parseDate(input, format, strict) {
      var p = Date.parseFunctions;

      if (p[format] == null) {
        Date.createParser(format);
      }

      return p[format](input, Ext.isDefined(strict) ? strict : Date.useStrict);
    },
    // private
    getFormatCode: function getFormatCode(character) {
      var f = Date.formatCodes[character];

      if (f) {
        f = typeof f == 'function' ? f() : f;
        Date.formatCodes[character] = f; // reassign function result to prevent repeated execution
      } // note: unknown characters are treated as literals


      return f || "'" + String.escape(character) + "'";
    },
    // private
    createFormat: function createFormat(format) {
      var code = [],
          special = false,
          ch = '';

      for (var i = 0; i < format.length; ++i) {
        ch = format.charAt(i);

        if (!special && ch == "\\") {
          special = true;
        } else if (special) {
          special = false;
          code.push("'" + String.escape(ch) + "'");
        } else {
          code.push(Date.getFormatCode(ch));
        }
      }

      Date.formatFunctions[format] = new Function("return " + code.join('+'));
    },
    // private
    createParser: function () {
      var code = ["var dt, y, m, d, h, i, s, ms, o, z, zz, u, v,", "def = Date.defaults,", "results = String(input).match(Date.parseRegexes[{0}]);", // either null, or an array of matched strings
      "if(results){", "{1}", "if(u != null){", // i.e. unix time is defined
      "v = new Date(u * 1000);", // give top priority to UNIX time
      "}else{", // create Date object representing midnight of the current day;
      // this will provide us with our date defaults
      // (note: clearTime() handles Daylight Saving Time automatically)
      "dt = (new Date()).clearTime();", // date calculations (note: these calculations create a dependency on Ext.num())
      "y = Ext.num(y, Ext.num(def.y, dt.getFullYear()));", "m = Ext.num(m, Ext.num(def.m - 1, dt.getMonth()));", "d = Ext.num(d, Ext.num(def.d, dt.getDate()));", // time calculations (note: these calculations create a dependency on Ext.num())
      "h  = Ext.num(h, Ext.num(def.h, dt.getHours()));", "i  = Ext.num(i, Ext.num(def.i, dt.getMinutes()));", "s  = Ext.num(s, Ext.num(def.s, dt.getSeconds()));", "ms = Ext.num(ms, Ext.num(def.ms, dt.getMilliseconds()));", "if(z >= 0 && y >= 0){", // both the year and zero-based day of year are defined and >= 0.
      // these 2 values alone provide sufficient info to create a full date object
      // create Date object representing January 1st for the given year
      "v = new Date(y, 0, 1, h, i, s, ms);", // then add day of year, checking for Date "rollover" if necessary
      "v = !strict? v : (strict === true && (z <= 364 || (v.isLeapYear() && z <= 365))? v.add(Date.DAY, z) : null);", "}else if(strict === true && !Date.isValid(y, m + 1, d, h, i, s, ms)){", // check for Date "rollover"
      "v = null;", // invalid date, so return null
      "}else{", // plain old Date object
      "v = new Date(y, m, d, h, i, s, ms);", "}", "}", "}", "if(v){", // favour UTC offset over GMT offset
      "if(zz != null){", // reset to UTC, then add offset
      "v = v.add(Date.SECOND, -v.getTimezoneOffset() * 60 - zz);", "}else if(o){", // reset to GMT, then add offset
      "v = v.add(Date.MINUTE, -v.getTimezoneOffset() + (sn == '+'? -1 : 1) * (hr * 60 + mn));", "}", "}", "return v;"].join('\n');
      return function (format) {
        var regexNum = Date.parseRegexes.length,
            currentGroup = 1,
            calc = [],
            regex = [],
            special = false,
            ch = "";

        for (var i = 0; i < format.length; ++i) {
          ch = format.charAt(i);

          if (!special && ch == "\\") {
            special = true;
          } else if (special) {
            special = false;
            regex.push(String.escape(ch));
          } else {
            var obj = $f(ch, currentGroup);
            currentGroup += obj.g;
            regex.push(obj.s);

            if (obj.g && obj.c) {
              calc.push(obj.c);
            }
          }
        }

        Date.parseRegexes[regexNum] = new RegExp("^" + regex.join('') + "$", "i");
        Date.parseFunctions[format] = new Function("input", "strict", xf(code, regexNum, calc.join('')));
      };
    }(),
    // private
    parseCodes: {
      /*
       * Notes:
       * g = {Number} calculation group (0 or 1. only group 1 contributes to date calculations.)
       * c = {String} calculation method (required for group 1. null for group 0. {0} = currentGroup - position in regex result array)
       * s = {String} regex pattern. all matches are stored in results[], and are accessible by the calculation mapped to 'c'
       */
      d: {
        g: 1,
        c: "d = parseInt(results[{0}], 10);\n",
        s: "(\\d{2})" // day of month with leading zeroes (01 - 31)

      },
      j: {
        g: 1,
        c: "d = parseInt(results[{0}], 10);\n",
        s: "(\\d{1,2})" // day of month without leading zeroes (1 - 31)

      },
      D: function D() {
        for (var a = [], i = 0; i < 7; a.push(Date.getShortDayName(i)), ++i); // get localised short day names


        return {
          g: 0,
          c: null,
          s: "(?:" + a.join("|") + ")"
        };
      },
      l: function l() {
        return {
          g: 0,
          c: null,
          s: "(?:" + Date.dayNames.join("|") + ")"
        };
      },
      N: {
        g: 0,
        c: null,
        s: "[1-7]" // ISO-8601 day number (1 (monday) - 7 (sunday))

      },
      S: {
        g: 0,
        c: null,
        s: "(?:st|nd|rd|th)"
      },
      w: {
        g: 0,
        c: null,
        s: "[0-6]" // javascript day number (0 (sunday) - 6 (saturday))

      },
      z: {
        g: 1,
        c: "z = parseInt(results[{0}], 10);\n",
        s: "(\\d{1,3})" // day of the year (0 - 364 (365 in leap years))

      },
      W: {
        g: 0,
        c: null,
        s: "(?:\\d{2})" // ISO-8601 week number (with leading zero)

      },
      F: function F() {
        return {
          g: 1,
          c: "m = parseInt(Date.getMonthNumber(results[{0}]), 10);\n",
          // get localised month number
          s: "(" + Date.monthNames.join("|") + ")"
        };
      },
      M: function M() {
        for (var a = [], i = 0; i < 12; a.push(Date.getShortMonthName(i)), ++i); // get localised short month names


        return Ext.applyIf({
          s: "(" + a.join("|") + ")"
        }, $f("F"));
      },
      m: {
        g: 1,
        c: "m = parseInt(results[{0}], 10) - 1;\n",
        s: "(\\d{2})" // month number with leading zeros (01 - 12)

      },
      n: {
        g: 1,
        c: "m = parseInt(results[{0}], 10) - 1;\n",
        s: "(\\d{1,2})" // month number without leading zeros (1 - 12)

      },
      t: {
        g: 0,
        c: null,
        s: "(?:\\d{2})" // no. of days in the month (28 - 31)

      },
      L: {
        g: 0,
        c: null,
        s: "(?:1|0)"
      },
      o: function o() {
        return $f("Y");
      },
      Y: {
        g: 1,
        c: "y = parseInt(results[{0}], 10);\n",
        s: "(\\d{4})" // 4-digit year

      },
      y: {
        g: 1,
        c: "var ty = parseInt(results[{0}], 10);\n" + "y = ty > Date.y2kYear ? 1900 + ty : 2000 + ty;\n",
        // 2-digit year
        s: "(\\d{1,2})"
      },
      a: {
        g: 1,
        c: "if (results[{0}] == 'am') {\n" + "if (!h || h == 12) { h = 0; }\n" + "} else { if (!h || h < 12) { h = (h || 0) + 12; }}",
        s: "(am|pm)"
      },
      A: {
        g: 1,
        c: "if (results[{0}] == 'AM') {\n" + "if (!h || h == 12) { h = 0; }\n" + "} else { if (!h || h < 12) { h = (h || 0) + 12; }}",
        s: "(AM|PM)"
      },
      g: function g() {
        return $f("G");
      },
      G: {
        g: 1,
        c: "h = parseInt(results[{0}], 10);\n",
        s: "(\\d{1,2})" // 24-hr format of an hour without leading zeroes (0 - 23)

      },
      h: function h() {
        return $f("H");
      },
      H: {
        g: 1,
        c: "h = parseInt(results[{0}], 10);\n",
        s: "(\\d{2})" //  24-hr format of an hour with leading zeroes (00 - 23)

      },
      i: {
        g: 1,
        c: "i = parseInt(results[{0}], 10);\n",
        s: "(\\d{2})" // minutes with leading zeros (00 - 59)

      },
      s: {
        g: 1,
        c: "s = parseInt(results[{0}], 10);\n",
        s: "(\\d{2})" // seconds with leading zeros (00 - 59)

      },
      u: {
        g: 1,
        c: "ms = results[{0}]; ms = parseInt(ms, 10)/Math.pow(10, ms.length - 3);\n",
        s: "(\\d+)" // decimal fraction of a second (minimum = 1 digit, maximum = unlimited)

      },
      O: {
        g: 1,
        c: ["o = results[{0}];", "var sn = o.substring(0,1),", // get + / - sign
        "hr = o.substring(1,3)*1 + Math.floor(o.substring(3,5) / 60),", // get hours (performs minutes-to-hour conversion also, just in case)
        "mn = o.substring(3,5) % 60;", // get minutes
        "o = ((-12 <= (hr*60 + mn)/60) && ((hr*60 + mn)/60 <= 14))? (sn + String.leftPad(hr, 2, '0') + String.leftPad(mn, 2, '0')) : null;\n" // -12hrs <= GMT offset <= 14hrs
        ].join("\n"),
        s: "([+\-]\\d{4})" // GMT offset in hrs and mins

      },
      P: {
        g: 1,
        c: ["o = results[{0}];", "var sn = o.substring(0,1),", // get + / - sign
        "hr = o.substring(1,3)*1 + Math.floor(o.substring(4,6) / 60),", // get hours (performs minutes-to-hour conversion also, just in case)
        "mn = o.substring(4,6) % 60;", // get minutes
        "o = ((-12 <= (hr*60 + mn)/60) && ((hr*60 + mn)/60 <= 14))? (sn + String.leftPad(hr, 2, '0') + String.leftPad(mn, 2, '0')) : null;\n" // -12hrs <= GMT offset <= 14hrs
        ].join("\n"),
        s: "([+\-]\\d{2}:\\d{2})" // GMT offset in hrs and mins (with colon separator)

      },
      T: {
        g: 0,
        c: null,
        s: "[A-Z]{1,4}" // timezone abbrev. may be between 1 - 4 chars

      },
      Z: {
        g: 1,
        c: "zz = results[{0}] * 1;\n" // -43200 <= UTC offset <= 50400
        + "zz = (-43200 <= zz && zz <= 50400)? zz : null;\n",
        s: "([+\-]?\\d{1,5})" // leading '+' sign is optional for UTC offset

      },
      c: function c() {
        var calc = [],
            arr = [$f("Y", 1), // year
        $f("m", 2), // month
        $f("d", 3), // day
        $f("h", 4), // hour
        $f("i", 5), // minute
        $f("s", 6), // second
        {
          c: "ms = results[7] || '0'; ms = parseInt(ms, 10)/Math.pow(10, ms.length - 3);\n"
        }, // decimal fraction of a second (minimum = 1 digit, maximum = unlimited)
        {
          c: [// allow either "Z" (i.e. UTC) or "-0530" or "+08:00" (i.e. UTC offset) timezone delimiters. assumes local timezone if no timezone is specified
          "if(results[8]) {", // timezone specified
          "if(results[8] == 'Z'){", "zz = 0;", // UTC
          "}else if (results[8].indexOf(':') > -1){", $f("P", 8).c, // timezone offset with colon separator
          "}else{", $f("O", 8).c, // timezone offset without colon separator
          "}", "}"].join('\n')
        }];

        for (var i = 0, l = arr.length; i < l; ++i) {
          calc.push(arr[i].c);
        }

        return {
          g: 1,
          c: calc.join(""),
          s: [arr[0].s, // year (required)
          "(?:", "-", arr[1].s, // month (optional)
          "(?:", "-", arr[2].s, // day (optional)
          "(?:", "(?:T| )?", // time delimiter -- either a "T" or a single blank space
          arr[3].s, ":", arr[4].s, // hour AND minute, delimited by a single colon (optional). MUST be preceded by either a "T" or a single blank space
          "(?::", arr[5].s, ")?", // seconds (optional)
          "(?:(?:\\.|,)(\\d+))?", // decimal fraction of a second (e.g. ",12345" or ".98765") (optional)
          "(Z|(?:[-+]\\d{2}(?::)?\\d{2}))?", // "Z" (UTC) or "-0530" (UTC offset without colon delimiter) or "+08:00" (UTC offset with colon delimiter) (optional)
          ")?", ")?", ")?"].join("")
        };
      },
      U: {
        g: 1,
        c: "u = parseInt(results[{0}], 10);\n",
        s: "(-?\\d+)" // leading minus sign indicates seconds before UNIX epoch

      }
    }
  });
})();

Ext.apply(Date.prototype, {
  // private
  dateFormat: function dateFormat(format) {
    if (Date.formatFunctions[format] == null) {
      Date.createFormat(format);
    }

    return Date.formatFunctions[format].call(this);
  },

  /**
   * Get the timezone abbreviation of the current date (equivalent to the format specifier 'T').
   *
   * Note: The date string returned by the javascript Date object's toString() method varies
   * between browsers (e.g. FF vs IE) and system region settings (e.g. IE in Asia vs IE in America).
   * For a given date string e.g. "Thu Oct 25 2007 22:55:35 GMT+0800 (Malay Peninsula Standard Time)",
   * getTimezone() first tries to get the timezone abbreviation from between a pair of parentheses
   * (which may or may not be present), failing which it proceeds to get the timezone abbreviation
   * from the GMT offset portion of the date string.
   * @return {String} The abbreviated timezone name (e.g. 'CST', 'PDT', 'EDT', 'MPST' ...).
   */
  getTimezone: function getTimezone() {
    // the following list shows the differences between date strings from different browsers on a WinXP SP2 machine from an Asian locale:
    //
    // Opera  : "Thu, 25 Oct 2007 22:53:45 GMT+0800" -- shortest (weirdest) date string of the lot
    // Safari : "Thu Oct 25 2007 22:55:35 GMT+0800 (Malay Peninsula Standard Time)" -- value in parentheses always gives the correct timezone (same as FF)
    // FF     : "Thu Oct 25 2007 22:55:35 GMT+0800 (Malay Peninsula Standard Time)" -- value in parentheses always gives the correct timezone
    // IE     : "Thu Oct 25 22:54:35 UTC+0800 2007" -- (Asian system setting) look for 3-4 letter timezone abbrev
    // IE     : "Thu Oct 25 17:06:37 PDT 2007" -- (American system setting) look for 3-4 letter timezone abbrev
    //
    // this crazy regex attempts to guess the correct timezone abbreviation despite these differences.
    // step 1: (?:\((.*)\) -- find timezone in parentheses
    // step 2: ([A-Z]{1,4})(?:[\-+][0-9]{4})?(?: -?\d+)?) -- if nothing was found in step 1, find timezone from timezone offset portion of date string
    // step 3: remove all non uppercase characters found in step 1 and 2
    return this.toString().replace(/^.* (?:\((.*)\)|([A-Z]{1,4})(?:[\-+][0-9]{4})?(?: -?\d+)?)$/, "$1$2").replace(/[^A-Z]/g, "");
  },

  /**
   * Get the offset from GMT of the current date (equivalent to the format specifier 'O').
   * @param {Boolean} colon (optional) true to separate the hours and minutes with a colon (defaults to false).
   * @return {String} The 4-character offset string prefixed with + or - (e.g. '-0600').
   */
  getGMTOffset: function getGMTOffset(colon) {
    return (this.getTimezoneOffset() > 0 ? "-" : "+") + String.leftPad(Math.floor(Math.abs(this.getTimezoneOffset()) / 60), 2, "0") + (colon ? ":" : "") + String.leftPad(Math.abs(this.getTimezoneOffset() % 60), 2, "0");
  },

  /**
   * Get the numeric day number of the year, adjusted for leap year.
   * @return {Number} 0 to 364 (365 in leap years).
   */
  getDayOfYear: function getDayOfYear() {
    var num = 0,
        d = this.clone(),
        m = this.getMonth(),
        i;

    for (i = 0, d.setDate(1), d.setMonth(0); i < m; d.setMonth(++i)) {
      num += d.getDaysInMonth();
    }

    return num + this.getDate() - 1;
  },

  /**
   * Get the numeric ISO-8601 week number of the year.
   * (equivalent to the format specifier 'W', but without a leading zero).
   * @return {Number} 1 to 53
   */
  getWeekOfYear: function () {
    // adapted from http://www.merlyn.demon.co.uk/weekcalc.htm
    var ms1d = 864e5,
        // milliseconds in a day
    ms7d = 7 * ms1d; // milliseconds in a week

    return function () {
      // return a closure so constants get calculated only once
      var DC3 = Date.UTC(this.getFullYear(), this.getMonth(), this.getDate() + 3) / ms1d,
          // an Absolute Day Number
      AWN = Math.floor(DC3 / 7),
          // an Absolute Week Number
      Wyr = new Date(AWN * ms7d).getUTCFullYear();
      return AWN - Math.floor(Date.UTC(Wyr, 0, 7) / ms7d) + 1;
    };
  }(),

  /**
   * Checks if the current date falls within a leap year.
   * @return {Boolean} True if the current date falls within a leap year, false otherwise.
   */
  isLeapYear: function isLeapYear() {
    var year = this.getFullYear();
    return !!((year & 3) == 0 && (year % 100 || year % 400 == 0 && year));
  },

  /**
   * Get the first day of the current month, adjusted for leap year.  The returned value
   * is the numeric day index within the week (0-6) which can be used in conjunction with
   * the {@link #monthNames} array to retrieve the textual day name.
   * Example:
   * <pre><code>
  var dt = new Date('1/10/2007');
  document.write(Date.dayNames[dt.getFirstDayOfMonth()]); //output: 'Monday'
  </code></pre>
   * @return {Number} The day number (0-6).
   */
  getFirstDayOfMonth: function getFirstDayOfMonth() {
    var day = (this.getDay() - (this.getDate() - 1)) % 7;
    return day < 0 ? day + 7 : day;
  },

  /**
   * Get the last day of the current month, adjusted for leap year.  The returned value
   * is the numeric day index within the week (0-6) which can be used in conjunction with
   * the {@link #monthNames} array to retrieve the textual day name.
   * Example:
   * <pre><code>
  var dt = new Date('1/10/2007');
  document.write(Date.dayNames[dt.getLastDayOfMonth()]); //output: 'Wednesday'
  </code></pre>
   * @return {Number} The day number (0-6).
   */
  getLastDayOfMonth: function getLastDayOfMonth() {
    return this.getLastDateOfMonth().getDay();
  },

  /**
   * Get the date of the first day of the month in which this date resides.
   * @return {Date}
   */
  getFirstDateOfMonth: function getFirstDateOfMonth() {
    return new Date(this.getFullYear(), this.getMonth(), 1);
  },

  /**
   * Get the date of the last day of the month in which this date resides.
   * @return {Date}
   */
  getLastDateOfMonth: function getLastDateOfMonth() {
    return new Date(this.getFullYear(), this.getMonth(), this.getDaysInMonth());
  },

  /**
   * Get the number of days in the current month, adjusted for leap year.
   * @return {Number} The number of days in the month.
   */
  getDaysInMonth: function () {
    var daysInMonth = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
    return function () {
      // return a closure for efficiency
      var m = this.getMonth();
      return m == 1 && this.isLeapYear() ? 29 : daysInMonth[m];
    };
  }(),

  /**
   * Get the English ordinal suffix of the current day (equivalent to the format specifier 'S').
   * @return {String} 'st, 'nd', 'rd' or 'th'.
   */
  getSuffix: function getSuffix() {
    switch (this.getDate()) {
      case 1:
      case 21:
      case 31:
        return "st";

      case 2:
      case 22:
        return "nd";

      case 3:
      case 23:
        return "rd";

      default:
        return "th";
    }
  },

  /**
   * Creates and returns a new Date instance with the exact same date value as the called instance.
   * Dates are copied and passed by reference, so if a copied date variable is modified later, the original
   * variable will also be changed.  When the intention is to create a new variable that will not
   * modify the original instance, you should create a clone.
   *
   * Example of correctly cloning a date:
   * <pre><code>
  //wrong way:
  var orig = new Date('10/1/2006');
  var copy = orig;
  copy.setDate(5);
  document.write(orig);  //returns 'Thu Oct 05 2006'!
  //correct way:
  var orig = new Date('10/1/2006');
  var copy = orig.clone();
  copy.setDate(5);
  document.write(orig);  //returns 'Thu Oct 01 2006'
  </code></pre>
   * @return {Date} The new Date instance.
   */
  clone: function clone() {
    return new Date(this.getTime());
  },

  /**
   * Checks if the current date is affected by Daylight Saving Time (DST).
   * @return {Boolean} True if the current date is affected by DST.
   */
  isDST: function isDST() {
    // adapted from http://extjs.com/forum/showthread.php?p=247172#post247172
    // courtesy of @geoffrey.mcgill
    return new Date(this.getFullYear(), 0, 1).getTimezoneOffset() != this.getTimezoneOffset();
  },

  /**
   * Attempts to clear all time information from this Date by setting the time to midnight of the same day,
   * automatically adjusting for Daylight Saving Time (DST) where applicable.
   * (note: DST timezone information for the browser's host operating system is assumed to be up-to-date)
   * @param {Boolean} clone true to create a clone of this date, clear the time and return it (defaults to false).
   * @return {Date} this or the clone.
   */
  clearTime: function clearTime(clone) {
    if (clone) {
      return this.clone().clearTime();
    } // get current date before clearing time


    var d = this.getDate(); // clear time

    this.setHours(0);
    this.setMinutes(0);
    this.setSeconds(0);
    this.setMilliseconds(0);

    if (this.getDate() != d) {
      // account for DST (i.e. day of month changed when setting hour = 0)
      // note: DST adjustments are assumed to occur in multiples of 1 hour (this is almost always the case)
      // refer to http://www.timeanddate.com/time/aboutdst.html for the (rare) exceptions to this rule
      // increment hour until cloned date == current date
      for (var hr = 1, c = this.add(Date.HOUR, hr); c.getDate() != d; hr++, c = this.add(Date.HOUR, hr));

      this.setDate(d);
      this.setHours(c.getHours());
    }

    return this;
  },

  /**
   * Provides a convenient method for performing basic date arithmetic. This method
   * does not modify the Date instance being called - it creates and returns
   * a new Date instance containing the resulting date value.
   *
   * Examples:
   * <pre><code>
  // Basic usage:
  var dt = new Date('10/29/2006').add(Date.DAY, 5);
  document.write(dt); //returns 'Fri Nov 03 2006 00:00:00'
  // Negative values will be subtracted:
  var dt2 = new Date('10/1/2006').add(Date.DAY, -5);
  document.write(dt2); //returns 'Tue Sep 26 2006 00:00:00'
  // You can even chain several calls together in one line:
  var dt3 = new Date('10/1/2006').add(Date.DAY, 5).add(Date.HOUR, 8).add(Date.MINUTE, -30);
  document.write(dt3); //returns 'Fri Oct 06 2006 07:30:00'
  </code></pre>
   *
   * @param {String} interval A valid date interval enum value.
   * @param {Number} value The amount to add to the current date.
   * @return {Date} The new Date instance.
   */
  add: function add(interval, value) {
    var d = this.clone();
    if (!interval || value === 0) return d;

    switch (interval.toLowerCase()) {
      case Date.MILLI:
        d.setMilliseconds(this.getMilliseconds() + value);
        break;

      case Date.SECOND:
        d.setSeconds(this.getSeconds() + value);
        break;

      case Date.MINUTE:
        d.setMinutes(this.getMinutes() + value);
        break;

      case Date.HOUR:
        d.setHours(this.getHours() + value);
        break;

      case Date.DAY:
        d.setDate(this.getDate() + value);
        break;

      case Date.MONTH:
        var day = this.getDate();

        if (day > 28) {
          day = Math.min(day, this.getFirstDateOfMonth().add('mo', value).getLastDateOfMonth().getDate());
        }

        d.setDate(day);
        d.setMonth(this.getMonth() + value);
        break;

      case Date.YEAR:
        d.setFullYear(this.getFullYear() + value);
        break;
    }

    return d;
  },

  /**
   * Checks if this date falls on or between the given start and end dates.
   * @param {Date} start Start date
   * @param {Date} end End date
   * @return {Boolean} true if this date falls on or between the given start and end dates.
   */
  between: function between(start, end) {
    var t = this.getTime();
    return start.getTime() <= t && t <= end.getTime();
  }
});
/**
 * Formats a date given the supplied format string.
 * @param {String} format The format string.
 * @return {String} The formatted date.
 * @method format
 */

Date.prototype.format = Date.prototype.dateFormat; // private

if (Ext.isSafari && (navigator.userAgent.match(/WebKit\/(\d+)/)[1] || NaN) < 420) {
  Ext.apply(Date.prototype, {
    _xMonth: Date.prototype.setMonth,
    _xDate: Date.prototype.setDate,
    // Bug in Safari 1.3, 2.0 (WebKit build < 420)
    // Date.setMonth does not work consistently if iMonth is not 0-11
    setMonth: function setMonth(num) {
      if (num <= -1) {
        var n = Math.ceil(-num),
            back_year = Math.ceil(n / 12),
            month = n % 12 ? 12 - n % 12 : 0;
        this.setFullYear(this.getFullYear() - back_year);
        return this._xMonth(month);
      } else {
        return this._xMonth(num);
      }
    },
    // Bug in setDate() method (resolved in WebKit build 419.3, so to be safe we target Webkit builds < 420)
    // The parameter for Date.setDate() is converted to a signed byte integer in Safari
    // http://brianary.blogspot.com/2006/03/safari-date-bug.html
    setDate: function setDate(d) {
      // use setTime() to workaround setDate() bug
      // subtract current day of month in milliseconds, then add desired day of month in milliseconds
      return this.setTime(this.getTime() - (this.getDate() - d) * 864e5);
    }
  });
}
/* Some basic Date tests... (requires Firebug)

Date.parseDate('', 'c'); // call Date.parseDate() once to force computation of regex string so we can console.log() it
console.log('Insane Regex for "c" format: %o', Date.parseCodes.c.s); // view the insane regex for the "c" format specifier

// standard tests
console.group('Standard Date.parseDate() Tests');
    console.log('Date.parseDate("2009-01-05T11:38:56", "c")               = %o', Date.parseDate("2009-01-05T11:38:56", "c")); // assumes browser's timezone setting
    console.log('Date.parseDate("2009-02-04T12:37:55.001000", "c")        = %o', Date.parseDate("2009-02-04T12:37:55.001000", "c")); // assumes browser's timezone setting
    console.log('Date.parseDate("2009-03-03T13:36:54,101000Z", "c")       = %o', Date.parseDate("2009-03-03T13:36:54,101000Z", "c")); // UTC
    console.log('Date.parseDate("2009-04-02T14:35:53.901000-0530", "c")   = %o', Date.parseDate("2009-04-02T14:35:53.901000-0530", "c")); // GMT-0530
    console.log('Date.parseDate("2009-05-01T15:34:52,9876000+08:00", "c") = %o', Date.parseDate("2009-05-01T15:34:52,987600+08:00", "c")); // GMT+08:00
console.groupEnd();

// ISO-8601 format as specified in http://www.w3.org/TR/NOTE-datetime
// -- accepts ALL 6 levels of date-time granularity
console.group('ISO-8601 Granularity Test (see http://www.w3.org/TR/NOTE-datetime)');
    console.log('Date.parseDate("1997", "c")                              = %o', Date.parseDate("1997", "c")); // YYYY (e.g. 1997)
    console.log('Date.parseDate("1997-07", "c")                           = %o', Date.parseDate("1997-07", "c")); // YYYY-MM (e.g. 1997-07)
    console.log('Date.parseDate("1997-07-16", "c")                        = %o', Date.parseDate("1997-07-16", "c")); // YYYY-MM-DD (e.g. 1997-07-16)
    console.log('Date.parseDate("1997-07-16T19:20+01:00", "c")            = %o', Date.parseDate("1997-07-16T19:20+01:00", "c")); // YYYY-MM-DDThh:mmTZD (e.g. 1997-07-16T19:20+01:00)
    console.log('Date.parseDate("1997-07-16T19:20:30+01:00", "c")         = %o', Date.parseDate("1997-07-16T19:20:30+01:00", "c")); // YYYY-MM-DDThh:mm:ssTZD (e.g. 1997-07-16T19:20:30+01:00)
    console.log('Date.parseDate("1997-07-16T19:20:30.45+01:00", "c")      = %o', Date.parseDate("1997-07-16T19:20:30.45+01:00", "c")); // YYYY-MM-DDThh:mm:ss.sTZD (e.g. 1997-07-16T19:20:30.45+01:00)
    console.log('Date.parseDate("1997-07-16 19:20:30.45+01:00", "c")      = %o', Date.parseDate("1997-07-16 19:20:30.45+01:00", "c")); // YYYY-MM-DD hh:mm:ss.sTZD (e.g. 1997-07-16T19:20:30.45+01:00)
    console.log('Date.parseDate("1997-13-16T19:20:30.45+01:00", "c", true)= %o', Date.parseDate("1997-13-16T19:20:30.45+01:00", "c", true)); // strict date parsing with invalid month value
console.groupEnd();

//*/

/***/ }),
/* 739 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.MixedCollection
 * @extends Ext.util.Observable
 * A Collection class that maintains both numeric indexes and keys and exposes events.
 * @constructor
 * @param {Boolean} allowFunctions Specify <tt>true</tt> if the {@link #addAll}
 * function should add function references to the collection. Defaults to
 * <tt>false</tt>.
 * @param {Function} keyFn A function that can accept an item of the type(s) stored in this MixedCollection
 * and return the key value for that item.  This is used when available to look up the key on items that
 * were passed without an explicit key parameter to a MixedCollection method.  Passing this parameter is
 * equivalent to providing an implementation for the {@link #getKey} method.
 */
Ext.util.MixedCollection = function (allowFunctions, keyFn) {
  this.items = [];
  this.map = {};
  this.keys = [];
  this.length = 0;
  this.addEvents(
  /**
   * @event clear
   * Fires when the collection is cleared.
   */
  'clear',
  /**
   * @event add
   * Fires when an item is added to the collection.
   * @param {Number} index The index at which the item was added.
   * @param {Object} o The item added.
   * @param {String} key The key associated with the added item.
   */
  'add',
  /**
   * @event replace
   * Fires when an item is replaced in the collection.
   * @param {String} key he key associated with the new added.
   * @param {Object} old The item being replaced.
   * @param {Object} new The new item.
   */
  'replace',
  /**
   * @event remove
   * Fires when an item is removed from the collection.
   * @param {Object} o The item being removed.
   * @param {String} key (optional) The key associated with the removed item.
   */
  'remove', 'sort');
  this.allowFunctions = allowFunctions === true;

  if (keyFn) {
    this.getKey = keyFn;
  }

  Ext.util.MixedCollection.superclass.constructor.call(this);
};

Ext.extend(Ext.util.MixedCollection, Ext.util.Observable, {
  /**
   * @cfg {Boolean} allowFunctions Specify <tt>true</tt> if the {@link #addAll}
   * function should add function references to the collection. Defaults to
   * <tt>false</tt>.
   */
  allowFunctions: false,

  /**
   * Adds an item to the collection. Fires the {@link #add} event when complete.
   * @param {String} key <p>The key to associate with the item, or the new item.</p>
   * <p>If a {@link #getKey} implementation was specified for this MixedCollection,
   * or if the key of the stored items is in a property called <tt><b>id</b></tt>,
   * the MixedCollection will be able to <i>derive</i> the key for the new item.
   * In this case just pass the new item in this parameter.</p>
   * @param {Object} o The item to add.
   * @return {Object} The item added.
   */
  add: function add(key, o) {
    if (arguments.length == 1) {
      o = arguments[0];
      key = this.getKey(o);
    }

    if (typeof key != 'undefined' && key !== null) {
      var old = this.map[key];

      if (typeof old != 'undefined') {
        return this.replace(key, o);
      }

      this.map[key] = o;
    }

    this.length++;
    this.items.push(o);
    this.keys.push(key);
    this.fireEvent('add', this.length - 1, o, key);
    return o;
  },

  /**
    * MixedCollection has a generic way to fetch keys if you implement getKey.  The default implementation
    * simply returns <b><code>item.id</code></b> but you can provide your own implementation
    * to return a different value as in the following examples:<pre><code>
  // normal way
  var mc = new Ext.util.MixedCollection();
  mc.add(someEl.dom.id, someEl);
  mc.add(otherEl.dom.id, otherEl);
  //and so on
  // using getKey
  var mc = new Ext.util.MixedCollection();
  mc.getKey = function(el){
  return el.dom.id;
  };
  mc.add(someEl);
  mc.add(otherEl);
  // or via the constructor
  var mc = new Ext.util.MixedCollection(false, function(el){
  return el.dom.id;
  });
  mc.add(someEl);
  mc.add(otherEl);
   * </code></pre>
   * @param {Object} item The item for which to find the key.
   * @return {Object} The key for the passed item.
   */
  getKey: function getKey(o) {
    return o.id;
  },

  /**
   * Replaces an item in the collection. Fires the {@link #replace} event when complete.
   * @param {String} key <p>The key associated with the item to replace, or the replacement item.</p>
   * <p>If you supplied a {@link #getKey} implementation for this MixedCollection, or if the key
   * of your stored items is in a property called <tt><b>id</b></tt>, then the MixedCollection
   * will be able to <i>derive</i> the key of the replacement item. If you want to replace an item
   * with one having the same key value, then just pass the replacement item in this parameter.</p>
   * @param o {Object} o (optional) If the first parameter passed was a key, the item to associate
   * with that key.
   * @return {Object}  The new item.
   */
  replace: function replace(key, o) {
    if (arguments.length == 1) {
      o = arguments[0];
      key = this.getKey(o);
    }

    var old = this.map[key];

    if (typeof key == 'undefined' || key === null || typeof old == 'undefined') {
      return this.add(key, o);
    }

    var index = this.indexOfKey(key);
    this.items[index] = o;
    this.map[key] = o;
    this.fireEvent('replace', key, old, o);
    return o;
  },

  /**
   * Adds all elements of an Array or an Object to the collection.
   * @param {Object/Array} objs An Object containing properties which will be added
   * to the collection, or an Array of values, each of which are added to the collection.
   * Functions references will be added to the collection if <code>{@link #allowFunctions}</code>
   * has been set to <tt>true</tt>.
   */
  addAll: function addAll(objs) {
    if (arguments.length > 1 || Ext.isArray(objs)) {
      var args = arguments.length > 1 ? arguments : objs;

      for (var i = 0, len = args.length; i < len; i++) {
        this.add(args[i]);
      }
    } else {
      for (var key in objs) {
        if (this.allowFunctions || typeof objs[key] != 'function') {
          this.add(key, objs[key]);
        }
      }
    }
  },

  /**
   * Executes the specified function once for every item in the collection, passing the following arguments:
   * <div class="mdetail-params"><ul>
   * <li><b>item</b> : Mixed<p class="sub-desc">The collection item</p></li>
   * <li><b>index</b> : Number<p class="sub-desc">The item's index</p></li>
   * <li><b>length</b> : Number<p class="sub-desc">The total number of items in the collection</p></li>
   * </ul></div>
   * The function should return a boolean value. Returning false from the function will stop the iteration.
   * @param {Function} fn The function to execute for each item.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the current item in the iteration.
   */
  each: function each(fn, scope) {
    var items = [].concat(this.items); // each safe for removal

    for (var i = 0, len = items.length; i < len; i++) {
      if (fn.call(scope || items[i], items[i], i, len) === false) {
        break;
      }
    }
  },

  /**
   * Executes the specified function once for every key in the collection, passing each
   * key, and its associated item as the first two parameters.
   * @param {Function} fn The function to execute for each item.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the browser window.
   */
  eachKey: function eachKey(fn, scope) {
    for (var i = 0, len = this.keys.length; i < len; i++) {
      fn.call(scope || window, this.keys[i], this.items[i], i, len);
    }
  },

  /**
   * Returns the first item in the collection which elicits a true return value from the
   * passed selection function.
   * @param {Function} fn The selection function to execute for each item.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the browser window.
   * @return {Object} The first item in the collection which returned true from the selection function.
   */
  find: function find(fn, scope) {
    for (var i = 0, len = this.items.length; i < len; i++) {
      if (fn.call(scope || window, this.items[i], this.keys[i])) {
        return this.items[i];
      }
    }

    return null;
  },

  /**
   * Inserts an item at the specified index in the collection. Fires the {@link #add} event when complete.
   * @param {Number} index The index to insert the item at.
   * @param {String} key The key to associate with the new item, or the item itself.
   * @param {Object} o (optional) If the second parameter was a key, the new item.
   * @return {Object} The item inserted.
   */
  insert: function insert(index, key, o) {
    if (arguments.length == 2) {
      o = arguments[1];
      key = this.getKey(o);
    }

    if (this.containsKey(key)) {
      this.suspendEvents();
      this.removeKey(key);
      this.resumeEvents();
    }

    if (index >= this.length) {
      return this.add(key, o);
    }

    this.length++;
    this.items.splice(index, 0, o);

    if (typeof key != 'undefined' && key !== null) {
      this.map[key] = o;
    }

    this.keys.splice(index, 0, key);
    this.fireEvent('add', index, o, key);
    return o;
  },

  /**
   * Remove an item from the collection.
   * @param {Object} o The item to remove.
   * @return {Object} The item removed or false if no item was removed.
   */
  remove: function remove(o) {
    return this.removeAt(this.indexOf(o));
  },

  /**
   * Remove an item from a specified index in the collection. Fires the {@link #remove} event when complete.
   * @param {Number} index The index within the collection of the item to remove.
   * @return {Object} The item removed or false if no item was removed.
   */
  removeAt: function removeAt(index) {
    if (index < this.length && index >= 0) {
      this.length--;
      var o = this.items[index];
      this.items.splice(index, 1);
      var key = this.keys[index];

      if (typeof key != 'undefined') {
        delete this.map[key];
      }

      this.keys.splice(index, 1);
      this.fireEvent('remove', o, key);
      return o;
    }

    return false;
  },

  /**
   * Removed an item associated with the passed key fom the collection.
   * @param {String} key The key of the item to remove.
   * @return {Object} The item removed or false if no item was removed.
   */
  removeKey: function removeKey(key) {
    return this.removeAt(this.indexOfKey(key));
  },

  /**
   * Returns the number of items in the collection.
   * @return {Number} the number of items in the collection.
   */
  getCount: function getCount() {
    return this.length;
  },

  /**
   * Returns index within the collection of the passed Object.
   * @param {Object} o The item to find the index of.
   * @return {Number} index of the item. Returns -1 if not found.
   */
  indexOf: function indexOf(o) {
    return this.items.indexOf(o);
  },

  /**
   * Returns index within the collection of the passed key.
   * @param {String} key The key to find the index of.
   * @return {Number} index of the key.
   */
  indexOfKey: function indexOfKey(key) {
    return this.keys.indexOf(key);
  },

  /**
   * Returns the item associated with the passed key OR index.
   * Key has priority over index.  This is the equivalent
   * of calling {@link #key} first, then if nothing matched calling {@link #itemAt}.
   * @param {String/Number} key The key or index of the item.
   * @return {Object} If the item is found, returns the item.  If the item was not found, returns <tt>undefined</tt>.
   * If an item was found, but is a Class, returns <tt>null</tt>.
   */
  item: function item(key) {
    var mk = this.map[key],
        item = mk !== undefined ? mk : typeof key == 'number' ? this.items[key] : undefined;
    return !Ext.isFunction(item) || this.allowFunctions ? item : null; // for prototype!
  },

  /**
   * Returns the item at the specified index.
   * @param {Number} index The index of the item.
   * @return {Object} The item at the specified index.
   */
  itemAt: function itemAt(index) {
    return this.items[index];
  },

  /**
   * Returns the item associated with the passed key.
   * @param {String/Number} key The key of the item.
   * @return {Object} The item associated with the passed key.
   */
  key: function key(_key) {
    return this.map[_key];
  },

  /**
   * Returns true if the collection contains the passed Object as an item.
   * @param {Object} o  The Object to look for in the collection.
   * @return {Boolean} True if the collection contains the Object as an item.
   */
  contains: function contains(o) {
    return this.indexOf(o) != -1;
  },

  /**
   * Returns true if the collection contains the passed Object as a key.
   * @param {String} key The key to look for in the collection.
   * @return {Boolean} True if the collection contains the Object as a key.
   */
  containsKey: function containsKey(key) {
    return typeof this.map[key] != 'undefined';
  },

  /**
   * Removes all items from the collection.  Fires the {@link #clear} event when complete.
   */
  clear: function clear() {
    this.length = 0;
    this.items = [];
    this.keys = [];
    this.map = {};
    this.fireEvent('clear');
  },

  /**
   * Returns the first item in the collection.
   * @return {Object} the first item in the collection..
   */
  first: function first() {
    return this.items[0];
  },

  /**
   * Returns the last item in the collection.
   * @return {Object} the last item in the collection..
   */
  last: function last() {
    return this.items[this.length - 1];
  },

  /**
   * @private
   * @param {String} property Property to sort by ('key', 'value', or 'index')
   * @param {String} dir (optional) Direction to sort 'ASC' or 'DESC'. Defaults to 'ASC'.
   * @param {Function} fn (optional) Comparison function that defines the sort order.
   * Defaults to sorting by numeric value.
   */
  _sort: function _sort(property, dir, fn) {
    var i,
        len,
        dsc = String(dir).toUpperCase() == 'DESC' ? -1 : 1,
        c = [],
        k = this.keys,
        items = this.items;

    fn = fn || function (a, b) {
      return a - b;
    };

    for (i = 0, len = items.length; i < len; i++) {
      c[c.length] = {
        key: k[i],
        value: items[i],
        index: i
      };
    }

    c.sort(function (a, b) {
      var v = fn(a[property], b[property]) * dsc;

      if (v === 0) {
        v = a.index < b.index ? -1 : 1;
      }

      return v;
    });

    for (i = 0, len = c.length; i < len; i++) {
      items[i] = c[i].value;
      k[i] = c[i].key;
    }

    this.fireEvent('sort', this);
  },

  /**
   * Sorts this collection by <b>item</b> value with the passed comparison function.
   * @param {String} direction (optional) 'ASC' or 'DESC'. Defaults to 'ASC'.
   * @param {Function} fn (optional) Comparison function that defines the sort order.
   * Defaults to sorting by numeric value.
   */
  sort: function sort(dir, fn) {
    this._sort('value', dir, fn);
  },

  /**
   * Sorts this collection by <b>key</b>s.
   * @param {String} direction (optional) 'ASC' or 'DESC'. Defaults to 'ASC'.
   * @param {Function} fn (optional) Comparison function that defines the sort order.
   * Defaults to sorting by case insensitive string.
   */
  keySort: function keySort(dir, fn) {
    this._sort('key', dir, fn || function (a, b) {
      var v1 = String(a).toUpperCase(),
          v2 = String(b).toUpperCase();
      return v1 > v2 ? 1 : v1 < v2 ? -1 : 0;
    });
  },

  /**
   * Returns a range of items in this collection
   * @param {Number} startIndex (optional) The starting index. Defaults to 0.
   * @param {Number} endIndex (optional) The ending index. Defaults to the last item.
   * @return {Array} An array of items
   */
  getRange: function getRange(start, end) {
    var items = this.items;

    if (items.length < 1) {
      return [];
    }

    start = start || 0;
    end = Math.min(typeof end == 'undefined' ? this.length - 1 : end, this.length - 1);
    var i,
        r = [];

    if (start <= end) {
      for (i = start; i <= end; i++) {
        r[r.length] = items[i];
      }
    } else {
      for (i = start; i >= end; i--) {
        r[r.length] = items[i];
      }
    }

    return r;
  },

  /**
   * Filter the <i>objects</i> in this collection by a specific property.
   * Returns a new collection that has been filtered.
   * @param {String} property A property on your objects
   * @param {String/RegExp} value Either string that the property values
   * should start with or a RegExp to test against the property
   * @param {Boolean} anyMatch (optional) True to match any part of the string, not just the beginning
   * @param {Boolean} caseSensitive (optional) True for case sensitive comparison (defaults to False).
   * @return {MixedCollection} The new filtered collection
   */
  filter: function filter(property, value, anyMatch, caseSensitive) {
    if (Ext.isEmpty(value, false)) {
      return this.clone();
    }

    value = this.createValueMatcher(value, anyMatch, caseSensitive);
    return this.filterBy(function (o) {
      return o && value.test(o[property]);
    });
  },

  /**
   * Filter by a function. Returns a <i>new</i> collection that has been filtered.
   * The passed function will be called with each object in the collection.
   * If the function returns true, the value is included otherwise it is filtered.
   * @param {Function} fn The function to be called, it will receive the args o (the object), k (the key)
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to this MixedCollection.
   * @return {MixedCollection} The new filtered collection
   */
  filterBy: function filterBy(fn, scope) {
    var r = new Ext.util.MixedCollection();
    r.getKey = this.getKey;
    var k = this.keys,
        it = this.items;

    for (var i = 0, len = it.length; i < len; i++) {
      if (fn.call(scope || this, it[i], k[i])) {
        r.add(k[i], it[i]);
      }
    }

    return r;
  },

  /**
   * Finds the index of the first matching object in this collection by a specific property/value.
   * @param {String} property The name of a property on your objects.
   * @param {String/RegExp} value A string that the property values
   * should start with or a RegExp to test against the property.
   * @param {Number} start (optional) The index to start searching at (defaults to 0).
   * @param {Boolean} anyMatch (optional) True to match any part of the string, not just the beginning.
   * @param {Boolean} caseSensitive (optional) True for case sensitive comparison.
   * @return {Number} The matched index or -1
   */
  findIndex: function findIndex(property, value, start, anyMatch, caseSensitive) {
    if (Ext.isEmpty(value, false)) {
      return -1;
    }

    value = this.createValueMatcher(value, anyMatch, caseSensitive);
    return this.findIndexBy(function (o) {
      return o && value.test(o[property]);
    }, null, start);
  },

  /**
   * Find the index of the first matching object in this collection by a function.
   * If the function returns <i>true</i> it is considered a match.
   * @param {Function} fn The function to be called, it will receive the args o (the object), k (the key).
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to this MixedCollection.
   * @param {Number} start (optional) The index to start searching at (defaults to 0).
   * @return {Number} The matched index or -1
   */
  findIndexBy: function findIndexBy(fn, scope, start) {
    var k = this.keys,
        it = this.items;

    for (var i = start || 0, len = it.length; i < len; i++) {
      if (fn.call(scope || this, it[i], k[i])) {
        return i;
      }
    }

    return -1;
  },
  // private
  createValueMatcher: function createValueMatcher(value, anyMatch, caseSensitive, exactMatch) {
    if (!value.exec) {
      // not a regex
      var er = Ext.escapeRe;
      value = String(value);

      if (anyMatch === true) {
        value = er(value);
      } else {
        value = '^' + er(value);

        if (exactMatch === true) {
          value += '$';
        }
      }

      value = new RegExp(value, caseSensitive ? '' : 'i');
    }

    return value;
  },

  /**
   * Creates a shallow copy of this collection
   * @return {MixedCollection}
   */
  clone: function clone() {
    var r = new Ext.util.MixedCollection();
    var k = this.keys,
        it = this.items;

    for (var i = 0, len = it.length; i < len; i++) {
      r.add(k[i], it[i]);
    }

    r.getKey = this.getKey;
    return r;
  }
});
/**
 * This method calls {@link #item item()}.
 * Returns the item associated with the passed key OR index. Key has priority
 * over index.  This is the equivalent of calling {@link #key} first, then if
 * nothing matched calling {@link #itemAt}.
 * @param {String/Number} key The key or index of the item.
 * @return {Object} If the item is found, returns the item.  If the item was
 * not found, returns <tt>undefined</tt>. If an item was found, but is a Class,
 * returns <tt>null</tt>.
 */

Ext.util.MixedCollection.prototype.get = Ext.util.MixedCollection.prototype.item;

/***/ }),
/* 740 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.JSON
 * Modified version of Douglas Crockford"s json.js that doesn"t
 * mess with the Object prototype
 * http://www.json.org/js.html
 * @singleton
 */
Ext.util.JSON = new function () {
  var useHasOwn = !!{}.hasOwnProperty,
      isNative = function () {
    var useNative = null;
    return function () {
      if (useNative === null) {
        useNative = Ext.USE_NATIVE_JSON && window.JSON && JSON.toString() == '[object JSON]';
      }

      return useNative;
    };
  }(),
      pad = function pad(n) {
    return n < 10 ? "0" + n : n;
  },
      doDecode = function doDecode(json) {
    return eval("(" + json + ')');
  },
      doEncode = function doEncode(o) {
    if (!Ext.isDefined(o) || o === null) {
      return "null";
    } else if (Ext.isArray(o)) {
      return encodeArray(o);
    } else if (Ext.isDate(o)) {
      return Ext.util.JSON.encodeDate(o);
    } else if (Ext.isString(o)) {
      return encodeString(o);
    } else if (typeof o == "number") {
      //don't use isNumber here, since finite checks happen inside isNumber
      return isFinite(o) ? String(o) : "null";
    } else if (Ext.isBoolean(o)) {
      return String(o);
    } else {
      var a = ["{"],
          b,
          i,
          v;

      for (i in o) {
        // don't encode DOM objects
        if (!o.getElementsByTagName) {
          if (!useHasOwn || o.hasOwnProperty(i)) {
            v = o[i];

            switch (typeof v) {
              case "undefined":
              case "function":
              case "unknown":
                break;

              default:
                if (b) {
                  a.push(',');
                }

                a.push(doEncode(i), ":", v === null ? "null" : doEncode(v));
                b = true;
            }
          }
        }
      }

      a.push("}");
      return a.join("");
    }
  },
      m = {
    "\b": '\\b',
    "\t": '\\t',
    "\n": '\\n',
    "\f": '\\f',
    "\r": '\\r',
    '"': '\\"',
    "\\": '\\\\'
  },
      encodeString = function encodeString(s) {
    if (/["\\\x00-\x1f]/.test(s)) {
      return '"' + s.replace(/([\x00-\x1f\\"])/g, function (a, b) {
        var c = m[b];

        if (c) {
          return c;
        }

        c = b.charCodeAt();
        return "\\u00" + Math.floor(c / 16).toString(16) + (c % 16).toString(16);
      }) + '"';
    }

    return '"' + s + '"';
  },
      encodeArray = function encodeArray(o) {
    var a = ["["],
        b,
        i,
        l = o.length,
        v;

    for (i = 0; i < l; i += 1) {
      v = o[i];

      switch (typeof v) {
        case "undefined":
        case "function":
        case "unknown":
          break;

        default:
          if (b) {
            a.push(',');
          }

          a.push(v === null ? "null" : Ext.util.JSON.encode(v));
          b = true;
      }
    }

    a.push("]");
    return a.join("");
  };
  /**
   * <p>Encodes a Date. This returns the actual string which is inserted into the JSON string as the literal expression.
   * <b>The returned value includes enclosing double quotation marks.</b></p>
   * <p>The default return format is "yyyy-mm-ddThh:mm:ss".</p>
   * <p>To override this:</p><pre><code>
  Ext.util.JSON.encodeDate = function(d) {
  return d.format('"Y-m-d"');
  };
  </code></pre>
   * @param {Date} d The Date to encode
   * @return {String} The string literal to use in a JSON string.
   */


  this.encodeDate = function (o) {
    return '"' + o.getFullYear() + "-" + pad(o.getMonth() + 1) + "-" + pad(o.getDate()) + "T" + pad(o.getHours()) + ":" + pad(o.getMinutes()) + ":" + pad(o.getSeconds()) + '"';
  };
  /**
   * Encodes an Object, Array or other value
   * @param {Mixed} o The variable to encode
   * @return {String} The JSON string
   */


  this.encode = function () {
    var ec;
    return function (o) {
      if (!ec) {
        // setup encoding function on first access
        ec = isNative() ? JSON.stringify : doEncode;
      }

      return ec(o);
    };
  }();
  /**
   * Decodes (parses) a JSON string to an object. If the JSON is invalid, this function throws a SyntaxError unless the safe option is set.
   * @param {String} json The JSON string
   * @return {Object} The resulting object
   */


  this.decode = function () {
    var dc;
    return function (json) {
      if (!dc) {
        // setup decoding function on first access
        dc = isNative() ? JSON.parse : doDecode;
      }

      return dc(json);
    };
  }();
}();
/**
 * Shorthand for {@link Ext.util.JSON#encode}
 * @param {Mixed} o The variable to encode
 * @return {String} The JSON string
 * @member Ext
 * @method encode
 */

Ext.encode = Ext.util.JSON.encode;
/**
 * Shorthand for {@link Ext.util.JSON#decode}
 * @param {String} json The JSON string
 * @param {Boolean} safe (optional) Whether to return null or throw an exception if the JSON is invalid.
 * @return {Object} The resulting object
 * @member Ext
 * @method decode
 */

Ext.decode = Ext.util.JSON.decode;

/***/ }),
/* 741 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.Format
 * Reusable data formatting functions
 * @singleton
 */
Ext.util.Format = function () {
  var trimRe = /^\s+|\s+$/g,
      stripTagsRE = /<\/?[^>]+>/gi,
      stripScriptsRe = /(?:<script.*?>)((\n|\r|.)*?)(?:<\/script>)/ig,
      nl2brRe = /\r?\n/g;
  return {
    /**
     * Truncate a string and add an ellipsis ('...') to the end if it exceeds the specified length
     * @param {String} value The string to truncate
     * @param {Number} length The maximum length to allow before truncating
     * @param {Boolean} word True to try to find a common work break
     * @return {String} The converted text
     */
    ellipsis: function ellipsis(value, len, word) {
      if (value && value.length > len) {
        if (word) {
          var vs = value.substr(0, len - 2),
              index = Math.max(vs.lastIndexOf(' '), vs.lastIndexOf('.'), vs.lastIndexOf('!'), vs.lastIndexOf('?'));

          if (index == -1 || index < len - 15) {
            return value.substr(0, len - 3) + "...";
          } else {
            return vs.substr(0, index) + "...";
          }
        } else {
          return value.substr(0, len - 3) + "...";
        }
      }

      return value;
    },

    /**
     * Checks a reference and converts it to empty string if it is undefined
     * @param {Mixed} value Reference to check
     * @return {Mixed} Empty string if converted, otherwise the original value
     */
    undef: function undef(value) {
      return value !== undefined ? value : "";
    },

    /**
     * Checks a reference and converts it to the default value if it's empty
     * @param {Mixed} value Reference to check
     * @param {String} defaultValue The value to insert of it's undefined (defaults to "")
     * @return {String}
     */
    defaultValue: function defaultValue(value, _defaultValue) {
      return value !== undefined && value !== '' ? value : _defaultValue;
    },

    /**
     * Convert certain characters (&, <, >, and ') to their HTML character equivalents for literal display in web pages.
     * @param {String} value The string to encode
     * @return {String} The encoded text
     */
    htmlEncode: function htmlEncode(value) {
      return !value ? value : String(value).replace(/&/g, "&amp;").replace(/>/g, "&gt;").replace(/</g, "&lt;").replace(/"/g, "&quot;");
    },

    /**
     * Convert certain characters (&, <, >, and ') from their HTML character equivalents.
     * @param {String} value The string to decode
     * @return {String} The decoded text
     */
    htmlDecode: function htmlDecode(value) {
      return !value ? value : String(value).replace(/&gt;/g, ">").replace(/&lt;/g, "<").replace(/&quot;/g, '"').replace(/&amp;/g, "&");
    },

    /**
     * Trims any whitespace from either side of a string
     * @param {String} value The text to trim
     * @return {String} The trimmed text
     */
    trim: function trim(value) {
      return String(value).replace(trimRe, "");
    },

    /**
     * Returns a substring from within an original string
     * @param {String} value The original text
     * @param {Number} start The start index of the substring
     * @param {Number} length The length of the substring
     * @return {String} The substring
     */
    substr: function substr(value, start, length) {
      return String(value).substr(start, length);
    },

    /**
     * Converts a string to all lower case letters
     * @param {String} value The text to convert
     * @return {String} The converted text
     */
    lowercase: function lowercase(value) {
      return String(value).toLowerCase();
    },

    /**
     * Converts a string to all upper case letters
     * @param {String} value The text to convert
     * @return {String} The converted text
     */
    uppercase: function uppercase(value) {
      return String(value).toUpperCase();
    },

    /**
     * Converts the first character only of a string to upper case
     * @param {String} value The text to convert
     * @return {String} The converted text
     */
    capitalize: function capitalize(value) {
      return !value ? value : value.charAt(0).toUpperCase() + value.substr(1).toLowerCase();
    },
    // private
    call: function call(value, fn) {
      if (arguments.length > 2) {
        var args = Array.prototype.slice.call(arguments, 2);
        args.unshift(value);
        return eval(fn).apply(window, args);
      } else {
        return eval(fn).call(window, value);
      }
    },

    /**
     * Format a number as US currency
     * @param {Number/String} value The numeric value to format
     * @return {String} The formatted currency string
     */
    usMoney: function usMoney(v) {
      v = Math.round((v - 0) * 100) / 100;
      v = v == Math.floor(v) ? v + ".00" : v * 10 == Math.floor(v * 10) ? v + "0" : v;
      v = String(v);
      var ps = v.split('.'),
          whole = ps[0],
          sub = ps[1] ? '.' + ps[1] : '.00',
          r = /(\d+)(\d{3})/;

      while (r.test(whole)) {
        whole = whole.replace(r, '$1' + ',' + '$2');
      }

      v = whole + sub;

      if (v.charAt(0) == '-') {
        return '-$' + v.substr(1);
      }

      return "$" + v;
    },

    /**
     * Parse a value into a formatted date using the specified format pattern.
     * @param {String/Date} value The value to format (Strings must conform to the format expected by the javascript Date object's <a href="http://www.w3schools.com/jsref/jsref_parse.asp">parse()</a> method)
     * @param {String} format (optional) Any valid date format string (defaults to 'm/d/Y')
     * @return {String} The formatted date string
     */
    date: function date(v, format) {
      if (!v) {
        return "";
      }

      if (!Ext.isDate(v)) {
        v = new Date(Date.parse(v));
      }

      return v.dateFormat(format || "m/d/Y");
    },

    /**
     * Returns a date rendering function that can be reused to apply a date format multiple times efficiently
     * @param {String} format Any valid date format string
     * @return {Function} The date formatting function
     */
    dateRenderer: function dateRenderer(format) {
      return function (v) {
        return Ext.util.Format.date(v, format);
      };
    },

    /**
     * Strips all HTML tags
     * @param {Mixed} value The text from which to strip tags
     * @return {String} The stripped text
     */
    stripTags: function stripTags(v) {
      return !v ? v : String(v).replace(stripTagsRE, "");
    },

    /**
     * Strips all script tags
     * @param {Mixed} value The text from which to strip script tags
     * @return {String} The stripped text
     */
    stripScripts: function stripScripts(v) {
      return !v ? v : String(v).replace(stripScriptsRe, "");
    },

    /**
     * Simple format for a file size (xxx bytes, xxx KB, xxx MB)
     * @param {Number/String} size The numeric value to format
     * @return {String} The formatted file size
     */
    fileSize: function fileSize(size) {
      if (size < 1024) {
        return size + " bytes";
      } else if (size < 1048576) {
        return Math.round(size * 10 / 1024) / 10 + " KB";
      } else {
        return Math.round(size * 10 / 1048576) / 10 + " MB";
      }
    },

    /**
     * It does simple math for use in a template, for example:<pre><code>
     * var tpl = new Ext.Template('{value} * 10 = {value:math("* 10")}');
     * </code></pre>
     * @return {Function} A function that operates on the passed value.
     */
    math: function () {
      var fns = {};
      return function (v, a) {
        if (!fns[a]) {
          fns[a] = new Function('v', 'return v ' + a + ';');
        }

        return fns[a](v);
      };
    }(),

    /**
     * Rounds the passed number to the required decimal precision.
     * @param {Number/String} value The numeric value to round.
     * @param {Number} precision The number of decimal places to which to round the first parameter's value.
     * @return {Number} The rounded value.
     */
    round: function round(value, precision) {
      var result = Number(value);

      if (typeof precision == 'number') {
        precision = Math.pow(10, precision);
        result = Math.round(value * precision) / precision;
      }

      return result;
    },

    /**
     * Formats the number according to the format string.
     * <div style="margin-left:40px">examples (123456.789):
     * <div style="margin-left:10px">
     * 0 - (123456) show only digits, no precision<br>
     * 0.00 - (123456.78) show only digits, 2 precision<br>
     * 0.0000 - (123456.7890) show only digits, 4 precision<br>
     * 0,000 - (123,456) show comma and digits, no precision<br>
     * 0,000.00 - (123,456.78) show comma and digits, 2 precision<br>
     * 0,0.00 - (123,456.78) shortcut method, show comma and digits, 2 precision<br>
     * To reverse the grouping (,) and decimal (.) for international numbers, add /i to the end.
     * For example: 0.000,00/i
     * </div></div>
     * @param {Number} v The number to format.
     * @param {String} format The way you would like to format this text.
     * @return {String} The formatted number.
     */
    number: function number(v, format) {
      if (!format) {
        return v;
      }

      v = Ext.num(v, NaN);

      if (isNaN(v)) {
        return '';
      }

      var comma = ',',
          dec = '.',
          i18n = false,
          neg = v < 0;
      v = Math.abs(v);

      if (format.substr(format.length - 2) == '/i') {
        format = format.substr(0, format.length - 2);
        i18n = true;
        comma = '.';
        dec = ',';
      }

      var hasComma = format.indexOf(comma) != -1,
          psplit = (i18n ? format.replace(/[^\d\,]/g, '') : format.replace(/[^\d\.]/g, '')).split(dec);

      if (1 < psplit.length) {
        v = v.toFixed(psplit[1].length);
      } else if (2 < psplit.length) {
        throw 'NumberFormatException: invalid format, formats should have no more than 1 period: ' + format;
      } else {
        v = v.toFixed(0);
      }

      var fnum = v.toString();

      if (hasComma) {
        psplit = fnum.split('.');
        var cnum = psplit[0],
            parr = [],
            j = cnum.length,
            m = Math.floor(j / 3),
            n = cnum.length % 3 || 3;

        for (var i = 0; i < j; i += n) {
          if (i != 0) {
            n = 3;
          }

          parr[parr.length] = cnum.substr(i, n);
          m -= 1;
        }

        fnum = parr.join(comma);

        if (psplit[1]) {
          fnum += dec + psplit[1];
        }
      }

      return (neg ? '-' : '') + format.replace(/[\d,?\.?]+/, fnum);
    },

    /**
     * Returns a number rendering function that can be reused to apply a number format multiple times efficiently
     * @param {String} format Any valid number format string for {@link #number}
     * @return {Function} The number formatting function
     */
    numberRenderer: function numberRenderer(format) {
      return function (v) {
        return Ext.util.Format.number(v, format);
      };
    },

    /**
     * Selectively do a plural form of a word based on a numeric value. For example, in a template,
     * {commentCount:plural("Comment")}  would result in "1 Comment" if commentCount was 1 or would be "x Comments"
     * if the value is 0 or greater than 1.
     * @param {Number} value The value to compare against
     * @param {String} singular The singular form of the word
     * @param {String} plural (optional) The plural form of the word (defaults to the singular with an "s")
     */
    plural: function plural(v, s, p) {
      return v + ' ' + (v == 1 ? s : p ? p : s + 's');
    },

    /**
     * Converts newline characters to the HTML tag &lt;br/>
     * @param {String} The string value to format.
     * @return {String} The string with embedded &lt;br/> tags in place of newlines.
     */
    nl2br: function nl2br(v) {
      return Ext.isEmpty(v) ? '' : v.replace(nl2brRe, '<br/>');
    }
  };
}();

/***/ }),
/* 742 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.XTemplate
 * @extends Ext.Template
 * <p>A template class that supports advanced functionality like:<div class="mdetail-params"><ul>
 * <li>Autofilling arrays using templates and sub-templates</li>
 * <li>Conditional processing with basic comparison operators</li>
 * <li>Basic math function support</li>
 * <li>Execute arbitrary inline code with special built-in template variables</li>
 * <li>Custom member functions</li>
 * <li>Many special tags and built-in operators that aren't defined as part of
 * the API, but are supported in the templates that can be created</li>
 * </ul></div></p>
 * <p>XTemplate provides the templating mechanism built into:<div class="mdetail-params"><ul>
 * <li>{@link Ext.DataView}</li>
 * <li>{@link Ext.ListView}</li>
 * <li>{@link Ext.form.ComboBox}</li>
 * <li>{@link Ext.grid.TemplateColumn}</li>
 * <li>{@link Ext.grid.GroupingView}</li>
 * <li>{@link Ext.menu.Item}</li>
 * <li>{@link Ext.layout.MenuLayout}</li>
 * <li>{@link Ext.ColorPalette}</li>
 * </ul></div></p>
 * 
 * <p>For example usage {@link #XTemplate see the constructor}.</p>  
 *   
 * @constructor
 * The {@link Ext.Template#Template Ext.Template constructor} describes
 * the acceptable parameters to pass to the constructor. The following
 * examples demonstrate all of the supported features.</p>
 * 
 * <div class="mdetail-params"><ul>
 * 
 * <li><b><u>Sample Data</u></b> 
 * <div class="sub-desc">
 * <p>This is the data object used for reference in each code example:</p>
 * <pre><code>
var data = {
    name: 'Jack Slocum',
    title: 'Lead Developer',
    company: 'Ext JS, LLC',
    email: 'jack@extjs.com',
    address: '4 Red Bulls Drive',
    city: 'Cleveland',
    state: 'Ohio',
    zip: '44102',
    drinks: ['Red Bull', 'Coffee', 'Water'],
    kids: [{
        name: 'Sara Grace',
        age:3
    },{
        name: 'Zachary',
        age:2
    },{
        name: 'John James',
        age:0
    }]
};
 * </code></pre>
 * </div>
 * </li>
 * 
 * 
 * <li><b><u>Auto filling of arrays</u></b> 
 * <div class="sub-desc">
 * <p>The <b><tt>tpl</tt></b> tag and the <b><tt>for</tt></b> operator are used
 * to process the provided data object:
 * <ul>
 * <li>If the value specified in <tt>for</tt> is an array, it will auto-fill,
 * repeating the template block inside the <tt>tpl</tt> tag for each item in the
 * array.</li>
 * <li>If <tt>for="."</tt> is specified, the data object provided is examined.</li>
 * <li>While processing an array, the special variable <tt>{#}</tt>
 * will provide the current array index + 1 (starts at 1, not 0).</li>
 * </ul>
 * </p>
 * <pre><code>
&lt;tpl <b>for</b>=".">...&lt;/tpl>       // loop through array at root node
&lt;tpl <b>for</b>="foo">...&lt;/tpl>     // loop through array at foo node
&lt;tpl <b>for</b>="foo.bar">...&lt;/tpl> // loop through array at foo.bar node
 * </code></pre>
 * Using the sample data above:
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Kids: ',
    '&lt;tpl <b>for</b>=".">',       // process the data.kids node
        '&lt;p>{#}. {name}&lt;/p>',  // use current array index to autonumber
    '&lt;/tpl>&lt;/p>'
);
tpl.overwrite(panel.body, data.kids); // pass the kids property of the data object
 * </code></pre>
 * <p>An example illustrating how the <b><tt>for</tt></b> property can be leveraged
 * to access specified members of the provided data object to populate the template:</p>
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Name: {name}&lt;/p>',
    '&lt;p>Title: {title}&lt;/p>',
    '&lt;p>Company: {company}&lt;/p>',
    '&lt;p>Kids: ',
    '&lt;tpl <b>for="kids"</b>>',     // interrogate the kids property within the data
        '&lt;p>{name}&lt;/p>',
    '&lt;/tpl>&lt;/p>'
);
tpl.overwrite(panel.body, data);  // pass the root node of the data object
 * </code></pre>
 * <p>Flat arrays that contain values (and not objects) can be auto-rendered
 * using the special <b><tt>{.}</tt></b> variable inside a loop.  This variable
 * will represent the value of the array at the current index:</p>
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>{name}\&#39;s favorite beverages:&lt;/p>',
    '&lt;tpl for="drinks">',
       '&lt;div> - {.}&lt;/div>',
    '&lt;/tpl>'
);
tpl.overwrite(panel.body, data);
 * </code></pre>
 * <p>When processing a sub-template, for example while looping through a child array,
 * you can access the parent object's members via the <b><tt>parent</tt></b> object:</p>
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Name: {name}&lt;/p>',
    '&lt;p>Kids: ',
    '&lt;tpl for="kids">',
        '&lt;tpl if="age > 1">',
            '&lt;p>{name}&lt;/p>',
            '&lt;p>Dad: {<b>parent</b>.name}&lt;/p>',
        '&lt;/tpl>',
    '&lt;/tpl>&lt;/p>'
);
tpl.overwrite(panel.body, data);
 * </code></pre>
 * </div>
 * </li>
 * 
 * 
 * <li><b><u>Conditional processing with basic comparison operators</u></b> 
 * <div class="sub-desc">
 * <p>The <b><tt>tpl</tt></b> tag and the <b><tt>if</tt></b> operator are used
 * to provide conditional checks for deciding whether or not to render specific
 * parts of the template. Notes:<div class="sub-desc"><ul>
 * <li>Double quotes must be encoded if used within the conditional</li>
 * <li>There is no <tt>else</tt> operator &mdash; if needed, two opposite
 * <tt>if</tt> statements should be used.</li>
 * </ul></div>
 * <pre><code>
&lt;tpl if="age &gt; 1 &amp;&amp; age &lt; 10">Child&lt;/tpl>
&lt;tpl if="age >= 10 && age < 18">Teenager&lt;/tpl>
&lt;tpl <b>if</b>="this.isGirl(name)">...&lt;/tpl>
&lt;tpl <b>if</b>="id==\'download\'">...&lt;/tpl>
&lt;tpl <b>if</b>="needsIcon">&lt;img src="{icon}" class="{iconCls}"/>&lt;/tpl>
// no good:
&lt;tpl if="name == "Jack"">Hello&lt;/tpl>
// encode &#34; if it is part of the condition, e.g.
&lt;tpl if="name == &#38;quot;Jack&#38;quot;">Hello&lt;/tpl>
 * </code></pre>
 * Using the sample data above:
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Name: {name}&lt;/p>',
    '&lt;p>Kids: ',
    '&lt;tpl for="kids">',
        '&lt;tpl if="age > 1">',
            '&lt;p>{name}&lt;/p>',
        '&lt;/tpl>',
    '&lt;/tpl>&lt;/p>'
);
tpl.overwrite(panel.body, data);
 * </code></pre>
 * </div>
 * </li>
 * 
 * 
 * <li><b><u>Basic math support</u></b> 
 * <div class="sub-desc">
 * <p>The following basic math operators may be applied directly on numeric
 * data values:</p><pre>
 * + - * /
 * </pre>
 * For example:
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Name: {name}&lt;/p>',
    '&lt;p>Kids: ',
    '&lt;tpl for="kids">',
        '&lt;tpl if="age &amp;gt; 1">',  // <-- Note that the &gt; is encoded
            '&lt;p>{#}: {name}&lt;/p>',  // <-- Auto-number each item
            '&lt;p>In 5 Years: {age+5}&lt;/p>',  // <-- Basic math
            '&lt;p>Dad: {parent.name}&lt;/p>',
        '&lt;/tpl>',
    '&lt;/tpl>&lt;/p>'
);
tpl.overwrite(panel.body, data);
</code></pre>
 * </div>
 * </li>
 *
 * 
 * <li><b><u>Execute arbitrary inline code with special built-in template variables</u></b> 
 * <div class="sub-desc">
 * <p>Anything between <code>{[ ... ]}</code> is considered code to be executed
 * in the scope of the template. There are some special variables available in that code:
 * <ul>
 * <li><b><tt>values</tt></b>: The values in the current scope. If you are using
 * scope changing sub-templates, you can change what <tt>values</tt> is.</li>
 * <li><b><tt>parent</tt></b>: The scope (values) of the ancestor template.</li>
 * <li><b><tt>xindex</tt></b>: If you are in a looping template, the index of the
 * loop you are in (1-based).</li>
 * <li><b><tt>xcount</tt></b>: If you are in a looping template, the total length
 * of the array you are looping.</li>
 * <li><b><tt>fm</tt></b>: An alias for <tt>Ext.util.Format</tt>.</li>
 * </ul>
 * This example demonstrates basic row striping using an inline code block and the
 * <tt>xindex</tt> variable:</p>
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Name: {name}&lt;/p>',
    '&lt;p>Company: {[values.company.toUpperCase() + ", " + values.title]}&lt;/p>',
    '&lt;p>Kids: ',
    '&lt;tpl for="kids">',
       '&lt;div class="{[xindex % 2 === 0 ? "even" : "odd"]}">',
        '{name}',
        '&lt;/div>',
    '&lt;/tpl>&lt;/p>'
);
tpl.overwrite(panel.body, data);
 * </code></pre>
 * </div>
 * </li>
 * 
 * <li><b><u>Template member functions</u></b> 
 * <div class="sub-desc">
 * <p>One or more member functions can be specified in a configuration
 * object passed into the XTemplate constructor for more complex processing:</p>
 * <pre><code>
var tpl = new Ext.XTemplate(
    '&lt;p>Name: {name}&lt;/p>',
    '&lt;p>Kids: ',
    '&lt;tpl for="kids">',
        '&lt;tpl if="this.isGirl(name)">',
            '&lt;p>Girl: {name} - {age}&lt;/p>',
        '&lt;/tpl>',
        // use opposite if statement to simulate 'else' processing:
        '&lt;tpl if="this.isGirl(name) == false">',
            '&lt;p>Boy: {name} - {age}&lt;/p>',
        '&lt;/tpl>',
        '&lt;tpl if="this.isBaby(age)">',
            '&lt;p>{name} is a baby!&lt;/p>',
        '&lt;/tpl>',
    '&lt;/tpl>&lt;/p>',
    {
        // XTemplate configuration:
        compiled: true,
        disableFormats: true,
        // member functions:
        isGirl: function(name){
            return name == 'Sara Grace';
        },
        isBaby: function(age){
            return age < 1;
        }
    }
);
tpl.overwrite(panel.body, data);
 * </code></pre>
 * </div>
 * </li>
 * 
 * </ul></div>
 * 
 * @param {Mixed} config
 */
Ext.XTemplate = function () {
  Ext.XTemplate.superclass.constructor.apply(this, arguments);
  var me = this,
      s = me.html,
      re = /<tpl\b[^>]*>((?:(?=([^<]+))\2|<(?!tpl\b[^>]*>))*?)<\/tpl>/,
      nameRe = /^<tpl\b[^>]*?for="(.*?)"/,
      ifRe = /^<tpl\b[^>]*?if="(.*?)"/,
      execRe = /^<tpl\b[^>]*?exec="(.*?)"/,
      m,
      id = 0,
      tpls = [],
      VALUES = 'values',
      PARENT = 'parent',
      XINDEX = 'xindex',
      XCOUNT = 'xcount',
      RETURN = 'return ',
      WITHVALUES = 'with(values){ ';
  s = ['<tpl>', s, '</tpl>'].join('');

  while (m = s.match(re)) {
    var m2 = m[0].match(nameRe),
        m3 = m[0].match(ifRe),
        m4 = m[0].match(execRe),
        exp = null,
        fn = null,
        exec = null,
        name = m2 && m2[1] ? m2[1] : '';

    if (m3) {
      exp = m3 && m3[1] ? m3[1] : null;

      if (exp) {
        fn = new Function(VALUES, PARENT, XINDEX, XCOUNT, WITHVALUES + RETURN + Ext.util.Format.htmlDecode(exp) + '; }');
      }
    }

    if (m4) {
      exp = m4 && m4[1] ? m4[1] : null;

      if (exp) {
        exec = new Function(VALUES, PARENT, XINDEX, XCOUNT, WITHVALUES + Ext.util.Format.htmlDecode(exp) + '; }');
      }
    }

    if (name) {
      switch (name) {
        case '.':
          name = new Function(VALUES, PARENT, WITHVALUES + RETURN + VALUES + '; }');
          break;

        case '..':
          name = new Function(VALUES, PARENT, WITHVALUES + RETURN + PARENT + '; }');
          break;

        default:
          name = new Function(VALUES, PARENT, WITHVALUES + RETURN + name + '; }');
      }
    }

    tpls.push({
      id: id,
      target: name,
      exec: exec,
      test: fn,
      body: m[1] || ''
    });
    s = s.replace(m[0], '{xtpl' + id + '}');
    ++id;
  }

  Ext.each(tpls, function (t) {
    me.compileTpl(t);
  });
  me.master = tpls[tpls.length - 1];
  me.tpls = tpls;
};

Ext.extend(Ext.XTemplate, Ext.Template, {
  // private
  re: /\{([\w-\.\#]+)(?:\:([\w\.]*)(?:\((.*?)?\))?)?(\s?[\+\-\*\\]\s?[\d\.\+\-\*\\\(\)]+)?\}/g,
  // private
  codeRe: /\{\[((?:\\\]|.|\n)*?)\]\}/g,
  // private
  applySubTemplate: function applySubTemplate(id, values, parent, xindex, xcount) {
    var me = this,
        len,
        t = me.tpls[id],
        vs,
        buf = [];

    if (t.test && !t.test.call(me, values, parent, xindex, xcount) || t.exec && t.exec.call(me, values, parent, xindex, xcount)) {
      return '';
    }

    vs = t.target ? t.target.call(me, values, parent) : values;
    len = vs.length;
    parent = t.target ? values : parent;

    if (t.target && Ext.isArray(vs)) {
      Ext.each(vs, function (v, i) {
        buf[buf.length] = t.compiled.call(me, v, parent, i + 1, len);
      });
      return buf.join('');
    }

    return t.compiled.call(me, vs, parent, xindex, xcount);
  },
  // private
  compileTpl: function compileTpl(tpl) {
    var fm = Ext.util.Format,
        useF = this.disableFormats !== true,
        sep = Ext.isGecko ? "+" : ",",
        body;

    function fn(m, name, format, args, math) {
      if (name.substr(0, 4) == 'xtpl') {
        return "'" + sep + 'this.applySubTemplate(' + name.substr(4) + ', values, parent, xindex, xcount)' + sep + "'";
      }

      var v;

      if (name === '.') {
        v = 'values';
      } else if (name === '#') {
        v = 'xindex';
      } else if (name.indexOf('.') != -1) {
        v = name;
      } else {
        v = "values['" + name + "']";
      }

      if (math) {
        v = '(' + v + math + ')';
      }

      if (format && useF) {
        args = args ? ',' + args : "";

        if (format.substr(0, 5) != "this.") {
          format = "fm." + format + '(';
        } else {
          format = 'this.call("' + format.substr(5) + '", ';
          args = ", values";
        }
      } else {
        args = '';
        format = "(" + v + " === undefined ? '' : ";
      }

      return "'" + sep + format + v + args + ")" + sep + "'";
    }

    function codeFn(m, code) {
      // Single quotes get escaped when the template is compiled, however we want to undo this when running code.
      return "'" + sep + '(' + code.replace(/\\'/g, "'") + ')' + sep + "'";
    } // branched to use + in gecko and [].join() in others


    if (Ext.isGecko) {
      body = "tpl.compiled = function(values, parent, xindex, xcount){ return '" + tpl.body.replace(/(\r\n|\n)/g, '\\n').replace(/'/g, "\\'").replace(this.re, fn).replace(this.codeRe, codeFn) + "';};";
    } else {
      body = ["tpl.compiled = function(values, parent, xindex, xcount){ return ['"];
      body.push(tpl.body.replace(/(\r\n|\n)/g, '\\n').replace(/'/g, "\\'").replace(this.re, fn).replace(this.codeRe, codeFn));
      body.push("'].join('');};");
      body = body.join('');
    }

    eval(body);
    return this;
  },

  /**
   * Returns an HTML fragment of this template with the specified values applied.
   * @param {Object} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
   * @return {String} The HTML fragment
   */
  applyTemplate: function applyTemplate(values) {
    return this.master.compiled.call(this, values, {}, 1, 1);
  },

  /**
   * Compile the template to a function for optimized performance.  Recommended if the template will be used frequently.
   * @return {Function} The compiled function
   */
  compile: function compile() {
    return this;
  }
  /**
   * @property re
   * @hide
   */

  /**
   * @property disableFormats
   * @hide
   */

  /**
   * @method set
   * @hide
   */

});
/**
 * Alias for {@link #applyTemplate}
 * Returns an HTML fragment of this template with the specified values applied.
 * @param {Object/Array} values The template values. Can be an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'})
 * @return {String} The HTML fragment
 * @member Ext.XTemplate
 * @method apply
 */

Ext.XTemplate.prototype.apply = Ext.XTemplate.prototype.applyTemplate;
/**
 * Creates a template from the passed element's value (<i>display:none</i> textarea, preferred) or innerHTML.
 * @param {String/HTMLElement} el A DOM element or its id
 * @return {Ext.Template} The created template
 * @static
 */

Ext.XTemplate.from = function (el) {
  el = Ext.getDom(el);
  return new Ext.XTemplate(el.value || el.innerHTML);
};

/***/ }),
/* 743 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.CSS
 * Utility class for manipulating CSS rules
 * @singleton
 */
Ext.util.CSS = function () {
  var rules = null;
  var doc = document;
  var camelRe = /(-[a-z])/gi;

  var camelFn = function camelFn(m, a) {
    return a.charAt(1).toUpperCase();
  };

  return {
    /**
     * Creates a stylesheet from a text blob of rules.
     * These rules will be wrapped in a STYLE tag and appended to the HEAD of the document.
     * @param {String} cssText The text containing the css rules
     * @param {String} id An id to add to the stylesheet for later removal
     * @return {StyleSheet}
     */
    createStyleSheet: function createStyleSheet(cssText, id) {
      var ss;
      var head = doc.getElementsByTagName("head")[0];
      var rules = doc.createElement("style");
      rules.setAttribute("type", "text/css");

      if (id) {
        rules.setAttribute("id", id);
      }

      if (Ext.isIE) {
        head.appendChild(rules);
        ss = rules.styleSheet;
        ss.cssText = cssText;
      } else {
        try {
          rules.appendChild(doc.createTextNode(cssText));
        } catch (e) {
          rules.cssText = cssText;
        }

        head.appendChild(rules);
        ss = rules.styleSheet ? rules.styleSheet : rules.sheet || doc.styleSheets[doc.styleSheets.length - 1];
      }

      this.cacheStyleSheet(ss);
      return ss;
    },

    /**
     * Removes a style or link tag by id
     * @param {String} id The id of the tag
     */
    removeStyleSheet: function removeStyleSheet(id) {
      var existing = doc.getElementById(id);

      if (existing) {
        existing.parentNode.removeChild(existing);
      }
    },

    /**
     * Dynamically swaps an existing stylesheet reference for a new one
     * @param {String} id The id of an existing link tag to remove
     * @param {String} url The href of the new stylesheet to include
     */
    swapStyleSheet: function swapStyleSheet(id, url) {
      this.removeStyleSheet(id);
      var ss = doc.createElement("link");
      ss.setAttribute("rel", "stylesheet");
      ss.setAttribute("type", "text/css");
      ss.setAttribute("id", id);
      ss.setAttribute("href", url);
      doc.getElementsByTagName("head")[0].appendChild(ss);
    },

    /**
     * Refresh the rule cache if you have dynamically added stylesheets
     * @return {Object} An object (hash) of rules indexed by selector
     */
    refreshCache: function refreshCache() {
      return this.getRules(true);
    },
    // private
    cacheStyleSheet: function cacheStyleSheet(ss) {
      if (!rules) {
        rules = {};
      }

      try {
        // try catch for cross domain access issue
        var ssRules = ss.cssRules || ss.rules;

        for (var j = ssRules.length - 1; j >= 0; --j) {
          rules[ssRules[j].selectorText.toLowerCase()] = ssRules[j];
        }
      } catch (e) {}
    },

    /**
     * Gets all css rules for the document
     * @param {Boolean} refreshCache true to refresh the internal cache
     * @return {Object} An object (hash) of rules indexed by selector
     */
    getRules: function getRules(refreshCache) {
      if (rules === null || refreshCache) {
        rules = {};
        var ds = doc.styleSheets;

        for (var i = 0, len = ds.length; i < len; i++) {
          try {
            this.cacheStyleSheet(ds[i]);
          } catch (e) {}
        }
      }

      return rules;
    },

    /**
    * Gets an an individual CSS rule by selector(s)
    * @param {String/Array} selector The CSS selector or an array of selectors to try. The first selector that is found is returned.
    * @param {Boolean} refreshCache true to refresh the internal cache if you have recently updated any rules or added styles dynamically
    * @return {CSSRule} The CSS rule or null if one is not found
    */
    getRule: function getRule(selector, refreshCache) {
      var rs = this.getRules(refreshCache);

      if (!Ext.isArray(selector)) {
        return rs[selector.toLowerCase()];
      }

      for (var i = 0; i < selector.length; i++) {
        if (rs[selector[i]]) {
          return rs[selector[i].toLowerCase()];
        }
      }

      return null;
    },

    /**
    * Updates a rule property
    * @param {String/Array} selector If it's an array it tries each selector until it finds one. Stops immediately once one is found.
    * @param {String} property The css property
    * @param {String} value The new value for the property
    * @return {Boolean} true If a rule was found and updated
    */
    updateRule: function updateRule(selector, property, value) {
      if (!Ext.isArray(selector)) {
        var rule = this.getRule(selector);

        if (rule) {
          rule.style[property.replace(camelRe, camelFn)] = value;
          return true;
        }
      } else {
        for (var i = 0; i < selector.length; i++) {
          if (this.updateRule(selector[i], property, value)) {
            return true;
          }
        }
      }

      return false;
    }
  };
}();

/***/ }),
/* 744 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 @class Ext.util.ClickRepeater
 @extends Ext.util.Observable

 A wrapper class which can be applied to any element. Fires a "click" event while the
 mouse is pressed. The interval between firings may be specified in the config but
 defaults to 20 milliseconds.

 Optionally, a CSS class may be applied to the element during the time it is pressed.

 @cfg {Mixed} el The element to act as a button.
 @cfg {Number} delay The initial delay before the repeating event begins firing.
 Similar to an autorepeat key delay.
 @cfg {Number} interval The interval between firings of the "click" event. Default 20 ms.
 @cfg {String} pressClass A CSS class name to be applied to the element while pressed.
 @cfg {Boolean} accelerate True if autorepeating should start slowly and accelerate.
           "interval" and "delay" are ignored.
 @cfg {Boolean} preventDefault True to prevent the default click event
 @cfg {Boolean} stopDefault True to stop the default click event

 @history
    2007-02-02 jvs Original code contributed by Nige "Animal" White
    2007-02-02 jvs Renamed to ClickRepeater
    2007-02-03 jvs Modifications for FF Mac and Safari

 @constructor
 @param {Mixed} el The element to listen on
 @param {Object} config
 */
Ext.util.ClickRepeater = function (el, config) {
  this.el = Ext.get(el);
  this.el.unselectable();
  Ext.apply(this, config);
  this.addEvents(
  /**
   * @event mousedown
   * Fires when the mouse button is depressed.
   * @param {Ext.util.ClickRepeater} this
   */
  "mousedown",
  /**
   * @event click
   * Fires on a specified interval during the time the element is pressed.
   * @param {Ext.util.ClickRepeater} this
   */
  "click",
  /**
   * @event mouseup
   * Fires when the mouse key is released.
   * @param {Ext.util.ClickRepeater} this
   */
  "mouseup");

  if (!this.disabled) {
    this.disabled = true;
    this.enable();
  } // allow inline handler


  if (this.handler) {
    this.on("click", this.handler, this.scope || this);
  }

  Ext.util.ClickRepeater.superclass.constructor.call(this);
};

Ext.extend(Ext.util.ClickRepeater, Ext.util.Observable, {
  interval: 20,
  delay: 250,
  preventDefault: true,
  stopDefault: false,
  timer: 0,

  /**
   * Enables the repeater and allows events to fire.
   */
  enable: function enable() {
    if (this.disabled) {
      this.el.on('mousedown', this.handleMouseDown, this);

      if (this.preventDefault || this.stopDefault) {
        this.el.on('click', this.eventOptions, this);
      }
    }

    this.disabled = false;
  },

  /**
   * Disables the repeater and stops events from firing.
   */
  disable: function disable(
  /* private */
  force) {
    if (force || !this.disabled) {
      clearTimeout(this.timer);

      if (this.pressClass) {
        this.el.removeClass(this.pressClass);
      }

      Ext.getDoc().un('mouseup', this.handleMouseUp, this);
      this.el.removeAllListeners();
    }

    this.disabled = true;
  },

  /**
   * Convenience function for setting disabled/enabled by boolean.
   * @param {Boolean} disabled
   */
  setDisabled: function setDisabled(disabled) {
    this[disabled ? 'disable' : 'enable']();
  },
  eventOptions: function eventOptions(e) {
    if (this.preventDefault) {
      e.preventDefault();
    }

    if (this.stopDefault) {
      e.stopEvent();
    }
  },
  // private
  destroy: function destroy() {
    this.disable(true);
    Ext.destroy(this.el);
    this.purgeListeners();
  },
  // private
  handleMouseDown: function handleMouseDown() {
    clearTimeout(this.timer);
    this.el.blur();

    if (this.pressClass) {
      this.el.addClass(this.pressClass);
    }

    this.mousedownTime = new Date();
    Ext.getDoc().on("mouseup", this.handleMouseUp, this);
    this.el.on("mouseout", this.handleMouseOut, this);
    this.fireEvent("mousedown", this);
    this.fireEvent("click", this); //      Do not honor delay or interval if acceleration wanted.

    if (this.accelerate) {
      this.delay = 400;
    }

    this.timer = this.click.defer(this.delay || this.interval, this);
  },
  // private
  click: function click() {
    this.fireEvent("click", this);
    this.timer = this.click.defer(this.accelerate ? this.easeOutExpo(this.mousedownTime.getElapsed(), 400, -390, 12000) : this.interval, this);
  },
  easeOutExpo: function easeOutExpo(t, b, c, d) {
    return t == d ? b + c : c * (-Math.pow(2, -10 * t / d) + 1) + b;
  },
  // private
  handleMouseOut: function handleMouseOut() {
    clearTimeout(this.timer);

    if (this.pressClass) {
      this.el.removeClass(this.pressClass);
    }

    this.el.on("mouseover", this.handleMouseReturn, this);
  },
  // private
  handleMouseReturn: function handleMouseReturn() {
    this.el.un("mouseover", this.handleMouseReturn, this);

    if (this.pressClass) {
      this.el.addClass(this.pressClass);
    }

    this.click();
  },
  // private
  handleMouseUp: function handleMouseUp() {
    clearTimeout(this.timer);
    this.el.un("mouseover", this.handleMouseReturn, this);
    this.el.un("mouseout", this.handleMouseOut, this);
    Ext.getDoc().un("mouseup", this.handleMouseUp, this);
    this.el.removeClass(this.pressClass);
    this.fireEvent("mouseup", this);
  }
});

/***/ }),
/* 745 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.KeyNav
 * <p>Provides a convenient wrapper for normalized keyboard navigation.  KeyNav allows you to bind
 * navigation keys to function calls that will get called when the keys are pressed, providing an easy
 * way to implement custom navigation schemes for any UI component.</p>
 * <p>The following are all of the possible keys that can be implemented: enter, left, right, up, down, tab, esc,
 * pageUp, pageDown, del, home, end.  Usage:</p>
 <pre><code>
var nav = new Ext.KeyNav("my-element", {
    "left" : function(e){
        this.moveLeft(e.ctrlKey);
    },
    "right" : function(e){
        this.moveRight(e.ctrlKey);
    },
    "enter" : function(e){
        this.save();
    },
    scope : this
});
</code></pre>
 * @constructor
 * @param {Mixed} el The element to bind to
 * @param {Object} config The config
 */
Ext.KeyNav = function (el, config) {
  this.el = Ext.get(el);
  Ext.apply(this, config);

  if (!this.disabled) {
    this.disabled = true;
    this.enable();
  }
};

Ext.KeyNav.prototype = {
  /**
   * @cfg {Boolean} disabled
   * True to disable this KeyNav instance (defaults to false)
   */
  disabled: false,

  /**
   * @cfg {String} defaultEventAction
   * The method to call on the {@link Ext.EventObject} after this KeyNav intercepts a key.  Valid values are
   * {@link Ext.EventObject#stopEvent}, {@link Ext.EventObject#preventDefault} and
   * {@link Ext.EventObject#stopPropagation} (defaults to 'stopEvent')
   */
  defaultEventAction: "stopEvent",

  /**
   * @cfg {Boolean} forceKeyDown
   * Handle the keydown event instead of keypress (defaults to false).  KeyNav automatically does this for IE since
   * IE does not propagate special keys on keypress, but setting this to true will force other browsers to also
   * handle keydown instead of keypress.
   */
  forceKeyDown: false,
  // private
  relay: function relay(e) {
    var k = e.getKey();
    var h = this.keyToHandler[k];

    if (h && this[h]) {
      if (this.doRelay(e, this[h], h) !== true) {
        e[this.defaultEventAction]();
      }
    }
  },
  // private
  doRelay: function doRelay(e, h, hname) {
    return h.call(this.scope || this, e);
  },
  // possible handlers
  enter: false,
  left: false,
  right: false,
  up: false,
  down: false,
  tab: false,
  esc: false,
  pageUp: false,
  pageDown: false,
  del: false,
  home: false,
  end: false,
  // quick lookup hash
  keyToHandler: {
    37: "left",
    39: "right",
    38: "up",
    40: "down",
    33: "pageUp",
    34: "pageDown",
    46: "del",
    36: "home",
    35: "end",
    13: "enter",
    27: "esc",
    9: "tab"
  },
  stopKeyUp: function stopKeyUp(e) {
    var k = e.getKey();

    if (k >= 37 && k <= 40) {
      // *** bugfix - safari 2.x fires 2 keyup events on cursor keys
      // *** (note: this bugfix sacrifices the "keyup" event originating from keyNav elements in Safari 2)
      e.stopEvent();
    }
  },

  /**
   * Destroy this KeyNav (this is the same as calling disable).
   */
  destroy: function destroy() {
    this.disable();
  },

  /**
   * Enable this KeyNav
   */
  enable: function enable() {
    if (this.disabled) {
      if (Ext.isSafari2) {
        // call stopKeyUp() on "keyup" event
        this.el.on('keyup', this.stopKeyUp, this);
      }

      this.el.on(this.isKeydown() ? 'keydown' : 'keypress', this.relay, this);
      this.disabled = false;
    }
  },

  /**
   * Disable this KeyNav
   */
  disable: function disable() {
    if (!this.disabled) {
      if (Ext.isSafari2) {
        // remove "keyup" event handler
        this.el.un('keyup', this.stopKeyUp, this);
      }

      this.el.un(this.isKeydown() ? 'keydown' : 'keypress', this.relay, this);
      this.disabled = true;
    }
  },

  /**
   * Convenience function for setting disabled/enabled by boolean.
   * @param {Boolean} disabled
   */
  setDisabled: function setDisabled(disabled) {
    this[disabled ? "disable" : "enable"]();
  },
  // private
  isKeydown: function isKeydown() {
    return this.forceKeyDown || Ext.EventManager.useKeydown;
  }
};

/***/ }),
/* 746 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.KeyMap
 * Handles mapping keys to actions for an element. One key map can be used for multiple actions.
 * The constructor accepts the same config object as defined by {@link #addBinding}.
 * If you bind a callback function to a KeyMap, anytime the KeyMap handles an expected key
 * combination it will call the function with this signature (if the match is a multi-key
 * combination the callback will still be called only once): (String key, Ext.EventObject e)
 * A KeyMap can also handle a string representation of keys.<br />
 * Usage:
 <pre><code>
// map one key by key code
var map = new Ext.KeyMap("my-element", {
    key: 13, // or Ext.EventObject.ENTER
    fn: myHandler,
    scope: myObject
});

// map multiple keys to one action by string
var map = new Ext.KeyMap("my-element", {
    key: "a\r\n\t",
    fn: myHandler,
    scope: myObject
});

// map multiple keys to multiple actions by strings and array of codes
var map = new Ext.KeyMap("my-element", [
    {
        key: [10,13],
        fn: function(){ alert("Return was pressed"); }
    }, {
        key: "abc",
        fn: function(){ alert('a, b or c was pressed'); }
    }, {
        key: "\t",
        ctrl:true,
        shift:true,
        fn: function(){ alert('Control + shift + tab was pressed.'); }
    }
]);
</code></pre>
 * <b>Note: A KeyMap starts enabled</b>
 * @constructor
 * @param {Mixed} el The element to bind to
 * @param {Object} config The config (see {@link #addBinding})
 * @param {String} eventName (optional) The event to bind to (defaults to "keydown")
 */
Ext.KeyMap = function (el, config, eventName) {
  this.el = Ext.get(el);
  this.eventName = eventName || "keydown";
  this.bindings = [];

  if (config) {
    this.addBinding(config);
  }

  this.enable();
};

Ext.KeyMap.prototype = {
  /**
   * True to stop the event from bubbling and prevent the default browser action if the
   * key was handled by the KeyMap (defaults to false)
   * @type Boolean
   */
  stopEvent: false,

  /**
   * Add a new binding to this KeyMap. The following config object properties are supported:
   * <pre>
  Property    Type             Description
  ----------  ---------------  ----------------------------------------------------------------------
  key         String/Array     A single keycode or an array of keycodes to handle
  shift       Boolean          True to handle key only when shift is pressed, False to handle the key only when shift is not pressed (defaults to undefined)
  ctrl        Boolean          True to handle key only when ctrl is pressed, False to handle the key only when ctrl is not pressed (defaults to undefined)
  alt         Boolean          True to handle key only when alt is pressed, False to handle the key only when alt is not pressed (defaults to undefined)
  handler     Function         The function to call when KeyMap finds the expected key combination
  fn          Function         Alias of handler (for backwards-compatibility)
  scope       Object           The scope of the callback function
  stopEvent   Boolean          True to stop the event from bubbling and prevent the default browser action if the key was handled by the KeyMap (defaults to false)
  </pre>
   *
   * Usage:
   * <pre><code>
  // Create a KeyMap
  var map = new Ext.KeyMap(document, {
  key: Ext.EventObject.ENTER,
  fn: handleKey,
  scope: this
  });
  //Add a new binding to the existing KeyMap later
  map.addBinding({
  key: 'abc',
  shift: true,
  fn: handleKey,
  scope: this
  });
  </code></pre>
   * @param {Object/Array} config A single KeyMap config or an array of configs
   */
  addBinding: function addBinding(config) {
    if (Ext.isArray(config)) {
      Ext.each(config, function (c) {
        this.addBinding(c);
      }, this);
      return;
    }

    var keyCode = config.key,
        fn = config.fn || config.handler,
        scope = config.scope;

    if (config.stopEvent) {
      this.stopEvent = config.stopEvent;
    }

    if (typeof keyCode == "string") {
      var ks = [];
      var keyString = keyCode.toUpperCase();

      for (var j = 0, len = keyString.length; j < len; j++) {
        ks.push(keyString.charCodeAt(j));
      }

      keyCode = ks;
    }

    var keyArray = Ext.isArray(keyCode);

    var handler = function handler(e) {
      if (this.checkModifiers(config, e)) {
        var k = e.getKey();

        if (keyArray) {
          for (var i = 0, len = keyCode.length; i < len; i++) {
            if (keyCode[i] == k) {
              if (this.stopEvent) {
                e.stopEvent();
              }

              fn.call(scope || window, k, e);
              return;
            }
          }
        } else {
          if (k == keyCode) {
            if (this.stopEvent) {
              e.stopEvent();
            }

            fn.call(scope || window, k, e);
          }
        }
      }
    };

    this.bindings.push(handler);
  },
  // private
  checkModifiers: function checkModifiers(config, e) {
    var val,
        key,
        keys = ['shift', 'ctrl', 'alt'];

    for (var i = 0, len = keys.length; i < len; ++i) {
      key = keys[i];
      val = config[key];

      if (!(val === undefined || val === e[key + 'Key'])) {
        return false;
      }
    }

    return true;
  },

  /**
   * Shorthand for adding a single key listener
   * @param {Number/Array/Object} key Either the numeric key code, array of key codes or an object with the
   * following options:
   * {key: (number or array), shift: (true/false), ctrl: (true/false), alt: (true/false)}
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the browser window.
   */
  on: function on(key, fn, scope) {
    var keyCode, shift, ctrl, alt;

    if (typeof key == "object" && !Ext.isArray(key)) {
      keyCode = key.key;
      shift = key.shift;
      ctrl = key.ctrl;
      alt = key.alt;
    } else {
      keyCode = key;
    }

    this.addBinding({
      key: keyCode,
      shift: shift,
      ctrl: ctrl,
      alt: alt,
      fn: fn,
      scope: scope
    });
  },
  // private
  handleKeyDown: function handleKeyDown(e) {
    if (this.enabled) {
      //just in case
      var b = this.bindings;

      for (var i = 0, len = b.length; i < len; i++) {
        b[i].call(this, e);
      }
    }
  },

  /**
   * Returns true if this KeyMap is enabled
   * @return {Boolean}
   */
  isEnabled: function isEnabled() {
    return this.enabled;
  },

  /**
   * Enables this KeyMap
   */
  enable: function enable() {
    if (!this.enabled) {
      this.el.on(this.eventName, this.handleKeyDown, this);
      this.enabled = true;
    }
  },

  /**
   * Disable this KeyMap
   */
  disable: function disable() {
    if (this.enabled) {
      this.el.removeListener(this.eventName, this.handleKeyDown, this);
      this.enabled = false;
    }
  },

  /**
   * Convenience function for setting disabled/enabled by boolean.
   * @param {Boolean} disabled
   */
  setDisabled: function setDisabled(disabled) {
    this[disabled ? "disable" : "enable"]();
  }
};

/***/ }),
/* 747 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.TextMetrics
 * Provides precise pixel measurements for blocks of text so that you can determine exactly how high and
 * wide, in pixels, a given block of text will be. Note that when measuring text, it should be plain text and
 * should not contain any HTML, otherwise it may not be measured correctly.
 * @singleton
 */
Ext.util.TextMetrics = function () {
  var shared;
  return {
    /**
     * Measures the size of the specified text
     * @param {String/HTMLElement} el The element, dom node or id from which to copy existing CSS styles
     * that can affect the size of the rendered text
     * @param {String} text The text to measure
     * @param {Number} fixedWidth (optional) If the text will be multiline, you have to set a fixed width
     * in order to accurately measure the text height
     * @return {Object} An object containing the text's size {width: (width), height: (height)}
     */
    measure: function measure(el, text, fixedWidth) {
      if (!shared) {
        shared = Ext.util.TextMetrics.Instance(el, fixedWidth);
      }

      shared.bind(el);
      shared.setFixedWidth(fixedWidth || 'auto');
      return shared.getSize(text);
    },

    /**
     * Return a unique TextMetrics instance that can be bound directly to an element and reused.  This reduces
     * the overhead of multiple calls to initialize the style properties on each measurement.
     * @param {String/HTMLElement} el The element, dom node or id that the instance will be bound to
     * @param {Number} fixedWidth (optional) If the text will be multiline, you have to set a fixed width
     * in order to accurately measure the text height
     * @return {Ext.util.TextMetrics.Instance} instance The new instance
     */
    createInstance: function createInstance(el, fixedWidth) {
      return Ext.util.TextMetrics.Instance(el, fixedWidth);
    }
  };
}();

Ext.util.TextMetrics.Instance = function (bindTo, fixedWidth) {
  var ml = new Ext.Element(document.createElement('div'));
  document.body.appendChild(ml.dom);
  ml.position('absolute');
  ml.setLeftTop(-1000, -1000);
  ml.hide();

  if (fixedWidth) {
    ml.setWidth(fixedWidth);
  }

  var instance = {
    /**
     * <p><b>Only available on the instance returned from {@link #createInstance}, <u>not</u> on the singleton.</b></p>
     * Returns the size of the specified text based on the internal element's style and width properties
     * @param {String} text The text to measure
     * @return {Object} An object containing the text's size {width: (width), height: (height)}
     */
    getSize: function getSize(text) {
      ml.update(text);
      var s = ml.getSize();
      ml.update('');
      return s;
    },

    /**
     * <p><b>Only available on the instance returned from {@link #createInstance}, <u>not</u> on the singleton.</b></p>
     * Binds this TextMetrics instance to an element from which to copy existing CSS styles
     * that can affect the size of the rendered text
     * @param {String/HTMLElement} el The element, dom node or id
     */
    bind: function bind(el) {
      ml.setStyle(Ext.fly(el).getStyles('font-size', 'font-style', 'font-weight', 'font-family', 'line-height', 'text-transform', 'letter-spacing'));
    },

    /**
     * <p><b>Only available on the instance returned from {@link #createInstance}, <u>not</u> on the singleton.</b></p>
     * Sets a fixed width on the internal measurement element.  If the text will be multiline, you have
     * to set a fixed width in order to accurately measure the text height.
     * @param {Number} width The width to set on the element
     */
    setFixedWidth: function setFixedWidth(width) {
      ml.setWidth(width);
    },

    /**
     * <p><b>Only available on the instance returned from {@link #createInstance}, <u>not</u> on the singleton.</b></p>
     * Returns the measured width of the specified text
     * @param {String} text The text to measure
     * @return {Number} width The width in pixels
     */
    getWidth: function getWidth(text) {
      ml.dom.style.width = 'auto';
      return this.getSize(text).width;
    },

    /**
     * <p><b>Only available on the instance returned from {@link #createInstance}, <u>not</u> on the singleton.</b></p>
     * Returns the measured height of the specified text.  For multiline text, be sure to call
     * {@link #setFixedWidth} if necessary.
     * @param {String} text The text to measure
     * @return {Number} height The height in pixels
     */
    getHeight: function getHeight(text) {
      return this.getSize(text).height;
    }
  };
  instance.bind(bindTo);
  return instance;
};

Ext.Element.addMethods({
  /**
   * Returns the width in pixels of the passed text, or the width of the text in this Element.
   * @param {String} text The text to measure. Defaults to the innerHTML of the element.
   * @param {Number} min (Optional) The minumum value to return.
   * @param {Number} max (Optional) The maximum value to return.
   * @return {Number} The text width in pixels.
   * @member Ext.Element getTextWidth
   */
  getTextWidth: function getTextWidth(text, min, max) {
    return Ext.util.TextMetrics.measure(this.dom, Ext.value(text, this.dom.innerHTML, true)).width.constrain(min || 0, max || 1000000);
  }
});

/***/ }),
/* 748 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.util.Cookies
 * Utility class for managing and interacting with cookies.
 * @singleton
 */
Ext.util.Cookies = {
  /**
   * Create a cookie with the specified name and value. Additional settings
   * for the cookie may be optionally specified (for example: expiration,
   * access restriction, SSL).
   * @param {String} name The name of the cookie to set. 
   * @param {Mixed} value The value to set for the cookie.
   * @param {Object} expires (Optional) Specify an expiration date the
   * cookie is to persist until.  Note that the specified Date object will
   * be converted to Greenwich Mean Time (GMT). 
   * @param {String} path (Optional) Setting a path on the cookie restricts
   * access to pages that match that path. Defaults to all pages (<tt>'/'</tt>). 
   * @param {String} domain (Optional) Setting a domain restricts access to
   * pages on a given domain (typically used to allow cookie access across
   * subdomains). For example, "extjs.com" will create a cookie that can be
   * accessed from any subdomain of extjs.com, including www.extjs.com,
   * support.extjs.com, etc.
   * @param {Boolean} secure (Optional) Specify true to indicate that the cookie
   * should only be accessible via SSL on a page using the HTTPS protocol.
   * Defaults to <tt>false</tt>. Note that this will only work if the page
   * calling this code uses the HTTPS protocol, otherwise the cookie will be
   * created with default options.
   */
  set: function set(name, value) {
    var argv = arguments;
    var argc = arguments.length;
    var expires = argc > 2 ? argv[2] : null;
    var path = argc > 3 ? argv[3] : '/';
    var domain = argc > 4 ? argv[4] : null;
    var secure = argc > 5 ? argv[5] : false;
    document.cookie = name + "=" + escape(value) + (expires === null ? "" : "; expires=" + expires.toGMTString()) + (path === null ? "" : "; path=" + path) + (domain === null ? "" : "; domain=" + domain) + (secure === true ? "; secure" : "");
  },

  /**
   * Retrieves cookies that are accessible by the current page. If a cookie
   * does not exist, <code>get()</code> returns <tt>null</tt>.  The following
   * example retrieves the cookie called "valid" and stores the String value
   * in the variable <tt>validStatus</tt>.
   * <pre><code>
   * var validStatus = Ext.util.Cookies.get("valid");
   * </code></pre>
   * @param {String} name The name of the cookie to get
   * @return {Mixed} Returns the cookie value for the specified name;
   * null if the cookie name does not exist.
   */
  get: function get(name) {
    var arg = name + "=";
    var alen = arg.length;
    var clen = document.cookie.length;
    var i = 0;
    var j = 0;

    while (i < clen) {
      j = i + alen;

      if (document.cookie.substring(i, j) == arg) {
        return Ext.util.Cookies.getCookieVal(j);
      }

      i = document.cookie.indexOf(" ", i) + 1;

      if (i === 0) {
        break;
      }
    }

    return null;
  },

  /**
   * Removes a cookie with the provided name from the browser
   * if found by setting its expiration date to sometime in the past. 
   * @param {String} name The name of the cookie to remove
   */
  clear: function clear(name) {
    if (Ext.util.Cookies.get(name)) {
      document.cookie = name + "=" + "; expires=Thu, 01-Jan-70 00:00:01 GMT";
    }
  },

  /**
   * @private
   */
  getCookieVal: function getCookieVal(offset) {
    var endstr = document.cookie.indexOf(";", offset);

    if (endstr == -1) {
      endstr = document.cookie.length;
    }

    return unescape(document.cookie.substring(offset, endstr));
  }
};

/***/ }),
/* 749 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * Framework-wide error-handler.  Developers can override this method to provide
 * custom exception-handling.  Framework errors will often extend from the base
 * Ext.Error class.
 * @param {Object/Error} e The thrown exception object.
 */
Ext.handleError = function (e) {
  throw e;
};
/**
 * @class Ext.Error
 * @extends Error
 * <p>A base error class. Future implementations are intended to provide more
 * robust error handling throughout the framework (<b>in the debug build only</b>)
 * to check for common errors and problems. The messages issued by this class
 * will aid error checking. Error checks will be automatically removed in the
 * production build so that performance is not negatively impacted.</p>
 * <p>Some sample messages currently implemented:</p><pre>
"DataProxy attempted to execute an API-action but found an undefined
url / function. Please review your Proxy url/api-configuration."
 * </pre><pre>
"Could not locate your "root" property in your server response.
Please review your JsonReader config to ensure the config-property
"root" matches the property your server-response.  See the JsonReader
docs for additional assistance."
 * </pre>
 * <p>An example of the code used for generating error messages:</p><pre><code>
try {
    generateError({
        foo: 'bar'
    });
}
catch (e) {
    console.error(e);
}
function generateError(data) {
    throw new Ext.Error('foo-error', data);
}
 * </code></pre>
 * @param {String} message
 */


Ext.Error = function (message) {
  // Try to read the message from Ext.Error.lang
  this.message = this.lang[message] ? this.lang[message] : message;
};

Ext.Error.prototype = new Error();
Ext.apply(Ext.Error.prototype, {
  // protected.  Extensions place their error-strings here.
  lang: {},
  name: 'Ext.Error',

  /**
   * getName
   * @return {String}
   */
  getName: function getName() {
    return this.name;
  },

  /**
   * getMessage
   * @return {String}
   */
  getMessage: function getMessage() {
    return this.message;
  },

  /**
   * toJson
   * @return {String}
   */
  toJson: function toJson() {
    return Ext.encode(this);
  }
});

/***/ }),
/* 750 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ComponentMgr
 * <p>Provides a registry of all Components (instances of {@link Ext.Component} or any subclass
 * thereof) on a page so that they can be easily accessed by {@link Ext.Component component}
 * {@link Ext.Component#id id} (see {@link #get}, or the convenience method {@link Ext#getCmp Ext.getCmp}).</p>
 * <p>This object also provides a registry of available Component <i>classes</i>
 * indexed by a mnemonic code known as the Component's {@link Ext.Component#xtype xtype}.
 * The <code>{@link Ext.Component#xtype xtype}</code> provides a way to avoid instantiating child Components
 * when creating a full, nested config object for a complete Ext page.</p>
 * <p>A child Component may be specified simply as a <i>config object</i>
 * as long as the correct <code>{@link Ext.Component#xtype xtype}</code> is specified so that if and when the Component
 * needs rendering, the correct type can be looked up for lazy instantiation.</p>
 * <p>For a list of all available <code>{@link Ext.Component#xtype xtypes}</code>, see {@link Ext.Component}.</p>
 * @singleton
 */
Ext.ComponentMgr = function () {
  var all = new Ext.util.MixedCollection();
  var types = {};
  var ptypes = {};
  return {
    /**
     * Registers a component.
     * @param {Ext.Component} c The component
     */
    register: function register(c) {
      all.add(c);
    },

    /**
     * Unregisters a component.
     * @param {Ext.Component} c The component
     */
    unregister: function unregister(c) {
      all.remove(c);
    },

    /**
     * Returns a component by {@link Ext.Component#id id}.
     * For additional details see {@link Ext.util.MixedCollection#get}.
     * @param {String} id The component {@link Ext.Component#id id}
     * @return Ext.Component The Component, <code>undefined</code> if not found, or <code>null</code> if a
     * Class was found.
     */
    get: function get(id) {
      return all.get(id);
    },

    /**
     * Registers a function that will be called when a Component with the specified id is added to ComponentMgr. This will happen on instantiation.
     * @param {String} id The component {@link Ext.Component#id id}
     * @param {Function} fn The callback function
     * @param {Object} scope The scope (<code>this</code> reference) in which the callback is executed. Defaults to the Component.
     */
    onAvailable: function onAvailable(id, fn, scope) {
      all.on("add", function (index, o) {
        if (o.id == id) {
          fn.call(scope || o, o);
          all.un("add", fn, scope);
        }
      });
    },

    /**
     * The MixedCollection used internally for the component cache. An example usage may be subscribing to
     * events on the MixedCollection to monitor addition or removal.  Read-only.
     * @type {MixedCollection}
     */
    all: all,

    /**
     * The xtypes that have been registered with the component manager.
     * @type {Object}
     */
    types: types,

    /**
     * The ptypes that have been registered with the component manager.
     * @type {Object}
     */
    ptypes: ptypes,

    /**
     * Checks if a Component type is registered.
     * @param {Ext.Component} xtype The mnemonic string by which the Component class may be looked up
     * @return {Boolean} Whether the type is registered.
     */
    isRegistered: function isRegistered(xtype) {
      return types[xtype] !== undefined;
    },

    /**
     * Checks if a Plugin type is registered.
     * @param {Ext.Component} ptype The mnemonic string by which the Plugin class may be looked up
     * @return {Boolean} Whether the type is registered.
     */
    isPluginRegistered: function isPluginRegistered(ptype) {
      return ptypes[ptype] !== undefined;
    },

    /**
     * <p>Registers a new Component constructor, keyed by a new
     * {@link Ext.Component#xtype}.</p>
     * <p>Use this method (or its alias {@link Ext#reg Ext.reg}) to register new
     * subclasses of {@link Ext.Component} so that lazy instantiation may be used when specifying
     * child Components.
     * see {@link Ext.Container#items}</p>
     * @param {String} xtype The mnemonic string by which the Component class may be looked up.
     * @param {Constructor} cls The new Component class.
     */
    registerType: function registerType(xtype, cls) {
      types[xtype] = cls;
      cls.xtype = xtype;
    },

    /**
     * Creates a new Component from the specified config object using the
     * config object's {@link Ext.component#xtype xtype} to determine the class to instantiate.
     * @param {Object} config A configuration object for the Component you wish to create.
     * @param {Constructor} defaultType The constructor to provide the default Component type if
     * the config object does not contain a <code>xtype</code>. (Optional if the config contains a <code>xtype</code>).
     * @return {Ext.Component} The newly instantiated Component.
     */
    create: function create(config, defaultType) {
      return config.render ? config : new types[config.xtype || defaultType](config);
    },

    /**
     * <p>Registers a new Plugin constructor, keyed by a new
     * {@link Ext.Component#ptype}.</p>
     * <p>Use this method (or its alias {@link Ext#preg Ext.preg}) to register new
     * plugins for {@link Ext.Component}s so that lazy instantiation may be used when specifying
     * Plugins.</p>
     * @param {String} ptype The mnemonic string by which the Plugin class may be looked up.
     * @param {Constructor} cls The new Plugin class.
     */
    registerPlugin: function registerPlugin(ptype, cls) {
      ptypes[ptype] = cls;
      cls.ptype = ptype;
    },

    /**
     * Creates a new Plugin from the specified config object using the
     * config object's {@link Ext.component#ptype ptype} to determine the class to instantiate.
     * @param {Object} config A configuration object for the Plugin you wish to create.
     * @param {Constructor} defaultType The constructor to provide the default Plugin type if
     * the config object does not contain a <code>ptype</code>. (Optional if the config contains a <code>ptype</code>).
     * @return {Ext.Component} The newly instantiated Plugin.
     */
    createPlugin: function createPlugin(config, defaultType) {
      var PluginCls = ptypes[config.ptype || defaultType];

      if (PluginCls.init) {
        return PluginCls;
      } else {
        return new PluginCls(config);
      }
    }
  };
}();
/**
 * Shorthand for {@link Ext.ComponentMgr#registerType}
 * @param {String} xtype The {@link Ext.component#xtype mnemonic string} by which the Component class
 * may be looked up.
 * @param {Constructor} cls The new Component class.
 * @member Ext
 * @method reg
 */


Ext.reg = Ext.ComponentMgr.registerType; // this will be called a lot internally, shorthand to keep the bytes down

/**
 * Shorthand for {@link Ext.ComponentMgr#registerPlugin}
 * @param {String} ptype The {@link Ext.component#ptype mnemonic string} by which the Plugin class
 * may be looked up.
 * @param {Constructor} cls The new Plugin class.
 * @member Ext
 * @method preg
 */

Ext.preg = Ext.ComponentMgr.registerPlugin;
/**
 * Shorthand for {@link Ext.ComponentMgr#create}
 * Creates a new Component from the specified config object using the
 * config object's {@link Ext.component#xtype xtype} to determine the class to instantiate.
 * @param {Object} config A configuration object for the Component you wish to create.
 * @param {Constructor} defaultType The constructor to provide the default Component type if
 * the config object does not contain a <code>xtype</code>. (Optional if the config contains a <code>xtype</code>).
 * @return {Ext.Component} The newly instantiated Component.
 * @member Ext
 * @method create
 */

Ext.create = Ext.ComponentMgr.create;

/***/ }),
/* 751 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Component
 * @extends Ext.util.Observable
 * <p>Base class for all Ext components.  All subclasses of Component may participate in the automated
 * Ext component lifecycle of creation, rendering and destruction which is provided by the {@link Ext.Container Container} class.
 * Components may be added to a Container through the {@link Ext.Container#items items} config option at the time the Container is created,
 * or they may be added dynamically via the {@link Ext.Container#add add} method.</p>
 * <p>The Component base class has built-in support for basic hide/show and enable/disable behavior.</p>
 * <p>All Components are registered with the {@link Ext.ComponentMgr} on construction so that they can be referenced at any time via
 * {@link Ext#getCmp}, passing the {@link #id}.</p>
 * <p>All user-developed visual widgets that are required to participate in automated lifecycle and size management should subclass Component (or
 * {@link Ext.BoxComponent} if managed box model handling is required, ie height and width management).</p>
 * <p>See the <a href="http://extjs.com/learn/Tutorial:Creating_new_UI_controls">Creating new UI controls</a> tutorial for details on how
 * and to either extend or augment ExtJs base classes to create custom Components.</p>
 * <p>Every component has a specific xtype, which is its Ext-specific type name, along with methods for checking the
 * xtype like {@link #getXType} and {@link #isXType}. This is the list of all valid xtypes:</p>
 * <pre>
xtype            Class
-------------    ------------------
box              {@link Ext.BoxComponent}
button           {@link Ext.Button}
buttongroup      {@link Ext.ButtonGroup}
colorpalette     {@link Ext.ColorPalette}
component        {@link Ext.Component}
container        {@link Ext.Container}
cycle            {@link Ext.CycleButton}
dataview         {@link Ext.DataView}
datepicker       {@link Ext.DatePicker}
editor           {@link Ext.Editor}
editorgrid       {@link Ext.grid.EditorGridPanel}
flash            {@link Ext.FlashComponent}
grid             {@link Ext.grid.GridPanel}
listview         {@link Ext.ListView}
panel            {@link Ext.Panel}
progress         {@link Ext.ProgressBar}
propertygrid     {@link Ext.grid.PropertyGrid}
slider           {@link Ext.Slider}
spacer           {@link Ext.Spacer}
splitbutton      {@link Ext.SplitButton}
tabpanel         {@link Ext.TabPanel}
treepanel        {@link Ext.tree.TreePanel}
viewport         {@link Ext.ViewPort}
window           {@link Ext.Window}

Toolbar components
---------------------------------------
paging           {@link Ext.PagingToolbar}
toolbar          {@link Ext.Toolbar}
tbbutton         {@link Ext.Toolbar.Button}        (deprecated; use button)
tbfill           {@link Ext.Toolbar.Fill}
tbitem           {@link Ext.Toolbar.Item}
tbseparator      {@link Ext.Toolbar.Separator}
tbspacer         {@link Ext.Toolbar.Spacer}
tbsplit          {@link Ext.Toolbar.SplitButton}   (deprecated; use splitbutton)
tbtext           {@link Ext.Toolbar.TextItem}

Menu components
---------------------------------------
menu             {@link Ext.menu.Menu}
colormenu        {@link Ext.menu.ColorMenu}
datemenu         {@link Ext.menu.DateMenu}
menubaseitem     {@link Ext.menu.BaseItem}
menucheckitem    {@link Ext.menu.CheckItem}
menuitem         {@link Ext.menu.Item}
menuseparator    {@link Ext.menu.Separator}
menutextitem     {@link Ext.menu.TextItem}

Form components
---------------------------------------
form             {@link Ext.form.FormPanel}
checkbox         {@link Ext.form.Checkbox}
checkboxgroup    {@link Ext.form.CheckboxGroup}
combo            {@link Ext.form.ComboBox}
datefield        {@link Ext.form.DateField}
displayfield     {@link Ext.form.DisplayField}
field            {@link Ext.form.Field}
fieldset         {@link Ext.form.FieldSet}
hidden           {@link Ext.form.Hidden}
htmleditor       {@link Ext.form.HtmlEditor}
label            {@link Ext.form.Label}
numberfield      {@link Ext.form.NumberField}
radio            {@link Ext.form.Radio}
radiogroup       {@link Ext.form.RadioGroup}
textarea         {@link Ext.form.TextArea}
textfield        {@link Ext.form.TextField}
timefield        {@link Ext.form.TimeField}
trigger          {@link Ext.form.TriggerField}

Chart components
---------------------------------------
chart            {@link Ext.chart.Chart}
barchart         {@link Ext.chart.BarChart}
cartesianchart   {@link Ext.chart.CartesianChart}
columnchart      {@link Ext.chart.ColumnChart}
linechart        {@link Ext.chart.LineChart}
piechart         {@link Ext.chart.PieChart}

Store xtypes
---------------------------------------
arraystore       {@link Ext.data.ArrayStore}
directstore      {@link Ext.data.DirectStore}
groupingstore    {@link Ext.data.GroupingStore}
jsonstore        {@link Ext.data.JsonStore}
simplestore      {@link Ext.data.SimpleStore}      (deprecated; use arraystore)
store            {@link Ext.data.Store}
xmlstore         {@link Ext.data.XmlStore}
</pre>
 * @constructor
 * @param {Ext.Element/String/Object} config The configuration options may be specified as either:
 * <div class="mdetail-params"><ul>
 * <li><b>an element</b> :
 * <p class="sub-desc">it is set as the internal element and its id used as the component id</p></li>
 * <li><b>a string</b> :
 * <p class="sub-desc">it is assumed to be the id of an existing element and is used as the component id</p></li>
 * <li><b>anything else</b> :
 * <p class="sub-desc">it is assumed to be a standard config object and is applied to the component</p></li>
 * </ul></div>
 */
Ext.Component = function (config) {
  config = config || {};

  if (config.initialConfig) {
    if (config.isAction) {
      // actions
      this.baseAction = config;
    }

    config = config.initialConfig; // component cloning / action set up
  } else if (config.tagName || config.dom || Ext.isString(config)) {
    // element object
    config = {
      applyTo: config,
      id: config.id || config
    };
  }
  /**
   * This Component's initial configuration specification. Read-only.
   * @type Object
   * @property initialConfig
   */


  this.initialConfig = config;
  Ext.apply(this, config);
  this.addEvents(
  /**
   * @event added
   * Fires when a component is added to an Ext.Container
   * @param {Ext.Component} this
   * @param {Ext.Container} ownerCt Container which holds the component
   * @param {number} index Position at which the component was added
   */
  'added',
  /**
   * @event disable
   * Fires after the component is disabled.
   * @param {Ext.Component} this
   */
  'disable',
  /**
   * @event enable
   * Fires after the component is enabled.
   * @param {Ext.Component} this
   */
  'enable',
  /**
   * @event beforeshow
   * Fires before the component is shown by calling the {@link #show} method.
   * Return false from an event handler to stop the show.
   * @param {Ext.Component} this
   */
  'beforeshow',
  /**
   * @event show
   * Fires after the component is shown when calling the {@link #show} method.
   * @param {Ext.Component} this
   */
  'show',
  /**
   * @event beforehide
   * Fires before the component is hidden by calling the {@link #hide} method.
   * Return false from an event handler to stop the hide.
   * @param {Ext.Component} this
   */
  'beforehide',
  /**
   * @event hide
   * Fires after the component is hidden.
   * Fires after the component is hidden when calling the {@link #hide} method.
   * @param {Ext.Component} this
   */
  'hide',
  /**
   * @event removed
   * Fires when a component is removed from an Ext.Container
   * @param {Ext.Component} this
   * @param {Ext.Container} ownerCt Container which holds the component
   */
  'removed',
  /**
   * @event beforerender
   * Fires before the component is {@link #rendered}. Return false from an
   * event handler to stop the {@link #render}.
   * @param {Ext.Component} this
   */
  'beforerender',
  /**
   * @event render
   * Fires after the component markup is {@link #rendered}.
   * @param {Ext.Component} this
   */
  'render',
  /**
   * @event afterrender
   * <p>Fires after the component rendering is finished.</p>
   * <p>The afterrender event is fired after this Component has been {@link #rendered}, been postprocesed
   * by any afterRender method defined for the Component, and, if {@link #stateful}, after state
   * has been restored.</p>
   * @param {Ext.Component} this
   */
  'afterrender',
  /**
   * @event beforedestroy
   * Fires before the component is {@link #destroy}ed. Return false from an event handler to stop the {@link #destroy}.
   * @param {Ext.Component} this
   */
  'beforedestroy',
  /**
   * @event destroy
   * Fires after the component is {@link #destroy}ed.
   * @param {Ext.Component} this
   */
  'destroy',
  /**
   * @event beforestaterestore
   * Fires before the state of the component is restored. Return false from an event handler to stop the restore.
   * @param {Ext.Component} this
   * @param {Object} state The hash of state values returned from the StateProvider. If this
   * event is not vetoed, then the state object is passed to <b><tt>applyState</tt></b>. By default,
   * that simply copies property values into this Component. The method maybe overriden to
   * provide custom state restoration.
   */
  'beforestaterestore',
  /**
   * @event staterestore
   * Fires after the state of the component is restored.
   * @param {Ext.Component} this
   * @param {Object} state The hash of state values returned from the StateProvider. This is passed
   * to <b><tt>applyState</tt></b>. By default, that simply copies property values into this
   * Component. The method maybe overriden to provide custom state restoration.
   */
  'staterestore',
  /**
   * @event beforestatesave
   * Fires before the state of the component is saved to the configured state provider. Return false to stop the save.
   * @param {Ext.Component} this
   * @param {Object} state The hash of state values. This is determined by calling
   * <b><tt>getState()</tt></b> on the Component. This method must be provided by the
   * developer to return whetever representation of state is required, by default, Ext.Component
   * has a null implementation.
   */
  'beforestatesave',
  /**
   * @event statesave
   * Fires after the state of the component is saved to the configured state provider.
   * @param {Ext.Component} this
   * @param {Object} state The hash of state values. This is determined by calling
   * <b><tt>getState()</tt></b> on the Component. This method must be provided by the
   * developer to return whetever representation of state is required, by default, Ext.Component
   * has a null implementation.
   */
  'statesave');
  this.getId();
  Ext.ComponentMgr.register(this);
  Ext.Component.superclass.constructor.call(this);

  if (this.baseAction) {
    this.baseAction.addComponent(this);
  }

  const v = this.initComponent();

  const afterInit = () => {
    if (this.plugins) {
      if (Ext.isArray(this.plugins)) {
        for (var i = 0, len = this.plugins.length; i < len; i++) {
          this.plugins[i] = this.initPlugin(this.plugins[i]);
        }
      } else {
        this.plugins = this.initPlugin(this.plugins);
      }
    }

    if (this.stateful !== false) {
      this.initState();
    }

    if (this.applyTo) {
      this.applyToMarkup(this.applyTo);
      delete this.applyTo;
    } else if (this.renderTo) {
      this.render(this.renderTo);
      delete this.renderTo;
    }
  };

  if (Ext.isThenable(v)) {
    v.then(() => {
      afterInit();
    });
  } else {
    afterInit();
  }
}; // private


Ext.Component.AUTO_ID = 1000;
Ext.extend(Ext.Component, Ext.util.Observable, {
  // Configs below are used for all Components when rendered by FormLayout.

  /**
   * @cfg {String} fieldLabel <p>The label text to display next to this Component (defaults to '').</p>
   * <br><p><b>Note</b>: this config is only used when this Component is rendered by a Container which
   * has been configured to use the <b>{@link Ext.layout.FormLayout FormLayout}</b> layout manager (e.g.
   * {@link Ext.form.FormPanel} or specifying <tt>layout:'form'</tt>).</p><br>
   * <p>Also see <tt>{@link #hideLabel}</tt> and
   * {@link Ext.layout.FormLayout}.{@link Ext.layout.FormLayout#fieldTpl fieldTpl}.</p>
   * Example use:<pre><code>
  new Ext.FormPanel({
  height: 100,
  renderTo: Ext.getBody(),
  items: [{
      xtype: 'textfield',
      fieldLabel: 'Name'
  }]
  });
  </code></pre>
   */

  /**
   * @cfg {String} labelStyle <p>A CSS style specification string to apply directly to this field's
   * label.  Defaults to the container's labelStyle value if set (e.g.,
   * <tt>{@link Ext.layout.FormLayout#labelStyle}</tt> , or '').</p>
   * <br><p><b>Note</b>: see the note for <code>{@link #clearCls}</code>.</p><br>
   * <p>Also see <code>{@link #hideLabel}</code> and
   * <code>{@link Ext.layout.FormLayout}.{@link Ext.layout.FormLayout#fieldTpl fieldTpl}.</code></p>
   * Example use:<pre><code>
  new Ext.FormPanel({
  height: 100,
  renderTo: Ext.getBody(),
  items: [{
      xtype: 'textfield',
      fieldLabel: 'Name',
      labelStyle: 'font-weight:bold;'
  }]
  });
  </code></pre>
   */

  /**
   * @cfg {String} labelSeparator <p>The separator to display after the text of each
   * <tt>{@link #fieldLabel}</tt>.  This property may be configured at various levels.
   * The order of precedence is:
   * <div class="mdetail-params"><ul>
   * <li>field / component level</li>
   * <li>container level</li>
   * <li>{@link Ext.layout.FormLayout#labelSeparator layout level} (defaults to colon <tt>':'</tt>)</li>
   * </ul></div>
   * To display no separator for this field's label specify empty string ''.</p>
   * <br><p><b>Note</b>: see the note for <tt>{@link #clearCls}</tt>.</p><br>
   * <p>Also see <tt>{@link #hideLabel}</tt> and
   * {@link Ext.layout.FormLayout}.{@link Ext.layout.FormLayout#fieldTpl fieldTpl}.</p>
   * Example use:<pre><code>
  new Ext.FormPanel({
  height: 100,
  renderTo: Ext.getBody(),
  layoutConfig: {
      labelSeparator: '~'   // layout config has lowest priority (defaults to ':')
  },
  {@link Ext.layout.FormLayout#labelSeparator labelSeparator}: '>>',     // config at container level
  items: [{
      xtype: 'textfield',
      fieldLabel: 'Field 1',
      labelSeparator: '...' // field/component level config supersedes others
  },{
      xtype: 'textfield',
      fieldLabel: 'Field 2' // labelSeparator will be '='
  }]
  });
  </code></pre>
   */

  /**
   * @cfg {Boolean} hideLabel <p><tt>true</tt> to completely hide the label element
   * ({@link #fieldLabel label} and {@link #labelSeparator separator}). Defaults to <tt>false</tt>.
   * By default, even if you do not specify a <tt>{@link #fieldLabel}</tt> the space will still be
   * reserved so that the field will line up with other fields that do have labels.
   * Setting this to <tt>true</tt> will cause the field to not reserve that space.</p>
   * <br><p><b>Note</b>: see the note for <tt>{@link #clearCls}</tt>.</p><br>
   * Example use:<pre><code>
  new Ext.FormPanel({
  height: 100,
  renderTo: Ext.getBody(),
  items: [{
      xtype: 'textfield'
      hideLabel: true
  }]
  });
  </code></pre>
   */

  /**
   * @cfg {String} clearCls <p>The CSS class used to to apply to the special clearing div rendered
   * directly after each form field wrapper to provide field clearing (defaults to
   * <tt>'x-form-clear-left'</tt>).</p>
   * <br><p><b>Note</b>: this config is only used when this Component is rendered by a Container
   * which has been configured to use the <b>{@link Ext.layout.FormLayout FormLayout}</b> layout
   * manager (e.g. {@link Ext.form.FormPanel} or specifying <tt>layout:'form'</tt>) and either a
   * <tt>{@link #fieldLabel}</tt> is specified or <tt>isFormField=true</tt> is specified.</p><br>
   * <p>See {@link Ext.layout.FormLayout}.{@link Ext.layout.FormLayout#fieldTpl fieldTpl} also.</p>
   */

  /**
   * @cfg {String} itemCls
   * <p><b>Note</b>: this config is only used when this Component is rendered by a Container which
   * has been configured to use the <b>{@link Ext.layout.FormLayout FormLayout}</b> layout manager (e.g.
   * {@link Ext.form.FormPanel} or specifying <tt>layout:'form'</tt>).</p><br>
   * <p>An additional CSS class to apply to the div wrapping the form item
   * element of this field.  If supplied, <tt>itemCls</tt> at the <b>field</b> level will override
   * the default <tt>itemCls</tt> supplied at the <b>container</b> level. The value specified for
   * <tt>itemCls</tt> will be added to the default class (<tt>'x-form-item'</tt>).</p>
   * <p>Since it is applied to the item wrapper (see
   * {@link Ext.layout.FormLayout}.{@link Ext.layout.FormLayout#fieldTpl fieldTpl}), it allows
   * you to write standard CSS rules that can apply to the field, the label (if specified), or
   * any other element within the markup for the field.</p>
   * <br><p><b>Note</b>: see the note for <tt>{@link #fieldLabel}</tt>.</p><br>
   * Example use:<pre><code>
  // Apply a style to the field&#39;s label:
  &lt;style>
  .required .x-form-item-label {font-weight:bold;color:red;}
  &lt;/style>
  new Ext.FormPanel({
  height: 100,
  renderTo: Ext.getBody(),
  items: [{
      xtype: 'textfield',
      fieldLabel: 'Name',
      itemCls: 'required' //this label will be styled
  },{
      xtype: 'textfield',
      fieldLabel: 'Favorite Color'
  }]
  });
  </code></pre>
   */

  /**
   * @cfg {String} id
   * <p>The <b>unique</b> id of this component (defaults to an {@link #getId auto-assigned id}).
   * You should assign an id if you need to be able to access the component later and you do
   * not have an object reference available (e.g., using {@link Ext}.{@link Ext#getCmp getCmp}).</p>
   * <p>Note that this id will also be used as the element id for the containing HTML element
   * that is rendered to the page for this component. This allows you to write id-based CSS
   * rules to style the specific instance of this component uniquely, and also to select
   * sub-elements using this component's id as the parent.</p>
   * <p><b>Note</b>: to avoid complications imposed by a unique <tt>id</tt> also see
   * <code>{@link #itemId}</code> and <code>{@link #ref}</code>.</p>
   * <p><b>Note</b>: to access the container of an item see <code>{@link #ownerCt}</code>.</p>
   */

  /**
   * @cfg {String} itemId
   * <p>An <tt>itemId</tt> can be used as an alternative way to get a reference to a component
   * when no object reference is available.  Instead of using an <code>{@link #id}</code> with
   * {@link Ext}.{@link Ext#getCmp getCmp}, use <code>itemId</code> with
   * {@link Ext.Container}.{@link Ext.Container#getComponent getComponent} which will retrieve
   * <code>itemId</code>'s or <tt>{@link #id}</tt>'s. Since <code>itemId</code>'s are an index to the
   * container's internal MixedCollection, the <code>itemId</code> is scoped locally to the container --
   * avoiding potential conflicts with {@link Ext.ComponentMgr} which requires a <b>unique</b>
   * <code>{@link #id}</code>.</p>
   * <pre><code>
  var c = new Ext.Panel({ //
  {@link Ext.BoxComponent#height height}: 300,
  {@link #renderTo}: document.body,
  {@link Ext.Container#layout layout}: 'auto',
  {@link Ext.Container#items items}: [
      {
          itemId: 'p1',
          {@link Ext.Panel#title title}: 'Panel 1',
          {@link Ext.BoxComponent#height height}: 150
      },
      {
          itemId: 'p2',
          {@link Ext.Panel#title title}: 'Panel 2',
          {@link Ext.BoxComponent#height height}: 150
      }
  ]
  })
  p1 = c.{@link Ext.Container#getComponent getComponent}('p1'); // not the same as {@link Ext#getCmp Ext.getCmp()}
  p2 = p1.{@link #ownerCt}.{@link Ext.Container#getComponent getComponent}('p2'); // reference via a sibling
   * </code></pre>
   * <p>Also see <tt>{@link #id}</tt> and <code>{@link #ref}</code>.</p>
   * <p><b>Note</b>: to access the container of an item see <tt>{@link #ownerCt}</tt>.</p>
   */

  /**
   * @cfg {String} xtype
   * The registered <tt>xtype</tt> to create. This config option is not used when passing
   * a config object into a constructor. This config option is used only when
   * lazy instantiation is being used, and a child item of a Container is being
   * specified not as a fully instantiated Component, but as a <i>Component config
   * object</i>. The <tt>xtype</tt> will be looked up at render time up to determine what
   * type of child Component to create.<br><br>
   * The predefined xtypes are listed {@link Ext.Component here}.
   * <br><br>
   * If you subclass Components to create your own Components, you may register
   * them using {@link Ext.ComponentMgr#registerType} in order to be able to
   * take advantage of lazy instantiation and rendering.
   */

  /**
   * @cfg {String} ptype
   * The registered <tt>ptype</tt> to create. This config option is not used when passing
   * a config object into a constructor. This config option is used only when
   * lazy instantiation is being used, and a Plugin is being
   * specified not as a fully instantiated Component, but as a <i>Component config
   * object</i>. The <tt>ptype</tt> will be looked up at render time up to determine what
   * type of Plugin to create.<br><br>
   * If you create your own Plugins, you may register them using
   * {@link Ext.ComponentMgr#registerPlugin} in order to be able to
   * take advantage of lazy instantiation and rendering.
   */

  /**
   * @cfg {String} cls
   * An optional extra CSS class that will be added to this component's Element (defaults to '').  This can be
   * useful for adding customized styles to the component or any of its children using standard CSS rules.
   */

  /**
   * @cfg {String} overCls
   * An optional extra CSS class that will be added to this component's Element when the mouse moves
   * over the Element, and removed when the mouse moves out. (defaults to '').  This can be
   * useful for adding customized 'active' or 'hover' styles to the component or any of its children using standard CSS rules.
   */

  /**
   * @cfg {String} style
   * A custom style specification to be applied to this component's Element.  Should be a valid argument to
   * {@link Ext.Element#applyStyles}.
   * <pre><code>
  new Ext.Panel({
  title: 'Some Title',
  renderTo: Ext.getBody(),
  width: 400, height: 300,
  layout: 'form',
  items: [{
      xtype: 'textarea',
      style: {
          width: '95%',
          marginBottom: '10px'
      }
  },
      new Ext.Button({
          text: 'Send',
          minWidth: '100',
          style: {
              marginBottom: '10px'
          }
      })
  ]
  });
   * </code></pre>
   */

  /**
   * @cfg {String} ctCls
   * <p>An optional extra CSS class that will be added to this component's container. This can be useful for
   * adding customized styles to the container or any of its children using standard CSS rules.  See
   * {@link Ext.layout.ContainerLayout}.{@link Ext.layout.ContainerLayout#extraCls extraCls} also.</p>
   * <p><b>Note</b>: <tt>ctCls</tt> defaults to <tt>''</tt> except for the following class
   * which assigns a value by default:
   * <div class="mdetail-params"><ul>
   * <li>{@link Ext.layout.Box Box Layout} : <tt>'x-box-layout-ct'</tt></li>
   * </ul></div>
   * To configure the above Class with an extra CSS class append to the default.  For example,
   * for BoxLayout (Hbox and Vbox):<pre><code>
   * ctCls: 'x-box-layout-ct custom-class'
   * </code></pre>
   * </p>
   */

  /**
   * @cfg {Boolean} disabled
   * Render this component disabled (default is false).
   */
  disabled: false,

  /**
   * @cfg {Boolean} hidden
   * Render this component hidden (default is false). If <tt>true</tt>, the
   * {@link #hide} method will be called internally.
   */
  hidden: false,

  /**
   * @cfg {Object/Array} plugins
   * An object or array of objects that will provide custom functionality for this component.  The only
   * requirement for a valid plugin is that it contain an init method that accepts a reference of type Ext.Component.
   * When a component is created, if any plugins are available, the component will call the init method on each
   * plugin, passing a reference to itself.  Each plugin can then call methods or respond to events on the
   * component as needed to provide its functionality.
   */

  /**
   * @cfg {Mixed} applyTo
   * <p>Specify the id of the element, a DOM element or an existing Element corresponding to a DIV
   * that is already present in the document that specifies some structural markup for this
   * component.</p><div><ul>
   * <li><b>Description</b> : <ul>
   * <div class="sub-desc">When <tt>applyTo</tt> is used, constituent parts of the component can also be specified
   * by id or CSS class name within the main element, and the component being created may attempt
   * to create its subcomponents from that markup if applicable.</div>
   * </ul></li>
   * <li><b>Notes</b> : <ul>
   * <div class="sub-desc">When using this config, a call to render() is not required.</div>
   * <div class="sub-desc">If applyTo is specified, any value passed for {@link #renderTo} will be ignored and the target
   * element's parent node will automatically be used as the component's container.</div>
   * </ul></li>
   * </ul></div>
   */

  /**
   * @cfg {Mixed} renderTo
   * <p>Specify the id of the element, a DOM element or an existing Element that this component
   * will be rendered into.</p><div><ul>
   * <li><b>Notes</b> : <ul>
   * <div class="sub-desc">Do <u>not</u> use this option if the Component is to be a child item of
   * a {@link Ext.Container Container}. It is the responsibility of the
   * {@link Ext.Container Container}'s {@link Ext.Container#layout layout manager}
   * to render and manage its child items.</div>
   * <div class="sub-desc">When using this config, a call to render() is not required.</div>
   * </ul></li>
   * </ul></div>
   * <p>See <tt>{@link #render}</tt> also.</p>
   */

  /**
   * @cfg {Boolean} stateful
   * <p>A flag which causes the Component to attempt to restore the state of
   * internal properties from a saved state on startup. The component must have
   * either a <code>{@link #stateId}</code> or <code>{@link #id}</code> assigned
   * for state to be managed. Auto-generated ids are not guaranteed to be stable
   * across page loads and cannot be relied upon to save and restore the same
   * state for a component.<p>
   * <p>For state saving to work, the state manager's provider must have been
   * set to an implementation of {@link Ext.state.Provider} which overrides the
   * {@link Ext.state.Provider#set set} and {@link Ext.state.Provider#get get}
   * methods to save and recall name/value pairs. A built-in implementation,
   * {@link Ext.state.CookieProvider} is available.</p>
   * <p>To set the state provider for the current page:</p>
   * <pre><code>
  Ext.state.Manager.setProvider(new Ext.state.CookieProvider({
  expires: new Date(new Date().getTime()+(1000*60*60*24*7)), //7 days from now
  }));
   * </code></pre>
   * <p>A stateful Component attempts to save state when one of the events
   * listed in the <code>{@link #stateEvents}</code> configuration fires.</p>
   * <p>To save state, a stateful Component first serializes its state by
   * calling <b><code>getState</code></b>. By default, this function does
   * nothing. The developer must provide an implementation which returns an
   * object hash which represents the Component's restorable state.</p>
   * <p>The value yielded by getState is passed to {@link Ext.state.Manager#set}
   * which uses the configured {@link Ext.state.Provider} to save the object
   * keyed by the Component's <code>{@link stateId}</code>, or, if that is not
   * specified, its <code>{@link #id}</code>.</p>
   * <p>During construction, a stateful Component attempts to <i>restore</i>
   * its state by calling {@link Ext.state.Manager#get} passing the
   * <code>{@link #stateId}</code>, or, if that is not specified, the
   * <code>{@link #id}</code>.</p>
   * <p>The resulting object is passed to <b><code>applyState</code></b>.
   * The default implementation of <code>applyState</code> simply copies
   * properties into the object, but a developer may override this to support
   * more behaviour.</p>
   * <p>You can perform extra processing on state save and restore by attaching
   * handlers to the {@link #beforestaterestore}, {@link #staterestore},
   * {@link #beforestatesave} and {@link #statesave} events.</p>
   */

  /**
   * @cfg {String} stateId
   * The unique id for this component to use for state management purposes
   * (defaults to the component id if one was set, otherwise null if the
   * component is using a generated id).
   * <p>See <code>{@link #stateful}</code> for an explanation of saving and
   * restoring Component state.</p>
   */

  /**
   * @cfg {Array} stateEvents
   * <p>An array of events that, when fired, should trigger this component to
   * save its state (defaults to none). <code>stateEvents</code> may be any type
   * of event supported by this component, including browser or custom events
   * (e.g., <tt>['click', 'customerchange']</tt>).</p>
   * <p>See <code>{@link #stateful}</code> for an explanation of saving and
   * restoring Component state.</p>
   */

  /**
   * @cfg {Mixed} autoEl
   * <p>A tag name or {@link Ext.DomHelper DomHelper} spec used to create the {@link #getEl Element} which will
   * encapsulate this Component.</p>
   * <p>You do not normally need to specify this. For the base classes {@link Ext.Component}, {@link Ext.BoxComponent},
   * and {@link Ext.Container}, this defaults to <b><tt>'div'</tt></b>. The more complex Ext classes use a more complex
   * DOM structure created by their own onRender methods.</p>
   * <p>This is intended to allow the developer to create application-specific utility Components encapsulated by
   * different DOM elements. Example usage:</p><pre><code>
  {
  xtype: 'box',
  autoEl: {
      tag: 'img',
      src: 'http://www.example.com/example.jpg'
  }
  }, {
  xtype: 'box',
  autoEl: {
      tag: 'blockquote',
      html: 'autoEl is cool!'
  }
  }, {
  xtype: 'container',
  autoEl: 'ul',
  cls: 'ux-unordered-list',
  items: {
      xtype: 'box',
      autoEl: 'li',
      html: 'First list item'
  }
  }
  </code></pre>
   */
  autoEl: 'div',

  /**
   * @cfg {String} disabledClass
   * CSS class added to the component when it is disabled (defaults to 'x-item-disabled').
   */
  disabledClass: 'x-item-disabled',

  /**
   * @cfg {Boolean} allowDomMove
   * Whether the component can move the Dom node when rendering (defaults to true).
   */
  allowDomMove: true,

  /**
   * @cfg {Boolean} autoShow
   * True if the component should check for hidden classes (e.g. 'x-hidden' or 'x-hide-display') and remove
   * them on render (defaults to false).
   */
  autoShow: false,

  /**
   * @cfg {String} hideMode
   * <p>How this component should be hidden. Supported values are <tt>'visibility'</tt>
   * (css visibility), <tt>'offsets'</tt> (negative offset position) and <tt>'display'</tt>
   * (css display).</p>
   * <br><p><b>Note</b>: the default of <tt>'display'</tt> is generally preferred
   * since items are automatically laid out when they are first shown (no sizing
   * is done while hidden).</p>
   */
  hideMode: 'display',

  /**
   * @cfg {Boolean} hideParent
   * True to hide and show the component's container when hide/show is called on the component, false to hide
   * and show the component itself (defaults to false).  For example, this can be used as a shortcut for a hide
   * button on a window by setting hide:true on the button when adding it to its parent container.
   */
  hideParent: false,

  /**
   * <p>The {@link Ext.Element} which encapsulates this Component. Read-only.</p>
   * <p>This will <i>usually</i> be a &lt;DIV> element created by the class's onRender method, but
   * that may be overridden using the <code>{@link #autoEl}</code> config.</p>
   * <br><p><b>Note</b>: this element will not be available until this Component has been rendered.</p><br>
   * <p>To add listeners for <b>DOM events</b> to this Component (as opposed to listeners
   * for this Component's own Observable events), see the {@link Ext.util.Observable#listeners listeners}
   * config for a suggestion, or use a render listener directly:</p><pre><code>
  new Ext.Panel({
  title: 'The Clickable Panel',
  listeners: {
      render: function(p) {
          // Append the Panel to the click handler&#39;s argument list.
          p.getEl().on('click', handlePanelClick.createDelegate(null, [p], true));
      },
      single: true  // Remove the listener after first invocation
  }
  });
  </code></pre>
   * <p>See also <tt>{@link #getEl getEl}</p>
   * @type Ext.Element
   * @property el
   */

  /**
   * This Component's owner {@link Ext.Container Container} (defaults to undefined, and is set automatically when
   * this Component is added to a Container).  Read-only.
   * <p><b>Note</b>: to access items within the Container see <tt>{@link #itemId}</tt>.</p>
   * @type Ext.Container
   * @property ownerCt
   */

  /**
   * True if this component is hidden. Read-only.
   * @type Boolean
   * @property hidden
   */

  /**
   * True if this component is disabled. Read-only.
   * @type Boolean
   * @property disabled
   */

  /**
   * True if this component has been rendered. Read-only.
   * @type Boolean
   * @property rendered
   */
  rendered: false,

  /**
   * @cfg {String} contentEl
   * <p>Optional. Specify an existing HTML element, or the <code>id</code> of an existing HTML element to use as the content
   * for this component.</p>
   * <ul>
   * <li><b>Description</b> :
   * <div class="sub-desc">This config option is used to take an existing HTML element and place it in the layout element
   * of a new component (it simply moves the specified DOM element <i>after the Component is rendered</i> to use as the content.</div></li>
   * <li><b>Notes</b> :
   * <div class="sub-desc">The specified HTML element is appended to the layout element of the component <i>after any configured
   * {@link #html HTML} has been inserted</i>, and so the document will not contain this element at the time the {@link #render} event is fired.</div>
   * <div class="sub-desc">The specified HTML element used will not participate in any <code><b>{@link Ext.Container#layout layout}</b></code>
   * scheme that the Component may use. It is just HTML. Layouts operate on child <code><b>{@link Ext.Container#items items}</b></code>.</div>
   * <div class="sub-desc">Add either the <code>x-hidden</code> or the <code>x-hide-display</code> CSS class to
   * prevent a brief flicker of the content before it is rendered to the panel.</div></li>
   * </ul>
   */

  /**
   * @cfg {String/Object} html
   * An HTML fragment, or a {@link Ext.DomHelper DomHelper} specification to use as the layout element
   * content (defaults to ''). The HTML content is added after the component is rendered,
   * so the document will not contain this HTML at the time the {@link #render} event is fired.
   * This content is inserted into the body <i>before</i> any configured {@link #contentEl} is appended.
   */

  /**
   * @cfg {Mixed} tpl
   * An <bold>{@link Ext.Template}</bold>, <bold>{@link Ext.XTemplate}</bold>
   * or an array of strings to form an Ext.XTemplate.
   * Used in conjunction with the <code>{@link #data}</code> and
   * <code>{@link #tplWriteMode}</code> configurations.
   */

  /**
   * @cfg {String} tplWriteMode The Ext.(X)Template method to use when
   * updating the content area of the Component. Defaults to <tt>'overwrite'</tt>
   * (see <code>{@link Ext.XTemplate#overwrite}</code>).
   */
  tplWriteMode: 'overwrite',

  /**
   * @cfg {Mixed} data
   * The initial set of data to apply to the <code>{@link #tpl}</code> to
   * update the content area of the Component.
   */
  // private
  ctype: 'Ext.Component',
  // private
  actionMode: 'el',
  // private
  getActionEl: function getActionEl() {
    return this[this.actionMode];
  },
  initPlugin: function initPlugin(p) {
    if (p.ptype && !Ext.isFunction(p.init)) {
      p = Ext.ComponentMgr.createPlugin(p);
    } else if (Ext.isString(p)) {
      p = Ext.ComponentMgr.createPlugin({
        ptype: p
      });
    }

    p.init(this);
    return p;
  },

  /* // protected
   * Function to be implemented by Component subclasses to be part of standard component initialization flow (it is empty by default).
   * <pre><code>
  // Traditional constructor:
  Ext.Foo = function(config){
  // call superclass constructor:
  Ext.Foo.superclass.constructor.call(this, config);
   this.addEvents({
      // add events
  });
  };
  Ext.extend(Ext.Foo, Ext.Bar, {
  // class body
  }
  // initComponent replaces the constructor:
  Ext.Foo = Ext.extend(Ext.Bar, {
  initComponent : function(){
      // call superclass initComponent
      Ext.Container.superclass.initComponent.call(this);
       this.addEvents({
          // add events
      });
  }
  }
  </code></pre>
   */
  initComponent: Ext.emptyFn,

  /**
   * <p>Render this Component into the passed HTML element.</p>
   * <p><b>If you are using a {@link Ext.Container Container} object to house this Component, then
   * do not use the render method.</b></p>
   * <p>A Container's child Components are rendered by that Container's
   * {@link Ext.Container#layout layout} manager when the Container is first rendered.</p>
   * <p>Certain layout managers allow dynamic addition of child components. Those that do
   * include {@link Ext.layout.CardLayout}, {@link Ext.layout.AnchorLayout},
   * {@link Ext.layout.FormLayout}, {@link Ext.layout.TableLayout}.</p>
   * <p>If the Container is already rendered when a new child Component is added, you may need to call
   * the Container's {@link Ext.Container#doLayout doLayout} to refresh the view which causes any
   * unrendered child Components to be rendered. This is required so that you can add multiple
   * child components if needed while only refreshing the layout once.</p>
   * <p>When creating complex UIs, it is important to remember that sizing and positioning
   * of child items is the responsibility of the Container's {@link Ext.Container#layout layout} manager.
   * If you expect child items to be sized in response to user interactions, you must
   * configure the Container with a layout manager which creates and manages the type of layout you
   * have in mind.</p>
   * <p><b>Omitting the Container's {@link Ext.Container#layout layout} config means that a basic
   * layout manager is used which does nothing but render child components sequentially into the
   * Container. No sizing or positioning will be performed in this situation.</b></p>
   * @param {Element/HTMLElement/String} container (optional) The element this Component should be
   * rendered into. If it is being created from existing markup, this should be omitted.
   * @param {String/Number} position (optional) The element ID or DOM node index within the container <b>before</b>
   * which this component will be inserted (defaults to appending to the end of the container)
   */
  render: function render(container, position) {
    if (!this.rendered && this.fireEvent('beforerender', this) !== false) {
      if (!container && this.el) {
        this.el = Ext.get(this.el);
        container = this.el.dom.parentNode;
        this.allowDomMove = false;
      }

      this.container = Ext.get(container);

      if (this.ctCls) {
        this.container.addClass(this.ctCls);
      }

      this.rendered = true;

      if (position !== undefined) {
        if (Ext.isNumber(position)) {
          position = this.container.dom.childNodes[position];
        } else {
          position = Ext.getDom(position);
        }
      }

      this.onRender(this.container, position || null);

      if (this.autoShow) {
        this.el.removeClass(['x-hidden', 'x-hide-' + this.hideMode]);
      }

      if (this.cls) {
        this.el.addClass(this.cls);
        delete this.cls;
      }

      if (this.style) {
        this.el.applyStyles(this.style);
        delete this.style;
      }

      if (this.overCls) {
        this.el.addClassOnOver(this.overCls);
      }

      this.fireEvent('render', this); // Populate content of the component with html, contentEl or
      // a tpl.

      var contentTarget = this.getContentTarget();

      if (this.html) {
        contentTarget.update(Ext.DomHelper.markup(this.html));
        delete this.html;
      }

      if (this.contentEl) {
        var ce = Ext.getDom(this.contentEl);
        Ext.fly(ce).removeClass(['x-hidden', 'x-hide-display']);
        contentTarget.appendChild(ce);
      }

      if (this.tpl) {
        if (!this.tpl.compile) {
          this.tpl = new Ext.XTemplate(this.tpl);
        }

        if (this.data) {
          this.tpl[this.tplWriteMode](contentTarget, this.data);
          delete this.data;
        }
      }

      this.afterRender(this.container);

      _.defer(_.bind(this.componentDidMount, this, this));

      if (this.hidden) {
        // call this so we don't fire initial hide events.
        this.doHide();
      }

      if (this.disabled) {
        // pass silent so the event doesn't fire the first time.
        this.disable(true);
      }

      if (this.stateful !== false) {
        this.initStateEvents();
      }

      this.fireEvent('afterrender', this);
    }

    return this;
  },
  isRendered: function isRendered() {
    var me = this;
    return new Promise(function (fulfill, reject) {
      if (me.rendered) {
        fulfill(true);
      } else {
        me.on('render', fulfill);
      }
    });
  },

  /**
   * Update the content area of a component.
   * @param {Mixed} htmlOrData
   * If this component has been configured with a template via the tpl config
   * then it will use this argument as data to populate the template.
   * If this component was not configured with a template, the components
   * content area will be updated via Ext.Element update
   * @param {Boolean} loadScripts
   * (optional) Only legitimate when using the html configuration. Defaults to false
   * @param {Function} callback
   * (optional) Only legitimate when using the html configuration. Callback to execute when scripts have finished loading
   */
  update: function update(htmlOrData, loadScripts, cb) {
    var contentTarget = this.getContentTarget();

    if (this.tpl && typeof htmlOrData !== "string") {
      this.tpl[this.tplWriteMode](contentTarget, htmlOrData || {});
    } else {
      var html = Ext.isObject(htmlOrData) ? Ext.DomHelper.markup(htmlOrData) : htmlOrData;
      contentTarget.update(html, loadScripts, cb);
    }
  },

  /**
   * @private
   * Method to manage awareness of when components are added to their
   * respective Container, firing an added event.
   * References are established at add time rather than at render time.
   * @param {Ext.Container} container Container which holds the component
   * @param {number} pos Position at which the component was added
   */
  onAdded: function onAdded(container, pos) {
    this.ownerCt = container;
    this.initRef();
    this.fireEvent('added', this, container, pos);
  },

  /**
   * @private
   * Method to manage awareness of when components are removed from their
   * respective Container, firing an removed event. References are properly
   * cleaned up after removing a component from its owning container.
   */
  onRemoved: function onRemoved() {
    this.removeRef();
    this.fireEvent('removed', this, this.ownerCt);
    delete this.ownerCt;
  },

  /**
   * @private
   * Method to establish a reference to a component.
   */
  initRef: function initRef() {
    /**
     * @cfg {String} ref
     * <p>A path specification, relative to the Component's <code>{@link #ownerCt}</code>
     * specifying into which ancestor Container to place a named reference to this Component.</p>
     * <p>The ancestor axis can be traversed by using '/' characters in the path.
     * For example, to put a reference to a Toolbar Button into <i>the Panel which owns the Toolbar</i>:</p><pre><code>
    var myGrid = new Ext.grid.EditorGridPanel({
    title: 'My EditorGridPanel',
    store: myStore,
    colModel: myColModel,
    tbar: [{
    text: 'Save',
    handler: saveChanges,
    disabled: true,
    ref: '../saveButton'
    }],
    listeners: {
    afteredit: function() {
    //          The button reference is in the GridPanel
        myGrid.saveButton.enable();
    }
    }
    });
    </code></pre>
     * <p>In the code above, if the <code>ref</code> had been <code>'saveButton'</code>
     * the reference would have been placed into the Toolbar. Each '/' in the <code>ref</code>
     * moves up one level from the Component's <code>{@link #ownerCt}</code>.</p>
     * <p>Also see the <code>{@link #added}</code> and <code>{@link #removed}</code> events.</p>
     */
    if (this.ref && !this.refOwner) {
      var levels = this.ref.split('/'),
          last = levels.length,
          i = 0,
          t = this;

      while (t && i < last) {
        t = t.ownerCt;
        ++i;
      }

      if (t) {
        t[this.refName = levels[--i]] = this;
        /**
         * @type Ext.Container
         * @property refOwner
         * The ancestor Container into which the {@link #ref} reference was inserted if this Component
         * is a child of a Container, and has been configured with a <code>ref</code>.
         */

        this.refOwner = t;
      }
    }
  },
  removeRef: function removeRef() {
    if (this.refOwner && this.refName) {
      delete this.refOwner[this.refName];
      delete this.refOwner;
    }
  },
  // private
  initState: function initState() {
    if (Ext.state.Manager) {
      var id = this.getStateId();

      if (id) {
        var state = Ext.state.Manager.get(id) || this.initialState;

        if (state) {
          if (this.fireEvent('beforestaterestore', this, state) !== false) {
            this.applyState(Ext.apply({}, state));
            this.fireEvent('staterestore', this, state);
          }
        }
      }
    }
  },
  // private
  getStateId: function getStateId() {
    return this.stateId || (/^(ext-comp-|ext-gen)/.test(String(this.id)) ? null : this.id);
  },
  // private
  initStateEvents: function initStateEvents() {
    if (this.stateEvents) {
      for (var i = 0, e; e = this.stateEvents[i]; i++) {
        this.on(e, this.saveState, this, {
          delay: 100
        });
      }
    }
  },
  // private
  applyState: function applyState(state) {
    if (state) {
      Ext.apply(this, state);
    }
  },
  // private
  getState: function getState() {
    return null;
  },
  // private
  saveState: function saveState() {
    if (Ext.state.Manager && this.stateful !== false) {
      var id = this.getStateId();

      if (id) {
        var state = this.getState();

        if (this.fireEvent('beforestatesave', this, state) !== false) {
          Ext.state.Manager.set(id, state);
          this.fireEvent('statesave', this, state);
        }
      }
    }
  },

  /**
   * Apply this component to existing markup that is valid. With this function, no call to render() is required.
   * @param {String/HTMLElement} el
   */
  applyToMarkup: function applyToMarkup(el) {
    this.allowDomMove = false;
    this.el = Ext.get(el);
    this.render(this.el.dom.parentNode);
  },

  /**
   * Adds a CSS class to the component's underlying element.
   * @param {string} cls The CSS class name to add
   * @return {Ext.Component} this
   */
  addClass: function addClass(cls) {
    if (this.el) {
      this.el.addClass(cls);
    } else {
      this.cls = this.cls ? this.cls + ' ' + cls : cls;
    }

    return this;
  },

  /**
   * Removes a CSS class from the component's underlying element.
   * @param {string} cls The CSS class name to remove
   * @return {Ext.Component} this
   */
  removeClass: function removeClass(cls) {
    if (this.el) {
      this.el.removeClass(cls);
    } else if (this.cls) {
      this.cls = this.cls.split(' ').remove(cls).join(' ');
    }

    return this;
  },
  // private
  // default function is not really useful
  onRender: function onRender(ct, position) {
    if (!this.el && this.autoEl) {
      if (Ext.isString(this.autoEl)) {
        this.el = document.createElement(this.autoEl);
      } else {
        var div = document.createElement('div');
        Ext.DomHelper.overwrite(div, this.autoEl);
        this.el = div.firstChild;
      }

      if (!this.el.id) {
        this.el.id = this.getId();
      }
    }

    if (this.el) {
      this.el = Ext.get(this.el);

      if (this.allowDomMove !== false) {
        ct.dom.insertBefore(this.el.dom, position);

        if (div) {
          Ext.removeNode(div);
          div = null;
        }
      }
    }
  },
  // private
  getAutoCreate: function getAutoCreate() {
    var cfg = Ext.isObject(this.autoCreate) ? this.autoCreate : Ext.apply({}, this.defaultAutoCreate);

    if (this.id && !cfg.id) {
      cfg.id = this.id;
    }

    return cfg;
  },
  // private
  afterRender: Ext.emptyFn,
  // https://reactjs.org/docs/react-component.html#componentdidmount
  componentDidMount: Ext.emptyFn,

  /**
   * Destroys this component by purging any event listeners, removing the component's element from the DOM,
   * removing the component from its {@link Ext.Container} (if applicable) and unregistering it from
   * {@link Ext.ComponentMgr}.  Destruction is generally handled automatically by the framework and this method
   * should usually not need to be called directly.
   *
   */
  destroy: function destroy() {
    if (!this.isDestroyed) {
      if (this.fireEvent('beforedestroy', this) !== false) {
        this.destroying = true;
        this.beforeDestroy();
        this.componentWillUnmount(this);

        if (this.ownerCt && this.ownerCt.remove) {
          this.ownerCt.remove(this, false);
        }

        if (this.rendered) {
          this.el.remove();

          if (this.actionMode == 'container' || this.removeMode == 'container') {
            this.container.remove();
          }
        }

        this.onDestroy();
        Ext.ComponentMgr.unregister(this);
        this.fireEvent('destroy', this);
        this.purgeListeners();
        this.destroying = false;
        this.isDestroyed = true;
      }
    }
  },
  deleteMembers: function deleteMembers() {
    var args = arguments;

    for (var i = 0, len = args.length; i < len; ++i) {
      delete this[args[i]];
    }
  },
  // private
  beforeDestroy: Ext.emptyFn,
  // https://reactjs.org/docs/react-component.html#componentwillunmount
  componentWillUnmount: Ext.emptyFn,
  // private
  onDestroy: Ext.emptyFn,

  /**
   * <p>Returns the {@link Ext.Element} which encapsulates this Component.</p>
   * <p>This will <i>usually</i> be a &lt;DIV> element created by the class's onRender method, but
   * that may be overridden using the {@link #autoEl} config.</p>
   * <br><p><b>Note</b>: this element will not be available until this Component has been rendered.</p><br>
   * <p>To add listeners for <b>DOM events</b> to this Component (as opposed to listeners
   * for this Component's own Observable events), see the {@link #listeners} config for a suggestion,
   * or use a render listener directly:</p><pre><code>
  new Ext.Panel({
  title: 'The Clickable Panel',
  listeners: {
      render: function(p) {
          // Append the Panel to the click handler&#39;s argument list.
          p.getEl().on('click', handlePanelClick.createDelegate(null, [p], true));
      },
      single: true  // Remove the listener after first invocation
  }
  });
  </code></pre>
   * @return {Ext.Element} The Element which encapsulates this Component.
   */
  getEl: function getEl() {
    return this.el;
  },
  // private
  getContentTarget: function getContentTarget() {
    return this.el;
  },

  /**
   * Returns the <code>id</code> of this component or automatically generates and
   * returns an <code>id</code> if an <code>id</code> is not defined yet:<pre><code>
   * 'ext-comp-' + (++Ext.Component.AUTO_ID)
   * </code></pre>
   * @return {String} id
   */
  getId: function getId() {
    return this.id || (this.id = 'ext-comp-' + ++Ext.Component.AUTO_ID);
  },

  /**
   * Returns the <code>{@link #itemId}</code> of this component.  If an
   * <code>{@link #itemId}</code> was not assigned through configuration the
   * <code>id</code> is returned using <code>{@link #getId}</code>.
   * @return {String}
   */
  getItemId: function getItemId() {
    return this.itemId || this.getId();
  },

  /**
   * Try to focus this component.
   * @param {Boolean} selectText (optional) If applicable, true to also select the text in this component
   * @param {Boolean/Number} delay (optional) Delay the focus this number of milliseconds (true for 10 milliseconds)
   * @return {Ext.Component} this
   */
  focus: function focus(selectText, delay) {
    if (delay) {
      this.focus.defer(Ext.isNumber(delay) ? delay : 10, this, [selectText, false]);
      return;
    }

    if (this.rendered) {
      this.el.focus();

      if (selectText === true) {
        this.el.dom.select();
      }
    }

    return this;
  },
  // private
  blur: function blur() {
    if (this.rendered) {
      this.el.blur();
    }

    return this;
  },

  /**
   * Disable this component and fire the 'disable' event.
   * @return {Ext.Component} this
   */
  disable: function disable(
  /* private */
  silent) {
    if (this.rendered) {
      this.onDisable();
    }

    this.disabled = true;

    if (silent !== true) {
      this.fireEvent('disable', this);
    }

    return this;
  },
  // private
  onDisable: function onDisable() {
    this.getActionEl().addClass(this.disabledClass);
    this.el.dom.disabled = true;
  },

  /**
   * Enable this component and fire the 'enable' event.
   * @return {Ext.Component} this
   */
  enable: function enable() {
    if (this.rendered) {
      this.onEnable();
    }

    this.disabled = false;
    this.fireEvent('enable', this);
    return this;
  },
  // private
  onEnable: function onEnable() {
    this.getActionEl().removeClass(this.disabledClass);
    this.el.dom.disabled = false;
  },

  /**
   * Convenience function for setting disabled/enabled by boolean.
   * @param {Boolean} disabled
   * @return {Ext.Component} this
   */
  setDisabled: function setDisabled(disabled) {
    return this[disabled ? 'disable' : 'enable']();
  },

  /**
   * Show this component.  Listen to the '{@link #beforeshow}' event and return
   * <tt>false</tt> to cancel showing the component.  Fires the '{@link #show}'
   * event after showing the component.
   * @return {Ext.Component} this
   */
  show: function show() {
    if (this.fireEvent('beforeshow', this) !== false) {
      this.hidden = false;

      if (this.autoRender) {
        this.render(Ext.isBoolean(this.autoRender) ? Ext.getBody() : this.autoRender);
      }

      if (this.rendered) {
        this.onShow();
      }

      this.fireEvent('show', this);
    }

    return this;
  },
  // private
  onShow: function onShow() {
    this.getVisibilityEl().removeClass('x-hide-' + this.hideMode);
  },

  /**
   * Hide this component.  Listen to the '{@link #beforehide}' event and return
   * <tt>false</tt> to cancel hiding the component.  Fires the '{@link #hide}'
   * event after hiding the component. Note this method is called internally if
   * the component is configured to be <code>{@link #hidden}</code>.
   * @return {Ext.Component} this
   */
  hide: function hide() {
    if (this.fireEvent('beforehide', this) !== false) {
      this.doHide();
      this.fireEvent('hide', this);
    }

    return this;
  },
  // private
  doHide: function doHide() {
    this.hidden = true;

    if (this.rendered) {
      this.onHide();
    }
  },
  // private
  onHide: function onHide() {
    this.getVisibilityEl().addClass('x-hide-' + this.hideMode);
  },
  // private
  getVisibilityEl: function getVisibilityEl() {
    return this.hideParent ? this.container : this.getActionEl();
  },

  /**
   * Convenience function to hide or show this component by boolean.
   * @param {Boolean} visible True to show, false to hide
   * @return {Ext.Component} this
   */
  setVisible: function setVisible(visible) {
    return this[visible ? 'show' : 'hide']();
  },

  /**
   * Returns true if this component is visible.
   * @return {Boolean} True if this component is visible, false otherwise.
   */
  isVisible: function isVisible() {
    return this.rendered && this.getVisibilityEl().isVisible();
  },
  isHidden: function isHidden() {
    return !this.isVisible();
  },

  /**
   * Clone the current component using the original config values passed into this instance by default.
   * @param {Object} overrides A new config containing any properties to override in the cloned version.
   * An id property can be passed on this object, otherwise one will be generated to avoid duplicates.
   * @return {Ext.Component} clone The cloned copy of this component
   */
  cloneConfig: function cloneConfig(overrides) {
    overrides = overrides || {};
    var id = overrides.id || Ext.id();
    var cfg = Ext.applyIf(overrides, this.initialConfig);
    cfg.id = id; // prevent dup id

    return new this.constructor(cfg);
  },

  /**
   * Gets the xtype for this component as registered with {@link Ext.ComponentMgr}. For a list of all
   * available xtypes, see the {@link Ext.Component} header. Example usage:
   * <pre><code>
  var t = new Ext.form.TextField();
  alert(t.getXType());  // alerts 'textfield'
  </code></pre>
   * @return {String} The xtype
   */
  getXType: function getXType() {
    return this.constructor.xtype;
  },

  /**
   * <p>Tests whether or not this Component is of a specific xtype. This can test whether this Component is descended
   * from the xtype (default) or whether it is directly of the xtype specified (shallow = true).</p>
   * <p><b>If using your own subclasses, be aware that a Component must register its own xtype
   * to participate in determination of inherited xtypes.</b></p>
   * <p>For a list of all available xtypes, see the {@link Ext.Component} header.</p>
   * <p>Example usage:</p>
   * <pre><code>
  var t = new Ext.form.TextField();
  var isText = t.isXType('textfield');        // true
  var isBoxSubclass = t.isXType('box');       // true, descended from BoxComponent
  var isBoxInstance = t.isXType('box', true); // false, not a direct BoxComponent instance
  </code></pre>
   * @param {String} xtype The xtype to check for this Component
   * @param {Boolean} shallow (optional) False to check whether this Component is descended from the xtype (this is
   * the default), or true to check whether this Component is directly of the specified xtype.
   * @return {Boolean} True if this component descends from the specified xtype, false otherwise.
   */
  isXType: function isXType(xtype, shallow) {
    //assume a string by default
    if (Ext.isFunction(xtype)) {
      xtype = xtype.xtype; //handle being passed the class, e.g. Ext.Component
    } else if (Ext.isObject(xtype)) {
      xtype = xtype.constructor.xtype; //handle being passed an instance
    }

    return !shallow ? ('/' + this.getXTypes() + '/').indexOf('/' + xtype + '/') != -1 : this.constructor.xtype == xtype;
  },

  /**
   * <p>Returns this Component's xtype hierarchy as a slash-delimited string. For a list of all
   * available xtypes, see the {@link Ext.Component} header.</p>
   * <p><b>If using your own subclasses, be aware that a Component must register its own xtype
   * to participate in determination of inherited xtypes.</b></p>
   * <p>Example usage:</p>
   * <pre><code>
  var t = new Ext.form.TextField();
  alert(t.getXTypes());  // alerts 'component/box/field/textfield'
  </code></pre>
   * @return {String} The xtype hierarchy string
   */
  getXTypes: function getXTypes() {
    var tc = this.constructor;

    if (!tc.xtypes) {
      var c = [],
          sc = this;

      while (sc && sc.constructor.xtype) {
        c.unshift(sc.constructor.xtype);
        sc = sc.constructor.superclass;
      }

      tc.xtypeChain = c;
      tc.xtypes = c.join('/');
    }

    return tc.xtypes;
  },

  /**
   * Find a container above this component at any level by a custom function. If the passed function returns
   * true, the container will be returned.
   * @param {Function} fn The custom function to call with the arguments (container, this component).
   * @return {Ext.Container} The first Container for which the custom function returns true
   */
  findParentBy: function findParentBy(fn) {
    for (var p = this.ownerCt; p != null && !fn(p, this); p = p.ownerCt);

    return p || null;
  },

  /**
   * Find a container above this component at any level by xtype or class
   * @param {String/Class} xtype The xtype string for a component, or the class of the component directly
   * @return {Ext.Container} The first Container which matches the given xtype or class
   */
  findParentByType: function findParentByType(xtype) {
    return Ext.isFunction(xtype) ? this.findParentBy(function (p) {
      return p.constructor === xtype;
    }) : this.findParentBy(function (p) {
      return p.constructor.xtype === xtype;
    });
  },
  // protected
  getPositionEl: function getPositionEl() {
    return this.positionEl || this.el;
  },
  // private
  purgeListeners: function purgeListeners() {
    Ext.Component.superclass.purgeListeners.call(this);

    if (this.mons) {
      this.on('beforedestroy', this.clearMons, this, {
        single: true
      });
    }
  },
  // private
  clearMons: function clearMons() {
    Ext.each(this.mons, function (m) {
      m.item.un(m.ename, m.fn, m.scope);
    }, this);
    this.mons = [];
  },
  // private
  createMons: function createMons() {
    if (!this.mons) {
      this.mons = [];
      this.on('beforedestroy', this.clearMons, this, {
        single: true
      });
    }
  },

  /**
   * <p>Adds listeners to any Observable object (or Elements) which are automatically removed when this Component
   * is destroyed. Usage:</p><code><pre>
  myGridPanel.mon(myGridPanel.getSelectionModel(), 'selectionchange', handleSelectionChange, null, {buffer: 50});
  </pre></code>
   * <p>or:</p><code><pre>
  myGridPanel.mon(myGridPanel.getSelectionModel(), {
  selectionchange: handleSelectionChange,
  buffer: 50
  });
  </pre></code>
   * @param {Observable|Element} item The item to which to add a listener/listeners.
   * @param {Object|String} ename The event name, or an object containing event name properties.
   * @param {Function} fn Optional. If the <code>ename</code> parameter was an event name, this
   * is the handler function.
   * @param {Object} scope Optional. If the <code>ename</code> parameter was an event name, this
   * is the scope (<code>this</code> reference) in which the handler function is executed.
   * @param {Object} opt Optional. If the <code>ename</code> parameter was an event name, this
   * is the {@link Ext.util.Observable#addListener addListener} options.
   */
  mon: function mon(item, ename, fn, scope, opt) {
    this.createMons();

    if (Ext.isObject(ename)) {
      var propRe = /^(?:scope|delay|buffer|single|stopEvent|preventDefault|stopPropagation|normalized|args|delegate)$/;
      var o = ename;

      for (var e in o) {
        if (propRe.test(e)) {
          continue;
        }

        if (Ext.isFunction(o[e])) {
          // shared options
          this.mons.push({
            item: item,
            ename: e,
            fn: o[e],
            scope: o.scope
          });
          item.on(e, o[e], o.scope, o);
        } else {
          // individual options
          this.mons.push({
            item: item,
            ename: e,
            fn: o[e],
            scope: o.scope
          });
          item.on(e, o[e]);
        }
      }

      return;
    }

    this.mons.push({
      item: item,
      ename: ename,
      fn: fn,
      scope: scope
    });
    item.on(ename, fn, scope, opt);
  },

  /**
   * Removes listeners that were added by the {@link #mon} method.
   * @param {Observable|Element} item The item from which to remove a listener/listeners.
   * @param {Object|String} ename The event name, or an object containing event name properties.
   * @param {Function} fn Optional. If the <code>ename</code> parameter was an event name, this
   * is the handler function.
   * @param {Object} scope Optional. If the <code>ename</code> parameter was an event name, this
   * is the scope (<code>this</code> reference) in which the handler function is executed.
   */
  mun: function mun(item, ename, fn, scope) {
    var found, mon;
    this.createMons();

    for (var i = 0, len = this.mons.length; i < len; ++i) {
      mon = this.mons[i];

      if (item === mon.item && ename == mon.ename && fn === mon.fn && scope === mon.scope) {
        this.mons.splice(i, 1);
        item.un(ename, fn, scope);
        found = true;
        break;
      }
    }

    return found;
  },

  /**
   * Returns the next component in the owning container
   * @return Ext.Component
   */
  nextSibling: function nextSibling() {
    if (this.ownerCt) {
      var index = this.ownerCt.items.indexOf(this);

      if (index != -1 && index + 1 < this.ownerCt.items.getCount()) {
        return this.ownerCt.items.itemAt(index + 1);
      }
    }

    return null;
  },

  /**
   * Returns the previous component in the owning container
   * @return Ext.Component
   */
  previousSibling: function previousSibling() {
    if (this.ownerCt) {
      var index = this.ownerCt.items.indexOf(this);

      if (index > 0) {
        return this.ownerCt.items.itemAt(index - 1);
      }
    }

    return null;
  },

  /**
   * Provides the link for Observable's fireEvent method to bubble up the ownership hierarchy.
   * @return {Ext.Container} the Container which owns this Component.
   */
  getBubbleTarget: function getBubbleTarget() {
    return this.ownerCt;
  },

  /**
   * is this component rendered?
   * @return {Promise}
   */
  afterIsRendered: function afterIsRendered() {
    var me = this;

    if (this.rendered) {
      return Promise.resolve(me);
    }

    return new Promise(function (resolve) {
      me.on('render', resolve);
    });
  }
});
Ext.reg('component', Ext.Component);

/***/ }),
/* 752 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Action
 * <p>An Action is a piece of reusable functionality that can be abstracted out of any particular component so that it
 * can be usefully shared among multiple components.  Actions let you share handlers, configuration options and UI
 * updates across any components that support the Action interface (primarily {@link Ext.Toolbar}, {@link Ext.Button}
 * and {@link Ext.menu.Menu} components).</p>
 * <p>Aside from supporting the config object interface, any component that needs to use Actions must also support
 * the following method list, as these will be called as needed by the Action class: setText(string), setIconCls(string),
 * setDisabled(boolean), setVisible(boolean) and setHandler(function).</p>
 * Example usage:<br>
 * <pre><code>
// Define the shared action.  Each component below will have the same
// display text and icon, and will display the same message on click.
var action = new Ext.Action({
    {@link #text}: 'Do something',
    {@link #handler}: function(){
        Ext.Msg.alert('Click', 'You did something.');
    },
    {@link #iconCls}: 'do-something',
    {@link #itemId}: 'myAction'
});

var panel = new Ext.Panel({
    title: 'Actions',
    width: 500,
    height: 300,
    tbar: [
        // Add the action directly to a toolbar as a menu button
        action,
        {
            text: 'Action Menu',
            // Add the action to a menu as a text item
            menu: [action]
        }
    ],
    items: [
        // Add the action to the panel body as a standard button
        new Ext.Button(action)
    ],
    renderTo: Ext.getBody()
});

// Change the text for all components using the action
action.setText('Something else');

// Reference an action through a container using the itemId
var btn = panel.getComponent('myAction');
var aRef = btn.baseAction;
aRef.setText('New text');
</code></pre>
 * @constructor
 * @param {Object} config The configuration options
 */
Ext.Action = Ext.extend(Object, {
  /**
   * @cfg {String} text The text to set for all components using this action (defaults to '').
   */

  /**
   * @cfg {String} iconCls
   * The CSS class selector that specifies a background image to be used as the header icon for
   * all components using this action (defaults to '').
   * <p>An example of specifying a custom icon class would be something like:
   * </p><pre><code>
  // specify the property in the config for the class:
   ...
   iconCls: 'do-something'
  // css class that specifies background image to be used as the icon image:
  .do-something { background-image: url(../images/my-icon.gif) 0 6px no-repeat !important; }
  </code></pre>
   */

  /**
   * @cfg {Boolean} disabled True to disable all components using this action, false to enable them (defaults to false).
   */

  /**
   * @cfg {Boolean} hidden True to hide all components using this action, false to show them (defaults to false).
   */

  /**
   * @cfg {Function} handler The function that will be invoked by each component tied to this action
   * when the component's primary event is triggered (defaults to undefined).
   */

  /**
   * @cfg {String} itemId
   * See {@link Ext.Component}.{@link Ext.Component#itemId itemId}.
   */

  /**
   * @cfg {Object} scope The scope (<tt><b>this</b></tt> reference) in which the
   * <code>{@link #handler}</code> is executed. Defaults to this Button.
   */
  constructor: function constructor(config) {
    this.initialConfig = config;
    this.itemId = config.itemId = config.itemId || config.id || Ext.id();
    this.items = [];
  },
  // private
  isAction: true,

  /**
   * Sets the text to be displayed by all components using this action.
   * @param {String} text The text to display
   */
  setText: function setText(text) {
    this.initialConfig.text = text;
    this.callEach('setText', [text]);
  },

  /**
   * Gets the text currently displayed by all components using this action.
   */
  getText: function getText() {
    return this.initialConfig.text;
  },

  /**
   * Sets the icon CSS class for all components using this action.  The class should supply
   * a background image that will be used as the icon image.
   * @param {String} cls The CSS class supplying the icon image
   */
  setIconClass: function setIconClass(cls) {
    this.initialConfig.iconCls = cls;
    this.callEach('setIconClass', [cls]);
  },

  /**
   * Gets the icon CSS class currently used by all components using this action.
   */
  getIconClass: function getIconClass() {
    return this.initialConfig.iconCls;
  },

  /**
   * Sets the disabled state of all components using this action.  Shortcut method
   * for {@link #enable} and {@link #disable}.
   * @param {Boolean} disabled True to disable the component, false to enable it
   */
  setDisabled: function setDisabled(v) {
    this.initialConfig.disabled = v;
    this.callEach('setDisabled', [v]);
  },

  /**
   * Enables all components using this action.
   */
  enable: function enable() {
    this.setDisabled(false);
  },

  /**
   * Disables all components using this action.
   */
  disable: function disable() {
    this.setDisabled(true);
  },

  /**
   * Returns true if the components using this action are currently disabled, else returns false.  
   */
  isDisabled: function isDisabled() {
    return this.initialConfig.disabled;
  },

  /**
   * Sets the hidden state of all components using this action.  Shortcut method
   * for <code>{@link #hide}</code> and <code>{@link #show}</code>.
   * @param {Boolean} hidden True to hide the component, false to show it
   */
  setHidden: function setHidden(v) {
    this.initialConfig.hidden = v;
    this.callEach('setVisible', [!v]);
  },

  /**
   * Shows all components using this action.
   */
  show: function show() {
    this.setHidden(false);
  },

  /**
   * Hides all components using this action.
   */
  hide: function hide() {
    this.setHidden(true);
  },

  /**
   * Returns true if the components using this action are currently hidden, else returns false.  
   */
  isHidden: function isHidden() {
    return this.initialConfig.hidden;
  },

  /**
   * Sets the function that will be called by each Component using this action when its primary event is triggered.
   * @param {Function} fn The function that will be invoked by the action's components.  The function
   * will be called with no arguments.
   * @param {Object} scope The scope (<code>this</code> reference) in which the function is executed. Defaults to the Component firing the event.
   */
  setHandler: function setHandler(fn, scope) {
    this.initialConfig.handler = fn;
    this.initialConfig.scope = scope;
    this.callEach('setHandler', [fn, scope]);
  },

  /**
   * Executes the specified function once for each Component currently tied to this action.  The function passed
   * in should accept a single argument that will be an object that supports the basic Action config/method interface.
   * @param {Function} fn The function to execute for each component
   * @param {Object} scope The scope (<code>this</code> reference) in which the function is executed.  Defaults to the Component.
   */
  each: function each(fn, scope) {
    Ext.each(this.items, fn, scope);
  },
  // private
  callEach: function callEach(fnName, args) {
    var cs = this.items;

    for (var i = 0, len = cs.length; i < len; i++) {
      cs[i][fnName].apply(cs[i], args);
    }
  },
  // private
  addComponent: function addComponent(comp) {
    this.items.push(comp);
    comp.on('destroy', this.removeComponent, this);
  },
  // private
  removeComponent: function removeComponent(comp) {
    this.items.remove(comp);
  },

  /**
   * Executes this action manually using the handler function specified in the original config object
   * or the handler function set with <code>{@link #setHandler}</code>.  Any arguments passed to this
   * function will be passed on to the handler function.
   * @param {Mixed} arg1 (optional) Variable number of arguments passed to the handler function
   * @param {Mixed} arg2 (optional)
   * @param {Mixed} etc... (optional)
   */
  execute: function execute() {
    this.initialConfig.handler.apply(this.initialConfig.scope || window, arguments);
  }
});

/***/ }),
/* 753 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Layer
 * @extends Ext.Element
 * An extended {@link Ext.Element} object that supports a shadow and shim, constrain to viewport and
 * automatic maintaining of shadow/shim positions.
 * @cfg {Boolean} shim False to disable the iframe shim in browsers which need one (defaults to true)
 * @cfg {String/Boolean} shadow True to automatically create an {@link Ext.Shadow}, or a string indicating the
 * shadow's display {@link Ext.Shadow#mode}. False to disable the shadow. (defaults to false)
 * @cfg {Object} dh DomHelper object config to create element with (defaults to {tag: 'div', cls: 'x-layer'}).
 * @cfg {Boolean} constrain False to disable constrain to viewport (defaults to true)
 * @cfg {String} cls CSS class to add to the element
 * @cfg {Number} zindex Starting z-index (defaults to 11000)
 * @cfg {Number} shadowOffset Number of pixels to offset the shadow (defaults to 4)
 * @cfg {Boolean} useDisplay
 * Defaults to use css offsets to hide the Layer. Specify <tt>true</tt>
 * to use css style <tt>'display:none;'</tt> to hide the Layer.
 * @constructor
 * @param {Object} config An object with config options.
 * @param {String/HTMLElement} existingEl (optional) Uses an existing DOM element. If the element is not found it creates it.
 */
(function () {
  Ext.Layer = function (config, existingEl) {
    config = config || {};
    var dh = Ext.DomHelper;
    var cp = config.parentEl,
        pel = cp ? Ext.getDom(cp) : document.body;

    if (existingEl) {
      this.dom = Ext.getDom(existingEl);
    }

    if (!this.dom) {
      var o = config.dh || {
        tag: 'div',
        cls: 'x-layer'
      };
      this.dom = dh.append(pel, o);
    }

    if (config.cls) {
      this.addClass(config.cls);
    }

    this.constrain = config.constrain !== false;
    this.setVisibilityMode(Ext.Element.VISIBILITY);

    if (config.id) {
      this.id = this.dom.id = config.id;
    } else {
      this.id = Ext.id(this.dom);
    }

    this.zindex = config.zindex || this.getZIndex();
    this.position('absolute', this.zindex);

    if (config.shadow) {
      this.shadowOffset = config.shadowOffset || 4;
      this.shadow = new Ext.Shadow({
        offset: this.shadowOffset,
        mode: config.shadow
      });
    } else {
      this.shadowOffset = 0;
    }

    this.useShim = config.shim !== false && Ext.useShims;
    this.useDisplay = config.useDisplay;
    this.hide();
  };

  var supr = Ext.Element.prototype; // shims are shared among layer to keep from having 100 iframes

  var shims = [];
  Ext.extend(Ext.Layer, Ext.Element, {
    getZIndex: function getZIndex() {
      return this.zindex || parseInt((this.getShim() || this).getStyle('z-index'), 10) || 11000;
    },
    getShim: function getShim() {
      if (!this.useShim) {
        return null;
      }

      if (this.shim) {
        return this.shim;
      }

      var shim = shims.shift();

      if (!shim) {
        shim = this.createShim();
        shim.enableDisplayMode('block');
        shim.dom.style.display = 'none';
        shim.dom.style.visibility = 'visible';
      }

      var pn = this.dom.parentNode;

      if (shim.dom.parentNode != pn) {
        pn.insertBefore(shim.dom, this.dom);
      }

      shim.setStyle('z-index', this.getZIndex() - 2);
      this.shim = shim;
      return shim;
    },
    hideShim: function hideShim() {
      if (this.shim) {
        this.shim.setDisplayed(false);
        shims.push(this.shim);
        delete this.shim;
      }
    },
    disableShadow: function disableShadow() {
      if (this.shadow) {
        this.shadowDisabled = true;
        this.shadow.hide();
        this.lastShadowOffset = this.shadowOffset;
        this.shadowOffset = 0;
      }
    },
    enableShadow: function enableShadow(show) {
      if (this.shadow) {
        this.shadowDisabled = false;
        this.shadowOffset = this.lastShadowOffset;
        delete this.lastShadowOffset;

        if (show) {
          this.sync(true);
        }
      }
    },
    // private
    // this code can execute repeatedly in milliseconds (i.e. during a drag) so
    // code size was sacrificed for effeciency (e.g. no getBox/setBox, no XY calls)
    sync: function sync(doShow) {
      var sw = this.shadow;

      if (!this.updating && this.isVisible() && (sw || this.useShim)) {
        var sh = this.getShim();
        var w = this.getWidth(),
            h = this.getHeight();
        var l = this.getLeft(true),
            t = this.getTop(true);

        if (sw && !this.shadowDisabled) {
          if (doShow && !sw.isVisible()) {
            sw.show(this);
          } else {
            sw.realign(l, t, w, h);
          }

          if (sh) {
            if (doShow) {
              sh.show();
            } // fit the shim behind the shadow, so it is shimmed too


            var a = sw.adjusts,
                s = sh.dom.style;
            s.left = Math.min(l, l + a.l) + 'px';
            s.top = Math.min(t, t + a.t) + 'px';
            s.width = w + a.w + 'px';
            s.height = h + a.h + 'px';
          }
        } else if (sh) {
          if (doShow) {
            sh.show();
          }

          sh.setSize(w, h);
          sh.setLeftTop(l, t);
        }
      }
    },
    // private
    destroy: function destroy() {
      this.hideShim();

      if (this.shadow) {
        this.shadow.hide();
      }

      this.removeAllListeners();
      Ext.removeNode(this.dom);
      delete this.dom;
    },
    remove: function remove() {
      this.destroy();
    },
    // private
    beginUpdate: function beginUpdate() {
      this.updating = true;
    },
    // private
    endUpdate: function endUpdate() {
      this.updating = false;
      this.sync(true);
    },
    // private
    hideUnders: function hideUnders(negOffset) {
      if (this.shadow) {
        this.shadow.hide();
      }

      this.hideShim();
    },
    // private
    constrainXY: function constrainXY() {
      if (this.constrain) {
        var vw = Ext.lib.Dom.getViewWidth(),
            vh = Ext.lib.Dom.getViewHeight();
        var s = Ext.getDoc().getScroll();
        var xy = this.getXY();
        var x = xy[0],
            y = xy[1];
        var so = this.shadowOffset;
        var w = this.dom.offsetWidth + so,
            h = this.dom.offsetHeight + so; // only move it if it needs it

        var moved = false; // first validate right/bottom

        if (x + w > vw + s.left) {
          x = vw - w - so;
          moved = true;
        }

        if (y + h > vh + s.top) {
          y = vh - h - so;
          moved = true;
        } // then make sure top/left isn't negative


        if (x < s.left) {
          x = s.left;
          moved = true;
        }

        if (y < s.top) {
          y = s.top;
          moved = true;
        }

        if (moved) {
          if (this.avoidY) {
            var ay = this.avoidY;

            if (y <= ay && y + h >= ay) {
              y = ay - h - 5;
            }
          }

          xy = [x, y];
          this.storeXY(xy);
          supr.setXY.call(this, xy);
          this.sync();
        }
      }

      return this;
    },
    isVisible: function isVisible() {
      return this.visible;
    },
    // private
    showAction: function showAction() {
      this.visible = true; // track visibility to prevent getStyle calls

      if (this.useDisplay === true) {
        this.setDisplayed('');
      } else if (this.lastXY) {
        supr.setXY.call(this, this.lastXY);
      } else if (this.lastLT) {
        supr.setLeftTop.call(this, this.lastLT[0], this.lastLT[1]);
      }
    },
    // private
    hideAction: function hideAction() {
      this.visible = false;

      if (this.useDisplay === true) {
        this.setDisplayed(false);
      } else {
        this.setLeftTop(-10000, -10000);
      }
    },
    // overridden Element method
    setVisible: function setVisible(v, a, d, c, e) {
      if (v) {
        this.showAction();
      }

      if (a && v) {
        var cb = function () {
          this.sync(true);

          if (c) {
            c();
          }
        }.createDelegate(this);

        supr.setVisible.call(this, true, true, d, cb, e);
      } else {
        if (!v) {
          this.hideUnders(true);
        }

        var cb = c;

        if (a) {
          cb = function () {
            this.hideAction();

            if (c) {
              c();
            }
          }.createDelegate(this);
        }

        supr.setVisible.call(this, v, a, d, cb, e);

        if (v) {
          this.sync(true);
        } else if (!a) {
          this.hideAction();
        }
      }

      return this;
    },
    storeXY: function storeXY(xy) {
      delete this.lastLT;
      this.lastXY = xy;
    },
    storeLeftTop: function storeLeftTop(left, top) {
      delete this.lastXY;
      this.lastLT = [left, top];
    },
    // private
    beforeFx: function beforeFx() {
      this.beforeAction();
      return Ext.Layer.superclass.beforeFx.apply(this, arguments);
    },
    // private
    afterFx: function afterFx() {
      Ext.Layer.superclass.afterFx.apply(this, arguments);
      this.sync(this.isVisible());
    },
    // private
    beforeAction: function beforeAction() {
      if (!this.updating && this.shadow) {
        this.shadow.hide();
      }
    },
    // overridden Element method
    setLeft: function setLeft(left) {
      this.storeLeftTop(left, this.getTop(true));
      supr.setLeft.apply(this, arguments);
      this.sync();
      return this;
    },
    setTop: function setTop(top) {
      this.storeLeftTop(this.getLeft(true), top);
      supr.setTop.apply(this, arguments);
      this.sync();
      return this;
    },
    setLeftTop: function setLeftTop(left, top) {
      this.storeLeftTop(left, top);
      supr.setLeftTop.apply(this, arguments);
      this.sync();
      return this;
    },
    setXY: function setXY(xy, a, d, c, e) {
      this.fixDisplay();
      this.beforeAction();
      this.storeXY(xy);
      var cb = this.createCB(c);
      supr.setXY.call(this, xy, a, d, cb, e);

      if (!a) {
        cb();
      }

      return this;
    },
    // private
    createCB: function createCB(c) {
      var el = this;
      return function () {
        el.constrainXY();
        el.sync(true);

        if (c) {
          c();
        }
      };
    },
    // overridden Element method
    setX: function setX(x, a, d, c, e) {
      this.setXY([x, this.getY()], a, d, c, e);
      return this;
    },
    // overridden Element method
    setY: function setY(y, a, d, c, e) {
      this.setXY([this.getX(), y], a, d, c, e);
      return this;
    },
    // overridden Element method
    setSize: function setSize(w, h, a, d, c, e) {
      this.beforeAction();
      var cb = this.createCB(c);
      supr.setSize.call(this, w, h, a, d, cb, e);

      if (!a) {
        cb();
      }

      return this;
    },
    // overridden Element method
    setWidth: function setWidth(w, a, d, c, e) {
      this.beforeAction();
      var cb = this.createCB(c);
      supr.setWidth.call(this, w, a, d, cb, e);

      if (!a) {
        cb();
      }

      return this;
    },
    // overridden Element method
    setHeight: function setHeight(h, a, d, c, e) {
      this.beforeAction();
      var cb = this.createCB(c);
      supr.setHeight.call(this, h, a, d, cb, e);

      if (!a) {
        cb();
      }

      return this;
    },
    // overridden Element method
    setBounds: function setBounds(x, y, w, h, a, d, c, e) {
      this.beforeAction();
      var cb = this.createCB(c);

      if (!a) {
        this.storeXY([x, y]);
        supr.setXY.call(this, [x, y]);
        supr.setSize.call(this, w, h, a, d, cb, e);
        cb();
      } else {
        supr.setBounds.call(this, x, y, w, h, a, d, cb, e);
      }

      return this;
    },

    /**
     * Sets the z-index of this layer and adjusts any shadow and shim z-indexes. The layer z-index is automatically
     * incremented by two more than the value passed in so that it always shows above any shadow or shim (the shadow
     * element, if any, will be assigned z-index + 1, and the shim element, if any, will be assigned the unmodified z-index).
     * @param {Number} zindex The new z-index to set
     * @return {this} The Layer
     */
    setZIndex: function setZIndex(zindex) {
      this.zindex = zindex;
      this.setStyle('z-index', zindex + 2);

      if (this.shadow) {
        this.shadow.setZIndex(zindex + 1);
      }

      if (this.shim) {
        this.shim.setStyle('z-index', zindex);
      }

      return this;
    }
  });
})();

/***/ }),
/* 754 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Shadow
 * Simple class that can provide a shadow effect for any element.  Note that the element MUST be absolutely positioned,
 * and the shadow does not provide any shimming.  This should be used only in simple cases -- for more advanced
 * functionality that can also provide the same shadow effect, see the {@link Ext.Layer} class.
 * @constructor
 * Create a new Shadow
 * @param {Object} config The config object
 */
Ext.Shadow = function (config) {
  Ext.apply(this, config);

  if (typeof this.mode != "string") {
    this.mode = this.defaultMode;
  }

  var o = this.offset,
      a = {
    h: 0
  };
  var rad = Math.floor(this.offset / 2);

  switch (this.mode.toLowerCase()) {
    // all this hideous nonsense calculates the various offsets for shadows
    case "drop":
      a.w = 0;
      a.l = a.t = o;
      a.t -= 1;

      if (Ext.isIE) {
        a.l -= this.offset + rad;
        a.t -= this.offset + rad;
        a.w -= rad;
        a.h -= rad;
        a.t += 1;
      }

      break;

    case "sides":
      a.w = o * 2;
      a.l = -o;
      a.t = o - 1;

      if (Ext.isIE) {
        a.l -= this.offset - rad;
        a.t -= this.offset + rad;
        a.l += 1;
        a.w -= (this.offset - rad) * 2;
        a.w -= rad + 1;
        a.h -= 1;
      }

      break;

    case "frame":
      a.w = a.h = o * 2;
      a.l = a.t = -o;
      a.t += 1;
      a.h -= 2;

      if (Ext.isIE) {
        a.l -= this.offset - rad;
        a.t -= this.offset - rad;
        a.l += 1;
        a.w -= this.offset + rad + 1;
        a.h -= this.offset + rad;
        a.h += 1;
      }

      break;
  }

  ;
  this.adjusts = a;
};

Ext.Shadow.prototype = {
  /**
   * @cfg {String} mode
   * The shadow display mode.  Supports the following options:<div class="mdetail-params"><ul>
   * <li><b><tt>sides</tt></b> : Shadow displays on both sides and bottom only</li>
   * <li><b><tt>frame</tt></b> : Shadow displays equally on all four sides</li>
   * <li><b><tt>drop</tt></b> : Traditional bottom-right drop shadow</li>
   * </ul></div>
   */

  /**
   * @cfg {String} offset
   * The number of pixels to offset the shadow from the element (defaults to <tt>4</tt>)
   */
  offset: 4,
  // private
  defaultMode: "drop",

  /**
   * Displays the shadow under the target element
   * @param {Mixed} targetEl The id or element under which the shadow should display
   */
  show: function show(target) {
    target = Ext.get(target);

    if (!this.el) {
      this.el = Ext.Shadow.Pool.pull();

      if (this.el.dom.nextSibling != target.dom) {
        this.el.insertBefore(target);
      }
    }

    this.el.setStyle("z-index", this.zIndex || parseInt(target.getStyle("z-index"), 10) - 1);

    if (Ext.isIE) {
      this.el.dom.style.filter = "progid:DXImageTransform.Microsoft.alpha(opacity=50) progid:DXImageTransform.Microsoft.Blur(pixelradius=" + this.offset + ")";
    }

    this.realign(target.getLeft(true), target.getTop(true), target.getWidth(), target.getHeight());
    this.el.dom.style.display = "block";
  },

  /**
   * Returns true if the shadow is visible, else false
   */
  isVisible: function isVisible() {
    return this.el ? true : false;
  },

  /**
   * Direct alignment when values are already available. Show must be called at least once before
   * calling this method to ensure it is initialized.
   * @param {Number} left The target element left position
   * @param {Number} top The target element top position
   * @param {Number} width The target element width
   * @param {Number} height The target element height
   */
  realign: function realign(l, t, w, h) {
    if (!this.el) {
      return;
    }

    var a = this.adjusts,
        d = this.el.dom,
        s = d.style;
    var iea = 0;
    s.left = l + a.l + "px";
    s.top = t + a.t + "px";
    var sw = w + a.w,
        sh = h + a.h,
        sws = sw + "px",
        shs = sh + "px";

    if (s.width != sws || s.height != shs) {
      s.width = sws;
      s.height = shs;

      if (!Ext.isIE) {
        var cn = d.childNodes;
        var sww = Math.max(0, sw - 12) + "px";
        cn[0].childNodes[1].style.width = sww;
        cn[1].childNodes[1].style.width = sww;
        cn[2].childNodes[1].style.width = sww;
        cn[1].style.height = Math.max(0, sh - 12) + "px";
      }
    }
  },

  /**
   * Hides this shadow
   */
  hide: function hide() {
    if (this.el) {
      this.el.dom.style.display = "none";
      Ext.Shadow.Pool.push(this.el);
      delete this.el;
    }
  },

  /**
   * Adjust the z-index of this shadow
   * @param {Number} zindex The new z-index
   */
  setZIndex: function setZIndex(z) {
    this.zIndex = z;

    if (this.el) {
      this.el.setStyle("z-index", z);
    }
  }
}; // Private utility class that manages the internal Shadow cache

Ext.Shadow.Pool = function () {
  var p = [];
  var markup = Ext.isIE ? '<div class="x-ie-shadow"></div>' : '<div class="x-shadow"><div class="xst"><div class="xstl"></div><div class="xstc"></div><div class="xstr"></div></div><div class="xsc"><div class="xsml"></div><div class="xsmc"></div><div class="xsmr"></div></div><div class="xsb"><div class="xsbl"></div><div class="xsbc"></div><div class="xsbr"></div></div></div>';
  return {
    pull: function pull() {
      var sh = p.shift();

      if (!sh) {
        sh = Ext.get(Ext.DomHelper.insertHtml("beforeBegin", document.body.firstChild, markup));
        sh.autoBoxAdjust = false;
      }

      return sh;
    },
    push: function push(sh) {
      p.push(sh);
    }
  };
}();

/***/ }),
/* 755 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.BoxComponent
 * @extends Ext.Component
 * <p>Base class for any {@link Ext.Component Component} that is to be sized as a box, using width and height.</p>
 * <p>BoxComponent provides automatic box model adjustments for sizing and positioning and will work correctly
 * within the Component rendering model.</p>
 * <p>A BoxComponent may be created as a custom Component which encapsulates any HTML element, either a pre-existing
 * element, or one that is created to your specifications at render time. Usually, to participate in layouts,
 * a Component will need to be a <b>Box</b>Component in order to have its width and height managed.</p>
 * <p>To use a pre-existing element as a BoxComponent, configure it so that you preset the <b>el</b> property to the
 * element to reference:<pre><code>
var pageHeader = new Ext.BoxComponent({
    el: 'my-header-div'
});</code></pre>
 * This may then be {@link Ext.Container#add added} to a {@link Ext.Container Container} as a child item.</p>
 * <p>To create a BoxComponent based around a HTML element to be created at render time, use the
 * {@link Ext.Component#autoEl autoEl} config option which takes the form of a
 * {@link Ext.DomHelper DomHelper} specification:<pre><code>
var myImage = new Ext.BoxComponent({
    autoEl: {
        tag: 'img',
        src: '/images/my-image.jpg'
    }
});</code></pre></p>
 * @constructor
 * @param {Ext.Element/String/Object} config The configuration options.
 * @xtype box
 */
Ext.BoxComponent = Ext.extend(Ext.Component, {
  // Configs below are used for all Components when rendered by BoxLayout.

  /**
   * @cfg {Number} flex
   * <p><b>Note</b>: this config is only used when this Component is rendered
   * by a Container which has been configured to use a <b>{@link Ext.layout.BoxLayout BoxLayout}.</b>
   * Each child Component with a <code>flex</code> property will be flexed either vertically (by a VBoxLayout)
   * or horizontally (by an HBoxLayout) according to the item's <b>relative</b> <code>flex</code> value
   * compared to the sum of all Components with <code>flex</flex> value specified. Any child items that have
   * either a <code>flex = 0</code> or <code>flex = undefined</code> will not be 'flexed' (the initial size will not be changed).
   */
  // Configs below are used for all Components when rendered by AnchorLayout.

  /**
   * @cfg {String} anchor <p><b>Note</b>: this config is only used when this Component is rendered
   * by a Container which has been configured to use an <b>{@link Ext.layout.AnchorLayout AnchorLayout} (or subclass thereof).</b>
   * based layout manager, for example:<div class="mdetail-params"><ul>
   * <li>{@link Ext.form.FormPanel}</li>
   * <li>specifying <code>layout: 'anchor' // or 'form', or 'absolute'</code></li>
   * </ul></div></p>
   * <p>See {@link Ext.layout.AnchorLayout}.{@link Ext.layout.AnchorLayout#anchor anchor} also.</p>
   */
  // tabTip config is used when a BoxComponent is a child of a TabPanel

  /**
   * @cfg {String} tabTip
   * <p><b>Note</b>: this config is only used when this BoxComponent is a child item of a TabPanel.</p>
   * A string to be used as innerHTML (html tags are accepted) to show in a tooltip when mousing over
   * the associated tab selector element. {@link Ext.QuickTips}.init()
   * must be called in order for the tips to render.
   */
  // Configs below are used for all Components when rendered by BorderLayout.

  /**
   * @cfg {String} region <p><b>Note</b>: this config is only used when this BoxComponent is rendered
   * by a Container which has been configured to use the <b>{@link Ext.layout.BorderLayout BorderLayout}</b>
   * layout manager (e.g. specifying <tt>layout:'border'</tt>).</p><br>
   * <p>See {@link Ext.layout.BorderLayout} also.</p>
   */
  // margins config is used when a BoxComponent is rendered by BorderLayout or BoxLayout.

  /**
   * @cfg {Object} margins <p><b>Note</b>: this config is only used when this BoxComponent is rendered
   * by a Container which has been configured to use the <b>{@link Ext.layout.BorderLayout BorderLayout}</b>
   * or one of the two <b>{@link Ext.layout.BoxLayout BoxLayout} subclasses.</b></p>
   * <p>An object containing margins to apply to this BoxComponent in the
   * format:</p><pre><code>
  {
  top: (top margin),
  right: (right margin),
  bottom: (bottom margin),
  left: (left margin)
  }</code></pre>
   * <p>May also be a string containing space-separated, numeric margin values. The order of the
   * sides associated with each value matches the way CSS processes margin values:</p>
   * <p><div class="mdetail-params"><ul>
   * <li>If there is only one value, it applies to all sides.</li>
   * <li>If there are two values, the top and bottom borders are set to the first value and the
   * right and left are set to the second.</li>
   * <li>If there are three values, the top is set to the first value, the left and right are set
   * to the second, and the bottom is set to the third.</li>
   * <li>If there are four values, they apply to the top, right, bottom, and left, respectively.</li>
   * </ul></div></p>
   * <p>Defaults to:</p><pre><code>
   * {top:0, right:0, bottom:0, left:0}
   * </code></pre>
   */

  /**
   * @cfg {Number} x
   * The local x (left) coordinate for this component if contained within a positioning container.
   */

  /**
   * @cfg {Number} y
   * The local y (top) coordinate for this component if contained within a positioning container.
   */

  /**
   * @cfg {Number} pageX
   * The page level x coordinate for this component if contained within a positioning container.
   */

  /**
   * @cfg {Number} pageY
   * The page level y coordinate for this component if contained within a positioning container.
   */

  /**
   * @cfg {Number} height
   * The height of this component in pixels (defaults to auto).
   * <b>Note</b> to express this dimension as a percentage or offset see {@link Ext.Component#anchor}.
   */

  /**
   * @cfg {Number} width
   * The width of this component in pixels (defaults to auto).
   * <b>Note</b> to express this dimension as a percentage or offset see {@link Ext.Component#anchor}.
   */

  /**
   * @cfg {Number} boxMinHeight
   * <p>The minimum value in pixels which this BoxComponent will set its height to.</p>
   * <p><b>Warning:</b> This will override any size management applied by layout managers.</p>
   */

  /**
   * @cfg {Number} boxMinWidth
   * <p>The minimum value in pixels which this BoxComponent will set its width to.</p>
   * <p><b>Warning:</b> This will override any size management applied by layout managers.</p>
   */

  /**
   * @cfg {Number} boxMaxHeight
   * <p>The maximum value in pixels which this BoxComponent will set its height to.</p>
   * <p><b>Warning:</b> This will override any size management applied by layout managers.</p>
   */

  /**
   * @cfg {Number} boxMaxWidth
   * <p>The maximum value in pixels which this BoxComponent will set its width to.</p>
   * <p><b>Warning:</b> This will override any size management applied by layout managers.</p>
   */

  /**
   * @cfg {Boolean} autoHeight
   * <p>True to use height:'auto', false to use fixed height (or allow it to be managed by its parent
   * Container's {@link Ext.Container#layout layout manager}. Defaults to false.</p>
   * <p><b>Note</b>: Although many components inherit this config option, not all will
   * function as expected with a height of 'auto'. Setting autoHeight:true means that the
   * browser will manage height based on the element's contents, and that Ext will not manage it at all.</p>
   * <p>If the <i>browser</i> is managing the height, be aware that resizes performed by the browser in response
   * to changes within the structure of the Component cannot be detected. Therefore changes to the height might
   * result in elements needing to be synchronized with the new height. Example:</p><pre><code>
  var w = new Ext.Window({
  title: 'Window',
  width: 600,
  autoHeight: true,
  items: {
      title: 'Collapse Me',
      height: 400,
      collapsible: true,
      border: false,
      listeners: {
          beforecollapse: function() {
              w.el.shadow.hide();
          },
          beforeexpand: function() {
              w.el.shadow.hide();
          },
          collapse: function() {
              w.syncShadow();
          },
          expand: function() {
              w.syncShadow();
          }
      }
  }
  }).show();
  </code></pre>
   */

  /**
   * @cfg {Boolean} autoWidth
   * <p>True to use width:'auto', false to use fixed width (or allow it to be managed by its parent
   * Container's {@link Ext.Container#layout layout manager}. Defaults to false.</p>
   * <p><b>Note</b>: Although many components  inherit this config option, not all will
   * function as expected with a width of 'auto'. Setting autoWidth:true means that the
   * browser will manage width based on the element's contents, and that Ext will not manage it at all.</p>
   * <p>If the <i>browser</i> is managing the width, be aware that resizes performed by the browser in response
   * to changes within the structure of the Component cannot be detected. Therefore changes to the width might
   * result in elements needing to be synchronized with the new width. For example, where the target element is:</p><pre><code>
  &lt;div id='grid-container' style='margin-left:25%;width:50%'>&lt;/div>
  </code></pre>
   * A Panel rendered into that target element must listen for browser window resize in order to relay its
    * child items when the browser changes its width:<pre><code>
  var myPanel = new Ext.Panel({
  renderTo: 'grid-container',
  monitorResize: true, // relay on browser resize
  title: 'Panel',
  height: 400,
  autoWidth: true,
  layout: 'hbox',
  layoutConfig: {
      align: 'stretch'
  },
  defaults: {
      flex: 1
  },
  items: [{
      title: 'Box 1',
  }, {
      title: 'Box 2'
  }, {
      title: 'Box 3'
  }],
  });
  </code></pre>
   */

  /**
   * @cfg {Boolean} autoScroll
   * <code>true</code> to use overflow:'auto' on the components layout element and show scroll bars automatically when
   * necessary, <code>false</code> to clip any overflowing content (defaults to <code>false</code>).
   */

  /* // private internal config
   * {Boolean} deferHeight
   * True to defer height calculations to an external component, false to allow this component to set its own
   * height (defaults to false).
   */
  // private
  initComponent: function initComponent() {
    Ext.BoxComponent.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event resize
     * Fires after the component is resized.
     * @param {Ext.Component} this
     * @param {Number} adjWidth The box-adjusted width that was set
     * @param {Number} adjHeight The box-adjusted height that was set
     * @param {Number} rawWidth The width that was originally specified
     * @param {Number} rawHeight The height that was originally specified
     */
    'resize',
    /**
     * @event move
     * Fires after the component is moved.
     * @param {Ext.Component} this
     * @param {Number} x The new x position
     * @param {Number} y The new y position
     */
    'move');
  },
  // private, set in afterRender to signify that the component has been rendered
  boxReady: false,
  // private, used to defer height settings to subclasses
  deferHeight: false,

  /**
   * Sets the width and height of this BoxComponent. This method fires the {@link #resize} event. This method can accept
   * either width and height as separate arguments, or you can pass a size object like <code>{width:10, height:20}</code>.
   * @param {Mixed} width The new width to set. This may be one of:<div class="mdetail-params"><ul>
   * <li>A Number specifying the new width in the {@link #getEl Element}'s {@link Ext.Element#defaultUnit}s (by default, pixels).</li>
   * <li>A String used to set the CSS width style.</li>
   * <li>A size object in the format <code>{width: widthValue, height: heightValue}</code>.</li>
   * <li><code>undefined</code> to leave the width unchanged.</li>
   * </ul></div>
   * @param {Mixed} height The new height to set (not required if a size object is passed as the first arg).
   * This may be one of:<div class="mdetail-params"><ul>
   * <li>A Number specifying the new height in the {@link #getEl Element}'s {@link Ext.Element#defaultUnit}s (by default, pixels).</li>
   * <li>A String used to set the CSS height style. Animation may <b>not</b> be used.</li>
   * <li><code>undefined</code> to leave the height unchanged.</li>
   * </ul></div>
   * @return {Ext.BoxComponent} this
   */
  setSize: function setSize(w, h) {
    // support for standard size objects
    if (typeof w == 'object') {
      h = w.height, w = w.width;
    }

    if (Ext.isDefined(w) && Ext.isDefined(this.boxMinWidth) && w < this.boxMinWidth) {
      w = this.boxMinWidth;
    }

    if (Ext.isDefined(h) && Ext.isDefined(this.boxMinHeight) && h < this.boxMinHeight) {
      h = this.boxMinHeight;
    }

    if (Ext.isDefined(w) && Ext.isDefined(this.boxMaxWidth) && w > this.boxMaxWidth) {
      w = this.boxMaxWidth;
    }

    if (Ext.isDefined(h) && Ext.isDefined(this.boxMaxHeight) && h > this.boxMaxHeight) {
      h = this.boxMaxHeight;
    } // not rendered


    if (!this.boxReady) {
      this.width = w, this.height = h;
      return this;
    } // prevent recalcs when not needed


    if (this.cacheSizes !== false && this.lastSize && this.lastSize.width == w && this.lastSize.height == h) {
      return this;
    }

    this.lastSize = {
      width: w,
      height: h
    };
    var adj = this.adjustSize(w, h),
        aw = adj.width,
        ah = adj.height,
        rz;

    if (aw !== undefined || ah !== undefined) {
      // this code is nasty but performs better with floaters
      rz = this.getResizeEl();

      if (!this.deferHeight && aw !== undefined && ah !== undefined) {
        rz.setSize(aw, ah);
      } else if (!this.deferHeight && ah !== undefined) {
        rz.setHeight(ah);
      } else if (aw !== undefined) {
        rz.setWidth(aw);
      }

      this.onResize(aw, ah, w, h);
      this.fireEvent('resize', this, aw, ah, w, h);
    }

    return this;
  },

  /**
   * Sets the width of the component.  This method fires the {@link #resize} event.
   * @param {Number} width The new width to setThis may be one of:<div class="mdetail-params"><ul>
   * <li>A Number specifying the new width in the {@link #getEl Element}'s {@link Ext.Element#defaultUnit}s (by default, pixels).</li>
   * <li>A String used to set the CSS width style.</li>
   * </ul></div>
   * @return {Ext.BoxComponent} this
   */
  setWidth: function setWidth(width) {
    return this.setSize(width);
  },

  /**
   * Sets the height of the component.  This method fires the {@link #resize} event.
   * @param {Number} height The new height to set. This may be one of:<div class="mdetail-params"><ul>
   * <li>A Number specifying the new height in the {@link #getEl Element}'s {@link Ext.Element#defaultUnit}s (by default, pixels).</li>
   * <li>A String used to set the CSS height style.</li>
   * <li><i>undefined</i> to leave the height unchanged.</li>
   * </ul></div>
   * @return {Ext.BoxComponent} this
   */
  setHeight: function setHeight(height) {
    return this.setSize(undefined, height);
  },

  /**
   * Gets the current size of the component's underlying element.
   * @return {Object} An object containing the element's size {width: (element width), height: (element height)}
   */
  getSize: function getSize() {
    return this.getResizeEl().getSize();
  },

  /**
   * Gets the current width of the component's underlying element.
   * @return {Number}
   */
  getWidth: function getWidth() {
    return this.getResizeEl().getWidth();
  },

  /**
   * Gets the current height of the component's underlying element.
   * @return {Number}
   */
  getHeight: function getHeight() {
    return this.getResizeEl().getHeight();
  },

  /**
   * Gets the current size of the component's underlying element, including space taken by its margins.
   * @return {Object} An object containing the element's size {width: (element width + left/right margins), height: (element height + top/bottom margins)}
   */
  getOuterSize: function getOuterSize() {
    var el = this.getResizeEl();
    return {
      width: el.getWidth() + el.getMargins('lr'),
      height: el.getHeight() + el.getMargins('tb')
    };
  },

  /**
   * Gets the current XY position of the component's underlying element.
   * @param {Boolean} local (optional) If true the element's left and top are returned instead of page XY (defaults to false)
   * @return {Array} The XY position of the element (e.g., [100, 200])
   */
  getPosition: function getPosition(local) {
    var el = this.getPositionEl();

    if (local === true) {
      return [el.getLeft(true), el.getTop(true)];
    }

    return this.xy || el.getXY();
  },

  /**
   * Gets the current box measurements of the component's underlying element.
   * @param {Boolean} local (optional) If true the element's left and top are returned instead of page XY (defaults to false)
   * @return {Object} box An object in the format {x, y, width, height}
   */
  getBox: function getBox(local) {
    var pos = this.getPosition(local);
    var s = this.getSize();
    s.x = pos[0];
    s.y = pos[1];
    return s;
  },

  /**
   * Sets the current box measurements of the component's underlying element.
   * @param {Object} box An object in the format {x, y, width, height}
   * @return {Ext.BoxComponent} this
   */
  updateBox: function updateBox(box) {
    this.setSize(box.width, box.height);
    this.setPagePosition(box.x, box.y);
    return this;
  },

  /**
   * <p>Returns the outermost Element of this Component which defines the Components overall size.</p>
   * <p><i>Usually</i> this will return the same Element as <code>{@link #getEl}</code>,
   * but in some cases, a Component may have some more wrapping Elements around its main
   * active Element.</p>
   * <p>An example is a ComboBox. It is encased in a <i>wrapping</i> Element which
   * contains both the <code>&lt;input></code> Element (which is what would be returned
   * by its <code>{@link #getEl}</code> method, <i>and</i> the trigger button Element.
   * This Element is returned as the <code>resizeEl</code>.
   * @return {Ext.Element} The Element which is to be resized by size managing layouts.
   */
  getResizeEl: function getResizeEl() {
    return this.resizeEl || this.el;
  },

  /**
   * Sets the overflow on the content element of the component.
   * @param {Boolean} scroll True to allow the Component to auto scroll.
   * @return {Ext.BoxComponent} this
   */
  setAutoScroll: function setAutoScroll(scroll) {
    if (this.rendered) {
      this.getContentTarget().setOverflow(scroll ? 'auto' : '');
    }

    this.autoScroll = scroll;
    return this;
  },

  /**
   * Sets the left and top of the component.  To set the page XY position instead, use {@link #setPagePosition}.
   * This method fires the {@link #move} event.
   * @param {Number} left The new left
   * @param {Number} top The new top
   * @return {Ext.BoxComponent} this
   */
  setPosition: function setPosition(x, y) {
    if (x && typeof x[1] == 'number') {
      y = x[1];
      x = x[0];
    }

    this.x = x;
    this.y = y;

    if (!this.boxReady) {
      return this;
    }

    var adj = this.adjustPosition(x, y);
    var ax = adj.x,
        ay = adj.y;
    var el = this.getPositionEl();

    if (ax !== undefined || ay !== undefined) {
      if (ax !== undefined && ay !== undefined) {
        el.setLeftTop(ax, ay);
      } else if (ax !== undefined) {
        el.setLeft(ax);
      } else if (ay !== undefined) {
        el.setTop(ay);
      }

      this.onPosition(ax, ay);
      this.fireEvent('move', this, ax, ay);
    }

    return this;
  },

  /**
   * Sets the page XY position of the component.  To set the left and top instead, use {@link #setPosition}.
   * This method fires the {@link #move} event.
   * @param {Number} x The new x position
   * @param {Number} y The new y position
   * @return {Ext.BoxComponent} this
   */
  setPagePosition: function setPagePosition(x, y) {
    if (x && typeof x[1] == 'number') {
      y = x[1];
      x = x[0];
    }

    this.pageX = x;
    this.pageY = y;

    if (!this.boxReady) {
      return;
    }

    if (x === undefined || y === undefined) {
      // cannot translate undefined points
      return;
    }

    var p = this.getPositionEl().translatePoints(x, y);
    this.setPosition(p.left, p.top);
    return this;
  },
  // private
  afterRender: function afterRender() {
    Ext.BoxComponent.superclass.afterRender.call(this);

    if (this.resizeEl) {
      this.resizeEl = Ext.get(this.resizeEl);
    }

    if (this.positionEl) {
      this.positionEl = Ext.get(this.positionEl);
    }

    this.boxReady = true;
    Ext.isDefined(this.autoScroll) && this.setAutoScroll(this.autoScroll);
    this.setSize(this.width, this.height);

    if (this.x || this.y) {
      this.setPosition(this.x, this.y);
    } else if (this.pageX || this.pageY) {
      this.setPagePosition(this.pageX, this.pageY);
    }
  },

  /**
   * Force the component's size to recalculate based on the underlying element's current height and width.
   * @return {Ext.BoxComponent} this
   */
  syncSize: function syncSize() {
    delete this.lastSize;
    this.setSize(this.autoWidth ? undefined : this.getResizeEl().getWidth(), this.autoHeight ? undefined : this.getResizeEl().getHeight());
    return this;
  },

  /* // protected
   * Called after the component is resized, this method is empty by default but can be implemented by any
   * subclass that needs to perform custom logic after a resize occurs.
   * @param {Number} adjWidth The box-adjusted width that was set
   * @param {Number} adjHeight The box-adjusted height that was set
   * @param {Number} rawWidth The width that was originally specified
   * @param {Number} rawHeight The height that was originally specified
   */
  onResize: function onResize(adjWidth, adjHeight, rawWidth, rawHeight) {},

  /* // protected
   * Called after the component is moved, this method is empty by default but can be implemented by any
   * subclass that needs to perform custom logic after a move occurs.
   * @param {Number} x The new x position
   * @param {Number} y The new y position
   */
  onPosition: function onPosition(x, y) {},
  // private
  adjustSize: function adjustSize(w, h) {
    if (this.autoWidth) {
      w = 'auto';
    }

    if (this.autoHeight) {
      h = 'auto';
    }

    return {
      width: w,
      height: h
    };
  },
  // private
  adjustPosition: function adjustPosition(x, y) {
    return {
      x: x,
      y: y
    };
  }
});
Ext.reg('box', Ext.BoxComponent);
/**
 * @class Ext.Spacer
 * @extends Ext.BoxComponent
 * <p>Used to provide a sizable space in a layout.</p>
 * @constructor
 * @param {Object} config
 */

Ext.Spacer = Ext.extend(Ext.BoxComponent, {
  autoEl: 'div'
});
Ext.reg('spacer', Ext.Spacer);

/***/ }),
/* 756 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.SplitBar
 * @extends Ext.util.Observable
 * Creates draggable splitter bar functionality from two elements (element to be dragged and element to be resized).
 * <br><br>
 * Usage:
 * <pre><code>
var split = new Ext.SplitBar("elementToDrag", "elementToSize",
                   Ext.SplitBar.HORIZONTAL, Ext.SplitBar.LEFT);
split.setAdapter(new Ext.SplitBar.AbsoluteLayoutAdapter("container"));
split.minSize = 100;
split.maxSize = 600;
split.animate = true;
split.on('moved', splitterMoved);
</code></pre>
 * @constructor
 * Create a new SplitBar
 * @param {Mixed} dragElement The element to be dragged and act as the SplitBar.
 * @param {Mixed} resizingElement The element to be resized based on where the SplitBar element is dragged
 * @param {Number} orientation (optional) Either Ext.SplitBar.HORIZONTAL or Ext.SplitBar.VERTICAL. (Defaults to HORIZONTAL)
 * @param {Number} placement (optional) Either Ext.SplitBar.LEFT or Ext.SplitBar.RIGHT for horizontal or
                        Ext.SplitBar.TOP or Ext.SplitBar.BOTTOM for vertical. (By default, this is determined automatically by the initial
                        position of the SplitBar).
 */
Ext.SplitBar = function (dragElement, resizingElement, orientation, placement, existingProxy) {
  /** @private */
  this.el = Ext.get(dragElement, true);
  this.el.dom.unselectable = "on";
  /** @private */

  this.resizingEl = Ext.get(resizingElement, true);
  /**
   * @private
   * The orientation of the split. Either Ext.SplitBar.HORIZONTAL or Ext.SplitBar.VERTICAL. (Defaults to HORIZONTAL)
   * Note: If this is changed after creating the SplitBar, the placement property must be manually updated
   * @type Number
   */

  this.orientation = orientation || Ext.SplitBar.HORIZONTAL;
  /**
   * The increment, in pixels by which to move this SplitBar. When <i>undefined</i>, the SplitBar moves smoothly.
   * @type Number
   * @property tickSize
   */

  /**
   * The minimum size of the resizing element. (Defaults to 0)
   * @type Number
   */

  this.minSize = 0;
  /**
   * The maximum size of the resizing element. (Defaults to 2000)
   * @type Number
   */

  this.maxSize = 2000;
  /**
   * Whether to animate the transition to the new size
   * @type Boolean
   */

  this.animate = false;
  /**
   * Whether to create a transparent shim that overlays the page when dragging, enables dragging across iframes.
   * @type Boolean
   */

  this.useShim = false;
  /** @private */

  this.shim = null;

  if (!existingProxy) {
    /** @private */
    this.proxy = Ext.SplitBar.createProxy(this.orientation);
  } else {
    this.proxy = Ext.get(existingProxy).dom;
  }
  /** @private */


  this.dd = new Ext.dd.DDProxy(this.el.dom.id, "XSplitBars", {
    dragElId: this.proxy.id
  });
  /** @private */

  this.dd.b4StartDrag = this.onStartProxyDrag.createDelegate(this);
  /** @private */

  this.dd.endDrag = this.onEndProxyDrag.createDelegate(this);
  /** @private */

  this.dragSpecs = {};
  /**
   * @private The adapter to use to positon and resize elements
   */

  this.adapter = new Ext.SplitBar.BasicLayoutAdapter();
  this.adapter.init(this);

  if (this.orientation == Ext.SplitBar.HORIZONTAL) {
    /** @private */
    this.placement = placement || (this.el.getX() > this.resizingEl.getX() ? Ext.SplitBar.LEFT : Ext.SplitBar.RIGHT);
    this.el.addClass("x-splitbar-h");
  } else {
    /** @private */
    this.placement = placement || (this.el.getY() > this.resizingEl.getY() ? Ext.SplitBar.TOP : Ext.SplitBar.BOTTOM);
    this.el.addClass("x-splitbar-v");
  }

  this.addEvents(
  /**
   * @event resize
   * Fires when the splitter is moved (alias for {@link #moved})
   * @param {Ext.SplitBar} this
   * @param {Number} newSize the new width or height
   */
  "resize",
  /**
   * @event moved
   * Fires when the splitter is moved
   * @param {Ext.SplitBar} this
   * @param {Number} newSize the new width or height
   */
  "moved",
  /**
   * @event beforeresize
   * Fires before the splitter is dragged
   * @param {Ext.SplitBar} this
   */
  "beforeresize", "beforeapply");
  Ext.SplitBar.superclass.constructor.call(this);
};

Ext.extend(Ext.SplitBar, Ext.util.Observable, {
  onStartProxyDrag: function onStartProxyDrag(x, y) {
    this.fireEvent("beforeresize", this);
    this.overlay = Ext.DomHelper.append(document.body, {
      cls: "x-drag-overlay",
      html: "&#160;"
    }, true);
    this.overlay.unselectable();
    this.overlay.setSize(Ext.lib.Dom.getViewWidth(true), Ext.lib.Dom.getViewHeight(true));
    this.overlay.show();
    Ext.get(this.proxy).setDisplayed("block");
    var size = this.adapter.getElementSize(this);
    this.activeMinSize = this.getMinimumSize();
    this.activeMaxSize = this.getMaximumSize();
    var c1 = size - this.activeMinSize;
    var c2 = Math.max(this.activeMaxSize - size, 0);

    if (this.orientation == Ext.SplitBar.HORIZONTAL) {
      this.dd.resetConstraints();
      this.dd.setXConstraint(this.placement == Ext.SplitBar.LEFT ? c1 : c2, this.placement == Ext.SplitBar.LEFT ? c2 : c1, this.tickSize);
      this.dd.setYConstraint(0, 0);
    } else {
      this.dd.resetConstraints();
      this.dd.setXConstraint(0, 0);
      this.dd.setYConstraint(this.placement == Ext.SplitBar.TOP ? c1 : c2, this.placement == Ext.SplitBar.TOP ? c2 : c1, this.tickSize);
    }

    this.dragSpecs.startSize = size;
    this.dragSpecs.startPoint = [x, y];
    Ext.dd.DDProxy.prototype.b4StartDrag.call(this.dd, x, y);
  },

  /**
   * @private Called after the drag operation by the DDProxy
   */
  onEndProxyDrag: function onEndProxyDrag(e) {
    Ext.get(this.proxy).setDisplayed(false);
    var endPoint = Ext.lib.Event.getXY(e);

    if (this.overlay) {
      Ext.destroy(this.overlay);
      delete this.overlay;
    }

    var newSize;

    if (this.orientation == Ext.SplitBar.HORIZONTAL) {
      newSize = this.dragSpecs.startSize + (this.placement == Ext.SplitBar.LEFT ? endPoint[0] - this.dragSpecs.startPoint[0] : this.dragSpecs.startPoint[0] - endPoint[0]);
    } else {
      newSize = this.dragSpecs.startSize + (this.placement == Ext.SplitBar.TOP ? endPoint[1] - this.dragSpecs.startPoint[1] : this.dragSpecs.startPoint[1] - endPoint[1]);
    }

    newSize = Math.min(Math.max(newSize, this.activeMinSize), this.activeMaxSize);

    if (newSize != this.dragSpecs.startSize) {
      if (this.fireEvent('beforeapply', this, newSize) !== false) {
        this.adapter.setElementSize(this, newSize);
        this.fireEvent("moved", this, newSize);
        this.fireEvent("resize", this, newSize);
      }
    }
  },

  /**
   * Get the adapter this SplitBar uses
   * @return The adapter object
   */
  getAdapter: function getAdapter() {
    return this.adapter;
  },

  /**
   * Set the adapter this SplitBar uses
   * @param {Object} adapter A SplitBar adapter object
   */
  setAdapter: function setAdapter(adapter) {
    this.adapter = adapter;
    this.adapter.init(this);
  },

  /**
   * Gets the minimum size for the resizing element
   * @return {Number} The minimum size
   */
  getMinimumSize: function getMinimumSize() {
    return this.minSize;
  },

  /**
   * Sets the minimum size for the resizing element
   * @param {Number} minSize The minimum size
   */
  setMinimumSize: function setMinimumSize(minSize) {
    this.minSize = minSize;
  },

  /**
   * Gets the maximum size for the resizing element
   * @return {Number} The maximum size
   */
  getMaximumSize: function getMaximumSize() {
    return this.maxSize;
  },

  /**
   * Sets the maximum size for the resizing element
   * @param {Number} maxSize The maximum size
   */
  setMaximumSize: function setMaximumSize(maxSize) {
    this.maxSize = maxSize;
  },

  /**
   * Sets the initialize size for the resizing element
   * @param {Number} size The initial size
   */
  setCurrentSize: function setCurrentSize(size) {
    var oldAnimate = this.animate;
    this.animate = false;
    this.adapter.setElementSize(this, size);
    this.animate = oldAnimate;
  },

  /**
   * Destroy this splitbar.
   * @param {Boolean} removeEl True to remove the element
   */
  destroy: function destroy(removeEl) {
    Ext.destroy(this.shim, Ext.get(this.proxy));
    this.dd.unreg();

    if (removeEl) {
      this.el.remove();
    }

    this.purgeListeners();
  }
});
/**
 * @private static Create our own proxy element element. So it will be the same same size on all browsers, we won't use borders. Instead we use a background color.
 */

Ext.SplitBar.createProxy = function (dir) {
  var proxy = new Ext.Element(document.createElement("div"));
  document.body.appendChild(proxy.dom);
  proxy.unselectable();
  var cls = 'x-splitbar-proxy';
  proxy.addClass(cls + ' ' + (dir == Ext.SplitBar.HORIZONTAL ? cls + '-h' : cls + '-v'));
  return proxy.dom;
};
/**
 * @class Ext.SplitBar.BasicLayoutAdapter
 * Default Adapter. It assumes the splitter and resizing element are not positioned
 * elements and only gets/sets the width of the element. Generally used for table based layouts.
 */


Ext.SplitBar.BasicLayoutAdapter = function () {};

Ext.SplitBar.BasicLayoutAdapter.prototype = {
  // do nothing for now
  init: function init(s) {},

  /**
   * Called before drag operations to get the current size of the resizing element.
   * @param {Ext.SplitBar} s The SplitBar using this adapter
   */
  getElementSize: function getElementSize(s) {
    if (s.orientation == Ext.SplitBar.HORIZONTAL) {
      return s.resizingEl.getWidth();
    } else {
      return s.resizingEl.getHeight();
    }
  },

  /**
   * Called after drag operations to set the size of the resizing element.
   * @param {Ext.SplitBar} s The SplitBar using this adapter
   * @param {Number} newSize The new size to set
   * @param {Function} onComplete A function to be invoked when resizing is complete
   */
  setElementSize: function setElementSize(s, newSize, onComplete) {
    if (s.orientation == Ext.SplitBar.HORIZONTAL) {
      if (!s.animate) {
        s.resizingEl.setWidth(newSize);

        if (onComplete) {
          onComplete(s, newSize);
        }
      } else {
        s.resizingEl.setWidth(newSize, true, .1, onComplete, 'easeOut');
      }
    } else {
      if (!s.animate) {
        s.resizingEl.setHeight(newSize);

        if (onComplete) {
          onComplete(s, newSize);
        }
      } else {
        s.resizingEl.setHeight(newSize, true, .1, onComplete, 'easeOut');
      }
    }
  }
};
/**
 *@class Ext.SplitBar.AbsoluteLayoutAdapter
 * @extends Ext.SplitBar.BasicLayoutAdapter
 * Adapter that  moves the splitter element to align with the resized sizing element.
 * Used with an absolute positioned SplitBar.
 * @param {Mixed} container The container that wraps around the absolute positioned content. If it's
 * document.body, make sure you assign an id to the body element.
 */

Ext.SplitBar.AbsoluteLayoutAdapter = function (container) {
  this.basic = new Ext.SplitBar.BasicLayoutAdapter();
  this.container = Ext.get(container);
};

Ext.SplitBar.AbsoluteLayoutAdapter.prototype = {
  init: function init(s) {
    this.basic.init(s);
  },
  getElementSize: function getElementSize(s) {
    return this.basic.getElementSize(s);
  },
  setElementSize: function setElementSize(s, newSize, onComplete) {
    this.basic.setElementSize(s, newSize, this.moveSplitter.createDelegate(this, [s]));
  },
  moveSplitter: function moveSplitter(s) {
    var yes = Ext.SplitBar;

    switch (s.placement) {
      case yes.LEFT:
        s.el.setX(s.resizingEl.getRight());
        break;

      case yes.RIGHT:
        s.el.setStyle("right", this.container.getWidth() - s.resizingEl.getLeft() + "px");
        break;

      case yes.TOP:
        s.el.setY(s.resizingEl.getBottom());
        break;

      case yes.BOTTOM:
        s.el.setY(s.resizingEl.getTop() - s.el.getHeight());
        break;
    }
  }
};
/**
 * Orientation constant - Create a vertical SplitBar
 * @static
 * @type Number
 */

Ext.SplitBar.VERTICAL = 1;
/**
 * Orientation constant - Create a horizontal SplitBar
 * @static
 * @type Number
 */

Ext.SplitBar.HORIZONTAL = 2;
/**
 * Placement constant - The resizing element is to the left of the splitter element
 * @static
 * @type Number
 */

Ext.SplitBar.LEFT = 1;
/**
 * Placement constant - The resizing element is to the right of the splitter element
 * @static
 * @type Number
 */

Ext.SplitBar.RIGHT = 2;
/**
 * Placement constant - The resizing element is positioned above the splitter element
 * @static
 * @type Number
 */

Ext.SplitBar.TOP = 3;
/**
 * Placement constant - The resizing element is positioned under splitter element
 * @static
 * @type Number
 */

Ext.SplitBar.BOTTOM = 4;

/***/ }),
/* 757 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Container
 * @extends Ext.BoxComponent
 * <p>Base class for any {@link Ext.BoxComponent} that may contain other Components. Containers handle the
 * basic behavior of containing items, namely adding, inserting and removing items.</p>
 *
 * <p>The most commonly used Container classes are {@link Ext.Panel}, {@link Ext.Window} and {@link Ext.TabPanel}.
 * If you do not need the capabilities offered by the aforementioned classes you can create a lightweight
 * Container to be encapsulated by an HTML element to your specifications by using the
 * <code><b>{@link Ext.Component#autoEl autoEl}</b></code> config option. This is a useful technique when creating
 * embedded {@link Ext.layout.ColumnLayout column} layouts inside {@link Ext.form.FormPanel FormPanels}
 * for example.</p>
 *
 * <p>The code below illustrates both how to explicitly create a Container, and how to implicitly
 * create one using the <b><code>'container'</code></b> xtype:<pre><code>
// explicitly create a Container
var embeddedColumns = new Ext.Container({
    autoEl: 'div',  // This is the default
    layout: 'column',
    defaults: {
        // implicitly create Container by specifying xtype
        xtype: 'container',
        autoEl: 'div', // This is the default.
        layout: 'form',
        columnWidth: 0.5,
        style: {
            padding: '10px'
        }
    },
//  The two items below will be Ext.Containers, each encapsulated by a &lt;DIV> element.
    items: [{
        items: {
            xtype: 'datefield',
            name: 'startDate',
            fieldLabel: 'Start date'
        }
    }, {
        items: {
            xtype: 'datefield',
            name: 'endDate',
            fieldLabel: 'End date'
        }
    }]
});</code></pre></p>
 *
 * <p><u><b>Layout</b></u></p>
 * <p>Container classes delegate the rendering of child Components to a layout
 * manager class which must be configured into the Container using the
 * <code><b>{@link #layout}</b></code> configuration property.</p>
 * <p>When either specifying child <code>{@link #items}</code> of a Container,
 * or dynamically {@link #add adding} Components to a Container, remember to
 * consider how you wish the Container to arrange those child elements, and
 * whether those child elements need to be sized using one of Ext's built-in
 * <b><code>{@link #layout}</code></b> schemes. By default, Containers use the
 * {@link Ext.layout.ContainerLayout ContainerLayout} scheme which only
 * renders child components, appending them one after the other inside the
 * Container, and <b>does not apply any sizing</b> at all.</p>
 * <p>A common mistake is when a developer neglects to specify a
 * <b><code>{@link #layout}</code></b> (e.g. widgets like GridPanels or
 * TreePanels are added to Containers for which no <code><b>{@link #layout}</b></code>
 * has been specified). If a Container is left to use the default
 * {@link Ext.layout.ContainerLayout ContainerLayout} scheme, none of its
 * child components will be resized, or changed in any way when the Container
 * is resized.</p>
 * <p>Certain layout managers allow dynamic addition of child components.
 * Those that do include {@link Ext.layout.CardLayout},
 * {@link Ext.layout.AnchorLayout}, {@link Ext.layout.FormLayout}, and
 * {@link Ext.layout.TableLayout}. For example:<pre><code>
//  Create the GridPanel.
var myNewGrid = new Ext.grid.GridPanel({
    store: myStore,
    columns: myColumnModel,
    title: 'Results', // the title becomes the title of the tab
});

myTabPanel.add(myNewGrid); // {@link Ext.TabPanel} implicitly uses {@link Ext.layout.CardLayout CardLayout}
myTabPanel.{@link Ext.TabPanel#setActiveTab setActiveTab}(myNewGrid);
 * </code></pre></p>
 * <p>The example above adds a newly created GridPanel to a TabPanel. Note that
 * a TabPanel uses {@link Ext.layout.CardLayout} as its layout manager which
 * means all its child items are sized to {@link Ext.layout.FitLayout fit}
 * exactly into its client area.
 * <p><b><u>Overnesting is a common problem</u></b>.
 * An example of overnesting occurs when a GridPanel is added to a TabPanel
 * by wrapping the GridPanel <i>inside</i> a wrapping Panel (that has no
 * <code><b>{@link #layout}</b></code> specified) and then add that wrapping Panel
 * to the TabPanel. The point to realize is that a GridPanel <b>is</b> a
 * Component which can be added directly to a Container. If the wrapping Panel
 * has no <code><b>{@link #layout}</b></code> configuration, then the overnested
 * GridPanel will not be sized as expected.<p>
 *
 * <p><u><b>Adding via remote configuration</b></u></p>
 *
 * <p>A server side script can be used to add Components which are generated dynamically on the server.
 * An example of adding a GridPanel to a TabPanel where the GridPanel is generated by the server
 * based on certain parameters:
 * </p><pre><code>
// execute an Ajax request to invoke server side script:
Ext.Ajax.request({
    url: 'gen-invoice-grid.php',
    // send additional parameters to instruct server script
    params: {
        startDate: Ext.getCmp('start-date').getValue(),
        endDate: Ext.getCmp('end-date').getValue()
    },
    // process the response object to add it to the TabPanel:
    success: function(xhr) {
        var newComponent = eval(xhr.responseText); // see discussion below
        myTabPanel.add(newComponent); // add the component to the TabPanel
        myTabPanel.setActiveTab(newComponent);
    },
    failure: function() {
        Ext.Msg.alert("Grid create failed", "Server communication failure");
    }
});
</code></pre>
 * <p>The server script needs to return an executable Javascript statement which, when processed
 * using <code>eval()</code>, will return either a config object with an {@link Ext.Component#xtype xtype},
 * or an instantiated Component. The server might return this for example:</p><pre><code>
(function() {
    function formatDate(value){
        return value ? value.dateFormat('M d, Y') : '';
    };

    var store = new Ext.data.Store({
        url: 'get-invoice-data.php',
        baseParams: {
            startDate: '01/01/2008',
            endDate: '01/31/2008'
        },
        reader: new Ext.data.JsonReader({
            record: 'transaction',
            idProperty: 'id',
            totalRecords: 'total'
        }, [
           'customer',
           'invNo',
           {name: 'date', type: 'date', dateFormat: 'm/d/Y'},
           {name: 'value', type: 'float'}
        ])
    });

    var grid = new Ext.grid.GridPanel({
        title: 'Invoice Report',
        bbar: new Ext.PagingToolbar(store),
        store: store,
        columns: [
            {header: "Customer", width: 250, dataIndex: 'customer', sortable: true},
            {header: "Invoice Number", width: 120, dataIndex: 'invNo', sortable: true},
            {header: "Invoice Date", width: 100, dataIndex: 'date', renderer: formatDate, sortable: true},
            {header: "Value", width: 120, dataIndex: 'value', renderer: 'usMoney', sortable: true}
        ],
    });
    store.load();
    return grid;  // return instantiated component
})();
</code></pre>
 * <p>When the above code fragment is passed through the <code>eval</code> function in the success handler
 * of the Ajax request, the code is executed by the Javascript processor, and the anonymous function
 * runs, and returns the instantiated grid component.</p>
 * <p>Note: since the code above is <i>generated</i> by a server script, the <code>baseParams</code> for
 * the Store, the metadata to allow generation of the Record layout, and the ColumnModel
 * can all be generated into the code since these are all known on the server.</p>
 *
 * @xtype container
 */
Ext.Container = Ext.extend(Ext.BoxComponent, {
  /**
   * @cfg {Boolean} monitorResize
   * True to automatically monitor window resize events to handle anything that is sensitive to the current size
   * of the viewport.  This value is typically managed by the chosen <code>{@link #layout}</code> and should not need
   * to be set manually.
   */

  /**
   * @cfg {String/Object} layout
   * <p><b>*Important</b>: In order for child items to be correctly sized and
   * positioned, typically a layout manager <b>must</b> be specified through
   * the <code>layout</code> configuration option.</p>
   * <br><p>The sizing and positioning of child {@link items} is the responsibility of
   * the Container's layout manager which creates and manages the type of layout
   * you have in mind.  For example:</p><pre><code>
  new Ext.Window({
  width:300, height: 300,
  layout: 'fit', // explicitly set layout manager: override the default (layout:'auto')
  items: [{
      title: 'Panel inside a Window'
  }]
  }).show();
   * </code></pre>
   * <p>If the {@link #layout} configuration is not explicitly specified for
   * a general purpose container (e.g. Container or Panel) the
   * {@link Ext.layout.ContainerLayout default layout manager} will be used
   * which does nothing but render child components sequentially into the
   * Container (no sizing or positioning will be performed in this situation).
   * Some container classes implicitly specify a default layout
   * (e.g. FormPanel specifies <code>layout:'form'</code>). Other specific
   * purpose classes internally specify/manage their internal layout (e.g.
   * GridPanel, TabPanel, TreePanel, Toolbar, Menu, etc.).</p>
   * <br><p><b><code>layout</code></b> may be specified as either as an Object or
   * as a String:</p><div><ul class="mdetail-params">
   *
   * <li><u>Specify as an Object</u></li>
   * <div><ul class="mdetail-params">
   * <li>Example usage:</li>
  <pre><code>
  layout: {
  type: 'vbox',
  padding: '5',
  align: 'left'
  }
  </code></pre>
   *
   * <li><code><b>type</b></code></li>
   * <br/><p>The layout type to be used for this container.  If not specified,
   * a default {@link Ext.layout.ContainerLayout} will be created and used.</p>
   * <br/><p>Valid layout <code>type</code> values are:</p>
   * <div class="sub-desc"><ul class="mdetail-params">
   * <li><code><b>{@link Ext.layout.AbsoluteLayout absolute}</b></code></li>
   * <li><code><b>{@link Ext.layout.AccordionLayout accordion}</b></code></li>
   * <li><code><b>{@link Ext.layout.AnchorLayout anchor}</b></code></li>
   * <li><code><b>{@link Ext.layout.ContainerLayout auto}</b></code> &nbsp;&nbsp;&nbsp; <b>Default</b></li>
   * <li><code><b>{@link Ext.layout.BorderLayout border}</b></code></li>
   * <li><code><b>{@link Ext.layout.CardLayout card}</b></code></li>
   * <li><code><b>{@link Ext.layout.ColumnLayout column}</b></code></li>
   * <li><code><b>{@link Ext.layout.FitLayout fit}</b></code></li>
   * <li><code><b>{@link Ext.layout.FormLayout form}</b></code></li>
   * <li><code><b>{@link Ext.layout.HBoxLayout hbox}</b></code></li>
   * <li><code><b>{@link Ext.layout.MenuLayout menu}</b></code></li>
   * <li><code><b>{@link Ext.layout.TableLayout table}</b></code></li>
   * <li><code><b>{@link Ext.layout.ToolbarLayout toolbar}</b></code></li>
   * <li><code><b>{@link Ext.layout.VBoxLayout vbox}</b></code></li>
   * </ul></div>
   *
   * <li>Layout specific configuration properties</li>
   * <br/><p>Additional layout specific configuration properties may also be
   * specified. For complete details regarding the valid config options for
   * each layout type, see the layout class corresponding to the <code>type</code>
   * specified.</p>
   *
   * </ul></div>
   *
   * <li><u>Specify as a String</u></li>
   * <div><ul class="mdetail-params">
   * <li>Example usage:</li>
  <pre><code>
  layout: 'vbox',
  layoutConfig: {
  padding: '5',
  align: 'left'
  }
  </code></pre>
   * <li><code><b>layout</b></code></li>
   * <br/><p>The layout <code>type</code> to be used for this container (see list
   * of valid layout type values above).</p><br/>
   * <li><code><b>{@link #layoutConfig}</b></code></li>
   * <br/><p>Additional layout specific configuration properties. For complete
   * details regarding the valid config options for each layout type, see the
   * layout class corresponding to the <code>layout</code> specified.</p>
   * </ul></div></ul></div>
   */

  /**
   * @cfg {Object} layoutConfig
   * This is a config object containing properties specific to the chosen
   * <b><code>{@link #layout}</code></b> if <b><code>{@link #layout}</code></b>
   * has been specified as a <i>string</i>.</p>
   */

  /**
   * @cfg {Boolean/Number} bufferResize
   * When set to true (50 milliseconds) or a number of milliseconds, the layout assigned for this container will buffer
   * the frequency it calculates and does a re-layout of components. This is useful for heavy containers or containers
   * with a large quantity of sub-components for which frequent layout calls would be expensive. Defaults to <code>50</code>.
   */
  // Deprecated - will be removed in 3.2.x
  bufferResize: 50,

  /**
   * @cfg {String/Number} activeItem
   * A string component id or the numeric index of the component that should be initially activated within the
   * container's layout on render.  For example, activeItem: 'item-1' or activeItem: 0 (index 0 = the first
   * item in the container's collection).  activeItem only applies to layout styles that can display
   * items one at a time (like {@link Ext.layout.AccordionLayout}, {@link Ext.layout.CardLayout} and
   * {@link Ext.layout.FitLayout}).  Related to {@link Ext.layout.ContainerLayout#activeItem}.
   */

  /**
   * @cfg {Object/Array} items
   * <pre><b>** IMPORTANT</b>: be sure to <b>{@link #layout specify a <code>layout</code>} if needed ! **</b></pre>
   * <p>A single item, or an array of child Components to be added to this container,
   * for example:</p>
   * <pre><code>
  // specifying a single item
  items: {...},
  layout: 'fit',    // specify a layout!
  // specifying multiple items
  items: [{...}, {...}],
  layout: 'anchor', // specify a layout!
   * </code></pre>
   * <p>Each item may be:</p>
   * <div><ul class="mdetail-params">
   * <li>any type of object based on {@link Ext.Component}</li>
   * <li>a fully instanciated object or</li>
   * <li>an object literal that:</li>
   * <div><ul class="mdetail-params">
   * <li>has a specified <code>{@link Ext.Component#xtype xtype}</code></li>
   * <li>the {@link Ext.Component#xtype} specified is associated with the Component
   * desired and should be chosen from one of the available xtypes as listed
   * in {@link Ext.Component}.</li>
   * <li>If an <code>{@link Ext.Component#xtype xtype}</code> is not explicitly
   * specified, the {@link #defaultType} for that Container is used.</li>
   * <li>will be "lazily instanciated", avoiding the overhead of constructing a fully
   * instanciated Component object</li>
   * </ul></div></ul></div>
   * <p><b>Notes</b>:</p>
   * <div><ul class="mdetail-params">
   * <li>Ext uses lazy rendering. Child Components will only be rendered
   * should it become necessary. Items are automatically laid out when they are first
   * shown (no sizing is done while hidden), or in response to a {@link #doLayout} call.</li>
   * <li>Do not specify <code>{@link Ext.Panel#contentEl contentEl}</code>/
   * <code>{@link Ext.Panel#html html}</code> with <code>items</code>.</li>
   * </ul></div>
   */

  /**
   * @cfg {Object|Function} defaults
   * <p>This option is a means of applying default settings to all added items whether added through the {@link #items}
   * config or via the {@link #add} or {@link #insert} methods.</p>
   * <p>If an added item is a config object, and <b>not</b> an instantiated Component, then the default properties are
   * unconditionally applied. If the added item <b>is</b> an instantiated Component, then the default properties are
   * applied conditionally so as not to override existing properties in the item.</p>
   * <p>If the defaults option is specified as a function, then the function will be called using this Container as the
   * scope (<code>this</code> reference) and passing the added item as the first parameter. Any resulting object
   * from that call is then applied to the item as default properties.</p>
   * <p>For example, to automatically apply padding to the body of each of a set of
   * contained {@link Ext.Panel} items, you could pass: <code>defaults: {bodyStyle:'padding:15px'}</code>.</p>
   * <p>Usage:</p><pre><code>
  defaults: {               // defaults are applied to items, not the container
  autoScroll:true
  },
  items: [
  {
      xtype: 'panel',   // defaults <b>do not</b> have precedence over
      id: 'panel1',     // options in config objects, so the defaults
      autoScroll: false // will not be applied here, panel1 will be autoScroll:false
  },
  new Ext.Panel({       // defaults <b>do</b> have precedence over options
      id: 'panel2',     // options in components, so the defaults
      autoScroll: false // will be applied here, panel2 will be autoScroll:true.
  })
  ]
   * </code></pre>
   */

  /** @cfg {Boolean} autoDestroy
   * If true the container will automatically destroy any contained component that is removed from it, else
   * destruction must be handled manually (defaults to true).
   */
  autoDestroy: true,

  /** @cfg {Boolean} forceLayout
   * If true the container will force a layout initially even if hidden or collapsed. This option
   * is useful for forcing forms to render in collapsed or hidden containers. (defaults to false).
   */
  forceLayout: false,

  /** @cfg {Boolean} hideBorders
   * True to hide the borders of each contained component, false to defer to the component's existing
   * border settings (defaults to false).
   */

  /** @cfg {String} defaultType
   * <p>The default {@link Ext.Component xtype} of child Components to create in this Container when
   * a child item is specified as a raw configuration object, rather than as an instantiated Component.</p>
   * <p>Defaults to <code>'panel'</code>, except {@link Ext.menu.Menu} which defaults to <code>'menuitem'</code>,
   * and {@link Ext.Toolbar} and {@link Ext.ButtonGroup} which default to <code>'button'</code>.</p>
   */
  defaultType: 'panel',

  /** @cfg {String} resizeEvent
   * The event to listen to for resizing in layouts. Defaults to <code>'resize'</code>.
   */
  resizeEvent: 'resize',

  /**
   * @cfg {Array} bubbleEvents
   * <p>An array of events that, when fired, should be bubbled to any parent container.
   * See {@link Ext.util.Observable#enableBubble}.
   * Defaults to <code>['add', 'remove']</code>.
   */
  bubbleEvents: ['add', 'remove'],
  // private
  initComponent: function initComponent() {
    Ext.Container.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event afterlayout
     * Fires when the components in this container are arranged by the associated layout manager.
     * @param {Ext.Container} this
     * @param {ContainerLayout} layout The ContainerLayout implementation for this container
     */
    'afterlayout',
    /**
     * @event beforeadd
     * Fires before any {@link Ext.Component} is added or inserted into the container.
     * A handler can return false to cancel the add.
     * @param {Ext.Container} this
     * @param {Ext.Component} component The component being added
     * @param {Number} index The index at which the component will be added to the container's items collection
     */
    'beforeadd',
    /**
     * @event beforeremove
     * Fires before any {@link Ext.Component} is removed from the container.  A handler can return
     * false to cancel the remove.
     * @param {Ext.Container} this
     * @param {Ext.Component} component The component being removed
     */
    'beforeremove',
    /**
     * @event add
     * @bubbles
     * Fires after any {@link Ext.Component} is added or inserted into the container.
     * @param {Ext.Container} this
     * @param {Ext.Component} component The component that was added
     * @param {Number} index The index at which the component was added to the container's items collection
     */
    'add',
    /**
     * @event remove
     * @bubbles
     * Fires after any {@link Ext.Component} is removed from the container.
     * @param {Ext.Container} this
     * @param {Ext.Component} component The component that was removed
     */
    'remove');
    this.enableBubble(this.bubbleEvents);
    /**
     * The collection of components in this container as a {@link Ext.util.MixedCollection}
     * @type MixedCollection
     * @property items
     */

    var items = this.items;

    if (items) {
      delete this.items;
      this.add(items);
    }
  },
  // private
  initItems: function initItems() {
    if (!this.items) {
      this.items = new Ext.util.MixedCollection(false, this.getComponentId);
      this.getLayout(); // initialize the layout
    }
  },
  // private
  setLayout: function setLayout(layout) {
    if (this.layout && this.layout != layout) {
      this.layout.setContainer(null);
    }

    this.initItems();
    this.layout = layout;
    layout.setContainer(this);
  },
  afterRender: function afterRender() {
    // Render this Container, this should be done before setLayout is called which
    // will hook onResize
    Ext.Container.superclass.afterRender.call(this);

    if (!this.layout) {
      this.layout = 'auto';
    }

    if (Ext.isObject(this.layout) && !this.layout.layout) {
      this.layoutConfig = this.layout;
      this.layout = this.layoutConfig.type;
    }

    if (Ext.isString(this.layout)) {
      this.layout = new Ext.Container.LAYOUTS[this.layout.toLowerCase()](this.layoutConfig);
    }

    this.setLayout(this.layout); // If a CardLayout, the active item set

    if (this.activeItem !== undefined) {
      var item = this.activeItem;
      delete this.activeItem;
      this.layout.setActiveItem(item);
    } // If we have no ownerCt, render and size all children


    if (!this.ownerCt) {
      this.doLayout(false, true);
    } // This is a manually configured flag set by users in conjunction with renderTo.
    // Not to be confused with the flag by the same name used in Layouts.


    if (this.monitorResize === true) {
      Ext.EventManager.onWindowResize(this.doLayout, this, [false]);
    }
  },

  /**
   * <p>Returns the Element to be used to contain the child Components of this Container.</p>
   * <p>An implementation is provided which returns the Container's {@link #getEl Element}, but
   * if there is a more complex structure to a Container, this may be overridden to return
   * the element into which the {@link #layout layout} renders child Components.</p>
   * @return {Ext.Element} The Element to render child Components into.
   */
  getLayoutTarget: function getLayoutTarget() {
    return this.el;
  },
  // private - used as the key lookup function for the items collection
  getComponentId: function getComponentId(comp) {
    return comp.getItemId();
  },

  /**
   * <p>Adds {@link Ext.Component Component}(s) to this Container.</p>
   * <br><p><b>Description</b></u> :
   * <div><ul class="mdetail-params">
   * <li>Fires the {@link #beforeadd} event before adding</li>
   * <li>The Container's {@link #defaults default config values} will be applied
   * accordingly (see <code>{@link #defaults}</code> for details).</li>
   * <li>Fires the {@link #add} event after the component has been added.</li>
   * </ul></div>
   * <br><p><b>Notes</b></u> :
   * <div><ul class="mdetail-params">
   * <li>If the Container is <i>already rendered</i> when <code>add</code>
   * is called, you may need to call {@link #doLayout} to refresh the view which causes
   * any unrendered child Components to be rendered. This is required so that you can
   * <code>add</code> multiple child components if needed while only refreshing the layout
   * once. For example:<pre><code>
  var tb = new {@link Ext.Toolbar}();
  tb.render(document.body);  // toolbar is rendered
  tb.add({text:'Button 1'}); // add multiple items ({@link #defaultType} for {@link Ext.Toolbar Toolbar} is 'button')
  tb.add({text:'Button 2'});
  tb.{@link #doLayout}();             // refresh the layout
   * </code></pre></li>
   * <li><i>Warning:</i> Containers directly managed by the BorderLayout layout manager
   * may not be removed or added.  See the Notes for {@link Ext.layout.BorderLayout BorderLayout}
   * for more details.</li>
   * </ul></div>
   * @param {Object/Array} component
   * <p>Either a single component or an Array of components to add.  See
   * <code>{@link #items}</code> for additional information.</p>
   * @param {Object} (Optional) component_2
   * @param {Object} (Optional) component_n
   * @return {Ext.Component} component The Component (or config object) that was added.
   */
  add: function add(comp) {
    this.initItems();
    var args = arguments.length > 1;

    if (args || Ext.isArray(comp)) {
      var result = [];
      Ext.each(args ? arguments : comp, function (c) {
        result.push(this.add(c));
      }, this);
      return result;
    }

    var c = this.lookupComponent(this.applyDefaults(comp));
    var index = this.items.length;

    if (this.fireEvent('beforeadd', this, c, index) !== false && this.onBeforeAdd(c) !== false) {
      this.items.add(c); // *onAdded

      c.onAdded(this, index);
      this.onAdd(c);
      this.fireEvent('add', this, c, index);
    }

    return c;
  },
  onAdd: function onAdd(c) {// Empty template method
  },
  // private
  onAdded: function onAdded(container, pos) {
    //overridden here so we can cascade down, not worth creating a template method.
    this.ownerCt = container;
    this.initRef(); //initialize references for child items

    this.cascade(function (c) {
      c.initRef();
    });
    this.fireEvent('added', this, container, pos);
  },

  /**
   * Inserts a Component into this Container at a specified index. Fires the
   * {@link #beforeadd} event before inserting, then fires the {@link #add} event after the
   * Component has been inserted.
   * @param {Number} index The index at which the Component will be inserted
   * into the Container's items collection
   * @param {Ext.Component} component The child Component to insert.<br><br>
   * Ext uses lazy rendering, and will only render the inserted Component should
   * it become necessary.<br><br>
   * A Component config object may be passed in order to avoid the overhead of
   * constructing a real Component object if lazy rendering might mean that the
   * inserted Component will not be rendered immediately. To take advantage of
   * this 'lazy instantiation', set the {@link Ext.Component#xtype} config
   * property to the registered type of the Component wanted.<br><br>
   * For a list of all available xtypes, see {@link Ext.Component}.
   * @return {Ext.Component} component The Component (or config object) that was
   * inserted with the Container's default config values applied.
   */
  insert: function insert(index, comp) {
    this.initItems();
    var a = arguments,
        len = a.length;

    if (len > 2) {
      var result = [];

      for (var i = len - 1; i >= 1; --i) {
        result.push(this.insert(index, a[i]));
      }

      return result;
    }

    var c = this.lookupComponent(this.applyDefaults(comp));
    index = Math.min(index, this.items.length);

    if (this.fireEvent('beforeadd', this, c, index) !== false && this.onBeforeAdd(c) !== false) {
      if (c.ownerCt == this) {
        this.items.remove(c);
      }

      this.items.insert(index, c);
      c.onAdded(this, index);
      this.onAdd(c);
      this.fireEvent('add', this, c, index);
    }

    return c;
  },
  // private
  applyDefaults: function applyDefaults(c) {
    var d = this.defaults;

    if (d) {
      if (Ext.isFunction(d)) {
        d = d.call(this, c);
      }

      if (Ext.isString(c)) {
        c = Ext.ComponentMgr.get(c);
        Ext.apply(c, d);
      } else if (!c.events) {
        Ext.applyIf(c, d);
      } else {
        Ext.apply(c, d);
      }
    }

    return c;
  },
  // private
  onBeforeAdd: function onBeforeAdd(item) {
    if (item.ownerCt) {
      item.ownerCt.remove(item, false);
    }

    if (this.hideBorders === true) {
      item.border = item.border === true;
    }
  },

  /**
   * Removes a component from this container.  Fires the {@link #beforeremove} event before removing, then fires
   * the {@link #remove} event after the component has been removed.
   * @param {Component/String} component The component reference or id to remove.
   * @param {Boolean} autoDestroy (optional) True to automatically invoke the removed Component's {@link Ext.Component#destroy} function.
   * Defaults to the value of this Container's {@link #autoDestroy} config.
   * @return {Ext.Component} component The Component that was removed.
   */
  remove: function remove(comp, autoDestroy) {
    this.initItems();
    var c = this.getComponent(comp);

    if (c && this.fireEvent('beforeremove', this, c) !== false) {
      this.doRemove(c, autoDestroy);
      this.fireEvent('remove', this, c);
    }

    return c;
  },
  onRemove: function onRemove(c) {// Empty template method
  },
  // private
  doRemove: function doRemove(c, autoDestroy) {
    var l = this.layout,
        hasLayout = l && this.rendered;

    if (hasLayout) {
      l.onRemove(c);
    }

    this.items.remove(c);
    c.onRemoved();
    this.onRemove(c);

    if (autoDestroy === true || autoDestroy !== false && this.autoDestroy) {
      c.destroy();
    }

    if (hasLayout) {
      l.afterRemove(c);
    }
  },

  /**
   * Removes all components from this container.
   * @param {Boolean} autoDestroy (optional) True to automatically invoke the removed Component's {@link Ext.Component#destroy} function.
   * Defaults to the value of this Container's {@link #autoDestroy} config.
   * @return {Array} Array of the destroyed components
   */
  removeAll: function removeAll(autoDestroy) {
    this.initItems();
    var item,
        rem = [],
        items = [];
    this.items.each(function (i) {
      rem.push(i);
    });

    for (var i = 0, len = rem.length; i < len; ++i) {
      item = rem[i];
      this.remove(item, autoDestroy);

      if (item.ownerCt !== this) {
        items.push(item);
      }
    }

    return items;
  },

  /**
   * Examines this container's <code>{@link #items}</code> <b>property</b>
   * and gets a direct child component of this container.
   * @param {String/Number} comp This parameter may be any of the following:
   * <div><ul class="mdetail-params">
   * <li>a <b><code>String</code></b> : representing the <code>{@link Ext.Component#itemId itemId}</code>
   * or <code>{@link Ext.Component#id id}</code> of the child component </li>
   * <li>a <b><code>Number</code></b> : representing the position of the child component
   * within the <code>{@link #items}</code> <b>property</b></li>
   * </ul></div>
   * <p>For additional information see {@link Ext.util.MixedCollection#get}.
   * @return Ext.Component The component (if found).
   */
  getComponent: function getComponent(comp) {
    if (Ext.isObject(comp)) {
      comp = comp.getItemId();
    }

    return this.items.get(comp);
  },
  // private
  lookupComponent: function lookupComponent(comp) {
    if (Ext.isString(comp)) {
      return Ext.ComponentMgr.get(comp);
    } else if (!comp.events) {
      return this.createComponent(comp);
    }

    return comp;
  },
  // private
  createComponent: function createComponent(config, defaultType) {
    // add in ownerCt at creation time but then immediately
    // remove so that onBeforeAdd can handle it
    var c = config.render ? config : Ext.create(Ext.apply({
      ownerCt: this
    }, config), defaultType || this.defaultType);
    delete c.ownerCt;
    return c;
  },

  /**
  * We can only lay out if there is a view area in which to layout.
  * display:none on the layout target, *or any of its parent elements* will mean it has no view area.
  */
  // private
  canLayout: function canLayout() {
    var el = this.getVisibilityEl();
    return el && el.dom && !el.isStyle("display", "none");
  },

  /**
   * Force this container's layout to be recalculated. A call to this function is required after adding a new component
   * to an already rendered container, or possibly after changing sizing/position properties of child components.
   * @param {Boolean} shallow (optional) True to only calc the layout of this component, and let child components auto
   * calc layouts as required (defaults to false, which calls doLayout recursively for each subcontainer)
   * @param {Boolean} force (optional) True to force a layout to occur, even if the item is hidden.
   * @return {Ext.Container} this
   */
  doLayout: function doLayout(shallow, force) {
    var rendered = this.rendered,
        forceLayout = force || this.forceLayout;

    if (this.collapsed || !this.canLayout()) {
      this.deferLayout = this.deferLayout || !shallow;

      if (!forceLayout) {
        return;
      }

      shallow = shallow && !this.deferLayout;
    } else {
      delete this.deferLayout;
    }

    if (rendered && this.layout) {
      this.layout.layout();
    }

    if (shallow !== true && this.items) {
      var cs = this.items.items;

      for (var i = 0, len = cs.length; i < len; i++) {
        var c = cs[i];

        if (c.doLayout) {
          c.doLayout(false, forceLayout);
        }
      }
    }

    if (rendered) {
      this.onLayout(shallow, forceLayout);
    } // Initial layout completed


    this.hasLayout = true;
    delete this.forceLayout;
  },
  onLayout: Ext.emptyFn,
  // private
  shouldBufferLayout: function shouldBufferLayout() {
    /*
     * Returns true if the container should buffer a layout.
     * This is true only if the container has previously been laid out
     * and has a parent container that is pending a layout.
     */
    var hl = this.hasLayout;

    if (this.ownerCt) {
      // Only ever buffer if we've laid out the first time and we have one pending.
      return hl ? !this.hasLayoutPending() : false;
    } // Never buffer initial layout


    return hl;
  },
  // private
  hasLayoutPending: function hasLayoutPending() {
    // Traverse hierarchy to see if any parent container has a pending layout.
    var pending = false;
    this.ownerCt.bubble(function (c) {
      if (c.layoutPending) {
        pending = true;
        return false;
      }
    });
    return pending;
  },
  onShow: function onShow() {
    // removes css classes that were added to hide
    Ext.Container.superclass.onShow.call(this); // If we were sized during the time we were hidden, layout.

    if (Ext.isDefined(this.deferLayout)) {
      delete this.deferLayout;
      this.doLayout(true);
    }
  },

  /**
   * Returns the layout currently in use by the container.  If the container does not currently have a layout
   * set, a default {@link Ext.layout.ContainerLayout} will be created and set as the container's layout.
   * @return {ContainerLayout} layout The container's layout
   */
  getLayout: function getLayout() {
    if (!this.layout) {
      var layout = new Ext.layout.ContainerLayout(this.layoutConfig);
      this.setLayout(layout);
    }

    return this.layout;
  },
  // private
  beforeDestroy: function beforeDestroy() {
    var c;

    if (this.items) {
      while (c = this.items.first()) {
        this.doRemove(c, true);
      }
    }

    if (this.monitorResize) {
      Ext.EventManager.removeResizeListener(this.doLayout, this);
    }

    Ext.destroy(this.layout);
    Ext.Container.superclass.beforeDestroy.call(this);
  },

  /**
   * Bubbles up the component/container heirarchy, calling the specified function with each component. The scope (<i>this</i>) of
   * function call will be the scope provided or the current component. The arguments to the function
   * will be the args provided or the current component. If the function returns false at any point,
   * the bubble is stopped.
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope of the function (defaults to current node)
   * @param {Array} args (optional) The args to call the function with (default to passing the current component)
   * @return {Ext.Container} this
   */
  bubble: function bubble(fn, scope, args) {
    var p = this;

    while (p) {
      if (fn.apply(scope || p, args || [p]) === false) {
        break;
      }

      p = p.ownerCt;
    }

    return this;
  },

  /**
   * Cascades down the component/container heirarchy from this component (called first), calling the specified function with
   * each component. The scope (<i>this</i>) of
   * function call will be the scope provided or the current component. The arguments to the function
   * will be the args provided or the current component. If the function returns false at any point,
   * the cascade is stopped on that branch.
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope of the function (defaults to current component)
   * @param {Array} args (optional) The args to call the function with (defaults to passing the current component)
   * @return {Ext.Container} this
   */
  cascade: function cascade(fn, scope, args) {
    if (fn.apply(scope || this, args || [this]) !== false) {
      if (this.items) {
        var cs = this.items.items;

        for (var i = 0, len = cs.length; i < len; i++) {
          if (cs[i].cascade) {
            cs[i].cascade(fn, scope, args);
          } else {
            fn.apply(scope || cs[i], args || [cs[i]]);
          }
        }
      }
    }

    return this;
  },

  /**
   * Find a component under this container at any level by id
   * @param {String} id
   * @return Ext.Component
   */
  findById: function findById(id) {
    var m,
        ct = this;
    this.cascade(function (c) {
      if (ct != c && c.id === id) {
        m = c;
        return false;
      }
    });
    return m || null;
  },

  /**
   * Find a component under this container at any level by xtype or class
   * @param {String/Class} xtype The xtype string for a component, or the class of the component directly
   * @param {Boolean} shallow (optional) False to check whether this Component is descended from the xtype (this is
   * the default), or true to check whether this Component is directly of the specified xtype.
   * @return {Array} Array of Ext.Components
   */
  findByType: function findByType(xtype, shallow) {
    return this.findBy(function (c) {
      return c.isXType(xtype, shallow);
    });
  },

  /**
   * Find a component under this container at any level by property
   * @param {String} prop
   * @param {String} value
   * @return {Array} Array of Ext.Components
   */
  find: function find(prop, value) {
    return this.findBy(function (c) {
      return c[prop] === value;
    });
  },

  /**
   * Find a component under this container at any level by a custom function. If the passed function returns
   * true, the component will be included in the results. The passed function is called with the arguments (component, this container).
   * @param {Function} fn The function to call
   * @param {Object} scope (optional)
   * @return {Array} Array of Ext.Components
   */
  findBy: function findBy(fn, scope) {
    var m = [],
        ct = this;
    this.cascade(function (c) {
      if (ct != c && fn.call(scope || c, c, ct) === true) {
        m.push(c);
      }
    });
    return m;
  },

  /**
   * Get a component contained by this container (alias for items.get(key))
   * @param {String/Number} key The index or id of the component
   * @return {Ext.Component} Ext.Component
   */
  get: function get(key) {
    return this.items.get(key);
  }
});
Ext.Container.LAYOUTS = {};
Ext.reg('container', Ext.Container);

/***/ }),
/* 758 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.ContainerLayout
 * <p>This class is intended to be extended or created via the <tt><b>{@link Ext.Container#layout layout}</b></tt>
 * configuration property.  See <tt><b>{@link Ext.Container#layout}</b></tt> for additional details.</p>
 */
Ext.layout.ContainerLayout = Ext.extend(Object, {
  /**
   * @cfg {String} extraCls
   * <p>An optional extra CSS class that will be added to the container. This can be useful for adding
   * customized styles to the container or any of its children using standard CSS rules. See
   * {@link Ext.Component}.{@link Ext.Component#ctCls ctCls} also.</p>
   * <p><b>Note</b>: <tt>extraCls</tt> defaults to <tt>''</tt> except for the following classes
   * which assign a value by default:
   * <div class="mdetail-params"><ul>
   * <li>{@link Ext.layout.AbsoluteLayout Absolute Layout} : <tt>'x-abs-layout-item'</tt></li>
   * <li>{@link Ext.layout.Box Box Layout} : <tt>'x-box-item'</tt></li>
   * <li>{@link Ext.layout.ColumnLayout Column Layout} : <tt>'x-column'</tt></li>
   * </ul></div>
   * To configure the above Classes with an extra CSS class append to the default.  For example,
   * for ColumnLayout:<pre><code>
   * extraCls: 'x-column custom-class'
   * </code></pre>
   * </p>
   */

  /**
   * @cfg {Boolean} renderHidden
   * True to hide each contained item on render (defaults to false).
   */

  /**
   * A reference to the {@link Ext.Component} that is active.  For example, <pre><code>
   * if(myPanel.layout.activeItem.id == 'item-1') { ... }
   * </code></pre>
   * <tt>activeItem</tt> only applies to layout styles that can display items one at a time
   * (like {@link Ext.layout.AccordionLayout}, {@link Ext.layout.CardLayout}
   * and {@link Ext.layout.FitLayout}).  Read-only.  Related to {@link Ext.Container#activeItem}.
   * @type {Ext.Component}
   * @property activeItem
   */
  // private
  monitorResize: false,
  // private
  activeItem: null,
  constructor: function constructor(config) {
    this.id = Ext.id(null, 'ext-layout-');
    Ext.apply(this, config);
  },
  type: 'container',

  /* Workaround for how IE measures autoWidth elements.  It prefers bottom-up measurements
    whereas other browser prefer top-down.  We will hide all target child elements before we measure and
    put them back to get an accurate measurement.
  */
  IEMeasureHack: function IEMeasureHack(target, viewFlag) {
    var tChildren = target.dom.childNodes,
        tLen = tChildren.length,
        c,
        d = [],
        e,
        i,
        ret;

    for (i = 0; i < tLen; i++) {
      c = tChildren[i];
      e = Ext.get(c);

      if (e) {
        d[i] = e.getStyle('display');
        e.setStyle({
          display: 'none'
        });
      }
    }

    ret = target ? target.getViewSize(viewFlag) : {};

    for (i = 0; i < tLen; i++) {
      c = tChildren[i];
      e = Ext.get(c);

      if (e) {
        e.setStyle({
          display: d[i]
        });
      }
    }

    return ret;
  },
  // Placeholder for the derived layouts
  getLayoutTargetSize: Ext.EmptyFn,
  // private
  layout: function layout() {
    var ct = this.container,
        target = ct.getLayoutTarget();

    if (!(this.hasLayout || Ext.isEmpty(this.targetCls))) {
      target.addClass(this.targetCls);
    }

    this.onLayout(ct, target);
    ct.fireEvent('afterlayout', ct, this);
  },
  // private
  onLayout: function onLayout(ct, target) {
    this.renderAll(ct, target);
  },
  // private
  isValidParent: function isValidParent(c, target) {
    return target && c.getPositionEl().dom.parentNode == (target.dom || target);
  },
  // private
  renderAll: function renderAll(ct, target) {
    var items = ct.items.items,
        i,
        c,
        len = items.length;

    for (i = 0; i < len; i++) {
      c = items[i];

      if (c && (!c.rendered || !this.isValidParent(c, target))) {
        this.renderItem(c, i, target);
      }
    }
  },
  // private
  renderItem: function renderItem(c, position, target) {
    if (c) {
      if (!c.rendered) {
        c.render(target, position);
        this.configureItem(c, position);
      } else if (!this.isValidParent(c, target)) {
        if (Ext.isNumber(position)) {
          position = target.dom.childNodes[position];
        }

        target.dom.insertBefore(c.getPositionEl().dom, position || null);
        c.container = target;
        this.configureItem(c, position);
      }
    }
  },
  // private.
  // Get all rendered items to lay out.
  getRenderedItems: function getRenderedItems(ct) {
    var t = ct.getLayoutTarget(),
        cti = ct.items.items,
        len = cti.length,
        i,
        c,
        items = [];

    for (i = 0; i < len; i++) {
      if ((c = cti[i]).rendered && this.isValidParent(c, t)) {
        items.push(c);
      }
    }

    ;
    return items;
  },
  // private
  configureItem: function configureItem(c, position) {
    if (this.extraCls) {
      var t = c.getPositionEl ? c.getPositionEl() : c;
      t.addClass(this.extraCls);
    } // If we are forcing a layout, do so *before* we hide so elements have height/width


    if (c.doLayout && this.forceLayout) {
      c.doLayout();
    }

    if (this.renderHidden && c != this.activeItem) {
      c.hide();
    }
  },
  onRemove: function onRemove(c) {
    if (this.activeItem == c) {
      delete this.activeItem;
    }

    if (c.rendered && this.extraCls) {
      var t = c.getPositionEl ? c.getPositionEl() : c;
      t.removeClass(this.extraCls);
    }
  },
  afterRemove: function afterRemove(c) {
    if (c.removeRestore) {
      c.removeMode = 'container';
      delete c.removeRestore;
    }
  },
  // private
  onResize: function onResize() {
    var ct = this.container,
        b;

    if (ct.collapsed) {
      return;
    }

    if (b = ct.bufferResize) {
      // Only allow if we should buffer the layout
      if (ct.shouldBufferLayout()) {
        if (!this.resizeTask) {
          this.resizeTask = new Ext.util.DelayedTask(this.runLayout, this);
          this.resizeBuffer = Ext.isNumber(b) ? b : 50;
        }

        ct.layoutPending = true;
        this.resizeTask.delay(this.resizeBuffer);
      }
    } else {
      this.runLayout();
    }
  },
  runLayout: function runLayout() {
    var ct = this.container; // AutoLayout is known to require the recursive doLayout call, others need this currently (BorderLayout for example)
    // but shouldn't.  A more extensive review will take place for 3.2 which requires a ContainerMgr with hierarchy lookups.
    //this.layout();
    //ct.onLayout();

    ct.doLayout();
    delete ct.layoutPending;
  },
  // private
  setContainer: function setContainer(ct) {
    if (!Ext.LayoutManager) {
      Ext.LayoutManager = {};
    }
    /* This monitorResize flag will be renamed soon as to avoid confusion
    * with the Container version which hooks onWindowResize to doLayout
    *
    * monitorResize flag in this context attaches the resize event between
    * a container and it's layout
    */


    if (this.monitorResize && ct != this.container) {
      var old = this.container;

      if (old) {
        old.un(old.resizeEvent, this.onResize, this);
      }

      if (ct) {
        ct.on(ct.resizeEvent, this.onResize, this);
      }
    }

    this.container = ct;
  },
  // private
  parseMargins: function parseMargins(v) {
    if (Ext.isNumber(v)) {
      v = v.toString();
    }

    var ms = v.split(' ');
    var len = ms.length;

    if (len == 1) {
      ms[1] = ms[2] = ms[3] = ms[0];
    } else if (len == 2) {
      ms[2] = ms[0];
      ms[3] = ms[1];
    } else if (len == 3) {
      ms[3] = ms[1];
    }

    return {
      top: parseInt(ms[0], 10) || 0,
      right: parseInt(ms[1], 10) || 0,
      bottom: parseInt(ms[2], 10) || 0,
      left: parseInt(ms[3], 10) || 0
    };
  },

  /**
   * The {@link Ext.Template Ext.Template} used by Field rendering layout classes (such as
   * {@link Ext.layout.FormLayout}) to create the DOM structure of a fully wrapped,
   * labeled and styled form Field. A default Template is supplied, but this may be
   * overriden to create custom field structures. The template processes values returned from
   * {@link Ext.layout.FormLayout#getTemplateArgs}.
   * @property fieldTpl
   * @type Ext.Template
   */
  fieldTpl: function () {
    var t = new Ext.Template('<div class="x-form-item {itemCls}" tabIndex="-1">', '<label for="{id}" style="{labelStyle}" class="x-form-item-label">{label}{labelSeparator}</label>', '<div class="x-form-element" id="x-form-el-{id}" style="{elementStyle}">', '</div><div class="{clearCls}"></div>', '</div>');
    t.disableFormats = true;
    return t.compile();
  }(),

  /*
   * Destroys this layout. This is a template method that is empty by default, but should be implemented
   * by subclasses that require explicit destruction to purge event handlers or remove DOM nodes.
   * @protected
   */
  destroy: function destroy() {
    if (!Ext.isEmpty(this.targetCls)) {
      var target = this.container.getLayoutTarget();

      if (target) {
        target.removeClass(this.targetCls);
      }
    }
  }
});

/***/ }),
/* 759 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.AutoLayout
 * <p>The AutoLayout is the default layout manager delegated by {@link Ext.Container} to
 * render any child Components when no <tt>{@link Ext.Container#layout layout}</tt> is configured into
 * a {@link Ext.Container Container}. ContainerLayout provides the basic foundation for all other layout
 * classes in Ext. It simply renders all child Components into the Container, performing no sizing or
 * positioning services. To utilize a layout that provides sizing and positioning of child Components,
 * specify an appropriate <tt>{@link Ext.Container#layout layout}</tt>.</p>
 */
Ext.layout.AutoLayout = Ext.extend(Ext.layout.ContainerLayout, {
  runLayout: function runLayout() {
    var ct = this.container;
    ct.doLayout();
    delete ct.layoutPending;
  }
});
Ext.Container.LAYOUTS['auto'] = Ext.layout.AutoLayout;

/***/ }),
/* 760 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.FitLayout
 * @extends Ext.layout.ContainerLayout
 * <p>This is a base class for layouts that contain <b>a single item</b> that automatically expands to fill the layout's
 * container.  This class is intended to be extended or created via the <tt>layout:'fit'</tt> {@link Ext.Container#layout}
 * config, and should generally not need to be created directly via the new keyword.</p>
 * <p>FitLayout does not have any direct config options (other than inherited ones).  To fit a panel to a container
 * using FitLayout, simply set layout:'fit' on the container and add a single panel to it.  If the container has
 * multiple panels, only the first one will be displayed.  Example usage:</p>
 * <pre><code>
var p = new Ext.Panel({
    title: 'Fit Layout',
    layout:'fit',
    items: {
        title: 'Inner Panel',
        html: '&lt;p&gt;This is the inner panel content&lt;/p&gt;',
        border: false
    }
});
</code></pre>
 */
Ext.layout.FitLayout = Ext.extend(Ext.layout.ContainerLayout, {
  // private
  monitorResize: true,
  type: 'fit',
  getLayoutTargetSize: function getLayoutTargetSize() {
    var target = this.container.getLayoutTarget();

    if (!target) {
      return {};
    } // Style Sized (scrollbars not included)


    return target.getStyleSize();
  },
  // private
  onLayout: function onLayout(ct, target) {
    Ext.layout.FitLayout.superclass.onLayout.call(this, ct, target);

    if (!ct.collapsed) {
      this.setItemSize(this.activeItem || ct.items.itemAt(0), this.getLayoutTargetSize());
    }
  },
  // private
  setItemSize: function setItemSize(item, size) {
    if (item && size.height > 0) {
      // display none?
      item.setSize(size);
    }
  }
});
Ext.Container.LAYOUTS['fit'] = Ext.layout.FitLayout;

/***/ }),
/* 761 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.CardLayout
 * @extends Ext.layout.FitLayout
 * <p>This layout manages multiple child Components, each fitted to the Container, where only a single child Component can be
 * visible at any given time.  This layout style is most commonly used for wizards, tab implementations, etc.
 * This class is intended to be extended or created via the layout:'card' {@link Ext.Container#layout} config,
 * and should generally not need to be created directly via the new keyword.</p>
 * <p>The CardLayout's focal method is {@link #setActiveItem}.  Since only one panel is displayed at a time,
 * the only way to move from one Component to the next is by calling setActiveItem, passing the id or index of
 * the next panel to display.  The layout itself does not provide a user interface for handling this navigation,
 * so that functionality must be provided by the developer.</p>
 * <p>In the following example, a simplistic wizard setup is demonstrated.  A button bar is added
 * to the footer of the containing panel to provide navigation buttons.  The buttons will be handled by a
 * common navigation routine -- for this example, the implementation of that routine has been ommitted since
 * it can be any type of custom logic.  Note that other uses of a CardLayout (like a tab control) would require a
 * completely different implementation.  For serious implementations, a better approach would be to extend
 * CardLayout to provide the custom functionality needed.  Example usage:</p>
 * <pre><code>
var navHandler = function(direction){
    // This routine could contain business logic required to manage the navigation steps.
    // It would call setActiveItem as needed, manage navigation button state, handle any
    // branching logic that might be required, handle alternate actions like cancellation
    // or finalization, etc.  A complete wizard implementation could get pretty
    // sophisticated depending on the complexity required, and should probably be
    // done as a subclass of CardLayout in a real-world implementation.
};

var card = new Ext.Panel({
    title: 'Example Wizard',
    layout:'card',
    activeItem: 0, // make sure the active item is set on the container config!
    bodyStyle: 'padding:15px',
    defaults: {
        // applied to each contained panel
        border:false
    },
    // just an example of one possible navigation scheme, using buttons
    bbar: [
        {
            id: 'move-prev',
            text: 'Back',
            handler: navHandler.createDelegate(this, [-1]),
            disabled: true
        },
        '->', // greedy spacer so that the buttons are aligned to each side
        {
            id: 'move-next',
            text: 'Next',
            handler: navHandler.createDelegate(this, [1])
        }
    ],
    // the panels (or "cards") within the layout
    items: [{
        id: 'card-0',
        html: '&lt;h1&gt;Welcome to the Wizard!&lt;/h1&gt;&lt;p&gt;Step 1 of 3&lt;/p&gt;'
    },{
        id: 'card-1',
        html: '&lt;p&gt;Step 2 of 3&lt;/p&gt;'
    },{
        id: 'card-2',
        html: '&lt;h1&gt;Congratulations!&lt;/h1&gt;&lt;p&gt;Step 3 of 3 - Complete&lt;/p&gt;'
    }]
});
</code></pre>
 */
Ext.layout.CardLayout = Ext.extend(Ext.layout.FitLayout, {
  /**
   * @cfg {Boolean} deferredRender
   * True to render each contained item at the time it becomes active, false to render all contained items
   * as soon as the layout is rendered (defaults to false).  If there is a significant amount of content or
   * a lot of heavy controls being rendered into panels that are not displayed by default, setting this to
   * true might improve performance.
   */
  deferredRender: false,

  /**
   * @cfg {Boolean} layoutOnCardChange
   * True to force a layout of the active item when the active card is changed. Defaults to false.
   */
  layoutOnCardChange: false,

  /**
   * @cfg {Boolean} renderHidden @hide
   */
  // private
  renderHidden: true,
  type: 'card',
  constructor: function constructor(config) {
    Ext.layout.CardLayout.superclass.constructor.call(this, config);
  },

  /**
   * Sets the active (visible) item in the layout.
   * @param {String/Number} item The string component id or numeric index of the item to activate
   */
  setActiveItem: function setActiveItem(item) {
    var ai = this.activeItem,
        ct = this.container;
    item = ct.getComponent(item); // Is this a valid, different card?

    if (item && ai != item) {
      // Changing cards, hide the current one
      if (ai) {
        ai.hide();

        if (ai.hidden !== true) {
          return false;
        }

        ai.fireEvent('deactivate', ai);
      } // Change activeItem reference


      this.activeItem = item; // The container is about to get a recursive layout, remove any deferLayout reference
      // because it will trigger a redundant layout.

      delete item.deferLayout; // Show the new component

      item.show();
      this.layout();

      if (item.doLayout) {
        item.doLayout();
      }

      item.fireEvent('activate', item);
    }
  },
  // private
  renderAll: function renderAll(ct, target) {
    if (this.deferredRender) {
      this.renderItem(this.activeItem, undefined, target);
      ct.items.each(c => {
        if (Ext.isFunction(c.setOwnerCt)) {
          c.setOwnerCt(ct);
        }
      });
    } else {
      Ext.layout.CardLayout.superclass.renderAll.call(this, ct, target);
    }
  }
});
Ext.Container.LAYOUTS['card'] = Ext.layout.CardLayout;

/***/ }),
/* 762 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.AnchorLayout
 * @extends Ext.layout.ContainerLayout
 * <p>This is a layout that enables anchoring of contained elements relative to the container's dimensions.
 * If the container is resized, all anchored items are automatically rerendered according to their
 * <b><tt>{@link #anchor}</tt></b> rules.</p>
 * <p>This class is intended to be extended or created via the layout:'anchor' {@link Ext.Container#layout}
 * config, and should generally not need to be created directly via the new keyword.</p>
 * <p>AnchorLayout does not have any direct config options (other than inherited ones). By default,
 * AnchorLayout will calculate anchor measurements based on the size of the container itself. However, the
 * container using the AnchorLayout can supply an anchoring-specific config property of <b>anchorSize</b>.
 * If anchorSize is specifed, the layout will use it as a virtual container for the purposes of calculating
 * anchor measurements based on it instead, allowing the container to be sized independently of the anchoring
 * logic if necessary.  For example:</p>
 * <pre><code>
var viewport = new Ext.Viewport({
    layout:'anchor',
    anchorSize: {width:800, height:600},
    items:[{
        title:'Item 1',
        html:'Content 1',
        width:800,
        anchor:'right 20%'
    },{
        title:'Item 2',
        html:'Content 2',
        width:300,
        anchor:'50% 30%'
    },{
        title:'Item 3',
        html:'Content 3',
        width:600,
        anchor:'-100 50%'
    }]
});
 * </code></pre>
 */
Ext.layout.AnchorLayout = Ext.extend(Ext.layout.ContainerLayout, {
  /**
   * @cfg {String} anchor
   * <p>This configuation option is to be applied to <b>child <tt>items</tt></b> of a container managed by
   * this layout (ie. configured with <tt>layout:'anchor'</tt>).</p><br/>
   *
   * <p>This value is what tells the layout how an item should be anchored to the container. <tt>items</tt>
   * added to an AnchorLayout accept an anchoring-specific config property of <b>anchor</b> which is a string
   * containing two values: the horizontal anchor value and the vertical anchor value (for example, '100% 50%').
   * The following types of anchor values are supported:<div class="mdetail-params"><ul>
   *
   * <li><b>Percentage</b> : Any value between 1 and 100, expressed as a percentage.<div class="sub-desc">
   * The first anchor is the percentage width that the item should take up within the container, and the
   * second is the percentage height.  For example:<pre><code>
  // two values specified
  anchor: '100% 50%' // render item complete width of the container and
                 // 1/2 height of the container
  // one value specified
  anchor: '100%'     // the width value; the height will default to auto
   * </code></pre></div></li>
   *
   * <li><b>Offsets</b> : Any positive or negative integer value.<div class="sub-desc">
   * This is a raw adjustment where the first anchor is the offset from the right edge of the container,
   * and the second is the offset from the bottom edge. For example:<pre><code>
  // two values specified
  anchor: '-50 -100' // render item the complete width of the container
                 // minus 50 pixels and
                 // the complete height minus 100 pixels.
  // one value specified
  anchor: '-50'      // anchor value is assumed to be the right offset value
                 // bottom offset will default to 0
   * </code></pre></div></li>
   *
   * <li><b>Sides</b> : Valid values are <tt>'right'</tt> (or <tt>'r'</tt>) and <tt>'bottom'</tt>
   * (or <tt>'b'</tt>).<div class="sub-desc">
   * Either the container must have a fixed size or an anchorSize config value defined at render time in
   * order for these to have any effect.</div></li>
   *
   * <li><b>Mixed</b> : <div class="sub-desc">
   * Anchor values can also be mixed as needed.  For example, to render the width offset from the container
   * right edge by 50 pixels and 75% of the container's height use:
   * <pre><code>
  anchor: '-50 75%'
   * </code></pre></div></li>
   *
   *
   * </ul></div>
   */
  // private
  monitorResize: true,
  type: 'anchor',
  getLayoutTargetSize: function getLayoutTargetSize() {
    var target = this.container.getLayoutTarget();

    if (!target) {
      return {};
    } // Style Sized (scrollbars not included)


    return target.getStyleSize();
  },
  // private
  onLayout: function onLayout(ct, target) {
    Ext.layout.AnchorLayout.superclass.onLayout.call(this, ct, target);
    var size = this.getLayoutTargetSize();
    var w = size.width,
        h = size.height;

    if (w < 20 && h < 20) {
      return;
    } // find the container anchoring size


    var aw, ah;

    if (ct.anchorSize) {
      if (typeof ct.anchorSize == 'number') {
        aw = ct.anchorSize;
      } else {
        aw = ct.anchorSize.width;
        ah = ct.anchorSize.height;
      }
    } else {
      aw = ct.initialConfig.width;
      ah = ct.initialConfig.height;
    }

    var cs = this.getRenderedItems(ct),
        len = cs.length,
        i,
        c,
        a,
        cw,
        ch,
        el,
        vs;

    for (i = 0; i < len; i++) {
      c = cs[i];
      el = c.getPositionEl();

      if (c.anchor) {
        a = c.anchorSpec;

        if (!a) {
          // cache all anchor values
          vs = c.anchor.split(' ');
          c.anchorSpec = a = {
            right: this.parseAnchor(vs[0], c.initialConfig.width, aw),
            bottom: this.parseAnchor(vs[1], c.initialConfig.height, ah)
          };
        }

        cw = a.right ? this.adjustWidthAnchor(a.right(w) - el.getMargins('lr'), c) : undefined;
        ch = a.bottom ? this.adjustHeightAnchor(a.bottom(h) - el.getMargins('tb'), c) : undefined;

        if (cw || ch) {
          c.setSize(cw || undefined, ch || undefined);
        }
      }
    }
  },
  // private
  parseAnchor: function parseAnchor(a, start, cstart) {
    if (a && a != 'none') {
      var last;

      if (/^(r|right|b|bottom)$/i.test(a)) {
        // standard anchor
        var diff = cstart - start;
        return function (v) {
          if (v !== last) {
            last = v;
            return v - diff;
          }
        };
      } else if (a.indexOf('%') != -1) {
        var ratio = parseFloat(a.replace('%', '')) * .01; // percentage

        return function (v) {
          if (v !== last) {
            last = v;
            return Math.floor(v * ratio);
          }
        };
      } else {
        a = parseInt(a, 10);

        if (!isNaN(a)) {
          // simple offset adjustment
          return function (v) {
            if (v !== last) {
              last = v;
              return v + a;
            }
          };
        }
      }
    }

    return false;
  },
  // private
  adjustWidthAnchor: function adjustWidthAnchor(value, comp) {
    return value;
  },
  // private
  adjustHeightAnchor: function adjustHeightAnchor(value, comp) {
    return value;
  }
  /**
   * @property activeItem
   * @hide
   */

});
Ext.Container.LAYOUTS['anchor'] = Ext.layout.AnchorLayout;

/***/ }),
/* 763 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.ColumnLayout
 * @extends Ext.layout.ContainerLayout
 * <p>This is the layout style of choice for creating structural layouts in a multi-column format where the width of
 * each column can be specified as a percentage or fixed width, but the height is allowed to vary based on the content.
 * This class is intended to be extended or created via the layout:'column' {@link Ext.Container#layout} config,
 * and should generally not need to be created directly via the new keyword.</p>
 * <p>ColumnLayout does not have any direct config options (other than inherited ones), but it does support a
 * specific config property of <b><tt>columnWidth</tt></b> that can be included in the config of any panel added to it.  The
 * layout will use the columnWidth (if present) or width of each panel during layout to determine how to size each panel.
 * If width or columnWidth is not specified for a given panel, its width will default to the panel's width (or auto).</p>
 * <p>The width property is always evaluated as pixels, and must be a number greater than or equal to 1.
 * The columnWidth property is always evaluated as a percentage, and must be a decimal value greater than 0 and
 * less than 1 (e.g., .25).</p>
 * <p>The basic rules for specifying column widths are pretty simple.  The logic makes two passes through the
 * set of contained panels.  During the first layout pass, all panels that either have a fixed width or none
 * specified (auto) are skipped, but their widths are subtracted from the overall container width.  During the second
 * pass, all panels with columnWidths are assigned pixel widths in proportion to their percentages based on
 * the total <b>remaining</b> container width.  In other words, percentage width panels are designed to fill the space
 * left over by all the fixed-width and/or auto-width panels.  Because of this, while you can specify any number of columns
 * with different percentages, the columnWidths must always add up to 1 (or 100%) when added together, otherwise your
 * layout may not render as expected.  Example usage:</p>
 * <pre><code>
// All columns are percentages -- they must add up to 1
var p = new Ext.Panel({
    title: 'Column Layout - Percentage Only',
    layout:'column',
    items: [{
        title: 'Column 1',
        columnWidth: .25
    },{
        title: 'Column 2',
        columnWidth: .6
    },{
        title: 'Column 3',
        columnWidth: .15
    }]
});

// Mix of width and columnWidth -- all columnWidth values must add up
// to 1. The first column will take up exactly 120px, and the last two
// columns will fill the remaining container width.
var p = new Ext.Panel({
    title: 'Column Layout - Mixed',
    layout:'column',
    items: [{
        title: 'Column 1',
        width: 120
    },{
        title: 'Column 2',
        columnWidth: .8
    },{
        title: 'Column 3',
        columnWidth: .2
    }]
});
</code></pre>
 */
Ext.layout.ColumnLayout = Ext.extend(Ext.layout.ContainerLayout, {
  // private
  monitorResize: true,
  type: 'column',
  extraCls: 'x-column',
  scrollOffset: 0,
  // private
  targetCls: 'x-column-layout-ct',
  isValidParent: function isValidParent(c, target) {
    return this.innerCt && c.getPositionEl().dom.parentNode == this.innerCt.dom;
  },
  getLayoutTargetSize: function getLayoutTargetSize() {
    var target = this.container.getLayoutTarget(),
        ret;

    if (target) {
      ret = target.getViewSize();
      ret.width -= target.getPadding('lr');
      ret.height -= target.getPadding('tb');
    }

    return ret;
  },
  renderAll: function renderAll(ct, target) {
    if (!this.innerCt) {
      // the innerCt prevents wrapping and shuffling while
      // the container is resizing
      this.innerCt = target.createChild({
        cls: 'x-column-inner'
      });
      this.innerCt.createChild({
        cls: 'x-clear'
      });
    }

    Ext.layout.ColumnLayout.superclass.renderAll.call(this, ct, this.innerCt);
  },
  // private
  onLayout: function onLayout(ct, target) {
    var cs = ct.items.items,
        len = cs.length,
        c,
        i;
    this.renderAll(ct, target);
    var size = this.getLayoutTargetSize();

    if (size.width < 1 && size.height < 1) {
      // display none?
      return;
    }

    var w = size.width - this.scrollOffset,
        h = size.height,
        pw = w;
    this.innerCt.setWidth(w); // some columns can be percentages while others are fixed
    // so we need to make 2 passes

    for (i = 0; i < len; i++) {
      c = cs[i];

      if (!c.columnWidth) {
        pw -= c.getWidth() + c.getPositionEl().getMargins('lr');
      }
    }

    pw = pw < 0 ? 0 : pw;

    for (i = 0; i < len; i++) {
      c = cs[i];

      if (c.columnWidth) {
        c.setSize(Math.floor(c.columnWidth * pw) - c.getPositionEl().getMargins('lr'));
      }
    } // Browsers differ as to when they account for scrollbars.  We need to re-measure to see if the scrollbar
    // spaces were accounted for properly.  If not, re-layout.


    if (Ext.isIE) {
      if (i = target.getStyle('overflow') && i != 'hidden' && !this.adjustmentPass) {
        var ts = this.getLayoutTargetSize();

        if (ts.width != size.width) {
          this.adjustmentPass = true;
          this.onLayout(ct, target);
        }
      }
    }

    delete this.adjustmentPass;
  }
  /**
   * @property activeItem
   * @hide
   */

});
Ext.Container.LAYOUTS['column'] = Ext.layout.ColumnLayout;

/***/ }),
/* 764 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.BorderLayout
 * @extends Ext.layout.ContainerLayout
 * <p>This is a multi-pane, application-oriented UI layout style that supports multiple
 * nested panels, automatic {@link Ext.layout.BorderLayout.Region#split split} bars between
 * {@link Ext.layout.BorderLayout.Region#BorderLayout.Region regions} and built-in
 * {@link Ext.layout.BorderLayout.Region#collapsible expanding and collapsing} of regions.</p>
 * <p>This class is intended to be extended or created via the <tt>layout:'border'</tt>
 * {@link Ext.Container#layout} config, and should generally not need to be created directly
 * via the new keyword.</p>
 * <p>BorderLayout does not have any direct config options (other than inherited ones).
 * All configuration options available for customizing the BorderLayout are at the
 * {@link Ext.layout.BorderLayout.Region} and {@link Ext.layout.BorderLayout.SplitRegion}
 * levels.</p>
 * <p>Example usage:</p>
 * <pre><code>
var myBorderPanel = new Ext.Panel({
    {@link Ext.Component#renderTo renderTo}: document.body,
    {@link Ext.BoxComponent#width width}: 700,
    {@link Ext.BoxComponent#height height}: 500,
    {@link Ext.Panel#title title}: 'Border Layout',
    {@link Ext.Container#layout layout}: 'border',
    {@link Ext.Container#items items}: [{
        {@link Ext.Panel#title title}: 'South Region is resizable',
        {@link Ext.layout.BorderLayout.Region#BorderLayout.Region region}: 'south',     // position for region
        {@link Ext.BoxComponent#height height}: 100,
        {@link Ext.layout.BorderLayout.Region#split split}: true,         // enable resizing
        {@link Ext.SplitBar#minSize minSize}: 75,         // defaults to {@link Ext.layout.BorderLayout.Region#minHeight 50}
        {@link Ext.SplitBar#maxSize maxSize}: 150,
        {@link Ext.layout.BorderLayout.Region#margins margins}: '0 5 5 5'
    },{
        // xtype: 'panel' implied by default
        {@link Ext.Panel#title title}: 'West Region is collapsible',
        {@link Ext.layout.BorderLayout.Region#BorderLayout.Region region}:'west',
        {@link Ext.layout.BorderLayout.Region#margins margins}: '5 0 0 5',
        {@link Ext.BoxComponent#width width}: 200,
        {@link Ext.layout.BorderLayout.Region#collapsible collapsible}: true,   // make collapsible
        {@link Ext.layout.BorderLayout.Region#cmargins cmargins}: '5 5 0 5', // adjust top margin when collapsed
        {@link Ext.Component#id id}: 'west-region-container',
        {@link Ext.Container#layout layout}: 'fit',
        {@link Ext.Panel#unstyled unstyled}: true
    },{
        {@link Ext.Panel#title title}: 'Center Region',
        {@link Ext.layout.BorderLayout.Region#BorderLayout.Region region}: 'center',     // center region is required, no width/height specified
        {@link Ext.Component#xtype xtype}: 'container',
        {@link Ext.Container#layout layout}: 'fit',
        {@link Ext.layout.BorderLayout.Region#margins margins}: '5 5 0 0'
    }]
});
</code></pre>
 * <p><b><u>Notes</u></b>:</p><div class="mdetail-params"><ul>
 * <li>Any container using the BorderLayout <b>must</b> have a child item with <tt>region:'center'</tt>.
 * The child item in the center region will always be resized to fill the remaining space not used by
 * the other regions in the layout.</li>
 * <li>Any child items with a region of <tt>west</tt> or <tt>east</tt> must have <tt>width</tt> defined
 * (an integer representing the number of pixels that the region should take up).</li>
 * <li>Any child items with a region of <tt>north</tt> or <tt>south</tt> must have <tt>height</tt> defined.</li>
 * <li>The regions of a BorderLayout are <b>fixed at render time</b> and thereafter, its child Components may not be removed or added</b>.  To add/remove
 * Components within a BorderLayout, have them wrapped by an additional Container which is directly
 * managed by the BorderLayout.  If the region is to be collapsible, the Container used directly
 * by the BorderLayout manager should be a Panel.  In the following example a Container (an Ext.Panel)
 * is added to the west region:
 * <div style="margin-left:16px"><pre><code>
wrc = {@link Ext#getCmp Ext.getCmp}('west-region-container');
wrc.{@link Ext.Panel#removeAll removeAll}();
wrc.{@link Ext.Container#add add}({
    title: 'Added Panel',
    html: 'Some content'
});
wrc.{@link Ext.Container#doLayout doLayout}();
 * </code></pre></div>
 * </li>
 * <li> To reference a {@link Ext.layout.BorderLayout.Region Region}:
 * <div style="margin-left:16px"><pre><code>
wr = myBorderPanel.layout.west;
 * </code></pre></div>
 * </li>
 * </ul></div>
 */
Ext.layout.BorderLayout = Ext.extend(Ext.layout.ContainerLayout, {
  // private
  monitorResize: true,
  // private
  rendered: false,
  type: 'border',
  targetCls: 'x-border-layout-ct',
  getLayoutTargetSize: function getLayoutTargetSize() {
    var target = this.container.getLayoutTarget();
    return target ? target.getViewSize() : {};
  },
  // private
  onLayout: function onLayout(ct, target) {
    var collapsed,
        i,
        c,
        pos,
        items = ct.items.items,
        len = items.length;

    if (!this.rendered) {
      collapsed = [];

      for (i = 0; i < len; i++) {
        c = items[i];
        pos = c.region;

        if (c.collapsed) {
          collapsed.push(c);
        }

        c.collapsed = false;

        if (!c.rendered) {
          c.render(target, i);
          c.getPositionEl().addClass('x-border-panel');
        }

        this[pos] = pos != 'center' && c.split ? new Ext.layout.BorderLayout.SplitRegion(this, c.initialConfig, pos) : new Ext.layout.BorderLayout.Region(this, c.initialConfig, pos);
        this[pos].render(target, c);
      }

      this.rendered = true;
    }

    var size = this.getLayoutTargetSize();

    if (size.width < 20 || size.height < 20) {
      // display none?
      if (collapsed) {
        this.restoreCollapsed = collapsed;
      }

      return;
    } else if (this.restoreCollapsed) {
      collapsed = this.restoreCollapsed;
      delete this.restoreCollapsed;
    }

    var w = size.width,
        h = size.height,
        centerW = w,
        centerH = h,
        centerY = 0,
        centerX = 0,
        n = this.north,
        s = this.south,
        west = this.west,
        e = this.east,
        c = this.center,
        b,
        m,
        totalWidth,
        totalHeight;

    if (!c && Ext.layout.BorderLayout.WARN !== false) {
      throw 'No center region defined in BorderLayout ' + ct.id;
    }

    if (n && n.isVisible()) {
      b = n.getSize();
      m = n.getMargins();
      b.width = w - (m.left + m.right);
      b.x = m.left;
      b.y = m.top;
      centerY = b.height + b.y + m.bottom;
      centerH -= centerY;
      n.applyLayout(b);
    }

    if (s && s.isVisible()) {
      b = s.getSize();
      m = s.getMargins();
      b.width = w - (m.left + m.right);
      b.x = m.left;
      totalHeight = b.height + m.top + m.bottom;
      b.y = h - totalHeight + m.top;
      centerH -= totalHeight;
      s.applyLayout(b);
    }

    if (west && west.isVisible()) {
      b = west.getSize();
      m = west.getMargins();
      b.height = centerH - (m.top + m.bottom);
      b.x = m.left;
      b.y = centerY + m.top;
      totalWidth = b.width + m.left + m.right;
      centerX += totalWidth;
      centerW -= totalWidth;
      west.applyLayout(b);
    }

    if (e && e.isVisible()) {
      b = e.getSize();
      m = e.getMargins();
      b.height = centerH - (m.top + m.bottom);
      totalWidth = b.width + m.left + m.right;
      b.x = w - totalWidth + m.left;
      b.y = centerY + m.top;
      centerW -= totalWidth;
      e.applyLayout(b);
    }

    if (c) {
      m = c.getMargins();
      var centerBox = {
        x: centerX + m.left,
        y: centerY + m.top,
        width: centerW - (m.left + m.right),
        height: centerH - (m.top + m.bottom)
      };
      c.applyLayout(centerBox);
    }

    if (collapsed) {
      for (i = 0, len = collapsed.length; i < len; i++) {
        collapsed[i].collapse(false);
      }
    }

    if (Ext.isIE && Ext.isStrict) {
      // workaround IE strict repainting issue
      target.repaint();
    } // Putting a border layout into an overflowed container is NOT correct and will make a second layout pass necessary.


    if (i = target.getStyle('overflow') && i != 'hidden' && !this.adjustmentPass) {
      var ts = this.getLayoutTargetSize();

      if (ts.width != size.width || ts.height != size.height) {
        this.adjustmentPass = true;
        this.onLayout(ct, target);
      }
    }

    delete this.adjustmentPass;
  },
  destroy: function destroy() {
    var r = ['north', 'south', 'east', 'west'],
        i,
        region;

    for (i = 0; i < r.length; i++) {
      region = this[r[i]];

      if (region) {
        if (region.destroy) {
          region.destroy();
        } else if (region.split) {
          region.split.destroy(true);
        }
      }
    }

    Ext.layout.BorderLayout.superclass.destroy.call(this);
  }
  /**
   * @property activeItem
   * @hide
   */

});
/**
 * @class Ext.layout.BorderLayout.Region
 * <p>This is a region of a {@link Ext.layout.BorderLayout BorderLayout} that acts as a subcontainer
 * within the layout.  Each region has its own {@link Ext.layout.ContainerLayout layout} that is
 * independent of other regions and the containing BorderLayout, and can be any of the
 * {@link Ext.layout.ContainerLayout valid Ext layout types}.</p>
 * <p>Region size is managed automatically and cannot be changed by the user -- for
 * {@link #split resizable regions}, see {@link Ext.layout.BorderLayout.SplitRegion}.</p>
 * @constructor
 * Create a new Region.
 * @param {Layout} layout The {@link Ext.layout.BorderLayout BorderLayout} instance that is managing this Region.
 * @param {Object} config The configuration options
 * @param {String} position The region position.  Valid values are: <tt>north</tt>, <tt>south</tt>,
 * <tt>east</tt>, <tt>west</tt> and <tt>center</tt>.  Every {@link Ext.layout.BorderLayout BorderLayout}
 * <b>must have a center region</b> for the primary content -- all other regions are optional.
 */

Ext.layout.BorderLayout.Region = function (layout, config, pos) {
  Ext.apply(this, config);
  this.layout = layout;
  this.position = pos;
  this.state = {};

  if (typeof this.margins == 'string') {
    this.margins = this.layout.parseMargins(this.margins);
  }

  this.margins = Ext.applyIf(this.margins || {}, this.defaultMargins);

  if (this.collapsible) {
    if (typeof this.cmargins == 'string') {
      this.cmargins = this.layout.parseMargins(this.cmargins);
    }

    if (this.collapseMode == 'mini' && !this.cmargins) {
      this.cmargins = {
        left: 0,
        top: 0,
        right: 0,
        bottom: 0
      };
    } else {
      this.cmargins = Ext.applyIf(this.cmargins || {}, pos == 'north' || pos == 'south' ? this.defaultNSCMargins : this.defaultEWCMargins);
    }
  }
};

Ext.layout.BorderLayout.Region.prototype = {
  /**
   * @cfg {Boolean} animFloat
   * When a collapsed region's bar is clicked, the region's panel will be displayed as a floated
   * panel that will close again once the user mouses out of that panel (or clicks out if
   * <tt>{@link #autoHide} = false</tt>).  Setting <tt>{@link #animFloat} = false</tt> will
   * prevent the open and close of these floated panels from being animated (defaults to <tt>true</tt>).
   */

  /**
   * @cfg {Boolean} autoHide
   * When a collapsed region's bar is clicked, the region's panel will be displayed as a floated
   * panel.  If <tt>autoHide = true</tt>, the panel will automatically hide after the user mouses
   * out of the panel.  If <tt>autoHide = false</tt>, the panel will continue to display until the
   * user clicks outside of the panel (defaults to <tt>true</tt>).
   */

  /**
   * @cfg {String} collapseMode
   * <tt>collapseMode</tt> supports two configuration values:<div class="mdetail-params"><ul>
   * <li><b><tt>undefined</tt></b> (default)<div class="sub-desc">By default, {@link #collapsible}
   * regions are collapsed by clicking the expand/collapse tool button that renders into the region's
   * title bar.</div></li>
   * <li><b><tt>'mini'</tt></b><div class="sub-desc">Optionally, when <tt>collapseMode</tt> is set to
   * <tt>'mini'</tt> the region's split bar will also display a small collapse button in the center of
   * the bar. In <tt>'mini'</tt> mode the region will collapse to a thinner bar than in normal mode.
   * </div></li>
   * </ul></div></p>
   * <p><b>Note</b>: if a collapsible region does not have a title bar, then set <tt>collapseMode =
   * 'mini'</tt> and <tt>{@link #split} = true</tt> in order for the region to be {@link #collapsible}
   * by the user as the expand/collapse tool button (that would go in the title bar) will not be rendered.</p>
   * <p>See also <tt>{@link #cmargins}</tt>.</p>
   */

  /**
   * @cfg {Object} margins
   * An object containing margins to apply to the region when in the expanded state in the
   * format:<pre><code>
  {
  top: (top margin),
  right: (right margin),
  bottom: (bottom margin),
  left: (left margin)
  }</code></pre>
   * <p>May also be a string containing space-separated, numeric margin values. The order of the
   * sides associated with each value matches the way CSS processes margin values:</p>
   * <p><div class="mdetail-params"><ul>
   * <li>If there is only one value, it applies to all sides.</li>
   * <li>If there are two values, the top and bottom borders are set to the first value and the
   * right and left are set to the second.</li>
   * <li>If there are three values, the top is set to the first value, the left and right are set
   * to the second, and the bottom is set to the third.</li>
   * <li>If there are four values, they apply to the top, right, bottom, and left, respectively.</li>
   * </ul></div></p>
   * <p>Defaults to:</p><pre><code>
   * {top:0, right:0, bottom:0, left:0}
   * </code></pre>
   */

  /**
   * @cfg {Object} cmargins
   * An object containing margins to apply to the region when in the collapsed state in the
   * format:<pre><code>
  {
  top: (top margin),
  right: (right margin),
  bottom: (bottom margin),
  left: (left margin)
  }</code></pre>
   * <p>May also be a string containing space-separated, numeric margin values. The order of the
   * sides associated with each value matches the way CSS processes margin values.</p>
   * <p><ul>
   * <li>If there is only one value, it applies to all sides.</li>
   * <li>If there are two values, the top and bottom borders are set to the first value and the
   * right and left are set to the second.</li>
   * <li>If there are three values, the top is set to the first value, the left and right are set
   * to the second, and the bottom is set to the third.</li>
   * <li>If there are four values, they apply to the top, right, bottom, and left, respectively.</li>
   * </ul></p>
   */

  /**
   * @cfg {Boolean} collapsible
   * <p><tt>true</tt> to allow the user to collapse this region (defaults to <tt>false</tt>).  If
   * <tt>true</tt>, an expand/collapse tool button will automatically be rendered into the title
   * bar of the region, otherwise the button will not be shown.</p>
   * <p><b>Note</b>: that a title bar is required to display the collapse/expand toggle button -- if
   * no <tt>title</tt> is specified for the region's panel, the region will only be collapsible if
   * <tt>{@link #collapseMode} = 'mini'</tt> and <tt>{@link #split} = true</tt>.
   */
  collapsible: false,

  /**
   * @cfg {Boolean} split
   * <p><tt>true</tt> to create a {@link Ext.layout.BorderLayout.SplitRegion SplitRegion} and
   * display a 5px wide {@link Ext.SplitBar} between this region and its neighbor, allowing the user to
   * resize the regions dynamically.  Defaults to <tt>false</tt> creating a
   * {@link Ext.layout.BorderLayout.Region Region}.</p><br>
   * <p><b>Notes</b>:</p><div class="mdetail-params"><ul>
   * <li>this configuration option is ignored if <tt>region='center'</tt></li>
   * <li>when <tt>split == true</tt>, it is common to specify a
   * <tt>{@link Ext.SplitBar#minSize minSize}</tt> and <tt>{@link Ext.SplitBar#maxSize maxSize}</tt>
   * for the {@link Ext.BoxComponent BoxComponent} representing the region. These are not native
   * configs of {@link Ext.BoxComponent BoxComponent}, and are used only by this class.</li>
   * <li>if <tt>{@link #collapseMode} = 'mini'</tt> requires <tt>split = true</tt> to reserve space
   * for the collapse tool</tt></li>
   * </ul></div>
   */
  split: false,

  /**
   * @cfg {Boolean} floatable
   * <tt>true</tt> to allow clicking a collapsed region's bar to display the region's panel floated
   * above the layout, <tt>false</tt> to force the user to fully expand a collapsed region by
   * clicking the expand button to see it again (defaults to <tt>true</tt>).
   */
  floatable: true,

  /**
   * @cfg {Number} minWidth
   * <p>The minimum allowable width in pixels for this region (defaults to <tt>50</tt>).
   * <tt>maxWidth</tt> may also be specified.</p><br>
   * <p><b>Note</b>: setting the <tt>{@link Ext.SplitBar#minSize minSize}</tt> /
   * <tt>{@link Ext.SplitBar#maxSize maxSize}</tt> supersedes any specified
   * <tt>minWidth</tt> / <tt>maxWidth</tt>.</p>
   */
  minWidth: 50,

  /**
   * @cfg {Number} minHeight
   * The minimum allowable height in pixels for this region (defaults to <tt>50</tt>)
   * <tt>maxHeight</tt> may also be specified.</p><br>
   * <p><b>Note</b>: setting the <tt>{@link Ext.SplitBar#minSize minSize}</tt> /
   * <tt>{@link Ext.SplitBar#maxSize maxSize}</tt> supersedes any specified
   * <tt>minHeight</tt> / <tt>maxHeight</tt>.</p>
   */
  minHeight: 50,
  // private
  defaultMargins: {
    left: 0,
    top: 0,
    right: 0,
    bottom: 0
  },
  // private
  defaultNSCMargins: {
    left: 5,
    top: 5,
    right: 5,
    bottom: 5
  },
  // private
  defaultEWCMargins: {
    left: 5,
    top: 0,
    right: 5,
    bottom: 0
  },
  floatingZIndex: 100,

  /**
   * True if this region is collapsed. Read-only.
   * @type Boolean
   * @property
   */
  isCollapsed: false,

  /**
   * This region's panel.  Read-only.
   * @type Ext.Panel
   * @property panel
   */

  /**
   * This region's layout.  Read-only.
   * @type Layout
   * @property layout
   */

  /**
   * This region's layout position (north, south, east, west or center).  Read-only.
   * @type String
   * @property position
   */
  // private
  render: function render(ct, p) {
    this.panel = p;
    p.el.enableDisplayMode();
    this.targetEl = ct;
    this.el = p.el;
    var gs = p.getState,
        ps = this.position;

    p.getState = function () {
      return Ext.apply(gs.call(p) || {}, this.state);
    }.createDelegate(this);

    if (ps != 'center') {
      p.allowQueuedExpand = false;
      p.on({
        beforecollapse: this.beforeCollapse,
        collapse: this.onCollapse,
        beforeexpand: this.beforeExpand,
        expand: this.onExpand,
        hide: this.onHide,
        show: this.onShow,
        scope: this
      });

      if (this.collapsible || this.floatable) {
        p.collapseEl = 'el';
        p.slideAnchor = this.getSlideAnchor();
      }

      if (p.tools && p.tools.toggle) {
        p.tools.toggle.addClass('x-tool-collapse-' + ps);
        p.tools.toggle.addClassOnOver('x-tool-collapse-' + ps + '-over');
      }
    }
  },
  // private
  getCollapsedEl: function getCollapsedEl() {
    if (!this.collapsedEl) {
      if (!this.toolTemplate) {
        var tt = new Ext.Template('<div class="x-tool x-tool-{id}">&#160;</div>');
        tt.disableFormats = true;
        tt.compile();
        Ext.layout.BorderLayout.Region.prototype.toolTemplate = tt;
      }

      this.collapsedEl = this.targetEl.createChild({
        cls: "x-layout-collapsed x-layout-collapsed-" + this.position,
        id: this.panel.id + '-xcollapsed'
      });
      this.collapsedEl.enableDisplayMode('block');

      if (this.collapseMode == 'mini') {
        this.collapsedEl.addClass('x-layout-cmini-' + this.position);
        this.miniCollapsedEl = this.collapsedEl.createChild({
          cls: "x-layout-mini x-layout-mini-" + this.position,
          html: "&#160;"
        });
        this.miniCollapsedEl.addClassOnOver('x-layout-mini-over');
        this.collapsedEl.addClassOnOver("x-layout-collapsed-over");
        this.collapsedEl.on('click', this.onExpandClick, this, {
          stopEvent: true
        });
      } else {
        if (this.collapsible !== false && !this.hideCollapseTool) {
          var t = this.toolTemplate.append(this.collapsedEl.dom, {
            id: 'expand-' + this.position
          }, true);
          t.addClassOnOver('x-tool-expand-' + this.position + '-over');
          t.on('click', this.onExpandClick, this, {
            stopEvent: true
          });
        }

        if (this.floatable !== false || this.titleCollapse) {
          this.collapsedEl.addClassOnOver("x-layout-collapsed-over");
          this.collapsedEl.on("click", this[this.floatable ? 'collapseClick' : 'onExpandClick'], this);
        }
      }
    }

    return this.collapsedEl;
  },
  // private
  onExpandClick: function onExpandClick(e) {
    if (this.isSlid) {
      this.panel.expand(false);
    } else {
      this.panel.expand();
    }
  },
  // private
  onCollapseClick: function onCollapseClick(e) {
    this.panel.collapse();
  },
  // private
  beforeCollapse: function beforeCollapse(p, animate) {
    this.lastAnim = animate;

    if (this.splitEl) {
      this.splitEl.hide();
    }

    this.getCollapsedEl().show();
    var el = this.panel.getEl();
    this.originalZIndex = el.getStyle('z-index');
    el.setStyle('z-index', 100);
    this.isCollapsed = true;
    this.layout.layout();
  },
  // private
  onCollapse: function onCollapse(animate) {
    this.panel.el.setStyle('z-index', 1);

    if (this.lastAnim === false || this.panel.animCollapse === false) {
      this.getCollapsedEl().dom.style.visibility = 'visible';
    } else {
      this.getCollapsedEl().slideIn(this.panel.slideAnchor, {
        duration: .2
      });
    }

    this.state.collapsed = true;
    this.panel.saveState();
  },
  // private
  beforeExpand: function beforeExpand(animate) {
    if (this.isSlid) {
      this.afterSlideIn();
    }

    var c = this.getCollapsedEl();
    this.el.show();

    if (this.position == 'east' || this.position == 'west') {
      this.panel.setSize(undefined, c.getHeight());
    } else {
      this.panel.setSize(c.getWidth(), undefined);
    }

    c.hide();
    c.dom.style.visibility = 'hidden';
    this.panel.el.setStyle('z-index', this.floatingZIndex);
  },
  // private
  onExpand: function onExpand() {
    this.isCollapsed = false;

    if (this.splitEl) {
      this.splitEl.show();
    }

    this.layout.layout();
    this.panel.el.setStyle('z-index', this.originalZIndex);
    this.state.collapsed = false;
    this.panel.saveState();
  },
  // private
  collapseClick: function collapseClick(e) {
    if (this.isSlid) {
      e.stopPropagation();
      this.slideIn();
    } else {
      e.stopPropagation();
      this.slideOut();
    }
  },
  // private
  onHide: function onHide() {
    if (this.isCollapsed) {
      this.getCollapsedEl().hide();
    } else if (this.splitEl) {
      this.splitEl.hide();
    }
  },
  // private
  onShow: function onShow() {
    if (this.isCollapsed) {
      this.getCollapsedEl().show();
    } else if (this.splitEl) {
      this.splitEl.show();
    }
  },

  /**
   * True if this region is currently visible, else false.
   * @return {Boolean}
   */
  isVisible: function isVisible() {
    return !this.panel.hidden;
  },

  /**
   * Returns the current margins for this region.  If the region is collapsed, the
   * {@link #cmargins} (collapsed margins) value will be returned, otherwise the
   * {@link #margins} value will be returned.
   * @return {Object} An object containing the element's margins: <tt>{left: (left
   * margin), top: (top margin), right: (right margin), bottom: (bottom margin)}</tt>
   */
  getMargins: function getMargins() {
    return this.isCollapsed && this.cmargins ? this.cmargins : this.margins;
  },

  /**
   * Returns the current size of this region.  If the region is collapsed, the size of the
   * collapsedEl will be returned, otherwise the size of the region's panel will be returned.
   * @return {Object} An object containing the element's size: <tt>{width: (element width),
   * height: (element height)}</tt>
   */
  getSize: function getSize() {
    return this.isCollapsed ? this.getCollapsedEl().getSize() : this.panel.getSize();
  },

  /**
   * Sets the specified panel as the container element for this region.
   * @param {Ext.Panel} panel The new panel
   */
  setPanel: function setPanel(panel) {
    this.panel = panel;
  },

  /**
   * Returns the minimum allowable width for this region.
   * @return {Number} The minimum width
   */
  getMinWidth: function getMinWidth() {
    return this.minWidth;
  },

  /**
   * Returns the minimum allowable height for this region.
   * @return {Number} The minimum height
   */
  getMinHeight: function getMinHeight() {
    return this.minHeight;
  },
  // private
  applyLayoutCollapsed: function applyLayoutCollapsed(box) {
    var ce = this.getCollapsedEl();
    ce.setLeftTop(box.x, box.y);
    ce.setSize(box.width, box.height);
  },
  // private
  applyLayout: function applyLayout(box) {
    if (this.isCollapsed) {
      this.applyLayoutCollapsed(box);
    } else {
      this.panel.setPosition(box.x, box.y);
      this.panel.setSize(box.width, box.height);
    }
  },
  // private
  beforeSlide: function beforeSlide() {
    this.panel.beforeEffect();
  },
  // private
  afterSlide: function afterSlide() {
    this.panel.afterEffect();
  },
  // private
  initAutoHide: function initAutoHide() {
    if (this.autoHide !== false) {
      if (!this.autoHideHd) {
        var st = new Ext.util.DelayedTask(this.slideIn, this);
        this.autoHideHd = {
          "mouseout": function mouseout(e) {
            if (!e.within(this.el, true)) {
              st.delay(500);
            }
          },
          "mouseover": function mouseover(e) {
            st.cancel();
          },
          scope: this
        };
      }

      this.el.on(this.autoHideHd);
      this.collapsedEl.on(this.autoHideHd);
    }
  },
  // private
  clearAutoHide: function clearAutoHide() {
    if (this.autoHide !== false) {
      this.el.un("mouseout", this.autoHideHd.mouseout);
      this.el.un("mouseover", this.autoHideHd.mouseover);
      this.collapsedEl.un("mouseout", this.autoHideHd.mouseout);
      this.collapsedEl.un("mouseover", this.autoHideHd.mouseover);
    }
  },
  // private
  clearMonitor: function clearMonitor() {
    Ext.getDoc().un("click", this.slideInIf, this);
  },

  /**
   * If this Region is {@link #floatable}, this method slides this Region into full visibility <i>over the top
   * of the center Region</i> where it floats until either {@link #slideIn} is called, or other regions of the layout
   * are clicked, or the mouse exits the Region.
   */
  slideOut: function slideOut() {
    if (this.isSlid || this.el.hasActiveFx()) {
      return;
    }

    this.isSlid = true;
    var ts = this.panel.tools,
        dh,
        pc;

    if (ts && ts.toggle) {
      ts.toggle.hide();
    }

    this.el.show(); // Temporarily clear the collapsed flag so we can onResize the panel on the slide

    pc = this.panel.collapsed;
    this.panel.collapsed = false;

    if (this.position == 'east' || this.position == 'west') {
      // Temporarily clear the deferHeight flag so we can size the height on the slide
      dh = this.panel.deferHeight;
      this.panel.deferHeight = false;
      this.panel.setSize(undefined, this.collapsedEl.getHeight()); // Put the deferHeight flag back after setSize

      this.panel.deferHeight = dh;
    } else {
      this.panel.setSize(this.collapsedEl.getWidth(), undefined);
    } // Put the collapsed flag back after onResize


    this.panel.collapsed = pc;
    this.restoreLT = [this.el.dom.style.left, this.el.dom.style.top];
    this.el.alignTo(this.collapsedEl, this.getCollapseAnchor());
    this.el.setStyle("z-index", this.floatingZIndex + 2);
    this.panel.el.replaceClass('x-panel-collapsed', 'x-panel-floating');

    if (this.animFloat !== false) {
      this.beforeSlide();
      this.el.slideIn(this.getSlideAnchor(), {
        callback: function callback() {
          this.afterSlide();
          this.initAutoHide();
          Ext.getDoc().on("click", this.slideInIf, this);
        },
        scope: this,
        block: true
      });
    } else {
      this.initAutoHide();
      Ext.getDoc().on("click", this.slideInIf, this);
    }
  },
  // private
  afterSlideIn: function afterSlideIn() {
    this.clearAutoHide();
    this.isSlid = false;
    this.clearMonitor();
    this.el.setStyle("z-index", "");
    this.panel.el.replaceClass('x-panel-floating', 'x-panel-collapsed');
    this.el.dom.style.left = this.restoreLT[0];
    this.el.dom.style.top = this.restoreLT[1];
    var ts = this.panel.tools;

    if (ts && ts.toggle) {
      ts.toggle.show();
    }
  },

  /**
   * If this Region is {@link #floatable}, and this Region has been slid into floating visibility, then this method slides
   * this region back into its collapsed state.
   */
  slideIn: function slideIn(cb) {
    if (!this.isSlid || this.el.hasActiveFx()) {
      Ext.callback(cb);
      return;
    }

    this.isSlid = false;

    if (this.animFloat !== false) {
      this.beforeSlide();
      this.el.slideOut(this.getSlideAnchor(), {
        callback: function callback() {
          this.el.hide();
          this.afterSlide();
          this.afterSlideIn();
          Ext.callback(cb);
        },
        scope: this,
        block: true
      });
    } else {
      this.el.hide();
      this.afterSlideIn();
    }
  },
  // private
  slideInIf: function slideInIf(e) {
    if (!e.within(this.el)) {
      this.slideIn();
    }
  },
  // private
  anchors: {
    "west": "left",
    "east": "right",
    "north": "top",
    "south": "bottom"
  },
  // private
  sanchors: {
    "west": "l",
    "east": "r",
    "north": "t",
    "south": "b"
  },
  // private
  canchors: {
    "west": "tl-tr",
    "east": "tr-tl",
    "north": "tl-bl",
    "south": "bl-tl"
  },
  // private
  getAnchor: function getAnchor() {
    return this.anchors[this.position];
  },
  // private
  getCollapseAnchor: function getCollapseAnchor() {
    return this.canchors[this.position];
  },
  // private
  getSlideAnchor: function getSlideAnchor() {
    return this.sanchors[this.position];
  },
  // private
  getAlignAdj: function getAlignAdj() {
    var cm = this.cmargins;

    switch (this.position) {
      case "west":
        return [0, 0];
        break;

      case "east":
        return [0, 0];
        break;

      case "north":
        return [0, 0];
        break;

      case "south":
        return [0, 0];
        break;
    }
  },
  // private
  getExpandAdj: function getExpandAdj() {
    var c = this.collapsedEl,
        cm = this.cmargins;

    switch (this.position) {
      case "west":
        return [-(cm.right + c.getWidth() + cm.left), 0];
        break;

      case "east":
        return [cm.right + c.getWidth() + cm.left, 0];
        break;

      case "north":
        return [0, -(cm.top + cm.bottom + c.getHeight())];
        break;

      case "south":
        return [0, cm.top + cm.bottom + c.getHeight()];
        break;
    }
  },
  destroy: function destroy() {
    Ext.destroy(this.miniCollapsedEl, this.collapsedEl);
  }
};
/**
 * @class Ext.layout.BorderLayout.SplitRegion
 * @extends Ext.layout.BorderLayout.Region
 * <p>This is a specialized type of {@link Ext.layout.BorderLayout.Region BorderLayout region} that
 * has a built-in {@link Ext.SplitBar} for user resizing of regions.  The movement of the split bar
 * is configurable to move either {@link #tickSize smooth or incrementally}.</p>
 * @constructor
 * Create a new SplitRegion.
 * @param {Layout} layout The {@link Ext.layout.BorderLayout BorderLayout} instance that is managing this Region.
 * @param {Object} config The configuration options
 * @param {String} position The region position.  Valid values are: north, south, east, west and center.  Every
 * BorderLayout must have a center region for the primary content -- all other regions are optional.
 */

Ext.layout.BorderLayout.SplitRegion = function (layout, config, pos) {
  Ext.layout.BorderLayout.SplitRegion.superclass.constructor.call(this, layout, config, pos); // prevent switch

  this.applyLayout = this.applyFns[pos];
};

Ext.extend(Ext.layout.BorderLayout.SplitRegion, Ext.layout.BorderLayout.Region, {
  /**
   * @cfg {Number} tickSize
   * The increment, in pixels by which to move this Region's {@link Ext.SplitBar SplitBar}.
   * By default, the {@link Ext.SplitBar SplitBar} moves smoothly.
   */

  /**
   * @cfg {String} splitTip
   * The tooltip to display when the user hovers over a
   * {@link Ext.layout.BorderLayout.Region#collapsible non-collapsible} region's split bar
   * (defaults to <tt>"Drag to resize."</tt>).  Only applies if
   * <tt>{@link #useSplitTips} = true</tt>.
   */
  splitTip: "Drag to resize.",

  /**
   * @cfg {String} collapsibleSplitTip
   * The tooltip to display when the user hovers over a
   * {@link Ext.layout.BorderLayout.Region#collapsible collapsible} region's split bar
   * (defaults to "Drag to resize. Double click to hide."). Only applies if
   * <tt>{@link #useSplitTips} = true</tt>.
   */
  collapsibleSplitTip: "Drag to resize. Double click to hide.",

  /**
   * @cfg {Boolean} useSplitTips
   * <tt>true</tt> to display a tooltip when the user hovers over a region's split bar
   * (defaults to <tt>false</tt>).  The tooltip text will be the value of either
   * <tt>{@link #splitTip}</tt> or <tt>{@link #collapsibleSplitTip}</tt> as appropriate.
   */
  useSplitTips: false,
  // private
  splitSettings: {
    north: {
      orientation: Ext.SplitBar.VERTICAL,
      placement: Ext.SplitBar.TOP,
      maxFn: 'getVMaxSize',
      minProp: 'minHeight',
      maxProp: 'maxHeight'
    },
    south: {
      orientation: Ext.SplitBar.VERTICAL,
      placement: Ext.SplitBar.BOTTOM,
      maxFn: 'getVMaxSize',
      minProp: 'minHeight',
      maxProp: 'maxHeight'
    },
    east: {
      orientation: Ext.SplitBar.HORIZONTAL,
      placement: Ext.SplitBar.RIGHT,
      maxFn: 'getHMaxSize',
      minProp: 'minWidth',
      maxProp: 'maxWidth'
    },
    west: {
      orientation: Ext.SplitBar.HORIZONTAL,
      placement: Ext.SplitBar.LEFT,
      maxFn: 'getHMaxSize',
      minProp: 'minWidth',
      maxProp: 'maxWidth'
    }
  },
  // private
  applyFns: {
    west: function west(box) {
      if (this.isCollapsed) {
        return this.applyLayoutCollapsed(box);
      }

      var sd = this.splitEl.dom,
          s = sd.style;
      this.panel.setPosition(box.x, box.y);
      var sw = sd.offsetWidth;
      s.left = box.x + box.width - sw + 'px';
      s.top = box.y + 'px';
      s.height = Math.max(0, box.height) + 'px';
      this.panel.setSize(box.width - sw, box.height);
    },
    east: function east(box) {
      if (this.isCollapsed) {
        return this.applyLayoutCollapsed(box);
      }

      var sd = this.splitEl.dom,
          s = sd.style;
      var sw = sd.offsetWidth;
      this.panel.setPosition(box.x + sw, box.y);
      s.left = box.x + 'px';
      s.top = box.y + 'px';
      s.height = Math.max(0, box.height) + 'px';
      this.panel.setSize(box.width - sw, box.height);
    },
    north: function north(box) {
      if (this.isCollapsed) {
        return this.applyLayoutCollapsed(box);
      }

      var sd = this.splitEl.dom,
          s = sd.style;
      var sh = sd.offsetHeight;
      this.panel.setPosition(box.x, box.y);
      s.left = box.x + 'px';
      s.top = box.y + box.height - sh + 'px';
      s.width = Math.max(0, box.width) + 'px';
      this.panel.setSize(box.width, box.height - sh);
    },
    south: function south(box) {
      if (this.isCollapsed) {
        return this.applyLayoutCollapsed(box);
      }

      var sd = this.splitEl.dom,
          s = sd.style;
      var sh = sd.offsetHeight;
      this.panel.setPosition(box.x, box.y + sh);
      s.left = box.x + 'px';
      s.top = box.y + 'px';
      s.width = Math.max(0, box.width) + 'px';
      this.panel.setSize(box.width, box.height - sh);
    }
  },
  // private
  render: function render(ct, p) {
    Ext.layout.BorderLayout.SplitRegion.superclass.render.call(this, ct, p);
    var ps = this.position;
    this.splitEl = ct.createChild({
      cls: "x-layout-split x-layout-split-" + ps,
      html: "&#160;",
      id: this.panel.id + '-xsplit'
    });

    if (this.collapseMode == 'mini') {
      this.miniSplitEl = this.splitEl.createChild({
        cls: "x-layout-mini x-layout-mini-" + ps,
        html: "&#160;"
      });
      this.miniSplitEl.addClassOnOver('x-layout-mini-over');
      this.miniSplitEl.on('click', this.onCollapseClick, this, {
        stopEvent: true
      });
    }

    var s = this.splitSettings[ps];
    this.split = new Ext.SplitBar(this.splitEl.dom, p.el, s.orientation);
    this.split.tickSize = this.tickSize;
    this.split.placement = s.placement;
    this.split.getMaximumSize = this[s.maxFn].createDelegate(this);
    this.split.minSize = this.minSize || this[s.minProp];
    this.split.on("beforeapply", this.onSplitMove, this);
    this.split.useShim = this.useShim === true;
    this.maxSize = this.maxSize || this[s.maxProp];

    if (p.hidden) {
      this.splitEl.hide();
    }

    if (this.useSplitTips) {
      this.splitEl.dom.title = this.collapsible ? this.collapsibleSplitTip : this.splitTip;
    }

    if (this.collapsible) {
      this.splitEl.on("dblclick", this.onCollapseClick, this);
    }
  },
  //docs inherit from superclass
  getSize: function getSize() {
    if (this.isCollapsed) {
      return this.collapsedEl.getSize();
    }

    var s = this.panel.getSize();

    if (this.position == 'north' || this.position == 'south') {
      s.height += this.splitEl.dom.offsetHeight;
    } else {
      s.width += this.splitEl.dom.offsetWidth;
    }

    return s;
  },
  // private
  getHMaxSize: function getHMaxSize() {
    var cmax = this.maxSize || 10000;
    var center = this.layout.center;
    return Math.min(cmax, this.el.getWidth() + center.el.getWidth() - center.getMinWidth());
  },
  // private
  getVMaxSize: function getVMaxSize() {
    var cmax = this.maxSize || 10000;
    var center = this.layout.center;
    return Math.min(cmax, this.el.getHeight() + center.el.getHeight() - center.getMinHeight());
  },
  // private
  onSplitMove: function onSplitMove(split, newSize) {
    var s = this.panel.getSize();
    this.lastSplitSize = newSize;

    if (this.position == 'north' || this.position == 'south') {
      this.panel.setSize(s.width, newSize);
      this.state.height = newSize;
    } else {
      this.panel.setSize(newSize, s.height);
      this.state.width = newSize;
    }

    this.layout.layout();
    this.panel.saveState();
    return false;
  },

  /**
   * Returns a reference to the split bar in use by this region.
   * @return {Ext.SplitBar} The split bar
   */
  getSplitBar: function getSplitBar() {
    return this.split;
  },
  // inherit docs
  destroy: function destroy() {
    Ext.destroy(this.miniSplitEl, this.split, this.splitEl);
    Ext.layout.BorderLayout.SplitRegion.superclass.destroy.call(this);
  }
});
Ext.Container.LAYOUTS['border'] = Ext.layout.BorderLayout;

/***/ }),
/* 765 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.FormLayout
 * @extends Ext.layout.AnchorLayout
 * <p>This layout manager is specifically designed for rendering and managing child Components of
 * {@link Ext.form.FormPanel forms}. It is responsible for rendering the labels of
 * {@link Ext.form.Field Field}s.</p>
 *
 * <p>This layout manager is used when a Container is configured with the <tt>layout:'form'</tt>
 * {@link Ext.Container#layout layout} config option, and should generally not need to be created directly
 * via the new keyword. See <tt><b>{@link Ext.Container#layout}</b></tt> for additional details.</p>
 *
 * <p>In an application, it will usually be preferrable to use a {@link Ext.form.FormPanel FormPanel}
 * (which is configured with FormLayout as its layout class by default) since it also provides built-in
 * functionality for {@link Ext.form.BasicForm#doAction loading, validating and submitting} the form.</p>
 *
 * <p>A {@link Ext.Container Container} <i>using</i> the FormLayout layout manager (e.g.
 * {@link Ext.form.FormPanel} or specifying <tt>layout:'form'</tt>) can also accept the following
 * layout-specific config properties:<div class="mdetail-params"><ul>
 * <li><b><tt>{@link Ext.form.FormPanel#hideLabels hideLabels}</tt></b></li>
 * <li><b><tt>{@link Ext.form.FormPanel#labelAlign labelAlign}</tt></b></li>
 * <li><b><tt>{@link Ext.form.FormPanel#labelPad labelPad}</tt></b></li>
 * <li><b><tt>{@link Ext.form.FormPanel#labelSeparator labelSeparator}</tt></b></li>
 * <li><b><tt>{@link Ext.form.FormPanel#labelWidth labelWidth}</tt></b></li>
 * </ul></div></p>
 *
 * <p>Any Component (including Fields) managed by FormLayout accepts the following as a config option:
 * <div class="mdetail-params"><ul>
 * <li><b><tt>{@link Ext.Component#anchor anchor}</tt></b></li>
 * </ul></div></p>
 *
 * <p>Any Component managed by FormLayout may be rendered as a form field (with an associated label) by
 * configuring it with a non-null <b><tt>{@link Ext.Component#fieldLabel fieldLabel}</tt></b>. Components configured
 * in this way may be configured with the following options which affect the way the FormLayout renders them:
 * <div class="mdetail-params"><ul>
 * <li><b><tt>{@link Ext.Component#clearCls clearCls}</tt></b></li>
 * <li><b><tt>{@link Ext.Component#fieldLabel fieldLabel}</tt></b></li>
 * <li><b><tt>{@link Ext.Component#hideLabel hideLabel}</tt></b></li>
 * <li><b><tt>{@link Ext.Component#itemCls itemCls}</tt></b></li>
 * <li><b><tt>{@link Ext.Component#labelSeparator labelSeparator}</tt></b></li>
 * <li><b><tt>{@link Ext.Component#labelStyle labelStyle}</tt></b></li>
 * </ul></div></p>
 *
 * <p>Example usage:</p>
 * <pre><code>
// Required if showing validation messages
Ext.QuickTips.init();

// While you can create a basic Panel with layout:'form', practically
// you should usually use a FormPanel to also get its form functionality
// since it already creates a FormLayout internally.
var form = new Ext.form.FormPanel({
    title: 'Form Layout',
    bodyStyle: 'padding:15px',
    width: 350,
    defaultType: 'textfield',
    defaults: {
        // applied to each contained item
        width: 230,
        msgTarget: 'side'
    },
    items: [{
            fieldLabel: 'First Name',
            name: 'first',
            allowBlank: false,
            {@link Ext.Component#labelSeparator labelSeparator}: ':' // override labelSeparator layout config
        },{
            fieldLabel: 'Last Name',
            name: 'last'
        },{
            fieldLabel: 'Email',
            name: 'email',
            vtype:'email'
        }, {
            xtype: 'textarea',
            hideLabel: true,     // override hideLabels layout config
            name: 'msg',
            anchor: '100% -53'
        }
    ],
    buttons: [
        {text: 'Save'},
        {text: 'Cancel'}
    ],
    layoutConfig: {
        {@link #labelSeparator}: '~' // superseded by assignment below
    },
    // config options applicable to container when layout='form':
    hideLabels: false,
    labelAlign: 'left',   // or 'right' or 'top'
    {@link Ext.form.FormPanel#labelSeparator labelSeparator}: '>>', // takes precedence over layoutConfig value
    labelWidth: 65,       // defaults to 100
    labelPad: 8           // defaults to 5, must specify labelWidth to be honored
});
</code></pre>
 */
Ext.layout.FormLayout = Ext.extend(Ext.layout.AnchorLayout, {
  /**
   * @cfg {String} labelSeparator
   * See {@link Ext.form.FormPanel}.{@link Ext.form.FormPanel#labelSeparator labelSeparator}.  Configuration
   * of this property at the <b>container</b> level takes precedence.
   */
  labelSeparator: ':',

  /**
   * Read only. The CSS style specification string added to field labels in this layout if not
   * otherwise {@link Ext.Component#labelStyle specified by each contained field}.
   * @type String
   * @property labelStyle
   */

  /**
   * @cfg {Boolean} trackLabels
   * True to show/hide the field label when the field is hidden. Defaults to <tt>false</tt>.
   */
  trackLabels: false,
  type: 'form',
  onRemove: function onRemove(c) {
    Ext.layout.FormLayout.superclass.onRemove.call(this, c);

    if (this.trackLabels) {
      c.un('show', this.onFieldShow, this);
      c.un('hide', this.onFieldHide, this);
    } // check for itemCt, since we may be removing a fieldset or something similar


    var el = c.getPositionEl(),
        ct = c.getItemCt && c.getItemCt();

    if (c.rendered && ct) {
      if (el && el.dom) {
        el.insertAfter(ct);
      }

      Ext.destroy(ct);
      Ext.destroyMembers(c, 'label', 'itemCt');

      if (c.customItemCt) {
        Ext.destroyMembers(c, 'getItemCt', 'customItemCt');
      }
    }
  },
  // private
  setContainer: function setContainer(ct) {
    Ext.layout.FormLayout.superclass.setContainer.call(this, ct);

    if (ct.labelAlign) {
      ct.addClass('x-form-label-' + ct.labelAlign);
    }

    if (ct.hideLabels) {
      Ext.apply(this, {
        labelStyle: 'display:none',
        elementStyle: 'padding-left:0;',
        labelAdjust: 0
      });
    } else {
      this.labelSeparator = ct.labelSeparator || this.labelSeparator;
      ct.labelWidth = ct.labelWidth || 100;

      if (Ext.isNumber(ct.labelWidth)) {
        var pad = Ext.isNumber(ct.labelPad) ? ct.labelPad : 5;
        Ext.apply(this, {
          labelAdjust: ct.labelWidth + pad,
          labelStyle: 'width:' + ct.labelWidth + 'px;',
          elementStyle: 'padding-left:' + (ct.labelWidth + pad) + 'px'
        });
      }

      if (ct.labelAlign == 'top') {
        Ext.apply(this, {
          labelStyle: 'width:auto;',
          labelAdjust: 0,
          elementStyle: 'padding-left:0;'
        });
      }
    }
  },
  // private
  isHide: function isHide(c) {
    return c.hideLabel || this.container.hideLabels;
  },
  onFieldShow: function onFieldShow(c) {
    c.getItemCt().removeClass('x-hide-' + c.hideMode);
  },
  onFieldHide: function onFieldHide(c) {
    c.getItemCt().addClass('x-hide-' + c.hideMode);
  },
  //private
  getLabelStyle: function getLabelStyle(s) {
    var ls = '',
        items = [this.labelStyle, s];

    for (var i = 0, len = items.length; i < len; ++i) {
      if (items[i]) {
        ls += items[i];

        if (ls.substr(-1, 1) != ';') {
          ls += ';';
        }
      }
    }

    return ls;
  },

  /**
   * @cfg {Ext.Template} fieldTpl
   * A {@link Ext.Template#compile compile}d {@link Ext.Template} for rendering
   * the fully wrapped, labeled and styled form Field. Defaults to:</p><pre><code>
  new Ext.Template(
  &#39;&lt;div class="x-form-item {itemCls}" tabIndex="-1">&#39;,
      &#39;&lt;&#108;abel for="{id}" style="{labelStyle}" class="x-form-item-&#108;abel">{&#108;abel}{labelSeparator}&lt;/&#108;abel>&#39;,
      &#39;&lt;div class="x-form-element" id="x-form-el-{id}" style="{elementStyle}">&#39;,
      &#39;&lt;/div>&lt;div class="{clearCls}">&lt;/div>&#39;,
  '&lt;/div>'
  );
  </code></pre>
   * <p>This may be specified to produce a different DOM structure when rendering form Fields.</p>
   * <p>A description of the properties within the template follows:</p><div class="mdetail-params"><ul>
   * <li><b><tt>itemCls</tt></b> : String<div class="sub-desc">The CSS class applied to the outermost div wrapper
   * that contains this field label and field element (the default class is <tt>'x-form-item'</tt> and <tt>itemCls</tt>
   * will be added to that). If supplied, <tt>itemCls</tt> at the field level will override the default <tt>itemCls</tt>
   * supplied at the container level.</div></li>
   * <li><b><tt>id</tt></b> : String<div class="sub-desc">The id of the Field</div></li>
   * <li><b><tt>{@link #labelStyle}</tt></b> : String<div class="sub-desc">
   * A CSS style specification string to add to the field label for this field (defaults to <tt>''</tt> or the
   * {@link #labelStyle layout's value for <tt>labelStyle</tt>}).</div></li>
   * <li><b><tt>label</tt></b> : String<div class="sub-desc">The text to display as the label for this
   * field (defaults to <tt>''</tt>)</div></li>
   * <li><b><tt>{@link #labelSeparator}</tt></b> : String<div class="sub-desc">The separator to display after
   * the text of the label for this field (defaults to a colon <tt>':'</tt> or the
   * {@link #labelSeparator layout's value for labelSeparator}). To hide the separator use empty string ''.</div></li>
   * <li><b><tt>elementStyle</tt></b> : String<div class="sub-desc">The styles text for the input element's wrapper.</div></li>
   * <li><b><tt>clearCls</tt></b> : String<div class="sub-desc">The CSS class to apply to the special clearing div
   * rendered directly after each form field wrapper (defaults to <tt>'x-form-clear-left'</tt>)</div></li>
   * </ul></div>
   * <p>Also see <tt>{@link #getTemplateArgs}</tt></p>
   */
  // private
  renderItem: function renderItem(c, position, target) {
    if (c && (c.isFormField || c.fieldLabel) && c.inputType != 'hidden') {
      var args = this.getTemplateArgs(c);

      if (Ext.isNumber(position)) {
        position = target.dom.childNodes[position] || null;
      }

      if (position) {
        c.itemCt = this.fieldTpl.insertBefore(position, args, true);
      } else {
        c.itemCt = this.fieldTpl.append(target, args, true);
      }

      if (!c.getItemCt) {
        // Non form fields don't have getItemCt, apply it here
        // This will get cleaned up in onRemove
        Ext.apply(c, {
          getItemCt: function getItemCt() {
            return c.itemCt;
          },
          customItemCt: true
        });
      }

      c.label = c.getItemCt().child('label.x-form-item-label');

      if (!c.rendered) {
        c.render('x-form-el-' + c.id);
      } else if (!this.isValidParent(c, target)) {
        Ext.fly('x-form-el-' + c.id).appendChild(c.getPositionEl());
      }

      if (this.trackLabels) {
        if (c.hidden) {
          this.onFieldHide(c);
        }

        c.on({
          scope: this,
          show: this.onFieldShow,
          hide: this.onFieldHide
        });
      }

      this.configureItem(c);
    } else {
      Ext.layout.FormLayout.superclass.renderItem.apply(this, arguments);
    }
  },

  /**
   * <p>Provides template arguments for rendering the fully wrapped, labeled and styled form Field.</p>
   * <p>This method returns an object hash containing properties used by the layout's {@link #fieldTpl}
   * to create a correctly wrapped, labeled and styled form Field. This may be overriden to
   * create custom layouts. The properties which must be returned are:</p><div class="mdetail-params"><ul>
   * <li><b><tt>itemCls</tt></b> : String<div class="sub-desc">The CSS class applied to the outermost div wrapper
   * that contains this field label and field element (the default class is <tt>'x-form-item'</tt> and <tt>itemCls</tt>
   * will be added to that). If supplied, <tt>itemCls</tt> at the field level will override the default <tt>itemCls</tt>
   * supplied at the container level.</div></li>
   * <li><b><tt>id</tt></b> : String<div class="sub-desc">The id of the Field</div></li>
   * <li><b><tt>{@link #labelStyle}</tt></b> : String<div class="sub-desc">
   * A CSS style specification string to add to the field label for this field (defaults to <tt>''</tt> or the
   * {@link #labelStyle layout's value for <tt>labelStyle</tt>}).</div></li>
   * <li><b><tt>label</tt></b> : String<div class="sub-desc">The text to display as the label for this
   * field (defaults to <tt>''</tt>)</div></li>
   * <li><b><tt>{@link #labelSeparator}</tt></b> : String<div class="sub-desc">The separator to display after
   * the text of the label for this field (defaults to a colon <tt>':'</tt> or the
   * {@link #labelSeparator layout's value for labelSeparator}). To hide the separator use empty string ''.</div></li>
   * <li><b><tt>elementStyle</tt></b> : String<div class="sub-desc">The styles text for the input element's wrapper.</div></li>
   * <li><b><tt>clearCls</tt></b> : String<div class="sub-desc">The CSS class to apply to the special clearing div
   * rendered directly after each form field wrapper (defaults to <tt>'x-form-clear-left'</tt>)</div></li>
   * </ul></div>
   * @param (Ext.form.Field} field The {@link Ext.form.Field Field} being rendered.
   * @return An object hash containing the properties required to render the Field.
   */
  getTemplateArgs: function getTemplateArgs(field) {
    var noLabelSep = !field.fieldLabel || field.hideLabel;
    return {
      id: field.id,
      label: field.fieldLabel,
      labelStyle: this.getLabelStyle(field.labelStyle),
      elementStyle: this.elementStyle || '',
      labelSeparator: noLabelSep ? '' : Ext.isDefined(field.labelSeparator) ? field.labelSeparator : this.labelSeparator,
      itemCls: (field.itemCls || this.container.itemCls || '') + (field.hideLabel ? ' x-hide-label' : ''),
      clearCls: field.clearCls || 'x-form-clear-left'
    };
  },
  // private
  adjustWidthAnchor: function adjustWidthAnchor(value, c) {
    if (c.label && !this.isHide(c) && this.container.labelAlign != 'top') {
      var adjust = Ext.isIE6 || Ext.isIE && !Ext.isStrict;
      return value - this.labelAdjust + (adjust ? -3 : 0);
    }

    return value;
  },
  adjustHeightAnchor: function adjustHeightAnchor(value, c) {
    if (c.label && !this.isHide(c) && this.container.labelAlign == 'top') {
      return value - c.label.getHeight();
    }

    return value;
  },
  // private
  isValidParent: function isValidParent(c, target) {
    return target && this.container.getEl().contains(c.getPositionEl());
  }
  /**
   * @property activeItem
   * @hide
   */

});
Ext.Container.LAYOUTS['form'] = Ext.layout.FormLayout;

/***/ }),
/* 766 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.AccordionLayout
 * @extends Ext.layout.FitLayout
 * <p>This is a layout that manages multiple Panels in an expandable accordion style such that only
 * <b>one Panel can be expanded at any given time</b>. Each Panel has built-in support for expanding and collapsing.</p>
 * <p>Note: Only Ext.Panels <b>and all subclasses of Ext.Panel</b> may be used in an accordion layout Container.</p>
 * <p>This class is intended to be extended or created via the <tt><b>{@link Ext.Container#layout layout}</b></tt>
 * configuration property.  See <tt><b>{@link Ext.Container#layout}</b></tt> for additional details.</p>
 * <p>Example usage:</p>
 * <pre><code>
var accordion = new Ext.Panel({
    title: 'Accordion Layout',
    layout:'accordion',
    defaults: {
        // applied to each contained panel
        bodyStyle: 'padding:15px'
    },
    layoutConfig: {
        // layout-specific configs go here
        titleCollapse: false,
        animate: true,
        activeOnTop: true
    },
    items: [{
        title: 'Panel 1',
        html: '&lt;p&gt;Panel content!&lt;/p&gt;'
    },{
        title: 'Panel 2',
        html: '&lt;p&gt;Panel content!&lt;/p&gt;'
    },{
        title: 'Panel 3',
        html: '&lt;p&gt;Panel content!&lt;/p&gt;'
    }]
});
</code></pre>
 */
Ext.layout.AccordionLayout = Ext.extend(Ext.layout.FitLayout, {
  /**
   * @cfg {Boolean} fill
   * True to adjust the active item's height to fill the available space in the container, false to use the
   * item's current height, or auto height if not explicitly set (defaults to true).
   */
  fill: true,

  /**
   * @cfg {Boolean} autoWidth
   * True to set each contained item's width to 'auto', false to use the item's current width (defaults to true).
   * Note that some components, in particular the {@link Ext.grid.GridPanel grid}, will not function properly within
   * layouts if they have auto width, so in such cases this config should be set to false.
   */
  autoWidth: true,

  /**
   * @cfg {Boolean} titleCollapse
   * True to allow expand/collapse of each contained panel by clicking anywhere on the title bar, false to allow
   * expand/collapse only when the toggle tool button is clicked (defaults to true).  When set to false,
   * {@link #hideCollapseTool} should be false also.
   */
  titleCollapse: true,

  /**
   * @cfg {Boolean} hideCollapseTool
   * True to hide the contained panels' collapse/expand toggle buttons, false to display them (defaults to false).
   * When set to true, {@link #titleCollapse} should be true also.
   */
  hideCollapseTool: false,

  /**
   * @cfg {Boolean} collapseFirst
   * True to make sure the collapse/expand toggle button always renders first (to the left of) any other tools
   * in the contained panels' title bars, false to render it last (defaults to false).
   */
  collapseFirst: false,

  /**
   * @cfg {Boolean} animate
   * True to slide the contained panels open and closed during expand/collapse using animation, false to open and
   * close directly with no animation (defaults to false).  Note: to defer to the specific config setting of each
   * contained panel for this property, set this to undefined at the layout level.
   */
  animate: false,

  /**
   * @cfg {Boolean} sequence
   * <b>Experimental</b>. If animate is set to true, this will result in each animation running in sequence.
   */
  sequence: false,

  /**
   * @cfg {Boolean} activeOnTop
   * True to swap the position of each panel as it is expanded so that it becomes the first item in the container,
   * false to keep the panels in the rendered order. <b>This is NOT compatible with "animate:true"</b> (defaults to false).
   */
  activeOnTop: false,
  type: 'accordion',
  renderItem: function renderItem(c) {
    if (this.animate === false) {
      c.animCollapse = false;
    }

    c.collapsible = true;

    if (this.autoWidth) {
      c.autoWidth = true;
    }

    if (this.titleCollapse) {
      c.titleCollapse = true;
    }

    if (this.hideCollapseTool) {
      c.hideCollapseTool = true;
    }

    if (this.collapseFirst !== undefined) {
      c.collapseFirst = this.collapseFirst;
    }

    if (!this.activeItem && !c.collapsed) {
      this.setActiveItem(c, true);
    } else if (this.activeItem && this.activeItem != c) {
      c.collapsed = true;
    }

    Ext.layout.AccordionLayout.superclass.renderItem.apply(this, arguments);
    c.header.addClass('x-accordion-hd');
    c.on('beforeexpand', this.beforeExpand, this);
  },
  onRemove: function onRemove(c) {
    Ext.layout.AccordionLayout.superclass.onRemove.call(this, c);

    if (c.rendered) {
      c.header.removeClass('x-accordion-hd');
    }

    c.un('beforeexpand', this.beforeExpand, this);
  },
  // private
  beforeExpand: function beforeExpand(p, anim) {
    var ai = this.activeItem;

    if (ai) {
      if (this.sequence) {
        delete this.activeItem;

        if (!ai.collapsed) {
          ai.collapse({
            callback: function callback() {
              p.expand(anim || true);
            },
            scope: this
          });
          return false;
        }
      } else {
        ai.collapse(this.animate);
      }
    }

    this.setActive(p);

    if (this.activeOnTop) {
      p.el.dom.parentNode.insertBefore(p.el.dom, p.el.dom.parentNode.firstChild);
    } // Items have been hidden an possibly rearranged, we need to get the container size again.


    this.layout();
  },
  // private
  setItemSize: function setItemSize(item, size) {
    if (this.fill && item) {
      var hh = 0,
          i,
          ct = this.getRenderedItems(this.container),
          len = ct.length,
          p; // Add up all the header heights

      for (i = 0; i < len; i++) {
        if ((p = ct[i]) != item) {
          hh += p.header.getHeight();
        }
      }

      ; // Subtract the header heights from the container size

      size.height -= hh; // Call setSize on the container to set the correct height.  For Panels, deferedHeight
      // will simply store this size for when the expansion is done.

      item.setSize(size);
    }
  },

  /**
   * Sets the active (expanded) item in the layout.
   * @param {String/Number} item The string component id or numeric index of the item to activate
   */
  setActiveItem: function setActiveItem(item) {
    this.setActive(item, true);
  },
  // private
  setActive: function setActive(item, expand) {
    var ai = this.activeItem;
    item = this.container.getComponent(item);

    if (ai != item) {
      if (item.rendered && item.collapsed && expand) {
        item.expand();
      } else {
        if (ai) {
          ai.fireEvent('deactivate', ai);
        }

        this.activeItem = item;
        item.fireEvent('activate', item);
      }
    }
  }
});
Ext.Container.LAYOUTS.accordion = Ext.layout.AccordionLayout; //backwards compat

Ext.layout.Accordion = Ext.layout.AccordionLayout;

/***/ }),
/* 767 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.TableLayout
 * @extends Ext.layout.ContainerLayout
 * <p>This layout allows you to easily render content into an HTML table.  The total number of columns can be
 * specified, and rowspan and colspan can be used to create complex layouts within the table.
 * This class is intended to be extended or created via the layout:'table' {@link Ext.Container#layout} config,
 * and should generally not need to be created directly via the new keyword.</p>
 * <p>Note that when creating a layout via config, the layout-specific config properties must be passed in via
 * the {@link Ext.Container#layoutConfig} object which will then be applied internally to the layout.  In the
 * case of TableLayout, the only valid layout config property is {@link #columns}.  However, the items added to a
 * TableLayout can supply the following table-specific config properties:</p>
 * <ul>
 * <li><b>rowspan</b> Applied to the table cell containing the item.</li>
 * <li><b>colspan</b> Applied to the table cell containing the item.</li>
 * <li><b>cellId</b> An id applied to the table cell containing the item.</li>
 * <li><b>cellCls</b> A CSS class name added to the table cell containing the item.</li>
 * </ul>
 * <p>The basic concept of building up a TableLayout is conceptually very similar to building up a standard
 * HTML table.  You simply add each panel (or "cell") that you want to include along with any span attributes
 * specified as the special config properties of rowspan and colspan which work exactly like their HTML counterparts.
 * Rather than explicitly creating and nesting rows and columns as you would in HTML, you simply specify the
 * total column count in the layoutConfig and start adding panels in their natural order from left to right,
 * top to bottom.  The layout will automatically figure out, based on the column count, rowspans and colspans,
 * how to position each panel within the table.  Just like with HTML tables, your rowspans and colspans must add
 * up correctly in your overall layout or you'll end up with missing and/or extra cells!  Example usage:</p>
 * <pre><code>
// This code will generate a layout table that is 3 columns by 2 rows
// with some spanning included.  The basic layout will be:
// +--------+-----------------+
// |   A    |   B             |
// |        |--------+--------|
// |        |   C    |   D    |
// +--------+--------+--------+
var table = new Ext.Panel({
    title: 'Table Layout',
    layout:'table',
    defaults: {
        // applied to each contained panel
        bodyStyle:'padding:20px'
    },
    layoutConfig: {
        // The total column count must be specified here
        columns: 3
    },
    items: [{
        html: '&lt;p&gt;Cell A content&lt;/p&gt;',
        rowspan: 2
    },{
        html: '&lt;p&gt;Cell B content&lt;/p&gt;',
        colspan: 2
    },{
        html: '&lt;p&gt;Cell C content&lt;/p&gt;',
        cellCls: 'highlight'
    },{
        html: '&lt;p&gt;Cell D content&lt;/p&gt;'
    }]
});
</code></pre>
 */
Ext.layout.TableLayout = Ext.extend(Ext.layout.ContainerLayout, {
  /**
   * @cfg {Number} columns
   * The total number of columns to create in the table for this layout.  If not specified, all Components added to
   * this layout will be rendered into a single row using one column per Component.
   */
  // private
  monitorResize: false,
  type: 'table',
  targetCls: 'x-table-layout-ct',

  /**
   * @cfg {Object} tableAttrs
   * <p>An object containing properties which are added to the {@link Ext.DomHelper DomHelper} specification
   * used to create the layout's <tt>&lt;table&gt;</tt> element. Example:</p><pre><code>
  {
  xtype: 'panel',
  layout: 'table',
  layoutConfig: {
      tableAttrs: {
          style: {
              width: '100%'
          }
      },
      columns: 3
  }
  }</code></pre>
   */
  tableAttrs: null,
  // private
  setContainer: function setContainer(ct) {
    Ext.layout.TableLayout.superclass.setContainer.call(this, ct);
    this.currentRow = 0;
    this.currentColumn = 0;
    this.cells = [];
  },
  // private
  onLayout: function onLayout(ct, target) {
    var cs = ct.items.items,
        len = cs.length,
        c,
        i;

    if (!this.table) {
      target.addClass('x-table-layout-ct');
      this.table = target.createChild(Ext.apply({
        tag: 'table',
        cls: 'x-table-layout',
        cellspacing: 0,
        cn: {
          tag: 'tbody'
        }
      }, this.tableAttrs), null, true);
    }

    this.renderAll(ct, target);
  },
  // private
  getRow: function getRow(index) {
    var row = this.table.tBodies[0].childNodes[index];

    if (!row) {
      row = document.createElement('tr');
      this.table.tBodies[0].appendChild(row);
    }

    return row;
  },
  // private
  getNextCell: function getNextCell(c) {
    var cell = this.getNextNonSpan(this.currentColumn, this.currentRow);
    var curCol = this.currentColumn = cell[0],
        curRow = this.currentRow = cell[1];

    for (var rowIndex = curRow; rowIndex < curRow + (c.rowspan || 1); rowIndex++) {
      if (!this.cells[rowIndex]) {
        this.cells[rowIndex] = [];
      }

      for (var colIndex = curCol; colIndex < curCol + (c.colspan || 1); colIndex++) {
        this.cells[rowIndex][colIndex] = true;
      }
    }

    var td = document.createElement('td');

    if (c.cellId) {
      td.id = c.cellId;
    }

    var cls = 'x-table-layout-cell';

    if (c.cellCls) {
      cls += ' ' + c.cellCls;
    }

    td.className = cls;

    if (c.colspan) {
      td.colSpan = c.colspan;
    }

    if (c.rowspan) {
      td.rowSpan = c.rowspan;
    }

    this.getRow(curRow).appendChild(td);
    return td;
  },
  // private
  getNextNonSpan: function getNextNonSpan(colIndex, rowIndex) {
    var cols = this.columns;

    while (cols && colIndex >= cols || this.cells[rowIndex] && this.cells[rowIndex][colIndex]) {
      if (cols && colIndex >= cols) {
        rowIndex++;
        colIndex = 0;
      } else {
        colIndex++;
      }
    }

    return [colIndex, rowIndex];
  },
  // private
  renderItem: function renderItem(c, position, target) {
    // Ensure we have our inner table to get cells to render into.
    if (!this.table) {
      this.table = target.createChild(Ext.apply({
        tag: 'table',
        cls: 'x-table-layout',
        cellspacing: 0,
        cn: {
          tag: 'tbody'
        }
      }, this.tableAttrs), null, true);
    }

    if (c && !c.rendered) {
      c.render(this.getNextCell(c));
      this.configureItem(c, position);
    } else if (c && !this.isValidParent(c, target)) {
      var container = this.getNextCell(c);
      container.insertBefore(c.getPositionEl().dom, null);
      c.container = Ext.get(container);
      this.configureItem(c, position);
    }
  },
  // private
  isValidParent: function isValidParent(c, target) {
    return c.getPositionEl().up('table', 5).dom.parentNode === (target.dom || target);
  }
  /**
   * @property activeItem
   * @hide
   */

});
Ext.Container.LAYOUTS['table'] = Ext.layout.TableLayout;

/***/ }),
/* 768 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.AbsoluteLayout
 * @extends Ext.layout.AnchorLayout
 * <p>This is a layout that inherits the anchoring of <b>{@link Ext.layout.AnchorLayout}</b> and adds the
 * ability for x/y positioning using the standard x and y component config options.</p>
 * <p>This class is intended to be extended or created via the <tt><b>{@link Ext.Container#layout layout}</b></tt>
 * configuration property.  See <tt><b>{@link Ext.Container#layout}</b></tt> for additional details.</p>
 * <p>Example usage:</p>
 * <pre><code>
var form = new Ext.form.FormPanel({
    title: 'Absolute Layout',
    layout:'absolute',
    layoutConfig: {
        // layout-specific configs go here
        extraCls: 'x-abs-layout-item',
    },
    baseCls: 'x-plain',
    url:'save-form.php',
    defaultType: 'textfield',
    items: [{
        x: 0,
        y: 5,
        xtype:'label',
        text: 'Send To:'
    },{
        x: 60,
        y: 0,
        name: 'to',
        anchor:'100%'  // anchor width by percentage
    },{
        x: 0,
        y: 35,
        xtype:'label',
        text: 'Subject:'
    },{
        x: 60,
        y: 30,
        name: 'subject',
        anchor: '100%'  // anchor width by percentage
    },{
        x:0,
        y: 60,
        xtype: 'textarea',
        name: 'msg',
        anchor: '100% 100%'  // anchor width and height
    }]
});
</code></pre>
 */
Ext.layout.AbsoluteLayout = Ext.extend(Ext.layout.AnchorLayout, {
  extraCls: 'x-abs-layout-item',
  type: 'anchor',
  onLayout: function onLayout(ct, target) {
    target.position();
    this.paddingLeft = target.getPadding('l');
    this.paddingTop = target.getPadding('t');
    Ext.layout.AbsoluteLayout.superclass.onLayout.call(this, ct, target);
  },
  // private
  adjustWidthAnchor: function adjustWidthAnchor(value, comp) {
    return value ? value - comp.getPosition(true)[0] + this.paddingLeft : value;
  },
  // private
  adjustHeightAnchor: function adjustHeightAnchor(value, comp) {
    return value ? value - comp.getPosition(true)[1] + this.paddingTop : value;
  }
  /**
   * @property activeItem
   * @hide
   */

});
Ext.Container.LAYOUTS['absolute'] = Ext.layout.AbsoluteLayout;

/***/ }),
/* 769 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.BoxLayout
 * @extends Ext.layout.ContainerLayout
 * <p>Base Class for HBoxLayout and VBoxLayout Classes. Generally it should not need to be used directly.</p>
 */
Ext.layout.BoxLayout = Ext.extend(Ext.layout.ContainerLayout, {
  /**
   * @cfg {Object} defaultMargins
   * <p>If the individual contained items do not have a <tt>margins</tt>
   * property specified, the default margins from this property will be
   * applied to each item.</p>
   * <br><p>This property may be specified as an object containing margins
   * to apply in the format:</p><pre><code>
  {
  top: (top margin),
  right: (right margin),
  bottom: (bottom margin),
  left: (left margin)
  }</code></pre>
   * <p>This property may also be specified as a string containing
   * space-separated, numeric margin values. The order of the sides associated
   * with each value matches the way CSS processes margin values:</p>
   * <div class="mdetail-params"><ul>
   * <li>If there is only one value, it applies to all sides.</li>
   * <li>If there are two values, the top and bottom borders are set to the
   * first value and the right and left are set to the second.</li>
   * <li>If there are three values, the top is set to the first value, the left
   * and right are set to the second, and the bottom is set to the third.</li>
   * <li>If there are four values, they apply to the top, right, bottom, and
   * left, respectively.</li>
   * </ul></div>
   * <p>Defaults to:</p><pre><code>
   * {top:0, right:0, bottom:0, left:0}
   * </code></pre>
   */
  defaultMargins: {
    left: 0,
    top: 0,
    right: 0,
    bottom: 0
  },

  /**
   * @cfg {String} padding
   * <p>Sets the padding to be applied to all child items managed by this layout.</p>
   * <p>This property must be specified as a string containing
   * space-separated, numeric padding values. The order of the sides associated
   * with each value matches the way CSS processes padding values:</p>
   * <div class="mdetail-params"><ul>
   * <li>If there is only one value, it applies to all sides.</li>
   * <li>If there are two values, the top and bottom borders are set to the
   * first value and the right and left are set to the second.</li>
   * <li>If there are three values, the top is set to the first value, the left
   * and right are set to the second, and the bottom is set to the third.</li>
   * <li>If there are four values, they apply to the top, right, bottom, and
   * left, respectively.</li>
   * </ul></div>
   * <p>Defaults to: <code>"0"</code></p>
   */
  padding: '0',
  // documented in subclasses
  pack: 'start',
  // private
  monitorResize: true,
  type: 'box',
  scrollOffset: 0,
  extraCls: 'x-box-item',
  targetCls: 'x-box-layout-ct',
  innerCls: 'x-box-inner',
  constructor: function constructor(config) {
    Ext.layout.BoxLayout.superclass.constructor.call(this, config);

    if (Ext.isString(this.defaultMargins)) {
      this.defaultMargins = this.parseMargins(this.defaultMargins);
    }
  },
  // private
  isValidParent: function isValidParent(c, target) {
    return this.innerCt && c.getPositionEl().dom.parentNode == this.innerCt.dom;
  },
  // private
  renderAll: function renderAll(ct, target) {
    if (!this.innerCt) {
      // the innerCt prevents wrapping and shuffling while
      // the container is resizing
      this.innerCt = target.createChild({
        cls: this.innerCls
      });
      this.padding = this.parseMargins(this.padding);
    }

    Ext.layout.BoxLayout.superclass.renderAll.call(this, ct, this.innerCt);
  },
  onLayout: function onLayout(ct, target) {
    this.renderAll(ct, target);
  },
  getLayoutTargetSize: function getLayoutTargetSize() {
    var target = this.container.getLayoutTarget(),
        ret;

    if (target) {
      ret = target.getViewSize();
      ret.width -= target.getPadding('lr');
      ret.height -= target.getPadding('tb');
    }

    return ret;
  },
  // private
  renderItem: function renderItem(c) {
    if (Ext.isString(c.margins)) {
      c.margins = this.parseMargins(c.margins);
    } else if (!c.margins) {
      c.margins = this.defaultMargins;
    }

    Ext.layout.BoxLayout.superclass.renderItem.apply(this, arguments);
  }
});
/**
 * @class Ext.layout.VBoxLayout
 * @extends Ext.layout.BoxLayout
 * <p>A layout that arranges items vertically down a Container. This layout optionally divides available vertical
 * space between child items containing a numeric <code>flex</code> configuration.</p>
 * This layout may also be used to set the widths of child items by configuring it with the {@link #align} option.
 */

Ext.layout.VBoxLayout = Ext.extend(Ext.layout.BoxLayout, {
  /**
   * @cfg {String} align
   * Controls how the child items of the container are aligned. Acceptable configuration values for this
   * property are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>left</tt></b> : <b>Default</b><div class="sub-desc">child items are aligned horizontally
   * at the <b>left</b> side of the container</div></li>
   * <li><b><tt>center</tt></b> : <div class="sub-desc">child items are aligned horizontally at the
   * <b>mid-width</b> of the container</div></li>
   * <li><b><tt>stretch</tt></b> : <div class="sub-desc">child items are stretched horizontally to fill
   * the width of the container</div></li>
   * <li><b><tt>stretchmax</tt></b> : <div class="sub-desc">child items are stretched horizontally to
   * the size of the largest item.</div></li>
   * </ul></div>
   */
  align: 'left',
  // left, center, stretch, strechmax
  type: 'vbox',

  /**
   * @cfg {String} pack
   * Controls how the child items of the container are packed together. Acceptable configuration values
   * for this property are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>start</tt></b> : <b>Default</b><div class="sub-desc">child items are packed together at
   * <b>top</b> side of container</div></li>
   * <li><b><tt>center</tt></b> : <div class="sub-desc">child items are packed together at
   * <b>mid-height</b> of container</div></li>
   * <li><b><tt>end</tt></b> : <div class="sub-desc">child items are packed together at <b>bottom</b>
   * side of container</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Number} flex
   * This configuation option is to be applied to <b>child <tt>items</tt></b> of the container managed
   * by this layout. Each child item with a <tt>flex</tt> property will be flexed <b>vertically</b>
   * according to each item's <b>relative</b> <tt>flex</tt> value compared to the sum of all items with
   * a <tt>flex</tt> value specified.  Any child items that have either a <tt>flex = 0</tt> or
   * <tt>flex = undefined</tt> will not be 'flexed' (the initial size will not be changed).
   */
  // private
  onLayout: function onLayout(ct, target) {
    Ext.layout.VBoxLayout.superclass.onLayout.call(this, ct, target);
    var cs = this.getRenderedItems(ct),
        csLen = cs.length,
        c,
        i,
        cm,
        ch,
        margin,
        cl,
        diff,
        aw,
        availHeight,
        size = this.getLayoutTargetSize(),
        w = size.width,
        h = size.height - this.scrollOffset,
        l = this.padding.left,
        t = this.padding.top,
        isStart = this.pack == 'start',
        extraHeight = 0,
        maxWidth = 0,
        totalFlex = 0,
        usedHeight = 0,
        idx = 0,
        heights = [],
        restore = []; // Do only width calculations and apply those first, as they can affect height

    for (i = 0; i < csLen; i++) {
      c = cs[i];
      cm = c.margins;
      margin = cm.top + cm.bottom; // Max height for align

      maxWidth = Math.max(maxWidth, c.getWidth() + cm.left + cm.right);
    }

    var innerCtWidth = maxWidth + this.padding.left + this.padding.right;

    switch (this.align) {
      case 'stretch':
        this.innerCt.setSize(w, h);
        break;

      case 'stretchmax':
      case 'left':
        this.innerCt.setSize(innerCtWidth, h);
        break;

      case 'center':
        this.innerCt.setSize(w = Math.max(w, innerCtWidth), h);
        break;
    }

    var availableWidth = Math.max(0, w - this.padding.left - this.padding.right); // Apply widths

    for (i = 0; i < csLen; i++) {
      c = cs[i];
      cm = c.margins;

      if (this.align == 'stretch') {
        c.setWidth((w - (this.padding.left + this.padding.right) - (cm.left + cm.right)).constrain(c.minWidth || 0, c.maxWidth || 1000000));
      } else if (this.align == 'stretchmax') {
        c.setWidth((maxWidth - (cm.left + cm.right)).constrain(c.minWidth || 0, c.maxWidth || 1000000));
      } else if (isStart && c.flex) {
        c.setWidth();
      }
    } // Height calculations


    for (i = 0; i < csLen; i++) {
      c = cs[i]; // Total of all the flex values

      totalFlex += c.flex || 0; // Don't run height calculations on flexed items

      if (!c.flex) {
        // Render and layout sub-containers without a flex or height, once
        if (!c.height && !c.hasLayout && c.doLayout) {
          c.doLayout();
        }

        ch = c.getHeight();
      } else {
        ch = 0;
      }

      cm = c.margins; // Determine how much height is available to flex

      extraHeight += ch + cm.top + cm.bottom;
    } // Final avail height calc


    availHeight = Math.max(0, h - extraHeight - this.padding.top - this.padding.bottom);
    var leftOver = availHeight;

    for (i = 0; i < csLen; i++) {
      c = cs[i];

      if (isStart && c.flex) {
        ch = Math.floor(availHeight * (c.flex / totalFlex));
        leftOver -= ch;
        heights.push(ch);
      }
    }

    if (this.pack == 'center') {
      t += availHeight ? availHeight / 2 : 0;
    } else if (this.pack == 'end') {
      t += availHeight;
    }

    idx = 0; // Apply heights

    for (i = 0; i < csLen; i++) {
      c = cs[i];
      cm = c.margins;
      t += cm.top;
      aw = availableWidth;
      cl = l + cm.left; // default left pos
      // Adjust left pos for centering

      if (this.align == 'center') {
        if ((diff = availableWidth - (c.getWidth() + cm.left + cm.right)) > 0) {
          cl += diff / 2;
          aw -= diff;
        }
      }

      c.setPosition(cl, t);

      if (isStart && c.flex) {
        ch = Math.max(0, heights[idx++] + (leftOver-- > 0 ? 1 : 0));
        c.setSize(aw, ch);
      } else {
        ch = c.getHeight();
      }

      t += ch + cm.bottom;
    } // Putting a box layout into an overflowed container is NOT correct and will make a second layout pass necessary.


    if (i = target.getStyle('overflow') && i != 'hidden' && !this.adjustmentPass) {
      var ts = this.getLayoutTargetSize();

      if (ts.width != size.width || ts.height != size.height) {
        this.adjustmentPass = true;
        this.onLayout(ct, target);
      }
    }

    delete this.adjustmentPass;
  }
});
Ext.Container.LAYOUTS.vbox = Ext.layout.VBoxLayout;
/**
 * @class Ext.layout.HBoxLayout
 * @extends Ext.layout.BoxLayout
 * <p>A layout that arranges items horizontally across a Container. This layout optionally divides available horizontal
 * space between child items containing a numeric <code>flex</code> configuration.</p>
 * This layout may also be used to set the heights of child items by configuring it with the {@link #align} option.
 */

Ext.layout.HBoxLayout = Ext.extend(Ext.layout.BoxLayout, {
  /**
   * @cfg {String} align
   * Controls how the child items of the container are aligned. Acceptable configuration values for this
   * property are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>top</tt></b> : <b>Default</b><div class="sub-desc">child items are aligned vertically
   * at the <b>top</b> of the container</div></li>
   * <li><b><tt>middle</tt></b> : <div class="sub-desc">child items are aligned vertically in the
   * <b>middle</b> of the container</div></li>
   * <li><b><tt>stretch</tt></b> : <div class="sub-desc">child items are stretched vertically to fill
   * the height of the container</div></li>
   * <li><b><tt>stretchmax</tt></b> : <div class="sub-desc">child items are stretched vertically to
   * the height of the largest item.</div></li>
   */
  align: 'top',
  // top, middle, stretch, strechmax
  type: 'hbox',

  /**
   * @cfg {String} pack
   * Controls how the child items of the container are packed together. Acceptable configuration values
   * for this property are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>start</tt></b> : <b>Default</b><div class="sub-desc">child items are packed together at
   * <b>left</b> side of container</div></li>
   * <li><b><tt>center</tt></b> : <div class="sub-desc">child items are packed together at
   * <b>mid-width</b> of container</div></li>
   * <li><b><tt>end</tt></b> : <div class="sub-desc">child items are packed together at <b>right</b>
   * side of container</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Number} flex
   * This configuation option is to be applied to <b>child <tt>items</tt></b> of the container managed
   * by this layout. Each child item with a <tt>flex</tt> property will be flexed <b>horizontally</b>
   * according to each item's <b>relative</b> <tt>flex</tt> value compared to the sum of all items with
   * a <tt>flex</tt> value specified.  Any child items that have either a <tt>flex = 0</tt> or
   * <tt>flex = undefined</tt> will not be 'flexed' (the initial size will not be changed).
   */
  // private
  onLayout: function onLayout(ct, target) {
    Ext.layout.HBoxLayout.superclass.onLayout.call(this, ct, target);
    var cs = this.getRenderedItems(ct),
        csLen = cs.length,
        c,
        i,
        cm,
        cw,
        ch,
        diff,
        availWidth,
        size = this.getLayoutTargetSize(),
        w = size.width - this.scrollOffset,
        h = size.height,
        l = this.padding.left,
        t = this.padding.top,
        isStart = this.pack == 'start',
        isRestore = ['stretch', 'stretchmax'].indexOf(this.align) == -1,
        extraWidth = 0,
        maxHeight = 0,
        totalFlex = 0,
        usedWidth = 0;

    for (i = 0; i < csLen; i++) {
      c = cs[i]; // Total of all the flex values

      totalFlex += c.flex || 0; // Don't run width calculations on flexed items

      if (!c.flex) {
        // Render and layout sub-containers without a flex or width, once
        if (!c.width && !c.hasLayout && c.doLayout) {
          c.doLayout();
        }

        cw = c.getWidth();
      } else {
        cw = 0;
      }

      cm = c.margins; // Determine how much width is available to flex

      extraWidth += cw + cm.left + cm.right; // Max height for align

      maxHeight = Math.max(maxHeight, c.getHeight() + cm.top + cm.bottom);
    } // Final avail width calc


    availWidth = Math.max(0, w - extraWidth - this.padding.left - this.padding.right);
    var innerCtHeight = maxHeight + this.padding.top + this.padding.bottom;

    switch (this.align) {
      case 'stretch':
        this.innerCt.setSize(w, h);
        break;

      case 'stretchmax':
      case 'top':
        this.innerCt.setSize(w, innerCtHeight);
        break;

      case 'middle':
        this.innerCt.setSize(w, h = Math.max(h, innerCtHeight));
        break;
    }

    var leftOver = availWidth,
        widths = [],
        restore = [],
        idx = 0,
        availableHeight = Math.max(0, h - this.padding.top - this.padding.bottom);

    for (i = 0; i < csLen; i++) {
      c = cs[i];

      if (isStart && c.flex) {
        cw = Math.floor(availWidth * (c.flex / totalFlex));
        leftOver -= cw;
        widths.push(cw);
      }
    }

    if (this.pack == 'center') {
      l += availWidth ? availWidth / 2 : 0;
    } else if (this.pack == 'end') {
      l += availWidth;
    }

    for (i = 0; i < csLen; i++) {
      c = cs[i];
      cm = c.margins;
      l += cm.left;
      c.setPosition(l, t + cm.top);

      if (isStart && c.flex) {
        cw = Math.max(0, widths[idx++] + (leftOver-- > 0 ? 1 : 0));

        if (isRestore) {
          restore.push(c.getHeight());
        }

        c.setSize(cw, availableHeight);
      } else {
        cw = c.getWidth();
      }

      l += cw + cm.right;
    }

    idx = 0;

    for (i = 0; i < csLen; i++) {
      c = cs[i];
      cm = c.margins;
      ch = c.getHeight();

      if (isStart && c.flex) {
        ch = restore[idx++];
      }

      if (this.align == 'stretch') {
        c.setHeight((h - (this.padding.top + this.padding.bottom) - (cm.top + cm.bottom)).constrain(c.minHeight || 0, c.maxHeight || 1000000));
      } else if (this.align == 'stretchmax') {
        c.setHeight((maxHeight - (cm.top + cm.bottom)).constrain(c.minHeight || 0, c.maxHeight || 1000000));
      } else {
        if (this.align == 'middle') {
          diff = availableHeight - (ch + cm.top + cm.bottom);
          ch = t + cm.top + diff / 2;

          if (diff > 0) {
            c.setPosition(c.x, ch);
          }
        }

        if (isStart && c.flex) {
          c.setHeight(ch);
        }
      }
    } // Putting a box layout into an overflowed container is NOT correct and will make a second layout pass necessary.


    if (i = target.getStyle('overflow') && i != 'hidden' && !this.adjustmentPass) {
      var ts = this.getLayoutTargetSize();

      if (ts.width != size.width || ts.height != size.height) {
        this.adjustmentPass = true;
        this.onLayout(ct, target);
      }
    }

    delete this.adjustmentPass;
  }
});
Ext.Container.LAYOUTS.hbox = Ext.layout.HBoxLayout;

/***/ }),
/* 770 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.ToolbarLayout
 * @extends Ext.layout.ContainerLayout
 * Layout manager implicitly used by Ext.Toolbar.
 */
Ext.layout.ToolbarLayout = Ext.extend(Ext.layout.ContainerLayout, {
  monitorResize: true,
  triggerWidth: 18,
  lastOverflow: false,
  noItemsMenuText: '<div class="x-toolbar-no-items">(None)</div>',
  // private
  onLayout: function onLayout(ct, target) {
    if (!this.leftTr) {
      var align = ct.buttonAlign == 'center' ? 'center' : 'left';
      target.addClass('x-toolbar-layout-ct');
      target.insertHtml('beforeEnd', '<table cellspacing="0" class="x-toolbar-ct"><tbody><tr><td class="x-toolbar-left" align="' + align + '"><table cellspacing="0"><tbody><tr class="x-toolbar-left-row"></tr></tbody></table></td><td class="x-toolbar-right" align="right"><table cellspacing="0" class="x-toolbar-right-ct"><tbody><tr><td><table cellspacing="0"><tbody><tr class="x-toolbar-right-row"></tr></tbody></table></td><td><table cellspacing="0"><tbody><tr class="x-toolbar-extras-row"></tr></tbody></table></td></tr></tbody></table></td></tr></tbody></table>');
      this.leftTr = target.child('tr.x-toolbar-left-row', true);
      this.rightTr = target.child('tr.x-toolbar-right-row', true);
      this.extrasTr = target.child('tr.x-toolbar-extras-row', true);
    }

    var side = ct.buttonAlign == 'right' ? this.rightTr : this.leftTr,
        pos = 0,
        items = ct.items.items;

    for (var i = 0, len = items.length, c; i < len; i++, pos++) {
      c = items[i];

      if (c.isFill) {
        side = this.rightTr;
        pos = -1;
      } else if (!c.rendered) {
        c.render(this.insertCell(c, side, pos));
      } else {
        if (!c.xtbHidden && !this.isValidParent(c, side.childNodes[pos])) {
          var td = this.insertCell(c, side, pos);
          td.appendChild(c.getPositionEl().dom);
          c.container = Ext.get(td);
        }
      }
    } //strip extra empty cells


    this.cleanup(this.leftTr);
    this.cleanup(this.rightTr);
    this.cleanup(this.extrasTr);
    this.fitToSize(target);
  },
  cleanup: function cleanup(row) {
    var cn = row.childNodes,
        i,
        c;

    for (i = cn.length - 1; i >= 0 && (c = cn[i]); i--) {
      if (!c.firstChild) {
        row.removeChild(c);
      }
    }
  },
  insertCell: function insertCell(c, side, pos) {
    var td = document.createElement('td');
    td.className = 'x-toolbar-cell';
    side.insertBefore(td, side.childNodes[pos] || null);
    return td;
  },
  hideItem: function hideItem(item) {
    var h = this.hiddens = this.hiddens || [];
    h.push(item);
    item.xtbHidden = true;
    item.xtbWidth = item.getPositionEl().dom.parentNode.offsetWidth;
    item.hide();
  },
  unhideItem: function unhideItem(item) {
    item.show();
    item.xtbHidden = false;
    this.hiddens.remove(item);

    if (this.hiddens.length < 1) {
      delete this.hiddens;
    }
  },
  getItemWidth: function getItemWidth(c) {
    return c.hidden ? c.xtbWidth || 0 : c.getPositionEl().dom.parentNode.offsetWidth;
  },
  fitToSize: function fitToSize(t) {
    if (this.container.enableOverflow === false) {
      return;
    }

    var w = t.dom.clientWidth,
        lw = this.lastWidth || 0,
        iw = t.dom.firstChild.offsetWidth,
        clipWidth = w - this.triggerWidth,
        hideIndex = -1;
    this.lastWidth = w;

    if (iw > w || this.hiddens && w >= lw) {
      var i,
          items = this.container.items.items,
          len = items.length,
          c,
          loopWidth = 0;

      for (i = 0; i < len; i++) {
        c = items[i];

        if (!c.isFill) {
          loopWidth += this.getItemWidth(c);

          if (loopWidth > clipWidth) {
            if (!(c.hidden || c.xtbHidden)) {
              this.hideItem(c);
            }
          } else if (c.xtbHidden) {
            this.unhideItem(c);
          }
        }
      }
    }

    if (this.hiddens) {
      this.initMore();

      if (!this.lastOverflow) {
        this.container.fireEvent('overflowchange', this.container, true);
        this.lastOverflow = true;
      }
    } else if (this.more) {
      this.clearMenu();
      this.more.destroy();
      delete this.more;

      if (this.lastOverflow) {
        this.container.fireEvent('overflowchange', this.container, false);
        this.lastOverflow = false;
      }
    }
  },
  createMenuConfig: function createMenuConfig(c, hideOnClick) {
    var cfg = Ext.apply({}, c.initialConfig),
        group = c.toggleGroup;
    Ext.apply(cfg, {
      text: c.overflowText || c.text,
      iconCls: c.iconCls,
      icon: c.icon,
      itemId: c.itemId,
      disabled: c.disabled,
      handler: c.handler,
      scope: c.scope,
      menu: c.menu,
      hideOnClick: hideOnClick
    });

    if (group || c.enableToggle) {
      Ext.apply(cfg, {
        group: group,
        checked: c.pressed,
        listeners: {
          checkchange: function checkchange(item, checked) {
            c.toggle(checked);
          }
        }
      });
    }

    delete cfg.ownerCt;
    delete cfg.xtype;
    delete cfg.id;
    return cfg;
  },
  // private
  addComponentToMenu: function addComponentToMenu(m, c) {
    if (c instanceof Ext.Toolbar.Separator) {
      m.add('-');
    } else if (Ext.isFunction(c.isXType)) {
      if (c.isXType('splitbutton')) {
        m.add(this.createMenuConfig(c, true));
      } else if (c.isXType('button')) {
        m.add(this.createMenuConfig(c, !c.menu));
      } else if (c.isXType('buttongroup')) {
        c.items.each(function (item) {
          this.addComponentToMenu(m, item);
        }, this);
      }
    }
  },
  clearMenu: function clearMenu() {
    var m = this.moreMenu;

    if (m && m.items) {
      m.items.each(function (item) {
        delete item.menu;
      });
    }
  },
  // private
  beforeMoreShow: function beforeMoreShow(m) {
    var h = this.container.items.items,
        len = h.length,
        c,
        prev,
        needsSep = function needsSep(group, item) {
      return group.isXType('buttongroup') && !(item instanceof Ext.Toolbar.Separator);
    };

    this.clearMenu();
    m.removeAll();

    for (var i = 0; i < len; i++) {
      c = h[i];

      if (c.xtbHidden) {
        if (prev && (needsSep(c, prev) || needsSep(prev, c))) {
          m.add('-');
        }

        this.addComponentToMenu(m, c);
        prev = c;
      }
    } // put something so the menu isn't empty
    // if no compatible items found


    if (m.items.length < 1) {
      m.add(this.noItemsMenuText);
    }
  },
  initMore: function initMore() {
    if (!this.more) {
      this.moreMenu = new Ext.menu.Menu({
        ownerCt: this.container,
        listeners: {
          beforeshow: this.beforeMoreShow,
          scope: this
        }
      });
      this.more = new Ext.Button({
        iconCls: 'x-toolbar-more-icon',
        cls: 'x-toolbar-more',
        menu: this.moreMenu,
        ownerCt: this.container
      });
      var td = this.insertCell(this.more, this.extrasTr, 100);
      this.more.render(td);
    }
  },
  destroy: function destroy() {
    Ext.destroy(this.more, this.moreMenu);
    delete this.leftTr;
    delete this.rightTr;
    delete this.extrasTr;
    Ext.layout.ToolbarLayout.superclass.destroy.call(this);
  }
});
Ext.Container.LAYOUTS.toolbar = Ext.layout.ToolbarLayout;

/***/ }),
/* 771 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.layout.MenuLayout
 * @extends Ext.layout.ContainerLayout
 * <p>Layout manager used by {@link Ext.menu.Menu}. Generally this class should not need to be used directly.</p>
 */
Ext.layout.MenuLayout = Ext.extend(Ext.layout.ContainerLayout, {
  monitorResize: true,
  setContainer: function setContainer(ct) {
    this.monitorResize = !ct.floating; // This event is only fired by the menu in IE, used so we don't couple
    // the menu with the layout.

    ct.on('autosize', this.doAutoSize, this);
    Ext.layout.MenuLayout.superclass.setContainer.call(this, ct);
  },
  renderItem: function renderItem(c, position, target) {
    if (!this.itemTpl) {
      this.itemTpl = Ext.layout.MenuLayout.prototype.itemTpl = new Ext.XTemplate('<li id="{itemId}" class="{itemCls}">', '<tpl if="needsIcon">', '<img src="{icon}" class="{iconCls}"/>', '</tpl>', '</li>');
    }

    if (c && !c.rendered) {
      if (Ext.isNumber(position)) {
        position = target.dom.childNodes[position];
      }

      var a = this.getItemArgs(c); //          The Component's positionEl is the <li> it is rendered into

      c.render(c.positionEl = position ? this.itemTpl.insertBefore(position, a, true) : this.itemTpl.append(target, a, true)); //          Link the containing <li> to the item.

      c.positionEl.menuItemId = c.getItemId(); //          If rendering a regular Component, and it needs an icon,
      //          move the Component rightwards.

      if (!a.isMenuItem && a.needsIcon) {
        c.positionEl.addClass('x-menu-list-item-indent');
      }

      this.configureItem(c, position);
    } else if (c && !this.isValidParent(c, target)) {
      if (Ext.isNumber(position)) {
        position = target.dom.childNodes[position];
      }

      target.dom.insertBefore(c.getActionEl().dom, position || null);
    }
  },
  getItemArgs: function getItemArgs(c) {
    var isMenuItem = c instanceof Ext.menu.Item;
    return {
      isMenuItem: isMenuItem,
      needsIcon: !isMenuItem && (c.icon || c.iconCls),
      icon: c.icon || Ext.BLANK_IMAGE_URL,
      iconCls: 'x-menu-item-icon ' + (c.iconCls || ''),
      itemId: 'x-menu-el-' + c.id,
      itemCls: 'x-menu-list-item '
    };
  },
  //  Valid if the Component is in a <li> which is part of our target <ul>
  isValidParent: function isValidParent(c, target) {
    return c.el.up('li.x-menu-list-item', 5).dom.parentNode === (target.dom || target);
  },
  onLayout: function onLayout(ct, target) {
    Ext.layout.MenuLayout.superclass.onLayout.call(this, ct, target);
    this.doAutoSize();
  },
  doAutoSize: function doAutoSize() {
    var ct = this.container,
        w = ct.width;

    if (ct.floating) {
      if (w) {
        ct.setWidth(w);
      } else if (Ext.isIE) {
        ct.setWidth(Ext.isStrict && (Ext.isIE7 || Ext.isIE8) ? 'auto' : ct.minWidth);
        var el = ct.getEl(),
            t = el.dom.offsetWidth; // force recalc

        ct.setWidth(ct.getLayoutTarget().getWidth() + el.getFrameWidth('lr'));
      }
    }
  }
});
Ext.Container.LAYOUTS['menu'] = Ext.layout.MenuLayout;

/***/ }),
/* 772 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Viewport
 * @extends Ext.Container
 * <p>A specialized container representing the viewable application area (the browser viewport).</p>
 * <p>The Viewport renders itself to the document body, and automatically sizes itself to the size of
 * the browser viewport and manages window resizing. There may only be one Viewport created
 * in a page. Inner layouts are available by virtue of the fact that all {@link Ext.Panel Panel}s
 * added to the Viewport, either through its {@link #items}, or through the items, or the {@link #add}
 * method of any of its child Panels may themselves have a layout.</p>
 * <p>The Viewport does not provide scrolling, so child Panels within the Viewport should provide
 * for scrolling if needed using the {@link #autoScroll} config.</p>
 * <p>An example showing a classic application border layout:</p><pre><code>
new Ext.Viewport({
    layout: 'border',
    items: [{
        region: 'north',
        html: '&lt;h1 class="x-panel-header">Page Title&lt;/h1>',
        autoHeight: true,
        border: false,
        margins: '0 0 5 0'
    }, {
        region: 'west',
        collapsible: true,
        title: 'Navigation',
        width: 200
        // the west region might typically utilize a {@link Ext.tree.TreePanel TreePanel} or a Panel with {@link Ext.layout.AccordionLayout Accordion layout}
    }, {
        region: 'south',
        title: 'Title for Panel',
        collapsible: true,
        html: 'Information goes here',
        split: true,
        height: 100,
        minHeight: 100
    }, {
        region: 'east',
        title: 'Title for the Grid Panel',
        collapsible: true,
        split: true,
        width: 200,
        xtype: 'grid',
        // remaining grid configuration not shown ...
        // notice that the GridPanel is added directly as the region
        // it is not "overnested" inside another Panel
    }, {
        region: 'center',
        xtype: 'tabpanel', // TabPanel itself has no title
        items: {
            title: 'Default Tab',
            html: 'The first tab\'s content. Others may be added dynamically'
        }
    }]
});
</code></pre>
 * @constructor
 * Create a new Viewport
 * @param {Object} config The config object
 * @xtype viewport
 */
Ext.Viewport = Ext.extend(Ext.Container, {
  /*
   * Privatize config options which, if used, would interfere with the
   * correct operation of the Viewport as the sole manager of the
   * layout of the document body.
   */

  /**
   * @cfg {Mixed} applyTo @hide
   */

  /**
   * @cfg {Boolean} allowDomMove @hide
   */

  /**
   * @cfg {Boolean} hideParent @hide
   */

  /**
   * @cfg {Mixed} renderTo @hide
   */

  /**
   * @cfg {Boolean} hideParent @hide
   */

  /**
   * @cfg {Number} height @hide
   */

  /**
   * @cfg {Number} width @hide
   */

  /**
   * @cfg {Boolean} autoHeight @hide
   */

  /**
   * @cfg {Boolean} autoWidth @hide
   */

  /**
   * @cfg {Boolean} deferHeight @hide
   */

  /**
   * @cfg {Boolean} monitorResize @hide
   */
  initComponent: function initComponent() {
    Ext.Viewport.superclass.initComponent.call(this);
    document.getElementsByTagName('html')[0].className += ' x-viewport';
    this.el = Ext.getBody();
    this.el.setHeight = Ext.emptyFn;
    this.el.setWidth = Ext.emptyFn;
    this.el.setSize = Ext.emptyFn;
    this.el.dom.scroll = 'no';
    this.allowDomMove = false;
    this.autoWidth = true;
    this.autoHeight = true;
    Ext.EventManager.onWindowResize(this.fireResize, this);
    this.renderTo = this.el;
  },
  fireResize: function fireResize(w, h) {
    this.fireEvent('resize', this, w, h, w, h);
  }
});
Ext.reg('viewport', Ext.Viewport);

/***/ }),
/* 773 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Panel
 * @extends Ext.Container
 * <p>Panel is a container that has specific functionality and structural components that make
 * it the perfect building block for application-oriented user interfaces.</p>
 * <p>Panels are, by virtue of their inheritance from {@link Ext.Container}, capable
 * of being configured with a {@link Ext.Container#layout layout}, and containing child Components.</p>
 * <p>When either specifying child {@link Ext.Component#items items} of a Panel, or dynamically {@link Ext.Container#add adding} Components
 * to a Panel, remember to consider how you wish the Panel to arrange those child elements, and whether
 * those child elements need to be sized using one of Ext's built-in <code><b>{@link Ext.Container#layout layout}</b></code> schemes. By
 * default, Panels use the {@link Ext.layout.ContainerLayout ContainerLayout} scheme. This simply renders
 * child components, appending them one after the other inside the Container, and <b>does not apply any sizing</b>
 * at all.</p>
 * <p>A Panel may also contain {@link #bbar bottom} and {@link #tbar top} toolbars, along with separate
 * {@link #header}, {@link #footer} and {@link #body} sections (see {@link #frame} for additional
 * information).</p>
 * <p>Panel also provides built-in {@link #collapsible expandable and collapsible behavior}, along with
 * a variety of {@link #tools prebuilt tool buttons} that can be wired up to provide other customized
 * behavior.  Panels can be easily dropped into any {@link Ext.Container Container} or layout, and the
 * layout and rendering pipeline is {@link Ext.Container#add completely managed by the framework}.</p>
 * @constructor
 * @param {Object} config The config object
 * @xtype panel
 */
Ext.Panel = Ext.extend(Ext.Container, {
  /**
   * The Panel's header {@link Ext.Element Element}. Read-only.
   * <p>This Element is used to house the {@link #title} and {@link #tools}</p>
   * <br><p><b>Note</b>: see the Note for <code>{@link Ext.Component#el el}</code> also.</p>
   * @type Ext.Element
   * @property header
   */

  /**
   * The Panel's body {@link Ext.Element Element} which may be used to contain HTML content.
   * The content may be specified in the {@link #html} config, or it may be loaded using the
   * {@link autoLoad} config, or through the Panel's {@link #getUpdater Updater}. Read-only.
   * <p>If this is used to load visible HTML elements in either way, then
   * the Panel may not be used as a Layout for hosting nested Panels.</p>
   * <p>If this Panel is intended to be used as the host of a Layout (See {@link #layout}
   * then the body Element must not be loaded or changed - it is under the control
   * of the Panel's Layout.
   * <br><p><b>Note</b>: see the Note for <code>{@link Ext.Component#el el}</code> also.</p>
   * @type Ext.Element
   * @property body
   */

  /**
   * The Panel's bwrap {@link Ext.Element Element} used to contain other Panel elements
   * (tbar, body, bbar, footer). See {@link #bodyCfg}. Read-only.
   * @type Ext.Element
   * @property bwrap
   */

  /**
   * True if this panel is collapsed. Read-only.
   * @type Boolean
   * @property collapsed
   */

  /**
   * @cfg {Object} bodyCfg
   * <p>A {@link Ext.DomHelper DomHelper} element specification object may be specified for any
   * Panel Element.</p>
   * <p>By default, the Default element in the table below will be used for the html markup to
   * create a child element with the commensurate Default class name (<code>baseCls</code> will be
   * replaced by <code>{@link #baseCls}</code>):</p>
   * <pre>
   * Panel      Default  Default             Custom      Additional       Additional
   * Element    element  class               element     class            style
   * ========   ==========================   =========   ==============   ===========
   * {@link #header}     div      {@link #baseCls}+'-header'   {@link #headerCfg}   headerCssClass   headerStyle
   * {@link #bwrap}      div      {@link #baseCls}+'-bwrap'     {@link #bwrapCfg}    bwrapCssClass    bwrapStyle
   * + tbar     div      {@link #baseCls}+'-tbar'       {@link #tbarCfg}     tbarCssClass     tbarStyle
   * + {@link #body}     div      {@link #baseCls}+'-body'       {@link #bodyCfg}     {@link #bodyCssClass}     {@link #bodyStyle}
   * + bbar     div      {@link #baseCls}+'-bbar'       {@link #bbarCfg}     bbarCssClass     bbarStyle
   * + {@link #footer}   div      {@link #baseCls}+'-footer'   {@link #footerCfg}   footerCssClass   footerStyle
   * </pre>
   * <p>Configuring a Custom element may be used, for example, to force the {@link #body} Element
   * to use a different form of markup than is created by default. An example of this might be
   * to {@link Ext.Element#createChild create a child} Panel containing a custom content, such as
   * a header, or forcing centering of all Panel content by having the body be a &lt;center&gt;
   * element:</p>
   * <pre><code>
  new Ext.Panel({
  title: 'Message Title',
  renderTo: Ext.getBody(),
  width: 200, height: 130,
  <b>bodyCfg</b>: {
      tag: 'center',
      cls: 'x-panel-body',  // Default class not applied if Custom element specified
      html: 'Message'
  },
  footerCfg: {
      tag: 'h2',
      cls: 'x-panel-footer'        // same as the Default class
      html: 'footer html'
  },
  footerCssClass: 'custom-footer', // additional css class, see {@link Ext.element#addClass addClass}
  footerStyle:    'background-color:red' // see {@link #bodyStyle}
  });
   * </code></pre>
   * <p>The example above also explicitly creates a <code>{@link #footer}</code> with custom markup and
   * styling applied.</p>
   */

  /**
   * @cfg {Object} headerCfg
   * <p>A {@link Ext.DomHelper DomHelper} element specification object specifying the element structure
   * of this Panel's {@link #header} Element.  See <code>{@link #bodyCfg}</code> also.</p>
   */

  /**
   * @cfg {Object} bwrapCfg
   * <p>A {@link Ext.DomHelper DomHelper} element specification object specifying the element structure
   * of this Panel's {@link #bwrap} Element.  See <code>{@link #bodyCfg}</code> also.</p>
   */

  /**
   * @cfg {Object} tbarCfg
   * <p>A {@link Ext.DomHelper DomHelper} element specification object specifying the element structure
   * of this Panel's {@link #tbar} Element.  See <code>{@link #bodyCfg}</code> also.</p>
   */

  /**
   * @cfg {Object} bbarCfg
   * <p>A {@link Ext.DomHelper DomHelper} element specification object specifying the element structure
   * of this Panel's {@link #bbar} Element.  See <code>{@link #bodyCfg}</code> also.</p>
   */

  /**
   * @cfg {Object} footerCfg
   * <p>A {@link Ext.DomHelper DomHelper} element specification object specifying the element structure
   * of this Panel's {@link #footer} Element.  See <code>{@link #bodyCfg}</code> also.</p>
   */

  /**
   * @cfg {Boolean} closable
   * Panels themselves do not directly support being closed, but some Panel subclasses do (like
   * {@link Ext.Window}) or a Panel Class within an {@link Ext.TabPanel}.  Specify <code>true</code>
   * to enable closing in such situations. Defaults to <code>false</code>.
   */

  /**
   * The Panel's footer {@link Ext.Element Element}. Read-only.
   * <p>This Element is used to house the Panel's <code>{@link #buttons}</code> or <code>{@link #fbar}</code>.</p>
   * <br><p><b>Note</b>: see the Note for <code>{@link Ext.Component#el el}</code> also.</p>
   * @type Ext.Element
   * @property footer
   */

  /**
   * @cfg {Mixed} applyTo
   * <p>The id of the node, a DOM node or an existing Element corresponding to a DIV that is already present in
   * the document that specifies some panel-specific structural markup.  When <code>applyTo</code> is used,
   * constituent parts of the panel can be specified by CSS class name within the main element, and the panel
   * will automatically create those components from that markup. Any required components not specified in the
   * markup will be autogenerated if necessary.</p>
   * <p>The following class names are supported (baseCls will be replaced by {@link #baseCls}):</p>
   * <ul><li>baseCls + '-header'</li>
   * <li>baseCls + '-header-text'</li>
   * <li>baseCls + '-bwrap'</li>
   * <li>baseCls + '-tbar'</li>
   * <li>baseCls + '-body'</li>
   * <li>baseCls + '-bbar'</li>
   * <li>baseCls + '-footer'</li></ul>
   * <p>Using this config, a call to render() is not required.  If applyTo is specified, any value passed for
   * {@link #renderTo} will be ignored and the target element's parent node will automatically be used as the
   * panel's container.</p>
   */

  /**
   * @cfg {Object/Array} tbar
   * <p>The top toolbar of the panel. This can be a {@link Ext.Toolbar} object, a toolbar config, or an array of
   * buttons/button configs to be added to the toolbar.  Note that this is not available as a property after render.
   * To access the top toolbar after render, use {@link #getTopToolbar}.</p>
   * <p><b>Note:</b> Although a Toolbar may contain Field components, these will <b>not</b> be updated by a load
   * of an ancestor FormPanel. A Panel's toolbars are not part of the standard Container->Component hierarchy, and
   * so are not scanned to collect form items. However, the values <b>will</b> be submitted because form
   * submission parameters are collected from the DOM tree.</p>
   */

  /**
   * @cfg {Object/Array} bbar
   * <p>The bottom toolbar of the panel. This can be a {@link Ext.Toolbar} object, a toolbar config, or an array of
   * buttons/button configs to be added to the toolbar.  Note that this is not available as a property after render.
   * To access the bottom toolbar after render, use {@link #getBottomToolbar}.</p>
   * <p><b>Note:</b> Although a Toolbar may contain Field components, these will <b>not</b> be updated by a load
   * of an ancestor FormPanel. A Panel's toolbars are not part of the standard Container->Component hierarchy, and
   * so are not scanned to collect form items. However, the values <b>will</b> be submitted because form
   * submission parameters are collected from the DOM tree.</p>
   */

  /** @cfg {Object/Array} fbar
   * <p>A {@link Ext.Toolbar Toolbar} object, a Toolbar config, or an array of
   * {@link Ext.Button Button}s/{@link Ext.Button Button} configs, describing a {@link Ext.Toolbar Toolbar} to be rendered into this Panel's footer element.</p>
   * <p>After render, the <code>fbar</code> property will be an {@link Ext.Toolbar Toolbar} instance.</p>
   * <p>If <code>{@link #buttons}</code> are specified, they will supersede the <code>fbar</code> configuration property.</p>
   * The Panel's <code>{@link #buttonAlign}</code> configuration affects the layout of these items, for example:
   * <pre><code>
  var w = new Ext.Window({
  height: 250,
  width: 500,
  bbar: new Ext.Toolbar({
      items: [{
          text: 'bbar Left'
      },'->',{
          text: 'bbar Right'
      }]
  }),
  {@link #buttonAlign}: 'left', // anything but 'center' or 'right' and you can use '-', and '->'
                                // to control the alignment of fbar items
  fbar: [{
      text: 'fbar Left'
  },'->',{
      text: 'fbar Right'
  }]
  }).show();
   * </code></pre>
   * <p><b>Note:</b> Although a Toolbar may contain Field components, these will <b>not</b> be updated by a load
   * of an ancestor FormPanel. A Panel's toolbars are not part of the standard Container->Component hierarchy, and
   * so are not scanned to collect form items. However, the values <b>will</b> be submitted because form
   * submission parameters are collected from the DOM tree.</p>
   */

  /**
   * @cfg {Boolean} header
   * <code>true</code> to create the Panel's header element explicitly, <code>false</code> to skip creating
   * it.  If a <code>{@link #title}</code> is set the header will be created automatically, otherwise it will not.
   * If a <code>{@link #title}</code> is set but <code>header</code> is explicitly set to <code>false</code>, the header
   * will not be rendered.
   */

  /**
   * @cfg {Boolean} footer
   * <code>true</code> to create the footer element explicitly, false to skip creating it. The footer
   * will be created automatically if <code>{@link #buttons}</code> or a <code>{@link #fbar}</code> have
   * been configured.  See <code>{@link #bodyCfg}</code> for an example.
   */

  /**
   * @cfg {String} title
   * The title text to be used as innerHTML (html tags are accepted) to display in the panel
   * <code>{@link #header}</code> (defaults to ''). When a <code>title</code> is specified the
   * <code>{@link #header}</code> element will automatically be created and displayed unless
   * {@link #header} is explicitly set to <code>false</code>.  If you do not want to specify a
   * <code>title</code> at config time, but you may want one later, you must either specify a non-empty
   * <code>title</code> (a blank space ' ' will do) or <code>header:true</code> so that the container
   * element will get created.
   */

  /**
   * @cfg {Array} buttons
   * <code>buttons</code> will be used as <code>{@link Ext.Container#items items}</code> for the toolbar in
   * the footer (<code>{@link #fbar}</code>). Typically the value of this configuration property will be
   * an array of {@link Ext.Button}s or {@link Ext.Button} configuration objects.
   * If an item is configured with <code>minWidth</code> or the Panel is configured with <code>minButtonWidth</code>,
   * that width will be applied to the item.
   */

  /**
   * @cfg {Object/String/Function} autoLoad
   * A valid url spec according to the Updater {@link Ext.Updater#update} method.
   * If autoLoad is not null, the panel will attempt to load its contents
   * immediately upon render.<p>
   * The URL will become the default URL for this panel's {@link #body} element,
   * so it may be {@link Ext.Element#refresh refresh}ed at any time.</p>
   */

  /**
   * @cfg {Boolean} frame
   * <code>false</code> by default to render with plain 1px square borders. <code>true</code> to render with
   * 9 elements, complete with custom rounded corners (also see {@link Ext.Element#boxWrap}).
   * <p>The template generated for each condition is depicted below:</p><pre><code>
   *
  // frame = false
  &lt;div id="developer-specified-id-goes-here" class="x-panel">
   &lt;div class="x-panel-header">&lt;span class="x-panel-header-text">Title: (frame:false)&lt;/span>&lt;/div>
   &lt;div class="x-panel-bwrap">
      &lt;div class="x-panel-body">&lt;p>html value goes here&lt;/p>&lt;/div>
  &lt;/div>
  &lt;/div>
  // frame = true (create 9 elements)
  &lt;div id="developer-specified-id-goes-here" class="x-panel">
  &lt;div class="x-panel-tl">&lt;div class="x-panel-tr">&lt;div class="x-panel-tc">
      &lt;div class="x-panel-header">&lt;span class="x-panel-header-text">Title: (frame:true)&lt;/span>&lt;/div>
  &lt;/div>&lt;/div>&lt;/div>
   &lt;div class="x-panel-bwrap">
      &lt;div class="x-panel-ml">&lt;div class="x-panel-mr">&lt;div class="x-panel-mc">
          &lt;div class="x-panel-body">&lt;p>html value goes here&lt;/p>&lt;/div>
      &lt;/div>&lt;/div>&lt;/div>
       &lt;div class="x-panel-bl">&lt;div class="x-panel-br">&lt;div class="x-panel-bc"/>
      &lt;/div>&lt;/div>&lt;/div>
  &lt;/div>
   * </code></pre>
   */

  /**
   * @cfg {Boolean} border
   * True to display the borders of the panel's body element, false to hide them (defaults to true).  By default,
   * the border is a 2px wide inset border, but this can be further altered by setting {@link #bodyBorder} to false.
   */

  /**
   * @cfg {Boolean} bodyBorder
   * True to display an interior border on the body element of the panel, false to hide it (defaults to true).
   * This only applies when {@link #border} == true.  If border == true and bodyBorder == false, the border will display
   * as a 1px wide inset border, giving the entire body element an inset appearance.
   */

  /**
   * @cfg {String/Object/Function} bodyCssClass
   * Additional css class selector to be applied to the {@link #body} element in the format expected by
   * {@link Ext.Element#addClass} (defaults to null). See {@link #bodyCfg}.
   */

  /**
   * @cfg {String/Object/Function} bodyStyle
   * Custom CSS styles to be applied to the {@link #body} element in the format expected by
   * {@link Ext.Element#applyStyles} (defaults to null). See {@link #bodyCfg}.
   */

  /**
   * @cfg {String} iconCls
   * The CSS class selector that specifies a background image to be used as the header icon (defaults to '').
   * <p>An example of specifying a custom icon class would be something like:
   * </p><pre><code>
  // specify the property in the config for the class:
   ...
   iconCls: 'my-icon'
  // css class that specifies background image to be used as the icon image:
  .my-icon { background-image: url(../images/my-icon.gif) 0 6px no-repeat !important; }
  </code></pre>
   */

  /**
   * @cfg {Boolean} collapsible
   * True to make the panel collapsible and have the expand/collapse toggle button automatically rendered into
   * the header tool button area, false to keep the panel statically sized with no button (defaults to false).
   */

  /**
   * @cfg {Array} tools
   * An array of tool button configs to be added to the header tool area. When rendered, each tool is
   * stored as an {@link Ext.Element Element} referenced by a public property called <code><b></b>tools.<i>&lt;tool-type&gt;</i></code>
   * <p>Each tool config may contain the following properties:
   * <div class="mdetail-params"><ul>
   * <li><b>id</b> : String<div class="sub-desc"><b>Required.</b> The type
   * of tool to create. By default, this assigns a CSS class of the form <code>x-tool-<i>&lt;tool-type&gt;</i></code> to the
   * resulting tool Element. Ext provides CSS rules, and an icon sprite containing images for the tool types listed below.
   * The developer may implement custom tools by supplying alternate CSS rules and background images:
   * <ul>
   * <div class="x-tool x-tool-toggle" style="float:left; margin-right:5;"> </div><div><code> toggle</code> (Created by default when {@link #collapsible} is <code>true</code>)</div>
   * <div class="x-tool x-tool-close" style="float:left; margin-right:5;"> </div><div><code> close</code></div>
   * <div class="x-tool x-tool-minimize" style="float:left; margin-right:5;"> </div><div><code> minimize</code></div>
   * <div class="x-tool x-tool-maximize" style="float:left; margin-right:5;"> </div><div><code> maximize</code></div>
   * <div class="x-tool x-tool-restore" style="float:left; margin-right:5;"> </div><div><code> restore</code></div>
   * <div class="x-tool x-tool-gear" style="float:left; margin-right:5;"> </div><div><code> gear</code></div>
   * <div class="x-tool x-tool-pin" style="float:left; margin-right:5;"> </div><div><code> pin</code></div>
   * <div class="x-tool x-tool-unpin" style="float:left; margin-right:5;"> </div><div><code> unpin</code></div>
   * <div class="x-tool x-tool-right" style="float:left; margin-right:5;"> </div><div><code> right</code></div>
   * <div class="x-tool x-tool-left" style="float:left; margin-right:5;"> </div><div><code> left</code></div>
   * <div class="x-tool x-tool-up" style="float:left; margin-right:5;"> </div><div><code> up</code></div>
   * <div class="x-tool x-tool-down" style="float:left; margin-right:5;"> </div><div><code> down</code></div>
   * <div class="x-tool x-tool-refresh" style="float:left; margin-right:5;"> </div><div><code> refresh</code></div>
   * <div class="x-tool x-tool-minus" style="float:left; margin-right:5;"> </div><div><code> minus</code></div>
   * <div class="x-tool x-tool-plus" style="float:left; margin-right:5;"> </div><div><code> plus</code></div>
   * <div class="x-tool x-tool-help" style="float:left; margin-right:5;"> </div><div><code> help</code></div>
   * <div class="x-tool x-tool-search" style="float:left; margin-right:5;"> </div><div><code> search</code></div>
   * <div class="x-tool x-tool-save" style="float:left; margin-right:5;"> </div><div><code> save</code></div>
   * <div class="x-tool x-tool-print" style="float:left; margin-right:5;"> </div><div><code> print</code></div>
   * </ul></div></li>
   * <li><b>handler</b> : Function<div class="sub-desc"><b>Required.</b> The function to
   * call when clicked. Arguments passed are:<ul>
   * <li><b>event</b> : Ext.EventObject<div class="sub-desc">The click event.</div></li>
   * <li><b>toolEl</b> : Ext.Element<div class="sub-desc">The tool Element.</div></li>
   * <li><b>panel</b> : Ext.Panel<div class="sub-desc">The host Panel</div></li>
   * <li><b>tc</b> : Object<div class="sub-desc">The tool configuration object</div></li>
   * </ul></div></li>
   * <li><b>stopEvent</b> : Boolean<div class="sub-desc">Defaults to true. Specify as false to allow click event to propagate.</div></li>
   * <li><b>scope</b> : Object<div class="sub-desc">The scope in which to call the handler.</div></li>
   * <li><b>qtip</b> : String/Object<div class="sub-desc">A tip string, or
   * a config argument to {@link Ext.QuickTip#register}</div></li>
   * <li><b>hidden</b> : Boolean<div class="sub-desc">True to initially render hidden.</div></li>
   * <li><b>on</b> : Object<div class="sub-desc">A listener config object specifiying
   * event listeners in the format of an argument to {@link #addListener}</div></li>
   * </ul></div>
   * <p>Note that, apart from the toggle tool which is provided when a panel is collapsible, these
   * tools only provide the visual button. Any required functionality must be provided by adding
   * handlers that implement the necessary behavior.</p>
   * <p>Example usage:</p>
   * <pre><code>
  tools:[{
  id:'refresh',
  qtip: 'Refresh form Data',
  // hidden:true,
  handler: function(event, toolEl, panel){
      // refresh logic
  }
  },
  {
  id:'help',
  qtip: 'Get Help',
  handler: function(event, toolEl, panel){
      // whatever
  }
  }]
  </code></pre>
   * <p>For the custom id of <code>'help'</code> define two relevant css classes with a link to
   * a 15x15 image:</p>
   * <pre><code>
  .x-tool-help {background-image: url(images/help.png);}
  .x-tool-help-over {background-image: url(images/help_over.png);}
  // if using an image sprite:
  .x-tool-help {background-image: url(images/help.png) no-repeat 0 0;}
  .x-tool-help-over {background-position:-15px 0;}
  </code></pre>
   */

  /**
   * @cfg {Ext.Template/Ext.XTemplate} toolTemplate
   * <p>A Template used to create {@link #tools} in the {@link #header} Element. Defaults to:</p><pre><code>
  new Ext.Template('&lt;div class="x-tool x-tool-{id}">&amp;#160;&lt;/div>')</code></pre>
   * <p>This may may be overridden to provide a custom DOM structure for tools based upon a more
   * complex XTemplate. The template's data is a single tool configuration object (Not the entire Array)
   * as specified in {@link #tools}.  In the following example an &lt;a> tag is used to provide a
   * visual indication when hovering over the tool:</p><pre><code>
  var win = new Ext.Window({
  tools: [{
      id: 'download',
      href: '/MyPdfDoc.pdf'
  }],
  toolTemplate: new Ext.XTemplate(
      '&lt;tpl if="id==\'download\'">',
          '&lt;a class="x-tool x-tool-pdf" href="{href}">&lt;/a>',
      '&lt;/tpl>',
      '&lt;tpl if="id!=\'download\'">',
          '&lt;div class="x-tool x-tool-{id}">&amp;#160;&lt;/div>',
      '&lt;/tpl>'
  ),
  width:500,
  height:300,
  closeAction:'hide'
  });</code></pre>
   * <p>Note that the CSS class 'x-tool-pdf' should have an associated style rule which provides an
   * appropriate background image, something like:</p>
  <pre><code>
  a.x-tool-pdf {background-image: url(../shared/extjs/images/pdf.gif)!important;}
  </code></pre>
   */

  /**
   * @cfg {Boolean} hideCollapseTool
   * <code>true</code> to hide the expand/collapse toggle button when <code>{@link #collapsible} == true</code>,
   * <code>false</code> to display it (defaults to <code>false</code>).
   */

  /**
   * @cfg {Boolean} titleCollapse
   * <code>true</code> to allow expanding and collapsing the panel (when <code>{@link #collapsible} = true</code>)
   * by clicking anywhere in the header bar, <code>false</code>) to allow it only by clicking to tool button
   * (defaults to <code>false</code>)). If this panel is a child item of a border layout also see the
   * {@link Ext.layout.BorderLayout.Region BorderLayout.Region}
   * <code>{@link Ext.layout.BorderLayout.Region#floatable floatable}</code> config option.
   */

  /**
   * @cfg {Mixed} floating
   * <p>This property is used to configure the underlying {@link Ext.Layer}. Acceptable values for this
   * configuration property are:</p><div class="mdetail-params"><ul>
   * <li><b><code>false</code></b> : <b>Default.</b><div class="sub-desc">Display the panel inline where it is
   * rendered.</div></li>
   * <li><b><code>true</code></b> : <div class="sub-desc">Float the panel (absolute position it with automatic
   * shimming and shadow).<ul>
   * <div class="sub-desc">Setting floating to true will create an Ext.Layer for this panel and display the
   * panel at negative offsets so that it is hidden.</div>
   * <div class="sub-desc">Since the panel will be absolute positioned, the position must be set explicitly
   * <i>after</i> render (e.g., <code>myPanel.setPosition(100,100);</code>).</div>
   * <div class="sub-desc"><b>Note</b>: when floating a panel you should always assign a fixed width,
   * otherwise it will be auto width and will expand to fill to the right edge of the viewport.</div>
   * </ul></div></li>
   * <li><b><code>{@link Ext.Layer object}</code></b> : <div class="sub-desc">The specified object will be used
   * as the configuration object for the {@link Ext.Layer} that will be created.</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Boolean/String} shadow
   * <code>true</code> (or a valid Ext.Shadow {@link Ext.Shadow#mode} value) to display a shadow behind the
   * panel, <code>false</code> to display no shadow (defaults to <code>'sides'</code>).  Note that this option
   * only applies when <code>{@link #floating} = true</code>.
   */

  /**
   * @cfg {Number} shadowOffset
   * The number of pixels to offset the shadow if displayed (defaults to <code>4</code>). Note that this
   * option only applies when <code>{@link #floating} = true</code>.
   */

  /**
   * @cfg {Boolean} shim
   * <code>false</code> to disable the iframe shim in browsers which need one (defaults to <code>true</code>).
   * Note that this option only applies when <code>{@link #floating} = true</code>.
   */

  /**
   * @cfg {Object/Array} keys
   * A {@link Ext.KeyMap} config object (in the format expected by {@link Ext.KeyMap#addBinding}
   * used to assign custom key handling to this panel (defaults to <code>null</code>).
   */

  /**
   * @cfg {Boolean/Object} draggable
   * <p><code>true</code> to enable dragging of this Panel (defaults to <code>false</code>).</p>
   * <p>For custom drag/drop implementations, an <b>Ext.Panel.DD</b> config could also be passed
   * in this config instead of <code>true</code>. Ext.Panel.DD is an internal, undocumented class which
   * moves a proxy Element around in place of the Panel's element, but provides no other behaviour
   * during dragging or on drop. It is a subclass of {@link Ext.dd.DragSource}, so behaviour may be
   * added by implementing the interface methods of {@link Ext.dd.DragDrop} e.g.:
   * <pre><code>
  new Ext.Panel({
  title: 'Drag me',
  x: 100,
  y: 100,
  renderTo: Ext.getBody(),
  floating: true,
  frame: true,
  width: 400,
  height: 200,
  draggable: {
  //      Config option of Ext.Panel.DD class.
  //      It&#39;s a floating Panel, so do not show a placeholder proxy in the original position.
      insertProxy: false,
  //      Called for each mousemove event while dragging the DD object.
      onDrag : function(e){
  //          Record the x,y position of the drag proxy so that we can
  //          position the Panel at end of drag.
          var pel = this.proxy.getEl();
          this.x = pel.getLeft(true);
          this.y = pel.getTop(true);
  //          Keep the Shadow aligned if there is one.
          var s = this.panel.getEl().shadow;
          if (s) {
              s.realign(this.x, this.y, pel.getWidth(), pel.getHeight());
          }
      },
  //      Called on the mouseup event.
      endDrag : function(e){
          this.panel.setPosition(this.x, this.y);
      }
  }
  }).show();
  </code></pre>
   */

  /**
   * @cfg {Boolean} disabled
   * Render this panel disabled (default is <code>false</code>). An important note when using the disabled
   * config on panels is that IE will often fail to initialize the disabled mask element correectly if
   * the panel's layout has not yet completed by the time the Panel is disabled during the render process.
   * If you experience this issue, you may need to instead use the {@link #afterlayout} event to initialize
   * the disabled state:
   * <pre><code>
  new Ext.Panel({
  ...
  listeners: {
      'afterlayout': {
          fn: function(p){
              p.disable();
          },
          single: true // important, as many layouts can occur
      }
  }
  });
  </code></pre>
   */

  /**
   * @cfg {Boolean} autoHeight
   * <code>true</code> to use height:'auto', <code>false</code> to use fixed height (defaults to <code>false</code>).
   * <b>Note</b>: Setting <code>autoHeight: true</code> means that the browser will manage the panel's height
   * based on its contents, and that Ext will not manage it at all. If the panel is within a layout that
   * manages dimensions (<code>fit</code>, <code>border</code>, etc.) then setting <code>autoHeight: true</code>
   * can cause issues with scrolling and will not generally work as expected since the panel will take
   * on the height of its contents rather than the height required by the Ext layout.
   */

  /**
   * @cfg {String} baseCls
   * The base CSS class to apply to this panel's element (defaults to <code>'x-panel'</code>).
   * <p>Another option available by default is to specify <code>'x-plain'</code> which strips all styling
   * except for required attributes for Ext layouts to function (e.g. overflow:hidden).
   * See <code>{@link #unstyled}</code> also.</p>
   */
  baseCls: 'x-panel',

  /**
   * @cfg {String} collapsedCls
   * A CSS class to add to the panel's element after it has been collapsed (defaults to
   * <code>'x-panel-collapsed'</code>).
   */
  collapsedCls: 'x-panel-collapsed',

  /**
   * @cfg {Boolean} maskDisabled
   * <code>true</code> to mask the panel when it is {@link #disabled}, <code>false</code> to not mask it (defaults
   * to <code>true</code>).  Either way, the panel will always tell its contained elements to disable themselves
   * when it is disabled, but masking the panel can provide an additional visual cue that the panel is
   * disabled.
   */
  maskDisabled: true,

  /**
   * @cfg {Boolean} animCollapse
   * <code>true</code> to animate the transition when the panel is collapsed, <code>false</code> to skip the
   * animation (defaults to <code>true</code> if the {@link Ext.Fx} class is available, otherwise <code>false</code>).
   */
  animCollapse: Ext.enableFx,

  /**
   * @cfg {Boolean} headerAsText
   * <code>true</code> to display the panel <code>{@link #title}</code> in the <code>{@link #header}</code>,
   * <code>false</code> to hide it (defaults to <code>true</code>).
   */
  headerAsText: true,

  /**
   * @cfg {String} buttonAlign
   * The alignment of any {@link #buttons} added to this panel.  Valid values are <code>'right'</code>,
   * <code>'left'</code> and <code>'center'</code> (defaults to <code>'right'</code>).
   */
  buttonAlign: 'right',

  /**
   * @cfg {Boolean} collapsed
   * <code>true</code> to render the panel collapsed, <code>false</code> to render it expanded (defaults to
   * <code>false</code>).
   */
  collapsed: false,

  /**
   * @cfg {Boolean} collapseFirst
   * <code>true</code> to make sure the collapse/expand toggle button always renders first (to the left of)
   * any other tools in the panel's title bar, <code>false</code> to render it last (defaults to <code>true</code>).
   */
  collapseFirst: true,

  /**
   * @cfg {Number} minButtonWidth
   * Minimum width in pixels of all {@link #buttons} in this panel (defaults to <code>75</code>)
   */
  minButtonWidth: 75,

  /**
   * @cfg {Boolean} unstyled
   * Overrides the <code>{@link #baseCls}</code> setting to <code>{@link #baseCls} = 'x-plain'</code> which renders
   * the panel unstyled except for required attributes for Ext layouts to function (e.g. overflow:hidden).
   */

  /**
   * @cfg {String} elements
   * A comma-delimited list of panel elements to initialize when the panel is rendered.  Normally, this list will be
   * generated automatically based on the items added to the panel at config time, but sometimes it might be useful to
   * make sure a structural element is rendered even if not specified at config time (for example, you may want
   * to add a button or toolbar dynamically after the panel has been rendered).  Adding those elements to this
   * list will allocate the required placeholders in the panel when it is rendered.  Valid values are<div class="mdetail-params"><ul>
   * <li><code>header</code></li>
   * <li><code>tbar</code> (top bar)</li>
   * <li><code>body</code></li>
   * <li><code>bbar</code> (bottom bar)</li>
   * <li><code>footer</code></li>
   * </ul></div>
   * Defaults to '<code>body</code>'.
   */
  elements: 'body',

  /**
   * @cfg {Boolean} preventBodyReset
   * Defaults to <code>false</code>.  When set to <code>true</code>, an extra css class <code>'x-panel-normal'</code>
   * will be added to the panel's element, effectively applying css styles suggested by the W3C
   * (see http://www.w3.org/TR/CSS21/sample.html) to the Panel's <b>body</b> element (not the header,
   * footer, etc.).
   */
  preventBodyReset: false,

  /**
   * @cfg {Number/String} padding
   * A shortcut for setting a padding style on the body element. The value can either be
   * a number to be applied to all sides, or a normal css string describing padding.
   * Defaults to <tt>undefined</tt>.
   *
   */
  padding: undefined,

  /** @cfg {String} resizeEvent
   * The event to listen to for resizing in layouts. Defaults to <tt>'bodyresize'</tt>.
   */
  resizeEvent: 'bodyresize',
  // protected - these could be used to customize the behavior of the window,
  // but changing them would not be useful without further mofifications and
  // could lead to unexpected or undesirable results.
  toolTarget: 'header',
  collapseEl: 'bwrap',
  slideAnchor: 't',
  disabledClass: '',
  // private, notify box this class will handle heights
  deferHeight: true,
  // private
  expandDefaults: {
    duration: 0.25
  },
  // private
  collapseDefaults: {
    duration: 0.25
  },
  // private
  initComponent: function initComponent() {
    Ext.Panel.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event bodyresize
     * Fires after the Panel has been resized.
     * @param {Ext.Panel} p the Panel which has been resized.
     * @param {Number} width The Panel body's new width.
     * @param {Number} height The Panel body's new height.
     */
    'bodyresize',
    /**
     * @event titlechange
     * Fires after the Panel title has been {@link #title set} or {@link #setTitle changed}.
     * @param {Ext.Panel} p the Panel which has had its title changed.
     * @param {String} The new title.
     */
    'titlechange',
    /**
     * @event iconchange
     * Fires after the Panel icon class has been {@link #iconCls set} or {@link #setIconClass changed}.
     * @param {Ext.Panel} p the Panel which has had its {@link #iconCls icon class} changed.
     * @param {String} The new icon class.
     * @param {String} The old icon class.
     */
    'iconchange',
    /**
     * @event collapse
     * Fires after the Panel has been collapsed.
     * @param {Ext.Panel} p the Panel that has been collapsed.
     */
    'collapse',
    /**
     * @event expand
     * Fires after the Panel has been expanded.
     * @param {Ext.Panel} p The Panel that has been expanded.
     */
    'expand',
    /**
     * @event beforecollapse
     * Fires before the Panel is collapsed.  A handler can return false to cancel the collapse.
     * @param {Ext.Panel} p the Panel being collapsed.
     * @param {Boolean} animate True if the collapse is animated, else false.
     */
    'beforecollapse',
    /**
     * @event beforeexpand
     * Fires before the Panel is expanded.  A handler can return false to cancel the expand.
     * @param {Ext.Panel} p The Panel being expanded.
     * @param {Boolean} animate True if the expand is animated, else false.
     */
    'beforeexpand',
    /**
     * @event beforeclose
     * Fires before the Panel is closed.  Note that Panels do not directly support being closed, but some
     * Panel subclasses do (like {@link Ext.Window}) or a Panel within a Ext.TabPanel.  This event only
     * applies to such subclasses.
     * A handler can return false to cancel the close.
     * @param {Ext.Panel} p The Panel being closed.
     */
    'beforeclose',
    /**
     * @event close
     * Fires after the Panel is closed.  Note that Panels do not directly support being closed, but some
     * Panel subclasses do (like {@link Ext.Window}) or a Panel within a Ext.TabPanel.
     * @param {Ext.Panel} p The Panel that has been closed.
     */
    'close',
    /**
     * @event activate
     * Fires after the Panel has been visually activated.
     * Note that Panels do not directly support being activated, but some Panel subclasses
     * do (like {@link Ext.Window}). Panels which are child Components of a TabPanel fire the
     * activate and deactivate events under the control of the TabPanel.
     * @param {Ext.Panel} p The Panel that has been activated.
     */
    'activate',
    /**
     * @event deactivate
     * Fires after the Panel has been visually deactivated.
     * Note that Panels do not directly support being deactivated, but some Panel subclasses
     * do (like {@link Ext.Window}). Panels which are child Components of a TabPanel fire the
     * activate and deactivate events under the control of the TabPanel.
     * @param {Ext.Panel} p The Panel that has been deactivated.
     */
    'deactivate');

    if (this.unstyled) {
      this.baseCls = 'x-plain';
    }

    this.toolbars = []; // shortcuts

    if (this.tbar) {
      this.elements += ',tbar';
      this.topToolbar = this.createToolbar(this.tbar);
      delete this.tbar;
    }

    if (this.bbar) {
      this.elements += ',bbar';
      this.bottomToolbar = this.createToolbar(this.bbar);
      delete this.bbar;
    }

    if (this.header === true) {
      this.elements += ',header';
      delete this.header;
    } else if (this.headerCfg || this.title && this.header !== false) {
      this.elements += ',header';
    }

    if (this.footerCfg || this.footer === true) {
      this.elements += ',footer';
      delete this.footer;
    }

    if (this.buttons) {
      this.fbar = this.buttons;
      delete this.buttons;
    }

    if (this.fbar) {
      this.createFbar(this.fbar);
    }

    if (this.autoLoad) {
      this.on('render', this.doAutoLoad, this, {
        delay: 10
      });
    }
  },
  // private
  createFbar: function createFbar(fbar) {
    var min = this.minButtonWidth;
    this.elements += ',footer';
    this.fbar = this.createToolbar(fbar, {
      buttonAlign: this.buttonAlign,
      toolbarCls: 'x-panel-fbar',
      enableOverflow: false,
      defaults: function defaults(c) {
        return {
          minWidth: c.minWidth || min
        };
      }
    }); //@compat addButton and buttons could possibly be removed
    //@target 4.0

    /**
     * This Panel's Array of buttons as created from the <code>{@link #buttons}</code>
     * config property. Read only.
     * @type Array
     * @property buttons
     */

    this.fbar.items.each(function (c) {
      c.minWidth = c.minWidth || this.minButtonWidth;
    }, this);
    this.buttons = this.fbar.items.items;
  },
  // private
  createToolbar: function createToolbar(tb, options) {
    var result; // Convert array to proper toolbar config

    if (Ext.isArray(tb)) {
      tb = {
        items: tb
      };
    }

    result = tb.events ? Ext.apply(tb, options) : this.createComponent(Ext.apply({}, tb, options), 'toolbar');
    this.toolbars.push(result);
    return result;
  },
  // private
  createElement: function createElement(name, pnode) {
    if (this[name]) {
      pnode.appendChild(this[name].dom);
      return;
    }

    if (name === 'bwrap' || this.elements.indexOf(name) != -1) {
      if (this[name + 'Cfg']) {
        this[name] = Ext.fly(pnode).createChild(this[name + 'Cfg']);
      } else {
        var el = document.createElement('div');
        el.className = this[name + 'Cls'];
        this[name] = Ext.get(pnode.appendChild(el));
      }

      if (this[name + 'CssClass']) {
        this[name].addClass(this[name + 'CssClass']);
      }

      if (this[name + 'Style']) {
        this[name].applyStyles(this[name + 'Style']);
      }
    }
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.Panel.superclass.onRender.call(this, ct, position);
    this.createClasses();
    var el = this.el,
        d = el.dom,
        bw,
        ts;

    if (this.collapsible && !this.hideCollapseTool) {
      this.tools = this.tools ? this.tools.slice(0) : [];
      this.tools[this.collapseFirst ? 'unshift' : 'push']({
        id: 'toggle',
        handler: this.toggleCollapse,
        scope: this
      });
    }

    if (this.tools) {
      ts = this.tools;
      this.elements += this.header !== false ? ',header' : '';
    }

    this.tools = {};
    el.addClass(this.baseCls);

    if (d.firstChild) {
      // existing markup
      this.header = el.down('.' + this.headerCls);
      this.bwrap = el.down('.' + this.bwrapCls);
      var cp = this.bwrap ? this.bwrap : el;
      this.tbar = cp.down('.' + this.tbarCls);
      this.body = cp.down('.' + this.bodyCls);
      this.bbar = cp.down('.' + this.bbarCls);
      this.footer = cp.down('.' + this.footerCls);
      this.fromMarkup = true;
    }

    if (this.preventBodyReset === true) {
      el.addClass('x-panel-reset');
    }

    if (this.cls) {
      el.addClass(this.cls);
    }

    if (this.buttons) {
      this.elements += ',footer';
    } // This block allows for maximum flexibility and performance when using existing markup
    // framing requires special markup


    if (this.frame) {
      el.insertHtml('afterBegin', String.format(Ext.Element.boxMarkup, this.baseCls));
      this.createElement('header', d.firstChild.firstChild.firstChild);
      this.createElement('bwrap', d); // append the mid and bottom frame to the bwrap

      bw = this.bwrap.dom;
      var ml = d.childNodes[1],
          bl = d.childNodes[2];
      bw.appendChild(ml);
      bw.appendChild(bl);
      var mc = bw.firstChild.firstChild.firstChild;
      this.createElement('tbar', mc);
      this.createElement('body', mc);
      this.createElement('bbar', mc);
      this.createElement('footer', bw.lastChild.firstChild.firstChild);

      if (!this.footer) {
        this.bwrap.dom.lastChild.className += ' x-panel-nofooter';
      }
      /*
       * Store a reference to this element so:
       * a) We aren't looking it up all the time
       * b) The last element is reported incorrectly when using a loadmask
       */


      this.ft = Ext.get(this.bwrap.dom.lastChild);
      this.mc = Ext.get(mc);
    } else {
      this.createElement('header', d);
      this.createElement('bwrap', d); // append the mid and bottom frame to the bwrap

      bw = this.bwrap.dom;
      this.createElement('tbar', bw);
      this.createElement('body', bw);
      this.createElement('bbar', bw);
      this.createElement('footer', bw);

      if (!this.header) {
        this.body.addClass(this.bodyCls + '-noheader');

        if (this.tbar) {
          this.tbar.addClass(this.tbarCls + '-noheader');
        }
      }
    }

    if (Ext.isDefined(this.padding)) {
      this.body.setStyle('padding', this.body.addUnits(this.padding));
    }

    if (this.border === false) {
      this.el.addClass(this.baseCls + '-noborder');
      this.body.addClass(this.bodyCls + '-noborder');

      if (this.header) {
        this.header.addClass(this.headerCls + '-noborder');
      }

      if (this.footer) {
        this.footer.addClass(this.footerCls + '-noborder');
      }

      if (this.tbar) {
        this.tbar.addClass(this.tbarCls + '-noborder');
      }

      if (this.bbar) {
        this.bbar.addClass(this.bbarCls + '-noborder');
      }
    }

    if (this.bodyBorder === false) {
      this.body.addClass(this.bodyCls + '-noborder');
    }

    this.bwrap.enableDisplayMode('block');

    if (this.header) {
      this.header.unselectable(); // for tools, we need to wrap any existing header markup

      if (this.headerAsText) {
        this.header.dom.innerHTML = '<span class="' + this.headerTextCls + '">' + this.header.dom.innerHTML + '</span>';

        if (this.iconCls) {
          this.setIconClass(this.iconCls);
        }
      }
    }

    if (this.floating) {
      this.makeFloating(this.floating);
    }

    if (this.collapsible && this.titleCollapse && this.header) {
      this.mon(this.header, 'click', this.toggleCollapse, this);
      this.header.setStyle('cursor', 'pointer');
    }

    if (ts) {
      this.addTool.apply(this, ts);
    } // Render Toolbars.


    if (this.fbar) {
      this.footer.addClass('x-panel-btns');
      this.fbar.ownerCt = this;
      this.fbar.render(this.footer);
      this.footer.createChild({
        cls: 'x-clear'
      });
    }

    if (this.tbar && this.topToolbar) {
      this.topToolbar.ownerCt = this;
      this.topToolbar.render(this.tbar);
    }

    if (this.bbar && this.bottomToolbar) {
      this.bottomToolbar.ownerCt = this;
      this.bottomToolbar.render(this.bbar);
    }
  },

  /**
   * Sets the CSS class that provides the icon image for this panel.  This method will replace any existing
   * icon class if one has already been set and fire the {@link #iconchange} event after completion.
   * @param {String} cls The new CSS class name
   */
  setIconClass: function setIconClass(cls) {
    var old = this.iconCls;
    this.iconCls = cls;

    if (this.rendered && this.header) {
      if (this.frame) {
        this.header.addClass('x-panel-icon');
        this.header.replaceClass(old, this.iconCls);
      } else {
        var hd = this.header,
            img = hd.child('img.x-panel-inline-icon');

        if (img) {
          Ext.fly(img).replaceClass(old, this.iconCls);
        } else {
          Ext.DomHelper.insertBefore(hd.dom.firstChild, {
            tag: 'img',
            src: Ext.BLANK_IMAGE_URL,
            cls: 'x-panel-inline-icon ' + this.iconCls
          });
        }
      }
    }

    this.fireEvent('iconchange', this, cls, old);
  },
  // private
  makeFloating: function makeFloating(cfg) {
    this.floating = true;
    this.el = new Ext.Layer(Ext.apply({}, cfg, {
      shadow: Ext.isDefined(this.shadow) ? this.shadow : 'sides',
      shadowOffset: this.shadowOffset,
      constrain: false,
      shim: this.shim === false ? false : undefined
    }), this.el);
  },

  /**
   * Returns the {@link Ext.Toolbar toolbar} from the top (<code>{@link #tbar}</code>) section of the panel.
   * @return {Ext.Toolbar} The toolbar
   */
  getTopToolbar: function getTopToolbar() {
    return this.topToolbar;
  },

  /**
   * Returns the {@link Ext.Toolbar toolbar} from the bottom (<code>{@link #bbar}</code>) section of the panel.
   * @return {Ext.Toolbar} The toolbar
   */
  getBottomToolbar: function getBottomToolbar() {
    return this.bottomToolbar;
  },

  /**
   * Adds a button to this panel.  Note that this method must be called prior to rendering.  The preferred
   * approach is to add buttons via the {@link #buttons} config.
   * @param {String/Object} config A valid {@link Ext.Button} config.  A string will become the text for a default
   * button config, an object will be treated as a button config object.
   * @param {Function} handler The function to be called on button {@link Ext.Button#click}
   * @param {Object} scope The scope (<code>this</code> reference) in which the button handler function is executed. Defaults to the Button.
   * @return {Ext.Button} The button that was added
   */
  addButton: function addButton(config, handler, scope) {
    if (!this.fbar) {
      this.createFbar([]);
    }

    if (handler) {
      if (Ext.isString(config)) {
        config = {
          text: config
        };
      }

      config = Ext.apply({
        handler: handler,
        scope: scope
      }, config);
    }

    return this.fbar.add(config);
  },
  // private
  addTool: function addTool() {
    if (!this.rendered) {
      if (!this.tools) {
        this.tools = [];
      }

      Ext.each(arguments, function (arg) {
        this.tools.push(arg);
      }, this);
      return;
    } // nowhere to render tools!


    if (!this[this.toolTarget]) {
      return;
    }

    if (!this.toolTemplate) {
      // initialize the global tool template on first use
      var tt = new Ext.Template('<div class="x-tool x-tool-{id}">&#160;</div>');
      tt.disableFormats = true;
      tt.compile();
      Ext.Panel.prototype.toolTemplate = tt;
    }

    for (var i = 0, a = arguments, len = a.length; i < len; i++) {
      var tc = a[i];

      if (!this.tools[tc.id]) {
        var overCls = 'x-tool-' + tc.id + '-over';
        var t = this.toolTemplate.insertFirst(this[this.toolTarget], tc, true);
        this.tools[tc.id] = t;
        t.enableDisplayMode('block');
        this.mon(t, 'click', this.createToolHandler(t, tc, overCls, this));

        if (tc.on) {
          this.mon(t, tc.on);
        }

        if (tc.hidden) {
          t.hide();
        }

        if (tc.qtip) {
          if (Ext.isObject(tc.qtip)) {
            Ext.QuickTips.register(Ext.apply({
              target: t.id
            }, tc.qtip));
          } else {
            t.dom.qtip = tc.qtip;
          }
        }

        t.addClassOnOver(overCls);
      }
    }
  },
  onLayout: function onLayout(shallow, force) {
    Ext.Panel.superclass.onLayout.apply(this, arguments);

    if (this.hasLayout && this.toolbars.length > 0) {
      Ext.each(this.toolbars, function (tb) {
        tb.doLayout(undefined, force);
      });
      this.syncHeight();
    }
  },
  syncHeight: function syncHeight() {
    var h = this.toolbarHeight,
        bd = this.body,
        lsh = this.lastSize.height,
        sz;

    if (this.autoHeight || !Ext.isDefined(lsh) || lsh == 'auto') {
      return;
    }

    if (h != this.getToolbarHeight()) {
      h = Math.max(0, this.adjustBodyHeight(lsh - this.getFrameHeight()));
      bd.setHeight(h);
      sz = bd.getSize();
      this.toolbarHeight = this.getToolbarHeight();
      this.onBodyResize(sz.width, sz.height);
    }
  },
  // private
  onShow: function onShow() {
    if (this.floating) {
      return this.el.show();
    }

    Ext.Panel.superclass.onShow.call(this);
  },
  // private
  onHide: function onHide() {
    if (this.floating) {
      return this.el.hide();
    }

    Ext.Panel.superclass.onHide.call(this);
  },
  // private
  createToolHandler: function createToolHandler(t, tc, overCls, panel) {
    return function (e) {
      t.removeClass(overCls);

      if (tc.stopEvent !== false) {
        e.stopEvent();
      }

      if (tc.handler) {
        tc.handler.call(tc.scope || t, e, t, panel, tc);
      }
    };
  },
  // private
  afterRender: function afterRender() {
    if (this.floating && !this.hidden) {
      this.el.show();
    }

    if (this.title) {
      this.setTitle(this.title);
    }

    Ext.Panel.superclass.afterRender.call(this); // do sizing calcs last

    if (this.collapsed) {
      this.collapsed = false;
      this.collapse(false);
    }

    this.initEvents();
  },
  // private
  getKeyMap: function getKeyMap() {
    if (!this.keyMap) {
      this.keyMap = new Ext.KeyMap(this.el, this.keys);
    }

    return this.keyMap;
  },
  // private
  initEvents: function initEvents() {
    if (this.keys) {
      this.getKeyMap();
    }

    if (this.draggable) {
      this.initDraggable();
    }

    if (this.toolbars.length > 0) {
      Ext.each(this.toolbars, function (tb) {
        tb.doLayout();
        tb.on({
          scope: this,
          afterlayout: this.syncHeight,
          remove: this.syncHeight
        });
      }, this);
      this.syncHeight();
    }
  },
  // private
  initDraggable: function initDraggable() {
    /**
     * <p>If this Panel is configured {@link #draggable}, this property will contain
     * an instance of {@link Ext.dd.DragSource} which handles dragging the Panel.</p>
     * The developer must provide implementations of the abstract methods of {@link Ext.dd.DragSource}
     * in order to supply behaviour for each stage of the drag/drop process. See {@link #draggable}.
     * @type Ext.dd.DragSource.
     * @property dd
     */
    this.dd = new Ext.Panel.DD(this, Ext.isBoolean(this.draggable) ? null : this.draggable);
  },
  // private
  beforeEffect: function beforeEffect(anim) {
    if (this.floating) {
      this.el.beforeAction();
    }

    if (anim !== false) {
      this.el.addClass('x-panel-animated');
    }
  },
  // private
  afterEffect: function afterEffect(anim) {
    this.syncShadow();

    if (anim !== false) {
      this.el.removeClass('x-panel-animated');
    }
  },
  // private - wraps up an animation param with internal callbacks
  createEffect: function createEffect(a, cb, scope) {
    var o = {
      scope: scope,
      block: true
    };

    if (a === true) {
      o.callback = cb;
      return o;
    } else if (!a.callback) {
      o.callback = cb;
    } else {
      // wrap it up
      o.callback = function () {
        cb.call(scope);
        Ext.callback(a.callback, a.scope);
      };
    }

    return Ext.applyIf(o, a);
  },

  /**
   * Collapses the panel body so that it becomes hidden.  Fires the {@link #beforecollapse} event which will
   * cancel the collapse action if it returns false.
   * @param {Boolean} animate True to animate the transition, else false (defaults to the value of the
   * {@link #animCollapse} panel config)
   * @return {Ext.Panel} this
   */
  collapse: function collapse(animate) {
    if (this.collapsed || this.el.hasFxBlock() || this.fireEvent('beforecollapse', this, animate) === false) {
      return;
    }

    var doAnim = animate === true || animate !== false && this.animCollapse;
    this.beforeEffect(doAnim);
    this.onCollapse(doAnim, animate);
    return this;
  },
  // private
  onCollapse: function onCollapse(doAnim, animArg) {
    if (doAnim) {
      this[this.collapseEl].slideOut(this.slideAnchor, Ext.apply(this.createEffect(animArg || true, this.afterCollapse, this), this.collapseDefaults));
    } else {
      this[this.collapseEl].hide();
      this.afterCollapse(false);
    }
  },
  // private
  afterCollapse: function afterCollapse(anim) {
    this.collapsed = true;
    this.el.addClass(this.collapsedCls);
    this.afterEffect(anim);
    this.fireEvent('collapse', this);
  },

  /**
   * Expands the panel body so that it becomes visible.  Fires the {@link #beforeexpand} event which will
   * cancel the expand action if it returns false.
   * @param {Boolean} animate True to animate the transition, else false (defaults to the value of the
   * {@link #animCollapse} panel config)
   * @return {Ext.Panel} this
   */
  expand: function expand(animate) {
    if (!this.collapsed || this.el.hasFxBlock() || this.fireEvent('beforeexpand', this, animate) === false) {
      return;
    }

    var doAnim = animate === true || animate !== false && this.animCollapse;
    this.el.removeClass(this.collapsedCls);
    this.beforeEffect(doAnim);
    this.onExpand(doAnim, animate);
    return this;
  },
  // private
  onExpand: function onExpand(doAnim, animArg) {
    if (doAnim) {
      this[this.collapseEl].slideIn(this.slideAnchor, Ext.apply(this.createEffect(animArg || true, this.afterExpand, this), this.expandDefaults));
    } else {
      this[this.collapseEl].show();
      this.afterExpand(false);
    }
  },
  // private
  afterExpand: function afterExpand(anim) {
    this.collapsed = false;
    this.afterEffect(anim);

    if (this.deferLayout) {
      delete this.deferLayout;
      this.doLayout(true);
    }

    this.fireEvent('expand', this);
  },

  /**
   * Shortcut for performing an {@link #expand} or {@link #collapse} based on the current state of the panel.
   * @param {Boolean} animate True to animate the transition, else false (defaults to the value of the
   * {@link #animCollapse} panel config)
   * @return {Ext.Panel} this
   */
  toggleCollapse: function toggleCollapse(animate) {
    this[this.collapsed ? 'expand' : 'collapse'](animate);
    return this;
  },
  // private
  onDisable: function onDisable() {
    if (this.rendered && this.maskDisabled) {
      this.el.mask();
    }

    Ext.Panel.superclass.onDisable.call(this);
  },
  // private
  onEnable: function onEnable() {
    if (this.rendered && this.maskDisabled) {
      this.el.unmask();
    }

    Ext.Panel.superclass.onEnable.call(this);
  },
  // private
  onResize: function onResize(w, h) {
    if (Ext.isDefined(w) || Ext.isDefined(h)) {
      if (!this.collapsed) {
        // First, set the the Panel's body width.
        // If we have auto-widthed it, get the resulting full offset width so we can size the Toolbars to match
        // The Toolbars must not buffer this resize operation because we need to know their heights.
        if (Ext.isNumber(w)) {
          this.body.setWidth(w = this.adjustBodyWidth(w - this.getFrameWidth()));
        } else if (w == 'auto') {
          w = this.body.setWidth('auto').dom.offsetWidth;
        } else {
          w = this.body.dom.offsetWidth;
        }

        if (this.tbar) {
          this.tbar.setWidth(w);

          if (this.topToolbar) {
            this.topToolbar.setSize(w);
          }
        }

        if (this.bbar) {
          this.bbar.setWidth(w);

          if (this.bottomToolbar) {
            this.bottomToolbar.setSize(w); // The bbar does not move on resize without this.

            if (Ext.isIE) {
              this.bbar.setStyle('position', 'static');
              this.bbar.setStyle('position', '');
            }
          }
        }

        if (this.footer) {
          this.footer.setWidth(w);

          if (this.fbar) {
            this.fbar.setSize(Ext.isIE ? w - this.footer.getFrameWidth('lr') : 'auto');
          }
        } // At this point, the Toolbars must be layed out for getFrameHeight to find a result.


        if (Ext.isNumber(h)) {
          h = Math.max(0, this.adjustBodyHeight(h - this.getFrameHeight()));
          this.body.setHeight(h);
        } else if (h == 'auto') {
          this.body.setHeight(h);
        }

        if (this.disabled && this.el._mask) {
          this.el._mask.setSize(this.el.dom.clientWidth, this.el.getHeight());
        }
      } else {
        // Adds an event to set the correct height afterExpand.  This accounts for the deferHeight flag in panel
        this.queuedBodySize = {
          width: w,
          height: h
        };

        if (!this.queuedExpand && this.allowQueuedExpand !== false) {
          this.queuedExpand = true;
          this.on('expand', function () {
            delete this.queuedExpand;
            this.onResize(this.queuedBodySize.width, this.queuedBodySize.height);
          }, this, {
            single: true
          });
        }
      }

      this.onBodyResize(w, h);
    }

    this.syncShadow();
    Ext.Panel.superclass.onResize.call(this);
  },
  // private
  onBodyResize: function onBodyResize(w, h) {
    this.fireEvent('bodyresize', this, w, h);
  },
  // private
  getToolbarHeight: function getToolbarHeight() {
    var h = 0;

    if (this.rendered) {
      Ext.each(this.toolbars, function (tb) {
        h += tb.getHeight();
      }, this);
    }

    return h;
  },
  // private
  adjustBodyHeight: function adjustBodyHeight(h) {
    return h;
  },
  // private
  adjustBodyWidth: function adjustBodyWidth(w) {
    return w;
  },
  // private
  onPosition: function onPosition() {
    this.syncShadow();
  },

  /**
   * Returns the width in pixels of the framing elements of this panel (not including the body width).  To
   * retrieve the body width see {@link #getInnerWidth}.
   * @return {Number} The frame width
   */
  getFrameWidth: function getFrameWidth() {
    var w = this.el.getFrameWidth('lr') + this.bwrap.getFrameWidth('lr');

    if (this.frame) {
      var l = this.bwrap.dom.firstChild;
      w += Ext.fly(l).getFrameWidth('l') + Ext.fly(l.firstChild).getFrameWidth('r');
      w += this.mc.getFrameWidth('lr');
    }

    return w;
  },

  /**
   * Returns the height in pixels of the framing elements of this panel (including any top and bottom bars and
   * header and footer elements, but not including the body height).  To retrieve the body height see {@link #getInnerHeight}.
   * @return {Number} The frame height
   */
  getFrameHeight: function getFrameHeight() {
    var h = this.el.getFrameWidth('tb') + this.bwrap.getFrameWidth('tb');
    h += (this.tbar ? this.tbar.getHeight() : 0) + (this.bbar ? this.bbar.getHeight() : 0);

    if (this.frame) {
      h += this.el.dom.firstChild.offsetHeight + this.ft.dom.offsetHeight + this.mc.getFrameWidth('tb');
    } else {
      h += (this.header ? this.header.getHeight() : 0) + (this.footer ? this.footer.getHeight() : 0);
    }

    return h;
  },

  /**
   * Returns the width in pixels of the body element (not including the width of any framing elements).
   * For the frame width see {@link #getFrameWidth}.
   * @return {Number} The body width
   */
  getInnerWidth: function getInnerWidth() {
    return this.getSize().width - this.getFrameWidth();
  },

  /**
   * Returns the height in pixels of the body element (not including the height of any framing elements).
   * For the frame height see {@link #getFrameHeight}.
   * @return {Number} The body height
   */
  getInnerHeight: function getInnerHeight() {
    return this.getSize().height - this.getFrameHeight();
  },
  // private
  syncShadow: function syncShadow() {
    if (this.floating) {
      this.el.sync(true);
    }
  },
  // private
  getLayoutTarget: function getLayoutTarget() {
    return this.body;
  },
  // private
  getContentTarget: function getContentTarget() {
    return this.body;
  },

  /**
   * <p>Sets the title text for the panel and optionally the {@link #iconCls icon class}.</p>
   * <p>In order to be able to set the title, a header element must have been created
   * for the Panel. This is triggered either by configuring the Panel with a non-blank <code>{@link #title}</code>,
   * or configuring it with <code><b>{@link #header}: true</b></code>.</p>
   * @param {String} title The title text to set
   * @param {String} iconCls (optional) {@link #iconCls iconCls} A user-defined CSS class that provides the icon image for this panel
   */
  setTitle: function setTitle(title, iconCls) {
    this.title = title;

    if (this.header && this.headerAsText) {
      this.header.child('span').update(title);
    }

    if (iconCls) {
      this.setIconClass(iconCls);
    }

    this.fireEvent('titlechange', this, title);
    return this;
  },

  /**
   * Get the {@link Ext.Updater} for this panel. Enables you to perform Ajax updates of this panel's body.
   * @return {Ext.Updater} The Updater
   */
  getUpdater: function getUpdater() {
    return this.body.getUpdater();
  },

  /**
  * Loads this content panel immediately with content returned from an XHR call.
  * @param {Object/String/Function} config A config object containing any of the following options:
  <pre><code>
  panel.load({
  url: 'your-url.php',
  params: {param1: 'foo', param2: 'bar'}, // or a URL encoded string
  callback: yourFunction,
  scope: yourObject, // optional scope for the callback
  discardUrl: false,
  nocache: false,
  text: 'Loading...',
  timeout: 30,
  scripts: false
  });
  </code></pre>
  * The only required property is url. The optional properties nocache, text and scripts
  * are shorthand for disableCaching, indicatorText and loadScripts and are used to set their
  * associated property on this panel Updater instance.
  * @return {Ext.Panel} this
  */
  load: function load() {
    var um = this.body.getUpdater();
    um.update.apply(um, arguments);
    return this;
  },
  // private
  beforeDestroy: function beforeDestroy() {
    Ext.Panel.superclass.beforeDestroy.call(this);

    if (this.header) {
      this.header.removeAllListeners();
    }

    if (this.tools) {
      for (var k in this.tools) {
        Ext.destroy(this.tools[k]);
      }
    }

    if (this.toolbars.length > 0) {
      Ext.each(this.toolbars, function (tb) {
        tb.un('afterlayout', this.syncHeight, this);
        tb.un('remove', this.syncHeight, this);
      }, this);
    }

    if (Ext.isArray(this.buttons)) {
      while (this.buttons.length) {
        Ext.destroy(this.buttons[0]);
      }
    }

    if (this.rendered) {
      Ext.destroy(this.ft, this.header, this.footer, this.toolbars, this.tbar, this.bbar, this.body, this.mc, this.bwrap);

      if (this.fbar) {
        Ext.destroy(this.fbar, this.fbar.el);
      }
    } else {
      Ext.destroy(this.topToolbar, this.bottomToolbar);
    }
  },
  // private
  createClasses: function createClasses() {
    this.headerCls = this.baseCls + '-header';
    this.headerTextCls = this.baseCls + '-header-text';
    this.bwrapCls = this.baseCls + '-bwrap';
    this.tbarCls = this.baseCls + '-tbar';
    this.bodyCls = this.baseCls + '-body';
    this.bbarCls = this.baseCls + '-bbar';
    this.footerCls = this.baseCls + '-footer';
  },
  // private
  createGhost: function createGhost(cls, useShim, appendTo) {
    var el = document.createElement('div');
    el.className = 'x-panel-ghost ' + (cls ? cls : '');

    if (this.header) {
      el.appendChild(this.el.dom.firstChild.cloneNode(true));
    }

    Ext.fly(el.appendChild(document.createElement('ul'))).setHeight(this.bwrap.getHeight());
    el.style.width = this.el.dom.offsetWidth + 'px';
    ;

    if (!appendTo) {
      this.container.dom.appendChild(el);
    } else {
      Ext.getDom(appendTo).appendChild(el);
    }

    if (useShim !== false && this.el.useShim !== false) {
      var layer = new Ext.Layer({
        shadow: false,
        useDisplay: true,
        constrain: false
      }, el);
      layer.show();
      return layer;
    } else {
      return new Ext.Element(el);
    }
  },
  // private
  doAutoLoad: function doAutoLoad() {
    var u = this.body.getUpdater();

    if (this.renderer) {
      u.setRenderer(this.renderer);
    }

    u.update(Ext.isObject(this.autoLoad) ? this.autoLoad : {
      url: this.autoLoad
    });
  },

  /**
   * Retrieve a tool by id.
   * @param {String} id
   * @return {Object} tool
   */
  getTool: function getTool(id) {
    return this.tools[id];
  }
  /**
   * @cfg {String} autoEl @hide
   */

});
Ext.reg('panel', Ext.Panel);

/***/ }),
/* 774 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Editor
 * @extends Ext.Component
 * A base editor field that handles displaying/hiding on demand and has some built-in sizing and event handling logic.
 * @constructor
 * Create a new Editor
 * @param {Object} config The config object
 * @xtype editor
 */
Ext.Editor = function (field, config) {
  if (field.field) {
    this.field = Ext.create(field.field, 'textfield');
    config = Ext.apply({}, field); // copy so we don't disturb original config

    delete config.field;
  } else {
    this.field = field;
  }

  Ext.Editor.superclass.constructor.call(this, config);
};

Ext.extend(Ext.Editor, Ext.Component, {
  /**
  * @cfg {Ext.form.Field} field
  * The Field object (or descendant) or config object for field
  */

  /**
   * @cfg {Boolean} allowBlur
   * True to {@link #completeEdit complete the editing process} if in edit mode when the
   * field is blurred. Defaults to <tt>false</tt>.
   */

  /**
   * @cfg {Boolean/String} autoSize
   * True for the editor to automatically adopt the size of the underlying field, "width" to adopt the width only,
   * or "height" to adopt the height only, "none" to always use the field dimensions. (defaults to false)
   */

  /**
   * @cfg {Boolean} revertInvalid
   * True to automatically revert the field value and cancel the edit when the user completes an edit and the field
   * validation fails (defaults to true)
   */

  /**
   * @cfg {Boolean} ignoreNoChange
   * True to skip the edit completion process (no save, no events fired) if the user completes an edit and
   * the value has not changed (defaults to false).  Applies only to string values - edits for other data types
   * will never be ignored.
   */

  /**
   * @cfg {Boolean} hideEl
   * False to keep the bound element visible while the editor is displayed (defaults to true)
   */

  /**
   * @cfg {Mixed} value
   * The data value of the underlying field (defaults to "")
   */
  value: "",

  /**
   * @cfg {String} alignment
   * The position to align to (see {@link Ext.Element#alignTo} for more details, defaults to "c-c?").
   */
  alignment: "c-c?",

  /**
   * @cfg {Array} offsets
   * The offsets to use when aligning (see {@link Ext.Element#alignTo} for more details. Defaults to <tt>[0, 0]</tt>.
   */
  offsets: [0, 0],

  /**
   * @cfg {Boolean/String} shadow "sides" for sides/bottom only, "frame" for 4-way shadow, and "drop"
   * for bottom-right shadow (defaults to "frame")
   */
  shadow: "frame",

  /**
   * @cfg {Boolean} constrain True to constrain the editor to the viewport
   */
  constrain: false,

  /**
   * @cfg {Boolean} swallowKeys Handle the keydown/keypress events so they don't propagate (defaults to true)
   */
  swallowKeys: true,

  /**
   * @cfg {Boolean} completeOnEnter True to complete the edit when the enter key is pressed. Defaults to <tt>true</tt>.
   */
  completeOnEnter: true,

  /**
   * @cfg {Boolean} cancelOnEsc True to cancel the edit when the escape key is pressed. Defaults to <tt>true</tt>.
   */
  cancelOnEsc: true,

  /**
   * @cfg {Boolean} updateEl True to update the innerHTML of the bound element when the update completes (defaults to false)
   */
  updateEl: false,
  initComponent: function initComponent() {
    Ext.Editor.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event beforestartedit
     * Fires when editing is initiated, but before the value changes.  Editing can be canceled by returning
     * false from the handler of this event.
     * @param {Editor} this
     * @param {Ext.Element} boundEl The underlying element bound to this editor
     * @param {Mixed} value The field value being set
     */
    "beforestartedit",
    /**
     * @event startedit
     * Fires when this editor is displayed
     * @param {Ext.Element} boundEl The underlying element bound to this editor
     * @param {Mixed} value The starting field value
     */
    "startedit",
    /**
     * @event beforecomplete
     * Fires after a change has been made to the field, but before the change is reflected in the underlying
     * field.  Saving the change to the field can be canceled by returning false from the handler of this event.
     * Note that if the value has not changed and ignoreNoChange = true, the editing will still end but this
     * event will not fire since no edit actually occurred.
     * @param {Editor} this
     * @param {Mixed} value The current field value
     * @param {Mixed} startValue The original field value
     */
    "beforecomplete",
    /**
     * @event complete
     * Fires after editing is complete and any changed value has been written to the underlying field.
     * @param {Editor} this
     * @param {Mixed} value The current field value
     * @param {Mixed} startValue The original field value
     */
    "complete",
    /**
     * @event canceledit
     * Fires after editing has been canceled and the editor's value has been reset.
     * @param {Editor} this
     * @param {Mixed} value The user-entered field value that was discarded
     * @param {Mixed} startValue The original field value that was set back into the editor after cancel
     */
    "canceledit",
    /**
     * @event specialkey
     * Fires when any key related to navigation (arrows, tab, enter, esc, etc.) is pressed.  You can check
     * {@link Ext.EventObject#getKey} to determine which key was pressed.
     * @param {Ext.form.Field} this
     * @param {Ext.EventObject} e The event object
     */
    "specialkey");
  },
  // private
  onRender: function onRender(ct, position) {
    this.el = new Ext.Layer({
      shadow: this.shadow,
      cls: "x-editor",
      parentEl: ct,
      shim: this.shim,
      shadowOffset: this.shadowOffset || 4,
      id: this.id,
      constrain: this.constrain
    });

    if (this.zIndex) {
      this.el.setZIndex(this.zIndex);
    }

    this.el.setStyle("overflow", Ext.isGecko ? "auto" : "hidden");

    if (this.field.msgTarget != 'title') {
      this.field.msgTarget = 'qtip';
    }

    this.field.inEditor = true;
    this.mon(this.field, {
      scope: this,
      blur: this.onBlur,
      specialkey: this.onSpecialKey
    });

    if (this.field.grow) {
      this.mon(this.field, "autosize", this.el.sync, this.el, {
        delay: 1
      });
    }

    this.field.render(this.el).show();
    this.field.getEl().dom.name = '';

    if (this.swallowKeys) {
      this.field.el.swallowEvent(['keypress', // *** Opera
      'keydown' // *** all other browsers
      ]);
    }
  },
  // private
  onSpecialKey: function onSpecialKey(field, e) {
    var key = e.getKey(),
        complete = this.completeOnEnter && key == e.ENTER,
        cancel = this.cancelOnEsc && key == e.ESC;

    if (complete || cancel) {
      e.stopEvent();

      if (complete) {
        this.completeEdit();
      } else {
        this.cancelEdit();
      }

      if (field.triggerBlur) {
        field.triggerBlur();
      }
    }

    this.fireEvent('specialkey', field, e);
  },

  /**
   * Starts the editing process and shows the editor.
   * @param {Mixed} el The element to edit
   * @param {String} value (optional) A value to initialize the editor with. If a value is not provided, it defaults
   * @param {Record} record the field is part of
    * to the innerHTML of el.
   */
  startEdit: function startEdit(el, value, record) {
    if (this.editing) {
      this.completeEdit();
    }

    this.boundEl = Ext.get(el);
    var v = value !== undefined ? value : this.boundEl.dom.innerHTML;

    if (!this.rendered) {
      this.render(this.parentEl || document.body);
    }

    if (this.fireEvent("beforestartedit", this, this.boundEl, v, record) !== false) {
      this.startValue = v;
      this.field.reset();
      this.field.setValue(v, record);
      this.realign(true);
      this.editing = true;
      this.show();
    }
  },
  // private
  doAutoSize: function doAutoSize() {
    if (this.autoSize) {
      var sz = this.boundEl.getSize(),
          fs = this.field.getSize();

      switch (this.autoSize) {
        case "width":
          this.setSize(sz.width, fs.height);
          break;

        case "height":
          this.setSize(fs.width, sz.height);
          break;

        case "none":
          this.setSize(fs.width, fs.height);
          break;

        default:
          this.setSize(sz.width, sz.height);
      }
    }
  },

  /**
   * Sets the height and width of this editor.
   * @param {Number} width The new width
   * @param {Number} height The new height
   */
  setSize: function setSize(w, h) {
    delete this.field.lastSize;
    this.field.setSize(w, h);

    if (this.el) {
      if (Ext.isGecko2 || Ext.isOpera) {
        // prevent layer scrollbars
        this.el.setSize(w, h);
      }

      this.el.sync();
    }
  },

  /**
   * Realigns the editor to the bound field based on the current alignment config value.
   * @param {Boolean} autoSize (optional) True to size the field to the dimensions of the bound element.
   */
  realign: function realign(autoSize) {
    if (autoSize === true) {
      this.doAutoSize();
    }

    this.el.alignTo(this.boundEl, this.alignment, this.offsets);
  },

  /**
   * Ends the editing process, persists the changed value to the underlying field, and hides the editor.
   * @param {Boolean} remainVisible Override the default behavior and keep the editor visible after edit (defaults to false)
   */
  completeEdit: function completeEdit(remainVisible) {
    if (!this.editing) {
      return;
    }

    var v = this.getValue();

    if (!this.field.isValid()) {
      if (this.revertInvalid !== false) {
        this.cancelEdit(remainVisible);
      }

      return;
    }

    if (String(v) === String(this.startValue) && this.ignoreNoChange) {
      this.hideEdit(remainVisible);
      return;
    }

    if (this.fireEvent("beforecomplete", this, v, this.startValue) !== false) {
      v = this.getValue();

      if (this.updateEl && this.boundEl) {
        this.boundEl.update(v);
      }

      this.hideEdit(remainVisible);
      this.fireEvent("complete", this, v, this.startValue);
    }
  },
  // private
  onShow: function onShow() {
    this.el.show();

    if (this.hideEl !== false) {
      this.boundEl.hide();
    }

    this.field.show().focus(false, true);
    this.fireEvent("startedit", this.boundEl, this.startValue);
  },

  /**
   * Cancels the editing process and hides the editor without persisting any changes.  The field value will be
   * reverted to the original starting value.
   * @param {Boolean} remainVisible Override the default behavior and keep the editor visible after
   * cancel (defaults to false)
   */
  cancelEdit: function cancelEdit(remainVisible) {
    if (this.editing) {
      var v = this.getValue();
      this.setValue(this.startValue);
      this.hideEdit(remainVisible);
      this.fireEvent("canceledit", this, v, this.startValue);
    }
  },
  // private
  hideEdit: function hideEdit(remainVisible) {
    if (remainVisible !== true) {
      this.editing = false;
      this.hide();
    }
  },
  // private
  onBlur: function onBlur() {
    // selectSameEditor flag allows the same editor to be started without onBlur firing on itself
    if (this.allowBlur !== true && this.editing && this.selectSameEditor !== true) {
      this.completeEdit();
    }
  },
  // private
  onHide: function onHide() {
    if (this.editing) {
      this.completeEdit();
      return;
    }

    this.field.blur();

    if (this.field.collapse) {
      this.field.collapse();
    }

    this.el.hide();

    if (this.hideEl !== false) {
      this.boundEl.show();
    }
  },

  /**
   * Sets the data value of the editor
   * @param {Mixed} value Any valid value supported by the underlying field
   */
  setValue: function setValue(v) {
    this.field.setValue(v);
  },

  /**
   * Gets the data value of the editor
   * @return {Mixed} The data value
   */
  getValue: function getValue() {
    return this.field.getValue();
  },
  beforeDestroy: function beforeDestroy() {
    Ext.destroyMembers(this, 'field');
    delete this.parentEl;
    delete this.boundEl;
  }
});
Ext.reg('editor', Ext.Editor);

/***/ }),
/* 775 */
/***/ (function(module, exports, __webpack_require__) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ColorPalette
 * @extends Ext.Component
 * Simple color palette class for choosing colors.  The palette can be rendered to any container.<br />
 * Here's an example of typical usage:
 * <pre><code>
var cp = new Ext.ColorPalette({value:'993300'});  // initial selected color
cp.render('my-div');

cp.on('select', function(palette, selColor){
    // do something with selColor
});
</code></pre>
 * @constructor
 * Create a new ColorPalette
 * @param {Object} config The config object
 * @xtype colorpalette
 */
Ext.ColorPalette = Ext.extend(Ext.Component, {
  /**
   * @cfg {String} tpl An existing XTemplate instance to be used in place of the default template for rendering the component.
   */

  /**
   * @cfg {String} itemCls
   * The CSS class to apply to the containing element (defaults to 'x-color-palette')
   */
  itemCls: 'x-color-palette',

  /**
   * @cfg {String} value
   * The initial color to highlight (should be a valid 6-digit color hex code without the # symbol).  Note that
   * the hex codes are case-sensitive.
   */
  value: null,

  /**
   * @cfg {String} clickEvent
   * The DOM event that will cause a color to be selected. This can be any valid event name (dblclick, contextmenu). 
   * Defaults to <tt>'click'</tt>.
   */
  clickEvent: 'click',
  // private
  ctype: 'Ext.ColorPalette',

  /**
   * @cfg {Boolean} allowReselect If set to true then reselecting a color that is already selected fires the {@link #select} event
   */
  allowReselect: false,

  /**
   * <p>An array of 6-digit color hex code strings (without the # symbol).  This array can contain any number
   * of colors, and each hex code should be unique.  The width of the palette is controlled via CSS by adjusting
   * the width property of the 'x-color-palette' class (or assigning a custom class), so you can balance the number
   * of colors with the width setting until the box is symmetrical.</p>
   * <p>You can override individual colors if needed:</p>
   * <pre><code>
  var cp = new Ext.ColorPalette();
  cp.colors[0] = 'FF0000';  // change the first box to red
  </code></pre>
  Or you can provide a custom array of your own for complete control:
  <pre><code>
  var cp = new Ext.ColorPalette();
  cp.colors = ['000000', '993300', '333300'];
  </code></pre>
   * @type Array
   */
  colors: ['000000', '993300', '333300', '003300', '003366', '000080', '333399', '333333', '800000', 'FF6600', '808000', '008000', '008080', '0000FF', '666699', '808080', 'FF0000', 'FF9900', '99CC00', '339966', '33CCCC', '3366FF', '800080', '969696', 'FF00FF', 'FFCC00', 'FFFF00', '00FF00', '00FFFF', '00CCFF', '993366', 'C0C0C0', 'FF99CC', 'FFCC99', 'FFFF99', 'CCFFCC', 'CCFFFF', '99CCFF', 'CC99FF', 'FFFFFF', 'FFECF6', 'FFF3E7', 'FFFFE7', 'E2FFE2', 'DCFCFF', 'EDF6FF', 'F4E9FF', 'picker'],

  /**
   * @cfg {Function} handler
   * Optional. A function that will handle the select event of this palette.
   * The handler is passed the following parameters:<div class="mdetail-params"><ul>
   * <li><code>palette</code> : ColorPalette<div class="sub-desc">The {@link #palette Ext.ColorPalette}.</div></li>
   * <li><code>color</code> : String<div class="sub-desc">The 6-digit color hex code (without the # symbol).</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Object} scope
   * The scope (<tt><b>this</b></tt> reference) in which the <code>{@link #handler}</code>
   * function will be called.  Defaults to this ColorPalette instance.
   */
  colorPicker: null,
  // private
  initComponent: function initComponent() {
    Ext.ColorPalette.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event select
     * Fires when a color is selected
     * @param {ColorPalette} this
     * @param {String} color The 6-digit color hex code (without the # symbol)
     */
    'select');

    if (this.handler) {
      this.on('select', this.handler, this.scope, true);
    }
  },
  // private
  onRender: function onRender(container, position) {
    this.autoEl = {
      tag: 'div',
      cls: this.itemCls
    };
    Ext.ColorPalette.superclass.onRender.call(this, container, position);
    var t = this.tpl || new Ext.XTemplate('<tpl for="."><a href="#" class="color-{.}" hidefocus="on"><em><span style="background:#{[this.getColor(values)]}; text-align: center" unselectable="on">{[this.getSymbol(values)]}</span></em></a></tpl>', {
      getColor(value) {
        if (value === 'picker') {
          return 'FFFFFF';
        }

        return value;
      },

      getSymbol: function getSymbol(value) {
        if (value === 'picker') {
          return '+';
        }

        return '&#160';
      }
    });
    t.overwrite(this.el, this.colors);
    this.mon(this.el, this.clickEvent, this.handleClick, this, {
      delegate: 'a'
    });

    if (this.clickEvent != 'click') {
      this.mon(this.el, 'click', Ext.emptyFn, this, {
        delegate: 'a',
        preventDefault: true
      });
    }
  },
  // private
  afterRender: function afterRender() {
    Ext.ColorPalette.superclass.afterRender.call(this);

    if (this.value) {
      var s = this.value;
      this.value = null;
      this.suspendEvents();
      this.select(s);
      this.resumeEvents();
    }
  },
  // private
  handleClick: function handleClick(e, t) {
    e.preventDefault();

    if (this.colorPicker) {
      return;
    }

    if (!this.disabled) {
      var c = t.className.match(/(?:^|\s)color-(.{6})(?:\s|$)/)[1];
      this.select(c.toUpperCase());
    }
  },

  /**
   * Selects the specified color in the palette (fires the {@link #select} event)
   * @param {String} color A valid 6-digit color hex code (# will be stripped if included)
   */
  select: function select(color) {
    color = String(color).replace('#', '');

    if (color === 'PICKER') {
      this.renderColorPicker();
      return;
    }

    if (!/^[0-9A-F]{6}$/i.test(color)) {
      return;
    }

    if (color !== this.value || this.allowReselect) {
      this.highlightElement(this.el, color);
      this.value = color;
      this.fireEvent('select', this, color);
      let values = Tine.Calendar.ColorManager.str2dec(color); // weights of color values see: https://stackoverflow.com/questions/596216/formula-to-determine-brightness-of-rgb-color

      let Y = 0.299 * values[0] + 0.587 * values[1] + 0.114 * values[2];
      let textColor = Y > 128 ? '000000' : 'FFFFFF';
      this.el.child('a.color-picker > em > span').dom.style.backgroundColor = '#' + color;
      this.el.child('a.color-picker > em > span').dom.style.color = '#' + textColor;
    }
  },

  highlightElement(el, color) {
    if (this.value && el.child('a.color-' + this.value)) {
      el.child('a.color-' + this.value).removeClass('x-color-palette-sel');
    }

    if (el.child('a.color-picker')) {
      el.child('a.color-picker').removeClass('x-color-palette-sel');
    }

    if (el.child('a.color-' + color)) {
      el.child('a.color-' + color).addClass('x-color-palette-sel');
    } else {
      el.child('a.color-picker').addClass('x-color-palette-sel');
    }
  },

  renderColorPicker: async function renderColorPicker() {
    const me = this;
    const {
      default: Vue
    } = await __webpack_require__.e(/* import() | Tinebase/js/Vue */ 35).then(__webpack_require__.t.bind(null, 2212, 7));
    const {
      default: ColorPickerApp
    } = await __webpack_require__.e(/* import() | Tinebase/js/ColorPickerApp */ 30).then(__webpack_require__.bind(null, 2720));
    const colorPickerApp = new Ext.Component({
      border: false,
      id: 'ColorPickerApp-' + this.id
    });
    const picker = Tine.WindowFactory.getWindow({
      modal: true,
      name: 'ColorPickerWindow_' + this.id,
      title: i18n._('Select Color'),
      closeAction: 'destroy',
      width: 215,
      height: 330,
      items: new Tine.Tinebase.dialog.Dialog({
        listeners: {
          scope: this,
          apply: function apply(color) {
            this.select(color);
            picker.destroy();
            me.colorPicker = null;
          },
          cancel: function cancel() {
            picker.destroy();
            me.colorPicker = null;
          }
        },
        getEventData: function getEventData(eventName) {
          if (eventName === 'apply') {
            return vm.$refs.colorPickerApp.getColor();
          }
        },
        items: [{
          items: colorPickerApp,
          layout: 'absolute'
        }]
      })
    }).show();
    picker.setZIndex(16000);
    await colorPickerApp.afterIsRendered();
    this.colorPicker = picker;
    this.fireEvent('pickerShow', picker);
    const vm = new Vue({
      el: '#ColorPickerApp-' + this.id,
      render: createElement => {
        return createElement(ColorPickerApp, {
          props: {
            initialColor: me.value
          },
          ref: 'colorPickerApp'
        });
      }
    });
  }
  /**
   * @cfg {String} autoEl @hide
   */

});
Ext.reg('colorpalette', Ext.ColorPalette);

/***/ }),
/* 776 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.DatePicker
 * @extends Ext.Component
 * <p>A popup date picker. This class is used by the {@link Ext.form.DateField DateField} class
 * to allow browsing and selection of valid dates.</p>
 * <p>All the string values documented below may be overridden by including an Ext locale file in
 * your page.</p>
 * @constructor
 * Create a new DatePicker
 * @param {Object} config The config object
 * @xtype datepicker
 */
Ext.DatePicker = Ext.extend(Ext.BoxComponent, {
  /**
   * @cfg {String} todayText
   * The text to display on the button that selects the current date (defaults to <code>'Today'</code>)
   */
  todayText: 'Today',

  /**
   * @cfg {String} okText
   * The text to display on the ok button (defaults to <code>'&#160;OK&#160;'</code> to give the user extra clicking room)
   */
  okText: '&#160;OK&#160;',

  /**
   * @cfg {String} cancelText
   * The text to display on the cancel button (defaults to <code>'Cancel'</code>)
   */
  cancelText: 'Cancel',

  /**
   * @cfg {Function} handler
   * Optional. A function that will handle the select event of this picker.
   * The handler is passed the following parameters:<div class="mdetail-params"><ul>
   * <li><code>picker</code> : DatePicker<div class="sub-desc">This DatePicker.</div></li>
   * <li><code>date</code> : Date<div class="sub-desc">The selected date.</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Object} scope
   * The scope (<code><b>this</b></code> reference) in which the <code>{@link #handler}</code>
   * function will be called.  Defaults to this DatePicker instance.
   */

  /**
   * @cfg {String} todayTip
   * A string used to format the message for displaying in a tooltip over the button that
   * selects the current date. Defaults to <code>'{0} (Spacebar)'</code> where
   * the <code>{0}</code> token is replaced by today's date.
   */
  todayTip: '{0} (Spacebar)',

  /**
   * @cfg {String} minText
   * The error text to display if the minDate validation fails (defaults to <code>'This date is before the minimum date'</code>)
   */
  minText: 'This date is before the minimum date',

  /**
   * @cfg {String} maxText
   * The error text to display if the maxDate validation fails (defaults to <code>'This date is after the maximum date'</code>)
   */
  maxText: 'This date is after the maximum date',

  /**
   * @cfg {String} format
   * The default date format string which can be overriden for localization support.  The format must be
   * valid according to {@link Date#parseDate} (defaults to <code>'m/d/y'</code>).
   */
  format: 'm/d/y',

  /**
   * @cfg {String} disabledDaysText
   * The tooltip to display when the date falls on a disabled day (defaults to <code>'Disabled'</code>)
   */
  disabledDaysText: 'Disabled',

  /**
   * @cfg {String} disabledDatesText
   * The tooltip text to display when the date falls on a disabled date (defaults to <code>'Disabled'</code>)
   */
  disabledDatesText: 'Disabled',

  /**
   * @cfg {Array} monthNames
   * An array of textual month names which can be overriden for localization support (defaults to Date.monthNames)
   */
  monthNames: Date.monthNames,

  /**
   * @cfg {Array} dayNames
   * An array of textual day names which can be overriden for localization support (defaults to Date.dayNames)
   */
  dayNames: Date.dayNames,

  /**
   * @cfg {String} nextText
   * The next month navigation button tooltip (defaults to <code>'Next Month (Control+Right)'</code>)
   */
  nextText: 'Next Month (Control+Right)',

  /**
   * @cfg {String} prevText
   * The previous month navigation button tooltip (defaults to <code>'Previous Month (Control+Left)'</code>)
   */
  prevText: 'Previous Month (Control+Left)',

  /**
   * @cfg {String} monthYearText
   * The header month selector tooltip (defaults to <code>'Choose a month (Control+Up/Down to move years)'</code>)
   */
  monthYearText: 'Choose a month (Control+Up/Down to move years)',

  /**
   * @cfg {Number} startDay
   * Day index at which the week should begin, 0-based (defaults to 0, which is Sunday)
   */
  startDay: 0,

  /**
   * @cfg {Boolean} showToday
   * False to hide the footer area containing the Today button and disable the keyboard handler for spacebar
   * that selects the current date (defaults to <code>true</code>).
   */
  showToday: true,

  /**
   * @cfg {Date} minDate
   * Minimum allowable date (JavaScript date object, defaults to null)
   */

  /**
   * @cfg {Date} maxDate
   * Maximum allowable date (JavaScript date object, defaults to null)
   */

  /**
   * @cfg {Object} dateClss
   * {datestr: clssString} additional css cls classes for given dates
   */

  /**
   * @cfg {Array} disabledDays
   * An array of days to disable, 0-based. For example, [0, 6] disables Sunday and Saturday (defaults to null).
   */

  /**
   * @cfg {RegExp} disabledDatesRE
   * JavaScript regular expression used to disable a pattern of dates (defaults to null).  The {@link #disabledDates}
   * config will generate this regex internally, but if you specify disabledDatesRE it will take precedence over the
   * disabledDates value.
   */

  /**
   * @cfg {Array} disabledDates
   * An array of 'dates' to disable, as strings. These strings will be used to build a dynamic regular
   * expression so they are very powerful. Some examples:
   * <ul>
   * <li>['03/08/2003', '09/16/2003'] would disable those exact dates</li>
   * <li>['03/08', '09/16'] would disable those days for every year</li>
   * <li>['^03/08'] would only match the beginning (useful if you are using short years)</li>
   * <li>['03/../2006'] would disable every day in March 2006</li>
   * <li>['^03'] would disable every day in every March</li>
   * </ul>
   * Note that the format of the dates included in the array should exactly match the {@link #format} config.
   * In order to support regular expressions, if you are using a date format that has '.' in it, you will have to
   * escape the dot when restricting dates. For example: ['03\\.08\\.03'].
   */
  // private
  // Set by other components to stop the picker focus being updated when the value changes.
  focusOnSelect: true,
  // private
  initComponent: function initComponent() {
    Ext.DatePicker.superclass.initComponent.call(this);
    this.value = this.value ? this.value.clearTime(true) : new Date().clearTime();
    this.setSelected(_.isArray(this.selections) ? this.selections : []);
    this.addEvents(
    /**
     * @event select
     * Fires when a date is selected
     * @param {DatePicker} this DatePicker
     * @param {Date} date The selected date
     */
    'select',
    /**
     * @event beforeselect
     * Fires before a date is selected. return false to abort selection
     * @param {DatePicker} this DatePicker
     * @param {Date} date The date to select
     */
    'beforeselect');

    if (this.handler) {
      this.on('select', this.handler, this.scope || this);
    }

    this.initDisabledDays();
  },
  // private
  initDisabledDays: function initDisabledDays() {
    if (!this.disabledDatesRE && this.disabledDates) {
      var dd = this.disabledDates,
          len = dd.length - 1,
          re = '(?:';
      Ext.each(dd, function (d, i) {
        re += Ext.isDate(d) ? '^' + Ext.escapeRe(d.dateFormat(this.format)) + '$' : dd[i];

        if (i != len) {
          re += '|';
        }
      }, this);
      this.disabledDatesRE = new RegExp(re + ')');
    }
  },

  /**
   * Replaces any existing disabled dates with new values and refreshes the DatePicker.
   * @param {Array/RegExp} disabledDates An array of date strings (see the {@link #disabledDates} config
   * for details on supported values), or a JavaScript regular expression used to disable a pattern of dates.
   */
  setDisabledDates: function setDisabledDates(dd) {
    if (Ext.isArray(dd)) {
      this.disabledDates = dd;
      this.disabledDatesRE = null;
    } else {
      this.disabledDatesRE = dd;
    }

    this.initDisabledDays();
    this.update(this.value, true);
  },

  /**
   * Replaces any existing disabled days (by index, 0-6) with new values and refreshes the DatePicker.
   * @param {Array} disabledDays An array of disabled day indexes. See the {@link #disabledDays} config
   * for details on supported values.
   */
  setDisabledDays: function setDisabledDays(dd) {
    this.disabledDays = dd;
    this.update(this.value, true);
  },

  /**
   * Replaces any existing {@link #minDate} with the new value and refreshes the DatePicker.
   * @param {Date} value The minimum date that can be selected
   */
  setMinDate: function setMinDate(dt) {
    this.minDate = dt;
    this.update(this.value, true);
  },

  /**
   * Replaces any existing {@link #maxDate} with the new value and refreshes the DatePicker.
   * @param {Date} value The maximum date that can be selected
   */
  setMaxDate: function setMaxDate(dt) {
    this.maxDate = dt;
    this.update(this.value, true);
  },

  /** 
   * Replaces any existing {@link #dateClss} with the new clss and refreshes the DatePicker.
   * @param {Object} datestr: clssString cls classes for given dates
   */
  setDateClss: function setDateClss(clss) {
    this.dateClss = clss;
    this.update(this.value, true);
  },

  /**
   * Sets the value of the date field
   * @param {Date} value The date to set
   */
  setValue: function setValue(value) {
    this.value = value.clearTime(true);
    this.update(this.value);
  },
  setSelected: function setSelected(selections) {
    this.selections = [];

    _.each(selections, selection => {
      if (_.isString(selection)) {
        selection = Date.parseDate(selection, this.format);
      }

      if (_.isDate(selection)) {
        selection = selection.getTime();
      }

      if (_.isNumber(selection)) {
        this.selections.push(selection);
      }
    });

    this.selections.sort();
    this.update(this.value);
  },
  getSelected: function getSelected() {
    return _.map(this.selections, ts => {
      return new Date(ts);
    });
  },

  /**
   * Gets the current selected value of the date field
   * @return {Date} The selected date
   */
  getValue: function getValue() {
    return this.value;
  },
  // private
  focus: function focus() {
    this.update(this.activeDate);
  },
  // private
  onEnable: function onEnable(initial) {
    Ext.DatePicker.superclass.onEnable.call(this);
    this.doDisabled(false);
    this.update(initial ? this.value : this.activeDate);

    if (Ext.isIE) {
      this.el.repaint();
    }
  },
  // private
  onDisable: function onDisable() {
    Ext.DatePicker.superclass.onDisable.call(this);
    this.doDisabled(true);

    if (Ext.isIE && !Ext.isIE8) {
      /* Really strange problem in IE6/7, when disabled, have to explicitly
       * repaint each of the nodes to get them to display correctly, simply
       * calling repaint on the main element doesn't appear to be enough.
       */
      Ext.each([].concat(this.textNodes, this.el.query('th span')), function (el) {
        Ext.fly(el).repaint();
      });
    }
  },
  // private
  doDisabled: function doDisabled(disabled) {
    this.keyNav.setDisabled(disabled);
    this.prevRepeater.setDisabled(disabled);
    this.nextRepeater.setDisabled(disabled);

    if (this.showToday) {
      this.todayKeyListener.setDisabled(disabled);
      this.todayBtn.setDisabled(disabled);
    }
  },
  // private
  onRender: function onRender(container, position) {
    var m = ['<table cellspacing="0">', '<tr><td class="x-date-left"><a href="#" title="', this.prevText, '">&#160;</a></td><td class="x-date-middle" align="center"></td><td class="x-date-right"><a href="#" title="', this.nextText, '">&#160;</a></td></tr>', '<tr><td colspan="3"><table class="x-date-inner" cellspacing="0"><thead><tr>'],
        dn = this.dayNames,
        i;

    for (i = 0; i < 7; i++) {
      var d = this.startDay + i;

      if (d > 6) {
        d = d - 7;
      }

      m.push('<th><span>', dn[d].substr(0, 1), '</span></th>');
    }

    m[m.length] = '</tr></thead><tbody><tr>';

    for (i = 0; i < 42; i++) {
      if (i % 7 === 0 && i !== 0) {
        m[m.length] = '</tr><tr>';
      }

      m[m.length] = '<td><a href="#" hidefocus="on" class="x-date-date" tabIndex="1"><em><span></span></em></a></td>';
    }

    m.push('</tr></tbody></table></td></tr>', this.showToday ? '<tr><td colspan="3" class="x-date-bottom" align="center"></td></tr>' : '', '</table><div class="x-date-mp"></div>');
    var el = document.createElement('div');
    el.className = 'x-date-picker';
    el.innerHTML = m.join('');
    container.dom.insertBefore(el, position);
    this.el = Ext.get(el);
    this.eventEl = Ext.get(el.firstChild);
    this.prevRepeater = new Ext.util.ClickRepeater(this.el.child('td.x-date-left a'), {
      handler: this.showPrevMonth,
      scope: this,
      preventDefault: true,
      stopDefault: true
    });
    this.nextRepeater = new Ext.util.ClickRepeater(this.el.child('td.x-date-right a'), {
      handler: this.showNextMonth,
      scope: this,
      preventDefault: true,
      stopDefault: true
    });
    this.monthPicker = this.el.down('div.x-date-mp');
    this.monthPicker.enableDisplayMode('block');
    this.keyNav = new Ext.KeyNav(this.eventEl, {
      'left': function left(e) {
        if (e.ctrlKey) {
          this.showPrevMonth();
        } else {
          this.update(this.activeDate.add('d', -1));
        }
      },
      'right': function right(e) {
        if (e.ctrlKey) {
          this.showNextMonth();
        } else {
          this.update(this.activeDate.add('d', 1));
        }
      },
      'up': function up(e) {
        if (e.ctrlKey) {
          this.showNextYear();
        } else {
          this.update(this.activeDate.add('d', -7));
        }
      },
      'down': function down(e) {
        if (e.ctrlKey) {
          this.showPrevYear();
        } else {
          this.update(this.activeDate.add('d', 7));
        }
      },
      'pageUp': function pageUp(e) {
        this.showNextMonth();
      },
      'pageDown': function pageDown(e) {
        this.showPrevMonth();
      },
      'enter': function enter(e) {
        e.stopPropagation();
        return true;
      },
      scope: this
    });
    this.el.unselectable();
    this.cells = this.el.select('table.x-date-inner tbody td');
    this.textNodes = this.el.query('table.x-date-inner tbody span');
    this.mbtn = new Ext.Button({
      text: '&#160;',
      tooltip: this.monthYearText,
      renderTo: this.el.child('td.x-date-middle', true)
    });
    this.mbtn.el.child('em').addClass('x-btn-arrow');

    if (this.showToday) {
      this.todayKeyListener = this.eventEl.addKeyListener(Ext.EventObject.SPACE, this.selectToday, this);
      var today = new Date().dateFormat(this.format);
      this.todayBtn = new Ext.Button({
        renderTo: this.el.child('td.x-date-bottom', true),
        text: String.format(this.todayText, today),
        tooltip: String.format(this.todayTip, today),
        handler: this.selectToday,
        scope: this
      });
    }

    this.mon(this.eventEl, 'mousewheel', this.handleMouseWheel, this);
    this.mon(this.eventEl, 'click', this.handleDateClick, this, {
      delegate: 'a.x-date-date'
    });
    this.mon(this.mbtn, 'click', this.showMonthPicker, this);
    this.onEnable(true);
  },
  // private
  createMonthPicker: function createMonthPicker() {
    if (!this.monthPicker.dom.firstChild) {
      var buf = ['<table border="0" cellspacing="0">'];

      for (var i = 0; i < 6; i++) {
        buf.push('<tr><td class="x-date-mp-month"><a href="#">', Date.getShortMonthName(i), '</a></td>', '<td class="x-date-mp-month x-date-mp-sep"><a href="#">', Date.getShortMonthName(i + 6), '</a></td>', i === 0 ? '<td class="x-date-mp-ybtn" align="center"><a class="x-date-mp-prev"></a></td><td class="x-date-mp-ybtn" align="center"><a class="x-date-mp-next"></a></td></tr>' : '<td class="x-date-mp-year"><a href="#"></a></td><td class="x-date-mp-year"><a href="#"></a></td></tr>');
      }

      buf.push('<tr class="x-date-mp-btns"><td colspan="4"><button type="button" class="x-date-mp-ok">', this.okText, '</button><button type="button" class="x-date-mp-cancel">', this.cancelText, '</button></td></tr>', '</table>');
      this.monthPicker.update(buf.join(''));
      this.mon(this.monthPicker, 'click', this.onMonthClick, this);
      this.mon(this.monthPicker, 'dblclick', this.onMonthDblClick, this);
      this.mpMonths = this.monthPicker.select('td.x-date-mp-month');
      this.mpYears = this.monthPicker.select('td.x-date-mp-year');
      this.mpMonths.each(function (m, a, i) {
        i += 1;

        if (i % 2 === 0) {
          m.dom.xmonth = 5 + Math.round(i * 0.5);
        } else {
          m.dom.xmonth = Math.round((i - 1) * 0.5);
        }
      });
    }
  },
  // private
  showMonthPicker: function showMonthPicker() {
    if (!this.disabled) {
      this.createMonthPicker();
      var size = this.el.getSize();
      this.monthPicker.setSize(size);
      this.monthPicker.child('table').setSize(size);
      this.mpSelMonth = (this.activeDate || this.value).getMonth();
      this.updateMPMonth(this.mpSelMonth);
      this.mpSelYear = (this.activeDate || this.value).getFullYear();
      this.updateMPYear(this.mpSelYear);
      this.monthPicker.slideIn('t', {
        duration: 0.2
      });
    }
  },
  // private
  updateMPYear: function updateMPYear(y) {
    this.mpyear = y;
    var ys = this.mpYears.elements;

    for (var i = 1; i <= 10; i++) {
      var td = ys[i - 1],
          y2;

      if (i % 2 === 0) {
        y2 = y + Math.round(i * 0.5);
        td.firstChild.innerHTML = y2;
        td.xyear = y2;
      } else {
        y2 = y - (5 - Math.round(i * 0.5));
        td.firstChild.innerHTML = y2;
        td.xyear = y2;
      }

      this.mpYears.item(i - 1)[y2 == this.mpSelYear ? 'addClass' : 'removeClass']('x-date-mp-sel');
    }
  },
  // private
  updateMPMonth: function updateMPMonth(sm) {
    this.mpMonths.each(function (m, a, i) {
      m[m.dom.xmonth == sm ? 'addClass' : 'removeClass']('x-date-mp-sel');
    });
  },
  // private
  selectMPMonth: function selectMPMonth(m) {},
  // private
  onMonthClick: function onMonthClick(e, t) {
    e.stopEvent();
    var el = new Ext.Element(t),
        pn;

    if (el.is('button.x-date-mp-cancel')) {
      this.hideMonthPicker();
    } else if (el.is('button.x-date-mp-ok')) {
      var d = new Date(this.mpSelYear, this.mpSelMonth, (this.activeDate || this.value).getDate());

      if (d.getMonth() != this.mpSelMonth) {
        // 'fix' the JS rolling date conversion if needed
        d = new Date(this.mpSelYear, this.mpSelMonth, 1).getLastDateOfMonth();
      }

      this.update(d);
      this.hideMonthPicker();
    } else if (pn = el.up('td.x-date-mp-month', 2)) {
      this.mpMonths.removeClass('x-date-mp-sel');
      pn.addClass('x-date-mp-sel');
      this.mpSelMonth = pn.dom.xmonth;
    } else if (pn = el.up('td.x-date-mp-year', 2)) {
      this.mpYears.removeClass('x-date-mp-sel');
      pn.addClass('x-date-mp-sel');
      this.mpSelYear = pn.dom.xyear;
    } else if (el.is('a.x-date-mp-prev')) {
      this.updateMPYear(this.mpyear - 10);
    } else if (el.is('a.x-date-mp-next')) {
      this.updateMPYear(this.mpyear + 10);
    }
  },
  // private
  onMonthDblClick: function onMonthDblClick(e, t) {
    e.stopEvent();
    var el = new Ext.Element(t),
        pn;

    if (pn = el.up('td.x-date-mp-month', 2)) {
      this.update(new Date(this.mpSelYear, pn.dom.xmonth, (this.activeDate || this.value).getDate()));
      this.hideMonthPicker();
    } else if (pn = el.up('td.x-date-mp-year', 2)) {
      this.update(new Date(pn.dom.xyear, this.mpSelMonth, (this.activeDate || this.value).getDate()));
      this.hideMonthPicker();
    }
  },
  // private
  hideMonthPicker: function hideMonthPicker(disableAnim) {
    if (this.monthPicker) {
      if (disableAnim === true) {
        this.monthPicker.hide();
      } else {
        this.monthPicker.slideOut('t', {
          duration: 0.2
        });
      }
    }
  },
  // private
  showPrevMonth: function showPrevMonth(e) {
    this.update(this.activeDate.add('mo', -1));
  },
  // private
  showNextMonth: function showNextMonth(e) {
    this.update(this.activeDate.add('mo', 1));
  },
  // private
  showPrevYear: function showPrevYear() {
    this.update(this.activeDate.add('y', -1));
  },
  // private
  showNextYear: function showNextYear() {
    this.update(this.activeDate.add('y', 1));
  },
  // private
  handleMouseWheel: function handleMouseWheel(e) {
    e.stopEvent();

    if (!this.disabled) {
      var delta = e.getWheelDelta();

      if (delta > 0) {
        this.showPrevMonth();
      } else if (delta < 0) {
        this.showNextMonth();
      }
    }
  },
  // private
  handleDateClick: function handleDateClick(e, t) {
    e.stopEvent();

    if (!this.disabled && t.dateValue && !Ext.fly(t.parentNode).hasClass('x-date-disabled')) {
      this.cancelFocus = this.focusOnSelect === false;
      const date = new Date(t.dateValue);

      if (_.indexOf(this.selections, t.dateValue) >= 0) {
        if (this.fireEvent('beforedeselect', this, date, this.value) !== false) {
          _.pull(this.selections, t.dateValue);
        }
      } else {
        if (this.fireEvent('beforeselect', this, date, this.value) !== false) {
          this.selections.push(t.dateValue);
          this.selections.sort();
        }
      }

      this.setValue(date);
      delete this.cancelFocus;
      this.fireEvent('select', this, this.value);
    }
  },
  // private
  selectToday: function selectToday() {
    if (this.todayBtn && !this.todayBtn.disabled) {
      const today = new Date().clearTime();

      if (this.fireEvent('beforeselect', this, today) !== false) {
        this.setValue(today, false);
        this.fireEvent('select', this, this.value);
      }
    }
  },
  // private
  update: function update(date, forceRefresh) {
    if (this.rendered) {
      var vd = this.activeDate,
          vis = this.isVisible();
      this.activeDate = date;

      if (!forceRefresh && vd && this.el) {
        var t = date.getTime();

        if (vd.getMonth() == date.getMonth() && vd.getFullYear() == date.getFullYear()) {
          this.cells.removeClass('x-date-selected'); // this.cells.removeClass('x-date-multiselect');

          this.cells.each(function (c) {
            if (this.allowMultiSelection) {
              if (_.indexOf(this.selections, c.dom.firstChild.dateValue) >= 0) {
                c.addClass('x-date-selected');
              }
            } else {
              if (c.dom.firstChild.dateValue == t) {
                c.addClass('x-date-selected');

                if (vis && !this.cancelFocus) {
                  Ext.fly(c.dom.firstChild).focus(50);
                }

                return false;
              }
            }
          }, this);
          return;
        }
      }

      var days = date.getDaysInMonth(),
          firstOfMonth = date.getFirstDateOfMonth(),
          startingPos = firstOfMonth.getDay() - this.startDay;

      if (startingPos < 0) {
        startingPos += 7;
      }

      days += startingPos;
      var pm = date.add('mo', -1),
          prevStart = pm.getDaysInMonth() - startingPos,
          cells = this.cells.elements,
          textEls = this.textNodes,
          // convert everything to numbers so it's fast
      day = 86400000,
          d = new Date(pm.getFullYear(), pm.getMonth(), prevStart).clearTime(),
          today = new Date().clearTime().getTime(),
          sel = date.clearTime(true).getTime(),
          min = this.minDate ? this.minDate.clearTime(true) : Number.NEGATIVE_INFINITY,
          max = this.maxDate ? this.maxDate.clearTime(true) : Number.POSITIVE_INFINITY,
          ddMatch = this.disabledDatesRE,
          ddText = this.disabledDatesText,
          ddays = this.disabledDays ? this.disabledDays.join('') : false,
          ddaysText = this.disabledDaysText,
          format = this.format;
      const oldStartDate = this.startDate;
      this.startDate = d.clone();

      if (this.showToday) {
        var td = new Date().clearTime(),
            disable = td < min || td > max || ddMatch && format && ddMatch.test(td.dateFormat(format)) || ddays && ddays.indexOf(td.getDay()) != -1;

        if (!this.disabled) {
          this.todayBtn.setDisabled(disable);
          this.todayKeyListener[disable ? 'disable' : 'enable']();
        }
      }

      var setCellClass = function setCellClass(cal, cell) {
        cell.title = '';
        var t = d.getTime();
        cell.firstChild.dateValue = t;

        if (t == today) {
          cell.className += ' x-date-today';
          cell.title = cal.todayText;
        }

        if (cal.allowMultiSelection) {
          if (_.indexOf(cal.selections, t) >= 0) {
            cell.className += ' x-date-selected';
          }
        } else {
          if (t == sel) {
            cell.className += ' x-date-selected';

            if (vis) {
              Ext.fly(cell.firstChild).focus(50);
            }
          }
        } // disabling


        if (t < min) {
          cell.className = ' x-date-disabled';
          cell.title = cal.minText;
          return;
        }

        if (t > max) {
          cell.className = ' x-date-disabled';
          cell.title = cal.maxText;
          return;
        }

        if (ddays) {
          if (ddays.indexOf(d.getDay()) != -1) {
            cell.title = ddaysText;
            cell.className = ' x-date-disabled';
          }
        }

        if (ddMatch && format) {
          var fvalue = d.dateFormat(format);

          if (ddMatch.test(fvalue)) {
            cell.title = ddText.replace('%0', fvalue);
            cell.className = ' x-date-disabled';
          }
        } // apply dateClss


        const dateClss = _.get(this.dateClss, t);

        if (dateClss) {
          cell.className += ' ' + dateClss;
        }
      };

      var i = 0;

      for (; i < startingPos; i++) {
        textEls[i].innerHTML = ++prevStart;
        d.setDate(d.getDate() + 1);
        cells[i].className = 'x-date-prevday';
        setCellClass(this, cells[i]);
      }

      for (; i < days; i++) {
        var intDay = i - startingPos + 1;
        textEls[i].innerHTML = intDay;
        d.setDate(d.getDate() + 1);
        cells[i].className = 'x-date-active';
        setCellClass(this, cells[i]);
      }

      var extraDays = 0;

      for (; i < 42; i++) {
        textEls[i].innerHTML = ++extraDays;
        d.setDate(d.getDate() + 1);
        cells[i].className = 'x-date-nextday';
        setCellClass(this, cells[i]);
      }

      this.mbtn.setText(this.monthNames[date.getMonth()] + ' ' + date.getFullYear());

      if (!this.internalRender) {
        var main = this.el.dom.firstChild,
            w = main.offsetWidth;
        this.el.setWidth(w + this.el.getBorderWidth('lr'));
        Ext.fly(main).setWidth(w);
        this.internalRender = true; // opera does not respect the auto grow header center column
        // then, after it gets a width opera refuses to recalculate
        // without a second pass

        if (Ext.isOpera && !this.secondPass) {
          main.rows[0].cells[1].style.width = w - (main.rows[0].cells[0].offsetWidth + main.rows[0].cells[2].offsetWidth) + 'px';
          this.secondPass = true;
          this.update.defer(10, this, [date]);
        }
      }

      if (!oldStartDate || oldStartDate.getTime() !== this.startDate.getTime()) {
        _.defer(() => {
          this.getPeriod().then(period => {
            this.fireEvent('periodchange', this, period);
          });
        });
      }
    }
  },
  // private
  beforeDestroy: function beforeDestroy() {
    if (this.rendered) {
      Ext.destroy(this.keyNav, this.monthPicker, this.eventEl, this.mbtn, this.nextRepeater, this.prevRepeater, this.cells.el, this.todayBtn);
      delete this.textNodes;
      delete this.cells.elements;
    }
  },
  getPeriod: async function getPeriod() {
    await this.afterIsRendered();
    return {
      from: this.startDate,
      until: this.startDate.add(Date.DAY, 42)
    };
  },
  showLoadMask: async function showLoadMask() {
    await this.afterIsRendered();

    if (!this.loadMask) {
      this.loadMask = new Ext.LoadMask(this.getEl());
    }

    this.loadMask.show.defer(100, this.loadMask);
  },
  hideLoadMask: async function hideLoadMask() {
    if (this.loadMask) {
      this.loadMask.hide.defer(100, this.loadMask);
    }

    return Promise.resolve();
  }
  /**
   * @cfg {String} autoEl @hide
   */

});
Ext.reg('datepicker', Ext.DatePicker);

/***/ }),
/* 777 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.LoadMask
 * A simple utility class for generically masking elements while loading data.  If the {@link #store}
 * config option is specified, the masking will be automatically synchronized with the store's loading
 * process and the mask element will be cached for reuse.  For all other elements, this mask will replace the
 * element's Updater load indicator and will be destroyed after the initial load.
 * <p>Example usage:</p>
 *<pre><code>
// Basic mask:
var myMask = new Ext.LoadMask(Ext.getBody(), {msg:"Please wait..."});
myMask.show();
</code></pre>
 * @constructor
 * Create a new LoadMask
 * @param {Mixed} el The element or DOM node, or its id
 * @param {Object} config The config object
 */
Ext.LoadMask = function (el, config) {
  this.el = Ext.get(el);
  Ext.apply(this, config);

  if (this.store) {
    this.store.on({
      scope: this,
      beforeload: this.onBeforeLoad,
      load: this.onLoad,
      exception: this.onLoad
    });
    this.removeMask = Ext.value(this.removeMask, false);
  } else {
    var um = this.el.getUpdater();
    um.showLoadIndicator = false; // disable the default indicator

    um.on({
      scope: this,
      beforeupdate: this.onBeforeLoad,
      update: this.onLoad,
      failure: this.onLoad
    });
    this.removeMask = Ext.value(this.removeMask, true);
  }
};

Ext.LoadMask.prototype = {
  /**
   * @cfg {Ext.data.Store} store
   * Optional Store to which the mask is bound. The mask is displayed when a load request is issued, and
   * hidden on either load sucess, or load fail.
   */

  /**
   * @cfg {Boolean} removeMask
   * True to create a single-use mask that is automatically destroyed after loading (useful for page loads),
   * False to persist the mask element reference for multiple uses (e.g., for paged data widgets).  Defaults to false.
   */

  /**
   * @cfg {String} msg
   * The text to display in a centered loading message box (defaults to 'Loading...')
   */
  msg: 'Loading...',

  /**
   * @cfg {String} msgCls
   * The CSS class to apply to the loading message element (defaults to "x-mask-loading")
   */
  msgCls: 'x-mask-loading',

  /**
   * Read-only. True if the mask is currently disabled so that it will not be displayed (defaults to false)
   * @type Boolean
   */
  disabled: false,

  /**
   * Disables the mask to prevent it from being displayed
   */
  disable: function disable() {
    this.disabled = true;
  },

  /**
   * Enables the mask so that it can be displayed
   */
  enable: function enable() {
    this.disabled = false;
  },
  // private
  onLoad: function onLoad() {
    this.el.unmask(this.removeMask);
  },
  // private
  onBeforeLoad: function onBeforeLoad() {
    if (!this.disabled) {
      this.el.mask(this.msg, this.msgCls);
    }
  },

  /**
   * Show this LoadMask over the configured Element.
   */
  show: function show() {
    this.onBeforeLoad();
  },

  /**
   * Hide this LoadMask.
   */
  hide: function hide() {
    this.onLoad();
  },
  // private
  destroy: function destroy() {
    if (this.store) {
      this.store.un('beforeload', this.onBeforeLoad, this);
      this.store.un('load', this.onLoad, this);
      this.store.un('exception', this.onLoad, this);
    } else {
      var um = this.el.getUpdater();
      um.un('beforeupdate', this.onBeforeLoad, this);
      um.un('update', this.onLoad, this);
      um.un('failure', this.onLoad, this);
    }
  }
};

/***/ }),
/* 778 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Slider
 * @extends Ext.BoxComponent
 * Slider which supports vertical or horizontal orientation, keyboard adjustments,
 * configurable snapping, axis clicking and animation. Can be added as an item to
 * any container. Example usage:
<pre><code>
new Ext.Slider({
    renderTo: Ext.getBody(),
    width: 200,
    value: 50,
    increment: 10,
    minValue: 0,
    maxValue: 100
});
</code></pre>
 */
Ext.Slider = Ext.extend(Ext.BoxComponent, {
  /**
   * @cfg {Number} value The value to initialize the slider with. Defaults to minValue.
   */

  /**
   * @cfg {Boolean} vertical Orient the Slider vertically rather than horizontally, defaults to false.
   */
  vertical: false,

  /**
   * @cfg {Number} minValue The minimum value for the Slider. Defaults to 0.
   */
  minValue: 0,

  /**
   * @cfg {Number} maxValue The maximum value for the Slider. Defaults to 100.
   */
  maxValue: 100,

  /**
   * @cfg {Number/Boolean} decimalPrecision.
   * <p>The number of decimal places to which to round the Slider's value. Defaults to 0.</p>
   * <p>To disable rounding, configure as <tt><b>false</b></tt>.</p>
   */
  decimalPrecision: 0,

  /**
   * @cfg {Number} keyIncrement How many units to change the Slider when adjusting with keyboard navigation. Defaults to 1. If the increment config is larger, it will be used instead.
   */
  keyIncrement: 1,

  /**
   * @cfg {Number} increment How many units to change the slider when adjusting by drag and drop. Use this option to enable 'snapping'.
   */
  increment: 0,
  // private
  clickRange: [5, 15],

  /**
   * @cfg {Boolean} clickToChange Determines whether or not clicking on the Slider axis will change the slider. Defaults to true
   */
  clickToChange: true,

  /**
   * @cfg {Boolean} animate Turn on or off animation. Defaults to true
   */
  animate: true,

  /**
   * True while the thumb is in a drag operation
   * @type boolean
   */
  dragging: false,
  // private override
  initComponent: function initComponent() {
    if (!Ext.isDefined(this.value)) {
      this.value = this.minValue;
    }

    Ext.Slider.superclass.initComponent.call(this);
    this.keyIncrement = Math.max(this.increment, this.keyIncrement);
    this.addEvents(
    /**
     * @event beforechange
     * Fires before the slider value is changed. By returning false from an event handler,
     * you can cancel the event and prevent the slider from changing.
     * @param {Ext.Slider} slider The slider
     * @param {Number} newValue The new value which the slider is being changed to.
     * @param {Number} oldValue The old value which the slider was previously.
     */
    'beforechange',
    /**
     * @event change
     * Fires when the slider value is changed.
     * @param {Ext.Slider} slider The slider
     * @param {Number} newValue The new value which the slider has been changed to.
     */
    'change',
    /**
     * @event changecomplete
     * Fires when the slider value is changed by the user and any drag operations have completed.
     * @param {Ext.Slider} slider The slider
     * @param {Number} newValue The new value which the slider has been changed to.
     */
    'changecomplete',
    /**
     * @event dragstart
     * Fires after a drag operation has started.
     * @param {Ext.Slider} slider The slider
     * @param {Ext.EventObject} e The event fired from Ext.dd.DragTracker
     */
    'dragstart',
    /**
     * @event drag
     * Fires continuously during the drag operation while the mouse is moving.
     * @param {Ext.Slider} slider The slider
     * @param {Ext.EventObject} e The event fired from Ext.dd.DragTracker
     */
    'drag',
    /**
     * @event dragend
     * Fires after the drag operation has completed.
     * @param {Ext.Slider} slider The slider
     * @param {Ext.EventObject} e The event fired from Ext.dd.DragTracker
     */
    'dragend');

    if (this.vertical) {
      Ext.apply(this, Ext.Slider.Vertical);
    }
  },
  // private override
  onRender: function onRender() {
    this.autoEl = {
      cls: 'x-slider ' + (this.vertical ? 'x-slider-vert' : 'x-slider-horz'),
      cn: {
        cls: 'x-slider-end',
        cn: {
          cls: 'x-slider-inner',
          cn: [{
            cls: 'x-slider-thumb'
          }, {
            tag: 'a',
            cls: 'x-slider-focus',
            href: "#",
            tabIndex: '-1',
            hidefocus: 'on'
          }]
        }
      }
    };
    Ext.Slider.superclass.onRender.apply(this, arguments);
    this.endEl = this.el.first();
    this.innerEl = this.endEl.first();
    this.thumb = this.innerEl.first();
    this.halfThumb = (this.vertical ? this.thumb.getHeight() : this.thumb.getWidth()) / 2;
    this.focusEl = this.thumb.next();
    this.initEvents();
  },
  // private override
  initEvents: function initEvents() {
    this.thumb.addClassOnOver('x-slider-thumb-over');
    this.mon(this.el, {
      scope: this,
      mousedown: this.onMouseDown,
      keydown: this.onKeyDown
    });
    this.focusEl.swallowEvent("click", true);
    this.tracker = new Ext.dd.DragTracker({
      onBeforeStart: this.onBeforeDragStart.createDelegate(this),
      onStart: this.onDragStart.createDelegate(this),
      onDrag: this.onDrag.createDelegate(this),
      onEnd: this.onDragEnd.createDelegate(this),
      tolerance: 3,
      autoStart: 300
    });
    this.tracker.initEl(this.thumb);
  },
  // private override
  onMouseDown: function onMouseDown(e) {
    if (this.disabled) {
      return;
    }

    if (this.clickToChange && e.target != this.thumb.dom) {
      var local = this.innerEl.translatePoints(e.getXY());
      this.onClickChange(local);
    }

    this.focus();
  },
  // private
  onClickChange: function onClickChange(local) {
    if (local.top > this.clickRange[0] && local.top < this.clickRange[1]) {
      this.setValue(Ext.util.Format.round(this.reverseValue(local.left), this.decimalPrecision), undefined, true);
    }
  },
  // private
  onKeyDown: function onKeyDown(e) {
    if (this.disabled) {
      e.preventDefault();
      return;
    }

    var k = e.getKey();

    switch (k) {
      case e.UP:
      case e.RIGHT:
        e.stopEvent();

        if (e.ctrlKey) {
          this.setValue(this.maxValue, undefined, true);
        } else {
          this.setValue(this.value + this.keyIncrement, undefined, true);
        }

        break;

      case e.DOWN:
      case e.LEFT:
        e.stopEvent();

        if (e.ctrlKey) {
          this.setValue(this.minValue, undefined, true);
        } else {
          this.setValue(this.value - this.keyIncrement, undefined, true);
        }

        break;

      default:
        e.preventDefault();
    }
  },
  // private
  doSnap: function doSnap(value) {
    if (!(this.increment && value)) {
      return value;
    }

    var newValue = value,
        inc = this.increment,
        m = value % inc;

    if (m != 0) {
      newValue -= m;

      if (m * 2 > inc) {
        newValue += inc;
      } else if (m * 2 < -inc) {
        newValue -= inc;
      }
    }

    return newValue.constrain(this.minValue, this.maxValue);
  },
  // private
  afterRender: function afterRender() {
    Ext.Slider.superclass.afterRender.apply(this, arguments);

    if (this.value !== undefined) {
      var v = this.normalizeValue(this.value);

      if (v !== this.value) {
        delete this.value;
        this.setValue(v, false);
      } else {
        this.moveThumb(this.translateValue(v), false);
      }
    }
  },
  // private
  getRatio: function getRatio() {
    var w = this.innerEl.getWidth(),
        v = this.maxValue - this.minValue;
    return v == 0 ? w : w / v;
  },
  // private
  normalizeValue: function normalizeValue(v) {
    v = this.doSnap(v);
    v = Ext.util.Format.round(v, this.decimalPrecision);
    v = v.constrain(this.minValue, this.maxValue);
    return v;
  },

  /**
   * Sets the minimum value for the slider instance. If the current value is less than the 
   * minimum value, the current value will be changed.
   * @param {Number} val The new minimum value
   */
  setMinValue: function setMinValue(val) {
    this.minValue = val;
    this.syncThumb();

    if (this.value < val) {
      this.setValue(val);
    }
  },

  /**
   * Sets the maximum value for the slider instance. If the current value is more than the 
   * maximum value, the current value will be changed.
   * @param {Number} val The new maximum value
   */
  setMaxValue: function setMaxValue(val) {
    this.maxValue = val;
    this.syncThumb();

    if (this.value > val) {
      this.setValue(val);
    }
  },

  /**
   * Programmatically sets the value of the Slider. Ensures that the value is constrained within
   * the minValue and maxValue.
   * @param {Number} value The value to set the slider to. (This will be constrained within minValue and maxValue)
   * @param {Boolean} animate Turn on or off animation, defaults to true
   */
  setValue: function setValue(v, animate, changeComplete) {
    v = this.normalizeValue(v);

    if (v !== this.value && this.fireEvent('beforechange', this, v, this.value) !== false) {
      this.value = v;
      this.moveThumb(this.translateValue(v), animate !== false);
      this.fireEvent('change', this, v);

      if (changeComplete) {
        this.fireEvent('changecomplete', this, v);
      }
    }
  },
  // private
  translateValue: function translateValue(v) {
    var ratio = this.getRatio();
    return v * ratio - this.minValue * ratio - this.halfThumb;
  },
  reverseValue: function reverseValue(pos) {
    var ratio = this.getRatio();
    return (pos + this.minValue * ratio) / ratio;
  },
  // private
  moveThumb: function moveThumb(v, animate) {
    if (!animate || this.animate === false) {
      this.thumb.setLeft(v);
    } else {
      this.thumb.shift({
        left: v,
        stopFx: true,
        duration: .35
      });
    }
  },
  // private
  focus: function focus() {
    this.focusEl.focus(10);
  },
  // private
  onBeforeDragStart: function onBeforeDragStart(e) {
    return !this.disabled;
  },
  // private
  onDragStart: function onDragStart(e) {
    this.thumb.addClass('x-slider-thumb-drag');
    this.dragging = true;
    this.dragStartValue = this.value;
    this.fireEvent('dragstart', this, e);
  },
  // private
  onDrag: function onDrag(e) {
    var pos = this.innerEl.translatePoints(this.tracker.getXY());
    this.setValue(Ext.util.Format.round(this.reverseValue(pos.left), this.decimalPrecision), false);
    this.fireEvent('drag', this, e);
  },
  // private
  onDragEnd: function onDragEnd(e) {
    this.thumb.removeClass('x-slider-thumb-drag');
    this.dragging = false;
    this.fireEvent('dragend', this, e);

    if (this.dragStartValue != this.value) {
      this.fireEvent('changecomplete', this, this.value);
    }
  },
  // private
  onResize: function onResize(w, h) {
    this.innerEl.setWidth(w - (this.el.getPadding('l') + this.endEl.getPadding('r')));
    this.syncThumb();
    Ext.Slider.superclass.onResize.apply(this, arguments);
  },
  //private
  onDisable: function onDisable() {
    Ext.Slider.superclass.onDisable.call(this);
    this.thumb.addClass(this.disabledClass);

    if (Ext.isIE) {
      //IE breaks when using overflow visible and opacity other than 1.
      //Create a place holder for the thumb and display it.
      var xy = this.thumb.getXY();
      this.thumb.hide();
      this.innerEl.addClass(this.disabledClass).dom.disabled = true;

      if (!this.thumbHolder) {
        this.thumbHolder = this.endEl.createChild({
          cls: 'x-slider-thumb ' + this.disabledClass
        });
      }

      this.thumbHolder.show().setXY(xy);
    }
  },
  //private
  onEnable: function onEnable() {
    Ext.Slider.superclass.onEnable.call(this);
    this.thumb.removeClass(this.disabledClass);

    if (Ext.isIE) {
      this.innerEl.removeClass(this.disabledClass).dom.disabled = false;

      if (this.thumbHolder) {
        this.thumbHolder.hide();
      }

      this.thumb.show();
      this.syncThumb();
    }
  },

  /**
   * Synchronizes the thumb position to the proper proportion of the total component width based
   * on the current slider {@link #value}.  This will be called automatically when the Slider
   * is resized by a layout, but if it is rendered auto width, this method can be called from
   * another resize handler to sync the Slider if necessary.
   */
  syncThumb: function syncThumb() {
    if (this.rendered) {
      this.moveThumb(this.translateValue(this.value));
    }
  },

  /**
   * Returns the current value of the slider
   * @return {Number} The current value of the slider
   */
  getValue: function getValue() {
    return this.value;
  },
  // private
  beforeDestroy: function beforeDestroy() {
    Ext.destroyMembers(this, 'endEl', 'innerEl', 'thumb', 'halfThumb', 'focusEl', 'tracker', 'thumbHolder');
    Ext.Slider.superclass.beforeDestroy.call(this);
  }
});
Ext.reg('slider', Ext.Slider); // private class to support vertical sliders

Ext.Slider.Vertical = {
  onResize: function onResize(w, h) {
    this.innerEl.setHeight(h - (this.el.getPadding('t') + this.endEl.getPadding('b')));
    this.syncThumb();
  },
  getRatio: function getRatio() {
    var h = this.innerEl.getHeight(),
        v = this.maxValue - this.minValue;
    return h / v;
  },
  moveThumb: function moveThumb(v, animate) {
    if (!animate || this.animate === false) {
      this.thumb.setBottom(v);
    } else {
      this.thumb.shift({
        bottom: v,
        stopFx: true,
        duration: .35
      });
    }
  },
  onDrag: function onDrag(e) {
    var pos = this.innerEl.translatePoints(this.tracker.getXY()),
        bottom = this.innerEl.getHeight() - pos.top;
    this.setValue(this.minValue + Ext.util.Format.round(bottom / this.getRatio(), this.decimalPrecision), false);
    this.fireEvent('drag', this, e);
  },
  onClickChange: function onClickChange(local) {
    if (local.left > this.clickRange[0] && local.left < this.clickRange[1]) {
      var bottom = this.innerEl.getHeight() - local.top;
      this.setValue(this.minValue + Ext.util.Format.round(bottom / this.getRatio(), this.decimalPrecision), undefined, true);
    }
  }
};

/***/ }),
/* 779 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ProgressBar
 * @extends Ext.BoxComponent
 * <p>An updateable progress bar component.  The progress bar supports two different modes: manual and automatic.</p>
 * <p>In manual mode, you are responsible for showing, updating (via {@link #updateProgress}) and clearing the
 * progress bar as needed from your own code.  This method is most appropriate when you want to show progress
 * throughout an operation that has predictable points of interest at which you can update the control.</p>
 * <p>In automatic mode, you simply call {@link #wait} and let the progress bar run indefinitely, only clearing it
 * once the operation is complete.  You can optionally have the progress bar wait for a specific amount of time
 * and then clear itself.  Automatic mode is most appropriate for timed operations or asynchronous operations in
 * which you have no need for indicating intermediate progress.</p>
 * @cfg {Float} value A floating point value between 0 and 1 (e.g., .5, defaults to 0)
 * @cfg {String} text The progress bar text (defaults to '')
 * @cfg {Mixed} textEl The element to render the progress text to (defaults to the progress
 * bar's internal text element)
 * @cfg {String} id The progress bar element's id (defaults to an auto-generated id)
 * @xtype progress
 */
Ext.ProgressBar = Ext.extend(Ext.BoxComponent, {
  /**
   * @cfg {String} baseCls
   * The base CSS class to apply to the progress bar's wrapper element (defaults to 'x-progress')
   */
  baseCls: 'x-progress',

  /**
  * @cfg {Boolean} animate
  * True to animate the progress bar during transitions (defaults to false)
  */
  animate: false,
  // private
  waitTimer: null,
  // private
  initComponent: function initComponent() {
    Ext.ProgressBar.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event update
     * Fires after each update interval
     * @param {Ext.ProgressBar} this
     * @param {Number} The current progress value
     * @param {String} The current progress text
     */
    "update");
  },
  // private
  onRender: function onRender(ct, position) {
    var tpl = new Ext.Template('<div class="{cls}-wrap">', '<div class="{cls}-inner">', '<div class="{cls}-bar">', '<div class="{cls}-text">', '<div>&#160;</div>', '</div>', '</div>', '<div class="{cls}-text {cls}-text-back">', '<div>&#160;</div>', '</div>', '</div>', '</div>');
    this.el = position ? tpl.insertBefore(position, {
      cls: this.baseCls
    }, true) : tpl.append(ct, {
      cls: this.baseCls
    }, true);

    if (this.id) {
      this.el.dom.id = this.id;
    }

    var inner = this.el.dom.firstChild;
    this.progressBar = Ext.get(inner.firstChild);

    if (this.textEl) {
      //use an external text el
      this.textEl = Ext.get(this.textEl);
      delete this.textTopEl;
    } else {
      //setup our internal layered text els
      this.textTopEl = Ext.get(this.progressBar.dom.firstChild);
      var textBackEl = Ext.get(inner.childNodes[1]);
      this.textTopEl.setStyle("z-index", 99).addClass('x-hidden');
      this.textEl = new Ext.CompositeElement([this.textTopEl.dom.firstChild, textBackEl.dom.firstChild]);
      this.textEl.setWidth(inner.offsetWidth);
    }

    this.progressBar.setHeight(inner.offsetHeight);
  },
  // private
  afterRender: function afterRender() {
    Ext.ProgressBar.superclass.afterRender.call(this);

    if (this.value) {
      this.updateProgress(this.value, this.text);
    } else {
      this.updateText(this.text);
    }
  },

  /**
   * Updates the progress bar value, and optionally its text.  If the text argument is not specified,
   * any existing text value will be unchanged.  To blank out existing text, pass ''.  Note that even
   * if the progress bar value exceeds 1, it will never automatically reset -- you are responsible for
   * determining when the progress is complete and calling {@link #reset} to clear and/or hide the control.
   * @param {Float} value (optional) A floating point value between 0 and 1 (e.g., .5, defaults to 0)
   * @param {String} text (optional) The string to display in the progress text element (defaults to '')
   * @param {Boolean} animate (optional) Whether to animate the transition of the progress bar. If this value is
   * not specified, the default for the class is used (default to false)
   * @return {Ext.ProgressBar} this
   */
  updateProgress: function updateProgress(value, text, animate) {
    this.value = value || 0;

    if (text) {
      this.updateText(text);
    }

    if (this.rendered && !this.isDestroyed) {
      var w = Math.floor(value * this.el.dom.firstChild.offsetWidth);
      this.progressBar.setWidth(w, animate === true || animate !== false && this.animate);

      if (this.textTopEl) {
        //textTopEl should be the same width as the bar so overflow will clip as the bar moves
        this.textTopEl.removeClass('x-hidden').setWidth(w);
      }
    }

    this.fireEvent('update', this, value, text);
    return this;
  },

  /**
   * Initiates an auto-updating progress bar.  A duration can be specified, in which case the progress
   * bar will automatically reset after a fixed amount of time and optionally call a callback function
   * if specified.  If no duration is passed in, then the progress bar will run indefinitely and must
   * be manually cleared by calling {@link #reset}.  The wait method accepts a config object with
   * the following properties:
   * <pre>
  Property   Type          Description
  ---------- ------------  ----------------------------------------------------------------------
  duration   Number        The length of time in milliseconds that the progress bar should
                       run before resetting itself (defaults to undefined, in which case it
                       will run indefinitely until reset is called)
  interval   Number        The length of time in milliseconds between each progress update
                       (defaults to 1000 ms)
  animate    Boolean       Whether to animate the transition of the progress bar. If this value is
                       not specified, the default for the class is used.                                                   
  increment  Number        The number of progress update segments to display within the progress
                       bar (defaults to 10).  If the bar reaches the end and is still
                       updating, it will automatically wrap back to the beginning.
  text       String        Optional text to display in the progress bar element (defaults to '').
  fn         Function      A callback function to execute after the progress bar finishes auto-
                       updating.  The function will be called with no arguments.  This function
                       will be ignored if duration is not specified since in that case the
                       progress bar can only be stopped programmatically, so any required function
                       should be called by the same code after it resets the progress bar.
  scope      Object        The scope that is passed to the callback function (only applies when
                       duration and fn are both passed).
  </pre>
       *
       * Example usage:
       * <pre><code>
  var p = new Ext.ProgressBar({
  renderTo: 'my-el'
  });
  //Wait for 5 seconds, then update the status el (progress bar will auto-reset)
  p.wait({
  interval: 100, //bar will move fast!
  duration: 5000,
  increment: 15,
  text: 'Updating...',
  scope: this,
  fn: function(){
    Ext.fly('status').update('Done!');
  }
  });
  //Or update indefinitely until some async action completes, then reset manually
  p.wait();
  myAction.on('complete', function(){
  p.reset();
  Ext.fly('status').update('Done!');
  });
  </code></pre>
   * @param {Object} config (optional) Configuration options
   * @return {Ext.ProgressBar} this
   */
  wait: function wait(o) {
    if (!this.waitTimer) {
      var scope = this;
      o = o || {};
      this.updateText(o.text);
      this.waitTimer = Ext.TaskMgr.start({
        run: function run(i) {
          var inc = o.increment || 10;
          i -= 1;
          this.updateProgress(((i + inc) % inc + 1) * (100 / inc) * 0.01, null, o.animate);
        },
        interval: o.interval || 1000,
        duration: o.duration,
        onStop: function onStop() {
          if (o.fn) {
            o.fn.apply(o.scope || this);
          }

          this.reset();
        },
        scope: scope
      });
    }

    return this;
  },

  /**
   * Returns true if the progress bar is currently in a {@link #wait} operation
   * @return {Boolean} True if waiting, else false
   */
  isWaiting: function isWaiting() {
    return this.waitTimer !== null;
  },

  /**
   * Updates the progress bar text.  If specified, textEl will be updated, otherwise the progress
   * bar itself will display the updated text.
   * @param {String} text (optional) The string to display in the progress text element (defaults to '')
   * @return {Ext.ProgressBar} this
   */
  updateText: function updateText(text) {
    this.text = text || '&#160;';

    if (this.rendered) {
      this.textEl.update(this.text);
    }

    return this;
  },

  /**
   * Synchronizes the inner bar width to the proper proportion of the total componet width based
   * on the current progress {@link #value}.  This will be called automatically when the ProgressBar
   * is resized by a layout, but if it is rendered auto width, this method can be called from
   * another resize handler to sync the ProgressBar if necessary.
   */
  syncProgressBar: function syncProgressBar() {
    if (this.value) {
      this.updateProgress(this.value, this.text);
    }

    return this;
  },

  /**
   * Sets the size of the progress bar.
   * @param {Number} width The new width in pixels
   * @param {Number} height The new height in pixels
   * @return {Ext.ProgressBar} this
   */
  setSize: function setSize(w, h) {
    Ext.ProgressBar.superclass.setSize.call(this, w, h);

    if (this.textTopEl) {
      var inner = this.el.dom.firstChild;
      this.textEl.setSize(inner.offsetWidth, inner.offsetHeight);
    }

    this.syncProgressBar();
    return this;
  },

  /**
   * Resets the progress bar value to 0 and text to empty string.  If hide = true, the progress
   * bar will also be hidden (using the {@link #hideMode} property internally).
   * @param {Boolean} hide (optional) True to hide the progress bar (defaults to false)
   * @return {Ext.ProgressBar} this
   */
  reset: function reset(hide) {
    this.updateProgress(0);

    if (this.textTopEl) {
      this.textTopEl.addClass('x-hidden');
    }

    this.clearTimer();

    if (hide === true) {
      this.hide();
    }

    return this;
  },
  // private
  clearTimer: function clearTimer() {
    if (this.waitTimer) {
      this.waitTimer.onStop = null; //prevent recursion

      Ext.TaskMgr.stop(this.waitTimer);
      this.waitTimer = null;
    }
  },
  onDestroy: function onDestroy() {
    this.clearTimer();

    if (this.rendered) {
      if (this.textEl.isComposite) {
        this.textEl.clear();
      }

      Ext.destroyMembers(this, 'textEl', 'progressBar', 'textTopEl');
    }

    Ext.ProgressBar.superclass.onDestroy.call(this);
  }
});
Ext.reg('progress', Ext.ProgressBar);

/***/ }),
/* 780 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/*
 * These classes are derivatives of the similarly named classes in the YUI Library.
 * The original license:
 * Copyright (c) 2006, Yahoo! Inc. All rights reserved.
 * Code licensed under the BSD License:
 * http://developer.yahoo.net/yui/license.txt
 */
(function () {
  var Event = Ext.EventManager;
  var Dom = Ext.lib.Dom;
  /**
   * @class Ext.dd.DragDrop
   * Defines the interface and base operation of items that that can be
   * dragged or can be drop targets.  It was designed to be extended, overriding
   * the event handlers for startDrag, onDrag, onDragOver and onDragOut.
   * Up to three html elements can be associated with a DragDrop instance:
   * <ul>
   * <li>linked element: the element that is passed into the constructor.
   * This is the element which defines the boundaries for interaction with
   * other DragDrop objects.</li>
   * <li>handle element(s): The drag operation only occurs if the element that
   * was clicked matches a handle element.  By default this is the linked
   * element, but there are times that you will want only a portion of the
   * linked element to initiate the drag operation, and the setHandleElId()
   * method provides a way to define this.</li>
   * <li>drag element: this represents the element that would be moved along
   * with the cursor during a drag operation.  By default, this is the linked
   * element itself as in {@link Ext.dd.DD}.  setDragElId() lets you define
   * a separate element that would be moved, as in {@link Ext.dd.DDProxy}.
   * </li>
   * </ul>
   * This class should not be instantiated until the onload event to ensure that
   * the associated elements are available.
   * The following would define a DragDrop obj that would interact with any
   * other DragDrop obj in the "group1" group:
   * <pre>
   *  dd = new Ext.dd.DragDrop("div1", "group1");
   * </pre>
   * Since none of the event handlers have been implemented, nothing would
   * actually happen if you were to run the code above.  Normally you would
   * override this class or one of the default implementations, but you can
   * also override the methods you want on an instance of the class...
   * <pre>
   *  dd.onDragDrop = function(e, id) {
   *  &nbsp;&nbsp;alert("dd was dropped on " + id);
   *  }
   * </pre>
   * @constructor
   * @param {String} id of the element that is linked to this instance
   * @param {String} sGroup the group of related DragDrop objects
   * @param {object} config an object containing configurable attributes
   *                Valid properties for DragDrop:
   *                    padding, isTarget, maintainOffset, primaryButtonOnly
   */

  Ext.dd.DragDrop = function (id, sGroup, config) {
    if (id) {
      this.init(id, sGroup, config);
    }
  };

  Ext.dd.DragDrop.prototype = {
    /**
     * Set to false to enable a DragDrop object to fire drag events while dragging
     * over its own Element. Defaults to true - DragDrop objects do not by default
     * fire drag events to themselves.
     * @property ignoreSelf
     * @type Boolean
     */

    /**
     * The id of the element associated with this object.  This is what we
     * refer to as the "linked element" because the size and position of
     * this element is used to determine when the drag and drop objects have
     * interacted.
     * @property id
     * @type String
     */
    id: null,

    /**
     * Configuration attributes passed into the constructor
     * @property config
     * @type object
     */
    config: null,

    /**
     * The id of the element that will be dragged.  By default this is same
     * as the linked element , but could be changed to another element. Ex:
     * Ext.dd.DDProxy
     * @property dragElId
     * @type String
     * @private
     */
    dragElId: null,

    /**
     * The ID of the element that initiates the drag operation.  By default
     * this is the linked element, but could be changed to be a child of this
     * element.  This lets us do things like only starting the drag when the
     * header element within the linked html element is clicked.
     * @property handleElId
     * @type String
     * @private
     */
    handleElId: null,

    /**
     * An object who's property names identify HTML tags to be considered invalid as drag handles.
     * A non-null property value identifies the tag as invalid. Defaults to the 
     * following value which prevents drag operations from being initiated by &lt;a> elements:<pre><code>
    {
    A: "A"
    }</code></pre>
     * @property invalidHandleTypes
     * @type Object
     */
    invalidHandleTypes: null,

    /**
     * An object who's property names identify the IDs of elements to be considered invalid as drag handles.
     * A non-null property value identifies the ID as invalid. For example, to prevent
     * dragging from being initiated on element ID "foo", use:<pre><code>
    {
    foo: true
    }</code></pre>
     * @property invalidHandleIds
     * @type Object
     */
    invalidHandleIds: null,

    /**
     * An Array of CSS class names for elements to be considered in valid as drag handles.
     * @property invalidHandleClasses
     * @type Array
     */
    invalidHandleClasses: null,

    /**
     * The linked element's absolute X position at the time the drag was
     * started
     * @property startPageX
     * @type int
     * @private
     */
    startPageX: 0,

    /**
     * The linked element's absolute X position at the time the drag was
     * started
     * @property startPageY
     * @type int
     * @private
     */
    startPageY: 0,

    /**
     * The group defines a logical collection of DragDrop objects that are
     * related.  Instances only get events when interacting with other
     * DragDrop object in the same group.  This lets us define multiple
     * groups using a single DragDrop subclass if we want.
     * @property groups
     * @type object An object in the format {'group1':true, 'group2':true}
     */
    groups: null,

    /**
     * Individual drag/drop instances can be locked.  This will prevent
     * onmousedown start drag.
     * @property locked
     * @type boolean
     * @private
     */
    locked: false,

    /**
     * Lock this instance
     * @method lock
     */
    lock: function lock() {
      this.locked = true;
    },

    /**
     * When set to true, other DD objects in cooperating DDGroups do not receive
     * notification events when this DD object is dragged over them. Defaults to false.
     * @property moveOnly
     * @type boolean
     */
    moveOnly: false,

    /**
     * Unlock this instace
     * @method unlock
     */
    unlock: function unlock() {
      this.locked = false;
    },

    /**
     * By default, all instances can be a drop target.  This can be disabled by
     * setting isTarget to false.
     * @property isTarget
     * @type boolean
     */
    isTarget: true,

    /**
     * The padding configured for this drag and drop object for calculating
     * the drop zone intersection with this object.
     * @property padding
     * @type int[] An array containing the 4 padding values: [top, right, bottom, left]
     */
    padding: null,

    /**
     * Cached reference to the linked element
     * @property _domRef
     * @private
     */
    _domRef: null,

    /**
     * Internal typeof flag
     * @property __ygDragDrop
     * @private
     */
    __ygDragDrop: true,

    /**
     * Set to true when horizontal contraints are applied
     * @property constrainX
     * @type boolean
     * @private
     */
    constrainX: false,

    /**
     * Set to true when vertical contraints are applied
     * @property constrainY
     * @type boolean
     * @private
     */
    constrainY: false,

    /**
     * The left constraint
     * @property minX
     * @type int
     * @private
     */
    minX: 0,

    /**
     * The right constraint
     * @property maxX
     * @type int
     * @private
     */
    maxX: 0,

    /**
     * The up constraint
     * @property minY
     * @type int
     * @type int
     * @private
     */
    minY: 0,

    /**
     * The down constraint
     * @property maxY
     * @type int
     * @private
     */
    maxY: 0,

    /**
     * Maintain offsets when we resetconstraints.  Set to true when you want
     * the position of the element relative to its parent to stay the same
     * when the page changes
     *
     * @property maintainOffset
     * @type boolean
     */
    maintainOffset: false,

    /**
     * Array of pixel locations the element will snap to if we specified a
     * horizontal graduation/interval.  This array is generated automatically
     * when you define a tick interval.
     * @property xTicks
     * @type int[]
     */
    xTicks: null,

    /**
     * Array of pixel locations the element will snap to if we specified a
     * vertical graduation/interval.  This array is generated automatically
     * when you define a tick interval.
     * @property yTicks
     * @type int[]
     */
    yTicks: null,

    /**
     * By default the drag and drop instance will only respond to the primary
     * button click (left button for a right-handed mouse).  Set to true to
     * allow drag and drop to start with any mouse click that is propogated
     * by the browser
     * @property primaryButtonOnly
     * @type boolean
     */
    primaryButtonOnly: true,

    /**
     * The availabe property is false until the linked dom element is accessible.
     * @property available
     * @type boolean
     */
    available: false,

    /**
     * By default, drags can only be initiated if the mousedown occurs in the
     * region the linked element is.  This is done in part to work around a
     * bug in some browsers that mis-report the mousedown if the previous
     * mouseup happened outside of the window.  This property is set to true
     * if outer handles are defined.
     *
     * @property hasOuterHandles
     * @type boolean
     * @default false
     */
    hasOuterHandles: false,

    /**
     * Code that executes immediately before the startDrag event
     * @method b4StartDrag
     * @private
     */
    b4StartDrag: function b4StartDrag(x, y) {},

    /**
     * Abstract method called after a drag/drop object is clicked
     * and the drag or mousedown time thresholds have beeen met.
     * @method startDrag
     * @param {int} X click location
     * @param {int} Y click location
     */
    startDrag: function startDrag(x, y) {
      /* override this */
    },

    /**
     * Code that executes immediately before the onDrag event
     * @method b4Drag
     * @private
     */
    b4Drag: function b4Drag(e) {},

    /**
     * Abstract method called during the onMouseMove event while dragging an
     * object.
     * @method onDrag
     * @param {Event} e the mousemove event
     */
    onDrag: function onDrag(e) {
      /* override this */
    },

    /**
     * Abstract method called when this element fist begins hovering over
     * another DragDrop obj
     * @method onDragEnter
     * @param {Event} e the mousemove event
     * @param {String|DragDrop[]} id In POINT mode, the element
     * id this is hovering over.  In INTERSECT mode, an array of one or more
     * dragdrop items being hovered over.
     */
    onDragEnter: function onDragEnter(e, id) {
      /* override this */
    },

    /**
     * Code that executes immediately before the onDragOver event
     * @method b4DragOver
     * @private
     */
    b4DragOver: function b4DragOver(e) {},

    /**
     * Abstract method called when this element is hovering over another
     * DragDrop obj
     * @method onDragOver
     * @param {Event} e the mousemove event
     * @param {String|DragDrop[]} id In POINT mode, the element
     * id this is hovering over.  In INTERSECT mode, an array of dd items
     * being hovered over.
     */
    onDragOver: function onDragOver(e, id) {
      /* override this */
    },

    /**
     * Code that executes immediately before the onDragOut event
     * @method b4DragOut
     * @private
     */
    b4DragOut: function b4DragOut(e) {},

    /**
     * Abstract method called when we are no longer hovering over an element
     * @method onDragOut
     * @param {Event} e the mousemove event
     * @param {String|DragDrop[]} id In POINT mode, the element
     * id this was hovering over.  In INTERSECT mode, an array of dd items
     * that the mouse is no longer over.
     */
    onDragOut: function onDragOut(e, id) {
      /* override this */
    },

    /**
     * Code that executes immediately before the onDragDrop event
     * @method b4DragDrop
     * @private
     */
    b4DragDrop: function b4DragDrop(e) {},

    /**
     * Abstract method called when this item is dropped on another DragDrop
     * obj
     * @method onDragDrop
     * @param {Event} e the mouseup event
     * @param {String|DragDrop[]} id In POINT mode, the element
     * id this was dropped on.  In INTERSECT mode, an array of dd items this
     * was dropped on.
     */
    onDragDrop: function onDragDrop(e, id) {
      /* override this */
    },

    /**
     * Abstract method called when this item is dropped on an area with no
     * drop target
     * @method onInvalidDrop
     * @param {Event} e the mouseup event
     */
    onInvalidDrop: function onInvalidDrop(e) {
      /* override this */
    },

    /**
     * Code that executes immediately before the endDrag event
     * @method b4EndDrag
     * @private
     */
    b4EndDrag: function b4EndDrag(e) {},

    /**
     * Fired when we are done dragging the object
     * @method endDrag
     * @param {Event} e the mouseup event
     */
    endDrag: function endDrag(e) {
      /* override this */
    },

    /**
     * Code executed immediately before the onMouseDown event
     * @method b4MouseDown
     * @param {Event} e the mousedown event
     * @private
     */
    b4MouseDown: function b4MouseDown(e) {},

    /**
     * Event handler that fires when a drag/drop obj gets a mousedown
     * @method onMouseDown
     * @param {Event} e the mousedown event
     */
    onMouseDown: function onMouseDown(e) {
      /* override this */
    },

    /**
     * Event handler that fires when a drag/drop obj gets a mouseup
     * @method onMouseUp
     * @param {Event} e the mouseup event
     */
    onMouseUp: function onMouseUp(e) {
      /* override this */
    },

    /**
     * Override the onAvailable method to do what is needed after the initial
     * position was determined.
     * @method onAvailable
     */
    onAvailable: function onAvailable() {},

    /**
     * Provides default constraint padding to "constrainTo" elements (defaults to {left: 0, right:0, top:0, bottom:0}).
     * @type Object
     */
    defaultPadding: {
      left: 0,
      right: 0,
      top: 0,
      bottom: 0
    },

    /**
     * Initializes the drag drop object's constraints to restrict movement to a certain element.
    *
    * Usage:
    <pre><code>
    var dd = new Ext.dd.DDProxy("dragDiv1", "proxytest",
                { dragElId: "existingProxyDiv" });
    dd.startDrag = function(){
     this.constrainTo("parent-id");
    };
    </code></pre>
    * Or you can initalize it using the {@link Ext.Element} object:
    <pre><code>
    Ext.get("dragDiv1").initDDProxy("proxytest", {dragElId: "existingProxyDiv"}, {
     startDrag : function(){
         this.constrainTo("parent-id");
     }
    });
    </code></pre>
     * @param {Mixed} constrainTo The element to constrain to.
     * @param {Object/Number} pad (optional) Pad provides a way to specify "padding" of the constraints,
     * and can be either a number for symmetrical padding (4 would be equal to {left:4, right:4, top:4, bottom:4}) or
     * an object containing the sides to pad. For example: {right:10, bottom:10}
     * @param {Boolean} inContent (optional) Constrain the draggable in the content box of the element (inside padding and borders)
     */
    constrainTo: function constrainTo(_constrainTo, pad, inContent) {
      if (Ext.isNumber(pad)) {
        pad = {
          left: pad,
          right: pad,
          top: pad,
          bottom: pad
        };
      }

      pad = pad || this.defaultPadding;
      var b = Ext.get(this.getEl()).getBox(),
          ce = Ext.get(_constrainTo),
          s = ce.getScroll(),
          c,
          cd = ce.dom;

      if (cd == document.body) {
        c = {
          x: s.left,
          y: s.top,
          width: Ext.lib.Dom.getViewWidth(),
          height: Ext.lib.Dom.getViewHeight()
        };
      } else {
        var xy = ce.getXY();
        c = {
          x: xy[0],
          y: xy[1],
          width: cd.clientWidth,
          height: cd.clientHeight
        };
      }

      var topSpace = b.y - c.y,
          leftSpace = b.x - c.x;
      this.resetConstraints();
      this.setXConstraint(leftSpace - (pad.left || 0), // left
      c.width - leftSpace - b.width - (pad.right || 0), //right
      this.xTickSize);
      this.setYConstraint(topSpace - (pad.top || 0), //top
      c.height - topSpace - b.height - (pad.bottom || 0), //bottom
      this.yTickSize);
    },

    /**
     * Returns a reference to the linked element
     * @method getEl
     * @return {HTMLElement} the html element
     */
    getEl: function getEl() {
      if (!this._domRef) {
        this._domRef = Ext.getDom(this.id);
      }

      return this._domRef;
    },

    /**
     * Returns a reference to the actual element to drag.  By default this is
     * the same as the html element, but it can be assigned to another
     * element. An example of this can be found in Ext.dd.DDProxy
     * @method getDragEl
     * @return {HTMLElement} the html element
     */
    getDragEl: function getDragEl() {
      return Ext.getDom(this.dragElId);
    },

    /**
     * Sets up the DragDrop object.  Must be called in the constructor of any
     * Ext.dd.DragDrop subclass
     * @method init
     * @param id the id of the linked element
     * @param {String} sGroup the group of related items
     * @param {object} config configuration attributes
     */
    init: function init(id, sGroup, config) {
      this.initTarget(id, sGroup, config);
      Event.on(this.id, "mousedown", this.handleMouseDown, this); // Event.on(this.id, "selectstart", Event.preventDefault);
    },

    /**
     * Initializes Targeting functionality only... the object does not
     * get a mousedown handler.
     * @method initTarget
     * @param id the id of the linked element
     * @param {String} sGroup the group of related items
     * @param {object} config configuration attributes
     */
    initTarget: function initTarget(id, sGroup, config) {
      // configuration attributes
      this.config = config || {}; // create a local reference to the drag and drop manager

      this.DDM = Ext.dd.DDM; // initialize the groups array

      this.groups = {}; // assume that we have an element reference instead of an id if the
      // parameter is not a string

      if (typeof id !== "string") {
        id = Ext.id(id);
      } // set the id


      this.id = id; // add to an interaction group

      this.addToGroup(sGroup ? sGroup : "default"); // We don't want to register this as the handle with the manager
      // so we just set the id rather than calling the setter.

      this.handleElId = id; // the linked element is the element that gets dragged by default

      this.setDragElId(id); // by default, clicked anchors will not start drag operations.

      this.invalidHandleTypes = {
        A: "A"
      };
      this.invalidHandleIds = {};
      this.invalidHandleClasses = [];
      this.applyConfig();
      this.handleOnAvailable();
    },

    /**
     * Applies the configuration parameters that were passed into the constructor.
     * This is supposed to happen at each level through the inheritance chain.  So
     * a DDProxy implentation will execute apply config on DDProxy, DD, and
     * DragDrop in order to get all of the parameters that are available in
     * each object.
     * @method applyConfig
     */
    applyConfig: function applyConfig() {
      // configurable properties:
      //    padding, isTarget, maintainOffset, primaryButtonOnly
      this.padding = this.config.padding || [0, 0, 0, 0];
      this.isTarget = this.config.isTarget !== false;
      this.maintainOffset = this.config.maintainOffset;
      this.primaryButtonOnly = this.config.primaryButtonOnly !== false;
    },

    /**
     * Executed when the linked element is available
     * @method handleOnAvailable
     * @private
     */
    handleOnAvailable: function handleOnAvailable() {
      this.available = true;
      this.resetConstraints();
      this.onAvailable();
    },

    /**
    * Configures the padding for the target zone in px.  Effectively expands
    * (or reduces) the virtual object size for targeting calculations.
    * Supports css-style shorthand; if only one parameter is passed, all sides
    * will have that padding, and if only two are passed, the top and bottom
    * will have the first param, the left and right the second.
    * @method setPadding
    * @param {int} iTop    Top pad
    * @param {int} iRight  Right pad
    * @param {int} iBot    Bot pad
    * @param {int} iLeft   Left pad
    */
    setPadding: function setPadding(iTop, iRight, iBot, iLeft) {
      // this.padding = [iLeft, iRight, iTop, iBot];
      if (!iRight && 0 !== iRight) {
        this.padding = [iTop, iTop, iTop, iTop];
      } else if (!iBot && 0 !== iBot) {
        this.padding = [iTop, iRight, iTop, iRight];
      } else {
        this.padding = [iTop, iRight, iBot, iLeft];
      }
    },

    /**
     * Stores the initial placement of the linked element.
     * @method setInitPosition
     * @param {int} diffX   the X offset, default 0
     * @param {int} diffY   the Y offset, default 0
     */
    setInitPosition: function setInitPosition(diffX, diffY) {
      var el = this.getEl();

      if (!this.DDM.verifyEl(el)) {
        return;
      }

      var dx = diffX || 0;
      var dy = diffY || 0;
      var p = Dom.getXY(el);
      this.initPageX = p[0] - dx;
      this.initPageY = p[1] - dy;
      this.lastPageX = p[0];
      this.lastPageY = p[1];
      this.setStartPosition(p);
    },

    /**
     * Sets the start position of the element.  This is set when the obj
     * is initialized, the reset when a drag is started.
     * @method setStartPosition
     * @param pos current position (from previous lookup)
     * @private
     */
    setStartPosition: function setStartPosition(pos) {
      var p = pos || Dom.getXY(this.getEl());
      this.deltaSetXY = null;
      this.startPageX = p[0];
      this.startPageY = p[1];
    },

    /**
     * Add this instance to a group of related drag/drop objects.  All
     * instances belong to at least one group, and can belong to as many
     * groups as needed.
     * @method addToGroup
     * @param sGroup {string} the name of the group
     */
    addToGroup: function addToGroup(sGroup) {
      this.groups[sGroup] = true;
      this.DDM.regDragDrop(this, sGroup);
    },

    /**
     * Remove's this instance from the supplied interaction group
     * @method removeFromGroup
     * @param {string}  sGroup  The group to drop
     */
    removeFromGroup: function removeFromGroup(sGroup) {
      if (this.groups[sGroup]) {
        delete this.groups[sGroup];
      }

      this.DDM.removeDDFromGroup(this, sGroup);
    },

    /**
     * Allows you to specify that an element other than the linked element
     * will be moved with the cursor during a drag
     * @method setDragElId
     * @param id {string} the id of the element that will be used to initiate the drag
     */
    setDragElId: function setDragElId(id) {
      this.dragElId = id;
    },

    /**
     * Allows you to specify a child of the linked element that should be
     * used to initiate the drag operation.  An example of this would be if
     * you have a content div with text and links.  Clicking anywhere in the
     * content area would normally start the drag operation.  Use this method
     * to specify that an element inside of the content div is the element
     * that starts the drag operation.
     * @method setHandleElId
     * @param id {string} the id of the element that will be used to
     * initiate the drag.
     */
    setHandleElId: function setHandleElId(id) {
      if (typeof id !== "string") {
        id = Ext.id(id);
      }

      this.handleElId = id;
      this.DDM.regHandle(this.id, id);
    },

    /**
     * Allows you to set an element outside of the linked element as a drag
     * handle
     * @method setOuterHandleElId
     * @param id the id of the element that will be used to initiate the drag
     */
    setOuterHandleElId: function setOuterHandleElId(id) {
      if (typeof id !== "string") {
        id = Ext.id(id);
      }

      Event.on(id, "mousedown", this.handleMouseDown, this);
      this.setHandleElId(id);
      this.hasOuterHandles = true;
    },

    /**
     * Remove all drag and drop hooks for this element
     * @method unreg
     */
    unreg: function unreg() {
      Event.un(this.id, "mousedown", this.handleMouseDown);
      this._domRef = null;

      this.DDM._remove(this);
    },
    destroy: function destroy() {
      this.unreg();
    },

    /**
     * Returns true if this instance is locked, or the drag drop mgr is locked
     * (meaning that all drag/drop is disabled on the page.)
     * @method isLocked
     * @return {boolean} true if this obj or all drag/drop is locked, else
     * false
     */
    isLocked: function isLocked() {
      return this.DDM.isLocked() || this.locked;
    },

    /**
     * Fired when this object is clicked
     * @method handleMouseDown
     * @param {Event} e
     * @param {Ext.dd.DragDrop} oDD the clicked dd object (this dd obj)
     * @private
     */
    handleMouseDown: function handleMouseDown(e, oDD) {
      if (this.primaryButtonOnly && e.button != 0) {
        return;
      }

      if (this.isLocked()) {
        return;
      }

      this.DDM.refreshCache(this.groups);
      var pt = new Ext.lib.Point(Ext.lib.Event.getPageX(e), Ext.lib.Event.getPageY(e));

      if (!this.hasOuterHandles && !this.DDM.isOverTarget(pt, this)) {} else {
        if (this.clickValidator(e)) {
          // set the initial element position
          this.setStartPosition();
          this.b4MouseDown(e);
          this.onMouseDown(e);
          this.DDM.handleMouseDown(e, this);
          this.DDM.stopEvent(e);
        } else {}
      }
    },
    clickValidator: function clickValidator(e) {
      var target = e.getTarget();
      return this.isValidHandleChild(target) && (this.id == this.handleElId || this.DDM.handleWasClicked(target, this.id));
    },

    /**
     * Allows you to specify a tag name that should not start a drag operation
     * when clicked.  This is designed to facilitate embedding links within a
     * drag handle that do something other than start the drag.
     * @method addInvalidHandleType
     * @param {string} tagName the type of element to exclude
     */
    addInvalidHandleType: function addInvalidHandleType(tagName) {
      var type = tagName.toUpperCase();
      this.invalidHandleTypes[type] = type;
    },

    /**
     * Lets you to specify an element id for a child of a drag handle
     * that should not initiate a drag
     * @method addInvalidHandleId
     * @param {string} id the element id of the element you wish to ignore
     */
    addInvalidHandleId: function addInvalidHandleId(id) {
      if (typeof id !== "string") {
        id = Ext.id(id);
      }

      this.invalidHandleIds[id] = id;
    },

    /**
     * Lets you specify a css class of elements that will not initiate a drag
     * @method addInvalidHandleClass
     * @param {string} cssClass the class of the elements you wish to ignore
     */
    addInvalidHandleClass: function addInvalidHandleClass(cssClass) {
      this.invalidHandleClasses.push(cssClass);
    },

    /**
     * Unsets an excluded tag name set by addInvalidHandleType
     * @method removeInvalidHandleType
     * @param {string} tagName the type of element to unexclude
     */
    removeInvalidHandleType: function removeInvalidHandleType(tagName) {
      var type = tagName.toUpperCase(); // this.invalidHandleTypes[type] = null;

      delete this.invalidHandleTypes[type];
    },

    /**
     * Unsets an invalid handle id
     * @method removeInvalidHandleId
     * @param {string} id the id of the element to re-enable
     */
    removeInvalidHandleId: function removeInvalidHandleId(id) {
      if (typeof id !== "string") {
        id = Ext.id(id);
      }

      delete this.invalidHandleIds[id];
    },

    /**
     * Unsets an invalid css class
     * @method removeInvalidHandleClass
     * @param {string} cssClass the class of the element(s) you wish to
     * re-enable
     */
    removeInvalidHandleClass: function removeInvalidHandleClass(cssClass) {
      for (var i = 0, len = this.invalidHandleClasses.length; i < len; ++i) {
        if (this.invalidHandleClasses[i] == cssClass) {
          delete this.invalidHandleClasses[i];
        }
      }
    },

    /**
     * Checks the tag exclusion list to see if this click should be ignored
     * @method isValidHandleChild
     * @param {HTMLElement} node the HTMLElement to evaluate
     * @return {boolean} true if this is a valid tag type, false if not
     */
    isValidHandleChild: function isValidHandleChild(node) {
      var valid = true; // var n = (node.nodeName == "#text") ? node.parentNode : node;

      var nodeName;

      try {
        nodeName = node.nodeName.toUpperCase();
      } catch (e) {
        nodeName = node.nodeName;
      }

      valid = valid && !this.invalidHandleTypes[nodeName];
      valid = valid && !this.invalidHandleIds[node.id];

      for (var i = 0, len = this.invalidHandleClasses.length; valid && i < len; ++i) {
        valid = !Ext.fly(node).hasClass(this.invalidHandleClasses[i]);
      }

      return valid;
    },

    /**
     * Create the array of horizontal tick marks if an interval was specified
     * in setXConstraint().
     * @method setXTicks
     * @private
     */
    setXTicks: function setXTicks(iStartX, iTickSize) {
      this.xTicks = [];
      this.xTickSize = iTickSize;
      var tickMap = {};

      for (var i = this.initPageX; i >= this.minX; i = i - iTickSize) {
        if (!tickMap[i]) {
          this.xTicks[this.xTicks.length] = i;
          tickMap[i] = true;
        }
      }

      for (i = this.initPageX; i <= this.maxX; i = i + iTickSize) {
        if (!tickMap[i]) {
          this.xTicks[this.xTicks.length] = i;
          tickMap[i] = true;
        }
      }

      this.xTicks.sort(this.DDM.numericSort);
    },

    /**
     * Create the array of vertical tick marks if an interval was specified in
     * setYConstraint().
     * @method setYTicks
     * @private
     */
    setYTicks: function setYTicks(iStartY, iTickSize) {
      this.yTicks = [];
      this.yTickSize = iTickSize;
      var tickMap = {};

      for (var i = this.initPageY; i >= this.minY; i = i - iTickSize) {
        if (!tickMap[i]) {
          this.yTicks[this.yTicks.length] = i;
          tickMap[i] = true;
        }
      }

      for (i = this.initPageY; i <= this.maxY; i = i + iTickSize) {
        if (!tickMap[i]) {
          this.yTicks[this.yTicks.length] = i;
          tickMap[i] = true;
        }
      }

      this.yTicks.sort(this.DDM.numericSort);
    },

    /**
     * By default, the element can be dragged any place on the screen.  Use
     * this method to limit the horizontal travel of the element.  Pass in
     * 0,0 for the parameters if you want to lock the drag to the y axis.
     * @method setXConstraint
     * @param {int} iLeft the number of pixels the element can move to the left
     * @param {int} iRight the number of pixels the element can move to the
     * right
     * @param {int} iTickSize optional parameter for specifying that the
     * element
     * should move iTickSize pixels at a time.
     */
    setXConstraint: function setXConstraint(iLeft, iRight, iTickSize) {
      this.leftConstraint = iLeft;
      this.rightConstraint = iRight;
      this.minX = this.initPageX - iLeft;
      this.maxX = this.initPageX + iRight;

      if (iTickSize) {
        this.setXTicks(this.initPageX, iTickSize);
      }

      this.constrainX = true;
    },

    /**
     * Clears any constraints applied to this instance.  Also clears ticks
     * since they can't exist independent of a constraint at this time.
     * @method clearConstraints
     */
    clearConstraints: function clearConstraints() {
      this.constrainX = false;
      this.constrainY = false;
      this.clearTicks();
    },

    /**
     * Clears any tick interval defined for this instance
     * @method clearTicks
     */
    clearTicks: function clearTicks() {
      this.xTicks = null;
      this.yTicks = null;
      this.xTickSize = 0;
      this.yTickSize = 0;
    },

    /**
     * By default, the element can be dragged any place on the screen.  Set
     * this to limit the vertical travel of the element.  Pass in 0,0 for the
     * parameters if you want to lock the drag to the x axis.
     * @method setYConstraint
     * @param {int} iUp the number of pixels the element can move up
     * @param {int} iDown the number of pixels the element can move down
     * @param {int} iTickSize optional parameter for specifying that the
     * element should move iTickSize pixels at a time.
     */
    setYConstraint: function setYConstraint(iUp, iDown, iTickSize) {
      this.topConstraint = iUp;
      this.bottomConstraint = iDown;
      this.minY = this.initPageY - iUp;
      this.maxY = this.initPageY + iDown;

      if (iTickSize) {
        this.setYTicks(this.initPageY, iTickSize);
      }

      this.constrainY = true;
    },

    /**
     * resetConstraints must be called if you manually reposition a dd element.
     * @method resetConstraints
     * @param {boolean} maintainOffset
     */
    resetConstraints: function resetConstraints() {
      // Maintain offsets if necessary
      if (this.initPageX || this.initPageX === 0) {
        // figure out how much this thing has moved
        var dx = this.maintainOffset ? this.lastPageX - this.initPageX : 0;
        var dy = this.maintainOffset ? this.lastPageY - this.initPageY : 0;
        this.setInitPosition(dx, dy); // This is the first time we have detected the element's position
      } else {
        this.setInitPosition();
      }

      if (this.constrainX) {
        this.setXConstraint(this.leftConstraint, this.rightConstraint, this.xTickSize);
      }

      if (this.constrainY) {
        this.setYConstraint(this.topConstraint, this.bottomConstraint, this.yTickSize);
      }
    },

    /**
     * Normally the drag element is moved pixel by pixel, but we can specify
     * that it move a number of pixels at a time.  This method resolves the
     * location when we have it set up like this.
     * @method getTick
     * @param {int} val where we want to place the object
     * @param {int[]} tickArray sorted array of valid points
     * @return {int} the closest tick
     * @private
     */
    getTick: function getTick(val, tickArray) {
      if (!tickArray) {
        // If tick interval is not defined, it is effectively 1 pixel,
        // so we return the value passed to us.
        return val;
      } else if (tickArray[0] >= val) {
        // The value is lower than the first tick, so we return the first
        // tick.
        return tickArray[0];
      } else {
        for (var i = 0, len = tickArray.length; i < len; ++i) {
          var next = i + 1;

          if (tickArray[next] && tickArray[next] >= val) {
            var diff1 = val - tickArray[i];
            var diff2 = tickArray[next] - val;
            return diff2 > diff1 ? tickArray[i] : tickArray[next];
          }
        } // The value is larger than the last tick, so we return the last
        // tick.


        return tickArray[tickArray.length - 1];
      }
    },

    /**
     * toString method
     * @method toString
     * @return {string} string representation of the dd obj
     */
    toString: function toString() {
      return "DragDrop " + this.id;
    }
  };
})();
/**
 * The drag and drop utility provides a framework for building drag and drop
 * applications.  In addition to enabling drag and drop for specific elements,
 * the drag and drop elements are tracked by the manager class, and the
 * interactions between the various elements are tracked during the drag and
 * the implementing code is notified about these important moments.
 */
// Only load the library once.  Rewriting the manager class would orphan
// existing drag and drop instances.


if (!Ext.dd.DragDropMgr) {
  /**
   * @class Ext.dd.DragDropMgr
   * DragDropMgr is a singleton that tracks the element interaction for
   * all DragDrop items in the window.  Generally, you will not call
   * this class directly, but it does have helper methods that could
   * be useful in your DragDrop implementations.
   * @singleton
   */
  Ext.dd.DragDropMgr = function () {
    var Event = Ext.EventManager;
    return {
      /**
       * Two dimensional Array of registered DragDrop objects.  The first
       * dimension is the DragDrop item group, the second the DragDrop
       * object.
       * @property ids
       * @type {string: string}
       * @private
       * @static
       */
      ids: {},

      /**
       * Array of element ids defined as drag handles.  Used to determine
       * if the element that generated the mousedown event is actually the
       * handle and not the html element itself.
       * @property handleIds
       * @type {string: string}
       * @private
       * @static
       */
      handleIds: {},

      /**
       * the DragDrop object that is currently being dragged
       * @property dragCurrent
       * @type DragDrop
       * @private
       * @static
       **/
      dragCurrent: null,

      /**
       * the DragDrop object(s) that are being hovered over
       * @property dragOvers
       * @type Array
       * @private
       * @static
       */
      dragOvers: {},

      /**
       * the X distance between the cursor and the object being dragged
       * @property deltaX
       * @type int
       * @private
       * @static
       */
      deltaX: 0,

      /**
       * the Y distance between the cursor and the object being dragged
       * @property deltaY
       * @type int
       * @private
       * @static
       */
      deltaY: 0,

      /**
       * Flag to determine if we should prevent the default behavior of the
       * events we define. By default this is true, but this can be set to
       * false if you need the default behavior (not recommended)
       * @property preventDefault
       * @type boolean
       * @static
       */
      preventDefault: true,

      /**
       * Flag to determine if we should stop the propagation of the events
       * we generate. This is true by default but you may want to set it to
       * false if the html element contains other features that require the
       * mouse click.
       * @property stopPropagation
       * @type boolean
       * @static
       */
      stopPropagation: true,

      /**
       * Internal flag that is set to true when drag and drop has been
       * intialized
       * @property initialized
       * @private
       * @static
       */
      initialized: false,

      /**
       * All drag and drop can be disabled.
       * @property locked
       * @private
       * @static
       */
      locked: false,

      /**
       * Called the first time an element is registered.
       * @method init
       * @private
       * @static
       */
      init: function init() {
        this.initialized = true;
      },

      /**
       * In point mode, drag and drop interaction is defined by the
       * location of the cursor during the drag/drop
       * @property POINT
       * @type int
       * @static
       */
      POINT: 0,

      /**
       * In intersect mode, drag and drop interaction is defined by the
       * overlap of two or more drag and drop objects.
       * @property INTERSECT
       * @type int
       * @static
       */
      INTERSECT: 1,

      /**
       * The current drag and drop mode.  Default: POINT
       * @property mode
       * @type int
       * @static
       */
      mode: 0,

      /**
       * Runs method on all drag and drop objects
       * @method _execOnAll
       * @private
       * @static
       */
      _execOnAll: function _execOnAll(sMethod, args) {
        for (var i in this.ids) {
          for (var j in this.ids[i]) {
            var oDD = this.ids[i][j];

            if (!this.isTypeOfDD(oDD)) {
              continue;
            }

            oDD[sMethod].apply(oDD, args);
          }
        }
      },

      /**
       * Drag and drop initialization.  Sets up the global event handlers
       * @method _onLoad
       * @private
       * @static
       */
      _onLoad: function _onLoad() {
        this.init();
        Event.on(document, "mouseup", this.handleMouseUp, this, true);
        Event.on(document, "mousemove", this.handleMouseMove, this, true);
        Event.on(window, "unload", this._onUnload, this, true);
        Event.on(window, "resize", this._onResize, this, true); // Event.on(window,   "mouseout",    this._test);
      },

      /**
       * Reset constraints on all drag and drop objs
       * @method _onResize
       * @private
       * @static
       */
      _onResize: function _onResize(e) {
        this._execOnAll("resetConstraints", []);
      },

      /**
       * Lock all drag and drop functionality
       * @method lock
       * @static
       */
      lock: function lock() {
        this.locked = true;
      },

      /**
       * Unlock all drag and drop functionality
       * @method unlock
       * @static
       */
      unlock: function unlock() {
        this.locked = false;
      },

      /**
       * Is drag and drop locked?
       * @method isLocked
       * @return {boolean} True if drag and drop is locked, false otherwise.
       * @static
       */
      isLocked: function isLocked() {
        return this.locked;
      },

      /**
       * Location cache that is set for all drag drop objects when a drag is
       * initiated, cleared when the drag is finished.
       * @property locationCache
       * @private
       * @static
       */
      locationCache: {},

      /**
       * Set useCache to false if you want to force object the lookup of each
       * drag and drop linked element constantly during a drag.
       * @property useCache
       * @type boolean
       * @static
       */
      useCache: true,

      /**
       * The number of pixels that the mouse needs to move after the
       * mousedown before the drag is initiated.  Default=3;
       * @property clickPixelThresh
       * @type int
       * @static
       */
      clickPixelThresh: 3,

      /**
       * The number of milliseconds after the mousedown event to initiate the
       * drag if we don't get a mouseup event. Default=350
       * @property clickTimeThresh
       * @type int
       * @static
       */
      clickTimeThresh: 350,

      /**
       * Flag that indicates that either the drag pixel threshold or the
       * mousdown time threshold has been met
       * @property dragThreshMet
       * @type boolean
       * @private
       * @static
       */
      dragThreshMet: false,

      /**
       * Timeout used for the click time threshold
       * @property clickTimeout
       * @type Object
       * @private
       * @static
       */
      clickTimeout: null,

      /**
       * The X position of the mousedown event stored for later use when a
       * drag threshold is met.
       * @property startX
       * @type int
       * @private
       * @static
       */
      startX: 0,

      /**
       * The Y position of the mousedown event stored for later use when a
       * drag threshold is met.
       * @property startY
       * @type int
       * @private
       * @static
       */
      startY: 0,

      /**
       * Each DragDrop instance must be registered with the DragDropMgr.
       * This is executed in DragDrop.init()
       * @method regDragDrop
       * @param {DragDrop} oDD the DragDrop object to register
       * @param {String} sGroup the name of the group this element belongs to
       * @static
       */
      regDragDrop: function regDragDrop(oDD, sGroup) {
        if (!this.initialized) {
          this.init();
        }

        if (!this.ids[sGroup]) {
          this.ids[sGroup] = {};
        }

        this.ids[sGroup][oDD.id] = oDD;
      },

      /**
       * Removes the supplied dd instance from the supplied group. Executed
       * by DragDrop.removeFromGroup, so don't call this function directly.
       * @method removeDDFromGroup
       * @private
       * @static
       */
      removeDDFromGroup: function removeDDFromGroup(oDD, sGroup) {
        if (!this.ids[sGroup]) {
          this.ids[sGroup] = {};
        }

        var obj = this.ids[sGroup];

        if (obj && obj[oDD.id]) {
          delete obj[oDD.id];
        }
      },

      /**
       * Unregisters a drag and drop item.  This is executed in
       * DragDrop.unreg, use that method instead of calling this directly.
       * @method _remove
       * @private
       * @static
       */
      _remove: function _remove(oDD) {
        for (var g in oDD.groups) {
          if (g && this.ids[g] && this.ids[g][oDD.id]) {
            delete this.ids[g][oDD.id];
          }
        }

        delete this.handleIds[oDD.id];
      },

      /**
       * Each DragDrop handle element must be registered.  This is done
       * automatically when executing DragDrop.setHandleElId()
       * @method regHandle
       * @param {String} sDDId the DragDrop id this element is a handle for
       * @param {String} sHandleId the id of the element that is the drag
       * handle
       * @static
       */
      regHandle: function regHandle(sDDId, sHandleId) {
        if (!this.handleIds[sDDId]) {
          this.handleIds[sDDId] = {};
        }

        this.handleIds[sDDId][sHandleId] = sHandleId;
      },

      /**
       * Utility function to determine if a given element has been
       * registered as a drag drop item.
       * @method isDragDrop
       * @param {String} id the element id to check
       * @return {boolean} true if this element is a DragDrop item,
       * false otherwise
       * @static
       */
      isDragDrop: function isDragDrop(id) {
        return this.getDDById(id) ? true : false;
      },

      /**
       * Returns the drag and drop instances that are in all groups the
       * passed in instance belongs to.
       * @method getRelated
       * @param {DragDrop} p_oDD the obj to get related data for
       * @param {boolean} bTargetsOnly if true, only return targetable objs
       * @return {DragDrop[]} the related instances
       * @static
       */
      getRelated: function getRelated(p_oDD, bTargetsOnly) {
        var oDDs = [];

        for (var i in p_oDD.groups) {
          for (var j in this.ids[i]) {
            var dd = this.ids[i][j];

            if (!this.isTypeOfDD(dd)) {
              continue;
            }

            if (!bTargetsOnly || dd.isTarget) {
              oDDs[oDDs.length] = dd;
            }
          }
        }

        return oDDs;
      },

      /**
       * Returns true if the specified dd target is a legal target for
       * the specifice drag obj
       * @method isLegalTarget
       * @param {DragDrop} the drag obj
       * @param {DragDrop} the target
       * @return {boolean} true if the target is a legal target for the
       * dd obj
       * @static
       */
      isLegalTarget: function isLegalTarget(oDD, oTargetDD) {
        var targets = this.getRelated(oDD, true);

        for (var i = 0, len = targets.length; i < len; ++i) {
          if (targets[i].id == oTargetDD.id) {
            return true;
          }
        }

        return false;
      },

      /**
       * My goal is to be able to transparently determine if an object is
       * typeof DragDrop, and the exact subclass of DragDrop.  typeof
       * returns "object", oDD.constructor.toString() always returns
       * "DragDrop" and not the name of the subclass.  So for now it just
       * evaluates a well-known variable in DragDrop.
       * @method isTypeOfDD
       * @param {Object} the object to evaluate
       * @return {boolean} true if typeof oDD = DragDrop
       * @static
       */
      isTypeOfDD: function isTypeOfDD(oDD) {
        return oDD && oDD.__ygDragDrop;
      },

      /**
       * Utility function to determine if a given element has been
       * registered as a drag drop handle for the given Drag Drop object.
       * @method isHandle
       * @param {String} id the element id to check
       * @return {boolean} true if this element is a DragDrop handle, false
       * otherwise
       * @static
       */
      isHandle: function isHandle(sDDId, sHandleId) {
        return this.handleIds[sDDId] && this.handleIds[sDDId][sHandleId];
      },

      /**
       * Returns the DragDrop instance for a given id
       * @method getDDById
       * @param {String} id the id of the DragDrop object
       * @return {DragDrop} the drag drop object, null if it is not found
       * @static
       */
      getDDById: function getDDById(id) {
        for (var i in this.ids) {
          if (this.ids[i][id]) {
            return this.ids[i][id];
          }
        }

        return null;
      },

      /**
       * Fired after a registered DragDrop object gets the mousedown event.
       * Sets up the events required to track the object being dragged
       * @method handleMouseDown
       * @param {Event} e the event
       * @param oDD the DragDrop object being dragged
       * @private
       * @static
       */
      handleMouseDown: function handleMouseDown(e, oDD) {
        if (Ext.QuickTips) {
          Ext.QuickTips.disable();
        }

        if (this.dragCurrent) {
          // the original browser mouseup wasn't handled (e.g. outside FF browser window)
          // so clean up first to avoid breaking the next drag
          this.handleMouseUp(e);
        }

        this.currentTarget = e.getTarget();
        this.dragCurrent = oDD;
        var el = oDD.getEl(); // track start position

        this.startX = e.getPageX();
        this.startY = e.getPageY();
        this.deltaX = this.startX - el.offsetLeft;
        this.deltaY = this.startY - el.offsetTop;
        this.dragThreshMet = false;
        this.clickTimeout = setTimeout(function () {
          var DDM = Ext.dd.DDM;
          DDM.startDrag(DDM.startX, DDM.startY);
        }, this.clickTimeThresh);
      },

      /**
       * Fired when either the drag pixel threshol or the mousedown hold
       * time threshold has been met.
       * @method startDrag
       * @param x {int} the X position of the original mousedown
       * @param y {int} the Y position of the original mousedown
       * @static
       */
      startDrag: function startDrag(x, y) {
        clearTimeout(this.clickTimeout);

        if (this.dragCurrent) {
          this.dragCurrent.b4StartDrag(x, y);
          this.dragCurrent.startDrag(x, y);
        }

        this.dragThreshMet = true;
      },

      /**
       * Internal function to handle the mouseup event.  Will be invoked
       * from the context of the document.
       * @method handleMouseUp
       * @param {Event} e the event
       * @private
       * @static
       */
      handleMouseUp: function handleMouseUp(e) {
        if (Ext.QuickTips) {
          Ext.QuickTips.enable();
        }

        if (!this.dragCurrent) {
          return;
        }

        clearTimeout(this.clickTimeout);

        if (this.dragThreshMet) {
          this.fireEvents(e, true);
        } else {}

        this.stopDrag(e);
        this.stopEvent(e);
      },

      /**
       * Utility to stop event propagation and event default, if these
       * features are turned on.
       * @method stopEvent
       * @param {Event} e the event as returned by this.getEvent()
       * @static
       */
      stopEvent: function stopEvent(e) {
        if (this.stopPropagation) {
          e.stopPropagation();
        }

        if (this.preventDefault) {
          e.preventDefault();
        }
      },

      /**
       * Internal function to clean up event handlers after the drag
       * operation is complete
       * @method stopDrag
       * @param {Event} e the event
       * @private
       * @static
       */
      stopDrag: function stopDrag(e) {
        // Fire the drag end event for the item that was dragged
        if (this.dragCurrent) {
          if (this.dragThreshMet) {
            this.dragCurrent.b4EndDrag(e);
            this.dragCurrent.endDrag(e);
          }

          this.dragCurrent.onMouseUp(e);
        }

        this.dragCurrent = null;
        this.dragOvers = {};
      },

      /**
       * Internal function to handle the mousemove event.  Will be invoked
       * from the context of the html element.
       *
       * @TODO figure out what we can do about mouse events lost when the
       * user drags objects beyond the window boundary.  Currently we can
       * detect this in internet explorer by verifying that the mouse is
       * down during the mousemove event.  Firefox doesn't give us the
       * button state on the mousemove event.
       * @method handleMouseMove
       * @param {Event} e the event
       * @private
       * @static
       */
      handleMouseMove: function handleMouseMove(e) {
        if (!this.dragCurrent) {
          return true;
        } // var button = e.which || e.button;
        // check for IE mouseup outside of page boundary


        if (Ext.isIE && e.button !== 0 && e.button !== 1 && e.button !== 2) {
          this.stopEvent(e);
          return this.handleMouseUp(e);
        }

        if (!this.dragThreshMet) {
          var diffX = Math.abs(this.startX - e.getPageX());
          var diffY = Math.abs(this.startY - e.getPageY());

          if (diffX > this.clickPixelThresh || diffY > this.clickPixelThresh) {
            this.startDrag(this.startX, this.startY);
          }
        }

        if (this.dragThreshMet) {
          this.dragCurrent.b4Drag(e);
          this.dragCurrent.onDrag(e);

          if (!this.dragCurrent.moveOnly) {
            this.fireEvents(e, false);
          }
        }

        this.stopEvent(e);
        return true;
      },

      /**
       * Iterates over all of the DragDrop elements to find ones we are
       * hovering over or dropping on
       * @method fireEvents
       * @param {Event} e the event
       * @param {boolean} isDrop is this a drop op or a mouseover op?
       * @private
       * @static
       */
      fireEvents: function fireEvents(e, isDrop) {
        var dc = this.dragCurrent; // If the user did the mouse up outside of the window, we could
        // get here even though we have ended the drag.

        if (!dc || dc.isLocked()) {
          return;
        }

        var pt = e.getPoint(); // cache the previous dragOver array

        var oldOvers = [];
        var outEvts = [];
        var overEvts = [];
        var dropEvts = [];
        var enterEvts = []; // Check to see if the object(s) we were hovering over is no longer
        // being hovered over so we can fire the onDragOut event

        for (var i in this.dragOvers) {
          var ddo = this.dragOvers[i];

          if (!this.isTypeOfDD(ddo)) {
            continue;
          }

          if (!this.isOverTarget(pt, ddo, this.mode)) {
            outEvts.push(ddo);
          }

          oldOvers[i] = true;
          delete this.dragOvers[i];
        }

        for (var sGroup in dc.groups) {
          if ("string" != typeof sGroup) {
            continue;
          }

          for (i in this.ids[sGroup]) {
            var oDD = this.ids[sGroup][i];

            if (!this.isTypeOfDD(oDD)) {
              continue;
            }

            if (oDD.isTarget && !oDD.isLocked() && (oDD != dc || dc.ignoreSelf === false)) {
              if (this.isOverTarget(pt, oDD, this.mode)) {
                // look for drop interactions
                if (isDrop) {
                  dropEvts.push(oDD); // look for drag enter and drag over interactions
                } else {
                  // initial drag over: dragEnter fires
                  if (!oldOvers[oDD.id]) {
                    enterEvts.push(oDD); // subsequent drag overs: dragOver fires
                  } else {
                    overEvts.push(oDD);
                  }

                  this.dragOvers[oDD.id] = oDD;
                }
              }
            }
          }
        }

        if (this.mode) {
          if (outEvts.length) {
            dc.b4DragOut(e, outEvts);
            dc.onDragOut(e, outEvts);
          }

          if (enterEvts.length) {
            dc.onDragEnter(e, enterEvts);
          }

          if (overEvts.length) {
            dc.b4DragOver(e, overEvts);
            dc.onDragOver(e, overEvts);
          }

          if (dropEvts.length) {
            dc.b4DragDrop(e, dropEvts);
            dc.onDragDrop(e, dropEvts);
          }
        } else {
          // fire dragout events
          var len = 0;

          for (i = 0, len = outEvts.length; i < len; ++i) {
            dc.b4DragOut(e, outEvts[i].id);
            dc.onDragOut(e, outEvts[i].id);
          } // fire enter events


          for (i = 0, len = enterEvts.length; i < len; ++i) {
            // dc.b4DragEnter(e, oDD.id);
            dc.onDragEnter(e, enterEvts[i].id);
          } // fire over events


          for (i = 0, len = overEvts.length; i < len; ++i) {
            dc.b4DragOver(e, overEvts[i].id);
            dc.onDragOver(e, overEvts[i].id);
          } // fire drop events


          for (i = 0, len = dropEvts.length; i < len; ++i) {
            dc.b4DragDrop(e, dropEvts[i].id);
            dc.onDragDrop(e, dropEvts[i].id);
          }
        } // notify about a drop that did not find a target


        if (isDrop && !dropEvts.length) {
          dc.onInvalidDrop(e);
        }
      },

      /**
       * Helper function for getting the best match from the list of drag
       * and drop objects returned by the drag and drop events when we are
       * in INTERSECT mode.  It returns either the first object that the
       * cursor is over, or the object that has the greatest overlap with
       * the dragged element.
       * @method getBestMatch
       * @param  {DragDrop[]} dds The array of drag and drop objects
       * targeted
       * @return {DragDrop}       The best single match
       * @static
       */
      getBestMatch: function getBestMatch(dds) {
        var winner = null; // Return null if the input is not what we expect
        //if (!dds || !dds.length || dds.length == 0) {
        // winner = null;
        // If there is only one item, it wins
        //} else if (dds.length == 1) {

        var len = dds.length;

        if (len == 1) {
          winner = dds[0];
        } else {
          // Loop through the targeted items
          for (var i = 0; i < len; ++i) {
            var dd = dds[i]; // If the cursor is over the object, it wins.  If the
            // cursor is over multiple matches, the first one we come
            // to wins.

            if (dd.cursorIsOver) {
              winner = dd;
              break; // Otherwise the object with the most overlap wins
            } else {
              if (!winner || winner.overlap.getArea() < dd.overlap.getArea()) {
                winner = dd;
              }
            }
          }
        }

        return winner;
      },

      /**
       * Refreshes the cache of the top-left and bottom-right points of the
       * drag and drop objects in the specified group(s).  This is in the
       * format that is stored in the drag and drop instance, so typical
       * usage is:
       * <code>
       * Ext.dd.DragDropMgr.refreshCache(ddinstance.groups);
       * </code>
       * Alternatively:
       * <code>
       * Ext.dd.DragDropMgr.refreshCache({group1:true, group2:true});
       * </code>
       * @TODO this really should be an indexed array.  Alternatively this
       * method could accept both.
       * @method refreshCache
       * @param {Object} groups an associative array of groups to refresh
       * @static
       */
      refreshCache: function refreshCache(groups) {
        for (var sGroup in groups) {
          if ("string" != typeof sGroup) {
            continue;
          }

          for (var i in this.ids[sGroup]) {
            var oDD = this.ids[sGroup][i];

            if (this.isTypeOfDD(oDD)) {
              // if (this.isTypeOfDD(oDD) && oDD.isTarget) {
              var loc = this.getLocation(oDD);

              if (loc) {
                this.locationCache[oDD.id] = loc;
              } else {
                delete this.locationCache[oDD.id]; // this will unregister the drag and drop object if
                // the element is not in a usable state
                // oDD.unreg();
              }
            }
          }
        }
      },

      /**
       * This checks to make sure an element exists and is in the DOM.  The
       * main purpose is to handle cases where innerHTML is used to remove
       * drag and drop objects from the DOM.  IE provides an 'unspecified
       * error' when trying to access the offsetParent of such an element
       * @method verifyEl
       * @param {HTMLElement} el the element to check
       * @return {boolean} true if the element looks usable
       * @static
       */
      verifyEl: function verifyEl(el) {
        if (el) {
          var parent;

          if (Ext.isIE) {
            try {
              parent = el.offsetParent;
            } catch (e) {}
          } else {
            parent = el.offsetParent;
          }

          if (parent) {
            return true;
          }
        }

        return false;
      },

      /**
       * Returns a Region object containing the drag and drop element's position
       * and size, including the padding configured for it
       * @method getLocation
       * @param {DragDrop} oDD the drag and drop object to get the
       *                       location for
       * @return {Ext.lib.Region} a Region object representing the total area
       *                             the element occupies, including any padding
       *                             the instance is configured for.
       * @static
       */
      getLocation: function getLocation(oDD) {
        if (!this.isTypeOfDD(oDD)) {
          return null;
        }

        var el = oDD.getEl(),
            pos,
            x1,
            x2,
            y1,
            y2,
            t,
            r,
            b,
            l;

        try {
          pos = Ext.lib.Dom.getXY(el);
        } catch (e) {}

        if (!pos) {
          return null;
        }

        x1 = pos[0];
        x2 = x1 + el.offsetWidth;
        y1 = pos[1];
        y2 = y1 + el.offsetHeight;
        t = y1 - oDD.padding[0];
        r = x2 + oDD.padding[1];
        b = y2 + oDD.padding[2];
        l = x1 - oDD.padding[3];
        return new Ext.lib.Region(t, r, b, l);
      },

      /**
       * Checks the cursor location to see if it over the target
       * @method isOverTarget
       * @param {Ext.lib.Point} pt The point to evaluate
       * @param {DragDrop} oTarget the DragDrop object we are inspecting
       * @return {boolean} true if the mouse is over the target
       * @private
       * @static
       */
      isOverTarget: function isOverTarget(pt, oTarget, intersect) {
        // use cache if available
        var loc = this.locationCache[oTarget.id];

        if (!loc || !this.useCache) {
          loc = this.getLocation(oTarget);
          this.locationCache[oTarget.id] = loc;
        }

        if (!loc) {
          return false;
        }

        oTarget.cursorIsOver = loc.contains(pt); // DragDrop is using this as a sanity check for the initial mousedown
        // in this case we are done.  In POINT mode, if the drag obj has no
        // contraints, we are also done. Otherwise we need to evaluate the
        // location of the target as related to the actual location of the
        // dragged element.

        var dc = this.dragCurrent;

        if (!dc || !dc.getTargetCoord || !intersect && !dc.constrainX && !dc.constrainY) {
          return oTarget.cursorIsOver;
        }

        oTarget.overlap = null; // Get the current location of the drag element, this is the
        // location of the mouse event less the delta that represents
        // where the original mousedown happened on the element.  We
        // need to consider constraints and ticks as well.

        var pos = dc.getTargetCoord(pt.x, pt.y);
        var el = dc.getDragEl();
        var curRegion = new Ext.lib.Region(pos.y, pos.x + el.offsetWidth, pos.y + el.offsetHeight, pos.x);
        var overlap = curRegion.intersect(loc);

        if (overlap) {
          oTarget.overlap = overlap;
          return intersect ? true : oTarget.cursorIsOver;
        } else {
          return false;
        }
      },

      /**
       * unload event handler
       * @method _onUnload
       * @private
       * @static
       */
      _onUnload: function _onUnload(e, me) {
        Ext.dd.DragDropMgr.unregAll();
      },

      /**
       * Cleans up the drag and drop events and objects.
       * @method unregAll
       * @private
       * @static
       */
      unregAll: function unregAll() {
        if (this.dragCurrent) {
          this.stopDrag();
          this.dragCurrent = null;
        }

        this._execOnAll("unreg", []);

        for (var i in this.elementCache) {
          delete this.elementCache[i];
        }

        this.elementCache = {};
        this.ids = {};
      },

      /**
       * A cache of DOM elements
       * @property elementCache
       * @private
       * @static
       */
      elementCache: {},

      /**
       * Get the wrapper for the DOM element specified
       * @method getElWrapper
       * @param {String} id the id of the element to get
       * @return {Ext.dd.DDM.ElementWrapper} the wrapped element
       * @private
       * @deprecated This wrapper isn't that useful
       * @static
       */
      getElWrapper: function getElWrapper(id) {
        var oWrapper = this.elementCache[id];

        if (!oWrapper || !oWrapper.el) {
          oWrapper = this.elementCache[id] = new this.ElementWrapper(Ext.getDom(id));
        }

        return oWrapper;
      },

      /**
       * Returns the actual DOM element
       * @method getElement
       * @param {String} id the id of the elment to get
       * @return {Object} The element
       * @deprecated use Ext.lib.Ext.getDom instead
       * @static
       */
      getElement: function getElement(id) {
        return Ext.getDom(id);
      },

      /**
       * Returns the style property for the DOM element (i.e.,
       * document.getElById(id).style)
       * @method getCss
       * @param {String} id the id of the elment to get
       * @return {Object} The style property of the element
       * @deprecated use Ext.lib.Dom instead
       * @static
       */
      getCss: function getCss(id) {
        var el = Ext.getDom(id);
        return el ? el.style : null;
      },

      /**
       * Inner class for cached elements
       * @class Ext.dd.DragDropMgr.ElementWrapper
       * @for DragDropMgr
       * @private
       * @deprecated
       */
      ElementWrapper: function ElementWrapper(el) {
        /**
         * The element
         * @property el
         */
        this.el = el || null;
        /**
         * The element id
         * @property id
         */

        this.id = this.el && el.id;
        /**
         * A reference to the style property
         * @property css
         */

        this.css = this.el && el.style;
      },

      /**
       * Returns the X position of an html element
       * @method getPosX
       * @param el the element for which to get the position
       * @return {int} the X coordinate
       * @for DragDropMgr
       * @deprecated use Ext.lib.Dom.getX instead
       * @static
       */
      getPosX: function getPosX(el) {
        return Ext.lib.Dom.getX(el);
      },

      /**
       * Returns the Y position of an html element
       * @method getPosY
       * @param el the element for which to get the position
       * @return {int} the Y coordinate
       * @deprecated use Ext.lib.Dom.getY instead
       * @static
       */
      getPosY: function getPosY(el) {
        return Ext.lib.Dom.getY(el);
      },

      /**
       * Swap two nodes.  In IE, we use the native method, for others we
       * emulate the IE behavior
       * @method swapNode
       * @param n1 the first node to swap
       * @param n2 the other node to swap
       * @static
       */
      swapNode: function swapNode(n1, n2) {
        if (n1.swapNode) {
          n1.swapNode(n2);
        } else {
          var p = n2.parentNode;
          var s = n2.nextSibling;

          if (s == n1) {
            p.insertBefore(n1, n2);
          } else if (n2 == n1.nextSibling) {
            p.insertBefore(n2, n1);
          } else {
            n1.parentNode.replaceChild(n2, n1);
            p.insertBefore(n1, s);
          }
        }
      },

      /**
       * Returns the current scroll position
       * @method getScroll
       * @private
       * @static
       */
      getScroll: function getScroll() {
        var t,
            l,
            dde = document.documentElement,
            db = document.body;

        if (dde && (dde.scrollTop || dde.scrollLeft)) {
          t = dde.scrollTop;
          l = dde.scrollLeft;
        } else if (db) {
          t = db.scrollTop;
          l = db.scrollLeft;
        } else {}

        return {
          top: t,
          left: l
        };
      },

      /**
       * Returns the specified element style property
       * @method getStyle
       * @param {HTMLElement} el          the element
       * @param {string}      styleProp   the style property
       * @return {string} The value of the style property
       * @deprecated use Ext.lib.Dom.getStyle
       * @static
       */
      getStyle: function getStyle(el, styleProp) {
        return Ext.fly(el).getStyle(styleProp);
      },

      /**
       * Gets the scrollTop
       * @method getScrollTop
       * @return {int} the document's scrollTop
       * @static
       */
      getScrollTop: function getScrollTop() {
        return this.getScroll().top;
      },

      /**
       * Gets the scrollLeft
       * @method getScrollLeft
       * @return {int} the document's scrollTop
       * @static
       */
      getScrollLeft: function getScrollLeft() {
        return this.getScroll().left;
      },

      /**
       * Sets the x/y position of an element to the location of the
       * target element.
       * @method moveToEl
       * @param {HTMLElement} moveEl      The element to move
       * @param {HTMLElement} targetEl    The position reference element
       * @static
       */
      moveToEl: function moveToEl(moveEl, targetEl) {
        var aCoord = Ext.lib.Dom.getXY(targetEl);
        Ext.lib.Dom.setXY(moveEl, aCoord);
      },

      /**
       * Numeric array sort function
       * @method numericSort
       * @static
       */
      numericSort: function numericSort(a, b) {
        return a - b;
      },

      /**
       * Internal counter
       * @property _timeoutCount
       * @private
       * @static
       */
      _timeoutCount: 0,

      /**
       * Trying to make the load order less important.  Without this we get
       * an error if this file is loaded before the Event Utility.
       * @method _addListeners
       * @private
       * @static
       */
      _addListeners: function _addListeners() {
        var DDM = Ext.dd.DDM;

        if (Ext.lib.Event && document) {
          DDM._onLoad();
        } else {
          if (DDM._timeoutCount > 2000) {} else {
            setTimeout(DDM._addListeners, 10);

            if (document && document.body) {
              DDM._timeoutCount += 1;
            }
          }
        }
      },

      /**
       * Recursively searches the immediate parent and all child nodes for
       * the handle element in order to determine wheter or not it was
       * clicked.
       * @method handleWasClicked
       * @param node the html element to inspect
       * @static
       */
      handleWasClicked: function handleWasClicked(node, id) {
        if (this.isHandle(id, node.id)) {
          return true;
        } else {
          // check to see if this is a text node child of the one we want
          var p = node.parentNode;

          while (p) {
            if (this.isHandle(id, p.id)) {
              return true;
            } else {
              p = p.parentNode;
            }
          }
        }

        return false;
      }
    };
  }(); // shorter alias, save a few bytes


  Ext.dd.DDM = Ext.dd.DragDropMgr;

  Ext.dd.DDM._addListeners();
}
/**
 * @class Ext.dd.DD
 * A DragDrop implementation where the linked element follows the
 * mouse cursor during a drag.
 * @extends Ext.dd.DragDrop
 * @constructor
 * @param {String} id the id of the linked element
 * @param {String} sGroup the group of related DragDrop items
 * @param {object} config an object containing configurable attributes
 *                Valid properties for DD:
 *                    scroll
 */


Ext.dd.DD = function (id, sGroup, config) {
  if (id) {
    this.init(id, sGroup, config);
  }
};

Ext.extend(Ext.dd.DD, Ext.dd.DragDrop, {
  /**
   * When set to true, the utility automatically tries to scroll the browser
   * window when a drag and drop element is dragged near the viewport boundary.
   * Defaults to true.
   * @property scroll
   * @type boolean
   */
  scroll: true,

  /**
   * Sets the pointer offset to the distance between the linked element's top
   * left corner and the location the element was clicked
   * @method autoOffset
   * @param {int} iPageX the X coordinate of the click
   * @param {int} iPageY the Y coordinate of the click
   */
  autoOffset: function autoOffset(iPageX, iPageY) {
    var x = iPageX - this.startPageX;
    var y = iPageY - this.startPageY;
    this.setDelta(x, y);
  },

  /**
   * Sets the pointer offset.  You can call this directly to force the
   * offset to be in a particular location (e.g., pass in 0,0 to set it
   * to the center of the object)
   * @method setDelta
   * @param {int} iDeltaX the distance from the left
   * @param {int} iDeltaY the distance from the top
   */
  setDelta: function setDelta(iDeltaX, iDeltaY) {
    this.deltaX = iDeltaX;
    this.deltaY = iDeltaY;
  },

  /**
   * Sets the drag element to the location of the mousedown or click event,
   * maintaining the cursor location relative to the location on the element
   * that was clicked.  Override this if you want to place the element in a
   * location other than where the cursor is.
   * @method setDragElPos
   * @param {int} iPageX the X coordinate of the mousedown or drag event
   * @param {int} iPageY the Y coordinate of the mousedown or drag event
   */
  setDragElPos: function setDragElPos(iPageX, iPageY) {
    // the first time we do this, we are going to check to make sure
    // the element has css positioning
    var el = this.getDragEl();
    this.alignElWithMouse(el, iPageX, iPageY);
  },

  /**
   * Sets the element to the location of the mousedown or click event,
   * maintaining the cursor location relative to the location on the element
   * that was clicked.  Override this if you want to place the element in a
   * location other than where the cursor is.
   * @method alignElWithMouse
   * @param {HTMLElement} el the element to move
   * @param {int} iPageX the X coordinate of the mousedown or drag event
   * @param {int} iPageY the Y coordinate of the mousedown or drag event
   */
  alignElWithMouse: function alignElWithMouse(el, iPageX, iPageY) {
    var oCoord = this.getTargetCoord(iPageX, iPageY);
    var fly = el.dom ? el : Ext.fly(el, '_dd');

    if (!this.deltaSetXY) {
      var aCoord = [oCoord.x, oCoord.y];
      fly.setXY(aCoord);
      var newLeft = fly.getLeft(true);
      var newTop = fly.getTop(true);
      this.deltaSetXY = [newLeft - oCoord.x, newTop - oCoord.y];
    } else {
      fly.setLeftTop(oCoord.x + this.deltaSetXY[0], oCoord.y + this.deltaSetXY[1]);
    }

    this.cachePosition(oCoord.x, oCoord.y);
    this.autoScroll(oCoord.x, oCoord.y, el.offsetHeight, el.offsetWidth);
    return oCoord;
  },

  /**
   * Saves the most recent position so that we can reset the constraints and
   * tick marks on-demand.  We need to know this so that we can calculate the
   * number of pixels the element is offset from its original position.
   * @method cachePosition
   * @param iPageX the current x position (optional, this just makes it so we
   * don't have to look it up again)
   * @param iPageY the current y position (optional, this just makes it so we
   * don't have to look it up again)
   */
  cachePosition: function cachePosition(iPageX, iPageY) {
    if (iPageX) {
      this.lastPageX = iPageX;
      this.lastPageY = iPageY;
    } else {
      var aCoord = Ext.lib.Dom.getXY(this.getEl());
      this.lastPageX = aCoord[0];
      this.lastPageY = aCoord[1];
    }
  },

  /**
   * Auto-scroll the window if the dragged object has been moved beyond the
   * visible window boundary.
   * @method autoScroll
   * @param {int} x the drag element's x position
   * @param {int} y the drag element's y position
   * @param {int} h the height of the drag element
   * @param {int} w the width of the drag element
   * @private
   */
  autoScroll: function autoScroll(x, y, h, w) {
    if (this.scroll) {
      // The client height
      var clientH = Ext.lib.Dom.getViewHeight(); // The client width

      var clientW = Ext.lib.Dom.getViewWidth(); // The amt scrolled down

      var st = this.DDM.getScrollTop(); // The amt scrolled right

      var sl = this.DDM.getScrollLeft(); // Location of the bottom of the element

      var bot = h + y; // Location of the right of the element

      var right = w + x; // The distance from the cursor to the bottom of the visible area,
      // adjusted so that we don't scroll if the cursor is beyond the
      // element drag constraints

      var toBot = clientH + st - y - this.deltaY; // The distance from the cursor to the right of the visible area

      var toRight = clientW + sl - x - this.deltaX; // How close to the edge the cursor must be before we scroll
      // var thresh = (document.all) ? 100 : 40;

      var thresh = 40; // How many pixels to scroll per autoscroll op.  This helps to reduce
      // clunky scrolling. IE is more sensitive about this ... it needs this
      // value to be higher.

      var scrAmt = document.all ? 80 : 30; // Scroll down if we are near the bottom of the visible page and the
      // obj extends below the crease

      if (bot > clientH && toBot < thresh) {
        window.scrollTo(sl, st + scrAmt);
      } // Scroll up if the window is scrolled down and the top of the object
      // goes above the top border


      if (y < st && st > 0 && y - st < thresh) {
        window.scrollTo(sl, st - scrAmt);
      } // Scroll right if the obj is beyond the right border and the cursor is
      // near the border.


      if (right > clientW && toRight < thresh) {
        window.scrollTo(sl + scrAmt, st);
      } // Scroll left if the window has been scrolled to the right and the obj
      // extends past the left border


      if (x < sl && sl > 0 && x - sl < thresh) {
        window.scrollTo(sl - scrAmt, st);
      }
    }
  },

  /**
   * Finds the location the element should be placed if we want to move
   * it to where the mouse location less the click offset would place us.
   * @method getTargetCoord
   * @param {int} iPageX the X coordinate of the click
   * @param {int} iPageY the Y coordinate of the click
   * @return an object that contains the coordinates (Object.x and Object.y)
   * @private
   */
  getTargetCoord: function getTargetCoord(iPageX, iPageY) {
    var x = iPageX - this.deltaX;
    var y = iPageY - this.deltaY;

    if (this.constrainX) {
      if (x < this.minX) {
        x = this.minX;
      }

      if (x > this.maxX) {
        x = this.maxX;
      }
    }

    if (this.constrainY) {
      if (y < this.minY) {
        y = this.minY;
      }

      if (y > this.maxY) {
        y = this.maxY;
      }
    }

    x = this.getTick(x, this.xTicks);
    y = this.getTick(y, this.yTicks);
    return {
      x: x,
      y: y
    };
  },

  /**
   * Sets up config options specific to this class. Overrides
   * Ext.dd.DragDrop, but all versions of this method through the
   * inheritance chain are called
   */
  applyConfig: function applyConfig() {
    Ext.dd.DD.superclass.applyConfig.call(this);
    this.scroll = this.config.scroll !== false;
  },

  /**
   * Event that fires prior to the onMouseDown event.  Overrides
   * Ext.dd.DragDrop.
   */
  b4MouseDown: function b4MouseDown(e) {
    // this.resetConstraints();
    this.autoOffset(e.getPageX(), e.getPageY());
  },

  /**
   * Event that fires prior to the onDrag event.  Overrides
   * Ext.dd.DragDrop.
   */
  b4Drag: function b4Drag(e) {
    this.setDragElPos(e.getPageX(), e.getPageY());
  },
  toString: function toString() {
    return "DD " + this.id;
  } //////////////////////////////////////////////////////////////////////////
  // Debugging ygDragDrop events that can be overridden
  //////////////////////////////////////////////////////////////////////////

  /*
  startDrag: function(x, y) {
  },
   onDrag: function(e) {
  },
   onDragEnter: function(e, id) {
  },
   onDragOver: function(e, id) {
  },
   onDragOut: function(e, id) {
  },
   onDragDrop: function(e, id) {
  },
   endDrag: function(e) {
  }
   */

});
/**
 * @class Ext.dd.DDProxy
 * A DragDrop implementation that inserts an empty, bordered div into
 * the document that follows the cursor during drag operations.  At the time of
 * the click, the frame div is resized to the dimensions of the linked html
 * element, and moved to the exact location of the linked element.
 *
 * References to the "frame" element refer to the single proxy element that
 * was created to be dragged in place of all DDProxy elements on the
 * page.
 *
 * @extends Ext.dd.DD
 * @constructor
 * @param {String} id the id of the linked html element
 * @param {String} sGroup the group of related DragDrop objects
 * @param {object} config an object containing configurable attributes
 *                Valid properties for DDProxy in addition to those in DragDrop:
 *                   resizeFrame, centerFrame, dragElId
 */

Ext.dd.DDProxy = function (id, sGroup, config) {
  if (id) {
    this.init(id, sGroup, config);
    this.initFrame();
  }
};
/**
 * The default drag frame div id
 * @property Ext.dd.DDProxy.dragElId
 * @type String
 * @static
 */


Ext.dd.DDProxy.dragElId = "ygddfdiv";
Ext.extend(Ext.dd.DDProxy, Ext.dd.DD, {
  /**
   * By default we resize the drag frame to be the same size as the element
   * we want to drag (this is to get the frame effect).  We can turn it off
   * if we want a different behavior.
   * @property resizeFrame
   * @type boolean
   */
  resizeFrame: true,

  /**
   * By default the frame is positioned exactly where the drag element is, so
   * we use the cursor offset provided by Ext.dd.DD.  Another option that works only if
   * you do not have constraints on the obj is to have the drag frame centered
   * around the cursor.  Set centerFrame to true for this effect.
   * @property centerFrame
   * @type boolean
   */
  centerFrame: false,

  /**
   * Creates the proxy element if it does not yet exist
   * @method createFrame
   */
  createFrame: function createFrame() {
    var self = this;
    var body = document.body;

    if (!body || !body.firstChild) {
      setTimeout(function () {
        self.createFrame();
      }, 50);
      return;
    }

    var div = this.getDragEl();

    if (!div) {
      div = document.createElement("div");
      div.id = this.dragElId;
      var s = div.style;
      s.position = "absolute";
      s.visibility = "hidden";
      s.cursor = "move";
      s.border = "2px solid #aaa";
      s.zIndex = 999; // appendChild can blow up IE if invoked prior to the window load event
      // while rendering a table.  It is possible there are other scenarios
      // that would cause this to happen as well.

      body.insertBefore(div, body.firstChild);
    }
  },

  /**
   * Initialization for the drag frame element.  Must be called in the
   * constructor of all subclasses
   * @method initFrame
   */
  initFrame: function initFrame() {
    this.createFrame();
  },
  applyConfig: function applyConfig() {
    Ext.dd.DDProxy.superclass.applyConfig.call(this);
    this.resizeFrame = this.config.resizeFrame !== false;
    this.centerFrame = this.config.centerFrame;
    this.setDragElId(this.config.dragElId || Ext.dd.DDProxy.dragElId);
  },

  /**
   * Resizes the drag frame to the dimensions of the clicked object, positions
   * it over the object, and finally displays it
   * @method showFrame
   * @param {int} iPageX X click position
   * @param {int} iPageY Y click position
   * @private
   */
  showFrame: function showFrame(iPageX, iPageY) {
    var el = this.getEl();
    var dragEl = this.getDragEl();
    var s = dragEl.style;

    this._resizeProxy();

    if (this.centerFrame) {
      this.setDelta(Math.round(parseInt(s.width, 10) / 2), Math.round(parseInt(s.height, 10) / 2));
    }

    this.setDragElPos(iPageX, iPageY);
    Ext.fly(dragEl).show();
  },

  /**
   * The proxy is automatically resized to the dimensions of the linked
   * element when a drag is initiated, unless resizeFrame is set to false
   * @method _resizeProxy
   * @private
   */
  _resizeProxy: function _resizeProxy() {
    if (this.resizeFrame) {
      var el = this.getEl();
      Ext.fly(this.getDragEl()).setSize(el.offsetWidth, el.offsetHeight);
    }
  },
  // overrides Ext.dd.DragDrop
  b4MouseDown: function b4MouseDown(e) {
    var x = e.getPageX();
    var y = e.getPageY();
    this.autoOffset(x, y);
    this.setDragElPos(x, y);
  },
  // overrides Ext.dd.DragDrop
  b4StartDrag: function b4StartDrag(x, y) {
    // show the drag frame
    this.showFrame(x, y);
  },
  // overrides Ext.dd.DragDrop
  b4EndDrag: function b4EndDrag(e) {
    Ext.fly(this.getDragEl()).hide();
  },
  // overrides Ext.dd.DragDrop
  // By default we try to move the element to the last location of the frame.
  // This is so that the default behavior mirrors that of Ext.dd.DD.
  endDrag: function endDrag(e) {
    var lel = this.getEl();
    var del = this.getDragEl(); // Show the drag frame briefly so we can get its position

    del.style.visibility = "";
    this.beforeMove(); // Hide the linked element before the move to get around a Safari
    // rendering bug.

    lel.style.visibility = "hidden";
    Ext.dd.DDM.moveToEl(lel, del);
    del.style.visibility = "hidden";
    lel.style.visibility = "";
    this.afterDrag();
  },
  beforeMove: function beforeMove() {},
  afterDrag: function afterDrag() {},
  toString: function toString() {
    return "DDProxy " + this.id;
  }
});
/**
 * @class Ext.dd.DDTarget
 * A DragDrop implementation that does not move, but can be a drop
 * target.  You would get the same result by simply omitting implementation
 * for the event callbacks, but this way we reduce the processing cost of the
 * event listener and the callbacks.
 * @extends Ext.dd.DragDrop
 * @constructor
 * @param {String} id the id of the element that is a drop target
 * @param {String} sGroup the group of related DragDrop objects
 * @param {object} config an object containing configurable attributes
 *                 Valid properties for DDTarget in addition to those in
 *                 DragDrop:
 *                    none
 */

Ext.dd.DDTarget = function (id, sGroup, config) {
  if (id) {
    this.initTarget(id, sGroup, config);
  }
}; // Ext.dd.DDTarget.prototype = new Ext.dd.DragDrop();


Ext.extend(Ext.dd.DDTarget, Ext.dd.DragDrop, {
  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  getDragEl: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  isValidHandleChild: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  startDrag: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  endDrag: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onDrag: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onDragDrop: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onDragEnter: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onDragOut: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onDragOver: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onInvalidDrop: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onMouseDown: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  onMouseUp: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  setXConstraint: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  setYConstraint: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  resetConstraints: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  clearConstraints: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  clearTicks: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  setInitPosition: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  setDragElId: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  setHandleElId: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  setOuterHandleElId: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  addInvalidHandleClass: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  addInvalidHandleId: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  addInvalidHandleType: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  removeInvalidHandleClass: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  removeInvalidHandleId: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. A DDTarget does not support being dragged.
   * @method
   */
  removeInvalidHandleType: Ext.emptyFn,
  toString: function toString() {
    return "DDTarget " + this.id;
  }
});

/***/ }),
/* 781 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.DragTracker
 * @extends Ext.util.Observable
 */
Ext.dd.DragTracker = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Boolean} active
  * Defaults to <tt>false</tt>.
  */
  active: false,

  /**
   * @cfg {Number} tolerance
  * Defaults to <tt>5</tt>.
  */
  tolerance: 5,

  /**
   * @cfg {Boolean/Number} autoStart
  * Defaults to <tt>false</tt>. Specify <tt>true</tt> to defer trigger start by 1000 ms.
  * Specify a Number for the number of milliseconds to defer trigger start.
  */
  autoStart: false,
  constructor: function constructor(config) {
    Ext.apply(this, config);
    this.addEvents(
    /**
     * @event mousedown
     * @param {Object} this
     * @param {Object} e event object
     */
    'mousedown',
    /**
     * @event mouseup
     * @param {Object} this
     * @param {Object} e event object
     */
    'mouseup',
    /**
     * @event mousemove
     * @param {Object} this
     * @param {Object} e event object
     */
    'mousemove',
    /**
     * @event dragstart
     * @param {Object} this
     * @param {Object} startXY the page coordinates of the event
     */
    'dragstart',
    /**
     * @event dragend
     * @param {Object} this
     * @param {Object} e event object
     */
    'dragend',
    /**
     * @event drag
     * @param {Object} this
     * @param {Object} e event object
     */
    'drag');
    this.dragRegion = new Ext.lib.Region(0, 0, 0, 0);

    if (this.el) {
      this.initEl(this.el);
    }

    Ext.dd.DragTracker.superclass.constructor.call(this, config);
  },
  initEl: function initEl(el) {
    this.el = Ext.get(el);
    el.on('mousedown', this.onMouseDown, this, this.delegate ? {
      delegate: this.delegate
    } : undefined);
  },
  destroy: function destroy() {
    this.el.un('mousedown', this.onMouseDown, this);
  },
  onMouseDown: function onMouseDown(e, target) {
    if (this.fireEvent('mousedown', this, e) !== false && this.onBeforeStart(e) !== false) {
      this.startXY = this.lastXY = e.getXY();
      this.dragTarget = this.delegate ? target : this.el.dom;

      if (this.preventDefault !== false) {
        e.preventDefault();
      }

      var doc = Ext.getDoc();
      doc.on('mouseup', this.onMouseUp, this);
      doc.on('mousemove', this.onMouseMove, this);
      doc.on('selectstart', this.stopSelect, this);

      if (this.autoStart) {
        this.timer = this.triggerStart.defer(this.autoStart === true ? 1000 : this.autoStart, this);
      }
    }
  },
  onMouseMove: function onMouseMove(e, target) {
    // HACK: IE hack to see if button was released outside of window. */
    if (this.active && Ext.isIE && !e.browserEvent.button) {
      e.preventDefault();
      this.onMouseUp(e);
      return;
    }

    e.preventDefault();
    var xy = e.getXY(),
        s = this.startXY;
    this.lastXY = xy;

    if (!this.active) {
      if (Math.abs(s[0] - xy[0]) > this.tolerance || Math.abs(s[1] - xy[1]) > this.tolerance) {
        this.triggerStart();
      } else {
        return;
      }
    }

    this.fireEvent('mousemove', this, e);
    this.onDrag(e);
    this.fireEvent('drag', this, e);
  },
  onMouseUp: function onMouseUp(e) {
    var doc = Ext.getDoc();
    doc.un('mousemove', this.onMouseMove, this);
    doc.un('mouseup', this.onMouseUp, this);
    doc.un('selectstart', this.stopSelect, this);
    e.preventDefault();
    this.clearStart();
    var wasActive = this.active;
    this.active = false;
    delete this.elRegion;
    this.fireEvent('mouseup', this, e);

    if (wasActive) {
      this.onEnd(e);
      this.fireEvent('dragend', this, e);
    }
  },
  triggerStart: function triggerStart(isTimer) {
    this.clearStart();
    this.active = true;
    this.onStart(this.startXY);
    this.fireEvent('dragstart', this, this.startXY);
  },
  clearStart: function clearStart() {
    if (this.timer) {
      clearTimeout(this.timer);
      delete this.timer;
    }
  },
  stopSelect: function stopSelect(e) {
    e.stopEvent();
    return false;
  },
  onBeforeStart: function onBeforeStart(e) {},
  onStart: function onStart(xy) {},
  onDrag: function onDrag(e) {},
  onEnd: function onEnd(e) {},
  getDragTarget: function getDragTarget() {
    return this.dragTarget;
  },
  getDragCt: function getDragCt() {
    return this.el;
  },
  getXY: function getXY(constrain) {
    return constrain ? this.constrainModes[constrain].call(this, this.lastXY) : this.lastXY;
  },
  getOffset: function getOffset(constrain) {
    var xy = this.getXY(constrain);
    var s = this.startXY;
    return [s[0] - xy[0], s[1] - xy[1]];
  },
  constrainModes: {
    'point': function point(xy) {
      if (!this.elRegion) {
        this.elRegion = this.getDragCt().getRegion();
      }

      var dr = this.dragRegion;
      dr.left = xy[0];
      dr.top = xy[1];
      dr.right = xy[0];
      dr.bottom = xy[1];
      dr.constrainTo(this.elRegion);
      return [dr.left, dr.top];
    }
  }
});

/***/ }),
/* 782 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.ScrollManager
 * <p>Provides automatic scrolling of overflow regions in the page during drag operations.</p>
 * <p>The ScrollManager configs will be used as the defaults for any scroll container registered with it,
 * but you can also override most of the configs per scroll container by adding a 
 * <tt>ddScrollConfig</tt> object to the target element that contains these properties: {@link #hthresh},
 * {@link #vthresh}, {@link #increment} and {@link #frequency}.  Example usage:
 * <pre><code>
var el = Ext.get('scroll-ct');
el.ddScrollConfig = {
    vthresh: 50,
    hthresh: -1,
    frequency: 100,
    increment: 200
};
Ext.dd.ScrollManager.register(el);
</code></pre>
 * <b>Note: This class uses "Point Mode" and is untested in "Intersect Mode".</b>
 * @singleton
 */
Ext.dd.ScrollManager = function () {
  var ddm = Ext.dd.DragDropMgr;
  var els = {};
  var dragEl = null;
  var proc = {};

  var onStop = function onStop(e) {
    dragEl = null;
    clearProc();
  };

  var triggerRefresh = function triggerRefresh() {
    if (ddm.dragCurrent) {
      ddm.refreshCache(ddm.dragCurrent.groups);
    }
  };

  var doScroll = function doScroll() {
    if (ddm.dragCurrent) {
      var dds = Ext.dd.ScrollManager;
      var inc = proc.el.ddScrollConfig ? proc.el.ddScrollConfig.increment : dds.increment;

      if (!dds.animate) {
        if (proc.el.scroll(proc.dir, inc)) {
          triggerRefresh();
        }
      } else {
        proc.el.scroll(proc.dir, inc, true, dds.animDuration, triggerRefresh);
      }
    }
  };

  var clearProc = function clearProc() {
    if (proc.id) {
      clearInterval(proc.id);
    }

    proc.id = 0;
    proc.el = null;
    proc.dir = "";
  };

  var startProc = function startProc(el, dir) {
    clearProc();
    proc.el = el;
    proc.dir = dir;
    var freq = el.ddScrollConfig && el.ddScrollConfig.frequency ? el.ddScrollConfig.frequency : Ext.dd.ScrollManager.frequency;
    proc.id = setInterval(doScroll, freq);
  };

  var onFire = function onFire(e, isDrop) {
    if (isDrop || !ddm.dragCurrent) {
      return;
    }

    var dds = Ext.dd.ScrollManager;

    if (!dragEl || dragEl != ddm.dragCurrent) {
      dragEl = ddm.dragCurrent; // refresh regions on drag start

      dds.refreshCache();
    }

    var xy = Ext.lib.Event.getXY(e);
    var pt = new Ext.lib.Point(xy[0], xy[1]);

    for (var id in els) {
      var el = els[id],
          r = el._region;
      var c = el.ddScrollConfig ? el.ddScrollConfig : dds;

      if (r && r.contains(pt) && el.isScrollable()) {
        if (r.bottom - pt.y <= c.vthresh) {
          if (proc.el != el) {
            startProc(el, "down");
          }

          return;
        } else if (r.right - pt.x <= c.hthresh) {
          if (proc.el != el) {
            startProc(el, "left");
          }

          return;
        } else if (pt.y - r.top <= c.vthresh) {
          if (proc.el != el) {
            startProc(el, "up");
          }

          return;
        } else if (pt.x - r.left <= c.hthresh) {
          if (proc.el != el) {
            startProc(el, "right");
          }

          return;
        }
      }
    }

    clearProc();
  };

  ddm.fireEvents = ddm.fireEvents.createSequence(onFire, ddm);
  ddm.stopDrag = ddm.stopDrag.createSequence(onStop, ddm);
  return {
    /**
     * Registers new overflow element(s) to auto scroll
     * @param {Mixed/Array} el The id of or the element to be scrolled or an array of either
     */
    register: function register(el) {
      if (Ext.isArray(el)) {
        for (var i = 0, len = el.length; i < len; i++) {
          this.register(el[i]);
        }
      } else {
        el = Ext.get(el);
        els[el.id] = el;
      }
    },

    /**
     * Unregisters overflow element(s) so they are no longer scrolled
     * @param {Mixed/Array} el The id of or the element to be removed or an array of either
     */
    unregister: function unregister(el) {
      if (Ext.isArray(el)) {
        for (var i = 0, len = el.length; i < len; i++) {
          this.unregister(el[i]);
        }
      } else {
        el = Ext.get(el);
        delete els[el.id];
      }
    },

    /**
     * The number of pixels from the top or bottom edge of a container the pointer needs to be to
     * trigger scrolling (defaults to 25)
     * @type Number
     */
    vthresh: 25,

    /**
     * The number of pixels from the right or left edge of a container the pointer needs to be to
     * trigger scrolling (defaults to 25)
     * @type Number
     */
    hthresh: 25,

    /**
     * The number of pixels to scroll in each scroll increment (defaults to 50)
     * @type Number
     */
    increment: 100,

    /**
     * The frequency of scrolls in milliseconds (defaults to 500)
     * @type Number
     */
    frequency: 500,

    /**
     * True to animate the scroll (defaults to true)
     * @type Boolean
     */
    animate: true,

    /**
     * The animation duration in seconds - 
     * MUST BE less than Ext.dd.ScrollManager.frequency! (defaults to .4)
     * @type Number
     */
    animDuration: .4,

    /**
     * Manually trigger a cache refresh.
     */
    refreshCache: function refreshCache() {
      for (var id in els) {
        if (typeof els[id] == 'object') {
          // for people extending the object prototype
          els[id]._region = els[id].getRegion();
        }
      }
    }
  };
}();

/***/ }),
/* 783 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.Registry
 * Provides easy access to all drag drop components that are registered on a page.  Items can be retrieved either
 * directly by DOM node id, or by passing in the drag drop event that occurred and looking up the event target.
 * @singleton
 */
Ext.dd.Registry = function () {
  var elements = {};
  var handles = {};
  var autoIdSeed = 0;

  var getId = function getId(el, autogen) {
    if (typeof el == "string") {
      return el;
    }

    var id = el.id;

    if (!id && autogen !== false) {
      id = "extdd-" + ++autoIdSeed;
      el.id = id;
    }

    return id;
  };

  return {
    /**
     * Resgister a drag drop element
     * @param {String/HTMLElement) element The id or DOM node to register
     * @param {Object} data (optional) An custom data object that will be passed between the elements that are involved
     * in drag drop operations.  You can populate this object with any arbitrary properties that your own code
     * knows how to interpret, plus there are some specific properties known to the Registry that should be
     * populated in the data object (if applicable):
     * <pre>
    Value      Description<br />
    ---------  ------------------------------------------<br />
    handles    Array of DOM nodes that trigger dragging<br />
           for the element being registered<br />
    isHandle   True if the element passed in triggers<br />
           dragging itself, else false
    </pre>
     */
    register: function register(el, data) {
      data = data || {};

      if (typeof el == "string") {
        el = document.getElementById(el);
      }

      data.ddel = el;
      elements[getId(el)] = data;

      if (data.isHandle !== false) {
        handles[data.ddel.id] = data;
      }

      if (data.handles) {
        var hs = data.handles;

        for (var i = 0, len = hs.length; i < len; i++) {
          handles[getId(hs[i])] = data;
        }
      }
    },

    /**
     * Unregister a drag drop element
     * @param {String/HTMLElement) element The id or DOM node to unregister
     */
    unregister: function unregister(el) {
      var id = getId(el, false);
      var data = elements[id];

      if (data) {
        delete elements[id];

        if (data.handles) {
          var hs = data.handles;

          for (var i = 0, len = hs.length; i < len; i++) {
            delete handles[getId(hs[i], false)];
          }
        }
      }
    },

    /**
     * Returns the handle registered for a DOM Node by id
     * @param {String/HTMLElement} id The DOM node or id to look up
     * @return {Object} handle The custom handle data
     */
    getHandle: function getHandle(id) {
      if (typeof id != "string") {
        // must be element?
        id = id.id;
      }

      return handles[id];
    },

    /**
     * Returns the handle that is registered for the DOM node that is the target of the event
     * @param {Event} e The event
     * @return {Object} handle The custom handle data
     */
    getHandleFromEvent: function getHandleFromEvent(e) {
      var t = Ext.lib.Event.getTarget(e);
      return t ? handles[t.id] : null;
    },

    /**
     * Returns a custom data object that is registered for a DOM node by id
     * @param {String/HTMLElement} id The DOM node or id to look up
     * @return {Object} data The custom data
     */
    getTarget: function getTarget(id) {
      if (typeof id != "string") {
        // must be element?
        id = id.id;
      }

      return elements[id];
    },

    /**
     * Returns a custom data object that is registered for the DOM node that is the target of the event
     * @param {Event} e The event
     * @return {Object} data The custom data
     */
    getTargetFromEvent: function getTargetFromEvent(e) {
      var t = Ext.lib.Event.getTarget(e);
      return t ? elements[t.id] || handles[t.id] : null;
    }
  };
}();

/***/ }),
/* 784 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.StatusProxy
 * A specialized drag proxy that supports a drop status icon, {@link Ext.Layer} styles and auto-repair.  This is the
 * default drag proxy used by all Ext.dd components.
 * @constructor
 * @param {Object} config
 */
Ext.dd.StatusProxy = function (config) {
  Ext.apply(this, config);
  this.id = this.id || Ext.id();
  this.el = new Ext.Layer({
    dh: {
      id: this.id,
      tag: "div",
      cls: "x-dd-drag-proxy " + this.dropNotAllowed,
      children: [{
        tag: "div",
        cls: "x-dd-drop-icon"
      }, {
        tag: "div",
        cls: "x-dd-drag-ghost"
      }]
    },
    shadow: !config || config.shadow !== false
  });
  this.ghost = Ext.get(this.el.dom.childNodes[1]);
  this.dropStatus = this.dropNotAllowed;
};

Ext.dd.StatusProxy.prototype = {
  /**
   * @cfg {String} dropAllowed
   * The CSS class to apply to the status element when drop is allowed (defaults to "x-dd-drop-ok").
   */
  dropAllowed: "x-dd-drop-ok",

  /**
   * @cfg {String} dropNotAllowed
   * The CSS class to apply to the status element when drop is not allowed (defaults to "x-dd-drop-nodrop").
   */
  dropNotAllowed: "x-dd-drop-nodrop",

  /**
   * Updates the proxy's visual element to indicate the status of whether or not drop is allowed
   * over the current target element.
   * @param {String} cssClass The css class for the new drop status indicator image
   */
  setStatus: function setStatus(cssClass) {
    cssClass = cssClass || this.dropNotAllowed;

    if (this.dropStatus != cssClass) {
      this.el.replaceClass(this.dropStatus, cssClass);
      this.dropStatus = cssClass;
    }
  },

  /**
   * Resets the status indicator to the default dropNotAllowed value
   * @param {Boolean} clearGhost True to also remove all content from the ghost, false to preserve it
   */
  reset: function reset(clearGhost) {
    this.el.dom.className = "x-dd-drag-proxy " + this.dropNotAllowed;
    this.dropStatus = this.dropNotAllowed;

    if (clearGhost) {
      this.ghost.update("");
    }
  },

  /**
   * Updates the contents of the ghost element
   * @param {String/HTMLElement} html The html that will replace the current innerHTML of the ghost element, or a
   * DOM node to append as the child of the ghost element (in which case the innerHTML will be cleared first).
   */
  update: function update(html) {
    if (typeof html == "string") {
      this.ghost.update(html);
    } else {
      this.ghost.update("");
      html.style.margin = "0";
      this.ghost.dom.appendChild(html);
    }

    var el = this.ghost.dom.firstChild;

    if (el) {
      Ext.fly(el).setStyle('float', 'none');
    }
  },

  /**
   * Returns the underlying proxy {@link Ext.Layer}
   * @return {Ext.Layer} el
  */
  getEl: function getEl() {
    return this.el;
  },

  /**
   * Returns the ghost element
   * @return {Ext.Element} el
   */
  getGhost: function getGhost() {
    return this.ghost;
  },

  /**
   * Hides the proxy
   * @param {Boolean} clear True to reset the status and clear the ghost contents, false to preserve them
   */
  hide: function hide(clear) {
    this.el.hide();

    if (clear) {
      this.reset(true);
    }
  },

  /**
   * Stops the repair animation if it's currently running
   */
  stop: function stop() {
    if (this.anim && this.anim.isAnimated && this.anim.isAnimated()) {
      this.anim.stop();
    }
  },

  /**
   * Displays this proxy
   */
  show: function show() {
    this.el.show();
  },

  /**
   * Force the Layer to sync its shadow and shim positions to the element
   */
  sync: function sync() {
    this.el.sync();
  },

  /**
   * Causes the proxy to return to its position of origin via an animation.  Should be called after an
   * invalid drop operation by the item being dragged.
   * @param {Array} xy The XY position of the element ([x, y])
   * @param {Function} callback The function to call after the repair is complete.
   * @param {Object} scope The scope (<code>this</code> reference) in which the callback function is executed. Defaults to the browser window.
   */
  repair: function repair(xy, callback, scope) {
    this.callback = callback;
    this.scope = scope;

    if (xy && this.animRepair !== false) {
      this.el.addClass("x-dd-drag-repair");
      this.el.hideUnders(true);
      this.anim = this.el.shift({
        duration: this.repairDuration || .5,
        easing: 'easeOut',
        xy: xy,
        stopFx: true,
        callback: this.afterRepair,
        scope: this
      });
    } else {
      this.afterRepair();
    }
  },
  // private
  afterRepair: function afterRepair() {
    this.hide(true);

    if (typeof this.callback == "function") {
      this.callback.call(this.scope || this);
    }

    this.callback = null;
    this.scope = null;
  },
  destroy: function destroy() {
    Ext.destroy(this.ghost, this.el);
  }
};

/***/ }),
/* 785 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.DragSource
 * @extends Ext.dd.DDProxy
 * A simple class that provides the basic implementation needed to make any element draggable.
 * @constructor
 * @param {Mixed} el The container element
 * @param {Object} config
 */
Ext.dd.DragSource = function (el, config) {
  this.el = Ext.get(el);

  if (!this.dragData) {
    this.dragData = {};
  }

  Ext.apply(this, config);

  if (!this.proxy) {
    this.proxy = new Ext.dd.StatusProxy();
  }

  Ext.dd.DragSource.superclass.constructor.call(this, this.el.dom, this.ddGroup || this.group, {
    dragElId: this.proxy.id,
    resizeFrame: false,
    isTarget: false,
    scroll: this.scroll === true
  });
  this.dragging = false;
};

Ext.extend(Ext.dd.DragSource, Ext.dd.DDProxy, {
  /**
   * @cfg {String} ddGroup
   * A named drag drop group to which this object belongs.  If a group is specified, then this object will only
   * interact with other drag drop objects in the same group (defaults to undefined).
   */

  /**
   * @cfg {String} dropAllowed
   * The CSS class returned to the drag source when drop is allowed (defaults to "x-dd-drop-ok").
   */
  dropAllowed: "x-dd-drop-ok",

  /**
   * @cfg {String} dropNotAllowed
   * The CSS class returned to the drag source when drop is not allowed (defaults to "x-dd-drop-nodrop").
   */
  dropNotAllowed: "x-dd-drop-nodrop",

  /**
   * Returns the data object associated with this drag source
   * @return {Object} data An object containing arbitrary data
   */
  getDragData: function getDragData(e) {
    return this.dragData;
  },
  // private
  onDragEnter: function onDragEnter(e, id) {
    var target = Ext.dd.DragDropMgr.getDDById(id);
    this.cachedTarget = target;

    if (this.beforeDragEnter(target, e, id) !== false) {
      if (target.isNotifyTarget) {
        var status = target.notifyEnter(this, e, this.dragData);
        this.proxy.setStatus(status);
      } else {
        this.proxy.setStatus(this.dropAllowed);
      }

      if (this.afterDragEnter) {
        /**
         * An empty function by default, but provided so that you can perform a custom action
         * when the dragged item enters the drop target by providing an implementation.
         * @param {Ext.dd.DragDrop} target The drop target
         * @param {Event} e The event object
         * @param {String} id The id of the dragged element
         * @method afterDragEnter
         */
        this.afterDragEnter(target, e, id);
      }
    }
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action
   * before the dragged item enters the drop target and optionally cancel the onDragEnter.
   * @param {Ext.dd.DragDrop} target The drop target
   * @param {Event} e The event object
   * @param {String} id The id of the dragged element
   * @return {Boolean} isValid True if the drag event is valid, else false to cancel
   */
  beforeDragEnter: function beforeDragEnter(target, e, id) {
    return true;
  },
  // private
  alignElWithMouse: function alignElWithMouse() {
    Ext.dd.DragSource.superclass.alignElWithMouse.apply(this, arguments);
    this.proxy.sync();
  },
  // private
  onDragOver: function onDragOver(e, id) {
    var target = this.cachedTarget || Ext.dd.DragDropMgr.getDDById(id);

    if (this.beforeDragOver(target, e, id) !== false) {
      if (target.isNotifyTarget) {
        var status = target.notifyOver(this, e, this.dragData);
        this.proxy.setStatus(status);
      }

      if (this.afterDragOver) {
        /**
         * An empty function by default, but provided so that you can perform a custom action
         * while the dragged item is over the drop target by providing an implementation.
         * @param {Ext.dd.DragDrop} target The drop target
         * @param {Event} e The event object
         * @param {String} id The id of the dragged element
         * @method afterDragOver
         */
        this.afterDragOver(target, e, id);
      }
    }
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action
   * while the dragged item is over the drop target and optionally cancel the onDragOver.
   * @param {Ext.dd.DragDrop} target The drop target
   * @param {Event} e The event object
   * @param {String} id The id of the dragged element
   * @return {Boolean} isValid True if the drag event is valid, else false to cancel
   */
  beforeDragOver: function beforeDragOver(target, e, id) {
    return true;
  },
  // private
  onDragOut: function onDragOut(e, id) {
    var target = this.cachedTarget || Ext.dd.DragDropMgr.getDDById(id);

    if (this.beforeDragOut(target, e, id) !== false) {
      if (target.isNotifyTarget) {
        target.notifyOut(this, e, this.dragData);
      }

      this.proxy.reset();

      if (this.afterDragOut) {
        /**
         * An empty function by default, but provided so that you can perform a custom action
         * after the dragged item is dragged out of the target without dropping.
         * @param {Ext.dd.DragDrop} target The drop target
         * @param {Event} e The event object
         * @param {String} id The id of the dragged element
         * @method afterDragOut
         */
        this.afterDragOut(target, e, id);
      }
    }

    this.cachedTarget = null;
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action before the dragged
   * item is dragged out of the target without dropping, and optionally cancel the onDragOut.
   * @param {Ext.dd.DragDrop} target The drop target
   * @param {Event} e The event object
   * @param {String} id The id of the dragged element
   * @return {Boolean} isValid True if the drag event is valid, else false to cancel
   */
  beforeDragOut: function beforeDragOut(target, e, id) {
    return true;
  },
  // private
  onDragDrop: function onDragDrop(e, id) {
    var target = this.cachedTarget || Ext.dd.DragDropMgr.getDDById(id);

    if (this.beforeDragDrop(target, e, id) !== false) {
      if (target.isNotifyTarget) {
        if (target.notifyDrop(this, e, this.dragData)) {
          // valid drop?
          this.onValidDrop(target, e, id);
        } else {
          this.onInvalidDrop(target, e, id);
        }
      } else {
        this.onValidDrop(target, e, id);
      }

      if (this.afterDragDrop) {
        /**
         * An empty function by default, but provided so that you can perform a custom action
         * after a valid drag drop has occurred by providing an implementation.
         * @param {Ext.dd.DragDrop} target The drop target
         * @param {Event} e The event object
         * @param {String} id The id of the dropped element
         * @method afterDragDrop
         */
        this.afterDragDrop(target, e, id);
      }
    }

    delete this.cachedTarget;
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action before the dragged
   * item is dropped onto the target and optionally cancel the onDragDrop.
   * @param {Ext.dd.DragDrop} target The drop target
   * @param {Event} e The event object
   * @param {String} id The id of the dragged element
   * @return {Boolean} isValid True if the drag drop event is valid, else false to cancel
   */
  beforeDragDrop: function beforeDragDrop(target, e, id) {
    return true;
  },
  // private
  onValidDrop: function onValidDrop(target, e, id) {
    this.hideProxy();

    if (this.afterValidDrop) {
      /**
       * An empty function by default, but provided so that you can perform a custom action
       * after a valid drop has occurred by providing an implementation.
       * @param {Object} target The target DD 
       * @param {Event} e The event object
       * @param {String} id The id of the dropped element
       * @method afterInvalidDrop
       */
      this.afterValidDrop(target, e, id);
    }
  },
  // private
  getRepairXY: function getRepairXY(e, data) {
    return this.el.getXY();
  },
  // private
  onInvalidDrop: function onInvalidDrop(target, e, id) {
    this.beforeInvalidDrop(target, e, id);

    if (this.cachedTarget) {
      if (this.cachedTarget.isNotifyTarget) {
        this.cachedTarget.notifyOut(this, e, this.dragData);
      }

      this.cacheTarget = null;
    }

    this.proxy.repair(this.getRepairXY(e, this.dragData), this.afterRepair, this);

    if (this.afterInvalidDrop) {
      /**
       * An empty function by default, but provided so that you can perform a custom action
       * after an invalid drop has occurred by providing an implementation.
       * @param {Event} e The event object
       * @param {String} id The id of the dropped element
       * @method afterInvalidDrop
       */
      this.afterInvalidDrop(e, id);
    }
  },
  // private
  afterRepair: function afterRepair() {
    if (Ext.enableFx) {
      this.el.highlight(this.hlColor || "c3daf9");
    }

    this.dragging = false;
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action after an invalid
   * drop has occurred.
   * @param {Ext.dd.DragDrop} target The drop target
   * @param {Event} e The event object
   * @param {String} id The id of the dragged element
   * @return {Boolean} isValid True if the invalid drop should proceed, else false to cancel
   */
  beforeInvalidDrop: function beforeInvalidDrop(target, e, id) {
    return true;
  },
  // private
  handleMouseDown: function handleMouseDown(e) {
    if (this.dragging) {
      return;
    }

    var data = this.getDragData(e);

    if (data && this.onBeforeDrag(data, e) !== false) {
      this.dragData = data;
      this.proxy.stop();
      Ext.dd.DragSource.superclass.handleMouseDown.apply(this, arguments);
    }
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action before the initial
   * drag event begins and optionally cancel it.
   * @param {Object} data An object containing arbitrary data to be shared with drop targets
   * @param {Event} e The event object
   * @return {Boolean} isValid True if the drag event is valid, else false to cancel
   */
  onBeforeDrag: function onBeforeDrag(data, e) {
    return true;
  },

  /**
   * An empty function by default, but provided so that you can perform a custom action once the initial
   * drag event has begun.  The drag cannot be canceled from this function.
   * @param {Number} x The x position of the click on the dragged object
   * @param {Number} y The y position of the click on the dragged object
   */
  onStartDrag: Ext.emptyFn,
  // private override
  startDrag: function startDrag(x, y) {
    this.proxy.reset();
    this.dragging = true;
    this.proxy.update("");
    this.onInitDrag(x, y);
    this.proxy.show();
  },
  // private
  onInitDrag: function onInitDrag(x, y) {
    var clone = this.el.dom.cloneNode(true);
    clone.id = Ext.id(); // prevent duplicate ids

    this.proxy.update(clone);
    this.onStartDrag(x, y);
    return true;
  },

  /**
   * Returns the drag source's underlying {@link Ext.dd.StatusProxy}
   * @return {Ext.dd.StatusProxy} proxy The StatusProxy
   */
  getProxy: function getProxy() {
    return this.proxy;
  },

  /**
   * Hides the drag source's {@link Ext.dd.StatusProxy}
   */
  hideProxy: function hideProxy() {
    this.proxy.hide();
    this.proxy.reset(true);
    this.dragging = false;
  },
  // private
  triggerCacheRefresh: function triggerCacheRefresh() {
    Ext.dd.DDM.refreshCache(this.groups);
  },
  // private - override to prevent hiding
  b4EndDrag: function b4EndDrag(e) {},
  // private - override to prevent moving
  endDrag: function endDrag(e) {
    this.onEndDrag(this.dragData, e);
  },
  // private
  onEndDrag: function onEndDrag(data, e) {},
  // private - pin to cursor
  autoOffset: function autoOffset(x, y) {
    this.setDelta(-12, -20);
  },
  destroy: function destroy() {
    Ext.dd.DragSource.superclass.destroy.call(this);
    Ext.destroy(this.proxy);
  }
});

/***/ }),
/* 786 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.DropTarget
 * @extends Ext.dd.DDTarget
 * A simple class that provides the basic implementation needed to make any element a drop target that can have
 * draggable items dropped onto it.  The drop has no effect until an implementation of notifyDrop is provided.
 * @constructor
 * @param {Mixed} el The container element
 * @param {Object} config
 */
Ext.dd.DropTarget = function (el, config) {
  this.el = Ext.get(el);
  Ext.apply(this, config);

  if (this.containerScroll) {
    Ext.dd.ScrollManager.register(this.el);
  }

  Ext.dd.DropTarget.superclass.constructor.call(this, this.el.dom, this.ddGroup || this.group, {
    isTarget: true
  });
};

Ext.extend(Ext.dd.DropTarget, Ext.dd.DDTarget, {
  /**
   * @cfg {String} ddGroup
   * A named drag drop group to which this object belongs.  If a group is specified, then this object will only
   * interact with other drag drop objects in the same group (defaults to undefined).
   */

  /**
   * @cfg {String} overClass
   * The CSS class applied to the drop target element while the drag source is over it (defaults to "").
   */

  /**
   * @cfg {String} dropAllowed
   * The CSS class returned to the drag source when drop is allowed (defaults to "x-dd-drop-ok").
   */
  dropAllowed: "x-dd-drop-ok",

  /**
   * @cfg {String} dropNotAllowed
   * The CSS class returned to the drag source when drop is not allowed (defaults to "x-dd-drop-nodrop").
   */
  dropNotAllowed: "x-dd-drop-nodrop",
  // private
  isTarget: true,
  // private
  isNotifyTarget: true,

  /**
   * The function a {@link Ext.dd.DragSource} calls once to notify this drop target that the source is now over the
   * target.  This default implementation adds the CSS class specified by overClass (if any) to the drop element
   * and returns the dropAllowed config value.  This method should be overridden if drop validation is required.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop target
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  notifyEnter: function notifyEnter(dd, e, data) {
    if (this.overClass) {
      this.el.addClass(this.overClass);
    }

    return this.dropAllowed;
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls continuously while it is being dragged over the target.
   * This method will be called on every mouse movement while the drag source is over the drop target.
   * This default implementation simply returns the dropAllowed config value.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop target
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  notifyOver: function notifyOver(dd, e, data) {
    return this.dropAllowed;
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls once to notify this drop target that the source has been dragged
   * out of the target without dropping.  This default implementation simply removes the CSS class specified by
   * overClass (if any) from the drop element.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop target
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   */
  notifyOut: function notifyOut(dd, e, data) {
    if (this.overClass) {
      this.el.removeClass(this.overClass);
    }
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls once to notify this drop target that the dragged item has
   * been dropped on it.  This method has no default implementation and returns false, so you must provide an
   * implementation that does something to process the drop event and returns true so that the drag source's
   * repair action does not run.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop target
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {Boolean} True if the drop was valid, else false
   */
  notifyDrop: function notifyDrop(dd, e, data) {
    return false;
  }
});

/***/ }),
/* 787 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.DragZone
 * @extends Ext.dd.DragSource
 * <p>This class provides a container DD instance that allows dragging of multiple child source nodes.</p>
 * <p>This class does not move the drag target nodes, but a proxy element which may contain
 * any DOM structure you wish. The DOM element to show in the proxy is provided by either a
 * provided implementation of {@link #getDragData}, or by registered draggables registered with {@link Ext.dd.Registry}</p>
 * <p>If you wish to provide draggability for an arbitrary number of DOM nodes, each of which represent some
 * application object (For example nodes in a {@link Ext.DataView DataView}) then use of this class
 * is the most efficient way to "activate" those nodes.</p>
 * <p>By default, this class requires that draggable child nodes are registered with {@link Ext.dd.Registry}.
 * However a simpler way to allow a DragZone to manage any number of draggable elements is to configure
 * the DragZone with  an implementation of the {@link #getDragData} method which interrogates the passed
 * mouse event to see if it has taken place within an element, or class of elements. This is easily done
 * by using the event's {@link Ext.EventObject#getTarget getTarget} method to identify a node based on a
 * {@link Ext.DomQuery} selector. For example, to make the nodes of a DataView draggable, use the following
 * technique. Knowledge of the use of the DataView is required:</p><pre><code>
myDataView.on('render', function(v) {
    myDataView.dragZone = new Ext.dd.DragZone(v.getEl(), {

//      On receipt of a mousedown event, see if it is within a DataView node.
//      Return a drag data object if so.
        getDragData: function(e) {

//          Use the DataView's own itemSelector (a mandatory property) to
//          test if the mousedown is within one of the DataView's nodes.
            var sourceEl = e.getTarget(v.itemSelector, 10);

//          If the mousedown is within a DataView node, clone the node to produce
//          a ddel element for use by the drag proxy. Also add application data
//          to the returned data object.
            if (sourceEl) {
                d = sourceEl.cloneNode(true);
                d.id = Ext.id();
                return {
                    ddel: d,
                    sourceEl: sourceEl,
                    repairXY: Ext.fly(sourceEl).getXY(),
                    sourceStore: v.store,
                    draggedRecord: v.{@link Ext.DataView#getRecord getRecord}(sourceEl)
                }
            }
        },

//      Provide coordinates for the proxy to slide back to on failed drag.
//      This is the original XY coordinates of the draggable element captured
//      in the getDragData method.
        getRepairXY: function() {
            return this.dragData.repairXY;
        }
    });
});</code></pre>
 * See the {@link Ext.dd.DropZone DropZone} documentation for details about building a DropZone which
 * cooperates with this DragZone.
 * @constructor
 * @param {Mixed} el The container element
 * @param {Object} config
 */
Ext.dd.DragZone = function (el, config) {
  Ext.dd.DragZone.superclass.constructor.call(this, el, config);

  if (this.containerScroll) {
    Ext.dd.ScrollManager.register(this.el);
  }
};

Ext.extend(Ext.dd.DragZone, Ext.dd.DragSource, {
  /**
   * This property contains the data representing the dragged object. This data is set up by the implementation
   * of the {@link #getDragData} method. It must contain a <tt>ddel</tt> property, but can contain
   * any other data according to the application's needs.
   * @type Object
   * @property dragData
   */

  /**
   * @cfg {Boolean} containerScroll True to register this container with the Scrollmanager
   * for auto scrolling during drag operations.
   */

  /**
   * @cfg {String} hlColor The color to use when visually highlighting the drag source in the afterRepair
   * method after a failed drop (defaults to "c3daf9" - light blue)
   */

  /**
   * Called when a mousedown occurs in this container. Looks in {@link Ext.dd.Registry}
   * for a valid target to drag based on the mouse down. Override this method
   * to provide your own lookup logic (e.g. finding a child by class name). Make sure your returned
   * object has a "ddel" attribute (with an HTML Element) for other functions to work.
   * @param {EventObject} e The mouse down event
   * @return {Object} The dragData
   */
  getDragData: function getDragData(e) {
    return Ext.dd.Registry.getHandleFromEvent(e);
  },

  /**
   * Called once drag threshold has been reached to initialize the proxy element. By default, it clones the
   * this.dragData.ddel
   * @param {Number} x The x position of the click on the dragged object
   * @param {Number} y The y position of the click on the dragged object
   * @return {Boolean} true to continue the drag, false to cancel
   */
  onInitDrag: function onInitDrag(x, y) {
    this.proxy.update(this.dragData.ddel.cloneNode(true));
    this.onStartDrag(x, y);
    return true;
  },

  /**
   * Called after a repair of an invalid drop. By default, highlights this.dragData.ddel 
   */
  afterRepair: function afterRepair() {
    if (Ext.enableFx) {
      Ext.Element.fly(this.dragData.ddel).highlight(this.hlColor || "c3daf9");
    }

    this.dragging = false;
  },

  /**
   * Called before a repair of an invalid drop to get the XY to animate to. By default returns
   * the XY of this.dragData.ddel
   * @param {EventObject} e The mouse up event
   * @return {Array} The xy location (e.g. [100, 200])
   */
  getRepairXY: function getRepairXY(e) {
    return Ext.Element.fly(this.dragData.ddel).getXY();
  }
});

/***/ }),
/* 788 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.DropZone
 * @extends Ext.dd.DropTarget
 * <p>This class provides a container DD instance that allows dropping on multiple child target nodes.</p>
 * <p>By default, this class requires that child nodes accepting drop are registered with {@link Ext.dd.Registry}.
 * However a simpler way to allow a DropZone to manage any number of target elements is to configure the
 * DropZone with an implementation of {@link #getTargetFromEvent} which interrogates the passed
 * mouse event to see if it has taken place within an element, or class of elements. This is easily done
 * by using the event's {@link Ext.EventObject#getTarget getTarget} method to identify a node based on a
 * {@link Ext.DomQuery} selector.</p>
 * <p>Once the DropZone has detected through calling getTargetFromEvent, that the mouse is over
 * a drop target, that target is passed as the first parameter to {@link #onNodeEnter}, {@link #onNodeOver},
 * {@link #onNodeOut}, {@link #onNodeDrop}. You may configure the instance of DropZone with implementations
 * of these methods to provide application-specific behaviour for these events to update both
 * application state, and UI state.</p>
 * <p>For example to make a GridPanel a cooperating target with the example illustrated in
 * {@link Ext.dd.DragZone DragZone}, the following technique might be used:</p><pre><code>
myGridPanel.on('render', function() {
    myGridPanel.dropZone = new Ext.dd.DropZone(myGridPanel.getView().scroller, {

//      If the mouse is over a grid row, return that node. This is
//      provided as the "target" parameter in all "onNodeXXXX" node event handling functions
        getTargetFromEvent: function(e) {
            return e.getTarget(myGridPanel.getView().rowSelector);
        },

//      On entry into a target node, highlight that node.
        onNodeEnter : function(target, dd, e, data){ 
            Ext.fly(target).addClass('my-row-highlight-class');
        },

//      On exit from a target node, unhighlight that node.
        onNodeOut : function(target, dd, e, data){ 
            Ext.fly(target).removeClass('my-row-highlight-class');
        },

//      While over a target node, return the default drop allowed class which
//      places a "tick" icon into the drag proxy.
        onNodeOver : function(target, dd, e, data){ 
            return Ext.dd.DropZone.prototype.dropAllowed;
        },

//      On node drop we can interrogate the target to find the underlying
//      application object that is the real target of the dragged data.
//      In this case, it is a Record in the GridPanel's Store.
//      We can use the data set up by the DragZone's getDragData method to read
//      any data we decided to attach in the DragZone's getDragData method.
        onNodeDrop : function(target, dd, e, data){
            var rowIndex = myGridPanel.getView().findRowIndex(target);
            var r = myGridPanel.getStore().getAt(rowIndex);
            Ext.Msg.alert('Drop gesture', 'Dropped Record id ' + data.draggedRecord.id +
                ' on Record id ' + r.id);
            return true;
        }
    });
}
</code></pre>
 * See the {@link Ext.dd.DragZone DragZone} documentation for details about building a DragZone which
 * cooperates with this DropZone.
 * @constructor
 * @param {Mixed} el The container element
 * @param {Object} config
 */
Ext.dd.DropZone = function (el, config) {
  Ext.dd.DropZone.superclass.constructor.call(this, el, config);
};

Ext.extend(Ext.dd.DropZone, Ext.dd.DropTarget, {
  /**
   * Returns a custom data object associated with the DOM node that is the target of the event.  By default
   * this looks up the event target in the {@link Ext.dd.Registry}, although you can override this method to
   * provide your own custom lookup.
   * @param {Event} e The event
   * @return {Object} data The custom data
   */
  getTargetFromEvent: function getTargetFromEvent(e) {
    return Ext.dd.Registry.getTargetFromEvent(e);
  },

  /**
   * Called when the DropZone determines that a {@link Ext.dd.DragSource} has entered a drop node
   * that has either been registered or detected by a configured implementation of {@link #getTargetFromEvent}.
   * This method has no default implementation and should be overridden to provide
   * node-specific processing if necessary.
   * @param {Object} nodeData The custom data associated with the drop node (this is the same value returned from 
   * {@link #getTargetFromEvent} for this node)
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   */
  onNodeEnter: function onNodeEnter(n, dd, e, data) {},

  /**
   * Called while the DropZone determines that a {@link Ext.dd.DragSource} is over a drop node
   * that has either been registered or detected by a configured implementation of {@link #getTargetFromEvent}.
   * The default implementation returns this.dropNotAllowed, so it should be
   * overridden to provide the proper feedback.
   * @param {Object} nodeData The custom data associated with the drop node (this is the same value returned from
   * {@link #getTargetFromEvent} for this node)
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  onNodeOver: function onNodeOver(n, dd, e, data) {
    return this.dropAllowed;
  },

  /**
   * Called when the DropZone determines that a {@link Ext.dd.DragSource} has been dragged out of
   * the drop node without dropping.  This method has no default implementation and should be overridden to provide
   * node-specific processing if necessary.
   * @param {Object} nodeData The custom data associated with the drop node (this is the same value returned from
   * {@link #getTargetFromEvent} for this node)
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   */
  onNodeOut: function onNodeOut(n, dd, e, data) {},

  /**
   * Called when the DropZone determines that a {@link Ext.dd.DragSource} has been dropped onto
   * the drop node.  The default implementation returns false, so it should be overridden to provide the
   * appropriate processing of the drop event and return true so that the drag source's repair action does not run.
   * @param {Object} nodeData The custom data associated with the drop node (this is the same value returned from
   * {@link #getTargetFromEvent} for this node)
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {Boolean} True if the drop was valid, else false
   */
  onNodeDrop: function onNodeDrop(n, dd, e, data) {
    return false;
  },

  /**
   * Called while the DropZone determines that a {@link Ext.dd.DragSource} is being dragged over it,
   * but not over any of its registered drop nodes.  The default implementation returns this.dropNotAllowed, so
   * it should be overridden to provide the proper feedback if necessary.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  onContainerOver: function onContainerOver(dd, e, data) {
    return this.dropNotAllowed;
  },

  /**
   * Called when the DropZone determines that a {@link Ext.dd.DragSource} has been dropped on it,
   * but not on any of its registered drop nodes.  The default implementation returns false, so it should be
   * overridden to provide the appropriate processing of the drop event if you need the drop zone itself to
   * be able to accept drops.  It should return true when valid so that the drag source's repair action does not run.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {Boolean} True if the drop was valid, else false
   */
  onContainerDrop: function onContainerDrop(dd, e, data) {
    return false;
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls once to notify this drop zone that the source is now over
   * the zone.  The default implementation returns this.dropNotAllowed and expects that only registered drop
   * nodes can process drag drop operations, so if you need the drop zone itself to be able to process drops
   * you should override this method and provide a custom implementation.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  notifyEnter: function notifyEnter(dd, e, data) {
    return this.dropNotAllowed;
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls continuously while it is being dragged over the drop zone.
   * This method will be called on every mouse movement while the drag source is over the drop zone.
   * It will call {@link #onNodeOver} while the drag source is over a registered node, and will also automatically
   * delegate to the appropriate node-specific methods as necessary when the drag source enters and exits
   * registered nodes ({@link #onNodeEnter}, {@link #onNodeOut}). If the drag source is not currently over a
   * registered node, it will call {@link #onContainerOver}.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  notifyOver: function notifyOver(dd, e, data) {
    var n = this.getTargetFromEvent(e);

    if (!n) {
      // not over valid drop target
      if (this.lastOverNode) {
        this.onNodeOut(this.lastOverNode, dd, e, data);
        this.lastOverNode = null;
      }

      return this.onContainerOver(dd, e, data);
    }

    if (this.lastOverNode != n) {
      if (this.lastOverNode) {
        this.onNodeOut(this.lastOverNode, dd, e, data);
      }

      this.onNodeEnter(n, dd, e, data);
      this.lastOverNode = n;
    }

    return this.onNodeOver(n, dd, e, data);
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls once to notify this drop zone that the source has been dragged
   * out of the zone without dropping.  If the drag source is currently over a registered node, the notification
   * will be delegated to {@link #onNodeOut} for node-specific handling, otherwise it will be ignored.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop target
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag zone
   */
  notifyOut: function notifyOut(dd, e, data) {
    if (this.lastOverNode) {
      this.onNodeOut(this.lastOverNode, dd, e, data);
      this.lastOverNode = null;
    }
  },

  /**
   * The function a {@link Ext.dd.DragSource} calls once to notify this drop zone that the dragged item has
   * been dropped on it.  The drag zone will look up the target node based on the event passed in, and if there
   * is a node registered for that event, it will delegate to {@link #onNodeDrop} for node-specific handling,
   * otherwise it will call {@link #onContainerDrop}.
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {Boolean} True if the drop was valid, else false
   */
  notifyDrop: function notifyDrop(dd, e, data) {
    if (this.lastOverNode) {
      this.onNodeOut(this.lastOverNode, dd, e, data);
      this.lastOverNode = null;
    }

    var n = this.getTargetFromEvent(e);
    return n ? this.onNodeDrop(n, dd, e, data) : this.onContainerDrop(dd, e, data);
  },
  // private
  triggerCacheRefresh: function triggerCacheRefresh() {
    Ext.dd.DDM.refreshCache(this.groups);
  }
});

/***/ }),
/* 789 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Element
 */
Ext.Element.addMethods({
  /**
   * Initializes a {@link Ext.dd.DD} drag drop object for this element.
   * @param {String} group The group the DD object is member of
   * @param {Object} config The DD config object
   * @param {Object} overrides An object containing methods to override/implement on the DD object
   * @return {Ext.dd.DD} The DD object
   */
  initDD: function initDD(group, config, overrides) {
    var dd = new Ext.dd.DD(Ext.id(this.dom), group, config);
    return Ext.apply(dd, overrides);
  },

  /**
   * Initializes a {@link Ext.dd.DDProxy} object for this element.
   * @param {String} group The group the DDProxy object is member of
   * @param {Object} config The DDProxy config object
   * @param {Object} overrides An object containing methods to override/implement on the DDProxy object
   * @return {Ext.dd.DDProxy} The DDProxy object
   */
  initDDProxy: function initDDProxy(group, config, overrides) {
    var dd = new Ext.dd.DDProxy(Ext.id(this.dom), group, config);
    return Ext.apply(dd, overrides);
  },

  /**
   * Initializes a {@link Ext.dd.DDTarget} object for this element.
   * @param {String} group The group the DDTarget object is member of
   * @param {Object} config The DDTarget config object
   * @param {Object} overrides An object containing methods to override/implement on the DDTarget object
   * @return {Ext.dd.DDTarget} The DDTarget object
   */
  initDDTarget: function initDDTarget(group, config, overrides) {
    var dd = new Ext.dd.DDTarget(Ext.id(this.dom), group, config);
    return Ext.apply(dd, overrides);
  }
});

/***/ }),
/* 790 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Api
 * @extends Object
 * Ext.data.Api is a singleton designed to manage the data API including methods
 * for validating a developer's DataProxy API.  Defines variables for CRUD actions
 * create, read, update and destroy in addition to a mapping of RESTful HTTP methods
 * GET, POST, PUT and DELETE to CRUD actions.
 * @singleton
 */
Ext.data.Api = function () {
  // private validActions.  validActions is essentially an inverted hash of Ext.data.Api.actions, where value becomes the key.
  // Some methods in this singleton (e.g.: getActions, getVerb) will loop through actions with the code <code>for (var verb in this.actions)</code>
  // For efficiency, some methods will first check this hash for a match.  Those methods which do acces validActions will cache their result here.
  // We cannot pre-define this hash since the developer may over-ride the actions at runtime.
  var validActions = {};
  return {
    /**
     * Defined actions corresponding to remote actions:
     * <pre><code>
    actions: {
    create  : 'create',  // Text representing the remote-action to create records on server.
    read    : 'read',    // Text representing the remote-action to read/load data from server.
    update  : 'update',  // Text representing the remote-action to update records on server.
    destroy : 'destroy'  // Text representing the remote-action to destroy records on server.
    }
     * </code></pre>
     * @property actions
     * @type Object
     */
    actions: {
      create: 'create',
      read: 'read',
      update: 'update',
      destroy: 'destroy'
    },

    /**
     * Defined {CRUD action}:{HTTP method} pairs to associate HTTP methods with the
     * corresponding actions for {@link Ext.data.DataProxy#restful RESTful proxies}.
     * Defaults to:
     * <pre><code>
    restActions : {
    create  : 'POST',
    read    : 'GET',
    update  : 'PUT',
    destroy : 'DELETE'
    },
     * </code></pre>
     */
    restActions: {
      create: 'POST',
      read: 'GET',
      update: 'PUT',
      destroy: 'DELETE'
    },

    /**
     * Returns true if supplied action-name is a valid API action defined in <code>{@link #actions}</code> constants
     * @param {String} action
     * @param {String[]}(Optional) List of available CRUD actions.  Pass in list when executing multiple times for efficiency.
     * @return {Boolean}
     */
    isAction: function isAction(action) {
      return Ext.data.Api.actions[action] ? true : false;
    },

    /**
     * Returns the actual CRUD action KEY "create", "read", "update" or "destroy" from the supplied action-name.  This method is used internally and shouldn't generally
     * need to be used directly.  The key/value pair of Ext.data.Api.actions will often be identical but this is not necessarily true.  A developer can override this naming
     * convention if desired.  However, the framework internally calls methods based upon the KEY so a way of retreiving the the words "create", "read", "update" and "destroy" is
     * required.  This method will cache discovered KEYS into the private validActions hash.
     * @param {String} name The runtime name of the action.
     * @return {String||null} returns the action-key, or verb of the user-action or null if invalid.
     * @nodoc
     */
    getVerb: function getVerb(name) {
      if (validActions[name]) {
        return validActions[name]; // <-- found in cache.  return immediately.
      }

      for (var verb in this.actions) {
        if (this.actions[verb] === name) {
          validActions[name] = verb;
          break;
        }
      }

      return validActions[name] !== undefined ? validActions[name] : null;
    },

    /**
     * Returns true if the supplied API is valid; that is, check that all keys match defined actions
     * otherwise returns an array of mistakes.
     * @return {String[]||true}
     */
    isValid: function isValid(api) {
      var invalid = [];
      var crud = this.actions; // <-- cache a copy of the actions.

      for (var action in api) {
        if (!(action in crud)) {
          invalid.push(action);
        }
      }

      return !invalid.length ? true : invalid;
    },

    /**
     * Returns true if the supplied verb upon the supplied proxy points to a unique url in that none of the other api-actions
     * point to the same url.  The question is important for deciding whether to insert the "xaction" HTTP parameter within an
     * Ajax request.  This method is used internally and shouldn't generally need to be called directly.
     * @param {Ext.data.DataProxy} proxy
     * @param {String} verb
     * @return {Boolean}
     */
    hasUniqueUrl: function hasUniqueUrl(proxy, verb) {
      var url = proxy.api[verb] ? proxy.api[verb].url : null;
      var unique = true;

      for (var action in proxy.api) {
        if ((unique = action === verb ? true : proxy.api[action].url != url ? true : false) === false) {
          break;
        }
      }

      return unique;
    },

    /**
     * This method is used internally by <tt>{@link Ext.data.DataProxy DataProxy}</tt> and should not generally need to be used directly.
     * Each action of a DataProxy api can be initially defined as either a String or an Object.  When specified as an object,
     * one can explicitly define the HTTP method (GET|POST) to use for each CRUD action.  This method will prepare the supplied API, setting
     * each action to the Object form.  If your API-actions do not explicitly define the HTTP method, the "method" configuration-parameter will
     * be used.  If the method configuration parameter is not specified, POST will be used.
     <pre><code>
    new Ext.data.HttpProxy({
    method: "POST",     // <-- default HTTP method when not specified.
    api: {
    create: 'create.php',
    load: 'read.php',
    save: 'save.php',
    destroy: 'destroy.php'
    }
    });
    // Alternatively, one can use the object-form to specify the API
    new Ext.data.HttpProxy({
    api: {
    load: {url: 'read.php', method: 'GET'},
    create: 'create.php',
    destroy: 'destroy.php',
    save: 'update.php'
    }
    });
    </code></pre>
     *
     * @param {Ext.data.DataProxy} proxy
     */
    prepare: function prepare(proxy) {
      if (!proxy.api) {
        proxy.api = {}; // <-- No api?  create a blank one.
      }

      for (var verb in this.actions) {
        var action = this.actions[verb];
        proxy.api[action] = proxy.api[action] || proxy.url || proxy.directFn;

        if (typeof proxy.api[action] == 'string') {
          proxy.api[action] = {
            url: proxy.api[action],
            method: proxy.restful === true ? Ext.data.Api.restActions[action] : undefined
          };
        }
      }
    },

    /**
     * Prepares a supplied Proxy to be RESTful.  Sets the HTTP method for each api-action to be one of
     * GET, POST, PUT, DELETE according to the defined {@link #restActions}.
     * @param {Ext.data.DataProxy} proxy
     */
    restify: function restify(proxy) {
      proxy.restful = true;

      for (var verb in this.restActions) {
        proxy.api[this.actions[verb]].method || (proxy.api[this.actions[verb]].method = this.restActions[verb]);
      } // TODO: perhaps move this interceptor elsewhere?  like into DataProxy, perhaps?  Placed here
      // to satisfy initial 3.0 final release of REST features.


      proxy.onWrite = proxy.onWrite.createInterceptor(function (action, o, response, rs) {
        var reader = o.reader;
        var res = new Ext.data.Response({
          action: action,
          raw: response
        });

        switch (response.status) {
          case 200:
            // standard 200 response, send control back to HttpProxy#onWrite by returning true from this intercepted #onWrite
            return true;
            break;

          case 201:
            // entity created but no response returned
            if (Ext.isEmpty(res.raw.responseText)) {
              res.success = true;
            } else {
              //if the response contains data, treat it like a 200
              return true;
            }

            break;

          case 204:
            // no-content.  Create a fake response.
            res.success = true;
            res.data = null;
            break;

          default:
            return true;
            break;
        }

        if (res.success === true) {
          this.fireEvent("write", this, action, res.data, res, rs, o.request.arg);
        } else {
          this.fireEvent('exception', this, 'remote', action, o, res, rs);
        }

        o.request.callback.call(o.request.scope, res.data, res, res.success);
        return false; // <-- false to prevent intercepted function from running.
      }, proxy);
    }
  };
}();
/**
 * Ext.data.Response
 * Experimental.  Do not use directly.
 */


Ext.data.Response = function (params, response) {
  Ext.apply(this, params, {
    raw: response
  });
};

Ext.data.Response.prototype = {
  message: null,
  success: false,
  status: null,
  root: null,
  raw: null,
  getMessage: function getMessage() {
    return this.message;
  },
  getSuccess: function getSuccess() {
    return this.success;
  },
  getStatus: function getStatus() {
    return this.status;
  },
  getRoot: function getRoot() {
    return this.root;
  },
  getRawResponse: function getRawResponse() {
    return this.raw;
  }
};
/**
 * @class Ext.data.Api.Error
 * @extends Ext.Error
 * Error class for Ext.data.Api errors
 */

Ext.data.Api.Error = Ext.extend(Ext.Error, {
  constructor: function constructor(message, arg) {
    this.arg = arg;
    Ext.Error.call(this, message);
  },
  name: 'Ext.data.Api'
});
Ext.apply(Ext.data.Api.Error.prototype, {
  lang: {
    'action-url-undefined': 'No fallback url defined for this action.  When defining a DataProxy api, please be sure to define an url for each CRUD action in Ext.data.Api.actions or define a default url in addition to your api-configuration.',
    'invalid': 'received an invalid API-configuration.  Please ensure your proxy API-configuration contains only the actions defined in Ext.data.Api.actions',
    'invalid-url': 'Invalid url.  Please review your proxy configuration.',
    'execute': 'Attempted to execute an unknown action.  Valid API actions are defined in Ext.data.Api.actions"'
  }
});

/***/ }),
/* 791 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.SortTypes
 * @singleton
 * Defines the default sorting (casting?) comparison functions used when sorting data.
 */
Ext.data.SortTypes = {
  /**
   * Default sort that does nothing
   * @param {Mixed} s The value being converted
   * @return {Mixed} The comparison value
   */
  none: function none(s) {
    return s;
  },

  /**
   * The regular expression used to strip tags
   * @type {RegExp}
   * @property
   */
  stripTagsRE: /<\/?[^>]+>/gi,

  /**
   * Strips all HTML tags to sort on text only
   * @param {Mixed} s The value being converted
   * @return {String} The comparison value
   */
  asText: function asText(s) {
    return String(s).replace(this.stripTagsRE, "");
  },

  /**
   * Strips all HTML tags to sort on text only - Case insensitive
   * @param {Mixed} s The value being converted
   * @return {String} The comparison value
   */
  asUCText: function asUCText(s) {
    return String(s).toUpperCase().replace(this.stripTagsRE, "");
  },

  /**
   * Case insensitive string
   * @param {Mixed} s The value being converted
   * @return {String} The comparison value
   */
  asUCString: function asUCString(s) {
    return String(s).toUpperCase();
  },

  /**
   * Date sorting
   * @param {Mixed} s The value being converted
   * @return {Number} The comparison value
   */
  asDate: function asDate(s) {
    if (!s) {
      return 0;
    }

    if (Ext.isDate(s)) {
      return s.getTime();
    }

    return Date.parse(String(s));
  },

  /**
   * Float sorting
   * @param {Mixed} s The value being converted
   * @return {Float} The comparison value
   */
  asFloat: function asFloat(s) {
    var val = parseFloat(String(s).replace(/,/g, ""));
    return isNaN(val) ? 0 : val;
  },

  /**
   * Integer sorting
   * @param {Mixed} s The value being converted
   * @return {Number} The comparison value
   */
  asInt: function asInt(s) {
    var val = parseInt(String(s).replace(/,/g, ""), 10);
    return isNaN(val) ? 0 : val;
  }
};

/***/ }),
/* 792 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Record
 * <p>Instances of this class encapsulate both Record <em>definition</em> information, and Record
 * <em>value</em> information for use in {@link Ext.data.Store} objects, or any code which needs
 * to access Records cached in an {@link Ext.data.Store} object.</p>
 * <p>Constructors for this class are generated by passing an Array of field definition objects to {@link #create}.
 * Instances are usually only created by {@link Ext.data.Reader} implementations when processing unformatted data
 * objects.</p>
 * <p>Note that an instance of a Record class may only belong to one {@link Ext.data.Store Store} at a time.
 * In order to copy data from one Store to another, use the {@link #copy} method to create an exact
 * copy of the Record, and insert the new instance into the other Store.</p>
 * <p>When serializing a Record for submission to the server, be aware that it contains many private
 * properties, and also a reference to its owning Store which in turn holds references to its Records.
 * This means that a whole Record may not be encoded using {@link Ext.util.JSON.encode}. Instead, use the
 * <code>{@link #data}</code> and <code>{@link #id}</code> properties.</p>
 * <p>Record objects generated by this constructor inherit all the methods of Ext.data.Record listed below.</p>
 * @constructor
 * <p>This constructor should not be used to create Record objects. Instead, use {@link #create} to
 * generate a subclass of Ext.data.Record configured with information about its constituent fields.<p>
 * <p><b>The generated constructor has the same signature as this constructor.</b></p>
 * @param {Object} data (Optional) An object, the properties of which provide values for the new Record's
 * fields. If not specified the <code>{@link Ext.data.Field#defaultValue defaultValue}</code>
 * for each field will be assigned.
 * @param {Object} id (Optional) The id of the Record. The id is used by the
 * {@link Ext.data.Store} object which owns the Record to index its collection
 * of Records (therefore this id should be unique within each store). If an
 * <code>id</code> is not specified a <b><code>{@link #phantom}</code></b>
 * Record will be created with an {@link #Record.id automatically generated id}.
 */
Ext.data.Record = function (data, id) {
  // if no id, call the auto id method
  this.id = id || id === 0 ? id : Ext.data.Record.id(this);
  this.data = data || {};
};
/**
 * Generate a constructor for a specific Record layout.
 * @param {Array} o An Array of <b>{@link Ext.data.Field Field}</b> definition objects.
 * The constructor generated by this method may be used to create new Record instances. The data
 * object must contain properties named after the {@link Ext.data.Field field}
 * <b><tt>{@link Ext.data.Field#name}s</tt></b>.  Example usage:<pre><code>
// create a Record constructor from a description of the fields
var TopicRecord = Ext.data.Record.create([ // creates a subclass of Ext.data.Record
    {{@link Ext.data.Field#name name}: 'title', {@link Ext.data.Field#mapping mapping}: 'topic_title'},
    {name: 'author', mapping: 'username', allowBlank: false},
    {name: 'totalPosts', mapping: 'topic_replies', type: 'int'},
    {name: 'lastPost', mapping: 'post_time', type: 'date'},
    {name: 'lastPoster', mapping: 'user2'},
    {name: 'excerpt', mapping: 'post_text', allowBlank: false},
    // In the simplest case, if no properties other than <tt>name</tt> are required,
    // a field definition may consist of just a String for the field name.
    'signature'
]);

// create Record instance
var myNewRecord = new TopicRecord(
    {
        title: 'Do my job please',
        author: 'noobie',
        totalPosts: 1,
        lastPost: new Date(),
        lastPoster: 'Animal',
        excerpt: 'No way dude!',
        signature: ''
    },
    id // optionally specify the id of the record otherwise {@link #Record.id one is auto-assigned}
);
myStore.{@link Ext.data.Store#add add}(myNewRecord);
</code></pre>
 * @method create
 * @return {function} A constructor which is used to create new Records according
 * to the definition. The constructor has the same signature as {@link #Record}.
 * @static
 */


Ext.data.Record.create = function (o) {
  var f = Ext.extend(Ext.data.Record, {});
  var p = f.prototype;
  p.fields = new Ext.util.MixedCollection(false, function (field) {
    return field.name;
  });

  for (var i = 0, len = o.length; i < len; i++) {
    p.fields.add(new Ext.data.Field(o[i]));
  }

  f.getField = function (name) {
    return p.fields.get(name);
  };

  return f;
};

Ext.data.Record.PREFIX = 'ext-record';
Ext.data.Record.AUTO_ID = 1;
Ext.data.Record.EDIT = 'edit';
Ext.data.Record.REJECT = 'reject';
Ext.data.Record.COMMIT = 'commit';
/**
 * Generates a sequential id. This method is typically called when a record is {@link #create}d
 * and {@link #Record no id has been specified}. The returned id takes the form:
 * <tt>&#123;PREFIX}-&#123;AUTO_ID}</tt>.<div class="mdetail-params"><ul>
 * <li><b><tt>PREFIX</tt></b> : String<p class="sub-desc"><tt>Ext.data.Record.PREFIX</tt>
 * (defaults to <tt>'ext-record'</tt>)</p></li>
 * <li><b><tt>AUTO_ID</tt></b> : String<p class="sub-desc"><tt>Ext.data.Record.AUTO_ID</tt>
 * (defaults to <tt>1</tt> initially)</p></li>
 * </ul></div>
 * @param {Record} rec The record being created.  The record does not exist, it's a {@link #phantom}.
 * @return {String} auto-generated string id, <tt>"ext-record-i++'</tt>;
 */

Ext.data.Record.id = function (rec) {
  rec.phantom = true;
  return [Ext.data.Record.PREFIX, '-', Ext.data.Record.AUTO_ID++].join('');
};

Ext.data.Record.prototype = {
  /**
   * <p><b>This property is stored in the Record definition's <u>prototype</u></b></p>
   * A MixedCollection containing the defined {@link Ext.data.Field Field}s for this Record.  Read-only.
   * @property fields
   * @type Ext.util.MixedCollection
   */

  /**
   * An object hash representing the data for this Record. Every field name in the Record definition
   * is represented by a property of that name in this object. Note that unless you specified a field
   * with {@link Ext.data.Field#name name} "id" in the Record definition, this will <b>not</b> contain
   * an <tt>id</tt> property.
   * @property data
   * @type {Object}
   */

  /**
   * The unique ID of the Record {@link #Record as specified at construction time}.
   * @property id
   * @type {Object}
   */

  /**
   * <p><b>Only present if this Record was created by an {@link Ext.data.XmlReader XmlReader}</b>.</p>
   * <p>The XML element which was the source of the data for this Record.</p>
   * @property node
   * @type {XMLElement}
   */

  /**
   * <p><b>Only present if this Record was created by an {@link Ext.data.ArrayReader ArrayReader} or a {@link Ext.data.JsonReader JsonReader}</b>.</p>
   * <p>The Array or object which was the source of the data for this Record.</p>
   * @property json
   * @type {Array|Object}
   */

  /**
   * Readonly flag - true if this Record has been modified.
   * @type Boolean
   */
  dirty: false,
  editing: false,
  error: null,

  /**
   * This object contains a key and value storing the original values of all modified
   * fields or is null if no fields have been modified.
   * @property modified
   * @type {Object}
   */
  modified: null,

  /**
   * <tt>true</tt> when the record does not yet exist in a server-side database (see
   * {@link #markDirty}).  Any record which has a real database pk set as its id property
   * is NOT a phantom -- it's real.
   * @property phantom
   * @type {Boolean}
   */
  phantom: false,
  // private
  join: function join(store) {
    /**
     * The {@link Ext.data.Store} to which this Record belongs.
     * @property store
     * @type {Ext.data.Store}
     */
    this.store = store;
  },

  /**
   * Set the {@link Ext.data.Field#name named field} to the specified value.  For example:
   * <pre><code>
  // record has a field named 'firstname'
  var Employee = Ext.data.Record.{@link #create}([
  {name: 'firstname'},
  ...
  ]);
  // update the 2nd record in the store:
  var rec = myStore.{@link Ext.data.Store#getAt getAt}(1);
  // set the value (shows dirty flag):
  rec.set('firstname', 'Betty');
  // commit the change (removes dirty flag):
  rec.{@link #commit}();
  // update the record in the store, bypass setting dirty flag,
  // and do not store the change in the {@link Ext.data.Store#getModifiedRecords modified records}
  rec.{@link #data}['firstname'] = 'Wilma'; // updates record, but not the view
  rec.{@link #commit}(); // updates the view
   * </code></pre>
   * <b>Notes</b>:<div class="mdetail-params"><ul>
   * <li>If the store has a writer and <code>autoSave=true</code>, each set()
   * will execute an XHR to the server.</li>
   * <li>Use <code>{@link #beginEdit}</code> to prevent the store's <code>update</code>
   * event firing while using set().</li>
   * <li>Use <code>{@link #endEdit}</code> to have the store's <code>update</code>
   * event fire.</li>
   * </ul></div>
   * @param {String} name The {@link Ext.data.Field#name name of the field} to set.
   * @param {String/Object/Array} value The value to set the field to.
   */
  set: function set(name, value) {
    var encode = Ext.isPrimitive(value) ? String : Ext.encode;

    if (encode(this.data[name]) == encode(value)) {
      return;
    }

    this.dirty = true;

    if (!this.modified) {
      this.modified = {};
    }

    if (this.modified[name] === undefined) {
      this.modified[name] = this.data[name];
    }

    this.data[name] = value;

    if (!this.editing) {
      this.afterEdit();
    }
  },
  // private
  afterEdit: function afterEdit() {
    if (this.store) {
      this.store.afterEdit(this);
    }
  },
  // private
  afterReject: function afterReject() {
    if (this.store) {
      this.store.afterReject(this);
    }
  },
  // private
  afterCommit: function afterCommit() {
    if (this.store) {
      this.store.afterCommit(this);
    }
  },

  /**
   * Get the value of the {@link Ext.data.Field#name named field}.
   * @param {String} name The {@link Ext.data.Field#name name of the field} to get the value of.
   * @return {Object} The value of the field.
   */
  get: function get(name) {
    return this.data[name];
  },

  /**
   * Begin an edit. While in edit mode, no events (e.g.. the <code>update</code> event)
   * are relayed to the containing store.
   * See also: <code>{@link #endEdit}</code> and <code>{@link #cancelEdit}</code>.
   */
  beginEdit: function beginEdit() {
    this.editing = true;
    this.modified = this.modified || {};
  },

  /**
   * Cancels all changes made in the current edit operation.
   */
  cancelEdit: function cancelEdit() {
    this.editing = false;
    delete this.modified;
  },

  /**
   * End an edit. If any data was modified, the containing store is notified
   * (ie, the store's <code>update</code> event will fire).
   */
  endEdit: function endEdit() {
    this.editing = false;

    if (this.dirty) {
      this.afterEdit();
    }
  },

  /**
   * Usually called by the {@link Ext.data.Store} which owns the Record.
   * Rejects all changes made to the Record since either creation, or the last commit operation.
   * Modified fields are reverted to their original values.
   * <p>Developers should subscribe to the {@link Ext.data.Store#update} event
   * to have their code notified of reject operations.</p>
   * @param {Boolean} silent (optional) True to skip notification of the owning
   * store of the change (defaults to false)
   */
  reject: function reject(silent) {
    var m = this.modified;

    for (var n in m) {
      if (typeof m[n] != "function") {
        this.data[n] = m[n];
      }
    }

    this.dirty = false;
    delete this.modified;
    this.editing = false;

    if (silent !== true) {
      this.afterReject();
    }
  },

  /**
   * Usually called by the {@link Ext.data.Store} which owns the Record.
   * Commits all changes made to the Record since either creation, or the last commit operation.
   * <p>Developers should subscribe to the {@link Ext.data.Store#update} event
   * to have their code notified of commit operations.</p>
   * @param {Boolean} silent (optional) True to skip notification of the owning
   * store of the change (defaults to false)
   */
  commit: function commit(silent) {
    this.dirty = false;
    delete this.modified;
    this.editing = false;

    if (silent !== true) {
      this.afterCommit();
    }
  },

  /**
   * Gets a hash of only the fields that have been modified since this Record was created or commited.
   * @return Object
   */
  getChanges: function getChanges() {
    var m = this.modified,
        cs = {};

    for (var n in m) {
      if (m.hasOwnProperty(n)) {
        cs[n] = this.data[n];
      }
    }

    return cs;
  },
  // private
  hasError: function hasError() {
    return this.error !== null;
  },
  // private
  clearError: function clearError() {
    this.error = null;
  },

  /**
   * Creates a copy (clone) of this Record.
   * @param {String} id (optional) A new Record id, defaults to the id
   * of the record being copied. See <code>{@link #id}</code>. 
   * To generate a phantom record with a new id use:<pre><code>
  var rec = record.copy(); // clone the record
  Ext.data.Record.id(rec); // automatically generate a unique sequential id
   * </code></pre>
   * @return {Record}
   */
  copy: function copy(newId) {
    return new this.constructor(Ext.apply({}, this.data), newId || this.id);
  },

  /**
   * Returns <tt>true</tt> if the passed field name has been <code>{@link #modified}</code>
   * since the load or last commit.
   * @param {String} fieldName {@link Ext.data.Field.{@link Ext.data.Field#name}
   * @return {Boolean}
   */
  isModified: function isModified(fieldName) {
    return !!(this.modified && this.modified.hasOwnProperty(fieldName));
  },

  /**
   * By default returns <tt>false</tt> if any {@link Ext.data.Field field} within the
   * record configured with <tt>{@link Ext.data.Field#allowBlank} = false</tt> returns
   * <tt>true</tt> from an {@link Ext}.{@link Ext#isEmpty isempty} test.
   * @return {Boolean}
   */
  isValid: function isValid() {
    return this.fields.find(function (f) {
      return f.allowBlank === false && Ext.isEmpty(this.data[f.name]) ? true : false;
    }, this) ? false : true;
  },

  /**
   * <p>Marks this <b>Record</b> as <code>{@link #dirty}</code>.  This method
   * is used interally when adding <code>{@link #phantom}</code> records to a
   * {@link Ext.data.Store#writer writer enabled store}.</p>
   * <br><p>Marking a record <code>{@link #dirty}</code> causes the phantom to
   * be returned by {@link Ext.data.Store#getModifiedRecords} where it will
   * have a create action composed for it during {@link Ext.data.Store#save store save}
   * operations.</p>
   */
  markDirty: function markDirty() {
    this.dirty = true;

    if (!this.modified) {
      this.modified = {};
    }

    this.fields.each(function (f) {
      this.modified[f.name] = this.data[f.name];
    }, this);
  }
};

/***/ }),
/* 793 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.StoreMgr
 * @extends Ext.util.MixedCollection
 * The default global group of stores.
 * @singleton
 */
Ext.StoreMgr = Ext.apply(new Ext.util.MixedCollection(), {
  /**
   * @cfg {Object} listeners @hide
   */

  /**
   * Registers one or more Stores with the StoreMgr. You do not normally need to register stores
   * manually.  Any store initialized with a {@link Ext.data.Store#storeId} will be auto-registered. 
   * @param {Ext.data.Store} store1 A Store instance
   * @param {Ext.data.Store} store2 (optional)
   * @param {Ext.data.Store} etc... (optional)
   */
  register: function register() {
    for (var i = 0, s; s = arguments[i]; i++) {
      this.add(s);
    }
  },

  /**
   * Unregisters one or more Stores with the StoreMgr
   * @param {String/Object} id1 The id of the Store, or a Store instance
   * @param {String/Object} id2 (optional)
   * @param {String/Object} etc... (optional)
   */
  unregister: function unregister() {
    for (var i = 0, s; s = arguments[i]; i++) {
      this.remove(this.lookup(s));
    }
  },

  /**
   * Gets a registered Store by id
   * @param {String/Object} id The id of the Store, or a Store instance
   * @return {Ext.data.Store}
   */
  lookup: function lookup(id) {
    if (Ext.isArray(id)) {
      var fields = ['field1'],
          expand = !Ext.isArray(id[0]);

      if (!expand) {
        for (var i = 2, len = id[0].length; i <= len; ++i) {
          fields.push('field' + i);
        }
      }

      return new Ext.data.ArrayStore({
        fields: fields,
        data: id,
        expandData: expand,
        autoDestroy: true,
        autoCreated: true
      });
    }

    return Ext.isObject(id) ? id.events ? id : Ext.create(id, 'store') : this.get(id);
  },
  // getKey implementation for MixedCollection
  getKey: function getKey(o) {
    return o.storeId;
  }
});

/***/ }),
/* 794 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Store
 * @extends Ext.util.Observable
 * <p>The Store class encapsulates a client side cache of {@link Ext.data.Record Record}
 * objects which provide input data for Components such as the {@link Ext.grid.GridPanel GridPanel},
 * the {@link Ext.form.ComboBox ComboBox}, or the {@link Ext.DataView DataView}.</p>
 * <p><u>Retrieving Data</u></p>
 * <p>A Store object may access a data object using:<div class="mdetail-params"><ul>
 * <li>{@link #proxy configured implementation} of {@link Ext.data.DataProxy DataProxy}</li>
 * <li>{@link #data} to automatically pass in data</li>
 * <li>{@link #loadData} to manually pass in data</li>
 * </ul></div></p>
 * <p><u>Reading Data</u></p>
 * <p>A Store object has no inherent knowledge of the format of the data object (it could be
 * an Array, XML, or JSON). A Store object uses an appropriate {@link #reader configured implementation}
 * of a {@link Ext.data.DataReader DataReader} to create {@link Ext.data.Record Record} instances from the data
 * object.</p>
 * <p><u>Store Types</u></p>
 * <p>There are several implementations of Store available which are customized for use with
 * a specific DataReader implementation.  Here is an example using an ArrayStore which implicitly
 * creates a reader commensurate to an Array data object.</p>
 * <pre><code>
var myStore = new Ext.data.ArrayStore({
    fields: ['fullname', 'first'],
    idIndex: 0 // id for each record will be the first element
});
 * </code></pre>
 * <p>For custom implementations create a basic {@link Ext.data.Store} configured as needed:</p>
 * <pre><code>
// create a {@link Ext.data.Record Record} constructor:
var rt = Ext.data.Record.create([
    {name: 'fullname'},
    {name: 'first'}
]);
var myStore = new Ext.data.Store({
    // explicitly create reader
    reader: new Ext.data.ArrayReader(
        {
            idIndex: 0  // id for each record will be the first element
        },
        rt // recordType
    )
});
 * </code></pre>
 * <p>Load some data into store (note the data object is an array which corresponds to the reader):</p>
 * <pre><code>
var myData = [
    [1, 'Fred Flintstone', 'Fred'],  // note that id for the record is the first element
    [2, 'Barney Rubble', 'Barney']
];
myStore.loadData(myData);
 * </code></pre>
 * <p>Records are cached and made available through accessor functions.  An example of adding
 * a record to the store:</p>
 * <pre><code>
var defaultData = {
    fullname: 'Full Name',
    first: 'First Name'
};
var recId = 100; // provide unique id for the record
var r = new myStore.recordType(defaultData, ++recId); // create new record
myStore.{@link #insert}(0, r); // insert a new record into the store (also see {@link #add})
 * </code></pre>
 * <p><u>Writing Data</u></p>
 * <p>And <b>new in Ext version 3</b>, use the new {@link Ext.data.DataWriter DataWriter} to create an automated, <a href="http://extjs.com/deploy/dev/examples/writer/writer.html">Writable Store</a>
 * along with <a href="http://extjs.com/deploy/dev/examples/restful/restful.html">RESTful features.</a>
 * @constructor
 * Creates a new Store.
 * @param {Object} config A config object containing the objects needed for the Store to access data,
 * and read the data into Records.
 * @xtype store
 */
Ext.data.Store = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {String} storeId If passed, the id to use to register with the <b>{@link Ext.StoreMgr StoreMgr}</b>.
   * <p><b>Note</b>: if a (deprecated) <tt>{@link #id}</tt> is specified it will supersede the <tt>storeId</tt>
   * assignment.</p>
   */

  /**
   * @cfg {String} url If a <tt>{@link #proxy}</tt> is not specified the <tt>url</tt> will be used to
   * implicitly configure a {@link Ext.data.HttpProxy HttpProxy} if an <tt>url</tt> is specified.
   * Typically this option, or the <code>{@link #data}</code> option will be specified.
   */

  /**
   * @cfg {Boolean/Object} autoLoad If <tt>{@link #data}</tt> is not specified, and if <tt>autoLoad</tt>
   * is <tt>true</tt> or an <tt>Object</tt>, this store's {@link #load} method is automatically called
   * after creation. If the value of <tt>autoLoad</tt> is an <tt>Object</tt>, this <tt>Object</tt> will
   * be passed to the store's {@link #load} method.
   */

  /**
   * @cfg {Ext.data.DataProxy} proxy The {@link Ext.data.DataProxy DataProxy} object which provides
   * access to a data object.  See <code>{@link #url}</code>.
   */

  /**
   * @cfg {Array} data An inline data object readable by the <code>{@link #reader}</code>.
   * Typically this option, or the <code>{@link #url}</code> option will be specified.
   */

  /**
   * @cfg {Ext.data.DataReader} reader The {@link Ext.data.DataReader Reader} object which processes the
   * data object and returns an Array of {@link Ext.data.Record} objects which are cached keyed by their
   * <b><tt>{@link Ext.data.Record#id id}</tt></b> property.
   */

  /**
   * @cfg {Ext.data.DataWriter} writer
   * <p>The {@link Ext.data.DataWriter Writer} object which processes a record object for being written
   * to the server-side database.</p>
   * <br><p>When a writer is installed into a Store the {@link #add}, {@link #remove}, and {@link #update}
   * events on the store are monitored in order to remotely {@link #createRecords create records},
   * {@link #destroyRecord destroy records}, or {@link #updateRecord update records}.</p>
   * <br><p>The proxy for this store will relay any {@link #writexception} events to this store.</p>
   * <br><p>Sample implementation:
   * <pre><code>
  var writer = new {@link Ext.data.JsonWriter}({
  encode: true,
  writeAllFields: true // write all fields, not just those that changed
  });
  // Typical Store collecting the Proxy, Reader and Writer together.
  var store = new Ext.data.Store({
  storeId: 'user',
  root: 'records',
  proxy: proxy,
  reader: reader,
  writer: writer,     // <-- plug a DataWriter into the store just as you would a Reader
  paramsAsHash: true,
  autoSave: false    // <-- false to delay executing create, update, destroy requests
                      //     until specifically told to do so.
  });
   * </code></pre></p>
   */
  writer: undefined,

  /**
   * @cfg {Object} baseParams
   * <p>An object containing properties which are to be sent as parameters
   * for <i>every</i> HTTP request.</p>
   * <p>Parameters are encoded as standard HTTP parameters using {@link Ext#urlEncode}.</p>
   * <p><b>Note</b>: <code>baseParams</code> may be superseded by any <code>params</code>
   * specified in a <code>{@link #load}</code> request, see <code>{@link #load}</code>
   * for more details.</p>
   * This property may be modified after creation using the <code>{@link #setBaseParam}</code>
   * method.
   * @property
   */

  /**
   * @cfg {Object} sortInfo A config object to specify the sort order in the request of a Store's
   * {@link #load} operation.  Note that for local sorting, the <tt>direction</tt> property is
   * case-sensitive. See also {@link #remoteSort} and {@link #paramNames}.
   * For example:<pre><code>
  sortInfo: {
  field: 'fieldName',
  direction: 'ASC' // or 'DESC' (case sensitive for local sorting)
  }
  </code></pre>
   */

  /**
   * @cfg {boolean} remoteSort <tt>true</tt> if sorting is to be handled by requesting the <tt>{@link #proxy Proxy}</tt>
   * to provide a refreshed version of the data object in sorted order, as opposed to sorting the Record cache
   * in place (defaults to <tt>false</tt>).
   * <p>If <tt>remoteSort</tt> is <tt>true</tt>, then clicking on a {@link Ext.grid.Column Grid Column}'s
   * {@link Ext.grid.Column#header header} causes the current page to be requested from the server appending
   * the following two parameters to the <b><tt>{@link #load params}</tt></b>:<div class="mdetail-params"><ul>
   * <li><b><tt>sort</tt></b> : String<p class="sub-desc">The <tt>name</tt> (as specified in the Record's
   * {@link Ext.data.Field Field definition}) of the field to sort on.</p></li>
   * <li><b><tt>dir</tt></b> : String<p class="sub-desc">The direction of the sort, 'ASC' or 'DESC' (case-sensitive).</p></li>
   * </ul></div></p>
   */
  remoteSort: false,

  /**
   * @cfg {Boolean} autoDestroy <tt>true</tt> to destroy the store when the component the store is bound
   * to is destroyed (defaults to <tt>false</tt>).
   * <p><b>Note</b>: this should be set to true when using stores that are bound to only 1 component.</p>
   */
  autoDestroy: false,

  /**
   * @cfg {Boolean} pruneModifiedRecords <tt>true</tt> to clear all modified record information each time
   * the store is loaded or when a record is removed (defaults to <tt>false</tt>). See {@link #getModifiedRecords}
   * for the accessor method to retrieve the modified records.
   */
  pruneModifiedRecords: false,

  /**
   * Contains the last options object used as the parameter to the {@link #load} method. See {@link #load}
   * for the details of what this may contain. This may be useful for accessing any params which were used
   * to load the current Record cache.
   * @property
   */
  lastOptions: null,

  /**
   * @cfg {Boolean} autoSave
   * <p>Defaults to <tt>true</tt> causing the store to automatically {@link #save} records to
   * the server when a record is modified (ie: becomes 'dirty'). Specify <tt>false</tt> to manually call {@link #save}
   * to send all modifiedRecords to the server.</p>
   * <br><p><b>Note</b>: each CRUD action will be sent as a separate request.</p>
   */
  autoSave: true,

  /**
   * @cfg {Boolean} batch
   * <p>Defaults to <tt>true</tt> (unless <code>{@link #restful}:true</code>). Multiple
   * requests for each CRUD action (CREATE, READ, UPDATE and DESTROY) will be combined
   * and sent as one transaction. Only applies when <code>{@link #autoSave}</code> is set
   * to <tt>false</tt>.</p>
   * <br><p>If Store is RESTful, the DataProxy is also RESTful, and a unique transaction is
   * generated for each record.</p>
   */
  batch: true,

  /**
   * @cfg {Boolean} restful
   * Defaults to <tt>false</tt>.  Set to <tt>true</tt> to have the Store and the set
   * Proxy operate in a RESTful manner. The store will automatically generate GET, POST,
   * PUT and DELETE requests to the server. The HTTP method used for any given CRUD
   * action is described in {@link Ext.data.Api#restActions}.  For additional information
   * see {@link Ext.data.DataProxy#restful}.
   * <p><b>Note</b>: if <code>{@link #restful}:true</code> <code>batch</code> will
   * internally be set to <tt>false</tt>.</p>
   */
  restful: false,

  /**
   * @cfg {Object} paramNames
   * <p>An object containing properties which specify the names of the paging and
   * sorting parameters passed to remote servers when loading blocks of data. By default, this
   * object takes the following form:</p><pre><code>
  {
  start : 'start',  // The parameter name which specifies the start row
  limit : 'limit',  // The parameter name which specifies number of rows to return
  sort : 'sort',    // The parameter name which specifies the column to sort on
  dir : 'dir'       // The parameter name which specifies the sort direction
  }
  </code></pre>
   * <p>The server must produce the requested data block upon receipt of these parameter names.
   * If different parameter names are required, this property can be overriden using a configuration
   * property.</p>
   * <p>A {@link Ext.PagingToolbar PagingToolbar} bound to this Store uses this property to determine
   * the parameter names to use in its {@link #load requests}.
   */
  paramNames: undefined,

  /**
   * @cfg {Object} defaultParamNames
   * Provides the default values for the {@link #paramNames} property. To globally modify the parameters
   * for all stores, this object should be changed on the store prototype.
   */
  defaultParamNames: {
    start: 'start',
    limit: 'limit',
    sort: 'sort',
    dir: 'dir'
  },
  // private
  batchKey: '_ext_batch_',
  constructor: function constructor(config) {
    this.data = new Ext.util.MixedCollection(false);

    this.data.getKey = function (o) {
      return o.id;
    }; // temporary removed-records cache


    this.removed = [];

    if (config && config.data) {
      this.inlineData = config.data;
      delete config.data;
    }

    Ext.apply(this, config);
    /**
     * See the <code>{@link #baseParams corresponding configuration option}</code>
     * for a description of this property.
     * To modify this property see <code>{@link #setBaseParam}</code>.
     * @property
     */

    this.baseParams = Ext.isObject(this.baseParams) ? this.baseParams : {};
    this.paramNames = Ext.applyIf(this.paramNames || {}, this.defaultParamNames);

    if ((this.url || this.api) && !this.proxy) {
      this.proxy = new Ext.data.HttpProxy({
        url: this.url,
        api: this.api
      });
    } // If Store is RESTful, so too is the DataProxy


    if (this.restful === true && this.proxy) {
      // When operating RESTfully, a unique transaction is generated for each record.
      // TODO might want to allow implemention of faux REST where batch is possible using RESTful routes only.
      this.batch = false;
      Ext.data.Api.restify(this.proxy);
    }

    if (this.reader) {
      // reader passed
      if (!this.recordType) {
        this.recordType = this.reader.recordType;
      }

      if (this.reader.onMetaChange) {
        this.reader.onMetaChange = this.reader.onMetaChange.createSequence(this.onMetaChange, this);
      }

      if (this.writer) {
        // writer passed
        if (this.writer instanceof Ext.data.DataWriter === false) {
          // <-- config-object instead of instance.
          this.writer = this.buildWriter(this.writer);
        }

        this.writer.meta = this.reader.meta;
        this.pruneModifiedRecords = true;
      }
    }
    /**
     * The {@link Ext.data.Record Record} constructor as supplied to (or created by) the
     * {@link Ext.data.DataReader Reader}. Read-only.
     * <p>If the Reader was constructed by passing in an Array of {@link Ext.data.Field} definition objects,
     * instead of a Record constructor, it will implicitly create a Record constructor from that Array (see
     * {@link Ext.data.Record}.{@link Ext.data.Record#create create} for additional details).</p>
     * <p>This property may be used to create new Records of the type held in this Store, for example:</p><pre><code>
    // create the data store
    var store = new Ext.data.ArrayStore({
    autoDestroy: true,
    fields: [
       {name: 'company'},
       {name: 'price', type: 'float'},
       {name: 'change', type: 'float'},
       {name: 'pctChange', type: 'float'},
       {name: 'lastChange', type: 'date', dateFormat: 'n/j h:ia'}
    ]
    });
    store.loadData(myData);
    // create the Grid
    var grid = new Ext.grid.EditorGridPanel({
    store: store,
    colModel: new Ext.grid.ColumnModel({
        columns: [
            {id:'company', header: 'Company', width: 160, dataIndex: 'company'},
            {header: 'Price', renderer: 'usMoney', dataIndex: 'price'},
            {header: 'Change', renderer: change, dataIndex: 'change'},
            {header: '% Change', renderer: pctChange, dataIndex: 'pctChange'},
            {header: 'Last Updated', width: 85,
                renderer: Ext.util.Format.dateRenderer('m/d/Y'),
                dataIndex: 'lastChange'}
        ],
        defaults: {
            sortable: true,
            width: 75
        }
    }),
    autoExpandColumn: 'company', // match the id specified in the column model
    height:350,
    width:600,
    title:'Array Grid',
    tbar: [{
        text: 'Add Record',
        handler : function(){
            var defaultData = {
                change: 0,
                company: 'New Company',
                lastChange: (new Date()).clearTime(),
                pctChange: 0,
                price: 10
            };
            var recId = 3; // provide unique id
            var p = new store.recordType(defaultData, recId); // create new record
            grid.stopEditing();
            store.{@link #insert}(0, p); // insert a new record into the store (also see {@link #add})
            grid.startEditing(0, 0);
        }
    }]
    });
     * </code></pre>
     * @property recordType
     * @type Function
     */


    if (this.recordType) {
      /**
       * A {@link Ext.util.MixedCollection MixedCollection} containing the defined {@link Ext.data.Field Field}s
       * for the {@link Ext.data.Record Records} stored in this Store. Read-only.
       * @property fields
       * @type Ext.util.MixedCollection
       */
      this.fields = this.recordType.prototype.fields;
    }

    this.modified = [];
    this.addEvents(
    /**
     * @event datachanged
     * Fires when the data cache has changed in a bulk manner (e.g., it has been sorted, filtered, etc.) and a
     * widget that is using this Store as a Record cache should refresh its view.
     * @param {Store} this
     */
    'datachanged',
    /**
     * @event metachange
     * Fires when this store's reader provides new metadata (fields). This is currently only supported for JsonReaders.
     * @param {Store} this
     * @param {Object} meta The JSON metadata
     */
    'metachange',
    /**
     * @event add
     * Fires when Records have been {@link #add}ed to the Store
     * @param {Store} this
     * @param {Ext.data.Record[]} records The array of Records added
     * @param {Number} index The index at which the record(s) were added
     */
    'add',
    /**
     * @event remove
     * Fires when a Record has been {@link #remove}d from the Store
     * @param {Store} this
     * @param {Ext.data.Record} record The Record that was removed
     * @param {Number} index The index at which the record was removed
     */
    'remove',
    /**
     * @event update
     * Fires when a Record has been updated
     * @param {Store} this
     * @param {Ext.data.Record} record The Record that was updated
     * @param {String} operation The update operation being performed.  Value may be one of:
     * <pre><code>
    Ext.data.Record.EDIT
    Ext.data.Record.REJECT
    Ext.data.Record.COMMIT
     * </code></pre>
     */
    'update',
    /**
     * @event clear
     * Fires when the data cache has been cleared.
     * @param {Store} this
     * @param {Record[]} The records that were cleared.
     */
    'clear',
    /**
     * @event exception
     * <p>Fires if an exception occurs in the Proxy during a remote request.
     * This event is relayed through the corresponding {@link Ext.data.DataProxy}.
     * See {@link Ext.data.DataProxy}.{@link Ext.data.DataProxy#exception exception}
     * for additional details.
     * @param {misc} misc See {@link Ext.data.DataProxy}.{@link Ext.data.DataProxy#exception exception}
     * for description.
     */
    'exception',
    /**
     * @event beforeload
     * Fires before a request is made for a new data object.  If the beforeload handler returns
     * <tt>false</tt> the {@link #load} action will be canceled.
     * @param {Store} this
     * @param {Object} options The loading options that were specified (see {@link #load} for details)
     */
    'beforeload',
    /**
     * @event load
     * Fires after a new set of Records has been loaded.
     * @param {Store} this
     * @param {Ext.data.Record[]} records The Records that were loaded
     * @param {Object} options The loading options that were specified (see {@link #load} for details)
     */
    'load',
    /**
     * @event loadexception
     * <p>This event is <b>deprecated</b> in favor of the catch-all <b><code>{@link #exception}</code></b>
     * event instead.</p>
     * <p>This event is relayed through the corresponding {@link Ext.data.DataProxy}.
     * See {@link Ext.data.DataProxy}.{@link Ext.data.DataProxy#loadexception loadexception}
     * for additional details.
     * @param {misc} misc See {@link Ext.data.DataProxy}.{@link Ext.data.DataProxy#loadexception loadexception}
     * for description.
     */
    'loadexception',
    /**
     * @event beforewrite
     * @param {Ext.data.Store} store
     * @param {String} action [Ext.data.Api.actions.create|update|destroy]
     * @param {Record/Array[Record]} rs
     * @param {Object} options The loading options that were specified. Edit <code>options.params</code> to add Http parameters to the request.  (see {@link #save} for details)
     * @param {Object} arg The callback's arg object passed to the {@link #request} function
     */
    'beforewrite',
    /**
     * @event write
     * Fires if the server returns 200 after an Ext.data.Api.actions CRUD action.
     * Success of the action is determined in the <code>result['successProperty']</code>property (<b>NOTE</b> for RESTful stores,
     * a simple 20x response is sufficient for the actions "destroy" and "update".  The "create" action should should return 200 along with a database pk).
     * @param {Ext.data.Store} store
     * @param {String} action [Ext.data.Api.actions.create|update|destroy]
     * @param {Object} result The 'data' picked-out out of the response for convenience.
     * @param {Ext.Direct.Transaction} res
     * @param {Record/Record[]} rs Store's records, the subject(s) of the write-action
     */
    'write',
    /**
     * @event beforesave
     * Fires before a save action is called. A save encompasses destroying records, updating records and creating records.
     * @param {Ext.data.Store} store
     * @param {Object} data An object containing the data that is to be saved. The object will contain a key for each appropriate action,
     * with an array of records for each action.
     */
    'beforesave',
    /**
     * @event save
     * Fires after a save is completed. A save encompasses destroying records, updating records and creating records.
     * @param {Ext.data.Store} store
     * @param {Number} batch The identifier for the batch that was saved.
     * @param {Object} data An object containing the data that is to be saved. The object will contain a key for each appropriate action,
     * with an array of records for each action.
     */
    'save');

    if (this.proxy) {
      // TODO remove deprecated loadexception with ext-3.0.1
      this.relayEvents(this.proxy, ['loadexception', 'exception']);
    } // With a writer set for the Store, we want to listen to add/remove events to remotely create/destroy records.


    if (this.writer) {
      this.on({
        scope: this,
        add: this.createRecords,
        remove: this.destroyRecord,
        update: this.updateRecord,
        clear: this.onClear
      });
    }

    this.sortToggle = {};

    if (this.sortField) {
      this.setDefaultSort(this.sortField, this.sortDir);
    } else if (this.sortInfo) {
      this.setDefaultSort(this.sortInfo.field, this.sortInfo.direction);
    }

    Ext.data.Store.superclass.constructor.call(this);

    if (this.id) {
      this.storeId = this.id;
      delete this.id;
    }

    if (this.storeId) {
      Ext.StoreMgr.register(this);
    }

    if (this.inlineData) {
      this.loadData(this.inlineData);
      delete this.inlineData;
    } else if (this.autoLoad) {
      this.load.defer(10, this, [typeof this.autoLoad == 'object' ? this.autoLoad : undefined]);
    } // used internally to uniquely identify a batch


    this.batchCounter = 0;
    this.batches = {};
  },

  /**
   * builds a DataWriter instance when Store constructor is provided with a writer config-object instead of an instace.
   * @param {Object} config Writer configuration
   * @return {Ext.data.DataWriter}
   * @private
   */
  buildWriter: function buildWriter(config) {
    var klass = undefined,
        type = (config.format || 'json').toLowerCase();

    switch (type) {
      case 'json':
        klass = Ext.data.JsonWriter;
        break;

      case 'xml':
        klass = Ext.data.XmlWriter;
        break;

      default:
        klass = Ext.data.JsonWriter;
    }

    return new klass(config);
  },

  /**
   * Destroys the store.
   */
  destroy: function destroy() {
    if (!this.isDestroyed) {
      if (this.storeId) {
        Ext.StoreMgr.unregister(this);
      }

      this.clearData();
      this.data = null;
      Ext.destroy(this.proxy);
      this.reader = this.writer = null;
      this.purgeListeners();
      this.isDestroyed = true;
    }
  },

  /**
   * Add Records to the Store and fires the {@link #add} event.  To add Records
   * to the store from a remote source use <code>{@link #load}({add:true})</code>.
   * See also <code>{@link #recordType}</code> and <code>{@link #insert}</code>.
   * @param {Ext.data.Record[]} records An Array of Ext.data.Record objects
   * to add to the cache. See {@link #recordType}.
   */
  add: function add(records) {
    records = [].concat(records);

    if (records.length < 1) {
      return;
    }

    for (var i = 0, len = records.length; i < len; i++) {
      records[i].join(this);
    }

    var index = this.data.length;
    this.data.addAll(records);

    if (this.snapshot) {
      this.snapshot.addAll(records);
    }

    this.fireEvent('add', this, records, index);
  },

  /**
   * (Local sort only) Inserts the passed Record into the Store at the index where it
   * should go based on the current sort information.
   * @param {Ext.data.Record} record
   */
  addSorted: function addSorted(record) {
    const remoteSort = this.remoteSort;
    this.remoteSort = false;
    var index = this.findInsertIndex(record);
    this.remoteSort = remoteSort;
    this.insert(index, record);
  },

  /**
   * appends (number) to property to ensure uniqness
   *
   * @param {Ext.data.Record} record
   * @param {String} prop property name or property path
   */
  addUnique: function addUnique(record, prop) {
    prop = prop.match(/^data\./) ? prop : "data.".concat(prop);
    let [, name, idx, ext] = String(_.get(record, prop)).match(/(.*?)(?:\s\((\d+)\))?(\..*)/) || [null, _.get(record, prop)];

    while (_.find(this.data.items, item => {
      return _.get(item, prop) === _.get(record, prop);
    })) {
      idx = idx || 0;

      _.set(record, prop, "".concat(name, " (").concat(++idx, ")").concat(ext || ''));
    }

    this.addSorted(record);
  },

  /**
   * Remove Records from the Store and fires the {@link #remove} event.
   * @param {Ext.data.Record/Ext.data.Record[]} record The record object or array of records to remove from the cache.
   */
  remove: function remove(record) {
    if (Ext.isArray(record)) {
      Ext.each(record, function (r) {
        this.remove(r);
      }, this);
    }

    var index = this.data.indexOf(record);

    if (index > -1) {
      record.join(null);
      this.data.removeAt(index);
    }

    if (this.pruneModifiedRecords) {
      this.modified.remove(record);
    }

    if (this.snapshot) {
      this.snapshot.remove(record);
    }

    if (index > -1) {
      this.fireEvent('remove', this, record, index);
    }
  },

  /**
   * Remove a Record from the Store at the specified index. Fires the {@link #remove} event.
   * @param {Number} index The index of the record to remove.
   */
  removeAt: function removeAt(index) {
    this.remove(this.getAt(index));
  },

  /**
   * Remove all Records from the Store and fires the {@link #clear} event.
   * @param {Boolean} silent [false] Defaults to <tt>false</tt>.  Set <tt>true</tt> to not fire clear event.
   */
  removeAll: function removeAll(silent) {
    var items = [];
    this.each(function (rec) {
      items.push(rec);
    });
    this.clearData();

    if (this.snapshot) {
      this.snapshot.clear();
    }

    if (this.pruneModifiedRecords) {
      this.modified = [];
    }

    if (silent !== true) {
      // <-- prevents write-actions when we just want to clear a store.
      this.fireEvent('clear', this, items);
    }
  },
  // private
  onClear: function onClear(store, records) {
    Ext.each(records, function (rec, index) {
      this.destroyRecord(this, rec, index);
    }, this);
  },

  /**
   * Inserts Records into the Store at the given index and fires the {@link #add} event.
   * See also <code>{@link #add}</code> and <code>{@link #addSorted}</code>.
   * @param {Number} index The start index at which to insert the passed Records.
   * @param {Ext.data.Record[]} records An Array of Ext.data.Record objects to add to the cache.
   */
  insert: function insert(index, records) {
    records = [].concat(records);

    for (var i = 0, len = records.length; i < len; i++) {
      this.data.insert(index, records[i]);
      records[i].join(this);
    }

    if (this.snapshot) {
      this.snapshot.addAll(records);
    }

    this.fireEvent('add', this, records, index);
  },

  /**
   * Get the index within the cache of the passed Record.
   * @param {Ext.data.Record} record The Ext.data.Record object to find.
   * @return {Number} The index of the passed Record. Returns -1 if not found.
   */
  indexOf: function indexOf(record) {
    return this.data.indexOf(record);
  },

  /**
   * Get the index within the cache of the Record with the passed id.
   * @param {String} id The id of the Record to find.
   * @return {Number} The index of the Record. Returns -1 if not found.
   */
  indexOfId: function indexOfId(id) {
    return this.data.indexOfKey(String(id));
  },

  /**
   * Get the Record with the specified id.
   * @param {String} id The id of the Record to find.
   * @return {Ext.data.Record} The Record with the passed id. Returns undefined if not found.
   */
  getById: function getById(id) {
    return (this.snapshot || this.data).key(id);
  },

  /**
   * Get the Record at the specified index.
   * @param {Number} index The index of the Record to find.
   * @return {Ext.data.Record} The Record at the passed index. Returns undefined if not found.
   */
  getAt: function getAt(index) {
    return this.data.itemAt(index);
  },

  /**
   * Returns a range of Records between specified indices.
   * @param {Number} startIndex (optional) The starting index (defaults to 0)
   * @param {Number} endIndex (optional) The ending index (defaults to the last Record in the Store)
   * @return {Ext.data.Record[]} An array of Records
   */
  getRange: function getRange(start, end) {
    return this.data.getRange(start, end);
  },
  // private
  storeOptions: function storeOptions(o) {
    o = Ext.apply({}, o);
    delete o.callback;
    delete o.scope;
    this.lastOptions = o;
  },
  // private
  clearData: function clearData() {
    this.data.each(function (rec) {
      rec.join(null);
    });
    this.data.clear();
  },

  /**
   * <p>Loads the Record cache from the configured <tt>{@link #proxy}</tt> using the configured <tt>{@link #reader}</tt>.</p>
   * <br><p>Notes:</p><div class="mdetail-params"><ul>
   * <li><b><u>Important</u></b>: loading is asynchronous! This call will return before the new data has been
   * loaded. To perform any post-processing where information from the load call is required, specify
   * the <tt>callback</tt> function to be called, or use a {@link Ext.util.Observable#listeners a 'load' event handler}.</li>
   * <li>If using {@link Ext.PagingToolbar remote paging}, the first load call must specify the <tt>start</tt> and <tt>limit</tt>
   * properties in the <code>options.params</code> property to establish the initial position within the
   * dataset, and the number of Records to cache on each read from the Proxy.</li>
   * <li>If using {@link #remoteSort remote sorting}, the configured <code>{@link #sortInfo}</code>
   * will be automatically included with the posted parameters according to the specified
   * <code>{@link #paramNames}</code>.</li>
   * </ul></div>
   * @param {Object} options An object containing properties which control loading options:<ul>
   * <li><b><tt>params</tt></b> :Object<div class="sub-desc"><p>An object containing properties to pass as HTTP
   * parameters to a remote data source. <b>Note</b>: <code>params</code> will override any
   * <code>{@link #baseParams}</code> of the same name.</p>
   * <p>Parameters are encoded as standard HTTP parameters using {@link Ext#urlEncode}.</p></div></li>
   * <li><b>callback</b> : Function<div class="sub-desc"><p>A function to be called after the Records
   * have been loaded. The callback is called after the load event is fired, and is passed the following arguments:<ul>
   * <li>r : Ext.data.Record[] An Array of Records loaded.</li>
   * <li>options : Options object from the load call.</li>
   * <li>success : Boolean success indicator.</li></ul></p></div></li>
   * <li><b>scope</b> : Object<div class="sub-desc"><p>Scope with which to call the callback (defaults
   * to the Store object)</p></div></li>
   * <li><b>add</b> : Boolean<div class="sub-desc"><p>Indicator to append loaded records rather than
   * replace the current cache.  <b>Note</b>: see note for <tt>{@link #loadData}</tt></p></div></li>
   * </ul>
   * @return {Boolean} If the <i>developer</i> provided <tt>{@link #beforeload}</tt> event handler returns
   * <tt>false</tt>, the load call will abort and will return <tt>false</tt>; otherwise will return <tt>true</tt>.
   */
  load: function load(options) {
    options = options || {};
    this.storeOptions(options);

    if (this.sortInfo && this.remoteSort) {
      var pn = this.paramNames;
      options.params = options.params || {};
      options.params[pn.sort] = this.sortInfo.field;
      options.params[pn.dir] = this.sortInfo.direction;
    }

    try {
      return this.execute('read', null, options); // <-- null represents rs.  No rs for load actions.
    } catch (e) {
      this.handleException(e);
      return false;
    }
  },

  /**
   * promisified store load
   */
  promiseLoad: function promiseLoad(options) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      try {
        me.load(Ext.apply(options || {}, {
          callback: function callback(r, options, success) {
            if (success) {
              fulfill(r, options);
            } else if (Ext.isFunction(reject)) {
              reject(new Error(options));
            }
          }
        }));
      } catch (error) {
        if (Ext.isFunction(reject)) {
          reject(new Error(options));
        }
      }
    });
  },
  nextLoad: function nextLoad() {
    var me = this;
    return new Promise(function (resolve) {
      me.on('load', resolve, me, {
        single: true
      });
    });
  },

  /**
   * updateRecord  Should not be used directly.  This method will be called automatically if a Writer is set.
   * Listens to 'update' event.
   * @param {Object} store
   * @param {Object} record
   * @param {Object} action
   * @private
   */
  updateRecord: function updateRecord(store, record, action) {
    if (action == Ext.data.Record.EDIT && this.autoSave === true && (!record.phantom || record.phantom && record.isValid())) {
      this.save();
    }
  },

  /**
   * Should not be used directly.  Store#add will call this automatically if a Writer is set
   * @param {Object} store
   * @param {Object} rs
   * @param {Object} index
   * @private
   */
  createRecords: function createRecords(store, rs, index) {
    for (var i = 0, len = rs.length; i < len; i++) {
      if (rs[i].phantom && rs[i].isValid()) {
        rs[i].markDirty(); // <-- Mark new records dirty

        this.modified.push(rs[i]); // <-- add to modified
      }
    }

    if (this.autoSave === true) {
      this.save();
    }
  },

  /**
   * Destroys a record or records.  Should not be used directly.  It's called by Store#remove if a Writer is set.
   * @param {Store} this
   * @param {Ext.data.Record/Ext.data.Record[]}
   * @param {Number} index
   * @private
   */
  destroyRecord: function destroyRecord(store, record, index) {
    if (this.modified.indexOf(record) != -1) {
      // <-- handled already if @cfg pruneModifiedRecords == true
      this.modified.remove(record);
    }

    if (!record.phantom) {
      this.removed.push(record); // since the record has already been removed from the store but the server request has not yet been executed,
      // must keep track of the last known index this record existed.  If a server error occurs, the record can be
      // put back into the store.  @see Store#createCallback where the record is returned when response status === false

      record.lastIndex = index;

      if (this.autoSave === true) {
        this.save();
      }
    }
  },

  /**
   * This method should generally not be used directly.  This method is called internally
   * by {@link #load}, or if a Writer is set will be called automatically when {@link #add},
   * {@link #remove}, or {@link #update} events fire.
   * @param {String} action Action name ('read', 'create', 'update', or 'destroy')
   * @param {Record/Record[]} rs
   * @param {Object} options
   * @throws Error
   * @private
   */
  execute: function execute(action, rs, options,
  /* private */
  batch) {
    // blow up if action not Ext.data.CREATE, READ, UPDATE, DESTROY
    if (!Ext.data.Api.isAction(action)) {
      throw new Ext.data.Api.Error('execute', action);
    } // make sure options has a fresh, new params hash


    options = Ext.applyIf(options || {}, {
      params: {}
    });

    if (batch !== undefined) {
      this.addToBatch(batch);
    } // have to separate before-events since load has a different signature than create,destroy and save events since load does not
    // include the rs (record resultset) parameter.  Capture return values from the beforeaction into doRequest flag.


    var doRequest = true;

    if (action === 'read') {
      doRequest = this.fireEvent('beforeload', this, options);
      Ext.applyIf(options.params, this.baseParams);
    } else {
      // if Writer is configured as listful, force single-record rs to be [{}] instead of {}
      // TODO Move listful rendering into DataWriter where the @cfg is defined.  Should be easy now.
      if (this.writer.listful === true && this.restful !== true) {
        rs = Ext.isArray(rs) ? rs : [rs];
      } // if rs has just a single record, shift it off so that Writer writes data as '{}' rather than '[{}]'
      else if (Ext.isArray(rs) && rs.length == 1) {
          rs = rs.shift();
        } // Write the action to options.params


      if ((doRequest = this.fireEvent('beforewrite', this, action, rs, options)) !== false) {
        this.writer.apply(options.params, this.baseParams, action, rs);
      }
    }

    if (doRequest !== false) {
      // Send request to proxy.
      if (this.writer && this.proxy.url && !this.proxy.restful && !Ext.data.Api.hasUniqueUrl(this.proxy, action)) {
        options.params.xaction = action; // <-- really old, probaby unecessary.
      } // Note:  Up until this point we've been dealing with 'action' as a key from Ext.data.Api.actions.
      // We'll flip it now and send the value into DataProxy#request, since it's the value which maps to
      // the user's configured DataProxy#api
      // TODO Refactor all Proxies to accept an instance of Ext.data.Request (not yet defined) instead of this looooooong list
      // of params.  This method is an artifact from Ext2.


      this.proxy.request(Ext.data.Api.actions[action], rs, options.params, this.reader, this.createCallback(action, rs, batch), this, options);
    }

    return doRequest;
  },

  /**
   * Saves all pending changes to the store.  If the commensurate Ext.data.Api.actions action is not configured, then
   * the configured <code>{@link #url}</code> will be used.
   * <pre>
   * change            url
   * ---------------   --------------------
   * removed records   Ext.data.Api.actions.destroy
   * phantom records   Ext.data.Api.actions.create
   * {@link #getModifiedRecords modified records}  Ext.data.Api.actions.update
   * </pre>
   * @TODO:  Create extensions of Error class and send associated Record with thrown exceptions.
   * e.g.:  Ext.data.DataReader.Error or Ext.data.Error or Ext.data.DataProxy.Error, etc.
   * @return {Number} batch Returns a number to uniquely identify the "batch" of saves occurring. -1 will be returned
   * if there are no items to save or the save was cancelled.
   */
  save: function save() {
    if (!this.writer) {
      throw new Ext.data.Store.Error('writer-undefined');
    }

    var queue = [],
        len,
        trans,
        batch,
        data = {}; // DESTROY:  First check for removed records.  Records in this.removed are guaranteed non-phantoms.  @see Store#remove

    if (this.removed.length) {
      queue.push(['destroy', this.removed]);
    } // Check for modified records. Use a copy so Store#rejectChanges will work if server returns error.


    var rs = [].concat(this.getModifiedRecords());

    if (rs.length) {
      // CREATE:  Next check for phantoms within rs.  splice-off and execute create.
      var phantoms = [];

      for (var i = rs.length - 1; i >= 0; i--) {
        if (rs[i].phantom === true) {
          var rec = rs.splice(i, 1).shift();

          if (rec.isValid()) {
            phantoms.push(rec);
          }
        } else if (!rs[i].isValid()) {
          // <-- while we're here, splice-off any !isValid real records
          rs.splice(i, 1);
        }
      } // If we have valid phantoms, create them...


      if (phantoms.length) {
        queue.push(['create', phantoms]);
      } // UPDATE:  And finally, if we're still here after splicing-off phantoms and !isValid real records, update the rest...


      if (rs.length) {
        queue.push(['update', rs]);
      }
    }

    len = queue.length;

    if (len) {
      batch = ++this.batchCounter;

      for (var i = 0; i < len; ++i) {
        trans = queue[i];
        data[trans[0]] = trans[1];
      }

      if (this.fireEvent('beforesave', this, data) !== false) {
        for (var i = 0; i < len; ++i) {
          trans = queue[i];
          this.doTransaction(trans[0], trans[1], batch);
        }

        return batch;
      }
    }

    return -1;
  },
  // private.  Simply wraps call to Store#execute in try/catch.  Defers to Store#handleException on error.  Loops if batch: false
  doTransaction: function doTransaction(action, rs, batch) {
    function transaction(records) {
      try {
        this.execute(action, records, undefined, batch);
      } catch (e) {
        this.handleException(e);
      }
    }

    if (this.batch === false) {
      for (var i = 0, len = rs.length; i < len; i++) {
        transaction.call(this, rs[i]);
      }
    } else {
      transaction.call(this, rs);
    }
  },
  // private
  addToBatch: function addToBatch(batch) {
    var b = this.batches,
        key = this.batchKey + batch,
        o = b[key];

    if (!o) {
      b[key] = o = {
        id: batch,
        count: 0,
        data: {}
      };
    }

    ++o.count;
  },
  removeFromBatch: function removeFromBatch(batch, action, data) {
    var b = this.batches,
        key = this.batchKey + batch,
        o = b[key],
        data,
        arr;

    if (o) {
      arr = o.data[action] || [];
      o.data[action] = arr.concat(data);

      if (o.count === 1) {
        data = o.data;
        delete b[key];
        this.fireEvent('save', this, batch, data);
      } else {
        --o.count;
      }
    }
  },
  // @private callback-handler for remote CRUD actions
  // Do not override -- override loadRecords, onCreateRecords, onDestroyRecords and onUpdateRecords instead.
  createCallback: function createCallback(action, rs, batch) {
    var actions = Ext.data.Api.actions;
    return action == 'read' ? this.loadRecords : function (data, response, success) {
      // calls: onCreateRecords | onUpdateRecords | onDestroyRecords
      this['on' + Ext.util.Format.capitalize(action) + 'Records'](success, rs, [].concat(data)); // If success === false here, exception will have been called in DataProxy

      if (success === true) {
        this.fireEvent('write', this, action, data, response, rs);
      }

      this.removeFromBatch(batch, action, data);
    };
  },
  // Clears records from modified array after an exception event.
  // NOTE:  records are left marked dirty.  Do we want to commit them even though they were not updated/realized?
  // TODO remove this method?
  clearModified: function clearModified(rs) {
    if (Ext.isArray(rs)) {
      for (var n = rs.length - 1; n >= 0; n--) {
        this.modified.splice(this.modified.indexOf(rs[n]), 1);
      }
    } else {
      this.modified.splice(this.modified.indexOf(rs), 1);
    }
  },
  // remap record ids in MixedCollection after records have been realized.  @see Store#onCreateRecords, @see DataReader#realize
  reMap: function reMap(record) {
    if (Ext.isArray(record)) {
      for (var i = 0, len = record.length; i < len; i++) {
        this.reMap(record[i]);
      }
    } else {
      delete this.data.map[record._phid];
      this.data.map[record.id] = record;
      var index = this.data.keys.indexOf(record._phid);
      this.data.keys.splice(index, 1, record.id);
      delete record._phid;
    }
  },
  // @protected onCreateRecord proxy callback for create action
  onCreateRecords: function onCreateRecords(success, rs, data) {
    if (success === true) {
      try {
        this.reader.realize(rs, data);
        this.reMap(rs);
      } catch (e) {
        this.handleException(e);

        if (Ext.isArray(rs)) {
          // Recurse to run back into the try {}.  DataReader#realize splices-off the rs until empty.
          this.onCreateRecords(success, rs, data);
        }
      }
    }
  },
  // @protected, onUpdateRecords proxy callback for update action
  onUpdateRecords: function onUpdateRecords(success, rs, data) {
    if (success === true) {
      try {
        this.reader.update(rs, data);
      } catch (e) {
        this.handleException(e);

        if (Ext.isArray(rs)) {
          // Recurse to run back into the try {}.  DataReader#update splices-off the rs until empty.
          this.onUpdateRecords(success, rs, data);
        }
      }
    }
  },
  // @protected onDestroyRecords proxy callback for destroy action
  onDestroyRecords: function onDestroyRecords(success, rs, data) {
    // splice each rec out of this.removed
    rs = rs instanceof Ext.data.Record ? [rs] : [].concat(rs);

    for (var i = 0, len = rs.length; i < len; i++) {
      this.removed.splice(this.removed.indexOf(rs[i]), 1);
    }

    if (success === false) {
      // put records back into store if remote destroy fails.
      // @TODO: Might want to let developer decide.
      for (i = rs.length - 1; i >= 0; i--) {
        this.insert(rs[i].lastIndex, rs[i]); // <-- lastIndex set in Store#destroyRecord
      }
    }
  },
  // protected handleException.  Possibly temporary until Ext framework has an exception-handler.
  handleException: function handleException(e) {
    // @see core/Error.js
    Ext.handleError(e);
  },

  /**
   * <p>Reloads the Record cache from the configured Proxy using the configured
   * {@link Ext.data.Reader Reader} and the options from the last load operation
   * performed.</p>
   * <p><b>Note</b>: see the Important note in {@link #load}.</p>
   * @param {Object} options <p>(optional) An <tt>Object</tt> containing
   * {@link #load loading options} which may override the {@link #lastOptions options}
   * used in the last {@link #load} operation. See {@link #load} for details
   * (defaults to <tt>null</tt>, in which case the {@link #lastOptions} are
   * used).</p>
   * <br><p>To add new params to the existing params:</p><pre><code>
  lastOptions = myStore.lastOptions;
  Ext.apply(lastOptions.params, {
  myNewParam: true
  });
  myStore.reload(lastOptions);
   * </code></pre>
   */
  reload: function reload(options) {
    this.load(Ext.applyIf(options || {}, this.lastOptions));
  },
  // private
  // Called as a callback by the Reader during a load operation.
  loadRecords: function loadRecords(o, options, success) {
    if (this.isDestroyed === true) {
      return;
    }

    if (!o || success === false) {
      if (success !== false) {
        this.fireEvent('load', this, [], options);
      }

      if (options.callback) {
        options.callback.call(options.scope || this, [], options, false, o);
      }

      return;
    }

    var r = o.records,
        t = o.totalRecords || r.length;

    if (!options || options.add !== true) {
      if (this.pruneModifiedRecords) {
        this.modified = [];
      }

      for (var i = 0, len = r.length; i < len; i++) {
        r[i].join(this);
      }

      if (this.snapshot) {
        this.data = this.snapshot;
        delete this.snapshot;
      }

      this.clearData();
      this.data.addAll(r);
      this.totalLength = t;
      this.applySort();
      this.fireEvent('datachanged', this);
    } else {
      this.totalLength = Math.max(t, this.data.length + r.length);
      this.add(r);
    }

    this.fireEvent('load', this, r, options);

    if (options.callback) {
      options.callback.call(options.scope || this, r, options, true);
    }
  },

  /**
   * Loads data from a passed data block and fires the {@link #load} event. A {@link Ext.data.Reader Reader}
   * which understands the format of the data must have been configured in the constructor.
   * @param {Object} data The data block from which to read the Records.  The format of the data expected
   * is dependent on the type of {@link Ext.data.Reader Reader} that is configured and should correspond to
   * that {@link Ext.data.Reader Reader}'s <tt>{@link Ext.data.Reader#readRecords}</tt> parameter.
   * @param {Boolean} append (Optional) <tt>true</tt> to append the new Records rather the default to replace
   * the existing cache.
   * <b>Note</b>: that Records in a Store are keyed by their {@link Ext.data.Record#id id}, so added Records
   * with ids which are already present in the Store will <i>replace</i> existing Records. Only Records with
   * new, unique ids will be added.
   */
  loadData: function loadData(o, append) {
    var r = this.reader.readRecords(o);
    this.loadRecords(r, {
      add: append
    }, true);
  },

  /**
   * Gets the number of cached records.
   * <p>If using paging, this may not be the total size of the dataset. If the data object
   * used by the Reader contains the dataset size, then the {@link #getTotalCount} function returns
   * the dataset size.  <b>Note</b>: see the Important note in {@link #load}.</p>
   * @return {Number} The number of Records in the Store's cache.
   */
  getCount: function getCount() {
    return this.data.length || 0;
  },

  /**
   * Gets the total number of records in the dataset as returned by the server.
   * <p>If using paging, for this to be accurate, the data object used by the {@link #reader Reader}
   * must contain the dataset size. For remote data sources, the value for this property
   * (<tt>totalProperty</tt> for {@link Ext.data.JsonReader JsonReader},
   * <tt>totalRecords</tt> for {@link Ext.data.XmlReader XmlReader}) shall be returned by a query on the server.
   * <b>Note</b>: see the Important note in {@link #load}.</p>
   * @return {Number} The number of Records as specified in the data object passed to the Reader
   * by the Proxy.
   * <p><b>Note</b>: this value is not updated when changing the contents of the Store locally.</p>
   */
  getTotalCount: function getTotalCount() {
    return this.totalLength || 0;
  },

  /**
   * Returns an object describing the current sort state of this Store.
   * @return {Object} The sort state of the Store. An object with two properties:<ul>
   * <li><b>field : String<p class="sub-desc">The name of the field by which the Records are sorted.</p></li>
   * <li><b>direction : String<p class="sub-desc">The sort order, 'ASC' or 'DESC' (case-sensitive).</p></li>
   * </ul>
   * See <tt>{@link #sortInfo}</tt> for additional details.
   */
  getSortState: function getSortState() {
    return this.sortInfo;
  },
  // private
  applySort: function applySort() {
    if (this.sortInfo && !this.remoteSort) {
      var s = this.sortInfo,
          f = s.field;
      this.sortData(f, s.direction);
    }
  },
  // private
  sortData: function sortData(f, direction) {
    direction = direction || 'ASC';
    var st = this.fields.get(f).sortType;
    var locale = Tine.Tinebase.registry.get('locale').locale;
    var fn = st !== Ext.data.SortTypes.asUCString ? function (r1, r2) {
      var v1 = st(r1.data[f]),
          v2 = st(r2.data[f]);
      return v1 > v2 ? 1 : v1 < v2 ? -1 : 0;
    } : function (r1, r2) {
      var v1 = st(r1.data[f]),
          v2 = st(r2.data[f]);
      return v1.localeCompare(v2, locale);
    };
    this.data.sort(direction, fn);

    if (this.snapshot && this.snapshot != this.data) {
      this.snapshot.sort(direction, fn);
    }
  },

  /**
   * Sets the default sort column and order to be used by the next {@link #load} operation.
   * @param {String} fieldName The name of the field to sort by.
   * @param {String} dir (optional) The sort order, 'ASC' or 'DESC' (case-sensitive, defaults to <tt>'ASC'</tt>)
   */
  setDefaultSort: function setDefaultSort(field, dir) {
    dir = dir ? dir.toUpperCase() : 'ASC';
    this.sortInfo = {
      field: field,
      direction: dir
    };
    this.sortToggle[field] = dir;
  },

  /**
   * Sort the Records.
   * If remote sorting is used, the sort is performed on the server, and the cache is reloaded. If local
   * sorting is used, the cache is sorted internally. See also {@link #remoteSort} and {@link #paramNames}.
   * @param {String} fieldName The name of the field to sort by.
   * @param {String} dir (optional) The sort order, 'ASC' or 'DESC' (case-sensitive, defaults to <tt>'ASC'</tt>)
   */
  sort: function sort(fieldName, dir) {
    var f = this.fields.get(fieldName);

    if (!f) {
      return false;
    }

    if (!dir) {
      if (this.sortInfo && this.sortInfo.field == f.name) {
        // toggle sort dir
        dir = (this.sortToggle[f.name] || 'ASC').toggle('ASC', 'DESC');
      } else {
        dir = f.sortDir;
      }
    }

    var st = this.sortToggle ? this.sortToggle[f.name] : null;
    var si = this.sortInfo ? this.sortInfo : null;
    this.sortToggle[f.name] = dir;
    this.sortInfo = {
      field: f.name,
      direction: dir
    };

    if (!this.remoteSort) {
      this.applySort();
      this.fireEvent('datachanged', this);
    } else {
      if (!this.load(this.lastOptions)) {
        if (st) {
          this.sortToggle[f.name] = st;
        }

        if (si) {
          this.sortInfo = si;
        }
      }
    }
  },

  /**
   * Calls the specified function for each of the {@link Ext.data.Record Records} in the cache.
   * @param {Function} fn The function to call. The {@link Ext.data.Record Record} is passed as the first parameter.
   * Returning <tt>false</tt> aborts and exits the iteration.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed.
   * Defaults to the current {@link Ext.data.Record Record} in the iteration.
   */
  each: function each(fn, scope) {
    this.data.each(fn, scope);
  },

  /**
   * Gets all {@link Ext.data.Record records} modified since the last commit.  Modified records are
   * persisted across load operations (e.g., during paging). <b>Note</b>: deleted records are not
   * included.  See also <tt>{@link #pruneModifiedRecords}</tt> and
   * {@link Ext.data.Record}<tt>{@link Ext.data.Record#markDirty markDirty}.</tt>.
   * @return {Ext.data.Record[]} An array of {@link Ext.data.Record Records} containing outstanding
   * modifications.  To obtain modified fields within a modified record see
   *{@link Ext.data.Record}<tt>{@link Ext.data.Record#modified modified}.</tt>.
   */
  getModifiedRecords: function getModifiedRecords() {
    return this.modified;
  },
  // private
  createFilterFn: function createFilterFn(property, value, anyMatch, caseSensitive) {
    if (Ext.isEmpty(value, false)) {
      return false;
    }

    value = this.data.createValueMatcher(value, anyMatch, caseSensitive);
    return function (r) {
      return value.test(r.data[property]);
    };
  },

  /**
   * Sums the value of <tt>property</tt> for each {@link Ext.data.Record record} between <tt>start</tt>
   * and <tt>end</tt> and returns the result.
   * @param {String} property A field in each record
   * @param {Number} start (optional) The record index to start at (defaults to <tt>0</tt>)
   * @param {Number} end (optional) The last record index to include (defaults to length - 1)
   * @return {Number} The sum
   */
  sum: function sum(property, start, end) {
    var rs = this.data.items,
        v = 0;
    start = start || 0;
    end = end || end === 0 ? end : rs.length - 1;

    for (var i = start; i <= end; i++) {
      v += rs[i].data[property] || 0;
    }

    return v;
  },

  /**
   * Filter the {@link Ext.data.Record records} by a specified property.
   * @param {String} field A field on your records
   * @param {String/RegExp} value Either a string that the field should begin with, or a RegExp to test
   * against the field.
   * @param {Boolean} anyMatch (optional) <tt>true</tt> to match any part not just the beginning
   * @param {Boolean} caseSensitive (optional) <tt>true</tt> for case sensitive comparison
   */
  filter: function filter(property, value, anyMatch, caseSensitive) {
    var fn = this.createFilterFn(property, value, anyMatch, caseSensitive);
    return fn ? this.filterBy(fn) : this.clearFilter();
  },

  /**
   * Filter by a function. The specified function will be called for each
   * Record in this Store. If the function returns <tt>true</tt> the Record is included,
   * otherwise it is filtered out.
   * @param {Function} fn The function to be called. It will be passed the following parameters:<ul>
   * <li><b>record</b> : Ext.data.Record<p class="sub-desc">The {@link Ext.data.Record record}
   * to test for filtering. Access field values using {@link Ext.data.Record#get}.</p></li>
   * <li><b>id</b> : Object<p class="sub-desc">The ID of the Record passed.</p></li>
   * </ul>
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to this Store.
   */
  filterBy: function filterBy(fn, scope) {
    this.snapshot = this.snapshot || this.data;
    this.data = this.queryBy(fn, scope || this);
    this.fireEvent('datachanged', this);
  },

  /**
   * Query the records by a specified property.
   * @param {String} field A field on your records
   * @param {String/RegExp} value Either a string that the field
   * should begin with, or a RegExp to test against the field.
   * @param {Boolean} anyMatch (optional) True to match any part not just the beginning
   * @param {Boolean} caseSensitive (optional) True for case sensitive comparison
   * @return {MixedCollection} Returns an Ext.util.MixedCollection of the matched records
   */
  query: function query(property, value, anyMatch, caseSensitive) {
    var fn = this.createFilterFn(property, value, anyMatch, caseSensitive);
    return fn ? this.queryBy(fn) : this.data.clone();
  },

  /**
   * Query the cached records in this Store using a filtering function. The specified function
   * will be called with each record in this Store. If the function returns <tt>true</tt> the record is
   * included in the results.
   * @param {Function} fn The function to be called. It will be passed the following parameters:<ul>
   * <li><b>record</b> : Ext.data.Record<p class="sub-desc">The {@link Ext.data.Record record}
   * to test for filtering. Access field values using {@link Ext.data.Record#get}.</p></li>
   * <li><b>id</b> : Object<p class="sub-desc">The ID of the Record passed.</p></li>
   * </ul>
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to this Store.
   * @return {MixedCollection} Returns an Ext.util.MixedCollection of the matched records
   **/
  queryBy: function queryBy(fn, scope) {
    var data = this.snapshot || this.data;
    return data.filterBy(fn, scope || this);
  },

  /**
   * Finds the index of the first matching Record in this store by a specific field value.
   * @param {String} fieldName The name of the Record field to test.
   * @param {String/RegExp} value Either a string that the field value
   * should begin with, or a RegExp to test against the field.
   * @param {Number} startIndex (optional) The index to start searching at
   * @param {Boolean} anyMatch (optional) True to match any part of the string, not just the beginning
   * @param {Boolean} caseSensitive (optional) True for case sensitive comparison
   * @return {Number} The matched index or -1
   */
  find: function find(property, value, start, anyMatch, caseSensitive) {
    var fn = this.createFilterFn(property, value, anyMatch, caseSensitive);
    return fn ? this.data.findIndexBy(fn, null, start) : -1;
  },

  /**
   * Finds the index of the first matching Record in this store by a specific field value.
   * @param {String} fieldName The name of the Record field to test.
   * @param {Mixed} value The value to match the field against.
   * @param {Number} startIndex (optional) The index to start searching at
   * @return {Number} The matched index or -1
   */
  findExact: function findExact(property, value, start) {
    return this.data.findIndexBy(function (rec) {
      return rec.get(property) === value;
    }, this, start);
  },

  /**
   * Find the index of the first matching Record in this Store by a function.
   * If the function returns <tt>true</tt> it is considered a match.
   * @param {Function} fn The function to be called. It will be passed the following parameters:<ul>
   * <li><b>record</b> : Ext.data.Record<p class="sub-desc">The {@link Ext.data.Record record}
   * to test for filtering. Access field values using {@link Ext.data.Record#get}.</p></li>
   * <li><b>id</b> : Object<p class="sub-desc">The ID of the Record passed.</p></li>
   * </ul>
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to this Store.
   * @param {Number} startIndex (optional) The index to start searching at
   * @return {Number} The matched index or -1
   */
  findBy: function findBy(fn, scope, start) {
    return this.data.findIndexBy(fn, scope, start);
  },

  /**
   * Collects unique values for a particular dataIndex from this store.
   * @param {String} dataIndex The property to collect
   * @param {Boolean} allowNull (optional) Pass true to allow null, undefined or empty string values
   * @param {Boolean} bypassFilter (optional) Pass true to collect from all records, even ones which are filtered
   * @return {Array} An array of the unique values
   **/
  collect: function collect(dataIndex, allowNull, bypassFilter) {
    var d = bypassFilter === true && this.snapshot ? this.snapshot.items : this.data.items;
    var v,
        sv,
        r = [],
        l = {};

    for (var i = 0, len = d.length; i < len; i++) {
      v = d[i].data[dataIndex];
      sv = String(v);

      if ((allowNull || !Ext.isEmpty(v)) && !l[sv]) {
        l[sv] = true;
        r[r.length] = v;
      }
    }

    return r;
  },

  /**
   * Revert to a view of the Record cache with no filtering applied.
   * @param {Boolean} suppressEvent If <tt>true</tt> the filter is cleared silently without firing the
   * {@link #datachanged} event.
   */
  clearFilter: function clearFilter(suppressEvent) {
    if (this.isFiltered()) {
      this.data = this.snapshot;
      delete this.snapshot;

      if (suppressEvent !== true) {
        this.fireEvent('datachanged', this);
      }
    }
  },

  /**
   * Returns true if this store is currently filtered
   * @return {Boolean}
   */
  isFiltered: function isFiltered() {
    return this.snapshot && this.snapshot != this.data;
  },
  // private
  afterEdit: function afterEdit(record) {
    if (this.modified.indexOf(record) == -1) {
      this.modified.push(record);
    }

    this.fireEvent('update', this, record, Ext.data.Record.EDIT);
  },
  // private
  afterReject: function afterReject(record) {
    this.modified.remove(record);
    this.fireEvent('update', this, record, Ext.data.Record.REJECT);
  },
  // private
  afterCommit: function afterCommit(record) {
    this.modified.remove(record);
    this.fireEvent('update', this, record, Ext.data.Record.COMMIT);
  },

  /**
   * Commit all Records with {@link #getModifiedRecords outstanding changes}. To handle updates for changes,
   * subscribe to the Store's {@link #update update event}, and perform updating when the third parameter is
   * Ext.data.Record.COMMIT.
   */
  commitChanges: function commitChanges() {
    var m = this.modified.slice(0);
    this.modified = [];

    for (var i = 0, len = m.length; i < len; i++) {
      m[i].commit();
    }
  },

  /**
   * {@link Ext.data.Record#reject Reject} outstanding changes on all {@link #getModifiedRecords modified records}.
   */
  rejectChanges: function rejectChanges() {
    var m = this.modified.slice(0);
    this.modified = [];

    for (var i = 0, len = m.length; i < len; i++) {
      m[i].reject();
    }

    var m = this.removed.slice(0).reverse();
    this.removed = [];

    for (var i = 0, len = m.length; i < len; i++) {
      this.insert(m[i].lastIndex || 0, m[i]);
      m[i].reject();
    }
  },
  // private
  onMetaChange: function onMetaChange(meta) {
    this.recordType = this.reader.recordType;
    this.fields = this.recordType.prototype.fields;
    delete this.snapshot;

    if (this.reader.meta.sortInfo) {
      this.sortInfo = this.reader.meta.sortInfo;
    } else if (this.sortInfo && !this.fields.get(this.sortInfo.field)) {
      delete this.sortInfo;
    }

    if (this.writer) {
      this.writer.meta = this.reader.meta;
    }

    this.modified = [];
    this.fireEvent('metachange', this, this.reader.meta);
  },
  // private
  findInsertIndex: function findInsertIndex(record) {
    this.suspendEvents();
    var data = this.data.clone();
    this.data.add(record);
    this.applySort();
    var index = this.data.indexOf(record);
    this.data = data;
    this.resumeEvents();
    return index;
  },

  /**
   * Set the value for a property name in this store's {@link #baseParams}.  Usage:</p><pre><code>
  myStore.setBaseParam('foo', {bar:3});
  </code></pre>
   * @param {String} name Name of the property to assign
   * @param {Mixed} value Value to assign the <tt>name</tt>d property
   **/
  setBaseParam: function setBaseParam(name, value) {
    this.baseParams = this.baseParams || {};
    this.baseParams[name] = value;
  }
});
Ext.reg('store', Ext.data.Store);
/**
 * @class Ext.data.Store.Error
 * @extends Ext.Error
 * Store Error extension.
 * @param {String} name
 */

Ext.data.Store.Error = Ext.extend(Ext.Error, {
  name: 'Ext.data.Store'
});
Ext.apply(Ext.data.Store.Error.prototype, {
  lang: {
    'writer-undefined': 'Attempted to execute a write-action without a DataWriter installed.'
  }
});

/***/ }),
/* 795 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Field
 * <p>This class encapsulates the field definition information specified in the field definition objects
 * passed to {@link Ext.data.Record#create}.</p>
 * <p>Developers do not need to instantiate this class. Instances are created by {@link Ext.data.Record.create}
 * and cached in the {@link Ext.data.Record#fields fields} property of the created Record constructor's <b>prototype.</b></p>
 */
Ext.data.Field = function (config) {
  if (typeof config == "string") {
    config = {
      name: config
    };
  }

  Ext.apply(this, config);

  if (!this.type) {
    this.type = "auto";
  }

  var st = Ext.data.SortTypes; // named sortTypes are supported, here we look them up

  if (typeof this.sortType == "string") {
    this.sortType = st[this.sortType];
  } // set default sortType for strings and dates


  if (!this.sortType) {
    switch (this.type) {
      case "string":
        this.sortType = st.asUCString;
        break;

      case "date":
        this.sortType = st.asDate;
        break;

      default:
        this.sortType = st.none;
    }
  } // define once


  var stripRe = /[\$,%]/g; // prebuilt conversion function for this field, instead of
  // switching every time we're reading a value

  if (!this.convert) {
    var cv,
        dateFormat = this.dateFormat;

    switch (this.type) {
      case "":
      case "auto":
      case undefined:
        cv = function cv(v) {
          return v;
        };

        break;

      case "string":
        cv = function cv(v) {
          return v === undefined || v === null ? '' : String(v);
        };

        break;

      case "int":
        cv = function cv(v) {
          return v !== undefined && v !== null && v !== '' ? parseInt(String(v).replace(stripRe, ""), 10) : '';
        };

        break;

      case "float":
        cv = function cv(v) {
          return v !== undefined && v !== null && v !== '' ? parseFloat(String(v).replace(stripRe, ""), 10) : '';
        };

        break;

      case "bool":
        cv = function cv(v) {
          return v === true || v === "true" || v == 1;
        };

        break;

      case "date":
        cv = function cv(v) {
          if (!v) {
            return '';
          }

          if (Ext.isDate(v)) {
            return v;
          }

          if (dateFormat) {
            if (dateFormat == "timestamp") {
              return new Date(v * 1000);
            }

            if (dateFormat == "time") {
              return new Date(parseInt(v, 10));
            }

            return Date.parseDate(v, dateFormat);
          }

          var parsed = Date.parse(v);
          return parsed ? new Date(parsed) : null;
        };

        break;

      default:
        cv = function cv(v) {
          return v;
        };

        break;
    }

    this.convert = cv;
  }
};

Ext.data.Field.prototype = {
  /**
   * @cfg {String} name
   * The name by which the field is referenced within the Record. This is referenced by, for example,
   * the <tt>dataIndex</tt> property in column definition objects passed to {@link Ext.grid.ColumnModel}.
   * <p>Note: In the simplest case, if no properties other than <tt>name</tt> are required, a field
   * definition may consist of just a String for the field name.</p>
   */

  /**
   * @cfg {String} type
   * (Optional) The data type for conversion to displayable value if <tt>{@link Ext.data.Field#convert convert}</tt>
   * has not been specified. Possible values are
   * <div class="mdetail-params"><ul>
   * <li>auto (Default, implies no conversion)</li>
   * <li>string</li>
   * <li>int</li>
   * <li>float</li>
   * <li>boolean</li>
   * <li>date</li></ul></div>
   */

  /**
   * @cfg {Function} convert
   * (Optional) A function which converts the value provided by the Reader into an object that will be stored
   * in the Record. It is passed the following parameters:<div class="mdetail-params"><ul>
   * <li><b>v</b> : Mixed<div class="sub-desc">The data value as read by the Reader, if undefined will use
   * the configured <tt>{@link Ext.data.Field#defaultValue defaultValue}</tt>.</div></li>
   * <li><b>rec</b> : Mixed<div class="sub-desc">The data object containing the row as read by the Reader.
   * Depending on the Reader type, this could be an Array ({@link Ext.data.ArrayReader ArrayReader}), an object
   *  ({@link Ext.data.JsonReader JsonReader}), or an XML element ({@link Ext.data.XMLReader XMLReader}).</div></li>
   * </ul></div>
   * <pre><code>
  // example of convert function
  function fullName(v, record){
  return record.name.last + ', ' + record.name.first;
  }
  function location(v, record){
  return !record.city ? '' : (record.city + ', ' + record.state);
  }
  var Dude = Ext.data.Record.create([
  {name: 'fullname',  convert: fullName},
  {name: 'firstname', mapping: 'name.first'},
  {name: 'lastname',  mapping: 'name.last'},
  {name: 'city', defaultValue: 'homeless'},
  'state',
  {name: 'location',  convert: location}
  ]);
  // create the data store
  var store = new Ext.data.Store({
  reader: new Ext.data.JsonReader(
      {
          idProperty: 'key',
          root: 'daRoot',
          totalProperty: 'total'
      },
      Dude  // recordType
  )
  });
  var myData = [
  { key: 1,
    name: { first: 'Fat',    last:  'Albert' }
    // notice no city, state provided in data object
  },
  { key: 2,
    name: { first: 'Barney', last:  'Rubble' },
    city: 'Bedrock', state: 'Stoneridge'
  },
  { key: 3,
    name: { first: 'Cliff',  last:  'Claven' },
    city: 'Boston',  state: 'MA'
  }
  ];
   * </code></pre>
   */

  /**
   * @cfg {String} dateFormat
   * (Optional) A format string for the {@link Date#parseDate Date.parseDate} function, or "timestamp" if the
   * value provided by the Reader is a UNIX timestamp, or "time" if the value provided by the Reader is a
   * javascript millisecond timestamp.
   */
  dateFormat: null,

  /**
   * @cfg {Mixed} defaultValue
   * (Optional) The default value used <b>when a Record is being created by a {@link Ext.data.Reader Reader}</b>
   * when the item referenced by the <tt>{@link Ext.data.Field#mapping mapping}</tt> does not exist in the data
   * object (i.e. undefined). (defaults to "")
   */
  defaultValue: "",

  /**
   * @cfg {String/Number} mapping
   * <p>(Optional) A path expression for use by the {@link Ext.data.DataReader} implementation
   * that is creating the {@link Ext.data.Record Record} to extract the Field value from the data object.
   * If the path expression is the same as the field name, the mapping may be omitted.</p>
   * <p>The form of the mapping expression depends on the Reader being used.</p>
   * <div class="mdetail-params"><ul>
   * <li>{@link Ext.data.JsonReader}<div class="sub-desc">The mapping is a string containing the javascript
   * expression to reference the data from an element of the data item's {@link Ext.data.JsonReader#root root} Array. Defaults to the field name.</div></li>
   * <li>{@link Ext.data.XmlReader}<div class="sub-desc">The mapping is an {@link Ext.DomQuery} path to the data
   * item relative to the DOM element that represents the {@link Ext.data.XmlReader#record record}. Defaults to the field name.</div></li>
   * <li>{@link Ext.data.ArrayReader}<div class="sub-desc">The mapping is a number indicating the Array index
   * of the field's value. Defaults to the field specification's Array position.</div></li>
   * </ul></div>
   * <p>If a more complex value extraction strategy is required, then configure the Field with a {@link #convert}
   * function. This is passed the whole row object, and may interrogate it in whatever way is necessary in order to
   * return the desired data.</p>
   */
  mapping: null,

  /**
   * @cfg {Function} sortType
   * (Optional) A function which converts a Field's value to a comparable value in order to ensure
   * correct sort ordering. Predefined functions are provided in {@link Ext.data.SortTypes}. A custom
   * sort example:<pre><code>
  // current sort     after sort we want
  // +-+------+          +-+------+
  // |1|First |          |1|First |
  // |2|Last  |          |3|Second|
  // |3|Second|          |2|Last  |
  // +-+------+          +-+------+
  sortType: function(value) {
  switch (value.toLowerCase()) // native toLowerCase():
  {
    case 'first': return 1;
    case 'second': return 2;
    default: return 3;
  }
  }
   * </code></pre>
   */
  sortType: null,

  /**
   * @cfg {String} sortDir
   * (Optional) Initial direction to sort (<tt>"ASC"</tt> or  <tt>"DESC"</tt>).  Defaults to
   * <tt>"ASC"</tt>.
   */
  sortDir: "ASC",

  /**
   * @cfg {Boolean} allowBlank
   * (Optional) Used for validating a {@link Ext.data.Record record}, defaults to <tt>true</tt>.
   * An empty value here will cause {@link Ext.data.Record}.{@link Ext.data.Record#isValid isValid}
   * to evaluate to <tt>false</tt>.
   */
  allowBlank: true
};

/***/ }),
/* 796 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.DataReader
 * Abstract base class for reading structured data from a data source and converting
 * it into an object containing {@link Ext.data.Record} objects and metadata for use
 * by an {@link Ext.data.Store}.  This class is intended to be extended and should not
 * be created directly. For existing implementations, see {@link Ext.data.ArrayReader},
 * {@link Ext.data.JsonReader} and {@link Ext.data.XmlReader}.
 * @constructor Create a new DataReader
 * @param {Object} meta Metadata configuration options (implementation-specific).
 * @param {Array/Object} recordType
 * <p>Either an Array of {@link Ext.data.Field Field} definition objects (which
 * will be passed to {@link Ext.data.Record#create}, or a {@link Ext.data.Record Record}
 * constructor created using {@link Ext.data.Record#create}.</p>
 */
Ext.data.DataReader = function (meta, recordType) {
  /**
   * This DataReader's configured metadata as passed to the constructor.
   * @type Mixed
   * @property meta
   */
  this.meta = meta;
  /**
   * @cfg {Array/Object} fields
   * <p>Either an Array of {@link Ext.data.Field Field} definition objects (which
   * will be passed to {@link Ext.data.Record#create}, or a {@link Ext.data.Record Record}
   * constructor created from {@link Ext.data.Record#create}.</p>
   */

  this.recordType = Ext.isArray(recordType) ? Ext.data.Record.create(recordType) : recordType; // if recordType defined make sure extraction functions are defined

  if (this.recordType) {
    this.buildExtractors();
    this.recordType.prototype.fields.on('add', this.onMetaChange.createDelegate(this, [], false), this, {
      buffer: 10
    });
  }
};

Ext.data.DataReader.prototype = {
  /**
   * @cfg {String} messageProperty [undefined] Optional name of a property within a server-response that represents a user-feedback message.
   */

  /**
   * Abstract method created in extension's buildExtractors impl.
   */
  getTotal: Ext.emptyFn,

  /**
   * Abstract method created in extension's buildExtractors impl.
   */
  getRoot: Ext.emptyFn,

  /**
   * Abstract method created in extension's buildExtractors impl.
   */
  getMessage: Ext.emptyFn,

  /**
   * Abstract method created in extension's buildExtractors impl.
   */
  getSuccess: Ext.emptyFn,

  /**
   * Abstract method created in extension's buildExtractors impl.
   */
  getId: Ext.emptyFn,

  /**
   * Abstract method, overridden in DataReader extensions such as {@link Ext.data.JsonReader} and {@link Ext.data.XmlReader}
   */
  buildExtractors: Ext.emptyFn,

  /**
   * Abstract method overridden in DataReader extensions such as {@link Ext.data.JsonReader} and {@link Ext.data.XmlReader}
   */
  extractData: Ext.emptyFn,

  /**
   * Abstract method overridden in DataReader extensions such as {@link Ext.data.JsonReader} and {@link Ext.data.XmlReader}
   */
  extractValues: Ext.emptyFn,

  /**
   * Used for un-phantoming a record after a successful database insert.  Sets the records pk along with new data from server.
   * You <b>must</b> return at least the database pk using the idProperty defined in your DataReader configuration.  The incoming
   * data from server will be merged with the data in the local record.
   * In addition, you <b>must</b> return record-data from the server in the same order received.
   * Will perform a commit as well, un-marking dirty-fields.  Store's "update" event will be suppressed.
   * @param {Record/Record[]} record The phantom record to be realized.
   * @param {Object/Object[]} data The new record data to apply.  Must include the primary-key from database defined in idProperty field.
   */
  realize: function realize(rs, data) {
    if (Ext.isArray(rs)) {
      for (var i = rs.length - 1; i >= 0; i--) {
        // recurse
        if (Ext.isArray(data)) {
          this.realize(rs.splice(i, 1).shift(), data.splice(i, 1).shift());
        } else {
          // weird...rs is an array but data isn't??  recurse but just send in the whole invalid data object.
          // the else clause below will detect !this.isData and throw exception.
          this.realize(rs.splice(i, 1).shift(), data);
        }
      }
    } else {
      // If rs is NOT an array but data IS, see if data contains just 1 record.  If so extract it and carry on.
      if (Ext.isArray(data) && data.length == 1) {
        data = data.shift();
      }

      if (!this.isData(data)) {
        // TODO: Let exception-handler choose to commit or not rather than blindly rs.commit() here.
        //rs.commit();
        throw new Ext.data.DataReader.Error('realize', rs);
      }

      rs.phantom = false; // <-- That's what it's all about

      rs._phid = rs.id; // <-- copy phantom-id -> _phid, so we can remap in Store#onCreateRecords

      rs.id = this.getId(data);
      rs.fields.each(function (f) {
        if (data[f.name] !== f.defaultValue) {
          rs.data[f.name] = data[f.name];
        }
      });
      rs.commit();
    }
  },

  /**
   * Used for updating a non-phantom or "real" record's data with fresh data from server after remote-save.
   * If returning data from multiple-records after a batch-update, you <b>must</b> return record-data from the server in
   * the same order received.  Will perform a commit as well, un-marking dirty-fields.  Store's "update" event will be
   * suppressed as the record receives fresh new data-hash
   * @param {Record/Record[]} rs
   * @param {Object/Object[]} data
   */
  update: function update(rs, data) {
    if (Ext.isArray(rs)) {
      for (var i = rs.length - 1; i >= 0; i--) {
        if (Ext.isArray(data)) {
          this.update(rs.splice(i, 1).shift(), data.splice(i, 1).shift());
        } else {
          // weird...rs is an array but data isn't??  recurse but just send in the whole data object.
          // the else clause below will detect !this.isData and throw exception.
          this.update(rs.splice(i, 1).shift(), data);
        }
      }
    } else {
      // If rs is NOT an array but data IS, see if data contains just 1 record.  If so extract it and carry on.
      if (Ext.isArray(data) && data.length == 1) {
        data = data.shift();
      }

      if (this.isData(data)) {
        rs.fields.each(function (f) {
          if (data[f.name] !== f.defaultValue) {
            rs.data[f.name] = data[f.name];
          }
        });
      }

      rs.commit();
    }
  },

  /**
   * returns extracted, type-cast rows of data.  Iterates to call #extractValues for each row
   * @param {Object[]/Object} data-root from server response
   * @param {Boolean} returnRecords [false] Set true to return instances of Ext.data.Record
   * @private
   */
  extractData: function extractData(root, returnRecords) {
    // A bit ugly this, too bad the Record's raw data couldn't be saved in a common property named "raw" or something.
    var rawName = this instanceof Ext.data.JsonReader ? 'json' : 'node';
    var rs = []; // Had to add Check for XmlReader, #isData returns true if root is an Xml-object.  Want to check in order to re-factor
    // #extractData into DataReader base, since the implementations are almost identical for JsonReader, XmlReader

    if (this.isData(root) && !(this instanceof Ext.data.XmlReader)) {
      root = [root];
    }

    var f = this.recordType.prototype.fields,
        fi = f.items,
        fl = f.length,
        rs = [];

    if (returnRecords === true) {
      var Record = this.recordType;

      for (var i = 0; i < root.length; i++) {
        var n = root[i];
        var record = new Record(this.extractValues(n, fi, fl), this.getId(n));
        record[rawName] = n; // <-- There's implementation of ugly bit, setting the raw record-data.

        rs.push(record);
      }
    } else {
      for (var i = 0; i < root.length; i++) {
        var data = this.extractValues(root[i], fi, fl);
        data[this.meta.idProperty] = this.getId(root[i]);
        rs.push(data);
      }
    }

    return rs;
  },

  /**
   * Returns true if the supplied data-hash <b>looks</b> and quacks like data.  Checks to see if it has a key
   * corresponding to idProperty defined in your DataReader config containing non-empty pk.
   * @param {Object} data
   * @return {Boolean}
   */
  isData: function isData(data) {
    return data && Ext.isObject(data) && !Ext.isEmpty(this.getId(data)) ? true : false;
  },
  // private function a store will createSequence upon
  onMetaChange: function onMetaChange(meta) {
    delete this.ef;

    if (meta) {
      this.meta = meta;
      this.recordType = Ext.data.Record.create(meta.fields);
    }

    this.buildExtractors();
  }
};
/**
 * @class Ext.data.DataReader.Error
 * @extends Ext.Error
 * General error class for Ext.data.DataReader
 */

Ext.data.DataReader.Error = Ext.extend(Ext.Error, {
  constructor: function constructor(message, arg) {
    this.arg = arg;
    Ext.Error.call(this, message);
  },
  name: 'Ext.data.DataReader'
});
Ext.apply(Ext.data.DataReader.Error.prototype, {
  lang: {
    'update': "#update received invalid data from server.  Please see docs for DataReader#update and review your DataReader configuration.",
    'realize': "#realize was called with invalid remote-data.  Please see the docs for DataReader#realize and review your DataReader configuration.",
    'invalid-response': "#readResponse received an invalid response from the server."
  }
});

/***/ }),
/* 797 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.DataWriter
 * <p>Ext.data.DataWriter facilitates create, update, and destroy actions between
 * an Ext.data.Store and a server-side framework. A Writer enabled Store will
 * automatically manage the Ajax requests to perform CRUD actions on a Store.</p>
 * <p>Ext.data.DataWriter is an abstract base class which is intended to be extended
 * and should not be created directly. For existing implementations, see
 * {@link Ext.data.JsonWriter}.</p>
 * <p>Creating a writer is simple:</p>
 * <pre><code>
var writer = new Ext.data.JsonWriter({
    encode: false   // &lt;--- false causes data to be printed to jsonData config-property of Ext.Ajax#reqeust
});
 * </code></pre>
 * * <p>Same old JsonReader as Ext-2.x:</p>
 * <pre><code>
var reader = new Ext.data.JsonReader({idProperty: 'id'}, [{name: 'first'}, {name: 'last'}, {name: 'email'}]);
 * </code></pre>
 *
 * <p>The proxy for a writer enabled store can be configured with a simple <code>url</code>:</p>
 * <pre><code>
// Create a standard HttpProxy instance.
var proxy = new Ext.data.HttpProxy({
    url: 'app.php/users'    // &lt;--- Supports "provides"-type urls, such as '/users.json', '/products.xml' (Hello Rails/Merb)
});
 * </code></pre>
 * <p>For finer grained control, the proxy may also be configured with an <code>API</code>:</p>
 * <pre><code>
// Maximum flexibility with the API-configuration
var proxy = new Ext.data.HttpProxy({
    api: {
        read    : 'app.php/users/read',
        create  : 'app.php/users/create',
        update  : 'app.php/users/update',
        destroy : {  // &lt;--- Supports object-syntax as well
            url: 'app.php/users/destroy',
            method: "DELETE"
        }
    }
});
 * </code></pre>
 * <p>Pulling it all together into a Writer-enabled Store:</p>
 * <pre><code>
var store = new Ext.data.Store({
    proxy: proxy,
    reader: reader,
    writer: writer,
    autoLoad: true,
    autoSave: true  // -- Cell-level updates.
});
 * </code></pre>
 * <p>Initiating write-actions <b>automatically</b>, using the existing Ext2.0 Store/Record API:</p>
 * <pre><code>
var rec = store.getAt(0);
rec.set('email', 'foo@bar.com');  // &lt;--- Immediately initiates an UPDATE action through configured proxy.

store.remove(rec);  // &lt;---- Immediately initiates a DESTROY action through configured proxy.
 * </code></pre>
 * <p>For <b>record/batch</b> updates, use the Store-configuration {@link Ext.data.Store#autoSave autoSave:false}</p>
 * <pre><code>
var store = new Ext.data.Store({
    proxy: proxy,
    reader: reader,
    writer: writer,
    autoLoad: true,
    autoSave: false  // -- disable cell-updates
});

var urec = store.getAt(0);
urec.set('email', 'foo@bar.com');

var drec = store.getAt(1);
store.remove(drec);

// Push the button!
store.save();
 * </code></pre>
 * @constructor Create a new DataWriter
 * @param {Object} meta Metadata configuration options (implementation-specific)
 * @param {Object} recordType Either an Array of field definition objects as specified
 * in {@link Ext.data.Record#create}, or an {@link Ext.data.Record} object created
 * using {@link Ext.data.Record#create}.
 */
Ext.data.DataWriter = function (config) {
  Ext.apply(this, config);
};

Ext.data.DataWriter.prototype = {
  /**
   * @cfg {Boolean} writeAllFields
   * <tt>false</tt> by default.  Set <tt>true</tt> to have DataWriter return ALL fields of a modified
   * record -- not just those that changed.
   * <tt>false</tt> to have DataWriter only request modified fields from a record.
   */
  writeAllFields: false,

  /**
   * @cfg {Boolean} listful
   * <tt>false</tt> by default.  Set <tt>true</tt> to have the DataWriter <b>always</b> write HTTP params as a list,
   * even when acting upon a single record.
   */
  listful: false,
  // <-- listful is actually not used internally here in DataWriter.  @see Ext.data.Store#execute.

  /**
   * Compiles a Store recordset into a data-format defined by an extension such as {@link Ext.data.JsonWriter} or {@link Ext.data.XmlWriter} in preparation for a {@link Ext.data.Api#actions server-write action}.  The first two params are similar similar in nature to {@link Ext#apply},
   * Where the first parameter is the <i>receiver</i> of paramaters and the second, baseParams, <i>the source</i>.
   * @param {Object} params The request-params receiver.
   * @param {Object} baseParams as defined by {@link Ext.data.Store#baseParams}.  The baseParms must be encoded by the extending class, eg: {@link Ext.data.JsonWriter}, {@link Ext.data.XmlWriter}.
   * @param {String} action [{@link Ext.data.Api#actions create|update|destroy}]
   * @param {Record/Record[]} rs The recordset to write, the subject(s) of the write action.
   */
  apply: function apply(params, baseParams, action, rs) {
    var data = [],
        renderer = action + 'Record'; // TODO implement @cfg listful here

    if (Ext.isArray(rs)) {
      Ext.each(rs, function (rec) {
        data.push(this[renderer](rec));
      }, this);
    } else if (rs instanceof Ext.data.Record) {
      data = this[renderer](rs);
    }

    this.render(params, baseParams, data);
  },

  /**
   * abstract method meant to be overridden by all DataWriter extensions.  It's the extension's job to apply the "data" to the "params".
   * The data-object provided to render is populated with data according to the meta-info defined in the user's DataReader config,
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Record[]} rs Store recordset
   * @param {Object} params Http params to be sent to server.
   * @param {Object} data object populated according to DataReader meta-data.
   */
  render: Ext.emptyFn,

  /**
   * @cfg {Function} updateRecord Abstract method that should be implemented in all subclasses
   * (e.g.: {@link Ext.data.JsonWriter#updateRecord JsonWriter.updateRecord}
   */
  updateRecord: Ext.emptyFn,

  /**
   * @cfg {Function} createRecord Abstract method that should be implemented in all subclasses
   * (e.g.: {@link Ext.data.JsonWriter#createRecord JsonWriter.createRecord})
   */
  createRecord: Ext.emptyFn,

  /**
   * @cfg {Function} destroyRecord Abstract method that should be implemented in all subclasses
   * (e.g.: {@link Ext.data.JsonWriter#destroyRecord JsonWriter.destroyRecord})
   */
  destroyRecord: Ext.emptyFn,

  /**
   * Converts a Record to a hash, taking into account the state of the Ext.data.Record along with configuration properties
   * related to its rendering, such as {@link #writeAllFields}, {@link Ext.data.Record#phantom phantom}, {@link Ext.data.Record#getChanges getChanges} and
   * {@link Ext.data.DataReader#idProperty idProperty}
   * @param {Ext.data.Record}
   * @param {Object} config <b>NOT YET IMPLEMENTED</b>.  Will implement an exlude/only configuration for fine-control over which fields do/don't get rendered.
   * @return {Object}
   * @protected
   * TODO Implement excludes/only configuration with 2nd param?
   */
  toHash: function toHash(rec, config) {
    var map = rec.fields.map,
        data = {},
        raw = this.writeAllFields === false && rec.phantom === false ? rec.getChanges() : rec.data,
        m;
    Ext.iterate(raw, function (prop, value) {
      if (m = map[prop]) {
        data[m.mapping ? m.mapping : m.name] = value;
      }
    }); // we don't want to write Ext auto-generated id to hash.  Careful not to remove it on Models not having auto-increment pk though.
    // We can tell its not auto-increment if the user defined a DataReader field for it *and* that field's value is non-empty.
    // we could also do a RegExp here for the Ext.data.Record AUTO_ID prefix.

    if (rec.phantom) {
      if (rec.fields.containsKey(this.meta.idProperty) && Ext.isEmpty(rec.data[this.meta.idProperty])) {
        delete data[this.meta.idProperty];
      }
    } else {
      data[this.meta.idProperty] = rec.id;
    }

    return data;
  },

  /**
   * Converts a {@link Ext.data.DataWriter#toHash Hashed} {@link Ext.data.Record} to fields-array array suitable
   * for encoding to xml via XTemplate, eg:
  <code><pre>&lt;tpl for=".">&lt;{name}>{value}&lt;/{name}&lt;/tpl></pre></code>
   * eg, <b>non-phantom</b>:
  <code><pre>{id: 1, first: 'foo', last: 'bar'} --> [{name: 'id', value: 1}, {name: 'first', value: 'foo'}, {name: 'last', value: 'bar'}]</pre></code>
   * {@link Ext.data.Record#phantom Phantom} records will have had their idProperty omitted in {@link #toHash} if determined to be auto-generated.
   * Non AUTOINCREMENT pks should have been protected.
   * @param {Hash} data Hashed by Ext.data.DataWriter#toHash
   * @return {[Object]} Array of attribute-objects.
   * @protected
   */
  toArray: function toArray(data) {
    var fields = [];
    Ext.iterate(data, function (k, v) {
      fields.push({
        name: k,
        value: v
      });
    }, this);
    return fields;
  }
};

/***/ }),
/* 798 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.DataProxy
 * @extends Ext.util.Observable
 * <p>Abstract base class for implementations which provide retrieval of unformatted data objects.
 * This class is intended to be extended and should not be created directly. For existing implementations,
 * see {@link Ext.data.DirectProxy}, {@link Ext.data.HttpProxy}, {@link Ext.data.ScriptTagProxy} and
 * {@link Ext.data.MemoryProxy}.</p>
 * <p>DataProxy implementations are usually used in conjunction with an implementation of {@link Ext.data.DataReader}
 * (of the appropriate type which knows how to parse the data object) to provide a block of
 * {@link Ext.data.Records} to an {@link Ext.data.Store}.</p>
 * <p>The parameter to a DataProxy constructor may be an {@link Ext.data.Connection} or can also be the
 * config object to an {@link Ext.data.Connection}.</p>
 * <p>Custom implementations must implement either the <code><b>doRequest</b></code> method (preferred) or the
 * <code>load</code> method (deprecated). See
 * {@link Ext.data.HttpProxy}.{@link Ext.data.HttpProxy#doRequest doRequest} or
 * {@link Ext.data.HttpProxy}.{@link Ext.data.HttpProxy#load load} for additional details.</p>
 * <p><b><u>Example 1</u></b></p>
 * <pre><code>
proxy: new Ext.data.ScriptTagProxy({
    {@link Ext.data.Connection#url url}: 'http://extjs.com/forum/topics-remote.php'
}),
 * </code></pre>
 * <p><b><u>Example 2</u></b></p>
 * <pre><code>
proxy : new Ext.data.HttpProxy({
    {@link Ext.data.Connection#method method}: 'GET',
    {@link Ext.data.HttpProxy#prettyUrls prettyUrls}: false,
    {@link Ext.data.Connection#url url}: 'local/default.php', // see options parameter for {@link Ext.Ajax#request}
    {@link #api}: {
        // all actions except the following will use above url
        create  : 'local/new.php',
        update  : 'local/update.php'
    }
}),
 * </code></pre>
 * <p>And <b>new in Ext version 3</b>, attach centralized event-listeners upon the DataProxy class itself!  This is a great place
 * to implement a <i>messaging system</i> to centralize your application's user-feedback and error-handling.</p>
 * <pre><code>
// Listen to all "beforewrite" event fired by all proxies.
Ext.data.DataProxy.on('beforewrite', function(proxy, action) {
    console.log('beforewrite: ', action);
});

// Listen to "write" event fired by all proxies
Ext.data.DataProxy.on('write', function(proxy, action, data, res, rs) {
    console.info('write: ', action);
});

// Listen to "exception" event fired by all proxies
Ext.data.DataProxy.on('exception', function(proxy, type, action) {
    console.error(type + action + ' exception);
});
 * </code></pre>
 * <b>Note:</b> These three events are all fired with the signature of the corresponding <i>DataProxy instance</i> event {@link #beforewrite beforewrite}, {@link #write write} and {@link #exception exception}.
 */
Ext.data.DataProxy = function (conn) {
  // make sure we have a config object here to support ux proxies.
  // All proxies should now send config into superclass constructor.
  conn = conn || {}; // This line caused a bug when people use custom Connection object having its own request method.
  // http://extjs.com/forum/showthread.php?t=67194.  Have to set DataProxy config
  //Ext.applyIf(this, conn);

  this.api = conn.api;
  this.url = conn.url;
  this.restful = conn.restful;
  this.listeners = conn.listeners; // deprecated

  this.prettyUrls = conn.prettyUrls;
  /**
   * @cfg {Object} api
   * Specific urls to call on CRUD action methods "read", "create", "update" and "destroy".
   * Defaults to:<pre><code>
  api: {
  read    : undefined,
  create  : undefined,
  update  : undefined,
  destroy : undefined
  }
   * </code></pre>
   * <p>The url is built based upon the action being executed <tt>[load|create|save|destroy]</tt>
   * using the commensurate <tt>{@link #api}</tt> property, or if undefined default to the
   * configured {@link Ext.data.Store}.{@link Ext.data.Store#url url}.</p><br>
   * <p>For example:</p>
   * <pre><code>
  api: {
  load :    '/controller/load',
  create :  '/controller/new',  // Server MUST return idProperty of new record
  save :    '/controller/update',
  destroy : '/controller/destroy_action'
  }
  // Alternatively, one can use the object-form to specify each API-action
  api: {
  load: {url: 'read.php', method: 'GET'},
  create: 'create.php',
  destroy: 'destroy.php',
  save: 'update.php'
  }
   * </code></pre>
   * <p>If the specific URL for a given CRUD action is undefined, the CRUD action request
   * will be directed to the configured <tt>{@link Ext.data.Connection#url url}</tt>.</p>
   * <br><p><b>Note</b>: To modify the URL for an action dynamically the appropriate API
   * property should be modified before the action is requested using the corresponding before
   * action event.  For example to modify the URL associated with the load action:
   * <pre><code>
  // modify the url for the action
  myStore.on({
  beforeload: {
      fn: function (store, options) {
          // use <tt>{@link Ext.data.HttpProxy#setUrl setUrl}</tt> to change the URL for *just* this request.
          store.proxy.setUrl('changed1.php');
            // set optional second parameter to true to make this URL change
          // permanent, applying this URL for all subsequent requests.
          store.proxy.setUrl('changed1.php', true);
            // Altering the proxy API should be done using the public
          // method <tt>{@link Ext.data.DataProxy#setApi setApi}</tt>.
          store.proxy.setApi('read', 'changed2.php');
            // Or set the entire API with a config-object.
          // When using the config-object option, you must redefine the <b>entire</b>
          // API -- not just a specific action of it.
          store.proxy.setApi({
              read    : 'changed_read.php',
              create  : 'changed_create.php',
              update  : 'changed_update.php',
              destroy : 'changed_destroy.php'
          });
      }
  }
  });
   * </code></pre>
   * </p>
   */

  this.addEvents(
  /**
   * @event exception
   * <p>Fires if an exception occurs in the Proxy during a remote request. This event is relayed
   * through a corresponding {@link Ext.data.Store}.{@link Ext.data.Store#exception exception},
   * so any Store instance may observe this event.</p>
   * <p>In addition to being fired through the DataProxy instance that raised the event, this event is also fired
   * through the Ext.data.DataProxy <i>class</i> to allow for centralized processing of exception events from <b>all</b>
   * DataProxies by attaching a listener to the Ext.data.Proxy class itself.</p>
   * <p>This event can be fired for one of two reasons:</p>
   * <div class="mdetail-params"><ul>
   * <li>remote-request <b>failed</b> : <div class="sub-desc">
   * The server did not return status === 200.
   * </div></li>
   * <li>remote-request <b>succeeded</b> : <div class="sub-desc">
   * The remote-request succeeded but the reader could not read the response.
   * This means the server returned data, but the configured Reader threw an
   * error while reading the response.  In this case, this event will be
   * raised and the caught error will be passed along into this event.
   * </div></li>
   * </ul></div>
   * <br><p>This event fires with two different contexts based upon the 2nd
   * parameter <tt>type [remote|response]</tt>.  The first four parameters
   * are identical between the two contexts -- only the final two parameters
   * differ.</p>
   * @param {DataProxy} this The proxy that sent the request
   * @param {String} type
   * <p>The value of this parameter will be either <tt>'response'</tt> or <tt>'remote'</tt>.</p>
   * <div class="mdetail-params"><ul>
   * <li><b><tt>'response'</tt></b> : <div class="sub-desc">
   * <p>An <b>invalid</b> response from the server was returned: either 404,
   * 500 or the response meta-data does not match that defined in the DataReader
   * (e.g.: root, idProperty, successProperty).</p>
   * </div></li>
   * <li><b><tt>'remote'</tt></b> : <div class="sub-desc">
   * <p>A <b>valid</b> response was returned from the server having
   * successProperty === false.  This response might contain an error-message
   * sent from the server.  For example, the user may have failed
   * authentication/authorization or a database validation error occurred.</p>
   * </div></li>
   * </ul></div>
   * @param {String} action Name of the action (see {@link Ext.data.Api#actions}.
   * @param {Object} options The options for the action that were specified in the {@link #request}.
   * @param {Object} response
   * <p>The value of this parameter depends on the value of the <code>type</code> parameter:</p>
   * <div class="mdetail-params"><ul>
   * <li><b><tt>'response'</tt></b> : <div class="sub-desc">
   * <p>The raw browser response object (e.g.: XMLHttpRequest)</p>
   * </div></li>
   * <li><b><tt>'remote'</tt></b> : <div class="sub-desc">
   * <p>The decoded response object sent from the server.</p>
   * </div></li>
   * </ul></div>
   * @param {Mixed} arg
   * <p>The type and value of this parameter depends on the value of the <code>type</code> parameter:</p>
   * <div class="mdetail-params"><ul>
   * <li><b><tt>'response'</tt></b> : Error<div class="sub-desc">
   * <p>The JavaScript Error object caught if the configured Reader could not read the data.
   * If the remote request returns success===false, this parameter will be null.</p>
   * </div></li>
   * <li><b><tt>'remote'</tt></b> : Record/Record[]<div class="sub-desc">
   * <p>This parameter will only exist if the <tt>action</tt> was a <b>write</b> action
   * (Ext.data.Api.actions.create|update|destroy).</p>
   * </div></li>
   * </ul></div>
   */
  'exception',
  /**
   * @event beforeload
   * Fires before a request to retrieve a data object.
   * @param {DataProxy} this The proxy for the request
   * @param {Object} params The params object passed to the {@link #request} function
   */
  'beforeload',
  /**
   * @event load
   * Fires before the load method's callback is called.
   * @param {DataProxy} this The proxy for the request
   * @param {Object} o The request transaction object
   * @param {Object} options The callback's <tt>options</tt> property as passed to the {@link #request} function
   */
  'load',
  /**
   * @event loadexception
   * <p>This event is <b>deprecated</b>.  The signature of the loadexception event
   * varies depending on the proxy, use the catch-all {@link #exception} event instead.
   * This event will fire in addition to the {@link #exception} event.</p>
   * @param {misc} misc See {@link #exception}.
   * @deprecated
   */
  'loadexception',
  /**
   * @event beforewrite
   * <p>Fires before a request is generated for one of the actions Ext.data.Api.actions.create|update|destroy</p>
   * <p>In addition to being fired through the DataProxy instance that raised the event, this event is also fired
   * through the Ext.data.DataProxy <i>class</i> to allow for centralized processing of beforewrite events from <b>all</b>
   * DataProxies by attaching a listener to the Ext.data.Proxy class itself.</p>
   * @param {DataProxy} this The proxy for the request
   * @param {String} action [Ext.data.Api.actions.create|update|destroy]
   * @param {Record/Array[Record]} rs The Record(s) to create|update|destroy.
   * @param {Object} params The request <code>params</code> object.  Edit <code>params</code> to add parameters to the request.
   */
  'beforewrite',
  /**
   * @event write
   * <p>Fires before the request-callback is called</p>
   * <p>In addition to being fired through the DataProxy instance that raised the event, this event is also fired
   * through the Ext.data.DataProxy <i>class</i> to allow for centralized processing of write events from <b>all</b>
   * DataProxies by attaching a listener to the Ext.data.Proxy class itself.</p>
   * @param {DataProxy} this The proxy that sent the request
   * @param {String} action [Ext.data.Api.actions.create|upate|destroy]
   * @param {Object} data The data object extracted from the server-response
   * @param {Object} response The decoded response from server
   * @param {Record/Record{}} rs The records from Store
   * @param {Object} options The callback's <tt>options</tt> property as passed to the {@link #request} function
   */
  'write');
  Ext.data.DataProxy.superclass.constructor.call(this); // Prepare the proxy api.  Ensures all API-actions are defined with the Object-form.

  try {
    Ext.data.Api.prepare(this);
  } catch (e) {
    if (e instanceof Ext.data.Api.Error) {
      e.toConsole();
    }
  } // relay each proxy's events onto Ext.data.DataProxy class for centralized Proxy-listening


  Ext.data.DataProxy.relayEvents(this, ['beforewrite', 'write', 'exception']);
};

Ext.extend(Ext.data.DataProxy, Ext.util.Observable, {
  /**
   * @cfg {Boolean} restful
   * <p>Defaults to <tt>false</tt>.  Set to <tt>true</tt> to operate in a RESTful manner.</p>
   * <br><p> Note: this parameter will automatically be set to <tt>true</tt> if the
   * {@link Ext.data.Store} it is plugged into is set to <code>restful: true</code>. If the
   * Store is RESTful, there is no need to set this option on the proxy.</p>
   * <br><p>RESTful implementations enable the serverside framework to automatically route
   * actions sent to one url based upon the HTTP method, for example:
   * <pre><code>
  store: new Ext.data.Store({
  restful: true,
  proxy: new Ext.data.HttpProxy({url:'/users'}); // all requests sent to /users
  ...
  )}
   * </code></pre>
   * If there is no <code>{@link #api}</code> specified in the configuration of the proxy,
   * all requests will be marshalled to a single RESTful url (/users) so the serverside
   * framework can inspect the HTTP Method and act accordingly:
   * <pre>
  <u>Method</u>   <u>url</u>        <u>action</u>
  POST     /users     create
  GET      /users     read
  PUT      /users/23  update
  DESTROY  /users/23  delete
   * </pre></p>
   * <p>If set to <tt>true</tt>, a {@link Ext.data.Record#phantom non-phantom} record's
   * {@link Ext.data.Record#id id} will be appended to the url. Some MVC (e.g., Ruby on Rails,
   * Merb and Django) support segment based urls where the segments in the URL follow the
   * Model-View-Controller approach:<pre><code>
   * someSite.com/controller/action/id
   * </code></pre>
   * Where the segments in the url are typically:<div class="mdetail-params"><ul>
   * <li>The first segment : represents the controller class that should be invoked.</li>
   * <li>The second segment : represents the class function, or method, that should be called.</li>
   * <li>The third segment : represents the ID (a variable typically passed to the method).</li>
   * </ul></div></p>
   * <br><p>Refer to <code>{@link Ext.data.DataProxy#api}</code> for additional information.</p>
   */
  restful: false,

  /**
   * <p>Redefines the Proxy's API or a single action of an API. Can be called with two method signatures.</p>
   * <p>If called with an object as the only parameter, the object should redefine the <b>entire</b> API, e.g.:</p><pre><code>
  proxy.setApi({
  read    : '/users/read',
  create  : '/users/create',
  update  : '/users/update',
  destroy : '/users/destroy'
  });
  </code></pre>
   * <p>If called with two parameters, the first parameter should be a string specifying the API action to
   * redefine and the second parameter should be the URL (or function if using DirectProxy) to call for that action, e.g.:</p><pre><code>
  proxy.setApi(Ext.data.Api.actions.read, '/users/new_load_url');
  </code></pre>
   * @param {String/Object} api An API specification object, or the name of an action.
   * @param {String/Function} url The URL (or function if using DirectProxy) to call for the action.
   */
  setApi: function setApi() {
    if (arguments.length == 1) {
      var valid = Ext.data.Api.isValid(arguments[0]);

      if (valid === true) {
        this.api = arguments[0];
      } else {
        throw new Ext.data.Api.Error('invalid', valid);
      }
    } else if (arguments.length == 2) {
      if (!Ext.data.Api.isAction(arguments[0])) {
        throw new Ext.data.Api.Error('invalid', arguments[0]);
      }

      this.api[arguments[0]] = arguments[1];
    }

    Ext.data.Api.prepare(this);
  },

  /**
   * Returns true if the specified action is defined as a unique action in the api-config.
   * request.  If all API-actions are routed to unique urls, the xaction parameter is unecessary.  However, if no api is defined
   * and all Proxy actions are routed to DataProxy#url, the server-side will require the xaction parameter to perform a switch to
   * the corresponding code for CRUD action.
   * @param {String [Ext.data.Api.CREATE|READ|UPDATE|DESTROY]} action
   * @return {Boolean}
   */
  isApiAction: function isApiAction(action) {
    return this.api[action] ? true : false;
  },

  /**
   * All proxy actions are executed through this method.  Automatically fires the "before" + action event
   * @param {String} action Name of the action
   * @param {Ext.data.Record/Ext.data.Record[]/null} rs Will be null when action is 'load'
   * @param {Object} params
   * @param {Ext.data.DataReader} reader
   * @param {Function} callback
   * @param {Object} scope The scope (<code>this</code> reference) in which the callback function is executed. Defaults to the Proxy object.
   * @param {Object} options Any options specified for the action (e.g. see {@link Ext.data.Store#load}.
   */
  request: function request(action, rs, params, reader, callback, scope, options) {
    if (!this.api[action] && !this.load) {
      throw new Ext.data.DataProxy.Error('action-undefined', action);
    }

    params = params || {};

    if (action === Ext.data.Api.actions.read ? this.fireEvent("beforeload", this, params) : this.fireEvent("beforewrite", this, action, rs, params) !== false) {
      this.doRequest.apply(this, arguments);
    } else {
      callback.call(scope || this, null, options, false);
    }
  },

  /**
   * <b>Deprecated</b> load method using old method signature. See {@doRequest} for preferred method.
   * @deprecated
   * @param {Object} params
   * @param {Object} reader
   * @param {Object} callback
   * @param {Object} scope
   * @param {Object} arg
   */
  load: null,

  /**
   * @cfg {Function} doRequest Abstract method that should be implemented in all subclasses.  <b>Note:</b> Should only be used by custom-proxy developers.
   * (e.g.: {@link Ext.data.HttpProxy#doRequest HttpProxy.doRequest},
   * {@link Ext.data.DirectProxy#doRequest DirectProxy.doRequest}).
   */
  doRequest: function doRequest(action, rs, params, reader, callback, scope, options) {
    // default implementation of doRequest for backwards compatibility with 2.0 proxies.
    // If we're executing here, the action is probably "load".
    // Call with the pre-3.0 method signature.
    this.load(params, reader, callback, scope, options);
  },

  /**
   * @cfg {Function} onRead Abstract method that should be implemented in all subclasses.  <b>Note:</b> Should only be used by custom-proxy developers.  Callback for read {@link Ext.data.Api#actions action}.
   * @param {String} action Action name as per {@link Ext.data.Api.actions#read}.
   * @param {Object} o The request transaction object
   * @param {Object} res The server response
   * @fires loadexception (deprecated)
   * @fires exception
   * @fires load
   * @protected
   */
  onRead: Ext.emptyFn,

  /**
   * @cfg {Function} onWrite Abstract method that should be implemented in all subclasses.  <b>Note:</b> Should only be used by custom-proxy developers.  Callback for <i>create, update and destroy</i> {@link Ext.data.Api#actions actions}.
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Object} trans The request transaction object
   * @param {Object} res The server response
   * @fires exception
   * @fires write
   * @protected
   */
  onWrite: Ext.emptyFn,

  /**
   * buildUrl
   * Sets the appropriate url based upon the action being executed.  If restful is true, and only a single record is being acted upon,
   * url will be built Rails-style, as in "/controller/action/32".  restful will aply iff the supplied record is an
   * instance of Ext.data.Record rather than an Array of them.
   * @param {String} action The api action being executed [read|create|update|destroy]
   * @param {Ext.data.Record/Array[Ext.data.Record]} The record or Array of Records being acted upon.
   * @return {String} url
   * @private
   */
  buildUrl: function buildUrl(action, record) {
    record = record || null; // conn.url gets nullified after each request.  If it's NOT null here, that means the user must have intervened with a call
    // to DataProxy#setUrl or DataProxy#setApi and changed it before the request was executed.  If that's the case, use conn.url,
    // otherwise, build the url from the api or this.url.

    var url = this.conn && this.conn.url ? this.conn.url : this.api[action] ? this.api[action].url : this.url;

    if (!url) {
      throw new Ext.data.Api.Error('invalid-url', action);
    } // look for urls having "provides" suffix used in some MVC frameworks like Rails/Merb and others.  The provides suffice informs
    // the server what data-format the client is dealing with and returns data in the same format (eg: application/json, application/xml, etc)
    // e.g.: /users.json, /users.xml, etc.
    // with restful routes, we need urls like:
    // PUT /users/1.json
    // DELETE /users/1.json


    var provides = null;
    var m = url.match(/(.*)(\.json|\.xml|\.html)$/);

    if (m) {
      provides = m[2]; // eg ".json"

      url = m[1]; // eg: "/users"
    } // prettyUrls is deprectated in favor of restful-config


    if ((this.restful === true || this.prettyUrls === true) && record instanceof Ext.data.Record && !record.phantom) {
      url += '/' + record.id;
    }

    return provides === null ? url : url + provides;
  },

  /**
   * Destroys the proxy by purging any event listeners and cancelling any active requests.
   */
  destroy: function destroy() {
    this.purgeListeners();
  }
}); // Apply the Observable prototype to the DataProxy class so that proxy instances can relay their
// events to the class.  Allows for centralized listening of all proxy instances upon the DataProxy class.

Ext.apply(Ext.data.DataProxy, Ext.util.Observable.prototype);
Ext.util.Observable.call(Ext.data.DataProxy);
/**
 * @class Ext.data.DataProxy.Error
 * @extends Ext.Error
 * DataProxy Error extension.
 * constructor
 * @param {String} name
 * @param {Record/Array[Record]/Array}
 */

Ext.data.DataProxy.Error = Ext.extend(Ext.Error, {
  constructor: function constructor(message, arg) {
    this.arg = arg;
    Ext.Error.call(this, message);
  },
  name: 'Ext.data.DataProxy'
});
Ext.apply(Ext.data.DataProxy.Error.prototype, {
  lang: {
    'action-undefined': "DataProxy attempted to execute an API-action but found an undefined url / function.  Please review your Proxy url/api-configuration.",
    'api-invalid': 'Recieved an invalid API-configuration.  Please ensure your proxy API-configuration contains only the actions from Ext.data.Api.actions.'
  }
});

/***/ }),
/* 799 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Request
 * A simple Request class used internally to the data package to provide more generalized remote-requests
 * to a DataProxy.
 * TODO Not yet implemented.  Implement in Ext.data.Store#execute
 */
Ext.data.Request = function (params) {
  Ext.apply(this, params);
};

Ext.data.Request.prototype = {
  /**
   * @cfg {String} action
   */
  action: undefined,

  /**
   * @cfg {Ext.data.Record[]/Ext.data.Record} rs The Store recordset associated with the request.
   */
  rs: undefined,

  /**
   * @cfg {Object} params HTTP request params
   */
  params: undefined,

  /**
   * @cfg {Function} callback The function to call when request is complete
   */
  callback: Ext.emptyFn,

  /**
   * @cfg {Object} scope The scope of the callback funtion
   */
  scope: undefined,

  /**
   * @cfg {Ext.data.DataReader} reader The DataReader instance which will parse the received response
   */
  reader: undefined
};

/***/ }),
/* 800 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Response
 * A generic response class to normalize response-handling internally to the framework.
 */
Ext.data.Response = function (params) {
  Ext.apply(this, params);
};

Ext.data.Response.prototype = {
  /**
   * @cfg {String} action {@link Ext.data.Api#actions}
   */
  action: undefined,

  /**
   * @cfg {Boolean} success
   */
  success: undefined,

  /**
   * @cfg {String} message
   */
  message: undefined,

  /**
   * @cfg {Array/Object} data
   */
  data: undefined,

  /**
   * @cfg {Object} raw The raw response returned from server-code
   */
  raw: undefined,

  /**
   * @cfg {Ext.data.Record/Ext.data.Record[]} records related to the Request action
   */
  records: undefined
};

/***/ }),
/* 801 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.ScriptTagProxy
 * @extends Ext.data.DataProxy
 * An implementation of Ext.data.DataProxy that reads a data object from a URL which may be in a domain
 * other than the originating domain of the running page.<br>
 * <p>
 * <b>Note that if you are retrieving data from a page that is in a domain that is NOT the same as the originating domain
 * of the running page, you must use this class, rather than HttpProxy.</b><br>
 * <p>
 * The content passed back from a server resource requested by a ScriptTagProxy <b>must</b> be executable JavaScript
 * source code because it is used as the source inside a &lt;script> tag.<br>
 * <p>
 * In order for the browser to process the returned data, the server must wrap the data object
 * with a call to a callback function, the name of which is passed as a parameter by the ScriptTagProxy.
 * Below is a Java example for a servlet which returns data for either a ScriptTagProxy, or an HttpProxy
 * depending on whether the callback name was passed:
 * <p>
 * <pre><code>
boolean scriptTag = false;
String cb = request.getParameter("callback");
if (cb != null) {
    scriptTag = true;
    response.setContentType("text/javascript");
} else {
    response.setContentType("application/x-json");
}
Writer out = response.getWriter();
if (scriptTag) {
    out.write(cb + "(");
}
out.print(dataBlock.toJsonString());
if (scriptTag) {
    out.write(");");
}
</code></pre>
 * <p>Below is a PHP example to do the same thing:</p><pre><code>
$callback = $_REQUEST['callback'];

// Create the output object.
$output = array('a' => 'Apple', 'b' => 'Banana');

//start output
if ($callback) {
    header('Content-Type: text/javascript');
    echo $callback . '(' . json_encode($output) . ');';
} else {
    header('Content-Type: application/x-json');
    echo json_encode($output);
}
</code></pre>
 * <p>Below is the ASP.Net code to do the same thing:</p><pre><code>
String jsonString = "{success: true}";
String cb = Request.Params.Get("callback");
String responseString = "";
if (!String.IsNullOrEmpty(cb)) {
    responseString = cb + "(" + jsonString + ")";
} else {
    responseString = jsonString;
}
Response.Write(responseString);
</code></pre>
 *
 * @constructor
 * @param {Object} config A configuration object.
 */
Ext.data.ScriptTagProxy = function (config) {
  Ext.apply(this, config);
  Ext.data.ScriptTagProxy.superclass.constructor.call(this, config);
  this.head = document.getElementsByTagName("head")[0];
  /**
   * @event loadexception
   * <b>Deprecated</b> in favor of 'exception' event.
   * Fires if an exception occurs in the Proxy during data loading.  This event can be fired for one of two reasons:
   * <ul><li><b>The load call timed out.</b>  This means the load callback did not execute within the time limit
   * specified by {@link #timeout}.  In this case, this event will be raised and the
   * fourth parameter (read error) will be null.</li>
   * <li><b>The load succeeded but the reader could not read the response.</b>  This means the server returned
   * data, but the configured Reader threw an error while reading the data.  In this case, this event will be
   * raised and the caught error will be passed along as the fourth parameter of this event.</li></ul>
   * Note that this event is also relayed through {@link Ext.data.Store}, so you can listen for it directly
   * on any Store instance.
   * @param {Object} this
   * @param {Object} options The loading options that were specified (see {@link #load} for details).  If the load
   * call timed out, this parameter will be null.
   * @param {Object} arg The callback's arg object passed to the {@link #load} function
   * @param {Error} e The JavaScript Error object caught if the configured Reader could not read the data.
   * If the remote request returns success: false, this parameter will be null.
   */
};

Ext.data.ScriptTagProxy.TRANS_ID = 1000;
Ext.extend(Ext.data.ScriptTagProxy, Ext.data.DataProxy, {
  /**
   * @cfg {String} url The URL from which to request the data object.
   */

  /**
   * @cfg {Number} timeout (optional) The number of milliseconds to wait for a response. Defaults to 30 seconds.
   */
  timeout: 30000,

  /**
   * @cfg {String} callbackParam (Optional) The name of the parameter to pass to the server which tells
   * the server the name of the callback function set up by the load call to process the returned data object.
   * Defaults to "callback".<p>The server-side processing must read this parameter value, and generate
   * javascript output which calls this named function passing the data object as its only parameter.
   */
  callbackParam: "callback",

  /**
   *  @cfg {Boolean} nocache (optional) Defaults to true. Disable caching by adding a unique parameter
   * name to the request.
   */
  nocache: true,

  /**
   * HttpProxy implementation of DataProxy#doRequest
   * @param {String} action
   * @param {Ext.data.Record/Ext.data.Record[]} rs If action is <tt>read</tt>, rs will be null
   * @param {Object} params An object containing properties which are to be used as HTTP parameters
   * for the request to the remote server.
   * @param {Ext.data.DataReader} reader The Reader object which converts the data
   * object into a block of Ext.data.Records.
   * @param {Function} callback The function into which to pass the block of Ext.data.Records.
   * The function must be passed <ul>
   * <li>The Record block object</li>
   * <li>The "arg" argument from the load function</li>
   * <li>A boolean success indicator</li>
   * </ul>
   * @param {Object} scope The scope (<code>this</code> reference) in which the callback function is executed. Defaults to the browser window.
   * @param {Object} arg An optional argument which is passed to the callback as its second parameter.
   */
  doRequest: function doRequest(action, rs, params, reader, callback, scope, arg) {
    var p = Ext.urlEncode(Ext.apply(params, this.extraParams));
    var url = this.buildUrl(action, rs);

    if (!url) {
      throw new Ext.data.Api.Error('invalid-url', url);
    }

    url = Ext.urlAppend(url, p);

    if (this.nocache) {
      url = Ext.urlAppend(url, '_dc=' + new Date().getTime());
    }

    var transId = ++Ext.data.ScriptTagProxy.TRANS_ID;
    var trans = {
      id: transId,
      action: action,
      cb: "stcCallback" + transId,
      scriptId: "stcScript" + transId,
      params: params,
      arg: arg,
      url: url,
      callback: callback,
      scope: scope,
      reader: reader
    };
    window[trans.cb] = this.createCallback(action, rs, trans);
    url += String.format("&{0}={1}", this.callbackParam, trans.cb);

    if (this.autoAbort !== false) {
      this.abort();
    }

    trans.timeoutId = this.handleFailure.defer(this.timeout, this, [trans]);
    var script = document.createElement("script");
    script.setAttribute("src", url);
    script.setAttribute("type", "text/javascript");
    script.setAttribute("id", trans.scriptId);
    this.head.appendChild(script);
    this.trans = trans;
  },
  // @private createCallback
  createCallback: function createCallback(action, rs, trans) {
    var self = this;
    return function (res) {
      self.trans = false;
      self.destroyTrans(trans, true);

      if (action === Ext.data.Api.actions.read) {
        self.onRead.call(self, action, trans, res);
      } else {
        self.onWrite.call(self, action, trans, res, rs);
      }
    };
  },

  /**
   * Callback for read actions
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Object} trans The request transaction object
   * @param {Object} res The server response
   * @protected
   */
  onRead: function onRead(action, trans, res) {
    var result;

    try {
      result = trans.reader.readRecords(res);
    } catch (e) {
      // @deprecated: fire loadexception
      this.fireEvent("loadexception", this, trans, res, e);
      this.fireEvent('exception', this, 'response', action, trans, res, e);
      trans.callback.call(trans.scope || window, null, trans.arg, false);
      return;
    }

    if (result.success === false) {
      // @deprecated: fire old loadexception for backwards-compat.
      this.fireEvent('loadexception', this, trans, res);
      this.fireEvent('exception', this, 'remote', action, trans, res, null);
    } else {
      this.fireEvent("load", this, res, trans.arg);
    }

    trans.callback.call(trans.scope || window, result, trans.arg, result.success);
  },

  /**
   * Callback for write actions
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Object} trans The request transaction object
   * @param {Object} res The server response
   * @protected
   */
  onWrite: function onWrite(action, trans, response, rs) {
    var reader = trans.reader;

    try {
      // though we already have a response object here in STP, run through readResponse to catch any meta-data exceptions.
      var res = reader.readResponse(action, response);
    } catch (e) {
      this.fireEvent('exception', this, 'response', action, trans, res, e);
      trans.callback.call(trans.scope || window, null, res, false);
      return;
    }

    if (!res.success === true) {
      this.fireEvent('exception', this, 'remote', action, trans, res, rs);
      trans.callback.call(trans.scope || window, null, res, false);
      return;
    }

    this.fireEvent("write", this, action, res.data, res, rs, trans.arg);
    trans.callback.call(trans.scope || window, res.data, res, true);
  },
  // private
  isLoading: function isLoading() {
    return this.trans ? true : false;
  },

  /**
   * Abort the current server request.
   */
  abort: function abort() {
    if (this.isLoading()) {
      this.destroyTrans(this.trans);
    }
  },
  // private
  destroyTrans: function destroyTrans(trans, isLoaded) {
    this.head.removeChild(document.getElementById(trans.scriptId));
    clearTimeout(trans.timeoutId);

    if (isLoaded) {
      window[trans.cb] = undefined;

      try {
        delete window[trans.cb];
      } catch (e) {}
    } else {
      // if hasn't been loaded, wait for load to remove it to prevent script error
      window[trans.cb] = function () {
        window[trans.cb] = undefined;

        try {
          delete window[trans.cb];
        } catch (e) {}
      };
    }
  },
  // private
  handleFailure: function handleFailure(trans) {
    this.trans = false;
    this.destroyTrans(trans, false);

    if (trans.action === Ext.data.Api.actions.read) {
      // @deprecated firing loadexception
      this.fireEvent("loadexception", this, null, trans.arg);
    }

    this.fireEvent('exception', this, 'response', trans.action, {
      response: null,
      options: trans.arg
    });
    trans.callback.call(trans.scope || window, null, trans.arg, false);
  },
  // inherit docs
  destroy: function destroy() {
    this.abort();
    Ext.data.ScriptTagProxy.superclass.destroy.call(this);
  }
});

/***/ }),
/* 802 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.HttpProxy
 * @extends Ext.data.DataProxy
 * <p>An implementation of {@link Ext.data.DataProxy} that processes data requests within the same
 * domain of the originating page.</p>
 * <p><b>Note</b>: this class cannot be used to retrieve data from a domain other
 * than the domain from which the running page was served. For cross-domain requests, use a
 * {@link Ext.data.ScriptTagProxy ScriptTagProxy}.</p>
 * <p>Be aware that to enable the browser to parse an XML document, the server must set
 * the Content-Type header in the HTTP response to "<tt>text/xml</tt>".</p>
 * @constructor
 * @param {Object} conn
 * An {@link Ext.data.Connection} object, or options parameter to {@link Ext.Ajax#request}.
 * <p>Note that if this HttpProxy is being used by a {@link Ext.data.Store Store}, then the
 * Store's call to {@link #load} will override any specified <tt>callback</tt> and <tt>params</tt>
 * options. In this case, use the Store's {@link Ext.data.Store#events events} to modify parameters,
 * or react to loading events. The Store's {@link Ext.data.Store#baseParams baseParams} may also be
 * used to pass parameters known at instantiation time.</p>
 * <p>If an options parameter is passed, the singleton {@link Ext.Ajax} object will be used to make
 * the request.</p>
 */
Ext.data.HttpProxy = function (conn) {
  Ext.data.HttpProxy.superclass.constructor.call(this, conn);
  /**
   * The Connection object (Or options parameter to {@link Ext.Ajax#request}) which this HttpProxy
   * uses to make requests to the server. Properties of this object may be changed dynamically to
   * change the way data is requested.
   * @property
   */

  this.conn = conn; // nullify the connection url.  The url param has been copied to 'this' above.  The connection
  // url will be set during each execution of doRequest when buildUrl is called.  This makes it easier for users to override the
  // connection url during beforeaction events (ie: beforeload, beforewrite, etc).
  // Url is always re-defined during doRequest.

  this.conn.url = null;
  this.useAjax = !conn || !conn.events; // A hash containing active requests, keyed on action [Ext.data.Api.actions.create|read|update|destroy]

  var actions = Ext.data.Api.actions;
  this.activeRequest = {};

  for (var verb in actions) {
    this.activeRequest[actions[verb]] = undefined;
  }
};

Ext.extend(Ext.data.HttpProxy, Ext.data.DataProxy, {
  /**
   * Return the {@link Ext.data.Connection} object being used by this Proxy.
   * @return {Connection} The Connection object. This object may be used to subscribe to events on
   * a finer-grained basis than the DataProxy events.
   */
  getConnection: function getConnection() {
    return this.useAjax ? Ext.Ajax : this.conn;
  },

  /**
   * Used for overriding the url used for a single request.  Designed to be called during a beforeaction event.  Calling setUrl
   * will override any urls set via the api configuration parameter.  Set the optional parameter makePermanent to set the url for
   * all subsequent requests.  If not set to makePermanent, the next request will use the same url or api configuration defined
   * in the initial proxy configuration.
   * @param {String} url
   * @param {Boolean} makePermanent (Optional) [false]
   *
   * (e.g.: beforeload, beforesave, etc).
   */
  setUrl: function setUrl(url, makePermanent) {
    this.conn.url = url;

    if (makePermanent === true) {
      this.url = url;
      this.api = null;
      Ext.data.Api.prepare(this);
    }
  },

  /**
   * HttpProxy implementation of DataProxy#doRequest
   * @param {String} action The crud action type (create, read, update, destroy)
   * @param {Ext.data.Record/Ext.data.Record[]} rs If action is load, rs will be null
   * @param {Object} params An object containing properties which are to be used as HTTP parameters
   * for the request to the remote server.
   * @param {Ext.data.DataReader} reader The Reader object which converts the data
   * object into a block of Ext.data.Records.
   * @param {Function} callback
   * <div class="sub-desc"><p>A function to be called after the request.
   * The <tt>callback</tt> is passed the following arguments:<ul>
   * <li><tt>r</tt> : Ext.data.Record[] The block of Ext.data.Records.</li>
   * <li><tt>options</tt>: Options object from the action request</li>
   * <li><tt>success</tt>: Boolean success indicator</li></ul></p></div>
   * @param {Object} scope The scope (<code>this</code> reference) in which the callback function is executed. Defaults to the browser window.
   * @param {Object} arg An optional argument which is passed to the callback as its second parameter.
   * @protected
   */
  doRequest: function doRequest(action, rs, params, reader, cb, scope, arg) {
    var o = {
      method: this.api[action] ? this.api[action]['method'] : undefined,
      request: {
        callback: cb,
        scope: scope,
        arg: arg
      },
      reader: reader,
      callback: this.createCallback(action, rs),
      scope: this
    }; // If possible, transmit data using jsonData || xmlData on Ext.Ajax.request (An installed DataWriter would have written it there.).
    // Use std HTTP params otherwise.

    if (params.jsonData) {
      o.jsonData = params.jsonData;
    } else if (params.xmlData) {
      o.xmlData = params.xmlData;
    } else {
      o.params = params || {};
    } // Set the connection url.  If this.conn.url is not null here,
    // the user must have overridden the url during a beforewrite/beforeload event-handler.
    // this.conn.url is nullified after each request.


    this.conn.url = this.buildUrl(action, rs);

    if (this.useAjax) {
      Ext.applyIf(o, this.conn); // If a currently running request is found for this action, abort it.

      if (this.activeRequest[action]) {////
        // Disabled aborting activeRequest while implementing REST.  activeRequest[action] will have to become an array
        // TODO ideas anyone?
        //
        //Ext.Ajax.abort(this.activeRequest[action]);
      }

      this.activeRequest[action] = Ext.Ajax.request(o);
    } else {
      this.conn.request(o);
    } // request is sent, nullify the connection url in preparation for the next request


    this.conn.url = null;
  },

  /**
   * Returns a callback function for a request.  Note a special case is made for the
   * read action vs all the others.
   * @param {String} action [create|update|delete|load]
   * @param {Ext.data.Record[]} rs The Store-recordset being acted upon
   * @private
   */
  createCallback: function createCallback(action, rs) {
    return function (o, success, response) {
      this.activeRequest[action] = undefined;

      if (!success) {
        if (action === Ext.data.Api.actions.read) {
          // @deprecated: fire loadexception for backwards compat.
          // TODO remove in 3.1
          this.fireEvent('loadexception', this, o, response);
        }

        this.fireEvent('exception', this, 'response', action, o, response);
        o.request.callback.call(o.request.scope, null, o.request.arg, false);
        return;
      }

      if (action === Ext.data.Api.actions.read) {
        this.onRead(action, o, response);
      } else {
        this.onWrite(action, o, response, rs);
      }
    };
  },

  /**
   * Callback for read action
   * @param {String} action Action name as per {@link Ext.data.Api.actions#read}.
   * @param {Object} o The request transaction object
   * @param {Object} res The server response
   * @fires loadexception (deprecated)
   * @fires exception
   * @fires load
   * @protected
   */
  onRead: function onRead(action, o, response) {
    var result;

    try {
      result = o.reader.read(response);
    } catch (e) {
      // @deprecated: fire old loadexception for backwards-compat.
      // TODO remove in 3.1
      this.fireEvent('loadexception', this, o, response, e);
      this.fireEvent('exception', this, 'response', action, o, response, e);
      o.request.callback.call(o.request.scope, null, o.request.arg, false);
      return;
    }

    if (result.success === false) {
      // @deprecated: fire old loadexception for backwards-compat.
      // TODO remove in 3.1
      this.fireEvent('loadexception', this, o, response); // Get DataReader read-back a response-object to pass along to exception event

      var res = o.reader.readResponse(action, response);
      this.fireEvent('exception', this, 'remote', action, o, res, null);
    } else {
      this.fireEvent('load', this, o, o.request.arg);
    } // TODO refactor onRead, onWrite to be more generalized now that we're dealing with Ext.data.Response instance
    // the calls to request.callback(...) in each will have to be made identical.
    // NOTE reader.readResponse does not currently return Ext.data.Response


    o.request.callback.call(o.request.scope, result, o.request.arg, result.success);
  },

  /**
   * Callback for write actions
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Object} trans The request transaction object
   * @param {Object} res The server response
   * @fires exception
   * @fires write
   * @protected
   */
  onWrite: function onWrite(action, o, response, rs) {
    var reader = o.reader;
    var res;

    try {
      res = reader.readResponse(action, response);
    } catch (e) {
      this.fireEvent('exception', this, 'response', action, o, response, e);
      o.request.callback.call(o.request.scope, null, o.request.arg, false);
      return;
    }

    if (res.success === true) {
      this.fireEvent('write', this, action, res.data, res, rs, o.request.arg);
    } else {
      this.fireEvent('exception', this, 'remote', action, o, res, rs);
    } // TODO refactor onRead, onWrite to be more generalized now that we're dealing with Ext.data.Response instance
    // the calls to request.callback(...) in each will have to be made similar.
    // NOTE reader.readResponse does not currently return Ext.data.Response


    o.request.callback.call(o.request.scope, res.data, res, res.success);
  },
  // inherit docs
  destroy: function destroy() {
    if (!this.useAjax) {
      this.conn.abort();
    } else if (this.activeRequest) {
      var actions = Ext.data.Api.actions;

      for (var verb in actions) {
        if (this.activeRequest[actions[verb]]) {
          Ext.Ajax.abort(this.activeRequest[actions[verb]]);
        }
      }
    }

    Ext.data.HttpProxy.superclass.destroy.call(this);
  }
});

/***/ }),
/* 803 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.MemoryProxy
 * @extends Ext.data.DataProxy
 * An implementation of Ext.data.DataProxy that simply passes the data specified in its constructor
 * to the Reader when its load method is called.
 * @constructor
 * @param {Object} data The data object which the Reader uses to construct a block of Ext.data.Records.
 */
Ext.data.MemoryProxy = function (data) {
  // Must define a dummy api with "read" action to satisfy DataProxy#doRequest and Ext.data.Api#prepare *before* calling super
  var api = {};
  api[Ext.data.Api.actions.read] = true;
  Ext.data.MemoryProxy.superclass.constructor.call(this, {
    api: api
  });
  this.data = data;
};

Ext.extend(Ext.data.MemoryProxy, Ext.data.DataProxy, {
  /**
   * @event loadexception
   * Fires if an exception occurs in the Proxy during data loading. Note that this event is also relayed
   * through {@link Ext.data.Store}, so you can listen for it directly on any Store instance.
   * @param {Object} this
   * @param {Object} arg The callback's arg object passed to the {@link #load} function
   * @param {Object} null This parameter does not apply and will always be null for MemoryProxy
   * @param {Error} e The JavaScript Error object caught if the configured Reader could not read the data
   */

  /**
  * MemoryProxy implementation of DataProxy#doRequest
  * @param {String} action
  * @param {Ext.data.Record/Ext.data.Record[]} rs If action is load, rs will be null
  * @param {Object} params An object containing properties which are to be used as HTTP parameters
  * for the request to the remote server.
  * @param {Ext.data.DataReader} reader The Reader object which converts the data
  * object into a block of Ext.data.Records.
  * @param {Function} callback The function into which to pass the block of Ext.data.Records.
  * The function must be passed <ul>
  * <li>The Record block object</li>
  * <li>The "arg" argument from the load function</li>
  * <li>A boolean success indicator</li>
  * </ul>
  * @param {Object} scope The scope (<code>this</code> reference) in which the callback function is executed. Defaults to the browser window.
  * @param {Object} arg An optional argument which is passed to the callback as its second parameter.
  */
  doRequest: function doRequest(action, rs, params, reader, callback, scope, arg) {
    // No implementation for CRUD in MemoryProxy.  Assumes all actions are 'load'
    params = params || {};
    var result;

    try {
      result = reader.readRecords(this.data);
    } catch (e) {
      // @deprecated loadexception
      this.fireEvent("loadexception", this, null, arg, e);
      this.fireEvent('exception', this, 'response', action, arg, null, e);
      callback.call(scope, null, arg, false);
      return;
    }

    callback.call(scope, result, arg, true);
  }
});

/***/ }),
/* 804 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.JsonWriter
 * @extends Ext.data.DataWriter
 * DataWriter extension for writing an array or single {@link Ext.data.Record} object(s) in preparation for executing a remote CRUD action.
 */
Ext.data.JsonWriter = Ext.extend(Ext.data.DataWriter, {
  /**
   * @cfg {Boolean} encode <tt>true</tt> to {@link Ext.util.JSON#encode encode} the
   * {@link Ext.data.DataWriter#toHash hashed data}. Defaults to <tt>true</tt>.  When using
   * {@link Ext.data.DirectProxy}, set this to <tt>false</tt> since Ext.Direct.JsonProvider will perform
   * its own json-encoding.  In addition, if you're using {@link Ext.data.HttpProxy}, setting to <tt>false</tt>
   * will cause HttpProxy to transmit data using the <b>jsonData</b> configuration-params of {@link Ext.Ajax#request}
   * instead of <b>params</b>.  When using a {@link Ext.data.Store#restful} Store, some serverside frameworks are
   * tuned to expect data through the jsonData mechanism.  In those cases, one will want to set <b>encode: <tt>false</tt></b>, as in
   * let the lower-level connection object (eg: Ext.Ajax) do the encoding.
   */
  encode: true,

  /**
   * @cfg {Boolean} encodeDelete False to send only the id to the server on delete, true to encode it in an object
   * literal, eg: <pre><code>
  {id: 1}
  * </code></pre> Defaults to <tt>false</tt>
   */
  encodeDelete: false,
  constructor: function constructor(config) {
    Ext.data.JsonWriter.superclass.constructor.call(this, config);
  },

  /**
   * Final action of a write event.  Apply the written data-object to params.
   * @param {Object} http params-object to write-to.
   * @param {Object} baseParams as defined by {@link Ext.data.Store#baseParams}.  The baseParms must be encoded by the extending class, eg: {@link Ext.data.JsonWriter}, {@link Ext.data.XmlWriter}.
   * @param {Object/Object[]} data Data-object representing compiled Store-recordset.
   */
  render: function render(params, baseParams, data) {
    if (this.encode === true) {
      // Encode here now.
      Ext.apply(params, baseParams);
      params[this.meta.root] = Ext.encode(data);
    } else {
      // defer encoding for some other layer, probably in {@link Ext.Ajax#request}.  Place everything into "jsonData" key.
      var jdata = Ext.apply({}, baseParams);
      jdata[this.meta.root] = data;
      params.jsonData = jdata;
    }
  },

  /**
   * Implements abstract Ext.data.DataWriter#createRecord
   * @protected
   * @param {Ext.data.Record} rec
   * @return {Object}
   */
  createRecord: function createRecord(rec) {
    return this.toHash(rec);
  },

  /**
   * Implements abstract Ext.data.DataWriter#updateRecord
   * @protected
   * @param {Ext.data.Record} rec
   * @return {Object}
   */
  updateRecord: function updateRecord(rec) {
    return this.toHash(rec);
  },

  /**
   * Implements abstract Ext.data.DataWriter#destroyRecord
   * @protected
   * @param {Ext.data.Record} rec
   * @return {Object}
   */
  destroyRecord: function destroyRecord(rec) {
    if (this.encodeDelete) {
      var data = {};
      data[this.meta.idProperty] = rec.id;
      return data;
    } else {
      return rec.id;
    }
  }
});

/***/ }),
/* 805 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.JsonReader
 * @extends Ext.data.DataReader
 * <p>Data reader class to create an Array of {@link Ext.data.Record} objects
 * from a JSON packet based on mappings in a provided {@link Ext.data.Record}
 * constructor.</p>
 * <p>Example code:</p>
 * <pre><code>
var myReader = new Ext.data.JsonReader({
    // metadata configuration options:
    {@link #idProperty}: 'id'
    {@link #root}: 'rows',
    {@link #totalProperty}: 'results',
    {@link Ext.data.DataReader#messageProperty}: "msg"  // The element within the response that provides a user-feedback message (optional)

    // the fields config option will internally create an {@link Ext.data.Record}
    // constructor that provides mapping for reading the record data objects
    {@link Ext.data.DataReader#fields fields}: [
        // map Record&#39;s 'firstname' field to data object&#39;s key of same name
        {name: 'name'},
        // map Record&#39;s 'job' field to data object&#39;s 'occupation' key
        {name: 'job', mapping: 'occupation'}
    ]
});
</code></pre>
 * <p>This would consume a JSON data object of the form:</p><pre><code>
{
    results: 2000, // Reader&#39;s configured {@link #totalProperty}
    rows: [        // Reader&#39;s configured {@link #root}
        // record data objects:
        { {@link #idProperty id}: 1, firstname: 'Bill', occupation: 'Gardener' },
        { {@link #idProperty id}: 2, firstname: 'Ben' , occupation: 'Horticulturalist' },
        ...
    ]
}
</code></pre>
 * <p><b><u>Automatic configuration using metaData</u></b></p>
 * <p>It is possible to change a JsonReader's metadata at any time by including
 * a <b><tt>metaData</tt></b> property in the JSON data object. If the JSON data
 * object has a <b><tt>metaData</tt></b> property, a {@link Ext.data.Store Store}
 * object using this Reader will reconfigure itself to use the newly provided
 * field definition and fire its {@link Ext.data.Store#metachange metachange}
 * event. The metachange event handler may interrogate the <b><tt>metaData</tt></b>
 * property to perform any configuration required.</p>
 * <p>Note that reconfiguring a Store potentially invalidates objects which may
 * refer to Fields or Records which no longer exist.</p>
 * <p>To use this facility you would create the JsonReader like this:</p><pre><code>
var myReader = new Ext.data.JsonReader();
</code></pre>
 * <p>The first data packet from the server would configure the reader by
 * containing a <b><tt>metaData</tt></b> property <b>and</b> the data. For
 * example, the JSON data object might take the form:</p><pre><code>
{
    metaData: {
        "{@link #idProperty}": "id",
        "{@link #root}": "rows",
        "{@link #totalProperty}": "results"
        "{@link #successProperty}": "success",
        "{@link Ext.data.DataReader#fields fields}": [
            {"name": "name"},
            {"name": "job", "mapping": "occupation"}
        ],
        // used by store to set its sortInfo
        "sortInfo":{
           "field": "name",
           "direction": "ASC"
        },
        // {@link Ext.PagingToolbar paging data} (if applicable)
        "start": 0,
        "limit": 2,
        // custom property
        "foo": "bar"
    },
    // Reader&#39;s configured {@link #successProperty}
    "success": true,
    // Reader&#39;s configured {@link #totalProperty}
    "results": 2000,
    // Reader&#39;s configured {@link #root}
    // (this data simulates 2 results {@link Ext.PagingToolbar per page})
    "rows": [ // <b>*Note:</b> this must be an Array
        { "id": 1, "name": "Bill", "occupation": "Gardener" },
        { "id": 2, "name":  "Ben", "occupation": "Horticulturalist" }
    ]
}
 * </code></pre>
 * <p>The <b><tt>metaData</tt></b> property in the JSON data object should contain:</p>
 * <div class="mdetail-params"><ul>
 * <li>any of the configuration options for this class</li>
 * <li>a <b><tt>{@link Ext.data.Record#fields fields}</tt></b> property which
 * the JsonReader will use as an argument to the
 * {@link Ext.data.Record#create data Record create method} in order to
 * configure the layout of the Records it will produce.</li>
 * <li>a <b><tt>{@link Ext.data.Store#sortInfo sortInfo}</tt></b> property
 * which the JsonReader will use to set the {@link Ext.data.Store}'s
 * {@link Ext.data.Store#sortInfo sortInfo} property</li>
 * <li>any custom properties needed</li>
 * </ul></div>
 *
 * @constructor
 * Create a new JsonReader
 * @param {Object} meta Metadata configuration options.
 * @param {Array/Object} recordType
 * <p>Either an Array of {@link Ext.data.Field Field} definition objects (which
 * will be passed to {@link Ext.data.Record#create}, or a {@link Ext.data.Record Record}
 * constructor created from {@link Ext.data.Record#create}.</p>
 */
Ext.data.JsonReader = function (meta, recordType) {
  meta = meta || {};
  /**
   * @cfg {String} idProperty [id] Name of the property within a row object
   * that contains a record identifier value.  Defaults to <tt>id</tt>
   */

  /**
   * @cfg {String} successProperty [success] Name of the property from which to
   * retrieve the success attribute. Defaults to <tt>success</tt>.  See
   * {@link Ext.data.DataProxy}.{@link Ext.data.DataProxy#exception exception}
   * for additional information.
   */

  /**
   * @cfg {String} totalProperty [total] Name of the property from which to
   * retrieve the total number of records in the dataset. This is only needed
   * if the whole dataset is not passed in one go, but is being paged from
   * the remote server.  Defaults to <tt>total</tt>.
   */

  /**
   * @cfg {String} root [undefined] <b>Required</b>.  The name of the property
   * which contains the Array of row objects.  Defaults to <tt>undefined</tt>.
   * An exception will be thrown if the root property is undefined. The data
   * packet value for this property should be an empty array to clear the data
   * or show no data.
   */

  Ext.applyIf(meta, {
    idProperty: 'id',
    successProperty: 'success',
    totalProperty: 'total'
  });
  Ext.data.JsonReader.superclass.constructor.call(this, meta, recordType || meta.fields);
};

Ext.extend(Ext.data.JsonReader, Ext.data.DataReader, {
  /**
   * This JsonReader's metadata as passed to the constructor, or as passed in
   * the last data packet's <b><tt>metaData</tt></b> property.
   * @type Mixed
   * @property meta
   */

  /**
   * This method is only used by a DataProxy which has retrieved data from a remote server.
   * @param {Object} response The XHR object which contains the JSON data in its responseText.
   * @return {Object} data A data block which is used by an Ext.data.Store object as
   * a cache of Ext.data.Records.
   */
  read: function read(response) {
    var json = response.responseText;
    var o = Ext.decode(json);

    if (!o) {
      throw {
        message: 'JsonReader.read: Json object not found'
      };
    }

    return this.readRecords(o);
  },

  /**
   * Decode a json response from server.
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Object} response
   * TODO: refactor code between JsonReader#readRecords, #readResponse into 1 method.
   * there's ugly duplication going on due to maintaining backwards compat. with 2.0.  It's time to do this.
   */
  readResponse: function readResponse(action, response) {
    var o = response.responseText !== undefined ? Ext.decode(response.responseText) : response;

    if (!o) {
      throw new Ext.data.JsonReader.Error('response');
    }

    var root = this.getRoot(o);

    if (action === Ext.data.Api.actions.create) {
      var def = Ext.isDefined(root);

      if (def && Ext.isEmpty(root)) {
        throw new Ext.data.JsonReader.Error('root-empty', this.meta.root);
      } else if (!def) {
        throw new Ext.data.JsonReader.Error('root-undefined-response', this.meta.root);
      }
    } // instantiate response object


    var res = new Ext.data.Response({
      action: action,
      success: this.getSuccess(o),
      data: root ? this.extractData(root, false) : [],
      message: this.getMessage(o),
      raw: o
    }); // blow up if no successProperty

    if (Ext.isEmpty(res.success)) {
      throw new Ext.data.JsonReader.Error('successProperty-response', this.meta.successProperty);
    }

    return res;
  },

  /**
   * Create a data block containing Ext.data.Records from a JSON object.
   * @param {Object} o An object which contains an Array of row objects in the property specified
   * in the config as 'root, and optionally a property, specified in the config as 'totalProperty'
   * which contains the total size of the dataset.
   * @return {Object} data A data block which is used by an Ext.data.Store object as
   * a cache of Ext.data.Records.
   */
  readRecords: function readRecords(o) {
    /**
     * After any data loads, the raw JSON data is available for further custom processing.  If no data is
     * loaded or there is a load exception this property will be undefined.
     * @type Object
     */
    this.jsonData = o;

    if (o.metaData) {
      this.onMetaChange(o.metaData);
    }

    var s = this.meta,
        Record = this.recordType,
        f = Record.prototype.fields,
        fi = f.items,
        fl = f.length,
        v;
    var root = this.getRoot(o),
        c = root.length,
        totalRecords = c,
        success = true;

    if (s.totalProperty) {
      v = parseInt(this.getTotal(o), 10);

      if (!isNaN(v)) {
        totalRecords = v;
      }
    }

    if (s.successProperty) {
      v = this.getSuccess(o);

      if (v === false || v === 'false') {
        success = false;
      }
    } // TODO return Ext.data.Response instance instead.  @see #readResponse


    return {
      success: success,
      records: this.extractData(root, true),
      // <-- true to return [Ext.data.Record]
      totalRecords: totalRecords
    };
  },
  // private
  buildExtractors: function buildExtractors() {
    if (this.ef) {
      return;
    }

    var s = this.meta,
        Record = this.recordType,
        f = Record.prototype.fields,
        fi = f.items,
        fl = f.length;

    if (s.totalProperty) {
      this.getTotal = this.createAccessor(s.totalProperty);
    }

    if (s.successProperty) {
      this.getSuccess = this.createAccessor(s.successProperty);
    }

    if (s.messageProperty) {
      this.getMessage = this.createAccessor(s.messageProperty);
    }

    this.getRoot = s.root ? this.createAccessor(s.root) : function (p) {
      return p;
    };

    if (s.id || s.idProperty) {
      var g = this.createAccessor(s.id || s.idProperty);

      this.getId = function (rec) {
        var r = g(rec);
        return r === undefined || r === '' ? null : r;
      };
    } else {
      this.getId = function () {
        return null;
      };
    }

    var ef = [];

    for (var i = 0; i < fl; i++) {
      f = fi[i];
      var map = f.mapping !== undefined && f.mapping !== null ? f.mapping : f.name;
      ef.push(this.createAccessor(map));
    }

    this.ef = ef;
  },

  /**
   * @ignore
   * TODO This isn't used anywhere??  Don't we want to use this where possible instead of complex #createAccessor?
   */
  simpleAccess: function simpleAccess(obj, subsc) {
    return obj[subsc];
  },

  /**
   * @ignore
   */
  createAccessor: function () {
    var re = /[\[\.]/;
    return function (expr) {
      if (Ext.isEmpty(expr)) {
        return Ext.emptyFn;
      }

      if (Ext.isFunction(expr)) {
        return expr;
      }

      var i = String(expr).search(re);

      if (i >= 0) {
        return new Function('obj', 'return obj' + (i > 0 ? '.' : '') + expr);
      }

      return function (obj) {
        return obj[expr];
      };
    };
  }(),

  /**
   * type-casts a single row of raw-data from server
   * @param {Object} data
   * @param {Array} items
   * @param {Integer} len
   * @private
   */
  extractValues: function extractValues(data, items, len) {
    var f,
        values = {};

    for (var j = 0; j < len; j++) {
      f = items[j];
      var v = this.ef[j](data);
      values[f.name] = f.convert(v !== undefined ? v : f.defaultValue, data);
    }

    return values;
  }
});
/**
 * @class Ext.data.JsonReader.Error
 * Error class for JsonReader
 */

Ext.data.JsonReader.Error = Ext.extend(Ext.Error, {
  constructor: function constructor(message, arg) {
    this.arg = arg;
    Ext.Error.call(this, message);
  },
  name: 'Ext.data.JsonReader'
});
Ext.apply(Ext.data.JsonReader.Error.prototype, {
  lang: {
    'response': 'An error occurred while json-decoding your server response',
    'successProperty-response': 'Could not locate your "successProperty" in your server response.  Please review your JsonReader config to ensure the config-property "successProperty" matches the property in your server-response.  See the JsonReader docs.',
    'root-undefined-config': 'Your JsonReader was configured without a "root" property.  Please review your JsonReader config and make sure to define the root property.  See the JsonReader docs.',
    'idProperty-undefined': 'Your JsonReader was configured without an "idProperty"  Please review your JsonReader configuration and ensure the "idProperty" is set (e.g.: "id").  See the JsonReader docs.',
    'root-empty': 'Data was expected to be returned by the server in the "root" property of the response.  Please review your JsonReader configuration to ensure the "root" property matches that returned in the server-response.  See JsonReader docs.'
  }
});

/***/ }),
/* 806 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.ArrayReader
 * @extends Ext.data.JsonReader
 * <p>Data reader class to create an Array of {@link Ext.data.Record} objects from an Array.
 * Each element of that Array represents a row of data fields. The
 * fields are pulled into a Record object using as a subscript, the <code>mapping</code> property
 * of the field definition if it exists, or the field's ordinal position in the definition.</p>
 * <p>Example code:</p>
 * <pre><code>
var Employee = Ext.data.Record.create([
    {name: 'name', mapping: 1},         // "mapping" only needed if an "id" field is present which
    {name: 'occupation', mapping: 2}    // precludes using the ordinal position as the index.
]);
var myReader = new Ext.data.ArrayReader({
    {@link #idIndex}: 0
}, Employee);
</code></pre>
 * <p>This would consume an Array like this:</p>
 * <pre><code>
[ [1, 'Bill', 'Gardener'], [2, 'Ben', 'Horticulturalist'] ]
 * </code></pre>
 * @constructor
 * Create a new ArrayReader
 * @param {Object} meta Metadata configuration options.
 * @param {Array/Object} recordType
 * <p>Either an Array of {@link Ext.data.Field Field} definition objects (which
 * will be passed to {@link Ext.data.Record#create}, or a {@link Ext.data.Record Record}
 * constructor created from {@link Ext.data.Record#create}.</p>
 */
Ext.data.ArrayReader = Ext.extend(Ext.data.JsonReader, {
  /**
   * @cfg {String} successProperty
   * @hide
   */

  /**
   * @cfg {Number} id (optional) The subscript within row Array that provides an ID for the Record.
   * Deprecated. Use {@link #idIndex} instead.
   */

  /**
   * @cfg {Number} idIndex (optional) The subscript within row Array that provides an ID for the Record.
   */

  /**
   * Create a data block containing Ext.data.Records from an Array.
   * @param {Object} o An Array of row objects which represents the dataset.
   * @return {Object} data A data block which is used by an Ext.data.Store object as
   * a cache of Ext.data.Records.
   */
  readRecords: function readRecords(o) {
    this.arrayData = o;
    var s = this.meta,
        sid = s ? Ext.num(s.idIndex, s.id) : null,
        recordType = this.recordType,
        fields = recordType.prototype.fields,
        records = [],
        success = true,
        v;
    var root = this.getRoot(o);

    for (var i = 0, len = root.length; i < len; i++) {
      var n = root[i],
          values = {},
          id = (sid || sid === 0) && n[sid] !== undefined && n[sid] !== "" ? n[sid] : null;

      for (var j = 0, jlen = fields.length; j < jlen; j++) {
        var f = fields.items[j],
            k = f.mapping !== undefined && f.mapping !== null ? f.mapping : j;
        v = n[k] !== undefined ? n[k] : f.defaultValue;
        v = f.convert(v, n);
        values[f.name] = v;
      }

      var record = new recordType(values, id);
      record.json = n;
      records[records.length] = record;
    }

    var totalRecords = records.length;

    if (s.totalProperty) {
      v = parseInt(this.getTotal(o), 10);

      if (!isNaN(v)) {
        totalRecords = v;
      }
    }

    if (s.successProperty) {
      v = this.getSuccess(o);

      if (v === false || v === 'false') {
        success = false;
      }
    }

    return {
      success: success,
      records: records,
      totalRecords: totalRecords
    };
  }
});

/***/ }),
/* 807 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.ArrayStore
 * @extends Ext.data.Store
 * <p>Formerly known as "SimpleStore".</p>
 * <p>Small helper class to make creating {@link Ext.data.Store}s from Array data easier.
 * An ArrayStore will be automatically configured with a {@link Ext.data.ArrayReader}.</p>
 * <p>A store configuration would be something like:<pre><code>
var store = new Ext.data.ArrayStore({
    // store configs
    autoDestroy: true,
    storeId: 'myStore',
    // reader configs
    idIndex: 0,  
    fields: [
       'company',
       {name: 'price', type: 'float'},
       {name: 'change', type: 'float'},
       {name: 'pctChange', type: 'float'},
       {name: 'lastChange', type: 'date', dateFormat: 'n/j h:ia'}
    ]
});
 * </code></pre></p>
 * <p>This store is configured to consume a returned object of the form:<pre><code>
var myData = [
    ['3m Co',71.72,0.02,0.03,'9/1 12:00am'],
    ['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'],
    ['Boeing Co.',75.43,0.53,0.71,'9/1 12:00am'],
    ['Hewlett-Packard Co.',36.53,-0.03,-0.08,'9/1 12:00am'],
    ['Wal-Mart Stores, Inc.',45.45,0.73,1.63,'9/1 12:00am']
];
 * </code></pre>
 * An object literal of this form could also be used as the {@link #data} config option.</p>
 * <p><b>*Note:</b> Although not listed here, this class accepts all of the configuration options of 
 * <b>{@link Ext.data.ArrayReader ArrayReader}</b>.</p>
 * @constructor
 * @param {Object} config
 * @xtype arraystore
 */
Ext.data.ArrayStore = Ext.extend(Ext.data.Store, {
  /**
   * @cfg {Ext.data.DataReader} reader @hide
   */
  constructor: function constructor(config) {
    Ext.data.ArrayStore.superclass.constructor.call(this, Ext.apply(config, {
      reader: new Ext.data.ArrayReader(config)
    }));
  },
  loadData: function loadData(data, append) {
    if (this.expandData === true) {
      var r = [];

      for (var i = 0, len = data.length; i < len; i++) {
        r[r.length] = [data[i]];
      }

      data = r;
    }

    Ext.data.ArrayStore.superclass.loadData.call(this, data, append);
  }
});
Ext.reg('arraystore', Ext.data.ArrayStore); // backwards compat

Ext.data.SimpleStore = Ext.data.ArrayStore;
Ext.reg('simplestore', Ext.data.SimpleStore);

/***/ }),
/* 808 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.JsonStore
 * @extends Ext.data.Store
 * <p>Small helper class to make creating {@link Ext.data.Store}s from JSON data easier.
 * A JsonStore will be automatically configured with a {@link Ext.data.JsonReader}.</p>
 * <p>A store configuration would be something like:<pre><code>
var store = new Ext.data.JsonStore({
    // store configs
    autoDestroy: true,
    url: 'get-images.php',
    storeId: 'myStore',
    // reader configs
    root: 'images',
    idProperty: 'name',
    fields: ['name', 'url', {name:'size', type: 'float'}, {name:'lastmod', type:'date'}]
});
 * </code></pre></p>
 * <p>This store is configured to consume a returned object of the form:<pre><code>
{
    images: [
        {name: 'Image one', url:'/GetImage.php?id=1', size:46.5, lastmod: new Date(2007, 10, 29)},
        {name: 'Image Two', url:'/GetImage.php?id=2', size:43.2, lastmod: new Date(2007, 10, 30)}
    ]
}
 * </code></pre>
 * An object literal of this form could also be used as the {@link #data} config option.</p>
 * <p><b>*Note:</b> Although not listed here, this class accepts all of the configuration options of
 * <b>{@link Ext.data.JsonReader JsonReader}</b>.</p>
 * @constructor
 * @param {Object} config
 * @xtype jsonstore
 */
Ext.data.JsonStore = Ext.extend(Ext.data.Store, {
  /**
   * @cfg {Ext.data.DataReader} reader @hide
   */
  constructor: function constructor(config) {
    Ext.data.JsonStore.superclass.constructor.call(this, Ext.apply(config, {
      reader: new Ext.data.JsonReader(config)
    }));
  }
});
Ext.reg('jsonstore', Ext.data.JsonStore);

/***/ }),
/* 809 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.XmlWriter
 * @extends Ext.data.DataWriter
 * DataWriter extension for writing an array or single {@link Ext.data.Record} object(s) in preparation for executing a remote CRUD action via XML.
 * XmlWriter uses an instance of {@link Ext.XTemplate} for maximum flexibility in defining your own custom XML schema if the default schema is not appropriate for your needs.
 * See the {@link #tpl} configuration-property.
 */
Ext.data.XmlWriter = function (params) {
  Ext.data.XmlWriter.superclass.constructor.apply(this, arguments); // compile the XTemplate for rendering XML documents.

  this.tpl = typeof this.tpl === 'string' ? new Ext.XTemplate(this.tpl).compile() : this.tpl.compile();
};

Ext.extend(Ext.data.XmlWriter, Ext.data.DataWriter, {
  /**
   * @cfg {String} documentRoot [xrequest] (Optional) The name of the XML document root-node.  <b>Note:</b>
   * this parameter is required </b>only when</b> sending extra {@link Ext.data.Store#baseParams baseParams} to the server
   * during a write-request -- if no baseParams are set, the {@link Ext.data.XmlReader#record} meta-property can
   * suffice as the XML document root-node for write-actions involving just a <b>single record</b>.  For requests
   * involving <b>multiple</b> records and <b>NO</b> baseParams, the {@link Ext.data.XmlWriter#root} property can
   * act as the XML document root.
   */
  documentRoot: 'xrequest',

  /**
   * @cfg {Boolean} forceDocumentRoot [false] Set to <tt>true</tt> to force XML documents having a root-node as defined
   * by {@link #documentRoot}, even with no baseParams defined.
   */
  forceDocumentRoot: false,

  /**
   * @cfg {String} root [records] The name of the containing element which will contain the nodes of an write-action involving <b>multiple</b> records.  Each
   * xml-record written to the server will be wrapped in an element named after {@link Ext.data.XmlReader#record} property.
   * eg:
  <code><pre>
  &lt;?xml version="1.0" encoding="UTF-8"?>
  &lt;user>&lt;first>Barney&lt;/first>&lt;/user>
  </code></pre>
   * However, when <b>multiple</b> records are written in a batch-operation, these records must be wrapped in a containing
   * Element.
   * eg:
  <code><pre>
  &lt;?xml version="1.0" encoding="UTF-8"?>
  &lt;records>
      &lt;first>Barney&lt;/first>&lt;/user>
      &lt;records>&lt;first>Barney&lt;/first>&lt;/user>
  &lt;/records>
  </code></pre>
   * Defaults to <tt>records</tt>.  Do not confuse the nature of this property with that of {@link #documentRoot}
   */
  root: 'records',

  /**
   * @cfg {String} xmlVersion [1.0] The <tt>version</tt> written to header of xml documents.
  <code><pre>&lt;?xml version="1.0" encoding="ISO-8859-15"?></pre></code>
   */
  xmlVersion: '1.0',

  /**
   * @cfg {String} xmlEncoding [ISO-8859-15] The <tt>encoding</tt> written to header of xml documents.
  <code><pre>&lt;?xml version="1.0" encoding="ISO-8859-15"?></pre></code>
   */
  xmlEncoding: 'ISO-8859-15',

  /**
   * @cfg {String/Ext.XTemplate} tpl The XML template used to render {@link Ext.data.Api#actions write-actions} to your server.
   * <p>One can easily provide his/her own custom {@link Ext.XTemplate#constructor template-definition} if the default does not suffice.</p>
   * <p>Defaults to:</p>
  <code><pre>
  &lt;?xml version="{version}" encoding="{encoding}"?>
  &lt;tpl if="documentRoot">&lt;{documentRoot}>
  &lt;tpl for="baseParams">
      &lt;tpl for=".">
          &lt;{name}>{value}&lt;/{name}>
      &lt;/tpl>
  &lt;/tpl>
  &lt;tpl if="records.length &gt; 1">&lt;{root}>',
  &lt;tpl for="records">
      &lt;{parent.record}>
      &lt;tpl for=".">
          &lt;{name}>{value}&lt;/{name}>
      &lt;/tpl>
      &lt;/{parent.record}>
  &lt;/tpl>
  &lt;tpl if="records.length &gt; 1">&lt;/{root}>&lt;/tpl>
  &lt;tpl if="documentRoot">&lt;/{documentRoot}>&lt;/tpl>
  </pre></code>
   * <p>Templates will be called with the following API</p>
   * <ul>
   * <li>{String} version [1.0] The xml version.</li>
   * <li>{String} encoding [ISO-8859-15] The xml encoding.</li>
   * <li>{String/false} documentRoot The XML document root-node name or <tt>false</tt> if not required.  See {@link #documentRoot} and {@link #forceDocumentRoot}.</li>
   * <li>{String} record The meta-data parameter defined on your {@link Ext.data.XmlReader#record} configuration represents the name of the xml-tag containing each record.</li>
   * <li>{String} root The meta-data parameter defined by {@link Ext.data.XmlWriter#root} configuration-parameter.  Represents the name of the xml root-tag when sending <b>multiple</b> records to the server.</li>
   * <li>{Array} records The records being sent to the server, ie: the subject of the write-action being performed.  The records parameter will be always be an array, even when only a single record is being acted upon.
   *     Each item within the records array will contain an array of field objects having the following properties:
   *     <ul>
   *         <li>{String} name The field-name of the record as defined by your {@link Ext.data.Record#create Ext.data.Record definition}.  The "mapping" property will be used, otherwise it will match the "name" property.  Use this parameter to define the XML tag-name of the property.</li>
   *         <li>{Mixed} value The record value of the field enclosed within XML tags specified by name property above.</li>
   *     </ul></li>
   * <li>{Array} baseParams.  The baseParams as defined upon {@link Ext.data.Store#baseParams}.  Note that the baseParams have been converted into an array of [{name : "foo", value: "bar"}, ...] pairs in the same manner as the <b>records</b> parameter above.  See {@link #documentRoot} and {@link #forceDocumentRoot}.</li>
   * </ul>
   */
  // Break up encoding here in case it's being included by some kind of page that will parse it (eg. PHP)
  tpl: '<tpl for="."><' + '?xml version="{version}" encoding="{encoding}"?' + '><tpl if="documentRoot"><{documentRoot}><tpl for="baseParams"><tpl for="."><{name}>{value}</{name}</tpl></tpl></tpl><tpl if="records.length&gt;1"><{root}></tpl><tpl for="records"><{parent.record}><tpl for="."><{name}>{value}</{name}></tpl></{parent.record}></tpl><tpl if="records.length&gt;1"></{root}></tpl><tpl if="documentRoot"></{documentRoot}></tpl></tpl>',

  /**
   * XmlWriter implementation of the final stage of a write action.
   * @param {Object} params Transport-proxy's (eg: {@link Ext.Ajax#request}) params-object to write-to.
   * @param {Object} baseParams as defined by {@link Ext.data.Store#baseParams}.  The baseParms must be encoded by the extending class, eg: {@link Ext.data.JsonWriter}, {@link Ext.data.XmlWriter}.
   * @param {Object/Object[]} data Data-object representing the compiled Store-recordset.
   */
  render: function render(params, baseParams, data) {
    baseParams = this.toArray(baseParams);
    params.xmlData = this.tpl.applyTemplate({
      version: this.xmlVersion,
      encoding: this.xmlEncoding,
      documentRoot: baseParams.length > 0 || this.forceDocumentRoot === true ? this.documentRoot : false,
      record: this.meta.record,
      root: this.root,
      baseParams: baseParams,
      records: Ext.isArray(data[0]) ? data : [data]
    });
  },

  /**
   * createRecord
   * @protected
   * @param {Ext.data.Record} rec
   * @return {Array} Array of <tt>name:value</tt> pairs for attributes of the {@link Ext.data.Record}.  See {@link Ext.data.DataWriter#toHash}.
   */
  createRecord: function createRecord(rec) {
    return this.toArray(this.toHash(rec));
  },

  /**
   * updateRecord
   * @protected
   * @param {Ext.data.Record} rec
   * @return {Array} Array of {name:value} pairs for attributes of the {@link Ext.data.Record}.  See {@link Ext.data.DataWriter#toHash}.
   */
  updateRecord: function updateRecord(rec) {
    return this.toArray(this.toHash(rec));
  },

  /**
   * destroyRecord
   * @protected
   * @param {Ext.data.Record} rec
   * @return {Array} Array containing a attribute-object (name/value pair) representing the {@link Ext.data.DataReader#idProperty idProperty}.
   */
  destroyRecord: function destroyRecord(rec) {
    var data = {};
    data[this.meta.idProperty] = rec.id;
    return this.toArray(data);
  }
});

/***/ }),
/* 810 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.XmlReader
 * @extends Ext.data.DataReader
 * <p>Data reader class to create an Array of {@link Ext.data.Record} objects from an XML document
 * based on mappings in a provided {@link Ext.data.Record} constructor.</p>
 * <p><b>Note</b>: that in order for the browser to parse a returned XML document, the Content-Type
 * header in the HTTP response must be set to "text/xml" or "application/xml".</p>
 * <p>Example code:</p>
 * <pre><code>
var Employee = Ext.data.Record.create([
   {name: 'name', mapping: 'name'},     // "mapping" property not needed if it is the same as "name"
   {name: 'occupation'}                 // This field will use "occupation" as the mapping.
]);
var myReader = new Ext.data.XmlReader({
   totalProperty: "results", // The element which contains the total dataset size (optional)
   record: "row",           // The repeated element which contains row information
   idProperty: "id"         // The element within the row that provides an ID for the record (optional)
   messageProperty: "msg"   // The element within the response that provides a user-feedback message (optional)
}, Employee);
</code></pre>
 * <p>
 * This would consume an XML file like this:
 * <pre><code>
&lt;?xml version="1.0" encoding="UTF-8"?>
&lt;dataset>
 &lt;results>2&lt;/results>
 &lt;row>
   &lt;id>1&lt;/id>
   &lt;name>Bill&lt;/name>
   &lt;occupation>Gardener&lt;/occupation>
 &lt;/row>
 &lt;row>
   &lt;id>2&lt;/id>
   &lt;name>Ben&lt;/name>
   &lt;occupation>Horticulturalist&lt;/occupation>
 &lt;/row>
&lt;/dataset>
</code></pre>
 * @cfg {String} totalProperty The DomQuery path from which to retrieve the total number of records
 * in the dataset. This is only needed if the whole dataset is not passed in one go, but is being
 * paged from the remote server.
 * @cfg {String} record The DomQuery path to the repeated element which contains record information.
 * @cfg {String} record The DomQuery path to the repeated element which contains record information.
 * @cfg {String} successProperty The DomQuery path to the success attribute used by forms.
 * @cfg {String} idPath The DomQuery path relative from the record element to the element that contains
 * a record identifier value.
 * @constructor
 * Create a new XmlReader.
 * @param {Object} meta Metadata configuration options
 * @param {Object} recordType Either an Array of field definition objects as passed to
 * {@link Ext.data.Record#create}, or a Record constructor object created using {@link Ext.data.Record#create}.
 */
Ext.data.XmlReader = function (meta, recordType) {
  meta = meta || {}; // backwards compat, convert idPath or id / success

  Ext.applyIf(meta, {
    idProperty: meta.idProperty || meta.idPath || meta.id,
    successProperty: meta.successProperty || meta.success
  });
  Ext.data.XmlReader.superclass.constructor.call(this, meta, recordType || meta.fields);
};

Ext.extend(Ext.data.XmlReader, Ext.data.DataReader, {
  /**
   * This method is only used by a DataProxy which has retrieved data from a remote server.
   * @param {Object} response The XHR object which contains the parsed XML document.  The response is expected
   * to contain a property called <tt>responseXML</tt> which refers to an XML document object.
   * @return {Object} records A data block which is used by an {@link Ext.data.Store} as
   * a cache of Ext.data.Records.
   */
  read: function read(response) {
    var doc = response.responseXML;

    if (!doc) {
      throw {
        message: "XmlReader.read: XML Document not available"
      };
    }

    return this.readRecords(doc);
  },

  /**
   * Create a data block containing Ext.data.Records from an XML document.
   * @param {Object} doc A parsed XML document.
   * @return {Object} records A data block which is used by an {@link Ext.data.Store} as
   * a cache of Ext.data.Records.
   */
  readRecords: function readRecords(doc) {
    /**
     * After any data loads/reads, the raw XML Document is available for further custom processing.
     * @type XMLDocument
     */
    this.xmlData = doc;
    var root = doc.documentElement || doc,
        q = Ext.DomQuery,
        totalRecords = 0,
        success = true;

    if (this.meta.totalProperty) {
      totalRecords = this.getTotal(root, 0);
    }

    if (this.meta.successProperty) {
      success = this.getSuccess(root);
    }

    var records = this.extractData(q.select(this.meta.record, root), true); // <-- true to return Ext.data.Record[]
    // TODO return Ext.data.Response instance.  @see #readResponse

    return {
      success: success,
      records: records,
      totalRecords: totalRecords || records.length
    };
  },

  /**
   * Decode a json response from server.
   * @param {String} action [{@link Ext.data.Api#actions} create|read|update|destroy]
   * @param {Object} response HTTP Response object from browser.
   * @return {Ext.data.Response} response Returns an instance of {@link Ext.data.Response}
   */
  readResponse: function readResponse(action, response) {
    var q = Ext.DomQuery,
        doc = response.responseXML; // create general Response instance.

    var res = new Ext.data.Response({
      action: action,
      success: this.getSuccess(doc),
      message: this.getMessage(doc),
      data: this.extractData(q.select(this.meta.record, doc) || q.select(this.meta.root, doc), false),
      raw: doc
    });

    if (Ext.isEmpty(res.success)) {
      throw new Ext.data.DataReader.Error('successProperty-response', this.meta.successProperty);
    } // Create actions from a response having status 200 must return pk


    if (action === Ext.data.Api.actions.create) {
      var def = Ext.isDefined(res.data);

      if (def && Ext.isEmpty(res.data)) {
        throw new Ext.data.JsonReader.Error('root-empty', this.meta.root);
      } else if (!def) {
        throw new Ext.data.JsonReader.Error('root-undefined-response', this.meta.root);
      }
    }

    return res;
  },
  getSuccess: function getSuccess() {
    return true;
  },

  /**
   * build response-data extractor functions.
   * @private
   * @ignore
   */
  buildExtractors: function buildExtractors() {
    if (this.ef) {
      return;
    }

    var s = this.meta,
        Record = this.recordType,
        f = Record.prototype.fields,
        fi = f.items,
        fl = f.length;

    if (s.totalProperty) {
      this.getTotal = this.createAccessor(s.totalProperty);
    }

    if (s.successProperty) {
      this.getSuccess = this.createAccessor(s.successProperty);
    }

    if (s.messageProperty) {
      this.getMessage = this.createAccessor(s.messageProperty);
    }

    this.getRoot = function (res) {
      return !Ext.isEmpty(res[this.meta.record]) ? res[this.meta.record] : res[this.meta.root];
    };

    if (s.idPath || s.idProperty) {
      var g = this.createAccessor(s.idPath || s.idProperty);

      this.getId = function (rec) {
        var id = g(rec) || rec.id;
        return id === undefined || id === '' ? null : id;
      };
    } else {
      this.getId = function () {
        return null;
      };
    }

    var ef = [];

    for (var i = 0; i < fl; i++) {
      f = fi[i];
      var map = f.mapping !== undefined && f.mapping !== null ? f.mapping : f.name;
      ef.push(this.createAccessor(map));
    }

    this.ef = ef;
  },

  /**
   * Creates a function to return some particular key of data from a response.
   * @param {String} key
   * @return {Function}
   * @private
   * @ignore
   */
  createAccessor: function () {
    var q = Ext.DomQuery;
    return function (key) {
      switch (key) {
        case this.meta.totalProperty:
          return function (root, def) {
            return q.selectNumber(key, root, def);
          };
          break;

        case this.meta.successProperty:
          return function (root, def) {
            var sv = q.selectValue(key, root, true);
            var success = sv !== false && sv !== 'false';
            return success;
          };
          break;

        default:
          return function (root, def) {
            return q.selectValue(key, root, def);
          };
          break;
      }
    };
  }(),

  /**
   * extracts values and type-casts a row of data from server, extracted by #extractData
   * @param {Hash} data
   * @param {Ext.data.Field[]} items
   * @param {Number} len
   * @private
   * @ignore
   */
  extractValues: function extractValues(data, items, len) {
    var f,
        values = {};

    for (var j = 0; j < len; j++) {
      f = items[j];
      var v = this.ef[j](data);
      values[f.name] = f.convert(v !== undefined ? v : f.defaultValue, data);
    }

    return values;
  }
});

/***/ }),
/* 811 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.XmlStore
 * @extends Ext.data.Store
 * <p>Small helper class to make creating {@link Ext.data.Store}s from XML data easier.
 * A XmlStore will be automatically configured with a {@link Ext.data.XmlReader}.</p>
 * <p>A store configuration would be something like:<pre><code>
var store = new Ext.data.XmlStore({
    // store configs
    autoDestroy: true,
    storeId: 'myStore',
    url: 'sheldon.xml', // automatically configures a HttpProxy
    // reader configs
    record: 'Item', // records will have an "Item" tag
    idPath: 'ASIN',
    totalRecords: '@TotalResults'
    fields: [
        // set up the fields mapping into the xml doc
        // The first needs mapping, the others are very basic
        {name: 'Author', mapping: 'ItemAttributes > Author'},
        'Title', 'Manufacturer', 'ProductGroup'
    ]
});
 * </code></pre></p>
 * <p>This store is configured to consume a returned object of the form:<pre><code>
&#60?xml version="1.0" encoding="UTF-8"?>
&#60ItemSearchResponse xmlns="http://webservices.amazon.com/AWSECommerceService/2009-05-15">
    &#60Items>
        &#60Request>
            &#60IsValid>True&#60/IsValid>
            &#60ItemSearchRequest>
                &#60Author>Sidney Sheldon&#60/Author>
                &#60SearchIndex>Books&#60/SearchIndex>
            &#60/ItemSearchRequest>
        &#60/Request>
        &#60TotalResults>203&#60/TotalResults>
        &#60TotalPages>21&#60/TotalPages>
        &#60Item>
            &#60ASIN>0446355453&#60/ASIN>
            &#60DetailPageURL>
                http://www.amazon.com/
            &#60/DetailPageURL>
            &#60ItemAttributes>
                &#60Author>Sidney Sheldon&#60/Author>
                &#60Manufacturer>Warner Books&#60/Manufacturer>
                &#60ProductGroup>Book&#60/ProductGroup>
                &#60Title>Master of the Game&#60/Title>
            &#60/ItemAttributes>
        &#60/Item>
    &#60/Items>
&#60/ItemSearchResponse>
 * </code></pre>
 * An object literal of this form could also be used as the {@link #data} config option.</p>
 * <p><b>Note:</b> Although not listed here, this class accepts all of the configuration options of 
 * <b>{@link Ext.data.XmlReader XmlReader}</b>.</p>
 * @constructor
 * @param {Object} config
 * @xtype xmlstore
 */
Ext.data.XmlStore = Ext.extend(Ext.data.Store, {
  /**
   * @cfg {Ext.data.DataReader} reader @hide
   */
  constructor: function constructor(config) {
    Ext.data.XmlStore.superclass.constructor.call(this, Ext.apply(config, {
      reader: new Ext.data.XmlReader(config)
    }));
  }
});
Ext.reg('xmlstore', Ext.data.XmlStore);

/***/ }),
/* 812 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.GroupingStore
 * @extends Ext.data.Store
 * A specialized store implementation that provides for grouping records by one of the available fields. This
 * is usually used in conjunction with an {@link Ext.grid.GroupingView} to proved the data model for
 * a grouped GridPanel.
 * @constructor
 * Creates a new GroupingStore.
 * @param {Object} config A config object containing the objects needed for the Store to access data,
 * and read the data into Records.
 * @xtype groupingstore
 */
Ext.data.GroupingStore = Ext.extend(Ext.data.Store, {
  //inherit docs
  constructor: function constructor(config) {
    Ext.data.GroupingStore.superclass.constructor.call(this, config);
    this.applyGroupField();
  },

  /**
   * @cfg {String} groupField
   * The field name by which to sort the store's data (defaults to '').
   */

  /**
   * @cfg {Boolean} remoteGroup
   * True if the grouping should apply on the server side, false if it is local only (defaults to false).  If the
   * grouping is local, it can be applied immediately to the data.  If it is remote, then it will simply act as a
   * helper, automatically sending the grouping field name as the 'groupBy' param with each XHR call.
   */
  remoteGroup: false,

  /**
   * @cfg {Boolean} groupOnSort
   * True to sort the data on the grouping field when a grouping operation occurs, false to sort based on the
   * existing sort info (defaults to false).
   */
  groupOnSort: false,
  groupDir: 'ASC',

  /**
   * Clears any existing grouping and refreshes the data using the default sort.
   */
  clearGrouping: function clearGrouping() {
    this.groupField = false;

    if (this.remoteGroup) {
      if (this.baseParams) {
        delete this.baseParams.groupBy;
        delete this.baseParams.groupDir;
      }

      var lo = this.lastOptions;

      if (lo && lo.params) {
        delete lo.params.groupBy;
        delete lo.params.groupDir;
      }

      this.reload();
    } else {
      this.applySort();
      this.fireEvent('datachanged', this);
    }
  },

  /**
   * Groups the data by the specified field.
   * @param {String} field The field name by which to sort the store's data
   * @param {Boolean} forceRegroup (optional) True to force the group to be refreshed even if the field passed
   * in is the same as the current grouping field, false to skip grouping on the same field (defaults to false)
   */
  groupBy: function groupBy(field, forceRegroup, direction) {
    direction = direction ? String(direction).toUpperCase() == 'DESC' ? 'DESC' : 'ASC' : this.groupDir;

    if (this.groupField == field && this.groupDir == direction && !forceRegroup) {
      return; // already grouped by this field
    }

    this.groupField = field;
    this.groupDir = direction;
    this.applyGroupField();

    if (this.groupOnSort) {
      this.sort(field, direction);
      return;
    }

    if (this.remoteGroup) {
      this.reload();
    } else {
      var si = this.sortInfo || {};

      if (forceRegroup || si.field != field || si.direction != direction) {
        this.applySort();
      } else {
        this.sortData(field, direction);
      }

      this.fireEvent('datachanged', this);
    }
  },
  // private
  applyGroupField: function applyGroupField() {
    if (this.remoteGroup) {
      if (!this.baseParams) {
        this.baseParams = {};
      }

      Ext.apply(this.baseParams, {
        groupBy: this.groupField,
        groupDir: this.groupDir
      });
      var lo = this.lastOptions;

      if (lo && lo.params) {
        Ext.apply(lo.params, {
          groupBy: this.groupField,
          groupDir: this.groupDir
        });
      }
    }
  },
  // private
  applySort: function applySort() {
    Ext.data.GroupingStore.superclass.applySort.call(this);

    if (!this.groupOnSort && !this.remoteGroup) {
      var gs = this.getGroupState();

      if (gs && (gs != this.sortInfo.field || this.groupDir != this.sortInfo.direction)) {
        this.sortData(this.groupField, this.groupDir);
      }
    }
  },
  // private
  applyGrouping: function applyGrouping(alwaysFireChange) {
    if (this.groupField !== false) {
      this.groupBy(this.groupField, true, this.groupDir);
      return true;
    } else {
      if (alwaysFireChange === true) {
        this.fireEvent('datachanged', this);
      }

      return false;
    }
  },
  // private
  getGroupState: function getGroupState() {
    return this.groupOnSort && this.groupField !== false ? this.sortInfo ? this.sortInfo.field : undefined : this.groupField;
  }
});
Ext.reg('groupingstore', Ext.data.GroupingStore);

/***/ }),
/* 813 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.DirectProxy
 * @extends Ext.data.DataProxy
 */
Ext.data.DirectProxy = function (config) {
  Ext.apply(this, config);

  if (typeof this.paramOrder == 'string') {
    this.paramOrder = this.paramOrder.split(/[\s,|]/);
  }

  Ext.data.DirectProxy.superclass.constructor.call(this, config);
};

Ext.extend(Ext.data.DirectProxy, Ext.data.DataProxy, {
  /**
   * @cfg {Array/String} paramOrder Defaults to <tt>undefined</tt>. A list of params to be executed
   * server side.  Specify the params in the order in which they must be executed on the server-side
   * as either (1) an Array of String values, or (2) a String of params delimited by either whitespace,
   * comma, or pipe. For example,
   * any of the following would be acceptable:<pre><code>
  paramOrder: ['param1','param2','param3']
  paramOrder: 'param1 param2 param3'
  paramOrder: 'param1,param2,param3'
  paramOrder: 'param1|param2|param'
   </code></pre>
   */
  paramOrder: undefined,

  /**
   * @cfg {Boolean} paramsAsHash
   * Send parameters as a collection of named arguments (defaults to <tt>true</tt>). Providing a
   * <tt>{@link #paramOrder}</tt> nullifies this configuration.
   */
  paramsAsHash: true,

  /**
   * @cfg {Function} directFn
   * Function to call when executing a request.  directFn is a simple alternative to defining the api configuration-parameter
   * for Store's which will not implement a full CRUD api.
   */
  directFn: undefined,

  /**
   * DirectProxy implementation of {@link Ext.data.DataProxy#doRequest}
   * @param {String} action The crud action type (create, read, update, destroy)
   * @param {Ext.data.Record/Ext.data.Record[]} rs If action is load, rs will be null
   * @param {Object} params An object containing properties which are to be used as HTTP parameters
   * for the request to the remote server.
   * @param {Ext.data.DataReader} reader The Reader object which converts the data
   * object into a block of Ext.data.Records.
   * @param {Function} callback
   * <div class="sub-desc"><p>A function to be called after the request.
   * The <tt>callback</tt> is passed the following arguments:<ul>
   * <li><tt>r</tt> : Ext.data.Record[] The block of Ext.data.Records.</li>
   * <li><tt>options</tt>: Options object from the action request</li>
   * <li><tt>success</tt>: Boolean success indicator</li></ul></p></div>
   * @param {Object} scope The scope (<code>this</code> reference) in which the callback function is executed. Defaults to the browser window.
   * @param {Object} arg An optional argument which is passed to the callback as its second parameter.
   * @protected
   */
  doRequest: function doRequest(action, rs, params, reader, callback, scope, options) {
    var args = [],
        directFn = this.api[action] || this.directFn;

    switch (action) {
      case Ext.data.Api.actions.create:
        args.push(params.jsonData); // <-- create(Hash)

        break;

      case Ext.data.Api.actions.read:
        // If the method has no parameters, ignore the paramOrder/paramsAsHash.
        if (directFn.directCfg.method.len > 0) {
          if (this.paramOrder) {
            for (var i = 0, len = this.paramOrder.length; i < len; i++) {
              args.push(params[this.paramOrder[i]]);
            }
          } else if (this.paramsAsHash) {
            args.push(params);
          }
        }

        break;

      case Ext.data.Api.actions.update:
        args.push(params.jsonData); // <-- update(Hash/Hash[])

        break;

      case Ext.data.Api.actions.destroy:
        args.push(params.jsonData); // <-- destroy(Int/Int[])

        break;
    }

    var trans = {
      params: params || {},
      request: {
        callback: callback,
        scope: scope,
        arg: options
      },
      reader: reader
    };
    args.push(this.createCallback(action, rs, trans), this);
    directFn.apply(window, args);
  },
  // private
  createCallback: function createCallback(action, rs, trans) {
    return function (result, res) {
      if (!res.status) {
        // @deprecated fire loadexception
        if (action === Ext.data.Api.actions.read) {
          this.fireEvent("loadexception", this, trans, res, null);
        }

        this.fireEvent('exception', this, 'remote', action, trans, res, null);
        trans.request.callback.call(trans.request.scope, null, trans.request.arg, false);
        return;
      }

      if (action === Ext.data.Api.actions.read) {
        this.onRead(action, trans, result, res);
      } else {
        this.onWrite(action, trans, result, res, rs);
      }
    };
  },

  /**
   * Callback for read actions
   * @param {String} action [Ext.data.Api.actions.create|read|update|destroy]
   * @param {Object} trans The request transaction object
   * @param {Object} result Data object picked out of the server-response.
   * @param {Object} res The server response
   * @protected
   */
  onRead: function onRead(action, trans, result, res) {
    var records;

    try {
      records = trans.reader.readRecords(result);
    } catch (ex) {
      // @deprecated: Fire old loadexception for backwards-compat.
      this.fireEvent("loadexception", this, trans, res, ex);
      this.fireEvent('exception', this, 'response', action, trans, res, ex);
      trans.request.callback.call(trans.request.scope, null, trans.request.arg, false);
      return;
    }

    this.fireEvent("load", this, res, trans.request.arg);
    trans.request.callback.call(trans.request.scope, records, trans.request.arg, true);
  },

  /**
   * Callback for write actions
   * @param {String} action [{@link Ext.data.Api#actions create|read|update|destroy}]
   * @param {Object} trans The request transaction object
   * @param {Object} result Data object picked out of the server-response.
   * @param {Object} res The server response
   * @param {Ext.data.Record/[Ext.data.Record]} rs The Store resultset associated with the action.
   * @protected
   */
  onWrite: function onWrite(action, trans, result, res, rs) {
    var data = trans.reader.extractData(result, false);
    this.fireEvent("write", this, action, data, res, rs, trans.request.arg);
    trans.request.callback.call(trans.request.scope, data, res, true);
  }
});

/***/ }),
/* 814 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.DirectStore
 * @extends Ext.data.Store
 * <p>Small helper class to create an {@link Ext.data.Store} configured with an
 * {@link Ext.data.DirectProxy} and {@link Ext.data.JsonReader} to make interacting
 * with an {@link Ext.Direct} Server-side {@link Ext.direct.Provider Provider} easier.
 * To create a different proxy/reader combination create a basic {@link Ext.data.Store}
 * configured as needed.</p>
 *
 * <p><b>*Note:</b> Although they are not listed, this class inherits all of the config options of:</p>
 * <div><ul class="mdetail-params">
 * <li><b>{@link Ext.data.Store Store}</b></li>
 * <div class="sub-desc"><ul class="mdetail-params">
 *
 * </ul></div>
 * <li><b>{@link Ext.data.JsonReader JsonReader}</b></li>
 * <div class="sub-desc"><ul class="mdetail-params">
 * <li><tt><b>{@link Ext.data.JsonReader#root root}</b></tt></li>
 * <li><tt><b>{@link Ext.data.JsonReader#idProperty idProperty}</b></tt></li>
 * <li><tt><b>{@link Ext.data.JsonReader#totalProperty totalProperty}</b></tt></li>
 * </ul></div>
 *
 * <li><b>{@link Ext.data.DirectProxy DirectProxy}</b></li>
 * <div class="sub-desc"><ul class="mdetail-params">
 * <li><tt><b>{@link Ext.data.DirectProxy#directFn directFn}</b></tt></li>
 * <li><tt><b>{@link Ext.data.DirectProxy#paramOrder paramOrder}</b></tt></li>
 * <li><tt><b>{@link Ext.data.DirectProxy#paramsAsHash paramsAsHash}</b></tt></li>
 * </ul></div>
 * </ul></div>
 *
 * @xtype directstore
 *
 * @constructor
 * @param {Object} config
 */
Ext.data.DirectStore = Ext.extend(Ext.data.Store, {
  constructor: function constructor(config) {
    // each transaction upon a singe record will generate a distinct Direct transaction since Direct queues them into one Ajax request.
    var c = Ext.apply({}, {
      batchTransactions: false
    }, config);
    Ext.data.DirectStore.superclass.constructor.call(this, Ext.apply(c, {
      proxy: Ext.isDefined(c.proxy) ? c.proxy : new Ext.data.DirectProxy(Ext.copyTo({}, c, 'paramOrder,paramsAsHash,directFn,api')),
      reader: !Ext.isDefined(c.reader) && c.fields ? new Ext.data.JsonReader(Ext.copyTo({}, c, 'totalProperty,root,idProperty'), c.fields) : c.reader
    }));
  }
});
Ext.reg('directstore', Ext.data.DirectStore);

/***/ }),
/* 815 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Direct
 * @extends Ext.util.Observable
 * <p><b><u>Overview</u></b></p>
 * 
 * <p>Ext.Direct aims to streamline communication between the client and server
 * by providing a single interface that reduces the amount of common code
 * typically required to validate data and handle returned data packets
 * (reading data, error conditions, etc).</p>
 *  
 * <p>The Ext.direct namespace includes several classes for a closer integration
 * with the server-side. The Ext.data namespace also includes classes for working
 * with Ext.data.Stores which are backed by data from an Ext.Direct method.</p>
 * 
 * <p><b><u>Specification</u></b></p>
 * 
 * <p>For additional information consult the 
 * <a href="http://extjs.com/products/extjs/direct.php">Ext.Direct Specification</a>.</p>
 *   
 * <p><b><u>Providers</u></b></p>
 * 
 * <p>Ext.Direct uses a provider architecture, where one or more providers are
 * used to transport data to and from the server. There are several providers
 * that exist in the core at the moment:</p><div class="mdetail-params"><ul>
 * 
 * <li>{@link Ext.direct.JsonProvider JsonProvider} for simple JSON operations</li>
 * <li>{@link Ext.direct.PollingProvider PollingProvider} for repeated requests</li>
 * <li>{@link Ext.direct.RemotingProvider RemotingProvider} exposes server side
 * on the client.</li>
 * </ul></div>
 * 
 * <p>A provider does not need to be invoked directly, providers are added via
 * {@link Ext.Direct}.{@link Ext.Direct#add add}.</p>
 * 
 * <p><b><u>Router</u></b></p>
 * 
 * <p>Ext.Direct utilizes a "router" on the server to direct requests from the client
 * to the appropriate server-side method. Because the Ext.Direct API is completely
 * platform-agnostic, you could completely swap out a Java based server solution
 * and replace it with one that uses C# without changing the client side JavaScript
 * at all.</p>
 * 
 * <p><b><u>Server side events</u></b></p>
 * 
 * <p>Custom events from the server may be handled by the client by adding
 * listeners, for example:</p>
 * <pre><code>
{"type":"event","name":"message","data":"Successfully polled at: 11:19:30 am"}

// add a handler for a 'message' event sent by the server 
Ext.Direct.on('message', function(e){
    out.append(String.format('&lt;p>&lt;i>{0}&lt;/i>&lt;/p>', e.data));
            out.el.scrollTo('t', 100000, true);
});
 * </code></pre>
 * @singleton
 */
Ext.Direct = Ext.extend(Ext.util.Observable, {
  /**
   * Each event type implements a getData() method. The default event types are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>event</tt></b> : Ext.Direct.Event</li>
   * <li><b><tt>exception</tt></b> : Ext.Direct.ExceptionEvent</li>
   * <li><b><tt>rpc</tt></b> : Ext.Direct.RemotingEvent</li>
   * </ul></div>
   * @property eventTypes
   * @type Object
   */

  /**
   * Four types of possible exceptions which can occur:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>Ext.Direct.exceptions.TRANSPORT</tt></b> : 'xhr'</li>
   * <li><b><tt>Ext.Direct.exceptions.PARSE</tt></b> : 'parse'</li>
   * <li><b><tt>Ext.Direct.exceptions.LOGIN</tt></b> : 'login'</li>
   * <li><b><tt>Ext.Direct.exceptions.SERVER</tt></b> : 'exception'</li>
   * </ul></div>
   * @property exceptions
   * @type Object
   */
  exceptions: {
    TRANSPORT: 'xhr',
    PARSE: 'parse',
    LOGIN: 'login',
    SERVER: 'exception'
  },
  // private
  constructor: function constructor() {
    this.addEvents(
    /**
     * @event event
     * Fires after an event.
     * @param {event} e The {@link Ext.Direct#eventTypes Ext.Direct.Event type} that occurred.
     * @param {Ext.direct.Provider} provider The {@link Ext.direct.Provider Provider}.
     */
    'event',
    /**
     * @event exception
     * Fires after an event exception.
     * @param {event} e The {@link Ext.Direct#eventTypes Ext.Direct.Event type} that occurred.
     */
    'exception');
    this.transactions = {};
    this.providers = {};
  },

  /**
   * Adds an Ext.Direct Provider and creates the proxy or stub methods to execute server-side methods.
   * If the provider is not already connected, it will auto-connect.
   * <pre><code>
  var pollProv = new Ext.direct.PollingProvider({
  url: 'php/poll2.php'
  }); 
  Ext.Direct.addProvider(
  {
      "type":"remoting",       // create a {@link Ext.direct.RemotingProvider} 
      "url":"php\/router.php", // url to connect to the Ext.Direct server-side router.
      "actions":{              // each property within the actions object represents a Class 
          "TestAction":[       // array of methods within each server side Class   
          {
              "name":"doEcho", // name of method
              "len":1
          },{
              "name":"multiply",
              "len":1
          },{
              "name":"doForm",
              "formHandler":true, // handle form on server with Ext.Direct.Transaction 
              "len":1
          }]
      },
      "namespace":"myApplication",// namespace to create the Remoting Provider in
  },{
      type: 'polling', // create a {@link Ext.direct.PollingProvider} 
      url:  'php/poll.php'
  },
  pollProv // reference to previously created instance
  );
   * </code></pre>
   * @param {Object/Array} provider Accepts either an Array of Provider descriptions (an instance
   * or config object for a Provider) or any number of Provider descriptions as arguments.  Each
   * Provider description instructs Ext.Direct how to create client-side stub methods.
   */
  addProvider: function addProvider(provider) {
    var a = arguments;

    if (a.length > 1) {
      for (var i = 0, len = a.length; i < len; i++) {
        this.addProvider(a[i]);
      }

      return;
    } // if provider has not already been instantiated


    if (!provider.events) {
      provider = new Ext.Direct.PROVIDERS[provider.type](provider);
    }

    provider.id = provider.id || Ext.id();
    this.providers[provider.id] = provider;
    provider.on('data', this.onProviderData, this);
    provider.on('exception', this.onProviderException, this);

    if (!provider.isConnected()) {
      provider.connect();
    }

    return provider;
  },

  /**
   * Retrieve a {@link Ext.direct.Provider provider} by the
   * <b><tt>{@link Ext.direct.Provider#id id}</tt></b> specified when the provider is
   * {@link #addProvider added}.
   * @param {String} id Unique identifier assigned to the provider when calling {@link #addProvider} 
   */
  getProvider: function getProvider(id) {
    return this.providers[id];
  },
  removeProvider: function removeProvider(id) {
    var provider = id.id ? id : this.providers[id.id];
    provider.un('data', this.onProviderData, this);
    provider.un('exception', this.onProviderException, this);
    delete this.providers[provider.id];
    return provider;
  },
  addTransaction: function addTransaction(t) {
    this.transactions[t.tid] = t;
    return t;
  },
  removeTransaction: function removeTransaction(t) {
    delete this.transactions[t.tid || t];
    return t;
  },
  getTransaction: function getTransaction(tid) {
    return this.transactions[tid.tid || tid];
  },
  onProviderData: function onProviderData(provider, e) {
    if (Ext.isArray(e)) {
      for (var i = 0, len = e.length; i < len; i++) {
        this.onProviderData(provider, e[i]);
      }

      return;
    }

    if (e.name && e.name != 'event' && e.name != 'exception') {
      this.fireEvent(e.name, e);
    } else if (e.type == 'exception') {
      this.fireEvent('exception', e);
    }

    this.fireEvent('event', e, provider);
  },
  createEvent: function createEvent(response, extraProps) {
    return new Ext.Direct.eventTypes[response.type](Ext.apply(response, extraProps));
  }
}); // overwrite impl. with static instance

Ext.Direct = new Ext.Direct();
Ext.Direct.TID = 1;
Ext.Direct.PROVIDERS = {};

/***/ }),
/* 816 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Direct.Transaction
 * @extends Object
 * <p>Supporting Class for Ext.Direct (not intended to be used directly).</p>
 * @constructor
 * @param {Object} config
 */
Ext.Direct.Transaction = function (config) {
  Ext.apply(this, config);
  this.tid = ++Ext.Direct.TID;
  this.retryCount = 0;
};

Ext.Direct.Transaction.prototype = {
  send: function send() {
    this.provider.queueTransaction(this);
  },
  retry: function retry() {
    this.retryCount++;
    this.send();
  },
  getProvider: function getProvider() {
    return this.provider;
  }
};

/***/ }),
/* 817 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.Direct.Event = function (config) {
  Ext.apply(this, config);
};

Ext.Direct.Event.prototype = {
  status: true,
  getData: function getData() {
    return this.data;
  }
};
Ext.Direct.RemotingEvent = Ext.extend(Ext.Direct.Event, {
  type: 'rpc',
  getTransaction: function getTransaction() {
    return this.transaction || Ext.Direct.getTransaction(this.tid);
  }
});
Ext.Direct.ExceptionEvent = Ext.extend(Ext.Direct.RemotingEvent, {
  status: false,
  type: 'exception'
});
Ext.Direct.eventTypes = {
  'rpc': Ext.Direct.RemotingEvent,
  'event': Ext.Direct.Event,
  'exception': Ext.Direct.ExceptionEvent
};

/***/ }),
/* 818 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.direct.Provider
 * @extends Ext.util.Observable
 * <p>Ext.direct.Provider is an abstract class meant to be extended.</p>
 * 
 * <p>For example ExtJs implements the following subclasses:</p>
 * <pre><code>
Provider
|
+---{@link Ext.direct.JsonProvider JsonProvider} 
    |
    +---{@link Ext.direct.PollingProvider PollingProvider}   
    |
    +---{@link Ext.direct.RemotingProvider RemotingProvider}   
 * </code></pre>
 * @abstract
 */
Ext.direct.Provider = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {String} id
   * The unique id of the provider (defaults to an {@link Ext#id auto-assigned id}).
   * You should assign an id if you need to be able to access the provider later and you do
   * not have an object reference available, for example:
   * <pre><code>
  Ext.Direct.addProvider(
  {
      type: 'polling',
      url:  'php/poll.php',
      id:   'poll-provider'
  }
  );
   
  var p = {@link Ext.Direct Ext.Direct}.{@link Ext.Direct#getProvider getProvider}('poll-provider');
  p.disconnect();
   * </code></pre>
   */

  /**
   * @cfg {Number} priority
   * Priority of the request. Lower is higher priority, <tt>0</tt> means "duplex" (always on).
   * All Providers default to <tt>1</tt> except for PollingProvider which defaults to <tt>3</tt>.
   */
  priority: 1,

  /**
   * @cfg {String} type
   * <b>Required</b>, <tt>undefined</tt> by default.  The <tt>type</tt> of provider specified
   * to {@link Ext.Direct Ext.Direct}.{@link Ext.Direct#addProvider addProvider} to create a
   * new Provider. Acceptable values by default are:<div class="mdetail-params"><ul>
   * <li><b><tt>polling</tt></b> : {@link Ext.direct.PollingProvider PollingProvider}</li>
   * <li><b><tt>remoting</tt></b> : {@link Ext.direct.RemotingProvider RemotingProvider}</li>
   * </ul></div>
   */
  // private
  constructor: function constructor(config) {
    Ext.apply(this, config);
    this.addEvents(
    /**
     * @event connect
     * Fires when the Provider connects to the server-side
     * @param {Ext.direct.Provider} provider The {@link Ext.direct.Provider Provider}.
     */
    'connect',
    /**
     * @event disconnect
     * Fires when the Provider disconnects from the server-side
     * @param {Ext.direct.Provider} provider The {@link Ext.direct.Provider Provider}.
     */
    'disconnect',
    /**
     * @event data
     * Fires when the Provider receives data from the server-side
     * @param {Ext.direct.Provider} provider The {@link Ext.direct.Provider Provider}.
     * @param {event} e The {@link Ext.Direct#eventTypes Ext.Direct.Event type} that occurred.
     */
    'data',
    /**
     * @event exception
     * Fires when the Provider receives an exception from the server-side
     */
    'exception');
    Ext.direct.Provider.superclass.constructor.call(this, config);
  },

  /**
   * Returns whether or not the server-side is currently connected.
   * Abstract method for subclasses to implement.
   */
  isConnected: function isConnected() {
    return false;
  },

  /**
   * Abstract methods for subclasses to implement.
   */
  connect: Ext.emptyFn,

  /**
   * Abstract methods for subclasses to implement.
   */
  disconnect: Ext.emptyFn
});

/***/ }),
/* 819 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.direct.JsonProvider
 * @extends Ext.direct.Provider
 */
Ext.direct.JsonProvider = Ext.extend(Ext.direct.Provider, {
  parseResponse: function parseResponse(xhr) {
    if (!Ext.isEmpty(xhr.responseText)) {
      if (typeof xhr.responseText == 'object') {
        return xhr.responseText;
      }

      return Ext.decode(xhr.responseText);
    }

    return null;
  },
  getEvents: function getEvents(xhr) {
    var data = null;

    try {
      data = this.parseResponse(xhr);
    } catch (e) {
      var event = new Ext.Direct.ExceptionEvent({
        data: e,
        xhr: xhr,
        code: Ext.Direct.exceptions.PARSE,
        message: 'Error parsing json response: \n\n ' + data
      });
      return [event];
    }

    var events = [];

    if (Ext.isArray(data)) {
      for (var i = 0, len = data.length; i < len; i++) {
        events.push(Ext.Direct.createEvent(data[i]));
      }
    } else {
      events.push(Ext.Direct.createEvent(data));
    }

    return events;
  }
});

/***/ }),
/* 820 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.direct.PollingProvider
 * @extends Ext.direct.JsonProvider
 *
 * <p>Provides for repetitive polling of the server at distinct {@link #interval intervals}.
 * The initial request for data originates from the client, and then is responded to by the
 * server.</p>
 * 
 * <p>All configurations for the PollingProvider should be generated by the server-side
 * API portion of the Ext.Direct stack.</p>
 *
 * <p>An instance of PollingProvider may be created directly via the new keyword or by simply
 * specifying <tt>type = 'polling'</tt>.  For example:</p>
 * <pre><code>
var pollA = new Ext.direct.PollingProvider({
    type:'polling',
    url: 'php/pollA.php',
});
Ext.Direct.addProvider(pollA);
pollA.disconnect();

Ext.Direct.addProvider(
    {
        type:'polling',
        url: 'php/pollB.php',
        id: 'pollB-provider'
    }
);
var pollB = Ext.Direct.getProvider('pollB-provider');
 * </code></pre>
 */
Ext.direct.PollingProvider = Ext.extend(Ext.direct.JsonProvider, {
  /**
   * @cfg {Number} priority
   * Priority of the request (defaults to <tt>3</tt>). See {@link Ext.direct.Provider#priority}.
   */
  // override default priority
  priority: 3,

  /**
   * @cfg {Number} interval
   * How often to poll the server-side in milliseconds (defaults to <tt>3000</tt> - every
   * 3 seconds).
   */
  interval: 3000,

  /**
   * @cfg {Object} baseParams An object containing properties which are to be sent as parameters
   * on every polling request
   */

  /**
   * @cfg {String/Function} url
   * The url which the PollingProvider should contact with each request. This can also be
   * an imported Ext.Direct method which will accept the baseParams as its only argument.
   */
  // private
  constructor: function constructor(config) {
    Ext.direct.PollingProvider.superclass.constructor.call(this, config);
    this.addEvents(
    /**
     * @event beforepoll
     * Fired immediately before a poll takes place, an event handler can return false
     * in order to cancel the poll.
     * @param {Ext.direct.PollingProvider}
     */
    'beforepoll',
    /**
     * @event poll
     * This event has not yet been implemented.
     * @param {Ext.direct.PollingProvider}
     */
    'poll');
  },
  // inherited
  isConnected: function isConnected() {
    return !!this.pollTask;
  },

  /**
   * Connect to the server-side and begin the polling process. To handle each
   * response subscribe to the data event.
   */
  connect: function connect() {
    if (this.url && !this.pollTask) {
      this.pollTask = Ext.TaskMgr.start({
        run: function run() {
          if (this.fireEvent('beforepoll', this) !== false) {
            if (typeof this.url == 'function') {
              this.url(this.baseParams);
            } else {
              Ext.Ajax.request({
                url: this.url,
                callback: this.onData,
                scope: this,
                params: this.baseParams
              });
            }
          }
        },
        interval: this.interval,
        scope: this
      });
      this.fireEvent('connect', this);
    } else if (!this.url) {
      throw 'Error initializing PollingProvider, no url configured.';
    }
  },

  /**
   * Disconnect from the server-side and stop the polling process. The disconnect
   * event will be fired on a successful disconnect.
   */
  disconnect: function disconnect() {
    if (this.pollTask) {
      Ext.TaskMgr.stop(this.pollTask);
      delete this.pollTask;
      this.fireEvent('disconnect', this);
    }
  },
  // private
  onData: function onData(opt, success, xhr) {
    if (success) {
      var events = this.getEvents(xhr);

      for (var i = 0, len = events.length; i < len; i++) {
        var e = events[i];
        this.fireEvent('data', this, e);
      }
    } else {
      var e = new Ext.Direct.ExceptionEvent({
        data: e,
        code: Ext.Direct.exceptions.TRANSPORT,
        message: 'Unable to connect to the server.',
        xhr: xhr
      });
      this.fireEvent('data', this, e);
    }
  }
});
Ext.Direct.PROVIDERS['polling'] = Ext.direct.PollingProvider;

/***/ }),
/* 821 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.direct.RemotingProvider
 * @extends Ext.direct.JsonProvider
 * 
 * <p>The {@link Ext.direct.RemotingProvider RemotingProvider} exposes access to
 * server side methods on the client (a remote procedure call (RPC) type of
 * connection where the client can initiate a procedure on the server).</p>
 * 
 * <p>This allows for code to be organized in a fashion that is maintainable,
 * while providing a clear path between client and server, something that is
 * not always apparent when using URLs.</p>
 * 
 * <p>To accomplish this the server-side needs to describe what classes and methods
 * are available on the client-side. This configuration will typically be
 * outputted by the server-side Ext.Direct stack when the API description is built.</p>
 */
Ext.direct.RemotingProvider = Ext.extend(Ext.direct.JsonProvider, {
  /**
   * @cfg {Object} actions
   * Object literal defining the server side actions and methods. For example, if
   * the Provider is configured with:
   * <pre><code>
  "actions":{ // each property within the 'actions' object represents a server side Class 
  "TestAction":[ // array of methods within each server side Class to be   
  {              // stubbed out on client
      "name":"doEcho", 
      "len":1            
  },{
      "name":"multiply",// name of method
      "len":2           // The number of parameters that will be used to create an
                        // array of data to send to the server side function.
                        // Ensure the server sends back a Number, not a String. 
  },{
      "name":"doForm",
      "formHandler":true, // direct the client to use specialized form handling method 
      "len":1
  }]
  }
   * </code></pre>
   * <p>Note that a Store is not required, a server method can be called at any time.
   * In the following example a <b>client side</b> handler is used to call the
   * server side method "multiply" in the server-side "TestAction" Class:</p>
   * <pre><code>
  TestAction.multiply(
  2, 4, // pass two arguments to server, so specify len=2
  // callback function after the server is called
  // result: the result returned by the server
  //      e: Ext.Direct.RemotingEvent object
  function(result, e){
      var t = e.getTransaction();
      var action = t.action; // server side Class called
      var method = t.method; // server side method called
      if(e.status){
          var answer = Ext.encode(result); // 8
  
      }else{
          var msg = e.message; // failure message
      }
  }
  );
   * </code></pre>
   * In the example above, the server side "multiply" function will be passed two
   * arguments (2 and 4).  The "multiply" method should return the value 8 which will be
   * available as the <tt>result</tt> in the example above. 
   */

  /**
   * @cfg {String/Object} namespace
   * Namespace for the Remoting Provider (defaults to the browser global scope of <i>window</i>).
   * Explicitly specify the namespace Object, or specify a String to have a
   * {@link Ext#namespace namespace created} implicitly.
   */

  /**
   * @cfg {String} url
   * <b>Required<b>. The url to connect to the {@link Ext.Direct} server-side router. 
   */

  /**
   * @cfg {String} enableUrlEncode
   * Specify which param will hold the arguments for the method.
   * Defaults to <tt>'data'</tt>.
   */

  /**
   * @cfg {Number/Boolean} enableBuffer
   * <p><tt>true</tt> or <tt>false</tt> to enable or disable combining of method
   * calls. If a number is specified this is the amount of time in milliseconds
   * to wait before sending a batched request (defaults to <tt>10</tt>).</p>
   * <br><p>Calls which are received within the specified timeframe will be
   * concatenated together and sent in a single request, optimizing the
   * application by reducing the amount of round trips that have to be made
   * to the server.</p>
   */
  enableBuffer: 10,

  /**
   * @cfg {Number} maxRetries
   * Number of times to re-attempt delivery on failure of a call. Defaults to <tt>1</tt>.
   */
  maxRetries: 1,

  /**
   * @cfg {Number} timeout
   * The timeout to use for each request. Defaults to <tt>undefined</tt>.
   */
  timeout: undefined,
  constructor: function constructor(config) {
    Ext.direct.RemotingProvider.superclass.constructor.call(this, config);
    this.addEvents(
    /**
     * @event beforecall
     * Fires immediately before the client-side sends off the RPC call.
     * By returning false from an event handler you can prevent the call from
     * executing.
     * @param {Ext.direct.RemotingProvider} provider
     * @param {Ext.Direct.Transaction} transaction
     */
    'beforecall',
    /**
     * @event call
     * Fires immediately after the request to the server-side is sent. This does
     * NOT fire after the response has come back from the call.
     * @param {Ext.direct.RemotingProvider} provider
     * @param {Ext.Direct.Transaction} transaction
     */
    'call');
    this.namespace = Ext.isString(this.namespace) ? Ext.ns(this.namespace) : this.namespace || window;
    this.transactions = {};
    this.callBuffer = [];
  },
  // private
  initAPI: function initAPI() {
    var o = this.actions;

    for (var c in o) {
      var cls = this.namespace[c] || (this.namespace[c] = {}),
          ms = o[c];

      for (var i = 0, len = ms.length; i < len; i++) {
        var m = ms[i];
        cls[m.name] = this.createMethod(c, m);
      }
    }
  },
  // inherited
  isConnected: function isConnected() {
    return !!this.connected;
  },
  connect: function connect() {
    if (this.url) {
      this.initAPI();
      this.connected = true;
      this.fireEvent('connect', this);
    } else if (!this.url) {
      throw 'Error initializing RemotingProvider, no url configured.';
    }
  },
  disconnect: function disconnect() {
    if (this.connected) {
      this.connected = false;
      this.fireEvent('disconnect', this);
    }
  },
  onData: function onData(opt, success, xhr) {
    if (success) {
      var events = this.getEvents(xhr);

      for (var i = 0, len = events.length; i < len; i++) {
        var e = events[i],
            t = this.getTransaction(e);
        this.fireEvent('data', this, e);

        if (t) {
          this.doCallback(t, e, true);
          Ext.Direct.removeTransaction(t);
        }
      }
    } else {
      var ts = [].concat(opt.ts);

      for (var i = 0, len = ts.length; i < len; i++) {
        var t = this.getTransaction(ts[i]);

        if (t && t.retryCount < this.maxRetries) {
          t.retry();
        } else {
          var e = new Ext.Direct.ExceptionEvent({
            data: e,
            transaction: t,
            code: Ext.Direct.exceptions.TRANSPORT,
            message: 'Unable to connect to the server.',
            xhr: xhr
          });
          this.fireEvent('data', this, e);

          if (t) {
            this.doCallback(t, e, false);
            Ext.Direct.removeTransaction(t);
          }
        }
      }
    }
  },
  getCallData: function getCallData(t) {
    return {
      action: t.action,
      method: t.method,
      data: t.data,
      type: 'rpc',
      tid: t.tid
    };
  },
  doSend: function doSend(data) {
    var o = {
      url: this.url,
      callback: this.onData,
      scope: this,
      ts: data,
      timeout: this.timeout
    },
        callData;

    if (Ext.isArray(data)) {
      callData = [];

      for (var i = 0, len = data.length; i < len; i++) {
        callData.push(this.getCallData(data[i]));
      }
    } else {
      callData = this.getCallData(data);
    }

    if (this.enableUrlEncode) {
      var params = {};
      params[Ext.isString(this.enableUrlEncode) ? this.enableUrlEncode : 'data'] = Ext.encode(callData);
      o.params = params;
    } else {
      o.jsonData = callData;
    }

    Ext.Ajax.request(o);
  },
  combineAndSend: function combineAndSend() {
    var len = this.callBuffer.length;

    if (len > 0) {
      this.doSend(len == 1 ? this.callBuffer[0] : this.callBuffer);
      this.callBuffer = [];
    }
  },
  queueTransaction: function queueTransaction(t) {
    if (t.form) {
      this.processForm(t);
      return;
    }

    this.callBuffer.push(t);

    if (this.enableBuffer) {
      if (!this.callTask) {
        this.callTask = new Ext.util.DelayedTask(this.combineAndSend, this);
      }

      this.callTask.delay(Ext.isNumber(this.enableBuffer) ? this.enableBuffer : 10);
    } else {
      this.combineAndSend();
    }
  },
  doCall: function doCall(c, m, args) {
    var data = null,
        hs = args[m.len],
        scope = args[m.len + 1];

    if (m.len !== 0) {
      data = args.slice(0, m.len);
    }

    var t = new Ext.Direct.Transaction({
      provider: this,
      args: args,
      action: c,
      method: m.name,
      data: data,
      cb: scope && Ext.isFunction(hs) ? hs.createDelegate(scope) : hs
    });

    if (this.fireEvent('beforecall', this, t) !== false) {
      Ext.Direct.addTransaction(t);
      this.queueTransaction(t);
      this.fireEvent('call', this, t);
    }
  },
  doForm: function doForm(c, m, form, callback, scope) {
    var t = new Ext.Direct.Transaction({
      provider: this,
      action: c,
      method: m.name,
      args: [form, callback, scope],
      cb: scope && Ext.isFunction(callback) ? callback.createDelegate(scope) : callback,
      isForm: true
    });

    if (this.fireEvent('beforecall', this, t) !== false) {
      Ext.Direct.addTransaction(t);
      var isUpload = String(form.getAttribute("enctype")).toLowerCase() == 'multipart/form-data',
          params = {
        extTID: t.tid,
        extAction: c,
        extMethod: m.name,
        extType: 'rpc',
        extUpload: String(isUpload)
      }; // change made from typeof callback check to callback.params
      // to support addl param passing in DirectSubmit EAC 6/2

      Ext.apply(t, {
        form: Ext.getDom(form),
        isUpload: isUpload,
        params: callback && Ext.isObject(callback.params) ? Ext.apply(params, callback.params) : params
      });
      this.fireEvent('call', this, t);
      this.processForm(t);
    }
  },
  processForm: function processForm(t) {
    Ext.Ajax.request({
      url: this.url,
      params: t.params,
      callback: this.onData,
      scope: this,
      form: t.form,
      isUpload: t.isUpload,
      ts: t
    });
  },
  createMethod: function createMethod(c, m) {
    var f;

    if (!m.formHandler) {
      f = function () {
        this.doCall(c, m, Array.prototype.slice.call(arguments, 0));
      }.createDelegate(this);
    } else {
      f = function (form, callback, scope) {
        this.doForm(c, m, form, callback, scope);
      }.createDelegate(this);
    }

    f.directCfg = {
      action: c,
      method: m
    };
    return f;
  },
  getTransaction: function getTransaction(opt) {
    return opt && opt.tid ? Ext.Direct.getTransaction(opt.tid) : null;
  },
  doCallback: function doCallback(t, e) {
    var fn = e.status ? 'success' : 'failure';

    if (t && t.cb) {
      var hs = t.cb,
          result = Ext.isDefined(e.result) ? e.result : e.data;

      if (Ext.isFunction(hs)) {
        hs(result, e);
      } else {
        Ext.callback(hs[fn], hs.scope, [result, e]);
        Ext.callback(hs.callback, hs.scope, [result, e]);
      }
    }
  }
});
Ext.Direct.PROVIDERS['remoting'] = Ext.direct.RemotingProvider;

/***/ }),
/* 822 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Resizable
 * @extends Ext.util.Observable
 * <p>Applies drag handles to an element to make it resizable. The drag handles are inserted into the element 
 * and positioned absolute. Some elements, such as a textarea or image, don't support this. To overcome that, you can wrap
 * the textarea in a div and set 'resizeChild' to true (or to the id of the element), <b>or</b> set wrap:true in your config and
 * the element will be wrapped for you automatically.</p>
 * <p>Here is the list of valid resize handles:</p>
 * <pre>
Value   Description
------  -------------------
 'n'     north
 's'     south
 'e'     east
 'w'     west
 'nw'    northwest
 'sw'    southwest
 'se'    southeast
 'ne'    northeast
 'all'   all
</pre>
 * <p>Here's an example showing the creation of a typical Resizable:</p>
 * <pre><code>
var resizer = new Ext.Resizable('element-id', {
    handles: 'all',
    minWidth: 200,
    minHeight: 100,
    maxWidth: 500,
    maxHeight: 400,
    pinned: true
});
resizer.on('resize', myHandler);
</code></pre>
 * <p>To hide a particular handle, set its display to none in CSS, or through script:<br>
 * resizer.east.setDisplayed(false);</p>
 * @constructor
 * Create a new resizable component
 * @param {Mixed} el The id or element to resize
 * @param {Object} config configuration options
  */
Ext.Resizable = Ext.extend(Ext.util.Observable, {
  constructor: function constructor(el, config) {
    this.el = Ext.get(el);

    if (config && config.wrap) {
      config.resizeChild = this.el;
      this.el = this.el.wrap(typeof config.wrap == 'object' ? config.wrap : {
        cls: 'xresizable-wrap'
      });
      this.el.id = this.el.dom.id = config.resizeChild.id + '-rzwrap';
      this.el.setStyle('overflow', 'hidden');
      this.el.setPositioning(config.resizeChild.getPositioning());
      config.resizeChild.clearPositioning();

      if (!config.width || !config.height) {
        var csize = config.resizeChild.getSize();
        this.el.setSize(csize.width, csize.height);
      }

      if (config.pinned && !config.adjustments) {
        config.adjustments = 'auto';
      }
    }
    /**
     * The proxy Element that is resized in place of the real Element during the resize operation.
     * This may be queried using {@link Ext.Element#getBox} to provide the new area to resize to.
     * Read only.
     * @type Ext.Element.
     * @property proxy
     */


    this.proxy = this.el.createProxy({
      tag: 'div',
      cls: 'x-resizable-proxy',
      id: this.el.id + '-rzproxy'
    }, Ext.getBody());
    this.proxy.unselectable();
    this.proxy.enableDisplayMode('block');
    Ext.apply(this, config);

    if (this.pinned) {
      this.disableTrackOver = true;
      this.el.addClass('x-resizable-pinned');
    } // if the element isn't positioned, make it relative


    var position = this.el.getStyle('position');

    if (position != 'absolute' && position != 'fixed') {
      this.el.setStyle('position', 'relative');
    }

    if (!this.handles) {
      // no handles passed, must be legacy style
      this.handles = 's,e,se';

      if (this.multiDirectional) {
        this.handles += ',n,w';
      }
    }

    if (this.handles == 'all') {
      this.handles = 'n s e w ne nw se sw';
    }

    var hs = this.handles.split(/\s*?[,;]\s*?| /);
    var ps = Ext.Resizable.positions;

    for (var i = 0, len = hs.length; i < len; i++) {
      if (hs[i] && ps[hs[i]]) {
        var pos = ps[hs[i]];
        this[pos] = new Ext.Resizable.Handle(this, pos, this.disableTrackOver, this.transparent, this.handleCls);
      }
    } // legacy


    this.corner = this.southeast;

    if (this.handles.indexOf('n') != -1 || this.handles.indexOf('w') != -1) {
      this.updateBox = true;
    }

    this.activeHandle = null;

    if (this.resizeChild) {
      if (typeof this.resizeChild == 'boolean') {
        this.resizeChild = Ext.get(this.el.dom.firstChild, true);
      } else {
        this.resizeChild = Ext.get(this.resizeChild, true);
      }
    }

    if (this.adjustments == 'auto') {
      var rc = this.resizeChild;
      var hw = this.west,
          he = this.east,
          hn = this.north,
          hs = this.south;

      if (rc && (hw || hn)) {
        rc.position('relative');
        rc.setLeft(hw ? hw.el.getWidth() : 0);
        rc.setTop(hn ? hn.el.getHeight() : 0);
      }

      this.adjustments = [(he ? -he.el.getWidth() : 0) + (hw ? -hw.el.getWidth() : 0), (hn ? -hn.el.getHeight() : 0) + (hs ? -hs.el.getHeight() : 0) - 1];
    }

    if (this.draggable) {
      this.dd = this.dynamic ? this.el.initDD(null) : this.el.initDDProxy(null, {
        dragElId: this.proxy.id
      });
      this.dd.setHandleElId(this.resizeChild ? this.resizeChild.id : this.el.id);

      if (this.constrainTo) {
        this.dd.constrainTo(this.constrainTo);
      }
    }

    this.addEvents(
    /**
     * @event beforeresize
     * Fired before resize is allowed. Set {@link #enabled} to false to cancel resize.
     * @param {Ext.Resizable} this
     * @param {Ext.EventObject} e The mousedown event
     */
    'beforeresize',
    /**
     * @event resize
     * Fired after a resize.
     * @param {Ext.Resizable} this
     * @param {Number} width The new width
     * @param {Number} height The new height
     * @param {Ext.EventObject} e The mouseup event
     */
    'resize');

    if (this.width !== null && this.height !== null) {
      this.resizeTo(this.width, this.height);
    } else {
      this.updateChildSize();
    }

    if (Ext.isIE) {
      this.el.dom.style.zoom = 1;
    }

    Ext.Resizable.superclass.constructor.call(this);
  },

  /**
   * @cfg {Array/String} adjustments String 'auto' or an array [width, height] with values to be <b>added</b> to the
   * resize operation's new size (defaults to <tt>[0, 0]</tt>)
   */
  adjustments: [0, 0],

  /**
   * @cfg {Boolean} animate True to animate the resize (not compatible with dynamic sizing, defaults to false)
   */
  animate: false,

  /**
   * @cfg {Mixed} constrainTo Constrain the resize to a particular element
   */

  /**
   * @cfg {Boolean} disableTrackOver True to disable mouse tracking. This is only applied at config time. (defaults to false)
   */
  disableTrackOver: false,

  /**
   * @cfg {Boolean} draggable Convenience to initialize drag drop (defaults to false)
   */
  draggable: false,

  /**
   * @cfg {Number} duration Animation duration if animate = true (defaults to 0.35)
   */
  duration: 0.35,

  /**
   * @cfg {Boolean} dynamic True to resize the element while dragging instead of using a proxy (defaults to false)
   */
  dynamic: false,

  /**
   * @cfg {String} easing Animation easing if animate = true (defaults to <tt>'easingOutStrong'</tt>)
   */
  easing: 'easeOutStrong',

  /**
   * @cfg {Boolean} enabled False to disable resizing (defaults to true)
   */
  enabled: true,

  /**
   * @property enabled Writable. False if resizing is disabled.
   * @type Boolean 
   */

  /**
   * @cfg {String} handles String consisting of the resize handles to display (defaults to undefined).
   * Specify either <tt>'all'</tt> or any of <tt>'n s e w ne nw se sw'</tt>.
   */
  handles: false,

  /**
   * @cfg {Boolean} multiDirectional <b>Deprecated</b>.  Deprecated style of adding multi-direction resize handles.
   */
  multiDirectional: false,

  /**
   * @cfg {Number} height The height of the element in pixels (defaults to null)
   */
  height: null,

  /**
   * @cfg {Number} width The width of the element in pixels (defaults to null)
   */
  width: null,

  /**
   * @cfg {Number} heightIncrement The increment to snap the height resize in pixels
   * (only applies if <code>{@link #dynamic}==true</code>). Defaults to <tt>0</tt>.
   */
  heightIncrement: 0,

  /**
   * @cfg {Number} widthIncrement The increment to snap the width resize in pixels
   * (only applies if <code>{@link #dynamic}==true</code>). Defaults to <tt>0</tt>.
   */
  widthIncrement: 0,

  /**
   * @cfg {Number} minHeight The minimum height for the element (defaults to 5)
   */
  minHeight: 5,

  /**
   * @cfg {Number} minWidth The minimum width for the element (defaults to 5)
   */
  minWidth: 5,

  /**
   * @cfg {Number} maxHeight The maximum height for the element (defaults to 10000)
   */
  maxHeight: 10000,

  /**
   * @cfg {Number} maxWidth The maximum width for the element (defaults to 10000)
   */
  maxWidth: 10000,

  /**
   * @cfg {Number} minX The minimum x for the element (defaults to 0)
   */
  minX: 0,

  /**
   * @cfg {Number} minY The minimum x for the element (defaults to 0)
   */
  minY: 0,

  /**
   * @cfg {Boolean} pinned True to ensure that the resize handles are always visible, false to display them only when the
   * user mouses over the resizable borders. This is only applied at config time. (defaults to false)
   */
  pinned: false,

  /**
   * @cfg {Boolean} preserveRatio True to preserve the original ratio between height
   * and width during resize (defaults to false)
   */
  preserveRatio: false,

  /**
   * @cfg {Boolean/String/Element} resizeChild True to resize the first child, or id/element to resize (defaults to false) 
   */
  resizeChild: false,

  /**
   * @cfg {Boolean} transparent True for transparent handles. This is only applied at config time. (defaults to false)
   */
  transparent: false,

  /**
   * @cfg {Ext.lib.Region} resizeRegion Constrain the resize to a particular region
   */

  /**
   * @cfg {Boolean} wrap True to wrap an element with a div if needed (required for textareas and images, defaults to false)
   * in favor of the handles config option (defaults to false)
   */

  /**
   * @cfg {String} handleCls A css class to add to each handle. Defaults to <tt>''</tt>.
   */

  /**
   * Perform a manual resize and fires the 'resize' event.
   * @param {Number} width
   * @param {Number} height
   */
  resizeTo: function resizeTo(width, height) {
    this.el.setSize(width, height);
    this.updateChildSize();
    this.fireEvent('resize', this, width, height, null);
  },
  // private
  startSizing: function startSizing(e, handle) {
    this.fireEvent('beforeresize', this, e);

    if (this.enabled) {
      // 2nd enabled check in case disabled before beforeresize handler
      if (!this.overlay) {
        this.overlay = this.el.createProxy({
          tag: 'div',
          cls: 'x-resizable-overlay',
          html: '&#160;'
        }, Ext.getBody());
        this.overlay.unselectable();
        this.overlay.enableDisplayMode('block');
        this.overlay.on({
          scope: this,
          mousemove: this.onMouseMove,
          mouseup: this.onMouseUp
        });
      }

      this.overlay.setStyle('cursor', handle.el.getStyle('cursor'));
      this.resizing = true;
      this.startBox = this.el.getBox();
      this.startPoint = e.getXY();
      this.offsets = [this.startBox.x + this.startBox.width - this.startPoint[0], this.startBox.y + this.startBox.height - this.startPoint[1]];
      this.overlay.setSize(Ext.lib.Dom.getViewWidth(true), Ext.lib.Dom.getViewHeight(true));
      this.overlay.show();

      if (this.constrainTo) {
        var ct = Ext.get(this.constrainTo);
        this.resizeRegion = ct.getRegion().adjust(ct.getFrameWidth('t'), ct.getFrameWidth('l'), -ct.getFrameWidth('b'), -ct.getFrameWidth('r'));
      }

      this.proxy.setStyle('visibility', 'hidden'); // workaround display none

      this.proxy.show();
      this.proxy.setBox(this.startBox);

      if (!this.dynamic) {
        this.proxy.setStyle('visibility', 'visible');
      }
    }
  },
  // private
  onMouseDown: function onMouseDown(handle, e) {
    if (this.enabled) {
      e.stopEvent();
      this.activeHandle = handle;
      this.startSizing(e, handle);
    }
  },
  // private
  onMouseUp: function onMouseUp(e) {
    this.activeHandle = null;
    var size = this.resizeElement();
    this.resizing = false;
    this.handleOut();
    this.overlay.hide();
    this.proxy.hide();
    this.fireEvent('resize', this, size.width, size.height, e);
  },
  // private
  updateChildSize: function updateChildSize() {
    if (this.resizeChild) {
      var el = this.el;
      var child = this.resizeChild;
      var adj = this.adjustments;

      if (el.dom.offsetWidth) {
        var b = el.getSize(true);
        child.setSize(b.width + adj[0], b.height + adj[1]);
      } // Second call here for IE
      // The first call enables instant resizing and
      // the second call corrects scroll bars if they
      // exist


      if (Ext.isIE) {
        setTimeout(function () {
          if (el.dom.offsetWidth) {
            var b = el.getSize(true);
            child.setSize(b.width + adj[0], b.height + adj[1]);
          }
        }, 10);
      }
    }
  },
  // private
  snap: function snap(value, inc, min) {
    if (!inc || !value) {
      return value;
    }

    var newValue = value;
    var m = value % inc;

    if (m > 0) {
      if (m > inc / 2) {
        newValue = value + (inc - m);
      } else {
        newValue = value - m;
      }
    }

    return Math.max(min, newValue);
  },

  /**
   * <p>Performs resizing of the associated Element. This method is called internally by this
   * class, and should not be called by user code.</p>
   * <p>If a Resizable is being used to resize an Element which encapsulates a more complex UI
   * component such as a Panel, this method may be overridden by specifying an implementation
   * as a config option to provide appropriate behaviour at the end of the resize operation on
   * mouseup, for example resizing the Panel, and relaying the Panel's content.</p>
   * <p>The new area to be resized to is available by examining the state of the {@link #proxy}
   * Element. Example:
  <pre><code>
  new Ext.Panel({
  title: 'Resize me',
  x: 100,
  y: 100,
  renderTo: Ext.getBody(),
  floating: true,
  frame: true,
  width: 400,
  height: 200,
  listeners: {
      render: function(p) {
          new Ext.Resizable(p.getEl(), {
              handles: 'all',
              pinned: true,
              transparent: true,
              resizeElement: function() {
                  var box = this.proxy.getBox();
                  p.updateBox(box);
                  if (p.layout) {
                      p.doLayout();
                  }
                  return box;
              }
         });
     }
  }
  }).show();
  </code></pre>
   */
  resizeElement: function resizeElement() {
    var box = this.proxy.getBox();

    if (this.updateBox) {
      this.el.setBox(box, false, this.animate, this.duration, null, this.easing);
    } else {
      this.el.setSize(box.width, box.height, this.animate, this.duration, null, this.easing);
    }

    this.updateChildSize();

    if (!this.dynamic) {
      this.proxy.hide();
    }

    if (this.draggable && this.constrainTo) {
      this.dd.resetConstraints();
      this.dd.constrainTo(this.constrainTo);
    }

    return box;
  },
  // private
  constrain: function constrain(v, diff, m, mx) {
    if (v - diff < m) {
      diff = v - m;
    } else if (v - diff > mx) {
      diff = v - mx;
    }

    return diff;
  },
  // private
  onMouseMove: function onMouseMove(e) {
    if (this.enabled && this.activeHandle) {
      try {
        // try catch so if something goes wrong the user doesn't get hung
        if (this.resizeRegion && !this.resizeRegion.contains(e.getPoint())) {
          return;
        } //var curXY = this.startPoint;


        var curSize = this.curSize || this.startBox,
            x = this.startBox.x,
            y = this.startBox.y,
            ox = x,
            oy = y,
            w = curSize.width,
            h = curSize.height,
            ow = w,
            oh = h,
            mw = this.minWidth,
            mh = this.minHeight,
            mxw = this.maxWidth,
            mxh = this.maxHeight,
            wi = this.widthIncrement,
            hi = this.heightIncrement,
            eventXY = e.getXY(),
            diffX = -(this.startPoint[0] - Math.max(this.minX, eventXY[0])),
            diffY = -(this.startPoint[1] - Math.max(this.minY, eventXY[1])),
            pos = this.activeHandle.position,
            tw,
            th;

        switch (pos) {
          case 'east':
            w += diffX;
            w = Math.min(Math.max(mw, w), mxw);
            break;

          case 'south':
            h += diffY;
            h = Math.min(Math.max(mh, h), mxh);
            break;

          case 'southeast':
            w += diffX;
            h += diffY;
            w = Math.min(Math.max(mw, w), mxw);
            h = Math.min(Math.max(mh, h), mxh);
            break;

          case 'north':
            diffY = this.constrain(h, diffY, mh, mxh);
            y += diffY;
            h -= diffY;
            break;

          case 'west':
            diffX = this.constrain(w, diffX, mw, mxw);
            x += diffX;
            w -= diffX;
            break;

          case 'northeast':
            w += diffX;
            w = Math.min(Math.max(mw, w), mxw);
            diffY = this.constrain(h, diffY, mh, mxh);
            y += diffY;
            h -= diffY;
            break;

          case 'northwest':
            diffX = this.constrain(w, diffX, mw, mxw);
            diffY = this.constrain(h, diffY, mh, mxh);
            y += diffY;
            h -= diffY;
            x += diffX;
            w -= diffX;
            break;

          case 'southwest':
            diffX = this.constrain(w, diffX, mw, mxw);
            h += diffY;
            h = Math.min(Math.max(mh, h), mxh);
            x += diffX;
            w -= diffX;
            break;
        }

        var sw = this.snap(w, wi, mw);
        var sh = this.snap(h, hi, mh);

        if (sw != w || sh != h) {
          switch (pos) {
            case 'northeast':
              y -= sh - h;
              break;

            case 'north':
              y -= sh - h;
              break;

            case 'southwest':
              x -= sw - w;
              break;

            case 'west':
              x -= sw - w;
              break;

            case 'northwest':
              x -= sw - w;
              y -= sh - h;
              break;
          }

          w = sw;
          h = sh;
        }

        if (this.preserveRatio) {
          switch (pos) {
            case 'southeast':
            case 'east':
              h = oh * (w / ow);
              h = Math.min(Math.max(mh, h), mxh);
              w = ow * (h / oh);
              break;

            case 'south':
              w = ow * (h / oh);
              w = Math.min(Math.max(mw, w), mxw);
              h = oh * (w / ow);
              break;

            case 'northeast':
              w = ow * (h / oh);
              w = Math.min(Math.max(mw, w), mxw);
              h = oh * (w / ow);
              break;

            case 'north':
              tw = w;
              w = ow * (h / oh);
              w = Math.min(Math.max(mw, w), mxw);
              h = oh * (w / ow);
              x += (tw - w) / 2;
              break;

            case 'southwest':
              h = oh * (w / ow);
              h = Math.min(Math.max(mh, h), mxh);
              tw = w;
              w = ow * (h / oh);
              x += tw - w;
              break;

            case 'west':
              th = h;
              h = oh * (w / ow);
              h = Math.min(Math.max(mh, h), mxh);
              y += (th - h) / 2;
              tw = w;
              w = ow * (h / oh);
              x += tw - w;
              break;

            case 'northwest':
              tw = w;
              th = h;
              h = oh * (w / ow);
              h = Math.min(Math.max(mh, h), mxh);
              w = ow * (h / oh);
              y += th - h;
              x += tw - w;
              break;
          }
        }

        this.proxy.setBounds(x, y, w, h);

        if (this.dynamic) {
          this.resizeElement();
        }
      } catch (ex) {}
    }
  },
  // private
  handleOver: function handleOver() {
    if (this.enabled) {
      this.el.addClass('x-resizable-over');
    }
  },
  // private
  handleOut: function handleOut() {
    if (!this.resizing) {
      this.el.removeClass('x-resizable-over');
    }
  },

  /**
   * Returns the element this component is bound to.
   * @return {Ext.Element}
   */
  getEl: function getEl() {
    return this.el;
  },

  /**
   * Returns the resizeChild element (or null).
   * @return {Ext.Element}
   */
  getResizeChild: function getResizeChild() {
    return this.resizeChild;
  },

  /**
   * Destroys this resizable. If the element was wrapped and 
   * removeEl is not true then the element remains.
   * @param {Boolean} removeEl (optional) true to remove the element from the DOM
   */
  destroy: function destroy(removeEl) {
    Ext.destroy(this.dd, this.overlay, this.proxy);
    this.overlay = null;
    this.proxy = null;
    var ps = Ext.Resizable.positions;

    for (var k in ps) {
      if (typeof ps[k] != 'function' && this[ps[k]]) {
        this[ps[k]].destroy();
      }
    }

    if (removeEl) {
      this.el.update('');
      Ext.destroy(this.el);
      this.el = null;
    }

    this.purgeListeners();
  },
  syncHandleHeight: function syncHandleHeight() {
    var h = this.el.getHeight(true);

    if (this.west) {
      this.west.el.setHeight(h);
    }

    if (this.east) {
      this.east.el.setHeight(h);
    }
  }
}); // private
// hash to map config positions to true positions

Ext.Resizable.positions = {
  n: 'north',
  s: 'south',
  e: 'east',
  w: 'west',
  se: 'southeast',
  sw: 'southwest',
  nw: 'northwest',
  ne: 'northeast'
};
Ext.Resizable.Handle = Ext.extend(Object, {
  constructor: function constructor(rz, pos, disableTrackOver, transparent, cls) {
    if (!this.tpl) {
      // only initialize the template if resizable is used
      var tpl = Ext.DomHelper.createTemplate({
        tag: 'div',
        cls: 'x-resizable-handle x-resizable-handle-{0}'
      });
      tpl.compile();
      Ext.Resizable.Handle.prototype.tpl = tpl;
    }

    this.position = pos;
    this.rz = rz;
    this.el = this.tpl.append(rz.el.dom, [this.position], true);
    this.el.unselectable();

    if (transparent) {
      this.el.setOpacity(0);
    }

    if (!Ext.isEmpty(cls)) {
      this.el.addClass(cls);
    }

    this.el.on('mousedown', this.onMouseDown, this);

    if (!disableTrackOver) {
      this.el.on({
        scope: this,
        mouseover: this.onMouseOver,
        mouseout: this.onMouseOut
      });
    }
  },
  // private
  afterResize: function afterResize(rz) {// do nothing    
  },
  // private
  onMouseDown: function onMouseDown(e) {
    this.rz.onMouseDown(this, e);
  },
  // private
  onMouseOver: function onMouseOver(e) {
    this.rz.handleOver(this, e);
  },
  // private
  onMouseOut: function onMouseOut(e) {
    this.rz.handleOut(this, e);
  },
  // private
  destroy: function destroy() {
    Ext.destroy(this.el);
    this.el = null;
  }
});

/***/ }),
/* 823 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Window
 * @extends Ext.Panel
 * <p>A specialized panel intended for use as an application window.  Windows are floated, {@link #resizable}, and
 * {@link #draggable} by default.  Windows can be {@link #maximizable maximized} to fill the viewport,
 * restored to their prior size, and can be {@link #minimize}d.</p>
 * <p>Windows can also be linked to a {@link Ext.WindowGroup} or managed by the {@link Ext.WindowMgr} to provide
 * grouping, activation, to front, to back and other application-specific behavior.</p>
 * <p>By default, Windows will be rendered to document.body. To {@link #constrain} a Window to another element
 * specify {@link Ext.Component#renderTo renderTo}.</p>
 * <p><b>Note:</b> By default, the <code>{@link #closable close}</code> header tool <i>destroys</i> the Window resulting in
 * destruction of any child Components. This makes the Window object, and all its descendants <b>unusable</b>. To enable
 * re-use of a Window, use <b><code>{@link #closeAction closeAction: 'hide'}</code></b>.</p>
 * @constructor
 * @param {Object} config The config object
 * @xtype window
 */
Ext.Window = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Number} x
   * The X position of the left edge of the window on initial showing. Defaults to centering the Window within
   * the width of the Window's container {@link Ext.Element Element) (The Element that the Window is rendered to).
   */

  /**
   * @cfg {Number} y
   * The Y position of the top edge of the window on initial showing. Defaults to centering the Window within
   * the height of the Window's container {@link Ext.Element Element) (The Element that the Window is rendered to).
   */

  /**
   * @cfg {Boolean} modal
   * True to make the window modal and mask everything behind it when displayed, false to display it without
   * restricting access to other UI elements (defaults to false).
   */

  /**
   * @cfg {String/Element} animateTarget
   * Id or element from which the window should animate while opening (defaults to null with no animation).
   */

  /**
   * @cfg {String} resizeHandles
   * A valid {@link Ext.Resizable} handles config string (defaults to 'all').  Only applies when resizable = true.
   */

  /**
   * @cfg {Ext.WindowGroup} manager
   * A reference to the WindowGroup that should manage this window (defaults to {@link Ext.WindowMgr}).
   */

  /**
  * @cfg {String/Number/Component} defaultButton
  * <p>Specifies a Component to receive focus when this Window is focussed.</p>
  * <p>This may be one of:</p><div class="mdetail-params"><ul>
  * <li>The index of a footer Button.</li>
  * <li>The id of a Component.</li>
  * <li>A Component.</li>
  * </ul></div>
  */

  /**
  * @cfg {Function} onEsc
  * Allows override of the built-in processing for the escape key. Default action
  * is to close the Window (performing whatever action is specified in {@link #closeAction}.
  * To prevent the Window closing when the escape key is pressed, specify this as
  * Ext.emptyFn (See {@link Ext#emptyFn}).
  */

  /**
   * @cfg {Boolean} collapsed
   * True to render the window collapsed, false to render it expanded (defaults to false). Note that if
   * {@link #expandOnShow} is true (the default) it will override the <tt>collapsed</tt> config and the window
   * will always be expanded when shown.
   */

  /**
   * @cfg {Boolean} maximized
   * True to initially display the window in a maximized state. (Defaults to false).
   */

  /**
  * @cfg {String} baseCls
  * The base CSS class to apply to this panel's element (defaults to 'x-window').
  */
  baseCls: 'x-window',

  /**
   * @cfg {Boolean} resizable
   * True to allow user resizing at each edge and corner of the window, false to disable resizing (defaults to true).
   */
  resizable: true,

  /**
   * @cfg {Boolean} draggable
   * True to allow the window to be dragged by the header bar, false to disable dragging (defaults to true).  Note
   * that by default the window will be centered in the viewport, so if dragging is disabled the window may need
   * to be positioned programmatically after render (e.g., myWindow.setPosition(100, 100);).
   */
  draggable: true,

  /**
   * @cfg {Boolean} closable
   * <p>True to display the 'close' tool button and allow the user to close the window, false to
   * hide the button and disallow closing the window (defaults to true).</p>
   * <p>By default, when close is requested by either clicking the close button in the header
   * or pressing ESC when the Window has focus, the {@link #close} method will be called. This
   * will <i>{@link Ext.Component#destroy destroy}</i> the Window and its content meaning that
   * it may not be reused.</p>
   * <p>To make closing a Window <i>hide</i> the Window so that it may be reused, set
   * {@link #closeAction} to 'hide'.
   */
  closable: true,

  /**
   * @cfg {String} closeAction
   * <p>The action to take when the close header tool is clicked:
   * <div class="mdetail-params"><ul>
   * <li><b><code>'{@link #close}'</code></b> : <b>Default</b><div class="sub-desc">
   * {@link #close remove} the window from the DOM and {@link Ext.Component#destroy destroy}
   * it and all descendant Components. The window will <b>not</b> be available to be
   * redisplayed via the {@link #show} method.
   * </div></li>
   * <li><b><code>'{@link #hide}'</code></b> : <div class="sub-desc">
   * {@link #hide} the window by setting visibility to hidden and applying negative offsets.
   * The window will be available to be redisplayed via the {@link #show} method.
   * </div></li>
   * </ul></div>
   * <p><b>Note:</b> This setting does not affect the {@link #close} method
   * which will always {@link Ext.Component#destroy destroy} the window. To
   * programatically <i>hide</i> a window, call {@link #hide}.</p>
   */
  closeAction: 'close',

  /**
   * @cfg {Boolean} constrain
   * True to constrain the window within its containing element, false to allow it to fall outside of its
   * containing element. By default the window will be rendered to document.body.  To render and constrain the
   * window within another element specify {@link #renderTo}.
   * (defaults to false).  Optionally the header only can be constrained using {@link #constrainHeader}.
   */
  constrain: false,

  /**
   * @cfg {Boolean} constrainHeader
   * True to constrain the window header within its containing element (allowing the window body to fall outside
   * of its containing element) or false to allow the header to fall outside its containing element (defaults to
   * false). Optionally the entire window can be constrained using {@link #constrain}.
   */
  constrainHeader: false,

  /**
   * @cfg {Boolean} plain
   * True to render the window body with a transparent background so that it will blend into the framing
   * elements, false to add a lighter background color to visually highlight the body element and separate it
   * more distinctly from the surrounding frame (defaults to false).
   */
  plain: false,

  /**
   * @cfg {Boolean} minimizable
   * True to display the 'minimize' tool button and allow the user to minimize the window, false to hide the button
   * and disallow minimizing the window (defaults to false).  Note that this button provides no implementation --
   * the behavior of minimizing a window is implementation-specific, so the minimize event must be handled and a
   * custom minimize behavior implemented for this option to be useful.
   */
  minimizable: false,

  /**
   * @cfg {Boolean} maximizable
   * True to display the 'maximize' tool button and allow the user to maximize the window, false to hide the button
   * and disallow maximizing the window (defaults to false).  Note that when a window is maximized, the tool button
   * will automatically change to a 'restore' button with the appropriate behavior already built-in that will
   * restore the window to its previous size.
   */
  maximizable: false,

  /**
   * @cfg {Number} minHeight
   * The minimum height in pixels allowed for this window (defaults to 100).  Only applies when resizable = true.
   */
  minHeight: 100,

  /**
   * @cfg {Number} minWidth
   * The minimum width in pixels allowed for this window (defaults to 200).  Only applies when resizable = true.
   */
  minWidth: 200,

  /**
   * @cfg {Boolean} expandOnShow
   * True to always expand the window when it is displayed, false to keep it in its current state (which may be
   * {@link #collapsed}) when displayed (defaults to true).
   */
  expandOnShow: true,
  // inherited docs, same default
  collapsible: false,

  /**
   * @cfg {Boolean} initHidden
   * True to hide the window until show() is explicitly called (defaults to true).
   * @deprecated
   */
  initHidden: undefined,

  /**
   * @cfg {Boolean} hidden
   * Render this component hidden (default is <tt>true</tt>). If <tt>true</tt>, the
   * {@link #hide} method will be called internally.
   */
  hidden: true,
  // The following configs are set to provide the basic functionality of a window.
  // Changing them would require additional code to handle correctly and should
  // usually only be done in subclasses that can provide custom behavior.  Changing them
  // may have unexpected or undesirable results.

  /** @cfg {String} elements @hide */
  elements: 'header,body',

  /** @cfg {Boolean} frame @hide */
  frame: true,

  /** @cfg {Boolean} floating @hide */
  floating: true,
  // private
  initComponent: function initComponent() {
    this.initTools();
    Ext.Window.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event activate
     * Fires after the window has been visually activated via {@link #setActive}.
     * @param {Ext.Window} this
     */

    /**
     * @event deactivate
     * Fires after the window has been visually deactivated via {@link #setActive}.
     * @param {Ext.Window} this
     */

    /**
     * @event resize
     * Fires after the window has been resized.
     * @param {Ext.Window} this
     * @param {Number} width The window's new width
     * @param {Number} height The window's new height
     */
    'resize',
    /**
     * @event maximize
     * Fires after the window has been maximized.
     * @param {Ext.Window} this
     */
    'maximize',
    /**
     * @event minimize
     * Fires after the window has been minimized.
     * @param {Ext.Window} this
     */
    'minimize',
    /**
     * @event restore
     * Fires after the window has been restored to its original size after being maximized.
     * @param {Ext.Window} this
     */
    'restore'); // for backwards compat, this should be removed at some point

    if (Ext.isDefined(this.initHidden)) {
      this.hidden = this.initHidden;
    }

    if (this.hidden === false) {
      this.hidden = true;
      this.show();
    }
  },
  // private
  getState: function getState() {
    return Ext.apply(Ext.Window.superclass.getState.call(this) || {}, this.getBox(true));
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.Window.superclass.onRender.call(this, ct, position);

    if (this.plain) {
      this.el.addClass('x-window-plain');
    } // this element allows the Window to be focused for keyboard events


    this.focusEl = this.el.createChild({
      tag: 'a',
      href: '#',
      cls: 'x-dlg-focus',
      tabIndex: '-1',
      html: '&#160;'
    });
    this.focusEl.swallowEvent('click', true);
    this.proxy = this.el.createProxy('x-window-proxy');
    this.proxy.enableDisplayMode('block');

    if (this.modal) {
      this.mask = this.container.createChild({
        cls: 'ext-el-mask'
      }, this.el.dom);
      this.mask.enableDisplayMode('block');
      this.mask.hide();
      this.mon(this.mask, 'click', this.focus, this);
    }

    if (this.maximizable) {
      this.mon(this.header, 'dblclick', this.toggleMaximize, this);
    }
  },
  // private
  initEvents: function initEvents() {
    Ext.Window.superclass.initEvents.call(this);

    if (this.animateTarget) {
      this.setAnimateTarget(this.animateTarget);
    }

    if (this.resizable) {
      this.resizer = new Ext.Resizable(this.el, {
        minWidth: this.minWidth,
        minHeight: this.minHeight,
        handles: this.resizeHandles || 'all',
        pinned: true,
        resizeElement: this.resizerAction,
        handleCls: 'x-window-handle'
      });
      this.resizer.window = this;
      this.mon(this.resizer, 'beforeresize', this.beforeResize, this);
    }

    if (this.draggable) {
      this.header.addClass('x-window-draggable');
    }

    this.mon(this.el, 'mousedown', this.toFront, this);
    this.manager = this.manager || Ext.WindowMgr;
    this.manager.register(this);

    if (this.maximized) {
      this.maximized = false;
      this.maximize();
    }

    if (this.closable) {
      var km = this.getKeyMap();
      km.on(27, this.onEsc, this);
      km.disable();
    }
  },
  initDraggable: function initDraggable() {
    /**
     * If this Window is configured {@link #draggable}, this property will contain
     * an instance of {@link Ext.dd.DD} which handles dragging the Window's DOM Element.
     * @type Ext.dd.DD
     * @property dd
     */
    this.dd = new Ext.Window.DD(this);
  },
  // private
  onEsc: function onEsc(k, e) {
    e.stopEvent();
    this[this.closeAction]();
  },
  // private
  beforeDestroy: function beforeDestroy() {
    if (this.rendered) {
      this.hide();

      if (this.doAnchor) {
        Ext.EventManager.removeResizeListener(this.doAnchor, this);
        Ext.EventManager.un(window, 'scroll', this.doAnchor, this);
      }

      Ext.destroy(this.focusEl, this.resizer, this.dd, this.proxy, this.mask);
    }

    Ext.Window.superclass.beforeDestroy.call(this);
  },
  // private
  onDestroy: function onDestroy() {
    if (this.manager) {
      this.manager.unregister(this);
    }

    Ext.Window.superclass.onDestroy.call(this);
  },
  // private
  initTools: function initTools() {
    if (this.minimizable) {
      this.addTool({
        id: 'minimize',
        handler: this.minimize.createDelegate(this, [])
      });
    }

    if (this.maximizable) {
      this.addTool({
        id: 'maximize',
        handler: this.maximize.createDelegate(this, [])
      });
      this.addTool({
        id: 'restore',
        handler: this.restore.createDelegate(this, []),
        hidden: true
      });
    }

    if (this.closable) {
      this.addTool({
        id: 'close',
        handler: this[this.closeAction].createDelegate(this, [])
      });
    }
  },
  // private
  resizerAction: function resizerAction() {
    var box = this.proxy.getBox();
    this.proxy.hide();
    this.window.handleResize(box);
    return box;
  },
  // private
  beforeResize: function beforeResize() {
    this.resizer.minHeight = Math.max(this.minHeight, this.getFrameHeight() + 40); // 40 is a magic minimum content size?

    this.resizer.minWidth = Math.max(this.minWidth, this.getFrameWidth() + 40);
    this.resizeBox = this.el.getBox();
  },
  // private
  updateHandles: function updateHandles() {
    if (Ext.isIE && this.resizer) {
      this.resizer.syncHandleHeight();
      this.el.repaint();
    }
  },
  // private
  handleResize: function handleResize(box) {
    var rz = this.resizeBox;

    if (rz.x != box.x || rz.y != box.y) {
      this.updateBox(box);
    } else {
      this.setSize(box);
    }

    this.focus();
    this.updateHandles();
    this.saveState();
    this.doLayout();
  },

  /**
   * Focuses the window.  If a defaultButton is set, it will receive focus, otherwise the
   * window itself will receive focus.
   */
  focus: function focus() {
    var f = this.focusEl,
        db = this.defaultButton,
        t = typeof db;

    if (Ext.isDefined(db)) {
      if (Ext.isNumber(db) && this.fbar) {
        f = this.fbar.items.get(db);
      } else if (Ext.isString(db)) {
        f = Ext.getCmp(db);
      } else {
        f = db;
      }
    }

    f = f || this.focusEl;
    f.focus.defer(10, f);
  },

  /**
   * Sets the target element from which the window should animate while opening.
   * @param {String/Element} el The target element or id
   */
  setAnimateTarget: function setAnimateTarget(el) {
    el = Ext.get(el);
    this.animateTarget = el;
  },
  // private
  beforeShow: function beforeShow() {
    delete this.el.lastXY;
    delete this.el.lastLT;

    if (this.x === undefined || this.y === undefined) {
      var xy = this.el.getAlignToXY(this.container, 'c-c');
      var pos = this.el.translatePoints(xy[0], xy[1]);
      this.x = this.x === undefined ? pos.left : this.x;
      this.y = this.y === undefined ? pos.top : this.y;
    }

    this.el.setLeftTop(this.x, this.y);

    if (this.expandOnShow) {
      this.expand(false);
    }

    if (this.modal) {
      Ext.getBody().addClass('x-body-masked');
      this.mask.setSize(Ext.lib.Dom.getViewWidth(true), Ext.lib.Dom.getViewHeight(true));
      this.mask.show();
    }
  },

  /**
   * Shows the window, rendering it first if necessary, or activates it and brings it to front if hidden.
   * @param {String/Element} animateTarget (optional) The target element or id from which the window should
   * animate while opening (defaults to null with no animation)
   * @param {Function} callback (optional) A callback function to call after the window is displayed
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to this Window.
   * @return {Ext.Window} this
   */
  show: function show(animateTarget, cb, scope) {
    if (!this.rendered) {
      this.render(Ext.getBody());
    }

    if (this.hidden === false) {
      this.toFront();
      return this;
    }

    if (this.fireEvent('beforeshow', this) === false) {
      return this;
    }

    if (cb) {
      this.on('show', cb, scope, {
        single: true
      });
    }

    this.hidden = false;

    if (Ext.isDefined(animateTarget)) {
      this.setAnimateTarget(animateTarget);
    }

    this.beforeShow();

    if (this.animateTarget) {
      this.animShow();
    } else {
      this.afterShow();
    }

    return this;
  },
  // private
  afterShow: function afterShow(isAnim) {
    if (this.isDestroyed) {
      return false;
    }

    this.proxy.hide();
    this.el.setStyle('display', 'block');
    this.el.show();

    if (this.maximized) {
      this.fitContainer();
    }

    if (Ext.isMac && Ext.isGecko2) {
      // work around stupid FF 2.0/Mac scroll bar bug
      this.cascade(this.setAutoScroll);
    }

    if (this.monitorResize || this.modal || this.constrain || this.constrainHeader) {
      Ext.EventManager.onWindowResize(this.onWindowResize, this);
    }

    this.doConstrain();
    this.doLayout();

    if (this.keyMap) {
      this.keyMap.enable();
    }

    this.toFront();
    this.updateHandles();

    if (isAnim && (Ext.isIE || Ext.isWebKit)) {
      var sz = this.getSize();
      this.onResize(sz.width, sz.height);
    }

    this.onShow();
    this.fireEvent('show', this);
  },
  // private
  animShow: function animShow() {
    this.proxy.show();
    this.proxy.setBox(this.animateTarget.getBox());
    this.proxy.setOpacity(0);
    var b = this.getBox();
    this.el.setStyle('display', 'none');
    this.proxy.shift(Ext.apply(b, {
      callback: this.afterShow.createDelegate(this, [true], false),
      scope: this,
      easing: 'easeNone',
      duration: 0.25,
      opacity: 0.5
    }));
  },

  /**
   * Hides the window, setting it to invisible and applying negative offsets.
   * @param {String/Element} animateTarget (optional) The target element or id to which the window should
   * animate while hiding (defaults to null with no animation)
   * @param {Function} callback (optional) A callback function to call after the window is hidden
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to this Window.
   * @return {Ext.Window} this
   */
  hide: function hide(animateTarget, cb, scope) {
    if (this.hidden || this.fireEvent('beforehide', this) === false) {
      return this;
    }

    if (cb) {
      this.on('hide', cb, scope, {
        single: true
      });
    }

    this.hidden = true;

    if (animateTarget !== undefined) {
      this.setAnimateTarget(animateTarget);
    }

    if (this.modal) {
      this.mask.hide();
      Ext.getBody().removeClass('x-body-masked');
    }

    if (this.animateTarget) {
      this.animHide();
    } else {
      this.el.hide();
      this.afterHide();
    }

    return this;
  },
  // private
  afterHide: function afterHide() {
    this.proxy.hide();

    if (this.monitorResize || this.modal || this.constrain || this.constrainHeader) {
      Ext.EventManager.removeResizeListener(this.onWindowResize, this);
    }

    if (this.keyMap) {
      this.keyMap.disable();
    }

    this.onHide();
    this.fireEvent('hide', this);
  },
  // private
  animHide: function animHide() {
    this.proxy.setOpacity(0.5);
    this.proxy.show();
    var tb = this.getBox(false);
    this.proxy.setBox(tb);
    this.el.hide();
    this.proxy.shift(Ext.apply(this.animateTarget.getBox(), {
      callback: this.afterHide,
      scope: this,
      duration: 0.25,
      easing: 'easeNone',
      opacity: 0
    }));
  },

  /**
   * Method that is called immediately before the <code>show</code> event is fired.
   * Defaults to <code>Ext.emptyFn</code>.
   */
  onShow: Ext.emptyFn,

  /**
   * Method that is called immediately before the <code>hide</code> event is fired.
   * Defaults to <code>Ext.emptyFn</code>.
   */
  onHide: Ext.emptyFn,
  // private
  onWindowResize: function onWindowResize() {
    if (this.maximized) {
      this.fitContainer();
    }

    if (this.modal) {
      this.mask.setSize('100%', '100%');
      var force = this.mask.dom.offsetHeight;
      this.mask.setSize(Ext.lib.Dom.getViewWidth(true), Ext.lib.Dom.getViewHeight(true));
    }

    this.doConstrain();
  },
  // private
  doConstrain: function doConstrain() {
    if (this.constrain || this.constrainHeader) {
      var offsets;

      if (this.constrain) {
        offsets = {
          right: this.el.shadowOffset,
          left: this.el.shadowOffset,
          bottom: this.el.shadowOffset
        };
      } else {
        var s = this.getSize();
        offsets = {
          right: -(s.width - 100),
          bottom: -(s.height - 25)
        };
      }

      var xy = this.el.getConstrainToXY(this.container, true, offsets);

      if (xy) {
        this.setPosition(xy[0], xy[1]);
      }
    }
  },
  // private - used for dragging
  ghost: function ghost(cls) {
    var ghost = this.createGhost(cls);
    var box = this.getBox(true);
    ghost.setLeftTop(box.x, box.y);
    ghost.setWidth(box.width);
    this.el.hide();
    this.activeGhost = ghost;
    return ghost;
  },
  // private
  unghost: function unghost(show, matchPosition) {
    if (!this.activeGhost) {
      return;
    }

    if (show !== false) {
      this.el.show();
      this.focus();

      if (Ext.isMac && Ext.isGecko2) {
        // work around stupid FF 2.0/Mac scroll bar bug
        this.cascade(this.setAutoScroll);
      }
    }

    if (matchPosition !== false) {
      this.setPosition(this.activeGhost.getLeft(true), this.activeGhost.getTop(true));
    }

    this.activeGhost.hide();
    this.activeGhost.remove();
    delete this.activeGhost;
  },

  /**
   * Placeholder method for minimizing the window.  By default, this method simply fires the {@link #minimize} event
   * since the behavior of minimizing a window is application-specific.  To implement custom minimize behavior,
   * either the minimize event can be handled or this method can be overridden.
   * @return {Ext.Window} this
   */
  minimize: function minimize() {
    this.fireEvent('minimize', this);
    return this;
  },

  /**
   * <p>Closes the Window, removes it from the DOM, {@link Ext.Component#destroy destroy}s
   * the Window object and all its descendant Components. The {@link Ext.Panel#beforeclose beforeclose}
   * event is fired before the close happens and will cancel the close action if it returns false.<p>
   * <p><b>Note:</b> This method is not affected by the {@link #closeAction} setting which
   * only affects the action triggered when clicking the {@link #closable 'close' tool in the header}.
   * To hide the Window without destroying it, call {@link #hide}.</p>
   */
  close: function close() {
    if (this.fireEvent('beforeclose', this) !== false) {
      if (this.hidden) {
        this.doClose();
      } else {
        this.hide(null, this.doClose, this);
      }
    }
  },
  // private
  doClose: function doClose() {
    this.fireEvent('close', this);
    this.destroy();
  },

  /**
   * Fits the window within its current container and automatically replaces
   * the {@link #maximizable 'maximize' tool button} with the 'restore' tool button.
   * Also see {@link #toggleMaximize}.
   * @return {Ext.Window} this
   */
  maximize: function maximize() {
    if (!this.maximized) {
      this.expand(false);
      this.restoreSize = this.getSize();
      this.restorePos = this.getPosition(true);

      if (this.maximizable) {
        this.tools.maximize.hide();
        this.tools.restore.show();
      }

      this.maximized = true;
      this.el.disableShadow();

      if (this.dd) {
        this.dd.lock();
      }

      if (this.collapsible) {
        this.tools.toggle.hide();
      }

      this.el.addClass('x-window-maximized');
      this.container.addClass('x-window-maximized-ct');
      this.setPosition(0, 0);
      this.fitContainer();
      this.fireEvent('maximize', this);
    }

    return this;
  },

  /**
   * Restores a {@link #maximizable maximized}  window back to its original
   * size and position prior to being maximized and also replaces
   * the 'restore' tool button with the 'maximize' tool button.
   * Also see {@link #toggleMaximize}.
   * @return {Ext.Window} this
   */
  restore: function restore() {
    if (this.maximized) {
      var t = this.tools;
      this.el.removeClass('x-window-maximized');

      if (t.restore) {
        t.restore.hide();
      }

      if (t.maximize) {
        t.maximize.show();
      }

      this.setPosition(this.restorePos[0], this.restorePos[1]);
      this.setSize(this.restoreSize.width, this.restoreSize.height);
      delete this.restorePos;
      delete this.restoreSize;
      this.maximized = false;
      this.el.enableShadow(true);

      if (this.dd) {
        this.dd.unlock();
      }

      if (this.collapsible && t.toggle) {
        t.toggle.show();
      }

      this.container.removeClass('x-window-maximized-ct');
      this.doConstrain();
      this.fireEvent('restore', this);
    }

    return this;
  },

  /**
   * A shortcut method for toggling between {@link #maximize} and {@link #restore} based on the current maximized
   * state of the window.
   * @return {Ext.Window} this
   */
  toggleMaximize: function toggleMaximize() {
    return this[this.maximized ? 'restore' : 'maximize']();
  },
  // private
  fitContainer: function fitContainer() {
    var vs = this.container.getViewSize(false);
    this.setSize(vs.width, vs.height);
  },
  // private
  // z-index is managed by the WindowManager and may be overwritten at any time
  setZIndex: function setZIndex(index) {
    if (this.modal) {
      this.mask.setStyle('z-index', index);
    }

    this.el.setZIndex(++index);
    index += 5;

    if (this.resizer) {
      this.resizer.proxy.setStyle('z-index', ++index);
    }

    this.lastZIndex = index;
  },

  /**
   * Aligns the window to the specified element
   * @param {Mixed} element The element to align to.
   * @param {String} position (optional, defaults to "tl-bl?") The position to align to (see {@link Ext.Element#alignTo} for more details).
   * @param {Array} offsets (optional) Offset the positioning by [x, y]
   * @return {Ext.Window} this
   */
  alignTo: function alignTo(element, position, offsets) {
    var xy = this.el.getAlignToXY(element, position, offsets);
    this.setPagePosition(xy[0], xy[1]);
    return this;
  },

  /**
   * Anchors this window to another element and realigns it when the window is resized or scrolled.
   * @param {Mixed} element The element to align to.
   * @param {String} position The position to align to (see {@link Ext.Element#alignTo} for more details)
   * @param {Array} offsets (optional) Offset the positioning by [x, y]
   * @param {Boolean/Number} monitorScroll (optional) true to monitor body scroll and reposition. If this parameter
   * is a number, it is used as the buffer delay (defaults to 50ms).
   * @return {Ext.Window} this
   */
  anchorTo: function anchorTo(el, alignment, offsets, monitorScroll) {
    if (this.doAnchor) {
      Ext.EventManager.removeResizeListener(this.doAnchor, this);
      Ext.EventManager.un(window, 'scroll', this.doAnchor, this);
    }

    this.doAnchor = function () {
      this.alignTo(el, alignment, offsets);
    };

    Ext.EventManager.onWindowResize(this.doAnchor, this);
    var tm = typeof monitorScroll;

    if (tm != 'undefined') {
      Ext.EventManager.on(window, 'scroll', this.doAnchor, this, {
        buffer: tm == 'number' ? monitorScroll : 50
      });
    }

    return this;
  },

  /**
   * Brings this window to the front of any other visible windows
   * @param {Boolean} e (optional) Specify <tt>false</tt> to prevent the window from being focused.
   * @return {Ext.Window} this
   */
  toFront: function toFront(e) {
    if (this.manager.bringToFront(this)) {
      if (!e || !e.getTarget().focus) {
        this.focus();
      }
    }

    return this;
  },

  /**
   * Makes this the active window by showing its shadow, or deactivates it by hiding its shadow.  This method also
   * fires the {@link #activate} or {@link #deactivate} event depending on which action occurred. This method is
   * called internally by {@link Ext.WindowMgr}.
   * @param {Boolean} active True to activate the window, false to deactivate it (defaults to false)
   */
  setActive: function setActive(active) {
    if (active) {
      if (!this.maximized) {
        this.el.enableShadow(true);
      }

      this.fireEvent('activate', this);
    } else {
      this.el.disableShadow();
      this.fireEvent('deactivate', this);
    }
  },

  /**
   * Sends this window to the back of (lower z-index than) any other visible windows
   * @return {Ext.Window} this
   */
  toBack: function toBack() {
    this.manager.sendToBack(this);
    return this;
  },

  /**
   * Centers this window in the viewport
   * @return {Ext.Window} this
   */
  center: function center() {
    var xy = this.el.getAlignToXY(this.container, 'c-c');
    this.setPagePosition(xy[0], xy[1]);
    return this;
  }
  /**
   * @cfg {Boolean} autoWidth @hide
   **/

});
Ext.reg('window', Ext.Window); // private - custom Window DD implementation

Ext.Window.DD = function (win) {
  this.win = win;
  Ext.Window.DD.superclass.constructor.call(this, win.el.id, 'WindowDD-' + win.id);
  this.setHandleElId(win.header.id);
  this.scroll = false;
};

Ext.extend(Ext.Window.DD, Ext.dd.DD, {
  moveOnly: true,
  headerOffsets: [100, 25],
  startDrag: function startDrag() {
    var w = this.win;
    this.proxy = w.ghost();

    if (w.constrain !== false) {
      var so = w.el.shadowOffset;
      this.constrainTo(w.container, {
        right: so,
        left: so,
        bottom: so
      });
    } else if (w.constrainHeader !== false) {
      var s = this.proxy.getSize();
      this.constrainTo(w.container, {
        right: -(s.width - this.headerOffsets[0]),
        bottom: -(s.height - this.headerOffsets[1])
      });
    }
  },
  b4Drag: Ext.emptyFn,
  onDrag: function onDrag(e) {
    this.alignElWithMouse(this.proxy, e.getPageX(), e.getPageY());
  },
  endDrag: function endDrag(e) {
    this.win.unghost();
    this.win.saveState();
  }
});

/***/ }),
/* 824 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.WindowGroup
 * An object that manages a group of {@link Ext.Window} instances and provides z-order management
 * and window activation behavior.
 * @constructor
 */
Ext.WindowGroup = function () {
  var list = {};
  var accessList = [];
  var front = null; // private

  var sortWindows = function sortWindows(d1, d2) {
    return !d1._lastAccess || d1._lastAccess < d2._lastAccess ? -1 : 1;
  }; // private


  var orderWindows = function orderWindows() {
    var a = accessList,
        len = a.length;

    if (len > 0) {
      a.sort(sortWindows);
      var seed = a[0].manager.zseed;

      for (var i = 0; i < len; i++) {
        var win = a[i];

        if (win && !win.hidden) {
          win.setZIndex(seed + i * 10);
        }
      }
    }

    activateLast();
  }; // private


  var setActiveWin = function setActiveWin(win) {
    if (win != front) {
      if (front) {
        front.setActive(false);
      }

      front = win;

      if (win) {
        win.setActive(true);
      }
    }
  }; // private


  var activateLast = function activateLast() {
    for (var i = accessList.length - 1; i >= 0; --i) {
      if (!accessList[i].hidden) {
        setActiveWin(accessList[i]);
        return;
      }
    } // none to activate


    setActiveWin(null);
  };

  return {
    /**
     * The starting z-index for windows in this WindowGroup (defaults to 9000)
     * @type Number The z-index value
     */
    zseed: 9000,

    /**
     * <p>Registers a {@link Ext.Window Window} with this WindowManager. This should not
     * need to be called under normal circumstances. Windows are automatically registered
     * with a {@link Ext.Window#manager manager} at construction time.</p>
     * <p>Where this may be useful is moving Windows between two WindowManagers. For example,
     * to bring the Ext.MessageBox dialog under the same manager as the Desktop's
     * WindowManager in the desktop sample app:</p><code><pre>
    var msgWin = Ext.MessageBox.getDialog();
    MyDesktop.getDesktop().getManager().register(msgWin);
    </pre></code>
     * @param {Window} win The Window to register.
     */
    register: function register(win) {
      if (win.manager) {
        win.manager.unregister(win);
      }

      win.manager = this;
      list[win.id] = win;
      accessList.push(win);
      win.on('hide', activateLast);
    },

    /**
     * <p>Unregisters a {@link Ext.Window Window} from this WindowManager. This should not
     * need to be called. Windows are automatically unregistered upon destruction.
     * See {@link #register}.</p>
     * @param {Window} win The Window to unregister.
     */
    unregister: function unregister(win) {
      delete win.manager;
      delete list[win.id];
      win.un('hide', activateLast);
      accessList.remove(win);
    },

    /**
     * Gets a registered window by id.
     * @param {String/Object} id The id of the window or a {@link Ext.Window} instance
     * @return {Ext.Window}
     */
    get: function get(id) {
      return typeof id == "object" ? id : list[id];
    },

    /**
     * Brings the specified window to the front of any other active windows in this WindowGroup.
     * @param {String/Object} win The id of the window or a {@link Ext.Window} instance
     * @return {Boolean} True if the dialog was brought to the front, else false
     * if it was already in front
     */
    bringToFront: function bringToFront(win) {
      win = this.get(win);

      if (win != front) {
        win._lastAccess = new Date().getTime();
        orderWindows();
        return true;
      }

      return false;
    },

    /**
     * Sends the specified window to the back of other active windows in this WindowGroup.
     * @param {String/Object} win The id of the window or a {@link Ext.Window} instance
     * @return {Ext.Window} The window
     */
    sendToBack: function sendToBack(win) {
      win = this.get(win);
      win._lastAccess = -new Date().getTime();
      orderWindows();
      return win;
    },

    /**
     * Hides all windows in this WindowGroup.
     */
    hideAll: function hideAll() {
      for (var id in list) {
        if (list[id] && typeof list[id] != "function" && list[id].isVisible()) {
          list[id].hide();
        }
      }
    },

    /**
     * Gets the currently-active window in this WindowGroup.
     * @return {Ext.Window} The active window
     */
    getActive: function getActive() {
      return front;
    },

    /**
     * Returns zero or more windows in this WindowGroup using the custom search function passed to this method.
     * The function should accept a single {@link Ext.Window} reference as its only argument and should
     * return true if the window matches the search criteria, otherwise it should return false.
     * @param {Function} fn The search function
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the Window being tested.
     * that gets passed to the function if not specified)
     * @return {Array} An array of zero or more matching windows
     */
    getBy: function getBy(fn, scope) {
      var r = [];

      for (var i = accessList.length - 1; i >= 0; --i) {
        var win = accessList[i];

        if (fn.call(scope || win, win) !== false) {
          r.push(win);
        }
      }

      return r;
    },

    /**
     * Executes the specified function once for every window in this WindowGroup, passing each
     * window as the only parameter. Returning false from the function will stop the iteration.
     * @param {Function} fn The function to execute for each item
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the current Window in the iteration.
     */
    each: function each(fn, scope) {
      for (var id in list) {
        if (list[id] && typeof list[id] != "function") {
          if (fn.call(scope || list[id], list[id]) === false) {
            return;
          }
        }
      }
    }
  };
};
/**
 * @class Ext.WindowMgr
 * @extends Ext.WindowGroup
 * The default global window group that is available automatically.  To have more than one group of windows
 * with separate z-order stacks, create additional instances of {@link Ext.WindowGroup} as needed.
 * @singleton
 */


Ext.WindowMgr = new Ext.WindowGroup();

/***/ }),
/* 825 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.MessageBox
 * <p>Utility class for generating different styles of message boxes.  The alias Ext.Msg can also be used.<p/>
 * <p>Note that the MessageBox is asynchronous.  Unlike a regular JavaScript <code>alert</code> (which will halt
 * browser execution), showing a MessageBox will not cause the code to stop.  For this reason, if you have code
 * that should only run <em>after</em> some user feedback from the MessageBox, you must use a callback function
 * (see the <code>function</code> parameter for {@link #show} for more details).</p>
 * <p>Example usage:</p>
 *<pre><code>
// Basic alert:
Ext.Msg.alert('Status', 'Changes saved successfully.');

// Prompt for user data and process the result using a callback:
Ext.Msg.prompt('Name', 'Please enter your name:', function(btn, text){
    if (btn == 'ok'){
        // process text value and close...
    }
});

// Show a dialog using config options:
Ext.Msg.show({
   title:'Save Changes?',
   msg: 'You are closing a tab that has unsaved changes. Would you like to save your changes?',
   buttons: Ext.Msg.YESNOCANCEL,
   fn: processResult,
   animEl: 'elId',
   icon: Ext.MessageBox.QUESTION
});
</code></pre>
 * @singleton
 */
Ext.MessageBox = function () {
  var dlg,
      opt,
      mask,
      waitTimer,
      bodyEl,
      msgEl,
      textboxEl,
      textareaEl,
      progressBar,
      pp,
      iconEl,
      spacerEl,
      buttons,
      activeTextEl,
      bwidth,
      bufferIcon = '',
      iconCls = '',
      buttonNames = ['ok', 'yes', 'no', 'cancel']; // private

  var handleButton = function handleButton(button) {
    buttons[button].blur();

    if (dlg.isVisible()) {
      dlg.hide();
      handleHide();
      Ext.callback(opt.fn, opt.scope || window, [button, activeTextEl.dom.value, opt], 1);
    }
  }; // private


  var handleHide = function handleHide() {
    if (opt && opt.cls) {
      dlg.el.removeClass(opt.cls);
    }

    progressBar.reset();
  }; // private


  var handleEsc = function handleEsc(d, k, e) {
    if (opt && opt.closable !== false) {
      dlg.hide();
      handleHide();
    }

    if (e) {
      e.stopEvent();
    }
  }; // private


  var updateButtons = function updateButtons(b) {
    var width = 0,
        cfg;

    if (!b) {
      Ext.each(buttonNames, function (name) {
        buttons[name].hide();
      });
      return width;
    }

    dlg.footer.dom.style.display = '';
    Ext.iterate(buttons, function (name, btn) {
      cfg = b[name];

      if (cfg) {
        btn.show();
        btn.setText(Ext.isString(cfg) ? cfg : Ext.MessageBox.buttonText[name]);
        width += btn.getEl().getWidth() + 15;
      } else {
        btn.hide();
      }
    });
    return width;
  };

  return {
    /**
     * Returns a reference to the underlying {@link Ext.Window} element
     * @return {Ext.Window} The window
     */
    getDialog: function getDialog(titleText) {
      if (!dlg) {
        var btns = [];
        buttons = {};
        Ext.each(buttonNames, function (name) {
          btns.push(buttons[name] = new Ext.Button({
            text: this.buttonText[name],
            handler: handleButton.createCallback(name),
            hideMode: 'offsets'
          }));
        }, this);
        dlg = new Ext.Window({
          autoCreate: true,
          title: titleText,
          resizable: false,
          constrain: true,
          constrainHeader: true,
          minimizable: false,
          maximizable: false,
          stateful: false,
          modal: true,
          shim: true,
          buttonAlign: "center",
          width: 400,
          height: 100,
          minHeight: 80,
          plain: true,
          footer: true,
          closable: true,
          close: function close() {
            if (opt && opt.buttons && opt.buttons.no && !opt.buttons.cancel) {
              handleButton("no");
            } else {
              handleButton("cancel");
            }
          },
          fbar: new Ext.Toolbar({
            items: btns,
            enableOverflow: false
          })
        });
        dlg.render(document.body);
        dlg.getEl().addClass('x-window-dlg');
        mask = dlg.mask;
        bodyEl = dlg.body.createChild({
          html: '<div class="ext-mb-icon"></div><div class="ext-mb-content"><span class="ext-mb-text"></span><br /><div class="ext-mb-fix-cursor"><input type="text" class="ext-mb-input" /><textarea class="ext-mb-textarea"></textarea></div></div>'
        });
        iconEl = Ext.get(bodyEl.dom.firstChild);
        var contentEl = bodyEl.dom.childNodes[1];
        msgEl = Ext.get(contentEl.firstChild);
        textboxEl = Ext.get(contentEl.childNodes[2].firstChild);
        textboxEl.enableDisplayMode();
        textboxEl.addKeyListener([10, 13], function (key, e) {
          if (dlg.isVisible() && opt && opt.buttons) {
            e.stopEvent();

            if (opt.buttons.ok) {
              handleButton("ok");
            } else if (opt.buttons.yes) {
              handleButton("yes");
            }
          }
        });
        textareaEl = Ext.get(contentEl.childNodes[2].childNodes[1]);
        textareaEl.enableDisplayMode();
        progressBar = new Ext.ProgressBar({
          renderTo: bodyEl
        });
        bodyEl.createChild({
          cls: 'x-clear'
        });
      }

      return dlg;
    },

    /**
     * Updates the message box body text
     * @param {String} text (optional) Replaces the message box element's innerHTML with the specified string (defaults to
     * the XHTML-compliant non-breaking space character '&amp;#160;')
     * @return {Ext.MessageBox} this
     */
    updateText: function updateText(text) {
      if (!dlg.isVisible() && !opt.width) {
        dlg.setSize(this.maxWidth, 100); // resize first so content is never clipped from previous shows
      }

      msgEl.update(text || '&#160;');
      var iw = iconCls != '' ? iconEl.getWidth() + iconEl.getMargins('lr') : 0,
          mw = msgEl.getWidth() + msgEl.getMargins('lr'),
          fw = dlg.getFrameWidth('lr'),
          bw = dlg.body.getFrameWidth('lr'),
          w;

      if (Ext.isIE && iw > 0) {
        //3 pixels get subtracted in the icon CSS for an IE margin issue,
        //so we have to add it back here for the overall width to be consistent
        iw += 3;
      }

      w = Math.max(Math.min(opt.width || iw + mw + fw + bw, opt.maxWidth || this.maxWidth), Math.max(opt.minWidth || this.minWidth, bwidth || 0));

      if (opt.prompt === true) {
        activeTextEl.setWidth(w - iw - fw - bw);
      }

      if (opt.progress === true || opt.wait === true) {
        progressBar.setSize(w - iw - fw - bw);
      }

      if (Ext.isIE && w == bwidth) {
        w += 4; //Add offset when the content width is smaller than the buttons.    
      }

      dlg.setSize(w, 'auto').center();
      return this;
    },

    /**
     * Updates a progress-style message box's text and progress bar. Only relevant on message boxes
     * initiated via {@link Ext.MessageBox#progress} or {@link Ext.MessageBox#wait},
     * or by calling {@link Ext.MessageBox#show} with progress: true.
     * @param {Number} value Any number between 0 and 1 (e.g., .5, defaults to 0)
     * @param {String} progressText The progress text to display inside the progress bar (defaults to '')
     * @param {String} msg The message box's body text is replaced with the specified string (defaults to undefined
     * so that any existing body text will not get overwritten by default unless a new value is passed in)
     * @return {Ext.MessageBox} this
     */
    updateProgress: function updateProgress(value, progressText, msg) {
      progressBar.updateProgress(value, progressText);

      if (msg) {
        this.updateText(msg);
      }

      return this;
    },

    /**
     * Returns true if the message box is currently displayed
     * @return {Boolean} True if the message box is visible, else false
     */
    isVisible: function isVisible() {
      return dlg && dlg.isVisible();
    },

    /**
     * Hides the message box if it is displayed
     * @return {Ext.MessageBox} this
     */
    hide: function hide() {
      var proxy = dlg ? dlg.activeGhost : null;

      if (this.isVisible() || proxy) {
        dlg.hide();
        handleHide();

        if (proxy) {
          // unghost is a private function, but i saw no better solution
          // to fix the locking problem when dragging while it closes
          dlg.unghost(false, false);
        }
      }

      return this;
    },

    /**
     * Displays a new message box, or reinitializes an existing message box, based on the config options
     * passed in. All display functions (e.g. prompt, alert, etc.) on MessageBox call this function internally,
     * although those calls are basic shortcuts and do not support all of the config options allowed here.
     * @param {Object} config The following config options are supported: <ul>
     * <li><b>animEl</b> : String/Element<div class="sub-desc">An id or Element from which the message box should animate as it
     * opens and closes (defaults to undefined)</div></li>
     * <li><b>buttons</b> : Object/Boolean<div class="sub-desc">A button config object (e.g., Ext.MessageBox.OKCANCEL or {ok:'Foo',
     * cancel:'Bar'}), or false to not show any buttons (defaults to false)</div></li>
     * <li><b>closable</b> : Boolean<div class="sub-desc">False to hide the top-right close button (defaults to true). Note that
     * progress and wait dialogs will ignore this property and always hide the close button as they can only
     * be closed programmatically.</div></li>
     * <li><b>cls</b> : String<div class="sub-desc">A custom CSS class to apply to the message box's container element</div></li>
     * <li><b>defaultTextHeight</b> : Number<div class="sub-desc">The default height in pixels of the message box's multiline textarea
     * if displayed (defaults to 75)</div></li>
     * <li><b>fn</b> : Function<div class="sub-desc">A callback function which is called when the dialog is dismissed either
     * by clicking on the configured buttons, or on the dialog close button, or by pressing
     * the return button to enter input.
     * <p>Progress and wait dialogs will ignore this option since they do not respond to user
     * actions and can only be closed programmatically, so any required function should be called
     * by the same code after it closes the dialog. Parameters passed:<ul>
     * <li><b>buttonId</b> : String<div class="sub-desc">The ID of the button pressed, one of:<div class="sub-desc"><ul>
     * <li><tt>ok</tt></li>
     * <li><tt>yes</tt></li>
     * <li><tt>no</tt></li>
     * <li><tt>cancel</tt></li>
     * </ul></div></div></li>
     * <li><b>text</b> : String<div class="sub-desc">Value of the input field if either <tt><a href="#show-option-prompt" ext:member="show-option-prompt" ext:cls="Ext.MessageBox">prompt</a></tt>
     * or <tt><a href="#show-option-multiline" ext:member="show-option-multiline" ext:cls="Ext.MessageBox">multiline</a></tt> is true</div></li>
     * <li><b>opt</b> : Object<div class="sub-desc">The config object passed to show.</div></li>
     * </ul></p></div></li>
     * <li><b>scope</b> : Object<div class="sub-desc">The scope of the callback function</div></li>
     * <li><b>icon</b> : String<div class="sub-desc">A CSS class that provides a background image to be used as the body icon for the
     * dialog (e.g. Ext.MessageBox.WARNING or 'custom-class') (defaults to '')</div></li>
     * <li><b>iconCls</b> : String<div class="sub-desc">The standard {@link Ext.Window#iconCls} to
     * add an optional header icon (defaults to '')</div></li>
     * <li><b>maxWidth</b> : Number<div class="sub-desc">The maximum width in pixels of the message box (defaults to 600)</div></li>
     * <li><b>minWidth</b> : Number<div class="sub-desc">The minimum width in pixels of the message box (defaults to 100)</div></li>
     * <li><b>modal</b> : Boolean<div class="sub-desc">False to allow user interaction with the page while the message box is
     * displayed (defaults to true)</div></li>
     * <li><b>msg</b> : String<div class="sub-desc">A string that will replace the existing message box body text (defaults to the
     * XHTML-compliant non-breaking space character '&amp;#160;')</div></li>
     * <li><a id="show-option-multiline"></a><b>multiline</b> : Boolean<div class="sub-desc">
     * True to prompt the user to enter multi-line text (defaults to false)</div></li>
     * <li><b>progress</b> : Boolean<div class="sub-desc">True to display a progress bar (defaults to false)</div></li>
     * <li><b>progressText</b> : String<div class="sub-desc">The text to display inside the progress bar if progress = true (defaults to '')</div></li>
     * <li><a id="show-option-prompt"></a><b>prompt</b> : Boolean<div class="sub-desc">True to prompt the user to enter single-line text (defaults to false)</div></li>
     * <li><b>proxyDrag</b> : Boolean<div class="sub-desc">True to display a lightweight proxy while dragging (defaults to false)</div></li>
     * <li><b>title</b> : String<div class="sub-desc">The title text</div></li>
     * <li><b>value</b> : String<div class="sub-desc">The string value to set into the active textbox element if displayed</div></li>
     * <li><b>wait</b> : Boolean<div class="sub-desc">True to display a progress bar (defaults to false)</div></li>
     * <li><b>waitConfig</b> : Object<div class="sub-desc">A {@link Ext.ProgressBar#waitConfig} object (applies only if wait = true)</div></li>
     * <li><b>width</b> : Number<div class="sub-desc">The width of the dialog in pixels</div></li>
     * </ul>
     * Example usage:
     * <pre><code>
    Ext.Msg.show({
    title: 'Address',
    msg: 'Please enter your address:',
    width: 300,
    buttons: Ext.MessageBox.OKCANCEL,
    multiline: true,
    fn: saveAddress,
    animEl: 'addAddressBtn',
    icon: Ext.MessageBox.INFO
    });
    </code></pre>
     * @return {Ext.MessageBox} this
     */
    show: function show(options) {
      if (this.isVisible()) {
        this.hide();
      }

      opt = options;
      var d = this.getDialog(opt.title || "&#160;");
      d.setTitle(opt.title || "&#160;");
      var allowClose = opt.closable !== false && opt.progress !== true && opt.wait !== true;
      d.tools.close.setDisplayed(allowClose);
      activeTextEl = textboxEl;
      opt.prompt = opt.prompt || (opt.multiline ? true : false);

      if (opt.prompt) {
        if (opt.multiline) {
          textboxEl.hide();
          textareaEl.show();
          textareaEl.setHeight(Ext.isNumber(opt.multiline) ? opt.multiline : this.defaultTextHeight);
          activeTextEl = textareaEl;
        } else {
          textboxEl.show();
          textareaEl.hide();
        }
      } else {
        textboxEl.hide();
        textareaEl.hide();
      }

      activeTextEl.dom.value = opt.value || "";

      if (opt.prompt) {
        d.focusEl = activeTextEl;
      } else {
        var bs = opt.buttons;
        var db = null;

        if (bs && bs.ok) {
          db = buttons["ok"];
        } else if (bs && bs.yes) {
          db = buttons["yes"];
        }

        if (db) {
          d.focusEl = db;
        }
      }

      if (opt.iconCls) {
        d.setIconClass(opt.iconCls);
      }

      this.setIcon(Ext.isDefined(opt.icon) ? opt.icon : bufferIcon);
      bwidth = updateButtons(opt.buttons);
      progressBar.setVisible(opt.progress === true || opt.wait === true);
      this.updateProgress(0, opt.progressText);
      this.updateText(opt.msg);

      if (opt.cls) {
        d.el.addClass(opt.cls);
      }

      d.proxyDrag = opt.proxyDrag === true;
      d.modal = opt.modal !== false;
      d.mask = opt.modal !== false ? mask : false;

      if (!d.isVisible()) {
        // force it to the end of the z-index stack so it gets a cursor in FF
        document.body.appendChild(dlg.el.dom);
        d.setAnimateTarget(opt.animEl); //workaround for window internally enabling keymap in afterShow

        d.on('show', function () {
          if (allowClose === true) {
            d.keyMap.enable();
          } else {
            d.keyMap.disable();
          }
        }, this, {
          single: true
        });
        d.show(opt.animEl);
      }

      if (opt.wait === true) {
        progressBar.wait(opt.waitConfig);
      }

      return this;
    },

    /**
     * Adds the specified icon to the dialog.  By default, the class 'ext-mb-icon' is applied for default
     * styling, and the class passed in is expected to supply the background image url. Pass in empty string ('')
     * to clear any existing icon. This method must be called before the MessageBox is shown.
     * The following built-in icon classes are supported, but you can also pass in a custom class name:
     * <pre>
    Ext.MessageBox.INFO
    Ext.MessageBox.WARNING
    Ext.MessageBox.QUESTION
    Ext.MessageBox.ERROR
     *</pre>
     * @param {String} icon A CSS classname specifying the icon's background image url, or empty string to clear the icon
     * @return {Ext.MessageBox} this
     */
    setIcon: function setIcon(icon) {
      if (!dlg) {
        bufferIcon = icon;
        return;
      }

      bufferIcon = undefined;

      if (icon && icon != '') {
        iconEl.removeClass('x-hidden');
        iconEl.replaceClass(iconCls, icon);
        bodyEl.addClass('x-dlg-icon');
        iconCls = icon;
      } else {
        iconEl.replaceClass(iconCls, 'x-hidden');
        bodyEl.removeClass('x-dlg-icon');
        iconCls = '';
      }

      return this;
    },

    /**
     * Displays a message box with a progress bar.  This message box has no buttons and is not closeable by
     * the user.  You are responsible for updating the progress bar as needed via {@link Ext.MessageBox#updateProgress}
     * and closing the message box when the process is complete.
     * @param {String} title The title bar text
     * @param {String} msg The message box body text
     * @param {String} progressText (optional) The text to display inside the progress bar (defaults to '')
     * @return {Ext.MessageBox} this
     */
    progress: function progress(title, msg, progressText) {
      this.show({
        title: title,
        msg: msg,
        buttons: false,
        progress: true,
        closable: false,
        minWidth: this.minProgressWidth,
        progressText: progressText
      });
      return this;
    },

    /**
     * Displays a message box with an infinitely auto-updating progress bar.  This can be used to block user
     * interaction while waiting for a long-running process to complete that does not have defined intervals.
     * You are responsible for closing the message box when the process is complete.
     * @param {String} msg The message box body text
     * @param {String} title (optional) The title bar text
     * @param {Object} config (optional) A {@link Ext.ProgressBar#waitConfig} object
     * @return {Ext.MessageBox} this
     */
    wait: function wait(msg, title, config) {
      this.show({
        title: title,
        msg: msg,
        buttons: false,
        closable: false,
        wait: true,
        modal: true,
        minWidth: this.minProgressWidth,
        waitConfig: config
      });
      return this;
    },

    /**
     * Displays a standard read-only message box with an OK button (comparable to the basic JavaScript alert prompt).
     * If a callback function is passed it will be called after the user clicks the button, and the
     * id of the button that was clicked will be passed as the only parameter to the callback
     * (could also be the top-right close button).
     * @param {String} title The title bar text
     * @param {String} msg The message box body text
     * @param {Function} fn (optional) The callback function invoked after the message box is closed
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to the browser wnidow.
     * @return {Ext.MessageBox} this
     */
    alert: function alert(title, msg, fn, scope) {
      this.show({
        title: title,
        msg: msg,
        buttons: this.OK,
        fn: fn,
        scope: scope,
        minWidth: this.minWidth
      });
      return this;
    },

    /**
     * Displays a confirmation message box with Yes and No buttons (comparable to JavaScript's confirm).
     * If a callback function is passed it will be called after the user clicks either button,
     * and the id of the button that was clicked will be passed as the only parameter to the callback
     * (could also be the top-right close button).
     * @param {String} title The title bar text
     * @param {String} msg The message box body text
     * @param {Function} fn (optional) The callback function invoked after the message box is closed
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to the browser wnidow.
     * @return {Ext.MessageBox} this
     */
    confirm: function confirm(title, msg, fn, scope) {
      this.show({
        title: title,
        msg: msg,
        buttons: this.YESNO,
        fn: fn,
        scope: scope,
        icon: this.QUESTION,
        minWidth: this.minWidth
      });
      return this;
    },

    /**
     * Displays a message box with OK and Cancel buttons prompting the user to enter some text (comparable to JavaScript's prompt).
     * The prompt can be a single-line or multi-line textbox.  If a callback function is passed it will be called after the user
     * clicks either button, and the id of the button that was clicked (could also be the top-right
     * close button) and the text that was entered will be passed as the two parameters to the callback.
     * @param {String} title The title bar text
     * @param {String} msg The message box body text
     * @param {Function} fn (optional) The callback function invoked after the message box is closed
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to the browser wnidow.
     * @param {Boolean/Number} multiline (optional) True to create a multiline textbox using the defaultTextHeight
     * property, or the height in pixels to create the textbox (defaults to false / single-line)
     * @param {String} value (optional) Default value of the text input element (defaults to '')
     * @return {Ext.MessageBox} this
     */
    prompt: function prompt(title, msg, fn, scope, multiline, value) {
      this.show({
        title: title,
        msg: msg,
        buttons: this.OKCANCEL,
        fn: fn,
        minWidth: this.minPromptWidth,
        scope: scope,
        prompt: true,
        multiline: multiline,
        value: value
      });
      return this;
    },

    /**
     * Button config that displays a single OK button
     * @type Object
     */
    OK: {
      ok: true
    },

    /**
     * Button config that displays a single Cancel button
     * @type Object
     */
    CANCEL: {
      cancel: true
    },

    /**
     * Button config that displays OK and Cancel buttons
     * @type Object
     */
    OKCANCEL: {
      ok: true,
      cancel: true
    },

    /**
     * Button config that displays Yes and No buttons
     * @type Object
     */
    YESNO: {
      yes: true,
      no: true
    },

    /**
     * Button config that displays Yes, No and Cancel buttons
     * @type Object
     */
    YESNOCANCEL: {
      yes: true,
      no: true,
      cancel: true
    },

    /**
     * The CSS class that provides the INFO icon image
     * @type String
     */
    INFO: 'ext-mb-info',

    /**
     * The CSS class that provides the WARNING icon image
     * @type String
     */
    WARNING: 'ext-mb-warning',

    /**
     * The CSS class that provides the QUESTION icon image
     * @type String
     */
    QUESTION: 'ext-mb-question',

    /**
     * The CSS class that provides the ERROR icon image
     * @type String
     */
    ERROR: 'ext-mb-error',

    /**
     * The default height in pixels of the message box's multiline textarea if displayed (defaults to 75)
     * @type Number
     */
    defaultTextHeight: 75,

    /**
     * The maximum width in pixels of the message box (defaults to 600)
     * @type Number
     */
    maxWidth: 600,

    /**
     * The minimum width in pixels of the message box (defaults to 100)
     * @type Number
     */
    minWidth: 100,

    /**
     * The minimum width in pixels of the message box if it is a progress-style dialog.  This is useful
     * for setting a different minimum width than text-only dialogs may need (defaults to 250).
     * @type Number
     */
    minProgressWidth: 250,

    /**
     * The minimum width in pixels of the message box if it is a prompt dialog.  This is useful
     * for setting a different minimum width than text-only dialogs may need (defaults to 250).
     * @type Number
     */
    minPromptWidth: 250,

    /**
     * An object containing the default button text strings that can be overriden for localized language support.
     * Supported properties are: ok, cancel, yes and no.  Generally you should include a locale-specific
     * resource file for handling language support across the framework.
     * Customize the default text like so: Ext.MessageBox.buttonText.yes = "oui"; //french
     * @type Object
     */
    buttonText: {
      ok: "OK",
      cancel: "Cancel",
      yes: "Yes",
      no: "No"
    }
  };
}();
/**
 * Shorthand for {@link Ext.MessageBox}
 */


Ext.Msg = Ext.MessageBox;

/***/ }),
/* 826 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.dd.PanelProxy
 * A custom drag proxy implementation specific to {@link Ext.Panel}s. This class is primarily used internally
 * for the Panel's drag drop implementation, and should never need to be created directly.
 * @constructor
 * @param panel The {@link Ext.Panel} to proxy for
 * @param config Configuration options
 */
Ext.dd.PanelProxy = function (panel, config) {
  this.panel = panel;
  this.id = this.panel.id + '-ddproxy';
  Ext.apply(this, config);
};

Ext.dd.PanelProxy.prototype = {
  /**
   * @cfg {Boolean} insertProxy True to insert a placeholder proxy element while dragging the panel,
   * false to drag with no proxy (defaults to true).
   */
  insertProxy: true,
  // private overrides
  setStatus: Ext.emptyFn,
  reset: Ext.emptyFn,
  update: Ext.emptyFn,
  stop: Ext.emptyFn,
  sync: Ext.emptyFn,

  /**
   * Gets the proxy's element
   * @return {Element} The proxy's element
   */
  getEl: function getEl() {
    return this.ghost;
  },

  /**
   * Gets the proxy's ghost element
   * @return {Element} The proxy's ghost element
   */
  getGhost: function getGhost() {
    return this.ghost;
  },

  /**
   * Gets the proxy's element
   * @return {Element} The proxy's element
   */
  getProxy: function getProxy() {
    return this.proxy;
  },

  /**
   * Hides the proxy
   */
  hide: function hide() {
    if (this.ghost) {
      if (this.proxy) {
        this.proxy.remove();
        delete this.proxy;
      }

      this.panel.el.dom.style.display = '';
      this.ghost.remove();
      delete this.ghost;
    }
  },

  /**
   * Shows the proxy
   */
  show: function show() {
    if (!this.ghost) {
      this.ghost = this.panel.createGhost(undefined, undefined, Ext.getBody());
      this.ghost.setXY(this.panel.el.getXY());

      if (this.insertProxy) {
        this.proxy = this.panel.el.insertSibling({
          cls: 'x-panel-dd-spacer'
        });
        this.proxy.setSize(this.panel.getSize());
      }

      this.panel.el.dom.style.display = 'none';
    }
  },
  // private
  repair: function repair(xy, callback, scope) {
    this.hide();

    if (typeof callback == "function") {
      callback.call(scope || this);
    }
  },

  /**
   * Moves the proxy to a different position in the DOM.  This is typically called while dragging the Panel
   * to keep the proxy sync'd to the Panel's location.
   * @param {HTMLElement} parentNode The proxy's parent DOM node
   * @param {HTMLElement} before (optional) The sibling node before which the proxy should be inserted (defaults
   * to the parent's last child if not specified)
   */
  moveProxy: function moveProxy(parentNode, before) {
    if (this.proxy) {
      parentNode.insertBefore(this.proxy.dom, before);
    }
  }
}; // private - DD implementation for Panels

Ext.Panel.DD = function (panel, cfg) {
  this.panel = panel;
  this.dragData = {
    panel: panel
  };
  this.proxy = new Ext.dd.PanelProxy(panel, cfg);
  Ext.Panel.DD.superclass.constructor.call(this, panel.el, cfg);
  var h = panel.header;

  if (h) {
    this.setHandleElId(h.id);
  }

  (h ? h : this.panel.body).setStyle('cursor', 'move');
  this.scroll = false;
};

Ext.extend(Ext.Panel.DD, Ext.dd.DragSource, {
  showFrame: Ext.emptyFn,
  startDrag: Ext.emptyFn,
  b4StartDrag: function b4StartDrag(x, y) {
    this.proxy.show();
  },
  b4MouseDown: function b4MouseDown(e) {
    var x = e.getPageX();
    var y = e.getPageY();
    this.autoOffset(x, y);
  },
  onInitDrag: function onInitDrag(x, y) {
    this.onStartDrag(x, y);
    return true;
  },
  createFrame: Ext.emptyFn,
  getDragEl: function getDragEl(e) {
    return this.proxy.ghost.dom;
  },
  endDrag: function endDrag(e) {
    this.proxy.hide();
    this.panel.saveState();
  },
  autoOffset: function autoOffset(x, y) {
    x -= this.startPageX;
    y -= this.startPageY;
    this.setDelta(x, y);
  }
});

/***/ }),
/* 827 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.state.Provider
 * Abstract base class for state provider implementations. This class provides methods
 * for encoding and decoding <b>typed</b> variables including dates and defines the
 * Provider interface.
 */
Ext.state.Provider = function () {
  /**
   * @event statechange
   * Fires when a state change occurs.
   * @param {Provider} this This state provider
   * @param {String} key The state key which was changed
   * @param {String} value The encoded value for the state
   */
  this.addEvents("statechange");
  this.state = {};
  Ext.state.Provider.superclass.constructor.call(this);
};

Ext.extend(Ext.state.Provider, Ext.util.Observable, {
  /**
   * Returns the current value for a key
   * @param {String} name The key name
   * @param {Mixed} defaultValue A default value to return if the key's value is not found
   * @return {Mixed} The state data
   */
  get: function get(name, defaultValue) {
    return typeof this.state[name] == "undefined" ? defaultValue : this.state[name];
  },

  /**
   * Clears a value from the state
   * @param {String} name The key name
   */
  clear: function clear(name) {
    delete this.state[name];
    this.fireEvent("statechange", this, name, null);
  },

  /**
   * Sets the value for a key
   * @param {String} name The key name
   * @param {Mixed} value The value to set
   */
  set: function set(name, value) {
    this.state[name] = value;
    this.fireEvent("statechange", this, name, value);
  },

  /**
   * Decodes a string previously encoded with {@link #encodeValue}.
   * @param {String} value The value to decode
   * @return {Mixed} The decoded value
   */
  decodeValue: function decodeValue(cookie) {
    var re = /^(a|n|d|b|s|o)\:(.*)$/;
    var matches = re.exec(unescape(cookie));
    if (!matches || !matches[1]) return; // non state cookie

    var type = matches[1];
    var v = matches[2];

    switch (type) {
      case "n":
        return parseFloat(v);

      case "d":
        return new Date(Date.parse(v));

      case "b":
        return v == "1";

      case "a":
        var all = [];

        if (v != '') {
          Ext.each(v.split('^'), function (val) {
            all.push(this.decodeValue(val));
          }, this);
        }

        return all;

      case "o":
        var all = {};

        if (v != '') {
          Ext.each(v.split('^'), function (val) {
            var kv = val.split('=');
            all[kv[0]] = this.decodeValue(kv[1]);
          }, this);
        }

        return all;

      default:
        return v;
    }
  },

  /**
   * Encodes a value including type information.  Decode with {@link #decodeValue}.
   * @param {Mixed} value The value to encode
   * @return {String} The encoded value
   */
  encodeValue: function encodeValue(v) {
    var enc;

    if (typeof v == "number") {
      enc = "n:" + v;
    } else if (typeof v == "boolean") {
      enc = "b:" + (v ? "1" : "0");
    } else if (Ext.isDate(v)) {
      enc = "d:" + v.toGMTString();
    } else if (Ext.isArray(v)) {
      var flat = "";

      for (var i = 0, len = v.length; i < len; i++) {
        flat += this.encodeValue(v[i]);
        if (i != len - 1) flat += "^";
      }

      enc = "a:" + flat;
    } else if (typeof v == "object") {
      var flat = "";

      for (var key in v) {
        if (typeof v[key] != "function" && v[key] !== undefined) {
          flat += key + "=" + this.encodeValue(v[key]) + "^";
        }
      }

      enc = "o:" + flat.substring(0, flat.length - 1);
    } else {
      enc = "s:" + v;
    }

    return escape(enc);
  }
});

/***/ }),
/* 828 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.state.Manager
 * This is the global state manager. By default all components that are "state aware" check this class
 * for state information if you don't pass them a custom state provider. In order for this class
 * to be useful, it must be initialized with a provider when your application initializes. Example usage:
 <pre><code>
// in your initialization function
init : function(){
   Ext.state.Manager.setProvider(new Ext.state.CookieProvider());
   var win = new Window(...);
   win.restoreState();
}
 </code></pre>
 * @singleton
 */
Ext.state.Manager = function () {
  var provider = new Ext.state.Provider();
  return {
    /**
     * Configures the default state provider for your application
     * @param {Provider} stateProvider The state provider to set
     */
    setProvider: function setProvider(stateProvider) {
      provider = stateProvider;
    },

    /**
     * Returns the current value for a key
     * @param {String} name The key name
     * @param {Mixed} defaultValue The default value to return if the key lookup does not match
     * @return {Mixed} The state data
     */
    get: function get(key, defaultValue) {
      return provider.get(key, defaultValue);
    },

    /**
     * Sets the value for a key
     * @param {String} name The key name
     * @param {Mixed} value The state data
     */
    set: function set(key, value) {
      provider.set(key, value);
    },

    /**
     * Clears a value from the state
     * @param {String} name The key name
     */
    clear: function clear(key) {
      provider.clear(key);
    },

    /**
     * Gets the currently configured state provider
     * @return {Provider} The state provider
     */
    getProvider: function getProvider() {
      return provider;
    }
  };
}();

/***/ }),
/* 829 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.state.CookieProvider
 * @extends Ext.state.Provider
 * The default Provider implementation which saves state via cookies.
 * <br />Usage:
 <pre><code>
   var cp = new Ext.state.CookieProvider({
       path: "/cgi-bin/",
       expires: new Date(new Date().getTime()+(1000*60*60*24*30)), //30 days
       domain: "extjs.com"
   });
   Ext.state.Manager.setProvider(cp);
 </code></pre>
 * @cfg {String} path The path for which the cookie is active (defaults to root '/' which makes it active for all pages in the site)
 * @cfg {Date} expires The cookie expiration date (defaults to 7 days from now)
 * @cfg {String} domain The domain to save the cookie for.  Note that you cannot specify a different domain than
 * your page is on, but you can specify a sub-domain, or simply the domain itself like 'extjs.com' to include
 * all sub-domains if you need to access cookies across different sub-domains (defaults to null which uses the same
 * domain the page is running on including the 'www' like 'www.extjs.com')
 * @cfg {Boolean} secure True if the site is using SSL (defaults to false)
 * @constructor
 * Create a new CookieProvider
 * @param {Object} config The configuration object
 */
Ext.state.CookieProvider = function (config) {
  Ext.state.CookieProvider.superclass.constructor.call(this);
  this.path = "/";
  this.expires = new Date(new Date().getTime() + 1000 * 60 * 60 * 24 * 7); //7 days

  this.domain = null;
  this.secure = false;
  Ext.apply(this, config);
  this.state = this.readCookies();
};

Ext.extend(Ext.state.CookieProvider, Ext.state.Provider, {
  // private
  set: function set(name, value) {
    if (typeof value == "undefined" || value === null) {
      this.clear(name);
      return;
    }

    this.setCookie(name, value);
    Ext.state.CookieProvider.superclass.set.call(this, name, value);
  },
  // private
  clear: function clear(name) {
    this.clearCookie(name);
    Ext.state.CookieProvider.superclass.clear.call(this, name);
  },
  // private
  readCookies: function readCookies() {
    var cookies = {};
    var c = document.cookie + ";";
    var re = /\s?(.*?)=(.*?);/g;
    var matches;

    while ((matches = re.exec(c)) != null) {
      var name = matches[1];
      var value = matches[2];

      if (name && name.substring(0, 3) == "ys-") {
        cookies[name.substr(3)] = this.decodeValue(value);
      }
    }

    return cookies;
  },
  // private
  setCookie: function setCookie(name, value) {
    document.cookie = "ys-" + name + "=" + this.encodeValue(value) + (this.expires == null ? "" : "; expires=" + this.expires.toGMTString()) + (this.path == null ? "" : "; path=" + this.path) + (this.domain == null ? "" : "; domain=" + this.domain) + (this.secure == true ? "; secure" : "");
  },
  // private
  clearCookie: function clearCookie(name) {
    document.cookie = "ys-" + name + "=null; expires=Thu, 01-Jan-70 00:00:01 GMT" + (this.path == null ? "" : "; path=" + this.path) + (this.domain == null ? "" : "; domain=" + this.domain) + (this.secure == true ? "; secure" : "");
  }
});

/***/ }),
/* 830 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.DataView
 * @extends Ext.BoxComponent
 * A mechanism for displaying data using custom layout templates and formatting. DataView uses an {@link Ext.XTemplate}
 * as its internal templating mechanism, and is bound to an {@link Ext.data.Store}
 * so that as the data in the store changes the view is automatically updated to reflect the changes.  The view also
 * provides built-in behavior for many common events that can occur for its contained items including click, doubleclick,
 * mouseover, mouseout, etc. as well as a built-in selection model. <b>In order to use these features, an {@link #itemSelector}
 * config must be provided for the DataView to determine what nodes it will be working with.</b>
 *
 * <p>The example below binds a DataView to a {@link Ext.data.Store} and renders it into an {@link Ext.Panel}.</p>
 * <pre><code>
var store = new Ext.data.JsonStore({
    url: 'get-images.php',
    root: 'images',
    fields: [
        'name', 'url',
        {name:'size', type: 'float'},
        {name:'lastmod', type:'date', dateFormat:'timestamp'}
    ]
});
store.load();

var tpl = new Ext.XTemplate(
    '&lt;tpl for="."&gt;',
        '&lt;div class="thumb-wrap" id="{name}"&gt;',
        '&lt;div class="thumb"&gt;&lt;img src="{url}" title="{name}"&gt;&lt;/div&gt;',
        '&lt;span class="x-editable"&gt;{shortName}&lt;/span&gt;&lt;/div&gt;',
    '&lt;/tpl&gt;',
    '&lt;div class="x-clear"&gt;&lt;/div&gt;'
);

var panel = new Ext.Panel({
    id:'images-view',
    frame:true,
    width:535,
    autoHeight:true,
    collapsible:true,
    layout:'fit',
    title:'Simple DataView',

    items: new Ext.DataView({
        store: store,
        tpl: tpl,
        autoHeight:true,
        multiSelect: true,
        overClass:'x-view-over',
        itemSelector:'div.thumb-wrap',
        emptyText: 'No images to display'
    })
});
panel.render(document.body);
</code></pre>
 * @constructor
 * Create a new DataView
 * @param {Object} config The config object
 * @xtype dataview
 */
Ext.DataView = Ext.extend(Ext.BoxComponent, {
  /**
   * @cfg {String/Array} tpl
   * The HTML fragment or an array of fragments that will make up the template used by this DataView.  This should
   * be specified in the same format expected by the constructor of {@link Ext.XTemplate}.
   */

  /**
   * @cfg {Ext.data.Store} store
   * The {@link Ext.data.Store} to bind this DataView to.
   */

  /**
   * @cfg {String} itemSelector
   * <b>This is a required setting</b>. A simple CSS selector (e.g. <tt>div.some-class</tt> or 
   * <tt>span:first-child</tt>) that will be used to determine what nodes this DataView will be
   * working with.
   */

  /**
   * @cfg {Boolean} multiSelect
   * True to allow selection of more than one item at a time, false to allow selection of only a single item
   * at a time or no selection at all, depending on the value of {@link #singleSelect} (defaults to false).
   */

  /**
   * @cfg {Boolean} singleSelect
   * True to allow selection of exactly one item at a time, false to allow no selection at all (defaults to false).
   * Note that if {@link #multiSelect} = true, this value will be ignored.
   */

  /**
   * @cfg {Boolean} simpleSelect
   * True to enable multiselection by clicking on multiple items without requiring the user to hold Shift or Ctrl,
   * false to force the user to hold Ctrl or Shift to select more than on item (defaults to false).
   */

  /**
   * @cfg {String} overClass
   * A CSS class to apply to each item in the view on mouseover (defaults to undefined).
   */

  /**
   * @cfg {String} loadingText
   * A string to display during data load operations (defaults to undefined).  If specified, this text will be
   * displayed in a loading div and the view's contents will be cleared while loading, otherwise the view's
   * contents will continue to display normally until the new data is loaded and the contents are replaced.
   */

  /**
   * @cfg {String} selectedClass
   * A CSS class to apply to each selected item in the view (defaults to 'x-view-selected').
   */
  selectedClass: "x-view-selected",

  /**
   * @cfg {String} emptyText
   * The text to display in the view when there is no data to display (defaults to '').
   */
  emptyText: "",

  /**
   * @cfg {Boolean} deferEmptyText True to defer emptyText being applied until the store's first load
   */
  deferEmptyText: true,

  /**
   * @cfg {Boolean} trackOver True to enable mouseenter and mouseleave events
   */
  trackOver: false,
  //private
  last: false,
  // private
  initComponent: function initComponent() {
    Ext.DataView.superclass.initComponent.call(this);

    if (Ext.isString(this.tpl) || Ext.isArray(this.tpl)) {
      this.tpl = new Ext.XTemplate(this.tpl);
    }

    this.addEvents(
    /**
     * @event beforeclick
     * Fires before a click is processed. Returns false to cancel the default action.
     * @param {Ext.DataView} this
     * @param {Number} index The index of the target node
     * @param {HTMLElement} node The target node
     * @param {Ext.EventObject} e The raw event object
     */
    "beforeclick",
    /**
     * @event click
     * Fires when a template node is clicked.
     * @param {Ext.DataView} this
     * @param {Number} index The index of the target node
     * @param {HTMLElement} node The target node
     * @param {Ext.EventObject} e The raw event object
     */
    "click",
    /**
     * @event mouseenter
     * Fires when the mouse enters a template node. trackOver:true or an overClass must be set to enable this event.
     * @param {Ext.DataView} this
     * @param {Number} index The index of the target node
     * @param {HTMLElement} node The target node
     * @param {Ext.EventObject} e The raw event object
     */
    "mouseenter",
    /**
     * @event mouseleave
     * Fires when the mouse leaves a template node. trackOver:true or an overClass must be set to enable this event.
     * @param {Ext.DataView} this
     * @param {Number} index The index of the target node
     * @param {HTMLElement} node The target node
     * @param {Ext.EventObject} e The raw event object
     */
    "mouseleave",
    /**
     * @event containerclick
     * Fires when a click occurs and it is not on a template node.
     * @param {Ext.DataView} this
     * @param {Ext.EventObject} e The raw event object
     */
    "containerclick",
    /**
     * @event dblclick
     * Fires when a template node is double clicked.
     * @param {Ext.DataView} this
     * @param {Number} index The index of the target node
     * @param {HTMLElement} node The target node
     * @param {Ext.EventObject} e The raw event object
     */
    "dblclick",
    /**
     * @event contextmenu
     * Fires when a template node is right clicked.
     * @param {Ext.DataView} this
     * @param {Number} index The index of the target node
     * @param {HTMLElement} node The target node
     * @param {Ext.EventObject} e The raw event object
     */
    "contextmenu",
    /**
     * @event containercontextmenu
     * Fires when a right click occurs that is not on a template node.
     * @param {Ext.DataView} this
     * @param {Ext.EventObject} e The raw event object
     */
    "containercontextmenu",
    /**
     * @event selectionchange
     * Fires when the selected nodes change.
     * @param {Ext.DataView} this
     * @param {Array} selections Array of the selected nodes
     */
    "selectionchange",
    /**
     * @event beforeselect
     * Fires before a selection is made. If any handlers return false, the selection is cancelled.
     * @param {Ext.DataView} this
     * @param {HTMLElement} node The node to be selected
     * @param {Array} selections Array of currently selected nodes
     */
    "beforeselect");
    this.store = Ext.StoreMgr.lookup(this.store);
    this.all = new Ext.CompositeElementLite();
    this.selected = new Ext.CompositeElementLite();
  },
  // private
  afterRender: function afterRender() {
    Ext.DataView.superclass.afterRender.call(this);
    this.mon(this.getTemplateTarget(), {
      "click": this.onClick,
      "dblclick": this.onDblClick,
      "contextmenu": this.onContextMenu,
      scope: this
    });

    if (this.overClass || this.trackOver) {
      this.mon(this.getTemplateTarget(), {
        "mouseover": this.onMouseOver,
        "mouseout": this.onMouseOut,
        scope: this
      });
    }

    if (this.store) {
      this.bindStore(this.store, true);
    }
  },

  /**
   * Refreshes the view by reloading the data from the store and re-rendering the template.
   */
  refresh: function refresh() {
    this.clearSelections(false, true);
    var el = this.getTemplateTarget();
    el.update("");
    var records = this.store.getRange();

    if (records.length < 1) {
      if (!this.deferEmptyText || this.hasSkippedEmptyText) {
        el.update(this.emptyText);
      }

      this.all.clear();
    } else {
      this.tpl.overwrite(el, this.collectData(records, 0));
      this.all.fill(Ext.query(this.itemSelector, el.dom));
      this.updateIndexes(0);
    }

    this.hasSkippedEmptyText = true;
  },
  getTemplateTarget: function getTemplateTarget() {
    return this.el;
  },

  /**
   * Function which can be overridden to provide custom formatting for each Record that is used by this
   * DataView's {@link #tpl template} to render each node.
   * @param {Array/Object} data The raw data object that was used to create the Record.
   * @param {Number} recordIndex the index number of the Record being prepared for rendering.
   * @param {Record} record The Record being prepared for rendering.
   * @return {Array/Object} The formatted data in a format expected by the internal {@link #tpl template}'s overwrite() method.
   * (either an array if your params are numeric (i.e. {0}) or an object (i.e. {foo: 'bar'}))
   */
  prepareData: function prepareData(data) {
    return data;
  },

  /**
   * <p>Function which can be overridden which returns the data object passed to this
   * DataView's {@link #tpl template} to render the whole DataView.</p>
   * <p>This is usually an Array of data objects, each element of which is processed by an
   * {@link Ext.XTemplate XTemplate} which uses <tt>'&lt;tpl for="."&gt;'</tt> to iterate over its supplied
   * data object as an Array. However, <i>named</i> properties may be placed into the data object to
   * provide non-repeating data such as headings, totals etc.</p>
   * @param {Array} records An Array of {@link Ext.data.Record}s to be rendered into the DataView.
   * @param {Number} startIndex the index number of the Record being prepared for rendering.
   * @return {Array} An Array of data objects to be processed by a repeating XTemplate. May also
   * contain <i>named</i> properties.
   */
  collectData: function collectData(records, startIndex) {
    var r = [];

    for (var i = 0, len = records.length; i < len; i++) {
      r[r.length] = this.prepareData(records[i].data, startIndex + i, records[i]);
    }

    return r;
  },
  // private
  bufferRender: function bufferRender(records) {
    var div = document.createElement('div');
    this.tpl.overwrite(div, this.collectData(records));
    return Ext.query(this.itemSelector, div);
  },
  // private
  onUpdate: function onUpdate(ds, record) {
    var index = this.store.indexOf(record);

    if (index > -1) {
      var sel = this.isSelected(index);
      var original = this.all.elements[index];
      var node = this.bufferRender([record], index)[0];
      this.all.replaceElement(index, node, true);

      if (sel) {
        this.selected.replaceElement(original, node);
        this.all.item(index).addClass(this.selectedClass);
      }

      this.updateIndexes(index, index);
    }
  },
  // private
  onAdd: function onAdd(ds, records, index) {
    if (this.all.getCount() === 0) {
      this.refresh();
      return;
    }

    var nodes = this.bufferRender(records, index),
        n,
        a = this.all.elements;

    if (index < this.all.getCount()) {
      n = this.all.item(index).insertSibling(nodes, 'before', true);
      a.splice.apply(a, [index, 0].concat(nodes));
    } else {
      n = this.all.last().insertSibling(nodes, 'after', true);
      a.push.apply(a, nodes);
    }

    this.updateIndexes(index);
  },
  // private
  onRemove: function onRemove(ds, record, index) {
    this.deselect(index);
    this.all.removeElement(index, true);
    this.updateIndexes(index);

    if (this.store.getCount() === 0) {
      this.refresh();
    }
  },

  /**
   * Refreshes an individual node's data from the store.
   * @param {Number} index The item's data index in the store
   */
  refreshNode: function refreshNode(index) {
    this.onUpdate(this.store, this.store.getAt(index));
  },
  // private
  updateIndexes: function updateIndexes(startIndex, endIndex) {
    var ns = this.all.elements;
    startIndex = startIndex || 0;
    endIndex = endIndex || (endIndex === 0 ? 0 : ns.length - 1);

    for (var i = startIndex; i <= endIndex; i++) {
      ns[i].viewIndex = i;
    }
  },

  /**
   * Returns the store associated with this DataView.
   * @return {Ext.data.Store} The store
   */
  getStore: function getStore() {
    return this.store;
  },

  /**
   * Changes the data store bound to this view and refreshes it.
   * @param {Store} store The store to bind to this view
   */
  bindStore: function bindStore(store, initial) {
    if (!initial && this.store) {
      if (store !== this.store && this.store.autoDestroy) {
        this.store.destroy();
      } else {
        this.store.un("beforeload", this.onBeforeLoad, this);
        this.store.un("datachanged", this.refresh, this);
        this.store.un("add", this.onAdd, this);
        this.store.un("remove", this.onRemove, this);
        this.store.un("update", this.onUpdate, this);
        this.store.un("clear", this.refresh, this);
      }

      if (!store) {
        this.store = null;
      }
    }

    if (store) {
      store = Ext.StoreMgr.lookup(store);
      store.on({
        scope: this,
        beforeload: this.onBeforeLoad,
        datachanged: this.refresh,
        add: this.onAdd,
        remove: this.onRemove,
        update: this.onUpdate,
        clear: this.refresh
      });
    }

    this.store = store;

    if (store) {
      this.refresh();
    }
  },

  /**
   * Returns the template node the passed child belongs to, or null if it doesn't belong to one.
   * @param {HTMLElement} node
   * @return {HTMLElement} The template node
   */
  findItemFromChild: function findItemFromChild(node) {
    return Ext.fly(node).findParent(this.itemSelector, this.getTemplateTarget());
  },
  // private
  onClick: function onClick(e) {
    var item = e.getTarget(this.itemSelector, this.getTemplateTarget());

    if (item) {
      var index = this.indexOf(item);

      if (this.onItemClick(item, index, e) !== false) {
        this.fireEvent("click", this, index, item, e);
      }
    } else {
      if (this.fireEvent("containerclick", this, e) !== false) {
        this.onContainerClick(e);
      }
    }
  },
  onContainerClick: function onContainerClick(e) {
    this.clearSelections();
  },
  // private
  onContextMenu: function onContextMenu(e) {
    var item = e.getTarget(this.itemSelector, this.getTemplateTarget());

    if (item) {
      this.fireEvent("contextmenu", this, this.indexOf(item), item, e);
    } else {
      this.fireEvent("containercontextmenu", this, e);
    }
  },
  // private
  onDblClick: function onDblClick(e) {
    var item = e.getTarget(this.itemSelector, this.getTemplateTarget());

    if (item) {
      this.fireEvent("dblclick", this, this.indexOf(item), item, e);
    }
  },
  // private
  onMouseOver: function onMouseOver(e) {
    var item = e.getTarget(this.itemSelector, this.getTemplateTarget());

    if (item && item !== this.lastItem) {
      this.lastItem = item;
      Ext.fly(item).addClass(this.overClass);
      this.fireEvent("mouseenter", this, this.indexOf(item), item, e);
    }
  },
  // private
  onMouseOut: function onMouseOut(e) {
    if (this.lastItem) {
      if (!e.within(this.lastItem, true, true)) {
        Ext.fly(this.lastItem).removeClass(this.overClass);
        this.fireEvent("mouseleave", this, this.indexOf(this.lastItem), this.lastItem, e);
        delete this.lastItem;
      }
    }
  },
  // private
  onItemClick: function onItemClick(item, index, e) {
    if (this.fireEvent("beforeclick", this, index, item, e) === false) {
      return false;
    }

    if (this.multiSelect) {
      this.doMultiSelection(item, index, e);
      e.preventDefault();
    } else if (this.singleSelect) {
      this.doSingleSelection(item, index, e);
      e.preventDefault();
    }

    return true;
  },
  // private
  doSingleSelection: function doSingleSelection(item, index, e) {
    if (e.ctrlKey && this.isSelected(index)) {
      this.deselect(index);
    } else {
      this.select(index, false);
    }
  },
  // private
  doMultiSelection: function doMultiSelection(item, index, e) {
    if (e.shiftKey && this.last !== false) {
      var last = this.last;
      this.selectRange(last, index, e.ctrlKey);
      this.last = last; // reset the last
    } else {
      if ((e.ctrlKey || this.simpleSelect) && this.isSelected(index)) {
        this.deselect(index);
      } else {
        this.select(index, e.ctrlKey || e.shiftKey || this.simpleSelect);
      }
    }
  },

  /**
   * Gets the number of selected nodes.
   * @return {Number} The node count
   */
  getSelectionCount: function getSelectionCount() {
    return this.selected.getCount();
  },

  /**
   * Gets the currently selected nodes.
   * @return {Array} An array of HTMLElements
   */
  getSelectedNodes: function getSelectedNodes() {
    return this.selected.elements;
  },

  /**
   * Gets the indexes of the selected nodes.
   * @return {Array} An array of numeric indexes
   */
  getSelectedIndexes: function getSelectedIndexes() {
    var indexes = [],
        s = this.selected.elements;

    for (var i = 0, len = s.length; i < len; i++) {
      indexes.push(s[i].viewIndex);
    }

    return indexes;
  },

  /**
   * Gets an array of the selected records
   * @return {Array} An array of {@link Ext.data.Record} objects
   */
  getSelectedRecords: function getSelectedRecords() {
    var r = [],
        s = this.selected.elements;

    for (var i = 0, len = s.length; i < len; i++) {
      r[r.length] = this.store.getAt(s[i].viewIndex);
    }

    return r;
  },

  /**
   * Gets an array of the records from an array of nodes
   * @param {Array} nodes The nodes to evaluate
   * @return {Array} records The {@link Ext.data.Record} objects
   */
  getRecords: function getRecords(nodes) {
    var r = [],
        s = nodes;

    for (var i = 0, len = s.length; i < len; i++) {
      r[r.length] = this.store.getAt(s[i].viewIndex);
    }

    return r;
  },

  /**
   * Gets a record from a node
   * @param {HTMLElement} node The node to evaluate
   * @return {Record} record The {@link Ext.data.Record} object
   */
  getRecord: function getRecord(node) {
    return this.store.getAt(node.viewIndex);
  },

  /**
   * Clears all selections.
   * @param {Boolean} suppressEvent (optional) True to skip firing of the selectionchange event
   */
  clearSelections: function clearSelections(suppressEvent, skipUpdate) {
    if ((this.multiSelect || this.singleSelect) && this.selected.getCount() > 0) {
      if (!skipUpdate) {
        this.selected.removeClass(this.selectedClass);
      }

      this.selected.clear();
      this.last = false;

      if (!suppressEvent) {
        this.fireEvent("selectionchange", this, this.selected.elements);
      }
    }
  },

  /**
   * Returns true if the passed node is selected, else false.
   * @param {HTMLElement/Number} node The node or node index to check
   * @return {Boolean} True if selected, else false
   */
  isSelected: function isSelected(node) {
    return this.selected.contains(this.getNode(node));
  },

  /**
   * Deselects a node.
   * @param {HTMLElement/Number} node The node to deselect
   */
  deselect: function deselect(node) {
    if (this.isSelected(node)) {
      node = this.getNode(node);
      this.selected.removeElement(node);

      if (this.last == node.viewIndex) {
        this.last = false;
      }

      Ext.fly(node).removeClass(this.selectedClass);
      this.fireEvent("selectionchange", this, this.selected.elements);
    }
  },

  /**
   * Selects a set of nodes.
   * @param {Array/HTMLElement/String/Number} nodeInfo An HTMLElement template node, index of a template node,
   * id of a template node or an array of any of those to select
   * @param {Boolean} keepExisting (optional) true to keep existing selections
   * @param {Boolean} suppressEvent (optional) true to skip firing of the selectionchange vent
   */
  select: function select(nodeInfo, keepExisting, suppressEvent) {
    if (Ext.isArray(nodeInfo)) {
      if (!keepExisting) {
        this.clearSelections(true);
      }

      for (var i = 0, len = nodeInfo.length; i < len; i++) {
        this.select(nodeInfo[i], true, true);
      }

      if (!suppressEvent) {
        this.fireEvent("selectionchange", this, this.selected.elements);
      }
    } else {
      var node = this.getNode(nodeInfo);

      if (!keepExisting) {
        this.clearSelections(true);
      }

      if (node && !this.isSelected(node)) {
        if (this.fireEvent("beforeselect", this, node, this.selected.elements) !== false) {
          Ext.fly(node).addClass(this.selectedClass);
          this.selected.add(node);
          this.last = node.viewIndex;

          if (!suppressEvent) {
            this.fireEvent("selectionchange", this, this.selected.elements);
          }
        }
      }
    }
  },

  /**
   * Selects a range of nodes. All nodes between start and end are selected.
   * @param {Number} start The index of the first node in the range
   * @param {Number} end The index of the last node in the range
   * @param {Boolean} keepExisting (optional) True to retain existing selections
   */
  selectRange: function selectRange(start, end, keepExisting) {
    if (!keepExisting) {
      this.clearSelections(true);
    }

    this.select(this.getNodes(start, end), true);
  },

  /**
   * Gets a template node.
   * @param {HTMLElement/String/Number} nodeInfo An HTMLElement template node, index of a template node or the id of a template node
   * @return {HTMLElement} The node or null if it wasn't found
   */
  getNode: function getNode(nodeInfo) {
    if (Ext.isString(nodeInfo)) {
      return document.getElementById(nodeInfo);
    } else if (Ext.isNumber(nodeInfo)) {
      return this.all.elements[nodeInfo];
    }

    return nodeInfo;
  },

  /**
   * Gets a range nodes.
   * @param {Number} start (optional) The index of the first node in the range
   * @param {Number} end (optional) The index of the last node in the range
   * @return {Array} An array of nodes
   */
  getNodes: function getNodes(start, end) {
    var ns = this.all.elements;
    start = start || 0;
    end = !Ext.isDefined(end) ? Math.max(ns.length - 1, 0) : end;
    var nodes = [],
        i;

    if (start <= end) {
      for (i = start; i <= end && ns[i]; i++) {
        nodes.push(ns[i]);
      }
    } else {
      for (i = start; i >= end && ns[i]; i--) {
        nodes.push(ns[i]);
      }
    }

    return nodes;
  },

  /**
   * Finds the index of the passed node.
   * @param {HTMLElement/String/Number} nodeInfo An HTMLElement template node, index of a template node or the id of a template node
   * @return {Number} The index of the node or -1
   */
  indexOf: function indexOf(node) {
    node = this.getNode(node);

    if (Ext.isNumber(node.viewIndex)) {
      return node.viewIndex;
    }

    return this.all.indexOf(node);
  },
  // private
  onBeforeLoad: function onBeforeLoad() {
    if (this.loadingText) {
      this.clearSelections(false, true);
      this.getTemplateTarget().update('<div class="loading-indicator">' + this.loadingText + '</div>');
      this.all.clear();
    }
  },
  onDestroy: function onDestroy() {
    this.all.clear();
    this.selected.clear();
    Ext.DataView.superclass.onDestroy.call(this);
    this.bindStore(null);
  }
});
/**
 * Changes the data store bound to this view and refreshes it. (deprecated in favor of bindStore)
 * @param {Store} store The store to bind to this view
 */

Ext.DataView.prototype.setStore = Ext.DataView.prototype.bindStore;
Ext.reg('dataview', Ext.DataView);

/***/ }),
/* 831 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.list.ListView
 * @extends Ext.DataView
 * <p>Ext.list.ListView is a fast and light-weight implentation of a
 * {@link Ext.grid.GridPanel Grid} like view with the following characteristics:</p>
 * <div class="mdetail-params"><ul>
 * <li>resizable columns</li>
 * <li>selectable</li>
 * <li>column widths are initially proportioned by percentage based on the container
 * width and number of columns</li>
 * <li>uses templates to render the data in any required format</li>
 * <li>no horizontal scrolling</li>
 * <li>no editing</li>
 * </ul></div>
 * <p>Example usage:</p>
 * <pre><code>
// consume JSON of this form:
{
   "images":[
      {
         "name":"dance_fever.jpg",
         "size":2067,
         "lastmod":1236974993000,
         "url":"images\/thumbs\/dance_fever.jpg"
      },
      {
         "name":"zack_sink.jpg",
         "size":2303,
         "lastmod":1236974993000,
         "url":"images\/thumbs\/zack_sink.jpg"
      }
   ]
} 
var store = new Ext.data.JsonStore({
    url: 'get-images.php',
    root: 'images',
    fields: [
        'name', 'url',
        {name:'size', type: 'float'},
        {name:'lastmod', type:'date', dateFormat:'timestamp'}
    ]
});
store.load();

var listView = new Ext.list.ListView({
    store: store,
    multiSelect: true,
    emptyText: 'No images to display',
    reserveScrollOffset: true,
    columns: [{
        header: 'File',
        width: .5,
        dataIndex: 'name'
    },{
        header: 'Last Modified',
        width: .35, 
        dataIndex: 'lastmod',
        tpl: '{lastmod:date("m-d h:i a")}'
    },{
        header: 'Size',
        dataIndex: 'size',
        tpl: '{size:fileSize}', // format using Ext.util.Format.fileSize()
        align: 'right'
    }]
});

// put it in a Panel so it looks pretty
var panel = new Ext.Panel({
    id:'images-view',
    width:425,
    height:250,
    collapsible:true,
    layout:'fit',
    title:'Simple ListView <i>(0 items selected)</i>',
    items: listView
});
panel.render(document.body);

// little bit of feedback
listView.on('selectionchange', function(view, nodes){
    var l = nodes.length;
    var s = l != 1 ? 's' : '';
    panel.setTitle('Simple ListView <i>('+l+' item'+s+' selected)</i>');
});
 * </code></pre>
 * @constructor
 * @param {Object} config
 * @xtype listview
 */
Ext.list.ListView = Ext.extend(Ext.DataView, {
  /**
   * Set this property to <tt>true</tt> to disable the header click handler disabling sort
   * (defaults to <tt>false</tt>).
   * @type Boolean
   * @property disableHeaders
   */

  /**
   * @cfg {Boolean} hideHeaders
   * <tt>true</tt> to hide the {@link #internalTpl header row} (defaults to <tt>false</tt> so
   * the {@link #internalTpl header row} will be shown).
   */

  /**
   * @cfg {String} itemSelector
   * Defaults to <tt>'dl'</tt> to work with the preconfigured <b><tt>{@link Ext.DataView#tpl tpl}</tt></b>.
   * This setting specifies the CSS selector (e.g. <tt>div.some-class</tt> or <tt>span:first-child</tt>)
   * that will be used to determine what nodes the ListView will be working with.   
   */
  itemSelector: 'dl',

  /**
   * @cfg {String} selectedClass The CSS class applied to a selected row (defaults to
   * <tt>'x-list-selected'</tt>). An example overriding the default styling:
  <pre><code>
  .x-list-selected {background-color: yellow;}
  </code></pre>
   * @type String
   */
  selectedClass: 'x-list-selected',

  /**
   * @cfg {String} overClass The CSS class applied when over a row (defaults to
   * <tt>'x-list-over'</tt>). An example overriding the default styling:
  <pre><code>
  .x-list-over {background-color: orange;}
  </code></pre>
   * @type String
   */
  overClass: 'x-list-over',

  /**
   * @cfg {Boolean} reserveScrollOffset
   * By default will defer accounting for the configured <b><tt>{@link #scrollOffset}</tt></b>
   * for 10 milliseconds.  Specify <tt>true</tt> to account for the configured
   * <b><tt>{@link #scrollOffset}</tt></b> immediately.
   */

  /**
   * @cfg {Number} scrollOffset The amount of space to reserve for the scrollbar (defaults to
   * <tt>undefined</tt>). If an explicit value isn't specified, this will be automatically
   * calculated.
   */
  scrollOffset: undefined,

  /**
   * @cfg {Boolean/Object} columnResize
   * Specify <tt>true</tt> or specify a configuration object for {@link Ext.list.ListView.ColumnResizer}
   * to enable the columns to be resizable (defaults to <tt>true</tt>).
   */
  columnResize: true,

  /**
   * @cfg {Array} columns An array of column configuration objects, for example:
   * <pre><code>
  {
  align: 'right',
  dataIndex: 'size',
  header: 'Size',
  tpl: '{size:fileSize}',
  width: .35
  }
   * </code></pre> 
   * Acceptable properties for each column configuration object are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>align</tt></b> : String<div class="sub-desc">Set the CSS text-align property
   * of the column. Defaults to <tt>'left'</tt>.</div></li>
   * <li><b><tt>dataIndex</tt></b> : String<div class="sub-desc">See {@link Ext.grid.Column}.
   * {@link Ext.grid.Column#dataIndex dataIndex} for details.</div></li>
   * <li><b><tt>header</tt></b> : String<div class="sub-desc">See {@link Ext.grid.Column}.
   * {@link Ext.grid.Column#header header} for details.</div></li>
   * <li><b><tt>tpl</tt></b> : String<div class="sub-desc">Specify a string to pass as the
   * configuration string for {@link Ext.XTemplate}.  By default an {@link Ext.XTemplate}
   * will be implicitly created using the <tt>dataIndex</tt>.</div></li>
   * <li><b><tt>width</tt></b> : Number<div class="sub-desc">Percentage of the container width
   * this column should be allocated.  Columns that have no width specified will be
   * allocated with an equal percentage to fill 100% of the container width.  To easily take
   * advantage of the full container width, leave the width of at least one column undefined.
   * Note that if you do not want to take up the full width of the container, the width of
   * every column needs to be explicitly defined.</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Boolean/Object} columnSort
   * Specify <tt>true</tt> or specify a configuration object for {@link Ext.list.ListView.Sorter}
   * to enable the columns to be sortable (defaults to <tt>true</tt>).
   */
  columnSort: true,

  /**
   * @cfg {String/Array} internalTpl
   * The template to be used for the header row.  See {@link #tpl} for more details.
   */

  /*
   * IE has issues when setting percentage based widths to 100%. Default to 99.
   */
  maxWidth: Ext.isIE ? 99 : 100,
  initComponent: function initComponent() {
    if (this.columnResize) {
      this.colResizer = new Ext.list.ColumnResizer(this.colResizer);
      this.colResizer.init(this);
    }

    if (this.columnSort) {
      this.colSorter = new Ext.list.Sorter(this.columnSort);
      this.colSorter.init(this);
    }

    if (!this.internalTpl) {
      this.internalTpl = new Ext.XTemplate('<div class="x-list-header"><div class="x-list-header-inner">', '<tpl for="columns">', '<div style="width:{[values.width*100]}%;text-align:{align};"><em unselectable="on" id="', this.id, '-xlhd-{#}">', '{header}', '</em></div>', '</tpl>', '<div class="x-clear"></div>', '</div></div>', '<div class="x-list-body"><div class="x-list-body-inner">', '</div></div>');
    }

    if (!this.tpl) {
      this.tpl = new Ext.XTemplate('<tpl for="rows">', '<dl>', '<tpl for="parent.columns">', '<dt style="width:{[values.width*100]}%;text-align:{align};">', '<em unselectable="on"<tpl if="cls"> class="{cls}</tpl>">', '{[values.tpl.apply(parent)]}', '</em></dt>', '</tpl>', '<div class="x-clear"></div>', '</dl>', '</tpl>');
    }

    ;
    var cs = this.columns,
        allocatedWidth = 0,
        colsWithWidth = 0,
        len = cs.length,
        columns = [];

    for (var i = 0; i < len; i++) {
      var c = cs[i];

      if (!c.isColumn) {
        c.xtype = c.xtype ? /^lv/.test(c.xtype) ? c.xtype : 'lv' + c.xtype : 'lvcolumn';
        c = Ext.create(c);
      }

      if (c.width) {
        allocatedWidth += c.width * 100;
        colsWithWidth++;
      }

      columns.push(c);
    }

    cs = this.columns = columns; // auto calculate missing column widths

    if (colsWithWidth < len) {
      var remaining = len - colsWithWidth;

      if (allocatedWidth < this.maxWidth) {
        var perCol = (this.maxWidth - allocatedWidth) / remaining / 100;

        for (var j = 0; j < len; j++) {
          var c = cs[j];

          if (!c.width) {
            c.width = perCol;
          }
        }
      }
    }

    Ext.list.ListView.superclass.initComponent.call(this);
  },
  onRender: function onRender() {
    this.autoEl = {
      cls: 'x-list-wrap'
    };
    Ext.list.ListView.superclass.onRender.apply(this, arguments);
    this.internalTpl.overwrite(this.el, {
      columns: this.columns
    });
    this.innerBody = Ext.get(this.el.dom.childNodes[1].firstChild);
    this.innerHd = Ext.get(this.el.dom.firstChild.firstChild);

    if (this.hideHeaders) {
      this.el.dom.firstChild.style.display = 'none';
    }
  },
  getTemplateTarget: function getTemplateTarget() {
    return this.innerBody;
  },

  /**
   * <p>Function which can be overridden which returns the data object passed to this
   * view's {@link #tpl template} to render the whole ListView. The returned object 
   * shall contain the following properties:</p>
   * <div class="mdetail-params"><ul>
   * <li><b>columns</b> : String<div class="sub-desc">See <tt>{@link #columns}</tt></div></li>
   * <li><b>rows</b> : String<div class="sub-desc">See
   * <tt>{@link Ext.DataView}.{@link Ext.DataView#collectData collectData}</div></li>
   * </ul></div>
   * @param {Array} records An Array of {@link Ext.data.Record}s to be rendered into the DataView.
   * @param {Number} startIndex the index number of the Record being prepared for rendering.
   * @return {Object} A data object containing properties to be processed by a repeating
   * XTemplate as described above.
   */
  collectData: function collectData() {
    var rs = Ext.list.ListView.superclass.collectData.apply(this, arguments);
    return {
      columns: this.columns,
      rows: rs
    };
  },
  verifyInternalSize: function verifyInternalSize() {
    if (this.lastSize) {
      this.onResize(this.lastSize.width, this.lastSize.height);
    }
  },
  // private
  onResize: function onResize(w, h) {
    var bd = this.innerBody.dom;
    var hd = this.innerHd.dom;

    if (!bd) {
      return;
    }

    var bdp = bd.parentNode;

    if (Ext.isNumber(w)) {
      var sw = w - Ext.num(this.scrollOffset, Ext.getScrollBarWidth());

      if (this.reserveScrollOffset || bdp.offsetWidth - bdp.clientWidth > 10) {
        bd.style.width = sw + 'px';
        hd.style.width = sw + 'px';
      } else {
        bd.style.width = w + 'px';
        hd.style.width = w + 'px';
        setTimeout(function () {
          if (bdp.offsetWidth - bdp.clientWidth > 10) {
            bd.style.width = sw + 'px';
            hd.style.width = sw + 'px';
          }
        }, 10);
      }
    }

    if (Ext.isNumber(h)) {
      bdp.style.height = h - hd.parentNode.offsetHeight + 'px';
    }
  },
  updateIndexes: function updateIndexes() {
    Ext.list.ListView.superclass.updateIndexes.apply(this, arguments);
    this.verifyInternalSize();
  },
  findHeaderIndex: function findHeaderIndex(hd) {
    hd = hd.dom || hd;
    var pn = hd.parentNode,
        cs = pn.parentNode.childNodes;

    for (var i = 0, c; c = cs[i]; i++) {
      if (c == pn) {
        return i;
      }
    }

    return -1;
  },
  setHdWidths: function setHdWidths() {
    var els = this.innerHd.dom.getElementsByTagName('div');

    for (var i = 0, cs = this.columns, len = cs.length; i < len; i++) {
      els[i].style.width = cs[i].width * 100 + '%';
    }
  }
});
Ext.reg('listview', Ext.list.ListView); // Backwards compatibility alias

Ext.ListView = Ext.list.ListView;

/***/ }),
/* 832 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.list.Column
 * <p>This class encapsulates column configuration data to be used in the initialization of a
 * {@link Ext.list.ListView ListView}.</p>
 * <p>While subclasses are provided to render data in different ways, this class renders a passed
 * data field unchanged and is usually used for textual columns.</p>
 */
Ext.list.Column = Ext.extend(Object, {
  /**
   * @private
   * @cfg {Boolean} isColumn
   * Used by ListView constructor method to avoid reprocessing a Column
   * if <code>isColumn</code> is not set ListView will recreate a new Ext.list.Column
   * Defaults to true.
   */
  isColumn: true,

  /**
   * @cfg {String} align
   * Set the CSS text-align property of the column. Defaults to <tt>'left'</tt>.
   */
  align: 'left',

  /**
   * @cfg {String} header Optional. The header text to be used as innerHTML
   * (html tags are accepted) to display in the ListView.  <b>Note</b>: to
   * have a clickable header with no text displayed use <tt>'&#160;'</tt>.
   */
  header: '',

  /**
   * @cfg {Number} width Optional. Percentage of the container width
   * this column should be allocated.  Columns that have no width specified will be
   * allocated with an equal percentage to fill 100% of the container width.  To easily take
   * advantage of the full container width, leave the width of at least one column undefined.
   * Note that if you do not want to take up the full width of the container, the width of
   * every column needs to be explicitly defined.
   */
  width: null,

  /**
   * @cfg {String} cls Optional. This option can be used to add a CSS class to the cell of each
   * row for this column.
   */
  cls: '',

  /**
   * @cfg {String} tpl Optional. Specify a string to pass as the
   * configuration string for {@link Ext.XTemplate}.  By default an {@link Ext.XTemplate}
   * will be implicitly created using the <tt>dataIndex</tt>.
   */

  /**
   * @cfg {String} dataIndex <p><b>Required</b>. The name of the field in the
   * ListViews's {@link Ext.data.Store}'s {@link Ext.data.Record} definition from
   * which to draw the column's value.</p>
   */
  constructor: function constructor(c) {
    if (!c.tpl) {
      c.tpl = new Ext.XTemplate('{' + c.dataIndex + '}');
    } else if (Ext.isString(c.tpl)) {
      c.tpl = new Ext.XTemplate(c.tpl);
    }

    Ext.apply(this, c);
  }
});
Ext.reg('lvcolumn', Ext.list.Column);
/**
 * @class Ext.list.NumberColumn
 * @extends Ext.list.Column
 * <p>A Column definition class which renders a numeric data field according to a {@link #format} string.  See the
 * {@link Ext.list.Column#xtype xtype} config option of {@link Ext.list.Column} for more details.</p>
 */

Ext.list.NumberColumn = Ext.extend(Ext.list.Column, {
  /**
   * @cfg {String} format
   * A formatting string as used by {@link Ext.util.Format#number} to format a numeric value for this Column
   * (defaults to <tt>'0,000.00'</tt>).
   */
  format: '0,000.00',
  constructor: function constructor(c) {
    c.tpl = c.tpl || new Ext.XTemplate('{' + c.dataIndex + ':number("' + (c.format || this.format) + '")}');
    Ext.list.NumberColumn.superclass.constructor.call(this, c);
  }
});
Ext.reg('lvnumbercolumn', Ext.list.NumberColumn);
/**
 * @class Ext.list.DateColumn
 * @extends Ext.list.Column
 * <p>A Column definition class which renders a passed date according to the default locale, or a configured
 * {@link #format}. See the {@link Ext.list.Column#xtype xtype} config option of {@link Ext.list.Column}
 * for more details.</p>
 */

Ext.list.DateColumn = Ext.extend(Ext.list.Column, {
  format: 'm/d/Y',
  constructor: function constructor(c) {
    c.tpl = c.tpl || new Ext.XTemplate('{' + c.dataIndex + ':date("' + (c.format || this.format) + '")}');
    Ext.list.DateColumn.superclass.constructor.call(this, c);
  }
});
Ext.reg('lvdatecolumn', Ext.list.DateColumn);
/**
 * @class Ext.list.BooleanColumn
 * @extends Ext.list.Column
 * <p>A Column definition class which renders boolean data fields.  See the {@link Ext.list.Column#xtype xtype}
 * config option of {@link Ext.list.Column} for more details.</p>
 */

Ext.list.BooleanColumn = Ext.extend(Ext.list.Column, {
  /**
   * @cfg {String} trueText
   * The string returned by the renderer when the column value is not falsey (defaults to <tt>'true'</tt>).
   */
  trueText: 'true',

  /**
   * @cfg {String} falseText
   * The string returned by the renderer when the column value is falsey (but not undefined) (defaults to
   * <tt>'false'</tt>).
   */
  falseText: 'false',

  /**
   * @cfg {String} undefinedText
   * The string returned by the renderer when the column value is undefined (defaults to <tt>'&#160;'</tt>).
   */
  undefinedText: '&#160;',
  constructor: function constructor(c) {
    c.tpl = c.tpl || new Ext.XTemplate('{' + c.dataIndex + ':this.format}');
    var t = this.trueText,
        f = this.falseText,
        u = this.undefinedText;

    c.tpl.format = function (v) {
      if (v === undefined) {
        return u;
      }

      if (!v || v === 'false') {
        return f;
      }

      return t;
    };

    Ext.list.DateColumn.superclass.constructor.call(this, c);
  }
});
Ext.reg('lvbooleancolumn', Ext.list.BooleanColumn);

/***/ }),
/* 833 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.list.ColumnResizer
 * @extends Ext.util.Observable
 * <p>Supporting Class for Ext.list.ListView</p>
 * @constructor
 * @param {Object} config
 */
Ext.list.ColumnResizer = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Number} minPct The minimum percentage to allot for any column (defaults to <tt>.05</tt>)
   */
  minPct: .05,
  constructor: function constructor(config) {
    Ext.apply(this, config);
    Ext.list.ColumnResizer.superclass.constructor.call(this);
  },
  init: function init(listView) {
    this.view = listView;
    listView.on('render', this.initEvents, this);
  },
  initEvents: function initEvents(view) {
    view.mon(view.innerHd, 'mousemove', this.handleHdMove, this);
    this.tracker = new Ext.dd.DragTracker({
      onBeforeStart: this.onBeforeStart.createDelegate(this),
      onStart: this.onStart.createDelegate(this),
      onDrag: this.onDrag.createDelegate(this),
      onEnd: this.onEnd.createDelegate(this),
      tolerance: 3,
      autoStart: 300
    });
    this.tracker.initEl(view.innerHd);
    view.on('beforedestroy', this.tracker.destroy, this.tracker);
  },
  handleHdMove: function handleHdMove(e, t) {
    var hw = 5,
        x = e.getPageX(),
        hd = e.getTarget('em', 3, true);

    if (hd) {
      var r = hd.getRegion(),
          ss = hd.dom.style,
          pn = hd.dom.parentNode;

      if (x - r.left <= hw && pn != pn.parentNode.firstChild) {
        this.activeHd = Ext.get(pn.previousSibling.firstChild);
        ss.cursor = Ext.isWebKit ? 'e-resize' : 'col-resize';
      } else if (r.right - x <= hw && pn != pn.parentNode.lastChild.previousSibling) {
        this.activeHd = hd;
        ss.cursor = Ext.isWebKit ? 'w-resize' : 'col-resize';
      } else {
        delete this.activeHd;
        ss.cursor = '';
      }
    }
  },
  onBeforeStart: function onBeforeStart(e) {
    this.dragHd = this.activeHd;
    return !!this.dragHd;
  },
  onStart: function onStart(e) {
    this.view.disableHeaders = true;
    this.proxy = this.view.el.createChild({
      cls: 'x-list-resizer'
    });
    this.proxy.setHeight(this.view.el.getHeight());
    var x = this.tracker.getXY()[0],
        w = this.view.innerHd.getWidth();
    this.hdX = this.dragHd.getX();
    this.hdIndex = this.view.findHeaderIndex(this.dragHd);
    this.proxy.setX(this.hdX);
    this.proxy.setWidth(x - this.hdX);
    this.minWidth = w * this.minPct;
    this.maxWidth = w - this.minWidth * (this.view.columns.length - 1 - this.hdIndex);
  },
  onDrag: function onDrag(e) {
    var cursorX = this.tracker.getXY()[0];
    this.proxy.setWidth((cursorX - this.hdX).constrain(this.minWidth, this.maxWidth));
  },
  onEnd: function onEnd(e) {
    /* calculate desired width by measuring proxy and then remove it */
    var nw = this.proxy.getWidth();
    this.proxy.remove();
    var index = this.hdIndex,
        vw = this.view,
        cs = vw.columns,
        len = cs.length,
        w = this.view.innerHd.getWidth(),
        minPct = this.minPct * 100,
        pct = Math.ceil(nw * vw.maxWidth / w),
        diff = cs[index].width * 100 - pct,
        each = Math.floor(diff / (len - 1 - index)),
        mod = diff - each * (len - 1 - index);

    for (var i = index + 1; i < len; i++) {
      var cw = cs[i].width * 100 + each,
          ncw = Math.max(minPct, cw);

      if (cw != ncw) {
        mod += cw - ncw;
      }

      cs[i].width = ncw / 100;
    }

    cs[index].width = pct / 100;
    cs[index + 1].width += mod / 100;
    delete this.dragHd;
    vw.setHdWidths();
    vw.refresh();
    setTimeout(function () {
      vw.disableHeaders = false;
    }, 100);
  }
}); // Backwards compatibility alias

Ext.ListView.ColumnResizer = Ext.list.ColumnResizer;

/***/ }),
/* 834 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.list.Sorter
 * @extends Ext.util.Observable
 * <p>Supporting Class for Ext.list.ListView</p>
 * @constructor
 * @param {Object} config
 */
Ext.list.Sorter = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Array} sortClasses
   * The CSS classes applied to a header when it is sorted. (defaults to <tt>["sort-asc", "sort-desc"]</tt>)
   */
  sortClasses: ["sort-asc", "sort-desc"],
  constructor: function constructor(config) {
    Ext.apply(this, config);
    Ext.list.Sorter.superclass.constructor.call(this);
  },
  init: function init(listView) {
    this.view = listView;
    listView.on('render', this.initEvents, this);
  },
  initEvents: function initEvents(view) {
    view.mon(view.innerHd, 'click', this.onHdClick, this);
    view.innerHd.setStyle('cursor', 'pointer');
    view.mon(view.store, 'datachanged', this.updateSortState, this);
    this.updateSortState.defer(10, this, [view.store]);
  },
  updateSortState: function updateSortState(store) {
    var state = store.getSortState();

    if (!state) {
      return;
    }

    this.sortState = state;
    var cs = this.view.columns,
        sortColumn = -1;

    for (var i = 0, len = cs.length; i < len; i++) {
      if (cs[i].dataIndex == state.field) {
        sortColumn = i;
        break;
      }
    }

    if (sortColumn != -1) {
      var sortDir = state.direction;
      this.updateSortIcon(sortColumn, sortDir);
    }
  },
  updateSortIcon: function updateSortIcon(col, dir) {
    var sc = this.sortClasses;
    var hds = this.view.innerHd.select('em').removeClass(sc);
    hds.item(col).addClass(sc[dir == "DESC" ? 1 : 0]);
  },
  onHdClick: function onHdClick(e) {
    var hd = e.getTarget('em', 3);

    if (hd && !this.view.disableHeaders) {
      var index = this.view.findHeaderIndex(hd);
      this.view.store.sort(this.view.columns[index].dataIndex);
    }
  }
}); // Backwards compatibility alias

Ext.ListView.Sorter = Ext.list.Sorter;

/***/ }),
/* 835 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.TabPanel
 * <p>A basic tab container. TabPanels can be used exactly like a standard {@link Ext.Panel}
 * for layout purposes, but also have special support for containing child Components
 * (<tt>{@link Ext.Container#items items}</tt>) that are managed using a
 * {@link Ext.layout.CardLayout CardLayout layout manager}, and displayed as separate tabs.</p>
 *
 * <b>Note:</b> By default, a tab's close tool <i>destroys</i> the child tab Component
 * and all its descendants. This makes the child tab Component, and all its descendants <b>unusable</b>. To enable
 * re-use of a tab, configure the TabPanel with <b><code>{@link #autoDestroy autoDestroy: false}</code></b>.
 *
 * <p><b><u>TabPanel header/footer elements</u></b></p>
 * <p>TabPanels use their {@link Ext.Panel#header header} or {@link Ext.Panel#footer footer} element
 * (depending on the {@link #tabPosition} configuration) to accommodate the tab selector buttons.
 * This means that a TabPanel will not display any configured title, and will not display any
 * configured header {@link Ext.Panel#tools tools}.</p>
 * <p>To display a header, embed the TabPanel in a {@link Ext.Panel Panel} which uses
 * <b><tt>{@link Ext.Container#layout layout:'fit'}</tt></b>.</p>
 *
 * <p><b><u>Tab Events</u></b></p>
 * <p>There is no actual tab class &mdash; each tab is simply a {@link Ext.BoxComponent Component}
 * such as a {@link Ext.Panel Panel}. However, when rendered in a TabPanel, each child Component
 * can fire additional events that only exist for tabs and are not available from other Components.
 * These events are:</p>
 * <div><ul class="mdetail-params">
 * <li><tt><b>{@link Ext.Panel#activate activate}</b></tt> : Fires when this Component becomes
 * the active tab.</li>
 * <li><tt><b>{@link Ext.Panel#deactivate deactivate}</b></tt> : Fires when the Component that
 * was the active tab becomes deactivated.</li>
 * <li><tt><b>{@link Ext.Panel#beforeclose beforeclose}</b></tt> : Fires when the user clicks on the close tool of a closeable tab.
 * May be vetoed by returning <code>false</code> from a handler.</li>
 * <li><tt><b>{@link Ext.Panel#close close}</b></tt> : Fires a closeable tab has been closed by the user.</li>
 * </ul></div>
 * <p><b><u>Creating TabPanels from Code</u></b></p>
 * <p>TabPanels can be created and rendered completely in code, as in this example:</p>
 * <pre><code>
var tabs = new Ext.TabPanel({
    renderTo: Ext.getBody(),
    activeTab: 0,
    items: [{
        title: 'Tab 1',
        html: 'A simple tab'
    },{
        title: 'Tab 2',
        html: 'Another one'
    }]
});
</code></pre>
 * <p><b><u>Creating TabPanels from Existing Markup</u></b></p>
 * <p>TabPanels can also be rendered from pre-existing markup in a couple of ways.</p>
 * <div><ul class="mdetail-params">
 *
 * <li>Pre-Structured Markup</li>
 * <div class="sub-desc">
 * <p>A container div with one or more nested tab divs with class <tt>'x-tab'</tt> can be rendered entirely
 * from existing markup (See the {@link #autoTabs} example).</p>
 * </div>
 *
 * <li>Un-Structured Markup</li>
 * <div class="sub-desc">
 * <p>A TabPanel can also be rendered from markup that is not strictly structured by simply specifying by id
 * which elements should be the container and the tabs. Using this method tab content can be pulled from different
 * elements within the page by id regardless of page structure. For example:</p>
 * <pre><code>
var tabs = new Ext.TabPanel({
    renderTo: 'my-tabs',
    activeTab: 0,
    items:[
        {contentEl:'tab1', title:'Tab 1'},
        {contentEl:'tab2', title:'Tab 2'}
    ]
});

// Note that the tabs do not have to be nested within the container (although they can be)
&lt;div id="my-tabs">&lt;/div>
&lt;div id="tab1" class="x-hide-display">A simple tab&lt;/div>
&lt;div id="tab2" class="x-hide-display">Another one&lt;/div>
</code></pre>
 * Note that the tab divs in this example contain the class <tt>'x-hide-display'</tt> so that they can be rendered
 * deferred without displaying outside the tabs. You could alternately set <tt>{@link #deferredRender} = false </tt>
 * to render all content tabs on page load.
 * </div>
 *
 * </ul></div>
 *
 * @extends Ext.Panel
 * @constructor
 * @param {Object} config The configuration options
 * @xtype tabpanel
 */
Ext.TabPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Boolean} layoutOnTabChange
   * Set to true to force a layout of the active tab when the tab is changed. Defaults to false.
   * See {@link Ext.layout.CardLayout}.<code>{@link Ext.layout.CardLayout#layoutOnCardChange layoutOnCardChange}</code>.
   */

  /**
   * @cfg {String} tabCls <b>This config option is used on <u>child Components</u> of ths TabPanel.</b> A CSS
   * class name applied to the tab strip item representing the child Component, allowing special
   * styling to be applied.
   */

  /**
   * @cfg {Boolean} deferredRender
   * <p><tt>true</tt> by default to defer the rendering of child <tt>{@link Ext.Container#items items}</tt>
   * to the browsers DOM until a tab is activated. <tt>false</tt> will render all contained
   * <tt>{@link Ext.Container#items items}</tt> as soon as the {@link Ext.layout.CardLayout layout}
   * is rendered. If there is a significant amount of content or a lot of heavy controls being
   * rendered into panels that are not displayed by default, setting this to <tt>true</tt> might
   * improve performance.</p>
   * <br><p>The <tt>deferredRender</tt> property is internally passed to the layout manager for
   * TabPanels ({@link Ext.layout.CardLayout}) as its {@link Ext.layout.CardLayout#deferredRender}
   * configuration value.</p>
   * <br><p><b>Note</b>: leaving <tt>deferredRender</tt> as <tt>true</tt> means that the content
   * within an unactivated tab will not be available. For example, this means that if the TabPanel
   * is within a {@link Ext.form.FormPanel form}, then until a tab is activated, any Fields within
   * unactivated tabs will not be rendered, and will therefore not be submitted and will not be
   * available to either {@link Ext.form.BasicForm#getValues getValues} or
   * {@link Ext.form.BasicForm#setValues setValues}.</p>
   */
  deferredRender: true,

  /**
   * @cfg {Number} tabWidth The initial width in pixels of each new tab (defaults to 120).
   */
  tabWidth: 120,

  /**
   * @cfg {Number} minTabWidth The minimum width in pixels for each tab when {@link #resizeTabs} = true (defaults to 30).
   */
  minTabWidth: 30,

  /**
   * @cfg {Boolean} resizeTabs True to automatically resize each tab so that the tabs will completely fill the
   * tab strip (defaults to false).  Setting this to true may cause specific widths that might be set per tab to
   * be overridden in order to fit them all into view (although {@link #minTabWidth} will always be honored).
   */
  resizeTabs: false,

  /**
   * @cfg {Boolean} enableTabScroll True to enable scrolling to tabs that may be invisible due to overflowing the
   * overall TabPanel width. Only available with tabPosition:'top' (defaults to false).
   */
  enableTabScroll: false,

  /**
   * @cfg {Number} scrollIncrement The number of pixels to scroll each time a tab scroll button is pressed
   * (defaults to <tt>100</tt>, or if <tt>{@link #resizeTabs} = true</tt>, the calculated tab width).  Only
   * applies when <tt>{@link #enableTabScroll} = true</tt>.
   */
  scrollIncrement: 0,

  /**
   * @cfg {Number} scrollRepeatInterval Number of milliseconds between each scroll while a tab scroll button is
   * continuously pressed (defaults to <tt>400</tt>).
   */
  scrollRepeatInterval: 400,

  /**
   * @cfg {Float} scrollDuration The number of milliseconds that each scroll animation should last (defaults
   * to <tt>.35</tt>). Only applies when <tt>{@link #animScroll} = true</tt>.
   */
  scrollDuration: 0.35,

  /**
   * @cfg {Boolean} animScroll True to animate tab scrolling so that hidden tabs slide smoothly into view (defaults
   * to <tt>true</tt>).  Only applies when <tt>{@link #enableTabScroll} = true</tt>.
   */
  animScroll: true,

  /**
   * @cfg {String} tabPosition The position where the tab strip should be rendered (defaults to <tt>'top'</tt>).
   * The only other supported value is <tt>'bottom'</tt>.  <b>Note</b>: tab scrolling is only supported for
   * <tt>tabPosition: 'top'</tt>.
   */
  tabPosition: 'top',

  /**
   * @cfg {String} baseCls The base CSS class applied to the panel (defaults to <tt>'x-tab-panel'</tt>).
   */
  baseCls: 'x-tab-panel',

  /**
   * @cfg {Boolean} autoTabs
   * <p><tt>true</tt> to query the DOM for any divs with a class of 'x-tab' to be automatically converted
   * to tabs and added to this panel (defaults to <tt>false</tt>).  Note that the query will be executed within
   * the scope of the container element only (so that multiple tab panels from markup can be supported via this
   * method).</p>
   * <p>This method is only possible when the markup is structured correctly as a container with nested divs
   * containing the class <tt>'x-tab'</tt>. To create TabPanels without these limitations, or to pull tab content
   * from other elements on the page, see the example at the top of the class for generating tabs from markup.</p>
   * <p>There are a couple of things to note when using this method:<ul>
   * <li>When using the <tt>autoTabs</tt> config (as opposed to passing individual tab configs in the TabPanel's
   * {@link #items} collection), you must use <tt>{@link #applyTo}</tt> to correctly use the specified <tt>id</tt>
   * as the tab container. The <tt>autoTabs</tt> method <em>replaces</em> existing content with the TabPanel
   * components.</li>
   * <li>Make sure that you set <tt>{@link #deferredRender}: false</tt> so that the content elements for each
   * tab will be rendered into the TabPanel immediately upon page load, otherwise they will not be transformed
   * until each tab is activated and will be visible outside the TabPanel.</li>
   * </ul>Example usage:</p>
   * <pre><code>
  var tabs = new Ext.TabPanel({
  applyTo: 'my-tabs',
  activeTab: 0,
  deferredRender: false,
  autoTabs: true
  });
  // This markup will be converted to a TabPanel from the code above
  &lt;div id="my-tabs">
  &lt;div class="x-tab" title="Tab 1">A simple tab&lt;/div>
  &lt;div class="x-tab" title="Tab 2">Another one&lt;/div>
  &lt;/div>
  </code></pre>
   */
  autoTabs: false,

  /**
   * @cfg {String} autoTabSelector The CSS selector used to search for tabs in existing markup when
   * <tt>{@link #autoTabs} = true</tt> (defaults to <tt>'div.x-tab'</tt>).  This can be any valid selector
   * supported by {@link Ext.DomQuery#select}. Note that the query will be executed within the scope of this
   * tab panel only (so that multiple tab panels from markup can be supported on a page).
   */
  autoTabSelector: 'div.x-tab',

  /**
   * @cfg {String/Number} activeTab A string id or the numeric index of the tab that should be initially
   * activated on render (defaults to undefined).
   */
  activeTab: undefined,

  /**
   * @cfg {Number} tabMargin The number of pixels of space to calculate into the sizing and scrolling of
   * tabs. If you change the margin in CSS, you will need to update this value so calculations are correct
   * with either <tt>{@link #resizeTabs}</tt> or scrolling tabs. (defaults to <tt>2</tt>)
   */
  tabMargin: 2,

  /**
   * @cfg {Boolean} plain </tt>true</tt> to render the tab strip without a background container image
   * (defaults to <tt>false</tt>).
   */
  plain: false,

  /**
   * @cfg {Number} wheelIncrement For scrolling tabs, the number of pixels to increment on mouse wheel
   * scrolling (defaults to <tt>20</tt>).
   */
  wheelIncrement: 20,

  /*
   * This is a protected property used when concatenating tab ids to the TabPanel id for internal uniqueness.
   * It does not generally need to be changed, but can be if external code also uses an id scheme that can
   * potentially clash with this one.
   */
  idDelimiter: '__',
  // private
  itemCls: 'x-tab-item',
  // private config overrides
  elements: 'body',
  headerAsText: false,
  frame: false,
  hideBorders: true,
  // private
  initComponent: function initComponent() {
    this.frame = false;
    Ext.TabPanel.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event beforetabchange
     * Fires before the active tab changes. Handlers can <tt>return false</tt> to cancel the tab change.
     * @param {TabPanel} this
     * @param {Panel} newTab The tab being activated
     * @param {Panel} currentTab The current active tab
     */
    'beforetabchange',
    /**
     * @event tabchange
     * Fires after the active tab has changed.
     * @param {TabPanel} this
     * @param {Panel} tab The new active tab
     */
    'tabchange',
    /**
     * @event contextmenu
     * Relays the contextmenu event from a tab selector element in the tab strip.
     * @param {TabPanel} this
     * @param {Panel} tab The target tab
     * @param {EventObject} e
     */
    'contextmenu');
    /**
     * @cfg {Object} layoutConfig
     * TabPanel implicitly uses {@link Ext.layout.CardLayout} as its layout manager.
     * <code>layoutConfig</code> may be used to configure this layout manager.
     * <code>{@link #deferredRender}</code> and <code>{@link #layoutOnTabChange}</code>
     * configured on the TabPanel will be applied as configs to the layout manager.
     */

    this.setLayout(new Ext.layout.CardLayout(Ext.apply({
      layoutOnCardChange: this.layoutOnTabChange,
      deferredRender: this.deferredRender
    }, this.layoutConfig)));

    if (this.tabPosition == 'top') {
      this.elements += ',header';
      this.stripTarget = 'header';
    } else {
      this.elements += ',footer';
      this.stripTarget = 'footer';
    }

    if (!this.stack) {
      this.stack = Ext.TabPanel.AccessStack();
    }

    this.initItems();
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.TabPanel.superclass.onRender.call(this, ct, position);

    if (this.plain) {
      var pos = this.tabPosition == 'top' ? 'header' : 'footer';
      this[pos].addClass('x-tab-panel-' + pos + '-plain');
    }

    var st = this[this.stripTarget];
    this.stripWrap = st.createChild({
      cls: 'x-tab-strip-wrap',
      cn: {
        tag: 'ul',
        cls: 'x-tab-strip x-tab-strip-' + this.tabPosition
      }
    });
    var beforeEl = this.tabPosition == 'bottom' ? this.stripWrap : null;
    st.createChild({
      cls: 'x-tab-strip-spacer'
    }, beforeEl);
    this.strip = new Ext.Element(this.stripWrap.dom.firstChild); // create an empty span with class x-tab-strip-text to force the height of the header element when there's no tabs.

    this.edge = this.strip.createChild({
      tag: 'li',
      cls: 'x-tab-edge',
      cn: [{
        tag: 'span',
        cls: 'x-tab-strip-text',
        cn: '&#160;'
      }]
    });
    this.strip.createChild({
      cls: 'x-clear'
    });
    this.body.addClass('x-tab-panel-body-' + this.tabPosition);
    /**
     * @cfg {Template/XTemplate} itemTpl <p>(Optional) A {@link Ext.Template Template} or
     * {@link Ext.XTemplate XTemplate} which may be provided to process the data object returned from
     * <tt>{@link #getTemplateArgs}</tt> to produce a clickable selector element in the tab strip.</p>
     * <p>The main element created should be a <tt>&lt;li></tt> element. In order for a click event on
     * a selector element to be connected to its item, it must take its <i>id</i> from the TabPanel's
     * native <tt>{@link #getTemplateArgs}</tt>.</p>
     * <p>The child element which contains the title text must be marked by the CSS class
     * <tt>x-tab-strip-inner</tt>.</p>
     * <p>To enable closability, the created element should contain an element marked by the CSS class
     * <tt>x-tab-strip-close</tt>.</p>
     * <p>If a custom <tt>itemTpl</tt> is supplied, it is the developer's responsibility to create CSS
     * style rules to create the desired appearance.</p>
     * Below is an example of how to create customized tab selector items:<pre><code>
    new Ext.TabPanel({
    renderTo: document.body,
    minTabWidth: 115,
    tabWidth: 135,
    enableTabScroll: true,
    width: 600,
    height: 250,
    defaults: {autoScroll:true},
    itemTpl: new Ext.XTemplate(
    '&lt;li class="{cls}" id="{id}" style="overflow:hidden">',
     '&lt;tpl if="closable">',
        '&lt;a class="x-tab-strip-close">&lt;/a>',
     '&lt;/tpl>',
     '&lt;a class="x-tab-right" href="#" style="padding-left:6px">',
        '&lt;em class="x-tab-left">',
            '&lt;span class="x-tab-strip-inner">',
                '&lt;img src="{src}" style="float:left;margin:3px 3px 0 0">',
                '&lt;span style="margin-left:20px" class="x-tab-strip-text {iconCls}">{text} {extra}&lt;/span>',
            '&lt;/span>',
        '&lt;/em>',
    '&lt;/a>',
    '&lt;/li>'
    ),
    getTemplateArgs: function(item) {
    //      Call the native method to collect the base data. Like the ID!
    var result = Ext.TabPanel.prototype.getTemplateArgs.call(this, item);
    //      Add stuff used in our template
    return Ext.apply(result, {
        closable: item.closable,
        src: item.iconSrc,
        extra: item.extraText || ''
    });
    },
    items: [{
    title: 'New Tab 1',
    iconSrc: '../shared/icons/fam/grid.png',
    html: 'Tab Body 1',
    closable: true
    }, {
    title: 'New Tab 2',
    iconSrc: '../shared/icons/fam/grid.png',
    html: 'Tab Body 2',
    extraText: 'Extra stuff in the tab button'
    }]
    });
    </code></pre>
     */

    if (!this.itemTpl) {
      var tt = new Ext.Template('<li class="{cls}" id="{id}"><a class="x-tab-strip-close"></a>', '<a class="x-tab-right" href="#"><em class="x-tab-left">', '<span class="x-tab-strip-inner"><span class="x-tab-strip-text {iconCls}">{text}</span></span>', '</em></a></li>');
      tt.disableFormats = true;
      tt.compile();
      Ext.TabPanel.prototype.itemTpl = tt;
    }

    this.items.each(this.initTab, this);
  },
  // private
  afterRender: function afterRender() {
    Ext.TabPanel.superclass.afterRender.call(this);

    if (this.autoTabs) {
      this.readTabs(false);
    }

    if (this.activeTab !== undefined) {
      var item = Ext.isObject(this.activeTab) ? this.activeTab : this.items.get(this.activeTab);
      delete this.activeTab;
      this.setActiveTab(item);
    }
  },
  // private
  initEvents: function initEvents() {
    Ext.TabPanel.superclass.initEvents.call(this);
    this.mon(this.strip, {
      scope: this,
      mousedown: this.onStripMouseDown,
      contextmenu: this.onStripContextMenu
    });

    if (this.enableTabScroll) {
      this.mon(this.strip, 'mousewheel', this.onWheel, this);
    }
  },
  // private
  findTargets: function findTargets(e) {
    var item = null,
        itemEl = e.getTarget('li:not(.x-tab-edge)', this.strip);

    if (itemEl) {
      item = this.getComponent(itemEl.id.split(this.idDelimiter)[1]);

      if (item.disabled) {
        return {
          close: null,
          item: null,
          el: null
        };
      }
    }

    return {
      close: e.getTarget('.x-tab-strip-close', this.strip),
      item: item,
      el: itemEl
    };
  },
  // private
  onStripMouseDown: function onStripMouseDown(e) {
    if (e.button !== 0) {
      return;
    }

    e.preventDefault();
    var t = this.findTargets(e);

    if (t.close) {
      if (t.item.fireEvent('beforeclose', t.item) !== false) {
        t.item.fireEvent('close', t.item);
        this.remove(t.item);
      }

      return;
    }

    if (t.item && t.item != this.activeTab) {
      this.setActiveTab(t.item);
    }
  },
  // private
  onStripContextMenu: function onStripContextMenu(e) {
    e.preventDefault();
    var t = this.findTargets(e);

    if (t.item) {
      this.fireEvent('contextmenu', this, t.item, e);
    }
  },

  /**
   * True to scan the markup in this tab panel for <tt>{@link #autoTabs}</tt> using the
   * <tt>{@link #autoTabSelector}</tt>
   * @param {Boolean} removeExisting True to remove existing tabs
   */
  readTabs: function readTabs(removeExisting) {
    if (removeExisting === true) {
      this.items.each(function (item) {
        this.remove(item);
      }, this);
    }

    var tabs = this.el.query(this.autoTabSelector);

    for (var i = 0, len = tabs.length; i < len; i++) {
      var tab = tabs[i],
          title = tab.getAttribute('title');
      tab.removeAttribute('title');
      this.add({
        title: title,
        contentEl: tab
      });
    }
  },
  // private
  initTab: function initTab(item, index) {
    var before = this.strip.dom.childNodes[index],
        p = this.getTemplateArgs(item),
        el = before ? this.itemTpl.insertBefore(before, p) : this.itemTpl.append(this.strip, p),
        cls = 'x-tab-strip-over',
        tabEl = Ext.get(el);
    tabEl.hover(function () {
      if (!item.disabled) {
        tabEl.addClass(cls);
      }
    }, function () {
      tabEl.removeClass(cls);
    });

    if (item.tabTip) {
      tabEl.child('span.x-tab-strip-text', true).qtip = item.tabTip;
    }

    item.tabEl = el; // Route *keyboard triggered* click events to the tab strip mouse handler.

    tabEl.select('a').on('click', function (e) {
      if (!e.getPageX()) {
        this.onStripMouseDown(e);
      }
    }, this, {
      preventDefault: true
    });
    item.on({
      scope: this,
      disable: this.onItemDisabled,
      enable: this.onItemEnabled,
      titlechange: this.onItemTitleChanged,
      iconchange: this.onItemIconChanged,
      beforeshow: this.onBeforeShowItem
    });
  },

  /**
   * <p>Provides template arguments for rendering a tab selector item in the tab strip.</p>
   * <p>This method returns an object hash containing properties used by the TabPanel's <tt>{@link #itemTpl}</tt>
   * to create a formatted, clickable tab selector element. The properties which must be returned
   * are:</p><div class="mdetail-params"><ul>
   * <li><b>id</b> : String<div class="sub-desc">A unique identifier which links to the item</div></li>
   * <li><b>text</b> : String<div class="sub-desc">The text to display</div></li>
   * <li><b>cls</b> : String<div class="sub-desc">The CSS class name</div></li>
   * <li><b>iconCls</b> : String<div class="sub-desc">A CSS class to provide appearance for an icon.</div></li>
   * </ul></div>
   * @param {BoxComponent} item The {@link Ext.BoxComponent BoxComponent} for which to create a selector element in the tab strip.
   * @return {Object} An object hash containing the properties required to render the selector element.
   */
  getTemplateArgs: function getTemplateArgs(item) {
    var cls = item.closable ? 'x-tab-strip-closable' : '';

    if (item.disabled) {
      cls += ' x-item-disabled';
    }

    if (item.iconCls) {
      cls += ' x-tab-with-icon';
    }

    if (item.tabCls) {
      cls += ' ' + item.tabCls;
    }

    return {
      id: this.id + this.idDelimiter + item.getItemId(),
      text: item.title,
      cls: cls,
      iconCls: item.iconCls || ''
    };
  },
  // private
  onAdd: function onAdd(c) {
    Ext.TabPanel.superclass.onAdd.call(this, c);

    if (this.rendered) {
      var items = this.items;
      this.initTab(c, items.indexOf(c));

      if (items.getCount() == 1) {
        this.syncSize();
      }

      this.delegateUpdates();
    }
  },
  // private
  onBeforeAdd: function onBeforeAdd(item) {
    var existing = item.events ? this.items.containsKey(item.getItemId()) ? item : null : this.items.get(item);

    if (existing) {
      this.setActiveTab(item);
      return false;
    }

    Ext.TabPanel.superclass.onBeforeAdd.apply(this, arguments);
    var es = item.elements;
    item.elements = es ? es.replace(',header', '') : es;
    item.border = item.border === true;
  },
  // private
  onRemove: function onRemove(c) {
    var te = Ext.get(c.tabEl); // check if the tabEl exists, it won't if the tab isn't rendered

    if (te) {
      te.select('a').removeAllListeners();
      Ext.destroy(te);
    }

    Ext.TabPanel.superclass.onRemove.call(this, c);
    this.stack.remove(c);
    delete c.tabEl;
    c.un('disable', this.onItemDisabled, this);
    c.un('enable', this.onItemEnabled, this);
    c.un('titlechange', this.onItemTitleChanged, this);
    c.un('iconchange', this.onItemIconChanged, this);
    c.un('beforeshow', this.onBeforeShowItem, this);

    if (c == this.activeTab) {
      var next = this.stack.next();

      if (next) {
        this.setActiveTab(next);
      } else if (this.items.getCount() > 0) {
        this.setActiveTab(0);
      } else {
        this.setActiveTab(null);
      }
    }

    if (!this.destroying) {
      this.delegateUpdates();
    }
  },
  // private
  onBeforeShowItem: function onBeforeShowItem(item) {
    if (item != this.activeTab) {
      this.setActiveTab(item);
      return false;
    }
  },
  // private
  onItemDisabled: function onItemDisabled(item) {
    var el = this.getTabEl(item);

    if (el) {
      Ext.fly(el).addClass('x-item-disabled');
    }

    this.stack.remove(item);
  },
  // private
  onItemEnabled: function onItemEnabled(item) {
    var el = this.getTabEl(item);

    if (el) {
      Ext.fly(el).removeClass('x-item-disabled');
    }
  },
  // private
  onItemTitleChanged: function onItemTitleChanged(item) {
    var el = this.getTabEl(item);

    if (el) {
      Ext.fly(el).child('span.x-tab-strip-text', true).innerHTML = item.title;
    }
  },
  //private
  onItemIconChanged: function onItemIconChanged(item, iconCls, oldCls) {
    var el = this.getTabEl(item);

    if (el) {
      el = Ext.get(el);
      el.child('span.x-tab-strip-text').replaceClass(oldCls, iconCls);
      el[Ext.isEmpty(iconCls) ? 'removeClass' : 'addClass']('x-tab-with-icon');
    }
  },

  /**
   * Gets the DOM element for the tab strip item which activates the child panel with the specified
   * ID. Access this to change the visual treatment of the item, for example by changing the CSS class name.
   * @param {Panel/Number/String} tab The tab component, or the tab's index, or the tabs id or itemId.
   * @return {HTMLElement} The DOM node
   */
  getTabEl: function getTabEl(item) {
    var c = this.getComponent(item);
    return c ? c.tabEl : null;
  },
  // private
  onResize: function onResize() {
    Ext.TabPanel.superclass.onResize.apply(this, arguments);
    this.delegateUpdates();
  },

  /**
   * Suspends any internal calculations or scrolling while doing a bulk operation. See {@link #endUpdate}
   */
  beginUpdate: function beginUpdate() {
    this.suspendUpdates = true;
  },

  /**
   * Resumes calculations and scrolling at the end of a bulk operation. See {@link #beginUpdate}
   */
  endUpdate: function endUpdate() {
    this.suspendUpdates = false;
    this.delegateUpdates();
  },

  /**
   * Hides the tab strip item for the passed tab
   * @param {Number/String/Panel} item The tab index, id or item
   */
  hideTabStripItem: function hideTabStripItem(item) {
    item = this.getComponent(item);
    var el = this.getTabEl(item);

    if (el) {
      el.style.display = 'none';
      this.delegateUpdates();
    }

    this.stack.remove(item);
  },

  /**
   * Unhides the tab strip item for the passed tab
   * @param {Number/String/Panel} item The tab index, id or item
   */
  unhideTabStripItem: function unhideTabStripItem(item) {
    item = this.getComponent(item);
    var el = this.getTabEl(item);

    if (el) {
      el.style.display = '';
      this.delegateUpdates();
    }
  },
  // private
  delegateUpdates: function delegateUpdates() {
    if (this.suspendUpdates) {
      return;
    }

    if (this.resizeTabs && this.rendered) {
      this.autoSizeTabs();
    }

    if (this.enableTabScroll && this.rendered) {
      this.autoScrollTabs();
    }
  },
  // private
  autoSizeTabs: function autoSizeTabs() {
    var count = this.items.length,
        ce = this.tabPosition != 'bottom' ? 'header' : 'footer',
        ow = this[ce].dom.offsetWidth,
        aw = this[ce].dom.clientWidth;

    if (!this.resizeTabs || count < 1 || !aw) {
      // !aw for display:none
      return;
    }

    var each = Math.max(Math.min(Math.floor((aw - 4) / count) - this.tabMargin, this.tabWidth), this.minTabWidth); // -4 for float errors in IE

    this.lastTabWidth = each;
    var lis = this.strip.query('li:not(.x-tab-edge)');

    for (var i = 0, len = lis.length; i < len; i++) {
      var li = lis[i],
          inner = Ext.fly(li).child('.x-tab-strip-inner', true),
          tw = li.offsetWidth,
          iw = inner.offsetWidth;
      inner.style.width = each - (tw - iw) + 'px';
    }
  },
  // private
  adjustBodyWidth: function adjustBodyWidth(w) {
    if (this.header) {
      this.header.setWidth(w);
    }

    if (this.footer) {
      this.footer.setWidth(w);
    }

    return w;
  },

  /**
   * Sets the specified tab as the active tab. This method fires the {@link #beforetabchange} event which
   * can <tt>return false</tt> to cancel the tab change.
   * @param {String/Number} item
   * The id or tab Panel to activate. This parameter may be any of the following:
   * <div><ul class="mdetail-params">
   * <li>a <b><tt>String</tt></b> : representing the <code>{@link Ext.Component#itemId itemId}</code>
   * or <code>{@link Ext.Component#id id}</code> of the child component </li>
   * <li>a <b><tt>Number</tt></b> : representing the position of the child component
   * within the <code>{@link Ext.Container#items items}</code> <b>property</b></li>
   * </ul></div>
   * <p>For additional information see {@link Ext.util.MixedCollection#get}.
   */
  setActiveTab: function setActiveTab(item) {
    item = this.getComponent(item);

    if (this.fireEvent('beforetabchange', this, item, this.activeTab) === false) {
      return;
    }

    if (!this.rendered) {
      this.activeTab = item;
      return;
    }

    if (this.activeTab != item) {
      if (this.activeTab) {
        var oldEl = this.getTabEl(this.activeTab);

        if (oldEl) {
          Ext.fly(oldEl).removeClass('x-tab-strip-active');
        }
      }

      if (item) {
        var el = this.getTabEl(item);
        Ext.fly(el).addClass('x-tab-strip-active');
        this.activeTab = item;
        this.stack.add(item);
        this.layout.setActiveItem(item);

        if (this.scrolling) {
          this.scrollToTab(item, this.animScroll);
        }
      }

      this.fireEvent('tabchange', this, item);
    }
  },

  /**
   * Returns the Component which is the currently active tab. <b>Note that before the TabPanel
   * first activates a child Component, this method will return whatever was configured in the
   * {@link #activeTab} config option.</b>
   * @return {BoxComponent} The currently active child Component if one <i>is</i> active, or the {@link #activeTab} config value.
   */
  getActiveTab: function getActiveTab() {
    return this.activeTab || null;
  },

  /**
   * Gets the specified tab by id.
   * @param {String} id The tab id
   * @return {Panel} The tab
   */
  getItem: function getItem(item) {
    return this.getComponent(item);
  },
  // private
  autoScrollTabs: function autoScrollTabs() {
    this.pos = this.tabPosition == 'bottom' ? this.footer : this.header;
    var count = this.items.length,
        ow = this.pos.dom.offsetWidth,
        tw = this.pos.dom.clientWidth,
        wrap = this.stripWrap,
        wd = wrap.dom,
        cw = wd.offsetWidth,
        pos = this.getScrollPos(),
        l = this.edge.getOffsetsTo(this.stripWrap)[0] + pos;

    if (!this.enableTabScroll || count < 1 || cw < 20) {
      // 20 to prevent display:none issues
      return;
    }

    if (l <= tw) {
      wd.scrollLeft = 0;
      wrap.setWidth(tw);

      if (this.scrolling) {
        this.scrolling = false;
        this.pos.removeClass('x-tab-scrolling');
        this.scrollLeft.hide();
        this.scrollRight.hide(); // See here: http://extjs.com/forum/showthread.php?t=49308&highlight=isSafari

        if (Ext.isAir || Ext.isWebKit) {
          wd.style.marginLeft = '';
          wd.style.marginRight = '';
        }
      }
    } else {
      if (!this.scrolling) {
        this.pos.addClass('x-tab-scrolling'); // See here: http://extjs.com/forum/showthread.php?t=49308&highlight=isSafari

        if (Ext.isAir || Ext.isWebKit) {
          wd.style.marginLeft = '18px';
          wd.style.marginRight = '18px';
        }
      }

      tw -= wrap.getMargins('lr');
      wrap.setWidth(tw > 20 ? tw : 20);

      if (!this.scrolling) {
        if (!this.scrollLeft) {
          this.createScrollers();
        } else {
          this.scrollLeft.show();
          this.scrollRight.show();
        }
      }

      this.scrolling = true;

      if (pos > l - tw) {
        // ensure it stays within bounds
        wd.scrollLeft = l - tw;
      } else {
        // otherwise, make sure the active tab is still visible
        this.scrollToTab(this.activeTab, false);
      }

      this.updateScrollButtons();
    }
  },
  // private
  createScrollers: function createScrollers() {
    this.pos.addClass('x-tab-scrolling-' + this.tabPosition);
    var h = this.stripWrap.dom.offsetHeight; // left

    var sl = this.pos.insertFirst({
      cls: 'x-tab-scroller-left'
    });
    sl.setHeight(h);
    sl.addClassOnOver('x-tab-scroller-left-over');
    this.leftRepeater = new Ext.util.ClickRepeater(sl, {
      interval: this.scrollRepeatInterval,
      handler: this.onScrollLeft,
      scope: this
    });
    this.scrollLeft = sl; // right

    var sr = this.pos.insertFirst({
      cls: 'x-tab-scroller-right'
    });
    sr.setHeight(h);
    sr.addClassOnOver('x-tab-scroller-right-over');
    this.rightRepeater = new Ext.util.ClickRepeater(sr, {
      interval: this.scrollRepeatInterval,
      handler: this.onScrollRight,
      scope: this
    });
    this.scrollRight = sr;
  },
  // private
  getScrollWidth: function getScrollWidth() {
    return this.edge.getOffsetsTo(this.stripWrap)[0] + this.getScrollPos();
  },
  // private
  getScrollPos: function getScrollPos() {
    return parseInt(this.stripWrap.dom.scrollLeft, 10) || 0;
  },
  // private
  getScrollArea: function getScrollArea() {
    return parseInt(this.stripWrap.dom.clientWidth, 10) || 0;
  },
  // private
  getScrollAnim: function getScrollAnim() {
    return {
      duration: this.scrollDuration,
      callback: this.updateScrollButtons,
      scope: this
    };
  },
  // private
  getScrollIncrement: function getScrollIncrement() {
    return this.scrollIncrement || (this.resizeTabs ? this.lastTabWidth + 2 : 100);
  },

  /**
   * Scrolls to a particular tab if tab scrolling is enabled
   * @param {Panel} item The item to scroll to
   * @param {Boolean} animate True to enable animations
   */
  scrollToTab: function scrollToTab(item, animate) {
    if (!item) {
      return;
    }

    var el = this.getTabEl(item),
        pos = this.getScrollPos(),
        area = this.getScrollArea(),
        left = Ext.fly(el).getOffsetsTo(this.stripWrap)[0] + pos,
        right = left + el.offsetWidth;

    if (left < pos) {
      this.scrollTo(left, animate);
    } else if (right > pos + area) {
      this.scrollTo(right - area, animate);
    }
  },
  // private
  scrollTo: function scrollTo(pos, animate) {
    this.stripWrap.scrollTo('left', pos, animate ? this.getScrollAnim() : false);

    if (!animate) {
      this.updateScrollButtons();
    }
  },
  onWheel: function onWheel(e) {
    var d = e.getWheelDelta() * this.wheelIncrement * -1;
    e.stopEvent();
    var pos = this.getScrollPos(),
        newpos = pos + d,
        sw = this.getScrollWidth() - this.getScrollArea();
    var s = Math.max(0, Math.min(sw, newpos));

    if (s != pos) {
      this.scrollTo(s, false);
    }
  },
  // private
  onScrollRight: function onScrollRight() {
    var sw = this.getScrollWidth() - this.getScrollArea(),
        pos = this.getScrollPos(),
        s = Math.min(sw, pos + this.getScrollIncrement());

    if (s != pos) {
      this.scrollTo(s, this.animScroll);
    }
  },
  // private
  onScrollLeft: function onScrollLeft() {
    var pos = this.getScrollPos(),
        s = Math.max(0, pos - this.getScrollIncrement());

    if (s != pos) {
      this.scrollTo(s, this.animScroll);
    }
  },
  // private
  updateScrollButtons: function updateScrollButtons() {
    var pos = this.getScrollPos();
    this.scrollLeft[pos === 0 ? 'addClass' : 'removeClass']('x-tab-scroller-left-disabled');
    this.scrollRight[pos >= this.getScrollWidth() - this.getScrollArea() ? 'addClass' : 'removeClass']('x-tab-scroller-right-disabled');
  },
  // private
  beforeDestroy: function beforeDestroy() {
    Ext.destroy(this.leftRepeater, this.rightRepeater);
    this.deleteMembers('strip', 'edge', 'scrollLeft', 'scrollRight', 'stripWrap');
    this.activeTab = null;
    Ext.TabPanel.superclass.beforeDestroy.apply(this);
  }
  /**
   * @cfg {Boolean} collapsible
   * @hide
   */

  /**
   * @cfg {String} header
   * @hide
   */

  /**
   * @cfg {Boolean} headerAsText
   * @hide
   */

  /**
   * @property header
   * @hide
   */

  /**
   * @cfg title
   * @hide
   */

  /**
   * @cfg {Array} tools
   * @hide
   */

  /**
   * @cfg {Array} toolTemplate
   * @hide
   */

  /**
   * @cfg {Boolean} hideCollapseTool
   * @hide
   */

  /**
   * @cfg {Boolean} titleCollapse
   * @hide
   */

  /**
   * @cfg {Boolean} collapsed
   * @hide
   */

  /**
   * @cfg {String} layout
   * @hide
   */

  /**
   * @cfg {Boolean} preventBodyReset
   * @hide
   */

});
Ext.reg('tabpanel', Ext.TabPanel);
/**
 * See {@link #setActiveTab}. Sets the specified tab as the active tab. This method fires
 * the {@link #beforetabchange} event which can <tt>return false</tt> to cancel the tab change.
 * @param {String/Panel} tab The id or tab Panel to activate
 * @method activate
 */

Ext.TabPanel.prototype.activate = Ext.TabPanel.prototype.setActiveTab; // private utility class used by TabPanel

Ext.TabPanel.AccessStack = function () {
  var items = [];
  return {
    add: function add(item) {
      items.push(item);

      if (items.length > 10) {
        items.shift();
      }
    },
    remove: function remove(item) {
      var s = [];

      for (var i = 0, len = items.length; i < len; i++) {
        if (items[i] != item) {
          s.push(items[i]);
        }
      }

      items = s;
    },
    next: function next() {
      return items.pop();
    }
  };
};

/***/ }),
/* 836 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Button
 * @extends Ext.BoxComponent
 * Simple Button class
 * @cfg {String} text The button text to be used as innerHTML (html tags are accepted)
 * @cfg {String} icon The path to an image to display in the button (the image will be set as the background-image
 * CSS property of the button by default, so if you want a mixed icon/text button, set cls:'x-btn-text-icon')
 * @cfg {Function} handler A function called when the button is clicked (can be used instead of click event).
 * The handler is passed the following parameters:<div class="mdetail-params"><ul>
 * <li><code>b</code> : Button<div class="sub-desc">This Button.</div></li>
 * <li><code>e</code> : EventObject<div class="sub-desc">The click event.</div></li>
 * </ul></div>
 * @cfg {Number} minWidth The minimum width for this button (used to give a set of buttons a common width).
 * See also {@link Ext.Panel}.<tt>{@link Ext.Panel#minButtonWidth minButtonWidth}</tt>.
 * @cfg {String/Object} tooltip The tooltip for the button - can be a string to be used as innerHTML (html tags are accepted) or QuickTips config object
 * @cfg {Boolean} hidden True to start hidden (defaults to false)
 * @cfg {Boolean} disabled True to start disabled (defaults to false)
 * @cfg {Boolean} pressed True to start pressed (only if enableToggle = true)
 * @cfg {String} toggleGroup The group this toggle button is a member of (only 1 per group can be pressed)
 * @cfg {Boolean/Object} repeat True to repeat fire the click event while the mouse is down. This can also be
 * a {@link Ext.util.ClickRepeater ClickRepeater} config object (defaults to false).
 * @constructor
 * Create a new button
 * @param {Object} config The config object
 * @xtype button
 */
Ext.Button = Ext.extend(Ext.BoxComponent, {
  /**
   * Read-only. True if this button is hidden
   * @type Boolean
   */
  hidden: false,

  /**
   * Read-only. True if this button is disabled
   * @type Boolean
   */
  disabled: false,

  /**
   * Read-only. True if this button is pressed (only if enableToggle = true)
   * @type Boolean
   */
  pressed: false,

  /**
   * @cfg {Number} tabIndex Set a DOM tabIndex for this button (defaults to undefined)
   */

  /**
   * @cfg {Boolean} allowDepress
   * False to not allow a pressed Button to be depressed (defaults to undefined). Only valid when {@link #enableToggle} is true.
   */

  /**
   * @cfg {Boolean} enableToggle
   * True to enable pressed/not pressed toggling (defaults to false)
   */
  enableToggle: false,

  /**
   * @cfg {Function} toggleHandler
   * Function called when a Button with {@link #enableToggle} set to true is clicked. Two arguments are passed:<ul class="mdetail-params">
   * <li><b>button</b> : Ext.Button<div class="sub-desc">this Button object</div></li>
   * <li><b>state</b> : Boolean<div class="sub-desc">The next state of the Button, true means pressed.</div></li>
   * </ul>
   */

  /**
   * @cfg {Mixed} menu
   * Standard menu attribute consisting of a reference to a menu object, a menu id or a menu config blob (defaults to undefined).
   */

  /**
   * @cfg {String} menuAlign
   * The position to align the menu to (see {@link Ext.Element#alignTo} for more details, defaults to 'tl-bl?').
   */
  menuAlign: 'tl-bl?',

  /**
   * @cfg {String} overflowText If used in a {@link Ext.Toolbar Toolbar}, the
   * text to be used if this item is shown in the overflow menu. See also
   * {@link Ext.Toolbar.Item}.<code>{@link Ext.Toolbar.Item#overflowText overflowText}</code>.
   */

  /**
   * @cfg {String} iconCls
   * A css class which sets a background image to be used as the icon for this button
   */

  /**
   * @cfg {String} type
   * submit, reset or button - defaults to 'button'
   */
  type: 'button',
  // private
  menuClassTarget: 'tr:nth(2)',

  /**
   * @cfg {String} clickEvent
   * The DOM event that will fire the handler of the button. This can be any valid event name (dblclick, contextmenu).
   * Defaults to <tt>'click'</tt>.
   */
  clickEvent: 'click',

  /**
   * @cfg {Boolean} handleMouseEvents
   * False to disable visual cues on mouseover, mouseout and mousedown (defaults to true)
   */
  handleMouseEvents: true,

  /**
   * @cfg {String} tooltipType
   * The type of tooltip to use. Either 'qtip' (default) for QuickTips or 'title' for title attribute.
   */
  tooltipType: 'qtip',

  /**
   * @cfg {String} buttonSelector
   * <p>(Optional) A {@link Ext.DomQuery DomQuery} selector which is used to extract the active, clickable element from the
   * DOM structure created.</p>
   * <p>When a custom {@link #template} is used, you  must ensure that this selector results in the selection of
   * a focussable element.</p>
   * <p>Defaults to <b><tt>'button:first-child'</tt></b>.</p>
   */
  buttonSelector: 'button:first-child',

  /**
   * @cfg {String} scale
   * <p>(Optional) The size of the Button. Three values are allowed:</p>
   * <ul class="mdetail-params">
   * <li>'small'<div class="sub-desc">Results in the button element being 16px high.</div></li>
   * <li>'medium'<div class="sub-desc">Results in the button element being 24px high.</div></li>
   * <li>'large'<div class="sub-desc">Results in the button element being 32px high.</div></li>
   * </ul>
   * <p>Defaults to <b><tt>'small'</tt></b>.</p>
   */
  scale: 'small',

  /**
   * @cfg {Object} scope The scope (<tt><b>this</b></tt> reference) in which the
   * <code>{@link #handler}</code> and <code>{@link #toggleHandler}</code> is
   * executed. Defaults to this Button.
   */

  /**
   * @cfg {String} iconAlign
   * <p>(Optional) The side of the Button box to render the icon. Four values are allowed:</p>
   * <ul class="mdetail-params">
   * <li>'top'<div class="sub-desc"></div></li>
   * <li>'right'<div class="sub-desc"></div></li>
   * <li>'bottom'<div class="sub-desc"></div></li>
   * <li>'left'<div class="sub-desc"></div></li>
   * </ul>
   * <p>Defaults to <b><tt>'left'</tt></b>.</p>
   */
  iconAlign: 'left',

  /**
   * @cfg {String} arrowAlign
   * <p>(Optional) The side of the Button box to render the arrow if the button has an associated {@link #menu}.
   * Two values are allowed:</p>
   * <ul class="mdetail-params">
   * <li>'right'<div class="sub-desc"></div></li>
   * <li>'bottom'<div class="sub-desc"></div></li>
   * </ul>
   * <p>Defaults to <b><tt>'right'</tt></b>.</p>
   */
  arrowAlign: 'right',

  /**
   * @cfg {Ext.Template} template (Optional)
   * <p>A {@link Ext.Template Template} used to create the Button's DOM structure.</p>
   * Instances, or subclasses which need a different DOM structure may provide a different
   * template layout in conjunction with an implementation of {@link #getTemplateArgs}.
   * @type Ext.Template
   * @property template
   */

  /**
   * @cfg {String} cls
   * A CSS class string to apply to the button's main element.
   */

  /**
   * @property menu
   * @type Menu
   * The {@link Ext.menu.Menu Menu} object associated with this Button when configured with the {@link #menu} config option.
   */
  initComponent: function initComponent() {
    Ext.Button.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event click
     * Fires when this button is clicked
     * @param {Button} this
     * @param {EventObject} e The click event
     */
    'click',
    /**
     * @event toggle
     * Fires when the 'pressed' state of this button changes (only if enableToggle = true)
     * @param {Button} this
     * @param {Boolean} pressed
     */
    'toggle',
    /**
     * @event mouseover
     * Fires when the mouse hovers over the button
     * @param {Button} this
     * @param {Event} e The event object
     */
    'mouseover',
    /**
     * @event mouseout
     * Fires when the mouse exits the button
     * @param {Button} this
     * @param {Event} e The event object
     */
    'mouseout',
    /**
     * @event menushow
     * If this button has a menu, this event fires when it is shown
     * @param {Button} this
     * @param {Menu} menu
     */
    'menushow',
    /**
     * @event menuhide
     * If this button has a menu, this event fires when it is hidden
     * @param {Button} this
     * @param {Menu} menu
     */
    'menuhide',
    /**
     * @event menutriggerover
     * If this button has a menu, this event fires when the mouse enters the menu triggering element
     * @param {Button} this
     * @param {Menu} menu
     * @param {EventObject} e
     */
    'menutriggerover',
    /**
     * @event menutriggerout
     * If this button has a menu, this event fires when the mouse leaves the menu triggering element
     * @param {Button} this
     * @param {Menu} menu
     * @param {EventObject} e
     */
    'menutriggerout');

    if (this.menu) {
      this.menu = Ext.menu.MenuMgr.get(this.menu);
    }

    if (Ext.isString(this.toggleGroup)) {
      this.enableToggle = true;
    }
  },

  /**
    * <p>This method returns an Array which provides substitution parameters for the {@link #template Template} used
    * to create this Button's DOM structure.</p>
    * <p>Instances or subclasses which use a different Template to create a different DOM structure may need to provide their
    * own implementation of this method.</p>
    * <p>The default implementation which provides data for the default {@link #template} returns an Array containing the
    * following items:</p><div class="mdetail-params"><ul>
    * <li>The &lt;button&gt;'s {@link #type}</li>
    * <li>A CSS class name applied to the Button's main &lt;tbody&gt; element which determines the button's scale and icon alignment.</li>
    * <li>A CSS class to determine the presence and position of an arrow icon. (<code>'x-btn-arrow'</code> or <code>'x-btn-arrow-bottom'</code> or <code>''</code>)</li>
    * <li>The {@link #cls} CSS class name applied to the button's wrapping &lt;table&gt; element.</li>
    * <li>The Component id which is applied to the button's wrapping &lt;table&gt; element.</li>
    * </ul></div>
    * @return {Array} Substitution data for a Template.
   */
  getTemplateArgs: function getTemplateArgs() {
    return [this.type, 'x-btn-' + this.scale + ' x-btn-icon-' + this.scale + '-' + this.iconAlign, this.getMenuClass(), this.cls, this.id];
  },
  // private
  setButtonClass: function setButtonClass() {
    if (this.useSetClass) {
      if (!Ext.isEmpty(this.oldCls)) {
        this.el.removeClass([this.oldCls, 'x-btn-pressed']);
      }

      this.oldCls = this.iconCls || this.icon ? this.text ? ' x-btn-text-icon' : ' x-btn-icon' : ' x-btn-noicon';
      this.el.addClass([this.oldCls, this.pressed ? 'x-btn-pressed' : null]);
    }
  },
  // protected
  getMenuClass: function getMenuClass() {
    return this.menu ? this.arrowAlign != 'bottom' ? 'x-btn-arrow' : 'x-btn-arrow-bottom' : '';
  },
  // private
  onRender: function onRender(ct, position) {
    if (!this.template) {
      if (!Ext.Button.buttonTemplate) {
        // hideous table template
        Ext.Button.buttonTemplate = new Ext.Template('<table id="{4}" cellspacing="0" class="x-btn {3}"><tbody class="{1}">', '<tr><td class="x-btn-tl"><i>&#160;</i></td><td class="x-btn-tc"></td><td class="x-btn-tr"><i>&#160;</i></td></tr>', '<tr><td class="x-btn-ml"><i>&#160;</i></td><td class="x-btn-mc"><em class="{2}" unselectable="on"><button type="{0}"></button></em></td><td class="x-btn-mr"><i>&#160;</i></td></tr>', '<tr><td class="x-btn-bl"><i>&#160;</i></td><td class="x-btn-bc"></td><td class="x-btn-br"><i>&#160;</i></td></tr>', '</tbody></table>');
        Ext.Button.buttonTemplate.compile();
      }

      this.template = Ext.Button.buttonTemplate;
    }

    var btn,
        targs = this.getTemplateArgs();

    if (position) {
      btn = this.template.insertBefore(position, targs, true);
    } else {
      btn = this.template.append(ct, targs, true);
    }
    /**
     * An {@link Ext.Element Element} encapsulating the Button's clickable element. By default,
     * this references a <tt>&lt;button&gt;</tt> element. Read only.
     * @type Ext.Element
     * @property btnEl
     */


    this.btnEl = btn.child(this.buttonSelector);
    this.mon(this.btnEl, {
      scope: this,
      focus: this.onFocus,
      blur: this.onBlur
    });
    this.initButtonEl(btn, this.btnEl);
    Ext.ButtonToggleMgr.register(this);
  },
  // private
  initButtonEl: function initButtonEl(btn, btnEl) {
    this.el = btn;
    this.setIcon(this.icon);
    this.setText(this.text);
    this.setIconClass(this.iconCls);

    if (Ext.isDefined(this.tabIndex)) {
      btnEl.dom.tabIndex = this.tabIndex;
    }

    if (this.tooltip) {
      this.setTooltip(this.tooltip, true);
    }

    if (this.handleMouseEvents) {
      this.mon(btn, {
        scope: this,
        mouseover: this.onMouseOver,
        mousedown: this.onMouseDown
      }); // new functionality for monitoring on the document level
      //this.mon(btn, 'mouseout', this.onMouseOut, this);
    }

    if (this.menu) {
      this.mon(this.menu, {
        scope: this,
        show: this.onMenuShow,
        hide: this.onMenuHide
      });
    }

    if (this.repeat) {
      var repeater = new Ext.util.ClickRepeater(btn, Ext.isObject(this.repeat) ? this.repeat : {});
      this.mon(repeater, 'click', this.onClick, this);
    }

    this.mon(btn, this.clickEvent, this.onClick, this);
  },
  // private
  afterRender: function afterRender() {
    Ext.Button.superclass.afterRender.call(this);
    this.useSetClass = true;
    this.setButtonClass();
    this.doc = Ext.getDoc();
    this.doAutoWidth();
  },

  /**
   * Sets the CSS class that provides a background image to use as the button's icon.  This method also changes
   * the value of the {@link iconCls} config internally.
   * @param {String} cls The CSS class providing the icon image
   * @return {Ext.Button} this
   */
  setIconClass: function setIconClass(cls) {
    this.iconCls = cls;

    if (this.el) {
      this.btnEl.dom.className = '';
      this.btnEl.addClass(['x-btn-text', cls || '']);
      this.setButtonClass();
    }

    return this;
  },

  /**
   * Sets the tooltip for this Button.
   * @param {String/Object} tooltip. This may be:<div class="mdesc-details"><ul>
   * <li><b>String</b> : A string to be used as innerHTML (html tags are accepted) to show in a tooltip</li>
   * <li><b>Object</b> : A configuration object for {@link Ext.QuickTips#register}.</li>
   * </ul></div>
   * @return {Ext.Button} this
   */
  setTooltip: function setTooltip(tooltip,
  /* private */
  initial) {
    if (this.rendered) {
      if (!initial) {
        this.clearTip();
      }

      if (Ext.isObject(tooltip)) {
        Ext.QuickTips.register(Ext.apply({
          target: this.btnEl.id
        }, tooltip));
        this.tooltip = tooltip;
      } else {
        this.btnEl.dom[this.tooltipType] = tooltip;
      }
    } else {
      this.tooltip = tooltip;
    }

    return this;
  },
  // private
  clearTip: function clearTip() {
    if (Ext.isObject(this.tooltip)) {
      Ext.QuickTips.unregister(this.btnEl);
    }
  },
  // private
  beforeDestroy: function beforeDestroy() {
    if (this.rendered) {
      this.clearTip();
    }

    if (this.menu && this.destroyMenu !== false) {
      Ext.destroy(this.menu);
    }

    Ext.destroy(this.repeater);
  },
  // private
  onDestroy: function onDestroy() {
    if (this.rendered) {
      this.doc.un('mouseover', this.monitorMouseOver, this);
      this.doc.un('mouseup', this.onMouseUp, this);
      delete this.doc;
      delete this.btnEl;
      Ext.ButtonToggleMgr.unregister(this);
    }

    Ext.Button.superclass.onDestroy.call(this);
  },
  // private
  doAutoWidth: function doAutoWidth() {
    if (this.el && this.text && this.width === undefined) {
      this.el.setWidth('auto');

      if (Ext.isIE7 && Ext.isStrict) {
        var ib = this.btnEl;

        if (ib && ib.getWidth() > 20) {
          ib.clip();
          ib.setWidth(Ext.util.TextMetrics.measure(ib, this.text).width + ib.getFrameWidth('lr'));
        }
      }

      if (this.minWidth) {
        if (this.el.getWidth() < this.minWidth) {
          this.el.setWidth(this.minWidth);
        }
      }
    }
  },

  /**
   * Assigns this Button's click handler
   * @param {Function} handler The function to call when the button is clicked
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the handler function is executed.
   * Defaults to this Button.
   * @return {Ext.Button} this
   */
  setHandler: function setHandler(handler, scope) {
    this.handler = handler;
    this.scope = scope;
    return this;
  },

  /**
   * Sets this Button's text
   * @param {String} text The button text
   * @return {Ext.Button} this
   */
  setText: function setText(text) {
    this.text = text;

    if (this.el) {
      this.btnEl.update(text || '&#160;');
      this.setButtonClass();
    }

    this.doAutoWidth();
    return this;
  },

  /**
   * Sets the background image (inline style) of the button.  This method also changes
   * the value of the {@link icon} config internally.
   * @param {String} icon The path to an image to display in the button
   * @return {Ext.Button} this
   */
  setIcon: function setIcon(icon) {
    this.icon = icon;

    if (this.el) {
      this.btnEl.setStyle('background-image', icon ? 'url(' + icon + ')' : '');
      this.setButtonClass();
    }

    return this;
  },

  /**
   * Gets the text for this Button
   * @return {String} The button text
   */
  getText: function getText() {
    return this.text;
  },

  /**
   * If a state it passed, it becomes the pressed state otherwise the current state is toggled.
   * @param {Boolean} state (optional) Force a particular state
   * @param {Boolean} supressEvent (optional) True to stop events being fired when calling this method.
   * @return {Ext.Button} this
   */
  toggle: function toggle(state, suppressEvent) {
    state = state === undefined ? !this.pressed : !!state;

    if (state != this.pressed) {
      if (this.rendered) {
        this.el[state ? 'addClass' : 'removeClass']('x-btn-pressed');
      }

      this.pressed = state;

      if (!suppressEvent) {
        this.fireEvent('toggle', this, state);

        if (this.toggleHandler) {
          this.toggleHandler.call(this.scope || this, this, state);
        }
      }
    }

    return this;
  },

  /**
   * Focus the button
   */
  focus: function focus() {
    this.btnEl.focus();
  },
  // private
  onDisable: function onDisable() {
    this.onDisableChange(true);
  },
  // private
  onEnable: function onEnable() {
    this.onDisableChange(false);
  },
  onDisableChange: function onDisableChange(disabled) {
    if (this.el) {
      if (!Ext.isIE6 || !this.text) {
        this.el[disabled ? 'addClass' : 'removeClass'](this.disabledClass);
      }

      this.el.dom.disabled = disabled;
    }

    this.disabled = disabled;
  },

  /**
   * Show this button's menu (if it has one)
   */
  showMenu: function showMenu() {
    if (this.rendered && this.menu) {
      if (this.tooltip) {
        Ext.QuickTips.getQuickTip().cancelShow(this.btnEl);
      }

      if (this.menu.isVisible()) {
        this.menu.hide();
      }

      this.menu.ownerCt = this;
      this.menu.show(this.el, this.menuAlign);
    }

    return this;
  },

  /**
   * Hide this button's menu (if it has one)
   */
  hideMenu: function hideMenu() {
    if (this.hasVisibleMenu()) {
      this.menu.hide();
    }

    return this;
  },

  /**
   * Returns true if the button has a menu and it is visible
   * @return {Boolean}
   */
  hasVisibleMenu: function hasVisibleMenu() {
    return this.menu && this.menu.ownerCt == this && this.menu.isVisible();
  },
  // private
  onClick: function onClick(e) {
    if (e) {
      e.preventDefault();
    }

    if (e.button !== 0) {
      return;
    }

    if (!this.disabled) {
      if (this.enableToggle && (this.allowDepress !== false || !this.pressed)) {
        this.toggle();
      }

      if (this.menu && !this.hasVisibleMenu() && !this.ignoreNextClick) {
        this.showMenu();
      }

      this.fireEvent('click', this, e);

      if (this.handler) {
        //this.el.removeClass('x-btn-over');
        this.handler.call(this.scope || this, this, e);
      }
    }
  },
  // private
  isMenuTriggerOver: function isMenuTriggerOver(e, internal) {
    return this.menu && !internal;
  },
  // private
  isMenuTriggerOut: function isMenuTriggerOut(e, internal) {
    return this.menu && !internal;
  },
  // private
  onMouseOver: function onMouseOver(e) {
    if (!this.disabled) {
      var internal = e.within(this.el, true);

      if (!internal) {
        this.el.addClass('x-btn-over');

        if (!this.monitoringMouseOver) {
          this.doc.on('mouseover', this.monitorMouseOver, this);
          this.monitoringMouseOver = true;
        }

        this.fireEvent('mouseover', this, e);
      }

      if (this.isMenuTriggerOver(e, internal)) {
        this.fireEvent('menutriggerover', this, this.menu, e);
      }
    }
  },
  // private
  monitorMouseOver: function monitorMouseOver(e) {
    if (e.target != this.el.dom && !e.within(this.el)) {
      if (this.monitoringMouseOver) {
        this.doc.un('mouseover', this.monitorMouseOver, this);
        this.monitoringMouseOver = false;
      }

      this.onMouseOut(e);
    }
  },
  // private
  onMouseOut: function onMouseOut(e) {
    var internal = e.within(this.el) && e.target != this.el.dom;
    this.el.removeClass('x-btn-over');
    this.fireEvent('mouseout', this, e);

    if (this.isMenuTriggerOut(e, internal)) {
      this.fireEvent('menutriggerout', this, this.menu, e);
    }
  },
  focus: function focus() {
    this.btnEl.focus();
  },
  blur: function blur() {
    this.btnEl.blur();
  },
  // private
  onFocus: function onFocus(e) {
    if (!this.disabled) {
      this.el.addClass('x-btn-focus');
    }
  },
  // private
  onBlur: function onBlur(e) {
    this.el.removeClass('x-btn-focus');
  },
  // private
  getClickEl: function getClickEl(e, isUp) {
    return this.el;
  },
  // private
  onMouseDown: function onMouseDown(e) {
    if (!this.disabled && e.button === 0) {
      this.getClickEl(e).addClass('x-btn-click');
      this.doc.on('mouseup', this.onMouseUp, this);
    }
  },
  // private
  onMouseUp: function onMouseUp(e) {
    if (e.button === 0) {
      this.getClickEl(e, true).removeClass('x-btn-click');
      this.doc.un('mouseup', this.onMouseUp, this);
    }
  },
  // private
  onMenuShow: function onMenuShow(e) {
    if (this.menu.ownerCt == this) {
      this.menu.ownerCt = this;
      this.ignoreNextClick = 0;
      this.el.addClass('x-btn-menu-active');
      this.fireEvent('menushow', this, this.menu);
    }
  },
  // private
  onMenuHide: function onMenuHide(e) {
    if (this.menu.ownerCt == this) {
      this.el.removeClass('x-btn-menu-active');
      this.ignoreNextClick = this.restoreClick.defer(250, this);
      this.fireEvent('menuhide', this, this.menu);
      delete this.menu.ownerCt;
    }
  },
  // private
  restoreClick: function restoreClick() {
    this.ignoreNextClick = 0;
  }
  /**
   * @cfg {String} autoEl @hide
   */

  /**
   * @cfg {String/Object} html @hide
   */

  /**
   * @cfg {String} contentEl  @hide
   */

  /**
   * @cfg {Mixed} data  @hide
   */

  /**
   * @cfg {Mixed} tpl  @hide
   */

  /**
   * @cfg {String} tplWriteMode  @hide
   */

});
Ext.reg('button', Ext.Button); // Private utility class used by Button

Ext.ButtonToggleMgr = function () {
  var groups = {};

  function toggleGroup(btn, state) {
    if (state) {
      var g = groups[btn.toggleGroup];

      for (var i = 0, l = g.length; i < l; i++) {
        if (g[i] != btn) {
          g[i].toggle(false);
        }
      }
    }
  }

  return {
    register: function register(btn) {
      if (!btn.toggleGroup) {
        return;
      }

      var g = groups[btn.toggleGroup];

      if (!g) {
        g = groups[btn.toggleGroup] = [];
      }

      g.push(btn);
      btn.on('toggle', toggleGroup);
    },
    unregister: function unregister(btn) {
      if (!btn.toggleGroup) {
        return;
      }

      var g = groups[btn.toggleGroup];

      if (g) {
        g.remove(btn);
        btn.un('toggle', toggleGroup);
      }
    },

    /**
     * Gets the pressed button in the passed group or null
     * @param {String} group
     * @return Button
     */
    getPressed: function getPressed(group) {
      var g = groups[group];

      if (g) {
        for (var i = 0, len = g.length; i < len; i++) {
          if (g[i].pressed === true) {
            return g[i];
          }
        }
      }

      return null;
    }
  };
}();

/***/ }),
/* 837 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.SplitButton
 * @extends Ext.Button
 * A split button that provides a built-in dropdown arrow that can fire an event separately from the default
 * click event of the button.  Typically this would be used to display a dropdown menu that provides additional
 * options to the primary button action, but any custom handler can provide the arrowclick implementation.  Example usage:
 * <pre><code>
// display a dropdown menu:
new Ext.SplitButton({
	renderTo: 'button-ct', // the container id
   	text: 'Options',
   	handler: optionsHandler, // handle a click on the button itself
   	menu: new Ext.menu.Menu({
        items: [
        	// these items will render as dropdown menu items when the arrow is clicked:
	        {text: 'Item 1', handler: item1Handler},
	        {text: 'Item 2', handler: item2Handler}
        ]
   	})
});

// Instead of showing a menu, you provide any type of custom
// functionality you want when the dropdown arrow is clicked:
new Ext.SplitButton({
	renderTo: 'button-ct',
   	text: 'Options',
   	handler: optionsHandler,
   	arrowHandler: myCustomHandler
});
</code></pre>
 * @cfg {Function} arrowHandler A function called when the arrow button is clicked (can be used instead of click event)
 * @cfg {String} arrowTooltip The title attribute of the arrow
 * @constructor
 * Create a new menu button
 * @param {Object} config The config object
 * @xtype splitbutton
 */
Ext.SplitButton = Ext.extend(Ext.Button, {
  // private
  arrowSelector: 'em',
  split: true,
  // private
  initComponent: function initComponent() {
    Ext.SplitButton.superclass.initComponent.call(this);
    /**
     * @event arrowclick
     * Fires when this button's arrow is clicked
     * @param {MenuButton} this
     * @param {EventObject} e The click event
     */

    this.addEvents("arrowclick");
  },
  // private
  onRender: function onRender() {
    Ext.SplitButton.superclass.onRender.apply(this, arguments);

    if (this.arrowTooltip) {
      this.el.child(this.arrowSelector).dom[this.tooltipType] = this.arrowTooltip;
    }
  },

  /**
   * Sets this button's arrow click handler.
   * @param {Function} handler The function to call when the arrow is clicked
   * @param {Object} scope (optional) Scope for the function passed above
   */
  setArrowHandler: function setArrowHandler(handler, scope) {
    this.arrowHandler = handler;
    this.scope = scope;
  },
  getMenuClass: function getMenuClass() {
    return 'x-btn-split' + (this.arrowAlign == 'bottom' ? '-bottom' : '');
  },
  isClickOnArrow: function isClickOnArrow(e) {
    if (this.arrowAlign != 'bottom') {
      var visBtn = this.el.child('em.x-btn-split');
      var right = visBtn.getRegion().right - visBtn.getPadding('r');
      return e.getPageX() > right;
    } else {
      return e.getPageY() > this.btnEl.getRegion().bottom;
    }
  },
  // private
  onClick: function onClick(e, t) {
    e.preventDefault();

    if (!this.disabled) {
      if (this.isClickOnArrow(e)) {
        if (this.menu && !this.menu.isVisible() && !this.ignoreNextClick) {
          this.showMenu();
        }

        this.fireEvent("arrowclick", this, e);

        if (this.arrowHandler) {
          this.arrowHandler.call(this.scope || this, this, e);
        }
      } else {
        if (this.enableToggle) {
          this.toggle();
        }

        this.fireEvent("click", this, e);

        if (this.handler) {
          this.handler.call(this.scope || this, this, e);
        }
      }
    }
  },
  // private
  isMenuTriggerOver: function isMenuTriggerOver(e) {
    return this.menu && e.target.tagName == this.arrowSelector;
  },
  // private
  isMenuTriggerOut: function isMenuTriggerOut(e, internal) {
    return this.menu && e.target.tagName != this.arrowSelector;
  }
});
Ext.reg('splitbutton', Ext.SplitButton);

/***/ }),
/* 838 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.CycleButton
 * @extends Ext.SplitButton
 * A specialized SplitButton that contains a menu of {@link Ext.menu.CheckItem} elements.  The button automatically
 * cycles through each menu item on click, raising the button's {@link #change} event (or calling the button's
 * {@link #changeHandler} function, if supplied) for the active menu item. Clicking on the arrow section of the
 * button displays the dropdown menu just like a normal SplitButton.  Example usage:
 * <pre><code>
var btn = new Ext.CycleButton({
    showText: true,
    prependText: 'View as ',
    items: [{
        text:'text only',
        iconCls:'view-text',
        checked:true
    },{
        text:'HTML',
        iconCls:'view-html'
    }],
    changeHandler:function(btn, item){
        Ext.Msg.alert('Change View', item.text);
    }
});
</code></pre>
 * @constructor
 * Create a new split button
 * @param {Object} config The config object
 * @xtype cycle
 */
Ext.CycleButton = Ext.extend(Ext.SplitButton, {
  /**
   * @cfg {Array} items An array of {@link Ext.menu.CheckItem} <b>config</b> objects to be used when creating the
   * button's menu items (e.g., {text:'Foo', iconCls:'foo-icon'})
   */

  /**
   * @cfg {Boolean} showText True to display the active item's text as the button text (defaults to false)
   */

  /**
   * @cfg {String} prependText A static string to prepend before the active item's text when displayed as the
   * button's text (only applies when showText = true, defaults to '')
   */

  /**
   * @cfg {Function} changeHandler A callback function that will be invoked each time the active menu
   * item in the button's menu has changed.  If this callback is not supplied, the SplitButton will instead
   * fire the {@link #change} event on active item change.  The changeHandler function will be called with the
   * following argument list: (SplitButton this, Ext.menu.CheckItem item)
   */

  /**
   * @cfg {String} forceIcon A css class which sets an image to be used as the static icon for this button.  This
   * icon will always be displayed regardless of which item is selected in the dropdown list.  This overrides the 
   * default behavior of changing the button's icon to match the selected item's icon on change.
   */

  /**
   * @property menu
   * @type Menu
   * The {@link Ext.menu.Menu Menu} object used to display the {@link Ext.menu.CheckItem CheckItems} representing the available choices.
   */
  // private
  getItemText: function getItemText(item) {
    if (item && this.showText === true) {
      var text = '';

      if (this.prependText) {
        text += this.prependText;
      }

      text += item.text;
      return text;
    }

    return undefined;
  },

  /**
   * Sets the button's active menu item.
   * @param {Ext.menu.CheckItem} item The item to activate
   * @param {Boolean} suppressEvent True to prevent the button's change event from firing (defaults to false)
   */
  setActiveItem: function setActiveItem(item, suppressEvent) {
    if (!Ext.isObject(item)) {
      item = this.menu.getComponent(item);
    }

    if (item) {
      if (!this.rendered) {
        this.text = this.getItemText(item);
        this.iconCls = item.iconCls;
      } else {
        var t = this.getItemText(item);

        if (t) {
          this.setText(t);
        }

        this.setIconClass(item.iconCls);
      }

      this.activeItem = item;

      if (!item.checked) {
        item.setChecked(true, false);
      }

      if (this.forceIcon) {
        this.setIconClass(this.forceIcon);
      }

      if (!suppressEvent) {
        this.fireEvent('change', this, item);
      }
    }
  },

  /**
   * Gets the currently active menu item.
   * @return {Ext.menu.CheckItem} The active item
   */
  getActiveItem: function getActiveItem() {
    return this.activeItem;
  },
  // private
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event change
     * Fires after the button's active menu item has changed.  Note that if a {@link #changeHandler} function
     * is set on this CycleButton, it will be called instead on active item change and this change event will
     * not be fired.
     * @param {Ext.CycleButton} this
     * @param {Ext.menu.CheckItem} item The menu item that was selected
     */
    "change");

    if (this.changeHandler) {
      this.on('change', this.changeHandler, this.scope || this);
      delete this.changeHandler;
    }

    this.itemCount = this.items.length;
    this.menu = {
      cls: 'x-cycle-menu',
      items: []
    };
    var checked = 0;
    Ext.each(this.items, function (item, i) {
      Ext.apply(item, {
        group: item.group || this.id,
        itemIndex: i,
        checkHandler: this.checkHandler,
        scope: this,
        checked: item.checked || false
      });
      this.menu.items.push(item);

      if (item.checked) {
        checked = i;
      }
    }, this);
    Ext.CycleButton.superclass.initComponent.call(this);
    this.on('click', this.toggleSelected, this);
    this.setActiveItem(checked, true);
  },
  // private
  checkHandler: function checkHandler(item, pressed) {
    if (pressed) {
      this.setActiveItem(item);
    }
  },

  /**
   * This is normally called internally on button click, but can be called externally to advance the button's
   * active item programmatically to the next one in the menu.  If the current item is the last one in the menu
   * the active item will be set to the first item in the menu.
   */
  toggleSelected: function toggleSelected() {
    var m = this.menu;
    m.render(); // layout if we haven't before so the items are active

    if (!m.hasLayout) {
      m.doLayout();
    }

    var nextIdx, checkItem;

    for (var i = 1; i < this.itemCount; i++) {
      nextIdx = (this.activeItem.itemIndex + i) % this.itemCount; // check the potential item

      checkItem = m.items.itemAt(nextIdx); // if its not disabled then check it.

      if (!checkItem.disabled) {
        checkItem.setChecked(true);
        break;
      }
    }
  }
});
Ext.reg('cycle', Ext.CycleButton);

/***/ }),
/* 839 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Toolbar
 * @extends Ext.Container
 * <p>Basic Toolbar class. Although the <tt>{@link Ext.Container#defaultType defaultType}</tt> for Toolbar
 * is <tt>{@link Ext.Button button}</tt>, Toolbar elements (child items for the Toolbar container) may
 * be virtually any type of Component. Toolbar elements can be created explicitly via their constructors,
 * or implicitly via their xtypes, and can be <tt>{@link #add}</tt>ed dynamically.</p>
 * <p>Some items have shortcut strings for creation:</p>
 * <pre>
<u>Shortcut</u>  <u>xtype</u>          <u>Class</u>                  <u>Description</u>
'->'      'tbfill'       {@link Ext.Toolbar.Fill}       begin using the right-justified button container
'-'       'tbseparator'  {@link Ext.Toolbar.Separator}  add a vertical separator bar between toolbar items
' '       'tbspacer'     {@link Ext.Toolbar.Spacer}     add horiztonal space between elements
 * </pre>
 *
 * Example usage of various elements:
 * <pre><code>
var tb = new Ext.Toolbar({
    renderTo: document.body,
    width: 600,
    height: 100,
    items: [
        {
            // xtype: 'button', // default for Toolbars, same as 'tbbutton'
            text: 'Button'
        },
        {
            xtype: 'splitbutton', // same as 'tbsplitbutton'
            text: 'Split Button'
        },
        // begin using the right-justified button container
        '->', // same as {xtype: 'tbfill'}, // Ext.Toolbar.Fill
        {
            xtype: 'textfield',
            name: 'field1',
            emptyText: 'enter search term'
        },
        // add a vertical separator bar between toolbar items
        '-', // same as {xtype: 'tbseparator'} to create Ext.Toolbar.Separator
        'text 1', // same as {xtype: 'tbtext', text: 'text1'} to create Ext.Toolbar.TextItem
        {xtype: 'tbspacer'},// same as ' ' to create Ext.Toolbar.Spacer
        'text 2',
        {xtype: 'tbspacer', width: 50}, // add a 50px space
        'text 3'
    ]
});
 * </code></pre>
 * Example adding a ComboBox within a menu of a button:
 * <pre><code>
// ComboBox creation
var combo = new Ext.form.ComboBox({
    store: new Ext.data.ArrayStore({
        autoDestroy: true,
        fields: ['initials', 'fullname'],
        data : [
            ['FF', 'Fred Flintstone'],
            ['BR', 'Barney Rubble']
        ]
    }),
    displayField: 'fullname',
    typeAhead: true,
    mode: 'local',
    forceSelection: true,
    triggerAction: 'all',
    emptyText: 'Select a name...',
    selectOnFocus: true,
    width: 135,
    getListParent: function() {
        return this.el.up('.x-menu');
    },
    iconCls: 'no-icon' //use iconCls if placing within menu to shift to right side of menu
});

// put ComboBox in a Menu
var menu = new Ext.menu.Menu({
    id: 'mainMenu',
    items: [
        combo // A Field in a Menu
    ]
});

// add a Button with the menu
tb.add({
        text:'Button w/ Menu',
        menu: menu  // assign menu by instance
    });
tb.doLayout();
 * </code></pre>
 * @constructor
 * Creates a new Toolbar
 * @param {Object/Array} config A config object or an array of buttons to <tt>{@link #add}</tt>
 * @xtype toolbar
 */
Ext.Toolbar = function (config) {
  if (Ext.isArray(config)) {
    config = {
      items: config,
      layout: 'toolbar'
    };
  } else {
    config = Ext.apply({
      layout: 'toolbar'
    }, config);

    if (config.buttons) {
      config.items = config.buttons;
    }
  }

  Ext.Toolbar.superclass.constructor.call(this, config);
};

(function () {
  var T = Ext.Toolbar;
  Ext.extend(T, Ext.Container, {
    defaultType: 'button',

    /**
     * @cfg {String/Object} layout
     * This class assigns a default layout (<code>layout:'<b>toolbar</b>'</code>).
     * Developers <i>may</i> override this configuration option if another layout
     * is required (the constructor must be passed a configuration object in this
     * case instead of an array).
     * See {@link Ext.Container#layout} for additional information.
     */
    enableOverflow: false,

    /**
     * @cfg {Boolean} enableOverflow
     * Defaults to false. Configure <code>true<code> to make the toolbar provide a button
     * which activates a dropdown Menu to show items which overflow the Toolbar's width.
     */

    /**
     * @cfg {String} buttonAlign
     * <p>The default position at which to align child items. Defaults to <code>"left"</code></p>
     * <p>May be specified as <code>"center"</code> to cause items added before a Fill (A <code>"->"</code>) item
     * to be centered in the Toolbar. Items added after a Fill are still right-aligned.</p>
     * <p>Specify as <code>"right"</code> to right align all child items.</p>
     */
    trackMenus: true,
    internalDefaults: {
      removeMode: 'container',
      hideParent: true
    },
    toolbarCls: 'x-toolbar',
    initComponent: function initComponent() {
      T.superclass.initComponent.call(this);
      /**
       * @event overflowchange
       * Fires after the overflow state has changed.
       * @param {Object} c The Container
       * @param {Boolean} lastOverflow overflow state
       */

      this.addEvents('overflowchange');
    },
    // private
    onRender: function onRender(ct, position) {
      if (!this.el) {
        if (!this.autoCreate) {
          this.autoCreate = {
            cls: this.toolbarCls + ' x-small-editor'
          };
        }

        this.el = ct.createChild(Ext.apply({
          id: this.id
        }, this.autoCreate), position);
        Ext.Toolbar.superclass.onRender.apply(this, arguments);
      }
    },

    /**
     * <p>Adds element(s) to the toolbar -- this function takes a variable number of
     * arguments of mixed type and adds them to the toolbar.</p>
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Mixed} arg1 The following types of arguments are all valid:<br />
     * <ul>
     * <li>{@link Ext.Button} config: A valid button config object (equivalent to {@link #addButton})</li>
     * <li>HtmlElement: Any standard HTML element (equivalent to {@link #addElement})</li>
     * <li>Field: Any form field (equivalent to {@link #addField})</li>
     * <li>Item: Any subclass of {@link Ext.Toolbar.Item} (equivalent to {@link #addItem})</li>
     * <li>String: Any generic string (gets wrapped in a {@link Ext.Toolbar.TextItem}, equivalent to {@link #addText}).
     * Note that there are a few special strings that are treated differently as explained next.</li>
     * <li>'-': Creates a separator element (equivalent to {@link #addSeparator})</li>
     * <li>' ': Creates a spacer element (equivalent to {@link #addSpacer})</li>
     * <li>'->': Creates a fill element (equivalent to {@link #addFill})</li>
     * </ul>
     * @param {Mixed} arg2
     * @param {Mixed} etc.
     * @method add
     */
    // private
    lookupComponent: function lookupComponent(c) {
      if (Ext.isString(c)) {
        if (c == '-') {
          c = new T.Separator();
        } else if (c == ' ') {
          c = new T.Spacer();
        } else if (c == '->') {
          c = new T.Fill();
        } else {
          c = new T.TextItem(c);
        }

        this.applyDefaults(c);
      } else {
        if (c.isFormField || c.render) {
          // some kind of form field, some kind of Toolbar.Item
          c = this.createComponent(c);
        } else if (c.tag) {
          // DomHelper spec
          c = new T.Item({
            autoEl: c
          });
        } else if (c.tagName) {
          // element
          c = new T.Item({
            el: c
          });
        } else if (Ext.isObject(c)) {
          // must be button config?
          c = c.xtype ? this.createComponent(c) : this.constructButton(c);
        }
      }

      return c;
    },
    // private
    applyDefaults: function applyDefaults(c) {
      if (!Ext.isString(c)) {
        c = Ext.Toolbar.superclass.applyDefaults.call(this, c);
        var d = this.internalDefaults;

        if (c.events) {
          Ext.applyIf(c.initialConfig, d);
          Ext.apply(c, d);
        } else {
          Ext.applyIf(c, d);
        }
      }

      return c;
    },

    /**
     * Adds a separator
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @return {Ext.Toolbar.Item} The separator {@link Ext.Toolbar.Item item}
     */
    addSeparator: function addSeparator() {
      return this.add(new T.Separator());
    },

    /**
     * Adds a spacer element
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @return {Ext.Toolbar.Spacer} The spacer item
     */
    addSpacer: function addSpacer() {
      return this.add(new T.Spacer());
    },

    /**
     * Forces subsequent additions into the float:right toolbar
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     */
    addFill: function addFill() {
      this.add(new T.Fill());
    },

    /**
     * Adds any standard HTML element to the toolbar
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Mixed} el The element or id of the element to add
     * @return {Ext.Toolbar.Item} The element's item
     */
    addElement: function addElement(el) {
      return this.addItem(new T.Item({
        el: el
      }));
    },

    /**
     * Adds any Toolbar.Item or subclass
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Ext.Toolbar.Item} item
     * @return {Ext.Toolbar.Item} The item
     */
    addItem: function addItem(item) {
      return this.add.apply(this, arguments);
    },

    /**
     * Adds a button (or buttons). See {@link Ext.Button} for more info on the config.
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Object/Array} config A button config or array of configs
     * @return {Ext.Button/Array}
     */
    addButton: function addButton(config) {
      if (Ext.isArray(config)) {
        var buttons = [];

        for (var i = 0, len = config.length; i < len; i++) {
          buttons.push(this.addButton(config[i]));
        }

        return buttons;
      }

      return this.add(this.constructButton(config));
    },

    /**
     * Adds text to the toolbar
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {String} text The text to add
     * @return {Ext.Toolbar.Item} The element's item
     */
    addText: function addText(text) {
      return this.addItem(new T.TextItem(text));
    },

    /**
     * Adds a new element to the toolbar from the passed {@link Ext.DomHelper} config
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Object} config
     * @return {Ext.Toolbar.Item} The element's item
     */
    addDom: function addDom(config) {
      return this.add(new T.Item({
        autoEl: config
      }));
    },

    /**
     * Adds a dynamically rendered Ext.form field (TextField, ComboBox, etc). Note: the field should not have
     * been rendered yet. For a field that has already been rendered, use {@link #addElement}.
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Ext.form.Field} field
     * @return {Ext.Toolbar.Item}
     */
    addField: function addField(field) {
      return this.add(field);
    },

    /**
     * Inserts any {@link Ext.Toolbar.Item}/{@link Ext.Button} at the specified index.
     * <br><p><b>Note</b>: See the notes within {@link Ext.Container#add}.</p>
     * @param {Number} index The index where the item is to be inserted
     * @param {Object/Ext.Toolbar.Item/Ext.Button/Array} item The button, or button config object to be
     * inserted, or an array of buttons/configs.
     * @return {Ext.Button/Item}
     */
    insertButton: function insertButton(index, item) {
      if (Ext.isArray(item)) {
        var buttons = [];

        for (var i = 0, len = item.length; i < len; i++) {
          buttons.push(this.insertButton(index + i, item[i]));
        }

        return buttons;
      }

      return Ext.Toolbar.superclass.insert.call(this, index, item);
    },
    // private
    trackMenu: function trackMenu(item, remove) {
      if (this.trackMenus && item.menu) {
        var method = remove ? 'mun' : 'mon';
        this[method](item, 'menutriggerover', this.onButtonTriggerOver, this);
        this[method](item, 'menushow', this.onButtonMenuShow, this);
        this[method](item, 'menuhide', this.onButtonMenuHide, this);
      }
    },
    // private
    constructButton: function constructButton(item) {
      var b = item.events ? item : this.createComponent(item, item.split ? 'splitbutton' : this.defaultType);
      return b;
    },
    // private
    onAdd: function onAdd(c) {
      Ext.Toolbar.superclass.onAdd.call(this);
      this.trackMenu(c);

      if (this.disabled) {
        c.disable();
      }
    },
    // private
    onRemove: function onRemove(c) {
      Ext.Toolbar.superclass.onRemove.call(this);
      this.trackMenu(c, true);
    },
    // private
    onDisable: function onDisable() {
      this.items.each(function (item) {
        if (item.disable) {
          item.disable();
        }
      });
    },
    // private
    onEnable: function onEnable() {
      this.items.each(function (item) {
        if (item.enable) {
          item.enable();
        }
      });
    },
    // private
    onButtonTriggerOver: function onButtonTriggerOver(btn) {
      if (this.activeMenuBtn && this.activeMenuBtn != btn) {
        this.activeMenuBtn.hideMenu();
        btn.showMenu();
        this.activeMenuBtn = btn;
      }
    },
    // private
    onButtonMenuShow: function onButtonMenuShow(btn) {
      this.activeMenuBtn = btn;
    },
    // private
    onButtonMenuHide: function onButtonMenuHide(btn) {
      delete this.activeMenuBtn;
    }
  });
  Ext.reg('toolbar', Ext.Toolbar);
  /**
   * @class Ext.Toolbar.Item
   * @extends Ext.BoxComponent
   * The base class that other non-interacting Toolbar Item classes should extend in order to
   * get some basic common toolbar item functionality.
   * @constructor
   * Creates a new Item
   * @param {HTMLElement} el
   * @xtype tbitem
   */

  T.Item = Ext.extend(Ext.BoxComponent, {
    hideParent: true,
    //  Hiding a Toolbar.Item hides its containing TD
    enable: Ext.emptyFn,
    disable: Ext.emptyFn,
    focus: Ext.emptyFn
    /**
     * @cfg {String} overflowText Text to be used for the menu if the item is overflowed.
     */

  });
  Ext.reg('tbitem', T.Item);
  /**
   * @class Ext.Toolbar.Separator
   * @extends Ext.Toolbar.Item
   * A simple class that adds a vertical separator bar between toolbar items
   * (css class:<tt>'xtb-sep'</tt>). Example usage:
   * <pre><code>
  new Ext.Panel({
      tbar : [
          'Item 1',
          {xtype: 'tbseparator'}, // or '-'
          'Item 2'
      ]
  });
  </code></pre>
   * @constructor
   * Creates a new Separator
   * @xtype tbseparator
   */

  T.Separator = Ext.extend(T.Item, {
    onRender: function onRender(ct, position) {
      this.el = ct.createChild({
        tag: 'span',
        cls: 'xtb-sep'
      }, position);
    }
  });
  Ext.reg('tbseparator', T.Separator);
  /**
   * @class Ext.Toolbar.Spacer
   * @extends Ext.Toolbar.Item
   * A simple element that adds extra horizontal space between items in a toolbar.
   * By default a 2px wide space is added via css specification:<pre><code>
  .x-toolbar .xtb-spacer {
      width:2px;
  }
   * </code></pre>
   * <p>Example usage:</p>
   * <pre><code>
  new Ext.Panel({
      tbar : [
          'Item 1',
          {xtype: 'tbspacer'}, // or ' '
          'Item 2',
          // space width is also configurable via javascript
          {xtype: 'tbspacer', width: 50}, // add a 50px space
          'Item 3'
      ]
  });
  </code></pre>
   * @constructor
   * Creates a new Spacer
   * @xtype tbspacer
   */

  T.Spacer = Ext.extend(T.Item, {
    /**
     * @cfg {Number} width
     * The width of the spacer in pixels (defaults to 2px via css style <tt>.x-toolbar .xtb-spacer</tt>).
     */
    onRender: function onRender(ct, position) {
      this.el = ct.createChild({
        tag: 'div',
        cls: 'xtb-spacer',
        style: this.width ? 'width:' + this.width + 'px' : ''
      }, position);
    }
  });
  Ext.reg('tbspacer', T.Spacer);
  /**
   * @class Ext.Toolbar.Fill
   * @extends Ext.Toolbar.Spacer
   * A non-rendering placeholder item which instructs the Toolbar's Layout to begin using
   * the right-justified button container.
   * <pre><code>
  new Ext.Panel({
      tbar : [
          'Item 1',
          {xtype: 'tbfill'}, // or '->'
          'Item 2'
      ]
  });
  </code></pre>
   * @constructor
   * Creates a new Fill
   * @xtype tbfill
   */

  T.Fill = Ext.extend(T.Item, {
    // private
    render: Ext.emptyFn,
    isFill: true
  });
  Ext.reg('tbfill', T.Fill);
  /**
   * @class Ext.Toolbar.TextItem
   * @extends Ext.Toolbar.Item
   * A simple class that renders text directly into a toolbar
   * (with css class:<tt>'xtb-text'</tt>). Example usage:
   * <pre><code>
  new Ext.Panel({
      tbar : [
          {xtype: 'tbtext', text: 'Item 1'} // or simply 'Item 1'
      ]
  });
  </code></pre>
   * @constructor
   * Creates a new TextItem
   * @param {String/Object} text A text string, or a config object containing a <tt>text</tt> property
   * @xtype tbtext
   */

  T.TextItem = Ext.extend(T.Item, {
    /**
     * @cfg {String} text The text to be used as innerHTML (html tags are accepted)
     */
    constructor: function constructor(config) {
      T.TextItem.superclass.constructor.call(this, Ext.isString(config) ? {
        text: config
      } : config);
    },
    // private
    onRender: function onRender(ct, position) {
      this.autoEl = {
        cls: 'xtb-text',
        html: this.text || ''
      };
      T.TextItem.superclass.onRender.call(this, ct, position);
    },

    /**
     * Updates this item's text, setting the text to be used as innerHTML.
     * @param {String} t The text to display (html accepted).
     */
    setText: function setText(t) {
      if (this.rendered) {
        this.el.update(t);
      } else {
        this.text = t;
      }
    }
  });
  Ext.reg('tbtext', T.TextItem); // backwards compat

  T.Button = Ext.extend(Ext.Button, {});
  T.SplitButton = Ext.extend(Ext.SplitButton, {});
  Ext.reg('tbbutton', T.Button);
  Ext.reg('tbsplit', T.SplitButton);
})();

/***/ }),
/* 840 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ButtonGroup
 * @extends Ext.Panel
 * Container for a group of buttons. Example usage:
 * <pre><code>
var p = new Ext.Panel({
    title: 'Panel with Button Group',
    width: 300,
    height:200,
    renderTo: document.body,
    html: 'whatever',
    tbar: [{
        xtype: 'buttongroup',
        {@link #columns}: 3,
        title: 'Clipboard',
        items: [{
            text: 'Paste',
            scale: 'large',
            rowspan: 3, iconCls: 'add',
            iconAlign: 'top',
            cls: 'x-btn-as-arrow'
        },{
            xtype:'splitbutton',
            text: 'Menu Button',
            scale: 'large',
            rowspan: 3,
            iconCls: 'add',
            iconAlign: 'top',
            arrowAlign:'bottom',
            menu: [{text: 'Menu Item 1'}]
        },{
            xtype:'splitbutton', text: 'Cut', iconCls: 'add16', menu: [{text: 'Cut Menu Item'}]
        },{
            text: 'Copy', iconCls: 'add16'
        },{
            text: 'Format', iconCls: 'add16'
        }]
    }]
});
 * </code></pre>
 * @constructor
 * Create a new ButtonGroup.
 * @param {Object} config The config object
 * @xtype buttongroup
 */
Ext.ButtonGroup = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Number} columns The <tt>columns</tt> configuration property passed to the
   * {@link #layout configured layout manager}. See {@link Ext.layout.TableLayout#columns}.
   */

  /**
   * @cfg {String} baseCls  Defaults to <tt>'x-btn-group'</tt>.  See {@link Ext.Panel#baseCls}.
   */
  baseCls: 'x-btn-group',

  /**
   * @cfg {String} layout  Defaults to <tt>'table'</tt>.  See {@link Ext.Container#layout}.
   */
  layout: 'table',
  defaultType: 'button',

  /**
   * @cfg {Boolean} frame  Defaults to <tt>true</tt>.  See {@link Ext.Panel#frame}.
   */
  frame: true,
  internalDefaults: {
    removeMode: 'container',
    hideParent: true
  },
  initComponent: function initComponent() {
    this.layoutConfig = this.layoutConfig || {};
    Ext.applyIf(this.layoutConfig, {
      columns: this.columns
    });

    if (!this.title) {
      this.addClass('x-btn-group-notitle');
    }

    this.on('afterlayout', this.onAfterLayout, this);
    Ext.ButtonGroup.superclass.initComponent.call(this);
  },
  applyDefaults: function applyDefaults(c) {
    c = Ext.ButtonGroup.superclass.applyDefaults.call(this, c);
    var d = this.internalDefaults;

    if (c.events) {
      Ext.applyIf(c.initialConfig, d);
      Ext.apply(c, d);
    } else {
      Ext.applyIf(c, d);
    }

    return c;
  },
  onAfterLayout: function onAfterLayout() {
    var bodyWidth = this.body.getFrameWidth('lr') + this.body.dom.firstChild.offsetWidth;
    this.body.setWidth(bodyWidth);
    this.el.setWidth(bodyWidth + this.getFrameWidth());
  }
  /**
   * @cfg {Array} tools  @hide
   */

});
Ext.reg('buttongroup', Ext.ButtonGroup);

/***/ }),
/* 841 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.PagingToolbar
 * @extends Ext.Toolbar
 * <p>As the amount of records increases, the time required for the browser to render
 * them increases. Paging is used to reduce the amount of data exchanged with the client.
 * Note: if there are more records/rows than can be viewed in the available screen area, vertical
 * scrollbars will be added.</p>
 * <p>Paging is typically handled on the server side (see exception below). The client sends
 * parameters to the server side, which the server needs to interpret and then respond with the
 * approprate data.</p>
 * <p><b>Ext.PagingToolbar</b> is a specialized toolbar that is bound to a {@link Ext.data.Store}
 * and provides automatic paging control. This Component {@link Ext.data.Store#load load}s blocks
 * of data into the <tt>{@link #store}</tt> by passing {@link Ext.data.Store#paramNames paramNames} used for
 * paging criteria.</p>
 * <p>PagingToolbar is typically used as one of the Grid's toolbars:</p>
 * <pre><code>
Ext.QuickTips.init(); // to display button quicktips

var myStore = new Ext.data.Store({
    reader: new Ext.data.JsonReader({
        {@link Ext.data.JsonReader#totalProperty totalProperty}: 'results', 
        ...
    }),
    ...
});

var myPageSize = 25;  // server script should only send back 25 items at a time

var grid = new Ext.grid.GridPanel({
    ...
    store: myStore,
    bbar: new Ext.PagingToolbar({
        {@link #store}: myStore,       // grid and PagingToolbar using same store
        {@link #displayInfo}: true,
        {@link #pageSize}: myPageSize,
        {@link #prependButtons}: true,
        items: [
            'text 1'
        ]
    })
});
 * </code></pre>
 *
 * <p>To use paging, pass the paging requirements to the server when the store is first loaded.</p>
 * <pre><code>
store.load({
    params: {
        // specify params for the first page load if using paging
        start: 0,          
        limit: myPageSize,
        // other params
        foo:   'bar'
    }
});
 * </code></pre>
 * 
 * <p>If using {@link Ext.data.Store#autoLoad store's autoLoad} configuration:</p>
 * <pre><code>
var myStore = new Ext.data.Store({
    {@link Ext.data.Store#autoLoad autoLoad}: {params:{start: 0, limit: 25}},
    ...
});
 * </code></pre>
 * 
 * <p>The packet sent back from the server would have this form:</p>
 * <pre><code>
{
    "success": true,
    "results": 2000, 
    "rows": [ // <b>*Note:</b> this must be an Array 
        { "id":  1, "name": "Bill", "occupation": "Gardener" },
        { "id":  2, "name":  "Ben", "occupation": "Horticulturalist" },
        ...
        { "id": 25, "name":  "Sue", "occupation": "Botanist" }
    ]
}
 * </code></pre>
 * <p><u>Paging with Local Data</u></p>
 * <p>Paging can also be accomplished with local data using extensions:</p>
 * <div class="mdetail-params"><ul>
 * <li><a href="http://extjs.com/forum/showthread.php?t=71532">Ext.ux.data.PagingStore</a></li>
 * <li>Paging Memory Proxy (examples/ux/PagingMemoryProxy.js)</li>
 * </ul></div>
 * @constructor Create a new PagingToolbar
 * @param {Object} config The config object
 * @xtype paging
 */
(function () {
  var T = Ext.Toolbar;
  Ext.PagingToolbar = Ext.extend(Ext.Toolbar, {
    /**
     * @cfg {Ext.data.Store} store
     * The {@link Ext.data.Store} the paging toolbar should use as its data source (required).
     */

    /**
     * @cfg {Boolean} displayInfo
     * <tt>true</tt> to display the displayMsg (defaults to <tt>false</tt>)
     */

    /**
     * @cfg {Number} pageSize
     * The number of records to display per page (defaults to <tt>20</tt>)
     */
    pageSize: 20,

    /**
     * @cfg {Boolean} prependButtons
     * <tt>true</tt> to insert any configured <tt>items</tt> <i>before</i> the paging buttons.
     * Defaults to <tt>false</tt>.
     */

    /**
     * @cfg {String} displayMsg
     * The paging status message to display (defaults to <tt>'Displaying {0} - {1} of {2}'</tt>).
     * Note that this string is formatted using the braced numbers <tt>{0}-{2}</tt> as tokens
     * that are replaced by the values for start, end and total respectively. These tokens should
     * be preserved when overriding this string if showing those values is desired.
     */
    displayMsg: 'Displaying {0} - {1} of {2}',

    /**
     * @cfg {String} emptyMsg
     * The message to display when no records are found (defaults to 'No data to display')
     */
    emptyMsg: 'No data to display',

    /**
     * @cfg {String} beforePageText
     * The text displayed before the input item (defaults to <tt>'Page'</tt>).
     */
    beforePageText: 'Page',

    /**
     * @cfg {String} afterPageText
     * Customizable piece of the default paging text (defaults to <tt>'of {0}'</tt>). Note that
     * this string is formatted using <tt>{0}</tt> as a token that is replaced by the number of
     * total pages. This token should be preserved when overriding this string if showing the
     * total page count is desired.
     */
    afterPageText: 'of {0}',

    /**
     * @cfg {String} firstText
     * The quicktip text displayed for the first page button (defaults to <tt>'First Page'</tt>).
     * <b>Note</b>: quick tips must be initialized for the quicktip to show.
     */
    firstText: 'First Page',

    /**
     * @cfg {String} prevText
     * The quicktip text displayed for the previous page button (defaults to <tt>'Previous Page'</tt>).
     * <b>Note</b>: quick tips must be initialized for the quicktip to show.
     */
    prevText: 'Previous Page',

    /**
     * @cfg {String} nextText
     * The quicktip text displayed for the next page button (defaults to <tt>'Next Page'</tt>).
     * <b>Note</b>: quick tips must be initialized for the quicktip to show.
     */
    nextText: 'Next Page',

    /**
     * @cfg {String} lastText
     * The quicktip text displayed for the last page button (defaults to <tt>'Last Page'</tt>).
     * <b>Note</b>: quick tips must be initialized for the quicktip to show.
     */
    lastText: 'Last Page',

    /**
     * @cfg {String} refreshText
     * The quicktip text displayed for the Refresh button (defaults to <tt>'Refresh'</tt>).
     * <b>Note</b>: quick tips must be initialized for the quicktip to show.
     */
    refreshText: 'Refresh',

    /**
     * <p><b>Deprecated</b>. <code>paramNames</code> should be set in the <b>data store</b>
     * (see {@link Ext.data.Store#paramNames}).</p>
     * <br><p>Object mapping of parameter names used for load calls, initially set to:</p>
     * <pre>{start: 'start', limit: 'limit'}</pre>
     * @type Object
     * @property paramNames
     * @deprecated
     */

    /**
     * The number of records to display per page.  See also <tt>{@link #cursor}</tt>.
     * @type Number
     * @property pageSize
     */

    /**
     * Indicator for the record position.  This property might be used to get the active page
     * number for example:<pre><code>
     * // t is reference to the paging toolbar instance
     * var activePage = Math.ceil((t.cursor + t.pageSize) / t.pageSize);
     * </code></pre>
     * @type Number
     * @property cursor
     */
    initComponent: function initComponent() {
      var pagingItems = [this.first = new T.Button({
        tooltip: this.firstText,
        overflowText: this.firstText,
        iconCls: 'x-tbar-page-first',
        disabled: true,
        handler: this.moveFirst,
        scope: this
      }), this.prev = new T.Button({
        tooltip: this.prevText,
        overflowText: this.prevText,
        iconCls: 'x-tbar-page-prev',
        disabled: true,
        handler: this.movePrevious,
        scope: this
      }), '-', this.beforePageText, this.inputItem = new Ext.form.NumberField({
        cls: 'x-tbar-page-number',
        allowDecimals: false,
        allowNegative: false,
        enableKeyEvents: true,
        selectOnFocus: true,
        submitValue: false,
        listeners: {
          scope: this,
          keydown: this.onPagingKeyDown,
          blur: this.onPagingBlur
        }
      }), this.afterTextItem = new T.TextItem({
        text: String.format(this.afterPageText, 1)
      }), '-', this.next = new T.Button({
        tooltip: this.nextText,
        overflowText: this.nextText,
        iconCls: 'x-tbar-page-next',
        disabled: true,
        handler: this.moveNext,
        scope: this
      }), this.last = new T.Button({
        tooltip: this.lastText,
        overflowText: this.lastText,
        iconCls: 'x-tbar-page-last',
        disabled: true,
        handler: this.moveLast,
        scope: this
      }), '-', this.refresh = new T.Button({
        tooltip: this.refreshText,
        overflowText: this.refreshText,
        iconCls: 'x-tbar-loading',
        handler: this.doRefresh,
        scope: this
      })];
      var userItems = this.items || this.buttons || [];

      if (this.prependButtons) {
        this.items = userItems.concat(pagingItems);
      } else {
        this.items = pagingItems.concat(userItems);
      }

      delete this.buttons;

      if (this.displayInfo) {
        this.items.push('->');
        this.items.push(this.displayItem = new T.TextItem({}));
      }

      Ext.PagingToolbar.superclass.initComponent.call(this);
      this.addEvents(
      /**
       * @event change
       * Fires after the active page has been changed.
       * @param {Ext.PagingToolbar} this
       * @param {Object} pageData An object that has these properties:<ul>
       * <li><code>total</code> : Number <div class="sub-desc">The total number of records in the dataset as
       * returned by the server</div></li>
       * <li><code>activePage</code> : Number <div class="sub-desc">The current page number</div></li>
       * <li><code>pages</code> : Number <div class="sub-desc">The total number of pages (calculated from
       * the total number of records in the dataset as returned by the server and the current {@link #pageSize})</div></li>
       * </ul>
       */
      'change',
      /**
       * @event beforechange
       * Fires just before the active page is changed.
       * Return false to prevent the active page from being changed.
       * @param {Ext.PagingToolbar} this
       * @param {Object} params An object hash of the parameters which the PagingToolbar will send when
       * loading the required page. This will contain:<ul>
       * <li><code>start</code> : Number <div class="sub-desc">The starting row number for the next page of records to
       * be retrieved from the server</div></li>
       * <li><code>limit</code> : Number <div class="sub-desc">The number of records to be retrieved from the server</div></li>
       * </ul>
       * <p>(note: the names of the <b>start</b> and <b>limit</b> properties are determined
       * by the store's {@link Ext.data.Store#paramNames paramNames} property.)</p>
       * <p>Parameters may be added as required in the event handler.</p>
       */
      'beforechange');
      this.on('afterlayout', this.onFirstLayout, this, {
        single: true
      });
      this.cursor = 0;
      this.bindStore(this.store, true);
    },
    // private
    onFirstLayout: function onFirstLayout() {
      if (this.dsLoaded) {
        this.onLoad.apply(this, this.dsLoaded);
      }
    },
    // private
    updateInfo: function updateInfo() {
      if (this.displayItem) {
        var count = this.store.getCount();
        var msg = count == 0 ? this.emptyMsg : String.format(this.displayMsg, this.cursor + 1, this.cursor + count, this.store.getTotalCount());
        this.displayItem.setText(msg);
      }
    },
    // private
    onLoad: function onLoad(store, r, o) {
      if (!this.rendered) {
        this.dsLoaded = [store, r, o];
        return;
      }

      var p = this.getParams();
      this.cursor = o.params && o.params[p.start] ? o.params[p.start] : 0;
      var d = this.getPageData(),
          ap = d.activePage,
          ps = d.pages;
      this.afterTextItem.setText(String.format(this.afterPageText, d.pages));
      this.inputItem.setValue(ap);
      this.first.setDisabled(ap == 1);
      this.prev.setDisabled(ap == 1);
      this.next.setDisabled(ap == ps);
      this.last.setDisabled(ap == ps);
      this.refresh.enable();
      this.updateInfo();
      this.fireEvent('change', this, d);
    },
    // private
    getPageData: function getPageData() {
      var total = this.store.getTotalCount();
      return {
        total: total,
        activePage: Math.ceil((this.cursor + this.pageSize) / this.pageSize),
        pages: total < this.pageSize ? 1 : Math.ceil(total / this.pageSize)
      };
    },

    /**
     * Change the active page
     * @param {Integer} page The page to display
     */
    changePage: function changePage(page) {
      this.doLoad(((page - 1) * this.pageSize).constrain(0, this.store.getTotalCount()));
    },
    // private
    onLoadError: function onLoadError() {
      if (!this.rendered) {
        return;
      }

      this.refresh.enable();
    },
    // private
    readPage: function readPage(d) {
      var v = this.inputItem.getValue(),
          pageNum;

      if (!v || isNaN(pageNum = parseInt(v, 10))) {
        this.inputItem.setValue(d.activePage);
        return false;
      }

      return pageNum;
    },
    onPagingFocus: function onPagingFocus() {
      this.inputItem.select();
    },
    //private
    onPagingBlur: function onPagingBlur(e) {
      this.inputItem.setValue(this.getPageData().activePage);
    },
    // private
    onPagingKeyDown: function onPagingKeyDown(field, e) {
      var k = e.getKey(),
          d = this.getPageData(),
          pageNum;

      if (k == e.RETURN) {
        e.stopEvent();
        pageNum = this.readPage(d);

        if (pageNum !== false) {
          pageNum = Math.min(Math.max(1, pageNum), d.pages) - 1;
          this.doLoad(pageNum * this.pageSize);
        }
      } else if (k == e.HOME || k == e.END) {
        e.stopEvent();
        pageNum = k == e.HOME ? 1 : d.pages;
        field.setValue(pageNum);
      } else if (k == e.UP || k == e.PAGEUP || k == e.DOWN || k == e.PAGEDOWN) {
        e.stopEvent();

        if (pageNum = this.readPage(d)) {
          var increment = e.shiftKey ? 10 : 1;

          if (k == e.DOWN || k == e.PAGEDOWN) {
            increment *= -1;
          }

          pageNum += increment;

          if (pageNum >= 1 & pageNum <= d.pages) {
            field.setValue(pageNum);
          }
        }
      }
    },
    // private
    getParams: function getParams() {
      //retain backwards compat, allow params on the toolbar itself, if they exist.
      return this.paramNames || this.store.paramNames;
    },
    // private
    beforeLoad: function beforeLoad() {
      if (this.rendered && this.refresh) {
        this.refresh.disable();
      }
    },
    // private
    doLoad: function doLoad(start) {
      var o = {},
          pn = this.getParams();
      o[pn.start] = start;
      o[pn.limit] = this.pageSize;

      if (this.fireEvent('beforechange', this, o) !== false) {
        this.store.load({
          params: o
        });
      }
    },

    /**
     * Move to the first page, has the same effect as clicking the 'first' button.
     */
    moveFirst: function moveFirst() {
      this.doLoad(0);
    },

    /**
     * Move to the previous page, has the same effect as clicking the 'previous' button.
     */
    movePrevious: function movePrevious() {
      this.doLoad(Math.max(0, this.cursor - this.pageSize));
    },

    /**
     * Move to the next page, has the same effect as clicking the 'next' button.
     */
    moveNext: function moveNext() {
      this.doLoad(this.cursor + this.pageSize);
    },

    /**
     * Move to the last page, has the same effect as clicking the 'last' button.
     */
    moveLast: function moveLast() {
      var total = this.store.getTotalCount(),
          extra = total % this.pageSize;
      this.doLoad(extra ? total - extra : total - this.pageSize);
    },

    /**
     * Refresh the current page, has the same effect as clicking the 'refresh' button.
     */
    doRefresh: function doRefresh() {
      this.doLoad(this.cursor);
    },

    /**
     * Binds the paging toolbar to the specified {@link Ext.data.Store}
     * @param {Store} store The store to bind to this toolbar
     * @param {Boolean} initial (Optional) true to not remove listeners
     */
    bindStore: function bindStore(store, initial) {
      var doLoad;

      if (!initial && this.store) {
        if (store !== this.store && this.store.autoDestroy) {
          this.store.destroy();
        } else {
          this.store.un('beforeload', this.beforeLoad, this);
          this.store.un('load', this.onLoad, this);
          this.store.un('exception', this.onLoadError, this);
        }

        if (!store) {
          this.store = null;
        }
      }

      if (store) {
        store = Ext.StoreMgr.lookup(store);
        store.on({
          scope: this,
          beforeload: this.beforeLoad,
          load: this.onLoad,
          exception: this.onLoadError
        });
        doLoad = true;
      }

      this.store = store;

      if (doLoad) {
        this.onLoad(store, null, {});
      }
    },

    /**
     * Unbinds the paging toolbar from the specified {@link Ext.data.Store} <b>(deprecated)</b>
     * @param {Ext.data.Store} store The data store to unbind
     */
    unbind: function unbind(store) {
      this.bindStore(null);
    },

    /**
     * Binds the paging toolbar to the specified {@link Ext.data.Store} <b>(deprecated)</b>
     * @param {Ext.data.Store} store The data store to bind
     */
    bind: function bind(store) {
      this.bindStore(store);
    },
    // private
    onDestroy: function onDestroy() {
      this.bindStore(null);
      Ext.PagingToolbar.superclass.onDestroy.call(this);
    }
  });
})();

Ext.reg('paging', Ext.PagingToolbar);

/***/ }),
/* 842 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.History
 * @extends Ext.util.Observable
 * History management component that allows you to register arbitrary tokens that signify application
 * history state on navigation actions.  You can then handle the history {@link #change} event in order
 * to reset your application UI to the appropriate state when the user navigates forward or backward through
 * the browser history stack.
 * @singleton
 */
Ext.History = function () {
  var iframe, hiddenField;
  var ready = false;
  var currentToken;

  function getHash() {
    var href = top.location.href,
        i = href.indexOf("#");
    return i >= 0 ? href.substr(i + 1) : null;
  }

  function doSave() {
    hiddenField.value = currentToken;
  }

  function handleStateChange(token) {
    currentToken = token;
    Ext.History.fireEvent('change', token);
  }

  function updateIFrame(token) {
    var html = ['<html><body><div id="state">', Ext.util.Format.htmlEncode(token), '</div></body></html>'].join('');

    try {
      var doc = iframe.contentWindow.document;
      doc.open();
      doc.write(html);
      doc.close();
      return true;
    } catch (e) {
      return false;
    }
  }

  function checkIFrame() {
    if (!iframe.contentWindow || !iframe.contentWindow.document) {
      setTimeout(checkIFrame, 10);
      return;
    }

    var doc = iframe.contentWindow.document;
    var elem = doc.getElementById("state");
    var token = elem ? elem.innerText : null;
    var hash = getHash();
    setInterval(function () {
      doc = iframe.contentWindow.document;
      elem = doc.getElementById("state");
      var newtoken = elem ? elem.innerText : null;
      var newHash = getHash();

      if (newtoken !== token) {
        token = newtoken;
        handleStateChange(token);
        top.location.hash = token;
        hash = token;
        doSave();
      } else if (newHash !== hash) {
        hash = newHash;
        updateIFrame(newHash);
      }
    }, 50);
    ready = true;
    Ext.History.fireEvent('ready', Ext.History);
  }

  function startUp() {
    currentToken = hiddenField.value ? hiddenField.value : getHash();

    if (Ext.isIE) {
      checkIFrame();
    } else {
      var hash = getHash();
      setInterval(function () {
        var newHash = getHash();

        if (newHash !== hash) {
          hash = newHash;
          handleStateChange(hash);
          doSave();
        }
      }, 50);
      ready = true;
      Ext.History.fireEvent('ready', Ext.History);
    }
  }

  return {
    /**
     * The id of the hidden field required for storing the current history token.
     * @type String
     * @property
     */
    fieldId: 'x-history-field',

    /**
     * The id of the iframe required by IE to manage the history stack.
     * @type String
     * @property
     */
    iframeId: 'x-history-frame',
    events: {},

    /**
     * Initialize the global History instance.
     * @param {Boolean} onReady (optional) A callback function that will be called once the history
     * component is fully initialized.
     * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to the browser window.
     */
    init: function init(onReady, scope) {
      if (ready) {
        Ext.callback(onReady, scope, [this]);
        return;
      }

      if (!Ext.isReady) {
        Ext.onReady(function () {
          Ext.History.init(onReady, scope);
        });
        return;
      }

      hiddenField = Ext.getDom(Ext.History.fieldId);

      if (Ext.isIE) {
        iframe = Ext.getDom(Ext.History.iframeId);
      }

      this.addEvents(
      /**
       * @event ready
       * Fires when the Ext.History singleton has been initialized and is ready for use.
       * @param {Ext.History} The Ext.History singleton.
       */
      'ready',
      /**
       * @event change
       * Fires when navigation back or forwards within the local page's history occurs.
       * @param {String} token An identifier associated with the page state at that point in its history.
       */
      'change');

      if (onReady) {
        this.on('ready', onReady, scope, {
          single: true
        });
      }

      startUp();
    },

    /**
     * Add a new token to the history stack. This can be any arbitrary value, although it would
     * commonly be the concatenation of a component id and another id marking the specifc history
     * state of that component.  Example usage:
     * <pre><code>
    // Handle tab changes on a TabPanel
    tabPanel.on('tabchange', function(tabPanel, tab){
    Ext.History.add(tabPanel.id + ':' + tab.id);
    });
    </code></pre>
     * @param {String} token The value that defines a particular application-specific history state
     * @param {Boolean} preventDuplicates When true, if the passed token matches the current token
     * it will not save a new history step. Set to false if the same state can be saved more than once
     * at the same history stack location (defaults to true).
     */
    add: function add(token, preventDup) {
      if (preventDup !== false) {
        if (this.getToken() == token) {
          return true;
        }
      }

      if (Ext.isIE) {
        return updateIFrame(token);
      } else {
        top.location.hash = token;
        return true;
      }
    },

    /**
     * Programmatically steps back one step in browser history (equivalent to the user pressing the Back button).
     */
    back: function back() {
      history.go(-1);
    },

    /**
     * Programmatically steps forward one step in browser history (equivalent to the user pressing the Forward button).
     */
    forward: function forward() {
      history.go(1);
    },

    /**
     * Retrieves the currently-active history token.
     * @return {String} The token
     */
    getToken: function getToken() {
      return ready ? currentToken : getHash();
    }
  };
}();

Ext.apply(Ext.History, new Ext.util.Observable());

/***/ }),
/* 843 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.Tip
 * @extends Ext.Panel
 * @xtype tip
 * This is the base class for {@link Ext.QuickTip} and {@link Ext.Tooltip} that provides the basic layout and
 * positioning that all tip-based classes require. This class can be used directly for simple, statically-positioned
 * tips that are displayed programmatically, or it can be extended to provide custom tip implementations.
 * @constructor
 * Create a new Tip
 * @param {Object} config The configuration options
 */
Ext.Tip = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Boolean} closable True to render a close tool button into the tooltip header (defaults to false).
   */

  /**
   * @cfg {Number} width
   * Width in pixels of the tip (defaults to auto).  Width will be ignored if it exceeds the bounds of
   * {@link #minWidth} or {@link #maxWidth}.  The maximum supported value is 500.
   */

  /**
   * @cfg {Number} minWidth The minimum width of the tip in pixels (defaults to 40).
   */
  minWidth: 40,

  /**
   * @cfg {Number} maxWidth The maximum width of the tip in pixels (defaults to 300).  The maximum supported value is 500.
   */
  maxWidth: 300,

  /**
   * @cfg {Boolean/String} shadow True or "sides" for the default effect, "frame" for 4-way shadow, and "drop"
   * for bottom-right shadow (defaults to "sides").
   */
  shadow: "sides",

  /**
   * @cfg {String} defaultAlign <b>Experimental</b>. The default {@link Ext.Element#alignTo} anchor position value
   * for this tip relative to its element of origin (defaults to "tl-bl?").
   */
  defaultAlign: "tl-bl?",
  autoRender: true,
  quickShowInterval: 250,
  // private panel overrides
  frame: true,
  hidden: true,
  baseCls: 'x-tip',
  floating: {
    shadow: true,
    shim: true,
    useDisplay: true,
    constrain: false
  },
  autoHeight: true,
  closeAction: 'hide',
  // private
  initComponent: function initComponent() {
    Ext.Tip.superclass.initComponent.call(this);

    if (this.closable && !this.title) {
      this.elements += ',header';
    }
  },
  // private
  afterRender: function afterRender() {
    Ext.Tip.superclass.afterRender.call(this);

    if (this.closable) {
      this.addTool({
        id: 'close',
        handler: this[this.closeAction],
        scope: this
      });
    }
  },

  /**
   * Shows this tip at the specified XY position.  Example usage:
   * <pre><code>
  // Show the tip at x:50 and y:100
  tip.showAt([50,100]);
  </code></pre>
   * @param {Array} xy An array containing the x and y coordinates
   */
  showAt: function showAt(xy) {
    Ext.Tip.superclass.show.call(this);

    if (this.measureWidth !== false && (!this.initialConfig || typeof this.initialConfig.width != 'number')) {
      this.doAutoWidth();
    }

    if (this.constrainPosition) {
      xy = this.el.adjustForConstraints(xy);
    }

    this.setPagePosition(xy[0], xy[1]);
  },
  // protected
  doAutoWidth: function doAutoWidth(adjust) {
    adjust = adjust || 0;
    var bw = this.body.getTextWidth();

    if (this.title) {
      bw = Math.max(bw, this.header.child('span').getTextWidth(this.title));
    }

    bw += this.getFrameWidth() + (this.closable ? 20 : 0) + this.body.getPadding("lr") + adjust;
    this.setWidth(bw.constrain(this.minWidth, this.maxWidth)); // IE7 repaint bug on initial show

    if (Ext.isIE7 && !this.repainted) {
      this.el.repaint();
      this.repainted = true;
    }
  },

  /**
   * <b>Experimental</b>. Shows this tip at a position relative to another element using a standard {@link Ext.Element#alignTo}
   * anchor position value.  Example usage:
   * <pre><code>
  // Show the tip at the default position ('tl-br?')
  tip.showBy('my-el');
  // Show the tip's top-left corner anchored to the element's top-right corner
  tip.showBy('my-el', 'tl-tr');
  </code></pre>
   * @param {Mixed} el An HTMLElement, Ext.Element or string id of the target element to align to
   * @param {String} position (optional) A valid {@link Ext.Element#alignTo} anchor position (defaults to 'tl-br?' or
   * {@link #defaultAlign} if specified).
   */
  showBy: function showBy(el, pos) {
    if (!this.rendered) {
      this.render(Ext.getBody());
    }

    this.showAt(this.el.getAlignToXY(el, pos || this.defaultAlign));
  },
  initDraggable: function initDraggable() {
    this.dd = new Ext.Tip.DD(this, typeof this.draggable == 'boolean' ? null : this.draggable);
    this.header.addClass('x-tip-draggable');
  }
});
Ext.reg('tip', Ext.Tip); // private - custom Tip DD implementation

Ext.Tip.DD = function (tip, config) {
  Ext.apply(this, config);
  this.tip = tip;
  Ext.Tip.DD.superclass.constructor.call(this, tip.el.id, 'WindowDD-' + tip.id);
  this.setHandleElId(tip.header.id);
  this.scroll = false;
};

Ext.extend(Ext.Tip.DD, Ext.dd.DD, {
  moveOnly: true,
  scroll: false,
  headerOffsets: [100, 25],
  startDrag: function startDrag() {
    this.tip.el.disableShadow();
  },
  endDrag: function endDrag(e) {
    this.tip.el.enableShadow(true);
  }
});

/***/ }),
/* 844 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ToolTip
 * @extends Ext.Tip
 * A standard tooltip implementation for providing additional information when hovering over a target element.
 * @xtype tooltip
 * @constructor
 * Create a new Tooltip
 * @param {Object} config The configuration options
 */
Ext.ToolTip = Ext.extend(Ext.Tip, {
  /**
   * When a Tooltip is configured with the <code>{@link #delegate}</code>
   * option to cause selected child elements of the <code>{@link #target}</code>
   * Element to each trigger a seperate show event, this property is set to
   * the DOM element which triggered the show.
   * @type DOMElement
   * @property triggerElement
   */

  /**
   * @cfg {Mixed} target The target HTMLElement, Ext.Element or id to monitor
   * for mouseover events to trigger showing this ToolTip.
   */

  /**
   * @cfg {Boolean} autoHide True to automatically hide the tooltip after the
   * mouse exits the target element or after the <code>{@link #dismissDelay}</code>
   * has expired if set (defaults to true).  If <code>{@link closable} = true</code>
   * a close tool button will be rendered into the tooltip header.
   */

  /**
   * @cfg {Number} showDelay Delay in milliseconds before the tooltip displays
   * after the mouse enters the target element (defaults to 500)
   */
  showDelay: 500,

  /**
   * @cfg {Number} hideDelay Delay in milliseconds after the mouse exits the
   * target element but before the tooltip actually hides (defaults to 200).
   * Set to 0 for the tooltip to hide immediately.
   */
  hideDelay: 200,

  /**
   * @cfg {Number} dismissDelay Delay in milliseconds before the tooltip
   * automatically hides (defaults to 5000). To disable automatic hiding, set
   * dismissDelay = 0.
   */
  dismissDelay: 5000,

  /**
   * @cfg {Array} mouseOffset An XY offset from the mouse position where the
   * tooltip should be shown (defaults to [15,18]).
   */

  /**
   * @cfg {Boolean} trackMouse True to have the tooltip follow the mouse as it
   * moves over the target element (defaults to false).
   */
  trackMouse: false,

  /**
   * @cfg {Boolean} anchorToTarget True to anchor the tooltip to the target
   * element, false to anchor it relative to the mouse coordinates (defaults
   * to true).  When <code>anchorToTarget</code> is true, use
   * <code>{@link #defaultAlign}</code> to control tooltip alignment to the
   * target element.  When <code>anchorToTarget</code> is false, use
   * <code>{@link #anchorPosition}</code> instead to control alignment.
   */
  anchorToTarget: true,

  /**
   * @cfg {Number} anchorOffset A numeric pixel value used to offset the
   * default position of the anchor arrow (defaults to 0).  When the anchor
   * position is on the top or bottom of the tooltip, <code>anchorOffset</code>
   * will be used as a horizontal offset.  Likewise, when the anchor position
   * is on the left or right side, <code>anchorOffset</code> will be used as
   * a vertical offset.
   */
  anchorOffset: 0,

  /**
   * @cfg {String} delegate <p>Optional. A {@link Ext.DomQuery DomQuery}
   * selector which allows selection of individual elements within the
   * <code>{@link #target}</code> element to trigger showing and hiding the
   * ToolTip as the mouse moves within the target.</p>
   * <p>When specified, the child element of the target which caused a show
   * event is placed into the <code>{@link #triggerElement}</code> property
   * before the ToolTip is shown.</p>
   * <p>This may be useful when a Component has regular, repeating elements
   * in it, each of which need a Tooltip which contains information specific
   * to that element. For example:</p><pre><code>
  var myGrid = new Ext.grid.gridPanel(gridConfig);
  myGrid.on('render', function(grid) {
  var store = grid.getStore();  // Capture the Store.
  var view = grid.getView();    // Capture the GridView.
  myGrid.tip = new Ext.ToolTip({
      target: view.mainBody,    // The overall target element.
      delegate: '.x-grid3-row', // Each grid row causes its own seperate show and hide.
      trackMouse: true,         // Moving within the row should not hide the tip.
      renderTo: document.body,  // Render immediately so that tip.body can be
                                //  referenced prior to the first show.
      listeners: {              // Change content dynamically depending on which element
                                //  triggered the show.
          beforeshow: function updateTipBody(tip) {
              var rowIndex = view.findRowIndex(tip.triggerElement);
              tip.body.dom.innerHTML = 'Over Record ID ' + store.getAt(rowIndex).id;
          }
      }
  });
  });
   *</code></pre>
   */
  // private
  targetCounter: 0,
  constrainPosition: false,
  // private
  initComponent: function initComponent() {
    Ext.ToolTip.superclass.initComponent.call(this);
    this.lastActive = new Date();
    this.initTarget(this.target);
    this.origAnchor = this.anchor;
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.ToolTip.superclass.onRender.call(this, ct, position);
    this.anchorCls = 'x-tip-anchor-' + this.getAnchorPosition();
    this.anchorEl = this.el.createChild({
      cls: 'x-tip-anchor ' + this.anchorCls
    });
  },
  // private
  afterRender: function afterRender() {
    Ext.ToolTip.superclass.afterRender.call(this);
    this.anchorEl.setStyle('z-index', this.el.getZIndex() + 1);
  },

  /**
   * Binds this ToolTip to the specified element. The tooltip will be displayed when the mouse moves over the element.
   * @param {Mixed} t The Element, HtmlElement, or ID of an element to bind to
   */
  initTarget: function initTarget(target) {
    var t;

    if (t = Ext.get(target)) {
      if (this.target) {
        var tg = Ext.get(this.target);
        this.mun(tg, 'mouseover', this.onTargetOver, this);
        this.mun(tg, 'mouseout', this.onTargetOut, this);
        this.mun(tg, 'mousemove', this.onMouseMove, this);
      }

      this.mon(t, {
        mouseover: this.onTargetOver,
        mouseout: this.onTargetOut,
        mousemove: this.onMouseMove,
        scope: this
      });
      this.target = t;
    }

    if (this.anchor) {
      this.anchorTarget = this.target;
    }
  },
  // private
  onMouseMove: function onMouseMove(e) {
    var t = this.delegate ? e.getTarget(this.delegate) : this.triggerElement = true;

    if (t) {
      this.targetXY = e.getXY();

      if (t === this.triggerElement) {
        if (!this.hidden && this.trackMouse) {
          this.setPagePosition(this.getTargetXY());
        }
      } else {
        this.hide();
        this.lastActive = new Date(0);
        this.onTargetOver(e);
      }
    } else if (!this.closable && this.isVisible()) {
      this.hide();
    }
  },
  // private
  getTargetXY: function getTargetXY() {
    if (this.delegate) {
      this.anchorTarget = this.triggerElement;
    }

    if (this.anchor) {
      this.targetCounter++;
      var offsets = this.getOffsets(),
          xy = this.anchorToTarget && !this.trackMouse ? this.el.getAlignToXY(this.anchorTarget, this.getAnchorAlign()) : this.targetXY,
          dw = Ext.lib.Dom.getViewWidth() - 5,
          dh = Ext.lib.Dom.getViewHeight() - 5,
          de = document.documentElement,
          bd = document.body,
          scrollX = (de.scrollLeft || bd.scrollLeft || 0) + 5,
          scrollY = (de.scrollTop || bd.scrollTop || 0) + 5,
          axy = [xy[0] + offsets[0], xy[1] + offsets[1]],
          sz = this.getSize();
      this.anchorEl.removeClass(this.anchorCls);

      if (this.targetCounter < 2) {
        if (axy[0] < scrollX) {
          if (this.anchorToTarget) {
            this.defaultAlign = 'l-r';

            if (this.mouseOffset) {
              this.mouseOffset[0] *= -1;
            }
          }

          this.anchor = 'left';
          return this.getTargetXY();
        }

        if (axy[0] + sz.width > dw) {
          if (this.anchorToTarget) {
            this.defaultAlign = 'r-l';

            if (this.mouseOffset) {
              this.mouseOffset[0] *= -1;
            }
          }

          this.anchor = 'right';
          return this.getTargetXY();
        }

        if (axy[1] < scrollY) {
          if (this.anchorToTarget) {
            this.defaultAlign = 't-b';

            if (this.mouseOffset) {
              this.mouseOffset[1] *= -1;
            }
          }

          this.anchor = 'top';
          return this.getTargetXY();
        }

        if (axy[1] + sz.height > dh) {
          if (this.anchorToTarget) {
            this.defaultAlign = 'b-t';

            if (this.mouseOffset) {
              this.mouseOffset[1] *= -1;
            }
          }

          this.anchor = 'bottom';
          return this.getTargetXY();
        }
      }

      this.anchorCls = 'x-tip-anchor-' + this.getAnchorPosition();
      this.anchorEl.addClass(this.anchorCls);
      this.targetCounter = 0;
      return axy;
    } else {
      var mouseOffset = this.getMouseOffset();
      return [this.targetXY[0] + mouseOffset[0], this.targetXY[1] + mouseOffset[1]];
    }
  },
  getMouseOffset: function getMouseOffset() {
    var offset = this.anchor ? [0, 0] : [15, 18];

    if (this.mouseOffset) {
      offset[0] += this.mouseOffset[0];
      offset[1] += this.mouseOffset[1];
    }

    return offset;
  },
  // private
  getAnchorPosition: function getAnchorPosition() {
    if (this.anchor) {
      this.tipAnchor = this.anchor.charAt(0);
    } else {
      var m = this.defaultAlign.match(/^([a-z]+)-([a-z]+)(\?)?$/);

      if (!m) {
        throw 'AnchorTip.defaultAlign is invalid';
      }

      this.tipAnchor = m[1].charAt(0);
    }

    switch (this.tipAnchor) {
      case 't':
        return 'top';

      case 'b':
        return 'bottom';

      case 'r':
        return 'right';
    }

    return 'left';
  },
  // private
  getAnchorAlign: function getAnchorAlign() {
    switch (this.anchor) {
      case 'top':
        return 'tl-bl';

      case 'left':
        return 'tl-tr';

      case 'right':
        return 'tr-tl';

      default:
        return 'bl-tl';
    }
  },
  // private
  getOffsets: function getOffsets() {
    var offsets,
        ap = this.getAnchorPosition().charAt(0);

    if (this.anchorToTarget && !this.trackMouse) {
      switch (ap) {
        case 't':
          offsets = [0, 9];
          break;

        case 'b':
          offsets = [0, -13];
          break;

        case 'r':
          offsets = [-13, 0];
          break;

        default:
          offsets = [9, 0];
          break;
      }
    } else {
      switch (ap) {
        case 't':
          offsets = [-15 - this.anchorOffset, 30];
          break;

        case 'b':
          offsets = [-19 - this.anchorOffset, -13 - this.el.dom.offsetHeight];
          break;

        case 'r':
          offsets = [-15 - this.el.dom.offsetWidth, -13 - this.anchorOffset];
          break;

        default:
          offsets = [25, -13 - this.anchorOffset];
          break;
      }
    }

    var mouseOffset = this.getMouseOffset();
    offsets[0] += mouseOffset[0];
    offsets[1] += mouseOffset[1];
    return offsets;
  },
  // private
  onTargetOver: function onTargetOver(e) {
    if (this.disabled || e.within(this.target.dom, true)) {
      return;
    }

    var t = e.getTarget(this.delegate);

    if (t) {
      this.triggerElement = t;
      this.clearTimer('hide');
      this.targetXY = e.getXY();
      this.delayShow();
    }
  },
  // private
  delayShow: function delayShow() {
    if (this.hidden && !this.showTimer) {
      if (this.lastActive.getElapsed() < this.quickShowInterval) {
        this.show();
      } else {
        this.showTimer = this.show.defer(this.showDelay, this);
      }
    } else if (!this.hidden && this.autoHide !== false) {
      this.show();
    }
  },
  // private
  onTargetOut: function onTargetOut(e) {
    if (this.disabled || e.within(this.target.dom, true)) {
      return;
    }

    this.clearTimer('show');

    if (this.autoHide !== false) {
      this.delayHide();
    }
  },
  // private
  delayHide: function delayHide() {
    if (!this.hidden && !this.hideTimer) {
      this.hideTimer = this.hide.defer(this.hideDelay, this);
    }
  },

  /**
   * Hides this tooltip if visible.
   */
  hide: function hide() {
    this.clearTimer('dismiss');
    this.lastActive = new Date();

    if (this.anchorEl) {
      this.anchorEl.hide();
    }

    Ext.ToolTip.superclass.hide.call(this);
    delete this.triggerElement;
  },

  /**
   * Shows this tooltip at the current event target XY position.
   */
  show: function show() {
    if (this.anchor) {
      // pre-show it off screen so that the el will have dimensions
      // for positioning calcs when getting xy next
      this.showAt([-1000, -1000]);
      this.origConstrainPosition = this.constrainPosition;
      this.constrainPosition = false;
      this.anchor = this.origAnchor;
    }

    this.showAt(this.getTargetXY());

    if (this.anchor) {
      this.syncAnchor();
      this.anchorEl.show();
      this.constrainPosition = this.origConstrainPosition;
    } else {
      this.anchorEl.hide();
    }
  },
  // inherit docs
  showAt: function showAt(xy) {
    this.lastActive = new Date();
    this.clearTimers();
    Ext.ToolTip.superclass.showAt.call(this, xy);

    if (this.dismissDelay && this.autoHide !== false) {
      this.dismissTimer = this.hide.defer(this.dismissDelay, this);
    }

    if (this.anchor && !this.anchorEl.isVisible()) {
      this.syncAnchor();
      this.anchorEl.show();
    }
  },
  // private
  syncAnchor: function syncAnchor() {
    var anchorPos, targetPos, offset;

    switch (this.tipAnchor.charAt(0)) {
      case 't':
        anchorPos = 'b';
        targetPos = 'tl';
        offset = [20 + this.anchorOffset, 2];
        break;

      case 'r':
        anchorPos = 'l';
        targetPos = 'tr';
        offset = [-2, 11 + this.anchorOffset];
        break;

      case 'b':
        anchorPos = 't';
        targetPos = 'bl';
        offset = [20 + this.anchorOffset, -2];
        break;

      default:
        anchorPos = 'r';
        targetPos = 'tl';
        offset = [2, 11 + this.anchorOffset];
        break;
    }

    this.anchorEl.alignTo(this.el, anchorPos + '-' + targetPos, offset);
  },
  // private
  setPagePosition: function setPagePosition(x, y) {
    Ext.ToolTip.superclass.setPagePosition.call(this, x, y);

    if (this.anchor) {
      this.syncAnchor();
    }
  },
  // private
  clearTimer: function clearTimer(name) {
    name = name + 'Timer';
    clearTimeout(this[name]);
    delete this[name];
  },
  // private
  clearTimers: function clearTimers() {
    this.clearTimer('show');
    this.clearTimer('dismiss');
    this.clearTimer('hide');
  },
  // private
  onShow: function onShow() {
    Ext.ToolTip.superclass.onShow.call(this);
    Ext.getDoc().on('mousedown', this.onDocMouseDown, this);
  },
  // private
  onHide: function onHide() {
    Ext.ToolTip.superclass.onHide.call(this);
    Ext.getDoc().un('mousedown', this.onDocMouseDown, this);
  },
  // private
  onDocMouseDown: function onDocMouseDown(e) {
    if (this.autoHide !== true && !this.closable && !e.within(this.el.dom)) {
      this.disable();
      this.enable.defer(100, this);
    }
  },
  // private
  onDisable: function onDisable() {
    this.clearTimers();
    this.hide();
  },
  // private
  adjustPosition: function adjustPosition(x, y) {
    if (this.contstrainPosition) {
      var ay = this.targetXY[1],
          h = this.getSize().height;

      if (y <= ay && y + h >= ay) {
        y = ay - h - 5;
      }
    }

    return {
      x: x,
      y: y
    };
  },
  beforeDestroy: function beforeDestroy() {
    this.clearTimers();
    Ext.destroy(this.anchorEl);
    delete this.anchorEl;
    delete this.target;
    delete this.anchorTarget;
    delete this.triggerElement;
    Ext.ToolTip.superclass.beforeDestroy.call(this);
  },
  // private
  onDestroy: function onDestroy() {
    Ext.getDoc().un('mousedown', this.onDocMouseDown, this);
    Ext.ToolTip.superclass.onDestroy.call(this);
  }
});
Ext.reg('tooltip', Ext.ToolTip);

/***/ }),
/* 845 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.QuickTip
 * @extends Ext.ToolTip
 * @xtype quicktip
 * A specialized tooltip class for tooltips that can be specified in markup and automatically managed by the global
 * {@link Ext.QuickTips} instance.  See the QuickTips class header for additional usage details and examples.
 * @constructor
 * Create a new Tip
 * @param {Object} config The configuration options
 */
Ext.QuickTip = Ext.extend(Ext.ToolTip, {
  /**
   * @cfg {Mixed} target The target HTMLElement, Ext.Element or id to associate with this quicktip (defaults to the document).
   */

  /**
   * @cfg {Boolean} interceptTitles True to automatically use the element's DOM title value if available (defaults to false).
   */
  interceptTitles: false,
  // private
  tagConfig: {
    namespace: "ext",
    attribute: "qtip",
    width: "qwidth",
    target: "target",
    title: "qtitle",
    hide: "hide",
    cls: "qclass",
    align: "qalign",
    anchor: "anchor"
  },
  // private
  initComponent: function initComponent() {
    this.target = this.target || Ext.getDoc();
    this.targets = this.targets || {};
    Ext.QuickTip.superclass.initComponent.call(this);
  },

  /**
   * Configures a new quick tip instance and assigns it to a target element.  The following config values are
   * supported (for example usage, see the {@link Ext.QuickTips} class header):
   * <div class="mdetail-params"><ul>
   * <li>autoHide</li>
   * <li>cls</li>
   * <li>dismissDelay (overrides the singleton value)</li>
   * <li>target (required)</li>
   * <li>text (required)</li>
   * <li>title</li>
   * <li>width</li></ul></div>
   * @param {Object} config The config object
   */
  register: function register(config) {
    var cs = Ext.isArray(config) ? config : arguments;

    for (var i = 0, len = cs.length; i < len; i++) {
      var c = cs[i];
      var target = c.target;

      if (target) {
        if (Ext.isArray(target)) {
          for (var j = 0, jlen = target.length; j < jlen; j++) {
            this.targets[Ext.id(target[j])] = c;
          }
        } else {
          this.targets[Ext.id(target)] = c;
        }
      }
    }
  },

  /**
   * Removes this quick tip from its element and destroys it.
   * @param {String/HTMLElement/Element} el The element from which the quick tip is to be removed.
   */
  unregister: function unregister(el) {
    delete this.targets[Ext.id(el)];
  },

  /**
   * Hides a visible tip or cancels an impending show for a particular element.
   * @param {String/HTMLElement/Element} el The element that is the target of the tip.
   */
  cancelShow: function cancelShow(el) {
    var at = this.activeTarget;
    el = Ext.get(el).dom;

    if (this.isVisible()) {
      if (at && at.el == el) {
        this.hide();
      }
    } else if (at && at.el == el) {
      this.clearTimer('show');
    }
  },
  getTipCfg: function getTipCfg(e) {
    var t = e.getTarget(),
        ttp,
        cfg;

    if (this.interceptTitles && t.title && Ext.isString(t.title)) {
      ttp = t.title;
      t.qtip = ttp;
      t.removeAttribute("title");
      e.preventDefault();
    } else {
      cfg = this.tagConfig;
      ttp = t.qtip || Ext.fly(t).getAttribute(cfg.attribute, cfg.namespace);
    }

    return ttp;
  },
  // private
  onTargetOver: function onTargetOver(e) {
    if (this.disabled) {
      return;
    }

    this.targetXY = e.getXY();
    var t = e.getTarget();

    if (!t || t.nodeType !== 1 || t == document || t == document.body) {
      return;
    }

    if (this.activeTarget && (t == this.activeTarget.el || Ext.fly(this.activeTarget.el).contains(t))) {
      this.clearTimer('hide');
      this.show();
      return;
    }

    if (t && this.targets[t.id]) {
      this.activeTarget = this.targets[t.id];
      this.activeTarget.el = t;
      this.anchor = this.activeTarget.anchor;

      if (this.anchor) {
        this.anchorTarget = t;
      }

      this.delayShow();
      return;
    }

    var ttp,
        et = Ext.fly(t),
        cfg = this.tagConfig,
        ns = cfg.namespace;

    if (ttp = this.getTipCfg(e)) {
      var autoHide = et.getAttribute(cfg.hide, ns);
      this.activeTarget = {
        el: t,
        text: ttp,
        width: et.getAttribute(cfg.width, ns),
        autoHide: autoHide != "user" && autoHide !== 'false',
        title: et.getAttribute(cfg.title, ns),
        cls: et.getAttribute(cfg.cls, ns),
        align: et.getAttribute(cfg.align, ns)
      };
      this.anchor = et.getAttribute(cfg.anchor, ns);

      if (this.anchor) {
        this.anchorTarget = t;
      }

      this.delayShow();
    }
  },
  // private
  onTargetOut: function onTargetOut(e) {
    // If moving within the current target, and it does not have a new tip, ignore the mouseout
    if (this.activeTarget && e.within(this.activeTarget.el) && !this.getTipCfg(e)) {
      return;
    }

    this.clearTimer('show');

    if (this.autoHide !== false) {
      this.delayHide();
    }
  },
  // inherit docs
  showAt: function showAt(xy) {
    var t = this.activeTarget;

    if (t) {
      if (!this.rendered) {
        this.render(Ext.getBody());
        this.activeTarget = t;
      }

      if (t.width) {
        this.setWidth(t.width);
        this.body.setWidth(this.adjustBodyWidth(t.width - this.getFrameWidth()));
        this.measureWidth = false;
      } else {
        this.measureWidth = true;
      }

      this.setTitle(t.title || '');
      this.body.update(t.text);
      this.autoHide = t.autoHide;
      this.dismissDelay = t.dismissDelay || this.dismissDelay;

      if (this.lastCls) {
        this.el.removeClass(this.lastCls);
        delete this.lastCls;
      }

      if (t.cls) {
        this.el.addClass(t.cls);
        this.lastCls = t.cls;
      }

      if (this.anchor) {
        this.constrainPosition = false;
      } else if (t.align) {
        // TODO: this doesn't seem to work consistently
        xy = this.el.getAlignToXY(t.el, t.align);
        this.constrainPosition = false;
      } else {
        this.constrainPosition = true;
      }
    }

    Ext.QuickTip.superclass.showAt.call(this, xy);
  },
  // inherit docs
  hide: function hide() {
    delete this.activeTarget;
    Ext.QuickTip.superclass.hide.call(this);
  }
});
Ext.reg('quicktip', Ext.QuickTip);

/***/ }),
/* 846 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.QuickTips
 * <p>Provides attractive and customizable tooltips for any element. The QuickTips
 * singleton is used to configure and manage tooltips globally for multiple elements
 * in a generic manner.  To create individual tooltips with maximum customizability,
 * you should consider either {@link Ext.Tip} or {@link Ext.ToolTip}.</p>
 * <p>Quicktips can be configured via tag attributes directly in markup, or by
 * registering quick tips programmatically via the {@link #register} method.</p>
 * <p>The singleton's instance of {@link Ext.QuickTip} is available via
 * {@link #getQuickTip}, and supports all the methods, and all the all the
 * configuration properties of Ext.QuickTip. These settings will apply to all
 * tooltips shown by the singleton.</p>
 * <p>Below is the summary of the configuration properties which can be used.
 * For detailed descriptions see {@link #getQuickTip}</p>
 * <p><b>QuickTips singleton configs (all are optional)</b></p>
 * <div class="mdetail-params"><ul><li>dismissDelay</li>
 * <li>hideDelay</li>
 * <li>maxWidth</li>
 * <li>minWidth</li>
 * <li>showDelay</li>
 * <li>trackMouse</li></ul></div>
 * <p><b>Target element configs (optional unless otherwise noted)</b></p>
 * <div class="mdetail-params"><ul><li>autoHide</li>
 * <li>cls</li>
 * <li>dismissDelay (overrides singleton value)</li>
 * <li>target (required)</li>
 * <li>text (required)</li>
 * <li>title</li>
 * <li>width</li></ul></div>
 * <p>Here is an example showing how some of these config options could be used:</p>
 * <pre><code>
// Init the singleton.  Any tag-based quick tips will start working.
Ext.QuickTips.init();

// Apply a set of config properties to the singleton
Ext.apply(Ext.QuickTips.getQuickTip(), {
    maxWidth: 200,
    minWidth: 100,
    showDelay: 50,
    trackMouse: true
});

// Manually register a quick tip for a specific element
Ext.QuickTips.register({
    target: 'my-div',
    title: 'My Tooltip',
    text: 'This tooltip was added in code',
    width: 100,
    dismissDelay: 20
});
</code></pre>
 * <p>To register a quick tip in markup, you simply add one or more of the valid QuickTip attributes prefixed with
 * the <b>ext:</b> namespace.  The HTML element itself is automatically set as the quick tip target. Here is the summary
 * of supported attributes (optional unless otherwise noted):</p>
 * <ul><li><b>hide</b>: Specifying "user" is equivalent to setting autoHide = false.  Any other value will be the
 * same as autoHide = true.</li>
 * <li><b>qclass</b>: A CSS class to be applied to the quick tip (equivalent to the 'cls' target element config).</li>
 * <li><b>qtip (required)</b>: The quick tip text (equivalent to the 'text' target element config).</li>
 * <li><b>qtitle</b>: The quick tip title (equivalent to the 'title' target element config).</li>
 * <li><b>qwidth</b>: The quick tip width (equivalent to the 'width' target element config).</li></ul>
 * <p>Here is an example of configuring an HTML element to display a tooltip from markup:</p>
 * <pre><code>
// Add a quick tip to an HTML button
&lt;input type="button" value="OK" ext:qtitle="OK Button" ext:qwidth="100"
     ext:qtip="This is a quick tip from markup!">&lt;/input>
</code></pre>
 * @singleton
 */
Ext.QuickTips = function () {
  var tip,
      locks = [];
  return {
    /**
     * Initialize the global QuickTips instance and prepare any quick tips.
     * @param {Boolean} autoRender True to render the QuickTips container immediately to preload images. (Defaults to true) 
     */
    init: function init(autoRender) {
      if (!tip) {
        if (!Ext.isReady) {
          Ext.onReady(function () {
            Ext.QuickTips.init(autoRender);
          });
          return;
        }

        tip = new Ext.QuickTip({
          elements: 'header,body'
        });

        if (autoRender !== false) {
          tip.render(Ext.getBody());
        }
      }
    },

    /**
     * Enable quick tips globally.
     */
    enable: function enable() {
      if (tip) {
        locks.pop();

        if (locks.length < 1) {
          tip.enable();
        }
      }
    },

    /**
     * Disable quick tips globally.
     */
    disable: function disable() {
      if (tip) {
        tip.disable();
      }

      locks.push(1);
    },

    /**
     * Returns true if quick tips are enabled, else false.
     * @return {Boolean}
     */
    isEnabled: function isEnabled() {
      return tip !== undefined && !tip.disabled;
    },

    /**
     * Gets the global QuickTips instance.
     */
    getQuickTip: function getQuickTip() {
      return tip;
    },

    /**
     * Configures a new quick tip instance and assigns it to a target element.  See
     * {@link Ext.QuickTip#register} for details.
     * @param {Object} config The config object
     */
    register: function register() {
      tip.register.apply(tip, arguments);
    },

    /**
     * Removes any registered quick tip from the target element and destroys it.
     * @param {String/HTMLElement/Element} el The element from which the quick tip is to be removed.
     */
    unregister: function unregister() {
      tip.unregister.apply(tip, arguments);
    },

    /**
     * Alias of {@link #register}.
     * @param {Object} config The config object
     */
    tips: function tips() {
      tip.register.apply(tip, arguments);
    }
  };
}();

/***/ }),
/* 847 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreePanel
 * @extends Ext.Panel
 * <p>The TreePanel provides tree-structured UI representation of tree-structured data.</p>
 * <p>{@link Ext.tree.TreeNode TreeNode}s added to the TreePanel may each contain metadata
 * used by your application in their {@link Ext.tree.TreeNode#attributes attributes} property.</p>
 * <p><b>A TreePanel must have a {@link #root} node before it is rendered.</b> This may either be
 * specified using the {@link #root} config option, or using the {@link #setRootNode} method.
 * <p>An example of tree rendered to an existing div:</p><pre><code>
var tree = new Ext.tree.TreePanel({
    renderTo: 'tree-div',
    useArrows: true,
    autoScroll: true,
    animate: true,
    enableDD: true,
    containerScroll: true,
    border: false,
    // auto create TreeLoader
    dataUrl: 'get-nodes.php',

    root: {
        nodeType: 'async',
        text: 'Ext JS',
        draggable: false,
        id: 'source'
    }
});

tree.getRootNode().expand();
 * </code></pre>
 * <p>The example above would work with a data packet similar to this:</p><pre><code>
[{
    "text": "adapter",
    "id": "source\/adapter",
    "cls": "folder"
}, {
    "text": "dd",
    "id": "source\/dd",
    "cls": "folder"
}, {
    "text": "debug.js",
    "id": "source\/debug.js",
    "leaf": true,
    "cls": "file"
}]
 * </code></pre>
 * <p>An example of tree within a Viewport:</p><pre><code>
new Ext.Viewport({
    layout: 'border',
    items: [{
        region: 'west',
        collapsible: true,
        title: 'Navigation',
        xtype: 'treepanel',
        width: 200,
        autoScroll: true,
        split: true,
        loader: new Ext.tree.TreeLoader(),
        root: new Ext.tree.AsyncTreeNode({
            expanded: true,
            children: [{
                text: 'Menu Option 1',
                leaf: true
            }, {
                text: 'Menu Option 2',
                leaf: true
            }, {
                text: 'Menu Option 3',
                leaf: true
            }]
        }),
        rootVisible: false,
        listeners: {
            click: function(n) {
                Ext.Msg.alert('Navigation Tree Click', 'You clicked: "' + n.attributes.text + '"');
            }
        }
    }, {
        region: 'center',
        xtype: 'tabpanel',
        // remaining code not shown ...
    }]
});
</code></pre>
 *
 * @cfg {Ext.tree.TreeNode} root The root node for the tree.
 * @cfg {Boolean} rootVisible <tt>false</tt> to hide the root node (defaults to <tt>true</tt>)
 * @cfg {Boolean} lines <tt>false</tt> to disable tree lines (defaults to <tt>true</tt>)
 * @cfg {Boolean} enableDD <tt>true</tt> to enable drag and drop
 * @cfg {Boolean} enableDrag <tt>true</tt> to enable just drag
 * @cfg {Boolean} enableDrop <tt>true</tt> to enable just drop
 * @cfg {Object} dragConfig Custom config to pass to the {@link Ext.tree.TreeDragZone} instance
 * @cfg {Object} dropConfig Custom config to pass to the {@link Ext.tree.TreeDropZone} instance
 * @cfg {String} ddGroup The DD group this TreePanel belongs to
 * @cfg {Boolean} ddAppendOnly <tt>true</tt> if the tree should only allow append drops (use for trees which are sorted)
 * @cfg {Boolean} ddScroll <tt>true</tt> to enable body scrolling
 * @cfg {Boolean} containerScroll <tt>true</tt> to register this container with ScrollManager
 * @cfg {Boolean} hlDrop <tt>false</tt> to disable node highlight on drop (defaults to the value of {@link Ext#enableFx})
 * @cfg {String} hlColor The color of the node highlight (defaults to <tt>'C3DAF9'</tt>)
 * @cfg {Boolean} animate <tt>true</tt> to enable animated expand/collapse (defaults to the value of {@link Ext#enableFx})
 * @cfg {Boolean} singleExpand <tt>true</tt> if only 1 node per branch may be expanded
 * @cfg {Object} selModel A tree selection model to use with this TreePanel (defaults to an {@link Ext.tree.DefaultSelectionModel})
 * @cfg {Boolean} trackMouseOver <tt>false</tt> to disable mouse over highlighting
 * @cfg {Ext.tree.TreeLoader} loader A {@link Ext.tree.TreeLoader} for use with this TreePanel
 * @cfg {String} pathSeparator The token used to separate sub-paths in path strings (defaults to <tt>'/'</tt>)
 * @cfg {Boolean} useArrows <tt>true</tt> to use Vista-style arrows in the tree (defaults to <tt>false</tt>)
 * @cfg {String} requestMethod The HTTP request method for loading data (defaults to the value of {@link Ext.Ajax#method}).
 *
 * @constructor
 * @param {Object} config
 * @xtype treepanel
 */
Ext.tree.TreePanel = Ext.extend(Ext.Panel, {
  rootVisible: true,
  animate: Ext.enableFx,
  lines: false,
  enableDD: false,
  hlDrop: Ext.enableFx,
  pathSeparator: '/',
  useArrows: true,

  /**
   * @cfg {Array} bubbleEvents
   * <p>An array of events that, when fired, should be bubbled to any parent container.
   * See {@link Ext.util.Observable#enableBubble}.
   * Defaults to <tt>[]</tt>.
   */
  bubbleEvents: [],
  initComponent: function initComponent() {
    Ext.tree.TreePanel.superclass.initComponent.call(this);

    if (!this.eventModel) {
      this.eventModel = new Ext.tree.TreeEventModel(this);
    } // initialize the loader


    var l = this.loader;

    if (!l) {
      l = new Ext.tree.TreeLoader({
        dataUrl: this.dataUrl,
        requestMethod: this.requestMethod
      });
    } else if (Ext.isObject(l) && !l.load) {
      l = new Ext.tree.TreeLoader(l);
    }

    this.loader = l;
    this.nodeHash = {};
    /**
    * The root node of this tree.
    * @type Ext.tree.TreeNode
    * @property root
    */

    if (this.root) {
      var r = this.root;
      delete this.root;
      this.setRootNode(r);
    }

    this.addEvents(
    /**
    * @event append
    * Fires when a new child node is appended to a node in this tree.
    * @param {Tree} tree The owner tree
    * @param {Node} parent The parent node
    * @param {Node} node The newly appended node
    * @param {Number} index The index of the newly appended node
    */
    'append',
    /**
     * @event remove
     * Fires when a child node is removed from a node in this tree.
     * @param {Tree} tree The owner tree
     * @param {Node} parent The parent node
     * @param {Node} node The child node removed
     */
    'remove',
    /**
     * @event movenode
     * Fires when a node is moved to a new location in the tree
     * @param {Tree} tree The owner tree
     * @param {Node} node The node moved
     * @param {Node} oldParent The old parent of this node
     * @param {Node} newParent The new parent of this node
     * @param {Number} index The index it was moved to
     */
    'movenode',
    /**
     * @event insert
     * Fires when a new child node is inserted in a node in this tree.
     * @param {Tree} tree The owner tree
     * @param {Node} parent The parent node
     * @param {Node} node The child node inserted
     * @param {Node} refNode The child node the node was inserted before
     */
    'insert',
    /**
     * @event beforeappend
     * Fires before a new child is appended to a node in this tree, return false to cancel the append.
     * @param {Tree} tree The owner tree
     * @param {Node} parent The parent node
     * @param {Node} node The child node to be appended
     */
    'beforeappend',
    /**
     * @event beforeremove
     * Fires before a child is removed from a node in this tree, return false to cancel the remove.
     * @param {Tree} tree The owner tree
     * @param {Node} parent The parent node
     * @param {Node} node The child node to be removed
     */
    'beforeremove',
    /**
     * @event beforemovenode
     * Fires before a node is moved to a new location in the tree. Return false to cancel the move.
     * @param {Tree} tree The owner tree
     * @param {Node} node The node being moved
     * @param {Node} oldParent The parent of the node
     * @param {Node} newParent The new parent the node is moving to
     * @param {Number} index The index it is being moved to
     */
    'beforemovenode',
    /**
     * @event beforeinsert
     * Fires before a new child is inserted in a node in this tree, return false to cancel the insert.
     * @param {Tree} tree The owner tree
     * @param {Node} parent The parent node
     * @param {Node} node The child node to be inserted
     * @param {Node} refNode The child node the node is being inserted before
     */
    'beforeinsert',
    /**
    * @event beforeload
    * Fires before a node is loaded, return false to cancel
    * @param {Node} node The node being loaded
    */
    'beforeload',
    /**
    * @event load
    * Fires when a node is loaded
    * @param {Node} node The node that was loaded
    */
    'load',
    /**
    * @event textchange
    * Fires when the text for a node is changed
    * @param {Node} node The node
    * @param {String} text The new text
    * @param {String} oldText The old text
    */
    'textchange',
    /**
    * @event beforeexpandnode
    * Fires before a node is expanded, return false to cancel.
    * @param {Node} node The node
    * @param {Boolean} deep
    * @param {Boolean} anim
    */
    'beforeexpandnode',
    /**
    * @event beforecollapsenode
    * Fires before a node is collapsed, return false to cancel.
    * @param {Node} node The node
    * @param {Boolean} deep
    * @param {Boolean} anim
    */
    'beforecollapsenode',
    /**
    * @event expandnode
    * Fires when a node is expanded
    * @param {Node} node The node
    */
    'expandnode',
    /**
    * @event disabledchange
    * Fires when the disabled status of a node changes
    * @param {Node} node The node
    * @param {Boolean} disabled
    */
    'disabledchange',
    /**
    * @event collapsenode
    * Fires when a node is collapsed
    * @param {Node} node The node
    */
    'collapsenode',
    /**
    * @event beforeclick
    * Fires before click processing on a node. Return false to cancel the default action.
    * @param {Node} node The node
    * @param {Ext.EventObject} e The event object
    */
    'beforeclick',
    /**
    * @event click
    * Fires when a node is clicked
    * @param {Node} node The node
    * @param {Ext.EventObject} e The event object
    */
    'click',
    /**
    * @event containerclick
    * Fires when the tree container is clicked
    * @param {Tree} this
    * @param {Ext.EventObject} e The event object
    */
    'containerclick',
    /**
    * @event checkchange
    * Fires when a node with a checkbox's checked property changes
    * @param {Node} this This node
    * @param {Boolean} checked
    */
    'checkchange',
    /**
    * @event beforedblclick
    * Fires before double click processing on a node. Return false to cancel the default action.
    * @param {Node} node The node
    * @param {Ext.EventObject} e The event object
    */
    'beforedblclick',
    /**
    * @event dblclick
    * Fires when a node is double clicked
    * @param {Node} node The node
    * @param {Ext.EventObject} e The event object
    */
    'dblclick',
    /**
    * @event containerdblclick
    * Fires when the tree container is double clicked
    * @param {Tree} this
    * @param {Ext.EventObject} e The event object
    */
    'containerdblclick',
    /**
    * @event contextmenu
    * Fires when a node is right clicked. To display a context menu in response to this
    * event, first create a Menu object (see {@link Ext.menu.Menu} for details), then add
    * a handler for this event:<pre><code>
    new Ext.tree.TreePanel({
    title: 'My TreePanel',
    root: new Ext.tree.AsyncTreeNode({
    text: 'The Root',
    children: [
    { text: 'Child node 1', leaf: true },
    { text: 'Child node 2', leaf: true }
    ]
    }),
    contextMenu: new Ext.menu.Menu({
    items: [{
    id: 'delete-node',
    text: 'Delete Node'
    }],
    listeners: {
    itemclick: function(item) {
        switch (item.id) {
            case 'delete-node':
                var n = item.parentMenu.contextNode;
                if (n.parentNode) {
                    n.remove();
                }
                break;
        }
    }
    }
    }),
    listeners: {
    contextmenu: function(node, e) {
    //          Register the context node with the menu so that a Menu Item's handler function can access
    //          it via its {@link Ext.menu.BaseItem#parentMenu parentMenu} property.
    node.select();
    var c = node.getOwnerTree().contextMenu;
    c.contextNode = node;
    c.showAt(e.getXY());
    }
    }
    });
    </code></pre>
    * @param {Node} node The node
    * @param {Ext.EventObject} e The event object
    */
    'contextmenu',
    /**
    * @event containercontextmenu
    * Fires when the tree container is right clicked
    * @param {Tree} this
    * @param {Ext.EventObject} e The event object
    */
    'containercontextmenu',
    /**
    * @event beforechildrenrendered
    * Fires right before the child nodes for a node are rendered
    * @param {Node} node The node
    */
    'beforechildrenrendered',
    /**
      * @event startdrag
      * Fires when a node starts being dragged
      * @param {Ext.tree.TreePanel} this
      * @param {Ext.tree.TreeNode} node
      * @param {event} e The raw browser event
      */
    'startdrag',
    /**
     * @event enddrag
     * Fires when a drag operation is complete
     * @param {Ext.tree.TreePanel} this
     * @param {Ext.tree.TreeNode} node
     * @param {event} e The raw browser event
     */
    'enddrag',
    /**
     * @event dragdrop
     * Fires when a dragged node is dropped on a valid DD target
     * @param {Ext.tree.TreePanel} this
     * @param {Ext.tree.TreeNode} node
     * @param {DD} dd The dd it was dropped on
     * @param {event} e The raw browser event
     */
    'dragdrop',
    /**
     * @event beforenodedrop
     * Fires when a DD object is dropped on a node in this tree for preprocessing. Return false to cancel the drop. The dropEvent
     * passed to handlers has the following properties:<br />
     * <ul style="padding:5px;padding-left:16px;">
     * <li>tree - The TreePanel</li>
     * <li>target - The node being targeted for the drop</li>
     * <li>data - The drag data from the drag source</li>
     * <li>point - The point of the drop - append, above or below</li>
     * <li>source - The drag source</li>
     * <li>rawEvent - Raw mouse event</li>
     * <li>dropNode - Drop node(s) provided by the source <b>OR</b> you can supply node(s)
     * to be inserted by setting them on this object.</li>
     * <li>cancel - Set this to true to cancel the drop.</li>
     * <li>dropStatus - If the default drop action is cancelled but the drop is valid, setting this to true
     * will prevent the animated 'repair' from appearing.</li>
     * </ul>
     * @param {Object} dropEvent
     */
    'beforenodedrop',
    /**
     * @event nodedrop
     * Fires after a DD object is dropped on a node in this tree. The dropEvent
     * passed to handlers has the following properties:<br />
     * <ul style="padding:5px;padding-left:16px;">
     * <li>tree - The TreePanel</li>
     * <li>target - The node being targeted for the drop</li>
     * <li>data - The drag data from the drag source</li>
     * <li>point - The point of the drop - append, above or below</li>
     * <li>source - The drag source</li>
     * <li>rawEvent - Raw mouse event</li>
     * <li>dropNode - Dropped node(s).</li>
     * </ul>
     * @param {Object} dropEvent
     */
    'nodedrop',
    /**
    * @event nodedragover
    * Fires when a tree node is being targeted for a drag drop, return false to signal drop not allowed. The dragOverEvent
    * passed to handlers has the following properties:<br />
    * <ul style="padding:5px;padding-left:16px;">
    * <li>tree - The TreePanel</li>
    * <li>target - The node being targeted for the drop</li>
    * <li>data - The drag data from the drag source</li>
    * <li>point - The point of the drop - append, above or below</li>
    * <li>source - The drag source</li>
    * <li>rawEvent - Raw mouse event</li>
    * <li>dropNode - Drop node(s) provided by the source.</li>
    * <li>cancel - Set this to true to signal drop not allowed.</li>
    * </ul>
    * @param {Object} dragOverEvent
    */
    'nodedragover');

    if (this.singleExpand) {
      this.on('beforeexpandnode', this.restrictExpand, this);
    }
  },
  // private
  proxyNodeEvent: function proxyNodeEvent(ename, a1, a2, a3, a4, a5, a6) {
    if (ename == 'collapse' || ename == 'expand' || ename == 'beforecollapse' || ename == 'beforeexpand' || ename == 'move' || ename == 'beforemove') {
      ename = ename + 'node';
    } // args inline for performance while bubbling events


    return this.fireEvent(ename, a1, a2, a3, a4, a5, a6);
  },

  /**
   * Returns this root node for this tree
   * @return {Node}
   */
  getRootNode: function getRootNode() {
    return this.root;
  },

  /**
   * Sets the root node for this tree. If the TreePanel has already rendered a root node, the
   * previous root node (and all of its descendants) are destroyed before the new root node is rendered.
   * @param {Node} node
   * @return {Node}
   */
  setRootNode: function setRootNode(node) {
    Ext.destroy(this.root);

    if (!node.render) {
      // attributes passed
      node = this.loader.createNode(node);
    }

    this.root = node;
    node.ownerTree = this;
    node.isRoot = true;
    this.registerNode(node);

    if (!this.rootVisible) {
      var uiP = node.attributes.uiProvider;
      node.ui = uiP ? new uiP(node) : new Ext.tree.RootTreeNodeUI(node);
    }

    if (this.innerCt) {
      this.clearInnerCt();
      this.renderRoot();
    }

    return node;
  },
  clearInnerCt: function clearInnerCt() {
    this.innerCt.update('');
  },
  // private
  renderRoot: function renderRoot() {
    this.root.render();

    if (!this.rootVisible) {
      this.root.renderChildren();
    }
  },

  /**
   * Gets a node in this tree by its id
   * @param {String} id
   * @return {Node}
   */
  getNodeById: function getNodeById(id) {
    return this.nodeHash[id];
  },
  // private
  registerNode: function registerNode(node) {
    this.nodeHash[node.id] = node;
  },
  // private
  unregisterNode: function unregisterNode(node) {
    delete this.nodeHash[node.id];
  },
  // private
  toString: function toString() {
    return '[Tree' + (this.id ? ' ' + this.id : '') + ']';
  },
  // private
  restrictExpand: function restrictExpand(node) {
    var p = node.parentNode;

    if (p) {
      if (p.expandedChild && p.expandedChild.parentNode == p) {
        p.expandedChild.collapse();
      }

      p.expandedChild = node;
    }
  },

  /**
   * Retrieve an array of checked nodes, or an array of a specific attribute of checked nodes (e.g. 'id')
   * @param {String} attribute (optional) Defaults to null (return the actual nodes)
   * @param {TreeNode} startNode (optional) The node to start from, defaults to the root
   * @return {Array}
   */
  getChecked: function getChecked(a, startNode) {
    startNode = startNode || this.root;
    var r = [];

    var f = function f() {
      if (this.attributes.checked) {
        r.push(!a ? this : a == 'id' ? this.id : this.attributes[a]);
      }
    };

    startNode.cascade(f);
    return r;
  },

  /**
   * Returns the default {@link Ext.tree.TreeLoader} for this TreePanel.
   * @return {Ext.tree.TreeLoader} The TreeLoader for this TreePanel.
   */
  getLoader: function getLoader() {
    return this.loader;
  },

  /**
   * Expand all nodes
   */
  expandAll: function expandAll() {
    this.root.expand(true);
  },

  /**
   * Collapse all nodes
   */
  collapseAll: function collapseAll() {
    this.root.collapse(true);
  },

  /**
   * Returns the selection model used by this TreePanel.
   * @return {TreeSelectionModel} The selection model used by this TreePanel
   */
  getSelectionModel: function getSelectionModel() {
    if (!this.selModel) {
      this.selModel = new Ext.tree.DefaultSelectionModel();
    }

    return this.selModel;
  },

  /**
   * Expands a specified path in this TreePanel. A path can be retrieved from a node with {@link Ext.data.Node#getPath}
   * @param {String} path
   * @param {String} attr (optional) The attribute used in the path (see {@link Ext.data.Node#getPath} for more info)
   * @param {Function} callback (optional) The callback to call when the expand is complete. The callback will be called with
   * (bSuccess, oLastNode) where bSuccess is if the expand was successful and oLastNode is the last node that was expanded.
   */
  expandPath: function expandPath(path, attr, callback) {
    attr = attr || 'id';
    var keys = path.split(this.pathSeparator);
    var curNode = this.root;

    if (curNode.attributes[attr] != keys[1]) {
      // invalid root
      if (callback) {
        callback(false, null);
      }

      return;
    }

    var index = 1;

    var f = function f() {
      if (++index == keys.length) {
        if (callback) {
          callback(true, curNode);
        }

        return;
      }

      var c = curNode.findChild(attr, keys[index]);

      if (!c) {
        if (callback) {
          callback(false, curNode);
        }

        return;
      }

      curNode = c;
      c.expand(false, false, f);
    };

    curNode.expand(false, false, f);
  },

  /**
   * Selects the node in this tree at the specified path. A path can be retrieved from a node with {@link Ext.data.Node#getPath}
   * @param {String} path
   * @param {String} attr (optional) The attribute used in the path (see {@link Ext.data.Node#getPath} for more info)
   * @param {Function} callback (optional) The callback to call when the selection is complete. The callback will be called with
   * (bSuccess, oSelNode) where bSuccess is if the selection was successful and oSelNode is the selected node.
   */
  selectPath: function selectPath(path, attr, callback) {
    attr = attr || 'id';
    var keys = path.split(this.pathSeparator),
        v = keys.pop();

    if (keys.length > 1) {
      var f = function f(success, node) {
        if (success && node) {
          var n = node.findChild(attr, v);

          if (n) {
            n.select();

            if (callback) {
              callback(true, n);
            }
          } else if (callback) {
            callback(false, n);
          }
        } else {
          if (callback) {
            callback(false, n);
          }
        }
      };

      this.expandPath(keys.join(this.pathSeparator), attr, f);
    } else {
      this.root.select();

      if (callback) {
        callback(true, this.root);
      }
    }
  },

  /**
   * Returns the underlying Element for this tree
   * @return {Ext.Element} The Element
   */
  getTreeEl: function getTreeEl() {
    return this.body;
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.tree.TreePanel.superclass.onRender.call(this, ct, position);
    this.el.addClass('x-tree');
    this.innerCt = this.body.createChild({
      tag: 'ul',
      cls: 'x-tree-root-ct ' + (this.useArrows ? 'x-tree-arrows' : this.lines ? 'x-tree-lines' : 'x-tree-no-lines')
    });
  },
  // private
  initEvents: function initEvents() {
    Ext.tree.TreePanel.superclass.initEvents.call(this);

    if (this.containerScroll) {
      Ext.dd.ScrollManager.register(this.body);
    }

    if ((this.enableDD || this.enableDrop) && !this.dropZone) {
      /**
       * The dropZone used by this tree if drop is enabled (see {@link #enableDD} or {@link #enableDrop})
       * @property dropZone
       * @type Ext.tree.TreeDropZone
       */
      this.dropZone = new Ext.tree.TreeDropZone(this, this.dropConfig || {
        ddGroup: this.ddGroup || 'TreeDD',
        appendOnly: this.ddAppendOnly === true
      });
    }

    if ((this.enableDD || this.enableDrag) && !this.dragZone) {
      /**
       * The dragZone used by this tree if drag is enabled (see {@link #enableDD} or {@link #enableDrag})
       * @property dragZone
       * @type Ext.tree.TreeDragZone
       */
      this.dragZone = new Ext.tree.TreeDragZone(this, this.dragConfig || {
        ddGroup: this.ddGroup || 'TreeDD',
        scroll: this.ddScroll
      });
    }

    this.getSelectionModel().init(this);
  },
  // private
  afterRender: function afterRender() {
    Ext.tree.TreePanel.superclass.afterRender.call(this);
    this.renderRoot();
  },
  beforeDestroy: function beforeDestroy() {
    if (this.rendered) {
      Ext.dd.ScrollManager.unregister(this.body);
      Ext.destroy(this.dropZone, this.dragZone);
    }

    Ext.destroy(this.root, this.loader);
    this.nodeHash = this.root = this.loader = null;
    Ext.tree.TreePanel.superclass.beforeDestroy.call(this);
  }
  /**
   * @cfg {String/Number} activeItem
   * @hide
   */

  /**
   * @cfg {Boolean} autoDestroy
   * @hide
   */

  /**
   * @cfg {Object/String/Function} autoLoad
   * @hide
   */

  /**
   * @cfg {Boolean} autoWidth
   * @hide
   */

  /**
   * @cfg {Boolean/Number} bufferResize
   * @hide
   */

  /**
   * @cfg {String} defaultType
   * @hide
   */

  /**
   * @cfg {Object} defaults
   * @hide
   */

  /**
   * @cfg {Boolean} hideBorders
   * @hide
   */

  /**
   * @cfg {Mixed} items
   * @hide
   */

  /**
   * @cfg {String} layout
   * @hide
   */

  /**
   * @cfg {Object} layoutConfig
   * @hide
   */

  /**
   * @cfg {Boolean} monitorResize
   * @hide
   */

  /**
   * @property items
   * @hide
   */

  /**
   * @method cascade
   * @hide
   */

  /**
   * @method doLayout
   * @hide
   */

  /**
   * @method find
   * @hide
   */

  /**
   * @method findBy
   * @hide
   */

  /**
   * @method findById
   * @hide
   */

  /**
   * @method findByType
   * @hide
   */

  /**
   * @method getComponent
   * @hide
   */

  /**
   * @method getLayout
   * @hide
   */

  /**
   * @method getUpdater
   * @hide
   */

  /**
   * @method insert
   * @hide
   */

  /**
   * @method load
   * @hide
   */

  /**
   * @method remove
   * @hide
   */

  /**
   * @event add
   * @hide
   */

  /**
   * @method removeAll
   * @hide
   */

  /**
   * @event afterLayout
   * @hide
   */

  /**
   * @event beforeadd
   * @hide
   */

  /**
   * @event beforeremove
   * @hide
   */

  /**
   * @event remove
   * @hide
   */

  /**
   * @cfg {String} allowDomMove  @hide
   */

  /**
   * @cfg {String} autoEl @hide
   */

  /**
   * @cfg {String} applyTo  @hide
   */

  /**
   * @cfg {String} contentEl  @hide
   */

  /**
   * @cfg {Mixed} data  @hide
   */

  /**
   * @cfg {Mixed} tpl  @hide
   */

  /**
   * @cfg {String} tplWriteMode  @hide
   */

  /**
   * @cfg {String} disabledClass  @hide
   */

  /**
   * @cfg {String} elements  @hide
   */

  /**
   * @cfg {String} html  @hide
   */

  /**
   * @cfg {Boolean} preventBodyReset
   * @hide
   */

  /**
   * @property disabled
   * @hide
   */

  /**
   * @method applyToMarkup
   * @hide
   */

  /**
   * @method enable
   * @hide
   */

  /**
   * @method disable
   * @hide
   */

  /**
   * @method setDisabled
   * @hide
   */

});
Ext.tree.TreePanel.nodeTypes = {};
Ext.reg('treepanel', Ext.tree.TreePanel);

/***/ }),
/* 848 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.tree.TreeEventModel = function (tree) {
  this.tree = tree;
  this.tree.on('render', this.initEvents, this);
};

Ext.tree.TreeEventModel.prototype = {
  initEvents: function initEvents() {
    var t = this.tree;

    if (t.trackMouseOver !== false) {
      t.mon(t.innerCt, {
        scope: this,
        mouseover: this.delegateOver,
        mouseout: this.delegateOut
      });
    }

    t.mon(t.getTreeEl(), {
      scope: this,
      click: this.delegateClick,
      dblclick: this.delegateDblClick,
      contextmenu: this.delegateContextMenu
    });
  },
  getNode: function getNode(e) {
    var t;

    if (t = e.getTarget('.x-tree-node-el', 10)) {
      var id = Ext.fly(t, '_treeEvents').getAttribute('tree-node-id', 'ext');

      if (id) {
        return this.tree.getNodeById(id);
      }
    }

    return null;
  },
  getNodeTarget: function getNodeTarget(e) {
    var t = e.getTarget('.x-tree-node-icon', 1);

    if (!t) {
      t = e.getTarget('.x-tree-node-el', 6);
    }

    return t;
  },
  delegateOut: function delegateOut(e, t) {
    if (!this.beforeEvent(e)) {
      return;
    }

    if (e.getTarget('.x-tree-ec-icon', 1)) {
      var n = this.getNode(e);
      this.onIconOut(e, n);

      if (n == this.lastEcOver) {
        delete this.lastEcOver;
      }
    }

    if ((t = this.getNodeTarget(e)) && !e.within(t, true)) {
      this.onNodeOut(e, this.getNode(e));
    }
  },
  delegateOver: function delegateOver(e, t) {
    if (!this.beforeEvent(e)) {
      return;
    }

    if (Ext.isGecko && !this.trackingDoc) {
      // prevent hanging in FF
      Ext.getBody().on('mouseover', this.trackExit, this);
      this.trackingDoc = true;
    }

    if (this.lastEcOver) {
      // prevent hung highlight
      this.onIconOut(e, this.lastEcOver);
      delete this.lastEcOver;
    }

    if (e.getTarget('.x-tree-ec-icon', 1)) {
      this.lastEcOver = this.getNode(e);
      this.onIconOver(e, this.lastEcOver);
    }

    if (t = this.getNodeTarget(e)) {
      this.onNodeOver(e, this.getNode(e));
    }
  },
  trackExit: function trackExit(e) {
    if (this.lastOverNode) {
      if (this.lastOverNode.ui && !e.within(this.lastOverNode.ui.getEl())) {
        this.onNodeOut(e, this.lastOverNode);
      }

      delete this.lastOverNode;
      Ext.getBody().un('mouseover', this.trackExit, this);
      this.trackingDoc = false;
    }
  },
  delegateClick: function delegateClick(e, t) {
    if (this.beforeEvent(e)) {
      if (e.getTarget('input[type=checkbox]', 1)) {
        this.onCheckboxClick(e, this.getNode(e));
      } else if (e.getTarget('.x-tree-ec-icon', 1)) {
        this.onIconClick(e, this.getNode(e));
      } else if (this.getNodeTarget(e)) {
        this.onNodeClick(e, this.getNode(e));
      } else {
        this.onContainerEvent(e, 'click');
      }
    }
  },
  delegateDblClick: function delegateDblClick(e, t) {
    if (this.beforeEvent(e)) {
      if (this.getNodeTarget(e)) {
        this.onNodeDblClick(e, this.getNode(e));
      } else {
        this.onContainerEvent(e, 'dblclick');
      }
    }
  },
  delegateContextMenu: function delegateContextMenu(e, t) {
    if (this.beforeEvent(e)) {
      if (this.getNodeTarget(e)) {
        this.onNodeContextMenu(e, this.getNode(e));
      } else {
        this.onContainerEvent(e, 'contextmenu');
      }
    }
  },
  onContainerEvent: function onContainerEvent(e, type) {
    this.tree.fireEvent('container' + type, this.tree, e);
  },
  onNodeClick: function onNodeClick(e, node) {
    node.ui.onClick(e);
  },
  onNodeOver: function onNodeOver(e, node) {
    this.lastOverNode = node;
    node.ui.onOver(e);
  },
  onNodeOut: function onNodeOut(e, node) {
    node.ui.onOut(e);
  },
  onIconOver: function onIconOver(e, node) {
    node.ui.addClass('x-tree-ec-over');
  },
  onIconOut: function onIconOut(e, node) {
    node.ui.removeClass('x-tree-ec-over');
  },
  onIconClick: function onIconClick(e, node) {
    node.ui.ecClick(e);
  },
  onCheckboxClick: function onCheckboxClick(e, node) {
    node.ui.onCheckChange(e);
  },
  onNodeDblClick: function onNodeDblClick(e, node) {
    node.ui.onDblClick(e);
  },
  onNodeContextMenu: function onNodeContextMenu(e, node) {
    node.ui.onContextMenu(e);
  },
  beforeEvent: function beforeEvent(e) {
    var node = this.getNode(e);

    if (this.disabled || !node || !node.ui) {
      e.stopEvent();
      return false;
    }

    return true;
  },
  disable: function disable() {
    this.disabled = true;
  },
  enable: function enable() {
    this.disabled = false;
  }
};

/***/ }),
/* 849 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.DefaultSelectionModel
 * @extends Ext.util.Observable
 * The default single selection for a TreePanel.
 */
Ext.tree.DefaultSelectionModel = function (config) {
  this.selNode = null;
  this.addEvents(
  /**
   * @event selectionchange
   * Fires when the selected node changes
   * @param {DefaultSelectionModel} this
   * @param {TreeNode} node the new selection
   */
  'selectionchange',
  /**
   * @event beforeselect
   * Fires before the selected node changes, return false to cancel the change
   * @param {DefaultSelectionModel} this
   * @param {TreeNode} node the new selection
   * @param {TreeNode} node the old selection
   */
  'beforeselect');
  Ext.apply(this, config);
  Ext.tree.DefaultSelectionModel.superclass.constructor.call(this);
};

Ext.extend(Ext.tree.DefaultSelectionModel, Ext.util.Observable, {
  init: function init(tree) {
    this.tree = tree;
    tree.mon(tree.getTreeEl(), 'keydown', this.onKeyDown, this);
    tree.on('click', this.onNodeClick, this);
  },
  onNodeClick: function onNodeClick(node, e) {
    this.select(node);
  },

  /**
   * Select a node.
   * @param {TreeNode} node The node to select
   * @return {TreeNode} The selected node
   */
  select: function select(node,
  /* private*/
  selectNextNode) {
    // If node is hidden, select the next node in whatever direction was being moved in.
    if (!Ext.fly(node.ui.wrap).isVisible() && selectNextNode) {
      return selectNextNode.call(this, node);
    }

    var last = this.selNode;

    if (node == last) {
      node.ui.onSelectedChange(true);
    } else if (this.fireEvent('beforeselect', this, node, last) !== false) {
      if (last && last.ui) {
        last.ui.onSelectedChange(false);
      }

      this.selNode = node;
      node.ui.onSelectedChange(true);
      this.fireEvent('selectionchange', this, node, last);
    }

    return node;
  },

  /**
   * Deselect a node.
   * @param {TreeNode} node The node to unselect
   * @param {Boolean} silent True to stop the selectionchange event from firing.
   */
  unselect: function unselect(node, silent) {
    if (this.selNode == node) {
      this.clearSelections(silent);
    }
  },

  /**
   * Clear all selections
   * @param {Boolean} silent True to stop the selectionchange event from firing.
   */
  clearSelections: function clearSelections(silent) {
    var n = this.selNode;

    if (n) {
      n.ui.onSelectedChange(false);
      this.selNode = null;

      if (silent !== true) {
        this.fireEvent('selectionchange', this, null);
      }
    }

    return n;
  },

  /**
   * Get the selected node
   * @return {TreeNode} The selected node
   */
  getSelectedNode: function getSelectedNode() {
    return this.selNode;
  },

  /**
   * Returns true if the node is selected
   * @param {TreeNode} node The node to check
   * @return {Boolean}
   */
  isSelected: function isSelected(node) {
    return this.selNode == node;
  },

  /**
   * Selects the node above the selected node in the tree, intelligently walking the nodes
   * @return TreeNode The new selection
   */
  selectPrevious: function selectPrevious(
  /* private */
  s) {
    if (!(s = s || this.selNode || this.lastSelNode)) {
      return null;
    } // Here we pass in the current function to select to indicate the direction we're moving


    var ps = s.previousSibling;

    if (ps) {
      if (!ps.isExpanded() || ps.childNodes.length < 1) {
        return this.select(ps, this.selectPrevious);
      } else {
        var lc = ps.lastChild;

        while (lc && lc.isExpanded() && Ext.fly(lc.ui.wrap).isVisible() && lc.childNodes.length > 0) {
          lc = lc.lastChild;
        }

        return this.select(lc, this.selectPrevious);
      }
    } else if (s.parentNode && (this.tree.rootVisible || !s.parentNode.isRoot)) {
      return this.select(s.parentNode, this.selectPrevious);
    }

    return null;
  },

  /**
   * Selects the node above the selected node in the tree, intelligently walking the nodes
   * @return TreeNode The new selection
   */
  selectNext: function selectNext(
  /* private */
  s) {
    if (!(s = s || this.selNode || this.lastSelNode)) {
      return null;
    } // Here we pass in the current function to select to indicate the direction we're moving


    if (s.firstChild && s.isExpanded() && Ext.fly(s.ui.wrap).isVisible()) {
      return this.select(s.firstChild, this.selectNext);
    } else if (s.nextSibling) {
      return this.select(s.nextSibling, this.selectNext);
    } else if (s.parentNode) {
      var newS = null;
      s.parentNode.bubble(function () {
        if (this.nextSibling) {
          newS = this.getOwnerTree().selModel.select(this.nextSibling, this.selectNext);
          return false;
        }
      });
      return newS;
    }

    return null;
  },
  onKeyDown: function onKeyDown(e) {
    var s = this.selNode || this.lastSelNode; // undesirable, but required

    var sm = this;

    if (!s) {
      return;
    }

    var k = e.getKey();

    switch (k) {
      case e.DOWN:
        e.stopEvent();
        this.selectNext();
        break;

      case e.UP:
        e.stopEvent();
        this.selectPrevious();
        break;

      case e.RIGHT:
        e.preventDefault();

        if (s.hasChildNodes()) {
          if (!s.isExpanded()) {
            s.expand();
          } else if (s.firstChild) {
            this.select(s.firstChild, e);
          }
        }

        break;

      case e.LEFT:
        e.preventDefault();

        if (s.hasChildNodes() && s.isExpanded()) {
          s.collapse();
        } else if (s.parentNode && (this.tree.rootVisible || s.parentNode != this.tree.getRootNode())) {
          this.select(s.parentNode, e);
        }

        break;
    }

    ;
  }
});
/**
 * @class Ext.tree.MultiSelectionModel
 * @extends Ext.util.Observable
 * Multi selection for a TreePanel.
 */

Ext.tree.MultiSelectionModel = function (config) {
  this.selNodes = [];
  this.selMap = {};
  this.addEvents(
  /**
   * @event selectionchange
   * Fires when the selected nodes change
   * @param {MultiSelectionModel} this
   * @param {Array} nodes Array of the selected nodes
   */
  'selectionchange');
  Ext.apply(this, config);
  Ext.tree.MultiSelectionModel.superclass.constructor.call(this);
};

Ext.extend(Ext.tree.MultiSelectionModel, Ext.util.Observable, {
  init: function init(tree) {
    this.tree = tree;
    tree.mon(tree.getTreeEl(), 'keydown', this.onKeyDown, this);
    tree.on('click', this.onNodeClick, this);
  },
  onNodeClick: function onNodeClick(node, e) {
    if (e.ctrlKey && this.isSelected(node)) {
      this.unselect(node);
    } else {
      this.select(node, e, e.ctrlKey);
    }
  },

  /**
   * Select a node.
   * @param {TreeNode} node The node to select
   * @param {EventObject} e (optional) An event associated with the selection
   * @param {Boolean} keepExisting True to retain existing selections
   * @return {TreeNode} The selected node
   */
  select: function select(node, e, keepExisting, focus = true) {
    if (keepExisting !== true) {
      this.clearSelections(true);
    }

    if (this.isSelected(node)) {
      this.lastSelNode = node;
      return node;
    }

    this.selNodes.push(node);
    this.selMap[node.id] = node;
    this.lastSelNode = node;
    node.ui.onSelectedChange(true, focus);
    this.fireEvent('selectionchange', this, this.selNodes);
    return node;
  },

  /**
   * Deselect a node.
   * @param {TreeNode} node The node to unselect
   */
  unselect: function unselect(node) {
    if (this.selMap[node.id]) {
      node.ui.onSelectedChange(false);
      var sn = this.selNodes;
      var index = sn.indexOf(node);

      if (index != -1) {
        this.selNodes.splice(index, 1);
      }

      delete this.selMap[node.id];
      this.fireEvent('selectionchange', this, this.selNodes);
    }
  },

  /**
   * Clear all selections
   */
  clearSelections: function clearSelections(suppressEvent) {
    var sn = this.selNodes;

    if (sn.length > 0) {
      for (var i = 0, len = sn.length; i < len; i++) {
        sn[i].ui.onSelectedChange(false);
      }

      this.selNodes = [];
      this.selMap = {};

      if (suppressEvent !== true) {
        this.fireEvent('selectionchange', this, this.selNodes);
      }
    }
  },

  /**
   * Returns true if the node is selected
   * @param {TreeNode} node The node to check
   * @return {Boolean}
   */
  isSelected: function isSelected(node) {
    return this.selMap[node.id] ? true : false;
  },

  /**
   * Returns an array of the selected nodes
   * @return {Array}
   */
  getSelectedNodes: function getSelectedNodes() {
    return this.selNodes;
  },
  onKeyDown: Ext.tree.DefaultSelectionModel.prototype.onKeyDown,
  selectNext: Ext.tree.DefaultSelectionModel.prototype.selectNext,
  selectPrevious: Ext.tree.DefaultSelectionModel.prototype.selectPrevious
});

/***/ }),
/* 850 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.data.Tree
 * @extends Ext.util.Observable
 * Represents a tree data structure and bubbles all the events for its nodes. The nodes
 * in the tree have most standard DOM functionality.
 * @constructor
 * @param {Node} root (optional) The root node
 */
Ext.data.Tree = function (root) {
  this.nodeHash = {};
  /**
   * The root node for this tree
   * @type Node
   */

  this.root = null;

  if (root) {
    this.setRootNode(root);
  }

  this.addEvents(
  /**
   * @event append
   * Fires when a new child node is appended to a node in this tree.
   * @param {Tree} tree The owner tree
   * @param {Node} parent The parent node
   * @param {Node} node The newly appended node
   * @param {Number} index The index of the newly appended node
   */
  "append",
  /**
   * @event remove
   * Fires when a child node is removed from a node in this tree.
   * @param {Tree} tree The owner tree
   * @param {Node} parent The parent node
   * @param {Node} node The child node removed
   */
  "remove",
  /**
   * @event move
   * Fires when a node is moved to a new location in the tree
   * @param {Tree} tree The owner tree
   * @param {Node} node The node moved
   * @param {Node} oldParent The old parent of this node
   * @param {Node} newParent The new parent of this node
   * @param {Number} index The index it was moved to
   */
  "move",
  /**
   * @event insert
   * Fires when a new child node is inserted in a node in this tree.
   * @param {Tree} tree The owner tree
   * @param {Node} parent The parent node
   * @param {Node} node The child node inserted
   * @param {Node} refNode The child node the node was inserted before
   */
  "insert",
  /**
   * @event beforeappend
   * Fires before a new child is appended to a node in this tree, return false to cancel the append.
   * @param {Tree} tree The owner tree
   * @param {Node} parent The parent node
   * @param {Node} node The child node to be appended
   */
  "beforeappend",
  /**
   * @event beforeremove
   * Fires before a child is removed from a node in this tree, return false to cancel the remove.
   * @param {Tree} tree The owner tree
   * @param {Node} parent The parent node
   * @param {Node} node The child node to be removed
   */
  "beforeremove",
  /**
   * @event beforemove
   * Fires before a node is moved to a new location in the tree. Return false to cancel the move.
   * @param {Tree} tree The owner tree
   * @param {Node} node The node being moved
   * @param {Node} oldParent The parent of the node
   * @param {Node} newParent The new parent the node is moving to
   * @param {Number} index The index it is being moved to
   */
  "beforemove",
  /**
   * @event beforeinsert
   * Fires before a new child is inserted in a node in this tree, return false to cancel the insert.
   * @param {Tree} tree The owner tree
   * @param {Node} parent The parent node
   * @param {Node} node The child node to be inserted
   * @param {Node} refNode The child node the node is being inserted before
   */
  "beforeinsert");
  Ext.data.Tree.superclass.constructor.call(this);
};

Ext.extend(Ext.data.Tree, Ext.util.Observable, {
  /**
   * @cfg {String} pathSeparator
   * The token used to separate paths in node ids (defaults to '/').
   */
  pathSeparator: "/",
  // private
  proxyNodeEvent: function proxyNodeEvent() {
    return this.fireEvent.apply(this, arguments);
  },

  /**
   * Returns the root node for this tree.
   * @return {Node}
   */
  getRootNode: function getRootNode() {
    return this.root;
  },

  /**
   * Sets the root node for this tree.
   * @param {Node} node
   * @return {Node}
   */
  setRootNode: function setRootNode(node) {
    this.root = node;
    node.ownerTree = this;
    node.isRoot = true;
    this.registerNode(node);
    return node;
  },

  /**
   * Gets a node in this tree by its id.
   * @param {String} id
   * @return {Node}
   */
  getNodeById: function getNodeById(id) {
    return this.nodeHash[id];
  },
  // private
  registerNode: function registerNode(node) {
    this.nodeHash[node.id] = node;
  },
  // private
  unregisterNode: function unregisterNode(node) {
    delete this.nodeHash[node.id];
  },
  toString: function toString() {
    return "[Tree" + (this.id ? " " + this.id : "") + "]";
  }
});
/**
 * @class Ext.data.Node
 * @extends Ext.util.Observable
 * @cfg {Boolean} leaf true if this node is a leaf and does not have children
 * @cfg {String} id The id for this node. If one is not specified, one is generated.
 * @constructor
 * @param {Object} attributes The attributes/config for the node
 */

Ext.data.Node = function (attributes) {
  /**
   * The attributes supplied for the node. You can use this property to access any custom attributes you supplied.
   * @type {Object}
   */
  this.attributes = attributes || {};
  this.leaf = this.attributes.leaf;
  /**
   * The node id. @type String
   */

  this.id = this.attributes.id;

  if (!this.id) {
    this.id = Ext.id(null, "xnode-");
    this.attributes.id = this.id;
  }
  /**
   * All child nodes of this node. @type Array
   */


  this.childNodes = [];

  if (!this.childNodes.indexOf) {
    // indexOf is a must
    this.childNodes.indexOf = function (o) {
      for (var i = 0, len = this.length; i < len; i++) {
        if (this[i] == o) {
          return i;
        }
      }

      return -1;
    };
  }
  /**
   * The parent node for this node. @type Node
   */


  this.parentNode = null;
  /**
   * The first direct child node of this node, or null if this node has no child nodes. @type Node
   */

  this.firstChild = null;
  /**
   * The last direct child node of this node, or null if this node has no child nodes. @type Node
   */

  this.lastChild = null;
  /**
   * The node immediately preceding this node in the tree, or null if there is no sibling node. @type Node
   */

  this.previousSibling = null;
  /**
   * The node immediately following this node in the tree, or null if there is no sibling node. @type Node
   */

  this.nextSibling = null;
  this.addEvents({
    /**
     * @event append
     * Fires when a new child node is appended
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} node The newly appended node
     * @param {Number} index The index of the newly appended node
     */
    "append": true,

    /**
     * @event remove
     * Fires when a child node is removed
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} node The removed node
     */
    "remove": true,

    /**
     * @event move
     * Fires when this node is moved to a new location in the tree
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} oldParent The old parent of this node
     * @param {Node} newParent The new parent of this node
     * @param {Number} index The index it was moved to
     */
    "move": true,

    /**
     * @event insert
     * Fires when a new child node is inserted.
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} node The child node inserted
     * @param {Node} refNode The child node the node was inserted before
     */
    "insert": true,

    /**
     * @event beforeappend
     * Fires before a new child is appended, return false to cancel the append.
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} node The child node to be appended
     */
    "beforeappend": true,

    /**
     * @event beforeremove
     * Fires before a child is removed, return false to cancel the remove.
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} node The child node to be removed
     */
    "beforeremove": true,

    /**
     * @event beforemove
     * Fires before this node is moved to a new location in the tree. Return false to cancel the move.
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} oldParent The parent of this node
     * @param {Node} newParent The new parent this node is moving to
     * @param {Number} index The index it is being moved to
     */
    "beforemove": true,

    /**
     * @event beforeinsert
     * Fires before a new child is inserted, return false to cancel the insert.
     * @param {Tree} tree The owner tree
     * @param {Node} this This node
     * @param {Node} node The child node to be inserted
     * @param {Node} refNode The child node the node is being inserted before
     */
    "beforeinsert": true
  });
  this.listeners = this.attributes.listeners;
  Ext.data.Node.superclass.constructor.call(this);
};

Ext.extend(Ext.data.Node, Ext.util.Observable, {
  // private
  fireEvent: function fireEvent(evtName) {
    // first do standard event for this node
    if (Ext.data.Node.superclass.fireEvent.apply(this, arguments) === false) {
      return false;
    } // then bubble it up to the tree if the event wasn't cancelled


    var ot = this.getOwnerTree();

    if (ot) {
      if (ot.proxyNodeEvent.apply(ot, arguments) === false) {
        return false;
      }
    }

    return true;
  },

  /**
   * Returns true if this node is a leaf
   * @return {Boolean}
   */
  isLeaf: function isLeaf() {
    return this.leaf === true;
  },
  // private
  setFirstChild: function setFirstChild(node) {
    this.firstChild = node;
  },
  //private
  setLastChild: function setLastChild(node) {
    this.lastChild = node;
  },

  /**
   * Returns true if this node is the last child of its parent
   * @return {Boolean}
   */
  isLast: function isLast() {
    return !this.parentNode ? true : this.parentNode.lastChild == this;
  },

  /**
   * Returns true if this node is the first child of its parent
   * @return {Boolean}
   */
  isFirst: function isFirst() {
    return !this.parentNode ? true : this.parentNode.firstChild == this;
  },

  /**
   * Returns true if this node has one or more child nodes, else false.
   * @return {Boolean}
   */
  hasChildNodes: function hasChildNodes() {
    return !this.isLeaf() && this.childNodes.length > 0;
  },

  /**
   * Returns true if this node has one or more child nodes, or if the <tt>expandable</tt>
   * node attribute is explicitly specified as true (see {@link #attributes}), otherwise returns false.
   * @return {Boolean}
   */
  isExpandable: function isExpandable() {
    return this.attributes.expandable || this.hasChildNodes();
  },

  /**
   * Insert node(s) as the last child node of this node.
   * @param {Node/Array} node The node or Array of nodes to append
   * @return {Node} The appended node if single append, or null if an array was passed
   */
  appendChild: function appendChild(node) {
    var multi = false;

    if (Ext.isArray(node)) {
      multi = node;
    } else if (arguments.length > 1) {
      multi = arguments;
    } // if passed an array or multiple args do them one by one


    if (multi) {
      for (var i = 0, len = multi.length; i < len; i++) {
        this.appendChild(multi[i]);
      }
    } else {
      if (this.fireEvent("beforeappend", this.ownerTree, this, node) === false) {
        return false;
      }

      var index = this.childNodes.length;
      var oldParent = node.parentNode; // it's a move, make sure we move it cleanly

      if (oldParent) {
        if (node.fireEvent("beforemove", node.getOwnerTree(), node, oldParent, this, index) === false) {
          return false;
        }

        oldParent.removeChild(node);
      }

      index = this.childNodes.length;

      if (index === 0) {
        this.setFirstChild(node);
      }

      this.childNodes.push(node);
      node.parentNode = this;
      var ps = this.childNodes[index - 1];

      if (ps) {
        node.previousSibling = ps;
        ps.nextSibling = node;
      } else {
        node.previousSibling = null;
      }

      node.nextSibling = null;
      this.setLastChild(node);
      node.setOwnerTree(this.getOwnerTree());
      this.fireEvent("append", this.ownerTree, this, node, index);

      if (oldParent) {
        node.fireEvent("move", this.ownerTree, node, oldParent, this, index);
      }

      return node;
    }
  },

  /**
   * Removes a child node from this node.
   * @param {Node} node The node to remove
   * @param {Boolean} destroy <tt>true</tt> to destroy the node upon removal. Defaults to <tt>false</tt>.
   * @return {Node} The removed node
   */
  removeChild: function removeChild(node, destroy) {
    var index = this.childNodes.indexOf(node);

    if (index == -1) {
      return false;
    }

    if (this.fireEvent("beforeremove", this.ownerTree, this, node) === false) {
      return false;
    } // remove it from childNodes collection


    this.childNodes.splice(index, 1); // update siblings

    if (node.previousSibling) {
      node.previousSibling.nextSibling = node.nextSibling;
    }

    if (node.nextSibling) {
      node.nextSibling.previousSibling = node.previousSibling;
    } // update child refs


    if (this.firstChild == node) {
      this.setFirstChild(node.nextSibling);
    }

    if (this.lastChild == node) {
      this.setLastChild(node.previousSibling);
    }

    node.clear();
    this.fireEvent("remove", this.ownerTree, this, node);

    if (destroy) {
      node.destroy();
    }

    return node;
  },
  // private
  clear: function clear(destroy) {
    // clear any references from the node
    this.setOwnerTree(null, destroy);
    this.parentNode = this.previousSibling = this.nextSibling = null;

    if (destroy) {
      this.firstChild = this.lastChild = null;
    }
  },

  /**
   * Destroys the node.
   */
  destroy: function destroy() {
    this.purgeListeners();
    this.clear(true);
    Ext.each(this.childNodes, function (n) {
      n.destroy();
    });
    this.childNodes = null;
  },

  /**
   * Inserts the first node before the second node in this nodes childNodes collection.
   * @param {Node} node The node to insert
   * @param {Node} refNode The node to insert before (if null the node is appended)
   * @return {Node} The inserted node
   */
  insertBefore: function insertBefore(node, refNode) {
    if (!refNode) {
      // like standard Dom, refNode can be null for append
      return this.appendChild(node);
    } // nothing to do


    if (node == refNode) {
      return false;
    }

    if (this.fireEvent("beforeinsert", this.ownerTree, this, node, refNode) === false) {
      return false;
    }

    var index = this.childNodes.indexOf(refNode);
    var oldParent = node.parentNode;
    var refIndex = index; // when moving internally, indexes will change after remove

    if (oldParent == this && this.childNodes.indexOf(node) < index) {
      refIndex--;
    } // it's a move, make sure we move it cleanly


    if (oldParent) {
      if (node.fireEvent("beforemove", node.getOwnerTree(), node, oldParent, this, index, refNode) === false) {
        return false;
      }

      oldParent.removeChild(node);
    }

    if (refIndex === 0) {
      this.setFirstChild(node);
    }

    this.childNodes.splice(refIndex, 0, node);
    node.parentNode = this;
    var ps = this.childNodes[refIndex - 1];

    if (ps) {
      node.previousSibling = ps;
      ps.nextSibling = node;
    } else {
      node.previousSibling = null;
    }

    node.nextSibling = refNode;
    refNode.previousSibling = node;
    node.setOwnerTree(this.getOwnerTree());
    this.fireEvent("insert", this.ownerTree, this, node, refNode);

    if (oldParent) {
      node.fireEvent("move", this.ownerTree, node, oldParent, this, refIndex, refNode);
    }

    return node;
  },

  /**
   * Removes this node from its parent
   * @param {Boolean} destroy <tt>true</tt> to destroy the node upon removal. Defaults to <tt>false</tt>.
   * @return {Node} this
   */
  remove: function remove(destroy) {
    this.parentNode.removeChild(this, destroy);
    return this;
  },

  /**
   * Removes all child nodes from this node.
   * @param {Boolean} destroy <tt>true</tt> to destroy the node upon removal. Defaults to <tt>false</tt>.
   * @return {Node} this
   */
  removeAll: function removeAll(destroy) {
    var cn = this.childNodes,
        n;

    while (n = cn[0]) {
      this.removeChild(n, destroy);
    }

    return this;
  },

  /**
   * Returns the child node at the specified index.
   * @param {Number} index
   * @return {Node}
   */
  item: function item(index) {
    return this.childNodes[index];
  },

  /**
   * Replaces one child node in this node with another.
   * @param {Node} newChild The replacement node
   * @param {Node} oldChild The node to replace
   * @return {Node} The replaced node
   */
  replaceChild: function replaceChild(newChild, oldChild) {
    var s = oldChild ? oldChild.nextSibling : null;
    this.removeChild(oldChild);
    this.insertBefore(newChild, s);
    return oldChild;
  },

  /**
   * Returns the index of a child node
   * @param {Node} node
   * @return {Number} The index of the node or -1 if it was not found
   */
  indexOf: function indexOf(child) {
    return this.childNodes.indexOf(child);
  },

  /**
   * Returns the tree this node is in.
   * @return {Tree}
   */
  getOwnerTree: function getOwnerTree() {
    // if it doesn't have one, look for one
    if (!this.ownerTree) {
      var p = this;

      while (p) {
        if (p.ownerTree) {
          this.ownerTree = p.ownerTree;
          break;
        }

        p = p.parentNode;
      }
    }

    return this.ownerTree;
  },

  /**
   * Returns depth of this node (the root node has a depth of 0)
   * @return {Number}
   */
  getDepth: function getDepth() {
    var depth = 0;
    var p = this;

    while (p.parentNode) {
      ++depth;
      p = p.parentNode;
    }

    return depth;
  },
  // private
  setOwnerTree: function setOwnerTree(tree, destroy) {
    // if it is a move, we need to update everyone
    if (tree != this.ownerTree) {
      if (this.ownerTree) {
        this.ownerTree.unregisterNode(this);
      }

      this.ownerTree = tree; // If we're destroying, we don't need to recurse since it will be called on each child node

      if (destroy !== true) {
        Ext.each(this.childNodes, function (n) {
          n.setOwnerTree(tree);
        });
      }

      if (tree) {
        tree.registerNode(this);
      }
    }
  },

  /**
   * Changes the id of this node.
   * @param {String} id The new id for the node.
   */
  setId: function setId(id) {
    if (id !== this.id) {
      var t = this.ownerTree;

      if (t) {
        t.unregisterNode(this);
      }

      this.id = this.attributes.id = id;

      if (t) {
        t.registerNode(this);
      }

      this.onIdChange(id);
    }
  },
  // private
  onIdChange: Ext.emptyFn,

  /**
   * Returns the path for this node. The path can be used to expand or select this node programmatically.
   * @param {String} attr (optional) The attr to use for the path (defaults to the node's id)
   * @return {String} The path
   */
  getPath: function getPath(attr) {
    attr = attr || "id";
    var p = this.parentNode;
    var b = [this.attributes[attr]];

    while (p) {
      b.unshift(p.attributes[attr]);
      p = p.parentNode;
    }

    var sep = this.getOwnerTree().pathSeparator;
    return sep + b.join(sep);
  },

  /**
   * Bubbles up the tree from this node, calling the specified function with each node. The arguments to the function
   * will be the args provided or the current node. If the function returns false at any point,
   * the bubble is stopped.
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the current Node.
   * @param {Array} args (optional) The args to call the function with (default to passing the current Node)
   */
  bubble: function bubble(fn, scope, args) {
    var p = this;

    while (p) {
      if (fn.apply(scope || p, args || [p]) === false) {
        break;
      }

      p = p.parentNode;
    }
  },

  /**
   * Cascades down the tree from this node, calling the specified function with each node. The arguments to the function
   * will be the args provided or the current node. If the function returns false at any point,
   * the cascade is stopped on that branch.
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the current Node.
   * @param {Array} args (optional) The args to call the function with (default to passing the current Node)
   */
  cascade: function cascade(fn, scope, args) {
    if (fn.apply(scope || this, args || [this]) !== false) {
      var cs = this.childNodes;

      for (var i = 0, len = cs.length; i < len; i++) {
        cs[i].cascade(fn, scope, args);
      }
    }
  },

  /**
   * Interates the child nodes of this node, calling the specified function with each node. The arguments to the function
   * will be the args provided or the current node. If the function returns false at any point,
   * the iteration stops.
   * @param {Function} fn The function to call
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the current Node in the iteration.
   * @param {Array} args (optional) The args to call the function with (default to passing the current Node)
   */
  eachChild: function eachChild(fn, scope, args) {
    var cs = this.childNodes;

    for (var i = 0, len = cs.length; i < len; i++) {
      if (fn.apply(scope || this, args || [cs[i]]) === false) {
        break;
      }
    }
  },

  /**
   * Finds the first child that has the attribute with the specified value.
   * @param {String} attribute The attribute name
   * @param {Mixed} value The value to search for
   * @return {Node} The found child or null if none was found
   */
  findChild: function findChild(attribute, value) {
    var cs = this.childNodes;

    for (var i = 0, len = cs.length; i < len; i++) {
      if (cs[i].attributes[attribute] == value) {
        return cs[i];
      }
    }

    return null;
  },

  /**
   * Finds the first child by a custom function. The child matches if the function passed returns <code>true</code>.
   * @param {Function} fn A function which must return <code>true</code> if the passed Node is the required Node.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the Node being tested.
   * @return {Node} The found child or null if none was found
   */
  findChildBy: function findChildBy(fn, scope) {
    var cs = this.childNodes;

    for (var i = 0, len = cs.length; i < len; i++) {
      if (fn.call(scope || cs[i], cs[i]) === true) {
        return cs[i];
      }
    }

    return null;
  },

  /**
   * Sorts this nodes children using the supplied sort function.
   * @param {Function} fn A function which, when passed two Nodes, returns -1, 0 or 1 depending upon required sort order.
   * @param {Object} scope (optional)The scope (<code>this</code> reference) in which the function is executed. Defaults to the browser window.
   */
  sort: function sort(fn, scope) {
    var cs = this.childNodes;
    var len = cs.length;

    if (len > 0) {
      var sortFn = scope ? function () {
        fn.apply(scope, arguments);
      } : fn;
      cs.sort(sortFn);

      for (var i = 0; i < len; i++) {
        var n = cs[i];
        n.previousSibling = cs[i - 1];
        n.nextSibling = cs[i + 1];

        if (i === 0) {
          this.setFirstChild(n);
        }

        if (i == len - 1) {
          this.setLastChild(n);
        }
      }
    }
  },

  /**
   * Returns true if this node is an ancestor (at any point) of the passed node.
   * @param {Node} node
   * @return {Boolean}
   */
  contains: function contains(node) {
    return node.isAncestor(this);
  },

  /**
   * Returns true if the passed node is an ancestor (at any point) of this node.
   * @param {Node} node
   * @return {Boolean}
   */
  isAncestor: function isAncestor(node) {
    var p = this.parentNode;

    while (p) {
      if (p == node) {
        return true;
      }

      p = p.parentNode;
    }

    return false;
  },
  toString: function toString() {
    return "[Node" + (this.id ? " " + this.id : "") + "]";
  }
});

/***/ }),
/* 851 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeNode
 * @extends Ext.data.Node
 * @cfg {String} text The text for this node
 * @cfg {Boolean} expanded true to start the node expanded
 * @cfg {Boolean} allowDrag False to make this node undraggable if {@link #draggable} = true (defaults to true)
 * @cfg {Boolean} allowDrop False if this node cannot have child nodes dropped on it (defaults to true)
 * @cfg {Boolean} disabled true to start the node disabled
 * @cfg {String} icon The path to an icon for the node. The preferred way to do this
 * is to use the cls or iconCls attributes and add the icon via a CSS background image.
 * @cfg {String} cls A css class to be added to the node
 * @cfg {String} iconCls A css class to be added to the nodes icon element for applying css background images
 * @cfg {String} href URL of the link used for the node (defaults to #)
 * @cfg {String} hrefTarget target frame for the link
 * @cfg {Boolean} hidden True to render hidden. (Defaults to false).
 * @cfg {String} qtip An Ext QuickTip for the node
 * @cfg {Boolean} expandable If set to true, the node will always show a plus/minus icon, even when empty
 * @cfg {String} qtipCfg An Ext QuickTip config for the node (used instead of qtip)
 * @cfg {Boolean} singleClickExpand True for single click expand on this node
 * @cfg {Function} uiProvider A UI <b>class</b> to use for this node (defaults to Ext.tree.TreeNodeUI)
 * @cfg {Boolean} checked True to render a checked checkbox for this node, false to render an unchecked checkbox
 * (defaults to undefined with no checkbox rendered)
 * @cfg {Boolean} draggable True to make this node draggable (defaults to false)
 * @cfg {Boolean} isTarget False to not allow this node to act as a drop target (defaults to true)
 * @cfg {Boolean} allowChildren False to not allow this node to have child nodes (defaults to true)
 * @cfg {Boolean} editable False to not allow this node to be edited by an {@link Ext.tree.TreeEditor} (defaults to true)
 * @constructor
 * @param {Object/String} attributes The attributes/config for the node or just a string with the text for the node
 */
Ext.tree.TreeNode = function (attributes) {
  attributes = attributes || {};

  if (Ext.isString(attributes)) {
    attributes = {
      text: attributes
    };
  }

  this.childrenRendered = false;
  this.rendered = false;
  Ext.tree.TreeNode.superclass.constructor.call(this, attributes);
  this.expanded = attributes.expanded === true;
  this.isTarget = attributes.isTarget !== false;
  this.draggable = attributes.draggable !== false && attributes.allowDrag !== false;
  this.allowChildren = attributes.allowChildren !== false && attributes.allowDrop !== false;
  /**
   * Read-only. The text for this node. To change it use <code>{@link #setText}</code>.
   * @type String
   */

  this.text = attributes.text;
  /**
   * True if this node is disabled.
   * @type Boolean
   */

  this.disabled = attributes.disabled === true;
  /**
   * True if this node is hidden.
   * @type Boolean
   */

  this.hidden = attributes.hidden === true;
  this.addEvents(
  /**
  * @event textchange
  * Fires when the text for this node is changed
  * @param {Node} this This node
  * @param {String} text The new text
  * @param {String} oldText The old text
  */
  'textchange',
  /**
  * @event beforeexpand
  * Fires before this node is expanded, return false to cancel.
  * @param {Node} this This node
  * @param {Boolean} deep
  * @param {Boolean} anim
  */
  'beforeexpand',
  /**
  * @event beforecollapse
  * Fires before this node is collapsed, return false to cancel.
  * @param {Node} this This node
  * @param {Boolean} deep
  * @param {Boolean} anim
  */
  'beforecollapse',
  /**
  * @event expand
  * Fires when this node is expanded
  * @param {Node} this This node
  */
  'expand',
  /**
  * @event disabledchange
  * Fires when the disabled status of this node changes
  * @param {Node} this This node
  * @param {Boolean} disabled
  */
  'disabledchange',
  /**
  * @event collapse
  * Fires when this node is collapsed
  * @param {Node} this This node
  */
  'collapse',
  /**
  * @event beforeclick
  * Fires before click processing. Return false to cancel the default action.
  * @param {Node} this This node
  * @param {Ext.EventObject} e The event object
  */
  'beforeclick',
  /**
  * @event click
  * Fires when this node is clicked
  * @param {Node} this This node
  * @param {Ext.EventObject} e The event object
  */
  'click',
  /**
  * @event checkchange
  * Fires when a node with a checkbox's checked property changes
  * @param {Node} this This node
  * @param {Boolean} checked
  */
  'checkchange',
  /**
  * @event beforedblclick
  * Fires before double click processing. Return false to cancel the default action.
  * @param {Node} this This node
  * @param {Ext.EventObject} e The event object
  */
  'beforedblclick',
  /**
  * @event dblclick
  * Fires when this node is double clicked
  * @param {Node} this This node
  * @param {Ext.EventObject} e The event object
  */
  'dblclick',
  /**
  * @event contextmenu
  * Fires when this node is right clicked
  * @param {Node} this This node
  * @param {Ext.EventObject} e The event object
  */
  'contextmenu',
  /**
  * @event beforechildrenrendered
  * Fires right before the child nodes for this node are rendered
  * @param {Node} this This node
  */
  'beforechildrenrendered');
  var uiClass = this.attributes.uiProvider || this.defaultUI || Ext.tree.TreeNodeUI;
  /**
   * Read-only. The UI for this node
   * @type TreeNodeUI
   */

  this.ui = new uiClass(this);
};

Ext.extend(Ext.tree.TreeNode, Ext.data.Node, {
  preventHScroll: true,

  /**
   * Returns true if this node is expanded
   * @return {Boolean}
   */
  isExpanded: function isExpanded() {
    return this.expanded;
  },

  /**
   * Returns the UI object for this node.
   * @return {TreeNodeUI} The object which is providing the user interface for this tree
   * node. Unless otherwise specified in the {@link #uiProvider}, this will be an instance
   * of {@link Ext.tree.TreeNodeUI}
   */
  getUI: function getUI() {
    return this.ui;
  },
  getLoader: function getLoader() {
    var owner;
    return this.loader || ((owner = this.getOwnerTree()) && owner.loader ? owner.loader : this.loader = new Ext.tree.TreeLoader());
  },
  // private override
  setFirstChild: function setFirstChild(node) {
    var of = this.firstChild;
    Ext.tree.TreeNode.superclass.setFirstChild.call(this, node);

    if (this.childrenRendered && of && node != of) {
      of.renderIndent(true, true);
    }

    if (this.rendered) {
      this.renderIndent(true, true);
    }
  },
  // private override
  setLastChild: function setLastChild(node) {
    var ol = this.lastChild;
    Ext.tree.TreeNode.superclass.setLastChild.call(this, node);

    if (this.childrenRendered && ol && node != ol) {
      ol.renderIndent(true, true);
    }

    if (this.rendered) {
      this.renderIndent(true, true);
    }
  },
  // these methods are overridden to provide lazy rendering support
  // private override
  appendChild: function appendChild(n) {
    var node, exists;

    if (!n.render && !Ext.isArray(n)) {
      n = this.getLoader().createNode(n);
    } else {
      exists = !n.parentNode;
    }

    node = Ext.tree.TreeNode.superclass.appendChild.call(this, n);

    if (node) {
      this.afterAdd(node, exists);
    }

    this.ui.updateExpandIcon();
    return node;
  },
  // private override
  removeChild: function removeChild(node, destroy) {
    this.ownerTree.getSelectionModel().unselect(node);
    Ext.tree.TreeNode.superclass.removeChild.apply(this, arguments); // if it's been rendered remove dom node

    if (node.ui.rendered) {
      node.ui.remove();
    }

    if (this.childNodes.length < 1) {
      this.collapse(false, false);
    } else {
      this.ui.updateExpandIcon();
    }

    if (!this.firstChild && !this.isHiddenRoot()) {
      this.childrenRendered = false;
    }

    return node;
  },
  // private override
  insertBefore: function insertBefore(node, refNode) {
    var newNode, exists;

    if (!node.render) {
      node = this.getLoader().createNode(node);
    } else {
      exists = Ext.isObject(node.parentNode);
    }

    newNode = Ext.tree.TreeNode.superclass.insertBefore.call(this, node, refNode);

    if (newNode && refNode) {
      this.afterAdd(newNode, exists);
    }

    this.ui.updateExpandIcon();
    return newNode;
  },
  // private
  afterAdd: function afterAdd(node, exists) {
    if (this.childrenRendered) {
      // bulk render if the node already exists
      node.render(exists);
    } else if (exists) {
      // make sure we update the indent
      node.renderIndent(true, true);
    }
  },

  /**
   * Sets the text for this node
   * @param {String} text
   */
  setText: function setText(text) {
    var oldText = this.text;
    this.text = this.attributes.text = text;

    if (this.rendered) {
      // event without subscribing
      this.ui.onTextChange(this, text, oldText);
    }

    this.fireEvent('textchange', this, text, oldText);
  },

  /**
   * Triggers selection of this node
   */
  select: function select() {
    var t = this.getOwnerTree();

    if (t) {
      t.getSelectionModel().select(this);
    }
  },

  /**
   * Triggers deselection of this node
   * @param {Boolean} silent (optional) True to stop selection change events from firing.
   */
  unselect: function unselect(silent) {
    var t = this.getOwnerTree();

    if (t) {
      t.getSelectionModel().unselect(this, silent);
    }
  },

  /**
   * Returns true if this node is selected
   * @return {Boolean}
   */
  isSelected: function isSelected() {
    var t = this.getOwnerTree();
    return t ? t.getSelectionModel().isSelected(this) : false;
  },

  /**
   * Expand this node.
   * @param {Boolean} deep (optional) True to expand all children as well
   * @param {Boolean} anim (optional) false to cancel the default animation
   * @param {Function} callback (optional) A callback to be called when
   * expanding this node completes (does not wait for deep expand to complete).
   * Called with 1 parameter, this node.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to this TreeNode.
   */
  expand: function expand(deep, anim, callback, scope) {
    if (!this.expanded) {
      if (this.fireEvent('beforeexpand', this, deep, anim) === false) {
        return;
      }

      if (!this.childrenRendered) {
        this.renderChildren();
      }

      this.expanded = true;

      if (!this.isHiddenRoot() && this.getOwnerTree().animate && anim !== false || anim) {
        this.ui.animExpand(function () {
          this.fireEvent('expand', this);
          this.runCallback(callback, scope || this, [this]);

          if (deep === true) {
            this.expandChildNodes(true);
          }
        }.createDelegate(this));
        return;
      } else {
        this.ui.expand();
        this.fireEvent('expand', this);
        this.runCallback(callback, scope || this, [this]);
      }
    } else {
      this.runCallback(callback, scope || this, [this]);
    }

    if (deep === true) {
      this.expandChildNodes(true);
    }
  },
  runCallback: function runCallback(cb, scope, args) {
    if (Ext.isFunction(cb)) {
      cb.apply(scope, args);
    }
  },
  isHiddenRoot: function isHiddenRoot() {
    return this.isRoot && !this.getOwnerTree().rootVisible;
  },

  /**
   * Collapse this node.
   * @param {Boolean} deep (optional) True to collapse all children as well
   * @param {Boolean} anim (optional) false to cancel the default animation
   * @param {Function} callback (optional) A callback to be called when
   * expanding this node completes (does not wait for deep expand to complete).
   * Called with 1 parameter, this node.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to this TreeNode.
   */
  collapse: function collapse(deep, anim, callback, scope) {
    if (this.expanded && !this.isHiddenRoot()) {
      if (this.fireEvent('beforecollapse', this, deep, anim) === false) {
        return;
      }

      this.expanded = false;

      if (this.getOwnerTree().animate && anim !== false || anim) {
        this.ui.animCollapse(function () {
          this.fireEvent('collapse', this);
          this.runCallback(callback, scope || this, [this]);

          if (deep === true) {
            this.collapseChildNodes(true);
          }
        }.createDelegate(this));
        return;
      } else {
        this.ui.collapse();
        this.fireEvent('collapse', this);
        this.runCallback(callback, scope || this, [this]);
      }
    } else if (!this.expanded) {
      this.runCallback(callback, scope || this, [this]);
    }

    if (deep === true) {
      var cs = this.childNodes;

      for (var i = 0, len = cs.length; i < len; i++) {
        cs[i].collapse(true, false);
      }
    }
  },
  // private
  delayedExpand: function delayedExpand(delay) {
    if (!this.expandProcId) {
      this.expandProcId = this.expand.defer(delay, this);
    }
  },
  // private
  cancelExpand: function cancelExpand() {
    if (this.expandProcId) {
      clearTimeout(this.expandProcId);
    }

    this.expandProcId = false;
  },

  /**
   * Toggles expanded/collapsed state of the node
   */
  toggle: function toggle() {
    if (this.expanded) {
      this.collapse();
    } else {
      this.expand();
    }
  },

  /**
   * Ensures all parent nodes are expanded, and if necessary, scrolls
   * the node into view.
   * @param {Function} callback (optional) A function to call when the node has been made visible.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to this TreeNode.
   */
  ensureVisible: function ensureVisible(callback, scope) {
    var tree = this.getOwnerTree();
    tree.expandPath(this.parentNode ? this.parentNode.getPath() : this.getPath(), false, function () {
      var node = tree.getNodeById(this.id); // Somehow if we don't do this, we lose changes that happened to node in the meantime

      tree.getTreeEl().scrollChildIntoView(node.ui.anchor);
      this.runCallback(callback, scope || this, [this]);
    }.createDelegate(this));
  },

  /**
   * Expand all child nodes
   * @param {Boolean} deep (optional) true if the child nodes should also expand their child nodes
   */
  expandChildNodes: function expandChildNodes(deep) {
    var cs = this.childNodes;

    for (var i = 0, len = cs.length; i < len; i++) {
      cs[i].expand(deep);
    }
  },

  /**
   * Collapse all child nodes
   * @param {Boolean} deep (optional) true if the child nodes should also collapse their child nodes
   */
  collapseChildNodes: function collapseChildNodes(deep) {
    var cs = this.childNodes;

    for (var i = 0, len = cs.length; i < len; i++) {
      cs[i].collapse(deep);
    }
  },

  /**
   * Disables this node
   */
  disable: function disable() {
    this.disabled = true;
    this.unselect();

    if (this.rendered && this.ui.onDisableChange) {
      // event without subscribing
      this.ui.onDisableChange(this, true);
    }

    this.fireEvent('disabledchange', this, true);
  },

  /**
   * Enables this node
   */
  enable: function enable() {
    this.disabled = false;

    if (this.rendered && this.ui.onDisableChange) {
      // event without subscribing
      this.ui.onDisableChange(this, false);
    }

    this.fireEvent('disabledchange', this, false);
  },
  // private
  renderChildren: function renderChildren(suppressEvent) {
    if (suppressEvent !== false) {
      this.fireEvent('beforechildrenrendered', this);
    }

    var cs = this.childNodes;

    for (var i = 0, len = cs.length; i < len; i++) {
      cs[i].render(true);
    }

    this.childrenRendered = true;
  },
  // private
  sort: function sort(fn, scope) {
    Ext.tree.TreeNode.superclass.sort.apply(this, arguments);

    if (this.childrenRendered) {
      var cs = this.childNodes;

      for (var i = 0, len = cs.length; i < len; i++) {
        cs[i].render(true);
      }
    }
  },
  // private
  render: function render(bulkRender) {
    this.ui.render(bulkRender);

    if (!this.rendered) {
      // make sure it is registered
      this.getOwnerTree().registerNode(this);
      this.rendered = true;

      if (this.expanded) {
        this.expanded = false;
        this.expand(false, false);
      }
    }
  },
  // private
  renderIndent: function renderIndent(deep, refresh) {
    if (refresh) {
      this.ui.childIndent = null;
    }

    this.ui.renderIndent();

    if (deep === true && this.childrenRendered) {
      var cs = this.childNodes;

      for (var i = 0, len = cs.length; i < len; i++) {
        cs[i].renderIndent(true, refresh);
      }
    }
  },
  beginUpdate: function beginUpdate() {
    this.childrenRendered = false;
  },
  endUpdate: function endUpdate() {
    if (this.expanded && this.rendered) {
      this.renderChildren();
    }
  },
  destroy: function destroy() {
    this.unselect(true);
    Ext.tree.TreeNode.superclass.destroy.call(this);
    Ext.destroy(this.ui, this.loader);
    this.ui = this.loader = null;
  },
  // private
  onIdChange: function onIdChange(id) {
    this.ui.onIdChange(id);
  }
});
Ext.tree.TreePanel.nodeTypes.node = Ext.tree.TreeNode;

/***/ }),
/* 852 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.AsyncTreeNode
 * @extends Ext.tree.TreeNode
 * @cfg {TreeLoader} loader A TreeLoader to be used by this node (defaults to the loader defined on the tree)
 * @constructor
 * @param {Object/String} attributes The attributes/config for the node or just a string with the text for the node 
 */
Ext.tree.AsyncTreeNode = function (config) {
  this.loaded = config && config.loaded === true;
  this.loading = false;
  Ext.tree.AsyncTreeNode.superclass.constructor.apply(this, arguments);
  /**
  * @event beforeload
  * Fires before this node is loaded, return false to cancel
  * @param {Node} this This node
  */

  this.addEvents('beforeload', 'load');
  /**
  * @event load
  * Fires when this node is loaded
  * @param {Node} this This node
  */

  /**
   * The loader used by this node (defaults to using the tree's defined loader)
   * @type TreeLoader
   * @property loader
   */
};

Ext.extend(Ext.tree.AsyncTreeNode, Ext.tree.TreeNode, {
  expand: function expand(deep, anim, callback, scope) {
    if (this.loading) {
      // if an async load is already running, waiting til it's done
      var timer;

      var f = function () {
        if (!this.loading) {
          // done loading
          clearInterval(timer);
          this.expand(deep, anim, callback, scope);
        }
      }.createDelegate(this);

      timer = setInterval(f, 200);
      return;
    }

    if (!this.loaded) {
      if (this.fireEvent("beforeload", this) === false) {
        return;
      }

      this.loading = true;
      this.ui.beforeLoad(this);
      var loader = this.loader || this.attributes.loader || this.getOwnerTree().getLoader();

      if (loader) {
        loader.load(this, this.loadComplete.createDelegate(this, [deep, anim, callback, scope]), this);
        return;
      }
    }

    Ext.tree.AsyncTreeNode.superclass.expand.call(this, deep, anim, callback, scope);
  },

  /**
   * Returns true if this node is currently loading
   * @return {Boolean}
   */
  isLoading: function isLoading() {
    return this.loading;
  },
  loadComplete: function loadComplete(deep, anim, callback, scope) {
    this.loading = false;
    this.loaded = true;
    this.ui.afterLoad(this);
    this.fireEvent("load", this);
    this.expand(deep, anim, callback, scope);
  },

  /**
   * Returns true if this node has been loaded
   * @return {Boolean}
   */
  isLoaded: function isLoaded() {
    return this.loaded;
  },
  hasChildNodes: function hasChildNodes() {
    if (!this.isLeaf() && !this.loaded) {
      return true;
    } else {
      return Ext.tree.AsyncTreeNode.superclass.hasChildNodes.call(this);
    }
  },

  /**
   * Trigger a reload for this node
   * @param {Function} callback
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the callback is executed. Defaults to this Node.
   */
  reload: function reload(callback, scope) {
    this.collapse(false, false);

    while (this.firstChild) {
      this.removeChild(this.firstChild).destroy();
    }

    this.childrenRendered = false;
    this.loaded = false;

    if (this.isHiddenRoot()) {
      this.expanded = false;
    }

    this.expand(false, false, callback, scope);
  }
});
Ext.tree.TreePanel.nodeTypes.async = Ext.tree.AsyncTreeNode;

/***/ }),
/* 853 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeNodeUI
 * This class provides the default UI implementation for Ext TreeNodes.
 * The TreeNode UI implementation is separate from the
 * tree implementation, and allows customizing of the appearance of
 * tree nodes.<br>
 * <p>
 * If you are customizing the Tree's user interface, you
 * may need to extend this class, but you should never need to instantiate this class.<br>
 * <p>
 * This class provides access to the user interface components of an Ext TreeNode, through
 * {@link Ext.tree.TreeNode#getUI}
 */
Ext.tree.TreeNodeUI = function (node) {
  this.node = node;
  this.rendered = false;
  this.animating = false;
  this.wasLeaf = true;
  this.ecc = 'x-tree-ec-icon x-tree-elbow';
  this.emptyIcon = Ext.BLANK_IMAGE_URL;
};

Ext.tree.TreeNodeUI.prototype = {
  // private
  removeChild: function removeChild(node) {
    if (this.rendered) {
      this.ctNode.removeChild(node.ui.getEl());
    }
  },
  // private
  beforeLoad: function beforeLoad() {
    this.addClass("x-tree-node-loading");
  },
  // private
  afterLoad: function afterLoad() {
    this.removeClass("x-tree-node-loading");
  },
  // private
  onTextChange: function onTextChange(node, text, oldText) {
    if (this.rendered) {
      this.textNode.innerHTML = text;
    }
  },
  // private
  onDisableChange: function onDisableChange(node, state) {
    this.disabled = state;

    if (this.checkbox) {
      this.checkbox.disabled = state;
    }

    if (state) {
      this.addClass("x-tree-node-disabled");
    } else {
      this.removeClass("x-tree-node-disabled");
    }
  },
  // private
  onSelectedChange: function onSelectedChange(state, focus = true) {
    if (state) {
      if (focus) {
        this.focus();
      }

      this.addClass("x-tree-selected");
    } else {
      //this.blur();
      this.removeClass("x-tree-selected");
    }
  },
  // private
  onMove: function onMove(tree, node, oldParent, newParent, index, refNode) {
    this.childIndent = null;

    if (this.rendered) {
      var targetNode = newParent.ui.getContainer();

      if (!targetNode) {
        //target not rendered
        this.holder = document.createElement("div");
        this.holder.appendChild(this.wrap);
        return;
      }

      var insertBefore = refNode ? refNode.ui.getEl() : null;

      if (insertBefore) {
        targetNode.insertBefore(this.wrap, insertBefore);
      } else {
        targetNode.appendChild(this.wrap);
      }

      this.node.renderIndent(true, oldParent != newParent);
    }
  },

  /**
   * Adds one or more CSS classes to the node's UI element.
   * Duplicate classes are automatically filtered out.
   * @param {String/Array} className The CSS class to add, or an array of classes
   */
  addClass: function addClass(cls) {
    if (this.elNode) {
      Ext.fly(this.elNode).addClass(cls);
    }
  },

  /**
   * Removes one or more CSS classes from the node's UI element.
   * @param {String/Array} className The CSS class to remove, or an array of classes
   */
  removeClass: function removeClass(cls) {
    if (this.elNode) {
      Ext.fly(this.elNode).removeClass(cls);
    }
  },
  // private
  remove: function remove() {
    if (this.rendered) {
      this.holder = document.createElement("div");
      this.holder.appendChild(this.wrap);
    }
  },
  // private
  fireEvent: function fireEvent() {
    return this.node.fireEvent.apply(this.node, arguments);
  },
  // private
  initEvents: function initEvents() {
    this.node.on("move", this.onMove, this);

    if (this.node.disabled) {
      this.onDisableChange(this.node, true);
    }

    if (this.node.hidden) {
      this.hide();
    }

    var ot = this.node.getOwnerTree();
    var dd = ot.enableDD || ot.enableDrag || ot.enableDrop;

    if (dd && (!this.node.isRoot || ot.rootVisible)) {
      Ext.dd.Registry.register(this.elNode, {
        node: this.node,
        handles: this.getDDHandles(),
        isHandle: false
      });
    }
  },
  // private
  getDDHandles: function getDDHandles() {
    return [this.iconNode, this.textNode, this.elNode];
  },

  /**
   * Hides this node.
   */
  hide: function hide() {
    this.node.hidden = true;

    if (this.wrap) {
      this.wrap.style.display = "none";
    }
  },

  /**
   * Shows this node.
   */
  show: function show() {
    this.node.hidden = false;

    if (this.wrap) {
      this.wrap.style.display = "";
    }
  },
  // private
  onContextMenu: function onContextMenu(e) {
    if (this.node.hasListener("contextmenu") || this.node.getOwnerTree().hasListener("contextmenu")) {
      e.preventDefault();
      this.focus();
      this.fireEvent("contextmenu", this.node, e);
    }
  },
  // private
  onClick: function onClick(e) {
    if (this.dropping) {
      e.stopEvent();
      return;
    }

    if (this.fireEvent("beforeclick", this.node, e) !== false) {
      var a = e.getTarget('a');

      if (!this.disabled && this.node.attributes.href && a) {
        this.fireEvent("click", this.node, e);
        return;
      } else if (a && e.ctrlKey) {
        e.stopEvent();
      }

      e.preventDefault();

      if (this.disabled) {
        return;
      }

      if (this.node.attributes.singleClickExpand && !this.animating && this.node.isExpandable()) {
        this.node.toggle();
      }

      this.fireEvent("click", this.node, e);
    } else {
      e.stopEvent();
    }
  },
  // private
  onDblClick: function onDblClick(e) {
    e.preventDefault();

    if (this.disabled) {
      return;
    }

    if (this.fireEvent("beforedblclick", this.node, e) !== false) {
      if (this.checkbox) {
        this.toggleCheck();
      }

      if (!this.animating && this.node.isExpandable()) {
        this.node.toggle();
      }

      this.fireEvent("dblclick", this.node, e);
    }
  },
  onOver: function onOver(e) {
    this.addClass('x-tree-node-over');
  },
  onOut: function onOut(e) {
    this.removeClass('x-tree-node-over');
  },
  // private
  onCheckChange: function onCheckChange() {
    var checked = this.checkbox.checked; // fix for IE6

    this.checkbox.defaultChecked = checked;
    this.node.attributes.checked = checked;
    this.fireEvent('checkchange', this.node, checked);
  },
  // private
  ecClick: function ecClick(e) {
    if (!this.animating && this.node.isExpandable()) {
      this.node.toggle();
    }
  },
  // private
  startDrop: function startDrop() {
    this.dropping = true;
  },
  // delayed drop so the click event doesn't get fired on a drop
  endDrop: function endDrop() {
    setTimeout(function () {
      this.dropping = false;
    }.createDelegate(this), 50);
  },
  // private
  expand: function expand() {
    this.updateExpandIcon();
    this.ctNode.style.display = "";
  },
  // private
  focus: function focus() {
    if (!this.node.preventHScroll) {
      try {
        this.anchor.focus();
      } catch (e) {}
    } else {
      try {
        var noscroll = this.node.getOwnerTree().getTreeEl().dom;
        var l = noscroll.scrollLeft;
        this.anchor.focus();
        noscroll.scrollLeft = l;
      } catch (e) {}
    }
  },

  /**
   * Sets the checked status of the tree node to the passed value, or, if no value was passed,
   * toggles the checked status. If the node was rendered with no checkbox, this has no effect.
   * @param {Boolean} (optional) The new checked status.
   */
  toggleCheck: function toggleCheck(value) {
    var cb = this.checkbox;

    if (cb) {
      cb.checked = value === undefined ? !cb.checked : value;
      this.onCheckChange();
    }
  },
  // private
  blur: function blur() {
    try {
      this.anchor.blur();
    } catch (e) {}
  },
  // private
  animExpand: function animExpand(_callback) {
    var ct = Ext.get(this.ctNode);
    ct.stopFx();

    if (!this.node.isExpandable()) {
      this.updateExpandIcon();
      this.ctNode.style.display = "";
      Ext.callback(_callback);
      return;
    }

    this.animating = true;
    this.updateExpandIcon();
    ct.slideIn('t', {
      callback: function callback() {
        this.animating = false;
        Ext.callback(_callback);
      },
      scope: this,
      duration: this.node.ownerTree.duration || .25
    });
  },
  // private
  highlight: function highlight() {
    var tree = this.node.getOwnerTree();
    Ext.fly(this.wrap).highlight(tree.hlColor || "C3DAF9", {
      endColor: tree.hlBaseColor
    });
  },
  // private
  collapse: function collapse() {
    this.updateExpandIcon();
    this.ctNode.style.display = "none";
  },
  // private
  animCollapse: function animCollapse(_callback2) {
    var ct = Ext.get(this.ctNode);
    ct.enableDisplayMode('block');
    ct.stopFx();
    this.animating = true;
    this.updateExpandIcon();
    ct.slideOut('t', {
      callback: function callback() {
        this.animating = false;
        Ext.callback(_callback2);
      },
      scope: this,
      duration: this.node.ownerTree.duration || .25
    });
  },
  // private
  getContainer: function getContainer() {
    return this.ctNode;
  },

  /**
   * Returns the element which encapsulates this node.
   * @return {HtmlElement} The DOM element. The default implementation uses a <code>&lt;li></code>.
   */
  getEl: function getEl() {
    return this.wrap;
  },
  // private
  appendDDGhost: function appendDDGhost(ghostNode) {
    ghostNode.appendChild(this.elNode.cloneNode(true));
  },
  // private
  getDDRepairXY: function getDDRepairXY() {
    return Ext.lib.Dom.getXY(this.iconNode);
  },
  // private
  onRender: function onRender() {
    this.render();
  },
  // private
  render: function render(bulkRender) {
    var n = this.node,
        a = n.attributes;
    var targetNode = n.parentNode ? n.parentNode.ui.getContainer() : n.ownerTree.innerCt.dom;

    if (!this.rendered) {
      this.rendered = true;
      this.renderElements(n, a, targetNode, bulkRender);

      if (a.qtip) {
        if (this.textNode.setAttributeNS) {
          this.textNode.setAttributeNS("ext", "qtip", a.qtip);

          if (a.qtipTitle) {
            this.textNode.setAttributeNS("ext", "qtitle", a.qtipTitle);
          }
        } else {
          this.textNode.setAttribute("ext:qtip", a.qtip);

          if (a.qtipTitle) {
            this.textNode.setAttribute("ext:qtitle", a.qtipTitle);
          }
        }
      } else if (a.qtipCfg) {
        a.qtipCfg.target = Ext.id(this.textNode);
        Ext.QuickTips.register(a.qtipCfg);
      }

      this.initEvents();

      if (!this.node.expanded) {
        this.updateExpandIcon(true);
      }
    } else {
      if (bulkRender === true) {
        targetNode.appendChild(this.wrap);
      }
    }
  },
  // private
  renderElements: function renderElements(n, a, targetNode, bulkRender) {
    // add some indent caching, this helps performance when rendering a large tree
    this.indentMarkup = n.parentNode ? n.parentNode.ui.getChildIndent() : '';
    var cb = Ext.isBoolean(a.checked),
        nel,
        href = a.href ? a.href : Ext.isGecko ? "" : "#",
        buf = ['<li class="x-tree-node"><div ext:tree-node-id="', n.id, '" class="x-tree-node-el x-tree-node-leaf x-unselectable ', a.cls, '" unselectable="on">', '<span class="x-tree-node-indent">', this.indentMarkup, "</span>", '<img src="', this.emptyIcon, '" class="x-tree-ec-icon x-tree-elbow" />', '<img src="', a.icon || this.emptyIcon, '" class="x-tree-node-icon', a.icon ? " x-tree-node-inline-icon" : "", a.iconCls ? " " + a.iconCls : "", '" unselectable="on" />', cb ? '<input class="x-tree-node-cb" type="checkbox" ' + (a.checked ? 'checked="checked" />' : '/>') : '', '<a hidefocus="on" class="x-tree-node-anchor" href="', href, '" tabIndex="1" ', a.hrefTarget ? ' target="' + a.hrefTarget + '"' : "", '><span unselectable="on">', n.text, "</span></a></div>", '<ul class="x-tree-node-ct" style="display:none;"></ul>', "</li>"].join('');

    if (bulkRender !== true && n.nextSibling && (nel = n.nextSibling.ui.getEl())) {
      this.wrap = Ext.DomHelper.insertHtml("beforeBegin", nel, buf);
    } else {
      this.wrap = Ext.DomHelper.insertHtml("beforeEnd", targetNode, buf);
    }

    this.elNode = this.wrap.childNodes[0];
    this.ctNode = this.wrap.childNodes[1];
    var cs = this.elNode.childNodes;
    this.indentNode = cs[0];
    this.ecNode = cs[1];
    this.iconNode = cs[2];
    var index = 3;

    if (cb) {
      this.checkbox = cs[3]; // fix for IE6

      this.checkbox.defaultChecked = this.checkbox.checked;
      index++;
    }

    this.anchor = cs[index];
    this.textNode = cs[index].firstChild;
  },

  /**
   * Returns the &lt;a> element that provides focus for the node's UI.
   * @return {HtmlElement} The DOM anchor element.
   */
  getAnchor: function getAnchor() {
    return this.anchor;
  },

  /**
   * Returns the text node.
   * @return {HtmlNode} The DOM text node.
   */
  getTextEl: function getTextEl() {
    return this.textNode;
  },

  /**
   * Returns the icon &lt;img> element.
   * @return {HtmlElement} The DOM image element.
   */
  getIconEl: function getIconEl() {
    return this.iconNode;
  },

  /**
   * Returns the checked status of the node. If the node was rendered with no
   * checkbox, it returns false.
   * @return {Boolean} The checked flag.
   */
  isChecked: function isChecked() {
    return this.checkbox ? this.checkbox.checked : false;
  },
  // private
  updateExpandIcon: function updateExpandIcon() {
    if (this.rendered) {
      var n = this.node,
          c1,
          c2,
          cls = n.isLast() ? "x-tree-elbow-end" : "x-tree-elbow",
          hasChild = n.hasChildNodes();

      if (hasChild || n.attributes.expandable) {
        if (n.expanded) {
          cls += "-minus";
          c1 = "x-tree-node-collapsed";
          c2 = "x-tree-node-expanded";
        } else {
          cls += "-plus";
          c1 = "x-tree-node-expanded";
          c2 = "x-tree-node-collapsed";
        }

        if (this.wasLeaf) {
          this.removeClass("x-tree-node-leaf");
          this.wasLeaf = false;
        }

        if (this.c1 != c1 || this.c2 != c2) {
          Ext.fly(this.elNode).replaceClass(c1, c2);
          this.c1 = c1;
          this.c2 = c2;
        }
      } else {
        if (!this.wasLeaf) {
          Ext.fly(this.elNode).replaceClass("x-tree-node-expanded", "x-tree-node-collapsed");
          delete this.c1;
          delete this.c2;
          this.wasLeaf = true;
        }
      }

      var ecc = "x-tree-ec-icon " + cls;

      if (this.ecc != ecc) {
        this.ecNode.className = ecc;
        this.ecc = ecc;
      }
    }
  },
  // private
  onIdChange: function onIdChange(id) {
    if (this.rendered) {
      this.elNode.setAttribute('ext:tree-node-id', id);
    }
  },
  // private
  getChildIndent: function getChildIndent() {
    if (!this.childIndent) {
      var buf = [],
          p = this.node;

      while (p) {
        if (!p.isRoot || p.isRoot && p.ownerTree.rootVisible) {
          if (!p.isLast()) {
            buf.unshift('<img src="' + this.emptyIcon + '" class="x-tree-elbow-line" />');
          } else {
            buf.unshift('<img src="' + this.emptyIcon + '" class="x-tree-icon" />');
          }
        }

        p = p.parentNode;
      }

      this.childIndent = buf.join("");
    }

    return this.childIndent;
  },
  // private
  renderIndent: function renderIndent() {
    if (this.rendered) {
      var indent = "",
          p = this.node.parentNode;

      if (p) {
        indent = p.ui.getChildIndent();
      }

      if (this.indentMarkup != indent) {
        // don't rerender if not required
        this.indentNode.innerHTML = indent;
        this.indentMarkup = indent;
      }

      this.updateExpandIcon();
    }
  },
  destroy: function destroy() {
    if (this.elNode) {
      Ext.dd.Registry.unregister(this.elNode.id);
    }

    Ext.each(['textnode', 'anchor', 'checkbox', 'indentNode', 'ecNode', 'iconNode', 'elNode', 'ctNode', 'wrap', 'holder'], function (el) {
      if (this[el]) {
        Ext.fly(this[el]).remove();
        delete this[el];
      }
    }, this);
    delete this.node;
  }
};
/**
 * @class Ext.tree.RootTreeNodeUI
 * This class provides the default UI implementation for <b>root</b> Ext TreeNodes.
 * The RootTreeNode UI implementation allows customizing the appearance of the root tree node.<br>
 * <p>
 * If you are customizing the Tree's user interface, you
 * may need to extend this class, but you should never need to instantiate this class.<br>
 */

Ext.tree.RootTreeNodeUI = Ext.extend(Ext.tree.TreeNodeUI, {
  // private
  render: function render() {
    if (!this.rendered) {
      var targetNode = this.node.ownerTree.innerCt.dom;
      this.node.expanded = true;
      targetNode.innerHTML = '<div class="x-tree-root-node"></div>';
      this.wrap = this.ctNode = targetNode.firstChild;
    }
  },
  collapse: Ext.emptyFn,
  expand: Ext.emptyFn
});

/***/ }),
/* 854 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeLoader
 * @extends Ext.util.Observable
 * A TreeLoader provides for lazy loading of an {@link Ext.tree.TreeNode}'s child
 * nodes from a specified URL. The response must be a JavaScript Array definition
 * whose elements are node definition objects. e.g.:
 * <pre><code>
    [{
        id: 1,
        text: 'A leaf Node',
        leaf: true
    },{
        id: 2,
        text: 'A folder Node',
        children: [{
            id: 3,
            text: 'A child Node',
            leaf: true
        }]
   }]
</code></pre>
 * <br><br>
 * A server request is sent, and child nodes are loaded only when a node is expanded.
 * The loading node's id is passed to the server under the parameter name "node" to
 * enable the server to produce the correct child nodes.
 * <br><br>
 * To pass extra parameters, an event handler may be attached to the "beforeload"
 * event, and the parameters specified in the TreeLoader's baseParams property:
 * <pre><code>
    myTreeLoader.on("beforeload", function(treeLoader, node) {
        this.baseParams.category = node.attributes.category;
    }, this);
</code></pre>
 * This would pass an HTTP parameter called "category" to the server containing
 * the value of the Node's "category" attribute.
 * @constructor
 * Creates a new Treeloader.
 * @param {Object} config A config object containing config properties.
 */
Ext.tree.TreeLoader = function (config) {
  this.baseParams = {};
  Ext.apply(this, config);
  this.addEvents(
  /**
   * @event beforeload
   * Fires before a network request is made to retrieve the Json text which specifies a node's children.
   * @param {Object} This TreeLoader object.
   * @param {Object} node The {@link Ext.tree.TreeNode} object being loaded.
   * @param {Object} callback The callback function specified in the {@link #load} call.
   */
  "beforeload",
  /**
   * @event load
   * Fires when the node has been successfuly loaded.
   * @param {Object} This TreeLoader object.
   * @param {Object} node The {@link Ext.tree.TreeNode} object being loaded.
   * @param {Object} response The response object containing the data from the server.
   */
  "load",
  /**
   * @event loadexception
   * Fires if the network request failed.
   * @param {Object} This TreeLoader object.
   * @param {Object} node The {@link Ext.tree.TreeNode} object being loaded.
   * @param {Object} response The response object containing the data from the server.
   */
  "loadexception");
  Ext.tree.TreeLoader.superclass.constructor.call(this);

  if (Ext.isString(this.paramOrder)) {
    this.paramOrder = this.paramOrder.split(/[\s,|]/);
  }
};

Ext.extend(Ext.tree.TreeLoader, Ext.util.Observable, {
  /**
  * @cfg {String} dataUrl The URL from which to request a Json string which
  * specifies an array of node definition objects representing the child nodes
  * to be loaded.
  */

  /**
   * @cfg {String} requestMethod The HTTP request method for loading data (defaults to the value of {@link Ext.Ajax#method}).
   */

  /**
   * @cfg {String} url Equivalent to {@link #dataUrl}.
   */

  /**
   * @cfg {Boolean} preloadChildren If set to true, the loader recursively loads "children" attributes when doing the first load on nodes.
   */

  /**
  * @cfg {Object} baseParams (optional) An object containing properties which
  * specify HTTP parameters to be passed to each request for child nodes.
  */

  /**
  * @cfg {Object} baseAttrs (optional) An object containing attributes to be added to all nodes
  * created by this loader. If the attributes sent by the server have an attribute in this object,
  * they take priority.
  */

  /**
  * @cfg {Object} uiProviders (optional) An object containing properties which
  * specify custom {@link Ext.tree.TreeNodeUI} implementations. If the optional
  * <i>uiProvider</i> attribute of a returned child node is a string rather
  * than a reference to a TreeNodeUI implementation, then that string value
  * is used as a property name in the uiProviders object.
  */
  uiProviders: {},

  /**
  * @cfg {Boolean} clearOnLoad (optional) Default to true. Remove previously existing
  * child nodes before loading.
  */
  clearOnLoad: true,

  /**
   * @cfg {Array/String} paramOrder Defaults to <tt>undefined</tt>. Only used when using directFn.
   * Specifies the params in the order in which they must be passed to the server-side Direct method
   * as either (1) an Array of String values, or (2) a String of params delimited by either whitespace,
   * comma, or pipe. For example,
   * any of the following would be acceptable:<pre><code>
  nodeParameter: 'node',
  paramOrder: ['param1','param2','param3']
  paramOrder: 'node param1 param2 param3'
  paramOrder: 'param1,node,param2,param3'
  paramOrder: 'param1|param2|param|node'
   </code></pre>
   */
  paramOrder: undefined,

  /**
   * @cfg {Boolean} paramsAsHash Only used when using directFn.
   * Send parameters as a collection of named arguments (defaults to <tt>false</tt>). Providing a
   * <tt>{@link #paramOrder}</tt> nullifies this configuration.
   */
  paramsAsHash: false,

  /**
   * @cfg {String} nodeParameter The name of the parameter sent to the server which contains
   * the identifier of the node. Defaults to <tt>'node'</tt>.
   */
  nodeParameter: 'node',

  /**
   * @cfg {Function} directFn
   * Function to call when executing a request.
   */
  directFn: undefined,

  /**
   * Load an {@link Ext.tree.TreeNode} from the URL specified in the constructor.
   * This is called automatically when a node is expanded, but may be used to reload
   * a node (or append new children if the {@link #clearOnLoad} option is false.)
   * @param {Ext.tree.TreeNode} node
   * @param {Function} callback Function to call after the node has been loaded. The
   * function is passed the TreeNode which was requested to be loaded.
   * @param (Object) scope The cope (<code>this</code> reference) in which the callback is executed.
   * defaults to the loaded TreeNode.
   */
  load: function load(node, callback, scope) {
    if (this.clearOnLoad) {
      while (node.firstChild) {
        node.removeChild(node.firstChild);
      }
    }

    if (this.doPreload(node)) {
      // preloaded json children
      this.runCallback(callback, scope || node, [node]);
    } else if (this.directFn || this.dataUrl || this.url) {
      this.requestData(node, callback, scope || node);
    }
  },
  doPreload: function doPreload(node) {
    if (node.attributes.children) {
      if (node.childNodes.length < 1) {
        // preloaded?
        var cs = node.attributes.children;
        node.beginUpdate();

        for (var i = 0, len = cs.length; i < len; i++) {
          var cn = node.appendChild(this.createNode(cs[i]));

          if (this.preloadChildren) {
            this.doPreload(cn);
          }
        }

        node.endUpdate();
      }

      return true;
    }

    return false;
  },
  getParams: function getParams(node) {
    var bp = Ext.apply({}, this.baseParams),
        np = this.nodeParameter,
        po = this.paramOrder;
    np && (bp[np] = node.id);

    if (this.directFn) {
      var buf = [node.id];

      if (po) {
        // reset 'buf' if the nodeParameter was included in paramOrder
        if (np && po.indexOf(np) > -1) {
          buf = [];
        }

        for (var i = 0, len = po.length; i < len; i++) {
          buf.push(bp[po[i]]);
        }
      } else if (this.paramsAsHash) {
        buf = [bp];
      }

      return buf;
    } else {
      return bp;
    }
  },
  requestData: function requestData(node, callback, scope) {
    if (this.fireEvent("beforeload", this, node, callback) !== false) {
      if (this.directFn) {
        var args = this.getParams(node);
        args.push(this.processDirectResponse.createDelegate(this, [{
          callback: callback,
          node: node,
          scope: scope
        }], true));
        this.directFn.apply(window, args);
      } else {
        this.transId = Ext.Ajax.request({
          method: this.requestMethod,
          url: this.dataUrl || this.url,
          success: this.handleResponse,
          failure: this.handleFailure,
          scope: this,
          argument: {
            callback: callback,
            node: node,
            scope: scope
          },
          params: this.getParams(node)
        });
      }
    } else {
      // if the load is cancelled, make sure we notify
      // the node that we are done
      this.runCallback(callback, scope || node, []);
    }
  },
  processDirectResponse: function processDirectResponse(result, response, args) {
    if (response.status) {
      this.handleResponse({
        responseData: Ext.isArray(result) ? result : null,
        responseText: result,
        argument: args
      });
    } else {
      this.handleFailure({
        argument: args
      });
    }
  },
  // private
  runCallback: function runCallback(cb, scope, args) {
    if (Ext.isFunction(cb)) {
      cb.apply(scope, args);
    }
  },
  isLoading: function isLoading() {
    return !!this.transId;
  },
  abort: function abort() {
    if (this.isLoading()) {
      Ext.Ajax.abort(this.transId);
    }
  },

  /**
  * <p>Override this function for custom TreeNode node implementation, or to
  * modify the attributes at creation time.</p>
  * Example:<pre><code>
  new Ext.tree.TreePanel({
  ...
  loader: new Ext.tree.TreeLoader({
      url: 'dataUrl',
      createNode: function(attr) {
  //          Allow consolidation consignments to have
  //          consignments dropped into them.
          if (attr.isConsolidation) {
              attr.iconCls = 'x-consol',
              attr.allowDrop = true;
          }
          return Ext.tree.TreeLoader.prototype.createNode.call(this, attr);
      }
  }),
  ...
  });
  </code></pre>
  * @param attr {Object} The attributes from which to create the new node.
  */
  createNode: function createNode(attr) {
    // apply baseAttrs, nice idea Corey!
    if (this.baseAttrs) {
      Ext.applyIf(attr, this.baseAttrs);
    }

    if (this.applyLoader !== false && !attr.loader) {
      attr.loader = this;
    }

    if (Ext.isString(attr.uiProvider)) {
      attr.uiProvider = this.uiProviders[attr.uiProvider] || eval(attr.uiProvider);
    }

    if (attr.nodeType) {
      return new Ext.tree.TreePanel.nodeTypes[attr.nodeType](attr);
    } else {
      return attr.leaf ? new Ext.tree.TreeNode(attr) : new Ext.tree.AsyncTreeNode(attr);
    }
  },
  processResponse: function processResponse(response, node, callback, scope) {
    var json = response.responseText;

    try {
      var o = response.responseData || Ext.decode(json);
      node.beginUpdate();

      for (var i = 0, len = o.length; i < len; i++) {
        var n = this.createNode(o[i]);

        if (n) {
          node.appendChild(n);
        }
      }

      node.endUpdate();
      this.runCallback(callback, scope || node, [node]);
    } catch (e) {
      this.handleFailure(response);
    }
  },
  handleResponse: function handleResponse(response) {
    this.transId = false;
    var a = response.argument;
    this.processResponse(response, a.node, a.callback, a.scope);
    this.fireEvent("load", this, a.node, response);
  },
  handleFailure: function handleFailure(response) {
    this.transId = false;
    var a = response.argument;
    this.fireEvent("loadexception", this, a.node, response);
    this.runCallback(a.callback, a.scope || a.node, [a.node]);
  },
  destroy: function destroy() {
    this.abort();
    this.purgeListeners();
  }
});

/***/ }),
/* 855 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeFilter
 * Note this class is experimental and doesn't update the indent (lines) or expand collapse icons of the nodes
 * @param {TreePanel} tree
 * @param {Object} config (optional)
 */
Ext.tree.TreeFilter = function (tree, config) {
  this.tree = tree;
  this.filtered = {};
  Ext.apply(this, config);
};

Ext.tree.TreeFilter.prototype = {
  clearBlank: false,
  reverse: false,
  autoClear: false,
  remove: false,

  /**
  * Filter the data by a specific attribute.
  * @param {String/RegExp} value Either string that the attribute value
  * should start with or a RegExp to test against the attribute
  * @param {String} attr (optional) The attribute passed in your node's attributes collection. Defaults to "text".
  * @param {TreeNode} startNode (optional) The node to start the filter at.
  */
  filter: function filter(value, attr, startNode) {
    attr = attr || "text";
    var f;

    if (typeof value == "string") {
      var vlen = value.length; // auto clear empty filter

      if (vlen == 0 && this.clearBlank) {
        this.clear();
        return;
      }

      value = value.toLowerCase();

      f = function f(n) {
        return n.attributes[attr].substr(0, vlen).toLowerCase() == value;
      };
    } else if (value.exec) {
      // regex?
      f = function f(n) {
        return value.test(n.attributes[attr]);
      };
    } else {
      throw 'Illegal filter type, must be string or regex';
    }

    this.filterBy(f, null, startNode);
  },

  /**
   * Filter by a function. The passed function will be called with each
   * node in the tree (or from the startNode). If the function returns true, the node is kept
   * otherwise it is filtered. If a node is filtered, its children are also filtered.
   * @param {Function} fn The filter function
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to the current Node.
   */
  filterBy: function filterBy(fn, scope, startNode) {
    startNode = startNode || this.tree.root;

    if (this.autoClear) {
      this.clear();
    }

    var af = this.filtered,
        rv = this.reverse;

    var f = function f(n) {
      if (n == startNode) {
        return true;
      }

      if (af[n.id]) {
        return false;
      }

      var m = fn.call(scope || n, n);

      if (!m || rv) {
        af[n.id] = n;
        n.ui.hide();
        return false;
      }

      return true;
    };

    startNode.cascade(f);

    if (this.remove) {
      for (var id in af) {
        if (typeof id != "function") {
          var n = af[id];

          if (n && n.parentNode) {
            n.parentNode.removeChild(n);
          }
        }
      }
    }
  },

  /**
   * Clears the current filter. Note: with the "remove" option
   * set a filter cannot be cleared.
   */
  clear: function clear() {
    var t = this.tree;
    var af = this.filtered;

    for (var id in af) {
      if (typeof id != "function") {
        var n = af[id];

        if (n) {
          n.ui.show();
        }
      }
    }

    this.filtered = {};
  }
};

/***/ }),
/* 856 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeSorter
 * Provides sorting of nodes in a {@link Ext.tree.TreePanel}.  The TreeSorter automatically monitors events on the
 * associated TreePanel that might affect the tree's sort order (beforechildrenrendered, append, insert and textchange).
 * Example usage:<br />
 * <pre><code>
new Ext.tree.TreeSorter(myTree, {
    folderSort: true,
    dir: "desc",
    sortType: function(node) {
        // sort by a custom, typed attribute:
        return parseInt(node.id, 10);
    }
});
</code></pre>
 * @constructor
 * @param {TreePanel} tree
 * @param {Object} config
 */
Ext.tree.TreeSorter = function (tree, config) {
  /**
   * @cfg {Boolean} folderSort True to sort leaf nodes under non-leaf nodes (defaults to false)
   */

  /**
   * @cfg {String} property The named attribute on the node to sort by (defaults to "text").  Note that this
   * property is only used if no {@link #sortType} function is specified, otherwise it is ignored.
   */

  /**
   * @cfg {String} dir The direction to sort ("asc" or "desc," case-insensitive, defaults to "asc")
   */

  /**
   * @cfg {String} leafAttr The attribute used to determine leaf nodes when {@link #folderSort} = true (defaults to "leaf")
   */

  /**
   * @cfg {Boolean} caseSensitive true for case-sensitive sort (defaults to false)
   */

  /**
   * @cfg {Function} sortType A custom "casting" function used to convert node values before sorting.  The function
   * will be called with a single parameter (the {@link Ext.tree.TreeNode} being evaluated) and is expected to return
   * the node's sort value cast to the specific data type required for sorting.  This could be used, for example, when
   * a node's text (or other attribute) should be sorted as a date or numeric value.  See the class description for
   * example usage.  Note that if a sortType is specified, any {@link #property} config will be ignored.
   */
  Ext.apply(this, config);
  tree.on("beforechildrenrendered", this.doSort, this);
  tree.on("append", this.updateSort, this);
  tree.on("insert", this.updateSort, this);
  tree.on("textchange", this.updateSortParent, this);
  var dsc = this.dir && this.dir.toLowerCase() == "desc";
  var p = this.property || "text";
  var sortType = this.sortType;
  var fs = this.folderSort;
  var cs = this.caseSensitive === true;
  var leafAttr = this.leafAttr || 'leaf';

  this.sortFn = function (n1, n2) {
    if (fs) {
      if (n1.attributes[leafAttr] && !n2.attributes[leafAttr]) {
        return 1;
      }

      if (!n1.attributes[leafAttr] && n2.attributes[leafAttr]) {
        return -1;
      }
    }

    var v1 = sortType ? sortType(n1) : cs ? n1.attributes[p] : n1.attributes[p].toUpperCase();
    var v2 = sortType ? sortType(n2) : cs ? n2.attributes[p] : n2.attributes[p].toUpperCase();

    if (v1 < v2) {
      return dsc ? +1 : -1;
    } else if (v1 > v2) {
      return dsc ? -1 : +1;
    } else {
      return 0;
    }
  };
};

Ext.tree.TreeSorter.prototype = {
  doSort: function doSort(node) {
    node.sort(this.sortFn);
  },
  compareNodes: function compareNodes(n1, n2) {
    return n1.text.toUpperCase() > n2.text.toUpperCase() ? 1 : -1;
  },
  updateSort: function updateSort(tree, node) {
    if (node.childrenRendered) {
      this.doSort.defer(1, this, [node]);
    }
  },
  updateSortParent: function updateSortParent(node) {
    var p = node.parentNode;

    if (p && p.childrenRendered) {
      this.doSort.defer(1, this, [p]);
    }
  }
};

/***/ }),
/* 857 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeDropZone
 * @extends Ext.dd.DropZone
 * @constructor
 * @param {String/HTMLElement/Element} tree The {@link Ext.tree.TreePanel} for which to enable dropping
 * @param {Object} config
 */
if (Ext.dd.DropZone) {
  Ext.tree.TreeDropZone = function (tree, config) {
    /**
     * @cfg {Boolean} allowParentInsert
     * Allow inserting a dragged node between an expanded parent node and its first child that will become a
     * sibling of the parent when dropped (defaults to false)
     */
    this.allowParentInsert = config.allowParentInsert || false;
    /**
     * @cfg {String} allowContainerDrop
     * True if drops on the tree container (outside of a specific tree node) are allowed (defaults to false)
     */

    this.allowContainerDrop = config.allowContainerDrop || false;
    /**
     * @cfg {String} appendOnly
     * True if the tree should only allow append drops (use for trees which are sorted, defaults to false)
     */

    this.appendOnly = config.appendOnly || false;
    Ext.tree.TreeDropZone.superclass.constructor.call(this, tree.getTreeEl(), config);
    /**
    * The TreePanel for this drop zone
    * @type Ext.tree.TreePanel
    * @property
    */

    this.tree = tree;
    /**
    * Arbitrary data that can be associated with this tree and will be included in the event object that gets
    * passed to any nodedragover event handler (defaults to {})
    * @type Ext.tree.TreePanel
    * @property
    */

    this.dragOverData = {}; // private

    this.lastInsertClass = "x-tree-no-status";
  };

  Ext.extend(Ext.tree.TreeDropZone, Ext.dd.DropZone, {
    /**
     * @cfg {String} ddGroup
     * A named drag drop group to which this object belongs.  If a group is specified, then this object will only
     * interact with other drag drop objects in the same group (defaults to 'TreeDD').
     */
    ddGroup: "TreeDD",

    /**
     * @cfg {String} expandDelay
     * The delay in milliseconds to wait before expanding a target tree node while dragging a droppable node
     * over the target (defaults to 1000)
     */
    expandDelay: 1000,
    // private
    expandNode: function expandNode(node) {
      if (node.hasChildNodes() && !node.isExpanded()) {
        node.expand(false, null, this.triggerCacheRefresh.createDelegate(this));
      }
    },
    // private
    queueExpand: function queueExpand(node) {
      this.expandProcId = this.expandNode.defer(this.expandDelay, this, [node]);
    },
    // private
    cancelExpand: function cancelExpand() {
      if (this.expandProcId) {
        clearTimeout(this.expandProcId);
        this.expandProcId = false;
      }
    },
    // private
    isValidDropPoint: function isValidDropPoint(n, pt, dd, e, data) {
      if (!n || !data) {
        return false;
      }

      var targetNode = n.node;
      var dropNode = data.node; // default drop rules

      if (!(targetNode && targetNode.isTarget && pt)) {
        return false;
      }

      if (pt == "append" && targetNode.allowChildren === false) {
        return false;
      }

      if ((pt == "above" || pt == "below") && targetNode.parentNode && targetNode.parentNode.allowChildren === false) {
        return false;
      }

      if (dropNode && (targetNode == dropNode || dropNode.contains(targetNode))) {
        return false;
      } // reuse the object


      var overEvent = this.dragOverData;
      overEvent.tree = this.tree;
      overEvent.target = targetNode;
      overEvent.data = data;
      overEvent.point = pt;
      overEvent.source = dd;
      overEvent.rawEvent = e;
      overEvent.dropNode = dropNode;
      overEvent.cancel = false;
      var result = this.tree.fireEvent("nodedragover", overEvent);
      return overEvent.cancel === false && result !== false;
    },
    // private
    getDropPoint: function getDropPoint(e, n, dd) {
      var tn = n.node;

      if (tn.isRoot) {
        return tn.allowChildren !== false ? "append" : false; // always append for root
      }

      var dragEl = n.ddel;
      var t = Ext.lib.Dom.getY(dragEl),
          b = t + dragEl.offsetHeight;
      var y = Ext.lib.Event.getPageY(e);
      var noAppend = tn.allowChildren === false || tn.isLeaf();

      if (this.appendOnly || tn.parentNode.allowChildren === false) {
        return noAppend ? false : "append";
      }

      var noBelow = false;

      if (!this.allowParentInsert) {
        noBelow = tn.hasChildNodes() && tn.isExpanded();
      }

      var q = (b - t) / (noAppend ? 2 : 3);

      if (y >= t && y < t + q) {
        return "above";
      } else if (!noBelow && (noAppend || y >= b - q && y <= b)) {
        return "below";
      } else {
        return "append";
      }
    },
    // private
    onNodeEnter: function onNodeEnter(n, dd, e, data) {
      this.cancelExpand();
    },
    onContainerOver: function onContainerOver(dd, e, data) {
      if (this.allowContainerDrop && this.isValidDropPoint({
        ddel: this.tree.getRootNode().ui.elNode,
        node: this.tree.getRootNode()
      }, "append", dd, e, data)) {
        return this.dropAllowed;
      }

      return this.dropNotAllowed;
    },
    // private
    onNodeOver: function onNodeOver(n, dd, e, data) {
      var pt = this.getDropPoint(e, n, dd);
      var node = n.node; // auto node expand check

      if (!this.expandProcId && pt == "append" && node.hasChildNodes() && !n.node.isExpanded()) {
        this.queueExpand(node);
      } else if (pt != "append") {
        this.cancelExpand();
      } // set the insert point style on the target node


      var returnCls = this.dropNotAllowed;

      if (this.isValidDropPoint(n, pt, dd, e, data)) {
        if (pt) {
          var el = n.ddel;
          var cls;

          if (pt == "above") {
            returnCls = n.node.isFirst() ? "x-tree-drop-ok-above" : "x-tree-drop-ok-between";
            cls = "x-tree-drag-insert-above";
          } else if (pt == "below") {
            returnCls = n.node.isLast() ? "x-tree-drop-ok-below" : "x-tree-drop-ok-between";
            cls = "x-tree-drag-insert-below";
          } else {
            returnCls = "x-tree-drop-ok-append";
            cls = "x-tree-drag-append";
          }

          if (this.lastInsertClass != cls) {
            Ext.fly(el).replaceClass(this.lastInsertClass, cls);
            this.lastInsertClass = cls;
          }
        }
      }

      return returnCls;
    },
    // private
    onNodeOut: function onNodeOut(n, dd, e, data) {
      this.cancelExpand();
      this.removeDropIndicators(n);
    },
    // private
    onNodeDrop: function onNodeDrop(n, dd, e, data) {
      var point = this.getDropPoint(e, n, dd);
      var targetNode = n.node;
      targetNode.ui.startDrop();

      if (!this.isValidDropPoint(n, point, dd, e, data)) {
        targetNode.ui.endDrop();
        return false;
      } // first try to find the drop node


      var dropNode = data.node || (dd.getTreeNode ? dd.getTreeNode(data, targetNode, point, e) : null);
      return this.processDrop(targetNode, data, point, dd, e, dropNode);
    },
    onContainerDrop: function onContainerDrop(dd, e, data) {
      if (this.allowContainerDrop && this.isValidDropPoint({
        ddel: this.tree.getRootNode().ui.elNode,
        node: this.tree.getRootNode()
      }, "append", dd, e, data)) {
        var targetNode = this.tree.getRootNode();
        targetNode.ui.startDrop();
        var dropNode = data.node || (dd.getTreeNode ? dd.getTreeNode(data, targetNode, 'append', e) : null);
        return this.processDrop(targetNode, data, 'append', dd, e, dropNode);
      }

      return false;
    },
    // private
    processDrop: function processDrop(target, data, point, dd, e, dropNode) {
      var dropEvent = {
        tree: this.tree,
        target: target,
        data: data,
        point: point,
        source: dd,
        rawEvent: e,
        dropNode: dropNode,
        cancel: !dropNode,
        dropStatus: false
      };
      var retval = this.tree.fireEvent("beforenodedrop", dropEvent);

      if (retval === false || dropEvent.cancel === true || !dropEvent.dropNode) {
        target.ui.endDrop();
        return dropEvent.dropStatus;
      }

      target = dropEvent.target;

      if (point == 'append' && !target.isExpanded()) {
        target.expand(false, null, function () {
          this.completeDrop(dropEvent);
        }.createDelegate(this));
      } else {
        this.completeDrop(dropEvent);
      }

      return true;
    },
    // private
    completeDrop: function completeDrop(de) {
      var ns = de.dropNode,
          p = de.point,
          t = de.target;

      if (!Ext.isArray(ns)) {
        ns = [ns];
      }

      var n;

      for (var i = 0, len = ns.length; i < len; i++) {
        n = ns[i];

        if (p == "above") {
          t.parentNode.insertBefore(n, t);
        } else if (p == "below") {
          t.parentNode.insertBefore(n, t.nextSibling);
        } else {
          t.appendChild(n);
        }
      }

      n.ui.focus();

      if (Ext.enableFx && this.tree.hlDrop) {
        n.ui.highlight();
      }

      t.ui.endDrop();
      this.tree.fireEvent("nodedrop", de);
    },
    // private
    afterNodeMoved: function afterNodeMoved(dd, data, e, targetNode, dropNode) {
      if (Ext.enableFx && this.tree.hlDrop) {
        dropNode.ui.focus();
        dropNode.ui.highlight();
      }

      this.tree.fireEvent("nodedrop", this.tree, targetNode, data, dd, e);
    },
    // private
    getTree: function getTree() {
      return this.tree;
    },
    // private
    removeDropIndicators: function removeDropIndicators(n) {
      if (n && n.ddel) {
        var el = n.ddel;
        Ext.fly(el).removeClass(["x-tree-drag-insert-above", "x-tree-drag-insert-below", "x-tree-drag-append"]);
        this.lastInsertClass = "_noclass";
      }
    },
    // private
    beforeDragDrop: function beforeDragDrop(target, e, id) {
      this.cancelExpand();
      return true;
    },
    // private
    afterRepair: function afterRepair(data) {
      if (data && Ext.enableFx) {
        data.node.ui.highlight();
      }

      this.hideProxy();
    }
  });
}

/***/ }),
/* 858 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeDragZone
 * @extends Ext.dd.DragZone
 * @constructor
 * @param {String/HTMLElement/Element} tree The {@link Ext.tree.TreePanel} for which to enable dragging
 * @param {Object} config
 */
if (Ext.dd.DragZone) {
  Ext.tree.TreeDragZone = function (tree, config) {
    Ext.tree.TreeDragZone.superclass.constructor.call(this, tree.innerCt, config);
    /**
    * The TreePanel for this drag zone
    * @type Ext.tree.TreePanel
    * @property
    */

    this.tree = tree;
  };

  Ext.extend(Ext.tree.TreeDragZone, Ext.dd.DragZone, {
    /**
     * @cfg {String} ddGroup
     * A named drag drop group to which this object belongs.  If a group is specified, then this object will only
     * interact with other drag drop objects in the same group (defaults to 'TreeDD').
     */
    ddGroup: "TreeDD",
    // private
    onBeforeDrag: function onBeforeDrag(data, e) {
      var n = data.node;
      return n && n.draggable && !n.disabled;
    },
    // private
    onInitDrag: function onInitDrag(e) {
      var data = this.dragData; // if user wants to select he clicks instead of drages!
      // this.tree.getSelectionModel().select(data.node);

      this.tree.eventModel.disable();
      this.proxy.update("");
      data.node.ui.appendDDGhost(this.proxy.ghost.dom);
      this.tree.fireEvent("startdrag", this.tree, data.node, e);
    },
    // private
    getRepairXY: function getRepairXY(e, data) {
      return data.node.ui.getDDRepairXY();
    },
    // private
    onEndDrag: function onEndDrag(data, e) {
      this.tree.eventModel.enable.defer(100, this.tree.eventModel);
      this.tree.fireEvent("enddrag", this.tree, data.node, e);
    },
    // private
    onValidDrop: function onValidDrop(dd, e, id) {
      this.tree.fireEvent("dragdrop", this.tree, this.dragData.node, dd, e);
      this.hideProxy();
    },
    // private
    beforeInvalidDrop: function beforeInvalidDrop(e, id) {// this scrolls the original position back into view
      // var sm = this.tree.getSelectionModel();
      // sm.clearSelections();
      // sm.select(this.dragData.node);
    },
    // private
    afterRepair: function afterRepair() {
      if (Ext.enableFx && this.tree.hlDrop) {
        Ext.Element.fly(this.dragData.ddel).highlight(this.hlColor || "c3daf9");
      }

      this.dragging = false;
    }
  });
}

/***/ }),
/* 859 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.TreeEditor
 * @extends Ext.Editor
 * Provides editor functionality for inline tree node editing.  Any valid {@link Ext.form.Field} subclass can be used
 * as the editor field.
 * @constructor
 * @param {TreePanel} tree
 * @param {Object} fieldConfig (optional) Either a prebuilt {@link Ext.form.Field} instance or a Field config object
 * that will be applied to the default field instance (defaults to a {@link Ext.form.TextField}).
 * @param {Object} config (optional) A TreeEditor config object
 */
Ext.tree.TreeEditor = function (tree, fc, config) {
  fc = fc || {};
  var field = fc.events ? fc : new Ext.form.TextField(fc);
  Ext.tree.TreeEditor.superclass.constructor.call(this, field, config);
  this.tree = tree;

  if (!tree.rendered) {
    tree.on('render', this.initEditor, this);
  } else {
    this.initEditor(tree);
  }
};

Ext.extend(Ext.tree.TreeEditor, Ext.Editor, {
  /**
   * @cfg {String} alignment
   * The position to align to (see {@link Ext.Element#alignTo} for more details, defaults to "l-l").
   */
  alignment: "l-l",
  // inherit
  autoSize: false,

  /**
   * @cfg {Boolean} hideEl
   * True to hide the bound element while the editor is displayed (defaults to false)
   */
  hideEl: false,

  /**
   * @cfg {String} cls
   * CSS class to apply to the editor (defaults to "x-small-editor x-tree-editor")
   */
  cls: "x-small-editor x-tree-editor",

  /**
   * @cfg {Boolean} shim
   * True to shim the editor if selects/iframes could be displayed beneath it (defaults to false)
   */
  shim: false,
  // inherit
  shadow: "frame",

  /**
   * @cfg {Number} maxWidth
   * The maximum width in pixels of the editor field (defaults to 250).  Note that if the maxWidth would exceed
   * the containing tree element's size, it will be automatically limited for you to the container width, taking
   * scroll and client offsets into account prior to each edit.
   */
  maxWidth: 250,

  /**
   * @cfg {Number} editDelay The number of milliseconds between clicks to register a double-click that will trigger
   * editing on the current node (defaults to 350).  If two clicks occur on the same node within this time span,
   * the editor for the node will display, otherwise it will be processed as a regular click.
   */
  editDelay: 350,
  initEditor: function initEditor(tree) {
    tree.on({
      scope: this,
      beforeclick: this.beforeNodeClick,
      dblclick: this.onNodeDblClick
    });
    this.on({
      scope: this,
      complete: this.updateNode,
      beforestartedit: this.fitToTree,
      specialkey: this.onSpecialKey
    });
    this.on('startedit', this.bindScroll, this, {
      delay: 10
    });
  },
  // private
  fitToTree: function fitToTree(ed, el) {
    var td = this.tree.getTreeEl().dom,
        nd = el.dom;

    if (td.scrollLeft > nd.offsetLeft) {
      // ensure the node left point is visible
      td.scrollLeft = nd.offsetLeft;
    }

    var w = Math.min(this.maxWidth, (td.clientWidth > 20 ? td.clientWidth : td.offsetWidth) - Math.max(0, nd.offsetLeft - td.scrollLeft) -
    /*cushion*/
    5);
    this.setSize(w, '');
  },

  /**
   * Edit the text of the passed {@link Ext.tree.TreeNode TreeNode}.
   * @param node {Ext.tree.TreeNode} The TreeNode to edit. The TreeNode must be {@link Ext.tree.TreeNode#editable editable}.
   */
  triggerEdit: function triggerEdit(node, defer) {
    this.completeEdit();

    if (node.attributes.editable !== false) {
      /**
       * The {@link Ext.tree.TreeNode TreeNode} this editor is bound to. Read-only.
       * @type Ext.tree.TreeNode
       * @property editNode
       */
      this.editNode = node;

      if (this.tree.autoScroll) {
        Ext.fly(node.ui.getEl()).scrollIntoView(this.tree.body);
      }

      var value = node.text || '';

      if (!Ext.isGecko && Ext.isEmpty(node.text)) {
        node.setText('&#160;');
      }

      this.autoEditTimer = this.startEdit.defer(this.editDelay, this, [node.ui.textNode, value]);
      return false;
    }
  },
  // private
  bindScroll: function bindScroll() {
    this.tree.getTreeEl().on('scroll', this.cancelEdit, this);
  },
  // private
  beforeNodeClick: function beforeNodeClick(node, e) {
    clearTimeout(this.autoEditTimer);

    if (this.tree.getSelectionModel().isSelected(node)) {
      e.stopEvent();
      return this.triggerEdit(node);
    }
  },
  onNodeDblClick: function onNodeDblClick(node, e) {
    clearTimeout(this.autoEditTimer);
  },
  // private
  updateNode: function updateNode(ed, value) {
    this.tree.getTreeEl().un('scroll', this.cancelEdit, this);
    this.editNode.setText(value);
  },
  // private
  onHide: function onHide() {
    Ext.tree.TreeEditor.superclass.onHide.call(this);

    if (this.editNode) {
      this.editNode.ui.focus.defer(50, this.editNode.ui);
    }
  },
  // private
  onSpecialKey: function onSpecialKey(field, e) {
    var k = e.getKey();

    if (k == e.ESC) {
      e.stopEvent();
      this.cancelEdit();
    } else if (k == e.ENTER && !e.hasModifier()) {
      e.stopEvent();
      this.completeEdit();
    }
  },
  onDestroy: function onDestroy() {
    clearTimeout(this.autoEditTimer);
    Ext.tree.TreeEditor.superclass.onDestroy.call(this);
    var tree = this.tree;
    tree.un('beforeclick', this.beforeNodeClick, this);
    tree.un('dblclick', this.onNodeDblClick, this);
  }
});

/***/ }),
/* 860 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.Menu
 * @extends Ext.Container
 * <p>A menu object.  This is the container to which you may add menu items.  Menu can also serve as a base class
 * when you want a specialized menu based off of another component (like {@link Ext.menu.DateMenu} for example).</p>
 * <p>Menus may contain either {@link Ext.menu.Item menu items}, or general {@link Ext.Component Component}s.</p>
 * <p>To make a contained general {@link Ext.Component Component} line up with other {@link Ext.menu.Item menu items}
 * specify <tt>iconCls: 'no-icon'</tt>.  This reserves a space for an icon, and indents the Component in line
 * with the other menu items.  See {@link Ext.form.ComboBox}.{@link Ext.form.ComboBox#getListParent getListParent}
 * for an example.</p>
 * <p>By default, Menus are absolutely positioned, floating Components. By configuring a Menu with
 * <b><tt>{@link #floating}:false</tt></b>, a Menu may be used as child of a Container.</p>
 *
 * @xtype menu
 */
Ext.menu.Menu = Ext.extend(Ext.Container, {
  /**
   * @cfg {Object} defaults
   * A config object that will be applied to all items added to this container either via the {@link #items}
   * config or via the {@link #add} method.  The defaults config can contain any number of
   * name/value property pairs to be added to each item, and should be valid for the types of items
   * being added to the menu.
   */

  /**
   * @cfg {Mixed} items
   * An array of items to be added to this menu. Menus may contain either {@link Ext.menu.Item menu items},
   * or general {@link Ext.Component Component}s.
   */

  /**
   * @cfg {Number} minWidth The minimum width of the menu in pixels (defaults to 120)
   */
  minWidth: 120,

  /**
   * @cfg {Boolean/String} shadow True or 'sides' for the default effect, 'frame' for 4-way shadow, and 'drop'
   * for bottom-right shadow (defaults to 'sides')
   */
  shadow: 'sides',

  /**
   * @cfg {String} subMenuAlign The {@link Ext.Element#alignTo} anchor position value to use for submenus of
   * this menu (defaults to 'tl-tr?')
   */
  subMenuAlign: 'tl-tr?',

  /**
   * @cfg {String} defaultAlign The default {@link Ext.Element#alignTo} anchor position value for this menu
   * relative to its element of origin (defaults to 'tl-bl?')
   */
  defaultAlign: 'tl-bl?',

  /**
   * @cfg {Boolean} allowOtherMenus True to allow multiple menus to be displayed at the same time (defaults to false)
   */
  allowOtherMenus: false,

  /**
   * @cfg {Boolean} ignoreParentClicks True to ignore clicks on any item in this menu that is a parent item (displays
   * a submenu) so that the submenu is not dismissed when clicking the parent item (defaults to false).
   */
  ignoreParentClicks: false,

  /**
   * @cfg {Boolean} enableScrolling True to allow the menu container to have scroller controls if the menu is too long (defaults to true).
   */
  enableScrolling: true,

  /**
   * @cfg {Number} maxHeight The maximum height of the menu. Only applies when enableScrolling is set to True (defaults to null).
   */
  maxHeight: null,

  /**
   * @cfg {Number} scrollIncrement The amount to scroll the menu. Only applies when enableScrolling is set to True (defaults to 24).
   */
  scrollIncrement: 24,

  /**
   * @cfg {Boolean} showSeparator True to show the icon separator. (defaults to true).
   */
  showSeparator: true,

  /**
   * @cfg {Array} defaultOffsets An array specifying the [x, y] offset in pixels by which to
   * change the default Menu popup position after aligning according to the {@link #defaultAlign}
   * configuration. Defaults to <tt>[0, 0]</tt>.
   */
  defaultOffsets: [0, 0],

  /**
   * @cfg {Boolean} plain
   * True to remove the incised line down the left side of the menu. Defaults to <tt>false</tt>.
   */
  plain: false,

  /**
   * @cfg {Boolean} floating
   * <p>By default, a Menu configured as <b><code>floating:true</code></b>
   * will be rendered as an {@link Ext.Layer} (an absolutely positioned,
   * floating Component with zindex=15000).
   * If configured as <b><code>floating:false</code></b>, the Menu may be
   * used as child item of another Container instead of a free-floating
   * {@link Ext.Layer Layer}.
   */
  floating: true,

  /**
   * @cfg {Number} zIndex
   * zIndex to use when the menu is floating.
   */
  zIndex: 15000,
  // private
  hidden: true,

  /**
   * @cfg {String/Object} layout
   * This class assigns a default layout (<code>layout:'<b>menu</b>'</code>).
   * Developers <i>may</i> override this configuration option if another layout is required.
   * See {@link Ext.Container#layout} for additional information.
   */
  layout: 'menu',
  hideMode: 'offsets',
  // Important for laying out Components
  scrollerHeight: 8,
  autoLayout: true,
  // Provided for backwards compat
  defaultType: 'menuitem',
  bufferResize: false,
  initComponent: function initComponent() {
    if (Ext.isArray(this.initialConfig)) {
      Ext.apply(this, {
        items: this.initialConfig
      });
    }

    this.addEvents(
    /**
     * @event click
     * Fires when this menu is clicked (or when the enter key is pressed while it is active)
     * @param {Ext.menu.Menu} this
    * @param {Ext.menu.Item} menuItem The menu item that was clicked
     * @param {Ext.EventObject} e
     */
    'click',
    /**
     * @event mouseover
     * Fires when the mouse is hovering over this menu
     * @param {Ext.menu.Menu} this
     * @param {Ext.EventObject} e
     * @param {Ext.menu.Item} menuItem The menu item that was clicked
     */
    'mouseover',
    /**
     * @event mouseout
     * Fires when the mouse exits this menu
     * @param {Ext.menu.Menu} this
     * @param {Ext.EventObject} e
     * @param {Ext.menu.Item} menuItem The menu item that was clicked
     */
    'mouseout',
    /**
     * @event itemclick
     * Fires when a menu item contained in this menu is clicked
     * @param {Ext.menu.BaseItem} baseItem The BaseItem that was clicked
     * @param {Ext.EventObject} e
     */
    'itemclick');
    Ext.menu.MenuMgr.register(this);

    if (this.floating) {
      Ext.EventManager.onWindowResize(this.hide, this);
    } else {
      if (this.initialConfig.hidden !== false) {
        this.hidden = false;
      }

      this.internalDefaults = {
        hideOnClick: false
      };
    }

    Ext.menu.Menu.superclass.initComponent.call(this);

    if (this.autoLayout) {
      var fn = this.doLayout.createDelegate(this, []);
      this.on({
        add: fn,
        remove: fn
      });
    }
  },
  //private
  getLayoutTarget: function getLayoutTarget() {
    return this.ul;
  },
  // private
  onRender: function onRender(ct, position) {
    if (!ct) {
      ct = Ext.getBody();
    }

    var dh = {
      id: this.getId(),
      cls: 'x-menu ' + (this.floating ? 'x-menu-floating x-layer ' : '') + (this.cls || '') + (this.plain ? ' x-menu-plain' : '') + (this.showSeparator ? '' : ' x-menu-nosep'),
      style: this.style,
      cn: [{
        tag: 'a',
        cls: 'x-menu-focus',
        href: '#',
        onclick: 'return false;',
        tabIndex: '-1'
      }, {
        tag: 'ul',
        cls: 'x-menu-list'
      }]
    };

    if (this.floating) {
      this.el = new Ext.Layer({
        shadow: this.shadow,
        dh: dh,
        constrain: false,
        parentEl: ct,
        zindex: this.zIndex
      });
    } else {
      this.el = ct.createChild(dh);
    }

    Ext.menu.Menu.superclass.onRender.call(this, ct, position);

    if (!this.keyNav) {
      this.keyNav = new Ext.menu.MenuNav(this);
    } // generic focus element


    this.focusEl = this.el.child('a.x-menu-focus');
    this.ul = this.el.child('ul.x-menu-list');
    this.mon(this.ul, {
      scope: this,
      click: this.onClick,
      mouseover: this.onMouseOver,
      mouseout: this.onMouseOut
    });

    if (this.enableScrolling) {
      this.mon(this.el, {
        scope: this,
        delegate: '.x-menu-scroller',
        click: this.onScroll,
        mouseover: this.deactivateActive
      });
    }
  },
  // private
  findTargetItem: function findTargetItem(e) {
    var t = e.getTarget('.x-menu-list-item', this.ul, true);

    if (t && t.menuItemId) {
      return this.items.get(t.menuItemId);
    }
  },
  // private
  onClick: function onClick(e) {
    var t = this.findTargetItem(e);

    if (t) {
      if (t.isFormField) {
        this.setActiveItem(t);
      } else if (t instanceof Ext.menu.BaseItem) {
        if (t.menu && this.ignoreParentClicks) {
          t.expandMenu();
          e.preventDefault();
        } else if (t.onClick) {
          t.onClick(e);
          this.fireEvent('click', this, t, e);
        }
      }
    }
  },
  // private
  setActiveItem: function setActiveItem(item, autoExpand) {
    if (item != this.activeItem) {
      this.deactivateActive();

      if ((this.activeItem = item).isFormField) {
        item.focus();
      } else {
        item.activate(autoExpand);
      }
    } else if (autoExpand) {
      item.expandMenu();
    }
  },
  deactivateActive: function deactivateActive() {
    var a = this.activeItem;

    if (a) {
      if (a.isFormField) {
        //Fields cannot deactivate, but Combos must collapse
        if (a.collapse) {
          a.collapse();
        }
      } else {
        a.deactivate();
      }

      delete this.activeItem;
    }
  },
  // private
  tryActivate: function tryActivate(start, step) {
    var items = this.items;

    for (var i = start, len = items.length; i >= 0 && i < len; i += step) {
      var item = items.get(i);

      if (!item.disabled && (item.canActivate || item.isFormField)) {
        this.setActiveItem(item, false);
        return item;
      }
    }

    return false;
  },
  // private
  onMouseOver: function onMouseOver(e) {
    var t = this.findTargetItem(e);

    if (t) {
      if (t.canActivate && !t.disabled) {
        this.setActiveItem(t, true);
      }
    }

    this.over = true;
    this.fireEvent('mouseover', this, e, t);
  },
  // private
  onMouseOut: function onMouseOut(e) {
    var t = this.findTargetItem(e);

    if (t) {
      if (t == this.activeItem && t.shouldDeactivate && t.shouldDeactivate(e)) {
        this.activeItem.deactivate();
        delete this.activeItem;
      }
    }

    this.over = false;
    this.fireEvent('mouseout', this, e, t);
  },
  // private
  onScroll: function onScroll(e, t) {
    if (e) {
      e.stopEvent();
    }

    var ul = this.ul.dom,
        top = Ext.fly(t).is('.x-menu-scroller-top');
    ul.scrollTop += this.scrollIncrement * (top ? -1 : 1);

    if (top ? ul.scrollTop <= 0 : ul.scrollTop + this.activeMax >= ul.scrollHeight) {
      this.onScrollerOut(null, t);
    }
  },
  // private
  onScrollerIn: function onScrollerIn(e, t) {
    var ul = this.ul.dom,
        top = Ext.fly(t).is('.x-menu-scroller-top');

    if (top ? ul.scrollTop > 0 : ul.scrollTop + this.activeMax < ul.scrollHeight) {
      Ext.fly(t).addClass(['x-menu-item-active', 'x-menu-scroller-active']);
    }
  },
  // private
  onScrollerOut: function onScrollerOut(e, t) {
    Ext.fly(t).removeClass(['x-menu-item-active', 'x-menu-scroller-active']);
  },

  /**
   * If <code>{@link #floating}=true</code>, shows this menu relative to
   * another element using {@link #showat}, otherwise uses {@link Ext.Component#show}.
   * @param {Mixed} element The element to align to
   * @param {String} position (optional) The {@link Ext.Element#alignTo} anchor position to use in aligning to
   * the element (defaults to this.defaultAlign)
   * @param {Ext.menu.Menu} parentMenu (optional) This menu's parent menu, if applicable (defaults to undefined)
   */
  show: function show(el, pos, parentMenu) {
    if (this.floating) {
      this.parentMenu = parentMenu;

      if (!this.el) {
        this.render();
        this.doLayout(false, true);
      }

      this.showAt(this.el.getAlignToXY(el, pos || this.defaultAlign, this.defaultOffsets), parentMenu);
    } else {
      Ext.menu.Menu.superclass.show.call(this);
    }
  },

  /**
   * Displays this menu at a specific xy position and fires the 'show' event if a
   * handler for the 'beforeshow' event does not return false cancelling the operation.
   * @param {Array} xyPosition Contains X & Y [x, y] values for the position at which to show the menu (coordinates are page-based)
   * @param {Ext.menu.Menu} parentMenu (optional) This menu's parent menu, if applicable (defaults to undefined)
   */
  showAt: function showAt(xy, parentMenu) {
    if (this.fireEvent('beforeshow', this) !== false) {
      this.parentMenu = parentMenu;

      if (!this.el) {
        this.render();
      }

      if (this.enableScrolling) {
        // set the position so we can figure out the constrain value.
        this.el.setXY(xy); //constrain the value, keep the y coordinate the same

        xy[1] = this.constrainScroll(xy[1]);
        xy = [this.el.adjustForConstraints(xy)[0], xy[1]];
      } else {
        //constrain to the viewport.
        xy = this.el.adjustForConstraints(xy);
      }

      this.el.setXY(xy);
      this.el.show();
      Ext.menu.Menu.superclass.onShow.call(this);

      if (Ext.isIE) {
        // internal event, used so we don't couple the layout to the menu
        this.fireEvent('autosize', this);

        if (!Ext.isIE8) {
          this.el.repaint();
        }
      }

      this.hidden = false;
      this.focus();
      this.fireEvent('show', this);
    }
  },
  constrainScroll: function constrainScroll(y) {
    var max,
        full = this.ul.setHeight('auto').getHeight(),
        returnY = y,
        normalY,
        parentEl,
        scrollTop,
        viewHeight;

    if (this.floating) {
      parentEl = Ext.fly(this.el.dom.parentNode);
      scrollTop = parentEl.getScroll().top;
      viewHeight = parentEl.getViewSize().height; //Normalize y by the scroll position for the parent element.  Need to move it into the coordinate space
      //of the view.

      normalY = y - scrollTop;
      max = this.maxHeight ? this.maxHeight : viewHeight - normalY;

      if (full > viewHeight) {
        max = viewHeight; //Set returnY equal to (0,0) in view space by reducing y by the value of normalY

        returnY = y - normalY;
      } else if (max < full) {
        returnY = y - (full - max);
        max = full;
      }
    } else {
      max = this.getHeight();
    }

    if (full > max && max > 0) {
      this.activeMax = max - this.scrollerHeight * 2 - this.el.getFrameWidth('tb') - Ext.num(this.el.shadowOffset, 0);
      this.ul.setHeight(this.activeMax);
      this.createScrollers();
      this.el.select('.x-menu-scroller').setDisplayed('');
    } else {
      this.ul.setHeight(full);
      this.el.select('.x-menu-scroller').setDisplayed('none');
    }

    this.ul.dom.scrollTop = 0;
    return returnY;
  },
  createScrollers: function createScrollers() {
    if (!this.scroller) {
      this.scroller = {
        pos: 0,
        top: this.el.insertFirst({
          tag: 'div',
          cls: 'x-menu-scroller x-menu-scroller-top',
          html: '&#160;'
        }),
        bottom: this.el.createChild({
          tag: 'div',
          cls: 'x-menu-scroller x-menu-scroller-bottom',
          html: '&#160;'
        })
      };
      this.scroller.top.hover(this.onScrollerIn, this.onScrollerOut, this);
      this.scroller.topRepeater = new Ext.util.ClickRepeater(this.scroller.top, {
        listeners: {
          click: this.onScroll.createDelegate(this, [null, this.scroller.top], false)
        }
      });
      this.scroller.bottom.hover(this.onScrollerIn, this.onScrollerOut, this);
      this.scroller.bottomRepeater = new Ext.util.ClickRepeater(this.scroller.bottom, {
        listeners: {
          click: this.onScroll.createDelegate(this, [null, this.scroller.bottom], false)
        }
      });
    }
  },
  onLayout: function onLayout() {
    if (this.isVisible()) {
      if (this.enableScrolling) {
        this.constrainScroll(this.el.getTop());
      }

      if (this.floating) {
        this.el.sync();
      }
    }
  },
  focus: function focus() {
    if (!this.hidden) {
      this.doFocus.defer(50, this);
    }
  },
  doFocus: function doFocus() {
    if (!this.hidden) {
      this.focusEl.focus();
    }
  },

  /**
   * Hides this menu and optionally all parent menus
   * @param {Boolean} deep (optional) True to hide all parent menus recursively, if any (defaults to false)
   */
  hide: function hide(deep) {
    if (!this.isDestroyed) {
      this.deepHide = deep;
      Ext.menu.Menu.superclass.hide.call(this);
      delete this.deepHide;
    }
  },
  // private
  onHide: function onHide() {
    Ext.menu.Menu.superclass.onHide.call(this);
    this.deactivateActive();

    if (this.el && this.floating) {
      this.el.hide();
    }

    var pm = this.parentMenu;

    if (this.deepHide === true && pm) {
      if (pm.floating) {
        pm.hide(true);
      } else {
        pm.deactivateActive();
      }
    }
  },
  // private
  lookupComponent: function lookupComponent(c) {
    if (Ext.isString(c)) {
      c = c == 'separator' || c == '-' ? new Ext.menu.Separator() : new Ext.menu.TextItem(c);
      this.applyDefaults(c);
    } else {
      if (Ext.isObject(c)) {
        c = this.getMenuItem(c);
      } else if (c.tagName || c.el) {
        // element. Wrap it.
        c = new Ext.BoxComponent({
          el: c
        });
      }
    }

    return c;
  },
  applyDefaults: function applyDefaults(c) {
    if (!Ext.isString(c)) {
      c = Ext.menu.Menu.superclass.applyDefaults.call(this, c);
      var d = this.internalDefaults;

      if (d) {
        if (c.events) {
          Ext.applyIf(c.initialConfig, d);
          Ext.apply(c, d);
        } else {
          Ext.applyIf(c, d);
        }
      }
    }

    return c;
  },
  // private
  getMenuItem: function getMenuItem(config) {
    if (!config.isXType) {
      if (!config.xtype && Ext.isBoolean(config.checked)) {
        return new Ext.menu.CheckItem(config);
      }

      return Ext.create(config, this.defaultType);
    }

    return config;
  },

  /**
   * Adds a separator bar to the menu
   * @return {Ext.menu.Item} The menu item that was added
   */
  addSeparator: function addSeparator() {
    return this.add(new Ext.menu.Separator());
  },

  /**
   * Adds an {@link Ext.Element} object to the menu
   * @param {Mixed} el The element or DOM node to add, or its id
   * @return {Ext.menu.Item} The menu item that was added
   */
  addElement: function addElement(el) {
    return this.add(new Ext.menu.BaseItem({
      el: el
    }));
  },

  /**
   * Adds an existing object based on {@link Ext.menu.BaseItem} to the menu
   * @param {Ext.menu.Item} item The menu item to add
   * @return {Ext.menu.Item} The menu item that was added
   */
  addItem: function addItem(item) {
    return this.add(item);
  },

  /**
   * Creates a new {@link Ext.menu.Item} based an the supplied config object and adds it to the menu
   * @param {Object} config A MenuItem config object
   * @return {Ext.menu.Item} The menu item that was added
   */
  addMenuItem: function addMenuItem(config) {
    return this.add(this.getMenuItem(config));
  },

  /**
   * Creates a new {@link Ext.menu.TextItem} with the supplied text and adds it to the menu
   * @param {String} text The text to display in the menu item
   * @return {Ext.menu.Item} The menu item that was added
   */
  addText: function addText(text) {
    return this.add(new Ext.menu.TextItem(text));
  },
  //private
  onDestroy: function onDestroy() {
    Ext.EventManager.removeResizeListener(this.hide, this);
    var pm = this.parentMenu;

    if (pm && pm.activeChild == this) {
      delete pm.activeChild;
    }

    delete this.parentMenu;
    Ext.menu.Menu.superclass.onDestroy.call(this);
    Ext.menu.MenuMgr.unregister(this);

    if (this.keyNav) {
      this.keyNav.disable();
    }

    var s = this.scroller;

    if (s) {
      Ext.destroy(s.topRepeater, s.bottomRepeater, s.top, s.bottom);
    }

    Ext.destroy(this.el, this.focusEl, this.ul);
  }
});
Ext.reg('menu', Ext.menu.Menu); // MenuNav is a private utility class used internally by the Menu

Ext.menu.MenuNav = Ext.extend(Ext.KeyNav, function () {
  function up(e, m) {
    if (!m.tryActivate(m.items.indexOf(m.activeItem) - 1, -1)) {
      m.tryActivate(m.items.length - 1, -1);
    }
  }

  function down(e, m) {
    if (!m.tryActivate(m.items.indexOf(m.activeItem) + 1, 1)) {
      m.tryActivate(0, 1);
    }
  }

  return {
    constructor: function constructor(menu) {
      Ext.menu.MenuNav.superclass.constructor.call(this, menu.el);
      this.scope = this.menu = menu;
    },
    doRelay: function doRelay(e, h) {
      var k = e.getKey(); //          Keystrokes within a form Field (e.g.: down in a Combo) do not navigate. Allow only TAB

      if (this.menu.activeItem && this.menu.activeItem.isFormField && k != e.TAB) {
        return false;
      }

      if (!this.menu.activeItem && e.isNavKeyPress() && k != e.SPACE && k != e.RETURN) {
        this.menu.tryActivate(0, 1);
        return false;
      }

      return h.call(this.scope || this, e, this.menu);
    },
    tab: function tab(e, m) {
      e.stopEvent();

      if (e.shiftKey) {
        up(e, m);
      } else {
        down(e, m);
      }
    },
    up: up,
    down: down,
    right: function right(e, m) {
      if (m.activeItem) {
        m.activeItem.expandMenu(true);
      }
    },
    left: function left(e, m) {
      m.hide();

      if (m.parentMenu && m.parentMenu.activeItem) {
        m.parentMenu.activeItem.activate();
      }
    },
    enter: function enter(e, m) {
      if (m.activeItem) {
        e.stopPropagation();
        m.activeItem.onClick(e);
        m.fireEvent('click', this, m.activeItem);
        return true;
      }
    }
  };
}());

/***/ }),
/* 861 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.MenuMgr
 * Provides a common registry of all menu items on a page so that they can be easily accessed by id.
 * @singleton
 */
Ext.menu.MenuMgr = function () {
  var menus,
      active,
      groups = {},
      attached = false,
      lastShow = new Date(); // private - called when first menu is created

  function init() {
    menus = {};
    active = new Ext.util.MixedCollection();
    Ext.getDoc().addKeyListener(27, function () {
      if (active.length > 0) {
        _hideAll();
      }
    });
  } // private


  function _hideAll() {
    if (active && active.length > 0) {
      var c = active.clone();
      c.each(function (m) {
        m.hide();
      });
      return true;
    }

    return false;
  } // private


  function onHide(m) {
    active.remove(m);

    if (active.length < 1) {
      Ext.getDoc().un("mousedown", onMouseDown);
      attached = false;
    }
  } // private


  function onShow(m) {
    var last = active.last();
    lastShow = new Date();
    active.add(m);

    if (!attached) {
      Ext.getDoc().on("mousedown", onMouseDown);
      attached = true;
    }

    if (m.parentMenu) {
      m.getEl().setZIndex(parseInt(m.parentMenu.getEl().getStyle("z-index"), 10) + 3);
      m.parentMenu.activeChild = m;
    } else if (last && !last.isDestroyed && last.isVisible()) {
      m.getEl().setZIndex(parseInt(last.getEl().getStyle("z-index"), 10) + 3);
    }
  } // private


  function onBeforeHide(m) {
    if (m.activeChild) {
      m.activeChild.hide();
    }

    if (m.autoHideTimer) {
      clearTimeout(m.autoHideTimer);
      delete m.autoHideTimer;
    }
  } // private


  function onBeforeShow(m) {
    var pm = m.parentMenu;

    if (!pm && !m.allowOtherMenus) {
      _hideAll();
    } else if (pm && pm.activeChild) {
      pm.activeChild.hide();
    }
  } // private


  function onMouseDown(e) {
    if (lastShow.getElapsed() > 50 && active.length > 0 && !e.getTarget(".x-menu")) {
      _hideAll();
    }
  } // private


  function onBeforeCheck(mi, state) {
    if (state) {
      var g = groups[mi.group];

      for (var i = 0, l = g.length; i < l; i++) {
        if (g[i] != mi) {
          g[i].setChecked(false);
        }
      }
    }
  }

  return {
    /**
     * Hides all menus that are currently visible
     * @return {Boolean} success True if any active menus were hidden.
     */
    hideAll: function hideAll() {
      return _hideAll();
    },
    // private
    register: function register(menu) {
      if (!menus) {
        init();
      }

      menus[menu.id] = menu;
      menu.on({
        beforehide: onBeforeHide,
        hide: onHide,
        beforeshow: onBeforeShow,
        show: onShow
      });
    },

    /**
     * Returns a {@link Ext.menu.Menu} object
     * @param {String/Object} menu The string menu id, an existing menu object reference, or a Menu config that will
     * be used to generate and return a new Menu instance.
     * @return {Ext.menu.Menu} The specified menu, or null if none are found
     */
    get: function get(menu) {
      if (typeof menu == "string") {
        // menu id
        if (!menus) {
          // not initialized, no menus to return
          return null;
        }

        return menus[menu];
      } else if (menu.events) {
        // menu instance
        return menu;
      } else if (typeof menu.length == 'number') {
        // array of menu items?
        return new Ext.menu.Menu({
          items: menu
        });
      } else {
        // otherwise, must be a config
        return Ext.create(menu, 'menu');
      }
    },
    // private
    unregister: function unregister(menu) {
      delete menus[menu.id];
      menu.un("beforehide", onBeforeHide);
      menu.un("hide", onHide);
      menu.un("beforeshow", onBeforeShow);
      menu.un("show", onShow);
    },
    // private
    registerCheckable: function registerCheckable(menuItem) {
      var g = menuItem.group;

      if (g) {
        if (!groups[g]) {
          groups[g] = [];
        }

        groups[g].push(menuItem);
        menuItem.on("beforecheckchange", onBeforeCheck);
      }
    },
    // private
    unregisterCheckable: function unregisterCheckable(menuItem) {
      var g = menuItem.group;

      if (g) {
        groups[g].remove(menuItem);
        menuItem.un("beforecheckchange", onBeforeCheck);
      }
    },
    getCheckedItem: function getCheckedItem(groupId) {
      var g = groups[groupId];

      if (g) {
        for (var i = 0, l = g.length; i < l; i++) {
          if (g[i].checked) {
            return g[i];
          }
        }
      }

      return null;
    },
    setCheckedItem: function setCheckedItem(groupId, itemId) {
      var g = groups[groupId];

      if (g) {
        for (var i = 0, l = g.length; i < l; i++) {
          if (g[i].id == itemId) {
            g[i].setChecked(true);
          }
        }
      }

      return null;
    }
  };
}();

/***/ }),
/* 862 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.BaseItem
 * @extends Ext.Component
 * The base class for all items that render into menus.  BaseItem provides default rendering, activated state
 * management and base configuration options shared by all menu components.
 * @constructor
 * Creates a new BaseItem
 * @param {Object} config Configuration options
 * @xtype menubaseitem
 */
Ext.menu.BaseItem = Ext.extend(Ext.Component, {
  /**
   * @property parentMenu
   * @type Ext.menu.Menu
   * The parent Menu of this Item.
   */

  /**
   * @cfg {Function} handler
   * A function that will handle the click event of this menu item (optional).
   * The handler is passed the following parameters:<div class="mdetail-params"><ul>
   * <li><code>b</code> : Item<div class="sub-desc">This menu Item.</div></li>
   * <li><code>e</code> : EventObject<div class="sub-desc">The click event.</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Object} scope
   * The scope (<tt><b>this</b></tt> reference) in which the handler function will be called.
   */

  /**
   * @cfg {Boolean} canActivate True if this item can be visually activated (defaults to false)
   */
  canActivate: false,

  /**
   * @cfg {String} activeClass The CSS class to use when the item becomes activated (defaults to "x-menu-item-active")
   */
  activeClass: "x-menu-item-active",

  /**
   * @cfg {Boolean} hideOnClick True to hide the containing menu after this item is clicked (defaults to true)
   */
  hideOnClick: true,

  /**
   * @cfg {Number} clickHideDelay Length of time in milliseconds to wait before hiding after a click (defaults to 100)
   */
  clickHideDelay: 1,
  // private
  ctype: "Ext.menu.BaseItem",
  // private
  actionMode: "container",
  initComponent: function initComponent() {
    Ext.menu.BaseItem.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event click
     * Fires when this item is clicked
     * @param {Ext.menu.BaseItem} this
     * @param {Ext.EventObject} e
     */
    'click',
    /**
     * @event activate
     * Fires when this item is activated
     * @param {Ext.menu.BaseItem} this
     */
    'activate',
    /**
     * @event deactivate
     * Fires when this item is deactivated
     * @param {Ext.menu.BaseItem} this
     */
    'deactivate');

    if (this.handler) {
      this.on("click", this.handler, this.scope);
    }
  },
  // private
  onRender: function onRender(container, position) {
    Ext.menu.BaseItem.superclass.onRender.apply(this, arguments);

    if (this.ownerCt && this.ownerCt instanceof Ext.menu.Menu) {
      this.parentMenu = this.ownerCt;
    } else {
      this.container.addClass('x-menu-list-item');
      this.mon(this.el, {
        scope: this,
        click: this.onClick,
        mouseenter: this.activate,
        mouseleave: this.deactivate
      });
    }
  },

  /**
   * Sets the function that will handle click events for this item (equivalent to passing in the {@link #handler}
   * config property).  If an existing handler is already registered, it will be unregistered for you.
   * @param {Function} handler The function that should be called on click
   * @param {Object} scope The scope (<code>this</code> reference) in which the handler function is executed. Defaults to this menu item.
   */
  setHandler: function setHandler(handler, scope) {
    if (this.handler) {
      this.un("click", this.handler, this.scope);
    }

    this.on("click", this.handler = handler, this.scope = scope);
  },
  // private
  onClick: function onClick(e) {
    if (!this.disabled && this.fireEvent("click", this, e) !== false && this.parentMenu && this.parentMenu.fireEvent("itemclick", this, e) !== false) {
      this.handleClick(e);
    } else {
      e.stopEvent();
    }
  },
  // private
  activate: function activate() {
    if (this.disabled) {
      return false;
    }

    var li = this.container;
    li.addClass(this.activeClass);
    this.region = li.getRegion().adjust(2, 2, -2, -2);
    this.fireEvent("activate", this);
    return true;
  },
  // private
  deactivate: function deactivate() {
    this.container.removeClass(this.activeClass);
    this.fireEvent("deactivate", this);
  },
  // private
  shouldDeactivate: function shouldDeactivate(e) {
    return !this.region || !this.region.contains(e.getPoint());
  },
  // private
  handleClick: function handleClick(e) {
    var pm = this.parentMenu;

    if (this.hideOnClick) {
      if (pm.floating) {
        pm.hide.defer(this.clickHideDelay, pm, [true]);
      } else {
        pm.deactivateActive();
      }
    }
  },
  // private. Do nothing
  expandMenu: Ext.emptyFn,
  // private. Do nothing
  hideMenu: Ext.emptyFn
});
Ext.reg('menubaseitem', Ext.menu.BaseItem);

/***/ }),
/* 863 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.TextItem
 * @extends Ext.menu.BaseItem
 * Adds a static text string to a menu, usually used as either a heading or group separator.
 * @constructor
 * Creates a new TextItem
 * @param {Object/String} config If config is a string, it is used as the text to display, otherwise it
 * is applied as a config object (and should contain a <tt>text</tt> property).
 * @xtype menutextitem
 */
Ext.menu.TextItem = Ext.extend(Ext.menu.BaseItem, {
  /**
   * @cfg {String} text The text to display for this item (defaults to '')
   */

  /**
   * @cfg {Boolean} hideOnClick True to hide the containing menu after this item is clicked (defaults to false)
   */
  hideOnClick: false,

  /**
   * @cfg {String} itemCls The default CSS class to use for text items (defaults to "x-menu-text")
   */
  itemCls: "x-menu-text",
  constructor: function constructor(config) {
    if (typeof config == 'string') {
      config = {
        text: config
      };
    }

    Ext.menu.TextItem.superclass.constructor.call(this, config);
  },
  // private
  onRender: function onRender() {
    var s = document.createElement("span");
    s.className = this.itemCls;
    s.innerHTML = this.text;
    this.el = s;
    Ext.menu.TextItem.superclass.onRender.apply(this, arguments);
  }
});
Ext.reg('menutextitem', Ext.menu.TextItem);

/***/ }),
/* 864 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.Separator
 * @extends Ext.menu.BaseItem
 * Adds a separator bar to a menu, used to divide logical groups of menu items. Generally you will
 * add one of these by using "-" in you call to add() or in your items config rather than creating one directly.
 * @constructor
 * @param {Object} config Configuration options
 * @xtype menuseparator
 */
Ext.menu.Separator = Ext.extend(Ext.menu.BaseItem, {
  /**
   * @cfg {String} itemCls The default CSS class to use for separators (defaults to "x-menu-sep")
   */
  itemCls: "x-menu-sep",

  /**
   * @cfg {Boolean} hideOnClick True to hide the containing menu after this item is clicked (defaults to false)
   */
  hideOnClick: false,

  /** 
   * @cfg {String} activeClass
   * @hide 
   */
  activeClass: '',
  // private
  onRender: function onRender(li) {
    var s = document.createElement("span");
    s.className = this.itemCls;
    s.innerHTML = "&#160;";
    this.el = s;
    li.addClass("x-menu-sep-li");
    Ext.menu.Separator.superclass.onRender.apply(this, arguments);
  }
});
Ext.reg('menuseparator', Ext.menu.Separator);

/***/ }),
/* 865 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.Item
 * @extends Ext.menu.BaseItem
 * A base class for all menu items that require menu-related functionality (like sub-menus) and are not static
 * display items.  Item extends the base functionality of {@link Ext.menu.BaseItem} by adding menu-specific
 * activation and click handling.
 * @constructor
 * Creates a new Item
 * @param {Object} config Configuration options
 * @xtype menuitem
 */
Ext.menu.Item = Ext.extend(Ext.menu.BaseItem, {
  /**
   * @property menu
   * @type Ext.menu.Menu
   * The submenu associated with this Item if one was configured.
   */

  /**
   * @cfg {Mixed} menu (optional) Either an instance of {@link Ext.menu.Menu} or the config object for an
   * {@link Ext.menu.Menu} which acts as the submenu when this item is activated.
   */

  /**
   * @cfg {String} icon The path to an icon to display in this item (defaults to Ext.BLANK_IMAGE_URL).  If
   * icon is specified {@link #iconCls} should not be.
   */

  /**
   * @cfg {String} iconCls A CSS class that specifies a background image that will be used as the icon for
   * this item (defaults to '').  If iconCls is specified {@link #icon} should not be.
   */

  /**
   * @cfg {String} text The text to display in this item (defaults to '').
   */

  /**
   * @cfg {String} href The href attribute to use for the underlying anchor link (defaults to '#').
   */

  /**
   * @cfg {String} hrefTarget The target attribute to use for the underlying anchor link (defaults to '').
   */

  /**
   * @cfg {String} itemCls The default CSS class to use for menu items (defaults to 'x-menu-item')
   */
  itemCls: 'x-menu-item',

  /**
   * @cfg {Boolean} canActivate True if this item can be visually activated (defaults to true)
   */
  canActivate: true,

  /**
   * @cfg {Number} showDelay Length of time in milliseconds to wait before showing this item (defaults to 200)
   */
  showDelay: 200,
  // doc'd in BaseItem
  hideDelay: 200,
  // private
  ctype: 'Ext.menu.Item',
  initComponent: function initComponent() {
    Ext.menu.Item.superclass.initComponent.call(this);

    if (this.menu) {
      this.menu = Ext.menu.MenuMgr.get(this.menu);
      this.menu.ownerCt = this;
    }
  },
  // private
  onRender: function onRender(container, position) {
    if (!this.itemTpl) {
      this.itemTpl = Ext.menu.Item.prototype.itemTpl = new Ext.XTemplate('<a id="{id}" class="{cls}" hidefocus="true" unselectable="on"  <tpl if="href != \'#\'">href="{href}"</tpl>', '<tpl if="hrefTarget">', ' target="{hrefTarget}"', '</tpl>', '>', '<img src="{icon}" class="x-menu-item-icon {iconCls}"/>', '<span class="x-menu-item-text">{text}</span>', '</a>');
    }

    var a = this.getTemplateArgs();
    this.el = position ? this.itemTpl.insertBefore(position, a, true) : this.itemTpl.append(container, a, true);
    this.iconEl = this.el.child('img.x-menu-item-icon');
    this.textEl = this.el.child('.x-menu-item-text');

    if (!this.href) {
      // if no link defined, prevent the default anchor event
      this.mon(this.el, 'click', Ext.emptyFn, null, {
        preventDefault: true
      });
    }

    Ext.menu.Item.superclass.onRender.call(this, container, position);
  },
  getTemplateArgs: function getTemplateArgs() {
    return {
      id: this.id,
      cls: this.itemCls + (this.menu ? ' x-menu-item-arrow' : '') + (this.cls ? ' ' + this.cls : ''),
      href: this.href || '#',
      hrefTarget: this.hrefTarget,
      icon: this.icon || Ext.BLANK_IMAGE_URL,
      iconCls: this.iconCls || '',
      text: this.itemText || this.text || '&#160;'
    };
  },

  /**
   * Sets the text to display in this menu item
   * @param {String} text The text to display
   */
  setText: function setText(text) {
    this.text = text || '&#160;';

    if (this.rendered) {
      this.textEl.update(this.text);
      this.parentMenu.layout.doAutoSize();
    }
  },

  /**
   * Sets the CSS class to apply to the item's icon element
   * @param {String} cls The CSS class to apply
   */
  setIconClass: function setIconClass(cls) {
    var oldCls = this.iconCls;
    this.iconCls = cls;

    if (this.rendered) {
      this.iconEl.replaceClass(oldCls, this.iconCls);
    }
  },
  //private
  beforeDestroy: function beforeDestroy() {
    if (this.menu) {
      delete this.menu.ownerCt;
      this.menu.destroy();
    }

    Ext.menu.Item.superclass.beforeDestroy.call(this);
  },
  // private
  handleClick: function handleClick(e) {
    if (!this.href) {
      // if no link defined, stop the event automatically
      e.stopEvent();
    }

    Ext.menu.Item.superclass.handleClick.apply(this, arguments);
  },
  // private
  activate: function activate(autoExpand) {
    if (Ext.menu.Item.superclass.activate.apply(this, arguments)) {
      this.focus();

      if (autoExpand) {
        this.expandMenu();
      }
    }

    return true;
  },
  // private
  shouldDeactivate: function shouldDeactivate(e) {
    if (Ext.menu.Item.superclass.shouldDeactivate.call(this, e)) {
      if (this.menu && this.menu.isVisible()) {
        return !this.menu.getEl().getRegion().contains(e.getPoint());
      }

      return true;
    }

    return false;
  },
  // private
  deactivate: function deactivate() {
    Ext.menu.Item.superclass.deactivate.apply(this, arguments);
    this.hideMenu();
  },
  // private
  expandMenu: function expandMenu(autoActivate) {
    if (!this.disabled && this.menu) {
      clearTimeout(this.hideTimer);
      delete this.hideTimer;

      if (!this.menu.isVisible() && !this.showTimer) {
        this.showTimer = this.deferExpand.defer(this.showDelay, this, [autoActivate]);
      } else if (this.menu.isVisible() && autoActivate) {
        this.menu.tryActivate(0, 1);
      }
    }
  },
  // private
  deferExpand: function deferExpand(autoActivate) {
    delete this.showTimer;
    this.menu.show(this.container, this.parentMenu.subMenuAlign || 'tl-tr?', this.parentMenu);

    if (autoActivate) {
      this.menu.tryActivate(0, 1);
    }
  },
  // private
  hideMenu: function hideMenu() {
    clearTimeout(this.showTimer);
    delete this.showTimer;

    if (!this.hideTimer && this.menu && this.menu.isVisible()) {
      this.hideTimer = this.deferHide.defer(this.hideDelay, this);
    }
  },
  // private
  deferHide: function deferHide() {
    delete this.hideTimer;

    if (this.menu.over) {
      this.parentMenu.setActiveItem(this, false);
    } else {
      this.menu.hide();
    }
  }
});
Ext.reg('menuitem', Ext.menu.Item);

/***/ }),
/* 866 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.CheckItem
 * @extends Ext.menu.Item
 * Adds a menu item that contains a checkbox by default, but can also be part of a radio group.
 * @constructor
 * Creates a new CheckItem
 * @param {Object} config Configuration options
 * @xtype menucheckitem
 */
Ext.menu.CheckItem = Ext.extend(Ext.menu.Item, {
  /**
   * @cfg {String} group
   * All check items with the same group name will automatically be grouped into a single-select
   * radio button group (defaults to '')
   */

  /**
   * @cfg {String} itemCls The default CSS class to use for check items (defaults to "x-menu-item x-menu-check-item")
   */
  itemCls: "x-menu-item x-menu-check-item",

  /**
   * @cfg {String} groupClass The default CSS class to use for radio group check items (defaults to "x-menu-group-item")
   */
  groupClass: "x-menu-group-item",

  /**
   * @cfg {Boolean} checked True to initialize this checkbox as checked (defaults to false).  Note that
   * if this checkbox is part of a radio group (group = true) only the last item in the group that is
   * initialized with checked = true will be rendered as checked.
   */
  checked: false,
  // private
  ctype: "Ext.menu.CheckItem",
  initComponent: function initComponent() {
    Ext.menu.CheckItem.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event beforecheckchange
     * Fires before the checked value is set, providing an opportunity to cancel if needed
     * @param {Ext.menu.CheckItem} this
     * @param {Boolean} checked The new checked value that will be set
     */
    "beforecheckchange",
    /**
     * @event checkchange
     * Fires after the checked value has been set
     * @param {Ext.menu.CheckItem} this
     * @param {Boolean} checked The checked value that was set
     */
    "checkchange");
    /**
     * A function that handles the checkchange event.  The function is undefined by default, but if an implementation
     * is provided, it will be called automatically when the checkchange event fires.
     * @param {Ext.menu.CheckItem} this
     * @param {Boolean} checked The checked value that was set
     * @method checkHandler
     */

    if (this.checkHandler) {
      this.on('checkchange', this.checkHandler, this.scope);
    }

    Ext.menu.MenuMgr.registerCheckable(this);
  },
  // private
  onRender: function onRender(c) {
    Ext.menu.CheckItem.superclass.onRender.apply(this, arguments);

    if (this.group) {
      this.el.addClass(this.groupClass);
    }

    if (this.checked) {
      this.checked = false;
      this.setChecked(true, true);
    }
  },
  // private
  destroy: function destroy() {
    Ext.menu.MenuMgr.unregisterCheckable(this);
    Ext.menu.CheckItem.superclass.destroy.apply(this, arguments);
  },

  /**
   * Set the checked state of this item
   * @param {Boolean} checked The new checked value
   * @param {Boolean} suppressEvent (optional) True to prevent the checkchange event from firing (defaults to false)
   */
  setChecked: function setChecked(state, suppressEvent) {
    var suppress = suppressEvent === true;

    if (this.checked != state && (suppress || this.fireEvent("beforecheckchange", this, state) !== false)) {
      if (this.container) {
        this.container[state ? "addClass" : "removeClass"]("x-menu-item-checked");
      }

      this.checked = state;

      if (!suppress) {
        this.fireEvent("checkchange", this, state);
      }
    }
  },
  // private
  handleClick: function handleClick(e) {
    if (!this.disabled && !(this.checked && this.group)) {
      // disable unselect on radio item
      this.setChecked(!this.checked);
    }

    Ext.menu.CheckItem.superclass.handleClick.apply(this, arguments);
  }
});
Ext.reg('menucheckitem', Ext.menu.CheckItem);

/***/ }),
/* 867 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.DateMenu
 * @extends Ext.menu.Menu
 * <p>A menu containing an {@link Ext.DatePicker} Component.</p>
 * <p>Notes:</p><div class="mdetail-params"><ul>
 * <li>Although not listed here, the <b>constructor</b> for this class
 * accepts all of the configuration options of <b>{@link Ext.DatePicker}</b>.</li>
 * <li>If subclassing DateMenu, any configuration options for the DatePicker must be
 * applied to the <tt><b>initialConfig</b></tt> property of the DateMenu.
 * Applying {@link Ext.DatePicker DatePicker} configuration settings to
 * <b><tt>this</tt></b> will <b>not</b> affect the DatePicker's configuration.</li>
 * </ul></div>
 * @xtype datemenu
 */
Ext.menu.DateMenu = Ext.extend(Ext.menu.Menu, {
  /** 
   * @cfg {Boolean} enableScrolling
   * @hide 
   */
  enableScrolling: false,

  /**
   * @cfg {Function} handler
   * Optional. A function that will handle the select event of this menu.
   * The handler is passed the following parameters:<div class="mdetail-params"><ul>
   * <li><code>picker</code> : DatePicker<div class="sub-desc">The Ext.DatePicker.</div></li>
   * <li><code>date</code> : Date<div class="sub-desc">The selected date.</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Object} scope
   * The scope (<tt><b>this</b></tt> reference) in which the <code>{@link #handler}</code>
   * function will be called.  Defaults to this DateMenu instance.
   */

  /** 
   * @cfg {Boolean} hideOnClick
   * False to continue showing the menu after a date is selected, defaults to true.
   */
  hideOnClick: true,

  /** 
   * @cfg {String} pickerId
   * An id to assign to the underlying date picker. Defaults to <tt>null</tt>.
   */
  pickerId: null,

  /** 
   * @cfg {Number} maxHeight
   * @hide 
   */

  /** 
   * @cfg {Number} scrollIncrement
   * @hide 
   */

  /**
   * The {@link Ext.DatePicker} instance for this DateMenu
   * @property picker
   * @type DatePicker
   */
  cls: 'x-date-menu',

  /**
   * @event click
   * @hide
   */

  /**
   * @event itemclick
   * @hide
   */
  initComponent: function initComponent() {
    this.on('beforeshow', this.onBeforeShow, this);

    if (this.strict = Ext.isIE7 && Ext.isStrict) {
      this.on('show', this.onShow, this, {
        single: true,
        delay: 20
      });
    }

    Ext.apply(this, {
      plain: true,
      showSeparator: false,
      items: this.picker = new Ext.DatePicker(Ext.applyIf({
        internalRender: this.strict || !Ext.isIE,
        ctCls: 'x-menu-date-item',
        id: this.pickerId
      }, this.initialConfig))
    });
    this.picker.purgeListeners();
    Ext.menu.DateMenu.superclass.initComponent.call(this);
    /**
     * @event select
     * Fires when a date is selected from the {@link #picker Ext.DatePicker}
     * @param {DatePicker} picker The {@link #picker Ext.DatePicker}
     * @param {Date} date The selected date
     */

    this.relayEvents(this.picker, ['select']);
    this.on('show', this.picker.focus, this.picker);
    this.on('select', this.menuHide, this);

    if (this.handler) {
      this.on('select', this.handler, this.scope || this);
    }
  },
  menuHide: function menuHide() {
    if (this.hideOnClick) {
      this.hide(true);
    }
  },
  onBeforeShow: function onBeforeShow() {
    if (this.picker) {
      this.picker.hideMonthPicker(true);
    }
  },
  onShow: function onShow() {
    var el = this.picker.getEl();
    el.setWidth(el.getWidth()); //nasty hack for IE7 strict mode
  }
});
Ext.reg('datemenu', Ext.menu.DateMenu);

/***/ }),
/* 868 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.menu.ColorMenu
 * @extends Ext.menu.Menu
 * <p>A menu containing a {@link Ext.ColorPalette} Component.</p>
 * <p>Notes:</p><div class="mdetail-params"><ul>
 * <li>Although not listed here, the <b>constructor</b> for this class
 * accepts all of the configuration options of <b>{@link Ext.ColorPalette}</b>.</li>
 * <li>If subclassing ColorMenu, any configuration options for the ColorPalette must be
 * applied to the <tt><b>initialConfig</b></tt> property of the ColorMenu.
 * Applying {@link Ext.ColorPalette ColorPalette} configuration settings to
 * <b><tt>this</tt></b> will <b>not</b> affect the ColorPalette's configuration.</li>
 * </ul></div> * 
 * @xtype colormenu
 */
Ext.menu.ColorMenu = Ext.extend(Ext.menu.Menu, {
  /** 
   * @cfg {Boolean} enableScrolling
   * @hide 
   */
  enableScrolling: false,

  /**
   * @cfg {Function} handler
   * Optional. A function that will handle the select event of this menu.
   * The handler is passed the following parameters:<div class="mdetail-params"><ul>
   * <li><code>palette</code> : ColorPalette<div class="sub-desc">The {@link #palette Ext.ColorPalette}.</div></li>
   * <li><code>color</code> : String<div class="sub-desc">The 6-digit color hex code (without the # symbol).</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Object} scope
   * The scope (<tt><b>this</b></tt> reference) in which the <code>{@link #handler}</code>
   * function will be called.  Defaults to this ColorMenu instance.
   */

  /** 
   * @cfg {Boolean} hideOnClick
   * False to continue showing the menu after a color is selected, defaults to true.
   */
  hideOnClick: true,
  cls: 'x-color-menu',

  /** 
   * @cfg {String} paletteId
   * An id to assign to the underlying color palette. Defaults to <tt>null</tt>.
   */
  paletteId: null,

  /** 
   * @cfg {Number} maxHeight
   * @hide 
   */

  /** 
   * @cfg {Number} scrollIncrement
   * @hide 
   */

  /**
   * @property palette
   * @type ColorPalette
   * The {@link Ext.ColorPalette} instance for this ColorMenu
   */

  /**
   * @event click
   * @hide
   */

  /**
   * @event itemclick
   * @hide
   */
  initComponent: function initComponent() {
    Ext.apply(this, {
      plain: true,
      showSeparator: false,
      items: this.palette = new Ext.ColorPalette(Ext.applyIf({
        id: this.paletteId
      }, this.initialConfig))
    });
    this.palette.purgeListeners();
    Ext.menu.ColorMenu.superclass.initComponent.call(this);
    /**
     * @event select
     * Fires when a color is selected from the {@link #palette Ext.ColorPalette}
     * @param {Ext.ColorPalette} palette The {@link #palette Ext.ColorPalette}
    * @param {String} color The 6-digit color hex code (without the # symbol)
     */

    this.relayEvents(this.palette, ['select', 'pickerShow']);
    this.on('select', this.menuHide, this);

    if (this.handler) {
      this.on('select', this.handler, this.scope || this);
    }
  },
  menuHide: function menuHide() {
    if (this.hideOnClick) {
      this.hide(true);
    }
  }
});
Ext.reg('colormenu', Ext.menu.ColorMenu);

/***/ }),
/* 869 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.Field
 * @extends Ext.BoxComponent
 * Base class for form fields that provides default event handling, sizing, value handling and other functionality.
 * @constructor
 * Creates a new Field
 * @param {Object} config Configuration options
 * @xtype field
 */
Ext.form.Field = Ext.extend(Ext.BoxComponent, {
  /**
   * <p>The label Element associated with this Field. <b>Only available after this Field has been rendered by a
   * {@link form Ext.layout.FormLayout} layout manager.</b></p>
   * @type Ext.Element
   * @property label
   */

  /**
   * @cfg {String} inputType The type attribute for input fields -- e.g. radio, text, password, file (defaults
   * to 'text'). The types 'file' and 'password' must be used to render those field types currently -- there are
   * no separate Ext components for those. Note that if you use <tt>inputType:'file'</tt>, {@link #emptyText}
   * is not supported and should be avoided.
   */

  /**
   * @cfg {Number} tabIndex The tabIndex for this field. Note this only applies to fields that are rendered,
   * not those which are built via applyTo (defaults to undefined).
   */

  /**
   * @cfg {Mixed} value A value to initialize this field with (defaults to undefined).
   */

  /**
   * @cfg {String} name The field's HTML name attribute (defaults to '').
   * <b>Note</b>: this property must be set if this field is to be automatically included with
   * {@link Ext.form.BasicForm#submit form submit()}.
   */

  /**
   * @cfg {String} cls A custom CSS class to apply to the field's underlying element (defaults to '').
   */

  /**
   * @cfg {String} invalidClass The CSS class to use when marking a field invalid (defaults to 'x-form-invalid')
   */
  invalidClass: 'x-form-invalid',

  /**
   * @cfg {String} invalidText The error text to use when marking a field invalid and no message is provided
   * (defaults to 'The value in this field is invalid')
   */
  invalidText: 'The value in this field is invalid',

  /**
   * @cfg {String} focusClass The CSS class to use when the field receives focus (defaults to 'x-form-focus')
   */
  focusClass: 'x-form-focus',

  /**
   * @cfg {Boolean} preventMark
   * <tt>true</tt> to disable {@link #markInvalid marking the field invalid}.
   * Defaults to <tt>false</tt>.
   */

  /**
   * @cfg {String/Boolean} validationEvent The event that should initiate field validation. Set to false to disable
    automatic validation (defaults to 'keyup').
   */
  validationEvent: 'keyup',

  /**
   * @cfg {Boolean} validateOnBlur Whether the field should validate when it loses focus (defaults to true).
   */
  validateOnBlur: true,

  /**
   * @cfg {Number} validationDelay The length of time in milliseconds after user input begins until validation
   * is initiated (defaults to 250)
   */
  validationDelay: 250,

  /**
   * @cfg {String/Object} autoCreate <p>A {@link Ext.DomHelper DomHelper} element spec, or true for a default
   * element spec. Used to create the {@link Ext.Component#getEl Element} which will encapsulate this Component.
   * See <tt>{@link Ext.Component#autoEl autoEl}</tt> for details.  Defaults to:</p>
   * <pre><code>{tag: 'input', type: 'text', size: '20', autocomplete: 'off'}</code></pre>
   */
  defaultAutoCreate: {
    tag: 'input',
    type: 'text',
    size: '20',
    autocomplete: 'off'
  },

  /**
   * @cfg {String} fieldClass The default CSS class for the field (defaults to 'x-form-field')
   */
  fieldClass: 'x-form-field',

  /**
   * @cfg {String} msgTarget<p>The location where the message text set through {@link #markInvalid} should display.
   * Must be one of the following values:</p>
   * <div class="mdetail-params"><ul>
   * <li><code>qtip</code> Display a quick tip containing the message when the user hovers over the field. This is the default.
   * <div class="subdesc"><b>{@link Ext.QuickTips#init Ext.QuickTips.init} must have been called for this setting to work.</b></div</li>
   * <li><code>title</code> Display the message in a default browser title attribute popup.</li>
   * <li><code>under</code> Add a block div beneath the field containing the error message.</li>
   * <li><code>side</code> Add an error icon to the right of the field, displaying the message in a popup on hover.</li>
   * <li><code>[element id]</code> Add the error message directly to the innerHTML of the specified element.</li>
   * </ul></div>
   */
  msgTarget: 'qtip',

  /**
   * @cfg {String} msgFx <b>Experimental</b> The effect used when displaying a validation message under the field
   * (defaults to 'normal').
   */
  msgFx: 'normal',

  /**
   * @cfg {Boolean} readOnly <tt>true</tt> to mark the field as readOnly in HTML
   * (defaults to <tt>false</tt>).
   * <br><p><b>Note</b>: this only sets the element's readOnly DOM attribute.
   * Setting <code>readOnly=true</code>, for example, will not disable triggering a
   * ComboBox or DateField; it gives you the option of forcing the user to choose
   * via the trigger without typing in the text box. To hide the trigger use
   * <code>{@link Ext.form.TriggerField#hideTrigger hideTrigger}</code>.</p>
   */
  readOnly: false,

  /**
   * @cfg {Boolean} disabled True to disable the field (defaults to false).
   * <p>Be aware that conformant with the <a href="http://www.w3.org/TR/html401/interact/forms.html#h-17.12.1">HTML specification</a>,
   * disabled Fields will not be {@link Ext.form.BasicForm#submit submitted}.</p>
   */
  disabled: false,

  /**
   * @cfg {Boolean} submitValue False to clear the name attribute on the field so that it is not submitted during a form post.
   * Defaults to <tt>true</tt>.
   */
  submitValue: true,
  // private
  isFormField: true,
  // private
  msgDisplay: '',
  // private
  hasFocus: false,
  // private
  initComponent: function initComponent() {
    Ext.form.Field.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event focus
     * Fires when this field receives input focus.
     * @param {Ext.form.Field} this
     */
    'focus',
    /**
     * @event blur
     * Fires when this field loses input focus.
     * @param {Ext.form.Field} this
     */
    'blur',
    /**
     * @event specialkey
     * Fires when any key related to navigation (arrows, tab, enter, esc, etc.) is pressed.
     * To handle other keys see {@link Ext.Panel#keys} or {@link Ext.KeyMap}.
     * You can check {@link Ext.EventObject#getKey} to determine which key was pressed.
     * For example: <pre><code>
    var form = new Ext.form.FormPanel({
    ...
    items: [{
    fieldLabel: 'Field 1',
    name: 'field1',
    allowBlank: false
    },{
    fieldLabel: 'Field 2',
    name: 'field2',
    listeners: {
        specialkey: function(field, e){
            // e.HOME, e.END, e.PAGE_UP, e.PAGE_DOWN,
            // e.TAB, e.ESC, arrow keys: e.LEFT, e.RIGHT, e.UP, e.DOWN
            if (e.{@link Ext.EventObject#getKey getKey()} == e.ENTER) {
                var form = field.ownerCt.getForm();
                form.submit();
            }
        }
    }
    }
    ],
    ...
    });
     * </code></pre>
     * @param {Ext.form.Field} this
     * @param {Ext.EventObject} e The event object
     */
    'specialkey',
    /**
     * @event change
     * Fires just before the field blurs if the field value has changed.
     * @param {Ext.form.Field} this
     * @param {Mixed} newValue The new value
     * @param {Mixed} oldValue The original value
     */
    'change',
    /**
     * @event invalid
     * Fires after the field has been marked as invalid.
     * @param {Ext.form.Field} this
     * @param {String} msg The validation message
     */
    'invalid',
    /**
     * @event valid
     * Fires after the field has been validated with no errors.
     * @param {Ext.form.Field} this
     */
    'valid');
  },

  /**
   * Returns the {@link Ext.form.Field#name name} or {@link Ext.form.ComboBox#hiddenName hiddenName}
   * attribute of the field if available.
   * @return {String} name The field {@link Ext.form.Field#name name} or {@link Ext.form.ComboBox#hiddenName hiddenName}
   */
  getName: function getName() {
    return this.rendered && this.el.dom.name ? this.el.dom.name : this.name || this.id || '';
  },
  // private
  onRender: function onRender(ct, position) {
    if (!this.el) {
      var cfg = this.getAutoCreate();

      if (!cfg.name) {
        cfg.name = this.name || this.id;
      }

      if (this.inputType) {
        cfg.type = this.inputType;
      }

      this.autoEl = cfg;
    }

    Ext.form.Field.superclass.onRender.call(this, ct, position);

    if (this.submitValue === false) {
      this.el.dom.removeAttribute('name');
    }

    var type = this.el.dom.type;

    if (type) {
      if (type == 'password') {
        type = 'text';
      }

      this.el.addClass('x-form-' + type);
    }

    if (this.readOnly) {
      this.setReadOnly(true);
    }

    if (this.tabIndex !== undefined) {
      this.el.dom.setAttribute('tabIndex', this.tabIndex);
    }

    this.el.addClass([this.fieldClass, this.cls]);
  },
  // private
  getItemCt: function getItemCt() {
    return this.itemCt;
  },
  // private
  initValue: function initValue() {
    if (this.value !== undefined) {
      this.setValue(this.value);
    } else if (!Ext.isEmpty(this.el.dom.value) && this.el.dom.value != this.emptyText) {
      this.setValue(this.el.dom.value);
    }
    /**
     * The original value of the field as configured in the {@link #value} configuration, or
     * as loaded by the last form load operation if the form's {@link Ext.form.BasicForm#trackResetOnLoad trackResetOnLoad}
     * setting is <code>true</code>.
     * @type mixed
     * @property originalValue
     */


    this.originalValue = this.getValue();
  },

  /**
   * <p>Returns true if the value of this Field has been changed from its original value.
   * Will return false if the field is disabled or has not been rendered yet.</p>
   * <p>Note that if the owning {@link Ext.form.BasicForm form} was configured with
   * {@link Ext.form.BasicForm}.{@link Ext.form.BasicForm#trackResetOnLoad trackResetOnLoad}
   * then the <i>original value</i> is updated when the values are loaded by
   * {@link Ext.form.BasicForm}.{@link Ext.form.BasicForm#setValues setValues}.</p>
   * @return {Boolean} True if this field has been changed from its original value (and
   * is not disabled), false otherwise.
   */
  isDirty: function isDirty() {
    if (this.disabled || !this.rendered) {
      return false;
    }

    return String(this.getValue()) !== String(this.originalValue);
  },

  /**
   * Sets the read only state of this field.
   * @param {Boolean} readOnly Whether the field should be read only.
   */
  setReadOnly: function setReadOnly(readOnly) {
    if (this.rendered) {
      this.el.dom.readOnly = readOnly;
    }

    this.readOnly = readOnly;
  },
  // private
  afterRender: function afterRender() {
    Ext.form.Field.superclass.afterRender.call(this);
    this.initEvents();
    this.initValue();
  },
  // private
  fireKey: function fireKey(e) {
    if (e.isSpecialKey()) {
      this.fireEvent('specialkey', this, e);
    }
  },

  /**
   * Resets the current field value to the originally loaded value and clears any validation messages.
   * See {@link Ext.form.BasicForm}.{@link Ext.form.BasicForm#trackResetOnLoad trackResetOnLoad}
   */
  reset: function reset() {
    this.setValue(this.originalValue);
    this.clearInvalid();
  },
  // private
  initEvents: function initEvents() {
    this.mon(this.el, Ext.EventManager.useKeydown ? 'keydown' : 'keypress', this.fireKey, this);
    this.mon(this.el, 'focus', this.onFocus, this); // standardise buffer across all browsers + OS-es for consistent event order.
    // (the 10ms buffer for Editors fixes a weird FF/Win editor issue when changing OS window focus)

    this.mon(this.el, 'blur', this.onBlur, this, this.inEditor ? {
      buffer: 10
    } : null);
  },
  // private
  preFocus: Ext.emptyFn,
  // private
  onFocus: function onFocus() {
    this.preFocus();

    if (this.focusClass) {
      this.el.addClass(this.focusClass);
    }

    if (!this.hasFocus) {
      this.hasFocus = true;
      /**
       * <p>The value that the Field had at the time it was last focused. This is the value that is passed
       * to the {@link #change} event which is fired if the value has been changed when the Field is blurred.</p>
       * <p><b>This will be undefined until the Field has been visited.</b> Compare {@link #originalValue}.</p>
       * @type mixed
       * @property startValue
       */

      this.startValue = this.getValue();
      this.fireEvent('focus', this);
    }
  },
  // private
  beforeBlur: Ext.emptyFn,
  // private
  onBlur: function onBlur() {
    this.beforeBlur();

    if (this.focusClass) {
      this.el.removeClass(this.focusClass);
    }

    this.hasFocus = false;

    if (this.validationEvent !== false && (this.validateOnBlur || this.validationEvent == 'blur')) {
      this.validate();
    }

    var v = this.getValue();

    if (String(v) !== String(this.startValue)) {
      this.fireEvent('change', this, v, this.startValue);
    }

    this.fireEvent('blur', this);
    this.postBlur();
  },
  // private
  postBlur: Ext.emptyFn,

  /**
   * Returns whether or not the field value is currently valid by
   * {@link #validateValue validating} the {@link #processValue processed value}
   * of the field. <b>Note</b>: {@link #disabled} fields are ignored.
   * @param {Boolean} preventMark True to disable marking the field invalid
   * @return {Boolean} True if the value is valid, else false
   */
  isValid: function isValid(preventMark) {
    if (this.disabled || this.hidden || this.readOnly) {
      return true;
    }

    var restore = this.preventMark;
    this.preventMark = preventMark === true;
    var v = this.validateValue(this.processValue(this.getRawValue()));
    this.preventMark = restore;
    return v;
  },

  /**
   * Validates the field value
   * @return {Boolean} True if the value is valid, else false
   */
  validate: function validate() {
    if (this.disabled || this.hidden || this.readOnly || this.validateValue(this.processValue(this.getRawValue()))) {
      this.clearInvalid();
      return true;
    }

    return false;
  },

  /**
   * This method should only be overridden if necessary to prepare raw values
   * for validation (see {@link #validate} and {@link #isValid}).  This method
   * is expected to return the processed value for the field which will
   * be used for validation (see validateValue method).
   * @param {Mixed} value
   */
  processValue: function processValue(value) {
    return value;
  },

  /**
   * @private
   * Subclasses should provide the validation implementation by overriding this
   * @param {Mixed} value
   */
  validateValue: function validateValue(value) {
    return true;
  },

  /**
   * Gets the active error message for this field.
   * @return {String} Returns the active error message on the field, if there is no error, an empty string is returned.
   */
  getActiveError: function getActiveError() {
    return this.activeError || '';
  },

  /**
   * <p>Display an error message associated with this field, using {@link #msgTarget} to determine how to
   * display the message and applying {@link #invalidClass} to the field's UI element.</p>
   * <p><b>Note</b>: this method does not cause the Field's {@link #validate} method to return <code>false</code>
   * if the value does <i>pass</i> validation. So simply marking a Field as invalid will not prevent
   * submission of forms submitted with the {@link Ext.form.Action.Submit#clientValidation} option set.</p>
   * {@link #isValid invalid}.
   * @param {String} msg (optional) The validation message (defaults to {@link #invalidText})
   */
  markInvalid: function markInvalid(msg) {
    if (!this.rendered || this.preventMark) {
      // not rendered
      return;
    }

    msg = msg || this.invalidText;
    var mt = this.getMessageHandler();

    if (mt) {
      mt.mark(this, msg);
    } else if (this.msgTarget) {
      this.el.addClass(this.invalidClass);
      var t = Ext.getDom(this.msgTarget);

      if (t) {
        t.innerHTML = msg;
        t.style.display = this.msgDisplay;
      }
    }

    this.activeError = msg;
    this.fireEvent('invalid', this, msg);
  },

  /**
   * Clear any invalid styles/messages for this field
   */
  clearInvalid: function clearInvalid() {
    if (!this.rendered || this.preventMark) {
      // not rendered
      return;
    }

    this.el.removeClass(this.invalidClass);
    var mt = this.getMessageHandler();

    if (mt) {
      mt.clear(this);
    } else if (this.msgTarget) {
      this.el.removeClass(this.invalidClass);
      var t = Ext.getDom(this.msgTarget);

      if (t) {
        t.innerHTML = '';
        t.style.display = 'none';
      }
    }

    delete this.activeError;
    this.fireEvent('valid', this);
  },
  // private
  getMessageHandler: function getMessageHandler() {
    return Ext.form.MessageTargets[this.msgTarget];
  },
  // private
  getErrorCt: function getErrorCt() {
    return this.el.findParent('.x-form-element', 5, true) || // use form element wrap if available
    this.el.findParent('.x-form-field-wrap', 5, true); // else direct field wrap
  },
  // Alignment for 'under' target
  alignErrorEl: function alignErrorEl() {
    this.errorEl.setWidth(this.getErrorCt().getWidth(true) - 20);
  },
  // Alignment for 'side' target
  alignErrorIcon: function alignErrorIcon() {
    this.errorIcon.alignTo(this.el, 'tl-tr', [2, 0]);
  },

  /**
   * Returns the raw data value which may or may not be a valid, defined value.  To return a normalized value see {@link #getValue}.
   * @return {Mixed} value The field value
   */
  getRawValue: function getRawValue() {
    var v = this.rendered ? this.el.getValue() || "" : Ext.value(this.value, '');

    if (v === this.emptyText) {
      v = '';
    }

    return v;
  },

  /**
   * Returns the normalized data value (undefined or emptyText will be returned as '').  To return the raw value see {@link #getRawValue}.
   * @return {Mixed} value The field value
   */
  getValue: function getValue() {
    if (!this.rendered) {
      return this.value;
    }

    var v = this.el.getValue();

    if (v === this.emptyText || v === undefined) {
      v = '';
    }

    return v;
  },

  /**
   * Sets the underlying DOM field's value directly, bypassing validation.  To set the value with validation see {@link #setValue}.
   * @param {Mixed} value The value to set
   * @return {Mixed} value The field value that is set
   */
  setRawValue: function setRawValue(v) {
    return this.rendered && this.el.dom ? this.el.dom.value = Ext.isEmpty(v) ? '' : v : '';
  },

  /**
   * Sets a data value into the field and validates it.  To set the value directly without validation see {@link #setRawValue}.
   * @param {Mixed} value The value to set
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(v) {
    this.value = v;

    if (this.rendered) {
      this.el.dom.value = Ext.isEmpty(v) ? '' : v;
      this.validate();
    }

    return this;
  },
  // private, does not work for all fields
  append: function append(v) {
    this.setValue([this.getValue(), v].join(''));
  }
  /**
   * @cfg {Boolean} autoWidth @hide
   */

  /**
   * @cfg {Boolean} autoHeight @hide
   */

  /**
   * @cfg {String} autoEl @hide
   */

});
Ext.form.MessageTargets = {
  'qtip': {
    mark: function mark(field, msg) {
      field.el.addClass(field.invalidClass);
      field.el.dom.qtip = msg;
      field.el.dom.qclass = 'x-form-invalid-tip';

      if (Ext.QuickTips) {
        // fix for floating editors interacting with DND
        Ext.QuickTips.enable();
      }
    },
    clear: function clear(field) {
      var _field$dom;

      field.el.removeClass(field.invalidClass);
      if (field === null || field === void 0 ? void 0 : (_field$dom = field.dom) === null || _field$dom === void 0 ? void 0 : _field$dom.dom) field.el.dom.qtip = '';
    }
  },
  'title': {
    mark: function mark(field, msg) {
      field.el.addClass(field.invalidClass);
      field.el.dom.title = msg;
    },
    clear: function clear(field) {
      field.el.dom.title = '';
    }
  },
  'under': {
    mark: function mark(field, msg) {
      field.el.addClass(field.invalidClass);

      if (!field.errorEl) {
        var elp = field.getErrorCt();

        if (!elp) {
          // field has no container el
          field.el.dom.title = msg;
          return;
        }

        field.errorEl = elp.createChild({
          cls: 'x-form-invalid-msg'
        });
        field.on('resize', field.alignErrorEl, field);
        field.on('destroy', function () {
          Ext.destroy(this.errorEl);
        }, field);
      }

      field.alignErrorEl();
      field.errorEl.update(msg);
      Ext.form.Field.msgFx[field.msgFx].show(field.errorEl, field);
    },
    clear: function clear(field) {
      field.el.removeClass(field.invalidClass);

      if (field.errorEl) {
        Ext.form.Field.msgFx[field.msgFx].hide(field.errorEl, field);
      } else {
        field.el.dom.title = '';
      }
    }
  },
  'side': {
    mark: function mark(field, msg) {
      field.el.addClass(field.invalidClass);

      if (!field.errorIcon) {
        var elp = field.getErrorCt();

        if (!elp) {
          // field has no container el
          field.el.dom.title = msg;
          return;
        }

        field.errorIcon = elp.createChild({
          cls: 'x-form-invalid-icon'
        });
        field.on('resize', field.alignErrorIcon, field);
        field.on('destroy', function () {
          Ext.destroy(this.errorIcon);
        }, field);
      }

      field.alignErrorIcon();
      field.errorIcon.dom.qtip = msg;
      field.errorIcon.dom.qclass = 'x-form-invalid-tip';
      field.errorIcon.show();
    },
    clear: function clear(field) {
      field.el.removeClass(field.invalidClass);

      if (field.errorIcon) {
        field.errorIcon.dom.qtip = '';
        field.errorIcon.hide();
      } else {
        field.el.dom.title = '';
      }
    }
  }
}; // anything other than normal should be considered experimental

Ext.form.Field.msgFx = {
  normal: {
    show: function show(msgEl, f) {
      msgEl.setDisplayed('block');
    },
    hide: function hide(msgEl, f) {
      msgEl.setDisplayed(false).update('');
    }
  },
  slide: {
    show: function show(msgEl, f) {
      msgEl.slideIn('t', {
        stopFx: true
      });
    },
    hide: function hide(msgEl, f) {
      msgEl.slideOut('t', {
        stopFx: true,
        useDisplay: true
      });
    }
  },
  slideRight: {
    show: function show(msgEl, f) {
      msgEl.fixDisplay();
      msgEl.alignTo(f.el, 'tl-tr');
      msgEl.slideIn('l', {
        stopFx: true
      });
    },
    hide: function hide(msgEl, f) {
      msgEl.slideOut('l', {
        stopFx: true,
        useDisplay: true
      });
    }
  }
};
Ext.reg('field', Ext.form.Field);

/***/ }),
/* 870 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.TextField
 * @extends Ext.form.Field
 * <p>Basic text field.  Can be used as a direct replacement for traditional text inputs,
 * or as the base class for more sophisticated input controls (like {@link Ext.form.TextArea}
 * and {@link Ext.form.ComboBox}).</p>
 * <p><b><u>Validation</u></b></p>
 * <p>The validation procedure is described in the documentation for {@link #validateValue}.</p>
 * <p><b><u>Alter Validation Behavior</u></b></p>
 * <p>Validation behavior for each field can be configured:</p>
 * <div class="mdetail-params"><ul>
 * <li><code>{@link Ext.form.TextField#invalidText invalidText}</code> : the default validation message to
 * show if any validation step above does not provide a message when invalid</li>
 * <li><code>{@link Ext.form.TextField#maskRe maskRe}</code> : filter out keystrokes before any validation occurs</li>
 * <li><code>{@link Ext.form.TextField#stripCharsRe stripCharsRe}</code> : filter characters after being typed in,
 * but before being validated</li>
 * <li><code>{@link Ext.form.Field#invalidClass invalidClass}</code> : alternate style when invalid</li>
 * <li><code>{@link Ext.form.Field#validateOnBlur validateOnBlur}</code>,
 * <code>{@link Ext.form.Field#validationDelay validationDelay}</code>, and
 * <code>{@link Ext.form.Field#validationEvent validationEvent}</code> : modify how/when validation is triggered</li>
 * </ul></div>
 * 
 * @constructor Creates a new TextField
 * @param {Object} config Configuration options
 * 
 * @xtype textfield
 */
Ext.form.TextField = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {String} vtypeText A custom error message to display in place of the default message provided
   * for the <b><code>{@link #vtype}</code></b> currently set for this field (defaults to <tt>''</tt>).  <b>Note</b>:
   * only applies if <b><code>{@link #vtype}</code></b> is set, else ignored.
   */

  /**
   * @cfg {RegExp} stripCharsRe A JavaScript RegExp object used to strip unwanted content from the value
   * before validation (defaults to <tt>null</tt>).
   */

  /**
   * @cfg {Boolean} grow <tt>true</tt> if this field should automatically grow and shrink to its content
   * (defaults to <tt>false</tt>)
   */
  grow: false,

  /**
   * @cfg {Number} growMin The minimum width to allow when <code><b>{@link #grow}</b> = true</code> (defaults
   * to <tt>30</tt>)
   */
  growMin: 30,

  /**
   * @cfg {Number} growMax The maximum width to allow when <code><b>{@link #grow}</b> = true</code> (defaults
   * to <tt>800</tt>)
   */
  growMax: 800,

  /**
   * @cfg {String} vtype A validation type name as defined in {@link Ext.form.VTypes} (defaults to <tt>null</tt>)
   */
  vtype: null,

  /**
   * @cfg {RegExp} maskRe An input mask regular expression that will be used to filter keystrokes that do
   * not match (defaults to <tt>null</tt>)
   */
  maskRe: null,

  /**
   * @cfg {Boolean} disableKeyFilter Specify <tt>true</tt> to disable input keystroke filtering (defaults
   * to <tt>false</tt>)
   */
  disableKeyFilter: false,

  /**
   * @cfg {Boolean} allowBlank Specify <tt>false</tt> to validate that the value's length is > 0 (defaults to
   * <tt>true</tt>)
   */
  allowBlank: true,

  /**
   * @cfg {Number} minLength Minimum input field length required (defaults to <tt>0</tt>)
   */
  minLength: 0,

  /**
   * @cfg {Number} maxLength Maximum input field length allowed by validation (defaults to Number.MAX_VALUE).
   * This behavior is intended to provide instant feedback to the user by improving usability to allow pasting
   * and editing or overtyping and back tracking. To restrict the maximum number of characters that can be
   * entered into the field use <tt><b>{@link Ext.form.Field#autoCreate autoCreate}</b></tt> to add
   * any attributes you want to a field, for example:<pre><code>
  var myField = new Ext.form.NumberField({
  id: 'mobile',
  anchor:'90%',
  fieldLabel: 'Mobile',
  maxLength: 16, // for validation
  autoCreate: {tag: 'input', type: 'text', size: '20', autocomplete: 'off', maxlength: '10'}
  });
  </code></pre>
   */
  maxLength: Number.MAX_VALUE,

  /**
   * @cfg {String} minLengthText Error text to display if the <b><tt>{@link #minLength minimum length}</tt></b>
   * validation fails (defaults to <tt>'The minimum length for this field is {minLength}'</tt>)
   */
  minLengthText: 'The minimum length for this field is {0}',

  /**
   * @cfg {String} maxLengthText Error text to display if the <b><tt>{@link #maxLength maximum length}</tt></b>
   * validation fails (defaults to <tt>'The maximum length for this field is {maxLength}'</tt>)
   */
  maxLengthText: 'The maximum length for this field is {0}',

  /**
   * @cfg {Boolean} selectOnFocus <tt>true</tt> to automatically select any existing field text when the field
   * receives input focus (defaults to <tt>false</tt>)
   */
  selectOnFocus: false,

  /**
   * @cfg {String} blankText The error text to display if the <b><tt>{@link #allowBlank}</tt></b> validation
   * fails (defaults to <tt>'This field is required'</tt>)
   */
  blankText: 'This field is required',

  /**
   * @cfg {Function} validator
   * <p>A custom validation function to be called during field validation ({@link #validateValue})
   * (defaults to <tt>null</tt>). If specified, this function will be called first, allowing the
   * developer to override the default validation process.</p>
   * <br><p>This function will be passed the following Parameters:</p>
   * <div class="mdetail-params"><ul>
   * <li><code>value</code>: <i>Mixed</i>
   * <div class="sub-desc">The current field value</div></li>
   * </ul></div>
   * <br><p>This function is to Return:</p>
   * <div class="mdetail-params"><ul>
   * <li><code>true</code>: <i>Boolean</i>
   * <div class="sub-desc"><code>true</code> if the value is valid</div></li>
   * <li><code>msg</code>: <i>String</i>
   * <div class="sub-desc">An error message if the value is invalid</div></li>
   * </ul></div>
   */
  validator: null,

  /**
   * @cfg {RegExp} regex A JavaScript RegExp object to be tested against the field value during validation
   * (defaults to <tt>null</tt>). If the test fails, the field will be marked invalid using
   * <b><tt>{@link #regexText}</tt></b>.
   */
  regex: null,

  /**
   * @cfg {String} regexText The error text to display if <b><tt>{@link #regex}</tt></b> is used and the
   * test fails during validation (defaults to <tt>''</tt>)
   */
  regexText: '',

  /**
   * @cfg {String} emptyText The default text to place into an empty field (defaults to <tt>null</tt>).
   * <b>Note</b>: that this value will be submitted to the server if this field is enabled and configured
   * with a {@link #name}.
   */
  emptyText: null,

  /**
   * @cfg {String} emptyClass The CSS class to apply to an empty field to style the <b><tt>{@link #emptyText}</tt></b>
   * (defaults to <tt>'x-form-empty-field'</tt>).  This class is automatically added and removed as needed
   * depending on the current field value.
   */
  emptyClass: 'x-form-empty-field',

  /**
   * @cfg {Boolean} enableKeyEvents <tt>true</tt> to enable the proxying of key events for the HTML input
   * field (defaults to <tt>false</tt>)
   */
  initComponent: function initComponent() {
    Ext.form.TextField.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event autosize
     * Fires when the <tt><b>{@link #autoSize}</b></tt> function is triggered. The field may or
     * may not have actually changed size according to the default logic, but this event provides
     * a hook for the developer to apply additional logic at runtime to resize the field if needed.
     * @param {Ext.form.Field} this This text field
     * @param {Number} width The new field width
     */
    'autosize',
    /**
     * @event keydown
     * Keydown input field event. This event only fires if <tt><b>{@link #enableKeyEvents}</b></tt>
     * is set to true.
     * @param {Ext.form.TextField} this This text field
     * @param {Ext.EventObject} e
     */
    'keydown',
    /**
     * @event keyup
     * Keyup input field event. This event only fires if <tt><b>{@link #enableKeyEvents}</b></tt>
     * is set to true.
     * @param {Ext.form.TextField} this This text field
     * @param {Ext.EventObject} e
     */
    'keyup',
    /**
     * @event keypress
     * Keypress input field event. This event only fires if <tt><b>{@link #enableKeyEvents}</b></tt>
     * is set to true.
     * @param {Ext.form.TextField} this This text field
     * @param {Ext.EventObject} e
     */
    'keypress');
  },
  // private
  initEvents: function initEvents() {
    Ext.form.TextField.superclass.initEvents.call(this);

    if (this.validationEvent == 'keyup') {
      this.validationTask = new Ext.util.DelayedTask(this.validate, this);
      this.mon(this.el, 'keyup', this.filterValidation, this);
    } else if (this.validationEvent !== false && this.validationEvent != 'blur') {
      this.mon(this.el, this.validationEvent, this.validate, this, {
        buffer: this.validationDelay
      });
    }

    if (this.selectOnFocus || this.emptyText) {
      this.mon(this.el, 'mousedown', this.onMouseDown, this);

      if (this.emptyText) {
        this.applyEmptyText();
      }
    }

    if (this.maskRe || this.vtype && this.disableKeyFilter !== true && (this.maskRe = Ext.form.VTypes[this.vtype + 'Mask'])) {
      this.mon(this.el, 'keypress', this.filterKeys, this);
    }

    if (this.grow) {
      this.mon(this.el, 'keyup', this.onKeyUpBuffered, this, {
        buffer: 50
      });
      this.mon(this.el, 'paste', this.onKeyUpBuffered, this, {
        buffer: 50
      });
      this.mon(this.el, 'click', this.autoSize, this);
    }

    if (this.enableKeyEvents) {
      this.mon(this.el, {
        scope: this,
        keyup: this.onKeyUp,
        paste: this.onPaste,
        keydown: this.onKeyDown,
        keypress: this.onKeyPress
      });
    }
  },
  onMouseDown: function onMouseDown(e) {
    if (!this.hasFocus) {
      this.mon(this.el, 'mouseup', Ext.emptyFn, this, {
        single: true,
        preventDefault: true
      });
    }
  },
  processValue: function processValue(value) {
    if (this.stripCharsRe) {
      var newValue = value.replace(this.stripCharsRe, '');

      if (newValue !== value) {
        this.setRawValue(newValue);
        return newValue;
      }
    }

    return value;
  },
  filterValidation: function filterValidation(e) {
    if (!e.isNavKeyPress()) {
      this.validationTask.delay(this.validationDelay);
    }
  },
  //private
  onDisable: function onDisable() {
    Ext.form.TextField.superclass.onDisable.call(this);

    if (Ext.isIE) {
      this.el.dom.unselectable = 'on';
    }
  },
  //private
  onEnable: function onEnable() {
    Ext.form.TextField.superclass.onEnable.call(this);

    if (Ext.isIE) {
      this.el.dom.unselectable = '';
    }
  },
  // private
  onKeyUpBuffered: function onKeyUpBuffered(e) {
    if (this.doAutoSize(e)) {
      this.autoSize();
    }
  },
  // private
  doAutoSize: function doAutoSize(e) {
    return !e.isNavKeyPress();
  },
  // private
  onKeyUp: function onKeyUp(e) {
    this.fireEvent('keyup', this, e);
  },
  // private
  onPaste: function onPaste(e) {
    this.fireEvent('paste', this, e);
  },
  // private
  onKeyDown: function onKeyDown(e) {
    this.fireEvent('keydown', this, e);
  },
  // private
  onKeyPress: function onKeyPress(e) {
    this.fireEvent('keypress', this, e);
  },

  /**
   * Resets the current field value to the originally-loaded value and clears any validation messages.
   * Also adds <tt><b>{@link #emptyText}</b></tt> and <tt><b>{@link #emptyClass}</b></tt> if the
   * original value was blank.
   */
  reset: function reset() {
    Ext.form.TextField.superclass.reset.call(this);
    this.applyEmptyText();
  },
  applyEmptyText: function applyEmptyText() {
    if (this.rendered && this.el.dom && this.emptyText && this.getRawValue().length < 1 && !this.hasFocus) {
      this.setRawValue(this.emptyText);
      this.el.addClass(this.emptyClass);
    }
  },
  // private
  preFocus: function preFocus() {
    var el = this.el;

    if (this.emptyText) {
      if (el.dom.value == this.emptyText) {
        this.setRawValue('');
      }

      el.removeClass(this.emptyClass);
    }

    if (this.selectOnFocus) {
      el.dom.select();
    }
  },
  // private
  postBlur: function postBlur() {
    this.applyEmptyText();
  },
  // private
  filterKeys: function filterKeys(e) {
    if (e.ctrlKey) {
      return;
    }

    var k = e.getKey();

    if (Ext.isGecko && (e.isNavKeyPress() || k == e.BACKSPACE || k == e.DELETE && e.button == -1)) {
      return;
    }

    var cc = String.fromCharCode(e.getCharCode());

    if (!Ext.isGecko && e.isSpecialKey() && !cc) {
      return;
    }

    if (!this.maskRe.test(cc)) {
      e.stopEvent();
    }
  },
  setValue: function setValue(v) {
    if (this.emptyText && this.el && !Ext.isEmpty(v)) {
      this.el.removeClass(this.emptyClass);
    }

    Ext.form.TextField.superclass.setValue.apply(this, arguments);
    this.applyEmptyText();
    this.autoSize();
    return this;
  },

  /**
   * <p>Validates a value according to the field's validation rules and marks the field as invalid
   * if the validation fails. Validation rules are processed in the following order:</p>
   * <div class="mdetail-params"><ul>
   * 
   * <li><b>1. Field specific validator</b>
   * <div class="sub-desc">
   * <p>A validator offers a way to customize and reuse a validation specification.
   * If a field is configured with a <code>{@link #validator}</code>
   * function, it will be passed the current field value.  The <code>{@link #validator}</code>
   * function is expected to return either:
   * <div class="mdetail-params"><ul>
   * <li>Boolean <tt>true</tt> if the value is valid (validation continues).</li>
   * <li>a String to represent the invalid message if invalid (validation halts).</li>
   * </ul></div>
   * </div></li>
   * 
   * <li><b>2. Basic Validation</b>
   * <div class="sub-desc">
   * <p>If the <code>{@link #validator}</code> has not halted validation,
   * basic validation proceeds as follows:</p>
   * 
   * <div class="mdetail-params"><ul>
   * 
   * <li><code>{@link #allowBlank}</code> : (Invalid message =
   * <code>{@link #emptyText}</code>)<div class="sub-desc">
   * Depending on the configuration of <code>{@link #allowBlank}</code>, a
   * blank field will cause validation to halt at this step and return
   * Boolean true or false accordingly.  
   * </div></li>
   * 
   * <li><code>{@link #minLength}</code> : (Invalid message =
   * <code>{@link #minLengthText}</code>)<div class="sub-desc">
   * If the passed value does not satisfy the <code>{@link #minLength}</code>
   * specified, validation halts.
   * </div></li>
   * 
   * <li><code>{@link #maxLength}</code> : (Invalid message =
   * <code>{@link #maxLengthText}</code>)<div class="sub-desc">
   * If the passed value does not satisfy the <code>{@link #maxLength}</code>
   * specified, validation halts.
   * </div></li>
   * 
   * </ul></div>
   * </div></li>
   * 
   * <li><b>3. Preconfigured Validation Types (VTypes)</b>
   * <div class="sub-desc">
   * <p>If none of the prior validation steps halts validation, a field
   * configured with a <code>{@link #vtype}</code> will utilize the
   * corresponding {@link Ext.form.VTypes VTypes} validation function.
   * If invalid, either the field's <code>{@link #vtypeText}</code> or
   * the VTypes vtype Text property will be used for the invalid message.
   * Keystrokes on the field will be filtered according to the VTypes
   * vtype Mask property.</p>
   * </div></li>
   * 
   * <li><b>4. Field specific regex test</b>
   * <div class="sub-desc">
   * <p>If none of the prior validation steps halts validation, a field's
   * configured <code>{@link #regex}</code> test will be processed.
   * The invalid message for this test is configured with
   * <code>{@link #regexText}</code>.</p>
   * </div></li>
   * 
   * @param {Mixed} value The value to validate
   * @return {Boolean} True if the value is valid, else false
   */
  validateValue: function validateValue(value) {
    if (Ext.isFunction(this.validator)) {
      var msg = this.validator(value);

      if (msg !== true) {
        this.markInvalid(msg);
        return false;
      }
    }

    if (value.length < 1 || value === this.emptyText) {
      // if it's blank
      if (this.allowBlank) {
        this.clearInvalid();
        return true;
      } else {
        this.markInvalid(this.blankText);
        return false;
      }
    }

    if (value.length < this.minLength) {
      this.markInvalid(String.format(this.minLengthText, this.minLength));
      return false;
    }

    if (value.length > this.maxLength) {
      this.markInvalid(String.format(this.maxLengthText, this.maxLength));
      return false;
    }

    if (this.vtype) {
      var vt = Ext.form.VTypes;

      if (!vt[this.vtype](value, this)) {
        this.markInvalid(this.vtypeText || vt[this.vtype + 'Text']);
        return false;
      }
    }

    if (this.regex && !this.regex.test(value)) {
      this.markInvalid(this.regexText);
      return false;
    }

    return true;
  },

  /**
   * Selects text in this field
   * @param {Number} start (optional) The index where the selection should start (defaults to 0)
   * @param {Number} end (optional) The index where the selection should end (defaults to the text length)
   */
  selectText: function selectText(start, end) {
    var v = this.getRawValue();
    var doFocus = false;

    if (v.length > 0) {
      start = start === undefined ? 0 : start;
      end = end === undefined ? v.length : end;
      var d = this.el.dom;

      if (d.setSelectionRange) {
        d.setSelectionRange(start, end);
      } else if (d.createTextRange) {
        var range = d.createTextRange();
        range.moveStart('character', start);
        range.moveEnd('character', end - v.length);
        range.select();
      }

      doFocus = Ext.isGecko || Ext.isOpera;
    } else {
      doFocus = true;
    }

    if (doFocus) {
      this.focus();
    }
  },

  /**
   * Automatically grows the field to accomodate the width of the text up to the maximum field width allowed.
   * This only takes effect if <tt><b>{@link #grow}</b> = true</tt>, and fires the {@link #autosize} event.
   */
  autoSize: function autoSize() {
    if (!this.grow || !this.rendered) {
      return;
    }

    if (!this.metrics) {
      this.metrics = Ext.util.TextMetrics.createInstance(this.el);
    }

    var el = this.el;
    var v = el.dom.value;
    var d = document.createElement('div');
    d.appendChild(document.createTextNode(v));
    v = d.innerHTML;
    Ext.removeNode(d);
    d = null;
    v += '&#160;';
    var w = Math.min(this.growMax, Math.max(this.metrics.getWidth(v) +
    /* add extra padding */
    10, this.growMin));
    this.el.setWidth(w);
    this.fireEvent('autosize', this, w);
  },
  onDestroy: function onDestroy() {
    if (this.validationTask) {
      this.validationTask.cancel();
      this.validationTask = null;
    }

    Ext.form.TextField.superclass.onDestroy.call(this);
  }
});
Ext.reg('textfield', Ext.form.TextField);

/***/ }),
/* 871 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.TriggerField
 * @extends Ext.form.TextField
 * Provides a convenient wrapper for TextFields that adds a clickable trigger button (looks like a combobox by default).
 * The trigger has no default action, so you must assign a function to implement the trigger click handler by
 * overriding {@link #onTriggerClick}. You can create a TriggerField directly, as it renders exactly like a combobox
 * for which you can provide a custom implementation.  For example:
 * <pre><code>
var trigger = new Ext.form.TriggerField();
trigger.onTriggerClick = myTriggerFn;
trigger.applyToMarkup('my-field');
</code></pre>
 *
 * However, in general you will most likely want to use TriggerField as the base class for a reusable component.
 * {@link Ext.form.DateField} and {@link Ext.form.ComboBox} are perfect examples of this.
 *
 * @constructor
 * Create a new TriggerField.
 * @param {Object} config Configuration options (valid {@Ext.form.TextField} config options will also be applied
 * to the base TextField)
 * @xtype trigger
 */
Ext.form.TriggerField = Ext.extend(Ext.form.TextField, {
  /**
   * @cfg {String} triggerClass
   * An additional CSS class used to style the trigger button.  The trigger will always get the
   * class <tt>'x-form-trigger'</tt> by default and <tt>triggerClass</tt> will be <b>appended</b> if specified.
   */

  /**
   * @cfg {Mixed} triggerConfig
   * <p>A {@link Ext.DomHelper DomHelper} config object specifying the structure of the
   * trigger element for this Field. (Optional).</p>
   * <p>Specify this when you need a customized element to act as the trigger button for a TriggerField.</p>
   * <p>Note that when using this option, it is the developer's responsibility to ensure correct sizing, positioning
   * and appearance of the trigger.  Defaults to:</p>
   * <pre><code>{tag: "img", src: Ext.BLANK_IMAGE_URL, cls: "x-form-trigger " + this.triggerClass}</code></pre>
   */

  /**
   * @cfg {String/Object} autoCreate <p>A {@link Ext.DomHelper DomHelper} element spec, or true for a default
   * element spec. Used to create the {@link Ext.Component#getEl Element} which will encapsulate this Component.
   * See <tt>{@link Ext.Component#autoEl autoEl}</tt> for details.  Defaults to:</p>
   * <pre><code>{tag: "input", type: "text", size: "16", autocomplete: "off"}</code></pre>
   */
  defaultAutoCreate: {
    tag: "input",
    type: "text",
    size: "16",
    autocomplete: "off"
  },

  /**
   * @cfg {Boolean} hideTrigger <tt>true</tt> to hide the trigger element and display only the base
   * text field (defaults to <tt>false</tt>)
   */
  hideTrigger: false,

  /**
   * @cfg {Boolean} editable <tt>false</tt> to prevent the user from typing text directly into the field,
   * the field will only respond to a click on the trigger to set the value. (defaults to <tt>true</tt>).
   */
  editable: true,

  /**
   * @cfg {Boolean} readOnly <tt>true</tt> to prevent the user from changing the field, and
   * hides the trigger.  Superceeds the editable and hideTrigger options if the value is true.
   * (defaults to <tt>false</tt>)
   */
  readOnly: false,

  /**
   * @cfg {String} wrapFocusClass The class added to the to the wrap of the trigger element. Defaults to
   * <tt>x-trigger-wrap-focus</tt>.
   */
  wrapFocusClass: 'x-trigger-wrap-focus',

  /**
   * @hide
   * @method autoSize
   */
  autoSize: Ext.emptyFn,
  // private
  monitorTab: true,
  // private
  deferHeight: true,
  // private
  mimicing: false,
  actionMode: 'wrap',
  defaultTriggerWidth: 17,
  // private
  onResize: function onResize(w, h) {
    Ext.form.TriggerField.superclass.onResize.call(this, w, h);
    var tw = this.getTriggerWidth();

    if (Ext.isNumber(w)) {
      this.el.setWidth(w - tw);
    }

    this.wrap.setWidth(this.el.getWidth() + tw);
  },
  getTriggerWidth: function getTriggerWidth() {
    var tw = this.trigger.getWidth();

    if (!(this.hideTrigger || this.readOnly) && tw === 0) {
      tw = this.defaultTriggerWidth;
    }

    return tw;
  },
  // private
  alignErrorIcon: function alignErrorIcon() {
    if (this.wrap) {
      this.errorIcon.alignTo(this.wrap, 'tl-tr', [2, 0]);
    }
  },
  // private
  onRender: function onRender(ct, position) {
    this.doc = Ext.isIE ? Ext.getBody() : Ext.getDoc();
    Ext.form.TriggerField.superclass.onRender.call(this, ct, position);
    this.wrap = this.el.wrap({
      cls: 'x-form-field-wrap x-form-field-trigger-wrap'
    });
    this.trigger = this.wrap.createChild(this.triggerConfig || {
      tag: "img",
      src: Ext.BLANK_IMAGE_URL,
      cls: "x-form-trigger " + this.triggerClass
    });
    this.initTrigger();

    if (!this.width) {
      this.wrap.setWidth(this.el.getWidth() + this.trigger.getWidth());
    }

    this.resizeEl = this.positionEl = this.wrap;
  },
  updateEditState: function updateEditState() {
    if (this.rendered) {
      if (this.readOnly) {
        this.el.dom.readOnly = true;
        this.el.addClass('x-trigger-noedit');
        this.mun(this.el, 'click', this.onTriggerClick, this);
        this.trigger.setDisplayed(false);
      } else {
        if (!this.editable) {
          this.el.dom.readOnly = true;
          this.el.addClass('x-trigger-noedit');
          this.mon(this.el, 'click', this.onTriggerClick, this);
        } else {
          this.el.dom.readOnly = false;
          this.el.removeClass('x-trigger-noedit');
          this.mun(this.el, 'click', this.onTriggerClick, this);
        }

        this.trigger.setDisplayed(!this.hideTrigger);
      }

      this.onResize(this.width || this.wrap.getWidth());
    }
  },
  setHideTrigger: function setHideTrigger(hideTrigger) {
    if (hideTrigger != this.hideTrigger) {
      this.hideTrigger = hideTrigger;
      this.updateEditState();
    }
  },

  /**
   * @param {Boolean} value True to allow the user to directly edit the field text
   * Allow or prevent the user from directly editing the field text.  If false is passed,
   * the user will only be able to modify the field using the trigger.  Will also add
   * a click event to the text field which will call the trigger. This method
   * is the runtime equivalent of setting the 'editable' config option at config time.
   */
  setEditable: function setEditable(editable) {
    if (editable != this.editable) {
      this.editable = editable;
      this.updateEditState();
    }
  },

  /**
   * @param {Boolean} value True to prevent the user changing the field and explicitly
   * hide the trigger.
   * Setting this to true will superceed settings editable and hideTrigger.
   * Setting this to false will defer back to editable and hideTrigger. This method
   * is the runtime equivalent of setting the 'readOnly' config option at config time.
   */
  setReadOnly: function setReadOnly(readOnly) {
    if (readOnly != this.readOnly) {
      this.readOnly = readOnly;
      this.updateEditState();
    }
  },
  afterRender: function afterRender() {
    Ext.form.TriggerField.superclass.afterRender.call(this);
    this.updateEditState();
  },
  // private
  initTrigger: function initTrigger() {
    this.mon(this.trigger, 'click', this.onTriggerClick, this, {
      preventDefault: true
    });
    this.trigger.addClassOnOver('x-form-trigger-over');
    this.trigger.addClassOnClick('x-form-trigger-click');
  },
  // private
  onDestroy: function onDestroy() {
    Ext.destroy(this.trigger, this.wrap);

    if (this.mimicing) {
      this.doc.un('mousedown', this.mimicBlur, this);
    }

    delete this.doc;
    Ext.form.TriggerField.superclass.onDestroy.call(this);
  },
  // private
  onFocus: function onFocus() {
    Ext.form.TriggerField.superclass.onFocus.call(this);

    if (!this.mimicing) {
      this.wrap.addClass(this.wrapFocusClass);
      this.mimicing = true;
      this.doc.on('mousedown', this.mimicBlur, this, {
        delay: 10
      });

      if (this.monitorTab) {
        this.on('specialkey', this.checkTab, this);
      }
    }
  },
  // private
  checkTab: function checkTab(me, e) {
    if (e.getKey() == e.TAB) {
      this.triggerBlur();
    }
  },
  // private
  // clicking in list would blur field -> see minicBlur
  onBlur: Ext.emptyFn,
  // private
  mimicBlur: function mimicBlur(e) {
    if (!this.isDestroyed && !this.wrap.contains(e.target) && this.validateBlur(e)) {
      this.triggerBlur();
    }
  },
  // private
  triggerBlur: function triggerBlur() {
    var _this$doc;

    this.mimicing = false;
    (_this$doc = this.doc) === null || _this$doc === void 0 ? void 0 : _this$doc.un('mousedown', this.mimicBlur, this);

    if (this.monitorTab && this.el) {
      this.un('specialkey', this.checkTab, this);
    }

    Ext.form.TriggerField.superclass.onBlur.call(this);

    if (this.wrap) {
      this.wrap.removeClass(this.wrapFocusClass);
    }
  },
  beforeBlur: Ext.emptyFn,
  // private
  // This should be overriden by any subclass that needs to check whether or not the field can be blurred.
  validateBlur: function validateBlur(e) {
    return true;
  },

  /**
   * The function that should handle the trigger's click event.  This method does nothing by default
   * until overridden by an implementing function.  See Ext.form.ComboBox and Ext.form.DateField for
   * sample implementations.
   * @method
   * @param {EventObject} e
   */
  onTriggerClick: Ext.emptyFn
  /**
   * @cfg {Boolean} grow @hide
   */

  /**
   * @cfg {Number} growMin @hide
   */

  /**
   * @cfg {Number} growMax @hide
   */

});
/**
 * @class Ext.form.TwinTriggerField
 * @extends Ext.form.TriggerField
 * TwinTriggerField is not a public class to be used directly.  It is meant as an abstract base class
 * to be extended by an implementing class.  For an example of implementing this class, see the custom
 * SearchField implementation here:
 * <a href="http://extjs.com/deploy/ext/examples/form/custom.html">http://extjs.com/deploy/ext/examples/form/custom.html</a>
 */

Ext.form.TwinTriggerField = Ext.extend(Ext.form.TriggerField, {
  /**
   * @cfg {Mixed} triggerConfig
   * <p>A {@link Ext.DomHelper DomHelper} config object specifying the structure of the trigger elements
   * for this Field. (Optional).</p>
   * <p>Specify this when you need a customized element to contain the two trigger elements for this Field.
   * Each trigger element must be marked by the CSS class <tt>x-form-trigger</tt> (also see
   * <tt>{@link #trigger1Class}</tt> and <tt>{@link #trigger2Class}</tt>).</p>
   * <p>Note that when using this option, it is the developer's responsibility to ensure correct sizing,
   * positioning and appearance of the triggers.</p>
   */

  /**
   * @cfg {String} trigger1Class
   * An additional CSS class used to style the trigger button.  The trigger will always get the
   * class <tt>'x-form-trigger'</tt> by default and <tt>triggerClass</tt> will be <b>appended</b> if specified.
   */

  /**
   * @cfg {String} trigger2Class
   * An additional CSS class used to style the trigger button.  The trigger will always get the
   * class <tt>'x-form-trigger'</tt> by default and <tt>triggerClass</tt> will be <b>appended</b> if specified.
   */
  initComponent: function initComponent() {
    Ext.form.TwinTriggerField.superclass.initComponent.call(this);
    this.triggerConfig = {
      tag: 'span',
      cls: 'x-form-twin-triggers',
      cn: [{
        tag: "img",
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger " + this.trigger1Class
      }, {
        tag: "img",
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger " + this.trigger2Class
      }]
    };
  },
  getTrigger: function getTrigger(index) {
    return this.triggers[index];
  },
  initTrigger: function initTrigger() {
    var ts = this.trigger.select('.x-form-trigger', true);
    var triggerField = this;
    ts.each(function (t, all, index) {
      var triggerIndex = 'Trigger' + (index + 1);

      t.hide = function () {
        var w = triggerField.wrap.getWidth();
        this.dom.style.display = 'none';
        triggerField.el.setWidth(w - triggerField.trigger.getWidth());
        this['hidden' + triggerIndex] = true;
      };

      t.show = function () {
        var w = triggerField.wrap.getWidth();
        this.dom.style.display = '';
        triggerField.el.setWidth(w - triggerField.trigger.getWidth());
        this['hidden' + triggerIndex] = false;
      };

      if (this['hide' + triggerIndex]) {
        t.dom.style.display = 'none';
        this['hidden' + triggerIndex] = true;
      }

      this.mon(t, 'click', this['on' + triggerIndex + 'Click'], this, {
        preventDefault: true
      });
      t.addClassOnOver('x-form-trigger-over');
      t.addClassOnClick('x-form-trigger-click');
    }, this);
    this.triggers = ts.elements;
  },
  onRender: function onRender(ct, position) {
    Ext.form.TwinTriggerField.superclass.onRender.apply(this, arguments);
    this.wrap.addClass('x-form-field-twin-trigger-wrap');
  },
  getTriggerWidth: function getTriggerWidth() {
    var tw = 0;
    Ext.each(this.triggers, function (t, index) {
      var triggerIndex = 'Trigger' + (index + 1),
          w = t.getWidth();

      if (w === 0 && !t['hidden' + triggerIndex]) {
        tw += this.defaultTriggerWidth;
      } else {
        tw += w;
      }
    }, this);
    return tw;
  },
  // private
  onDestroy: function onDestroy() {
    Ext.destroy(this.triggers);
    Ext.form.TwinTriggerField.superclass.onDestroy.call(this);
  },

  /**
   * The function that should handle the trigger's click event.  This method does nothing by default
   * until overridden by an implementing function. See {@link Ext.form.TriggerField#onTriggerClick}
   * for additional information.
   * @method
   * @param {EventObject} e
   */
  onTrigger1Click: Ext.emptyFn,

  /**
   * The function that should handle the trigger's click event.  This method does nothing by default
   * until overridden by an implementing function. See {@link Ext.form.TriggerField#onTriggerClick}
   * for additional information.
   * @method
   * @param {EventObject} e
   */
  onTrigger2Click: Ext.emptyFn
});
Ext.reg('trigger', Ext.form.TriggerField);

/***/ }),
/* 872 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.TextArea
 * @extends Ext.form.TextField
 * Multiline text field.  Can be used as a direct replacement for traditional textarea fields, plus adds
 * support for auto-sizing.
 * @constructor
 * Creates a new TextArea
 * @param {Object} config Configuration options
 * @xtype textarea
 */
Ext.form.TextArea = Ext.extend(Ext.form.TextField, {
  /**
   * @cfg {Number} growMin The minimum height to allow when <tt>{@link Ext.form.TextField#grow grow}=true</tt>
   * (defaults to <tt>60</tt>)
   */
  growMin: 60,

  /**
   * @cfg {Number} growMax The maximum height to allow when <tt>{@link Ext.form.TextField#grow grow}=true</tt>
   * (defaults to <tt>1000</tt>)
   */
  growMax: 1000,
  growAppend: '&#160;\n&#160;',
  enterIsSpecial: false,

  /**
   * @cfg {Boolean} preventScrollbars <tt>true</tt> to prevent scrollbars from appearing regardless of how much text is
   * in the field. This option is only relevant when {@link #grow} is <tt>true</tt>. Equivalent to setting overflow: hidden, defaults to 
   * <tt>false</tt>.
   */
  preventScrollbars: false,

  /**
   * @cfg {String/Object} autoCreate <p>A {@link Ext.DomHelper DomHelper} element spec, or true for a default
   * element spec. Used to create the {@link Ext.Component#getEl Element} which will encapsulate this Component.
   * See <tt>{@link Ext.Component#autoEl autoEl}</tt> for details.  Defaults to:</p>
   * <pre><code>{tag: "textarea", style: "width:100px;height:60px;", autocomplete: "off"}</code></pre>
   */
  // private
  onRender: function onRender(ct, position) {
    if (!this.el) {
      this.defaultAutoCreate = {
        tag: "textarea",
        style: "width:100px;height:60px;",
        autocomplete: "off"
      };
    }

    Ext.form.TextArea.superclass.onRender.call(this, ct, position);

    if (this.grow) {
      this.textSizeEl = Ext.DomHelper.append(document.body, {
        tag: "pre",
        cls: "x-form-grow-sizer"
      });

      if (this.preventScrollbars) {
        this.el.setStyle("overflow", "hidden");
      }

      this.el.setHeight(this.growMin);
    }
  },
  onDestroy: function onDestroy() {
    Ext.removeNode(this.textSizeEl);
    Ext.form.TextArea.superclass.onDestroy.call(this);
  },
  fireKey: function fireKey(e) {
    if (e.isSpecialKey() && (this.enterIsSpecial || e.getKey() != e.ENTER || e.hasModifier())) {
      this.fireEvent("specialkey", this, e);
    }
  },
  // private
  doAutoSize: function doAutoSize(e) {
    return !e.isNavKeyPress() || e.getKey() == e.ENTER;
  },

  /**
   * Automatically grows the field to accomodate the height of the text up to the maximum field height allowed.
   * This only takes effect if grow = true, and fires the {@link #autosize} event if the height changes.
   */
  autoSize: function autoSize() {
    if (!this.grow || !this.textSizeEl) {
      return;
    }

    var el = this.el,
        v = Ext.util.Format.htmlEncode(el.dom.value),
        ts = this.textSizeEl,
        h;
    Ext.fly(ts).setWidth(this.el.getWidth());

    if (v.length < 1) {
      v = "&#160;&#160;";
    } else {
      v += this.growAppend;

      if (Ext.isIE) {
        v = v.replace(/\n/g, '&#160;<br />');
      }
    }

    ts.innerHTML = v;
    h = Math.min(this.growMax, Math.max(ts.offsetHeight, this.growMin));

    if (h != this.lastHeight) {
      this.lastHeight = h;
      this.el.setHeight(h);
      this.fireEvent("autosize", this, h);
    }
  }
});
Ext.reg('textarea', Ext.form.TextArea);

/***/ }),
/* 873 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.NumberField
 * @extends Ext.form.TextField
 * Numeric text field that provides automatic keystroke filtering and numeric validation.
 * @constructor
 * Creates a new NumberField
 * @param {Object} config Configuration options
 * @xtype numberfield
 */
Ext.form.NumberField = Ext.extend(Ext.form.TextField, {
  /**
   * @cfg {RegExp} stripCharsRe @hide
   */

  /**
   * @cfg {RegExp} maskRe @hide
   */

  /**
   * @cfg {String} fieldClass The default CSS class for the field (defaults to "x-form-field x-form-num-field")
   */
  fieldClass: "x-form-field x-form-num-field",

  /**
   * @cfg {Boolean} allowDecimals False to disallow decimal values (defaults to true)
   */
  allowDecimals: true,

  /**
   * @cfg {String} decimalSeparator Character(s) to allow as the decimal separator (defaults to '.')
   */
  decimalSeparator: ".",

  /**
   * @cfg {Number} decimalPrecision The maximum precision to display after the decimal separator (defaults to 2)
   */
  decimalPrecision: 2,

  /**
   * @cfg {Boolean} allowNegative False to prevent entering a negative sign (defaults to true)
   */
  allowNegative: true,

  /**
   * @cfg {Number} minValue The minimum allowed value (defaults to Number.NEGATIVE_INFINITY)
   */
  minValue: Number.NEGATIVE_INFINITY,

  /**
   * @cfg {Number} maxValue The maximum allowed value (defaults to Number.MAX_VALUE)
   */
  maxValue: Number.MAX_VALUE,

  /**
   * @cfg {String} minText Error text to display if the minimum value validation fails (defaults to "The minimum value for this field is {minValue}")
   */
  minText: "The minimum value for this field is {0}",

  /**
   * @cfg {String} maxText Error text to display if the maximum value validation fails (defaults to "The maximum value for this field is {maxValue}")
   */
  maxText: "The maximum value for this field is {0}",

  /**
   * @cfg {String} nanText Error text to display if the value is not a valid number.  For example, this can happen
   * if a valid character like '.' or '-' is left in the field with no number (defaults to "{value} is not a valid number")
   */
  nanText: "{0} is not a valid number",

  /**
   * @cfg {String} baseChars The base set of characters to evaluate as valid numbers (defaults to '0123456789').
   */
  baseChars: "0123456789",
  // private
  initEvents: function initEvents() {
    var allowed = this.baseChars + '';

    if (this.allowDecimals) {
      allowed += this.decimalSeparator;
    }

    if (this.allowNegative) {
      allowed += '-';
    }

    this.maskRe = new RegExp('[' + Ext.escapeRe(allowed) + ']');
    Ext.form.NumberField.superclass.initEvents.call(this);
  },
  // private
  validateValue: function validateValue(value) {
    if (!Ext.form.NumberField.superclass.validateValue.call(this, value)) {
      return false;
    }

    if (value.length < 1) {
      // if it's blank and textfield didn't flag it then it's valid
      return true;
    }

    value = String(value).replace(this.decimalSeparator, ".");

    if (isNaN(value)) {
      this.markInvalid(String.format(this.nanText, value));
      return false;
    }

    var num = this.parseValue(value);

    if (num < this.minValue) {
      this.markInvalid(String.format(this.minText, this.minValue));
      return false;
    }

    if (num > this.maxValue) {
      this.markInvalid(String.format(this.maxText, this.maxValue));
      return false;
    }

    return true;
  },
  getValue: function getValue() {
    return this.fixPrecision(this.parseValue(Ext.form.NumberField.superclass.getValue.call(this)));
  },
  setValue: function setValue(v) {
    v = Ext.isNumber(v) ? v : parseFloat(String(v).replace(this.decimalSeparator, "."));
    v = isNaN(v) ? '' : String(v).replace(".", this.decimalSeparator);
    return Ext.form.NumberField.superclass.setValue.call(this, v);
  },

  /**
   * Replaces any existing {@link #minValue} with the new value.
   * @param {Number} value The minimum value
   */
  setMinValue: function setMinValue(value) {
    this.minValue = Ext.num(value, Number.NEGATIVE_INFINITY);
  },

  /**
   * Replaces any existing {@link #maxValue} with the new value.
   * @param {Number} value The maximum value
   */
  setMaxValue: function setMaxValue(value) {
    this.maxValue = Ext.num(value, Number.MAX_VALUE);
  },
  // private
  parseValue: function parseValue(value) {
    value = parseFloat(String(value).replace(this.decimalSeparator, "."));
    return isNaN(value) ? '' : value;
  },
  // private
  fixPrecision: function fixPrecision(value) {
    var nan = isNaN(value);

    if (!this.allowDecimals || this.decimalPrecision == -1 || nan || !value) {
      return nan ? '' : value;
    }

    return parseFloat(parseFloat(value).toFixed(this.decimalPrecision));
  },
  beforeBlur: function beforeBlur() {
    var v = this.parseValue(this.getRawValue());

    if (!Ext.isEmpty(v)) {
      this.setValue(this.fixPrecision(v));
    }
  }
});
Ext.reg('numberfield', Ext.form.NumberField);

/***/ }),
/* 874 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.DateField
 * @extends Ext.form.TriggerField
 * Provides a date input field with a {@link Ext.DatePicker} dropdown and automatic date validation.
 * @constructor
 * Create a new DateField
 * @param {Object} config
 * @xtype datefield
 */
Ext.form.DateField = Ext.extend(Ext.form.TriggerField, {
  /**
   * @cfg {String} format
   * The default date format string which can be overriden for localization support.  The format must be
   * valid according to {@link Date#parseDate} (defaults to <tt>'m/d/Y'</tt>).
   */
  format: "m/d/Y",

  /**
   * @cfg {String} altFormats
   * Multiple date formats separated by "<tt>|</tt>" to try when parsing a user input value and it
   * does not match the defined format (defaults to
   * <tt>'m/d/Y|n/j/Y|n/j/y|m/j/y|n/d/y|m/j/Y|n/d/Y|m-d-y|m-d-Y|m/d|m-d|md|mdy|mdY|d|Y-m-d'</tt>).
   */
  altFormats: "m/d/Y|n/j/Y|n/j/y|m/j/y|n/d/y|m/j/Y|n/d/Y|m-d-y|m-d-Y|m/d|m-d|md|mdy|mdY|d|Y-m-d",

  /**
   * @cfg {String} disabledDaysText
   * The tooltip to display when the date falls on a disabled day (defaults to <tt>'Disabled'</tt>)
   */
  disabledDaysText: "Disabled",

  /**
   * @cfg {String} disabledDatesText
   * The tooltip text to display when the date falls on a disabled date (defaults to <tt>'Disabled'</tt>)
   */
  disabledDatesText: "Disabled",

  /**
   * @cfg {String} minText
   * The error text to display when the date in the cell is before <tt>{@link #minValue}</tt> (defaults to
   * <tt>'The date in this field must be after {minValue}'</tt>).
   */
  minText: "The date in this field must be equal to or after {0}",

  /**
   * @cfg {String} maxText
   * The error text to display when the date in the cell is after <tt>{@link #maxValue}</tt> (defaults to
   * <tt>'The date in this field must be before {maxValue}'</tt>).
   */
  maxText: "The date in this field must be equal to or before {0}",

  /**
   * @cfg {String} invalidText
   * The error text to display when the date in the field is invalid (defaults to
   * <tt>'{value} is not a valid date - it must be in the format {format}'</tt>).
   */
  invalidText: "{0} is not a valid date - it must be in the format {1}",

  /**
   * @cfg {String} triggerClass
   * An additional CSS class used to style the trigger button.  The trigger will always get the
   * class <tt>'x-form-trigger'</tt> and <tt>triggerClass</tt> will be <b>appended</b> if specified
   * (defaults to <tt>'x-form-date-trigger'</tt> which displays a calendar icon).
   */
  triggerClass: 'x-form-date-trigger',

  /**
   * @cfg {Boolean} showToday
   * <tt>false</tt> to hide the footer area of the DatePicker containing the Today button and disable
   * the keyboard handler for spacebar that selects the current date (defaults to <tt>true</tt>).
   */
  showToday: true,

  /**
   * @cfg {Date/String} minValue
   * The minimum allowed date. Can be either a Javascript date object or a string date in a
   * valid format (defaults to null).
   */

  /**
   * @cfg {Date/String} maxValue
   * The maximum allowed date. Can be either a Javascript date object or a string date in a
   * valid format (defaults to null).
   */

  /**
   * @cfg {Array} disabledDays
   * An array of days to disable, 0 based (defaults to null). Some examples:<pre><code>
  // disable Sunday and Saturday:
  disabledDays:  [0, 6]
  // disable weekdays:
  disabledDays: [1,2,3,4,5]
   * </code></pre>
   */

  /**
   * @cfg {Array} disabledDates
   * An array of "dates" to disable, as strings. These strings will be used to build a dynamic regular
   * expression so they are very powerful. Some examples:<pre><code>
  // disable these exact dates:
  disabledDates: ["03/08/2003", "09/16/2003"]
  // disable these days for every year:
  disabledDates: ["03/08", "09/16"]
  // only match the beginning (useful if you are using short years):
  disabledDates: ["^03/08"]
  // disable every day in March 2006:
  disabledDates: ["03/../2006"]
  // disable every day in every March:
  disabledDates: ["^03"]
   * </code></pre>
   * Note that the format of the dates included in the array should exactly match the {@link #format} config.
   * In order to support regular expressions, if you are using a {@link #format date format} that has "." in
   * it, you will have to escape the dot when restricting dates. For example: <tt>["03\\.08\\.03"]</tt>.
   */

  /**
   * @cfg {String/Object} autoCreate
   * A {@link Ext.DomHelper DomHelper element specification object}, or <tt>true</tt> for the default element
   * specification object:<pre><code>
   * autoCreate: {tag: "input", type: "text", size: "10", autocomplete: "off"}
   * </code></pre>
   */
  // private
  defaultAutoCreate: {
    tag: "input",
    type: "text",
    size: "10",
    autocomplete: "off"
  },
  initComponent: function initComponent() {
    Ext.form.DateField.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event select
     * Fires when a date is selected via the date picker.
     * @param {Ext.form.DateField} this
     * @param {Date} date The date that was selected
     */
    'select');

    if (Ext.isString(this.minValue)) {
      this.minValue = this.parseDate(this.minValue);
    }

    if (Ext.isString(this.maxValue)) {
      this.maxValue = this.parseDate(this.maxValue);
    }

    if ((this.value === undefined || this.value === null) && this.default === 'CURRENT_TIMESTAMP') {
      this.value = this.fullDateTime = new Date().clearTime();
    }

    this.disabledDatesRE = null;
    this.initDisabledDays();
  },
  initEvents: function initEvents() {
    Ext.form.DateField.superclass.initEvents.call(this);
    this.keyNav = new Ext.KeyNav(this.el, {
      "down": function down(e) {
        this.onTriggerClick();
      },
      scope: this,
      forceKeyDown: true
    });
  },
  // private
  initDisabledDays: function initDisabledDays() {
    if (this.disabledDates) {
      var dd = this.disabledDates,
          len = dd.length - 1,
          re = "(?:";
      Ext.each(dd, function (d, i) {
        re += Ext.isDate(d) ? '^' + Ext.escapeRe(d.dateFormat(this.format)) + '$' : dd[i];

        if (i != len) {
          re += '|';
        }
      }, this);
      this.disabledDatesRE = new RegExp(re + ')');
    }
  },

  /**
   * Replaces any existing disabled dates with new values and refreshes the DatePicker.
   * @param {Array} disabledDates An array of date strings (see the <tt>{@link #disabledDates}</tt> config
   * for details on supported values) used to disable a pattern of dates.
   */
  setDisabledDates: function setDisabledDates(dd) {
    this.disabledDates = dd;
    this.initDisabledDays();

    if (this.menu) {
      this.menu.picker.setDisabledDates(this.disabledDatesRE);
    }
  },

  /**
   * Replaces any existing disabled days (by index, 0-6) with new values and refreshes the DatePicker.
   * @param {Array} disabledDays An array of disabled day indexes. See the <tt>{@link #disabledDays}</tt>
   * config for details on supported values.
   */
  setDisabledDays: function setDisabledDays(dd) {
    this.disabledDays = dd;

    if (this.menu) {
      this.menu.picker.setDisabledDays(dd);
    }
  },

  /**
   * Replaces any existing <tt>{@link #minValue}</tt> with the new value and refreshes the DatePicker.
   * @param {Date} value The minimum date that can be selected
   */
  setMinValue: function setMinValue(dt) {
    this.minValue = Ext.isString(dt) ? this.parseDate(dt) : dt;

    if (this.menu) {
      this.menu.picker.setMinDate(this.minValue);
    }
  },

  /**
   * Replaces any existing <tt>{@link #maxValue}</tt> with the new value and refreshes the DatePicker.
   * @param {Date} value The maximum date that can be selected
   */
  setMaxValue: function setMaxValue(dt) {
    this.maxValue = Ext.isString(dt) ? this.parseDate(dt) : dt;

    if (this.menu) {
      this.menu.picker.setMaxDate(this.maxValue);
    }
  },
  // private
  validateValue: function validateValue(value) {
    value = this.formatDate(value);

    if (!Ext.form.DateField.superclass.validateValue.call(this, value)) {
      return false;
    }

    if (value.length < 1) {
      // if it's blank and textfield didn't flag it then it's valid
      return true;
    }

    var svalue = value;
    value = this.parseDate(value);

    if (!value) {
      this.markInvalid(String.format(this.invalidText, svalue, this.format));
      return false;
    }

    var time = value.getTime();

    if (this.minValue && time < this.minValue.getTime()) {
      this.markInvalid(String.format(this.minText, this.formatDate(this.minValue)));
      return false;
    }

    if (this.maxValue && time > this.maxValue.getTime()) {
      this.markInvalid(String.format(this.maxText, this.formatDate(this.maxValue)));
      return false;
    }

    if (this.disabledDays) {
      var day = value.getDay();

      for (var i = 0; i < this.disabledDays.length; i++) {
        if (day === this.disabledDays[i]) {
          this.markInvalid(this.disabledDaysText);
          return false;
        }
      }
    }

    var fvalue = this.formatDate(value);

    if (this.disabledDatesRE && this.disabledDatesRE.test(fvalue)) {
      this.markInvalid(String.format(this.disabledDatesText, fvalue));
      return false;
    }

    return true;
  },
  // private
  // Provides logic to override the default TriggerField.validateBlur which just returns true
  validateBlur: function validateBlur() {
    return !this.menu || !this.menu.isVisible();
  },

  /**
   * Returns the current date value of the date field.
   * @return {Date} The date value
   */
  getValue: function getValue() {
    // return this.parseDate(Ext.form.DateField.superclass.getValue.call(this)) || "";
    // return the value that was set (has time information when unchanged in client) 
    // and not just the date part!
    var value = this.fullDateTime;
    return value || "";
  },

  /**
   * Sets the value of the date field.  You can pass a date object or any string that can be
   * parsed into a valid date, using <tt>{@link #format}</tt> as the date format, according
   * to the same rules as {@link Date#parseDate} (the default format used is <tt>"m/d/Y"</tt>).
   * <br />Usage:
   * <pre><code>
  //All of these calls set the same date value (May 4, 2006)
  //Pass a date object:
  var dt = new Date('5/4/2006');
  dateField.setValue(dt);
  //Pass a date string (default format):
  dateField.setValue('05/04/2006');
  //Pass a date string (custom format):
  dateField.format = 'Y-m-d';
  dateField.setValue('2006-05-04');
  </code></pre>
   * @param {String/Date} date The date or valid date string
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(date) {
    /**
     * fix timezone handling for date picker
     *
     * The getValue function always returns 00:00:00 as time. So if a form got filled
     * with a date like 2008-10-01T21:00:00 the form returns 2008-10-01T00:00:00 although
     * the user did not change the fieled.
     *
     * In a multi timezone context this is fatal! When a user in a certain timezone set
     * a date (just a date and no time information), this means in his timezone the
     * time range from 2008-10-01T00:00:00 to 2008-10-01T23:59:59.
     * _BUT_ for an other user sitting in a different timezone it means e.g. the
     * time range from 2008-10-01T02:00:00 to 2008-10-02T21:59:59.
     *
     * So on the one hand we need to make sure, that the date picker only returns
     * changed datetime information when the user did a change.
     *
     * @todo On the other hand we
     * need adjust the day +/- one day according to the timeshift.
     */
    // get value must not return a string representation, so we convert this always here
    // before memorisation
    if (Ext.isString(date)) {
      var v = Date.parseDate(date, Date.patterns.ISO8601Long);

      if (Ext.isDate(v)) {
        date = v;
      } else {
        date = Ext.form.DateField.prototype.parseDate.call(this, date);
      }
    } // preserve original datetime information


    this.fullDateTime = date;
    return Ext.form.DateField.superclass.setValue.call(this, this.formatDate(this.parseDate(date)));
  },
  // private
  parseDate: function parseDate(value) {
    if (!value || Ext.isDate(value)) {
      return value;
    }

    var v = Date.parseDate(value, this.format);

    if (!v && this.altFormats) {
      if (!this.altFormatsArray) {
        this.altFormatsArray = this.altFormats.split("|");
      }

      for (var i = 0, len = this.altFormatsArray.length; i < len && !v; i++) {
        v = Date.parseDate(value, this.altFormatsArray[i]);
      }
    }

    return v;
  },
  // private
  onDestroy: function onDestroy() {
    Ext.destroy(this.menu, this.keyNav);
    Ext.form.DateField.superclass.onDestroy.call(this);
  },
  // private
  formatDate: function formatDate(date) {
    return Ext.isDate(date) ? date.dateFormat(this.format) : date;
  },

  /**
   * @method onTriggerClick
   * @hide
   */
  // private
  // Implements the default empty TriggerField.onTriggerClick function to display the DatePicker
  onTriggerClick: function onTriggerClick() {
    if (this.disabled) {
      return;
    }

    if (this.menu == null) {
      this.menu = new Ext.menu.DateMenu({
        hideOnClick: false,
        focusOnSelect: false
      });
    }

    this.onFocus();
    Ext.apply(this.menu.picker, {
      minDate: this.minValue,
      maxDate: this.maxValue,
      disabledDatesRE: this.disabledDatesRE,
      disabledDatesText: this.disabledDatesText,
      disabledDays: this.disabledDays,
      disabledDaysText: this.disabledDaysText,
      format: this.format,
      showToday: this.showToday,
      minText: String.format(this.minText, this.formatDate(this.minValue)),
      maxText: String.format(this.maxText, this.formatDate(this.maxValue))
    });
    this.menu.picker.setValue(this.getValue() || new Date());
    this.menu.show(this.el, "tl-bl?");
    this.menuEvents('on');
  },
  //private
  menuEvents: function menuEvents(method) {
    this.menu[method]('select', this.onSelect, this);
    this.menu[method]('hide', this.onMenuHide, this);
    this.menu[method]('show', this.onFocus, this);
  },
  onSelect: function onSelect(m, d) {
    this.setValue(d);
    this.fireEvent('select', this, d);
    this.menu.hide();
  },
  onMenuHide: function onMenuHide() {
    this.focus(false, 60);
    this.menuEvents('un');
  },
  // private
  beforeBlur: function beforeBlur() {
    var v = this.parseDate(this.getRawValue());

    if (v) {
      this.setValue(v);
    }
  }
  /**
   * @cfg {Boolean} grow @hide
   */

  /**
   * @cfg {Number} growMin @hide
   */

  /**
   * @cfg {Number} growMax @hide
   */

  /**
   * @hide
   * @method autoSize
   */

});
Ext.reg('datefield', Ext.form.DateField);

/***/ }),
/* 875 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.DisplayField
 * @extends Ext.form.Field
 * A display-only text field which is not validated and not submitted.
 * @constructor
 * Creates a new DisplayField.
 * @param {Object} config Configuration options
 * @xtype displayfield
 */
Ext.form.DisplayField = Ext.extend(Ext.form.Field, {
  validationEvent: false,
  validateOnBlur: false,
  defaultAutoCreate: {
    tag: "div"
  },

  /**
   * @cfg {String} fieldClass The default CSS class for the field (defaults to <tt>"x-form-display-field"</tt>)
   */
  fieldClass: "x-form-display-field",

  /**
   * @cfg {Boolean} htmlEncode <tt>false</tt> to skip HTML-encoding the text when rendering it (defaults to
   * <tt>false</tt>). This might be useful if you want to include tags in the field's innerHTML rather than
   * rendering them as string literals per the default logic.
   */
  htmlEncode: false,
  // private
  initEvents: Ext.emptyFn,
  isValid: function isValid() {
    return true;
  },
  validate: function validate() {
    return true;
  },
  getRawValue: function getRawValue() {
    var v = this.rendered ? this.el.dom.innerHTML : Ext.value(this.value, '');

    if (v === this.emptyText) {
      v = '';
    }

    if (this.htmlEncode) {
      v = Ext.util.Format.htmlDecode(v);
    }

    return v;
  },
  getValue: function getValue() {
    return this.getRawValue();
  },
  getName: function getName() {
    return this.name;
  },
  setRawValue: function setRawValue(v) {
    if (this.htmlEncode) {
      v = Ext.util.Format.htmlEncode(v);
    }

    return this.rendered ? this.el.dom.innerHTML = Ext.isEmpty(v) ? '' : v : this.value = v;
  },
  setValue: function setValue(v) {
    this.setRawValue(v);
    return this;
  }
  /** 
   * @cfg {String} inputType 
   * @hide
   */

  /** 
   * @cfg {Boolean} disabled 
   * @hide
   */

  /** 
   * @cfg {Boolean} readOnly 
   * @hide
   */

  /** 
   * @cfg {Boolean} validateOnBlur 
   * @hide
   */

  /** 
   * @cfg {Number} validationDelay 
   * @hide
   */

  /** 
   * @cfg {String/Boolean} validationEvent 
   * @hide
   */

});
Ext.reg('displayfield', Ext.form.DisplayField);

/***/ }),
/* 876 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.ComboBox
 * @extends Ext.form.TriggerField
 * <p>A combobox control with support for autocomplete, remote-loading, paging and many other features.</p>
 * <p>A ComboBox works in a similar manner to a traditional HTML &lt;select> field. The difference is
 * that to submit the {@link #valueField}, you must specify a {@link #hiddenName} to create a hidden input
 * field to hold the value of the valueField. The <i>{@link #displayField}</i> is shown in the text field
 * which is named according to the {@link #name}.</p>
 * <p><b><u>Events</u></b></p>
 * <p>To do something when something in ComboBox is selected, configure the select event:<pre><code>
var cb = new Ext.form.ComboBox({
    // all of your config options
    listeners:{
         scope: yourScope,
         'select': yourFunction
    }
});

// Alternatively, you can assign events after the object is created:
var cb = new Ext.form.ComboBox(yourOptions);
cb.on('select', yourFunction, yourScope);
 * </code></pre></p>
 *
 * <p><b><u>ComboBox in Grid</u></b></p>
 * <p>If using a ComboBox in an {@link Ext.grid.EditorGridPanel Editor Grid} a {@link Ext.grid.Column#renderer renderer}
 * will be needed to show the displayField when the editor is not active.  Set up the renderer manually, or implement
 * a reusable render, for example:<pre><code>
// create reusable renderer
Ext.util.Format.comboRenderer = function(combo){
    return function(value){
        var record = combo.findRecord(combo.{@link #valueField}, value);
        return record ? record.get(combo.{@link #displayField}) : combo.{@link #valueNotFoundText};
    }
}

// create the combo instance
var combo = new Ext.form.ComboBox({
    {@link #typeAhead}: true,
    {@link #triggerAction}: 'all',
    {@link #lazyRender}:true,
    {@link #mode}: 'local',
    {@link #store}: new Ext.data.ArrayStore({
        id: 0,
        fields: [
            'myId',
            'displayText'
        ],
        data: [[1, 'item1'], [2, 'item2']]
    }),
    {@link #valueField}: 'myId',
    {@link #displayField}: 'displayText'
});

// snippet of column model used within grid
var cm = new Ext.grid.ColumnModel([{
       ...
    },{
       header: "Some Header",
       dataIndex: 'whatever',
       width: 130,
       editor: combo, // specify reference to combo instance
       renderer: Ext.util.Format.comboRenderer(combo) // pass combo instance to reusable renderer
    },
    ...
]);
 * </code></pre></p>
 *
 * <p><b><u>Filtering</u></b></p>
 * <p>A ComboBox {@link #doQuery uses filtering itself}, for information about filtering the ComboBox
 * store manually see <tt>{@link #lastQuery}</tt>.</p>
 * @constructor
 * Create a new ComboBox.
 * @param {Object} config Configuration options
 * @xtype combo
 */
Ext.form.ComboBox = Ext.extend(Ext.form.TriggerField, {
  /**
   * @cfg {Mixed} transform The id, DOM node or element of an existing HTML SELECT to convert to a ComboBox.
   * Note that if you specify this and the combo is going to be in an {@link Ext.form.BasicForm} or
   * {@link Ext.form.FormPanel}, you must also set <tt>{@link #lazyRender} = true</tt>.
   */

  /**
   * @cfg {Boolean} lazyRender <tt>true</tt> to prevent the ComboBox from rendering until requested
   * (should always be used when rendering into an {@link Ext.Editor} (e.g. {@link Ext.grid.EditorGridPanel Grids}),
   * defaults to <tt>false</tt>).
   */

  /**
   * @cfg {String/Object} autoCreate <p>A {@link Ext.DomHelper DomHelper} element spec, or <tt>true</tt> for a default
   * element spec. Used to create the {@link Ext.Component#getEl Element} which will encapsulate this Component.
   * See <tt>{@link Ext.Component#autoEl autoEl}</tt> for details.  Defaults to:</p>
   * <pre><code>{tag: "input", type: "text", size: "24", autocomplete: "off"}</code></pre>
   */

  /**
   * @cfg {Ext.data.Store/Array} store The data source to which this combo is bound (defaults to <tt>undefined</tt>).
   * Acceptable values for this property are:
   * <div class="mdetail-params"><ul>
   * <li><b>any {@link Ext.data.Store Store} subclass</b></li>
   * <li><b>an Array</b> : Arrays will be converted to a {@link Ext.data.ArrayStore} internally,
   * automatically generating {@link Ext.data.Field#name field names} to work with all data components.
   * <div class="mdetail-params"><ul>
   * <li><b>1-dimensional array</b> : (e.g., <tt>['Foo','Bar']</tt>)<div class="sub-desc">
   * A 1-dimensional array will automatically be expanded (each array item will be used for both the combo
   * {@link #valueField} and {@link #displayField})</div></li>
   * <li><b>2-dimensional array</b> : (e.g., <tt>[['f','Foo'],['b','Bar']]</tt>)<div class="sub-desc">
   * For a multi-dimensional array, the value in index 0 of each item will be assumed to be the combo
   * {@link #valueField}, while the value at index 1 is assumed to be the combo {@link #displayField}.
   * </div></li></ul></div></li></ul></div>
   * <p>See also <tt>{@link #mode}</tt>.</p>
   */

  /**
   * @cfg {String} title If supplied, a header element is created containing this text and added into the top of
   * the dropdown list (defaults to undefined, with no header element)
   */
  // private
  defaultAutoCreate: {
    tag: "input",
    type: "text",
    size: "24",
    autocomplete: "off"
  },

  /**
   * @cfg {Number} listWidth The width (used as a parameter to {@link Ext.Element#setWidth}) of the dropdown
   * list (defaults to the width of the ComboBox field).  See also <tt>{@link #minListWidth}
   */

  /**
   * @cfg {String} displayField The underlying {@link Ext.data.Field#name data field name} to bind to this
   * ComboBox (defaults to undefined if <tt>{@link #mode} = 'remote'</tt> or <tt>'field1'</tt> if
   * {@link #transform transforming a select} or if the {@link #store field name is autogenerated based on
   * the store configuration}).
   * <p>See also <tt>{@link #valueField}</tt>.</p>
   * <p><b>Note</b>: if using a ComboBox in an {@link Ext.grid.EditorGridPanel Editor Grid} a
   * {@link Ext.grid.Column#renderer renderer} will be needed to show the displayField when the editor is not
   * active.</p>
   */

  /**
   * @cfg {String} valueField The underlying {@link Ext.data.Field#name data value name} to bind to this
   * ComboBox (defaults to undefined if <tt>{@link #mode} = 'remote'</tt> or <tt>'field2'</tt> if
   * {@link #transform transforming a select} or if the {@link #store field name is autogenerated based on
   * the store configuration}).
   * <p><b>Note</b>: use of a <tt>valueField</tt> requires the user to make a selection in order for a value to be
   * mapped.  See also <tt>{@link #hiddenName}</tt>, <tt>{@link #hiddenValue}</tt>, and <tt>{@link #displayField}</tt>.</p>
   */

  /**
   * @cfg {String} hiddenName If specified, a hidden form field with this name is dynamically generated to store the
   * field's data value (defaults to the underlying DOM element's name). Required for the combo's value to automatically
   * post during a form submission.  See also {@link #valueField}.
   * <p><b>Note</b>: the hidden field's id will also default to this name if {@link #hiddenId} is not specified.
   * The ComboBox {@link Ext.Component#id id} and the <tt>{@link #hiddenId}</tt> <b>should be different</b>, since
   * no two DOM nodes should share the same id.  So, if the ComboBox <tt>{@link Ext.form.Field#name name}</tt> and
   * <tt>hiddenName</tt> are the same, you should specify a unique <tt>{@link #hiddenId}</tt>.</p>
   */

  /**
   * @cfg {String} hiddenId If <tt>{@link #hiddenName}</tt> is specified, <tt>hiddenId</tt> can also be provided
   * to give the hidden field a unique id (defaults to the <tt>{@link #hiddenName}</tt>).  The <tt>hiddenId</tt>
   * and combo {@link Ext.Component#id id} should be different, since no two DOM
   * nodes should share the same id.
   */

  /**
   * @cfg {String} hiddenValue Sets the initial value of the hidden field if {@link #hiddenName} is
   * specified to contain the selected {@link #valueField}, from the Store. Defaults to the configured
   * <tt>{@link Ext.form.Field#value value}</tt>.
   */

  /**
   * @cfg {String} listClass The CSS class to add to the predefined <tt>'x-combo-list'</tt> class
   * applied the dropdown list element (defaults to '').
   */
  listClass: '',

  /**
   * @cfg {String} selectedClass CSS class to apply to the selected item in the dropdown list
   * (defaults to <tt>'x-combo-selected'</tt>)
   */
  selectedClass: 'x-combo-selected',

  /**
   * @cfg {String} listEmptyText The empty text to display in the data view if no items are found.
   * (defaults to '')
   */
  listEmptyText: '',

  /**
   * @cfg {String} triggerClass An additional CSS class used to style the trigger button.  The trigger will always
   * get the class <tt>'x-form-trigger'</tt> and <tt>triggerClass</tt> will be <b>appended</b> if specified
   * (defaults to <tt>'x-form-arrow-trigger'</tt> which displays a downward arrow icon).
   */
  triggerClass: 'x-form-arrow-trigger',

  /**
   * @cfg {Boolean/String} shadow <tt>true</tt> or <tt>"sides"</tt> for the default effect, <tt>"frame"</tt> for
   * 4-way shadow, and <tt>"drop"</tt> for bottom-right
   */
  shadow: 'sides',

  /**
   * @cfg {String/Array} listAlign A valid anchor position value. See <tt>{@link Ext.Element#alignTo}</tt> for details
   * on supported anchor positions and offsets. To specify x/y offsets as well, this value
   * may be specified as an Array of <tt>{@link Ext.Element#alignTo}</tt> method arguments.</p>
   * <pre><code>[ 'tl-bl?', [6,0] ]</code></pre>(defaults to <tt>'tl-bl?'</tt>)
   */
  listAlign: 'tl-bl?',

  /**
   * @cfg {Number} maxHeight The maximum height in pixels of the dropdown list before scrollbars are shown
   * (defaults to <tt>300</tt>)
   */
  maxHeight: 300,

  /**
   * @cfg {Number} minHeight The minimum height in pixels of the dropdown list when the list is constrained by its
   * distance to the viewport edges (defaults to <tt>90</tt>)
   */
  minHeight: 90,

  /**
   * @cfg {String} triggerAction The action to execute when the trigger is clicked.
   * <div class="mdetail-params"><ul>
   * <li><b><tt>'query'</tt></b> : <b>Default</b>
   * <p class="sub-desc">{@link #doQuery run the query} using the {@link Ext.form.Field#getRawValue raw value}.</p></li>
   * <li><b><tt>'all'</tt></b> :
   * <p class="sub-desc">{@link #doQuery run the query} specified by the <tt>{@link #allQuery}</tt> config option</p></li>
   * </ul></div>
   * <p>See also <code>{@link #queryParam}</code>.</p>
   */
  triggerAction: 'all',

  /**
   * @cfg {Number} minChars The minimum number of characters the user must type before autocomplete and
   * {@link #typeAhead} activate (defaults to <tt>4</tt> if <tt>{@link #mode} = 'remote'</tt> or <tt>0</tt> if
   * <tt>{@link #mode} = 'local'</tt>, does not apply if
   * <tt>{@link Ext.form.TriggerField#editable editable} = false</tt>).
   */
  minChars: 1,

  /**
   * @cfg {Boolean} autoSelect <tt>true</tt> to select the first result gathered by the data store (defaults
   * to <tt>true</tt>).  A false value would require a manual selection from the dropdown list to set the components value
   * unless the value of ({@link #typeAheadDelay}) were true.
   */
  autoSelect: true,

  /**
   * @cfg {Boolean} typeAhead <tt>true</tt> to populate and autoselect the remainder of the text being
   * typed after a configurable delay ({@link #typeAheadDelay}) if it matches a known value (defaults
   * to <tt>false</tt>)
   */
  typeAhead: false,

  /**
   * @cfg {Number} queryDelay The length of time in milliseconds to delay between the start of typing and
   * sending the query to filter the dropdown list (defaults to <tt>500</tt> if <tt>{@link #mode} = 'remote'</tt>
   * or <tt>10</tt> if <tt>{@link #mode} = 'local'</tt>)
   */
  queryDelay: 150,

  /**
   * @cfg {Number} pageSize If greater than <tt>0</tt>, a {@link Ext.PagingToolbar} is displayed in the
   * footer of the dropdown list and the {@link #doQuery filter queries} will execute with page start and
   * {@link Ext.PagingToolbar#pageSize limit} parameters. Only applies when <tt>{@link #mode} = 'remote'</tt>
   * (defaults to <tt>0</tt>).
   */
  pageSize: 0,

  /**
   * @cfg {Boolean} selectOnFocus <tt>true</tt> to select any existing text in the field immediately on focus.
   * Only applies when <tt>{@link Ext.form.TriggerField#editable editable} = true</tt> (defaults to
   * <tt>false</tt>).
   */
  selectOnFocus: false,

  /**
   * @cfg {String} queryParam Name of the query ({@link Ext.data.Store#baseParam baseParam} name for the store)
   * as it will be passed on the querystring (defaults to <tt>'query'</tt>)
   */
  queryParam: 'query',

  /**
   * @cfg {String} loadingText The text to display in the dropdown list while data is loading.  Only applies
   * when <tt>{@link #mode} = 'remote'</tt> (defaults to <tt>'Loading...'</tt>)
   */
  loadingText: 'Loading...',

  /**
   * @cfg {Boolean} resizable <tt>true</tt> to add a resize handle to the bottom of the dropdown list
   * (creates an {@link Ext.Resizable} with 'se' {@link Ext.Resizable#pinned pinned} handles).
   * Defaults to <tt>false</tt>.
   */
  resizable: false,

  /**
   * @cfg {Number} handleHeight The height in pixels of the dropdown list resize handle if
   * <tt>{@link #resizable} = true</tt> (defaults to <tt>8</tt>)
   */
  handleHeight: 8,

  /**
   * @cfg {String} allQuery The text query to send to the server to return all records for the list
   * with no filtering (defaults to '')
   */
  allQuery: '',

  /**
   * @cfg {String} mode Acceptable values are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>'remote'</tt></b> : <b>Default</b>
   * <p class="sub-desc">Automatically loads the <tt>{@link #store}</tt> the <b>first</b> time the trigger
   * is clicked. If you do not want the store to be automatically loaded the first time the trigger is
   * clicked, set to <tt>'local'</tt> and manually load the store.  To force a requery of the store
   * <b>every</b> time the trigger is clicked see <tt>{@link #lastQuery}</tt>.</p></li>
   * <li><b><tt>'local'</tt></b> :
   * <p class="sub-desc">ComboBox loads local data</p>
   * <pre><code>
  var combo = new Ext.form.ComboBox({
  renderTo: document.body,
  mode: 'local',
  store: new Ext.data.ArrayStore({
      id: 0,
      fields: [
          'myId',  // numeric value is the key
          'displayText'
      ],
      data: [[1, 'item1'], [2, 'item2']]  // data is local
  }),
  valueField: 'myId',
  displayField: 'displayText',
  triggerAction: 'all'
  });
   * </code></pre></li>
   * </ul></div>
   */
  mode: 'remote',

  /**
   * @cfg {Number} minListWidth The minimum width of the dropdown list in pixels (defaults to <tt>70</tt>, will
   * be ignored if <tt>{@link #listWidth}</tt> has a higher value)
   */
  minListWidth: 70,

  /**
   * @cfg {Boolean} forceSelection <tt>true</tt> to restrict the selected value to one of the values in the list,
   * <tt>false</tt> to allow the user to set arbitrary text into the field (defaults to <tt>false</tt>)
   */
  forceSelection: false,

  /**
   * @cfg {Number} typeAheadDelay The length of time in milliseconds to wait until the typeahead text is displayed
   * if <tt>{@link #typeAhead} = true</tt> (defaults to <tt>250</tt>)
   */
  typeAheadDelay: 75,

  /**
   * @cfg {String} valueNotFoundText When using a name/value combo, if the value passed to setValue is not found in
   * the store, valueNotFoundText will be displayed as the field text if defined (defaults to undefined). If this
   * default text is used, it means there is no value set and no validation will occur on this field.
   */

  /**
   * @cfg {Boolean} lazyInit <tt>true</tt> to not initialize the list for this combo until the field is focused
   * (defaults to <tt>true</tt>)
   */
  lazyInit: true,

  /**
   * @cfg {Boolean} clearFilterOnReset <tt>true</tt> to clear any filters on the store (when in local mode) when reset is called
   * (defaults to <tt>true</tt>)
   */
  clearFilterOnReset: true,

  /**
   * @cfg {Boolean} submitValue False to clear the name attribute on the field so that it is not submitted during a form post.
   * If a hiddenName is specified, setting this to true will cause both the hidden field and the element to be submitted.
   * Defaults to <tt>undefined</tt>.
   */
  submitValue: undefined,

  /**
   * The value of the match string used to filter the store. Delete this property to force a requery.
   * Example use:
   * <pre><code>
  var combo = new Ext.form.ComboBox({
  ...
  mode: 'remote',
  ...
  listeners: {
      // delete the previous query in the beforequery event or set
      // combo.lastQuery = null (this will reload the store the next time it expands)
      beforequery: function(qe){
          delete qe.combo.lastQuery;
      }
  }
  });
   * </code></pre>
   * To make sure the filter in the store is not cleared the first time the ComboBox trigger is used
   * configure the combo with <tt>lastQuery=''</tt>. Example use:
   * <pre><code>
  var combo = new Ext.form.ComboBox({
  ...
  mode: 'local',
  triggerAction: 'all',
  lastQuery: ''
  });
   * </code></pre>
   * @property lastQuery
   * @type String
   */
  // private
  initComponent: function initComponent() {
    Ext.form.ComboBox.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event expand
     * Fires when the dropdown list is expanded
     * @param {Ext.form.ComboBox} combo This combo box
     */
    'expand',
    /**
     * @event collapse
     * Fires when the dropdown list is collapsed
     * @param {Ext.form.ComboBox} combo This combo box
     */
    'collapse',
    /**
     * @event beforeselect
     * Fires before a list item is selected. Return false to cancel the selection.
     * @param {Ext.form.ComboBox} combo This combo box
     * @param {Ext.data.Record} record The data record returned from the underlying store
     * @param {Number} index The index of the selected item in the dropdown list
     */
    'beforeselect',
    /**
     * @event select
     * Fires when a list item is selected
     * @param {Ext.form.ComboBox} combo This combo box
     * @param {Ext.data.Record} record The data record returned from the underlying store
     * @param {Number} index The index of the selected item in the dropdown list
     */
    'select',
    /**
     * @event beforequery
     * Fires before all queries are processed. Return false to cancel the query or set the queryEvent's
     * cancel property to true.
     * @param {Object} queryEvent An object that has these properties:<ul>
     * <li><code>combo</code> : Ext.form.ComboBox <div class="sub-desc">This combo box</div></li>
     * <li><code>query</code> : String <div class="sub-desc">The query</div></li>
     * <li><code>forceAll</code> : Boolean <div class="sub-desc">True to force "all" query</div></li>
     * <li><code>cancel</code> : Boolean <div class="sub-desc">Set to true to cancel the query</div></li>
     * </ul>
     */
    'beforequery');

    if (this.transform) {
      var s = Ext.getDom(this.transform);

      if (!this.hiddenName) {
        this.hiddenName = s.name;
      }

      if (!this.store) {
        this.mode = 'local';
        var d = [],
            opts = s.options;

        for (var i = 0, len = opts.length; i < len; i++) {
          var o = opts[i],
              value = (o.hasAttribute ? o.hasAttribute('value') : o.getAttributeNode('value').specified) ? o.value : o.text;

          if (o.selected && Ext.isEmpty(this.value, true)) {
            this.value = value;
          }

          d.push([value, o.text]);
        }

        this.store = new Ext.data.ArrayStore({
          'id': 0,
          fields: ['value', 'text'],
          data: d,
          autoDestroy: true
        });
        this.valueField = 'value';
        this.displayField = 'text';
      }

      s.name = Ext.id(); // wipe out the name in case somewhere else they have a reference

      if (!this.lazyRender) {
        this.target = true;
        this.el = Ext.DomHelper.insertBefore(s, this.autoCreate || this.defaultAutoCreate);
        this.render(this.el.parentNode, s);
      }

      Ext.removeNode(s);
    } //auto-configure store from local array data
    else if (this.store) {
        this.store = Ext.StoreMgr.lookup(this.store);

        if (this.store.autoCreated) {
          this.displayField = this.valueField = 'field1';

          if (!this.store.expandData) {
            this.displayField = 'field2';
          }

          this.mode = 'local';
        }
      }

    this.selectedIndex = -1;

    if (this.mode == 'local') {
      if (!Ext.isDefined(this.initialConfig.queryDelay)) {
        this.queryDelay = 10;
      }

      if (!Ext.isDefined(this.initialConfig.minChars)) {
        this.minChars = 0;
      }
    }

    if (this.expandOnFocus) {
      this.lazyInit = false;
      this.on('focus', function () {
        this.onTriggerClick();
      });
    } // NOTE: we don't blur the element in the UI as it looks ugly to loose focus class
    //       but we trigger blur event chain


    if (this.blurOnSelect) {
      this.on('select', function () {
        // prevent loop as bluring might select again
        if (new Date().getTime() - 1000 < this.blurOnSelectLastRun) return;

        _.delay(() => {
          this.blurOnSelectLastRun = new Date().getTime();
          const focusClass = this.focusClass;
          this.focusClass = '';
          Ext.form.TriggerField.superclass.onBlur.call(this);
          this.focusClass = focusClass;
        }, 100);
      }, this);
    }
  },
  // private
  onRender: function onRender(ct, position) {
    if (this.hiddenName && !Ext.isDefined(this.submitValue)) {
      this.submitValue = false;
    }

    Ext.form.ComboBox.superclass.onRender.call(this, ct, position);

    if (this.hiddenName) {
      this.hiddenField = this.el.insertSibling({
        tag: 'input',
        type: 'hidden',
        name: this.hiddenName,
        id: this.hiddenId || this.hiddenName
      }, 'before', true);
    }

    if (Ext.isGecko) {
      this.el.dom.setAttribute('autocomplete', 'off');
    }

    if (!this.lazyInit) {
      this.initList();
    } else {
      this.on('focus', this.initList, this, {
        single: true
      });
    }
  },
  // private
  initValue: function initValue() {
    Ext.form.ComboBox.superclass.initValue.call(this);

    if (this.hiddenField) {
      this.hiddenField.value = Ext.value(Ext.isDefined(this.hiddenValue) ? this.hiddenValue : this.value, '');
    }
  },
  // private
  initList: function initList() {
    if (!this.list) {
      var cls = 'x-combo-list',
          listParent = Ext.getDom(this.getListParent() || Ext.getBody()),
          zindex = parseInt(Ext.fly(listParent).getStyle('z-index'), 10);

      if (this.ownerCt && !zindex) {
        this.findParentBy(function (ct) {
          zindex = parseInt(ct.getPositionEl().getStyle('z-index'), 10);
          return !!zindex;
        });
      }

      this.list = new Ext.Layer({
        parentEl: listParent,
        shadow: this.shadow,
        cls: [cls, this.listClass].join(' '),
        constrain: false,
        zindex: (zindex || 12000) + 5
      });
      var lw = this.listWidth || Math.max(this.wrap.getWidth(), this.minListWidth);
      this.list.setSize(lw, 0);
      this.list.swallowEvent('mousewheel');
      this.assetHeight = 0;

      if (this.syncFont !== false) {
        this.list.setStyle('font-size', this.el.getStyle('font-size'));
      }

      if (this.title) {
        this.header = this.list.createChild({
          cls: cls + '-hd',
          html: this.title
        });
        this.assetHeight += this.header.getHeight();
      }

      this.innerList = this.list.createChild({
        cls: cls + '-inner'
      });
      this.mon(this.innerList, 'mouseover', this.onViewOver, this);
      this.mon(this.innerList, 'mousemove', this.onViewMove, this);
      this.innerList.setWidth(lw - this.list.getFrameWidth('lr'));

      if (this.pageSize) {
        this.footer = this.list.createChild({
          cls: cls + '-ft'
        });
        this.pageTb = new Ext.PagingToolbar({
          store: this.store,
          pageSize: this.pageSize,
          renderTo: this.footer
        });
        this.assetHeight += this.footer.getHeight();
      }

      if (!this.tpl) {
        /**
        * @cfg {String/Ext.XTemplate} tpl <p>The template string, or {@link Ext.XTemplate} instance to
        * use to display each item in the dropdown list. The dropdown list is displayed in a
        * DataView. See {@link #view}.</p>
        * <p>The default template string is:</p><pre><code>
          '&lt;tpl for=".">&lt;div class="x-combo-list-item">{' + this.displayField + '}&lt;/div>&lt;/tpl>'
        * </code></pre>
        * <p>Override the default value to create custom UI layouts for items in the list.
        * For example:</p><pre><code>
          '&lt;tpl for=".">&lt;div ext:qtip="{state}. {nick}" class="x-combo-list-item">{state}&lt;/div>&lt;/tpl>'
        * </code></pre>
        * <p>The template <b>must</b> contain one or more substitution parameters using field
        * names from the Combo's</b> {@link #store Store}. In the example above an
        * <pre>ext:qtip</pre> attribute is added to display other fields from the Store.</p>
        * <p>To preserve the default visual look of list items, add the CSS class name
        * <pre>x-combo-list-item</pre> to the template's container element.</p>
        * <p>Also see {@link #itemSelector} for additional details.</p>
        */
        this.tpl = '<tpl for="."><div class="' + cls + '-item">{' + this.displayField + '}</div></tpl>';
        /**
         * @cfg {String} itemSelector
         * <p>A simple CSS selector (e.g. div.some-class or span:first-child) that will be
         * used to determine what nodes the {@link #view Ext.DataView} which handles the dropdown
         * display will be working with.</p>
         * <p><b>Note</b>: this setting is <b>required</b> if a custom XTemplate has been
         * specified in {@link #tpl} which assigns a class other than <pre>'x-combo-list-item'</pre>
         * to dropdown list items</b>
         */
      }
      /**
      * The {@link Ext.DataView DataView} used to display the ComboBox's options.
      * @type Ext.DataView
      */


      this.view = new Ext.DataView({
        applyTo: this.innerList,
        tpl: this.tpl,
        singleSelect: true,
        selectedClass: this.selectedClass,
        itemSelector: this.itemSelector || '.' + cls + '-item',
        emptyText: this.listEmptyText,
        deferEmptyText: false
      });
      this.mon(this.view, {
        containerclick: this.onViewClick,
        click: this.onViewClick,
        scope: this
      });
      this.bindStore(this.store, true);

      if (this.resizable) {
        this.resizer = new Ext.Resizable(this.list, {
          pinned: true,
          handles: 'se'
        });
        this.mon(this.resizer, 'resize', function (r, w, h) {
          this.maxHeight = h - this.handleHeight - this.list.getFrameWidth('tb') - this.assetHeight;
          this.listWidth = w;
          this.innerList.setWidth(w - this.list.getFrameWidth('lr'));
          this.restrictHeight();
        }, this);
        this[this.pageSize ? 'footer' : 'innerList'].setStyle('margin-bottom', this.handleHeight + 'px');
      }
    }
  },

  /**
   * <p>Returns the element used to house this ComboBox's pop-up list. Defaults to the document body.</p>
   * A custom implementation may be provided as a configuration option if the floating list needs to be rendered
   * to a different Element. An example might be rendering the list inside a Menu so that clicking
   * the list does not hide the Menu:<pre><code>
  var store = new Ext.data.ArrayStore({
  autoDestroy: true,
  fields: ['initials', 'fullname'],
  data : [
      ['FF', 'Fred Flintstone'],
      ['BR', 'Barney Rubble']
  ]
  });
  var combo = new Ext.form.ComboBox({
  store: store,
  displayField: 'fullname',
  emptyText: 'Select a name...',
  forceSelection: true,
  getListParent: function() {
      return this.el.up('.x-menu');
  },
  iconCls: 'no-icon', //use iconCls if placing within menu to shift to right side of menu
  mode: 'local',
  selectOnFocus: true,
  triggerAction: 'all',
  typeAhead: true,
  width: 135
  });
  var menu = new Ext.menu.Menu({
  id: 'mainMenu',
  items: [
      combo // A Field in a Menu
  ]
  });
  </code></pre>
   */
  getListParent: function getListParent() {
    return document.body;
  },

  /**
   * Returns the store associated with this combo.
   * @return {Ext.data.Store} The store
   */
  getStore: function getStore() {
    return this.store;
  },
  // private
  bindStore: function bindStore(store, initial) {
    if (this.store && !initial) {
      if (this.store !== store && this.store.autoDestroy) {
        this.store.destroy();
      } else {
        this.store.un('beforeload', this.onBeforeLoad, this);
        this.store.un('load', this.onLoad, this);
        this.store.un('exception', this.collapse, this);
      }

      if (!store) {
        this.store = null;

        if (this.view) {
          this.view.bindStore(null);
        }

        if (this.pageTb) {
          this.pageTb.bindStore(null);
        }
      }
    }

    if (store) {
      if (!initial) {
        this.lastQuery = null;

        if (this.pageTb) {
          this.pageTb.bindStore(store);
        }
      }

      this.store = Ext.StoreMgr.lookup(store);
      this.store.on({
        scope: this,
        beforeload: this.onBeforeLoad,
        load: this.onLoad,
        exception: this.collapse
      });

      if (this.view) {
        this.view.bindStore(store);
      }
    }
  },
  reset: function reset() {
    Ext.form.ComboBox.superclass.reset.call(this);

    if (this.clearFilterOnReset && this.mode == 'local') {
      this.store.clearFilter();
    }
  },
  // private
  initEvents: function initEvents() {
    Ext.form.ComboBox.superclass.initEvents.call(this);
    this.keyNav = new Ext.KeyNav(this.el, {
      "up": function up(e) {
        this.inKeyMode = true;
        this.selectPrev();
      },
      "down": function down(e) {
        if (!this.isExpanded()) {
          this.onTriggerClick();
        } else {
          this.inKeyMode = true;
          this.selectNext();
        }
      },
      "enter": function enter(e) {
        this.onViewClick();
      },
      "esc": function esc(e) {
        this.collapse();
      },
      "tab": function tab(e) {
        this.collapse();
        return true;
      },
      scope: this,
      doRelay: function doRelay(e, h, hname) {
        if (hname == 'down' || this.scope.isExpanded()) {
          // this MUST be called before ComboBox#fireKey()
          var relay = Ext.KeyNav.prototype.doRelay.apply(this, arguments);

          if (!Ext.isIE && Ext.EventManager.useKeydown) {
            // call Combo#fireKey() for browsers which use keydown event (except IE)
            this.scope.fireKey(e);
          }

          return relay;
        }

        return true;
      },
      forceKeyDown: true,
      defaultEventAction: 'stopEvent'
    });
    this.queryDelay = Math.max(this.queryDelay || 10, this.mode == 'local' ? 10 : 250);
    this.dqTask = new Ext.util.DelayedTask(this.initQuery, this);

    if (this.typeAhead) {
      this.taTask = new Ext.util.DelayedTask(this.onTypeAhead, this);
    }

    if (!this.enableKeyEvents) {
      this.mon(this.el, 'keyup', this.onKeyUp, this);
    }
  },
  // private
  onDestroy: function onDestroy() {
    if (this.dqTask) {
      this.dqTask.cancel();
      this.dqTask = null;
    }

    this.bindStore(null);
    Ext.destroy(this.resizer, this.view, this.pageTb, this.list);
    Ext.destroyMembers(this, 'hiddenField');
    Ext.form.ComboBox.superclass.onDestroy.call(this);
  },
  // private
  fireKey: function fireKey(e) {
    if (!this.isExpanded()) {
      Ext.form.ComboBox.superclass.fireKey.call(this, e);
    }
  },
  // private
  onResize: function onResize(w, h) {
    Ext.form.ComboBox.superclass.onResize.apply(this, arguments);

    if (this.isVisible() && this.list) {
      this.doResize(w);
    } else {
      this.bufferSize = w;
    }
  },
  doResize: function doResize(w) {
    if (!Ext.isDefined(this.listWidth)) {
      var lw = Math.max(w, this.minListWidth);
      this.list.setWidth(lw);
      this.innerList.setWidth(lw - this.list.getFrameWidth('lr'));
    }
  },
  // private
  onEnable: function onEnable() {
    Ext.form.ComboBox.superclass.onEnable.apply(this, arguments);

    if (this.hiddenField) {
      this.hiddenField.disabled = false;
    }
  },
  // private
  onDisable: function onDisable() {
    Ext.form.ComboBox.superclass.onDisable.apply(this, arguments);

    if (this.hiddenField) {
      this.hiddenField.disabled = true;
    }
  },
  // private
  onBeforeLoad: function onBeforeLoad() {
    if (!this.hasFocus) {
      return;
    }

    this.innerList.update(this.loadingText ? '<div class="loading-indicator"><div class="loading-indicator-wait"></div>' + this.loadingText + '</div>' : '');
    this.restrictHeight();
    this.selectedIndex = -1;
  },
  // private
  onLoad: function onLoad() {
    if (!this.hasFocus) {
      return;
    }

    if (this.store.getCount() > 0 || this.listEmptyText) {
      this.expand();
      this.restrictHeight();

      if (this.lastQuery == this.allQuery) {
        if (this.editable) {
          this.el.dom.select();
        }

        if (this.autoSelect !== false && !this.selectByValue(this.value, true)) {
          this.select(0, true);
        }
      } else {
        if (this.autoSelect !== false) {
          this.selectNext();
        }

        if (this.typeAhead && this.lastKey != Ext.EventObject.BACKSPACE && this.lastKey != Ext.EventObject.DELETE) {
          this.taTask.delay(this.typeAheadDelay);
        }
      }
    } else {
      this.collapse();
    }
  },
  // private
  onTypeAhead: function onTypeAhead() {
    if (this.store.getCount() > 0) {
      var r = this.store.getAt(0);
      var newValue = r.data[this.displayField];
      var len = newValue.length;
      var selStart = this.getRawValue().length;

      if (selStart != len) {
        this.setRawValue(newValue);
        this.selectText(selStart, newValue.length);
      }
    }
  },
  // private
  assertValue: function assertValue() {
    var val = this.getRawValue(),
        rec = this.findRecord(this.displayField, val);

    if (!rec && this.forceSelection) {
      if (val.length > 0 && val != this.emptyText) {
        this.el.dom.value = Ext.value(this.lastSelectionText, '');
        this.applyEmptyText();
      } else {
        this.clearValue();
      }
    } else {
      if (rec) {
        val = rec.get(this.valueField || this.displayField);
      }

      this.setValue(val);
    }
  },
  // private
  onSelect: function onSelect(record, index) {
    if (this.fireEvent('beforeselect', this, record, index) !== false) {
      this.setValue(record.data[this.valueField || this.displayField]);
      this.collapse();
      this.fireEvent('select', this, record, index);
    }
  },
  // inherit docs
  getName: function getName() {
    var hf = this.hiddenField;
    return hf && hf.name ? hf.name : this.hiddenName || Ext.form.ComboBox.superclass.getName.call(this);
  },

  /**
   * Returns the currently selected field value or empty string if no value is set.
   * @return {String} value The selected value
   */
  getValue: function getValue() {
    if (this.valueField) {
      return Ext.isDefined(this.value) ? this.value : '';
    } else {
      return Ext.form.ComboBox.superclass.getValue.call(this);
    }
  },

  /**
   * Clears any text/value currently set in the field
   */
  clearValue: function clearValue() {
    if (this.hiddenField) {
      this.hiddenField.value = '';
    }

    this.setRawValue('');
    this.lastSelectionText = '';
    this.applyEmptyText();
    this.value = '';
  },

  /**
   * Sets the specified value into the field.  If the value finds a match, the corresponding record text
   * will be displayed in the field.  If the value does not match the data value of an existing item,
   * and the valueNotFoundText config option is defined, it will be displayed as the default field text.
   * Otherwise the field will be blank (although the value will still be set).
   * @param {String} value The value to match
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(v) {
    var text = v;

    if (this.valueField) {
      var r = this.findRecord(this.valueField, v);

      if (r) {
        text = r.data[this.displayField];
      } else if (Ext.isDefined(this.valueNotFoundText)) {
        text = this.valueNotFoundText;
      }
    }

    this.lastSelectionText = text;

    if (this.hiddenField) {
      this.hiddenField.value = Ext.value(v, '');
    }

    Ext.form.ComboBox.superclass.setValue.call(this, text);
    this.value = v;
    return this;
  },
  // private
  findRecord: function findRecord(prop, value) {
    var _this$store;

    var record;

    if (((_this$store = this.store) === null || _this$store === void 0 ? void 0 : _this$store.getCount()) > 0) {
      this.store.each(function (r) {
        if (r.data[prop] == value) {
          record = r;
          return false;
        }
      });
    }

    return record;
  },
  // private
  onViewMove: function onViewMove(e, t) {
    this.inKeyMode = false;
  },
  // private
  onViewOver: function onViewOver(e, t) {
    if (this.inKeyMode) {
      // prevent key nav and mouse over conflicts
      return;
    }

    var item = this.view.findItemFromChild(t);

    if (item) {
      var index = this.view.indexOf(item);
      this.select(index, false);
    }
  },
  // private
  onViewClick: function onViewClick(doFocus) {
    var index = this.view.getSelectedIndexes()[0],
        s = this.store,
        r = s.getAt(index);

    if (r) {
      this.onSelect(r, index);
    } else {
      this.collapse();
    }

    if (doFocus !== false) {
      this.el.focus();
    }
  },
  // private
  restrictHeight: function restrictHeight() {
    this.innerList.dom.style.height = '';
    var inner = this.innerList.dom,
        pad = this.list.getFrameWidth('tb') + (this.resizable ? this.handleHeight : 0) + this.assetHeight,
        h = Math.max(inner.clientHeight, inner.offsetHeight, inner.scrollHeight),
        ha = this.getPosition()[1] - Ext.getBody().getScroll().top,
        hb = Ext.lib.Dom.getViewHeight() - ha - this.getSize().height,
        space = Math.max(ha, hb, this.minHeight || 0) - this.list.shadowOffset - pad - 5;
    h = Math.min(h, space, this.maxHeight);
    this.innerList.setHeight(h);
    this.list.beginUpdate();
    this.list.setHeight(h + pad);
    this.list.alignTo.apply(this.list, [this.el].concat(this.listAlign));
    this.list.endUpdate();
  },

  /**
   * Returns true if the dropdown list is expanded, else false.
   */
  isExpanded: function isExpanded() {
    return this.list && this.list.isVisible();
  },

  /**
   * Select an item in the dropdown list by its data value. This function does NOT cause the select event to fire.
   * The store must be loaded and the list expanded for this function to work, otherwise use setValue.
   * @param {String} value The data value of the item to select
   * @param {Boolean} scrollIntoView False to prevent the dropdown list from autoscrolling to display the
   * selected item if it is not currently in view (defaults to true)
   * @return {Boolean} True if the value matched an item in the list, else false
   */
  selectByValue: function selectByValue(v, scrollIntoView) {
    if (!Ext.isEmpty(v, true)) {
      var r = this.findRecord(this.valueField || this.displayField, v);

      if (r) {
        this.select(this.store.indexOf(r), scrollIntoView);
        return true;
      }
    }

    return false;
  },

  /**
   * Select an item in the dropdown list by its numeric index in the list. This function does NOT cause the select event to fire.
   * The store must be loaded and the list expanded for this function to work, otherwise use setValue.
   * @param {Number} index The zero-based index of the list item to select
   * @param {Boolean} scrollIntoView False to prevent the dropdown list from autoscrolling to display the
   * selected item if it is not currently in view (defaults to true)
   */
  select: function select(index, scrollIntoView) {
    this.selectedIndex = index;
    this.view.select(index);

    if (scrollIntoView !== false) {
      var el = this.view.getNode(index);

      if (el) {
        this.innerList.scrollChildIntoView(el, false);
      }
    }
  },
  // private
  selectNext: function selectNext() {
    var ct = this.store.getCount();

    if (ct > 0) {
      if (this.selectedIndex == -1) {
        this.select(0);
      } else if (this.selectedIndex < ct - 1) {
        this.select(this.selectedIndex + 1);
      }
    }
  },
  // private
  selectPrev: function selectPrev() {
    var ct = this.store.getCount();

    if (ct > 0) {
      if (this.selectedIndex == -1) {
        this.select(0);
      } else if (this.selectedIndex !== 0) {
        this.select(this.selectedIndex - 1);
      }
    }
  },
  // private
  onKeyUp: function onKeyUp(e) {
    var k = e.getKey();

    if (this.editable !== false && this.readOnly !== true && (k == e.BACKSPACE || !e.isSpecialKey())) {
      this.lastKey = k;
      this.dqTask.delay(this.queryDelay);
    }

    Ext.form.ComboBox.superclass.onKeyUp.call(this, e);
  },
  // private
  validateBlur: function validateBlur() {
    return !this.list || !this.list.isVisible();
  },
  // private
  initQuery: function initQuery() {
    this.doQuery(this.getRawValue());
  },
  // private
  beforeBlur: function beforeBlur() {
    this.assertValue();
  },
  // private
  postBlur: function postBlur() {
    Ext.form.ComboBox.superclass.postBlur.call(this);
    this.collapse();
    this.inKeyMode = false;
  },

  /**
   * Execute a query to filter the dropdown list.  Fires the {@link #beforequery} event prior to performing the
   * query allowing the query action to be canceled if needed.
   * @param {String} query The SQL query to execute
   * @param {Boolean} forceAll <tt>true</tt> to force the query to execute even if there are currently fewer
   * characters in the field than the minimum specified by the <tt>{@link #minChars}</tt> config option.  It
   * also clears any filter previously saved in the current store (defaults to <tt>false</tt>)
   */
  doQuery: function doQuery(q, forceAll) {
    q = Ext.isEmpty(q) ? '' : q;
    var qe = {
      query: q,
      forceAll: forceAll,
      combo: this,
      cancel: false
    };

    if (this.fireEvent('beforequery', qe) === false || qe.cancel) {
      return false;
    }

    q = qe.query;
    forceAll = qe.forceAll;

    if (forceAll === true || q.length >= this.minChars) {
      if (this.lastQuery !== q) {
        this.lastQuery = q;

        if (this.mode == 'local') {
          this.selectedIndex = -1;

          if (forceAll) {
            this.store.clearFilter();
          } else {
            this.store.filter(this.displayField, q);
          }

          this.onLoad();
        } else {
          this.store.baseParams[this.queryParam] = q;
          this.store.load({
            params: this.getParams(q)
          });
          this.expand();
        }
      } else {
        this.selectedIndex = -1;
        this.onLoad();
      }
    }
  },
  // private
  getParams: function getParams(q) {
    var p = {}; //p[this.queryParam] = q;

    if (this.pageSize) {
      p.start = 0;
      p.limit = this.pageSize;
    }

    return p;
  },

  /**
   * Hides the dropdown list if it is currently expanded. Fires the {@link #collapse} event on completion.
   */
  collapse: function collapse() {
    if (!this.isExpanded()) {
      return;
    }

    this.list.hide();
    Ext.getDoc().un('mousewheel', this.collapseIf, this);
    Ext.getDoc().un('mousedown', this.collapseIf, this);
    this.fireEvent('collapse', this);
  },
  // private
  collapseIf: function collapseIf(e) {
    if (!e.within(this.wrap) && !e.within(this.list)) {
      this.collapse();
    }
  },

  /**
   * Expands the dropdown list if it is currently hidden. Fires the {@link #expand} event on completion.
   */
  expand: function expand() {
    if (this.isExpanded() || !this.hasFocus) {
      return;
    }

    if (this.bufferSize) {
      this.doResize(this.bufferSize);
      delete this.bufferSize;
    }

    this.list.alignTo.apply(this.list, [this.el].concat(this.listAlign));
    this.list.show();

    if (Ext.isGecko2) {
      this.innerList.setOverflow('auto'); // necessary for FF 2.0/Mac
    }

    this.mon(Ext.getDoc(), {
      scope: this,
      mousewheel: this.collapseIf,
      mousedown: this.collapseIf
    });
    this.fireEvent('expand', this);
  },

  /**
   * @method onTriggerClick
   * @hide
   */
  // private
  // Implements the default empty TriggerField.onTriggerClick function
  onTriggerClick: function onTriggerClick() {
    if (this.readOnly || this.disabled) {
      return;
    }

    if (this.isExpanded()) {
      this.collapse();
      this.el.focus();
    } else {
      this.onFocus({});

      if (this.triggerAction == 'all') {
        this.doQuery(this.allQuery, true);
      } else {
        this.doQuery(this.getRawValue());
      }

      this.el.focus();
    }
  }
  /**
   * @hide
   * @method autoSize
   */

  /**
   * @cfg {Boolean} grow @hide
   */

  /**
   * @cfg {Number} growMin @hide
   */

  /**
   * @cfg {Number} growMax @hide
   */

});
Ext.reg('combo', Ext.form.ComboBox);

/***/ }),
/* 877 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.Checkbox
 * @extends Ext.form.Field
 * Single checkbox field.  Can be used as a direct replacement for traditional checkbox fields.
 * @constructor
 * Creates a new Checkbox
 * @param {Object} config Configuration options
 * @xtype checkbox
 */
Ext.form.Checkbox = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {String} focusClass The CSS class to use when the checkbox receives focus (defaults to undefined)
   */
  focusClass: undefined,

  /**
   * @cfg {String} fieldClass The default CSS class for the checkbox (defaults to 'x-form-field')
   */
  fieldClass: 'x-form-field',

  /**
   * @cfg {Boolean} checked <tt>true</tt> if the checkbox should render initially checked (defaults to <tt>false</tt>)
   */
  checked: false,

  /**
   * @cfg {String/Object} autoCreate A DomHelper element spec, or true for a default element spec (defaults to
   * {tag: 'input', type: 'checkbox', autocomplete: 'off'})
   */
  defaultAutoCreate: {
    tag: 'input',
    type: 'checkbox',
    autocomplete: 'off'
  },

  /**
   * @cfg {String} boxLabel The text that appears beside the checkbox
   */

  /**
   * @cfg {String} inputValue The value that should go into the generated input element's value attribute
   */

  /**
   * @cfg {Function} handler A function called when the {@link #checked} value changes (can be used instead of 
   * handling the check event). The handler is passed the following parameters:
   * <div class="mdetail-params"><ul>
   * <li><b>checkbox</b> : Ext.form.Checkbox<div class="sub-desc">The Checkbox being toggled.</div></li>
   * <li><b>checked</b> : Boolean<div class="sub-desc">The new checked state of the checkbox.</div></li>
   * </ul></div>
   */

  /**
   * @cfg {Object} scope An object to use as the scope ('this' reference) of the {@link #handler} function
   * (defaults to this Checkbox).
   */
  // private
  actionMode: 'wrap',
  // private
  initComponent: function initComponent() {
    Ext.form.Checkbox.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event check
     * Fires when the checkbox is checked or unchecked.
     * @param {Ext.form.Checkbox} this This checkbox
     * @param {Boolean} checked The new checked value
     */
    'check');
  },
  // private
  onResize: function onResize() {
    Ext.form.Checkbox.superclass.onResize.apply(this, arguments);

    if (!this.boxLabel && !this.fieldLabel) {
      this.el.alignTo(this.wrap, 'c-c');
    }
  },
  // private
  initEvents: function initEvents() {
    Ext.form.Checkbox.superclass.initEvents.call(this);
    this.mon(this.el, {
      scope: this,
      click: this.onClick,
      change: this.onClick
    });
  },

  /**
   * @hide
   * Overridden and disabled. The editor element does not support standard valid/invalid marking.
   * @method
   */
  markInvalid: Ext.emptyFn,

  /**
   * @hide
   * Overridden and disabled. The editor element does not support standard valid/invalid marking.
   * @method
   */
  clearInvalid: Ext.emptyFn,
  // private
  onRender: function onRender(ct, position) {
    Ext.form.Checkbox.superclass.onRender.call(this, ct, position);

    if (this.inputValue !== undefined) {
      this.el.dom.value = this.inputValue;
    }

    this.wrap = this.el.wrap({
      cls: 'x-form-check-wrap'
    });

    if (this.boxLabel) {
      this.wrap.createChild({
        tag: 'label',
        htmlFor: this.el.id,
        cls: 'x-form-cb-label',
        html: this.boxLabel
      });
    }

    if (this.checked) {
      this.setValue(true);
    } else {
      this.checked = this.el.dom.checked;
    }

    this.el.dom.disabled = this.readOnly || this.disabled; // Need to repaint for IE, otherwise positioning is broken

    if (Ext.isIE) {
      this.wrap.repaint();
    }

    this.resizeEl = this.positionEl = this.wrap;
  },
  // private
  onDestroy: function onDestroy() {
    Ext.destroy(this.wrap);
    Ext.form.Checkbox.superclass.onDestroy.call(this);
  },
  // private
  initValue: function initValue() {
    this.originalValue = this.getValue();
  },

  /**
   * Returns the checked state of the checkbox.
   * @return {Boolean} True if checked, else false
   */
  getValue: function getValue() {
    if (this.rendered) {
      return this.el.dom.checked;
    }

    return this.checked;
  },
  setReadOnly: function setReadOnly(readOnly) {
    if (this.rendered) {
      this.el.dom.disabled = readOnly || this.disabled;
    }

    return Ext.form.Checkbox.superclass.setReadOnly.call(this, readOnly);
  },
  setDisabled: function setDisabled(disabled) {
    Ext.form.Checkbox.superclass.setDisabled.call(this, disabled);

    if (this.rendered) {
      this.el.dom.disabled = this.readOnly || disabled;
    }

    return this;
  },
  // private
  onClick: function onClick() {
    if (this.el.dom.checked != this.checked) {
      this.setValue(this.el.dom.checked);

      if (this.blurOnChange) {
        this.el.blur();
      }
    }
  },

  /**
   * Sets the checked state of the checkbox, fires the 'check' event, and calls a
   * <code>{@link #handler}</code> (if configured).
   * @param {Boolean/String} checked The following values will check the checkbox:
   * <code>true, 'true', '1', or 'on'</code>. Any other value will uncheck the checkbox.
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(v) {
    var checked = this.checked;
    this.checked = v === true || v === 'true' || v == '1' || String(v).toLowerCase() == 'on';

    if (this.rendered) {
      this.el.dom.checked = this.checked;
      this.el.dom.defaultChecked = this.checked;
    }

    if (checked != this.checked) {
      this.fireEvent('check', this, this.checked);

      if (this.handler) {
        this.handler.call(this.scope || this, this, this.checked);
      }
    }

    return this;
  }
});
Ext.reg('checkbox', Ext.form.Checkbox);

/***/ }),
/* 878 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.CheckboxGroup
 * @extends Ext.form.Field
 * <p>A grouping container for {@link Ext.form.Checkbox} controls.</p>
 * <p>Sample usage:</p>
 * <pre><code>
var myCheckboxGroup = new Ext.form.CheckboxGroup({
    id:'myGroup',
    xtype: 'checkboxgroup',
    fieldLabel: 'Single Column',
    itemCls: 'x-check-group-alt',
    // Put all controls in a single column with width 100%
    columns: 1,
    items: [
        {boxLabel: 'Item 1', name: 'cb-col-1'},
        {boxLabel: 'Item 2', name: 'cb-col-2', checked: true},
        {boxLabel: 'Item 3', name: 'cb-col-3'}
    ]
});
 * </code></pre>
 * @constructor
 * Creates a new CheckboxGroup
 * @param {Object} config Configuration options
 * @xtype checkboxgroup
 */
Ext.form.CheckboxGroup = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {Array} items An Array of {@link Ext.form.Checkbox Checkbox}es or Checkbox config objects
   * to arrange in the group.
   */

  /**
   * @cfg {String/Number/Array} columns Specifies the number of columns to use when displaying grouped
   * checkbox/radio controls using automatic layout.  This config can take several types of values:
   * <ul><li><b>'auto'</b> : <p class="sub-desc">The controls will be rendered one per column on one row and the width
   * of each column will be evenly distributed based on the width of the overall field container. This is the default.</p></li>
   * <li><b>Number</b> : <p class="sub-desc">If you specific a number (e.g., 3) that number of columns will be
   * created and the contained controls will be automatically distributed based on the value of {@link #vertical}.</p></li>
   * <li><b>Array</b> : Object<p class="sub-desc">You can also specify an array of column widths, mixing integer
   * (fixed width) and float (percentage width) values as needed (e.g., [100, .25, .75]). Any integer values will
   * be rendered first, then any float values will be calculated as a percentage of the remaining space. Float
   * values do not have to add up to 1 (100%) although if you want the controls to take up the entire field
   * container you should do so.</p></li></ul>
   */
  columns: 'auto',

  /**
   * @cfg {Boolean} vertical True to distribute contained controls across columns, completely filling each column
   * top to bottom before starting on the next column.  The number of controls in each column will be automatically
   * calculated to keep columns as even as possible.  The default value is false, so that controls will be added
   * to columns one at a time, completely filling each row left to right before starting on the next row.
   */
  vertical: false,

  /**
   * @cfg {Boolean} allowBlank False to validate that at least one item in the group is checked (defaults to true).
   * If no items are selected at validation time, {@link @blankText} will be used as the error text.
   */
  allowBlank: true,

  /**
   * @cfg {String} blankText Error text to display if the {@link #allowBlank} validation fails (defaults to "You must
   * select at least one item in this group")
   */
  blankText: "You must select at least one item in this group",
  // private
  defaultType: 'checkbox',
  // private
  groupCls: 'x-form-check-group',
  // private
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event change
     * Fires when the state of a child checkbox changes.
     * @param {Ext.form.CheckboxGroup} this
     * @param {Array} checked An array containing the checked boxes.
     */
    'change');
    this.on('change', this.validate, this);
    Ext.form.CheckboxGroup.superclass.initComponent.call(this);
  },
  // private
  onRender: function onRender(ct, position) {
    if (!this.el) {
      var panelCfg = {
        autoEl: {
          id: this.id
        },
        cls: this.groupCls,
        layout: 'column',
        renderTo: ct,
        bufferResize: false // Default this to false, since it doesn't really have a proper ownerCt.

      };
      var colCfg = {
        xtype: 'container',
        defaultType: this.defaultType,
        layout: 'form',
        defaults: {
          hideLabel: true,
          anchor: '100%'
        }
      };

      if (this.items[0].items) {
        // The container has standard ColumnLayout configs, so pass them in directly
        Ext.apply(panelCfg, {
          layoutConfig: {
            columns: this.items.length
          },
          defaults: this.defaults,
          items: this.items
        });

        for (var i = 0, len = this.items.length; i < len; i++) {
          Ext.applyIf(this.items[i], colCfg);
        }
      } else {
        // The container has field item configs, so we have to generate the column
        // panels first then move the items into the columns as needed.
        var numCols,
            cols = [];

        if (typeof this.columns == 'string') {
          // 'auto' so create a col per item
          this.columns = this.items.length;
        }

        if (!Ext.isArray(this.columns)) {
          var cs = [];

          for (var i = 0; i < this.columns; i++) {
            cs.push(100 / this.columns * .01); // distribute by even %
          }

          this.columns = cs;
        }

        numCols = this.columns.length; // Generate the column configs with the correct width setting

        for (var i = 0; i < numCols; i++) {
          var cc = Ext.apply({
            items: []
          }, colCfg);
          cc[this.columns[i] <= 1 ? 'columnWidth' : 'width'] = this.columns[i];

          if (this.defaults) {
            cc.defaults = Ext.apply(cc.defaults || {}, this.defaults);
          }

          cols.push(cc);
        }

        ; // Distribute the original items into the columns

        if (this.vertical) {
          var rows = Math.ceil(this.items.length / numCols),
              ri = 0;

          for (var i = 0, len = this.items.length; i < len; i++) {
            if (i > 0 && i % rows == 0) {
              ri++;
            }

            if (this.items[i].fieldLabel) {
              this.items[i].hideLabel = false;
            }

            cols[ri].items.push(this.items[i]);
          }

          ;
        } else {
          for (var i = 0, len = this.items.length; i < len; i++) {
            var ci = i % numCols;

            if (this.items[i].fieldLabel) {
              this.items[i].hideLabel = false;
            }

            cols[ci].items.push(this.items[i]);
          }

          ;
        }

        Ext.apply(panelCfg, {
          layoutConfig: {
            columns: numCols
          },
          items: cols
        });
      }

      this.panel = new Ext.Container(panelCfg);
      this.panel.ownerCt = this;
      this.el = this.panel.getEl();

      if (this.forId && this.itemCls) {
        var l = this.el.up(this.itemCls).child('label', true);

        if (l) {
          l.setAttribute('htmlFor', this.forId);
        }
      }

      var fields = this.panel.findBy(function (c) {
        return c.isFormField;
      }, this);
      this.items = new Ext.util.MixedCollection();
      this.items.addAll(fields);
    }

    Ext.form.CheckboxGroup.superclass.onRender.call(this, ct, position);
  },
  initValue: function initValue() {
    if (this.value) {
      this.setValue.apply(this, this.buffered ? this.value : [this.value]);
      delete this.buffered;
      delete this.value;
    }
  },
  afterRender: function afterRender() {
    Ext.form.CheckboxGroup.superclass.afterRender.call(this);
    this.eachItem(function (item) {
      item.on('check', this.fireChecked, this);
      item.inGroup = true;
    });
  },
  // private
  doLayout: function doLayout() {
    //ugly method required to layout hidden items
    if (this.rendered) {
      this.panel.forceLayout = this.ownerCt.forceLayout;
      this.panel.doLayout();
    }
  },
  // private
  fireChecked: function fireChecked() {
    var arr = [];
    this.eachItem(function (item) {
      if (item.checked) {
        arr.push(item);
      }
    });
    this.fireEvent('change', this, arr);
  },
  // private
  validateValue: function validateValue(value) {
    if (!this.allowBlank) {
      var blank = true;
      this.eachItem(function (f) {
        if (f.checked) {
          return blank = false;
        }
      });

      if (blank) {
        this.markInvalid(this.blankText);
        return false;
      }
    }

    return true;
  },
  // private
  isDirty: function isDirty() {
    //override the behaviour to check sub items.
    if (this.disabled || !this.rendered) {
      return false;
    }

    var dirty = false;
    this.eachItem(function (item) {
      if (item.isDirty()) {
        dirty = true;
        return false;
      }
    });
    return dirty;
  },
  // private
  onDisable: function onDisable() {
    this.eachItem(function (item) {
      item.disable();
    });
  },
  // private
  onEnable: function onEnable() {
    this.eachItem(function (item) {
      item.enable();
    });
  },
  // private
  doLayout: function doLayout() {
    if (this.rendered) {
      this.panel.forceLayout = this.ownerCt.forceLayout;
      this.panel.doLayout();
    }
  },
  // private
  onResize: function onResize(w, h) {
    this.panel.setSize(w, h);
    this.panel.doLayout();
  },
  // inherit docs from Field
  reset: function reset() {
    this.eachItem(function (c) {
      if (c.reset) {
        c.reset();
      }
    }); // Defer the clearInvalid so if BaseForm's collection is being iterated it will be called AFTER it is complete.
    // Important because reset is being called on both the group and the individual items.

    (function () {
      this.clearInvalid();
    }).defer(50, this);
  },

  /**
   * {@link Ext.form.Checkbox#setValue Set the value(s)} of an item or items
   * in the group. Examples illustrating how this method may be called:
   * <pre><code>
  // call with name and value
  myCheckboxGroup.setValue('cb-col-1', true);
  // call with an array of boolean values
  myCheckboxGroup.setValue([true, false, false]);
  // call with an object literal specifying item:value pairs
  myCheckboxGroup.setValue({
  'cb-col-2': false,
  'cb-col-3': true
  });
  // use comma separated string to set items with name to true (checked)
  myCheckboxGroup.setValue('cb-col-1,cb-col-3');
   * </code></pre>
   * See {@link Ext.form.Checkbox#setValue} for additional information.
   * @param {Mixed} id The checkbox to check, or as described by example shown.
   * @param {Boolean} value (optional) The value to set the item.
   * @return {Ext.form.CheckboxGroup} this
   */
  setValue: function setValue() {
    if (this.rendered) {
      this.onSetValue.apply(this, arguments);
    } else {
      this.buffered = true;
      this.value = arguments;
    }

    return this;
  },
  onSetValue: function onSetValue(id, value) {
    if (arguments.length == 1) {
      if (Ext.isArray(id)) {
        // an array of boolean values
        Ext.each(id, function (val, idx) {
          var item = this.items.itemAt(idx);

          if (item) {
            item.setValue(val);
          }
        }, this);
      } else if (Ext.isObject(id)) {
        // set of name/value pairs
        for (var i in id) {
          var f = this.getBox(i);

          if (f) {
            f.setValue(id[i]);
          }
        }
      } else {
        this.setValueForItem(id);
      }
    } else {
      var f = this.getBox(id);

      if (f) {
        f.setValue(value);
      }
    }
  },
  // private
  beforeDestroy: function beforeDestroy() {
    Ext.destroy(this.panel);
    Ext.form.CheckboxGroup.superclass.beforeDestroy.call(this);
  },
  setValueForItem: function setValueForItem(val) {
    val = String(val).split(',');
    this.eachItem(function (item) {
      if (val.indexOf(item.inputValue) > -1) {
        item.setValue(true);
      }
    });
  },
  // private
  getBox: function getBox(id) {
    var box = null;
    this.eachItem(function (f) {
      if (id == f || f.dataIndex == id || f.id == id || f.getName() == id) {
        box = f;
        return false;
      }
    });
    return box;
  },

  /**
   * Gets an array of the selected {@link Ext.form.Checkbox} in the group.
   * @return {Array} An array of the selected checkboxes.
   */
  getValue: function getValue() {
    var out = [];
    this.eachItem(function (item) {
      if (item.checked) {
        out.push(item);
      }
    });
    return out;
  },
  // private
  eachItem: function eachItem(fn) {
    if (this.items && this.items.each) {
      this.items.each(fn, this);
    }
  },

  /**
   * @cfg {String} name
   * @hide
   */

  /**
   * @method getRawValue
   * @hide
   */
  getRawValue: Ext.emptyFn,

  /**
   * @method setRawValue
   * @hide
   */
  setRawValue: Ext.emptyFn
});
Ext.reg('checkboxgroup', Ext.form.CheckboxGroup);

/***/ }),
/* 879 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.Radio
 * @extends Ext.form.Checkbox
 * Single radio field.  Same as Checkbox, but provided as a convenience for automatically setting the input type.
 * Radio grouping is handled automatically by the browser if you give each radio in a group the same name.
 * @constructor
 * Creates a new Radio
 * @param {Object} config Configuration options
 * @xtype radio
 */
Ext.form.Radio = Ext.extend(Ext.form.Checkbox, {
  inputType: 'radio',

  /**
   * Overridden and disabled. The editor element does not support standard valid/invalid marking. @hide
   * @method
   */
  markInvalid: Ext.emptyFn,

  /**
   * Overridden and disabled. The editor element does not support standard valid/invalid marking. @hide
   * @method
   */
  clearInvalid: Ext.emptyFn,

  /**
   * If this radio is part of a group, it will return the selected value
   * @return {String}
   */
  getGroupValue: function getGroupValue() {
    var p = this.el.up('form') || Ext.getBody();
    var c = p.child('input[name=' + this.el.dom.name + ']:checked', true);
    return c ? c.value : null;
  },
  // private
  onClick: function onClick() {
    if (this.el.dom.checked != this.checked) {
      var els = this.getCheckEl().select('input[name=' + this.el.dom.name + ']');
      els.each(function (el) {
        if (el.dom.id == this.id) {
          this.setValue(true);
        } else {
          Ext.getCmp(el.dom.id).setValue(false);
        }
      }, this);
    }
  },

  /**
   * Sets either the checked/unchecked status of this Radio, or, if a string value
   * is passed, checks a sibling Radio of the same name whose value is the value specified.
   * @param value {String/Boolean} Checked value, or the value of the sibling radio button to check.
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(v) {
    if (typeof v == 'boolean') {
      Ext.form.Radio.superclass.setValue.call(this, v);
    } else if (this.rendered) {
      var r = this.getCheckEl().child('input[name=' + this.el.dom.name + '][value=' + v + ']', true);

      if (r) {
        Ext.getCmp(r.id).setValue(true);
      }
    }

    return this;
  },
  // private
  getCheckEl: function getCheckEl() {
    if (this.inGroup) {
      return this.el.up('.x-form-radio-group');
    }

    return this.el.up('form') || Ext.getBody();
  }
});
Ext.reg('radio', Ext.form.Radio);

/***/ }),
/* 880 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.RadioGroup
 * @extends Ext.form.CheckboxGroup
 * A grouping container for {@link Ext.form.Radio} controls.
 * @constructor
 * Creates a new RadioGroup
 * @param {Object} config Configuration options
 * @xtype radiogroup
 */
Ext.form.RadioGroup = Ext.extend(Ext.form.CheckboxGroup, {
  /**
   * @cfg {Array} items An Array of {@link Ext.form.Radio Radio}s or Radio config objects
   * to arrange in the group.
   */

  /**
   * @cfg {Boolean} allowBlank True to allow every item in the group to be blank (defaults to true).
   * If allowBlank = false and no items are selected at validation time, {@link @blankText} will
   * be used as the error text.
   */
  allowBlank: true,

  /**
   * @cfg {String} blankText Error text to display if the {@link #allowBlank} validation fails
   * (defaults to 'You must select one item in this group')
   */
  blankText: 'You must select one item in this group',
  // private
  defaultType: 'radio',
  // private
  groupCls: 'x-form-radio-group',

  /**
   * @event change
   * Fires when the state of a child radio changes.
   * @param {Ext.form.RadioGroup} this
   * @param {Ext.form.Radio} checked The checked radio
   */

  /**
   * Gets the selected {@link Ext.form.Radio} in the group, if it exists.
   * @return {Ext.form.Radio} The selected radio.
   */
  getValue: function getValue() {
    var out = null;
    this.eachItem(function (item) {
      if (item.checked) {
        out = item;
        return false;
      }
    });
    return out;
  },

  /**
   * Sets the checked radio in the group.
   * @param {String/Ext.form.Radio} id The radio to check.
   * @param {Boolean} value The value to set the radio.
   * @return {Ext.form.RadioGroup} this
   */
  onSetValue: function onSetValue(id, value) {
    if (arguments.length > 1) {
      var f = this.getBox(id);

      if (f) {
        f.setValue(value);

        if (f.checked) {
          this.eachItem(function (item) {
            if (item !== f) {
              item.setValue(false);
            }
          });
        }
      }
    } else {
      this.setValueForItem(id);
    }
  },
  setValueForItem: function setValueForItem(val) {
    val = String(val).split(',')[0];
    this.eachItem(function (item) {
      item.setValue(val == item.inputValue);
    });
  },
  // private
  fireChecked: function fireChecked() {
    if (!this.checkTask) {
      this.checkTask = new Ext.util.DelayedTask(this.bufferChecked, this);
    }

    this.checkTask.delay(10);
  },
  // private
  bufferChecked: function bufferChecked() {
    var out = null;
    this.eachItem(function (item) {
      if (item.checked) {
        out = item;
        return false;
      }
    });
    this.fireEvent('change', this, out);
  },
  onDestroy: function onDestroy() {
    if (this.checkTask) {
      this.checkTask.cancel();
      this.checkTask = null;
    }

    Ext.form.RadioGroup.superclass.onDestroy.call(this);
  }
});
Ext.reg('radiogroup', Ext.form.RadioGroup);

/***/ }),
/* 881 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.Hidden
 * @extends Ext.form.Field
 * A basic hidden field for storing hidden values in forms that need to be passed in the form submit.
 * @constructor
 * Create a new Hidden field.
 * @param {Object} config Configuration options
 * @xtype hidden
 */
Ext.form.Hidden = Ext.extend(Ext.form.Field, {
  // private
  inputType: 'hidden',
  // private
  onRender: function onRender() {
    Ext.form.Hidden.superclass.onRender.apply(this, arguments);
  },
  // private
  initEvents: function initEvents() {
    this.originalValue = this.getValue();
  },
  // These are all private overrides
  setSize: Ext.emptyFn,
  setWidth: Ext.emptyFn,
  setHeight: Ext.emptyFn,
  setPosition: Ext.emptyFn,
  setPagePosition: Ext.emptyFn,
  markInvalid: Ext.emptyFn,
  clearInvalid: Ext.emptyFn
});
Ext.reg('hidden', Ext.form.Hidden);

/***/ }),
/* 882 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.BasicForm
 * @extends Ext.util.Observable
 * <p>Encapsulates the DOM &lt;form> element at the heart of the {@link Ext.form.FormPanel FormPanel} class, and provides
 * input field management, validation, submission, and form loading services.</p>
 * <p>By default, Ext Forms are submitted through Ajax, using an instance of {@link Ext.form.Action.Submit}.
 * To enable normal browser submission of an Ext Form, use the {@link #standardSubmit} config option.</p>
 * <p><b><u>File Uploads</u></b></p>
 * <p>{@link #fileUpload File uploads} are not performed using Ajax submission, that
 * is they are <b>not</b> performed using XMLHttpRequests. Instead the form is submitted in the standard
 * manner with the DOM <tt>&lt;form></tt> element temporarily modified to have its
 * <a href="http://www.w3.org/TR/REC-html40/present/frames.html#adef-target">target</a> set to refer
 * to a dynamically generated, hidden <tt>&lt;iframe></tt> which is inserted into the document
 * but removed after the return data has been gathered.</p>
 * <p>The server response is parsed by the browser to create the document for the IFRAME. If the
 * server is using JSON to send the return object, then the
 * <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.17">Content-Type</a> header
 * must be set to "text/html" in order to tell the browser to insert the text unchanged into the document body.</p>
 * <p>Characters which are significant to an HTML parser must be sent as HTML entities, so encode
 * "&lt;" as "&amp;lt;", "&amp;" as "&amp;amp;" etc.</p>
 * <p>The response text is retrieved from the document, and a fake XMLHttpRequest object
 * is created containing a <tt>responseText</tt> property in order to conform to the
 * requirements of event handlers and callbacks.</p>
 * <p>Be aware that file upload packets are sent with the content type <a href="http://www.faqs.org/rfcs/rfc2388.html">multipart/form</a>
 * and some server technologies (notably JEE) may require some custom processing in order to
 * retrieve parameter names and parameter values from the packet content.</p>
 * @constructor
 * @param {Mixed} el The form element or its id
 * @param {Object} config Configuration options
 */
Ext.form.BasicForm = Ext.extend(Ext.util.Observable, {
  constructor: function constructor(el, config) {
    Ext.apply(this, config);

    if (Ext.isString(this.paramOrder)) {
      this.paramOrder = this.paramOrder.split(/[\s,|]/);
    }
    /**
     * A {@link Ext.util.MixedCollection MixedCollection} containing all the Ext.form.Fields in this form.
     * @type MixedCollection
     * @property items
     */


    this.items = new Ext.util.MixedCollection(false, function (o) {
      return o.getItemId();
    });
    this.addEvents(
    /**
     * @event beforeaction
     * Fires before any action is performed. Return false to cancel the action.
     * @param {Form} this
     * @param {Action} action The {@link Ext.form.Action} to be performed
     */
    'beforeaction',
    /**
     * @event actionfailed
     * Fires when an action fails.
     * @param {Form} this
     * @param {Action} action The {@link Ext.form.Action} that failed
     */
    'actionfailed',
    /**
     * @event actioncomplete
     * Fires when an action is completed.
     * @param {Form} this
     * @param {Action} action The {@link Ext.form.Action} that completed
     */
    'actioncomplete');

    if (el) {
      this.initEl(el);
    }

    Ext.form.BasicForm.superclass.constructor.call(this);
  },

  /**
   * @cfg {String} method
   * The request method to use (GET or POST) for form actions if one isn't supplied in the action options.
   */

  /**
   * @cfg {DataReader} reader
   * An Ext.data.DataReader (e.g. {@link Ext.data.XmlReader}) to be used to read
   * data when executing 'load' actions. This is optional as there is built-in
   * support for processing JSON.  For additional information on using an XMLReader
   * see the example provided in examples/form/xml-form.html.
   */

  /**
   * @cfg {DataReader} errorReader
   * <p>An Ext.data.DataReader (e.g. {@link Ext.data.XmlReader}) to be used to
   * read field error messages returned from 'submit' actions. This is optional
   * as there is built-in support for processing JSON.</p>
   * <p>The Records which provide messages for the invalid Fields must use the
   * Field name (or id) as the Record ID, and must contain a field called 'msg'
   * which contains the error message.</p>
   * <p>The errorReader does not have to be a full-blown implementation of a
   * DataReader. It simply needs to implement a <tt>read(xhr)</tt> function
   * which returns an Array of Records in an object with the following
   * structure:</p><pre><code>
  {
  records: recordArray
  }
  </code></pre>
   */

  /**
   * @cfg {String} url
   * The URL to use for form actions if one isn't supplied in the
   * <code>{@link #doAction doAction} options</code>.
   */

  /**
   * @cfg {Boolean} fileUpload
   * Set to true if this form is a file upload.
   * <p>File uploads are not performed using normal 'Ajax' techniques, that is they are <b>not</b>
   * performed using XMLHttpRequests. Instead the form is submitted in the standard manner with the
   * DOM <tt>&lt;form></tt> element temporarily modified to have its
   * <a href="http://www.w3.org/TR/REC-html40/present/frames.html#adef-target">target</a> set to refer
   * to a dynamically generated, hidden <tt>&lt;iframe></tt> which is inserted into the document
   * but removed after the return data has been gathered.</p>
   * <p>The server response is parsed by the browser to create the document for the IFRAME. If the
   * server is using JSON to send the return object, then the
   * <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.17">Content-Type</a> header
   * must be set to "text/html" in order to tell the browser to insert the text unchanged into the document body.</p>
   * <p>Characters which are significant to an HTML parser must be sent as HTML entities, so encode
   * "&lt;" as "&amp;lt;", "&amp;" as "&amp;amp;" etc.</p>
   * <p>The response text is retrieved from the document, and a fake XMLHttpRequest object
   * is created containing a <tt>responseText</tt> property in order to conform to the
   * requirements of event handlers and callbacks.</p>
   * <p>Be aware that file upload packets are sent with the content type <a href="http://www.faqs.org/rfcs/rfc2388.html">multipart/form</a>
   * and some server technologies (notably JEE) may require some custom processing in order to
   * retrieve parameter names and parameter values from the packet content.</p>
   */

  /**
   * @cfg {Object} baseParams
   * <p>Parameters to pass with all requests. e.g. baseParams: {id: '123', foo: 'bar'}.</p>
   * <p>Parameters are encoded as standard HTTP parameters using {@link Ext#urlEncode}.</p>
   */

  /**
   * @cfg {Number} timeout Timeout for form actions in seconds (default is 30 seconds).
   */
  timeout: 30,

  /**
   * @cfg {Object} api (Optional) If specified load and submit actions will be handled
   * with {@link Ext.form.Action.DirectLoad} and {@link Ext.form.Action.DirectSubmit}.
   * Methods which have been imported by Ext.Direct can be specified here to load and submit
   * forms.
   * Such as the following:<pre><code>
  api: {
  load: App.ss.MyProfile.load,
  submit: App.ss.MyProfile.submit
  }
  </code></pre>
   * <p>Load actions can use <code>{@link #paramOrder}</code> or <code>{@link #paramsAsHash}</code>
   * to customize how the load method is invoked.
   * Submit actions will always use a standard form submit. The formHandler configuration must
   * be set on the associated server-side method which has been imported by Ext.Direct</p>
   */

  /**
   * @cfg {Array/String} paramOrder <p>A list of params to be executed server side.
   * Defaults to <tt>undefined</tt>. Only used for the <code>{@link #api}</code>
   * <code>load</code> configuration.</p>
   * <br><p>Specify the params in the order in which they must be executed on the
   * server-side as either (1) an Array of String values, or (2) a String of params
   * delimited by either whitespace, comma, or pipe. For example,
   * any of the following would be acceptable:</p><pre><code>
  paramOrder: ['param1','param2','param3']
  paramOrder: 'param1 param2 param3'
  paramOrder: 'param1,param2,param3'
  paramOrder: 'param1|param2|param'
   </code></pre>
   */
  paramOrder: undefined,

  /**
   * @cfg {Boolean} paramsAsHash Only used for the <code>{@link #api}</code>
   * <code>load</code> configuration. Send parameters as a collection of named
   * arguments (defaults to <tt>false</tt>). Providing a
   * <tt>{@link #paramOrder}</tt> nullifies this configuration.
   */
  paramsAsHash: false,

  /**
   * @cfg {String} waitTitle
   * The default title to show for the waiting message box (defaults to <tt>'Please Wait...'</tt>)
   */
  waitTitle: 'Please Wait...',
  // private
  activeAction: null,

  /**
   * @cfg {Boolean} trackResetOnLoad If set to <tt>true</tt>, {@link #reset}() resets to the last loaded
   * or {@link #setValues}() data instead of when the form was first created.  Defaults to <tt>false</tt>.
   */
  trackResetOnLoad: false,

  /**
   * @cfg {Boolean} standardSubmit
   * <p>If set to <tt>true</tt>, standard HTML form submits are used instead
   * of XHR (Ajax) style form submissions. Defaults to <tt>false</tt>.</p>
   * <br><p><b>Note:</b> When using <code>standardSubmit</code>, the
   * <code>options</code> to <code>{@link #submit}</code> are ignored because
   * Ext's Ajax infrastracture is bypassed. To pass extra parameters (e.g.
   * <code>baseParams</code> and <code>params</code>), utilize hidden fields
   * to submit extra data, for example:</p>
   * <pre><code>
  new Ext.FormPanel({
  standardSubmit: true,
  baseParams: {
      foo: 'bar'
  },
  {@link url}: 'myProcess.php',
  items: [{
      xtype: 'textfield',
      name: 'userName'
  }],
  buttons: [{
      text: 'Save',
      handler: function(){
          var fp = this.ownerCt.ownerCt,
              form = fp.getForm();
          if (form.isValid()) {
              // check if there are baseParams and if
              // hiddent items have been added already
              if (fp.baseParams && !fp.paramsAdded) {
                  // add hidden items for all baseParams
                  for (i in fp.baseParams) {
                      fp.add({
                          xtype: 'hidden',
                          name: i,
                          value: fp.baseParams[i]
                      });
                  }
                  fp.doLayout();
                  // set a custom flag to prevent re-adding
                  fp.paramsAdded = true;
              }
              form.{@link #submit}();
          }
      }
  }]
  });
   * </code></pre>
   */

  /**
   * By default wait messages are displayed with Ext.MessageBox.wait. You can target a specific
   * element by passing it or its id or mask the form itself by passing in true.
   * @type Mixed
   * @property waitMsgTarget
   */
  // private
  initEl: function initEl(el) {
    this.el = Ext.get(el);
    this.id = this.el.id || Ext.id();

    if (!this.standardSubmit) {
      this.el.on('submit', this.onSubmit, this);
    }

    this.el.addClass('x-form');
  },

  /**
   * Get the HTML form Element
   * @return Ext.Element
   */
  getEl: function getEl() {
    return this.el;
  },
  // private
  onSubmit: function onSubmit(e) {
    e.stopEvent();
  },
  // private
  destroy: function destroy() {
    this.items.each(function (f) {
      Ext.destroy(f);
    });

    if (this.el) {
      this.el.removeAllListeners();
      this.el.remove();
    }

    this.purgeListeners();
  },

  /**
   * Returns true if client-side validation on the form is successful.
   * @return Boolean
   */
  isValid: function isValid() {
    var valid = true;
    this.items.each(function (f) {
      if (!f.validate()) {
        valid = false;
      }
    });
    return valid;
  },

  /**
   * <p>Returns true if any fields in this form have changed from their original values.</p>
   * <p>Note that if this BasicForm was configured with {@link #trackResetOnLoad} then the
   * Fields' <i>original values</i> are updated when the values are loaded by {@link #setValues}
   * or {@link #loadRecord}.</p>
   * @return Boolean
   */
  isDirty: function isDirty() {
    var dirty = false;
    this.items.each(function (f) {
      if (f.isDirty()) {
        dirty = true;
        return false;
      }
    });
    return dirty;
  },

  /**
   * Performs a predefined action ({@link Ext.form.Action.Submit} or
   * {@link Ext.form.Action.Load}) or a custom extension of {@link Ext.form.Action}
   * to perform application-specific processing.
   * @param {String/Object} actionName The name of the predefined action type,
   * or instance of {@link Ext.form.Action} to perform.
   * @param {Object} options (optional) The options to pass to the {@link Ext.form.Action}.
   * All of the config options listed below are supported by both the
   * {@link Ext.form.Action.Submit submit} and {@link Ext.form.Action.Load load}
   * actions unless otherwise noted (custom actions could also accept
   * other config options):<ul>
   *
   * <li><b>url</b> : String<div class="sub-desc">The url for the action (defaults
   * to the form's {@link #url}.)</div></li>
   *
   * <li><b>method</b> : String<div class="sub-desc">The form method to use (defaults
   * to the form's method, or POST if not defined)</div></li>
   *
   * <li><b>params</b> : String/Object<div class="sub-desc"><p>The params to pass
   * (defaults to the form's baseParams, or none if not defined)</p>
   * <p>Parameters are encoded as standard HTTP parameters using {@link Ext#urlEncode}.</p></div></li>
   *
   * <li><b>headers</b> : Object<div class="sub-desc">Request headers to set for the action
   * (defaults to the form's default headers)</div></li>
   *
   * <li><b>success</b> : Function<div class="sub-desc">The callback that will
   * be invoked after a successful response (see top of
   * {@link Ext.form.Action.Submit submit} and {@link Ext.form.Action.Load load}
   * for a description of what constitutes a successful response).
   * The function is passed the following parameters:<ul>
   * <li><tt>form</tt> : Ext.form.BasicForm<div class="sub-desc">The form that requested the action</div></li>
   * <li><tt>action</tt> : The {@link Ext.form.Action Action} object which performed the operation.
   * <div class="sub-desc">The action object contains these properties of interest:<ul>
   * <li><tt>{@link Ext.form.Action#response response}</tt></li>
   * <li><tt>{@link Ext.form.Action#result result}</tt> : interrogate for custom postprocessing</li>
   * <li><tt>{@link Ext.form.Action#type type}</tt></li>
   * </ul></div></li></ul></div></li>
   *
   * <li><b>failure</b> : Function<div class="sub-desc">The callback that will be invoked after a
   * failed transaction attempt. The function is passed the following parameters:<ul>
   * <li><tt>form</tt> : The {@link Ext.form.BasicForm} that requested the action.</li>
   * <li><tt>action</tt> : The {@link Ext.form.Action Action} object which performed the operation.
   * <div class="sub-desc">The action object contains these properties of interest:<ul>
   * <li><tt>{@link Ext.form.Action#failureType failureType}</tt></li>
   * <li><tt>{@link Ext.form.Action#response response}</tt></li>
   * <li><tt>{@link Ext.form.Action#result result}</tt> : interrogate for custom postprocessing</li>
   * <li><tt>{@link Ext.form.Action#type type}</tt></li>
   * </ul></div></li></ul></div></li>
   *
   * <li><b>scope</b> : Object<div class="sub-desc">The scope in which to call the
   * callback functions (The <tt>this</tt> reference for the callback functions).</div></li>
   *
   * <li><b>clientValidation</b> : Boolean<div class="sub-desc">Submit Action only.
   * Determines whether a Form's fields are validated in a final call to
   * {@link Ext.form.BasicForm#isValid isValid} prior to submission. Set to <tt>false</tt>
   * to prevent this. If undefined, pre-submission field validation is performed.</div></li></ul>
   *
   * @return {BasicForm} this
   */
  doAction: function doAction(action, options) {
    if (Ext.isString(action)) {
      action = new Ext.form.Action.ACTION_TYPES[action](this, options);
    }

    if (this.fireEvent('beforeaction', this, action) !== false) {
      this.beforeAction(action);
      action.run.defer(100, action);
    }

    return this;
  },

  /**
   * Shortcut to {@link #doAction do} a {@link Ext.form.Action.Submit submit action}.
   * @param {Object} options The options to pass to the action (see {@link #doAction} for details).<br>
   * <p><b>Note:</b> this is ignored when using the {@link #standardSubmit} option.</p>
   * <p>The following code:</p><pre><code>
  myFormPanel.getForm().submit({
  clientValidation: true,
  url: 'updateConsignment.php',
  params: {
      newStatus: 'delivered'
  },
  success: function(form, action) {
     Ext.Msg.alert('Success', action.result.msg);
  },
  failure: function(form, action) {
      switch (action.failureType) {
          case Ext.form.Action.CLIENT_INVALID:
              Ext.Msg.alert('Failure', 'Form fields may not be submitted with invalid values');
              break;
          case Ext.form.Action.CONNECT_FAILURE:
              Ext.Msg.alert('Failure', 'Ajax communication failed');
              break;
          case Ext.form.Action.SERVER_INVALID:
             Ext.Msg.alert('Failure', action.result.msg);
     }
  }
  });
  </code></pre>
   * would process the following server response for a successful submission:<pre><code>
  {
  "success":true, // note this is Boolean, not string
  "msg":"Consignment updated"
  }
  </code></pre>
   * and the following server response for a failed submission:<pre><code>
  {
  "success":false, // note this is Boolean, not string
  "msg":"You do not have permission to perform this operation"
  }
  </code></pre>
   * @return {BasicForm} this
   */
  submit: function submit(options) {
    if (this.standardSubmit) {
      var v = this.isValid();

      if (v) {
        var el = this.el.dom;

        if (this.url && Ext.isEmpty(el.action)) {
          el.action = this.url;
        }

        el.submit();
      }

      return v;
    }

    var submitAction = String.format('{0}submit', this.api ? 'direct' : '');
    this.doAction(submitAction, options);
    return this;
  },

  /**
   * Shortcut to {@link #doAction do} a {@link Ext.form.Action.Load load action}.
   * @param {Object} options The options to pass to the action (see {@link #doAction} for details)
   * @return {BasicForm} this
   */
  load: function load(options) {
    var loadAction = String.format('{0}load', this.api ? 'direct' : '');
    this.doAction(loadAction, options);
    return this;
  },

  /**
   * Persists the values in this form into the passed {@link Ext.data.Record} object in a beginEdit/endEdit block.
   * @param {Record} record The record to edit
   * @return {BasicForm} this
   */
  updateRecord: function updateRecord(record) {
    record.beginEdit();
    var fs = record.fields;
    fs.each(function (f) {
      var field = this.findField(f.name);

      if (field) {
        record.set(f.name, field.getValue());
      }
    }, this);
    record.endEdit();
    return this;
  },

  /**
   * Loads an {@link Ext.data.Record} into this form by calling {@link #setValues} with the
   * {@link Ext.data.Record#data record data}.
   * See also {@link #trackResetOnLoad}.
   * @param {Record} record The record to load
   * @return {BasicForm} this
   */
  loadRecord: function loadRecord(record) {
    this.setValues(record.data, record);
    return this;
  },
  // private
  beforeAction: function beforeAction(action) {
    var o = action.options;

    if (o.waitMsg) {
      if (this.waitMsgTarget === true) {
        this.el.mask(o.waitMsg, 'x-mask-loading');
      } else if (this.waitMsgTarget) {
        this.waitMsgTarget = Ext.get(this.waitMsgTarget);
        this.waitMsgTarget.mask(o.waitMsg, 'x-mask-loading');
      } else {
        Ext.MessageBox.wait(o.waitMsg, o.waitTitle || this.waitTitle);
      }
    }
  },
  // private
  afterAction: function afterAction(action, success) {
    this.activeAction = null;
    var o = action.options;

    if (o.waitMsg) {
      if (this.waitMsgTarget === true) {
        this.el.unmask();
      } else if (this.waitMsgTarget) {
        this.waitMsgTarget.unmask();
      } else {
        Ext.MessageBox.updateProgress(1);
        Ext.MessageBox.hide();
      }
    }

    if (success) {
      if (o.reset) {
        this.reset();
      }

      Ext.callback(o.success, o.scope, [this, action]);
      this.fireEvent('actioncomplete', this, action);
    } else {
      Ext.callback(o.failure, o.scope, [this, action]);
      this.fireEvent('actionfailed', this, action);
    }
  },

  /**
   * Find a {@link Ext.form.Field} in this form.
   * @param {String} id The value to search for (specify either a {@link Ext.Component#id id},
   * {@link Ext.grid.Column#dataIndex dataIndex}, {@link Ext.form.Field#getName name or hiddenName}).
   * @return Field
   */
  findField: function findField(id) {
    var field = this.items.get(id);

    if (!Ext.isObject(field)) {
      this.items.each(function (f) {
        if (f.isFormField && (f.dataIndex == id || f.id == id || f.getName() == id)) {
          field = f;
          return false;
        }
      });
    }

    return field || null;
  },

  /**
   * Mark fields in this form invalid in bulk.
   * @param {Array/Object} errors Either an array in the form [{id:'fieldId', msg:'The message'},...] or an object hash of {id: msg, id2: msg2}
   * @return {BasicForm} this
   */
  markInvalid: function markInvalid(errors) {
    if (Ext.isArray(errors)) {
      for (var i = 0, len = errors.length; i < len; i++) {
        var fieldError = errors[i];
        var f = this.findField(fieldError.id);

        if (f) {
          f.markInvalid(fieldError.msg);
        }
      }
    } else {
      var field, id;

      for (id in errors) {
        if (!Ext.isFunction(errors[id]) && (field = this.findField(id))) {
          field.markInvalid(errors[id]);
        }
      }
    }

    return this;
  },

  /**
   * Set values for fields in this form in bulk.
   * @param {Array/Object} values Either an array in the form:<pre><code>
  [{id:'clientName', value:'Fred. Olsen Lines'},
  {id:'portOfLoading', value:'FXT'},
  {id:'portOfDischarge', value:'OSL'} ]</code></pre>
   * or an object hash of the form:<pre><code>
  {
  clientName: 'Fred. Olsen Lines',
  portOfLoading: 'FXT',
  portOfDischarge: 'OSL'
  }</code></pre>
   * @return {BasicForm} this
   */
  setValues: function setValues(values, record) {
    if (Ext.isArray(values)) {
      // array of objects
      for (var i = 0, len = values.length; i < len; i++) {
        var v = values[i];
        var f = this.findField(v.id);

        if (f) {
          f.setValue(v.value, record);

          if (this.trackResetOnLoad) {
            f.originalValue = f.getValue();
          }
        }
      }
    } else {
      // object hash
      var field, id;

      for (id in values) {
        if (!Ext.isFunction(values[id]) && (field = this.findField(id))) {
          field.setValue(values[id], record);

          if (this.trackResetOnLoad) {
            field.originalValue = field.getValue();
          }
        }
      }
    }

    return this;
  },

  /**
   * <p>Returns the fields in this form as an object with key/value pairs as they would be submitted using a standard form submit.
   * If multiple fields exist with the same name they are returned as an array.</p>
   * <p><b>Note:</b> The values are collected from all enabled HTML input elements within the form, <u>not</u> from
   * the Ext Field objects. This means that all returned values are Strings (or Arrays of Strings) and that the
   * value can potentially be the emptyText of a field.</p>
   * @param {Boolean} asString (optional) Pass true to return the values as a string. (defaults to false, returning an Object)
   * @return {String/Object}
   */
  getValues: function getValues(asString) {
    var fs = Ext.lib.Ajax.serializeForm(this.el.dom);

    if (asString === true) {
      return fs;
    }

    return Ext.urlDecode(fs);
  },

  /**
   * Retrieves the fields in the form as a set of key/value pairs, using the {@link Ext.form.Field#getValue getValue()} method.
   * If multiple fields exist with the same name they are returned as an array.
   * @param {Boolean} dirtyOnly (optional) True to return only fields that are dirty.
   * @return {Object} The values in the form
   */
  getFieldValues: function getFieldValues(dirtyOnly) {
    var o = {},
        n,
        key,
        val;
    this.items.each(function (f) {
      if (dirtyOnly !== true || f.isDirty()) {
        n = f.getName();
        key = o[n];
        val = f.getValue();

        if (Ext.isDefined(key)) {
          if (Ext.isArray(key)) {
            o[n].push(val);
          } else {
            o[n] = [key, val];
          }
        } else {
          o[n] = val;
        }
      }
    });
    return o;
  },

  /**
   * Clears all invalid messages in this form.
   * @return {BasicForm} this
   */
  clearInvalid: function clearInvalid() {
    this.items.each(function (f) {
      f.clearInvalid();
    });
    return this;
  },

  /**
   * Resets this form.
   * @return {BasicForm} this
   */
  reset: function reset() {
    this.items.each(function (f) {
      f.reset();
    });
    return this;
  },

  /**
   * Add Ext.form Components to this form's Collection. This does not result in rendering of
   * the passed Component, it just enables the form to validate Fields, and distribute values to
   * Fields.
   * <p><b>You will not usually call this function. In order to be rendered, a Field must be added
   * to a {@link Ext.Container Container}, usually an {@link Ext.form.FormPanel FormPanel}.
   * The FormPanel to which the field is added takes care of adding the Field to the BasicForm's
   * collection.</b></p>
   * @param {Field} field1
   * @param {Field} field2 (optional)
   * @param {Field} etc (optional)
   * @return {BasicForm} this
   */
  add: function add() {
    this.items.addAll(Array.prototype.slice.call(arguments, 0));
    return this;
  },

  /**
   * Removes a field from the items collection (does NOT remove its markup).
   * @param {Field} field
   * @return {BasicForm} this
   */
  remove: function remove(field) {
    this.items.remove(field);
    return this;
  },

  /**
   * Iterates through the {@link Ext.form.Field Field}s which have been {@link #add add}ed to this BasicForm,
   * checks them for an id attribute, and calls {@link Ext.form.Field#applyToMarkup} on the existing dom element with that id.
   * @return {BasicForm} this
   */
  render: function render() {
    this.items.each(function (f) {
      if (f.isFormField && !f.rendered && document.getElementById(f.id)) {
        // if the element exists
        f.applyToMarkup(f.id);
      }
    });
    return this;
  },

  /**
   * Calls {@link Ext#apply} for all fields in this form with the passed object.
   * @param {Object} values
   * @return {BasicForm} this
   */
  applyToFields: function applyToFields(o) {
    this.items.each(function (f) {
      Ext.apply(f, o);
    });
    return this;
  },

  /**
   * Calls {@link Ext#applyIf} for all field in this form with the passed object.
   * @param {Object} values
   * @return {BasicForm} this
   */
  applyIfToFields: function applyIfToFields(o) {
    this.items.each(function (f) {
      Ext.applyIf(f, o);
    });
    return this;
  },
  callFieldMethod: function callFieldMethod(fnName, args) {
    args = args || [];
    this.items.each(function (f) {
      if (Ext.isFunction(f[fnName])) {
        f[fnName].apply(f, args);
      }
    });
    return this;
  }
}); // back compat

Ext.BasicForm = Ext.form.BasicForm;

/***/ }),
/* 883 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.FormPanel
 * @extends Ext.Panel
 * <p>Standard form container.</p>
 *
 * <p><b><u>Layout</u></b></p>
 * <p>By default, FormPanel is configured with <tt>layout:'form'</tt> to use an {@link Ext.layout.FormLayout}
 * layout manager, which styles and renders fields and labels correctly. When nesting additional Containers
 * within a FormPanel, you should ensure that any descendant Containers which host input Fields use the
 * {@link Ext.layout.FormLayout} layout manager.</p>
 *
 * <p><b><u>BasicForm</u></b></p>
 * <p>Although <b>not listed</b> as configuration options of FormPanel, the FormPanel class accepts all
 * of the config options required to configure its internal {@link Ext.form.BasicForm} for:
 * <div class="mdetail-params"><ul>
 * <li>{@link Ext.form.BasicForm#fileUpload file uploads}</li>
 * <li>functionality for {@link Ext.form.BasicForm#doAction loading, validating and submitting} the form</li>
 * </ul></div>
 *
 * <p><b>Note</b>: If subclassing FormPanel, any configuration options for the BasicForm must be applied to
 * the <tt><b>initialConfig</b></tt> property of the FormPanel. Applying {@link Ext.form.BasicForm BasicForm}
 * configuration settings to <b><tt>this</tt></b> will <b>not</b> affect the BasicForm's configuration.</p>
 *
 * <p><b><u>Form Validation</u></b></p>
 * <p>For information on form validation see the following:</p>
 * <div class="mdetail-params"><ul>
 * <li>{@link Ext.form.TextField}</li>
 * <li>{@link Ext.form.VTypes}</li>
 * <li>{@link Ext.form.BasicForm#doAction BasicForm.doAction <b>clientValidation</b> notes}</li>
 * <li><tt>{@link Ext.form.FormPanel#monitorValid monitorValid}</tt></li>
 * </ul></div>
 *
 * <p><b><u>Form Submission</u></b></p>
 * <p>By default, Ext Forms are submitted through Ajax, using {@link Ext.form.Action}. To enable normal browser
 * submission of the {@link Ext.form.BasicForm BasicForm} contained in this FormPanel, see the
 * <tt><b>{@link Ext.form.BasicForm#standardSubmit standardSubmit}</b></tt> option.</p>
 *
 * @constructor
 * @param {Object} config Configuration options
 * @xtype form
 */
Ext.FormPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {String} formId (optional) The id of the FORM tag (defaults to an auto-generated id).
   */

  /**
   * @cfg {Boolean} hideLabels
   * <p><tt>true</tt> to hide field labels by default (sets <tt>display:none</tt>). Defaults to
   * <tt>false</tt>.</p>
   * <p>Also see {@link Ext.Component}.<tt>{@link Ext.Component#hideLabel hideLabel}</tt>.
   */

  /**
   * @cfg {Number} labelPad
   * The default padding in pixels for field labels (defaults to <tt>5</tt>). <tt>labelPad</tt> only
   * applies if <tt>{@link #labelWidth}</tt> is also specified, otherwise it will be ignored.
   */

  /**
   * @cfg {String} labelSeparator
   * See {@link Ext.Component}.<tt>{@link Ext.Component#labelSeparator labelSeparator}</tt>
   */

  /**
   * @cfg {Number} labelWidth The width of labels in pixels. This property cascades to child containers
   * and can be overridden on any child container (e.g., a fieldset can specify a different <tt>labelWidth</tt>
   * for its fields) (defaults to <tt>100</tt>).
   */

  /**
   * @cfg {String} itemCls A css class to apply to the x-form-item of fields. This property cascades to child containers.
   */

  /**
   * @cfg {Array} buttons
   * An array of {@link Ext.Button}s or {@link Ext.Button} configs used to add buttons to the footer of this FormPanel.<br>
   * <p>Buttons in the footer of a FormPanel may be configured with the option <tt>formBind: true</tt>. This causes
   * the form's {@link #monitorValid valid state monitor task} to enable/disable those Buttons depending on
   * the form's valid/invalid state.</p>
   */

  /**
   * @cfg {Number} minButtonWidth Minimum width of all buttons in pixels (defaults to <tt>75</tt>).
   */
  minButtonWidth: 75,

  /**
   * @cfg {String} labelAlign The label alignment value used for the <tt>text-align</tt> specification
   * for the <b>container</b>. Valid values are <tt>"left</tt>", <tt>"top"</tt> or <tt>"right"</tt>
   * (defaults to <tt>"left"</tt>). This property cascades to child <b>containers</b> and can be
   * overridden on any child <b>container</b> (e.g., a fieldset can specify a different <tt>labelAlign</tt>
   * for its fields).
   */
  labelAlign: 'left',

  /**
   * @cfg {Boolean} monitorValid If <tt>true</tt>, the form monitors its valid state <b>client-side</b> and
   * regularly fires the {@link #clientvalidation} event passing that state.<br>
   * <p>When monitoring valid state, the FormPanel enables/disables any of its configured
   * {@link #buttons} which have been configured with <code>formBind: true</code> depending
   * on whether the {@link Ext.form.BasicForm#isValid form is valid} or not. Defaults to <tt>false</tt></p>
   */
  monitorValid: false,

  /**
   * @cfg {Number} monitorPoll The milliseconds to poll valid state, ignored if monitorValid is not true (defaults to 200)
   */
  monitorPoll: 200,

  /**
   * @cfg {String} layout Defaults to <tt>'form'</tt>.  Normally this configuration property should not be altered.
   * For additional details see {@link Ext.layout.FormLayout} and {@link Ext.Container#layout Ext.Container.layout}.
   */
  layout: 'form',
  // private
  initComponent: function initComponent() {
    this.form = this.createForm();
    Ext.FormPanel.superclass.initComponent.call(this);
    this.bodyCfg = {
      tag: 'form',
      cls: this.baseCls + '-body',
      method: this.method || 'POST',
      id: this.formId || Ext.id()
    };

    if (this.fileUpload) {
      this.bodyCfg.enctype = 'multipart/form-data';
    }

    this.initItems();
    this.addEvents(
    /**
     * @event clientvalidation
     * If the monitorValid config option is true, this event fires repetitively to notify of valid state
     * @param {Ext.form.FormPanel} this
     * @param {Boolean} valid true if the form has passed client-side validation
     */
    'clientvalidation');
    this.relayEvents(this.form, ['beforeaction', 'actionfailed', 'actioncomplete']);
  },
  // private
  createForm: function createForm() {
    var config = Ext.applyIf({
      listeners: {}
    }, this.initialConfig);
    return new Ext.form.BasicForm(null, config);
  },
  // private
  initFields: function initFields() {
    var f = this.form;
    var formPanel = this;

    var fn = function fn(c) {
      if (formPanel.isField(c)) {
        f.add(c);
      } else if (c.findBy && c != formPanel) {
        formPanel.applySettings(c); //each check required for check/radio groups.

        if (c.items && c.items.each) {
          c.items.each(fn, this);
        }
      }
    };

    this.items.each(fn, this);
  },
  // private
  applySettings: function applySettings(c) {
    var ct = c.ownerCt;
    Ext.applyIf(c, {
      labelAlign: ct.labelAlign,
      labelWidth: ct.labelWidth,
      itemCls: ct.itemCls
    });
  },
  // private
  getLayoutTarget: function getLayoutTarget() {
    return this.form.el;
  },

  /**
   * Provides access to the {@link Ext.form.BasicForm Form} which this Panel contains.
   * @return {Ext.form.BasicForm} The {@link Ext.form.BasicForm Form} which this Panel contains.
   */
  getForm: function getForm() {
    return this.form;
  },
  // private
  onRender: function onRender(ct, position) {
    this.initFields();
    Ext.FormPanel.superclass.onRender.call(this, ct, position);
    this.form.initEl(this.body);
  },
  // private
  beforeDestroy: function beforeDestroy() {
    this.stopMonitoring();
    /*
     * Don't move this behaviour to BasicForm because it can be used
     * on it's own.
     */

    Ext.destroy(this.form);
    this.form.items.clear();
    Ext.FormPanel.superclass.beforeDestroy.call(this);
  },
  // Determine if a Component is usable as a form Field.
  isField: function isField(c) {
    return !!c.setValue && !!c.getValue && !!c.markInvalid && !!c.clearInvalid;
  },
  // private
  initEvents: function initEvents() {
    Ext.FormPanel.superclass.initEvents.call(this); // Listeners are required here to catch bubbling events from children.

    this.on({
      scope: this,
      add: this.onAddEvent,
      remove: this.onRemoveEvent
    });

    if (this.monitorValid) {
      // initialize after render
      this.startMonitoring();
    }
  },
  // private
  onAdd: function onAdd(c) {
    Ext.FormPanel.superclass.onAdd.call(this, c);
    this.processAdd(c);
  },
  // private
  onAddEvent: function onAddEvent(ct, c) {
    if (ct !== this) {
      this.processAdd(c);
    }
  },
  // private
  processAdd: function processAdd(c) {
    // If a single form Field, add it
    if (this.isField(c)) {
      this.form.add(c); // If a Container, add any Fields it might contain
    } else if (c.findBy) {
      this.applySettings(c);
      this.form.add.apply(this.form, c.findBy(this.isField));
    }
  },
  // private
  onRemove: function onRemove(c) {
    Ext.FormPanel.superclass.onRemove.call(this, c);
    this.processRemove(c);
  },
  onRemoveEvent: function onRemoveEvent(ct, c) {
    if (ct !== this) {
      this.processRemove(c);
    }
  },
  // private
  processRemove: function processRemove(c) {
    // If a single form Field, remove it
    if (this.isField(c)) {
      this.form.remove(c); // If a Container, its already destroyed by the time it gets here.  Remove any references to destroyed fields.
    } else if (c.findBy) {
      var isDestroyed = function isDestroyed(o) {
        return !!o.isDestroyed;
      };

      this.form.items.filterBy(isDestroyed, this.form).each(this.form.remove, this.form);
    }
  },

  /**
   * Starts monitoring of the valid state of this form. Usually this is done by passing the config
   * option "monitorValid"
   */
  startMonitoring: function startMonitoring() {
    if (!this.validTask) {
      this.validTask = new Ext.util.TaskRunner();
      this.validTask.start({
        run: this.bindHandler,
        interval: this.monitorPoll || 200,
        scope: this
      });
    }
  },

  /**
   * Stops monitoring of the valid state of this form
   */
  stopMonitoring: function stopMonitoring() {
    if (this.validTask) {
      this.validTask.stopAll();
      this.validTask = null;
    }
  },

  /**
   * This is a proxy for the underlying BasicForm's {@link Ext.form.BasicForm#load} call.
   * @param {Object} options The options to pass to the action (see {@link Ext.form.BasicForm#doAction} for details)
   */
  load: function load() {
    this.form.load.apply(this.form, arguments);
  },
  // private
  onDisable: function onDisable() {
    Ext.FormPanel.superclass.onDisable.call(this);

    if (this.form) {
      this.form.items.each(function () {
        this.disable();
      });
    }
  },
  // private
  onEnable: function onEnable() {
    Ext.FormPanel.superclass.onEnable.call(this);

    if (this.form) {
      this.form.items.each(function () {
        this.enable();
      });
    }
  },
  // private
  bindHandler: function bindHandler() {
    var valid = true;
    this.form.items.each(function (f) {
      if (!f.isValid(true)) {
        valid = false;
        return false;
      }
    });

    if (this.fbar) {
      var fitems = this.fbar.items.items;

      for (var i = 0, len = fitems.length; i < len; i++) {
        var btn = fitems[i];

        if (btn.formBind === true && btn.disabled === valid) {
          btn.setDisabled(!valid);
        }
      }
    }

    this.fireEvent('clientvalidation', this, valid);
  }
});
Ext.reg('form', Ext.FormPanel);
Ext.form.FormPanel = Ext.FormPanel;

/***/ }),
/* 884 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.FieldSet
 * @extends Ext.Panel
 * Standard container used for grouping items within a {@link Ext.form.FormPanel form}.
 * <pre><code>
var form = new Ext.FormPanel({
    title: 'Simple Form with FieldSets',
    labelWidth: 75, // label settings here cascade unless overridden
    url: 'save-form.php',
    frame:true,
    bodyStyle:'padding:5px 5px 0',
    width: 700,
    renderTo: document.body,
    layout:'column', // arrange items in columns
    defaults: {      // defaults applied to items
        layout: 'form',
        border: false,
        bodyStyle: 'padding:4px'
    },
    items: [{
        // Fieldset in Column 1
        xtype:'fieldset',
        columnWidth: 0.5,
        title: 'Fieldset 1',
        collapsible: true,
        autoHeight:true,
        defaults: {
            anchor: '-20' // leave room for error icon
        },
        defaultType: 'textfield',
        items :[{
                fieldLabel: 'Field 1'
            }, {
                fieldLabel: 'Field 2'
            }, {
                fieldLabel: 'Field 3'
            }
        ]
    },{
        // Fieldset in Column 2 - Panel inside
        xtype:'fieldset',
        title: 'Show Panel', // title, header, or checkboxToggle creates fieldset header
        autoHeight:true,
        columnWidth: 0.5,
        checkboxToggle: true,
        collapsed: true, // fieldset initially collapsed
        layout:'anchor',
        items :[{
            xtype: 'panel',
            anchor: '100%',
            title: 'Panel inside a fieldset',
            frame: true,
            height: 100
        }]
    }]
});
 * </code></pre>
 * @constructor
 * @param {Object} config Configuration options
 * @xtype fieldset
 */
Ext.form.FieldSet = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Mixed} checkboxToggle <tt>true</tt> to render a checkbox into the fieldset frame just
   * in front of the legend to expand/collapse the fieldset when the checkbox is toggled. (defaults
   * to <tt>false</tt>).
   * <p>A {@link Ext.DomHelper DomHelper} element spec may also be specified to create the checkbox.
   * If <tt>true</tt> is specified, the default DomHelper config object used to create the element
   * is:</p><pre><code>
   * {tag: 'input', type: 'checkbox', name: this.checkboxName || this.id+'-checkbox'}
   * </code></pre>   
   */

  /**
   * @cfg {String} checkboxName The name to assign to the fieldset's checkbox if <tt>{@link #checkboxToggle} = true</tt>
   * (defaults to <tt>'[checkbox id]-checkbox'</tt>).
   */

  /**
   * @cfg {Boolean} collapsible
   * <tt>true</tt> to make the fieldset collapsible and have the expand/collapse toggle button automatically
   * rendered into the legend element, <tt>false</tt> to keep the fieldset statically sized with no collapse
   * button (defaults to <tt>false</tt>). Another option is to configure <tt>{@link #checkboxToggle}</tt>.
   */

  /**
   * @cfg {Number} labelWidth The width of labels. This property cascades to child containers.
   */

  /**
   * @cfg {String} itemCls A css class to apply to the <tt>x-form-item</tt> of fields (see 
   * {@link Ext.layout.FormLayout}.{@link Ext.layout.FormLayout#fieldTpl fieldTpl} for details).
   * This property cascades to child containers.
   */

  /**
   * @cfg {String} baseCls The base CSS class applied to the fieldset (defaults to <tt>'x-fieldset'</tt>).
   */
  baseCls: 'x-fieldset',

  /**
   * @cfg {String} layout The {@link Ext.Container#layout} to use inside the fieldset (defaults to <tt>'form'</tt>).
   */
  layout: 'form',

  /**
   * @cfg {Boolean} animCollapse
   * <tt>true</tt> to animate the transition when the panel is collapsed, <tt>false</tt> to skip the
   * animation (defaults to <tt>false</tt>).
   */
  animCollapse: false,
  // private
  onRender: function onRender(ct, position) {
    if (!this.el) {
      this.el = document.createElement('fieldset');
      this.el.id = this.id;

      if (this.title || this.header || this.checkboxToggle) {
        this.el.appendChild(document.createElement('legend')).className = this.baseCls + '-header';
      }
    }

    Ext.form.FieldSet.superclass.onRender.call(this, ct, position);

    if (this.checkboxToggle) {
      var o = typeof this.checkboxToggle == 'object' ? this.checkboxToggle : {
        tag: 'input',
        type: 'checkbox',
        name: this.checkboxName || this.id + '-checkbox'
      };
      this.checkbox = this.header.insertFirst(o);
      this.checkbox.dom.checked = !this.collapsed;
      this.mon(this.checkbox, 'click', this.onCheckClick, this);
    }
  },
  // private
  onCollapse: function onCollapse(doAnim, animArg) {
    if (this.checkbox) {
      this.checkbox.dom.checked = false;
    }

    Ext.form.FieldSet.superclass.onCollapse.call(this, doAnim, animArg);
  },
  // private
  onExpand: function onExpand(doAnim, animArg) {
    if (this.checkbox) {
      this.checkbox.dom.checked = true;
    }

    Ext.form.FieldSet.superclass.onExpand.call(this, doAnim, animArg);
  },

  /**
   * This function is called by the fieldset's checkbox when it is toggled (only applies when
   * checkboxToggle = true).  This method should never be called externally, but can be
   * overridden to provide custom behavior when the checkbox is toggled if needed.
   */
  onCheckClick: function onCheckClick() {
    this[this.checkbox.dom.checked ? 'expand' : 'collapse']();
  }
  /**
   * @cfg {String/Number} activeItem
   * @hide
   */

  /**
   * @cfg {Mixed} applyTo
   * @hide
   */

  /**
   * @cfg {Boolean} bodyBorder
   * @hide
   */

  /**
   * @cfg {Boolean} border
   * @hide
   */

  /**
   * @cfg {Boolean/Number} bufferResize
   * @hide
   */

  /**
   * @cfg {Boolean} collapseFirst
   * @hide
   */

  /**
   * @cfg {String} defaultType
   * @hide
   */

  /**
   * @cfg {String} disabledClass
   * @hide
   */

  /**
   * @cfg {String} elements
   * @hide
   */

  /**
   * @cfg {Boolean} floating
   * @hide
   */

  /**
   * @cfg {Boolean} footer
   * @hide
   */

  /**
   * @cfg {Boolean} frame
   * @hide
   */

  /**
   * @cfg {Boolean} header
   * @hide
   */

  /**
   * @cfg {Boolean} headerAsText
   * @hide
   */

  /**
   * @cfg {Boolean} hideCollapseTool
   * @hide
   */

  /**
   * @cfg {String} iconCls
   * @hide
   */

  /**
   * @cfg {Boolean/String} shadow
   * @hide
   */

  /**
   * @cfg {Number} shadowOffset
   * @hide
   */

  /**
   * @cfg {Boolean} shim
   * @hide
   */

  /**
   * @cfg {Object/Array} tbar
   * @hide
   */

  /**
   * @cfg {Array} tools
   * @hide
   */

  /**
   * @cfg {Ext.Template/Ext.XTemplate} toolTemplate
   * @hide
   */

  /**
   * @cfg {String} xtype
   * @hide
   */

  /**
   * @property header
   * @hide
   */

  /**
   * @property footer
   * @hide
   */

  /**
   * @method focus
   * @hide
   */

  /**
   * @method getBottomToolbar
   * @hide
   */

  /**
   * @method getTopToolbar
   * @hide
   */

  /**
   * @method setIconClass
   * @hide
   */

  /**
   * @event activate
   * @hide
   */

  /**
   * @event beforeclose
   * @hide
   */

  /**
   * @event bodyresize
   * @hide
   */

  /**
   * @event close
   * @hide
   */

  /**
   * @event deactivate
   * @hide
   */

});
Ext.reg('fieldset', Ext.form.FieldSet);

/***/ }),
/* 885 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.HtmlEditor
 * @extends Ext.form.Field
 * Provides a lightweight HTML Editor component. Some toolbar features are not supported by Safari and will be
 * automatically hidden when needed.  These are noted in the config options where appropriate.
 * <br><br>The editor's toolbar buttons have tooltips defined in the {@link #buttonTips} property, but they are not
 * enabled by default unless the global {@link Ext.QuickTips} singleton is {@link Ext.QuickTips#init initialized}.
 * <br><br><b>Note: The focus/blur and validation marking functionality inherited from Ext.form.Field is NOT
 * supported by this editor.</b>
 * <br><br>An Editor is a sensitive component that can't be used in all spots standard fields can be used. Putting an Editor within
 * any element that has display set to 'none' can cause problems in Safari and Firefox due to their default iframe reloading bugs.
 * <br><br>Example usage:
 * <pre><code>
// Simple example rendered with default options:
Ext.QuickTips.init();  // enable tooltips
new Ext.form.HtmlEditor({
    renderTo: Ext.getBody(),
    width: 800,
    height: 300
});

// Passed via xtype into a container and with custom options:
Ext.QuickTips.init();  // enable tooltips
new Ext.Panel({
    title: 'HTML Editor',
    renderTo: Ext.getBody(),
    width: 600,
    height: 300,
    frame: true,
    layout: 'fit',
    items: {
        xtype: 'htmleditor',
        enableColors: false,
        enableAlignments: false
    }
});
</code></pre>
 * @constructor
 * Create a new HtmlEditor
 * @param {Object} config
 * @xtype htmleditor
 */
Ext.form.HtmlEditor = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {Boolean} enableFormat Enable the bold, italic and underline buttons (defaults to true)
   */
  enableFormat: true,

  /**
   * @cfg {Boolean} enableFontSize Enable the increase/decrease font size buttons (defaults to true)
   */
  enableFontSize: true,

  /**
   * @cfg {Boolean} enableColors Enable the fore/highlight color buttons (defaults to true)
   */
  enableColors: true,

  /**
   * @cfg {Boolean} enableAlignments Enable the left, center, right alignment buttons (defaults to true)
   */
  enableAlignments: true,

  /**
   * @cfg {Boolean} enableLists Enable the bullet and numbered list buttons. Not available in Safari. (defaults to true)
   */
  enableLists: true,

  /**
   * @cfg {Boolean} enableSourceEdit Enable the switch to source edit button. Not available in Safari. (defaults to true)
   */
  enableSourceEdit: true,

  /**
   * @cfg {Boolean} enableLinks Enable the create link button. Not available in Safari. (defaults to true)
   */
  enableLinks: true,

  /**
   * @cfg {Boolean} enableFont Enable font selection. Not available in Safari. (defaults to true)
   */
  enableFont: true,

  /**
   * @cfg {String} createLinkText The default text for the create link prompt
   */
  createLinkText: 'Please enter the URL for the link:',

  /**
   * @cfg {String} defaultLinkValue The default value for the create link prompt (defaults to http:/ /)
   */
  defaultLinkValue: 'http:/' + '/',

  /**
   * @cfg {Array} fontFamilies An array of available font families
   */
  fontFamilies: ['Arial', 'Courier New', 'Tahoma', 'Times New Roman', 'Verdana'],
  defaultFont: 'tahoma',

  /**
   * @cfg {String} defaultValue A default value to be put into the editor to resolve focus issues (defaults to &#160; (Non-breaking space) in Opera and IE6, &#8203; (Zero-width space) in all other browsers).
   */
  defaultValue: Ext.isOpera || Ext.isIE6 ? '&#160;' : '&#8203;',
  // private properties
  actionMode: 'wrap',
  validationEvent: false,
  deferHeight: true,
  initialized: false,
  activated: false,
  sourceEditMode: false,
  onFocus: Ext.emptyFn,
  iframePad: 3,
  hideMode: 'offsets',
  defaultAutoCreate: {
    tag: "textarea",
    style: "width:500px;height:300px;",
    autocomplete: "off"
  },
  // private
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event initialize
     * Fires when the editor is fully initialized (including the iframe)
     * @param {HtmlEditor} this
     */
    'initialize',
    /**
     * @event activate
     * Fires when the editor is first receives the focus. Any insertion must wait
     * until after this event.
     * @param {HtmlEditor} this
     */
    'activate',
    /**
    * @event beforesync
    * Fires before the textarea is updated with content from the editor iframe. Return false
    * to cancel the sync.
    * @param {HtmlEditor} this
    * @param {String} html
    */
    'beforesync',
    /**
    * @event beforepush
    * Fires before the iframe editor is updated with content from the textarea. Return false
    * to cancel the push.
    * @param {HtmlEditor} this
    * @param {String} html
    */
    'beforepush',
    /**
    * @event sync
    * Fires when the textarea is updated with content from the editor iframe.
    * @param {HtmlEditor} this
    * @param {String} html
    */
    'sync',
    /**
    * @event push
    * Fires when the iframe editor is updated with content from the textarea.
    * @param {HtmlEditor} this
    * @param {String} html
    */
    'push',
    /**
    * @event editmodechange
    * Fires when the editor switches edit modes
    * @param {HtmlEditor} this
    * @param {Boolean} sourceEdit True if source edit, false if standard editing.
    */
    'editmodechange');
  },
  // private
  createFontOptions: function createFontOptions() {
    var buf = [],
        fs = this.fontFamilies,
        ff,
        lc;

    for (var i = 0, len = fs.length; i < len; i++) {
      ff = fs[i];
      lc = ff.toLowerCase();
      buf.push('<option value="', lc, '" style="font-family:', ff, ';"', this.defaultFont == lc ? ' selected="true">' : '>', ff, '</option>');
    }

    return buf.join('');
  },

  /*
   * Protected method that will not generally be called directly. It
   * is called when the editor creates its toolbar. Override this method if you need to
   * add custom toolbar buttons.
   * @param {HtmlEditor} editor
   */
  createToolbar: function createToolbar(editor) {
    var items = [];
    var tipsEnabled = Ext.QuickTips && Ext.QuickTips.isEnabled();

    function btn(id, toggle, handler) {
      return {
        itemId: id,
        cls: 'x-btn-icon',
        iconCls: 'x-edit-' + id,
        enableToggle: toggle !== false,
        scope: editor,
        handler: handler || editor.relayBtnCmd,
        clickEvent: 'mousedown',
        tooltip: tipsEnabled ? _.get(editor, "buttonTips[".concat(id, "]"), undefined) : undefined,
        overflowText: _.get(editor, "buttonTips[".concat(id, "].title"), undefined),
        tabIndex: -1
      };
    }

    if (this.enableFont && !Ext.isSafari2) {
      var fontSelectItem = new Ext.Toolbar.Item({
        autoEl: {
          tag: 'select',
          cls: 'x-font-select',
          html: this.createFontOptions()
        }
      });
      items.push(fontSelectItem, '-');
    }

    if (this.enableFormat) {
      items.push(btn('bold'), btn('italic'), btn('underline'), btn('strikeThrough'), btn('formatblockPre', false, this.toggleCodeBlock));
    }

    if (this.enableFontSize) {
      items.push('-', btn('increasefontsize', false, this.adjustFont), btn('decreasefontsize', false, this.adjustFont));
    }

    if (this.enableColors) {
      items.push('-', {
        itemId: 'forecolor',
        cls: 'x-btn-icon',
        iconCls: 'x-edit-forecolor',
        clickEvent: 'mousedown',
        tooltip: tipsEnabled ? editor.buttonTips.forecolor || undefined : undefined,
        tabIndex: -1,
        menu: new Ext.menu.ColorMenu({
          allowReselect: true,
          focus: Ext.emptyFn,
          value: '000000',
          plain: true,
          listeners: {
            scope: this,
            select: function select(cp, color) {
              this.execCmd('forecolor', Ext.isWebKit || Ext.isIE ? '#' + color : color);
              this.deferFocus();
            }
          },
          clickEvent: 'mousedown'
        })
      }, {
        itemId: 'backcolor',
        cls: 'x-btn-icon',
        iconCls: 'x-edit-backcolor',
        clickEvent: 'mousedown',
        tooltip: tipsEnabled ? editor.buttonTips.backcolor || undefined : undefined,
        tabIndex: -1,
        menu: new Ext.menu.ColorMenu({
          focus: Ext.emptyFn,
          value: 'FFFFFF',
          plain: true,
          allowReselect: true,
          listeners: {
            scope: this,
            select: function select(cp, color) {
              if (Ext.isGecko) {
                this.execCmd('useCSS', false);
                this.execCmd('hilitecolor', color);
                this.execCmd('useCSS', true);
                this.deferFocus();
              } else {
                this.execCmd(Ext.isOpera ? 'hilitecolor' : 'backcolor', Ext.isWebKit || Ext.isIE ? '#' + color : color);
                this.deferFocus();
              }
            }
          },
          clickEvent: 'mousedown'
        })
      });
    }

    if (this.enableAlignments) {
      items.push('-', btn('justifyleft'), btn('justifycenter'), btn('justifyright'));
    }

    if (!Ext.isSafari2) {
      if (this.enableLinks) {
        items.push('-', btn('createlink', false, this.createLink));
      }

      if (this.enableLists) {
        items.push('-', btn('insertorderedlist'), btn('insertunorderedlist'));
      }

      if (this.enableSourceEdit) {
        items.push('-', btn('sourceedit', true, function (btn) {
          this.toggleSourceEdit(!this.sourceEditMode);
        }));
      }
    } // build the toolbar


    var tb = new Ext.Toolbar({
      renderTo: this.wrap.dom.firstChild,
      items: items
    });

    if (fontSelectItem) {
      this.fontSelect = fontSelectItem.el;
      this.mon(this.fontSelect, 'change', function () {
        var font = this.fontSelect.dom.value;
        this.relayCmd('fontname', font);
        this.deferFocus();
      }, this);
    } // stop form submits


    this.mon(tb.el, 'click', function (e) {
      e.preventDefault();
    });
    this.tb = tb;
  },
  onDisable: function onDisable() {
    this.wrap.mask();
    Ext.form.HtmlEditor.superclass.onDisable.call(this);
  },
  onEnable: function onEnable() {
    this.wrap.unmask();
    Ext.form.HtmlEditor.superclass.onEnable.call(this);
  },
  setReadOnly: function setReadOnly(readOnly) {
    Ext.form.HtmlEditor.superclass.setReadOnly.call(this, readOnly);

    if (this.initialized) {
      this.setDesignMode(!readOnly);
      var bd = this.getEditorBody();

      if (bd) {
        bd.style.cursor = this.readOnly ? 'default' : 'text';
      }

      this.disableItems(readOnly);
    }
  },

  /**
   * Protected method that will not generally be called directly. It
   * is called when the editor initializes the iframe with HTML contents. Override this method if you
   * want to change the initialization markup of the iframe (e.g. to add stylesheets).
   *
   * Note: IE8-Standards has unwanted scroller behavior, so the default meta tag forces IE7 compatibility
   */
  getDocMarkup: function getDocMarkup() {
    return '<html><head><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /><style type="text/css">body{border:0;margin:0;padding:3px;height:98%;cursor:text;}</style></head><body></body></html>';
  },
  // private
  getEditorBody: function getEditorBody() {
    var doc = this.getDoc();
    return doc.body || doc.documentElement;
  },
  // private
  getDoc: function getDoc() {
    return Ext.isIE ? this.getWin().document : this.iframe.contentDocument || this.getWin().document;
  },
  // private
  getWin: function getWin() {
    return Ext.isIE ? this.iframe.contentWindow : window.frames[this.iframe.name];
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.form.HtmlEditor.superclass.onRender.call(this, ct, position);
    this.el.dom.style.border = '0 none';
    this.el.dom.setAttribute('tabIndex', -1);
    this.el.addClass('x-hidden');

    if (Ext.isIE) {
      // fix IE 1px bogus margin
      this.el.applyStyles('margin-top:-1px;margin-bottom:-1px;');
    }

    this.wrap = this.el.wrap({
      cls: 'x-html-editor-wrap',
      cn: {
        cls: 'x-html-editor-tb'
      }
    });
    this.createToolbar(this);
    this.disableItems(true);
    this.tb.doLayout();
    this.createIFrame();

    if (!this.width) {
      var sz = this.el.getSize();
      this.setSize(sz.width, this.height || sz.height);
    }

    this.resizeEl = this.positionEl = this.wrap;
  },
  createIFrame: function createIFrame() {
    var iframe = document.createElement('iframe');
    iframe.name = Ext.id();
    iframe.frameBorder = '0';
    iframe.style.overflow = 'auto';
    this.wrap.dom.appendChild(iframe);
    this.iframe = iframe;
    this.monitorTask = Ext.TaskMgr.start({
      run: this.checkDesignMode,
      scope: this,
      interval: 100
    });
  },
  initFrame: function initFrame() {
    Ext.TaskMgr.stop(this.monitorTask);
    var doc = this.getDoc();
    this.win = this.getWin();
    doc.open();
    doc.write(this.getDocMarkup());
    doc.close();
    var task = {
      // must defer to wait for browser to be ready
      run: function run() {
        var doc = this.getDoc();

        if (doc.body || doc.readyState == 'complete') {
          Ext.TaskMgr.stop(task);
          this.setDesignMode(true);
          this.initEditor.defer(10, this);
        }
      },
      interval: 10,
      duration: 10000,
      scope: this
    };
    Ext.TaskMgr.start(task);
  },
  checkDesignMode: function checkDesignMode() {
    if (this.wrap && this.wrap.dom.offsetWidth) {
      var doc = this.getDoc();

      if (!doc) {
        return;
      }

      if (!doc.editorInitialized || this.getDesignMode() != 'on') {
        this.initFrame();
      }
    }
  },

  /* private
   * set current design mode. To enable, mode can be true or 'on', off otherwise
   */
  setDesignMode: function setDesignMode(mode) {
    var doc;

    if (doc = this.getDoc()) {
      if (this.readOnly) {
        mode = false;
      }

      doc.designMode = /on|true/i.test(String(mode).toLowerCase()) ? 'on' : 'off';
    }
  },
  // private
  getDesignMode: function getDesignMode() {
    var doc = this.getDoc();

    if (!doc) {
      return '';
    }

    return String(doc.designMode).toLowerCase();
  },
  disableItems: function disableItems(disabled) {
    if (this.fontSelect) {
      this.fontSelect.dom.disabled = disabled;
    }

    this.tb.items.each(function (item) {
      if (item.getItemId() != 'sourceedit') {
        item.setDisabled(disabled);
      }
    });
  },
  // private
  onResize: function onResize(w, h) {
    Ext.form.HtmlEditor.superclass.onResize.apply(this, arguments);

    if (this.el && this.iframe) {
      if (Ext.isNumber(w)) {
        var aw = w - this.wrap.getFrameWidth('lr');
        this.el.setWidth(aw);
        this.tb.setWidth(aw);
        this.iframe.style.width = Math.max(aw, 0) + 'px';
      }

      if (Ext.isNumber(h)) {
        var ah = h - this.wrap.getFrameWidth('tb') - this.tb.el.getHeight();
        this.el.setHeight(ah);
        this.iframe.style.height = Math.max(ah, 0) + 'px';
        var bd = this.getEditorBody();

        if (bd) {
          bd.style.height = Math.max(ah - this.iframePad * 2, 0) + 'px';
        }
      }
    }
  },

  /**
   * Toggles the editor between standard and source edit mode.
   * @param {Boolean} sourceEdit (optional) True for source edit, false for standard
   */
  toggleSourceEdit: function toggleSourceEdit(sourceEditMode) {
    if (sourceEditMode === undefined) {
      sourceEditMode = !this.sourceEditMode;
    }

    this.sourceEditMode = sourceEditMode === true;
    var btn = this.tb.getComponent('sourceedit');

    if (btn.pressed !== this.sourceEditMode) {
      btn.toggle(this.sourceEditMode);

      if (!btn.xtbHidden) {
        return;
      }
    }

    if (this.sourceEditMode) {
      this.disableItems(true);
      this.syncValue();
      this.iframe.className = 'x-hidden';
      this.el.removeClass('x-hidden');
      this.el.dom.removeAttribute('tabIndex');
      this.el.focus();
    } else {
      if (this.initialized) {
        this.disableItems(this.readOnly);
      }

      this.pushValue();
      this.iframe.className = '';
      this.el.addClass('x-hidden');
      this.el.dom.setAttribute('tabIndex', -1);
      this.deferFocus();
    }

    var lastSize = this.lastSize;

    if (lastSize) {
      delete this.lastSize;
      this.setSize(lastSize);
    }

    this.fireEvent('editmodechange', this, this.sourceEditMode);
  },
  // private used internally
  createLink: function createLink() {
    var url = prompt(this.createLinkText, this.defaultLinkValue);

    if (url && url != 'http:/' + '/') {
      this.relayCmd('createlink', url);
    }
  },
  // private
  initEvents: function initEvents() {
    this.originalValue = this.getValue();
  },

  /**
   * Overridden and disabled. The editor element does not support standard valid/invalid marking. @hide
   * @method
   */
  markInvalid: Ext.emptyFn,

  /**
   * Overridden and disabled. The editor element does not support standard valid/invalid marking. @hide
   * @method
   */
  clearInvalid: Ext.emptyFn,
  // docs inherit from Field
  setValue: function setValue(v) {
    Ext.form.HtmlEditor.superclass.setValue.call(this, v);
    this.pushValue();
    return this;
  },

  /**
   * Protected method that will not generally be called directly. If you need/want
   * custom HTML cleanup, this is the method you should override.
   * @param {String} html The HTML to be cleaned
   * @return {String} The cleaned HTML
   */
  cleanHtml: function cleanHtml(html) {
    html = String(html);

    if (Ext.isWebKit) {
      // strip safari nonsense
      html = html.replace(/\sclass="(?:Apple-style-span|khtml-block-placeholder)"/gi, '');
    }
    /*
     * Neat little hack. Strips out all the non-digit characters from the default
     * value and compares it to the character code of the first character in the string
     * because it can cause encoding issues when posted to the server.
     */


    if (html.charCodeAt(0) == this.defaultValue.replace(/\D/g, '')) {
      html = html.substring(1);
    }

    return html;
  },

  /**
   * Protected method that will not generally be called directly. Syncs the contents
   * of the editor iframe with the textarea.
   */
  syncValue: function syncValue() {
    if (this.initialized) {
      var bd = this.getEditorBody();
      var html = bd.innerHTML;

      if (Ext.isWebKit) {
        var bs = bd.getAttribute('style'); // Safari puts text-align styles on the body element!

        var m = bs.match(/text-align:(.*?);/i);

        if (m && m[1]) {
          html = '<div style="' + m[0] + '">' + html + '</div>';
        }
      }

      html = this.cleanHtml(html);

      if (this.fireEvent('beforesync', this, html) !== false) {
        this.el.dom.value = html;
        this.fireEvent('sync', this, html);
      }
    }
  },
  //docs inherit from Field
  getValue: function getValue() {
    this[this.sourceEditMode ? 'pushValue' : 'syncValue']();
    return Ext.form.HtmlEditor.superclass.getValue.call(this);
  },

  /**
   * Protected method that will not generally be called directly. Pushes the value of the textarea
   * into the iframe editor.
   */
  pushValue: function pushValue() {
    if (this.initialized) {
      var v = this.el.dom.value;

      if (!this.activated && v.length < 1) {
        v = this.defaultValue;
      }

      if (this.fireEvent('beforepush', this, v) !== false) {
        this.getEditorBody().innerHTML = v;

        if (Ext.isGecko) {
          // Gecko hack, see: https://bugzilla.mozilla.org/show_bug.cgi?id=232791#c8
          this.setDesignMode(false); //toggle off first
        }

        this.setDesignMode(true);
        this.fireEvent('push', this, v);
      }
    }
  },
  // private
  deferFocus: function deferFocus() {
    this.focus.defer(10, this);
  },
  // docs inherit from Field
  focus: function focus() {
    if (this.win && !this.sourceEditMode) {
      this.win.focus();
    } else {
      this.el.focus();
    }
  },
  // private
  initEditor: function initEditor() {
    //Destroying the component during/before initEditor can cause issues.
    try {
      var dbody = this.getEditorBody(),
          ss = this.el.getStyles('font-size', 'font-family', 'background-image', 'background-repeat'),
          doc,
          fn;
      ss['background-attachment'] = 'fixed'; // w3c

      dbody.bgProperties = 'fixed'; // ie

      if (this.enableFont && !Ext.isSafari2 && this.defaultFont) {
        ss['font-family'] = this.defaultFont;
      }

      Ext.DomHelper.applyStyles(dbody, ss);
      doc = this.getDoc();

      if (doc) {
        try {
          Ext.EventManager.removeAll(doc);
        } catch (e) {}
      }
      /*
       * We need to use createDelegate here, because when using buffer, the delayed task is added
       * as a property to the function. When the listener is removed, the task is deleted from the function.
       * Since onEditorEvent is shared on the prototype, if we have multiple html editors, the first time one of the editors
       * is destroyed, it causes the fn to be deleted from the prototype, which causes errors. Essentially, we're just anonymizing the function.
       */


      fn = this.onEditorEvent.createDelegate(this);
      Ext.EventManager.on(doc, {
        mousedown: fn,
        dblclick: fn,
        click: fn,
        keyup: fn,
        buffer: 100
      });

      if (Ext.isGecko) {
        Ext.EventManager.on(doc, 'keypress', this.applyCommand, this);
      }

      if (Ext.isIE || Ext.isWebKit || Ext.isOpera) {
        Ext.EventManager.on(doc, 'keydown', this.fixKeys, this);
      }

      doc.editorInitialized = true;
      this.initialized = true;
      this.pushValue();
      this.setReadOnly(this.readOnly);
      this.fireEvent('initialize', this);
    } catch (e) {}
  },
  // private
  onDestroy: function onDestroy() {
    if (this.monitorTask) {
      Ext.TaskMgr.stop(this.monitorTask);
    }

    if (this.rendered) {
      Ext.destroy(this.tb);
      var doc = this.getDoc();

      if (doc) {
        try {
          Ext.EventManager.removeAll(doc);

          for (var prop in doc) {
            delete doc[prop];
          }
        } catch (e) {}
      }

      if (this.wrap) {
        this.wrap.dom.innerHTML = '';
        this.wrap.remove();
      }
    }

    if (this.el) {
      this.el.removeAllListeners();
      this.el.remove();
    }

    this.purgeListeners();
  },
  // private
  onFirstFocus: function onFirstFocus() {
    this.activated = true;
    this.disableItems(this.readOnly);

    if (Ext.isGecko) {
      // prevent silly gecko errors
      this.win.focus();
      var s = this.win.getSelection();

      if (!s.focusNode || s.focusNode.nodeType != 3) {
        var r = s.getRangeAt(0);
        r.selectNodeContents(this.getEditorBody());
        r.collapse(true);
        this.deferFocus();
      }

      try {
        this.execCmd('useCSS', true);
        this.execCmd('styleWithCSS', false);
      } catch (e) {}
    }

    this.fireEvent('activate', this);
  },
  // private
  adjustFont: function adjustFont(btn) {
    var adjust = btn.getItemId() == 'increasefontsize' ? 1 : -1,
        doc = this.getDoc(),
        v = parseInt(doc.queryCommandValue('FontSize') || 2, 10);
    this.execCmd('FontSize', Math.max(1, v + adjust));
  },
  // private
  toggleCodeBlock: function toggleCodeBlock(btn) {
    let doc = this.getDoc();

    if (doc.queryCommandValue('formatblock') === 'pre') {
      let selection = this.getWin().getSelection();

      _.each(doc.querySelectorAll('pre'), function (node) {
        if (selection.containsNode(node, true)) {
          node.after(document.createElement('br'));
          node.replaceWith(node.textContent);
        }
      });
    } else {
      this.execCmd('formatblock', 'pre');
    }
  },
  // private
  onEditorEvent: function onEditorEvent(e) {
    this.updateToolbar();
  },

  /**
   * Protected method that will not generally be called directly. It triggers
   * a toolbar update by reading the markup state of the current selection in the editor.
   */
  updateToolbar: function updateToolbar() {
    if (this.readOnly) {
      return;
    }

    if (!this.activated) {
      this.onFirstFocus();
      return;
    }

    var btns = this.tb.items.map,
        doc = this.getDoc();

    if (this.enableFont && !Ext.isSafari2) {
      var name = (doc.queryCommandValue('FontName') || this.defaultFont).toLowerCase().replace(/"/g, '');

      if (name != this.fontSelect.dom.value) {
        this.fontSelect.dom.value = name;
      }
    }

    if (this.enableFormat) {
      btns.bold.toggle(doc.queryCommandState('bold'));
      btns.italic.toggle(doc.queryCommandState('italic'));
      btns.underline.toggle(doc.queryCommandState('underline'));
      btns.strikeThrough.toggle(doc.queryCommandState('strikeThrough'));
      btns.formatblockPre.toggle(doc.queryCommandValue('formatblock') === 'pre');
    }

    if (this.enableAlignments) {
      btns.justifyleft.toggle(doc.queryCommandState('justifyleft'));
      btns.justifycenter.toggle(doc.queryCommandState('justifycenter'));
      btns.justifyright.toggle(doc.queryCommandState('justifyright'));
    }

    if (!Ext.isSafari2 && this.enableLists) {
      btns.insertorderedlist.toggle(doc.queryCommandState('insertorderedlist'));
      btns.insertunorderedlist.toggle(doc.queryCommandState('insertunorderedlist'));
    }

    Ext.menu.MenuMgr.hideAll();
    this.syncValue();
  },
  // private
  relayBtnCmd: function relayBtnCmd(btn) {
    this.relayCmd(btn.getItemId());
  },

  /**
   * Executes a Midas editor command on the editor document and performs necessary focus and
   * toolbar updates. <b>This should only be called after the editor is initialized.</b>
   * @param {String} cmd The Midas command
   * @param {String/Boolean} value (optional) The value to pass to the command (defaults to null)
   */
  relayCmd: function relayCmd(cmd, value) {
    (function () {
      this.focus();
      this.execCmd(cmd, value);
      this.updateToolbar();
    }).defer(10, this);
  },

  /**
   * Executes a Midas editor command directly on the editor document.
   * For visual commands, you should use {@link #relayCmd} instead.
   * <b>This should only be called after the editor is initialized.</b>
   * @param {String} cmd The Midas command
   * @param {String/Boolean} value (optional) The value to pass to the command (defaults to null)
   */
  execCmd: function execCmd(cmd, value) {
    var doc = this.getDoc();
    doc.execCommand(cmd, false, value === undefined ? null : value);
    this.syncValue();
  },
  // private
  applyCommand: function applyCommand(e) {
    if (e.ctrlKey) {
      var c = e.getCharCode(),
          cmd;

      if (c > 0) {
        c = String.fromCharCode(c);

        switch (c) {
          case 'b':
            cmd = 'bold';
            break;

          case 'i':
            cmd = 'italic';
            break;

          case 'u':
            cmd = 'underline';
            break;

          case 'd':
            cmd = 'strikeThrough';
            break;
        }

        if (cmd) {
          this.win.focus();
          this.execCmd(cmd);
          this.deferFocus();
          e.preventDefault();
        }
      }
    }
  },

  /**
   * Inserts the passed text at the current cursor position. Note: the editor must be initialized and activated
   * to insert text.
   * @param {String} text
   */
  insertAtCursor: function insertAtCursor(text) {
    if (!this.activated) {
      return;
    }

    if (Ext.isIE) {
      this.win.focus();
      var doc = this.getDoc(),
          r = doc.selection.createRange();

      if (r) {
        r.pasteHTML(text);
        this.syncValue();
        this.deferFocus();
      }
    } else {
      this.win.focus();
      this.execCmd('InsertHTML', text);
      this.deferFocus();
    }
  },
  // private
  fixKeys: function () {
    // load time branching for fastest keydown performance
    if (Ext.isIE) {
      return function (e) {
        var k = e.getKey(),
            doc = this.getDoc(),
            r;

        if (k == e.TAB) {
          e.stopEvent();
          r = doc.selection.createRange();

          if (r) {
            r.collapse(true);
            r.pasteHTML('&nbsp;&nbsp;&nbsp;&nbsp;');
            this.deferFocus();
          }
        } else if (k == e.ENTER) {
          r = doc.selection.createRange();

          if (r) {
            var target = r.parentElement();

            if (!target || target.tagName.toLowerCase() != 'li') {
              e.stopEvent();
              r.pasteHTML('<br />');
              r.collapse(false);
              r.select();
            }
          }
        }
      };
    } else if (Ext.isOpera) {
      return function (e) {
        var k = e.getKey();

        if (k == e.TAB) {
          e.stopEvent();
          this.win.focus();
          this.execCmd('InsertHTML', '&nbsp;&nbsp;&nbsp;&nbsp;');
          this.deferFocus();
        }
      };
    } else if (Ext.isWebKit) {
      return function (e) {
        var k = e.getKey();

        if (k == e.TAB) {
          e.stopEvent();
          this.execCmd('InsertText', '\t');
          this.deferFocus();
        } else if (k == e.ENTER) {
          e.stopEvent();
          this.execCmd('InsertHtml', '<br /><br />');
          this.deferFocus();
        }
      };
    }
  }(),

  /**
   * Returns the editor's toolbar. <b>This is only available after the editor has been rendered.</b>
   * @return {Ext.Toolbar}
   */
  getToolbar: function getToolbar() {
    return this.tb;
  },

  /**
   * Object collection of toolbar tooltips for the buttons in the editor. The key
   * is the command id associated with that button and the value is a valid QuickTips object.
   * For example:
  <pre><code>
  {
  bold : {
      title: 'Bold (Ctrl+B)',
      text: 'Make the selected text bold.',
      cls: 'x-html-editor-tip'
  },
  italic : {
      title: 'Italic (Ctrl+I)',
      text: 'Make the selected text italic.',
      cls: 'x-html-editor-tip'
  },
  ...
  </code></pre>
  * @type Object
   */
  buttonTips: {
    bold: {
      title: 'Bold (Ctrl+B)',
      text: 'Make the selected text bold.',
      cls: 'x-html-editor-tip'
    },
    italic: {
      title: 'Italic (Ctrl+I)',
      text: 'Make the selected text italic.',
      cls: 'x-html-editor-tip'
    },
    underline: {
      title: 'Underline (Ctrl+U)',
      text: 'Underline the selected text.',
      cls: 'x-html-editor-tip'
    },
    strikeThrough: {
      title: 'Strike out',
      text: 'Strike out the selected text.',
      cls: 'x-html-editor-tip'
    },
    increasefontsize: {
      title: 'Grow Text',
      text: 'Increase the font size.',
      cls: 'x-html-editor-tip'
    },
    decreasefontsize: {
      title: 'Shrink Text',
      text: 'Decrease the font size.',
      cls: 'x-html-editor-tip'
    },
    backcolor: {
      title: 'Text Highlight Color',
      text: 'Change the background color of the selected text.',
      cls: 'x-html-editor-tip'
    },
    forecolor: {
      title: 'Font Color',
      text: 'Change the color of the selected text.',
      cls: 'x-html-editor-tip'
    },
    justifyleft: {
      title: 'Align Text Left',
      text: 'Align text to the left.',
      cls: 'x-html-editor-tip'
    },
    justifycenter: {
      title: 'Center Text',
      text: 'Center text in the editor.',
      cls: 'x-html-editor-tip'
    },
    justifyright: {
      title: 'Align Text Right',
      text: 'Align text to the right.',
      cls: 'x-html-editor-tip'
    },
    insertunorderedlist: {
      title: 'Bullet List',
      text: 'Start a bulleted list.',
      cls: 'x-html-editor-tip'
    },
    insertorderedlist: {
      title: 'Numbered List',
      text: 'Start a numbered list.',
      cls: 'x-html-editor-tip'
    },
    createlink: {
      title: 'Hyperlink',
      text: 'Make the selected text a hyperlink.',
      cls: 'x-html-editor-tip'
    },
    formatblockPre: {
      title: 'Code block',
      text: 'Insert pre-formatted code block',
      cls: 'x-html-editor-tip'
    },
    sourceedit: {
      title: 'Source Edit',
      text: 'Switch to source editing mode.',
      cls: 'x-html-editor-tip'
    }
  } // hide stuff that is not compatible

  /**
   * @event blur
   * @hide
   */

  /**
   * @event change
   * @hide
   */

  /**
   * @event focus
   * @hide
   */

  /**
   * @event specialkey
   * @hide
   */

  /**
   * @cfg {String} fieldClass @hide
   */

  /**
   * @cfg {String} focusClass @hide
   */

  /**
   * @cfg {String} autoCreate @hide
   */

  /**
   * @cfg {String} inputType @hide
   */

  /**
   * @cfg {String} invalidClass @hide
   */

  /**
   * @cfg {String} invalidText @hide
   */

  /**
   * @cfg {String} msgFx @hide
   */

  /**
   * @cfg {String} validateOnBlur @hide
   */

  /**
   * @cfg {Boolean} allowDomMove  @hide
   */

  /**
   * @cfg {String} applyTo @hide
   */

  /**
   * @cfg {String} autoHeight  @hide
   */

  /**
   * @cfg {String} autoWidth  @hide
   */

  /**
   * @cfg {String} cls  @hide
   */

  /**
   * @cfg {String} disabled  @hide
   */

  /**
   * @cfg {String} disabledClass  @hide
   */

  /**
   * @cfg {String} msgTarget  @hide
   */

  /**
   * @cfg {String} readOnly  @hide
   */

  /**
   * @cfg {String} style  @hide
   */

  /**
   * @cfg {String} validationDelay  @hide
   */

  /**
   * @cfg {String} validationEvent  @hide
   */

  /**
   * @cfg {String} tabIndex  @hide
   */

  /**
   * @property disabled
   * @hide
   */

  /**
   * @method applyToMarkup
   * @hide
   */

  /**
   * @method disable
   * @hide
   */

  /**
   * @method enable
   * @hide
   */

  /**
   * @method validate
   * @hide
   */

  /**
   * @event valid
   * @hide
   */

  /**
   * @method setDisabled
   * @hide
   */

  /**
   * @cfg keys
   * @hide
   */

});
Ext.reg('htmleditor', Ext.form.HtmlEditor);

/***/ }),
/* 886 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.TimeField
 * @extends Ext.form.ComboBox
 * Provides a time input field with a time dropdown and automatic time validation.  Example usage:
 * <pre><code>
new Ext.form.TimeField({
    minValue: '9:00 AM',
    maxValue: '6:00 PM',
    increment: 30
});
</code></pre>
 * @constructor
 * Create a new TimeField
 * @param {Object} config
 * @xtype timefield
 */
Ext.form.TimeField = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {Date/String} minValue
   * The minimum allowed time. Can be either a Javascript date object with a valid time value or a string 
   * time in a valid format -- see {@link #format} and {@link #altFormats} (defaults to undefined).
   */
  minValue: undefined,

  /**
   * @cfg {Date/String} maxValue
   * The maximum allowed time. Can be either a Javascript date object with a valid time value or a string 
   * time in a valid format -- see {@link #format} and {@link #altFormats} (defaults to undefined).
   */
  maxValue: undefined,

  /**
   * @cfg {String} minText
   * The error text to display when the date in the cell is before minValue (defaults to
   * 'The time in this field must be equal to or after {0}').
   */
  minText: "The time in this field must be equal to or after {0}",

  /**
   * @cfg {String} maxText
   * The error text to display when the time is after maxValue (defaults to
   * 'The time in this field must be equal to or before {0}').
   */
  maxText: "The time in this field must be equal to or before {0}",

  /**
   * @cfg {String} invalidText
   * The error text to display when the time in the field is invalid (defaults to
   * '{value} is not a valid time').
   */
  invalidText: "{0} is not a valid time",

  /**
   * @cfg {String} format
   * The default time format string which can be overriden for localization support.  The format must be
   * valid according to {@link Date#parseDate} (defaults to 'g:i A', e.g., '3:15 PM').  For 24-hour time
   * format try 'H:i' instead.
   */
  format: "g:i A",

  /**
   * @cfg {String} altFormats
   * Multiple date formats separated by "|" to try when parsing a user input value and it doesn't match the defined
   * format (defaults to 'g:ia|g:iA|g:i a|g:i A|h:i|g:i|H:i|ga|ha|gA|h a|g a|g A|gi|hi|gia|hia|g|H').
   */
  altFormats: "g:ia|g:iA|g:i a|g:i A|h:i|g:i|H:i|ga|ha|gA|h a|g a|g A|gi|hi|gia|hia|g|H",

  /**
   * @cfg {Number} increment
   * The number of minutes between each time value in the list (defaults to 15).
   */
  increment: 15,
  // private override
  mode: 'local',
  // private override
  triggerAction: 'all',
  // private override
  typeAhead: false,
  // private - This is the date to use when generating time values in the absence of either minValue
  // or maxValue.  Using the current date causes DST issues on DST boundary dates, so this is an 
  // arbitrary "safe" date that can be any date aside from DST boundary dates.
  initDate: '1/1/2008',
  // private
  initComponent: function initComponent() {
    if (Ext.isDefined(this.minValue)) {
      this.setMinValue(this.minValue, true);
    }

    if (Ext.isDefined(this.maxValue)) {
      this.setMaxValue(this.maxValue, true);
    }

    if (!this.store) {
      this.generateStore(true);
    }

    Ext.form.TimeField.superclass.initComponent.call(this);
  },

  /**
   * Replaces any existing {@link #minValue} with the new time and refreshes the store.
   * @param {Date/String} value The minimum time that can be selected
   */
  setMinValue: function setMinValue(value,
  /* private */
  initial) {
    this.setLimit(value, true, initial);
    return this;
  },

  /**
   * Replaces any existing {@link #maxValue} with the new time and refreshes the store.
   * @param {Date/String} value The maximum time that can be selected
   */
  setMaxValue: function setMaxValue(value,
  /* private */
  initial) {
    this.setLimit(value, false, initial);
    return this;
  },
  // private
  generateStore: function generateStore(initial) {
    var min = this.minValue || new Date(this.initDate).clearTime(),
        max = this.maxValue || new Date(this.initDate).clearTime().add('mi', 24 * 60 - 1),
        times = [];

    while (min <= max) {
      times.push(min.dateFormat(this.format));
      min = min.add('mi', this.increment);
    }

    this.bindStore(times, initial);
  },
  // private
  setLimit: function setLimit(value, isMin, initial) {
    var d;

    if (Ext.isString(value)) {
      d = this.parseDate(value);
    } else if (Ext.isDate(value)) {
      d = value;
    }

    if (d) {
      var val = new Date(this.initDate).clearTime();
      val.setHours(d.getHours(), d.getMinutes(), isMin ? 0 : 59, 0);
      this[isMin ? 'minValue' : 'maxValue'] = val;

      if (!initial) {
        this.generateStore();
      }
    }
  },
  // inherited docs
  getValue: function getValue() {
    var v = Ext.form.TimeField.superclass.getValue.call(this);
    return this.formatDate(this.parseDate(v)) || '';
  },
  // inherited docs
  setValue: function setValue(value) {
    return Ext.form.TimeField.superclass.setValue.call(this, this.formatDate(this.parseDate(value)));
  },
  // private overrides
  validateValue: Ext.form.DateField.prototype.validateValue,
  parseDate: Ext.form.DateField.prototype.parseDate,
  formatDate: Ext.form.DateField.prototype.formatDate,
  // private
  beforeBlur: function beforeBlur() {
    var v = this.parseDate(this.getRawValue());

    if (v) {
      this.setValue(v.dateFormat(this.format));
    }

    Ext.form.TimeField.superclass.beforeBlur.call(this);
  }
  /**
   * @cfg {Boolean} grow @hide
   */

  /**
   * @cfg {Number} growMin @hide
   */

  /**
   * @cfg {Number} growMax @hide
   */

  /**
   * @hide
   * @method autoSize
   */

});
Ext.reg('timefield', Ext.form.TimeField);

/***/ }),
/* 887 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.Label
 * @extends Ext.BoxComponent
 * Basic Label field.
 * @constructor
 * Creates a new Label
 * @param {Ext.Element/String/Object} config The configuration options.  If an element is passed, it is set as the internal
 * element and its id used as the component id.  If a string is passed, it is assumed to be the id of an existing element
 * and is used as the component id.  Otherwise, it is assumed to be a standard config object and is applied to the component.
 * @xtype label
 */
Ext.form.Label = Ext.extend(Ext.BoxComponent, {
  /**
   * @cfg {String} text The plain text to display within the label (defaults to ''). If you need to include HTML
   * tags within the label's innerHTML, use the {@link #html} config instead.
   */

  /**
   * @cfg {String} forId The id of the input element to which this label will be bound via the standard HTML 'for'
   * attribute. If not specified, the attribute will not be added to the label.
   */

  /**
   * @cfg {String} html An HTML fragment that will be used as the label's innerHTML (defaults to '').
   * Note that if {@link #text} is specified it will take precedence and this value will be ignored.
   */
  // private
  onRender: function onRender(ct, position) {
    if (!this.el) {
      this.el = document.createElement('label');
      this.el.id = this.getId();
      this.el.innerHTML = this.text ? Ext.util.Format.htmlEncode(this.text) : this.html || '';

      if (this.forId) {
        this.el.setAttribute('for', this.forId);
      }
    }

    Ext.form.Label.superclass.onRender.call(this, ct, position);
  },

  /**
   * Updates the label's innerHTML with the specified string.
   * @param {String} text The new label text
   * @param {Boolean} encode (optional) False to skip HTML-encoding the text when rendering it
   * to the label (defaults to true which encodes the value). This might be useful if you want to include
   * tags in the label's innerHTML rather than rendering them as string literals per the default logic.
   * @return {Label} this
   */
  setText: function setText(t, encode) {
    var e = encode === false;
    this[!e ? 'text' : 'html'] = t;
    delete this[e ? 'text' : 'html'];

    if (this.rendered) {
      this.el.dom.innerHTML = encode !== false ? Ext.util.Format.htmlEncode(t) : t;
    }

    return this;
  }
});
Ext.reg('label', Ext.form.Label);

/***/ }),
/* 888 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.Action
 * <p>The subclasses of this class provide actions to perform upon {@link Ext.form.BasicForm Form}s.</p>
 * <p>Instances of this class are only created by a {@link Ext.form.BasicForm Form} when
 * the Form needs to perform an action such as submit or load. The Configuration options
 * listed for this class are set through the Form's action methods: {@link Ext.form.BasicForm#submit submit},
 * {@link Ext.form.BasicForm#load load} and {@link Ext.form.BasicForm#doAction doAction}</p>
 * <p>The instance of Action which performed the action is passed to the success
 * and failure callbacks of the Form's action methods ({@link Ext.form.BasicForm#submit submit},
 * {@link Ext.form.BasicForm#load load} and {@link Ext.form.BasicForm#doAction doAction}),
 * and to the {@link Ext.form.BasicForm#actioncomplete actioncomplete} and
 * {@link Ext.form.BasicForm#actionfailed actionfailed} event handlers.</p>
 */
Ext.form.Action = function (form, options) {
  this.form = form;
  this.options = options || {};
};
/**
 * Failure type returned when client side validation of the Form fails
 * thus aborting a submit action. Client side validation is performed unless
 * {@link #clientValidation} is explicitly set to <tt>false</tt>.
 * @type {String}
 * @static
 */


Ext.form.Action.CLIENT_INVALID = 'client';
/**
 * <p>Failure type returned when server side processing fails and the {@link #result}'s
 * <tt style="font-weight:bold">success</tt> property is set to <tt>false</tt>.</p>
 * <p>In the case of a form submission, field-specific error messages may be returned in the
 * {@link #result}'s <tt style="font-weight:bold">errors</tt> property.</p>
 * @type {String}
 * @static
 */

Ext.form.Action.SERVER_INVALID = 'server';
/**
 * Failure type returned when a communication error happens when attempting
 * to send a request to the remote server. The {@link #response} may be examined to
 * provide further information.
 * @type {String}
 * @static
 */

Ext.form.Action.CONNECT_FAILURE = 'connect';
/**
 * Failure type returned when the response's <tt style="font-weight:bold">success</tt>
 * property is set to <tt>false</tt>, or no field values are returned in the response's
 * <tt style="font-weight:bold">data</tt> property.
 * @type {String}
 * @static
 */

Ext.form.Action.LOAD_FAILURE = 'load';
Ext.form.Action.prototype = {
  /**
   * @cfg {String} url The URL that the Action is to invoke.
   */

  /**
   * @cfg {Boolean} reset When set to <tt><b>true</b></tt>, causes the Form to be
   * {@link Ext.form.BasicForm.reset reset} on Action success. If specified, this happens
   * <b>before</b> the {@link #success} callback is called and before the Form's
   * {@link Ext.form.BasicForm.actioncomplete actioncomplete} event fires.
   */

  /**
   * @cfg {String} method The HTTP method to use to access the requested URL. Defaults to the
   * {@link Ext.form.BasicForm}'s method, or if that is not specified, the underlying DOM form's method.
   */

  /**
   * @cfg {Mixed} params <p>Extra parameter values to pass. These are added to the Form's
   * {@link Ext.form.BasicForm#baseParams} and passed to the specified URL along with the Form's
   * input fields.</p>
   * <p>Parameters are encoded as standard HTTP parameters using {@link Ext#urlEncode}.</p>
   */

  /**
   * @cfg {Number} timeout The number of seconds to wait for a server response before
   * failing with the {@link #failureType} as {@link #Action.CONNECT_FAILURE}. If not specified,
   * defaults to the configured <tt>{@link Ext.form.BasicForm#timeout timeout}</tt> of the
   * {@link Ext.form.BasicForm form}.
   */

  /**
   * @cfg {Function} success The function to call when a valid success return packet is recieved.
   * The function is passed the following parameters:<ul class="mdetail-params">
   * <li><b>form</b> : Ext.form.BasicForm<div class="sub-desc">The form that requested the action</div></li>
   * <li><b>action</b> : Ext.form.Action<div class="sub-desc">The Action class. The {@link #result}
   * property of this object may be examined to perform custom postprocessing.</div></li>
   * </ul>
   */

  /**
   * @cfg {Function} failure The function to call when a failure packet was recieved, or when an
   * error ocurred in the Ajax communication.
   * The function is passed the following parameters:<ul class="mdetail-params">
   * <li><b>form</b> : Ext.form.BasicForm<div class="sub-desc">The form that requested the action</div></li>
   * <li><b>action</b> : Ext.form.Action<div class="sub-desc">The Action class. If an Ajax
   * error ocurred, the failure type will be in {@link #failureType}. The {@link #result}
   * property of this object may be examined to perform custom postprocessing.</div></li>
   * </ul>
   */

  /**
   * @cfg {Object} scope The scope in which to call the callback functions (The <tt>this</tt> reference
   * for the callback functions).
   */

  /**
   * @cfg {String} waitMsg The message to be displayed by a call to {@link Ext.MessageBox#wait}
   * during the time the action is being processed.
   */

  /**
   * @cfg {String} waitTitle The title to be displayed by a call to {@link Ext.MessageBox#wait}
   * during the time the action is being processed.
   */

  /**
   * The type of action this Action instance performs.
   * Currently only "submit" and "load" are supported.
   * @type {String}
   */
  type: 'default',

  /**
   * The type of failure detected will be one of these: {@link #CLIENT_INVALID},
   * {@link #SERVER_INVALID}, {@link #CONNECT_FAILURE}, or {@link #LOAD_FAILURE}.  Usage:
   * <pre><code>
  var fp = new Ext.form.FormPanel({
  ...
  buttons: [{
      text: 'Save',
      formBind: true,
      handler: function(){
          if(fp.getForm().isValid()){
              fp.getForm().submit({
                  url: 'form-submit.php',
                  waitMsg: 'Submitting your data...',
                  success: function(form, action){
                      // server responded with success = true
                      var result = action.{@link #result};
                  },
                  failure: function(form, action){
                      if (action.{@link #failureType} === Ext.form.Action.{@link #CONNECT_FAILURE}) {
                          Ext.Msg.alert('Error',
                              'Status:'+action.{@link #response}.status+': '+
                              action.{@link #response}.statusText);
                      }
                      if (action.failureType === Ext.form.Action.{@link #SERVER_INVALID}){
                          // server responded with success = false
                          Ext.Msg.alert('Invalid', action.{@link #result}.errormsg);
                      }
                  }
              });
          }
      }
  },{
      text: 'Reset',
      handler: function(){
          fp.getForm().reset();
      }
  }]
   * </code></pre>
   * @property failureType
   * @type {String}
   */

  /**
  * The XMLHttpRequest object used to perform the action.
  * @property response
  * @type {Object}
  */

  /**
  * The decoded response object containing a boolean <tt style="font-weight:bold">success</tt> property and
  * other, action-specific properties.
  * @property result
  * @type {Object}
  */
  // interface method
  run: function run(options) {},
  // interface method
  success: function success(response) {},
  // interface method
  handleResponse: function handleResponse(response) {},
  // default connection failure
  failure: function failure(response) {
    this.response = response;
    this.failureType = Ext.form.Action.CONNECT_FAILURE;
    this.form.afterAction(this, false);
  },
  // private
  // shared code among all Actions to validate that there was a response
  // with either responseText or responseXml
  processResponse: function processResponse(response) {
    this.response = response;

    if (!response.responseText && !response.responseXML) {
      return true;
    }

    this.result = this.handleResponse(response);
    return this.result;
  },
  // utility functions used internally
  getUrl: function getUrl(appendParams) {
    var url = this.options.url || this.form.url || this.form.el.dom.action;

    if (appendParams) {
      var p = this.getParams();

      if (p) {
        url = Ext.urlAppend(url, p);
      }
    }

    return url;
  },
  // private
  getMethod: function getMethod() {
    return (this.options.method || this.form.method || this.form.el.dom.method || 'POST').toUpperCase();
  },
  // private
  getParams: function getParams() {
    var bp = this.form.baseParams;
    var p = this.options.params;

    if (p) {
      if (typeof p == "object") {
        p = Ext.urlEncode(Ext.applyIf(p, bp));
      } else if (typeof p == 'string' && bp) {
        p += '&' + Ext.urlEncode(bp);
      }
    } else if (bp) {
      p = Ext.urlEncode(bp);
    }

    return p;
  },
  // private
  createCallback: function createCallback(opts) {
    var opts = opts || {};
    return {
      success: this.success,
      failure: this.failure,
      scope: this,
      timeout: opts.timeout * 1000 || this.form.timeout * 1000,
      upload: this.form.fileUpload ? this.success : undefined
    };
  }
};
/**
 * @class Ext.form.Action.Submit
 * @extends Ext.form.Action
 * <p>A class which handles submission of data from {@link Ext.form.BasicForm Form}s
 * and processes the returned response.</p>
 * <p>Instances of this class are only created by a {@link Ext.form.BasicForm Form} when
 * {@link Ext.form.BasicForm#submit submit}ting.</p>
 * <p><u><b>Response Packet Criteria</b></u></p>
 * <p>A response packet may contain:
 * <div class="mdetail-params"><ul>
 * <li><b><code>success</code></b> property : Boolean
 * <div class="sub-desc">The <code>success</code> property is required.</div></li>
 * <li><b><code>errors</code></b> property : Object
 * <div class="sub-desc"><div class="sub-desc">The <code>errors</code> property,
 * which is optional, contains error messages for invalid fields.</div></li>
 * </ul></div>
 * <p><u><b>JSON Packets</b></u></p>
 * <p>By default, response packets are assumed to be JSON, so a typical response
 * packet may look like this:</p><pre><code>
{
    success: false,
    errors: {
        clientCode: "Client not found",
        portOfLoading: "This field must not be null"
    }
}</code></pre>
 * <p>Other data may be placed into the response for processing by the {@link Ext.form.BasicForm}'s callback
 * or event handler methods. The object decoded from this JSON is available in the
 * {@link Ext.form.Action#result result} property.</p>
 * <p>Alternatively, if an {@link #errorReader} is specified as an {@link Ext.data.XmlReader XmlReader}:</p><pre><code>
    errorReader: new Ext.data.XmlReader({
            record : 'field',
            success: '@success'
        }, [
            'id', 'msg'
        ]
    )
</code></pre>
 * <p>then the results may be sent back in XML format:</p><pre><code>
&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;message success="false"&gt;
&lt;errors&gt;
    &lt;field&gt;
        &lt;id&gt;clientCode&lt;/id&gt;
        &lt;msg&gt;&lt;![CDATA[Code not found. &lt;br /&gt;&lt;i&gt;This is a test validation message from the server &lt;/i&gt;]]&gt;&lt;/msg&gt;
    &lt;/field&gt;
    &lt;field&gt;
        &lt;id&gt;portOfLoading&lt;/id&gt;
        &lt;msg&gt;&lt;![CDATA[Port not found. &lt;br /&gt;&lt;i&gt;This is a test validation message from the server &lt;/i&gt;]]&gt;&lt;/msg&gt;
    &lt;/field&gt;
&lt;/errors&gt;
&lt;/message&gt;
</code></pre>
 * <p>Other elements may be placed into the response XML for processing by the {@link Ext.form.BasicForm}'s callback
 * or event handler methods. The XML document is available in the {@link #errorReader}'s {@link Ext.data.XmlReader#xmlData xmlData} property.</p>
 */

Ext.form.Action.Submit = function (form, options) {
  Ext.form.Action.Submit.superclass.constructor.call(this, form, options);
};

Ext.extend(Ext.form.Action.Submit, Ext.form.Action, {
  /**
   * @cfg {Ext.data.DataReader} errorReader <p><b>Optional. JSON is interpreted with
   * no need for an errorReader.</b></p>
   * <p>A Reader which reads a single record from the returned data. The DataReader's
   * <b>success</b> property specifies how submission success is determined. The Record's
   * data provides the error messages to apply to any invalid form Fields.</p>
   */

  /**
   * @cfg {boolean} clientValidation Determines whether a Form's fields are validated
   * in a final call to {@link Ext.form.BasicForm#isValid isValid} prior to submission.
   * Pass <tt>false</tt> in the Form's submit options to prevent this. If not defined, pre-submission field validation
   * is performed.
   */
  type: 'submit',
  // private
  run: function run() {
    var o = this.options;
    var method = this.getMethod();
    var isGet = method == 'GET';

    if (o.clientValidation === false || this.form.isValid()) {
      Ext.Ajax.request(Ext.apply(this.createCallback(o), {
        form: this.form.el.dom,
        url: this.getUrl(isGet),
        method: method,
        headers: o.headers,
        params: !isGet ? this.getParams() : null,
        isUpload: this.form.fileUpload
      }));
    } else if (o.clientValidation !== false) {
      // client validation failed
      this.failureType = Ext.form.Action.CLIENT_INVALID;
      this.form.afterAction(this, false);
    }
  },
  // private
  success: function success(response) {
    var result = this.processResponse(response);

    if (result === true || result.success) {
      this.form.afterAction(this, true);
      return;
    }

    if (result.errors) {
      this.form.markInvalid(result.errors);
    }

    this.failureType = Ext.form.Action.SERVER_INVALID;
    this.form.afterAction(this, false);
  },
  // private
  handleResponse: function handleResponse(response) {
    if (this.form.errorReader) {
      var rs = this.form.errorReader.read(response);
      var errors = [];

      if (rs.records) {
        for (var i = 0, len = rs.records.length; i < len; i++) {
          var r = rs.records[i];
          errors[i] = r.data;
        }
      }

      if (errors.length < 1) {
        errors = null;
      }

      return {
        success: rs.success,
        errors: errors
      };
    }

    return Ext.decode(response.responseText);
  }
});
/**
 * @class Ext.form.Action.Load
 * @extends Ext.form.Action
 * <p>A class which handles loading of data from a server into the Fields of an {@link Ext.form.BasicForm}.</p>
 * <p>Instances of this class are only created by a {@link Ext.form.BasicForm Form} when
 * {@link Ext.form.BasicForm#load load}ing.</p>
 * <p><u><b>Response Packet Criteria</b></u></p>
 * <p>A response packet <b>must</b> contain:
 * <div class="mdetail-params"><ul>
 * <li><b><code>success</code></b> property : Boolean</li>
 * <li><b><code>data</code></b> property : Object</li>
 * <div class="sub-desc">The <code>data</code> property contains the values of Fields to load.
 * The individual value object for each Field is passed to the Field's
 * {@link Ext.form.Field#setValue setValue} method.</div></li>
 * </ul></div>
 * <p><u><b>JSON Packets</b></u></p>
 * <p>By default, response packets are assumed to be JSON, so for the following form load call:<pre><code>
var myFormPanel = new Ext.form.FormPanel({
    title: 'Client and routing info',
    items: [{
        fieldLabel: 'Client',
        name: 'clientName'
    }, {
        fieldLabel: 'Port of loading',
        name: 'portOfLoading'
    }, {
        fieldLabel: 'Port of discharge',
        name: 'portOfDischarge'
    }]
});
myFormPanel.{@link Ext.form.FormPanel#getForm getForm}().{@link Ext.form.BasicForm#load load}({
    url: '/getRoutingInfo.php',
    params: {
        consignmentRef: myConsignmentRef
    },
    failure: function(form, action) {
        Ext.Msg.alert("Load failed", action.result.errorMessage);
    }
});
</code></pre>
 * a <b>success response</b> packet may look like this:</p><pre><code>
{
    success: true,
    data: {
        clientName: "Fred. Olsen Lines",
        portOfLoading: "FXT",
        portOfDischarge: "OSL"
    }
}</code></pre>
 * while a <b>failure response</b> packet may look like this:</p><pre><code>
{
    success: false,
    errorMessage: "Consignment reference not found"
}</code></pre>
 * <p>Other data may be placed into the response for processing the {@link Ext.form.BasicForm Form}'s
 * callback or event handler methods. The object decoded from this JSON is available in the
 * {@link Ext.form.Action#result result} property.</p>
 */

Ext.form.Action.Load = function (form, options) {
  Ext.form.Action.Load.superclass.constructor.call(this, form, options);
  this.reader = this.form.reader;
};

Ext.extend(Ext.form.Action.Load, Ext.form.Action, {
  // private
  type: 'load',
  // private
  run: function run() {
    Ext.Ajax.request(Ext.apply(this.createCallback(this.options), {
      method: this.getMethod(),
      url: this.getUrl(false),
      headers: this.options.headers,
      params: this.getParams()
    }));
  },
  // private
  success: function success(response) {
    var result = this.processResponse(response);

    if (result === true || !result.success || !result.data) {
      this.failureType = Ext.form.Action.LOAD_FAILURE;
      this.form.afterAction(this, false);
      return;
    }

    this.form.clearInvalid();
    this.form.setValues(result.data);
    this.form.afterAction(this, true);
  },
  // private
  handleResponse: function handleResponse(response) {
    if (this.form.reader) {
      var rs = this.form.reader.read(response);
      var data = rs.records && rs.records[0] ? rs.records[0].data : null;
      return {
        success: rs.success,
        data: data
      };
    }

    return Ext.decode(response.responseText);
  }
});
/**
 * @class Ext.form.Action.DirectLoad
 * @extends Ext.form.Action.Load
 * <p>Provides Ext.direct support for loading form data.</p>
 * <p>This example illustrates usage of Ext.Direct to <b>load</b> a form through Ext.Direct.</p>
 * <pre><code>
var myFormPanel = new Ext.form.FormPanel({
    // configs for FormPanel
    title: 'Basic Information',
    renderTo: document.body,
    width: 300, height: 160,
    padding: 10,

    // configs apply to child items
    defaults: {anchor: '100%'},
    defaultType: 'textfield',
    items: [{
        fieldLabel: 'Name',
        name: 'name'
    },{
        fieldLabel: 'Email',
        name: 'email'
    },{
        fieldLabel: 'Company',
        name: 'company'
    }],

    // configs for BasicForm
    api: {
        // The server-side method to call for load() requests
        load: Profile.getBasicInfo,
        // The server-side must mark the submit handler as a 'formHandler'
        submit: Profile.updateBasicInfo
    },
    // specify the order for the passed params
    paramOrder: ['uid', 'foo']
});

// load the form
myFormPanel.getForm().load({
    // pass 2 arguments to server side getBasicInfo method (len=2)
    params: {
        foo: 'bar',
        uid: 34
    }
});
 * </code></pre>
 * The data packet sent to the server will resemble something like:
 * <pre><code>
[
    {
        "action":"Profile","method":"getBasicInfo","type":"rpc","tid":2,
        "data":[34,"bar"] // note the order of the params
    }
]
 * </code></pre>
 * The form will process a data packet returned by the server that is similar
 * to the following format:
 * <pre><code>
[
    {
        "action":"Profile","method":"getBasicInfo","type":"rpc","tid":2,
        "result":{
            "success":true,
            "data":{
                "name":"Fred Flintstone",
                "company":"Slate Rock and Gravel",
                "email":"fred.flintstone@slaterg.com"
            }
        }
    }
]
 * </code></pre>
 */

Ext.form.Action.DirectLoad = Ext.extend(Ext.form.Action.Load, {
  constructor: function constructor(form, opts) {
    Ext.form.Action.DirectLoad.superclass.constructor.call(this, form, opts);
  },
  type: 'directload',
  run: function run() {
    var args = this.getParams();
    args.push(this.success, this);
    this.form.api.load.apply(window, args);
  },
  getParams: function getParams() {
    var buf = [],
        o = {};
    var bp = this.form.baseParams;
    var p = this.options.params;
    Ext.apply(o, p, bp);
    var paramOrder = this.form.paramOrder;

    if (paramOrder) {
      for (var i = 0, len = paramOrder.length; i < len; i++) {
        buf.push(o[paramOrder[i]]);
      }
    } else if (this.form.paramsAsHash) {
      buf.push(o);
    }

    return buf;
  },
  // Direct actions have already been processed and therefore
  // we can directly set the result; Direct Actions do not have
  // a this.response property.
  processResponse: function processResponse(result) {
    this.result = result;
    return result;
  },
  success: function success(response, trans) {
    if (trans.type == Ext.Direct.exceptions.SERVER) {
      response = {};
    }

    Ext.form.Action.DirectLoad.superclass.success.call(this, response);
  }
});
/**
 * @class Ext.form.Action.DirectSubmit
 * @extends Ext.form.Action.Submit
 * <p>Provides Ext.direct support for submitting form data.</p>
 * <p>This example illustrates usage of Ext.Direct to <b>submit</b> a form through Ext.Direct.</p>
 * <pre><code>
var myFormPanel = new Ext.form.FormPanel({
    // configs for FormPanel
    title: 'Basic Information',
    renderTo: document.body,
    width: 300, height: 160,
    padding: 10,
    buttons:[{
        text: 'Submit',
        handler: function(){
            myFormPanel.getForm().submit({
                params: {
                    foo: 'bar',
                    uid: 34
                }
            });
        }
    }],

    // configs apply to child items
    defaults: {anchor: '100%'},
    defaultType: 'textfield',
    items: [{
        fieldLabel: 'Name',
        name: 'name'
    },{
        fieldLabel: 'Email',
        name: 'email'
    },{
        fieldLabel: 'Company',
        name: 'company'
    }],

    // configs for BasicForm
    api: {
        // The server-side method to call for load() requests
        load: Profile.getBasicInfo,
        // The server-side must mark the submit handler as a 'formHandler'
        submit: Profile.updateBasicInfo
    },
    // specify the order for the passed params
    paramOrder: ['uid', 'foo']
});
 * </code></pre>
 * The data packet sent to the server will resemble something like:
 * <pre><code>
{
    "action":"Profile","method":"updateBasicInfo","type":"rpc","tid":"6",
    "result":{
        "success":true,
        "id":{
            "extAction":"Profile","extMethod":"updateBasicInfo",
            "extType":"rpc","extTID":"6","extUpload":"false",
            "name":"Aaron Conran","email":"aaron@extjs.com","company":"Ext JS, LLC"
        }
    }
}
 * </code></pre>
 * The form will process a data packet returned by the server that is similar
 * to the following:
 * <pre><code>
// sample success packet (batched requests)
[
    {
        "action":"Profile","method":"updateBasicInfo","type":"rpc","tid":3,
        "result":{
            "success":true
        }
    }
]

// sample failure packet (one request)
{
        "action":"Profile","method":"updateBasicInfo","type":"rpc","tid":"6",
        "result":{
            "errors":{
                "email":"already taken"
            },
            "success":false,
            "foo":"bar"
        }
}
 * </code></pre>
 * Also see the discussion in {@link Ext.form.Action.DirectLoad}.
 */

Ext.form.Action.DirectSubmit = Ext.extend(Ext.form.Action.Submit, {
  constructor: function constructor(form, opts) {
    Ext.form.Action.DirectSubmit.superclass.constructor.call(this, form, opts);
  },
  type: 'directsubmit',
  // override of Submit
  run: function run() {
    var o = this.options;

    if (o.clientValidation === false || this.form.isValid()) {
      // tag on any additional params to be posted in the
      // form scope
      this.success.params = this.getParams();
      this.form.api.submit(this.form.el.dom, this.success, this);
    } else if (o.clientValidation !== false) {
      // client validation failed
      this.failureType = Ext.form.Action.CLIENT_INVALID;
      this.form.afterAction(this, false);
    }
  },
  getParams: function getParams() {
    var o = {};
    var bp = this.form.baseParams;
    var p = this.options.params;
    Ext.apply(o, p, bp);
    return o;
  },
  // Direct actions have already been processed and therefore
  // we can directly set the result; Direct Actions do not have
  // a this.response property.
  processResponse: function processResponse(result) {
    this.result = result;
    return result;
  },
  success: function success(response, trans) {
    if (trans.type == Ext.Direct.exceptions.SERVER) {
      response = {};
    }

    Ext.form.Action.DirectSubmit.superclass.success.call(this, response);
  }
});
Ext.form.Action.ACTION_TYPES = {
  'load': Ext.form.Action.Load,
  'submit': Ext.form.Action.Submit,
  'directload': Ext.form.Action.DirectLoad,
  'directsubmit': Ext.form.Action.DirectSubmit
};

/***/ }),
/* 889 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.form.VTypes
 * <p>This is a singleton object which contains a set of commonly used field validation functions.
 * The validations provided are basic and intended to be easily customizable and extended.</p>
 * <p>To add custom VTypes specify the <code>{@link Ext.form.TextField#vtype vtype}</code> validation
 * test function, and optionally specify any corresponding error text to display and any keystroke
 * filtering mask to apply. For example:</p>
 * <pre><code>
// custom Vtype for vtype:'time'
var timeTest = /^([1-9]|1[0-9]):([0-5][0-9])(\s[a|p]m)$/i;
Ext.apply(Ext.form.VTypes, {
    //  vtype validation function
    time: function(val, field) {
        return timeTest.test(val);
    },
    // vtype Text property: The error text to display when the validation function returns false
    timeText: 'Not a valid time.  Must be in the format "12:34 PM".',
    // vtype Mask property: The keystroke filter mask
    timeMask: /[\d\s:amp]/i
});
 * </code></pre>
 * Another example: 
 * <pre><code>
// custom Vtype for vtype:'IPAddress'
Ext.apply(Ext.form.VTypes, {
    IPAddress:  function(v) {
        return /^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/.test(v);
    },
    IPAddressText: 'Must be a numeric IP address',
    IPAddressMask: /[\d\.]/i
});
 * </code></pre>
 * @singleton
 */
Ext.form.VTypes = function () {
  // closure these in so they are only created once.
  var _alpha = /^[a-zA-Z_]+$/,
      _alphanum = /^[a-zA-Z0-9_]+$/,
      _email = /^(("[\w-\s]+")|([\w-]+(?:\.[\w-]+)*)|("[\w-\s]+")([\w-]+(?:\.[\w-]+)*))(@((?:([^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]|-)+\.)*[^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]([^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]|-){0,63})\.([^\s,\x00-\x2F,\x3A-\x40,\x5B-\x60,\x7B-\x7F]{2,63}?)$)|(@\[?((25[0-5]\.|2[0-4][0-9]\.|1[0-9]{2}\.|[0-9]{1,63}\.))((25[0-5]|2[0-4][0-9]|1[0-9]{2}|[0-9]{1,63})\.){2}(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[0-9]{1,63})\]?$)/i,
      _url = /(((^https?)|(^ftp)):\/\/(([^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]|-)+\.)+[^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]{2,63}(\/([^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]|-|%)+(\.[^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]{2,})?)*((([^\s,\x00-\x2F,\x3A-\x40,\x5B-\x60,\x7B-\x7F]|[\-\.\?\\\/+@&#;`~=%!])*)(\.[^\s,\x00-\x2F\x3A-\x40\x5B-\x60\x7B-\x7F]{2,})?)*\/?)/i; // All these messages and functions are configurable

  return {
    /**
     * The function used to validate email addresses.  Note that this is a very basic validation -- complete
     * validation per the email RFC specifications is very complex and beyond the scope of this class, although
     * this function can be overridden if a more comprehensive validation scheme is desired.  See the validation
     * section of the <a href="http://en.wikipedia.org/wiki/E-mail_address">Wikipedia article on email addresses</a> 
     * for additional information.  This implementation is intended to validate the following emails:<tt>
     * 'barney@example.de', 'barney.rubble@example.com', 'barney-rubble@example.coop', 'barney+rubble@example.com'
     * </tt>.
     * @param {String} value The email address
     * @return {Boolean} true if the RegExp test passed, and false if not.
     */
    'email': function email(v) {
      return _email.test(v);
    },

    /**
     * The error text to display when the email validation function returns false.  Defaults to:
     * <tt>'This field should be an e-mail address in the format "user@example.com"'</tt>
     * @type String
     */
    'emailText': 'This field should be an e-mail address in the format "user@example.com"',

    /**
     * The keystroke filter mask to be applied on email input.  See the {@link #email} method for 
     * information about more complex email validation. Defaults to:
     * <tt>/[a-z0-9_\.\-@]/i</tt>
     * @type RegExp
     */
    'emailMask': /[\x2D\.0-9@-Z_a-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0560-\u0588\u05D0-\u05EA\u05EF-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08C7\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D04-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E86-\u0E8A\u0E8C-\u0EA3\u0EA5\u0EA7-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1878\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1C90-\u1CBA\u1CBD-\u1CBF\u1CE9-\u1CEC\u1CEE-\u1CF3\u1CF5\u1CF6\u1CFA\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u31BF\u31F0-\u31FF\u3400-\u4DBF\u4E00-\u9FFC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7BF\uA7C2-\uA7CA\uA7F5-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA8FE\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB69\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC\u{10000}-\u{1000B}\u{1000D}-\u{10026}\u{10028}-\u{1003A}\u{1003C}\u{1003D}\u{1003F}-\u{1004D}\u{10050}-\u{1005D}\u{10080}-\u{100FA}\u{10280}-\u{1029C}\u{102A0}-\u{102D0}\u{10300}-\u{1031F}\u{1032D}-\u{10340}\u{10342}-\u{10349}\u{10350}-\u{10375}\u{10380}-\u{1039D}\u{103A0}-\u{103C3}\u{103C8}-\u{103CF}\u{10400}-\u{1049D}\u{104B0}-\u{104D3}\u{104D8}-\u{104FB}\u{10500}-\u{10527}\u{10530}-\u{10563}\u{10600}-\u{10736}\u{10740}-\u{10755}\u{10760}-\u{10767}\u{10800}-\u{10805}\u{10808}\u{1080A}-\u{10835}\u{10837}\u{10838}\u{1083C}\u{1083F}-\u{10855}\u{10860}-\u{10876}\u{10880}-\u{1089E}\u{108E0}-\u{108F2}\u{108F4}\u{108F5}\u{10900}-\u{10915}\u{10920}-\u{10939}\u{10980}-\u{109B7}\u{109BE}\u{109BF}\u{10A00}\u{10A10}-\u{10A13}\u{10A15}-\u{10A17}\u{10A19}-\u{10A35}\u{10A60}-\u{10A7C}\u{10A80}-\u{10A9C}\u{10AC0}-\u{10AC7}\u{10AC9}-\u{10AE4}\u{10B00}-\u{10B35}\u{10B40}-\u{10B55}\u{10B60}-\u{10B72}\u{10B80}-\u{10B91}\u{10C00}-\u{10C48}\u{10C80}-\u{10CB2}\u{10CC0}-\u{10CF2}\u{10D00}-\u{10D23}\u{10E80}-\u{10EA9}\u{10EB0}\u{10EB1}\u{10F00}-\u{10F1C}\u{10F27}\u{10F30}-\u{10F45}\u{10FB0}-\u{10FC4}\u{10FE0}-\u{10FF6}\u{11003}-\u{11037}\u{11083}-\u{110AF}\u{110D0}-\u{110E8}\u{11103}-\u{11126}\u{11144}\u{11147}\u{11150}-\u{11172}\u{11176}\u{11183}-\u{111B2}\u{111C1}-\u{111C4}\u{111DA}\u{111DC}\u{11200}-\u{11211}\u{11213}-\u{1122B}\u{11280}-\u{11286}\u{11288}\u{1128A}-\u{1128D}\u{1128F}-\u{1129D}\u{1129F}-\u{112A8}\u{112B0}-\u{112DE}\u{11305}-\u{1130C}\u{1130F}\u{11310}\u{11313}-\u{11328}\u{1132A}-\u{11330}\u{11332}\u{11333}\u{11335}-\u{11339}\u{1133D}\u{11350}\u{1135D}-\u{11361}\u{11400}-\u{11434}\u{11447}-\u{1144A}\u{1145F}-\u{11461}\u{11480}-\u{114AF}\u{114C4}\u{114C5}\u{114C7}\u{11580}-\u{115AE}\u{115D8}-\u{115DB}\u{11600}-\u{1162F}\u{11644}\u{11680}-\u{116AA}\u{116B8}\u{11700}-\u{1171A}\u{11800}-\u{1182B}\u{118A0}-\u{118DF}\u{118FF}-\u{11906}\u{11909}\u{1190C}-\u{11913}\u{11915}\u{11916}\u{11918}-\u{1192F}\u{1193F}\u{11941}\u{119A0}-\u{119A7}\u{119AA}-\u{119D0}\u{119E1}\u{119E3}\u{11A00}\u{11A0B}-\u{11A32}\u{11A3A}\u{11A50}\u{11A5C}-\u{11A89}\u{11A9D}\u{11AC0}-\u{11AF8}\u{11C00}-\u{11C08}\u{11C0A}-\u{11C2E}\u{11C40}\u{11C72}-\u{11C8F}\u{11D00}-\u{11D06}\u{11D08}\u{11D09}\u{11D0B}-\u{11D30}\u{11D46}\u{11D60}-\u{11D65}\u{11D67}\u{11D68}\u{11D6A}-\u{11D89}\u{11D98}\u{11EE0}-\u{11EF2}\u{11FB0}\u{12000}-\u{12399}\u{12480}-\u{12543}\u{13000}-\u{1342E}\u{14400}-\u{14646}\u{16800}-\u{16A38}\u{16A40}-\u{16A5E}\u{16AD0}-\u{16AED}\u{16B00}-\u{16B2F}\u{16B40}-\u{16B43}\u{16B63}-\u{16B77}\u{16B7D}-\u{16B8F}\u{16E40}-\u{16E7F}\u{16F00}-\u{16F4A}\u{16F50}\u{16F93}-\u{16F9F}\u{16FE0}\u{16FE1}\u{16FE3}\u{17000}-\u{187F7}\u{18800}-\u{18CD5}\u{18D00}-\u{18D08}\u{1B000}-\u{1B11E}\u{1B150}-\u{1B152}\u{1B164}-\u{1B167}\u{1B170}-\u{1B2FB}\u{1BC00}-\u{1BC6A}\u{1BC70}-\u{1BC7C}\u{1BC80}-\u{1BC88}\u{1BC90}-\u{1BC99}\u{1D400}-\u{1D454}\u{1D456}-\u{1D49C}\u{1D49E}\u{1D49F}\u{1D4A2}\u{1D4A5}\u{1D4A6}\u{1D4A9}-\u{1D4AC}\u{1D4AE}-\u{1D4B9}\u{1D4BB}\u{1D4BD}-\u{1D4C3}\u{1D4C5}-\u{1D505}\u{1D507}-\u{1D50A}\u{1D50D}-\u{1D514}\u{1D516}-\u{1D51C}\u{1D51E}-\u{1D539}\u{1D53B}-\u{1D53E}\u{1D540}-\u{1D544}\u{1D546}\u{1D54A}-\u{1D550}\u{1D552}-\u{1D6A5}\u{1D6A8}-\u{1D6C0}\u{1D6C2}-\u{1D6DA}\u{1D6DC}-\u{1D6FA}\u{1D6FC}-\u{1D714}\u{1D716}-\u{1D734}\u{1D736}-\u{1D74E}\u{1D750}-\u{1D76E}\u{1D770}-\u{1D788}\u{1D78A}-\u{1D7A8}\u{1D7AA}-\u{1D7C2}\u{1D7C4}-\u{1D7CB}\u{1E100}-\u{1E12C}\u{1E137}-\u{1E13D}\u{1E14E}\u{1E2C0}-\u{1E2EB}\u{1E800}-\u{1E8C4}\u{1E900}-\u{1E943}\u{1E94B}\u{1EE00}-\u{1EE03}\u{1EE05}-\u{1EE1F}\u{1EE21}\u{1EE22}\u{1EE24}\u{1EE27}\u{1EE29}-\u{1EE32}\u{1EE34}-\u{1EE37}\u{1EE39}\u{1EE3B}\u{1EE42}\u{1EE47}\u{1EE49}\u{1EE4B}\u{1EE4D}-\u{1EE4F}\u{1EE51}\u{1EE52}\u{1EE54}\u{1EE57}\u{1EE59}\u{1EE5B}\u{1EE5D}\u{1EE5F}\u{1EE61}\u{1EE62}\u{1EE64}\u{1EE67}-\u{1EE6A}\u{1EE6C}-\u{1EE72}\u{1EE74}-\u{1EE77}\u{1EE79}-\u{1EE7C}\u{1EE7E}\u{1EE80}-\u{1EE89}\u{1EE8B}-\u{1EE9B}\u{1EEA1}-\u{1EEA3}\u{1EEA5}-\u{1EEA9}\u{1EEAB}-\u{1EEBB}\u{20000}-\u{2A6DD}\u{2A700}-\u{2B734}\u{2B740}-\u{2B81D}\u{2B820}-\u{2CEA1}\u{2CEB0}-\u{2EBE0}\u{2F800}-\u{2FA1D}\u{30000}-\u{3134A}]/u,

    /**
     * The function used to validate URLs
     * @param {String} value The URL
     * @return {Boolean} true if the RegExp test passed, and false if not.
     */
    'url': function url(v) {
      return _url.test(v);
    },

    /**
     * The error text to display when the url validation function returns false.  Defaults to:
     * <tt>'This field should be a URL in the format "http:/'+'/www.example.com"'</tt>
     * @type String
     */
    'urlText': 'This field should be a URL in the format "http:/' + '/www.example.com"',

    /**
     * The function used to validate alpha values
     * @param {String} value The value
     * @return {Boolean} true if the RegExp test passed, and false if not.
     */
    'alpha': function alpha(v) {
      return _alpha.test(v);
    },

    /**
     * The error text to display when the alpha validation function returns false.  Defaults to:
     * <tt>'This field should only contain letters and _'</tt>
     * @type String
     */
    'alphaText': 'This field should only contain letters and _',

    /**
     * The keystroke filter mask to be applied on alpha input.  Defaults to:
     * <tt>/[a-z_]/i</tt>
     * @type RegExp
     */
    'alphaMask': /[a-z_]/i,

    /**
     * The function used to validate alphanumeric values
     * @param {String} value The value
     * @return {Boolean} true if the RegExp test passed, and false if not.
     */
    'alphanum': function alphanum(v) {
      return _alphanum.test(v);
    },

    /**
     * The error text to display when the alphanumeric validation function returns false.  Defaults to:
     * <tt>'This field should only contain letters, numbers and _'</tt>
     * @type String
     */
    'alphanumText': 'This field should only contain letters, numbers and _',

    /**
     * The keystroke filter mask to be applied on alphanumeric input.  Defaults to:
     * <tt>/[a-z0-9_]/i</tt>
     * @type RegExp
     */
    'alphanumMask': /[a-z0-9_]/i
  };
}();

/***/ }),
/* 890 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.GridPanel
 * @extends Ext.Panel
 * <p>This class represents the primary interface of a component based grid control to represent data
 * in a tabular format of rows and columns. The GridPanel is composed of the following:</p>
 * <div class="mdetail-params"><ul>
 * <li><b>{@link Ext.data.Store Store}</b> : The Model holding the data records (rows)
 * <div class="sub-desc"></div></li>
 * <li><b>{@link Ext.grid.ColumnModel Column model}</b> : Column makeup
 * <div class="sub-desc"></div></li>
 * <li><b>{@link Ext.grid.GridView View}</b> : Encapsulates the user interface 
 * <div class="sub-desc"></div></li>
 * <li><b>{@link Ext.grid.AbstractSelectionModel selection model}</b> : Selection behavior 
 * <div class="sub-desc"></div></li>
 * </ul></div>
 * <p>Example usage:</p>
 * <pre><code>
var grid = new Ext.grid.GridPanel({
    {@link #store}: new {@link Ext.data.Store}({
        {@link Ext.data.Store#autoDestroy autoDestroy}: true,
        {@link Ext.data.Store#reader reader}: reader,
        {@link Ext.data.Store#data data}: xg.dummyData
    }),
    {@link #colModel}: new {@link Ext.grid.ColumnModel}({
        {@link Ext.grid.ColumnModel#defaults defaults}: {
            width: 120,
            sortable: true
        },
        {@link Ext.grid.ColumnModel#columns columns}: [
            {id: 'company', header: 'Company', width: 200, sortable: true, dataIndex: 'company'},
            {header: 'Price', renderer: Ext.util.Format.usMoney, dataIndex: 'price'},
            {header: 'Change', dataIndex: 'change'},
            {header: '% Change', dataIndex: 'pctChange'},
            // instead of specifying renderer: Ext.util.Format.dateRenderer('m/d/Y') use xtype
            {
                header: 'Last Updated', width: 135, dataIndex: 'lastChange',
                xtype: 'datecolumn', format: 'M d, Y'
            }
        ],
    }),
    {@link #viewConfig}: {
        {@link Ext.grid.GridView#forceFit forceFit}: true,

//      Return CSS class to apply to rows depending upon data values
        {@link Ext.grid.GridView#getRowClass getRowClass}: function(record, index) {
            var c = record.{@link Ext.data.Record#get get}('change');
            if (c < 0) {
                return 'price-fall';
            } else if (c > 0) {
                return 'price-rise';
            }
        }
    },
    {@link #sm}: new Ext.grid.RowSelectionModel({singleSelect:true}),
    width: 600,
    height: 300,
    frame: true,
    title: 'Framed with Row Selection and Horizontal Scrolling',
    iconCls: 'icon-grid'
});
 * </code></pre>
 * <p><b><u>Notes:</u></b></p>
 * <div class="mdetail-params"><ul>
 * <li>Although this class inherits many configuration options from base classes, some of them
 * (such as autoScroll, autoWidth, layout, items, etc) are not used by this class, and will
 * have no effect.</li>
 * <li>A grid <b>requires</b> a width in which to scroll its columns, and a height in which to
 * scroll its rows. These dimensions can either be set explicitly through the
 * <tt>{@link Ext.BoxComponent#height height}</tt> and <tt>{@link Ext.BoxComponent#width width}</tt>
 * configuration options or implicitly set by using the grid as a child item of a
 * {@link Ext.Container Container} which will have a {@link Ext.Container#layout layout manager}
 * provide the sizing of its child items (for example the Container of the Grid may specify
 * <tt>{@link Ext.Container#layout layout}:'fit'</tt>).</li>
 * <li>To access the data in a Grid, it is necessary to use the data model encapsulated
 * by the {@link #store Store}. See the {@link #cellclick} event for more details.</li>
 * </ul></div>
 * @constructor
 * @param {Object} config The config object
 * @xtype grid
 */
Ext.grid.GridPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {String} autoExpandColumn
   * <p>The <tt>{@link Ext.grid.Column#id id}</tt> of a {@link Ext.grid.Column column} in
   * this grid that should expand to fill unused space. This value specified here can not
   * be <tt>0</tt>.</p>
   * <br><p><b>Note</b>: If the Grid's {@link Ext.grid.GridView view} is configured with
   * <tt>{@link Ext.grid.GridView#forceFit forceFit}=true</tt> the <tt>autoExpandColumn</tt>
   * is ignored. See {@link Ext.grid.Column}.<tt>{@link Ext.grid.Column#width width}</tt>
   * for additional details.</p>
   * <p>See <tt>{@link #autoExpandMax}</tt> and <tt>{@link #autoExpandMin}</tt> also.</p>
   */
  autoExpandColumn: false,

  /**
   * @cfg {Number} autoExpandMax The maximum width the <tt>{@link #autoExpandColumn}</tt>
   * can have (if enabled). Defaults to <tt>1000</tt>.
   */
  autoExpandMax: 1000,

  /**
   * @cfg {Number} autoExpandMin The minimum width the <tt>{@link #autoExpandColumn}</tt>
   * can have (if enabled). Defaults to <tt>50</tt>.
   */
  autoExpandMin: 50,

  /**
   * @cfg {Boolean} columnLines <tt>true</tt> to add css for column separation lines.
   * Default is <tt>false</tt>.
   */
  columnLines: false,

  /**
   * @cfg {Object} cm Shorthand for <tt>{@link #colModel}</tt>.
   */

  /**
   * @cfg {Object} colModel The {@link Ext.grid.ColumnModel} to use when rendering the grid (required).
   */

  /**
   * @cfg {Array} columns An array of {@link Ext.grid.Column columns} to auto create a
   * {@link Ext.grid.ColumnModel}.  The ColumnModel may be explicitly created via the
   * <tt>{@link #colModel}</tt> configuration property.
   */

  /**
   * @cfg {String} ddGroup The DD group this GridPanel belongs to. Defaults to <tt>'GridDD'</tt> if not specified.
   */

  /**
   * @cfg {String} ddText
   * Configures the text in the drag proxy.  Defaults to:
   * <pre><code>
   * ddText : '{0} selected row{1}'
   * </code></pre>
   * <tt>{0}</tt> is replaced with the number of selected rows.
   */
  ddText: '{0} selected row{1}',

  /**
   * @cfg {Boolean} deferRowRender <P>Defaults to <tt>true</tt> to enable deferred row rendering.</p>
   * <p>This allows the GridPanel to be initially rendered empty, with the expensive update of the row
   * structure deferred so that layouts with GridPanels appear more quickly.</p>
   */
  deferRowRender: true,

  /**
   * @cfg {Boolean} disableSelection <p><tt>true</tt> to disable selections in the grid. Defaults to <tt>false</tt>.</p>
   * <p>Ignored if a {@link #selModel SelectionModel} is specified.</p>
   */

  /**
   * @cfg {Boolean} enableColumnResize <tt>false</tt> to turn off column resizing for the whole grid. Defaults to <tt>true</tt>.
   */

  /**
   * @cfg {Boolean} enableColumnHide
   * Defaults to <tt>true</tt> to enable {@link Ext.grid.Column#hidden hiding of columns}
   * with the {@link #enableHdMenu header menu}.
   */
  enableColumnHide: true,

  /**
   * @cfg {Boolean} enableColumnMove Defaults to <tt>true</tt> to enable drag and drop reorder of columns. <tt>false</tt>
   * to turn off column reordering via drag drop.
   */
  enableColumnMove: true,

  /**
   * @cfg {Boolean} enableDragDrop <p>Enables dragging of the selected rows of the GridPanel. Defaults to <tt>false</tt>.</p>
   * <p>Setting this to <b><tt>true</tt></b> causes this GridPanel's {@link #getView GridView} to
   * create an instance of {@link Ext.grid.GridDragZone}. <b>Note</b>: this is available only <b>after</b>
   * the Grid has been rendered as the GridView's <tt>{@link Ext.grid.GridView#dragZone dragZone}</tt>
   * property.</p>
   * <p>A cooperating {@link Ext.dd.DropZone DropZone} must be created who's implementations of
   * {@link Ext.dd.DropZone#onNodeEnter onNodeEnter}, {@link Ext.dd.DropZone#onNodeOver onNodeOver},
   * {@link Ext.dd.DropZone#onNodeOut onNodeOut} and {@link Ext.dd.DropZone#onNodeDrop onNodeDrop} are able
   * to process the {@link Ext.grid.GridDragZone#getDragData data} which is provided.</p>
   */
  enableDragDrop: false,

  /**
   * @cfg {Boolean} enableHdMenu Defaults to <tt>true</tt> to enable the drop down button for menu in the headers.
   */
  enableHdMenu: true,

  /**
   * @cfg {Boolean} hideHeaders True to hide the grid's header. Defaults to <code>false</code>.
   */

  /**
   * @cfg {Object} loadMask An {@link Ext.LoadMask} config or true to mask the grid while
   * loading. Defaults to <code>false</code>.
   */
  loadMask: false,

  /**
   * @cfg {Number} maxHeight Sets the maximum height of the grid - ignored if <tt>autoHeight</tt> is not on.
   */

  /**
   * @cfg {Number} minColumnWidth The minimum width a column can be resized to. Defaults to <tt>25</tt>.
   */
  minColumnWidth: 25,

  /**
   * @cfg {Object} sm Shorthand for <tt>{@link #selModel}</tt>.
   */

  /**
   * @cfg {Object} selModel Any subclass of {@link Ext.grid.AbstractSelectionModel} that will provide
   * the selection model for the grid (defaults to {@link Ext.grid.RowSelectionModel} if not specified).
   */

  /**
   * @cfg {Ext.data.Store} store The {@link Ext.data.Store} the grid should use as its data source (required).
   */

  /**
   * @cfg {Boolean} stripeRows <tt>true</tt> to stripe the rows. Default is <tt>false</tt>.
   * <p>This causes the CSS class <tt><b>x-grid3-row-alt</b></tt> to be added to alternate rows of
   * the grid. A default CSS rule is provided which sets a background colour, but you can override this
   * with a rule which either overrides the <b>background-color</b> style using the '!important'
   * modifier, or which uses a CSS selector of higher specificity.</p>
   */
  stripeRows: false,

  /**
   * @cfg {Boolean} trackMouseOver True to highlight rows when the mouse is over. Default is <tt>true</tt>
   * for GridPanel, but <tt>false</tt> for EditorGridPanel.
   */
  trackMouseOver: true,

  /**
   * @cfg {Array} stateEvents
   * An array of events that, when fired, should trigger this component to save its state.
   * Defaults to:<pre><code>
   * stateEvents: ['columnmove', 'columnresize', 'sortchange', 'groupchange']
   * </code></pre>
   * <p>These can be any types of events supported by this component, including browser or
   * custom events (e.g., <tt>['click', 'customerchange']</tt>).</p>
   * <p>See {@link Ext.Component#stateful} for an explanation of saving and restoring
   * Component state.</p>
   */
  stateEvents: ['columnmove', 'columnresize', 'sortchange', 'groupchange'],

  /**
   * @cfg {Object} view The {@link Ext.grid.GridView} used by the grid. This can be set
   * before a call to {@link Ext.Component#render render()}.
   */
  view: null,

  /**
   * @cfg {Array} bubbleEvents
   * <p>An array of events that, when fired, should be bubbled to any parent container.
   * See {@link Ext.util.Observable#enableBubble}. 
   * Defaults to <tt>[]</tt>.
   */
  bubbleEvents: [],

  /**
   * @cfg {Object} viewConfig A config object that will be applied to the grid's UI view.  Any of
   * the config options available for {@link Ext.grid.GridView} can be specified here. This option
   * is ignored if <tt>{@link #view}</tt> is specified.
   */
  // private
  rendered: false,
  // private
  viewReady: false,
  // private
  initComponent: function initComponent() {
    Ext.grid.GridPanel.superclass.initComponent.call(this);

    if (this.columnLines) {
      this.cls = (this.cls || '') + ' x-grid-with-col-lines';
    } // override any provided value since it isn't valid
    // and is causing too many bug reports ;)


    this.autoScroll = false;
    this.autoWidth = false;

    if (Ext.isArray(this.columns)) {
      this.colModel = new Ext.grid.ColumnModel(this.columns);
      delete this.columns;
    } // check and correct shorthanded configs


    if (this.ds) {
      this.store = this.ds;
      delete this.ds;
    }

    if (this.cm) {
      this.colModel = this.cm;
      delete this.cm;
    }

    if (this.sm) {
      this.selModel = this.sm;
      delete this.sm;
    }

    this.store = Ext.StoreMgr.lookup(this.store);
    this.addEvents( // raw events

    /**
     * @event click
     * The raw click event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'click',
    /**
     * @event dblclick
     * The raw dblclick event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'dblclick',
    /**
     * @event contextmenu
     * The raw contextmenu event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'contextmenu',
    /**
     * @event mousedown
     * The raw mousedown event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'mousedown',
    /**
     * @event mouseup
     * The raw mouseup event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'mouseup',
    /**
     * @event mouseover
     * The raw mouseover event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'mouseover',
    /**
     * @event mouseout
     * The raw mouseout event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'mouseout',
    /**
     * @event keypress
     * The raw keypress event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'keypress',
    /**
     * @event keydown
     * The raw keydown event for the entire grid.
     * @param {Ext.EventObject} e
     */
    'keydown', // custom events

    /**
     * @event cellmousedown
     * Fires before a cell is clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'cellmousedown',
    /**
     * @event rowmousedown
     * Fires before a row is clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowmousedown',
    /**
     * @event headermousedown
     * Fires before a header is clicked
     * @param {Grid} this
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'headermousedown',
    /**
     * @event groupmousedown
     * Fires before a group header is clicked. <b>Only applies for grids with a {@link Ext.grid.GroupingView GroupingView}</b>.
     * @param {Grid} this
     * @param {String} groupField
     * @param {String} groupValue
     * @param {Ext.EventObject} e
     */
    'groupmousedown',
    /**
     * @event rowbodymousedown
     * Fires before the row body is clicked. <b>Only applies for grids with {@link Ext.grid.GridView#enableRowBody enableRowBody} configured.</b>
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowbodymousedown',
    /**
     * @event containermousedown
     * Fires before the container is clicked. The container consists of any part of the grid body that is not covered by a row.
     * @param {Grid} this
     * @param {Ext.EventObject} e
     */
    'containermousedown',
    /**
     * @event cellclick
     * Fires when a cell is clicked.
     * The data for the cell is drawn from the {@link Ext.data.Record Record}
     * for this row. To access the data in the listener function use the
     * following technique:
     * <pre><code>
    function(grid, rowIndex, columnIndex, e) {
    var record = grid.getStore().getAt(rowIndex);  // Get the Record
    var fieldName = grid.getColumnModel().getDataIndex(columnIndex); // Get field name
    var data = record.get(fieldName);
    }
    </code></pre>
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'cellclick',
    /**
     * @event celldblclick
     * Fires when a cell is double clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'celldblclick',
    /**
     * @event rowclick
     * Fires when a row is clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowclick',
    /**
     * @event rowdblclick
     * Fires when a row is double clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowdblclick',
    /**
     * @event headerclick
     * Fires when a header is clicked
     * @param {Grid} this
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'headerclick',
    /**
     * @event headerdblclick
     * Fires when a header cell is double clicked
     * @param {Grid} this
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'headerdblclick',
    /**
     * @event groupclick
     * Fires when group header is clicked. <b>Only applies for grids with a {@link Ext.grid.GroupingView GroupingView}</b>.
     * @param {Grid} this
     * @param {String} groupField
     * @param {String} groupValue
     * @param {Ext.EventObject} e
     */
    'groupclick',
    /**
     * @event groupdblclick
     * Fires when group header is double clicked. <b>Only applies for grids with a {@link Ext.grid.GroupingView GroupingView}</b>.
     * @param {Grid} this
     * @param {String} groupField
     * @param {String} groupValue
     * @param {Ext.EventObject} e
     */
    'groupdblclick',
    /**
     * @event containerclick
     * Fires when the container is clicked. The container consists of any part of the grid body that is not covered by a row.
     * @param {Grid} this
     * @param {Ext.EventObject} e
     */
    'containerclick',
    /**
     * @event containerdblclick
     * Fires when the container is double clicked. The container consists of any part of the grid body that is not covered by a row.
     * @param {Grid} this
     * @param {Ext.EventObject} e
     */
    'containerdblclick',
    /**
     * @event rowbodyclick
     * Fires when the row body is clicked. <b>Only applies for grids with {@link Ext.grid.GridView#enableRowBody enableRowBody} configured.</b>
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowbodyclick',
    /**
     * @event rowbodydblclick
     * Fires when the row body is double clicked. <b>Only applies for grids with {@link Ext.grid.GridView#enableRowBody enableRowBody} configured.</b>
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowbodydblclick',
    /**
     * @event rowcontextmenu
     * Fires when a row is right clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowcontextmenu',
    /**
     * @event cellcontextmenu
     * Fires when a cell is right clicked
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Number} cellIndex
     * @param {Ext.EventObject} e
     */
    'cellcontextmenu',
    /**
     * @event headercontextmenu
     * Fires when a header is right clicked
     * @param {Grid} this
     * @param {Number} columnIndex
     * @param {Ext.EventObject} e
     */
    'headercontextmenu',
    /**
     * @event groupcontextmenu
     * Fires when group header is right clicked. <b>Only applies for grids with a {@link Ext.grid.GroupingView GroupingView}</b>.
     * @param {Grid} this
     * @param {String} groupField
     * @param {String} groupValue
     * @param {Ext.EventObject} e
     */
    'groupcontextmenu',
    /**
     * @event containercontextmenu
     * Fires when the container is right clicked. The container consists of any part of the grid body that is not covered by a row.
     * @param {Grid} this
     * @param {Ext.EventObject} e
     */
    'containercontextmenu',
    /**
     * @event rowbodycontextmenu
     * Fires when the row body is right clicked. <b>Only applies for grids with {@link Ext.grid.GridView#enableRowBody enableRowBody} configured.</b>
     * @param {Grid} this
     * @param {Number} rowIndex
     * @param {Ext.EventObject} e
     */
    'rowbodycontextmenu',
    /**
     * @event bodyscroll
     * Fires when the body element is scrolled
     * @param {Number} scrollLeft
     * @param {Number} scrollTop
     */
    'bodyscroll',
    /**
     * @event columnresize
     * Fires when the user resizes a column
     * @param {Number} columnIndex
     * @param {Number} newSize
     */
    'columnresize',
    /**
     * @event columnmove
     * Fires when the user moves a column
     * @param {Number} oldIndex
     * @param {Number} newIndex
     */
    'columnmove',
    /**
     * @event sortchange
     * Fires when the grid's store sort changes
     * @param {Grid} this
     * @param {Object} sortInfo An object with the keys field and direction
     */
    'sortchange',
    /**
     * @event groupchange
     * Fires when the grid's grouping changes (only applies for grids with a {@link Ext.grid.GroupingView GroupingView})
     * @param {Grid} this
     * @param {String} groupField A string with the grouping field, null if the store is not grouped.
     */
    'groupchange',
    /**
     * @event reconfigure
     * Fires when the grid is reconfigured with a new store and/or column model.
     * @param {Grid} this
     * @param {Ext.data.Store} store The new store
     * @param {Ext.grid.ColumnModel} colModel The new column model
     */
    'reconfigure',
    /**
     * @event viewready
     * Fires when the grid view is available (use this for selecting a default row). 
     * @param {Grid} this
     */
    'viewready');
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.grid.GridPanel.superclass.onRender.apply(this, arguments);
    var c = this.getGridEl();
    this.el.addClass('x-grid-panel');
    this.mon(c, {
      scope: this,
      mousedown: this.onMouseDown,
      click: this.onClick,
      dblclick: this.onDblClick,
      contextmenu: this.onContextMenu
    });
    this.relayEvents(c, ['mousedown', 'mouseup', 'mouseover', 'mouseout', 'keypress', 'keydown']);
    var view = this.getView();
    view.init(this);
    view.render();
    this.getSelectionModel().init(this);
  },
  // private
  initEvents: function initEvents() {
    Ext.grid.GridPanel.superclass.initEvents.call(this);

    if (this.loadMask) {
      this.loadMask = new Ext.LoadMask(this.bwrap, Ext.apply({
        store: this.store
      }, this.loadMask));
    }
  },
  initStateEvents: function initStateEvents() {
    Ext.grid.GridPanel.superclass.initStateEvents.call(this);
    this.mon(this.colModel, 'hiddenchange', this.saveState, this, {
      delay: 100
    });
  },
  applyState: function applyState(state) {
    var cm = this.colModel,
        cs = state.columns,
        store = this.store,
        s,
        c,
        oldIndex;

    if (cs) {
      for (var i = 0, len = cs.length; i < len; i++) {
        s = cs[i];
        c = cm.getColumnById(s.id);

        if (c) {
          c.hidden = s.hidden;
          c.width = s.width;
          oldIndex = cm.getIndexById(s.id);

          if (oldIndex != i) {
            cm.moveColumn(oldIndex, i);
          }
        }
      }
    }

    if (store) {
      s = state.sort;

      if (s) {
        store[store.remoteSort ? 'setDefaultSort' : 'sort'](s.field, s.direction);
      }

      s = state.group;

      if (store.groupBy) {
        if (s) {
          store.groupBy(s);
        } else {
          store.clearGrouping();
        }
      }
    }

    var o = Ext.apply({}, state);
    delete o.columns;
    delete o.sort;
    Ext.grid.GridPanel.superclass.applyState.call(this, o);
  },
  getState: function getState() {
    var o = {
      columns: []
    },
        store = this.store,
        ss,
        gs;

    for (var i = 0, c; c = this.colModel.config[i]; i++) {
      o.columns[i] = {
        id: c.id,
        width: c.width
      };

      if (c.hidden) {
        o.columns[i].hidden = true;
      }
    }

    if (store) {
      ss = store.getSortState();

      if (ss) {
        o.sort = ss;
      }

      if (store.getGroupState) {
        gs = store.getGroupState();

        if (gs) {
          o.group = gs;
        }
      }
    }

    return o;
  },
  // private
  afterRender: function afterRender() {
    Ext.grid.GridPanel.superclass.afterRender.call(this);
    var v = this.view;
    this.on('bodyresize', v.layout, v);
    v.layout();

    if (this.deferRowRender) {
      v.afterRender.defer(10, this.view);
    } else {
      v.afterRender();
    }

    this.viewReady = true;
  },

  /**
   * <p>Reconfigures the grid to use a different Store and Column Model
   * and fires the 'reconfigure' event. The View will be bound to the new
   * objects and refreshed.</p>
   * <p>Be aware that upon reconfiguring a GridPanel, certain existing settings <i>may</i> become
   * invalidated. For example the configured {@link #autoExpandColumn} may no longer exist in the
   * new ColumnModel. Also, an existing {@link Ext.PagingToolbar PagingToolbar} will still be bound
   * to the old Store, and will need rebinding. Any {@link #plugins} might also need reconfiguring
   * with the new data.</p>
   * @param {Ext.data.Store} store The new {@link Ext.data.Store} object
   * @param {Ext.grid.ColumnModel} colModel The new {@link Ext.grid.ColumnModel} object
   */
  reconfigure: function reconfigure(store, colModel) {
    var rendered = this.rendered;

    if (rendered) {
      if (this.loadMask) {
        this.loadMask.destroy();
        this.loadMask = new Ext.LoadMask(this.bwrap, Ext.apply({}, {
          store: store
        }, this.initialConfig.loadMask));
      }
    }

    if (this.view) {
      this.view.initData(store, colModel);
    }

    this.store = store;
    this.colModel = colModel;

    if (rendered) {
      this.view.refresh(true);
    }

    this.fireEvent('reconfigure', this, store, colModel);
  },
  // private
  onDestroy: function onDestroy() {
    if (this.rendered) {
      Ext.destroy(this.view, this.loadMask);
    } else if (this.store && this.store.autoDestroy) {
      this.store.destroy();
    }

    Ext.destroy(this.colModel, this.selModel);
    this.store = this.selModel = this.colModel = this.view = this.loadMask = null;
    Ext.grid.GridPanel.superclass.onDestroy.call(this);
  },
  // private
  processEvent: function processEvent(name, e) {
    this.fireEvent(name, e);
    var t = e.getTarget(),
        v = this.view,
        header = v.findHeaderIndex(t);

    if (header !== false) {
      this.fireEvent('header' + name, this, header, e);
    } else {
      var row = v.findRowIndex(t),
          cell,
          body;

      if (row !== false) {
        this.fireEvent('row' + name, this, row, e);
        cell = v.findCellIndex(t);
        body = v.findRowBody(t);

        if (cell !== false) {
          this.fireEvent('cell' + name, this, row, cell, e);
        }

        if (body) {
          this.fireEvent('rowbody' + name, this, row, e);
        }
      } else {
        this.fireEvent('container' + name, this, e);
      }
    }

    this.view.processEvent(name, e);
  },
  // private
  onClick: function onClick(e) {
    this.processEvent('click', e);
  },
  // private
  onMouseDown: function onMouseDown(e) {
    this.processEvent('mousedown', e);
  },
  // private
  onContextMenu: function onContextMenu(e, t) {
    this.processEvent('contextmenu', e);
  },
  // private
  onDblClick: function onDblClick(e) {
    this.processEvent('dblclick', e);
  },
  // private
  walkCells: function walkCells(row, col, step, fn, scope) {
    var cm = this.colModel,
        clen = cm.getColumnCount(),
        ds = this.store,
        rlen = ds.getCount(),
        first = true;

    if (step < 0) {
      if (col < 0) {
        row--;
        first = false;
      }

      while (row >= 0) {
        if (!first) {
          col = clen - 1;
        }

        first = false;

        while (col >= 0) {
          if (fn.call(scope || this, row, col, cm) === true) {
            return [row, col];
          }

          col--;
        }

        row--;
      }
    } else {
      if (col >= clen) {
        row++;
        first = false;
      }

      while (row < rlen) {
        if (!first) {
          col = 0;
        }

        first = false;

        while (col < clen) {
          if (fn.call(scope || this, row, col, cm) === true) {
            return [row, col];
          }

          col++;
        }

        row++;
      }
    }

    return null;
  },
  // private
  onResize: function onResize() {
    Ext.grid.GridPanel.superclass.onResize.apply(this, arguments);

    if (this.viewReady) {
      this.view.layout();
    }
  },

  /**
   * Returns the grid's underlying element.
   * @return {Element} The element
   */
  getGridEl: function getGridEl() {
    return this.body;
  },
  // private for compatibility, overridden by editor grid
  stopEditing: Ext.emptyFn,

  /**
   * Returns the grid's selection model configured by the <code>{@link #selModel}</code>
   * configuration option. If no selection model was configured, this will create
   * and return a {@link Ext.grid.RowSelectionModel RowSelectionModel}.
   * @return {SelectionModel}
   */
  getSelectionModel: function getSelectionModel() {
    if (!this.selModel) {
      this.selModel = new Ext.grid.RowSelectionModel(this.disableSelection ? {
        selectRow: Ext.emptyFn
      } : null);
    }

    return this.selModel;
  },

  /**
   * Returns the grid's data store.
   * @return {Ext.data.Store} The store
   */
  getStore: function getStore() {
    return this.store;
  },

  /**
   * Returns the grid's ColumnModel.
   * @return {Ext.grid.ColumnModel} The column model
   */
  getColumnModel: function getColumnModel() {
    return this.colModel;
  },

  /**
   * Returns the grid's GridView object.
   * @return {Ext.grid.GridView} The grid view
   */
  getView: function getView() {
    if (!this.view) {
      this.view = new Ext.grid.GridView(this.viewConfig);
    }

    return this.view;
  },

  /**
   * Called to get grid's drag proxy text, by default returns this.ddText.
   * @return {String} The text
   */
  getDragDropText: function getDragDropText() {
    var count = this.selModel.getCount();
    return String.format(this.ddText, count, count == 1 ? '' : 's');
  }
  /** 
   * @cfg {String/Number} activeItem 
   * @hide 
   */

  /** 
   * @cfg {Boolean} autoDestroy 
   * @hide 
   */

  /** 
   * @cfg {Object/String/Function} autoLoad 
   * @hide 
   */

  /** 
   * @cfg {Boolean} autoWidth 
   * @hide 
   */

  /** 
   * @cfg {Boolean/Number} bufferResize 
   * @hide 
   */

  /** 
   * @cfg {String} defaultType 
   * @hide 
   */

  /** 
   * @cfg {Object} defaults 
   * @hide 
   */

  /** 
   * @cfg {Boolean} hideBorders 
   * @hide 
   */

  /** 
   * @cfg {Mixed} items 
   * @hide 
   */

  /** 
   * @cfg {String} layout 
   * @hide 
   */

  /** 
   * @cfg {Object} layoutConfig 
   * @hide 
   */

  /** 
   * @cfg {Boolean} monitorResize 
   * @hide 
   */

  /** 
   * @property items 
   * @hide 
   */

  /** 
   * @method add 
   * @hide 
   */

  /** 
   * @method cascade 
   * @hide 
   */

  /** 
   * @method doLayout 
   * @hide 
   */

  /** 
   * @method find 
   * @hide 
   */

  /** 
   * @method findBy 
   * @hide 
   */

  /** 
   * @method findById 
   * @hide 
   */

  /** 
   * @method findByType 
   * @hide 
   */

  /** 
   * @method getComponent 
   * @hide 
   */

  /** 
   * @method getLayout 
   * @hide 
   */

  /** 
   * @method getUpdater 
   * @hide 
   */

  /** 
   * @method insert 
   * @hide 
   */

  /** 
   * @method load 
   * @hide 
   */

  /** 
   * @method remove 
   * @hide 
   */

  /** 
   * @event add 
   * @hide 
   */

  /** 
   * @event afterlayout 
   * @hide 
   */

  /** 
   * @event beforeadd 
   * @hide 
   */

  /** 
   * @event beforeremove 
   * @hide 
   */

  /** 
   * @event remove 
   * @hide 
   */

  /**
   * @cfg {String} allowDomMove  @hide
   */

  /**
   * @cfg {String} autoEl @hide
   */

  /**
   * @cfg {String} applyTo  @hide
   */

  /**
   * @cfg {String} autoScroll  @hide
   */

  /**
   * @cfg {String} bodyBorder  @hide
   */

  /**
   * @cfg {String} bodyStyle  @hide
   */

  /**
   * @cfg {String} contentEl  @hide
   */

  /**
   * @cfg {String} disabledClass  @hide
   */

  /**
   * @cfg {String} elements  @hide
   */

  /**
   * @cfg {String} html  @hide
   */

  /**
   * @cfg {Boolean} preventBodyReset
   * @hide
   */

  /**
   * @property disabled
   * @hide
   */

  /**
   * @method applyToMarkup
   * @hide
   */

  /**
   * @method enable
   * @hide
   */

  /**
   * @method disable
   * @hide
   */

  /**
   * @method setDisabled
   * @hide
   */

});
Ext.reg('grid', Ext.grid.GridPanel);

/***/ }),
/* 891 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.GridView
 * @extends Ext.util.Observable
 * <p>This class encapsulates the user interface of an {@link Ext.grid.GridPanel}.
 * Methods of this class may be used to access user interface elements to enable
 * special display effects. Do not change the DOM structure of the user interface.</p>
 * <p>This class does not provide ways to manipulate the underlying data. The data
 * model of a Grid is held in an {@link Ext.data.Store}.</p>
 * @constructor
 * @param {Object} config
 */
Ext.grid.GridView = Ext.extend(Ext.util.Observable, {
  /**
   * Override this function to apply custom CSS classes to rows during rendering.  You can also supply custom
   * parameters to the row template for the current row to customize how it is rendered using the <b>rowParams</b>
   * parameter.  This function should return the CSS class name (or empty string '' for none) that will be added
   * to the row's wrapping div.  To apply multiple class names, simply return them space-delimited within the string
   * (e.g., 'my-class another-class'). Example usage:
  <pre><code>
  viewConfig: {
  forceFit: true,
  showPreview: true, // custom property
  enableRowBody: true, // required to create a second, full-width row to show expanded Record data
  getRowClass: function(record, rowIndex, rp, ds){ // rp = rowParams
      if(this.showPreview){
          rp.body = '&lt;p>'+record.data.excerpt+'&lt;/p>';
          return 'x-grid3-row-expanded';
      }
      return 'x-grid3-row-collapsed';
  }
  },     
  </code></pre>
   * @param {Record} record The {@link Ext.data.Record} corresponding to the current row.
   * @param {Number} index The row index.
   * @param {Object} rowParams A config object that is passed to the row template during rendering that allows
   * customization of various aspects of a grid row.
   * <p>If {@link #enableRowBody} is configured <b><tt></tt>true</b>, then the following properties may be set
   * by this function, and will be used to render a full-width expansion row below each grid row:</p>
   * <ul>
   * <li><code>body</code> : String <div class="sub-desc">An HTML fragment to be used as the expansion row's body content (defaults to '').</div></li>
   * <li><code>bodyStyle</code> : String <div class="sub-desc">A CSS style specification that will be applied to the expansion row's &lt;tr> element. (defaults to '').</div></li>
   * </ul>
   * The following property will be passed in, and may be appended to:
   * <ul>
   * <li><code>tstyle</code> : String <div class="sub-desc">A CSS style specification that willl be applied to the &lt;table> element which encapsulates
   * both the standard grid row, and any expansion row.</div></li>
   * </ul>
   * @param {Store} store The {@link Ext.data.Store} this grid is bound to
   * @method getRowClass
   * @return {String} a CSS class name to add to the row.
   */

  /**
   * @cfg {Boolean} enableRowBody True to add a second TR element per row that can be used to provide a row body
   * that spans beneath the data row.  Use the {@link #getRowClass} method's rowParams config to customize the row body.
   */

  /**
   * @cfg {String} emptyText Default text (html tags are accepted) to display in the grid body when no rows
   * are available (defaults to ''). This value will be used to update the <tt>{@link #mainBody}</tt>:
  <pre><code>
  this.mainBody.update('&lt;div class="x-grid-empty">' + this.emptyText + '&lt;/div>');
  </code></pre>
   */

  /**
   * @cfg {Boolean} headersDisabled True to disable the grid column headers (defaults to <tt>false</tt>). 
   * Use the {@link Ext.grid.ColumnModel ColumnModel} <tt>{@link Ext.grid.ColumnModel#menuDisabled menuDisabled}</tt>
   * config to disable the <i>menu</i> for individual columns.  While this config is true the
   * following will be disabled:<div class="mdetail-params"><ul>
   * <li>clicking on header to sort</li>
   * <li>the trigger to reveal the menu.</li>
   * </ul></div>
   */

  /**
   * <p>A customized implementation of a {@link Ext.dd.DragZone DragZone} which provides default implementations
   * of the template methods of DragZone to enable dragging of the selected rows of a GridPanel.
   * See {@link Ext.grid.GridDragZone} for details.</p>
   * <p>This will <b>only</b> be present:<div class="mdetail-params"><ul>
   * <li><i>if</i> the owning GridPanel was configured with {@link Ext.grid.GridPanel#enableDragDrop enableDragDrop}: <tt>true</tt>.</li>
   * <li><i>after</i> the owning GridPanel has been rendered.</li>
   * </ul></div>
   * @property dragZone
   * @type {Ext.grid.GridDragZone}
   */

  /**
   * @cfg {Boolean} deferEmptyText True to defer <tt>{@link #emptyText}</tt> being applied until the store's
   * first load (defaults to <tt>true</tt>).
   */
  deferEmptyText: true,

  /**
   * @cfg {Number} scrollOffset The amount of space to reserve for the vertical scrollbar
   * (defaults to <tt>undefined</tt>). If an explicit value isn't specified, this will be automatically
   * calculated.
   */
  scrollOffset: undefined,

  /**
   * @cfg {Boolean} autoFill
   * Defaults to <tt>false</tt>.  Specify <tt>true</tt> to have the column widths re-proportioned
   * when the grid is <b>initially rendered</b>.  The 
   * {@link Ext.grid.Column#width initially configured width}</tt> of each column will be adjusted
   * to fit the grid width and prevent horizontal scrolling. If columns are later resized (manually
   * or programmatically), the other columns in the grid will <b>not</b> be resized to fit the grid width.
   * See <tt>{@link #forceFit}</tt> also.
   */
  autoFill: false,

  /**
   * @cfg {Boolean} forceFit
   * Defaults to <tt>false</tt>.  Specify <tt>true</tt> to have the column widths re-proportioned
   * at <b>all times</b>.  The {@link Ext.grid.Column#width initially configured width}</tt> of each
   * column will be adjusted to fit the grid width and prevent horizontal scrolling. If columns are
   * later resized (manually or programmatically), the other columns in the grid <b>will</b> be resized
   * to fit the grid width. See <tt>{@link #autoFill}</tt> also.
   */
  forceFit: false,

  /**
   * @cfg {Array} sortClasses The CSS classes applied to a header when it is sorted. (defaults to <tt>['sort-asc', 'sort-desc']</tt>)
   */
  sortClasses: ['sort-asc', 'sort-desc'],

  /**
   * @cfg {String} sortAscText The text displayed in the 'Sort Ascending' menu item (defaults to <tt>'Sort Ascending'</tt>)
   */
  sortAscText: 'Sort Ascending',

  /**
   * @cfg {String} sortDescText The text displayed in the 'Sort Descending' menu item (defaults to <tt>'Sort Descending'</tt>)
   */
  sortDescText: 'Sort Descending',

  /**
   * @cfg {String} columnsText The text displayed in the 'Columns' menu item (defaults to <tt>'Columns'</tt>)
   */
  columnsText: 'Columns',

  /**
   * @cfg {String} selectedRowClass The CSS class applied to a selected row (defaults to <tt>'x-grid3-row-selected'</tt>). An
   * example overriding the default styling:
  <pre><code>
  .x-grid3-row-selected {background-color: yellow;}
  </code></pre>
   * Note that this only controls the row, and will not do anything for the text inside it.  To style inner
   * facets (like text) use something like:
  <pre><code>
  .x-grid3-row-selected .x-grid3-cell-inner {
      color: #FFCC00;
  }
  </code></pre>
   * @type String
   */
  selectedRowClass: 'x-grid3-row-selected',
  // private
  borderWidth: 2,
  tdClass: 'x-grid3-cell',
  hdCls: 'x-grid3-hd',
  markDirty: true,

  /**
   * @cfg {Number} cellSelectorDepth The number of levels to search for cells in event delegation (defaults to <tt>4</tt>)
   */
  cellSelectorDepth: 4,

  /**
   * @cfg {Number} rowSelectorDepth The number of levels to search for rows in event delegation (defaults to <tt>10</tt>)
   */
  rowSelectorDepth: 10,

  /**
   * @cfg {Number} rowBodySelectorDepth The number of levels to search for row bodies in event delegation (defaults to <tt>10</tt>)
   */
  rowBodySelectorDepth: 10,

  /**
   * @cfg {String} cellSelector The selector used to find cells internally (defaults to <tt>'td.x-grid3-cell'</tt>)
   */
  cellSelector: 'td.x-grid3-cell',

  /**
   * @cfg {String} rowSelector The selector used to find rows internally (defaults to <tt>'div.x-grid3-row'</tt>)
   */
  rowSelector: 'div.x-grid3-row',

  /**
   * @cfg {String} rowBodySelector The selector used to find row bodies internally (defaults to <tt>'div.x-grid3-row'</tt>)
   */
  rowBodySelector: 'div.x-grid3-row-body',
  // private
  firstRowCls: 'x-grid3-row-first',
  lastRowCls: 'x-grid3-row-last',
  rowClsRe: /(?:^|\s+)x-grid3-row-(first|last|alt)(?:\s+|$)/g,
  constructor: function constructor(config) {
    Ext.apply(this, config); // These events are only used internally by the grid components

    this.addEvents(
    /**
     * @event beforerowremoved
     * Internal UI Event. Fired before a row is removed.
     * @param {Ext.grid.GridView} view
     * @param {Number} rowIndex The index of the row to be removed.
     * @param {Ext.data.Record} record The Record to be removed
     */
    'beforerowremoved',
    /**
     * @event beforerowsinserted
     * Internal UI Event. Fired before rows are inserted.
     * @param {Ext.grid.GridView} view
     * @param {Number} firstRow The index of the first row to be inserted.
     * @param {Number} lastRow The index of the last row to be inserted.
     */
    'beforerowsinserted',
    /**
     * @event beforerefresh
     * Internal UI Event. Fired before the view is refreshed.
     * @param {Ext.grid.GridView} view
     */
    'beforerefresh',
    /**
     * @event rowremoved
     * Internal UI Event. Fired after a row is removed.
     * @param {Ext.grid.GridView} view
     * @param {Number} rowIndex The index of the row that was removed.
     * @param {Ext.data.Record} record The Record that was removed
     */
    'rowremoved',
    /**
     * @event rowsinserted
     * Internal UI Event. Fired after rows are inserted.
     * @param {Ext.grid.GridView} view
     * @param {Number} firstRow The index of the first inserted.
     * @param {Number} lastRow The index of the last row inserted.
     */
    'rowsinserted',
    /**
     * @event rowupdated
     * Internal UI Event. Fired after a row has been updated.
     * @param {Ext.grid.GridView} view
     * @param {Number} firstRow The index of the row updated.
     * @param {Ext.data.record} record The Record backing the row updated.
     */
    'rowupdated',
    /**
     * @event refresh
     * Internal UI Event. Fired after the GridView's body has been refreshed.
     * @param {Ext.grid.GridView} view
     */
    'refresh');
    Ext.grid.GridView.superclass.constructor.call(this);
  },

  /* -------------------------------- UI Specific ----------------------------- */
  // private
  initTemplates: function initTemplates() {
    var ts = this.templates || {};

    if (!ts.master) {
      ts.master = new Ext.Template('<div class="x-grid3" hidefocus="true">', '<div class="x-grid3-viewport">', '<div class="x-grid3-header"><div class="x-grid3-header-inner"><div class="x-grid3-header-offset" style="{ostyle}">{header}</div></div><div class="x-clear"></div></div>', '<div class="x-grid3-scroller"><div class="x-grid3-body" style="{bstyle}">{body}</div><a href="#" class="x-grid3-focus" tabIndex="-1"></a></div>', '</div>', '<div class="x-grid3-resize-marker">&#160;</div>', '<div class="x-grid3-resize-proxy">&#160;</div>', '</div>');
    }

    if (!ts.header) {
      ts.header = new Ext.Template('<table border="0" cellspacing="0" cellpadding="0" style="{tstyle}">', '<thead><tr class="x-grid3-hd-row">{cells}</tr></thead>', '</table>');
    }

    if (!ts.hcell) {
      ts.hcell = new Ext.Template('<td class="x-grid3-hd x-grid3-cell x-grid3-td-{id} {css}" style="{style}"><div {tooltip} {attr} class="x-grid3-hd-inner x-grid3-hd-{id}" unselectable="on" style="{istyle}">', this.grid.enableHdMenu ? '<a class="x-grid3-hd-btn" href="#"></a>' : '', '{value}<img class="x-grid3-sort-icon" src="', Ext.BLANK_IMAGE_URL, '" />', '</div></td>');
    }

    if (!ts.body) {
      ts.body = new Ext.Template('{rows}');
    }

    if (!ts.row) {
      ts.row = new Ext.Template('<div class="x-grid3-row {alt}" style="{tstyle}"><table class="x-grid3-row-table" border="0" cellspacing="0" cellpadding="0" style="{tstyle}">', '<tbody><tr>{cells}</tr>', this.enableRowBody ? '<tr class="x-grid3-row-body-tr" style="{bodyStyle}"><td colspan="{cols}" class="x-grid3-body-cell" tabIndex="0" hidefocus="on"><div class="x-grid3-row-body">{body}</div></td></tr>' : '', '</tbody></table></div>');
    }

    if (!ts.cell) {
      ts.cell = new Ext.Template('<td class="x-grid3-col x-grid3-cell x-grid3-td-{id} {css}" style="{style}" tabIndex="0" {cellAttr}>', '<div class="x-grid3-cell-inner x-grid3-col-{id}" unselectable="on" {attr}>{value}</div>', '</td>');
    }

    for (var k in ts) {
      var t = ts[k];

      if (t && Ext.isFunction(t.compile) && !t.compiled) {
        t.disableFormats = true;
        t.compile();
      }
    }

    this.templates = ts;
    this.colRe = new RegExp('x-grid3-td-([^\\s]+)', '');
  },
  // private
  fly: function fly(el) {
    if (!this._flyweight) {
      this._flyweight = new Ext.Element.Flyweight(document.body);
    }

    this._flyweight.dom = el;
    return this._flyweight;
  },
  // private
  getEditorParent: function getEditorParent() {
    return this.scroller.dom;
  },
  // private
  initElements: function initElements() {
    var E = Ext.Element;
    var el = this.grid.getGridEl().dom.firstChild;
    var cs = el.childNodes;
    this.el = new E(el);
    this.mainWrap = new E(cs[0]);
    this.mainHd = new E(this.mainWrap.dom.firstChild);

    if (this.grid.hideHeaders) {
      this.mainHd.setDisplayed(false);
    }

    this.innerHd = this.mainHd.dom.firstChild;
    this.scroller = new E(this.mainWrap.dom.childNodes[1]);

    if (this.forceFit) {
      this.scroller.setStyle('overflow-x', 'hidden');
    }
    /**
     * <i>Read-only</i>. The GridView's body Element which encapsulates all rows in the Grid.
     * This {@link Ext.Element Element} is only available after the GridPanel has been rendered.
     * @type Ext.Element
     * @property mainBody
     */


    this.mainBody = new E(this.scroller.dom.firstChild);
    this.focusEl = new E(this.scroller.dom.childNodes[1]);
    this.focusEl.swallowEvent('click', true);
    this.resizeMarker = new E(cs[1]);
    this.resizeProxy = new E(cs[2]);
  },
  // private
  getRows: function getRows() {
    return this.hasRows() ? this.mainBody.dom.childNodes : [];
  },
  // finder methods, used with delegation
  // private
  findCell: function findCell(el) {
    if (!el) {
      return false;
    }

    return this.fly(el).findParent(this.cellSelector, this.cellSelectorDepth);
  },

  /**
   * <p>Return the index of the grid column which contains the passed HTMLElement.</p>
   * See also {@link #findRowIndex}
   * @param {HTMLElement} el The target element
   * @return {Number} The column index, or <b>false</b> if the target element is not within a row of this GridView.
   */
  findCellIndex: function findCellIndex(el, requiredCls) {
    var cell = this.findCell(el);

    if (cell && (!requiredCls || this.fly(cell).hasClass(requiredCls))) {
      return this.getCellIndex(cell);
    }

    return false;
  },
  // private
  getCellIndex: function getCellIndex(el) {
    if (el) {
      var m = el.className.match(this.colRe);

      if (m && m[1]) {
        return this.cm.getIndexById(m[1]);
      }
    }

    return false;
  },
  // private
  findHeaderCell: function findHeaderCell(el) {
    var cell = this.findCell(el);
    return cell && this.fly(cell).hasClass(this.hdCls) ? cell : null;
  },
  // private
  findHeaderIndex: function findHeaderIndex(el) {
    return this.findCellIndex(el, this.hdCls);
  },

  /**
   * Return the HtmlElement representing the grid row which contains the passed element.
   * @param {HTMLElement} el The target HTMLElement
   * @return {HTMLElement} The row element, or null if the target element is not within a row of this GridView.
   */
  findRow: function findRow(el) {
    if (!el) {
      return false;
    }

    return this.fly(el).findParent(this.rowSelector, this.rowSelectorDepth);
  },

  /**
   * <p>Return the index of the grid row which contains the passed HTMLElement.</p>
   * See also {@link #findCellIndex}
   * @param {HTMLElement} el The target HTMLElement
   * @return {Number} The row index, or <b>false</b> if the target element is not within a row of this GridView.
   */
  findRowIndex: function findRowIndex(el) {
    var r = this.findRow(el);
    return r ? r.rowIndex : false;
  },

  /**
   * Return the HtmlElement representing the grid row body which contains the passed element.
   * @param {HTMLElement} el The target HTMLElement
   * @return {HTMLElement} The row body element, or null if the target element is not within a row body of this GridView.
   */
  findRowBody: function findRowBody(el) {
    if (!el) {
      return false;
    }

    return this.fly(el).findParent(this.rowBodySelector, this.rowBodySelectorDepth);
  },
  // getter methods for fetching elements dynamically in the grid

  /**
   * Return the <tt>&lt;div></tt> HtmlElement which represents a Grid row for the specified index.
   * @param {Number} index The row index
   * @return {HtmlElement} The div element.
   */
  getRow: function getRow(row) {
    return this.getRows()[row];
  },

  /**
   * Returns the grid's <tt>&lt;td></tt> HtmlElement at the specified coordinates.
   * @param {Number} row The row index in which to find the cell.
   * @param {Number} col The column index of the cell.
   * @return {HtmlElement} The td at the specified coordinates.
   */
  getCell: function getCell(row, col) {
    return this.getRow(row).getElementsByTagName('td')[col];
  },

  /**
   * Return the <tt>&lt;td></tt> HtmlElement which represents the Grid's header cell for the specified column index.
   * @param {Number} index The column index
   * @return {HtmlElement} The td element.
   */
  getHeaderCell: function getHeaderCell(index) {
    return this.mainHd.dom.getElementsByTagName('td')[index];
  },
  // manipulating elements
  // private - use getRowClass to apply custom row classes
  addRowClass: function addRowClass(row, cls) {
    var r = this.getRow(row);

    if (r) {
      this.fly(r).addClass(cls);
    }
  },
  // private
  removeRowClass: function removeRowClass(row, cls) {
    var r = this.getRow(row);

    if (r) {
      this.fly(r).removeClass(cls);
    }
  },
  // private
  removeRow: function removeRow(row) {
    Ext.removeNode(this.getRow(row));
    this.syncFocusEl(row);
  },
  // private
  removeRows: function removeRows(firstRow, lastRow) {
    var bd = this.mainBody.dom;

    for (var rowIndex = firstRow; rowIndex <= lastRow; rowIndex++) {
      Ext.removeNode(bd.childNodes[firstRow]);
    }

    this.syncFocusEl(firstRow);
  },
  // scrolling stuff
  // private
  getScrollState: function getScrollState() {
    var sb = this.scroller.dom;
    return {
      left: sb.scrollLeft,
      top: sb.scrollTop
    };
  },
  // private
  restoreScroll: function restoreScroll(state) {
    var sb = this.scroller.dom;
    sb.scrollLeft = state.left;
    sb.scrollTop = state.top;
  },

  /**
   * Scrolls the grid to the top
   */
  scrollToTop: function scrollToTop() {
    this.scroller.dom.scrollTop = 0;
    this.scroller.dom.scrollLeft = 0;
  },
  // private
  syncScroll: function syncScroll() {
    this.syncHeaderScroll();
    var mb = this.scroller.dom;
    this.grid.fireEvent('bodyscroll', mb.scrollLeft, mb.scrollTop);
  },
  // private
  syncHeaderScroll: function syncHeaderScroll() {
    var mb = this.scroller.dom;
    this.innerHd.scrollLeft = mb.scrollLeft;
    this.innerHd.scrollLeft = mb.scrollLeft; // second time for IE (1/2 time first fails, other browsers ignore)
  },
  // private
  updateSortIcon: function updateSortIcon(col, dir) {
    var sc = this.sortClasses;
    var hds = this.mainHd.select('td').removeClass(sc);
    hds.item(col).addClass(sc[dir == 'DESC' ? 1 : 0]);
  },
  // private
  updateAllColumnWidths: function updateAllColumnWidths() {
    var tw = this.getTotalWidth(),
        clen = this.cm.getColumnCount(),
        ws = [],
        len,
        i;

    for (i = 0; i < clen; i++) {
      ws[i] = this.getColumnWidth(i);
    }

    this.innerHd.firstChild.style.width = this.getOffsetWidth();
    this.innerHd.firstChild.firstChild.style.width = tw;
    this.mainBody.dom.style.width = tw;

    for (i = 0; i < clen; i++) {
      var hd = this.getHeaderCell(i);
      hd.style.width = ws[i];
    }

    var ns = this.getRows(),
        row,
        trow;

    for (i = 0, len = ns.length; i < len; i++) {
      row = ns[i];
      row.style.width = tw;

      if (row.firstChild) {
        row.firstChild.style.width = tw;
        trow = row.firstChild.rows[0];

        for (var j = 0; j < clen; j++) {
          trow.childNodes[j].style.width = ws[j];
        }
      }
    }

    this.onAllColumnWidthsUpdated(ws, tw);
  },
  // private
  updateColumnWidth: function updateColumnWidth(col, width) {
    var w = this.getColumnWidth(col);
    var tw = this.getTotalWidth();
    this.innerHd.firstChild.style.width = this.getOffsetWidth();
    this.innerHd.firstChild.firstChild.style.width = tw;
    this.mainBody.dom.style.width = tw;
    var hd = this.getHeaderCell(col);
    hd.style.width = w;
    var ns = this.getRows(),
        row;

    for (var i = 0, len = ns.length; i < len; i++) {
      row = ns[i];
      row.style.width = tw;

      if (row.firstChild) {
        row.firstChild.style.width = tw;
        row.firstChild.rows[0].childNodes[col].style.width = w;
      }
    }

    this.onColumnWidthUpdated(col, w, tw);
  },
  // private
  updateColumnHidden: function updateColumnHidden(col, hidden) {
    var tw = this.getTotalWidth();
    this.innerHd.firstChild.style.width = this.getOffsetWidth();
    this.innerHd.firstChild.firstChild.style.width = tw;
    this.mainBody.dom.style.width = tw;
    var display = hidden ? 'none' : '';
    var hd = this.getHeaderCell(col);
    hd.style.display = display;
    var ns = this.getRows(),
        row;

    for (var i = 0, len = ns.length; i < len; i++) {
      row = ns[i];
      row.style.width = tw;

      if (row.firstChild) {
        row.firstChild.style.width = tw;
        row.firstChild.rows[0].childNodes[col].style.display = display;
      }
    }

    this.onColumnHiddenUpdated(col, hidden, tw);
    delete this.lastViewWidth; // force recalc

    this.layout();
  },
  // private
  doRender: function doRender(cs, rs, ds, startRow, colCount, stripe) {
    var ts = this.templates,
        ct = ts.cell,
        rt = ts.row,
        last = colCount - 1;
    var tstyle = 'width:' + this.getTotalWidth() + ';'; // buffers

    var buf = [],
        cb,
        c,
        p = {},
        rp = {
      tstyle: tstyle
    },
        r;

    for (var j = 0, len = rs.length; j < len; j++) {
      r = rs[j];
      cb = [];
      var rowIndex = j + startRow;

      for (var i = 0; i < colCount; i++) {
        c = cs[i];
        p.id = c.id;
        p.css = i === 0 ? 'x-grid3-cell-first ' : i == last ? 'x-grid3-cell-last ' : '';
        p.attr = p.cellAttr = '';
        p.value = c.renderer.call(c.scope, r.data[c.name], p, r, rowIndex, i, ds);
        p.style = c.style;

        if (Ext.isEmpty(p.value)) {
          p.value = '&#160;';
        }

        if (this.markDirty && r.dirty && Ext.isDefined(r.modified[c.name])) {
          p.css += ' x-grid3-dirty-cell';
        }

        cb[cb.length] = ct.apply(p);
      }

      var alt = [];

      if (stripe && (rowIndex + 1) % 2 === 0) {
        alt[0] = 'x-grid3-row-alt';
      }

      if (r.dirty) {
        alt[1] = ' x-grid3-dirty-row';
      }

      rp.cols = colCount;

      if (this.getRowClass) {
        alt[2] = this.getRowClass(r, rowIndex, rp, ds);
      }

      rp.alt = alt.join(' ');
      rp.cells = cb.join('');
      buf[buf.length] = rt.apply(rp);
    }

    return buf.join('');
  },
  // private
  processRows: function processRows(startRow, skipStripe) {
    if (!this.ds || this.ds.getCount() < 1) {
      return;
    }

    var rows = this.getRows(),
        len = rows.length,
        i,
        r;
    skipStripe = skipStripe || !this.grid.stripeRows;
    startRow = startRow || 0;

    for (i = 0; i < len; i++) {
      r = rows[i];

      if (r) {
        r.rowIndex = i;

        if (!skipStripe) {
          r.className = r.className.replace(this.rowClsRe, ' ');

          if ((i + 1) % 2 === 0) {
            r.className += ' x-grid3-row-alt';
          }
        }
      }
    } // add first/last-row classes


    if (startRow === 0) {
      Ext.fly(rows[0]).addClass(this.firstRowCls);
    }

    Ext.fly(rows[rows.length - 1]).addClass(this.lastRowCls);
  },
  afterRender: function afterRender() {
    if (!this.ds || !this.cm) {
      return;
    }

    this.mainBody.dom.innerHTML = this.renderRows() || '&#160;';
    this.processRows(0, true);

    if (this.deferEmptyText !== true) {
      this.applyEmptyText();
    }

    this.grid.fireEvent('viewready', this.grid);
  },
  // private
  renderUI: function renderUI() {
    var header = this.renderHeaders();
    var body = this.templates.body.apply({
      rows: '&#160;'
    });
    var html = this.templates.master.apply({
      body: body,
      header: header,
      ostyle: 'width:' + this.getOffsetWidth() + ';',
      bstyle: 'width:' + this.getTotalWidth() + ';'
    });
    var g = this.grid;
    g.getGridEl().dom.innerHTML = html;
    this.initElements(); // get mousedowns early

    Ext.fly(this.innerHd).on('click', this.handleHdDown, this);
    this.mainHd.on({
      scope: this,
      mouseover: this.handleHdOver,
      mouseout: this.handleHdOut,
      mousemove: this.handleHdMove
    });
    this.scroller.on('scroll', this.syncScroll, this);

    if (g.enableColumnResize !== false) {
      this.splitZone = new Ext.grid.GridView.SplitDragZone(g, this.mainHd.dom);
    }

    if (g.enableColumnMove) {
      this.columnDrag = new Ext.grid.GridView.ColumnDragZone(g, this.innerHd);
      this.columnDrop = new Ext.grid.HeaderDropZone(g, this.mainHd.dom);
    }

    if (g.enableHdMenu !== false) {
      this.hmenu = new Ext.menu.Menu({
        id: g.id + '-hctx'
      });
      this.hmenu.add({
        itemId: 'asc',
        text: this.sortAscText,
        cls: 'xg-hmenu-sort-asc'
      }, {
        itemId: 'desc',
        text: this.sortDescText,
        cls: 'xg-hmenu-sort-desc'
      });

      if (g.enableColumnHide !== false) {
        this.colMenu = new Ext.menu.Menu({
          id: g.id + '-hcols-menu'
        });
        this.colMenu.on({
          scope: this,
          beforeshow: this.beforeColMenuShow,
          itemclick: this.handleHdMenuClick
        });
        this.hmenu.add('-', {
          itemId: 'columns',
          hideOnClick: false,
          text: this.columnsText,
          menu: this.colMenu,
          iconCls: 'x-cols-icon'
        });
      }

      this.hmenu.on('itemclick', this.handleHdMenuClick, this);
    }

    if (g.trackMouseOver) {
      this.mainBody.on({
        scope: this,
        mouseover: this.onRowOver,
        mouseout: this.onRowOut
      });
    }

    if (g.enableDragDrop || g.enableDrag) {
      this.dragZone = new Ext.grid.GridDragZone(g, {
        ddGroup: g.ddGroup || 'GridDD'
      });
    }

    this.updateHeaderSortState();
  },
  // private
  processEvent: Ext.emptyFn,
  // private
  layout: function layout() {
    if (!this.mainBody) {
      return; // not rendered
    }

    var g = this.grid;
    var c = g.getGridEl();
    var csize = c.getSize(true);
    var vw = csize.width;

    if (!g.hideHeaders && (vw < 20 || csize.height < 20)) {
      // display: none?
      return;
    }

    if (g.autoHeight) {
      this.scroller.dom.style.overflow = 'visible';

      if (Ext.isWebKit) {
        this.scroller.dom.style.position = 'static';
      }
    } else {
      this.el.setSize(csize.width, csize.height);
      var hdHeight = this.mainHd.getHeight();
      var vh = csize.height - hdHeight;
      this.scroller.setSize(vw, vh);

      if (this.innerHd) {
        this.innerHd.style.width = vw + 'px';
      }
    }

    if (this.forceFit) {
      if (this.lastViewWidth != vw) {
        this.fitColumns(false, false);
        this.lastViewWidth = vw;
      }
    } else {
      this.autoExpand();
      this.syncHeaderScroll();
    }

    this.onLayout(vw, vh);
  },
  // template functions for subclasses and plugins
  // these functions include precalculated values
  onLayout: function onLayout(vw, vh) {// do nothing
  },
  onColumnWidthUpdated: function onColumnWidthUpdated(col, w, tw) {//template method
  },
  onAllColumnWidthsUpdated: function onAllColumnWidthsUpdated(ws, tw) {//template method
  },
  onColumnHiddenUpdated: function onColumnHiddenUpdated(col, hidden, tw) {// template method
  },
  updateColumnText: function updateColumnText(col, text) {// template method
  },
  afterMove: function afterMove(colIndex) {// template method
  },

  /* ----------------------------------- Core Specific -------------------------------------------*/
  // private
  init: function init(grid) {
    this.grid = grid;
    this.initTemplates();
    this.initData(grid.store, grid.colModel);
    this.initUI(grid);
  },
  // private
  getColumnId: function getColumnId(index) {
    return this.cm.getColumnId(index);
  },
  // private 
  getOffsetWidth: function getOffsetWidth() {
    return this.cm.getTotalWidth() + this.getScrollOffset() + 'px';
  },
  getScrollOffset: function getScrollOffset() {
    return Ext.num(this.scrollOffset, Ext.getScrollBarWidth());
  },
  // private
  renderHeaders: function renderHeaders() {
    var cm = this.cm,
        ts = this.templates,
        ct = ts.hcell,
        cb = [],
        p = {},
        len = cm.getColumnCount(),
        last = len - 1;

    for (var i = 0; i < len; i++) {
      p.id = cm.getColumnId(i);
      p.value = cm.getColumnHeader(i) || '';
      p.style = this.getColumnStyle(i, true);
      p.tooltip = this.getColumnTooltip(i);
      p.css = i === 0 ? 'x-grid3-cell-first ' : i == last ? 'x-grid3-cell-last ' : '';

      if (cm.config[i].align == 'right') {
        p.istyle = 'padding-right:16px';
      } else {
        delete p.istyle;
      }

      cb[cb.length] = ct.apply(p);
    }

    return ts.header.apply({
      cells: cb.join(''),
      tstyle: 'width:' + this.getTotalWidth() + ';'
    });
  },
  // private
  getColumnTooltip: function getColumnTooltip(i) {
    var tt = this.cm.getColumnTooltip(i);

    if (tt) {
      if (Ext.QuickTips.isEnabled()) {
        return 'ext:qtip="' + tt + '"';
      } else {
        return 'title="' + tt + '"';
      }
    }

    return '';
  },
  // private
  beforeUpdate: function beforeUpdate() {
    this.grid.stopEditing(true);
  },
  // private
  updateHeaders: function updateHeaders() {
    this.innerHd.firstChild.innerHTML = this.renderHeaders();
    this.innerHd.firstChild.style.width = this.getOffsetWidth();
    this.innerHd.firstChild.firstChild.style.width = this.getTotalWidth();
  },

  /**
   * Focuses the specified row.
   * @param {Number} row The row index
   */
  focusRow: function focusRow(row) {
    this.focusCell(row, 0, false);
  },

  /**
   * Focuses the specified cell.
   * @param {Number} row The row index
   * @param {Number} col The column index
   */
  focusCell: function focusCell(row, col, hscroll) {
    this.syncFocusEl(this.ensureVisible(row, col, hscroll));

    if (Ext.isGecko) {
      this.focusEl.focus();
    } else {
      this.focusEl.focus.defer(1, this.focusEl);
    }
  },
  resolveCell: function resolveCell(row, col, hscroll) {
    if (!Ext.isNumber(row)) {
      row = row.rowIndex;
    }

    if (!this.ds) {
      return null;
    }

    if (row < 0 || row >= this.ds.getCount()) {
      return null;
    }

    col = col !== undefined ? col : 0;
    var rowEl = this.getRow(row),
        cm = this.cm,
        colCount = cm.getColumnCount(),
        cellEl;

    if (!(hscroll === false && col === 0)) {
      while (col < colCount && cm.isHidden(col)) {
        col++;
      }

      cellEl = this.getCell(row, col);
    }

    return {
      row: rowEl,
      cell: cellEl
    };
  },
  getResolvedXY: function getResolvedXY(resolved) {
    if (!resolved) {
      return null;
    }

    var s = this.scroller.dom,
        c = resolved.cell,
        r = resolved.row;
    return c ? Ext.fly(c).getXY() : [this.el.getX(), Ext.fly(r).getY()];
  },
  syncFocusEl: function syncFocusEl(row, col, hscroll) {
    var xy = row;

    if (!Ext.isArray(xy)) {
      row = Math.min(row, Math.max(0, this.getRows().length - 1));
      xy = this.getResolvedXY(this.resolveCell(row, col, hscroll));
    }

    this.focusEl.setXY(xy || this.scroller.getXY());
  },
  ensureVisible: function ensureVisible(row, col, hscroll) {
    var resolved = this.resolveCell(row, col, hscroll);

    if (!resolved || !resolved.row) {
      return;
    }

    var rowEl = resolved.row,
        cellEl = resolved.cell,
        c = this.scroller.dom,
        ctop = 0,
        p = rowEl,
        stop = this.el.dom;

    while (p && p != stop) {
      ctop += p.offsetTop;
      p = p.offsetParent;
    }

    ctop -= this.mainHd.dom.offsetHeight;
    stop = parseInt(c.scrollTop, 10);
    var cbot = ctop + rowEl.offsetHeight,
        ch = c.clientHeight,
        sbot = stop + ch;

    if (ctop < stop) {
      c.scrollTop = ctop;
    } else if (cbot > sbot) {
      c.scrollTop = cbot - ch;
    }

    if (hscroll !== false) {
      var cleft = parseInt(cellEl.offsetLeft, 10);
      var cright = cleft + cellEl.offsetWidth;
      var sleft = parseInt(c.scrollLeft, 10);
      var sright = sleft + c.clientWidth;

      if (cleft < sleft) {
        c.scrollLeft = cleft;
      } else if (cright > sright) {
        c.scrollLeft = cright - c.clientWidth;
      }
    }

    return this.getResolvedXY(resolved);
  },
  // private
  insertRows: function insertRows(dm, firstRow, lastRow, isUpdate) {
    var last = dm.getCount() - 1;

    if (!isUpdate && firstRow === 0 && lastRow >= last) {
      this.fireEvent('beforerowsinserted', this, firstRow, lastRow);
      this.refresh();
      this.fireEvent('rowsinserted', this, firstRow, lastRow);
    } else {
      if (!isUpdate) {
        this.fireEvent('beforerowsinserted', this, firstRow, lastRow);
      }

      var html = this.renderRows(firstRow, lastRow),
          before = this.getRow(firstRow);

      if (before) {
        if (firstRow === 0) {
          Ext.fly(this.getRow(0)).removeClass(this.firstRowCls);
        }

        Ext.DomHelper.insertHtml('beforeBegin', before, html);
      } else {
        var r = this.getRow(last - 1);

        if (r) {
          Ext.fly(r).removeClass(this.lastRowCls);
        }

        Ext.DomHelper.insertHtml('beforeEnd', this.mainBody.dom, html);
      }

      if (!isUpdate) {
        this.fireEvent('rowsinserted', this, firstRow, lastRow);
        this.processRows(firstRow);
      } else if (firstRow === 0 || firstRow >= last) {
        //ensure first/last row is kept after an update.
        Ext.fly(this.getRow(firstRow)).addClass(firstRow === 0 ? this.firstRowCls : this.lastRowCls);
      }
    }

    this.syncFocusEl(firstRow);
  },
  // private
  deleteRows: function deleteRows(dm, firstRow, lastRow) {
    if (dm.getRowCount() < 1) {
      this.refresh();
    } else {
      this.fireEvent('beforerowsdeleted', this, firstRow, lastRow);
      this.removeRows(firstRow, lastRow);
      this.processRows(firstRow);
      this.fireEvent('rowsdeleted', this, firstRow, lastRow);
    }
  },
  // private
  getColumnStyle: function getColumnStyle(col, isHeader) {
    var style = !isHeader ? this.cm.config[col].css || '' : '';
    style += 'width:' + this.getColumnWidth(col) + ';';

    if (this.cm.isHidden(col)) {
      style += 'display:none;';
    }

    var align = this.cm.config[col].align;

    if (align) {
      style += 'text-align:' + align + ';';
    }

    return style;
  },
  // private
  getColumnWidth: function getColumnWidth(col) {
    var w = this.cm.getColumnWidth(col);

    if (Ext.isNumber(w)) {
      return (Ext.isBorderBox || Ext.isWebKit && !Ext.isSafari2 ? w : w - this.borderWidth > 0 ? w - this.borderWidth : 0) + 'px';
    }

    return w;
  },
  // private
  getTotalWidth: function getTotalWidth() {
    return this.cm.getTotalWidth() + 'px';
  },
  // private
  fitColumns: function fitColumns(preventRefresh, onlyExpand, omitColumn) {
    var cm = this.cm,
        i;
    var tw = cm.getTotalWidth(false);
    var aw = this.grid.getGridEl().getWidth(true) - this.getScrollOffset();

    if (aw < 20) {
      // not initialized, so don't screw up the default widths
      return;
    }

    var extra = aw - tw;

    if (extra === 0) {
      return false;
    }

    var vc = cm.getColumnCount(true);
    var ac = vc - (Ext.isNumber(omitColumn) ? 1 : 0);

    if (ac === 0) {
      ac = 1;
      omitColumn = undefined;
    }

    var colCount = cm.getColumnCount();
    var cols = [];
    var extraCol = 0;
    var width = 0;
    var w;

    for (i = 0; i < colCount; i++) {
      if (!cm.isHidden(i) && !cm.isFixed(i) && i !== omitColumn) {
        w = cm.getColumnWidth(i);
        cols.push(i);
        extraCol = i;
        cols.push(w);
        width += w;
      }
    }

    var frac = (aw - cm.getTotalWidth()) / width;

    while (cols.length) {
      w = cols.pop();
      i = cols.pop();
      cm.setColumnWidth(i, Math.max(this.grid.minColumnWidth, Math.floor(w + w * frac)), true);
    }

    if ((tw = cm.getTotalWidth(false)) > aw) {
      var adjustCol = ac != vc ? omitColumn : extraCol;
      cm.setColumnWidth(adjustCol, Math.max(1, cm.getColumnWidth(adjustCol) - (tw - aw)), true);
    }

    if (preventRefresh !== true) {
      this.updateAllColumnWidths();
    }

    return true;
  },
  // private
  autoExpand: function autoExpand(preventUpdate) {
    var g = this.grid,
        cm = this.cm;

    if (!this.userResized && g.autoExpandColumn) {
      var tw = cm.getTotalWidth(false);
      var aw = this.grid.getGridEl().getWidth(true) - this.getScrollOffset();

      if (tw != aw) {
        var ci = cm.getIndexById(g.autoExpandColumn);
        var currentWidth = cm.getColumnWidth(ci);
        var cw = Math.min(Math.max(aw - tw + currentWidth, g.autoExpandMin), g.autoExpandMax);

        if (cw != currentWidth) {
          cm.setColumnWidth(ci, cw, true);

          if (preventUpdate !== true) {
            this.updateColumnWidth(ci, cw);
          }
        }
      }
    }
  },
  // private
  getColumnData: function getColumnData() {
    // build a map for all the columns
    var cs = [],
        cm = this.cm,
        colCount = cm.getColumnCount();

    for (var i = 0; i < colCount; i++) {
      var name = cm.getDataIndex(i);
      cs[i] = {
        name: !Ext.isDefined(name) ? this.ds.fields.get(i).name : name,
        renderer: cm.getRenderer(i),
        scope: cm.getRendererScope(i),
        id: cm.getColumnId(i),
        style: this.getColumnStyle(i)
      };
    }

    return cs;
  },
  // private
  renderRows: function renderRows(startRow, endRow) {
    // pull in all the crap needed to render rows
    var g = this.grid,
        cm = g.colModel,
        ds = g.store,
        stripe = g.stripeRows;
    var colCount = cm.getColumnCount();

    if (ds.getCount() < 1) {
      return '';
    }

    var cs = this.getColumnData();
    startRow = startRow || 0;
    endRow = !Ext.isDefined(endRow) ? ds.getCount() - 1 : endRow; // records to render

    var rs = ds.getRange(startRow, endRow);
    return this.doRender(cs, rs, ds, startRow, colCount, stripe);
  },
  // private
  renderBody: function renderBody() {
    var markup = this.renderRows() || '&#160;';
    return this.templates.body.apply({
      rows: markup
    });
  },
  // private
  refreshRow: function refreshRow(record) {
    var ds = this.ds,
        index;

    if (Ext.isNumber(record)) {
      index = record;
      record = ds.getAt(index);

      if (!record) {
        return;
      }
    } else {
      index = ds.indexOf(record);

      if (index < 0) {
        return;
      }
    }

    this.insertRows(ds, index, index, true);
    this.getRow(index).rowIndex = index;
    this.onRemove(ds, record, index + 1, true);
    this.fireEvent('rowupdated', this, index, record);
  },

  /**
   * Refreshs the grid UI
   * @param {Boolean} headersToo (optional) True to also refresh the headers
   */
  refresh: function refresh(headersToo) {
    if (!this.grid) {
      return;
    }

    this.fireEvent('beforerefresh', this);
    this.grid.stopEditing(true);
    var result = this.renderBody();
    this.mainBody.update(result).setWidth(this.getTotalWidth());

    if (headersToo === true) {
      this.updateHeaders();
      this.updateHeaderSortState();
    }

    this.processRows(0, true);
    this.layout();
    this.applyEmptyText();
    this.fireEvent('refresh', this);
  },
  // private
  applyEmptyText: function applyEmptyText() {
    if (this.emptyText && !this.hasRows()) {
      this.mainBody.update('<div class="x-grid-empty">' + this.emptyText + '</div>');
    }
  },
  // private
  updateHeaderSortState: function updateHeaderSortState() {
    var state = this.ds.getSortState();

    if (!state) {
      return;
    }

    if (!this.sortState || this.sortState.field != state.field || this.sortState.direction != state.direction) {
      this.grid.fireEvent('sortchange', this.grid, state);
    }

    this.sortState = state;
    var sortColumn = this.cm.findColumnIndex(state.field);

    if (sortColumn != -1) {
      var sortDir = state.direction;
      this.updateSortIcon(sortColumn, sortDir);
    }
  },
  // private
  clearHeaderSortState: function clearHeaderSortState() {
    if (!this.sortState) {
      return;
    }

    this.grid.fireEvent('sortchange', this.grid, null);
    this.mainHd.select('td').removeClass(this.sortClasses);
    delete this.sortState;
  },
  // private
  destroy: function destroy() {
    if (this.colMenu) {
      Ext.menu.MenuMgr.unregister(this.colMenu);
      this.colMenu.destroy();
      delete this.colMenu;
    }

    if (this.hmenu) {
      Ext.menu.MenuMgr.unregister(this.hmenu);
      this.hmenu.destroy();
      delete this.hmenu;
    }

    this.initData(null, null);
    this.purgeListeners();
    Ext.fly(this.innerHd).un("click", this.handleHdDown, this);

    if (this.grid.enableColumnMove) {
      Ext.destroy(this.columnDrag.el, this.columnDrag.proxy.ghost, this.columnDrag.proxy.el, this.columnDrop.el, this.columnDrop.proxyTop, this.columnDrop.proxyBottom, this.columnDrag.dragData.ddel, this.columnDrag.dragData.header);

      if (this.columnDrag.proxy.anim) {
        Ext.destroy(this.columnDrag.proxy.anim);
      }

      delete this.columnDrag.proxy.ghost;
      delete this.columnDrag.dragData.ddel;
      delete this.columnDrag.dragData.header;
      this.columnDrag.destroy();
      delete Ext.dd.DDM.locationCache[this.columnDrag.id];
      delete this.columnDrag._domRef;
      delete this.columnDrop.proxyTop;
      delete this.columnDrop.proxyBottom;
      this.columnDrop.destroy();
      delete Ext.dd.DDM.locationCache["gridHeader" + this.grid.getGridEl().id];
      delete this.columnDrop._domRef;
      delete Ext.dd.DDM.ids[this.columnDrop.ddGroup];
    }

    if (this.splitZone) {
      // enableColumnResize
      this.splitZone.destroy();
      delete this.splitZone._domRef;
      delete Ext.dd.DDM.ids["gridSplitters" + this.grid.getGridEl().id];
    }

    Ext.fly(this.innerHd).removeAllListeners();
    Ext.removeNode(this.innerHd);
    delete this.innerHd;
    Ext.destroy(this.el, this.mainWrap, this.mainHd, this.scroller, this.mainBody, this.focusEl, this.resizeMarker, this.resizeProxy, this.activeHdBtn, this.dragZone, this.splitZone, this._flyweight);
    delete this.grid.container;

    if (this.dragZone) {
      this.dragZone.destroy();
    }

    Ext.dd.DDM.currentTarget = null;
    delete Ext.dd.DDM.locationCache[this.grid.getGridEl().id];
    Ext.EventManager.removeResizeListener(this.onWindowResize, this);
  },
  // private
  onDenyColumnHide: function onDenyColumnHide() {},
  // private
  render: function render() {
    if (this.autoFill) {
      var ct = this.grid.ownerCt;

      if (ct && ct.getLayout()) {
        ct.on('afterlayout', function () {
          this.fitColumns(true, true);
          this.updateHeaders();
        }, this, {
          single: true
        });
      } else {
        this.fitColumns(true, true);
      }
    } else if (this.forceFit) {
      this.fitColumns(true, false);
    } else if (this.grid.autoExpandColumn) {
      this.autoExpand(true);
    }

    this.renderUI();
  },

  /* --------------------------------- Model Events and Handlers --------------------------------*/
  // private
  initData: function initData(ds, cm) {
    if (this.ds) {
      this.ds.un('load', this.onLoad, this);
      this.ds.un('datachanged', this.onDataChange, this);
      this.ds.un('add', this.onAdd, this);
      this.ds.un('remove', this.onRemove, this);
      this.ds.un('update', this.onUpdate, this);
      this.ds.un('clear', this.onClear, this);

      if (this.ds !== ds && this.ds.autoDestroy) {
        this.ds.destroy();
      }
    }

    if (ds) {
      ds.on({
        scope: this,
        load: this.onLoad,
        datachanged: this.onDataChange,
        add: this.onAdd,
        remove: this.onRemove,
        update: this.onUpdate,
        clear: this.onClear
      });
    }

    this.ds = ds;

    if (this.cm) {
      this.cm.un('configchange', this.onColConfigChange, this);
      this.cm.un('widthchange', this.onColWidthChange, this);
      this.cm.un('headerchange', this.onHeaderChange, this);
      this.cm.un('hiddenchange', this.onHiddenChange, this);
      this.cm.un('columnmoved', this.onColumnMove, this);
    }

    if (cm) {
      delete this.lastViewWidth;
      cm.on({
        scope: this,
        configchange: this.onColConfigChange,
        widthchange: this.onColWidthChange,
        headerchange: this.onHeaderChange,
        hiddenchange: this.onHiddenChange,
        columnmoved: this.onColumnMove
      });
    }

    this.cm = cm;
  },
  // private
  onDataChange: function onDataChange() {
    this.refresh();
    this.updateHeaderSortState();
    this.syncFocusEl(0);
  },
  // private
  onClear: function onClear() {
    this.refresh();
    this.syncFocusEl(0);
  },
  // private
  onUpdate: function onUpdate(ds, record) {
    this.refreshRow(record);
  },
  // private
  onAdd: function onAdd(ds, records, index) {
    this.insertRows(ds, index, index + (records.length - 1));
  },
  // private
  onRemove: function onRemove(ds, record, index, isUpdate) {
    if (isUpdate !== true) {
      this.fireEvent('beforerowremoved', this, index, record);
    }

    this.removeRow(index);

    if (isUpdate !== true) {
      this.processRows(index);
      this.applyEmptyText();
      this.fireEvent('rowremoved', this, index, record);
    }
  },
  // private
  onLoad: function onLoad() {
    this.scrollToTop.defer(Ext.isGecko ? 1 : 0, this);
  },
  // private
  onColWidthChange: function onColWidthChange(cm, col, width) {
    this.updateColumnWidth(col, width);
  },
  // private
  onHeaderChange: function onHeaderChange(cm, col, text) {
    this.updateHeaders();
  },
  // private
  onHiddenChange: function onHiddenChange(cm, col, hidden) {
    this.updateColumnHidden(col, hidden);
  },
  // private
  onColumnMove: function onColumnMove(cm, oldIndex, newIndex) {
    this.indexMap = null;
    var s = this.getScrollState();
    this.refresh(true);
    this.restoreScroll(s);
    this.afterMove(newIndex);
    this.grid.fireEvent('columnmove', oldIndex, newIndex);
  },
  // private
  onColConfigChange: function onColConfigChange() {
    delete this.lastViewWidth;
    this.indexMap = null;
    this.refresh(true);
  },

  /* -------------------- UI Events and Handlers ------------------------------ */
  // private
  initUI: function initUI(grid) {
    grid.on('headerclick', this.onHeaderClick, this);
  },
  // private
  initEvents: function initEvents() {},
  // private
  onHeaderClick: function onHeaderClick(g, index) {
    if (this.headersDisabled || !this.cm.isSortable(index)) {
      return;
    }

    g.stopEditing(true);
    g.store.sort(this.cm.getDataIndex(index));
  },
  // private
  onRowOver: function onRowOver(e, t) {
    var row;

    if ((row = this.findRowIndex(t)) !== false) {
      this.addRowClass(row, 'x-grid3-row-over');
    }
  },
  // private
  onRowOut: function onRowOut(e, t) {
    var row;

    if ((row = this.findRowIndex(t)) !== false && !e.within(this.getRow(row), true)) {
      this.removeRowClass(row, 'x-grid3-row-over');
    }
  },
  // private
  handleWheel: function handleWheel(e) {
    e.stopPropagation();
  },
  // private
  onRowSelect: function onRowSelect(row) {
    this.addRowClass(row, this.selectedRowClass);
  },
  // private
  onRowDeselect: function onRowDeselect(row) {
    this.removeRowClass(row, this.selectedRowClass);
  },
  // private
  onCellSelect: function onCellSelect(row, col) {
    var cell = this.getCell(row, col);

    if (cell) {
      this.fly(cell).addClass('x-grid3-cell-selected');
    }
  },
  // private
  onCellDeselect: function onCellDeselect(row, col) {
    var cell = this.getCell(row, col);

    if (cell) {
      this.fly(cell).removeClass('x-grid3-cell-selected');
    }
  },
  // private
  onColumnSplitterMoved: function onColumnSplitterMoved(i, w) {
    this.userResized = true;
    var cm = this.grid.colModel;
    cm.setColumnWidth(i, w, true);

    if (this.forceFit) {
      this.fitColumns(true, false, i);
      this.updateAllColumnWidths();
    } else {
      this.updateColumnWidth(i, w);
      this.syncHeaderScroll();
    }

    this.grid.fireEvent('columnresize', i, w);
  },
  // private
  handleHdMenuClick: function handleHdMenuClick(item) {
    var index = this.hdCtxIndex,
        cm = this.cm,
        ds = this.ds,
        id = item.getItemId();

    switch (id) {
      case 'asc':
        ds.sort(cm.getDataIndex(index), 'ASC');
        break;

      case 'desc':
        ds.sort(cm.getDataIndex(index), 'DESC');
        break;

      default:
        index = cm.getIndexById(id.substr(4));

        if (index != -1) {
          if (item.checked && cm.getColumnsBy(this.isHideableColumn, this).length <= 1) {
            this.onDenyColumnHide();
            return false;
          }

          cm.setHidden(index, item.checked);
        }

    }

    return true;
  },
  // private
  isHideableColumn: function isHideableColumn(c) {
    return !c.hidden && !c.fixed;
  },
  // private
  beforeColMenuShow: function beforeColMenuShow() {
    var cm = this.cm,
        colCount = cm.getColumnCount();
    this.colMenu.removeAll();

    for (var i = 0; i < colCount; i++) {
      if (cm.config[i].fixed !== true && cm.config[i].hideable !== false) {
        this.colMenu.add(new Ext.menu.CheckItem({
          itemId: 'col-' + cm.getColumnId(i),
          text: cm.getColumnHeader(i),
          checked: !cm.isHidden(i),
          hideOnClick: false,
          disabled: cm.config[i].hideable === false
        }));
      }
    }
  },
  // private
  handleHdDown: function handleHdDown(e, t) {
    if (Ext.fly(t).hasClass('x-grid3-hd-btn')) {
      e.stopEvent();
      var hd = this.findHeaderCell(t);
      Ext.fly(hd).addClass('x-grid3-hd-menu-open');
      var index = this.getCellIndex(hd);
      this.hdCtxIndex = index;
      var ms = this.hmenu.items,
          cm = this.cm;
      ms.get('asc').setDisabled(!cm.isSortable(index));
      ms.get('desc').setDisabled(!cm.isSortable(index));
      this.hmenu.on('hide', function () {
        Ext.fly(hd).removeClass('x-grid3-hd-menu-open');
      }, this, {
        single: true
      });
      this.hmenu.show(t, 'tl-bl?');
    }
  },
  // private
  handleHdOver: function handleHdOver(e, t) {
    var hd = this.findHeaderCell(t);

    if (hd && !this.headersDisabled) {
      this.activeHdRef = t;
      this.activeHdIndex = this.getCellIndex(hd);
      var fly = this.fly(hd);
      this.activeHdRegion = fly.getRegion();

      if (!this.cm.isMenuDisabled(this.activeHdIndex)) {
        fly.addClass('x-grid3-hd-over');
        this.activeHdBtn = fly.child('.x-grid3-hd-btn');

        if (this.activeHdBtn) {
          this.activeHdBtn.dom.style.height = hd.firstChild.offsetHeight - 1 + 'px';
        }
      }
    }
  },
  // private
  handleHdMove: function handleHdMove(e, t) {
    var hd = this.findHeaderCell(this.activeHdRef);

    if (hd && !this.headersDisabled) {
      var hw = this.splitHandleWidth || 5,
          r = this.activeHdRegion,
          x = e.getPageX(),
          ss = hd.style,
          cur = '';

      if (this.grid.enableColumnResize !== false) {
        if (x - r.left <= hw && this.cm.isResizable(this.activeHdIndex - 1)) {
          cur = Ext.isAir ? 'move' : Ext.isWebKit ? 'e-resize' : 'col-resize'; // col-resize not always supported
        } else if (r.right - x <= (!this.activeHdBtn ? hw : 2) && this.cm.isResizable(this.activeHdIndex)) {
          cur = Ext.isAir ? 'move' : Ext.isWebKit ? 'w-resize' : 'col-resize';
        }
      }

      ss.cursor = cur;
    }
  },
  // private
  handleHdOut: function handleHdOut(e, t) {
    var hd = this.findHeaderCell(t);

    if (hd && (!Ext.isIE || !e.within(hd, true))) {
      this.activeHdRef = null;
      this.fly(hd).removeClass('x-grid3-hd-over');
      hd.style.cursor = '';
    }
  },
  // private
  hasRows: function hasRows() {
    var fc = this.mainBody.dom.firstChild;
    return fc && fc.nodeType == 1 && fc.className != 'x-grid-empty';
  },
  // back compat
  bind: function bind(d, c) {
    this.initData(d, c);
  }
}); // private
// This is a support class used internally by the Grid components

Ext.grid.GridView.SplitDragZone = function (grid, hd) {
  this.grid = grid;
  this.view = grid.getView();
  this.marker = this.view.resizeMarker;
  this.proxy = this.view.resizeProxy;
  Ext.grid.GridView.SplitDragZone.superclass.constructor.call(this, hd, 'gridSplitters' + this.grid.getGridEl().id, {
    dragElId: Ext.id(this.proxy.dom),
    resizeFrame: false
  });
  this.scroll = false;
  this.hw = this.view.splitHandleWidth || 5;
};

Ext.extend(Ext.grid.GridView.SplitDragZone, Ext.dd.DDProxy, {
  b4StartDrag: function b4StartDrag(x, y) {
    this.view.headersDisabled = true;
    var h = this.view.mainWrap.getHeight();
    this.marker.setHeight(h);
    this.marker.show();
    this.marker.alignTo(this.view.getHeaderCell(this.cellIndex), 'tl-tl', [-2, 0]);
    this.proxy.setHeight(h);
    var w = this.cm.getColumnWidth(this.cellIndex);
    var minw = Math.max(w - this.grid.minColumnWidth, 0);
    this.resetConstraints();
    this.setXConstraint(minw, 1000);
    this.setYConstraint(0, 0);
    this.minX = x - minw;
    this.maxX = x + 1000;
    this.startPos = x;
    Ext.dd.DDProxy.prototype.b4StartDrag.call(this, x, y);
  },
  allowHeaderDrag: function allowHeaderDrag(e) {
    return true;
  },
  handleMouseDown: function handleMouseDown(e) {
    var t = this.view.findHeaderCell(e.getTarget());

    if (t && this.allowHeaderDrag(e)) {
      var xy = this.view.fly(t).getXY(),
          x = xy[0],
          y = xy[1];
      var exy = e.getXY(),
          ex = exy[0];
      var w = t.offsetWidth,
          adjust = false;

      if (ex - x <= this.hw) {
        adjust = -1;
      } else if (x + w - ex <= this.hw) {
        adjust = 0;
      }

      if (adjust !== false) {
        this.cm = this.grid.colModel;
        var ci = this.view.getCellIndex(t);

        if (adjust == -1) {
          if (ci + adjust < 0) {
            return;
          }

          while (this.cm.isHidden(ci + adjust)) {
            --adjust;

            if (ci + adjust < 0) {
              return;
            }
          }
        }

        this.cellIndex = ci + adjust;
        this.split = t.dom;

        if (this.cm.isResizable(this.cellIndex) && !this.cm.isFixed(this.cellIndex)) {
          Ext.grid.GridView.SplitDragZone.superclass.handleMouseDown.apply(this, arguments);
        }
      } else if (this.view.columnDrag) {
        this.view.columnDrag.callHandleMouseDown(e);
      }
    }
  },
  endDrag: function endDrag(e) {
    this.marker.hide();
    var v = this.view;
    var endX = Math.max(this.minX, e.getPageX());
    var diff = endX - this.startPos;
    v.onColumnSplitterMoved(this.cellIndex, this.cm.getColumnWidth(this.cellIndex) + diff);
    setTimeout(function () {
      v.headersDisabled = false;
    }, 50);
  },
  autoOffset: function autoOffset() {
    this.setDelta(0, 0);
  }
});

/***/ }),
/* 892 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
// private
// This is a support class used internally by the Grid components
Ext.grid.HeaderDragZone = Ext.extend(Ext.dd.DragZone, {
  maxDragWidth: 120,
  constructor: function constructor(grid, hd, hd2) {
    this.grid = grid;
    this.view = grid.getView();
    this.ddGroup = "gridHeader" + this.grid.getGridEl().id;
    Ext.grid.HeaderDragZone.superclass.constructor.call(this, hd);

    if (hd2) {
      this.setHandleElId(Ext.id(hd));
      this.setOuterHandleElId(Ext.id(hd2));
    }

    this.scroll = false;
  },
  getDragData: function getDragData(e) {
    var t = Ext.lib.Event.getTarget(e);
    var h = this.view.findHeaderCell(t);

    if (h) {
      return {
        ddel: h.firstChild,
        header: h
      };
    }

    return false;
  },
  onInitDrag: function onInitDrag(e) {
    this.view.headersDisabled = true;
    var clone = this.dragData.ddel.cloneNode(true);
    clone.id = Ext.id();
    clone.style.width = Math.min(this.dragData.header.offsetWidth, this.maxDragWidth) + "px";
    this.proxy.update(clone);
    return true;
  },
  afterValidDrop: function afterValidDrop() {
    var v = this.view;
    setTimeout(function () {
      v.headersDisabled = false;
    }, 50);
  },
  afterInvalidDrop: function afterInvalidDrop() {
    var v = this.view;
    setTimeout(function () {
      v.headersDisabled = false;
    }, 50);
  }
}); // private
// This is a support class used internally by the Grid components

Ext.grid.HeaderDropZone = Ext.extend(Ext.dd.DropZone, {
  proxyOffsets: [-4, -9],
  fly: Ext.Element.fly,
  constructor: function constructor(grid, hd, hd2) {
    this.grid = grid;
    this.view = grid.getView(); // split the proxies so they don't interfere with mouse events

    this.proxyTop = Ext.DomHelper.append(document.body, {
      cls: "col-move-top",
      html: "&#160;"
    }, true);
    this.proxyBottom = Ext.DomHelper.append(document.body, {
      cls: "col-move-bottom",
      html: "&#160;"
    }, true);

    this.proxyTop.hide = this.proxyBottom.hide = function () {
      this.setLeftTop(-100, -100);
      this.setStyle("visibility", "hidden");
    };

    this.ddGroup = "gridHeader" + this.grid.getGridEl().id; // temporarily disabled
    //Ext.dd.ScrollManager.register(this.view.scroller.dom);

    Ext.grid.HeaderDropZone.superclass.constructor.call(this, grid.getGridEl().dom);
  },
  getTargetFromEvent: function getTargetFromEvent(e) {
    var t = Ext.lib.Event.getTarget(e);
    var cindex = this.view.findCellIndex(t);

    if (cindex !== false) {
      return this.view.getHeaderCell(cindex);
    }
  },
  nextVisible: function nextVisible(h) {
    var v = this.view,
        cm = this.grid.colModel;
    h = h.nextSibling;

    while (h) {
      if (!cm.isHidden(v.getCellIndex(h))) {
        return h;
      }

      h = h.nextSibling;
    }

    return null;
  },
  prevVisible: function prevVisible(h) {
    var v = this.view,
        cm = this.grid.colModel;
    h = h.prevSibling;

    while (h) {
      if (!cm.isHidden(v.getCellIndex(h))) {
        return h;
      }

      h = h.prevSibling;
    }

    return null;
  },
  positionIndicator: function positionIndicator(h, n, e) {
    var x = Ext.lib.Event.getPageX(e);
    var r = Ext.lib.Dom.getRegion(n.firstChild);
    var px,
        pt,
        py = r.top + this.proxyOffsets[1];

    if (r.right - x <= (r.right - r.left) / 2) {
      px = r.right + this.view.borderWidth;
      pt = "after";
    } else {
      px = r.left;
      pt = "before";
    }

    if (this.grid.colModel.isFixed(this.view.getCellIndex(n))) {
      return false;
    }

    px += this.proxyOffsets[0];
    this.proxyTop.setLeftTop(px, py);
    this.proxyTop.show();

    if (!this.bottomOffset) {
      this.bottomOffset = this.view.mainHd.getHeight();
    }

    this.proxyBottom.setLeftTop(px, py + this.proxyTop.dom.offsetHeight + this.bottomOffset);
    this.proxyBottom.show();
    return pt;
  },
  onNodeEnter: function onNodeEnter(n, dd, e, data) {
    if (data.header != n) {
      this.positionIndicator(data.header, n, e);
    }
  },
  onNodeOver: function onNodeOver(n, dd, e, data) {
    var result = false;

    if (data.header != n) {
      result = this.positionIndicator(data.header, n, e);
    }

    if (!result) {
      this.proxyTop.hide();
      this.proxyBottom.hide();
    }

    return result ? this.dropAllowed : this.dropNotAllowed;
  },
  onNodeOut: function onNodeOut(n, dd, e, data) {
    this.proxyTop.hide();
    this.proxyBottom.hide();
  },
  onNodeDrop: function onNodeDrop(n, dd, e, data) {
    var h = data.header;

    if (h != n) {
      var cm = this.grid.colModel;
      var x = Ext.lib.Event.getPageX(e);
      var r = Ext.lib.Dom.getRegion(n.firstChild);
      var pt = r.right - x <= (r.right - r.left) / 2 ? "after" : "before";
      var oldIndex = this.view.getCellIndex(h);
      var newIndex = this.view.getCellIndex(n);

      if (pt == "after") {
        newIndex++;
      }

      if (oldIndex < newIndex) {
        newIndex--;
      }

      cm.moveColumn(oldIndex, newIndex);
      return true;
    }

    return false;
  }
});
Ext.grid.GridView.ColumnDragZone = Ext.extend(Ext.grid.HeaderDragZone, {
  constructor: function constructor(grid, hd) {
    Ext.grid.GridView.ColumnDragZone.superclass.constructor.call(this, grid, hd, null);
    this.proxy.el.addClass('x-grid3-col-dd');
  },
  handleMouseDown: function handleMouseDown(e) {},
  callHandleMouseDown: function callHandleMouseDown(e) {
    Ext.grid.GridView.ColumnDragZone.superclass.handleMouseDown.call(this, e);
  }
});

/***/ }),
/* 893 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
// private
// This is a support class used internally by the Grid components
Ext.grid.SplitDragZone = Ext.extend(Ext.dd.DDProxy, {
  fly: Ext.Element.fly,
  constructor: function constructor(grid, hd, hd2) {
    this.grid = grid;
    this.view = grid.getView();
    this.proxy = this.view.resizeProxy;
    Ext.grid.SplitDragZone.superclass.constructor.call(this, hd, "gridSplitters" + this.grid.getGridEl().id, {
      dragElId: Ext.id(this.proxy.dom),
      resizeFrame: false
    });
    this.setHandleElId(Ext.id(hd));
    this.setOuterHandleElId(Ext.id(hd2));
    this.scroll = false;
  },
  b4StartDrag: function b4StartDrag(x, y) {
    this.view.headersDisabled = true;
    this.proxy.setHeight(this.view.mainWrap.getHeight());
    var w = this.cm.getColumnWidth(this.cellIndex);
    var minw = Math.max(w - this.grid.minColumnWidth, 0);
    this.resetConstraints();
    this.setXConstraint(minw, 1000);
    this.setYConstraint(0, 0);
    this.minX = x - minw;
    this.maxX = x + 1000;
    this.startPos = x;
    Ext.dd.DDProxy.prototype.b4StartDrag.call(this, x, y);
  },
  handleMouseDown: function handleMouseDown(e) {
    var ev = Ext.EventObject.setEvent(e);
    var t = this.fly(ev.getTarget());

    if (t.hasClass("x-grid-split")) {
      this.cellIndex = this.view.getCellIndex(t.dom);
      this.split = t.dom;
      this.cm = this.grid.colModel;

      if (this.cm.isResizable(this.cellIndex) && !this.cm.isFixed(this.cellIndex)) {
        Ext.grid.SplitDragZone.superclass.handleMouseDown.apply(this, arguments);
      }
    }
  },
  endDrag: function endDrag(e) {
    this.view.headersDisabled = false;
    var endX = Math.max(this.minX, Ext.lib.Event.getPageX(e));
    var diff = endX - this.startPos;
    this.view.onColumnSplitterMoved(this.cellIndex, this.cm.getColumnWidth(this.cellIndex) + diff);
  },
  autoOffset: function autoOffset() {
    this.setDelta(0, 0);
  }
});

/***/ }),
/* 894 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.GridDragZone
 * @extends Ext.dd.DragZone
 * <p>A customized implementation of a {@link Ext.dd.DragZone DragZone} which provides default implementations of two of the
 * template methods of DragZone to enable dragging of the selected rows of a GridPanel.</p>
 * <p>A cooperating {@link Ext.dd.DropZone DropZone} must be created who's template method implementations of
 * {@link Ext.dd.DropZone#onNodeEnter onNodeEnter}, {@link Ext.dd.DropZone#onNodeOver onNodeOver},
 * {@link Ext.dd.DropZone#onNodeOut onNodeOut} and {@link Ext.dd.DropZone#onNodeDrop onNodeDrop}</p> are able
 * to process the {@link #getDragData data} which is provided.
 */
Ext.grid.GridDragZone = function (grid, config) {
  this.view = grid.getView();
  Ext.grid.GridDragZone.superclass.constructor.call(this, this.view.mainBody.dom, config);
  this.scroll = false;
  this.grid = grid;
  this.ddel = document.createElement('div');
  this.ddel.className = 'x-grid-dd-wrap';
};

Ext.extend(Ext.grid.GridDragZone, Ext.dd.DragZone, {
  ddGroup: "GridDD",

  /**
   * <p>The provided implementation of the getDragData method which collects the data to be dragged from the GridPanel on mousedown.</p>
   * <p>This data is available for processing in the {@link Ext.dd.DropZone#onNodeEnter onNodeEnter}, {@link Ext.dd.DropZone#onNodeOver onNodeOver},
   * {@link Ext.dd.DropZone#onNodeOut onNodeOut} and {@link Ext.dd.DropZone#onNodeDrop onNodeDrop} methods of a cooperating {@link Ext.dd.DropZone DropZone}.</p>
   * <p>The data object contains the following properties:<ul>
   * <li><b>grid</b> : Ext.Grid.GridPanel<div class="sub-desc">The GridPanel from which the data is being dragged.</div></li>
   * <li><b>ddel</b> : htmlElement<div class="sub-desc">An htmlElement which provides the "picture" of the data being dragged.</div></li>
   * <li><b>rowIndex</b> : Number<div class="sub-desc">The index of the row which receieved the mousedown gesture which triggered the drag.</div></li>
   * <li><b>selections</b> : Array<div class="sub-desc">An Array of the selected Records which are being dragged from the GridPanel.</div></li>
   * </ul></p>
   */
  getDragData: function getDragData(e) {
    var t = Ext.lib.Event.getTarget(e);
    var rowIndex = this.view.findRowIndex(t);

    if (rowIndex !== false) {
      var sm = this.grid.selModel; // fix: make DD & checkbox selection working together
      // fix: behaviour with modifier (e.g. file copy of mulitiselection) should not change?
      //      if there is a valid use case let's have an option

      if (!sm.isSelected(rowIndex) && !e.getTarget('.x-grid3-row-checker')) {
        sm.handleMouseDown(this.grid, rowIndex, e);
      }

      return {
        grid: this.grid,
        ddel: this.ddel,
        rowIndex: rowIndex,
        selections: sm.getSelections()
      };
    }

    return false;
  },

  /**
   * <p>The provided implementation of the onInitDrag method. Sets the <tt>innerHTML</tt> of the drag proxy which provides the "picture"
   * of the data being dragged.</p>
   * <p>The <tt>innerHTML</tt> data is found by calling the owning GridPanel's {@link Ext.grid.GridPanel#getDragDropText getDragDropText}.</p>
   */
  onInitDrag: function onInitDrag(e) {
    var data = this.dragData;
    this.ddel.innerHTML = this.grid.getDragDropText();
    this.proxy.update(this.ddel); // fire start drag?
  },

  /**
   * An empty immplementation. Implement this to provide behaviour after a repair of an invalid drop. An implementation might highlight
   * the selected rows to show that they have not been dragged.
   */
  afterRepair: function afterRepair() {
    this.dragging = false;
  },

  /**
   * <p>An empty implementation. Implement this to provide coordinates for the drag proxy to slide back to after an invalid drop.</p>
   * <p>Called before a repair of an invalid drop to get the XY to animate to.</p>
   * @param {EventObject} e The mouse up event
   * @return {Array} The xy location (e.g. [100, 200])
   */
  getRepairXY: function getRepairXY(e, data) {
    return false;
  },
  onEndDrag: function onEndDrag(data, e) {// fire end drag?
  },
  onValidDrop: function onValidDrop(dd, e, id) {
    // fire drag drop?
    this.hideProxy();
  },
  beforeInvalidDrop: function beforeInvalidDrop(e, id) {}
});

/***/ }),
/* 895 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.ColumnModel
 * @extends Ext.util.Observable
 * <p>After the data has been read into the client side cache (<b>{@link Ext.data.Store Store}</b>),
 * the ColumnModel is used to configure how and what parts of that data will be displayed in the
 * vertical slices (columns) of the grid. The Ext.grid.ColumnModel Class is the default implementation
 * of a ColumnModel used by implentations of {@link Ext.grid.GridPanel GridPanel}.</p>
 * <p>Data is mapped into the store's records and then indexed into the ColumnModel using the
 * <tt>{@link Ext.grid.Column#dataIndex dataIndex}</tt>:</p>
 * <pre><code>
{data source} == mapping ==> {data store} == <b><tt>{@link Ext.grid.Column#dataIndex dataIndex}</tt></b> ==> {ColumnModel}
 * </code></pre>
 * <p>Each {@link Ext.grid.Column Column} in the grid's ColumnModel is configured with a
 * <tt>{@link Ext.grid.Column#dataIndex dataIndex}</tt> to specify how the data within
 * each record in the store is indexed into the ColumnModel.</p>
 * <p>There are two ways to initialize the ColumnModel class:</p>
 * <p><u>Initialization Method 1: an Array</u></p>
<pre><code>
 var colModel = new Ext.grid.ColumnModel([
    { header: "Ticker", width: 60, sortable: true},
    { header: "Company Name", width: 150, sortable: true, id: 'company'},
    { header: "Market Cap.", width: 100, sortable: true},
    { header: "$ Sales", width: 100, sortable: true, renderer: money},
    { header: "Employees", width: 100, sortable: true, resizable: false}
 ]);
 </code></pre>
 * <p>The ColumnModel may be initialized with an Array of {@link Ext.grid.Column} column configuration
 * objects to define the initial layout / display of the columns in the Grid. The order of each
 * {@link Ext.grid.Column} column configuration object within the specified Array defines the initial
 * order of the column display.  A Column's display may be initially hidden using the
 * <tt>{@link Ext.grid.Column#hidden hidden}</tt></b> config property (and then shown using the column
 * header menu).  Fields that are not included in the ColumnModel will not be displayable at all.</p>
 * <p>How each column in the grid correlates (maps) to the {@link Ext.data.Record} field in the
 * {@link Ext.data.Store Store} the column draws its data from is configured through the
 * <b><tt>{@link Ext.grid.Column#dataIndex dataIndex}</tt></b>.  If the
 * <b><tt>{@link Ext.grid.Column#dataIndex dataIndex}</tt></b> is not explicitly defined (as shown in the
 * example above) it will use the column configuration's index in the Array as the index.</p>
 * <p>See <b><tt>{@link Ext.grid.Column}</tt></b> for additional configuration options for each column.</p>
 * <p><u>Initialization Method 2: an Object</u></p>
 * <p>In order to use configuration options from <tt>Ext.grid.ColumnModel</tt>, an Object may be used to
 * initialize the ColumnModel.  The column configuration Array will be specified in the <tt><b>{@link #columns}</b></tt>
 * config property. The <tt><b>{@link #defaults}</b></tt> config property can be used to apply defaults
 * for all columns, e.g.:</p><pre><code>
 var colModel = new Ext.grid.ColumnModel({
    columns: [
        { header: "Ticker", width: 60, menuDisabled: false},
        { header: "Company Name", width: 150, id: 'company'},
        { header: "Market Cap."},
        { header: "$ Sales", renderer: money},
        { header: "Employees", resizable: false}
    ],
    defaults: {
        sortable: true,
        menuDisabled: true,
        width: 100
    },
    listeners: {
        {@link #hiddenchange}: function(cm, colIndex, hidden) {
            saveConfig(colIndex, hidden);
        }
    }
});
 </code></pre>
 * <p>In both examples above, the ability to apply a CSS class to all cells in a column (including the
 * header) is demonstrated through the use of the <b><tt>{@link Ext.grid.Column#id id}</tt></b> config
 * option. This column could be styled by including the following css:</p><pre><code>
 //add this css *after* the core css is loaded
.x-grid3-td-company {
    color: red; // entire column will have red font
}
// modify the header row only, adding an icon to the column header
.x-grid3-hd-company {
    background: transparent
        url(../../resources/images/icons/silk/building.png)
        no-repeat 3px 3px ! important;
        padding-left:20px;
}
 </code></pre>
 * Note that the "Company Name" column could be specified as the
 * <b><tt>{@link Ext.grid.GridPanel}.{@link Ext.grid.GridPanel#autoExpandColumn autoExpandColumn}</tt></b>.
 * @constructor
 * @param {Mixed} config Specify either an Array of {@link Ext.grid.Column} configuration objects or specify
 * a configuration Object (see introductory section discussion utilizing Initialization Method 2 above).
 */
Ext.grid.ColumnModel = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Number} defaultWidth (optional) The width of columns which have no <tt>{@link #width}</tt>
   * specified (defaults to <tt>100</tt>).  This property shall preferably be configured through the
   * <tt><b>{@link #defaults}</b></tt> config property.
   */
  defaultWidth: 100,

  /**
   * @cfg {Boolean} defaultSortable (optional) Default sortable of columns which have no
   * sortable specified (defaults to <tt>false</tt>).  This property shall preferably be configured
   * through the <tt><b>{@link #defaults}</b></tt> config property.
   */
  defaultSortable: false,

  /**
   * @cfg {Array} columns An Array of object literals.  The config options defined by
   * <b>{@link Ext.grid.Column}</b> are the options which may appear in the object literal for each
   * individual column definition.
   */

  /**
   * @cfg {Object} defaults Object literal which will be used to apply {@link Ext.grid.Column}
   * configuration options to all <tt><b>{@link #columns}</b></tt>.  Configuration options specified with
   * individual {@link Ext.grid.Column column} configs will supersede these <tt><b>{@link #defaults}</b></tt>.
   */
  constructor: function constructor(config) {
    /**
    * An Array of {@link Ext.grid.Column Column definition} objects representing the configuration
    * of this ColumnModel.  See {@link Ext.grid.Column} for the configuration properties that may
    * be specified.
    * @property config
    * @type Array
    */
    if (config.columns) {
      Ext.apply(this, config);
      this.setConfig(config.columns, true);
    } else {
      this.setConfig(config, true);
    }

    this.addEvents(
    /**
     * @event widthchange
     * Fires when the width of a column is programmaticially changed using
     * <code>{@link #setColumnWidth}</code>.
     * Note internal resizing suppresses the event from firing. See also
     * {@link Ext.grid.GridPanel}.<code>{@link #columnresize}</code>.
     * @param {ColumnModel} this
     * @param {Number} columnIndex The column index
     * @param {Number} newWidth The new width
     */
    "widthchange",
    /**
     * @event headerchange
     * Fires when the text of a header changes.
     * @param {ColumnModel} this
     * @param {Number} columnIndex The column index
     * @param {String} newText The new header text
     */
    "headerchange",
    /**
     * @event hiddenchange
     * Fires when a column is hidden or "unhidden".
     * @param {ColumnModel} this
     * @param {Number} columnIndex The column index
     * @param {Boolean} hidden true if hidden, false otherwise
     */
    "hiddenchange",
    /**
     * @event columnmoved
     * Fires when a column is moved.
     * @param {ColumnModel} this
     * @param {Number} oldIndex
     * @param {Number} newIndex
     */
    "columnmoved",
    /**
     * @event configchange
     * Fires when the configuration is changed
     * @param {ColumnModel} this
     */
    "configchange");
    Ext.grid.ColumnModel.superclass.constructor.call(this);
  },

  /**
   * Returns the id of the column at the specified index.
   * @param {Number} index The column index
   * @return {String} the id
   */
  getColumnId: function getColumnId(index) {
    return this.config[index].id;
  },
  getColumnAt: function getColumnAt(index) {
    return this.config[index];
  },

  /**
   * <p>Reconfigures this column model according to the passed Array of column definition objects.
   * For a description of the individual properties of a column definition object, see the
   * <a href="#Ext.grid.ColumnModel-configs">Config Options</a>.</p>
   * <p>Causes the {@link #configchange} event to be fired. A {@link Ext.grid.GridPanel GridPanel}
   * using this ColumnModel will listen for this event and refresh its UI automatically.</p>
   * @param {Array} config Array of Column definition objects.
   * @param {Boolean} initial Specify <tt>true</tt> to bypass cleanup which deletes the <tt>totalWidth</tt>
   * and destroys existing editors.
   */
  setConfig: function setConfig(config, initial) {
    var i, c, len;

    if (!initial) {
      // cleanup
      delete this.totalWidth;

      for (i = 0, len = this.config.length; i < len; i++) {
        this.config[i].destroy();
      }
    } // backward compatibility


    this.defaults = Ext.apply({
      width: this.defaultWidth,
      sortable: this.defaultSortable
    }, this.defaults);
    this.config = config;
    this.lookup = {};

    for (i = 0, len = config.length; i < len; i++) {
      c = Ext.applyIf(config[i], this.defaults); // if no id, create one using column's ordinal position

      if (Ext.isEmpty(c.id)) {
        c.id = i;
      }

      if (!c.isColumn) {
        var Cls = Ext.grid.Column.types[c.xtype || 'gridcolumn'];
        c = new Cls(c);
        config[i] = c;
      }

      this.lookup[c.id] = c;
    }

    if (!initial) {
      this.fireEvent('configchange', this);
    }
  },

  /**
   * Returns the column for a specified id.
   * @param {String} id The column id
   * @return {Object} the column
   */
  getColumnById: function getColumnById(id) {
    return this.lookup[id];
  },

  /**
   * Returns the index for a specified column id.
   * @param {String} id The column id
   * @return {Number} the index, or -1 if not found
   */
  getIndexById: function getIndexById(id) {
    for (var i = 0, len = this.config.length; i < len; i++) {
      if (this.config[i].id == id) {
        return i;
      }
    }

    return -1;
  },

  /**
   * Moves a column from one position to another.
   * @param {Number} oldIndex The index of the column to move.
   * @param {Number} newIndex The position at which to reinsert the coolumn.
   */
  moveColumn: function moveColumn(oldIndex, newIndex) {
    var c = this.config[oldIndex];
    this.config.splice(oldIndex, 1);
    this.config.splice(newIndex, 0, c);
    this.dataMap = null;
    this.fireEvent("columnmoved", this, oldIndex, newIndex);
  },

  /**
   * Returns the number of columns.
   * @param {Boolean} visibleOnly Optional. Pass as true to only include visible columns.
   * @return {Number}
   */
  getColumnCount: function getColumnCount(visibleOnly) {
    if (visibleOnly === true) {
      var c = 0;

      for (var i = 0, len = this.config.length; i < len; i++) {
        if (!this.isHidden(i)) {
          c++;
        }
      }

      return c;
    }

    return this.config.length;
  },

  /**
   * Returns the column configs that return true by the passed function that is called
   * with (columnConfig, index)
  <pre><code>
  // returns an array of column config objects for all hidden columns
  var columns = grid.getColumnModel().getColumnsBy(function(c){
  return c.hidden;
  });
  </code></pre>
   * @param {Function} fn A function which, when passed a {@link Ext.grid.Column Column} object, must
   * return <code>true</code> if the column is to be included in the returned Array.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function
   * is executed. Defaults to this ColumnModel.
   * @return {Array} result
   */
  getColumnsBy: function getColumnsBy(fn, scope) {
    var r = [];

    for (var i = 0, len = this.config.length; i < len; i++) {
      var c = this.config[i];

      if (fn.call(scope || this, c, i) === true) {
        r[r.length] = c;
      }
    }

    return r;
  },

  /**
   * Returns true if the specified column is sortable.
   * @param {Number} col The column index
   * @return {Boolean}
   */
  isSortable: function isSortable(col) {
    return !!this.config[col].sortable;
  },

  /**
   * Returns true if the specified column menu is disabled.
   * @param {Number} col The column index
   * @return {Boolean}
   */
  isMenuDisabled: function isMenuDisabled(col) {
    return !!this.config[col].menuDisabled;
  },

  /**
   * Returns the rendering (formatting) function defined for the column.
   * @param {Number} col The column index.
   * @return {Function} The function used to render the cell. See {@link #setRenderer}.
   */
  getRenderer: function getRenderer(col) {
    if (!this.config[col].renderer) {
      return Ext.grid.ColumnModel.defaultRenderer;
    }

    return this.config[col].renderer;
  },
  getRendererScope: function getRendererScope(col) {
    return this.config[col].scope;
  },

  /**
   * Sets the rendering (formatting) function for a column.  See {@link Ext.util.Format} for some
   * default formatting functions.
   * @param {Number} col The column index
   * @param {Function} fn The function to use to process the cell's raw data
   * to return HTML markup for the grid view. The render function is called with
   * the following parameters:<ul>
   * <li><b>value</b> : Object<p class="sub-desc">The data value for the cell.</p></li>
   * <li><b>metadata</b> : Object<p class="sub-desc">An object in which you may set the following attributes:<ul>
   * <li><b>css</b> : String<p class="sub-desc">A CSS class name to add to the cell's TD element.</p></li>
   * <li><b>attr</b> : String<p class="sub-desc">An HTML attribute definition string to apply to the data container element <i>within</i> the table cell
   * (e.g. 'style="color:red;"').</p></li></ul></p></li>
   * <li><b>record</b> : Ext.data.record<p class="sub-desc">The {@link Ext.data.Record} from which the data was extracted.</p></li>
   * <li><b>rowIndex</b> : Number<p class="sub-desc">Row index</p></li>
   * <li><b>colIndex</b> : Number<p class="sub-desc">Column index</p></li>
   * <li><b>store</b> : Ext.data.Store<p class="sub-desc">The {@link Ext.data.Store} object from which the Record was extracted.</p></li></ul>
   */
  setRenderer: function setRenderer(col, fn) {
    this.config[col].renderer = fn;
  },

  /**
   * Returns the width for the specified column.
   * @param {Number} col The column index
   * @return {Number}
   */
  getColumnWidth: function getColumnWidth(col) {
    return this.config[col].width;
  },

  /**
   * Sets the width for a column.
   * @param {Number} col The column index
   * @param {Number} width The new width
   * @param {Boolean} suppressEvent True to suppress firing the <code>{@link #widthchange}</code>
   * event. Defaults to false.
   */
  setColumnWidth: function setColumnWidth(col, width, suppressEvent) {
    this.config[col].width = width;
    this.totalWidth = null;

    if (!suppressEvent) {
      this.fireEvent("widthchange", this, col, width);
    }
  },

  /**
   * Returns the total width of all columns.
   * @param {Boolean} includeHidden True to include hidden column widths
   * @return {Number}
   */
  getTotalWidth: function getTotalWidth(includeHidden) {
    if (!this.totalWidth) {
      this.totalWidth = 0;

      for (var i = 0, len = this.config.length; i < len; i++) {
        if (includeHidden || !this.isHidden(i)) {
          this.totalWidth += this.getColumnWidth(i);
        }
      }
    }

    return this.totalWidth;
  },

  /**
   * Returns the header for the specified column.
   * @param {Number} col The column index
   * @return {String}
   */
  getColumnHeader: function getColumnHeader(col) {
    return this.config[col].header;
  },

  /**
   * Sets the header for a column.
   * @param {Number} col The column index
   * @param {String} header The new header
   */
  setColumnHeader: function setColumnHeader(col, header) {
    this.config[col].header = header;
    this.fireEvent("headerchange", this, col, header);
  },

  /**
   * Returns the tooltip for the specified column.
   * @param {Number} col The column index
   * @return {String}
   */
  getColumnTooltip: function getColumnTooltip(col) {
    return this.config[col].tooltip;
  },

  /**
   * Sets the tooltip for a column.
   * @param {Number} col The column index
   * @param {String} tooltip The new tooltip
   */
  setColumnTooltip: function setColumnTooltip(col, tooltip) {
    this.config[col].tooltip = tooltip;
  },

  /**
   * Returns the dataIndex for the specified column.
  <pre><code>
  // Get field name for the column
  var fieldName = grid.getColumnModel().getDataIndex(columnIndex);
  </code></pre>
   * @param {Number} col The column index
   * @return {String} The column's dataIndex
   */
  getDataIndex: function getDataIndex(col) {
    return this.config[col].dataIndex;
  },

  /**
   * Sets the dataIndex for a column.
   * @param {Number} col The column index
   * @param {String} dataIndex The new dataIndex
   */
  setDataIndex: function setDataIndex(col, dataIndex) {
    this.config[col].dataIndex = dataIndex;
  },

  /**
   * Finds the index of the first matching column for the given dataIndex.
   * @param {String} col The dataIndex to find
   * @return {Number} The column index, or -1 if no match was found
   */
  findColumnIndex: function findColumnIndex(dataIndex) {
    var c = this.config;

    for (var i = 0, len = c.length; i < len; i++) {
      if (c[i].dataIndex == dataIndex) {
        return i;
      }
    }

    return -1;
  },

  /**
   * Returns true if the cell is editable.
  <pre><code>
  var store = new Ext.data.Store({...});
  var colModel = new Ext.grid.ColumnModel({
  columns: [...],
  isCellEditable: function(col, row) {
  var record = store.getAt(row);
  if (record.get('readonly')) { // replace with your condition
    return false;
  }
  return Ext.grid.ColumnModel.prototype.isCellEditable.call(this, col, row);
  }
  });
  var grid = new Ext.grid.GridPanel({
  store: store,
  colModel: colModel,
  ...
  });
  </code></pre>
   * @param {Number} colIndex The column index
   * @param {Number} rowIndex The row index
   * @return {Boolean}
   */
  isCellEditable: function isCellEditable(colIndex, rowIndex) {
    var c = this.config[colIndex],
        ed = c.editable; //force boolean

    return !!(ed || !Ext.isDefined(ed) && c.editor);
  },

  /**
   * Returns the editor defined for the cell/column.
   * @param {Number} colIndex The column index
   * @param {Number} rowIndex The row index
   * @return {Ext.Editor} The {@link Ext.Editor Editor} that was created to wrap
   * the {@link Ext.form.Field Field} used to edit the cell.
   */
  getCellEditor: function getCellEditor(colIndex, rowIndex) {
    return this.config[colIndex].getCellEditor(rowIndex);
  },

  /**
   * Sets if a column is editable.
   * @param {Number} col The column index
   * @param {Boolean} editable True if the column is editable
   */
  setEditable: function setEditable(col, editable) {
    this.config[col].editable = editable;
  },

  /**
   * Returns <tt>true</tt> if the column is <code>{@link Ext.grid.Column#hidden hidden}</code>,
   * <tt>false</tt> otherwise.
   * @param {Number} colIndex The column index
   * @return {Boolean}
   */
  isHidden: function isHidden(colIndex) {
    return !!this.config[colIndex].hidden; // ensure returns boolean
  },

  /**
   * Returns <tt>true</tt> if the column is <code>{@link Ext.grid.Column#fixed fixed}</code>,
   * <tt>false</tt> otherwise.
   * @param {Number} colIndex The column index
   * @return {Boolean}
   */
  isFixed: function isFixed(colIndex) {
    return !!this.config[colIndex].fixed;
  },

  /**
   * Returns true if the column can be resized
   * @return {Boolean}
   */
  isResizable: function isResizable(colIndex) {
    return colIndex >= 0 && this.config[colIndex].resizable !== false && this.config[colIndex].fixed !== true;
  },

  /**
   * Sets if a column is hidden.
  <pre><code>
  myGrid.getColumnModel().setHidden(0, true); // hide column 0 (0 = the first column).
  </code></pre>
   * @param {Number} colIndex The column index
   * @param {Boolean} hidden True if the column is hidden
   */
  setHidden: function setHidden(colIndex, hidden) {
    var c = this.config[colIndex];

    if (c.hidden !== hidden) {
      c.hidden = hidden;
      this.totalWidth = null;
      this.fireEvent("hiddenchange", this, colIndex, hidden);
    }
  },

  /**
   * Sets the editor for a column and destroys the prior editor.
   * @param {Number} col The column index
   * @param {Object} editor The editor object
   */
  setEditor: function setEditor(col, editor) {
    this.config[col].setEditor(editor);
  },

  /**
   * Destroys this column model by purging any event listeners, and removing any editors.
   */
  destroy: function destroy() {
    for (var i = 0, len = this.config.length; i < len; i++) {
      this.config[i].destroy();
    }

    this.purgeListeners();
  }
}); // private

Ext.grid.ColumnModel.defaultRenderer = function (value) {
  if (typeof value == "string" && value.length < 1) {
    return "&#160;";
  }

  return value;
};

/***/ }),
/* 896 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.AbstractSelectionModel
 * @extends Ext.util.Observable
 * Abstract base class for grid SelectionModels.  It provides the interface that should be
 * implemented by descendant classes.  This class should not be directly instantiated.
 * @constructor
 */
Ext.grid.AbstractSelectionModel = Ext.extend(Ext.util.Observable, {
  /**
   * The GridPanel for which this SelectionModel is handling selection. Read-only.
   * @type Object
   * @property grid
   */
  constructor: function constructor() {
    this.locked = false;
    Ext.grid.AbstractSelectionModel.superclass.constructor.call(this);
  },

  /** @ignore Called by the grid automatically. Do not call directly. */
  init: function init(grid) {
    this.grid = grid;
    this.initEvents();
  },

  /**
   * Locks the selections.
   */
  lock: function lock() {
    this.locked = true;
  },

  /**
   * Unlocks the selections.
   */
  unlock: function unlock() {
    this.locked = false;
  },

  /**
   * Returns true if the selections are locked.
   * @return {Boolean}
   */
  isLocked: function isLocked() {
    return this.locked;
  },
  destroy: function destroy() {
    this.purgeListeners();
  }
});

/***/ }),
/* 897 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.RowSelectionModel
 * @extends Ext.grid.AbstractSelectionModel
 * The default SelectionModel used by {@link Ext.grid.GridPanel}.
 * It supports multiple selections and keyboard selection/navigation. The objects stored
 * as selections and returned by {@link #getSelected}, and {@link #getSelections} are
 * the {@link Ext.data.Record Record}s which provide the data for the selected rows.
 * @constructor
 * @param {Object} config
 */
Ext.grid.RowSelectionModel = Ext.extend(Ext.grid.AbstractSelectionModel, {
  /**
   * @cfg {Boolean} singleSelect
   * <tt>true</tt> to allow selection of only one row at a time (defaults to <tt>false</tt>
   * allowing multiple selections)
   */
  singleSelect: false,
  constructor: function constructor(config) {
    Ext.apply(this, config);
    this.selections = new Ext.util.MixedCollection(false, function (o) {
      return o.id;
    });
    this.last = false;
    this.lastActive = false;
    this.addEvents(
    /**
     * @event selectionchange
     * Fires when the selection changes
     * @param {SelectionModel} this
     */
    'selectionchange',
    /**
     * @event beforerowselect
     * Fires before a row is selected, return false to cancel the selection.
     * @param {SelectionModel} this
     * @param {Number} rowIndex The index to be selected
     * @param {Boolean} keepExisting False if other selections will be cleared
     * @param {Record} record The record to be selected
     */
    'beforerowselect',
    /**
     * @event rowselect
     * Fires when a row is selected.
     * @param {SelectionModel} this
     * @param {Number} rowIndex The selected index
     * @param {Ext.data.Record} r The selected record
     */
    'rowselect',
    /**
     * @event rowdeselect
     * Fires when a row is deselected.  To prevent deselection
     * {@link Ext.grid.AbstractSelectionModel#lock lock the selections}. 
     * @param {SelectionModel} this
     * @param {Number} rowIndex
     * @param {Record} record
     */
    'rowdeselect');
    Ext.grid.RowSelectionModel.superclass.constructor.call(this);
  },

  /**
   * @cfg {Boolean} moveEditorOnEnter
   * <tt>false</tt> to turn off moving the editor to the next row down when the enter key is pressed
   * or the next row up when shift + enter keys are pressed.
   */
  // private
  initEvents: function initEvents() {
    if (!this.grid.enableDragDrop && !this.grid.enableDrag) {
      this.grid.on('rowmousedown', this.handleMouseDown, this);
    }

    this.rowNav = new Ext.KeyNav(this.grid.getGridEl(), {
      'up': function up(e) {
        if (!e.shiftKey || this.singleSelect) {
          this.selectPrevious(false);
        } else if (this.last !== false && this.lastActive !== false) {
          var last = this.last;
          this.selectRange(this.last, this.lastActive - 1);
          this.grid.getView().focusRow(this.lastActive);

          if (last !== false) {
            this.last = last;
          }
        } else {
          this.selectFirstRow();
        }
      },
      'down': function down(e) {
        if (!e.shiftKey || this.singleSelect) {
          this.selectNext(false);
        } else if (this.last !== false && this.lastActive !== false) {
          var last = this.last;
          this.selectRange(this.last, this.lastActive + 1);
          this.grid.getView().focusRow(this.lastActive);

          if (last !== false) {
            this.last = last;
          }
        } else {
          this.selectFirstRow();
        }
      },
      scope: this
    });
    this.grid.getView().on({
      scope: this,
      refresh: this.onRefresh,
      rowupdated: this.onRowUpdated,
      rowremoved: this.onRemove
    });
  },
  // private
  onRefresh: function onRefresh() {
    var ds = this.grid.store,
        index;
    var s = this.getSelections();
    this.clearSelections(true);

    for (var i = 0, len = s.length; i < len; i++) {
      var r = s[i];

      if ((index = ds.indexOfId(r.id)) != -1) {
        this.selectRow(index, true);
      }
    }

    if (s.length != this.selections.getCount()) {
      this.fireEvent('selectionchange', this);
    }
  },
  // private
  onRemove: function onRemove(v, index, r) {
    if (this.selections.remove(r) !== false) {
      this.fireEvent('selectionchange', this);
    }
  },
  // private
  onRowUpdated: function onRowUpdated(v, index, r) {
    if (this.isSelected(r)) {
      v.onRowSelect(index);
    }
  },

  /**
   * Select records.
   * @param {Array} records The records to select
   * @param {Boolean} keepExisting (optional) <tt>true</tt> to keep existing selections
   */
  selectRecords: function selectRecords(records, keepExisting) {
    if (!keepExisting) {
      this.clearSelections();
    }

    var ds = this.grid.store;

    for (var i = 0, len = records.length; i < len; i++) {
      this.selectRow(ds.indexOf(records[i]), true);
    }
  },

  /**
   * Gets the number of selected rows.
   * @return {Number}
   */
  getCount: function getCount() {
    return this.selections.length;
  },

  /**
   * Selects the first row in the grid.
   */
  selectFirstRow: function selectFirstRow() {
    this.selectRow(0);
  },

  /**
   * Select the last row.
   * @param {Boolean} keepExisting (optional) <tt>true</tt> to keep existing selections
   */
  selectLastRow: function selectLastRow(keepExisting) {
    this.selectRow(this.grid.store.getCount() - 1, keepExisting);
  },

  /**
   * Selects the row immediately following the last selected row.
   * @param {Boolean} keepExisting (optional) <tt>true</tt> to keep existing selections
   * @return {Boolean} <tt>true</tt> if there is a next row, else <tt>false</tt>
   */
  selectNext: function selectNext(keepExisting) {
    if (this.hasNext()) {
      this.selectRow(this.last + 1, keepExisting);
      this.grid.getView().focusRow(this.last);
      return true;
    }

    return false;
  },

  /**
   * Selects the row that precedes the last selected row.
   * @param {Boolean} keepExisting (optional) <tt>true</tt> to keep existing selections
   * @return {Boolean} <tt>true</tt> if there is a previous row, else <tt>false</tt>
   */
  selectPrevious: function selectPrevious(keepExisting) {
    if (this.hasPrevious()) {
      this.selectRow(this.last - 1, keepExisting);
      this.grid.getView().focusRow(this.last);
      return true;
    }

    return false;
  },

  /**
   * Returns true if there is a next record to select
   * @return {Boolean}
   */
  hasNext: function hasNext() {
    return this.last !== false && this.last + 1 < this.grid.store.getCount();
  },

  /**
   * Returns true if there is a previous record to select
   * @return {Boolean}
   */
  hasPrevious: function hasPrevious() {
    return !!this.last;
  },

  /**
   * Returns the selected records
   * @return {Array} Array of selected records
   */
  getSelections: function getSelections() {
    return [].concat(this.selections.items);
  },

  /**
   * Returns the first selected record.
   * @return {Record}
   */
  getSelected: function getSelected() {
    return this.selections.itemAt(0);
  },

  /**
   * Calls the passed function with each selection. If the function returns
   * <tt>false</tt>, iteration is stopped and this function returns
   * <tt>false</tt>. Otherwise it returns <tt>true</tt>.
   * @param {Function} fn The function to call upon each iteration. It is passed the selected {@link Ext.data.Record Record}.
   * @param {Object} scope (optional) The scope (<code>this</code> reference) in which the function is executed. Defaults to this RowSelectionModel.
   * @return {Boolean} true if all selections were iterated
   */
  each: function each(fn, scope) {
    var s = this.getSelections();

    for (var i = 0, len = s.length; i < len; i++) {
      if (fn.call(scope || this, s[i], i) === false) {
        return false;
      }
    }

    return true;
  },

  /**
   * Clears all selections if the selection model
   * {@link Ext.grid.AbstractSelectionModel#isLocked is not locked}.
   * @param {Boolean} fast (optional) <tt>true</tt> to bypass the
   * conditional checks and events described in {@link #deselectRow}.
   */
  clearSelections: function clearSelections(fast) {
    if (this.isLocked()) {
      return;
    }

    if (fast !== true) {
      var ds = this.grid.store;
      var s = this.selections;
      s.each(function (r) {
        this.deselectRow(ds.indexOfId(r.id));
      }, this);
      s.clear();
    } else {
      this.selections.clear();
    }

    this.last = false;
  },

  /**
   * Selects all rows if the selection model
   * {@link Ext.grid.AbstractSelectionModel#isLocked is not locked}. 
   */
  selectAll: function selectAll() {
    if (this.isLocked()) {
      return;
    }

    this.selections.clear();

    for (var i = 0, len = this.grid.store.getCount(); i < len; i++) {
      this.selectRow(i, true);
    }
  },

  /**
   * Returns <tt>true</tt> if there is a selection.
   * @return {Boolean}
   */
  hasSelection: function hasSelection() {
    return this.selections.length > 0;
  },

  /**
   * Returns <tt>true</tt> if the specified row is selected.
   * @param {Number/Record} index The record or index of the record to check
   * @return {Boolean}
   */
  isSelected: function isSelected(index) {
    var r = Ext.isNumber(index) ? this.grid.store.getAt(index) : index;
    return r && this.selections.key(r.id) ? true : false;
  },

  /**
   * Returns <tt>true</tt> if the specified record id is selected.
   * @param {String} id The id of record to check
   * @return {Boolean}
   */
  isIdSelected: function isIdSelected(id) {
    return this.selections.key(id) ? true : false;
  },
  // private
  handleMouseDown: function handleMouseDown(g, rowIndex, e) {
    if (e.button !== 0 || this.isLocked()) {
      return;
    }

    var view = this.grid.getView();

    if (e.shiftKey && !this.singleSelect && this.last !== false) {
      var last = this.last;
      this.selectRange(last, rowIndex, e.ctrlKey);
      this.last = last; // reset the last

      view.focusRow(rowIndex);
    } else {
      var isSelected = this.isSelected(rowIndex);

      if (e.ctrlKey && isSelected) {
        this.deselectRow(rowIndex);
      } else if (!isSelected || this.getCount() > 1) {
        this.selectRow(rowIndex, e.ctrlKey || e.shiftKey);
        view.focusRow(rowIndex);
      }
    }
  },

  /**
   * Selects multiple rows.
   * @param {Array} rows Array of the indexes of the row to select
   * @param {Boolean} keepExisting (optional) <tt>true</tt> to keep
   * existing selections (defaults to <tt>false</tt>)
   */
  selectRows: function selectRows(rows, keepExisting) {
    if (!keepExisting) {
      this.clearSelections();
    }

    for (var i = 0, len = rows.length; i < len; i++) {
      this.selectRow(rows[i], true);
    }
  },

  /**
   * Selects a range of rows if the selection model
   * {@link Ext.grid.AbstractSelectionModel#isLocked is not locked}.
   * All rows in between startRow and endRow are also selected.
   * @param {Number} startRow The index of the first row in the range
   * @param {Number} endRow The index of the last row in the range
   * @param {Boolean} keepExisting (optional) True to retain existing selections
   */
  selectRange: function selectRange(startRow, endRow, keepExisting) {
    var i;

    if (this.isLocked()) {
      return;
    }

    if (!keepExisting) {
      this.clearSelections();
    }

    if (startRow <= endRow) {
      for (i = startRow; i <= endRow; i++) {
        this.selectRow(i, true);
      }
    } else {
      for (i = startRow; i >= endRow; i--) {
        this.selectRow(i, true);
      }
    }
  },

  /**
   * Deselects a range of rows if the selection model
   * {@link Ext.grid.AbstractSelectionModel#isLocked is not locked}.  
   * All rows in between startRow and endRow are also deselected.
   * @param {Number} startRow The index of the first row in the range
   * @param {Number} endRow The index of the last row in the range
   */
  deselectRange: function deselectRange(startRow, endRow, preventViewNotify) {
    if (this.isLocked()) {
      return;
    }

    for (var i = startRow; i <= endRow; i++) {
      this.deselectRow(i, preventViewNotify);
    }
  },

  /**
   * Selects a row.  Before selecting a row, checks if the selection model
   * {@link Ext.grid.AbstractSelectionModel#isLocked is locked} and fires the
   * {@link #beforerowselect} event.  If these checks are satisfied the row
   * will be selected and followed up by  firing the {@link #rowselect} and
   * {@link #selectionchange} events.
   * @param {Number} row The index of the row to select
   * @param {Boolean} keepExisting (optional) <tt>true</tt> to keep existing selections
   * @param {Boolean} preventViewNotify (optional) Specify <tt>true</tt> to
   * prevent notifying the view (disables updating the selected appearance)
   */
  selectRow: function selectRow(index, keepExisting, preventViewNotify) {
    if (this.isLocked() || index < 0 || index >= this.grid.store.getCount() || keepExisting && this.isSelected(index)) {
      return;
    }

    var r = this.grid.store.getAt(index);

    if (r && this.fireEvent('beforerowselect', this, index, keepExisting, r) !== false) {
      if (!keepExisting || this.singleSelect) {
        this.clearSelections();
      }

      this.selections.add(r);
      this.last = this.lastActive = index;

      if (!preventViewNotify) {
        this.grid.getView().onRowSelect(index);
      }

      this.fireEvent('rowselect', this, index, r);
      this.fireEvent('selectionchange', this);
    }
  },

  /**
   * Deselects a row.  Before deselecting a row, checks if the selection model
   * {@link Ext.grid.AbstractSelectionModel#isLocked is locked}.
   * If this check is satisfied the row will be deselected and followed up by
   * firing the {@link #rowdeselect} and {@link #selectionchange} events.
   * @param {Number} row The index of the row to deselect
   * @param {Boolean} preventViewNotify (optional) Specify <tt>true</tt> to
   * prevent notifying the view (disables updating the selected appearance)
   */
  deselectRow: function deselectRow(index, preventViewNotify) {
    if (this.isLocked()) {
      return;
    }

    if (this.last == index) {
      this.last = false;
    }

    if (this.lastActive == index) {
      this.lastActive = false;
    }

    var r = this.grid.store.getAt(index);

    if (r) {
      this.selections.remove(r);

      if (!preventViewNotify) {
        this.grid.getView().onRowDeselect(index);
      }

      this.fireEvent('rowdeselect', this, index, r);
      this.fireEvent('selectionchange', this);
    }
  },
  // private
  restoreLast: function restoreLast() {
    if (this._last) {
      this.last = this._last;
    }
  },
  // private
  acceptsNav: function acceptsNav(row, col, cm) {
    return !cm.isHidden(col) && cm.isCellEditable(col, row);
  },
  // private
  onEditorKey: function onEditorKey(field, e) {
    var k = e.getKey(),
        newCell,
        g = this.grid,
        last = g.lastEdit,
        ed = g.activeEditor,
        ae,
        last,
        r,
        c;
    var shift = e.shiftKey;

    if (k == e.TAB) {
      e.stopEvent();
      ed.completeEdit();

      if (shift) {
        newCell = g.walkCells(ed.row, ed.col - 1, -1, this.acceptsNav, this);
      } else {
        newCell = g.walkCells(ed.row, ed.col + 1, 1, this.acceptsNav, this);
      }
    } else if (k == e.ENTER) {
      if (this.moveEditorOnEnter !== false) {
        if (shift) {
          newCell = g.walkCells(last.row - 1, last.col, -1, this.acceptsNav, this);
        } else {
          newCell = g.walkCells(last.row + 1, last.col, 1, this.acceptsNav, this);
        }
      }
    }

    if (newCell) {
      r = newCell[0];
      c = newCell[1];

      if (last.row != r) {
        this.selectRow(r); // *** highlight newly-selected cell and update selection
      }

      if (g.isEditor && g.editing) {
        // *** handle tabbing while editorgrid is in edit mode
        ae = g.activeEditor;

        if (ae && ae.field.triggerBlur) {
          // *** if activeEditor is a TriggerField, explicitly call its triggerBlur() method
          ae.field.triggerBlur();
        }
      }

      g.startEditing(r, c);
    }
  },
  destroy: function destroy() {
    if (this.rowNav) {
      this.rowNav.disable();
      this.rowNav = null;
    }

    Ext.grid.RowSelectionModel.superclass.destroy.call(this);
  }
});

/***/ }),
/* 898 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.Column
 * <p>This class encapsulates column configuration data to be used in the initialization of a
 * {@link Ext.grid.ColumnModel ColumnModel}.</p>
 * <p>While subclasses are provided to render data in different ways, this class renders a passed
 * data field unchanged and is usually used for textual columns.</p>
 */
Ext.grid.Column = Ext.extend(Object, {
  /**
   * @cfg {Boolean} editable Optional. Defaults to <tt>true</tt>, enabling the configured
   * <tt>{@link #editor}</tt>.  Set to <tt>false</tt> to initially disable editing on this column.
   * The initial configuration may be dynamically altered using
   * {@link Ext.grid.ColumnModel}.{@link Ext.grid.ColumnModel#setEditable setEditable()}.
   */

  /**
   * @cfg {String} id Optional. A name which identifies this column (defaults to the column's initial
   * ordinal position.) The <tt>id</tt> is used to create a CSS <b>class</b> name which is applied to all
   * table cells (including headers) in that column (in this context the <tt>id</tt> does not need to be
   * unique). The class name takes the form of <pre>x-grid3-td-<b>id</b></pre>
   * Header cells will also receive this class name, but will also have the class <pre>x-grid3-hd</pre>
   * So, to target header cells, use CSS selectors such as:<pre>.x-grid3-hd-row .x-grid3-td-<b>id</b></pre>
   * The {@link Ext.grid.GridPanel#autoExpandColumn} grid config option references the column via this
   * unique identifier.
   */

  /**
   * @cfg {String} header Optional. The header text to be used as innerHTML
   * (html tags are accepted) to display in the Grid view.  <b>Note</b>: to
   * have a clickable header with no text displayed use <tt>'&#160;'</tt>.
   */

  /**
   * @cfg {Boolean} groupable Optional. If the grid is being rendered by an {@link Ext.grid.GroupingView}, this option
   * may be used to disable the header menu item to group by the column selected. Defaults to <tt>true</tt>,
   * which enables the header menu group option.  Set to <tt>false</tt> to disable (but still show) the
   * group option in the header menu for the column. See also <code>{@link #groupName}</code>.
   */

  /**
   * @cfg {String} groupName Optional. If the grid is being rendered by an {@link Ext.grid.GroupingView}, this option
   * may be used to specify the text with which to prefix the group field value in the group header line.
   * See also {@link #groupRenderer} and
   * {@link Ext.grid.GroupingView}.{@link Ext.grid.GroupingView#showGroupName showGroupName}.
   */

  /**
   * @cfg {Function} groupRenderer <p>Optional. If the grid is being rendered by an {@link Ext.grid.GroupingView}, this option
   * may be used to specify the function used to format the grouping field value for display in the group
   * {@link #groupName header}.  If a <tt><b>groupRenderer</b></tt> is not specified, the configured
   * <tt><b>{@link #renderer}</b></tt> will be called; if a <tt><b>{@link #renderer}</b></tt> is also not specified
   * the new value of the group field will be used.</p>
   * <p>The called function (either the <tt><b>groupRenderer</b></tt> or <tt><b>{@link #renderer}</b></tt>) will be
   * passed the following parameters:
   * <div class="mdetail-params"><ul>
   * <li><b>v</b> : Object<p class="sub-desc">The new value of the group field.</p></li>
   * <li><b>unused</b> : undefined<p class="sub-desc">Unused parameter.</p></li>
   * <li><b>r</b> : Ext.data.Record<p class="sub-desc">The Record providing the data
   * for the row which caused group change.</p></li>
   * <li><b>rowIndex</b> : Number<p class="sub-desc">The row index of the Record which caused group change.</p></li>
   * <li><b>colIndex</b> : Number<p class="sub-desc">The column index of the group field.</p></li>
   * <li><b>ds</b> : Ext.data.Store<p class="sub-desc">The Store which is providing the data Model.</p></li>
   * </ul></div></p>
   * <p>The function should return a string value.</p>
   */

  /**
   * @cfg {String} emptyGroupText Optional. If the grid is being rendered by an {@link Ext.grid.GroupingView}, this option
   * may be used to specify the text to display when there is an empty group value. Defaults to the
   * {@link Ext.grid.GroupingView}.{@link Ext.grid.GroupingView#emptyGroupText emptyGroupText}.
   */

  /**
   * @cfg {String} dataIndex <p><b>Required</b>. The name of the field in the
   * grid's {@link Ext.data.Store}'s {@link Ext.data.Record} definition from
   * which to draw the column's value.</p>
   */

  /**
   * @cfg {Number} width
   * Optional. The initial width in pixels of the column.
   * The width of each column can also be affected if any of the following are configured:
   * <div class="mdetail-params"><ul>
   * <li>{@link Ext.grid.GridPanel}.<tt>{@link Ext.grid.GridPanel#autoExpandColumn autoExpandColumn}</tt></li>
   * <li>{@link Ext.grid.GridView}.<tt>{@link Ext.grid.GridView#forceFit forceFit}</tt>
   * <div class="sub-desc">
   * <p>By specifying <tt>forceFit:true</tt>, {@link #fixed non-fixed width} columns will be
   * re-proportioned (based on the relative initial widths) to fill the width of the grid so
   * that no horizontal scrollbar is shown.</p>
   * </div></li>
   * <li>{@link Ext.grid.GridView}.<tt>{@link Ext.grid.GridView#autoFill autoFill}</tt></li>
   * <li>{@link Ext.grid.GridPanel}.<tt>{@link Ext.grid.GridPanel#minColumnWidth minColumnWidth}</tt></li>
   * <br><p><b>Note</b>: when the width of each column is determined, a space on the right side
   * is reserved for the vertical scrollbar.  The
   * {@link Ext.grid.GridView}.<tt>{@link Ext.grid.GridView#scrollOffset scrollOffset}</tt>
   * can be modified to reduce or eliminate the reserved offset.</p>
   */

  /**
   * @cfg {Boolean} sortable Optional. <tt>true</tt> if sorting is to be allowed on this column.
   * Defaults to the value of the <code>{@link Ext.grid.ColumnModel#defaultSortable}</code> property.
   * Whether local/remote sorting is used is specified in <code>{@link Ext.data.Store#remoteSort}</code>.
   */

  /**
   * @cfg {Boolean} fixed Optional. <tt>true</tt> if the column width cannot be changed.  Defaults to <tt>false</tt>.
   */

  /**
   * @cfg {Boolean} resizable Optional. <tt>false</tt> to disable column resizing. Defaults to <tt>true</tt>.
   */

  /**
   * @cfg {Boolean} menuDisabled Optional. <tt>true</tt> to disable the column menu. Defaults to <tt>false</tt>.
   */

  /**
   * @cfg {Boolean} hidden
   * Optional. <tt>true</tt> to initially hide this column. Defaults to <tt>false</tt>.
   * A hidden column {@link Ext.grid.GridPanel#enableColumnHide may be shown via the header row menu}.
   * If a column is never to be shown, simply do not include this column in the Column Model at all. 
   */

  /**
   * @cfg {String} tooltip Optional. A text string to use as the column header's tooltip.  If Quicktips
   * are enabled, this value will be used as the text of the quick tip, otherwise it will be set as the
   * header's HTML title attribute. Defaults to ''.
   */

  /**
   * @cfg {Mixed} renderer
   * <p>For an alternative to specifying a renderer see <code>{@link #xtype}</code></p>
   * <p>Optional. A renderer is an 'interceptor' method which can be used transform data (value,
   * appearance, etc.) before it is rendered). This may be specified in either of three ways:
   * <div class="mdetail-params"><ul>
   * <li>A renderer function used to return HTML markup for a cell given the cell's data value.</li>
   * <li>A string which references a property name of the {@link Ext.util.Format} class which
   * provides a renderer function.</li>
   * <li>An object specifying both the renderer function, and its execution scope (<tt><b>this</b></tt>
   * reference) e.g.:<pre style="margin-left:1.2em"><code>
  {
  fn: this.gridRenderer,
  scope: this
  }
  </code></pre></li></ul></div>
   * If not specified, the default renderer uses the raw data value.</p>
   * <p>For information about the renderer function (passed parameters, etc.), see
   * {@link Ext.grid.ColumnModel#setRenderer}. An example of specifying renderer function inline:</p><pre><code>
  var companyColumn = {
  header: 'Company Name',
  dataIndex: 'company',
  renderer: function(value, metaData, record, rowIndex, colIndex, store) {
    // provide the logic depending on business rules
    // name of your own choosing to manipulate the cell depending upon
    // the data in the underlying Record object.
    if (value == 'whatever') {
        //metaData.css : String : A CSS class name to add to the TD element of the cell.
        //metaData.attr : String : An html attribute definition string to apply to
        //                         the data container element within the table
        //                         cell (e.g. 'style="color:red;"').
        metaData.css = 'name-of-css-class-you-will-define';
    }
    return value;
  }
  }
   * </code></pre>
   * See also {@link #scope}.
   */

  /**
   * @cfg {String} xtype Optional. A String which references a predefined {@link Ext.grid.Column} subclass
   * type which is preconfigured with an appropriate <code>{@link #renderer}</code> to be easily
   * configured into a ColumnModel. The predefined {@link Ext.grid.Column} subclass types are:
   * <div class="mdetail-params"><ul>
   * <li><b><tt>gridcolumn</tt></b> : {@link Ext.grid.Column} (<b>Default</b>)<p class="sub-desc"></p></li>
   * <li><b><tt>booleancolumn</tt></b> : {@link Ext.grid.BooleanColumn}<p class="sub-desc"></p></li>
   * <li><b><tt>numbercolumn</tt></b> : {@link Ext.grid.NumberColumn}<p class="sub-desc"></p></li>
   * <li><b><tt>datecolumn</tt></b> : {@link Ext.grid.DateColumn}<p class="sub-desc"></p></li>
   * <li><b><tt>templatecolumn</tt></b> : {@link Ext.grid.TemplateColumn}<p class="sub-desc"></p></li>
   * </ul></div>
   * <p>Configuration properties for the specified <code>xtype</code> may be specified with
   * the Column configuration properties, for example:</p>
   * <pre><code>
  var grid = new Ext.grid.GridPanel({
  ...
  columns: [{
      header: 'Last Updated',
      dataIndex: 'lastChange',
      width: 85,
      sortable: true,
      //renderer: Ext.util.Format.dateRenderer('m/d/Y'),
      xtype: 'datecolumn', // use xtype instead of renderer
      format: 'M/d/Y' // configuration property for {@link Ext.grid.DateColumn}
  }, {
      ...
  }]
  });
   * </code></pre>
   */

  /**
   * @cfg {Object} scope Optional. The scope (<tt><b>this</b></tt> reference) in which to execute the
   * renderer.  Defaults to the Column configuration object.
   */

  /**
   * @cfg {String} align Optional. Set the CSS text-align property of the column.  Defaults to undefined.
   */

  /**
   * @cfg {String} css Optional. An inline style definition string which is applied to all table cells in the column
   * (excluding headers). Defaults to undefined.
   */

  /**
   * @cfg {Boolean} hideable Optional. Specify as <tt>false</tt> to prevent the user from hiding this column
   * (defaults to true).  To disallow column hiding globally for all columns in the grid, use
   * {@link Ext.grid.GridPanel#enableColumnHide} instead.
   */

  /**
   * @cfg {Ext.form.Field} editor Optional. The {@link Ext.form.Field} to use when editing values in this column
   * if editing is supported by the grid. See <tt>{@link #editable}</tt> also.
   */

  /**
   * @private
   * @cfg {Boolean} isColumn
   * Used by ColumnModel setConfig method to avoid reprocessing a Column
   * if <code>isColumn</code> is not set ColumnModel will recreate a new Ext.grid.Column
   * Defaults to true.
   */
  isColumn: true,
  constructor: function constructor(config) {
    Ext.apply(this, config);

    if (Ext.isString(this.renderer)) {
      this.renderer = Ext.util.Format[this.renderer];
    } else if (Ext.isObject(this.renderer)) {
      this.scope = this.renderer.scope;
      this.renderer = this.renderer.fn;
    }

    if (!this.scope) {
      this.scope = this;
    }

    this.tooltip = this.tooltip ? this.tooltip : Ext.util.Format.htmlEncode(this.header);
    var ed = this.editor;
    delete this.editor;
    this.setEditor(ed);
  },

  /**
   * Optional. A function which returns displayable data when passed the following parameters:
   * <div class="mdetail-params"><ul>
   * <li><b>value</b> : Object<p class="sub-desc">The data value for the cell.</p></li>
   * <li><b>metadata</b> : Object<p class="sub-desc">An object in which you may set the following attributes:<ul>
   * <li><b>css</b> : String<p class="sub-desc">A CSS class name to add to the cell's TD element.</p></li>
   * <li><b>attr</b> : String<p class="sub-desc">An HTML attribute definition string to apply to the data container
   * element <i>within</i> the table cell (e.g. 'style="color:red;"').</p></li></ul></p></li>
   * <li><b>record</b> : Ext.data.record<p class="sub-desc">The {@link Ext.data.Record} from which the data was
   * extracted.</p></li>
   * <li><b>rowIndex</b> : Number<p class="sub-desc">Row index</p></li>
   * <li><b>colIndex</b> : Number<p class="sub-desc">Column index</p></li>
   * <li><b>store</b> : Ext.data.Store<p class="sub-desc">The {@link Ext.data.Store} object from which the Record
   * was extracted.</p></li>
   * </ul></div>
   * @property renderer
   * @type Function
   */
  renderer: function renderer(value) {
    if (Ext.isString(value) && value.length < 1) {
      return '&#160;';
    }

    return value;
  },
  // private
  getEditor: function getEditor(rowIndex) {
    return this.editable !== false ? this.editor : null;
  },

  /**
   * Sets a new editor for this column.
   * @param {Ext.Editor/Ext.form.Field} editor The editor to set
   */
  setEditor: function setEditor(editor) {
    if (this.editor) {
      this.editor.destroy();
    }

    this.editor = null;

    if (editor) {
      //not an instance, create it
      if (!editor.isXType) {
        editor = Ext.create(editor, 'textfield');
      } //check if it's wrapped in an editor


      if (!editor.startEdit) {
        editor = new Ext.grid.GridEditor(editor);
      }

      this.editor = editor;
    }
  },
  destroy: function destroy() {
    this.setEditor(null);
  },

  /**
   * Returns the {@link Ext.Editor editor} defined for this column that was created to wrap the {@link Ext.form.Field Field}
   * used to edit the cell.
   * @param {Number} rowIndex The row index
   * @return {Ext.Editor}
   */
  getCellEditor: function getCellEditor(rowIndex) {
    return this.getEditor(rowIndex);
  }
});
/**
 * @class Ext.grid.BooleanColumn
 * @extends Ext.grid.Column
 * <p>A Column definition class which renders boolean data fields.  See the {@link Ext.grid.Column#xtype xtype}
 * config option of {@link Ext.grid.Column} for more details.</p>
 */

Ext.grid.BooleanColumn = Ext.extend(Ext.grid.Column, {
  /**
   * @cfg {String} trueText
   * The string returned by the renderer when the column value is not falsey (defaults to <tt>'true'</tt>).
   */
  trueText: 'true',

  /**
   * @cfg {String} falseText
   * The string returned by the renderer when the column value is falsey (but not undefined) (defaults to
   * <tt>'false'</tt>).
   */
  falseText: 'false',

  /**
   * @cfg {String} undefinedText
   * The string returned by the renderer when the column value is undefined (defaults to <tt>'&#160;'</tt>).
   */
  undefinedText: '&#160;',
  constructor: function constructor(cfg) {
    Ext.grid.BooleanColumn.superclass.constructor.call(this, cfg);
    var t = this.trueText,
        f = this.falseText,
        u = this.undefinedText;

    this.renderer = function (v) {
      if (v === undefined) {
        return u;
      }

      if (!v || v === 'false') {
        return f;
      }

      return t;
    };
  }
});
/**
 * @class Ext.grid.NumberColumn
 * @extends Ext.grid.Column
 * <p>A Column definition class which renders a numeric data field according to a {@link #format} string.  See the
 * {@link Ext.grid.Column#xtype xtype} config option of {@link Ext.grid.Column} for more details.</p>
 */

Ext.grid.NumberColumn = Ext.extend(Ext.grid.Column, {
  /**
   * @cfg {String} format
   * A formatting string as used by {@link Ext.util.Format#number} to format a numeric value for this Column
   * (defaults to <tt>'0,000.00'</tt>).
   */
  format: '0,000.00',
  constructor: function constructor(cfg) {
    Ext.grid.NumberColumn.superclass.constructor.call(this, cfg);
    this.renderer = Ext.util.Format.numberRenderer(this.format);
  }
});
/**
 * @class Ext.grid.DateColumn
 * @extends Ext.grid.Column
 * <p>A Column definition class which renders a passed date according to the default locale, or a configured
 * {@link #format}. See the {@link Ext.grid.Column#xtype xtype} config option of {@link Ext.grid.Column}
 * for more details.</p>
 */

Ext.grid.DateColumn = Ext.extend(Ext.grid.Column, {
  /**
   * @cfg {String} format
   * A formatting string as used by {@link Date#format} to format a Date for this Column
   * (defaults to <tt>'m/d/Y'</tt>).
   */
  format: 'm/d/Y',
  constructor: function constructor(cfg) {
    Ext.grid.DateColumn.superclass.constructor.call(this, cfg);
    this.renderer = Ext.util.Format.dateRenderer(this.format);
  }
});
/**
 * @class Ext.grid.TemplateColumn
 * @extends Ext.grid.Column
 * <p>A Column definition class which renders a value by processing a {@link Ext.data.Record Record}'s
 * {@link Ext.data.Record#data data} using a {@link #tpl configured} {@link Ext.XTemplate XTemplate}.
 * See the {@link Ext.grid.Column#xtype xtype} config option of {@link Ext.grid.Column} for more
 * details.</p>
 */

Ext.grid.TemplateColumn = Ext.extend(Ext.grid.Column, {
  /**
   * @cfg {String/XTemplate} tpl
   * An {@link Ext.XTemplate XTemplate}, or an XTemplate <i>definition string</i> to use to process a
   * {@link Ext.data.Record Record}'s {@link Ext.data.Record#data data} to produce a column's rendered value.
   */
  constructor: function constructor(cfg) {
    Ext.grid.TemplateColumn.superclass.constructor.call(this, cfg);
    var tpl = !Ext.isPrimitive(this.tpl) && this.tpl.compile ? this.tpl : new Ext.XTemplate(this.tpl);

    this.renderer = function (value, p, r) {
      return tpl.apply(r.data);
    };

    this.tpl = tpl;
  }
});
/*
 * @property types
 * @type Object
 * @member Ext.grid.Column
 * @static
 * <p>An object containing predefined Column classes keyed by a mnemonic code which may be referenced
 * by the {@link Ext.grid.ColumnModel#xtype xtype} config option of ColumnModel.</p>
 * <p>This contains the following properties</p><div class="mdesc-details"><ul>
 * <li>gridcolumn : <b>{@link Ext.grid.Column Column constructor}</b></li>
 * <li>booleancolumn : <b>{@link Ext.grid.BooleanColumn BooleanColumn constructor}</b></li>
 * <li>numbercolumn : <b>{@link Ext.grid.NumberColumn NumberColumn constructor}</b></li>
 * <li>datecolumn : <b>{@link Ext.grid.DateColumn DateColumn constructor}</b></li>
 * <li>templatecolumn : <b>{@link Ext.grid.TemplateColumn TemplateColumn constructor}</b></li>
 * </ul></div>
 */

Ext.grid.Column.types = {
  gridcolumn: Ext.grid.Column,
  booleancolumn: Ext.grid.BooleanColumn,
  numbercolumn: Ext.grid.NumberColumn,
  datecolumn: Ext.grid.DateColumn,
  templatecolumn: Ext.grid.TemplateColumn
};

/***/ }),
/* 899 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.RowNumberer
 * This is a utility class that can be passed into a {@link Ext.grid.ColumnModel} as a column config that provides
 * an automatic row numbering column.
 * <br>Usage:<br>
 <pre><code>
 // This is a typical column config with the first column providing row numbers
 var colModel = new Ext.grid.ColumnModel([
    new Ext.grid.RowNumberer(),
    {header: "Name", width: 80, sortable: true},
    {header: "Code", width: 50, sortable: true},
    {header: "Description", width: 200, sortable: true}
 ]);
 </code></pre>
 * @constructor
 * @param {Object} config The configuration options
 */
Ext.grid.RowNumberer = Ext.extend(Object, {
  /**
   * @cfg {String} header Any valid text or HTML fragment to display in the header cell for the row
   * number column (defaults to '').
   */
  header: "",

  /**
   * @cfg {Number} width The default width in pixels of the row number column (defaults to 23).
   */
  width: 23,

  /**
   * @cfg {Boolean} sortable True if the row number column is sortable (defaults to false).
   * @hide
   */
  sortable: false,
  constructor: function constructor(config) {
    Ext.apply(this, config);

    if (this.rowspan) {
      this.renderer = this.renderer.createDelegate(this);
    }
  },
  // private
  fixed: true,
  menuDisabled: true,
  dataIndex: '',
  id: 'numberer',
  rowspan: undefined,
  // private
  renderer: function renderer(v, p, record, rowIndex) {
    if (this.rowspan) {
      p.cellAttr = 'rowspan="' + this.rowspan + '"';
    }

    return rowIndex + 1;
  }
});

/***/ }),
/* 900 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.CheckboxSelectionModel
 * @extends Ext.grid.RowSelectionModel
 * A custom selection model that renders a column of checkboxes that can be toggled to select or deselect rows.
 * @constructor
 * @param {Object} config The configuration options
 */
Ext.grid.CheckboxSelectionModel = Ext.extend(Ext.grid.RowSelectionModel, {
  /**
   * @cfg {Boolean} checkOnly <tt>true</tt> if rows can only be selected by clicking on the
   * checkbox column (defaults to <tt>false</tt>).
   */

  /**
   * @cfg {String} header Any valid text or HTML fragment to display in the header cell for the
   * checkbox column.  Defaults to:<pre><code>
   * '&lt;div class="x-grid3-hd-checker">&#38;#160;&lt;/div>'</tt>
   * </code></pre>
   * The default CSS class of <tt>'x-grid3-hd-checker'</tt> displays a checkbox in the header
   * and provides support for automatic check all/none behavior on header click. This string
   * can be replaced by any valid HTML fragment, including a simple text string (e.g.,
   * <tt>'Select Rows'</tt>), but the automatic check all/none behavior will only work if the
   * <tt>'x-grid3-hd-checker'</tt> class is supplied.
   */
  header: '<div class="x-grid3-hd-checker">&#160;</div>',

  /**
   * @cfg {Number} width The default width in pixels of the checkbox column (defaults to <tt>20</tt>).
   */
  width: 20,

  /**
   * @cfg {Boolean} sortable <tt>true</tt> if the checkbox column is sortable (defaults to
   * <tt>false</tt>).
   */
  sortable: false,
  // private
  menuDisabled: true,
  fixed: true,
  dataIndex: '',
  id: 'checker',
  constructor: function constructor() {
    Ext.grid.CheckboxSelectionModel.superclass.constructor.apply(this, arguments);

    if (this.checkOnly) {
      this.handleMouseDown = Ext.emptyFn;
    }
  },
  // private
  initEvents: function initEvents() {
    Ext.grid.CheckboxSelectionModel.superclass.initEvents.call(this);
    this.grid.on('render', function () {
      var view = this.grid.getView();
      view.mainBody.on('mousedown', this.onMouseDown, this);
      Ext.fly(view.innerHd).on('mousedown', this.onHdMouseDown, this);
    }, this);
  },
  // private
  onMouseDown: function onMouseDown(e, t) {
    if (e.button === 0 && t.className == 'x-grid3-row-checker') {
      // Only fire if left-click
      e.stopEvent();
      var row = e.getTarget('.x-grid3-row');

      if (row) {
        var index = row.rowIndex;

        if (this.isSelected(index)) {
          this.deselectRow(index);
        } else {
          this.selectRow(index, true);
        }
      }
    }
  },
  // private
  onHdMouseDown: function onHdMouseDown(e, t) {
    if (t.className == 'x-grid3-hd-checker') {
      e.stopEvent();
      var hd = Ext.fly(t.parentNode);
      var isChecked = hd.hasClass('x-grid3-hd-checker-on');

      if (isChecked) {
        hd.removeClass('x-grid3-hd-checker-on');
        this.clearSelections();
      } else {
        hd.addClass('x-grid3-hd-checker-on');
        this.selectAll();
      }
    }
  },
  // private
  renderer: function renderer(v, p, record) {
    return '<div class="x-grid3-row-checker">&#160;</div>';
  }
});

/***/ }),
/* 901 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.CellSelectionModel
 * @extends Ext.grid.AbstractSelectionModel
 * This class provides the basic implementation for <i>single</i> <b>cell</b> selection in a grid.
 * The object stored as the selection contains the following properties:
 * <div class="mdetail-params"><ul>
 * <li><b>cell</b> : see {@link #getSelectedCell} 
 * <li><b>record</b> : Ext.data.record The {@link Ext.data.Record Record}
 * which provides the data for the row containing the selection</li>
 * </ul></div>
 * @constructor
 * @param {Object} config The object containing the configuration of this model.
 */
Ext.grid.CellSelectionModel = Ext.extend(Ext.grid.AbstractSelectionModel, {
  constructor: function constructor(config) {
    Ext.apply(this, config);
    this.selection = null;
    this.addEvents(
    /**
     * @event beforecellselect
     * Fires before a cell is selected, return false to cancel the selection.
     * @param {SelectionModel} this
     * @param {Number} rowIndex The selected row index
     * @param {Number} colIndex The selected cell index
     */
    "beforecellselect",
    /**
     * @event cellselect
     * Fires when a cell is selected.
     * @param {SelectionModel} this
     * @param {Number} rowIndex The selected row index
     * @param {Number} colIndex The selected cell index
     */
    "cellselect",
    /**
     * @event selectionchange
     * Fires when the active selection changes.
     * @param {SelectionModel} this
     * @param {Object} selection null for no selection or an object with two properties
     * <div class="mdetail-params"><ul>
     * <li><b>cell</b> : see {@link #getSelectedCell} 
     * <li><b>record</b> : Ext.data.record<p class="sub-desc">The {@link Ext.data.Record Record}
     * which provides the data for the row containing the selection</p></li>
     * </ul></div>
     */
    "selectionchange");
    Ext.grid.CellSelectionModel.superclass.constructor.call(this);
  },

  /** @ignore */
  initEvents: function initEvents() {
    this.grid.on('cellmousedown', this.handleMouseDown, this);
    this.grid.on(Ext.EventManager.useKeydown ? 'keydown' : 'keypress', this.handleKeyDown, this);
    this.grid.getView().on({
      scope: this,
      refresh: this.onViewChange,
      rowupdated: this.onRowUpdated,
      beforerowremoved: this.clearSelections,
      beforerowsinserted: this.clearSelections
    });

    if (this.grid.isEditor) {
      this.grid.on('beforeedit', this.beforeEdit, this);
    }
  },
  //private
  beforeEdit: function beforeEdit(e) {
    this.select(e.row, e.column, false, true, e.record);
  },
  //private
  onRowUpdated: function onRowUpdated(v, index, r) {
    if (this.selection && this.selection.record == r) {
      v.onCellSelect(index, this.selection.cell[1]);
    }
  },
  //private
  onViewChange: function onViewChange() {
    this.clearSelections(true);
  },

  /**
      * Returns an array containing the row and column indexes of the currently selected cell
      * (e.g., [0, 0]), or null if none selected. The array has elements:
      * <div class="mdetail-params"><ul>
      * <li><b>rowIndex</b> : Number<p class="sub-desc">The index of the selected row</p></li>
      * <li><b>cellIndex</b> : Number<p class="sub-desc">The index of the selected cell. 
      * Due to possible column reordering, the cellIndex should <b>not</b> be used as an
      * index into the Record's data. Instead, use the cellIndex to determine the <i>name</i>
      * of the selected cell and use the field name to retrieve the data value from the record:<pre><code>
  // get name
  var fieldName = grid.getColumnModel().getDataIndex(cellIndex);
  // get data value based on name
  var data = record.get(fieldName);
      * </code></pre></p></li>
      * </ul></div>
      * @return {Array} An array containing the row and column indexes of the selected cell, or null if none selected.
   */
  getSelectedCell: function getSelectedCell() {
    return this.selection ? this.selection.cell : null;
  },

  /**
   * If anything is selected, clears all selections and fires the selectionchange event.
   * @param {Boolean} preventNotify <tt>true</tt> to prevent the gridview from
   * being notified about the change.
   */
  clearSelections: function clearSelections(preventNotify) {
    var s = this.selection;

    if (s) {
      if (preventNotify !== true) {
        this.grid.view.onCellDeselect(s.cell[0], s.cell[1]);
      }

      this.selection = null;
      this.fireEvent("selectionchange", this, null);
    }
  },

  /**
   * Returns <tt>true</tt> if there is a selection.
   * @return {Boolean}
   */
  hasSelection: function hasSelection() {
    return this.selection ? true : false;
  },

  /** @ignore */
  handleMouseDown: function handleMouseDown(g, row, cell, e) {
    if (e.button !== 0 || this.isLocked()) {
      return;
    }

    this.select(row, cell);
  },

  /**
   * Selects a cell.  Before selecting a cell, fires the
   * {@link #beforecellselect} event.  If this check is satisfied the cell
   * will be selected and followed up by  firing the {@link #cellselect} and
   * {@link #selectionchange} events.
   * @param {Number} rowIndex The index of the row to select
   * @param {Number} colIndex The index of the column to select
   * @param {Boolean} preventViewNotify (optional) Specify <tt>true</tt> to
   * prevent notifying the view (disables updating the selected appearance)
   * @param {Boolean} preventFocus (optional) Whether to prevent the cell at
   * the specified rowIndex / colIndex from being focused.
   * @param {Ext.data.Record} r (optional) The record to select
   */
  select: function select(rowIndex, colIndex, preventViewNotify, preventFocus,
  /*internal*/
  r) {
    if (this.fireEvent("beforecellselect", this, rowIndex, colIndex) !== false) {
      this.clearSelections();
      r = r || this.grid.store.getAt(rowIndex);
      this.selection = {
        record: r,
        cell: [rowIndex, colIndex]
      };

      if (!preventViewNotify) {
        var v = this.grid.getView();
        v.onCellSelect(rowIndex, colIndex);

        if (preventFocus !== true) {
          v.focusCell(rowIndex, colIndex);
        }
      }

      this.fireEvent("cellselect", this, rowIndex, colIndex);
      this.fireEvent("selectionchange", this, this.selection);
    }
  },
  //private
  isSelectable: function isSelectable(rowIndex, colIndex, cm) {
    return !cm.isHidden(colIndex);
  },
  // private
  onEditorKey: function onEditorKey(field, e) {
    if (e.getKey() == e.TAB) {
      this.handleKeyDown(e);
    }
  },

  /** @ignore */
  handleKeyDown: function handleKeyDown(e) {
    if (!e.isNavKeyPress()) {
      return;
    }

    var k = e.getKey(),
        g = this.grid,
        s = this.selection,
        sm = this,
        walk = function walk(row, col, step) {
      return g.walkCells(row, col, step, g.isEditor && g.editing ? sm.acceptsNav : sm.isSelectable, // *** handle tabbing while editorgrid is in edit mode
      sm);
    },
        cell,
        newCell,
        r,
        c,
        ae;

    switch (k) {
      case e.ESC:
      case e.PAGE_UP:
      case e.PAGE_DOWN:
        // do nothing
        break;

      default:
        // *** call e.stopEvent() only for non ESC, PAGE UP/DOWN KEYS
        e.stopEvent();
        break;
    }

    if (!s) {
      cell = walk(0, 0, 1); // *** use private walk() function defined above

      if (cell) {
        this.select(cell[0], cell[1]);
      }

      return;
    }

    cell = s.cell; // currently selected cell

    r = cell[0]; // current row

    c = cell[1]; // current column

    switch (k) {
      case e.TAB:
        if (e.shiftKey) {
          newCell = walk(r, c - 1, -1);
        } else {
          newCell = walk(r, c + 1, 1);
        }

        break;

      case e.DOWN:
        newCell = walk(r + 1, c, 1);
        break;

      case e.UP:
        newCell = walk(r - 1, c, -1);
        break;

      case e.RIGHT:
        newCell = walk(r, c + 1, 1);
        break;

      case e.LEFT:
        newCell = walk(r, c - 1, -1);
        break;

      case e.ENTER:
        if (g.isEditor && !g.editing) {
          g.startEditing(r, c);
          return;
        }

        break;
    }

    if (newCell) {
      // *** reassign r & c variables to newly-selected cell's row and column
      r = newCell[0];
      c = newCell[1];
      this.select(r, c); // *** highlight newly-selected cell and update selection

      if (g.isEditor && g.editing) {
        // *** handle tabbing while editorgrid is in edit mode
        ae = g.activeEditor;

        if (ae && ae.field.triggerBlur) {
          // *** if activeEditor is a TriggerField, explicitly call its triggerBlur() method
          ae.field.triggerBlur();
        }

        g.startEditing(r, c);
      }
    }
  },
  acceptsNav: function acceptsNav(row, col, cm) {
    return !cm.isHidden(col) && cm.isCellEditable(col, row);
  }
});

/***/ }),
/* 902 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.EditorGridPanel
 * @extends Ext.grid.GridPanel
 * <p>This class extends the {@link Ext.grid.GridPanel GridPanel Class} to provide cell editing
 * on selected {@link Ext.grid.Column columns}. The editable columns are specified by providing
 * an {@link Ext.grid.ColumnModel#editor editor} in the {@link Ext.grid.Column column configuration}.</p>
 * <p>Editability of columns may be controlled programatically by inserting an implementation
 * of {@link Ext.grid.ColumnModel#isCellEditable isCellEditable} into the
 * {@link Ext.grid.ColumnModel ColumnModel}.</p>
 * <p>Editing is performed on the value of the <i>field</i> specified by the column's
 * <tt>{@link Ext.grid.ColumnModel#dataIndex dataIndex}</tt> in the backing {@link Ext.data.Store Store}
 * (so if you are using a {@link Ext.grid.ColumnModel#setRenderer renderer} in order to display
 * transformed data, this must be accounted for).</p>
 * <p>If a value-to-description mapping is used to render a column, then a {@link Ext.form.Field#ComboBox ComboBox}
 * which uses the same {@link Ext.form.Field#valueField value}-to-{@link Ext.form.Field#displayFieldField description}
 * mapping would be an appropriate editor.</p>
 * If there is a more complex mismatch between the visible data in the grid, and the editable data in
 * the {@link Edt.data.Store Store}, then code to transform the data both before and after editing can be
 * injected using the {@link #beforeedit} and {@link #afteredit} events.
 * @constructor
 * @param {Object} config The config object
 * @xtype editorgrid
 */
Ext.grid.EditorGridPanel = Ext.extend(Ext.grid.GridPanel, {
  /**
   * @cfg {Number} clicksToEdit
   * <p>The number of clicks on a cell required to display the cell's editor (defaults to 'auto').</p>
   * <p>Setting this option to 'auto' means that mousedown <i>on the selected cell</i> starts
   * editing that cell.</p>
   */
  clicksToEdit: 'auto',

  /**
  * @cfg {Boolean} forceValidation
  * True to force validation even if the value is unmodified (defaults to false)
  */
  forceValidation: false,
  // private
  isEditor: true,
  // private
  detectEdit: false,

  /**
   * @cfg {Boolean} autoEncode
   * True to automatically HTML encode and decode values pre and post edit (defaults to false)
   */
  autoEncode: false,

  /**
   * @cfg {Boolean} trackMouseOver @hide
   */
  // private
  trackMouseOver: false,
  // causes very odd FF errors
  // private
  initComponent: function initComponent() {
    Ext.grid.EditorGridPanel.superclass.initComponent.call(this);

    if (!this.selModel) {
      /**
       * @cfg {Object} selModel Any subclass of AbstractSelectionModel that will provide the selection model for
       * the grid (defaults to {@link Ext.grid.CellSelectionModel} if not specified).
       */
      this.selModel = new Ext.grid.CellSelectionModel();
    }

    this.activeEditor = null;
    this.addEvents(
    /**
     * @event beforeedit
     * Fires before cell editing is triggered. The edit event object has the following properties <br />
     * <ul style="padding:5px;padding-left:16px;">
     * <li>grid - This grid</li>
     * <li>record - The record being edited</li>
     * <li>field - The field name being edited</li>
     * <li>value - The value for the field being edited.</li>
     * <li>row - The grid row index</li>
     * <li>column - The grid column index</li>
     * <li>cancel - Set this to true to cancel the edit or return false from your handler.</li>
     * </ul>
     * @param {Object} e An edit event (see above for description)
     */
    "beforeedit",
    /**
     * @event afteredit
     * Fires after a cell is edited. The edit event object has the following properties <br />
     * <ul style="padding:5px;padding-left:16px;">
     * <li>grid - This grid</li>
     * <li>record - The record being edited</li>
     * <li>field - The field name being edited</li>
     * <li>value - The value being set</li>
     * <li>originalValue - The original value for the field, before the edit.</li>
     * <li>row - The grid row index</li>
     * <li>column - The grid column index</li>
     * </ul>
     *
     * <pre><code>
    grid.on('afteredit', afterEdit, this );
    function afterEdit(e) {
    // execute an XHR to send/commit data to the server, in callback do (if successful):
    e.record.commit();
    };
     * </code></pre>
     * @param {Object} e An edit event (see above for description)
     */
    "afteredit",
    /**
     * @event validateedit
     * Fires after a cell is edited, but before the value is set in the record. Return false
     * to cancel the change. The edit event object has the following properties <br />
     * <ul style="padding:5px;padding-left:16px;">
     * <li>grid - This grid</li>
     * <li>record - The record being edited</li>
     * <li>field - The field name being edited</li>
     * <li>value - The value being set</li>
     * <li>originalValue - The original value for the field, before the edit.</li>
     * <li>row - The grid row index</li>
     * <li>column - The grid column index</li>
     * <li>cancel - Set this to true to cancel the edit or return false from your handler.</li>
     * </ul>
     * Usage example showing how to remove the red triangle (dirty record indicator) from some
     * records (not all).  By observing the grid's validateedit event, it can be cancelled if
     * the edit occurs on a targeted row (for example) and then setting the field's new value
     * in the Record directly:
     * <pre><code>
    grid.on('validateedit', function(e) {
    var myTargetRow = 6;
    if (e.row == myTargetRow) {
    e.cancel = true;
    e.record.data[e.field] = e.value;
    }
    });
     * </code></pre>
     * @param {Object} e An edit event (see above for description)
     */
    "validateedit");
  },
  // private
  initEvents: function initEvents() {
    Ext.grid.EditorGridPanel.superclass.initEvents.call(this);
    this.on('beforeedit', this.onBeforeEdit, this);
    this.getGridEl().on('mousewheel', this.stopEditing.createDelegate(this, [true]), this);
    this.on('columnresize', this.stopEditing, this, [true]);

    if (this.clicksToEdit === 1) {
      this.on("cellclick", this.onCellDblClick, this);
    } else {
      var view = this.getView();

      if (this.clicksToEdit === 'auto' && view.mainBody) {
        view.mainBody.on('mousedown', this.onAutoEditClick, this);
        this.selModel.on('selectionchange', this.denyEdit, this);
        this.on('dblclick', this.denyEdit, this);

        if (this.view.dragZone) {
          (() => {
            // this.view.dragZone.onBeforeDrag = this.view.dragZone.onBeforeDrag.createInterceptor(() => {
            //     this.stopEditing(true);
            // });
            this.view.dragZone.onInitDrag = this.view.dragZone.onInitDrag.createSequence(() => {
              this.denyEdit();
              this.stopEditing(true);
            });
          }).defer(500);
        }

        ;
      }

      this.on('celldblclick', this.onCellDblClick, this);
    }
  },
  onResize: function onResize() {
    Ext.grid.EditorGridPanel.superclass.onResize.apply(this, arguments);
    var ae = this.activeEditor;

    if (this.editing && ae) {
      ae.realign(true);
    }
  },
  // private
  onCellDblClick: function onCellDblClick(g, row, col) {
    if (this.clicksToEdit === 'auto') {
      this.denyEdit();
    } else {
      this.startEditing(row, col);
    }
  },
  // private
  onAutoEditClick: function onAutoEditClick(e, t) {
    if (e.button !== 0) {
      return;
    }

    var row = this.view.findRowIndex(t),
        col = this.view.findCellIndex(t);

    if (row !== false && col !== false) {
      this.stopEditing();

      if (this.selModel.getSelectedCell) {
        // cell sm
        var sc = this.selModel.getSelectedCell();

        if (sc && sc[0] === row && sc[1] === col) {
          this.startEditingIf(row, col);
        }
      } else {
        if (this.selModel.isSelected(row)) {
          this.startEditingIf(row, col);
        }
      }
    }
  },
  // private
  onEditComplete: function onEditComplete(ed, value, startValue) {
    this.editing = false;
    this.activeEditor = null;
    var r = ed.record,
        field = this.colModel.getDataIndex(ed.col);
    value = this.postEditValue(value, startValue, r, field);

    if (this.forceValidation === true || String(value) !== String(startValue)) {
      var e = {
        grid: this,
        record: r,
        field: field,
        originalValue: startValue,
        value: value,
        row: ed.row,
        column: ed.col,
        cancel: false
      };

      if (this.fireEvent("validateedit", e) !== false && !e.cancel && String(value) !== String(startValue)) {
        r.set(field, e.value);
        delete e.cancel;
        this.fireEvent("afteredit", e);
      }
    }

    this.view.focusCell(ed.row, ed.col);
  },
  onBeforeEdit: function onBeforeEdit(o) {
    if (this.readOnly) {
      o.cancel = true;
    }
  },
  setReadOnly: function setReadOnly(readOnly) {
    this.readOnly = readOnly;
  },
  startEditingIf: async function startEditingIf(row, col) {
    let now = new Date().getTime(); // wait and see if we get a dblclick / dragstart

    if (now - this.editDenyTime > 300) {
      this.editDenyTime = now;
      await new Promise(fulfill => {
        window.setTimeout(fulfill, 300);
      });
      now = new Date().getTime();
    }

    if (now - this.editDenyTime >= 300) {
      return this.startEditing(row, col);
    }
  },
  denyEdit: function denyEdit() {
    this.editDenyTime = new Date().getTime();
  },

  /**
   * Starts editing the specified for the specified row/column
   * @param {Number} rowIndex
   * @param {Number} colIndex
   */
  startEditing: function startEditing(row, col) {
    this.stopEditing();

    if (this.colModel.isCellEditable(col, row)) {
      this.view.ensureVisible(row, col, true);
      var r = this.store.getAt(row),
          field = this.colModel.getDataIndex(col),
          e = {
        grid: this,
        record: r,
        field: field,
        value: r.data[field],
        row: row,
        column: col,
        cancel: false
      };

      if (this.fireEvent("beforeedit", e) !== false && !e.cancel) {
        this.editing = true;
        var ed = this.colModel.getCellEditor(col, row);

        if (!ed) {
          return;
        }

        if (!ed.rendered) {
          ed.parentEl = this.view.getEditorParent(ed);
          ed.on({
            scope: this,
            render: {
              fn: function fn(c) {
                c.field.focus(false, true);
              },
              single: true,
              scope: this
            },
            specialkey: function specialkey(field, e) {
              this.getSelectionModel().onEditorKey(field, e);
            },
            complete: this.onEditComplete,
            canceledit: this.stopEditing.createDelegate(this, [true])
          });
        }

        Ext.apply(ed, {
          row: row,
          col: col,
          record: r
        });
        this.lastEdit = {
          row: row,
          col: col
        };
        this.activeEditor = ed; // Set the selectSameEditor flag if we are reusing the same editor again and
        // need to prevent the editor from firing onBlur on itself.

        ed.selectSameEditor = this.activeEditor == this.lastActiveEditor;
        var v = this.preEditValue(r, field);
        ed.startEdit(this.view.getCell(row, col).firstChild, Ext.isDefined(v) ? v : '', r); // Clear the selectSameEditor flag

        (function () {
          delete ed.selectSameEditor;
        }).defer(50);
      }
    }
  },
  startEditingRecord: function startEditingRecord(record, property) {
    const row = this.store.indexOf(record);
    const cols = this.colModel.columns;

    const col = _.indexOf(cols, _.find(cols, {
      dataIndex: property
    }));

    this.startEditing(row, col);
  },
  // private
  preEditValue: function preEditValue(r, field) {
    var value = r.data[field];
    return this.autoEncode && Ext.isString(value) ? Ext.util.Format.htmlDecode(value) : value;
  },
  // private
  postEditValue: function postEditValue(value, originalValue, r, field) {
    return this.autoEncode && Ext.isString(value) ? Ext.util.Format.htmlEncode(value) : value;
  },

  /**
   * Stops any active editing
   * @param {Boolean} cancel (optional) True to cancel any changes
   */
  stopEditing: function stopEditing(cancel) {
    if (this.editing) {
      // Store the lastActiveEditor to check if it is changing
      var ae = this.lastActiveEditor = this.activeEditor;

      if (ae) {
        ae[cancel === true ? 'cancelEdit' : 'completeEdit']();
        this.view.focusCell(ae.row, ae.col);
      }

      this.activeEditor = null;
    }

    this.editing = false;
  }
});
Ext.reg('editorgrid', Ext.grid.EditorGridPanel);

/***/ }),
/* 903 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
// private
// This is a support class used internally by the Grid components
Ext.grid.GridEditor = function (field, config) {
  Ext.grid.GridEditor.superclass.constructor.call(this, field, config);
  field.monitorTab = false;
};

Ext.extend(Ext.grid.GridEditor, Ext.Editor, {
  alignment: "tl-tl",
  autoSize: "width",
  hideEl: false,
  cls: "x-small-editor x-grid-editor",
  shim: false,
  shadow: false
});

/***/ }),
/* 904 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.PropertyRecord
 * A specific {@link Ext.data.Record} type that represents a name/value pair and is made to work with the
 * {@link Ext.grid.PropertyGrid}.  Typically, PropertyRecords do not need to be created directly as they can be
 * created implicitly by simply using the appropriate data configs either via the {@link Ext.grid.PropertyGrid#source}
 * config property or by calling {@link Ext.grid.PropertyGrid#setSource}.  However, if the need arises, these records
 * can also be created explicitly as shwon below.  Example usage:
 * <pre><code>
var rec = new Ext.grid.PropertyRecord({
    name: 'Birthday',
    value: new Date(Date.parse('05/26/1972'))
});
// Add record to an already populated grid
grid.store.addSorted(rec);
</code></pre>
 * @constructor
 * @param {Object} config A data object in the format: {name: [name], value: [value]}.  The specified value's type
 * will be read automatically by the grid to determine the type of editor to use when displaying it.
 */
Ext.grid.PropertyRecord = Ext.data.Record.create([{
  name: 'name',
  type: 'string'
}, 'value']);
/**
 * @class Ext.grid.PropertyStore
 * @extends Ext.util.Observable
 * A custom wrapper for the {@link Ext.grid.PropertyGrid}'s {@link Ext.data.Store}. This class handles the mapping
 * between the custom data source objects supported by the grid and the {@link Ext.grid.PropertyRecord} format
 * required for compatibility with the underlying store. Generally this class should not need to be used directly --
 * the grid's data should be accessed from the underlying store via the {@link #store} property.
 * @constructor
 * @param {Ext.grid.Grid} grid The grid this store will be bound to
 * @param {Object} source The source data config object
 */

Ext.grid.PropertyStore = Ext.extend(Ext.util.Observable, {
  constructor: function constructor(grid, source) {
    this.grid = grid;
    this.store = new Ext.data.Store({
      recordType: Ext.grid.PropertyRecord
    });
    this.store.on('update', this.onUpdate, this);

    if (source) {
      this.setSource(source);
    }

    Ext.grid.PropertyStore.superclass.constructor.call(this);
  },
  // protected - should only be called by the grid.  Use grid.setSource instead.
  setSource: function setSource(o) {
    this.source = o;
    this.store.removeAll();
    var data = [];

    for (var k in o) {
      if (this.isEditableValue(o[k])) {
        data.push(new Ext.grid.PropertyRecord({
          name: k,
          value: o[k]
        }, k));
      }
    }

    this.store.loadRecords({
      records: data
    }, {}, true);
  },
  // private
  onUpdate: function onUpdate(ds, record, type) {
    if (type == Ext.data.Record.EDIT) {
      var v = record.data.value;
      var oldValue = record.modified.value;

      if (this.grid.fireEvent('beforepropertychange', this.source, record.id, v, oldValue) !== false) {
        this.source[record.id] = v;
        record.commit();
        this.grid.fireEvent('propertychange', this.source, record.id, v, oldValue);
      } else {
        record.reject();
      }
    }
  },
  // private
  getProperty: function getProperty(row) {
    return this.store.getAt(row);
  },
  // private
  isEditableValue: function isEditableValue(val) {
    return Ext.isPrimitive(val) || Ext.isDate(val);
  },
  // private
  setValue: function setValue(prop, value, create) {
    var r = this.getRec(prop);

    if (r) {
      r.set('value', value);
      this.source[prop] = value;
    } else if (create) {
      // only create if specified.
      this.source[prop] = value;
      r = new Ext.grid.PropertyRecord({
        name: prop,
        value: value
      }, prop);
      this.store.add(r);
    }
  },
  // private
  remove: function remove(prop) {
    var r = this.getRec(prop);

    if (r) {
      this.store.remove(r);
      delete this.source[prop];
    }
  },
  // private
  getRec: function getRec(prop) {
    return this.store.getById(prop);
  },
  // protected - should only be called by the grid.  Use grid.getSource instead.
  getSource: function getSource() {
    return this.source;
  }
});
/**
 * @class Ext.grid.PropertyColumnModel
 * @extends Ext.grid.ColumnModel
 * A custom column model for the {@link Ext.grid.PropertyGrid}.  Generally it should not need to be used directly.
 * @constructor
 * @param {Ext.grid.Grid} grid The grid this store will be bound to
 * @param {Object} source The source data config object
 */

Ext.grid.PropertyColumnModel = Ext.extend(Ext.grid.ColumnModel, {
  // private - strings used for locale support
  nameText: 'Name',
  valueText: 'Value',
  dateFormat: 'm/j/Y',
  trueText: 'true',
  falseText: 'false',
  constructor: function constructor(grid, store) {
    var g = Ext.grid,
        f = Ext.form;
    this.grid = grid;
    g.PropertyColumnModel.superclass.constructor.call(this, [{
      header: this.nameText,
      width: 50,
      sortable: true,
      dataIndex: 'name',
      id: 'name',
      menuDisabled: true
    }, {
      header: this.valueText,
      width: 50,
      resizable: false,
      dataIndex: 'value',
      id: 'value',
      menuDisabled: true
    }]);
    this.store = store;
    var bfield = new f.Field({
      autoCreate: {
        tag: 'select',
        children: [{
          tag: 'option',
          value: 'true',
          html: this.trueText
        }, {
          tag: 'option',
          value: 'false',
          html: this.falseText
        }]
      },
      getValue: function getValue() {
        return this.el.dom.value == 'true';
      }
    });
    this.editors = {
      'date': new g.GridEditor(new f.DateField({
        selectOnFocus: true
      })),
      'string': new g.GridEditor(new f.TextField({
        selectOnFocus: true
      })),
      'number': new g.GridEditor(new f.NumberField({
        selectOnFocus: true,
        style: 'text-align:left;'
      })),
      'boolean': new g.GridEditor(bfield, {
        autoSize: 'both'
      })
    };
    this.renderCellDelegate = this.renderCell.createDelegate(this);
    this.renderPropDelegate = this.renderProp.createDelegate(this);
  },
  // private
  renderDate: function renderDate(dateVal) {
    return dateVal.dateFormat(this.dateFormat);
  },
  // private
  renderBool: function renderBool(bVal) {
    return this[bVal ? 'trueText' : 'falseText'];
  },
  // private
  isCellEditable: function isCellEditable(colIndex, rowIndex) {
    return colIndex == 1;
  },
  // private
  getRenderer: function getRenderer(col) {
    return col == 1 ? this.renderCellDelegate : this.renderPropDelegate;
  },
  // private
  renderProp: function renderProp(v) {
    return this.getPropertyName(v);
  },
  // private
  renderCell: function renderCell(val, meta, rec) {
    var renderer = this.grid.customRenderers[rec.get('name')];

    if (renderer) {
      return renderer.apply(this, arguments);
    }

    var rv = val;

    if (Ext.isDate(val)) {
      rv = this.renderDate(val);
    } else if (typeof val == 'boolean') {
      rv = this.renderBool(val);
    }

    return Ext.util.Format.htmlEncode(rv);
  },
  // private
  getPropertyName: function getPropertyName(name) {
    var pn = this.grid.propertyNames;
    return pn && pn[name] ? pn[name] : name;
  },
  // private
  getCellEditor: function getCellEditor(colIndex, rowIndex) {
    var p = this.store.getProperty(rowIndex),
        n = p.data.name,
        val = p.data.value;

    if (this.grid.customEditors[n]) {
      return this.grid.customEditors[n];
    }

    if (Ext.isDate(val)) {
      return this.editors.date;
    } else if (typeof val == 'number') {
      return this.editors.number;
    } else if (typeof val == 'boolean') {
      return this.editors['boolean'];
    } else {
      return this.editors.string;
    }
  },
  // inherit docs
  destroy: function destroy() {
    Ext.grid.PropertyColumnModel.superclass.destroy.call(this);

    for (var ed in this.editors) {
      Ext.destroy(this.editors[ed]);
    }
  }
});
/**
 * @class Ext.grid.PropertyGrid
 * @extends Ext.grid.EditorGridPanel
 * A specialized grid implementation intended to mimic the traditional property grid as typically seen in
 * development IDEs.  Each row in the grid represents a property of some object, and the data is stored
 * as a set of name/value pairs in {@link Ext.grid.PropertyRecord}s.  Example usage:
 * <pre><code>
var grid = new Ext.grid.PropertyGrid({
    title: 'Properties Grid',
    autoHeight: true,
    width: 300,
    renderTo: 'grid-ct',
    source: {
        "(name)": "My Object",
        "Created": new Date(Date.parse('10/15/2006')),
        "Available": false,
        "Version": .01,
        "Description": "A test object"
    }
});
</code></pre>
 * @constructor
 * @param {Object} config The grid config object
 */

Ext.grid.PropertyGrid = Ext.extend(Ext.grid.EditorGridPanel, {
  /**
  * @cfg {Object} propertyNames An object containing property name/display name pairs.
  * If specified, the display name will be shown in the name column instead of the property name.
  */

  /**
  * @cfg {Object} source A data object to use as the data source of the grid (see {@link #setSource} for details).
  */

  /**
  * @cfg {Object} customEditors An object containing name/value pairs of custom editor type definitions that allow
  * the grid to support additional types of editable fields.  By default, the grid supports strongly-typed editing
  * of strings, dates, numbers and booleans using built-in form editors, but any custom type can be supported and
  * associated with a custom input control by specifying a custom editor.  The name of the editor
  * type should correspond with the name of the property that will use the editor.  Example usage:
  * <pre><code>
  var grid = new Ext.grid.PropertyGrid({
  ...
  customEditors: {
      'Start Time': new Ext.grid.GridEditor(new Ext.form.TimeField({selectOnFocus:true}))
  },
  source: {
      'Start Time': '10:00 AM'
  }
  });
  </code></pre>
  */

  /**
  * @cfg {Object} source A data object to use as the data source of the grid (see {@link #setSource} for details).
  */

  /**
  * @cfg {Object} customRenderers An object containing name/value pairs of custom renderer type definitions that allow
  * the grid to support custom rendering of fields.  By default, the grid supports strongly-typed rendering
  * of strings, dates, numbers and booleans using built-in form editors, but any custom type can be supported and
  * associated with the type of the value.  The name of the renderer type should correspond with the name of the property
  * that it will render.  Example usage:
  * <pre><code>
  var grid = new Ext.grid.PropertyGrid({
  ...
  customRenderers: {
      Available: function(v){
          if(v){
              return '<span style="color: green;">Yes</span>';
          }else{
              return '<span style="color: red;">No</span>';
          }
      }
  },
  source: {
      Available: true
  }
  });
  </code></pre>
  */
  // private config overrides
  enableColumnMove: false,
  stripeRows: false,
  trackMouseOver: false,
  clicksToEdit: 1,
  enableHdMenu: false,
  viewConfig: {
    forceFit: true
  },
  // private
  initComponent: function initComponent() {
    this.customRenderers = this.customRenderers || {};
    this.customEditors = this.customEditors || {};
    this.lastEditRow = null;
    var store = new Ext.grid.PropertyStore(this);
    this.propStore = store;
    var cm = new Ext.grid.PropertyColumnModel(this, store);
    store.store.sort('name', 'ASC');
    this.addEvents(
    /**
     * @event beforepropertychange
     * Fires before a property value changes.  Handlers can return false to cancel the property change
     * (this will internally call {@link Ext.data.Record#reject} on the property's record).
     * @param {Object} source The source data object for the grid (corresponds to the same object passed in
     * as the {@link #source} config property).
     * @param {String} recordId The record's id in the data store
     * @param {Mixed} value The current edited property value
     * @param {Mixed} oldValue The original property value prior to editing
     */
    'beforepropertychange',
    /**
     * @event propertychange
     * Fires after a property value has changed.
     * @param {Object} source The source data object for the grid (corresponds to the same object passed in
     * as the {@link #source} config property).
     * @param {String} recordId The record's id in the data store
     * @param {Mixed} value The current edited property value
     * @param {Mixed} oldValue The original property value prior to editing
     */
    'propertychange');
    this.cm = cm;
    this.ds = store.store;
    Ext.grid.PropertyGrid.superclass.initComponent.call(this);
    this.mon(this.selModel, 'beforecellselect', function (sm, rowIndex, colIndex) {
      if (colIndex === 0) {
        this.startEditing.defer(200, this, [rowIndex, 1]);
        return false;
      }
    }, this);
  },
  // private
  onRender: function onRender() {
    Ext.grid.PropertyGrid.superclass.onRender.apply(this, arguments);
    this.getGridEl().addClass('x-props-grid');
  },
  // private
  afterRender: function afterRender() {
    Ext.grid.PropertyGrid.superclass.afterRender.apply(this, arguments);

    if (this.source) {
      this.setSource(this.source);
    }
  },

  /**
   * Sets the source data object containing the property data.  The data object can contain one or more name/value
   * pairs representing all of the properties of an object to display in the grid, and this data will automatically
   * be loaded into the grid's {@link #store}.  The values should be supplied in the proper data type if needed,
   * otherwise string type will be assumed.  If the grid already contains data, this method will replace any
   * existing data.  See also the {@link #source} config value.  Example usage:
   * <pre><code>
  grid.setSource({
  "(name)": "My Object",
  "Created": new Date(Date.parse('10/15/2006')),  // date type
  "Available": false,  // boolean type
  "Version": .01,      // decimal type
  "Description": "A test object"
  });
  </code></pre>
   * @param {Object} source The data object
   */
  setSource: function setSource(source) {
    this.propStore.setSource(source);
  },

  /**
   * Gets the source data object containing the property data.  See {@link #setSource} for details regarding the
   * format of the data object.
   * @return {Object} The data object
   */
  getSource: function getSource() {
    return this.propStore.getSource();
  },

  /**
   * Sets the value of a property.
   * @param {String} prop The name of the property to set
   * @param {Mixed} value The value to test
   * @param {Boolean} create (Optional) True to create the property if it doesn't already exist. Defaults to <tt>false</tt>.
   */
  setProperty: function setProperty(prop, value, create) {
    this.propStore.setValue(prop, value, create);
  },

  /**
   * Removes a property from the grid.
   * @param {String} prop The name of the property to remove
   */
  removeProperty: function removeProperty(prop) {
    this.propStore.remove(prop);
  }
  /**
   * @cfg store
   * @hide
   */

  /**
   * @cfg colModel
   * @hide
   */

  /**
   * @cfg cm
   * @hide
   */

  /**
   * @cfg columns
   * @hide
   */

});
Ext.reg("propertygrid", Ext.grid.PropertyGrid);

/***/ }),
/* 905 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.grid.GroupingView
 * @extends Ext.grid.GridView
 * Adds the ability for single level grouping to the grid. A {@link Ext.data.GroupingStore GroupingStore}
 * must be used to enable grouping.  Some grouping characteristics may also be configured at the
 * {@link Ext.grid.Column Column level}<div class="mdetail-params"><ul>
 * <li><code>{@link Ext.grid.Column#emptyGroupText emptyGroupText}</li>
 * <li><code>{@link Ext.grid.Column#groupable groupable}</li>
 * <li><code>{@link Ext.grid.Column#groupName groupName}</li>
 * <li><code>{@link Ext.grid.Column#groupRender groupRender}</li>
 * </ul></div>
 * <p>Sample usage:</p>
 * <pre><code>
var grid = new Ext.grid.GridPanel({
    // A groupingStore is required for a GroupingView
    store: new {@link Ext.data.GroupingStore}({
        autoDestroy: true,
        reader: reader,
        data: xg.dummyData,
        sortInfo: {field: 'company', direction: 'ASC'},
        {@link Ext.data.GroupingStore#groupOnSort groupOnSort}: true,
        {@link Ext.data.GroupingStore#remoteGroup remoteGroup}: true,
        {@link Ext.data.GroupingStore#groupField groupField}: 'industry'
    }),
    colModel: new {@link Ext.grid.ColumnModel}({
        columns:[
            {id:'company',header: 'Company', width: 60, dataIndex: 'company'},
            // {@link Ext.grid.Column#groupable groupable}, {@link Ext.grid.Column#groupName groupName}, {@link Ext.grid.Column#groupRender groupRender} are also configurable at column level
            {header: 'Price', renderer: Ext.util.Format.usMoney, dataIndex: 'price', {@link Ext.grid.Column#groupable groupable}: false},
            {header: 'Change', dataIndex: 'change', renderer: Ext.util.Format.usMoney},
            {header: 'Industry', dataIndex: 'industry'},
            {header: 'Last Updated', renderer: Ext.util.Format.dateRenderer('m/d/Y'), dataIndex: 'lastChange'}
        ],
        defaults: {
            sortable: true,
            menuDisabled: false,
            width: 20
        }
    }),

    view: new Ext.grid.GroupingView({
        {@link Ext.grid.GridView#forceFit forceFit}: true,
        // custom grouping text template to display the number of items per group
        {@link #groupTextTpl}: '{text} ({[values.rs.length]} {[values.rs.length > 1 ? "Items" : "Item"]})'
    }),

    frame:true,
    width: 700,
    height: 450,
    collapsible: true,
    animCollapse: false,
    title: 'Grouping Example',
    iconCls: 'icon-grid',
    renderTo: document.body
});
 * </code></pre>
 * @constructor
 * @param {Object} config
 */
Ext.grid.GroupingView = Ext.extend(Ext.grid.GridView, {
  /**
   * @cfg {String} groupByText Text displayed in the grid header menu for grouping by a column
   * (defaults to 'Group By This Field').
   */
  groupByText: 'Group By This Field',

  /**
   * @cfg {String} showGroupsText Text displayed in the grid header for enabling/disabling grouping
   * (defaults to 'Show in Groups').
   */
  showGroupsText: 'Show in Groups',

  /**
   * @cfg {Boolean} hideGroupedColumn <tt>true</tt> to hide the column that is currently grouped (defaults to <tt>false</tt>)
   */
  hideGroupedColumn: false,

  /**
   * @cfg {Boolean} showGroupName If <tt>true</tt> will display a prefix plus a ': ' before the group field value
   * in the group header line.  The prefix will consist of the <tt><b>{@link Ext.grid.Column#groupName groupName}</b></tt>
   * (or the configured <tt><b>{@link Ext.grid.Column#header header}</b></tt> if not provided) configured in the
   * {@link Ext.grid.Column} for each set of grouped rows (defaults to <tt>true</tt>).
   */
  showGroupName: true,

  /**
   * @cfg {Boolean} startCollapsed <tt>true</tt> to start all groups collapsed (defaults to <tt>false</tt>)
   */
  startCollapsed: false,

  /**
   * @cfg {Boolean} enableGrouping <tt>false</tt> to disable grouping functionality (defaults to <tt>true</tt>)
   */
  enableGrouping: true,

  /**
   * @cfg {Boolean} enableGroupingMenu <tt>true</tt> to enable the grouping control in the column menu (defaults to <tt>true</tt>)
   */
  enableGroupingMenu: true,

  /**
   * @cfg {Boolean} enableNoGroups <tt>true</tt> to allow the user to turn off grouping (defaults to <tt>true</tt>)
   */
  enableNoGroups: true,

  /**
   * @cfg {String} emptyGroupText The text to display when there is an empty group value (defaults to <tt>'(None)'</tt>).
   * May also be specified per column, see {@link Ext.grid.Column}.{@link Ext.grid.Column#emptyGroupText emptyGroupText}.
   */
  emptyGroupText: '(None)',

  /**
   * @cfg {Boolean} ignoreAdd <tt>true</tt> to skip refreshing the view when new rows are added (defaults to <tt>false</tt>)
   */
  ignoreAdd: false,

  /**
   * @cfg {String} groupTextTpl The template used to render the group header (defaults to <tt>'{text}'</tt>).
   * This is used to format an object which contains the following properties:
   * <div class="mdetail-params"><ul>
   * <li><b>group</b> : String<p class="sub-desc">The <i>rendered</i> value of the group field.
   * By default this is the unchanged value of the group field. If a <tt><b>{@link Ext.grid.Column#groupRenderer groupRenderer}</b></tt>
   * is specified, it is the result of a call to that function.</p></li>
   * <li><b>gvalue</b> : Object<p class="sub-desc">The <i>raw</i> value of the group field.</p></li>
   * <li><b>text</b> : String<p class="sub-desc">The configured header (as described in <tt>{@link #showGroupName})</tt>
   * if <tt>{@link #showGroupName}</tt> is <tt>true</tt>) plus the <i>rendered</i> group field value.</p></li>
   * <li><b>groupId</b> : String<p class="sub-desc">A unique, generated ID which is applied to the
   * View Element which contains the group.</p></li>
   * <li><b>startRow</b> : Number<p class="sub-desc">The row index of the Record which caused group change.</p></li>
   * <li><b>rs</b> : Array<p class="sub-desc">Contains a single element: The Record providing the data
   * for the row which caused group change.</p></li>
   * <li><b>cls</b> : String<p class="sub-desc">The generated class name string to apply to the group header Element.</p></li>
   * <li><b>style</b> : String<p class="sub-desc">The inline style rules to apply to the group header Element.</p></li>
   * </ul></div></p>
   * See {@link Ext.XTemplate} for information on how to format data using a template. Possible usage:<pre><code>
  var grid = new Ext.grid.GridPanel({
  ...
  view: new Ext.grid.GroupingView({
      groupTextTpl: '{text} ({[values.rs.length]} {[values.rs.length > 1 ? "Items" : "Item"]})'
  }),
  });
   * </code></pre>
   */
  groupTextTpl: '{text}',

  /**
   * @cfg {String} groupMode Indicates how to construct the group identifier. <tt>'value'</tt> constructs the id using
   * raw value, <tt>'display'</tt> constructs the id using the rendered value. Defaults to <tt>'value'</tt>.
   */
  groupMode: 'value',

  /**
   * @cfg {Function} groupRenderer This property must be configured in the {@link Ext.grid.Column} for
   * each column.
   */
  // private
  gidSeed: 1000,
  // private
  initTemplates: function initTemplates() {
    Ext.grid.GroupingView.superclass.initTemplates.call(this);
    this.state = {};
    var sm = this.grid.getSelectionModel();
    sm.on(sm.selectRow ? 'beforerowselect' : 'beforecellselect', this.onBeforeRowSelect, this);

    if (!this.startGroup) {
      this.startGroup = new Ext.XTemplate('<div id="{groupId}" class="x-grid-group {cls}">', '<div id="{groupId}-hd" class="x-grid-group-hd" style="{style}"><div class="x-grid-group-title">', this.groupTextTpl, '</div></div>', '<div id="{groupId}-bd" class="x-grid-group-body">');
    }

    this.startGroup.compile();

    if (!this.endGroup) {
      this.endGroup = '</div></div>';
    }

    this.endGroup = '</div></div>';
  },
  // private
  findGroup: function findGroup(el) {
    return Ext.fly(el).up('.x-grid-group', this.mainBody.dom);
  },
  // private
  getGroups: function getGroups() {
    return this.hasRows() ? this.mainBody.dom.childNodes : [];
  },
  // private
  onAdd: function onAdd() {
    if (this.canGroup() && !this.ignoreAdd) {
      var ss = this.getScrollState();
      this.refresh();
      this.restoreScroll(ss);
    } else if (!this.canGroup()) {
      Ext.grid.GroupingView.superclass.onAdd.apply(this, arguments);
    }
  },
  // private
  onRemove: function onRemove(ds, record, index, isUpdate) {
    Ext.grid.GroupingView.superclass.onRemove.apply(this, arguments);
    var g = document.getElementById(record._groupId);

    if (g && g.childNodes[1].childNodes.length < 1) {
      Ext.removeNode(g);
    }

    this.applyEmptyText();
  },
  // private
  refreshRow: function refreshRow(record) {
    if (this.ds.getCount() == 1) {
      this.refresh();
    } else {
      this.isUpdating = true;
      Ext.grid.GroupingView.superclass.refreshRow.apply(this, arguments);
      this.isUpdating = false;
    }
  },
  // private
  beforeMenuShow: function beforeMenuShow() {
    var item,
        items = this.hmenu.items,
        disabled = this.cm.config[this.hdCtxIndex].groupable === false;

    if (item = items.get('groupBy')) {
      item.setDisabled(disabled);
    }

    if (item = items.get('showGroups')) {
      item.setDisabled(disabled);
      item.setChecked(this.enableGrouping, true);
    }
  },
  // private
  renderUI: function renderUI() {
    Ext.grid.GroupingView.superclass.renderUI.call(this);
    this.mainBody.on('mousedown', this.interceptMouse, this);

    if (this.enableGroupingMenu && this.hmenu) {
      this.hmenu.add('-', {
        itemId: 'groupBy',
        text: this.groupByText,
        handler: this.onGroupByClick,
        scope: this,
        iconCls: 'x-group-by-icon'
      });

      if (this.enableNoGroups) {
        this.hmenu.add({
          itemId: 'showGroups',
          text: this.showGroupsText,
          checked: true,
          checkHandler: this.onShowGroupsClick,
          scope: this
        });
      }

      this.hmenu.on('beforeshow', this.beforeMenuShow, this);
    }
  },
  processEvent: function processEvent(name, e) {
    var hd = e.getTarget('.x-grid-group-hd', this.mainBody);

    if (hd) {
      // group value is at the end of the string
      var field = this.getGroupField(),
          prefix = this.getPrefix(field),
          groupValue = hd.id.substring(prefix.length); // remove trailing '-hd'

      groupValue = groupValue.substr(0, groupValue.length - 3);

      if (groupValue) {
        this.grid.fireEvent('group' + name, this.grid, field, groupValue, e);
      }
    }
  },
  // private
  onGroupByClick: function onGroupByClick() {
    this.enableGrouping = true;
    this.grid.store.groupBy(this.cm.getDataIndex(this.hdCtxIndex));
    this.grid.fireEvent('groupchange', this, this.grid.store.getGroupState());
    this.beforeMenuShow(); // Make sure the checkboxes get properly set when changing groups

    this.refresh();
  },
  // private
  onShowGroupsClick: function onShowGroupsClick(mi, checked) {
    this.enableGrouping = checked;

    if (checked) {
      this.onGroupByClick();
    } else {
      this.grid.store.clearGrouping();
      this.grid.fireEvent('groupchange', this, null);
    }
  },

  /**
   * Toggle the group that contains the specific row.
   * @param {Number} rowIndex The row inside the group
   * @param {Boolean} expanded (optional)
   */
  toggleRowIndex: function toggleRowIndex(rowIndex, expanded) {
    if (!this.canGroup()) {
      return;
    }

    var row = this.getRow(rowIndex);

    if (row) {
      this.toggleGroup(this.findGroup(row), expanded);
    }
  },

  /**
   * Toggles the specified group if no value is passed, otherwise sets the expanded state of the group to the value passed.
   * @param {String} groupId The groupId assigned to the group (see getGroupId)
   * @param {Boolean} expanded (optional)
   */
  toggleGroup: function toggleGroup(group, expanded) {
    var gel = Ext.get(group);
    expanded = Ext.isDefined(expanded) ? expanded : gel.hasClass('x-grid-group-collapsed');

    if (this.state[gel.id] !== expanded) {
      this.grid.stopEditing(true);
      this.state[gel.id] = expanded;
      gel[expanded ? 'removeClass' : 'addClass']('x-grid-group-collapsed');
    }
  },

  /**
   * Toggles all groups if no value is passed, otherwise sets the expanded state of all groups to the value passed.
   * @param {Boolean} expanded (optional)
   */
  toggleAllGroups: function toggleAllGroups(expanded) {
    var groups = this.getGroups();

    for (var i = 0, len = groups.length; i < len; i++) {
      this.toggleGroup(groups[i], expanded);
    }
  },

  /**
   * Expands all grouped rows.
   */
  expandAllGroups: function expandAllGroups() {
    this.toggleAllGroups(true);
  },

  /**
   * Collapses all grouped rows.
   */
  collapseAllGroups: function collapseAllGroups() {
    this.toggleAllGroups(false);
  },
  // private
  interceptMouse: function interceptMouse(e) {
    var hd = e.getTarget('.x-grid-group-hd', this.mainBody);

    if (hd) {
      e.stopEvent();
      this.toggleGroup(hd.parentNode);
    }
  },
  // private
  getGroup: function getGroup(v, r, groupRenderer, rowIndex, colIndex, ds) {
    var g = groupRenderer ? groupRenderer(v, {}, r, rowIndex, colIndex, ds) : String(v);

    if (g === '' || g === '&#160;') {
      g = this.cm.config[colIndex].emptyGroupText || this.emptyGroupText;
    }

    return g;
  },
  // private
  getGroupField: function getGroupField() {
    return this.grid.store.getGroupState();
  },
  // private
  afterRender: function afterRender() {
    if (!this.ds || !this.cm) {
      return;
    }

    Ext.grid.GroupingView.superclass.afterRender.call(this);

    if (this.grid.deferRowRender) {
      this.updateGroupWidths();
    }
  },
  // private
  renderRows: function renderRows() {
    var groupField = this.getGroupField();
    var eg = !!groupField; // if they turned off grouping and the last grouped field is hidden

    if (this.hideGroupedColumn) {
      var colIndex = this.cm.findColumnIndex(groupField),
          hasLastGroupField = Ext.isDefined(this.lastGroupField);

      if (!eg && hasLastGroupField) {
        this.mainBody.update('');
        this.cm.setHidden(this.cm.findColumnIndex(this.lastGroupField), false);
        delete this.lastGroupField;
      } else if (eg && !hasLastGroupField) {
        this.lastGroupField = groupField;
        this.cm.setHidden(colIndex, true);
      } else if (eg && hasLastGroupField && groupField !== this.lastGroupField) {
        this.mainBody.update('');
        var oldIndex = this.cm.findColumnIndex(this.lastGroupField);
        this.cm.setHidden(oldIndex, false);
        this.lastGroupField = groupField;
        this.cm.setHidden(colIndex, true);
      }
    }

    return Ext.grid.GroupingView.superclass.renderRows.apply(this, arguments);
  },
  // private
  doRender: function doRender(cs, rs, ds, startRow, colCount, stripe) {
    if (rs.length < 1) {
      return '';
    }

    if (!this.canGroup() || this.isUpdating) {
      return Ext.grid.GroupingView.superclass.doRender.apply(this, arguments);
    }

    var groupField = this.getGroupField(),
        colIndex = this.cm.findColumnIndex(groupField),
        g,
        gstyle = 'width:' + this.getTotalWidth() + ';',
        cfg = this.cm.config[colIndex],
        groupRenderer = cfg.groupRenderer || cfg.renderer,
        prefix = this.showGroupName ? (cfg.groupName || cfg.header) + ': ' : '',
        groups = [],
        curGroup,
        i,
        len,
        gid;

    for (i = 0, len = rs.length; i < len; i++) {
      var rowIndex = startRow + i,
          r = rs[i],
          gvalue = r.data[groupField];
      g = this.getGroup(gvalue, r, groupRenderer, rowIndex, colIndex, ds);

      if (!curGroup || curGroup.group != g) {
        gid = this.constructId(gvalue, groupField, colIndex); // if state is defined use it, however state is in terms of expanded
        // so negate it, otherwise use the default.

        this.state[gid] = !(Ext.isDefined(this.state[gid]) ? !this.state[gid] : this.startCollapsed);
        curGroup = {
          group: g,
          gvalue: gvalue,
          text: prefix + g,
          groupId: gid,
          startRow: rowIndex,
          rs: [r],
          cls: this.state[gid] ? '' : 'x-grid-group-collapsed',
          style: gstyle
        };
        groups.push(curGroup);
      } else {
        curGroup.rs.push(r);
      }

      r._groupId = gid;
    }

    var buf = [];

    for (i = 0, len = groups.length; i < len; i++) {
      g = groups[i];
      this.doGroupStart(buf, g, cs, ds, colCount);
      buf[buf.length] = Ext.grid.GroupingView.superclass.doRender.call(this, cs, g.rs, ds, g.startRow, colCount, stripe);
      this.doGroupEnd(buf, g, cs, ds, colCount);
    }

    return buf.join('');
  },

  /**
   * Dynamically tries to determine the groupId of a specific value
   * @param {String} value
   * @return {String} The group id
   */
  getGroupId: function getGroupId(value) {
    var field = this.getGroupField();
    return this.constructId(value, field, this.cm.findColumnIndex(field));
  },
  // private
  constructId: function constructId(value, field, idx) {
    var cfg = this.cm.config[idx],
        groupRenderer = cfg.groupRenderer || cfg.renderer,
        val = this.groupMode == 'value' ? value : this.getGroup(value, {
      data: {}
    }, groupRenderer, 0, idx, this.ds);
    return this.getPrefix(field) + Ext.util.Format.htmlEncode(val);
  },
  // private
  canGroup: function canGroup() {
    return this.enableGrouping && !!this.getGroupField();
  },
  // private
  getPrefix: function getPrefix(field) {
    return this.grid.getGridEl().id + '-gp-' + field + '-';
  },
  // private
  doGroupStart: function doGroupStart(buf, g, cs, ds, colCount) {
    buf[buf.length] = this.startGroup.apply(g);
  },
  // private
  doGroupEnd: function doGroupEnd(buf, g, cs, ds, colCount) {
    buf[buf.length] = this.endGroup;
  },
  // private
  getRows: function getRows() {
    if (!this.canGroup()) {
      return Ext.grid.GroupingView.superclass.getRows.call(this);
    }

    var r = [];
    var g,
        gs = this.getGroups();

    for (var i = 0, len = gs.length; i < len; i++) {
      g = gs[i].childNodes[1].childNodes;

      for (var j = 0, jlen = g.length; j < jlen; j++) {
        r[r.length] = g[j];
      }
    }

    return r;
  },
  // private
  updateGroupWidths: function updateGroupWidths() {
    if (!this.canGroup() || !this.hasRows()) {
      return;
    }

    var tw = Math.max(this.cm.getTotalWidth(), this.el.dom.offsetWidth - this.getScrollOffset()) + 'px';
    var gs = this.getGroups();

    for (var i = 0, len = gs.length; i < len; i++) {
      gs[i].firstChild.style.width = tw;
    }
  },
  // private
  onColumnWidthUpdated: function onColumnWidthUpdated(col, w, tw) {
    Ext.grid.GroupingView.superclass.onColumnWidthUpdated.call(this, col, w, tw);
    this.updateGroupWidths();
  },
  // private
  onAllColumnWidthsUpdated: function onAllColumnWidthsUpdated(ws, tw) {
    Ext.grid.GroupingView.superclass.onAllColumnWidthsUpdated.call(this, ws, tw);
    this.updateGroupWidths();
  },
  // private
  onColumnHiddenUpdated: function onColumnHiddenUpdated(col, hidden, tw) {
    Ext.grid.GroupingView.superclass.onColumnHiddenUpdated.call(this, col, hidden, tw);
    this.updateGroupWidths();
  },
  // private
  onLayout: function onLayout() {
    this.updateGroupWidths();
  },
  // private
  onBeforeRowSelect: function onBeforeRowSelect(sm, rowIndex) {
    this.toggleRowIndex(rowIndex, true);
  }
}); // private

Ext.grid.GroupingView.GROUP_ID = 1000;

/***/ }),
/* 906 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(907);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 907 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\nhtml,body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,p,blockquote,th,td{margin:0;padding:0;}img,body,html{border:0;}address,caption,cite,code,dfn,em,strong,th,var{font-style:normal;font-weight:normal;}ol,ul {list-style:none;}caption,th {text-align:left;}h1,h2,h3,h4,h5,h6{font-size:100%;}q:before,q:after{content:'';}", ""]);

// exports


/***/ }),
/* 908 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(909);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 909 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.ext-el-mask {\r\n    z-index: 100;\r\n    position: absolute;\r\n    top:0;\r\n    left:0;\r\n    -moz-opacity: 0.5;\r\n    opacity: .50;\r\n    filter: alpha(opacity=50);\r\n    width: 100%;\r\n    height: 100%;\r\n    zoom: 1;\r\n}\r\n\r\n.ext-el-mask-msg {\r\n    z-index: 20001;\r\n    position: absolute;\r\n    top: 0;\r\n    left: 0;\r\n    border:1px solid;\r\n    background:repeat-x 0 -16px;\r\n    padding:2px;\r\n}\r\n\r\n.ext-el-mask-msg div {\r\n    padding:5px 10px 5px 10px;\r\n    border:1px solid;\r\n    cursor:wait;\r\n}\r\n\r\n.ext-shim {\r\n    position:absolute;\r\n    visibility:hidden;\r\n    left:0;\r\n    top:0;\r\n    overflow:hidden;\r\n}\r\n\r\n.ext-ie .ext-shim {\r\n    filter: alpha(opacity=0);\r\n}\r\n\r\n.ext-ie6 .ext-shim {\r\n    margin-left: 5px;\r\n    margin-top: 3px;\r\n}\r\n\r\n.x-mask-loading div {\r\n    padding:5px 10px 5px 25px;\r\n    background:no-repeat 5px 5px;\r\n    line-height:16px;\r\n}\r\n\r\n/* class for hiding elements without using display:none */\r\n.x-hidden, .x-hide-offsets {\r\n    position:absolute !important;\r\n    left:-10000px;\r\n    top:-10000px;\r\n    visibility:hidden;\r\n}\r\n\r\n.x-hide-display {\r\n    display:none !important;\r\n}\r\n\r\n.x-hide-visibility {\r\n    visibility:hidden !important;\r\n}\r\n\r\n.x-masked {\r\n    overflow: hidden !important;\r\n}\r\n.x-masked-relative {\r\n    position: relative !important;\r\n}\r\n\r\n.x-masked select, .x-masked object, .x-masked embed {\r\n    visibility: hidden;\r\n}\r\n\r\n.x-layer {\r\n    visibility: hidden;\r\n}\r\n\r\n.x-unselectable, .x-unselectable * {\r\n    -moz-user-select: none;\r\n    -khtml-user-select: none;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n.x-repaint {\r\n    zoom: 1;\r\n    background-color: transparent;\r\n    -moz-outline: none;\r\n    outline: none;\r\n}\r\n\r\n.x-item-disabled {\r\n    cursor: default;\r\n    opacity: .6;\r\n    -moz-opacity: .6;\r\n    filter: alpha(opacity=60);\r\n}\r\n\r\n.x-item-disabled * {\r\n    cursor: default !important;\r\n}\r\n\r\n.x-splitbar-proxy {\r\n    position: absolute;\r\n    visibility: hidden;\r\n    z-index: 20001;\r\n    zoom: 1;\r\n    line-height: 1px;\r\n    font-size: 1px;\r\n    overflow: hidden;\r\n}\r\n\r\n.x-splitbar-h, .x-splitbar-proxy-h {\r\n    cursor: e-resize;\r\n    cursor: col-resize;\r\n}\r\n\r\n.x-splitbar-v, .x-splitbar-proxy-v {\r\n    cursor: s-resize;\r\n    cursor: row-resize;\r\n}\r\n\r\n.x-color-palette {\r\n    width: 150px;\r\n    height: 92px;\r\n    cursor: pointer;\r\n}\r\n\r\n.x-color-palette a {\r\n    border: 1px solid;\r\n    float: left;\r\n    padding: 2px;\r\n    text-decoration: none;\r\n    -moz-outline: 0 none;\r\n    outline: 0 none;\r\n    cursor: pointer;\r\n}\r\n\r\n.x-color-palette a:hover, .x-color-palette a.x-color-palette-sel {\r\n    border: 1px solid;\r\n}\r\n\r\n.x-color-palette em {\r\n    display: block;\r\n    border: 1px solid;\r\n}\r\n\r\n.x-color-palette em span {\r\n    cursor: pointer;\r\n    display: block;\r\n    height: 10px;\r\n    line-height: 10px;\r\n    width: 10px;\r\n}\r\n\r\n.x-ie-shadow {\r\n    display: none;\r\n    position: absolute;\r\n    overflow: hidden;\r\n    left:0;\r\n    top:0;\r\n    zoom:1;\r\n}\r\n\r\n.x-shadow {\r\n    display: none;\r\n    position: absolute;\r\n    overflow: hidden;\r\n    left:0;\r\n    top:0;\r\n}\r\n\r\n.x-shadow * {\r\n    overflow: hidden;\r\n}\r\n\r\n.x-shadow * {\r\n    padding: 0;\r\n    border: 0;\r\n    margin: 0;\r\n    clear: none;\r\n    zoom: 1;\r\n}\r\n\r\n/* top  bottom */\r\n.x-shadow .xstc, .x-shadow .xsbc {\r\n    height: 6px;\r\n    float: left;\r\n}\r\n\r\n/* corners */\r\n.x-shadow .xstl, .x-shadow .xstr, .x-shadow .xsbl, .x-shadow .xsbr {\r\n    width: 6px;\r\n    height: 6px;\r\n    float: left;\r\n}\r\n\r\n/* sides */\r\n.x-shadow .xsc {\r\n    width: 100%;\r\n}\r\n\r\n.x-shadow .xsml, .x-shadow .xsmr {\r\n    width: 6px;\r\n    float: left;\r\n    height: 100%;\r\n}\r\n\r\n.x-shadow .xsmc {\r\n    float: left;\r\n    height: 100%;\r\n    background: transparent;\r\n}\r\n\r\n.x-shadow .xst, .x-shadow .xsb {\r\n    height: 6px;\r\n    overflow: hidden;\r\n    width: 100%;\r\n}\r\n\r\n.x-shadow .xsml {\r\n    background: transparent repeat-y 0 0;\r\n}\r\n\r\n.x-shadow .xsmr {\r\n    background: transparent repeat-y -6px 0;\r\n}\r\n\r\n.x-shadow .xstl {\r\n    background: transparent no-repeat 0 0;\r\n}\r\n\r\n.x-shadow .xstc {\r\n    background: transparent repeat-x 0 -30px;\r\n}\r\n\r\n.x-shadow .xstr {\r\n    background: transparent repeat-x 0 -18px;\r\n}\r\n\r\n.x-shadow .xsbl {\r\n    background: transparent no-repeat 0 -12px;\r\n}\r\n\r\n.x-shadow .xsbc {\r\n    background: transparent repeat-x 0 -36px;\r\n}\r\n\r\n.x-shadow .xsbr {\r\n    background: transparent repeat-x 0 -6px;\r\n}\r\n\r\n.loading-indicator {\r\n    background: no-repeat left;\r\n    padding-left: 20px;\r\n    line-height: 16px;\r\n    margin: 3px;\r\n}\r\n\r\n.x-text-resize {\r\n    position: absolute;\r\n    left: -1000px;\r\n    top: -1000px;\r\n    visibility: hidden;\r\n    zoom: 1;\r\n}\r\n\r\n.x-drag-overlay {\r\n    width: 100%;\r\n    height: 100%;\r\n    display: none;\r\n    position: absolute;\r\n    left: 0;\r\n    top: 0;\r\n    background-image:url(" + escape(__webpack_require__(231)) + ");\r\n    z-index: 20000;\r\n}\r\n\r\n.x-clear {\r\n    clear:both;\r\n    height:0;\r\n    overflow:hidden;\r\n    line-height:0;\r\n    font-size:0;\r\n}\r\n\r\n.x-spotlight {\r\n    z-index: 8999;\r\n    position: absolute;\r\n    top:0;\r\n    left:0;\r\n    -moz-opacity: 0.5;\r\n    opacity: .50;\r\n    filter: alpha(opacity=50);\r\n    width:0;\r\n    height:0;\r\n    zoom: 1;\r\n}\r\n\r\n#x-history-frame {\r\n    position:absolute;\r\n    top:-1px;\r\n    left:0;\r\n\twidth:1px;\r\n    height:1px;\r\n    visibility:hidden;\r\n}\r\n\r\n#x-history-field {\r\n    position:absolute;\r\n    top:0;\r\n    left:-1px;\r\n\twidth:1px;\r\n    height:1px;\r\n    visibility:hidden;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 910 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(911);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 911 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-resizable-handle {\r\n    position:absolute;\r\n    z-index:100;\r\n    /* ie needs these */\r\n    font-size:1px;\r\n    line-height:6px;\r\n    overflow:hidden;\r\n\tfilter:alpha(opacity=0);\r\n\topacity:0;\r\n\tzoom:1;\r\n}\r\n\r\n.x-resizable-handle-east{\r\n    width:6px;\r\n    cursor:e-resize;\r\n    right:0;\r\n    top:0;\r\n    height:100%;\r\n}\r\n\r\n.ext-ie .x-resizable-handle-east {\r\n    margin-right:-1px; /*IE rounding error*/\r\n}\r\n\r\n.x-resizable-handle-south{\r\n    width:100%;\r\n    cursor:s-resize;\r\n    left:0;\r\n    bottom:0;\r\n    height:6px;\r\n}\r\n\r\n.ext-ie .x-resizable-handle-south {\r\n    margin-bottom:-1px; /*IE rounding error*/\r\n}\r\n\r\n.x-resizable-handle-west{\r\n    width:6px;\r\n    cursor:w-resize;\r\n    left:0;\r\n    top:0;\r\n    height:100%;\r\n}\r\n\r\n.x-resizable-handle-north{\r\n    width:100%;\r\n    cursor:n-resize;\r\n    left:0;\r\n    top:0;\r\n    height:6px;\r\n}\r\n\r\n.x-resizable-handle-southeast{\r\n    width:6px;\r\n    cursor:se-resize;\r\n    right:0;\r\n    bottom:0;\r\n    height:6px;\r\n    z-index:101;\r\n}\r\n\r\n.x-resizable-handle-northwest{\r\n    width:6px;\r\n    cursor:nw-resize;\r\n    left:0;\r\n    top:0;\r\n    height:6px;\r\n    z-index:101;\r\n}\r\n\r\n.x-resizable-handle-northeast{\r\n    width:6px;\r\n    cursor:ne-resize;\r\n    right:0;\r\n    top:0;\r\n    height:6px;\r\n    z-index:101;\r\n}\r\n\r\n.x-resizable-handle-southwest{\r\n    width:6px;\r\n    cursor:sw-resize;\r\n    left:0;\r\n    bottom:0;\r\n    height:6px;\r\n    z-index:101;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle, .x-resizable-pinned .x-resizable-handle{\r\n    filter:alpha(opacity=100);\r\n\topacity:1;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-east, .x-resizable-pinned .x-resizable-handle-east,\r\n.x-resizable-over .x-resizable-handle-west, .x-resizable-pinned .x-resizable-handle-west\r\n{\r\n\tbackground-position: left;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-south, .x-resizable-pinned .x-resizable-handle-south,\r\n.x-resizable-over .x-resizable-handle-north, .x-resizable-pinned .x-resizable-handle-north\r\n{\r\n    background-position: top;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-southeast, .x-resizable-pinned .x-resizable-handle-southeast{\r\n    background-position: top left;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-northwest, .x-resizable-pinned .x-resizable-handle-northwest{\r\n    background-position:bottom right;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-northeast, .x-resizable-pinned .x-resizable-handle-northeast{\r\n    background-position: bottom left;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-southwest, .x-resizable-pinned .x-resizable-handle-southwest{\r\n    background-position: top right;\r\n}\r\n\r\n.x-resizable-proxy{\r\n    border: 1px dashed;\r\n    position:absolute;\r\n    overflow:hidden;\r\n    display:none;\r\n\tleft:0;\r\n    top:0;\r\n    z-index:50000;\r\n}\r\n\r\n.x-resizable-overlay{\r\n    width:100%;\r\n\theight:100%;\r\n\tdisplay:none;\r\n\tposition:absolute;\r\n\tleft:0;\r\n\ttop:0;\r\n\tz-index:200000;\r\n\t-moz-opacity: 0;\r\n    opacity:0;\r\n    filter: alpha(opacity=0);\r\n}\r\n", ""]);

// exports


/***/ }),
/* 912 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(913);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 913 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-tab-panel {\n    overflow:hidden;\n}\n\n.x-tab-panel-header, .x-tab-panel-footer {\n\tborder: 1px solid;\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-tab-panel-header {\n\tborder: 1px solid;\n\tpadding-bottom: 2px;\n}\n\n.x-tab-panel-footer {\n\tborder: 1px solid;\n\tpadding-top: 2px;\n}\n\n.x-tab-strip-wrap {\n\twidth:100%;\n    overflow:hidden;\n    position:relative;\n    zoom:1;\n}\n\nul.x-tab-strip {\n\tdisplay:block;\n    width:5000px;\n    zoom:1;\n}\n\nul.x-tab-strip-top{\n\tpadding-top: 1px;\n\tbackground: repeat-x bottom;\n\tborder-bottom: 1px solid;\n}\n\nul.x-tab-strip-bottom{\n\tpadding-bottom: 1px;\n\tbackground: repeat-x top;\n\tborder-top: 1px solid;\n\tborder-bottom: 0 none;\n}\n\n.x-tab-panel-header-plain .x-tab-strip-top {\n    background:transparent !important;\n    padding-top:0 !important;\n}\n\n.x-tab-panel-header-plain {\n    background:transparent !important;\n    border-width:0 !important;\n    padding-bottom:0 !important;\n}\n\n.x-tab-panel-header-plain .x-tab-strip-spacer,\n.x-tab-panel-footer-plain .x-tab-strip-spacer {\n    border:1px solid;\n    height:2px;\n    font-size:1px;\n    line-height:1px;\n}\n\n.x-tab-panel-header-plain .x-tab-strip-spacer {\n    border-top: 0 none;\n}\n\n.x-tab-panel-footer-plain .x-tab-strip-spacer {\n    border-bottom: 0 none;\n}\n\n.x-tab-panel-footer-plain .x-tab-strip-bottom {\n    background:transparent !important;\n    padding-bottom:0 !important;\n}\n\n.x-tab-panel-footer-plain {\n    background:transparent !important;\n    border-width:0 !important;\n    padding-top:0 !important;\n}\n\n.ext-border-box .x-tab-panel-header-plain .x-tab-strip-spacer,\n.ext-border-box .x-tab-panel-footer-plain .x-tab-strip-spacer {\n    height:3px;\n}\n\nul.x-tab-strip li {\n    float:left;\n    margin-left:2px;\n}\n\nul.x-tab-strip li.x-tab-edge {\n    float:left;\n    margin:0 !important;\n    padding:0 !important;\n    border:0 none !important;\n    font-size:1px !important;\n    line-height:1px !important;\n    overflow:hidden;\n    zoom:1;\n    background:transparent !important;\n    width:1px;\n}\n\n.x-tab-strip a, .x-tab-strip span, .x-tab-strip em {\n\tdisplay:block;\n}\n\n.x-tab-strip a {\n\ttext-decoration:none !important;\n\t-moz-outline: none;\n\toutline: none;\n\tcursor:pointer;\n}\n\n.x-tab-strip-inner {\n    overflow:hidden;\n\ttext-overflow: ellipsis;\n}\n\n.x-tab-strip span.x-tab-strip-text {\n\twhite-space: nowrap;\n\tcursor:pointer;\n    padding:4px 0;\n}\n\n.x-tab-strip-top .x-tab-with-icon .x-tab-right {\n    padding-left:6px;\n}\n\n.x-tab-strip .x-tab-with-icon span.x-tab-strip-text {\n\tpadding-left:20px;\n    background-position: 0 3px;\n    background-repeat: no-repeat;\n}\n\n.x-tab-strip-active, .x-tab-strip-active a.x-tab-right {\n    cursor:default;\n}\n\n.x-tab-strip-active span.x-tab-strip-text {\n\tcursor:default;\n}\n\n.x-tab-strip-disabled .x-tabs-text {\n\tcursor:default;\n}\n\n.x-tab-panel-body {\n    overflow:hidden;\n}\n\n.x-tab-panel-bwrap {\n    overflow:hidden;\n}\n\n.ext-ie .x-tab-strip .x-tab-right {\n    position:relative;\n}\n\n.x-tab-strip-top .x-tab-strip-active .x-tab-right {\n    margin-bottom:-1px;\n}\n\n/*\n * Horrible hack for IE8 in quirks mode\n */\n.ext-ie8 ul.x-tab-strip li {\n    position: relative;\n}\n.ext-ie8 .x-tab-strip .x-tab-right{\n    margin-bottom: 0 !important;\n    top: 1px;\n}\n.ext-ie8 ul.x-tab-strip-top {\n    padding-top: 0;\n}\n.ext-ie8 .x-tab-strip .x-tab-strip-closable a.x-tab-strip-close {\n    top:4px;\n}\n\n\n.x-tab-strip-top .x-tab-strip-active .x-tab-right span.x-tab-strip-text {\n    padding-bottom:5px;\n}\n\n.x-tab-strip-bottom .x-tab-strip-active .x-tab-right {\n    margin-top:-1px;\n}\n\n.x-tab-strip-bottom .x-tab-strip-active .x-tab-right span.x-tab-strip-text {\n    padding-top:5px;\n}\n\n.x-tab-strip-top .x-tab-right {\n\tbackground: transparent no-repeat 0 -51px;\n    padding-left:10px;\n}\n\n.x-tab-strip-top .x-tab-left {\n\tbackground: transparent no-repeat right -351px;\n    padding-right:10px;\n}\n\n.x-tab-strip-top .x-tab-strip-inner {\n\tbackground: transparent repeat-x 0 -201px;\n}\n\n.x-tab-strip-top .x-tab-strip-over .x-tab-right {\n\t background-position:0 -101px;\n}\n\n.x-tab-strip-top .x-tab-strip-over .x-tab-left {\n\t background-position:right -401px;\n}\n\n.x-tab-strip-top .x-tab-strip-over .x-tab-strip-inner {\n\t background-position:0 -251px;\n}\n\n.x-tab-strip-top .x-tab-strip-active .x-tab-right {\n\tbackground-position: 0 0;\n}\n\n.x-tab-strip-top .x-tab-strip-active .x-tab-left {\n\tbackground-position: right -301px;\n}\n\n.x-tab-strip-top .x-tab-strip-active .x-tab-strip-inner {\n\tbackground-position: 0 -151px;\n}\n\n.x-tab-strip-bottom .x-tab-right {\n\tbackground: no-repeat bottom right;\n}\n\n.x-tab-strip-bottom .x-tab-left {\n\tbackground: no-repeat bottom left;\n}\n\n.x-tab-strip-bottom .x-tab-strip-active .x-tab-right {\n\tbackground: no-repeat bottom right;\n}\n\n.x-tab-strip-bottom .x-tab-strip-active .x-tab-left {\n\tbackground: no-repeat bottom left;\n}\n\n.x-tab-strip-bottom .x-tab-left {\n    margin-right: 3px;\n    padding:0 10px;\n}\n\n.x-tab-strip-bottom .x-tab-right {\n    padding:0;\n}\n\n.x-tab-strip .x-tab-strip-close {\n    display:none;\n}\n\n.x-tab-strip-closable {\n    position:relative;\n}\n\n.x-tab-strip-closable .x-tab-left {\n    padding-right:19px;\n}\n\n.x-tab-strip .x-tab-strip-closable a.x-tab-strip-close {\n    opacity:.6;\n    -moz-opacity:.6;\n    background-repeat:no-repeat;\n    display:block;\n\twidth:11px;\n    height:11px;\n    position:absolute;\n    top:3px;\n    right:3px;\n    cursor:pointer;\n    z-index:2;\n}\n\n.x-tab-strip .x-tab-strip-active a.x-tab-strip-close {\n    opacity:.8;\n    -moz-opacity:.8;\n}\n.x-tab-strip .x-tab-strip-closable a.x-tab-strip-close:hover{\n    opacity:1;\n    -moz-opacity:1;\n}\n\n.x-tab-panel-body {\n    border: 1px solid;\n}\n\n.x-tab-panel-body-top {\n    border-top: 0 none;\n}\n\n.x-tab-panel-body-bottom {\n    border-bottom: 0 none;\n}\n\n.x-tab-scroller-left {\n    background: transparent no-repeat -18px 0;\n    border-bottom: 1px solid;\n    width:18px;\n    position:absolute;\n    left:0;\n    top:0;\n    z-index:10;\n    cursor:pointer;\n}\n.x-tab-scroller-left-over {\n    background-position: 0 0;\n}\n\n.x-tab-scroller-left-disabled {\n    background-position: -18px 0;\n    opacity:.5;\n    -moz-opacity:.5;\n    filter:alpha(opacity=50);\n    cursor:default;\n}\n\n.x-tab-scroller-right {\n    background: transparent no-repeat 0 0;\n    border-bottom: 1px solid;\n    width:18px;\n    position:absolute;\n    right:0;\n    top:0;\n    z-index:10;\n    cursor:pointer;\n}\n\n.x-tab-scroller-right-over {\n    background-position: -18px 0;\n}\n\n.x-tab-scroller-right-disabled {\n    background-position: 0 0;\n    opacity:.5;\n    -moz-opacity:.5;\n    filter:alpha(opacity=50);\n    cursor:default;\n}\n\n.x-tab-scrolling-bottom .x-tab-scroller-left, .x-tab-scrolling-bottom .x-tab-scroller-right{\n    margin-top: 1px;\n}\n\n.x-tab-scrolling .x-tab-strip-wrap {\n    margin-left:18px;\n    margin-right:18px;\n}\n\n.x-tab-scrolling {\n    position:relative;    \n}\n\n.x-tab-panel-bbar .x-toolbar {\n    border:1px solid;\n    border-top:0 none;\n    overflow:hidden;\n    padding:2px;\n}\n\n.x-tab-panel-tbar .x-toolbar {\n    border:1px solid;\n    border-top:0 none;\n    overflow:hidden;\n    padding:2px;\n}", ""]);

// exports


/***/ }),
/* 914 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(915);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 915 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n/* all fields */\n.x-form-field{\n    margin: 0 0 0 0;\n}\n\n.ext-webkit *:focus{\n    outline: none !important;\n}\n\n/* ---- text fields ---- */\n.x-form-text, textarea.x-form-field{\n    padding:1px 3px;\n    background:repeat-x 0 0;\n    border:1px solid;\n}\n\ntextarea.x-form-field {\n    padding:2px 3px;\n}\n\n.x-form-text, .ext-ie .x-form-file {\n    height:22px;\n    line-height:18px;\n    vertical-align:middle;\n}\n\n.ext-ie6 .x-form-text, .ext-ie7 .x-form-text {\n    margin:-1px 0; /* ie bogus margin bug */\n    height:22px; /* ie quirks */\n    line-height:18px;\n}\n\n.ext-ie6 textarea.x-form-field, .ext-ie7 textarea.x-form-field {\n    margin:-1px 0; /* ie bogus margin bug */\n}\n\n.ext-strict .x-form-text {\n    height:18px;\n}\n\n.ext-safari.ext-mac textarea.x-form-field {\n    margin-bottom:-2px; /* another bogus margin bug, safari/mac only */\n}\n\n.ext-strict .ext-ie8 .x-form-text, .ext-strict .ext-ie8 textarea.x-form-field {\n\tmargin-bottom: 1px;\n}\n\n.ext-gecko .x-form-text , .ext-ie8 .x-form-text {\n    padding-top:2px; /* FF won't center the text vertically */\n    padding-bottom:0;\n}\n\ntextarea {\n    resize: none;  /* Disable browser resizable textarea */\n}\n\n/* select boxes */\n.x-form-select-one {\n    height:20px;\n    line-height:18px;\n    vertical-align:middle;\n    border: 1px solid;\n}\n\n/* multi select boxes */\n\n/* --- TODO --- */\n\n/* 2.0.2 style */\n.x-form-check-wrap {\n    line-height:18px;\n    height: 22px;\n}\n\n.ext-ie .x-form-check-wrap input {\n    width:15px;\n    height:15px;\n}\n\n.x-form-check-wrap input{\n    vertical-align: bottom;\n}\n\n.x-editor .x-form-check-wrap {\n    padding:3px;\n}\n\n.x-editor .x-form-checkbox {\n    height:13px;\n}\n\n.x-form-check-group-label {\n    border-bottom: 1px solid;\n    margin-bottom: 5px;\n    padding-left: 3px !important;\n    float: none !important;\n}\n\n/* wrapped fields and triggers */\n.x-form-field-wrap .x-form-trigger{\n    width:17px;\n    height:21px;\n    border:0;\n    background:transparent no-repeat 0 0;\n    cursor:pointer;\n    border-bottom: 1px solid;\n    position:absolute;\n    top:0;\n}\n\n.x-form-field-wrap .x-form-date-trigger, .x-form-field-wrap .x-form-clear-trigger, .x-form-field-wrap .x-form-search-trigger{\n    cursor:pointer;\n}\n\n.ext-webkit .x-form-field-wrap .x-form-trigger{\n    right:0;\n}\n\n.x-form-field-wrap .x-form-twin-triggers .x-form-trigger{\n    position:static;\n    top:auto;\n    vertical-align:top;\n}\n\n.x-form-field-wrap {\n    position:relative;\n    left:0;top:0;\n    zoom:1;\n    white-space: nowrap;\n}\n\n.x-form-field-wrap .x-form-trigger-over{\n    background-position:-17px 0;\n}\n\n.x-form-field-wrap .x-form-trigger-click{\n    background-position:-34px 0;\n}\n\n.x-trigger-wrap-focus .x-form-trigger{\n    background-position:-51px 0;\n}\n\n.x-trigger-wrap-focus .x-form-trigger-over{\n    background-position:-68px 0;\n}\n\n.x-trigger-wrap-focus .x-form-trigger-click{\n    background-position:-85px 0;\n}\n\n.x-trigger-wrap-focus .x-form-trigger{\n    border-bottom: 1px solid;\n}\n\n.x-item-disabled .x-form-trigger-over{\n    background-position:0 0 !important;\n    border-bottom: 1px solid;\n}\n\n.x-item-disabled .x-form-trigger-click{\n    background-position:0 0 !important;\n    border-bottom: 1px solid;\n}\n\n.x-trigger-noedit{\n    cursor:pointer;\n}\n\n/* field focus style */\n.x-form-focus, textarea.x-form-focus{\n\tborder: 1px solid;\n}\n\n/* invalid fields */\n.x-form-invalid, textarea.x-form-invalid{\n\tbackground:repeat-x bottom;\n\tborder: 1px solid;\n}\n\n.ext-webkit .x-form-invalid{\n\tborder: 1px solid;\n}\n\n.x-form-inner-invalid, textarea.x-form-inner-invalid{\n\tbackground:repeat-x bottom;\n}\n\n/* editors */\n.x-editor {\n    visibility:hidden;\n    padding:0;\n    margin:0;\n}\n\n.x-form-grow-sizer {\n    left: -10000px;\n\tpadding: 8px 3px;\n    position: absolute;\n    visibility:hidden;\n    top: -10000px;\n\twhite-space: pre-wrap;\n    white-space: -moz-pre-wrap;\n    white-space: -pre-wrap;\n    white-space: -o-pre-wrap;\n    word-wrap: break-word;\n    zoom:1;\n}\n\n.x-form-grow-sizer p {\n    margin:0 !important;\n    border:0 none !important;\n    padding:0 !important;\n}\n\n/* Form Items CSS */\n\n.x-form-item {\n    display:block;\n    margin-bottom:4px;\n    zoom:1;\n}\n\n.x-form-item label.x-form-item-label {\n    display:block;\n    float:left;\n    width:100px;\n    padding:3px;\n    padding-left:0;\n    clear:left;\n    z-index:2;\n    position:relative;\n}\n\n.x-form-element {\n    padding-left:105px;\n    position:relative;\n}\n\n.x-form-invalid-msg {\n    padding:2px;\n    padding-left:18px;\n    background: transparent no-repeat 0 2px;\n    line-height:16px;\n    width:200px;\n}\n\n.x-form-label-left label.x-form-item-label {\n   text-align:left;\n}\n\n.x-form-label-right label.x-form-item-label {\n   text-align:right;\n}\n\n.x-form-label-top .x-form-item label.x-form-item-label {\n    width:auto;\n    float:none;\n    clear:none;\n    display:inline;\n    margin-bottom:4px;\n    position:static;\n}\n\n.x-form-label-top .x-form-element {\n    padding-left:0;\n    padding-top:4px;\n}\n\n.x-form-label-top .x-form-item {\n    padding-bottom:4px;\n}\n\n/* Editor small font for grid, toolbar and tree */\n.x-small-editor .x-form-text {\n    height:20px;\n    line-height:16px;\n    vertical-align:middle;\n}\n\n.ext-ie6 .x-small-editor .x-form-text, .ext-ie7 .x-small-editor .x-form-text {\n    margin-top:-1px !important; /* ie bogus margin bug */\n    margin-bottom:-1px !important;\n    height:20px !important; /* ie quirks */\n    line-height:16px !important;\n}\n\n.ext-strict .x-small-editor .x-form-text {\n    height:16px !important;\n}\n\n.ext-ie6 .x-small-editor .x-form-text, .ext-ie7 .x-small-editor .x-form-text {\n    height:20px;\n    line-height:16px;\n}\n\n.ext-border-box .x-small-editor .x-form-text {\n    height:20px;\n}\n\n.x-small-editor .x-form-select-one {\n    height:20px;\n    line-height:16px;\n    vertical-align:middle;\n}\n\n.x-small-editor .x-form-num-field {\n    text-align:right;\n}\n\n.x-small-editor .x-form-field-wrap .x-form-trigger{\n    height:19px;\n}\n\n.ext-webkit .x-small-editor .x-form-text{padding-top:3px;font-size:100%;}\n\n.x-form-clear {\n    clear:both;\n    height:0;\n    overflow:hidden;\n    line-height:0;\n    font-size:0;\n}\n.x-form-clear-left {\n    clear:left;\n    height:0;\n    overflow:hidden;\n    line-height:0;\n    font-size:0;\n}\n\n.ext-ie6 .x-form-check-wrap input, .ext-border-box .x-form-check-wrap input{\n   margin-top: 3px; \n}\n\n.x-form-cb-label {\n    position: relative;\n    margin-left:4px;\n    top: 2px;\n}\n\n.ext-ie .x-form-cb-label{\n    top: 1px;\n}\n\n.ext-ie6 .x-form-cb-label, .ext-border-box .x-form-cb-label{\n    top: 3px;\n}\n\n.x-form-display-field{\n    padding-top: 2px;\n}\n\n.ext-gecko .x-form-display-field, .ext-strict .ext-ie7 .x-form-display-field{\n    padding-top: 1px;\n}\n\n.ext-ie .x-form-display-field{\n    padding-top: 3px;\n}\n\n.ext-strict .ext-ie8 .x-form-display-field{\n    padding-top: 0;\n}\n\n.x-form-column {\n    float:left;\n    padding:0;\n    margin:0;\n    width:48%;\n    overflow:hidden;\n    zoom:1;\n}\n\n/* buttons */\n.x-form .x-form-btns-ct .x-btn{\n\tfloat:right;\n\tclear:none;\n}\n\n.x-form .x-form-btns-ct .x-form-btns td {\n\tborder:0;\n\tpadding:0;\n}\n\n.x-form .x-form-btns-ct .x-form-btns-right table{\n\tfloat:right;\n\tclear:none;\n}\n\n.x-form .x-form-btns-ct .x-form-btns-left table{\n\tfloat:left;\n\tclear:none;\n}\n\n.x-form .x-form-btns-ct .x-form-btns-center{\n\ttext-align:center; /*ie*/\n}\n\n.x-form .x-form-btns-ct .x-form-btns-center table{\n\tmargin:0 auto; /*everyone else*/\n}\n\n.x-form .x-form-btns-ct table td.x-form-btn-td{\n\tpadding:3px;\n}\n\n.x-form .x-form-btns-ct .x-btn-focus .x-btn-left{\n\tbackground-position:0 -147px;\n}\n\n.x-form .x-form-btns-ct .x-btn-focus .x-btn-right{\n\tbackground-position:0 -168px;\n}\n\n.x-form .x-form-btns-ct .x-btn-focus .x-btn-center{\n\tbackground-position:0 -189px;\n}\n\n.x-form .x-form-btns-ct .x-btn-click .x-btn-center{\n\tbackground-position:0 -126px;\n}\n\n.x-form .x-form-btns-ct .x-btn-click  .x-btn-right{\n\tbackground-position:0 -84px;\n}\n\n.x-form .x-form-btns-ct .x-btn-click .x-btn-left{\n\tbackground-position:0 -63px;\n}\n\n.x-form-invalid-icon {\n    width:16px;\n    height:18px;\n    visibility:hidden;\n    position:absolute;\n    left:0;\n    top:0;\n    display:block;\n    background:transparent no-repeat 0 2px;\n}\n\n/* fieldsets */\n.x-fieldset {\n    border:1px solid;\n    padding:10px;\n    margin-bottom:10px;\n    display:block; /* preserve margins in IE */\n}\n\n/* make top of checkbox/tools visible in webkit */\n.ext-webkit .x-fieldset-header {\n    padding-top: 1px;\n}        \n\n.ext-ie .x-fieldset legend {\n    margin-bottom:10px;\n}\n\n.ext-ie .x-fieldset {\n    padding-top: 0;\n    padding-bottom:10px;\n}\n\n.x-fieldset legend .x-tool-toggle {\n    margin-right:3px;\n    margin-left:0;\n    float:left !important;\n}\n\n.x-fieldset legend input {\n    margin-right:3px;\n    float:left !important;\n    height:13px;\n    width:13px;\n}\n\nfieldset.x-panel-collapsed {\n    padding-bottom:0 !important;\n    border-width: 1px 1px 0 1px !important;\n    border-left-color: transparent;\n    border-right-color: transparent;\n}      \n  \n.ext-ie6 fieldset.x-panel-collapsed{\n    padding-bottom:0 !important;\n    border-width: 1px 0 0 0 !important;\n    margin-left: 1px;\n    margin-right: 1px;\n}\n\nfieldset.x-panel-collapsed .x-fieldset-bwrap {\n    visibility:hidden;\n    position:absolute;\n    left:-1000px;\n    top:-1000px;\n}\n\n.ext-ie .x-fieldset-bwrap {\n    zoom:1;\n}\n\n.x-fieldset-noborder {\n    border:0px none transparent;\n}\n\n.x-fieldset-noborder legend {\n    margin-left:-3px;\n}\n\n/* IE legend positioning bug */\n.ext-ie .x-fieldset-noborder legend {\n    position: relative;\n    margin-bottom:23px;\n}\n.ext-ie .x-fieldset-noborder legend span {\n    position: absolute;\n    left:16px;\n}\n        \n.ext-gecko .x-window-body .x-form-item {\n    -moz-outline: none;\n    outline: none;\n    overflow: auto;\n}\n\n.ext-gecko .x-form-item {\n    -moz-outline: none;\n    outline: none;\n}\n\n.x-hide-label label.x-form-item-label {\n     display:none;\n}\n\n.x-hide-label .x-form-element {\n     padding-left: 0 !important;\n}\n\n.x-form-label-top .x-hide-label label.x-form-item-label{\n    display: none;\n}\n\n.x-fieldset {\n    overflow:hidden;\n}\n\n.x-fieldset-bwrap {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-fieldset-body {\n    overflow:hidden;\n}\n\n\n", ""]);

// exports


/***/ }),
/* 916 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(917);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 917 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-btn{\r\n\tcursor:pointer;\r\n\twhite-space: nowrap;\r\n}\r\n\r\n.x-btn button{\r\n    border:0 none;\r\n    background:transparent;\r\n    padding-left:3px;\r\n    padding-right:3px;\r\n    cursor:pointer;\r\n    margin:0;\r\n    overflow:visible;\r\n    width:auto;\r\n    -moz-outline:0 none;\r\n    outline:0 none;\r\n}\r\n\r\n* html .ext-ie .x-btn button {\r\n    width:1px;\r\n}\r\n\r\n.ext-gecko .x-btn button {\r\n    padding-left:0;\r\n    padding-right:0;\r\n}\r\n\r\n.ext-gecko .x-btn button::-moz-focus-inner {\r\n    padding:0;\r\n}\r\n\r\n.ext-ie .x-btn button {\r\n    padding-top:2px;\r\n}\r\n\r\n.x-btn td {\r\n    padding:0 !important;\r\n}\r\n\r\n.x-btn-text {\r\n    cursor:pointer;\r\n\twhite-space: nowrap;\r\n    padding:0;\r\n}\r\n\r\n/* icon placement and sizing styles */\r\n\r\n/* Only text */\r\n.x-btn-noicon .x-btn-small .x-btn-text{\r\n\theight: 16px;\r\n}\r\n\r\n.x-btn-noicon .x-btn-medium .x-btn-text{\r\n    height: 24px;\r\n}\r\n\r\n.x-btn-noicon .x-btn-large .x-btn-text{\r\n    height: 32px;\r\n}\r\n\r\n/* Only icons */\r\n.x-btn-icon .x-btn-text{\r\n    background-position: center;\r\n\tbackground-repeat: no-repeat;\r\n}\r\n\r\n.x-btn-icon .x-btn-small .x-btn-text{\r\n\theight: 16px;\r\n\twidth: 16px;\r\n}\r\n\r\n.x-btn-icon .x-btn-medium .x-btn-text{\r\n    height: 24px;\r\n\twidth: 24px;\r\n}\r\n\r\n.x-btn-icon .x-btn-large .x-btn-text{\r\n    height: 32px;\r\n\twidth: 32px;\r\n}\r\n\r\n/* Icons and text */\r\n/* left */\r\n.x-btn-text-icon .x-btn-icon-small-left .x-btn-text{\r\n    background-position: 0 center;\r\n\tbackground-repeat: no-repeat;\r\n    padding-left:18px;\r\n    height:16px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-medium-left .x-btn-text{\r\n    background-position: 0 center;\r\n\tbackground-repeat: no-repeat;\r\n    padding-left:26px;\r\n    height:24px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-large-left .x-btn-text{\r\n    background-position: 0 center;\r\n\tbackground-repeat: no-repeat;\r\n    padding-left:34px;\r\n    height:32px;\r\n}\r\n\r\n/* top */\r\n.x-btn-text-icon .x-btn-icon-small-top .x-btn-text{\r\n    background-position: center 0;\r\n\tbackground-repeat: no-repeat;\r\n    padding-top:18px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-medium-top .x-btn-text{\r\n    background-position: center 0;\r\n\tbackground-repeat: no-repeat;\r\n    padding-top:26px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-large-top .x-btn-text{\r\n    background-position: center 0;\r\n\tbackground-repeat: no-repeat;\r\n    padding-top:34px;\r\n}\r\n\r\n/* right */\r\n.x-btn-text-icon .x-btn-icon-small-right .x-btn-text{\r\n    background-position: right center;\r\n\tbackground-repeat: no-repeat;\r\n    padding-right:18px;\r\n    height:16px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-medium-right .x-btn-text{\r\n    background-position: right center;\r\n\tbackground-repeat: no-repeat;\r\n    padding-right:26px;\r\n    height:24px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-large-right .x-btn-text{\r\n    background-position: right center;\r\n\tbackground-repeat: no-repeat;\r\n    padding-right:34px;\r\n    height:32px;\r\n}\r\n\r\n/* bottom */\r\n.x-btn-text-icon .x-btn-icon-small-bottom .x-btn-text{\r\n    background-position: center bottom;\r\n\tbackground-repeat: no-repeat;\r\n    padding-bottom:18px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-medium-bottom .x-btn-text{\r\n    background-position: center bottom;\r\n\tbackground-repeat: no-repeat;\r\n    padding-bottom:26px;\r\n}\r\n\r\n.x-btn-text-icon .x-btn-icon-large-bottom .x-btn-text{\r\n    background-position: center bottom;\r\n\tbackground-repeat: no-repeat;\r\n    padding-bottom:34px;\r\n}\r\n\r\n/* background positioning */\r\n.x-btn-tr i, .x-btn-tl i, .x-btn-mr i, .x-btn-ml i, .x-btn-br i, .x-btn-bl i{\r\n\tfont-size:1px;\r\n    line-height:1px;\r\n    width:3px;\r\n    display:block;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-btn-tr i, .x-btn-tl i, .x-btn-br i, .x-btn-bl i{\r\n\theight:3px;\r\n}\r\n\r\n.x-btn-tl{\r\n\twidth:3px;\r\n\theight:3px;\r\n\tbackground:no-repeat 0 0;\r\n}\r\n.x-btn-tr{\r\n\twidth:3px;\r\n\theight:3px;\r\n\tbackground:no-repeat -3px 0;\r\n}\r\n.x-btn-tc{\r\n\theight:3px;\r\n\tbackground:repeat-x 0 -6px;\r\n}\r\n\r\n.x-btn-ml{\r\n\twidth:3px;\r\n\tbackground:no-repeat 0 -24px;\r\n}\r\n.x-btn-mr{\r\n\twidth:3px;\r\n\tbackground:no-repeat -3px -24px;\r\n}\r\n\r\n.x-btn-mc{\r\n\tbackground:repeat-x 0 -1096px;\r\n    vertical-align: middle;\r\n\ttext-align:center;\r\n\tpadding:0 5px;\r\n\tcursor:pointer;\r\n\twhite-space:nowrap;\r\n}\r\n\r\n/* Fixes an issue with the button height */\r\n.ext-strict .ext-ie6 .x-btn-mc, .ext-strict .ext-ie7 .x-btn-mc {\r\n    height: 100%;\r\n}\r\n\r\n.x-btn-bl{\r\n\twidth:3px;\r\n\theight:3px;\r\n\tbackground:no-repeat 0 -3px;\r\n}\r\n\r\n.x-btn-br{\r\n\twidth:3px;\r\n\theight:3px;\r\n\tbackground:no-repeat -3px -3px;\r\n}\r\n\r\n.x-btn-bc{\r\n\theight:3px;\r\n\tbackground:repeat-x 0 -15px;\r\n}\r\n\r\n.x-btn-over .x-btn-tl{\r\n\tbackground-position: -6px 0;\r\n}\r\n\r\n.x-btn-over .x-btn-tr{\r\n\tbackground-position: -9px 0;\r\n}\r\n\r\n.x-btn-over .x-btn-tc{\r\n\tbackground-position: 0 -9px;\r\n}\r\n\r\n.x-btn-over .x-btn-ml{\r\n\tbackground-position: -6px -24px;\r\n}\r\n\r\n.x-btn-over .x-btn-mr{\r\n\tbackground-position: -9px -24px;\r\n}\r\n\r\n.x-btn-over .x-btn-mc{\r\n\tbackground-position: 0 -2168px;\r\n}\r\n\r\n.x-btn-over .x-btn-bl{\r\n\tbackground-position: -6px -3px;\r\n}\r\n\r\n.x-btn-over .x-btn-br{\r\n\tbackground-position: -9px -3px;\r\n}\r\n\r\n.x-btn-over .x-btn-bc{\r\n\tbackground-position: 0 -18px;\r\n}\r\n\r\n.x-btn-click .x-btn-tl, .x-btn-menu-active .x-btn-tl, .x-btn-pressed .x-btn-tl{\r\n\tbackground-position: -12px 0;\r\n}\r\n\r\n.x-btn-click .x-btn-tr, .x-btn-menu-active .x-btn-tr, .x-btn-pressed .x-btn-tr{\r\n\tbackground-position: -15px 0;\r\n}\r\n\r\n.x-btn-click .x-btn-tc, .x-btn-menu-active .x-btn-tc, .x-btn-pressed .x-btn-tc{\r\n\tbackground-position: 0 -12px;\r\n}\r\n\r\n.x-btn-click .x-btn-ml, .x-btn-menu-active .x-btn-ml, .x-btn-pressed .x-btn-ml{\r\n\tbackground-position: -12px -24px;\r\n}\r\n\r\n.x-btn-click .x-btn-mr, .x-btn-menu-active .x-btn-mr, .x-btn-pressed .x-btn-mr{\r\n\tbackground-position: -15px -24px;\r\n}\r\n\r\n.x-btn-click .x-btn-mc, .x-btn-menu-active .x-btn-mc, .x-btn-pressed .x-btn-mc{\r\n\tbackground-position: 0 -3240px;\r\n}\r\n\r\n.x-btn-click .x-btn-bl, .x-btn-menu-active .x-btn-bl, .x-btn-pressed .x-btn-bl{\r\n\tbackground-position: -12px -3px;\r\n}\r\n\r\n.x-btn-click .x-btn-br, .x-btn-menu-active .x-btn-br, .x-btn-pressed .x-btn-br{\r\n\tbackground-position: -15px -3px;\r\n}\r\n\r\n.x-btn-click .x-btn-bc, .x-btn-menu-active .x-btn-bc, .x-btn-pressed .x-btn-bc{\r\n\tbackground-position: 0 -21px;\r\n}\r\n\r\n.x-btn-disabled *{\r\n\tcursor:default !important;\r\n}\r\n\r\n\r\n/* With a menu arrow */\r\n/* right */\r\n.x-btn-mc em.x-btn-arrow {\r\n    display:block;\r\n    background:transparent no-repeat right center;\r\n\tpadding-right:10px;\r\n}\r\n\r\n.x-btn-mc em.x-btn-split {\r\n    display:block;\r\n    background:transparent no-repeat right center;\r\n\tpadding-right:14px;\r\n}\r\n\r\n/* bottom */\r\n.x-btn-mc em.x-btn-arrow-bottom {\r\n    display:block;\r\n    background:transparent no-repeat center bottom;\r\n\tpadding-bottom:14px;\r\n}\r\n\r\n.x-btn-mc em.x-btn-split-bottom {\r\n    display:block;\r\n    background:transparent no-repeat center bottom;\r\n\tpadding-bottom:14px;\r\n}\r\n\r\n/* height adjustment class */\r\n.x-btn-as-arrow .x-btn-mc em {\r\n    display:block;\r\n    background:transparent;\r\n\tpadding-bottom:14px;\r\n}\r\n\r\n/* groups */\r\n.x-btn-group {\r\n    padding:1px;\r\n}\r\n\r\n.x-btn-group-header {\r\n    padding:2px;\r\n    text-align:center;\r\n}\r\n\r\n.x-btn-group-tc {\r\n\tbackground: transparent repeat-x 0 0;\r\n\toverflow:hidden;\r\n}\r\n\r\n.x-btn-group-tl {\r\n\tbackground: transparent no-repeat 0 0;\r\n\tpadding-left:3px;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-tr {\r\n\tbackground: transparent no-repeat right 0;\r\n\tzoom:1;\r\n    padding-right:3px;\r\n}\r\n\r\n.x-btn-group-bc {\r\n\tbackground: transparent repeat-x 0 bottom;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-bc .x-panel-footer {\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-bl {\r\n\tbackground: transparent no-repeat 0 bottom;\r\n\tpadding-left:3px;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-br {\r\n\tbackground: transparent no-repeat right bottom;\r\n\tpadding-right:3px;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-mc {\r\n    border:0 none;\r\n    padding:1px 0 0 0;\r\n    margin:0;\r\n}\r\n\r\n.x-btn-group-mc .x-btn-group-body {\r\n    background:transparent;\r\n    border: 0 none;\r\n}\r\n\r\n.x-btn-group-ml {\r\n\tbackground: transparent repeat-y 0 0;\r\n\tpadding-left:3px;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-mr {\r\n\tbackground: transparent repeat-y right 0;\r\n\tpadding-right:3px;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-bc .x-btn-group-footer {\r\n    padding-bottom:6px;\r\n}\r\n\r\n.x-panel-nofooter .x-btn-group-bc {\r\n\theight:3px;\r\n    font-size:0;\r\n    line-height:0;\r\n}\r\n\r\n.x-btn-group-bwrap {\r\n    overflow:hidden;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-body {\r\n    overflow:hidden;\r\n    zoom:1;\r\n}\r\n\r\n.x-btn-group-notitle .x-btn-group-tc {\r\n\tbackground: transparent repeat-x 0 0;\r\n\toverflow:hidden;\r\n    height:2px;\r\n}", ""]);

// exports


/***/ }),
/* 918 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(919);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 919 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-toolbar{\r\n    border-style:solid;\r\n    border-width:0 0 1px 0;\r\n    display: block;\r\n\tpadding:2px;\r\n    background:repeat-x top left;\r\n    position:relative;\r\n    left:0;\r\n    top:0;\r\n    zoom:1;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-toolbar-left {\r\n    width: 100%;\r\n}\r\n\r\n.x-toolbar .x-item-disabled .x-btn-icon {\r\n    opacity: .35;\r\n    -moz-opacity: .35;\r\n    filter: alpha(opacity=35);\r\n}\r\n\r\n.x-toolbar td {\r\n\tvertical-align:middle;\r\n}\r\n\r\n.x-toolbar td,.x-toolbar span,.x-toolbar input,.x-toolbar div,.x-toolbar select,.x-toolbar label{\r\n\twhite-space: nowrap;\r\n}\r\n\r\n.x-toolbar .x-item-disabled {\r\n\tcursor:default;\r\n\topacity:.6;\r\n\t-moz-opacity:.6;\r\n\tfilter:alpha(opacity=60);\r\n}\r\n\r\n.x-toolbar .x-item-disabled * {\r\n\tcursor:default;\r\n}\r\n\r\n.x-toolbar .x-toolbar-cell {\r\n    vertical-align:middle;\r\n}\r\n\r\n.x-toolbar .x-btn-tl, .x-toolbar .x-btn-tr, .x-toolbar .x-btn-tc, .x-toolbar .x-btn-ml, .x-toolbar .x-btn-mr,\r\n.x-toolbar .x-btn-mc, .x-toolbar .x-btn-bl, .x-toolbar .x-btn-br, .x-toolbar .x-btn-bc\r\n{\r\n\tbackground-position: 500px 500px;\r\n}\r\n\r\n/* These rules are duplicated from button.css to give priority of x-toolbar rules above */\r\n.x-toolbar .x-btn-over .x-btn-tl{\r\n\tbackground-position: -6px 0;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-tr{\r\n\tbackground-position: -9px 0;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-tc{\r\n\tbackground-position: 0 -9px;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-ml{\r\n\tbackground-position: -6px -24px;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-mr{\r\n\tbackground-position: -9px -24px;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-mc{\r\n\tbackground-position: 0 -2168px;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-bl{\r\n\tbackground-position: -6px -3px;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-br{\r\n\tbackground-position: -9px -3px;\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-bc{\r\n\tbackground-position: 0 -18px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-tl, .x-toolbar .x-btn-menu-active .x-btn-tl, .x-toolbar .x-btn-pressed .x-btn-tl{\r\n\tbackground-position: -12px 0;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-tr, .x-toolbar .x-btn-menu-active .x-btn-tr, .x-toolbar .x-btn-pressed .x-btn-tr{\r\n\tbackground-position: -15px 0;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-tc, .x-toolbar .x-btn-menu-active .x-btn-tc, .x-toolbar .x-btn-pressed .x-btn-tc{\r\n\tbackground-position: 0 -12px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-ml, .x-toolbar .x-btn-menu-active .x-btn-ml, .x-toolbar .x-btn-pressed .x-btn-ml{\r\n\tbackground-position: -12px -24px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-mr, .x-toolbar .x-btn-menu-active .x-btn-mr, .x-toolbar .x-btn-pressed .x-btn-mr{\r\n\tbackground-position: -15px -24px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-mc, .x-toolbar .x-btn-menu-active .x-btn-mc, .x-toolbar .x-btn-pressed .x-btn-mc{\r\n\tbackground-position: 0 -3240px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-bl, .x-toolbar .x-btn-menu-active .x-btn-bl, .x-toolbar .x-btn-pressed .x-btn-bl{\r\n\tbackground-position: -12px -3px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-br, .x-toolbar .x-btn-menu-active .x-btn-br, .x-toolbar .x-btn-pressed .x-btn-br{\r\n\tbackground-position: -15px -3px;\r\n}\r\n\r\n.x-toolbar .x-btn-click .x-btn-bc, .x-toolbar .x-btn-menu-active .x-btn-bc, .x-toolbar .x-btn-pressed .x-btn-bc{\r\n\tbackground-position: 0 -21px;\r\n}\r\n\r\n.x-toolbar div.xtb-text{\r\n    padding:2px 2px 0;\r\n    line-height:16px;\r\n    display:block;\r\n}\r\n\r\n.x-toolbar .xtb-sep {\r\n\tbackground-position: center;\r\n\tbackground-repeat: no-repeat;\r\n\tdisplay: block;\r\n\tfont-size: 1px;\r\n\theight: 16px;\r\n\twidth:4px;\r\n\toverflow: hidden;\r\n\tcursor:default;\r\n\tmargin: 0 2px 0;\r\n\tborder:0;\r\n}\r\n\r\n.x-toolbar .xtb-spacer {\r\n    width:2px;\r\n}\r\n\r\n/* Paging Toolbar */\r\n.x-tbar-page-number{\r\n\twidth:30px;\r\n\theight:14px;\r\n}\r\n\r\n.ext-ie .x-tbar-page-number{\r\n    margin-top: 2px;\r\n}\r\n\r\n.x-paging-info {\r\n    position:absolute;\r\n    top:5px;\r\n    right: 8px;\r\n}\r\n\r\n/* floating */\r\n.x-toolbar-ct {\r\n    width:100%;\r\n}\r\n\r\n.x-toolbar-right td {\r\n    text-align: center;\r\n}\r\n\r\n.x-panel-tbar, .x-panel-bbar, .x-window-tbar, .x-window-bbar, .x-tab-panel-tbar, .x-tab-panel-bbar, .x-plain-tbar, .x-plain-bbar {\r\n    overflow:hidden;\r\n    zoom:1;\r\n}\r\n\r\n.x-toolbar-more .x-btn-small .x-btn-text{\r\n\theight: 16px;\r\n\twidth: 12px;\r\n}\r\n\r\n.x-toolbar-more em.x-btn-arrow {\r\n    display:inline;\r\n    background:transparent;\r\n\tpadding-right:0;\r\n}\r\n\r\n.x-toolbar-more .x-btn-mc em.x-btn-arrow {\r\n    background-image: none;\r\n}\r\n\r\ndiv.x-toolbar-no-items {\r\n    color:gray !important;\r\n    padding:5px 10px !important;\r\n}\r\n\r\n/* fix ie toolbar form items */\r\n.ext-border-box .x-toolbar-cell .x-form-text {\r\n    margin-bottom:-1px !important;\r\n}\r\n\r\n.ext-border-box .x-toolbar-cell .x-form-field-wrap .x-form-text {\r\n    margin:0 !important;\r\n}\r\n\r\n.ext-ie .x-toolbar-cell .x-form-field-wrap {\r\n    height:21px;\r\n}\r\n\r\n.ext-ie .x-toolbar-cell .x-form-text {\r\n    position:relative;\r\n    top:-1px;\r\n}\r\n\r\n.ext-strict .ext-ie8 .x-toolbar-cell .x-form-field-trigger-wrap .x-form-text, .ext-strict .ext-ie .x-toolbar-cell .x-form-text {\r\n    top: 0px;\r\n}\r\n\r\n.x-toolbar-right td .x-form-field-trigger-wrap{\r\n    text-align: left;\r\n}\r\n\r\n.x-toolbar-cell .x-form-checkbox, .x-toolbar-cell .x-form-radio{\r\n    margin-top: 5px;\r\n}\r\n\r\n.x-toolbar-cell .x-form-cb-label{\r\n    vertical-align: bottom;\r\n    top: 1px;\r\n}\r\n\r\n.ext-ie .x-toolbar-cell .x-form-checkbox, .ext-ie .x-toolbar-cell .x-form-radio{\r\n    margin-top: 4px;\r\n}\r\n\r\n.ext-ie .x-toolbar-cell .x-form-cb-label{\r\n    top: 0;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 920 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(921);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 921 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n/* Grid3 styles */\r\n.x-grid3 {\r\n\tposition:relative;\r\n\toverflow:hidden;\r\n}\r\n\r\n.x-grid-panel .x-panel-body {\r\n    overflow:hidden !important;\r\n}\r\n\r\n.x-grid-panel .x-panel-mc .x-panel-body {\r\n    border:1px solid;\r\n}\r\n\r\n.x-grid3 table {\r\n    table-layout:fixed;\r\n}\r\n\r\n.x-grid3-viewport{\r\n\toverflow:hidden;\r\n}\r\n\r\n.x-grid3-hd-row td, .x-grid3-row td, .x-grid3-summary-row td{\r\n    -moz-outline: none;\r\n    outline: none;\r\n\t-moz-user-focus: normal;\r\n}\r\n\r\n.x-grid3-row td, .x-grid3-summary-row td {\r\n    line-height:13px;\r\n    vertical-align: top;\r\n\tpadding-left:1px;\r\n    padding-right:1px;\r\n    -moz-user-select: none;\r\n    -khtml-user-select:none;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n.x-grid3-cell{\r\n    -moz-user-select: none;\r\n    -khtml-user-select:none;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n.x-grid3-hd-row td {\r\n    line-height:15px;\r\n    vertical-align:middle;\r\n    border-left:1px solid;\r\n    border-right:1px solid;\r\n}\r\n\r\n.x-grid3-hd-row .x-grid3-marker-hd {\r\n    padding:3px;\r\n}\r\n\r\n.x-grid3-row .x-grid3-marker {\r\n    padding:3px;\r\n}\r\n\r\n.x-grid3-cell-inner, .x-grid3-hd-inner{\r\n\toverflow:hidden;\r\n\t-o-text-overflow: ellipsis;\r\n\ttext-overflow: ellipsis;\r\n    padding:3px 3px 3px 5px;\r\n    white-space: nowrap;\r\n}\r\n\r\n.x-grid3-hd-inner {\r\n    position:relative;\r\n\tcursor:inherit;\r\n\tpadding:4px 3px 4px 5px;\r\n}\r\n\r\n.x-grid3-row-body {\r\n    white-space:normal;\r\n}\r\n\r\n.x-grid3-body-cell {\r\n    -moz-outline:0 none;\r\n    outline:0 none;\r\n}\r\n\r\n/* IE Quirks to clip */\r\n.ext-ie .x-grid3-cell-inner, .ext-ie .x-grid3-hd-inner{\r\n\twidth:100%;\r\n}\r\n\r\n/* reverse above in strict mode */\r\n.ext-strict .x-grid3-cell-inner, .ext-strict .x-grid3-hd-inner{\r\n\twidth:auto;\r\n}\r\n\r\n.x-grid-row-loading {\r\n    background: no-repeat center center;\r\n}\r\n\r\n.x-grid-page {\r\n    overflow:hidden;\r\n}\r\n\r\n.x-grid3-row {\r\n\tcursor: default;\r\n    border: 1px solid;\r\n    width:100%;\r\n}\r\n\r\n.x-grid3-row-over {\r\n\tborder:1px solid;\r\n    background: repeat-x left top;\r\n}\r\n\r\n.x-grid3-resize-proxy {\r\n\twidth:1px;\r\n    left:0;\r\n\tcursor: e-resize;\r\n\tcursor: col-resize;\r\n\tposition:absolute;\r\n\ttop:0;\r\n\theight:100px;\r\n\toverflow:hidden;\r\n\tvisibility:hidden;\r\n\tborder:0 none;\r\n\tz-index:7;\r\n}\r\n\r\n.x-grid3-resize-marker {\r\n\twidth:1px;\r\n\tleft:0;\r\n\tposition:absolute;\r\n\ttop:0;\r\n\theight:100px;\r\n\toverflow:hidden;\r\n\tvisibility:hidden;\r\n\tborder:0 none;\r\n\tz-index:7;\r\n}\r\n\r\n.x-grid3-focus {\r\n\tposition:absolute;\r\n\tleft:0;\r\n\ttop:0;\r\n\twidth:1px;\r\n\theight:1px;\r\n    line-height:1px;\r\n    font-size:1px;\r\n    -moz-outline:0 none;\r\n    outline:0 none;\r\n    -moz-user-select: text;\r\n    -khtml-user-select: text;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n/* header styles */\r\n.x-grid3-header{\r\n\tbackground: repeat-x 0 bottom;\r\n\tcursor:default;\r\n    zoom:1;\r\n    padding:1px 0 0 0;\r\n}\r\n\r\n.x-grid3-header-pop {\r\n    border-left:1px solid;\r\n    float:right;\r\n    clear:none;\r\n}\r\n\r\n.x-grid3-header-pop-inner {\r\n    border-left:1px solid;\r\n    width:14px;\r\n    height:19px;\r\n    background: transparent no-repeat center center;\r\n}\r\n\r\n.ext-ie .x-grid3-header-pop-inner {\r\n    width:15px;\r\n}\r\n\r\n.ext-strict .x-grid3-header-pop-inner {\r\n    width:14px; \r\n}\r\n\r\n.x-grid3-header-inner {\r\n    overflow:hidden;\r\n    zoom:1;\r\n    float:left;\r\n}\r\n\r\n.x-grid3-header-offset {\r\n    padding-left:1px;\r\n    text-align: left;\r\n}\r\n\r\ntd.x-grid3-hd-over, td.sort-desc, td.sort-asc, td.x-grid3-hd-menu-open {\r\n    border-left:1px solid;\r\n    border-right:1px solid;\r\n}\r\n\r\ntd.x-grid3-hd-over .x-grid3-hd-inner, td.sort-desc .x-grid3-hd-inner, td.sort-asc .x-grid3-hd-inner, td.x-grid3-hd-menu-open .x-grid3-hd-inner {\r\n    background: repeat-x left bottom;\r\n\r\n}\r\n\r\n.x-grid3-sort-icon{\r\n\tbackground-repeat: no-repeat;\r\n\tdisplay: none;\r\n\theight: 4px;\r\n\twidth: 13px;\r\n\tmargin-left:3px;\r\n\tvertical-align: middle;\r\n}\r\n\r\n.sort-asc .x-grid3-sort-icon, .sort-desc .x-grid3-sort-icon {\r\n\tdisplay: inline;\r\n}\r\n\r\n/* Header position fixes for IE strict mode */\r\n.ext-strict .ext-ie .x-grid3-header-inner, .ext-strict .ext-ie6 .x-grid3-hd {\r\n    position:relative;\r\n}\r\n\r\n.ext-strict .ext-ie6 .x-grid3-hd-inner{\r\n    position:static;\r\n}\r\n\r\n/* Body Styles */\r\n.x-grid3-body {\r\n\tzoom:1;\r\n}\r\n\r\n.x-grid3-scroller {\r\n\toverflow:auto;\r\n    zoom:1;\r\n    position:relative;\r\n}\r\n\r\n.x-grid3-cell-text, .x-grid3-hd-text {\r\n\tdisplay: block;\r\n\tpadding: 3px 5px 3px 5px;\r\n\t-moz-user-select: none;\r\n\t-khtml-user-select: none;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n.x-grid3-split {\r\n\tbackground-position: center;\r\n\tbackground-repeat: no-repeat;\r\n\tcursor: e-resize;\r\n\tcursor: col-resize;\r\n\tdisplay: block;\r\n\tfont-size: 1px;\r\n\theight: 16px;\r\n\toverflow: hidden;\r\n\tposition: absolute;\r\n\ttop: 2px;\r\n\twidth: 6px;\r\n\tz-index: 3;\r\n}\r\n\r\n/* Column Reorder DD */\r\n.x-dd-drag-proxy .x-grid3-hd-inner{\r\n\tbackground: repeat-x left bottom;\r\n\twidth:120px;\r\n\tpadding:3px;\r\n\tborder:1px solid;\r\n\toverflow:hidden;\r\n}\r\n\r\n.col-move-top, .col-move-bottom{\r\n\twidth:9px;\r\n\theight:9px;\r\n\tposition:absolute;\r\n\ttop:0;\r\n\tline-height:1px;\r\n\tfont-size:1px;\r\n\toverflow:hidden;\r\n\tvisibility:hidden;\r\n\tz-index:20000;\r\n    background:transparent no-repeat left top;\r\n}\r\n\r\n/* Selection Styles */\r\n.x-grid3-row-selected {\r\n\tborder:1px dotted;\r\n}\r\n\r\n.x-grid3-locked td.x-grid3-row-marker, .x-grid3-locked .x-grid3-row-selected td.x-grid3-row-marker{\r\n    background: repeat-x 0 bottom !important;\r\n    vertical-align:middle !important;\r\n    padding:0;\r\n    border-top:1px solid;\r\n    border-bottom:none !important;\r\n    border-right:1px solid !important;\r\n    text-align:center;\r\n}\r\n\r\n.x-grid3-locked td.x-grid3-row-marker div, .x-grid3-locked .x-grid3-row-selected td.x-grid3-row-marker div{\r\n    padding:0 4px;\r\n    text-align:center;\r\n}\r\n\r\n/* dirty cells */\r\n.x-grid3-dirty-cell {\r\n    background: transparent no-repeat 0 0;\r\n}\r\n\r\n/* Grid Toolbars */\r\n.x-grid3-topbar, .x-grid3-bottombar{\r\n    overflow:hidden;\r\n\tdisplay:none;\r\n\tzoom:1;\r\n    position:relative;\r\n}\r\n\r\n.x-grid3-topbar .x-toolbar{\r\n\tborder-right:0 none;\r\n}\r\n\r\n.x-grid3-bottombar .x-toolbar{\r\n\tborder-right:0 none;\r\n\tborder-bottom:0 none;\r\n\tborder-top:1px solid;\r\n}\r\n\r\n/* Props Grid Styles */\r\n.x-props-grid .x-grid3-cell{\r\n\tpadding:1px;\r\n}\r\n\r\n.x-props-grid .x-grid3-td-name .x-grid3-cell-inner{\r\n\tbackground:transparent repeat-y -16px !important;\r\n    padding-left:12px;\r\n}\r\n\r\n.x-props-grid .x-grid3-body .x-grid3-td-name{\r\n    padding:1px;\r\n    padding-right:0;\r\n    border:0 none;\r\n    border-right:1px solid;\r\n}\r\n\r\n/* dd */\r\n.x-grid3-col-dd {\r\n    border:0 none;\r\n    padding:0;\r\n    background:transparent;\r\n}\r\n\r\n.x-dd-drag-ghost .x-grid3-dd-wrap {\r\n    padding:1px 3px 3px 1px;\r\n}\r\n\r\n.x-grid3-hd {\r\n    -moz-user-select:none;\r\n    -khtml-user-select:none;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n.x-grid3-hd-btn {\r\n    display:none;\r\n    position:absolute;\r\n    width:14px;\r\n    background:no-repeat left center;\r\n    right:0;\r\n    top:0;\r\n    z-index:2;\r\n\tcursor:pointer;\r\n}\r\n\r\n.x-grid3-hd-over .x-grid3-hd-btn, .x-grid3-hd-menu-open .x-grid3-hd-btn {\r\n    display:block;\r\n}\r\n\r\na.x-grid3-hd-btn:hover {\r\n    background-position:-14px center;\r\n}\r\n\r\n/* Expanders */\r\n.x-grid3-body .x-grid3-td-expander {\r\n    background:transparent repeat-y right;\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-expander .x-grid3-cell-inner {\r\n    padding:0 !important;\r\n    height:100%;\r\n}\r\n\r\n.x-grid3-row-expander {\r\n    width:100%;\r\n    height:18px;\r\n    background-position:4px 2px;\r\n    background-repeat:no-repeat;\r\n    background-color:transparent;\r\n}\r\n\r\n.x-grid3-row-collapsed .x-grid3-row-expander {\r\n    background-position:4px 2px;\r\n}\r\n\r\n.x-grid3-row-expanded .x-grid3-row-expander {\r\n    background-position:-21px 2px;\r\n}\r\n\r\n.x-grid3-row-collapsed .x-grid3-row-body {\r\n    display:none !important;\r\n}\r\n\r\n.x-grid3-row-expanded .x-grid3-row-body {\r\n    display:block !important;\r\n}\r\n\r\n/* Checkers */\r\n.x-grid3-body .x-grid3-td-checker {\r\n    background:transparent repeat-y right;\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-checker .x-grid3-cell-inner, .x-grid3-header .x-grid3-td-checker .x-grid3-hd-inner {\r\n    padding:0 !important;\r\n    height:100%;\r\n}\r\n\r\n.x-grid3-row-checker, .x-grid3-hd-checker {\r\n    width:100%;\r\n    height:18px;\r\n    background-position:2px 2px;\r\n    background-repeat:no-repeat;\r\n    background-color:transparent;\r\n}\r\n\r\n.x-grid3-row .x-grid3-row-checker {\r\n    background-position:2px 2px;\r\n}\r\n\r\n.x-grid3-row-selected .x-grid3-row-checker, .x-grid3-hd-checker-on .x-grid3-hd-checker,.x-grid3-row-checked .x-grid3-row-checker {\r\n    background-position:-23px 2px;\r\n}\r\n\r\n.x-grid3-hd-checker {\r\n    background-position:2px 1px;\r\n}\r\n\r\n.ext-border-box .x-grid3-hd-checker {\r\n    background-position:2px 3px;\r\n}\r\n\r\n.x-grid3-hd-checker-on .x-grid3-hd-checker {\r\n    background-position:-23px 1px;\r\n}\r\n\r\n.ext-border-box .x-grid3-hd-checker-on .x-grid3-hd-checker {\r\n    background-position:-23px 3px;\r\n}\r\n\r\n/* Numberer */\r\n.x-grid3-body .x-grid3-td-numberer {\r\n    background:transparent repeat-y right;\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-numberer .x-grid3-cell-inner {\r\n    padding:3px 5px 0 0 !important;\r\n    text-align:right;\r\n}\r\n\r\n/* Row Icon */\r\n\r\n.x-grid3-body .x-grid3-td-row-icon {\r\n    background:transparent repeat-y right;\r\n    vertical-align:top;\r\n    text-align:center;\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-row-icon .x-grid3-cell-inner {\r\n    padding:0 !important;\r\n    background-position:center center;\r\n    background-repeat:no-repeat;\r\n    width:16px;\r\n    height:16px;\r\n    margin-left:2px;\r\n    margin-top:3px;\r\n}\r\n\r\n/* All specials */\r\n.x-grid3-body .x-grid3-row-selected .x-grid3-td-numberer,\r\n.x-grid3-body .x-grid3-row-selected .x-grid3-td-checker,\r\n.x-grid3-body .x-grid3-row-selected .x-grid3-td-expander {\r\n\tbackground:transparent repeat-y right;\r\n}\r\n\r\n.x-grid3-body .x-grid3-check-col-td .x-grid3-cell-inner {\r\n    padding: 1px 0 0 0 !important;\r\n}\r\n\r\n.x-grid3-check-col {\r\n    width:100%;\r\n    height:16px;\r\n    background-position:center center;\r\n    background-repeat:no-repeat;\r\n    background-color:transparent;\r\n}\r\n\r\n.x-grid3-check-col-on {\r\n    width:100%;\r\n    height:16px;\r\n    background-position:center center;\r\n    background-repeat:no-repeat;\r\n    background-color:transparent;\r\n}\r\n\r\n/* Grouping classes */\r\n.x-grid-group, .x-grid-group-body, .x-grid-group-hd {\r\n    zoom:1;\r\n}\r\n\r\n.x-grid-group-hd {\r\n    border-bottom: 2px solid;\r\n    cursor:pointer;\r\n    padding-top:6px;\r\n}\r\n\r\n.x-grid-group-hd div.x-grid-group-title {\r\n    background:transparent no-repeat 3px 3px;\r\n    padding:4px 4px 4px 17px;\r\n}\r\n\r\n.x-grid-group-collapsed .x-grid-group-body {\r\n    display:none;\r\n}\r\n\r\n.ext-ie6 .x-grid3 .x-editor .x-form-text, .ext-ie7 .x-grid3 .x-editor .x-form-text {\r\n    position:relative;\r\n    top:-1px;\r\n}\r\n\r\n.ext-ie .x-props-grid .x-editor .x-form-text {\r\n    position:static;\r\n    top:0;\r\n}\r\n\r\n.x-grid-empty {\r\n    padding:10px;\r\n}\r\n\r\n/* fix floating toolbar issue */\r\n.ext-ie7 .x-grid-panel .x-panel-bbar {\r\n    position:relative;\r\n}\r\n\r\n\r\n/* Reset position to static when Grid Panel has been framed */\r\n/* to resolve 'snapping' from top to bottom behavior. */\r\n/* @forumThread 86656 */\r\n.ext-ie7 .x-grid-panel .x-panel-mc .x-panel-bbar {\r\n    position: static;\r\n}\r\n\r\n\r\n.ext-ie6 .x-grid3-header {\r\n    position: relative;\r\n}\r\n\r\n/* column lines */\r\n.x-grid-with-col-lines .x-grid3-row td.x-grid3-cell {\r\n    padding-right:0;\r\n    border-right:1px solid;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 922 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(923);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 923 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-dd-drag-proxy{\r\n\tposition:absolute;\r\n\tleft:0;\r\n    top:0;\r\n\tvisibility:hidden;\r\n\tz-index:15000;\r\n}\r\n\r\n.x-dd-drag-ghost{\r\n\t-moz-opacity: 0.85;\r\n    opacity:.85;\r\n    filter: alpha(opacity=85);\r\n    border: 1px solid;\r\n\tpadding:3px;\r\n\tpadding-left:20px;\r\n\twhite-space:nowrap;\r\n}\r\n\r\n.x-dd-drag-repair .x-dd-drag-ghost{\r\n\t-moz-opacity: 0.4;\r\n    opacity:.4;\r\n    filter: alpha(opacity=40);\r\n\tborder:0 none;\r\n\tpadding:0;\r\n\tbackground-color:transparent;\r\n}\r\n\r\n.x-dd-drag-repair .x-dd-drop-icon{\r\n\tvisibility:hidden;\r\n}\r\n\r\n.x-dd-drop-icon{\r\n    position:absolute;\r\n\ttop:3px;\r\n\tleft:3px;\r\n\tdisplay:block;\r\n\twidth:16px;\r\n\theight:16px;\r\n\tbackground-color:transparent;\r\n\tbackground-position: center;\r\n\tbackground-repeat: no-repeat;\r\n\tz-index:1;\r\n}\r\n\r\n.x-view-selector {\r\n    position:absolute;\r\n    left:0;\r\n    top:0;\r\n    width:0;\r\n    border:1px dotted;\r\n\topacity: .5;\r\n    -moz-opacity: .5;\r\n    filter:alpha(opacity=50);\r\n    zoom:1;\r\n}", ""]);

// exports


/***/ }),
/* 924 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(925);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 925 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.ext-strict .ext-ie .x-tree .x-panel-bwrap{\r\n    position:relative;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-tree-icon, .x-tree-ec-icon, .x-tree-elbow-line, .x-tree-elbow, .x-tree-elbow-end, .x-tree-elbow-plus, .x-tree-elbow-minus, .x-tree-elbow-end-plus, .x-tree-elbow-end-minus{\r\n\tborder: 0 none;\r\n\theight: 18px;\r\n\tmargin: 0;\r\n\tpadding: 0;\r\n\tvertical-align: top;\r\n\twidth: 16px;\r\n    background-repeat: no-repeat;\r\n}\r\n\r\n.x-tree-node-collapsed .x-tree-node-icon, .x-tree-node-expanded .x-tree-node-icon, .x-tree-node-leaf .x-tree-node-icon{\r\n\tborder: 0 none;\r\n\theight: 18px;\r\n\tmargin: 0;\r\n\tpadding: 0;\r\n\tvertical-align: top;\r\n\twidth: 16px;\r\n\tbackground-position:center;\r\n    background-repeat: no-repeat;\r\n}\r\n\r\n.ext-ie .x-tree-node-indent img, .ext-ie .x-tree-node-icon, .ext-ie .x-tree-ec-icon {\r\n    vertical-align: middle !important;\r\n}\r\n\r\n.ext-strict .ext-ie8 .x-tree-node-indent img, .ext-strict .ext-ie8 .x-tree-node-icon, .ext-strict .ext-ie8 .x-tree-ec-icon {\r\n    vertical-align: top !important;\r\n}\r\n\r\n/* checkboxes */\r\n\r\ninput.x-tree-node-cb {\r\n    margin-left:1px;\r\n    height: 19px;\r\n\tvertical-align: bottom;\r\n}\r\n\r\n.ext-ie input.x-tree-node-cb {\r\n    margin-left:0;\r\n    margin-top: 1px;\r\n    width: 16px;\r\n    height: 16px;\r\n    vertical-align: middle;\r\n}\r\n\r\n.ext-strict .ext-ie8 input.x-tree-node-cb{\r\n    margin: 1px 1px;\r\n    height: 14px;\r\n    vertical-align: bottom;\r\n}\r\n\r\n.ext-strict .ext-ie8 input.x-tree-node-cb + a{\r\n    vertical-align: bottom;\r\n}\r\n\r\n.ext-opera input.x-tree-node-cb {\r\n    height: 14px;\r\n    vertical-align: middle;\r\n}\r\n\r\n.x-tree-noicon .x-tree-node-icon{\r\n\twidth:0; height:0;\r\n}\r\n\r\n/* No line styles */\r\n.x-tree-no-lines .x-tree-elbow{\r\n\tbackground:transparent;\r\n}\r\n\r\n.x-tree-no-lines .x-tree-elbow-end{\r\n\tbackground:transparent;\r\n}\r\n\r\n.x-tree-no-lines .x-tree-elbow-line{\r\n\tbackground:transparent;\r\n}\r\n\r\n/* Arrows */\r\n.x-tree-arrows .x-tree-elbow{\r\n\tbackground:transparent;\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-plus{\r\n    background:transparent no-repeat 0 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-minus{\r\n    background:transparent no-repeat -16px 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-end{\r\n\tbackground:transparent;\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-end-plus{\r\n    background:transparent no-repeat 0 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-end-minus{\r\n    background:transparent no-repeat -16px 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-line{\r\n\tbackground:transparent;\r\n}\r\n\r\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-plus{\r\n    background-position:-32px 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-minus{\r\n    background-position:-48px 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-end-plus{\r\n    background-position:-32px 0;\r\n}\r\n\r\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-end-minus{\r\n    background-position:-48px 0;\r\n}\r\n\r\n.x-tree-elbow-plus, .x-tree-elbow-minus, .x-tree-elbow-end-plus, .x-tree-elbow-end-minus{\r\n\tcursor:pointer;\r\n}\r\n\r\n.ext-ie ul.x-tree-node-ct{\r\n    font-size:0;\r\n    line-height:0;\r\n    zoom:1;\r\n}\r\n\r\n.x-tree-node{\r\n\twhite-space: nowrap;\r\n}\r\n\r\n.x-tree-node-el {\r\n    line-height:18px;\r\n    cursor:pointer;\r\n}\r\n\r\n.x-tree-node a, .x-dd-drag-ghost a{\r\n\ttext-decoration:none;\r\n\t-khtml-user-select:none;\r\n\t-moz-user-select:none;\r\n    -webkit-user-select:ignore;\r\n    -kthml-user-focus:normal;\r\n    -moz-user-focus:normal;\r\n    -moz-outline: 0 none;\r\n    outline:0 none;\r\n}\r\n\r\n.x-tree-node a span, .x-dd-drag-ghost a span{\r\n\ttext-decoration:none;\r\n\tpadding:1px 3px 1px 2px;\r\n}\r\n\r\n.x-tree-node .x-tree-node-disabled .x-tree-node-icon{\r\n\t-moz-opacity: 0.5;\r\n   opacity:.5;\r\n   filter: alpha(opacity=50);\r\n}\r\n\r\n.x-tree-node .x-tree-node-inline-icon{\r\n\tbackground:transparent;\r\n}\r\n\r\n.x-tree-node a:hover, .x-dd-drag-ghost a:hover{\r\n\ttext-decoration:none;\r\n}\r\n\r\n.x-tree-node div.x-tree-drag-insert-below{\r\n \t border-bottom:1px dotted;\r\n}\r\n\r\n.x-tree-node div.x-tree-drag-insert-above{\r\n\t border-top:1px dotted;\r\n}\r\n\r\n.x-tree-dd-underline .x-tree-node div.x-tree-drag-insert-below{\r\n \t border-bottom:0 none;\r\n}\r\n\r\n.x-tree-dd-underline .x-tree-node div.x-tree-drag-insert-above{\r\n\t border-top:0 none;\r\n}\r\n\r\n.x-tree-dd-underline .x-tree-node div.x-tree-drag-insert-below a{\r\n \t border-bottom:2px solid;\r\n}\r\n\r\n.x-tree-dd-underline .x-tree-node div.x-tree-drag-insert-above a{\r\n\t border-top:2px solid;\r\n}\r\n\r\n.x-tree-node .x-tree-drag-append a span{\r\n\t border:1px dotted;\r\n}\r\n\r\n.x-dd-drag-ghost .x-tree-node-indent, .x-dd-drag-ghost .x-tree-ec-icon{\r\n\tdisplay:none !important;\r\n}\r\n\r\n/* Fix for ie rootVisible:false issue */\r\n.x-tree-root-ct {\r\n    zoom:1;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 926 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(927);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 927 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-date-picker {\n    border: 1px solid;\n    border-top:0 none;\n\tposition:relative;\n}\n\n.x-date-picker a {\n    -moz-outline:0 none;\n    outline:0 none;\n}\n\n.x-date-inner, .x-date-inner td, .x-date-inner th{\n    border-collapse:separate;\n}\n\n.x-date-middle,.x-date-left,.x-date-right {\n\tbackground: repeat-x 0 -83px;\n\toverflow:hidden;\n}\n\n.x-date-middle .x-btn-tc,.x-date-middle .x-btn-tl,.x-date-middle .x-btn-tr,\n.x-date-middle .x-btn-mc,.x-date-middle .x-btn-ml,.x-date-middle .x-btn-mr,\n.x-date-middle .x-btn-bc,.x-date-middle .x-btn-bl,.x-date-middle .x-btn-br{\n\tbackground:transparent !important;\n    vertical-align:middle;\n}\n\n.x-date-middle .x-btn-mc em.x-btn-arrow {\n    background:transparent no-repeat right 0;\n}\n\n.x-date-right, .x-date-left {\n    width:18px;\n}\n\n.x-date-right{\n    text-align:right;\n}\n\n.x-date-middle {\n    padding-top:2px;\n    padding-bottom:2px;\n    width:130px; /* FF3 */\n}\n\n.x-date-right a, .x-date-left a{\n    display:block;\n    width:16px;\n\theight:16px;\n\tbackground-position: center;\n\tbackground-repeat: no-repeat;\n\tcursor:pointer;\n    -moz-opacity: 0.6;\n    opacity:.6;\n    filter: alpha(opacity=60);\n}\n\n.x-date-right a:hover, .x-date-left a:hover{\n    -moz-opacity: 1;\n    opacity:1;\n    filter: alpha(opacity=100);\n}\n\n.x-item-disabled .x-date-right a:hover, .x-item-disabled .x-date-left a:hover{\n    -moz-opacity: 0.6;\n    opacity:.6;\n    filter: alpha(opacity=60);\n}\n\n.x-date-right a {\n    margin-right:2px;\n    text-decoration:none !important;\n}\n\n.x-date-left a{\n    margin-left:2px;\n    text-decoration:none !important;\n}\n\ntable.x-date-inner {\n    width: 100%;\n    table-layout:fixed;\n}\n\n.ext-webkit table.x-date-inner{\n    /* Fix for webkit browsers */\n    width: 175px;\n}\n\n\n.x-date-inner th {\n    width:25px;\n}\n\n.x-date-inner th {\n    background: repeat-x left top;\n    text-align:right !important;\n\tborder-bottom: 1px solid;\n\tcursor:default;\n    padding:0;\n    border-collapse:separate;\n}\n\n.x-date-inner th span {\n    display:block;\n    padding:2px;\n    padding-right:7px;\n}\n\n.x-date-inner td {\n    border: 1px solid;\n\ttext-align:right;\n    padding:0;\n}\n\n.x-date-inner a {\n    padding:2px 5px;\n    display:block;\n\ttext-decoration:none;\n    text-align:right;\n    zoom:1;\n}\n\n.x-date-inner .x-date-active{\n\tcursor:pointer;\n\tcolor:black;\n}\n\n.x-date-inner .x-date-selected a{\n\tbackground: repeat-x left top;\n\tborder:1px solid;\n    padding:1px 4px;\n}\n\n.x-date-inner .x-date-today a{\n\tborder: 1px solid;\n    padding:1px 4px;\n}\n\n.x-date-inner .x-date-prevday a,.x-date-inner .x-date-nextday a {\n    text-decoration:none !important;\n}\n\n.x-date-bottom {\n    padding:4px;\n    border-top: 1px solid;\n    background: repeat-x left top;\n}\n\n.x-date-inner a:hover, .x-date-inner .x-date-disabled a:hover{\n    text-decoration:none !important;\n}\n\n.x-item-disabled .x-date-inner a:hover{\n    background: none;\n}\n\n.x-date-inner .x-date-disabled a {\n\tcursor:default;\n}\n\n.x-date-menu .x-menu-item {\n\tpadding:1px 24px 1px 4px;\n\twhite-space: nowrap;\n}\n\n.x-date-menu .x-menu-item .x-menu-item-icon {\n    width:10px;\n    height:10px;\n    margin-right:5px;\n    background-position:center -4px !important;\n}\n\n.x-date-mp {\n\tposition:absolute;\n\tleft:0;\n\ttop:0;\n\tdisplay:none;\n}\n\n.x-date-mp td {\n    padding:2px;\n\tfont:normal 11px arial, helvetica,tahoma,sans-serif;\n}\n\ntd.x-date-mp-month,td.x-date-mp-year,td.x-date-mp-ybtn {\n    border: 0 none;\n\ttext-align:center;\n\tvertical-align: middle;\n\twidth:25%;\n}\n\n.x-date-mp-ok {\n\tmargin-right:3px;\n}\n\n.x-date-mp-btns button {\n\ttext-decoration:none;\n\ttext-align:center;\n\ttext-decoration:none !important;\n\tborder:1px solid;\n\tpadding:1px 3px 1px;\n\tcursor:pointer;\n}\n\n.x-date-mp-btns {\n\tbackground: repeat-x left top;\n}\n\n.x-date-mp-btns td {\n\tborder-top: 1px solid;\n    text-align:center;\n}\n\ntd.x-date-mp-month a,td.x-date-mp-year a {\n\tdisplay:block;\n\tpadding:2px 4px;\n\ttext-decoration:none;\n\ttext-align:center;\n}\n\ntd.x-date-mp-month a:hover,td.x-date-mp-year a:hover {\n\ttext-decoration:none;\n\tcursor:pointer;\n}\n\ntd.x-date-mp-sel a {\n\tpadding:1px 3px;\n\tbackground: repeat-x left top;\n\tborder:1px solid;\n}\n\n.x-date-mp-ybtn a {\n    overflow:hidden;\n    width:15px;\n    height:15px;\n    cursor:pointer;\n    background:transparent no-repeat;\n    display:block;\n    margin:0 auto;\n}\n\n.x-date-mp-ybtn a.x-date-mp-next {\n    background-position:0 -120px;\n}\n\n.x-date-mp-ybtn a.x-date-mp-next:hover {\n    background-position:-15px -120px;\n}\n\n.x-date-mp-ybtn a.x-date-mp-prev {\n    background-position:0 -105px;\n}\n\n.x-date-mp-ybtn a.x-date-mp-prev:hover {\n    background-position:-15px -105px;\n}\n\n.x-date-mp-ybtn {\n   text-align:center;\n}\n\ntd.x-date-mp-sep {\n   border-right:1px solid;\n}", ""]);

// exports


/***/ }),
/* 928 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(929);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 929 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-tip{\r\n\tposition: absolute;\r\n\ttop: 0;\r\n    left:0;\r\n    visibility: hidden;\r\n\tz-index: 20002;\r\n    border:0 none;\r\n}\r\n\r\n.x-tip .x-tip-close{\r\n\theight: 15px;\r\n\tfloat:right;\r\n\twidth: 15px;\r\n    margin:0 0 2px 2px;\r\n    cursor:pointer;\r\n    display:none;\r\n}\r\n\r\n.x-tip .x-tip-tc {\r\n\tbackground: transparent no-repeat 0 -62px;\r\n\tpadding-top:3px;\r\n    overflow:hidden;\r\n    zoom:1;\r\n}\r\n\r\n.x-tip .x-tip-tl {\r\n\tbackground: transparent no-repeat 0 0;\r\n\tpadding-left:6px;\r\n    overflow:hidden;\r\n    zoom:1;\r\n}\r\n\r\n.x-tip .x-tip-tr {\r\n\tbackground: transparent no-repeat right 0;\r\n\tpadding-right:6px;\r\n    overflow:hidden;\r\n    zoom:1;\r\n}\r\n\r\n.x-tip .x-tip-bc {\r\n\tbackground: transparent no-repeat 0 -121px;\r\n\theight:3px;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-tip .x-tip-bl {\r\n\tbackground: transparent no-repeat 0 -59px;\r\n\tpadding-left:6px;\r\n    zoom:1;\r\n}\r\n\r\n.x-tip .x-tip-br {\r\n\tbackground: transparent no-repeat right -59px;\r\n\tpadding-right:6px;\r\n    zoom:1;\r\n}\r\n\r\n.x-tip .x-tip-mc {\r\n    border:0 none;\r\n}\r\n\r\n.x-tip .x-tip-ml {\r\n\tbackground: no-repeat 0 -124px;\r\n\tpadding-left:6px;\r\n    zoom:1;\r\n}\r\n\r\n.x-tip .x-tip-mr {\r\n\tbackground: transparent no-repeat right -124px;\r\n\tpadding-right:6px;\r\n    zoom:1;\r\n}\r\n\r\n.ext-ie .x-tip .x-tip-header,.ext-ie .x-tip .x-tip-tc {\r\n    font-size:0;\r\n    line-height:0;\r\n}\r\n\r\n.ext-border-box .x-tip .x-tip-header, .ext-border-box .x-tip .x-tip-tc{\r\n    line-height: 1px;\r\n}\r\n\r\n.x-tip .x-tip-header-text {\r\n    padding:0;\r\n    margin:0 0 2px 0;\r\n}\r\n\r\n.x-tip .x-tip-body {\r\n    margin:0 !important;\r\n    line-height:14px;\r\n    padding:0;\r\n}\r\n\r\n.x-tip .x-tip-body .loading-indicator {\r\n    margin:0;\r\n}\r\n\r\n.x-tip-draggable .x-tip-header,.x-tip-draggable .x-tip-header-text {\r\n    cursor:move;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-tc {\r\n\tbackground: repeat-x 0 -12px;\r\n    padding-top:6px;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-bc {\r\n\tbackground: repeat-x 0 -18px;\r\n    height:6px;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-bl {\r\n\tbackground: no-repeat 0 -6px;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-br {\r\n\tbackground: no-repeat right -6px;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-body {\r\n    padding:2px;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-body {\r\n    padding-left:24px;\r\n    background:transparent no-repeat 2px 2px;\r\n}\r\n\r\n.x-tip-anchor {\r\n    position: absolute;\r\n    width: 9px;\r\n    height: 10px;\r\n    overflow:hidden;\r\n    background: transparent no-repeat 0 0;\r\n    zoom:1;\r\n}\r\n.x-tip-anchor-bottom {\r\n    background-position: -9px 0;\r\n}\r\n.x-tip-anchor-right {\r\n    background-position: -18px 0;\r\n    width: 10px;\r\n}\r\n.x-tip-anchor-left {\r\n    background-position: -28px 0;\r\n    width: 10px;\r\n}", ""]);

// exports


/***/ }),
/* 930 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(931);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 931 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-menu {\r\n\tz-index: 15000;\r\n\tzoom: 1;\r\n\tbackground: repeat-y;\r\n}\r\n\r\n.x-menu-floating{\r\n    border: 1px solid;\r\n}\r\n\r\n.x-menu a {\r\n    text-decoration: none !important;\r\n}\r\n\r\n.ext-ie .x-menu {\r\n    zoom:1;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-menu-list{\r\n    padding: 2px;\r\n\tbackground:transparent;\r\n\tborder:0 none;\r\n    overflow:hidden;\r\n    overflow-y: hidden;\r\n}\r\n\r\n.ext-strict .ext-ie .x-menu-list{\r\n    position: relative;\r\n}\r\n\r\n.x-menu li{\r\n\tline-height:100%;\r\n}\r\n\r\n.x-menu li.x-menu-sep-li{\r\n\tfont-size:1px;\r\n\tline-height:1px;\r\n}\r\n\r\n.x-menu-list-item{\r\n    white-space: nowrap;\r\n\tdisplay:block;\r\n\tpadding:1px;\r\n}\r\n\r\n.x-menu-item{\r\n    -moz-user-select: none;\r\n    -khtml-user-select:none;\r\n    -webkit-user-select:ignore;\r\n}\r\n\r\n.x-menu-item-arrow{\r\n\tbackground:transparent no-repeat right;\r\n}\r\n\r\n.x-menu-sep {\r\n\tdisplay:block;\r\n\tfont-size:1px;\r\n\tline-height:1px;\r\n\tmargin: 2px 3px;\r\n\tborder-bottom:1px solid;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-menu-focus {\r\n\tposition:absolute;\r\n\tleft:-1px;\r\n\ttop:-1px;\r\n\twidth:1px;\r\n\theight:1px;\r\n    line-height:1px;\r\n    font-size:1px;\r\n    -moz-outline:0 none;\r\n    outline:0 none;\r\n    -moz-user-select: none;\r\n    -khtml-user-select:none;\r\n    -webkit-user-select:ignore;\r\n    overflow:hidden;\r\n    display:block;\r\n}\r\n\r\na.x-menu-item {\r\n    cursor: pointer;\r\n    display: block;\r\n    line-height: 16px;\r\n    outline-color: -moz-use-text-color;\r\n    outline-style: none;\r\n    outline-width: 0;\r\n    padding: 3px 21px 3px 27px;\r\n    position: relative;\r\n    text-decoration: none;\r\n    white-space: nowrap;\r\n}\r\n\r\n.x-menu-item-active {\r\n    background-repeat: repeat-x;\r\n    background-position: left bottom;\r\n    border-style:solid;\r\n    border-width: 1px 0;\r\n    margin:0 1px;\r\n\tpadding: 0;\r\n}\r\n\r\n.x-menu-item-active a.x-menu-item {\r\n    border-style:solid;\r\n    border-width:0 1px;\r\n    margin:0 -1px;\r\n}\r\n\r\n.x-menu-item-icon {\r\n\tborder: 0 none;\r\n\theight: 16px;\r\n\tpadding: 0;\r\n\tvertical-align: top;\r\n\twidth: 16px;\r\n\tposition: absolute;\r\n    left: 3px;\r\n    top: 3px;\r\n    margin: 0;\r\n    background-position:center;\r\n}\r\n\r\n.ext-ie .x-menu-item-icon {\r\n    left: -24px;\r\n}\r\n.ext-strict .x-menu-item-icon {\r\n    left: 3px;\r\n}\r\n\r\n.ext-ie6 .x-menu-item-icon {\r\n    left: -24px;\r\n}\r\n\r\n.ext-ie .x-menu-item-icon {\r\n    vertical-align: middle;\r\n}\r\n\r\n.x-menu-check-item .x-menu-item-icon{\r\n\tbackground: transparent no-repeat center;\r\n}\r\n\r\n.x-menu-group-item .x-menu-item-icon{\r\n\tbackground: transparent;\r\n}\r\n\r\n.x-menu-item-checked .x-menu-group-item .x-menu-item-icon{\r\n    background: transparent no-repeat center;\r\n}\r\n\r\n.x-date-menu .x-menu-list{\r\n    padding: 0;\r\n}\r\n\r\n.x-menu-date-item{\r\n\tpadding:0;\r\n}\r\n\r\n.x-menu .x-color-palette, .x-menu .x-date-picker{\r\n    margin-left: 26px;\r\n\tmargin-right:4px;\r\n}\r\n\r\n.x-menu .x-date-picker{\r\n    border:1px solid;\r\n    margin-top:2px;\r\n    margin-bottom:2px;\r\n}\r\n\r\n.x-menu-plain .x-color-palette, .x-menu-plain .x-date-picker{\r\n\t margin: 0;\r\n\t border: 0 none;\r\n}\r\n\r\n.x-date-menu {\r\n   padding:0 !important;\r\n}\r\n\r\n/*\r\n * fixes separator visibility problem in IE 6\r\n */\r\n.ext-strict .ext-ie6 .x-menu-sep-li {\r\n    padding: 3px 4px;\r\n}\r\n.ext-strict .ext-ie6 .x-menu-sep {\r\n    margin: 0;\r\n    height: 1px;\r\n}\r\n\r\n/*\r\n * Ugly mess to remove the white border under the picker\r\n */\r\n.ext-ie .x-date-menu{\r\n    height: 199px;\r\n}\r\n\r\n.ext-strict .ext-ie .x-date-menu, .ext-border-box .ext-ie8 .x-date-menu{\r\n    height: 197px;\r\n}\r\n\r\n.ext-strict .ext-ie7 .x-date-menu{\r\n    height: 195px;\r\n}\r\n\r\n.ext-strict .ext-ie8 .x-date-menu{\r\n    height: auto;\r\n}\r\n\r\n.x-cycle-menu .x-menu-item-checked {\r\n    border:1px dotted !important;\r\n\tpadding:0;\r\n}\r\n\r\n.x-menu .x-menu-scroller {\r\n    width: 100%;\r\n\tbackground-repeat:no-repeat;\r\n\tbackground-position:center;\r\n\theight:8px;\r\n    line-height: 8px;\r\n\tcursor:pointer;\r\n    margin: 0;\r\n    padding: 0;\r\n}\r\n\r\n.x-menu .x-menu-scroller-active{\r\n    height: 6px;\r\n    line-height: 6px;\r\n}\r\n\r\n.x-menu-list-item-indent{\r\n    padding-left: 27px;\r\n}", ""]);

// exports


/***/ }),
/* 932 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(933);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 933 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n/*\n Creates rounded, raised boxes like on the Ext website - the markup isn't pretty:\n  <div class=\"x-box-blue\">\n        <div class=\"x-box-tl\"><div class=\"x-box-tr\"><div class=\"x-box-tc\"></div></div></div>\n        <div class=\"x-box-ml\"><div class=\"x-box-mr\"><div class=\"x-box-mc\">\n            <h3>YOUR TITLE HERE (optional)</h3>\n            <div>YOUR CONTENT HERE</div>\n        </div></div></div>\n        <div class=\"x-box-bl\"><div class=\"x-box-br\"><div class=\"x-box-bc\"></div></div></div>\n    </div>\n */\n\n.x-box-tl {\n\tbackground: transparent no-repeat 0 0;\n    zoom:1;\n}\n\n.x-box-tc {\n\theight: 8px;\n\tbackground: transparent repeat-x 0 0;\n\toverflow: hidden;\n}\n\n.x-box-tr {\n\tbackground: transparent no-repeat right -8px;\n}\n\n.x-box-ml {\n\tbackground: transparent repeat-y 0;\n\tpadding-left: 4px;\n\toverflow: hidden;\n    zoom:1;\n}\n\n.x-box-mc {\n\tbackground: repeat-x 0 -16px;\n\tpadding: 4px 10px;\n}\n\n.x-box-mc h3 {\n\tmargin: 0 0 4px 0;\n    zoom:1;\n}\n\n.x-box-mr {\n\tbackground: transparent repeat-y right;\n\tpadding-right: 4px;\n\toverflow: hidden;\n}\n\n.x-box-bl {\n\tbackground: transparent no-repeat 0 -16px;\n    zoom:1;\n}\n\n.x-box-bc {\n\tbackground: transparent repeat-x 0 -8px;\n\theight: 8px;\n\toverflow: hidden;\n}\n\n.x-box-br {\n\tbackground: transparent no-repeat right -24px;\n}\n\n.x-box-tl, .x-box-bl {\n\tpadding-left: 8px;\n\toverflow: hidden;\n}\n\n.x-box-tr, .x-box-br {\n\tpadding-right: 8px;\n\toverflow: hidden;\n}", ""]);

// exports


/***/ }),
/* 934 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(935);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 935 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-combo-list {\n    border:1px solid;\n    zoom:1;\n    overflow:hidden;\n}\n\n.x-combo-list-inner {\n    overflow:auto;\n    position:relative; /* for calculating scroll offsets */\n    zoom:1;\n    overflow-x:hidden;\n}\n\n.x-combo-list-hd {\n    border-bottom:1px solid;\n    padding:3px;\n}\n\n.x-resizable-pinned .x-combo-list-inner {\n    border-bottom:1px solid;\n}\n\n.x-combo-list-item {\n    padding:2px;\n    border:1px solid;\n    white-space: nowrap;\n    overflow:hidden;\n    text-overflow: ellipsis;\n}\n\n.x-combo-list .x-combo-selected{\n\tborder:1px dotted !important;\n    cursor:pointer;\n}\n\n.x-combo-list .x-toolbar {\n    border-top:1px solid;\n    border-bottom:0 none;\n}", ""]);

// exports


/***/ }),
/* 936 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(937);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 937 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-panel {\n    border-style: solid;\n    border-width:0;\n}\n\n.x-panel-header {\n    overflow:hidden;\n    zoom:1;\n    padding:5px 3px 4px 5px;\n    border:1px solid;\n    line-height: 15px;\n    background: transparent repeat-x 0 -1px;\n}\n\n.x-panel-body {\n    border:1px solid;\n    border-top:0 none;\n    overflow:hidden;\n    position: relative; /* added for item scroll positioning */\n}\n\n.x-panel-bbar .x-toolbar, .x-panel-tbar .x-toolbar {\n    border:1px solid;\n    border-top:0 none;\n    overflow:hidden;\n    padding:2px;\n}\n\n.x-panel-tbar-noheader .x-toolbar, .x-panel-mc .x-panel-tbar .x-toolbar {\n    border-top:1px solid;\n    border-bottom: 0 none;\n}\n\n.x-panel-body-noheader, .x-panel-mc .x-panel-body {\n    border-top:1px solid;\n}\n\n.x-panel-header {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-panel-tl .x-panel-header {\n    padding:5px 0 4px 0;\n    border:0 none;\n    background:transparent;\n}\n\n.x-panel-tl .x-panel-icon, .x-window-tl .x-panel-icon {\n    padding-left:20px !important;\n    background-repeat:no-repeat;\n    background-position:0 4px;\n    zoom:1;\n}\n\n.x-panel-inline-icon {\n    width:16px;\n\theight:16px;\n    background-repeat:no-repeat;\n    background-position:0 0;\n\tvertical-align:middle;\n\tmargin-right:4px;\n\tmargin-top:-1px;\n\tmargin-bottom:-1px;\n}\n\n.x-panel-tc {\n\tbackground: transparent repeat-x 0 0;\n\toverflow:hidden;\n}\n\n/* fix ie7 strict mode bug */\n.ext-strict .ext-ie7 .x-panel-tc {\n    overflow: visible;\n}\n\n.x-panel-tl {\n\tbackground: transparent no-repeat 0 0;\n\tpadding-left:6px;\n    zoom:1;\n    border-bottom:1px solid;\n}\n\n.x-panel-tr {\n\tbackground: transparent no-repeat right 0;\n\tzoom:1;\n    padding-right:6px;\n}\n\n.x-panel-bc {\n\tbackground: transparent repeat-x 0 bottom;\n    zoom:1;\n}\n\n.x-panel-bc .x-panel-footer {\n    zoom:1;\n}\n\n.x-panel-bl {\n\tbackground: transparent no-repeat 0 bottom;\n\tpadding-left:6px;\n    zoom:1;\n}\n\n.x-panel-br {\n\tbackground: transparent no-repeat right bottom;\n\tpadding-right:6px;\n    zoom:1;\n}\n\n.x-panel-mc {\n    border:0 none;\n    padding:0;\n    margin:0;\n    padding-top:6px;\n}\n\n.x-panel-mc .x-panel-body {\n    background:transparent;\n    border: 0 none;\n}\n\n.x-panel-ml {\n\tbackground: repeat-y 0 0;\n\tpadding-left:6px;\n    zoom:1;\n}\n\n.x-panel-mr {\n\tbackground: transparent repeat-y right 0;\n\tpadding-right:6px;\n    zoom:1;\n}\n\n.x-panel-bc .x-panel-footer {\n    padding-bottom:6px;\n}\n\n.x-panel-nofooter .x-panel-bc, .x-panel-nofooter .x-window-bc {\n\theight:6px;\n    font-size:0;\n    line-height:0;\n}\n\n.x-panel-bwrap {\n    overflow:hidden;\n    zoom:1;\n    left:0;\n    top:0;\n}\n.x-panel-body {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-panel-collapsed .x-resizable-handle{\n    display:none;\n}\n\n.ext-gecko .x-panel-animated div {\n    overflow:hidden !important;\n}\n\n/* Plain */\n.x-plain-body {\n    overflow:hidden;\n}\n\n.x-plain-bbar .x-toolbar {\n    overflow:hidden;\n    padding:2px;\n}\n\n.x-plain-tbar .x-toolbar {\n    overflow:hidden;\n    padding:2px;\n}\n\n.x-plain-bwrap {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-plain {\n    overflow:hidden;\n}\n\n/* Tools */\n.x-tool {\n    overflow:hidden;\n    width:15px;\n    height:15px;\n    float:right;\n    cursor:pointer;\n    background:transparent no-repeat;\n    margin-left:2px;\n}\n\n/* expand / collapse tools */\n.x-tool-toggle {\n    background-position:0 -60px;\n}\n\n.x-tool-toggle-over {\n    background-position:-15px -60px;\n}\n\n.x-panel-collapsed .x-tool-toggle {\n    background-position:0 -75px;\n}\n\n.x-panel-collapsed .x-tool-toggle-over {\n    background-position:-15px -75px;\n}\n\n\n.x-tool-close {\n    background-position:0 -0;\n}\n\n.x-tool-close-over {\n    background-position:-15px 0;\n}\n\n.x-tool-minimize {\n    background-position:0 -15px;\n}\n\n.x-tool-minimize-over {\n    background-position:-15px -15px;\n}\n\n.x-tool-maximize {\n    background-position:0 -30px;\n}\n\n.x-tool-maximize-over {\n    background-position:-15px -30px;\n}\n\n.x-tool-restore {\n    background-position:0 -45px;\n}\n\n.x-tool-restore-over {\n    background-position:-15px -45px;\n}\n\n.x-tool-gear {\n    background-position:0 -90px;\n}\n\n.x-tool-gear-over {\n    background-position:-15px -90px;\n}\n\n.x-tool-pin {\n    background-position:0 -135px;\n}\n\n.x-tool-pin-over {\n    background-position:-15px -135px;\n}\n\n.x-tool-unpin {\n    background-position:0 -150px;\n}\n\n.x-tool-unpin-over {\n    background-position:-15px -150px;\n}\n\n.x-tool-right {\n    background-position:0 -165px;\n}\n\n.x-tool-right-over {\n    background-position:-15px -165px;\n}\n\n.x-tool-left {\n    background-position:0 -180px;\n}\n\n.x-tool-left-over {\n    background-position:-15px -180px;\n}\n\n.x-tool-up {\n    background-position:0 -210px;\n}\n\n.x-tool-up-over {\n    background-position:-15px -210px;\n}\n\n.x-tool-down {\n    background-position:0 -195px;\n}\n\n.x-tool-down-over {\n    background-position:-15px -195px;\n}\n\n.x-tool-refresh {\n    background-position:0 -225px;\n}\n\n.x-tool-refresh-over {\n    background-position:-15px -225px;\n}\n\n.x-tool-minus {\n    background-position:0 -255px;\n}\n\n.x-tool-minus-over {\n    background-position:-15px -255px;\n}\n\n.x-tool-plus {\n    background-position:0 -240px;\n}\n\n.x-tool-plus-over {\n    background-position:-15px -240px;\n}\n\n.x-tool-search {\n    background-position:0 -270px;\n}\n\n.x-tool-search-over {\n    background-position:-15px -270px;\n}\n\n.x-tool-save {\n    background-position:0 -285px;\n}\n\n.x-tool-save-over {\n    background-position:-15px -285px;\n}\n\n.x-tool-help {\n    background-position:0 -300px;\n}\n\n.x-tool-help-over {\n    background-position:-15px -300px;\n}\n\n.x-tool-print {\n    background-position:0 -315px;\n}\n\n.x-tool-print-over {\n    background-position:-15px -315px;\n}\n\n/* Ghosting */\n.x-panel-ghost {\n    z-index:12000;\n    overflow:hidden;\n    position:absolute;\n    left:0;top:0;\n    opacity:.65;\n    -moz-opacity:.65;\n    filter:alpha(opacity=65);\n}\n\n.x-panel-ghost ul {\n    margin:0;\n    padding:0;\n    overflow:hidden;\n    font-size:0;\n    line-height:0;\n    border:1px solid;\n    border-top:0 none;\n    display:block;\n}\n\n.x-panel-ghost * {\n    cursor:move !important;\n}\n\n.x-panel-dd-spacer {\n    border:2px dashed;\n}\n\n/* Buttons */\n.x-panel-btns {\n    padding:5px;\n    overflow:hidden;\n}\n\n.x-panel-btns td.x-toolbar-cell{\n\tpadding:3px;\n}\n\n.x-panel-btns .x-btn-focus .x-btn-left{\n\tbackground-position:0 -147px;\n}\n\n.x-panel-btns .x-btn-focus .x-btn-right{\n\tbackground-position:0 -168px;\n}\n\n.x-panel-btns .x-btn-focus .x-btn-center{\n\tbackground-position:0 -189px;\n}\n\n.x-panel-btns .x-btn-over .x-btn-left{\n\tbackground-position:0 -63px;\n}\n\n.x-panel-btns .x-btn-over .x-btn-right{\n\tbackground-position:0 -84px;\n}\n\n.x-panel-btns .x-btn-over .x-btn-center{\n\tbackground-position:0 -105px;\n}\n\n.x-panel-btns .x-btn-click .x-btn-center{\n\tbackground-position:0 -126px;\n}\n\n.x-panel-btns .x-btn-click  .x-btn-right{\n\tbackground-position:0 -84px;\n}\n\n.x-panel-btns .x-btn-click .x-btn-left{\n\tbackground-position:0 -63px;\n}\n\n.x-panel-fbar td,.x-panel-fbar span,.x-panel-fbar input,.x-panel-fbar div,.x-panel-fbar select,.x-panel-fbar label{\n\twhite-space: nowrap;\n}\n", ""]);

// exports


/***/ }),
/* 938 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(939);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 939 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n/**\n * W3C Suggested Default style sheet for HTML 4\n * http://www.w3.org/TR/CSS21/sample.html\n *\n * Resets for Ext.Panel @cfg normal: true\n */\n.x-panel-reset .x-panel-body html,\n.x-panel-reset .x-panel-body address,\n.x-panel-reset .x-panel-body blockquote,\n.x-panel-reset .x-panel-body body,\n.x-panel-reset .x-panel-body dd,\n.x-panel-reset .x-panel-body div,\n.x-panel-reset .x-panel-body dl,\n.x-panel-reset .x-panel-body dt,\n.x-panel-reset .x-panel-body fieldset,\n.x-panel-reset .x-panel-body form,\n.x-panel-reset .x-panel-body frame, frameset,\n.x-panel-reset .x-panel-body h1,\n.x-panel-reset .x-panel-body h2,\n.x-panel-reset .x-panel-body h3,\n.x-panel-reset .x-panel-body h4,\n.x-panel-reset .x-panel-body h5,\n.x-panel-reset .x-panel-body h6,\n.x-panel-reset .x-panel-body noframes,\n.x-panel-reset .x-panel-body ol,\n.x-panel-reset .x-panel-body p,\n.x-panel-reset .x-panel-body ul,\n.x-panel-reset .x-panel-body center,\n.x-panel-reset .x-panel-body dir,\n.x-panel-reset .x-panel-body hr,\n.x-panel-reset .x-panel-body menu,\n.x-panel-reset .x-panel-body pre \t\t\t  { display: block }\n.x-panel-reset .x-panel-body li              { display: list-item }\n.x-panel-reset .x-panel-body head            { display: none }\n.x-panel-reset .x-panel-body table           { display: table }\n.x-panel-reset .x-panel-body tr              { display: table-row }\n.x-panel-reset .x-panel-body thead           { display: table-header-group }\n.x-panel-reset .x-panel-body tbody           { display: table-row-group }\n.x-panel-reset .x-panel-body tfoot           { display: table-footer-group }\n.x-panel-reset .x-panel-body col             { display: table-column }\n.x-panel-reset .x-panel-body colgroup        { display: table-column-group }\n.x-panel-reset .x-panel-body td,\n.x-panel-reset .x-panel-body th \t          { display: table-cell }\n.x-panel-reset .x-panel-body caption         { display: table-caption }\n.x-panel-reset .x-panel-body th              { font-weight: bolder; text-align: center }\n.x-panel-reset .x-panel-body caption         { text-align: center }\n.x-panel-reset .x-panel-body body            { margin: 8px }\n.x-panel-reset .x-panel-body h1              { font-size: 2em; margin: .67em 0 }\n.x-panel-reset .x-panel-body h2              { font-size: 1.5em; margin: .75em 0 }\n.x-panel-reset .x-panel-body h3              { font-size: 1.17em; margin: .83em 0 }\n.x-panel-reset .x-panel-body h4,\n.x-panel-reset .x-panel-body p,\n.x-panel-reset .x-panel-body blockquote,\n.x-panel-reset .x-panel-body ul,\n.x-panel-reset .x-panel-body fieldset,\n.x-panel-reset .x-panel-body form,\n.x-panel-reset .x-panel-body ol,\n.x-panel-reset .x-panel-body dl,\n.x-panel-reset .x-panel-body dir,\n.x-panel-reset .x-panel-body menu            { margin: 1.12em 0 }\n.x-panel-reset .x-panel-body h5              { font-size: .83em; margin: 1.5em 0 }\n.x-panel-reset .x-panel-body h6              { font-size: .75em; margin: 1.67em 0 }\n.x-panel-reset .x-panel-body h1,\n.x-panel-reset .x-panel-body h2,\n.x-panel-reset .x-panel-body h3,\n.x-panel-reset .x-panel-body h4,\n.x-panel-reset .x-panel-body h5,\n.x-panel-reset .x-panel-body h6,\n.x-panel-reset .x-panel-body b,\n.x-panel-reset .x-panel-body strong          { font-weight: bolder }\n.x-panel-reset .x-panel-body blockquote      { margin-left: 40px; margin-right: 40px }\n.x-panel-reset .x-panel-body i,\n.x-panel-reset .x-panel-body cite,\n.x-panel-reset .x-panel-body em,\n.x-panel-reset .x-panel-body var,\n.x-panel-reset .x-panel-body address    \t  { font-style: italic }\n.x-panel-reset .x-panel-body pre,\n.x-panel-reset .x-panel-body tt,\n.x-panel-reset .x-panel-body code,\n.x-panel-reset .x-panel-body kbd,\n.x-panel-reset .x-panel-body samp       \t  { font-family: monospace }\n.x-panel-reset .x-panel-body pre             { white-space: pre }\n.x-panel-reset .x-panel-body button,\n.x-panel-reset .x-panel-body textarea,\n.x-panel-reset .x-panel-body input,\n.x-panel-reset .x-panel-body select   \t\t  { display: inline-block }\n.x-panel-reset .x-panel-body big             { font-size: 1.17em }\n.x-panel-reset .x-panel-body small,\n.x-panel-reset .x-panel-body sub,\n.x-panel-reset .x-panel-body sup \t\t\t  { font-size: .83em }\n.x-panel-reset .x-panel-body sub             { vertical-align: sub }\n.x-panel-reset .x-panel-body sup             { vertical-align: super }\n.x-panel-reset .x-panel-body table           { border-spacing: 2px; }\n.x-panel-reset .x-panel-body thead,\n.x-panel-reset .x-panel-body tbody,\n.x-panel-reset .x-panel-body tfoot           { vertical-align: middle }\n.x-panel-reset .x-panel-body td,\n.x-panel-reset .x-panel-body th          \t  { vertical-align: inherit }\n.x-panel-reset .x-panel-body s,\n.x-panel-reset .x-panel-body strike,\n.x-panel-reset .x-panel-body del  \t\t\t  { text-decoration: line-through }\n.x-panel-reset .x-panel-body hr              { border: 1px inset }\n.x-panel-reset .x-panel-body ol,\n.x-panel-reset .x-panel-body ul,\n.x-panel-reset .x-panel-body dir,\n.x-panel-reset .x-panel-body menu,\n.x-panel-reset .x-panel-body dd        \t  { margin-left: 40px }\n.x-panel-reset .x-panel-body ul, .x-panel-reset .x-panel-body menu, .x-panel-reset .x-panel-body dir { list-style-type: disc;}\n.x-panel-reset .x-panel-body ol              { list-style-type: decimal }\n.x-panel-reset .x-panel-body ol ul,\n.x-panel-reset .x-panel-body ul ol,\n.x-panel-reset .x-panel-body ul ul,\n.x-panel-reset .x-panel-body ol ol    \t\t  { margin-top: 0; margin-bottom: 0 }\n.x-panel-reset .x-panel-body u,\n.x-panel-reset .x-panel-body ins          \t  { text-decoration: underline }\n.x-panel-reset .x-panel-body br:before       { content: \"\\A\" }\n.x-panel-reset .x-panel-body :before, .x-panel-reset .x-panel-body :after { white-space: pre-line }\n.x-panel-reset .x-panel-body center          { text-align: center }\n.x-panel-reset .x-panel-body :link, .x-panel-reset .x-panel-body :visited { text-decoration: underline }\n.x-panel-reset .x-panel-body :focus          { outline: thin dotted invert }\n\n/* Begin bidirectionality settings (do not change) */\n.x-panel-reset .x-panel-body BDO[DIR=\"ltr\"]  { direction: ltr; unicode-bidi: bidi-override }\n.x-panel-reset .x-panel-body BDO[DIR=\"rtl\"]  { direction: rtl; unicode-bidi: bidi-override }\n", ""]);

// exports


/***/ }),
/* 940 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(941);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 941 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-window {\n    zoom:1;\n}\n\n.x-window .x-window-handle {\n    opacity:0;\n    -moz-opacity:0;\n    filter:alpha(opacity=0);\n}\n\n.x-window-proxy {\n    border:1px solid;\n    z-index:12000;\n    overflow:hidden;\n    position:absolute;\n    left:0;top:0;\n    display:none;\n    opacity:.5;\n    -moz-opacity:.5;\n    filter:alpha(opacity=50);\n}\n\n.x-window-header {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-window-bwrap {\n    z-index:1;\n    position:relative;\n    zoom:1;\n    left:0;top:0;\n}\n\n.x-window-tl .x-window-header {\n    padding:5px 0 4px 0;\n}\n\n.x-window-header-text {\n    cursor:pointer;\n}\n\n.x-window-tc {\n\tbackground: transparent repeat-x 0 0;\n\toverflow:hidden;\n    zoom:1;\n}\n\n.x-window-tl {\n\tbackground: transparent no-repeat 0 0;\n\tpadding-left:6px;\n    zoom:1;\n    z-index:1;\n    position:relative;\n}\n\n.x-window-tr {\n\tbackground: transparent no-repeat right 0;\n\tpadding-right:6px;\n}\n\n.x-window-bc {\n\tbackground: transparent repeat-x 0 bottom;\n    zoom:1;\n}\n\n.x-window-bc .x-window-footer {\n    padding-bottom:6px;\n    zoom:1;\n    font-size:0;\n    line-height:0;\n}\n\n.x-window-bl {\n\tbackground: transparent no-repeat 0 bottom;\n\tpadding-left:6px;\n    zoom:1;\n}\n\n.x-window-br {\n\tbackground: transparent no-repeat right bottom;\n\tpadding-right:6px;\n    zoom:1;\n}\n\n.x-window-mc {\n    border:1px solid;\n    padding:0;\n    margin:0;\n}\n\n.x-window-ml {\n\tbackground: transparent repeat-y 0 0;\n\tpadding-left:6px;\n    zoom:1;\n}\n\n.x-window-mr {\n\tbackground: transparent repeat-y right 0;\n\tpadding-right:6px;\n    zoom:1;\n}\n\n.x-window-body {\n    overflow:hidden;\n}\n\n.x-window-bwrap {\n    overflow:hidden;\n}\n\n.x-window-maximized .x-window-bl, .x-window-maximized .x-window-br,\n    .x-window-maximized .x-window-ml, .x-window-maximized .x-window-mr,\n    .x-window-maximized .x-window-tl, .x-window-maximized .x-window-tr {\n    padding:0;\n}\n\n.x-window-maximized .x-window-footer {\n    padding-bottom:0;\n}\n\n.x-window-maximized .x-window-tc {\n    padding-left:3px;\n    padding-right:3px;\n}\n\n.x-window-maximized .x-window-mc {\n    border-left:0 none;\n    border-right:0 none;\n}\n\n.x-window-tbar .x-toolbar, .x-window-bbar .x-toolbar {\n    border-left:0 none;\n    border-right: 0 none;\n}\n\n.x-window-bbar .x-toolbar {\n    border-top:1px solid;\n    border-bottom:0 none;\n}\n\n.x-window-draggable, .x-window-draggable .x-window-header-text {\n    cursor:move;\n}\n\n.x-window-maximized .x-window-draggable, .x-window-maximized .x-window-draggable .x-window-header-text {\n    cursor:default;\n}\n\n.x-window-body {\n    background:transparent;\n}\n\n.x-panel-ghost .x-window-tl {\n    border-bottom:1px solid;\n}\n\n.x-panel-collapsed .x-window-tl {\n    border-bottom:1px solid;\n}\n\n.x-window-maximized-ct {\n    overflow:hidden;\n}\n\n.x-window-maximized .x-window-handle {\n    display:none;\n}\n\n.x-window-sizing-ghost ul {\n    border:0 none !important;\n}\n\n.x-dlg-focus{\n\t-moz-outline:0 none;\n\toutline:0 none;\n\twidth:0;\n\theight:0;\n\toverflow:hidden;\n\tposition:absolute;\n\ttop:0;\n\tleft:0;\n}\n\n.ext-webkit .x-dlg-focus{\n    width: 1px;\n    height: 1px;\n}\n\n.x-dlg-mask{\n    z-index:10000;\n    display:none;\n    position:absolute;\n    top:0;\n    left:0;\n    -moz-opacity: 0.5;\n    opacity:.50;\n    filter: alpha(opacity=50);\n}\n\nbody.ext-ie6.x-body-masked select {\n\tvisibility:hidden;\n}\n\nbody.ext-ie6.x-body-masked .x-window select {\n\tvisibility:visible;\n}\n\n.x-window-plain .x-window-mc {\n    border: 1px solid;\n}\n\n.x-window-plain .x-window-body {\n    border: 1px solid;\n    background:transparent !important;\n}", ""]);

// exports


/***/ }),
/* 942 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(943);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 943 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-html-editor-wrap {\r\n    border:1px solid;\r\n}\r\n\r\n.x-html-editor-tb .x-btn-text {\r\n    background:transparent no-repeat;\r\n}\r\n\r\n.x-html-editor-tb .x-edit-bold, .x-menu-item img.x-edit-bold {\r\n    background-position:0 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");    \r\n}\r\n\r\n.x-html-editor-tb .x-edit-italic, .x-menu-item img.x-edit-italic {\r\n    background-position:-16px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-underline, .x-menu-item img.x-edit-underline {\r\n    background-position:-32px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-forecolor, .x-menu-item img.x-edit-forecolor {\r\n    background-position:-160px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-backcolor, .x-menu-item img.x-edit-backcolor {\r\n    background-position:-176px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-justifyleft, .x-menu-item img.x-edit-justifyleft {\r\n    background-position:-112px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-justifycenter, .x-menu-item img.x-edit-justifycenter {\r\n    background-position:-128px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-justifyright, .x-menu-item img.x-edit-justifyright {\r\n    background-position:-144px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-insertorderedlist, .x-menu-item img.x-edit-insertorderedlist {\r\n    background-position:-80px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-insertunorderedlist, .x-menu-item img.x-edit-insertunorderedlist {\r\n    background-position:-96px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-increasefontsize, .x-menu-item img.x-edit-increasefontsize {\r\n    background-position:-48px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-decreasefontsize, .x-menu-item img.x-edit-decreasefontsize {\r\n    background-position:-64px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-sourceedit, .x-menu-item img.x-edit-sourceedit {\r\n    background-position:-192px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tb .x-edit-createlink, .x-menu-item img.x-edit-createlink {\r\n    background-position:-208px 0;\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}\r\n\r\n.x-html-editor-tip .x-tip-bd .x-tip-bd-inner {\r\n    padding:5px;\r\n    padding-bottom:1px;\r\n}\r\n\r\n.x-html-editor-tb .x-toolbar {\r\n    position:static !important;\r\n}", ""]);

// exports


/***/ }),
/* 944 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(945);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 945 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-panel-noborder .x-panel-body-noborder {\r\n    border-width:0;\r\n}\r\n\r\n.x-panel-noborder .x-panel-header-noborder {\r\n    border-width:0 0 1px;\r\n    border-style:solid;\r\n}\r\n\r\n.x-panel-noborder .x-panel-tbar-noborder .x-toolbar {\r\n    border-width:0 0 1px;\r\n    border-style:solid;\r\n}\r\n\r\n.x-panel-noborder .x-panel-bbar-noborder .x-toolbar {\r\n    border-width:1px 0 0 0;\r\n    border-style:solid;\r\n}\r\n\r\n.x-window-noborder .x-window-mc {\r\n    border-width:0;\r\n}\r\n\r\n.x-window-plain .x-window-body-noborder {\r\n    border-width:0;\r\n}\r\n\r\n.x-tab-panel-noborder .x-tab-panel-body-noborder {\r\n\tborder-width:0;\r\n}\r\n\r\n.x-tab-panel-noborder .x-tab-panel-header-noborder {\r\n    border-width: 0 0 1px 0;\r\n}\r\n\r\n.x-tab-panel-noborder .x-tab-panel-footer-noborder {\r\n    border-width: 1px 0 0 0;\r\n}\r\n\r\n.x-tab-panel-bbar-noborder .x-toolbar {\r\n    border-width: 1px 0 0 0;\r\n    border-style:solid;\r\n}\r\n\r\n.x-tab-panel-tbar-noborder .x-toolbar {\r\n    border-width:0 0 1px;\r\n    border-style:solid;\r\n}", ""]);

// exports


/***/ }),
/* 946 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(947);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 947 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-border-layout-ct {\n    position: relative;\n}\n\n.x-border-panel {\n    position:absolute;\n    left:0;\n    top:0;\n}\n\n.x-tool-collapse-south {\n    background-position:0 -195px;\n}\n\n.x-tool-collapse-south-over {\n    background-position:-15px -195px;\n}\n\n.x-tool-collapse-north {\n    background-position:0 -210px;\n}\n\n.x-tool-collapse-north-over {\n    background-position:-15px -210px;\n}\n\n.x-tool-collapse-west {\n    background-position:0 -180px;\n}\n\n.x-tool-collapse-west-over {\n    background-position:-15px -180px;\n}\n\n.x-tool-collapse-east {\n    background-position:0 -165px;\n}\n\n.x-tool-collapse-east-over {\n    background-position:-15px -165px;\n}\n\n.x-tool-expand-south {\n    background-position:0 -210px;\n}\n\n.x-tool-expand-south-over {\n    background-position:-15px -210px;\n}\n\n.x-tool-expand-north {\n    background-position:0 -195px;\n}\n.x-tool-expand-north-over {\n    background-position:-15px -195px;\n}\n\n.x-tool-expand-west {\n    background-position:0 -165px;\n}\n\n.x-tool-expand-west-over {\n    background-position:-15px -165px;\n}\n\n.x-tool-expand-east {\n    background-position:0 -180px;\n}\n\n.x-tool-expand-east-over {\n    background-position:-15px -180px;\n}\n\n.x-tool-expand-north, .x-tool-expand-south {\n    float:right;\n    margin:3px;\n}\n\n.x-tool-expand-east, .x-tool-expand-west {\n    float:none;\n    margin:3px auto;\n}\n\n.x-accordion-hd .x-tool-toggle {\n    background-position:0 -255px;\n}\n\n.x-accordion-hd .x-tool-toggle-over {\n    background-position:-15px -255px;\n}\n\n.x-panel-collapsed .x-accordion-hd .x-tool-toggle {\n    background-position:0 -240px;\n}\n\n.x-panel-collapsed .x-accordion-hd .x-tool-toggle-over {\n    background-position:-15px -240px;\n}\n\n.x-accordion-hd {\n\tpadding-top:4px;\n\tpadding-bottom:3px;\n\tborder-top:0 none;\n    background: transparent repeat-x 0 -9px;\n}\n\n.x-layout-collapsed{\n    position:absolute;\n    left:-10000px;\n    top:-10000px;\n    visibility:hidden;\n    width:20px;\n    height:20px;\n    overflow:hidden;\n\tborder:1px solid;\n\tz-index:20;\n}\n\n.ext-border-box .x-layout-collapsed{\n    width:22px;\n    height:22px;\n}\n\n.x-layout-collapsed-over{\n    cursor:pointer;\n}\n\n.x-layout-collapsed-west .x-layout-collapsed-tools, .x-layout-collapsed-east .x-layout-collapsed-tools{\n\tposition:absolute;\n    top:0;\n    left:0;\n    width:20px;\n    height:20px;\n}\n\n\n.x-layout-split{\n    position:absolute;\n    height:5px;\n    width:5px;\n    line-height:1px;\n    font-size:1px;\n    z-index:3;\n    background-color:transparent;\n}\n\n/* IE6 strict won't drag w/out a color */\n.ext-strict .ext-ie6 .x-layout-split{\n    background-color: #fff !important;\n    filter: alpha(opacity=1);\n}\n\n.x-layout-split-h{\n    background-image:url(" + escape(__webpack_require__(231)) + ");\n    background-position: left;\n}\n\n.x-layout-split-v{\n    background-image:url(" + escape(__webpack_require__(231)) + ");\n    background-position: top;\n}\n\n.x-column-layout-ct {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-column {\n    float:left;\n    padding:0;\n    margin:0;\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-column-inner {\n    overflow:hidden;\n    zoom:1;\n}\n\n/* mini mode */\n.x-layout-mini {\n    position:absolute;\n    top:0;\n    left:0;\n    display:block;\n    width:5px;\n    height:35px;\n    cursor:pointer;\n    opacity:.5;\n    -moz-opacity:.5;\n    filter:alpha(opacity=50);\n}\n\n.x-layout-mini-over, .x-layout-collapsed-over .x-layout-mini{\n    opacity:1;\n    -moz-opacity:1;\n    filter:none;\n}\n\n.x-layout-split-west .x-layout-mini {\n    top:48%;\n}\n\n.x-layout-split-east .x-layout-mini {\n    top:48%;\n}\n\n.x-layout-split-north .x-layout-mini {\n    left:48%;\n    height:5px;\n    width:35px;\n}\n\n.x-layout-split-south .x-layout-mini {\n    left:48%;\n    height:5px;\n    width:35px;\n}\n\n.x-layout-cmini-west .x-layout-mini {\n    top:48%;\n}\n\n.x-layout-cmini-east .x-layout-mini {\n    top:48%;\n}\n\n.x-layout-cmini-north .x-layout-mini {\n    left:48%;\n    height:5px;\n    width:35px;\n}\n\n.x-layout-cmini-south .x-layout-mini {\n    left:48%;\n    height:5px;\n    width:35px;\n}\n\n.x-layout-cmini-west, .x-layout-cmini-east {\n    border:0 none;\n    width:5px !important;\n    padding:0;\n    background:transparent;\n}\n\n.x-layout-cmini-north, .x-layout-cmini-south {\n    border:0 none;\n    height:5px !important;\n    padding:0;\n    background:transparent;\n}\n\n.x-viewport, .x-viewport body {\n    margin: 0;\n    padding: 0;\n    border: 0 none;\n    overflow: hidden;\n    height: 100%;\n}\n\n.x-abs-layout-item {\n    position:absolute;\n    left:0;\n    top:0;\n}\n\n.ext-ie input.x-abs-layout-item, .ext-ie textarea.x-abs-layout-item {\n    margin:0;\n}\n\n.x-box-layout-ct {\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-box-inner {\n    overflow:hidden;\n    zoom:1;\n    position:relative;\n    left:0;\n    top:0;\n}\n\n.x-box-item {\n    position:absolute;\n    left:0;\n    top:0;\n}", ""]);

// exports


/***/ }),
/* 948 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(949);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 949 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-progress-wrap {\r\n    border:1px solid;\r\n    overflow:hidden;\r\n}\r\n\r\n.x-progress-inner {\r\n    height:18px;\r\n    background:repeat-x;\r\n    position:relative;\r\n}\r\n\r\n.x-progress-bar {\r\n    height:18px;\r\n    float:left;\r\n    width:0;\r\n    background: repeat-x left center;\r\n    border-top:1px solid;\r\n    border-bottom:1px solid;\r\n    border-right:1px solid;\r\n}\r\n\r\n.x-progress-text {\r\n    padding:1px 5px;\r\n    overflow:hidden;\r\n    position:absolute;\r\n    left:0;\r\n    text-align:center;\r\n}\r\n\r\n.x-progress-text-back {\r\n    line-height:16px;\r\n}\r\n\r\n.ext-ie .x-progress-text-back {\r\n    line-height:15px;\r\n}\r\n\r\n.ext-strict .ext-ie7 .x-progress-text-back{\r\n    width: 100%;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 950 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(951);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 951 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-list-header{\r\n\tbackground: repeat-x 0 bottom;\r\n\tcursor:default;\r\n    zoom:1;\r\n    height:22px;\r\n}\r\n\r\n.x-list-header-inner div {\r\n    display:block;\r\n    float:left;\r\n    overflow:hidden;\r\n\t-o-text-overflow: ellipsis;\r\n\ttext-overflow: ellipsis;\r\n    white-space: nowrap;\r\n}\r\n\r\n.x-list-header-inner div em {\r\n    display:block;\r\n    border-left:1px solid;\r\n    padding:4px 4px;\r\n    overflow:hidden;\r\n    -moz-user-select: none;\r\n    -khtml-user-select: none;\r\n    line-height:14px;\r\n}\r\n\r\n.x-list-body {\r\n    overflow:auto;\r\n    overflow-x:hidden;\r\n    overflow-y:auto;\r\n    zoom:1;\r\n    float: left;\r\n    width: 100%;\r\n}\r\n\r\n.x-list-body dl {\r\n    zoom:1;\r\n}\r\n\r\n.x-list-body dt {\r\n    display:block;\r\n    float:left;\r\n    overflow:hidden;\r\n\t-o-text-overflow: ellipsis;\r\n\ttext-overflow: ellipsis;\r\n    white-space: nowrap;\r\n    cursor:pointer;\r\n    zoom:1;\r\n}\r\n\r\n.x-list-body dt em {\r\n    display:block;\r\n    padding:3px 4px;\r\n    overflow:hidden;\r\n    -moz-user-select: none;\r\n    -khtml-user-select: none;\r\n}\r\n\r\n.x-list-resizer {\r\n    border-left:1px solid;\r\n    border-right:1px solid;\r\n    position:absolute;\r\n    left:0;\r\n    top:0;\r\n}\r\n\r\n.x-list-header-inner em.sort-asc {\r\n    background: transparent no-repeat center 0;\r\n    border-style:solid;\r\n    border-width: 0 1px 1px;\r\n    padding-bottom:3px;\r\n}\r\n\r\n.x-list-header-inner em.sort-desc {\r\n    background: transparent no-repeat center -23px;\r\n    border-style:solid;\r\n    border-width: 0 1px 1px;\r\n    padding-bottom:3px;\r\n}\r\n\r\n", ""]);

// exports


/***/ }),
/* 952 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(953);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 953 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n/* Shared styles */\r\n.x-slider {\r\n    zoom:1;\r\n}\r\n\r\n.x-slider-inner {\r\n    position:relative;\r\n    left:0;\r\n    top:0;\r\n    overflow:visible;\r\n    zoom:1;\r\n}\r\n\r\n.x-slider-focus {\r\n\tposition:absolute;\r\n\tleft:0;\r\n\ttop:0;\r\n\twidth:1px;\r\n\theight:1px;\r\n    line-height:1px;\r\n    font-size:1px;\r\n    -moz-outline:0 none;\r\n    outline:0 none;\r\n    -moz-user-select: none;\r\n    -khtml-user-select:none;\r\n    -webkit-user-select:ignore;\r\n\tdisplay:block;\r\n\toverflow:hidden;  \r\n}\r\n\r\n/* Horizontal styles */\r\n.x-slider-horz {\r\n    padding-left:7px;\r\n    background:transparent no-repeat 0 -22px;\r\n}\r\n\r\n.x-slider-horz .x-slider-end {\r\n    padding-right:7px;\r\n    zoom:1;\r\n    background:transparent no-repeat right -44px;\r\n}\r\n\r\n.x-slider-horz .x-slider-inner {\r\n    background:transparent repeat-x 0 0;\r\n    height:22px;\r\n}\r\n\r\n.x-slider-horz .x-slider-thumb {\r\n    width:14px;\r\n    height:15px;\r\n    position:absolute;\r\n    left:0;\r\n    top:3px;\r\n    background:transparent no-repeat 0 0;\r\n}\r\n\r\n.x-slider-horz .x-slider-thumb-over {\r\n    background-position: -14px -15px;\r\n}\r\n\r\n.x-slider-horz .x-slider-thumb-drag {\r\n    background-position: -28px -30px;\r\n}\r\n\r\n/* Vertical styles */\r\n.x-slider-vert {\r\n    padding-top:7px;\r\n    background:transparent no-repeat -44px 0;\r\n    width:22px;\r\n}\r\n\r\n.x-slider-vert .x-slider-end {\r\n    padding-bottom:7px;\r\n    zoom:1;\r\n    background:transparent no-repeat -22px bottom;\r\n}\r\n\r\n.x-slider-vert .x-slider-inner {\r\n    background:transparent repeat-y 0 0;\r\n}\r\n\r\n.x-slider-vert .x-slider-thumb {\r\n    width:15px;\r\n    height:14px;\r\n    position:absolute;\r\n    left:3px;\r\n    bottom:0;\r\n    background:transparent no-repeat 0 0;\r\n}\r\n\r\n.x-slider-vert .x-slider-thumb-over {\r\n    background-position: -15px -14px;\r\n}\r\n\r\n.x-slider-vert .x-slider-thumb-drag {\r\n    background-position: -30px -28px;\r\n}", ""]);

// exports


/***/ }),
/* 954 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(955);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 955 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-window-dlg .x-window-body {\r\n    border:0 none !important;\r\n    padding:5px 10px;\r\n    overflow:hidden !important;\r\n}\r\n\r\n.x-window-dlg .x-window-mc {\r\n    border:0 none !important;\r\n}\r\n\r\n.x-window-dlg .ext-mb-input {\r\n    margin-top:4px;\r\n    width:95%;\r\n}\r\n\r\n.x-window-dlg .ext-mb-textarea {\r\n    margin-top:4px;\r\n}\r\n\r\n.x-window-dlg .x-progress-wrap {\r\n    margin-top:4px;\r\n}\r\n\r\n.ext-ie .x-window-dlg .x-progress-wrap {\r\n    margin-top:6px;\r\n}\r\n\r\n.x-window-dlg .x-msg-box-wait {\r\n    background:transparent no-repeat left;\r\n    display:block;\r\n    width:300px;\r\n    padding-left:18px;\r\n    line-height:18px;\r\n}\r\n\r\n.x-window-dlg .ext-mb-icon {\r\n    float:left;\r\n    width:47px;\r\n    height:32px;\r\n}\r\n\r\n.ext-ie .x-window-dlg .ext-mb-icon {\r\n    width:44px; /* 3px IE margin issue */\r\n}\r\n\r\n.x-window-dlg .x-dlg-icon .ext-mb-content{\r\n    zoom: 1; margin-left: 47px;\r\n}\r\n\r\n.x-window-dlg .ext-mb-info, .x-window-dlg .ext-mb-warning, .x-window-dlg .ext-mb-question, .x-window-dlg .ext-mb-error {\r\n    background:transparent no-repeat top left;\r\n}\r\n\r\n.ext-gecko2 .ext-mb-fix-cursor {\r\n    overflow:auto;\r\n}", ""]);

// exports


/***/ }),
/* 956 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(957);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 957 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.ext-el-mask {\r\n    background-color: #ccc;\r\n}\r\n\r\n.ext-el-mask-msg {\r\n    border-color:#6593cf;\r\n    background-color:#c3daf9;\r\n    background-image:url(" + escape(__webpack_require__(582)) + ");\r\n}\r\n.ext-el-mask-msg div {\r\n    background-color: #eee;\r\n    border-color:#a3bad9;\r\n    color:#222;\r\n    font:normal 11px tahoma, arial, helvetica, sans-serif;\r\n}\r\n\r\n.x-mask-loading div {\r\n    background-color:#fbfbfb;\r\n    background-image:url(" + escape(__webpack_require__(376)) + ");\r\n}\r\n\r\n.x-item-disabled {\r\n    color: gray;\r\n}\r\n\r\n.x-item-disabled * {\r\n    color: gray !important;\r\n}\r\n\r\n.x-splitbar-proxy {\r\n    background-color: #aaa;\r\n}\r\n\r\n.x-color-palette a {\r\n    border-color:#fff;\r\n}\r\n\r\n.x-color-palette a:hover, .x-color-palette a.x-color-palette-sel {\r\n    border-color:#8bb8f3;\r\n    background-color: #deecfd;\r\n}\r\n\r\n.x-color-palette em:hover, .x-color-palette span:hover{   \r\n    background-color: #deecfd;\r\n}\r\n\r\n.x-color-palette em {\r\n    border-color:#aca899;\r\n}\r\n\r\n.x-ie-shadow {\r\n    background-color:#777;\r\n}\r\n\r\n.x-shadow .xsmc {\r\n    background-image: url(" + escape(__webpack_require__(958)) + ");\r\n}\r\n\r\n.x-shadow .xsml, .x-shadow .xsmr {\r\n    background-image: url(" + escape(__webpack_require__(959)) + ");\r\n}\r\n\r\n.x-shadow .xstl, .x-shadow .xstc,  .x-shadow .xstr, .x-shadow .xsbl, .x-shadow .xsbc, .x-shadow .xsbr{\r\n    background-image: url(" + escape(__webpack_require__(960)) + ");\r\n}\r\n\r\n.loading-indicator {\r\n    font-size: 11px;\r\n    background-image: url(" + escape(__webpack_require__(376)) + ");\r\n}\r\n\r\n.x-spotlight {\r\n    background-color: #ccc;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 958 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAABhJREFUeNpiZGBgsGBAA0wMWACFggABBgAYjgBCU52H7gAAAABJRU5ErkJggg=="

/***/ }),
/* 959 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAGCAYAAAD37n+BAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAClJREFUeNpiZGBg4IBibiDmhdIgPgj8AOKvQPwZSv9gYiARDAcNAAEGAAwtBRShb5+6AAAAAElFTkSuQmCC"

/***/ }),
/* 960 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAYAAAAwCAYAAAAy7wv4AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAANlJREFUeNrEkz0PgjAQhltQQVHD5mDi4sLipIMJi///7/iFCuq9+l7SgSNh0SYP195DuPZIvXMuChjo3MsjJkMCGfsgMRJSxqHnRJMTxgQiIWNhSvkRKQUSMyFTsRduwlk4ChesIXYUSJyEq4oNRUWJeIdYCw8sNIk1xEJohJovgAZiLjxJrfPO7ZoHNFtiNtFsu/mjzO2aBzRb0tpE7GblvkNr4LONildQo9YaKcmCXqV/F7lrGRBLSxSW2FqitMShtyh7Fy96HzDvKl4FdxCxipwxfiHeAgwAKlpFtigygOYAAAAASUVORK5CYII="

/***/ }),
/* 961 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(962);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 962 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-tab-panel-header, .x-tab-panel-footer {\n\tbackground-color: #deecfd;\n\tborder-color:#8db2e3;\n    overflow:hidden;\n    zoom:1;\n}\n\n.x-tab-panel-header, .x-tab-panel-footer {\n\tborder-color:#8db2e3;\n}\n\nul.x-tab-strip-top{\n    background-color:#cedff5;\n\tbackground-image: url(" + escape(__webpack_require__(963)) + ");\n\tborder-bottom-color:#8db2e3;\n}\n\nul.x-tab-strip-bottom{\n    background-color:#cedff5;\n\tbackground-image: url(" + escape(__webpack_require__(964)) + ");\n\tborder-top-color:#8db2e3;\n}\n\n.x-tab-panel-header-plain .x-tab-strip-spacer,\n.x-tab-panel-footer-plain .x-tab-strip-spacer {\n    border-color:#8db2e3;\n    background-color: #deecfd;\n}\n\n.x-tab-strip span.x-tab-strip-text {\n\tfont:normal 11px tahoma,arial,helvetica;\n\tcolor:#416aa3;\n}\n\n.x-tab-strip-over span.x-tab-strip-text {\n\tcolor:#15428b;\n}\n\n.x-tab-strip-active span.x-tab-strip-text {\n\tcolor:#15428b;\n    font-weight:bold;\n}\n\n.x-tab-strip-disabled .x-tabs-text {\n\tcolor:#aaaaaa;\n}\n\n.x-tab-strip-top .x-tab-right, .x-tab-strip-top .x-tab-left, .x-tab-strip-top .x-tab-strip-inner{\n\tbackground-image: url(" + escape(__webpack_require__(965)) + ");\n}\n\n.x-tab-strip-bottom .x-tab-right {\n\tbackground-image: url(" + escape(__webpack_require__(966)) + ");\n}\n\n.x-tab-strip-bottom .x-tab-left {\n\tbackground-image: url(" + escape(__webpack_require__(967)) + ");\n}\n\n.x-tab-strip-bottom .x-tab-strip-over .x-tab-right {\n\tbackground-image: url(" + escape(__webpack_require__(968)) + ");\n}\n\n.x-tab-strip-bottom .x-tab-strip-over .x-tab-left {\n\tbackground-image: url(" + escape(__webpack_require__(969)) + ");\n}\n\n.x-tab-strip-bottom .x-tab-strip-active .x-tab-right {\n\tbackground-image: url(" + escape(__webpack_require__(970)) + ");\n}\n\n.x-tab-strip-bottom .x-tab-strip-active .x-tab-left {\n\tbackground-image: url(" + escape(__webpack_require__(971)) + ");\n}\n\n.x-tab-strip .x-tab-strip-closable a.x-tab-strip-close {\n\tbackground-image:url(" + escape(__webpack_require__(583)) + ");\n}\n\n.x-tab-strip .x-tab-strip-closable a.x-tab-strip-close:hover{\n\tbackground-image:url(" + escape(__webpack_require__(583)) + ");\n}\n\n.x-tab-panel-body {\n    border-color:#8db2e3;\n    background-color:#fff;\n}\n\n.x-tab-panel-body-top {\n    border-top: 0 none;\n}\n\n.x-tab-panel-body-bottom {\n    border-bottom: 0 none;\n}\n\n.x-tab-scroller-left {\n    background-image:url(" + escape(__webpack_require__(972)) + ");\n    border-bottom-color:#8db2e3;\n}\n\n.x-tab-scroller-left-over {\n    background-position: 0 0;\n}\n\n.x-tab-scroller-left-disabled {\n    background-position: -18px 0;\n    opacity:.5;\n    -moz-opacity:.5;\n    filter:alpha(opacity=50);\n    cursor:default;\n}\n\n.x-tab-scroller-right {\n    background-image:url(" + escape(__webpack_require__(973)) + ");\n    border-bottom-color:#8db2e3;\n}\n\n.x-tab-panel-bbar .x-toolbar, .x-tab-panel-tbar .x-toolbar {\n    border-color:#99bbe8;\n}", ""]);

// exports


/***/ }),
/* 963 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAaAIcAAMva78zb783b8M3c8M7c8M/d8NDd8dHe8dLf8tPg8tTg8tXh8tXh89bi89fi89jj89nk9Nrl9Nvl9dzm9d3m9d3n9d7n9t/o9gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABABoAAAggAC9YqEBhgoQIECA8cNCAwQIFCRAcOGCgAIEBAgIACAgAOw=="

/***/ }),
/* 964 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAaAIcAALnQ7cja8c7f9dDg9dLi9tPj9tXl99fm+Nno+Nvq+dzr+d7t+uDu+gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABABoAAAgXAAEACCBgAIECBg4gSKBgAYOHECNCDAgAOw=="

/***/ }),
/* 965 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhGADCAYcAAED/QI2y457A7MXd/M3e88ze9s7g98zi/tDh+NLj+NPm/tTk+dbm+tfo/dfr/9jn+9rp+9nq/tvq/tvq/9zq/N3s/97s/d/t/97v/+Dt/eDv/+Tv/eLw/+Ty/+Xz/+bw/ebz/+ny/Ory/erz/evz/Orz/+j0/+r1/+zz/ez0/e30/e33/+71/e/2/+/4//D2/fP4/fP6//P7//X5/vT7//T8//X8//f9//j7/vr8/v3+/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAAAYAMIBAAj/AAEACECwoMGDCAMM3MGwocOHEHcEIBCxYsQAO3Ro3Mixo0cdGHOIHEmypMkcGHGoXMmypUscGGfInEmzps0ZGGHo3Mmzp08YGF8IHUq0qNEXGFkoXcq0qVMWGElInUq1qlUSGENo3cq1q9cQGC2IHUu2rFkLYc+qNZt2rVu0O96+bSv3LN26Ze/iHat3L1y/bOMCJtt3b2G8h+smlrt4ruDBYhu7lbyWslrLdh9DxhwYMl/NgznnBQ1YNGHSfk1/9hwZtWHXiGErls2YtmPWf1mrbo1bYMLfCRdaHM4QY4HjyJMrX14ggAUD0KNLn07dQIANCLJr3869O4IAJRKI/x9Pvrz5BAFELFjPvr379wsCoGBAv779+/gZBFDxoL///wAG+EAALUBg4IEIJqggBARSoJsKuO0XYQoRohDhCBF+EGEGEUoQoQIRHhDiiLqJWCKJngVgYoorbtZiaC+WFmNqMxpWI2I3KpYjYzvO1eNkP1YW5GVD2lUkW0fmlSRhS/LVZGRPohWliii62BsAAmSp5ZZcdimAcMRZFMAADZRp5ploptmAcxG06eabcMYZwXUT1GnnnXjmOQF4FfTp55+ABlpBehcUauihiCZ6gXwaNOroo5BGqsF+HFRq6aWYZsoBgR106umnoIbaAYEmlGrqqaimasJ+qraqKquuxv9aagApyCqrfLbGGsAIuboawAe9thpABsG+KkGxqQagALKoqsjsqc4+O+sB0k5b7arUVhuttNs+2y2z3yIbbrHjBltur+fmmq6t696aLbfvehsvuPOKWy+595qbL7r7qtsvu/+6e227ugZc8MAG+wrcwgaF6fDDFn0k8cQnVWzxSxhnfNPGHP/k8cdHhSzyUySXfNXJKH+l8sq4tezyyzDHLPPMNNds880456zzzjz37PPPQAct9NBEF20Yw0hDbBFzTDdd3dNQeyf11OdVbTV8WGed39ZcC+j11wuGLbbRZJdt9tlop6322my37fbbcMct99xqeWn33UpXpObefMv/6fffegYuuKCEF67o4YhLqvjimjbuuKiQR37t5JRXbvnlmGeu+eacd+7556CHLvropJdu+umop6766qybizRwAuXtEAEKyT57ABPnvpFEFvc+kkQZB7+SRBwXP5NEHye/k0QiNz+URCVHv5REKFc/lUQrZ7+VRLhxz5r3noEPmfiDkQ+Y+X6hv5f6eLFfl/tywf+W/G7Rv5b9auF/lv5m8V+W/2QB4FgEKBYCWsCACHTO9xQYPgaOz4Hlg+D5JJg+Cq7Pgu3D4Ps0GD8Ozs+D9QPh/USYv9ctLHa2Kw4AmsZC5EgEajCMDlqmRkPtbCAAVsvheEoQgKz5kD0iCADX/4ZYHxQE4GtI9I8KAiC2Jh6oBSQ0CwWgiJslVjGKZkkBFstiRNyMYItk+QAYx5KBMYpFAma0gALSeAA2uhE3bYTjG1kTRzrO0TN1xOMdIZNHPu5xMH0E5B8BE0hCDtIvhUTkIfeSSEYuEi+NhKQb70ZJLaEwhV/imybNtAMB/O2TbjKBAARHSjutQACFS6WfZCAAxLnSUDEQwOJm6SgaCMBxuLSUDQQQuV566gYCqBYIgHmtXRYzmNWqATKlZctrsfJaLljms04gTWZ5oJrIwgA2i+WAbQarm9cCZ7XEKS1yPsuczEInstTJTW/2ip3fdGeu4PlOedqKnvO0p6zweSVPfcaKn/v0p6sA+k+BtoqgAzWoqhB6UIWmiqELdSiqIPpQAQQEADs="

/***/ }),
/* 966 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhLAEyAIcAAI2y45m76Jq86pu96qDC7afH8avL88ze9s7g98zi/tDh+NLj+NPm/tTk+dbm+tjn+9rp+9vq/tzq/N7s/eDu+uDt/eTv/ebw/ery/erz/erz/+zz/ez0/e30/e/2/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAsATIAAAj/ACcIHEiwoMGDCBMqXMiwocOHECNKnEixosWLFj8AwMixo8ePIEOKHEmyYYIAJVOqXMmypcuWJ1/KnEmzps2VMW/q3Mmzp8+cPoMKHUq0I9CiSJMqXXp0qdOnUGk2jUq1qlWPU69q3cpVYdauYMNe/Sq2rNmkZM+qXbszLdu3cGGijEu3rly7ePOKdKu3r9+FfP8KHjwhMOHDeQ0jXhxXMePHah1DnhxWMuXLWi1j3hxVM+fPSj2DHj1UNOnTPE2jXl1TNevXLl3Dnp1SNu3bIRnMxc17Z4TdvYPTrABcuPGWF4ofX14yg3Lm0EFueB69OkYO1K1rn9gh+/bvDruD/x8vUYKHABDSq1/Pvr379/Djy59Pv779+/jz69/Pv7///uc9IOCABBZo4IEIJqjgggw26OCDEEYo4YQUVmjhhRZ258CGHHbo4YcghijiiCSWaOKJKKao4oostujiizC+OF0DNNZo44045qjjjjz26OOPQAYp5JBEFmnkkUgmiSQGASzg5JNQRinllFRWaeWVWGap5ZZcdunll2CGKeaYYmoggAJopqnmmmy26eabcMYp55x01mnnnXjmqeeefPbJpwUDICDooIQWauihiCaq6KKMNuroo5BGKumklFZq6aWWTkDAAZx26umnoIYq6qiklmrqqaimquqqrLbq6quwxkcK6wcFfGDrrbjmquuuvPbq66/ABivssMQWa+yxyCar7LLKGsAAANBGK+201FZr7bXYZqvtttx26+234IYr7rjklksuAxQEBAA7"

/***/ }),
/* 967 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAwAxAIcAAI2y45m76Jq86pu96qDC7afH8avL88ze9s7g98zi/tDh+NLj+NPm/tTk+dbm+tjn+9rp+9vq/tzq/N7s/eDu+uDt/eTv/ebw/ery/erz/erz/+zz/ez0/e30/e/2/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAADADEAAAhTAAMkmCCQ4MCCCA8qNMgwYcOFDiNCnPiwIkIGBCMQrEDwAsEMBDcQ5ECwQ0mCHiQE8AAhQIcHATY4CIChgQANCwZYUEBgAoICHw4wMPCBAgMAAQEAOw=="

/***/ }),
/* 968 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhLAEyAMQAAOj0/+Dv/9/t/9fo/dnq/t3s/+Ty/57A7Nvq/+Lw/////42y48zi/tPm/u30/e/2/+zz/eDt/erz/ebw/ez0/d7s/dvq/urz/8Xd/OTv/eDu+ury/QAAAAAAAAAAAAAAACH5BAAAAAAALAAAAAAsATIAAAX/ICCOZGmeaKqubOu+cCzPdG3fNrPgfO//wKBwSGzpisikcslsMo/OqHRKrSah1qx2y+Viu+CweMz7ks/odNqsbrvfUjZ8Tq/35Pa8fp/C8/+AdX6BhIVng4aJilmIi46PS42Qk5Q/kpWYmTKXmp2eKJyfop+ho6aYpaeqj6mrroatr7J/sbO2drW3um+5u75ovb/CYcHDxlrFx8pTycvOTzvP0mvR09ZiDdXX21sW2tzgVBHf4eVNE+Tm6kgS6evvQRDu8PQ8FPP1+TQO+Pr+L/z+CazxYIGBgwgTKlzIsKHDhxAjSpxIsaLFixgzatzIcWPBBCBDihxJsqTJkyhT+6pcybKly5cwY8qcSbMmTX4BcurcybOnz59AgwodSrSo0aNIkypdyrSp06byBEidSrWq1atYs2rdyrWr169gw4odS7as2bNmNywowLat27dw48qdS7eu3bt48+rdy7ev37+AAwO+sACB4cOIEytezLix48eQI0ueTLmy5cuYM2verDnDAgKgQ4seTbq06dOoU6tezbq169ewY8ueTbs27QoLBujezbu379/AgwsfTry48ePIkytfzry58+fOMSxQQL269evYs2vfzr279+/gw4sfT768+fPo06Nf0OCA+/fw48ufT7++/fv48+vfz7+///8ABijggAI2oEEIADs="

/***/ }),
/* 969 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAwAxAMQAAJm76Oj0/9fr//X8/9Pm/v////P7//f9//T7/93s/+bz/9vq/+Lw/97v/6DC7er1/+33/57A7PT8/9nq/uDv/+Ty/+Xz/6fH8Zu96u/4/9fo/Zq86o2y4+Du+t/t//P6/yH5BAAAAAAALAAAAAADADEAAAU8ICAEIjmW6KmabNqubgzPb402pEU+ZEYaJARJQhoUSQcF4FABDBgABAXw8WwMCQxk4QhMLgUNIVLoEDghADs="

/***/ }),
/* 970 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAwAyAIcAAI2y483e89Pm/t7s/eDu+uny/Ovz/O71/fD2/fP4/fX5/vj7/vr8/v3+/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAADADIAAAg8AAc4ACCQ4MCCCA8qNMgwYcOFDiNCnPiwokSLFB0WGGhg4IGBCAYmGKhg4IKBDAY2GOggAICBAgAIIBAQADs="

/***/ }),
/* 971 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhLAEyAIcAAI2y483e89Pm/t7s/eDu+uny/Ovz/O71/fD2/fP4/fX5/vj7/vr8/v3+/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAsATIAAAj/AAE4GECwoMGDCBMqXMiwocOHECNKnEixosWLGDNiFKixo8ePIEOKHEmy5EOOJlOqXMmypUuWKF/KnEmzps2UMW/q3MmzJ8+cPoMKHUpUI9CiSJMqTXp0qdOnUGU2jUq1qtWOU69q3cpVYdauYMNW/Sq2rNmiZM+qXXszLdu3cFe6jUu37se5dvPqnYh3r9+/CfsCHvxXMOHDdg0jXvxWMePHZh1DntxVMuXLVi1j3vxUM+fPSD2DHh1UNOnTOk2jXj1TNevXMAfCnq3UNe3bIW3j3m1UNu/fbX0DHy5VOPHjco0jX05SN/PnBZ1Dfy6wgPXr2LNr3869u/fv4MOL/x9Pvrz58+jTq1+vXqCB9/Djy59Pv779+/jz69/Pv7///wAGKOCABA4o0AEIJqjgggw26OCDEEYo4YQUVmjhhRhmqOGGHHbIoUAIhCjiiCSWaOKJKKao4oostujiizDGKOOMNNZoY40CJaDjjjz26OOPQAYp5JBEFmnkkUgmqeSSTDbp5JNOCqTAlFRWaeWVWGap5ZZcdunll2CGKeaYZJZp5ploninQAmy26eabcMYp55x01mnnnXjmqeeefPbp55+ABgqoQAwUauihiCaq6KKMNuroo5BGKumklFZq6aWYZqpppgI14OmnoIYq6qiklmrqqaimquqqrLbq6quwxlcq66yyAhCAA7jmquuuvPbq66/ABivssMQWa+yxyCar7LLMNsusALY6K+201FZr7bXYZqutsARAC8C34IYr7rjklmvuueimq+667Lbr7rvwxivvvPTKGxAAOw=="

/***/ }),
/* 972 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhJAArAIcAAExypFZ8rkD/QGqNunSXxI2y48LY9MTZ9Mba9Mfb9Mnc9Mvd9M3e9M7f9Mzi/s7j/tDg9NLg9NTh89bi89fj89Dk/tHl/tPm/tXn/tfo/tnk89vl893m897n89jp/trq/tzq/t7r/eDo8+Lp8+Ds/eHt/ePu/eXv/efw/ejx/ery/ezz/ez0/e30/fD2/vb6/gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAIALAAAAAAkACsAAAj/AAUIHEiwoMGDCAsoXMiwocOHEF9InEixosQCFjNSLLCio8ePIFe8KDCipMmTKEeMVMGypcuXKkaKmEmzpk0RI1Po3MmzZ4qRHYIKHUq0w0gUSJMqXYpiRQEOUKNKncrB6YmrWE+42Jr1qtMNYMOKHbvBqYmzaLcS2Ir2rFMNcOPCHSA3rtMSePFuDRBgq1+8TikIHkwBAADCg52SWExiL1+/Wxc7nUC5smEAlTM7DcHZMd/PfTk7lUCa9OXTAEo7BQHCM+jHrJ1GmB0B9WnaTj/odg3ahW6nEIIHt21YuFMPyD14huwCudMG0KNfjk7daYbr1x0zv+6UgffvDAyD7P/uFIP582q3njfvdIH79+4HwH/v9IL9+xf84rfvVIH//wAGqIBTFhRo4IEIWuBUAgw26OCDCThVwYQUVmhhBU4hoOGGHHaIgFMPhCjiiCQ+4NQBKKao4ooHOOXAizDGKKMDLBRgwI045qijATXO6COMLdi445A3Bvnjj0ESSaSRR86YpJI7MtlkjE9CmaOUU75YpZVFFpAllUJy2eWXQIYpJpZZbsklmlOqaSWbTboJJZxHyqkknUiauaaXZDpg55J8kvnnkHj6OGiUgX55qI6FOqnnm4mm+eickbY56Z2VxnkpoH36uSmhBQQEADs="

/***/ }),
/* 973 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhJAArAIcAAExypFZ8rkD/QGqNunSXxI2y48LY9MTZ9Mba9Mfb9Mnc9Mvd9M3e9M7f9Mzi/s7j/tDg9NLg9NTh89bi89fj89Dk/tHl/tPm/tXn/tfo/tnk89vl893m897n89jp/trq/tzq/t7r/eDo8+Lp8+Ds/eHt/ePu/eXv/efw/ejx/ery/ezz/ez0/e30/fD2/vb6/gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAIALAAAAAAkACsAAAj/AAUIHEiwoMGDCAsoXMiwocOHEAu8mEixosWJEi9qpChxhMePIEOOkLiipMmTKFdIFMGypcuXIiSqmEmzpk0VEjvo3MmzZweJKYIKHUo0RYEVHJIqXcqUw1EUUKNKnYri6IarWLNq3XD0hNevLsJ+HXtUg9mzGgagRXvUhFu3YQmEffv2KIW7eCkAAJAX79ESJcIKDhAgLODDRycoXjxhLwDGio+SICE4LOHCLiZPPiqhs+PPADqLPhoihIvLqDGXDnE0gmvQn127PgoCxOnUl8PWPgqhN+y9vYMf/fDhNu6wxD8cbcC8eQPHzpkf9eChsvGw1KkfZcC9O4O93rsf8c2QwTrhsOTTH13Avv2CAe7dH8VAn37csPXrH1XAv7///wocdcGABApG4IFHJaDgggw2mMBRFkQo4YQUWnAUAhhmqOGGCBxVwYcghihiBUcdYOKJKKZ4wFEPtOjiizA+UAALBtRo4404GjCjAzz26OOPDhTQQo5E2igkkEj2KGSRRR6ZJJJLMpmjk0/+GKWUN1JZpZJDYpllC1ta2aWXNWoZ5pVkmrklml6qWSWbWLr5JJxSypkknUzaCeWYaYIZJpdkGunnn0Hy2eagf+LZJKJnGhono2s6Wiekb0qaJ6VzWroooTwqSqSeQHo6JaZJBgQAOw=="

/***/ }),
/* 974 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(975);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 975 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-form-field{\n    font:normal 12px tahoma, arial, helvetica, sans-serif;\n}\n\n.x-form-text, textarea.x-form-field{\n    background-color:#fff;\n    background-image:url(" + escape(__webpack_require__(393)) + ");\n    border-color:#b5b8c8;\n}\n\n.x-form-select-one {\n    background-color:#fff;\n    border-color:#b5b8c8;\n}\n\n.x-form-check-group-label {\n    border-bottom: 1px solid #99bbe8;\n    color: #15428b;\n}\n\n.x-editor .x-form-check-wrap {\n    background-color:#fff;\n}\n\n.x-form-field-wrap .x-form-trigger{\n    background-image:url(" + escape(__webpack_require__(976)) + ");\n    border-bottom-color:#b5b8c8;\n}\n\n.x-form-field-wrap .x-form-date-trigger{\n    background-image: url(" + escape(__webpack_require__(977)) + ");\n}\n\n.x-form-field-wrap .x-form-clear-trigger{\n    background-image: url(" + escape(__webpack_require__(978)) + ");\n}\n\n.x-form-field-wrap .x-form-search-trigger{\n    background-image: url(" + escape(__webpack_require__(979)) + ");\n}\n\n.x-trigger-wrap-focus .x-form-trigger{\n    border-bottom-color:#7eadd9;\n}\n\n.x-item-disabled .x-form-trigger-over{\n    border-bottom-color:#b5b8c8;\n}\n\n.x-item-disabled .x-form-trigger-click{\n    border-bottom-color:#b5b8c8;\n}\n\n.x-form-focus, textarea.x-form-focus{\n\tborder-color:#7eadd9;\n}\n\n.x-form-invalid, textarea.x-form-invalid{\n    background-color:#fff;\n\tbackground-image:url(" + escape(__webpack_require__(584)) + ");\n\tborder-color:#c30;\n}\n\n.ext-webkit .x-form-invalid{\n\tbackground-color:#fee;\n\tborder-color:#ff7870;\n}\n\n.x-form-inner-invalid, textarea.x-form-inner-invalid{\n    background-color:#fff;\n\tbackground-image:url(" + escape(__webpack_require__(584)) + ");\n}\n\n.x-form-grow-sizer {\n\tfont:normal 12px tahoma, arial, helvetica, sans-serif;\n}\n\n.x-form-item {\n    font:normal 12px tahoma, arial, helvetica, sans-serif;\n}\n\n.x-form-invalid-msg {\n    color:#c0272b;\n    font:normal 11px tahoma, arial, helvetica, sans-serif;\n    background-image:url(" + escape(__webpack_require__(980)) + ");\n}\n\n.x-form-empty-field {\n    color:gray;\n}\n\n.x-small-editor .x-form-field {\n    font:normal 11px arial, tahoma, helvetica, sans-serif;\n}\n\n.ext-webkit .x-small-editor .x-form-field {\n    font:normal 11px arial, tahoma, helvetica, sans-serif;\n}\n\n.x-form-invalid-icon {\n    background-image:url(" + escape(__webpack_require__(585)) + ");\n}\n\n.x-fieldset {\n    border-color:#b5b8c8;\n}\n\n.x-fieldset legend {\n    font:bold 11px tahoma, arial, helvetica, sans-serif;\n    color:#15428b;\n}\n", ""]);

// exports


/***/ }),
/* 976 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAIcAADFQizNRjDJSjDNSjDRTjTVTjTVTjjVUjTVUjkD/QH6t2bW4yK7Q467R46/Q46/R46/Q5LnP57DQ5LHQ5LXU5bzY6LzZ6NfZ38rb5svc5s7e6M/e6M/e6c/f6cXd+cbe+cff+cng+crg+svh+szi+s7j+s/k+tPh6tjl7dXl9tbl9tLj+NDl+tHl+9Pm+9Tn+9Xo+9Xq/9nn+N3z/+/v7+D0/+P2/+Xx+eb3/+ny9+zy+er4/+35//T09PT19fb29vD1+PH1+vD3+vL2+vH2/PH4//D7//P8//X4+vX5+vX5/fX5/vb5/fb6//b8//j4+Pn5+fr6+vv7+/j7/fn7/Pn9//r8/vv8/vz8/P39/fz9/vz+/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAkALAAAAABmABgAAAj/ABcIHEiw4IIEChIqXMhQAcKGEBM+jNhwIsWFFi9K1MKxo8ePFxZcGUmypMkICjCoXMmyJUqTMEu+jBkTZcubLFHS2MmzZ0+OC44IHUqUKBcuKXEqVRCjqdOnT7UgLUp16NGkSm8q8Mm1p48FRsKKHUsWaVacTKGqdYqUrNuxZs+23Nq1q5QFPPLq3cs3rtyVadeqRcq38F6/fzHQrevz7o7HkCNLRvw3sOCnSCVrjkxZ7mLGPO/iGE26tOnOZy1fborUtOvSqLMuxpIFC0/atnfetcG7ypYqvG34Bs7b74YOG1Zu4JAcsFMlVpSkiKECuhK2CoIP1/47uHHkypmz/6Qb5QCAAbaxDABwIIruBTVqOEFwvkqNKusROIkf9wQSKkickIF/AJ7gXAxEFHAeEzIwsV4BRLCmQHzz1XdffvvV0N9/AQ7IoYEqzbbeAFmMmBsNUSwww4r4nbfFiFWsOINZGgCh4ABJoJDEg0BoEGJTKygxohUjKrGChDK2OMCL9clIo43n5bgjAAX0GGJPUKwHwHlQ9PTDAh6E6cESWp63hJge3KBAAw9YIIQAAAgwBZwCCGHBAw0wYFkQAWwJQABBPKUmmmT6OcCZYqrJppt0zhmnnXjq6dMTIz7h05cfZJppoYdqmqmaDDDgQAVv+llnBQ6EqidUQ/QZwBBQqf/p6QecLjErqKKSCueWp6Ya6mc7PVGApZcuAMKxyDZhQBPIIotrrqX2quqqrBIAa6wKNHusssxq++yo0QqB6rTA7tRDV1+GoO66IRTB7rrPQkuAuL6qqlpTOqyl5rvqustvvODOOy65oBUrwsEIJ6xwvLnmMDC5q2Gr8MQJMzyqw/XaW7CXC4zg8ccgh8ywqBRkbG/EgioQ8sogj+xAydNqvPFOX5Jg880456wmBDz37PPP1KIcg5o5F43zzj8n3bOkM9PwZQlQRy311GpKYPXVWGcdNMpqTu211FVnLfbVTM/8pQlop6322mpO4PbbcMe9dcRqrm232m3HrffbZW91/CULgAcu+OB576333KupOfjighduONx9F/xlC5RXbvnljj/uNuKXqXn555ZnrnnkoH3pwumop6666I9zLpiaqseeOuuGk87Yly/krvvuvNO+t+v6KsD78Lv7fni5ty8Aw/LMN++88XLf27kCzlffPPSQKxAQADs="

/***/ }),
/* 977 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAIcAAED/QHeSt36t2YQAALW4yK7E7q7Q467R46/Q5LTJ4rbL5LnN5rnP57DQ5LHQ5LvQ6dHR0dLS0tPT09TU1NbW1tfX19fZ39nZ2dra2t3d3d7e3srb5sXd+cff+8nd9sve9c3f9M/g9Mvh/c3k/9Hh89Pi8tXj8d3z/9/0/+zs7O3t7e7u7u/v7+H1/+P2/+Xx+eb3/+j5/+r6//Dw8PHx8fT19fb29vr6+vv7+/v8/vz9/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAABmABgAAAj/AAkIHEiwIAEAAhIqXMhQAMKGEBM+jNhwIsWFFi9K1MGxo8ePFgjkGEmypEkGAjaoXMmyJUqTMEu+jBkTZcubLFHS2MmzZ0+OBEwIHUqUqI4dKXEqFVC06dCjAmRInUqV6g6kSpf63NqzRlCnTrFmvckUbFOkVdNaTTqWpYAZMwoEmEu3boEZOAiUKCG3rt8CJcS2XSlgb1+/dAEjjRHjMOIABWIIHrxBAAsWj/2yyEuCROa6JMQ6RlxApYDOn+mGFgADRuq5MESnLl15xYoAGnLn3qHhqoYAK/KGCIFbd+/evAOEEPs6gOnhxXXz9q0cqQsX0Xcj/+2C+WvTtrPr/x4w4HdwAiBAiM9N/jcI5saPUzedfr2G9gHeC2jRwj7+FvAZN11ypqmgQgAD9jbAVQMEoEJeH3yA4HY7LFhhAB8EGB9+pkU4oW8VMoghUiig8OF0FjaIgobGcVhZCimcqKCIKdxAgAceyBjihR4wl+CODZqGo44pBtCjACecQKSIJ/hIYZGmZZCBf+UFkIENBCSQAJW/JfCCAAccsOSFBxgggJZcBuClABxwkCYHX4Y5ZoNlCoABBjpuFwAGWCqgQJ7UKfClAQakSagAfgKanKACdNCBor91MGih8bFX5aEXXABpABdgucACmy4w6aaHfhrqlyKIsKkIo/6o56EVVP9gn24BVIDlAw/MmlsAD7RK4atm4qrrb70KMMIIwwYwgq8gAisABRRsSsGtubpKXbGEJnuosNYmV+yxmy4rQLaVGhfAoRNM0NwE1DaHbaHd/rZtrq99i+xr4mYb77lmSuDvvwAHTC2uBBdc8JcIINAcAsEa7DDBXx4r8cQUi5vwwmZGoPHGHHc88MMGf9nAyCSXbHLDIIdsbMUsi2vyyyWbCcHMNNds88cp4/qlAzz37PPPKOes88otU7zzz0j3LLPNTNOMc85HJ4100EJHXLTRAkid9NJNM/10ylFrrbQAQh9M9NXHhi22A1x3XfPXIKstNtVQn4223Fq37fbMcD8gjLfUdINt99V/by3A3jcTUDbEWa899uJDoz1x4VMLEBAAOw=="

/***/ }),
/* 978 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAIcAADB4sFh6sFl7sVp7sDCAwGGp0GKp0GKp0X6t2YGRsIGRsYGZsIGZsYCgwIGgwIGhwIGhwYCowICw0IGx0IGx0ZG40JG50JG50ZG44JG54LW4yK7Q467R46/Q46/Q5LTJ4rXJ4rbL5LnN5rDQ5LDR5LHQ5LDS5LXU5rbU5r3Q5rvQ6bzQ6bzR6b/S6LzY6NHR0dLS0tPT09TU1NbW1tfX19jY2NnZ2dra2tzc3N3d3d7e3sHS58HU68fY7cTd6srb5svc5sza7c/e6MXd+cff+8nd9sve9cre9s3f9NPc49Xc5NHc6tHd6tPe7NXe6tve4djf6NPf8tXf8tbf89fe8s/g9Mvh/czi+8/j+s3k/87l/9Ph6tvg79jl7d3q7tHh89Li89Pi8tLi9dPj9dXj8dfl89Tk99Dk/dLn/9fm+Nbo8dbp/9ni99ri9tnm9dzg8N3i89/j9d7n8tvn+tzm+tjo8tzo997o9dzs9trp+tvo+tnp/t/p/t/s+t7s/t3z/97z/9/0/+Pj4+zs7O3t7e7u7u/v7+Hl9uLl9OHs9+Tr9OLr+OPq+uHs+uTp+eTr/eTv+uXv+ubs/eft/ufv/+ju+Ojv/+nu/uru/OH1/+P2/+Xw/eXw/+fw/eT2/+X2/+b2/+b3/+nx+ury+ury/evy/Ovz/en0/+v1/+3z/O72/+/3/+j5/+r4/+r6//Dw8PHx8fLy8vPz8/D0/PH1/Pv8/vz9/gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAABmABgAAAj/ADUIHEiwoEAECBMqXMiwocOHECNKbGirosWLGG1pqMWxo8ePtRD8GEmypMkfCECq7JhypUqRJ2OORACrps2bOGFpIMOzp8+fZGDKPIkAqNGeCFwpXcq0qSuhQ0vSzEm15s6jRqFGnYk1q9OvS7VuRfCq7KuaZtGafaUhjNswZcq8jfvWrdioCOrSdbv3LQJWgFkpDTw4MKu7QxEYWhyLVqpYhmKlogV5sSENXzK7MdXJDRg3nUy5yZwZqhAhJE+bREB6c+fPoUeTRhCqdqtVqFqFaoVqle7aoUyjHqlaaqFCr2YZyFBKVqkMBma9Ol5IQ5UqY0gVwLDJziYMBUiN/7leReiWUZG2ANkSadQWqdezb+/+Pfz46wg0aQql6kCGU62cksEBqoSinybmoacee+4ZhxwmFhBgwSURWoDJdMdpgAQSYjxSAQEVTPJhBY+IsSESMAkhynaQdAEJeKIMh9KGHY4oIoglnohAJpl4QskFBFxgCZAXUOIJj5mkuCIGLb5YQIwkIUDIlK8oMgEAEgAwgSKvTDmlBkaEacYdV2Y5wR1mhBlmioyMKMmIjMiIgJpjlqklmmoagUAgfH6SCAVYAkBBIp/wySebbsIp5yCMDgILIhEEEAEisDTKqAZFZHpEGnFEGkEcaRyRaabmyWHnBHK8F+Wom3YqKaiijv+KwB+0AgLKIZ4eAgogtNJa6qmpSpXDsII48kAADQTwgCOCDDusBh98AMIOdDiAbAAO0LEDCNF+gAAH4JrgAxyewuGDCeBysAEC0U5b7bXZbtstAkPUiwUfEFwLAR9Y1Fvvt+GOW+656a57ww05LLJAAAs4sfACi+Rw8A0ahBBCCnowEAADS2jMgB4pWBwCAhts0IELcxyb7ANzuNBByetajLHHHW8MssgIEEHEFX543ITHflyhMxEkm4yyysq2/HLJCNhgAw6VDJDAG4I8kcAAleDgtA0aiCBCC40IoAAVQSihgACNtOC1CEWfkIfHTHicxwkwI+A12GKTbTbaanv/jYAVVpzBidht7AHF2ZycAbgVbb+9cdwbz103DZTr4AUXOtSgAxde6EA55RqooMIKPdQxRQ8s9DBFHT2sILoKbfchthQ+JHF2H3QzLTrppqOuOuuui45AFsSvgQcba2ixBht4rEE88bHPXvvtua87w/UzHIy99tjPEPruPPDg+grhBy98ySerEYULJLgQhRou1/06+eKPXv7rsD+fBRpoPM+//lkoWvrW1773xY9pMkigAhfIQBl8D38QhGDRTIYCFLysAxVcmu4iyEHhAfCDAJwgBi1IQRLWLQYoTKEKVxiDB3ZQgh6IoQxnSMN1vZCDwwOhDhFAwx7OcF0wCKIQoYdIRBi48IbCG4ESl8jEJtoQifjLoQ4/iIAmWpGJ63qBFrfIxS6+4IhIREAJxkjGMprxiVD04BSpaMY2ljGLXoyjFsF4QzG60Y1oTKMU1/g8O97xjAiQoxzp+EI//pGMeYTiHvkYwEMCUpBxJGQHDenIRIaRkfqj5CHhCEkuShKHjnwjAtL4ukXyUZN/5GQn50hK4YUSkaNspSnXiMo7risgADs="

/***/ }),
/* 979 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAIcAACxJcy5SiDVfnThnrjtorTxqsT1vsz9wsz5wtDx0tz52uD18ukVnlklolUhpmkJus0JvtEtxqURwtElztEp1tUx1tkx3uE54tk95uVB2tFF4tlF5uED/QDuEvjyEvzyMwkeDvUiDv0uFvlyCu12CvGyDn3GDnm6DoHCFonaMr3OLsHaUvXiVvUWKwkqGwEmMwkiNxEWRxUeUx0iTxUqUxkqVyFGLwVGMwVqXyFqYyWCUxmOdymSdynycyWyizXCkznat0niu1H6t2X6y1Hy016OuvrG1u4Cfy4qoz4Gv2o6314y514+825etwputxJOx1ZG525u515+415u+2p252qW0wKGzyqm0wa66yKC42KG/3aW92qS+3qi92bW4yJnA25jB35bD4JnU557V55zW6qrB3bTB17XD2bjL36jH4azD4q/L46HY66Ld7qTa6qfe7q7Q46/Q5Knb67TJ4bbL5LfM5LnK4LjL5LnN4rnO5r3O4bzP5bDQ5LXT5rXU5b7R4b3Q5rvQ6bnc6r7Z6L7f673f78TN3cjP18nQ2cjR3s/V3dLS0tfZ39nZ2d3d3cDP5sLQ4sHT5MPV5sXS5cfW58DS6cHU6sTT6MDZ6cLc6sTd68jV583X5srb5svc5srY68nZ7Mvc6cjf7Mza687e6M3c7sXd+crd9czf9Mjf+9DW4NHY49DZ5tfc49Dd6tDd7dXf7dne5Nze4dHf8MLi78jl787i7s7n78bo9M7g9Mrg+cvh/czi+83i/c3k/8vr9dLg7NTi69bh7dnj79nl7d3j6d7m7d/o79Lh8tDh9NXi8dXj9Nbk8tHm/tTk+Nfp/9jl8tnm9tzl8Njm+Nro9t7p8N3o9N/t9tjo+9nq/tvs/9zq+9zr/t3t/93z/9/0/+Hh4ePk5+Xl5eDk6eXn6ubo6+Xo7enp6e3t7eLp8eDq9eLs9uTq8+Xu9uHs+enu8+H1/+Xx+eX2/+vx9u7w8+/z9+rz+en5/+36//Hx8fX19fD7//H8//r6+vv8/v3+/iH5BAEAABwALAAAAABmABgAAAj/AL0IHEiwoBcOQhIqXMhQCMKGEBM+jNhwIsWFFi9K9Mexo8d/Hhl58UiyZB4hnVKqXMnyZMmXHF3CNImSpU2VJ/Pp3JlPn0+eHL0oGzqUGTRr6tRZgzbU37+aLD1J9cRSCNGiR5Mubfr0nlev+O7h24evrNd/T29OpbpSCM+e+mq5kXNL3059QokebVeIDBta65gqS7vSE6lgxIQFI8W2k1W91fj6BSy469ey/HC1efOLX9h7hFUaRqyYsUq3d48NmfHhA40vdvP184KsNrN1yoLEaC2DiTpoyEJ3OlxNkJgxhIiZdlwb2e3cuz/0/h1cyFex14jIaF0jzL6zUIcH/yt+PPlyIejS56P3owOPNWlwvJiiD91sZMmQUWPno8MO+Di0AIU6y4RGCjHAABFdDEsol5IQ+OnHn38ACkjgU/JkeI89P3jwXho5wABGWAYiqGBrDDroWHro5BPJAjrUE0ss89wggjGyeZFLLslQkweMMtJoQwjIQEOYJ8Ec099/8bWghINC7NjjjzHOOM+QRWIIjzz3WAKklTe4QA1oNSGpJIVNPknKiuptkUAZrRxyyDhPKKBHjqigkgs1VLwZ55xPJEAHNUcSgweQrQgJgivBeCJEnnv2CaecdApKqBDwZHqPFn4eggidCgBCZkqeGIqooow6ymI+XRiQRSyIqP9CDhIGQJLjKaegMg0VrsIqK610TFNoFJ0CmsAcxDiGSq679hrrrAYE+9Q31MrDhbO/IgCIPMMWWymyK57TIicFVJCOOeYII4EG5txqiq6XlHtuuhJYwIwzhUphgBS+QouGMI7ieso08ZqLrrr24iuENwzL84m8B0uAwTXclkmMvvw+S+u/jjriCDjnsPLAAA8c0cMDE5xxjiN4zTHHHq9sMnLJJ0uwxSh3xCMEHHDwockeENNLQSiD8CGEyzDLTLLJD9iMs86mmKLLNp9AsHTNamCji848+wy0wUITbXQjjoizigYEjEDA2hmYIY4jjeBVByClTHLBAGqvXUEXpQD/QgfXcPhhCyUzM22zKH7AIQQddNuN99oE7N3330Kkwks2o2wwAAlrF3BB1rykArjghF/d9BaIK162KhEIwAI6xRiSyDhvNxK3F5W8MknrK7ADix16wPJKJXnkwbUfokhyd94EUIB6HzwLkfvuAvT+e/DDF69zL9x80joL80DzyCXWcNPLLrtw3Ufyy0PuvCjQq65IAwGkQI444OQPju224wUKJAwIgAqkoYxXlKIUoLBEIBaoM+RFgnfpAAYa9GAL+PEMDkn4XwAHWMADJnCBgYhHEp7xCQcIcB3d6EY2tPGMZvjihTpb3wOrF8EJVjB+igNHEQBggvvxrxGLACIQ//FSCicA4ATSmIUCQchEEQ7iDxskhi00kYlMDCJxF0xCEY+YxCUykYFJyIYVAIACd3TDhS9MIwyT8MQoTrGKV7yg6mRhhHDsbxF4zGMe/eeKKwxDiV9sYhIy0QQAlIAYiOODIvkgRwyCoo9/9GIgRfiMaGBBHWdUoyZFSEhDItIPi2SkHIVgO48BUY+oxEslQIFASU6SjaGoQjDgx4c42PKWtlTcKlsZyCYKoRnPyEYLNblJWMqSlrjEpeJQyUw95sMLvYxmDDGhCUz0IZTYZKQQotlLnRHzmzAUQh+oac1shnKZzWwmXrg5SSEo8prmPOc22elLcH5TZ++MpzzT2WPMZ9LTl/rMpuL+CUJv2nOT7gzoPvmZSmgSNIQJVagiB/rQ7R1UjfiU6ESFwFBU+rOiEZUoRQlq0IuGU6Mb7age1wlSlGrzoRDthUlPilJ0qnQRHyVpSBU60n+W1KQZ1ajiAgIAOw=="

/***/ }),
/* 980 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAAAAAHBQEHBYEEBAQGRiYkD/QIBYEJBwEJBoIJBwIJB4IKB4EKB4IKCAELCIIMCYENCQENCgINCoMOCoAOCwAOC4AOC4EPC4MOC4UODAEODIEPDAEPDIEPDQEPDYEPDQIPDYIPDQMPDgIPDoIPDoMODAUPDoQPDwUPDwYPDwcIWEgIWPm42VnZCYnpSboJieoZqfqaCquKWwuq21u7S2tra5tre9tra9ub2+t77EutPOsvDIgPD4gPD4kPD4oMDAwMfLxc3Uz8/Uz9LSwdDVz9XVydbY0AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAUALAAAAAAQABAAAAidAAsIHEiwoMECQSRAyHGQoJASPVI8uNGwAJESOwgQuNBgxsEhJXwQ+EFgAIkGMgrqCNlj5AAAI0QsiDHQCEseGl+K6KDhAAyBGHz04IHiBwAAPzxwsDAhgMAiEVKgOGGCAIAMSykIWDEQiAMTJkL8+LEhA4UAKgriYEDix8sfZ1kctKEAhNWmLSrWSPChQgAXFQXSQGDgReDDiAsGBAA7"

/***/ }),
/* 981 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(982);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 982 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-btn{\r\n\tfont:normal 11px tahoma, verdana, helvetica;\r\n}\r\n\r\n.x-btn button{\r\n    font:normal 11px arial,tahoma,verdana,helvetica;\r\n    color:#333;\r\n}\r\n\r\n.x-btn em {\r\n    font-style:normal;\r\n    font-weight:normal;\r\n}\r\n\r\n.x-btn-tl, .x-btn-tr, .x-btn-tc, .x-btn-ml, .x-btn-mr, .x-btn-mc, .x-btn-bl, .x-btn-br, .x-btn-bc{\r\n\tbackground-image:url(" + escape(__webpack_require__(983)) + ");\r\n}\r\n\r\n.x-btn-click .x-btn-text, .x-btn-menu-active .x-btn-text, .x-btn-pressed .x-btn-text{\r\n    color:#000;\r\n}\r\n\r\n.x-btn-disabled *{\r\n\tcolor:gray !important;\r\n}\r\n\r\n.x-btn-mc em.x-btn-arrow {\r\n    background-image:url(" + escape(__webpack_require__(984)) + ");\r\n}\r\n\r\n.x-btn-mc em.x-btn-split {\r\n    background-image:url(" + escape(__webpack_require__(985)) + ");\r\n}\r\n\r\n.x-btn-over .x-btn-mc em.x-btn-split, .x-btn-click .x-btn-mc em.x-btn-split, .x-btn-menu-active .x-btn-mc em.x-btn-split, .x-btn-pressed .x-btn-mc em.x-btn-split {\r\n    background-image:url(" + escape(__webpack_require__(586)) + ");\r\n}\r\n\r\n.x-btn-mc em.x-btn-arrow-bottom {\r\n    background-image:url(" + escape(__webpack_require__(587)) + ");\r\n}\r\n\r\n.x-btn-mc em.x-btn-split-bottom {\r\n    background-image:url(" + escape(__webpack_require__(986)) + ");\r\n}\r\n\r\n.x-btn-over .x-btn-mc em.x-btn-split-bottom, .x-btn-click .x-btn-mc em.x-btn-split-bottom, .x-btn-menu-active .x-btn-mc em.x-btn-split-bottom, .x-btn-pressed .x-btn-mc em.x-btn-split-bottom {\r\n    background-image:url(" + escape(__webpack_require__(588)) + ");\r\n}\r\n\r\n.x-btn-group-header {\r\n    color: #3e6aaa;\r\n}\r\n\r\n.x-btn-group-tc {\r\n\tbackground-image: url(" + escape(__webpack_require__(394)) + ");\r\n}\r\n\r\n.x-btn-group-tl {\r\n\tbackground-image: url(" + escape(__webpack_require__(377)) + ");\r\n}\r\n\r\n.x-btn-group-tr {\r\n\tbackground-image: url(" + escape(__webpack_require__(377)) + ");\r\n}\r\n\r\n.x-btn-group-bc {\r\n\tbackground-image: url(" + escape(__webpack_require__(394)) + ");\r\n}\r\n\r\n.x-btn-group-bl {\r\n\tbackground-image: url(" + escape(__webpack_require__(377)) + ");\r\n}\r\n\r\n.x-btn-group-br {\r\n\tbackground-image: url(" + escape(__webpack_require__(377)) + ");\r\n}\r\n\r\n.x-btn-group-ml {\r\n\tbackground-image: url(" + escape(__webpack_require__(589)) + ");\r\n}\r\n.x-btn-group-mr {\r\n\tbackground-image: url(" + escape(__webpack_require__(589)) + ");\r\n}\r\n\r\n.x-btn-group-notitle .x-btn-group-tc {\r\n\tbackground-image: url(" + escape(__webpack_require__(394)) + ");\r\n}", ""]);

// exports


/***/ }),
/* 983 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64, "

/***/ }),
/* 984 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAKAIcAAAAAAP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAEALAAAAAAKAAoAAAgZAAMIHEiwoMGDCA0CWLhQYcODABJKnFgwIAA7"

/***/ }),
/* 985 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDgBIAIcAAAAAAMnJycLa9vX19QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAIALAAAAAAOAEgAAAiGAAUEGCCgoMGDBQciXCiQIMODCh8ajCixYcWEDitSlLjxYUeGHxeGRDgSYkaOJz2mBLlSZEuSL01etHix5MSYN2faxKgTJ8+aPmlqDLpTKMqeSAsCWLpUpkGmMBECcJl0aNWjQK+q1MqSK9WsYK2GxSq2LNmzW8emNbsWbVe1b9nGdftVYkAAOw=="

/***/ }),
/* 986 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhyAAOAIcAAAAAAMTExMLa9v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAIALAAAAADIAA4AAAiGAAUIHEiwoMGDCBMqXMiwocOHECNKnKgwgMWLGDNq3Mixo8ePIEOKHEmypMmTHgeoXMmypcuXMGPKnEmzps2bOHPq3CmTos+fQIMKHUq0qNGjSJMqXcq0qdOnUKNKnUq1qtWrBgFo1Yq1q9evAreCHUt2KoCyaNOqXcu2rdu3cOPKnUuXbEAAOw=="

/***/ }),
/* 987 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(988);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 988 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-toolbar{\r\n\tborder-color:#a9bfd3;\r\n    background-color:#d0def0;\r\n    background-image:url(" + escape(__webpack_require__(218)) + ");\r\n}\r\n\r\n.x-toolbar td,.x-toolbar span,.x-toolbar input,.x-toolbar div,.x-toolbar select,.x-toolbar label{\r\n    font:normal 11px arial,tahoma, helvetica, sans-serif;\r\n}\r\n\r\n.x-toolbar .x-item-disabled {\r\n\tcolor:gray;\r\n}\r\n\r\n.x-toolbar .x-item-disabled * {\r\n\tcolor:gray;\r\n}\r\n\r\n.x-toolbar .x-btn-mc em.x-btn-split {\r\n    background-image:url(" + escape(__webpack_require__(989)) + ");\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-mc em.x-btn-split, .x-toolbar .x-btn-click .x-btn-mc em.x-btn-split,\r\n.x-toolbar .x-btn-menu-active .x-btn-mc em.x-btn-split, .x-toolbar .x-btn-pressed .x-btn-mc em.x-btn-split\r\n{\r\n    background-image:url(" + escape(__webpack_require__(586)) + ");\r\n}\r\n\r\n.x-toolbar .x-btn-mc em.x-btn-split-bottom {\r\n    background-image:url(" + escape(__webpack_require__(587)) + ");\r\n}\r\n\r\n.x-toolbar .x-btn-over .x-btn-mc em.x-btn-split-bottom, .x-toolbar .x-btn-click .x-btn-mc em.x-btn-split-bottom,\r\n.x-toolbar .x-btn-menu-active .x-btn-mc em.x-btn-split-bottom, .x-toolbar .x-btn-pressed .x-btn-mc em.x-btn-split-bottom\r\n{\r\n    background-image:url(" + escape(__webpack_require__(588)) + ");\r\n}\r\n\r\n.x-toolbar .xtb-sep {\r\n\tbackground-image: url(" + escape(__webpack_require__(990)) + ");\r\n}\r\n\r\n.x-tbar-page-first{\r\n\tbackground-image: url(" + escape(__webpack_require__(991)) + ") !important;\r\n}\r\n\r\n.x-tbar-loading{\r\n\tbackground-image: url(" + escape(__webpack_require__(992)) + ") !important;\r\n}\r\n\r\n.x-tbar-page-last{\r\n\tbackground-image: url(" + escape(__webpack_require__(993)) + ") !important;\r\n}\r\n\r\n.x-tbar-page-next{\r\n\tbackground-image: url(" + escape(__webpack_require__(590)) + ") !important;\r\n}\r\n\r\n.x-tbar-page-prev{\r\n\tbackground-image: url(" + escape(__webpack_require__(591)) + ") !important;\r\n}\r\n\r\n.x-item-disabled .x-tbar-loading{\r\n\tbackground-image: url(" + escape(__webpack_require__(376)) + ") !important;\r\n}\r\n\r\n.x-item-disabled .x-tbar-page-first{\r\n\tbackground-image: url(" + escape(__webpack_require__(994)) + ") !important;\r\n}\r\n\r\n.x-item-disabled .x-tbar-page-last{\r\n\tbackground-image: url(" + escape(__webpack_require__(995)) + ") !important;\r\n}\r\n\r\n.x-item-disabled .x-tbar-page-next{\r\n\tbackground-image: url(" + escape(__webpack_require__(592)) + ") !important;\r\n}\r\n\r\n.x-item-disabled .x-tbar-page-prev{\r\n\tbackground-image: url(" + escape(__webpack_require__(593)) + ") !important;\r\n}\r\n\r\n.x-paging-info {\r\n    color:#444;\r\n}\r\n\r\n.x-toolbar-more-icon {\r\n    background-image: url(" + escape(__webpack_require__(996)) + ") !important;\r\n}", ""]);

// exports


/***/ }),
/* 989 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDgBIAIcAAAAAAMnJycLa9vX19QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAIALAAAAAAOAEgAAAg8AAUIHEiwoMGDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePAEKGVCiSIYCPKFOqXMmypcuXMGPKnBkQADs="

/***/ }),
/* 990 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgANAIcAAJrG/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACAA0AAAgOAAEEEEhwoMGCCA8GCAgAOw=="

/***/ }),
/* 991 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAACRIkChNli1TnjNZpjhgrz9otx1m9S9kzy9l0yxm2DBiyDFq2zhu3D5z2z913SRq8ixx7jRy6D5++URvwEJt1Ep1yE970Eh630574UD/QFOA1lOE3VWF3liH30+K9k+J/VGD4VeH4FaE6VmK4l+L4F+M4WCM5GWP62mR42iU5WuT62+W7G2Z5mec+2ma/2ic+XGa536f7oKg54Wu/42r8Iiu/5a076G+8KK9/6W//6rE7wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAABkALAAAAAAQABAAAAh6ADMIHEiwoMGDB2HIQGEwhEEWOhwSJKHBYIobFQeWyGHBoAkbHQV2yOGigsERNExm4JBjxocJBkHEgLkBR40XEgoYvLBCZ4YGLTxAIGDQgQqiAg9EeDDAIIMTTQcqMCDA4AIRVQkiCGAwAQauBQEYpABALMKzaNMODAgAOw=="

/***/ }),
/* 992 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAABBYsRhcvRhuzhR0xiBxzyZ4zyd70yd71SR72Cp50Dd3yTp/zT16yEN5w0J8x1J+whqI3BqA7ByQ+CKA1iqA0iyE0SqC2jyK1iyL5SqV/CqX/zSL4jqh/z2n/0qHyEqMzkqH1UqG20+J1kKQ30qS1liOzVaR3VSb10Sa4Eyf6VKf40uh4Uii60On/0it/0+u/1Kj4Vqk6lew/1my/2Wb3Wuc1W+c2nCNx26n3G6q33Sj3GCm7G+q5Guz72O3/3ax53a3+HS+/3W+/3W//3nB/37D/4Wl1oOn25Sx3YWp4Iq1442y4Y+66JC+552+5ojC74XC/YjK/47J/5TM/5bM/5jP/5vM/p7P/5/P/6XA5qHK763C5KzE6arM7KDT/6LR/6HU/6TS/6DZ/7TM6rDU87Df/7fc/73W87Hg/7rk/73g/7zi/7zl/8Tb9MTd9s7d88Dk/8Xi/87k99bh9Nbm9tHp/9rm9uPr+eXz/+b0/+vy/O31/Pb7//j5/P3+//7+/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAIAALAAAAAAQABAAAAiuAAEJHEiwoMEmKCZQ+DDG4MAeEjJwaDHkgBOHWiA8IfMDgwwiCeaYCEGQR56BbjYIiQLAigKHA5cAmVKlTAOYgPQYWeDlC5oHArusgMEihQo5NcSwgbMmzQ2BOPDEMQOmSI43NESA8OBgi8ATdcJgqaDEYJ+BJNRcobKDCU5AF6AMkBLEQpuBd5IQHBGDTgEfMxDo4HIkQBaHZwy8cNFBQwQbOO2UICCAAZK3mAMCADs="

/***/ }),
/* 993 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAACRIkChNli1TnjNZpjhgrz9otx1m9S9kzy9l0yxm2DBiyDFq2zhu3D5z2z913SRq8ixx7jRy6D5++URvwEJt1Ep1yE970Eh630574UD/QFOA1lOE3VWF3liH30+K9k+J/VGD4VeH4FaE6VmK4l+L4F+M4WCM5GWP62mR42iU5WuT62+W7G2Z5mec+2ma/2ic+XGa536f7oKg54Wu/42r8Iiu/5a076G+8KK9/6W//6rE7wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAABkALAAAAAAQABAAAAh4ADMIHEiwoMGDB2EYhCEDhUEWJAqy0BHCYAocEQemuKHBoAkcNSgMNGHDgsERNl60EJlhBI0KBkHQaAEhwYAMIGJMMHgBRk0AAi+sKGDQAYgEQAU6UEHAIAMKSQUyOHGz4IKoAheIEGAwQVcMARAWhIpVrNmzGQICADs="

/***/ }),
/* 994 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAGdnZ2xsbHJycnh4eH9/f0D/QIODg4WFhYaGhoeHh4uLi42NjY6Ojo+Pj5KSkpOTk5SUlJmZmZubm56enp+fn6GhoaOjo6SkpKenp6ioqKmpqaqqqq2tra+vr7GxsbS0tLW1tbe3t7i4uLm5ub29vb6+vsnJycvLy9HR0dra2tvb293d3eDg4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAUALAAAAAAQABAAAAh6AAsIHEiwoMGDB0OU6GDwgkEQLBwSzDDBoIcUFQdqWBHB4AYUHQVeWCHigUEMJkwWsLDihIYFBiuQgFlBxYkRFBAYjPBBZ4EHIzI4IGAQggeiAg88YDDAYAMOTQcaUCDAoAILVQkiCGAwgQSuBQEYZABALMKzaNMODAgAOw=="

/***/ }),
/* 995 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAGdnZ2xsbHJycnh4eH9/f0D/QIaGhoeHh4uLi42NjY6Ojo+Pj5KSkpOTk5SUlJmZmZubm56enqGhoaOjo6SkpKenp6ioqKqqqq2tra+vr7GxsbS0tLW1tbe3t7m5ub29vb6+vsnJycvLy9HR0dra2tvb2+Dg4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAUALAAAAAAQABAAAAh4AAsIHEiwoMGDBzsY7AAig0EOFgpyMEHBoIYSEQdqIBHB4IUSIhQMvDDigcEKIzx4EFmgQogGBiWE8MDgwIACEj4kMPigQ00AAh9sMGDQgYQDQAU60EDA4AIFSQUuwHCzIIKoAhFMEGDwQFcIARAWhIpVrNmzBQICADs="

/***/ }),
/* 996 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDAAQAIcAABVCi0D/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAMABAAAAgqAAMIHEiwoMGDCBMqXIgQAACBDg9GDDCx4MSKEB9S1DjwIkeGIEOKPBgQADs="

/***/ }),
/* 997 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(998);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 998 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-resizable-handle {\r\n\tbackground-color:#fff;\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-east, .x-resizable-pinned .x-resizable-handle-east,\r\n.x-resizable-over .x-resizable-handle-west, .x-resizable-pinned .x-resizable-handle-west\r\n{\r\n    background-image:url(" + escape(__webpack_require__(999)) + ");\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-south, .x-resizable-pinned .x-resizable-handle-south,\r\n.x-resizable-over .x-resizable-handle-north, .x-resizable-pinned .x-resizable-handle-north\r\n{\r\n    background-image:url(" + escape(__webpack_require__(594)) + ");\r\n}\r\n\r\n.x-resizable-over .x-resizable-handle-north, .x-resizable-pinned .x-resizable-handle-north{\r\n    background-image:url(" + escape(__webpack_require__(594)) + ");\r\n}\r\n.x-resizable-over .x-resizable-handle-southeast, .x-resizable-pinned .x-resizable-handle-southeast{\r\n    background-image:url(" + escape(__webpack_require__(1000)) + ");\r\n}\r\n.x-resizable-over .x-resizable-handle-northwest, .x-resizable-pinned .x-resizable-handle-northwest{\r\n    background-image:url(" + escape(__webpack_require__(1001)) + ");\r\n}\r\n.x-resizable-over .x-resizable-handle-northeast, .x-resizable-pinned .x-resizable-handle-northeast{\r\n    background-image:url(" + escape(__webpack_require__(1002)) + ");\r\n}\r\n.x-resizable-over .x-resizable-handle-southwest, .x-resizable-pinned .x-resizable-handle-southwest{\r\n    background-image:url(" + escape(__webpack_require__(1003)) + ");\r\n}\r\n.x-resizable-proxy{\r\n    border-color:#3b5a82;\r\n}\r\n.x-resizable-overlay{\r\n    background-color:#fff;\r\n}\r\n", ""]);

// exports


/***/ }),
/* 999 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgDQB4cAAHas8sPa+cre+tDj/Nbo/d3s/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAKANAHAAj/AAsQGCAggMGDAgkeRDiw4MIACR0ujPgQYsOKFB9mnHhRY0eOCj2GBCmR4UiTJQ1uRInxI0uRKS2eVOmS5kyZMVfazFkTZ8ubOn3C/MkTaM+gSI8qNcq0qFOiUIdKJRmV6tSXVrNi3bqzKlehWrteFRsW7NekTb2SPbv06Viza+PCnYvWbdm6aum2zYv3bd+7e/0GBpxWcGHCdtkeVpxY7l/GfAdDNtxY72LHkjFftlz5sebOmTlH3uxZNOXRoEmHLs16tWvVsFPLRk37tG3EtXHfnqy7N+/fn3MDN+07+G7jxYkPbx1bOPLlr2cfV/68OvXrzKUnz+4ce/Tu3KeH/9/+XXx58s3Np0evHfp69+2tj4cP/jx99fG9v5dvn/9+/fnN51+A/QFY338CGojfgQQiWGCCED4ooYMUNmghgxguqCF7GXK44X0ehgjiiAN2SKKCIpb4oYoponhihBWayOKLE164oosz5ojjjjDa2GKPMvJYY5BA3ljkj0MamSSSMSrZJJM+0viklFHqeCSVRC6JpZNVCjmllVqC+aWXXV4pZplhkpnlmGaqyeWaaLKZZpt0zmmnnHjGqSecfL7pJ5R9AvrnloIWSuihZwaKqJuGJjqoo40yumideSoK6aR37vmopJd2yumnlGoaaaiWgpppqaRumuqop6ra6o8AAP+QU6wGtGRArX7FOisAuHJ0K0YVIaQrRrTa2itCwao0rEbFevSrq5VCKyqm0bJaLbXTeroqtqi+yq203V6rrbfjimuquduWm+2566bLbrjtkvsuuPRaGy+68rqrb7784uvvvQDDK3C939o7sMEEq3twwQwrnPC8CEfcMMQT7/vvwg5LnHHF/Qb8sMUea0zxxiSPbDLIGJ/cccoof7yyyxfDHDLHMYvcss0v41wzzTOXfDPPLOcMtMxB7+yz0EcbrbLSPyfd89JPNw110VEjPTXRWOtcNdNWS+1112BzLfbWZFNtdtZDa3222mg7vXbacLvd9tVs1x033Xd/PfbbctsP3XfeYZc9t96C+423pwEBADs="

/***/ }),
/* 1000 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAKAIcAAHas8sPa+cnd+tDj/NPl/dbo/djp/tnq/tzr/t3s/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAKAAoAAAgyABMgMAAAwIAACAMgOFCgoIKEAQwUIDBAwcOEBQcUFADRoUOIFRUIsAixpMmTKFOWDAgAOw=="

/***/ }),
/* 1001 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAKAIcAAHas8sPa+cnd+tDj/NPl/dbo/djp/tnq/tzr/t3s/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAKAAoAAAgyAAMIHEiwoMGDCBEqUCBg4QCCCgAAiAiAoACJAyRCVDCAQAEDECUWOICAYEYABhAkCAgAOw=="

/***/ }),
/* 1002 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAKAIcAAHas8sPa+cnd+tDj/NPl/dbo/djp/tnq/tzr/t3s/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAKAAoAAAgzAAMIHEiwoMGDCAkOUKBAAEOCAAAoiKgAIoABEQUQNFCAwMKKAxEcKECRYAIEBiIOIBgQADs="

/***/ }),
/* 1003 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAKAIcAAHas8sPa+cnd+tDj/NPl/dbo/djp/tnq/tzr/t3s/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAKAAoAAAg0AAMIDDAAAAADCBIMDKDAYIEDCBYqUDCAQAEDCwUYLAhAosGGHQdOFDBxwMKTKFOqXBkgIAA7"

/***/ }),
/* 1004 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1005);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1005 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-grid3 {\r\n    background-color:#fff;\r\n}\r\n\r\n.x-grid-panel .x-panel-mc .x-panel-body {\r\n    border-color:#99bbe8;\r\n}\r\n\r\n.x-grid3-hd-row td, .x-grid3-row td, .x-grid3-summary-row td{\r\n\tfont:normal 11px arial, tahoma, helvetica, sans-serif;\r\n}\r\n\r\n.x-grid3-hd-row td {\r\n    border-left-color:#eee;\r\n    border-right-color:#d0d0d0;\r\n}\r\n\r\n.x-grid-row-loading {\r\n    background-color: #fff;\r\n    background-image:url(" + escape(__webpack_require__(1006)) + ");\r\n}\r\n\r\n.x-grid3-row {\r\n    border-color:#ededed;\r\n    border-top-color:#fff;\r\n}\r\n\r\n.x-grid3-row-alt{\r\n\tbackground-color:#fafafa;\r\n}\r\n\r\n.x-grid3-row-over {\r\n\tborder-color:#ddd;\r\n    background-color:#efefef;\r\n    background-image:url(" + escape(__webpack_require__(1007)) + ");\r\n}\r\n\r\n.x-grid3-resize-proxy {\r\n    background-color:#777;\r\n}\r\n\r\n.x-grid3-resize-marker {\r\n    background-color:#777;\r\n}\r\n\r\n.x-grid3-header{\r\n    background-color:#f9f9f9;\r\n\tbackground-image:url(" + escape(__webpack_require__(232)) + ");\r\n}\r\n\r\n.x-grid3-header-pop {\r\n    border-left-color:#d0d0d0;\r\n}\r\n\r\n.x-grid3-header-pop-inner {\r\n    border-left-color:#eee;\r\n    background-image:url(" + escape(__webpack_require__(1008)) + ");\r\n}\r\n\r\ntd.x-grid3-hd-over, td.sort-desc, td.sort-asc, td.x-grid3-hd-menu-open {\r\n    border-left-color:#aaccf6;\r\n    border-right-color:#aaccf6;\r\n}\r\n\r\ntd.x-grid3-hd-over .x-grid3-hd-inner, td.sort-desc .x-grid3-hd-inner, td.sort-asc .x-grid3-hd-inner, td.x-grid3-hd-menu-open .x-grid3-hd-inner {\r\n    background-color:#ebf3fd;\r\n    background-image:url(" + escape(__webpack_require__(233)) + ");\r\n\r\n}\r\n\r\n.sort-asc .x-grid3-sort-icon {\r\n\tbackground-image: url(" + escape(__webpack_require__(1009)) + ");\r\n}\r\n\r\n.sort-desc .x-grid3-sort-icon {\r\n\tbackground-image: url(" + escape(__webpack_require__(1010)) + ");\r\n}\r\n\r\n.x-grid3-cell-text, .x-grid3-hd-text {\r\n\tcolor:#000;\r\n}\r\n\r\n.x-grid3-split {\r\n\tbackground-image: url(" + escape(__webpack_require__(1011)) + ");\r\n}\r\n\r\n.x-grid3-hd-text {\r\n\tcolor:#15428b;\r\n}\r\n\r\n.x-dd-drag-proxy .x-grid3-hd-inner{\r\n    background-color:#ebf3fd;\r\n\tbackground-image:url(" + escape(__webpack_require__(233)) + ");\r\n\tborder-color:#aaccf6;\r\n}\r\n\r\n.col-move-top{\r\n\tbackground-image:url(" + escape(__webpack_require__(1012)) + ");\r\n}\r\n\r\n.col-move-bottom{\r\n\tbackground-image:url(" + escape(__webpack_require__(1013)) + ");\r\n}\r\n\r\n.x-grid3-row-selected {\r\n\tbackground-color: #dfe8f6 !important;\r\n\tbackground-image: none;\r\n\tborder-color:#a3bae9;\r\n}\r\n\r\n.x-grid3-cell-selected{\r\n\tbackground-color: #b8cfee !important;\r\n\tcolor:#000;\r\n}\r\n\r\n.x-grid3-cell-selected span{\r\n\tcolor:#000 !important;\r\n}\r\n\r\n.x-grid3-cell-selected .x-grid3-cell-text{\r\n\tcolor:#000;\r\n}\r\n\r\n.x-grid3-locked td.x-grid3-row-marker, .x-grid3-locked .x-grid3-row-selected td.x-grid3-row-marker{\r\n    background-color:#ebeadb !important;\r\n    background-image:url(" + escape(__webpack_require__(1014)) + ") !important;\r\n    color:#000;\r\n    border-top-color:#fff;\r\n    border-right-color:#6fa0df !important;\r\n}\r\n\r\n.x-grid3-locked td.x-grid3-row-marker div, .x-grid3-locked .x-grid3-row-selected td.x-grid3-row-marker div{\r\n    color:#15428b !important;\r\n}\r\n\r\n.x-grid3-dirty-cell {\r\n    background-image:url(" + escape(__webpack_require__(595)) + ");\r\n}\r\n\r\n.x-grid3-topbar, .x-grid3-bottombar{\r\n\tfont:normal 11px arial, tahoma, helvetica, sans-serif;\r\n}\r\n\r\n.x-grid3-bottombar .x-toolbar{\r\n\tborder-top-color:#a9bfd3;\r\n}\r\n\r\n.x-props-grid .x-grid3-td-name .x-grid3-cell-inner{\r\n\tbackground-image:url(" + escape(__webpack_require__(234)) + ") !important;\r\n    color:#000 !important;\r\n}\r\n\r\n.x-props-grid .x-grid3-body .x-grid3-td-name{\r\n    background-color:#fff !important;\r\n    border-right-color:#eee;\r\n}\r\n\r\n.xg-hmenu-sort-asc .x-menu-item-icon{\r\n\tbackground-image: url(" + escape(__webpack_require__(1015)) + ");\r\n}\r\n\r\n.xg-hmenu-sort-desc .x-menu-item-icon{\r\n\tbackground-image: url(" + escape(__webpack_require__(1016)) + ");\r\n}\r\n\r\n.xg-hmenu-lock .x-menu-item-icon{\r\n\tbackground-image: url(" + escape(__webpack_require__(1017)) + ");\r\n}\r\n\r\n.xg-hmenu-unlock .x-menu-item-icon{\r\n\tbackground-image: url(" + escape(__webpack_require__(1018)) + ");\r\n}\r\n\r\n.x-grid3-hd-btn {\r\n    background-color:#c3daf9;\r\n    background-image:url(" + escape(__webpack_require__(1019)) + ");\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-expander {\r\n    background-image:url(" + escape(__webpack_require__(234)) + ");\r\n}\r\n\r\n.x-grid3-row-expander {\r\n    background-image:url(" + escape(__webpack_require__(1020)) + ");\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-checker {\r\n    background-image: url(" + escape(__webpack_require__(234)) + ");\r\n}\r\n\r\n.x-grid3-row-checker, .x-grid3-hd-checker {\r\n    background-image:url(" + escape(__webpack_require__(1021)) + ");\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-numberer {\r\n    background-image:url(" + escape(__webpack_require__(234)) + ");\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-numberer .x-grid3-cell-inner {\r\n\tcolor:#444;\r\n}\r\n\r\n.x-grid3-body .x-grid3-td-row-icon {\r\n    background-image:url(" + escape(__webpack_require__(234)) + ");\r\n}\r\n\r\n.x-grid3-body .x-grid3-row-selected .x-grid3-td-numberer,\r\n.x-grid3-body .x-grid3-row-selected .x-grid3-td-checker,\r\n.x-grid3-body .x-grid3-row-selected .x-grid3-td-expander {\r\n\tbackground-image:url(" + escape(__webpack_require__(1022)) + ");\r\n}\r\n\r\n.x-grid3-check-col {\r\n\tbackground-image:url(" + escape(__webpack_require__(596)) + ");\r\n}\r\n\r\n.x-grid3-check-col-on {\r\n\tbackground-image:url(" + escape(__webpack_require__(597)) + ");\r\n}\r\n\r\n.x-grid-group, .x-grid-group-body, .x-grid-group-hd {\r\n    zoom:1;\r\n}\r\n\r\n.x-grid-group-hd {\r\n    border-bottom-color:#99bbe8;\r\n}\r\n\r\n.x-grid-group-hd div.x-grid-group-title {\r\n    background-image:url(" + escape(__webpack_require__(1023)) + ");\r\n    color:#3764a0;\r\n    font:bold 11px tahoma, arial, helvetica, sans-serif;\r\n}\r\n\r\n.x-grid-group-collapsed .x-grid-group-hd div.x-grid-group-title {\r\n    background-image:url(" + escape(__webpack_require__(1024)) + ");\r\n}\r\n\r\n.x-group-by-icon {\r\n    background-image:url(" + escape(__webpack_require__(598)) + ");\r\n}\r\n\r\n.x-cols-icon {\r\n    background-image:url(" + escape(__webpack_require__(1025)) + ");\r\n}\r\n\r\n.x-show-groups-icon {\r\n    background-image:url(" + escape(__webpack_require__(598)) + ");\r\n}\r\n\r\n.x-grid-empty {\r\n    color:gray;\r\n    font:normal 11px tahoma, arial, helvetica, sans-serif;\r\n}\r\n\r\n.x-grid-with-col-lines .x-grid3-row td.x-grid3-cell {\r\n    border-right-color:#ededed;\r\n}\r\n\r\n.x-grid-with-col-lines .x-grid3-row-selected {\r\n\tborder-top-color:#a3bae9;\r\n}", ""]);

// exports


/***/ }),
/* 1006 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhKQAJAIUAAAAAAJa425e525u83Zu83Jy83Jy93Z693p++3qG/36C/3qHA36LB36HB36LB3qPC4KbD4KXD4KfE4anF4qrG4qvH4q3J463I467J47LL5bPM5bXN5rTN5rXO5rfP5rjQ57nQ57rR57rR6MPU5cTU5cbW5tra2tzc3N/f3+Hh4eLi4uPj4+Xl5ebm5ufn5+jo6Onp6evr6+zs7O3t7e7u7u/v7/Dw8PT09PX19fb29vf39/n5+fr6+v///4CAgAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQJGQA+ACwAAAAAKQAJAAcIzwB9CBxIsKDBgwgPlliQIEGJgTVYrFhRA6JEihYnVhQYUePAEhQ8fMggYYSPGjJ28LgBg8bJlCtbvlTJ0iVKmjJ9KOgQQsSGCgN8rNDBg0eOGSiEEjWKVGnRo0mHPm3q44AGEBwwPBDgIwUOozZcnOj6NUfYsV7BiiWrdqwPBBYuTGCwgIAPFTZqxGjBIilevXz95t3b9+7gwAJLQIiAoIEDEidfvFDRooVNyZQtR55c+TJnzYkNBCjwkGMKEyg2njydGiJr1TVeJ5xNu7aPgAAh+QQJGQA+ACwAAAAAKQAJAAcI0gB9CBxIsKDBgwgP1mCxYkWNgSUWJEhQYuDChg8FXnRokSFHjTJ28LgBg4aPEhQ8fMggYYSPGiFHlnwZk6RJmCJtClyhgwePHDNQ+FDQIYSIDRUG+ODpE6hQpj+DLu0ZVaiPFDh+2nBxwscBDSA4YHgg4GrWHFu7YtXK1Szbrj5U2KgRowULoQgsXJjAYAGBuHPr3gVM165QuYUHv3zxQkWLFiZLQIiAoIEDEosbP77J2DHkzJ5NakxhAkXGkwYCFKg4uvTpGqRNW4x9OqHt27YDAgAh+QQJGQA+ACwAAAAAKQAJAAcIzwB9CBxIsKDBgwgP1mCxYkWNgQsbPhRYYkGCBCUgMnSoUSJEGTt43IBBw0cNkCJJ+ihBwcOHDBJGmEQ5suTJkDUFrtDBg0eOGSh87Oz5M6iCDiFEbKgwQChPn0CdEo3qIwUOnzZcnKh6NUfWrQc0gOCA4YEArli1ovWq1ocKGzVitGAR9G3cuUERWLgwgcECAm7hyqUb+C5hky9eqGjRwmbixY1XQoiAoIEDEogVM3asObLAGilMoJhoMvTogSUMBCiQ8bNp0qBFk05IuzbtgAAh+QQJGQA+ACwAAAAAKQAJAAcI0QB9CBxIsKDBgwgP1mCxYkWNgQsbPhQY0eHAEgsSJCgBkaFFijJ28LgBg4aPGiFHljyZkqTJEhQ8fMggYQRLkS4FrtDBg0eOGSh87Oz5M+hQn0B9KOgQQsSGCgOE8kQa1EcKHD5tuDhhFWsOrVyvZt3q44AGEBwwPBDQdSxXHyps1IjRgkXQuHPr3pVL164PBBYuTGCwgABcvnopvnihokULkzUWN358UrLjlxAiIGjggERlxpchpjCBYuLJ0aVFkzZdwkCAAhwpojadsLbt2gEBACH5BAkZAD4ALAAAAAApAAkABwjPAH0IHEiwoMGDCA/WYLFiRY2BCxs+FBjRIUSGFgWWWJAgQQmIMnbwuAGDho8aIUeWPJmSpEmUIl36KEHBw4cMEkYIXKGDB48cM1D44OkTqFCiP4MO7ZlUqIIOIURsqDBAYAocP224OOHjatatXbHm0MrV61iwBzSA4IDhgQCBKmzUiNGChdC4c+velUvXrg+8fYUisHBhAoMFBCi+eKGiRYuXixs/PhnZMWTGlmdCiICggQMSEFOYQDHxpGjSoUeXrnG6dAkDAQp8TEi7tu2AACH+j0ZJTEUgSURFTlRJVFkNCkNyZWF0ZWQgb3IgbW9kaWZpZWQgYnkNCkJyaWFuDQoNCg0KQ3JlYXRlZCBieSBBbGNoZW15IE1pbmR3b3JrcycNCkdJRiBDb25zdHJ1Y3Rpb24gU2V0IFByb2Zlc3Npb25hbA0KaHR0cDovL3d3dy5taW5kd29ya3Nob3AuY29tACH+6lVOUkVHSVNURVJFRCBTSEFSRVdBUkUNCg0KQXNzZW1ibGVkIHdpdGggR0lGIENvbnN0cnVjdGlvbiBTZXQ6DQoNCkFsY2hlbXkgTWluZHdvcmtzIEluYy4NCkJveCA1MDANCkJlZXRvbiwgT04NCkwwRyAxQTANCkNBTkFEQS4NCg0KaHR0cDovL3d3dy5taW5kd29ya3Nob3AuY29tDQoNClRoaXMgY29tbWVudCB3aWxsIG5vdCBhcHBlYXIgaW4gZmlsZXMgY3JlYXRlZCB3aXRoIGEgcmVnaXN0ZXJlZCB2ZXJzaW9uLgAh/wtHSUZDT050YjEuMAIFAA41AAYAAQAAAAAAAAAAADVjOlxVc2Vyc1xKYWNrXFByb2plY3RzXHJhdy1pbWFnZXNcbG9hZGluZ1xJbWFnZTEuZ2lmAA41AAYAAgAAAAAAAAAAADVjOlxVc2Vyc1xKYWNrXFByb2plY3RzXHJhdy1pbWFnZXNcbG9hZGluZ1xJbWFnZTIuZ2lmAA41AAYAAwAAAAAAAAAAADVjOlxVc2Vyc1xKYWNrXFByb2plY3RzXHJhdy1pbWFnZXNcbG9hZGluZ1xJbWFnZTMuZ2lmAA41AAYABAAAAAAAAAAAADVjOlxVc2Vyc1xKYWNrXFByb2plY3RzXHJhdy1pbWFnZXNcbG9hZGluZ1xJbWFnZTQuZ2lmAA41AAYABQAAAAAAAAAAADVjOlxVc2Vyc1xKYWNrXFByb2plY3RzXHJhdy1pbWFnZXNcbG9hZGluZ1xJbWFnZTUuZ2lmAAA7"

/***/ }),
/* 1007 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAdAIcAAAAAAAEBAQICAgMDAwQEBAUFBQYGBgcHBwgICAkJCQoKCgsLCwwMDA0NDQ4ODg8PDxAQEBERERISEhMTExQUFBUVFRYWFhcXFxgYGBkZGRoaGhsbGxwcHB0dHR4eHh8fHyAgICEhISIiIiMjIyQkJCUlJSYmJicnJygoKCkpKSoqKisrKywsLC0tLS4uLi8vLzAwMDExMTIyMjMzMzQ0NDU1NTY2Njc3Nzg4ODk5OTo6Ojs7Ozw8PD09PT4+Pj8/P0BAQEFBQUJCQkNDQ0REREVFRUZGRkdHR0hISElJSUpKSktLS0xMTE1NTU5OTk9PT1BQUFFRUVJSUlNTU1RUVFVVVVZWVldXV1hYWFlZWVpaWltbW1xcXF1dXV5eXl9fX2BgYGFhYWJiYmNjY2RkZGVlZWZmZmdnZ2hoaGlpaWpqamtra2xsbG1tbW5ubm9vb3BwcHFxcXJycnNzc3R0dHV1dXZ2dnd3d3h4eHl5eXp6ent7e3x8fH19fX5+fn9/f4CAgIGBgYKCgoODg4SEhIWFhYaGhoeHh4iIiImJiYqKiouLi4yMjI2NjY6Ojo+Pj5CQkJGRkZKSkpOTk5SUlJWVlZaWlpeXl5iYmJmZmZqampubm5ycnJ2dnZ6enp+fn6CgoKGhoaKioqOjo6SkpKWlpaampqenp6ioqKmpqaqqqqurq6ysrK2tra6urq+vr7CwsLGxsbKysrOzs7S0tLW1tba2tre3t7i4uLm5ubq6uru7u7y8vL29vb6+vr+/v8DAwMHBwcLCwsPDw8TExMXFxcbGxsfHx8jIyMnJycrKysvLy8zMzM3Nzc7Ozs/Pz9DQ0NHR0dLS0tPT09TU1NXV1dbW1tfX19jY2NnZ2dra2tvb29zc3N3d3d7e3t/f3+Dg4OHh4eLi4uPj4+Tk5OXl5ebm5ufn5+jo6Onp6erq6uvr6+zs7O3t7e7u7u/v7/Dw8PHx8fLy8vPz8/T09PX19fb29vf39/j4+Pn5+fr6+vv7+/z8/P39/f7+/v///yH5BAAAAP8ALAAAAAABAB0AAAgUAO/ds1eP3jx58eC9W8iwoUOHAQEAOw=="

/***/ }),
/* 1008 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgAJAIcAAGFhYUD/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAKAAkAAAgkAAEIHDgwAIAACA8mNEiQoEGEDxcqjPhwIkSIFhs6ZGjxosKAADs="

/***/ }),
/* 1009 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDQAFAIcAAGGQzUD/QOPu+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAANAAUAAAgbAAMIDABgoEGDABIeRJhQ4cKGEA8KmEiRosGAADs="

/***/ }),
/* 1010 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDQAFAIcAAGGQzUD/QOPu+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAANAAUAAAgeAAUAGEgQgIAACBEKLHgwYcKFBh1KFNhQosOKEgMCADs="

/***/ }),
/* 1011 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgANAIcAAKyomf///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACAA0AAAgOAAEEEEhwoMGCCA8GCAgAOw=="

/***/ }),
/* 1012 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCQAJAIcAADBQoDBYoDBYsEBgsEBosEBowFBwwFB4wFB40FB44AD/AFCA4FCI4FCI8GCI0GCQ8GCQ/3CQ4HCY4HCY8HCg8HCg/4Co/4Cw/5Cw/5C4/6DA/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAoALAAAAAAJAAkAAAhCABUooCAhggMHAgVK0JABg4GECiJosPCAAEQHFyA0GCCQYASKCwAMsHhgQgUGCAoASChgQQKVEBUIKBAgpkABEAMCADs="

/***/ }),
/* 1013 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCQAJAIcAACBIkCBIoCBQoDBQoDBYoDBYsDBo0EBwwEBw0EB40FB40AD/AFCA0FCA4GCI4GCQ8GCY8HCY4HCg8HCg/4Co8JCw/6DA/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAsALAAAAAAJAAkAAAhBABcIXBBhoEEJFggYXICwgoMBAyNYqDDhQQKIERAYqAABQgEBAAQ2sADBgQCDDSg4UBAApQMGB0IObDAAgE2BAQEAOw=="

/***/ }),
/* 1014 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgAWAIcAAG+g39fX193d3d7e3t/f3+Dg4OHh4eLi4uPj4+Tk5OXl5ebm5ufn5+jo6Onp6erq6uvr6+zs7O3t7e7u7u/v7/Dw8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACABYAAAg0AAUIGDCAAIECBQwYOHAAAYIECRQoWLCAAYMGDRw4ePAAAoQIESRImDCBAoUKFQIEAAAgIAA7"

/***/ }),
/* 1015 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAPcAAAAAAAD/ACkxOTE5SjFSlDFalDlalEJSY0JrtUprlEprtVJje1JzvVJzxlJ7rVJ7xlpre1p7vWOExnM5KXOMtXOUvXuMpXuUtXuU1oQxIYQ5KYxCOZQ5OZRCOZRCQpRKUpRSWpSlxpSlzpStxpxjY5xja5xrhJxzc5x7lJy11qVze6V7hKV7lKWEnKW13q2Mpa3G563O77WEnLWUrbWcrbWttbXO772lrb3G1sbG3sbW987O3tbe9////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH5BAEAAAEALAAAAAAQABAAAAiAAAMIbCCwYEEABgNgQBAioUCEBh8wMOAwAMSCCgIQqHgxQAQGFQw4cNgxo8CNCS9KKDAigAECCVJWnNmxBYoXKErQkFlwhUAQG0g6lJGhhkEIFgBcOGDwA4mEIQBIpVDQRFCHAwAIKDjDw84AKgxGvVCQw4QTJDScSLhgpluBAQEAOw=="

/***/ }),
/* 1016 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAPcAAAAAAAD/ACkxOTE5SjFCczFKhDlKezlSe0JSY0JapUpajEpjpVJje1JrnFJzrVpre1pztWN7tWuMvXM5KXOMtXuMpXuUtYQxIYQ5KYxCOYycxpQ5OZRCOZRCQpRKUpRSWpSlxpStxpStzpxjY5xja5xrhJxzc5x7lJy11qVze6V7hKV7lKWEnK2Mpa3G57WEnLWUrbWcrbWttbXG572lrb3G1r3W98bG3s7O3s7e79be9////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH5BAEAAAEALAAAAAAQABAAAAh/AAOwONHiBIkYARImBKAwgIqEHzI0XDgxwIsLMioynOhhRMUAGxWWkPgxZAAYHRAGSDHR5IYJJkZgMNHyo02TCheUrCghgQaNFR00MNDwQQUAFhA01EmgYQgAUCkohNCAgoEGDQcAELBUYVOFIJAqjFAARAADBBQ0ZGCzbcKAAAA7"

/***/ }),
/* 1017 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAE9SW2hZQGxubmdpcGpsc29wdHN1end3fG5xgIduF7iIDL6NCb+NCKiPUMGPC8KQC8aUC8uXAc6ZAMycCsmaF9OfAcieMM2hB86mDN2qAN6rAN+sANqqCt61Gdi1N965N+KuAOm1AOm2AOy4AOCzFOO3GuG/I+G/JuC6KM+mRNiwSdKwV+fCF+vGH+/LGvbDAPnEAP/TAP/VAP/ZAOTBI+XEIuvIMuvKO+vYN//nAP/rAP/uAP/8AP//AP/mOv/nPufTUf/nSv/vRf/sW///Q///Rv//TIGBhIaIjIqLjpCQk5eXl5iYmJmZmbKmhKenp6qqqrq5qbm4tb6+vry9wujRjP//q9bW1tnZ2dvb297f5v//w///xf//xv//yuPj4+zs7P/+5PPz8/b29v379P/99/j4+P/9+P/++Pz8/P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAGoALAAAAAAQABAAAAiYANUIHEiwoEE1WaZAeYLl4MAvSQwcOMLkikM1SpAIBLOkyUUCBKkUcKgFAUEpAw5uiSIAxw0bLZwAUGHwR4MAQIYE8YEigQKDLIS46FCCBIcKEiAYrOGlSA8dMmCM0PDAIA0uRHjkiPFCRAYHBk1g1crV6wKDJ7pk3dp1AwODH6wY6bFjRggQEVIcrOIBw4UJFCysuEhYTUAAOw=="

/***/ }),
/* 1018 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAHZ0aXFxcXNzc3R0dLZ5AJSEP5CIdMqVAM+fF9WmBdijAd6rAN+sANqrC9ShGtWkG9alHNimHNimHd22A9KlI9mnINerNd+6LuGtAOe0AOi0AOi1AOu3APC9AM+rT+DEDfTAAPXCAPrJAPzJAP/LCfLHHv/RAP/SAP/XAPrbAPvVEP/YGuvNPPLXKPHXLvPYJ/ffK//XJvbSM/bTNPnXN//kAP/mAP/rAPzwAP/8AP/+AP//AP/yOP/+N///Of//OuPJQvrbRf/eRebLef/rTf/vU///Q///U//uYv//ZoODg4SEhIaGhoeHh4iIiI2NjY+QkpGRkZSUlJmZmZubm56enp+fn4mRr5yepaCgoKGhoaSkpKSkpaampqenp6ioqLCwsLGxsb+/v+rauv//kP//vcvLy8zMzNzd5vnr0P//x///yP//yf//zeLi4uPj5vv15/Ly8vPz8/b29vf39///8Pn5+f7+/v///v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAHkALAAAAAAQABAAAAioAPMIHEiwoEGCYqZI+XKQ4BkqT5hkadJQIBgnAsNE8dLwDZclA7coaYgGC5SBXQYMJJPkCI8YF64YSCPQSgCBRRAQoIGEyAwABSoIrCJAoIoVJIQEkVEiwQEJAs1oEQijTQ8cKUSA4IAhgsEXa37osHEihIYFEAy2UOMjRw0TITIweGDQBZsfbuFuwODAIIsyRnbcQDGigwILB4cA+TChAQUPYypKHhgQADs="

/***/ }),
/* 1019 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhHAAyAIcAABU7hCJFh8Pa+cXf/8fg/8vi/8rm/83j/8zn/9Dm/9Dq/9Po/9Lr/9bp/9bu/9jq/9rs/97t/9jw/9zx/9/z/+Dw/+Py/+H1/+bz/+X2/+f5/+n1/+v2/+v7/+78//H///T//////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAcADIAAAj/AAWE4ECwoEGCAkEoXMhQocCDEDkkbEjxYUSDEykytHgRYQiNDTl2zAgShMiLJEGejJhS40qILSsO7Oix5MKXB2OGnElT50aeIz/aNAkUpVCbODEeLZm0oM+bRVkuVRkV5lSXVXNelbmhq9evXQV+GEu27FiBGNKqXZtWoIe3cOO+FWihrt27dQV22Mu3716BFQILHhxYoIbDiBMfFhghQojHkEM0jiAwQ4bIkC1nEAghRIDPoAOEgABB4IUQAFKrBhDiwgWBDx54Dh0i9gOBFCigXh0iNwWBDYLPFh08uMAJyHezRo5c4ILnCzyHgP5coITrElCHwH5dYILv30OAqgcv0IF58yHOnxd4oL379+0FMphPv/58gQXy69+fX6CC/wAG+J9ABBRo4IEFCoTAggw2uKBAA0Qo4YQRCmTAhRhmeCGEFHZooYYgctjhhB+CmKGII1YYgokaophiiSwa4OKIMLI4o4crxrhhCCmSmKOON1JYo4lB+qjjjj1KOGSIPCY5wJItNpkklCdK2SOVGBap5I8xaqnikTJa+SKXNopJI5lEmokjmAEBADs="

/***/ }),
/* 1020 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhMgAOAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrXI48bGxsbS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAEALAAAAAAyAA4AAAiYAAMIHEiwoMGDCBMqXMiwocOHEB0uIEBxwAABAg5AnFjxYkaIBByIFNmAAQCQI0maRCkSQEkFJx+GHFkSQUyHMx0AYLDAwM2GOUv2/MlwgE4ASAH4hGg0KdKlDwU4KAlggYICRBdKFWoVK0QBQgEoQOA1KtexZR0KYDDWQIG3WRWubfs2bcMDTpNqfIg3L4C9EQMLHkxYcEAAOw=="

/***/ }),
/* 1021 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhMgAOAIcAAENZkkRZkkZblEdclUhdlkhelklel0pfl0tgmFZpnV1woWBypGN1pWR2pWZ3p21+qkD/QEL/QnaGq46Pj4uZu4yZupCdva6zua+0urK3vLS5vbi7v52nwKOuyK+4z7u+wby/wrC50be/1bm/0LrB1bzD1sHDxcLExsbHyMbIysXJzcrLzMzNzcnM0MvP1c3P0cnP3czQ1s3R1s3R19TU1dTV1tXV1tDT2NDU2dLV2tTX29XY3NXZ3dra29jb3tvb3Nvc3Nrc39vd39zd3s/U4t3f4dzf5N7g4d/i5d7h6d/i6eDh4eDh4+Hi4uHi4+Di5uLj5OPk5eTl5eXm5ubm5ubn5+fn6Ojo6Onp6enp6urq6urr6+vr7Ovs7Ozs7Ozt7e3t7e3u7u/v7+rs8O3u8fDw8PLy8vLz9PLz9vT09PX19fb29vj4+Pn5+fj5+gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAABEALAAAAAAyAA4AAAj/ACMIHEiwoMGDCBMWnMCwocOGCgU+nMgwYoQJaTJq3JhmgkWMHNOwabOm48c0F1KqxKDhg8mIGFWmbMFBghE1HmGidMHTxY0dQky8VBizZwwyCQCMWJOT6E4XMnL4KAIFxdCERaE+8RCggZWrCGPOwKFDiJMpV1iAPRiTB5IdZxQIKAFkrUGMGXYEYXLFCxgwNewuTKMCRocwJAgwYGNDMEGMG4pI0SLGjOUhjgdiPPJAABEHB0SswdwUaxoQUbCAMZNGTZommSWmeZFkQIEDC9y8jn0xzQnVZdKsGU6FN8YUYygYQBCCZPHSYdOsoPFjSZUtXbhkMS69h5IKFtB8GNHOPeRG6Gw1qmnDxrVG9HcpPvwo36HFgAA7"

/***/ }),
/* 1022 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhGAACAIcAAKrM9tDj+tLk+tPl+tXm+9bn+9fn+9no+9rp+9zq+97r/N/s/OHt/OLu/OTv/OXv/Obw/Ojx/eny/evz/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAYAAIAAAgoACcIFCghAoQHDhowWKAgAYIDBgoQGCAgAICBBA0iVMjQIUSJFC0GBAA7"

/***/ }),
/* 1023 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCQAPAPcAAAAAADFKY5SlvZylvZytxqW11qm92r3GxrXI48bS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAP8ALAAAAAAJAA8AAAhOAP8JHEiwoEGDCggoHDBAgIADBBpIlMhgQYCIEysiuJhxgQIDAQY0CECSJEgBDSoqUJCgQAABKlkicClgQQIEBgroDHCgpM8DB4MKHRgQADs="

/***/ }),
/* 1024 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCQAPAPcAAAAAADFKY5SlvZylvZytxqW11qm92r3GxrXI48bS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAP8ALAAAAAAJAA8AAAhRAP8JHEiwoEGDCggoHDBAgIADBBpIlMhgQYCIEgNUTHBxYoAFCgwEGNAggEmTIgU0qBhAQYICAQRUVBAgAQKYAhbYNFCgZ4ADJ4MeOEi06MCAADs="

/***/ }),
/* 1025 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAFFxqVFyqVNzqVNzqlR1q1R1rFZ2rVd5rlh6sFh7sVp8slx+tFx+tUB240D/QF6Bt1+DuWCFumGFu2OHvWSIvlaG5WaLwGiOw2ySyGyUyW6Uym+Wy2+XzHCRwXCZznKaz3Oc0XOd0nWe1Hag1Xmi2Hmj2Xqk2nqk23qm3Hun3JGRkZWVlZ6enrCwsLq6ur6+voCex4yhxoat3ZK03pK56LbD28DAwMLCwsbGxsjIyMrKyszMzN3d3dji9v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAA4ALAAAAAAQABAAAAifAB0IHEiwoMGDBGvMSIHCBIkRIkJ88LAhQwYYNWTQ2MixY8cOKUKKHEnSwgkfKEv0WLmyBEqUE1zu0KGygs0eJVrwaOAjAomXKlni9NGA54MRPnLgqHmzRFGeDEQAFTq0qA8FIHzcsMG0Ak4WO30g4DBVqMuXBTT4eOGiK84VKlT4GIChLMuzKAPEuGCBggQICxQkOGCAgAABAGIgRBgQADs="

/***/ }),
/* 1026 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1027);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1027 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-dd-drag-ghost{\r\n\tcolor:#000;\r\n\tfont: normal 11px arial, helvetica, sans-serif;\r\n    border-color: #ddd #bbb #bbb #ddd;\r\n\tbackground-color:#fff;\r\n}\r\n\r\n.x-dd-drop-nodrop .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1028)) + ");\r\n}\r\n\r\n.x-dd-drop-ok .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1029)) + ");\r\n}\r\n\r\n.x-dd-drop-ok-add .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1030)) + ");\r\n}\r\n\r\n.x-view-selector {\r\n    background-color:#c3daf9;\r\n    border-color:#3399bb;\r\n}", ""]);

// exports


/***/ }),
/* 1028 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAMAAAMEEBMQQEMUUFMccHMkkJM00NM88PNRQUNVUVNlkZNpoaNxwcN10dOSQkOecnOmkpOuwsO24uO68vO/AwPDExPHIyPLMzPXY2Pfg4Pjk5Pno6Pvw8Pz09P34+P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAB8ALAAAAAAQABAAAAiSAD8IHNiBAoUOAxMOjGAAgMMAByoo/LABAQACDSA8YCAAgAKEAy0u4JBQg0MGCwE0mOgQQIALAg0UADmwpYYBCT50AOBAYUuBDAZ8oABgQsKfAh8AyCChaE2HCZVi4MBTINKBQWPOvCrwZs4PEVoCmJjgZUiHJAdqSAAA5cCKFzNu7PhxIsOWECVOJCjBgoeJAQEAOw=="

/***/ }),
/* 1029 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAACdyJCZ/Iyl3JSl6JTR8MDV/MSaEIyqPJTWPMT+FOz+LOz+NOz+ZPDuhJ0yXPUKhM0ShM0mwJ1G3LlWzNV21P1q+N06bQVKgQl6pSGSwTGy2Vm23V261WG+1WG+1WWq5UHS3W3S3XHC/V3C4WXG5W3K5W3O6XHG+X3e8YH23Zny6ZH28Zn2+Z3+4aVzAO1zDPWbFSWrDSWzFS2nISnTCWXLLVW/CYW/DYW7EYW7EYm7FY2/GZHDBY3HEY3DHZXPHZnTDZHLIaHTIaHXIaHbJaXbKannBZH7BaX7Hb3nJa3rMbX/KcIO+bYfCcoXFdYDKc4DMcoPOd4fJeYnEdovIeJDOf5G5j5C8jpbHg5HAj5bLhpfMhZTIj5bNiJrHh5jLhprKh5jMh5nNip3Oi5nRi5nQjJrUjZvXkZ/SkJ/SkZ3YkqHWlaHXlaPXlqvSm6vTm6rcl63fm67Xoa/XoK7cpa/cprPZpbHdp7TZpbTaprLbqLXbqLTdqrTfrLXfrLbQtbbRtbfZtbrbtb7ftbDjn7Xhrrfhr7fhsL7jtr/juMHjtsDkucvsv8DAwMvtwNbu0tns1Ob04+336/H58PT68vz9+/3+/f///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAI0ALAAAAAAQABAAAAjVABsJHEiwoEFCNVxUiAHHoEBHM2i0oUNnzYcJigoyelHFkJooUdQUotJgEEEYVQopKRJEyJAkfaY8GBhHhCElQXzoyNEDERI/GLgIlMHmDJEdOG7YWHQpEpkxDARKuAPlx6FHPBJdqlTmiBwDAiPUWfJk0iVJW7uQYDEngEAKacwAkULpkiUtG0ps8aJAIJoMfIyccAJJjAYOIfJYuDIQQhM9KEyM8NABhJ0WBQgKOsBkT5gVKr7gSQEAUMFACC6AeeMGiwMCfxw2yrJggIAEVmTrJhgQADs="

/***/ }),
/* 1030 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAD2GNUKNNkOPOESMO0WNPEmPP0iNQUmPQlOVTFWWTVCZQVeeRV6cVmGeWGSgVWSgV2aiWGejW2WrVWirU2uqWGqsW2yqWm61WG+1WG+1WXS3W3S3XHC4WXK5W3O6XHG+X3asZ3iuaHe8YHi0ZH+yany6ZH28Zn2+Z3m9bn25an25a3+5bXDBY3nBZHrGa3zDa37BaX7Hb4K1boO1boa3cYi4d4y7doq5eYm+eI2+e5O/f4HMdYbJeobJfIXNeYrCeY/CfYnIf4rPfZW/gozLgY7MhI7Sg5LFgJXAgpfHhZfMhZPNiJjLhpjMh5jMipvBl5vBmJTTipbTiZXUipbUi5fVi5nRi53YkqTOlKbPlqbQlqDZlaDZlqXbm6rUnavUnKbIoKfJoa/fpa/fprPZpbTZpbTaprLbqLPdqbXbqLfaqrTdqrXfrLbdrLjVr7jdr7vcr7rWsbzVubfgr77itr3ktsTcuMXducnexMrexcXowMvmw8zgxs3gx87pydTrz9fu0tnp0dzx2ODy3OPt4ePu4ufw5ejx5uvz6e/27P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAIsALAAAAAAQABAAAAjGABcJHEiwoME7SGjIuBHHoMBAOrDs+ePnzYoQfQoGsgFnUJ0uXMTo+QEhD0EdagRdWVKEyhQjc1REGGgnCaAtUYIoUuTjRQw2C8IIHNJmDJEeKHZWEOHBypEGAmfQqcJjp1VFHGB4KSCQBBohO67u5HDiywCBNZxIccFCwlgOHZTkSCDQzYQ1LT6IGHthgxkBTwaCSHGGKYcMGDSQsXCAIB8HI9I0MVGCSRkKAOQUxPNAARAtWXAEMKDZIRgGBQgggOKwtcGAADs="

/***/ }),
/* 1031 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1032);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1032 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-tree-node-expanded .x-tree-node-icon{\r\n\tbackground-image:url(" + escape(__webpack_require__(1033)) + ");\r\n}\r\n\r\n.x-tree-node-leaf .x-tree-node-icon{\r\n\tbackground-image:url(" + escape(__webpack_require__(1034)) + ");\r\n}\r\n\r\n.x-tree-node-collapsed .x-tree-node-icon{\r\n\tbackground-image:url(" + escape(__webpack_require__(1035)) + ");\r\n}\r\n\r\n.x-tree-node-loading .x-tree-node-icon{\r\n\tbackground-image:url(" + escape(__webpack_require__(1036)) + ") !important;\r\n}\r\n\r\n.x-tree-node .x-tree-node-inline-icon {\r\n    background-image: none;\r\n}\r\n\r\n.x-tree-node-loading a span{\r\n\t font-style: italic;\r\n\t color:#444444;\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow{\r\n\tbackground-image:url(" + escape(__webpack_require__(1037)) + ");\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow-plus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1038)) + ");\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow-minus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1039)) + ");\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow-end{\r\n\tbackground-image:url(" + escape(__webpack_require__(1040)) + ");\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow-end-plus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1041)) + ");\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow-end-minus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1042)) + ");\r\n}\r\n\r\n.x-tree-lines .x-tree-elbow-line{\r\n\tbackground-image:url(" + escape(__webpack_require__(1043)) + ");\r\n}\r\n\r\n.x-tree-no-lines .x-tree-elbow-plus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1044)) + ");\r\n}\r\n\r\n.x-tree-no-lines .x-tree-elbow-minus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1045)) + ");\r\n}\r\n\r\n.x-tree-no-lines .x-tree-elbow-end-plus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1046)) + ");\r\n}\r\n\r\n.x-tree-no-lines .x-tree-elbow-end-minus{\r\n\tbackground-image:url(" + escape(__webpack_require__(1047)) + ");\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-plus{\r\n    background-image:url(" + escape(__webpack_require__(164)) + ");\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-minus{\r\n    background-image:url(" + escape(__webpack_require__(164)) + ");\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-end-plus{\r\n    background-image:url(" + escape(__webpack_require__(164)) + ");\r\n}\r\n\r\n.x-tree-arrows .x-tree-elbow-end-minus{\r\n    background-image:url(" + escape(__webpack_require__(164)) + ");\r\n}\r\n\r\n.x-tree-node{\r\n\tcolor:#000;\r\n\tfont: normal 11px arial, tahoma, helvetica, sans-serif;\r\n}\r\n\r\n.x-tree-node a, .x-dd-drag-ghost a{\r\n\tcolor:#000;\r\n}\r\n\r\n.x-tree-node a span, .x-dd-drag-ghost a span{\r\n\tcolor:#000;\r\n}\r\n\r\n.x-tree-node .x-tree-node-disabled a span{\r\n\tcolor:gray !important;\r\n}\r\n\r\n.x-tree-node div.x-tree-drag-insert-below{\r\n \t border-bottom-color:#36c;\r\n}\r\n\r\n.x-tree-node div.x-tree-drag-insert-above{\r\n\t border-top-color:#36c;\r\n}\r\n\r\n.x-tree-dd-underline .x-tree-node div.x-tree-drag-insert-below a{\r\n \t border-bottom-color:#36c;\r\n}\r\n\r\n.x-tree-dd-underline .x-tree-node div.x-tree-drag-insert-above a{\r\n\t border-top-color:#36c;\r\n}\r\n\r\n.x-tree-node .x-tree-drag-append a span{\r\n\t background-color:#ddd;\r\n\t border-color:gray;\r\n}\r\n\r\n.x-tree-node .x-tree-node-over {\r\n\tbackground-color: #eee;\r\n}\r\n\r\n.x-tree-node .x-tree-selected {\r\n\tbackground-color: #d9e8fb;\r\n}\r\n\r\n.x-tree-drop-ok-append .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1048)) + ");\r\n}\r\n\r\n.x-tree-drop-ok-above .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1049)) + ");\r\n}\r\n\r\n.x-tree-drop-ok-below .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1050)) + ");\r\n}\r\n\r\n.x-tree-drop-ok-between .x-dd-drop-icon{\r\n  background-image: url(" + escape(__webpack_require__(1051)) + ");\r\n}", ""]);

// exports


/***/ }),
/* 1033 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAADFKY0L/QplnAZpoApxqBJ5sBqBuCKJwCqNxC6RyDKVzDad1D6x6FLB+GLOBG7WCHbeEH7qHIr2KJcaaGcaaGsKPKsiVMMmWMcuYM8yZNMmgIc+iJte4QNq/bOKzQ+LBUP3VcP/bdfDkev/kf5SlvZylvbe3t5ytxqW11qm92r3GxrnK5P/XhP/rhP/viffwif/4k///mf//nP//pcTExMXFxc3NzdHR0cbW69jh8efv9+vz//r7/P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABAAAAiZAAMIHEiwoMGDBzNkwHDBAkKBGXpI5MGjAsKIMjJm7CEhAoQHDhoIxNBDo0mJEhncCHChB4yXMGPKWFBjgs2bOG1+aIGAxoQYJk3G6DCBhQGfQGPClPFiAogCNAL8dEG1KtUZGjwQiPpTxoivYEfM4LBhQFSpMUKoXatWBAUBNQROUECXboIDBgoQGGDCxkAbNAILHuz34cGAADs="

/***/ }),
/* 1034 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAAAAADVJYzZKZC9iyDFlzTly4j5240B240Z75Ep940D/QE6B5FaG5ViH5WKO5myU526X52WV82qZ9Xab6Hqf6XGd9X+h6Xei9n2n+ICAgJOit5alupqpvp6uw4Sl6Yam6ouq6oSr+Yuw+pC1+5a5/Jq9/aOyyKe2zJ/A/qLC/9Dg8ODg8ODo8PDw8PDw//D4///4/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAoALAAAAAAQABAAAAiOABUIHEiwoMGDBUEoBPHBwoQHDhosQGCggEAQKVCUIDFCRAgMFypIiEDgokIPFCA4YJDgQIGXAwSeiEGzZs0XL1wIEGgiBoCfP2nidMEigMAONm/mZFFUIIeaGaJKjbrCqIINSW0OtarBJ1AAQpdyzRpjKNOxNKdOrSqwq00YOVuwWKGCa4C7ePPiRcg3IAA7"

/***/ }),
/* 1035 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAADFKY0L/QplnAZpoApxqBJ5sBqBuCKNxC6VzDad1D6h2EKt5E6x6FK58FrB+GLOBG7WCHbeEH7qHIr2KJcCNKMKPKsWSLceUL8iVMMmWMcuYM8yZNNu3Utu3cf/Ub//bdf/kf5SlvZylvZytxqW11qm92r3GxrnK5P/vif/4k///mf//nP//usDAwMvLy8zMzNPT09bW1sbW69jh8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABAAAAiVAAMIHEiwoMGDBzds0JABA0KBG2xIZMGiAsINHTho1NhhgoQIEB44EKhBosmTJhnECJBBxYqXMGOqSPAiwAUVOHPqxHnARQALKlIIHUpUhQGfFVSgWMq0qYoCPimoAEG1qlUVBHxOUPGhq9evKgb4lKDCg9mzaFUIqBkgpIMGCxQgOGCgAAEBLWAMhOGir9+/eh8eDAgAOw=="

/***/ }),
/* 1036 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQALMMAKqooJGOhp2bk7e1rZ2bkre1rJCPhqqon8PBudDOxXd1bISCef///wAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh+QQFAAAMACwAAAAAEAAQAAAET5DJyYyhmAZ7sxQEs1nMsmACGJKmSaVEOLXnK1PuBADepCiMg/DQ+/2GRI8RKOxJfpTCIJNIYArS6aRajWYZCASDa41Ow+Fx2YMWOyfpTAQAIfkEBQAADAAsAAAAABAAEAAABE6QyckEoZgKe7MEQMUxhoEd6FFdQWlOqTq15SlT9VQM3rQsjMKO5/n9hANixgjc9SQ/CgKRUSgw0ynFapVmGYkEg3v1gsPibg8tfk7CnggAIfkEBQAADAAsAAAAABAAEAAABE2QycnOoZjaA/IsRWV1goCBoMiUJTW8A0XMBPZmM4Ug3hQEjN2uZygahDyP0RBMEpmTRCKzWGCkUkq1SsFOFQrG1tr9gsPc3jnco4A9EQAh+QQFAAAMACwAAAAAEAAQAAAETpDJyUqhmFqbJ0LMIA7McWDfF5LmAVApOLUvLFMmlSTdJAiM3a73+wl5HYKSEET2lBSFIhMIYKRSimFriGIZiwWD2/WCw+Jt7xxeU9qZCAAh+QQFAAAMACwAAAAAEAAQAAAETZDJyRCimFqbZ0rVxgwF9n3hSJbeSQ2rCWIkpSjddBzMfee7nQ/XCfJ+OQYAQFksMgQBxumkEKLSCfVpMDCugqyW2w18xZmuwZycdDsRACH5BAUAAAwALAAAAAAQABAAAARNkMnJUqKYWpunUtXGIAj2feFIlt5JrWybkdSydNNQMLaND7pC79YBFnY+HENHMRgyhwPGaQhQotGm00oQMLBSLYPQ9QIASrLAq5x0OxEAIfkEBQAADAAsAAAAABAAEAAABE2QycmUopham+da1cYkCfZ94UiW3kmtbJuRlGF0E4Iwto3rut6tA9wFAjiJjkIgZAYDTLNJgUIpgqyAcTgwCuACJssAdL3gpLmbpLAzEQA7"

/***/ }),
/* 1037 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAPcAAEL/QsbGxv///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH5BAEAAAAALAAAAAAQABIAAAgvAAEIHEiwoMGBAQ4qXHgwIcOHCx1CnEhQIkWKCTMCsHjRIMeODD+CVChypMeDAQEAOw=="

/***/ }),
/* 1038 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrXI48bGxsbS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhrAAMIHEiwoMGBCQ4qXHgwIcOHBRcQmDhggAABBw4ScMCRYwMGADR2BPBRQUiDGzkCYLDAwMmCAxwAmDnTZQCHAwU4+AhggYICLwkK+LgAgAIEQA8KYHDUQIGnQQceoEk1I8SrN7FqFYiTYEAAOw=="

/***/ }),
/* 1039 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrnK5MbGxsbW69jh8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhpAAMIHEiwoMGBCQ4qXHgwIcOHBRcQmDhggAABBw4ScMCRYwMGADR2dPARQUiDGz0yWGDgZMEBDgDIlNkygMOBAkiuXKCggEuCAj4u4InA50EBDBQgMFCg6c+BB2ZKzQixqk2rWAXeJBgQADs="

/***/ }),
/* 1040 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAPcAAEL/QsbGxv///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH5BAEAAAAALAAAAAAQABIAAAgpAAEIHEiwoMGBAQ4qXHgwIcOHCx1CnEhQIkWKCTMCsHixo8ePIEOGDAgAOw=="

/***/ }),
/* 1041 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrXI48bGxsbS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhoAAMIHEiwoMGBCQ4qXHgwIcOHBRcQmDhggAABBw4ScMCRYwMGADR2BPBRQUiDGzkCYLDAwMmCAxwAmDnTZQCHAwU4+AhggYICLwkK+LgAgAIEQA8KYHDUQIGnQQceoEk1I8SrWLNCDAgAOw=="

/***/ }),
/* 1042 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrnK5MbGxsbW69jh8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhmAAMIHEiwoMGBCQ4qXHgwIcOHBRcQmDhggAABBw4ScMCRYwMGADR2dPARQUiDGz0yWGDgZMEBDgDIlNkygMOBAkiuXKCggEuCAj4u4InA50EBDBQgMFCg6c+BB2ZKzQixqtWrEAMCADs="

/***/ }),
/* 1043 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAPcAAEL/QsbGxv///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH5BAEAAAAALAAAAAAQABIAAAgrAAEIHEiwoMGBAQ4qXHgwIcOHCx1CnEhQIkWKFi9CzKiRIceOCj+CNPgxIAA7"

/***/ }),
/* 1044 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrXI48bGxsbS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhhAAMIHEiwoMGDCBMqXMjQ4AICEAcMECDgwEECDjJmbMAAwEWNADgq8GgQY0YADBYYIFlwgAMAMGGuPCjAAUcACxQUYElQAMcFABQg2EmTgVADBZLyHHggplOLDaNKnYowIAA7"

/***/ }),
/* 1045 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrnK5MbGxsbW69jh8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhfAAMIHEiwoMGDCBMqXMjQ4AICEAcMECDgwEECDjJmbMAAwEWNDjgi8GgQ40YGCwyQLDjAAYCXL1UeFBAS5QIFBVYSFMBxwU0EOWcyUIDAQIGjOgcegMnUYsOnUKMiDAgAOw=="

/***/ }),
/* 1046 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrXI48bGxsbS59Te8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhhAAMIHEiwoMGDCBMqXMjQ4AICEAcMECDgwEECDjJmbMAAwEWNADgq8GgQY0YADBYYIFlwgAMAMGGuPCjAAUcACxQUYElQAMcFABQg2EmTgVADBZLyHHggplOLDaNKnYowIAA7"

/***/ }),
/* 1047 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAASAIcAADFKY0L/QpSlvZylvZytxqW11qm92r3GxrnK5MbGxsbW69jh8efv9+vz/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAQABIAAAhfAAMIHEiwoMGDCBMqXMjQ4AICEAcMECDgwEECDjJmbMAAwEWNDjgi8GgQ40YGCwyQLDjAAYCXL1UeFBAS5QIFBVYSFMBxwU0EOWcyUIDAQIGjOgcegMnUYsOnUKMiDAgAOw=="

/***/ }),
/* 1048 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAD2GNUKNNkOPOESMO0WNPEmPP0iNQUmPQlOVTFWWTVCZQVeeRV6cVmGeWGSgVWSgV2aiWGejW2WrVWirU2uqWGqsW2yqWm61WG+1WG+1WXS3W3S3XHC4WXK5W3O6XHG+X3asZ3iuaHe8YHi0ZH+yany6ZH28Zn2+Z3m9bn25an25a3+5bXDBY3nBZHrGa3zDa37BaX7Hb4K1boO1boa3cYi4d4y7doq5eYm+eI2+e5O/f4HMdYbJeobJfIXNeYrCeY/CfYnIf4rPfZW/gozLgY7MhI7Sg5LFgJXAgpfHhZfMhZPNiJjLhpjMh5jMipvBl5vBmJTTipbTiZXUipbUi5fVi5nRi53YkqTOlKbPlqbQlqDZlaDZlqXbm6rUnavUnKbIoKfJoa/fpa/fprPZpbTZpbTaprLbqLPdqbXbqLfaqrTdqrXfrLbdrLjVr7jdr7vcr7rWsbzVubfgr77itr3ktsTcuMXducnexMrexcXowMvmw8zgxs3gx87pydTrz9fu0tnp0dzx2ODy3OPt4ePu4ufw5ejx5uvz6e/27P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAIsALAAAAAAQABAAAAjGABcJHEiwoME7SGjIuBHHoMBAOrDs+ePnzYoQfQoGsgFnUJ0uXMTo+QEhD0EdagRdWVKEyhQjc1REGGgnCaAtUYIoUuTjRQw2C8IIHNJmDJEeKHZWEOHBypEGAmfQqcJjp1VFHGB4KSCQBBohO67u5HDiywCBNZxIccFCwlgOHZTkSCDQzYQ1LT6IGHthgxkBTwaCSHGGKYcMGDSQsXCAIB8HI9I0MVGCSRkKAOQUxPNAARAtWXAEMKDZIRgGBQgggOKwtcGAADs="

/***/ }),
/* 1049 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAADVJY0Y3K0g5LFJBM1ZENSBIoGd6lWt+mXSFn3yNpo9+YJyMaqGQbq2dd7GgeNfFYOPUbO/ieKikn72tgq+vr7+/v5upwMGwhM/Pz9/f3////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAQABAAAAhsADUIHDgQQwGCCAkaPEjQQkINBSJKpPBQYIWIAjMcdPjw4kCGDS1IEIjhowaOAh0CqEjwggMGCxQ8dOhwQgQIDwhoSIDggIGEDQYMEBBgJsujJ0VWRHlSw0qkLmHKTEhTg02cOnn6BCqU6MOAADs="

/***/ }),
/* 1050 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAADVJY0Y3K0g5LFJBM1ZENSBIoGd6lWt+mXSFn3yNpo9+YJyMaqGQbq2dd7GgeNfFYOPUbO/ieKikn72tgq+vr7+/v5upwMGwhM/Pz9/f3////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAQABAAAAhsADUIFGjBgoSBCDVYQLgQQMKHGi44YLBAgYYECA4YIKhQw4QIEB4QgIiwwYABAgJAXEiyJUGDJFlydOgy4sSKFzNu7LjwY8iRLk2iVIlhYIGOECscFbg0aYGlGY4ulMn0qVUKLTE8rTlQa8KAADs="

/***/ }),
/* 1051 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAADVJY0Y3K0g5LFJBM1ZENSBIoGd6lWt+mXSFn3yNpo9+YJyMaqGQbq2dd7GgeNfFYOPUbO/ieKikn72tgr+/v5upwMGwhM/Pz////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAQABAAAAhoADEIFFihgoSBCDFUQLgQQMKHGCw4YLBAAYYECA4YIKgQw4QIEB4QgIiwwYABAgIIvMCQJAYKBVwihBlz4MKFCQvo3Cnzgs6WJH26LHhwJVCODmVGnFjxYsaNHRd+DDlSpkmUKpUqDQgAOw=="

/***/ }),
/* 1052 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1053);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1053 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-date-picker {\n    border-color: #1b376c;\n    background-color:#fff;\n}\n\n.x-date-middle,.x-date-left,.x-date-right {\n\tbackground-image: url(" + escape(__webpack_require__(1054)) + ");\n\tcolor:#fff;\n\tfont:bold 11px \"sans serif\", tahoma, verdana, helvetica;\n}\n\n.x-date-middle .x-btn .x-btn-text {\n    color:#fff;\n}\n\n.x-date-middle .x-btn-mc em.x-btn-arrow {\n    background-image:url(" + escape(__webpack_require__(1055)) + ");\n}\n\n.x-date-right a {\n    background-image: url(" + escape(__webpack_require__(1056)) + ");\n}\n\n.x-date-left a{\n\tbackground-image: url(" + escape(__webpack_require__(1057)) + ");\n}\n\n.x-date-inner th {\n    background-color:#dfecfb;\n    background-image:url(" + escape(__webpack_require__(235)) + ");\n\tborder-bottom-color:#a3bad9;\n    font:normal 10px arial, helvetica,tahoma,sans-serif;\n\tcolor:#233d6d;\n}\n\n.x-date-inner td {\n    border-color:#fff;\n}\n\n.x-date-inner a {\n    font:normal 11px arial, helvetica,tahoma,sans-serif;\n    color:#000;\n}\n\n.x-date-inner .x-date-active{\n\tcolor:#000;\n}\n\n.x-date-inner .x-date-selected a{\n    background-color:#dfecfb;\n\tbackground-image:url(" + escape(__webpack_require__(235)) + ");\n\tborder-color:#8db2e3;\n}\n\n.x-date-inner .x-date-today a{\n\tborder-color:darkred;\n}\n\n.x-date-inner .x-date-selected span{\n    font-weight:bold;\n}\n\n.x-date-inner .x-date-prevday a,.x-date-inner .x-date-nextday a {\n\tcolor:#aaa;\n}\n\n.x-date-bottom {\n    border-top-color:#a3bad9;\n    background-color:#dfecfb;\n    background-image:url(" + escape(__webpack_require__(235)) + ");\n}\n\n.x-date-inner a:hover, .x-date-inner .x-date-disabled a:hover{\n    color:#000;\n    background-color:#ddecfe;\n}\n\n.x-date-inner .x-date-disabled a {\n\tbackground-color:#eee;\n\tcolor:#bbb;\n}\n\n.x-date-mmenu{\n    background-color:#eee !important;\n}\n\n.x-date-mmenu .x-menu-item {\n\tfont-size:10px;\n\tcolor:#000;\n}\n\n.x-date-mp {\n\tbackground-color:#fff;\n}\n\n.x-date-mp td {\n\tfont:normal 11px arial, helvetica,tahoma,sans-serif;\n}\n\n.x-date-mp-btns button {\n\tbackground-color:#083772;\n\tcolor:#fff;\n\tborder-color: #3366cc #000055 #000055 #3366cc;\n\tfont:normal 11px arial, helvetica,tahoma,sans-serif;\n}\n\n.x-date-mp-btns {\n    background-color: #dfecfb;\n\tbackground-image: url(" + escape(__webpack_require__(235)) + ");\n}\n\n.x-date-mp-btns td {\n\tborder-top-color: #c5d2df;\n}\n\ntd.x-date-mp-month a,td.x-date-mp-year a {\n\tcolor:#15428b;\n}\n\ntd.x-date-mp-month a:hover,td.x-date-mp-year a:hover {\n\tcolor:#15428b;\n\tbackground-color: #ddecfe;\n}\n\ntd.x-date-mp-sel a {\n    background-color: #dfecfb;\n\tbackground-image: url(" + escape(__webpack_require__(235)) + ");\n\tborder-color:#8db2e3;\n}\n\n.x-date-mp-ybtn a {\n    background-image:url(" + escape(__webpack_require__(395)) + ");\n}\n\ntd.x-date-mp-sep {\n   border-right-color:#c5d2df;\n}", ""]);

// exports


/***/ }),
/* 1054 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAwB7AIcAABEpVxEqWBIqWRIrWhMsWxMsXBQtXRQuXhUuXxUvYBYwYRYxYhcxYxcyZBgzZRgzZhk0Zxk1aBo1aRo2aho3axs3bBs4bRw5bhw5bx06cB07cR47ch48cx89dB8+dSA+diA/dyFAeCFAeSJBeiJCeyNCfCNDfUp0vP3//wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAACgALAAAAAADAHsAAAj/ACtUQHFCoAkTFUqUqECCRIURIyqIEFEhRIgKIEBU+PChggcPFTp0qMCBQ4UNGypo0FAhQ4YKGDBUuHChggULAgVSoFBhwoQKEiRUiBChAgQIFR48qODAQYUGDSowYFBhwYIKChRUSJCgAgIEFQ4cqGDAQIUCBSoQIFBhwIAKAgRUCBCgAgAAA3NWKHgw4cKGDyNOrHgx48aOH0OOLHky5cqWL2POrHlT786eP4MOLXo06dKmT6NOrXo169auX8OOLXs27dq2b+POrXs354nbB00oLNGQBMQRE0VYDJERBMcPHz2I7FCSA8oNKzW4zBATA80LN3Hq3OlzQlAJRCMcKIWg9EFTB1AbTGVgdUFWBVwTfEUg9kBZA2gLrCXgdkBcAXQFcBcAAQEAOw=="

/***/ }),
/* 1055 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCgBkAPcAAP///0D/QF2Bo3SUsnyatYGeuIWhuoqlvY+pv5OswpiwxJy0x6G3yqa7zKq+z6/C0bTG1LjJ1r3N2b/O3P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAEALAAAAAAKAGQAAAhxAAMIHEiwoMGDCBMqRDgBgEOHEwg2hGiwYcSDFxdq3Mixo8ePIEOKHEmypMmTKFOqXMkyQAEKCA3APHhgpkEENgsmyElQAcyJDycsmAk0IgObFgU2yJnRAc+BD54KhCA1QISqLbNq3cq1q9evYMMWDAgAOw=="

/***/ }),
/* 1056 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDwAPAPcAABowbR04fSFChSdJki9klDx+pUCFpEGdqf///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAADwAPAAAITAAFABhIsCBBAQEEDFjIsOEAhAEcSlwYIKGAixgzXqzIsSKCjiBBIvgYMuRIkiU5nkSZ8mTKjiNfwnxpsObAijZr4sxZMAAAmRwBBAQAOw=="

/***/ }),
/* 1057 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDwAPAPcAABowbR04fSFChSdJki9klDx+pUCFpEGdqf///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAADwAPAAAISwAFABhIsCBBAQEEDFjIsOEAhAEcSlwYIKGAixgzXqzIsSOCjiA9fgwJEoFJkiJPouRocuTKiipfwiRpsObAijZr4sxZMAAAmTgDAgA7"

/***/ }),
/* 1058 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1059);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1059 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-tip .x-tip-close{\r\n\tbackground-image: url(" + escape(__webpack_require__(1060)) + ");\r\n}\r\n\r\n.x-tip .x-tip-tc, .x-tip .x-tip-tl, .x-tip .x-tip-tr, .x-tip .x-tip-bc, .x-tip .x-tip-bl, .x-tip .x-tip-br, .x-tip .x-tip-ml, .x-tip .x-tip-mr {\r\n\tbackground-image: url(" + escape(__webpack_require__(1061)) + ");\r\n}\r\n\r\n.x-tip .x-tip-mc {\r\n    font: normal 11px tahoma,arial,helvetica,sans-serif;\r\n}\r\n.x-tip .x-tip-ml {\r\n\tbackground-color: #fff;\r\n}\r\n\r\n.x-tip .x-tip-header-text {\r\n    font: bold 11px tahoma,arial,helvetica,sans-serif;\r\n    color:#444;\r\n}\r\n\r\n.x-tip .x-tip-body {\r\n    font: normal 11px tahoma,arial,helvetica,sans-serif;\r\n    color:#444;\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-tc, .x-form-invalid-tip .x-tip-tl, .x-form-invalid-tip .x-tip-tr, .x-form-invalid-tip .x-tip-bc,\r\n.x-form-invalid-tip .x-tip-bl, .x-form-invalid-tip .x-tip-br, .x-form-invalid-tip .x-tip-ml, .x-form-invalid-tip .x-tip-mr\r\n{\r\n\tbackground-image: url(" + escape(__webpack_require__(1062)) + ");\r\n}\r\n\r\n.x-form-invalid-tip .x-tip-body {\r\n    background-image:url(" + escape(__webpack_require__(585)) + ");\r\n}\r\n\r\n.x-tip-anchor {\r\n    background-image:url(" + escape(__webpack_require__(1063)) + ");\r\n}", ""]);

// exports


/***/ }),
/* 1060 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDwAPAIcAAGVlZUD/QIuLi4+Pj5OTk5eXl5ycnKCgoKSkpLy8vL29vb6+vr+/v8DAwMHBwcLCwsXFxcfHx9HR0dLS0t3d3ejo6O/v7/Hx8fPz8/T09PX19fb29vf39/j4+Pn5+fr6+vv7+/z8/P39/f7+/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAEALAAAAAAPAA8AAAipAANMGEiwIMEAEiiQWMiwIQkKEhqA+AACRIiLGENYfMAAhIeKGTFWdNDRA4CTGE8CGMngw0cBAgCIAABTRMUGDVxWHDAAAE8RNkE4WJAhQ4cOHwgonfihwwaSRY9+KECVqdMHRDFw4GCga1cPHjhsaMAgg9YDaD2gPRD2qYIMFxDI9dDBg1wEGjQ0IHqh6NajHbbmdQChAgigI0Y4JHEhQoAEkCNLjhwgIAA7"

/***/ }),
/* 1061 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64, "

/***/ }),
/* 1062 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64, "

/***/ }),
/* 1063 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhJgAKAPcAAI6qzq7C3ODo8uX1+e71/////////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAAYALAAAAAAmAAoAAAiUAA0INABgoIEBAwgoVIhwAICCBiMafDhgIIAAEAkKWKhQAIABAjBmlEjwooCKAgF4tBiAIwGMC0M+lPgwwEaFKVtitHiTwEqXMiHW7IlTo8+MFxfudNlRpE2mBAi2VLgz5caVBoCKTGnSpdGOSHVCjLk14tCFSTlW1ZgRZFmSJW06JHqUZduZcM1+ROgS4cS8gCMGBAA7"

/***/ }),
/* 1064 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1065);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1065 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-menu {\r\n    background-color:#f0f0f0;\r\n\tbackground-image:url(" + escape(__webpack_require__(1066)) + ");\r\n}\r\n\r\n.x-menu-floating{\r\n    border-color:#718bb7;\r\n}\r\n\r\n.x-menu-nosep {\r\n\tbackground-image:none;\r\n}\r\n\r\n.x-menu-list-item{\r\n\tfont:normal 11px arial,tahoma,sans-serif;\r\n}\r\n\r\n.x-menu-item-arrow{\r\n\tbackground-image:url(" + escape(__webpack_require__(1067)) + ");\r\n}\r\n\r\n.x-menu-sep {\r\n    background-color:#e0e0e0;\r\n\tborder-bottom-color:#fff;\r\n}\r\n\r\na.x-menu-item {\r\n\tcolor:#222;\r\n}\r\n\r\n.x-menu-item-active {\r\n    background-image: url(" + escape(__webpack_require__(1068)) + ");\r\n\tbackground-color: #dbecf4;\r\n    border-color:#aaccf6;\r\n}\r\n\r\n.x-menu-item-active a.x-menu-item {\r\n\tborder-color:#aaccf6;\r\n}\r\n\r\n.x-menu-check-item .x-menu-item-icon{\r\n\tbackground-image:url(" + escape(__webpack_require__(596)) + ");\r\n}\r\n\r\n.x-menu-item-checked .x-menu-item-icon{\r\n\tbackground-image:url(" + escape(__webpack_require__(597)) + ");\r\n}\r\n\r\n.x-menu-item-checked .x-menu-group-item .x-menu-item-icon{\r\n    background-image:url(" + escape(__webpack_require__(1069)) + ");\r\n}\r\n\r\n.x-menu-group-item .x-menu-item-icon{\r\n    background-image:none;\r\n}\r\n\r\n.x-menu-plain {\r\n\tbackground-color:#f0f0f0 !important;\r\n    background-image: none;\r\n}\r\n\r\n.x-date-menu, .x-color-menu{\r\n    background-color: #fff !important;\r\n}\r\n\r\n.x-menu .x-date-picker{\r\n    border-color:#a3bad9;\r\n}\r\n\r\n.x-cycle-menu .x-menu-item-checked {\r\n    border-color:#a3bae9 !important;\r\n    background-color:#def8f6;\r\n}\r\n\r\n.x-menu-scroller-top {\r\n    background-image:url(" + escape(__webpack_require__(396)) + ");\r\n}\r\n\r\n.x-menu-scroller-bottom {\r\n    background-image:url(" + escape(__webpack_require__(397)) + ");\r\n}\r\n", ""]);

// exports


/***/ }),
/* 1066 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlh+gABAIcAAOLj4/Dw8P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAD6AAEAAAgfAAMIHEiwoMGBAAQcXMiwocOHECNKnEixosWLGCMGBAA7"

/***/ }),
/* 1067 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDAAJAIcAACluvipxvzJ1vyxwwCt1yjp6zkD/QDiC1jmE0zyE0z2I3UeLyUGJ2VWUzlKg7FSg6Weg1WKq8Y7D9orD/JXL/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAYALAAAAAAMAAkAAAgzAA8YGEiwoAEFCQwaJEABgUKCBCRMYPDQAIEHESAIeEjAQYMAFQksAFDR4oCSBgqgNBAQADs="

/***/ }),
/* 1068 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgAVAIcAAKrM9tno++vz/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACABUAAAgRAAUIHEiwoIAACBMqXMhwYUAAOw=="

/***/ }),
/* 1069 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhEAAQAIcAAAI0cAM3cQI2cgM5cwA7egVGfgZHfQxKfw1LfwBCgQBCggBDggBEgwBFhABGhQBHhwBIhwBJhwBKiABLigBMiwBNjABOjABSjQFSjQZUjQZVjQhVjQhWjRFZjR1cjR1djR5djSNciiBdjSRcii1ijUJmkEBllEVnkUJpk0ZrlEBsnEBtnEZxmUdxmU95nU55nkx8o////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAADEALAAAAAAQABAAAAhYAGMIHEiwoMGDCBMqXEjwxYECLRbCCPFBQwQVCV2MIOEhQwUFKRAiEAGiw4UJDQYgNMBhA4YKEBIEQMhCggUKDxYQOJFwBQMHCgiYWIhCAIASDJMqXco0IAA7"

/***/ }),
/* 1070 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1071);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1071 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-box-tl {\n\tbackground-image: url(" + escape(__webpack_require__(378)) + ");\n}\n\n.x-box-tc {\n\tbackground-image: url(" + escape(__webpack_require__(398)) + ");\n}\n\n.x-box-tr {\n\tbackground-image: url(" + escape(__webpack_require__(378)) + ");\n}\n\n.x-box-ml {\n\tbackground-image: url(" + escape(__webpack_require__(1072)) + ");\n}\n\n.x-box-mc {\n\tbackground-color: #eee;\n    background-image: url(" + escape(__webpack_require__(398)) + ");\n\tfont-family: \"Myriad Pro\",\"Myriad Web\",\"Tahoma\",\"Helvetica\",\"Arial\",sans-serif;\n\tcolor: #393939;\n\tfont-size: 12px;\n}\n\n.x-box-mc h3 {\n\tfont-size: 14px;\n\tfont-weight: bold;\n}\n\n.x-box-mr {\n\tbackground-image: url(" + escape(__webpack_require__(1073)) + ");\n}\n\n.x-box-bl {\n\tbackground-image: url(" + escape(__webpack_require__(378)) + ");\n}\n\n.x-box-bc {\n\tbackground-image: url(" + escape(__webpack_require__(398)) + ");\n}\n\n.x-box-br {\n\tbackground-image: url(" + escape(__webpack_require__(378)) + ");\n}\n\n.x-box-blue .x-box-bl, .x-box-blue .x-box-br, .x-box-blue .x-box-tl, .x-box-blue .x-box-tr {\n\tbackground-image: url(" + escape(__webpack_require__(1074)) + ");\n}\n\n.x-box-blue .x-box-bc, .x-box-blue .x-box-mc, .x-box-blue .x-box-tc {\n\tbackground-image: url(" + escape(__webpack_require__(582)) + ");\n}\n\n.x-box-blue .x-box-mc {\n\tbackground-color: #c3daf9;\n}\n\n.x-box-blue .x-box-mc h3 {\n\tcolor: #17385b;\n}\n\n.x-box-blue .x-box-ml {\n\tbackground-image: url(" + escape(__webpack_require__(1075)) + ");\n}\n\n.x-box-blue .x-box-mr {\n\tbackground-image: url(" + escape(__webpack_require__(1076)) + ");\n}", ""]);

// exports


/***/ }),
/* 1072 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAABAIcAAMHBwdzc3Ozs7P7+/gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAEAAEAAAgHAAUEADAgIAA7"

/***/ }),
/* 1073 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAABAIcAAMHBwdzc3Ozs7P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAEAAEAAAgHAAcACCAgIAA7"

/***/ }),
/* 1074 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCAAgAIcAAKLG9LDP9s7OztHR0dPT09XV1dbW1tjY2NnZ2dzc3N3d3d7e3sHZ+eDg4OHh4eLi4uPj4+Tk5OXl5ebm5ufn5+np6erq6uvr6+zs7O3t7e7u7u/v7+jy/PDw8PHx8fLy8vPz8/T09PX19fb29vf39/j4+Pn5+fv7+/z8/P39/f7+/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAED/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAJoALAAAAAAIACAAAAjPADUJHEhwIAgNFQaKuNAgAACBISYYAHBghSYSFQoEWLGCg6YOCQBw5ODRQgAIHUlqmgAABUmVBQVW0ACiBEEAARpcEDFwxQEABiiEEMiBY4ACFUhoIskRQAIPS5k+CGAhKskTACZoyrAAwAcGYBlsiBDAwIiwIiogAKBABFhNGyQQAKDirEAMDgYAECBBoAcMEA44JIhQQoOYHTSEZfABwIIMYUkYCBBhA1gRCgAgqOB2hAoABCRs0CRBAIABDjAIxHkAAgaomhpImEm4Q8yAADs="

/***/ }),
/* 1075 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAABAIcAAKLG9Nzc3Ozs7P7+/gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAEAAEAAAgHAAUEADAgIAA7"

/***/ }),
/* 1076 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAABAIcAAKLG9Nzc3Ozs7P///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAEAAEAAAgHAAcACCAgIAA7"

/***/ }),
/* 1077 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1078);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1078 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-combo-list {\n    border-color:#98c0f4;\n    background-color:#ddecfe;\n    font:normal 12px tahoma, arial, helvetica, sans-serif;\n}\n\n.x-combo-list-inner {\n    background-color:#fff;\n}\n\n.x-combo-list-hd {\n    font:bold 11px tahoma, arial, helvetica, sans-serif;\n    color:#15428b;\n    background-image: url(" + escape(__webpack_require__(1079)) + ");\n    border-bottom-color:#98c0f4;\n}\n\n.x-resizable-pinned .x-combo-list-inner {\n    border-bottom-color:#98c0f4;\n}\n\n.x-combo-list-item {\n    border-color:#fff;\n}\n\n.x-combo-list .x-combo-selected{\n\tborder-color:#a3bae9 !important;\n    background-color:#dfe8f6;\n}\n\n.x-combo-list .x-toolbar {\n    border-top-color:#98c0f4;\n}\n\n.x-combo-list-small {\n    font:normal 11px tahoma, arial, helvetica, sans-serif;\n}", ""]);

// exports


/***/ }),
/* 1079 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQBiAIcAAMne+szf+s/h+tHj+tTl+9fm+9ro+93q/ODs/OPt/OXv/Ojx/evz/e71/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABAGIAAAggABswWKAgAYIDBgoQGCAgAICHECNKnEixosWLGDNSDAgAOw=="

/***/ }),
/* 1080 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1081);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1081 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-panel {\n    border-color: #99bbe8;\n}\n\n.x-panel-header {\n    color:#15428b;\n\tfont-weight:bold; \n    font-size: 11px;\n    font-family: tahoma,arial,verdana,sans-serif;\n    border-color:#99bbe8;\n    background-image: url(" + escape(__webpack_require__(1082)) + ");\n}\n\n.x-panel-body {\n    border-color:#99bbe8;\n    background-color:#fff;\n}\n\n.x-panel-bbar .x-toolbar, .x-panel-tbar .x-toolbar {\n    border-color:#99bbe8;\n}\n\n.x-panel-tbar-noheader .x-toolbar, .x-panel-mc .x-panel-tbar .x-toolbar {\n    border-top-color:#99bbe8;\n}\n\n.x-panel-body-noheader, .x-panel-mc .x-panel-body {\n    border-top-color:#99bbe8;\n}\n\n.x-panel-tl .x-panel-header {\n    color:#15428b;\n\tfont:bold 11px tahoma,arial,verdana,sans-serif;\n}\n\n.x-panel-tc {\n\tbackground-image: url(" + escape(__webpack_require__(599)) + ");\n}\n\n.x-panel-tl, .x-panel-tr, .x-panel-bl,  .x-panel-br{\n\tbackground-image: url(" + escape(__webpack_require__(1083)) + ");\n    border-bottom-color:#99bbe8;\n}\n\n.x-panel-bc {\n\tbackground-image: url(" + escape(__webpack_require__(599)) + ");\n}\n\n.x-panel-mc {\n    font: normal 11px tahoma,arial,helvetica,sans-serif;\n    background-color:#dfe8f6;\n}\n\n.x-panel-ml {\n\tbackground-color: #fff;\n    background-image:url(" + escape(__webpack_require__(600)) + ");\n}\n\n.x-panel-mr {\n\tbackground-image: url(" + escape(__webpack_require__(600)) + ");\n}\n\n.x-tool {\n    background-image:url(" + escape(__webpack_require__(395)) + ");\n}\n\n.x-panel-ghost {\n    background-color:#cbddf3;\n}\n\n.x-panel-ghost ul {\n    border-color:#99bbe8;\n}\n\n.x-panel-dd-spacer {\n    border-color:#99bbe8;\n}\n\n.x-panel-fbar td,.x-panel-fbar span,.x-panel-fbar input,.x-panel-fbar div,.x-panel-fbar select,.x-panel-fbar label{\n    font:normal 11px arial,tahoma, helvetica, sans-serif;\n}\n", ""]);

// exports


/***/ }),
/* 1082 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQAsAYcAAISgxKvH7LjP7rrQ7rzS773T77/U8MHV8MLW8MTY8cbZ8cja8snb8svd883e88/f89Dg9NLh9NTi9NXk9dfl9djm9trn9vP3+////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAABACwBAAhFAAFcsGChAoUJEiJAeOAggIABBAoYOIAggYIFDBo42Mixo8ePIEOKHEmypMmTKD1iWMmypcuXMGPKnEmzps2bOHPaBBAQADs="

/***/ }),
/* 1083 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhDAAsAYcAAED/QJm76KvH7LHL67jP7rrQ7rzS773T77/U8MHV8MLW8MTY8cbZ8cja8snb8svd883e88/f89Dg9NLh9NTi9NXk9dfl9djm9trn9tzo9t7p99/o9t/q9+Hs9+Tr9uPt+OXu+Obv+Ojw+erx+ezy+u70+u/1+vH2+/P3+/j7/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAMAAAAALAAAAAAMACwBAAj/AAEEGEiwoMABKBIqTDhgIAoMECNCROFQokSKAVBc2MhxI0YUFkKKDPmxgsmTJj9SWMly5ccJMGPC/Cihps2aHyPo3KnzI4SfQH9ixCCgqNGiGAZmIMC0KdMMAzUUmEp1qoaBHAxo3aqVw8AOB8KKDdth4AcEaNOi/TAQRIK3cN+CGBhCgd27dkMMFLGgr9++IgaOYEC4MOERA0k0WMx4MYmBJRxIniy5xEATDzJrzmxi4ImgQU84BA3UJ2kIpkmnBr06aOvSo0+/FhpbdW3Wt13nhp3xNOrdtHvLBv5buG3juJHrVs4bhe/ZxZ0PZx5c+nHrybEv1978OXHo4L+L/6ce3Tv58OfHc69ufn356e7Rx1ffvj58+9fxZ9e/nX/3+wDmF+B+A/ZX4H8CJkigggYyiOCCEDYY4YMSVkjhhewdmKGDG07YoYUfYvgehyN6WCKIJ4oon38htpiiiytq+OKMMZJYo4k3oohRChv06GOPKQzE448+BhnAkERuYCSSRC6ZJJBCPqlklE86WSWVSVqZJZZNcvmjll0eKSWYX3pZpJlQinmlmluyGSaTZboZJ5xnylknnWniOaWdeY6J5p56knmnn3wCSmigfwra55qIFqqooYweKmmklLbZ6KWTWprpm5vO2emglXIaqqejgqppqYueqqqoq5LaqqmsxmfqqqywzmprrbimSquut/KaK6Sv+iossLsS26uxvz6qbKLMOtospqgiO+yyzlYLbbDSZkvttcVu++m0z36rbbjRelsuudiamy663QrpwbvwvrtkvPHOS6+8Aw2Qwr787tuQQAUFDEBAADs="

/***/ }),
/* 1084 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1085);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1085 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-window-proxy {\n    background-color:#c7dffc;\n    border-color:#99bbe8;\n}\n\n.x-window-tl .x-window-header {\n    color:#15428b;\n\tfont:bold 11px tahoma,arial,verdana,sans-serif;\n}\n\n.x-window-tc {\n\tbackground-image: url(" + escape(__webpack_require__(601)) + ");\n}\n\n.x-window-tl {\n\tbackground-image: url(" + escape(__webpack_require__(602)) + ");\n}\n\n.x-window-tr {\n\tbackground-image: url(" + escape(__webpack_require__(603)) + ");\n}\n\n.x-window-bc {\n\tbackground-image: url(" + escape(__webpack_require__(601)) + ");\n}\n\n.x-window-bl {\n\tbackground-image: url(" + escape(__webpack_require__(602)) + ");\n}\n\n.x-window-br {\n\tbackground-image: url(" + escape(__webpack_require__(603)) + ");\n}\n\n.x-window-mc {\n    border-color:#99bbe8;\n    font: normal 11px tahoma,arial,helvetica,sans-serif;\n    background-color:#dfe8f6;\n}\n\n.x-window-ml {\n\tbackground-image: url(" + escape(__webpack_require__(604)) + ");\n}\n\n.x-window-mr {\n\tbackground-image: url(" + escape(__webpack_require__(604)) + ");\n}\n\n.x-window-maximized .x-window-tc {\n    background-color:#fff;\n}\n\n.x-window-bbar .x-toolbar {\n    border-top-color:#99bbe8;\n}\n\n.x-panel-ghost .x-window-tl {\n    border-bottom-color:#99bbe8;\n}\n\n.x-panel-collapsed .x-window-tl {\n    border-bottom-color:#84a0c4;\n}\n\n.x-dlg-mask{\n   background-color:#ccc;\n}\n\n.x-window-plain .x-window-mc {\n    background-color: #ccd9e8;\n    border-color: #a3bae9 #dfe8f6 #dfe8f6 #a3bae9;\n}\n\n.x-window-plain .x-window-body {\n    border-color: #dfe8f6 #a3bae9 #a3bae9 #dfe8f6;\n}\n\nbody.x-body-masked .x-window-plain .x-window-mc {\n    background-color: #ccd9e8;\n}", ""]);

// exports


/***/ }),
/* 1086 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1087);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1087 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-html-editor-wrap {\r\n    border-color:#a9bfd3;\r\n    background-color:#fff;\r\n}\r\n.x-html-editor-tb .x-btn-text {\r\n    background-image:url(" + escape(__webpack_require__(121)) + ");\r\n}", ""]);

// exports


/***/ }),
/* 1088 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1089);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1089 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-panel-noborder .x-panel-header-noborder {\r\n    border-bottom-color:#99bbe8;\r\n}\r\n\r\n.x-panel-noborder .x-panel-tbar-noborder .x-toolbar {\r\n    border-bottom-color:#99bbe8;\r\n}\r\n\r\n.x-panel-noborder .x-panel-bbar-noborder .x-toolbar {\r\n    border-top-color:#99bbe8;\r\n}\r\n\r\n.x-tab-panel-bbar-noborder .x-toolbar {\r\n    border-top-color:#99bbe8;\r\n}\r\n\r\n.x-tab-panel-tbar-noborder .x-toolbar {\r\n    border-bottom-color:#99bbe8;\r\n}", ""]);

// exports


/***/ }),
/* 1090 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1091);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1091 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-border-layout-ct {\n    background-color:#dfe8f6;\n}\n\n.x-accordion-hd {\n\tcolor:#222;\n    font-weight:normal;\n    background-image: url(" + escape(__webpack_require__(605)) + ");\n}\n\n.x-layout-collapsed{\n    background-color:#d2e0f2;\n\tborder-color:#98c0f4;\n}\n\n.x-layout-collapsed-over{\n    background-color:#d9e8fb;\n}\n\n.x-layout-split-west .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(606)) + ");\n}\n.x-layout-split-east .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(607)) + ");\n}\n.x-layout-split-north .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(396)) + ");\n}\n.x-layout-split-south .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(397)) + ");\n}\n\n.x-layout-cmini-west .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(607)) + ");\n}\n\n.x-layout-cmini-east .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(606)) + ");\n}\n\n.x-layout-cmini-north .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(397)) + ");\n}\n\n.x-layout-cmini-south .x-layout-mini {\n    background-image:url(" + escape(__webpack_require__(396)) + ");\n}", ""]);

// exports


/***/ }),
/* 1092 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1093);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1093 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-progress-wrap {\r\n    border-color:#6593cf;\r\n}\r\n\r\n.x-progress-inner {\r\n    background-color:#e0e8f3;\r\n    background-image:url(" + escape(__webpack_require__(1094)) + ");\r\n}\r\n\r\n.x-progress-bar {\r\n    background-color:#9cbfee;\r\n    background-image:url(" + escape(__webpack_require__(1095)) + ");\r\n    border-top-color:#d1e4fd;\r\n    border-bottom-color:#7fa9e4;\r\n    border-right-color:#7fa9e4;\r\n}\r\n\r\n.x-progress-text {\r\n    font-size:11px;\r\n    font-weight:bold;\r\n    color:#fff;\r\n}\r\n\r\n.x-progress-text-back {\r\n    color:#396095;\r\n}", ""]);

// exports


/***/ }),
/* 1094 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhCQBOAIcAAN/o8uDo8+Dp8+Hp8+Lq9OPq9OPr9OTr9OTs9OXs9ebt9eft9efu9uju9unv9urv9urw9+vw9+vx9+zx9+3y+O7y+O7z+O/z+fD0+fH1+fL1+vL2+vP2+vT3+vX3+/X4+/b4+/b5+/f5/Pj6/Pn6/Pn7/Pn7/fr7/fr8/fv8/fz8/fz9/v39/v3+/v7+/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAAJAE4AAAj/AF8IHDjwgMGDBxMoXMiw4UIFECNGXECxYsUGGDNq3JjRgcePHyGIHDkygsmTJyWoXLlygsuXLynInDmzgs2bNy3o3Lnzgs+fPzEIHTo0g9GjRzUoXbp0g9OnTzlInTq1g9WrVz1o3boVxIevYL+GAEG2LFkRaNOmHcG2bVsSJNy2NWGihN27JU7o3bs3hd+/f1WoAPx3heHDh1koXrzYheMWkCM7nuxCcuXIkBlrRsx5BeHPgFGI5ksaL964clOnVsvarOuwsLnKxkqbqm2ouJnqRsqbqG+gwHkKx0mcpnGYyFmyRMmcJMkHD0BK50gdI4PrFrNL3O5wIYLv4MEbIBhPnnyB8+jRE1jPnv2A9/DhC5hPn36A+/jxA9jPn39AADs="

/***/ }),
/* 1095 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAQBgAPcAAHOh4Hml4n+p5Hyr7IWu5oay7oqy6JC26pa67Jy/7pC58Zm/86DE9ajJ97DP+bfU+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACwAAAAAAQBgAAAIJwAfCBxIsKDBgwgLOmjAYIGCAgMABBBAwMABBAkyatzIsaPHjxwDAgA7"

/***/ }),
/* 1096 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1097);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1097 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-list-header{\r\n    background-color:#f9f9f9;\r\n\tbackground-image:url(" + escape(__webpack_require__(232)) + ");\r\n}\r\n\r\n.x-list-header-inner div em {\r\n    border-left-color:#ddd;\r\n    font:normal 11px arial, tahoma, helvetica, sans-serif;\r\n}\r\n\r\n.x-list-body dt em {\r\n    font:normal 11px arial, tahoma, helvetica, sans-serif;\r\n}\r\n\r\n.x-list-over {\r\n    background-color:#eee;\r\n}\r\n\r\n.x-list-selected {\r\n    background-color:#dfe8f6;\r\n}\r\n\r\n.x-list-resizer {\r\n    border-left-color:#555;\r\n    border-right-color:#555;\r\n}\r\n\r\n.x-list-header-inner em.sort-asc, .x-list-header-inner em.sort-desc {\r\n    background-image:url(" + escape(__webpack_require__(1098)) + ");\r\n    border-color: #99bbe8;\r\n}", ""]);

// exports


/***/ }),
/* 1098 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhsAQuAIcAAE2AxmmV0XWe1YWq24mt3Z275KG+5tno++vz/fn5+QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAACwBC4AAAj/ABMIHEiwoMGDCBMqXMiwocOHECNKnEixosWLGDNq3Mixo8ePIEOKHEmypMmTKFOqXMmypcuXMDEimEmzps2bOHPq3Mmzp8+fQIMKHUq0qNGjSJMqXcq0qdOnUKNKnWoTANWrWLNq3cq1q9evYMOKHUu2rNmzaNOqXcu2rVukAAQIeEu3rt27ePPq3cu3r9+/gAMLHrw1LoECBggrXsy4sePHkCNLnky5smWlhhEbSHy5s+fPoEOLHk26tOnTqFOrXs26tevXsGPLnk27tu3buHPr3s27t+/fwIMLH068uPHjyJMrX868ufPn0KNLV32guvXr2LNr3869u/fv4MOL/x9Pvrz58+jTq1/Pvr379/Djy59Pv779+/jz69/Pv7///wAGKOCABBZo4IEIJqjgggw26OCDEEYo4YQUVmjhhRhmqOGGHHbo4YcghijiiCSWaOKJKKao4oostujiizDGKOOMNNZo44045qjjjjz26OOPQAYp5JBEFmnkkUgmqeSSTDbp5JNQRinllFRWaeWVWGap5ZZcdunll2CGKeaYZJZp5plopqnmmmy26eabcMYp55x01mnnnXjmqeeefPbp55+ABirooOvFZOihiCaq6KKMNuroo5BGKumklFZq6aWYejTdppx2ihMAoIZqlaeklmrqqaimulsAA7TKmaqwxp4q66y01hqYq7bmquuuvPbqq1Ov/irssMQWa+yxyCar7LLMNuvss9BGK+201FZr7bXYZqvtttx26+234IYr7rhBEWruueimq+667Lbr7rvwxivvvPTWa++9+Oar77789uvvvwAHLPDABBds8MEIJ6zwwgw37PDDEEcs8cQUV2zxxRhnrPHGHHfs8ccghyzyyCSXbPLJKKes8sost2xgQAA7"

/***/ }),
/* 1099 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1100);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1100 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-slider-horz, .x-slider-horz .x-slider-end, .x-slider-horz .x-slider-inner {\r\n    background-image:url(" + escape(__webpack_require__(1101)) + ");\r\n}\r\n\r\n.x-slider-horz .x-slider-thumb {\r\n    background-image:url(" + escape(__webpack_require__(1102)) + ");\r\n}\r\n\r\n.x-slider-vert, .x-slider-vert .x-slider-end, .x-slider-vert .x-slider-inner {\r\n    background-image:url(" + escape(__webpack_require__(1103)) + ");\r\n}\r\n\r\n.x-slider-vert .x-slider-thumb {\r\n    background-image:url(" + escape(__webpack_require__(1104)) + ");\r\n}", ""]);

// exports


/***/ }),
/* 1101 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAABCCAMAAACsGTw+AAAALHRFWHRDcmVhdGlvbiBUaW1lAFRodSAyNyBNYXIgMjAwOCAwMzo0MDoxNyAtMDUwMLm0WfoAAAAHdElNRQfYBBoWIzvvlGReAAAACXBIWXMAAA7CAAAOwgEVKEqAAAAABGdBTUEAALGPC/xhBQAAACRQTFRF////vLu4xM3Rs6+pw7+53drX0M3HzMfBqqShw8TBzMjBvLu5ACxD7wAAAAF0Uk5TAEDm2GYAAABGSURBVHjazZC5DcAwEMPkyIm//fcNEOK8wLkIGwFqREhK0kEX6Iad0RfIzuVZ+Fbj5YlnZPT6ie9nO8SPrvzaTD7e/SHdFwQ4AeewCIHLAAAAAElFTkSuQmCC"

/***/ }),
/* 1102 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACoAAAAtCAMAAADvGAnRAAAALHRFWHRDcmVhdGlvbiBUaW1lAFRodSAyNyBNYXIgMjAwOCAwMzo1MDo1OCAtMDUwMAo4+CkAAAAHdElNRQfYBBoWJQbhpo/JAAAACXBIWXMAAA7CAAAOwgEVKEqAAAAABGdBTUEAALGPC/xhBQAAAX1QTFRFgP+Arcrpl7fpoLrdscvr3fH/zuX/1Or/b5TS8v//ttHursvpss3rqt7/lMn/nczzrt//2v//0f//yfr/x/r/bKLn8P//wvX/v/L/u/D/wfT/vPH/t+z/suj/sej/uO7/sun/rOP/qOH/xPf/wfP/ue7/pd//z///zP3/yfv/xPb/vfH/p+D/1///1f//0///zf7/sOf/reT/3v//3f//tuv/4///4v//4f//3///y/z/xff/6f//6P//5///5P//3P//1P//zv7/s+b/6///6v//5v//4P//2P//rN//r+H/y+P/yuP/xd//wdz/vtr/xN7/v9v/utf/tdP/tNP/u9n/tdT/rs//q83/x+H/w93/vNn/qMv/0uj/z+b/y+T/x+D/wNv/qsz/2u3/2Oz/1er/0Of/s9L/sND/4PL/3/L/3fD/udf/uNb/5vb/5fb/5PX/4fP/yOH/6/r/6vn/6fj/5/f/3vD/1ur/0ef/7vv/7fv/6Pf/4/T/2+7/wtqANAAAAAF0Uk5TAEDm2GYAAAFmSURBVHja7dTJP0JRFMDx5+F1b3hE9yqSkFlCSqXMs5QhIbOEpJQyD3+7dzevPi3uiY2N3+Ksvp+zOp8jCFpRrVbgphXf3nP5j/RnIvkl1nCpmMs/PmWyz7GXV0kS+TR9n8kmEZYeotEoQBO3yVgc4eBdKpUCaOwyfhVA+PpGCaDHJ6dn5whfsAAaOIgeRhA+YgF0I7gb2UN4nwXQza3tnTDCYRa4NRQKIRxiAXQ9oIQwmwGAaori0yqxWk2s5FKhonBZgCxpXlZbg+TCos+/5Fp26FbkVS6Vff6pabdnxjY75/XKfOqacHt0hHonrVYrQB3jOpudUIPJ6XQC1DZsH9ETOjqmBNDevv6BQUKHWADVd1m7LYT2sADabGi3dBDayQJoS6upzUyomQVuNRqNhBpZAG3SKxHKph6gjUXxaYOsU5PruVSoK1wWIEv6yZeU1KAvKRUllkGVL/lP/5ZqNGXQX3/Jbwi0RujXrZtBAAAAAElFTkSuQmCC"

/***/ }),
/* 1103 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAHCAMAAACLH2sFAAAALHRFWHRDcmVhdGlvbiBUaW1lAFRodSAyNyBNYXIgMjAwOCAwMzo0MDoxNyAtMDUwMLm0WfoAAAAHdElNRQfYBBoWJAgfBZOPAAAACXBIWXMAAA7CAAAOwgEVKEqAAAAABGdBTUEAALGPC/xhBQAAACRQTFRF////qqShxM3R3drXvLu4w7+5s6+pvLu5zMjBw8TBzMfB0M3HAgaZwgAAAAF0Uk5TAEDm2GYAAAA6SURBVHjaY2CAAkYmZmYmFgY0gF2UgZWNjRVDkCQjONm4uNlYKDICh9sGsxHsbBwcbJQZgT3sUdUCAGGeAYGTRrHZAAAAAElFTkSuQmCC"

/***/ }),
/* 1104 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAC0AAAAqCAMAAAAQwSIQAAAALHRFWHRDcmVhdGlvbiBUaW1lAFRodSAyNyBNYXIgMjAwOCAwMzo1MDo1OCAtMDUwMAo4+CkAAAAHdElNRQfYBBoWJSAzqwo0AAAACXBIWXMAAA7CAAAOwgEVKEqAAAAABGdBTUEAALGPC/xhBQAAAX1QTFRFQP9AoLrdl7fprsvpzuX/ss3r3fH/1Or/8v//b5TSrcrpttHuscvrnczzlMn/rN//0f//x/r/u/D/sej/qOH/pd//p+D/reT/tuv/wfP/y/z/r+H/2v//2P//zv7/t+z/xff/1P//3v//sOf/v/L/1///4P//8P//3P//4///bKLn3///5v//rOP/sun/vfH/0///4f//6P//suj/ue7/xPb/zf7/5P//6f//uO7/yfv/5///6v//vPH/xPf/zP3/1f//3f//4v//6///qt7/yfr/wvX/wfT/z///s+b/rt//yuP/vtr/tNP/q83/qMv/qsz/sND/uNb/w93/2+7/0ef/3fD/udf/yOH/1ur/4PL/s9L/wdz/2u3/4/T/3vD/5vb/4fP/6Pf/rs//tdT/wNv/1er/5PX/6vn/tdP/vNn/x+D/0Of/5/f/6/r/utf/u9n/y+T/6fj/7fv/v9v/x+H/z+b/2Oz/3/L/5fb/7vv/y+P/xd//xN7/0uj/wYSqewAAAAF0Uk5TAEDm2GYAAAE0SURBVHjaY2DgYUIAbgYCgIuJvbqmtsa7LjYqIY+gciY2du+YkpjSsvKKyowqJiJU++QXBBemhaUXFROlOjMlKzsnNjE3jyjVvskpqd5AwzOIUM0JA4lJRKjmgIH4BOJc4ucfEB3DEhtHtOrA8IjIKOJVBwWHhpGimiWEkGpGJiTVTKwMBJUjADMhxejAiw8BPAkpduETcHVzdxP0UFXStCConE9GQFDFVsXO3sHRyciZjwjVQvKWklYGMobWNkSpNtYzMTVT1Ta3IEq1sK6eviDQcCMiVGvBgLYOEarVYUBDkziXiIiKKatIqaoRrVpcXkFRiXjVEpJyMqSolpIlpJqXD0k1nzQDQeUIwE9IMTogsZRkQQAiSkkWZOVDSDWilCRKNbyUHGh30041I0rMk1hKAgAObEPMvjjB3wAAAABJRU5ErkJggg=="

/***/ }),
/* 1105 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1106);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1106 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1.1\n * Copyright(c) 2006-2010 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-window-dlg .ext-mb-text,\r\n.x-window-dlg .x-window-header-text {\r\n    font-size:12px;\r\n}\r\n\r\n.x-window-dlg .ext-mb-textarea {\r\n    font:normal 12px tahoma,arial,helvetica,sans-serif;\r\n}\r\n\r\n.x-window-dlg .x-msg-box-wait {\r\n    background-image:url(" + escape(__webpack_require__(376)) + ");\r\n}\r\n\r\n.x-window-dlg .ext-mb-info {\r\n    background-image:url(" + escape(__webpack_require__(1107)) + ");\r\n}\r\n\r\n.x-window-dlg .ext-mb-warning {\r\n    background-image:url(" + escape(__webpack_require__(1108)) + ");\r\n}\r\n\r\n.x-window-dlg .ext-mb-question {\r\n    background-image:url(" + escape(__webpack_require__(1109)) + ");\r\n}\r\n\r\n.x-window-dlg .ext-mb-error {\r\n    background-image:url(" + escape(__webpack_require__(1110)) + ");\r\n}", ""]);

// exports


/***/ }),
/* 1107 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhIAAgAPcAAAAAPAAASAARTwcZRQocSQIdVwADZAAIYgAKbQALfAAYfgwhTw4kUhEjTBAnVBYoUhksVRouWB4xWxMzbRk1Yx82YR43byEzWyU4YSY9ZiE9ayo9ZS4+ZC9CZyVDcihLezNCZTdIbTFKdDVQfj5TeEBNb0hafU5bewAbgwAbiwAgjQQsgQAmkgAnmgAqlwAumwIwjwAwnBg+iQAvowo+phxDjR9HkxpJqhpOvRtQvitJhDFPhT1chj9ijjtilD5hmylezEhgh0Fim1VjgltnhFxri1FtlV5zlk1solZ8p1Z/rF9+o2Rvi2Vwiml1j2l5lG15k216l3Z/l1yKuXiBmHqEnGOGq2mBp2OLsmWRvm2Tu3CKtHGQs36UsHucvU6G31GF42OHyWmNwXWWyHOawHqVwHubyW6h1nigxnCi03Gh1XKq33yo14OLoYqSpoyTp4uTqIicvZGXq5GZrpSarJedr5CftoSiv56ltaaru6iruqisuqmuvaywvoWdx4efyIKjxIClzoSpyouqxIusy4Co2oqv1Iyy05CmwZWtw5KuzJmuwpmu1JOxzZqww5qyy5K01JO22Ja425i205651Zu72JG64JS+5qaxw6S3yqa5y6myw6m2yKm7yaO807G1wrW4xbS9yri6xbm9yJ7B5ZzE7J3B8afA1qzE27bCzLvCyrHE1bDG3rTJ37jF1b3I1r7N26PE5aTG6KrG4qrH6KzJ56LK9aHM86TK9qbN86fN96XP+afR/azS+rTM47TP67jO5LzS5bLU9bDU+LbY8bTZ/LnX9rnY9bvd/b3i/8HDzMLFz8DG0cXL1cnK08/Q1srS3dPU2tLY3dvc3sbZ68/a5cvc7sTa88Le+tDX4tHa5dLd6Nvb4dvf5tzb4N3d4MTi/srk/s3o/9zi69Li8tHm/dPq/trm893p9Nvt/tPz/9zx/9/5/+Df4+Pj4+Ll6ebo6+jn5+vr7OPq8+Hv/+Py/uP6/+r1/uz6//Dw7vX18/H2+/P7/vn49v3+/uDf4yH5BAEAAP8ALAAAAAAgACAAAAj+AP8JHCiQ2ztt4+QpXDhv2zJnBCNKFMhMmr58/fxp3NgvI79NECdG7PauY8aNqvro28jPIyaRAttVi5dv5UZ/JAAAKHBS4759/lyFErnNXTygN6EFQJHCwJab/vjN82ctj8Rq7uAhjcrP37wDMb7MYBT1Xld/+9DtQ5XH28Bs094h5Ud3X1c/N8CEKXuvb9d76PB1ARUT2repUX/yw3c2Kt979SJ3RYeOWpRn/7JF63YPLb57n7ue5dfXXmR6qNctJrfuCB1vsKSNo9u3Nr4rFnTsmCAgDr969NalG14PXzlyrIo4SwUtMOR6kEH/WZEghQoEZfgJH57OnDl75aj+BQuRJ1Wzc8+B05PMzwaLGCjMaO/u3fs6csGCSXCT6hW5e6nRk84669TDDxIowGcGPvSVY045DoYDTDARtNEfa9txZ846+AiRYHz4mCOOOOWMKI452AADTIWcuGINd/R5l449HioInjjhhIOjjtf4MgsEbXgSSjDlxPigd+zUiMIY9uwITjhPgvMLK5Gw2Mkq13hHoonmsPPDh2OwAyU4ZJJpzCyoGPEAHM6c0kkr4ZS4o47rfAnfGOuQmQw4yCSDTC2nQKIBCFYhookmvoCDI5k6JomCCwqIYQ84fiIDTjG0UFJJEgQwAVE0dyySSS3YjKkjMTK8QMMLNRBDaZ/+mE7SCBkMcFCHW/9gMkgij8xyDJnqmIFACzgAAQQOMBTCZy+xQNIIGho8AEVIAtnhhSOPUBKLMMkMY0oxu+CCSzK86DKMLJI00ogWHjRABGEEtTOHFbsqMkkl2xZzTDL8DkMKJIQQIogSDjwwBB+4EuQNHkVgcccggwAiCCGHkNJLLpIoQgggU3iwwAVOfDINTKNQEQQPS3ih8h2ElFKKIVr08MEAEpzghjIwDRRNH1IMQUIGInDRsi2BUNAAB0O0IUo0OUcUzdOflDDCIZfwwsYFTeSxDNNNw6RMB1lYsosaG9DxTddd77HBFLecgYEcaKMNiglprFHBGyPH3fQSM0/4sMEbCesN08JV9BG4RAEBADs="

/***/ }),
/* 1108 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhHwAgAPcAAAAAAAAABQAACAAAEgAAFQAAGQAAHRAKBgAAIgAALgAAMQoAMBUAPiQZEScXJCcZIAAAQgcASxkBRR4ISh0QQwAAagAAfAYPcQsPdwwScw4UchcFYx4LbxEXbxUZbhodahESexQYfx0gaTEaYT0nTzIwXzUyXSQnZSgpZCssYi4tYi8wYjchaDEvYDEwYDs4bE06GFA8K0QxTkE/WVpODFhEHlxNLm1VImRQMnldIUBAWElJVFhOTlBHUVFTT3dhVn1iXRIUgBsdhiUrhSUthy4yhy81iTtBiFBAklNUh2lbumNlnmhqp29xp3Z4rn+Cr4x7HYNpIYFrNoR0Nox2M5WJLZ6JKZCAMZ+UKaWOE6qRFr+fEqWbJrOXPaemEbSjAbSvHb+6GLKoILidT8arDMulAs2kAMmoBs6uBsO4AtaqANWtANC8ANqwAN6yAN60AOC0AOK4AOW6AOS+AMbFFcrKI+bAAOfFAOXLAOrAAOjHAOrHBe/AAOzGAOrLAOzKHuXUAObcAOrUAezTD+nbAOrYDOjSFOzQGvHBAPHFAPXHAPHJAPXIAPXOAPnKAPnMAPzLAP3OAPPSAPLVAPfQAvLaAPnWAf/SAPzRB/7VAP7VBfjbAPreAP/ZAP/ZBP/dAP/dBv7bCv/fCv7fDObFKeTCPeXhAOnjAOrpAPLjAPHqAPnhAPvlAPjlBP/hAP7hBv/lAP/mBf/jCf/hDP7lCfroA//oAP/qBf/tAP7qCf/jEP/oEf/pFP/tEf/sFP/uG/PzAPn2APn0BP7xAP71AP/1Df79AP/+C//0Ev/yGf/wHf/3Gf79E//9HOPiI///Iv/+JP//Kfb2Pv//MenOaOvRYOnefuzqWevmZOrjbuvoZergfv//aIaIr4uLq4KCsomNsI6OsZCPuZKSt5WVuJaYuZmZtZqauqantqWkvbu6zL6y/+jZi+nciundjuXbsOrpocPC0cfH1srJ1dPT2tjX3dnZ39/f39va4Nzc4ODf4+PkwuHg1uHg3+Df4wAAACH5BAEAAP4ALAAAAAAfACAAAAj+AP0JHEhwID94BRMqXChwHzNj0uoxnJiwH7BgxozVEUexo79rqIxFy+jjm0eG/FChWsbtmDE6IOKdVKjNlKpm055h3LFkZsJTp4QxOwaNmLEwGOb5HIjNVKpjLpsxM7qDyVJ/94AOm5rm2DOjYEIo9Zkt0FMvAAAIcMZsmDEdTZYSIrRVgIAFCmw0cysmCL2Z2QA9PQaAgAQIMZgxwzVshpOZhQi1enjAAAMIN4xBw0WMi5C/HbcBqlTMJY0EEyRkMdZsGathK554FARoMi5jXxKwIIGHWLFntoZh+UzRGh5BuYrZMsYGARIZxnDZaobM1aoS3SgawlMJ2S1Yw2z+OVCCg5gtWMWaccJVZYjEhe7w+KFVbBWs5TUsaDHmylWsZrls4soJ4TA0CB6T9HJLf7AYA0UFaBADS3/LLGOJLe3lo1B8fryCzCef9DcMGRH4gYsrIMYCzSufTJLCOAodoockvdACIoiwWELBJ7bc+EmFlsByhREaEtSOHn6M0ssnnXQCoiuwbDEhk0y+Eo0smXyCAjkF7XEHJb7I0mSTn+DCmS09jtlJMtBc4ooVRBTpDztz9BHKLk1m0qQtZwwQwAOZuJJnJp5AI8oljagAzkB/2LGILqBkIqmetjQAQAEK5DDMpJLy8ssjrkxRBD7+vDNHHpjMksklq+r5SQCqA4zAARC4SHrJrZ4oo8kjiXhgjj/VxJGHJp5wSikMBGywzhiwdGLsLJow0gkPR/hDyhtyJKKIIowwwq0jl3QSxQ9dXOJIt9x2y0gifFxCxQXqULNGG2+4Ye+9bsAhhyOQIBIHvvfCEQcfkfTQgTf+lNJGGWY07PDDEEeshhtSZCDCr/6g80ILJXTs8ccgf+yCCSpo8EES9gwkTznlnOPyyzDHLLM56ZAaEAAAOw=="

/***/ }),
/* 1109 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhIAAgAPcAAAAXVwAWXQAbXQASZgAcawAcdAAffw8sbQAhcwAkegMpdwkxfRQ1eENGS0xLTUxOUkhQWVJSVEhVYUpabFRbZVxeYlVneVJof2ZmaWhnaWdscmVve3R0dnh6fQAlgAAqhgErjAEwlAc5mww7nBo+iBQ9kA8/oR5JnBtKqyJHkihOmTJTlTRYmSBOpiRSqypSpitVqDJYpTpfpjFiwjtry1JrhlJtiVtug154k0NqrEltq1x3ql1/oF98rFp9umFvgW12gWl5iXJ7hkFwxm+Cl3+AhWGBomaLrWmBrm6Lp22LqmiGvGqKv22RtGqRuHWNp3CKvHSVtnaZvXmWtHmXuHycvFqD0GKHyGuXwnGOxXmTw3iWy3ufwnGgz3Oh0X6j0IWEhouLjY+PkY+RlYmSnpWUl5aXnZ2dn4iVo4CWvoCatJOerJifqYWgvI2lvJOirpKnvJSpvZmls56ptpqsvaCfoqOjpqinqquqrqqrsa6zurCvsrOytbi3uru6vYCZy4KjxIagy4WpzIymwo2lyoypxYytzISj0oWq0Iyu0Yqs3oyz2petxZKuyZyvwZ6uzZCv25ewyZ6zx521zpS11JS12JW425mz05y724Gu94my6I+195e355W845i74KKzw6O4zKu1w6i3yqC716C72Ku+0bW8x7C/zr++wZbA6Z7C5pvC6p/E8K3C1arD27XBzLrBy7HD1bHF2bjF0rvJ1r3N26LC46TH6aTI7KrG4qrI56rL66fO9KnN9azR9q3S+bPK4rPP8rbS7bvQ5bPS87Xa/bvV87zd/r/h/8fGycjHy8vKzcTJ0sPO2c3O08vT3NPS1dLV2tjX29ra3sHV6cTa78jU6cra7MTc9sPc+Mrb8tDX49Lb5dHf7N3d4sTh/svk/s3o/9Th797h5dzj69Hh8tDm+9Pp/tnl8d/o89vs/t7x/+Df4+Pk5eHm6+Po7Orr6+Tr8uHt/Oru8+Py/+7y9ur0/ez6/vHw7/Lz9PL2+vL6/vz9/uDf4wAAAAAAACH5BAEAAP0ALAAAAAAgACAAAAj+APsJHChwnDdu7t7BW7jQHbdo06YRnEjR2zh38PDl08ePI8d8+ea5e+ZMIsWJ48hl1MeRn8uXLvXVm0eOmTNvJ/sdbAcvH8yfP+3Ne0cLlkmCO+HVA2rtTxYtj8jB1BfPXS090iZyY/fOp8t9/Ort8PACRoEAB9LsA9sxHblYeY5um+Zu3te1+5AMKKFN3goECQgA2mcPrD103ej4YafzGbd3YNfq2yePwQcPUPilIRCiwAp59OiBVdetFpll/bZFI2f3nj3X9uQpAPFBxr1LCEIkSKHN3rp1rsu1coRnWq3Vr+0pX77EBY0t+wjl9qCi3Dp16oCbk1XKjLJZz9D+wQ5NXp0xbOru9SggIoQPetjPZT9HrdQaPq+aobNHXt46/+TRow0JINBgBXrnJCifOcO08sYYsNTSDT3/ZScPdhiuc4gBM2wCjoLnhBPOOeA0+EYRr9DSzXUYxqeOgieMwImC4IhYYzjYANMKGh2IMss1LoKooDEhXLFOiOAkqSQ42QAziRAdSHLKMOYIGaKI5wTTgiLqJPkNON+EGaYwrgyiQRinfBJLNQnaaGOS4RzjpZh0GpPLJE9gcEczcYgCDDbh1Kjkl+BAwsQhx4iJDDLHMLrLKIbcwIEf0zBCByh/zhlmOF8EAEAAOnzD6DGkHrMLKY1E8UAZzvTDjBr+cWCaKJ3IsEDABwgs0MuoxRSzCyaFcCEBBqhI5E0oasAxSS7GNNooMjkUYAIKJ/hyTK+/3FJJIVVcEIEdR0kjxxRuREKKLsT0igwrMQyRiSbH/PILLp5QMogUNTwgBjQTQcNGEmoM0sglmNiyiy++/NJrL6pYkgi3R0wQQRjK4DSRNHkQoUQVbbQBiCCGVKLKL7x4YgggVTRhAwQVnOEMYydNg8oYP+CgBBVTUFFFIquskogUPNjQQARg8BFNTgOxEw0qdRQBxAZBTAFIJ6sIYoEDGIDRBzRHIS0QO9JAkwwfd6wByCKrfEFBGclAY7HXJ7ETkTNcIJKKFxTw8TYn3F6zY4oTi3RBAaV8Fz7NHFjg3UfXhSMtrhGDM954TtLsIUbFXgcEADs="

/***/ }),
/* 1110 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhIAAgAPcAAAMDAwoDBAwAAAkJCRECAhcXFxoTExsbHB4eHiAAACMQESkZGjAAADcAADkBAT8BAS4tLi8vMDEmJjU1Njw7PUUBAU8AAE0KClQAAFsAAF0BAU05Om0BAWIaG3IBAXQAAHgBAX4AAGIzNEZFRkdHSElJSlNSVFRUVWZRU25WVnRWVnFZWXpfYGdgYGZlZ2dmaGtrbXVgYHxoanZ1d318fn5+gIEAAIUAAIoAAI0AAI8PEJEAAJAGBpUAAJkAAJ4BAZY4OaEAAKMEBKUAAKYFBakAAKkFBa0AAK0FBbMBAbQICLoCArwLC74cHKsjJK4kJaspKakvL68yMrsiIrM6Oo9KTIhPUI9bW4VlZ4Jra49tbYlzc414eJZpaZlsbJRzc5pxcZ98fKhfX7VDQ7ZISL5KSqFrbaN7e79ycsMCAsQLC8sDA8sKCsccHc0SEtIBAdEKCtsBAdkLC9QSEtYZGdsWFtkZGc4kJMExMs48PNA0NdE6O+MAAOIMDOkAAOEUFOQcHOoTE+obG/MCAvMODvwGBv4LC/YQEPMbG/8UFP4aGuIuL+oiIus1NvYgIPYtLf0kJP0sLPY9Pf8zM/06O8VIRsxBQcpNTcRTU8VfX8hVVtJISNxDQ95JSddQUNZeXtxVVst0dd58feFNTe5PT/5DQ/5MTPZUVfJXWfdfX/5TU/9bW/BfYONhY+xoau1wcut5e/5kZP9qav9zc/98fOh/gYKBhIuKjY2Mjo+PkZOSlZaWmJuanZycnpq8vKSBga2EhK6KiruFhbOPkaOipaemqa+usbCvsra1uLm5vLy7v768v7++wZvBwaTBwaXLy6rFxavLy6bW1rLY2LzZ2ciTk9GAgsKnquqEhuKRk/+Bgf+MjP+Tk/+amueipOamqeOytf+jo8HAxMTDx8DMzMvKzs7N0MLe3tTHytzDx9DP09fW2tjX29nY3Nzb39zc393c4MDh4crk5Mvp6dPr69nt7dT4+Nv09ODBxeDZ3eDf4+b5+er39/T///7+/uDf4yH5BAEAAP8ALAAAAAAgACAAAAj+AP8JHEgQHCxWp1SZMoXqlTd3BCNKJIhNUqlYs7RpozUrlipKj1qhm0jym0WM27qFC9dtGy1Zq0xRQhSKZERYkUzJosVt5cqW2mbBlAlpjzmb/1zljEVrG7enLjkKjRWz1CRId5aRrBWp1KpZtGgFlaWwVClTqmKasvrI0RRxEsE5omRqVaxYqVRZVcRXEaRJkyRRAhyJESAg5SI26rrQlIwskBIZKjSosiFDiFpcgcSZkZ05MtgNzMZoEiVKksBQo9alsh8+rwfFUeGrmZhEigDZqaOD2MBFjCJNihRmmj9/8brA5gM7zgpfx6WhOfRnjhs1KNT9w1eHEWdIn87+9Tt+DkwcP37esHB2/DgoP9XVuOngWxQdQI4cKSo0St54f/OcEccbW0TTnj+k8NGHHGyooQYPMLgDyhx1CIIIIoT4sQk9/9UjDDDnHDjKG3HIAQcbTDBBxAjj6OHGHH8EEkgffMSRB4fH9fPfcZys8QYcQKbBhBJJSFBMG26wIUcfTA74hiX0HJhjJ2ms4SMba6ShBBJKLMALE2qwoaQccrxh5huV7HNgP3tUaaWVaSyhRBFLKKBLE2CuwQaQZ6YRDD9SVpPGoISmkcQRQiChQC54KLGEGlbCYeYSWVAjpT/3/LJEoUkgMYQQPxiQiyZcborlG0vEAM2lx83zxab+SyyRRBE//IBDAbtYQwQSSWy6xhIpsNdeHp748588WvR6RBFB+PADBwj0ko4QRByhrKoHWpJEEpfc85+rRRQxhA87/ODABMf884QQQljLxTMHXmLttmV4e5w9wATxQw885EDACYkNk8QPQRQRBTn/WTLvtkeMUU97UvSwAw47YFBADQM58YMPQQQBxXiXBHHEyIeKS8ZxT+QwMQ42CECBMQNdM4TEPvhQBiY/DBHuzkM0mwkVOOBwgw04NFDADKINZIYQO+wgcQ8Edyz1xj3kEPQNIeCAwQAkICNRFT/kILbTNZftQw9VC21D1hkAMMEuE+ljxQ5WBz023XUPHYJlDTZYAAAEuLRDEjxYgDDxDYgnPvTaNtzgAQMDTHDLOkj9s4sIH9ygNt97883BAwEcYEIvglf+jzg0bHCBBhx88AEHGlSQwAAIjGALM6YTBI8yubgwwgQRQBDBBCO8gEsy75AUEAAAOw=="

/***/ }),
/* 1111 */
/***/ (function(module, exports, __webpack_require__) {

/* pkg: Tinebase FAT Client (js/Tinebase-FAT.js)*/
__webpack_require__(1112);
__webpack_require__(1113);
__webpack_require__(1114);
__webpack_require__(1115);
__webpack_require__(1116);
__webpack_require__(1117);
__webpack_require__(1118);
__webpack_require__(1119);
__webpack_require__(1121);
__webpack_require__(1122);
__webpack_require__(1123);
__webpack_require__(1124);
__webpack_require__(1128);
__webpack_require__(1129);
__webpack_require__(1130);
__webpack_require__(1131);
__webpack_require__(1132);
__webpack_require__(1133);
__webpack_require__(1134);
__webpack_require__(1135);
__webpack_require__(1136);
__webpack_require__(1137);
__webpack_require__(1138);
__webpack_require__(1139);
__webpack_require__(1140);
__webpack_require__(1141);
__webpack_require__(1142);
__webpack_require__(1143);
__webpack_require__(1144);
__webpack_require__(1145);
__webpack_require__(1146);
__webpack_require__(1147);
__webpack_require__(1148);
__webpack_require__(1149);
__webpack_require__(1150);
__webpack_require__(1151);
__webpack_require__(1152);
__webpack_require__(1153);
__webpack_require__(1154);
__webpack_require__(1155);
__webpack_require__(1156);
__webpack_require__(1157);
__webpack_require__(1158);
__webpack_require__(2721);
__webpack_require__(1222);
__webpack_require__(1223);
__webpack_require__(1224);
__webpack_require__(1225);
__webpack_require__(1226);
__webpack_require__(1227);
__webpack_require__(1228);
__webpack_require__(1229);
__webpack_require__(1230);
__webpack_require__(1231);
__webpack_require__(1232);
__webpack_require__(1233);
__webpack_require__(1234);
__webpack_require__(1235);
__webpack_require__(1236);
__webpack_require__(1237);
__webpack_require__(1238);
__webpack_require__(1239);
__webpack_require__(1240);
__webpack_require__(1241);
__webpack_require__(1242);
__webpack_require__(1243);
__webpack_require__(1244);
__webpack_require__(1245);
__webpack_require__(1246);
__webpack_require__(1247);
__webpack_require__(1248);
__webpack_require__(1249);
__webpack_require__(1250);
__webpack_require__(1251);
__webpack_require__(1252);
__webpack_require__(1253);
__webpack_require__(1254);
__webpack_require__(1255);
__webpack_require__(1256);
__webpack_require__(1257);
__webpack_require__(1258);
__webpack_require__(1259);
__webpack_require__(1260);
__webpack_require__(1261);
__webpack_require__(1262);
__webpack_require__(1263);
__webpack_require__(1264);
__webpack_require__(1265);
__webpack_require__(1266);
__webpack_require__(1267);
__webpack_require__(1268);
__webpack_require__(408);
__webpack_require__(1269);
__webpack_require__(1270);
__webpack_require__(1271);
__webpack_require__(1272);
__webpack_require__(1273);
__webpack_require__(1274);
__webpack_require__(1275);
__webpack_require__(1276);
__webpack_require__(1277);
__webpack_require__(1278);
__webpack_require__(1279);
__webpack_require__(1280);
__webpack_require__(1281);
__webpack_require__(1282);
__webpack_require__(1283);
__webpack_require__(1284);
__webpack_require__(1285);
__webpack_require__(1286);
__webpack_require__(1287);
__webpack_require__(1288);
__webpack_require__(1289);
__webpack_require__(1290);
__webpack_require__(1291);
__webpack_require__(1292);
__webpack_require__(1293);
__webpack_require__(1294);
__webpack_require__(1295);
__webpack_require__(1296);
__webpack_require__(1297);
__webpack_require__(1298);
__webpack_require__(1299);
__webpack_require__(1301);
__webpack_require__(527);
__webpack_require__(1302);
__webpack_require__(1303);
__webpack_require__(1304);
__webpack_require__(1305);
__webpack_require__(1306);
__webpack_require__(1307);
__webpack_require__(1308);
__webpack_require__(1309);
__webpack_require__(1310);
__webpack_require__(1311);
__webpack_require__(1312);
__webpack_require__(1313);
__webpack_require__(1314);
__webpack_require__(1315);
__webpack_require__(1316);
__webpack_require__(1317);
__webpack_require__(1318);
__webpack_require__(1319);
__webpack_require__(1320);
__webpack_require__(1321);
__webpack_require__(1322);
__webpack_require__(1323);
__webpack_require__(1324);
__webpack_require__(1325);
__webpack_require__(1326);
__webpack_require__(1327);
__webpack_require__(1328);
__webpack_require__(1329);
__webpack_require__(1330);
__webpack_require__(1331);
__webpack_require__(1332);
__webpack_require__(1333);
__webpack_require__(1334);
__webpack_require__(1335);
__webpack_require__(1336);
__webpack_require__(1337);
__webpack_require__(1338);
__webpack_require__(1339);
__webpack_require__(1340);
__webpack_require__(1341);
__webpack_require__(1342);
__webpack_require__(1343);
__webpack_require__(1344);
__webpack_require__(1345);
__webpack_require__(1346);
__webpack_require__(1347);
__webpack_require__(1348);
__webpack_require__(1349);
__webpack_require__(1350);
__webpack_require__(1351);
__webpack_require__(1352);
__webpack_require__(1353);
__webpack_require__(633);
__webpack_require__(1356);
__webpack_require__(1357);
__webpack_require__(1358);
__webpack_require__(1359);
__webpack_require__(1360);
__webpack_require__(1361);
__webpack_require__(1362);
__webpack_require__(1363);
__webpack_require__(1364);
__webpack_require__(1365);
__webpack_require__(1366);
__webpack_require__(1367);
__webpack_require__(1368);
__webpack_require__(1369);
__webpack_require__(1370);
__webpack_require__(1371);
__webpack_require__(1372);
__webpack_require__(1373);
__webpack_require__(1374);
__webpack_require__(1375);
__webpack_require__(1376);
__webpack_require__(1377);
__webpack_require__(1378);
__webpack_require__(1379);
__webpack_require__(1380);
__webpack_require__(1381);
__webpack_require__(1382);
__webpack_require__(1383);
__webpack_require__(1384);
__webpack_require__(1385);
__webpack_require__(1386);
__webpack_require__(1387);
__webpack_require__(528);
__webpack_require__(1388);
__webpack_require__(1389);
__webpack_require__(1390);
__webpack_require__(1391);
__webpack_require__(1392);
__webpack_require__(1393);
__webpack_require__(1394);
__webpack_require__(1395);
__webpack_require__(1396);
__webpack_require__(1397);
__webpack_require__(1398);
__webpack_require__(529);
__webpack_require__(1399);
__webpack_require__(1400);
__webpack_require__(1401);
__webpack_require__(1402);
__webpack_require__(1403);
__webpack_require__(2725);
__webpack_require__(1404);
__webpack_require__(1405);
__webpack_require__(1406);
__webpack_require__(1407);
__webpack_require__(1408);
__webpack_require__(1409);
__webpack_require__(1410);
__webpack_require__(1411);
__webpack_require__(1412);
__webpack_require__(2726);
__webpack_require__(1413);
__webpack_require__(1414);
__webpack_require__(1415);
__webpack_require__(1416);
__webpack_require__(1417);
__webpack_require__(1418);
__webpack_require__(1419);
__webpack_require__(1420);
__webpack_require__(1421);
__webpack_require__(1422);
__webpack_require__(1423);
__webpack_require__(1424);
__webpack_require__(1426);
__webpack_require__(1427);
__webpack_require__(1428);
__webpack_require__(1429);
__webpack_require__(1430);
__webpack_require__(1431);
__webpack_require__(1432);
__webpack_require__(1433);
__webpack_require__(1434);
__webpack_require__(1435);
__webpack_require__(1436);
__webpack_require__(634);
__webpack_require__(1437);
/* pkg: Tinebase FAT Client (css/Tinebase-FAT.css)*/
__webpack_require__(1438);
__webpack_require__(1440);
__webpack_require__(1499);
__webpack_require__(1512);
__webpack_require__(1514);
__webpack_require__(1516);
__webpack_require__(1518);
__webpack_require__(1523);
__webpack_require__(1525);
__webpack_require__(1527);
__webpack_require__(1529);
__webpack_require__(1532);
__webpack_require__(1534);
__webpack_require__(1536);
__webpack_require__(1538);
__webpack_require__(1540);
__webpack_require__(1542);
__webpack_require__(1544);
__webpack_require__(1548);
__webpack_require__(1568);
__webpack_require__(1570);
__webpack_require__(1572);
__webpack_require__(1574);
__webpack_require__(1576);
__webpack_require__(1578);
__webpack_require__(1580);
__webpack_require__(1582);
__webpack_require__(1584);
__webpack_require__(1586);
__webpack_require__(1588);
__webpack_require__(1593);
__webpack_require__(1597);
__webpack_require__(1600);
__webpack_require__(1610);
__webpack_require__(1612);
__webpack_require__(1615);
__webpack_require__(1617);
__webpack_require__(1622);
__webpack_require__(1624);


/***/ }),
/* 1112 */
/***/ (function(module, exports) {

/**
 * for some reasons the original fix insertes two <br>'s on enter for webkit. But this is one to much
 */
Ext.apply(Ext.form.HtmlEditor.prototype, {
  fixKeys: function () {
    // load time branching for fastest keydown performance
    if (Ext.isIE) {
      return function (e) {
        var k = e.getKey(),
            doc = this.getDoc(),
            r;

        if (k == e.TAB) {
          e.stopEvent();
          r = doc.selection.createRange();

          if (r) {
            r.collapse(true);
            r.pasteHTML('&nbsp;&nbsp;&nbsp;&nbsp;');
            this.deferFocus();
          }
        } else if (k == e.ENTER) {
          r = doc.selection.createRange();

          if (r) {
            var target = r.parentElement();

            if (!target || target.tagName.toLowerCase() != 'li') {
              e.stopEvent();
              r.pasteHTML('<br />');
              r.collapse(false);
              r.select();
            }
          }
        }
      };
    } else if (Ext.isOpera) {
      return function (e) {
        var k = e.getKey();

        if (k == e.TAB) {
          e.stopEvent();
          this.win.focus();
          this.execCmd('InsertHTML', '&nbsp;&nbsp;&nbsp;&nbsp;');
          this.deferFocus();
        }
      };
    } else if (Ext.isWebKit) {
      return function (e) {
        var k = e.getKey();

        if (k == e.TAB) {
          e.stopEvent();
          this.execCmd('InsertText', '\t');
          this.deferFocus();
        }
      };
    }
  }()
});
/**
 * fix textfield allowBlank validation
 * taken from ext, added trim
 */

Ext.override(Ext.form.TextField, {
  validateValue: function validateValue(value) {
    if (Ext.isFunction(this.validator)) {
      var msg = this.validator(value);

      if (msg !== true) {
        this.markInvalid(msg);
        return false;
      }
    }

    if (Ext.util.Format.trim(value).length < 1 || value === this.emptyText) {
      // if it's blank
      if (this.allowBlank) {
        this.clearInvalid();
        return true;
      } else {
        this.markInvalid(this.blankText);
        return false;
      }
    }

    if (Ext.util.Format.trim(value).length < this.minLength) {
      this.markInvalid(String.format(this.minLengthText, this.minLength));
      return false;
    }

    if (Ext.util.Format.trim(value).length > this.maxLength) {
      this.markInvalid(String.format(this.maxLengthText, this.maxLength));
      return false;
    }

    if (this.vtype) {
      var vt = Ext.form.VTypes;

      if (!vt[this.vtype](value, this)) {
        this.markInvalid(this.vtypeText || vt[this.vtype + 'Text']);
        return false;
      }
    }

    if (this.regex && !this.regex.test(value)) {
      this.markInvalid(this.regexText);
      return false;
    }

    return true;
  }
});
Ext.applyIf(Ext.tree.MultiSelectionModel.prototype, {
  /**
   * implement convinience function as expected from grid selection models
   * 
   * @namespace {Ext.tree}
   * @return {Node}
   */
  getSelectedNode: function getSelectedNode() {
    var selection = this.getSelectedNodes();
    return Ext.isArray(selection) ? selection[0] : null;
  }
});
/**
 * Expand offers a deep parameter to also expand all children as well as a callback function.
 * Before the callback was triggered after the first children were loaded now the callback is triggered when all children
 * are loaded of all nodes!
 */

Ext.override(Ext.tree.AsyncTreeNode, {
  expand: function expand(deep, anim, callback, scope) {
    if (this.loading) {
      // if an async load is already running, waiting til it's done
      var timer;

      var f = function () {
        if (!this.loading) {
          // done loading
          clearInterval(timer);
          this.expand(deep, anim, callback, scope);
        }
      }.createDelegate(this);

      timer = setInterval(f, 200);
      return;
    }

    if (!this.loaded) {
      if (this.fireEvent("beforeload", this) === false) {
        return;
      }

      this.loading = true;
      this.ui.beforeLoad(this);
      var loader = this.loader || this.attributes.loader || this.getOwnerTree().getLoader();

      if (loader) {
        loader.load(this, this.loadComplete.createDelegate(this, [deep, anim, callback, scope]), this);
        return;
      }
    }

    if (!this.expanded) {
      if (this.fireEvent('beforeexpand', this, deep, anim) === false) {
        return;
      }

      if (!this.childrenRendered) {
        this.renderChildren();
      }

      this.expanded = true;

      if (!this.isHiddenRoot() && this.getOwnerTree().animate && anim !== false || anim) {
        this.ui.animExpand(function () {
          this.fireEvent('expand', this);
          this.expandChildNodesCallback(deep, anim, callback, scope);
        }.createDelegate(this));
        return;
      } else {
        this.ui.expand();
        this.fireEvent('expand', this);
        this.runCallback(callback, scope || this, [this]);
      }
    } else {
      this.runCallback(callback, scope || this, [this]);
    }

    if (deep === true) {
      this.expandChildNodesCallback(deep, anim, callback, scope);
    }
  },
  expandChildNodesCallback: function expandChildNodesCallback(deep, anim, callback, scope) {
    var ticketFn = this.runCallback.deferByTickets(this, [callback, scope || this, [this]], false);
    var wrapTicket = ticketFn();

    if (deep === true) {
      var cs = this.childNodes;

      for (var i = 0, len = cs.length; i < len; i++) {
        cs[i].expand(deep, anim, ticketFn());
      }
    }

    wrapTicket();
  }
});
/**
 * Need this for ArrowEvents to navigate.
 */

Ext.KeyNav.prototype.forceKeyDown = Ext.isGecko;
/**
 * We need to overwrite to preserve original time information because 
 * Ext.form.TimeField does not support seconds
 * 
 * @param {} time
 * @private
 */

Ext.form.TimeField.prototype.setValue = function (time) {
  this.fullDateTime = time;
  Ext.form.TimeField.superclass.setValue.call(this, this.formatDate(this.parseDate(time)));
};
/**
 * @private
 */


Ext.form.TimeField.prototype.getValue = function () {
  var value = this.fullDateTime,
      dtValue = "";

  if (value) {
    var dtValue = this.parseDate(value);

    if (Ext.isDate(dtValue)) {
      dtValue = dtValue.clone();

      dtValue.toJSON = function () {
        return this.format('H:i:s');
      };
    }
  }

  return dtValue;
};
/**
 * check if sort field is in column list to avoid server exceptions
 */


Ext.grid.GridPanel.prototype.applyState = Ext.grid.GridPanel.prototype.applyState.createInterceptor(function (state) {
  var cm = this.colModel,
      s = state.sort;

  if (s && cm.getIndexById(s.field) < 0) {
    delete state.sort;
  }
});
/**
 * fix for table in cell
 */

Ext.grid.GridView.prototype.getCell = function (row, col) {
  return this.fly(this.getRow(row)).query('td.x-grid3-cell')[col];
};
/**
 * fix interpretation of ISO-8601  formatcode (Date.patterns.ISO8601Long) 
 * 
 * Browsers do not support timezones and also javascripts Date object has no 
 * support for it.  All Date Objects are in _one_ timezone which may ore may 
 * not be the operating systems timezone the browser runs on.
 * 
 * parsing dates in ISO format having the timeshift appended (Date.patterns.ISO8601Long) lead to 
 * correctly converted Date Objects in the browsers timezone. This timezone 
 * conversion changes the the Date Parts and as such, javascipt widget 
 * representing date time information print values of the browsers timezone 
 * and _not_ the values send by the server!
 * 
 * So in a multi timezone envireonment, datetime information in the browser 
 * _must not_ be parsed including the offset. Just the values of the server 
 * side converted datetime information are allowed to be parsed.
 */


Date.parseIso = function (isoString) {
  return Date.parseDate(isoString.replace(/\+\d{2}\d{2}/, ''), 'Y-m-d\\Th:i:s');
};
/**
 * rename window
 */


Ext.Window.prototype.rename = function (newId) {
  // Note PopupWindows are identified by name, whereas Ext.windows
  // get identified by id this should be solved some time ;-)
  var manager = this.manager || Ext.WindowMgr;
  manager.unregister(this);
  this.id = newId;
  manager.register(this);
};
/**
 * utility class used by Button
 * 
 * Fix: http://yui-ext.com/forum/showthread.php?p=142049
 * adds the ButtonToggleMgr.getSelected(toggleGroup, handler, scope) function
 */


Ext.ButtonToggleMgr = function () {
  var groups = {};

  function toggleGroup(btn, state) {
    if (state) {
      var g = groups[btn.toggleGroup];

      for (var i = 0, l = g.length; i < l; i++) {
        if (g[i] != btn) {
          g[i].toggle(false);
        }
      }
    }
  }

  return {
    register: function register(btn) {
      if (!btn.toggleGroup) {
        return;
      }

      var g = groups[btn.toggleGroup];

      if (!g) {
        g = groups[btn.toggleGroup] = [];
      }

      g.push(btn);
      btn.on("toggle", toggleGroup);
    },
    unregister: function unregister(btn) {
      if (!btn.toggleGroup) {
        return;
      }

      var g = groups[btn.toggleGroup];

      if (g) {
        g.remove(btn);
        btn.un("toggle", toggleGroup);
      }
    },
    getSelected: function getSelected(toggleGroup, handler, scope) {
      var g = groups[toggleGroup];

      for (var i = 0, l = g.length; i < l; i++) {
        if (g[i].pressed === true) {
          if (handler) {
            handler.call(scope || g[i], g[i]);
          }

          return g[i];
        }
      }

      return;
    }
  };
}();

Ext.override(Ext.Button, {
  setIconClass: function setIconClass(cls) {
    this.iconCls = cls;

    if (this.el) {
      var iconEl = this.btnEl.next('.x-btn-image') || this.btnEl;
      this.btnEl.dom.className = '';

      if (iconEl === this.btnEl) {
        this.btnEl.addClass(['x-btn-text', cls || '']);
      } else {
        this.btnEl.addClass(['x-btn-text']);
        iconEl.dom.className = '';
        iconEl.addClass(['x-btn-image', cls || '']);
      }

      this.setButtonClass();

      if (this.scale === 'medium') {
        var iconEl = Ext.fly(this.el.query('td.x-btn-mc div')[0]);

        if (cls === 'x-btn-wait') {
          iconEl.setLeft(this.el.getWidth() / 2 - iconEl.getWidth() / 2);
        } else {
          iconEl.dom.style.left = "";
        }
      }
    }

    return this;
  }
});
/**
 * add beforeloadrecords event
 */

Ext.data.Store.prototype.loadRecords = Ext.data.Store.prototype.loadRecords.createInterceptor(function (o, options, success) {
  var pass = this.fireEvent('beforeloadrecords', o, options, success, this);

  if (pass === false) {
    // fire load event so loading indicator stops
    this.fireEvent('load', this, this.data.items, options);
    return false;
  }
});
/**
 * state encoding converts null to empty object
 * 
 * -> take encoder/decoder from Ext 4.1 where this is fixed
 */

Ext.override(Ext.state.Provider, {
  /**
   * Decodes a string previously encoded with {@link #encodeValue}.
   * @param {String} value The value to decode
   * @return {Object} The decoded value
   */
  decodeValue: function decodeValue(value) {
    // a -> Array
    // n -> Number
    // d -> Date
    // b -> Boolean
    // s -> String
    // o -> Object
    // -> Empty (null)
    var me = this,
        re = /^(a|n|d|b|s|o|e)\:(.*)$/,
        matches = re.exec(unescape(value)),
        all,
        type,
        keyValue,
        values,
        vLen,
        v;

    if (!matches || !matches[1]) {
      return; // non state
    }

    type = matches[1];
    value = matches[2];

    switch (type) {
      case 'e':
        return null;

      case 'n':
        return parseFloat(value);

      case 'd':
        return new Date(Date.parse(value));

      case 'b':
        return value == '1';

      case 'a':
        all = [];

        if (value != '') {
          values = value.split('^');
          vLen = values.length;

          for (v = 0; v < vLen; v++) {
            value = values[v];
            all.push(me.decodeValue(value));
          }
        }

        return all;

      case 'o':
        all = {};

        if (value != '') {
          values = value.split('^');
          vLen = values.length;

          for (v = 0; v < vLen; v++) {
            value = values[v];
            keyValue = value.split('=');
            all[keyValue[0]] = me.decodeValue(keyValue[1]);
          }
        }

        return all;

      default:
        return value;
    }
  },

  /**
   * Encodes a value including type information.  Decode with {@link #decodeValue}.
   * @param {Object} value The value to encode
   * @return {String} The encoded value
   */
  encodeValue: function encodeValue(value) {
    var flat = '',
        i = 0,
        enc,
        len,
        key;

    if (value == null) {
      return 'e:1';
    } else if (typeof value == 'number') {
      enc = 'n:' + value;
    } else if (typeof value == 'boolean') {
      enc = 'b:' + (value ? '1' : '0');
    } else if (Ext.isDate(value)) {
      enc = 'd:' + value.toGMTString();
    } else if (Ext.isArray(value)) {
      for (len = value.length; i < len; i++) {
        flat += this.encodeValue(value[i]);

        if (i != len - 1) {
          flat += '^';
        }
      }

      enc = 'a:' + flat;
    } else if (typeof value == 'object') {
      for (key in value) {
        if (typeof value[key] != 'function' && value[key] !== undefined) {
          flat += key + '=' + this.encodeValue(value[key]) + '^';
        }
      }

      enc = 'o:' + flat.substring(0, flat.length - 1);
    } else {
      enc = 's:' + value;
    }

    return escape(enc);
  }
});
/**
 * fix focus related emptyText problems
 * 0008616: emptyText gets inserted into ComboBoxes when the Box gets Hidden while focused 
 */

Ext.form.TriggerField.prototype.cmpRegforFocusFix = [];
Ext.form.TriggerField.prototype.initComponent = Ext.form.TriggerField.prototype.initComponent.createSequence(function () {
  if (this.emptyText) {
    Ext.form.TriggerField.prototype.cmpRegforFocusFix.push(this);
  }
});
Ext.form.TriggerField.prototype.onDestroy = Ext.form.TriggerField.prototype.onDestroy.createInterceptor(function () {
  Ext.form.TriggerField.prototype.cmpRegforFocusFix.remove(this);
});
Ext.form.TriggerField.prototype.taskForFocusFix = new Ext.util.DelayedTask(function () {
  Ext.each(Ext.form.TriggerField.prototype.cmpRegforFocusFix, function (cmp) {
    if (cmp.rendered && cmp.el.dom == document.activeElement) {
      if (cmp.el.dom.value == cmp.emptyText) {
        cmp.preFocus();
        cmp.hasFocus = true;
        cmp.setRawValue('');
      }
    }
  });
  Ext.form.TriggerField.prototype.taskForFocusFix.delay(1000);
});
Ext.form.TriggerField.prototype.taskForFocusFix.delay(1000);
Ext.form.TriggerField.prototype.cmpRegForResize = [];
Ext.form.TriggerField.prototype.initComponent = Ext.form.TriggerField.prototype.initComponent.createSequence(function () {
  Ext.form.TriggerField.prototype.cmpRegForResize.push(this);
});
Ext.form.TriggerField.prototype.taskForResize = new Ext.util.DelayedTask(function () {
  Ext.each(Ext.form.TriggerField.prototype.cmpRegForResize, function (cmp) {
    if (!cmp.rendered || !this.list) {
      Ext.form.TriggerField.prototype.taskForResize.delay(300);
      return;
    }

    var visible = !!window.lodash.get(cmp, 'el.dom.offsetParent', false);

    if (visible && visible !== cmp.wasVisible && cmp.el.dom && !cmp.noFix) {
      var width = cmp.width || Ext.isFunction(cmp.getWidth) ? cmp.getWidth() : 150;
      cmp.setWidth(width);

      if (cmp.wrap && cmp.wrap.dom) {
        cmp.wrap.setWidth(width);
      }

      cmp.syncSize();
    }

    cmp.wasVisible = visible;
  });
  Ext.form.TriggerField.prototype.taskForResize.delay(300);
});
Ext.form.TriggerField.prototype.taskForResize.delay(300); // fixing layers in LayerCombo
// TODO maybe expand this to all Ext.Layers:
// Ext.Layer.prototype.showAction = Ext.Layer.prototype.showAction.createSequence(function() {
// Ext.Layer.prototype.hideAction = Ext.Layer.prototype.hideAction.createSequence(function() {

Ext.form.ComboBox.prototype.expand = Ext.form.ComboBox.prototype.expand.createSequence(function () {
  // fix z-index problem when used in editorGrids
  // manage z-index by windowMgr
  this.list.setActive = Ext.emptyFn;
  this.list.setZIndex = Ext.emptyFn;
  Ext.WindowMgr.register(this.list);
  Ext.WindowMgr.bringToFront(this.list);
});
Ext.form.ComboBox.prototype.collapse = Ext.form.ComboBox.prototype.collapse.createSequence(function () {
  if (this.list) {
    Ext.WindowMgr.unregister(this.list);
  }
});
/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * fix for nested css
 * @see https://forge.tine20.org/view.php?id=11884
 *
 * only cacheStyleSheet is affected, but we need to overwrite whole class (closure)
 */

Ext.util.CSS = function () {
  var rules = null;
  var doc = document;
  var camelRe = /(-[a-z])/gi;

  var camelFn = function camelFn(m, a) {
    return a.charAt(1).toUpperCase();
  };

  return {
    /**
     * Creates a stylesheet from a text blob of rules.
     * These rules will be wrapped in a STYLE tag and appended to the HEAD of the document.
     * @param {String} cssText The text containing the css rules
     * @param {String} id An id to add to the stylesheet for later removal
     * @return {StyleSheet}
     */
    createStyleSheet: function createStyleSheet(cssText, id) {
      var ss;
      var head = doc.getElementsByTagName("head")[0];
      var rules = doc.createElement("style");
      rules.setAttribute("type", "text/css");

      if (id) {
        rules.setAttribute("id", id);
      }

      if (Ext.isIE) {
        head.appendChild(rules);
        ss = rules.styleSheet;
        ss.cssText = cssText;
      } else {
        try {
          rules.appendChild(doc.createTextNode(cssText));
        } catch (e) {
          rules.cssText = cssText;
        }

        head.appendChild(rules);
        ss = rules.styleSheet ? rules.styleSheet : rules.sheet || doc.styleSheets[doc.styleSheets.length - 1];
      }

      this.cacheStyleSheet(ss);
      return ss;
    },

    /**
     * Removes a style or link tag by id
     * @param {String} id The id of the tag
     */
    removeStyleSheet: function removeStyleSheet(id) {
      var existing = doc.getElementById(id);

      if (existing) {
        existing.parentNode.removeChild(existing);
      }
    },

    /**
     * Dynamically swaps an existing stylesheet reference for a new one
     * @param {String} id The id of an existing link tag to remove
     * @param {String} url The href of the new stylesheet to include
     */
    swapStyleSheet: function swapStyleSheet(id, url) {
      this.removeStyleSheet(id);
      var ss = doc.createElement("link");
      ss.setAttribute("rel", "stylesheet");
      ss.setAttribute("type", "text/css");
      ss.setAttribute("id", id);
      ss.setAttribute("href", url);
      doc.getElementsByTagName("head")[0].appendChild(ss);
    },

    /**
     * Refresh the rule cache if you have dynamically added stylesheets
     * @return {Object} An object (hash) of rules indexed by selector
     */
    refreshCache: function refreshCache() {
      return this.getRules(true);
    },
    // private
    cacheStyleSheet: function cacheStyleSheet(ss) {
      if (!rules) {
        rules = {};
      }

      try {
        // try catch for cross domain access issue
        var ssRules = ss.cssRules || ss.rules,
            sel,
            selParts;

        for (var j = ssRules.length - 1; j >= 0; --j) {
          // nested rules
          if (ssRules[j].styleSheet) {
            Ext.util.CSS.cacheStyleSheet(ssRules[j].styleSheet);
          } else if (ssRules[j].selectorText) {
            sel = ssRules[j].selectorText.toLowerCase();
            rules[sel] = ssRules[j];
            selParts = sel.split(', ');

            if (selParts.length > 1) {
              for (var p = selParts.length - 1; p >= 0; --p) {
                rules[selParts[p]] = ssRules[j];
              }
            }
          }
        }
      } catch (e) {}
    },

    /**
     * Gets all css rules for the document
     * @param {Boolean} refreshCache true to refresh the internal cache
     * @return {Object} An object (hash) of rules indexed by selector
     */
    getRules: function getRules(refreshCache) {
      if (rules === null || refreshCache) {
        rules = {};
        var ds = doc.styleSheets;

        for (var i = 0, len = ds.length; i < len; i++) {
          try {
            this.cacheStyleSheet(ds[i]);
          } catch (e) {}
        }
      }

      return rules;
    },

    /**
     * Gets an an individual CSS rule by selector(s)
     * @param {String/Array} selector The CSS selector or an array of selectors to try. The first selector that is found is returned.
     * @param {Boolean} refreshCache true to refresh the internal cache if you have recently updated any rules or added styles dynamically
     * @return {CSSRule} The CSS rule or null if one is not found
     */
    getRule: function getRule(selector, refreshCache) {
      var rs = this.getRules(refreshCache);

      if (!Ext.isArray(selector)) {
        return rs[selector.toLowerCase()];
      }

      for (var i = 0; i < selector.length; i++) {
        if (rs[selector[i]]) {
          return rs[selector[i].toLowerCase()];
        }
      }

      return null;
    },

    /**
     * Updates a rule property
     * @param {String/Array} selector If it's an array it tries each selector until it finds one. Stops immediately once one is found.
     * @param {String} property The css property
     * @param {String} value The new value for the property
     * @return {Boolean} true If a rule was found and updated
     */
    updateRule: function updateRule(selector, property, value) {
      if (!Ext.isArray(selector)) {
        var rule = this.getRule(selector);

        if (rule) {
          rule.style[property.replace(camelRe, camelFn)] = value;
          return true;
        }
      } else {
        for (var i = 0; i < selector.length; i++) {
          if (this.updateRule(selector[i], property, value)) {
            return true;
          }
        }
      }

      return false;
    }
  };
}(); // don't apply plugins to the menu, apply them only to the datepicker


Ext.override(Ext.menu.DateMenu, {
  initComponent: function initComponent() {
    this.on('beforeshow', this.onBeforeShow, this);

    if (this.strict = Ext.isIE7 && Ext.isStrict) {
      this.on('show', this.onShow, this, {
        single: true,
        delay: 20
      });
    }

    Ext.apply(this, {
      plain: true,
      showSeparator: false,
      items: this.picker = new Ext.DatePicker(Ext.applyIf({
        internalRender: this.strict || !Ext.isIE,
        ctCls: 'x-menu-date-item',
        id: this.pickerId
      }, this.initialConfig))
    }); // remove plugins from menu itself

    this.plugins = [];
    this.picker.purgeListeners();
    Ext.menu.DateMenu.superclass.initComponent.call(this);
    /**
     * @event select
     * Fires when a date is selected from the {@link #picker Ext.DatePicker}
     * @param {DatePicker} picker The {@link #picker Ext.DatePicker}
     * @param {Date} date The selected date
     */

    this.relayEvents(this.picker, ['select']);
    this.on('show', this.picker.focus, this.picker);
    this.on('select', this.menuHide, this);

    if (this.handler) {
      this.on('select', this.handler, this.scope || this);
    }
  }
});
Ext.override(Ext.tree.TreePanel, {
  /**
   * Gets a node in this tree by its id
   * @param {String} id
   * @return {Node}
   */
  getNodeById: function getNodeById(id) {
    try {
      return this.nodeHash[id];
    } catch (e) {
      return null;
    }
  },

  /**
   * Gets a node in this tree by its path
   * @param {String} path
   * @return {Node}
   */
  getNodeByPath: function getNodeByPath(path) {
    try {
      const node = _.filter(this.nodeHash, node => {
        var _node$attributes;

        return (node === null || node === void 0 ? void 0 : (_node$attributes = node.attributes) === null || _node$attributes === void 0 ? void 0 : _node$attributes.path) === path;
      });

      return node[0];
    } catch (e) {
      return null;
    }
  }
});
Ext.override(Ext.menu.Menu, {
  setActive: Ext.emptyFn,
  setZIndex: Ext.emptyFn,
  showAt: Ext.menu.Menu.prototype.showAt.createSequence(function () {
    Ext.WindowMgr.register(this);
    Ext.WindowMgr.bringToFront(this);
  }),
  hide: Ext.menu.Menu.prototype.hide.createSequence(function () {
    Ext.WindowMgr.unregister(this);
  })
});
/**
 * FIXME: we already overwrite the email regex above!! which one is better?
 */

Ext.apply(Ext.form.VTypes, {
  //@see https://stackoverflow.com/questions/46155/how-to-validate-an-email-address-in-javascript
  emailRe: /^(([^<>()\[\]\.,;:\s@\"]+(\.[^<>()\[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i,
  email: function email(v) {
    return this.emailRe.test(String(v).toLowerCase());
  }
});
Ext.override(Ext.grid.GridDragZone, {
  getDragData: function getDragData(e) {
    var t = Ext.lib.Event.getTarget(e);
    var rowIndex = this.view.findRowIndex(t);

    if (rowIndex !== false) {
      var sm = this.grid.selModel; // fix: make DD & checkbox selection working together

      if ((!sm.isSelected(rowIndex) || e.hasModifier()) && !e.getTarget('.x-grid3-row-checker')) {
        sm.handleMouseDown(this.grid, rowIndex, e);
      }

      return {
        grid: this.grid,
        ddel: this.ddel,
        rowIndex: rowIndex,
        selections: sm.getSelections()
      };
    }

    return false;
  }
});
Ext.override(Ext.Component, {
  /**
   * is this component rendered?
   * @return {Promise}
   */
  afterIsRendered: function afterIsRendered() {
    var me = this;

    if (this.rendered) {
      return Promise.resolve(me);
    }

    return new Promise(function (resolve) {
      me.on('render', resolve);
    });
  }
});
Ext.override(Ext.form.CheckboxGroup, {
  /**
   * is this component rendered?
   * @return {Promise}
   */
  getValue: function getValue() {
    var _ = window.lodash,
        out = [];

    if (_.isArray(this.items)) {
      // not yet rendered
      _.each(this.items, function (item) {
        if (item.checked) {
          out.push(item);
        }
      });
    } else {
      this.eachItem(function (item) {
        if (item.checked) {
          out.push(item);
        }
      });
    }

    return out;
  },
  onBeforeEdit: function onBeforeEdit(o) {
    if (this.readOnly) {
      o.cancel = true;
    }
  },
  setReadOnly: function setReadOnly(readOnly) {
    this.readOnly = readOnly;
  }
});
Ext.layout.VBoxLayout.prototype.onLayout = Ext.layout.VBoxLayout.prototype.onLayout.createSequence(function () {
  if (!this.vboxfix) {
    this.container.on('resize', function (c) {
      var w = c.getWidth();
      c.items.each(function (i) {
        i.setWidth(w);
      });
    }, this);
    this.vboxfix = true;
  }
});
Ext.override(Ext.layout.ToolbarLayout, {
  createMenuConfig: function createMenuConfig(c, hideOnClick) {
    var cfg = Ext.apply({}, c.initialConfig),
        group = c.toggleGroup;
    Ext.apply(cfg, {
      text: c.overflowText || c.text,
      iconCls: c.iconCls,
      icon: c.icon,
      itemId: c.itemId,
      disabled: c.disabled,
      handler: c.handler,
      scope: c.scope,
      menu: c.menu,
      hideOnClick: hideOnClick
    });

    if (group || c.enableToggle) {
      Ext.apply(cfg, {
        iconCls: null,
        icon: null,
        toggle: function toggle(pressed) {
          this.setChecked(pressed);
        },
        group: group,
        checked: c.pressed,
        listeners: {
          checkchange: function checkchange(item, checked) {
            c.toggle(checked);
          }
        }
      });
    }

    delete cfg.ownerCt;
    delete cfg.xtype;
    delete cfg.id;
    return cfg;
  }
});
Ext.override(Ext.LoadMask, {
  onBeforeLoad: function onBeforeLoad() {
    if (!this.disabled) {
      this.el.mask(this.msg, this.msgCls);
      Ext.fly(this.el.query('.ext-el-mask-msg')[0]).appendChild(Ext.DomHelper.createDom({
        tag: 'div',
        cls: 'x-mask-wait'
      }));
    }
  },
  onLoad: function onLoad() {
    this.el.unmask(this.removeMask);
  }
});
/**
 * autocomplete for forms
 */

Ext.FormPanel.prototype.initComponent = Ext.FormPanel.prototype.initComponent.createSequence(function () {
  if (this.autocomplete === false) {
    this.bodyCfg.autocomplete = 'false';
  }
});
/**
 * autocomplete fix for password fields
 * @see {https://stackoverflow.com/a/28457066}
 */

Ext.form.Field.prototype.origGetAutoCreate = Ext.Component.prototype.getAutoCreate;

Ext.form.Field.prototype.getAutoCreate = function () {
  var cfg = this.origGetAutoCreate();

  if (this.inputType == 'password' && this.hasOwnProperty('autocomplete')) {
    cfg.autocomplete = this.autocomplete;
  }

  return cfg;
};

Ext.override(Ext.EventObject, {
  getSignature: function getSignature() {
    return String(this.browserEvent.timeStamp) + '-' + this.getXY();
  }
});
/**
 * preserve dateformat
 */

Ext.data.Field = Ext.apply(Ext.data.Field.createSequence(function (config) {
  if (config && config.type == 'date' && config.dateFormat) {
    var convert = this.convert;

    this.convert = function (v) {
      var d = convert(v);

      if (Ext.isDate(d)) {
        d.toJSON = function () {
          return this.format(config.dateFormat);
        };
      }

      return d;
    };
  }
}), {
  prototype: Ext.data.Field.prototype
});

/***/ }),
/* 1113 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/**
 * auto add selection checkbox for touch devices
 */
if (Ext.isTouchDevice) {
  Ext.grid.GridPanel.prototype.initComponent = Ext.grid.GridPanel.prototype.initComponent.createSequence(function () {
    var cm = this.getColumnModel(),
        sm = this.getSelectionModel(),
        cols = cm.columns || cm.config || [],
        hasCheckboxSelModel = false;

    if (!(sm instanceof Ext.grid.RowSelectionModel)) {
      return;
    }

    Ext.each(cols, function (col) {
      hasCheckboxSelModel = hasCheckboxSelModel || col.dataIndex == 'checked' || col.id == 'checked';
    });

    if (!hasCheckboxSelModel && !this.skipAutoCheckboxSelection) {
      cols.unshift(sm);
    }
  });
  Ext.grid.RowSelectionModel.prototype.initEvents = Ext.grid.RowSelectionModel.prototype.initEvents.createSequence(function () {
    this.grid.on('render', function () {
      var view = this.grid.getView();
      view.mainBody.on('mousedown', this.onMouseDown, this);
      Ext.fly(view.innerHd).on('mousedown', this.onHdMouseDown, this);
    }, this);
  });
  Ext.each(['onMouseDown', 'onHdMouseDown', 'renderer', 'header', 'width', 'sortable', 'menuDisabled', 'fixed', 'dataIndex', 'id'], function (p) {
    Ext.grid.RowSelectionModel.prototype[p] = Ext.grid.CheckboxSelectionModel.prototype[p];
  });
}

/***/ }),
/* 1114 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.2.1
 * Copyright(c) 2006-2010 Ext JS, Inc.
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ux.Portal = Ext.extend(Ext.Panel, {
  layout: 'column',
  autoScroll: true,
  cls: 'x-portal',
  defaultType: 'portalcolumn',
  initComponent: function initComponent() {
    Ext.ux.Portal.superclass.initComponent.call(this);
    this.addEvents({
      validatedrop: true,
      beforedragover: true,
      dragover: true,
      beforedrop: true,
      drop: true
    });
  },
  initEvents: function initEvents() {
    Ext.ux.Portal.superclass.initEvents.call(this);
    this.dd = new Ext.ux.Portal.DropZone(this, this.dropConfig);
  },
  beforeDestroy: function beforeDestroy() {
    if (this.dd) {
      this.dd.unreg();
    }

    Ext.ux.Portal.superclass.beforeDestroy.call(this);
  }
});
Ext.reg('portal', Ext.ux.Portal);
Ext.ux.Portal.DropZone = Ext.extend(Ext.dd.DropTarget, {
  constructor: function constructor(portal, cfg) {
    this.portal = portal;
    Ext.dd.ScrollManager.register(portal.body);
    Ext.ux.Portal.DropZone.superclass.constructor.call(this, portal.bwrap.dom, cfg);
    portal.body.ddScrollConfig = this.ddScrollConfig;
  },
  ddScrollConfig: {
    vthresh: 50,
    hthresh: -1,
    animate: true,
    increment: 200
  },
  createEvent: function createEvent(dd, e, data, col, c, pos) {
    return {
      portal: this.portal,
      panel: data.panel,
      columnIndex: col,
      column: c,
      position: pos,
      data: data,
      source: dd,
      rawEvent: e,
      status: this.dropAllowed
    };
  },
  notifyOver: function notifyOver(dd, e, data) {
    var xy = e.getXY(),
        portal = this.portal,
        px = dd.proxy; // case column widths

    if (!this.grid) {
      this.grid = this.getGrid();
    } // handle case scroll where scrollbars appear during drag


    var cw = portal.body.dom.clientWidth;

    if (!this.lastCW) {
      this.lastCW = cw;
    } else if (this.lastCW != cw) {
      this.lastCW = cw;
      portal.doLayout();
      this.grid = this.getGrid();
    } // determine column


    var col = 0,
        xs = this.grid.columnX,
        cmatch = false;

    for (var len = xs.length; col < len; col++) {
      if (xy[0] < xs[col].x + xs[col].w) {
        cmatch = true;
        break;
      }
    } // no match, fix last index


    if (!cmatch) {
      col--;
    } // find insert position


    var p,
        match = false,
        pos = 0,
        c = portal.items.itemAt(col),
        items = c.items.items,
        overSelf = false;

    for (var len = items.length; pos < len; pos++) {
      p = items[pos];
      var h = p.el.getHeight();

      if (h === 0) {
        overSelf = true;
      } else if (p.el.getY() + h / 2 > xy[1]) {
        match = true;
        break;
      }
    }

    pos = (match && p ? pos : c.items.getCount()) + (overSelf ? -1 : 0);
    var overEvent = this.createEvent(dd, e, data, col, c, pos);

    if (portal.fireEvent('validatedrop', overEvent) !== false && portal.fireEvent('beforedragover', overEvent) !== false) {
      // make sure proxy width is fluid
      px.getProxy().setWidth('auto');

      if (p) {
        px.moveProxy(p.el.dom.parentNode, match ? p.el.dom : null);
      } else {
        px.moveProxy(c.el.dom, null);
      }

      this.lastPos = {
        c: c,
        col: col,
        p: overSelf || match && p ? pos : false
      };
      this.scrollPos = portal.body.getScroll();
      portal.fireEvent('dragover', overEvent);
      return overEvent.status;
    } else {
      return overEvent.status;
    }
  },
  notifyOut: function notifyOut() {
    delete this.grid;
  },
  notifyDrop: function notifyDrop(dd, e, data) {
    delete this.grid;

    if (!this.lastPos) {
      return;
    }

    var c = this.lastPos.c,
        col = this.lastPos.col,
        pos = this.lastPos.p,
        panel = dd.panel,
        dropEvent = this.createEvent(dd, e, data, col, c, pos !== false ? pos : c.items.getCount());

    if (this.portal.fireEvent('validatedrop', dropEvent) !== false && this.portal.fireEvent('beforedrop', dropEvent) !== false) {
      dd.proxy.getProxy().remove();
      panel.el.dom.parentNode.removeChild(dd.panel.el.dom);

      if (pos !== false) {
        c.insert(pos, panel);
      } else {
        c.add(panel);
      }

      c.doLayout();
      this.portal.fireEvent('drop', dropEvent); // scroll position is lost on drop, fix it

      var st = this.scrollPos.top;

      if (st) {
        var d = this.portal.body.dom;
        setTimeout(function () {
          d.scrollTop = st;
        }, 10);
      }
    }

    delete this.lastPos;
  },
  // internal cache of body and column coords
  getGrid: function getGrid() {
    var box = this.portal.bwrap.getBox();
    box.columnX = [];
    this.portal.items.each(function (c) {
      box.columnX.push({
        x: c.el.getX(),
        w: c.el.getWidth()
      });
    });
    return box;
  },
  // unregister the dropzone from ScrollManager
  unreg: function unreg() {
    Ext.dd.ScrollManager.unregister(this.portal.body);
    Ext.ux.Portal.DropZone.superclass.unreg.call(this);
  }
});

/***/ }),
/* 1115 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.2.1
 * Copyright(c) 2006-2010 Ext JS, Inc.
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ux.PortalColumn = Ext.extend(Ext.Container, {
  layout: 'anchor',
  //autoEl : 'div',//already defined by Ext.Component
  defaultType: 'portlet',
  cls: 'x-portal-column'
});
Ext.reg('portalcolumn', Ext.ux.PortalColumn);

/***/ }),
/* 1116 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.2.1
 * Copyright(c) 2006-2010 Ext JS, Inc.
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ux.Portlet = Ext.extend(Ext.Panel, {
  anchor: '100%',
  frame: true,
  collapsible: true,
  draggable: true,
  cls: 'x-portlet'
});
Ext.reg('portlet', Ext.ux.Portlet);

/***/ }),
/* 1117 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/**
 * NOTE: init.js is included before the tine2.0 code!
 */

/** --------------------- Ultra Generic JavaScript Stuff --------------------- **/

/**
 * create console pseudo object when firebug is disabled/not installed
 */
if (!window.console) window.console = {};

(function () {
  for (var fn in {
    // maximum possible console functions based on firebug
    log: null,
    debug: null,
    info: null,
    warn: null,
    error: null,
    assert: null,
    dir: null,
    dirxml: null,
    group: null,
    groupEnd: null,
    time: null,
    timeEnd: null,
    count: null,
    trace: null,
    profile: null,
    profileEnd: null
  }) {
    window.console[fn] = window.console[fn] || function () {};
  }
})();
/** -------------------- Extjs Framework Initialisation -------------------- **/

/**
 * don't fill the ext stats
 */


Ext.BLANK_IMAGE_URL = "library/ExtJS/resources/images/default/s.gif";
/**
 * use empty image as secure url
 */

Ext.SSL_SECURE_URL = "library/ExtJS/resources/images/default/s.gif";
/**
 * use native json implementation because we had problems with utf8 linebreaks (\u2028 for example)
 * @see 0003356: Special characters in telephone numbers makes addressbook stop responding
 * @type Boolean
 */

Ext.USE_NATIVE_JSON = true;
/**
 * init ext quick tips
 */

Ext.QuickTips.init();
/**
 * hide the field label when the field is hidden
 */

Ext.layout.FormLayout.prototype.trackLabels = true;
/**
 * html encode all grid columns per default and convert spaces to &nbsp;
 */

Ext.grid.ColumnModel.defaultRenderer = Ext.util.Format.htmlEncode;

Ext.grid.Column.prototype.renderer = function (value) {
  var result = Ext.util.Format.htmlEncode(value);
  return result;
};

Ext.apply(Ext.data.JsonStore.prototype, {
  url: 'index.php',
  root: 'results',
  idProperty: 'id',
  totalProperty: 'totalcount'
});
/**
 * additional date patterns
 * @see{Date}
 */

Date.patterns = {
  ISO8601Long: "Y-m-d H:i:s",
  ISO8601Short: "Y-m-d",
  ISO8601Time: "H:i:s",
  ShortDate: "n/j/Y",
  LongDate: "l, F d, Y",
  FullDateTime: "l, F d, Y g:i:s A",
  MonthDay: "F d",
  ShortTime: "g:i A",
  LongTime: "g:i:s A",
  SortableDateTime: "Y-m-d\\TH:i:s",
  UniversalSortableDateTime: "Y-m-d H:i:sO",
  YearMonth: "F, Y"
};

Ext.util.JSON.encodeDate = function (o) {
  var pad = function pad(n) {
    return n < 10 ? "0" + n : n;
  };

  return '"' + o.getFullYear() + "-" + pad(o.getMonth() + 1) + "-" + pad(o.getDate()) + " " + pad(o.getHours()) + ":" + pad(o.getMinutes()) + ":" + pad(o.getSeconds()) + '"';
};

Date.prototype.toJSON = function (key) {
  var pad = function pad(n) {
    return n < 10 ? "0" + n : n;
  };

  return this.getFullYear() + "-" + pad(this.getMonth() + 1) + "-" + pad(this.getDate()) + " " + pad(this.getHours()) + ":" + pad(this.getMinutes()) + ":" + pad(this.getSeconds());
};
/**
 * additional formats
 */


Ext.util.Format = Ext.apply(Ext.util.Format, {
  money: function money(v, metadata) {
    var _ = window.lodash,
        currencySymbol = Tine.Tinebase.registry.get('currencySymbol');

    if (!_.isNumber(v)) {
      v = Number(v);
    }

    var locale = Tine.Tinebase.registry.get('locale').locale;

    if (locale.includes('_')) {
      locale = locale.split('_')[0];
    }

    if (metadata && metadata.zeroMoney && v == '0') {
      return '';
    }

    return v.toLocaleString(locale, {
      minimumFractionDigits: 2
    }) + " " + currencySymbol;
  },
  percentage: function percentage(v) {
    if (v === null) {
      return 'none';
    }

    if (!isNaN(v)) {
      return v + " %";
    }
  },
  pad: function pad(v, l, s) {
    if (!s) {
      s = '&nbsp;';
    }

    var plen = l - v.length;

    for (var i = 0; i < plen; i++) {
      v += s;
    }

    return v;
  }
});
/**
 * html encoding for user generated content
 *
 * @param {String} value
 * @returns {String}
 */

Ext.XTemplate.prototype.encode = function (value) {
  return value ? Ext.util.Format.htmlEncode(value) : '';
};
/**
 * html encoding for user generated content when internally decoded (e.g. tooltips)
 *
 * @param {String} value
 * @returns {String}
 */


Ext.XTemplate.prototype.doubleEncode = function (value) {
  return value ? Tine.Tinebase.common.doubleEncode(value) : '';
};
/**
 * allow separate icons for small buttons - needed e.g. for animations
 * @type {Ext.Template}
 */


Ext.Button.buttonTemplate = new Ext.Template('<table id="{4}" cellspacing="0" class="x-btn {3}"><tbody class="{1}">', '<tr><td class="x-btn-tl"><i>&#160;</i></td><td class="x-btn-tc"></td><td class="x-btn-tr"><i>&#160;</i></td></tr>', '<tr><td class="x-btn-ml"><i>&#160;</i></td><td class="x-btn-mc"><em class="{2}" unselectable="on"><button type="{0}"></button><div class="x-btn-image"></div></em></td><td class="x-btn-mr"><i>&#160;</i></td></tr>', '<tr><td class="x-btn-bl"><i>&#160;</i></td><td class="x-btn-bc"></td><td class="x-btn-br"><i>&#160;</i></td></tr>', '</tbody></table>');
Ext.Button.buttonTemplate.compile();
Ext.Window.prototype.shadow = false;
Ext.Tip.prototype.shadow = false;
Ext.QuickTip.prototype.shadow = false;

/***/ }),
/* 1118 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * compatibility plugin for store to replace Ext.util.MixedCollection in registry & preferences
 */
;

(function (store, _) {
  var _set = _.set,
      _remove = _.remove,
      _clear = _.clear,
      _get = _.get,
      _on = _.storeAPI.on,
      _isPrefExp = /\.preferences$/;

  _.stringify = function (d) {
    return d === undefined || typeof d === "function" ? d + '' : Ext.encode(d);
  };

  _.parse = function (s) {
    // if it doesn't parse, return as is
    try {
      return Ext.decode(s);
    } catch (e) {
      return s;
    }
  };

  _.containsKey = function (key) {
    if (key && key.match(_isPrefExp)) {
      var parts = key.split('.');
      return !!Tine[parts[parts.length - 3]]['preferences'];
    }

    return this.has(key);
  };

  _.get = function (area, key) {
    if (key && key.match(_isPrefExp)) {
      var parts = key.split('.');
      return Tine[parts[parts.length - 3]]['preferences'];
    }

    return _get.apply(this, arguments);
  };
  /**
   * NOTE as localStorage don't sends events for own window, we need to
   * intercept store write options
   */


  _.set = function (area, key, string) {
    var oldValue = this.get(area, key),
        ret = _set.apply(this, arguments);

    this.fireEvent(key, oldValue, string);
    return ret;
  };

  _.remove = function (area, key) {
    var oldValue = this.get(area, key),
        ret = _remove.apply(this, arguments);

    this.fireEvent(key, oldValue, undefined);
    return ret;
  };

  _.clear = function (area) {// we come here without on clear without namespace only
    // hence no need to implement now
  };
  /**
   * fire a simulated storage event
   */


  _.fireEvent = function (key, oldValue, newValue) {
    if (Ext.isIE8 || Ext.isIE9) {
      // IEs fire same window events on their own
      return;
    }

    var event;

    if (document.createEvent) {
      event = document.createEvent('StorageEvent');
      event.initStorageEvent('storage', true, true, key, oldValue, newValue, window.location.href, window.localStorage);
      return dispatchEvent(event);
    } else {
      // IE < 9?
      event = document.createEventObject();
      event.eventType = "storage"; //event.eventName = "storage";

      event.key = key;
      event.newValue = newValue;
      event.oldValue = oldValue;
      return document.fireEvent("onstorage", event);
    }
  };
  /**
   * NOTE: in Ext.util.MixedCollection you can't register for specific keys
   *       so we add this capability as a fours parameter
   * NOTE: we only support the replace event yet and do no mapping computations
   */


  _.fn('on', function (event, fn, scope, key) {
    // Ext.util.MixedCollection
    if (['clear', 'add', 'replace', 'remove', 'sort'].indexOf(event) >= 0) {
      if (event != 'replace') {
        throw new Ext.Error('event ' + event + ' not implemented in store.compat');
      }

      return _on.call(this, key, function (e) {
        if (!key || key == e.key) {
          if (e.oldValue != e.newValue) {
            return fn.call(scope || window, e.key, e.oldValue, e.newValue);
          }
        }
      });
    } // fallback


    return _on.call(this, event, fn);
  });

  _.fn('add', _.storeAPI.set);

  _.fn('replace', _.storeAPI.set);

  _.fn('containsKey', _.containsKey);
})(window.store, window.store._);

/***/ }),
/* 1119 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(230)(__webpack_require__(1120));

/***/ }),
/* 1120 */
/***/ (function(module, exports) {

module.exports = "// Copyright (c) 2013 Andris Reinman\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n\n(function(root, factory) {\n    \"use strict\";\n\n    if (typeof define === 'function' && define.amd) {\n        define(factory);\n    } else if (typeof exports === 'object') {\n        module.exports = factory();\n    } else {\n        root.addressparser = factory();\n    }\n}(this, function() {\n    \"use strict\";\n\n    /**\n     * Defines an object as a namespace for the parsing function\n     */\n    var addressparser = {};\n\n    /**\n     * Parses structured e-mail addresses from an address field\n     *\n     * Example:\n     *\n     *    \"Name <address@domain>\"\n     *\n     * will be converted to\n     *\n     *     [{name: \"Name\", address: \"address@domain\"}]\n     *\n     * @param {String} str Address field\n     * @return {Array} An array of address objects\n     */\n    addressparser.parse = function(str) {\n        var tokenizer = new addressparser.Tokenizer(str),\n            tokens = tokenizer.tokenize();\n\n        var addresses = [],\n            address = [],\n            parsedAddresses = [];\n\n        tokens.forEach(function(token) {\n            if (token.type === \"operator\" && (token.value === \",\" || token.value === \";\")) {\n                if (address.length) {\n                    addresses.push(address);\n                }\n                address = [];\n            } else {\n                address.push(token);\n            }\n        });\n\n        if (address.length) {\n            addresses.push(address);\n        }\n\n        addresses.forEach(function(address) {\n            address = addressparser._handleAddress(address);\n            if (address.length) {\n                parsedAddresses = parsedAddresses.concat(address);\n            }\n        });\n\n        return parsedAddresses;\n    };\n\n    /**\n     * Converts tokens for a single address into an address object\n     *\n     * @param {Array} tokens Tokens object\n     * @return {Object} Address object\n     */\n    addressparser._handleAddress = function(tokens) {\n        var token,\n            isGroup = false,\n            state = \"text\",\n            address,\n            addresses = [],\n            data = {\n                address: [],\n                comment: [],\n                group: [],\n                text: []\n            },\n            i, len;\n\n        // Filter out <addresses>, (comments) and regular text\n        for (i = 0, len = tokens.length; i < len; i++) {\n            token = tokens[i];\n\n            if (token.type === \"operator\") {\n                switch (token.value) {\n                    case \"<\":\n                        state = \"address\";\n                        break;\n                    case \"(\":\n                        state = \"comment\";\n                        break;\n                    case \":\":\n                        state = \"group\";\n                        isGroup = true;\n                        break;\n                    default:\n                        state = \"text\";\n                }\n            } else {\n                if (token.value) {\n                    data[state].push(token.value);\n                }\n            }\n        }\n\n        // If there is no text but a comment, replace the two\n        if (!data.text.length && data.comment.length) {\n            data.text = data.comment;\n            data.comment = [];\n        }\n\n        if (isGroup) {\n            // http://tools.ietf.org/html/rfc2822#appendix-A.1.3\n            data.text = data.text.join(\" \");\n            addresses.push({\n                name: data.text || (address && address.name),\n                group: data.group.length ? addressparser.parse(data.group.join(\",\")) : []\n            });\n        } else {\n            // If no address was found, try to detect one from regular text\n            if (!data.address.length && data.text.length) {\n                for (i = data.text.length - 1; i >= 0; i--) {\n                    if (data.text[i].match(/^[^@\\s]+@[^@\\s]+$/)) {\n                        data.address = data.text.splice(i, 1);\n                        break;\n                    }\n                }\n\n                var _regexHandler = function(address) {\n                    if (!data.address.length) {\n                        data.address = [address.trim()];\n                        return \" \";\n                    } else {\n                        return address;\n                    }\n                };\n\n                // still no address\n                if (!data.address.length) {\n                    for (i = data.text.length - 1; i >= 0; i--) {\n                        data.text[i] = data.text[i].replace(/\\s*\\b[^@\\s]+@[^@\\s]+\\b\\s*/, _regexHandler).trim();\n                        if (data.address.length) {\n                            break;\n                        }\n                    }\n                }\n            }\n\n            // If there's still is no text but a comment exixts, replace the two\n            if (!data.text.length && data.comment.length) {\n                data.text = data.comment;\n                data.comment = [];\n            }\n\n            // Keep only the first address occurence, push others to regular text\n            if (data.address.length > 1) {\n                data.text = data.text.concat(data.address.splice(1));\n            }\n\n            // Join values with spaces\n            data.text = data.text.join(\" \");\n            data.address = data.address.join(\" \");\n\n            if (!data.address && isGroup) {\n                return [];\n            } else {\n                address = {\n                    address: data.address || data.text || \"\",\n                    name: data.text || data.address || \"\"\n                };\n\n                if (address.address === address.name) {\n                    if ((address.address || \"\").match(/@/)) {\n                        address.name = \"\";\n                    } else {\n                        address.address = \"\";\n                    }\n\n                }\n\n                addresses.push(address);\n            }\n        }\n\n        return addresses;\n    };\n\n    /**\n     * Creates a Tokenizer object for tokenizing address field strings\n     *\n     * @constructor\n     * @param {String} str Address field string\n     */\n    addressparser.Tokenizer = function(str) {\n\n        this.str = (str || \"\").toString();\n        this.operatorCurrent = \"\";\n        this.operatorExpecting = \"\";\n        this.node = null;\n        this.escaped = false;\n\n        this.list = [];\n\n    };\n\n    /**\n     * Operator tokens and which tokens are expected to end the sequence\n     */\n    addressparser.Tokenizer.prototype.operators = {\n        \"\\\"\": \"\\\"\",\n        \"(\": \")\",\n        \"<\": \">\",\n        \",\": \"\",\n        \":\": \";\"\n    };\n\n    /**\n     * Tokenizes the original input string\n     *\n     * @return {Array} An array of operator|text tokens\n     */\n    addressparser.Tokenizer.prototype.tokenize = function() {\n        var chr, list = [];\n        for (var i = 0, len = this.str.length; i < len; i++) {\n            chr = this.str.charAt(i);\n            this.checkChar(chr);\n        }\n\n        this.list.forEach(function(node) {\n            node.value = (node.value || \"\").toString().trim();\n            if (node.value) {\n                list.push(node);\n            }\n        });\n\n        return list;\n    };\n\n    /**\n     * Checks if a character is an operator or text and acts accordingly\n     *\n     * @param {String} chr Character from the address field\n     */\n    addressparser.Tokenizer.prototype.checkChar = function(chr) {\n        if ((chr in this.operators || chr === \"\\\\\") && this.escaped) {\n            this.escaped = false;\n        } else if (this.operatorExpecting && chr === this.operatorExpecting) {\n            this.node = {\n                type: \"operator\",\n                value: chr\n            };\n            this.list.push(this.node);\n            this.node = null;\n            this.operatorExpecting = \"\";\n            this.escaped = false;\n            return;\n        } else if (!this.operatorExpecting && chr in this.operators) {\n            this.node = {\n                type: \"operator\",\n                value: chr\n            };\n            this.list.push(this.node);\n            this.node = null;\n            this.operatorExpecting = this.operators[chr];\n            this.escaped = false;\n            return;\n        }\n\n        if (!this.escaped && chr === \"\\\\\") {\n            this.escaped = true;\n            return;\n        }\n\n        if (!this.node) {\n            this.node = {\n                type: \"text\",\n                value: \"\"\n            };\n            this.list.push(this.node);\n        }\n\n        if (this.escaped && chr !== \"\\\\\") {\n            this.node.value += \"\\\\\";\n        }\n\n        this.node.value += chr;\n        this.escaped = false;\n    };\n\n    return addressparser;\n}));"

/***/ }),
/* 1121 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Lars Kneschke <l.kneschke@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets');
/**
 * Widget to display maps
 *
 * @namespace   Tine.widgets
 * @class       Tine.widgets.MapPanel
 * @extends     GeoExt.MapPanel
 */

Tine.widgets.MapPanel = Ext.extend(Ext.Panel, {
  initComponent: function initComponent() {
    Tine.widgets.MapPanel.superclass.initComponent.call(this);
  },
  afterRender: function afterRender() {
    var me = this;

    __webpack_require__.e(/* require.ensure | Tinebase/js/OpenLayers */ 32).then((function () {
      __webpack_require__(680);

      __webpack_require__(681); // fix OpenLayers script location to find images/themes/...


      OpenLayers._getScriptLocation = function () {
        return 'library/OpenLayers/';
      };

      me.geoExtPanel = new GeoExt.MapPanel({
        zoom: me.zoom || 4,
        map: new OpenLayers.Map(),
        layers: [new OpenLayers.Layer.OSM()]
      });
      me.add(me.geoExtPanel);
      me.fireEvent('mapAdded', me);
    }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);

    Tine.widgets.MapPanel.superclass.afterRender.call(this);
  },
  setCenter: function setCenter(lon, lat) {
    this.geoExtPanel.center = new OpenLayers.LonLat(lon, lat).transform(new OpenLayers.Projection("EPSG:4326"), this.geoExtPanel.map.getProjectionObject());
    this.geoExtPanel.map.setCenter(this.center); // add a marker

    var size = new OpenLayers.Size(32, 32);
    var offset = new OpenLayers.Pixel(0, -size.h);
    var icon = new OpenLayers.Icon('images/oxygen/32x32/actions/flag-red.png', size, offset);
    var markers = new OpenLayers.Layer.Markers("Markers");
    markers.addMarker(new OpenLayers.Marker(this.geoExtPanel.center, icon));
    this.geoExtPanel.map.addLayer(markers);
  },
  beforeDestroy: function beforeDestroy() {
    if (this.geoExtPanel && this.geoExtPanel.map) {
      delete this.geoExtPanel.map;
    }

    this.supr().beforeDestroy.apply(this, arguments);
  }
});
Ext.reg('widget-mappanel', Tine.widgets.MapPanel);

/***/ }),
/* 1122 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2012-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets');
/**
 * @namespace   Tine.widgets
 * @class       Tine.widgets.ContentTypeTreePanel
 * @extends     Ext.tree.TreePanel
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @param       {Object} config Configuration options
 * @description
 * <p>Utility class for generating content type trees as used in the apps westpanel</p>
 *<p>Example usage:</p>
<pre><code>
var modulePanel =  new Tine.widgets.ContentTypeTreePanel({
    app: Tine.Tinebase.appMgr.get('Timetracker'),
    contentTypes: [{modelName: 'Timesheet', requiredRight: null}, {modelName: 'Timeaccount', requiredRight: 'manage'}],
    contentType: 'Timeaccount'
});
</code></pre>
 */

Tine.widgets.ContentTypeTreePanel = function (config) {
  Ext.apply(this, config);
  Tine.widgets.ContentTypeTreePanel.superclass.constructor.call(this);
};

Ext.extend(Tine.widgets.ContentTypeTreePanel, Ext.tree.TreePanel, {
  rootVisible: false,
  border: false,
  root: null,
  title: 'Modules',
  // i18n._('Modules')
  collapsible: true,
  baseCls: 'ux-arrowcollapse',
  animCollapse: true,
  titleCollapse: true,
  draggable: true,
  autoScroll: false,
  autoHeight: true,
  canonicalName: 'ModulPicker',
  collapsed: false,
  renderHidden: true,
  recordClass: null,

  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * @cfg {Array} contentTypes
   */
  contentTypes: null,

  /**
   * @cfg {String} contentType 
   */
  contentType: null,

  /**
   * Enable state
   * 
   * @type {Boolean}
   */
  stateful: true,

  /**
   * if a previous state has been applied, this is set to true.
   * if restoring the last state fails, this is set to false
   * 
   * @type Boolean
   */
  stateApplied: null,

  /**
   * define state events
   * 
   * @type {Array}
   */
  stateEvents: ['collapse', 'expand', 'collapsenode', 'expandnode'],

  /**
   * @private {Ext.tree.treeNode} the latest clicked node
   */
  lastClickedNode: null,

  /**
   * init
   */
  initComponent: function initComponent() {
    this.stateId = this.app.name + (this.contentType ? this.contentType : '') + '-moduletree';
    Tine.widgets.ContentTypeTreePanel.superclass.initComponent.call(this);
    this.setTitle(i18n._(this.title));
    var treeRoot = new Ext.tree.TreeNode({
      expanded: true,
      text: '',
      allowDrag: false,
      allowDrop: false,
      icon: false
    });
    var groupNodes = {};
    this.setRootNode(treeRoot);
    var treeRoot = this.getRootNode();
    this.recordClass = Tine[this.app.appName].Model[this.contentType];
    this.on('click', this.saveClickedNodeState, this);

    _.each(this.contentTypes, (ct, idx) => {
      ct.pos = ct.hasOwnProperty('pos') ? ct.pos : idx * 100;
    });

    this.contentTypes = _.sortBy(this.contentTypes, 'pos');
    Ext.each(this.contentTypes, function (ct) {
      var modelName = ct.hasOwnProperty('meta') ? ct.meta.modelName : ct.hasOwnProperty('model') ? ct.model : ct.modelName;
      var modelApp = ct.app ? ct.app : ct.appName ? Tine.Tinebase.appMgr.get(ct.appName) : this.app;
      var recordClass = Tine[modelApp.appName].Model[modelName];

      if (!recordClass && !ct.text) {
        // module is disabled (feature switch) or otherwise non-functional
        return;
      }

      var contentType = ct.contentType ? ct.contentType : recordClass.getMeta('modelName');
      var group = recordClass ? recordClass.getMeta('group') : false;

      if (group) {
        if (!groupNodes[group]) {
          groupNodes[group] = new Ext.tree.TreeNode({
            id: 'modulenode-' + group,
            iconCls: modelApp.appName + modelName,
            text: modelApp.i18n._hidden(group),
            leaf: false,
            expanded: false
          });
          treeRoot.appendChild(groupNodes[group]);
        }

        var parentNode = groupNodes[group];
      } else {
        var parentNode = treeRoot;
      } // check requiredRight if any
      // add check for model name also


      if (ct.requiredRight && recordClass && !Tine.Tinebase.common.hasRight(ct.requiredRight, this.app.appName, recordClass.getMeta('recordsName').toLowerCase()) && !Tine.Tinebase.common.hasRight(ct.requiredRight, this.app.appName, recordClass.getMeta('modelName').toLowerCase()) && !Tine.Tinebase.common.hasRight(ct.requiredRight, this.app.appName, recordClass.getMeta('modelName').toLowerCase() + 's')) return true;
      var c = {
        id: 'treenode-' + contentType,
        contentType: contentType,
        iconCls: ct.iconCls ? ct.iconCls : modelName ? modelApp.appName + modelName : contentType,
        text: ct.text ? ct.text : recordClass.getModuleName(),
        leaf: true
      };

      if (ct.genericCtxActions && recordClass) {
        c.container = modelApp.getRegistry().get('default' + recordClass.getMeta('modelName') + 'Container');
      }

      var child = new Ext.tree.TreeNode(c);
      child.on('click', function () {
        this.app.getMainScreen().setActiveContentType(contentType);
      }, this); // append generic ctx-items (Tine.widgets.tree.ContextMenu)

      if (ct.genericCtxActions) {
        this['contextMenu' + modelName] = Tine.widgets.tree.ContextMenu.getMenu({
          nodeName: modelApp.i18n.ngettext(recordClass.getMeta('recordName'), recordClass.getMeta('recordsName'), 12),
          actions: ct.genericCtxActions,
          scope: this,
          backend: 'Tinebase_Container',
          backendModel: 'Container'
        });
        child.on('contextmenu', function (node, event) {
          event.stopEvent();

          if (node.leaf) {
            this.ctxNode = node;
            this['contextMenu' + modelName].showAt(event.getXY());
          }
        }, this);
      }

      parentNode.appendChild(child);
    }, this);
  },

  /**
   * saves the last clicked node as state
   * 
   * @param {Ext.tree.treeNode} node
   * @param {Ext.EventObjectImpl} event
   */
  saveClickedNodeState: function saveClickedNodeState(node, event) {
    this.lastClickedNode = node;
    this.saveState();
  },

  /**
   * @see Ext.Component
   */
  getState: function getState() {
    var root = this.getRootNode();
    var state = {
      expanded: [],
      selected: this.lastClickedNode ? this.lastClickedNode.id : null
    };
    Ext.each(root.childNodes, function (node) {
      state.expanded.push(!!node.expanded);
    }, this);
    return state;
  },

  /**
   * applies state to cmp
   * 
   * @param {Object} state
   */
  applyState: function applyState(state) {
    var root = this.getRootNode();
    Ext.each(state.expanded, function (isExpanded, index) {
      // check if node exists, as user might have lost permissions for modules
      if (root.childNodes[index]) {
        root.childNodes[index].expanded = isExpanded;
      }
    }, this);
    (function () {
      var node = this.getNodeById(state.selected);

      if (node) {
        node.select();
        this.stateApplied = true;
        var contentType = node.id.split('-')[1];
        this.app.getMainScreen().setActiveContentType(contentType ? contentType : '');
      } else {
        this.stateApplied = false;
      }
    }).defer(10, this);
  },

  /**
   * is called after render, calls the superclass and this.afterRenderSelectNode
   */
  afterRender: function afterRender() {
    Tine.widgets.ContentTypeTreePanel.superclass.afterRender.call(this);
    this.afterRenderSelectNode();
  },

  /**
   * is called after render and will be deferred, if state restoring is still running
   */
  afterRenderSelectNode: function afterRenderSelectNode() {
    // wait if we don't know already if the state could be applied
    if (this.stateful === true && this.stateApplied === null) {
      this.afterRenderSelectNode.defer(20, this);
      return;
    } // don't do anything, if a state has been applied


    if (this.stateful === true && this.stateApplied === true) {
      return;
    } // find treenode to select


    var treeNode = this.getRootNode().findChild('id', 'treenode-' + this.contentType); // if no treenode was found, try to find the module node

    if (!treeNode) {
      // get group by current contentType
      for (var index = 0; index < this.contentTypes.length; index++) {
        if (this.contentTypes[index].modelName == this.contentType) {
          var group = this.contentTypes[index].group;
        }
      } // if a group was found, try to expand the node


      if (group) {
        var moduleNode = this.getRootNode().findChild('id', 'modulenode-' + group);

        if (moduleNode) {
          moduleNode.expand();
        } // try to find node a bit later after expanding the parent, so we can be sure the node is rendered already


        (function () {
          var treeNode = moduleNode.findChild('id', 'treenode-' + this.contentType);

          if (treeNode) {
            this.getSelectionModel().select(treeNode);
          }
        }).defer(50, this);
      }
    } else {
      //  select the node if it has been found
      if (treeNode) {
        this.getSelectionModel().select(treeNode);
      }
    }
  },

  /**
   * initializes the state and is called before afterRender
   * 
   * @see Ext.Component
   */
  initState: function initState() {
    Tine.widgets.ContentTypeTreePanel.superclass.initState.call(this);
    (function () {
      if (this.stateApplied === null) {
        this.stateApplied = false;
      }
    }).defer(50, this);
  }
});

/***/ }),
/* 1123 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <alex@stintzing.net>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.form');
/**
* @namespace   Tine.widgets.form
* @class       Tine.widgets.form.RecordPickerManager
* @author      Alexander Stintzing <a.stintzing@metaways.de>
*/

Tine.widgets.form.RecordPickerManager = function () {
  var items = {};
  return {
    /**
     * returns a registered recordpicker or creates the default one
     * @param {String/Tinebase.Application} appName      expands to recordClass: Tine[appName].Model[modelName],
     * @param {String/Tinebase.data.Record} modelName               recordProxy: Tine[appName][modelName.toLowerCase() + 'Backend'])
     * @param {Object} config       additional Configuration
     * @return {Object} recordpicker
     */
    get: function get(appName, modelName, config) {
      config = config || {};
      var appName = Ext.isString(appName) ? appName : appName.appName,
          modelName = Ext.isFunction(modelName) ? modelName.getMeta('modelName') : modelName,
          key = appName + modelName + (config.allowMultiple ? 's' : '');

      if (items[key]) {
        // if registered
        if (Ext.isString(items[key])) {
          // xtype
          return Ext.ComponentMgr.create(config, items[key]);
        } else {
          return new items[key](config);
        }
      } else {
        // not registered, create default
        var pickerClass = config.allowMultiple ? Tine.Tinebase.widgets.form.RecordsPickerCombo : Tine.Tinebase.widgets.form.RecordPickerComboBox,
            defaultconfig = {
          recordClass: Tine.Tinebase.data.RecordMgr.get(appName, modelName),
          recordProxy: Tine[appName][modelName.toLowerCase() + 'Backend'],
          loadingText: i18n._('Searching...')
        };
        Ext.apply(defaultconfig, config);
        return new pickerClass(defaultconfig);
      }
    },

    /**
     * Registers a component
     * @param {String} appName          the application registered for
     * @param {String} modelName        the registered model name
     * @param {String/Object} component the component or xtype to register 
     */
    register: function register(appName, modelName, component) {
      if (!Tine.hasOwnProperty('log')) {
        this.register.defer(100, this, [appName, modelName, component]);
        return false;
      }

      var appName = Ext.isString(appName) ? appName : appName.appName,
          modelName = Ext.isFunction(modelName) ? modelName.getMeta('modelName') : modelName,
          key = appName + modelName;
      Tine.log.debug('RecordPickerManager::registerItem: ' + appName + modelName);
      items[key] = component;
    }
  };
}();

/***/ }),
/* 1124 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var widgets_form_JsonField__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1125);
/* harmony import */ var widgets_form_JsonField__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(widgets_form_JsonField__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var widgets_form_XmlField__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1126);
/* harmony import */ var widgets_form_XmlField__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(widgets_form_XmlField__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var widgets_form_RecordEditField__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1127);
/* harmony import */ var widgets_form_RecordEditField__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(widgets_form_RecordEditField__WEBPACK_IMPORTED_MODULE_2__);
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.form');



/**
 * central form field manager
 * - get form field for a given field
 * - register form field for a given field
 *
 * @namespace   Tine.widgets.form
 * @class       Tine.widgets.form.FieldManager
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @singleton
 */

Tine.widgets.form.FieldManager = function () {
  var fields = {};
  return {
    /**
     * const for category editDialog
     */
    CATEGORY_EDITDIALOG: 'editDialog',

    /**
     * const for category propertyGrid
     */
    CATEGORY_PROPERTYGRID: 'propertyGrid',
    specialTypeMap: {
      password: 'tw-passwordTriggerField'
    },

    /**
     * get form field of well known field names
     *
     * @param {String} fieldName
     * @return {Object}
     */
    getByFieldname: function getByFieldname(fieldName) {
      var field = null;
      return field;
    },

    /**
     * get form field by data type
     *
     * @param {String} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {editDialog|propertyGrid} optional.
     * @param {Object} config
     * @return {Object}
     */
    getByModelConfig: function getByModelConfig(appName, modelName, fieldName, category, config) {
      var recordClass = Tine.Tinebase.data.RecordMgr.get(appName, modelName),
          modelConfig = recordClass ? recordClass.getModelConfiguration() : null,
          fieldDefinition = _.get(modelConfig, 'fields.' + fieldName, {}); // have self contained fieldDefinition 


      fieldDefinition.appName = appName;
      fieldDefinition.fieldName = fieldName;

      if (_.get(fieldDefinition, 'disabled')) {
        return null;
      }

      return this.getByFieldDefinition(fieldDefinition, category, config);
    },
    getByFieldDefinition: function getByFieldDefinition(fieldDefinition, category, config) {
      category = category || Tine.widgets.form.FieldManager.CATEGORY_EDITDIALOG;
      config = config || {};
      var field = {},
          fieldType = fieldDefinition.type || 'textfield',
          app = Tine.Tinebase.appMgr.get(fieldDefinition.owningApp || fieldDefinition.appName),
          i18n = fieldDefinition.useGlobalTranslation ? window.i18n : app.i18n;

      if (fieldType === 'virtual' && fieldDefinition.config) {
        fieldType = fieldDefinition.config.type || 'textfield';
        fieldDefinition = _.merge({}, fieldDefinition, fieldDefinition.config);
      }

      field.fieldLabel = i18n._hidden(fieldDefinition.label || fieldDefinition.fieldName);
      field.name = fieldDefinition.fieldName || fieldDefinition.name;
      field.readOnly = !!fieldDefinition.readOnly || !!_.get(fieldDefinition, 'uiconfig.readOnly');
      field.allowBlank = !!(fieldDefinition.validators && fieldDefinition.validators.allowEmpty); // make field available via recordForm.formfield_NAME

      field.ref = '../../formfield_' + field.name;

      if (fieldDefinition['default']) {
        field['default'] = i18n._hidden(fieldDefinition['default']);
      }

      switch (fieldType) {
        case 'money':
          field.xtype = 'extuxmoneyfield';

          if (fieldDefinition.hasOwnProperty('allowNegative')) {
            field.allowNegative = fieldDefinition.allowNegative;
          }

          break;

        case 'date':
        case 'datetime_separated_date':
          field.xtype = 'datefield';

          if (fieldDefinition.dateFormat) {
            field.dateFormat = fieldDefinition.dateFormat;
          }

          if (fieldDefinition.format) {
            field.format = fieldDefinition.format;
          }

          break;

        case 'time':
          field.xtype = 'timefield';
          break;

        case 'datetime':
          field.xtype = 'datetimefield'; // form ux.datetimefield

          break;

        case 'bool':
        case 'boolean':
          if (category === 'editDialog') {
            field.xtype = 'checkbox';
            field.boxLabel = _.get(fieldDefinition, 'boxLabel', field.fieldLabel);
            field.checked = field['default'];
            field.hideLabel = !_.get(fieldDefinition, 'boxLabel');
            field.blurOnChange = true;
          } else {
            field.xtype = 'booleancombo';
            field.blurOnSelect = true;
          }

          break;

        case 'integer':
          field.xtype = 'numberfield';
          field.allowDecimals = false;

          if (fieldDefinition.specialType && fieldDefinition.specialType === 'percent') {
            field.xtype = 'extuxnumberfield';
            field.useThousandSeparator = false;
            field.suffix = ' %';
          }

          if (fieldDefinition.specialType && fieldDefinition.specialType === 'durationSec') {
            field.xtype = 'durationspinner';
            field.baseUnit = 'seconds';
          }

          if (fieldDefinition.specialType && fieldDefinition.specialType === 'minutes') {
            field.xtype = 'durationspinner';
            field.baseUnit = 'minutes';
          }

          if (fieldDefinition.max) {
            field.maxValue = fieldDefinition.max;
          }

          if (fieldDefinition.min) {
            field.minValue = fieldDefinition.min;
          }

          break;

        case 'float':
          field.xtype = 'numberfield';
          field.decimalPrecision = 2;

          if (fieldDefinition.specialType && fieldDefinition.specialType === 'percent') {
            field.xtype = 'extuxnumberfield';
            field.suffix = ' %';
          }

          if (fieldDefinition.max) {
            field.maxValue = fieldDefinition.max;
          }

          if (fieldDefinition.min) {
            field.minValue = fieldDefinition.min;
          }

          break;

        case 'user':
          field.xtype = 'addressbookcontactpicker';
          field.userOnly = true;
          field.useAccountRecord = true;
          break;

        case 'relation':
        case 'relations':
          if (fieldDefinition.config && fieldDefinition.config.appName && fieldDefinition.config.modelName) {
            field.xtype = 'tinerelationpickercombo';
            field.recordClass = Tine[fieldDefinition.config.appName].Model[fieldDefinition.config.modelName];
            field.app = fieldDefinition.config.appName;
            field.relationType = fieldDefinition.config.type;
            field.modelUnique = true;

            if (fieldDefinition.config.additionalFilterSpec) {
              field.additionalFilterSpec = fieldDefinition.config.additionalFilterSpec;
            } // TODO pass degree and other options in config?


            field.relationDegree = 'sibling';

            if (fieldType === 'relations') {
              _.assign(field, {
                xtype: 'tinerelationpickergridpanel',
                isFormField: true,
                fieldName: fieldDefinition.fieldName,
                hideHeaders: true,
                height: 80
                /* 4 records */
                + 2 * 26
                /* 2 toolbars */

              });
            }
          }

          break;

        case 'record':
          if (fieldDefinition.config && fieldDefinition.config.appName && fieldDefinition.config.modelName) {
            if (fieldDefinition.config.additionalFilterSpec) {
              field.additionalFilterSpec = fieldDefinition.config.additionalFilterSpec;
            }

            if (category === 'editDialog' && fieldDefinition.config.dependentRecords) {
              field.xtype = 'tw-recordEditField';
              field.appName = fieldDefinition.config.appName;
              field.modelName = fieldDefinition.config.modelName;
              field.fieldName = fieldDefinition.fieldName;
              break;
            }

            var picker = Tine.widgets.form.RecordPickerManager.get(fieldDefinition.config.appName, fieldDefinition.config.modelName, Ext.apply(field, config));
            field = picker;
          }

          break;

        case 'records':
          if (category === 'editDialog') {
            if (fieldDefinition.config.additionalFilterSpec) {
              field.additionalFilterSpec = fieldDefinition.config.additionalFilterSpec;
            }

            field.xtype = 'wdgt.pickergrid';
            field.recordClass = Tine[fieldDefinition.config.appName].Model[fieldDefinition.config.modelName];
            field.allowCreateNew = _.get(fieldDefinition, 'config.dependentRecords', false);
            field.enableTbar = !_.get(fieldDefinition, 'config.dependentRecords', false);
            field.isFormField = true;
            field.fieldName = fieldDefinition.fieldName;
            field.hideHeaders = true;
            field.height = 80
            /* 4 records */
            + field.enableTbar * 26 + 26;
            /* 2 toolbars */

            if (_.get(fieldDefinition, 'config.dependentRecords', false)) {
              _.set(field, 'editDialogConfig.mode', 'local');
            }
          } else {
            var picker = Tine.widgets.form.RecordsPickerManager.get(fieldDefinition.config.appName, fieldDefinition.config.modelName, Ext.apply(field, config));
            field = picker;
          }

          break;

        case 'model':
          const availableModels = _.get(fieldDefinition, 'config.availableModels', []);

          if (availableModels.length) {
            field.xtype = 'combo';
            field.forceSelection = true;
            field.typeAhead = true;
            field.store = _.reduce(availableModels, function (arr, classname) {
              var recordClass = Tine.Tinebase.data.RecordMgr.get(classname);

              if (recordClass) {
                arr.push([classname, recordClass.getRecordName()]);
              }

              return arr;
            }, []);
          }

          break;

        case 'dynamicRecord':
          // NOTE: this editor depends and the className _data_ and therefore can't be assigned statically
          //       as the editor api (get/setValue) does not know about the record the value comes from
          //       it's not possible to auto create a editor here
          field.xtype = 'tw-recordEditField';
          field.appName = fieldDefinition.config.appName;
          field.modelName = fieldDefinition.config.refModelField;
          field.fieldName = fieldDefinition.fieldName;
          break;

        case 'keyfield':
          field.xtype = 'widget-keyfieldcombo';
          field.app = app;
          field.keyFieldName = fieldDefinition.name;
          break;

        case 'text':
        case 'fulltext':
          field.xtype = 'textarea';
          field.height = 70; // 5 lines

          break;

        case 'stringAutocomplete':
          field.xtype = 'tine.widget.field.AutoCompleteField';
          field.appName = fieldDefinition.config.appName;
          field.modelName = fieldDefinition.config.modelName;
          break;

        case 'numberableStr':
        case 'numberableInt':
          field.xtype = 'textfield';
          field.disabled = true;
          break;

        case 'json':
          field.xtype = 'tw-jsonfield';
          field.height = 150; // 12 lines

          break;

        case 'xml':
          field.xtype = 'tw-xmlfield';
          field.height = 150; // 12 lines

          break;

        case 'container':
          field.xtype = 'tinewidgetscontainerselectcombo';
          break;

        case 'containers':
          field.xtype = 'containerspicker';
          field.appName = fieldDefinition.config.appName;
          field.modelName = fieldDefinition.config.modelName;
          break;

        case 'filelocation':
          field.xtype = 'fileselectionfield';
          field.mode = fieldDefinition.config.mode;
          field.locationTypesEnabled = fieldDefinition.config.locationTypesEnabled;
          field.allowMultiple = fieldDefinition.config.allowMultiple;
          field.constraint = fieldDefinition.config.constraint;
          field.initialPath = fieldDefinition.config.initialPath;
          field.fileName = fieldDefinition.config.fileName;
          break;

        case 'hexcolor':
          field.xtype = 'colorfield';
          field.width = 80;
          break;

        case 'label':
          field.xtype = 'label';
          break;

        default:
          field.xtype = this.specialTypeMap[fieldDefinition.specialType] || 'textfield';

          if (fieldDefinition.length) {
            field.maxLength = fieldDefinition.length;
          }

          break;
      }

      Ext.apply(field, config);
      return field;
    },

    /**
     * returns form field for given field
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {editDialog|propertyGrid} optional.
     * @param {Object} config
     * @return {Object}
     */
    get: function get(appName, modelName, fieldName, category, config) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]),
          config = config || {}; // check for registered renderer

      var field = fields[categoryKey] ? fields[categoryKey] : fields[genericKey]; // check for common names

      if (!field) {
        field = this.getByFieldname(fieldName);
      } // check for known datatypes


      if (!field) {
        field = this.getByModelConfig(appName, modelName, fieldName, category, config);
      }

      return field;
    },

    /**
     * register renderer for given field
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {Object} field
     * @param {String} category {editDialog|propertyGrid} optional.
     */
    register: function register(appName, modelName, fieldName, field, category) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]);
      field.name = fieldName;
      fields[category ? categoryKey : genericKey] = field;
    },

    /**
     * check if a field is explicitly registered
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {editDialog|propertyGrid} optional.
     * @return {Boolean}
     */
    has: function has(appName, modelName, fieldName, category) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]); // check for registered renderer

      return (fields[categoryKey] ? fields[categoryKey] : fields[genericKey]) ? true : false;
    },

    /**
     * returns the modelName by modelName or record
     *
     * @param {Record/String} modelName
     * @return {String}
     */
    getModelName: function getModelName(modelName) {
      return Ext.isFunction(modelName) ? modelName.getMeta('modelName') : modelName;
    },

    /**
     * returns the modelName by appName or application instance
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @return {String}
     */
    getAppName: function getAppName(appName) {
      return Ext.isString(appName) ? appName : appName.appName;
    },

    /**
     * returns a key by joining the array values
     *
     * @param {Array} params
     * @return {String}
     */
    getKey: function getKey(params) {
      return params.join('_');
    }
  };
}();

/***/ }),
/* 1125 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2019 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.form');
Tine.Tinebase.widgets.form.JsonField = Ext.extend(Ext.form.Field, {
  defaultAutoCreate: {
    tag: 'div'
  },
  afterRender: function afterRender() {
    Tine.Tinebase.widgets.form.JsonField.superclass.afterRender.apply(this, arguments);
    __webpack_require__.e(/* import() | Tinebase/js/ace */ 36).then(__webpack_require__.bind(null, 578)).then(() => {
      this.ed = ace.edit(this.el.id, {
        mode: 'ace/mode/json',
        fontFamily: 'monospace',
        fontSize: 12
      }); // prevent value override from empty ed.getValue()

      this.setValue(this.value || '');
    });
  },
  setValue: function setValue(value) {
    Tine.Tinebase.widgets.form.JsonField.superclass.setValue.apply(this, arguments);

    if (this.ed) {
      this.ed.setValue(Ext.isString(value) ? value : JSON.stringify(value, undefined, 4), -1);
    }
  },
  getValue: function getValue() {
    let value = this.value;

    if (this.ed) {
      value = this.ed.getValue();
    }

    return value;
  }
});
Ext.reg('tw-jsonfield', Tine.Tinebase.widgets.form.JsonField);

/***/ }),
/* 1126 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2019 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.form');
Tine.Tinebase.widgets.form.XmlField = Ext.extend(Ext.form.Field, {
  defaultAutoCreate: {
    tag: 'div'
  },
  afterRender: function afterRender() {
    Tine.Tinebase.widgets.form.XmlField.superclass.afterRender.apply(this, arguments);
    __webpack_require__.e(/* import() | Tinebase/js/ace */ 36).then(__webpack_require__.bind(null, 578)).then(() => {
      this.ed = ace.edit(this.el.id, {
        mode: 'ace/mode/xml',
        fontFamily: 'monospace',
        fontSize: 12
      });
      this.setValue(this.value || '');
    });
  },
  setValue: function setValue(value) {
    Tine.Tinebase.widgets.form.XmlField.superclass.setValue.apply(this, arguments);

    if (this.ed) {
      this.ed.setValue(value);
      this.ed.clearSelection();
    }
  },
  getValue: function getValue() {
    let value = this.value;

    if (this.ed) {
      value = this.ed.getValue();
    }

    return value;
  }
});
Ext.reg('tw-xmlfield', Tine.Tinebase.widgets.form.XmlField);

/***/ }),
/* 1127 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Ching-En, Cheng <c.cheng@metaways.de>
 * @copyright   Copyright (c) 2020 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine*/
Ext.ns('Tine.Tinebase.widgets.form.RecordEditField');
Tine.Tinebase.widgets.form.RecordEditField = Ext.extend(Ext.form.TriggerField, {
  itemCls: 'tw-recordEditField',
  triggerClass: 'action_edit',
  editable: false,
  initComponent: async function initComponent() {
    var _ = window.lodash;
    this.recordClass = Tine.Tinebase.data.RecordMgr.get(this.appName, this.modelName);
    this.emptyText = i18n._('No record');
    Tine.Tinebase.widgets.form.RecordEditField.superclass.initComponent.call(this);
  },
  assertRecordClass: function assertRecordClass(owningRecord) {
    if (!owningRecord) return; // if the field is a dynamicReccord, get classname and adopt this.recordClass

    this.owningRecord = owningRecord;

    const owningRecordClass = _.get(this.owningRecord, 'constructor');

    const owningRecordFieldDefinitions = _.get(owningRecordClass, 'getFieldDefinitions') ? owningRecordClass.getFieldDefinitions() : null;

    const ownFieldDefinition = _.get(_.find(owningRecordFieldDefinitions, {
      name: this.fieldName
    }), 'fieldDefinition');

    const classNameField = _.get(ownFieldDefinition, 'config.refModelField');

    const className = _.get(this.owningRecord, 'data.' + classNameField);

    this.recordClass = className ? Tine.Tinebase.data.RecordMgr.get(className) || this.recordClass : this.recordClass;
  },
  setValue: function setValue(v, owningRecord) {
    this.recordData = _.get(v, 'data', v);
    this.assertRecordClass(owningRecord);
    let valueRecord = this.recordClass && this.recordData ? Tine.Tinebase.data.Record.setFromJson(this.recordData, this.recordClass) : null;
    Tine.Tinebase.widgets.form.RecordEditField.superclass.setValue.call(this, valueRecord ? valueRecord.getTitle() || '...' : '');
  },
  checkState: function checkState(editDialog, owningRecord) {
    this.assertRecordClass(owningRecord);
  },
  onTriggerClick: function onTriggerClick() {
    this.assertRecordClass(this.owningRecord);

    if (!this.recordClass) {
      alert('select model');
      return;
    }

    let me = this;
    let editDialogClass = Tine.widgets.dialog.EditDialog.getConstructor(this.recordClass);

    if (editDialogClass) {
      editDialogClass.openWindow({
        mode: 'local',
        record: this.recordData,
        listeners: {
          scope: me,
          'update': updatedRecord => {
            let record = !updatedRecord.data ? Tine.Tinebase.data.Record.setFromJson(updatedRecord, me.recordClass) : updatedRecord;
            Tine.Tinebase.common.assertComparable(record);
            this.setValue(record);
          },
          'cancel': () => {
            if (new Date().getTime() - 1000 < this.blurOnSelectLastRun) return;

            _.delay(() => {
              this.blurOnSelectLastRun = new Date().getTime();
              const focusClass = this.focusClass;
              this.focusClass = '';
              Ext.form.TriggerField.superclass.onBlur.call(this);
              this.focusClass = focusClass;
            }, 100);
          }
        }
      });
    }
  },
  getValue: function getValue() {
    return this.recordData;
  }
});
Ext.reg('tw-recordEditField', Tine.Tinebase.widgets.form.RecordEditField);

/***/ }),
/* 1128 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <alex@stintzing.net>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.dialog');
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.AddToRecordPanel
 * @extends     Ext.FormPanel
 * @author      Alexander Stintzing <alex@stintzing.net>
 */

Tine.widgets.dialog.AddToRecordPanel = Ext.extend(Ext.FormPanel, {
  /**
   * the name of the application the record to be added belongs to
   * @cfg {String}
   */
  appName: null,

  /**
   * the record class of the record the selected records should be added to
   * @cfg {Tine.Tinebase.data.Record}
   */
  recordClass: null,

  /**
   * the selection filter if is filter select
   * @type {Object}
   */
  selectionFilter: null,

  /**
   * count of records to add to
   * @type {Integer}
   */
  count: null,

  /**
   * the calling app
   * @type {String}
   */
  callingApp: null,

  /**
   * the calling model
   * @type {String}
   */
  callingModel: null,

  /**
   * the relations to add as Json Encoded array or bool on filterSelection
   * @type {Boolean|String} 
   */
  addRelations: null,
  // private
  app: null,
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  labelAlign: 'top',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    if (!this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    }

    Tine.log.debug('initComponent: appName: ', this.appName);
    Tine.log.debug('initComponent: app: ', this.app); // init actions

    this.initActions(); // init buttons and tbar

    this.initButtons(); // get items for this dialog

    this.items = this.getFormItems();
    Tine.widgets.dialog.AddToRecordPanel.superclass.initComponent.call(this);
  },

  /**
   * initializes the actions
   */
  initActions: function initActions() {
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    });
    this.action_update = new Ext.Action({
      text: i18n._('Ok'),
      minWidth: 70,
      scope: this,
      handler: this.onUpdate,
      iconCls: 'action_saveAndClose'
    });
  },

  /**
   * create the buttons
   * use preference settings for order of save and close buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->'];
    this.fbar.push(this.action_cancel, this.action_update);
  },

  /**
   * is called on render, creates keymap
   * @param {} ct
   * @param {} position
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.AddToRecordPanel.superclass.onRender.call(this, ct, position); // generalized keybord map for edit dlgs

    new Ext.KeyMap(this.el, [{
      key: [10, 13],
      // ctrl + return
      ctrl: true,
      fn: this.onUpdate,
      scope: this
    }]);
  },

  /**
   * is called on cancel
   */
  onCancel: function onCancel() {
    this.fireEvent('cancel');
    this.onClose();
  },

  /**
   * closes the window
   */
  onClose: function onClose() {
    this.purgeListeners();
    this.window.close();
  },

  /**
   * returns true if the form is valid, must be overridden
   * @return {Boolean}
   */
  isValid: Ext.emptyFn,

  /**
   * returns the items of the form, must be overridden
   * @return {Object} with the configured items
   */
  getFormItems: Ext.emptyFn,

  /**
   * returns the configuration for the relations to be created, must be overridden
   * @return {Object}
   */
  getRelationConfig: function getRelationConfig() {
    return {};
  },

  /**
   * returns the selected record. may be overridden.
   * @return {Object} config for the record to edit
   */
  getRecord: function getRecord() {
    var recordId = this.searchBox.getValue(),
        record = this.searchBox.store.getById(recordId);
    return record;
  },

  /**
   * is called when ok-button is pressed and edit dialog should be opened
   */
  onUpdate: function onUpdate() {
    if (this.isValid()) {
      if (this.app) {
        var ms = this.app.getMainScreen();

        if (ms) {
          var cp = ms.getCenterPanel();
        }
      }

      cp.onEditInNewWindow({
        actionType: 'edit'
      }, this.getRecord() ? this.getRecord() : this.searchBox.selectedRecord, [{
        ptype: 'addrelations_edit_dialog',
        selectionFilter: this.selectionFilter,
        addRelations: this.addRelations,
        relationConfig: this.getRelationConfig(),
        callingApp: this.callingApp,
        callingModel: this.callingModel
      }]);
      this.onClose();
    }
  }
});

/***/ }),
/* 1129 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * Base class for all Exception Handler dialogs
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.ExceptionHandlerDialog
 * @extends     Ext.FormPanel
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.dialog.ExceptionHandlerDialog = Ext.extend(Ext.FormPanel, {
  // private
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  labelAlign: 'top',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,
  fields: null,
  // private, auto set by exception

  /**
   * the calling application
   * 
   * @type Tine.Tinebase.Application
   */
  app: null,
  message: null,

  /**
   * the type of this exception handler dialog. May be error, warning, info, question
   * @type String
   */
  type: 'error',

  /**
   * the exception thrown by the server
   * 
   * @type {Object}
   */
  exception: null,

  /**
   * the callback function on OK
   * 
   * @type {Function}
   */
  callbackOnOk: null,

  /**
   * the callback scope on OK
   * @type {Object}
   */
  callbackOnOkScope: null,

  /**
   * the callback function on Cancel
   * 
   * @type {Function}
   */
  callbackOnCancel: null,

  /**
   * the callback scope on Cancel
   * @type {Object}
   */
  callbackOnCancelScope: null,

  /**
   * the callback function of Cancel and Ok, if not overwritten by callbackOnCancel or callbackOnOk
   * 
   * @type {Function}
   */
  callback: null,

  /**
   * the callback scope of Cancel and Ok, if not overwritten by callbackOnCancel or callbackOnOk
   * 
   * @type {Object}
   */
  callbackScope: null,
  messageHeight: 40,
  initComponent: function initComponent() {
    this.app = Tine.Tinebase.appMgr.get(this.exception.appName);
    this.message = this.app.i18n._hidden(this.exception.message);
    this.callbackOnOk = this.callbackOnOk ? this.callbackOnOk : this.callback ? this.callback : this.onClose;
    this.callbackOnCancel = this.callbackOnCancel ? this.callbackOnCancel : this.callback ? this.callback : this.onClose;
    this.callbackOnCancelScope = this.callbackOnCancelScope ? this.callbackOnCancelScope : this.callbackScope ? this.callbackScope : this;
    this.callbackOnOkScope = this.callbackOnOkScope ? this.callbackOnOkScope : this.callbackScope ? this.callbackScope : this;
    this.initActions();
    this.initButtons();
    this.initFormItems();
    Tine.widgets.dialog.ExceptionHandlerDialog.superclass.initComponent.call(this);
  },

  /**
   * create the buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->', this.action_cancel, this.action_update];
  },
  initFormItems: function initFormItems() {
    this.items = {
      border: false,
      frame: true,
      layout: 'border',
      cls: 'x-window-dlg',
      items: [{
        region: 'north',
        xtype: 'displayfield',
        style: {
          minHeight: '40px',
          paddingLeft: '40px'
        },
        height: this.messageHeight,
        'name': 'message',
        value: this.message,
        hideLabel: true,
        cls: 'ext-mb-' + this.type
      }, {
        region: 'center',
        xtype: 'columnform',
        labelAlign: 'top',
        formDefaults: {
          xtype: 'textfield',
          anchor: '100%',
          labelSeparator: '',
          columnWidth: 1,
          allowBlank: false
        },
        items: this.fields
      }]
    };
  },

  /**
   * is called on render, creates keymap
   * @param {} ct
   * @param {} position
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.ExceptionHandlerDialog.superclass.onRender.call(this, ct, position); // generalized keybord map for edit dlgs

    new Ext.KeyMap(this.getEl(), [{
      key: [10, 13],
      // ctrl + return
      ctrl: true,
      fn: this.callbackOnOk,
      scope: this
    }]);
  },
  onClose: function onClose() {
    this.purgeListeners();
    this.window.close();
  },
  onOk: function onOk() {
    var data = this.getForm().getFieldValues();
    this.callbackOnOk.call(this.callbackOnOkScope, data);
    this.onClose();
  },

  /**
   * initializes the actions
   */
  initActions: function initActions() {
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      minWidth: 70,
      handler: this.callbackOnCancel,
      scope: this.callbackOnCancelScope,
      iconCls: 'action_cancel'
    });
    this.action_update = new Ext.Action({
      text: i18n._('Ok'),
      minWidth: 70,
      scope: this,
      handler: this.onOk,
      iconCls: 'action_saveAndClose'
    });
  }
});
/**
 * @param {Object}
 * 
 * @return {Ext.ux.Window}
 */

Tine.widgets.dialog.ExceptionHandlerDialog.openWindow = function (config) {
  var app = Tine.Tinebase.appMgr.get(config.exception.appName);

  if (config.hasOwnProperty('exception')) {
    if (config.exception.hasOwnProperty('title') && config.exception.title) {
      var title = app.i18n._hidden(config.exception.title);
    } else if (config.exception.hasOwnProperty('number') && config.exception.number) {
      var title = String.format(i18n._('{1} - Exception {0}'), config.exception.code, app.getTitle());
    } else {
      var title = String.format(i18n._('{0} - Unknown Exception'), app.getTitle());
    }
  }

  var window = Tine.WindowFactory.getWindow({
    title: title,
    modal: true,
    width: config.hasOwnProperty('width') ? config.width : 290,
    height: config.hasOwnProperty('height') ? config.height : 95,
    contentPanelConstructor: 'Tine.widgets.dialog.ExceptionHandlerDialog',
    contentPanelConstructorConfig: config
  });
  return window;
};

/***/ }),
/* 1130 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2015 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.util');
/**
 * @namespace   Ext.ux.util
 * @class       Ext.ux.util.Cookie
 */

Ext.ux.util.Cookie = function (config) {
  this.path = "/";
  this.expires = new Date(new Date().getTime() + 1000 * 60 * 60 * 24 * 7); //7 days

  this.domain = null;
  this.secure = false;
  this.encode = false;
  Ext.apply(this, config);
};

Ext.override(Ext.ux.util.Cookie, {
  get: function get(name) {
    var c = document.cookie + ";";
    var re = /\s?(.*?)=(.*?);/g;
    var matches;

    while ((matches = re.exec(c)) != null) {
      if (name == matches[1]) {
        return this.decodeValue(matches[2]);
      }
    }

    return null;
  },
  set: function set(name, value) {
    document.cookie = name + "=" + this.encodeValue(value) + (this.expires == null ? "" : "; expires=" + this.expires.toGMTString()) + (this.path == null ? "" : "; path=" + this.path) + (this.domain == null ? "" : "; domain=" + this.domain) + (this.secure == true ? "; secure" : "");
  },
  clear: function clear(name) {
    var c = name + "=null; expires=Thu, 01-Jan-70 00:00:01 GMT";
    document.cookie = c + (this.path == null ? "" : "; path=" + this.path) + (this.domain == null ? "" : "; domain=" + this.domain) + (this.secure == true ? "; secure" : ""); // if path/domain/secure didn't match, force delete. more actions might be nessesary
    // @see http://stackoverflow.com/questions/2959010/how-to-get-the-domain-value-for-a-cookie-in-javascript

    if (this.get(name)) {
      document.cookie = c;
    }
  },
  encodeValue: function encodeValue(value) {
    return this.encode ? Ext.encode(value) : value;
  },
  decodeValue: function decodeValue(raw) {
    return this.encode ? Ext.decode(raw) : raw;
  }
});

/***/ }),
/* 1131 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.util.urlCoder');
/**
 * native encodeURIComponent converts space into %20 -> convert to modern +
 *
 * @param string
 * @returns {string}
 */

Ext.ux.util.urlCoder.encodeURIComponent = function (string) {
  return encodeURIComponent(string).replace(/\%20/gm, "+");
};
/**
 * native encodeURI converts space into %20 -> convert to modern +
 *
 * @param string
 * @returns {string}
 */


Ext.ux.util.urlCoder.encodeURI = function (string) {
  return encodeURI(string).replace(/\%20/gm, "+");
};
/**
 * native decodeURIComponent converts can't cope with modern + for spaces
 *
 * @param string
 * @returns {string}
 */


Ext.ux.util.urlCoder.decodeURIComponent = function (string) {
  return decodeURIComponent((string + '').replace(/\+/gm, "%20"));
};
/**
 * native decodeURI converts can't cope with modern + for spaces
 *
 * @param string
 * @returns {string}
 */


Ext.ux.util.urlCoder.decodeURI = function (string) {
  return decodeURI((string + '').replace(/\+/gm, "%20"));
};

/***/ }),
/* 1132 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.3.0
 * Copyright(c) 2006-2010 Ext JS, Inc.
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ns("Ext.ux");
/**
 * @class Ext.ux.FieldLabeler
 * <p>A plugin for Field Components which renders standard Ext form wrapping and labels
 * round the Field at render time regardless of the layout of the Container.</p>
 * <p>Usage:</p>
 * <pre><code>
    {
        xtype: 'combo',
        plugins: [ Ext.ux.FieldLabeler ],
        triggerAction: 'all',
        fieldLabel: 'Select type',
        store: typeStore
    }
 * </code></pre>
 */

Ext.ux.FieldLabeler = function () {
  //  Pulls a named property down from the first ancestor Container it's found in
  function getParentProperty(propName) {
    for (var p = this.ownerCt; p; p = p.ownerCt) {
      if (p[propName]) {
        return p[propName];
      }
    }
  }

  return {
    //      Add behaviour at important points in the Field's lifecycle.
    init: function init(f) {
      //          Replace the Field's onRender method with a sequence that calls the plugin's onRender after the Field's onRender
      f.onRender = f.onRender.createSequence(this.onRender); //          We need to completely override the onResize method because of the complexity

      f.onResize = this.onResize; //          Replace the Field's onDestroy method with a sequence that calls the plugin's onDestroy after the Field's onRender

      f.onDestroy = f.onDestroy.createSequence(this.onDestroy);
    },
    onRender: function onRender() {
      //          Do nothing if being rendered by a form layout
      if (this.ownerCt) {
        if (this.ownerCt.layout instanceof Ext.layout.FormLayout) {
          return;
        }
      }

      this.resizeEl = (this.wrap || this.el).wrap({
        cls: 'x-form-element',
        style: Ext.isIE || Ext.isOpera ? 'position:absolute;top:0;left:0;overflow:visible' : ''
      });
      this.positionEl = this.itemCt = this.resizeEl.wrap({
        cls: 'x-form-item '
      });

      if (this.nextSibling()) {
        this.margins = {
          top: 0,
          right: 0,
          bottom: this.positionEl.getMargins('b'),
          left: 0
        };
      }

      this.actionMode = 'itemCt'; //          If our Container is hiding labels, then we're done!

      if (!Ext.isDefined(this.hideLabels)) {
        this.hideLabels = getParentProperty.call(this, "hideLabels");
      }

      if (this.hideLabels) {
        this.resizeEl.setStyle('padding-left', '0px');
        return;
      } //          Collect the info we need to render the label from our Container.


      if (!Ext.isDefined(this.labelSeparator)) {
        this.labelSeparator = getParentProperty.call(this, "labelSeparator");
      }

      if (!Ext.isDefined(this.labelPad)) {
        this.labelPad = getParentProperty.call(this, "labelPad");
      }

      if (!Ext.isDefined(this.labelAlign)) {
        this.labelAlign = getParentProperty.call(this, "labelAlign") || 'left';
      }

      this.itemCt.addClass('x-form-label-' + this.labelAlign);

      if (this.labelAlign == 'top') {
        if (!this.labelWidth) {
          this.labelWidth = 'auto';
        }

        this.resizeEl.setStyle('padding-left', '0px');
      } else {
        if (!Ext.isDefined(this.labelWidth)) {
          this.labelWidth = getParentProperty.call(this, "labelWidth") || 100;
        }

        this.resizeEl.setStyle('padding-left', this.labelWidth + (this.labelPad || 5) + 'px');
        this.labelWidth += 'px';
      }

      this.label = this.itemCt.insertFirst({
        tag: 'label',
        cls: 'x-form-item-label',
        style: {
          width: this.labelWidth
        },
        html: this.fieldLabel + (this.labelSeparator || ':')
      });
    },
    //      private
    //      Ensure the input field is sized to fit in the content area of the resizeEl (to the right of its padding-left)
    //      We perform all necessary sizing here. We do NOT call the current class's onResize because we need this control
    //      we skip that and go up the hierarchy to Ext.form.Field
    onResize: function onResize(w, h) {
      Ext.form.Field.prototype.onResize.apply(this, arguments);
      w -= this.resizeEl.getPadding('l');

      if (this.getTriggerWidth) {
        this.wrap.setWidth(w);
        this.el.setWidth(w - this.getTriggerWidth());
      } else {
        this.el.setWidth(w);
      }

      if (this.el.dom.tagName.toLowerCase() == 'textarea') {
        var h = this.resizeEl.getHeight(true);

        if (!this.hideLabels && this.labelAlign == 'top') {
          h -= this.label.getHeight();
        }

        this.el.setHeight(h);
      }
    },
    //      private
    //      Ensure that we clean up on destroy.
    onDestroy: function onDestroy() {
      this.itemCt.remove();
    }
  };
}();

/***/ }),
/* 1133 */
/***/ (function(module, exports) {

Ext.applyIf(Array.prototype, {
  /**
   * Returns an object with ids of records to delete, to create or to update
   *
   * @param {Array} toCompare Array to compare with
   * @return object An object with sub array properties 'toDelete', 'toCreate' and 'toUpdate'
   */
  getMigration: function getMigration(toCompare) {
    return {
      toDelete: this.diff(toCompare),
      toCreate: toCompare.diff(this),
      toUpdate: this.intersect(toCompare)
    };
  },

  /**
   * Returns an array containing all the entries from this array that are not present in any of the other arrays.
   * 
   * @param {Array} array1
   * @param {Array} [array2]
   * @param {Array} [...]
   */
  diff: function diff() {
    var allItems = [],
        diffs = []; // create an array containing all items of all args

    for (var i = 0; i < arguments.length; i++) {
      allItems = allItems.concat(arguments[i]);
    } // check which item is not present in all args


    Ext.each(this, function (item) {
      if (allItems.indexOf(item) < 0) {
        diffs.push(item);
      }
    }, this);
    return diffs;
  },

  /**
   * simple map fn
   * 
   * @param {Function} fn
   */
  map: function map(fn) {
    var map = [];
    Ext.each(this, function (v, i) {
      map.push(fn.call(this, v, i));
    }, this);
    return map;
  },

  /**
   * returns an array containing all the values of this array that are present in all the arguments.
   * 
   * @param {Array} array1
   * @param {Array} [array2]
   * @param {Array} [...]
   */
  intersect: function intersect() {
    var allItems = [],
        intersect = []; // create an array containing all items of all args

    for (var i = 0; i < arguments.length; i++) {
      allItems = allItems.concat(arguments[i]);
    } // check which item is not present in all args


    Ext.each(this, function (item) {
      if (allItems.indexOf(item) >= 0) {
        intersect.push(item);
      }
    }, this);
    return intersect;
  },

  /**
   * Creates a copy of this Array, filtered to contain only unique values.
   * @return {Array} The new Array containing unique values.
   */
  unique: function unique() {
    return Ext.unique(this);
  }
});
/*
var testArr = ["green", "red", "blue", "red"],
    diff1 = testArr.diff(["green", "yellow", "red"]),
    diff2 = testArr.diff(["green"], "yellow", "red", "blue");

if (diff1.length !== 1) console.error('Failed asserting that diff contains one entry');
if (diff1[0] !== "blue") console.error('Failed asserting that diff is "blue"');
if (diff2.length !== 0) console.error('Failed asserting that diff is empty');
*/

/***/ }),
/* 1134 */
/***/ (function(module, exports) {

Ext.applyIf(Date.prototype, {
  /**
   * get time part in milliseconds
   * @returns {number}
   */
  getTimePart: function getTimePart() {
    return 1000 * (3600 * this.getHours() + 60 * this.getMinutes() + this.getSeconds());
  }
});
Ext.applyIf(Date, {
  /**
   * returns date of timepart (starting at begin of time)
   *
   * @returns {Date}
   */
  parseTimePart: function parseTimePart(timeString, format) {
    var date = Date.parseDate(timeString, format),
        today = new Date().clearTime();
    return new Date(date - today);
  }
});

/***/ }),
/* 1135 */
/***/ (function(module, exports) {

Ext.ns('Ext.ux');
/**
 * logging extension (only to console atm.)
 * 
 * NOTE: we extend the console object here so the console writer preserves 
 *       line number and files in its logging output!
 *       
 * @namespace   Ext.ux.log
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Ext.ux.log = window.console || {};
Ext.apply(Ext.ux.log, {
  /**
   * @cfg {Number} prio (defaults to 7)
   */
  PRIO: 7,

  /**
   * possible log levels
   * @type Object
   */
  priorities: {
    EMERG: 0,
    // Emergency: system is unusable
    ALERT: 1,
    // Alert: action must be taken immediately
    CRIT: 2,
    // Critical: critical conditions
    ERR: 3,
    // Error: error conditions
    ERROR: 3,
    // Error: error conditions
    WARN: 4,
    // Warning: warning conditions
    NOTICE: 5,
    // Notice: normal but significant condition
    INFO: 6,
    // Informational: informational messages
    DEBUG: 7,
    // Debug: debug messages
    TRACE: 8 // Debug: debug messages

  },
  // only console writer atm.
  prioLogFnMap: {
    EMERG: console.error,
    ALERT: console.error,
    CRIT: console.error,
    ERR: console.error,
    ERROR: console.error,
    WARN: console.warn,
    NOTICE: console.info,
    INFO: console.info,
    DEBUG: console.log,
    TRACE: console.log
  },

  /**
   * returns current logging priority
   * 
   * @return {}
   */
  getPrio: function getPrio() {
    return this.PRIO;
  },

  /**
   * set logging priority
   * 
   * @namespace Ext.ux.log
   * @param {Number} prio
   */
  setPrio: function setPrio(prio) {
    this.PRIO = Ext.LOGLEVEL = prio;

    for (var name in this.priorities) {
      this[name] = this[name.toLowerCase()] = prio >= this.priorities[name] ? this.prioLogFnMap[name] : Ext.emptyFn;
    }
  }
}); // init Ext.ux.log

Ext.onReady(function () {
  Ext.ux.log.setPrio(Ext.LOGLEVEL || 8);
  Ext.ux.log.debug('logger initialized');
});

/***/ }),
/* 1136 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.ConnectionStatus
 * @constructor
 */

Ext.ux.ConnectionStatus = function (config) {
  Ext.apply(this, config);
  Ext.ux.ConnectionStatus.superclass.constructor.call(this);
};

Ext.extend(Ext.ux.ConnectionStatus, Ext.Button, {
  /**
   * @cfg {boolean} showIcon
   */
  showIcon: true,

  /**
   * @property {String}
   */
  status: 'unknown',

  /**
   * @private
   */
  iconCls: 'x-ux-connectionstatus-unknown',

  /**
   * @property {bool} Browser supports online offline detection
   */
  isSuppoeted: null,
  cls: 'x-ux-connectionstatus',

  /**
   * @private
   */
  handler: function handler() {
    if (this.isSuppoeted) {
      this.toggleStatus();
    }
  },
  initComponent: function initComponent() {
    Ext.ux.ConnectionStatus.superclass.initComponent.call(this);
    this.onlineText = this.wrapText(i18n._('online'));
    this.offlineText = this.wrapText(i18n._('offline'));
    this.unknownText = this.wrapText(i18n._('unknown'));

    if (!this.showText) {
      this.setText = this.setTooltip;
    } // M$ IE has not online/offline events yet


    if (Ext.isIE6 || Ext.isIE7 || !window.navigator || window.navigator.onLine === undefined) {
      this.setStatus('unknown');
      this.isSupported = false;
    } else {
      this.setStatus(window.navigator.onLine ? 'online' : 'offline');
      this.isSupported = true;
    } //if (Ext.isGecko3) {


    Ext.getBody().on('offline', function () {
      this.setStatus('offline', true);
    }, this);
    Ext.getBody().on('online', function () {
      this.setStatus('online', true);
    }, this); //}
  },
  wrapText: function wrapText(text) {
    return this.showText ? '(' + text + ')' : text;
  },

  /**
   * toggles online status
   */
  toggleStatus: function toggleStatus() {
    this.setStatus(this.status == 'online' ? 'offline' : 'online');
  },
  setIconClass: function setIconClass(iconCls) {
    this.supr().setIconClass.call(this, this.showIcon ? iconCls : '');
  },

  /**
   * sets online status
   */
  setStatus: function setStatus(status) {
    switch (status) {
      case 'online':
        this.status = status;
        this.setText(this.onlineText);
        this.setIconClass('x-ux-connectionstatus-online');
        break;

      case 'offline':
        this.status = status;
        this.setText(this.offlineText);
        this.setIconClass('x-ux-connectionstatus-offline');
        break;

      case 'unknown':
        this.status = status;
        this.setText(this.unknownText);
        this.setIconClass('x-ux-connectionstatus-unknown'); // as HTML implementation status is verry poor atm. don't bother the user with this state

        this.hide();
        break;

      default:
        console.error('no such status:"' + status + '"');
        break;
    }
  }
});

/***/ }),
/* 1137 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     MIT, BSD, and GPL
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.direct');
/**
 * @namespace   Ext.ux.direct
 * @class       Ext.ux.direct.JsonRpcProvider
 * @extends     Ext.direct.RemotingProvider
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * Ext.Direct provider for seamless integration with JSON RPC servers
 * 
 *  Ext.Direct.addProvider(Ext.apply(Ext.app.JSONRPC_API, {
        'type'     : 'jsonrpcprovider',
        'url'      : Ext.app.JSONRPC_API
    }));
 * 
 */

Ext.ux.direct.JsonRpcProvider = Ext.extend(Ext.direct.RemotingProvider, {
  /**
   * @cfg {Boolean} paramsAsHash
   */
  //paramsAsHash: true,

  /**
   * @cfg {Boolean} useNamedParams
   */
  useNamedParams: false,

  /**
   * @cfg {Number} timeout
   */
  timeout: 60000,
  // private
  initAPI: function initAPI() {
    for (var method in this.services) {
      var mparts = method.split('.');
      var cls = this.namespace[mparts[0]] || (this.namespace[mparts[0]] = {});
      cls[mparts[1]] = this.createMethod(mparts[0], Ext.apply(this.services[method], {
        name: mparts[1],
        len: this.services[method].parameters.length
      }));
    }
  },
  // private
  doCall: function doCall(c, m, args) {
    const me = this;
    var promise = new Promise(function (fulfill, reject) {
      const paramArray = {};
      const method = "".concat(c, ".").concat(m.name);

      _.each(_.map(m.parameters, 'name'), (paramName, i) => {
        paramArray[paramName] = args[i];
      });

      var cb = args[m.len];

      if (!Ext.isFunction(cb)) {
        cb = Ext.emptyFn;
        args.push(cb);
        args.push(window);
      }

      args[m.len] = cb.createSequence(function (result, e) {
        if (e.status === 'failure') {
          reject(e);
        } else if (e.type === 'exception') {
          const errorData = e.error.data; //check for status code 650 (generic confirm)

          if (errorData.code === 650) {
            if (errorData.info) {
              errorData.message += '<br />' + errorData.info;
            }

            Ext.Msg.confirm(errorData.title, errorData.message, async button => {
              if (button === 'no') {
                fulfill(e);
              }

              if (button === 'yes') {
                const request = {
                  params: paramArray,
                  method: method
                };
                paramArray['method'] = method;
                Ext.Ajax.request({
                  headers: {
                    'X-TINE20-REQUEST-CONTEXT-CONFIRM': true
                  },
                  params: paramArray,
                  success: function success(_result, _request) {
                    const response = Ext.util.JSON.decode(_result.responseText);
                    fulfill(response);
                  },
                  failure: function failure(exception) {
                    if (!exception.code && exception.responseText) {
                      // we need to decode the exception first
                      const response = Ext.util.JSON.decode(exception.responseText);
                      exception = response.data;
                      exception.request = Ext.util.JSON.encode(request);
                    }

                    Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
                  }
                });
              }
            });
          } else {
            reject(e.error);
          }
        } else {
          fulfill(result);
        }
      });
    }); // support named/hashed parameters e.g. from DirectProxy

    if (args[args.length - 1].paramsAsHash) {
      var o = args.shift();

      for (var i = 0; i < m.parameters.length; i++) {
        args.splice(i, 0, o[m.parameters[i].name]);
      }
    }

    Ext.ux.direct.JsonRpcProvider.superclass.doCall.call(this, c, m, args);
    return promise;
  },
  // private
  getCallData: function getCallData(t) {
    var method = t.action + '.' + t.method,
        m = t.provider.services[method],
        data = t.data || [];

    if (this.useNamedParams) {
      var data = {};
      Ext.each(m.parameters, function (param, i) {
        data[param['name']] = t.data[i];
        /* NOTE: Ext.Direct and the automatically creaeted DirectFn's don't support optional params, cause 
         * callback and scope are expected on fixed positions!
         
        var value = typeof t.data[i] !== 'function' ? t.data[i] : undefined;
        
        if (value === undefined && ! param.optional) {
            value = param['default'];
        }
        
        if (value !== undefined) {
            data[param['name']] = value;
        }
        */
      }, this);
    }

    return {
      jsonrpc: '2.0',
      method: method,
      params: data,
      id: t.tid
    };
  },
  // private
  createMethod: function createMethod(c, m) {
    var f;

    if (!m.formHandler) {
      f = function () {
        return this.doCall(c, m, Array.prototype.slice.call(arguments, 0));
      }.createDelegate(this);
    } else {
      f = function (form, callback, scope) {
        return this.doForm(c, m, form, callback, scope);
      }.createDelegate(this);
    }

    f.directCfg = {
      action: c,
      method: m
    };
    return f;
  },
  // private
  onData: function onData(opt, success, xhr) {
    var rs = [].concat(Ext.decode(xhr.responseText));
    xhr.responseText = [];
    Ext.each(rs, function (rpcresponse, i) {
      xhr.responseText[i] = {
        type: rpcresponse.hasOwnProperty('result') ? 'rpc' : 'exception',
        result: rpcresponse.result,
        tid: rpcresponse.id,
        error: rpcresponse.error
      };

      if (xhr.responseText[i].type === 'rpc') {
        delete xhr.responseText.error;
      }
    });
    return Ext.ux.direct.JsonRpcProvider.superclass.onData.apply(this, arguments);
  }
});
Ext.Direct.PROVIDERS['jsonrpcprovider'] = Ext.ux.direct.JsonRpcProvider;

/***/ }),
/* 1138 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux');

Ext.ux.DatePickerWeekPlugin = function (config) {
  Ext.apply(this, config || {});
};

Ext.ux.DatePickerWeekPlugin.prototype = {
  /**
   * @cfg {String} weekHeaderString
   */
  weekHeaderString: 'WK',
  init: function init(picker) {
    picker.onRender = picker.onRender.createSequence(this.onRender, picker);
    picker.update = picker.update.createSequence(this.update, picker);
    picker.handleDateClick = picker.handleDateClick.createSequence(this.handleDateClick, picker);
    picker.showMonthPicker = picker.showMonthPicker.createInterceptor(this.inspectMonthPickerClick, picker);
    picker.weekHeaderString = this.weekHeaderString;
    picker.getRowEl = this.getRowEl.createDelegate(picker);
    picker.selectWeek = this.selectWeek.createDelegate(picker);
    picker.clearSelection = this.clearSelection.createDelegate(picker);
    picker.onWkCellOver = this.onWkCellOver.createDelegate(picker);
    picker.onWkCellOut = this.onWkCellOut.createDelegate(picker);
  },
  onRender: function onRender() {
    var innerCal = Ext.DomQuery.selectNode('table[class=x-date-inner]', this.getEl().dom);
    var trs = Ext.DomQuery.select('tr', innerCal);

    for (var el, i = 0; i < trs.length; i++) {
      el = Ext.DomHelper.insertFirst(trs[i], i == 0 ? '<th class="x-date-picker-wk-hd">' + this.weekHeaderString + '</th>' : '<td class="x-date-picker-wk"><a class="x-date-date" tabindex="1" hidefocus="on" href="#"><em><span>' + i + '</span></em></td>');
      Ext.get(el).addListener({
        scope: this,
        mouseover: this.onWkCellOver,
        mouseout: this.onWkCellOut
      });
    } // update again;


    this.update(this.value); // shit, datePicker is not on BaxComponent ;-(
    //this.picker.getEl().container.on('resize', function() {
    //    console.log(this.picker.getEl());
    //}, this);
  },
  onWkCellOver: function onWkCellOver(e, t) {
    var tr = e.getTarget('tr', 10, true);
    tr.addClass('x-date-picker-wk-wkrowover');
  },
  onWkCellOut: function onWkCellOut(e, t) {
    var tr = e.getTarget('tr', 10, true);
    tr.removeClass('x-date-picker-wk-wkrowover');
  },
  update: function update(date, forceRefresh, weekNumber) {
    var firstOfMonth = date.getFirstDateOfMonth(),
        startingPos = firstOfMonth.getDay() - this.startDay;

    if (startingPos < 0) {
      startingPos += 7;
    } // NOTE "+1" to ensure ISO week!


    var startDate = firstOfMonth.add(Date.DAY, -1 * startingPos + 1); // in some rare cases render might be too slow. But luckily we can ignore this because this is also rendered on click

    if (this.rendered == false) {
      return;
    }

    var wkCells = Ext.DomQuery.select('td[class=x-date-picker-wk]', this.getEl().dom);

    for (var i = 0, id; i < wkCells.length; i++) {
      id = Ext.id() + ':' + startDate.add(Date.DAY, i * 7).format('Y-m-d');
      wkCells[i].firstChild.firstChild.innerHTML = '<span id="' + id + '">' + startDate.add(Date.DAY, i * 7).getWeekOfYear() + '</span>';
    }

    if (weekNumber) {
      this.clearSelection();

      if (!Ext.isArray(weekNumber)) {
        weekNumber = [weekNumber];
      }

      for (var i = 0, row; i < weekNumber.length; i++) {
        row = this.getRowEl(weekNumber[i]);
        this.selectWeek(row);
      }
    }
  },
  handleDateClick: function handleDateClick(e) {
    target = e.getTarget('td[class=x-date-picker-wk]');

    if (target) {
      var row = target.parentNode;
      var weekNumber = target.firstChild.firstChild.firstChild.innerHTML;

      if (Ext.DomQuery.select('td[class=x-date-prevday]', row).length > 3) {
        this.showPrevMonth();
      } else if (Ext.DomQuery.select('td[class=x-date-nextday]', row).length > 4) {
        this.showNextMonth();
      } // get row again


      row = this.getRowEl(weekNumber); // set new date value

      var value = Date.parseDate(row.firstChild.firstChild.firstChild.firstChild.id.split(':')[1], 'Y-m-d');
      this.setValue(value); // set selection

      this.clearSelection();
      this.selectWeek(row);
      this.fireEvent("select", this, this.value, weekNumber);
    }
  },
  getRowEl: function getRowEl(weekNumber) {
    var wktds = Ext.DomQuery.select('td[class=x-date-picker-wk]', this.getEl().dom);

    for (var i = 0; i < wktds.length; i++) {
      if (wktds[i].firstChild.firstChild.firstChild.innerHTML == weekNumber) {
        var rowEl = wktds[i].parentNode;
        break;
      }
    }

    return rowEl;
  },
  clearSelection: function clearSelection() {
    var innerCal = Ext.DomQuery.selectNode('table[class=x-date-inner]', this.getEl().dom);
    var dates = Ext.DomQuery.select('td', innerCal);

    for (var i = 0; i < dates.length; i++) {
      Ext.fly(dates[i]).removeClass('x-date-selected');
    }
  },

  /**
   * inspects month picker onClick event method
   * return false to cancel original onClick handler
   */
  inspectMonthPickerClick: Ext.emptyFn,
  selectWeek: function selectWeek(rowEl) {
    if (rowEl) {
      // set new selection
      for (var j = 1; j < rowEl.childNodes.length; j++) {
        Ext.fly(rowEl.childNodes[j]).addClass('x-date-selected');
      }
    }
  }
};

/***/ }),
/* 1139 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     New BSD License
 * @author      www.steinarmyhre.com
 *
 */
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.ButtonLockedToggle & Ext.ux.tbButtonLockedToggle
 * @extends     Ext.Button
 * @description
 * The normal button, when enableToggle is used and toggleGroup is set correctly, still allows the user
 * to toggle off the toggled button by pressing on it. This class overrides the toggle-method so that
 * the toggled button is impossible to 'untoggle' other than programmatically or as a reaction
 * to any of the other buttons in the group getting toggled on.
 *
 * Toggle is by the way a very strange word when you repeat it enough.
 *
 * @author www.steinarmyhre.com
 * @constructor
 * Identical to Ext.Button and/or Ext.Toolbar.Button except that enableToggle is true by default.
 * @param (Object/Array) config A config object
 */

Ext.ux.ButtonLockedToggle = Ext.extend(Ext.Button, {
  enableToggle: true,
  toggle: function toggle(state) {
    if (state === undefined && this.pressed) {
      return;
    }

    state = state === undefined ? !this.pressed : state;

    if (state != this.pressed) {
      if (state) {
        if (this.el) this.el.addClass("x-btn-pressed");
        this.pressed = true;
        this.fireEvent("toggle", this, true);
      } else {
        if (this.el) this.el.removeClass("x-btn-pressed");
        this.pressed = false;
        this.fireEvent("toggle", this, false);
      }

      if (this.toggleHandler) {
        this.toggleHandler.call(this.scope || this, this, state);
      }
    }
  }
}); //Ext.ux.tbButtonLockedToggle = Ext.extend(Ext.Toolbar.Button, Ext.ux.ButtonLockedToggle);

Ext.reg('btnlockedtoggle', Ext.ux.ButtonLockedToggle);
Ext.reg('tbbtnlockedtoggle', Ext.ux.ButtonLockedToggle); //Ext.reg('tbbtnlockedtoggle', Ext.ux.tbButtonLockedToggle);

/***/ }),
/* 1140 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/**
 * increase depth of cell selector depth for event delegation (defaults to 4) 
 */
if (Ext.grid.GridView.prototype.cellSelectorDepth < 6) {
  Ext.grid.GridView.prototype.cellSelectorDepth = 6;
}

Ext.ns('Ext.ux');
/**
 * Percentage select combo box
 * 
 * @namespace   Ext.ux
 * @class       Ext.ux.PercentCombo
 * @extends     Ext.form.ComboBox
 */

Ext.ux.PercentCombo = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {bool} autoExpand Autoexpand comboBox on focus.
   */
  autoExpand: false,

  /**
   * @cfg {bool} blurOnSelect blurs combobox when item gets selected
   */
  blurOnSelect: false,
  displayField: 'value',
  valueField: 'key',
  mode: 'local',
  triggerAction: 'all',
  emptyText: 'percent ...',
  lazyInit: false,
  forceSelection: true,
  itemSelector: 'div.search-item',
  editable: false,
  //private
  initComponent: function initComponent() {
    Ext.ux.PercentCombo.superclass.initComponent.call(this); // allways set a default

    if (!this.value) {
      this.value = 0;
    }

    this.initTemplate();
    this.store = new Ext.data.SimpleStore({
      fields: ['key', 'value'],
      data: [['0', '0%'], ['10', '10%'], ['20', '20%'], ['30', '30%'], ['40', '40%'], ['50', '50%'], ['60', '60%'], ['70', '70%'], ['80', '80%'], ['90', '90%'], ['100', '100%']]
    });

    if (this.autoExpand) {
      this.lazyInit = false;
      this.on('focus', function () {
        this.selectByValue(this.getValue());
        this.onTriggerClick();
      });
    }

    if (this.blurOnSelect) {
      this.on('select', function () {
        this.fireEvent('blur', this);
      }, this);
    }
  },
  setValue: function setValue(value) {
    value = value ? value : 0;
    Ext.ux.PercentCombo.superclass.setValue.call(this, value);
  },

  /**
   * init template
   * @private
   */
  initTemplate: function initTemplate() {
    if (!this.tpl) {
      this.tpl = new Ext.XTemplate('<tpl for=".">', '<div class="search-item">', '<div class="x-progress-wrap PercentRenderer">', '<div class="x-progress-inner PercentRenderer">', '<div class="x-progress-bar PercentRenderer {[this.getColorClass(values)]}" style="width:{[this.getValue(values)]}%">', '<div class="PercentRendererText PercentRenderer">', '<div>{[this.getValue(values)]}%</div>', '</div>', '</div>', '</div>', '</div>', '</div>', '</tpl>', {
        getValue: function getValue(values) {
          return values.key;
        },
        getColorClass: function getColorClass(values) {
          return 'PercentRenderer-progress-bar' + values.key;
        }
      });
    }
  }
});
Ext.reg('extuxpercentcombo', Ext.ux.PercentCombo);
/**
 * Renders a percentage value to a percentage bar
 * @constructor
 */

Ext.ux.PercentRenderer = function (percent) {
  if (!Ext.ux.PercentRenderer.template) {
    Ext.ux.PercentRenderer.template = new Ext.XTemplate('<div class="x-progress-wrap PercentRenderer">', '<div class="x-progress-inner PercentRenderer">', '<div class="x-progress-bar PercentRenderer {colorclass}" style="width:{percent}%">', '<div class="PercentRendererText PercentRenderer">', '<div>{percent}%</div>', '</div>', '</div>', '<div class="x-progress-text x-progress-text-back PercentRenderer">', '<div>&#160;</div>', '</div>', '</div>', '</div>').compile();
  } // this will enable a color scheme for each percentage on the progress bar


  var colorClass = "PercentRenderer-progress-bar";
  colorClass += Math.round(percent / 10) + "0";
  return Ext.ux.PercentRenderer.template.apply({
    percent: percent,
    colorclass: colorClass
  });
};
/**
 * Renders a percentage value to a percentage bar / uploadrow
 * @constructor
 */


Ext.ux.PercentRendererWithName = function (value, metadata, record) {
  var metaStyle = '',
      dataSafeEnabled = !!Tine.Tinebase.areaLocks.getLocks(Tine.Tinebase.areaLocks.dataSafeAreaName).length;

  if (record.fileRecord) {
    record = record.fileRecord;
  }

  metadata.css = 'x-grid-mimeicon';

  if (record.get('type') === 'folder') {
    metadata.css += ' mime-icon-folder';

    if (dataSafeEnabled && !!record.get('pin_protected_node')) {
      metadata.css += ' x-type-data-safe';
    }
  } else {
    metadata.css += ' mime-icon-file';
    var contenttype = record.get('contenttype');

    if (contenttype) {
      metadata.css += ' ' + Tine.Tinebase.common.getMimeIconCls(contenttype);
    }
  }

  if (Tine.Tinebase.common.hasRight('run', 'Filemanager')) {
    metadata.css += ' ' + Tine.Filemanager.Model.Node.getStyles(record).join(' ');
  } // all browsers should support chunk upload

  /*
  if (!Ext.ux.file.Upload.isHtml5ChunkedUpload()) {
      var fileName = value;
      if (typeof value == 'object') {
          fileName = value.name;
      } 
  
      if(record.get('status') == 'uploading') {
          metadata.css += ' x-tinebase-uploadrow';
      }
      
      return Ext.util.Format.htmlEncode(fileName);
  }
  */


  if (!Ext.ux.PercentRendererWithName.template) {
    Ext.ux.PercentRendererWithName.template = new Ext.XTemplate('<div class="x-progress-wrap PercentRenderer" style="{display}">', '<div class="x-progress-inner PercentRenderer">', '<div class="x-progress-bar PercentRenderer" style="width:{percent}%;{additionalStyle}">', '<div class="PercentRendererText PercentRenderer">', '{fileName}', '</div>', '</div>', '<div class="x-progress-text x-progress-text-back PercentRenderer">', '<div>&#160;</div>', '</div>', '</div>', '</div>').compile();
  }

  if (value == undefined) {
    return '';
  }

  var fileName = value;

  if (typeof value == 'object') {
    fileName = value.name;
  }

  fileName = Ext.util.Format.htmlEncode(fileName);

  if (_.get(record, 'data.type', _.get(record, 'type')) === 'link') {
    fileName = '<div class="mime-icon-overlay mime-icon-link"></div>' + fileName;
  }

  if (record.get('is_quarantined') == '1') {
    const warningText = i18n._('This file might potentially harm your computer. Therefore it got quarantined and cannot be edited or downloaded.');

    fileName = '<div class="mime-icon-overlay x-tinebase-virus" ext:qtip="' + Tine.Tinebase.common.doubleEncode(warningText) + '"></div>' + fileName + ' (' + i18n._('quarantined') + ')';
  }

  if (_.get(record, 'data.type', _.get(record, 'type')) === 'link') {
    fileName = '<div class="mime-icon-overlay mime-icon-link"></div>' + fileName;
  } // check contenttype and get info , update ui based on it


  let percent = -1;

  if (String(record.get('contenttype')).match(/^vnd\.adobe\.partial-upload.*/)) {
    const progress = parseInt(_.last(_.split(record.get('contenttype'), ';')).replace('progress=', ''));

    if (progress > -1) {
      percent = progress;
    }
  } else {
    percent = record.get('progress');
  }

  var additionalStyle = '';

  if (record.get('status') === 'paused' && percent < 100) {
    fileName = i18n._('(paused)') + '&#160;&#160;' + fileName;
    additionalStyle = 'background-image: url(\'styles/images/tine20/progress/progress-bg-y.gif\') !important;';
  }

  var display = 'width:0px';

  if (percent > -1 && percent < 100) {
    display = '';
    var renderedField = Ext.ux.PercentRendererWithName.template.apply({
      percent: percent,
      display: display,
      fileName: fileName,
      additionalStyle: additionalStyle
    });
    return renderedField;
  } else {
    return fileName;
  }
};

/***/ }),
/* 1141 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2012-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.namespace('Tine.Tinebase');

__webpack_require__(608);

__webpack_require__(609);
/**
 * Tinebase Application Starter
 * 
 * @namespace   Tine.Tinebase
 * @function    Tine.Tinebase.ApplicationStarter
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 */


Tine.Tinebase.ApplicationStarter = {};
Ext.apply(Tine.Tinebase.ApplicationStarter, {
  /**
   * the applictions the user has access to
   * @type
   */
  userApplications: null,

  /**
   * type mapping
   * @type {Object}
   */
  types: {
    'date': 'date',
    'datetime': 'date',
    'datetime_separated_date': 'date',
    'datetime_separated_time': 'date',
    'time': 'date',
    'string': 'string',
    'text': 'string',
    'boolean': 'bool',
    'integer': 'int',
    'float': 'float'
  },
  __applicationStarterInitialized: new Promise(resolve => {
    Tine.Tinebase.ApplicationStarter.__applicationStarterInitializedResolve = resolve;
  }),

  /**
   * initializes the starter
   */
  init: function init() {
    // Wait until appmgr is initialized
    if (!Tine.Tinebase.hasOwnProperty('appMgr')) {
      this.init.defer(100, this);
      return;
    }

    Tine.log.info('ApplicationStarter::init');

    if (!this.userApplications || this.userApplications.length == 0) {
      this.userApplications = Tine.Tinebase.registry.get('userApplications');
      this.createStructure(true);

      Tine.Tinebase.ApplicationStarter.__applicationStarterInitializedResolve();
    }
  },
  isInitialised: function isInitialised() {
    return Tine.Tinebase.ApplicationStarter.__applicationStarterInitialized;
  },

  /**
   * returns the field
   * 
   * @param {Object} fieldDefinition
   * @return {Object}
   */
  getField: function getField(fieldDefinition, key) {
    // default type is auto
    var field = {
      name: key,
      fieldDefinition: fieldDefinition
    };

    if (fieldDefinition.type) {
      // add pre defined type
      field.type = this.types[fieldDefinition.type];

      switch (fieldDefinition.type) {
        case 'datetime_separated_date':
        case 'datetime':
        case 'date':
          field.dateFormat = Date.patterns.ISO8601Long;
          break;

        case 'time':
          field.dateFormat = Date.patterns.ISO8601Time;
          break;

        case 'record':
        case 'records':
          field.type = fieldDefinition.config.appName + '.' + fieldDefinition.config.modelName;

          field.getRecordClass = function () {
            return Tine.Tinebase.data.RecordMgr.get(field.type);
          };

          break;
      } // allow overwriting date pattern in model


      if (fieldDefinition.hasOwnProperty('dateFormat')) {
        field.dateFormat = fieldDefinition.dateFormat;
      }

      if (fieldDefinition.hasOwnProperty('label')) {
        field.label = fieldDefinition.label;
      }
    } // TODO: create field registry, add fields here


    return field;
  },

  /**
   * used in getFilter for mapping types to filter
   * 
   * @type 
   */
  filterMap: function filterMap(type, fieldconfig, filter, filterconfig, appName, modelName, modelConfig) {
    switch (type) {
      case 'string':
      case 'text':
        break;

      case 'attachments':
        filter.label = window.i18n._('Attachment');

      case 'fulltext':
        filter.valueType = 'fulltext';
        break;

      case 'user':
        filter.valueType = 'user';
        break;

      case 'boolean':
        filter.valueType = 'bool';
        filter.defaultValue = false;
        break;

      case 'record':
        filterconfig.options.modelName = filterconfig.options.modelName.replace(/_/, '');
        var foreignApp = filterconfig.options.appName;
        var foreignModel = filterconfig.options.modelName; // create generic foreign id filter

        var filterclass = Ext.extend(Tine.widgets.grid.ForeignRecordFilter, {
          foreignRecordClass: foreignApp + '.' + foreignModel,
          linkType: 'foreignId',
          ownField: fieldconfig.key,
          label: filter.label
        }); // register foreign id field as appName.modelName.fieldKey

        var fc = appName + '.' + modelName + '.' + fieldconfig.key;
        Tine.widgets.grid.FilterToolbar.FILTERS[fc] = filterclass;
        filter = {
          filtertype: fc
        };
        break;

      case 'relation':
        _.assign(filter, {
          filtertype: 'foreignrecord',
          valueType: 'relation',
          app: _.get(filterconfig, 'options.appName', appName),
          ownRecordClass: _.get(filterconfig, 'options.own_model'),
          foreignRecordClass: _.get(filterconfig, 'options.related_model')
        });

        break;

      case 'tag':
        filter = {
          filtertype: 'tinebase.tag',
          app: appName
        };
        break;

      case 'container':
        var applicationName = filterconfig.appName ? filterconfig.appName : appName;
        var modelName = filterconfig.modelName ? filterconfig.modelName : modelName;
        filter = {
          filtertype: 'tine.widget.container.filtermodel',
          app: applicationName,
          recordClass: applicationName + '.' + modelName,
          field: fieldconfig.key,
          label: fieldconfig.label,
          callingApp: appName
        };
        break;

      case 'keyfield':
        filter.filtertype = 'tine.widget.keyfield.filter';
        filter.app = {
          name: _.get(fieldconfig, 'owningApp', appName)
        };
        filter.keyfieldName = fieldconfig.name;
        break;

      case 'date':
      case 'datetime':
      case 'datetime_separated_date':
        filter.valueType = 'date';
        break;

      case 'time':
        filter.valueType = 'time';
        break;

      case 'money':
        filter.valueType = 'money';
        break;

      case 'float':
      case 'integer':
        filter.valueType = 'number';
        break;
    }

    return filter;
  },

  /**
   * returns filter
   * 
   * @param {String} fieldKey
   * @param {Object} filterconfig
   * @param {Object} fieldconfig
   * @return {Object}
   */
  getFilter: function getFilter(fieldKey, filterconfig, modelConfig) {
    // take field label if no filterlabel is defined
    // TODO Refactor: tag and tags see ticket 0008944
    // TODO Remove this ugly hack!
    if (fieldKey == 'tag') {
      fieldKey = 'tags';
    }

    var fieldconfig = modelConfig.fields[fieldKey];

    if (fieldconfig && fieldconfig.type === 'virtual') {
      fieldconfig = fieldconfig.config || {};
    }

    const appName = modelConfig.appName;
    const modelName = modelConfig.modelName;
    const owningAppName = _.get(fieldconfig, 'owningApp') || appName;
    const app = Tine.Tinebase.appMgr.get(owningAppName);

    if (!app) {
      Tine.log.error('Application ' + owningAppName + ' not found!');
      return null;
    } // check right on foreign app


    if (fieldconfig && (fieldconfig.type == 'record' || fieldconfig.type == 'records')) {
      var opt = fieldconfig.config;

      if (opt && !opt.doNotCheckModuleRight && !Tine.Tinebase.common.hasRight('view', opt.appName, _.lowerCase(opt.modelName))) {
        return null;
      }
    }

    var fieldTypeKey = fieldconfig && fieldconfig.type ? fieldconfig.type : filterconfig && filterconfig.type ? filterconfig.type : 'default',
        label = filterconfig && filterconfig.hasOwnProperty('label') ? filterconfig.label : fieldconfig && fieldconfig.hasOwnProperty('label') ? fieldconfig.label : null,
        globalI18n = filterconfig && filterconfig.hasOwnProperty('useGlobalTranslation') || fieldconfig && fieldconfig.hasOwnProperty('useGlobalTranslation'),
        i18n = globalI18n ? window.i18n : app.i18n;

    if (!label || _.get(fieldconfig, 'disabled')) {
      return null;
    } // prepare filter


    var filter = {
      label: i18n._hidden(label),
      field: fieldKey,
      gender: i18n._hidden('GENDER_' + label),
      specialType: fieldconfig ? fieldconfig.specialType : null
    };

    if (filterconfig) {
      if (filterconfig.hasOwnProperty('options') && (filterconfig.options.hasOwnProperty('jsFilterType') || filterconfig.options.hasOwnProperty('jsFilterValueType'))) {
        Tine.log.error('jsFilterType and jsFilterValueType are deprecated. Use jsConfig.<property> instead.');
      } // if js filter is defined in filterconfig.options, take this and return


      if (filterconfig.hasOwnProperty('jsConfig')) {
        Ext.apply(filter, filterconfig.jsConfig);
        return filter;
      }

      try {
        filter = this.filterMap(fieldTypeKey, fieldconfig, filter, filterconfig, appName, modelName, modelConfig);
      } catch (e) {
        var keys = filterconfig.filter.split('_'),
            filterkey = keys[0].toLowerCase() + '.' + keys[2].toLowerCase();
        filterkey = filterkey.replace(/filter/g, '');

        if (Tine.widgets.grid.FilterToolbar.FILTERS[filterkey]) {
          filter = {
            filtertype: filterkey
          };
        } else {
          // set to null if no filter could be found
          filter = null;
        }
      }
    }

    return filter;
  },

  /**
   * if application starter should be used, here the js contents are (pre-)created
   */
  createStructure: function createStructure(initial) {
    var start = new Date();
    Ext.each(this.userApplications, function (app) {
      var appName = app.name;
      Tine.log.info('ApplicationStarter::createStructure for app ' + appName);
      Ext.namespace('Tine.' + appName);

      if (!Tine[appName].AdminPanel) {
        Tine[appName].AdminPanel = Ext.extend(Ext.TabPanel, {
          border: false,
          activeTab: 0,
          appName: appName,
          initComponent: function initComponent() {
            this.app = Tine.Tinebase.appMgr.get(this.appName);
            this.items = [new Tine.Admin.config.GridPanel({
              configApp: this.app
            })];
            this.supr().initComponent.call(this);
          }
        });

        Tine[appName].AdminPanel.openWindow = function (config) {
          return Tine.WindowFactory.getWindow({
            width: 600,
            height: 470,
            name: 'Tine.' + appName + '.AdminPanel',
            contentPanelConstructor: 'Tine.' + appName + '.AdminPanel',
            contentPanelConstructorConfig: config
          });
        };
      }

      var models = Tine[appName].registry ? Tine[appName].registry.get('models') : null;

      if (models) {
        Tine[appName].isAuto = true;
        var contentTypes = []; // create translation

        Tine[appName].i18n = new Locale.Gettext();
        Tine[appName].i18n.textdomain(appName); // iterate models of this app

        Ext.iterate(models, function (modelName, modelConfig) {
          // create main screen
          if (!Tine[appName].hasOwnProperty('MainScreen')) {
            Tine[appName].MainScreen = Ext.extend(Tine.widgets.MainScreen, {
              app: appName,
              contentTypes: contentTypes,
              activeContentType: modelConfig.createModule ? modelName : null
            });
          }

          var containerProperty = modelConfig.hasOwnProperty('containerProperty') ? modelConfig.containerProperty : null; // NOTE: we need to preserve original modelName.
          //       - otherwise we can't referece
          //       - otherwise we can't compute phpClassName
          // modelName = modelName.replace(/_/, '');

          Ext.namespace('Tine.' + appName, 'Tine.' + appName + '.Model');
          var modelArrayName = modelName + 'Array',
              modelArray = [];
          Tine.log.info('ApplicationStarter::createStructure for model ' + modelName);

          if (modelConfig.createModule) {
            contentTypes.push(modelConfig);
          } // iterate record fields


          Ext.each(modelConfig.fieldKeys, function (key) {
            var fieldDefinition = modelConfig.fields[key];

            if (fieldDefinition.type === 'virtual') {
              fieldDefinition = fieldDefinition.config || {};
            } // add field to model array


            modelArray.push(this.getField(fieldDefinition, key));
          }, this); // iterate virtual record fields

          if (modelConfig.virtualFields && modelConfig.virtualFields.length) {
            Ext.each(modelConfig.virtualFields, function (field) {
              modelArray.push(this.getField(field, field.key));
            }, this);
          }

          Tine[appName].Model[modelArrayName] = modelArray; // create model

          if (!Tine[appName].Model.hasOwnProperty(modelName)) {
            Tine[appName].Model[modelName] = Tine.Tinebase.data.Record.create(Tine[appName].Model[modelArrayName], Ext.copyTo({
              modelConfiguration: modelConfig
            }, modelConfig, 'idProperty,defaultFilter,appName,modelName,recordName,recordsName,titleProperty,' + 'containerProperty,containerName,containersName,group,copyOmitFields,copyNoAppendTitle')); // called from legacy code - but all filters should come from registy (see below)

            Tine[appName].Model[modelName].getFilterModel = function () {
              return [];
            }; // NOTE: no constructor, super magic here


            if (Tine[appName].Model.hasOwnProperty(modelName + 'Mixin')) {
              Ext.override(Tine[appName].Model[modelName], Tine[appName].Model[modelName + 'Mixin']);
              Ext.apply(Tine[appName].Model[modelName], _.get(Tine[appName].Model[modelName + 'Mixin'], 'statics', {}));
            }
          } // register filters


          Ext.iterate(modelConfig.filterModel, function (key, filter) {
            var f = this.getFilter(key, filter, modelConfig);

            if (f) {
              Tine.widgets.grid.FilterRegistry.register(appName, modelName, f);
            }
          }, this); // create recordProxy

          var recordProxyName = modelName.toLowerCase() + 'Backend';

          if (!Tine[appName].hasOwnProperty(recordProxyName)) {
            Tine[appName][recordProxyName] = new Tine.Tinebase.data.RecordProxy({
              appName: appName,
              modelName: modelName,
              recordClass: Tine[appName].Model[modelName]
            });

            if (Tine[appName].hasOwnProperty([recordProxyName] + 'Mixin')) {
              Ext.apply(Tine[appName][recordProxyName], Tine[appName][recordProxyName + 'Mixin']);
              Ext.apply(Tine[appName][recordProxyName], _.get(Tine[appName][recordProxyName + 'Mixin'], 'statics', {}));
            }
          }

          if (recordProxyName === 'nodeBackend') return; // if default data is empty, it will be resolved to an array

          if (Ext.isArray(modelConfig.defaultData)) {
            modelConfig.defaultData = {};
          } // overwrite function


          Tine[appName].Model[modelName].getDefaultData = function () {
            if (!dd) {
              var dd = Ext.decode(Ext.encode(modelConfig.defaultData));
            } // find container by selection or use defaultContainer by registry


            if (modelConfig.containerProperty) {
              if (!dd.hasOwnProperty(modelConfig.containerProperty)) {
                var app = Tine.Tinebase.appMgr.get(appName),
                    registry = app.getRegistry(),
                    ctp = app.getMainScreen().getWestPanel().getContainerTreePanel();
                var container = (ctp && Ext.isFunction(ctp.getDefaultContainer) ? ctp.getDefaultContainer() : null) || (registry ? registry.get("default" + modelName + "Container") : null);

                if (container) {
                  dd[modelConfig.containerProperty] = container;
                }
              }
            }

            return dd;
          }; // create filter panel


          var filterPanelName = modelName + 'FilterPanel';

          if (!Tine[appName].hasOwnProperty(filterPanelName)) {
            Tine[appName][filterPanelName] = function (c) {
              Ext.apply(this, c);
              Tine[appName][filterPanelName].superclass.constructor.call(this);
            };

            Ext.extend(Tine[appName][filterPanelName], Tine.widgets.persistentfilter.PickerPanel);
          } // create container tree panel, if needed


          if (containerProperty) {
            var containerTreePanelName = modelName + 'TreePanel';

            if (!Tine[appName].hasOwnProperty(containerTreePanelName)) {
              Tine[appName][containerTreePanelName] = Ext.extend(Tine.widgets.container.TreePanel, {
                filterMode: 'filterToolbar',
                recordClass: Tine[appName].Model[modelName]
              });
            }
          } // create editDialog openWindow function only if edit dialog exists


          var editDialogName = modelName + 'EditDialog';

          if (!Tine[appName].hasOwnProperty(editDialogName)) {
            Tine[appName][editDialogName] = Ext.extend(Tine.widgets.dialog.EditDialog, {
              displayNotes: Tine[appName].Model[modelName].hasField('notes')
            });
          }

          if (Tine[appName].hasOwnProperty(editDialogName)) {
            var edp = Tine[appName][editDialogName].prototype;

            if (containerProperty && edp.showContainerSelector !== false) {
              edp.showContainerSelector = true;
            }

            Ext.apply(edp, {
              modelConfig: Ext.encode(modelConfig),
              modelName: modelName,
              recordClass: Tine[appName].Model[modelName],
              recordProxy: Tine[appName][recordProxyName],
              appName: appName,
              windowNamePrefix: modelName + 'EditWindow_'
            });

            if (!Ext.isFunction(Tine[appName][editDialogName].openWindow)) {
              Tine[appName][editDialogName].openWindow = function (cfg) {
                var id = cfg.recordId ? cfg.recordId : cfg.record && cfg.record.id ? cfg.record.id : 0;
                var window = Tine.WindowFactory.getWindow({
                  width: edp.windowWidth ? edp.windowWidth : 600,
                  height: edp.windowHeight ? edp.windowHeight : Tine.widgets.form.RecordForm.getFormHeight(Tine[appName].Model[modelName]),
                  name: edp.windowNamePrefix + id,
                  contentPanelConstructor: 'Tine.' + appName + '.' + editDialogName,
                  contentPanelConstructorConfig: cfg
                });
                return window;
              };
            }
          } // create Gridpanel


          var gridPanelName = modelName + 'GridPanel',
              gpConfig = {
            modelConfig: modelConfig,
            app: Tine.Tinebase.appMgr.get(appName),
            recordProxy: Tine[appName][recordProxyName],
            recordClass: Tine[appName].Model[modelName]
          };

          if (!Tine[appName].hasOwnProperty(gridPanelName)) {
            Tine[appName][gridPanelName] = Ext.extend(Tine.widgets.grid.GridPanel, gpConfig);
          } else {
            Ext.apply(Tine[appName][gridPanelName].prototype, gpConfig);
          }

          if (!Tine[appName][gridPanelName].prototype.detailsPanel) {
            Tine[appName][gridPanelName].prototype.detailsPanel = {
              xtype: 'widget-detailspanel',
              recordClass: Tine[appName].Model[modelName]
            };
          } // add model to global add splitbutton if set


          if (modelConfig.hasOwnProperty('splitButton') && modelConfig.splitButton == true) {
            var iconCls = appName + modelName;

            if (!Ext.util.CSS.getRule('.' + iconCls)) {
              iconCls = 'ApplicationIconCls';
            }

            Ext.ux.ItemRegistry.registerItem('Tine.widgets.grid.GridPanel.addButton', {
              text: Tine[appName].i18n._('New ' + modelName),
              iconCls: iconCls,
              scope: Tine.Tinebase.appMgr.get(appName),
              handler: function () {
                var ms = this.getMainScreen(),
                    cp = ms.getCenterPanel(modelName);
                cp.onEditInNewWindow.call(cp, {});
              }.createDelegate(Tine.Tinebase.appMgr.get(appName))
            });
          }
        }, this);
      }
    }, this);
    var stop = new Date();
  }
});

/***/ }),
/* 1142 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux');
/**
 * Class for handling of native browser popup window.
 * <p>This class is intended to make the usage of a native popup window as easy as dealing with a modal window.<p>
 * <p>Example usage:</p>
 * <pre><code>
 var win = new Ext.ux.PopupWindow({
     name: 'TasksEditWindow',
     width: 700,
     height: 300,
     url:index.php?method=Tasks.editTask&taskId=5
 });
 * </code></pre>
 * 
 * @namespace   Ext.ux
 * @class       Ext.ux.PopupWindow
 * @extends     Ext.Component
 */

Ext.ux.PopupWindow = function (config) {
  Ext.apply(this, config);
  this.contentPanelConstructorConfig = this.contentPanelConstructorConfig || {};
  this.addEvents({
    /**
     * @event beforecolse
     * @desc Fires before the Window is closed. A handler can return false to cancel the close.
     * @param {Ext.ux.PopupWindow}
     */
    "beforeclose": true,

    /**
     * @event render
     * @desc  Fires after the viewport in the popup window is rendered
     * @param {Ext.ux.PopupWindow}
     */
    "render": true,

    /**
     * @event close
     * @desc  Fired, when the window got closed
     */
    "close": true
  });
  Ext.ux.PopupWindow.superclass.constructor.call(this);
};

Ext.extend(Ext.ux.PopupWindow, Ext.Component, {
  /**
   * @cfg    {String}
   * @param  {String} url
   * @desc   url to open
   */
  url: null,

  /**
   * @cfg {String} internal name of new window
   */
  name: 'new window',

  /**
   * @cfg {Int} width of new window
   */
  width: 600,

  /**
   * @cfg {Int} height of new window
   */
  height: 500,

  /**
   * @cfg {Bolean}
   */
  modal: false,

  /**
   * @cfg {Boolean} cut relation to opener
   * needed e.g. when opening a new mainWindow
   */
  noParent: false,

  /**
   * @cfg {String}
   */
  layout: 'fit',

  /**
   * @cfg {String}
   */
  title: null,

  /**
   * @cfg {String} Name of a constructor to create item property
   */
  contentPanelConstructor: null,

  /**
   * @cfg {Object} Config object to pass to itemContructor
   */
  contentPanelConstructorConfig: null,

  /**
   * @property {Browser Window}
   */
  popup: null,

  /**
   * @property {Ext.ux.PopupWindowMgr}
   */
  windowManager: null,
  renderTo: 'useRenderFn',

  /**
   * @private
   */
  initComponent: function initComponent() {
    if (!this.title) {
      this.title = Tine.title;
    }

    this.windowManager = Ext.ux.PopupWindowMgr;
    this.stateful = true;
    this.stateId = 'ux.popupwindow-' + this.contentPanelConstructor; // window decoration and location bar count to window height

    this.height += 20;
    Ext.ux.PopupWindow.superclass.initComponent.call(this);
  },
  render: function render() {
    // open popup window first to save time
    if (!this.popup) {
      try {
        // NOTE: safaris devicePixelRatio is always 2 and does not change with zoom-level 
        this.evalDevicePixelRatio = !Ext.isSafari; // NOTE: FF scales windows itself -> no need for adoption
        // NOTE: Chrome/FF on MacOS with retina display have their devicePixelRatio multiplied by 2
        //       what about mac-mini? -> pls. report

        const devicePixelRatio = Ext.isGecko ? 1 : window.devicePixelRatio / (Ext.isMac ? 2 : 1);

        if (this.evalDevicePixelRatio && devicePixelRatio) {
          this.width = Math.round(this.width * devicePixelRatio);
          this.height = Math.round(this.height * devicePixelRatio);
        } //limit the window size


        this.width = Math.min(screen.availWidth, this.width);
        this.height = Math.min(screen.availHeight, this.height);
        this.popup = this.openWindow(this.name, this.url, this.width, this.height);

        if (this.noParent) {
          this.popup.opener = null;
        }
      } catch (e) {
        this.popup = null;
      }
    }

    if (!this.popup) {
      return Ext.MessageBox.alert(i18n._('Cannot open new window'), String.format(i18n._('An attempt to open a new window failed. When clicking OK, the opening procedure will be tried again. To avoid this message, please deactivate your browsers popup blocker for {0}'), Tine.title), function () {
        this.render();
      }.bind(this));
    } //. register window ( in fact register complete PopupWindow )


    this.windowManager.register(this); // closing properly or prevent close otherwise

    this.popup.addEventListener('beforeunload', _.bind(e => {
      if (!this.forceClose && this.fireEvent("beforeclose", this) === false) {
        e.preventDefault();
        e.returnValue = '';
      }
    }, this));
    this.popup.addEventListener('resize', _.debounce(_.bind(this.saveState, this), 150));
  },

  /**
   * Open browsers native popup
   *
   * @param {string}     windowName
   * @param {string}     url
   * @param width
   * @param height
   */
  openWindow: function openWindow(windowName, url, width, height) {
    windowName = Ext.isString(windowName) ? windowName.replace(/[^a-zA-Z0-9_]/g, '') : windowName; // thanks to http://www.nigraphic.com/blog/java-script/how-open-new-window-popup-center-screen
    // Determine offsets in case of dualscreen

    const dualScreenLeft = window.screenLeft != undefined ? window.screenLeft : screen.left;
    const dualScreenTop = window.screenTop != undefined ? window.screenTop : screen.top; // Window should be opened on mid of tine window

    const w = window.innerWidth ? window.innerWidth : document.documentElement.clientWidth ? document.documentElement.clientWidth : screen.width;
    const h = window.innerHeight ? window.innerHeight : document.documentElement.clientHeight ? document.documentElement.clientHeight : screen.height; // Determine correct left and top values including dual screen setup

    const left = w / 2 - width / 2 + dualScreenLeft;
    const top = h / 2 - height / 2 + dualScreenTop;
    return popup = window.open(url, windowName, 'width=' + width + ',height=' + height + ',top=' + top + ',left=' + left + ',directories=no,toolbar=no,location=no,menubar=no,scrollbars=no,status=no,resizable=yes,dependent=no');
  },
  getState: function getState() {
    // NOTE: innerWidth/Height is the original dimension without scaling
    // NOTE: FF does auto scaling!
    const state = {
      width: this.popup.innerWidth,
      height: this.popup.innerHeight
    };
    return state;
  },
  // state might have tiny window (e.g. because of small beamer attached)
  // -> only apply bigger states
  applyState: function applyState(state) {
    if (state) {
      state.width = Math.max(state.width, this.width);
      state.height = Math.max(state.height, this.height);
    }

    Ext.ux.PopupWindow.superclass.applyState.call(this, state);
  },

  /**
   * rename window name
   * 
   * @param {String} new name
   */
  rename: function rename(newName) {
    this.windowManager.unregister(this);
    this.name = this.popup.name = newName;
    this.windowManager.register(this);
  },

  /**
   * Sets the title text for the panel and optionally the icon class.
   * 
   * @param {String} title The title text to set
   * @param {String} iconCls (optional) iconCls A user-defined CSS class that provides the icon image for this panel
   */
  setTitle: function setTitle(title, iconCls) {
    if (this.popup && this.popup.document) {
      this.popup.document.title = Ext.util.Format.stripTags(title);
    }
  },

  /**
   * Closes the window, removes it from the DOM and destroys the window object. 
   * The beforeclose event is fired before the close happens and will cancel 
   * the close action if it returns false.
   */
  close: function close(force) {
    if (force || this.fireEvent("beforeclose", this) !== false) {
      this.forceClose = true;
      this.fireEvent('close', this);
      var popup = this.popup;
      this.destroy();

      if (this.navigateBackOnClose) {
        popup.history.back();
      } else {
        Ext.ux.PopupWindow.close(popup);
      }

      return true;
    } else {
      this.confirmLeavSite(this);
    }
  },

  /**
   * @private
   * 
   * called after this.popups native onLoad
   * note: 'this' references the popup, whereas window references the parent
   */
  onLoad: function onLoad() {
    this.Ext.onReady(function () {
      this.navigateBackOnClose = this.popup.history.length > 1;
    }, this);
  },

  /**
   * @private
   * 
   * note: 'this' references the popup, whereas window references the parent
   */
  onClose: function onClose() {},

  /**
   * @private
   */
  destroy: function destroy() {
    Ext.ux.PopupWindow.superclass.destroy.call(this);
    this.purgeListeners();
    this.windowManager.unregister(this);
    this.popup = null;
  }
});
/**
 * close window and show close message
 *
 * @static
 * @param win
 */

Ext.ux.PopupWindow.close = function (win) {
  win = win || window; // defer messagebox as it should not be displayed too early

  win.setTimeout(function () {
    if (!win) {
      return;
    }

    win.Ext.MessageBox.alert(i18n._('Window can be closed'), String.format(i18n._('This Window can be closed now. To avoid this message please deactivate your browsers popup blocker for {0}'), Tine.title), function () {
      win.close();
    });
  }, 2000);
  win.close();
};

/***/ }),
/* 1143 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/**
 * An object that represents a group of {@link Ext.ux.PopupWindow}
 * 
 * @namespace   Ext.ux
 * @class       Ext.ux.PopupWindowGroup
 * @constructor
 */
Ext.ux.PopupWindowGroup = function (config) {
  config = config || {};
  /**
   * @cfg {window} mainWindow
   */

  var mainWindow = config.mainWindow || window; // mark mainWindow

  mainWindow.isMainWindow = true;
  var list = {};
  var accessList = [];
  var front = null; // private

  var cleanupClosedWindows = function cleanupClosedWindows() {
    var doc;

    for (var id in list) {
      try {
        var newDate = new Date().getTime();

        if (list[id].registerTime && list[id].registerTime / 1 + 2000 > newDate / 1) {
          continue;
        }

        doc = list[id].popup.document;

        if (!Ext.isIE && !doc.defaultView) {
          doc = false;
        }
      } catch (e) {
        doc = false;
      }

      if (!doc) {
        list[id].destroy();
        accessList.remove(list[id]);
        list[id] = null;
        delete list[id];
      }
    }
  };

  var cleanUpTask = function cleanUpTask() {
    cleanupClosedWindows();
    cleanUpTask.defer(10000);
  };

  cleanUpTask();
  /*
  // private
  var sortWindows = function(d1, d2){
      return (!d1._lastAccess || d1._lastAccess < d2._lastAccess) ? -1 : 1;
  };
   // private
  var orderWindows = function(){
      var a = accessList, len = a.length;
      if(len > 0){
          a.sort(sortWindows);
          var seed = a[0].manager.zseed;
          for(var i = 0; i < len; i++){
              var win = a[i];
              if(win && !win.hidden){
                  win.setZIndex(seed + (i*10));
              }
          }
      }
      activateLast();
  };
   // private
  var setActiveWin = function(win){
      if(win != front){
          if(front){
              front.setActive(false);
          }
          front = win;
          if(win){
              win.setActive(true);
          }
      }
  };
   // private
  var activateLast = function(){
      for(var i = accessList.length-1; i >=0; --i) {
          if(!accessList[i].hidden){
              setActiveWin(accessList[i]);
              return;
          }
      }
      // none to activate
      setActiveWin(null);
  };
  */

  return {
    register: function register(win) {
      win.registerTime = new Date().getTime();
      cleanupClosedWindows();

      if (!win.popup) {
        console.error('pure window instead of Ext.ux.PopupWindow got registered');
      }

      list[win.name] = win;
      accessList.push(win); //win.on('hide', activateLast);
    },
    unregister: function unregister(win) {
      list[win.name] = null;
      delete list[win.name]; //win.un('hide', activateLast);

      accessList.remove(win);
    },

    /**
     * Gets a registered window by name.
     * @param {String/Object} name The name of the window or a browser window object
     * @return {Ext.ux.PopupWindow}
     */
    get: function get(name) {
      cleanupClosedWindows();
      name = typeof name == "object" ? name.name : name;
      return list[name];
    },

    /**
     * returns main window of this window group
     * 
     * @return window
     */
    getMainWindow: function getMainWindow() {
      return mainWindow;
    },

    /**
     * Brings the specified window to the front of any other active windows.
     * @param {String/Object} win The id of the window or a {@link Ext.Window} instance
     * @return {Boolean} True if the dialog was brought to the front, else false
     * if it was already in front
     */
    bringToFront: function bringToFront(win) {
      win = this.get(win);

      if (win != front) {
        win._lastAccess = new Date().getTime();

        if (win.popup.focus) {
          win.popup.focus();
        } //                front = win;
        // NOTE: we don't recognise the front window yet
        //                if (Ext.isOpera) {
        //                    Ext.Msg.alert(i18n._("The window you want to work with is backgrounded. Your browser doesn't support to foreground the window for you, so you need to use your operating systems window switching features. Please send complaints to your browser vendor!"))
        //                }
        //orderWindows();


        return true;
      }

      return false;
    },

    /**
     * Sends the specified window to the back of other active windows.
     * @param {String/Object} win The id of the window or a {@link Ext.Window} instance
     * @return {Ext.Window} The window
     */

    /*
    sendToBack : function(win){
        win = this.get(win);
        win._lastAccess = -(new Date().getTime());
        orderWindows();
        return win;
    },
    */

    /**
     * Hides all windows in the group.
     */

    /*
    hideAll : function(){
        for(var id in list){
            if(list[id] && typeof list[id] != "function" && list[id].isVisible()){
                list[id].hide();
            }
        }
    },
    */

    /**
     * Gets the currently-active window in the group.
     * @return {Ext.Window} The active window
     */

    /*
    getActive : function(){
        return front;
    },
    */

    /**
     * Returns zero or more windows in the group using the custom search function passed to this method.
     * The function should accept a single {@link Ext.ux.PopupWindow} reference as its only argument and should
     * return true if the window matches the search criteria, otherwise it should return false.
     * @param {Function} fn The search function
     * @param {Object} scope (optional) The scope in which to execute the function (defaults to the window
     * that gets passed to the function if not specified)
     * @return {Array} An array of zero or more matching windows
     */
    getBy: function getBy(fn, scope) {
      cleanupClosedWindows();
      var r = [];

      for (var i = accessList.length - 1; i >= 0; --i) {
        var win = accessList[i];

        if (fn.call(scope || win, win) !== false) {
          r.push(win);
        }
      }

      return r;
    },

    /**
     * Executes the specified function once for every window in the group, passing each
     * window as the only parameter. Returning false from the function will stop the iteration.
     * @param {Function} fn The function to execute for each item
     * @param {Object} scope (optional) The scope in which to execute the function
     */
    each: function each(fn, scope) {
      cleanupClosedWindows();

      for (var id in list) {
        if (list[id] && typeof list[id] != "function") {
          if (fn.call(scope || list[id], list[id]) === false) {
            return;
          }
        }
      }
    }
  };
};
/**
 * @class Ext.ux.PopupWindowMgr
 * @extends Ext.ux.PopupWindowGroup
 * The default global window group that is available automatically.  To have more than one group of 
 * popup windows, create additional instances of {@link Ext.ux.PopupWindowGroup} as needed.
 * @singleton
 */


try {
  Ext.ux.PopupWindowMgr = window.opener.Ext.ux.PopupWindowMgr ? window.opener.Ext.ux.PopupWindowMgr : new Ext.ux.PopupWindowGroup();
} catch (e) {
  // we might have no access no opener
  Ext.ux.PopupWindowMgr = new Ext.ux.PopupWindowGroup();
}

/***/ }),
/* 1144 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2018 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * 
 * TODO         play sound / vibrate?
 * TODO         allow to set display duration?
 */
Ext.ns('Ext.ux.Notification');

Ext.ux.Notification = function () {
  return {
    show: function show(title, text) {
      // define icon url
      // TODO use relative path here
      var iconUrl = window.location.href.replace(/#+.*/, '') + '/images/tine_logo.png'; // webkit notifications

      if (window.webkitNotifications !== undefined && window.webkitNotifications.checkPermission() == 0) {
        // 0 is PERMISSION_ALLOWED
        var notification = window.webkitNotifications.createNotification(iconUrl, title, text);
        notification.show();
        setTimeout(function () {
          notification.cancel();
        }, 15000); // Notification (see https://notifications.spec.whatwg.org/)
      } else if (window.Notification && window.Notification.permission == 'granted') {
        var notification = new window.Notification(title, {
          icon: iconUrl,
          body: text
        }); //notification.onclick = function () {
        //    window.open("http://stackoverflow.com/a/13328397/1269037");
        //};
        // default behaviour
      } else {
        Ext.ux.MessageBox.msg(title, text);
      }
    }
  };
}();

/***/ }),
/* 1145 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext*/
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.WindowFactory
 * @contructor
 *
 * @cfg {String} windowType type of window {Ext|Browser}
 */

Ext.ux.WindowFactory = function (config) {
  let me = this;
  Ext.apply(this, config);

  switch (this.windowType) {
    case 'Browser':
      this.windowClass = Ext.ux.PopupWindow;
      this.windowManager = Ext.ux.PopupWindowMgr;
      break;

    case 'Ext':
      this.windowClass = Ext.extend(Ext.Window, {
        confirmLeavSite: me.confirmLeavSite,
        // closing interception analog to browser windows
        close: function close(force) {
          if (force || this.fireEvent('beforeclose', this) !== false) {
            if (this.hidden) {
              this.doClose();
            } else {
              this.hide(null, this.doClose, this);
            }
          } else {
            this.confirmLeavSite(this);
          }
        }
      });
      this.windowManager = Ext.WindowMgr;
      break;

    default:
      console.error('No such windowType: ' + this.windowType);
      break;
  }
};
/**
 * @class Ext.ux.WindowFactory
 */


Ext.ux.WindowFactory.prototype = {
  /**
   * @private
   */
  windowClass: null,

  /**
   * @private
   */
  windowManager: null,

  /**
   * @rivate
   */
  getBrowserWindow: function getBrowserWindow(config) {
    var win = Ext.ux.PopupWindowMgr.get(config.name);

    if (!win) {
      win = new this.windowClass(config);
      win.confirmLeavSite = this.confirmLeavSite;
    }

    Ext.ux.PopupWindowMgr.bringToFront(win);
    return win;
  },

  /**
   * @private
   */
  getExtWindow: function getExtWindow(c) {
    var win = Ext.WindowMgr.get(c.name);
    var winConstructor = c.modal ? Ext.Window : this.windowClass;

    if (!win) {
      c.id = c.name; // add titleBar

      c.height = c.height + 20; // border width

      c.width = c.width + 16; // save normal size

      c.normSize = {
        width: c.width,
        height: c.height
      }; //limit the window size

      c.height = Math.min(Ext.getBody().getBox().height, c.height);
      c.width = Math.min(Ext.getBody().getBox().width, c.width);
      c.layout = c.layout || 'fit';
      const cp = this.getCenterPanel(c);
      c.items = {
        layout: 'card',
        border: false,
        activeItem: 0,
        isWindowMainCardPanel: true,
        items: [cp]
      }; // NOTE: is this still true ?? -> we can only handle one window yet

      c.modal = true;
      win = new winConstructor(c);
      c.items.items[0].window = win;

      if (cp.onWindowInject) {
        cp.onWindowInject.call(cp, win);
      }
    } // if initShow property is present and it is set to false don't show window, just return reference


    if (!c.hasOwnProperty('initShow') || c.initShow !== false) {
      win.show();
    }

    return win;
  },

  /**
   * constructs window items from config properties
   */
  getCenterPanel: function getCenterPanel(config) {
    var items;

    if (config.contentPanelConstructor) {
      config.contentPanelConstructorConfig = config.contentPanelConstructorConfig || {}; // place a reference to current window class in the itemConstructor.
      // this may be overwritten depending on concrete window implementation

      config.contentPanelConstructorConfig.window = config; // find the constructor in this context

      var parts = config.contentPanelConstructor.split('.'),
          ref = window;

      for (var i = 0; i < parts.length; i += 1) {
        ref = ref[parts[i]];
      } // finally construct the content panel


      Tine.log.info('WindowFactory::getCenterPanel - construct content panel');
      items = new ref(config.contentPanelConstructorConfig); // remove x-window reference

      config.contentPanelConstructorConfig.listeners = null;
    } else {
      items = config.items ? config.items : {};
    }

    return items;
  },

  /**
   * getWindow
   * 
   * creates new window if not already exists.
   * brings window to front
   */
  getWindow: function getWindow(config) {
    var windowType = config.windowType || (config.modal ? 'Ext' : this.windowType); // Names are only allowed to be alnum

    config.name = Ext.isString(config.name) ? config.name.replace(/[^a-zA-Z0-9_]/g, '') : config.name;

    if (!config.title && config.contentPanelConstructorConfig && config.contentPanelConstructorConfig.title) {
      config.title = config.contentPanelConstructorConfig.title;
      delete config.contentPanelConstructorConfig.title;
    }

    switch (windowType) {
      case 'Browser':
        try {
          return this.getBrowserWindow(config);
        } catch (e) {// fallthrough to Ext Window
        }

      case 'Ext':
        return this.getExtWindow(config);

      default:
        console.error('No such windowType: ' + this.windowType);
        break;
    }
  },
  confirmLeavSite: function confirmLeavSite(scope) {
    let win = scope.popup ? scope.popup : window;
    win.Ext.MessageBox.show({
      title: i18n._('Leave site?'),
      msg: i18n._('Changes you made may not be saved.'),
      buttons: Ext.MessageBox.OKCANCEL,
      fn: function fn(buttonId) {
        if (buttonId === 'ok') {
          scope.close(true);
        }
      },
      icon: Ext.MessageBox.WARNING
    });
  }
};

/***/ }),
/* 1146 */
/***/ (function(module, exports) {

/*
 * Ext JS Library 2.2
 * Copyright(c) 2006-2008, Ext JS, LLC.
 * licensing@extjs.com
 * 
 * http://extjs.com/license
 */

/**
 * @class Ext.ux.SliderTip
 * @extends Ext.Tip
 * Simple plugin for using an Ext.Tip with a slider to show the slider value
 */
Ext.ux.SliderTip = Ext.extend(Ext.Tip, {
  minWidth: 10,
  offsets: [0, -10],
  init: function init(slider) {
    slider.on('dragstart', this.onSlide, this);
    slider.on('drag', this.onSlide, this);
    slider.on('dragend', this.hide, this);
    slider.on('destroy', this.destroy, this);
  },
  onSlide: function onSlide(slider) {
    this.show();
    this.body.update(this.getText(slider));
    this.doAutoWidth();
    this.el.alignTo(slider.thumb, 'b-t?', this.offsets);
  },
  getText: function getText(slider) {
    return slider.getValue();
  }
});

/***/ }),
/* 1147 */
/***/ (function(module, exports) {

/*
 * @author Pontifex
 * @version 1.0
 *
 * @class Ext.ux.Wizard
 */
Ext.ns('Ext.ux');
/**
 * Ext.ux.Wizard Extension Class
 * 
 * @namespace   Ext.ux
 * @class       Ext.ux.Wizard
 * @extends     Ext.Panel
 * @constructor
 * @param {Object} config Configuration options
 */

Ext.ux.Wizard = function (config) {
  var _config = Ext.apply({
    layout: 'card',
    activeItem: 0,
    bodyStyle: 'paddingTop:15px',
    defaults: {
      // applied to each contained panel
      border: false
    },
    buttons: [{
      text: 'Previous',
      handler: this.movePrevious,
      scope: this,
      disabled: true
    }, {
      text: 'Next',
      handler: this.moveNext,
      scope: this
    }, {
      text: 'Finish',
      handler: this.finishHanlder,
      scope: this,
      disabled: true
    }, {
      text: 'Cancel',
      handler: this.hideHanlder,
      scope: this
    }]
  }, config || {});

  this.currentItem = 0;
  this.template = new Ext.Template('Step {current} of {count}');
  this.mandatorySteps = _config.mandatorySteps;
  Ext.ux.Wizard.superclass.constructor.call(this, _config);
  this.addEvents('leave', 'activate', 'finish', 'cancel');
  this.on('render', function () {
    this.footer.addClass('x-panel-footer-wizard');
    this.footer.insertFirst({
      html: '<div class="x-panel-footer-wizard-status">&nbsp;</div>'
    });
    this.setStatus();
    return true;
  });
}; // end of Ext.ux.Wizard constructor
// extend


Ext.extend(Ext.ux.Wizard, Ext.Panel, {
  getCurrentStep: function getCurrentStep() {
    return this.currentItem + 1;
  },
  getStepCount: function getStepCount() {
    return this.items.items.length;
  },
  setCurrentStep: function setCurrentStep(step) {
    this.move(step - 1);
  },

  /**
   * @private
   */
  beforeMove: function beforeMove(currentItem, nextItem, forward) {
    return this.fireEvent('leave', currentItem, nextItem, forward);
  },

  /**
   * @private
   */
  setStatus: function setStatus() {
    var BUTTON_PREVIOUS = 0;
    var BUTTON_NEXT = 1;
    var BUTTON_FINISH = 2;
    var BUTTON_CANCEL = 3;
    var isFirstItem = this.getCurrentStep() == 1;
    var isLastItem = this.getCurrentStep() == this.getStepCount();
    var minimunSteps = isNaN(parseInt(this.mandatorySteps)) ? this.getStepCount() : Math.min(Math.max(parseInt(this.mandatorySteps), 1), this.getStepCount());
    this.buttons[BUTTON_PREVIOUS].setDisabled(isFirstItem);
    this.buttons[BUTTON_NEXT].setDisabled(isLastItem);
    this.buttons[BUTTON_FINISH].setDisabled(!(isLastItem || minimunSteps < this.getCurrentStep()));
    this.footer.first('div div', true).firstChild.innerHTML = this.template.applyTemplate({
      'current': this.getCurrentStep(),
      'count': this.getStepCount()
    });
  },

  /**
   * @private
   */
  move: function move(item) {
    if (item >= 0 && item < this.items.items.length) {
      if (this.beforeMove(this.layout.activeItem, this.items.items[item], item > this.currentItem)) {
        this.layout.setActiveItem(item);
        this.currentItem = item;
        this.setStatus();
        this.fireEvent('activate', this.layout.activeItem);
      }
    }
  },

  /**
   * @private
   */
  moveNext: function moveNext(btn, e) {
    this.move(this.currentItem + 1);
  },

  /**
   * @private
   */
  movePrevious: function movePrevious(btn, e) {
    this.move(this.currentItem - 1);
  },

  /**
   * @private
   */
  hideHanlder: function hideHanlder() {
    if (this.fireEvent('cancel')) {
      this.hide();
    }
  },

  /**
   * @private
   */
  finishHanlder: function finishHanlder() {
    if (this.fireEvent('finish')) {
      this.hide();
    }
  }
});

/***/ }),
/* 1148 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux');
/**
 * Generic widget for a twintriggerd search field
 * 
 * @namespace   Ext.ux
 * @class       Ext.ux.SearchField
 * @extends     Ext.form.TwinTriggerField
 */

Ext.ux.SearchField = Ext.extend(Ext.form.TwinTriggerField, {
  /**
   * @cfg {String} paramName
   */
  paramName: 'query',

  /**
   * @cfg {Bool} selectOnFocus
   */
  selectOnFocus: true,

  /**
   * @cfg {String} emptyText
   */
  emptyText: '',
  validationEvent: false,
  validateOnBlur: false,
  trigger1Class: 'x-form-clear-trigger',
  trigger2Class: 'x-form-search-trigger',
  hideTrigger1: true,
  width: 180,
  hasSearch: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.emptyText = this.emptyText || i18n._('enter searchfilter');
    Ext.ux.SearchField.superclass.initComponent.call(this);
    this.on('specialkey', function (f, e) {
      if (e.getKey() == e.ENTER) {
        if (this.getValue() == '') {
          this.onTrigger1Click();
        } else {
          this.onTrigger2Click();
        }
      }
    }, this);
  },

  /**
   * @private
   */
  onTrigger1Click: function onTrigger1Click() {
    if (this.hasSearch) {
      this.el.dom.value = '';
      this.fireEvent('change', this, this.getRawValue(), this.startValue);
      this.startValue = this.getRawValue();
      this.triggers[0].hide();
      this.hasSearch = false;
    }
  },

  /**
   * @private
   */
  onTrigger2Click: function onTrigger2Click() {
    var v = this.getRawValue();
    this.fireEvent('change', this, this.getRawValue(), this.startValue);
    this.startValue = this.getRawValue();
    this.hasSearch = true;
    this.triggers[0][v.length < 1 ? 'hide' : 'show']();
  }
});
Ext.reg('ux-searchfield', Ext.ux.SearchField);

/***/ }),
/* 1149 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.BrowseButton
 * @extends     Ext.Button
 */

Ext.ux.BrowseButton = Ext.extend(Ext.Button, {
  initComponent: function initComponent() {
    this.plugins = this.plugins || [];
    this.plugins.push(new Ext.ux.file.BrowsePlugin({}));
    Ext.ux.BrowseButton.superclass.initComponent.call(this);
  }
});
Ext.reg('browsebutton', Ext.ux.BrowseButton);

/***/ }),
/* 1150 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * central column manager
 * - get column for a given column
 * - register column for a given column
 *
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.ColumnManager
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @singleton
 */

Tine.widgets.grid.ColumnManager = function () {
  var columns = {};
  return {
    /**
     * const for category editDialog
     */
    CATEGORY_EDITDIALOG: 'editDialog',

    /**
     * const for category mainScreen
     */
    CATEGORY_PROPERTYGRID: 'mainScreen',

    /**
     * get column of well known column names
     *
     * @param {String} columnName
     * @return {Object}
     */
    getByFieldname: function getByFieldname(columnName) {
      var column = null;
      return column;
    },

    /**
     * get column by data type
     *
     * @param {String} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {editDialog|mainScreen} optional.
     * @param {Object} config
     * @return {Object}
     */
    getByModelConfig: function getByModelConfig(appName, modelName, fieldName, category, config) {
      var _ = window.lodash,
          column = {},
          recordClass = Tine.Tinebase.data.RecordMgr.get(appName, modelName),
          modelConfig = recordClass ? recordClass.getModelConfiguration() : null,
          fieldDefinition = _.get(modelConfig, 'fields.' + fieldName, {}),
          fieldType = fieldDefinition.type || 'string',
          app = Tine.Tinebase.appMgr.get(fieldDefinition.owningApp || appName),
          i18n = fieldDefinition.useGlobalTranslation ? window.i18n : app.i18n;

      if (_.get(fieldDefinition, 'disabled')) {
        return null;
      }

      if (!app) {
        // e.g. no access to owningApp
        return null;
      }

      if (fieldDefinition.type === 'virtual') {
        fieldDefinition = fieldDefinition.config || {};
        ;
      } // don't show multiple record fields


      if (fieldDefinition.type == 'records') {
        return null;
      }

      if (fieldDefinition.disabled) {
        return null;
      } // don't show parent property in dependency of an editDialog


      if (this.editDialog && fieldDefinition.hasOwnProperty('config') && fieldDefinition.config.isParent) {
        return null;
      } // don't show record field if the user doesn't have the right on the application


      if (fieldDefinition.type == 'record' && !(fieldDefinition.config && fieldDefinition.config.doNotCheckModuleRight) && !Tine.Tinebase.common.hasRight('view', fieldDefinition.config.appName, fieldDefinition.config.modelName.toLowerCase() + 's')) {
        return null;
      }

      if (fieldDefinition.type == 'attachments') {
        config.width = 20;
        config.resizable = false;
        config.header = window.i18n._('Attachments');
        config.tooltip = config.header;
      }

      if (fieldDefinition.type == 'image') {
        config.width = 20;
        config.resizable = false;
        config.header = fieldDefinition.label == 'Image' ? window.i18n._('Image') : i18n._(fieldDefinition.label);
        config.tooltip = config.header;
      }

      if (_.indexOf(['hexcolor', 'bool', 'boolean'], fieldDefinition.type) >= 0) {
        config.width = config.width || 40;
      }

      if (_.indexOf(['data', 'datetime_separated_date', 'datetime_separated_time', 'datetime_separated_tz', 'money', 'integer', 'bool', 'boolean', 'float'], fieldDefinition.type) >= 0) {
        config.align = 'right';
        config.width = config.width || 90;
      }

      if (fieldDefinition.type == 'model') {
        config.width = config.width || 125;
      }

      if (fieldDefinition.type == 'dynamicRecord') {
        config.width = config.width || 400;
      } // If no label exists, don't use in grid


      if (!fieldDefinition.label) {
        return null;
      }

      Ext.applyIf(column, {
        id: fieldName,
        dataIndex: fieldName,
        header: i18n._(fieldDefinition.label),
        tooltip: i18n._(fieldDefinition.tooltip),
        hidden: fieldDefinition.hasOwnProperty('shy') ? fieldDefinition.shy : false,
        // defaults to false
        sortable: fieldDefinition.hasOwnProperty('sortable') && fieldDefinition.sortable == false ? false : true // defaults to true

      });

      if (fieldDefinition.hasOwnProperty('summaryType')) {
        column.summaryType = fieldDefinition.summaryType;
      }

      var renderer = Tine.widgets.grid.RendererManager.get(app, modelName, fieldName, Tine.widgets.grid.RendererManager.CATEGORY_GRIDPANEL);

      if (renderer) {
        column.renderer = renderer;
      }

      Ext.apply(column, config);
      return column;
    },

    /**
     * returns column for given column
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {editDialog|mainScreen} optional.
     * @param {Object} config
     * @return {Object}
     */
    get: function get(appName, modelName, fieldName, category, config) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]),
          config = config || {}; // check for registered renderer

      var column = columns[categoryKey] ? columns[categoryKey] : columns[genericKey]; // check for common names

      if (!column) {
        column = this.getByFieldname(fieldName);
      } // check for known datatypes


      if (!column) {
        column = this.getByModelConfig(appName, modelName, fieldName, category, config);
      }

      return column;
    },

    /**
     * register renderer for given column
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {Object} column
     * @param {String} category {editDialog|mainScreen} optional.
     */
    register: function register(appName, modelName, fieldName, column, category) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]);
      columns[category ? categoryKey : genericKey] = column;
    },

    /**
     * check if a column is explicitly registered
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {editDialog|mainScreen} optional.
     * @return {Boolean}
     */
    has: function has(appName, modelName, fieldName, category) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]); // check for registered renderer

      return (columns[categoryKey] ? columns[categoryKey] : columns[genericKey]) ? true : false;
    },

    /**
     * returns the modelName by modelName or record
     *
     * @param {Record/String} modelName
     * @return {String}
     */
    getModelName: function getModelName(modelName) {
      return Ext.isFunction(modelName) ? modelName.getMeta('modelName') : modelName;
    },

    /**
     * returns the modelName by appName or application instance
     *
     * @param {String/Tine.Tinebase.Application} appName
     * @return {String}
     */
    getAppName: function getAppName(appName) {
      return Ext.isString(appName) ? appName : appName.appName;
    },

    /**
     * returns a key by joining the array values
     *
     * @param {Array} params
     * @return {String}
     */
    getKey: function getKey(params) {
      return params.join('_');
    }
  };
}();

/***/ }),
/* 1151 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ns('Ext.ux.grid');
/**
 * @class Ext.ux.grid.CheckColumn
 * @extends Ext.util.Observable
 * GridPanel plugin to add a column with check boxes to a grid.
 * <p>Example usage:</p>
 * <pre><code>
// create the column
var checkColumn = new Ext.grid.CheckColumn({
   header: 'Indoor?',
   dataIndex: 'indoor',
   id: 'check',
   width: 55
});

// add the column to the column model
var cm = new Ext.grid.ColumnModel([{
       header: 'Foo',
       ...
    },
    checkColumn
]);

// create the grid
var grid = new Ext.grid.EditorGridPanel({
    ...
    cm: cm,
    plugins: [checkColumn], // include plugin
    ...
});
 * </code></pre>
 * In addition to storing a Boolean value within the record data, this
 * class toggles a css class between <tt>'x-grid3-check-col'</tt> and
 * <tt>'x-grid3-check-col-on'</tt> to alter the background image used for
 * a column.
 */

Ext.ux.grid.CheckColumn = function (config) {
  Ext.apply(this, config);

  if (!this.id) {
    this.id = Ext.id();
  }

  this.addEvents(
  /**
   * @event beforecheckchange
   * Fires before a check state changes
   * @param {Ext.ux.grid.CheckColumn} this
   * @param {boolean} newvalue
   * @param {boolean} oldvalue
   * @param {Ext.data.Record} record
   */
  'beforecheckchange',
  /**
   * @event checkchange
   * Fires when a check state changes
   * @param {Ext.ux.grid.CheckColumn} this
   * @param {boolean} newvalue
   * @param {boolean} oldvalue
   * @param {Ext.data.Record} record
   */
  'checkchange');
  this.renderer = this.renderer.createDelegate(this);
  Ext.ux.grid.CheckColumn.superclass.constructor.call(this);
};

Ext.extend(Ext.ux.grid.CheckColumn, Ext.util.Observable, {
  readOnly: false,
  init: function init(grid) {
    this.grid = grid;
    this.grid.on('render', function () {
      var view = this.grid.getView();
      view.mainBody.on('mousedown', this.onMouseDown, this);
    }, this);
    this.grid.afterIsRendered().then(() => {
      if (!this.grid.checkColumnAllActionsAdded && this.grid.view.hmenu) {
        this.grid.view.hmenu.add('-', this.selectAllAction = new Ext.Action({
          text: window.i18n._('Select all'),
          iconCls: 'x-grid3-check-col-on',
          handler: this.setAllSeleted.bind(this, true)
        }), this.deselectAllAction = new Ext.Action({
          text: window.i18n._('Deselect all'),
          iconCls: 'x-grid3-check-col',
          handler: this.setAllSeleted.bind(this, false)
        }));
        this.grid.view.hmenu.on('beforeshow', () => {
          const index = this.grid.view.hdCtxIndex;
          const col = this.grid.view.cm.columns[index];
          this.selectAllAction.setDisabled(col.constructor !== this.constructor);
          this.deselectAllAction.setDisabled(col.constructor !== this.constructor);
        });
        this.grid.checkColumnAllActionsAdded = true;
      }
    });
  },
  setAllSeleted: function setAllSeleted(selected) {
    const index = this.grid.view.hdCtxIndex;
    const col = this.grid.view.cm.columns[index];
    const store = this.grid.view.ds;
    store.each(r => {
      r.set(col.dataIndex, selected);
    });
  },

  /**
   * Validate action is valid or not here
   *
   * If returned false, the setting won't be changed.
   *
   * @param checkbox
   * @param record
   * @return {boolean}
   */
  onBeforeCheck: function onBeforeCheck(checkbox, record) {
    if (this.fireEvent('beforecheckchange', this, !record.data[this.dataIndex], record.data[this.dataIndex], record) === false) {
      return false;
    }

    return !this.grid.readOnly && !this.readOnly;
  },
  onMouseDown: function onMouseDown(e, t) {
    if (Ext.fly(t).hasClass(this.createId())) {
      e.stopEvent();
      var index = this.grid.getView().findRowIndex(t);
      var record = this.grid.store.getAt(index);

      if (this.onBeforeCheck(this, record)) {
        record.set(this.dataIndex, !record.data[this.dataIndex]);
        this.fireEvent('checkchange', this, record.data[this.dataIndex], !record.data[this.dataIndex], record);
      }
    }
  },
  renderer: function renderer(v, p, record) {
    p.css += ' x-grid3-check-col-td';
    return String.format('<div class="x-grid3-check-col{0} {1}">&#160;</div>', +v ? '-on' : '', this.createId());
  },
  createId: function createId() {
    return 'x-grid3-cc-' + this.id;
  }
}); // register ptype

Ext.preg('checkcolumn', Ext.ux.grid.CheckColumn); // backwards compat

Ext.grid.CheckColumn = Ext.ux.grid.CheckColumn;

/***/ }),
/* 1152 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.grid');
/**
 * @namespace   Ext.ux.grid
 * @class       Ext.ux.grid.ActionColumnPlugin
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @plugin for Ext.ux.grid.GridPanel
 */

Ext.ux.grid.ActionColumnPlugin = function (config) {
  Ext.apply(this, config);
};

Ext.extend(Ext.ux.grid.ActionColumnPlugin, Ext.util.Observable, {
  // private
  isColumn: true,
  menuDisabled: true,
  grid: null,
  gridPanel: null,
  filterable: false,

  /**
   * the template to put the data into
   * 
   * @type {Ext.XTemplate}
   */
  tpl: null,

  /**
   * config property actions
   * 
   * @type {Array}
   */
  actions: null,
  actionHandlers: null,

  /**
   * the main template for one column
   * 
   * @type {String}
   */
  templateHTML: '<div class="ux-action-column">' + '<tpl for="actions">' + '<div ext:ux-action-column-id="{id}" ext:ux-action-column="{actionName}" class="ux-action-column-item {cls} <tpl if="text">' + 'ux-action-column-text</tpl>" ext:qtip="{qtip}">' + '<tpl if="text"><span ext:qtip="{qtip}">{text}</span></tpl></div>' + '</tpl>' + '</div>',

  /**
   * initializes the plugin
   */
  init: function init(grid) {
    this.gridPanel = grid;
    this.grid = grid.getGrid();
    this.initTemplate();
    this.width = 60;
    this.view = this.grid.getView();
    this.renderer = this.renderColumn.createDelegate(this);
    this.grid.on('click', this.onClick, this);
  },

  /**
   * the onclick handler, finds the action and the index and calls
   */
  onClick: function onClick(e) {
    // handle row action click
    var target = e.getTarget('.ux-action-column-item');

    if (target) {
      var actionName = target.getAttribute(['ext:ux-action-column']);

      if (actionName) {
        var rowIndex = this.view.findRowIndex(target);

        if (rowIndex !== undefined) {
          this.actionHandlers[actionName].call(this.gridPanel, rowIndex);
        }
      }
    }
  },

  /**
   * renders the data into the initialized template
   * 
   * @param {String} value
   * @param {Object} cell
   * @param {Ext.data.Record} record
   * @param {Number} row
   * @param {Number} col
   * @param {Ext.data.Store} store
   * 
   * @return {String}
   */
  renderColumn: function renderColumn(value, cell, record, row, col, store) {
    return this.tpl.apply({
      data: record.data
    });
  },

  /**
   * initializes the template and sets actionHandlers
   */
  initTemplate: function initTemplate() {
    var actions = [];
    this.actionHandlers = []; // put each action into a template

    Ext.each(this.actions, function (a, i) {
      var action = {
        cls: a.iconCls ? a.iconCls : '',
        text: a.text ? a.text : '  ',
        qtip: a.tooltip ? Ext.util.Format.htmlEncode(Ext.util.Format.htmlEncode(a.tooltip)) : null,
        actionName: a.name
      };
      this.actionHandlers[a.name] = a.callback;
      actions.push(action);
    }, this);
    this.tpl = new Ext.XTemplate(new Ext.XTemplate(this.templateHTML).apply({
      actions: actions
    }));
  }
});
Ext.ComponentMgr.registerPlugin('grid-actioncolumn', Ext.ux.grid.ActionColumnPlugin);

/***/ }),
/* 1153 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.grid');
/**
 * Class for creating a edittable grid with quick add row on top.
 * <p>As form field for the quick add row, the quickaddField of the column definition is used.<p>
 * <p>The event 'newentry' is fired after the user finished editing the new row.<p>
 * <p>Example usage:</p>
 * <pre><code>
 var g =  new Ext.ux.grid.QuickaddGridPanel({
     ...
     quickaddMandatory: 'summary',
     columns: [
         {
             ...
             id: 'summary',
             quickaddField = new Ext.form.TextField({
                 emptyText: 'Add a task...'
             })
         },
         {
             ...
             id: 'due',
             quickaddField = new Ext.form.DateField({
                 ...
             })
         }
     ]
 });
 * </code></pre>
 *
 * @namespace   Ext.ux.grid
 * @class       Ext.ux.grid.QuickaddGridPanel
 * @extends     Ext.grid.EditorGridPanel
 */

Ext.ux.grid.QuickaddGridPanel = Ext.extend(Ext.grid.EditorGridPanel, {
  /**
   * @cfg {String} quickaddMandatory 
   * Mandatory field which must be set before quickadd fields will be enabled
   */
  quickaddMandatory: false,

  /**
   * if set, the quickadd fields are validated on blur
   * @type Boolean
   */
  validate: false,

  /**
   * @cfg {Bool} resetAllOnNew
   * reset all fields after new record got created (per default only den mandatory field gets resetted).
   */
  resetAllOnNew: false,

  /**
   * @property {Bool} adding true if a quickadd is in process
   */
  adding: false,
  parentScope: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.idPrefix = Ext.id();
    Ext.ux.grid.QuickaddGridPanel.superclass.initComponent.call(this);
    this.addEvents(
    /**
     * @event newentry
     * Fires when add process is finished 
     * @param {Object} data of the new entry
     */
    'newentry');
    this.cls = 'x-grid3-quickadd'; // The customized header template

    this.initTemplates(); // add our fields after view is rendered

    this.getView().afterRender = this.getView().afterRender.createSequence(this.renderQuickAddFields, this);

    if (!this.autoExpandColumn && this.quickaddMandatory) {
      this.autoExpandColumn = this.quickaddMandatory;
    } // init handlers


    this.quickaddHandlers = {
      scope: this,
      blur: function blur(field) {
        this.doBlur.defer(250, this);
      },
      specialkey: function specialkey(f, e) {
        var key = e.getKey();

        switch (key) {
          case e.ENTER:
            e.stopEvent();
            f.el.blur();

            if (f.triggerBlur) {
              f.triggerBlur();
            }

            break;

          case e.ESC:
            e.stopEvent();
            f.setValue('');
            f.el.blur();
            break;
        }
      }
    };
    this.on('beforeedit', this.onBeforeEdit, this);
    this.on('validateedit', this.onValidateEdit, this);
  },

  /**
   * renders the quick add fields
   */
  renderQuickAddFields: function renderQuickAddFields() {
    Ext.each(this.getCols(), function (column) {
      if (column.quickaddField) {
        column.quickaddField.render(this.getQuickAddWrap(column));
        column.quickaddField.setDisabled(this.readOnly || column.id != this.quickaddMandatory);
        column.quickaddField.on(this.quickaddHandlers);
      }
    }, this);
    this.colModel.on('configchange', this.syncFields, this); //this.colModel.on('widthchange', this.syncFields, this);

    this.colModel.on('hiddenchange', this.syncFields, this);
    this.on('resize', this.syncFields);
    this.on('columnresize', this.syncFields);
    this.colModel.on('columnmoved', this.syncFields, this);
    this.view.on('beforerefresh', this.onBeforeRefresh, this);
    this.view.on('refresh', this.onRefresh, this);
    this.syncFields();
    this.colModel.getColumnById(this.quickaddMandatory).quickaddField.on('focus', this.onMandatoryFocus, this);
  },
  onValidateEdit: function onValidateEdit(o) {
    var _ = window.lodash,
        me = this,
        fieldDef = _.isFunction(_.get(me, 'recordClass.getField')) ? _.get(me.recordClass.getField(o.field), 'fieldDefinition') : null;

    if (_.get(fieldDef, 'type') == 'record') {
      var col = _.find(me.getCols(), {
        dataIndex: o.field
      }),
          recordData = _.get(col, 'editor.field.selectedRecord.data'); // o.record.setValue(o.field, recordData);


      o.value = recordData ? recordData : o.value;
    }
  },

  /**
   * @private
   */
  doBlur: function doBlur() {
    // check if all quickadd fields are blured, validate them if required
    var focusedOrInvalid;
    Ext.each(this.getCols(true), function (item) {
      if (item.quickaddField && (item.quickaddField.hasFocus || item.quickaddField.hasFocusedSubPanels || this.validate && !item.quickaddField.isValid())) {
        focusedOrInvalid = true;
      }
    }, this); // only fire a new record if no quickaddField is focused

    if (!focusedOrInvalid) {
      var data = {};
      Ext.each(this.getCols(true), function (item) {
        if (item.quickaddField) {
          data[item.id] = item.quickaddField.selectedRecord ? item.quickaddField.selectedRecord.data : item.quickaddField.getValue(); // NOTE quickAddField might set more data at once

          if (item.quickaddField.getQuickAddRecordData) {
            Ext.apply(data, item.quickaddField.getQuickAddRecordData(this));
          }

          item.quickaddField.setDisabled(item.id != this.quickaddMandatory);
        }
      }, this);

      if (this.colModel.getColumnById(this.quickaddMandatory).quickaddField.getValue() != '') {
        if (this.fireEvent('newentry', data)) {
          var quickAddField = this.colModel.getColumnById(this.quickaddMandatory).quickaddField;

          if (quickAddField.resetOnNew !== false) {
            quickAddField.setValue('');

            if (this.validate) {
              quickAddField.clearInvalid();
            }
          }

          if (this.resetAllOnNew) {
            var columns = this.colModel.config;

            for (var i = 0, len = columns.length; i < len; i++) {
              if (columns[i].quickaddField != undefined) {
                if (columns[i].quickaddField.xtype === 'extuxmoneyfield') {
                  // prevent 0,00 € in moneyfields
                  columns[i].quickaddField.setRawValue('');
                } else {
                  columns[i].quickaddField.setValue('');
                }
              }
            }
          }
        }
      }

      this.adding = false;
    }
  },

  /**
   * gets columns
   * 
   * @param {Boolean} visibleOnly
   * @return {Array}
   */
  getCols: function getCols(visibleOnly) {
    if (visibleOnly === true) {
      var visibleCols = [];
      Ext.each(this.colModel.config, function (column) {
        if (!column.hidden) {
          visibleCols.push(column);
        }
      }, this);
      return visibleCols;
    }

    return this.colModel.config;
  },

  /**
   * returns wrap el for quick add filed of given col
   * 
   * @param {Ext.grid.Colum} col
   * @return {Ext.Element}
   */
  getQuickAddWrap: function getQuickAddWrap(column) {
    return Ext.get(this.idPrefix + column.id);
  },

  /**
   * @private
   */
  initTemplates: function initTemplates() {
    this.getView().templates = this.getView().templates ? this.getView().templates : {};
    var ts = this.getView().templates;
    var newRows = '';
    var cm = this.colModel;
    var ncols = cm.getColumnCount();

    for (var i = 0; i < ncols; i++) {
      var colId = cm.getColumnId(i);
      newRows += '<td><div class="x-small-editor" id="' + this.idPrefix + colId + '"></div></td>';
    }

    ts.header = new Ext.Template('<table border="0" cellspacing="0" cellpadding="0" style="{tstyle}">', '<thead><tr class="x-grid3-hd-row">{cells}</tr></thead>', '<tbody><tr class="new-row">', newRows, '</tr></tbody>', '</table>');
  },

  /**
   * @private
   */
  syncFields: function syncFields() {
    var newRowEl = Ext.get(Ext.DomQuery.selectNode('tr[class=new-row]', this.getView().mainHd.dom));
    var columns = this.getCols();

    for (var column, tdEl, i = columns.length - 1; i >= 0; i--) {
      column = columns[i];
      var tdEl = this.getQuickAddWrap(column).parent(); // resort columns

      newRowEl.insertFirst(tdEl); // set hidden state

      tdEl.dom.style.display = column.hidden ? 'none' : ''; // resize
      //tdEl.setWidth(column.width);

      if (column.quickaddField) {
        column.quickaddField.setSize(column.width - 1);
      }
    }
  },
  // save our editors - they get overwritten on hd-refresh
  onBeforeRefresh: function onBeforeRefresh() {
    Ext.each(this.getCols(), function (col) {
      if (col.quickaddField && col.quickaddField.rendered) {
        var el = col.quickaddField.el,
            hdEl = el.up('.x-grid3');
        hdEl.appendChild(col.quickaddField.wrap ? col.quickaddField.wrap : el);
      }
    }, this);
  },
  // restore editors
  onRefresh: function onRefresh() {
    Ext.each(this.getCols(), function (col) {
      if (col.quickaddField && col.quickaddField.rendered) {
        var wrap = this.getQuickAddWrap(col);
        wrap.appendChild(col.quickaddField.wrap ? col.quickaddField.wrap : col.quickaddField.el);
      }
    }, this);
  },

  /**
   * @private
   */
  onMandatoryFocus: function onMandatoryFocus() {
    if (this.readOnly) {
      return;
    }

    this.adding = true;
    Ext.each(this.getCols(true), function (item) {
      if (item.quickaddField) {
        item.quickaddField.setDisabled(false);
      }
    }, this);
  },
  beforeDragDrop: function beforeDragDrop() {
    if (this.readOnly) {
      return false;
    }
  },
  onBeforeEdit: function onBeforeEdit(o) {
    if (this.readOnly) {
      o.cancel = true;
    }
  },
  setReadOnly: function setReadOnly(readOnly) {
    this.readOnly = readOnly;
    Ext.each(this.getCols(true), function (item) {
      if (item.quickaddField) {
        item.quickaddField.setDisabled(readOnly || item.id != this.quickaddMandatory);
      }
    }, this);
  }
});

/***/ }),
/* 1154 */
/***/ (function(module, exports) {

/*
 * Ext JS Library 2.1
 * Copyright(c) 2006-2008, Ext JS, LLC.
 * licensing@extjs.com
 * 
 * http://extjs.com/license
 */

/**
 * @namespace   Ext.ux.grid
 * @class       Ext.ux.grid.RowExpander
 * @extends     Ext.util.Observable
 */
Ext.ux.grid.RowExpander = function (config) {
  Ext.apply(this, config);
  this.addEvents({
    beforeexpand: true,
    expand: true,
    beforecollapse: true,
    collapse: true
  });
  Ext.ux.grid.RowExpander.superclass.constructor.call(this);

  if (this.tpl) {
    if (typeof this.tpl == 'string') {
      this.tpl = new Ext.Template(this.tpl);
    }

    this.tpl.compile();
  }

  this.state = {};
  this.bodyContent = {};
};

Ext.extend(Ext.ux.grid.RowExpander, Ext.util.Observable, {
  header: "",
  width: 20,
  sortable: false,
  fixed: true,
  dataIndex: '',
  id: 'expander',
  lazyRender: true,
  enableCaching: false,
  getRowClass: function getRowClass(record, rowIndex, p, ds) {
    p.cols = p.cols - 1;
    var content = this.bodyContent[record.id];

    if (!content && !this.lazyRender) {
      content = this.getBodyContent(record, rowIndex);
    }

    if (content) {
      p.body = content;
    }

    return this.state[record.id] ? 'x-grid3-row-expanded' : 'x-grid3-row-collapsed';
  },
  init: function init(grid) {
    this.grid = grid;
    var view = grid.getView();
    view.getRowClass = this.getRowClass.createDelegate(this);
    view.enableRowBody = true;
    grid.on('render', function () {
      view.mainBody.on('mousedown', this.onMouseDown, this);
    }, this);
  },
  getBodyContent: function getBodyContent(record, index) {
    if (!this.enableCaching) {
      return this.tpl.apply(record.data);
    }

    var content = this.bodyContent[record.id];

    if (!content) {
      content = this.tpl.apply(record.data);
      this.bodyContent[record.id] = content;
    }

    return content;
  },
  onMouseDown: function onMouseDown(e, t) {
    if (t.className == 'x-grid3-row-expander') {
      e.stopEvent();
      var row = e.getTarget('.x-grid3-row');
      this.toggleRow(row);
    }
  },
  renderer: function renderer(v, p, record) {
    p.cellAttr = 'rowspan="2"';
    return '<div class="x-grid3-row-expander">&#160;</div>';
  },
  beforeExpand: function beforeExpand(record, body, rowIndex) {
    if (this.fireEvent('beforexpand', this, record, body, rowIndex) !== false) {
      if (this.tpl && this.lazyRender) {
        body.innerHTML = this.getBodyContent(record, rowIndex);
      }

      return true;
    } else {
      return false;
    }
  },
  toggleRow: function toggleRow(row) {
    if (typeof row == 'number') {
      row = this.grid.view.getRow(row);
    }

    this[Ext.fly(row).hasClass('x-grid3-row-collapsed') ? 'expandRow' : 'collapseRow'](row);
  },
  expandRow: function expandRow(row) {
    if (typeof row == 'number') {
      row = this.grid.view.getRow(row);
    }

    var record = this.grid.store.getAt(row.rowIndex);
    var body = Ext.DomQuery.selectNode('tr:nth(2) div.x-grid3-row-body', row);

    if (this.beforeExpand(record, body, row.rowIndex)) {
      this.state[record.id] = true;
      Ext.fly(row).replaceClass('x-grid3-row-collapsed', 'x-grid3-row-expanded');
      this.fireEvent('expand', this, record, body, row.rowIndex);
    }
  },
  collapseRow: function collapseRow(row) {
    if (typeof row == 'number') {
      row = this.grid.view.getRow(row);
    }

    var record = this.grid.store.getAt(row.rowIndex);
    var body = Ext.fly(row).child('tr:nth(1) div.x-grid3-row-body', true);

    if (this.fireEvent('beforcollapse', this, record, body, row.rowIndex) !== false) {
      this.state[record.id] = false;
      Ext.fly(row).replaceClass('x-grid3-row-expanded', 'x-grid3-row-collapsed');
      this.fireEvent('collapse', this, record, body, row.rowIndex);
    }
  }
});

/***/ }),
/* 1155 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @subpackage  widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.grid');
/**
 * Paging toolbar with build in selection support
 *
 * @namespace   Ext.ux.grid
 * @class       Ext.ux.grid.PagingToolbar
 * @extends     Ext.PagingToolbar
 * @constructor
 * @param       {Object} config
 */

Ext.ux.grid.PagingToolbar = Ext.extend(Ext.PagingToolbar, {
  /**
   * @cfg {Bool} displayPageInfo 
   * True to display the displayMsg (defaults to false)
   */
  displayPageInfo: false,

  /**
   * @cfg {Bool} displaySelectionHelper
   * True to display the selectionMsg (defaults to false)
   */
  displaySelectionHelper: false,

  /**
   * @cfg {Ext.grid.AbstractSelectionModel}
   */
  sm: null,

  /**
   * if this paging toolbar belongs to a nested grid, this must set to true to disable the reload
   * 
   * @type Boolean
   */
  nested: false,

  /**
   * @cfg {Bool} disableSelectAllPages
   */
  disableSelectAllPages: false,
  canonicalName: 'PagingToolbar',

  /**
   * @private
   */
  initComponent: function initComponent() {
    // initialise i18n
    this.selHelperText = {
      'main': i18n._('{0} selected'),
      'deselect': i18n._('Unselect all'),
      'selectall': i18n._('Select all pages ({0} records)'),
      'toggle': i18n._('Toggle selection')
    };
    Ext.ux.grid.PagingToolbar.superclass.initComponent.call(this); // if the grid is nested in an editdialog, disable refresh
    // TODO: remove this when using memoryproxy

    if (this.nested) {
      this.refresh.disable();
      this.refresh.addClass('x-ux-pagingtb-refresh-disabled');
    }
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Ext.ux.grid.PagingToolbar.superclass.onRender.call(this, ct, position);

    if (this.displaySelectionHelper) {
      this.renderSelHelper();
    }
  },

  /**
   * @private
   */
  renderSelHelper: function renderSelHelper() {
    this.deselectBtn = new Ext.Action({
      iconCls: 'x-ux-pagingtb-deselect',
      text: this.getSelHelperText('deselect'),
      scope: this,
      handler: function handler() {
        this.sm.clearSelections();
      }
    });
    this.selectAllPages = new Ext.Action({
      iconCls: 'x-ux-pagingtb-selectall',
      text: this.getSelHelperText('selectall'),
      scope: this,
      disabled: this.disableSelectAllPages,
      handler: function handler() {
        this.sm.selectAll();
      }
    });
    this.toggleSelectionBtn = new Ext.Action({
      iconCls: 'x-ux-pagingtb-toggle',
      text: this.getSelHelperText('toggle'),
      scope: this,
      handler: function handler() {
        this.sm.toggleSelection();
      }
    });
    this.addSeparator();
    this.selHelperBtn = new Ext.Action({
      xtype: 'tbsplit',
      text: this.getSelHelperText('main'),
      iconCls: 'x-ux-pagingtb-main',
      menu: new Ext.menu.Menu({
        items: [this.deselectBtn, this.selectAllPages, this.toggleSelectionBtn]
      })
    });
    this.add(this.selHelperBtn); // update buttons when data or selection changes

    this.sm.on('selectionchange', this.updateSelHelper, this);
    this.store.on('load', this.updateSelHelper, this);
  },

  /**
   * update all button descr.
   */
  updateSelHelper: function updateSelHelper() {
    this.selHelperBtn.setText(this.getSelHelperText('main'));
    this.selectAllPages.setText(this.getSelHelperText('selectall'));
  },

  /**
   * get test for button
   * @param {String} domain 
   * @return {String}
   */
  getSelHelperText: function getSelHelperText(domain) {
    var num;

    switch (domain) {
      case 'main':
        num = this.sm.getCount();
        break;

      case 'selectall':
        num = this.store.getTotalCount();
        break;

      default:
        return this.selHelperText[domain];
        break;
    }

    return String.format(this.selHelperText[domain], num);
  }
});

/***/ }),
/* 1156 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.grid');
/**
 * Grid Drop Zone
 * 
 * @param {Ext.grid.GridPanel} grid
 * @param {Object} config
 */

Ext.ux.grid.GridDropZone = function (grid, config) {
  this.view = grid.getView();
  this.grid = grid;
  Ext.ux.grid.GridDropZone.superclass.constructor.call(this, this.view.mainBody.dom, config);
};

Ext.extend(Ext.ux.grid.GridDropZone, Ext.dd.DropZone, {
  getTargetFromEvent: function getTargetFromEvent(e) {
    return e.getTarget(this.view.rowSelector);
  },
  onNodeEnter: function onNodeEnter(target, dd, e, data) {//Ext.fly(target).addClass('x-grid3-row-selected');
  },
  onNodeOut: function onNodeOut(target, dd, e, data) {
    this.removeDropIndicators(target); //Ext.fly(target).removeClass('x-grid3-row-selected');
  },
  onNodeOver: function onNodeOver(target, dd, e, data) {
    var pt = this.getDropPoint(e, target, dd),
        returnCls = this.dropNotAllowed,
        cls;

    if (this.isValidDropPoint(target, pt, dd, e, data)) {
      if (pt == "above") {
        returnCls = this.view.findRowIndex(target) === 0 ? "x-tree-drop-ok-above" : "x-tree-drop-ok-between";
        cls = "x-grid3-drag-insert-above";
      } else if (pt == "below") {
        returnCls = this.view.findRowIndex(target) === this.grid.getStore().getCount() - 1 ? "x-tree-drop-ok-below" : "x-tree-drop-ok-between";
        cls = "x-grid3-drag-insert-below";
      } else {
        returnCls = "x-tree-drop-ok-append";
        cls = "x-grid3-drag-append";
      }

      if (this.lastInsertClass != cls) {
        Ext.fly(target).replaceClass(this.lastInsertClass, cls);
        this.lastInsertClass = cls;
      }
    }

    return returnCls;
  },
  removeDropIndicators: function removeDropIndicators(target) {
    if (target) {
      Ext.fly(target).removeClass(["x-grid3-drag-insert-above", "x-grid3-drag-insert-below", "x-grid3-drag-append"]);
      this.lastInsertClass = "_noclass";
    }
  },
  getDropPoint: function getDropPoint(e, target, dd) {
    var dragEl = dd.ddel,
        t = Ext.lib.Dom.getY(target),
        b = t + target.offsetHeight,
        y = Ext.lib.Event.getPageY(e),
        q = (b - t) / 2;
    return y > t + q ? "below" : "above";
  },
  isValidDropPoint: function isValidDropPoint(target, pt, dd, e, data) {
    return true;
  }
});

/***/ }),
/* 1157 */
/***/ (function(module, exports) {

/**
 * Ext.ux.grid.GridViewMenuPlugin
 * Copyright (c) 2008, http://www.siteartwork.de
 *
 * Ext.ux.grid.GridViewMenuPlugin is licensed under the terms of the
 *                  GNU Open Source LGPL 3.0
 * license.
 *
 * This program is free software: you can redistribute it and/or modify it under
 * the terms of the LGPL as published by the Free Software
 * Foundation, either version 3 of the License, or any later version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the LGPL License for more
 * details.
 *
 * You should have received a copy of the GNU LGPL along with
 * this program. If not, see <http://www.gnu.org/licenses/lgpl.html>.
 *
 */
Ext.ns('Ext.ux.grid');
/**
 * Renders a menu button to the upper right corner of the grid this plugin is
 * bound to. The menu items will represent the column model and hide/show
 * the columns on click.
 *
 * Note that you have to set the enableHdMenu-property of the bound grid to
 * "false" so this plugin does not interfere with the header menus of the grid's view.
 *
 * @namespace   Ext.ux.grid
 * @class       Ext.ux.grid.GridViewMenuPlugin
 * @extends     Object
 * @constructor
 *
 * @author Thorsten Suckow-Homberg <ts@siteartwork.de>
 */

Ext.ux.grid.GridViewMenuPlugin = Ext.extend(Object, {
  /**
   * The {Ext.grid.GridView} this plugin is bound to.
   * @type {Ext.grid.GridView}
   * @protected
   */
  _view: null,

  /**
   * The menu button that gets rendered to the upper right corner of the
   * grid's view.
   * @type {Ext.Element}
   * @protected
   */
  _menuBtn: null,

  /**
   * The menu that will be shown when the menu button gets clicked.
   * Named after the "colModel" property of the grid's view so this plugin
   * can easily operate in the scope of the view.
   * @type {Ext.Menu}
   */
  colMenu: null,

  /**
   * The column model of the grid this plugin is bound to.
   * Named after the "cm" property of the grid's view so this plugin
   * can easily operate in the scope of the view.
   * @type {Ext.grid.ColumnModel}
   */
  cm: null,

  /**
   * Inits this plugin.
   * Method is API-only. Will be called automatically from the grid this
   * plugin is bound to.
   *
   * @param {Ext.grid.GridPanel} grid
   *
   * @throws {Exception} throws an exception if the plugin recognizes the
   * grid's "enableHdMenu" property to be set to "true"
   */
  init: function init(grid) {
    var v = this._view = grid.getView();
    v.afterMethod('initElements', this.initElements, this);
    v.afterMethod('initData', this.initData, this);
    v.afterMethod('onLayout', this._onLayout, this);
    v.beforeMethod('destroy', this._destroy, this);
    this.colMenu = new Ext.menu.Menu({
      listeners: {
        scope: this,
        beforeshow: this._beforeColMenuShow,
        itemclick: this._handleHdMenuClick
      }
    });
    this.colMenu.override({
      show: function show(el, pos, parentMenu) {
        this.parentMenu = parentMenu;

        if (!this.el) {
          this.render();
        }

        this.fireEvent("beforeshow", this); // show menu and constrain to viewport if necessary
        // ( + minor offset adjustments for pixel perfection)

        this.showAt(this.el.getAlignToXY(el, pos || this.defaultAlign, [Ext.isWebKit ? 2 : 1, 0]), parentMenu, true // true to constrain
        );
      }
    });
  },
  // -------- listeners

  /**
   * Callback for the itemclick event of the menu.
   * Default implementation calls the view's handleHdMenuClick-method in the
   * scope of the view itself.
   *
   * @param {Ext.menu.BaseItem baseItem} item
   * @param {Ext.EventObject} e
   *
   * @return {Boolean} returns false if hiding the column represented by the
   * column is not allowed, otherwise true
   *
   * @protected
   */
  _handleHdMenuClick: function _handleHdMenuClick(item, e) {
    if (this.colMenu.items.indexOf(item) > 1) {
      return this._view.handleHdMenuClick(item, e);
    }
  },

  /**
   * Listener for the beforeshow-event of the menu.
   * Default implementation calls the view's beforeColMenuShow-method
   * in the scope of this plugin.
   *
   * Overwrite this for custom behavior.
   *
   * @param {Ext.menu.Menu} menu
   *
   * @protected
   */
  _beforeColMenuShow: function _beforeColMenuShow(menu) {
    this._view.beforeColMenuShow.call(this, menu); // menu title tweak


    this.colMenu.insert(0, new Ext.menu.Separator());
    this.colMenu.insert(0, new Ext.menu.TextItem({
      text: String.format('<img src="{0}" class="x-menu-item-icon x-cols-icon" />{1}', Ext.BLANK_IMAGE_URL, this._view.columnsText),
      style: 'line-height:16px;padding:3px 21px 3px 27px;'
    }));
  },

  /**
   * Listener for the click event of the menuBtn element.
   * Used internally to show the menu.
   *
   * @param {Ext.EventObject} e
   * @param {HtmlElement} t
   *
   * @protected
   */
  _handleHdDown: function _handleHdDown(e, t) {
    if (Ext.fly(t).hasClass('x-grid3-hd-btn')) {
      e.stopEvent();
      this.colMenu.show(t, "tr-br?");
    }
  },
  // -------- helpers

  /**
   * Builds the element that gets added to teh grid's header for showing
   * the menu.
   * The default implementation will render the menu button into the upper
   * right corner of the grid.
   * Overwrite for custom behavior.
   *
   * @return {Ext.Element}
   *
   * @protected
   */
  _getMenuButton: function _getMenuButton() {
    var a = document.createElement('a');
    a.className = 'ext-ux-grid-gridviewmenuplugin-menuBtn x-grid3-hd-btn';
    a.href = '#';
    return new Ext.Element(a);
  },

  /**
   * Sequenced function for storing the view's cm property,
   * Called in the scope of this plugin.
   */
  initData: function initData() {
    this.cm = this._view.cm;
  },

  /**
   * Sequenced function for adding the menuBtn to the grid's header.
   * Called in the scope of this plugin.
   */
  initElements: function initElements() {
    this.menuBtn = this._getMenuButton();

    this._view.mainHd.dom.appendChild(this.menuBtn.dom);

    this.menuBtn.on("click", this._handleHdDown, this);
  },

  /**
   * sets the buttons size
   */
  _onLayout: function _onLayout() {
    // Note: if hidden, IE returns no offsetHeight and also can not set it
    if (this._view.mainHd.dom.offsetHeight > 1) {
      this.menuBtn.dom.style.height = this._view.mainHd.dom.offsetHeight - 1 + 'px';
    }
  },

  /**
   * Hooks into the view's destroy method and removes the menu and the menu
   * button.
   *
   * @protected
   */
  _destroy: function _destroy() {
    if (this.colMenu) {
      this.colMenu.removeAll();
      Ext.menu.MenuMgr.unregister(this.colMenu);

      if (this.colMenu.getEl()) {
        this.colMenu.getEl().remove();
      }

      delete this.colMenu;
    }

    if (this._menuBtn) {
      this._menuBtn.remove();

      delete this._menuBtn;
    }
  }
});

/***/ }),
/* 1158 */
/***/ (function(module, exports) {

/**
 * Original version by harley.333
 * Updated 5/6/2011 by taylorbarstow
 *
 * FOUND HERE: http://www.sencha.com/forum/showthread.php?53118-Multiple-Cells-Selection-Model
 *
 * @licence @see https://www.sencha.com/legal/terms-of-use/
 *   Code posted on Sencha Forum is made available as is and we license to customers any
 *   rights we may have to such code under our commercial license agreement. This Code is
 *   not officially supported. Any such code is subject to the restrictions of the license
 *   for the related Sencha product.
 *
 * @class Ext.ux.grid.MultiCellSelectionModel
 * @extends Ext.grid.AbstractSelectionModel
 * Supports multiple selections and keyboard selection/navigation.
 * @constructor
 * @param {Object} config
 */
Ext.ux.grid.MultiCellSelectionModel = function (config) {
  Ext.apply(this, config);
  this.selections = [];
  this.last = false;
  this.lastActive = false;
  this.addEvents(
  /**
   * @event selectionchange
   * Fires when the selection changes
   * @param {SelectionModel} this
   * @param {Array} selections A multi-dimensional array containing the indices of all selected cells ([[0,0],[1,1]])
   */
  "selectionchange",
  /**
   * @event beforecellselect
   * Fires when a cell is being selected, return false to cancel.
   * @param {Ext.ux.grid.MultiCellSelectionModel} this
   * @param {Array} cellInfo An array of cell indices ([rowIndex, columnIndex])
   * @param {Boolean} keepExisting False if other selections will be cleared
   */
  "beforecellselect",
  /**
   * @event cellselect
   * Fires when a cell is selected.
   * @param {Ext.ux.grid.MultiCellSelectionModel} this
   * @param {Array} cellInfo An array of cell indices ([rowIndex, columnIndex])
   */
  "cellselect",
  /**
   * @event celldeselect
   * Fires when a cell is deselected.
   * @param {Ext.ux.grid.MultiCellSelectionModel} this
   * @param {Array} cellInfo An array of cell indices ([rowIndex, columnIndex])
   */
  "celldeselect");
  Ext.ux.grid.MultiCellSelectionModel.superclass.constructor.call(this);
};

Ext.extend(Ext.ux.grid.MultiCellSelectionModel, Ext.grid.AbstractSelectionModel, {
  /**
   * @cfg {Boolean} singleSelect
   * True to allow selection of only one cell at a time (defaults to false)
   */
  singleSelect: false,

  /**
   * @cfg {Boolean} moveEditorOnEnter
   * False to turn off moving the editor to the next cell when the enter key is pressed
   */
  // private
  initEvents: function initEvents() {
    if (!this.grid.enableDragDrop && !this.grid.enableDrag) {
      this.grid.on("cellmousedown", this.handleMouseDown, this);
    } else {
      // allow click to work like normal
      this.grid.on("cellclick", function (grid, rowIndex, columnIndex, e) {
        if (e.button === 0 && !e.shiftKey && !e.ctrlKey) {
          this.selectCell([rowIndex, columnIndex], false);
          grid.view.focusCell(rowIndex, columnIndex);
        }
      }, this);
    }

    this.rowNav = new Ext.KeyNav(this.grid.getGridEl(), {
      "up": function up(e) {
        if (this.last == false) {
          this.selectCell([0, 0]);
        } else if (this.lastActive[0] == 0) {
          if (!e.shiftKey) {
            var row = this.lastActive[0],
                col = this.lastActive[1];
            this.clearSelections();
            this.selectCell([row, col]);
            this.grid.getView().focusCell(row, col);
          }

          return;
        } else {
          var row, col;
          row = this.lastActive[0] - 1;
          col = this.lastActive[1];

          if (!e.shiftKey) {
            this.clearSelections();
            this.selectCell([row, col]);
          } else {
            var last = this.last;
            this.selectRange(this.last, [row, col]);
            this.last = last;
          }

          this.grid.getView().focusCell(row, col);
          this.lastActive = [row, col];
        }
      },
      "down": function down(e) {
        if (this.last == false) {
          this.selectCell([0, 0]);
        } else if (this.lastActive[0] == this.grid.getStore().getCount() - 1) {
          if (!e.shiftKey) {
            var row = this.lastActive[0],
                col = this.lastActive[1];
            this.clearSelections();
            this.selectCell([row, col]);
            this.grid.getView().focusCell(row, col);
          }

          return;
        } else {
          var row, col;
          row = this.lastActive[0] + 1;
          col = this.lastActive[1];

          if (!e.shiftKey) {
            this.clearSelections();
            this.selectCell([row, col]);
          } else {
            var last = this.last;
            this.selectRange(this.last, [row, col]);
            this.last = last;
          }

          this.grid.getView().focusCell(row, col);
          this.lastActive = [row, col];
        }
      },
      "left": function left(e) {
        if (this.last == false) {
          this.selectCell([0, 0]);
        } else if (this.lastActive[1] == 0) {
          if (!e.shiftKey) {
            var row = this.lastActive[0],
                col = this.lastActive[1];
            this.clearSelections();
            this.selectCell([row, col]);
            this.grid.getView().focusCell(row, col);
          }

          return;
        } else {
          var row, col;
          row = this.lastActive[0];
          col = this.lastActive[1] - 1;

          if (!e.shiftKey) {
            this.clearSelections();
            this.selectCell([row, col]);
          } else {
            var last = this.last;
            this.selectRange(this.last, [row, col]);
            this.last = last;
          }

          this.grid.getView().focusCell(row, col);
          this.lastActive = [row, col];
        }
      },
      "right": function right(e) {
        if (this.last == false) {
          this.selectCell([0, 0]);
        } else if (this.lastActive[1] == this.grid.getColumnModel().getColumnCount() - 1) {
          if (!e.shiftKey) {
            var row = this.lastActive[0],
                col = this.lastActive[1];
            this.clearSelections();
            this.selectCell([row, col]);
            this.grid.getView().focusCell(row, col);
          }

          return;
        } else {
          var row, col;
          row = this.lastActive[0];
          col = this.lastActive[1] + 1;

          if (!e.shiftKey) {
            this.clearSelections();
            this.selectCell([row, col]);
          } else {
            var last = this.last;
            this.selectRange(this.last, [row, col]);
            this.last = last;
          }

          this.grid.getView().focusCell(row, col);
          this.lastActive = [row, col];
        }
      },
      scope: this
    });
    var view = this.grid.view;
    view.on("refresh", this.onRefresh, this);
    view.on("rowupdated", this.onRowUpdated, this);
    view.on("rowremoved", this.onRemove, this);
  },
  // private
  onRefresh: function onRefresh() {
    this.clearSelections();
  },
  //private
  onRowUpdated: function onRowUpdated(v, index, r) {
    var cols = this.grid.getColumnModel().getColumnCount();

    for (var i = 0; i < cols; i++) {
      if (this.isSelected([index, i])) {
        v.onCellSelect(index, i);
      }
    }
  },
  // private
  onRemove: function onRemove(v, index, r) {
    this.deselectRange([index, 0], [index, this.grid.getColumnModel().getColumnCount()]);
  },

  /**
   * Gets the number of selected cells.
   * @return {Number}
   */
  getCount: function getCount() {
    return this.selections.length;
  },

  /**
   * Selects the cell to the right of the last selected cell.
   * @param {Boolean} keepExisting (optional) True to keep existing selections
   * @return {Boolean} True if selection is successful, else false
   */
  selectRight: function selectRight(keepExisting) {
    if (this.hasNext()) {
      var row,
          col = this.last[1];

      if (col == this.grid.getColumnModel().getColumnCount() - 1) {
        row = this.last[0] + 1;
        col = 0;
      } else {
        row = this.last[0];
        col += 1;
      }

      this.selectCell([row, col], keepExisting);
      this.grid.getView().focusCell(this.last[0], this.last[1]);
      return true;
    }

    return false;
  },

  /**
   * Selects the cell underneath the last selected cell.
   * @param {Boolean} keepExisting (optional) True to keep existing selections
   * @return {Boolean} True if selection is successful, else false
   */
  selectDown: function selectDown(keepExisting) {
    var r,
        cols = this.grid.getColumnModel().getColumnCount();

    for (var i = 0; i < cols; i++) {
      r = this.selectRight(keepExisting);
      if (!r) break;
    }

    return r;
  },

  /**
   * Selects the cell above the last selected cell.
   * @param {Boolean} keepExisting (optional) True to keep existing selections
   * @return {Boolean} True if selection is successful, else false
   */
  selectUp: function selectUp(keepExisting) {
    var r,
        cols = this.grid.getColumnModel().getColumnCount();

    for (var i = 0; i < cols; i++) {
      r = this.selectLeft(keepExisting);
      if (!r) break;
    }

    return r;
  },

  /**
   * Selects the cell to the left of the last selected cell.
   * @param {Boolean} keepExisting (optional) True to keep existing selections
   * @return {Boolean} True if selection is successful, else false
   */
  selectLeft: function selectLeft(keepExisting) {
    if (this.hasPrevious()) {
      var row,
          col = this.last[1];

      if (col == 0) {
        row = this.last[0] - 1;
        col = this.grid.getColumnModel().getColumnCount() - 1;
      } else {
        row = this.last[0];
        col -= 1;
      }

      this.selectCell([row, col], keepExisting);
      this.grid.getView().focusCell(this.last[0], this.last[1]);
      return true;
    }

    return false;
  },

  /**
   * Returns true if there is a next cell to select
   * @return {Boolean}
   */
  hasNext: function hasNext() {
    return this.last !== false && (this.last[0] + 1 < this.grid.store.getCount() || this.last[1] + 1 < this.grid.getColumnModel().getColumnCount());
  },

  /**
   * Returns true if there is a previous cell to select
   * @return {Boolean}
   */
  hasPrevious: function hasPrevious() {
    return this.last !== false && (this.last[0] != 0 || this.last[1] != 0);
  },

  /**
   * Returns the selected cell indices
   * @return {Array} Array of cell indices ([rowIndex, columnIndex])
   */
  getSelections: function getSelections() {
    return [].concat(this.selections);
  },

  /**
   * Returns the first selected cell index.
   * @return {Array} An array containing the row and column indexes of the first selected cell, or null if none selected.
   */
  getSelectedCell: function getSelectedCell() {
    return this.selections.length > 0 ? [].concat(this.selections[0]) : null;
  },
  getSelectedRecords: function getSelectedRecords() {
    const rs = [];

    _.each(this.getSelections(), cell => {
      const r = this.grid.store.getAt(cell[0]);

      if (rs.indexOf(r) < 0) {
        rs.push(r);
      }
    });

    return rs;
  },

  /**
   * Calls the passed function with each selection. If the function returns false, iteration is
   * stopped and this function returns false. Otherwise it returns true.
   * @param {Function} fn
   * @param {Object} scope (optional)
   * @return {Boolean} true if all selections were iterated
   */
  each: function each(fn, scope) {
    var s = this.getSelections();

    for (var i = 0, len = s.length; i < len; i++) {
      if (fn.call(scope || this, s[i], i) === false) {
        return false;
      }
    }

    return true;
  },

  /**
   * Clears all selections.
   */
  clearSelections: function clearSelections() {
    if (this.locked) return;

    for (var i = this.selections.length - 1; i >= 0; i--) {
      this.deselectCell(this.selections[i]);
    }

    this.selections = [];
    this.last = false;
  },

  /**
   * Selects all cells.
   */
  selectAll: function selectAll() {
    if (this.locked) return;
    this.selections = [];
    var row, col;
    var rowCount = this.grid.GetStore().getCount();
    var colCount = this.grid.GetColumnModel().getColumnCount();

    for (row = 0; row < rowCount; row++) {
      for (col = 0; col < colCount; col++) {
        this.selectCell([row, cell], true);
      }
    }
  },

  /**
   * Returns True if there is a selection.
   * @return {Boolean}
   */
  hasSelection: function hasSelection() {
    return this.selections.length > 0;
  },

  /**
   * Returns True if the specified cell is selected.
   * @param {Array/Record} record The cell-index ([rowIndex, columnIndex]) to check
   * @return {Boolean}
   */
  isSelected: function isSelected(index) {
    var s = this.selections;

    for (var i = 0; i < s.length; i++) {
      if (s[i][0] == index[0] && s[i][1] == index[1]) {
        return true;
      }
    }

    return false;
  },
  // private
  handleMouseDown: function handleMouseDown(g, rowIndex, columnIndex, e) {
    if (e.button !== 0 || this.isLocked()) {
      return;
    }

    ;
    var view = this.grid.getView();

    if (e.shiftKey && this.last !== false) {
      var last = this.last;
      this.selectRange(last, [rowIndex, columnIndex], e.ctrlKey);
      this.last = last; // reset the last

      this.lastActive = [rowIndex, columnIndex];
      view.focusCell(rowIndex, columnIndex);
    } else {
      var isSelected = this.isSelected([rowIndex, columnIndex]);

      if (e.ctrlKey && isSelected) {
        this.deselectCell([rowIndex, columnIndex]);
      } else if (!isSelected || this.getCount() > 1) {
        this.selectCell([rowIndex, columnIndex], e.ctrlKey || e.shiftKey);
        view.focusCell(rowIndex, columnIndex);
      }
    }
  },

  /**
   * Selects multiple cells.
   * @param {Array} cells Array of the indices ([rowIndex, columnIndex]) of the cells to select
   * @param {Boolean} keepExisting (optional) True to keep existing selections (defaults to false)
   */
  selectCells: function selectCells(cells, keepExisting) {
    if (!keepExisting) {
      this.clearSelections();
    }

    for (var i = 0, len = cells.length; i < len; i++) {
      this.selectCell(cells[i], true);
    }
  },

  /**
   * Selects a range of cells. All cells in between startCell and endCell are also selected.
   * @param {Array} startCell The index of the first cell ([rowIndex, columnIndex]) in the range
   * @param {Array} endCell The index of the last cell ([rowIndex, columnIndex]) in the range
   * @param {Boolean} keepExisting (optional) True to retain existing selections
   */
  selectRange: function selectRange(startCell, endCell, keepExisting) {
    if (this.locked) return;

    if (!keepExisting) {
      this.clearSelections();
    }

    var row, col, colCount;
    var startRow = startCell[0];
    var startCol = startCell[1];
    var endRow = endCell[0];
    var endCol = endCell[1];

    if (endRow < startRow) {
      // flip 'em
      row = endRow;
      endRow = startRow;
      startRow = row;
    }

    if (endCol < startCol) {
      // flip 'em
      col = endCol;
      endCol = startCol;
      startCol = col;
    }

    for (row = startRow; row <= endRow; row++) {
      for (col = startCol; col <= endCol; col++) {
        this.selectCell([row, col], true);
      }
    }
  },

  /**
   * Deselects a range of cells. All cells in between startCell and endCell are also deselected.
   * @param {Array} startCell The index of the first cell ([rowIndex, columnIndex]) in the range
   * @param {Array} endCell The index of the last cell ([rowIndex, columnIndex]) in the range
   */
  deselectRange: function deselectRange(startCell, endCell, preventViewNotify) {
    if (this.locked) return;
    var row, col, colCount;
    var startRow = startCell[0];
    var startCol = startCell[1];
    var endRow = endCell[0];
    var endCol = endCell[1];

    if (endRow < startRow) {
      // flip 'em
      row = endRow;
      endRow = startRow;
      startRow = row;
    }

    if (endCol < startCol) {
      // flip 'em
      col = endCol;
      endCol = startCol;
      startCol = col;
    }

    for (row = startRow; row <= endRow; row++) {
      for (col = startCol; col <= endCol; col++) {
        this.deselectCell([row, col], preventViewNotify);
      }
    }
  },

  /**
   * Selects a cell.
   * @param {Array} cell The index of the cell ([rowIndex, columnIndex]) to select
   * @param {Boolean} keepExisting (optional) True to keep existing selections
   */
  selectCell: function selectCell(index, keepExisting, preventViewNotify) {
    if (this.locked) return;
    if (this.isSelected(index)) return;
    var row = index[0];
    var col = index[1];
    if (row < 0 || row >= this.grid.store.getCount()) return;
    if (col < 0 || col >= this.grid.getColumnModel().getColumnCount()) return;

    if (this.fireEvent("beforecellselect", this, index, keepExisting) !== false) {
      if (!keepExisting || this.singleSelect) {
        this.clearSelections();
      }

      this.selections.push(index);
      this.last = this.lastActive = index;

      if (!preventViewNotify) {
        this.grid.getView().onCellSelect(row, col);
      }

      this.fireEvent("cellselect", this, index);
      this.fireEvent("selectionchange", this, [].concat(this.selections));
    }
  },

  /**
   * Deselects a cell.
   * @param {Array} cell The index of the cell ([rowIndex, columnIndex]) to deselect
   */
  deselectCell: function deselectCell(index, preventViewNotify) {
    if (this.locked) return;

    if (this.last[0] == index[0] && this.last[1] == index[1]) {
      this.last = false;
    }

    if (this.lastActive[0] == index[0] && this.lastActive[1] == index[1]) {
      this.lastActive = false;
    }

    var s = this.selections;

    for (var i = 0; i < s.length; i++) {
      if (s[i][0] == index[0] && s[i][1] == index[1]) {
        this.selections.remove(s[i]);

        if (!preventViewNotify) {
          this.grid.getView().onCellDeselect(index[0], index[1]);
        }

        this.fireEvent("celldeselect", this, index);
        this.fireEvent("selectionchange", this, [].concat(this.selections));
        return;
      }
    }
  },
  // private
  acceptsNav: function acceptsNav(row, col, cm) {
    return !cm.isHidden(col) && cm.isCellEditable(col, row);
  },
  // private
  onEditorKey: function onEditorKey(field, e) {
    var k = e.getKey(),
        newCell,
        g = this.grid,
        ed = g.activeEditor;
    var shift = e.shiftKey;

    if (k == e.TAB || k == e.ENTER) {
      e.stopEvent();
      g.stopEditing();
      this.clearSelections();
      var row,
          col,
          delta = shift ? -1 : 1;

      if (k == e.TAB) {
        newCell = g.walkCells(ed.row, ed.col + delta, delta, this.acceptsNav, this);
      } else {
        newCell = g.walkCells(ed.row + delta, ed.col, delta, this.acceptsNav, this);
      }

      if (newCell) {
        g.startEditing(newCell[0], newCell[1]);
      } else {
        this.selectCell([ed.row, ed.col]);
        g.getView().focusCell(ed.row, ed.col);
      }
    } else if (k == e.ESC) {
      g.stopEditing(true);
      this.selectCell([ed.row, ed.col]);
      g.getView().focusCell(ed.row, ed.col);
    }
  }
});

/***/ }),
/* 1159 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

var PseudoWorker = __webpack_require__(1160);

if (typeof Worker === 'undefined') {
  global.Worker = PseudoWorker;
}

module.exports = PseudoWorker;
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 1160 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
/* WEBPACK VAR INJECTION */(function(global) {

function doEval(self, __pseudoworker_script) {
  /* jshint unused:false */
  (function () {
    /* jshint evil:true */
    eval(__pseudoworker_script);
  }).call(global);
}

function PseudoWorker(path) {
  var messageListeners = [];
  var errorListeners = [];
  var workerMessageListeners = [];
  var workerErrorListeners = [];
  var postMessageListeners = [];
  var terminated = false;
  var script;
  var workerSelf;

  var api = this;

  // custom each loop is for IE8 support
  function executeEach(arr, fun) {
    var i = -1;
    while (++i < arr.length) {
      if (arr[i]) {
        fun(arr[i]);
      }
    }
  }

  function callErrorListener(err) {
    return function (listener) {
      listener({
        type: 'error',
        error: err,
        message: err.message
      });
    };
  }

  function addEventListener(type, fun) {
    /* istanbul ignore else */
    if (type === 'message') {
      messageListeners.push(fun);
    } else if (type === 'error') {
      errorListeners.push(fun);
    }
  }

  function removeEventListener(type, fun) {
      var listeners;
      /* istanbul ignore else */
      if (type === 'message') {
        listeners = messageListeners;
      } else if (type === 'error') {
        listeners = errorListeners;
      } else {
        return;
      }
      var i = -1;
      while (++i < listeners.length) {
        var listener = listeners[i];
        if (listener === fun) {
          delete listeners[i];
          break;
        }
      }
  }

  function postError(err) {
    var callFun = callErrorListener(err);
    if (typeof api.onerror === 'function') {
      callFun(api.onerror);
    }
    if (workerSelf && typeof workerSelf.onerror === 'function') {
      callFun(workerSelf.onerror);
    }
    executeEach(errorListeners, callFun);
    executeEach(workerErrorListeners, callFun);
  }

  function runPostMessage(msg, transfer) {
    function callFun(listener) {
      try {
        listener({data: msg, ports: transfer});
      } catch (err) {
        postError(err);
      }
    }
    if (workerSelf && typeof workerSelf.onmessage === 'function') {
      callFun(workerSelf.onmessage);
    }
    executeEach(workerMessageListeners, callFun);
  }

  function postMessage(msg, transfer) {
    if (typeof msg === 'undefined') {
      throw new Error('postMessage() requires an argument');
    }
    if (terminated) {
      return;
    }
    if (!script) {
      postMessageListeners.push({msg: msg, transfer: (transfer ? transfer : undefined)});
      return;
    }
    runPostMessage(msg, transfer);
  }

  function terminate() {
    terminated = true;
  }

  function workerPostMessage(msg) {
    if (terminated) {
      return;
    }
    function callFun(listener) {
      listener({
        data: msg
      });
    }
    if (typeof api.onmessage === 'function') {
      callFun(api.onmessage);
    }
    executeEach(messageListeners, callFun);
  }

  function workerAddEventListener(type, fun) {
    /* istanbul ignore else */
    if (type === 'message') {
      workerMessageListeners.push(fun);
    } else if (type === 'error') {
      workerErrorListeners.push(fun);
    }
  }

  var xhr = new XMLHttpRequest();

  xhr.open('GET', path);
  xhr.onreadystatechange = function () {
    if (xhr.readyState === 4) {
      if (xhr.status >= 200 && xhr.status < 400) {
        script = xhr.responseText;
        workerSelf = {
          postMessage: workerPostMessage,
          addEventListener: workerAddEventListener,
          close: terminate
        };
        doEval(workerSelf, script);
        var currentListeners = postMessageListeners;
        postMessageListeners = [];
        for (var i = 0; i < currentListeners.length; i++) {
          runPostMessage(currentListeners[i].msg, currentListeners[i].transfer);
        }
      } else {
        postError(new Error('cannot find script ' + path));
      }
    }
  };

  xhr.send();

  api.postMessage = postMessage;
  api.addEventListener = addEventListener;
  api.removeEventListener = removeEventListener;
  api.terminate = terminate;

  return api;
}

module.exports = PseudoWorker;

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 1161 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1162);
module.exports = __webpack_require__(119).Object.keys;


/***/ }),
/* 1162 */
/***/ (function(module, exports, __webpack_require__) {

// 19.1.2.14 Object.keys(O)
var toObject = __webpack_require__(610);
var $keys = __webpack_require__(236);

__webpack_require__(1166)('keys', function () {
  return function keys(it) {
    return $keys(toObject(it));
  };
});


/***/ }),
/* 1163 */
/***/ (function(module, exports, __webpack_require__) {

// fallback for non-array-like ES3 and non-enumerable old V8 strings
var cof = __webpack_require__(237);
// eslint-disable-next-line no-prototype-builtins
module.exports = Object('z').propertyIsEnumerable(0) ? Object : function (it) {
  return cof(it) == 'String' ? it.split('') : Object(it);
};


/***/ }),
/* 1164 */
/***/ (function(module, exports, __webpack_require__) {

// false -> Array#indexOf
// true  -> Array#includes
var toIObject = __webpack_require__(172);
var toLength = __webpack_require__(612);
var toAbsoluteIndex = __webpack_require__(1165);
module.exports = function (IS_INCLUDES) {
  return function ($this, el, fromIndex) {
    var O = toIObject($this);
    var length = toLength(O.length);
    var index = toAbsoluteIndex(fromIndex, length);
    var value;
    // Array#includes uses SameValueZero equality algorithm
    // eslint-disable-next-line no-self-compare
    if (IS_INCLUDES && el != el) while (length > index) {
      value = O[index++];
      // eslint-disable-next-line no-self-compare
      if (value != value) return true;
    // Array#indexOf ignores holes, Array#includes - not
    } else for (;length > index; index++) if (IS_INCLUDES || index in O) {
      if (O[index] === el) return IS_INCLUDES || index || 0;
    } return !IS_INCLUDES && -1;
  };
};


/***/ }),
/* 1165 */
/***/ (function(module, exports, __webpack_require__) {

var toInteger = __webpack_require__(400);
var max = Math.max;
var min = Math.min;
module.exports = function (index, length) {
  index = toInteger(index);
  return index < 0 ? max(index + length, 0) : min(index, length);
};


/***/ }),
/* 1166 */
/***/ (function(module, exports, __webpack_require__) {

// most Object methods by ES6 should accept primitives
var $export = __webpack_require__(132);
var core = __webpack_require__(119);
var fails = __webpack_require__(219);
module.exports = function (KEY, exec) {
  var fn = (core.Object || {})[KEY] || Object[KEY];
  var exp = {};
  exp[KEY] = exec(fn);
  $export($export.S + $export.F * fails(function () { fn(1); }), 'Object', exp);
};


/***/ }),
/* 1167 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1168);
var $Object = __webpack_require__(119).Object;
module.exports = function defineProperty(it, key, desc) {
  return $Object.defineProperty(it, key, desc);
};


/***/ }),
/* 1168 */
/***/ (function(module, exports, __webpack_require__) {

var $export = __webpack_require__(132);
// 19.1.2.4 / 15.2.3.6 Object.defineProperty(O, P, Attributes)
$export($export.S + $export.F * !__webpack_require__(167), 'Object', { defineProperty: __webpack_require__(165).f });


/***/ }),
/* 1169 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1170);

/***/ }),
/* 1170 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1171);
__webpack_require__(621);
__webpack_require__(1177);
__webpack_require__(1178);
module.exports = __webpack_require__(119).Symbol;


/***/ }),
/* 1171 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

// ECMAScript 6 symbols shim
var global = __webpack_require__(122);
var has = __webpack_require__(171);
var DESCRIPTORS = __webpack_require__(167);
var $export = __webpack_require__(132);
var redefine = __webpack_require__(614);
var META = __webpack_require__(1172).KEY;
var $fails = __webpack_require__(219);
var shared = __webpack_require__(402);
var setToStringTag = __webpack_require__(384);
var uid = __webpack_require__(380);
var wks = __webpack_require__(126);
var wksExt = __webpack_require__(615);
var wksDefine = __webpack_require__(406);
var enumKeys = __webpack_require__(1173);
var isArray = __webpack_require__(617);
var anObject = __webpack_require__(166);
var isObject = __webpack_require__(174);
var toIObject = __webpack_require__(172);
var toPrimitive = __webpack_require__(405);
var createDesc = __webpack_require__(383);
var _create = __webpack_require__(618);
var gOPNExt = __webpack_require__(1175);
var $GOPD = __webpack_require__(1176);
var $DP = __webpack_require__(165);
var $keys = __webpack_require__(236);
var gOPD = $GOPD.f;
var dP = $DP.f;
var gOPN = gOPNExt.f;
var $Symbol = global.Symbol;
var $JSON = global.JSON;
var _stringify = $JSON && $JSON.stringify;
var PROTOTYPE = 'prototype';
var HIDDEN = wks('_hidden');
var TO_PRIMITIVE = wks('toPrimitive');
var isEnum = {}.propertyIsEnumerable;
var SymbolRegistry = shared('symbol-registry');
var AllSymbols = shared('symbols');
var OPSymbols = shared('op-symbols');
var ObjectProto = Object[PROTOTYPE];
var USE_NATIVE = typeof $Symbol == 'function';
var QObject = global.QObject;
// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173
var setter = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;

// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
var setSymbolDesc = DESCRIPTORS && $fails(function () {
  return _create(dP({}, 'a', {
    get: function () { return dP(this, 'a', { value: 7 }).a; }
  })).a != 7;
}) ? function (it, key, D) {
  var protoDesc = gOPD(ObjectProto, key);
  if (protoDesc) delete ObjectProto[key];
  dP(it, key, D);
  if (protoDesc && it !== ObjectProto) dP(ObjectProto, key, protoDesc);
} : dP;

var wrap = function (tag) {
  var sym = AllSymbols[tag] = _create($Symbol[PROTOTYPE]);
  sym._k = tag;
  return sym;
};

var isSymbol = USE_NATIVE && typeof $Symbol.iterator == 'symbol' ? function (it) {
  return typeof it == 'symbol';
} : function (it) {
  return it instanceof $Symbol;
};

var $defineProperty = function defineProperty(it, key, D) {
  if (it === ObjectProto) $defineProperty(OPSymbols, key, D);
  anObject(it);
  key = toPrimitive(key, true);
  anObject(D);
  if (has(AllSymbols, key)) {
    if (!D.enumerable) {
      if (!has(it, HIDDEN)) dP(it, HIDDEN, createDesc(1, {}));
      it[HIDDEN][key] = true;
    } else {
      if (has(it, HIDDEN) && it[HIDDEN][key]) it[HIDDEN][key] = false;
      D = _create(D, { enumerable: createDesc(0, false) });
    } return setSymbolDesc(it, key, D);
  } return dP(it, key, D);
};
var $defineProperties = function defineProperties(it, P) {
  anObject(it);
  var keys = enumKeys(P = toIObject(P));
  var i = 0;
  var l = keys.length;
  var key;
  while (l > i) $defineProperty(it, key = keys[i++], P[key]);
  return it;
};
var $create = function create(it, P) {
  return P === undefined ? _create(it) : $defineProperties(_create(it), P);
};
var $propertyIsEnumerable = function propertyIsEnumerable(key) {
  var E = isEnum.call(this, key = toPrimitive(key, true));
  if (this === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return false;
  return E || !has(this, key) || !has(AllSymbols, key) || has(this, HIDDEN) && this[HIDDEN][key] ? E : true;
};
var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(it, key) {
  it = toIObject(it);
  key = toPrimitive(key, true);
  if (it === ObjectProto && has(AllSymbols, key) && !has(OPSymbols, key)) return;
  var D = gOPD(it, key);
  if (D && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key])) D.enumerable = true;
  return D;
};
var $getOwnPropertyNames = function getOwnPropertyNames(it) {
  var names = gOPN(toIObject(it));
  var result = [];
  var i = 0;
  var key;
  while (names.length > i) {
    if (!has(AllSymbols, key = names[i++]) && key != HIDDEN && key != META) result.push(key);
  } return result;
};
var $getOwnPropertySymbols = function getOwnPropertySymbols(it) {
  var IS_OP = it === ObjectProto;
  var names = gOPN(IS_OP ? OPSymbols : toIObject(it));
  var result = [];
  var i = 0;
  var key;
  while (names.length > i) {
    if (has(AllSymbols, key = names[i++]) && (IS_OP ? has(ObjectProto, key) : true)) result.push(AllSymbols[key]);
  } return result;
};

// 19.4.1.1 Symbol([description])
if (!USE_NATIVE) {
  $Symbol = function Symbol() {
    if (this instanceof $Symbol) throw TypeError('Symbol is not a constructor!');
    var tag = uid(arguments.length > 0 ? arguments[0] : undefined);
    var $set = function (value) {
      if (this === ObjectProto) $set.call(OPSymbols, value);
      if (has(this, HIDDEN) && has(this[HIDDEN], tag)) this[HIDDEN][tag] = false;
      setSymbolDesc(this, tag, createDesc(1, value));
    };
    if (DESCRIPTORS && setter) setSymbolDesc(ObjectProto, tag, { configurable: true, set: $set });
    return wrap(tag);
  };
  redefine($Symbol[PROTOTYPE], 'toString', function toString() {
    return this._k;
  });

  $GOPD.f = $getOwnPropertyDescriptor;
  $DP.f = $defineProperty;
  __webpack_require__(620).f = gOPNExt.f = $getOwnPropertyNames;
  __webpack_require__(385).f = $propertyIsEnumerable;
  __webpack_require__(616).f = $getOwnPropertySymbols;

  if (DESCRIPTORS && !__webpack_require__(238)) {
    redefine(ObjectProto, 'propertyIsEnumerable', $propertyIsEnumerable, true);
  }

  wksExt.f = function (name) {
    return wrap(wks(name));
  };
}

$export($export.G + $export.W + $export.F * !USE_NATIVE, { Symbol: $Symbol });

for (var es6Symbols = (
  // 19.4.2.2, 19.4.2.3, 19.4.2.4, 19.4.2.6, 19.4.2.8, 19.4.2.9, 19.4.2.10, 19.4.2.11, 19.4.2.12, 19.4.2.13, 19.4.2.14
  'hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables'
).split(','), j = 0; es6Symbols.length > j;)wks(es6Symbols[j++]);

for (var wellKnownSymbols = $keys(wks.store), k = 0; wellKnownSymbols.length > k;) wksDefine(wellKnownSymbols[k++]);

$export($export.S + $export.F * !USE_NATIVE, 'Symbol', {
  // 19.4.2.1 Symbol.for(key)
  'for': function (key) {
    return has(SymbolRegistry, key += '')
      ? SymbolRegistry[key]
      : SymbolRegistry[key] = $Symbol(key);
  },
  // 19.4.2.5 Symbol.keyFor(sym)
  keyFor: function keyFor(sym) {
    if (!isSymbol(sym)) throw TypeError(sym + ' is not a symbol!');
    for (var key in SymbolRegistry) if (SymbolRegistry[key] === sym) return key;
  },
  useSetter: function () { setter = true; },
  useSimple: function () { setter = false; }
});

$export($export.S + $export.F * !USE_NATIVE, 'Object', {
  // 19.1.2.2 Object.create(O [, Properties])
  create: $create,
  // 19.1.2.4 Object.defineProperty(O, P, Attributes)
  defineProperty: $defineProperty,
  // 19.1.2.3 Object.defineProperties(O, Properties)
  defineProperties: $defineProperties,
  // 19.1.2.6 Object.getOwnPropertyDescriptor(O, P)
  getOwnPropertyDescriptor: $getOwnPropertyDescriptor,
  // 19.1.2.7 Object.getOwnPropertyNames(O)
  getOwnPropertyNames: $getOwnPropertyNames,
  // 19.1.2.8 Object.getOwnPropertySymbols(O)
  getOwnPropertySymbols: $getOwnPropertySymbols
});

// 24.3.2 JSON.stringify(value [, replacer [, space]])
$JSON && $export($export.S + $export.F * (!USE_NATIVE || $fails(function () {
  var S = $Symbol();
  // MS Edge converts symbol values to JSON as {}
  // WebKit converts symbol values to JSON as null
  // V8 throws on boxed symbols
  return _stringify([S]) != '[null]' || _stringify({ a: S }) != '{}' || _stringify(Object(S)) != '{}';
})), 'JSON', {
  stringify: function stringify(it) {
    var args = [it];
    var i = 1;
    var replacer, $replacer;
    while (arguments.length > i) args.push(arguments[i++]);
    $replacer = replacer = args[1];
    if (!isObject(replacer) && it === undefined || isSymbol(it)) return; // IE8 returns string on undefined
    if (!isArray(replacer)) replacer = function (key, value) {
      if (typeof $replacer == 'function') value = $replacer.call(this, key, value);
      if (!isSymbol(value)) return value;
    };
    args[1] = replacer;
    return _stringify.apply($JSON, args);
  }
});

// 19.4.3.4 Symbol.prototype[@@toPrimitive](hint)
$Symbol[PROTOTYPE][TO_PRIMITIVE] || __webpack_require__(173)($Symbol[PROTOTYPE], TO_PRIMITIVE, $Symbol[PROTOTYPE].valueOf);
// 19.4.3.5 Symbol.prototype[@@toStringTag]
setToStringTag($Symbol, 'Symbol');
// 20.2.1.9 Math[@@toStringTag]
setToStringTag(Math, 'Math', true);
// 24.3.3 JSON[@@toStringTag]
setToStringTag(global.JSON, 'JSON', true);


/***/ }),
/* 1172 */
/***/ (function(module, exports, __webpack_require__) {

var META = __webpack_require__(380)('meta');
var isObject = __webpack_require__(174);
var has = __webpack_require__(171);
var setDesc = __webpack_require__(165).f;
var id = 0;
var isExtensible = Object.isExtensible || function () {
  return true;
};
var FREEZE = !__webpack_require__(219)(function () {
  return isExtensible(Object.preventExtensions({}));
});
var setMeta = function (it) {
  setDesc(it, META, { value: {
    i: 'O' + ++id, // object ID
    w: {}          // weak collections IDs
  } });
};
var fastKey = function (it, create) {
  // return primitive with prefix
  if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
  if (!has(it, META)) {
    // can't set metadata to uncaught frozen object
    if (!isExtensible(it)) return 'F';
    // not necessary to add metadata
    if (!create) return 'E';
    // add missing metadata
    setMeta(it);
  // return object ID
  } return it[META].i;
};
var getWeak = function (it, create) {
  if (!has(it, META)) {
    // can't set metadata to uncaught frozen object
    if (!isExtensible(it)) return true;
    // not necessary to add metadata
    if (!create) return false;
    // add missing metadata
    setMeta(it);
  // return hash weak collections IDs
  } return it[META].w;
};
// add metadata on freeze-family methods calling
var onFreeze = function (it) {
  if (FREEZE && meta.NEED && isExtensible(it) && !has(it, META)) setMeta(it);
  return it;
};
var meta = module.exports = {
  KEY: META,
  NEED: false,
  fastKey: fastKey,
  getWeak: getWeak,
  onFreeze: onFreeze
};


/***/ }),
/* 1173 */
/***/ (function(module, exports, __webpack_require__) {

// all enumerable object keys, includes symbols
var getKeys = __webpack_require__(236);
var gOPS = __webpack_require__(616);
var pIE = __webpack_require__(385);
module.exports = function (it) {
  var result = getKeys(it);
  var getSymbols = gOPS.f;
  if (getSymbols) {
    var symbols = getSymbols(it);
    var isEnum = pIE.f;
    var i = 0;
    var key;
    while (symbols.length > i) if (isEnum.call(it, key = symbols[i++])) result.push(key);
  } return result;
};


/***/ }),
/* 1174 */
/***/ (function(module, exports, __webpack_require__) {

var dP = __webpack_require__(165);
var anObject = __webpack_require__(166);
var getKeys = __webpack_require__(236);

module.exports = __webpack_require__(167) ? Object.defineProperties : function defineProperties(O, Properties) {
  anObject(O);
  var keys = getKeys(Properties);
  var length = keys.length;
  var i = 0;
  var P;
  while (length > i) dP.f(O, P = keys[i++], Properties[P]);
  return O;
};


/***/ }),
/* 1175 */
/***/ (function(module, exports, __webpack_require__) {

// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
var toIObject = __webpack_require__(172);
var gOPN = __webpack_require__(620).f;
var toString = {}.toString;

var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames
  ? Object.getOwnPropertyNames(window) : [];

var getWindowNames = function (it) {
  try {
    return gOPN(it);
  } catch (e) {
    return windowNames.slice();
  }
};

module.exports.f = function getOwnPropertyNames(it) {
  return windowNames && toString.call(it) == '[object Window]' ? getWindowNames(it) : gOPN(toIObject(it));
};


/***/ }),
/* 1176 */
/***/ (function(module, exports, __webpack_require__) {

var pIE = __webpack_require__(385);
var createDesc = __webpack_require__(383);
var toIObject = __webpack_require__(172);
var toPrimitive = __webpack_require__(405);
var has = __webpack_require__(171);
var IE8_DOM_DEFINE = __webpack_require__(613);
var gOPD = Object.getOwnPropertyDescriptor;

exports.f = __webpack_require__(167) ? gOPD : function getOwnPropertyDescriptor(O, P) {
  O = toIObject(O);
  P = toPrimitive(P, true);
  if (IE8_DOM_DEFINE) try {
    return gOPD(O, P);
  } catch (e) { /* empty */ }
  if (has(O, P)) return createDesc(!pIE.f.call(O, P), O[P]);
};


/***/ }),
/* 1177 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(406)('asyncIterator');


/***/ }),
/* 1178 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(406)('observable');


/***/ }),
/* 1179 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(621);
__webpack_require__(1180);
__webpack_require__(1184);
__webpack_require__(1188);
__webpack_require__(1200);
__webpack_require__(1201);
module.exports = __webpack_require__(119).Promise;


/***/ }),
/* 1180 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var $at = __webpack_require__(1181)(true);

// 21.1.3.27 String.prototype[@@iterator]()
__webpack_require__(623)(String, 'String', function (iterated) {
  this._t = String(iterated); // target
  this._i = 0;                // next index
// 21.1.5.2.1 %StringIteratorPrototype%.next()
}, function () {
  var O = this._t;
  var index = this._i;
  var point;
  if (index >= O.length) return { value: undefined, done: true };
  point = $at(O, index);
  this._i += point.length;
  return { value: point, done: false };
});


/***/ }),
/* 1181 */
/***/ (function(module, exports, __webpack_require__) {

var toInteger = __webpack_require__(400);
var defined = __webpack_require__(379);
// true  -> String#at
// false -> String#codePointAt
module.exports = function (TO_STRING) {
  return function (that, pos) {
    var s = String(defined(that));
    var i = toInteger(pos);
    var l = s.length;
    var a, b;
    if (i < 0 || i >= l) return TO_STRING ? '' : undefined;
    a = s.charCodeAt(i);
    return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
      ? TO_STRING ? s.charAt(i) : a
      : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
  };
};


/***/ }),
/* 1182 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var create = __webpack_require__(618);
var descriptor = __webpack_require__(383);
var setToStringTag = __webpack_require__(384);
var IteratorPrototype = {};

// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
__webpack_require__(173)(IteratorPrototype, __webpack_require__(126)('iterator'), function () { return this; });

module.exports = function (Constructor, NAME, next) {
  Constructor.prototype = create(IteratorPrototype, { next: descriptor(1, next) });
  setToStringTag(Constructor, NAME + ' Iterator');
};


/***/ }),
/* 1183 */
/***/ (function(module, exports, __webpack_require__) {

// 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
var has = __webpack_require__(171);
var toObject = __webpack_require__(610);
var IE_PROTO = __webpack_require__(401)('IE_PROTO');
var ObjectProto = Object.prototype;

module.exports = Object.getPrototypeOf || function (O) {
  O = toObject(O);
  if (has(O, IE_PROTO)) return O[IE_PROTO];
  if (typeof O.constructor == 'function' && O instanceof O.constructor) {
    return O.constructor.prototype;
  } return O instanceof Object ? ObjectProto : null;
};


/***/ }),
/* 1184 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1185);
var global = __webpack_require__(122);
var hide = __webpack_require__(173);
var Iterators = __webpack_require__(239);
var TO_STRING_TAG = __webpack_require__(126)('toStringTag');

var DOMIterables = ('CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,' +
  'DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,' +
  'MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,' +
  'SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,' +
  'TextTrackList,TouchList').split(',');

for (var i = 0; i < DOMIterables.length; i++) {
  var NAME = DOMIterables[i];
  var Collection = global[NAME];
  var proto = Collection && Collection.prototype;
  if (proto && !proto[TO_STRING_TAG]) hide(proto, TO_STRING_TAG, NAME);
  Iterators[NAME] = Iterators.Array;
}


/***/ }),
/* 1185 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var addToUnscopables = __webpack_require__(1186);
var step = __webpack_require__(1187);
var Iterators = __webpack_require__(239);
var toIObject = __webpack_require__(172);

// 22.1.3.4 Array.prototype.entries()
// 22.1.3.13 Array.prototype.keys()
// 22.1.3.29 Array.prototype.values()
// 22.1.3.30 Array.prototype[@@iterator]()
module.exports = __webpack_require__(623)(Array, 'Array', function (iterated, kind) {
  this._t = toIObject(iterated); // target
  this._i = 0;                   // next index
  this._k = kind;                // kind
// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
}, function () {
  var O = this._t;
  var kind = this._k;
  var index = this._i++;
  if (!O || index >= O.length) {
    this._t = undefined;
    return step(1);
  }
  if (kind == 'keys') return step(0, index);
  if (kind == 'values') return step(0, O[index]);
  return step(0, [index, O[index]]);
}, 'values');

// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
Iterators.Arguments = Iterators.Array;

addToUnscopables('keys');
addToUnscopables('values');
addToUnscopables('entries');


/***/ }),
/* 1186 */
/***/ (function(module, exports) {

module.exports = function () { /* empty */ };


/***/ }),
/* 1187 */
/***/ (function(module, exports) {

module.exports = function (done, value) {
  return { value: value, done: !!done };
};


/***/ }),
/* 1188 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var LIBRARY = __webpack_require__(238);
var global = __webpack_require__(122);
var ctx = __webpack_require__(381);
var classof = __webpack_require__(624);
var $export = __webpack_require__(132);
var isObject = __webpack_require__(174);
var aFunction = __webpack_require__(382);
var anInstance = __webpack_require__(1189);
var forOf = __webpack_require__(1190);
var speciesConstructor = __webpack_require__(625);
var task = __webpack_require__(626).set;
var microtask = __webpack_require__(1195)();
var newPromiseCapabilityModule = __webpack_require__(407);
var perform = __webpack_require__(627);
var userAgent = __webpack_require__(1196);
var promiseResolve = __webpack_require__(628);
var PROMISE = 'Promise';
var TypeError = global.TypeError;
var process = global.process;
var versions = process && process.versions;
var v8 = versions && versions.v8 || '';
var $Promise = global[PROMISE];
var isNode = classof(process) == 'process';
var empty = function () { /* empty */ };
var Internal, newGenericPromiseCapability, OwnPromiseCapability, Wrapper;
var newPromiseCapability = newGenericPromiseCapability = newPromiseCapabilityModule.f;

var USE_NATIVE = !!function () {
  try {
    // correct subclassing with @@species support
    var promise = $Promise.resolve(1);
    var FakePromise = (promise.constructor = {})[__webpack_require__(126)('species')] = function (exec) {
      exec(empty, empty);
    };
    // unhandled rejections tracking support, NodeJS Promise without it fails @@species test
    return (isNode || typeof PromiseRejectionEvent == 'function')
      && promise.then(empty) instanceof FakePromise
      // v8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
      // https://bugs.chromium.org/p/chromium/issues/detail?id=830565
      // we can't detect it synchronously, so just check versions
      && v8.indexOf('6.6') !== 0
      && userAgent.indexOf('Chrome/66') === -1;
  } catch (e) { /* empty */ }
}();

// helpers
var isThenable = function (it) {
  var then;
  return isObject(it) && typeof (then = it.then) == 'function' ? then : false;
};
var notify = function (promise, isReject) {
  if (promise._n) return;
  promise._n = true;
  var chain = promise._c;
  microtask(function () {
    var value = promise._v;
    var ok = promise._s == 1;
    var i = 0;
    var run = function (reaction) {
      var handler = ok ? reaction.ok : reaction.fail;
      var resolve = reaction.resolve;
      var reject = reaction.reject;
      var domain = reaction.domain;
      var result, then, exited;
      try {
        if (handler) {
          if (!ok) {
            if (promise._h == 2) onHandleUnhandled(promise);
            promise._h = 1;
          }
          if (handler === true) result = value;
          else {
            if (domain) domain.enter();
            result = handler(value); // may throw
            if (domain) {
              domain.exit();
              exited = true;
            }
          }
          if (result === reaction.promise) {
            reject(TypeError('Promise-chain cycle'));
          } else if (then = isThenable(result)) {
            then.call(result, resolve, reject);
          } else resolve(result);
        } else reject(value);
      } catch (e) {
        if (domain && !exited) domain.exit();
        reject(e);
      }
    };
    while (chain.length > i) run(chain[i++]); // variable length - can't use forEach
    promise._c = [];
    promise._n = false;
    if (isReject && !promise._h) onUnhandled(promise);
  });
};
var onUnhandled = function (promise) {
  task.call(global, function () {
    var value = promise._v;
    var unhandled = isUnhandled(promise);
    var result, handler, console;
    if (unhandled) {
      result = perform(function () {
        if (isNode) {
          process.emit('unhandledRejection', value, promise);
        } else if (handler = global.onunhandledrejection) {
          handler({ promise: promise, reason: value });
        } else if ((console = global.console) && console.error) {
          console.error('Unhandled promise rejection', value);
        }
      });
      // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
      promise._h = isNode || isUnhandled(promise) ? 2 : 1;
    } promise._a = undefined;
    if (unhandled && result.e) throw result.v;
  });
};
var isUnhandled = function (promise) {
  return promise._h !== 1 && (promise._a || promise._c).length === 0;
};
var onHandleUnhandled = function (promise) {
  task.call(global, function () {
    var handler;
    if (isNode) {
      process.emit('rejectionHandled', promise);
    } else if (handler = global.onrejectionhandled) {
      handler({ promise: promise, reason: promise._v });
    }
  });
};
var $reject = function (value) {
  var promise = this;
  if (promise._d) return;
  promise._d = true;
  promise = promise._w || promise; // unwrap
  promise._v = value;
  promise._s = 2;
  if (!promise._a) promise._a = promise._c.slice();
  notify(promise, true);
};
var $resolve = function (value) {
  var promise = this;
  var then;
  if (promise._d) return;
  promise._d = true;
  promise = promise._w || promise; // unwrap
  try {
    if (promise === value) throw TypeError("Promise can't be resolved itself");
    if (then = isThenable(value)) {
      microtask(function () {
        var wrapper = { _w: promise, _d: false }; // wrap
        try {
          then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1));
        } catch (e) {
          $reject.call(wrapper, e);
        }
      });
    } else {
      promise._v = value;
      promise._s = 1;
      notify(promise, false);
    }
  } catch (e) {
    $reject.call({ _w: promise, _d: false }, e); // wrap
  }
};

// constructor polyfill
if (!USE_NATIVE) {
  // 25.4.3.1 Promise(executor)
  $Promise = function Promise(executor) {
    anInstance(this, $Promise, PROMISE, '_h');
    aFunction(executor);
    Internal.call(this);
    try {
      executor(ctx($resolve, this, 1), ctx($reject, this, 1));
    } catch (err) {
      $reject.call(this, err);
    }
  };
  // eslint-disable-next-line no-unused-vars
  Internal = function Promise(executor) {
    this._c = [];             // <- awaiting reactions
    this._a = undefined;      // <- checked in isUnhandled reactions
    this._s = 0;              // <- state
    this._d = false;          // <- done
    this._v = undefined;      // <- value
    this._h = 0;              // <- rejection state, 0 - default, 1 - handled, 2 - unhandled
    this._n = false;          // <- notify
  };
  Internal.prototype = __webpack_require__(1197)($Promise.prototype, {
    // 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected)
    then: function then(onFulfilled, onRejected) {
      var reaction = newPromiseCapability(speciesConstructor(this, $Promise));
      reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true;
      reaction.fail = typeof onRejected == 'function' && onRejected;
      reaction.domain = isNode ? process.domain : undefined;
      this._c.push(reaction);
      if (this._a) this._a.push(reaction);
      if (this._s) notify(this, false);
      return reaction.promise;
    },
    // 25.4.5.1 Promise.prototype.catch(onRejected)
    'catch': function (onRejected) {
      return this.then(undefined, onRejected);
    }
  });
  OwnPromiseCapability = function () {
    var promise = new Internal();
    this.promise = promise;
    this.resolve = ctx($resolve, promise, 1);
    this.reject = ctx($reject, promise, 1);
  };
  newPromiseCapabilityModule.f = newPromiseCapability = function (C) {
    return C === $Promise || C === Wrapper
      ? new OwnPromiseCapability(C)
      : newGenericPromiseCapability(C);
  };
}

$export($export.G + $export.W + $export.F * !USE_NATIVE, { Promise: $Promise });
__webpack_require__(384)($Promise, PROMISE);
__webpack_require__(1198)(PROMISE);
Wrapper = __webpack_require__(119)[PROMISE];

// statics
$export($export.S + $export.F * !USE_NATIVE, PROMISE, {
  // 25.4.4.5 Promise.reject(r)
  reject: function reject(r) {
    var capability = newPromiseCapability(this);
    var $$reject = capability.reject;
    $$reject(r);
    return capability.promise;
  }
});
$export($export.S + $export.F * (LIBRARY || !USE_NATIVE), PROMISE, {
  // 25.4.4.6 Promise.resolve(x)
  resolve: function resolve(x) {
    return promiseResolve(LIBRARY && this === Wrapper ? $Promise : this, x);
  }
});
$export($export.S + $export.F * !(USE_NATIVE && __webpack_require__(1199)(function (iter) {
  $Promise.all(iter)['catch'](empty);
})), PROMISE, {
  // 25.4.4.1 Promise.all(iterable)
  all: function all(iterable) {
    var C = this;
    var capability = newPromiseCapability(C);
    var resolve = capability.resolve;
    var reject = capability.reject;
    var result = perform(function () {
      var values = [];
      var index = 0;
      var remaining = 1;
      forOf(iterable, false, function (promise) {
        var $index = index++;
        var alreadyCalled = false;
        values.push(undefined);
        remaining++;
        C.resolve(promise).then(function (value) {
          if (alreadyCalled) return;
          alreadyCalled = true;
          values[$index] = value;
          --remaining || resolve(values);
        }, reject);
      });
      --remaining || resolve(values);
    });
    if (result.e) reject(result.v);
    return capability.promise;
  },
  // 25.4.4.4 Promise.race(iterable)
  race: function race(iterable) {
    var C = this;
    var capability = newPromiseCapability(C);
    var reject = capability.reject;
    var result = perform(function () {
      forOf(iterable, false, function (promise) {
        C.resolve(promise).then(capability.resolve, reject);
      });
    });
    if (result.e) reject(result.v);
    return capability.promise;
  }
});


/***/ }),
/* 1189 */
/***/ (function(module, exports) {

module.exports = function (it, Constructor, name, forbiddenField) {
  if (!(it instanceof Constructor) || (forbiddenField !== undefined && forbiddenField in it)) {
    throw TypeError(name + ': incorrect invocation!');
  } return it;
};


/***/ }),
/* 1190 */
/***/ (function(module, exports, __webpack_require__) {

var ctx = __webpack_require__(381);
var call = __webpack_require__(1191);
var isArrayIter = __webpack_require__(1192);
var anObject = __webpack_require__(166);
var toLength = __webpack_require__(612);
var getIterFn = __webpack_require__(1193);
var BREAK = {};
var RETURN = {};
var exports = module.exports = function (iterable, entries, fn, that, ITERATOR) {
  var iterFn = ITERATOR ? function () { return iterable; } : getIterFn(iterable);
  var f = ctx(fn, that, entries ? 2 : 1);
  var index = 0;
  var length, step, iterator, result;
  if (typeof iterFn != 'function') throw TypeError(iterable + ' is not iterable!');
  // fast case for arrays with default iterator
  if (isArrayIter(iterFn)) for (length = toLength(iterable.length); length > index; index++) {
    result = entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]);
    if (result === BREAK || result === RETURN) return result;
  } else for (iterator = iterFn.call(iterable); !(step = iterator.next()).done;) {
    result = call(iterator, f, step.value, entries);
    if (result === BREAK || result === RETURN) return result;
  }
};
exports.BREAK = BREAK;
exports.RETURN = RETURN;


/***/ }),
/* 1191 */
/***/ (function(module, exports, __webpack_require__) {

// call something on iterator step with safe closing on error
var anObject = __webpack_require__(166);
module.exports = function (iterator, fn, value, entries) {
  try {
    return entries ? fn(anObject(value)[0], value[1]) : fn(value);
  // 7.4.6 IteratorClose(iterator, completion)
  } catch (e) {
    var ret = iterator['return'];
    if (ret !== undefined) anObject(ret.call(iterator));
    throw e;
  }
};


/***/ }),
/* 1192 */
/***/ (function(module, exports, __webpack_require__) {

// check on default Array iterator
var Iterators = __webpack_require__(239);
var ITERATOR = __webpack_require__(126)('iterator');
var ArrayProto = Array.prototype;

module.exports = function (it) {
  return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);
};


/***/ }),
/* 1193 */
/***/ (function(module, exports, __webpack_require__) {

var classof = __webpack_require__(624);
var ITERATOR = __webpack_require__(126)('iterator');
var Iterators = __webpack_require__(239);
module.exports = __webpack_require__(119).getIteratorMethod = function (it) {
  if (it != undefined) return it[ITERATOR]
    || it['@@iterator']
    || Iterators[classof(it)];
};


/***/ }),
/* 1194 */
/***/ (function(module, exports) {

// fast apply, http://jsperf.lnkit.com/fast-apply/5
module.exports = function (fn, args, that) {
  var un = that === undefined;
  switch (args.length) {
    case 0: return un ? fn()
                      : fn.call(that);
    case 1: return un ? fn(args[0])
                      : fn.call(that, args[0]);
    case 2: return un ? fn(args[0], args[1])
                      : fn.call(that, args[0], args[1]);
    case 3: return un ? fn(args[0], args[1], args[2])
                      : fn.call(that, args[0], args[1], args[2]);
    case 4: return un ? fn(args[0], args[1], args[2], args[3])
                      : fn.call(that, args[0], args[1], args[2], args[3]);
  } return fn.apply(that, args);
};


/***/ }),
/* 1195 */
/***/ (function(module, exports, __webpack_require__) {

var global = __webpack_require__(122);
var macrotask = __webpack_require__(626).set;
var Observer = global.MutationObserver || global.WebKitMutationObserver;
var process = global.process;
var Promise = global.Promise;
var isNode = __webpack_require__(237)(process) == 'process';

module.exports = function () {
  var head, last, notify;

  var flush = function () {
    var parent, fn;
    if (isNode && (parent = process.domain)) parent.exit();
    while (head) {
      fn = head.fn;
      head = head.next;
      try {
        fn();
      } catch (e) {
        if (head) notify();
        else last = undefined;
        throw e;
      }
    } last = undefined;
    if (parent) parent.enter();
  };

  // Node.js
  if (isNode) {
    notify = function () {
      process.nextTick(flush);
    };
  // browsers with MutationObserver, except iOS Safari - https://github.com/zloirock/core-js/issues/339
  } else if (Observer && !(global.navigator && global.navigator.standalone)) {
    var toggle = true;
    var node = document.createTextNode('');
    new Observer(flush).observe(node, { characterData: true }); // eslint-disable-line no-new
    notify = function () {
      node.data = toggle = !toggle;
    };
  // environments with maybe non-completely correct, but existent Promise
  } else if (Promise && Promise.resolve) {
    // Promise.resolve without an argument throws an error in LG WebOS 2
    var promise = Promise.resolve(undefined);
    notify = function () {
      promise.then(flush);
    };
  // for other environments - macrotask based on:
  // - setImmediate
  // - MessageChannel
  // - window.postMessag
  // - onreadystatechange
  // - setTimeout
  } else {
    notify = function () {
      // strange IE + webpack dev server bug - use .call(global)
      macrotask.call(global, flush);
    };
  }

  return function (fn) {
    var task = { fn: fn, next: undefined };
    if (last) last.next = task;
    if (!head) {
      head = task;
      notify();
    } last = task;
  };
};


/***/ }),
/* 1196 */
/***/ (function(module, exports, __webpack_require__) {

var global = __webpack_require__(122);
var navigator = global.navigator;

module.exports = navigator && navigator.userAgent || '';


/***/ }),
/* 1197 */
/***/ (function(module, exports, __webpack_require__) {

var hide = __webpack_require__(173);
module.exports = function (target, src, safe) {
  for (var key in src) {
    if (safe && target[key]) target[key] = src[key];
    else hide(target, key, src[key]);
  } return target;
};


/***/ }),
/* 1198 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

var global = __webpack_require__(122);
var core = __webpack_require__(119);
var dP = __webpack_require__(165);
var DESCRIPTORS = __webpack_require__(167);
var SPECIES = __webpack_require__(126)('species');

module.exports = function (KEY) {
  var C = typeof core[KEY] == 'function' ? core[KEY] : global[KEY];
  if (DESCRIPTORS && C && !C[SPECIES]) dP.f(C, SPECIES, {
    configurable: true,
    get: function () { return this; }
  });
};


/***/ }),
/* 1199 */
/***/ (function(module, exports, __webpack_require__) {

var ITERATOR = __webpack_require__(126)('iterator');
var SAFE_CLOSING = false;

try {
  var riter = [7][ITERATOR]();
  riter['return'] = function () { SAFE_CLOSING = true; };
  // eslint-disable-next-line no-throw-literal
  Array.from(riter, function () { throw 2; });
} catch (e) { /* empty */ }

module.exports = function (exec, skipClosing) {
  if (!skipClosing && !SAFE_CLOSING) return false;
  var safe = false;
  try {
    var arr = [7];
    var iter = arr[ITERATOR]();
    iter.next = function () { return { done: safe = true }; };
    arr[ITERATOR] = function () { return iter; };
    exec(arr);
  } catch (e) { /* empty */ }
  return safe;
};


/***/ }),
/* 1200 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";
// https://github.com/tc39/proposal-promise-finally

var $export = __webpack_require__(132);
var core = __webpack_require__(119);
var global = __webpack_require__(122);
var speciesConstructor = __webpack_require__(625);
var promiseResolve = __webpack_require__(628);

$export($export.P + $export.R, 'Promise', { 'finally': function (onFinally) {
  var C = speciesConstructor(this, core.Promise || global.Promise);
  var isFunction = typeof onFinally == 'function';
  return this.then(
    isFunction ? function (x) {
      return promiseResolve(C, onFinally()).then(function () { return x; });
    } : onFinally,
    isFunction ? function (e) {
      return promiseResolve(C, onFinally()).then(function () { throw e; });
    } : onFinally
  );
} });


/***/ }),
/* 1201 */
/***/ (function(module, exports, __webpack_require__) {

"use strict";

// https://github.com/tc39/proposal-promise-try
var $export = __webpack_require__(132);
var newPromiseCapability = __webpack_require__(407);
var perform = __webpack_require__(627);

$export($export.S, 'Promise', { 'try': function (callbackfn) {
  var promiseCapability = newPromiseCapability.f(this);
  var result = perform(callbackfn);
  (result.e ? promiseCapability.reject : promiseCapability.resolve)(result.v);
  return promiseCapability.promise;
} });


/***/ }),
/* 1202 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1203);

/***/ }),
/* 1203 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1204);
module.exports = __webpack_require__(119).parseInt;


/***/ }),
/* 1204 */
/***/ (function(module, exports, __webpack_require__) {

var $export = __webpack_require__(132);
var $parseInt = __webpack_require__(1205);
// 18.2.5 parseInt(string, radix)
$export($export.G + $export.F * (parseInt != $parseInt), { parseInt: $parseInt });


/***/ }),
/* 1205 */
/***/ (function(module, exports, __webpack_require__) {

var $parseInt = __webpack_require__(122).parseInt;
var $trim = __webpack_require__(1206).trim;
var ws = __webpack_require__(629);
var hex = /^[-+]?0[xX]/;

module.exports = $parseInt(ws + '08') !== 8 || $parseInt(ws + '0x16') !== 22 ? function parseInt(str, radix) {
  var string = $trim(String(str), 3);
  return $parseInt(string, (radix >>> 0) || (hex.test(string) ? 16 : 10));
} : $parseInt;


/***/ }),
/* 1206 */
/***/ (function(module, exports, __webpack_require__) {

var $export = __webpack_require__(132);
var defined = __webpack_require__(379);
var fails = __webpack_require__(219);
var spaces = __webpack_require__(629);
var space = '[' + spaces + ']';
var non = '\u200b\u0085';
var ltrim = RegExp('^' + space + space + '*');
var rtrim = RegExp(space + space + '*$');

var exporter = function (KEY, exec, ALIAS) {
  var exp = {};
  var FORCE = fails(function () {
    return !!spaces[KEY]() || non[KEY]() != non;
  });
  var fn = exp[KEY] = FORCE ? exec(trim) : spaces[KEY];
  if (ALIAS) exp[ALIAS] = fn;
  $export($export.P + $export.F * FORCE, 'String', exp);
};

// 1 -> String#trimLeft
// 2 -> String#trimRight
// 3 -> String#trim
var trim = exporter.trim = function (string, TYPE) {
  string = String(defined(string));
  if (TYPE & 1) string = string.replace(ltrim, '');
  if (TYPE & 2) string = string.replace(rtrim, '');
  return string;
};

module.exports = exporter;


/***/ }),
/* 1207 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1208);

/***/ }),
/* 1208 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1209);
module.exports = __webpack_require__(119).Date.now;


/***/ }),
/* 1209 */
/***/ (function(module, exports, __webpack_require__) {

// 20.3.3.1 / 15.9.4.4 Date.now()
var $export = __webpack_require__(132);

$export($export.S, 'Date', { now: function () { return new Date().getTime(); } });


/***/ }),
/* 1210 */
/***/ (function(module, exports, __webpack_require__) {


/**
 * Module dependencies.
 */

var toFunction = __webpack_require__(1211);

/**
 * Group `arr` with callback `fn(val, i)`.
 *
 * @param {Array} arr
 * @param {Function|String} fn or prop
 * @return {Array}
 * @api public
 */

module.exports = function(arr, fn){
  var ret = {};
  var prop;
  fn = toFunction(fn);

  for (var i = 0; i < arr.length; ++i) {
    prop = fn(arr[i], i);
    ret[prop] = ret[prop] || [];
    ret[prop].push(arr[i]);
  }

  return ret;
};

/***/ }),
/* 1211 */
/***/ (function(module, exports, __webpack_require__) {


/**
 * Module Dependencies
 */

var expr;
try {
  expr = __webpack_require__(630);
} catch(e) {
  expr = __webpack_require__(630);
}

/**
 * Expose `toFunction()`.
 */

module.exports = toFunction;

/**
 * Convert `obj` to a `Function`.
 *
 * @param {Mixed} obj
 * @return {Function}
 * @api private
 */

function toFunction(obj) {
  switch ({}.toString.call(obj)) {
    case '[object Object]':
      return objectToFunction(obj);
    case '[object Function]':
      return obj;
    case '[object String]':
      return stringToFunction(obj);
    case '[object RegExp]':
      return regexpToFunction(obj);
    default:
      return defaultToFunction(obj);
  }
}

/**
 * Default to strict equality.
 *
 * @param {Mixed} val
 * @return {Function}
 * @api private
 */

function defaultToFunction(val) {
  return function(obj){
    return val === obj;
  };
}

/**
 * Convert `re` to a function.
 *
 * @param {RegExp} re
 * @return {Function}
 * @api private
 */

function regexpToFunction(re) {
  return function(obj){
    return re.test(obj);
  };
}

/**
 * Convert property `str` to a function.
 *
 * @param {String} str
 * @return {Function}
 * @api private
 */

function stringToFunction(str) {
  // immediate such as "> 20"
  if (/^ *\W+/.test(str)) return new Function('_', 'return _ ' + str);

  // properties such as "name.first" or "age > 18" or "age > 18 && age < 36"
  return new Function('_', 'return ' + get(str));
}

/**
 * Convert `object` to a function.
 *
 * @param {Object} object
 * @return {Function}
 * @api private
 */

function objectToFunction(obj) {
  var match = {};
  for (var key in obj) {
    match[key] = typeof obj[key] === 'string'
      ? defaultToFunction(obj[key])
      : toFunction(obj[key]);
  }
  return function(val){
    if (typeof val !== 'object') return false;
    for (var key in match) {
      if (!(key in val)) return false;
      if (!match[key](val[key])) return false;
    }
    return true;
  };
}

/**
 * Built the getter function. Supports getter style functions
 *
 * @param {String} str
 * @return {String}
 * @api private
 */

function get(str) {
  var props = expr(str);
  if (!props.length) return '_.' + str;

  var val, i, prop;
  for (i = 0; i < props.length; i++) {
    prop = props[i];
    val = '_.' + prop;
    val = "('function' == typeof " + val + " ? " + val + "() : " + val + ")";

    // mimic negative lookbehind to avoid problems with nested properties
    str = stripNested(prop, str, val);
  }

  return str;
}

/**
 * Mimic negative lookbehind to avoid problems with nested properties.
 *
 * See: http://blog.stevenlevithan.com/archives/mimic-lookbehind-javascript
 *
 * @param {String} prop
 * @param {String} str
 * @param {String} val
 * @return {String}
 * @api private
 */

function stripNested (prop, str, val) {
  return str.replace(new RegExp('(\\.)?' + prop, 'g'), function($0, $1) {
    return $1 ? $0 : val;
  });
}


/***/ }),
/* 1212 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1213);

/***/ }),
/* 1213 */
/***/ (function(module, exports, __webpack_require__) {

var core = __webpack_require__(119);
var $JSON = core.JSON || (core.JSON = { stringify: JSON.stringify });
module.exports = function stringify(it) { // eslint-disable-line no-unused-vars
  return $JSON.stringify.apply($JSON, arguments);
};


/***/ }),
/* 1214 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1215);

/***/ }),
/* 1215 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1216);
module.exports = __webpack_require__(119).Array.isArray;


/***/ }),
/* 1216 */
/***/ (function(module, exports, __webpack_require__) {

// 22.1.2.2 / 15.4.3.2 Array.isArray(arg)
var $export = __webpack_require__(132);

$export($export.S, 'Array', { isArray: __webpack_require__(617) });


/***/ }),
/* 1217 */
/***/ (function(module, exports, __webpack_require__) {

module.exports = __webpack_require__(1218);

/***/ }),
/* 1218 */
/***/ (function(module, exports, __webpack_require__) {

__webpack_require__(1219);
module.exports = __webpack_require__(119).Object.values;


/***/ }),
/* 1219 */
/***/ (function(module, exports, __webpack_require__) {

// https://github.com/tc39/proposal-object-values-entries
var $export = __webpack_require__(132);
var $values = __webpack_require__(1220)(false);

$export($export.S, 'Object', {
  values: function values(it) {
    return $values(it);
  }
});


/***/ }),
/* 1220 */
/***/ (function(module, exports, __webpack_require__) {

var getKeys = __webpack_require__(236);
var toIObject = __webpack_require__(172);
var isEnum = __webpack_require__(385).f;
module.exports = function (isEntries) {
  return function (it) {
    var O = toIObject(it);
    var keys = getKeys(O);
    var length = keys.length;
    var i = 0;
    var result = [];
    var key;
    while (length > i) if (isEnum.call(O, key = keys[i++])) {
      result.push(isEntries ? [key, O[key]] : O[key]);
    } return result;
  };
};


/***/ }),
/* 1221 */
/***/ (function(module, exports, __webpack_require__) {

var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;(function (root, factory) {
  'use strict'

  /*istanbul ignore next:cant test*/
  if ( true && typeof module.exports === 'object') {
    module.exports = factory()
  } else if (true) {
    // AMD. Register as an anonymous module.
    !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
				__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
				(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__))
  } else {}
})(this, function () {
  'use strict'

  var toStr = Object.prototype.toString

  function hasOwnProperty (obj, prop) {
    if (obj == null) {
      return false
    }
    //to handle objects with null prototypes (too edge case?)
    return Object.prototype.hasOwnProperty.call(obj, prop)
  }

  function isEmpty (value) {
    if (!value) {
      return true
    }
    if (isArray(value) && value.length === 0) {
      return true
    } else if (typeof value !== 'string') {
      for (var i in value) {
        if (hasOwnProperty(value, i)) {
          return false
        }
      }
      return true
    }
    return false
  }

  function toString (type) {
    return toStr.call(type)
  }

  function isObject (obj) {
    return typeof obj === 'object' && toString(obj) === '[object Object]'
  }

  var isArray = Array.isArray || function (obj) {
    /*istanbul ignore next:cant test*/
    return toStr.call(obj) === '[object Array]'
  }

  function isBoolean (obj) {
    return typeof obj === 'boolean' || toString(obj) === '[object Boolean]'
  }

  function getKey (key) {
    var intKey = parseInt(key)
    if (intKey.toString() === key) {
      return intKey
    }
    return key
  }

  function factory (options) {
    options = options || {}

    var objectPath = function (obj) {
      return Object.keys(objectPath).reduce(function (proxy, prop) {
        if (prop === 'create') {
          return proxy
        }

        /*istanbul ignore else*/
        if (typeof objectPath[prop] === 'function') {
          proxy[prop] = objectPath[prop].bind(objectPath, obj)
        }

        return proxy
      }, {})
    }

    var hasShallowProperty
    if (options.includeInheritedProps) {
      hasShallowProperty = function () {
        return true
      }
    } else {
      hasShallowProperty = function (obj, prop) {
        return (typeof prop === 'number' && Array.isArray(obj)) || hasOwnProperty(obj, prop)
      }
    }

    function getShallowProperty (obj, prop) {
      if (hasShallowProperty(obj, prop)) {
        return obj[prop]
      }
    }

    var getShallowPropertySafely
    if (options.includeInheritedProps) {
      getShallowPropertySafely = function (obj, currentPath) {
        if (typeof currentPath !== 'string' && typeof currentPath !== 'number') {
          currentPath = String(currentPath)
        }
        var currentValue = getShallowProperty(obj, currentPath)
        if (currentPath === '__proto__' || currentPath === 'prototype' ||
          (currentPath === 'constructor' && typeof currentValue === 'function')) {
          throw new Error('For security reasons, object\'s magic properties cannot be set')
        }
        return currentValue
      }
    } else {
      getShallowPropertySafely = function (obj, currentPath) {
        return getShallowProperty(obj, currentPath)
      }
    }

    function set (obj, path, value, doNotReplace) {
      if (typeof path === 'number') {
        path = [path]
      }
      if (!path || path.length === 0) {
        return obj
      }
      if (typeof path === 'string') {
        return set(obj, path.split('.').map(getKey), value, doNotReplace)
      }
      var currentPath = path[0]
      var currentValue = getShallowPropertySafely(obj, currentPath)
      if (path.length === 1) {
        if (currentValue === void 0 || !doNotReplace) {
          obj[currentPath] = value
        }
        return currentValue
      }

      if (currentValue === void 0) {
        //check if we assume an array
        if (typeof path[1] === 'number') {
          obj[currentPath] = []
        } else {
          obj[currentPath] = {}
        }
      }

      return set(obj[currentPath], path.slice(1), value, doNotReplace)
    }

    objectPath.has = function (obj, path) {
      if (typeof path === 'number') {
        path = [path]
      } else if (typeof path === 'string') {
        path = path.split('.')
      }

      if (!path || path.length === 0) {
        return !!obj
      }

      for (var i = 0; i < path.length; i++) {
        var j = getKey(path[i])

        if ((typeof j === 'number' && isArray(obj) && j < obj.length) ||
          (options.includeInheritedProps ? (j in Object(obj)) : hasOwnProperty(obj, j))) {
          obj = obj[j]
        } else {
          return false
        }
      }

      return true
    }

    objectPath.ensureExists = function (obj, path, value) {
      return set(obj, path, value, true)
    }

    objectPath.set = function (obj, path, value, doNotReplace) {
      return set(obj, path, value, doNotReplace)
    }

    objectPath.insert = function (obj, path, value, at) {
      var arr = objectPath.get(obj, path)
      at = ~~at
      if (!isArray(arr)) {
        arr = []
        objectPath.set(obj, path, arr)
      }
      arr.splice(at, 0, value)
    }

    objectPath.empty = function (obj, path) {
      if (isEmpty(path)) {
        return void 0
      }
      if (obj == null) {
        return void 0
      }

      var value, i
      if (!(value = objectPath.get(obj, path))) {
        return void 0
      }

      if (typeof value === 'string') {
        return objectPath.set(obj, path, '')
      } else if (isBoolean(value)) {
        return objectPath.set(obj, path, false)
      } else if (typeof value === 'number') {
        return objectPath.set(obj, path, 0)
      } else if (isArray(value)) {
        value.length = 0
      } else if (isObject(value)) {
        for (i in value) {
          if (hasShallowProperty(value, i)) {
            delete value[i]
          }
        }
      } else {
        return objectPath.set(obj, path, null)
      }
    }

    objectPath.push = function (obj, path /*, values */) {
      var arr = objectPath.get(obj, path)
      if (!isArray(arr)) {
        arr = []
        objectPath.set(obj, path, arr)
      }

      arr.push.apply(arr, Array.prototype.slice.call(arguments, 2))
    }

    objectPath.coalesce = function (obj, paths, defaultValue) {
      var value

      for (var i = 0, len = paths.length; i < len; i++) {
        if ((value = objectPath.get(obj, paths[i])) !== void 0) {
          return value
        }
      }

      return defaultValue
    }

    objectPath.get = function (obj, path, defaultValue) {
      if (typeof path === 'number') {
        path = [path]
      }
      if (!path || path.length === 0) {
        return obj
      }
      if (obj == null) {
        return defaultValue
      }
      if (typeof path === 'string') {
        return objectPath.get(obj, path.split('.'), defaultValue)
      }

      var currentPath = getKey(path[0])
      var nextObj = getShallowPropertySafely(obj, currentPath)
      if (nextObj === void 0) {
        return defaultValue
      }

      if (path.length === 1) {
        return nextObj
      }

      return objectPath.get(obj[currentPath], path.slice(1), defaultValue)
    }

    objectPath.del = function del (obj, path) {
      if (typeof path === 'number') {
        path = [path]
      }

      if (obj == null) {
        return obj
      }

      if (isEmpty(path)) {
        return obj
      }
      if (typeof path === 'string') {
        return objectPath.del(obj, path.split('.'))
      }

      var currentPath = getKey(path[0])
      getShallowPropertySafely(obj, currentPath)
      if (!hasShallowProperty(obj, currentPath)) {
        return obj
      }

      if (path.length === 1) {
        if (isArray(obj)) {
          obj.splice(currentPath, 1)
        } else {
          delete obj[currentPath]
        }
      } else {
        return objectPath.del(obj[currentPath], path.slice(1))
      }

      return obj
    }

    return objectPath
  }

  var mod = factory()
  mod.create = factory
  mod.withInheritedProps = factory({includeInheritedProps: true})
  return mod
})


/***/ }),
/* 1222 */
/***/ (function(module, exports) {

/* Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Martin Jatho <m.jatho@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.file');
/**
 * a simple file upload
 * objects of this class represent a single file uplaod
 * 
 * @namespace   Ext.ux.file
 * @class       Ext.ux.file.Upload
 * @extends     Ext.util.Observable
 * 
 * @constructor
 * @param       Object config
 */

Ext.ux.file.Upload = function (config) {
  var _this$file$fileObject, _this$file;

  Ext.apply(this, config);
  Ext.ux.file.Upload.superclass.constructor.apply(this, arguments);
  this.addEvents(
  /**
   * @event uploadcomplete
   * Fires when the upload was done successfully 
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'uploadcomplete',
  /**
   * @event uploadfailure
   * Fires when the upload failed 
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'uploadfailure',
  /**
   * @event uploadprogress
   * Fires on upload progress (html5 only)
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   * @param {XMLHttpRequestProgressEvent}
   */
  'uploadprogress',
  /**
   * @event uploadstart
   * Fires on upload progress (html5 only)
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'uploadstart',
  /**
   * @event uploadstart
   * Fires on upload progress (html5 only)
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'update');
  this.status = 'pending';
  this.promise = new Promise((resolve, reject) => {
    this.resolveFn = resolve;
    this.rejectFn = reject;
  });

  if (!this.file && this.fileSelector) {
    this.file = this.fileSelector.getFileList()[0];
  }

  this.file = (_this$file$fileObject = (_this$file = this.file) === null || _this$file === void 0 ? void 0 : _this$file.fileObject) !== null && _this$file$fileObject !== void 0 ? _this$file$fileObject : this.file;
  this.fileSize = this.file.size ? this.file.size : this.file.fileSize;
  this.maxChunkSize = this.maxPostSize - 16384;
  this.currentChunkSize = this.maxChunkSize;
  this.tempFiles = [];
  this.chunkTasks = [];
};

Ext.extend(Ext.ux.file.Upload, Ext.util.Observable, {
  id: -1,

  /**
   * @cfg {Int} maxFileUploadSize the maximum file size for traditinal form updoads
   */
  maxFileUploadSize: 20971520,
  // 20 MB

  /**
   * @cfg {Int} maxPostSize the maximum post size used for html5 uploads
   */
  maxPostSize: 20971520,
  // 20 MB

  /**
   * @property maxChunkSize the maximum chunk size used for html5 uploads
   * @type Int
   */
  maxChunkSize: 20955136,

  /**
   * @cfg {Int} minChunkSize the minimal chunk size used for html5 uploads
   */
  minChunkSize: 102400,

  /**
   *  max number of upload retries
   */
  MAX_RETRY_COUNT: 10,

  /**
   *  retry timeout in milliseconds
   */
  RETRY_TIMEOUT_MILLIS: 3000,

  /**
   *  retry timeout in milliseconds
   */
  CHUNK_TIMEOUT_MILLIS: 100,

  /**
   * @cfg {String} url the url we upload to
   */
  url: 'index.php',

  /**
   * @cfg {Ext.ux.file.BrowsePlugin} fileSelector
   * a file selector
   */
  fileSelector: null,

  /**
   * coresponding file record
   */
  fileRecord: null,

  /**
   * uploadPath
   */
  uploadPath: '/',

  /**
   * file to upload
   */
  file: null,

  /**
   * is this upload paused
   */
  paused: false,

  /**
   * is this upload queued
   */
  queued: false,

  /**
   * collected tempforary files
   * @property {Array} tempFiles
   */
  tempFiles: null,

  /**
   * did the last chunk upload fail
   */
  lastChunkUploadFailed: false,

  /**
   * how many retries were made while trying to upload current chunk
   */
  retryCount: 0,

  /**
   * size of the current chunk
   */
  currentChunkSize: 0,

  /**
   * where the chunk begins in file (byte number)
   */
  currentChunkPosition: 0,

  /**
   * size of the file to upload
   */
  fileSize: 0,

  /**
   * method for uploading temp file
   */
  uploadTempFileMethod: 'Tinebase.uploadTempFile',

  /**
   * upload progress of the file
   */
  uploadProgress: 0,

  /**
   * creates a form where the upload takes place in
   * @private
   */
  createForm: function createForm() {
    var form = Ext.getBody().createChild({
      tag: 'form',
      action: this.url,
      method: 'post',
      cls: 'x-hidden',
      id: Ext.id(),
      cn: [{
        tag: 'input',
        type: 'hidden',
        name: 'MAX_FILE_SIZE',
        value: this.maxFileUploadSize
      }]
    });
    return form;
  },

  /**
   * perform the upload
   * 
   * @return {Ext.Record} Ext.ux.file.Upload.file
   */
  upload: function upload() {
    if ((!Ext.isGecko && window.XMLHttpRequest && window.File && window.FileList || // safari, chrome, ...?
    Ext.isGecko && window.FileReader // FF
    ) && this.file) {
      // free browse plugin
      this.getInput();

      if (this.isHtml5ChunkedUpload()) {
        // calculate optimal maxChunkSize
        // TODO: own method for chunked upload
        var chunkMax = this.maxChunkSize;
        var chunkMin = this.minChunkSize;
        var actualChunkSize = this.maxChunkSize;

        if (this.fileSize > 5 * chunkMax) {
          actualChunkSize = chunkMax;
        } else {
          actualChunkSize = Math.max(chunkMin, this.fileSize / 5);
        }

        this.maxChunkSize = actualChunkSize;
        this.createFileRecord(false);
        this.fireEvent('uploadstart', this);
        this.fireEvent('update', 'uploadstart', this, this.fileRecord);
        this.html5ChunkedUpload();
        return this.fileRecord;
      } else {
        this.createFileRecord(false);
        this.fireEvent('uploadstart', this);
        this.fireEvent('update', 'uploadstart', this, this.fileRecord);
        this.html5upload();
        return this.fileRecord;
      }
    } else {//not support html4 anymore
    }
  },

  /**
   * 2010-01-26 Current Browsers implemetation state of:
   *  http://www.w3.org/TR/FileAPI
   *  
   *  Interface: File | Blob | FileReader | FileReaderSync | FileError
   *  FF       : yes  | no   | no         | no             | no       
   *  safari   : yes  | no   | no         | no             | no       
   *  chrome   : yes  | no   | no         | no             | no       
   *  
   *  => no json rpc style upload possible
   *  => no chunked uploads posible
   *  
   *  But all of them implement XMLHttpRequest Level 2:
   *   http://www.w3.org/TR/XMLHttpRequest2/
   *  => the only way of uploading is using the XMLHttpRequest Level 2.
   */
  html5upload: function html5upload() {
    // TODO: move to upload method / checks max post size
    if (this.maxPostSize / 1 < this.file.size / 1 && !this.isHtml5ChunkedUpload()) {
      this.fileRecord.html5upload = true;
      this.onUploadFail(null, null, this.fileRecord);
      return this.fileRecord;
    }

    var defaultHeaders = {
      "Content-Type": "application/octet-stream",
      "X-Tine20-Request-Type": "HTTP",
      "X-Requested-With": "XMLHttpRequest"
    };
    var xmlData = this.file;

    if (this.isHtml5ChunkedUpload()) {
      xmlData = this.currentChunk;
    }

    var conn = new Ext.data.Connection({
      disableCaching: true,
      method: 'POST',
      url: this.url + '?method=' + this.uploadTempFileMethod,
      timeout: 300000,
      // 5 mins
      defaultHeaders: defaultHeaders
    });
    var transaction = conn.request({
      headers: {
        "X-File-Name": window.btoa(unescape(encodeURIComponent(this.fileRecord.get('name')))),
        "X-File-Type": this.fileRecord.get('type'),
        "X-File-Size": this.fileRecord.get('size')
      },
      xmlData: xmlData,
      success: this.onUploadSuccess.createDelegate(this, null, true),
      failure: this.onUploadFail.createDelegate(this, null, true)
    });
    return this.fileRecord;
  },

  /**
   * Starting chunked file upload
   * 
   * @param {Boolean} whether this restarts a paused upload
   */
  html5ChunkedUpload: function html5ChunkedUpload() {
    this.prepareChunk();
    this.html5upload();
  },

  /**
   * resume this upload
   */
  resumeUpload: function resumeUpload() {
    this.setPaused(false);
    this.html5ChunkedUpload();
  },

  /**
   * calculation the next chunk size and slicing file
   */
  prepareChunk: function prepareChunk() {
    if (this.lastChunkUploadFailed) {
      this.currentChunkPosition = Math.max(0, this.currentChunkPosition - this.currentChunkSize);
      this.currentChunkSize = Math.max(this.minChunkSize, this.currentChunkSize / 2);
    } else {
      this.currentChunkSize = Math.min(this.maxChunkSize, this.currentChunkSize * 2);
    }

    this.lastChunkUploadFailed = false;
    var nextChunkPosition = Math.min(this.fileSize, this.currentChunkPosition + this.currentChunkSize);
    var newChunk = this.sliceFile(this.file, this.currentChunkPosition, nextChunkPosition);

    if (nextChunkPosition / 1 == this.fileSize / 1) {
      this.lastChunk = true;
    }

    this.currentChunkPosition = nextChunkPosition;
    this.currentChunk = newChunk;
  },

  /**
   * Setting final fileRecord states
   */
  finishUploadRecord: function finishUploadRecord(response) {
    response = Ext.util.JSON.decode(response.responseText);

    if (response.tempFile) {
      response = response.tempFile;
    }

    this.uploadProgress = 99;

    if (response.error === 0) {
      this.fileRecord.beginEdit();
      this.fileRecord.set('size', response.size);
      this.fileRecord.set('id', response.id);
      this.fileRecord.set('progress', this.uploadProgress);
      this.fileRecord.set('tempFile', '');
      this.fileRecord.set('tempFile', response);

      try {
        this.fileRecord.commit(false);
      } catch (e) {
        console.log(e);
      }

      this.fireEvent('uploadcomplete', this, this.fileRecord);
      this.fireEvent('update', 'uploadcomplete', this, this.fileRecord);
      this.resolveFn(this);
    } else {
      this.uploadProgress = -1;
      this.status = 'failure';
      this.fileRecord.beginEdit();
      this.fileRecord.set('status', this.status);
      this.fileRecord.set('progress', this.uploadProgress);
      this.fileRecord.set('tempFile', '');
      this.fileRecord.set('tempFile', response);
      this.fileRecord.commit(false);
      this.fireEvent('uploadfailure', this, this.fileRecord);
      this.fireEvent('update', 'uploadfailure', this, this.fileRecord);
      this.rejectFn(this);
    }
  },

  /**
   * executed if a chunk or file got uploaded successfully
   */
  onUploadSuccess: function onUploadSuccess(response, options, fileRecord) {
    var responseObj = Ext.util.JSON.decode(response.responseText);
    this.retryCount = 0;

    if (responseObj.status && responseObj.status !== 'success') {
      this.onUploadFail(responseObj, options, fileRecord);
    }

    this.fileRecord.beginEdit();
    this.fileRecord.set('tempFile', responseObj.tempFile);
    this.fileRecord.set('size', 0);

    try {
      this.fileRecord.commit(false);
    } catch (e) {
      console.log(e);
    }

    this.fireEvent('uploadprogress', this, this.fileRecord);

    if (!this.isHtml5ChunkedUpload()) {
      this.finishUploadRecord(response);
    } else {
      this.addTempfile(this.fileRecord.get('tempFile'));
      var percent = parseInt(this.currentChunkPosition * 100 / this.fileSize / 1);

      if (this.lastChunk) {
        percent = 98;
      }

      this.uploadProgress = percent;
      this.status = 'uploading';
      this.fileRecord.beginEdit();
      this.fileRecord.set('progress', this.uploadProgress);

      try {
        fileRecord.commit(false);
      } catch (e) {
        console.log(e);
      }

      if (this.lastChunk) {
        window.setTimeout(function () {
          Ext.Ajax.request({
            timeout: 10 * 60 * 1000,
            // Overriding Ajax timeout - important!
            params: {
              method: 'Tinebase.joinTempFiles',
              tempFilesData: this.tempFiles
            },
            success: this.finishUploadRecord.createDelegate(this),
            failure: _.bind(function (response, request) {
              let msg = formatMessage('Error while uploading "{fileName}". Please try again later.', {
                fileName: this.fileRecord.get('name')
              });
              Ext.MessageBox.alert(formatMessage('Upload Failed'), msg).setIcon(Ext.MessageBox.ERROR);
            }, this)
          });
        }.createDelegate(this), this.CHUNK_TIMEOUT_MILLIS);
      } else {
        window.setTimeout(function () {
          if (!this.isPaused()) {
            this.prepareChunk();
            this.html5upload();
          }
        }.createDelegate(this), this.CHUNK_TIMEOUT_MILLIS);
      }
    }
  },

  /**
   * executed if a chunk / file upload failed
   */
  onUploadFail: function onUploadFail(response, options, fileRecord) {
    this.status = 'failure';

    if (this.isHtml5ChunkedUpload()) {
      this.lastChunkUploadFailed = true;
      this.retryCount++;

      if (this.retryCount > this.MAX_RETRY_COUNT) {
        this.fileRecord.beginEdit();
        this.fileRecord.set('status', this.status);
        this.fileRecord.endEdit();
        this.fireEvent('uploadfailure', this, this.fileRecord);
        this.rejectFn(this);
      } else {
        window.setTimeout(function () {
          this.prepareChunk();
          this.html5upload();
        }.createDelegate(this), this.RETRY_TIMEOUT_MILLIS);
      }
    } else {
      this.fileRecord.beginEdit();
      this.fileRecord.set('status', this.status);
      this.fileRecord.endEdit();
      this.fireEvent('uploadfailure', this, this.fileRecord);
      this.rejectFn(this);
    }
  },

  /**
   * creating initial fileRecord for this upload
   */
  createFileRecord: function createFileRecord(pending) {
    this.status = "uploading";

    if (pending) {
      this.status = "pending";
    }

    this.uploadProgress = 0;
    this.fileRecord = new Ext.ux.file.Upload.file({
      name: this.file.name ? this.file.name : this.file.fileName,
      // safari and chrome use the non std. fileX props
      type: this.file.type ? this.file.type : this.file.fileType,
      // missing if safari and chrome
      size: 0,
      status: this.status,
      progress: this.uploadProgress,
      input: this.file,
      uploadKey: this.id,
      promise: this.promise
    });
    this.fireEvent('uploadinitial', this, this.fileRecord);
  },

  /**
   * adding temporary file to array
   *
   * @param tempFile
   */
  addTempfile: function addTempfile(tempFile) {
    this.tempFiles.push(tempFile);
    return true;
  },

  /**
   * returns the temporary files
   * 
   * @returns {Array} temporary files
   */
  getTempfiles: function getTempfiles() {
    return this.tempFiles;
  },

  /**
   * pause oder resume file upload
   * 
   * @param paused {Boolean} set true to pause file upload
   */
  setPaused: function setPaused(paused) {
    this.paused = paused;
    this.status = 'paused';

    if (!this.paused) {
      this.status = 'uploading';
    }

    this.fileRecord.beginEdit();
    this.fileRecord.set('status', this.status);
    this.fileRecord.endEdit();
    this.fireEvent('update', 'uploadpaused', this, this.fileRecord);
  },

  /**
   * indicates whether this upload ist paused
   * 
   * @returns {Boolean}
   */
  isPaused: function isPaused() {
    return this.paused;
  },

  /**
   * checks for the existance of a method of an object
   * 
   * @param object    {Object}
   * @param property  {String} method name 
   * @returns {Boolean}
   */
  isHostMethod: function isHostMethod(object, property) {
    var t = typeof object[property];
    return t == 'function' || !!(t == 'object' && object[property]) || t == 'unknown';
  },

  /**
   * indicates whether the current browser supports der File.slice method
   * 
   * @returns {Boolean}
   */
  isHtml5ChunkedUpload: function isHtml5ChunkedUpload() {
    if (window.File === undefined) return false;

    if (this.isHostMethod(File.prototype, 'slice') || this.isHostMethod(File.prototype, 'mozSlice') || this.isHostMethod(File.prototype, 'webkitSlice')) {
      return this.fileSize > this.minChunkSize;
    } else {
      return false;
    }
  },
  // private
  getInput: function getInput() {
    // NOTE: when a file got downloaded via url (CORS/xhr2) we don't have a input here
    if (!this.input && this.fileSelector && Ext.isFunction(this.fileSelector.detachInputFile)) {
      this.input = this.fileSelector.detachInputFile();
    }

    return this.input;
  },
  getProgress: function getProgress() {
    return this.uploadProgress;
  },

  getTotalUploadByte() {
    this.totalUploadByte = this.fileSize * this.uploadProgress / 100;
    return this.totalUploadByte;
  },

  /**
   * slices the given file
   * 
   * @param file  File object
   * @param start start position
   * @param end   end position            
   * @param type  file type
   * @returns
   */
  sliceFile: function sliceFile(file, start, end, type) {
    if (file.slice) {
      return file.slice(start, end);
    } else if (file.mozSlice) {
      return file.mozSlice(start, end, type);
    } else if (file.webkitSlice) {
      return file.webkitSlice(start, end);
    } else {
      return false;
    }
  },

  /**
   * sets dthe queued state of this upload
   * 
   * @param queued {Boolean}
   */
  setQueued: function setQueued(queued) {
    this.queued = queued;
    this.status = 'queued';

    if (!this.queued) {
      this.status = 'uploading';
    }

    this.fileRecord.beginEdit();
    this.fileRecord.set('status', this.status);
    this.fileRecord.endEdit();
    this.fireEvent('update', 'uploadqueued', this, this.fileRecord);
  },

  /**
   * indicates whether this upload is queued
   * 
   * @returns {Boolean}
   */
  isQueued: function isQueued() {
    return this.queued;
  }
});
/**
 * upload file record
 */

Ext.ux.file.Upload.file = Ext.data.Record.create([{
  name: 'id',
  type: 'text',
  system: true
}, {
  name: 'uploadKey',
  type: 'text',
  system: true
}, {
  name: 'name',
  type: 'text',
  system: true
}, {
  name: 'size',
  type: 'number',
  system: true
}, {
  name: 'type',
  type: 'text',
  system: true
}, {
  name: 'status',
  type: 'text',
  system: true
}, {
  name: 'progress',
  type: 'number',
  system: true
}, {
  name: 'form',
  system: true
}, {
  name: 'input',
  system: true
}, {
  name: 'url',
  system: true
}, {
  name: 'request',
  system: true
}, {
  name: 'promise',
  system: true
}, {
  name: 'path',
  system: true
}, {
  name: 'tempFile',
  system: true
}]);

Ext.ux.file.Upload.file.prototype.toString = function () {
  const data = Ext.ux.file.Upload.file.getFileData(this);
  return JSON.stringify(data);
};

Ext.ux.file.Upload.file.getFileData = function (file) {
  return Ext.copyTo({}, file.data, ['tempFile', 'name', 'path', 'size', 'type', 'id']);
};

/***/ }),
/* 1223 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license      New BSD License
 * @author       loeppky - based on the work done by MaximGB in Ext.ux.UploadDialog (http://extjs.com/forum/showthread.php?t=21558)
 * @author       Michael Spahn <m.spahn@metaways.de>
 * @copyright    Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.file');
/**
 * @namespace   Ext.ux.file
 * @class       Ext.ux.file.BrowsePlugin
 * @param       {Object} config Configuration options
 */

Ext.ux.file.BrowsePlugin = function (config) {
  Ext.apply(this, config);
};
/**
 * @TODO: proxy mouse events
 */


Ext.ux.file.BrowsePlugin.prototype = {
  /**
   * @cfg {Boolean} allowFolder
   * allow folder to be selected (HTML 5 only)
   */
  allowFolder: false,

  /**
   * @cfg {Boolean} multiple
   * allow multiple files to be selected (HTML 5 only)
   */
  multiple: true,

  /**
   * @cfg {Ext.Element} dropEl
   * element used as drop target if enableFileDrop is enabled
   */
  dropEl: null,

  /**
   * @cfg {Boolean} enableFileDrop
   * @see http://www.w3.org/TR/2008/WD-html5-20080610/editing.html
   *
   * enable drops from OS (defaults to true)
   */
  enableFileDrop: true,

  /**
   * @cfg {Boolean} enableFileDialog
   *
   * enable file dialog on click(defaults to true)
   */
  enableFileDialog: true,

  /**
   * @cfg {String} inputFileName
   * Name to use for the hidden input file DOM element.  Deaults to "file".
   */
  inputFileName: 'file',

  /**
   * @cfg {Function} onBrowseButtonClick
   */
  onBrowseButtonClick: Ext.emptyFn,

  /**
   * @property inputFileEl
   * @type Ext.Element
   * Element for the hidden file input.
   * @private
   */
  input_file: null,

  /**
   * @cfg handler
   * @type Function
   * The handler originally defined for the Ext.Button during construction using the "handler" config option.
   * We need to null out the "handler" property so that it is only called when a file is selected.
   * @private
   */
  handler: null,

  /**
   * @cfg scope
   * @type Object
   * The scope originally defined for the Ext.Button during construction using the "scope" config option.
   * While the "scope" property doesn't need to be nulled, to be consistent with handler, we do.
   * @private
   */
  scope: null,
  currentTreeNodeUI: null,

  /**
   * @see Ext.Button.initComponent
   */
  init: function init(cmp) {
    this.component = cmp;

    if (cmp.handler && !Ext.isFunction(this.handler)) {
      this.handler = cmp.handler;
      cmp.handler = null;
      this.scope = cmp.scope || window;
      cmp.scope = null;
    }

    cmp.on('afterrender', this.onRender, this);
    cmp.on('destroy', this.onDestroy, this);
  },

  /**
   * drag and drop
   */
  onDragLeave: function onDragLeave(e) {
    e.stopPropagation();
    e.preventDefault();
    this.component.el.applyStyles(' background-color: transparent');
  },
  onDragOver: function onDragOver(e) {
    e.stopPropagation();
    e.preventDefault();
    this.component.el.applyStyles(' background-color: #ebf0f5');
  },
  onDrop: function onDrop(e) {
    e.stopPropagation();
    e.preventDefault();
    this.component.el.applyStyles(' background-color: transparent');
    this.onBrowseButtonClick();
    this.onInputFileChange(e);
  },
  onRender: function onRender() {
    var me = this;

    if (me.enableFileDialog) {
      me.component.on('enable', this.onEnable, this);
      me.component.on('disable', this.onDisable, this);
      me.component.el.dom.addEventListener('click', function () {
        // no input on split area
        if (me.component.split && me.component.el.getBox().right - Ext.EventObject.getXY()[0] < 18) {
          return;
        }

        me.input_file.click();
      });
      me.createInputFile();
    }

    if (me.enableFileDrop && !Ext.isIE) {
      if (me.dropElSelector) {
        me.dropEl = me.component.el.up(me.dropElSelector);
      } else {
        me.dropEl = me.component.el;
      }

      me.dropEl.on('dragleave', me.onDragLeave, me);
      me.dropEl.on('dragover', me.onDragOver, me);
      me.dropEl.on('drop', me.onDrop, me);
    }
  },

  /**
   * clean up
   */
  onDestroy: function onDestroy() {
    this.input_file = null;

    if (this.dropEl) {
      this.dropEl.un('dragleave', this.onDragLeave, this);
      this.dropEl.un('dragover', this.onDragOver, this);
      this.dropEl.un('drop', this.onDrop, this);
      this.dropEl = null;
    }
  },
  onEnable: function onEnable() {
    this.setDisabled(false);
  },
  onDisable: function onDisable() {
    this.setDisabled(true);
  },
  setDisabled: function setDisabled(disabled) {
    this.input_file.disabled = disabled;
  },
  createInputFile: function createInputFile() {
    this.input_file = document.createElement('input');
    this.input_file.setAttribute('name', this.inputFileName || Ext.id(this.component.el));
    this.input_file.setAttribute('type', 'file');
    this.input_file.setAttribute('style', 'display: none;');
    this.input_file.multiple = this.multiple; // we can not select file and folder at the same time

    this.input_file.webkitdirectory = this.allowFolder;
    this.component.el.dom.appendChild(this.input_file);
    this.input_file.addEventListener('change', this.onInputFileChange.bind(this), false);
    this.input_file.addEventListener('click', function (e) {
      e.stopPropagation();
    });
  },

  /**
   * Handler when inputFileEl changes value (i.e. a new file is selected).
   * @param e
   * @private
   */
  onInputFileChange: async function onInputFileChange(e) {
    // easy cope with directories
    const fs = await __webpack_require__(2724);
    const files = await fs.getDroppedOrSelectedFiles(e.browserEvent || e);

    if (files) {
      this.files = files;
    } else {
      if (e.dataTransfer) {
        this.files = e.dataTransfer.files;
      } else {
        this.files = e.target.files;
      }
    }

    if (!_.isFunction(e.getTarget)) {
      // backwards compatibility
      e.getTarget = function () {
        return this.target;
      };
    }

    if (this.handler) {
      this.handler.call(this.scope, this, e);
    }

    _.delay(() => {
      this.input_file.value = '';
    }, 1000);
  },
  getFileList: function getFileList() {
    return this.files;
  },

  /**
   * @return {Ext.Element} the input file element
   */
  getInputFile: function getInputFile() {
    return this.input_file;
  },

  /**
   * get file name
   * @return {String}
   */
  getFileName: function getFileName() {
    var file = this.getFileList()[0];
    return file.name ? file.name : file.fileName;
  },

  /**
   * returns file class based on name extension
   * @return {String} class to use for file type icon
   */
  getFileCls: function getFileCls() {
    var fparts = this.getFileName().split('.');

    if (fparts.length === 1) {
      return '';
    } else {
      return fparts.pop().toLowerCase();
    }
  },
  isImage: function isImage() {
    var cls = this.getFileCls();
    return cls === 'jpg' || cls === 'gif' || cls === 'png' || cls === 'jpeg';
  }
};
Ext.preg('ux.browseplugin', Ext.ux.file.BrowsePlugin);

/***/ }),
/* 1224 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.file');
/**
 * @namespace   Ext.ux.file
 * @class       Ext.ux.file.Download
 * @extends     Ext.util.Observable
 */

Ext.ux.file.Download = function (config) {
  config = config || {};
  Ext.apply(this, config);
  Ext.ux.file.Download.superclass.constructor.call(this);
  this.addEvents({
    'success': true,
    'fail': true,
    'abort': true
  });
};

Ext.extend(Ext.ux.file.Download, Ext.util.Observable, {
  url: 'index.php',
  method: 'POST',
  params: null,
  timeout: 1800000,
  // 30 minutes

  /**
   * @private 
   */
  form: null,
  transactionId: null,

  /**
   * start download
   */
  start: function start() {
    this.form = Ext.getBody().createChild({
      tag: 'form',
      method: this.method,
      cls: 'x-hidden'
    });
    var con = new Ext.data.Connection({
      // firefox specific problem -> see http://www.extjs.com/forum/archive/index.php/t-44862.html
      //  "It appears that this is because the "load" is completing once the initial download dialog is displayed, 
      //  but the frame is then destroyed before the "save as" dialog is shown."
      //
      // TODO check if we can handle firefox event 'onSaveAsSubmit' (or something like that)
      //
      debugUploads: Ext.isGecko
    });
    this.transactionId = con.request({
      isUpload: true,
      form: this.form,
      params: this.params,
      scope: this,
      success: this.onSuccess,
      failure: this.onFailure,
      url: this.url,
      timeout: this.timeout
    }); // NOTE: success callback (iframe load) is not triggered with content-disposition: 'attachment' 
    //       as the iframe technically is not loaded

    _.delay(_.bind(this.onSuccess, this), 2000);

    return this;
  },

  /**
   * abort download
   */
  abort: function abort() {
    Ext.Ajax.abort(this.transactionId);
    this.form.remove();
    this.fireEvent('abort', this);
  },

  /**
   * @private
   * 
   */
  onSuccess: function onSuccess() {
    this.form.remove();
    this.fireEvent('success', this);
  },

  /**
   * @private
   * 
   */
  onFailure: function onFailure() {
    this.form.remove();
    this.fireEvent('fail', this);
  }
});

Ext.ux.file.Download.start = function (config) {
  return new Promise((resolve, reject) => {
    const dl = new Ext.ux.file.Download(config);
    dl.on('success', resolve);
    dl.on('fail', reject);
    dl.start();
  });
};

/***/ }),
/* 1225 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ColorField
 * @extends     Ext.form.TriggerField
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * Provides a color input field with a {@link Ext.menu.ColorMenu} dropdown.
 * @constructor Create a new ColorField
 * @param {Object} config
 * @xtype colorfield
 */

Ext.ux.form.ColorField = Ext.extend(Ext.form.TriggerField, {
  listWidth: 150,
  editable: false,
  color: null,
  // private
  initComponent: function initComponent() {
    Ext.ux.form.ColorField.superclass.initComponent.call(this);
    this.store = new Ext.data.Store({});
    this.addEvents(
    /**
     * @event select
     * Fires when a color is selected via the color picker.
     * @param {Ext.form.ColorField} this
     * @param {String} color The color that was selected
     */
    'select');
    this.on('afterrender', this.onAfterRender, this, {
      buffer: 500
    });
  },
  onAfterRender: function onAfterRender() {
    // if used as gridEditor
    if (this.inEditor) {
      var editorWrapEl = this.el.up('.x-grid-editor', 5);

      if (editorWrapEl) {
        this.editor = Ext.getCmp(editorWrapEl.id);
        this.editor.allowBlur = true;
        this.onTriggerClick();
      }
    }
  },
  // private
  onDestroy: function onDestroy() {
    Ext.destroy(this.menu);
    Ext.ux.form.ColorField.superclass.onDestroy.call(this);
  },
  //private
  onTriggerClick: function onTriggerClick() {
    if (this.disabled) {
      return;
    }

    if (this.menu == null) {
      this.menu = new Ext.menu.ColorMenu({
        hideOnClick: false,
        value: this.color,
        listeners: {
          scope: this,
          select: this.onSelect,
          pickerShow: this.onPickerShow
        }
      });
    }

    this.onFocus();
    this.menuEvents('on');
    this.menu.show(this.el, "tl-bl?");
  },
  setValue: function setValue(color) {
    color = color || '#FFFFFF';
    this.color = color;
    this.el.setStyle('background', color);
    this.el.setStyle('color', color);
    return Ext.ux.form.ColorField.superclass.setValue.call(this, color);
  },
  //private
  menuEvents: function menuEvents(method) {
    this.menu[method]('hide', this.onMenuHide, this);
    this.menu[method]('show', this.onMenuShow, this);
  },
  //private
  onSelect: function onSelect(m, d) {
    this.setValue('#' + d);
    this.fireEvent('select', this, '#' + d);

    if (this.inEditor && this.editor) {
      this.editor.completeEdit();
    }

    this.menu.hide();
  },
  //private
  onMenuShow: function onMenuShow() {
    // manage z-index by windowMgr
    this.menu.setActive = Ext.emptyFn;
    this.menu.setZIndex = Ext.emptyFn;
    Ext.WindowMgr.register(this.menu);
    Ext.WindowMgr.bringToFront(this.menu);
    this.onFocus();
  },
  //private
  onPickerShow: function onPickerShow(win) {
    // win is shown in a menu! ok btn is outside the menu and thus
    // menu is hidden -> editing is canceled!
    win.on('close', () => {
      this.colorPickerWindow = null;
    });
    this.colorPickerWindow = win;
  },
  //private
  onMenuHide: function onMenuHide() {
    this.focus(false, 60);
    this.menuEvents('un');
    Ext.WindowMgr.unregister(this.menu);

    if (this.inEditor && this.editor && !this.colorPickerWindow) {
      this.editor.cancelEdit();
    }
  }
});
Ext.reg('colorfield', Ext.ux.form.ColorField);

/***/ }),
/* 1226 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * Class for creating text-fields with an icon in front of the label.
 * <p>Example usage:</p>
 * <pre><code>
 var field =  new Ext.ux.form.IconTextField({
     labelIcon: 'images/oxygen/16x16/actions/mail.png'
     fieldLabel: 'email',
     name: 'email',
 });
 * </code></pre>
 * 
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.IconTextField
 * @extends     Ext.form.TextField
 */

Ext.ux.form.IconTextField = Ext.extend(Ext.form.TextField, {
  /**
   * @cfg {String} LabelIcon icon to be displayed in front of the label
   */
  labelIcon: '',

  /**
   * @private
   */
  initComponent: function initComponent() {
    Ext.ux.form.IconTextField.superclass.initComponent.call(this);

    if (this.labelIcon.length > 0) {
      this.fieldLabel = '<img src="' + this.labelIcon + '" class="x-ux-form-icontextfield-labelicon">' + this.fieldLabel;
    }
  }
});
Ext.reg('icontextfield', Ext.ux.form.IconTextField);

/***/ }),
/* 1227 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * Class for creating equal text-fields multiple times in a form.
 * If a value gets changed in one of the fields, all other will be updated
 * <p>Example usage:</p>
 * <pre><code>
 var dialog =  new Ext.Panel({
     layout: 'form',
     items: [
         {
             fieldLabel: 'First occurrence',
             xtype: 'mirrortextfield',
             name: 'themirrorfiled'
         },{
             fieldLabel: 'Normal field',
             xtype: 'textfield',
             name: 'someotherfield'
         },{
             fieldLabel: 'Second occurrence',
             xtype: 'mirrortextfield',
             name: 'themirrorfiled'
         },
     ]
 });
 * </code></pre>
 * 
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.MirrorTextField
 * @extends     Ext.ux.form.IconTextField
 */

Ext.ux.form.MirrorTextField = Ext.extend(Ext.ux.form.IconTextField, {
  /**
   * @private
   */
  initComponent: function initComponent() {
    Ext.ux.form.MirrorTextField.superclass.initComponent.call(this);
    Ext.ux.form.MirrorTextFieldManager.register(this);
  },

  /**
   * @private
   */
  setValue: function setValue(value) {
    Ext.ux.form.MirrorTextFieldManager.setAll(this, value);
  },

  /**
   * @private
   */
  onDestroy: function onDestroy() {
    if (this.rendered) {
      Ext.ux.form.MirrorTextFieldManager.unregister(this);
    }
  }
});
Ext.reg('mirrortextfield', Ext.ux.form.MirrorTextField);
/**
 * Helper for Ext.ux.form.MirrorTextField
 * @singleton
 */

Ext.ux.form.MirrorTextFieldManager = function () {
  var MirrorTextFields = {};

  function MirrorField(field, newValue, oldValue) {
    var m = MirrorTextFields[field.name];

    for (var i = 0, l = m.length; i < l; i++) {
      m[i].setRawValue(newValue);
    }

    return true;
  }

  return {
    register: function register(field) {
      var m = MirrorTextFields[field.name];

      if (!m) {
        m = MirrorTextFields[field.name] = [];
      }

      m.push(field);
      field.on("change", MirrorField);
    },
    unregister: function unregister(field) {
      var m = MirrorTextFields[field.name];

      if (m) {
        m.remove(field);
        field.un("change", MirrorField);
      }
    },
    setAll: function setAll(field, value) {
      var m = MirrorTextFields[field.name];

      if (m) {
        MirrorField(field, value);
      }
    }
  };
}();

/***/ }),
/* 1228 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ColumnFormPanel
 * @description
 * Helper Class for creating form panels with a horizontal layout. This class could be directly
 * created using the new keyword or by specifying the xtype: 'columnform'
 * Example usage:</p>
 * <pre><code>
var p = new Ext.ux.form.ColumnFormPanel({
    title: 'Horizontal Form Layout',
    items: [
        [
            {
                columnWidth: .6,
                fieldLabel:'Company Name', 
                name:'org_name'
            },
            {
                columnWidth: .4,
                fieldLabel:'Street', 
                name:'adr_one_street'
            }
        ],
        [
            {
                columnWidth: .7,
                fieldLabel:'Region',
                name:'adr_one_region'
            },
            {
                columnWidth: .3,
                fieldLabel:'Postal Code', 
                name:'adr_one_postalcode'
            }
        ]
    ]
});
</code></pre>
 */

Ext.ux.form.ColumnFormPanel = Ext.extend(Ext.Panel, {
  formDefaults: {
    xtype: 'icontextfield',
    anchor: '100%',
    labelSeparator: '',
    columnWidth: .333
  },
  layout: 'hfit',
  labelAlign: 'top',

  /**
   * @private
   */
  initComponent: function initComponent() {
    var items = []; // each item is an array with the config of one row

    for (var i = 0, j = this.items.length; i < j; i++) {
      var initialRowConfig = this.items[i];
      var rowConfig = {
        xtype: 'container',
        border: false,
        layout: 'column',
        items: [],
        listeners: {
          scope: this,
          beforeadd: this.onBeforeAddFromItem
        }
      }; // each row consits n column objects

      for (var n = 0, m = initialRowConfig.length; n < m; n++) {
        var column = initialRowConfig[n],
            cell = this.wrapFormItem(column);
        rowConfig.items.push(cell);
      }

      items.push(rowConfig);
    }

    this.items = items;
    Ext.ux.form.ColumnFormPanel.superclass.initComponent.call(this);
  },
  onBeforeAddFromItem: function onBeforeAddFromItem(column, c, index) {
    if (!c.isWraped) {
      var cell = this.wrapFormItem(c),
          rowItems = [cell].concat(column.items.items),
          totalWidth = 0; // normalize columnWidth to fit in row

      Ext.each(rowItems, function (c) {
        totalWidth += c.columnWidth || 0;
      });
      Ext.each(rowItems, function (c) {
        if (c.columnWidth) {
          c.columnWidth = c.columnWidth / totalWidth;
        }
      });
      column.insert(index, cell);
      return false;
    }
  },
  wrapFormItem: function wrapFormItem(c) {
    var cell = {
      isWraped: true,
      columnWidth: c.columnWidth ? c.columnWidth : this.formDefaults.columnWidth,
      layout: 'form',
      labelAlign: this.labelAlign,
      defaults: this.formDefaults,
      bodyStyle: 'padding-left: 2px; padding-right: 2px;',
      border: false,
      items: c
    };

    if (c.width) {
      cell.width = c.width;
      delete cell.columnWidth;
    }

    return cell;
  }
});
Ext.reg('columnform', Ext.ux.form.ColumnFormPanel);

/***/ }),
/* 1229 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * A NumberField allows to force decimals and prefix, suffix handling
 * 
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.NumberField
 * @extends     Ext.form.NumberField
 */

Ext.ux.form.NumberField = Ext.extend(Ext.form.NumberField, {
  /**
   * shall the thousand operator be shown?
   * 
   * @type {Boolean}
   */
  useThousandSeparator: true,

  /**
   * allows a prefix before the value
   * 
   * @type {String}
   */
  suffix: null,

  /**
   * allows a suffix after the value
   * 
   * @type {String}
   */
  prefix: null,
  initComponent: function initComponent() {
    if (this.useThousandSeparator) {
      this.thousandSeparator = this.thousandSeparator ? this.thousandSeparator : this.decimalSeparator == '.' ? ',' : '.';
    }

    Ext.ux.form.NumberField.superclass.initComponent.call(this);
    this.on('focus', this.emptyField, this);
    this.on('keydown', function (cmp, e) {
      if (e.getKey() === e.ENTER) {
        this.onBlur();
      }
    }, this);
  },
  emptyField: function emptyField() {
    if (this.getValue() == '0') {
      this.setRawValue("");
    }
  },

  /**
   * @see Ext.form.NumberField
   * 
   * if decimalSeparator is not ".", the decimals won't be shown if 0 in superclass, so fix it here
   * 
   * @param {String} v
   * @return {Ext.form.ComboBox}
   */
  setValue: function setValue(v) {
    // If empty string!
    if (v == "") {
      v = "0";
    }

    Ext.ux.form.NumberField.superclass.setValue.call(this, v);
    var split = String(this.getValue()).split('.');
    var tenString = split[0];
    var prefix = '';

    if (tenString[0] == '-') {
      tenString = tenString.substr(1);
      prefix = '-';
    }

    if (split.length == 1) {
      var decimalString = '';
    } else {
      var decimalString = split[1];
    }

    while (this.allowDecimals && decimalString.length < this.decimalPrecision) {
      decimalString += '0';
    }

    var tenStringValue = tenString;

    if (this.useThousandSeparator && tenString.length > 3) {
      var tenStringValue = '';
      var stringIndex = 0;
      var firstLength = tenString.length % 3;

      if (firstLength) {
        while (stringIndex < firstLength) {
          tenStringValue += tenString[stringIndex];
          stringIndex++;
        }

        tenStringValue += this.thousandSeparator;
      }

      var i = 0;

      while (stringIndex < tenString.length) {
        tenStringValue += tenString[stringIndex];
        stringIndex++;
        i++;

        if (i == 3 && stringIndex != tenString.length) {
          i = 0;
          tenStringValue += this.thousandSeparator;
        }
      }
    }

    var showValue = (this.prefix ? this.prefix : '') + tenStringValue + (this.decimalSeparator && decimalString ? this.decimalSeparator : '') + decimalString + (this.suffix ? this.suffix : '');
    this.setRawValue(prefix + showValue); // remove invalid after fix decimalPrecision

    this.clearInvalid();
    return this;
  },
  // private, overwrites Ext.form.NumberField.parseValue
  parseValue: function parseValue(value) {
    if (!value) {
      return value;
    }

    if (this.useThousandSeparator) {
      var regex = new RegExp(this.thousandSeparator == "." ? '\\.' : this.thousandSeparator, 'g');
      value = value.replace(regex, '');
    }

    value = String(value).replace(regex, '', 'g');
    value = parseFloat(String(value).replace(this.decimalSeparator, "."));
    value = isNaN(value) ? '' : value;
    return value;
  },

  /**
   * @see Ext.form.NumberField
   * 
   * strips the prefix and suffix before superclass is validating
   * 
   * @param {String} value
   * @return {String}
   */
  validateValue: function validateValue(value) {
    if (value && this.prefix) {
      var regex = new RegExp(this.prefix, 'g');
      value = value.replace(regex, '');
    }

    if (value && this.suffix) {
      var regex = new RegExp(this.suffix, 'g');
      value = value.replace(regex, '');
    }

    if (value && this.useThousandSeparator) {
      var regex = new RegExp(this.thousandSeparator == "." ? '\\.' : this.thousandSeparator, 'g');
      value = value.replace(regex, '');
    }

    const decimalRe = new RegExp(this.decimalSeparator === "." ? '\\.' : this.decimalSeparator, 'g');

    if (value && !this.allowDecimals && String(value).match(decimalRe)) {
      this.markInvalid(Tine.Tinebase.i18n._('no decimals allowed'));
      return false;
    }

    if (value && this.allowDecimals && String(value).match(decimalRe)) {
      const parts = value.split(decimalRe);

      if (parts[1].length > this.decimalPrecision) {
        this.markInvalid(String.format(Tine.Tinebase.i18n._('max decimals allowed: {0}'), this.decimalPrecision));
        return false;
      }
    }

    return Ext.ux.form.NumberField.superclass.validateValue.call(this, value);
  }
});
Ext.reg('extuxnumberfield', Ext.ux.form.NumberField);

/***/ }),
/* 1230 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext*/
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * A combination range and paging control
 *
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.PeriodPicker
 * @extends     Ext.form.Field
 */

Ext.ux.form.PeriodPicker = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {String} availableRanges
   * ranges available in range picker
   * _('Day'), _('Week'), _('Month'), _('Quarter'), _('Year')
   */
  availableRanges: 'day,week,month,quarter,year',

  /**
   * @cfg {String} range
   * initial range
   */
  range: 'month',

  /**
   * @cfg {Date} startDate
   * defaults to toDay, will be constraint to period, gets overwritten by value
   */
  startDate: null,

  /**
   * @cfg {Boolean} periodIncludesUntil
   * the period includes until timestamp
   */
  periodIncludesUntil: false,
  initComponent: function initComponent() {
    Ext.ux.form.PeriodPicker.superclass.initComponent.call(this);
    this.value = Ext.ux.form.PeriodPicker.getPeriod(this.value ? this.value.from : this.startDate || new Date(), this.range, this.periodIncludesUntil);
    this.startDate = this.value.from;
    this.startValue = this.value;
  },

  /**
   * @return {Object} {from: Date, until: Date}
   */
  getValue: function getValue() {
    return this.value;
  },

  /**
   * @param {Object} value {from: Date, until: Date}
   */
  setValue: function setValue(value) {
    value.from = Ext.isDate(value.from) ? value.from : Date.parseDate(value.from, Date.patterns.ISO8601Long);
    value.until = Ext.isDate(value.until) ? value.until : Date.parseDate(value.until, Date.patterns.ISO8601Long);
    this.range = Ext.ux.form.PeriodPicker.getRange(value);
    this.value = Ext.ux.form.PeriodPicker.getPeriod(value.from, this.range, this.periodIncludesUntil);
    this.startDate = this.value.from;
    this.getRangeCombo().setValue(this.range);
    var dateString;

    switch (this.range) {
      case 'day':
        dateString = Tine.Tinebase.common.dateRenderer(this.startDate);
        break;

      case 'week':
        // NOTE: '+1' is to ensure we display the ISO8601 based week where weeks always start on monday!
        var wkStart = this.startDate.add(Date.DAY, this.startDate.getDay() < 1 ? 1 : 0);
        dateString = wkStart.getWeekOfYear() + ' - ' + this.startDate.format('Y');
        break;

      case 'month':
        dateString = Date.getShortMonthName(this.startDate.getMonth()) + ' ' + this.startDate.format('Y');
        break;

      case 'quarter':
        dateString = Math.ceil(+this.startDate.format('n') / 3) + ' - ' + this.startDate.format('Y');
        break;

      case 'year':
        dateString = this.startDate.format('Y');
        break;
    }

    this.setPeriodText(dateString, new Date().between(this.value.from, this.value.until));

    if (JSON.stringify(this.value) != JSON.stringify(this.startValue)) {
      this.fireEvent('change', this, this.value, this.startValue);
    }

    this.startValue = this.value;
  },
  reset: function reset() {
    this.originalValue = this.startValue;
    Ext.ux.form.PeriodPicker.superclass.reset.apply(this, arguments);
  },
  setStartDate: function setStartDate(startDate) {
    var value = Ext.ux.form.PeriodPicker.getPeriod(startDate, this.range, this.periodIncludesUntil);
    this.setValue(value);
  },
  setPeriodText: function setPeriodText(text, isThis) {
    this.el[(isThis ? 'add' : 'remove') + 'Class']('ux-pp-this');
    this.el.child('.ux-pp-period').update(Ext.util.Format.htmlEncode(text));
  },
  // private
  onRangeComboChange: function onRangeComboChange() {
    this.setValue(Ext.ux.form.PeriodPicker.getPeriod(this.startDate, this.getRangeCombo().getValue()), this.periodIncludesUntil);
  },
  // private
  onClick: function onClick(e) {
    var mode = e.getTarget('.ux-pp-mode'),
        prev = e.getTarget('.ux-pp-prev'),
        next = e.getTarget('.ux-pp-next'),
        period = e.getTarget('.ux-pp-period');

    if (mode) {
      var newMode = this.mode != 'absolute' ? 'absolute' : 'relative';
      mode.removeClass('ux-pp-mode-' + this.mode);
      mode.addClass('ux-pp-mode-' + newMode);
      this.mode = newMode; // set period!
    } else if (next) {
      this.setStartDate(this.value.until.add(Date.SECOND, this.periodIncludesUntil ? 1 : 0));
    } else if (prev) {
      this.setStartDate(this.value.from.add(Date.DAY, -1));
    } else if (period) {
      this.getDatePickerMenu().show(period);
    }
  },
  // private
  onRender: function onRender(ct, position) {
    Ext.ux.form.PeriodPicker.superclass.onRender.call(this, ct, position);
    var rangeCombo = this.getRangeCombo();
    rangeCombo.render(this.el.child('.ux-pp-range'));
    this.onResize(this.getEl().getWidth(), this.getEl().getHeight());
    this.setValue(this.value);
    this.mon(this.getEl(), 'click', this.onClick, this);
  },
  // private
  getAutoCreate: function getAutoCreate() {
    this.autoCreate = {
      tag: 'div',
      cls: 'ux-pp-field',
      cn: [{
        tag: 'div',
        cls: 'ux-pp-range'
      }, {
        tag: 'div',
        cls: 'ux-pp-controls',
        cn: [
        /*{
        tag: 'div',
        cls: 'ux-pp-mode ux-pp-mode-' + this.mode
        },*/
        {
          tag: 'div',
          cls: 'ux-pp-prev'
        }, {
          tag: 'div',
          cls: 'ux-pp-period'
        }, {
          tag: 'div',
          cls: 'ux-pp-next'
        }]
      }]
    };
    return Ext.ux.form.PeriodPicker.superclass.getAutoCreate.apply(this, arguments);
  },
  // private
  onResize: function onResize(w, h) {
    Ext.ux.form.PeriodPicker.superclass.onResize.apply(this, arguments);
    var rw = Math.floor(this.getEl().getWidth() * 0.4),
        cw = Math.floor(this.getEl().getWidth() * 0.6);
    this.el.select('.ux-pp-range').setWidth(rw);
    this.getRangeCombo().wrap.setWidth(rw);
    this.getRangeCombo().setWidth(rw);
    this.el.select('.ux-pp-controls').setWidth(cw);
  },
  getRangeCombo: function getRangeCombo() {
    if (!this.rangeCombo) {
      var fieldDef = [];
      Ext.each(this.availableRanges.split(','), function (range) {
        fieldDef.push([range, i18n._hidden(Ext.util.Format.capitalize(range))]);
      });
      this.rangeCombo = new Ext.form.ComboBox({
        typeAhead: true,
        triggerAction: 'all',
        mode: 'local',
        forceSelection: true,
        allowBlank: false,
        editable: false,
        store: fieldDef,
        isInnerFTBCmp: true,
        // value: this.range,
        listeners: {
          scope: this,
          select: this.onRangeComboChange
        }
      });
    }

    return this.rangeCombo;
  },

  /**
   * returns a new datepickerMenu
   *
   * @returns {Ext.menu.DateMenu}
   */
  getDatePickerMenu: function getDatePickerMenu() {
    var me = this;
    return new Ext.menu.DateMenu({
      value: this.startDate,
      hideOnClick: true,
      focusOnSelect: true,
      plugins: [new Ext.ux.DatePickerWeekPlugin({
        weekHeaderString: Tine.Tinebase.appMgr.get('Calendar').i18n._hidden('WK'),
        inspectMonthPickerClick: function inspectMonthPickerClick(btn, e) {
          if (e.getTarget('button')) {
            if (me.availableRanges.match('month')) {
              me.getRangeCombo().setValue('month');
              me.range = 'month';
              me.setStartDate(this.activeDate);
              this.destroy();
            }

            return false;
          }
        }
      })],
      listeners: {
        scope: this,
        select: function select(picker, value, weekNumber) {
          var range = weekNumber ? 'week' : 'day';

          if (me.availableRanges.match(range)) {
            this.getRangeCombo().setValue(range);
            this.range = range;
            this.setStartDate(value);
          }
        }
      }
    });
  }
});
/**
 * gets period
 *
 * @static
 * @param {Date} startDate date within period
 * @param {String} range day|week|month|year
 * @param {Bool} includeUntil
 * @return {Object} {from: Date, until: Date}
 */

Ext.ux.form.PeriodPicker.getPeriod = function (startDate, range, includeUntil) {
  var from, until;

  switch (range) {
    case 'day':
      from = startDate.clearTime(true);
      until = from.add(Date.DAY, 1);
      break;

    case 'week':
      from = startDate.clearTime(true).add(Date.DAY, -1 * startDate.getDay());

      if (Ext.DatePicker.prototype.startDay) {
        from = from.add(Date.DAY, Ext.DatePicker.prototype.startDay - (startDate.getDay() == 0 ? 7 : 0));
      }

      until = from.add(Date.DAY, 7);
      break;

    case 'month':
      from = startDate.clearTime(true).getFirstDateOfMonth();
      until = from.getLastDateOfMonth().add(Date.DAY, 1);
      break;

    case 'quarter':
      from = startDate.clearTime(true).getFirstDateOfMonth().add(Date.MONTH, -1 * ((+startDate.format('n') - 1) % 3));
      until = from.add(Date.MONTH, 2).getLastDateOfMonth().add(Date.DAY, 1);
      break;

    case 'year':
      var year = startDate.format('Y');
      from = Date.parseDate(year + '-01-01 00:00:00', 'Y-m-d H:i:s');
      until = Date.parseDate(++year + '-01-01 00:00:00', 'Y-m-d H:i:s');
      break;
  }

  if (includeUntil) {
    until = until.add(Date.SECOND, -1);
  }

  return {
    from: from,
    until: until
  };
};
/**
 * gets period
 *
 * @static
 * @param {Object} {from: Date, until: Date}
 * @return {String} range day|week|month|year
 */


Ext.ux.form.PeriodPicker.getRange = function (period) {
  var from = Ext.isDate(period.from) ? period.from : new Date(period.from),
      until = Ext.isDate(period.until) ? period.until : new Date(period.until),
      ms = from.getElapsed(until),
      msDay = 86400000;

  if (ms > msDay * 300) {
    return 'year';
  } else if (ms > msDay * 80) {
    return 'quarter';
  } else if (ms > msDay * 20) {
    return 'month';
  } else if (ms > msDay * 5) {
    return 'week';
  } else {
    return 'day';
  }
};

Ext.reg('ux-period-picker', Ext.ux.form.PeriodPicker);

/***/ }),
/* 1231 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.MoneyField
 * @extends     Ext.form.MoneyField
 */

Ext.ux.form.MoneyField = Ext.extend(Ext.ux.form.NumberField, {
  style: 'text-align: right',
  initComponent: function initComponent() {
    this.suffix = ' ' + Tine.Tinebase.registry.get('currencySymbol');
    this.decimalPrecision = 2;
    this.decimalSeparator = Tine.Tinebase.registry.get('decimalSeparator');
    this.supr().initComponent.apply(this, arguments);
  }
});
Ext.reg('extuxmoneyfield', Ext.ux.form.MoneyField);

/***/ }),
/* 1232 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.BytesField
 * @extends     Ext.form.NumberField
 */

Ext.ux.form.BytesField = Ext.extend(Ext.form.NumberField, {
  /**
   * @cfg {String} basePow
   * change this if the value is measured other than in bytes
   */
  basePow: 0,

  /**
   * @cfg {Number} divisor
   */
  divisor: 1024,

  /**
   * @cfg {String} forceUnit
   */
  forceUnit: false,
  suffixes: ['bytes', 'kb', 'mb', 'gb', 'tb', 'pb', 'eb', 'zb', 'yb'],
  decimalPrecision: 2,
  minValue: 0,
  baseChars: "0123456789bBkKmMgGtTpPeEzZyY ",
  initComponent: function initComponent() {
    this.decimalSeparator = Tine.Tinebase.registry.get('decimalSeparator');
    this.validateRe = new RegExp('([0-9' + this.decimalSeparator + ']+)\\s*([a-zA-Z]+)');
    this.supr().initComponent.apply(this, arguments);
  },
  validateValue: function validateValue(value) {
    var _ = window.lodash,
        me = this,
        parts = String(value).match(this.validateRe),
        number = parts ? parts[1] : value,
        suffix = parts ? parts[2] : this.suffixes[this.basePow],
        pow = suffix ? this.suffixes.indexOf(suffix.toLowerCase()) : 0;

    if (!this.supr().validateValue.call(this, number)) {
      return false;
    }

    if (!_.reduce(me.suffixes, function (r, s) {
      return r || String(s).match(new RegExp('^' + suffix, 'i'));
    }, false)) {
      this.markInvalid(String.format(i18n._('{0} is not a valid unit'), suffix));
      return false;
    }

    return true;
  },
  parseValue: function parseValue(value) {
    var parts = String(value).match(this.validateRe),
        number = parts ? parts[1] : value,
        suffix = parts ? parts[2] : this.suffixes[this.basePow],
        pow = suffix ? this.suffixes.indexOf(suffix.toLowerCase()) : 0;
    value = this.supr().parseValue.call(this, number);
    value = value * Math.pow(this.divisor, pow);
    value = value / Math.pow(this.divisor, this.basePow); // NOTE: decimals might come from bytes

    value = Math.round(value);
    return value;
  },
  setValue: function setValue(value) {
    this.supr().setValue.call(this, value);
    value = value ? Tine.Tinebase.common.byteFormatter(value * Math.pow(this.divisor, this.basePow), this.forceUnit, this.decimalPrecision, false) : this.emptyText;
    this.setRawValue(value);
    return this;
  }
});
Ext.reg('extuxbytesfield', Ext.ux.form.BytesField);

/***/ }),
/* 1233 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.form.');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.LayerCombo
 * @extends     Ext.form.TriggerField
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * trigger field with support for extra layer on trigger click
 */

Ext.ux.form.LayerCombo = function (config) {
  Ext.ux.form.LayerCombo.superclass.constructor.call(this, config);
  this.addEvents(
  /**
   * @event beforecollapse
   * Fires before the layer is collapsed by calling the {@link #collapse} method.
   * Return false from an event handler to stop the collapse.
   * @param {LayerCombo} this
   */
  'beforecollapse',
  /**
   * @event beforeexpand
   * Fires before the layer is expanded by calling the {@link #expand} method.
   * Return false from an event handler to stop the expand.
   * @param {LayerCombo} this
   */
  'beforeexpand');
};

Ext.extend(Ext.ux.form.LayerCombo, Ext.form.TriggerField, {
  /**
   * @cfg {Boolean} hideButton Hide standard form buttons 
   */
  hideButtons: false,

  /**
   * @cfg {Object} config for innerForm
   */
  formConfig: null,

  /**
   * @cfg {Boolean} lazyInit <tt>true</tt> to not initialize the list for this combo until the field is focused
   * (defaults to <tt>true</tt>)
   */
  lazyInit: true,

  /**
   * @cfg {String} triggerClass An additional CSS class used to style the trigger button.  The trigger will always
   * get the class <tt>'x-form-trigger'</tt> and <tt>triggerClass</tt> will be <b>appended</b> if specified
   * (defaults to <tt>'x-form-arrow-trigger'</tt> which displays a downward arrow icon).
   */
  triggerClass: 'x-form-arrow-trigger',

  /**
   * @cfg {Boolean/String} shadow <tt>true</tt> or <tt>"sides"</tt> for the default effect, <tt>"frame"</tt> for
   * 4-way shadow, and <tt>"drop"</tt> for bottom-right
   */
  shadow: 'sides',

  /**
   * @cfg {String/Array} layerAlign A valid anchor position value. See <tt>{@link Ext.Element#alignTo}</tt> for details
   * on supported anchor positions and offsets. To specify x/y offsets as well, this value
   * may be specified as an Array of <tt>{@link Ext.Element#alignTo}</tt> method arguments.</p>
   * <pre><code>[ 'tl-bl?', [6,0] ]</code></pre>(defaults to <tt>'tr-br?'</tt>)
   */
  layerAlign: 'tl-bl?',

  /**
   * @cfg {String} layerClass The CSS class to add to the predefined <tt>'x-combo-layer'</tt> class
   * applied the dropdown layer element (defaults to '').
   */
  layerClass: '',

  /**
   * @cfg {Number} minLayerWidth The minimum width of the dropdown layer in pixels (defaults to <tt>70</tt>, will
   * be ignored if <tt>{@link #layerWidth}</tt> has a higher value)
   */
  minLayerWidth: 70,

  /**
   * @cfg {Number} layerWidth The width (used as a parameter to {@link Ext.Element#setWidth}) of the dropdown
   * layer (defaults to the width of the ComboBox field).  See also <tt>{@link #minLayerWidth}</tt>
   */

  /**
   * @cfg {Number} minLayerHeight The minimum height of the dropdown layer in pixels (defaults to <tt>70</tt>, will
   * be ignored if <tt>{@link #layerHeight}</tt> has a higher value)
   */
  minLayerHeight: 70,

  /**
   * @cfg {Number} layerHeight The width (used as a parameter to {@link Ext.Element#setHeight}) of the dropdown
   * layer (defaults to the width of the ComboBox field).  See also <tt>{@link #minLayerHeight}</tt>
   */

  /**
   * @property currentValue
   * @type mixed
   */
  currentValue: null,
  editable: false,

  /**
   * Hides the dropdown layer if it is currently expanded. Fires the {@link #collapse} event on completion.
   */
  collapse: function collapse() {
    if (!this.isExpanded()) {
      return;
    }

    if (this.fireEvent('beforecollapse', this) !== false) {
      this.layer.hide();
      Ext.getDoc().un('mousewheel', this.collapseIf, this);
      Ext.getDoc().un('mousedown', this.collapseIf, this);
      this.fireEvent('collapse', this);
    }
  },

  /**
   * @private
   * @param {Ext.EventObject} e
   */
  collapseIf: function collapseIf(e) {
    if (Ext.WindowMgr.getActive() == this.layer && !e.within(this.wrap) && !e.within(this.layer)) {
      this.collapse();

      if (this.inEditor && this.editor) {
        this.onCancel();
      }
    }
  },

  /**
   * this fn is here so this filed is detected like a combo
   * @private
   */
  doQuery: Ext.emptyFn,

  /**
   * Expands the dropdown layer if it is currently hidden. Fires the {@link #expand} event on completion.
   */
  expand: function expand() {
    if (this.isExpanded() || !this.hasFocus || this.fireEvent('beforeexpand', this) === false) {
      return;
    }

    this.setFormValue(this.currentValue);
    this.layer.alignTo.apply(this.layer, [this.el].concat(this.layerAlign));
    this.layer.show();

    if (Ext.isGecko2) {
      this.innerLayer.setOverflow('auto'); // necessary for FF 2.0/Mac
    }

    this.mon(Ext.getDoc(), {
      scope: this,
      mousewheel: this.collapseIf,
      mousedown: this.collapseIf
    });
    this.fireEvent('expand', this);
  },

  /**
   * get values from form
   * 
   * @return {mixed}
   */
  getFormValue: function getFormValue() {
    var formValues = this.getInnerForm().getForm().getFieldValues();
    return formValues;
  },

  /**
   * template fn for subclasses to return inner form items
   */
  getItems: function getItems() {
    return [];
  },

  /**
   * <p>Returns the element used to house this ComboBox's pop-up layer. Defaults to the document body.</p>
   * A custom implementation may be provided as a configuration option if the floating layer needs to be rendered
   * to a different Element. An example might be rendering the layer inside a Menu so that clicking
   * the layer does not hide the Menu
   */
  getLayerParent: function getLayerParent() {
    return document.body;
  },

  /**
   * get buttons
   * 
   * @private
   */
  getButtons: function getButtons() {
    if (!this.hideButtons) {
      this.action_ok = new Ext.Action({
        text: i18n._('Ok'),
        scope: this,
        handler: this.onOk,
        iconCls: 'action_saveAndClose'
      });
      this.action_cancel = new Ext.Action({
        text: i18n._('Cancel'),
        scope: this,
        handler: this.onCancel,
        iconCls: 'action_cancel'
      });
      return [this.action_cancel, this.action_ok];
    }

    return false;
  },

  /**
   * returns inner form of the layer
   * 
   */
  getInnerForm: function getInnerForm() {
    if (!this.innerForm) {
      this.innerForm = new Ext.form.FormPanel(Ext.apply({
        //labelWidth: 30,
        height: this.layerHeight || 'auto',
        border: false,
        cls: 'tw-editdialog',
        items: this.getItems(),
        buttonAlign: 'right',
        buttons: this.getButtons()
      }, this.formConfig));
    }

    return this.innerForm;
  },

  /**
   * Returns the currently selected field value or empty string if no value is set.
   * @return {String} value The selected value
   */
  getValue: function getValue() {
    return Ext.decode(Ext.encode(this.currentValue));
  },
  initComponent: function initComponent() {
    Ext.ux.form.LayerCombo.superclass.initComponent.apply(this, arguments);
    this.on('afterrender', this.onAfterRender, this, {
      buffer: 500
    });
    this.on('beforedestroy', this.onBeforeDestory, this);
  },
  onAfterRender: function onAfterRender() {
    // if used as gridEditor
    if (this.inEditor) {
      var editorWrapEl = this.el.up('.x-grid-editor', 5);

      if (editorWrapEl) {
        this.editor = Ext.getCmp(editorWrapEl.id);
        this.editor.allowBlur = true;
        this.expand();
      }
    }
  },
  onBeforeDestory: function onBeforeDestory() {
    if (this.layer) {
      Ext.WindowMgr.unregister(this.layer);
    }
  },

  /**
   * init the dropdown layer
   * 
   * @private
   */
  initLayer: function initLayer() {
    if (!this.layer) {
      var cls = 'ux-layercombo-layer',
          layerParent = Ext.getDom(this.getLayerParent() || Ext.getBody());
      this.layer = new Ext.Layer({
        parentEl: layerParent,
        shadow: this.shadow,
        cls: [cls, this.layerClass].join(' '),
        constrain: false
      }); // manage z-index by windowMgr

      this.layer.setActive = Ext.emptyFn;
      Ext.WindowMgr.register(this.layer);
      Ext.WindowMgr.bringToFront(this.layer);
      var lw = this.layerWidth || Math.max(this.wrap.getWidth(), this.minLayerWidth);
      this.layer.setSize(lw, 0);
      this.assetHeight = 0;

      if (this.syncFont !== false) {
        this.layer.setStyle('font-size', this.el.getStyle('font-size'));
      }

      if (this.title) {
        this.header = this.layer.createChild({
          cls: cls + '-hd',
          html: this.title
        });
        this.assetHeight += this.header.getHeight();
      }

      this.innerLayer = this.layer.createChild({
        cls: cls + '-inner'
      }); //this.mon(this.innerLayer, 'mouseover', this.onViewOver, this);
      //this.mon(this.innerLayer, 'mousemove', this.onViewMove, this);

      this.innerLayer.setWidth(lw - this.layer.getFrameWidth('lr'));
      var innerForm = this.getInnerForm();
      innerForm.render(this.innerLayer);
      this.setLayerHeight(this.layerHeight ? this.layerHeight : 'auto');
    }
  },

  /**
   * Returns true if the dropdown layer is expanded, else false.
   */
  isExpanded: function isExpanded() {
    return this.layer && this.layer.isVisible();
  },

  /**
   * cancel handler
   */
  onCancel: function onCancel() {
    this.setValue(this.currentValue);
    this.collapse();

    if (this.inEditor && this.editor) {
      this.editor.cancelEdit();
    }
  },

  /**
   * do cleanup
   * 
   * @private
   */
  onDestroy: function onDestroy() {
    if (this.dqTask) {
      this.dqTask.cancel();
      this.dqTask = null;
    }

    Ext.destroy(this.resizer, this.layer);
    Ext.destroyMembers(this, 'hiddenField');
    Ext.form.ComboBox.superclass.onDestroy.call(this);
  },

  /**
   * ok handler
   */
  onOk: function onOk() {
    this.collapse();
    var v = this.getFormValue();
    this.setValue(v);
    this.fireEvent('select', this, v); //this.startValue = v;

    if (this.inEditor && this.editor) {
      this.editor.completeEdit();
    }
  },

  /**
   * executed onRender
   * 
   * @private
   * 
   * @param {Ext.Container} ct
   * @param {Number} position
   */
  onRender: function onRender(ct, position) {
    if (this.hiddenName && !Ext.isDefined(this.submitValue)) {
      this.submitValue = false;
    }

    Ext.ux.form.LayerCombo.superclass.onRender.apply(this, arguments);

    if (this.hiddenName) {
      this.hiddenField = this.el.insertSibling({
        tag: 'input',
        type: 'hidden',
        name: this.hiddenName,
        id: this.hiddenId || this.hiddenName
      }, 'before', true);
    }

    if (Ext.isGecko) {
      this.el.dom.setAttribute('autocomplete', 'off');
    }

    if (!this.lazyInit) {
      this.initLayer();
    } else {
      this.on('focus', this.initLayer, this, {
        single: true
      });
    }
  },

  /**
   * Implements the default empty TriggerField.onTriggerClick function
   * 
   * @private
   */
  onTriggerClick: function onTriggerClick() {
    if (this.readOnly || this.disabled) {
      return;
    }

    if (this.isExpanded()) {
      this.collapse();
      this.el.focus();

      if (this.inEditor && this.editor) {
        this.onCancel();
      }
    } else {
      this.onFocus({});
      this.expand();
    }
  },

  /**
   * set layer height
   * 
   * @param {Number} height
   */
  setLayerHeight: function setLayerHeight(height) {
    if (!Ext.isNumber(height)) {
      height = this.innerForm.getHeight();
    }

    this.innerLayer.dom.style.height = '';
    var pad = this.layer.getFrameWidth('tb') + (this.resizable ? this.handleHeight : 0) + this.assetHeight;
    this.innerLayer.setHeight(height);
    this.layer.beginUpdate();
    this.layer.setHeight(height + pad);
    this.layer.alignTo.apply(this.layer, [this.el].concat(this.layerAlign));
    this.layer.endUpdate();
  },

  /**
   * Sets the specified value into the field.  If the value finds a match, the corresponding record text
   * will be displayed in the field.  If the value does not match the data value of an existing item,
   * and the valueNotFoundText config option is defined, it will be displayed as the default field text.
   * Otherwise the field will be blank (although the value will still be set).
   * 
   * @param {String} value The value to match
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    var oldValue = this.currentValue;
    this.currentValue = value;
    Tine.Tinebase.common.assertComparable(this.currentValue);

    if (JSON.stringify(value) != JSON.stringify(oldValue)) {
      this.fireEvent('change', this, value, oldValue);
    }

    return this;
  },

  /**
   * sets values to innerForm
   */
  setFormValue: function setFormValue(value) {
    this.getInnerForm().getForm().setValues(value);
  }
});
Ext.reg('ux.layercombo', Ext.ux.form.LayerCombo);

/***/ }),
/* 1234 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * A ComboBox with a secondary trigger button that clears the contents of the ComboBox
 * 
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ClearableComboBox
 * @extends     Ext.form.ComboBox
 */

Ext.ux.form.ClearableComboBox = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {bool} disableClearer
   * disables the clearer
   */
  disableClearer: null,
  initComponent: function initComponent() {
    Ext.ux.form.ClearableComboBox.superclass.initComponent.call(this);
    this.triggerConfig = {
      tag: 'span',
      cls: 'x-form-twin-triggers',
      style: 'padding-right:2px',
      // padding needed to prevent IE from clipping 2nd trigger button
      cn: [{
        tag: "img",
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger x-form-clear-trigger"
      }, {
        tag: "img",
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger " + this.triggerClass
      }]
    };
  },
  getTrigger: function getTrigger(index) {
    return this.triggers[index];
  },
  initTrigger: function initTrigger() {
    var ts = this.trigger.select('.x-form-trigger', true);
    this.wrap.setStyle('overflow', 'hidden');
    var triggerField = this;
    ts.each(function (t, all, index) {
      t.hide = function () {
        var _triggerField$el;

        this.dom.style.display = 'none';
        (_triggerField$el = triggerField.el) === null || _triggerField$el === void 0 ? void 0 : _triggerField$el.setWidth(triggerField.wrap.getWidth() - 21);
      };

      t.show = function () {
        this.dom.style.display = '';
        triggerField.el.setWidth(triggerField.wrap.getWidth() - 38);
      };

      var triggerIndex = 'Trigger' + (index + 1);

      if (this['hide' + triggerIndex]) {
        t.dom.style.display = 'none';
      }

      t.on("click", this['on' + triggerIndex + 'Click'], this, {
        preventDefault: true
      });
      t.addClassOnOver('x-form-trigger-over');
      t.addClassOnClick('x-form-trigger-click');
    }, this);
    this.triggers = ts.elements;
    this.triggers[0].hide();
  },
  onRender: function onRender(ct, position) {
    Ext.ux.form.ClearableComboBox.superclass.onRender.apply(this, arguments);
    this.wrap.addClass('x-form-field-twin-trigger-wrap');
  },
  // clear contents of combobox
  onTrigger1Click: function onTrigger1Click() {
    if (this.disabled) {
      return;
    }

    this.clearValue();
  },
  // pass to original combobox trigger handler
  onTrigger2Click: function onTrigger2Click() {
    this.onTriggerClick();
  },

  /**
   * reset
   */
  reset: function reset() {
    Ext.ux.form.ClearableComboBox.superclass.reset.apply(this, arguments);

    if (this.triggers && this.disableClearer !== true) {
      this.triggers[0].hide();
    }
  },

  /**
   * clear value
   */
  clearValue: function clearValue() {
    Ext.ux.form.ClearableComboBox.superclass.clearValue.apply(this, arguments);
    this.fireEvent('select', this, '', this.startValue);
    this.startValue = this.getRawValue();

    if (this.triggers && this.disableClearer !== true) {
      this.triggers[0].hide();
    }
  },
  // show clear trigger when item got selected
  onSelect: function onSelect(combo, record, index) {
    if (this.triggers && this.disableClearer !== true) {
      this.triggers[0].show();
    }

    Ext.ux.form.ClearableComboBox.superclass.onSelect.call(this, combo, record, index);
    this.startValue = this.getValue();
  },

  /**
   * @see Ext.form.ComboBox
   */
  setValue: function setValue(value) {
    Ext.ux.form.ClearableComboBox.superclass.setValue.call(this, value);

    if (value && this.triggers && this.disableClearer !== true && !this.readOnly) {
      this.triggers[0].show();
    }
  },

  /**
   * @see Ext.form.ComboBox
   */
  assertValue: function assertValue() {
    var val = this.getRawValue(),
        rec;

    if (this.valueField && Ext.isDefined(this.value)) {
      rec = this.findRecord(this.valueField, this.value);
    }

    if (!rec || rec.get(this.displayField) != val) {
      rec = this.findRecord(this.displayField, val);
    }

    if (!rec && this.forceSelection) {
      if (val.length > 0 && val != this.emptyText) {
        this.el.dom.value = Ext.value(this.lastSelectionText, '');
        this.applyEmptyText();
      } else {
        this.clearValue();
      }
    } else {
      if (rec && this.valueField) {
        // onSelect may have already set the value and by doing so
        // set the display field properly.  Let's not wipe out the
        // valueField here by just sending the displayField.
        if (this.value == val) {
          return;
        }

        val = rec.get(this.valueField || this.displayField);
      }

      this.selectedRecord = rec; // @see 0007622: losing non-contact recipient

      this.setRawValue(rec ? rec.get(this.displayField) : val);
    }
  }
});
Ext.reg('extuxclearablecombofield', Ext.ux.form.ClearableComboBox);

/***/ }),
/* 1235 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ClearableTextField
 * @extends     Ext.form.TriggerField
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * Textfield with clearing trigger
 */

Ext.ux.form.ClearableTextField = Ext.extend(Ext.form.TriggerField, {
  /**
   * @cfg {Boolean} disableTrigger
   */
  disableTrigger: false,
  enableKeyEvents: true,
  triggerClass: 'x-form-clear-trigger',
  checkTrigger: function checkTrigger() {
    this.setHideTrigger(!(this.getValue() && !this.disableTrigger));
  },
  initComponent: function initComponent() {
    this.supr().initComponent.call(this);
    this.on('keyup', this.checkTrigger, this);
  },
  afterRender: function afterRender() {
    this.supr().afterRender.call(this);
    this.checkTrigger();
  },
  onTriggerClick: function onTriggerClick() {
    var value = this.getValue();
    this.setValue('');

    if (value) {
      this.fireEvent('change', this, '', value);
    }

    this.checkTrigger();
    this.el.focus();
  },
  onDestroy: function onDestroy() {
    this.un('keyup', this.checkTrigger);
  },
  setValue: function setValue(value) {
    var ret = this.supr().setValue.call(this, value);
    this.checkTrigger();
    return ret;
  }
});
Ext.reg('extuxclearabletextfield', Ext.ux.form.ClearableTextField);

/***/ }),
/* 1236 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.form');
/**
 * A ComboBox with a (Ext.data.JsonStore) store that loads its data from a record in this format:
 * {
 *  value:1,
 *  records:[{
 *          totalcount: 2,
 *          results: {id: 0, name: 'name 1'}, {id: 1,name: 'name 2'}
 *      }]
 * }
 * 
 * use it like this:
 * {
 *   xtype:'reccombo',
 *   name: 'software_id',
 *   fieldLabel: this.app.i18n._('Software Version'),
 *   displayField: 'name',
 *   store: new Ext.data.Store({
 *      fields: Tine.Voipmanager.Model.SnomSoftware,
 *      proxy: Tine.Voipmanager.SnomSoftwareBackend,
 *      reader: Tine.Voipmanager.SnomSoftwareBackend.getReader(),
 *      remoteSort: true,
 *      sortInfo: {field: 'name', dir: 'ASC'}
 *   })
 * }
 *
 * @namespace   Ext.ux.form 
 * @class       Ext.ux.form.RecordsComboBox
 * @extends     Ext.form.ComboBox
 */

Ext.ux.form.RecordsComboBox = Ext.extend(Ext.form.ComboBox, {
  /**
   * default config
   */
  triggerAction: 'all',
  editable: false,
  forceSelection: true,
  valueField: 'id',

  /**
   * overwrite setValue() to get records
   * 
   * @param value
   */
  setValue: function setValue(value) {
    var val = value; // check if object and load options from record

    if (typeof value === 'object' && Object.prototype.toString.call(value) === '[object Object]') {
      if (value['records'] !== undefined) {
        this.mode = 'local';
        this.store.loadData(value['records']);
      }

      val = value['value'];
    }

    Ext.ux.form.RecordsComboBox.superclass.setValue.call(this, val);
  }
}); // register xtype

Ext.reg('reccombo', Ext.ux.form.RecordsComboBox);

/***/ }),
/* 1237 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext*/
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * A combination of datefield and timefield
 * 
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.DateTimeField
 * @extends     Ext.form.Field
 */

Ext.ux.form.DateTimeField = Ext.extend(Ext.form.Field, {
  autoEl: 'div',
  value: '',
  disabledClass: '',
  increment: 15,
  timeEditable: true,
  markedInvalid: false,
  minWidth: 160,
  allowBlank: true,

  /**
   * @cfg {Object} config to be applied to date field 
   */
  dateConf: null,

  /**
   * @cfg {Object} config to be applied to time field 
   */
  timeConf: null,

  /*
   * @cfg {String} Default Time in the form HH:MM, if null current time is used
   */
  defaultTime: null,
  initComponent: function initComponent() {
    Ext.ux.form.DateTimeField.superclass.initComponent.call(this);
    this.lastValues = [];
    this.on('change', this.onChange, this);
  },

  /**
   * Sets the default time when using the first time or after clearing the datefield
   * @param {Ext.form.Field}
   * @param {DateTime} newValue
   * @param {DateTime} oldValue
   */
  onChange: function onChange(f, newValue, oldValue) {
    if (oldValue == '' && newValue) {
      var newDate = newValue.clone(),
          now = new Date(),
          times = this.defaultTime ? this.defaultTime.split(':') : [now.getHours(), now.getMinutes()];
      newDate.setHours(parseInt(times[0]));
      newDate.setMinutes(parseInt(times[1]));
      f.setValue(newDate);
    }
  },
  clearInvalid: function clearInvalid() {
    this.markedInvalid = false;

    if (this.dateField) {
      this.dateField.clearInvalid();
    }

    if (this.timeField) {
      this.timeField.clearInvalid();
    }
  },
  clearTime: function clearTime() {
    var dateTime = this.getValue();

    if (Ext.isDate(dateTime)) {
      this.setValue(this.getValue().clearTime(true));
    } else {
      this.timeField.setValue(new Date().clearTime());
    }
  },
  combineDateTime: function combineDateTime(date, time) {
    date = Ext.isDate(date) ? date : new Date.clearTime();

    if (Ext.isDate(time)) {
      date = date.clone();
      date.clearTime();
      date = date.add(Date.HOUR, time.getHours());
      date = date.add(Date.MINUTE, time.getMinutes());
    }

    return date;
  },
  getName: function getName() {
    return this.name;
  },
  getValue: function getValue() {
    if (!this.dateField) {
      return this.value;
    }

    var date = this.dateField.getValue();
    var time = this.timeField.getValue(); // this is odd, why doesn't Ext.form.TimeField a Date datatype?

    if (!Ext.isDate(time)) {
      time = Date.parseDate(time, 'H:i');
    }

    if (Ext.isDate(date)) {
      date = this.combineDateTime(date, time);
    }

    return date;
  },
  getRawValue: function getRawValue() {
    if (!this.dateField) {
      return this.value;
    }

    var date = this.dateField.getRawValue();
    var time = this.timeField.getRawValue();
    return date + ' ' + time;
  },
  validateValue: function validateValue(value) {
    if (!Ext.form.DateField.superclass.validateValue.call(this, value)) {
      return false;
    }

    return true;
  },
  markInvalid: function markInvalid(msg) {
    this.markedInvalid = true;
    this.dateField.markInvalid(msg);
    this.timeField.markInvalid(msg);
  },
  addClass: function addClass(cls) {
    this.dateField.addClass(cls);
    this.timeField.addClass(cls);
  },
  removeClass: function removeClass(cls) {
    this.dateField.removeClass(cls);
    this.timeField.removeClass(cls);
  },
  onRender: function onRender(ct, position) {
    var me = this,
        dateField = this.allowBlank ? Ext.ux.form.ClearableDateField : Ext.form.DateField;
    this.width = this.width || this.minWidth; //Ext.ux.form.DateTimeField.superclass.onRender.call(this, ct, position);

    this.el = document.createElement(this.autoEl);
    this.el.id = this.getId();
    this.el = Ext.get(this.el);
    ct.dom.insertBefore(this.el.dom, position);
    this.el.applyStyles('overflow:visible;');
    this.el.blur = this.el.blur.createSequence(function () {
      me.dateField.el.blur();
      me.timeField.el.blur();
    });
    this.dateField = new dateField(Ext.apply({
      lazyRender: false,
      renderTo: this.el,
      readOnly: this.readOnly || this.dateFieldReadOnly,
      hideTrigger: this.hideTrigger,
      disabled: this.disabled || this.dateFieldDisabled,
      tabIndex: this.tabIndex === -1 ? this.tabIndex : false,
      allowBlank: this.allowBlank,
      value: this.value,
      listeners: {
        scope: this,
        change: this.onDateChange,
        select: this.onDateChange,
        focus: this.onDateFocus,
        blur: this.onDateBlur
      }
    }, this.dateConf || {}));
    this.timeField = new Ext.form.TimeField(Ext.apply({
      noFix: true,
      lazyRender: false,
      increment: this.increment,
      renderTo: this.el,
      readOnly: this.readOnly || this.timeFieldReadOnly,
      hideTrigger: this.hideTrigger,
      disabled: this.disabled || this.timeFieldDisabled,
      editable: this.timeEditable,
      tabIndex: this.tabIndex === -1 ? this.tabIndex : false,
      allowBlank: this.allowBlank,
      value: this.value,
      listeners: {
        scope: this,
        change: this.onTimeChange,
        select: this.onTimeChange,
        focus: this.onTimeFocus,
        blur: this.onTimeBlur
      }
    }, this.timeConf || {}));
  },
  triggerBlur: function triggerBlur() {
    if (this.dateField.hasFocus) {
      this.dateField.triggerBlur();
    } else if (this.timeField.hasFocus) {
      this.timeField.triggerBlur();
    }
  },
  onDateFocus: function onDateFocus() {
    if (!this.timeField.hasFocus) {
      this.hasFocus = true;
      this.fireEvent('focus', this);
    }
  },
  onDateBlur: function onDateBlur() {
    if (!this.timeField.hasFocus) {
      this.hasFocus = false;
      this.fireEvent('blur', this);
    }
  },
  onTimeFocus: function onTimeFocus() {
    if (!this.dateField.hasFocus) {
      this.hasFocus = true;
      this.fireEvent('focus', this);
    }
  },
  onTimeBlur: function onTimeBlur() {
    if (!this.dateField.hasFocus) {
      this.hasFocus = false;
      this.fireEvent('blur', this);
    }
  },
  onDateChange: function onDateChange() {
    var newValue = this.getValue();
    this.setValue(newValue);
    this.fireEvent('change', this, newValue, this.lastValues.length > 1 ? this.lastValues[this.lastValues.length - 2] : '');
  },
  onResize: function onResize(w, h) {
    Ext.ux.form.DateTimeField.superclass.onResize.apply(this, arguments);

    if (this.allowBlank) {
      var korrel = [0.65, 0.35];
    } else {
      var korrel = [0.55, 0.45];
    } // needed for readonly


    this.el.setHeight(20);
    this.el.setStyle({
      'position': 'relative'
    });
    this.dateField.wrap.setStyle({
      'position': 'absolute'
    });
    var dateFieldWidth = Math.abs(w * korrel[0] - 5);
    this.dateField.setWidth(dateFieldWidth);
    this.dateField.wrap.setWidth(dateFieldWidth);
    this.timeField.wrap.setStyle({
      'position': 'absolute'
    });
    var timeFieldWidth = Math.abs(w * korrel[1]);
    this.timeField.setWidth(timeFieldWidth);
    this.timeField.wrap.setWidth(timeFieldWidth);
    this.timeField.wrap.setLeft(dateFieldWidth + 5);
  },
  onTimeChange: function onTimeChange() {
    var newValue = this.getValue();
    this.setValue(newValue);
    this.fireEvent('change', this, newValue, this.lastValues.length > 1 ? this.lastValues[this.lastValues.length - 2] : '');
  },
  setDisabled: function setDisabled(bool, what) {
    if (what && what !== 'time') {
      if (this.dateField) {
        this.dateField.setDisabled(bool);
      } else {
        this.dateFieldDisabled = true;
      }
    }

    if (what && what !== 'date') {
      if (this.timeField) {
        this.timeField.setDisabled(bool);
      } else {
        this.timeFieldDisabled = true;
      }
    }

    Ext.ux.form.DateTimeField.superclass.setDisabled.call(this, bool);
  },
  setReadOnly: function setReadOnly(bool, what) {
    if (what !== 'time') {
      if (this.dateField) {
        this.dateField.setReadOnly(bool);
      } else {
        this.dateFieldReadOnly = true;
      }
    }

    if (what !== 'date') {
      if (this.timeField) {
        this.timeField.setReadOnly(bool);
      } else {
        this.timeFieldReadOnly = true;
      }
    }

    Ext.ux.form.DateTimeField.superclass.setReadOnly.call(this, bool);
  },
  setRawValue: Ext.EmptyFn,
  setValue: function setValue(value, record, skipHistory) {
    // NOTE: skipHistory was second param. don't know if this is used somehwere
    skipHistory = !_.isSet(skipHistory) && _.isBoolean(record) ? record : skipHistory;

    if (!skipHistory) {
      this.lastValues.push(value);
    }

    if (this.dateField && this.timeField) {
      this.dateField.setValue(value);
      this.timeField.setValue(Ext.isDate(value) ? value.clone() : value);
    }

    this.value = value;
  },
  undo: function undo() {
    if (this.lastValues.length > 1) {
      this.lastValues.pop();
      this.setValue(this.lastValues[this.lastValues.length - 1], true);
    } else {
      this.reset();
    }
  },
  isValid: function isValid(preventMark) {
    return this.dateField.isValid(preventMark) && this.timeField.isValid(preventMark) && !this.markedInvalid;
  }
});
Ext.reg('datetimefield', Ext.ux.form.DateTimeField);

/***/ }),
/* 1238 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext*/
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * a yes/no combo box
 *
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.BooleanCombo
 * @extends     Ext.form.ComboBox
 */

Ext.ux.form.BooleanCombo = Ext.extend(Ext.form.ComboBox, {
  mode: 'local',
  forceSelection: true,
  allowBlank: false,
  triggerAction: 'all',
  editable: false,
  initComponent: function initComponent() {
    this.store = [[true, i18n._('Yes')], [false, i18n._('No')]];
    this.supr().initComponent.call(this);
  }
});
Ext.reg('booleancombo', Ext.ux.form.BooleanCombo);

/***/ }),
/* 1239 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * A DateField with a secondary trigger button that clears the contents of the DateField
 *
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ClearableDateField
 * @extends     Ext.form.DateField
 */

Ext.ux.form.ClearableDateField = Ext.extend(Ext.form.DateField, {
  initComponent: function initComponent() {
    Ext.ux.form.ClearableDateField.superclass.initComponent.call(this);
    this.triggerConfig = {
      tag: 'span',
      cls: 'x-form-twin-triggers',
      cn: [{
        tag: "img",
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger x-form-clear-trigger"
      }, {
        tag: "img",
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger x-form-date-trigger"
      }]
    };
  },
  getTrigger: function getTrigger(index) {
    return this.triggers[index];
  },
  initTrigger: function initTrigger() {
    var ts = this.trigger.select('.x-form-trigger', true);
    this.wrap.setStyle('overflow', 'hidden');
    var triggerField = this;
    ts.each(function (t, all, index) {
      t.hide = function () {
        var w = triggerField.wrap.getWidth();
        this.dom.style.display = 'none';
        triggerField.el.setWidth(w - triggerField.trigger.getWidth());
      };

      t.show = function () {
        var w = triggerField.wrap.getWidth();
        this.dom.style.display = '';
        triggerField.el.setWidth(w - triggerField.trigger.getWidth());
      };

      var triggerIndex = 'Trigger' + (index + 1);

      if (this['hide' + triggerIndex]) {
        t.dom.style.display = 'none';
      }

      t.on("click", this['on' + triggerIndex + 'Click'], this, {
        preventDefault: true
      });
      t.addClassOnOver('x-form-trigger-over');
      t.addClassOnClick('x-form-trigger-click');
    }, this);
    this.triggers = ts.elements;
    this.triggers[0].hide();
  },
  validateValue: function validateValue(value) {
    if (value !== this.emptyText && value !== undefined && value.length > '1') {
      if (Ext.isArray(this.triggers) && this.triggers[0] && typeof this.triggers[0].show == 'function') {
        this.triggers[0].show();
      }
    }

    return Ext.ux.form.ClearableDateField.superclass.validateValue.apply(this, arguments);
  },
  // clear contents of combobox
  onTrigger1Click: function onTrigger1Click() {
    this.setValue('');
    this.fireEvent('select', this, '', '');
    this.triggers[0].hide();
  },
  // pass to original combobox trigger handler
  onTrigger2Click: function onTrigger2Click() {
    this.onTriggerClick();
  },
  setValue: function setValue(v) {
    if (Ext.isArray(this.triggers) && this.triggers[0] && typeof this.triggers[0].show == 'function') {
      this.triggers[0][v ? 'show' : 'hide']();
    }

    return Ext.ux.form.ClearableDateField.superclass.setValue.apply(this, arguments);
  }
});
Ext.reg('extuxclearabledatefield', Ext.ux.form.ClearableDateField);

/***/ }),
/* 1240 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext, Tine*/
Ext.ns('Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ImageField
 * 
 * <p>A field which displayes a image of the given url and optionally supplies upload
 * button with the feature to display the newly uploaded image on the fly</p>
 * <p>Example usage:</p>
 * <pre><code>
 var formField = new Ext.ux.form.ImageField({
     name: 'jpegimage',
     width: 90,
     height: 90
 });
 * </code></pre>
 */

Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {bool}
   */
  border: true,

  /**
   * @cfg {String}
   */
  defaultImage: 'images/icon-set/icon_undefined_contact.svg',

  /**
   * @cfg {Array} extra context actions
   */
  extraContextActions: null,
  defaultAutoCreate: {
    tag: 'div',
    cls: 'ux-imagefield-ct',
    cn: [{
      tag: 'img',
      cls: 'ux-imagefield-img'
    }, {
      tag: 'div',
      cls: 'ux-imagefield-button'
    }, {
      tag: 'div',
      cls: 'ux-imagefield-text'
    }]
  },
  handleMouseEvents: true,
  initComponent: function initComponent() {
    this.plugins = this.plugins || [];
    this.scope = this;
    this.handler = this.onFileSelect;
    this.browsePlugin = new Ext.ux.file.BrowsePlugin({});
    this.plugins.push(this.browsePlugin);
    Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.registerSkipItem(this);
    Ext.ux.form.ImageField.superclass.initComponent.call(this);
    this.value = this.defaultImage;
  },
  afterRender: function afterRender() {
    this.imageCt = this.el.child('img');
    this.buttonCt = this.el.child('div[class=ux-imagefield-button]');
    this.textCt = this.el.child('div[class=ux-imagefield-text]');

    if (this.border === false) {
      this.el.applyStyles({
        border: '0'
      });
    } else {
      if (this.borderColor) {
        this.el.applyStyles({
          border: '2px solid #' + this.borderColor
        });
      }
    }

    this.loadMask = new Ext.LoadMask(this.buttonCt, {
      msg: i18n._('Loading'),
      msgCls: 'x-mask-loading'
    });
    this.textCt.setSize(this.width, this.height);

    var clickToEditText = i18n._('Click to edit');

    var tm = Ext.util.TextMetrics.createInstance(this.textCt);
    tm.setFixedWidth(this.width);
    this.textCt.applyStyles({
      top: (this.height - tm.getHeight(clickToEditText)) / 2 + 'px'
    });
    this.textCt.insertHtml('afterBegin', clickToEditText);
    Ext.apply(this.browsePlugin, {
      buttonCt: this.buttonCt,
      renderTo: this.buttonCt
    });
    this.el.on('contextmenu', this.onContextMenu, this);
    Ext.ux.form.ImageField.superclass.afterRender.apply(this, arguments);
  },

  /**
  * returns value or empty string
  */
  getValue: function getValue() {
    if (!this.value || this.value === this.defaultImage) {
      return '';
    } else {
      return String(this.value);
    }
  },

  /**
  * set value (image)
  */
  setValue: function setValue(value) {
    Ext.ux.form.ImageField.superclass.setValue.call(this, value);

    if (!value || value === this.defaultImage) {
      this.value = this.defaultImage;
    } else {
      if (value instanceof Ext.ux.util.ImageURL || Ext.isString(value) && value.match(/&/)) {
        this.value = Ext.ux.util.ImageURL.prototype.parseURL(value);
        this.value.width = this.border === false ? this.width : this.width - 4;
        this.value.height = this.border === false ? this.height : this.height - 4;
        this.value.ratiomode = 0;
      } else {
        this.setDefaultImage(value);
      }
    }

    this.updateImage();
  },

  /**
  * show image
  */
  updateImage: function updateImage() {
    var img = Ext.DomHelper.insertAfter(this.imageCt, '<img src="' + this.value + '"/>', true);
    this.imageCt.remove();
    this.imageCt = img;
    this.textCt.setVisible(this.value === this.defaultImage);
    this.imageCt.setOpacity(this.value === this.defaultImage ? 0.2 : 1);
    img.on('load', function () {
      if (this.value === this.defaultImage) {
        this.imageCt.setStyle({
          position: 'absolute',
          top: (this.height - this.imageCt.getHeight()) / 2 + 'px',
          left: (this.width - this.imageCt.getWidth()) / 2 + 'px'
        });
      }

      this.loadMask.hide();
    }, this);
    img.on('error', function () {
      Ext.MessageBox.alert(i18n._('Image Failed'), i18n._('Could not load image. Please notify your Administrator')).setIcon(Ext.MessageBox.ERROR);
      this.loadMask.hide();
    }, this);
  },

  /**
  * set new default image
  */
  setDefaultImage: function setDefaultImage(image) {
    if (this.value === this.defaultImage) {
      this.defaultImage = image;
      this.setValue(this.defaultImage);
    } else {
      this.defaultImage = image;
    }
  },

  /**
   * @private
   */
  onFileSelect: function onFileSelect(fileSelector) {
    if (!fileSelector.isImage()) {
      Ext.MessageBox.alert(i18n._('Not An Image'), i18n._('Please select an image file (gif/png/jpeg)')).setIcon(Ext.MessageBox.ERROR);
      return;
    }

    var files = fileSelector.getFileList();
    this.uploader = new Ext.ux.file.Upload({
      file: files[0],
      fileSelector: fileSelector,
      id: Tine.Tinebase.uploadManager.generateUploadId()
    });
    this.uploader.on('uploadcomplete', this.onUploadComplete, this);
    this.uploader.on('uploadfailure', this.onUploadFail, this);
    this.loadMask.show();
    this.uploader.upload();

    if (this.ctxMenu) {
      this.ctxMenu.hide();
    }
  },
  onUploadComplete: function onUploadComplete(upload, record) {
    this.uploader.un('uploadcomplete', this.onUploadComplete, this);
    this.uploader.un('uploadfailure', this.onUploadFail, this);
    var value = new Ext.ux.util.ImageURL({
      id: record.get('tempFile').id,
      width: this.width,
      height: this.height,
      ratiomode: 0
    });
    this.setValue(value);
  },

  /**
   * @private
   */
  onUploadFail: function onUploadFail() {
    this.uploader.un('uploadcomplete', this.onUploadComplete, this);
    this.uploader.un('uploadfailure', this.onUploadFail, this);
    Ext.MessageBox.alert(i18n._('Upload Failed'), i18n._('Could not upload image. Please notify your Administrator')).setIcon(Ext.MessageBox.ERROR);
  },

  /**
   * executed on image contextmenu
   * @private
   */
  onContextMenu: function onContextMenu(e, input) {
    e.stopEvent();

    if (this.ctxMenu) {
      this.ctxMenu.destroy();
    }

    var upload = new Ext.menu.Item({
      text: i18n._('Change Image'),
      iconCls: 'action_uploadImage',
      handler: this.onFileSelect,
      scope: this,
      plugins: [new Ext.ux.file.BrowsePlugin({})]
    });
    this.ctxMenu = new Ext.menu.Menu({
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-MainContextMenu'
      }],
      items: [upload, {
        text: i18n._('Crop Image'),
        iconCls: 'action_cropImage',
        scope: this,
        disabled: true,
        handler: function handler() {
          var cropper = new Ext.ux.form.ImageCropper({
            imageURL: this.value
          });
          var dlg = new Tine.widgets.dialog.EditRecord({
            handlerScope: this,
            handlerCancle: this.close,
            items: cropper
          });
          var win = Tine.WindowFactory.getWindow({
            width: 320,
            height: 320,
            title: i18n._('Crop Image'),
            layout: 'fit',
            items: dlg
          });
        }
      }, {
        text: i18n._('Delete Image'),
        iconCls: 'action_delete',
        disabled: this.value === this.defaultImage,
        scope: this,
        handler: function handler() {
          this.setValue('');
        }
      }, {
        text: i18n._('Show Original Image'),
        iconCls: 'action_originalImage',
        disabled: this.value === this.defaultImage,
        scope: this,
        handler: this.downloadImage
      }].concat(this.getExtraContextActions())
    });
    this.ctxMenu.showAt(e.getXY());
  },
  getExtraContextActions: function getExtraContextActions() {
    return this.extraContextActions || [];
  },
  downloadImage: function downloadImage() {
    var url = Ext.apply(this.value, {
      height: -1,
      width: -1
    }).toString();
    var window = Tine.WindowFactory.getWindow({
      url: url,
      name: 'showImage',
      width: 800,
      height: 600
    });
  },

  /**
  * clean up
  */
  onDestroy: function onDestroy() {
    this.imageCt.remove();
    this.buttonCt.remove();
    this.textCt.remove();
    this.imageCt = null;
    this.buttonCt = null;
    this.textCt = null;
    this.loadMask.destroy();

    if (this.ctxMenu) {
      this.ctxMenu.destroy();
    }

    this.uploader = null;
    Ext.ux.form.ImageField.superclass.onDestroy.call(this);
  }
});
Ext.reg('ux.imagefield', Ext.ux.form.ImageField);
Ext.ns('Ext.ux.util');
/**
 * this class represents an image URL
 */

Ext.ux.util.ImageURL = function (config) {
  Ext.apply(this, config, {
    url: 'index.php',
    method: 'Tinebase.getImage',
    application: 'Tinebase',
    location: 'tempFile',
    width: 90,
    height: 120,
    ratiomode: 0,
    mtime: new Date().getTime()
  });
};
/**
 * generates an imageurl according to the class members
 * 
 * @return {String}
 */


Ext.ux.util.ImageURL.prototype.toString = function () {
  return this.url + "?method=" + this.method + "&application=" + this.application + "&location=" + this.location + "&id=" + this.id + "&width=" + this.width + "&height=" + this.height + "&ratiomode=" + this.ratiomode + "&mtime=" + this.mtime;
};
/**
 * parses an imageurl
 * 
 * @param  {String} url
 * @return {Ext.ux.util.ImageURL}
 */


Ext.ux.util.ImageURL.prototype.parseURL = function (url) {
  var urlString = url.toString(),
      params = {},
      lparams = urlString.substr(urlString.indexOf('?') + 1).split('&');

  for (var i = 0, j = lparams.length; i < j; i += 1) {
    var param = lparams[i].split('=');
    params[param[0]] = Ext.util.Format.htmlEncode(param[1]);
  }

  return new Ext.ux.util.ImageURL(params);
};

/***/ }),
/* 1241 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.form');
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.ImageCropper
 * @extends     Ext.Component
 */

Ext.ux.form.ImageCropper = function (config) {
  Ext.apply(this, config);
  Ext.ux.form.ImageCropper.superclass.constructor.apply(this, arguments);
  this.addEvents(
  /**
   * @event uploadcomplete
   * Fires when the upload was done successfully 
   * @param {String} croped image
   */
  'imagecropped');
};

Ext.extend(Ext.ux.form.ImageCropper, Ext.Component, {
  /**
   * @property {Object} natrual size of image
   */
  imageSize: false,
  width: 320,
  height: 320,
  initComponent: function initComponent() {
    this.imageURL.width = 290;
    this.imageURL.height = 240;
    this.imageURL.ratiomode = 1;
    Ext.ux.form.ImageCropper.superclass.initComponent.call(this);
  },
  onRender: function onRender(ct, position) {
    Ext.ux.form.ImageCropper.superclass.onRender.call(this, ct, position);
    this.wrapEl = Ext.DomHelper.insertFirst(ct, {
      tag: 'div'
    }, true); //this.maskEl = Ext.DomHelper.insertFirst(this.wrapEl, {tag: 'div', style: 'background-color: #000000'}, true);
    // bg image

    this.bgImageEl = Ext.DomHelper.insertFirst(this.wrapEl, {
      tag: 'img',
      id: 'yui_img',
      src: this.imageURL
    }, true);
    this.bgImageEl.setOpacity(0.5); // yui cropper is very fast. 
    // cause of the window usage the yui crop mask does not work, so we use the mask obove

    /*
    var Dom = YAHOO.util.Dom, 
    Event = YAHOO.util.Event;
         var crop = new YAHOO.widget.ImageCropper('yui_img');
    */
    // Ext only implementation is very slow!
    // the bad news is that the resizeable dosn't fire events while resizeing 
    // and that the dd onDrag looses scope

    this.fgImageEl = Ext.DomHelper.insertFirst(this.wrapEl, {
      tag: 'div',
      style: {
        width: '100px',
        height: '100px',
        position: 'absolute',
        top: '30px',
        left: '30px',
        'background-image': 'url(' + this.imageURL + ')',
        'background-repeat': 'no-repeat'
      }
    }, true);
    this.resizeable = new Ext.Resizable(this.fgImageEl, {
      wrap: true,
      pinned: true,
      handles: 's e se',
      draggable: true,
      dynamic: true
    });
    this.resizeable.dd.fgImageEl = this.fgImageEl;
    this.resizeable.dd.bgImageEl = this.bgImageEl;
    this.resizeable.dd.onDrag = this.syncImageEls; // fix opacity, which might be broken by the inherited window properties

    var rhs = this.resizeable.getEl().query('div.x-resizable-handle');

    for (var i = 0, j = rhs.length; i < j; i++) {
      Ext.get(rhs[i]).setOpacity(1);
    }

    this.syncImageEls();
  },

  /**
   * sync fg image with bg image
   */
  syncImageEls: function syncImageEls() {
    var dx = this.bgImageEl.getX() - this.fgImageEl.getX();
    var dy = this.bgImageEl.getY() - this.fgImageEl.getY();
    this.fgImageEl.setStyle('background-position', dx + 'px ' + dy + 'px');
  }
});

/***/ }),
/* 1242 */
/***/ (function(module, exports) {

/**
 * Copyright (c) 2008, Steven Chim
 * All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
 * 
 *     * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
 *     * The names of its contributors may not be used to endorse or promote products derived from this software without specific prior written permission.
 * 
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

/**
  * Ext.ux.form.Spinner Class
  *
  * @author  Steven Chim
  * @version Spinner.js 2008-08-27 v0.35
  *
  * @class Ext.ux.form.Spinner
  * @extends Ext.form.TriggerField
  */
Ext.ns("Ext.ux.form");
/**
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.Spinner
 * @extends     Ext.form.TriggerField
 */

Ext.ux.form.Spinner = function (config) {
  Ext.ux.form.Spinner.superclass.constructor.call(this, config);
  this.addEvents({
    'spin': true,
    'spinup': true,
    'spindown': true
  });
};

Ext.extend(Ext.ux.form.Spinner, Ext.form.TriggerField, {
  triggerClass: 'x-form-spinner-trigger',
  splitterClass: 'x-form-spinner-splitter',
  alternateKey: Ext.EventObject.shiftKey,
  strategy: undefined,
  //private
  onRender: function onRender(ct, position) {
    Ext.ux.form.Spinner.superclass.onRender.call(this, ct, position);
    this.splitter = this.wrap.createChild({
      tag: 'div',
      cls: this.splitterClass,
      style: 'width:13px; height:2px;'
    });
    this.splitter.show().setRight(Ext.isIE ? 1 : 2);
    this.splitter.show().setTop(8);
    this.proxy = this.trigger.createProxy('', this.splitter, true);
    this.proxy.addClass("x-form-spinner-proxy");
    this.proxy.setStyle('left', '0px');
    this.proxy.setSize(14, 1);
    this.proxy.hide();
    this.dd = new Ext.dd.DDProxy(this.splitter.dom.id, "SpinnerDrag", {
      dragElId: this.proxy.id
    });
    this.initSpinner();
  },
  //private
  initTrigger: function initTrigger() {
    this.trigger.addClassOnOver('x-form-trigger-over');
    this.trigger.addClassOnClick('x-form-trigger-click');
  },
  //private
  initSpinner: function initSpinner() {
    this.keyNav = new Ext.KeyNav(this.el, {
      "up": function up(e) {
        e.preventDefault();
        this.onSpinUp();
      },
      "down": function down(e) {
        e.preventDefault();
        this.onSpinDown();
      },
      "pageUp": function pageUp(e) {
        e.preventDefault();
        this.onSpinUpAlternate();
      },
      "pageDown": function pageDown(e) {
        e.preventDefault();
        this.onSpinDownAlternate();
      },
      scope: this
    });
    this.repeater = new Ext.util.ClickRepeater(this.trigger);
    this.repeater.on("click", this.onTriggerClick, this, {
      preventDefault: true
    });
    this.trigger.on("mouseover", this.onMouseOver, this, {
      preventDefault: true
    });
    this.trigger.on("mouseout", this.onMouseOut, this, {
      preventDefault: true
    });
    this.trigger.on("mousemove", this.onMouseMove, this, {
      preventDefault: true
    });
    this.trigger.on("mousedown", this.onMouseDown, this, {
      preventDefault: true
    });
    this.trigger.on("mouseup", this.onMouseUp, this, {
      preventDefault: true
    });
    this.wrap.on("mousewheel", this.handleMouseWheel, this);
    this.dd.setXConstraint(0, 0, 10);
    this.dd.setYConstraint(1500, 1500, 10);
    this.dd.endDrag = this.endDrag.createDelegate(this);
    this.dd.startDrag = this.startDrag.createDelegate(this);
    this.dd.onDrag = this.onDrag.createDelegate(this);
    /*
    jsakalos suggestion
    http://extjs.com/forum/showthread.php?p=121850#post121850 */

    if ('object' == typeof this.strategy && this.strategy.xtype) {
      switch (this.strategy.xtype) {
        case 'number':
          this.strategy = new Ext.ux.form.Spinner.NumberStrategy(this.strategy);
          break;

        case 'date':
          this.strategy = new Ext.ux.form.Spinner.DateStrategy(this.strategy);
          break;

        case 'time':
          this.strategy = new Ext.ux.form.Spinner.TimeStrategy(this.strategy);
          break;

        default:
          delete this.strategy;
          break;
      }

      delete this.strategy.xtype;
    }

    if (this.strategy == undefined) {
      this.strategy = new Ext.ux.form.Spinner.NumberStrategy();
    }

    this.strategy.init(this);
  },
  //private
  onMouseOver: function onMouseOver() {
    if (this.disabled) {
      return;
    }

    var middle = this.getMiddle();
    this.__tmphcls = Ext.EventObject.getPageY() < middle ? 'x-form-spinner-overup' : 'x-form-spinner-overdown';
    this.trigger.addClass(this.__tmphcls);
  },
  //private
  onMouseOut: function onMouseOut() {
    this.trigger.removeClass(this.__tmphcls);
  },
  //private
  onMouseMove: function onMouseMove() {
    if (this.disabled) {
      return;
    }

    var middle = this.getMiddle();

    if (Ext.EventObject.getPageY() > middle && this.__tmphcls == "x-form-spinner-overup" || Ext.EventObject.getPageY() < middle && this.__tmphcls == "x-form-spinner-overdown") {}
  },
  //private
  onMouseDown: function onMouseDown() {
    if (this.disabled) {
      return;
    }

    var middle = this.getMiddle();
    this.__tmpccls = Ext.EventObject.getPageY() < middle ? 'x-form-spinner-clickup' : 'x-form-spinner-clickdown';
    this.trigger.addClass(this.__tmpccls);
  },
  //private
  onMouseUp: function onMouseUp() {
    this.trigger.removeClass(this.__tmpccls);
  },
  //private
  onTriggerClick: function onTriggerClick() {
    if (this.disabled || this.getEl().dom.readOnly) {
      return;
    }

    var middle = this.getMiddle();
    var ud = Ext.EventObject.getPageY() < middle ? 'Up' : 'Down';
    this['onSpin' + ud]();
  },
  //private
  getMiddle: function getMiddle() {
    var t = this.trigger.getTop();
    var h = this.trigger.getHeight();
    var middle = t + h / 2;
    return middle;
  },
  //private
  //checks if control is allowed to spin
  isSpinnable: function isSpinnable() {
    if (this.disabled || this.getEl().dom.readOnly) {
      Ext.EventObject.preventDefault(); //prevent scrolling when disabled/readonly

      return false;
    }

    return true;
  },
  handleMouseWheel: function handleMouseWheel(e) {
    //disable scrolling when not focused
    if (this.wrap.hasClass('x-trigger-wrap-focus') == false) {
      return;
    }

    var delta = e.getWheelDelta();

    if (delta > 0) {
      this.onSpinUp();
      e.stopEvent();
    } else if (delta < 0) {
      this.onSpinDown();
      e.stopEvent();
    }
  },
  //private
  startDrag: function startDrag() {
    this.proxy.show();
    this._previousY = Ext.fly(this.dd.getDragEl()).getTop();
  },
  //private
  endDrag: function endDrag() {
    this.proxy.hide();
  },
  //private
  onDrag: function onDrag() {
    if (this.disabled) {
      return;
    }

    var y = Ext.fly(this.dd.getDragEl()).getTop();
    var ud = '';

    if (this._previousY > y) {
      ud = 'Up';
    } //up


    if (this._previousY < y) {
      ud = 'Down';
    } //down


    if (ud != '') {
      this['onSpin' + ud]();
    }

    this._previousY = y;
  },
  //private
  onSpinUp: function onSpinUp() {
    if (this.isSpinnable() == false) {
      return;
    }

    if (Ext.EventObject.shiftKey == true) {
      this.onSpinUpAlternate();
      return;
    } else {
      this.strategy.onSpinUp(this);
    }

    this.fireEvent("spin", this);
    this.fireEvent("spinup", this);
  },
  //private
  onSpinDown: function onSpinDown() {
    if (this.isSpinnable() == false) {
      return;
    }

    if (Ext.EventObject.shiftKey == true) {
      this.onSpinDownAlternate();
      return;
    } else {
      this.strategy.onSpinDown(this);
    }

    this.fireEvent("spin", this);
    this.fireEvent("spindown", this);
  },
  //private
  onSpinUpAlternate: function onSpinUpAlternate() {
    if (this.isSpinnable() == false) {
      return;
    }

    this.strategy.onSpinUpAlternate(this);
    this.fireEvent("spin", this);
    this.fireEvent("spinup", this);
  },
  //private
  onSpinDownAlternate: function onSpinDownAlternate() {
    if (this.isSpinnable() == false) {
      return;
    }

    this.strategy.onSpinDownAlternate(this);
    this.fireEvent("spin", this);
    this.fireEvent("spindown", this);
  }
});
Ext.reg('uxspinner', Ext.ux.form.Spinner);

/***/ }),
/* 1243 */
/***/ (function(module, exports) {

/**
 * Copyright (c) 2008, Steven Chim
 * All rights reserved.
 * 
 * Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
 * 
 *     * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
 *     * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
 *     * The names of its contributors may not be used to endorse or promote products derived from this software without specific prior written permission.
 * 
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */

/**
 * Abstract Strategy
 *
 * @namespace   Ext.ux.form.Spinner
 * @class       Ext.ux.form.Spinner.Strategy
 * @extends     Ext.util.Observable
 */
Ext.ux.form.Spinner.Strategy = function (config) {
  Ext.apply(this, config);
};

Ext.extend(Ext.ux.form.Spinner.Strategy, Ext.util.Observable, {
  defaultValue: 0,
  minValue: undefined,
  maxValue: undefined,
  incrementValue: 1,
  alternateIncrementValue: 5,
  validationTask: new Ext.util.DelayedTask(),
  init: function init(cmp) {},
  onSpinUp: function onSpinUp(field) {
    this.spin(field, false, false);
  },
  onSpinDown: function onSpinDown(field) {
    this.spin(field, true, false);
  },
  onSpinUpAlternate: function onSpinUpAlternate(field) {
    this.spin(field, false, true);
  },
  onSpinDownAlternate: function onSpinDownAlternate(field) {
    this.spin(field, true, true);
  },
  spin: function spin(field, down, alternate) {
    this.validationTask.delay(500, function () {
      field.validate();
    }); //extend
  },
  fixBoundries: function fixBoundries(value) {
    return value; //overwrite
  }
});
/**
 * Concrete Strategy: Numbers
 * 
 * @namespace   Ext.ux.form.Spinner
 * @class       Ext.ux.form.Spinner.NumberStrategy
 * @extends     Ext.ux.form.Spinner.Strategy
 */

Ext.ux.form.Spinner.NumberStrategy = function (config) {
  Ext.ux.form.Spinner.NumberStrategy.superclass.constructor.call(this, config);
};

Ext.extend(Ext.ux.form.Spinner.NumberStrategy, Ext.ux.form.Spinner.Strategy, {
  init: function init(field) {
    field.setValue = Ext.ux.form.NumberField.prototype.setValue;
    field.parseValue = Ext.ux.form.NumberField.prototype.parseValue;
    field.validateValue = Ext.ux.form.NumberField.prototype.validateValue;
    field.getValue = Ext.ux.form.NumberField.prototype.getValue;
    field.fixPrecision = Ext.ux.form.NumberField.prototype.fixPrecision;
    field.beforeBlur = Ext.ux.form.NumberField.prototype.beforeBlur;
    field.decimalSeparator = Ext.ux.form.NumberField.prototype.decimalSeparator;
    field.thousandSeparator = Ext.ux.form.NumberField.prototype.thousandSeparator;
    field.useThousandSeparator = field.useThousandSeparator === undefined ? Ext.ux.form.NumberField.prototype.useThousandSeparator : field.useThousandSeparator;
    this.decimalPrecision = field.decimalPrecision ? field.decimalPrecision : Ext.ux.form.NumberField.prototype.decimalPrecision;
    field.allowDecimals = field.allowDecimals ? field.allowDecimals : this.allowDecimals;
    field.el.applyStyles('text-align: right');
  },
  spin: function spin(field, down, alternate) {
    Ext.ux.form.Spinner.NumberStrategy.superclass.spin.call(this, field, down, alternate);
    var v = parseFloat(field.getValue());
    var incr = alternate == true ? this.alternateIncrementValue : this.incrementValue;
    down == true ? v -= incr : v += incr;
    v = isNaN(v) ? this.defaultValue : v;
    v = this.fixBoundries(v);
    field.setValue(v);
  },
  fixBoundries: function fixBoundries(value) {
    var v = value;

    if (this.minValue != undefined && v < this.minValue) {
      v = this.minValue;
    }

    if (this.maxValue != undefined && v > this.maxValue) {
      v = this.maxValue;
    }

    return this.fixPrecision(v);
  },
  // private
  fixPrecision: function fixPrecision(value) {
    var nan = isNaN(value);

    if (!this.allowDecimals || this.decimalPrecision == -1 || nan || !value) {
      return nan ? '' : value;
    }

    return parseFloat(parseFloat(value).toFixed(this.decimalPrecision));
  }
});
/**
 * Concrete Strategy: Date
 *
 * @namespace   Ext.ux.form.Spinner
 * @class       Ext.ux.form.Spinner.DateStrategy
 * @extends     Ext.ux.form.Spinner.Strategy
 */

Ext.ux.form.Spinner.DateStrategy = function (config) {
  Ext.ux.form.Spinner.DateStrategy.superclass.constructor.call(this, config);
};

Ext.ux.form.Spinner.DateStrategy.isNegRe = /^ *- */;
Ext.extend(Ext.ux.form.Spinner.DateStrategy, Ext.ux.form.Spinner.Strategy, {
  allowNegative: true,
  defaultValue: new Date(),
  format: "Y-m-d",
  incrementValue: 1,
  incrementConstant: Date.DAY,
  alternateIncrementValue: 1,
  alternateIncrementConstant: Date.MONTH,
  spin: function spin(field, down, alternate) {
    Ext.ux.form.Spinner.DateStrategy.superclass.spin.call(this, field, down, alternate);
    var v = field.getRawValue(),
        isNegValue = v.match(Ext.ux.form.Spinner.DateStrategy.isNegRe);

    if (isNegValue) {
      v = v.replace(Ext.ux.form.Spinner.DateStrategy.isNegRe, '');
    }

    v = Date.parseDate(v, this.format);
    var dir = down == true ? -1 : 1;
    var incr = alternate == true ? this.alternateIncrementValue : this.incrementValue;
    var dtconst = alternate == true ? this.alternateIncrementConstant : this.incrementConstant;

    if (typeof this.defaultValue == 'string') {
      this.defaultValue = Date.parseDate(this.defaultValue, this.format);
    } // transition form 0


    if (v.format('H:i:s') == '00:00:00' && this.allowNegative) {
      isNegValue = down;
    }

    if (isNegValue) {
      dir = dir * -1;
    }

    v = v ? v.add(dtconst, dir * incr) : this.defaultValue;

    if (v.format('H:i:s') == '00:00:00') {
      isNegValue = false;
    }

    v = this.fixBoundries(v);
    field.setRawValue((isNegValue ? '- ' : '') + Ext.util.Format.date(v, this.format));
  },
  //private
  fixBoundries: function fixBoundries(date) {
    var dt = date;
    var min = typeof this.minValue == 'string' ? Date.parseDate(this.minValue, this.format) : this.minValue;
    var max = typeof this.maxValue == 'string' ? Date.parseDate(this.maxValue, this.format) : this.maxValue;

    if (this.minValue != undefined && dt < min) {
      dt = min;
    }

    if (this.maxValue != undefined && dt > max) {
      dt = max;
    }

    return dt;
  }
});
/**
 * Concrete Strategy: Time
 *
 * @namespace   Ext.ux.form.Spinner
 * @class       Ext.ux.form.Spinner.TimeStrategy
 * @extends     Ext.ux.form.Spinner.DateStrategy
 */

Ext.ux.form.Spinner.TimeStrategy = function (config) {
  Ext.ux.form.Spinner.TimeStrategy.superclass.constructor.call(this, config);
};

Ext.extend(Ext.ux.form.Spinner.TimeStrategy, Ext.ux.form.Spinner.DateStrategy, {
  format: "H:i",
  incrementValue: 1,
  incrementConstant: Date.MINUTE,
  alternateIncrementValue: 1,
  alternateIncrementConstant: Date.HOUR
});

/***/ }),
/* 1244 */
/***/ (function(module, exports) {

/**
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2019 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.form');
/**
 * handles minutes to time conversions
 * @class Ext.ux.form.DurationSpinner
 * @extends Ext.ux.form.Spinner
 */

Ext.ux.form.DurationSpinner = Ext.extend(Ext.ux.form.Spinner, {
  /**
   * Set to empty value if value equals 0
   * @cfg emptyOnZero
   */
  emptyOnZero: null,

  /**
   * allow negative values
   * @cfg allowNegative bool
   */
  allowNegative: true,

  /**
   * $cfg {String} baseUnit minutes|seconds
   */
  baseUnit: 'minutes',
  initComponent: function initComponent() {
    this.preventMark = false;
    this.strategy = new Ext.ux.form.Spinner.TimeStrategy({
      incrementValue: 15,
      allowNegative: this.allowNegative
    });
    this.format = this.strategy.format;
    this.on('focus', function (field) {
      field.focus(true, 10);
    });
  },
  setValue: function setValue(value) {
    if (value === "" || value === null || value === undefined) {
      return;
    }

    value = Ext.ux.form.DurationSpinner.durationRenderer(value, this);
    Ext.ux.form.DurationSpinner.superclass.setValue.call(this, value);
  },
  validateValue: function validateValue(value) {
    if (value.search(/:/) != -1) {
      value = value.replace(Ext.ux.form.Spinner.DateStrategy.isNegRe, '');
      var parts = value.split(':'),
          hours = parseInt(parts[0]),
          minutes = parseInt(parts[1]);
      return 'NaN' != hours && 'NaN' != minutes;
    }
  },
  getValue: function getValue() {
    var value = Ext.ux.form.DurationSpinner.superclass.getValue.call(this),
        isNegValue = false;
    value = value.replace(',', '.');

    if (value && typeof value == 'string') {
      if (value.match(Ext.ux.form.Spinner.DateStrategy.isNegRe)) {
        value = value.replace(Ext.ux.form.Spinner.DateStrategy.isNegRe, '');
        isNegValue = true;
      }

      if (value.search(/:/) != -1) {
        var parts = value.split(':'),
            hours = parseInt(parts[0]),
            minutes = parseInt(parts[1]);

        if (0 > hours) {
          hours = 0;
        }

        if (0 > minutes) {
          minutes = 0;
        }

        if (minutes > 0) {
          value = hours * 60 + minutes;
        } else {
          value = hours * 60;
        }
      } else if (value > 0) {
        value = value * 60;
      } else {
        this.markInvalid(i18n._('Not a valid time'));
        return;
      }
    }

    if (this.baseUnit == 'seconds') {
      value = value * 60;
    }

    if (isNegValue) {
      value = -1 * value;
    }

    this.setValue(value);
    return value;
  }
});

Ext.ux.form.DurationSpinner.durationRenderer = function (value, config) {
  if (!value || value == '00:00') {
    value = config.emptyOnZero ? '' : '00:00';
  } else if (!value.toString().match(/:/)) {
    if (config.baseUnit == 'seconds') {
      value = Math.round(value / 60);
    }

    var isNegValue = value < 0,
        hours = Math.floor(Math.abs(value) / 60),
        minutes = Math.abs(value) - hours * 60;

    if (hours < 10) {
      hours = '0' + hours;
    }

    if (minutes < 10) {
      minutes = '0' + minutes;
    }

    if (minutes !== 0) {
      value = hours + ':' + minutes;
    } else {
      value = hours + ':00';
    }

    if (isNegValue) {
      value = '- ' + value;
    }
  }

  return value;
};

Ext.reg('durationspinner', Ext.ux.form.DurationSpinner);

/***/ }),
/* 1245 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Thomas Wadewitz <t.wadewitz@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * @todo        switch lock and trigger icons (because only the trigger icon has a round upper right corner)
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * Generic widget for a twin trigger combo field
 *
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.LockCombo
 * @extends     Ext.form.ComboBox
 */

Ext.ux.form.LockCombo = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {String} paramName
   */
  paramName: 'query',

  /**
   * @cfg {Bool} selectOnFocus
   */
  selectOnFocus: true,

  /**
   * @cfg {String} emptyText
   */
  emptyText: 'select entry...',
  hiddenFieldId: '',
  hiddenFieldData: '',
  validationEvent: false,
  validateOnBlur: false,
  trigger1Class: 'x-form-trigger',
  trigger2ClassLocked: 'x-form-locked-trigger',
  trigger2ClassUnlocked: 'x-form-unlocked-trigger',
  hideTrigger1: false,
  width: 180,
  hasSearch: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    Ext.ux.form.LockCombo.superclass.initComponent.call(this);

    if (!this.hiddenFieldData) {
      this.hiddenFieldData = '1';
    }

    this.triggerConfig = {
      tag: 'span',
      cls: 'x-form-twin-triggers',
      cn: [{
        tag: "img",
        id: 'trigger1',
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger " + this.trigger1Class
      }, {
        tag: "img",
        id: 'trigger2',
        src: Ext.BLANK_IMAGE_URL,
        cls: "x-form-trigger "
      }]
    };
  },
  getTrigger: function getTrigger(index) {
    return this.triggers[index];
  },
  initTrigger: function initTrigger() {
    var ts = this.trigger.select('.x-form-trigger', true);
    this.wrap.setStyle('overflow', 'hidden');
    var triggerField = this;
    ts.each(function (t, all, index) {
      t.hide = function () {
        var w = triggerField.wrap.getWidth();
        this.dom.style.display = 'none';
        triggerField.el.setWidth(w - triggerField.trigger.getWidth());
      };

      t.show = function () {
        var w = triggerField.wrap.getWidth();
        this.dom.style.display = '';
        triggerField.el.setWidth(w - triggerField.trigger.getWidth());
      };

      var triggerIndex = 'Trigger' + (index + 1);

      if (this['hide' + triggerIndex]) {
        t.dom.style.display = 'none';
      }

      t.on("click", this['on' + triggerIndex + 'Click'], this, {
        preventDefault: true
      });

      if (t.id == 'trigger2') {
        if (this.hiddenFieldData == '0') {
          var _cssClass = this.trigger2ClassLocked.toString();

          t.addClass(_cssClass);
        }

        if (this.hiddenFieldData == '1' || !this.hiddenFieldData) {
          var _cssClass = this.trigger2ClassUnlocked.toString();

          t.addClass(_cssClass);
        }
      }

      t.addClassOnOver('x-form-trigger-over');
      t.addClassOnClick('x-form-trigger-click');
    }, this);
    this.triggers = ts.elements;
  },
  onRender: function onRender(ct, position) {
    Ext.ux.form.LockCombo.superclass.onRender.call(this, ct, position); // render the Ext.Button

    this.hiddenBox = ct.parent().createChild({
      tag: 'input',
      type: 'hidden',
      name: this.hiddenFieldId,
      id: this.hiddenFieldId,
      value: this.hiddenFieldData
    });
    Ext.ComponentMgr.register(this.hiddenBox);
  },
  onTrigger1Click: function onTrigger1Click() {
    if (this.disabled) {
      return;
    }

    if (this.isExpanded()) {
      this.collapse();
      this.el.focus();
    } else {
      this.onFocus({});

      if (this.triggerAction == 'all') {
        this.doQuery(this.allQuery, true);
      } else {
        this.doQuery(this.getRawValue());
      }

      this.el.focus();
    }
  },
  onTrigger2Click: function onTrigger2Click() {
    var _currentValue = Ext.getCmp(this.hiddenFieldId).getValue();

    var ts = this.trigger.select('.x-form-trigger', true);

    if (_currentValue == '0') {
      Ext.getCmp(this.hiddenFieldId).dom.value = '1';

      var _cssClass = this.trigger2ClassUnlocked.toString();

      ts.each(function (t, all, index) {
        if (t.id == 'trigger2') {
          t.dom.className = "x-form-trigger " + _cssClass;
        }
      });
    } else {
      Ext.getCmp(this.hiddenFieldId).dom.value = '0';

      var _cssClass = this.trigger2ClassLocked.toString();

      ts.each(function (t, all, index) {
        if (t.id == 'trigger2') {
          t.dom.className = "x-form-trigger " + _cssClass;
        }
      });
    }
  }
});
Ext.reg('lockCombo', Ext.ux.form.LockCombo);

/***/ }),
/* 1246 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.form');
/**
 * Generic widget for a twin trigger textfield
 *
 * @namespace   Ext.ux.form
 * @class       Ext.ux.form.LockTextfield
 * @extends     Ext.form.TriggerField
 */

Ext.ux.form.LockTextfield = Ext.extend(Ext.form.TriggerField, {
  hiddenFieldId: '',
  hiddenFieldData: '',
  triggerClassLocked: 'x-form-locked-trigger',
  triggerClassUnlocked: 'x-form-unlocked-trigger',

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.triggerClass = this.hiddenFieldData == '1' ? this.triggerClassUnlocked : this.triggerClassLocked;
    Ext.ux.form.LockTextfield.superclass.initComponent.call(this);
  },
  onRender: function onRender(ct, position) {
    Ext.ux.form.LockTextfield.superclass.onRender.call(this, ct, position); // render the textfield

    this.hiddenBox = ct.parent().createChild({
      tag: 'input',
      type: 'hidden',
      name: this.hiddenFieldId,
      id: this.hiddenFieldId,
      value: this.hiddenFieldData
    });
    Ext.ComponentMgr.register(this.hiddenBox);
  },
  onTriggerClick: function onTriggerClick() {
    //this.hiddenFieldData = (this.hiddenFieldData == '1') ? '0' : '1';
    //this.triggerClass = (this.hiddenFieldData == '1') ? 'x-form-unlocked-trigger' : 'x-form-locked-trigger';
    var _currentValue = Ext.getCmp(this.hiddenFieldId).getValue();

    if (_currentValue == '0') {
      Ext.getCmp(this.hiddenFieldId).dom.value = '1';
      this.trigger.removeClass(this.triggerClassLocked);
      this.trigger.addClass(this.triggerClassUnlocked);
    } else {
      Ext.getCmp(this.hiddenFieldId).dom.value = '0';
      this.trigger.removeClass(this.triggerClassUnlocked);
      this.trigger.addClass(this.triggerClassLocked);
    }
  }
});
Ext.reg('lockTextfield', Ext.ux.form.LockTextfield);

/***/ }),
/* 1247 */
/***/ (function(module, exports) {

/*!
 * MIT license
 */

/**
 * @author Shea Frederick - http://www.vinylfox.com
 * @class Ext.ux.form.HtmlEditor.MidasCommand
 * @extends Ext.util.Observable
 * <p>A base plugin for extending to create standard Midas command buttons.
 * googlecode project page: http://code.google.com/p/ext-ux-htmleditor-plugins/
 * </p>
 */
Ext.ns('Ext.ux.form.HtmlEditor');
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.MidasCommand
 * @extends     Ext.util.Observable
 */

Ext.ux.form.HtmlEditor.MidasCommand = Ext.extend(Ext.util.Observable, {
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.btns = [];
    this.cmp.on('render', this.onRender, this);
    this.cmp.on('initialize', this.onInit, this, {
      delay: 100,
      single: true
    });
  },
  // private
  onInit: function onInit() {
    Ext.EventManager.on(this.cmp.getDoc(), {
      'mousedown': this.onEditorEvent,
      'dblclick': this.onEditorEvent,
      'click': this.onEditorEvent,
      'keyup': this.onEditorEvent,
      buffer: 100,
      scope: this
    });
  },
  // private
  onRender: function onRender() {
    var midasCmdButton,
        tb = this.cmp.getToolbar(),
        btn;
    Ext.each(this.midasBtns, function (b) {
      if (Ext.isObject(b)) {
        midasCmdButton = {
          iconCls: 'x-edit-' + b.cmd,
          handler: function handler() {
            this.cmp.relayCmd(b.cmd);
          },
          scope: this,
          tooltip: b.tooltip || {
            title: b.title
          },
          overflowText: b.overflowText || b.title
        };
      } else {
        midasCmdButton = new Ext.Toolbar.Separator();
      }

      btn = tb.addButton(midasCmdButton);

      if (b.enableOnSelection) {
        btn.disable();
      }

      this.btns.push(btn);
    }, this);
  },
  // private
  onEditorEvent: function onEditorEvent() {
    var doc = this.cmp.getDoc();
    Ext.each(this.btns, function (b, i) {
      if (this.midasBtns[i].enableOnSelection || this.midasBtns[i].disableOnSelection) {
        if (doc.getSelection) {
          if (this.midasBtns[i].enableOnSelection && doc.getSelection() !== '' || this.midasBtns[i].disableOnSelection && doc.getSelection() === '') {
            b.enable();
          } else {
            b.disable();
          }
        } else if (doc.selection) {
          if (this.midasBtns[i].enableOnSelection && doc.selection.createRange().text !== '' || this.midasBtns[i].disableOnSelection && doc.selection.createRange().text === '') {
            b.enable();
          } else {
            b.disable();
          }
        }
      }

      if (this.midasBtns[i].monitorCmdState) {
        b.toggle(doc.queryCommandState(this.midasBtns[i].cmd));
      }
    }, this);
  }
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.Divider
 * @extends     Ext.util.Observable
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates a divider on the HtmlEditor. Used for separating additional buttons.</p>
 */

Ext.ux.form.HtmlEditor.Divider = Ext.extend(Ext.util.Observable, {
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.cmp.on('render', this.onRender, this);
  },
  // private
  onRender: function onRender() {
    this.cmp.getToolbar().addButton([new Ext.Toolbar.Separator()]);
  }
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.IndentOutdent
 * @extends     Ext.ux.form.HtmlEditor.MidasCommand
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates two buttons on the HtmlEditor for indenting and outdenting of selected text.</p>
 */

Ext.ux.form.HtmlEditor.IndentOutdent = Ext.extend(Ext.ux.form.HtmlEditor.MidasCommand, {
  // private
  midasBtns: ['|', {
    cmd: 'outdent',
    tooltip: {
      title: 'Outdent Text'
    },
    overflowText: 'Outdent Text'
  }, {
    cmd: 'indent',
    tooltip: {
      title: 'Indent Text'
    },
    overflowText: 'Indent Text'
  }]
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.RemoveFormat
 * @extends     Ext.ux.form.HtmlEditor.MidasCommand
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates a button on the HtmlEditor that will remove all formatting on selected text.</p>
 */

Ext.ux.form.HtmlEditor.RemoveFormat = Ext.extend(Ext.ux.form.HtmlEditor.MidasCommand, {
  midasBtns: ['|', {
    enableOnSelection: true,
    cmd: 'removeFormat',
    tooltip: {
      title: 'Remove Formatting'
    },
    overflowText: 'Remove Formatting'
  }]
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.SubSuperScript
 * @extends     Ext.ux.form.HtmlEditor.MidasCommand
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates two buttons on the HtmlEditor for superscript and subscripting of selected text.</p>
 */

Ext.ux.form.HtmlEditor.SubSuperScript = Ext.extend(Ext.ux.form.HtmlEditor.MidasCommand, {
  // private
  midasBtns: ['|', {
    enableOnSelection: true,
    cmd: 'subscript',
    tooltip: {
      title: 'Subscript'
    },
    overflowText: 'Subscript'
  }, {
    enableOnSelection: true,
    cmd: 'superscript',
    tooltip: {
      title: 'Superscript'
    },
    overflowText: 'Superscript'
  }]
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.SpecialCharacters
 * @extends     Ext.util.Observable
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates a button on the HtmlEditor for inserting special characters.</p>
 */

Ext.ux.form.HtmlEditor.SpecialCharacters = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Array} specialChars
   * An array of additional characters to display for user selection.  Uses numeric portion of the ASCII HTML Character Code only. For example, to use the Copyright symbol, which is &#169; we would just specify <tt>169</tt> (ie: <tt>specialChars:[169]</tt>).
   */
  specialChars: [],

  /**
   * @cfg {Array} charRange
   * Two numbers specifying a range of ASCII HTML Characters to display for user selection. Defaults to <tt>[160, 256]</tt>.
   */
  charRange: [160, 256],
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.cmp.on('render', this.onRender, this);
  },
  // private
  onRender: function onRender() {
    var cmp = this.cmp;
    var btn = this.cmp.getToolbar().addButton({
      iconCls: 'x-edit-char',
      handler: function handler() {
        if (this.specialChars.length) {
          Ext.each(this.specialChars, function (c, i) {
            this.specialChars[i] = ['&#' + c + ';'];
          }, this);
        }

        for (i = this.charRange[0]; i < this.charRange[1]; i++) {
          this.specialChars.push(['&#' + i + ';']);
        }

        var charStore = new Ext.data.ArrayStore({
          fields: ['char'],
          data: this.specialChars
        });
        this.charWindow = new Ext.Window({
          title: 'Insert Special Character',
          width: 436,
          autoHeight: true,
          layout: 'fit',
          items: [{
            xtype: 'dataview',
            store: charStore,
            ref: '../charView',
            autoHeight: true,
            multiSelect: true,
            tpl: new Ext.XTemplate('<tpl for="."><div class="char-item">{char}</div></tpl><div class="x-clear"></div>'),
            overClass: 'char-over',
            itemSelector: 'div.char-item',
            listeners: {
              dblclick: function dblclick(t, i, n, e) {
                this.insertChar(t.getStore().getAt(i).get('char'));
                this.charWindow.close();
              },
              scope: this
            }
          }],
          buttons: [{
            text: 'Insert',
            handler: function handler() {
              Ext.each(this.charWindow.charView.getSelectedRecords(), function (rec) {
                var c = rec.get('char');
                this.insertChar(c);
              }, this);
              this.charWindow.close();
            },
            scope: this
          }, {
            text: 'Cancel',
            handler: function handler() {
              this.charWindow.close();
            },
            scope: this
          }]
        });
        this.charWindow.show();
      },
      scope: this,
      tooltip: {
        title: 'Insert Special Character'
      },
      overflowText: 'Special Characters'
    });
  },

  /**
   * Insert a single special character into the document.
   * @param c String The special character to insert (not just the numeric code, but the entire ASCII HTML entity).
   */
  insertChar: function insertChar(c) {
    if (c) {
      this.cmp.insertAtCursor(c);
    }
  }
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.Table
 * @extends     Ext.util.Observable
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates a button on the HtmlEditor for making simple tables.</p>
 */

Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
  // private
  cmd: 'table',

  /**
   * @cfg {Array} tableBorderOptions
   * A nested array of value/display options to present to the user for table border style. Defaults to a simple list of 5 varrying border types.
   */
  tableBorderOptions: [['none', 'None'], ['1px solid #000', 'Sold Thin'], ['2px solid #000', 'Solid Thick'], ['1px dashed #000', 'Dashed'], ['1px dotted #000', 'Dotted']],
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.cmp.on('render', this.onRender, this);
  },
  // private
  onRender: function onRender() {
    var cmp = this.cmp;
    var btn = this.cmp.getToolbar().addButton({
      iconCls: 'x-edit-table',
      handler: function handler() {
        if (!this.tableWindow) {
          this.tableWindow = new Ext.Window({
            title: 'Insert Table',
            closeAction: 'hide',
            items: [{
              itemId: 'insert-table',
              xtype: 'form',
              border: false,
              plain: true,
              bodyStyle: 'padding: 10px;',
              labelWidth: 60,
              labelAlign: 'right',
              items: [{
                xtype: 'numberfield',
                allowBlank: false,
                allowDecimals: false,
                fieldLabel: 'Rows',
                name: 'row',
                width: 60
              }, {
                xtype: 'numberfield',
                allowBlank: false,
                allowDecimals: false,
                fieldLabel: 'Columns',
                name: 'col',
                width: 60
              }, {
                xtype: 'combo',
                fieldLabel: 'Border',
                name: 'border',
                forceSelection: true,
                mode: 'local',
                store: new Ext.data.ArrayStore({
                  autoDestroy: true,
                  fields: ['spec', 'val'],
                  data: this.tableBorderOptions
                }),
                triggerAction: 'all',
                value: 'none',
                displayField: 'val',
                valueField: 'spec',
                width: 90
              }]
            }],
            buttons: [{
              text: 'Insert',
              handler: function handler() {
                var frm = this.tableWindow.getComponent('insert-table').getForm();

                if (frm.isValid()) {
                  var border = frm.findField('border').getValue();
                  var rowcol = [frm.findField('row').getValue(), frm.findField('col').getValue()];

                  if (rowcol.length == 2 && rowcol[0] > 0 && rowcol[0] < 10 && rowcol[1] > 0 && rowcol[1] < 10) {
                    var html = "<table>";

                    for (var row = 0; row < rowcol[0]; row++) {
                      html += "<tr>";

                      for (var col = 0; col < rowcol[1]; col++) {
                        html += "<td width='20%' style='border: " + border + ";'>" + row + "-" + col + "</td>";
                      }

                      html += "</tr>";
                    }

                    html += "</table>";
                    this.cmp.insertAtCursor(html);
                  }

                  this.tableWindow.hide();
                } else {
                  if (!frm.findField('row').isValid()) {
                    frm.findField('row').getEl().frame();
                  } else if (!frm.findField('col').isValid()) {
                    frm.findField('col').getEl().frame();
                  }
                }
              },
              scope: this
            }, {
              text: 'Cancel',
              handler: function handler() {
                this.tableWindow.hide();
              },
              scope: this
            }]
          });
        } else {
          this.tableWindow.getEl().frame();
        }

        this.tableWindow.show();
      },
      scope: this,
      tooltip: {
        title: 'Insert Table'
      },
      overflowText: 'Table'
    });
  }
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.Word
 * @extends     Ext.util.Observable
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates a button on the HtmlEditor for pasting text from Word without all the jibberish html.</p>
 */

Ext.ux.form.HtmlEditor.Word = Ext.extend(Ext.util.Observable, {
  curLength: 0,
  lastLength: 0,
  lastValue: '',
  wordPasteEnabled: true,
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.cmp.on('render', this.onRender, this);
    this.cmp.on('initialize', this.onInit, this, {
      delay: 100,
      single: true
    });
  },
  // private
  onInit: function onInit() {
    Ext.EventManager.on(this.cmp.getDoc(), {
      'keyup': this.checkIfPaste,
      scope: this
    });
    this.lastValue = this.cmp.getValue();
    this.curLength = this.lastValue.length;
    this.lastLength = this.lastValue.length;
  },
  // private
  checkIfPaste: function checkIfPaste(e) {
    var diffAt = 0;
    this.curLength = this.cmp.getValue().length;

    if (e.V == e.getKey() && e.ctrlKey && this.wordPasteEnabled) {
      this.cmp.suspendEvents();
      diffAt = this.findValueDiffAt(this.cmp.getValue());
      var parts = [this.cmp.getValue().substr(0, diffAt), this.fixWordPaste(this.cmp.getValue().substr(diffAt, this.curLength - this.lastLength)), this.cmp.getValue().substr(this.curLength - this.lastLength + diffAt, this.curLength)];
      this.cmp.setValue(parts.join(''));
      this.cmp.resumeEvents();
    }

    this.lastLength = this.cmp.getValue().length;
    this.lastValue = this.cmp.getValue();
  },
  // private
  findValueDiffAt: function findValueDiffAt(val) {
    for (i = 0; i < this.curLength; i++) {
      if (this.lastValue[i] != val[i]) {
        return i;
      }
    }
  },

  /**
   * Cleans up the jubberish html from Word pasted text.
   * @param wordPaste String The text that needs to be cleansed of Word jibberish html.
   * @return {String} The passed in text with all Word jibberish html removed.
   */
  fixWordPaste: function fixWordPaste(wordPaste) {
    var removals = [/&nbsp;/ig, /[\r\n]/g, /<(xml|style)[^>]*>.*?<\/\1>/ig, /<\/?(meta|object|span)[^>]*>/ig, /<\/?[A-Z0-9]*:[A-Z]*[^>]*>/ig, /(lang|class|type|href|name|title|id|clear)=\"[^\"]*\"/ig, /style=(\'\'|\"\")/ig, /<![\[-].*?-*>/g, /MsoNormal/g, /<\\?\?xml[^>]*>/g, /<\/?o:p[^>]*>/g, /<\/?v:[^>]*>/g, /<\/?o:[^>]*>/g, /<\/?st1:[^>]*>/g, /&nbsp;/g, /<\/?SPAN[^>]*>/g, /<\/?FONT[^>]*>/g, /<\/?STRONG[^>]*>/g, /<\/?H1[^>]*>/g, /<\/?H2[^>]*>/g, /<\/?H3[^>]*>/g, /<\/?H4[^>]*>/g, /<\/?H5[^>]*>/g, /<\/?H6[^>]*>/g, /<\/?P[^>]*><\/P>/g, /<!--(.*)-->/g, /<!--(.*)>/g, /<!(.*)-->/g, /<\\?\?xml[^>]*>/g, /<\/?o:p[^>]*>/g, /<\/?v:[^>]*>/g, /<\/?o:[^>]*>/g, /<\/?st1:[^>]*>/g, /style=\"[^\"]*\"/g, /style=\'[^\"]*\'/g, /lang=\"[^\"]*\"/g, /lang=\'[^\"]*\'/g, /class=\"[^\"]*\"/g, /class=\'[^\"]*\'/g, /type=\"[^\"]*\"/g, /type=\'[^\"]*\'/g, /href=\'#[^\"]*\'/g, /href=\"#[^\"]*\"/g, /name=\"[^\"]*\"/g, /name=\'[^\"]*\'/g, / clear=\"all\"/g, /id=\"[^\"]*\"/g, /title=\"[^\"]*\"/g, /<span[^>]*>/g, /<\/?span[^>]*>/g, /class=/g];
    Ext.each(removals, function (s) {
      wordPaste = wordPaste.replace(s, "");
    }); // keep the divs in paragraphs

    wordPaste = wordPaste.replace(/<div[^>]*>/g, "<p>");
    wordPaste = wordPaste.replace(/<\/?div[^>]*>/g, "</p>");
    return wordPaste;
  },
  // private
  onRender: function onRender() {
    this.cmp.getToolbar().add({
      iconCls: 'x-edit-wordpaste',
      pressed: true,
      handler: function handler(t) {
        t.toggle(!t.pressed);
        this.wordPasteEnabled = !this.wordPasteEnabled;
      },
      scope: this,
      tooltip: {
        text: 'Cleanse text pasted from Word or other Rich Text applications'
      }
    });
  }
});
/**
 * @namespace   Ext.ux.form.HtmlEditor
 * @class       Ext.ux.form.HtmlEditor.HR
 * @extends     Ext.util.Observable
 * @author      Shea Frederick - http://www.vinylfox.com
 * 
 * <p>A plugin that creates a button on the HtmlEditor for inserting a horizontal rule.</p>
 */

Ext.ux.form.HtmlEditor.HR = Ext.extend(Ext.util.Observable, {
  // private
  cmd: 'hr',
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.cmp.on('render', this.onRender, this);
  },
  // private
  onRender: function onRender() {
    var cmp = this.cmp;
    var btn = this.cmp.getToolbar().addButton({
      iconCls: 'x-edit-hr',
      handler: function handler() {
        if (!this.hrWindow) {
          this.hrWindow = new Ext.Window({
            title: 'Insert Rule',
            closeAction: 'hide',
            items: [{
              itemId: 'insert-hr',
              xtype: 'form',
              border: false,
              plain: true,
              bodyStyle: 'padding: 10px;',
              labelWidth: 60,
              labelAlign: 'right',
              items: [{
                xtype: 'label',
                html: 'Enter the width of the Rule in percentage<br/> followed by the % sign at the end, or to<br/> set a fixed width omit the % symbol.<br/>&nbsp;'
              }, {
                xtype: 'textfield',
                maskRe: /[0-9]|%/,
                regex: /^[1-9][0-9%]{1,3}/,
                fieldLabel: 'Width',
                name: 'hrwidth',
                width: 60,
                listeners: {
                  specialkey: function specialkey(f, e) {
                    if ((e.getKey() == e.ENTER || e.getKey() == e.RETURN) && f.isValid()) {
                      this.doInsertHR();
                    } else {
                      f.getEl().frame();
                    }
                  },
                  scope: this
                }
              }]
            }],
            buttons: [{
              text: 'Insert',
              handler: function handler() {
                var frm = this.hrWindow.getComponent('insert-hr').getForm();

                if (frm.isValid()) {
                  this.doInsertHR();
                } else {
                  frm.findField('hrwidth').getEl().frame();
                }
              },
              scope: this
            }, {
              text: 'Cancel',
              handler: function handler() {
                this.hrWindow.hide();
              },
              scope: this
            }]
          });
        } else {
          this.hrWindow.getEl().frame();
        }

        this.hrWindow.show();
      },
      scope: this,
      tooltip: {
        title: 'Insert Horizontal Rule'
      },
      overflowText: 'Horizontal Rule'
    });
  },
  // private
  doInsertHR: function doInsertHR() {
    var frm = this.hrWindow.getComponent('insert-hr').getForm();

    if (frm.isValid()) {
      var hrwidth = frm.findField('hrwidth').getValue();

      if (hrwidth) {
        this.insertHR(hrwidth);
      } else {
        this.insertHR('100%');
      }

      frm.reset();
      this.hrWindow.hide();
    }
  },

  /**
   * Insert a horizontal rule into the document.
   * @param w String The width of the horizontal rule as the <tt>width</tt> attribute of the HR tag expects. ie: '100%' or '400' (pixels).
   */
  insertHR: function insertHR(w) {
    this.cmp.insertAtCursor('<hr width="' + w + '">');
  }
});
Ext.ux.form.HtmlEditor.PlainText = Ext.extend(Ext.util.Observable, {
  // private
  cmd: 'plain',
  // private
  init: function init(cmp) {
    this.cmp = cmp;
    this.cmp.on('render', this.onRender, this);
  },
  // private
  onRender: function onRender() {
    var cmp = this.cmp;
    this.cmp.getToolbar().addFill();
    var btn = this.cmp.getToolbar().addButton({
      iconCls: 'x-edit-toggleFormat',
      handler: function handler() {
        this.cmp.fireEvent('toggleFormat', 'text/plain');
      },
      tooltip: {
        title: i18n._('Convert to pure text')
      },
      scope: this
    });
  }
});

/***/ }),
/* 1248 */
/***/ (function(module, exports) {

Ext.ns('Ext.ux.form');
/**
 * make a combo box recent aware
 *  => present recents on empty query
 * 
 */

Ext.ux.form.ComboBoxRecentsPlugin = function (config) {
  Ext.apply(this, config);
};

Ext.ux.form.ComboBoxRecentsPlugin.prototype = {
  recordClass: null,
  domain: 'all',
  init: function init(cmp) {
    this.cmp = cmp;
    this.recentsManager = new Tine.Tinebase.RecentsManager({
      recordClass: this.recordClass,
      domain: this.domain
    }); // @TODO have a interface idea for 'other'
    //        this.cmp.doQuery = this.cmp.doQuery.createInterceptor(this.onBeforeQuery, this);

    this.cmp.on('select', this.onSelect, this);
  },

  /**
   * fill store with recents for empty query
   * @param {String} q
   */
  onBeforeQuery: function onBeforeQuery(q) {
    if (!q) {
      var store = this.cmp.store,
          recents = this.recentsManager.getRecentRecords();

      if (recents) {
        var other = {};
        other[recordType.getMeta('idProperty')] = 'other';
        other[recordType.getMeta('titleProperty')] = String.format(i18n._('choose other {0}...'), recordType.getRecordsName());
        recents.push(new recordClass(other));
        this.cmp.store.loadRecords(recents, {
          add: false
        }, true);
        return false;
      }
    }
  },
  onSelect: function onSelect(cmp, record, index) {
    if (record && Ext.isFunction(record.get)) {
      this.recentsManager.addRecentRecord(record, this.domain);
    }
  },
  getStateId: function getStateId(model, domain) {
    return [model.getMeta('appName'), model.getMeta('modelName'), domain, 'recents'].join('-').toLowerCase();
  }
};
Ext.preg('Ext.ux.form.ComboBoxRecentsPlugin', Ext.ux.form.ComboBoxRecentsPlugin);

/***/ }),
/* 1249 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.layout');
/**
 * @namespace   Ext.ux.layout
 * @class       Ext.ux.layout.HorizontalFitLayout
 * @extends     Ext.layout.ContainerLayout
 * @description
 * <p>This is a base class for layouts that contain a single item that automatically expands horizontally to fill 
 * the horizontal dimenson of the layout's container.  This class is intended to be extended or created via the 
 * layout:'hfit' {@link Ext.Container#layout} config, and should generally not need to be created directly via 
 * the new keyword.</p>
 * <p>To fit a panel to a container horizontally using Horizontal FitLayout, simply set layout:'hfit' on the container 
 * and add a multiple panel to it.</p>
 * <p>Example usage:</p>
 * <pre><code>
var p = new Ext.Panel({
    title: 'Horizontal Fit Layout',
    layout:'hfit',
    items: [{
        title: 'Inner Panel One',
        html: '&lt;p&gt;This is the firsts inner panel content&lt;/p&gt;',
        border: false
    },{
        title: 'Inner Panel Two',
        html: '&lt;p&gt;This is the seconds inner panel content&lt;/p&gt;',
        border: false
    }]
});
</code></pre>
 */

Ext.ux.layout.HorizontalFitLayout = Ext.extend(Ext.layout.ContainerLayout, {
  /**
   * @cfg {bool} containsScrollbar
   */
  containsScrollbar: false,

  /**
   * @private
   */
  monitorResize: true,

  /**
   * @private
   */
  onLayout: function onLayout(ct, target) {
    Ext.layout.FitLayout.superclass.onLayout.call(this, ct, target);

    if (!this.container.collapsed) {
      var size = target.getStyleSize();
      size.width = ct.getContentTarget().isScrollable() ? size.width - Ext.getScrollBarWidth() : size.width;
      ct.items.each(function (item) {
        this.setItemSize(item, size);
      }, this);
    }
  },

  /**
   * @private
   */
  setItemSize: function setItemSize(item, size) {
    if (item && size.height > 0) {
      // display none?
      item.setWidth(size.width);
    }
  }
});
Ext.Container.LAYOUTS['hfit'] = Ext.ux.layout.HorizontalFitLayout;

/***/ }),
/* 1250 */
/***/ (function(module, exports) {

/*
 * Ext JS Library 2.2
 * Copyright(c) 2006-2008, Ext JS, LLC.
 * licensing@extjs.com
 * 
 * http://extjs.com/license
 */
Ext.ns('Ext.ux.layout');
/**
 * @namespace   Ext.ux.layout
 * @class       Ext.ux.layout.CenterLayout
 * @extends     Ext.layout.FitLayout
 * 
 * <p>This is a very simple layout style used to center contents within a container.  This layout works within
 * nested containers and can also be used as expected as a Viewport layout to center the page layout.</p>
 * <p>As a subclass of FitLayout, CenterLayout expects to have a single child panel of the container that uses 
 * the layout.  The layout does not require any config options, although the child panel contained within the
 * layout must provide a fixed or percentage width.  The child panel's height will fit to the container by
 * default, but you can specify <tt>autoHeight:true</tt> to allow it to autosize based on its content height.  
 * Example usage:</p> 
 * <pre><code>
// The content panel is centered in the container
var p = new Ext.Panel({
    title: 'Center Layout',
    layout: 'ux.center',
    items: [{
        title: 'Centered Content',
        width: '75%',
        html: 'Some content'
    }]
});

// If you leave the title blank and specify no border
// you'll create a non-visual, structural panel just
// for centering the contents in the main container.
var p = new Ext.Panel({
    layout: 'ux.center',
    border: false,
    items: [{
        title: 'Centered Content',
        width: 300,
        autoHeight: true,
        html: 'Some content'
    }]
});
</code></pre>
 */

Ext.ux.layout.CenterLayout = Ext.extend(Ext.layout.FitLayout, {
  // private
  setItemSize: function setItemSize(item, size) {
    this.container.addClass('ux-layout-center');
    item.addClass('ux-layout-center-item');

    if (item && size.height > 0) {
      if (item.width) {
        size.width = item.width;
      }

      item.setSize(size);
    }
  }
});
Ext.Container.LAYOUTS['ux.center'] = Ext.ux.layout.CenterLayout;

/***/ }),
/* 1251 */
/***/ (function(module, exports) {

/*
 * Ext JS Library 3.0.0
 * Copyright(c) 2006-2009 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
// We are adding these custom layouts to a namespace that does not
// exist by default in Ext, so we have to add the namespace first:
Ext.ns('Ext.ux.layout');
/**
 * @namespace   Ext.ux.layout
 * @class       Ext.ux.layout.RowLayout
 * @extends     Ext.layout.ContainerLayout
 * 
 * <p>This is the layout style of choice for creating structural layouts in a multi-row format where the height of
 * each row can be specified as a percentage or fixed height.  Row widths can also be fixed, percentage or auto.
 * This class is intended to be extended or created via the layout:'ux.row' {@link Ext.Container#layout} config,
 * and should generally not need to be created directly via the new keyword.</p>
 * <p>RowLayout does not have any direct config options (other than inherited ones), but it does support a
 * specific config property of <b><tt>rowHeight</tt></b> that can be included in the config of any panel added to it.  The
 * layout will use the rowHeight (if present) or height of each panel during layout to determine how to size each panel.
 * If height or rowHeight is not specified for a given panel, its height will default to the panel's height (or auto).</p>
 * <p>The height property is always evaluated as pixels, and must be a number greater than or equal to 1.
 * The rowHeight property is always evaluated as a percentage, and must be a decimal value greater than 0 and
 * less than 1 (e.g., .25).</p>
 * <p>The basic rules for specifying row heights are pretty simple.  The logic makes two passes through the
 * set of contained panels.  During the first layout pass, all panels that either have a fixed height or none
 * specified (auto) are skipped, but their heights are subtracted from the overall container height.  During the second
 * pass, all panels with rowHeights are assigned pixel heights in proportion to their percentages based on
 * the total <b>remaining</b> container height.  In other words, percentage height panels are designed to fill the space
 * left over by all the fixed-height and/or auto-height panels.  Because of this, while you can specify any number of rows
 * with different percentages, the rowHeights must always add up to 1 (or 100%) when added together, otherwise your
 * layout may not render as expected.  Example usage:</p>
 * <pre><code>
// All rows are percentages -- they must add up to 1
var p = new Ext.Panel({
    title: 'Row Layout - Percentage Only',
    layout:'ux.row',
    items: [{
        title: 'Row 1',
        rowHeight: .25
    },{
        title: 'Row 2',
        rowHeight: .6
    },{
        title: 'Row 3',
        rowHeight: .15
    }]
});

// Mix of height and rowHeight -- all rowHeight values must add
// up to 1. The first row will take up exactly 120px, and the last two
// rows will fill the remaining container height.
var p = new Ext.Panel({
    title: 'Row Layout - Mixed',
    layout:'ux.row',
    items: [{
        title: 'Row 1',
        height: 120,
        // standard panel widths are still supported too:
        width: '50%' // or 200
    },{
        title: 'Row 2',
        rowHeight: .8,
        width: 300
    },{
        title: 'Row 3',
        rowHeight: .2
    }]
});
</code></pre>
 */

Ext.ux.layout.RowLayout = Ext.extend(Ext.layout.ContainerLayout, {
  // private
  monitorResize: true,
  // private
  isValidParent: function isValidParent(c, target) {
    return c.getEl().dom.parentNode == this.innerCt.dom;
  },
  // private
  onLayout: function onLayout(ct, target) {
    var rs = ct.items.items,
        len = rs.length,
        r,
        i;

    if (!this.innerCt) {
      target.addClass('ux-row-layout-ct');
      this.innerCt = target.createChild({
        cls: 'x-row-inner'
      });
    }

    this.renderAll(ct, this.innerCt);
    var size = target.getViewSize();

    if (size.width < 1 && size.height < 1) {
      // display none?
      return;
    }

    var h = size.height - target.getPadding('tb'),
        ph = h;
    this.innerCt.setSize({
      height: h
    }); // some rows can be percentages while others are fixed
    // so we need to make 2 passes

    for (i = 0; i < len; i++) {
      r = rs[i];

      if (!r.rowHeight) {
        ph -= r.getSize().height + r.getEl().getMargins('tb');
      }
    }

    ph = ph < 0 ? 0 : ph;

    for (i = 0; i < len; i++) {
      r = rs[i];

      if (r.rowHeight) {
        r.setSize({
          height: Math.floor(r.rowHeight * ph) - r.getEl().getMargins('tb')
        });
      }
    }
  }
  /**
   * @property activeItem
   * @hide
   */

});
Ext.Container.LAYOUTS['ux.row'] = Ext.ux.layout.RowLayout;

/***/ }),
/* 1252 */
/***/ (function(module, exports) {

Ext.ns('Ext.ux.layout.CardLayout');
Ext.ux.layout.CardLayout.helper = {
  /**
   * remove all items which should not be keeped -> don't have a keep flag
   *
   * @param {Ext.Panel} cardPanel
   */
  cleanupCardPanelItems: function cleanupCardPanelItems(cardPanel) {
    if (cardPanel.items) {
      for (var i = 0, p; i < cardPanel.items.length; i++) {
        p = cardPanel.items.get(i);

        if (!p.keep) {
          cardPanel.remove(p);
        }
      }
    }
  },

  /**
   * add or set given item
   *
   * @param {Ext.Panel} cardPanel
   * @param {Ext.Panel} item
   */
  setActiveCardPanelItem: function setActiveCardPanelItem(cardPanel, item, keep) {
    // auto cleanup
    item.keep = !!keep;
    Ext.ux.layout.CardLayout.helper.cleanupCardPanelItems(cardPanel);

    if (cardPanel.items.indexOf(item) < 0) {
      cardPanel.add(item);
    }

    if (Ext.isFunction(cardPanel.layout.setActiveItem)) {
      cardPanel.layout.setActiveItem(item.id);
    } else {
      cardPanel.activeItem = cardPanel.items.indexOf(item);
    }

    cardPanel.doLayout();
  }
};

/***/ }),
/* 1253 */
/***/ (function(module, exports) {

/*
 * backport from Extjs 4.x  Ext.layout.container.Accordion
 */
Ext.ns('Ext.ux', 'Ext.ux.layout');

Ext.ux.layout.MultiAccordionLayout = function (config) {
  var me = this;
  Ext.ux.layout.MultiAccordionLayout.superclass.constructor(arguments);

  if (me.animate) {
    me.animatePolicy = Ext.apply({}, me.defaultAnimatePolicy);
  } else {
    me.animatePolicy = null;
  }
};

Ext.extend(Ext.ux.layout.MultiAccordionLayout, Ext.layout.VBoxLayout, {
  align: 'stretch',

  /**
   * @cfg {Boolean} fill
   * True to adjust the active item's height to fill the available space in the container, false to use the
   * item's current height, or auto height if not explicitly set.
   */
  fill: true,

  /**
   * @cfg {Boolean} autoWidth
   * Child Panels have their width actively managed to fit within the accordion's width.
   * @removed This config is ignored in ExtJS 4
   */

  /**
   * @cfg {Boolean} titleCollapse
   * True to allow expand/collapse of each contained panel by clicking anywhere on the title bar, false to allow
   * expand/collapse only when the toggle tool button is clicked.  When set to false,
   * {@link #hideCollapseTool} should be false also.
   */
  titleCollapse: true,

  /**
   * @cfg {Boolean} hideCollapseTool
   * True to hide the contained Panels' collapse/expand toggle buttons, false to display them.
   * When set to true, {@link #titleCollapse} is automatically set to true.
   */
  hideCollapseTool: false,

  /**
   * @cfg {Boolean} collapseFirst
   * True to make sure the collapse/expand toggle button always renders first (to the left of) any other tools
   * in the contained Panels' title bars, false to render it last. By default, this will use the
   * {@link Ext.panel.Panel#collapseFirst} setting on the panel. If the config option is specified on the layout,
   * it will override the panel value.
   */
  collapseFirst: undefined,

  /**
   * @cfg {Boolean} animate
   * True to slide the contained panels open and closed during expand/collapse using animation, false to open and
   * close directly with no animation. Note: The layout performs animated collapsing
   * and expanding, *not* the child Panels.
   */
  animate: true,

  /**
   * @cfg {Boolean} activeOnTop
   * Only valid when {@link #multi} is `false` and {@link #animate} is `false`.
   *
   * True to swap the position of each panel as it is expanded so that it becomes the first item in the container,
   * false to keep the panels in the rendered order.
   */
  activeOnTop: false,

  /**
   * @cfg {Boolean} multi
   * Set to true to enable multiple accordion items to be open at once.
   */
  multi: true,
  defaultAnimatePolicy: {
    y: true,
    height: true
  },
  // private
  onLayout: function onLayout(ct, target) {
    var items = ct.items.items;
    this.beforeRenderItems(items);
    this.container.on('afterlayout', this.updatePanelClasses, this);
    Ext.ux.layout.MultiAccordionLayout.superclass.onLayout.apply(this, arguments);
  },
  beforeRenderItems: function beforeRenderItems(items) {
    var me = this,
        ln = items.length,
        i = 0,
        owner = me.container.ownerCt,
        collapseFirst = me.collapseFirst,
        hasCollapseFirst = Ext.isDefined(collapseFirst),
        expandedItem,
        comp;

    for (; i < ln; i++) {
      comp = items[i];

      if (!comp.rendered) {
        // Set up initial properties for Panels in an accordion.
        if (hasCollapseFirst) {
          comp.collapseFirst = collapseFirst;
        }

        if (me.hideCollapseTool) {
          comp.hideCollapseTool = me.hideCollapseTool;
          comp.titleCollapse = true;
        } else if (me.titleCollapse) {
          comp.titleCollapse = me.titleCollapse;
        }

        delete comp.hideHeader;
        delete comp.width;
        comp.collapsible = true;
        comp.title = comp.title || '&#160;'; // comp.addBodyCls('x-accordion-body');
        // If only one child Panel is allowed to be expanded
        // then collapse all except the first one found with collapsed:false
        // If we have hasExpanded set, we've already done this

        if (!me.multi && !me.hasExpanded) {
          // If there is an expanded item, all others must be rendered collapsed.
          if (me.expandedItem !== undefined) {
            comp.collapsed = true;
          } // Otherwise expand the first item with collapsed explicitly configured as false
          else if (comp.hasOwnProperty('collapsed') && comp.collapsed === false) {
              me.expandedItem = i;
            } else {
              comp.collapsed = true;
            } // If only one child Panel may be expanded, then intercept expand/show requests.


          owner.mon(comp, {
            show: me.onComponentShow,
            beforeexpand: me.onComponentExpand,
            scope: me
          });
        } // If we must fill available space, a collapse must be listened for and a sibling must
        // be expanded.


        if (me.fill) {
          owner.mon(comp, {
            beforecollapse: me.onComponentCollapse,
            beforeexpand: me.onComponentExpand,
            expand: me.layout,
            collapse: me.layout,
            scope: me
          });
        }
      }
    } // If no collapsed:false Panels found, make the first one expanded.


    expandedItem = me.expandedItem;

    if (!me.hasExpanded) {
      if (expandedItem === undefined) {
        if (ln) {
          items[0].collapsed = false;
        }
      } else if (me.activeOnTop) {
        expandedItem = items[expandedItem];
        expandedItem.collapsed = false;
        me.configureItem(expandedItem);
        owner.insert(0, expandedItem);
      }

      me.hasExpanded = true;
    }
  },
  configureItem: function configureItem(item) {
    Ext.ux.layout.MultiAccordionLayout.superclass.configureItem.apply(this, arguments); // We handle animations for the expand/collapse of items.
    // Items do not have individual borders

    item.animCollapse = item.border = false; // If filling available space, all Panels flex.

    if (this.fill) {
      item.flex = 1;
    }
  },
  onChildPanelRender: function onChildPanelRender(panel) {
    panel.header.addClass('x-accordion-hd');
  },
  updatePanelClasses: function updatePanelClasses(ct) {
    var children = ct.items.items,
        ln = children.length,
        siblingCollapsed = true,
        i,
        child,
        header;

    for (i = 0; i < ln; i++) {
      child = children[i];
      header = child.header;
      header.addClass('x-accordion-hd');

      if (siblingCollapsed) {
        header.removeClass('x-accordion-hd-sibling-expanded');
      } else {
        header.addClass('x-accordion-hd-sibling-expanded');
      }

      if (i + 1 == ln && child.collapsed) {
        header.addClass('x-accordion-hd-last-collapsed');
      } else {
        header.removeClass('x-accordion-hd-last-collapsed');
      }

      siblingCollapsed = child.collapsed;
    }
  },
  // When a Component expands, adjust the heights of the other Components to be just enough to accommodate
  // their headers.
  // The expanded Component receives the only flex value, and so gets all remaining space.
  onComponentExpand: function onComponentExpand(toExpand) {
    var me = this,
        owner = me.container.ownerCt,
        multi = me.multi,
        animate = me.animate,
        moveToTop = !multi && !me.animate && me.activeOnTop,
        expanded,
        expandedCount,
        i,
        previousValue;
    toExpand.flex = 1;

    if (!me.processing) {
      me.processing = true;
      previousValue = owner.deferLayout;
      owner.deferLayout = true;
      expanded = multi ? [] : expanded = toExpand.ownerCt.items.filterBy(function (item) {
        return !item.collapsed;
      }).items;
      expandedCount = expanded.length; // Collapse all other expanded child items (Won't loop if multi is true)

      for (i = 0; i < expandedCount; i++) {
        expanded[i].collapse();
      }

      if (moveToTop) {
        // Prevent extra layout when moving the item
        Ext.suspendLayouts();
        owner.insert(0, toExpand);
        Ext.resumeLayouts();
      }

      owner.deferLayout = previousValue;
      me.processing = false;
    }
  },
  onComponentCollapse: function onComponentCollapse(comp) {
    var me = this,
        owner = me.container.ownerCt,
        toExpand,
        expanded,
        previousValue;

    if (owner.items.getCount() === 1) {
      // do not allow collapse if there is only one item
      return false;
    }

    comp.flex = false;

    if (!me.processing) {
      me.processing = true;
      previousValue = owner.deferLayout;
      owner.deferLayout = true;
      toExpand = comp.ownerCt.items.itemAt(comp.ownerCt.items.indexOf(comp) + 1) || comp.ownerCt.items.itemAt(comp.ownerCt.items.indexOf(comp) - 1); // If we are allowing multi, and the "toCollapse" component is NOT the only expanded Component,
      // then ask the box layout to collapse it to its header.

      if (me.multi) {
        expanded = comp.ownerCt.items.filterBy(function (item) {
          return !item.collapsed;
        }).items; // If the collapsing Panel is the only expanded one, expand the following Component.
        // All this is handling fill: true, so there must be at least one expanded,

        if (expanded.length === 1) {
          if (!toExpand) {
            me.processing = false;
            return false;
          }

          toExpand.expand();
        }
      } else if (toExpand) {
        toExpand.expand();
      }

      owner.deferLayout = previousValue;
      me.processing = false;
    }
  },
  onComponentShow: function onComponentShow(comp) {
    // Showing a Component means that you want to see it, so expand it.
    this.onComponentExpand(comp);
  }
});
Ext.Container.LAYOUTS['ux.multiaccordion'] = Ext.ux.layout.MultiAccordionLayout;

/***/ }),
/* 1254 */
/***/ (function(module, exports) {

/**
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     BSD
 * @author      Shea Frederick
 * @copyright   Copyright (c) 2008 Shea Frederick
 *
 * based on public domain code from Shea Frederick
 * "Free as a bird. Use it anywhere or any way you like."
 * 
 * http://extjs.com/blog/2008/07/01/integrating-google-maps-api-with-extjs/
 */
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.GMapPanel
 * @extends     Ext.Panel
 */

Ext.ux.GMapPanel = Ext.extend(Ext.Panel, {
  initComponent: function initComponent() {
    var defConfig = {
      plain: true,
      zoomLevel: 3,
      yaw: 180,
      pitch: 0,
      zoom: 0,
      gmapType: 'map',
      border: false
    };
    Ext.applyIf(this, defConfig);
    Ext.ux.GMapPanel.superclass.initComponent.call(this);
  },
  afterRender: function afterRender() {
    var wh = this.ownerCt.getSize();
    Ext.applyIf(this, wh);
    Ext.ux.GMapPanel.superclass.afterRender.call(this);

    if (this.gmapType === 'map') {
      this.gmap = new GMap2(this.body.dom);
    }

    if (this.gmapType === 'panorama') {
      this.gmap = new GStreetviewPanorama(this.body.dom);
    }

    if (typeof this.addControl === 'object' && this.gmapType === 'map') {
      this.gmap.addControl(this.addControl);
    }

    if (typeof this.setCenter === 'object') {
      if (typeof this.setCenter.geoCodeAddr === 'string') {
        this.geoCodeLookup(this.setCenter.geoCodeAddr);
      } else {
        if (this.gmapType === 'map') {
          var point = new GLatLng(this.setCenter.lat, this.setCenter['long']);
          this.gmap.setCenter(point, this.zoomLevel);
        }

        if (typeof this.setCenter.marker === 'object' && typeof point === 'object') {
          this.addMarker(point, this.setCenter.marker, this.setCenter.marker.clear);
        }
      }

      if (this.gmapType === 'panorama') {
        this.gmap.setLocationAndPOV(new GLatLng(this.setCenter.lat, this.setCenter['long']), {
          yaw: this.yaw,
          pitch: this.pitch,
          zoom: this.zoom
        });
      }
    }

    var dt = new Ext.util.DelayedTask();
    dt.delay(300, function () {
      this.addMarkers(this.markers);
    }, this);
  },
  onResize: function onResize(w, h) {
    if (typeof this.gmap == 'object') {
      this.gmap.checkResize();
    }

    Ext.ux.GMapPanel.superclass.onResize.call(this, w, h);
  },
  setSize: function setSize(width, height, animate) {
    if (typeof this.gmap == 'object') {
      this.gmap.checkResize();
    }

    Ext.ux.GMapPanel.superclass.setSize.call(this, width, height, animate);
  },
  getMap: function getMap() {
    return this.gmap;
  },
  addMarkers: function addMarkers(markers) {
    if (Ext.isArray(markers)) {
      for (var i = 0; i < markers.length; i++) {
        var mkr_point = new GLatLng(markers[i].lat, markers[i]['long']);
        this.addMarker(mkr_point, markers[i].marker, false, markers[i].setCenter);
      }
    }
  },
  addMarker: function addMarker(point, marker, clear, center) {
    Ext.applyIf(marker, G_DEFAULT_ICON);

    if (clear === true) {
      this.gmap.clearOverlays();
    }

    if (center === true) {
      this.gmap.setCenter(point, this.zoomLevel);
    }

    var mark = new GMarker(point, marker);
    this.gmap.addOverlay(mark);
  },
  geoCodeLookup: function geoCodeLookup(addr) {
    this.geocoder = new GClientGeocoder();
    this.geocoder.getLocations(addr, this.addAddressToMap.createDelegate(this));
  },
  addAddressToMap: function addAddressToMap(response) {
    if (!response || response.Status.code != 200) {
      Ext.MessageBox.alert('Error', 'Code ' + response.Status.code + ' Error Returned');
    } else {
      place = response.Placemark[0];
      addressinfo = place.AddressDetails;
      accuracy = addressinfo.Accuracy;

      if (accuracy === 0) {
        Ext.MessageBox.alert('Unable to Locate Address', 'Unable to Locate the Address you provided');
      } else {
        if (accuracy < 7) {
          Ext.MessageBox.alert('Address Accuracy', 'The address provided has a low accuracy.<br><br>Level ' + accuracy + ' Accuracy (8 = Exact Match, 1 = Vague Match)');
        } else {
          point = new GLatLng(place.Point.coordinates[1], place.Point.coordinates[0]);

          if (typeof this.setCenter.marker === 'object' && typeof point === 'object') {
            this.addMarker(point, this.setCenter.marker, this.setCenter.marker.clear, true);
          }
        }
      }
    }
  }
});
Ext.reg('gmappanel', Ext.ux.GMapPanel);

/***/ }),
/* 1255 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux', 'Ext.ux.tree');
/**
 * @namespace   Ext.ux.tree
 * @class       Ext.ux.tree.CheckboxSelectionModel
 * @extends     Ext.util.Observable
 * 
 * Checkbox multi selection for a TreePanel.
 */

Ext.ux.tree.CheckboxSelectionModel = function (config) {
  this.addEvents(
  /**
   * @event beforeselect
   * Fires before the selected node changes, return false to cancel the change
   * @param {DefaultSelectionModel} this
   * @param {TreeNode} node the node to select
   */
  "beforeselect",
  /**
   * @event selectionchange
   * Fires when the selected nodes change
   * @param {MultiSelectionModel} this
   * @param {Array} nodes Array of the selected nodes
   */
  "selectionchange");
  Ext.apply(this, config);
  Ext.ux.tree.CheckboxSelectionModel.superclass.constructor.call(this);
};

Ext.extend(Ext.ux.tree.CheckboxSelectionModel, Ext.util.Observable, {
  /**
   * @cfg {Bool} activateLeafNodesOnly
   * true to only activate leaf nodes
   */
  activateLeafNodesOnly: false,

  /**
   * @cfg {bool} optimizeSelection
   * true to optimize selection
   */
  optimizeSelection: false,

  /**
   * @type Ext.tree.TreeNode
   * currently active node
   */
  activeNode: null,

  /**
   * @cfg {Boolean} defaultValue
   * default check value
   */
  defaultValue: false,

  /**
   * activate given node
   * 
   * @param {Ext.tree.TreeNode} node
   * @return {Boolean}
   */
  activate: function activate(node) {
    if (!node) {
      return;
    }

    if (this.activateLeafNodesOnly && !node.isLeaf()) {
      return false;
    }

    if (this.activeNode) {
      this.activeNode.ui.onSelectedChange(false);
    }

    this.activeNode = node;
    node.ui.onSelectedChange(true);
  },

  /**
   * Clear all selections
   */
  clearSelections: function clearSelections(suppressEvent) {
    this.suspendEvents(false);
    var sn = this.tree.getChecked();

    if (sn.length > 0) {
      for (var i = 0, len = sn.length; i < len; i++) {
        sn[i].ui.toggleCheck(false);
      }
    }

    this.resumeEvents();
  },

  /**
   * get active node
   * @return {Ext.tree.TreeNode}
   */
  getActiveNode: function getActiveNode() {
    return this.activeNode;
  },

  /**
   * Returns an array of the selected nodes
   * @return {Array}
   */
  getSelectedNodes: function getSelectedNodes() {
    return this.tree.getChecked();
  },
  init: function init(tree) {
    this.tree = tree;
    tree.getTreeEl().on("keydown", this.onKeyDown, this);
    tree.on("click", this.onNodeClick, this);
    tree.on("beforeappend", this.onBeforeAppend, this);
    tree.on("checkchange", this.onCheckChange, this);
  },

  /**
   * Returns true if the node is selected
   * @param {Ext.tree.TreeNode} node The node to check
   * @return {Boolean}
   */
  isSelected: function isSelected(node) {
    if (node && node.ui) {
      return node.ui.isChecked();
    }
  },
  onBeforeAppend: function onBeforeAppend(tree, parent, node) {
    node.attributes.checked = this.defaultValue;
  },
  onCheckChange: function onCheckChange(node, checked) {
    if (checked) {
      this.activate(node);

      if (this.optimizeSelection) {
        this.optimize(node);
      }
    } else {}

    this.fireEvent("selectionchange", this, this.tree.getChecked());
  },
  onNodeClick: function onNodeClick(node) {
    this.select(node);
    this.activate(node);
  },

  /**
   * Select a node.
   * @param {Ext.tree.TreeNode} node The node to select
   * @return {Text.tree.TreeNode} The selected node
   */
  select: function select(node, e, keepExisting) {
    if (!node.ui.isChecked() && this.fireEvent('beforeselect', this, node) !== false) {
      node.ui.toggleCheck(true);
    }

    return node;
  },

  /**
   * Deselect a node.
   * @param {Ext.tree.TreeNode} node The node to unselect
   */
  unselect: function unselect(node) {
    node.ui.toggleCheck(false);
  },

  /**
   * optimizes the selection
   */
  optimize: function optimize(node) {
    this.suspendEvents();
    this.unselectChildNodes(node); // recursivly unselect parent nodes

    while (node = node.parentNode) {
      if (this.isSelected(node)) {
        node.unselect();
      }
    }

    this.resumeEvents();
  },

  /**
   * unselect child nodes of given node
   * 
   * @param {Ext.tree.TreeNode} node
   */
  unselectChildNodes: function unselectChildNodes(node) {
    if (node.isExpandable() && node.isExpanded()) {
      for (var i = 0; i < node.childNodes.length; i++) {
        if (node.childNodes[i].isExpandable()) {
          this.unselectChildNodes(node.childNodes[i]);
        }

        node.childNodes[i].unselect();
      }
    }
  },
  onKeyDown: Ext.tree.DefaultSelectionModel.prototype.onKeyDown,
  selectNext: Ext.tree.DefaultSelectionModel.prototype.selectNext,
  selectPrevious: Ext.tree.DefaultSelectionModel.prototype.selectPrevious
});

/***/ }),
/* 1256 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ns('Ext.ux.tree');
/**
 * @class Ext.ux.tree.TreeGridSorter
 * @extends Ext.tree.TreeSorter
 * Provides sorting of nodes in a {@link Ext.ux.tree.TreeGrid}.  The TreeGridSorter automatically monitors events on the
 * associated TreeGrid that might affect the tree's sort order (beforechildrenrendered, append, insert and textchange).
 * Example usage:<br />
 * <pre><code>
 new Ext.ux.tree.TreeGridSorter(myTreeGrid, {
     folderSort: true,
     dir: "desc",
     sortType: function(node) {
         // sort by a custom, typed attribute:
         return parseInt(node.id, 10);
     }
 });
 </code></pre>
 * @constructor
 * @param {TreeGrid} tree
 * @param {Object} config
 */

Ext.ux.tree.TreeGridSorter = Ext.extend(Ext.tree.TreeSorter, {
  /**
   * @cfg {Array} sortClasses The CSS classes applied to a header when it is sorted. (defaults to <tt>['sort-asc', 'sort-desc']</tt>)
   */
  sortClasses: ['sort-asc', 'sort-desc'],

  /**
   * @cfg {String} sortAscText The text displayed in the 'Sort Ascending' menu item (defaults to <tt>'Sort Ascending'</tt>)
   */
  sortAscText: 'Sort Ascending',

  /**
   * @cfg {String} sortDescText The text displayed in the 'Sort Descending' menu item (defaults to <tt>'Sort Descending'</tt>)
   */
  sortDescText: 'Sort Descending',
  constructor: function constructor(tree, config) {
    if (!Ext.isObject(config)) {
      config = {
        property: tree.columns[0].dataIndex || 'text',
        folderSort: true
      };
    }

    Ext.ux.tree.TreeGridSorter.superclass.constructor.apply(this, arguments);
    this.tree = tree;
    tree.on('headerclick', this.onHeaderClick, this);
    tree.ddAppendOnly = true;
    me = this;

    this.defaultSortFn = function (n1, n2) {
      var dsc = me.dir && me.dir.toLowerCase() == 'desc';
      var p = me.property || 'text';
      var sortType = me.sortType;
      var fs = me.folderSort;
      var cs = me.caseSensitive === true;
      var leafAttr = me.leafAttr || 'leaf';

      if (fs) {
        if (n1.attributes[leafAttr] && !n2.attributes[leafAttr]) {
          return 1;
        }

        if (!n1.attributes[leafAttr] && n2.attributes[leafAttr]) {
          return -1;
        }
      }

      var v1 = sortType ? sortType(n1) : cs ? n1.attributes[p] : n1.attributes[p].toUpperCase();
      var v2 = sortType ? sortType(n2) : cs ? n2.attributes[p] : n2.attributes[p].toUpperCase();

      if (v1 < v2) {
        return dsc ? +1 : -1;
      } else if (v1 > v2) {
        return dsc ? -1 : +1;
      } else {
        return 0;
      }
    };

    tree.on('afterrender', this.onAfterTreeRender, this, {
      single: true
    });
    tree.on('headermenuclick', this.onHeaderMenuClick, this);
  },
  onAfterTreeRender: function onAfterTreeRender() {
    if (this.tree.hmenu) {
      this.tree.hmenu.insert(0, {
        itemId: 'asc',
        text: this.sortAscText,
        cls: 'xg-hmenu-sort-asc'
      }, {
        itemId: 'desc',
        text: this.sortDescText,
        cls: 'xg-hmenu-sort-desc'
      });
    }

    this.updateSortIcon(0, 'asc');
  },
  onHeaderMenuClick: function onHeaderMenuClick(c, id, index) {
    if (id === 'asc' || id === 'desc') {
      this.onHeaderClick(c, null, index);
      return false;
    }
  },
  onHeaderClick: function onHeaderClick(c, el, i) {
    if (c && !this.tree.headersDisabled) {
      var me = this;
      me.property = c.dataIndex;
      me.dir = c.dir = c.dir === 'desc' ? 'asc' : 'desc';
      me.sortType = c.sortType;
      me.caseSensitive === Ext.isBoolean(c.caseSensitive) ? c.caseSensitive : this.caseSensitive;
      me.sortFn = c.sortFn || this.defaultSortFn;
      this.tree.root.cascade(function (n) {
        if (!n.isLeaf()) {
          me.updateSort(me.tree, n);
        }
      });
      this.updateSortIcon(i, c.dir);
    }
  },
  // private
  updateSortIcon: function updateSortIcon(col, dir) {
    var sc = this.sortClasses;
    var hds = this.tree.innerHd.select('td').removeClass(sc);
    hds.item(col).addClass(sc[dir == 'desc' ? 1 : 0]);
  }
});

/***/ }),
/* 1257 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.tree.ColumnResizer
 * @extends Ext.util.Observable
 */
Ext.tree.ColumnResizer = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Number} minWidth The minimum width the column can be dragged to.
   * Defaults to <tt>14</tt>.
   */
  minWidth: 14,
  constructor: function constructor(config) {
    Ext.apply(this, config);
    Ext.tree.ColumnResizer.superclass.constructor.call(this);
  },
  init: function init(tree) {
    this.tree = tree;
    tree.on('render', this.initEvents, this);
  },
  initEvents: function initEvents(tree) {
    tree.mon(tree.innerHd, 'mousemove', this.handleHdMove, this);
    this.tracker = new Ext.dd.DragTracker({
      onBeforeStart: this.onBeforeStart.createDelegate(this),
      onStart: this.onStart.createDelegate(this),
      onDrag: this.onDrag.createDelegate(this),
      onEnd: this.onEnd.createDelegate(this),
      tolerance: 3,
      autoStart: 300
    });
    this.tracker.initEl(tree.innerHd);
    tree.on('beforedestroy', this.tracker.destroy, this.tracker);
  },
  handleHdMove: function handleHdMove(e, t) {
    var hw = 5,
        x = e.getPageX(),
        hd = e.getTarget('.x-treegrid-hd', 3, true);

    if (hd) {
      var r = hd.getRegion(),
          ss = hd.dom.style,
          pn = hd.dom.parentNode;

      if (x - r.left <= hw && hd.dom !== pn.firstChild) {
        var ps = hd.dom.previousSibling;

        while (ps && Ext.fly(ps).hasClass('x-treegrid-hd-hidden')) {
          ps = ps.previousSibling;
        }

        if (ps) {
          this.activeHd = Ext.get(ps);
          ss.cursor = Ext.isWebKit ? 'e-resize' : 'col-resize';
        }
      } else if (r.right - x <= hw) {
        var ns = hd.dom;

        while (ns && Ext.fly(ns).hasClass('x-treegrid-hd-hidden')) {
          ns = ns.previousSibling;
        }

        if (ns) {
          this.activeHd = Ext.get(ns);
          ss.cursor = Ext.isWebKit ? 'w-resize' : 'col-resize';
        }
      } else {
        delete this.activeHd;
        ss.cursor = '';
      }
    }
  },
  onBeforeStart: function onBeforeStart(e) {
    this.dragHd = this.activeHd;
    return !!this.dragHd;
  },
  onStart: function onStart(e) {
    this.tree.headersDisabled = true;
    this.proxy = this.tree.body.createChild({
      cls: 'x-treegrid-resizer'
    });
    this.proxy.setHeight(this.tree.body.getHeight());
    var x = this.tracker.getXY()[0];
    this.hdX = this.dragHd.getX();
    this.hdIndex = this.tree.findHeaderIndex(this.dragHd);
    this.proxy.setX(this.hdX);
    this.proxy.setWidth(x - this.hdX);
    this.maxWidth = this.tree.outerCt.getWidth() - this.tree.innerBody.translatePoints(this.hdX).left;
  },
  onDrag: function onDrag(e) {
    var cursorX = this.tracker.getXY()[0];
    this.proxy.setWidth((cursorX - this.hdX).constrain(this.minWidth, this.maxWidth));
  },
  onEnd: function onEnd(e) {
    var nw = this.proxy.getWidth(),
        tree = this.tree;
    this.proxy.remove();
    delete this.dragHd;
    tree.columns[this.hdIndex].width = nw;
    tree.updateColumnWidths();
    setTimeout(function () {
      tree.headersDisabled = false;
    }, 100);
  }
});

/***/ }),
/* 1258 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ux.tree.TreeGridNodeUI
 * @extends Ext.tree.TreeNodeUI
 */
Ext.ux.tree.TreeGridNodeUI = Ext.extend(Ext.tree.TreeNodeUI, {
  isTreeGridNodeUI: true,
  renderElements: function renderElements(n, a, targetNode, bulkRender) {
    var t = n.getOwnerTree(),
        cols = t.columns,
        c = cols[0],
        i,
        buf,
        len;
    this.indentMarkup = n.parentNode ? n.parentNode.ui.getChildIndent() : '';
    buf = ['<tbody class="x-tree-node">', '<tr ext:tree-node-id="', n.id, '" class="x-tree-node-el x-tree-node-leaf ', a.cls, '">', '<td class="x-treegrid-col">', '<span class="x-tree-node-indent">', this.indentMarkup, "</span>", '<img src="', this.emptyIcon, '" class="x-tree-ec-icon x-tree-elbow">', '<img src="', a.icon || this.emptyIcon, '" class="x-tree-node-icon', a.icon ? " x-tree-node-inline-icon" : "", a.iconCls ? " " + a.iconCls : "", '" unselectable="on">', '<a hidefocus="on" class="x-tree-node-anchor" href="', a.href ? a.href : '#', '" tabIndex="1" ', a.hrefTarget ? ' target="' + a.hrefTarget + '"' : '', '>', '<span unselectable="on">', c.tpl ? c.tpl.apply(a) : a[c.dataIndex] || c.text, '</span></a>', '</td>'];

    for (i = 1, len = cols.length; i < len; i++) {
      c = cols[i];
      buf.push('<td class="x-treegrid-col ', c.cls ? c.cls : '', '">', '<div unselectable="on" class="x-treegrid-text"', c.align ? ' style="text-align: ' + c.align + ';"' : '', '>', c.tpl ? c.tpl.apply(a) : a[c.dataIndex], '</div>', '</td>');
    }

    buf.push('</tr><tr class="x-tree-node-ct"><td colspan="', cols.length, '">', '<table class="x-treegrid-node-ct-table" cellpadding="0" cellspacing="0" style="table-layout: fixed; display: none; width: ', t.innerCt.getWidth(), 'px;"><colgroup>');

    for (i = 0, len = cols.length; i < len; i++) {
      buf.push('<col style="width: ', cols[i].hidden ? 0 : cols[i].width, 'px;" />');
    }

    buf.push('</colgroup></table></td></tr></tbody>');

    if (bulkRender !== true && n.nextSibling && n.nextSibling.ui.getEl()) {
      this.wrap = Ext.DomHelper.insertHtml("beforeBegin", n.nextSibling.ui.getEl(), buf.join(''));
    } else {
      this.wrap = Ext.DomHelper.insertHtml("beforeEnd", targetNode, buf.join(''));
    }

    this.elNode = this.wrap.childNodes[0];
    this.ctNode = this.wrap.childNodes[1].firstChild.firstChild;
    var cs = this.elNode.firstChild.childNodes;
    this.indentNode = cs[0];
    this.ecNode = cs[1];
    this.iconNode = cs[2];
    this.anchor = cs[3];
    this.textNode = cs[3].firstChild;
  },
  // private
  animExpand: function animExpand(cb) {
    this.ctNode.style.display = "";
    Ext.ux.tree.TreeGridNodeUI.superclass.animExpand.call(this, cb);
  }
});
Ext.ux.tree.TreeGridRootNodeUI = Ext.extend(Ext.tree.TreeNodeUI, {
  isTreeGridNodeUI: true,
  // private
  render: function render() {
    if (!this.rendered) {
      this.wrap = this.ctNode = this.node.ownerTree.innerCt.dom;
      this.node.expanded = true;
    }

    if (Ext.isWebKit) {
      // weird table-layout: fixed issue in webkit
      var ct = this.ctNode;
      ct.style.tableLayout = null;
      (function () {
        ct.style.tableLayout = 'fixed';
      }).defer(1);
    }
  },
  destroy: function destroy() {
    if (this.elNode) {
      Ext.dd.Registry.unregister(this.elNode.id);
    }

    delete this.node;
  },
  collapse: Ext.emptyFn,
  expand: Ext.emptyFn
});

/***/ }),
/* 1259 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ux.tree.TreeGridLoader
 * @extends Ext.tree.TreeLoader
 */
Ext.ux.tree.TreeGridLoader = Ext.extend(Ext.tree.TreeLoader, {
  createNode: function createNode(attr) {
    if (!attr.uiProvider) {
      attr.uiProvider = Ext.ux.tree.TreeGridNodeUI;
    }

    return Ext.tree.TreeLoader.prototype.createNode.call(this, attr);
  }
});

/***/ }),
/* 1260 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
(function () {
  Ext.override(Ext.list.Column, {
    init: function init() {
      if (!this.type) {
        this.type = "auto";
      }

      var st = Ext.data.SortTypes; // named sortTypes are supported, here we look them up

      if (typeof this.sortType == "string") {
        this.sortType = st[this.sortType];
      } // set default sortType for strings and dates


      if (!this.sortType) {
        switch (this.type) {
          case "string":
            this.sortType = st.asUCString;
            break;

          case "date":
            this.sortType = st.asDate;
            break;

          default:
            this.sortType = st.none;
        }
      }
    }
  });
  Ext.tree.Column = Ext.extend(Ext.list.Column, {});
  Ext.tree.NumberColumn = Ext.extend(Ext.list.NumberColumn, {});
  Ext.tree.DateColumn = Ext.extend(Ext.list.DateColumn, {});
  Ext.tree.BooleanColumn = Ext.extend(Ext.list.BooleanColumn, {});
  Ext.reg('tgcolumn', Ext.tree.Column);
  Ext.reg('tgnumbercolumn', Ext.tree.NumberColumn);
  Ext.reg('tgdatecolumn', Ext.tree.DateColumn);
  Ext.reg('tgbooleancolumn', Ext.tree.BooleanColumn);
})();

/***/ }),
/* 1261 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */

/**
 * @class Ext.ux.tree.TreeGrid
 * @extends Ext.tree.TreePanel
 * 
 * @xtype treegrid
 */
Ext.ux.tree.TreeGrid = Ext.extend(Ext.tree.TreePanel, {
  rootVisible: false,
  useArrows: true,
  lines: false,
  borderWidth: Ext.isBorderBox ? 0 : 2,
  // the combined left/right border for each cell
  cls: 'x-treegrid',
  columnResize: true,
  enableSort: true,
  reserveScrollOffset: true,
  enableHdMenu: true,
  columnsText: 'Columns',
  initComponent: function initComponent() {
    if (!this.root) {
      this.root = new Ext.tree.AsyncTreeNode({
        text: 'Root'
      });
    } // initialize the loader


    var l = this.loader;

    if (!l) {
      l = new Ext.ux.tree.TreeGridLoader({
        dataUrl: this.dataUrl,
        requestMethod: this.requestMethod,
        store: this.store
      });
    } else if (Ext.isObject(l) && !l.load) {
      l = new Ext.ux.tree.TreeGridLoader(l);
    } else if (l) {
      l.createNode = function (attr) {
        if (!attr.uiProvider) {
          attr.uiProvider = Ext.ux.tree.TreeGridNodeUI;
        }

        return Ext.tree.TreeLoader.prototype.createNode.call(this, attr);
      };
    }

    this.loader = l;
    Ext.ux.tree.TreeGrid.superclass.initComponent.call(this);
    this.initColumns();

    if (this.enableSort) {
      this.treeGridSorter = new Ext.ux.tree.TreeGridSorter(this, this.enableSort);
    }

    if (this.columnResize) {
      this.colResizer = new Ext.tree.ColumnResizer(this.columnResize);
      this.colResizer.init(this);
    }

    var c = this.columns;

    if (!this.internalTpl) {
      this.internalTpl = new Ext.XTemplate('<div class="x-grid3-header">', '<div class="x-treegrid-header-inner">', '<div class="x-grid3-header-offset">', '<table cellspacing="0" cellpadding="0" border="0"><colgroup><tpl for="columns"><col /></tpl></colgroup>', '<thead><tr class="x-grid3-hd-row">', '<tpl for="columns">', '<td class="x-grid3-hd x-grid3-cell x-treegrid-hd" style="text-align: {align};" id="', this.id, '-xlhd-{#}">', '<div class="x-grid3-hd-inner x-treegrid-hd-inner" unselectable="on">', this.enableHdMenu ? '<a class="x-grid3-hd-btn" href="#"></a>' : '', '{header}<img class="x-grid3-sort-icon" src="', Ext.BLANK_IMAGE_URL, '" />', '</div>', '</td></tpl>', '</tr></thead>', '</div></table>', '</div></div>', '</div>', '<div class="x-treegrid-root-node">', '<table class="x-treegrid-root-table" cellpadding="0" cellspacing="0" style="table-layout: fixed;"></table>', '</div>');
    }

    if (!this.colgroupTpl) {
      this.colgroupTpl = new Ext.XTemplate('<colgroup><tpl for="columns"><col style="width: {width}px"/></tpl></colgroup>');
    }
  },
  initColumns: function initColumns() {
    var cs = this.columns,
        len = cs.length,
        columns = [],
        i,
        c;

    for (i = 0; i < len; i++) {
      c = cs[i];

      if (!c.isColumn) {
        c.xtype = c.xtype ? /^tg/.test(c.xtype) ? c.xtype : 'tg' + c.xtype : 'tgcolumn';
        c = Ext.create(c);
      }

      c.init(this);
      columns.push(c);

      if (this.enableSort !== false && c.sortable !== false) {
        c.sortable = true;
        this.enableSort = true;
      }
    }

    this.columns = columns;
  },
  onRender: function onRender() {
    Ext.tree.TreePanel.superclass.onRender.apply(this, arguments);
    this.el.addClass('x-treegrid');
    this.outerCt = this.body.createChild({
      cls: 'x-tree-root-ct x-treegrid-ct ' + (this.useArrows ? 'x-tree-arrows' : this.lines ? 'x-tree-lines' : 'x-tree-no-lines')
    });
    this.internalTpl.overwrite(this.outerCt, {
      columns: this.columns
    });
    this.mainHd = Ext.get(this.outerCt.dom.firstChild);
    this.innerHd = Ext.get(this.mainHd.dom.firstChild);
    this.innerBody = Ext.get(this.outerCt.dom.lastChild);
    this.innerCt = Ext.get(this.innerBody.dom.firstChild);
    this.colgroupTpl.insertFirst(this.innerCt, {
      columns: this.columns
    });

    if (this.hideHeaders) {
      this.header.dom.style.display = 'none';
    } else if (this.enableHdMenu !== false) {
      this.hmenu = new Ext.menu.Menu({
        id: this.id + '-hctx'
      });

      if (this.enableColumnHide !== false) {
        this.colMenu = new Ext.menu.Menu({
          id: this.id + '-hcols-menu'
        });
        this.colMenu.on({
          scope: this,
          beforeshow: this.beforeColMenuShow,
          itemclick: this.handleHdMenuClick
        });
        this.hmenu.add({
          itemId: 'columns',
          hideOnClick: false,
          text: this.columnsText,
          menu: this.colMenu,
          iconCls: 'x-cols-icon'
        });
      }

      this.hmenu.on('itemclick', this.handleHdMenuClick, this);
    }
  },
  setRootNode: function setRootNode(node) {
    node.attributes.uiProvider = Ext.ux.tree.TreeGridRootNodeUI;
    node = Ext.ux.tree.TreeGrid.superclass.setRootNode.call(this, node);

    if (this.innerCt) {
      this.colgroupTpl.insertFirst(this.innerCt, {
        columns: this.columns
      });
    }

    return node;
  },
  clearInnerCt: function clearInnerCt() {
    if (Ext.isIE) {
      var dom = this.innerCt.dom;

      while (dom.firstChild) {
        dom.removeChild(dom.firstChild);
      }
    } else {
      Ext.ux.tree.TreeGrid.superclass.clearInnerCt.call(this);
    }
  },
  initEvents: function initEvents() {
    Ext.ux.tree.TreeGrid.superclass.initEvents.apply(this, arguments);
    this.mon(this.innerBody, 'scroll', this.syncScroll, this);
    this.mon(this.innerHd, 'click', this.handleHdDown, this);
    this.mon(this.mainHd, {
      scope: this,
      mouseover: this.handleHdOver,
      mouseout: this.handleHdOut
    });
  },
  onResize: function onResize(w, h) {
    Ext.ux.tree.TreeGrid.superclass.onResize.apply(this, arguments);
    var bd = this.innerBody.dom;
    var hd = this.innerHd.dom;

    if (!bd) {
      return;
    }

    if (Ext.isNumber(h)) {
      bd.style.height = this.body.getHeight(true) - hd.offsetHeight + 'px';
    }

    if (Ext.isNumber(w)) {
      var sw = Ext.num(this.scrollOffset, Ext.getScrollBarWidth());

      if (this.reserveScrollOffset || bd.offsetWidth - bd.clientWidth > 10) {
        this.setScrollOffset(sw);
      } else {
        var me = this;
        setTimeout(function () {
          me.setScrollOffset(bd.offsetWidth - bd.clientWidth > 10 ? sw : 0);
        }, 10);
      }
    }
  },
  updateColumnWidths: function updateColumnWidths() {
    var cols = this.columns,
        colCount = cols.length,
        groups = this.outerCt.query('colgroup'),
        groupCount = groups.length,
        c,
        g,
        i,
        j;

    for (i = 0; i < colCount; i++) {
      c = cols[i];

      for (j = 0; j < groupCount; j++) {
        g = groups[j];
        g.childNodes[i].style.width = (c.hidden ? 0 : c.width) + 'px';
      }
    }

    for (i = 0, groups = this.innerHd.query('td'), len = groups.length; i < len; i++) {
      c = Ext.fly(groups[i]);

      if (cols[i] && cols[i].hidden) {
        c.addClass('x-treegrid-hd-hidden');
      } else {
        c.removeClass('x-treegrid-hd-hidden');
      }
    }

    var tcw = this.getTotalColumnWidth();
    Ext.fly(this.innerHd.dom.firstChild).setWidth(tcw + (this.scrollOffset || 0));
    this.outerCt.select('table').setWidth(tcw);
    this.syncHeaderScroll();
  },
  getVisibleColumns: function getVisibleColumns() {
    var columns = [],
        cs = this.columns,
        len = cs.length,
        i;

    for (i = 0; i < len; i++) {
      if (!cs[i].hidden) {
        columns.push(cs[i]);
      }
    }

    return columns;
  },
  getTotalColumnWidth: function getTotalColumnWidth() {
    var total = 0;

    for (var i = 0, cs = this.getVisibleColumns(), len = cs.length; i < len; i++) {
      total += cs[i].width;
    }

    return total;
  },
  setScrollOffset: function setScrollOffset(scrollOffset) {
    this.scrollOffset = scrollOffset;
    this.updateColumnWidths();
  },
  // private
  handleHdDown: function handleHdDown(e, t) {
    var hd = e.getTarget('.x-treegrid-hd');

    if (hd && Ext.fly(t).hasClass('x-grid3-hd-btn')) {
      var ms = this.hmenu.items,
          cs = this.columns,
          index = this.findHeaderIndex(hd),
          c = cs[index],
          sort = c.sortable;
      e.stopEvent();
      Ext.fly(hd).addClass('x-grid3-hd-menu-open');
      this.hdCtxIndex = index;
      this.fireEvent('headerbuttonclick', ms, c, hd, index);
      this.hmenu.on('hide', function () {
        Ext.fly(hd).removeClass('x-grid3-hd-menu-open');
      }, this, {
        single: true
      });
      this.hmenu.show(t, 'tl-bl?');
    } else if (hd) {
      var index = this.findHeaderIndex(hd);
      this.fireEvent('headerclick', this.columns[index], hd, index);
    }
  },
  // private
  handleHdOver: function handleHdOver(e, t) {
    var hd = e.getTarget('.x-treegrid-hd');

    if (hd && !this.headersDisabled) {
      index = this.findHeaderIndex(hd);
      this.activeHdRef = t;
      this.activeHdIndex = index;
      var el = Ext.get(hd);
      this.activeHdRegion = el.getRegion();
      el.addClass('x-grid3-hd-over');
      this.activeHdBtn = el.child('.x-grid3-hd-btn');

      if (this.activeHdBtn) {
        this.activeHdBtn.dom.style.height = hd.firstChild.offsetHeight - 1 + 'px';
      }
    }
  },
  // private
  handleHdOut: function handleHdOut(e, t) {
    var hd = e.getTarget('.x-treegrid-hd');

    if (hd && (!Ext.isIE || !e.within(hd, true))) {
      this.activeHdRef = null;
      Ext.fly(hd).removeClass('x-grid3-hd-over');
      hd.style.cursor = '';
    }
  },
  findHeaderIndex: function findHeaderIndex(hd) {
    hd = hd.dom || hd;
    var cs = hd.parentNode.childNodes;

    for (var i = 0, c; c = cs[i]; i++) {
      if (c == hd) {
        return i;
      }
    }

    return -1;
  },
  // private
  beforeColMenuShow: function beforeColMenuShow() {
    var cols = this.columns,
        colCount = cols.length,
        i,
        c;
    this.colMenu.removeAll();

    for (i = 1; i < colCount; i++) {
      c = cols[i];

      if (c.hideable !== false) {
        this.colMenu.add(new Ext.menu.CheckItem({
          itemId: 'col-' + i,
          text: c.header,
          checked: !c.hidden,
          hideOnClick: false,
          disabled: c.hideable === false
        }));
      }
    }
  },
  // private
  handleHdMenuClick: function handleHdMenuClick(item) {
    var index = this.hdCtxIndex,
        id = item.getItemId();

    if (this.fireEvent('headermenuclick', this.columns[index], id, index) !== false) {
      index = id.substr(4);

      if (index > 0 && this.columns[index]) {
        this.setColumnVisible(index, !item.checked);
      }
    }

    return true;
  },
  setColumnVisible: function setColumnVisible(index, visible) {
    this.columns[index].hidden = !visible;
    this.updateColumnWidths();
  },

  /**
   * Scrolls the grid to the top
   */
  scrollToTop: function scrollToTop() {
    this.innerBody.dom.scrollTop = 0;
    this.innerBody.dom.scrollLeft = 0;
  },
  // private
  syncScroll: function syncScroll() {
    this.syncHeaderScroll();
    var mb = this.innerBody.dom;
    this.fireEvent('bodyscroll', mb.scrollLeft, mb.scrollTop);
  },
  // private
  syncHeaderScroll: function syncHeaderScroll() {
    var mb = this.innerBody.dom;
    this.innerHd.dom.scrollLeft = mb.scrollLeft;
    this.innerHd.dom.scrollLeft = mb.scrollLeft; // second time for IE (1/2 time first fails, other browsers ignore)
  },
  registerNode: function registerNode(n) {
    Ext.ux.tree.TreeGrid.superclass.registerNode.call(this, n);

    if (!n.uiProvider && !n.isRoot && !n.ui.isTreeGridNodeUI) {
      n.ui = new Ext.ux.tree.TreeGridNodeUI(n);
    }
  }
});
Ext.reg('treegrid', Ext.ux.tree.TreeGrid);

/***/ }),
/* 1262 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.display');
/**
 * @class       Ext.ux.display.DisplayPanel
 * @namespace   Ext.ux.display
 * @extends     Ext.form.FormPanel
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * <b>Panel for displaying information on record basis.</b>
 */

Ext.ux.display.DisplayPanel = Ext.extend(Ext.Panel, {
  /*
   * private
   */
  cls: 'x-ux-display',
  layout: 'ux.display',

  /**
   * holds all display fields of the panel
   * 
   * @type {Ext.util.MixedCollection}
   */
  fields: null,

  /**
   * initializes the component, builds this.fields, calls parent
   */
  initComponent: function initComponent() {
    Ext.ux.display.DisplayPanel.superclass.initComponent.call(this);
    this.fields = new Ext.util.MixedCollection();
    this.fields.addAll(this.findBy(function (c) {
      return Ext.isFunction(c.setValue);
    }));
  },

  /**
   * fills this fields with the corresponding record data
   * 
   * @param {Tine.Tinebase.data.Record} record
   */
  loadRecord: function loadRecord(record) {
    this.fields.each(function (field) {
      var data = record.get(field.name) ? record.get(field.name) : '';
      field.setValue(data, record);
    });
  }
});
Ext.reg('ux.displaypanel', Ext.ux.display.DisplayPanel);

/***/ }),
/* 1263 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.display');
/**
 * @class       Ext.ux.display.DisplayField
 * @namespace   Ext.ux.display
 * @extends     Ext.form.DisplayField
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * <b>Field for displaying information in a displaypanel</b>
 */

Ext.ux.display.DisplayField = Ext.extend(Ext.form.DisplayField, {
  htmlEncode: true,
  nl2br: false,
  linkify: false,
  // don't enumerate as form field
  markInvalid: null,
  renderer: function renderer(v) {
    return v;
  },
  // try to apply grid compatible renderer
  applyRenderer: function applyRenderer(v) {
    var parentWithRecord = this.findParentBy(function (c) {
      return !!c.record;
    }),
        metadata = {
      css: {},
      attr: {}
    },
        record = parentWithRecord ? parentWithRecord.record : null,
        store = record ? record.store : null;
    return this.renderer(v, metadata, record, 0, 0, store);
  },
  setRawValue: function setRawValue(value) {
    var v = this.applyRenderer(value);

    if (String(v) == '[object Object]') {
      v = '...';
      this.hide();
    }

    if (this.htmlEncode) {
      v = Ext.util.Format.htmlEncode(v);
    }

    if (this.nl2br) {
      v = Ext.util.Format.nl2br(v);
    }

    if (this.linkify) {
      Tine.Tinebase.common.linkifyText(v, this.getEl());
    }

    return this.rendered ? this.el.dom.innerHTML = Ext.isEmpty(v) ? '' : v : this.value = v;
  }
});
Ext.reg('ux.displayfield', Ext.ux.display.DisplayField);

/***/ }),
/* 1264 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/**
 * @class Ext.ux.display.DisplayTextArea
 * @namespace Ext.ux.display
 * @extends Ext.Container
 * @author Cornelius Weiss <c.weiss@metaways.de>
 *
 * Textarea for displaying a text in a displaypanel
 */
Ext.ux.display.DisplayTextArea = Ext.extend(Ext.Container, {
  type: 'text/plain',
  htmlEncode: true,
  nl2br: true,
  linkify: true,
  autoScroll: true,
  layout: 'fit',
  cls: 'x-ux-display-textarea',
  initComponent: function initComponent() {
    this.supr().initComponent.call(this);
    var langMatches = String(this.type).match(/^code\/(.*)/);
    this.lang = langMatches ? langMatches[1] : undefined;

    if (this.type == 'text/plain' && this.renderer === Ext.ux.display.DisplayField.prototype.renderer) {
      this.htmlEncode = true;
      this.nl2br = true;
    } else if (this.lang) {
      this.htmlEncode = false;
      this.nl2br = true;
      this.linkify = false;
    } else {
      // rich content needs to be prepared by the server!
      this.linkify = false;
    }
  },
  renderer: Ext.ux.display.DisplayField.prototype.renderer,
  applyRenderer: Ext.ux.display.DisplayField.prototype.applyRenderer,
  afterRender: function afterRender() {
    var me = this;
    this.supr().afterRender.call(this);

    if (this.value) {
      this.setValue(this.value);
    }

    if (this.lang) {
      __webpack_require__.e(/* import() | Tinebase/js/ace */ 36).then(__webpack_require__.bind(null, 578)).then(function () {
        me.ed = ace.edit(me.el.id, {
          mode: 'ace/mode/' + me.lang,
          fontFamily: 'monospace',
          fontSize: 12
        });
        me.ed.setOptions({
          readOnly: true,
          highlightActiveLine: false,
          highlightGutterLine: false
        });

        if (me.value) {
          me.ed.setValue(me.value);
        }
      });
    }
  },
  setValue: function setValue(value, record) {
    if (value == this.value) {
      return;
    }

    this.value = value;

    if (this.ed) {
      this.ed.setValue(Ext.isString(this.value) ? this.value : JSON.stringify(this.value, undefined, 4), -1);
      return;
    }

    if (!this.rendered) {
      return;
    }

    var v = this.renderer(value, {}, record);

    if (this.htmlEncode) {
      v = Ext.util.Format.htmlEncode(v);
    }

    if (this.nl2br) {
      v = Ext.util.Format.nl2br(v);
    }

    this.getEl().update(v);

    if (this.linkify) {
      Tine.Tinebase.common.linkifyText(v, this.getEl());
    }
  }
});
Ext.reg('ux.displaytextarea', Ext.ux.display.DisplayTextArea);

/***/ }),
/* 1265 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux.layout');
/**
 * @namespace   Ext.ux.layout
 * @class       Ext.ux.layout.DisplayLayout
 * @extends     Ext.layout.FormLayout
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * <b>Layout for displaying information in a displaypanel</b>
 */

Ext.ux.layout.DisplayLayout = Ext.extend(Ext.layout.FormLayout, {
  /**
   * @cfg {String} background
   * one of {solid|border|none}
   */
  background: 'none',
  onLayout: function onLayout(ct, target) {
    Ext.ux.layout.DisplayLayout.superclass.onLayout.apply(this, arguments);
    target.addClass('x-ux-display-background-' + this.background);

    if (this.declaration && !this.declEl) {
      this.declEl = target.createChild({
        dom: 'div',
        html: this.declaration,
        'class': 'x-ux-display-declaration x-ux-display-background-declaration'
      });
    }
  },
  destroy: function destroy() {
    if (this.declEl) {
      this.declEl.remove();
    }

    Ext.ux.layout.DisplayLayout.superclass.destroy.call(this);
  }
});
Ext.Container.LAYOUTS['ux.display'] = Ext.ux.layout.DisplayLayout;

/***/ }),
/* 1266 */
/***/ (function(module, exports) {

Ext.ns('Ext.ux');

Ext.ux.MessageBox = function () {
  var msgCt;

  function createBox(t, s) {
    return ['<div class="x-ux-messagebox-msg">', '<div class="x-box-tl"><div class="x-box-tr"><div class="x-box-tc"></div></div></div>', '<div class="x-box-ml"><div class="x-box-mr"><div class="x-box-mc"><h3>', t, '</h3>', s, '</div></div></div>', '<div class="x-box-bl"><div class="x-box-br"><div class="x-box-bc"></div></div></div>', '</div>'].join('');
  }

  return {
    msg: function msg(title, format) {
      const timeOut = !Number.isNaN(Array.prototype.slice.call(arguments, 2)) ? Array.prototype.slice.call(arguments, 2) : 2;

      if (!msgCt) {
        msgCt = Ext.DomHelper.insertFirst(document.body, {
          id: 'x-ux-messagebox-msg-div'
        }, true);
      }

      msgCt.alignTo(document, 't-t');
      var s = String.format.apply(String, Array.prototype.slice.call(arguments, 1));
      var m = Ext.DomHelper.append(msgCt, {
        html: createBox(title, s)
      }, true);
      m.slideIn('t').pause(timeOut).ghost("t", {
        remove: true
      });
    }
  };
}();

/***/ }),
/* 1267 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.TabPanelSortPlugin
 * 
 * @constructor
 * @param {Object} config Configurations options
 */

Ext.ux.TabPanelSortPlugin = function (config) {
  Ext.apply(this, config);
};

Ext.ux.TabPanelSortPlugin.prototype = {
  /**
   * @cfg {Object} dragZoneConfig
   */
  dragZoneConfig: null,

  /**
   * @cfg {Object} dropZoneConfig
   */
  dropZoneConfig: null,

  /**
   * @cfg {Number} pos
   * position
   */
  pos: null,

  /**
   * @cfg {Bool}
   */
  enableDD: true,

  /**
   * tabpanel
   * @type object
   */
  tabpanel: null,

  /**
   * init this plugin
   * 
   * @param {Ext.Component} cmp
   */
  init: function init(cmp) {
    this.tabpanel = cmp;
    this.tabpanel.addEvents(
    /**
     * @event tabsort
     * Fired when tabs where resorted
     * @param {Ext.TabPanel}
     */
    'tabsort');
    this.tabpanel.on('beforerender', this.onBeforeRender, this);
    this.tabpanel.on('render', this.onRender, this);
  },
  onBeforeRender: function onBeforeRender(tabpanel) {
    tabpanel.items.sort('ASC', function (a, b) {
      var posA = a.pos || 100 + 10 * tabpanel.items.indexOf(a),
          posB = b.pos || 100 + 10 * tabpanel.items.indexOf(b);
      return posA - posB;
    });
  },

  /**
   * onRender define dragZone and dropZone
   * 
   * @param {Ext.TabPanel} tabpanel
   */
  onRender: function onRender(tabpanel) {
    if (this.enableDD) {
      this.dragZone = new Ext.dd.DragZone(tabpanel.header, Ext.apply({
        getDragData: this.getDragData.createDelegate(this),
        getRepairXY: this.getRepairXY.createDelegate(this)
      }, this.dragZoneConfig || {}));
      this.dropZone = new Ext.dd.DropZone(tabpanel.header, Ext.apply({
        onNodeOver: this.onNodeOver.createDelegate(this),
        onNodeDrop: this.onNodeDrop.createDelegate(this),
        getTargetFromEvent: this.getTargetFromEvent.createDelegate(this)
      }, this.dropZoneConfig || {}));
    }
  },

  /**
   * gets static ddel
   * 
   * @return {Ext.Element}
   */
  getDDEl: function getDDEl() {
    if (!this.ddel) {
      this.ddel = Ext.get(document.createElement('div'));
    }

    return this.ddel;
  },

  /**
   * Called when a mousedown occurs in this container. Looks in {@link Ext.dd.Registry}
   * for a valid target to drag based on the mouse down. Override this method
   * to provide your own lookup logic (e.g. finding a child by class name). Make sure your returned
   * object has a "ddel" attribute (with an HTML Element) for other functions to work.
   * @param {EventObject} e The mouse down event
   * @return {Object} The dragData
   */
  getDragData: function getDragData(e) {
    var target = this.tabpanel.findTargets(e);

    if (target.el) {
      this.pos = this.tabpanel.items.indexOf(target.item);
      var ddel = this.getDDEl();
      ddel.update(Ext.DomQuery.selectNode('span[class^=x-tab-strip-text]', target.el).innerHTML);
      return Ext.apply(target, {
        pos: this.pos,
        ddel: ddel.dom,
        repairXY: Ext.fly(target.el).getXY()
      });
    }

    ;
  },

  /**
   * Called while the DropZone determines that a {@link Ext.dd.DragSource} is over a drop node
   * that has either been registered or detected by a configured implementation of {@link #getTargetFromEvent}.
   * The default implementation returns this.dropNotAllowed, so it should be
   * overridden to provide the proper feedback.
   * 
   * @param {Object} nodeData The custom data associated with the drop node (this is the same value returned from
   * {@link #getTargetFromEvent} for this node)
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {String} status The CSS class that communicates the drop status back to the source so that the
   * underlying {@link Ext.dd.StatusProxy} can be updated
   */
  onNodeOver: function onNodeOver(target, dd, e, data) {
    var target = this.tabpanel.findTargets(e);

    if (target.el) {
      this.pos = this.tabpanel.items.indexOf(target.item);
      var box = Ext.fly(target.el).getBox(),
          side = e.getXY()[0] > box.x + box.width / 2 ? 'r' : 'l';

      if (this.pos > data.pos && side === 'l') {
        //                Ext.fly(data.el).insertBefore(target.el);
        this.pos = --this.pos;
      } else if (this.pos < data.pos && side === 'r') {
        //                Ext.fly(data.el).insertAfter(target.el);
        this.pos = ++this.pos;
      }
    } //@TODO: separation line


    return Ext.dd.DropZone.prototype.dropAllowed;
  },

  /**
   * Called when the DropZone determines that a {@link Ext.dd.DragSource} has been dropped onto
   * the drop node.  The default implementation returns false, so it should be overridden to provide the
   * appropriate processing of the drop event and return true so that the drag source's repair action does not run.
   * @param {Object} nodeData The custom data associated with the drop node (this is the same value returned from
   * {@link #getTargetFromEvent} for this node)
   * @param {Ext.dd.DragSource} source The drag source that was dragged over this drop zone
   * @param {Event} e The event
   * @param {Object} data An object containing arbitrary data supplied by the drag source
   * @return {Boolean} True if the drop was valid, else false
   */
  onNodeDrop: function onNodeDrop(target, dd, e, data) {
    if (this.pos == this.tabpanel.items.length - 1) {
      Ext.fly(data.el).insertAfter(this.tabpanel.items.itemAt(this.pos).tabEl);
    } else {
      if (this.tabpanel.items.indexOf(data.item) < this.pos) {
        Ext.fly(data.el).insertBefore(this.tabpanel.items.itemAt(this.pos + 1).tabEl);
      } else {
        Ext.fly(data.el).insertBefore(this.tabpanel.items.itemAt(this.pos).tabEl);
      }
    }

    this.tabpanel.items.remove(data.item);
    this.tabpanel.items.insert(this.pos, data.item);
    this.tabpanel.fireEvent('tabsort', this.tabpanel);
    return true;
  },

  /**
   * Called before a repair of an invalid drop to get the XY to animate to. By default returns
   * the XY of this.dragData.ddel
   * @param {EventObject} e The mouse up event
   * @return {Array} The xy location (e.g. [100, 200])
   */
  getRepairXY: function getRepairXY(e) {
    return this.dragZone.dragData.repairXY;
  },

  /**
   * Returns a custom data object associated with the DOM node that is the target of the event.  By default
   * this looks up the event target in the {@link Ext.dd.Registry}, although you can override this method to
   * provide your own custom lookup.
   * @param {Event} e The event
   * @return {Object} data The custom data
   */
  getTargetFromEvent: function getTargetFromEvent(e) {
    return e.getTarget('ul[class^=x-tab]', 10);
  }
};
Ext.preg('ux.tabpanelsortplugin', Ext.ux.TabPanelSortPlugin);

/***/ }),
/* 1268 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2019 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux');
/**
 * plugin registry for Ext.Component
 *
 * NOTE: a component needs to query this registry for registered plugins! We don't automatically query
 *       this registry for performance reasons.
 */

Ext.ux.pluginRegistry = function () {
  var map = {};
  return {
    /**
     * register plugin
     *
     * @param name
     * @param plugin
     */
    register: function register(name, plugin) {
      if (!map[name]) {
        map[name] = [];
      }

      map[name].push(plugin);
    },

    /**
     * get registered plugins
     *
     * @param name
     * @return {Array}
     */
    get: function get(name) {
      return map[name] || [];
    },

    /**
     * adds registered plugins for given component. helper fn to be called during initComponent in a specific component which
     * want's to use this pluginRegistry
     *
     * @param {Ext.Component} cmp
     * @param {String} name optional, defaults to canonical name
     */
    addRegisteredPlugins: function addRegisteredPlugins(cmp, name) {
      var name = name || Tine.Tinebase.CanonicalPath.getPath(cmp),
          existingPlugins = cmp.plugins || [],
          registeredPlugins = this.get(name);
      cmp.plugins = existingPlugins.concat(registeredPlugins);
      return cmp.plugins;
    }
  };
}();

/***/ }),
/* 1269 */
/***/ (function(module, exports) {

Ext.applyIf(Function.prototype, {
  /**
   * defers execution on a ticket bases. The function gets executed when all registered tickets are back.
   * 
   * @namespace   Function
   * @autor       Cornelius Weiss <c.weiss@metaways.de>
   * @license     BSD, MIT and GPL
   *
   *
  var sayHi = function(name){
  alert('Hi, ' + name);
  }
  var ticketFn = sayHi.deferByTickets(this, ['Fred']);
  // take ticket
  var ticketFn1 = ticketFn();
  var ticketFn2 = ticketFn();
  // give tickets back
  ticketFn1();
  ticketFn2();
    * NOTE: the function gets never executed if not at least one ticket is taken and given back
   *
   * @param {Object} scope (optional) The scope (this reference) in which the function is executed.
   * @param {Array} args (optional) Overrides arguments for the call. (Defaults to the arguments passed by the caller)
   * @param {Boolean/Number} appendArgs (optional) if True args are appended to call args instead of overriding,
   * if a number the args are inserted at the specified position
   * @return {Function} ticketFn
   */
  deferByTickets: function deferByTickets(obj, args, appendArgs) {
    var fn = this.createDelegate(obj, args, appendArgs),
        waitTickets = []; // run if all tickets are back

    var run = function run() {
      if (Ext.isEmpty(waitTickets)) {
        fn();
      }
    };

    return function () {
      var ticket = Ext.id();
      waitTickets.push(ticket); // fn to return wait ticket

      return function () {
        waitTickets.remove(ticket);
        run();
      };
    };
  }
});

/***/ }),
/* 1270 */
/***/ (function(module, exports) {

// Backport from Ext 4.0
Ext.applyIf(Function.prototype, {
  /**
   * <p>Creates a delegate function, optionally with a bound scope which, when called, buffers
   * the execution of the passed function for the configured number of milliseconds.
   * If called again within that period, the impending invocation will be canceled, and the
   * timeout period will begin again.</p>
   *
   * @param {Function} fn The function to invoke on a buffered timer.
   * @param {Number} buffer The number of milliseconds by which to buffer the invocation of the
   * function.
   * @param {Object} scope (optional) The scope (<code><b>this</b></code> reference) in which
   * the passed function is executed. If omitted, defaults to the scope specified by the caller.
   * @param {Array} args (optional) Override arguments for the call. Defaults to the arguments
   * passed by the caller.
   * @return {Function} A function which invokes the passed function after buffering for the specified time.
   */
  createBuffered: function createBuffered(fn, buffer, scope, args) {
    return function () {
      var timerId;
      return function () {
        var me = this,
            argsPassed = arguments;

        if (timerId) {
          clearInterval(timerId);
          timerId = null;
        }

        timerId = setTimeout(function () {
          fn.apply(scope || me, args || argsPassed);
        }, buffer);
      };
    }();
  }
});

/***/ }),
/* 1271 */
/***/ (function(module, exports) {

/**
 * @class GetIt.GridPrinter
 * @author Ed Spencer (edward@domine.co.uk)
 * Class providing a common way of printing Ext.Components. Ext.ux.Printer.print delegates the printing to a specialised
 * renderer class (each of which subclasses Ext.ux.Printer.BaseRenderer), based on the xtype of the component.
 * Each renderer is registered with an xtype, and is used if the component to print has that xtype.
 * 
 * See the files in the renderers directory to customise or to provide your own renderers.
 * 
 * Usage example:
 * 
 * var grid = new Ext.grid.GridPanel({
 *   colModel: //some column model,
 *   store   : //some store
 * });
 * 
 * Ext.ux.Printer.print(grid);
 * 
 */
Ext.ux.Printer = function () {
  return {
    /**
     * @property renderers
     * @type Object
     * An object in the form {xtype: RendererClass} which is manages the renderers registered by xtype
     */
    renderers: {},

    /**
     * Registers a renderer function to handle components of a given xtype
     * @param {String} xtype The component xtype the renderer will handle
     * @param {Function} renderer The renderer to invoke for components of this xtype
     */
    registerRenderer: function registerRenderer(xtype, renderer) {
      this.renderers[xtype] = new renderer();
    },

    /**
     * Returns the registered renderer for a given xtype
     * @param {String} xtype The component xtype to find a renderer for
     * @return {Object/undefined} The renderer instance for this xtype, or null if not found
     */
    getRenderer: function getRenderer(xtype) {
      return this.renderers[xtype];
    },
    findRenderer: function findRenderer(component) {
      var xtypes = component.getXTypes().split('/'),
          renderer = undefined; //iterate backwards over the xtypes of this component, dispatching to the most specific renderer

      for (var i = xtypes.length - 1; i >= 0; i--) {
        var xtype = xtypes[i],
            renderer = this.getRenderer(xtype);

        if (renderer != undefined) {
          break;
        }
      }

      return renderer;
    },

    /**
     * Prints the passed grid. Reflects on the grid's column model to build a table, and fills it using the store
     * @param {Ext.Component} component The component to print
     */
    print: function print(component) {
      var renderer = this.findRenderer(component);

      if (renderer != undefined) {
        renderer.print(component);
      }
    }
  };
}();
/**
 * Override how getXTypes works so that it doesn't require that every single class has
 * an xtype registered for it.
 */


Ext.override(Ext.Component, {
  getXTypes: function getXTypes() {
    var tc = this.constructor;

    if (!tc.xtypes) {
      var c = [],
          sc = this;

      while (sc) {
        //was: while(sc && sc.constructor.xtype) {
        var xtype = sc.constructor.xtype;
        if (xtype != undefined) c.unshift(xtype);
        sc = sc.constructor.superclass;
      }

      tc.xtypeChain = c;
      tc.xtypes = c.join('/');
    }

    return tc.xtypes;
  }
});

/***/ }),
/* 1272 */
/***/ (function(module, exports, __webpack_require__) {

/**
 * @class Ext.ux.Printer.BaseRenderer
 * @extends Object
 * @author Ed Spencer
 * @author Cornelius Weiß
 * Abstract base renderer class. Don't use this directly, use a subclass instead
 */
Ext.ux.Printer.BaseRenderer = Ext.extend(Object, {
  /**
  * @cfg {String} printStrategy window or iframe
  */
  printStrategy: 'iframe',

  /**
   * @property stylesheetPath
   * @type String
   * The path at which the print stylesheet can be found (defaults to 'stylesheets/print.css')
   */
  stylesheetPath: 'stylesheets/print.css',

  /**
  * @cfg {Boolean} useHtml2Canvas
  */
  useHtml2Canvas: false,
  debug: false,
  constructor: function constructor(config) {
    Ext.apply(this, config);
    Ext.ux.Printer.BaseRenderer.superclass.constructor.call(this, config);
  },

  /**
  * template method to intercept when document is ready
  *
  * @param {Document} document
  * @pram {Ext.Component} component
  */
  onBeforePrint: Ext.emptyFn,

  /**
  * Prints the component
  * @param {Ext.Component} component The component to print
  */
  print: function print(component) {
    var mask = new Ext.LoadMask(Ext.getBody(), {
      msg: i18n._("Preparing print, please wait...")
    });
    mask.show();

    if (this.debug) {
      this.printStrategy = 'window';
    }

    return this[this.printStrategy + 'Print'](component).then(function () {
      mask.hide.defer(200, mask);
    }).catch(function (error) {
      mask.hide();
      Ext.Msg.show({
        title: i18n._('Printing Error'),
        msg: error,
        buttons: Ext.Msg.OK,
        icon: Ext.MessageBox.ERROR
      });
    });
  },

  /**
  * Prints the component using the new window strategy
  * @param {Ext.Component} component The component to print
  */
  windowPrint: function windowPrint(component) {
    var name = component && component.getXType ? String.format("print_{0}_{1}", String(component.getXType()).replace(/(\.|-)/g, '_'), component.id.replace(/(\.|-)/g, '_')) : "print";
    var win = window.open('', name);
    var me = this;
    return me.generateHTML(component).then(function (html) {
      win.document.write(html);
      win.document.close(); // gecko looses its document after document.close(). but fortunally waits with printing till css is loaded itself

      me.doPrint(win);
    });
  },

  /**
   * Prints the component using the hidden iframe strategy
   * @param {Ext.Component} component The component to print
   */
  iframePrint: function iframePrint(component) {
    var me = this;
    return me.generateHTML(component).then(function (html) {
      var id = Ext.id(),
          frame = document.createElement('iframe'),
          style = {
        position: 'absolute',
        'background-color': '#FFFFFF',
        width: '210mm',
        height: '297mm',
        top: '-10000px',
        left: '-10000px'
      };

      if (this.debug) {
        Ext.apply(style, {
          top: '0px',
          left: '0px',
          'z-index': 10000000
        });
      }

      Ext.fly(frame).set({
        id: id,
        name: id,
        style: style
      });
      document.body.appendChild(frame);
      Ext.fly(frame).set({
        src: Ext.SSL_SECURE_URL
      });
      var doc = frame.contentWindow.document || frame.contentDocument || WINDOW.frames[id].document;
      doc.open();
      doc.write(html);
      doc.close(); // resize to full height as browser might print only the visible area

      var totalHeight = Ext.fly(doc.body).getHeight();
      Ext.fly(frame).setStyle('height', totalHeight + 'px');
      return me.doPrintOnStylesheetLoad(frame.contentWindow, component);
    });
  },

  /**
   * check if style is loaded and do print afterwards
   *
   * @param {window} win
   */
  doPrintOnStylesheetLoad: function doPrintOnStylesheetLoad(win, component) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      var checkcss = function checkcss(win, component) {
        var el = win.document.getElementById('csscheck'),
            comp = el.currentStyle || getComputedStyle(el, null);

        if (comp.display !== "none") {
          return checkcss.defer(10, me, [win, component]);
        } // give some extra time for logo


        _.delay(fulfill, 500);
      };

      checkcss(win, component);
    }).then(function () {
      me.onBeforePrint(win.document, component);
    }).then(function () {
      return me.doPrint(win);
    });
  },
  doPrint: function doPrint(win) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      if (me.useHtml2Canvas) {
        __webpack_require__.e(/* require.ensure | Tinebase/js/html2canvas */ 42).then((function () {
          var html2canvas = __webpack_require__(391);

          html2canvas(win.document.body, {
            grabMouse: false,
            scale: 300 / 96 // 300 dpi

          }).then(function (canvas) {
            var screenshot = canvas.toDataURL();
            me.useHtml2Canvas = false;
            win.document.body.innerHTML = '<img style="display: block; width: 100%" />';
            win.document.body.firstChild.onload = me.doPrint.createDelegate(me, [win]);
            win.document.body.firstChild.src = screenshot;
            fulfill();
          });
        }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
      } else {
        try {
          if (!win.document.execCommand('print', false, null)) {
            win.print();
          }
        } catch (e) {
          win.print();
        }

        if (!me.debug) {
          win.close();
        }

        fulfill();
      }
    });
  },

  /**
  * Generates the HTML Markup which wraps whatever this.generateBody produces
  * @param {Ext.Component} component The component to generate HTML for
  * @return {String} An HTML fragment to be placed inside the print window
  */
  generateHTML: function generateHTML(component) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      me.prepareData(component).then(function (data) {
        me.generateBody(component, data).then(function (bodyHtml) {
          fulfill(new Ext.XTemplate('<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">', '<html>', '<head> ', '<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />', '<x-additional-headers />', '<link href="' + me.stylesheetPath + '?' + new Date().getTime() + '" rel="stylesheet" type="text/css" media="screen,print" />', '<title>' + me.getTitle(component) + '</title>', '</head>', '<body>', '<div id="csscheck"></div>', bodyHtml, '</body>', '</html>' // NOTE: we need to append additional headers outside xtemplate as the template.compile has problems e.g. with complex css structures
          ).apply(data).replace('<x-additional-headers />', me.getAdditionalHeaders()));
        });
      });
    });
  },

  /**
  * Returns the HTML that will be placed into the <head> element of th print window.
  * @param {Ext.Component} component The component to render
  * @return {String} The HTML fragment to place inside the print window's <head> element
  */
  getAdditionalHeaders: function getAdditionalHeaders(component) {
    return '';
  },

  /**
  * Returns the HTML that will be placed into the print window. This should produce HTML to go inside the
  * <body> element only, as <head> is generated in the print function
  * @param {Ext.Component} component The component to render
  * @param data The data extracted from the component
  * @return {String} The HTML fragment to place inside the print window's <body> element
  */
  generateBody: function generateBody(component, data) {
    return new Promise(function (fulfill, reject) {
      fulfill('');
    });
  },

  /**
  * Prepares data suitable for use in an XTemplate from the component
  * @param {Ext.Component} component The component to acquire data from
  * @return {Array} An empty array (override this to prepare your own data)
  */
  prepareData: function prepareData(component) {
    return new Promise(function (fulfill, reject) {
      fulfill(component);
    });
  },

  /**
  * Returns the title to give to the print window
  * @param {Ext.Component} component The component to be printed
  * @return {String} The window title
  */
  getTitle: function getTitle(component) {
    return typeof component.getTitle == 'function' ? component.getTitle() : component.title || "Printing";
  }
});

/***/ }),
/* 1273 */
/***/ (function(module, exports) {

/**
 * @class Ext.ux.Printer.GridPanelRenderer
 * @extends Ext.ux.Printer.BaseRenderer
 * @author Ed Spencer
 * Helper class to easily print the contents of a grid. Will open a new window with a table where the first row
 * contains the headings from your column model, and with a row for each item in your grid's store. When formatted
 * with appropriate CSS it should look very similar to a default grid. If renderers are specified in your column
 * model, they will be used in creating the table. Override headerTpl and bodyTpl to change how the markup is generated
 */
Ext.ux.Printer.GridPanelRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  headlineTpl: new Ext.XTemplate('<div class="gridpanelrenderer_header_title">', '<h1>{header_title}</h1>', '</div>', '<div class="gridpanelrenderer_header_logo">', '{header_logo}', '</div>', '<div class="clear"></div>'),

  /**
   * Generates the body HTML for the grid
   * @param {Ext.grid.GridPanel} grid The grid to print
   */
  generateBody: function generateBody(grid, data) {
    var me = this; // when called inside other components the outer generateHTML (outer page renderer) didn't prepare data
    // this is the case e.g. inside editDialogs - we don't load remote data then

    data = data || me.extractData(grid, grid.store.data.items);
    return new Promise(function (fulfill, reject) {
      var columns = me.getColumns(grid); //use the headerTpl and bodyTpl XTemplates to create the main XTemplate below

      var headings = me.headerTpl.apply(columns);
      var body = me.bodyTpl.apply(columns);
      var installLogoImg = Tine.Tinebase.common.getUrl('full') && Tine.Tinebase.registry.get('installLogo') ? '<img src="' + Tine.Tinebase.registry.get('installLogo') + '" />' : null;
      var header = me.headlineTpl.apply({
        header_title: Tine.Tinebase.registry.get('brandingTitle'),
        header_logo: installLogoImg
      });

      if (grid.title) {
        header += '<div class="rp-print-single-block-heading">' + grid.title + '</div>';
      }

      fulfill(new Ext.XTemplate(String.format('{0}<table>{1}<tpl for=".">{2}</tpl></table>', header, headings, body)).apply(data));
    });
  },

  /**
   * Prepares data from the grid for use in the XTemplate
   * @param {Ext.grid.GridPanel} grid The grid panel
   * @return {Array} Data suitable for use in the XTemplate
   */
  prepareData: function prepareData(grid) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      //refetch data without paging
      grid.store.on('beforeload', function (store, options) {
        options.params = options.params || {};
        delete options.params.start;
        delete options.params.limit; // @TODO rethink - with local sort we don't need a remote query at all?

        if (!options.params.sort && !grid.store.remoteSort) {
          var sortState = grid.store.getSortState();
          options.params.sort = sortState.field;
          options.params.dir = sortState.direction;
        }
      }, me, {
        'single': true
      });
      grid.store.on('beforeloadrecords', function (o, options, success, store) {
        var data = me.extractData(grid, o.records);
        fulfill(data); // don't touch original store!

        return false;
      }, me, {
        'single': true
      });
      grid.store.load();
    });
  },
  extractData: function extractData(grid, records) {
    var columns = this.getColumns(grid),
        data = [];
    Ext.each(records, function (item) {
      var convertedData = {};
      Ext.each(columns, function (column) {
        var key = column.dataIndex,
            value = item.get(key);
        convertedData[key] = column.renderer ? column.renderer(value, null, item) : value;
        convertedData[key] = convertedData[key] || '';
      });
      data.push(convertedData);
    });
    return data;
  },

  /**
   * Returns the array of columns from a grid
   * @param {Ext.grid.GridPanel} grid The grid to get columns from
   * @return {Array} The array of grid columns
   */
  getColumns: function getColumns(grid) {
    var columns = [];
    Ext.each(grid.getColumnModel().config, function (col) {
      if (col.hidden != true) columns.push(col);
    }, this);
    return columns;
  },

  /**
   * @property headerTpl
   * @type Ext.XTemplate
   * The XTemplate used to create the headings row. By default this just uses <th> elements, override to provide your own
   */
  headerTpl: new Ext.XTemplate('<tr><thead>', '<tpl for=".">', '<th>{header}</th>', '</tpl>', '</thead></tr>'),

  /**
   * @property bodyTpl
   * @type Ext.XTemplate
   * The XTemplate used to create each row. This is used inside the 'print' function to build another XTemplate, to which the data
   * are then applied (see the escaped dataIndex attribute here - this ends up as "{dataIndex}")
   */
  bodyTpl: new Ext.XTemplate('<tr>', '<tpl for=".">', '<td>\{{dataIndex}\}</td>', '</tpl>', '</tr>')
});
Ext.ux.Printer.registerRenderer('grid', Ext.ux.Printer.GridPanelRenderer);

/***/ }),
/* 1274 */
/***/ (function(module, exports) {

/**
 * @class Ext.ux.Printer.ColumnTreeRenderer
 * @extends Ext.ux.Printer.BaseRenderer
 * @author Ed Spencer
 * Helper class to easily print the contents of a column tree
 */
Ext.ux.Printer.ColumnTreeRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  /**
   * Generates the body HTML for the tree
   * @param {Ext.tree.ColumnTree} tree The tree to print
   */
  generateBody: function generateBody(tree) {
    var columns = this.getColumns(tree); //use the headerTpl and bodyTpl XTemplates to create the main XTemplate below

    var headings = this.headerTpl.apply(columns);
    var body = this.bodyTpl.apply(columns);
    return String.format('<table>{0}<tpl for=".">{1}</tpl></table>', headings, body);
  },

  /**
   * Returns the array of columns from a tree
   * @param {Ext.tree.ColumnTree} tree The tree to get columns from
   * @return {Array} The array of tree columns
   */
  getColumns: function getColumns(tree) {
    return tree.columns;
  },

  /**
   * Descends down the tree from the root, creating an array of data suitable for use in an XTemplate
   * @param {Ext.tree.ColumnTree} tree The column tree
   * @return {Array} Data suitable for use in the body XTemplate
   */
  prepareData: function prepareData(tree) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      var root = tree.root,
          data = [],
          cols = this.getColumns(tree),
          padding = me.indentPadding;

      var f = function f(node) {
        if (node.hidden === true || node.isHiddenRoot() === true) return;
        var row = Ext.apply({
          depth: node.getDepth() * padding
        }, node.attributes);
        Ext.iterate(row, function (key, value) {
          Ext.each(cols, function (column) {
            if (column.dataIndex == key) {
              row[key] = column.renderer ? column.renderer(value) : value;
            }
          }, me);
        }); //the property used in the first column is renamed to 'text' in node.attributes, so reassign it here

        row[me.getColumns(tree)[0].dataIndex] = node.attributes.text;
        data.push(row);
      };

      root.cascade(f, me);
      fulfill(data);
    });
  },

  /**
   * @property indentPadding
   * @type Number
   * Number of pixels to indent node by. This is multiplied by the node depth, so a node with node.getDepth() == 3 will
   * be padded by 45 (or 3x your custom indentPadding)
   */
  indentPadding: 15,

  /**
   * @property headerTpl
   * @type Ext.XTemplate
   * The XTemplate used to create the headings row. By default this just uses <th> elements, override to provide your own
   */
  headerTpl: new Ext.XTemplate('<tr>', '<tpl for=".">', '<th width="{width}">{header}</th>', '</tpl>', '</tr>'),

  /**
   * @property bodyTpl
   * @type Ext.XTemplate
   * The XTemplate used to create each row. This is used inside the 'print' function to build another XTemplate, to which the data
   * are then applied (see the escaped dataIndex attribute here - this ends up as "{dataIndex}")
   */
  bodyTpl: new Ext.XTemplate('<tr>', '<tpl for=".">', '<td style="padding-left: {[xindex == 1 ? "\\{depth\\}" : "0"]}px">\{{dataIndex}\}</td>', '</tpl>', '</tr>')
});
Ext.ux.Printer.registerRenderer('columntree', Ext.ux.Printer.ColumnTreeRenderer);

/***/ }),
/* 1275 */
/***/ (function(module, exports) {

Ext.ux.Printer.FieldRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  /**
   * Generates the body HTML for the field
   * @param {Ext.form.Field} field The field to print
   */
  generateBody: function generateBody(field) {
    var label = field.fieldLabel || field.ownerCt.title || '';
    return '' + '<div class="rp-print-single-details-row">' + '<span class="rp-print-single-label">' + label + '</span>' + '<span class="rp-print-single-value">' + field.getRawValue() + '</span>' + '</div>';
  }
});
Ext.ux.Printer.registerRenderer('field', Ext.ux.Printer.FieldRenderer);

/***/ }),
/* 1276 */
/***/ (function(module, exports) {

Ext.ux.Printer.CheckRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  /**
   * Generates the body HTML for the checkbox
   * @param {Ext.form.Field} field The checkbox to print
   */
  generateBody: function generateBody(field) {
    var value = !!+field.getValue() ? window.i18n._('Yes') : window.i18n._('No');
    return '' + '<div class="rp-print-single-details-row">' + '<span class="rp-print-single-label">' + (field.boxLabel || field.fieldLabel) + '</span>' + '<span class="rp-print-single-value">' + value + '</span>' + '</div>';
  }
});
Ext.ux.Printer.registerRenderer('checkbox', Ext.ux.Printer.CheckRenderer);

/***/ }),
/* 1277 */
/***/ (function(module, exports) {

Ext.ux.Printer.ComboRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  /**
   * Generates the body HTML for the combo box
   * @param {Ext.form.Field} field The field to print
   */
  generateBody: function generateBody(field) {
    return '' + '<div class="rp-print-single-details-row">' + '<span class="rp-print-single-label">' + field.fieldLabel + '</span>' + '<span class="rp-print-single-value">' + field.getRawValue() + '</span>' + '</div>';
  }
});
Ext.ux.Printer.registerRenderer('combo', Ext.ux.Printer.ComboRenderer);

/***/ }),
/* 1278 */
/***/ (function(module, exports) {

Ext.ux.Printer.ContainerRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  /**
   * Generates the body HTML for the container
   * @param {Ext.Container} container The container to print
   */
  generateBody: function generateBody(container) {
    var _ = window.lodash;
    return _.reduce(container.items.items, function (promise, cmp) {
      return promise.then(function (html) {
        return new Promise(function (resolve, reject) {
          var renderer = Ext.ux.Printer.findRenderer(cmp),
              result = renderer ? renderer.generateBody(cmp) : '';

          if (_.isString(result)) {
            resolve(html + result);
          } else {
            result.then(function (string) {
              resolve(html + string);
            });
          }
        });
      });
    }, Promise.resolve(''));
  }
});
Ext.ux.Printer.registerRenderer('container', Ext.ux.Printer.ContainerRenderer);

/***/ }),
/* 1279 */
/***/ (function(module, exports) {

Ext.ux.Printer.PanelRenderer = Ext.extend(Ext.ux.Printer.ContainerRenderer, {
  /**
   * Generates the body HTML for the panel
   * @param {Ext.Panel} panel The panel to print
   */
  generateBody: function generateBody(panel) {
    return Ext.ux.Printer.PanelRenderer.superclass.generateBody.call(this, panel).then(function (html) {
      if (panel.header) {
        html = '<div class = "panel-header">' + panel.header + '</div>' + html;
      }

      return html;
    });
  }
});
Ext.ux.Printer.registerRenderer('panel', Ext.ux.Printer.PanelRenderer);

/***/ }),
/* 1280 */
/***/ (function(module, exports) {

Ext.ux.Printer.TagsRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  /**
   * Generates the body HTML for the tagsPanel
   * @param {Tine.widgets.tags.TagPanel} tagsPanel
   */
  generateBody: function generateBody(tagsPanel) {
    var _ = window.lodash;
    return '<div class="cal-print-single-block-heading">' + i18n._('Tags') + '</div>' + '<div class="rp-print-single-block rp-print-single-tags">' + tagsPanel.dataView.el.dom.innerHTML + '</div><br class="x-clear"><br>';
  }
});
Ext.ux.Printer.registerRenderer('Tine.widgets.tags.TagPanel', Ext.ux.Printer.TagsRenderer);

/***/ }),
/* 1281 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Offertory
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux.Printer');
/**
 * Render any EditDialog.
 */

Ext.ux.Printer.EditDialogRenderer = Ext.extend(Ext.ux.Printer.BaseRenderer, {
  stylesheetPath: 'Tinebase/css/widgets/print.css',

  /**
   * @param {Tine.widgets.dialog.EditDialog} editDialog the edit dialog to print
   * @return {Array} Data suitable for use in the XTemplate
   */
  prepareData: function prepareData(editDialog) {
    return new Promise(function (fulfill, reject) {
      var _ = window.lodash; // hack to have all form items rendered

      _.each(editDialog.findByType('tabpanel'), function (tabpanel) {
        var active = tabpanel.getActiveTab();

        _.each(tabpanel.items.items, function (item) {
          tabpanel.setActiveTab(item);
        });

        tabpanel.setActiveTab(active);
      }); // wait for rendering


      (function () {
        var recordData = Ext.util.JSON.decode(Ext.util.JSON.encode(editDialog.record.data));
        editDialog.getForm().items.each(function (field) {
          if ((field instanceof Ext.form.ComboBox || !Ext.isString(recordData[name])) && Ext.isFunction(field.getRawValue)) {
            var name = field.getName(),
                isCustomField = String(name).match(/^customfield_(.*)/),
                string = field.getRawValue();

            if (isCustomField) {
              _.set(recordData, 'customfields.' + isCustomField[1], string);
            } else {
              recordData[name] = string;
            }
          }
        });
        fulfill(recordData);
      }).defer(1000);
    });
  },
  generateBody: function generateBody(editDialog, data) {
    var _ = window.lodash,
        me = this,
        appName = editDialog.recordClass.getMeta('appName');
    data.titleHTML = editDialog.record.getTitle();
    data.customFieldHTML = Tine.widgets.customfields.Renderer.renderAll(appName, editDialog.recordClass, data.customfields); // @TODO render container
    // @TODO render tags, notes, attachments

    return new Promise(function (fulfill, reject) {
      me.generateRecordHTML(editDialog).then(function (recordHTML) {
        data.recordHTML = recordHTML;
        var bodyTpl = new Ext.XTemplate('<div class="rp-print-single">', '    {[Tine.widgets.printer.headerRenderer()]}', '    <div class="rp-print-single-summary">{titleHTML}</div>', '    <table>', '        <tr>', '            <td>', '            </td>', '            <td>', '                <div class="rp-print-single-block">', '                    {values.recordHTML}', '                    <br/>', '                    {values.customFieldHTML}', '                    <br/>', '                    <div class="cal-print-single-block-heading">', window.i18n._('Related to'), '</div>', '                    <div class="rp-print-single-block">', '                        {[this.relationRenderer(values.relations)]}', '                    </div>', '                </div>', '            </td>', '        </tr>', '    </table>', '</div>', {
          relationRenderer: function relationRenderer(values) {
            return Tine.widgets.relation.Renderer.renderAll(values);
          }
        });
        fulfill(bodyTpl.apply(data));
      });
    });
  },

  /**
   * generate html for direct record properties
   *
   *
   * @param editDialog
   * @param {Array} recordComponents Array of components/strings
   * @returns {Promise}
   */
  generateRecordHTML: function generateRecordHTML(editDialog, recordComponents) {
    var _ = window.lodash,
        me = this,
        appName = editDialog.recordClass.getMeta('appName'),
        app = Tine.Tinebase.appMgr.get(appName),
        form = editDialog.recordForm || editDialog.getForm(),
        fields = form.items.items;
    recordComponents = recordComponents || fields;
    return _.reduce(recordComponents || fields, function (promise, cmp) {
      return promise.then(function (html) {
        return new Promise(function (resolve, reject) {
          var renderer = Ext.ux.Printer.findRenderer(_.isString(cmp) ? form.findField(cmp) : cmp),
              result = renderer ? renderer.generateBody(cmp) : '';

          if (_.isString(result)) {
            resolve(html + result);
          } else {
            result.then(function (string) {
              resolve(html + string);
            });
          }
        });
      });
    }, Promise.resolve(''));
  },
  getTitle: function getTitle(editDialog) {
    return editDialog.recordClass.getRecordName() + ': ' + editDialog.record.getTitle();
  }
});

/***/ }),
/* 1282 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.data');
/**
 * central title renderer manager for records
 * 
 * @namespace   Tine.Tinebase.data
 * @class       Tine.Tinebase.data.TitleRendererManager
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @singleton
 */

Tine.Tinebase.data.TitleRendererManager = function () {
  var renderers = {};
  return {
    /**
     * returns renderer for given field
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {gridPanel|displayPanel} optional.
     * @return {Function}
     */
    get: function get(appName, modelName) {
      return renderers[appName + modelName];
    },

    /**
     * register renderer for given field
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {Function} renderer
     * @param {String} category {gridPanel|displayPanel} optional.
     * @param {Object} scope to call renderer in, optional.
     */
    register: function register(appName, modelName, renderer) {
      renderers[appName + modelName] = renderer;
    },

    /**
     * check if a renderer is explicitly registered
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {gridPanel|displayPanel} optional.
     * @return {Boolean}
     */
    has: function has(appName, modelName) {
      // check for registered renderer
      return renderers[appName + modelName] ? true : false;
    }
  };
}();

/***/ }),
/* 1283 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var twingEnv__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(581);
/*
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 */
// @see https://github.com/ericmorand/twing/issues/332
// #if process.env.NODE_ENV !== 'unittest'
 // #endif

Ext.ns('Tine.Tinebase', 'Tine.Tinebase.data');

Tine.Tinebase.data.Record = function (data, id) {
  if (id || id === 0) {
    this.id = id;
  } else if (data[this.idProperty]) {
    this.id = data[this.idProperty];
  } else {
    this.id = ++Ext.data.Record.AUTO_ID;
  }

  this.data = data;
  this.initData();
  this.ctime = new Date().getTime();
};
/**
 * @namespace Tine.Tinebase.data
 * @class     Tine.Tinebase.data.Record
 * @extends   Ext.data.Record
 * 
 * Baseclass of Tine 2.0 models
 */


Ext.extend(Tine.Tinebase.data.Record, Ext.data.Record, {
  /**
   * @cfg {String} appName
   * internal/untranslated app name (required)
   */
  appName: null,

  /**
   * @cfg {String} modelName
   * name of the model/record  (required)
   */
  modelName: null,

  /**
   * @cfg {String} idProperty
   * property of the id of the record
   */
  idProperty: 'id',

  /**
   * @cfg {String} titleProperty
   * property of the title attibute, used in generic getTitle function  (required)
   */
  titleProperty: null,

  /**
   * @cfg {String} recordName
   * untranslated record/item name
   */
  recordName: 'record',

  /**
   * @cfg {String} recordName
   * untranslated records/items (plural) name
   */
  recordsName: 'records',

  /**
   * @cfg {String} grantsPath
   * path (see _.get() to find grants
   */
  grantsPath: null,

  /**
   * @cfg {String} containerProperty
   * name of the container property
   */
  containerProperty: null,

  /**
   * @cfg {String} containerName
   * untranslated container name
   */
  containerName: 'container',

  /**
   * @cfg {string} containerName
   * untranslated name of container (plural)
   */
  containersName: 'containers',

  /**
   * @cfg: {bool} copyNoAppendTitle
   * don't append "(copy)" string to title when record is copied
   */
  copyNoAppendTitle: null,

  /**
   * default filter
   * @type {string}
   */
  defaultFilter: null,
  cfExp: /^#(.+)/,

  /**
   * template fn called when record is instanciated
   */
  initData: Ext.emptyFn,

  /**
   * Get the value of the {@link Ext.data.Field#name named field}.
   * @param {String} name The {@link Ext.data.Field#name name of the field} to get the value of.
   * @return {Object} The value of the field.
   */
  get: function get(name) {
    var cfName = String(name).match(this.cfExp);

    if (cfName) {
      return this.data.customfields ? this.data.customfields[cfName[1]] : null;
    }

    return this.data[name];
  },

  /**
   * Set the value of the {@link Ext.data.Field#name named field}.
   * @param {String} name The {@link Ext.data.Field#name name of the field} to get the value of.
   * @return {Object} The value of the field.
   */
  set: function set(name, value) {
    var encode = Ext.isPrimitive(value) ? String : Ext.encode,
        current = this.get(name),
        cfName;

    if (current !== null && encode(current) == encode(value)) {
      return;
    }

    this.dirty = true;

    if (!this.modified) {
      this.modified = {};
    }

    if (this.modified[name] === undefined) {
      this.modified[name] = current;
    }

    if (encode(value) == encode(this.modified[name])) {
      delete this.modified[name];
    }

    if (Object.keys(this.modified).length === 0) {
      this.dirty = false;
    }

    if (cfName = String(name).match(this.cfExp)) {
      var oldValueJSON = JSON.stringify(this.get('customfields') || {}),
          valueObject = JSON.parse(oldValueJSON);
      Tine.Tinebase.common.assertComparable(valueObject);
      valueObject[cfName[1]] = value;

      if (JSON.stringify(valueObject) != oldValueJSON) {
        this.set('customfields', valueObject);
      }
    } else {
      this.data[name] = value;
    }

    if (!this.editing) {
      this.afterEdit();
    }
  },

  /**
   * returns title of this record
   * 
   * @return {String}
   */
  getTitle: function getTitle() {
    var _ = window.lodash,
        me = this;

    if (Tine.Tinebase.data.TitleRendererManager.has(this.appName, this.modelName)) {
      return Tine.Tinebase.data.TitleRendererManager.get(this.appName, this.modelName)(this);
    } else if (String(this.titleProperty).match(/[{ ]/)) {
      if (!this.constructor.titleTwing) {
        var twingEnv = Object(twingEnv__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])();
        var loader = twingEnv.getLoader();
        loader.setTemplate(this.constructor.getPhpClassName() + 'Title', Tine.Tinebase.appMgr.get(this.appName).i18n._hidden(this.titleProperty));
        this.constructor.titleTwing = twingEnv;
      }

      return this.constructor.titleTwing.render(this.constructor.getPhpClassName() + 'Title', this.data);
    } else {
      var s = this.titleProperty ? this.titleProperty.split('.') : [null];
      return s.length > 0 && this.get(s[0]) && this.get(s[0])[s[1]] ? this.get(s[0])[s[1]] : s[0] ? this.get(this.titleProperty) : '';
    }
  },

  /**
   * returns the id of the record
   */
  getId: function getId() {
    return this.get(this.idProperty ? this.idProperty : 'id');
  },

  /**
   * sets the id of the record
   *
   * @param {String} id
   */
  setId: function setId(id) {
    return this.set(this.idProperty ? this.idProperty : 'id', id);
  },

  /**
   * converts data to String
   * 
   * @return {String}
   */
  toString: function toString() {
    return Ext.encode(this.data);
  },
  toJSON: function toJSON() {
    return this.data;
  },

  /**
   * returns true if given record obsoletes this one
   * 
   * - returns false if record has no modlog properties to make 
   *   handling of updated records work in the grid panel
   * @see 0009464: user grid does not refresh after ctx menu action
   * 
   * @param {Tine.Tinebase.data.Record} record
   * @return {Boolean}
   */
  isObsoletedBy: function isObsoletedBy(record) {
    if (record.modelName !== this.modelName || record.getId() !== this.getId()) {
      throw new Ext.Error('Records could not be compared');
    }

    if (this.constructor.hasField('seq') && record.get('seq') != this.get('seq')) {
      return record.get('seq') > this.get('seq');
    }

    return this.constructor.hasField('last_modified_time') ? record.get('last_modified_time') > this.get('last_modified_time') : false;
  },

  /**
   * update complete record with data from given record
   *
   * @param record
   */
  update: function update(record) {
    record = _.get(record, 'data', false) ? record : Tine.Tinebase.data.Record.setFromJson(record, this.constructor);
    this.beginEdit();
    this.fields.each(field => {
      let newValue = Tine.Tinebase.common.assertComparable(record.get(field.name));
      Tine.Tinebase.common.assertComparable(_.get(this, 'data.' + field.name));
      this.set(field.name, newValue);
    }, this);
    this.endEdit();
  },
  resolveForeignRecords: async function resolveForeignRecords(fields) {
    const fieldDefs = this.constructor.getModelConfiguration().fields;
    const pms = [];

    _.each(this.constructor.getModelConfiguration().fields, (def, fieldName) => {
      if (fields && _.indexOf(fields, fieldName) < 0) return;
      let value = this.get(fieldName);

      if (_.get(def, 'type') === 'record' && value && !_.isFunction(_.get(value, 'beginEdit'))) {
        const recordClass = Tine.Tinebase.data.RecordMgr.get(def.config.appName, def.config.modelName);
        if (!recordClass) return;

        if (String(value)[0] === '{' || _.isObject(value)) {
          this.set(fieldName, Tine.Tinebase.data.Record.setFromJson(value, recordClass));
        } else {
          const proxy = new Tine.Tinebase.data.RecordProxy({
            recordClass: recordClass
          });
          pms.push(proxy.promiseLoadRecord(value).then(record => {
            this.set(fieldName, record);
          }));
        }
      }
    });

    await Promise.all(pms);
  }
});
/**
 * Generate a constructor for a specific Record layout.
 * 
 * @param {Array} def see {@link Ext.data.Record#create}
 * @param {Object} meta information see {@link Tine.Tinebase.data.Record}
 * 
 * <br>usage:<br>
<b>IMPORTANT: the ngettext comments are required for the translation system!</b>
<pre><code>
var TopicRecord = Tine.Tinebase.data.Record.create([
    {name: 'summary', mapping: 'topic_title'},
    {name: 'details', mapping: 'username'}
], {
    appName: 'Tasks',
    modelName: 'Task',
    idProperty: 'id',
    titleProperty: 'summary',
    // ngettext('Task', 'Tasks', n);
    recordName: 'Task',
    recordsName: 'Tasks',
    containerProperty: 'container_id',
    // ngettext('to do list', 'to do lists', n);
    containerName: 'to do list',
    containesrName: 'to do lists'
});
</code></pre>
 * @static
 */

Tine.Tinebase.data.Record.create = function (o, meta) {
  var f = Ext.extend(Tine.Tinebase.data.Record, {});
  var p = f.prototype;
  Ext.apply(p, meta);
  p.fields = new Ext.util.MixedCollection(false, function (field) {
    return field.name;
  });

  for (var i = 0, len = o.length; i < len; i++) {
    if (o[i]['name'] == meta.containerProperty && meta.allowBlankContainer === false) {
      o[i]['allowBlank'] = false;
    }

    p.fields.add(new Ext.data.Field(o[i]));
  }

  f.getField = function (name) {
    return p.fields.get(name);
  };

  f.getMeta = function (name) {
    var value = null;

    switch (name) {
      case 'phpClassName':
        value = p.appName + '_Model_' + p.modelName;
        break;

      default:
        value = p[name];
    }

    return value;
  };

  f.getDefaultData = function () {
    return {};
  };

  f.getFieldDefinitions = function () {
    return p.fields.items;
  };

  f.getFieldNames = function () {
    if (!p.fieldsarray) {
      var arr = p.fieldsarray = [];
      Ext.each(p.fields.items, function (item) {
        arr.push(item.name);
      });
    }

    return p.fieldsarray;
  };

  f.hasField = function (n) {
    return p.fields.indexOfKey(n) >= 0;
  };

  f.getRecordName = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n;
    return i18n.n_(p.recordName, p.recordsName, 1);
  };

  f.getModuleName = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n,
        moduleName;

    if (p.modelConfiguration && p.modelConfiguration.moduleName) {
      return i18n._(p.modelConfiguration.moduleName);
    }

    return p.moduleName ? i18n._(p.moduleName) : f.getRecordsName();
  };

  f.getRecordsName = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n;
    return i18n.n_(p.recordName, p.recordsName, 50);
  };

  f.getRecordGender = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n,
        msgId = 'GENDER_' + p.recordName,
        gender = i18n._hidden(msgId);

    return gender !== msgId ? gender : 'other';
  };

  f.getContainerName = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n;
    return i18n.n_(p.containerName, p.containersName, 1);
  };

  f.getContainersName = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n;
    return i18n.n_(p.containerName, p.containersName, 50);
  };

  f.getAppName = function () {
    var app = Tine.Tinebase.appMgr.get(p.appName),
        i18n = app && app.i18n ? app.i18n : window.i18n;
    return i18n._(p.appName);
  };

  f.getIconCls = function () {
    return 'ApplicationIconCls ' + p.appName + 'IconCls ' + p.appName + p.recordName;
  };
  /**
   * returns the php class name of the record itself or by the application(name) and model(name)
   * @param {mixed} app       the application instance or the application name or the record class
   * @param {mixed} model     the model name
   * @return {String} php class name
   */


  f.getPhpClassName = function (app, model) {
    // without arguments the php class name of the this is returned
    if (!app && !model) {
      return f.getMeta('phpClassName');
    } // if var app is a record class, the getMeta method is called


    if (Ext.isFunction(app.getMeta)) {
      return app.getMeta('phpClassName');
    }

    var appName = Ext.isObject(app) && app.hasOwnProperty('name') ? app.name : app;
    return appName + '_Model_' + model;
  };

  f.getModelConfiguration = function () {
    return p.modelConfiguration;
  }; // sanitize containerProperty label


  var containerProperty = f.getMeta('containerProperty');

  if (containerProperty) {
    var field = p.fields.get(containerProperty);

    if (field) {
      field.label = p.containerName;
    }
  }

  if (!p.grantsPath) {
    p.grantsPath = 'data' + (containerProperty ? '.' + containerProperty : '') + '.account_grants';
  }

  Tine.Tinebase.data.RecordMgr.add(f);
  return f;
};

Tine.Tinebase.data.Record.generateUID = function (length) {
  length = length || 40;
  var s = '0123456789abcdef',
      uuid = new Array(length);

  for (var i = 0; i < length; i++) {
    uuid[i] = s.charAt(Math.ceil(Math.random() * 15));
  }

  return uuid.join('');
};

Tine.Tinebase.data.RecordManager = Ext.extend(Ext.util.MixedCollection, {
  add: function add(record) {
    if (!Ext.isFunction(record.getMeta)) {
      throw new Ext.Error('only records of type Tinebase.data.Record could be added');
    }

    var appName = record.getMeta('appName'),
        modelName = record.getMeta('modelName');

    if (!appName && modelName) {
      throw new Ext.Error('appName and modelName must be in the metadatas');
    }

    Tine.Tinebase.data.RecordManager.superclass.add.call(this, appName + '.' + modelName, record);
  },
  get: function get(appName, modelName) {
    if (!appName && _.isFunction(_.get(modelName, 'getMeta'))) {
      return modelName;
    }

    if (!appName) return;

    if (Ext.isFunction(appName.getMeta)) {
      return appName;
    }

    if (!modelName && appName.modelName) {
      modelName = appName.modelName;
    }

    if (appName.appName) {
      appName = appName.appName;
    }

    if (_.isString(appName) && !modelName) {
      appName = appName.replace(/^Tine[._]/, '').replace(/[._]Model[._]/, '.');
      let appPart = appName.match(/^.+\./);

      if (appPart) {
        modelName = appName.replace(appPart[0], '');
        appName = appPart[0].replace(/\.$/, '');
      }
    }

    if (!Ext.isString(appName)) {
      throw new Ext.Error('appName must be a string');
    }

    Ext.each([appName, modelName], function (what) {
      if (!Ext.isString(what)) return;
      var parts = what.split(/(?:_Model_)|(?:\.)/);

      if (parts.length > 1) {
        appName = parts[0];
        modelName = parts[1];
      }
    });
    return Tine.Tinebase.data.RecordManager.superclass.get.call(this, appName + '.' + modelName);
  }
});
Tine.Tinebase.data.RecordMgr = new Tine.Tinebase.data.RecordManager(true);
/**
 * create record from json string
 *
 * @param {String} json
 * @param {Tine.Tinebase.data.Record} recordClass
 * @returns {Tine.Tinebase.data.Record}
 */

Tine.Tinebase.data.Record.setFromJson = function (json, recordClass) {
  var jsonReader = new Ext.data.JsonReader({
    id: recordClass.idProperty,
    root: 'results',
    totalProperty: 'totalcount'
  }, recordClass);

  try {
    var recordData = {
      results: _.compact([Ext.isString(json) ? Ext.decode(json) : json])
    },
        data = jsonReader.readRecords(recordData),
        record = data.records[0];
  } catch (e) {
    Tine.log.warn('Exception in setFromJson:');
    Tine.log.warn(e);
  }

  var recordId = _.get(record, 'data.' + _.get(record, 'idProperty'), Tine.Tinebase.data.Record.generateUID());

  if (!record) {
    record = new recordClass({}, recordId);
  }

  record.id = recordId;
  return record;
};

/***/ }),
/* 1284 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/**
 * @namespace Tine.Tinebase.data
 * @class     Tine.Tinebase.data.RecordStore
 * @extends   Ext.data.Store
 * @author    Cornelius Weiss <c.weiss@metaways.de>
 * 
 * Small helper class to create an {@link Ext.data.Store} configured with an
 * {@link Ext.data.DirectProxy} and {@link Ext.data.JsonReader} to make interacting
 * with an {@link Ext.Direct} Server-side {@link Ext.ux.direct.ZendFrameworkProvider} easier.
 * 
 * @xtype     tinerecordstore
 * @constructor
 * @param {Object} config config object
 */
Tine.Tinebase.data.RecordStore = function (c) {
  /**
   * @cfg {bool} readOnly
   * set to true to skip creation of a writer
   */

  /**
   * @cfg {Tine.Tinebase.data.Record} recordClass
   * model of this proxy (required)
   */
  c.batchTransactions = false;
  c.appName = c.recordClass.getMeta('appName');
  c.modelName = c.recordClass.getMeta('modelName');

  if (!c.sortInfo) {
    // TODO we might want to use $defaultSortInfo of the model here (see Tine.widgets.grid.GridPanel.initStore)
    var titleProperty = c.recordClass.getMeta('titleProperty'),
        defaultSortField = Ext.isArray(titleProperty) ? titleProperty[1][0] : titleProperty,
        defaultSortInfo = c.recordClass.hasField(titleProperty) ? {
      field: defaultSortField,
      order: 'DESC'
    } : null;
    c.sortInfo = c.defaultSortInfo || defaultSortInfo;
  }

  if (typeof c.reader == 'undefined') {
    c.reader = new Ext.data.JsonReader({
      root: c.root || 'results',
      totalProperty: c.totalProperty || 'totalcount',
      id: c.recordClass.getMeta('idProperty')
    }, c.recordClass);
  }

  if (typeof c.writer == 'undefined' && !c.readOnly) {
    c.writer = new Ext.data.JsonWriter({});
  }

  if (typeof c.proxy == 'undefined') {
    c.proxy = new Tine.Tinebase.data.RecordProxy({
      recordClass: c.recordClass
    });
  }

  Tine.Tinebase.data.RecordStore.superclass.constructor.call(this, c);
};

Ext.extend(Tine.Tinebase.data.RecordStore, Ext.data.Store, {});
Ext.reg('tinerecordstore', Tine.Tinebase.data.RecordStore);

/***/ }),
/* 1285 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.data');
/**
 * @namespace   Tine.Tinebase.data
 * @class       Tine.Tinebase.data.GroupedStoreCollection
 * @extends     Ext.util.MixedCollection
 *
 * grouping store collection
 *
 * automatically manages group stores
 *
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config
 */

Tine.Tinebase.data.GroupedStoreCollection = function (config) {
  this.fixedGroups = [];
  Ext.apply(this, config);
  Tine.Tinebase.data.GroupedStoreCollection.superclass.constructor.call(this);
  this.store.on('beforeload', this.onStoreBeforeLoad, this);
  this.store.on('load', this.onStoreLoad, this);
  this.store.on('add', this.onStoreAdd, this);
  this.store.on('update', this.onStoreUpdate, this);
  this.store.on('remove', this.onStoreRemove, this);

  if (this.group) {
    this.applyGrouping();
  }
};

Ext.extend(Tine.Tinebase.data.GroupedStoreCollection, Ext.util.MixedCollection, {
  /**
   * @cfg {Ext.data.Store} store
   */
  store: null,

  /**
   * @cfg {String|Function} group
   */
  group: '',

  /**
   * @cfg {Array} fixedGroups
   * if present, these is the fixed set of groups
   */
  fixedGroups: null,

  /**
   * @cfg {Bool} groupOnLoad
   * apply grouping when store is loaded
   * NOTE: when disabled, grouping must be triggered manually
   */
  groupOnLoad: true,
  applyGrouping: function applyGrouping() {
    if (this.fixedGroups.length) {
      this.setFixedGroups(this.fixedGroups);
    }

    this.groupRecords(this.store.getRange(), false);
  },
  groupBy: function groupBy(group) {
    this.group = group;
    this.applyGrouping();
  },
  groupRecords: function groupRecords(rs, append) {
    // put data into groups
    var groups = [];
    var records = [];
    Ext.each(rs, function (r) {
      var groupNames = this.getGroupNames(r);
      Ext.each(groupNames, function (groupName) {
        var idx = groups.indexOf(groupName);

        if (idx < 0) {
          groups.push(groupName);
          records.push([r.copy()]);
        } else {
          records[idx].push(r.copy());
        }
      });
    }, this); // collection housekeeping

    if (!this.fixedGroups.length) {
      Ext.each(this.keys.concat(), function (groupName) {
        if (groups.indexOf(groupName) < 0) {
          this.removeKey(groupName);
        }
      }, this);
    }

    if (!append) {
      // clear stores which have no longer data
      this.eachKey(function (groupName) {
        if (groups.indexOf(groupName) < 0) {
          var store = this.getCloneStore(groupName);
          store.loadRecords({
            records: []
          }, {
            add: append
          }, true);
        }
      }, this);
    }

    Ext.each(groups, function (groupName, idx) {
      var store = this.getCloneStore(groupName); // do we need a beforeload event here?

      store.loadRecords({
        records: records[idx]
      }, {
        add: append
      }, true);
    }, this);
  },
  setFixedGroups: function setFixedGroups(groupNames) {
    this.fixedGroups = groupNames;

    if (groupNames.length) {
      this.setGroups(groupNames);
    }

    this.groupRecords(this.store.getRange(), false);
  },
  // add/delete cloneStores
  setGroups: function setGroups(groupNames) {
    Ext.each(this.keys.concat(), function (groupName) {
      if (groupNames.indexOf(groupName) < 0) {
        this.removeKey(groupName);
      }
    }, this);
    Ext.each(groupNames, function (groupName, idx) {
      var store = this.get(groupName);

      if (!store) {
        store = this.createCloneStore();
        this.addSorted(groupName, store);
      }
    }, this);
  },

  /**
   * gets groups of given record
   *
   * @param {Ext.data.record} record
   * @returns {Array}
   */
  getGroupNames: function getGroupNames(record) {
    var _ = window.lodash,
        groupNames = Ext.isFunction(this.group) ? this.group(record) : record.get(this.group);

    if (!Ext.isArray(groupNames)) {
      groupNames = [groupNames];
    }

    if (this.fixedGroups.length) {
      groupNames = _.intersection(groupNames, this.fixedGroups);
    }

    return groupNames;
  },
  onStoreBeforeLoad: function onStoreBeforeLoad(store, options) {
    var ret = true;
    this.eachKey(function (groupName) {
      var store = this.get(groupName);
      ret = ret && store.fireEvent('beforeload', store, options);
    }, this);
    return ret;
  },
  onStoreLoad: function onStoreLoad() {
    if (this.groupOnLoad) {
      this.applyGrouping();
    }
  },
  onStoreAdd: function onStoreAdd(store, records, index) {
    this.suspendCloneStoreEvents = true;
    Ext.each(records, function (record) {
      Ext.each(this.getGroupNames(record), function (groupName) {
        var store = this.get(groupName),
            existingRecord = record.id != 0 ? store.getById(record.id) : null; // NOTE: record might be existing as it was added to a cloneStore

        if (existingRecord) {
          this.getCloneStore(groupName).replace(existingRecord, record.copy());
        } else {
          this.getCloneStore(groupName).add([record.copy()]);
        }
      }, this);
    }, this);
    this.suspendCloneStoreEvents = false;
  },
  onStoreUpdate: function onStoreUpdate(store, record, operation) {
    this.suspendCloneStoreEvents = true;
    var groupNames = this.getGroupNames(record);
    this.eachKey(function (groupName) {
      var store = this.get(groupName),
          existingRecord = store.getById(record.id);

      if (existingRecord) {
        if (groupNames.indexOf(groupName) < 0) {
          store.remove(existingRecord);
        } else {
          store.replaceRecord(existingRecord, record.copy());
        }
      } else {
        store.add([record.copy()]);
      }

      groupNames.remove(groupName);
    }, this);
    Ext.each(groupNames, function (groupName) {
      var store = this.getCloneStore(groupName);
      store.add(record.copy());
    }, this);
    this.suspendCloneStoreEvents = false;
  },
  onStoreRemove: function onStoreRemove(store, record, index) {
    this.suspendCloneStoreEvents = true;
    this.eachKey(function (groupName) {
      var store = this.get(groupName),
          existingRecord = store.getById(record.id);

      if (existingRecord) {
        store.remove(existingRecord);
      }
    }, this);
    this.suspendCloneStoreEvents = false;
  },
  getCloneStore: function getCloneStore(groupName) {
    var store = this.get(groupName);

    if (!store && !this.fixedGroups.length) {
      store = this.createCloneStore();
      this.addSorted(groupName, store);
    }

    return store;
  },
  addSorted: function addSorted(groupName, store) {
    var idx = this.length;

    if (this.sortFn) {
      var items = [store].concat(this.items);
      items.sort(this.sortFn);
      idx = items.indexOf(store);
    }

    this.insert(idx, groupName, store);
  },
  createCloneStore: function createCloneStore() {
    var clone = new Ext.data.Store({
      fields: this.store.fields,
      // load: this.mainStore.load.createDelegate(this.mainStore),
      // proxy: this.store.proxy,
      replaceRecord: function replaceRecord(o, n) {
        var idx = this.indexOf(o);
        this.remove(o);
        this.insert(idx, n);
      }
    });
    clone.on('add', this.onCloneStoreAdd, this);
    clone.on('update', this.onCloneStoreUpdate, this);
    clone.on('remove', this.onCloneStoreRemove, this);
    return clone;
  },
  onCloneStoreAdd: function onCloneStoreAdd(eventStore, rs) {
    if (this.suspendCloneStoreEvents) return;
    Ext.each(rs, function (r) {
      this.store.add(r.copy());
    }, this);
  },
  onCloneStoreUpdate: function onCloneStoreUpdate(eventStore, r) {
    if (this.suspendCloneStoreEvents) return;
    var existingRecord = this.store.getById(r.id);

    if (existingRecord) {
      this.store.replaceRecord(existingRecord, r.copy());
    }
  },
  onCloneStoreRemove: function onCloneStoreRemove(store, r) {
    if (this.suspendCloneStoreEvents) return;
    var existingRecord = this.store.getById(r.id);

    if (existingRecord) {
      this.store.remove(existingRecord);
    }
  }
});

/***/ }),
/* 1286 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase.data');
/**
 * @namespace   Tine.Tinebase.data
 * @class       Tine.Tinebase.data.RecordProxy
 * @extends     Ext.data.DataProxy
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * Generic record proxy for an model/datatype of an application
 * 
 * @constructor
 * @param {Object} config Config Object
 */

Tine.Tinebase.data.RecordProxy = function (c) {
  // we support all actions
  c.api = {
    read: true,
    create: true,
    update: true,
    destroy: true
  };
  Tine.Tinebase.data.RecordProxy.superclass.constructor.call(this, c);
  Ext.apply(this, c);
  this.init();
  this.appName = this.appName ? this.appName : this.recordClass.getMeta('appName');
  this.modelName = this.modelName ? this.modelName : this.recordClass.getMeta('modelName');
  this.idProperty = this.idProperty ? this.idProperty : this.recordClass.getMeta('idProperty');
  /* NOTE: in ExtJS records always are part of a store. The store is
           the only instance which triggers read/write actions.
           
           In our edit dialoges in contrast we work with single (store-less) 
           records and the handlers itselve trigger the read/write actions.
           This might change in future, but as long as we do so, we also need
           the reader/writer here.
   */

  this.jsonReader = new Ext.data.JsonReader(Ext.apply({
    id: this.idProperty,
    root: 'results',
    totalProperty: 'totalcount'
  }, c.readerConfig || {}), this.recordClass);
};

Ext.extend(Tine.Tinebase.data.RecordProxy, Ext.data.DataProxy, {
  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,

  /**
   * @type String 
   * @property appName
   * internal/untranslated app name
   */
  appName: null,

  /**
   * default value for timeout on searches
   * 
   * @type Number
   */
  searchTimeout: 60000,

  /**
   * default value for timeout on saving
   * 
   * @type Number
   */
  saveTimeout: 300000,

  /**
   * default value for timeout on deleting by filter
   * 
   * @type Number
   */
  deleteByFilterTimeout: 300000,

  /**
   * default value for timeout on deleting
   * 
   * @type Number
   */
  deleteTimeout: 120000,

  /**
   * @type String 
   * @property idProperty
   * property of the id of the record
   */
  idProperty: null,

  /**
   * @type String 
   * @property modelName
   * name of the model/record 
   */
  modelName: null,

  /**
   * id of last transaction
   * @property transId
   */
  transId: null,

  /**
   * TODO is this really needed?
   */
  onDestroyRecords: Ext.emptyFn,
  removeFromBatch: Ext.emptyFn,
  init: Ext.emptyFn,

  /**
   * Aborts any outstanding request.
   * @param {Number} transactionId (Optional) defaults to the last transaction
   */
  abort: function abort(transactionId) {
    return Ext.Ajax.abort(transactionId);
  },

  /**
   * Determine whether this object has a request outstanding.
   * @param {Number} transactionId (Optional) defaults to the last transaction
   * @return {Boolean} True if there is an outstanding request.
   */
  isLoading: function isLoading(transId) {
    return Ext.Ajax.isLoading(transId);
  },

  /**
   * loads a single 'full featured' record
   * 
   * @param   {Ext.data.Record} record
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success {Ext.data.Record}
   */
  loadRecord: function loadRecord(record, options) {
    options = options || {};
    options.params = options.params || {};

    options.beforeSuccess = function (response) {
      if (!options.suppressBusEvents) {
        _.defer(_.bind(this.postMessage, this), 'update', response.responseText);
      }

      return [this.recordReader(response)];
    };

    var p = options.params;
    p.method = this.appName + '.get' + this.modelName;
    p.id = Ext.isString(record) ? record : record.get(this.idProperty);
    return this.doXHTTPRequest(options);
  },
  promiseLoadRecord: function promiseLoadRecord(record, options) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      try {
        me.loadRecord(record, Ext.apply(options || {}, {
          success: function success(r) {
            fulfill(r);
          },
          failure: function failure(error) {
            reject(new Error(error));
          }
        }));
      } catch (error) {
        if (Ext.isFunction(reject)) {
          reject(new Error(options));
        }
      }
    });
  },

  /**
   * searches all (lightweight) records matching filter
   * 
   * @param   {Object} filter
   * @param   {Object} paging
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success {Object} root:[records], totalcount: number
   */
  searchRecords: function searchRecords(filter, paging, options) {
    options = options || {};
    options.params = options.params || {};
    var p = options.params;
    p.method = this.appName + '.search' + this.modelName + 's';
    p.filter = filter ? filter : [];
    p.paging = paging;

    options.beforeSuccess = function (response) {
      return [this.jsonReader.read(response)];
    }; // increase timeout as this can take a longer (1 minute)


    options.timeout = this.searchTimeout;
    return this.doXHTTPRequest(options);
  },

  /**
   * saves a single record
   * 
   * @param   {Ext.data.Record} record
   * @param   {Object} options
   * @param   {Object} additionalArguments
   * @return  {Number} Ext.Ajax transaction id
   * @success {Ext.data.Record}
   */
  saveRecord: function saveRecord(record, options, additionalArguments) {
    options = options || {};
    options.params = options.params || {};

    options.beforeSuccess = function (response) {
      if (!options.suppressBusEvents) {
        let recordData = JSON.parse(response.responseText);
        let action = !_.get(record, 'data.id') && _.get(recordData, 'id') || !_.get(record, 'data.creation_time') && _.get(recordData, 'creation_time') ? 'create' : 'update';

        _.defer(_.bind(this.postMessage, this), action, recordData);
      }

      return [this.recordReader(response)];
    };

    var p = options.params;
    p.method = this.appName + '.save' + this.modelName;
    p.recordData = record.data;

    if (additionalArguments) {
      Ext.apply(p, additionalArguments);
    } // increase timeout as this can take a longer (5 minutes)


    options.timeout = this.saveTimeout;
    return this.doXHTTPRequest(options);
  },
  promiseSaveRecord: function promiseSaveRecord(record, options, additionalArguments) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      try {
        me.saveRecord(record, Ext.apply(options || {}, {
          success: function success(r) {
            fulfill(r);
          },
          failure: function failure(error) {
            reject(new Error(error));
          }
        }), additionalArguments);
      } catch (error) {
        if (Ext.isFunction(reject)) {
          reject(new Error(options));
        }
      }
    });
  },

  /**
   * deletes multiple records identified by their ids
   * 
   * @param   {Array} records Array of records or ids
   * @param   {Object} options
   * @param   {Object} additionalArguments
   * @return  {Number} Ext.Ajax transaction id
   * @success 
   */
  deleteRecords: function deleteRecords(records, options, additionalArguments) {
    options = options || {};
    options.params = options.params || {};
    options.params.method = this.appName + '.delete' + this.modelName + 's';
    options.params.ids = this.getRecordIds(records);

    if (additionalArguments) {
      Ext.apply(options.params, additionalArguments);
    }

    options.beforeSuccess = function (response) {
      var _ = window.lodash,
          me = this;

      if (!Ext.isArray(records)) {
        records = [records];
      }

      if (!options.suppressBusEvents) {
        _.each(records, function (record) {
          me.postMessage('delete', record.data);
        });
      }
    }; // increase timeout as this can take a long time (2 mins)


    options.timeout = this.deleteTimeout;
    return this.doXHTTPRequest(options);
  },
  promiseDeleteRecords: function promiseDeleteRecords(record, options, additionalArguments) {
    var me = this;
    return new Promise(function (fulfill, reject) {
      try {
        me.deleteRecords(record, Ext.apply(options || {}, {
          success: function success(r) {
            fulfill(r);
          },
          failure: function failure(error) {
            reject(new Error(error));
          }
        }), additionalArguments);
      } catch (error) {
        if (Ext.isFunction(reject)) {
          reject(new Error(options));
        }
      }
    });
  },

  /**
   * deletes multiple records identified by a filter
   * 
   * @param   {Object} filter
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success 
   */
  deleteRecordsByFilter: function deleteRecordsByFilter(filter, options) {
    options = options || {};
    options.params = options.params || {};
    options.params.method = this.appName + '.delete' + this.modelName + 'sByFilter';
    options.params.filter = filter; // increase timeout as this can take a long time (5 mins)

    options.timeout = this.deleteByFilterTimeout;
    return this.doXHTTPRequest(options);
  },

  /**
   * updates multiple records with the same data
   * 
   * @param   {Array} filter filter data
   * @param   {Object} updates
   * @return  {Number} Ext.Ajax transaction id
   * @success
   */
  updateRecords: function updateRecords(filter, updates, options) {
    options = options || {};
    options.params = options.params || {};
    options.params.method = this.appName + '.updateMultiple' + this.modelName + 's';
    options.params.filter = filter;
    options.params.values = updates;

    options.beforeSuccess = function (response) {
      return [Ext.util.JSON.decode(response.responseText)];
    };

    return this.doXHTTPRequest(options);
  },

  /**
   * returns an array of ids
   * 
   * @private 
   * @param  {Ext.data.Record|Array}
   * @return {Array} of ids
   */
  getRecordIds: function getRecordIds(records) {
    var ids = [];

    if (!Ext.isArray(records)) {
      records = [records];
    }

    for (var i = 0; i < records.length; i++) {
      ids.push(records[i].id ? records[i].id : records.id);
    }

    return ids;
  },

  /**
   * required method for Ext.data.Proxy, used by store
   */
  load: function load(params, reader, callback, scope, arg) {
    if (this.fireEvent("beforeload", this, params) !== false) {
      // 2017-11-03 cweiss - NOTE: some ext widgets directly work on the paging params.
      //   and don't update eventually existing params.paging properties. So we ALWAYS
      //   NEED to construct a new paging object from the params here!
      var paging = {
        sort: params.sort,
        dir: params.dir,
        start: params.start,
        limit: params.limit
      };
      this.searchRecords(params.filter, paging, {
        params: params,
        scope: this,
        success: function success(records) {
          callback.call(scope || this, records, arg, true);
        },
        failure: function failure(exception) {
          //this.fireEvent('exception', this, 'remote', 'read', options, response, arg);
          this.fireEvent('loadexception', this, 'remote', exception, arg);
          callback.call(scope || this, exception, arg, false);
        }
      });
    } else {
      callback.call(scope || this, null, arg, false);
    }
  },

  /**
   * do the request
   * 
   * @param {} action
   * @param {} rs
   * @param {} params
   * @param {} reader
   * @param {} callback
   * @param {} scope
   * @param {} options
   */
  doRequest: function doRequest(action, rs, params, reader, callback, scope, options) {
    var opts = {
      params: params,
      callback: callback,
      scope: scope
    };

    switch (action) {
      case Ext.data.Api.actions.create:
        this.saveRecord(rs, opts);
        break;

      case Ext.data.Api.actions.read:
        this.load(params, reader, callback, scope, options);
        break;

      case Ext.data.Api.actions.update:
        this.saveRecord(rs, opts);
        break;

      case Ext.data.Api.actions.destroy:
        this.deleteRecords(rs, opts);
        break;
    }
  },

  /**
   * returns reader
   * 
   * @return {Ext.data.DataReader}
   */
  getReader: function getReader() {
    return this.jsonReader;
  },

  /**
   * reads a single 'fully featured' record from json data
   * 
   * NOTE: You might want to override this method if you have a more complex record
   * 
   * @param  XHR response
   * @return {Ext.data.Record}
   */
  recordReader: function recordReader(response) {
    return Tine.Tinebase.data.Record.setFromJson(response.responseText, this.recordClass);
  },

  /**
   * performs an Ajax request
   */
  doXHTTPRequest: function doXHTTPRequest(options) {
    var requestOptions = {
      scope: this,
      params: options.params,
      callback: options.callback,
      headers: options.headers,
      success: function success(response) {
        var args = [];

        if (typeof options.beforeSuccess == 'function') {
          args = options.beforeSuccess.call(this, response);
        }

        if (typeof options.success == 'function') {
          options.success.apply(options.scope, args);
        }
      },
      // note incoming options are implicitly json-rpc converted
      failure: function failure(response, jsonrpcoptions) {
        var responseData = Ext.decode(response.responseText),
            exception = responseData.data ? responseData.data : responseData;
        exception.request = jsonrpcoptions.jsonData;
        exception.response = response.responseText;
        var args = [exception];

        if (typeof options.beforeFailure == 'function') {
          args = options.beforeFailure.call(this, response);
        }

        if (typeof options.failure == 'function') {
          Tine.log.debug('Tine.Tinebase.data.RecordProxy::doXHTTPRequest -> call failure fn');
          options.failure.apply(options.scope, args);
        } // requests with callback need to define their own exception handling
        else if (!options.callback) {
            Tine.log.debug('Tine.Tinebase.data.RecordProxy::doXHTTPRequest -> handle exception');
            this.handleRequestException(exception);
          } else {
            Tine.log.debug('Tine.Tinebase.data.RecordProxy::doXHTTPRequest -> call callback fn');
          }
      }
    };

    if (options.timeout) {
      requestOptions.timeout = options.timeout;
    }

    this.transId = Ext.Ajax.request(requestOptions);
    return this.transId;
  },

  /**
   * default exception handler
   * 
   * @param {Object} exception
   */
  handleRequestException: function handleRequestException(exception) {
    Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
  },

  /**
   * posts message about record crud action on central message bus
   * NOTE: we don't use the Ext internal write event as:
   *       a) to deal with cross window issues we only publish bare data
   *       b) to be able mix with other libraries
   *
   * @param {String} action [create|update|delete]
   * @param {Record} record
   */
  postMessage: function postMessage(action, record) {
    var _ = window.lodash,
        recordData = _.isFunction(record.beginEdit) ? record.data : _.isString(record) ? JSON.parse(record) : record;
    window.postal.publish({
      channel: "recordchange",
      topic: [this.appName, this.modelName, action].join('.'),
      data: recordData
    });
  }
});

/***/ }),
/* 1287 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @subpackage  data
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase.data');
/**
 * Abstract Backdend for an model/datatype of an application
 * 
 * @namespace   Tine.Tinebase.data
 * @class       Tine.Tinebase.data.AbstractBackend
 * @extends     Ext.data.DataProxy
 * @constructor 
 */

Tine.Tinebase.data.AbstractBackend = function (config) {
  Tine.Tinebase.data.AbstractBackend.superclass.constructor.call(this);
  Ext.apply(this, config);
};

Ext.extend(Tine.Tinebase.data.AbstractBackend, Ext.data.DataProxy, {
  /**
   * @cfg {String} appName
   * internal/untranslated app name (required)
   */
  appName: null,

  /**
   * @cfg {String} modelName
   * name of the model/record  (required)
   */
  modelName: null,

  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,

  /**
   * @cfg {String} idProperty
   * property of the id of the record
   */
  idProperty: 'id',

  /**
   * loads a single 'full featured' record
   * 
   * @param   {Ext.data.Record} record
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success {Ext.data.Record}
   */
  loadRecord: function loadRecord(record, options) {
    options.success.defer(1000, options.scope, record);
  },

  /**
   * searches all (lightweight) records matching filter
   * 
   * @param   {Object} filter
   * @param   {Object} paging
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success {Object} root:[recrods], totalcount: number
   */
  searchRecords: function searchRecords(filter, paging, options) {
    options.success.defer(1000, options.scope, [{
      records: [],
      success: 1,
      totalRecords: 0
    }]);
  },

  /**
   * saves a single record
   * 
   * @param   {Ext.data.Record} record
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success {Ext.data.Record}
   */
  saveRecord: function saveRecord(record, options) {
    record.commit(true);
    options.success.defer(1000, options.scope, [record]);
  },

  /**
   * deletes multiple records identified by their ids
   * 
   * @param   {Array} records Array of records or ids
   * @param   {Object} options
   * @return  {Number} Ext.Ajax transaction id
   * @success 
   */
  deleteRecords: function deleteRecords(records, options) {
    options.success.defer(1000, options.scope);
  },

  /**
   * updates multiple records with the same data
   * 
   * @param   {Array} filter filter data
   * @param   {Object} updates
   * @return  {Number} Ext.Ajax transaction id
   * @success
   */
  updateRecords: function updateRecords(filter, updates, options) {
    options.success.defer(1000, options.scope, []);
  },

  /**
   * returns an array of ids
   * 
   * @private 
   * @param  {Ext.data.Record|Array}
   * @return {Array} of ids
   */
  getRecordIds: function getRecordIds(records) {
    var ids = [];

    if (!Ext.isArray(records)) {
      records = [records];
    }

    for (var i = 0; i < records.length; i++) {
      ids.push(records[i].id ? records[i].id : records.id);
    }

    return ids;
  },

  /**
   * reqired method for Ext.data.Proxy, used by store
   * @todo read the specs and implement success/fail handling
   * @todo move reqest to searchRecord
   */
  load: function load(params, reader, callback, scope, arg) {
    if (this.fireEvent("beforeload", this, params) !== false) {
      // move paging to own object
      var paging = {
        sort: params.sort,
        dir: params.dir,
        start: params.start,
        limit: params.limit
      };
      this.searchRecords(params.filter, paging, {
        scope: this,
        success: function success(records) {
          callback.call(scope || this, records, arg, true);
        }
      });
    } else {
      callback.call(scope || this, null, arg, false);
    }
  },

  /**
   * returns reader
   * 
   * @return {Ext.data.DataReader}
   */
  getReader: function getReader() {},

  /**
   * is request still loading?
   * 
   * @param  {Number} Ext.Ajax transaction id
   * @return {Bool}
   */
  isLoading: function isLoading(tid) {}
});

/***/ }),
/* 1288 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.data');
/**
 * tine 2.0 record clipboard
 * 
 * @namespace   Tine.Tinebase.data
 * @class       Tine.Tinebase.data.Clipboard
 * 
 * <p>Record Clipboard</p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @singleton
 */

Tine.Tinebase.data.Clipboard = function () {
  var items = {};
  return {
    clear: function clear(appName, modelName) {
      var key = this.getKey(appName, modelName);
      items[key] = [];
    },
    getKey: function getKey(appName, modelName) {
      var key = appName + modelName;

      if (!items.hasOwnProperty(key)) {
        items[key] = [];
      }

      return key;
    },
    push: function push(record) {
      Tine.log.debug('Putting record to clipboard:');
      Tine.log.debug(record);
      var key = this.getKey(record.appName, record.modelName);
      items[key].push(record);
    },
    pull: function pull(appName, modelName, stay) {
      var key = this.getKey(appName, modelName);

      if (items[key].length == 0) {
        return null;
      }

      if (!stay) {
        Tine.log.debug('Releasing record from clipboard:');
        var record = items[key].pop();
      } else {
        Tine.log.debug('Fetching record from clipboard:');
        var i = items[key].length - 1;
        var record = items[key][i];
      }

      Tine.log.debug(record);
      return record;
    },

    /**
     * returns the ids of all records by appName and modelName as array
     * 
     * @return array
     */
    getIds: function getIds(appName, modelName) {
      var key = appName + modelName;
      var ret = [];

      if (!items.hasOwnProperty(key)) {
        return ret;
      }

      if (items[key].length == 0) {
        return ret;
      }

      for (var index = 0; index < items[key].length; index++) {
        ret.push(items[key][index].get('id'));
      }

      return ret;
    },
    has: function has(appName, modelName) {
      var key = appName + modelName;

      if (items.hasOwnProperty(key)) {
        return items[key].length > 0;
      }

      return false;
    }
  };
}();

/***/ }),
/* 1289 */
/***/ (function(module, exports) {

Ext.ns('Tine.Tinebase');

Tine.Tinebase.RecentsManager = function (config) {
  Ext.apply(this, config);

  if (!this.stateId) {
    this.stateId = [this.recordClass.getMeta('appName'), this.recordClass.getMeta('modelName'), this.domain, 'recents'].join('-').toLowerCase();
  }
};

Tine.Tinebase.RecentsManager.prototype = {
  /**
   * @cfg {Tine.data.Record} recordClass
   */
  recordClass: null,

  /**
   * @cfg {string} this.domain recents this.domain
   */
  domain: 'all',

  /**
   * @cfg {Integer} maximum number of recents
   */
  maxRecents: 10,
  addRecentRecord: function addRecentRecord(record) {
    var id = record.getId(),
        recents = this.getRecentRecords(record.constructor, this.domain),
        dtSelect = new Date().getTime(); // check if record is already in current recents

    Ext.each(recents, function (r) {
      if (r.getId() == id) {
        recents.remove(r);
        return false;
      }
    }, this);
    record.dtSelect = dtSelect;
    recents.push(record);
    recents.sort(function (a, b) {
      return a.dtSelect > b.dtSelect;
    });
    recents.slice(0, this.maxRecents);
    this.saveRecentRecords(recents, record.constructor, this.domain);
  },
  getRecentRecords: function getRecentRecords() {
    var stateId = this.getStateId(this.recordClass, this.domain),
        recentsData = Ext.state.Manager.get(stateId),
        rs = [];

    if (Ext.isArray(recentsData)) {
      Ext.each(recentsData, function (recentData) {
        var recent = new this.recordClass(recentData);
        recent.dtSelect = recentData.dtSelect;
        rs.push(recent);
      }, this);
    }

    return rs;
  },

  /**
   * @private
   */
  saveRecentRecords: function saveRecentRecords(recents) {
    var stateId = this.getStateId(this.recordClass, this.domain),
        recentsData = [];
    Ext.each(recents, function (r) {
      var data = r.data;
      data['dtSelect'] = r.dtSelect;
      recentsData.push(data);
    }, this);
    Ext.state.Manager.set(stateId, recentsData);
  },
  getStateId: function getStateId() {
    return this.stateId;
  }
};

/***/ }),
/* 1290 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase');
/**
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.StateProvider
 * @extends     Ext.state.Provider
 */

Tine.Tinebase.StateProvider = function (config) {
  Tine.Tinebase.StateProvider.superclass.constructor.call(this);
  Ext.apply(this, config);
  this.state = this.readRegistry();
};

Ext.extend(Tine.Tinebase.StateProvider, Ext.state.Provider, {
  // private
  clear: function clear(name) {
    // persistent clear
    Tine.Tinebase.clearState(name); // store back in registry (as needed for popups)

    var stateInfo = Tine.Tinebase.registry.get('stateInfo');
    delete stateInfo[name];
    Tine.Tinebase.StateProvider.superclass.clear.call(this, name);
  },
  // private
  readRegistry: function readRegistry() {
    var states = {};
    var stateInfo = Tine.Tinebase.registry.get('stateInfo');

    for (var name in stateInfo) {
      states[name] = this.decodeValue(stateInfo[name]);
    }

    ;
    return states;
  },
  // private
  set: function set(name, value) {
    if (typeof value == "undefined" || value === null) {
      this.clear(name);
      return;
    }

    var stateInfo = Tine.Tinebase.registry.get('stateInfo'),
        encodedValue = this.encodeValue(value);

    if (stateInfo[name] != encodedValue) {
      // persistent save
      Tine.Tinebase.setState(name, encodedValue); // store back in registry (as needed for popups)

      stateInfo[name] = encodedValue;
      Tine.Tinebase.registry.set('stateInfo', stateInfo);
    }

    Tine.Tinebase.StateProvider.superclass.set.call(this, name, value);
  }
});

/***/ }),
/* 1291 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * Tine 2.0 main application manager
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.AppManager
 * @extends     Ext.util.Observable
 * @consturctor
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.AppManager = function () {
  /**
   * @property apps
   * @type Ext.util.MixedCollection
   * 
   * enabled apps
   */
  this.apps = new Ext.util.MixedCollection({});
  this.initialisedPromises = []; // fill this.apps with registry data 
  // do it the other way round because add() always adds records at the beginning of the MixedCollection

  var enabledApps = Tine.Tinebase.registry.get('userApplications'),
      app;
  Tine.log.debug('Tine.Tinebase.AppManager - enabled Apps: ');
  Tine.log.debug(enabledApps);

  for (var i = enabledApps.length - 1; i >= 0; i--) {
    app = enabledApps[i]; // if the app is not in the namespace, we don't initialise it

    if (Tine[app.name]) {
      app.appName = app.name;
      app.isInitialised = false;
      this.apps.add(app.appName, app);
    }
  }
};

Ext.apply(Tine.Tinebase.AppManager.prototype, {
  /**
   * @cfg {Tine.Application}
   */
  defaultApp: null,

  /**
   * returns an appObject
   * 
   * @param {String} appName
   * @return {Tine.Application}
   */
  get: function get(appName) {
    if (Ext.isObject(appName) && appName.hasOwnProperty('appName')) {
      appName = appName.appName;
    }

    if (Ext.isObject(appName) && appName.hasOwnProperty('name')) {
      appName = appName.name;
    }

    if (!this.isEnabled(appName)) {
      return false;
    }

    var app = this.apps.get(appName);

    if (!app.isInitialised) {
      var appObj = this.getAppObj(app);
      appObj.isInitialised = true;
      Ext.applyIf(appObj, app);
      this.apps.replace(appName, appObj);
      this.getInitialisedRecord(appName).resolver();
    }

    return this.apps.get(appName);
  },

  /**
   * helper as consumer might not know if we are in maincreen or dialog
   * @deprecated
   */
  getActive: function getActive() {
    if (Tine.Tinebase.MainScreen) {
      return Tine.Tinebase.MainScreen.getActiveApp();
    }
  },

  /**
   * returns appObject
   * 
   * @param {String} applicationId
   * @return {Tine.Application}
   */
  getById: function getById(applicationId) {
    return this.apps.find(function (app) {
      return app.id == applicationId;
    }, this);
  },

  /**
   * returns appObject of default app
   * 
   * @return {Tine.Application}
   */
  getDefault: function getDefault() {
    if (!this.defaultApp) {
      var defaultAppName = Tine.Tinebase.registry.get('preferences') && Tine.Tinebase.registry.get('preferences').get('defaultapp') ? Tine.Tinebase.registry.get('preferences').get('defaultapp') : this.defaultAppName;
      this.defaultApp = this.get(defaultAppName) || this.apps.find(function (app) {
        return app.hasMainScreen;
      });

      if (!this.defaultApp) {
        // no global exception concept yet...
        //throw Ext.Error('no apps enabled', 620);
        Ext.MessageBox.show({
          title: i18n._('Missing Applications'),
          msg: i18n._('There are no applications enabled for you. Please contact your administrator.'),
          buttons: Ext.Msg.OK,
          icon: Ext.MessageBox.WARNING
        });
      }
    }

    return this.defaultApp;
  },

  /**
   * set default app for this session
   * 
   * @param {Tine.Application/String} app
   */
  setDefault: function setDefault(app) {
    if (Ext.isString(app)) {
      app = this.get(app);
    }

    if (app) {
      this.defaultApp = app;
    }
  },

  /**
   * returns a list of all apps for current user
   */
  getAll: function getAll() {
    this.initAll();
    return this.apps;
  },

  /**
   * checks whether a given app is enabled for current user or not
   */
  isEnabled: function isEnabled(appName) {
    var app = this.apps.get(appName);
    return app ? app.status == 'enabled' : false;
  },

  /**
   * initialises all enabled apps
   * @private
   */
  initAll: function initAll() {
    this.apps.each(function (app) {
      this.get(app.appName);
    }, this);
  },

  /**
   * @private
   */
  getAppObj: function getAppObj(app) {
    try {
      // legacy
      if (typeof Tine[app.appName].getPanel == 'function') {
        // make a legacy Tine.Application
        return this.getLegacyApp(app);
      }

      return typeof Tine[app.appName].Application == 'function' ? new Tine[app.appName].Application(app) : new Tine.Tinebase.Application(app);
    } catch (e) {
      console.error('Initialising of Application "' + app.appName + '" failed with the following message:' + e);
      console.error(e.stack);

      if (!Tine[app.appName].registry) {
        // registry load problem: reload
        Tine.Tinebase.common.reload({});
      }

      return false;
    }
  },

  /**
   * @private
   */
  getLegacyApp: function getLegacyApp(app) {
    app.hasMainScreen = true;
    var appPanel = Tine[app.appName].getPanel();
    var appObj = new Tine.Tinebase.Application(app);
    var mainScreen = new Tine.widgets.MainScreen({
      app: appObj
    });
    Ext.apply(appObj, {
      mainScreen: mainScreen
    });
    Ext.apply(mainScreen, {
      appPanel: appPanel,
      getContainerTreePanel: function getContainerTreePanel() {
        return this.appPanel;
      },
      getWestPanel: function getWestPanel() {
        return this.appPanel;
      },
      afterRender: function afterRender() {
        Tine.widgets.MainScreen.superclass.afterRender.call(this);
        Tine.Tinebase.MainScreen.setActiveCenterPanel(mainScreen, true);
        Tine.Tinebase.MainScreen.setActiveTreePanel(appPanel, true); // remove favorite toolbar for legacy modules

        var westRegionPanel = mainScreen.westRegionPanel,
            westPanelToolbar = westRegionPanel.getTopToolbar();
        westPanelToolbar.removeAll();
        westPanelToolbar.hide();
        westPanelToolbar.doLayout();
        appPanel.fireEvent('beforeexpand', appPanel);
      }
    });
    appPanel.on('render', function (p) {
      p.header.remove(); // additionally to removing the DOM node, we also need to reset the 
      // header class variable, as IE evals "if (this.header)" to true otherwise 

      p.header = false;
      p.doLayout();
    });
    return appObj;
  },
  getInitialisedRecord: function getInitialisedRecord(appName) {
    let record = _.find(this.initialisedPromises, {
      appName: appName
    });

    if (!record) {
      record = {
        appName: appName
      };
      record.promise = new Promise(resolve => {
        record.resolver = resolve;
      });
      this.initialisedPromises.push(record);
    }

    return record;
  },
  isInitialised: function isInitialised(appName) {
    return this.getInitialisedRecord(appName).promise;
  }
});

/***/ }),
/* 1292 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine', 'Tine.Tinebase');
/**
 * @namespace Tine.Tinebase
 * @class Tine.Tinebase.ExceptionHandler
 * @singleton
 * 
 * IE NOTE: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnscrpt/html/WebErrors2.asp
 *    "A common problem that bites many developers occurs when their onerror handler is not 
 *     called because they have script debugging enabled for Internet Explorer."
 *
 * central class for exception handling
 */

Tine.Tinebase.ExceptionHandler = function () {
  /**
   * handle window errors
   * 
   * NOTE: this isn't working cross browser and reports generated by this
   *       are useless most times as we don't have the trace and user tend to 
   *       not describe the problem. Moreover, in most cases, js exceptions are 
   *       not a problem for the UI anyway.
   *       
   *       Therefore we don't show the error reporting dialog anymore for js
   *       exceptions, but let the exception bubble, so browser specific error
   *       analysis is possible
   */
  var onWindowError = function onWindowError() {
    var error = getNormalisedError.apply(this, arguments);
    var traceHtml = '<table>';

    for (p in error) {
      if (error.hasOwnProperty(p)) {
        traceHtml += '<tr><td><b>' + p + '</b></td><td>' + error[p] + '</td></tr>';
      }
    }

    traceHtml += '</table>'; // check for special cases we don't want to handle

    if (traceHtml.match(/versioncheck/)) {
      return true;
    } // we don't wanna know fancy FF3.5 crome bugs


    if (traceHtml.match(/chrome/)) {
      return true;
    } // don't show openlayers error (occurs if window with contact is closed too fast)
    // TODO better fix this error ...


    if (traceHtml.match(/OpenLayers\.js/) && traceHtml.match(/element is null/)) {
      return true;
    } // let exception bubble to browser


    return false;
  };
  /**
   * @todo   make this working in safari
   * @return {string}
   */


  var getNormalisedError = function getNormalisedError() {
    var error = {
      name: 'unknown error',
      message: 'unknown',
      code: 'unknown',
      description: 'unknown',
      url: 'unknown',
      line: 'unknown',
      trace: 'unknown'
    }; // NOTE: Arguments is not always a real Array

    var args = [];

    for (var i = 0; i < arguments.length; i++) {
      args[i] = arguments[i];
    }

    if (args[0] instanceof Error) {
      // Error object thrown in try...catch
      error.name = args[0].name;
      error.message = args[0].message;
      error.code = args[0].number & 0xFFFF; //Apply binary arithmetic for IE number, firefox returns message string in element array element 0

      error.description = args[0].description;
      error.trace = args[0].stack;
    } else if (args.length == 3 && typeof args[2] == "number") {
      // Check the signature for a match with an unhandled exception
      error.name = 'catchable exception';
      error.message = args[0];
      error.url = args[1];
      error.line = args[2];
    } else {
      error.message = "An unknown JS error has occured.";
      error.description = 'The following information may be useful:' + "\n";

      for (var x = 0; x < args.length; x++) {
        try {
          error.description += Ext.encode(args[x]) + "\n";
        } catch (e) {
          error.description += 'Could not encode error args: ' + e + "\n";
        }
      }
    }

    return error;
  };
  /**
   * generic request exception handling
   * 
   * NOTE: status codes 9xx are reserved for applications and must not be handled here!
   * 
   * @param {exception|Object} exception
   * @param {Function} callback
   * @param {Object}   callbackScope
   * @param {Function} callbackOnOk
   * @param {Object}   callbackOnOkScope
   */


  var handleRequestException = function handleRequestException(exception, callback, callbackScope, callbackOnOk, callbackOnOkScope) {
    if (!exception.code && exception.responseText) {
      // we need to decode the exception first
      var response = Ext.util.JSON.decode(exception.responseText);
      exception = response.data;
    }

    if (exception.appName != 'Tinebase' && Tine.Tinebase.ExceptionHandlerRegistry.has(exception.appName)) {
      // the registered function must return true to don't work on this generically
      if (Tine.Tinebase.ExceptionHandlerRegistry.get(exception.appName)(exception, callback, callbackScope, callbackOnOk, callbackOnOkScope) === true) {
        return;
      }
    }

    var defaults = {
      buttons: Ext.Msg.OK,
      icon: Ext.MessageBox.WARNING,
      fn: callback,
      scope: callbackScope
    };
    Tine.log.debug('Tine.Tinebase.ExceptionHandler::handleRequestException -> Exception:');
    Tine.log.debug(exception);

    if (Tine.Tinebase.tineInit.isReloading) {
      Tine.log.debug('Tine.Tinebase.ExceptionHandler::handleRequestException -> Exception handling skipped because Tine 2.0 is reloading');
      return;
    } // TODO find a generic way for this, some kind of registry for each app to register sensitive information


    const request = exception.request && Ext.isString(exception.request) ? Ext.util.JSON.decode(exception.request) : exception.request;

    if (request && request.method === 'Felamimail.saveMessage') {
      request.params.recordData.body = null;
      exception.request = Ext.util.JSON.encode(request);
      Tine.log.debug(exception);
    }

    if (!callback) callback = Ext.emptyFn;
    if (!callbackScope) callbackScope = this;

    switch (exception.code) {
      // not authorised
      case 401:
        Tine.Tinebase.tineInit.isReloading = true;
        Tine.Tinebase.tineInit.clearRegistry().then(() => {
          if (!window.isMainWindow) {
            Ext.ux.PopupWindow.close();
            return;
          }

          Tine.Tinebase.common.reload({
            clearCache: true
          });
        });
        break;
      // insufficient rights

      case 403:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Insufficient Rights'),
          msg: exception.message ? Tine[exception.appName].i18n._(exception.message) : i18n._('Sorry, you are not permitted to perform this action'),
          icon: Ext.MessageBox.ERROR
        }));
        break;
      // not found

      case 404:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Not Found'),
          msg: i18n._('Sorry, your request could not be completed because the required data could not be found. In most cases this means that someone already deleted the data. Please refresh your current view.'),
          icon: Ext.MessageBox.ERROR
        }));
        break;
      // concurrency conflict

      case 409:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Concurrent Updates'),
          msg: i18n._('Someone else saved this record while you where editing the data. You need to reload and make your changes again.')
        }));
        break;
      // outdated client

      case 426:
        var version = Tine.Tinebase.registry.set('version', exception.version);
        Tine.Tinebase.tineInit.checkClientVersion();
        break;
      // Service Unavailable!
      // Use this error code for generic problems like misconfig we don't want to see bugreports for

      case 503:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Service Unavailable'),
          msg: i18n._('The server is currently unable to handle the request due to a temporary overloading, maintenance or misconfiguration of the server. Please try again or contact your administrator.')
        }));
        break;
      // invalid record exception

      case 505:
        var message = exception.message ? '<br /><b>' + i18n._('Server Message:') + '</b><br />' + exception.message : '';
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Invalid Data'),
          msg: i18n._('Your input data is not valid. Please provide valid data.') + message
        }));
        break;
      // server communication loss

      case 510:
        // NOTE: when communication is lost, we can't create a nice ext window.
        // NOTE: - reloads/redirects cancel all open xhr requests from the browser side
        //       - we need some way to distinguish server/client connection losses
        //       - the extjs xhr abstraction has no such feature
        //       - so we defer the alert. In case of reload/redirect the deferd fn dosn't get executed
        //         if the new contet/html arrives before the defer time is over.
        //       - this might not always be the case due to network, service or session problems
        (function () {
          alert(i18n._('Connection lost, please check your network!'));
        }).defer(1000);
        break;
      // transaction aborted / timeout

      case 520:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Timeout'),
          msg: i18n._('Sorry, some timeout occured while processing your request. Please reload your browser, try again or contact your administrator.')
        }));
        break;
      // empty response

      case 540:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('No Response'),
          msg: i18n._('Sorry, the Server did not respond any data. Please reload your browser, try again or contact your administrator.')
        }));
        break;
      // memory exhausted

      case 550:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Out of Resources'),
          msg: i18n._('Sorry, the Server stated a "memory exhausted" condition. Please contact your administrator.')
        }));
        break;
      // generic error with message generated on the server

      case 600:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._(exception.title),
          msg: Ext.util.Format.nl2br(i18n._(exception.message))
        }));
        break;
      // user in no role

      case 610:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('No Role Memberships'),
          msg: i18n._('Your user account has no role memberships. Please contact your administrator.')
        }));
        break;
      // area is locked

      case 630:
        Tine.Tinebase.areaLocks.handleAreaLockException(exception);
        break;
      // handle generic confirm

      case 650:
        if (request) {
          let params = request.params;
          params['method'] = request.method;

          if (exception.info) {
            exception.message += '<br />' + exception.info;
          }

          Ext.Msg.confirm(exception.title, exception.message, async function (button) {
            if (button === 'yes') {
              Ext.Ajax.request({
                scope: callbackScope,
                headers: {
                  'X-TINE20-REQUEST-CONTEXT-CONFIRM': true
                },
                params: params,
                success: function success(_result, _request) {
                  Ext.callback(callback, callbackScope);
                },
                failure: function failure(exception) {
                  if (!exception.code && exception.responseText) {
                    // we need to decode the exception first
                    const response = Ext.util.JSON.decode(exception.responseText);
                    exception = response.data;
                    exception.request = Ext.util.JSON.encode(request);
                  }

                  Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
                }
              });
            }
          });
        }

        break;
      // Tinebase_Exception_InvalidRelationConstraints

      case 912:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._(exception.title),
          msg: i18n._(exception.message)
        }));
        break;
      // lost/insufficent permissions for api call or bad api call

      case -32601:
        Ext.MessageBox.show(Ext.apply(defaults, {
          title: i18n._('Method Not Found / Insufficent Permissions'),
          msg: i18n._('You tried to access a function that is not available. Please reload your browser, try again or contact your administrator.')
        }));
        break;
      // generic failure -> notify developers

      default:
        var windowHeight = 400;

        if (Ext.getBody().getHeight(true) * 0.7 < windowHeight) {
          windowHeight = Ext.getBody().getHeight(true) * 0.7;
        }

        if (!Tine.Tinebase.exceptionDlg) {
          Tine.Tinebase.exceptionDlg = new Tine.Tinebase.ExceptionDialog({
            height: windowHeight,
            exception: exception,
            listeners: {
              close: function close() {
                Tine.Tinebase.exceptionDlg = null;
              }
            }
          });
          Tine.Tinebase.exceptionDlg.show();
        }

        break;
    }

    if (Tine.Tinebase.configManager.get('automaticBugreports') && !Tine.Tinebase.exceptionDlg) {
      Tine.log.debug('Tine.Tinebase.ExceptionHandler::handleRequestException -> Activate non-interacive exception dialog.');
      Tine.Tinebase.exceptionDlg = new Tine.Tinebase.ExceptionDialog({
        exception: exception,
        nonInteractive: true,
        listeners: {
          close: function close() {
            Tine.Tinebase.exceptionDlg = null;
          }
        }
      });
      Tine.Tinebase.exceptionDlg.show();
    }
  };

  var handleException = function handleException(exception) {
    exception = getNormalisedError(exception); // for the fast :-)

    Ext.applyIf(exception, {
      code: -1000 // appName: this.app.appName,

    });
    console.error(exception.trace);
    handleRequestException(exception);
  }; // init window error handler


  window.onerror = window.onerror && Ext.isFunction(window.onerror) && Ext.isFunction(window.onerror.createSequence) ? window.onerror.createSequence(onWindowError) : onWindowError;
  window.addEventListener("unhandledrejection", function (promiseRejectionEvent) {
    var error = promiseRejectionEvent.reason; // unhandled from jsonrpcprovider

    if (_.get(error, 'code') && _.get(error, 'data')) {
      handleRequestException(error.data);
    }
  });
  return {
    handleException: handleException,
    handleRequestException: handleRequestException
  };
}();

/***/ }),
/* 1293 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase');
/**
 * @namespace Tine.Tinebase
 * @class Tine.Tinebase.ExceptionHandlerRegistry
 * @singleton
 * 
 * 
 */

Tine.Tinebase.ExceptionHandlerRegistry = function () {
  return {
    items: {},

    /**
     * registers a handler
     * 
     * @param {String} appName
     * @param {Function} handler
     */
    register: function register(appName, handler) {
      this.items[appName] = handler;
    },

    /**
     * returns a handler for an application
     * 
     * @param {String} appName
     * @return {Function}
     */
    get: function get(appName) {
      if (this.items.hasOwnProperty(appName)) {
        return this.items[appName];
      }

      return null;
    },

    /**
     * checks if a application exception handler has been registered already
     * 
     * @param {String} appName
     * @return {Bool}
     */
    has: function has(appName) {
      if (this.items.hasOwnProperty(appName)) {
        return true;
      }

      return false;
    }
  };
}();

/***/ }),
/* 1294 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext, Tine, window*/
Ext.ns('Tine', 'Tine.Tinebase');
/**
 * @namespace  Tine.Tinebase
 * @class      Tine.Tinebase.ExceptionDialog
 * @extends    Ext.Window
 */

Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
  width: 400,
  height: 600,
  xtype: 'panel',
  layout: 'fit',
  plain: true,
  closeAction: 'close',
  autoScroll: true,
  releaseMode: true,

  /**
   * non-interactive mode: do not show anything and just submit the report
   * 
   * @type Boolean
   */
  nonInteractive: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.currentAccount = Tine.Tinebase.registry.get('currentAccount'); // check if we have the version in registry (is not the case in the setup)

    if (!Tine.Tinebase.registry.get('version') || Tine.Tinebase.registry.get('version').buildType != 'RELEASE') {
      this.releaseMode = false;
      this.width = 800;
    }

    var trace = '';

    if (Ext.isArray(this.exception.trace)) {
      for (var i = 0, j = this.exception.trace.length; i < j; i++) {
        trace += (this.exception.trace[i].file ? this.exception.trace[i].file : '[internal function]') + (this.exception.trace[i].line ? '(' + this.exception.trace[i].line + ')' : '') + ': ' + (this.exception.trace[i]['class'] ? '<b>' + this.exception.trace[i]['class'] + this.exception.trace[i].type + '</b>' : '') + '<b>' + this.exception.trace[i]['function'] + '</b>' + '(' + (this.exception.trace[i].args && this.exception.trace[i].args[0] ? this.exception.trace[i].args[0] : '') + ')<br/>';
      }

      this.exception.traceHTML = trace;
    }

    if (Ext.isString(this.exception.trace)) {
      this.exception.traceHTML = Ext.util.Format.nl2br(Ext.util.Format.htmlEncode(this.exception.trace).replace(/ /g, '&nbsp;').replace(/\t/g, '&nbsp;&nbsp;&nbsp;&nbsp;'));
    }

    this.title = i18n._('Abnormal End');
    this.items = this.getReportForm();
    Tine.Tinebase.ExceptionDialog.superclass.initComponent.call(this);
    this.on('show', function () {
      if (this.nonInteractive) {
        Tine.log.debug('Tine.Tinebase.ExceptionDialog::onShow -> Sending bugreport non-interactive ...');
        this.onSendReport();
      } else {
        // fix layout issue
        this.setHeight(this.getHeight() + 10);
      }
    }, this);
    this.on('close', function () {
      if (Tine.Tinebase.configManager.get('automaticBugreports') && !this.nonInteractive) {
        Tine.log.debug('Tine.Tinebase.ExceptionDialog::onCancel -> Activate non-interacive exception dialog.');
        Tine.Tinebase.exceptionDlg = new Tine.Tinebase.ExceptionDialog({
          exception: this.exception,
          nonInteractive: true,
          listeners: {
            close: function close() {
              Tine.Tinebase.exceptionDlg = null;
            }
          }
        });
        Tine.Tinebase.exceptionDlg.show();
      }
    }, this);
  },

  /**
   * use button order based on preference
   * 
   * @private
   * @return {Array}
   */
  initButtons: function initButtons() {
    this.reportButtons = [{
      text: i18n._('Cancel'),
      iconCls: 'action_cancel',
      scope: this,
      handler: function handler() {
        this.close();
      }
    }, {
      text: i18n._('Send Report'),
      iconCls: 'action_saveAndClose',
      enabled: Tine.Tinebase.common.hasRight('report_bugs', 'Tinebase'),
      scope: this,
      handler: this.onSendReport
    }];
    return this.reportButtons;
  },

  /**
   * @private
   */
  getReportForm: function getReportForm() {
    this.initButtons();
    this.reportForm = new Ext.FormPanel({
      id: 'tb-exceptiondialog-frompanel',
      bodyStyle: 'padding:5px;',
      buttonAlign: 'right',
      labelAlign: 'top',
      autoScroll: true,
      buttons: this.reportButtons,
      items: [{
        xtype: 'panel',
        border: false,
        html: '<div class="tb-exceptiondialog-text">' + '<p>' + i18n._('An error occurred, the program ended abnormal.') + '</p>' + '<p>' + i18n._('The last action you made was potentially not performed correctly.') + '</p>' + '<p>' + i18n._('Please help improving this software and notify the vendor. Include a brief description of what you where doing when the error occurred.') + '</p>' + '</div>'
      }, {
        id: 'tb-exceptiondialog-description',
        height: 60,
        xtype: 'textarea',
        fieldLabel: i18n._('Description'),
        name: 'description',
        anchor: '95%',
        readOnly: false
      }, {
        xtype: 'fieldset',
        id: 'tb-exceptiondialog-send-contact',
        anchor: '95%',
        title: i18n._('Send Contact Information'),
        autoHeight: true,
        checkboxToggle: true,
        items: [{
          id: 'tb-exceptiondialog-contact',
          xtype: 'textfield',
          hideLabel: true,
          anchor: '100%',
          name: 'contact',
          value: this.currentAccount ? this.currentAccount.accountFullName + ' ' + this.currentAccount.accountEmailAddress : 'unknown'
        }]
      }, {
        xtype: 'panel',
        width: '95%',
        layout: 'form',
        collapsible: true,
        collapsed: this.releaseMode,
        title: i18n._('Details:'),
        defaults: {
          xtype: 'textfield',
          readOnly: true,
          anchor: '95%'
        },
        html: '<div class="tb-exceptiondialog-details">' + '<p class="tb-exceptiondialog-msg">' + this.exception.message + '</p>' + '<p class="tb-exceptiondialog-trace">' + this.exception.traceHTML + '</p>' + '</div>'
      }]
    });
    return this.reportForm;
  },

  /**
   * send the report to tine20.org bugracker
   * 
   * @private
   */
  onSendReport: function onSendReport() {
    if (!this.nonInteractive) {
      Ext.MessageBox.wait(i18n._('Sending report...'), i18n._('Please wait a moment'));
    }

    var baseUrl = Tine.bugreportUrl;
    var hash = this.generateHash();
    this.exception.msg = this.exception.message;
    this.exception.description = Ext.getCmp('tb-exceptiondialog-description').getValue();
    this.exception.clientVersion = Tine.clientVersion;
    this.exception.serverVersion = Tine.Tinebase.registry.get('version') ? Tine.Tinebase.registry.get('version') : {};

    if (Ext.isArray(this.exception.clientProps)) {
      Ext.each(this.exception.clientProps, function (prop) {
        this.exception[prop] = null;
        delete this.exception[prop];
      }, this);
      delete this.exception['clientProps'];
    } // tinebase version


    Ext.each(Tine.Tinebase.registry.get('userApplications'), function (app) {
      if (app.name == 'Tinebase') {
        this.exception.tinebaseVersion = app;
        return false;
      }
    }, this); // append contact?

    if (!Ext.getCmp('tb-exceptiondialog-send-contact').collapsed) {
      this.exception.contact = Ext.getCmp('tb-exceptiondialog-contact').getValue();
    }

    var ua = navigator.userAgent.toLowerCase(),
        isIE = ua.match(/msie (\d+)/),
        useCOSR = !isIE || isIE[1] > 9;

    if (useCOSR) {
      // NOTE: - we create a new connection to not compromise the json key
      var conn = new Ext.data.Connection();
      conn.request({
        url: baseUrl,
        method: 'POST',
        jsonData: Ext.encode({
          jsonrpc: '2.0',
          method: 'API.reportBug',
          id: ++Ext.Ajax.requestId,
          params: {
            hash: hash,
            exception: this.exception
          }
        })
      });
    } else {
      // NOTE:  - we have about 80 chars overhead (url, paramnames etc) in each request
      //        - 1024 chars are expected to be pass client/server limits savely => 940
      //        - base64 means about 30% overhead => 600
      var chunks = this.strChunk(Ext.util.JSON.encode(this.exception), 600);
      var img = [];

      for (var i = 0; i < chunks.length; i++) {
        var part = i + 1 + '/' + chunks.length;
        var data = {
          data: this.base64encode('hash=' + hash + '&part=' + part + '&data=' + chunks[i])
        };
        var url = baseUrl + '?' + Ext.urlEncode(data);
        img.push(Ext.DomHelper.insertFirst(this.el, {
          tag: 'img',
          src: url,
          hidden: true
        }, true));
      }
    }

    if (!this.nonInteractive) {
      window.setTimeout(this.showTransmissionCompleted, 4000);
    }

    this.close();
  },

  /**
   * @private
   */
  showTransmissionCompleted: function showTransmissionCompleted() {
    Ext.MessageBox.show({
      title: i18n._('Transmission Completed'),
      msg: i18n._('Your report has been sent. Thanks for your contribution') + '<br /><b>' + i18n._('Please restart your browser now!') + '</b>',
      buttons: Ext.MessageBox.OK,
      icon: Ext.MessageBox.INFO
    });
  },

  /**
   * @private
   */
  strChunk: function strChunk(str, chunklen) {
    var chunks = [];
    var numChunks = Math.ceil(str.length / chunklen);

    for (var i = 0; i < str.length; i += chunklen) {
      chunks.push(str.substr(i, chunklen));
    }

    return chunks;
  },

  /**
   * @private
   */
  generateHash: function generateHash() {
    // if the time isn't unique enough, the addition 
    // of random chars should be
    var t = String(new Date().getTime()).substr(4);
    var s = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';

    for (var i = 0; i < 4; i++) {
      t += s.charAt(Math.floor(Math.random() * 26));
    }

    return t;
  },

  /**
   * base 64 encode given string
   * @private
   */
  base64encode: function base64encode(input) {
    var keyStr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
    var output = "";
    var chr1, chr2, chr3, enc1, enc2, enc3, enc4;
    var i = 0;

    while (i < input.length) {
      chr1 = input.charCodeAt(i++);
      chr2 = input.charCodeAt(i++);
      chr3 = input.charCodeAt(i++);
      enc1 = chr1 >> 2;
      enc2 = (chr1 & 3) << 4 | chr2 >> 4;
      enc3 = (chr2 & 15) << 2 | chr3 >> 6;
      enc4 = chr3 & 63;

      if (isNaN(chr2)) {
        enc3 = enc4 = 64;
      } else if (isNaN(chr3)) {
        enc4 = 64;
      }

      output = output + keyStr.charAt(enc1) + keyStr.charAt(enc2) + keyStr.charAt(enc3) + keyStr.charAt(enc4);
    }

    return output;
  }
});

/***/ }),
/* 1295 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.container');
/**
 * Tinebase container class
 * 
 * @todo move container model here
 * 
 * @namespace   Tine.Tinebase.container
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.container = {
  /**
   * type for personal containers
   * 
   * @constant TYPE_PERSONAL
   * @type String
   */
  TYPE_PERSONAL: 'personal',

  /**
   * type for shared container
   * 
   * @constant TYPE_SHARED
   * @type String
   */
  TYPE_SHARED: 'shared',

  /**
   * @private
   *
   * @deprecated
   * @property isLeafRegExp
   * @type RegExp
   */
  isLeafRegExp: /^\/personal\/[0-9a-z_\-]+\/|^\/shared\/.+/i,

  /**
   * @private
   * 
   * @property isPersonalNodeRegExp
   * @type RegExp
   */
  isPersonalNodeRegExp: /^\/personal\/([0-9a-z_\-]+)$/i,

  /**
   * returns the path of the 'my ...' node
   * 
   * @return {String}
   */
  getMyNodePath: function getMyNodePath() {
    return '/personal/' + Tine.Tinebase.registry.get('currentAccount').accountId;
  },

  /**
   * returns the file node path of the 'my ...' node
   * 
   * @return {String}
   */
  getMyFileNodePath: function getMyFileNodePath() {
    return '/personal/' + Tine.Tinebase.registry.get('currentAccount').accountLoginName;
  },

  /**
   * returns true if given path represents a (single) container
   * 
   * NOTE: if path could only be undefined when server send container without path.
   *       This happens only in server json classes which only could return containers
   * NOTE: for virtual paths we can't compute if path represents a container(leaf)
   *       so don't use this function anymore
   *
   * @deprecated
   * @static
   * @param {String} path
   * @return {Boolean}
   */
  pathIsContainer: function pathIsContainer(path) {
    return !Ext.isString(path) || !!path.match(Tine.Tinebase.container.isLeafRegExp);
  },

  /**
   * returns true if given path represents a personal container of current user
   * 
   * @param {String} path
   * @return {Boolean}
   */
  pathIsMyPersonalContainer: function pathIsMyPersonalContainer(path) {
    var regExp = new RegExp('^' + window.lodash.escapeRegExp(Tine.Tinebase.container.getMyNodePath()) + '\/([0-9a-z_\-]+)$');
    var matches = String(path).match(regExp);
    return !!matches;
  },

  /**
   * returns owner id if given path represents an personal _node_
   * 
   * @static
   * @param {String} path
   * @return {String/Boolean}
   */
  pathIsPersonalNode: function pathIsPersonalNode(path) {
    if (!Ext.isString(path)) {
      return false;
    }

    var matches = path.match(Tine.Tinebase.container.isPersonalNodeRegExp);
    return matches ? matches[1] : false;
  },

  /**
   * gets translated container name by path
   * 
   * @static
   * @param {String} path
   * @param {String} containerName
   * @param {String} containersName
   * @return {String}
   */
  path2name: function path2name(path, containerName, containersName) {
    switch (path) {
      case '/':
        return String.format(i18n._('All {0}'), containersName);

      case '/shared':
        return String.format(i18n._('Shared {0}'), containersName);

      case '/personal':
        return String.format(i18n._('Other Users {0}'), containersName);
    }

    if (path === Tine.Tinebase.container.getMyNodePath() || path === Tine.Tinebase.container.getMyFileNodePath()) {
      return String.format(i18n._('My {0}'), containersName);
    }

    return path;
  },

  /**
   * returns container type (personal/shared) of given path
   * 
   * @static
   * @param {String} path
   * @return {String}
   */
  path2type: function path2type(path) {
    var pathParts = Ext.isArray(path) ? path : String(path).split('/');
    return pathParts[1];
  },

  /**
   * get grants model of given container
   *
   * @static
   * @param container
   * @return {Record}
   */
  getGrantsModel: function getGrantsModel(container) {
    var _ = window.lodash,
        containerData = _.isFunction(container.beginEdit) ? container.data : container,
        grantsModelName = _.get(containerData, 'xprops.Tinebase.Container.GrantsModel', containerData.model + 'Grants'),
        grantsModel = Tine.Tinebase.data.RecordMgr.get(grantsModelName);

    return grantsModel || Tine.Tinebase.data.RecordMgr.get(Tine.Tinebase.Model.Grant);
  }
};

/***/ }),
/* 1296 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * Encapsuple string escaping and subsituting methods
 *
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.EncodingHelper
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @singleton
 * @return {string}
 */

Tine.Tinebase.EncodingHelper = {
  /**
   * Encode string
   *
   * @param value
   */
  encode: function encode(value) {
    if (!value) {
      return '';
    }

    value = Ext.util.Format.htmlEncode(value);
    return Ext.util.Format.nl2br(value);
  }
};

/***/ }),
/* 1297 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine, Locale*/
Ext.ns('Tine', 'Tine.Tinebase');
/**
 * static common helpers
 */

Tine.Tinebase.common = {
  /**
   *
   * @param {String} part
   */
  getUrl: function getUrl(part) {
    var pathname = window.location.pathname.replace('index.php', ''),
        hostname = window.location.host,
        protocol = window.location.protocol,
        url;

    switch (part) {
      case 'path':
        url = pathname;
        break;

      case 'full':
      default:
        url = protocol + '//' + hostname + pathname;
        break;
    }

    return url;
  },

  /**
   * reload client
   *
   * @param {Object} options
   *      {Boolean} keepRegistry
   *      {Boolean} clearCache
   *      {Boolean} redirectAlways
   *      {String} redirectUrl
   */
  reload: async function reload(options) {
    options = options || {};

    if (!options.keepRegistry) {
      Tine.Tinebase.tineInit.isReloading = true;
      await Tine.Tinebase.tineInit.clearRegistry();
    }

    if (!options.redirectAlways && options.redirectUrl && options.redirectUrl != '') {
      // redirect only after logout (redirectAlways == false) - we can't wait for the browser here...
      // @todo how can we move that to the server?
      // @see https://github.com/tine20/tine20/issues/6236
      window.setTimeout(function () {
        window.location = options.redirectUrl;
      }, 500);
    } else {
      // give browser some time to clear registry
      window.setTimeout(function () {
        window.location.reload(!!options.clearCache);
      }, 500);
    }
  },
  showDebugConsole: function showDebugConsole() {
    if (!Ext.debug) {
      var head = document.getElementsByTagName("head")[0],
          scriptTag = document.createElement("script");
      scriptTag.setAttribute("src", 'library/ExtJS/src/debug.js');
      scriptTag.setAttribute("type", "text/javascript");
      head.appendChild(scriptTag);
      var scriptEl = Ext.get(scriptTag);
      scriptEl.on('load', function () {
        Ext.log('debug console initialised');
      });
      scriptEl.on('fail', function () {
        Ext.Msg.alert('could not activate debug console');
      });
    } else {
      Ext.log('debug console reactivated');
    }
  },

  /**
   * Returns localised date and time string
   * 
   * @param {mixed} $_iso8601
   * @see Ext.util.Format.date
   * @return {String} localised date and time
   */
  dateTimeRenderer: function dateTimeRenderer($_iso8601, metadata) {
    if (metadata) {
      metadata.css = 'tine-gird-cell-datetime';
    }

    var dateObj = $_iso8601 instanceof Date ? $_iso8601 : Date.parseDate($_iso8601, Date.patterns.ISO8601Long);
    return Ext.util.Format.date(dateObj, Locale.getTranslationData('Date', 'medium') + ' ' + Locale.getTranslationData('Time', 'medium'));
  },

  /**
   * Returns localised date string
   * 
   * @param {mixed} date
   * @see Ext.util.Format.date
   * @return {String} localised date
   */
  dateRenderer: function dateRenderer(date, metadata) {
    if (metadata) {
      metadata.css = metadata.css + ' tine-gird-cell-date';
    }

    var dateObj = date instanceof Date ? date : Date.parseDate(date, Date.patterns.ISO8601Long);
    return Ext.util.Format.date(dateObj, Locale.getTranslationData('Date', 'medium'));
  },

  /**
   * Returns localised number string with two digits if no format is given
   * 
   * @param {Number} v The number to format.
   * @param {String} format The way you would like to format this text.
   * @see Ext.util.Format.number
   * 
   * @return {String} The formatted number.
   */
  floatRenderer: function floatRenderer(v, format) {
    if (!format) {
      // default format by locale and with two decimals
      format = '0' + Tine.Tinebase.registry.get('thousandSeparator') + '000' + Tine.Tinebase.registry.get('decimalSeparator') + '00';
    }

    return Ext.util.Format.number(v, format);
  },

  /**
   * Renders a float or integer as percent
   * 
   * @param {Number} v The number to format.
   * @see Ext.util.Format.number
   * 
   * @return {String} The formatted number.
   */
  percentRenderer: function percentRenderer(v, type) {
    if (!Ext.isNumber(v)) {
      v = 0;
    }

    v = Ext.util.Format.number(v, type == 'float' ? '0.00' : '0');

    if (type == 'float') {
      var decimalSeparator = Tine.Tinebase.registry.get('decimalSeparator');

      if (decimalSeparator == ',') {
        v = v.replace(/\./, ',');
      }
    }

    return v + ' %';
  },

  /**
   * Returns localised time string
   * 
   * @param {mixed} date
   * @see Ext.util.Format.date
   * @return {String} localised time
   */
  timeRenderer: function timeRenderer(date, metadata) {
    if (metadata) {
      metadata.css = 'tine-gird-cell-time';
    }

    var dateObj = date instanceof Date ? date : Date.parseDate(date, Date.patterns.ISO8601Long);
    return Ext.util.Format.date(dateObj, Locale.getTranslationData('Time', 'medium'));
  },

  /**
   * renders bytes for filesize 
   * @param {Integer} value
   * @param {Object} metadata
   * @param {Tine.Tinebase.data.Record} record
   * @param {Integer} decimals
   * @param {Boolean} useDecimalValues
   * @return {String}
   */
  byteRenderer: function byteRenderer(value, metadata, record, decimals, useDecimalValues) {
    if (isNaN(parseInt(value, 10))) {
      return '';
    }

    return Tine.Tinebase.common.byteFormatter(value, null, decimals, useDecimalValues);
  },

  /**
   * format byte values
   * @param {String} value
   * @param {Boolean} forceUnit
   * @param {Integer} decimals
   * @param {Boolean} useDecimalValues
   */
  byteFormatter: function byteFormatter(value, forceUnit, decimals, useDecimalValues) {
    value = parseInt(value, 10);
    decimals = Ext.isNumber(decimals) ? decimals : 2;
    var decimalSeparator = Tine.Tinebase.registry.get('decimalSeparator'),
        suffix = ['Bytes', 'Bytes', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
        divisor = useDecimalValues ? 1000 : 1024;

    if (forceUnit) {
      var i = suffix.indexOf(forceUnit);
      i = i == -1 ? 0 : i;
    } else {
      for (var i = 0, j; i < suffix.length; i++) {
        if (value < Math.pow(divisor, i)) break;
      }
    }

    value = (i <= 1 ? value : Ext.util.Format.round(value / Math.pow(divisor, Math.max(1, i - 1)), decimals)) + ' ' + suffix[i];
    return String(value).replace('.', decimalSeparator);
  },

  /**
   * Returns rendered tags for grids
   * 
   * @param {mixed} tags
   * @return {String} tags as colored squares with qtips
   * 
   * TODO add style for tag divs
   */
  tagsRenderer: function tagsRenderer(tags) {
    var result = '';

    if (tags) {
      for (var i = 0; i < tags.length; i += 1) {
        if (tags[i] && tags[i].name) {
          var qtipText = Tine.Tinebase.common.doubleEncode(tags[i].name);

          if (tags[i].description) {
            qtipText += ' | ' + Tine.Tinebase.common.doubleEncode(tags[i].description);
          }

          if (tags[i].occurrence) {
            qtipText += ' (' + i18n._('Usage:&#160;') + tags[i].occurrence + ')';
          }

          result += '<div ext:qtip="' + qtipText + '" class="tb-grid-tags" style="background-color:' + (tags[i].color ? tags[i].color : '#fff') + ';">&#160;</div>';
        }
      }
    }

    return result;
  },

  /**
   * render single tag
   * 
   * @param {Tine.Tinebase.Model.Tag} tag
   */
  tagRenderer: function tagRenderer(tag) {
    if (!Tine.Tinebase.common.tagRenderer.tpl) {
      Tine.Tinebase.common.tagRenderer.tpl = new Ext.XTemplate('<div class="tb-grid-tags" style="background-color:{values.color};">&#160;</div>', '<div class="x-widget-tag-tagitem-text" ext:qtip="', '{[this.encode(values.name)]}', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</i>&nbsp;[{occurrence}]', '<tpl if="description != null && description.length &gt; 1"><hr>{[this.encode(values.description)]}</tpl>" >', '&nbsp;{[this.encode(values.name)]}', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</div>', {
        encode: function encode(value) {
          if (value) {
            return Tine.Tinebase.common.doubleEncode(value);
          } else {
            return '';
          }
        }
      }).compile();
    }

    var result = i18n._('No Information');

    if (tag && Ext.isFunction(tag.beginEdit)) {
      // support records
      tag = tag.data;
    } else if (arguments[2] && Ext.isFunction(arguments[2].beginEdit)) {
      // support grid renderers
      tag = arguments[2].data;
    } // non objects are treated as ids and -> No Information


    if (Ext.isObject(tag)) {
      result = Tine.Tinebase.common.tagRenderer.tpl.apply(tag);
    }

    return result;
  },

  /**
   * Returns rendered containers
   * 
   * @TODO show qtip with grants
   * 
   * @param {mixed} container
   * @return {String} 
   */
  containerRenderer: function containerRenderer(container, metaData) {
    // lazy init tempalte
    if (!Tine.Tinebase.common.containerRenderer.tpl) {
      Tine.Tinebase.common.containerRenderer.tpl = new Ext.XTemplate('<div class="x-tree-node-leaf x-unselectable file">', '<img class="x-tree-node-icon" unselectable="on" src="', Ext.BLANK_IMAGE_URL, '">', '<span style="color: {color};">&nbsp;&#9673;&nbsp</span>', '<span> ', '{name}', '</span>', '</div>').compile();
    }

    var result = i18n._('No Information'); // support container records


    if (container && Ext.isFunction(container.beginEdit)) {
      container = container.data;
    } // non objects are treated as ids and -> No Information


    if (Ext.isObject(container)) {
      var name = Ext.isFunction(container.beginEdit) ? container.get('name') : container.name,
          color = Ext.isFunction(container.beginEdit) ? container.get('color') : container.color;

      if (name) {
        result = Tine.Tinebase.common.containerRenderer.tpl.apply({
          name: Ext.util.Format.htmlEncode(name).replace(/ /g, "&nbsp;"),
          color: color ? color : '#808080'
        });
      } else if (Ext.isObject(metaData)) {
        metaData.css = 'x-form-empty-field';
      }
    }

    return result;
  },

  /**
   * Returns rendered relations
   *
   * @param {mixed} container
   * @return {String}
   *
   * TODO use/invent renderer registry to show more information on relations
   */
  relationsRenderer: function relationsRenderer(relations, metaData) {
    // _('No Access') - we need this string in other apps if relation is not shown e.g. record_removed_reason
    var result = '';

    if (relations) {
      for (var i = 0; i < relations.length; i += 1) {
        if (relations[i]) {
          var qtipText = Tine.Tinebase.common.doubleEncode(relations[i].type);
          result += '<div ext:qtip="' + qtipText + '" class="tb-grid-tags" style="background-color:white"' + ';">&#160;</div>';
        }
      }
    }

    return result;
  },

  /**
   * Returns prettyfied minutes
   * 
   * @param  {Number} minutes
   * @param  {String} format -> {0} will be replaced by Hours, {1} with minutes
   * @param  {String} leadingZeros add leading zeros for given item {i|H}
   * @return {String}
   */
  minutesRenderer: function minutesRenderer(minutes, format, leadingZeros) {
    var s,
        i = minutes % 60,
        H = Math.floor(minutes / 60),
        Hs;

    if (leadingZeros && (Ext.isString(leadingZeros) || leadingZeros === true)) {
      if (leadingZeros === true || leadingZeros.match(/i/) && String(i).length === 1) {
        i = '0' + String(i);
      }

      if (leadingZeros === true || leadingZeros.match(/H/) && String(H).length === 1) {
        H = '0' + String(H);
      }
    }

    if (!format || !Ext.isString(format)) {
      s = String.format(i18n.ngettext('{0} minute', '{0} minutes', i), i);
      Hs = String.format(i18n.ngettext('{0} hour', '{0} hours', H), H); //var ds = String.format(i18n.ngettext('{0} workday', '{0} workdays', d), d);

      if (i === 0) {
        s = Hs;
      } else {
        s = H ? Hs + ', ' + s : s;
      } //s = d ? ds + ', ' + s : s;


      return s;
    }

    return String.format(format, H, i);
  },

  /**
   * Returns prettyfied seconds
   * 
   * @param  {Number} seconds
   * @return {String}
   */
  secondsRenderer: function secondsRenderer(seconds) {
    var s = seconds % 60,
        m = Math.floor(seconds / 60),
        result = '';
    var secondResult = String.format(i18n.ngettext('{0} second', '{0} seconds', s), s);

    if (m) {
      result = Tine.Tinebase.common.minutesRenderer(m);
    }

    if (s) {
      if (result !== '') {
        result += ', ';
      }

      result += secondResult;
    }

    return result;
  },

  /**
   * Returns the formated username
   * 
   * @param {object} account object 
   * @return {string} formated user display name
   */
  usernameRenderer: function usernameRenderer(accountObject) {
    var result = accountObject ? accountObject.accountDisplayName : '';
    return Ext.util.Format.htmlEncode(result);
  },

  /**
   * Returns a username or groupname with according icon in front
   */
  accountRenderer: function accountRenderer(accountObject, metadata, record, rowIndex, colIndex, store) {
    if (!accountObject) {
      return '';
    }

    var _ = window.lodash,
        type,
        iconCls,
        displayName,
        email;

    if (accountObject.accountDisplayName) {
      type = _.get(record, 'data.account_type', 'user');
      displayName = accountObject.accountDisplayName; // need to create a "dummy" app to call featureEnabled()
      // TODO: should be improved

      var tinebaseApp = new Tine.Tinebase.Application({
        appName: 'Tinebase'
      });

      if (tinebaseApp.featureEnabled('featureShowAccountEmail') && accountObject.accountEmailAddress) {
        // add email address if available
        email = accountObject.accountEmailAddress;
        displayName += ' (' + email + ')';
      }
    } else if (accountObject.name && !_.get(record, 'data.account_type')) {
      type = 'group';
      displayName = accountObject.name;
    } else if (record && record.data.name) {
      type = record.data.type;
      displayName = record.data.name; // so odd, - new records, picked via pickerGridPanel
    } else if (record && record.data.account_name) {
      type = record.data.account_type;
      displayName = _.get(record, 'data.account_name.name', record.data.account_name);
    }

    if (displayName == 'Anyone') {
      displayName = i18n._(displayName);
      type = 'group';
    }

    iconCls = 'tine-grid-row-action-icon renderer renderer_account' + Ext.util.Format.capitalize(type) + 'Icon';
    return '<div class="' + iconCls + '">&#160;</div>' + Ext.util.Format.htmlEncode(displayName || '');
  },

  /**
   * Returns account type icon
   * 
   * @return String
   */
  accountTypeRenderer: function accountTypeRenderer(type) {
    var iconCls = 'tine-grid-row-action-icon ' + (type === 'user' ? 'renderer_accountUserIcon' : 'renderer_accountGroupIcon');
    return '<div style="background-position: 0px" class="' + iconCls + '">&#160;</div>';
  },

  /**
   * Returns dropdown hint icon for editor grid columns with comboboxes
   * 
   * @return String
   */
  cellEditorHintRenderer: function cellEditorHintRenderer(value) {
    return '<div style="position:relative">' + value + '<div class="tine-grid-cell-hint">&#160;</div></div>';
  },

  /**
   * return yes or no in the selected language for a boolean value
   * 
   * @param {string} value
   * @return {string}
   */
  booleanRenderer: function booleanRenderer(value) {
    var translationString = String.format("{0}", Boolean(value) && value !== "0" ? Locale.getTranslationData('Question', 'yes') : Locale.getTranslationData('Question', 'no'));
    return translationString.substr(0, translationString.indexOf(':'));
  },

  /**
   * i18n renderer
   *
   * NOTE: needs to be bound to i18n object!
   *
   * renderer: Tine.Tinebase.common.i18nRenderer.createDelegate(this.app.i18n)
   * @param original
   */
  i18nRenderer: function i18nRenderer(original) {
    return this._hidden(original);
  },

  /**
   * color renderer
   *
   * @param color
   */
  colorRenderer: function colorRenderer(color) {
    // normalize
    color = String(color).replace('#', '');
    return '<div style="background-color: #' + Ext.util.Format.htmlEncode(color) + '">&#160;</div>';
  },

  /**
   * foreign record renderer
   *
   * @param record
   * @param metadata
   *
   * TODO use title fn? allow to configure displayed field(s)?
   */
  foreignRecordRenderer: function foreignRecordRenderer(record, metaData) {
    return record && record.name ? record.name : '';
  },

  /**
   * sorts account/user objects
   * 
   * @param {Object|String} user_id
   * @return {String}
   */
  accountSortType: function accountSortType(user_id) {
    if (user_id && user_id.accountDisplayName) {
      return user_id.accountDisplayName;
    } else if (user_id && user_id.n_fileas) {
      return user_id.n_fileas;
    } else if (user_id && user_id.name) {
      return user_id.name;
    } else {
      return user_id;
    }
  },

  /**
   * sorts records
   * 
   * @param {Object} record
   * @return {String}
   */
  recordSortType: function recordSortType(record) {
    if (record && Ext.isFunction(record.getTitle)) {
      return record.getTitle();
    } else if (record && record.id) {
      return record.id;
    } else {
      return record;
    }
  },

  /**
   * check whether given value can be interpreted as true
   * 
   * @param {String|Integer|Boolean} value
   * @return {Boolean}
   */
  isTrue: function isTrue(value) {
    return value === 1 || value === '1' || value === true || value === 'true';
  },

  /**
   * check whether object is empty (has no property)
   * 
   * @param {Object} obj
   * @return {Boolean}
   */
  isEmptyObject: function isEmptyObject(obj) {
    for (var name in obj) {
      if (obj.hasOwnProperty(name)) {
        return false;
      }
    }

    return true;
  },

  /**
   * clone function
   * 
   * @param {Object/Array} o Object or array to clone
   * @return {Object/Array} Deep clone of an object or an array
   */
  clone: function clone(o) {
    if (!o || 'object' !== typeof o) {
      return o;
    }

    if ('function' === typeof o.clone) {
      return o.clone();
    }

    var c = '[object Array]' === Object.prototype.toString.call(o) ? [] : {},
        p,
        v;

    for (p in o) {
      if (o.hasOwnProperty(p)) {
        v = o[p];

        if (v && 'object' === typeof v) {
          c[p] = Tine.Tinebase.common.clone(v);
        } else {
          c[p] = v;
        }
      }
    }

    return c;
  },

  /**
   * assert that given object is comparable
   * 
   * @param {mixed} o
   * @return {mixed} o
   */
  assertComparable: function assertComparable(o) {
    // NOTE: Ext estimates Object/Array by a toString operation
    if (Ext.isObject(o) || Ext.isArray(o)) {
      Tine.Tinebase.common.applyComparableToString(o);
    }

    return o;
  },

  /**
   * apply Ext.encode as toString functino to given object
   * 
   * @param {mixed} o
   */
  applyComparableToString: function applyComparableToString(o) {
    o.toString = function () {
      return Ext.encode(o);
    };
  },

  /**
   * check if user has right to view/manage this application/resource
   * 
   * @param   {String}      right (view, admin, manage)
   * @param   {String}      application
   * @param   {String}      resource (for example roles, accounts, ...)
   * @returns {Boolean} 
   */
  hasRight: function hasRight(right, application, resource) {
    if (!(Tine && Tine[application] && Tine[application].registry && Tine[application].registry.get('rights'))) {
      if (Tine.Tinebase.tineInit.isReloading) {
        Tine.log.info('Tine 2.0 is reloading ...');
      } else if (!Tine.Tinebase.appMgr) {
        console.error('Tine.Tinebase.appMgr not yet available');
      } else if (Tine.Tinebase.appMgr.get(application)) {
        console.error('Tine.' + application + '.rights is not available, initialisation Error! Reloading app.'); // reload registry/mainscreen - registry problem?

        Tine.Tinebase.common.reload({});
      }

      return false;
    }

    var userRights = Tine[application].registry.get('rights'),
        allAppRights = Tine[application].registry.get('allrights');

    if (allAppRights && right === 'view' && allAppRights.indexOf('view') < 0) {
      // switch to run as app has no view right
      right = 'run';
    }

    var result = false;

    for (var i = 0; i < userRights.length; i += 1) {
      if (userRights[i] === 'admin') {
        result = true;
        break;
      }

      if (right === 'view' && (userRights[i] === 'view_' + resource || userRights[i] === 'manage_' + resource)) {
        result = true;
        break;
      }

      if (right === 'manage' && userRights[i] === 'manage_' + resource) {
        result = true;
        break;
      }

      if (right === userRights[i]) {
        result = true;
        break;
      }
    }

    return result;
  },

  /**
   * returns random integer number
   * @param {Integer} min
   * @param {Integer} max
   * @return {Integer}
   */
  getRandomNumber: function getRandomNumber(min, max) {
    if (min > max) {
      return -1;
    }

    if (min === max) {
      return min;
    }

    return min + parseInt(Math.random() * (max - min + 1), 10);
  },

  /**
   * HTML-encodes a string twice
   * @param {String} value
   * @return {String}
   */
  doubleEncode: function doubleEncode(value) {
    return Ext.util.Format.htmlEncode(Ext.util.Format.htmlEncode(value));
  },

  /**
   * simple html to text conversion
   *
   * @param html
   * @returns {String}
   */
  html2text: function html2text(html) {
    const text = html.replace(/\n/g, ' ').replace(/(<br[^>]*>)/g, '\n--br').replace(/(<li[^>]*>)/g, '\n * ').replace(/<(blockquote|div|dl|dt|dd|form|h1|h2|h3|h4|h5|h6|hr|p|pre|table|tr|td|li|section|header|footer)[^>]*>(?!\s*\<\/\1\>)/g, '\n--block').replace(/<style(.+?)\/style>/g, '').replace(/<(.+?)>/g, '').replace(/&nbsp;/g, ' ').replace(/--block(\n--block)+/g, '--block').replace(/--block\n--br/g, '').replace(/(--block|--br)/g, '');
    return Ext.util.Format.htmlDecode(text);
  },

  /**
   * linkify text
   *
   * @param {String} text
   * @param {Ext.Element|Function} cb
   */
  linkifyText: function linkifyText(text, cb, scope) {
    __webpack_require__.e(/* require.ensure | Tinebase/js/linkify */ 43).then((function () {
      const linkifyHtml = __webpack_require__(686);

      let linkifyed = linkifyHtml(text);

      if (Ext.isFunction(cb)) {
        cb.call(scope || window, linkifyed);
      } else {
        cb.update(linkifyed);
      }
    }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
  },

  /**
   * linkify text
   *
   * @param {String} text
   * @param {Ext.Element|Function} cb
   */
  findEmail: function findEmail(text, cb, scope) {
    return text.match(/([a-zA-Z0-9._-]+@[a-zA-Z0-9._-]+\.[a-zA-Z0-9._-]+)/gi);
  },

  /**
   * Confirm application restart
   *
   * @param Boolean closewindow
   */
  confirmApplicationRestart: function confirmApplicationRestart(closewindow) {
    Ext.Msg.confirm(i18n._('Confirm'), i18n._('Restart application to apply new configuration?'), function (btn) {
      if (btn == 'yes') {
        // reload mainscreen to make sure registry gets updated
        Tine.Tinebase.common.reload();

        if (closewindow) {
          window.close();
        }
      }
    }, this);
  },

  /**
   * Math.trunc polyfill
   *
   * https://developer.mozilla.org/de/docs/Web/JavaScript/Reference/Global_Objects/Math/trunc
   *
   * @param x
   * @return {*}
   */
  trunc: function trunc(x) {
    if (isNaN(x)) {
      return NaN;
    }

    if (x > 0) {
      return Math.floor(x);
    }

    return Math.ceil(x);
  },

  /**
   * check valid email domain (if email domain is set in config)
   *
   * @param {String} email
   * @return {Boolean}
   */
  checkEmailDomain: function checkEmailDomain(email) {
    const allowedDomains = this.getAllowedDomains();

    if (!email || !allowedDomains) {
      if (!email) {
        Tine.log.debug('Tine.Tinebase.common.checkEmailDomain - no mail given');
      }

      return true;
    }

    Tine.log.debug('Tine.Tinebase.common.checkEmailDomain - email: ' + email);
    const emailDomain = email.split('@')[1];
    return allowedDomains.indexOf(emailDomain) !== -1;
  },
  getAllowedDomains: function getAllowedDomains() {
    if (!Tine.Tinebase.registry.get('primarydomain')) {
      Tine.log.debug('Tine.Tinebase.common.checkEmailDomain - no primarydomain config found');
      return null;
    }

    let allowedDomains = [Tine.Tinebase.registry.get('primarydomain')];

    if (Ext.isString(Tine.Tinebase.registry.get('secondarydomains'))) {
      allowedDomains = allowedDomains.concat(Tine.Tinebase.registry.get('secondarydomains').split(','));
    }

    if (Ext.isString(Tine.Tinebase.registry.get('additionaldomains'))) {
      allowedDomains = allowedDomains.concat(Tine.Tinebase.registry.get('additionaldomains').split(','));
    }

    Tine.log.debug('Tine.Tinebase.common.checkEmailDomain - allowedDomains:');
    Tine.log.debug(allowedDomains);
    return allowedDomains;
  },
  getMimeIconCls: function getMimeIconCls(mimeType) {
    return 'mime-content-type-' + mimeType.replace(/\/.*$/, '') + ' mime-suffix-' + (mimeType.match(/\+/) ? mimeType.replace(/^.*\+/, '') : 'none') + ' mime-type-' + mimeType.replace(/\//g, '-slash-').replace(/\./g, '-dot-').replace(/\+/g, '-plus-');
  }
};
/*
var s = '<blockquote class="felamimail-body-blockquote"><div>Hello,</div><div><br></div><div>...</div></blockquote>';
if (Tine.Tinebase.common.html2text(s) != "\nHello,\n\n...") console.error('ignore empty div: "' + Tine.Tinebase.common.html2text(s) + '"');

var s = '<font face="tahoma, arial, helvetica, sans-serif" style="font-size: 11px; font-family: tahoma, arial, helvetica, sans-serif;"><span style="font-size: 11px;">​<font color="#808080">Dipl.-Phys. Cornelius Weiss</font></span></font><div style="font-size: 11px; font-family: tahoma, arial, helvetica, sans-serif;"><font face="tahoma, arial, helvetica, sans-serif" color="#808080"><span style="font-size: 11px;">Team Leader Software Engineering</span></font></div>';
if (Tine.Tinebase.common.html2text(s) != "​Dipl.-Phys. Cornelius Weiss\nTeam Leader Software Engineering") console.error('cope with styled div tag: '  + Tine.Tinebase.common.html2text(s));

var s = '<div><div><span><font><br></font></span></div></div>';
if (Tine.Tinebase.common.html2text(s) != "\n") console.error('cope with nested blocks: "' + Tine.Tinebase.common.html2text(s) + '"');
*/

/***/ }),
/* 1298 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2012-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * central config
 */

Tine.Tinebase.configManager = function () {
  return {
    get: function get(name, appName) {
      var registry = appName && Tine[appName] ? Tine[appName].registry : Tine.Tinebase.registry,
          config = registry ? registry.get('config') : false,
          pathParts = String(name).split('.'),
          path = pathParts.join('.value.') + (pathParts.length == 1 ? '.value' : '');
      return lodash.get(config, path);
    },
    set: function set(name, value, appName) {
      var registry = appName && Tine[appName] ? Tine[appName].registry : Tine.Tinebase.registry,
          config = (registry ? registry.get('config') : false) || {},
          pathParts = String(name).split('.'),
          path = pathParts.join('.value.') + (pathParts.length == 1 ? '.value' : '');
      lodash.set(config, path, value);
      registry.set('config', config);
    }
  };
}();

/***/ }),
/* 1299 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');

__webpack_require__(608);

__webpack_require__(609);

__webpack_require__(1300);
/**
 * central renderer manager
 * - get renderer for a given field
 * - register renderer for a given field
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.RendererManager
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @singleton
 */


Tine.widgets.grid.RendererManager = function () {
  var renderers = {};
  return {
    /**
     * const for category gridPanel
     */
    CATEGORY_GRIDPANEL: 'gridPanel',

    /**
     * const for category displayPanel
     */
    CATEGORY_DISPLAYPANEL: 'displayPanel',

    /**
     * default renderer - quote content
     */
    defaultRenderer: function defaultRenderer(value) {
      return value ? Ext.util.Format.htmlEncode(value) : '';
    },

    /**
     * get renderer of well known field names
     * 
     * @param {String} fieldName
     * @return Function/null
     */
    getByFieldname: function getByFieldname(fieldName) {
      var renderer = null;

      if (fieldName == 'tags') {
        renderer = Tine.Tinebase.common.tagsRenderer;
      } else if (fieldName == 'notes') {
        // @TODO
        renderer = function renderer(value) {
          return value ? i18n._('has notes') : '';
        };
      } else if (fieldName == 'relations') {
        renderer = Tine.Tinebase.common.relationsRenderer;
      } else if (fieldName == 'customfields') {// @TODO
        // we should not come here!
      } else if (fieldName == 'container_id') {
        renderer = Tine.Tinebase.common.containerRenderer;
      } else if (fieldName == 'attachments') {
        renderer = Tine.widgets.grid.attachmentRenderer;
      } else if (fieldName == 'color') {
        renderer = Tine.Tinebase.common.colorRenderer;
      }

      return renderer;
    },

    /**
     * get renderer by data type
     *
     * @param {String} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {boolean} cf
     * @return {Function}
     */
    getByDataType: function getByDataType(appName, modelName, fieldName, cf = false) {
      if (!cf) {
        var renderer = null,
            recordClass = Tine.Tinebase.data.RecordMgr.get(appName, modelName),
            field = recordClass ? recordClass.getField(fieldName) : null,
            fieldDefinition = _.get(field, 'fieldDefinition', field),
            fieldType = fieldDefinition ? fieldDefinition.type : 'auto';
      }

      switch (fieldType) {
        case 'record':
          if (Tine.Tinebase.common.hasRight('view', fieldDefinition.config.appName, fieldDefinition.config.modelName.toLowerCase())) {
            renderer = function renderer(value, row, record) {
              var foreignRecordClass = Tine[fieldDefinition.config.appName].Model[fieldDefinition.config.modelName];

              if (foreignRecordClass) {
                const record = Tine.Tinebase.data.Record.setFromJson(value, foreignRecordClass);
                const titleProperty = foreignRecordClass.getMeta('titleProperty');
                value = _.isFunction(_.get(record, 'getTitle')) ? record.getTitle() : _.get(record, titleProperty, '');

                if (!!+_.get(record, 'data.is_deleted')) {
                  value = '<span style="text-decoration: line-through;">' + value + '</span>';
                }
              }

              return value;
            };
          } else {
            renderer = null;
          }

          break;

        case 'integer':
        case 'float':
          if (fieldDefinition.hasOwnProperty('specialType')) {
            switch (fieldDefinition.specialType) {
              case 'bytes1000':
                renderer = function renderer(value, cell, record) {
                  return Tine.Tinebase.common.byteRenderer(value, cell, record, 2, true);
                };

                break;

              case 'bytes':
                renderer = function renderer(value, cell, record) {
                  return Tine.Tinebase.common.byteRenderer(value, cell, record, 2, false);
                };

                break;

              case 'minutes':
                renderer = Tine.Tinebase.common.minutesRenderer;
                break;

              case 'seconds':
                renderer = Tine.Tinebase.common.secondsRenderer;
                break;

              case 'percent':
                renderer = function renderer(value, cell, record) {
                  return Tine.Tinebase.common.percentRenderer(value, fieldDefinition.type);
                };

                break;

              case 'durationSec':
                renderer = function renderer(value, cell, record) {
                  return Ext.ux.form.DurationSpinner.durationRenderer(value, {
                    baseUnit: 'seconds'
                  });
                };

                break;

              default:
                renderer = Ext.util.Format.htmlEncode;
            }

            renderer = renderer.createSequence(function (value, metadata, record) {
              if (metadata) {
                metadata.css = 'tine-gird-cell-number';
              }
            });
          }

          break;

        case 'user':
          renderer = Tine.Tinebase.common.usernameRenderer;
          break;

        case 'keyfield':
        case 'keyField':
          renderer = Tine.Tinebase.widgets.keyfield.Renderer.get(appName, _.get(fieldDefinition, 'keyFieldConfigName', fieldDefinition.name));
          break;

        case 'datetime_separated_date':
        case 'date':
          renderer = Tine.Tinebase.common.dateRenderer;
          break;

        case 'datetime':
          renderer = Tine.Tinebase.common.dateTimeRenderer;
          break;

        case 'time':
          renderer = Tine.Tinebase.common.timeRenderer;
          break;

        case 'tag':
          renderer = Tine.Tinebase.common.tagsRenderer;
          break;

        case 'container':
          renderer = Tine.Tinebase.common.containerRenderer;
          break;

        case 'boolean':
          renderer = Tine.Tinebase.common.booleanRenderer;
          break;

        case 'money':
          if (fieldDefinition.hasOwnProperty('specialType')) {
            if (fieldDefinition.specialType === 'zeroMoney') {
              // if this option is set, zero values are hidden in the grid
              renderer = function renderer(value) {
                return Ext.util.Format.money(value, {
                  zeroMoney: true
                });
              };

              break;
            }
          }

          renderer = Ext.util.Format.money;
          break;

        case 'attachments':
          renderer = Tine.widgets.grid.attachmentRenderer;
          break;

        case 'image':
          renderer = Tine.widgets.grid.imageRenderer;
          break;

        case 'json':
          renderer = Tine.widgets.grid.jsonRenderer;
          break;

        case 'relation':
          let cc = fieldDefinition.config;

          if (cc && cc.type && cc.appName && cc.modelName) {
            let rendererObj = new Tine.widgets.relation.GridRenderer({
              appName: appName,
              type: cc.type,
              foreignApp: cc.appName,
              foreignModel: cc.modelName
            });
            renderer = _.bind(rendererObj.render, rendererObj);
            break;
          }

          break;

        case 'hexcolor':
          renderer = Tine.Tinebase.common.colorRenderer;
          break;

        case 'model':
          renderer = (classname, metaData, record) => {
            const recordClass = Tine.Tinebase.data.RecordMgr.get(classname);
            return recordClass ? recordClass.getRecordName() : classname;
          };

          break;

        case 'dynamicRecord':
          const classNameField = fieldDefinition.config.refModelField;

          renderer = (configRecord, metaData, record) => {
            const configRcordClass = Tine.Tinebase.data.RecordMgr.get(record.get(classNameField));
            return Tine.Tinebase.data.Record.setFromJson(configRecord, configRcordClass).getTitle();
          };

          break;

        case 'records':
        case 'recodList': //@Todo add records/list renderer!

      }

      return renderer;
    },

    /**
     * returns renderer for given field
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {gridPanel|displayPanel} optional.
     * @return {Function}
     */
    get: function get(appName, modelName, fieldName, category) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]); // check for registered renderer

      var renderer = renderers[categoryKey] ? renderers[categoryKey] : renderers[genericKey]; // check for common names

      if (!renderer) {
        renderer = this.getByFieldname(fieldName);
      } // check for known datatypes


      if (!renderer) {
        renderer = this.getByDataType(appName, modelName, fieldName, String(fieldName).match(/^#.+/));
      }

      if (!renderer && String(fieldName).match(/^#.+/)) {
        var cfConfig = Tine.widgets.customfields.ConfigManager.getConfig(appName, modelName, fieldName.replace(/^#/, ''));
        renderer = Tine.widgets.customfields.Renderer.get(appName, cfConfig);
      }

      return renderer ? renderer : this.defaultRenderer;
    },

    /**
     * register renderer for given field
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {Function} renderer
     * @param {String} category {gridPanel|displayPanel} optional.
     * @param {Object} scope to call renderer in, optional.
     */
    register: function register(appName, modelName, fieldName, renderer, category, scope) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]);
      renderers[category ? categoryKey : genericKey] = scope ? renderer.createDelegate(scope) : renderer;
    },

    /**
     * check if a renderer is explicitly registered
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @param {Record/String} modelName
     * @param {String} fieldName
     * @param {String} category {gridPanel|displayPanel} optional.
     * @return {Boolean}
     */
    has: function has(appName, modelName, fieldName, category) {
      var appName = this.getAppName(appName),
          modelName = this.getModelName(modelName),
          categoryKey = this.getKey([appName, modelName, fieldName, category]),
          genericKey = this.getKey([appName, modelName, fieldName]); // check for registered renderer

      return (renderers[categoryKey] ? renderers[categoryKey] : renderers[genericKey]) ? true : false;
    },

    /**
     * returns the modelName by modelName or record
     * 
     * @param {Record/String} modelName
     * @return {String}
     */
    getModelName: function getModelName(modelName) {
      return Ext.isFunction(modelName) ? modelName.getMeta('modelName') : modelName;
    },

    /**
     * returns the modelName by appName or application instance
     * 
     * @param {String/Tine.Tinebase.Application} appName
     * @return {String}
     */
    getAppName: function getAppName(appName) {
      return Ext.isString(appName) ? appName : appName.appName;
    },

    /**
     * returns a key by joining the array values
     * 
     * @param {Array} params
     * @return {String}
     */
    getKey: function getKey(params) {
      return params.join('_');
    }
  };
}();

/***/ }),
/* 1300 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2019 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');

Tine.widgets.grid.jsonRenderer = function (value, metadata, record) {
  var result = Ext.isString(value) ? value : JSON.stringify(value);
  return Tine.widgets.grid.jsonRenderer.syntaxHighlight(result);
};

Tine.widgets.grid.jsonRenderer.displayField = function (value) {
  var result = Ext.isString(value) ? value : JSON.stringify(value, undefined, 4);
  return Tine.widgets.grid.jsonRenderer.syntaxHighlight(result);
};

Tine.widgets.grid.jsonRenderer.syntaxHighlight = function (json) {
  json = String(json).replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;');
  return json.replace(/("(\\u[a-zA-Z0-9]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)/g, function (match) {
    var cls = 'number';

    if (/^"/.test(match)) {
      if (/:$/.test(match)) {
        cls = 'key';
      } else {
        cls = 'string';
      }
    } else if (/true|false/.test(match)) {
      cls = 'boolean';
    } else if (/null/.test(match)) {
      cls = 'null';
    }

    return '<span class="' + cls + '">' + match + '</span>';
  });
};

/***/ }),
/* 1301 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.Model');
/**
 * @type {Array}
 * 
 * modlog Fields
 */

Tine.Tinebase.Model.modlogFields = [{
  name: 'creation_time',
  type: 'date',
  dateFormat: Date.patterns.ISO8601Long,
  omitDuplicateResolving: true
}, {
  name: 'created_by',
  omitDuplicateResolving: true
}, {
  name: 'last_modified_time',
  type: 'date',
  dateFormat: Date.patterns.ISO8601Long,
  omitDuplicateResolving: true
}, {
  name: 'last_modified_by',
  omitDuplicateResolving: true
}, {
  name: 'is_deleted',
  type: 'boolean',
  omitDuplicateResolving: true
}, {
  name: 'deleted_time',
  type: 'date',
  dateFormat: Date.patterns.ISO8601Long,
  omitDuplicateResolving: true
}, {
  name: 'deleted_by',
  omitDuplicateResolving: true
}, {
  name: 'seq',
  omitDuplicateResolving: true
}];
/**
 * @type {Array}
 * generic Record fields
 */

Tine.Tinebase.Model.genericFields = Tine.Tinebase.Model.modlogFields.concat([{
  name: 'container_id',
  header: 'Container',
  omitDuplicateResolving: false
}]);
/**
 * Model of a language
 */

Tine.Tinebase.Model.Language = Ext.data.Record.create([{
  name: 'locale'
}, {
  name: 'language'
}, {
  name: 'region'
}]);
/**
 * Model of a timezone
 */

Tine.Tinebase.Model.Timezone = Ext.data.Record.create([{
  name: 'timezone'
}, {
  name: 'timezoneTranslation'
}]);
/**
 * Model of a role
 */

Tine.Tinebase.Model.Role = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'name'
}, {
  name: 'description'
}], {
  appName: 'Tinebase',
  modelName: 'Role',
  idProperty: 'id',
  titleProperty: 'name',
  recordName: 'Role',
  recordsName: 'Roles'
});
/**
 * Model of a generalised account (user or group)
 */

Tine.Tinebase.Model.Account = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'type'
}, {
  name: 'name'
}, {
  name: 'data'
} // todo: throw away data
], {
  appName: 'Tinebase',
  modelName: 'Account',
  idProperty: 'id',
  titleProperty: 'name'
});
/**
 * Model of a container
 */

Tine.Tinebase.Model.Container = Tine.Tinebase.data.Record.create(Tine.Tinebase.Model.modlogFields.concat([{
  name: 'id'
}, {
  name: 'name'
}, {
  name: 'hierarchy'
}, {
  name: 'type'
}, {
  name: 'backend'
}, {
  name: 'order'
}, {
  name: 'color'
}, {
  name: 'application_id'
}, {
  name: 'owner_id'
}, {
  name: 'model'
}, {
  name: 'uuid'
}, {
  name: 'content_seq'
}, {
  name: 'account_grants'
}, {
  name: 'path'
}, {
  name: 'xprops'
}, // virtual
{
  name: 'ownerContact'
}, {
  name: 'is_container_node',
  type: 'boolean'
}, {
  name: 'dtselect',
  type: 'number'
}]), {
  appName: 'Tinebase',
  modelName: 'Container',
  idProperty: 'id',
  titleProperty: 'name'
});
/**
 * Model of a grant
 */

Tine.Tinebase.Model.Grant = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'record_id'
}, {
  name: 'account_id'
}, {
  name: 'account_type'
}, {
  name: 'account_name',
  sortType: Tine.Tinebase.common.accountSortType
}, {
  name: 'freebusyGrant',
  type: 'boolean'
}, {
  name: 'readGrant',
  type: 'boolean'
}, {
  name: 'addGrant',
  type: 'boolean'
}, {
  name: 'editGrant',
  type: 'boolean'
}, {
  name: 'deleteGrant',
  type: 'boolean'
}, {
  name: 'privateGrant',
  type: 'boolean'
}, // TODO app specific (ADB) grant definition is currently needed here - make it work without
{
  name: 'privateDataGrant',
  type: 'boolean'
}, {
  name: 'exportGrant',
  type: 'boolean'
}, {
  name: 'syncGrant',
  type: 'boolean'
}, {
  name: 'downloadGrant',
  type: 'boolean'
}, {
  name: 'publishGrant',
  type: 'boolean'
}, {
  name: 'adminGrant',
  type: 'boolean'
}], {
  appName: 'Tinebase',
  modelName: 'Grant',
  idProperty: 'id',
  titleProperty: 'account_name',
  // ngettext('Grant', 'Grants', n); gettext('Grant');
  recordName: 'Grant',
  recordsName: 'Grants'
});
/**
 * Model of a tag
 * 
 * @constructor {Tine.Tinebase.data.Record}
 */

Tine.Tinebase.Model.Tag = Tine.Tinebase.data.Record.create(Tine.Tinebase.Model.modlogFields.concat([{
  name: 'id'
}, {
  name: 'app'
}, {
  name: 'owner'
}, {
  name: 'name'
}, {
  name: 'type'
}, {
  name: 'description'
}, {
  name: 'color'
}, {
  name: 'system_tag'
}, {
  name: 'occurrence'
}, {
  name: 'rights'
}, {
  name: 'contexts'
}, {
  name: 'selection_occurrence',
  type: 'number'
}]), {
  appName: 'Tinebase',
  modelName: 'Tag',
  idProperty: 'id',
  titleProperty: 'name',
  // ngettext('Tag', 'Tags', n); gettext('Tag');
  recordName: 'Tag',
  recordsName: 'Tags'
});
/**
 * replace template fields with data
 * @static
 */

Tine.Tinebase.Model.Tag.replaceTemplateField = function (tagData) {
  if (Ext.isArray(tagData)) {
    return Ext.each(tagData, Tine.Tinebase.Model.Tag.replaceTemplateField);
  }

  if (Ext.isFunction(tagData.beginEdit)) {
    tagData = tagData.data;
  }

  var replace = {
    'CURRENTDATE': Tine.Tinebase.common.dateRenderer(new Date()),
    'CURRENTTIME': Tine.Tinebase.common.timeRenderer(new Date()),
    'USERFULLNAME': Tine.Tinebase.registry.get('currentAccount').accountDisplayName
  };
  Ext.each(['name', 'description'], function (field) {
    for (var token in replace) {
      if (replace.hasOwnProperty(token) && Ext.isString(tagData[field])) {
        tagData[field] = tagData[field].replace(new RegExp('###' + token + '###', 'g'), replace[token]);
      }
    }
  }, this);
};
/**
 * Model of a PickerRecord
 * 
 * @constructor {Ext.data.Record}
 * 
 * @deprecated
 */


Tine.Tinebase.PickerRecord = Ext.data.Record.create([{
  name: 'id'
}, {
  name: 'name'
}, {
  name: 'data'
}]);
/**
 * Model of a note
 * 
 * @constructor {Ext.data.Record}
 */

Tine.Tinebase.Model.Note = Ext.data.Record.create([{
  name: 'id'
}, {
  name: 'note_type_id'
}, {
  name: 'note'
}, {
  name: 'creation_time',
  type: 'date',
  dateFormat: Date.patterns.ISO8601Long
}, {
  name: 'created_by'
}]);
/**
 * Model of a note type
 * 
 * @constructor {Ext.data.Record}
 */

Tine.Tinebase.Model.NoteType = Ext.data.Record.create([{
  name: 'id'
}, {
  name: 'name'
}, {
  name: 'icon'
}, {
  name: 'icon_class'
}, {
  name: 'description'
}, {
  name: 'is_user_type'
}]);
/**
 * Model of a customfield definition
 */

Tine.Tinebase.Model.Customfield = Ext.data.Record.create([{
  name: 'id'
}, {
  name: 'application_id'
}, {
  name: 'model'
}, {
  name: 'name'
}, {
  name: 'definition'
}, {
  name: 'account_grants'
}]);
/**
 * Model of a customfield value
 */

Tine.Tinebase.Model.CustomfieldValue = Ext.data.Record.create([{
  name: 'record_id'
}, {
  name: 'customfield_id'
}, {
  name: 'value'
}]);
/**
 * Model of a preference
 * 
 * @constructor {Ext.data.Record}
 */

Tine.Tinebase.Model.Preference = Ext.data.Record.create([{
  name: 'id'
}, {
  name: 'name'
}, {
  name: 'value'
}, {
  name: 'type'
}, {
  name: 'label'
}, {
  name: 'description'
}, {
  name: 'personal_only',
  type: 'boolean'
}, {
  name: 'locked',
  type: 'boolean'
}, {
  name: 'uiconfig'
}, {
  name: 'options'
}]);
/**
 * Model of an alarm
 * 
 * @constructor {Ext.data.Record}
 */

Tine.Tinebase.Model.Alarm = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'record_id'
}, {
  name: 'model'
}, {
  name: 'alarm_time',
  type: 'date',
  dateFormat: Date.patterns.ISO8601Long
}, {
  name: 'minutes_before',
  sortType: Ext.data.SortTypes.asInt
}, {
  name: 'sent_time',
  type: 'date',
  dateFormat: Date.patterns.ISO8601Long
}, {
  name: 'sent_status'
}, {
  name: 'sent_message'
}, {
  name: 'options'
}], {
  appName: 'Tinebase',
  modelName: 'Alarm',
  idProperty: 'id',
  titleProperty: 'minutes_before',
  // ngettext('Alarm', 'Alarms', n); gettext('Alarm');
  recordName: 'Alarm',
  recordsName: 'Alarms',
  getOption: function getOption(name) {
    var encodedOptions = this.get('options'),
        options = encodedOptions ? Ext.decode(encodedOptions) : {};
    return options[name];
  },
  setOption: function setOption(name, value) {
    var encodedOptions = this.get('options'),
        options = encodedOptions ? Ext.decode(encodedOptions) : {};
    options[name] = value;
    this.set('options', Ext.encode(options));
  }
});
/**
 * @namespace Tine.Tinebase.Model
 * @class     Tine.Tinebase.Model.ImportJob
 * @extends   Tine.Tinebase.data.Record
 * 
 * Model of an import job
 */

Tine.Tinebase.Model.ImportJob = Tine.Tinebase.data.Record.create([{
  name: 'files'
}, {
  name: 'import_definition_id'
}, {
  name: 'model'
}, {
  name: 'import_function'
}, {
  name: 'container_id'
}, {
  name: 'dry_run'
}, {
  name: 'options'
}], {
  appName: 'Tinebase',
  modelName: 'Import',
  idProperty: 'id',
  titleProperty: 'model',
  // ngettext('Import', 'Imports', n); gettext('Import');
  recordName: 'Import',
  recordsName: 'Imports'
});
/**
 * @namespace Tine.Tinebase.Model
 * @class     Tine.Tinebase.Model.ExportJob
 * @extends   Tine.Tinebase.data.Record
 * 
 * Model of an export job
 */

Tine.Tinebase.Model.ExportJob = Tine.Tinebase.data.Record.create([{
  name: 'scope'
}, {
  name: 'filter'
}, {
  name: 'definitionId'
}, {
  name: 'format'
}, {
  name: 'exportFunction'
}, {
  name: 'recordsName'
}, {
  name: 'model'
}, {
  name: 'returnFileLocation'
}, {
  name: 'count',
  type: 'int'
}, {
  name: 'options'
}], {
  appName: 'Tinebase',
  modelName: 'Export',
  idProperty: 'id',
  titleProperty: 'model',
  // ngettext('Export', 'Export', n); gettext('Export');
  recordName: 'Export',
  recordsName: 'Exports'
});
/**
 * @namespace Tine.Tinebase.Model
 * @class     Tine.Tinebase.Model.Credentials
 * @extends   Tine.Tinebase.data.Record
 * 
 * Model of user credentials
 */

Tine.Tinebase.Model.Credentials = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'username'
}, {
  name: 'password'
}], {
  appName: 'Tinebase',
  modelName: 'Credentials',
  idProperty: 'id',
  titleProperty: 'username',
  // ngettext('Credentials', 'Credentials', n); gettext('Credentials');
  recordName: 'Credentials',
  recordsName: 'Credentials'
});
/**
 * @namespace Tine.Tinebase.Model
 * @class     Tine.Tinebase.Model.Relation
 * @extends   Tine.Tinebase.data.Record
 * 
 * Model of a Relation
 */

Tine.Tinebase.Model.Relation = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'own_model'
}, {
  name: 'own_id'
}, {
  name: 'related_model'
}, {
  name: 'related_id'
}, {
  name: 'type'
}, {
  name: 'remark'
}, {
  name: 'related_record',
  sortType: Tine.Tinebase.common.recordSortType
}, {
  name: 'creation_time'
}], {
  appName: 'Tinebase',
  modelName: 'Relation',
  idProperty: 'id',
  titleProperty: 'related_model',
  // ngettext('Relation', 'Relations', n); gettext('Relation');
  recordName: 'Relation',
  recordsName: 'Relations'
});
/**
 * find duplicate relation in store
 *
 * @param store
 * @param record
 * @return int index in store
 */

Tine.Tinebase.Model.Relation.findDuplicate = function (store, record) {
  return store.findBy(function (r) {
    return r.get('related_model') == record.get('related_model') && r.get('related_id') == record.get('related_id') && r.get('type') == record.get('type');
  }, this);
};
/**
 * @namespace Tine.Tinebase.Model
 * @class     Tine.Tinebase.Model.Department
 * @extends   Tine.Tinebase.data.Record
 * 
 * Model of a Department
 */


Tine.Tinebase.Model.Department = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'name'
}, {
  name: 'description'
}], {
  appName: 'Tinebase',
  modelName: 'Department',
  idProperty: 'id',
  titleProperty: 'name',
  // ngettext('Department', 'Departments', n); gettext('Department');
  recordName: 'Department',
  recordsName: 'Departments'
});

Tine.Tinebase.Model.Department.getFilterModel = function () {
  return [{
    label: i18n._('Name'),
    field: 'name',
    operators: ['contains']
  }];
};
/**
 * @namespace Tine.Tinebase.Model
 * @class     Tine.Tinebase.Model.Config
 * @extends   Tine.Tinebase.data.Record
 * 
 * Model of a application config settings
 */


Tine.Tinebase.Model.Config = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'application_id'
}, {
  name: 'name'
}, {
  name: 'value'
}, {
  name: 'label'
}, {
  name: 'description'
}, {
  name: 'type'
}, {
  name: 'clientRegistryInclude'
}, {
  name: 'setByAdminModule'
}, {
  name: 'setBySetupModule'
}, {
  name: 'default'
}, {
  name: 'source'
} //{name: 'settings'}
], {
  appName: 'Tinebase',
  modelName: 'Config',
  idProperty: 'id',
  titleProperty: 'name',
  // ngettext('Config', 'Configs', n); gettext('Configs');
  recordName: 'Config',
  recordsName: 'Configs'
});
Tine.widgets.grid.RendererManager.register('Tinebase', 'Tree_Node', 'size', Tine.Tinebase.common.byteRenderer);
Tine.widgets.grid.RendererManager.register('Tinebase', 'Tree_Node', 'revision_size', Tine.Tinebase.common.byteRenderer);
Tine.Tinebase.Model.KeyFieldRecord = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'value'
}, {
  name: 'i18nValue'
}, {
  name: 'icon'
}, {
  name: 'color'
}, {
  name: 'system'
}], {
  appName: 'Tinebase',
  modelName: 'KeyFieldRecord',
  idProperty: 'id',
  titleProperty: 'value'
});
Tine.Tinebase.Model.Path = Tine.Tinebase.data.Record.create([{
  name: 'id'
}, {
  name: 'path'
}, {
  name: 'shadow_path'
}, {
  name: 'creation_time'
}], {
  appName: 'Tinebase',
  modelName: 'Path',
  idProperty: 'id',
  titleProperty: 'path' // defaultFilter: 'path'

});

Tine.Tinebase.Model.Path.getFilterModel = function () {
  return [{
    label: i18n._('Query'),
    field: 'query',
    operators: ['contains']
  }, {
    label: i18n._('Path'),
    field: 'path',
    operators: ['contains']
  }];
};

/***/ }),
/* 1302 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.keyfield');
/**
 * key field store
 * 
 * @namespace   Tine.Tinebase.widgets.keyfield
 * @param       {Object} config
 * @constructor
 */

Tine.Tinebase.widgets.keyfield.Store = function (config) {
  // init app
  config.app = Ext.isString(config.app) ? Tine.Tinebase.appMgr.get(config.app) : config.app; // get keyField config

  if (config.app.getRegistry()) {
    if (!config.keyFieldConfig) {
      config.keyFieldConfig = config.app.getRegistry().get('config')[config.keyFieldName];
    } // init data / translate values


    var data = config.keyFieldConfig && config.keyFieldConfig.value && config.keyFieldConfig.value.records && config.keyFieldConfig.value.records.length ? config.keyFieldConfig.value.records : [];
    Ext.each(data, function (d) {
      d.i18nValue = d.value ? config.app.i18n._hidden(d.value) : "";
      d.id = String(d.id);
    });
    config.data = data;
  }

  if (!config.keyFieldConfig) {
    throw 'No keyfield config found for ' + config.keyFieldName + ' in ' + config.app.appName + ' registry.';
  }

  var modelName = config.keyFieldConfig.definition && config.keyFieldConfig.definition.options && config.keyFieldConfig.definition.options.recordModel ? config.keyFieldConfig.definition.options.recordModel : "Tinebase_Model_KeyFieldRecord",
      recordClass = Tine.Tinebase.data.RecordMgr.get(modelName) || Tine.Tinebase.Model.KeyFieldRecord,
      fields = [].concat(recordClass.getFieldDefinitions()); // add 'virtual' field

  fields.push({
    name: 'i18nValue'
  });
  this.recordClass = Ext.data.Record.create(fields);
  config.fields = this.recordClass;
  Tine.Tinebase.widgets.keyfield.Store.superclass.constructor.call(this, config);
};
/**
 * @namespace   Tine.Tinebase.widgets.keyfield
 * @class       Tine.Tinebase.widgets.keyfield.Store
 * @extends     Ext.data.JsonStore
 */


Ext.extend(Tine.Tinebase.widgets.keyfield.Store, Ext.data.JsonStore, {
  /**
   * @cfg {String/Application} app
   */
  app: null,

  /**
   * @cfg {String} keyFieldName 
   * name of key field
   */
  keyFieldName: null,

  /**
   * @property keyFieldConfig
   * @type Object
   */
  keyFieldConfig: null
});
/**
 * manages key field stores
 * 
 * @namespace   Tine.Tinebase.widgets.keyfield
 * @class       Tine.Tinebase.widgets.keyfield.StoreMgr
 * @singleton
 */

Tine.Tinebase.widgets.keyfield.StoreMgr = function () {
  return {
    /**
     * returns key field record store
     * 
     * @param {String/Application} app
     * @param {String} keyFieldName 
     * @return Ext.data.Store
     */
    get: function get(app, keyFieldName) {
      var appName = Ext.isString(app) ? app : app.appName;
      return new Tine.Tinebase.widgets.keyfield.Store({
        app: app,
        keyFieldName: keyFieldName
      });
    },
    has: function has(app, keyFieldName) {
      var store;

      try {
        store = this.get(app, keyFieldName);
      } catch (e) {}

      return !!store;
    }
  };
}();

/***/ }),
/* 1303 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.keyfield');
/**
 * key field combo
 * 
 * @namespace   Tine.Tinebase.widgets.keyfield
 * @class       Tine.Tinebase.widgets.keyfield.ComboBox
 * @extends     Ext.form.ComboBox
 */

Tine.Tinebase.widgets.keyfield.ComboBox = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {String/Application} app
   */
  app: null,

  /**
   * @cfg {String} keyFieldName 
   * name of key field
   */
  keyFieldName: null,

  /**
   * @cfg {Boolean} showIcon
   * show icon in list and value
   */
  showIcon: true,

  /**
   * sort by a field
   * 
   * @cfg {String} sortBy
   */
  sortBy: null,

  /* begin config */
  blurOnSelect: true,
  expandOnFocus: true,
  mode: 'local',
  displayField: 'i18nValue',
  valueField: 'id',
  forceSelection: true,

  /* end config */
  initComponent: function initComponent() {
    this.app = Ext.isString(this.app) ? Tine.Tinebase.appMgr.get(this.app) : this.app; // get keyField config

    this.keyFieldConfig = this.app.getRegistry().get('config')[this.keyFieldName];
    var definition = this.keyFieldConfig.definition,
        options = definition && definition.options || {};
    this.parentField = options.parentField;

    if (!this.value && !this.parentField && this.keyFieldConfig && Ext.isObject(this.keyFieldConfig.value) && this.keyFieldConfig.value.hasOwnProperty('default')) {
      this.value = this.keyFieldConfig.value['default'];
    }

    this.store = Tine.Tinebase.widgets.keyfield.StoreMgr.get(this.app, this.keyFieldName);

    if (this.sortBy) {
      this.store.sort(this.sortBy);
    }

    this.showIcon = this.showIcon && this.store.find('icon', /^.+$/) > -1;
    this.initTpl();
    this.on('afterrender', this.onAfterRender, this, {
      buffer: 50
    });
    Tine.Tinebase.widgets.keyfield.ComboBox.superclass.initComponent.call(this);
  },
  initTpl: function initTpl() {
    if (this.showIcon) {
      this.tpl = '<tpl for="."><div class="x-combo-list-item"><img src="{icon}" class="tine-keyfield-icon"/>{' + this.displayField + '}</div></tpl>';
    }
  },
  onAfterRender: function onAfterRender() {
    if (this.parentField) {
      var formPanel = this.findParentBy(function (c) {
        return Ext.isFunction(c.getForm);
      }),
          form = formPanel ? formPanel.getForm() : null,
          parentField = form ? form.findField(this.parentField) : null;

      if (parentField) {
        parentField.setValue = parentField.setValue.createSequence(this.applyParentValue, this);
        this.applyParentValue(parentField.getValue());
      }
    }
  },
  applyParentValue: function applyParentValue(parentValue) {
    this.store.filter('id', parentValue);
    var parentRe = new RegExp('^' + window.lodash.escapeRegExp(parentValue)),
        defaultValues = this.keyFieldConfig && Ext.isObject(this.keyFieldConfig.value) && this.keyFieldConfig.value.hasOwnProperty('default') ? this.keyFieldConfig.value['default'] : false,
        defaultValue = ''; // apply default if current value is not appropriate

    if (!String(this.getValue()).match(parentRe)) {
      Ext.each(defaultValues, function (candidate) {
        if (String(candidate).match(parentRe)) {
          defaultValue = candidate;
          return false;
        }
      }, this);
      this.setValue(defaultValue);
    }
  },
  doQuery: function doQuery() {
    this.onLoad();
  }
});
Ext.reg('widget-keyfieldcombo', Tine.Tinebase.widgets.keyfield.ComboBox);

/***/ }),
/* 1304 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.keyfield');
/**
 * manages key field renderers
 * 
 * @namespace   Tine.Tinebase.widgets.keyfield
 * @class       Tine.Tinebase.widgets.keyfield.Renderer
 * @singleton
 */

Tine.Tinebase.widgets.keyfield.Renderer = function () {
  var renderers = {};
  return {
    /**
     * returns key field record renderer
     * 
     * @param {String/Application}  app
     * @param {String}              keyFieldName 
     * @param {String}              what pipe seperated field with text|icon
     * @return Ext.data.Store
     */
    get: function get(app, keyFieldName, what) {
      try {
        var appName = Ext.isString(app) ? app : app.appName,
            app = Tine.Tinebase.appMgr.get(appName),
            store = Tine.Tinebase.widgets.keyfield.StoreMgr.get(app, keyFieldName),
            what = what ? what : 'text|icon',
            whatParts = what.split('|'),
            key = appName + keyFieldName + what;
      } catch (e) {
        Tine.log.error(e);
      }

      if (!renderers[key]) {
        renderers[key] = function (id) {
          if (!id) return "";
          var record = store.getById(id),
              i18nValue = record ? record.get('i18nValue') : app.i18n._hidden(id),
              icon = record ? record.get('icon') : null,
              string = '';

          if (whatParts.indexOf('icon') > -1 && icon) {
            string = string + '<img src="' + icon + '" class="tine-keyfield-icon" ext:qtip="' + Ext.util.Format.htmlEncode(i18nValue) + '" />';
          }

          if (whatParts.indexOf('text') > -1 && i18nValue) {
            string = string + Ext.util.Format.htmlEncode(i18nValue);
          }

          return string;
        };
      }

      return renderers[key];
    },

    /**
     * render a given value
     * 
     * @param {String/Application}  app
     * @param {String}              keyFieldName 
     * @return Ext.data.Store
     */
    render: function render(app, keyFieldName, id) {
      var renderer = this.get(app, keyFieldName);
      return renderer(id);
    },

    /**
     * register a custom renderer
     * 
     * @param {String/Application}  app
     * @param {String}              keyFieldName 
     * @param {Function}            renderer
     */
    register: function register(app, keyFieldName, renderer) {
      var appName = Ext.isString(app) ? app : app.appName,
          key = appName + '_' + keyFieldName;
      renderers[key] = renderer;
    }
  };
}();

/***/ }),
/* 1305 */
/***/ (function(module, exports) {

/**
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets');
/**
 * lang chooser widget
 *
 * @namespace   Tine.widgets
 * @class       Tine.widgets.LangChooser
 * @extends     Ext.form.ComboBox
 */

Tine.widgets.LangChooser = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {Sring}
   */
  fieldLabel: null,
  displayField: 'language',
  valueField: 'locale',
  triggerAction: 'all',
  editable: false,
  width: 100,
  listWidth: 200,
  initComponent: function initComponent() {
    this.value = Tine.Tinebase.registry.get('locale').language;
    this.fieldLabel = this.fieldLabel ? this.fieldLabel : i18n._('Language');
    this.tpl = new Ext.XTemplate('<tpl for=".">' + '<div class="x-combo-list-item">' + '{language} <tpl if="region.length &gt; 1">{region}</tpl> [{locale}]' + '</div>' + '</tpl>', {
      encode: function encode(value) {
        return Ext.util.Format.htmlEncode(value);
      }
    });
    this.store = new Ext.data.JsonStore({
      id: 'locale',
      root: 'results',
      totalProperty: 'totalcount',
      fields: Tine.Tinebase.Model.Language,
      baseParams: {
        method: 'Tinebase.getAvailableTranslations'
      }
    });
    Tine.widgets.LangChooser.superclass.initComponent.call(this);
    this.on('select', this.onLangSelect, this);
  },
  onLangSelect: function onLangSelect(combo, localeRecord, idx) {
    var currentLocale = Tine.Tinebase.registry.get('locale').locale;
    var newLocale = localeRecord.get('locale');

    if (newLocale !== currentLocale) {
      Ext.MessageBox.wait(i18n._('Setting new language...'), i18n._('Please Wait'));
      Ext.Ajax.request({
        scope: this,
        params: {
          method: 'Tinebase.setLocale',
          localeString: newLocale,
          saveaspreference: true,
          setcookie: true
        },
        success: function success(result, request) {
          if (window.google && google.gears && google.gears.localServer) {
            var pkgStore = google.gears.localServer.openStore('tine20-package-store');

            if (pkgStore) {
              google.gears.localServer.removeStore('tine20-package-store');
            }
          }

          window.location.reload(true);
        }
      });
    }
  }
});
Ext.reg('tinelangchooser', Tine.widgets.LangChooser);

/***/ }),
/* 1306 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine', 'Tine.widgets');
/**
 * get a fresh set of actions
 *
 * NOTE: An Action is a piece of reusable functionality that can be abstracted
 * out of any particular component so that it can be usefully shared among
 * multiple components. Actions let you share handlers, configuration options
 * and UI updates across any components that support the Action interface
 * (primarily Ext.Toolbar, Ext.Button and Ext.menu.Menu components).
 *
 * NOTE: Using the same action multiple times requires a shared selection model
 *       a) action toolbar is valid for grid selections (and maybe tree selections
 *          and state). So the actions can't be shared with context menus!
 *       b) context menus for grid/tree have different selection mechanisms
 *          i) selected - when the item the context menu was issued on is
 *             part of the current tree/grid selection the context actions
 *             are updated with the current selection and have to be applied
 *             on all selected items
 *         ii) context - when the item the context menu was issued on is
 *             not part of the current grid/tree selection the context actions
 *             are updated with the single underlaying item and have to be applied
 *             to the underlaying item only.
 *          as only one context menu is visible at a time, it's ok to share
 *          actions in context menus, as they are updated with the selection
 *          before the menu is shown.
 *
 *
 * NOTE: Each action should have an action updater - even to apply initial sate.
 *       The action updater runs every time the selection/scope for the action changes.
 *
 * IMPORTANT: it's in the responsibility of the component which created the action
 *       to update it!
 *
 * NOTE: consumers don't directly listen to events fired by the event handlers
 *       all communication is done via the message bus or uploadManager
 *       @TODO rethink: do we need events/callbacks for e.g. for window close?
 *       @TODO do the consumers need something like 'opener'?
 */

Tine.widgets.ActionManager = function (config) {
  Ext.apply(this, config);
};

Tine.widgets.ActionManager.prototype = {
  /**
   * @cfg {Object} actionConfigs
   */
  actionConfigs: null,
  getConfig: function getConfig(type) {
    var _ = window.lodash,
        name = _.upperFirst(type);

    return _.get(this.actionConfigs, name);
  },

  /**
   * check if actionConfigs for type is available
   *
   * @param {String}
   * @return {Bool}
   */
  has: function has(type) {
    return !!this.getConfig(type);
  },

  /**
   * get new action by actionType
   *
   * @param {String} type
   * @param {Object} config
   * @returns {Ext.Action}
   */
  get: function get(type, config) {
    var _ = window.lodash;

    if (_.isArray(type)) {
      return _.map(type, _.bind(this.get, this, _, config));
    }

    config = config || {}; // NOTE: we copy shared config into a new object to avoid "static" properties
    //       in the instances

    Ext.applyIf(config, this.getConfig(type));

    if (_.isString(config.app)) {
      config.app = Tine.Tinebase.appMgr.get(config.app);
    }

    if (!config.translationObject && config.app) {
      config.translationObject = config.app.i18n;
    }

    if (config.translationObject && config.text) {
      config.text = config.translationObject._hidden(config.text);
    } // NOTE: an Ext.Action can't be extended :-(


    var action = new Ext.Action(config);
    action.initialConfig.scope = action;

    if (_.isFunction(action.initialConfig.init)) {
      action.initialConfig.init.call(action.initialConfig);
    }

    return action;
  }
};

/***/ }),
/* 1307 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine', 'Tine.widgets');

Tine.widgets.ActionUpdater = function (config) {
  config = config || {};
  var actions = config.actions || [];
  config.actions = [];
  Ext.apply(this, config);

  if (this.recordClass && Ext.isFunction(this.recordClass.getMeta)) {
    this.grantsPath = this.recordClass.getMeta('grantsPath');
  }

  this.addActions(actions);
};

Tine.widgets.ActionUpdater.prototype = {
  /**
   * @cfg {Array|Toolbar} actions
   * all actions to update
   */
  actions: null,

  /**
   * @cfg {Bool} evalGrants
   * should grants of a grant-aware records be evaluated (defaults to true)
   */
  evalGrants: true,
  recordClass: null,
  grantsPath: null,

  /**
   * add actions to update
   * @param {Array|Toolbar} actions
   */
  addActions: function addActions(actions, explicitUpdaterOnly) {
    if (Ext.isArray(actions)) {
      for (var i = 0; i < actions.length; i++) {
        this.addAction(actions[i], explicitUpdaterOnly);
      }
    } else if (Ext.isFunction(actions.each)) {
      actions.each(action => {
        this.addAction(action, explicitUpdaterOnly);
      });
    } else if (Ext.isObject(actions)) {
      for (var action in actions) {
        this.addAction(actions[action], explicitUpdaterOnly);
      }
    }
  },

  /**
   * add a single action to update
   * @param {Ext.Action} action
   */
  addAction: function addAction(action, explicitUpdaterOnly) {
    // register action once only!
    if (!action || this.actions.indexOf(action) >= 0) {
      return;
    } // if action has to initialConfig it's no Ext.Action!


    if (action.initialConfig) {
      if (!explicitUpdaterOnly || _.isFunction(_.get(action, 'initialConfig.actionUpdater'))) {
        // in some cases our actionUpdater config is not in the initial config
        // this happens for direct extensions of button class, like the notes button
        if (action.requiredGrant) {
          Ext.applyIf(action.initialConfig, {
            requiredGrant: action.requiredGrant,
            actionUpdater: action.actionUpdater,
            allowMultiple: action.allowMultiple,
            singularText: action.singularText,
            pluralText: action.pluralText,
            translationObject: action.translationObject,
            selections: []
          });
        }

        this.actions.push(action);
      }

      if (action.initialConfig.menu) {
        this.addActions(action.initialConfig.menu.items ? action.initialConfig.menu.items : action.initialConfig.menu, explicitUpdaterOnly);
      }
    } // e.g. btngroup 


    if (action.items && action.constructor !== Ext.Action) {
      // add only those actions having an explicit actionUpdater (to stay backward compatible)
      this.addActions(action.items, true);
    }
  },

  /**
   * performs the actual update
   * @param {Array|SelectionModel} records
   * @param {Array|Tine.Tinebase.Model.Container} container
   */
  updateActions: function updateActions(records, container) {
    records = records || [];
    var isFilterSelect = false,
        selectionModel = null;

    if (typeof records.getSelections == 'function') {
      isFilterSelect = records.isFilterSelect;
      selectionModel = records;
      records = records.getSelections() || [];
    } else if (typeof records.beginEdit == 'function') {
      records = [records];
    }

    var grants = this.getGrantsSum(records);
    this.each(function (action) {
      // action updater opt-in fn has precedence over generic action updater!
      var actionUpdater = action.actionUpdater || action.initialConfig.actionUpdater;

      if (typeof actionUpdater == 'function') {
        var scope = action.scope || action.initialConfig.scope || window;
        actionUpdater.call(scope, action, grants, records, isFilterSelect, container);
      } else {
        this.defaultUpdater(action, grants, records, isFilterSelect, container);
      } // reference selection into action


      action.initialConfig.selections = records;
      action.initialConfig.isFilterSelect = isFilterSelect;
      action.initialConfig.selectionModel = selectionModel;
    }, this);
  },

  /**
   * default action updater
   * 
   * - sets disabled status based on grants and required grant
   * - sets disabled status based on allowMutliple
   * - sets action text (signular/plural text)
   * 
   * @param {Ext.Action} action
   * @param {Object} grants
   * @param {Object} records
   * @param {Boolean} isFilterSelect
   */
  defaultUpdater: function defaultUpdater(action, grants, records, isFilterSelect) {
    var nCondition = records.length != 0 && (records.length > 1 ? action.initialConfig.allowMultiple : true),
        mCondition = records && records.length > 1,
        grantCondition = !this.evalGrants || grants[action.initialConfig.requiredGrant]; // @todo discuss if actions are only to be touched if requiredGrant is set

    if (action.initialConfig.requiredGrant && action.initialConfig.requiredGrant != 'addGrant') {
      action.setDisabled(!(grantCondition && nCondition));
    } // disable on filter selection if required


    if (action.disableOnFilterSelection && isFilterSelect) {
      Tine.log.debug("disable on filter selection");
      action.setDisabled(true);
      return;
    }

    if (nCondition) {
      if (mCondition) {
        if (action.initialConfig.requiredMultipleRight) {
          var right = action.initialConfig.requiredMultipleRight.split('_');

          if (right.length == 2) {
            action.setDisabled(!Tine.Tinebase.common.hasRight(right[0], action.initialConfig.scope.app.name, right[1]));
          } else {
            Tine.log.debug('multiple edit right was not properly applied');
          }
        }

        if (action.initialConfig.requiredMultipleGrant) {
          var hasRight = true;

          if (Ext.isArray(records)) {
            Ext.each(records, function (record) {
              if (record.get('container_id') && record.get('container_id').account_grants) {
                hasRight = hasRight && record.get('container_id').account_grants[action.initialConfig.requiredMultipleGrant];
              } else {
                return false;
              }
            }, this);
            action.setDisabled(!hasRight);
          }
        }
      }

      if (action.initialConfig.singularText && action.initialConfig.pluralText && action.initialConfig.translationObject) {
        var text = action.initialConfig.translationObject.n_(action.initialConfig.singularText, action.initialConfig.pluralText, records.length);
        action.setText(text);
      }
    }
  },

  /**
   * Calls the specified function for each action
   * 
   * @param {Function} fn The function to call. The action is passed as the first parameter.
   * Returning <tt>false</tt> aborts and exits the iteration.
   * @param {Object} scope (optional) The scope in which to call the function (defaults to the action).
   */
  each: function each(fn, scope) {
    for (var i = 0; i < this.actions.length; i++) {
      if (fn.call(scope || this.actions[i], this.actions[i]) === false) break;
    }
  },

  /**
   * calculats the grants sum of the given record(s)
   * 
   * @param  {Array}  records
   * @return {Object} grantName: sum
   */
  getGrantsSum: function getGrantsSum(records) {
    var _ = window.lodash,
        defaultGrant = records.length == 0 ? false : true,
        grants = {
      addGrant: defaultGrant,
      adminGrant: defaultGrant,
      deleteGrant: defaultGrant,
      editGrant: defaultGrant,
      readGrant: defaultGrant,
      exportGrant: defaultGrant,
      syncGrant: defaultGrant
    };

    if (!this.evalGrants) {
      return grants;
    }

    var recordGrants;

    for (var i = 0; i < records.length; i++) {
      recordGrants = _.get(records[i], this.grantsPath, null); // NOTE: we skip grant update for records without grantsPath

      if (recordGrants === null) {
        continue;
      }

      for (var grant in grants) {
        grants[grant] = _.get(grants, grant, false) && _.get(recordGrants, grant, false);
      } // custom grants model


      for (grant in recordGrants) {
        grants[grant] = _.get(grants, grant, defaultGrant) && _.get(recordGrants, grant, false);
      }
    } // if calculated admin right is true, overwrite all grants with true


    if (grants.adminGrant) {
      for (var grant in grants) {
        grants[grant] = true;
      }
    }

    return grants;
  }
};
/**
 * sets text and disabled status of a set of actions according to the grants 
 * of a set of records
 * @legacy use ActionUpdater Obj. instead!
 * 
 * @param {Array|SelectionModel} records
 * @param {Array|Toolbar}        actions
 * @param {String}               containerField
 * @param {Bool}                 skipGrants evaluation
 */

Tine.widgets.actionUpdater = function (records, actions, containerField, skipGrants) {
  if (!containerField) {
    containerField = 'container_id';
  }

  if (typeof records.getSelections == 'function') {
    records = records.getSelections();
  } else if (typeof records.beginEdit == 'function') {
    records = [records];
  } // init grants


  var defaultGrant = records.length == 0 ? false : true;
  var grants = {
    addGrant: defaultGrant,
    adminGrant: defaultGrant,
    deleteGrant: defaultGrant,
    editGrant: defaultGrant,
    exportGrant: defaultGrant,
    readGrant: defaultGrant,
    syncGrant: defaultGrant
  }; // calculate sum of grants

  for (var i = 0; i < records.length; i++) {
    var recordGrants = records[i].get(containerField) ? records[i].get(containerField).account_grants : {};

    for (var grant in grants) {
      grants[grant] = grants[grant] & recordGrants[grant];
    }
  } // if calculated admin right is true, overwrite all grants with true


  if (grants.adminGrant) {
    for (var grant in grants) {
      grants[grant] = true;
    }
  }
  /**
   * action iterator
   */


  var actionIterator = function actionIterator(action) {
    var initialConfig = action.initialConfig;

    if (initialConfig) {
      // happens for direct extensions of button class, like the notes button
      if (action.requiredGrant) {
        initialConfig = {
          requiredGrant: action.requiredGrant,
          allowMultiple: action.allowMultiple,
          singularText: action.singularText,
          pluralText: action.pluralText,
          translationObject: action.translationObject
        };
      } // NOTE: we don't handle add action for the moment!


      var requiredGrant = initialConfig.requiredGrant;

      if (requiredGrant && requiredGrant != 'addGrant') {
        var enable = skipGrants || grants[requiredGrant];

        if (records.length > 1 && !initialConfig.allowMultiple) {
          enable = false;
        }

        if (records.length == 0) {
          enable = false;
        }

        action.setDisabled(!enable);

        if (initialConfig.singularText && initialConfig.pluralText && initialConfig.translationObject) {
          var text = initialConfig.translationObject.n_(initialConfig.singularText, initialConfig.pluralText, records.length);
          action.setText(text);
        }
      }
    }
  };
  /**
   * call action iterator
   */


  switch (typeof actions) {
    case 'object':
      if (typeof actions.each == 'function') {
        actions.each(actionIterator, this);
      } else {
        for (var action in actions) {
          actionIterator(actions[action]);
        }
      }

      break;

    case 'array':
      for (var i = 0; i < actions.length; i++) {
        actionIterator(actions[i]);
      }

      break;
  }
};

/***/ }),
/* 1308 */
/***/ (function(module, exports) {

/**
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * @deprecated  use EditDialog instead. This class will be removed when all
 *              dialogs are moved to the EditDialog widget
 */

/*global Ext, Tine*/
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * Generic 'Edit Record' dialog
 *
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.EditRecord
 * @extends     Ext.FormPanel
 */

Tine.widgets.dialog.EditRecord = Ext.extend(Ext.FormPanel, {
  /**
   * @cfg {Array} additional toolbar items
   */
  tbarItems: false,

  /**
   * @cfg {String} internal app name
   */
  appName: null,

  /**
   * @cfg {String} translated container item name
   */
  //containerItemName: 'record',

  /**
   * @cfg {String} translated container name
   */
  containerName: 'container',

  /**
   * @cfg {string} containerName
   * name of container (plural)
   */
  containersName: 'containers',

  /**
   * @cfg {String} name of the container property
   */
  containerProperty: 'container_id',

  /**
   * @cfg {Bool} show container selector in bottom area
   */
  showContainerSelector: false,

  /**
   * @cfg {Object} handlerScope scope, the defined handlers will be executed in 
   */
  handlerScope: null,

  /**
   * @cfg {function} handler for generic save and close action
   */
  handlerSaveAndClose: null,

  /**
   * @cfg {function} handler for generic save and close action
   */
  handlerApplyChanges: null,

  /**
   * @cfg {function} handler for generic save and close action
   */
  handlerCancel: null,

  /**
   * @cfg {String} layout of the containing window
   */
  windowLayout: 'border',

  /**
   * @property {Ext.Window|Ext.ux.PopupWindow|Ext.Air.Window}
   */
  window: null,
  // private
  bodyStyle: 'padding:5px',
  //layout: 'fit',
  anchor: '100% 100%',
  region: 'center',
  deferredRender: false,
  buttonAlign: 'right',
  cls: 'tw-editdialog',
  //private
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event cancel
     * Fired when user pressed cancel button
     */
    'cancel',
    /**
     * @event saveAndClose
     * Fired when user pressed OK button
     */
    'saveAndClose',
    /**
     * @event update
     * @desc  Fired when the record got updated
     * @param {Ext.data.record} data data of the entry
     */
    'update',
    /**
     * @event apply
     * Fired when user pressed apply button
     */
    'apply');
    this.initHandlers();
    this.initActions();
    this.initButtons();
    Tine.widgets.dialog.EditRecord.superclass.initComponent.call(this);
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.EditRecord.superclass.onRender.call(this, ct, position);

    if (this.showContainerSelector) {
      this.recordContainerEl = this.footer.first().insertFirst({
        tag: 'div',
        style: {
          'position': 'relative',
          'top': '4px',
          'float': 'left'
        }
      });
      var ContainerForm = new Tine.widgets.container.SelectionComboBox({
        id: this.appName + 'EditRecordContainerSelector',
        fieldLabel: i18n._('Saved in'),
        width: 300,
        name: this.containerProperty,
        //itemName: this.containerItemName,
        containerName: this.containerName,
        containersName: this.containersName,
        appName: this.appName
      });
      this.getForm().add(ContainerForm);
      var containerSelect = new Ext.Panel({
        layout: 'form',
        border: false,
        renderTo: this.recordContainerEl,
        bodyStyle: {
          'background-color': '#F0F0F0'
        },
        items: ContainerForm
      });
    }
  },

  /**
   * Init actions
   */
  initActions: function initActions() {
    this.action_saveAndClose = new Ext.Action({
      requiredGrant: 'editGrant',
      text: i18n._('Ok'),
      //tooltip: 'Save changes and close this window',
      minWidth: 70,
      //handler: this.onSaveAndClose,
      handler: this.handlerSaveAndClose,
      iconCls: 'action_saveAndClose',
      scope: this.handlerScope
    });
    this.action_applyChanges = new Ext.Action({
      requiredGrant: 'editGrant',
      text: i18n._('Apply'),
      //tooltip: 'Save changes',
      minWidth: 70,
      handler: this.handlerApplyChanges,
      iconCls: 'action_applyChanges',
      scope: this.handlerScope //disabled: true

    });
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      //tooltip: 'Reject changes and close this window',
      minWidth: 70,
      handler: this.handlerCancel,
      iconCls: 'action_cancel',
      scope: this.handlerScope
    });
    this.action_delete = new Ext.Action({
      requiredGrant: 'deleteGrant',
      text: i18n._('delete'),
      minWidth: 70,
      handler: this.handlerDelete,
      iconCls: 'action_delete',
      scope: this.handlerScope,
      disabled: true
    });
  },

  /**
   * init buttons
   * use preference settings for order of save and close buttons
   */
  initButtons: function initButtons() {
    var genericButtons = [this.action_delete];
    this.buttons = [];
    this.buttons.push(this.action_cancel, this.action_saveAndClose);

    if (this.tbarItems) {
      this.tbar = new Ext.Toolbar({
        items: this.tbarItems
      });
    }
  },

  /**
   * @private
   */
  initHandlers: function initHandlers() {
    this.handlerScope = this.handlerScope ? this.handlerScope : this;
    this.handlerSaveAndClose = this.handlerSaveAndClose ? this.handlerSaveAndClose : function (e, button) {
      this.handlerApplyChanges(e, button, true);
    };
    this.handlerCancel = this.handlerCancel ? this.handlerCancel : this.closeWindow;
  },

  /**
   * update (action updateer) top and bottom toolbars
   */
  updateToolbars: function updateToolbars(record, containerField) {
    var actions = [this.action_saveAndClose, this.action_applyChanges, this.action_delete, this.action_cancel];
    Tine.widgets.actionUpdater(record, actions, containerField);
    Tine.widgets.actionUpdater(record, this.tbarItems, containerField);
  },

  /**
   * get top toolbar
   */
  getToolbar: function getToolbar() {
    return this.getTopToolbar();
  },

  /**
   * @private
   */
  onCancel: function onCancel() {
    this.fireEvent('cancel');
    this.purgeListeners();
  },

  /**
   * @private
   */
  onSaveAndClose: function onSaveAndClose() {
    this.fireEvent('saveAndClose');
  },

  /**
   * @private
   */
  onApply: function onApply() {
    this.fireEvent('apply');
  },

  /**
   * helper function to close window
   */
  closeWindow: function closeWindow() {
    this.window.close();
  }
});
Ext.reg('tineeditrecord', Tine.widgets.dialog.EditRecord);

/***/ }),
/* 1309 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets');
/**
 * check if newer version of Tine 2.0 is available
 * 
 * @namespace   Tine.widgets
 * @class       Tine.widgets.VersionCheck
 * @constructor
 */

Tine.widgets.VersionCheck = function () {
  var ds = new Ext.data.Store({
    proxy: new Ext.data.ScriptTagProxy({
      url: 'https://versioncheck.tine20.net/versionCheck/be/versionCheck.php'
    }),
    reader: new Ext.data.JsonReader({
      root: 'version'
    }, ['codeName', 'packageString', 'releaseTime', 'critical', 'build'])
  });
  ds.on('load', function (store, records) {
    if (!Tine.Tinebase.registry.get('version')) {
      return false;
    }

    var availableVersion = records[0];
    installedVersion = Tine.Tinebase.registry.get('version');
    Tine.log.debug('Available Tine version:');
    Tine.log.debug(availableVersion);
    Tine.log.debug('Installed Tine version:');
    Tine.log.debug(installedVersion);
    var local = Date.parseDate(installedVersion.releaseTime, Date.patterns.ISO8601Long);
    var latest = Date.parseDate(availableVersion.get('releaseTime'), Date.patterns.ISO8601Long);

    if (latest > local && Tine.Tinebase.common.hasRight('run', 'Tinebase')) {
      var versionString = availableVersion.get('codeName') + ' ' + availableVersion.get('packageString');

      if (availableVersion.get('critical') == true) {
        Ext.MessageBox.show({
          title: i18n._('New version of Tine 2.0 available'),
          msg: String.format(i18n._('Version "{0}" of Tine 2.0 is available.'), versionString) + "\n" + i18n._("It's a critical update and must be installed as soon as possible!"),
          width: 500,
          buttons: Ext.Msg.OK,
          icon: Ext.MessageBox.ERROR
        });
      } else {
        Ext.MessageBox.show({
          title: i18n._('New version of Tine 2.0 available'),
          msg: String.format(i18n._('Version "{0}" of Tine 2.0 is available.'), versionString) + "\n" + i18n._('Please consider updating!'),
          width: 400,
          buttons: Ext.Msg.OK,
          icon: Ext.MessageBox.INFO
        });
      }
    }
  }, this);
  ds.load({
    params: {
      version: Ext.util.JSON.encode(Tine.Tinebase.registry.get('version'))
    }
  });
};

/***/ }),
/* 1310 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * Alarm Panel
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.AlarmPanel
 * @extends     Ext.Panel
 * 
 * @TODO add validation (alarm after alarmtime)
 */

Tine.widgets.dialog.AlarmPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {string} name of alarm field
   */
  recordAlarmField: 'dtstart',
  //private
  layout: 'fit',
  border: true,
  frame: true,
  canonicalName: 'AlarmGrid',
  initComponent: function initComponent() {
    this.title = this.title || i18n._('Alarms');
    this.alarmOptions = this.alarmOptions || [['0', i18n._('0 minutes before')], ['5', i18n._('5 minutes before')], ['15', i18n._('15 minutes before')], ['30', i18n._('30 minutes before')], ['60', i18n._('1 hour before')], ['120', i18n._('2 hours before')], ['720', i18n._('12 hours before')], ['1440', i18n._('1 day before')], ['2880', i18n._('2 days before')], ['custom', i18n._('Custom Datetime')]];
    this.items = this.alarmGrid = new Tine.widgets.grid.QuickaddGridPanel({
      layout: 'fit',
      autoExpandColumn: 'alarm_time',
      quickaddMandatory: 'minutes_before',
      frame: false,
      recordClass: Tine.Tinebase.Model.Alarm,
      onNewentry: this.onNewentry.createDelegate(this),
      cm: new Ext.grid.ColumnModel([{
        id: 'minutes_before',
        header: i18n._('Alarm Time'),
        dataIndex: 'minutes_before',
        width: 200,
        hideable: false,
        sortable: true,
        quickaddField: new Ext.form.ComboBox({
          triggerAction: 'all',
          lazyRender: false,
          editable: false,
          mode: 'local',
          forceSelection: true,
          store: this.alarmOptions,
          listeners: {
            scope: this,
            beforeselect: function beforeselect(combo, record, index) {
              var alarmFieldDate = this.record ? this.record.get(this.recordAlarmField) : null;
              this.alarmTimeQuickAdd.setDisabled(record.data.field1 != 'custom'); // preset a usefull value

              if (Ext.isDate(alarmFieldDate) && record.data.field1 == 'custom') {
                this.alarmTimeQuickAdd.setValue(alarmFieldDate.add(Date.MINUTE, -1 * Ext.isNumber(combo.getValue()) ? combo.getValue() : 0));
              }

              if (record.data.field1 != 'custom') {
                this.alarmTimeQuickAdd.setValue();
              }
            }
          }
        }),
        editor: new Ext.form.ComboBox({
          triggerAction: 'all',
          lazyRender: false,
          editable: false,
          mode: 'local',
          forceSelection: true,
          allowBlank: false,
          expandOnFocus: true,
          blurOnSelect: true,
          store: this.alarmOptions
        }),
        renderer: this.minutesBeforeRenderer.createDelegate(this)
      }, {
        id: 'alarm_time',
        dataIndex: 'alarm_time',
        hideable: false,
        sortable: false,
        renderer: this.alarmTimeRenderer.createDelegate(this),
        quickaddField: this.alarmTimeQuickAdd = new Ext.ux.form.DateTimeField({
          allowBlank: true
        }),
        editor: new Ext.ux.form.DateTimeField({
          allowBlank: false
        })
      }])
    });
    this.alarmGrid.on('beforeedit', this.onBeforeEdit, this);
    this.alarmGrid.on('afteredit', this.onAfterEdit, this);
    Tine.widgets.dialog.AlarmPanel.superclass.initComponent.call(this);
  },
  onNewentry: function onNewentry(recordData) {
    if (recordData.minutes_before == 'custom' && !Ext.isDate(recordData.alarm_time)) {
      return false;
    }

    Tine.widgets.grid.QuickaddGridPanel.prototype.onNewentry.apply(this.alarmGrid, arguments);
    this.alarmGrid.store.sort('minutes_before', 'ASC');
  },
  onBeforeEdit: function onBeforeEdit(o) {
    if (o.field == 'alarm_time') {
      var minutesBefore = o.record.get('minutes_before'),
          alarmTime = o.record.get('alarm_time'); // allow status setting if status authkey is present

      if (minutesBefore != 'custom') {
        o.cancel = true;
      } else if (alarmTime && !Ext.isDate(alarmTime)) {
        var alarmDate = Date.parseDate(alarmTime, Date.patterns.ISO8601Long);
        o.record.set('alarm_time', '');
        o.record.set('alarm_time', alarmDate);
      }
    }
  },
  onAfterEdit: function onAfterEdit(o) {
    if (o.record.get('minutes_before') == 'custom' && !Ext.isDate(o.record.get('alarm_time'))) {
      var alarmFieldDate = this.record ? this.record.get(this.recordAlarmField) : null;
      o.record.set('alarm_time', Ext.isDate(alarmFieldDate) ? alarmFieldDate.clone() : new Date());
    }

    if (o.record.get('minutes_before') != 'custom') {
      o.record.set('alarm_time', '');
    }

    this.alarmGrid.store.sort('minutes_before', 'ASC');
  },
  minutesBeforeRenderer: function minutesBeforeRenderer(value) {
    var string = null;
    Ext.each(this.alarmOptions, function (opt) {
      if (opt[0] == value) {
        string = opt[1];
        return false;
      }
    });

    if (!string) {
      string = String.format(i18n._('{0} minutes before'), value);
    }

    return string;
  },
  alarmTimeRenderer: function alarmTimeRenderer(value, metaData, record) {
    return record.get('minutes_before') == 'custom' ? Tine.Tinebase.common.dateTimeRenderer.apply(this, arguments) : '';
  },

  /**
   * on record load event
   * 
   * @param {Object} record
   */
  onRecordLoad: function onRecordLoad(record) {
    this.record = record;
    this.alarmGrid.store.removeAll();
    this.alarmGrid.setStoreFromArray(record.get('alarms') || []);
    this.alarmGrid.store.sort('minutes_before', 'ASC');
  },

  /**
   * on record update event
   * 
   * @param {Object} record
   */
  onRecordUpdate: function onRecordUpdate(record) {
    // we need to initialze alarms because stringcompare would detect no change of the arrays
    record.set('alarms', '');
    record.set('alarms', this.alarmGrid.getFromStoreAsArray());
  },

  /**
   * disable contents not panel
   */
  setDisabled: function setDisabled(v) {
    this.el[v ? 'mask' : 'unmask']();
  }
});

/***/ }),
/* 1311 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.dialog');
/**
 * @namespace Tine.Tinebase
 * @class Tine.Tinebase.dialog.Dialog
 * @extends Ext.Panel
 */

Tine.Tinebase.dialog.Dialog = Ext.extend(Ext.FormPanel, {
  /**
   * @cfg {Number} windowWidth
   * width of dialog window
   */
  windowWidth: 300,

  /**
   * @cfg {Number} windowHeight
   * height of dialog window
   */
  windowHeight: 400,

  /**
   * @cfg {Tine.Tinebase.Application} app
   * instance of the app object (required if not appName is given)
   */
  app: null,

  /**
   * @cfg {String} appName
   * name of app (required if no app is given)
   */
  appName: null,

  /**
   * @cfg {String} OkButtonText
   * text of ok button (optional) default to _('Ok')
   */
  applyButtonText: '',

  /**
   * @cfg {String} cancelButtonText
   * text of cancel button (optional) defaults to _('Cancel')
   */
  cancelButtonText: '',

  /**
   * @cfg {String} canonicalName
   * canonical name of dialog (required) see getCanonicalPathSegment
   */
  canonicalName: '',
  cls: 'tw-editdialog',
  layout: 'fit',
  border: false,
  initComponent: function initComponent() {
    var _this$fbar;

    if (!this.app && this.appName) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    }

    if (!this.appName && this.app) {
      this.appName = this.app.name;
    }

    this.fbar = (_this$fbar = this.fbar) !== null && _this$fbar !== void 0 ? _this$fbar : ['->', {
      text: this.cancelButtonText ? this.app.i18n._hidden(this.cancelButtonText) : i18n._('Cancel'),
      minWidth: 70,
      ref: '../buttonCancel',
      scope: this,
      handler: this.onButtonCancel,
      iconCls: 'action_cancel'
    }, {
      text: this.applyButtonText ? this.app.i18n._hidden(this.applyButtonText) : i18n._('Ok'),
      minWidth: 70,
      ref: '../buttonApply',
      scope: this,
      handler: this.onButtonApply,
      iconCls: 'action_saveAndClose'
    }];
    Tine.Tinebase.dialog.Dialog.superclass.initComponent.call(this);
  },
  onWindowInject: function onWindowInject(win) {
    win.onEsc = _.bind(this.onButtonCancel, this);
  },
  afterRender: function afterRender() {
    Tine.Tinebase.dialog.Dialog.superclass.afterRender.call(this);

    if (this.enableKeyEvents) {
      this.getEl().on('keydown', e => {
        if (e.getKey() === e.ENTER) this.onButtonApply();
        if (e.getKey() === e.ESC) this.onButtonCancel();
      });
    }
  },

  /**
   * template fn, implement to have specific data in the events
   */
  getEventData: Ext.emptyFn,
  onButtonCancel: function onButtonCancel() {
    this.fireEvent.apply(this, ['cancel', this.getEventData('cancel')]);

    if (this.window.closeAction !== 'hide') {
      this.purgeListeners();
      this.window.close();
    } else {
      this.window.hide();
    }
  },
  onButtonApply: function onButtonApply() {
    var eventData = this.getEventData('apply');
    this.fireAsyncEvent.apply(this, ['beforeapply', eventData]).then(() => {
      this.fireEvent.apply(this, ['apply', eventData]);

      if (this.window.closeAction !== 'hide') {
        this.purgeListeners();
        this.window.close();
      } else {
        this.window.hide();
      }
    }).catch(() => {});
  },
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    return ['', this.appName, this.canonicalName].join(Tine.Tinebase.CanonicalPath.separator);
  }
});

/***/ }),
/* 1312 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2019 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * Generic 'Edit Record' dialog
 * Base class for all 'Edit Record' dialogs
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.EditDialog
 * @extends     Ext.FormPanel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.dialog.EditDialog = Ext.extend(Ext.FormPanel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   * instance of the app object (required)
   */
  app: null,

  /**
   * @cfg {String} mode
   * Set to 'local' if the EditDialog only operates on this.record (defaults to 'remote' which loads and saves using the recordProxy)
   */
  mode: 'remote',

  /**
   * @cfg {Array} tbarItems
   * additional toolbar items (defaults to false)
   */
  tbarItems: false,

  /**
   * internal/untranslated app name (required)
   * 
   * @cfg {String} appName
   */
  appName: null,

  /**
   * the modelName (filled by application starter)
   * 
   * @type {String} modelName
   */
  modelName: null,

  /**
   * record definition class  (required if no modelconfig! don't declare for modelconfig!!)
   * 
   * @cfg {Ext.data.Record} recordClass
   */
  recordClass: null,

  /**
   * @cfg {Ext.data.DataProxy} recordProxy
   */
  recordProxy: null,

  /**
   * @cfg {Bool} showContainerSelector
   * show container selector in bottom area
   */
  showContainerSelector: null,

  /**
   * @cfg {Bool} evalGrants
   * should grants of a grant-aware records be evaluated (defaults to true)
   */
  evalGrants: true,

  /**
   * @cfg {String} requiredSaveGrant
   * required grant for apply/save
   */
  requiredSaveGrant: 'editGrant',

  /**
   * @cfg {Ext.data.Record} record
   * record in edit process.
   */
  record: null,

  /**
   * holds the modelConfig for the handled record (json-encoded object)
   * will be decoded in initComponent
   * 
   * @type 
   */
  modelConfig: null,

  /**
   * @cfg {String} saveAndCloseButtonText
   * text of save and close button
   */
  saveAndCloseButtonText: '',

  /**
   * @cfg {Function} saveAndCloseActionUpdater
   * overwritable action updater
   */
  saveAndCloseActionUpdater: null,

  /**
   * @cfg {String} cancelButtonText
   * text of cancel button
   */
  cancelButtonText: '',

  /**
   * @cfg {Boolean} copyRecord
   * copy record
   */
  copyRecord: false,

  /**
   * @cfg {Boolean} doDuplicateCheck
   * do duplicate check when saving record (mode remote only)
   */
  doDuplicateCheck: true,

  /**
   * when a record has the relations-property the relations-panel can be disabled here
   * @cfg {Boolean} hideRelationsPanel
   */
  hideRelationsPanel: false,

  /**
   * when a record has the attachments-property the attachments-panel can be disabled here
   * @cfg {Boolean} hideAttachmentsPanel
   */
  hideAttachmentsPanel: false,

  /**
   * Registry for other relationgridpanels than the generic one,
   * handling special types of relations the generic one will not.
   * Panels registered here must have a store with the relation records.
   * 
   * @type {Array}
   */
  relationPanelRegistry: null,

  /**
   * ignore relations to given php-class names in the relation grid
   * @type {Array}
   */
  ignoreRelatedModels: null,

  /**
   * dialog is currently saving data
   * @type Boolean
   */
  saving: false,

  /**
   * Disable adding cf tab even if model has support for customfields
   * @type Boolean
   */
  disableCfs: false,

  /**
   * check for unsaved changes before closing
   * @type Boolean
   */
  checkUnsavedChanges: true,

  /**
   * @property window {Ext.Window|Ext.ux.PopupWindow|Ext.Air.Window}
   */

  /**
   * @property {Number} loadRequest 
   * transaction id of loadData request
   */

  /**
   * @property loadMask {Ext.LoadMask}
   */

  /**
   * @property containerSelectCombo {Tine.widgets.container.SelectionComboBox}
   */
  containerSelectCombo: null,

  /**
   * If set, these fields are readOnly (when called dependent to related record)
   * 
   * @type {Ext.util.MixedCollection}
   */
  fixedFields: null,

  /**
   * Plain Object with additional configuration (JSON-encoded)
   * 
   * @type {Object}
   */
  additionalConfig: null,

  /**
   * Assuming mode is not local, but the dialog is supposed to treat this.record as a json string and keep those data
   */
  recordFromJson: false,

  /**
   * canonical name
   * @cfg {String} canonicalName
   */
  canonicalName: 'EditDialog',
  // private
  bodyStyle: 'padding:5px',
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,

  /**
   * relations panel
   * 
   * @type Tine.widgets.relation.GenericPickerGridPanel
   */
  relationsPanel: null,
  // Array of Relation Pickers
  relationPickers: null,

  /**
   * attachments panel
   * 
   * @type Tine.widgets.dialog.AttachmentsGridPanel
   */
  attachmentsPanel: null,

  /**
   * holds the loadMask
   * set this to false, if no loadMask should be shown
   * 
   * @type {Ext.LoadMask}
   */
  loadMask: null,

  /**
   * hook notes panel into dialog
   */
  displayNotes: false,
  useMultiple: false,
  inheritableStatics: {
    /**
     * register checkState provider
     * @param {String} field
     * @param {Funciton} fn check state function
     */
    registerCheckStateProvider: function registerCheckStateProvider(field, fn) {
      arguments.callee.__providers = arguments.callee.__providers || {};
      arguments.callee.__providers[field] = arguments.callee.__providers[field] || [];

      arguments.callee.__providers[field].push(fn);
    },

    getCheckStateProviders(field) {
      return _.get(this, "registerCheckStateProvider.__providers.".concat(field), []);
    }

  },
  //private
  initComponent: function initComponent() {
    this.relationPanelRegistry = this.relationPanelRegistry ? this.relationPanelRegistry : [];
    this.addEvents(
    /**
     * @event cancel
     * Fired when user pressed cancel button
     */
    'cancel',
    /**
     * @event saveAndClose
     * Fired when user pressed OK button
     */
    'saveAndClose',
    /**
     * @event update
     * @desc  Fired when the record got updated
     * @param {Json String} data data of the entry
     * @pram  {String} this.mode
     */
    'update',
    /**
     * @event apply
     * Fired when user pressed apply button
     */
    'apply',
    /**
     * @event load
     * @param {Tine.widgets.dialog.EditDialog} this
     * @param {Tine.data.Record} record which got loaded
     * @param {Function} ticket function for async defer
     * Fired when record is loaded
     */
    'load',
    /**
     * @event save
     * @param {Tine.widgets.dialog.EditDialog} this
     * @param {Tine.data.Record} record which got loaded
     * @param {Function} ticket function for async defer
     * Fired when remote record is saving
     */
    'save',
    /**
     * @event updateDependent
     * Fired when a subpanel updates the record locally
     */
    'updateDependent',
    /**
     * @event change
     * Fires just before the field blurs if the field value has changed.
     * @param {Ext.form.Field} this
     * @param {Mixed} newValue The new value
     * @param {Mixed} oldValue The original value
     */
    'change');

    if (Ext.isString(this.modelConfig)) {
      this.modelConfig = Ext.decode(this.modelConfig);
    }

    if (Ext.isString(this.additionalConfig)) {
      Ext.apply(this, Ext.decode(this.additionalConfig));
    }

    var fixedFieldsData = Ext.isString(this.fixedFields) ? Ext.decode(this.fixedFields) : [];
    this.fixedFields = new Ext.util.MixedCollection();
    this.fixedFields.addAll(fixedFieldsData);

    if (!this.recordClass && this.modelName) {
      this.recordClass = Tine[this.appName].Model[this.modelName];
    }

    if (this.recordClass) {
      this.appName = this.appName ? this.appName : this.recordClass.getMeta('appName');
      this.modelName = this.modelName ? this.modelName : this.recordClass.getMeta('modelName');
    }

    if (!this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    }

    if (!this.windowNamePrefix) {
      this.windowNamePrefix = this.modelName + 'EditWindow_';
    }

    Tine.log.debug('initComponent: appName: ', this.appName);
    Tine.log.debug('initComponent: modelName: ', this.modelName);
    Tine.log.debug('initComponent: app: ', this.app); // init some translations

    if (this.app.i18n && this.recordClass !== null) {
      this.i18nRecordName = this.app.i18n.n_hidden(this.recordClass.getMeta('recordName'), this.recordClass.getMeta('recordsName'), 1);
      this.i18nRecordsName = this.app.i18n._hidden(this.recordClass.getMeta('recordsName'));
    } // auto record proxy


    if (!this.recordProxy && this.recordClass) {
      Tine.log.debug('no record proxy given, creating a new one...');
      this.recordProxy = new Tine.Tinebase.data.RecordProxy({
        recordClass: this.recordClass
      });
    } // auto eval grants


    if (this.recordClass) {
      var grantsField = this.recordClass.getMeta('grantsPath').replace(/^data\./, '').replace(/\..+/g, '');
      this.evalGrants = this.evalGrants && (grantsField == 'data' || this.recordClass.hasField(grantsField));
    } // init plugins


    this.plugins = Ext.isString(this.plugins) ? Ext.decode(this.plugins) : Ext.isArray(this.plugins) ? this.plugins.concat(Ext.decode(this.initialConfig.plugins)) : [];
    this.plugins.push(this.tokenModePlugin = new Tine.widgets.dialog.TokenModeEditDialogPlugin({})); // added possibility to disable using customfield plugin

    if (this.disableCfs !== true) {
      const cfPlugin = new Tine.widgets.customfields.EditDialogPlugin({});
      this.plugins.push(cfPlugin);
      this.initPlugin(cfPlugin);
    }

    Ext.ux.pluginRegistry.addRegisteredPlugins(this); // multiEditPlugin need to load before record is initialised

    const multiEditPlugin = _.find(this.plugins, {
      ptype: "multiple_edit_dialog"
    });

    if (multiEditPlugin) {
      this.initPlugin(multiEditPlugin);
    } // init actions


    this.initActions(); // init buttons and tbar

    this.initButtons(); // init record 

    this.initRecord(); // init container selector

    this.initContainerSelector(); // get items for this dialog

    this.items = this.getFormItems(); // init relations panel if relations are defined

    this.initRelationsPanel(); // init attachments panel

    this.initAttachmentsPanel(); // init notes panel

    this.initNotesPanel(); // apply generic tab sorting

    if (this.items.xtype == 'tabpanel') {
      this.items.plugins = this.items.plugins || [];
      this.items.plugins.push({
        ptype: 'ux.tabpanelsortplugin',
        enableDD: false
      });
      this.items.items[0].pos = 10;
    }

    Tine.widgets.dialog.EditDialog.superclass.initComponent.call(this); // set fields readOnly if set

    this.fixFields(); // firefox fix: blur each item before tab changes, so no field  will be focused afterwards

    if (Ext.isGecko) {
      this.items.items[0].addListener('beforetabchange', function (tabpanel, newtab, oldtab) {
        if (!oldtab) {
          return;
        }

        var form = this.getForm();
        if (form && form.hasOwnProperty('items')) form.items.each(function (item, index) {
          item.blur();
        });
      }, this);
    }

    if (Ext.isFunction(this.window.relayEvents) && Tine.Tinebase.featureEnabled('featureRememberPopupSize')) {
      this.window.relayEvents(this, ['resize']);
    }
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    if (this.recordClass) {
      return ['', this.recordClass.getMeta('appName'), this.canonicalName, this.recordClass.getMeta('modelName')].join(Tine.Tinebase.CanonicalPath.separator);
    }
  },

  /**
   * generic form layout
   */
  getFormItems: function getFormItems() {
    return {
      xtype: 'tabpanel',
      border: false,
      plain: true,
      activeTab: 0,
      defaults: {
        hideMode: 'offsets'
      },
      plugins: [{
        ptype: 'ux.tabpanelkeyplugin'
      }, {
        ptype: 'ux.itemregistry',
        key: [this.app.appName, this.recordClass.getMeta('modelName'), 'EditDialog-TabPanel'].join('-')
      }],
      items: [{
        title: this.i18nRecordName,
        autoScroll: true,
        border: false,
        frame: true,
        layout: 'border',
        defaults: {
          autoScroll: true
        },
        items: [Ext.applyIf(this.getRecordFormItems(), {
          region: 'center',
          xtype: 'columnform',
          labelAlign: 'top',
          formDefaults: {
            xtype: 'textfield',
            anchor: '100%',
            labelSeparator: '',
            columnWidth: 1 / 2
          }
        })].concat(this.getEastPanel())
      }, new Tine.widgets.activities.ActivitiesTabPanel({
        app: this.appName,
        record_id: this.record.id,
        record_model: this.modelName
      })]
    };
  },
  getEastPanel: function getEastPanel() {
    var items = [];

    if (this.recordClass.hasField('description')) {
      items.push(new Ext.Panel({
        title: i18n._('Description'),
        iconCls: 'descriptionIcon',
        layout: 'form',
        labelAlign: 'top',
        border: false,
        items: [{
          style: 'margin-top: -4px; border 0px;',
          labelSeparator: '',
          xtype: 'textarea',
          name: 'description',
          hideLabel: true,
          grow: false,
          preventScrollbars: false,
          anchor: '100% 100%',
          emptyText: i18n._('Enter description'),
          requiredGrant: 'editGrant'
        }]
      }));
    }

    if (this.recordClass.hasField('tags')) {
      items.push(new Tine.widgets.tags.TagPanel({
        app: this.appName,
        border: false,
        bodyStyle: 'border:1px solid #B5B8C8;'
      }));
    }

    return items.length ? {
      layout: 'ux.multiaccordion',
      animate: true,
      region: 'east',
      width: 210,
      split: true,
      collapsible: true,
      collapseMode: 'mini',
      header: false,
      margins: '0 5 0 5',
      border: true,
      items: items
    } : [];
  },
  getRecordFormItems: function getRecordFormItems() {
    return new Tine.widgets.form.RecordForm({
      recordClass: this.recordClass,
      editDialog: this
    });
  },

  /**
   * allows to fetch record form fields
   *
   * @param name
   * @returns {*}
   */
  getRecordFormField: function getRecordFormField(name) {
    return this.recordForm['formfield_' + name];
  },

  /**
   * fix fields (used for preselecting form fields when called in dependency to another record)
   * @return {Boolean}
   */
  fixFields: function fixFields() {
    if (this.fixedFields && this.fixedFields.getCount() > 0) {
      if (!this.rendered) {
        this.fixFields.defer(100, this);
        return false;
      }

      this.fixedFields.each(function (value, index) {
        var key = this.fixedFields.keys[index];
        var field = this.getForm().findField(key);

        if (field) {
          if (Ext.isFunction(this.recordClass.getField(key).type)) {
            var foreignRecordClass = this.recordClass.getField(key).type;
            var record = new foreignRecordClass(value);
            field.selectedRecord = record;
            field.setValue(value, this.record);
            field.fireEvent('select');
          } else {
            field.setValue(value, this.record);
          }

          field.disable();
        }
      }, this);
    }
  },

  /**
   * call checkState for every field
   */
  checkStates: function checkStates() {
    if (this.loadRequest) {
      return _.delay(_.bind(this.checkStates, this), 250);
    }

    this.onRecordUpdate();
    this.getForm().items.each(function (item) {
      if (Ext.isFunction(item.checkState)) {
        item.checkState(this, this.record);
      }

      if (item.name) {
        _.each(this.constructor.getCheckStateProviders(item.name), fn => {
          fn.call(item, this, this.record);
        });
      }
    }, this);
  },

  /**
   * Get available model for given application
   *
   *  @param {Mixed} application
   *  @param {Boolean} customFieldModel
   */
  getApplicationModels: function getApplicationModels(application, customFieldModel) {
    var models = [],
        useModel,
        appName = Ext.isString(application) ? application : application.get('name'),
        app = Tine.Tinebase.appMgr.get(appName),
        trans = app && app.i18n ? app.i18n : i18n,
        appModels = Tine[appName].Model;

    if (appModels) {
      for (var model in appModels) {
        if (appModels.hasOwnProperty(model) && typeof appModels[model].getMeta === 'function') {
          if (customFieldModel && appModels[model].getField('customfields')) {
            useModel = appModels[model].getMeta('appName') + '_Model_' + appModels[model].getMeta('modelName');
            Tine.log.info('Found model with customfields property: ' + useModel);
            models.push([useModel, trans.n_(appModels[model].getMeta('recordName'), appModels[model].getMeta('recordsName'), 1)]);
          } else if (!customFieldModel) {
            useModel = 'Tine.' + appModels[model].getMeta('appName') + '.Model.' + appModels[model].getMeta('modelName');
            Tine.log.info('Found model: ' + useModel);
            models.push([useModel, trans.n_(appModels[model].getMeta('recordName'), appModels[model].getMeta('recordsName'), 1)]);
          }
        }
      }
    }

    return models;
  },

  /**
   * init actions
   */
  initActions: function initActions() {
    this.action_saveAndClose = new Ext.Action({
      requiredGrant: this.requiredSaveGrant,
      text: this.saveAndCloseButtonText != '' ? this.app.i18n._(this.saveAndCloseButtonText) : i18n._('Ok'),
      minWidth: 70,
      ref: '../btnSaveAndClose',
      scope: this,
      actionUpdater: this.saveAndCloseActionUpdater,
      // TODO: remove the defer when all subpanels use the deferByTicket mechanism
      handler: function handler() {
        this.onSaveAndClose.defer(500, this);
      },
      iconCls: 'action_saveAndClose'
    });
    this.action_applyChanges = new Ext.Action({
      requiredGrant: this.requiredSaveGrant,
      text: i18n._('Apply'),
      minWidth: 70,
      ref: '../btnApplyChanges',
      scope: this,
      handler: this.onApplyChanges,
      iconCls: 'action_applyChanges'
    });
    this.action_cancel = new Ext.Action({
      text: this.cancelButtonText != '' ? this.app.i18n._(this.cancelButtonText) : i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    });
    this.action_delete = new Ext.Action({
      requiredGrant: 'deleteGrant',
      text: i18n._('delete'),
      minWidth: 70,
      scope: this,
      handler: this.onDelete,
      iconCls: 'action_delete',
      disabled: true
    });
    this.action_export = Tine.widgets.exportAction.getExportButton(this.recordClass, {
      getExportOptions: this.getExportOptions.createDelegate(this)
    }, Tine.widgets.exportAction.SCOPE_SINGLE);

    if (this.enablePrinting) {
      this.action_print = new Ext.Action({
        requiredGrant: 'readGrant',
        text: String.format(i18n._('Print {0}'), this.recordClass.getRecordName()),
        handler: this.onPrint,
        iconCls: 'action_print',
        disabled: false,
        scope: this
      });
    }

    this.actionUpdater = new Tine.widgets.ActionUpdater({
      recordClass: this.recordClass,
      evalGrants: this.evalGrants
    });
    this.actionUpdater.addActions([this.action_saveAndClose, this.action_applyChanges, this.action_cancel, this.action_delete]);
  },

  /**
   * get export options/data
   */
  getExportOptions: function getExportOptions() {
    this.onRecordUpdate();
    return {
      recordData: this.record.data
    };
  },

  /**
   * init buttons
   *
   * use button order from preference
   */
  initButtons: function initButtons() {
    this.fbar = ['->'];
    this.fbar.push(this.action_cancel, this.action_saveAndClose);

    if (this.action_print) {
      this.actionUpdater.addAction(this.action_print);
      this.tbarItems = this.tbarItems || [];
      this.tbarItems.push(this.action_print);
    }

    if (this.action_export) {
      this.actionUpdater.addAction(this.action_export);
      this.tbarItems = this.tbarItems || [];
      this.tbarItems.push(this.action_export);
    }

    if (this.tbarItems && this.tbarItems.length) {
      this.actionUpdater.addActions(this.tbarItems);
      this.tbar = new Ext.Toolbar({
        items: this.tbarItems
      });
    }
  },

  /**
   * init container selector
   */
  initContainerSelector: function initContainerSelector() {
    if (this.showContainerSelector) {
      this.containerSelectCombo = new Tine.widgets.container.SelectionComboBox({
        id: this.app.appName + 'EditDialogContainerSelector-' + Ext.id(),
        fieldLabel: i18n._('Saved in'),
        width: 300,
        listWidth: 300,
        name: this.recordClass.getMeta('containerProperty'),
        recordClass: this.recordClass,
        containerName: this.app.i18n.n_hidden(this.recordClass.getMeta('containerName'), this.recordClass.getMeta('containersName'), 1),
        containersName: this.app.i18n._hidden(this.recordClass.getMeta('containersName')),
        appName: this.app.appName,
        // required grant to change container
        requiredGrant: this.evalGrants ? 'deleteGrant' : false,
        // required grants for the container to choose
        requiredGrants: [this.evalGrants ? 'addGrant' : false],
        disabled: this.isContainerSelectorDisabled(),
        listeners: {
          scope: this,
          select: function select() {
            // enable or disable save button dependent to containers account grants
            // on edit: check editGrant, on add: check addGrant
            var grants = this.containerSelectCombo.selectedContainer ? this.containerSelectCombo.selectedContainer.account_grants : {},
                grantToCheck = this.record.data.id ? 'editGrant' : 'addGrant',
                enabled = grants.hasOwnProperty(grantToCheck) && grants[grantToCheck] || grants.hasOwnProperty('adminGrant') && grants.adminGrant ? true : false;
            this.action_saveAndClose.setDisabled(!enabled);
          }
        }
      });
      this.on('render', function () {
        this.getForm().add(this.containerSelectCombo);
      }, this);
      this.fbar = [i18n._('Saved in'), this.containerSelectCombo].concat(this.fbar);
    }
  },

  /**
   * checks if the container selector should be disabled (dependent on account grants of the container itself)
   * @return {}
   */
  isContainerSelectorDisabled: function isContainerSelectorDisabled() {
    if (this.record) {
      var cp = this.recordClass.getMeta('containerProperty'),
          container = this.record.data[cp],
          grants = container && container.hasOwnProperty('account_grants') ? container.account_grants : null,
          cond = false; // check grants if record already exists and grants should be evaluated

      if (this.evalGrants && this.record.data.id && grants) {
        cond = !(grants.hasOwnProperty('editGrant') && grants.editGrant);
      }

      return cond;
    } else {
      return false;
    }
  },

  /**
   * init record to edit
   */
  initRecord: function initRecord() {
    Tine.log.debug('init record with mode: ' + this.mode);

    if (!this.record) {
      Tine.log.debug('creating new default data record');
      this.record = new this.recordClass(this.recordClass.getDefaultData(), 0);
    } // Mode local means, that the record is not supposed to be loaded from server and saved to server.
    // So if mode !== local, the record would be always loaded from the server and discard all data passed as record before
    // To bypass this you can set recordFromJson === true, then the dialog wouldn't load the record from server!
    // But to make this work you need to pass a json encoded record to the editdialog as string!


    if (this.mode !== 'local' && this.recordFromJson !== true) {
      if (this.record && this.record.id) {
        this.loadRemoteRecord();
      } else {
        this.onRecordLoad.defer(10, this);
      }
    } else {
      // note: in local mode we expect a valid record
      if (!Ext.isFunction(this.record.beginEdit)) {
        this.record = this.recordProxy.recordReader({
          responseText: this.record
        });
      }

      this.onRecordLoad.defer(10, this);
    }
  },

  /**
   * load record via record proxy
   */
  loadRemoteRecord: function loadRemoteRecord() {
    Tine.log.info('initiating record load via proxy');
    this.loadRequest = this.recordProxy.loadRecord(this.record, {
      scope: this,
      success: function success(record) {
        this.record = record;
        this.onRecordLoad();
      }
    });
  },

  /**
   * copy this.record record
   */
  doCopyRecord: function doCopyRecord() {
    this.record = this.doCopyRecordToReturn(this.record);

    var _ = window.lodash,
        hasRequiredGrant = _.get(this.record, this.recordClass.getMeta('grantsPath') + '.addGrant'); // unset container if user is not allowed to add record in original container


    if (this.evalGrants && !hasRequiredGrant) {
      _.unset(this.record, 'data.' + this.recordClass.getMeta('containerProperty'));

      _.set(this.record, this.recordClass.getMeta('grantsPath') + '.deleteGrant', true);

      _.set(this.record, this.recordClass.getMeta('grantsPath') + '.addGrant', true);

      _.set(this.record, this.recordClass.getMeta('grantsPath') + '.editGrant', true);
    }
  },

  /**
   * Copy record and returns "new record with same settings"
   *
   * @param {Tine.Tinebase.data.Record} record
   */
  doCopyRecordToReturn: function doCopyRecordToReturn(record) {
    var recordData = this.getCopyRecordData(record, this.recordClass, this.omitCopyTitle);
    return new this.recordClass(recordData, Tine.Tinebase.data.Record.generateUID());
  },

  /**
   * get data to copy record
   *
   * @param {Tine.Tinebase.data.Record} record
   * @param recordClass
   * @param {Boolean} omitCopyTitle
   */
  getCopyRecordData: function getCopyRecordData(record, recordClass, omitCopyTitle) {
    var _ = window.lodash,
        titleProperty = recordClass.getMeta('titleProperty'),
        omitFields = _.concat(recordClass.getMeta('copyOmitFields') || [], // 2017-12-21 - cweiss - why where attachments omitted? if you know please document here!
    ['id', 'notes'
    /*, 'attachments'*/
    ]),
        fields = recordClass.getFieldNames(),
        fieldsToCopy = fields.diff(omitFields),
        recordData = Ext.copyTo({}, record.data, fieldsToCopy),
        resetProperties = {
      alarms: ['id', 'record_id', 'sent_time', 'sent_message'],
      relations: ['id', 'own_id', 'created_by', 'creation_time', 'last_modified_by', 'last_modified_time']
    },
        setProperties = {
      alarms: {
        sent_status: 'pending'
      }
    };

    Ext.iterate(resetProperties, function (property, properties) {
      if (recordData.hasOwnProperty(property)) {
        var r = recordData[property];

        for (var index = 0; index < r.length; index++) {
          Ext.each(properties, function (prop) {
            r[index][prop] = prop == 'id' ? Tine.Tinebase.data.Record.generateUID() : null;
          });
        }
      }
    });
    Ext.iterate(setProperties, function (property, properties) {
      if (recordData.hasOwnProperty(property)) {
        var r = recordData[property];

        for (var index = 0; index < r.length; index++) {
          Ext.iterate(properties, function (prop, value) {
            r[index][prop] = value;
          });
        }
      }
    });

    if (!omitCopyTitle && !recordClass.getMeta('copyNoAppendTitle')) {
      recordData[titleProperty] = String.format(i18n._('{0} (copy)'), recordData[titleProperty]);
    }

    return recordData;
  },

  /**
   * executed after record got updated from proxy
   */
  onRecordLoad: function onRecordLoad() {
    var _ = window.lodash;
    Tine.log.debug('Tine.widgets.dialog.EditDialog::onRecordLoad() - Loading of the following record completed:');
    Tine.log.debug(this.record);

    if (!this.record.id || this.recordClass.getMeta('containerProperty') && !_.get(this.record, 'data.' + this.recordClass.getMeta('containerProperty'), false)) {
      _.set(this.record, this.recordClass.getMeta('grantsPath') + '.deleteGrant', true);

      _.set(this.record, this.recordClass.getMeta('grantsPath') + '.addGrant', true);

      _.set(this.record, this.recordClass.getMeta('grantsPath') + '.editGrant', true);
    }

    this.fixedFields.eachKey(function (field, value) {
      this.record.set(field, value);
    }, this);

    if (this.copyRecord) {
      this.doCopyRecord();
      this.window.setTitle(String.format(i18n._('Copy {0}'), this.i18nRecordName));
    } else {
      if (!this.record.id) {
        this.window.setTitle(formatMessage('{gender, select, male {Add New {recordName}} female {Add New {recordName}} other {Add New {recordName}}}', {
          gender: this.recordClass.getRecordGender(),
          recordName: this.i18nRecordName
        }));
      } else {
        this.window.setTitle(String.format(i18n._('Edit {0} "{1}"'), this.i18nRecordName, this.record.getTitle()));
      }
    }

    var ticketFn = this.onAfterRecordLoad.deferByTickets(this),
        wrapTicket = ticketFn();
    this.fireEvent('load', this, this.record, ticketFn);
    wrapTicket();
  },
  // finally load the record into the form
  onAfterRecordLoad: function onAfterRecordLoad() {
    var _ = window.lodash,
        form = this.getForm();

    if (form) {
      form.loadRecord(this.record);
      form.clearInvalid();
    }

    if (this.record && this.record.hasOwnProperty('data') && Ext.isObject(this.record.data[this.recordClass.getMeta('containerProperty')])) {
      this.updateToolbars(this.record, this.recordClass.getMeta('containerProperty'));
    } // add current timestamp as id, if this is a dependent record 


    if (this.modelConfig && this.modelConfig.isDependent == true && this.record.id == 0) {
      this.record.set('id', new Date().getTime());
    } // apply grants to fields with requiredGrant prop


    if (this.evalGrants) {
      this.getForm().items.each(function (f) {
        if (f.isFormField && f.requiredGrant !== undefined) {
          var hasRequiredGrant = _.get(this.record, this.recordClass.getMeta('grantsPath') + '.' + f.requiredGrant);

          f.setDisabled(!hasRequiredGrant);
        }
      }, this);
    }

    this.loadRequest = null;
    (function () {
      this.checkStates();
      this.record.commit();
    }).defer(100, this);
    this.hideLoadMask();
  },

  /**
   * executed when record gets updated from form
   */
  onRecordUpdate: function onRecordUpdate(callback, scope) {
    var form = this.getForm(); // merge changes from form into record

    form.updateRecord(this.record);
    this.actionUpdater.updateActions([this.record]); //TODO Use Promises instead of Tickets if async is needed

    this.fireEvent('recordUpdate', this, this.record);
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.EditDialog.superclass.onRender.call(this, ct, position); // generalized keybord map for edit dlgs

    new Ext.KeyMap(this.el, [{
      key: [10, 13],
      // ctrl + return
      ctrl: true,
      scope: this,
      fn: function fn() {
        if (this.getForm().hasOwnProperty('items')) {
          // force set last selected field
          this.getForm().items.each(function (item) {
            if (item.hasFocus) {
              item.setValue(item.getRawValue(), this.record);
            }
          }, this);
        }

        this.action_saveAndClose.execute();
      }
    }]);
    this.showLoadMask(); // init change event

    var form = this.getForm().items.each(function (item) {
      this.relayEvents(item, ['change', 'select']);
    }, this);
    this.on('change', this.checkStates, this, {
      buffer: 100
    });
    this.on('select', this.checkStates, this, {
      buffer: 100
    });
    this.window.on('beforeclose', this.onBeforeClose, this);
  },

  /**
   * update (action updateer) top and bottom toolbars
   */
  updateToolbars: function updateToolbars(record, containerField) {
    if (!this.evalGrants) {
      return;
    }

    this.actionUpdater.updateActions(record);
  },

  /**
   * get top toolbar
   */
  getToolbar: function getToolbar() {
    return this.getTopToolbar();
  },

  /**
   * is form valid?
   * 
   * @return {Boolean}
   */
  isValid: function isValid() {
    var me = this;
    return new Promise(function (fulfill, reject) {
      if (me.getForm().isValid()) {
        fulfill(true);
      } else {
        reject(me.getValidationErrorMessage());
      }
    });
  },

  /**
   * vaidates on multiple edit
   * 
   * @return {Boolean}
   */
  isMultipleValid: function isMultipleValid() {
    return true;
  },
  onBeforeClose: function onBeforeClose() {
    if (this.checkUnsavedChanges && this.window.confirmLeavSite && this.record) {
      this.checkStates();

      if (_.keys(this.record.getChanges()).length) {
        console.warn('this changes would be lost:');
        console.warn(this.record.getChanges());
        return false;
      }
    }

    this.purgeListeners();
  },

  /**
   * @private
   */
  onCancel: function onCancel(force) {
    if (force === true || this.fireEvent('beforecancel', this) !== false) {
      this.fireEvent('cancel', this);
      this.window.close(force);
    }
  },

  /**
   * @private
   */
  onSaveAndClose: function onSaveAndClose() {
    this.fireEvent('saveAndClose');
    this.onApplyChanges(true);
  },

  /**
   * generic apply changes handler
   * @param {Boolean} closeWindow
   */
  onApplyChanges: function onApplyChanges(closeWindow) {
    if (this.saving) {
      return;
    }

    this.saving = true;
    this.showLoadMask();
    var ticketFn = this.doApplyChanges.deferByTickets(this, [closeWindow]),
        wrapTicket = ticketFn();
    this.fireEvent('save', this, this.record, ticketFn);
    wrapTicket();
  },

  /**
   * is called from onApplyChanges
   * @param {Boolean} closeWindow
   */
  doApplyChanges: function doApplyChanges(closeWindow) {
    // we need to sync record before validating to let (sub) panels have 
    // current data of other panels
    this.onRecordUpdate(); // quit copy mode

    this.copyRecord = false;
    var isValid = this.isValid(),
        vBool = !!isValid,
        me = this;

    if (Ext.isDefined(isValid) && !Ext.isFunction(isValid.then)) {
      // convert legacy isValid into promise
      isValid = new Promise(function (fulfill, reject) {
        return vBool ? fulfill(true) : reject(me.getValidationErrorMessage());
      });
    }

    isValid.then(function () {
      if (me.mode !== 'local') {
        me.recordProxy.saveRecord(me.record, {
          scope: me,
          success: function success(record) {
            // override record with returned data
            me.record = record;
            me.afterIsRendered().then(me.onRecordLoad.bind(me)).then(() => {
              let ticketFn = me.onAfterApplyChanges.deferByTickets(me, [closeWindow]);
              let wrapTicket = ticketFn();
              me.fireEvent('update', Ext.util.JSON.encode(me.record.data), me.mode, me, ticketFn);
              wrapTicket();
            });
          },
          failure: me.onRequestFailed,
          timeout: 300000 // 5 minutes

        }, me.getAdditionalSaveParams(me));
      } else {
        me.afterIsRendered().then(function () {
          me.onRecordLoad();
          var ticketFn = me.onAfterApplyChanges.deferByTickets(me, [closeWindow]),
              wrapTicket = ticketFn();
          me.fireEvent('update', Ext.util.JSON.encode(me.record.data), me.mode, me, ticketFn);
          wrapTicket();
        }.bind(me));
      }
    }, function (message) {
      me.saving = false;
      me.hideLoadMask();
      Ext.MessageBox.alert(i18n._('Errors'), message);
    });
  },

  /**
   * returns additional save params
   *
   * @param {EditDialog} me
   * @returns {{duplicateCheck: boolean}}
   */
  getAdditionalSaveParams: function getAdditionalSaveParams(me) {
    return {
      duplicateCheck: me.doDuplicateCheck
    };
  },
  onAfterApplyChanges: function onAfterApplyChanges(closeWindow) {
    this.window.rename(this.windowNamePrefix + this.record.id);
    this.saving = false;

    if (closeWindow) {
      this.window.fireEvent('saveAndClose');
      this.window.close(true);
    } else {
      this.hideLoadMask();
    }
  },

  /**
   * get validation error message
   * 
   * @return {String}
   */
  getValidationErrorMessage: function getValidationErrorMessage() {
    return i18n._('Please review the fields marked red. They contain invalid values.');
  },

  /**
   * generic delete handler
   */
  onDelete: function onDelete(btn, e) {
    Ext.MessageBox.confirm(i18n._('Confirm'), String.format(i18n._('Do you really want to delete this {0}?'), this.i18nRecordName), function (_button) {
      if (btn == 'yes') {
        var deleteMask = new Ext.LoadMask(this.getEl(), {
          msg: String.format(i18n._('Deleting {0}'), this.i18nRecordName)
        });
        deleteMask.show();
        this.recordProxy.deleteRecords(this.record, {
          scope: this,
          success: function success() {
            this.window.close();
          },
          failure: function failure() {
            Ext.MessageBox.alert(i18n._('Failed'), String.format(i18n._('Could not delete {0}.'), this.i18nRecordName));
            Ext.MessageBox.hide();
          }
        });
      }
    });
  },
  onPrint: function onPrint(printMode) {
    this.onRecordUpdate();
    var renderer = new (this.printer || Ext.ux.Printer.EditDialogRenderer)();
    renderer.print(this);
  },

  /**
   * duplicate(s) found exception handler
   * 
   * @param {Object} exception
   */
  onDuplicateException: function onDuplicateException(exception) {
    var resolveGridPanel = new Tine.widgets.dialog.DuplicateResolveGridPanel({
      app: this.app,
      store: new Tine.widgets.dialog.DuplicateResolveStore({
        app: this.app,
        recordClass: this.recordClass,
        recordProxy: this.recordProxy,
        data: {
          clientRecord: exception.clientRecord,
          duplicates: exception.duplicates
        }
      }),
      fbar: ['->', this.action_cancel, this.action_saveAndClose]
    }); // intercept save handler

    resolveGridPanel.btnSaveAndClose.setHandler(function (btn, e) {
      var resolveStrategy = resolveGridPanel.store.resolveStrategy; // action discard -> close window

      if (resolveStrategy == 'discard') {
        return this.onCancel();
      }

      this.record = resolveGridPanel.store.getResolvedRecord(); // quit copy mode before populating form with resolved data

      this.copyRecord = false;
      this.onRecordLoad();
      mainCardPanel.layout.setActiveItem(this.id);
      resolveGridPanel.doLayout();
      this.doDuplicateCheck = false;
      this.onSaveAndClose();
    }, this); // place in viewport

    this.window.setTitle(String.format(i18n._('Resolve Duplicate {0} Suspicion'), this.i18nRecordName));
    var mainCardPanel = this.findParentBy(function (p) {
      return p.isWindowMainCardPanel;
    });
    mainCardPanel.add(resolveGridPanel);
    mainCardPanel.layout.setActiveItem(resolveGridPanel.id);
    resolveGridPanel.doLayout();
  },

  /**
   * generic request exception handler
   * 
   * @param {Object} exception
   */
  onRequestFailed: function onRequestFailed(exception) {
    this.saving = false;

    if (this.exceptionHandlingMap && this.exceptionHandlingMap[exception.code] && typeof this.exceptionHandlingMap[exception.code] === 'function') {
      this.exceptionHandlingMap[exception.code](exception);
    } else if (exception.code == 629) {
      this.onDuplicateException.apply(this, arguments);
    } else if (exception.code === 650) {
      Tine.Tinebase.ExceptionHandler.handleRequestException(exception, function () {
        this.onAfterApplyChanges(true);
      }, this);
    } else {
      Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
    }

    this.hideLoadMask();
  },

  /**
   * creates the relations panel, if relations are defined
   */
  initRelationsPanel: function initRelationsPanel() {
    if (!this.hideRelationsPanel && this.recordClass && this.recordClass.hasField('relations')) {
      // init relations panel before onRecordLoad
      if (!this.relationsPanel) {
        this.relationsPanel = new Tine.widgets.relation.GenericPickerGridPanel({
          anchor: '100% 100%',
          editDialog: this
        });
        this.items.items.push(this.relationsPanel);
      }
    }
  },

  /**
   * create notes panel
   */
  initNotesPanel: function initNotesPanel() {
    // This dialog is pretty generic but for some cases it's used in a differend way
    if (this.displayNotes == true) {
      this.items.items.push(new Tine.widgets.activities.ActivitiesGridPanel({
        anchor: '100% 100%',
        editDialog: this
      }));
    }
  },

  /**
   * creates attachments panel
   */
  initAttachmentsPanel: function initAttachmentsPanel() {
    if (!this.attachmentsPanel && !this.hideAttachmentsPanel && this.recordClass && this.recordClass.hasField('attachments') && Tine.Tinebase.registry.get('filesystemAvailable')) {
      this.attachmentsPanel = new Tine.widgets.dialog.AttachmentsGridPanel({
        anchor: '100% 100%',
        editDialog: this
      });
      this.items.items.push(this.attachmentsPanel);
    }
  },
  showLoadMask: async function showLoadMask() {
    return this.afterIsRendered().then(() => {
      if (this.loadMask !== false && this.i18nRecordName) {
        if (!this.loadMask) {
          this.loadMask = new Ext.LoadMask(this.getEl(), {
            msg: String.format(i18n._('Transferring {0}...'), this.i18nRecordName)
          });
        }

        this.loadMask.show();
      }
    });
  },
  hideLoadMask: async function hideLoadMask() {
    let me = this;
    return this.afterIsRendered().then(() => {
      if (this.loadMask) {
        return new Promise(resolve => {
          _.defer(() => {
            me.loadMask.hide();
            resolve();
          });
        });
      }

      return Promise.resolve();
    });
  }
});

Tine.widgets.dialog.EditDialog.getConstructor = function (recordClass) {
  var appName = recordClass.getMeta('appName'),
      modelName = recordClass.getMeta('modelName'),
      editDialogClass = Tine[appName][modelName + 'EditDialog'];
  return editDialogClass;
};

/***/ }),
/* 1313 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine*/
Ext.ns('Tine.widgets.dialog');
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.SimpleRecordEditDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * SimpleRecord Edit Dialog <br>
 *
 * @author      Philipp Schüle <p.schuele@metaways.de>
 */

Tine.widgets.dialog.SimpleRecordEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
  windowNamePrefix: 'SimpleRecordEditWindow_',
  getFormItems: function getFormItems() {
    return {
      xtype: 'tabpanel',
      border: false,
      plain: true,
      activeTab: 0,
      plugins: [{
        ptype: 'ux.tabpanelkeyplugin'
      }],
      defaults: {
        hideMode: 'offsets'
      },
      items: [{
        title: this.app.i18n._(this.recordClass.getMeta('recordName')),
        autoScroll: true,
        border: false,
        frame: true,
        layout: 'border',
        items: [{
          region: 'center',
          xtype: 'columnform',
          labelAlign: 'top',
          formDefaults: {
            xtype: 'textfield',
            anchor: '100%',
            labelSeparator: '',
            columnWidth: 1
          },
          items: [[{
            fieldLabel: this.app.i18n._('Name'),
            name: 'name',
            allowBlank: false
          }, {
            fieldLabel: this.app.i18n._('Description'),
            name: 'description',
            xtype: 'textarea'
          }]]
        }]
      }, new Tine.widgets.activities.ActivitiesTabPanel({
        app: this.appName,
        record_id: this.record && !this.copyRecord ? this.record.id : '',
        record_model: this.appName + '_Model_' + this.recordClass.getMeta('modelName')
      })]
    };
  }
});

/***/ }),
/* 1314 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.editDialog');
/**
 * @namespace   Tine.widgets.editDialog
 * @class       Tine.widgets.dialog.MultipleEditDialogPlugin
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @plugin for Tine.widgets.editDialog
 */

Tine.widgets.dialog.MultipleEditDialogPlugin = function (config) {
  Ext.apply(this, config); // uhh, quick hack to circumvent large refactoring
  // -> limitation: no two multiedit plugins shown at once (seems acceptable)

  Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.skipItems = [];
};

Tine.widgets.dialog.MultipleEditDialogPlugin.prototype = {
  /**
   * the application calling this plugin
   */
  app: null,

  /**
   * the editDialog the plugin is applied to
   */
  editDialog: null,

  /**
   * the selected records 
   */
  selectedRecords: null,

  /**
   * the selections' filter
   */
  selectionFilter: null,

  /**
   * this record is created on the fly and never saved as is, only changes to this record are sent to the backend
   */
  interRecord: null,

  /**
   * a shorthand for this.editDialog.getForm() 
   */
  form: null,

  /**
   * Array which holds the fieldConfigs which can be handled by this plugin
   * Array of Objects: { key: <the raw key>, type: <custom/default>', formField: <the corresponding form field>, recordKey: <used for getters/setters of the record>}
   * @type Array
   */
  handleFields: null,

  /**
   * if records are defined by a filterselection
   * @type 
   */
  isFilterSelect: null,

  /**
   * holds the fields which have been changed
   * @type {array} changedFields
   */
  changedFields: null,

  /**
   * count of all handled records
   * @type {Integer} totalRecordCount
   */
  totalRecordCount: null,

  /**
   * component registry to skip on multiple edit
   * @type {Array} skipItems
   */
  skipItems: [],
  // private
  isInitialised: false,

  /**
   * initializes the plugin
   */
  init: function init(ed) {
    if (this.isInitialised) {
      return;
    }

    this.isInitialised = true;
    ed.mode = 'local';
    ed.evalGrants = false;
    ed.onRecordLoad = Ext.emptyFn;
    ed.onApplyChanges = ed.onApplyChanges.createInterceptor(this.onRecordUpdate, this);
    ed.onRecordUpdate = Ext.emptyFn;
    ed.initRecord = Ext.emptyFn;
    ed.useMultiple = true;
    ed.interRecord = new ed.recordClass({});
    ed.loadRecord = true;
    ed.checkUnsavedChanges = false;
    this.app = Tine.Tinebase.appMgr.get(ed.app);
    this.handleFields = [];
    this.interRecord = ed.interRecord;

    if (ed.action_saveAndClose) {
      ed.action_saveAndClose.enable();
    }

    ed.on('fieldchange', this.findChangedFields, this);

    if (ed.hasOwnProperty('isMultipleValid') && Ext.isFunction(ed.isMultipleValid)) {
      ed.isValid = ed.isMultipleValid;
    } else {
      ed.isValid = function () {
        return true;
      };
    }

    this.editDialog = ed; // disable clearer of relation picker combos, otherwise the clearer will be shown before initializing

    if (this.editDialog.relationPickers) {
      Ext.each(this.editDialog.relationPickers, function (ff) {
        ff.combo.blurOnSelect = true;
        ff.combo.disableClearer = true;
      });
    }

    ed.on('render', async () => {
      await ed.showLoadMask();
      this.onAfterRender();
    }, this);
  },

  /**
   * method to register components which are disabled on multiple edit
   * call this from the component to disable by: Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.registerSkipItem(this);
   * @param {} item
   */
  registerSkipItem: function registerSkipItem(item) {
    this.skipItems.push(item);
  },

  /**
   * handle fields for multiedit
   */
  onAfterRender: function onAfterRender() {
    // skip registered form items
    Ext.each(this.skipItems, function (item) {
      item.setDisabled(true);
    }, this);
    var keys = []; // disable container selector - just container_id

    var field = this.editDialog.getForm().findField('container_id');

    if (field) {
      field.disable();
    } // get fields to handle


    Ext.each(this.editDialog.recordClass.getFieldNames(), function (key) {
      var field = this.editDialog.getForm().findField(key);

      if (!field) {
        Tine.log.info('No field found for property "' + key + '". Ignoring...');
        return true;
      }

      Tine.log.info('Field found for property "' + key + '".');
      keys.push({
        key: key,
        type: 'default',
        formField: field,
        recordKey: key
      });
    }, this); // get customfields to handle

    var cfConfigs = Tine.widgets.customfields.ConfigManager.getConfigs(this.app, this.editDialog.recordClass);

    if (cfConfigs) {
      Ext.each(cfConfigs, function (config) {
        var field = this.editDialog.getForm().findField('customfield_' + config.data.name);

        if (!field) {
          Tine.log.info('No customfield found for property "' + config.data.name + '". Ignoring...');
          return true;
        }

        Tine.log.info('Customfield found for property "' + config.data.name + '".');
        keys.push({
          key: config.data.name,
          type: 'custom',
          formField: field,
          recordKey: '#' + config.data.name
        });
      }, this);
    } // get relationpickerfields to handle


    if (this.editDialog.relationPickers) {
      Ext.each(this.editDialog.relationPickers, function (picker) {
        Tine.log.info('RelationPicker found. Using "' + '%' + picker.relationType + '-' + picker.fullModelName + '" as key.');
        keys.push({
          key: picker.relationType + '-' + picker.fullModelName,
          type: 'relation',
          formField: picker.combo,
          recordKey: '%' + picker.relationType + '-' + picker.fullModelName
        });
      });
    }

    Ext.each(keys, function (field) {
      var ff = field.formField; // disable fields which cannot be handled atm.

      if (!ff.isXType('textfield') && !ff.isXType('checkbox') && !ff.isXType('datetimefield') || ff.multiEditable === false) {
        Tine.log.debug('Disabling field for key "' + field.recordKey + '". Cannot be handled atm.');
        ff.setDisabled(true);
        this.interRecord.set(field.recordKey, '');
        return true;
      } // remove empty text


      if (ff.hasOwnProperty('emptyText')) {
        ff.emptyText = '';
      } // default event for init


      ff.startEvents = ['focus']; // default trigger event

      ff.triggerEvents = ['blur']; // special events for special field types

      if (ff.isXType('durationspinner')) {
        ff.emptyOnZero = true;
        ff.startEvents = ['focus', 'spin'];
        ff.triggerEvents = ['spin', 'blur'];
      } else if (ff.isXType('tinerelationpickercombo')) {// leave as it is, otherwise tinerecordpickercombobox would match
      } else if (ff.isXType('tinerecordpickercombobox')) {
        ff.startEvents = ['focus', 'expand'];
        ff.triggerEvents = ['select', 'blur'];
      } else if (ff.isXType('checkbox')) {
        ff.startEvents = ['check'];
        ff.triggerEvents = ['check', 'blur'];
      } // add field to handlefields array


      this.handleFields.push(field);
      Ext.each(ff.startEvents, function (initEvent) {
        ff.on(initEvent, this.onInitField, this, [ff]);
      }, this);
    }, this);
    this.editDialog.record = this.interRecord;
    this.onRecordLoad();
  },

  /**
   * is called when an init handler for this field is called
   * @param {Object} ff the form field
   */
  onInitField: function onInitField(ff) {
    Tine.log.info('Init handler called for field "' + ff.name + '".'); // if already initialized, dont't repeat setting start values and inserting button

    if (!ff.multipleInitialized) {
      if (!ff.isXType('checkbox')) {
        this.createMultiButton(ff);
      }

      var match = ff.hasOwnProperty('name') ? ff.name.match(/customfield_(.*)/) : null;

      if (match && match.length == 2) {
        var cf = this.interRecord.get('customfields');

        if (cf && cf.hasOwnProperty(match[1])) {
          var startValue = cf[match[1]];
        } else {
          var startValue = '';
        }
      } else {
        var startValue = this.interRecord.get(ff.name);
      }

      if (ff.isXType('addressbookcontactpicker') && ff.useAccountRecord) {
        ff.startRecord = startValue ? startValue : null;
        startValue = startValue['accountId'] ? startValue['accountId'] : null;
      } else if (ff.isXType('timefield')) {
        if (startValue.length) {
          startValue = startValue.replace(/\d{4}-\d{2}-\d{2}\s/, '').replace(/:\d{2}$/, '');
        }
      } else if (ff.isXType('trigger') && ff.triggers) {
        ff.on('blur', this.hideTriggerClearer);
        ff.on('focus', this.hideTriggerClearer);
        ff.on('select', this.hideTriggerClearer);
      } else if (Ext.isObject(startValue)) {
        startValue = startValue[ff.recordClass.getMeta('idProperty')];
        ff.startRecord = new ff.recordClass(startValue);
      } else if (ff.isXType('checkbox')) {
        var startValue = startValue == 1 ? true : false;
        ff.setValue(startValue);
      }

      ff.startingValue = startValue == undefined || startValue == null ? '' : startValue;
      Tine.log.info('Setting start value to "' + startValue + '".');
      Ext.each(ff.triggerEvents, function (triggerEvent) {
        ff.on(triggerEvent, this.onTriggerField, ff);
        ff.on('fieldchange', function () {
          this.editDialog.fireEvent('fieldchange');
        }, this);
      }, this);
      ff.multipleInitialized = true;

      if (ff.isXType('durationspinner') || ff.isXType('checkbox')) {
        ff.fireEvent(ff.triggerEvents[1]);
      }
    } else {
      if (ff.multiButton) {
        ff.multiButton.removeClass('hidden');
      }
    }
  },

  /**
   * hides the default clearer
   */
  hideTriggerClearer: function hideTriggerClearer() {
    this.triggers[0].hide();
  },

  /**
   * creates the multibutton (button to reset or clear the field value)
   * @param {Ext.form.field} formField
   */
  createMultiButton: function createMultiButton(formField) {
    var subLeft = 18;

    if (formField.isXType('tinerecordpickercombobox')) {
      formField.disableClearer = true;
      subLeft += 19;
    } else if (formField.isXType('extuxclearabledatefield')) {
      formField.disableClearer = true;

      if (!formField.multi) {
        subLeft += 17;
      }
    } else if (formField.isXType('tine.widget.field.AutoCompleteField')) {// is trigger, but without button, so do nothing
    } else if (formField.isXType('trigger')) {
      if (!formField.hideTrigger) {
        subLeft += 17;
      }
    } else if (formField.isXType('datetimefield')) {
      subLeft += 17;
    }

    var el = formField.el.parent().select('.tinebase-editmultipledialog-clearer'),
        width = formField.getWidth(),
        left = width - subLeft + 'px';
    formField.startLeft = width - subLeft;

    if (el.elements.length > 0) {
      el.setStyle({
        left: left
      });
      el.removeClass('hidden');
      return;
    }

    if (formField.isXType('combo') || formField.isXType('extuxclearabledatefield') || formField.isXType('datefield') || formField.isXType('uxspinner')) {
      left = left + ';top: 3px';
    } // create Button


    formField.multiButton = new Ext.Element(document.createElement('img'));
    formField.multiButton.set({
      'src': Ext.BLANK_IMAGE_URL,
      'ext:qtip': Ext.util.Format.htmlEncode(i18n._('Delete value from all selected records')),
      'class': 'tinebase-editmultipledialog-clearer',
      'style': 'left:' + left
    });
    formField.multiButton.addClassOnOver('over');
    formField.multiButton.addClassOnClick('click'); // handles the reset/restore button

    formField.multiButton.on('click', this.onMultiButton, formField);
    formField.el.insertSibling(formField.multiButton);
  },

  /**
   * is called if the multibutton of "this" field is triggered
   */
  onMultiButton: function onMultiButton() {
    Tine.log.debug('Multibutton called.'); // scope: formField

    if (this.multiButton.hasClass('undo')) {
      Tine.log.debug('Resetting value to "' + this.startingValue + '".');

      if (this.startRecord) {
        this.store.removeAll();
        this.reset();

        if (this.multi) {
          this.setValue('');
        } else {
          this.setValue(this.startRecord);
          this.value = this.startingValue;
        }
      } else {
        this.setValue(this.startingValue);
      }

      if (this.isXType('extuxclearabledatefield') && this.multi) {
        var startLeft = this.startLeft ? this.startLeft : 0;
        var parent = this.el.parent().select('.tinebase-editmultipledialog-clearer');
        parent.setStyle('left', startLeft + 'px');
      }

      if (this.multi) {
        this.cleared = false;
      }
    } else {
      Tine.log.debug('Clearing value.');

      if (this.isXType('extuxclearabledatefield') && this.multi) {
        var startLeft = this.startLeft ? this.startLeft : 0;
        startLeft -= 17;
        var parent = this.el.parent().select('.tinebase-editmultipledialog-clearer');
        parent.setStyle('left', startLeft + 'px');
      }

      if (this.store) {
        this.store.removeAll();
      }

      this.setValue('');

      if (this.multi) {
        this.cleared = true;
        this.allowBlank = this.origAllowBlank;
      }
    } // trigger event


    this.fireEvent(this.triggerEvents[0], this);
  },

  /*
   * is called when a trigger event is fired
   */
  onTriggerField: function onTriggerField(calledOnAfterRender) {
    // scope on formField
    Tine.log.info('Trigger handler called for field "' + this.name + '".');

    if (!this.el && calledOnAfterRender) {
      return;
    }

    if (!this.el && !calledOnAfterRender) {
      this.on('afterrender', Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.onTriggerField.createDelegate(this, [true]));
      return;
    }

    var ar = this.el.parent().select('.tinebase-editmultipledialog-dirty');
    var originalValue = this.hasOwnProperty('startingValue') ? this.startingValue : this.originalValue,
        currentValue;

    if (this.isXType('datefield')) {
      currentValue = this.fullDateTime ? this.fullDateTime.format('Y-m-d H:i:s') : '';
    } else if (this.isXType('timefield')) {
      currentValue = this.fullDateTime;
    } else {
      currentValue = this.getValue();
    }

    Tine.log.info('Start value: "' + originalValue + '", current: "' + currentValue + '"');

    if (Ext.encode(originalValue) != Ext.encode(currentValue) || this.cleared === true) {
      // if edited or cleared
      // Create or set arrow
      if (ar.elements.length > 0) {
        ar.setStyle('display', 'block');
      } else {
        var arrow = new Ext.Element(document.createElement('img'));
        arrow.set({
          'src': Ext.BLANK_IMAGE_URL,
          'class': 'tinebase-editmultipledialog-dirty',
          'height': 5,
          'width': 5
        });
        this.el.insertSibling(arrow);
      } // Set field


      this.edited = true;
      this.removeClass('tinebase-editmultipledialog-noneedit'); // Set button

      if (this.multiButton) {
        this.multiButton.addClass('undo');
        this.multiButton.removeClass('hidden');
        this.multiButton.set({
          'ext:qtip': Ext.util.Format.htmlEncode(i18n._('Undo change for all selected records'))
        });
      }
    } else {
      // If set back
      // Set arrow
      if (ar.elements.length > 0) {
        ar.setStyle('display', 'none');
      } // Set field


      this.edited = false;

      if (this.multi) {
        this.addClass('tinebase-editmultipledialog-noneedit');
      } // Set button


      if (this.multiButton) {
        this.multiButton.removeClass('undo');
        this.multiButton.addClass('hidden');
        this.multiButton.set({
          'ext:qtip': Ext.util.Format.htmlEncode(i18n._('Delete value from all selected records'))
        });
      }
    }

    this.fireEvent('fieldchange');
  },

  /**
   * waits until the dialog is rendered and fetches real records by the filter on filter selection
   */
  onRecordLoad: function onRecordLoad() {
    // fetch records from server on filterselection to get the exact difference
    if (this.isFilterSelect && this.selectionFilter) {
      this.fetchRecordsOnLoad();
    } else {
      var records = [];
      Ext.each(this.selectedRecords, function (recordData, index) {
        records.push(new this.editDialog.recordClass(recordData));
      }, this);
      this.onRecordPrepare(records);
    }
  },

  /**
   * find out which fields have differences
   */
  onRecordPrepare: function onRecordPrepare(records) {
    Ext.each(this.handleFields, function (field) {
      var refData = false;
      Ext.each(records, function (record, index) {
        if (field.type == 'relation') {
          this.setFieldValue(field, false);
        } else {
          // the first record of the selected is the reference
          if (index === 0) {
            refData = record.get(field.recordKey);
          }

          if (Ext.encode(record.get(field.recordKey)) != Ext.encode(refData)) {
            this.interRecord.set(field.recordKey, '');
            this.setFieldValue(field, false);
            return false;
          } else {
            if (index == records.length - 1) {
              this.interRecord.set(field.recordKey, refData);
              this.setFieldValue(field, true);
              return true;
            }
          }
        }
      }, this);
    }, this); // TODO: grantsProperty not handled here, not needed at the moment but sometimes, perhaps.
    //        var cp = this.editDialog.recordClass.getMeta('containerProperty') ? this.editDialog.recordClass.getMeta('containerProperty') : 'container_id';
    //        if (this.interRecord.get(cp) !== undefined) {
    //            this.interRecord.set(cp, {account_grants: {editGrant: true}});
    //        }

    this.interRecord.dirty = false;
    this.interRecord.modified = {};
    this.editDialog.window.setTitle(String.format(i18n._('Edit {0} {1}'), this.totalRecordCount, this.editDialog.i18nRecordsName));
    Tine.log.debug('loading of the following intermediate record completed:');
    Tine.log.debug(this.interRecord);
    this.editDialog.updateToolbars(this.interRecord, this.editDialog.recordClass.getMeta('containerProperty'));

    if (this.editDialog.tbarItems) {
      Ext.each(this.editDialog.tbarItems, function (item) {
        if (Ext.isFunction(item.setDisabled)) item.setDisabled(true);
        item.multiEditable = false;
      });
    } // some field sanitizing


    Ext.each(this.handleFields, function (field) {
      // handle TimeFields to set original value (not possible before)
      if (field.formField.isXType('timefield')) {
        var value = this.interRecord.get(field.key);

        if (value) {
          field.formField.setValue(Date.parseDate(value, Date.patterns.ISO8601Time));
        }
      } // handle DateTimeFields to set original value
      else if (field.formField.isXType('datetimefield')) {
          var value = this.interRecord.get(field.key);

          if (value) {
            field.formField.setValue(Date.parseDate(value, Date.patterns.ISO8601Long));
          }
        }
    }, this);

    const ticketFn = (() => {
      this.editDialog.hideLoadMask();
    }).deferByTickets(this);

    const wrapTicket = ticketFn();
    this.editDialog.fireEvent('load', this.editDialog, this.editDialog.record, ticketFn);
    wrapTicket();
  },

  /**
   * Set field value
   * @param {Ext.form.Field} field
   * @param {Boolean} samevalue true, if value is the same of all records
   */
  setFieldValue: function setFieldValue(field, samevalue) {
    var ff = field.formField;
    ff.removeClass('x-form-empty-field');

    if (!samevalue) {
      // The records does not have the same value on this field
      ff.addClass('tinebase-editmultipledialog-noneedit');
      ff.origAllowBlank = ff.allowBlank;
      ff.allowBlank = true;
      ff.multi = true;
      ff.setValue('');
      ff.originalValue = '';
      ff.clearInvalid();
      Ext.QuickTips.register({
        target: ff,
        dismissDelay: 30000,
        title: i18n._('Different Values'),
        text: i18n._('This field has different values. Editing this field will overwrite the old values.'),
        width: 200
      });

      if (ff.isXType('checkbox')) {
        this.wrapCheckbox(ff);
      }
    } else {
      // All records have the same value on this field
      if (ff.isXType('checkbox')) {
        ff.originalValue = this.interRecord.get(ff.name);
        ff.setValue(this.interRecord.get(ff.name));
      } else if (ff.isXType('tinerecordpickercombobox')) {
        var val = this.interRecord.get(field.recordKey);

        if (val) {
          if (!ff.isXType('addressbookcontactpicker')) {
            ff.startRecord = new ff.recordClass(val);
          } else {
            ff.startRecord = val;
          }
        }
      } else {
        ff.setValue(this.interRecord.get(field.recordKey));
      }
    }

    ff.edited = false;

    if (ff.isXType('checkbox')) {
      ff.on('check', function () {
        this.edited = this.originalValue !== this.getValue();
      });
    }
  },

  /**
   * Wraps the checkbox with dirty colored span
   * @param {Ext.form.Field} checkbox
   */
  wrapCheckbox: function wrapCheckbox(checkbox) {
    if (checkbox.rendered !== true) {
      this.wrapCheckbox.defer(100, this, [checkbox]);
      return;
    }

    checkbox.getEl().wrap({
      tag: 'span',
      'class': 'tinebase-editmultipledialog-dirtycheck'
    });
    checkbox.originalValue = null;
    checkbox.setValue(false);
  },
  findChangedFields: function findChangedFields() {
    this.changedFields = [];
    Ext.each(this.handleFields, function (field) {
      if (field.formField.edited === true) {
        this.changedFields.push(field);
      }
    }, this);
  },

  /**
   * is called when the form is submitted. only fieldvalues with edited=true are committed 
   * @return {Boolean}
   */
  onRecordUpdate: function onRecordUpdate() {
    if (!this.editDialog.isMultipleValid()) {
      Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
      Ext.each(this.handleFields, function (item) {
        if (item.activeError) {
          if (!item.edited) item.activeError = null;
        }
      });
      return false;
    }

    this.changedHuman = '<br /><br /><ul>';
    var changes = [];
    Ext.each(this.changedFields, function (field) {
      var ff = field.formField,
          renderer = Ext.util.Format.htmlEncode;
      var label = ff.fieldLabel ? ff.fieldLabel : ff.boxLabel ? ff.boxLabel : ff.ownerCt.fieldLabel;
      label = label ? label : ff.ownerCt.title;
      changes.push({
        name: field.type == 'relation' ? field.recordKey : ff.getName(),
        value: ff.getValue()
      });
      this.changedHuman += '<li><span style="font-weight:bold">' + label + ':</span> ';

      if (ff.isXType('checkbox')) {
        renderer = Tine.Tinebase.common.booleanRenderer;
      } else if (ff.isXType('durationspinner')) {
        renderer = Tine.Tinebase.common.minutesRenderer;
      }

      this.changedHuman += ff.lastSelectionText ? renderer(ff.lastSelectionText) : renderer(ff.getValue());
      this.changedHuman += '</li>';
    }, this); // cope with added relations

    if (this.editDialog.relationsPanel) {
      Ext.each(this.editDialog.relationsPanel.getData(), function (relation) {
        var rrc = Tine.Tinebase.data.RecordMgr.get(relation['related_model']),
            rr = new rrc(relation['related_record']),
            modelName = rrc.getRecordName(),
            title = rr.getTitle(),
            type = relation['type'] || " ";
        relation['own_id'] = "";
        relation['related_record'] = "";
        changes.push({
          name: '%add',
          value: Ext.encode(relation)
        });
        this.changedHuman += '<li><span style="font-weight:bold">' + String.format(i18n._('Add {0} Relation'), modelName) + ':</span> ';
        this.changedHuman += Ext.util.Format.htmlEncode(title);
        this.changedHuman += '</li>';
      }, this);
    }

    this.changedHuman += '</ul>';
    var filter = this.selectionFilter;

    if (changes.length > 0) {
      Ext.MessageBox.confirm(i18n._('Confirm'), String.format(i18n._('Do you really want to change these {0} records?') + this.changedHuman, this.totalRecordCount), function (_btn) {
        if (_btn == 'yes') {
          Ext.MessageBox.wait(i18n._('Please wait'), i18n._('Applying changes'));
          Ext.Ajax.request({
            url: 'index.php',
            timeout: 3600000,
            // 1 hour
            params: {
              method: 'Tinebase.updateMultipleRecords',
              appName: this.editDialog.recordClass.getMeta('appName'),
              modelName: this.editDialog.recordClass.getMeta('modelName'),
              changes: changes,
              filter: filter
            },
            success: function success(_result, _request) {
              Ext.MessageBox.hide();
              var resp = Ext.decode(_result.responseText);

              if (resp.failcount > 0) {
                var window = Tine.widgets.dialog.MultipleEditResultSummary.openWindow({
                  response: _result.responseText,
                  appName: this.app.appName,
                  recordClass: this.editDialog.recordClass
                });
                window.on('close', function () {
                  this.editDialog.fireEvent('update');
                  this.editDialog.onCancel();
                }, this);
              } else {
                this.editDialog.fireEvent('update');
                this.editDialog.onCancel();
              }
            },
            failure: function failure(exception) {
              Tine.Tinebase.ExceptionHandler.handleRequestException(exception, this.onUpdateFailure, this);
            },
            scope: this
          });
        } else {
          this.editDialog.onCancel();
        }
      }, this);
    } else {
      this.editDialog.onCancel();
    }

    return false;
  },

  /**
   * 
   * @param {} btn
   * @param {} dialog
   */
  onUpdateFailure: function onUpdateFailure(btn, dialog) {
    this.editDialog.getForm().clear();
    this.onRecordLoad();
  },

  /**
   * fetch records from backend on selectionFilter
   */
  fetchRecordsOnLoad: function fetchRecordsOnLoad() {
    Tine.log.debug('Fetching additional records...');
    this.editDialog.recordProxy.searchRecords(this.selectionFilter, null, {
      scope: this,
      success: function success(result) {
        this.onRecordPrepare.call(this, result.records);
      }
    });
  }
};
Ext.ComponentMgr.registerPlugin('multiple_edit_dialog', Tine.widgets.dialog.MultipleEditDialogPlugin);

/***/ }),
/* 1315 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.editDialog');
/**
 * @namespace   Tine.widgets.editDialog
 * @class       Tine.widgets.dialog.AddRelationsDialogPlugin
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @plugin for Tine.widgets.editDialog
 */

Tine.widgets.dialog.AddRelationsEditDialogPlugin = function (config) {
  Ext.apply(this, config);
};

Tine.widgets.dialog.AddRelationsEditDialogPlugin.prototype = {
  /**
   * the recordClass of the calling component
   * @type {Ext.data.Record} recordClass
   */
  recordClass: null,

  /**
   * the editDialog the plugin is applied to
   * @type {Tine.widgets.dialog.EditDialog} editDialog
   */
  editDialog: null,

  /**
   * relations to add
   * @type {Array}
   */
  addRelations: null,

  /**
   * the selection filter
   * @type {Object} selectionFilter
   */
  selectionFilter: null,

  /**
   * the application name of the calling component
   * @type {String} callingApp
   */
  callingApp: null,

  /**
   * the model name of the calling component
   * @type {String} callingModel
   */
  callingModel: null,

  /**
   * the configuration for the relations
   * @type {Object} relationConfig
   */
  relationConfig: null,

  /**
   * the record proxy of the calling app
   * @type {Tine.Tinebase.data.RecordProxy} recordProxy
   */
  recordProxy: null,

  /**
   * initializes the plugin
   * @var {Tine.widgets.dialog.EditDialog} ed
   */
  init: function init(ed) {
    ed.on('load', function (editDialog, record, ticketFn) {
      this.interceptor = ticketFn();
      this.fetchRecords();
    }, this);
    Tine.log.info('Init plugin "Tine.widgets.dialog.AddRelationsDialogPlugin"...'); // fetch default relation config is none is given

    this.relationConfig = this.relationConfig ? this.relationConfig : {};
    Ext.each(ed.app.getRegistry().get('relatableModels'), function (rc) {
      if (rc.relatedApp == this.callingApp && rc.relatedModel == this.callingModel) {
        Ext.applyIf(this.relationConfig, rc['default']);
        return false;
      }
    }, this);
    this.editDialog = ed;
    this.recordClass = Tine[this.callingApp].Model[this.callingModel];
    this.recordProxy = new Tine.Tinebase.data.RecordProxy({
      recordClass: this.recordClass
    });
  },

  /**
   * hook in after this.editDialog.initRecord
   */
  fetchRecords: function fetchRecords() {
    if (Ext.isBoolean(this.addRelations)) {
      Tine.log.debug('Fetching additional records...');
      this.recordProxy.searchRecords(this.selectionFilter, null, {
        scope: this,
        success: function success(result) {
          this.addRelationsOnLoad(result.records);
        }
      });
    } else {
      var records = [];
      Ext.each(this.addRelations, function (plainRecord) {
        records.push(this.recordProxy.recordReader({
          responseText: Ext.encode(plainRecord)
        }));
      }, this);
      this.addRelationsOnLoad(records);
    }
  },

  /**
   * adds the relations to the record
   * @param {Array} records
   */
  addRelationsOnLoad: function addRelationsOnLoad(records) {
    var ownIdProperty = this.editDialog.recordClass.getMeta('idProperty'),
        foreignIdProperty = this.recordClass.getMeta('idProperty');
    var existingRelations = this.editDialog.record.get('relations');
    existingRelations = Ext.isArray(existingRelations) ? existingRelations : [];
    var addRelations = [];
    Ext.each(records, function (record) {
      var add = true;
      Ext.each(existingRelations, function (existingRelation) {
        if (record.get(foreignIdProperty) == existingRelation.related_record[foreignIdProperty]) {
          add = false;
          return;
        }
      }, this);

      if (add) {
        if (record.data.hasOwnProperty('relations')) {
          delete record.data.relations;
        }

        var relation = {
          own_backend: "Sql",
          related_degree: "sibling",
          own_id: this.editDialog.record.get(ownIdProperty),
          own_model: this.editDialog.app.name + '_Model_' + this.editDialog.recordClass.getMeta('modelName'),
          related_backend: "Sql",
          related_id: record.get(foreignIdProperty),
          related_model: this.callingApp + '_Model_' + this.callingModel,
          related_record: record.data,
          remark: "",
          type: ""
        };
        Ext.apply(relation, this.relationConfig);
        addRelations.push(relation);
      }
    }, this);
    Ext.each(existingRelations, function (existingRelation) {
      if (existingRelation.related_record.hasOwnProperty('relation')) {
        delete existingRelation.related_record.relation;
      }
    }, this);
    this.editDialog.record.set('relations', existingRelations.concat(addRelations));
    this.interceptor();
  }
};
Ext.ComponentMgr.registerPlugin('addrelations_edit_dialog', Tine.widgets.dialog.AddRelationsEditDialogPlugin);

/***/ }),
/* 1316 */
/***/ (function(module, exports) {

Ext.ns('Tine.widgets.dialog');

Tine.widgets.dialog.MultipleEditResultSummary = function (config) {
  Tine.widgets.dialog.MultiOptionsDialog.superclass.constructor.call(this, config);
  this.options = config.options || {};
  this.scope = config.scope || window;
};
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.MultipleEditResultSummary
 * @extends     Ext.FormPanel
 */


Ext.extend(Tine.widgets.dialog.MultipleEditResultSummary, Ext.FormPanel, {
  layout: 'fit',
  border: false,
  labelAlign: 'top',
  items: null,
  anchor: '100% 100%',

  /**
   * Store holding the Exceptions
   * @type Ext.Store
   */
  store: null,

  /**
   * Json Response from updateMultipleRecords
   * @type String
   */
  response: null,

  /**
   * The appname of the calling app
   * @type String 
   */
  appName: null,

  /**
   * The calling app
   * @type Tinebase.Application
   */
  app: null,

  /**
   * {Ext.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,
  initComponent: function initComponent() {
    this.response = Ext.decode(this.response);

    if (!this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    } // init some translations


    if (this.app.i18n && this.recordClass !== null) {
      this.i18nRecordName = this.app.i18n.n_hidden(this.recordClass.getMeta('recordName'), this.recordClass.getMeta('recordsName'), 1);
      this.i18nRecordsName = this.app.i18n._hidden(this.recordClass.getMeta('recordsName'));
    } // init actions


    this.initActions(); // init buttons and tbar

    this.initButtons();
    this.initStore(); // get items for this dialog

    this.items = this.getFormItems();
    Tine.widgets.dialog.MultipleEditResultSummary.superclass.initComponent.call(this);
  },

  /**
   * init actions
   */
  initActions: function initActions() {
    this.action_update = new Ext.Action({
      text: i18n._('OK'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_saveAndClose'
    });
  },
  initStore: function initStore() {
    this.store = new Ext.data.JsonStore({
      mode: 'local',
      idProperty: 'id',
      fields: ['id', 'record', 'message'],
      sortInfo: {
        field: 'record',
        direction: 'ASC'
      }
    });
    this.store.loadData(this.response.exceptions);
  },

  /**
   * init buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->', this.action_update];
  },

  /**
   * is called when the component is rendered
   * @param {} ct
   * @param {} position
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.MultipleEditResultSummary.superclass.onRender.call(this, ct, position); // generalized keybord map for edit dlgs

    var map = new Ext.KeyMap(this.el, [{
      key: [10, 13],
      // ctrl + return
      ctrl: true,
      fn: this.onCancel,
      scope: this
    }]);
  },

  /**
   * closes the window
   */
  onCancel: function onCancel() {
    this.fireEvent('cancel');
    this.purgeListeners();
    this.window.close();
  },
  getFormItems: function getFormItems() {
    if (this.items) return this.items;
    var allrecs = this.response.totalcount + this.response.failcount;
    var rn = allrecs > 1 ? this.i18nRecordsName : this.i18nRecordName;
    var summary = String.format(i18n._('You edited {0} {1}.'), allrecs, rn);
    summary += '<br />';
    rn = this.response.totalcount > 1 ? this.i18nRecordsName : this.i18nRecordName;
    summary += String.format(this.response.totalcount > 1 ? i18n._('{0} {1} have been updated properly.') : i18n._('{0} {1} has been updated properly.'), this.response.totalcount, rn);
    summary += '<br />';
    rn = this.response.failcount > 1 ? this.i18nRecordsName : this.i18nRecordName;
    summary += String.format(this.response.failcount > 1 ? i18n._('{0} {1} have invalid data after updating. These {1} have not been changed.') : i18n._('{0} {1} has invalid data after updating. This {1} has not been changed.'), this.response.failcount, rn);
    return {
      border: false,
      cls: 'x-ux-display',
      layout: 'ux.display',
      frame: true,
      autoScroll: true,
      items: [{
        height: 100,
        border: false,
        items: [{
          hideLabel: true,
          xtype: 'ux.displayfield',
          value: summary,
          htmlEncode: false,
          style: 'padding: 0 5px; color: black',
          cls: 'x-panel-mc'
        }],
        hideLabel: true,
        ref: '../../summaryPanelInfo',
        layout: 'ux.display',
        layoutConfig: {
          background: 'border'
        }
      }, {
        baseCls: 'ux-arrowcollapse',
        cls: 'ux-arrowcollapse-plain',
        collapsible: true,
        hidden: false,
        flex: 1,
        title: '',
        ref: '../../summaryPanelFailures',
        items: [{
          xtype: 'grid',
          store: this.store,
          autoHeight: true,
          columns: [{
            id: 'id',
            header: i18n._('Index'),
            width: 60,
            sortable: false,
            dataIndex: 'id',
            hidden: true
          }, {
            id: 'record',
            header: this.i18nRecordName,
            width: 160,
            sortable: true,
            dataIndex: 'record',
            renderer: function renderer(value) {
              return value.n_fn;
            }
          }, {
            id: 'failure',
            header: i18n._('Failure'),
            width: 60,
            sortable: true,
            dataIndex: 'message'
          }],
          autoExpandColumn: 'failure'
        }]
      }]
    };
  }
});

Tine.widgets.dialog.MultipleEditResultSummary.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 600,
    height: 450,
    modal: true,
    title: i18n._('Summary'),
    contentPanelConstructor: 'Tine.widgets.dialog.MultipleEditResultSummary',
    contentPanelConstructorConfig: config
  });
  return window;
};

/***/ }),
/* 1317 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.display');
/**
 * @class       Tine.widgets.display.RecordDisplayPanel
 * @namespace   Tine.widgets.display
 * @extends     Ext.ux.display.DisplayPanel
 *
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 *
 * Panel for displaying information of a singel record.
 */

Tine.widgets.display.RecordDisplayPanel = Ext.extend(Ext.ux.display.DisplayPanel, {
  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class
   */
  recordClass: null,

  /**
   * @property {String}
   */
  appName: null,

  /**
   * @property {String}
   */
  modelName: null,

  /**
   * @property {Tine.Tinebase.Application}
   */
  app: null,

  /* private */
  layout: 'fit',
  border: false,

  /**
   * initializes the component, builds this.fields, calls parent
   */
  initComponent: function initComponent() {
    this.appName = this.recordClass.getMeta('appName');
    this.modelName = this.recordClass.getMeta('modelName');
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    var containerProperty = this.recordClass.getMeta('containerProperty');

    if (!this.containerRenderer && this.recordClass.hasField(containerProperty)) {
      this.containerRenderer = Tine.widgets.grid.RendererManager.get(this.appName, this.modelName, containerProperty, Tine.widgets.grid.RendererManager.CATEGORY_DISPLAYPANEL);
    }

    this.items = [{
      layout: 'vbox',
      border: false,
      layoutConfig: {
        align: 'stretch'
      },
      items: [{
        layout: 'hbox',
        flex: 0,
        height: 16,
        border: false,
        style: 'padding-left: 5px; padding-right: 5px',
        layoutConfig: {
          align: 'stretch'
        },
        items: this.getHeadlineItems()
      }, {
        layout: 'hbox',
        flex: 1,
        border: false,
        layoutConfig: {
          padding: '5',
          align: 'stretch'
        },
        defaults: {
          margins: '0 5 0 0'
        },
        items: this.getBodyItems()
      }]
    }];
    Tine.widgets.display.RecordDisplayPanel.superclass.initComponent.call(this);
  },
  getHeadlineItems: function getHeadlineItems() {
    var headlineItems = [{
      flex: 0.5,
      xtype: 'ux.displayfield',
      name: this.recordClass.getMeta('titleProperty'),
      style: 'padding-top: 2px',
      cls: 'x-ux-display-header',
      htmlEncode: false,
      renderer: this.titleRenderer.createDelegate(this)
    }];

    if (this.recordClass.getMeta('containerProperty')) {
      headlineItems.push({
        flex: 0.5,
        xtype: 'ux.displayfield',
        style: 'text-align: right;',
        cls: 'x-ux-display-header',
        name: this.recordClass.getMeta('containerProperty'),
        htmlEncode: false,
        renderer: this.containerRenderer
      });
    }

    return headlineItems;
  },

  /**
   * @returns {Array.<*>}
   */
  getBodyItems: function getBodyItems() {
    var modelConfig = this.recordClass.getModelConfiguration(),
        typesToExclude = ['records'],
        // most likely never fetch from backend in any grid view!
    fieldsToExclude = ['alarms', 'tags', 'notes', 'attachments', 'relations', 'customfields', this.recordClass.getMeta('idProperty'), this.recordClass.getMeta('titleProperty'), this.recordClass.getMeta('containerProperty')],
        fieldNames = this.recordClass.getFieldNames(),
        displayFields = [],
        displayAreas = [],
        textDisplayAreas = [],
        fieldDisplayArea = {
      flex: 1,
      layout: 'ux.display',
      labelWidth: 150,
      autoScroll: true,
      layoutConfig: {
        background: 'solid'
      }
    };
    Ext.each(Tine.Tinebase.Model.genericFields, function (field) {
      fieldsToExclude.push(field.name);
    });
    Ext.each(fieldNames, function (fieldName) {
      var fieldDefinition = modelConfig.fields[fieldName],
          fieldType = fieldDefinition.type || 'textfield',
          field = {
        xtype: 'ux.displayfield',
        name: fieldDefinition.fieldName,
        htmlEncode: false,
        ctCls: 'tine-tinebase-recorddisplaypanel-displayfield',
        fieldLabel: this.app.i18n._hidden(fieldDefinition.label || fieldDefinition.fieldName)
      };

      if (typesToExclude.indexOf(fieldDefinition.type) !== -1) {
        return;
      }

      if (fieldType === 'virtual') {
        field.fieldLabel = this.app.i18n._hidden(_.get(fieldDefinition, 'config.label', fieldDefinition.fieldName));
        fieldType = _.get(fieldDefinition, 'config.type', 'textfield');
      }

      if (fieldsToExclude.indexOf(fieldDefinition.fieldName) < 0 && !fieldDefinition.shy) {
        if (_.indexOf(['text', 'json', 'fulltext'], fieldType) >= 0) {
          Ext.apply(field, {
            flex: 1,
            cls: 'x-ux-display-background-border',
            xtype: 'ux.displaytextarea'
          });

          if (fieldType === 'json') {
            Ext.apply(field, {
              type: 'code/json'
            });
          }

          if (Tine.widgets.grid.RendererManager.has(this.appName, this.modelName, fieldDefinition.fieldName, Tine.widgets.grid.RendererManager.CATEGORY_DISPLAYPANEL)) {
            field.renderer = Tine.widgets.grid.RendererManager.get(this.appName, this.modelName, fieldDefinition.fieldName, Tine.widgets.grid.RendererManager.CATEGORY_DISPLAYPANEL);
            field.htmlEncode = false;
            field.nl2br = false;
          }

          textDisplayAreas.push(field);
        } else if (fieldType === 'image') {
          // should be the first area
          displayAreas.unshift({
            width: 90,
            layout: 'ux.display',
            layoutConfig: {
              background: 'solid'
            },
            items: [{
              xtype: 'ux.displayfield',
              name: fieldDefinition.fieldName,
              cls: 'preview-panel-image',
              anchor: '100% 100%',
              hideLabel: true,
              htmlEncode: false,
              // TODO move image renderer to Tinebase
              //renderer: Tine.widgets.grid.RendererManager.get(this.appName, this.modelName,
              // fieldDefinition.fieldName, Tine.widgets.grid.RendererManager.CATEGORY_DISPLAYPANEL)
              renderer: Tine.widgets.grid.RendererManager.get('Addressbook', 'Addressbook_Model_Contact', fieldDefinition.fieldName, Tine.widgets.grid.RendererManager.CATEGORY_DISPLAYPANEL)
            }]
          });
        } else {
          var renderer = Tine.widgets.grid.RendererManager.get(this.appName, this.modelName, fieldDefinition.fieldName, Tine.widgets.grid.RendererManager.CATEGORY_DISPLAYPANEL);

          if (renderer) {
            // in case a rendered value contains newlines, we convert them into <br />
            field.renderer = function () {
              let rendererValue = this.renderer.apply(this.me, arguments);

              if (rendererValue && window.lodash.isString(rendererValue) && rendererValue.includes("\n")) {
                return Ext.util.Format.nl2br(rendererValue);
              } else {
                return rendererValue;
              }
            }.bind({
              me: this,
              renderer: renderer
            });
          }

          displayFields.push(field);
        }
      }
    }, this); // auto height

    this.defaultHeight = 25 + displayFields.length * 18;
    fieldDisplayArea.items = displayFields;
    displayAreas.push(fieldDisplayArea);
    return displayAreas.concat(textDisplayAreas);
  },
  loadRecord: function loadRecord(record) {
    this.record = record;
    this.supr().loadRecord.apply(this, arguments);
  },
  titleRenderer: function titleRenderer(title) {
    return this.record ? Tine.Tinebase.EncodingHelper.encode(this.record.getTitle()) : Tine.Tinebase.EncodingHelper.encode(title);
  }
});
Ext.reg('ux.displaypanel', Ext.ux.display.DisplayPanel);

/***/ }),
/* 1318 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.display');
/**
 * @class       Tine.widgets.display.DefaultDisplayPanel
 * @namespace   Tine.widgets.display
 * @extends     Ext.ux.display.DisplayPanel
 *
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 *
 * Panel for displaying default info.
 */

Tine.widgets.display.DefaultDisplayPanel = Ext.extend(Ext.ux.display.DisplayPanel, {
  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class
   */
  recordClass: null,

  /**
   * @property {String}
   */
  appName: null,

  /**
   * @property {String}
   */
  modelName: null,

  /**
   * @property {Tine.Tinebase.Application}
   */
  app: null,

  /* private */
  layout: 'fit',
  border: false,

  /**
   * initializes the component, builds this.fields, calls parent
   */
  initComponent: function initComponent() {
    this.appName = this.recordClass.getMeta('appName');
    this.modelName = this.recordClass.getMeta('modelName');
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    this.items = [{
      layout: 'hbox',
      border: false,
      defaults: {
        margins: '0 5 0 0'
      },
      layoutConfig: {
        padding: '5',
        align: 'stretch'
      },
      items: [{
        flex: 1,
        border: false,
        layout: 'ux.display',
        layoutConfig: {
          background: 'solid',
          declaration: this.recordClass.getRecordsName()
        }
      }]
    }];
    Tine.widgets.display.DefaultDisplayPanel.superclass.initComponent.call(this);
  }
});
Ext.reg('ux.displaypanel', Ext.ux.display.DisplayPanel);

/***/ }),
/* 1319 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <alex@stintzing.net>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.TabPanelKeyPlugin
 * @author      Alexander Stintzing <alex@stintzing.net>
 */

Ext.ux.TabPanelKeyPlugin = function (config) {
  Ext.apply(this, config);
};

Ext.ux.TabPanelKeyPlugin.prototype = {
  panel: null,
  init: function init(panel) {
    this.panel = panel;
    this.panel.on('afterrender', this.onRender, this);
    this.panel.on('add', this.onItemAdd, this);
  },

  /**
   * creates shortcuts for tabs
   */
  onRender: function onRender() {
    if (!this.panel.rendered) {
      this.onRender.defer(250, this);
      return;
    }

    var tabCount = this.panel.items.length;

    for (var index = 0; index < tabCount; index++) {
      var item = this.panel.items.items[index];
      this.registerKeyMap(item, index);
    }
  },
  onItemAdd: function onItemAdd(panel, item, index) {
    this.registerKeyMap(item, index);
  },
  registerKeyMap: function registerKeyMap(item, index, el) {
    el = el || Ext.getBody();

    if (item.disabled !== true) {
      new Ext.KeyMap(el, [{
        key: index + 49,
        ctrl: true,
        scope: this,
        fn: this.switchTab
      }]);
    }
  },

  /**
   * switch to tab
   * @param Integer code
   */
  switchTab: function switchTab(code) {
    var number = parseInt(code) - 49;

    if (this.panel) {
      this.panel.setActiveTab(number);
    }
  }
};
Ext.preg('ux.tabpanelkeyplugin', Ext.ux.TabPanelKeyPlugin);

/***/ }),
/* 1320 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.editDialog');
/**
 * Token Mode Edit Plugin
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.TokenModeEditDialogPlugin
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.dialog.TokenModeEditDialogPlugin = function (config) {
  Ext.apply(this, config);
};

Tine.widgets.dialog.TokenModeEditDialogPlugin.prototype = {
  /**
   * @property app
   * @type Tine.Tinebase.Application
   */
  app: null,

  /**
   * @property editDialog
   * @type Tine.widgets.dialog.EditDialog
   */
  editDialog: null,

  /**
   * @property form
   * @type Ext.form.BasicForm
   */
  form: null,

  /**
   * @property inTokenMode
   * @type Boolean
   */
  inTokenMode: false,

  /**
   * @property selection
   * @type Array
   */
  selection: null,
  init: function init(editDialog) {
    this.editDialog = editDialog;
    this.app = Tine.Tinebase.appMgr.get(this.editDialog.app);
    this.form = this.editDialog.getForm();

    if (this.editDialog.rendered) {
      this.onAfterRender();
    } else {
      this.editDialog.on('afterrender', this.onAfterRender, this);
    }

    this.editDialog.onRecordLoad = this.editDialog.onRecordLoad.createSequence(this.onRecordLoad, this);
  },
  onAfterRender: function onAfterRender() {
    this.editDialog.getEl().on('keydown', function (e) {
      if (e.ctrlKey && e.getKey() === e.T) {
        if (this.inTokenMode) {
          this.endTokenMode();
        } else {
          this.startTokenMode();
        }
      }
    }, this);
  },
  onRecordLoad: function onRecordLoad() {
    if (this.inTokenMode) {
      // restart token mode defered to don't consume time before closeing
      this.startTokenMode.defer(100, this);
    }
  },
  startTokenMode: function startTokenMode() {
    this.initialize();

    if (this.inTokenMode) {
      this.endTokenMode();
    }

    this.inTokenMode = true;
    this.selection = [];
    this.form.items.each(function (item) {
      if (item instanceof Ext.form.TextField && !item.disabled && !item.forceSelection) {
        if (item.rendered) {
          this.tokenizeField(item);
        } else {
          item.on('render', this.tokenizeField, this);
        }
      }
    }, this);
  },
  endTokenMode: function endTokenMode() {
    if (this.inTokenMode) {
      this.inTokenMode = false;
      Ext.select('div[class^=tinebase-tokenedit-tokenbox]', this.editDialog.getEl()).remove();
      this.form.items.each(function (item) {
        item.un('render', this.tokenizeField, this);
        item.un('resize', this.syncFieldSize, this);
      }, this);
    }
  },
  initialize: function initialize() {
    if (!this.isInitialized) {
      this.isInitialized = true; //this.editDialog.getEl().on('dblclick', this.endTokenMode, this);

      this.dragZone = new Ext.dd.DragZone(this.editDialog.getEl(), {
        getDragData: this.getDragData.createDelegate(this),
        getRepairXY: Ext.emptyFn
      });
      this.dropZone = new Ext.dd.DropZone(this.editDialog.getEl(), {
        onNodeOver: this.onNodeOver.createDelegate(this),
        onNodeDrop: this.onNodeDrop.createDelegate(this),
        getTargetFromEvent: this.getTargetFromEvent.createDelegate(this)
      });
      this.editDialog.getEl().on('mousedown', this.onClick, this);
    }
  },
  tokenizeField: function tokenizeField(field) {
    if (!this.inTokenMode || !field.itemCt) {
      // token mode might be stopped in the meantime
      return;
    }

    var el = field.itemCt.insertFirst({
      'tag': 'div',
      'class': 'tinebase-tokenedit-tokenbox x-form-text' + (field instanceof Ext.form.TextArea ? ' tinebase-tokenedit-tokenbox-area' : '')
    });
    this.syncFieldSize(field);
    field.on('resize', this.syncFieldSize, this);
    var value = Ext.util.Format.htmlEncode(field.getValue());

    if (value) {
      value = value.replace(/\n/g, ' &#x21A9; ');
      var tokens = String(value).split(/\s+/);
      this.getTokenTpl().overwrite(el, tokens);
    }
  },
  syncFieldSize: function syncFieldSize(field) {
    var el = field.itemCt.down('div[class^=tinebase-tokenedit-tokenbox]');
    el.setBox(field.el.getBox());
  },
  getTokenTpl: function getTokenTpl() {
    if (!this.tokenTpl) {
      this.tokenTpl = new Ext.XTemplate('<tpl for=".">', '<span class="tinebase-tokenedit-token">{.}</span>', '</tpl>').compile();
    }

    return this.tokenTpl;
  },
  onClick: function onClick(e) {
    if (this.processedEvent == e.browserEvent) {
      return;
    }

    this.processedEvent = e.browserEvent;
    var target = e.getTarget('.tinebase-tokenedit-token', 10, true);

    if (target) {
      if (e.ctrlKey) {
        if (this.selection.indexOf(target) < 0) {
          this.selection.push(target);
          target.addClass('tinebase-tokenedit-token-selected');
        } else {
          this.selection.remove(target);
          target.removeClass('tinebase-tokenedit-token-selected');
        }
      } else {
        Ext.each(this.selection, function (el) {
          el.removeClass('tinebase-tokenedit-token-selected');
        }, this);
        this.selection = [target];
        target.addClass('tinebase-tokenedit-token-selected');
      }
    }
  },
  getDragData: function getDragData(e) {
    var target = e.getTarget('.tinebase-tokenedit-token', 10, true);

    if (target) {
      // autoselect token
      if (this.selection.indexOf(target) < 0) {
        this.onClick(e);
      }

      this.processedEvent = e.browserEvent;
      var ddel = new Ext.Element(document.createElement('div'));
      ddel.id = Ext.id();
      var sourceFields = [];
      Ext.each(this.selection, function (el) {
        sourceFields.push(Ext.getCmp(el.parent('div[class^=tinebase-tokenedit-tokenbox]').parent('div').child('*[id^=ext-comp]').id));
        var clone = el.dom.cloneNode(true);
        clone.id = Ext.id();
        ddel.appendChild(clone);
      }, this);
      return {
        ddel: ddel.dom,
        sourceFields: sourceFields
      };
    }
  },
  getTargetFromEvent: function getTargetFromEvent(e) {
    var target = e.getTarget('.tinebase-tokenedit-tokenbox', 10, true);
    this.getPositionEl().setStyle('display', target ? 'inline-block' : 'none');
    return target;
  },
  onNodeOver: function onNodeOver(target, dd, e, data) {
    var tokens = target.query('.tinebase-tokenedit-token'),
        nextToken = null,
        nextTokenBox = null,
        eventXY = e.getXY(); // find the 'nearest' other token

    Ext.each(tokens, function (el) {
      var token = Ext.get(el),
          box = token.getBox();
      var dx = eventXY[0] > box[0] ? Math.max(0, Math.min(eventXY[0] - box[0], eventXY[0] - box['right'])) : Math.max(0, Math.min(box[0] - eventXY[0], box['right'] - eventXY[0]));
      var dy = eventXY[1] > box[1] ? Math.max(0, Math.min(eventXY[1] - box[1], eventXY[1] - box['bottom'])) : Math.max(0, Math.min(box[1] - eventXY[1], box['bottom'] - eventXY[1]));
      token.distance = dx + dy;

      if (!nextToken || token.distance < nextToken.distance) {
        nextToken = token;
        nextTokenBox = box;
      }
    }, this);

    if (nextToken) {
      // show positioning symbol left or right to nearest token
      data.insertPosition = eventXY[0] > nextTokenBox['x'] + nextTokenBox['width'] / 2 ? 'insertAfter' : 'insertBefore';
      this.getPositionEl()[data.insertPosition](nextToken);
    } else {
      target.insertFirst(this.getPositionEl());
    } // cache nextToken


    data.nextToken = nextToken;
    return Ext.dd.DropZone.prototype.dropAllowed;
  },
  onNodeDrop: function onNodeDrop(target, dd, e, data) {
    var field = Ext.getCmp(target.up('div').child('*[id^=ext-comp]').id),
        positionEl = this.getPositionEl();
    positionEl.setStyle('display', 'none');
    Ext.each(this.selection, function (el) {
      el.insertBefore(positionEl);
    }, this); // update source and target fields

    Ext.each([field].concat(data.sourceFields), function (f) {
      var value = [];
      Ext.each(f.itemCt.query('.tinebase-tokenedit-token'), function (el) {
        value.push(el.innerHTML);
      }, this);
      value = value.join(' ');
      value = Ext.util.Format.htmlDecode(value.replace(/\s*\u21A9\s*/g, '\n'));
      f.setValue(value);
    }, this);
  },
  getPositionEl: function getPositionEl() {
    if (!this.positionEl) {
      this.positionEl = this.editDialog.getEl().createChild({
        'tag': 'span',
        'class': 'tinebase-tokenedit-position',
        'html': '&nbsp;'
      });
    }

    return this.positionEl;
  }
};

/***/ }),
/* 1321 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * Wizard Panel
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.WizardPanel
 * @extends     Ext.Panel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.dialog.WizardPanel = Ext.extend(Ext.Panel, {
  // private config overrides
  cls: 'tw-editdialog',
  border: false,
  layout: 'card',
  activeItem: 0,

  /**
   * init this wizard
   */
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event cancel
     * @desc Fired when user pressed cancel button
     * @param {WizardPanel} this
     * @parm {Ext.Panel} active panel
     */
    'cancel',
    /**
     * @event finish
     * @desc Fired when user pressed finish button
     * @param {WizardPanel} this
     * @parm {Ext.Panel} active panel
     */
    'finish');
    this.initFooterBar();
    this.on('afterrender', this.onAfterRender, this);
    Tine.widgets.dialog.WizardPanel.superclass.initComponent.call(this);
  },

  /**
   * back button handler
   */
  onBackButton: function onBackButton() {
    return Ext.isFunction(this.layout.activeItem.onBackButton) ? this.layout.activeItem.onBackButton() : this.navigate(-1);
  },

  /**
   * next button handler
   */
  onNextButton: function onNextButton() {
    return Ext.isFunction(this.layout.activeItem.onNextButton) ? this.layout.activeItem.onNextButton() : this.navigate(+1);
  },

  /**
   * cancel button handler
   */
  onCancelButton: function onCancelButton() {
    if (Ext.isFunction(this.layout.activeItem.onCancelButton)) {
      return this.layout.activeItem.onCancelButton();
    } else {
      this.fireEvent('cancel', this, this.layout.activeItem);
    }
  },

  /**
   * finish button handler
   */
  onFinishButton: function onFinishButton() {
    if (Ext.isFunction(this.layout.activeItem.onFinishButton)) {
      return this.layout.activeItem.onFinishButton();
    } else {
      this.fireEvent('finish', this, this.layout.activeItem);
    }
  },

  /**
   * navigate to panel
   * 
   * @param {Number/String} ref
   */
  navigate: function navigate(ref) {
    var currentIndex = this.items.indexOf(this.layout.activeItem),
        toActivatePanel = Ext.isNumber(ref) ? this.items.get(currentIndex + ref) : this.items.get(ref);

    if (toActivatePanel) {
      this.layout.setActiveItem(toActivatePanel);
      toActivatePanel.doLayout();
    }

    this.manageButtons();
  },

  /**
   * manage footer buttons
   */
  manageButtons: function manageButtons() {
    Ext.each(['back', 'next', 'cancel', 'finish'], function (key) {
      if (this[key + 'Button'] && Ext.isFunction(this[key + 'IsAllowed'])) {
        this[key + 'Button'].setDisabled(!this[key + 'IsAllowed']());
      }
    }, this);
  },

  /**
   * check if back button is allowed
   */
  backIsAllowed: function backIsAllowed() {
    var panelCondition = Ext.isFunction(this.layout.activeItem.backIsAllowed) ? this.layout.activeItem.backIsAllowed() : true;
    return panelCondition && this.items.indexOf(this.layout.activeItem) > 0;
  },

  /**
   * check if next button is allowed
   */
  nextIsAllowed: function nextIsAllowed() {
    var panelCondition = Ext.isFunction(this.layout.activeItem.nextIsAllowed) ? this.layout.activeItem.nextIsAllowed() : true;
    return panelCondition && this.items.indexOf(this.layout.activeItem) < this.items.getCount() - 1;
  },

  /**
   * check if cancel button is allowed
   */
  cancelIsAllowed: function cancelIsAllowed() {
    var panelCondition = Ext.isFunction(this.layout.activeItem.cancelIsAllowed) ? this.layout.activeItem.cancelIsAllowed() : true;
    return panelCondition && true;
  },

  /**
   * check if finish button is allowed
   */
  finishIsAllowed: function finishIsAllowed() {
    var panelCondition = Ext.isFunction(this.layout.activeItem.finishIsAllowed) ? this.layout.activeItem.finishIsAllowed() : true;
    return panelCondition && this.items.indexOf(this.layout.activeItem) == this.items.getCount() - 1;
  },

  /**
   * init footer bar
   */
  initFooterBar: function initFooterBar() {
    this.fbar = ['->', {
      text: i18n._('Back'),
      minWidth: 70,
      ref: '../backButton',
      iconCls: 'action_previous',
      scope: this,
      handler: this.onBackButton
    }, {
      text: i18n._('Next'),
      minWidth: 70,
      ref: '../nextButton',
      iconCls: 'action_next',
      scope: this,
      handler: this.onNextButton
    }, {
      text: i18n._('Cancel'),
      minWidth: 70,
      ref: '../cancelButton',
      iconCls: 'action_cancel',
      scope: this,
      handler: this.onCancelButton
    }, {
      text: i18n._('Finish'),
      minWidth: 70,
      ref: '../finishButton',
      iconCls: 'action_saveAndClose',
      scope: this,
      handler: this.onFinishButton
    }];
  },

  /**
   * called after this wizard is rendered
   */
  onAfterRender: function onAfterRender() {
    this.manageButtons();
  }
});
Ext.reg('tw-wizardpanel', Tine.widgets.dialog.WizardPanel);

/***/ }),
/* 1322 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Admin
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * admin settings panel
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.AdminPanel
 * @extends     Tine.widgets.dialog.EditDialog
 * 
 * <p>Admin Panel</p>
 * <p><pre>
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.dialog.AdminPanel
 */

Tine.widgets.dialog.AdminPanel = Ext.extend(Tine.widgets.dialog.EditDialog, {
  /**
   * @private
   */
  appName: 'Admin',
  recordClass: Tine.Tinebase.Model.Config,
  evalGrants: false,
  //private
  initComponent: function initComponent() {
    this.record = new this.recordClass({
      id: this.appName
    });
    Tine.widgets.dialog.AdminPanel.superclass.initComponent.call(this);
  },

  /**
   * executed after record got updated from proxy
   */
  onRecordLoad: function onRecordLoad() {
    // interrupt process flow until dialog is rendered
    if (!this.rendered) {
      this.onRecordLoad.defer(250, this);
      return;
    }

    this.window.setTitle(String.format(i18n._('Change settings for application {0}'), this.appName));

    if (this.fireEvent('load', this) !== false) {
      var settings = this.record.get('settings'),
          form = this.getForm();

      for (var setting in settings) {
        form.findField(setting).setValue(settings[setting]);
      }

      form.clearInvalid();
      this.loadMask.hide();
    }
  },

  /**
   * executed when record gets updated from form
   */
  onRecordUpdate: function onRecordUpdate() {
    // merge changes from form into settings
    var settings = this.record.get('settings'),
        form = this.getForm(),
        newSettings = {};

    for (var setting in settings) {
      newSettings[setting] = form.findField(setting).getValue();
    }

    this.record.set('settings', newSettings); // TODO update registry
  },

  /**
   * returns dialog
   * 
   * NOTE: when this method gets called, all initalisation is done.
   * 
   * @return {Object}
   * @private
   */
  getFormItems: function getFormItems() {
    return {
      xtype: 'tabpanel',
      activeTab: 0,
      border: false,
      items: [{
        title: i18n._('Defaults'),
        autoScroll: true,
        border: false,
        frame: true,
        xtype: 'columnform',
        formDefaults: {
          anchor: '90%',
          labelSeparator: '',
          columnWidth: 1
        },
        items: this.getConfigItems()
      }]
    };
  },

  /**
   * get config items
   * - overwrite this in subclasses
   * 
   * @return {Array}
   */
  getConfigItems: function getConfigItems() {
    return [];
  }
});

/***/ }),
/* 1323 */
/***/ (function(module, exports) {

/**
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * TODO         add general local + modal dialog (can be used here, in Tine.Courses.AddMemberDialog and ...)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * Generic 'Credentials' dialog
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.CredentialsDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @constructor
 * @param       {Object} config The configuration options.
 */

Tine.widgets.dialog.CredentialsDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
  credentialsId: null,

  /**
   * @private
   */
  windowNamePrefix: 'CredentialsWindow_',
  loadRecord: false,
  tbarItems: [],
  evalGrants: false,
  sendRequest: true,
  mode: 'local',

  /**
   * returns dialog
   */
  getFormItems: function getFormItems() {
    return {
      bodyStyle: 'padding:5px;',
      buttonAlign: 'right',
      labelAlign: 'top',
      border: false,
      layout: 'form',
      defaults: {
        xtype: 'textfield',
        anchor: '90%',
        listeners: {
          scope: this,
          specialkey: function specialkey(field, event) {
            if (event.getKey() == event.ENTER) {
              this.onApplyChanges();
            }
          }
        }
      },
      items: [{
        fieldLabel: i18n._('Username'),
        name: 'username',
        allowBlank: false
      }, {
        fieldLabel: i18n._('Password'),
        name: 'password',
        xtype: 'tw-passwordTriggerField',
        clipboard: false
      }]
    };
  },

  /**
   * executed after record got updated from proxy
   * 
   * @private
   */
  onRecordLoad: function onRecordLoad() {
    // interrupt process flow till dialog is rendered
    if (!this.rendered) {
      this.onRecordLoad.defer(250, this);
      return;
    }

    var title = this.windowTitle || this.app.i18n._('Please enter your credentials');

    this.window.setTitle(title);
    this.getForm().loadRecord(this.record);
    this.hideLoadMask();
  },

  /**
   * generic apply changes handler
   */
  onApplyChanges: function onApplyChanges() {
    var form = this.getForm();

    if (form.isValid()) {
      var values = form.getFieldValues();

      if (this.sendRequest) {
        this.loadMask.show();
        var params = {
          method: this.appName + '.changeCredentials',
          password: values.password,
          username: values.username,
          id: this.credentialsId
        };
        Ext.Ajax.request({
          params: params,
          scope: this,
          success: function success(_result, _request) {
            this.hideLoadMask();
            this.fireEvent('update', _result);
            this.purgeListeners();
            this.window.close();
          }
        });
      } else {
        this.fireEvent('update', values);
        this.window.close();
      }
    } else {
      Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
    }
  }
});
/**
 * credentials dialog popup / window
 */

Tine.widgets.dialog.CredentialsDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 240,
    height: 180,
    name: Tine.widgets.dialog.CredentialsDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.CredentialsDialog',
    contentPanelConstructorConfig: config,
    modal: true
  });
  return window;
};

/***/ }),
/* 1324 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @subpackage  widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * @todo        add filter toolbar
 * @todo        use proxy store?
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * 'Edit Preferences' dialog
 *
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.Preferences
 * @extends     Ext.FormPanel
 * @constructor
 * @param       {Object} config The configuration options.
 */

Tine.widgets.dialog.Preferences = Ext.extend(Ext.FormPanel, {
  /**
   * @property {Locale.gettext} i18n
   */
  i18n: null,

  /**
   * @property {Tine.widgets.dialog.PreferencesCardPanel} prefsCardPanel
   */
  prefsCardPanel: null,

  /**
   * @property {Tine.widgets.dialog.PreferencesTreePanel} treePanel
   */
  treePanel: null,

  /**
   * @property {Object} prefPanels
   * here we store the pref panels for all apps
   */
  prefPanels: {},

  /**
   * @property {boolean} adminMode
   * when adminMode is activated -> show defaults/forced values
   */
  adminMode: false,

  /**
   * @property {Object} prefPanels
   * here we store the pref panels for all apps [admin mode]
   */
  adminPrefPanels: {},

  /**
   * @cfg String  initialCardName to select after render
   */
  initialCardName: null,
  // private
  layout: 'fit',
  cls: 'tw-editdialog',
  anchor: '100% 100%',
  buttonAlign: 'right',
  border: false,
  //private
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event cancel
     * Fired when user pressed cancel button
     */
    'cancel',
    /**
     * @event saveAndClose
     * Fired when user pressed OK button
     */
    'saveAndClose',
    /**
     * @event update
     * @desc  Fired when the record got updated
     * @param {Json String} data data of the entry
     */
    'update');
    this.i18n = new Locale.Gettext();
    this.i18n.textdomain('Tinebase');
    this.initActions();
    this.initButtons();
    this.items = this.getItems();
    Tine.widgets.dialog.Preferences.superclass.initComponent.call(this);
  },

  /**
   * init actions
   * 
   * @todo only allow admin mode if user has admin right
   */
  initActions: function initActions() {
    this.action_saveAndClose = new Ext.Action({
      text: i18n._('Ok'),
      minWidth: 70,
      scope: this,
      handler: this.onSaveAndClose,
      iconCls: 'action_saveAndClose'
    });
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    });
    this.action_switchAdminMode = new Ext.Action({
      text: i18n._('Admin Mode'),
      minWidth: 70,
      scope: this,
      handler: this.onSwitchAdminMode,
      iconCls: 'action_adminMode',
      enableToggle: true
    });
  },

  /**
   * init buttons
   * use preference settings for order of save and close buttons
   */
  initButtons: function initButtons() {
    this.buttons = [];
    this.buttons.push(this.action_cancel, this.action_saveAndClose);
    this.tbar = new Ext.Toolbar({
      items: [this.action_switchAdminMode]
    });
  },

  /**
   * returns dialog
   * 
   * NOTE: when this method gets called, all initalisation is done.
   */
  getItems: function getItems() {
    this.prefsCardPanel = new Tine.widgets.dialog.PreferencesCardPanel({
      region: 'center'
    });
    this.treePanel = new Tine.widgets.dialog.PreferencesTreePanel({
      title: i18n._('Applications'),
      region: 'west',
      width: 200,
      border: false,
      frame: false,
      initialNodeId: this.initialCardName
    });
    return [{
      xtype: 'panel',
      autoScroll: true,
      border: false,
      frame: false,
      layout: 'border',
      items: [this.treePanel, this.prefsCardPanel]
    }];
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.Preferences.superclass.onRender.call(this, ct, position); // recalculate height, as autoHeight fails for Ext.Window ;-(

    this.setHeight(Ext.fly(this.el.dom.parentNode).getHeight());
    this.window.setTitle(this.i18n._('Edit Preferences'));
    this.loadMask = new Ext.LoadMask(ct, {
      msg: i18n._('Loading ...')
    });
  },

  /**
   * @private
   */
  onCancel: function onCancel() {
    this.fireEvent('cancel');
    this.purgeListeners();
    this.window.close();
  },

  /**
   * @private
   * 
   * TODO check if this is working correctly
   */
  onDestroy: function onDestroy() {
    // delete panels
    for (var panelName in this.adminPrefPanels) {
      if (this.adminPrefPanels.hasOwnProperty(panelName)) {
        if (this.adminPrefPanels[panelName] !== null) {
          this.adminPrefPanels[panelName].destroy();
          this.adminPrefPanels[panelName] = null;
        }
      }
    }

    for (panelName in this.prefPanels) {
      if (this.prefPanels.hasOwnProperty(panelName)) {
        if (this.prefPanels[panelName] !== null) {
          this.prefPanels[panelName].destroy();
          this.prefPanels[panelName] = null;
        }
      }
    }

    this.prefsCardPanel.destroy();
    this.prefsCardPanel = null;
    Tine.widgets.dialog.Preferences.superclass.onDestroy.apply(this, arguments);
  },

  /**
   * @private
   */
  onSaveAndClose: function onSaveAndClose() {
    this.onApplyChanges(true);
    this.fireEvent('saveAndClose');
  },

  /**
   * apply changes handler
   */
  onApplyChanges: function onApplyChanges(closeWindow) {
    if (!this.isValid()) {
      Ext.MessageBox.alert(i18n._('Errors'), i18n._('You need to correct the red marked fields before config could be saved'));
      return;
    }

    this.loadMask.show(); // get values from card panels

    var data = this.getValuesFromPanels(); // save preference data

    Ext.Ajax.request({
      scope: this,
      params: {
        method: 'Tinebase.savePreferences',
        data: data,
        adminMode: this.adminMode ? 1 : 0
      },
      success: function success(response) {
        this.loadMask.hide(); // update registry

        this.updateRegistry(Ext.util.JSON.decode(response.responseText).results);

        if (closeWindow) {
          this.purgeListeners();
          this.window.close();
        }
      },
      failure: function failure(response) {
        Ext.MessageBox.alert(i18n._('Errors'), i18n._('Saving of preferences failed.'));
      }
    });
  },

  /**
   * check all panels if they are valid
   * 
   * @return {Boolean}
   */
  isValid: function isValid() {
    var panel = {};
    var panelsToSave = this.adminMode ? this.adminPrefPanels : this.prefPanels;

    for (panelName in panelsToSave) {
      panel = panelsToSave[panelName];

      if (panel && typeof panel.isValid === 'function' && !panel.isValid()) {
        return false;
      }
    }

    return true;
  },

  /**
   * get values from card panels
   * 
   * @return {Object} with form data
   */
  getValuesFromPanels: function getValuesFromPanels() {
    var panel,
        data = {};
    var panelsToSave = this.adminMode ? this.adminPrefPanels : this.prefPanels;

    for (panelName in panelsToSave) {
      if (panelsToSave.hasOwnProperty(panelName)) {
        panel = panelsToSave[panelName];

        if (panel !== null) {
          data[panel.appName] = {};

          for (var j = 0; j < panel.items.length; j++) {
            var item = panel.items.items[j];

            if (item && item.name) {
              if (this.adminMode) {
                // filter personal_only (disabled) items
                if (!item.disabled) {
                  data[panel.appName][item.prefId] = {
                    value: item.getValue(),
                    name: item.name
                  };
                  data[panel.appName][item.prefId].type = Ext.getCmp(item.name + '_writable').getValue() == 1 ? 'default' : 'forced';
                }
              } else {
                data[panel.appName][item.name] = {
                  value: item.getValue()
                };
              }
            }
          }
        }
      }
    }

    return data;
  },

  /**
   * update registry after saving of prefs
   * 
   * @param {Object} data
   */
  updateRegistry: function updateRegistry(data) {
    for (application in data) {
      if (data.hasOwnProperty(application)) {
        appPrefs = data[application];
        var registryValues = Tine[application].registry.get('preferences');
        var changed = false;

        for (var i = 0; i < appPrefs.length; i++) {
          if (registryValues.get(appPrefs[i].name) != appPrefs[i].value) {
            registryValues.replace(appPrefs[i].name, appPrefs[i].value);
            changed = true;
          }
        }

        if (changed) {
          Tine[application].registry.replace('preferences', registryValues);
        }
      }
    }
  },

  /**
   * onSwitchAdminMode
   * 
   * @private
   * 
   * @todo enable/disable apps according to admin right for applications
   */
  onSwitchAdminMode: function onSwitchAdminMode(button, event) {
    this.adminMode = !this.adminMode;

    if (this.adminMode) {
      this.prefsCardPanel.addClass('prefpanel_adminMode');
    } else {
      this.prefsCardPanel.removeClass('prefpanel_adminMode');
    } // activate panel in card panel


    var selectedNode = this.treePanel.getSelectionModel().getSelectedNode();

    if (selectedNode) {
      this.showPrefsForApp(this.treePanel.getSelectionModel().getSelectedNode().id);
    }

    this.treePanel.checkGrants(this.adminMode);
  },

  /**
   * init app preferences store
   * 
   * @param {String} appName
   * 
   * @todo use generic json backend here?
   */
  initPrefStore: function initPrefStore(appName) {
    this.loadMask.show(); // set filter to get only default/forced values if in admin mode

    var filter = this.adminMode ? [{
      field: 'account',
      operator: 'equals',
      value: {
        accountId: 0,
        accountType: 'anyone'
      }
    }] : '';
    var store = new Ext.data.JsonStore({
      fields: Tine.Tinebase.Model.Preference,
      baseParams: {
        method: 'Tinebase.searchPreferencesForApplication',
        applicationName: appName,
        filter: filter
      },
      listeners: {
        load: this.onStoreLoad,
        scope: this
      },
      root: 'results',
      totalProperty: 'totalcount',
      id: 'id',
      remoteSort: false
    });
    store.load();
  },

  /**
   * called after a new set of preference Records has been loaded
   * 
   * @param  {Ext.data.Store} this.store
   * @param  {Array}          loaded records
   * @param  {Array}          load options
   */
  onStoreLoad: function onStoreLoad(store, records, options) {
    var appName = store.baseParams.applicationName;
    var card = new Tine.widgets.dialog.PreferencesPanel({
      prefStore: store,
      appName: appName,
      adminMode: this.adminMode
    });
    card.on('change', function (appName) {
      // mark card as changed in tree
      var node = this.treePanel.getNodeById(appName);
      node.setText(node.text + '*');
    }, this); // add to panel registry

    if (this.adminMode) {
      this.adminPrefPanels[appName] = card;
    } else {
      this.prefPanels[appName] = card;
    }

    this.activateCard(card, false);
    this.loadMask.hide();
  },

  /**
   * activateCard in preferences panel
   * 
   * @param {Tine.widgets.dialog.PreferencesPanel} panel
   * @param {boolean} exists
   */
  activateCard: function activateCard(panel, exists) {
    if (!exists) {
      this.prefsCardPanel.add(panel);
      this.prefsCardPanel.layout.container.add(panel);
    }

    this.prefsCardPanel.layout.setActiveItem(panel.id);
    panel.doLayout();
  },

  /**
   * showPrefsForApp 
   * - check stores (create new store if not exists)
   * - activate pref panel for app
   * 
   * @param {String} appName
   */
  showPrefsForApp: function showPrefsForApp(appName) {
    // TODO: invent panel hooking approach here
    if (appName === 'Tinebase.UserProfile') {
      if (!this.prefPanels[appName]) {
        this.prefPanels[appName] = new Tine.Tinebase.UserProfilePanel({
          appName: appName
        });
        this.activateCard(this.prefPanels[appName], false);
      }
    }

    var panel = this.adminMode ? this.adminPrefPanels[appName] : this.prefPanels[appName];

    if (!this.adminMode) {
      // check grant for pref and enable/disable button
      this.action_switchAdminMode.setDisabled(!Tine.Tinebase.common.hasRight('admin', appName));
    } // check stores/panels


    if (!panel) {
      // add new card + store
      this.initPrefStore(appName);
    } else {
      this.activateCard(panel, true);
    }
  }
});
/**
 * Timetracker Edit Popup
 */

Tine.widgets.dialog.Preferences.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 800,
    height: 470,
    name: 'Preferences',
    contentPanelConstructor: 'Tine.widgets.dialog.Preferences',
    contentPanelConstructorConfig: config
  });
  return window;
};

/***/ }),
/* 1325 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @subpackage  widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * @todo        create generic app tree panel?
 * @todo        add button: set default value(s)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * preferences application tree panel
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.PreferencesTreePanel
 * @extends     Ext.tree.TreePanel
 */

Tine.widgets.dialog.PreferencesTreePanel = Ext.extend(Ext.tree.TreePanel, {
  /**
   * @cfg String  initialNodeId to select after render
   */
  initialNodeId: null,
  // presets
  iconCls: 'x-new-application',
  rootVisible: true,
  border: false,
  autoScroll: true,
  bodyStyle: 'background-color:white',

  /**
   * initComponent
   * 
   */
  initComponent: function initComponent() {
    Tine.widgets.dialog.PreferencesTreePanel.superclass.initComponent.call(this);
    this.initTreeNodes();
    this.initHandlers();
    this.selectInitialNode.defer(200, this);
  },

  /**
   * select initial node
   */
  selectInitialNode: function selectInitialNode() {
    var initialNode = this.initialNodeId !== null ? this.getNodeById(this.initialNodeId) : this.getRootNode();
    this.fireEvent('click', initialNode);
  },

  /**
   * initTreeNodes with Tinebase and apps prefs
   * 
   * @private
   */
  initTreeNodes: function initTreeNodes() {
    // general preferences are tree root
    var treeRoot = new Ext.tree.TreeNode({
      text: i18n._('General Preferences'),
      id: 'Tinebase',
      draggable: false,
      allowDrop: false,
      expanded: true
    });
    this.setRootNode(treeRoot); // add all apps

    var allApps = Tine.Tinebase.appMgr.getAll(); // sort nodes by translated title (text property)
    //        new Ext.tree.TreeSorter(this, {
    //            folderSort: true,
    //            dir: "asc"
    //        });
    // add "My Profile"

    if (Tine.Tinebase.common.hasRight('manage_own_profile', 'Tinebase')) {
      var profileNode = new Ext.tree.TreeNode({
        text: i18n._('My Profile'),
        cls: 'file',
        iconCls: 'tinebase-accounttype-user',
        id: 'Tinebase.UserProfile',
        leaf: null
      });
      treeRoot.appendChild(profileNode);
    } // console.log(allApps);


    allApps.each(function (app) {
      if (app && Ext.isFunction(app.getTitle)) {
        var node = new Ext.tree.TreeNode({
          text: app.getTitle(),
          cls: 'file',
          id: app.appName,
          iconCls: app.getIconCls('PreferencesTreePanel'),
          leaf: null
        });
        treeRoot.appendChild(node);
      }
    }, this);
  },

  /**
   * initTreeNodes with Tinebase and apps prefs
   * 
   * @private
   */
  initHandlers: function initHandlers() {
    this.on('click', function (node) {
      // note: if node is clicked, it is not selected!
      node.getOwnerTree().selectPath(node.getPath());
      node.expand(); // get parent pref panel

      var parentPanel = this.findParentByType(Tine.widgets.dialog.Preferences); // add panel to card panel to show prefs for chosen app

      parentPanel.showPrefsForApp(node.id);
    }, this);
    this.on('beforeexpand', function (_panel) {
      if (_panel.getSelectionModel().getSelectedNode() === null) {
        _panel.expandPath('/Tinebase');

        _panel.selectPath('/Tinebase');
      }

      _panel.fireEvent('click', _panel.getSelectionModel().getSelectedNode());
    }, this);
  },

  /**
   * check grants for tree nodes / apps
   * 
   * @param {Bool} adminMode
   */
  checkGrants: function checkGrants(adminMode) {
    var root = this.getRootNode();
    root.eachChild(function (node) {
      // enable or disable according to admin rights / admin mode
      if (!Tine.Tinebase.common.hasRight('admin', node.id) && adminMode) {
        node.disable();
      } else {
        node.enable();
      }
    });
  }
});

/***/ }),
/* 1326 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @subpackage  widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO         add pref description to input fields
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');
/**
 * preferences card panel
 * -> this panel is filled with the preferences subpanels containing the pref stores for the apps
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.PreferencesCardPanel
 * @extends     Ext.Panel
 */

Tine.widgets.dialog.PreferencesCardPanel = Ext.extend(Ext.Panel, {
  //private
  layout: 'card',
  border: false,
  frame: true,
  labelAlign: 'top',
  autoScroll: true,
  defaults: {
    anchor: '100%'
  },
  initComponent: function initComponent() {
    this.title = i18n._('Preferences');
    Tine.widgets.dialog.PreferencesCardPanel.superclass.initComponent.call(this);
  }
});
/**
 * preferences panel with the preference input fields for an application
 * 
 * @todo add checkbox type
 */

Tine.widgets.dialog.PreferencesPanel = Ext.extend(Ext.Panel, {
  /**
   * the prefs store
   * @cfg {Ext.data.Store}
   */
  prefStore: null,

  /**
   * @cfg {String} appName
   */
  appName: 'Tinebase',

  /**
   * @cfg {Boolean} adminMode activated?
   */
  adminMode: false,
  //private
  layout: 'form',
  border: true,
  labelAlign: 'top',
  autoScroll: true,
  defaults: {
    anchor: '95%',
    labelSeparator: ''
  },
  bodyStyle: 'padding:5px',

  /**
   * init component
   * @private
   */
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event change
     * @param appName
     * Fired when a value is changed
     */
    'change');

    if (this.prefStore && this.prefStore.getCount() > 0) {
      Tine.log.debug('Tine.widgets.dialog.PreferencesPanel::initComponent() -> Adding pref items from store:');
      Tine.log.debug(this.prefStore);
      this.items = [];
      this.prefStore.each(function (pref) {
        // check if options available -> use combobox or textfield
        var fieldDef = {
          fieldLabel: pref.get('label'),
          name: pref.get('name'),
          value: pref.get('value'),
          listeners: {
            scope: this,
            change: function change(field, newValue, oldValue) {
              // fire change event
              this.fireEvent('change', this.appName);
            }
          },
          prefId: pref.id,
          description: pref.get('description')
        };
        var options = pref.get('options'); // NOTE: some prefs have no default and only one option (e.g. std email account)

        if (options.length > 1 || options.length == 1 && options[0][0] !== '_default_') {
          if (pref.get('uiconfig') && pref.get('uiconfig').xtype) {
            // TODO support admin mode / currently this is personal_only
            Ext.apply(fieldDef, {
              xtype: pref.get('uiconfig').xtype,
              recordClass: Tine[pref.get('uiconfig').appName].Model[pref.get('uiconfig').model],
              value: pref.get('value') === '_default_' ? [] : pref.get('value')
            });
          } else {
            Ext.apply(fieldDef, {
              xtype: this.adminMode ? 'lockCombo' : 'combo',
              store: pref.get('options'),
              mode: 'local',
              forceSelection: true,
              allowBlank: false,
              triggerAction: 'all'
            });
          }
        } else {
          Ext.apply(fieldDef, {
            xtype: this.adminMode ? 'lockTextfield' : 'textfield',
            defaultValue: options[0] && options[0][1] ? options[0][1] : '',
            isValid: function isValid() {
              // crude hack to guess type (prefs need DTD)
              var type = this.defaultValue.match(/\(([0-9]*)\)$/) ? 'int' : 'string',
                  value = this.getValue(); // default is always valid

              if (value == '_default_') {
                return true;
              }

              if (type == 'int') {
                return !!String(value).match(/^\d+$/);
              }

              return true;
            },
            setValue: function setValue(v) {
              v = v == '_default_' ? this.defaultValue : v;
              Ext.form.TextField.prototype.setValue.call(this, v);
            },
            getValue: function getValue() {
              var value = Ext.form.TextField.prototype.getValue.call(this);
              return value == this.defaultValue ? '_default_' : value;
            },
            postBlur: function postBlur() {
              var value = this.getValue();

              if (value === '') {
                this.setValue('_default_');
              }
            }
          });
        }

        if (this.adminMode) {
          // set lock (value forced => hiddenFieldData = '0')
          fieldDef.hiddenFieldData = pref.get('type') == 'forced' ? '0' : '1';
          fieldDef.hiddenFieldId = pref.get('name') + '_writable'; // disable personal only fields (not quite sure why we get a string here in personal_only field)

          fieldDef.disabled = pref.get('personal_only') === '1' || pref.get('personal_only') === true;
        } else {
          fieldDef.disabled = pref.get('type') == 'forced' || pref.get('locked') == true;
        }

        try {
          var fieldObj = Ext.ComponentMgr.create(fieldDef);
          this.items.push(fieldObj); // ugh a bit ugly
          // what does that do??

          pref.fieldObj = fieldObj;
        } catch (e) {
          Tine.log.debug(e);
          Tine.log.error('Unable to create preference field "' + pref.get('name') + '". Check definition!');
          this.prefStore.remove(pref);
        }
      }, this);
    } else {
      this.html = '<div class="x-grid-empty">' + i18n._('There are no preferences for this application.') + "</div>";
    }

    Ext.QuickTips.init();
    Tine.widgets.dialog.PreferencesPanel.superclass.initComponent.call(this);
  },

  /**
   * afterRender -> adds qtips to all elements
   * 
   * @private
   * 
   * @todo add qtip to label as well
   */
  afterRender: function afterRender() {
    Tine.widgets.dialog.PreferencesPanel.superclass.afterRender.call(this); // NOTE: server side translations have problems with quotes. Preferences with quotes
    //       in their description don't get translated. Thus we (re) translate them here
    //       as the js translations are much better

    var app = Tine.Tinebase.appMgr.get(this.appName),
        gt = app ? app.i18n._.createDelegate(app.i18n) : i18n._.createDelegate(i18n);

    if (this.items && this.items.items) {
      for (var i = 0; i < this.items.items.length; i++) {
        var field = this.items.items[i];
        Ext.QuickTips.register({
          target: field,
          dismissDelay: 30000,
          title: Ext.util.Format.htmlEncode(gt(field.fieldLabel)),
          text: Ext.util.Format.htmlEncode(gt(field.description)),
          width: 200
        });
      }
    }
  },

  /**
   * check validity for all panel items
   * 
   * @return {Boolean}
   */
  isValid: function isValid() {
    var isValid = true;

    if (this.items && this.items.items) {
      var field;

      for (var i = 0; i < this.items.items.length; i++) {
        field = this.items.items[i];

        if (!field.isValid()) {
          field.markInvalid();
          isValid = false;
        }
      }
    }

    return isValid;
  }
});

/***/ }),
/* 1327 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * Generic 'Import' dialog
 *
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.ImportDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @constructor
 * @param       {Object} config The configuration options.
 * 
 * TODO add app grid to show results when dry run is selected
 */

Tine.widgets.dialog.ImportDialog = Ext.extend(Tine.widgets.dialog.WizardPanel, {
  /**
   * @cfg {String} appName (required)
   */
  appName: null,

  /**
   * @cfg {String} modelName (required)
   */
  modelName: null,

  /**
   * @cfg {String} defaultImportContainer
   */
  defaultImportContainer: null,

  /**
   * @property allowedFileExtensions
   * @type Array
   */
  allowedFileExtensions: null,

  /**
   * @property recordClass
   * @type Tine.Tinebase.data.Record
   */
  recordClass: null,

  /**
   * @property definitionsStore
   * @type Ext.data.JsonStore
   */
  definitionsStore: null,

  /**
   * @property selectedDefinition
   * @type Ext.data.Record
   */
  selectedDefinition: null,

  /**
   * @property exceptionStore
   * @type Ext.data.JsonStore
   */
  exceptionStore: null,

  /**
   * @property lastImportResponse
   * @type Objcet resutls of the last import request
   */
  lastImportResponse: null,

  /**
   * canonical name
   * @cfg {String} canonicalName
   */
  canonicalName: 'ImportDialog',
  // private config overrides
  windowNamePrefix: 'ImportWindow_',

  /**
   * init import wizard
   */
  initComponent: function initComponent() {
    Tine.log.debug('Tine.widgets.dialog.ImportDialog::initComponent this');
    Tine.log.debug(this);
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    this.recordClass = Tine.Tinebase.data.RecordMgr.get(this.appName, this.modelName);
    this.allowedFileExtensions = []; // init definitions

    this.definitionsStore = new Ext.data.JsonStore({
      fields: Tine.Tinebase.Model.ImportExportDefinition,
      root: 'results',
      totalProperty: 'totalcount',
      remoteSort: false
    });

    if (Tine[this.appName].registry.get('importDefinitions')) {
      Ext.each(Tine.widgets.importAction.getImports(this.recordClass), function (defData) {
        var options = defData.plugin_options_json,
            extension = options ? options.extension : null;
        defData.label = this.app.i18n._hidden(options && options.label ? options.label : defData.name);

        if (this.allowedFileExtensions.indexOf(extension) == -1) {
          this.allowedFileExtensions = this.allowedFileExtensions.concat(extension);
        }

        this.definitionsStore.addSorted(new Tine.Tinebase.Model.ImportExportDefinition(defData, defData.id));
      }, this);
      this.definitionsStore.sort('label');
    }

    if (!this.selectedDefinition) {
      var defaultConfig = Tine[this.appName].registry.get('defaultImportDefinition'),
          defaultExists = defaultConfig && this.definitionsStore.getById(defaultConfig.id);
      this.selectedDefinition = defaultExists ? this.definitionsStore.getById(defaultConfig.id) : this.definitionsStore.getAt(0);
    } // init exception store


    this.exceptionStore = new Ext.data.JsonStore({
      mode: 'local',
      idProperty: 'index',
      fields: ['index', 'code', 'message', 'exception', 'resolveStrategy', 'resolvedRecord', 'isResolved']
    });
    this.items = this.getItems();
    Tine.widgets.dialog.ImportDialog.superclass.initComponent.call(this);
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    if (this.recordClass) {
      return ['', this.recordClass.getMeta('appName'), this.canonicalName, this.recordClass.getMeta('modelName')].join(Tine.Tinebase.CanonicalPath.separator);
    }
  },
  getItems: function getItems() {
    return [this.getFilePanel(), this.getOptionsPanel(), this.getConflictsPanel(), this.getSummaryPanel()];
  },

  /**
   * close window on cancel
   */
  onCancelButton: function onCancelButton() {
    this.fireEvent('cancel', this, this.layout.activeItem);
    this.window.close();
  },

  /**
   * do import request
   * 
   * @param {Function} callback
   * @param {Object}   importOptions
   */
  doImport: function doImport(callback, importOptions, clientRecordData) {
    Ext.Ajax.request({
      scope: this,
      timeout: 1800000,
      // 30 minutes
      callback: this.onImportResponse.createDelegate(this, [callback], true),
      params: {
        method: this.appName + '.import' + this.recordClass.getMeta('modelName') + 's',
        tempFileId: this.uploadButton.getTempFileId(),
        definitionId: this.definitionCombo.getValue(),
        importOptions: Ext.apply({
          container_id: this.containerCombo ? this.containerCombo.getValue() : null,
          autotags: this.tagsPanel.getFormField().getValue()
        }, importOptions || {}),
        clientRecordData: clientRecordData
      }
    });
  },

  /**
   * called when import request sends response
   * 
   * @param {Object}   request
   * @param {Boolean}  success
   * @param {Object}   response
   * @param {Function} callback
   */
  onImportResponse: function onImportResponse(request, success, response, callback) {
    response = Ext.util.JSON.decode(response.responseText);
    Tine.log.debug('Tine.widgets.dialog.ImportDialog::onImportResponse server response');
    Tine.log.debug(response);
    this.lastImportResponse = response;

    if (success) {
      // load exception store
      this.exceptionStore.loadData(response.exceptions);
      this.exceptionStore.filterBy(this.exceptionStoreFilter, this);

      if (this.exceptionStore.getCount()) {
        this.loadConflict(0);
      } // finally apply callback


      if (Ext.isFunction(callback)) {
        callback.call(this, request, success, response);
      }
    } else {
      this.checkMask.hide();
      Tine.Tinebase.ExceptionHandler.handleRequestException(response.data);
    }
  },
  exceptionStoreFilter: function exceptionStoreFilter(record, id) {
    return record.get('code') == 629 && !record.get('isResolved');
  },

  /********************************************************** FILE PANEL **********************************************************/

  /**
   * returns the file panel of this wizard (step 1)
   * 
   * @TODO restrict allowed extensions on definition selection OR
   *       restirct allowed definitions on file selection
   */
  getFilePanel: function getFilePanel() {
    if (this.filePanel) {
      return this.filePanel;
    }

    var def = this.selectedDefinition,
        description = def ? this.app.i18n._hidden(def.get('description')) : '',
        options = def ? def.get('plugin_options_json') : null,
        example = options && options.example ? options.example : '';
    return {
      title: i18n._('Choose File and Format'),
      layout: 'vbox',
      border: false,
      xtype: 'ux.displaypanel',
      frame: true,
      ref: '../filePanel',
      canonicalName: 'ImportFileAndFormat',
      items: [{
        xtype: 'panel',
        baseCls: 'ux-subformpanel',
        title: i18n._('Choose Import File'),
        height: 100,
        items: [{
          xtype: 'label',
          html: '<p>' + i18n._('Please choose the file that contains the records you want to add to Tine 2.0').replace(/Tine 2\.0/g, Tine.title) + '</p><br />'
        }, {
          xtype: 'tw.uploadbutton',
          ref: '../../uploadButton',
          text: String.format(i18n._('Select file containing your {0}'), this.recordClass.getRecordsName()),
          handler: this.onFileReady,
          allowedTypes: this.allowedFileExtensions,
          scope: this
        }]
      }, {
        xtype: 'panel',
        baseCls: 'ux-subformpanel',
        title: i18n._('What should the file you upload look like?'),
        flex: 1,
        items: [
        /*{
        xtype: 'label',
        cls: 'tb-login-big-label',
        html: i18n._('What should the file you upload look like?') + '<br />'
        },*/
        {
          xtype: 'label',
          html: '<p>' + i18n._('Tine 2.0 does not understand all kind of files you might want to upload. You will have to manually adjust your file so Tine 2.0 can handle it.').replace(/Tine 2\.0/g, Tine.title) + '</p><br />'
        }, {
          xtype: 'label',
          html: '<p>' + i18n._('Following you find a list of all supported import formats and a sample file, how Tine 2.0 expects your file to look like.').replace(/Tine 2\.0/g, Tine.title) + '</p><br />'
        }, {
          xtype: 'label',
          html: '<p>' + i18n._('Please select the import format of the file you want to upload').replace(/Tine 2\.0/g, Tine.title) + '</p>'
        }, {
          xtype: 'combo',
          ref: '../../definitionCombo',
          store: this.definitionsStore,
          displayField: 'label',
          valueField: 'id',
          mode: 'local',
          triggerAction: 'all',
          editable: false,
          allowBlank: false,
          forceSelection: true,
          width: 400,
          value: this.selectedDefinition ? this.selectedDefinition.id : null,
          listeners: {
            scope: this,
            'select': this.onDefinitionSelect
          }
        }, {
          xtype: 'label',
          ref: '../../exampleLink',
          html: example ? '<p><a href="' + example + '">' + i18n._('Download example file') + '</a></p>' : '<p>&nbsp;</p>'
        }, {
          xtype: 'displayfield',
          //                    fieldLabel: i18n._('Import description'),
          ref: '../../definitionDescription',
          height: 70,
          value: description,
          cls: 'x-ux-display-background-border',
          style: 'padding-left: 5px;'
        }]
      }],
      nextIsAllowed: function () {
        return this.definitionCombo && this.definitionCombo.getValue() && this.uploadButton && this.uploadButton.fileRecord;
      }.createDelegate(this)
    };
  },
  onFileReady: function onFileReady() {
    this.manageButtons();
  },

  /**
   * select handler of definition combo
   */
  onDefinitionSelect: function onDefinitionSelect(combo, record, index) {
    var description = record.get('description'),
        options = record.get('plugin_options_json'),
        example = options && options.example ? options.example : '';
    this.selectedDefinition = record;
    this.definitionDescription.setValue(description);
    this.exampleLink.setText(example ? '<p><a href="' + example + '">' + i18n._('Download example file') + '</a></p>' : '<p>&nbsp;</p>', false);
    this.manageButtons();
  },

  /**
   * get options of the plugin from the currently selected definition
   */
  getImportPluginOptions: function getImportPluginOptions() {
    var options = this.selectedDefinition ? this.selectedDefinition.get('plugin_options_json') : null;
    return options || {};
  },

  /********************************************************** OPTIONS PANEL **********************************************************/
  getOptionsPanel: function getOptionsPanel() {
    if (this.optionsPanel) {
      return this.optionsPanel;
    }

    var items = [];

    if (null !== this.recordClass.getContainerName()) {
      items = items.concat([{
        xtype: 'label',
        html: '<p>' + String.format(i18n._('Select {0} to add you {1} to:'), this.recordClass.getContainerName(), this.recordClass.getRecordsName()) + '</p>'
      }, new Tine.widgets.container.SelectionComboBox({
        id: this.app.appName + 'EditDialogContainerSelector',
        width: 300,
        ref: '../containerCombo',
        stateful: false,
        containerName: this.recordClass.getContainerName(),
        containersName: this.recordClass.getContainersName(),
        appName: this.appName,
        recordClass: this.recordClass,
        value: this.defaultImportContainer,
        listeners: {
          scope: this,
          select: function select() {
            this.manageButtons();
          }
        },
        requiredGrant: false,
        // 'add' ?
        style: 'margin-bottom: 15px;'
      })]);
    }

    items.push(new Tine.widgets.tags.TagPanel({
      canonicalName: 'ImportTags',
      app: this.appName,
      ref: '../tagsPanel',
      style: 'border: 1px solid silver; border-top: none;',
      border: true,
      collapsible: false,
      height: 200
    }));
    return {
      title: i18n._('Set Import Options'),
      layout: 'fit',
      border: false,
      xtype: 'form',
      frame: true,
      ref: '../optionsPanel',
      canonicalName: 'ImportOptions',
      items: items,
      listeners: {
        scope: this,
        show: function show() {
          var options = this.getImportPluginOptions();

          if (options.autotags) {
            var tags = options.autotags;
            Ext.each([].concat(tags), function (tag) {
              tag.name = this.app.i18n._hidden(tag.name);
              tag.description = this.app.i18n._hidden(tag.description);
            }, this);
            this.tagsPanel.getFormField().setValue(tags);
          }

          if (this.containerCombo) {
            this.containerCombo.setValue(options.container_id ? options.container_id : this.defaultImportContainer);
          }
        }
      },

      /**
       * check if next button is allowed
       */
      nextIsAllowed: function () {
        if (null !== this.recordClass.getContainerName()) {
          return this.containerCombo && this.containerCombo.getValue();
        }

        return true;
      }.createDelegate(this),

      /**
       * next button handler for this panel
       */
      onNextButton: function () {
        if (!this.checkMask) {
          this.checkMask = new Ext.LoadMask(this.getEl(), {
            msg: i18n._('Checking Import')
          });
        }

        this.checkMask.show();
        this.doImport(function (request, success, response) {
          this.checkMask.hide(); // jump to finish panel if no conflicts where detected

          if (!response.duplicatecount) {
            this.navigate(+2);
          } else {
            this.navigate(+1);
          }
        }, {
          dryrun: true
        });
      }.createDelegate(this)
    };
  },

  /********************************************************** CONFLICT PANEL **********************************************************/
  getConflictsPanel: function getConflictsPanel() {
    if (this.conflictsPanel) {
      return this.conflictsPanel;
    }

    return {
      title: i18n._('Resolve Conflicts'),
      layout: 'vbox',
      border: false,
      xtype: 'form',
      frame: true,
      ref: '../conflictsPanel',
      canonicalName: 'ImportResolveConflicts',
      items: [
      /*{
      xtype: 'label',
      ref: '../conflictsLabel',
      rawText: '<p>' + i18n._('There are {0} {1} that might already exist.') + '</p>',
      html: '<p></p>',
      height: 20
      },*/
      {
        xtype: 'paging',
        ref: '../conflictPagingToolbar',
        pageSize: 1,
        beforePageText: i18n._('Conflict'),
        firstText: i18n._('First Conflict'),
        prevText: i18n._('Previous Conflict'),
        nextText: i18n._('Next Conflict'),
        lastText: i18n._('Last Conflict'),
        store: this.exceptionStore,
        doLoad: this.loadConflict.createDelegate(this),
        onLoad: Ext.emptyFn,
        listeners: {
          afterrender: function afterrender(t) {
            t.refresh.hide();
          }
        },
        items: [this.conflictIndexText = new Ext.Toolbar.TextItem({}), '->', {
          text: i18n._('Resolve this conflict'),
          xtype: 'splitbutton',
          scope: this,
          handler: this.onResolveConflict,
          menu: [{
            text: i18n._('Resolve all conflicts'),
            scope: this,
            handler: this.onResolveAllConflict
          }]
        }]
      }, new Tine.widgets.dialog.DuplicateResolveGridPanel({
        flex: 1,
        ref: '../duplicateResolveGridPanel',
        header: false,
        app: this.app,
        store: new Tine.widgets.dialog.DuplicateResolveStore({
          app: this.app,
          recordClass: this.recordClass
        })
      })],
      listeners: {
        scope: this,
        show: function show() {
          if (!this.exceptionStore.isFiltered()) {
            this.exceptionStore.filterBy(this.exceptionStoreFilter, this);
            this.manageButtons();
          }
        }
      },

      /**
       * check if next button is allowed
       */
      nextIsAllowed: function () {
        var nextIsAllowed = true; // check if all conflicts are resolved

        this.exceptionStore.each(function (exception) {
          if (!exception.get('isResolved')) {
            nextIsAllowed = false;
            return false;
          }
        }, this);
        return nextIsAllowed;
      }.createDelegate(this)
    };
  },

  /**
   * mark current conflict resolved
   */
  onResolveConflict: function onResolveConflict() {
    var index = this.conflictPagingToolbar.cursor,
        record = this.exceptionStore.getAt(index),
        resolveStore = this.duplicateResolveGridPanel.getStore(),
        resolveStrategy = resolveStore.resolveStrategy,
        resolveRecord = resolveStore.getResolvedRecord(); // mark exception record resolved

    record.set('resolveStrategy', resolveStrategy);
    record.set('resolvedRecord', resolveRecord);
    record.set('isResolved', true); // load next conflict

    this.exceptionStore.filterBy(this.exceptionStoreFilter, this);
    this.manageButtons();
    this.loadConflict(this.exceptionStore.getCount() > index ? index : index - 1);

    if (Ext.isFunction(arguments[0])) {
      return arguments[0].call(this);
    }
  },

  /**
   * resolve all conflicts using current strategy
   */
  onResolveAllConflict: function onResolveAllConflict() {
    // @TODO: disable grid to spedup things?
    if (this.exceptionStore.getCount() > 0) {
      this.conflictMask.show();
      this.conflictMask.hidden = false;
      return this.onResolveConflict.defer(20, this, [this.onResolveAllConflict]);
    } else {
      this.conflictMask.hide();
      this.conflictMask.hidden = true;
    }
  },

  /**
   * load conflict with given index
   * 
   * @param {Number} index
   */
  loadConflict: function loadConflict(index) {
    if (!this.conflictMask) {
      this.conflictMask = new Ext.LoadMask(this.getEl(), {
        msg: i18n._('Processing Conflict Data'),
        hidden: true
      });
    } // give DOM the time to show loadMask


    if (this.conflictMask.hidden) {
      this.conflictMask.show();
      this.conflictMask.hidden = false;
      return this.loadConflict.defer(200, this, arguments);
    }

    var thisRecord = this.exceptionStore.getAt(this.conflictPagingToolbar.cursor),
        nextRecord = this.exceptionStore.getAt(index),
        resolveStore = this.duplicateResolveGridPanel.getStore(); // preserv changes

    if (this.conflictPagingToolbar.cursor != index && thisRecord && resolveStore.getCount()) {
      thisRecord.set('resolvedRecord', resolveStore.getResolvedRecord());
      thisRecord.set('resolveStrategy', resolveStore.resolveStrategy);
    }

    if (nextRecord) {
      resolveStore.loadData(nextRecord.get('exception'), nextRecord.get('resolveStrategy') || resolveStore.resolveStrategy, nextRecord.get('resolvedRecord'));
    } else {
      resolveStore.removeAll();
      this.duplicateResolveGridPanel.getView().mainBody.update('<br />  ' + i18n._('No conflict to resolve')); // defer navigation to complete this step before

      this.navigate.defer(200, this, [+1]);
    } // update paging toolbar


    var p = this.conflictPagingToolbar,
        ap = index + 1,
        ps = this.exceptionStore.getCount();
    p.cursor = index;
    p.afterTextItem.setText(String.format(p.afterPageText, ps));
    p.inputItem.setValue(ap);
    p.first.setDisabled(ap == 1);
    p.prev.setDisabled(ap == 1);
    p.next.setDisabled(ap == ps);
    p.last.setDisabled(ap == ps);
    this.conflictIndexText.setText(nextRecord ? String.format(i18n._('(This is record {0} in your import file)'), nextRecord.get('index') + 1) : i18n._('No conflict to resolve'));
    this.conflictMask.hide();
    this.conflictMask.hidden = true;
  },

  /********************************************************** SUMMARY PANEL **********************************************************/
  getSummaryPanel: function getSummaryPanel() {
    if (this.summaryPanel) {
      return this.summaryPanel;
    }

    var exceptionExpander = new Ext.ux.grid.RowExpander({
      tpl: new Ext.XTemplate('{[this.showClientRecord(values)]}', {
        showClientRecord: function showClientRecord(values) {
          if (values && values.exception && values.exception.clientRecord) {
            // there is no generic detailsPanel retirval yet
            //                    if (Ext.isObject(values.exception.clientRecord)) {
            //                        var detailsPanel = new Tine.Addressbook.ContactGridDetailsPanel({});
            //                        
            //                        return detailsPanel.tpl.apply(values.exception.clientRecord);
            //                    }
            return Ext.util.Format.htmlEncode(Ext.encode(values.exception.clientRecord));
          } else {
            return i18n._('No Detail Informations');
          }
        }
      })
    });
    return {
      title: i18n._('Summary'),
      border: false,
      xtype: 'ux.displaypanel',
      frame: true,
      ref: '../summaryPanel',
      autoScroll: true,
      canonicalName: 'ImportSummary',
      items: [{
        height: 100,
        ref: '../summaryPanelInfo',
        border: false,
        layout: 'ux.display',
        layoutConfig: {
          background: 'border'
        }
      }, {
        ref: '../summaryPanelFailures',
        baseCls: 'ux-arrowcollapse',
        cls: 'ux-arrowcollapse-plain',
        collapsible: true,
        hidden: true,
        flex: 1,
        title: '',
        items: [{
          xtype: 'grid',
          store: this.exceptionStore,
          autoHeight: true,
          plugins: exceptionExpander,
          columns: [exceptionExpander, {
            id: 'index',
            header: i18n._('Index'),
            width: 60,
            sortable: false,
            dataIndex: 'index'
          }, {
            id: 'exception',
            header: i18n._('Record'),
            width: 120,
            sortable: false,
            dataIndex: 'exception',
            renderer: function renderer(exception) {
              // TODO find a way to show record more pretty
              return exception.clientRecord ? Ext.util.JSON.encode(exception.clientRecord) : '';
            }
          }, {
            id: 'failure',
            header: i18n._('Failure'),
            width: 60,
            sortable: false,
            dataIndex: 'message'
          }],
          autoExpandColumn: 'failure'
        }]
      }],
      listeners: {
        scope: this,
        show: this.onSummaryPanelShow
      },

      /**
       * finish button handler for this panel
       */
      onFinishButton: function () {
        if (!this.importMask) {
          this.importMask = new Ext.LoadMask(this.getEl(), {
            msg: String.format(i18n._('Importing {0}'), this.recordClass.getRecordsName())
          });
        }

        this.importMask.show(); // collect client data

        var clientRecordData = [];
        var importOptions = {};
        this.exceptionStore.clearFilter(true);
        this.exceptionStore.each(function (r) {
          clientRecordData.push({
            recordData: r.get('resolvedRecord').data,
            resolveStrategy: r.get('resolveStrategy') || 'discard',
            index: r.get('index')
          });
        });
        this.doImport(function (request, success, response) {
          this.importMask.hide();
          this.fireEvent('finish', this, this.layout.activeItem);

          if (response.failcount > 0 && Ext.isArray(response.exceptions) && response.exceptions.length > 0) {
            // show errors and fence finish/back btn
            this.backButton.setDisabled(true);
            this.finishButton.setHandler(function () {
              this.window.close();
            }, this);
            this.summaryPanelInfo.hide();
            this.exceptionStore.clearFilter(true);
            this.summaryPanelFailures.show();
            this.summaryPanelFailures.setTitle(String.format(i18n._('{0} records had failures and where discarded.'), response.failcount));
          } else {
            this.window.close();
          }
        }, importOptions, clientRecordData);
      }.createDelegate(this)
    };
  },

  /**
   * summary panel show handler
   */
  onSummaryPanelShow: function onSummaryPanelShow() {
    if (!this.summaryPanelInfo.rendered) {
      return this.onSummaryPanelShow.defer(100, this);
    } // calc metrics


    var rsp = this.lastImportResponse,
        totalcount = rsp.totalcount,
        failcount = 0,
        mergecount = 0,
        discardcount = 0;
    this.exceptionStore.clearFilter();
    this.exceptionStore.each(function (r) {
      var strategy = r.get('resolveStrategy');

      if (!strategy || !Ext.isString(strategy)) {
        failcount++;
      } else if (strategy == 'keep') {
        totalcount++;
      } else if (strategy.match(/^merge.*/)) {
        mergecount++;
      } else if (strategy == 'discard') {
        discardcount++;
      }
    }, this);
    var tags = this.tagsPanel.getFormField().getValue(),
        container = this.containerCombo ? this.containerCombo.selectedContainer : null,
        info = [String.format(i18n._('In total we found {0} records in your import file.'), rsp.totalcount + rsp.duplicatecount + rsp.failcount)];

    if (totalcount && null !== this.recordClass.getContainerName()) {
      info.push(String.format(i18n._('{0} of them will be added as new records into: "{1}".'), totalcount, Tine.Tinebase.common.containerRenderer(container).replace('<div', '<span').replace('</div>', '</span>')));
    }

    if (mergecount + discardcount) {
      info.push(String.format(i18n._('{0} of them where identified as duplicates.'), mergecount + discardcount));

      if (mergecount) {
        info.push(String.format(i18n._('From the identified duplicates {0} will be merged into the existing records.'), mergecount));
      }

      if (discardcount) {
        info.push(String.format(i18n._('From the identified duplicates {0} will be discarded.'), discardcount));
      }
    }

    if (Ext.isArray(tags) && tags.length) {
      var tagNames = [],
          tagRecord = null;
      Ext.each(tags, function (tag) {
        if (Ext.isString(tag)) {
          tagRecord = this.tagsPanel.recordTagsStore.getById(tag);
          tag = tagRecord ? tagRecord.data : null;
        }

        if (tag) {
          tagNames.push(tag.name);
        }
      }, this);
      info.push(String.format(i18n._('All records will be tagged with: "{0}" so you can find them easily.'), tagNames.join(', ')));
    }

    this.summaryPanelInfo.update('<div style="padding: 5px;">' + info.join('<br />') + '</div>'); // failures

    if (failcount) {
      this.exceptionStore.filterBy(function (record, id) {
        return !(record.get('code') == 629 && !record.get('isResolved'));
      });
      this.summaryPanelFailures.show();
      this.summaryPanelFailures.setTitle(String.format(i18n._('{0} records have failures and will be discarded.'), failcount));
    }
  }
});
/**
 * credentials dialog popup / window
 */

Tine.widgets.dialog.ImportDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 800,
    height: 600,
    name: Tine.widgets.dialog.ImportDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.ImportDialog',
    contentPanelConstructorConfig: config //,
    //        modal: true

  });
  return window;
};

/***/ }),
/* 1328 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * Simple Import Dialog
 *
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.ImportDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @constructor
 * @param       {Object} config The configuration options.
 * 
 * TODO add app grid to show results when dry run is selected
 */

Tine.widgets.dialog.SimpleImportDialog = Ext.extend(Tine.widgets.dialog.ImportDialog, {
  /**
   * init import wizard
   */
  initComponent: function initComponent() {
    Tine.log.debug('Tine.widgets.dialog.SimpleImportDialog::initComponent this');
    Tine.log.debug(this);
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    this.recordClass = Tine.Tinebase.data.RecordMgr.get(this.appName, this.modelName);
    this.allowedFileExtensions = []; // init definitions

    this.definitionsStore = new Ext.data.JsonStore({
      fields: Tine.Tinebase.Model.ImportExportDefinition,
      root: 'results',
      totalProperty: 'totalcount',
      remoteSort: false
    });

    if (Tine[this.appName].registry.get('importDefinitions')) {
      Ext.each(Tine.widgets.importAction.getImports(this.recordClass), function (defData) {
        var options = defData.plugin_options_json,
            extension = options ? options.extension : null;
        defData.label = this.app.i18n._hidden(options && options.label ? options.label : defData.name);

        if (this.allowedFileExtensions.indexOf(extension) == -1) {
          this.allowedFileExtensions = this.allowedFileExtensions.concat(extension);
        }

        this.definitionsStore.addSorted(new Tine.Tinebase.Model.ImportExportDefinition(defData, defData.id));
      }, this);
      this.definitionsStore.sort('label');
    }

    if (!this.selectedDefinition) {
      var defaultConfig = Tine[this.appName].registry.get('defaultImportDefinition'),
          defaultExists = defaultConfig && this.definitionsStore.getById(defaultConfig.id);
      this.selectedDefinition = defaultExists ? this.definitionsStore.getById(defaultConfig.id) : this.definitionsStore.getAt(0);
    }

    this.items = [this.getFilePanel()];
    Tine.widgets.dialog.ImportDialog.superclass.initComponent.call(this);
  },

  /**
   * do import request
   * 
   * @param {Function} callback
   * @param {Object}   importOptions
   */
  doImport: function doImport(callback, importOptions, clientRecordData) {
    Ext.Ajax.request({
      scope: this,
      timeout: 1800000,
      // 30 minutes
      callback: this.onImportResponse.createDelegate(this, [callback], true),
      params: {
        method: this.appName + '.import' + this.recordClass.getMeta('modelName') + 's',
        tempFileId: this.uploadButton.getTempFileId(),
        definitionId: this.definitionCombo.getValue(),
        importOptions: Ext.apply({
          container_id: this.containerCombo.getValue()
        }, importOptions || {}),
        clientRecordData: clientRecordData
      }
    });
  },

  /**
   * called when import request sends response
   * 
   * @param {Object}   request
   * @param {Boolean}  success
   * @param {Object}   response
   * @param {Function} callback
   */
  onImportResponse: function onImportResponse(request, success, response, callback) {
    response = Ext.util.JSON.decode(response.responseText);
    Tine.log.debug('Tine.widgets.dialog.SimpleImportDialog::onImportResponse server response');
    Tine.log.debug(response);
    this.lastImportResponse = response; // finlay apply callback

    if (Ext.isFunction(callback)) {
      callback.call(this, request, success, response);
    }
  },
  getTypeSelection: function getTypeSelection() {},

  /**
   * returns the file panel of this wizard (step 1)
   */
  getFilePanel: function getFilePanel() {
    if (this.filePanel) {
      return this.filePanel;
    }

    var def = this.selectedDefinition,
        description = def ? this.app.i18n._hidden(def.get('description')) : '',
        options = def ? def.get('plugin_options_json') : null,
        example = options && options.example ? options.example : '';
    return {
      title: i18n._('Choose File and Format'),
      layout: 'vbox',
      border: false,
      xtype: 'ux.displaypanel',
      frame: true,
      ref: '../filePanel',
      items: [{
        xtype: 'panel',
        baseCls: 'ux-subformpanel',
        title: i18n._('Choose Import File'),
        height: 100,
        items: [{
          xtype: 'label',
          html: '<p>' + i18n._('Please choose the file that contains the records you want to add to Tine 2.0').replace(/Tine 2\.0/g, Tine.title) + '</p><br />'
        }, {
          xtype: 'tw.uploadbutton',
          ref: '../../uploadButton',
          text: String.format(i18n._('Select file containing your {0}'), this.recordClass.getRecordsName()),
          handler: this.onFileReady,
          allowedTypes: this.allowedFileExtensions,
          scope: this
        }]
      }, {
        xtype: 'panel',
        baseCls: 'ux-subformpanel',
        title: i18n._('Set Import Options'),
        height: 100,
        items: [{
          xtype: 'label',
          html: '<p>' + String.format(i18n._('Select {0} to add you {1} to:'), this.recordClass.getContainerName(), this.recordClass.getRecordsName()) + '</p>'
        }, new Tine.widgets.container.SelectionComboBox({
          id: this.app.appName + 'EditDialogContainerSelector',
          width: 300,
          ref: '../../containerCombo',
          stateful: false,
          recordClass: this.recordClass,
          containerName: this.recordClass.getContainerName(),
          containersName: this.recordClass.getContainersName(),
          appName: this.appName,
          value: this.defaultImportContainer,
          requiredGrant: false
        })]
      }, {
        xtype: 'panel',
        baseCls: 'ux-subformpanel',
        title: i18n._('What should the file you upload look like?'),
        flex: 1,
        items: [{
          xtype: 'label',
          html: '<p>' + i18n._('Tine 2.0 does not understand all kind of files you might want to upload. You will have to manually adjust your file so Tine 2.0 can handle it.').replace(/Tine 2\.0/g, Tine.title) + '</p><br />'
        }, {
          xtype: 'label',
          html: '<p>' + i18n._('Following you find a list of all supported import formats and a sample file, how Tine 2.0 expects your file to look like.').replace(/Tine 2\.0/g, Tine.title) + '</p><br />'
        }, {
          xtype: 'label',
          html: '<p>' + i18n._('Please select the import format of the file you want to upload').replace(/Tine 2\.0/g, Tine.title) + '</p>'
        }, {
          xtype: 'combo',
          ref: '../../definitionCombo',
          store: this.definitionsStore,
          displayField: 'label',
          valueField: 'id',
          mode: 'local',
          triggerAction: 'all',
          editable: false,
          allowBlank: false,
          forceSelection: true,
          width: 400,
          value: this.selectedDefinition ? this.selectedDefinition.id : null,
          listeners: {
            scope: this,
            'select': this.onDefinitionSelect
          }
        }, {
          xtype: 'label',
          ref: '../../exampleLink',
          html: example ? '<p><a href="' + example + '">' + i18n._('Download example file') + '</a></p>' : '<p>&nbsp;</p>'
        }, {
          xtype: 'displayfield',
          ref: '../../definitionDescription',
          height: 70,
          value: description,
          cls: 'x-ux-display-background-border',
          style: 'padding-left: 5px;'
        }]
      }],

      /**
      * finish button handler for this panel
      */
      onFinishButton: function () {
        if (!this.importMask) {
          this.importMask = new Ext.LoadMask(this.getEl(), {
            msg: String.format(i18n._('Importing {0}'), this.recordClass.getRecordsName())
          });
        }

        this.importMask.show(); // collect client data

        var clientRecordData = [];
        var importOptions = {};
        this.doImport(function (request, success, response) {
          this.importMask.hide();
          this.fireEvent('finish', this, this.layout.activeItem);

          if (Ext.isArray(response.exceptions) && response.exceptions.length > 0) {
            this.backButton.setDisabled(true);
            this.finishButton.setHandler(function () {
              this.window.close();
            }, this);
          } else {
            this.window.close();
          }
        }, importOptions, clientRecordData);
      }.createDelegate(this),
      finishIsAllowed: function () {
        return this.definitionCombo && this.definitionCombo.getValue() && this.uploadButton && this.uploadButton.fileRecord && this.containerCombo && this.containerCombo.getValue();
      }.createDelegate(this)
    };
  }
});
/**
 * Create new import window
 */

Tine.widgets.dialog.SimpleImportDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 800,
    height: 600,
    name: Tine.widgets.dialog.SimpleImportDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.SimpleImportDialog',
    contentPanelConstructorConfig: config
  });
  return window;
};

/***/ }),
/* 1329 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _Model_ImportExportDefinition__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(631);
/* harmony import */ var _Model_ImportExportDefinition__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_Model_ImportExportDefinition__WEBPACK_IMPORTED_MODULE_0__);
/**
 * Tine 2.0
 * 
 * @package     Tine
 * @subpackage  Widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 */
Ext.ns('Tine.widgets', 'Tine.widgets.dialog');

/**
 * Generic 'Export' dialog
 *
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.ExportDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @constructor
 * @param       {Object} config The configuration options
 * 
 * TODO         add template for def combo (shows description, format?, ...)
 *              -> add panel with it
 * 
 */

Tine.widgets.dialog.ExportDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
  /**
   * @cfg {String} appName
   */
  appName: null,

  /**
   * @cfg {Number} height
   */
  height: 600,

  /**
   * @cfg {Number} width
   */
  width: 800,
  // private
  windowNamePrefix: 'ExportWindow_',
  checkUnsavedChanges: false,
  loadMask: false,
  tbarItems: [],
  evalGrants: false,
  sendRequest: true,
  mode: 'local',
  //private
  initComponent: function initComponent() {
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    this.recordClass = Tine.Tinebase.Model.ExportJob;
    this.saveAndCloseButtonText = i18n._('Export');
    this.definitionsStore = new Ext.data.JsonStore({
      fields: Tine.Tinebase.Model.ImportExportDefinition,
      root: 'results',
      totalProperty: 'totalcount',
      idProperty: 'id',
      remoteSort: false
    });
    var recordClass = Tine.Tinebase.data.RecordMgr.get(this.record.get('model')),
        scope = this.record.get('scope'),
        exportDefinitions = Tine.widgets.exportAction.getExports(recordClass, null, scope);
    Ext.each(exportDefinitions, function (defData) {
      defData.label = this.app.i18n._hidden(defData.label ? defData.label : defData.name);
      this.definitionsStore.addSorted(new Tine.Tinebase.Model.ImportExportDefinition(defData, defData.id));
    }, this);
    this.definitionsStore.sort('label');
    this.record.set('returnFileLocation', true);
    Tine.widgets.dialog.ExportDialog.superclass.initComponent.call(this);
  },

  /**
   * returns dialog
   */
  getFormItems: function getFormItems() {
    return {
      bodyStyle: 'padding:5px;',
      buttonAlign: 'right',
      labelAlign: 'top',
      border: false,
      layout: 'form',
      ref: 'formPanel',
      defaults: {
        anchor: '100%'
      },
      items: [{
        xtype: 'combo',
        fieldLabel: i18n._('Export'),
        name: 'definitionId',
        store: this.definitionsStore,
        displayField: 'label',
        mode: 'local',
        triggerAction: 'all',
        editable: false,
        allowBlank: false,
        forceSelection: true,
        emptyText: i18n._('Select Export Definition ...'),
        valueField: 'id',
        checkState: this.checkDefinitionState.createDelegate(this)
      }, {
        xtype: 'displayfield',
        fieldLabel: i18n._('Description'),
        ref: '../definitionDescription',
        height: 70,
        cls: 'x-ux-display-background-border',
        style: 'padding-left: 5px;'
      }]
    };
  },
  checkDefinitionState: function checkDefinitionState() {
    const definitionId = this.record.get('definitionId');
    const definition = this.definitionsStore.getById(definitionId);

    if (definitionId && definitionId !== this.definitionId) {
      this.definitionDescription.setValue(this.app.i18n._hidden(definition.get('description')));
      this.formPanel.items.each(item => {
        if (item.definitionId && item.definitionId === this.definitionId) {
          item.ownerCt.remove(item);
        }
      });

      const optionsDefinitions = _.get(definition, 'data.plugin_options_definition', {});

      const options = _.get(definition, 'data.plugin_options_json', {});

      _.each(optionsDefinitions, (fieldDefinition, fieldName) => {
        _.assign(fieldDefinition, {
          appName: this.appName,
          fieldName: fieldName
        });

        const config = {
          value: _.get(options, 'fieldName'),
          definitionId: definitionId
        };
        const field = Ext.create(Tine.widgets.form.FieldManager.getByFieldDefinition(fieldDefinition, Tine.widgets.form.FieldManager.CATEGORY_EDITDIALOG, {
          value: _.get(options, 'fieldName'),
          definitionId: definitionId
        }));
        this.formPanel.add(field);
        this.relayEvents(field, ['change', 'select']);
      });

      this.doLayout();
      this.definitionId = definitionId;
    }
  },
  onRecordUpdate: function onRecordUpdate() {
    if (this.definitionId) {
      this.formPanel.items.each(item => {
        if (item.definitionId && item.definitionId === this.definitionId) {
          // this.record is a exportJob not an definition! :-(
          _.set(this.record, 'data.options.' + item.name, item.getValue());
        }
      });
    }

    return Tine.widgets.dialog.ExportDialog.superclass.onRecordUpdate.call(this);
  },

  /**
   * apply changes handler
   */
  onApplyChanges: function onApplyChanges(closeWindow) {
    var form = this.getForm();

    if (form.isValid()) {
      this.onRecordUpdate();
      const exportMask = new Ext.LoadMask(this.getEl(), {
        msg: i18n._('Exporting...')
      });
      exportMask.show();
      Tine.widgets.exportAction.downloadExport(this.record).then(raw => {
        const response = JSON.parse(raw.responseText);

        if (_.get(response, 'file_location.type') === 'download') {
          new Ext.ux.file.Download({
            params: {
              method: 'Tinebase.downloadTempfile',
              requestType: 'HTTP',
              tmpfileId: _.get(response, 'file_location.tempfile_id')
            }
          }).start();
        }

        Ext.Msg.show({
          title: i18n._('Success'),
          msg: i18n._('Export created successfully.') + (_.get(response, 'file_location.type') === 'download' ? '<br /><b>' + i18n._('Please check your computers downloads folder!') + '</b>' : ''),
          icon: Ext.MessageBox.INFO,
          buttons: Ext.Msg.OK,
          scope: this.window,
          fn: this.window.close
        });
      }).catch(error => {
        Ext.Msg.show({
          title: i18n._('Failure'),
          msg: i18n._('Export could not be created. Please try again later'),
          icon: Ext.MessageBox.ERROR,
          buttons: Ext.Msg.OK,
          scope: this.window,
          fn: this.window.close
        });
      });
    } else {
      Ext.Msg.show({
        title: i18n._('Errors'),
        msg: this.getValidationErrorMessage(),
        icon: Ext.MessageBox.ERROR,
        buttons: Ext.Msg.OK
      });
    }
  }
});

Tine.widgets.dialog.ExportDialog.openWindow = function (config) {
  return Tine.WindowFactory.getWindow({
    width: Tine.widgets.dialog.ExportDialog.prototype.width,
    height: Tine.widgets.dialog.ExportDialog.prototype.height,
    name: Tine.widgets.dialog.ExportDialog.prototype.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.ExportDialog',
    contentPanelConstructorConfig: config
  });
};

/***/ }),
/* 1330 */
/***/ (function(module, exports) {

Ext.ns('Tine.widgets.dialog');

Tine.widgets.dialog.MultiOptionsDialog = function (config) {
  Tine.widgets.dialog.MultiOptionsDialog.superclass.constructor.call(this, config);
  this.options = config.options || {};
  this.scope = config.scope || window;
};
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.MultiOptionsDialog
 * @extends     Ext.FormPanel
 */


Ext.extend(Tine.widgets.dialog.MultiOptionsDialog, Ext.FormPanel, {
  /**
   * @cfg {Array} options
   * @see {Ext.fom.CheckBoxGroup}
   */
  options: null,

  /**
   * @cfg {Object} scope
   */
  scope: null,

  /**
   * @cfg {String} questionText defaults to i18n._('What would you like to do?')
   */
  questionText: null,

  /**
   * @cfg {String} invalidText defaults to i18n._('You need to select an option!')
   */
  invalidText: null,

  /**
   * @cfg {Function} handler
   */
  handler: Ext.emptyFn,

  /**
   * @cfg {Boolean} allowCancel
   */
  allowCancel: false,
  windowNamePrefix: 'MultiOptionsDialog',
  bodyStyle: 'padding:5px',
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,
  initComponent: function initComponent() {
    // init buttons and tbar
    this.initButtons();
    this.itemsName = this.id + '-radioItems'; // get items for this dialog

    this.items = [{
      layout: 'hbox',
      border: false,
      layoutConfig: {
        align: 'stretch'
      },
      items: [{
        border: false,
        html: '<div class="x-window-dlg"><div class="ext-mb-icon ext-mb-question"></div></div>',
        flex: 0,
        width: 45
      }, {
        border: false,
        layout: 'fit',
        flex: 1,
        autoScroll: true,
        items: [{
          xtype: 'label',
          border: false,
          cls: 'ext-mb-text',
          html: this.questionText || i18n._('What would you like to do?')
        }, {
          xtype: 'radiogroup',
          hideLabel: true,
          itemCls: 'x-check-group-alt',
          columns: 1,
          name: 'optionGroup',
          items: this.getItems()
        }]
      }]
    }];
    this.afterIsRendered().then(() => {
      this.mon(this.el, 'dblclick', e => {
        window.getSelection().removeAllRanges();

        _.defer(_.bind(this.onOk, this));
      });
    });
    this.supr().initComponent.call(this);
  },

  /**
   * init buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->', {
      xtype: 'button',
      text: i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      hidden: !this.allowCancel,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    }, {
      xtype: 'button',
      text: i18n._('Ok'),
      minWidth: 70,
      scope: this,
      handler: this.onOk,
      iconCls: 'action_saveAndClose'
    }];
  },
  getItems: function getItems() {
    var items = [];
    Ext.each(this.options, function (option) {
      items.push({
        checked: !!option.checked,
        disabled: !!option.disabled,
        fieldLabel: '',
        labelSeparator: '',
        boxLabel: option.text,
        name: this.itemsName,
        inputValue: option.name
      });
    }, this);
    return items;
  },
  onOk: function onOk() {
    var field = this.getForm().findField('optionGroup');
    var selecedRadio = field.getValue();
    var option = selecedRadio ? selecedRadio.getGroupValue() : null;

    if (!option) {
      field.markInvalid(this.invalidText || i18n._('You need to select an option!'));
      return;
    }

    this.handler.call(this.scope, option);
    this.window.close();
  },
  onCancel: function onCancel() {
    this.handler.call(this.scope, 'cancel');
    this.window.close();
  }
});

Tine.widgets.dialog.MultiOptionsDialog.getOption = function (config) {
  return new Promise((resolve, reject) => {
    const dlg = Tine.widgets.dialog.MultiOptionsDialog.openWindow(_.assign(config, {
      handler: option => {
        if (option === 'cancel') {
          reject(new Error('USERABORT'));
        }

        resolve(option);
      }
    }));
  });
};
/**
 * grants dialog popup / window
 */


Tine.widgets.dialog.MultiOptionsDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: config.width || 400,
    height: config.height || 150,
    closable: false,
    name: Tine.widgets.dialog.MultiOptionsDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.MultiOptionsDialog',
    contentPanelConstructorConfig: config,
    modal: true
  });
  return window;
};

/***/ }),
/* 1331 */
/***/ (function(module, exports) {

Ext.ns('Tine.widgets.dialog');

Tine.widgets.dialog.FileListDialog = function (config) {
  Tine.widgets.dialog.FileListDialog.superclass.constructor.call(this, config);
  this.options = config.options || {};
  this.scope = config.scope || window;
};
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.FileListDialog
 * @extends     Ext.FormPanel
 */


Ext.extend(Tine.widgets.dialog.FileListDialog, Ext.FormPanel, {
  /**
   * @cfg {Array} options
   * @see {Ext.fom.CheckBoxGroup}
   */
  options: null,

  /**
   * @cfg {Object} scope
   */
  scope: null,

  /**
   * @cfg {String} questionText defaults to i18n._('What would you like to do?')
   */
  questionText: null,

  /**
   * @cfg {String} invalidText defaults to i18n._('You need to select an option!')
   */
  invalidText: null,

  /**
   * @cfg {Function} handler
   */
  handler: Ext.emptyFn,

  /**
   * @cfg {Boolean} allowCancel
   */
  allowCancel: false,
  windowNamePrefix: 'FileListDialog',
  bodyStyle: 'padding:5px',
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,
  initComponent: function initComponent() {
    // init buttons and tbar
    this.initButtons();
    this.itemsName = this.id + '-fileList'; // get items for this dialog

    this.items = [{
      layout: 'hbox',
      border: false,
      layoutConfig: {
        align: 'stretch'
      },
      items: [{
        border: false,
        layout: 'fit',
        flex: 1,
        autoScroll: true,
        items: [{
          xtype: 'label',
          border: false,
          cls: 'ext-mb-text',
          html: this.text
        }]
      }]
    }];
    this.supr().initComponent.call(this);
  },

  /**
   * init buttons
   * use preference settings for order of yes and no buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->'];
    var noBtn = {
      xtype: 'button',
      text: i18n._('No'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    };
    var yesBtn = {
      xtype: 'button',
      text: i18n._('Yes'),
      minWidth: 70,
      scope: this,
      handler: this.onOk,
      iconCls: 'action_applyChanges'
    };
    this.fbar.push(noBtn, yesBtn);
  },
  onOk: function onOk() {
    this.handler.call(this.scope, 'yes');
    this.window.close();
  },
  onCancel: function onCancel() {
    this.handler.call(this.scope, 'no');
    this.window.close();
  }
});
/**
 * grants dialog popup / window
 */

Tine.widgets.dialog.FileListDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: config.width || 400,
    height: config.height || 150,
    closable: false,
    name: Tine.widgets.dialog.FileListDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.FileListDialog',
    contentPanelConstructorConfig: config,
    modal: true
  });
  return window;
};

/***/ }),
/* 1332 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.DuplicateMergeDialog
 * @extends     Ext.FormPanel
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @param {Object} config The configuration options.
 */

Tine.widgets.dialog.DuplicateMergeDialog = Ext.extend(Ext.FormPanel, {
  appName: null,
  app: null,
  modelName: null,
  recordClass: null,
  recordProxy: null,
  loadMask: null,
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  labelAlign: 'top',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,

  /**
   * init component
   */
  initComponent: function initComponent() {
    if (!this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    }

    this.recordClass = Tine.Tinebase.data.RecordMgr.get(this.appName, this.modelName);
    this.selections = Ext.decode(this.selections);
    this.records = [];
    this.recordProxy = Tine[this.appName][this.recordClass.getMeta('recordName').toLowerCase() + 'Backend'];

    if (!this.recordProxy) {
      return;
    }

    Ext.each(this.selections, function (rec) {
      this.records.push(this.recordProxy.recordReader({
        responseText: Ext.encode(rec)
      }));
    }, this);
    Tine.log.debug('initComponent: appName: ', this.appName);
    Tine.log.debug('initComponent: app: ', this.app); // init actions

    this.initActions(); // get items for this dialog

    this.items = this.getFormItems();
    Tine.widgets.dialog.DuplicateMergeDialog.superclass.initComponent.call(this);
  },

  /**
   * initializes the actions for the buttons
   */
  initActions: function initActions() {
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    });
    this.action_update = new Ext.Action({
      text: i18n._('OK'),
      minWidth: 70,
      scope: this,
      handler: this.onUpdate,
      iconCls: 'action_saveAndClose'
    });
    this.fbar = ['->', this.action_cancel, this.action_update];
  },

  /**
   * is called to resolve the records
   */
  onUpdate: function onUpdate() {
    var store = this.gridPanel.getStore(),
        updateRecord = store.getResolvedRecord(),
        removeRecords = [],
        allRecords = store.duplicates.concat([store.clientRecord]),
        strategy = this.gridPanel.actionCombo.getValue();
    Tine.log.debug('Tine.widgets.dialog.DuplicateMergeDialog::onUpdate() - strategy:');
    Tine.log.debug(this.gridPanel.actionCombo.getValue());
    Tine.log.debug('Tine.widgets.dialog.DuplicateMergeDialog::onUpdate() - allRecords:');
    Tine.log.debug(allRecords);

    if (strategy === 'mergeTheirs') {
      // we need to use the first id and seq in update record
      updateRecord.id = allRecords[0].id;
      updateRecord.set('seq', allRecords[0].get('seq'));
    } else {
      // we need to use the second id + seq (from clientRecord) in update record
      updateRecord.id = allRecords[1].id;
      updateRecord.set('seq', allRecords[1].get('seq'));
    }

    updateRecord.data.id = updateRecord.id;
    Tine.log.debug('Tine.widgets.dialog.DuplicateMergeDialog::onUpdate() - updateRecord:');
    Tine.log.debug(updateRecord);
    Ext.each(allRecords, function (rec) {
      if (rec.id != updateRecord.id) {
        removeRecords.push(rec);
      }
    });
    Tine.log.debug('Tine.widgets.dialog.DuplicateMergeDialog::onUpdate() - removeRecords:');
    Tine.log.debug(removeRecords);
    this.loadMask = new Ext.LoadMask(this.getEl(), {
      msg: i18n._('Merging Records...')
    });
    this.loadMask.show();
    this.recordProxy.saveRecord(updateRecord, {
      scope: this,
      success: function success(newRecord) {
        this.removeDuplicates(removeRecords);
      },
      failure: function failure(_failure) {
        this.onFailure('update', _failure);
      }
    });
  },

  /**
   * remove duplicate records, when update of the new record succeeded
   * @param {Array} removeRecords
   */
  removeDuplicates: function removeDuplicates(removeRecords) {
    this.recordProxy.deleteRecords(removeRecords, {
      scope: this,
      success: function success() {
        this.onSuccess();
      },
      failure: function failure(_failure2) {
        this.onFailure('remove', _failure2);
      }
    });
  },

  /**
   * is called when a failure on saving the merge result or deleting the duplicate happens
   * @param {} step
   * @param {} failure
   */
  onFailure: function onFailure(step, failure) {
    if (step == 'update') {
      Tine.Tinebase.ExceptionHandler.handleRequestException(failure, function () {
        if (this.loadMask) this.loadMask.hide();
      }, this);
    } else {
      Ext.MessageBox.alert(i18n._('Merge Failed'), String.format(i18n._('The merge succeeded, but the duplicate {0} could not be deleted.'), this.recordClass.getRecordName()), function () {
        Tine.Tinebase.ExceptionHandler.handleRequestException(failure);
        if (this.loadMask) this.loadMask.hide();
      }, this);
    }
  },

  /**
   * returns the form items of this panel
   * @return {}
   */
  getFormItems: function getFormItems() {
    return {
      layout: 'border',
      items: [{
        region: 'center',
        layout: 'fit',
        items: [new Tine.widgets.dialog.DuplicateResolveGridPanel({
          ref: '../../gridPanel',
          app: this.app,
          recordClass: this.recordClass,
          store: new Tine.widgets.dialog.DuplicateResolveStore({
            recordClass: this.recordClass,
            defaultResolveStrategy: 'mergeMine',
            app: this.app,
            data: {
              clientRecord: this.records.shift(),
              duplicates: this.records
            },
            // TODO we might add some grants handling here to show the user if she can't edit, update or delete the records
            // strategy can't be set to 'keep' here
            checkEditGrant: Ext.emptyFn
          }),
          listeners: {
            afterrender: function afterrender() {
              var recordsName = this.recordClass.getRecordsName(),
                  recordName = this.recordClass.getRecordName(); // change actionComboListEls

              this.actionCombo.store = new Ext.data.ArrayStore({
                id: 0,
                fields: ['value', 'text'],
                data: [['mergeMine', String.format(i18n._('Merge {0}, prefer First'), recordsName)], ['mergeTheirs', String.format(i18n._('Merge {0}, prefer Second'), recordsName)]]
              });
              this.store.resolveStrategy = 'mergeMine';
              this.actionCombo.setWidth(400);
              this.onStoreLoad(); // change title

              this.setTitle(String.format(i18n._('Merge {0}'), recordsName)); // change column headers

              this.getColumnModel().setColumnHeader(this.getColumnModel().getIndexById('clientValue'), String.format(i18n._('First {0}'), recordName));
              this.getColumnModel().setColumnHeader(this.getColumnModel().getIndexById('value0'), String.format(i18n._('Second {0}'), recordName));
              this.getColumnModel().setColumnHeader(this.getColumnModel().getIndexById('finalValue'), String.format(i18n._('Final {0}'), recordName));
            }
          }
        })]
      }]
    };
  },
  onSuccess: function onSuccess() {
    this.window.fireEvent('contentschange');
    this.onCancel();
  },
  onCancel: function onCancel() {
    this.window.purgeListeners();
    this.window.close();
  }
});

Tine.widgets.dialog.DuplicateMergeDialog.getWindow = function (config) {
  return Tine.WindowFactory.getWindow({
    width: 800,
    height: 600,
    name: Tine.widgets.dialog.ImportDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.dialog.DuplicateMergeDialog',
    contentPanelConstructorConfig: config
  });
};

/***/ }),
/* 1333 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2020 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.dialog');
/**
 * 
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.DuplicateResolveGridPanel
 * @extends     Ext.grid.EditorGridPanel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.dialog.DuplicateResolveGridPanel = Ext.extend(Ext.grid.EditorGridPanel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   * instance of the app object (required)
   */
  app: null,
  // private config overrides
  cls: 'tw-editdialog',
  border: false,
  layout: 'fit',
  enableColumnMove: false,
  stripeRows: true,
  trackMouseOver: false,
  clicksToEdit: 2,
  enableHdMenu: false,
  viewConfig: {
    forceFit: true
  },
  initComponent: function initComponent() {
    this.title = i18n._('The record you try to add might already exist.');
    this.view = new Ext.grid.GroupingView({
      forceFit: true,
      hideGroupedColumn: true,
      groupTextTpl: '{group}'
    });
    this.initColumnModel();
    this.initToolbar();
    this.store.on('load', this.onStoreLoad, this);
    this.store.on('strategychange', this.onStoreLoad, this);
    this.on('cellclick', this.onCellClick, this);
    this.on('afterrender', this.onAfterRender, this);
    this.on('afteredit', this.onAfterEdit, this);
    Tine.widgets.dialog.DuplicateResolveGridPanel.superclass.initComponent.call(this);
  },
  onAfterRender: function onAfterRender() {
    // apply initial strategy
    this.onStoreLoad();
  },

  /**
   * is called on doubleclick on a cell and sets the editor if the cell is the finalValue
   * 
   * @param {Ext.grid.EditorGridPanel} grid
   * @param {number} rowIndex
   * @param {number} colIndex
   * @param {Ext.EventObject} e
   */
  onCellDblClick: function onCellDblClick(grid, rowIndex, colIndex, e) {
    var strategy = this.actionCombo.getValue(); // editing is just possible if strategy "keep" is chosen, or the finalValue when choosing strategy "mergeTheirs" or "mergeMine"

    if (!(colIndex == 4 && (strategy == 'mergeMine' || strategy == 'mergeTheirs') || strategy == 'keep' && colIndex == 2)) {
      return;
    }

    var cm = this.getColumnModel();
    var column = cm.getColumnAt(colIndex);
    var record = this.store.getAt(rowIndex);
    var fieldDef = record.get('fieldDef');

    if (!Ext.isFunction(fieldDef.type)) {
      switch (fieldDef.type) {
        case 'string':
          column.setEditor(new Ext.form.TextField({}));
          break;

        case 'date':
          column.setEditor(new Ext.ux.form.ClearableDateField({}));
          break;

        case 'int':
          column.setEditor(new Ext.form.NumberField({}));
          break;

        default:
          // TODO: allow more types, create FieldRegistry
          return;
      }

      this.startEditing(rowIndex, colIndex);
    } else {
      return;
    }
  },

  /**
   * is called after edit a field
   * 
   * @param {Ext.EventObject} e
   */
  onAfterEdit: function onAfterEdit(e) {
    var record = this.store.getAt(e.row);

    if (e.field == 'clientValue') {
      record.set('finalValue', e.value);
    }

    this.stopEditing();
  },

  /**
   * adopt final value to the one selected
   * 
   * @param {Ext.grid.EditorGridPanel} grid
   * @param {number} rowIndex
   * @param {number} colIndex
   * @param {Ext.EventObject} e
   */
  onCellClick: function onCellClick(grid, rowIndex, colIndex, e) {
    var dataIndex = this.getColumnModel().getDataIndex(colIndex),
        resolveRecord = this.store.getAt(rowIndex);

    if (resolveRecord && dataIndex && dataIndex.match(/clientValue|value\d+/)) {
      if (e.shiftKey && Ext.isString(resolveRecord.get(dataIndex))) {
        // combine string values if shift is pressed
        var record = this.store.getAt(rowIndex),
            combined = record.get('clientValue') + ' / ' + record.get('value0'),
            colToSelect = colIndex == 2 ? 3 : 2,
            otherCellEl = this.getView().getCell(rowIndex, colToSelect);

        if (otherCellEl) {
          // TODO it would be nicer if this worked ...
          //Ext.fly(otherCellEl).addClass('x-grid3-cell-selected');
          Ext.fly(otherCellEl).highlight();
        }

        resolveRecord.set('finalValue', combined);
      } else {
        resolveRecord.set('finalValue', resolveRecord.get(dataIndex));
      }

      var celEl = this.getView().getCell(rowIndex, this.getColumnModel().getIndexById('finalValue'));

      if (celEl) {
        Ext.fly(celEl).highlight();
      }
    }
  },

  /**
   * called when the store got new data
   */
  onStoreLoad: function onStoreLoad() {
    var strategy = this.store.resolveStrategy;
    this.actionCombo.setValue(strategy);
    this.applyStrategy(strategy);
  },

  /**
   * select handler of action combo
   */
  onActionSelect: function onActionSelect(combo, record, idx) {
    var strategy = record.get('value');
    this.applyStrategy(strategy);
    this.store.applyStrategy(strategy);
  },

  /**
   * apply an action (generate final data)
   * - mergeTheirs:   merge keep existing values (discards client record)
   * - mergeMine:     merge, keep client values (discards client record)
   * - discard:       discard client record
   * - keep:          keep client record (create duplicate)
   * 
   * @param {Ext.data.Store} store with field records (DuplicateResolveModel)
   * @param {Sting} strategy
   */
  applyStrategy: function applyStrategy(strategy) {
    var cm = this.getColumnModel(),
        view = this.getView();

    if (cm) {
      cm.setHidden(cm.getIndexById('clientValue'), strategy == 'discard');
      cm.setHidden(cm.getIndexById('finalValue'), strategy == 'keep');

      if (view && view.grid) {
        this.getView().refresh();
      }
    }
  },

  /**
   * init our column model
   */
  initColumnModel: function initColumnModel() {
    var valueRendererDelegate = this.valueRenderer.createDelegate(this);
    this.cm = new Ext.grid.ColumnModel([{
      header: i18n._('Field Group'),
      width: 50,
      sortable: true,
      dataIndex: 'group',
      id: 'group',
      menuDisabled: true
    }, {
      header: i18n._('Field Name'),
      width: 50,
      sortable: true,
      dataIndex: 'i18nFieldName',
      id: 'i18nFieldName',
      menuDisabled: true
    }, {
      header: i18n._('My Value'),
      width: 50,
      resizable: false,
      dataIndex: 'clientValue',
      id: 'clientValue',
      menuDisabled: true,
      renderer: valueRendererDelegate
    }, {
      header: i18n._('Existing Value'),
      width: 50,
      resizable: false,
      dataIndex: 'value' + this.store.duplicateIdx,
      id: 'value' + this.store.duplicateIdx,
      menuDisabled: true,
      renderer: valueRendererDelegate
    }, {
      header: i18n._('Final Value'),
      width: 50,
      resizable: false,
      dataIndex: 'finalValue',
      id: 'finalValue',
      menuDisabled: true,
      renderer: valueRendererDelegate,
      editable: true
    }]);
  },

  /**
   * init the toolbar
   */
  initToolbar: function initToolbar() {
    let mergeStrategies = [['keep', i18n._('Keep both records')]];

    if (!_.get(this, 'store.clientRecord.id')) {
      // only allow all strategies for new (client) records
      mergeStrategies = [['mergeTheirs', i18n._('Merge, keeping existing details')], ['mergeMine', i18n._('Merge, keeping my details')], ['discard', i18n._('Keep existing record and discard mine')]].concat(mergeStrategies);
    }

    this.tbar = [{
      xtype: 'label',
      text: i18n._('Action:') + ' '
    }, {
      xtype: 'combo',
      ref: '../actionCombo',
      typeAhead: true,
      width: 350,
      triggerAction: 'all',
      lazyRender: true,
      mode: 'local',
      valueField: 'value',
      displayField: 'text',
      value: this.store.resolveStrategy,
      store: new Ext.data.ArrayStore({
        id: 0,
        fields: ['value', 'text'],
        data: mergeStrategies
      }),
      listeners: {
        scope: this,
        select: this.onActionSelect
      }
    }];
  },

  /**
   * interceptor for all renderers
   * - manage colors
   * - pick appropriate renderer
   */
  valueRenderer: function valueRenderer(value, metaData, record, rowIndex, colIndex, store) {
    var fieldName = record.get('fieldName'),
        dataIndex = this.getColumnModel().getDataIndex(colIndex),
        cfValue = arguments[0],
        renderer = Tine.widgets.grid.RendererManager.get(this.app, this.store.recordClass, fieldName, Tine.widgets.grid.RendererManager.CATEGORY_GRIDPANEL); // color management

    if (dataIndex && dataIndex.match(/clientValue|value\d+/) && !this.store.resolveStrategy.match(/(keep|discard)/)) {
      var action = record.get('finalValue') == value ? 'keep' : 'discard';
      metaData.css = 'tine-duplicateresolve-' + action + 'value';
    }

    if (String(fieldName).match(/^#.+/)) {
      arguments[0] = {};
      arguments[0][fieldName.replace(/^#/, '')] = cfValue;
    }

    metaData.css = metaData.css + ' tine-dublicateResolve-cell';
    return renderer.apply(this, arguments);
  }
});
/**
 * @class Tine.widgets.dialog.DuplicateResolveModel
 * A specific {@link Ext.data.Record} type that represents a field/clientValue/doublicateValues/finalValue set and is made to work with the
 * {@link Tine.widgets.dialog.DuplicateResolveGridPanel}.
 * @constructor
 */

Tine.widgets.dialog.DuplicateResolveModel = Ext.data.Record.create([{
  name: 'fieldName',
  type: 'string'
}, {
  name: 'fieldDef',
  type: 'fieldDef'
}, {
  name: 'group',
  type: 'string'
}, {
  name: 'i18nFieldName',
  type: 'string'
}, 'clientValue', 'value0', 'value1', 'value2', 'value3', 'value4', 'finalValue']);
Tine.widgets.dialog.DuplicateResolveStore = Ext.extend(Ext.data.GroupingStore, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   * instance of the app object (required)
   */
  app: null,

  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,

  /**
   * @cfg {Ext.data.DataProxy} recordProxy
   */
  recordProxy: null,

  /**
   * @cfg {Object/Record} clientRecord
   */
  clientRecord: null,

  /**
   * @cfg {Array} duplicates
   * array of Objects or Records
   */
  duplicates: null,

  /**
   * @cfg {String} resolveStrategy
   * default resolve action
   */
  resolveStrategy: null,

  /**
   * @cfg {String} defaultResolveStrategy
   * default resolve action
   */
  defaultResolveStrategy: 'mergeTheirs',
  // private config overrides
  idProperty: 'fieldName',
  fields: Tine.widgets.dialog.DuplicateResolveModel,
  groupField: 'group',
  sortInfo: {
    field: 'group',
    oder: 'ASC'
  },
  constructor: function constructor(config) {
    var initialData = config.data;
    delete config.data;
    this.reader = new Ext.data.JsonReader({
      idProperty: this.idProperty,
      fields: this.fields
    });
    Tine.widgets.dialog.DuplicateResolveStore.superclass.constructor.apply(this, arguments);

    if (!this.recordProxy && this.recordClass) {
      this.recordProxy = new Tine.Tinebase.data.RecordProxy({
        recordClass: this.recordClass
      });
    } // force duplicate 0 atm.


    this.duplicateIdx = 0;

    if (initialData) {
      this.loadData(initialData);
    }
  },
  loadData: function loadData(data, resolveStrategy, finalRecord) {
    // init records
    this.clientRecord = this.createRecord(data.clientRecord);
    this.duplicates = data.duplicates;
    Ext.each([].concat(this.duplicates), function (duplicate, idx) {
      this.duplicates[idx] = this.createRecord(this.duplicates[idx]);
    }, this);

    if (this.clientRecord.id) {
      this.resolveStrategy = 'keep';
    } else {
      this.resolveStrategy = resolveStrategy || this.defaultResolveStrategy;
    }

    if (finalRecord) {
      finalRecord = this.createRecord(finalRecord);
    }

    var fieldDefinitions = this.recordClass.getFieldDefinitions(),
        cfDefinitions = Tine.widgets.customfields.ConfigManager.getConfigs(this.app, this.recordClass, true);
    var recordsToAdd = [];
    Ext.each(fieldDefinitions.concat(cfDefinitions), function (field) {
      if (field.omitDuplicateResolving) {
        return;
      }

      var fieldName = field.name,
          fieldGroup = field.uiconfig ? field.uiconfig.group : field.group,
          recordData = {
        fieldName: fieldName,
        fieldDef: field,
        i18nFieldName: field.label ? this.app.i18n._hidden(field.label) : this.app.i18n._hidden(fieldName),
        clientValue: Tine.Tinebase.common.assertComparable(this.clientRecord.get(fieldName))
      };
      recordData.group = fieldGroup ? this.app.i18n._hidden(fieldGroup) : recordData.i18nFieldName;
      Ext.each([].concat(this.duplicates), function (duplicate, idx) {
        recordData['value' + idx] = Tine.Tinebase.common.assertComparable(this.duplicates[idx].get(fieldName));
      }, this);
      var record = new Tine.widgets.dialog.DuplicateResolveModel(recordData, fieldName);

      if (finalRecord) {
        if (finalRecord.modified && finalRecord.modified.hasOwnProperty(fieldName)) {
          record.set('finalValue', finalRecord.modified[fieldName]);
        }

        record.set('finalValue', finalRecord.get(fieldName));
      }

      recordsToAdd.push(record);
    }, this);
    this.insert(0, recordsToAdd);

    if (!finalRecord) {
      this.applyStrategy(this.resolveStrategy);
    }

    this.sortData();
    this.fireEvent('load', this);
  },

  /**
   * custom sorter
   * 
   * @param {String} f (ignored atm.)
   * @param {String} direction
   */
  sortData: function sortData(f, direction) {
    direction = direction || 'ASC';
    var groupConflictScore = {};
    this.each(function (r) {
      var group = r.get('group'),
          myValue = String(r.get('clientValue')).replace(/^undefined$|^null$|^\[\]$/, ''),
          theirValue = String(r.get('value' + this.duplicateIdx)).replace(/^undefined$|^null$|^\[\]$/, '');

      if (!groupConflictScore.hasOwnProperty(group)) {
        groupConflictScore[group] = 990;
      }

      if (myValue || theirValue) {
        groupConflictScore[group] -= 1;
      }

      if (myValue != theirValue) {
        groupConflictScore[group] -= 10;
      }
    }, this);
    this.data.sort('ASC', function (r1, r2) {
      var g1 = r1.get('group'),
          v1 = String(groupConflictScore[g1]) + g1,
          g2 = r2.get('group'),
          v2 = String(groupConflictScore[g2]) + g2;
      return v1 > v2 ? 1 : v1 < v2 ? -1 : 0;
    });
  },

  /**
   * apply an strategy (generate final data)
   * - mergeTheirs:   merge keep existing values (discards client record)
   * - mergeMine:     merge, keep client values (discards client record)
   * - discard:       discard client record
   * - keep:          keep client record (create duplicate)
   * 
   * @param {Sting} strategy
   */
  applyStrategy: function applyStrategy(strategy) {
    Tine.log.debug('Tine.widgets.dialog.DuplicateResolveStore::applyStrategy() - action: ' + strategy);
    this.resolveStrategy = strategy;
    this.checkEditGrant();
    this.each(function (resolveRecord) {
      var theirs = resolveRecord.get('value' + this.duplicateIdx),
          mine = resolveRecord.get('clientValue'),
          location = this.resolveStrategy === 'keep' ? 'mine' : 'theirs'; // undefined or empty theirs value -> keep mine

      if (this.resolveStrategy == 'mergeTheirs' && ['', 'null', 'undefined', '[]'].indexOf(String(theirs)) > -1) {
        location = 'mine';
      } // only keep mine if its not undefined or empty


      if (this.resolveStrategy == 'mergeMine' && ['', 'null', 'undefined', '[]'].indexOf(String(mine)) < 0) {
        location = 'mine';
      } // special merge for tags


      if (resolveRecord.get('fieldName') == 'tags') {
        resolveRecord.set('finalValue', this.mergeTags(mine, theirs));
      } else {
        resolveRecord.set('finalValue', location === 'mine' ? mine : theirs);
      }

      Tine.log.debug('Tine.widgets.dialog.DuplicateResolveStore::applyStrategy() - resolved record field: ' + resolveRecord.get('fieldName'));
      Tine.log.debug(resolveRecord);
    }, this);
    this.commitChanges();
  },

  /**
   * merge tags
   *
   * @param {Array} mine
   * @param {Array} theirs
   *
   * TODO generalize me for "merge-able" values
   */
  mergeTags: function mergeTags(mine, theirs) {
    var result = [],
        records = Tine.Tinebase.common.assertComparable([].concat(this.resolveStrategy != 'discard' ? mine : []).concat(this.resolveStrategy != 'keep' ? theirs : [])),
        recordIds = []; // remove duplicates (TODO should be simplified)

    Ext.each(records, function (value) {
      if (value && recordIds.indexOf(value['id']) < 0) {
        result.push(value);
        recordIds.push(value['id']);
      }
    });
    return result;
  },
  checkEditGrant: function checkEditGrant() {
    var grant = !this.recordClass.getMeta('containerProperty') ? true : this.duplicates[this.duplicateIdx].get('container_id') ? this.duplicates[this.duplicateIdx].get(this.recordClass.getMeta('containerProperty')).account_grants['editGrant'] : false; // change strategy from merge to keep if user has no rights to merge

    if (this.resolveStrategy.match(/^merge/) && !grant) {
      Tine.log.info('Tine.widgets.dialog.DuplicateResolveStore::checkEditGrant() - user has no editGrant, changing strategy to keep');
      this.resolveStrategy = 'keep';
      this.fireEvent('strategychange', this, this.resolveStrategy);
    }
  },

  /**
   * returns record with conflict resolved data
   */
  getResolvedRecord: function getResolvedRecord() {
    var record = (this.resolveStrategy == 'keep' || this.resolveStrategy == 'mergeMine' ? this.clientRecord : this.duplicates[this.duplicateIdx]).copy();
    this.each(function (resolveRecord) {
      var fieldName = resolveRecord.get('fieldName'),
          finalValue = resolveRecord.get('finalValue'),
          modified = resolveRecord.modified || {}; // also record changes

      if (modified.hasOwnProperty('finalValue')) {
        Tine.log.debug('Tine.widgets.dialog.DuplicateResolveStore::getResolvedRecord ' + fieldName + ' changed from ' + modified.finalValue + ' to ' + finalValue);
        record.set(fieldName, Tine.Tinebase.common.assertComparable(modified.finalValue));
      }

      record.set(fieldName, Tine.Tinebase.common.assertComparable(finalValue));
    }, this);
    Tine.log.debug('Tine.widgets.dialog.DuplicateResolveStore::getResolvedRecord() resolved record:');
    Tine.log.debug(record);
    return record;
  },

  /**
   * create record from data
   * 
   * @param {Object} data
   * @return {Record}
   */
  createRecord: function createRecord(data) {
    return Ext.isFunction(data.beginEdit) ? data : this.recordProxy.recordReader({
      responseText: Ext.encode(data)
    });
  }
});

/***/ }),
/* 1334 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase.widgets', 'Tine.widgets.grid');
/**
 * grid details panel
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.DetailsPanel
 * @extends     Ext.Panel
 * 
 * <p>Grid Details Panel</p>
 * <p><pre>
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.grid.DetailsPanel
 */

Tine.widgets.grid.DetailsPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Number} defaultHeight
   * default Heights
   */
  defaultHeight: 125,

  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class
   */
  recordClass: null,

  /**
   * @cfg {Bool} listenMessageBus
   * listen to messagebus for record changes
   */
  listenMessageBus: true,

  /**
   * @property grid
   * @type Tine.widgets.grid.GridPanel
   */
  grid: null,

  /**
   * @property record
   * @type Tine.Tinebase.data.Record
   */
  record: null,

  /**
   * @property defaultInfosPanel holds panel for default information
   * @type Ext.Panel
   */
  defaultInfosPanel: null,

  /**
   * @property singleRecordPanel holds panel for single record details
   * @type Ext.Panel
   */
  singleRecordPanel: null,

  /**
   * @property multiRecordsPanel holds panel for multi selection aggregates/information
   * @type Ext.Panel
   */
  multiRecordsPanel: null,

  /**
   * @private
   */
  border: false,
  autoScroll: true,
  layout: 'card',
  activeItem: 0,

  /**
   * get panel for default information
   * 
   * @return {Ext.Panel}
   */
  getDefaultInfosPanel: function getDefaultInfosPanel() {
    if (!this.defaultInfosPanel) {
      if (this.recordClass) {
        this.defaultInfosPanel = new Tine.widgets.display.DefaultDisplayPanel({
          recordClass: this.recordClass
        });
        this.defaultHeight = Math.max(this.defaultHeight, this.defaultInfosPanel.defaultHeight);
      } else {
        this.defaultInfosPanel = new Ext.Panel(this.defaults);
      }
    }

    return this.defaultInfosPanel;
  },

  /**
   * get panel for single record details
   * 
   * @return {Ext.Panel}
   */
  getSingleRecordPanel: function getSingleRecordPanel() {
    if (!this.singleRecordPanel) {
      if (this.recordClass) {
        this.singleRecordPanel = new Tine.widgets.display.RecordDisplayPanel({
          recordClass: this.recordClass
        });
        this.defaultHeight = Math.max(this.defaultHeight, this.singleRecordPanel.defaultHeight);
      } else {
        this.singleRecordPanel = new Ext.Panel(this.defaults);
      }
    }

    return this.singleRecordPanel;
  },

  /**
   * get panel for multi selection aggregates/information
   * 
   * @return {Ext.Panel}
   */
  getMultiRecordsPanel: function getMultiRecordsPanel() {
    if (!this.multiRecordsPanel) {
      this.multiRecordsPanel = new Ext.Panel(this.defaults);
    }

    return this.multiRecordsPanel;
  },

  /**
   * inits this details panel
   */
  initComponent: function initComponent() {
    this.items = [this.getDefaultInfosPanel(), this.getSingleRecordPanel(), this.getMultiRecordsPanel()]; // NOTE: this defaults overwrites configs in already instanciated configs -> see docu

    Ext.each(this.items, function (item) {
      Ext.applyIf(item, {
        border: false,
        autoScroll: true,
        layout: 'fit'
      });
    }, this);

    if (this.listenMessageBus && this.recordClass) {
      this.initMessageBus();
    }

    Tine.widgets.grid.DetailsPanel.superclass.initComponent.apply(this, arguments);
  },
  onDestroy: function onDestroy() {
    _.each(this.postalSubscriptions, subscription => {
      subscription.unsubscribe();
    });

    return this.supr().onDestroy.call(this);
  },
  initMessageBus: function initMessageBus() {
    this.postalSubscriptions = [];
    this.postalSubscriptions.push(postal.subscribe({
      channel: "recordchange",
      topic: [this.recordClass.getMeta('appName'), this.recordClass.getMeta('modelName'), '*'].join('.'),
      callback: this.onRecordChanges.createDelegate(this)
    }));
  },

  /**
   * bus notified about record changes
   */
  onRecordChanges: function onRecordChanges(data, e) {
    var _ = window.lodash;

    if (this.singleRecordPanel.isVisible() && this.record.id == data.id) {
      this.record = Tine.Tinebase.data.Record.setFromJson(data, this.recordClass);
      this.updateDetails(this.record, this.getSingleRecordPanel().body);
    }
  },

  /**
   * update template
   * 
   * @param {Tine.Tinebase.data.Record} record
   * @param {Mixed} body
   */
  updateDetails: function updateDetails(record, body) {
    if (this.tpl) {
      this.tpl.overwrite(body, record.data);
    } else {
      this.getSingleRecordPanel().loadRecord.defer(100, this.getSingleRecordPanel(), [record]);
    }
  },

  /**
   * show default template
   * 
   * @param {Mixed} body
   */
  showDefault: function showDefault(body) {
    if (this.defaultTpl && body) {
      this.defaultTpl.overwrite(body);
    }
  },

  /**
   * show template for multiple rows
   * 
   * @param {Ext.grid.RowSelectionModel} sm
   * @param {Mixed} body
   */
  showMulti: function showMulti(sm, body) {
    if (this.multiTpl) {
      this.multiTpl.overwrite(body);
    }
  },

  /**
   * bind grid to details panel
   * 
   * @param {Tine.widgets.grid.GridPanel} grid
   */
  doBind: function doBind(grid) {
    this.grid = grid;
    /*
    grid.getSelectionModel().on('selectionchange', function(sm) {
        if (this.updateOnSelectionChange) {
            this.onDetailsUpdate(sm);
        }
    }, this);
    */

    grid.store.on('load', function (store) {
      this.onDetailsUpdate(grid.getSelectionModel());
    }, this);
  },

  /**
   * update details panel
   * 
   * @param {Ext.grid.RowSelectionModel} sm
   */
  onDetailsUpdate: function onDetailsUpdate(sm) {
    var count = sm.getCount();

    if (count === 0 || sm.isFilterSelect) {
      if (this.layout && Ext.isFunction(this.layout.setActiveItem)) {
        this.layout.setActiveItem(this.getDefaultInfosPanel());
      }

      this.showDefault(this.getDefaultInfosPanel().body);
      this.record = null;
    } else if (count === 1) {
      this.layout.setActiveItem(this.getSingleRecordPanel());
      this.record = sm.getSelected();
      this.updateDetails(this.record, this.getSingleRecordPanel().body);
    } else if (count > 1) {
      this.layout.setActiveItem(this.getMultiRecordsPanel());
      this.record = sm.getSelected();
      this.showMulti(sm, this.getMultiRecordsPanel().body);
    }
  },

  /**
   * get load mask
   * 
   * @return {Ext.LoadMask}
   */
  getLoadMask: function getLoadMask() {
    if (!this.loadMask) {
      this.loadMask = new Ext.LoadMask(this.el);
    }

    return this.loadMask;
  },

  /**
   * Wraps the items with default layout
   * 
   * @param {Array} items
   * @return {Object}
   */
  wrapPanel: function wrapPanel(items, labelWidth) {
    return {
      layout: 'fit',
      border: false,
      items: [{
        layout: 'vbox',
        border: false,
        layoutConfig: {
          align: 'stretch'
        },
        items: [{
          layout: 'hbox',
          flex: 1,
          border: false,
          layoutConfig: {
            padding: '5',
            align: 'stretch'
          },
          defaults: {
            margins: '0 5 0 0'
          },
          items: [{
            flex: 2,
            layout: 'ux.display',
            labelWidth: labelWidth,
            padding: 10,
            layoutConfig: {
              background: 'solid',
              margins: '0 5 0 0'
            },
            items: items
          }]
        }]
      }]
    };
  }
});
Ext.reg('widget-detailspanel', Tine.widgets.grid.DetailsPanel);

/***/ }),
/* 1335 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO         add year to 'inweek' filter?
 */
Ext.ns('Tine.widgets.grid');
/**
 * Model of filter
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterModel
 * @extends     Ext.util.Observable
 * @constructor
 */

Tine.widgets.grid.FilterModel = function (config) {
  Ext.apply(this, config);
  Tine.widgets.grid.FilterModel.superclass.constructor.call(this);
  this.addEvents(
  /**
   * @event filtertrigger
   * is fired when user request to update list by filter
   * @param {Tine.widgets.grid.FilterToolbar}
   */
  'filtertrigger');
  this.initComponent();
};

Ext.extend(Tine.widgets.grid.FilterModel, Ext.util.Observable, {
  /**
   * @cfg {String} label 
   * label for the filter
   */
  label: '',

  /**
   * @cfg {String} field
   * name of th field to filter
   */
  field: '',

  /**
   * @cfg {String} valueType
   * type of value
   */
  valueType: 'string',

  /**
   * @cfg {String} defaultValue
   * default value
   */
  defaultValue: null,

  /**
   * @cfg {Array} operators
   * valid operators
   */
  operators: null,

  /**
   * @cfg {String} defaultOperator
   * name of the default operator
   */
  defaultOperator: null,

  /**
   * @cfg {Array} customOperators
   * define custom operators
   */
  customOperators: null,

  /**
   * @cfg {Ext.data.Store|Array} 
   * used by combo valueType
   */
  store: null,

  /**
   * @cfg {String} displayField
   * used by combo valueType
   */
  displayField: null,

  /**
   * @cfg {String} valueField
   * used by combo valueType
   */
  valueField: null,

  /**
   * @cfg dateFilterSupportsPeriod
   * @type Boolean
   */
  dateFilterSupportsPeriod: true,

  /**
   * holds the future operators of date filters. Auto set by getDateFutureOps
   * 
   * @type {Array}
   */
  dateFutureOps: null,

  /**
   * holds the future operators of date filters. Auto set by getDatePastOps
   * 
   * @type {Array}
   */
  datePastOps: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.isFilterModel = true;

    if (!this.operators) {
      this.operators = [];
    }

    if (this.appName && !this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    } // e.g. {name = 'someApp'}


    this.app = Tine.Tinebase.appMgr.get(this.app);

    if (this.app) {
      this.itemName = this.itemName || this.label;
      this.label = this.app.i18n._hidden(this.label);
    }

    if (this.defaultOperator === null) {
      switch (this.valueType) {
        case 'date':
          this.defaultOperator = 'within';
          break;

        case 'account':
        case 'group':
        case 'user':
        case 'bool':
        case 'number':
        case 'money':
        case 'percentage':
        case 'combo':
        case 'time':
        case 'country':
          this.defaultOperator = 'equals';
          break;

        case 'string':
        default:
          this.defaultOperator = 'contains';
          break;
      }
    }

    if (this.defaultValue === null) {
      switch (this.valueType) {
        case 'customfield':
        case 'string':
          this.defaultValue = '';
          break;

        case 'bool':
          this.defaultValue = '1';
          break;

        case 'percentage':
          this.defaultValue = '0';
          break;

        case 'date':
        case 'account':
        case 'group':
        case 'user':
        case 'number':
        case 'money':
        case 'country':
        default:
          break;
      }
    }

    this.datePastOps = this.getDatePastOps();
    this.dateFutureOps = this.getDateFutureOps();
  },

  /**
   * returns past operators for date fields, may be overridden
   * 
   * @return {Array}
   */
  getDatePastOps: function getDatePastOps() {
    return [['dayThis', i18n._('today')], ['dayLast', i18n._('yesterday')], ['weekThis', i18n._('this week')], ['weekLast', i18n._('last week')], ['weekBeforeLast', i18n._('the week before last')], ['monthThis', i18n._('this month')], ['monthLast', i18n._('last month')], ['monthThreeLast', i18n._('last three months')], ['monthSixLast', i18n._('last six months')], ['anytime', i18n._('anytime')], ['quarterThis', i18n._('this quarter')], ['quarterLast', i18n._('last quarter')], ['yearThis', i18n._('this year')], ['yearLast', i18n._('last year')]];
  },

  /**
   * returns future operators for date fields, may be overridden
   * 
   * @return {Array}
   */
  getDateFutureOps: function getDateFutureOps() {
    return [['dayNext', i18n._('tomorrow')], ['weekNext', i18n._('next week')], ['monthNext', i18n._('next month')], ['quarterNext', i18n._('next quarter')], ['yearNext', i18n._('next year')]];
  },
  onDestroy: Ext.emptyFn,
  getItemGender: function getItemGender() {
    var me = this,
        app = Tine.Tinebase.appMgr.get(me.app),
        i18n = app ? app.i18n : window.i18n,
        gender = this.gender || i18n._hidden('GENDER_' + (me.itemName || me.label));

    return String(gender).match(/^GENDER_/) ? 'other' : gender;
  },

  /**
   * operator renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  operatorRenderer: function operatorRenderer(filter, el) {
    var _ = window.lodash,
        me = this,
        gender = me.getItemGender(),
        operatorStore = new Ext.data.JsonStore({
      fields: ['operator', 'label'],
      data: [{
        operator: 'contains',
        label: i18n._('contains')
      }, {
        operator: 'wordstartswith',
        label: i18n._('contains word starting with')
      }, {
        operator: 'notcontains',
        label: i18n._('contains not')
      }, {
        operator: 'regex',
        label: i18n._('reg. exp.')
      }, {
        operator: 'equals',
        label: i18n._('is equal to')
      }, {
        operator: 'equalsspecial',
        label: i18n._('is equal to without (-, )')
      }, {
        operator: 'greater',
        label: i18n._('is greater than')
      }, {
        operator: 'less',
        label: i18n._('is less than')
      }, {
        operator: 'not',
        label: i18n._('is not')
      }, {
        operator: 'in',
        label: formatMessage('{gender, select, male {one of} female {one of} other {one of}}', {
          gender: gender
        })
      }, {
        operator: 'allOf',
        label: formatMessage('{gender, select, male {all of} female {all of} other {all of}}', {
          gender: gender
        })
      }, {
        operator: 'notin',
        label: formatMessage('{gender, select, male {none of} female {none of} other {none of}}', {
          gender: gender
        })
      }, {
        operator: 'before',
        label: i18n._('is before')
      }, {
        operator: 'after',
        label: i18n._('is after')
      }, {
        operator: 'within',
        label: i18n._('is within')
      }, {
        operator: 'inweek',
        label: i18n._('is in week no.')
      }, {
        operator: 'startswith',
        label: i18n._('starts with')
      }, {
        operator: 'endswith',
        label: i18n._('ends with')
      }, {
        operator: 'definedBy',
        label: i18n._('defined by')
      }].concat(this.getCustomOperators() || []),
      remoteSort: false,
      sortInfo: {
        field: 'label',
        direction: 'ASC'
      }
    }); // filter operators

    if (this.operators.length == 0) {
      switch (this.valueType) {
        case 'fulltext':
          this.operators.push('wordstartswith');
          break;

        case 'string':
          this.operators.push('contains', 'notcontains', 'equals', 'startswith', 'endswith', 'not', 'in', 'notin');
          break;

        case 'customfield':
          this.operators.push('contains', 'equals', 'startswith', 'endswith', 'not');
          break;

        case 'time':
          this.operators.push('equals', 'before', 'after');
          break;

        case 'date':
          this.operators.push('equals', 'before', 'after', 'within', 'inweek');
          break;

        case 'number':
        case 'money':
        case 'percentage':
          this.operators.push('equals', 'greater', 'less');
          break;

        default:
          this.operators.push(this.defaultOperator);
          break;
      }
    }

    if (this.operators.length > 0) {
      operatorStore.each(function (operator) {
        if (this.operators.indexOf(operator.get('operator')) < 0) {
          operatorStore.remove(operator);
        }
      }, this);
    } // add registered / custom operators


    _.each(this.operators, function (operator) {
      if (_.isObject(operator)) {
        operatorStore.loadData([{
          operator: operator.operator.filterName,
          label: operator.label
        }], true);
      }
    });

    if (operatorStore.getCount() > 1) {
      var operator = new Ext.form.ComboBox({
        filter: filter,
        mode: 'local',
        lazyInit: false,
        emptyText: i18n._('select a operator'),
        forceSelection: true,
        typeAhead: true,
        triggerAction: 'all',
        store: operatorStore,
        displayField: 'label',
        valueField: 'operator',
        value: filter.get('operator') ? filter.get('operator') : this.defaultOperator,
        tpl: '<tpl for="."><div class="x-combo-list-item tw-ftb-operator-{operator}">{label}</div></tpl>',
        renderTo: el
      });
      operator.on('select', function (combo, newRecord, newKey) {
        if (combo.value != combo.filter.get('operator')) {
          this.onOperatorChange(combo.filter, combo.value, true);
        }
      }, this);
      operator.on('blur', function (combo) {
        if (combo.value != combo.filter.get('operator')) {
          this.onOperatorChange(combo.filter, combo.value, true);
        }
      }, this);
    } else if (this.operators[0] == 'freeform') {
      var operator = new Ext.form.TextField({
        filter: filter,
        emptyText: this.emptyTextOperator || '',
        value: filter.get('operator') ? filter.get('operator') : '',
        renderTo: el
      });
    } else {
      var operator = new Ext.form.Label({
        readOnly: true,
        filter: filter,
        style: {
          margin: '0px 10px'
        },
        getValue: function getValue() {
          return operatorStore.getAt(0).get('operator');
        },
        text: operatorStore.getAt(0).get('label'),
        renderTo: el,
        setValue: Ext.emptyFn
      });
    }

    return operator;
  },

  /**
   * get custom operators
   * 
   * @return {Array}
   */
  getCustomOperators: function getCustomOperators() {
    return this.customOperators || [];
  },

  /**
   * called on operator change of a filter row
   * @private
   */
  onOperatorChange: function onOperatorChange(filter, newOperator, keepValue) {
    filter.set('operator', newOperator);
    filter.set('value', ''); // for date filters we need to rerender the value section

    if (this.valueType == 'date') {
      switch (newOperator) {
        case 'within':
          filter.numberfield.hide();
          filter.datePicker.hide();
          filter.withinCombo.show();
          filter.formFields.value = filter.withinCombo;
          break;

        case 'inweek':
          filter.withinCombo.hide();
          filter.datePicker.hide();
          filter.numberfield.show();
          filter.formFields.value = filter.numberfield;
          break;

        default:
          filter.withinCombo.hide();
          filter.numberfield.hide();
          filter.datePicker.show();
          filter.formFields.value = filter.datePicker;
      }
    }

    var _ = window.lodash,
        valueField = _.get(filter, 'formFields.value');

    if (valueField instanceof Ext.ux.form.ClearableTextField) {
      valueField.disableTrigger = newOperator != 'contains';
      valueField.checkTrigger();
    }

    var width = valueField.el.up('.tw-ftb-frow-value').getWidth() - 10;

    if (valueField.wrap) {
      valueField.wrap.setWidth(width);
    }

    valueField.setWidth(width);
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    var value,
        commonOptions = {
      filter: filter,
      renderTo: el,
      value: filter.data.value ? filter.data.value : this.defaultValue
    };

    switch (this.valueType) {
      case 'time':
        value = new Ext.form.TimeField(Ext.apply(commonOptions, {
          listeners: {
            'specialkey': function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            },
            'select': this.onFiltertrigger,
            scope: this
          }
        }));
        break;

      case 'date':
        value = this.dateValueRenderer(filter, el);
        break;

      case 'percentage':
        value = new Ext.ux.PercentCombo(Ext.apply(commonOptions, {
          listeners: {
            'specialkey': function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            },
            'select': this.onFiltertrigger,
            scope: this
          }
        }));
        break;

      case 'user':
        value = new Tine.Addressbook.SearchCombo(Ext.apply(commonOptions, {
          listWidth: 350,
          emptyText: i18n._('Search Account ...'),
          userOnly: true,
          name: 'organizer',
          nameField: 'n_fileas',
          useAccountRecord: true,
          listeners: {
            'specialkey': function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            },
            'select': this.onFiltertrigger,
            scope: this
          }
        }));
        break;

      case 'bool':
        value = new Ext.form.ComboBox(Ext.apply(commonOptions, {
          mode: 'local',
          forceSelection: true,
          triggerAction: 'all',
          store: [[0, Locale.getTranslationData('Question', 'no').replace(/:.*/, '')], [1, Locale.getTranslationData('Question', 'yes').replace(/:.*/, '')]],
          listeners: {
            'specialkey': function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            },
            'select': this.onFiltertrigger,
            scope: this
          }
        }));
        break;

      case 'combo':
        var comboConfig = Ext.apply(commonOptions, {
          mode: 'local',
          forceSelection: true,
          triggerAction: 'all',
          store: this.store,
          listeners: {
            'specialkey': function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            },
            'select': this.onFiltertrigger,
            scope: this
          }
        });

        if (this.displayField !== null && this.valueField !== null) {
          comboConfig.displayField = this.displayField;
          comboConfig.valueField = this.valueField;
        }

        value = new Ext.form.ComboBox(comboConfig);
        break;

      case 'country':
        value = new Tine.widgets.CountryCombo(Ext.apply(commonOptions, {}));
        break;

      case 'number':
        if (filter.specialType == 'percent') {
          Ext.apply(commonOptions, {
            useThousandSeparator: false,
            suffix: ' %'
          });
        }

        value = new Ext.ux.form.NumberField(Ext.apply(commonOptions, {
          decimalPrecision: 2,
          decimalSeparator: Tine.Tinebase.registry.get('decimalSeparator')
        }));
        break;

      case 'money':
        value = new Ext.ux.form.MoneyField(Ext.apply(commonOptions, {
          listeners: {
            scope: this,
            specialkey: function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            }
          }
        }));
        break;

      case 'customfield':
      case 'string':
      default:
        value = new Ext.ux.form.ClearableTextField(Ext.apply(commonOptions, {
          emptyText: this.emptyText,
          listeners: {
            scope: this,
            specialkey: function specialkey(field, e) {
              if (e.getKey() == e.ENTER) {
                this.onFiltertrigger();
              }
            }
          }
        }));
        break;
    }

    return value;
  },

  /**
   * called on value change of a filter row
   * @private
   */
  onValueChange: function onValueChange(filter, newValue) {
    filter.set('value', newValue);
  },

  /**
   * render a date value
   * 
   * we place a picker and a combo in the dom element and hide the one we don't need yet
   */
  dateValueRenderer: function dateValueRenderer(filter, el) {
    var me = this,
        operator = filter.get('operator') ? filter.get('operator') : this.defaultOperator;
    var valueType = 'datePicker';

    switch (operator) {
      case 'within':
        valueType = 'withinCombo';
        break;

      case 'inweek':
        valueType = 'numberfield';
        break;
    }

    var comboOps = this.pastOnly ? this.datePastOps : this.dateFutureOps.concat(this.datePastOps);
    var comboValue = 'weekThis';

    if (filter.data.value && filter.data.value.toString().match(/^[a-zA-Z]+$/)) {
      comboValue = filter.data.value.toString();
    } else if (filter.data.value && filter.data.value.from) {
      comboValue = filter.data.value;
    } else if (this.defaultValue && this.defaultValue.toString().match(/^[a-zA-Z]+$/)) {
      comboValue = this.defaultValue.toString();
    }

    if (this.dateFilterSupportsPeriod) {
      comboOps.unshift(['period', i18n._('Period ...')]);
    }

    filter.withinCombo = new Ext.form.ComboBox({
      hidden: valueType != 'withinCombo',
      filter: filter,
      renderTo: el,
      mode: 'local',
      lazyInit: false,
      forceSelection: true,
      typeAhead: true,
      triggerAction: 'all',
      store: comboOps,
      editable: false,
      listeners: {
        'specialkey': function specialkey(field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        },
        'select': function select(c) {
          if (c.getValue() != 'period') {
            this.onFiltertrigger();
          }
        },
        scope: this
      }
    });
    filter.withinCombo.origSetValue = filter.withinCombo.setValue;
    filter.withinCombo.origGetValue = filter.withinCombo.getValue;
    filter.withinCombo.origOnSelect = filter.withinCombo.onSelect;

    filter.withinCombo.setValue = function (value) {
      // try to convert some values when initialising
      var range = this.range || (value && value.from ? Ext.ux.form.PeriodPicker.getRange(value) : Ext.ux.form.PeriodPicker.prototype.range);

      if (me.dateFilterSupportsPeriod && !this.manualSelect && value != 'period' && !value.from) {
        range = window.lodash.get(String(value).match(/(day|week|month|quater|year)This$/), 1);

        if (range) {
          value = 'period';
        }
      }

      if (value == 'period' || value.from) {
        this.setRawValue('');

        if (!this.pp) {
          this.pp = new Ext.ux.form.PeriodPicker({
            range: range,
            FTBWidthCorrection: -18,
            periodIncludesUntil: true,
            cls: 'x-pp-combo',
            'renderTo': this.wrap
          });
          this.pp.on('change', me.onFiltertrigger, me, {
            buffer: 250
          });
          filter.withinCombo.on('resize', function (cmp, w) {
            this.pp.setSize(w - 18);
          });
        }

        this.pp.show();

        if (value.from) {
          this.pp.setValue(value);
        }
      } else {
        if (this.pp) {
          this.pp.hide();
        }

        return this.origSetValue(value);
      }
    };

    filter.withinCombo.getValue = function (value) {
      if (this.pp && this.pp.isVisible()) {
        return this.pp.getValue();
      } else {
        return this.origGetValue();
      }
    };

    filter.withinCombo.onSelect = function () {
      this.manualSelect = true;
      return this.origOnSelect.apply(this, arguments);
    };

    filter.withinCombo.setValue(comboValue);
    var pickerValue = '';

    if (Ext.isDate(filter.data.value)) {
      pickerValue = filter.data.value;
    } else if (Ext.isDate(Date.parseDate(filter.data.value, Date.patterns.ISO8601Long))) {
      pickerValue = Date.parseDate(filter.data.value, Date.patterns.ISO8601Long);
    } else if (Ext.isDate(this.defaultValue)) {
      pickerValue = this.defaultValue;
    }

    filter.datePicker = new Ext.form.DateField({
      hidden: valueType != 'datePicker',
      filter: filter,
      value: pickerValue,
      renderTo: el,
      listeners: {
        'specialkey': function specialkey(field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        },
        'select': this.onFiltertrigger,
        scope: this
      }
    });
    filter.numberfield = new Ext.form.NumberField({
      hidden: valueType != 'numberfield',
      filter: filter,
      value: pickerValue,
      renderTo: el,
      minValue: 1,
      maxValue: 52,
      maxLength: 2,
      allowDecimals: false,
      allowNegative: false,
      listeners: {
        scope: this,
        specialkey: function specialkey(field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        }
      }
    }); // upps, how to get a var i only know the name of???

    return filter[valueType];
  },

  /**
   * @private
   */
  onFiltertrigger: function onFiltertrigger() {
    // auto search on filter change only if set in user preferences
    if (parseInt(Tine.Tinebase.registry.get('preferences').get('filterChangeAutoSearch'), 10) === 1) {
      this.fireEvent('filtertrigger', this);
    }
  }
});
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterRegistry
 * @singleton
 */

Tine.widgets.grid.FilterRegistry = function () {
  var filters = {};
  return {
    register: function register(appName, modelName, filter) {
      var key = appName + '.' + modelName;

      if (!filters[key]) {
        filters[key] = [];
      }

      Ext.applyIf(filter, {
        appName: appName,
        modelName: modelName
      });
      filters[key].push(filter);
    },
    get: function get(appName, modelName) {
      if (Ext.isFunction(appName.getMeta)) {
        modelName = appName.getMeta('modelName');
        appName = appName.getMeta('appName');
      }

      var key = appName + '.' + modelName;
      return filters[key] || [];
    }
  };
}();

/***/ }),
/* 1336 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * Model of filter
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.MonthFilter
 * @extends     Tine.widgets.grid.FilterModel
 */

Tine.widgets.grid.MonthFilter = Ext.extend(Tine.widgets.grid.FilterModel, {
  valueType: 'date',
  defaultValue: 'monthLast',
  dateFilterSupportsPeriod: false,
  appName: null,
  label: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    Tine.widgets.grid.MonthFilter.superclass.initComponent.call(this);
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    this.label = this.label ? this.app.i18n._hidden(this.label) : i18n._("Month");
    this.operators = ['within', 'before', 'after', 'equals'];
  },

  /**
   * called on operator change of a filter row
   * @private
   */
  onOperatorChange: function onOperatorChange(filter, newOperator) {
    filter.set('operator', newOperator);
    filter.set('value', ''); // for date filters we need to rerender the value section

    switch (newOperator) {
      case 'within':
        filter.numberfield.hide();
        filter.datePicker.hide();
        filter.textfield.hide();
        filter.withinCombo.show();
        filter.formFields.value = filter.withinCombo;
        break;

      case 'inweek':
        filter.withinCombo.hide();
        filter.datePicker.hide();
        filter.textfield.hide();
        filter.numberfield.show();
        filter.formFields.value = filter.numberfield;
        break;

      case 'equals':
        filter.withinCombo.hide();
        filter.datePicker.hide();
        filter.numberfield.hide();
        filter.textfield.show();
        filter.formFields.value = filter.textfield;
        break;

      default:
        filter.withinCombo.hide();
        filter.numberfield.hide();
        filter.textfield.hide();
        filter.datePicker.show();
        filter.formFields.value = filter.datePicker;
    }

    var width = filter.formFields.value.el.up('.tw-ftb-frow-value').getWidth() - 10;

    if (filter.formFields.value.wrap) {
      filter.formFields.value.wrap.setWidth(width);
    }

    filter.formFields.value.setWidth(width);
  },

  /**
   * render a date value
   * 
   * we place a picker and a combo in the dom element and hide the one we don't need yet
   */
  dateValueRenderer: function dateValueRenderer(filter, el) {
    var operator = filter.get('operator') ? filter.get('operator') : this.defaultOperator;

    if (!filter.textfield) {
      filter.textfield = new Ext.ux.form.ClearableTextField({
        filter: filter,
        hidden: true,
        renderTo: el,
        value: filter.data.value ? filter.data.value : '',
        emptyText: this.emptyText,
        listeners: {
          scope: this,
          change: function change() {
            this.onFiltertrigger();
          },
          specialkey: function specialkey(field, e) {
            if (e.getKey() == e.ENTER) {
              this.onFiltertrigger();
            }
          }
        }
      });
    }

    if (operator != 'equals') {
      return Tine.widgets.grid.MonthFilter.superclass.dateValueRenderer.call(this, filter, el);
    }

    return filter.textfield;
  },

  /**
   * returns past operators for date fields, may be overridden
   * 
   * @return {Array}
   */
  getDatePastOps: function getDatePastOps() {
    return [['monthThis', i18n._('this month')], ['monthLast', i18n._('last month')], ['quarterThis', i18n._('this quarter')], ['quarterLast', i18n._('last quarter')], ['yearThis', i18n._('this year')], ['yearLast', i18n._('last year')]];
  },

  /**
   * returns future operators for date fields, may be overridden
   * 
   * @return {Array}
   */
  getDateFutureOps: function getDateFutureOps() {
    return [];
  }
});

/***/ }),
/* 1337 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterPlugin
 * @extends     Ext.util.Observable
 * <p>Base class for all grid filter plugins.</p>
 * @constructor
 */

Tine.widgets.grid.FilterPlugin = function (config) {
  config = config || {};
  Ext.apply(this, config);
  this.addEvents(
  /**
   * @event change
   * Fired when the filter changed.
   * @param {Tine.widgets.grid.FilterPlugin} this
   */
  'change');
  Tine.widgets.grid.FilterPlugin.superclass.constructor.call(this);
};

Ext.extend(Tine.widgets.grid.FilterPlugin, Ext.util.Observable, {
  /**
   * @property {Ext.grid.GridPanel} grid
   */
  grid: null,

  /**
   * @property {Ext.data.Store} store
   */
  store: null,

  /**
   * @property {String} xtype
   */
  xtype: 'filterplugin',

  /**
   * main method which must return the filter object of this filter
   * 
   * @return {Object}
   */
  getValue: Ext.emptyFn,

  /**
   * returns gird panel this filterplugin is bound to/for
   * 
   * @return {Ext.Panel}
   */
  getGridPanel: function getGridPanel() {
    return this.grid;
  },

  /**
   * main method which must set the filter from given data
   * 
   * @param {Array} all filters
   */
  setValue: Ext.emptyFn,

  /**
   * plugin method of Ext.grid.GridPanel
   * 
   * @param {Ext.grid.GridPanel} grid
   */
  init: function init(grid) {
    this.grid = grid;
    this.store = grid.store;
    this.doBind();
  },

  /**
   * binds this plugin to the grid store
   */
  doBind: function doBind() {
    this.store.on('beforeload', this.onBeforeLoad, this);
    this.store.on('load', this.onLoad, this);
  },

  /**
   * fires our change event
   */
  onFilterChange: function onFilterChange() {
    if (this.getGridPanel() && typeof this.getGridPanel().getView === 'function') {
      this.getGridPanel().getView().isPagingRefresh = true;
    }

    if (this.store) {
      this.store.load({});
    }

    this.fireEvent('change', this);
  },

  /**
   * called before store loads
   */
  onBeforeLoad: function onBeforeLoad(store, options) {
    options = options || {};
    options.params = options.params || {};
    options.params.filter = options.params.filter ? options.params.filter : [];
    this.lastStoreTransactionId = options.transactionId;
    var value = this.getValue();

    if (value && Ext.isArray(options.params.filter)) {
      value = Ext.isArray(value) ? value : [value];

      for (var i = 0; i < value.length; i++) {
        options.params.filter.push(value[i]);
      }
    }
  },

  /**
   * called after store data loaded
   */
  onLoad: function onLoad(store, records, options) {
    if (this.lastStoreTransactionId && options.transactionId && this.lastStoreTransactionId !== options.transactionId) {
      Tine.log.debug('FilterPlugin::onLoad - do not set non recent filter data');
      return;
    }

    if (Ext.isArray(store.proxy.jsonReader.jsonData.filter)) {
      // filter plugin has to 'pick' its records
      this.setValue(store.proxy.jsonReader.jsonData.filter, options);
    }
  }
});

/***/ }),
/* 1338 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterButton
 * @extends     Ext.Button
 * <p>Toggle Button to be used as filter</p>
 * @constructor
 */

Tine.widgets.grid.FilterButton = function (config) {
  config = config || {};
  Ext.apply(this, config);
  Tine.widgets.grid.FilterButton.superclass.constructor.call(this);
  Ext.applyIf(this, new Tine.widgets.grid.FilterPlugin());
};

Ext.extend(Tine.widgets.grid.FilterButton, Ext.Button, {
  /**
   * @cfg {String} field the filed to filter
   */
  field: null,

  /**
   * @cfg {String} operator operator of filter (defaults 'equals')
   */
  operator: 'equals',

  /**
   * @cfg {Bool} invert true if loging should be inverted (defaults false)
   */
  invert: false,

  /**
   * @private only toggle actions make sense as filters!
   */
  enableToggle: true,

  /**
   * @private
   */
  getValue: function getValue() {
    return {
      field: this.field,
      operator: this.operator,
      value: this.invert ? !this.pressed : this.pressed
    };
  },

  /**
   * @private
   */
  setValue: function setValue(filters) {
    for (var i = 0; i < filters.length; i++) {
      if (filters[i].field == this.field) {
        this.toggle(this.invert ? !filters[i].value : !!filters[i].value);
        break;
      }
    }
  },

  /**
   * @private
   */
  handler: function handler() {
    this.onFilterChange();
  }
});
Ext.reg('wdgt.filterbutton', Tine.widgets.grid.FilterButton);

/***/ }),
/* 1339 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _Model_ImportExportDefinition__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(631);
/* harmony import */ var _Model_ImportExportDefinition__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_Model_ImportExportDefinition__WEBPACK_IMPORTED_MODULE_0__);
/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');

/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.ExportButton
 * @extends     Ext.Button
 * <p>export button</p>
 * @constructor
 */

Tine.widgets.grid.ExportButton = function (config) {
  config = config || {};
  Ext.apply(this, config);
  config.handler = this.doExport.createDelegate(this);
  Tine.widgets.grid.ExportButton.superclass.constructor.call(this, config);
};

Ext.extend(Tine.widgets.grid.ExportButton, Ext.Action, {
  /**
   * @cfg {Tine.Tinebase.data.Record} recordClass
   */
  recordClass: null,

  /**
   * @cfg {Function} getExportOptions
   */
  getExportOptions: null,

  /**
   * @cfg {String} icon class
   */
  iconCls: 'action_export',

  /**
   * @cfg {String} format of export (default: csv)
   */
  format: 'csv',

  /**
   * @cfg {String} definitionId
   */
  definitionId: null,

  /**
   * @cfg {String} export function (for example: Timetracker.exportTimesheets)
   */
  exportFunction: null,

  /**
   * @cfg {Tine.widgets.grid.FilterSelectionModel} sm
   */
  sm: null,

  /**
   * @cfg {Tine.widgets.grid.GridPanel} gridPanel
   * use this alternativly to sm
   */
  gridPanel: null,

  /**
   * @cfg {Boolean} showExportDialog
   */
  showExportDialog: false,

  /**
   * add sub menu with attached/related templates
   *
   * @param action
   * @param grants
   * @param records
   * @param isFilterSelect
   */
  actionUpdater: function actionUpdater(action, grants, records, isFilterSelect) {
    var _ = window.lodash,
        favorite = _.get(action, 'initialConfig.definition.favorite'),
        scope = _.get(action, 'initialConfig.definition.scope'),
        format = _.get(action, 'initialConfig.definition.format'),
        handler = _.get(action, 'initialConfig.handler');

    if (_.isFunction(handler) && favorite == '1' && records.length == 1) {
      var record = records[0],
          attachments = _.get(record, 'data.attachments', []),
          relations = _.get(record, 'data.relations', []),
          relatedFiles = _.map(_.filter(relations, {
        related_model: 'Filemanager_Model_Node'
      }), 'related_record'),
          allFiles = _.concat(attachments, relatedFiles),
          menuItems = _.reduce(allFiles, function (result, file) {
        if (file && _.endsWith(file.name, format)) {
          result.push({
            text: file.name,
            handler: handler.createDelegate(action, [{
              template: file.id
            }])
          });
        }

        return result;
      }, []);

      if (menuItems.length) {
        _.each(action.items, function (item) {
          item.menu = new Ext.menu.Menu({
            items: menuItems
          });
        });
      }
    }
  },

  /**
   * do export
   */
  doExport: async function doExport(options) {
    var _ = window.lodash,
        appName,
        filter,
        model,
        count = 1; // options could be action (default handler signature)

    options = !options || options.el ? {} : options;

    if (this.gridPanel) {
      // get selection model
      if (!this.sm) {
        this.sm = this.gridPanel.grid.getSelectionModel();
      } // select all if nothing is selected


      if (this.sm.getCount() === 0) {
        this.sm.selectAll();
      }

      this.recordClass = this.recordClass || this.gridPanel.recordClass;
      filter = this.sm.getSelectionFilter();
      count = this.sm.getCount();
      options.sortInfo = this.gridPanel.getStore().sortInfo;
    }

    if (_.isFunction(this.getExportOptions)) {
      _.assign(options, this.getExportOptions());
    }

    appName = this.recordClass.getMeta('appName');
    model = this.recordClass.getMeta('phpClassName');
    this.exportFunction = this.exportFunction || appName + '.export' + this.recordClass.getMeta('modelName') + 's';
    var exportJob = new Tine.Tinebase.Model.ExportJob({
      scope: this.exportScope,
      filter: filter,
      format: this.format,
      exportFunction: this.exportFunction,
      count: count,
      definitionId: this.definitionId,
      recordsName: this.recordClass.getRecordsName(),
      model: model,
      options: options
    });
    let optionsMissing = false;

    if (this.definitionId) {
      const definition = Tine.Tinebase.Model.ImportExportDefinition.get(appName, this.definitionId);
      optionsMissing = definition.optionsMissing(options);
    }

    if (this.showExportDialog || Ext.EventObject.altKey === true || optionsMissing) {
      Tine.widgets.dialog.ExportDialog.openWindow({
        appName: appName,
        record: exportJob
      });
    } else {
      Tine.widgets.exportAction.downloadExport(exportJob);
    }
  }
});

/***/ }),
/* 1340 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine', 'Tine.widgets', 'Tine.widgets.exportAction');
Tine.widgets.exportAction.SCOPE_SINGLE = 'single';
Tine.widgets.exportAction.SCOPE_MULTI = 'multi';
Tine.widgets.exportAction.SCOPE_HIDDEN = 'hidden';
Tine.widgets.exportAction.SCOPE_REPORT = 'report';
/**
 * get all (favorite) export definitions for given model
 *
 * @param {Tine.Tinebase.data.Record} recordClass
 * @param {Boolean} favorites
 * @param {String} scope
 * @return {Collection} exportDefinitionsData
 */

Tine.widgets.exportAction.getExports = function (recordClass, favorites, scope) {
  var _ = window.lodash,
      appName = recordClass.getMeta('appName'),
      phpClassName = recordClass.getMeta('phpClassName'),
      app = Tine.Tinebase.appMgr.get(appName),
      allExportDefinitions = _.get(app.getRegistry().get('exportDefinitions'), 'results', []),
      exportDefinitions = _.filter(allExportDefinitions, {
    model: phpClassName
  });

  if (_.isBoolean(favorites)) {
    exportDefinitions = _.filter(exportDefinitions, function (d) {
      if (favorites) {
        return d.favorite === true;
      } else {
        return d.favorite === false || d.favorite === null;
      }
    });
  }

  if (_.isString(scope)) {
    exportDefinitions = _.filter(exportDefinitions, function (d) {
      let definedScope = d.scope === Tine.widgets.exportAction.SCOPE_REPORT ? Tine.widgets.exportAction.SCOPE_MULTI : d.scope;

      if (definedScope === Tine.widgets.exportAction.SCOPE_HIDDEN) {
        return false;
      }

      return !definedScope || definedScope === scope;
    });
  }

  return _.sortBy(exportDefinitions, 'order');
};

Tine.widgets.exportAction.getExportMenuItems = function (recordClass, exportConfig, scope) {
  var _ = window.lodash,
      appName = recordClass.getMeta('appName'),
      app = Tine.Tinebase.appMgr.get(appName),
      exportDefinitions = Tine.widgets.exportAction.getExports(recordClass, true, scope);
  return _.reduce(exportDefinitions, function (items, definition) {
    items.push(new Tine.widgets.grid.ExportButton(_.assign({
      exportScope: scope,
      recordClass: recordClass,
      definition: definition,
      text: app.i18n._hidden(definition.label ? definition.label : definition.name),
      format: '',
      definitionId: definition.id,
      iconCls: definition.icon_class,
      order: definition.order
    }, exportConfig)));
    return items;
  }, []);
};

Tine.widgets.exportAction.getExportButton = function (recordClass, exportConfig, scope, additionalItems) {
  if (!recordClass || !Tine.Tinebase.appMgr.isEnabled(recordClass.getMeta('appName'))) return;
  var _ = window.lodash,
      appName = recordClass.getMeta('appName'),
      recordName = recordClass.getRecordName(),
      recordsName = recordClass.getRecordsName(),
      exportFunction = appName + '.export' + recordClass.getMeta('modelName') + 's',
      allItems = Tine.widgets.exportAction.getExports(recordClass, null, scope),
      menuItems = Tine.widgets.exportAction.getExportMenuItems(recordClass, exportConfig, scope);

  if (allItems.length) {
    menuItems.push(new Tine.widgets.grid.ExportButton(_.assign({
      exportScope: scope,
      recordClass: recordClass,
      text: i18n._('Export as ...'),
      iconCls: 'action_export',
      showExportDialog: true,
      exportFunction: exportFunction,
      order: 1000
    }, exportConfig)));
  }

  menuItems = menuItems.concat(additionalItems || []);
  return menuItems.length ? new Ext.Action({
    requiredGrant: 'exportGrant',
    text: String.format(i18n.ngettext('Export {0}', 'Export {0}', 50), recordsName),
    singularText: String.format(i18n.ngettext('Export {0}', 'Export {0}', 1), recordName),
    pluralText: String.format(i18n.ngettext('Export {0}', 'Export {0}', 1), recordsName),
    translationObject: i18n,
    iconCls: 'action_export',
    scope: this,
    disabled: false,
    allowMultiple: true,
    actionUpdater: this.updateAction,
    menu: {
      items: menuItems
    }
  }) : null;
};
/**
 * execute and download export
 *
 * @param {Tine.Tinebase.Model.ExportJob} exportJob
 */


Tine.widgets.exportAction.downloadExport = function (exportJob) {
  var _ = window.lodash,
      filter = exportJob.get('filter'),
      options = _.assign(exportJob.get('options'), {
    format: exportJob.get('format'),
    definitionId: exportJob.get('definitionId'),
    returnFileLocation: exportJob.get('returnFileLocation')
  });

  if (options.filter) {
    filter = options.filter;
    delete options.filter;
  }

  const params = {
    method: exportJob.get('exportFunction'),
    requestType: 'HTTP',
    filter: Ext.util.JSON.encode(filter),
    options: Ext.util.JSON.encode(options)
  };

  if (!options.returnFileLocation) {
    new Ext.ux.file.Download({
      params: params
    }).start();
  } else {
    return new Promise((resolve, reject) => {
      const connection = new Ext.data.Connection();
      connection.request({
        params: params,
        success: resolve,
        failure: reject,
        url: 'index.php',
        method: 'POST',
        timeout: 1800000 // 30 minutes - this might take a while

      });
    });
  }
}; // Don't use the generic action Updater if no records are selected


Tine.widgets.exportAction.updateAction = function (action, grants, records, isFilterSelect) {
  if (records.length != 0) {
    Tine.widgets.ActionUpdater.prototype.defaultUpdater(action, grants, records, isFilterSelect);
  }
};

/***/ }),
/* 1341 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine', 'Tine.widgets', 'Tine.widgets.importAction');
Tine.widgets.importAction.SCOPE_SINGLE = 'single';
Tine.widgets.importAction.SCOPE_MULTI = 'multi';
Tine.widgets.importAction.SCOPE_HIDDEN = 'hidden';
/**
 * get all (favorite) import definitions for given model
 *
 * @param {Tine.Tinebase.data.Record} recordClass
 * @param {Object} importConfig
 */

Tine.widgets.importAction.getImports = function (recordClass, favorites, scope) {
  var _ = window.lodash,
      appName = recordClass.getMeta('appName'),
      phpClassName = recordClass.getMeta('phpClassName'),
      app = Tine.Tinebase.appMgr.get(appName),
      allImportDefinitions = _.get(app.getRegistry().get('importDefinitions'), 'results', []),
      importDefinitions = _.filter(allImportDefinitions, {
    model: phpClassName
  });

  if (_.isBoolean(favorites)) {
    importDefinitions = _.filter(importDefinitions, function (d) {
      if (favorites) {
        return d.favorite === '1';
      } else {
        return d.favorite === '0' || d.favorite === null;
      }
    });
  }

  if (_.isString(scope)) {
    importDefinitions = _.filter(importDefinitions, function (d) {
      return Tine.widgets.importAction.SCOPE_HIDDEN !== d.scope && (d.scope === null || d.scope == "" || d.scope == scope);
    });
  }

  return _.sortBy(importDefinitions, 'order');
};

/***/ }),
/* 1342 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterToolbar
 * @extends     Ext.Panel
 * 
 * <br>Usage:<br>
     <pre><code>
     tb = new Tine.widgets.grid.FilterToolbar({
         filterModels: [
            {label: 'Full Name', field: 'n_fn', defaultOperator: 'contains'},
            {label: 'Container', field: 'container_id', operatorRenderer: function() {...}, valueRenderer: function() {...}},
            {label: 'Contact', field: 'quicksearch'}
         ],
         defaultFilter: 'quicksearch',
         filters: [
            {field: 'n_fn', operator: 'contains', value: 'Smith'},
            {field: 'container_id', operator: 'equals', value: 4}
        ]
     });
    </code></pre>
 * @constructor
 * @param {Object} config
 */

Tine.widgets.grid.FilterToolbar = function (config) {
  Ext.apply(this, config);
  Tine.widgets.grid.FilterToolbar.superclass.constructor.call(this); // become filterPlugin

  Ext.applyIf(this, new Tine.widgets.grid.FilterPlugin());
  this.childSheets = {};
};
/**
 * Filter registry
 * @type Object
 */


Tine.widgets.grid.FilterToolbar.FILTERS = {};
Ext.extend(Tine.widgets.grid.FilterToolbar, Ext.Panel, {
  /**
   * @cfg {Array} array of filter models (possible filters in this toolbar)
   */
  filterModels: null,

  /**
   * @cfg {String} fieldname of default filter
   */
  defaultFilter: null,

  /**
   * @cfg {Tine.Tinebase.data.Record} model this filter is for
   */
  recordClass: null,

  /**
   * @cfg {Bool} allowSaving (defaults to false)
   */
  allowSaving: false,

  /**
   * @cfg {Bool} neverAllowSaving (defaults to false)
   */
  neverAllowSaving: false,

  /**
   * @cfg {Bool} showSearchButton (defaults to true)
   */
  showSearchButton: true,

  /**
   * define if the filters should be sorted by the "sort" field.
   * 
   * @type {Boolean}
   */
  customFilterSorting: false,

  /**
   * @cfg {String} row prefix (defaults to i18n._('Show'))
   */
  rowPrefix: null,

  /**
   * @property childSheets
   * @type Object
   */
  childSheets: null,

  /**
   * @property isActive
   * @type Boolean
   */
  isActive: true,

  /**
   * does any of all of the filters match (or/and)
   * 
   * @type String
   */
  conjunctionOperator: 'and',
  // _('and')
  // _('or')
  header: false,
  border: false,
  monitorResize: true,
  region: 'north',
  layout: 'fit',
  canonicalName: 'FilterToolbar',
  //split: true,
  record: Ext.data.Record.create([{
    name: 'field'
  }, {
    name: 'operator'
  }, {
    name: 'value'
  }]),
  frowIdPrefix: 'tw-ftb-frowid-',

  /**
   * @private
   */
  initTemplates: function initTemplates() {
    var ts = this.templates || {};

    if (!ts.master) {
      ts.master = new Ext.Template('<div class="tw-filtertoolbar x-toolbar x-small-editor" hidefocus="true">', '<table style="width: auto;" border="0" cellpadding="0" cellspacing="0">', '{tbody}', '</table>', '</div>');
    }

    if (!ts.filterrow) {
      ts.filterrow = new Ext.Template('<tr id="{id}" class="fw-ftb-frow">', '<td class="tw-ftb-frow-pbutton"></td>', '<td class="tw-ftb-frow-mbutton"></td>', '<td class="tw-ftb-frow-prefix">{prefix}</td>', '<td class="tw-ftb-frow-field">{field}</td>', '<td class="tw-ftb-frow-operator">{operator}</td>', '<td class="tw-ftb-frow-value">{value}</td>', '<td class="tw-ftb-frow-searchbutton"></td>', //'<td class="tw-ftb-frow-deleteallfilters"></td>',
      //'<td class="tw-ftb-frow-savefilterbutton"></td>',
      '</tr>');
    }

    for (var k in ts) {
      var t = ts[k];

      if (t && typeof t.compile == 'function' && !t.compiled) {
        t.disableFormats = true;
        t.compile();
      }
    }

    this.templates = ts;
  },

  /**
   * @private
   */
  initActions: function initActions() {
    this.actions = {
      addFilterRow: new Ext.Button({
        //disabled: true,
        tooltip: i18n._('add new filter'),
        iconCls: 'action_addFilter',
        scope: this,
        handler: this.addFilter
      }),
      removeAllFilters: new Ext.Button({
        tooltip: i18n._('reset all filters'),
        iconCls: 'action_delAllFilter',
        scope: this,
        handler: this.deleteAllFilters
      }),
      startSearch: new Ext.Button({
        text: i18n._('start search'),
        iconCls: 'action_startFilter',
        scope: this,
        handler: function handler() {
          this.onFiltertrigger();
        }
      }),
      saveFilter: new Ext.Button({
        tooltip: i18n._('save as favorite'),
        iconCls: 'action_saveFilter',
        handler: this.onSaveFilter.createDelegate(this)
      })
    };
    this.action_loadFilter = new Ext.Action({
      text: i18n._('Load a favorite'),
      hidden: true,
      iconCls: 'action-tinebase-favorite',
      scope: this,
      handler: this.onLoadFilter
    });
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.grid.FilterToolbar.superclass.onRender.call(this, ct, position); // only get app and enable saving if this.store is available (that is not the case in the activities panel)
    // at this point the plugins are initialised

    if (!this.app && this.store) {
      this.app = Tine.Tinebase.appMgr.get(this.store.proxy.recordClass.getMeta('appName'));
    } // automatically enable saving


    if (!this.neverAllowSaving && this.app && this.app.getMainScreen() && typeof this.app.getMainScreen().getWestPanel == 'function' && this.app.getMainScreen().getWestPanel().hasFavoritesPanel) {
      this.allowSaving = true;
    } // render static table


    this.renderTable(); // render each filter row into table

    this.filterStore.each(function (filter) {
      this.renderFilterRow(filter);
    }, this); // render static action buttons

    for (var action in this.actions) {
      this.actions[action].hidden = true;
      this.actions[action].render(this.bwrap);
    } // wrap search button an set it always mouse-overed


    this.searchButtonWrap = this.actions.startSearch.getEl().wrap();
    this.searchButtonWrap.addClass('x-btn-over'); // arrange static action buttons

    this.onFilterRowsChange();

    if (!this.parentSheet) {
      this.tbar = new Ext.Toolbar({
        items: [],
        hidden: true
      });
      this.tbar.render(this.el, 0); //            // tab bar to start or filters
      //            this.tabBar = new Ext.Panel({
      //                cls: 'tw-ftb-criteria-tabs',
      //                border: false,
      //                height: Ext.isGecko ? 22 : 20,
      //                items: new Ext.TabPanel({
      //                    border: false,
      //                    plain: true,
      //                    activeItem: 1,
      //                    items: [{title: 'combination', html:''}, {title: 'criteria 1', html:''}, {title: 'criteria 2', html: ''}, {iconCls: 'action_add', title: '&nbsp;', html: ''}]
      //                })
      //            });
      //            this.tabBar.render(this.el, 0);
    }

    this.breadCrumb = new Ext.Action({
      text: (this.parentSheet ? '&gt;&nbsp;&nbsp;&nbsp;' : '') + this.title,
      scope: this,
      handler: function handler() {
        this.setActiveSheet(this);
      }
    });
  },
  generateTitle: function generateTitle() {
    var title = this.id;

    if (this.recordClass) {
      var app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName')),
          recordName = this.recordClass.getMeta('recordName'),
          recordsName = this.recordClass.getMeta('recordsName');
      title = app.i18n.n_hidden(recordName, recordsName, 50);
    }

    return title;
  },

  /**
   * is persiting this filterPanel is allowed
   * 
   * @return {Boolean}
   */
  isSaveAllowed: function isSaveAllowed() {
    return this.allowSaving;
  },

  /**
   * called when the title of this panel changes
   * 
   * @param {Ext.Panel} panel
   * @param {String} title
   */
  onTitleChange: function onTitleChange(panel, title) {
    if (this.breadCrumb) {
      this.breadCrumb.setText((this.parentSheet ? '&gt;&nbsp;&nbsp;&nbsp;' : '') + title);
    }
  },

  /**
   * save filterset as persisten filter
   */
  onSaveFilter: function onSaveFilter() {
    this.app.getMainScreen().getWestPanel().getFavoritesPanel().saveFilter();
  },
  onLoadFilter: function onLoadFilter() {
    Ext.Msg.alert('sorry', 'not yet implemented');
  },

  /**
   * renders static table
   * @private
   */
  renderTable: function renderTable() {
    var ts = this.templates;
    var tbody = '';
    this.filterStore.each(function (filter) {
      tbody += ts.filterrow.apply({
        id: this.frowIdPrefix + filter.id
      });
    }, this);
    this.tableEl = ts.master.overwrite(this.bwrap, {
      tbody: tbody
    }, true);
  },

  /**
   * renders the filter specific stuff of a single filter row
   * 
   * @param {Ext.data.Record} el representing a filter tr tag
   * @private
   */
  renderFilterRow: function renderFilterRow(filter) {
    filter.formFields = {};
    var filterModel = this.getFilterModel(filter);

    if (!filterModel) {
      Tine.log.warn('Tine.widgets.grid.FilterToolbar::renderFilterRow no filterModel found');
      Tine.log.warn(filter);
      this.filterStore.remove(filter);
      return;
    }

    var fRow = this.bwrap.child('tr[id=' + this.frowIdPrefix + filter.id + ']'); // field

    filter.formFields.field = new Ext.form.ComboBox({
      filter: filter,
      minListWidth: 240,
      // will be ignored if width is heigher
      resizable: true,
      // id: 'tw-ftb-frow-fieldcombo-' + filter.id,
      mode: 'local',
      lazyInit: false,
      emptyText: i18n._('select a field'),
      forceSelection: true,
      typeAhead: true,
      triggerAction: 'all',
      store: this.fieldStore,
      displayField: 'label',
      valueField: 'field',
      value: filterModel.field,
      renderTo: fRow.child('td[class=tw-ftb-frow-field]'),
      validator: this.validateFilter.createDelegate(this),
      tpl: '<tpl for="."><div class="x-combo-list-item tw-ftb-field-{field}">{label}</div></tpl>'
    });
    filter.formFields.field.setValue = filter.formFields.field.setValue.createInterceptor(function () {
      // NOTE: as this.fieldStore is a shared store we need to clear the filter before we use it,
      //       otherwise the record (e.g. query) might not be in the store
      this.fieldStore.clearFilter();
    }, this);
    filter.formFields.field.on('select', function (combo, newRecord, newKey) {
      if (combo.value != combo.filter.get('field')) {
        this.onFieldChange(combo.filter, combo.value);
      }
    }, this);
    filter.formFields.field.on('blur', function (combo) {
      if (combo.value != combo.filter.get('field')) {
        this.onFieldChange(combo.filter, combo.value);
      }
    }, this); // operator

    filter.formFields.operator = filterModel.operatorRenderer(filter, fRow.child('td[class^=tw-ftb-frow-operator]')); // value

    filter.formFields.value = filterModel.valueRenderer(filter, fRow.child('td[class^=tw-ftb-frow-value]'));
    filter.deleteRowButton = new Ext.Button({
      id: 'tw-ftb-frow-deletebutton-' + filter.id,
      tooltip: i18n._('Delete this filter'),
      filter: filter,
      iconCls: 'action_delThisFilter',
      renderTo: fRow.child('td[class=tw-ftb-frow-mbutton]'),
      scope: this,
      handler: function handler(button) {
        this.deleteFilter(button.filter);
      }
    });
  },

  /**
   * validate if type ahead is in our filter store
   * @return {Bool}
   */
  validateFilter: function validateFilter(value) {
    return this.fieldStore.query('label', value).getCount() != 0;
  },

  /**
   * @private
   */
  arrangeButtons: function arrangeButtons() {
    var numFilters = this.filterStore.getCount();

    if (numFilters == 0) {
      Tine.log.info('Tine.widgets.grid.FilterToolbar::arrangeButtons no filters found!');
      return;
    }

    var firstId = this.filterStore.getAt(0).id;
    var lastId = this.filterStore.getAt(numFilters - 1).id;
    this.filterStore.each(function (filter) {
      var tr = this.bwrap.child('tr[id=' + this.frowIdPrefix + filter.id + ']');

      if (tr) {
        tr.child('td[class=tw-ftb-frow-prefix]').dom.innerHTML = '<span style="width: 25px; display: inline-block">' + i18n._(this.conjunctionOperator) + '<span>';
      }

      if (filter.id == lastId) {
        if (tr) {
          // move add filter button
          tr.child('td[class=tw-ftb-frow-pbutton]').insertFirst(this.actions.addFilterRow.getEl());
          this.actions.addFilterRow.show(); // move start search button

          tr.child('td[class=tw-ftb-frow-searchbutton]').insertFirst(this.searchButtonWrap); // have save button for single rows

          if (numFilters === 1) {
            tr.child('td[class=tw-ftb-frow-searchbutton]').insertFirst(this.actions.saveFilter.getEl());
          }

          this.searchButtonWrap.applyStyles('float: left');
          this.actions.saveFilter.getEl().applyStyles('float: left');
        }

        if (this.showSearchButton) {
          this.actions.startSearch.show();
        } // move delete all filters


        this.actions.removeAllFilters.setVisible(numFilters > 1); // move save filter button

        this.actions.saveFilter.setVisible(this.allowSaving);
      }

      if (filter.id == firstId) {
        if (tr) {
          tr.child('td[class=tw-ftb-frow-prefix]').dom.innerHTML = this.rowPrefix;
        } // hack for the save/delete all btns which are now in the first row


        this.actions.removeAllFilters.getEl().applyStyles('float: left');

        if (tr) {
          if (numFilters > 1) {
            tr.child('td[class=tw-ftb-frow-searchbutton]').insertFirst(this.actions.saveFilter.getEl());
          }

          tr.child('td[class=tw-ftb-frow-searchbutton]').insertFirst(this.actions.removeAllFilters.getEl());
        }
      }
    }, this);
  },
  doLayout: function doLayout() {
    if (typeof this.layout.layout == 'function') {
      Tine.widgets.grid.FilterToolbar.superclass.doLayout.apply(this, arguments);
    }

    if (this.rendered) {
      this.arrangeButtons();
      this.fixWidths();
    }
  },
  fixWidths: function fixWidths() {
    var aw = this.getWidth() - 250,
        dim = {
      'tw-ftb-frow-field': Math.floor(aw * 0.45),
      'tw-ftb-frow-operator': Math.floor(aw * 0.17),
      'tw-ftb-frow-value': Math.floor(aw * 0.38)
    };

    for (var cls in dim) {
      this.el.select('.' + cls).setWidth(dim[cls]);
      this.el.select('.' + cls + ' div[class^=x-form-field-wrap] *').each(function (el) {
        var cmp = Ext.getCmp(el.id);

        if (cmp && !cmp.isInnerFTBCmp) {
          var width = dim[cls] + (cmp.FTBWidthCorrection || 0);

          if (cmp.wrap) {
            cmp.wrap.setWidth(width);
          }

          cmp.setWidth(width);
        }
      });
    }
  },

  /**
   * called  when a filter action is to be triggered (start new search)
   * @private
   */
  onFiltertrigger: function onFiltertrigger() {
    if (!this.supressEvents) {
      this.onFilterChange();
    }
  },

  /**
   * called on field change of a filter row
   * @private
   */
  onFieldChange: function onFieldChange(filter, newField) {
    var oldFilterModel = this.getFilterModel(filter),
        oldOperator = filter.formFields.operator.getValue(),
        oldValue = filter.formFields.value.getValue(); // only use old operator/value for textfields

    var f = filter.formFields.value;

    if (typeof f.selectText != 'function' || typeof f.doQuery == 'function') {
      oldValue = '';
    }

    if (oldFilterModel && Ext.isFunction(oldFilterModel.onDestroy)) {
      oldFilterModel.onDestroy(filter);
    } // NOTE: removeMode got introduced on ext3.1 but is not docuemented
    //       'childonly' is no ext mode, we just need something other than 'container'


    filter.formFields.operator.removeMode = 'childsonly';
    filter.formFields.value.removeMode = 'childsonly';
    filter.formFields.operator.destroy();
    delete filter.formFields.operator;
    filter.formFields.value.destroy();
    delete filter.formFields.value;
    var filterModel = this.getFilterModel(newField);
    var fRow = this.bwrap.child('tr[id=' + this.frowIdPrefix + filter.id + ']');
    var opEl = fRow.child('td[class^=tw-ftb-frow-operator]');
    var valEl = fRow.child('td[class^=tw-ftb-frow-value]');
    filter.set('field', newField);
    filter.set('operator', '');
    filter.set('value', '');
    filter.formFields.operator = filterModel.operatorRenderer(filter, opEl);
    filter.formFields.value = filterModel.valueRenderer(filter, valEl); // only use old operator/value for textfields

    var f = filter.formFields.value;

    if (oldValue && typeof f.selectText == 'function' && typeof f.doQuery != 'function') {
      var o = filter.formFields.operator;

      if (typeof o.findRecord == 'function') {
        if (typeof o.setValue == 'function' && o.findRecord(o.valueField, oldOperator)) {
          o.setValue(oldOperator);
        }
      }

      filter.formFields.value.setValue(oldValue);
      filter.formFields.value.selectText.defer(50, filter.formFields.value);
    }

    this.fixWidths();
  },

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.title = this.generateTitle();
    this.on('titlechange', this.onTitleChange, this);
    Tine.widgets.grid.FilterToolbar.superclass.initComponent.call(this);
    this.on('show', function () {
      this.doLayout();
    }, this);

    if (this.rowPrefix === null) {
      this.rowPrefix = i18n._('Show');
    }

    this.initTemplates();
    this.initActions(); // init filters

    this.filters = Ext.isArray(this.filters) ? this.filters : [];

    if (this.filters.length < 1) {
      this.filters = [{
        field: this.defaultFilter
      }];
    }

    this.filterStore = new Ext.data.JsonStore({
      fields: this.record,
      data: this.filters
    }); // init filter models

    this.filterModelMap = {};
    var filtersFields = [];

    if (this.recordClass && !this.filterModels) {
      // TODO: getFilterModel should not be used anymore. This should completely done by the registry.
      this.filterModels = Ext.isFunction(this.recordClass.getFilterModel) ? this.recordClass.getFilterModel() : [];
    }

    if (this.recordClass) {
      // concat registered filters
      this.filterModels = this.filterModels.concat(Tine.widgets.grid.FilterRegistry.get(this.recordClass)); // auto add foreign record filter on demand

      var foreignRecordFilter = this.createFilterModel({
        filtertype: 'foreignrecord',
        ownRecordClass: this.recordClass,
        isGeneric: true
      });

      if (foreignRecordFilter.operatorStore.getCount() > 0) {
        this.filterModels.push(foreignRecordFilter);
      } // auto add self id filter
      // add own record filter by default but ignore if set


      if (this.ownRecordFilter !== false) {
        this.ownRecordFilterModel = this.createFilterModel({
          filtertype: 'ownrecord',
          ownRecordClass: this.recordClass
        });
        this.filterModels.push(this.ownRecordFilterModel);
      }
    }

    for (var i = 0; i < this.filterModels.length; i++) {
      try {
        var config = this.filterModels[i],
            fm;

        if (config.valueType === 'fulltext' && !Tine.Tinebase.registry.get('fulltextAvailable')) {
          continue;
        }

        fm = this.createFilterModel(config);
      } catch (e) {
        Tine.log.error('Could not create filter model - skipping');
        Tine.log.error(e.stack ? e.stack : e);
        Tine.log.debug(config);
        continue;
      }

      this.filterModelMap[fm.field] = fm;
      filtersFields.push(fm);
      fm.on('filtertrigger', this.onFiltertrigger, this); // insert subfilters

      if (Ext.isFunction(fm.getSubFilters)) {
        Ext.each(fm.getSubFilters(), function (sfm) {
          sfm.superFilter = fm; // :<field> indicates a left hand filter

          sfm.field = ':' + sfm.field;
          this.filterModelMap[sfm.field] = sfm;
          filtersFields.push(sfm);
          sfm.on('filtertrigger', this.onFiltertrigger, this);
        }, this);
      }
    } // init filter selection


    this.fieldStore = new Ext.data.JsonStore({
      fields: this.customFilterSorting ? ['field', 'label', 'sort'] : ['field', 'label'],
      data: filtersFields,
      remoteSort: false,
      sortInfo: this.customFilterSorting ? {
        field: 'sort',
        direction: 'ASC'
      } : {
        field: 'label',
        direction: 'ASC'
      }
    });
  },

  /**
   * called when a filter row gets added/deleted
   * @private
   */
  onFilterRowsChange: function onFilterRowsChange() {
    if (!this.supressEvents && Ext.isFunction(this.ownerCt.layout.layout)) {
      this.ownerCt.layout.layout();
    }

    this.doLayout();
  },
  createFilterModel: function createFilterModel(config) {
    if (config && config.isFilterModel) {
      return config;
    } // push this filtertoolbar in config


    config.ftb = this;

    if (config.filtertype) {
      // filter from reg
      return new Tine.widgets.grid.FilterToolbar.FILTERS[config.filtertype](config);
    } else {
      return new Tine.widgets.grid.FilterModel(config);
    }
  },

  /**
   * returns filterModel
   * 
   * @param {String} fieldName
   * @return {Tine.widgets.grid.FilterModel}
   */
  getFilterModel: function getFilterModel(field) {
    var fieldName = Ext.isFunction(field.get) ? field.get('field') : field;

    if (!fieldName && field.data && field.data.condition) {
      return this.ownRecordFilterModel;
    }

    if (!this.filterModelMap[fieldName]) {
      Tine.log.err('"' + fieldName + '" filter not defined in filter map');
    }

    return this.filterModelMap[fieldName];
  },

  /**
   * adds a new filter row
   */
  addFilter: function addFilter(filter) {
    if (!filter || arguments[1]) {
      filter = new this.record({
        field: this.defaultFilter
      });
    }

    this.filterStore.add(filter);

    if (this.bwrap) {
      var frow = this.templates.filterrow.append(this.bwrap.child('.tw-filtertoolbar table tbody'), {
        id: 'tw-ftb-frowid-' + filter.id
      }, true);
      this.renderFilterRow(filter);
    }

    this.onFilterRowsChange();
    return filter;
  },

  /**
   * resets a filter
   * @param {Ext.Record} filter to reset
   */
  resetFilter: function resetFilter(filter) {},

  /**
   * deletes a filter
   * @param {Ext.Record} filter to delete
   * @param {Boolean} supressDefault supress new default row
   */
  deleteFilter: function deleteFilter(filter, supressDefault) {
    var fRow = this.bwrap ? this.bwrap.child('tr[id=tw-ftb-frowid-' + filter.id + ']') : null; //var isLast = this.filterStore.getAt(this.filterStore.getCount()-1).id == filter.id;

    var isLast = this.filterStore.getCount() == 1,
        filterModel = this.getFilterModel(filter);
    this.filterStore.remove(this.filterStore.getById(filter.id));

    if (filter.formFields) {
      filter.formFields.field.destroy();
      filter.formFields.operator.destroy();
      filter.formFields.value.destroy();
    }

    if (filterModel && Ext.isFunction(filterModel.onDestroy)) {
      filterModel.onDestroy(filter);
    }

    if (isLast && !supressDefault && this.bwrap) {
      // add a new first row
      var firstFilter = this.addFilter(); // save buttons somewhere

      for (var action in this.actions) {
        this.actions[action].hide();
        this.bwrap.insertFirst(action == 'startSearch' ? this.searchButtonWrap : this.actions[action].getEl());
      }
    }

    if (fRow) {
      fRow.remove();
    }

    this.onFilterRowsChange();

    if (!this.supressEvents) {
      this.onFiltertrigger();
    }
  },

  /**
   * deletes all filters
   */
  deleteAllFilters: function deleteAllFilters() {
    this.supressEvents = true;
    this.filterStore.each(function (filter) {
      this.deleteFilter(filter);
    }, this);
    this.supressEvents = false;
    this.onFiltertrigger();
    this.onFilterRowsChange();
  },
  getValue: function getValue() {
    var filters = [];
    this.filterStore.each(function (filter) {
      var filterModel = this.getFilterModel(filter),
          line = Ext.isFunction(filterModel.getFilterData) ? filterModel.getFilterData(filter) : this.getFilterData(filter);

      if (line.field && Ext.isString(line.field) && line.field.match(/:/)) {
        var parts = line.field.split(':'); // customfield handling

        if (parts[0] == 'customfield') {
          filters.push({
            field: 'customfield',
            operator: line.operator,
            value: {
              cfId: parts[1],
              value: line.value
            }
          });
        } else if (filterModel && filterModel.superFilter) {
          // if we are a childfilter of a recordclass of the subfilter, just place the subfilter
          if (this.parentSheet && this.parentSheet.recordClass == filterModel.superFilter.foreignRecordClass) {
            filters.push(line);
            return;
          } // check if filter of type superfilter is present


          if (this.filterStore.find('field', filterModel.superFilter.field) < 0) {
            // create one
            // @TODO HIDE? -> see ForeignRecordFilter line ~300
            var superFilter = this.addFilter(new this.record({
              field: filterModel.superFilter.field,
              operator: 'definedBy'
            }));
            line = this.getFilterData(superFilter);
            filters.push(line);
          }
        }
      } else {
        if (!(line.operator === 'contains' && !line.value)) {
          filters.push(line);
        }
      }
    }, this);
    return filters;
  },

  /**
   * @static
   * @param {filterRecord} filter
   */
  getFilterData: function getFilterData(filter) {
    var line = {};

    for (var formfield in filter.formFields) {
      line[formfield] = filter.formFields[formfield].getValue();
    } // fill data with filter record data in case form field not exist (not rendered)


    filter.fields.each(function (field) {
      var name = field.name;

      if (!line.hasOwnProperty(name)) {
        line[name] = filter.get(name);
      }
    }, this); // append id

    line.id = filter.id;
    return line;
  },

  /**
   * set filterData in a filter
   * 
   * @static
   * @param {filterRecord} filter
   * @param {Object} filterData
   * @return {filterRecord}
   */
  setFilterData: function setFilterData(filter, filterData) {
    if (filter.formFields) {
      filter.beginEdit();
      Ext.each(['field', 'operator', 'value'], function (t) {
        filter.set(t, filterData[t]);

        if (Ext.isFunction(filter.formFields[t].setValue)) {
          filter.formFields[t].setValue(filterData[t]);
        }
      }, this);
      filter.endEdit();
    }

    return filter;
  },
  setValue: function setValue(filters) {
    if (!filters) {
      return;
    }

    this.supressEvents = true;
    var oldFilters = [];
    this.filterStore.each(function (filterRecord) {
      oldFilters.push(filterRecord);
    }, this);
    var filterModel, filterData, filterRecord; // custom fields handling

    for (var i = 0; i < filters.length; i++) {
      filterData = filters[i];

      if (filterData.value && filterData.value.cfId) {
        filters[i].field = filterData.field + ':' + filterData.value.cfId;
        filters[i].value = filterData.value.value;
      }
    }

    for (var i = 0; i < filters.length; i++) {
      filterRecord = null;
      filterData = filters[i];
      filterModel = filterData.condition ? this.ownRecordFilterModel : this.filterModelMap[filterData.field];

      if (!filterModel && String(filterData.field)[0] == ':') {
        // filter group got expanded by server (e.g. by implicit filter)
        filterData.field = filterData.field.replace(/^:/, '');
        filterModel = this.filterModelMap[filterData.field];
      }

      if (filterModel) {
        if (filterData.id) {
          filterRecord = this.filterStore.getById(filterData.id);
        } // refresh existing filters


        if (filterRecord) {
          Ext.isFunction(filterModel.setFilterData) ? filterModel.setFilterData(filterRecord, filterData) : this.setFilterData(filterRecord, filterData);
          oldFilters.remove(filterRecord);
        } // add non existing filters only if they where not created implicitly by server
        else if (!filterData.implicit) {
            // NOTE: don't use filterData.id here, it's a ext-comp-* which comes from a different session
            // and might be a totally different element yet.
            filterRecord = new this.record(filterData);
            this.addFilter(filterRecord);
          }
      }
    } // remove unused filters


    Ext.each(oldFilters, function (filterRecord) {
      this.deleteFilter(filterRecord);
    }, this); // add a default query filter if missing

    if (this.filterStore.find('field', 'query') < 0) {
      this.addFilter(new this.record({
        field: 'query'
      }));
    }

    this.supressEvents = false;
    this.onFilterRowsChange();
  },

  /**
   * gets filter data of all filter plugins
   * 
   * NOTE: As we can't find all filter plugins directly we need a litte hack 
   *       to get their data
   *       
   *       We register ourselve as latest beforeload.
   *       In the options.filter we have the filters then.
   */
  getAllFilterData: function getAllFilterData() {
    this.store.on('beforeload', this.storeOnBeforeload, this);
    this.store.load();
    this.store.un('beforeload', this.storeOnBeforeload, this);
    return this.allFilterData;
  },
  storeOnBeforeload: function storeOnBeforeload(store, options) {
    this.allFilterData = options.params.filter;
    this.store.fireEvent('exception');
    return false;
  },
  onDestroy: function onDestroy() {
    if (this.parentSheet) {
      this.parentSheet.removeFilterSheet(this);
    }
  },

  /***** sheets functions *****/
  addFilterSheet: function addFilterSheet(ftb) {
    ftb.ownerCt = this.ownerCt;
    ftb.parentSheet = this;
    this.childSheets[ftb.id] = ftb;
    ftb.onFilterChange = this.onFilterChange.createDelegate(this);
  },
  removeFilterSheet: function removeFilterSheet(ftb) {
    if (!this.childSheets[ftb.id].destroying) {
      this.childSheets[ftb.id].destroy();
    }

    delete this.childSheets[ftb.id];

    if (ftb == this.activeSheet) {
      this.setActiveSheet.defer(100, this, [this]);
    }
  },
  setActiveSheet: function setActiveSheet(sheet) {
    var ftb = Ext.isString(sheet) ? sheet = this.id ? this : this.childSheets[sheet] : sheet,
        rootSheet = this.getRootSheet(),
        parentSheets = sheet.getParentSheets();

    if (!ftb.rendered) {
      ftb.render(this.el);
    }

    this.bwrap[ftb == this ? 'show' : 'hide']();

    for (var ftbId in this.childSheets) {
      if (this.childSheets.hasOwnProperty(ftbId)) {
        if (ftb == this.childSheets[ftbId]) {
          this.childSheets[ftbId].show();
          this.childSheets[ftbId].setActiveSheet(sheet);
        } else {
          this.childSheets[ftbId].hide();
        }
      }
    } // show toolbar on demand


    if (ftb != rootSheet) {
      rootSheet.tbar.removeAll();
      Ext.each(parentSheets, function (sheet) {
        sheet.breadCrumb.enable();
        rootSheet.tbar.add(sheet.breadCrumb);
      }, this);
      ftb.breadCrumb.disable();
      rootSheet.tbar.add(ftb.breadCrumb, '->', ftb.action_loadFilter);
      rootSheet.tbar.show();
      rootSheet.tbar.doLayout();
    } else {
      rootSheet.tbar.hide();
    }

    this.activeSheet = ftb;
    this.onFilterRowsChange();
  },
  getParentSheets: function getParentSheets(parents) {
    parents = parents || [];

    if (this.parentSheet) {
      parents.unshift(this.parentSheet);
      return this.parentSheet.getParentSheets(parents);
    }

    return parents;
  },
  getRootSheet: function getRootSheet() {
    return this.parentSheet ? this.parentSheet.getRootSheet() : this;
  }
});
Ext.reg('tinewidgetsfiltertoolbar', Tine.widgets.grid.FilterToolbar);

/***/ }),
/* 1343 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
Tine.widgets.grid.FilterStructureTreePanel = Ext.extend(Ext.tree.TreePanel, {
  /**
   * @cfg {Tine.widgets.grid.FilterPanel} filterPanel
   */
  filterPanel: null,
  cls: 'tw-ftb-filterstructure-treepanel',
  autoScroll: true,
  border: false,
  useArrows: true,
  collapsible: true,
  collapsed: true,
  baseCls: 'ux-arrowcollapse',
  animCollapse: true,
  titleCollapse: true,
  rootVisible: false,
  //    draggable : true,
  //    rootVisible: false,
  initComponent: function initComponent() {
    this.title = ['<span ext:qtip="', Ext.util.Format.htmlEncode(i18n._('Show records that match to one of the following filters')), '">', Ext.util.Format.htmlEncode(i18n._('or alternatively')), '</span>'].join(''); //        this.tbar = [{
    //            text: '+',
    //            scope: this,
    //            handler: this.onAddFilterPanel
    //        }];

    this.root = {
      path: '/',
      //            iconCls: this.filterPanel.activeFilterPanel.app ? this.filterPanel.activeFilterPanel.app.getIconCls() : '',
      expanded: true,
      //            text: i18n._('or alternatively'),
      //            qtip: i18n._('Show records that match to one of the following filters'),
      children: [this.createNode(this.filterPanel.activeFilterPanel), {
        id: 'addFilterPanel',
        text: i18n._('Add alternative filter'),
        iconCls: 'action_add',
        leaf: true
      }]
    };
    this.contextMenu = new Ext.menu.Menu({
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-MainContextMenu'
      }],
      items: [{
        text: i18n._('Remove Filter'),
        iconCls: 'action_remove',
        scope: this,
        handler: this.onCtxRemove
      }]
    });
    this.on('click', this.onClick, this);
    this.on('beforeclick', this.onBeforeClick, this);
    this.on('contextmenu', this.onContextMenu, this);
    this.on('checkchange', this.onCheckChange, this);
    this.on('afterrender', this.onAfterRender, this);
    this.on('insert', this.onNodeInsert, this);
    this.on('textchange', this.onNodeTextChange, this);
    this.on('expandnode', this.filterPanel.manageHeight, this.filterPanel);
    this.on('collapsenode', this.filterPanel.manageHeight, this.filterPanel);
    this.on('collapse', this.filterPanel.manageHeight, this.filterPanel);
    this.on('expand', this.filterPanel.manageHeight, this.filterPanel);
    this.filterPanel.on('filterpaneladded', this.onFilterPanelAdded, this);
    this.filterPanel.on('filterpanelremoved', this.onFilterPanelRemoved, this);
    this.filterPanel.on('filterpanelactivate', this.onFilterPanelActivate, this);
    this.filterPanel.activeFilterPanel.on('titlechange', this.onFilterPanelTitleChange, this);
    this.editor = new Ext.tree.TreeEditor(this);
    this.editor.on('startedit', function (el, value) {
      this.editor.setValue(Ext.util.Format.htmlDecode(value));
    }, this);
    Tine.widgets.grid.FilterStructureTreePanel.superclass.initComponent.call(this);
  },
  onContextMenu: function onContextMenu(node, e) {
    e.stopEvent();

    if (this.getRootNode().childNodes.length > 2 && node.id != 'addFilterPanel') {
      this.contextMenu.contextNode = node;
      this.contextMenu.showAt(e.getXY());
    }
  },
  onCtxRemove: function onCtxRemove() {
    if (this.contextMenu.contextNode) {
      this.filterPanel.removeFilterPanel(this.contextMenu.contextNode.id);
    }
  },
  onAfterRender: function onAfterRender() {
    this.onFilterPanelActivate(this.filterPanel, this.filterPanel.activeFilterPanel); //        this.getRootNode().collapse();
  },

  /**
   * called when the text of a noded changed
   * 
   * @param {Ext.tree.TreeNode} node
   * @param {String} text
   * @param {String} oldText
   */
  onNodeTextChange: function onNodeTextChange(node, text, oldText) {
    if (node.attributes && node.attributes.filterPanel) {
      node.attributes.filterPanel.setTitle(Ext.util.Format.htmlEncode(text));
    }
  },

  /**
   * called when a node got inserted to this tree
   * 
   * @param {Ext.tree.TreePanel} tree
   * @param {Ext.tree.TreeNode} parent
   * @param {Ext.tree.TreeNode} node
   */
  onNodeInsert: function onNodeInsert(tree, parent, node) {
    var clickEl = Ext.EventObject.target ? Ext.EventObject.getTarget('.x-tree-node-el', 10) : null,
        isUserActionInsert = clickEl && Ext.fly(clickEl, '_treeEvents').getAttribute('tree-node-id', 'ext') == 'addFilterPanel' ? true : false,
        nodeCount = this.getRootNode().childNodes.length; // expand this panel if more than 2 childnodes (initial + add)

    if (nodeCount > 2 && this.collapsed) {
      this.expand();
    } // start editor for new node (if initialted by user)


    if (isUserActionInsert) {
      this.editor.triggerEdit.defer(100, this.editor, [node]);
    }
  },

  /**
   * called when a filterPanel gets added
   * 
   * @param {Tine.widgets.grid.filterPanel} filterToolbar
   * @param {Tine.widgets.grid.filterToolbar} filterPanel
   */
  onFilterPanelAdded: function onFilterPanelAdded(filterToolbar, filterPanel) {
    //        this.getRootNode().appendChild(this.createNode(filterPanel));
    //        var newNode = this.createNode(filterPanel);
    //        newNode
    this.getRootNode().insertBefore(this.createNode(filterPanel), this.getNodeById('addFilterPanel'));
    filterPanel.on('titlechange', this.onFilterPanelTitleChange, this);
  },

  /**
   * called when a filterPanel gets removed
   * 
   * @param {Tine.widgets.grid.filterPanel} filterToolbar
   * @param {Tine.widgets.grid.filterToolbar} filterPanel
   */
  onFilterPanelRemoved: function onFilterPanelRemoved(filterToolbar, filterPanel) {
    var node = this.getNodeById(filterPanel.id);
    delete node.filterPanel;

    if (node) {
      node.remove();
    }
  },

  /**
   * called when a filterPanel gets activated
   * 
   * @param {Tine.widgets.grid.filterPanel} filterToolbar
   * @param {Tine.widgets.grid.filterToolbar} filterPanel
   */
  onFilterPanelActivate: function onFilterPanelActivate(filterToolbar, filterPanel) {
    var node = this.getNodeById(filterPanel.id);

    if (this.getSelectionModel().isSelected(node)) {
      return;
    }

    if (node) {
      this.suspendEvents();
      node.select();
      this.resumeEvents();
    }
  },

  /**
   * called when a filterPanel title changed
   * 
   * @param {Tine.widgets.grid.filterToolbar} filterPanel
   * @param {String} text
   */
  onFilterPanelTitleChange: function onFilterPanelTitleChange(filterPanel, text) {
    var node = this.getNodeById(filterPanel.id);

    if (node) {
      this.suspendEvents();
      node.setText(text);
      this.resumeEvents();
    }
  },
  onBeforeClick: function onBeforeClick(node) {
    if (node.id == 'addFilterPanel') {
      this.onAddFilterPanel();
      return false;
    }
  },
  onAddFilterPanel: function onAddFilterPanel() {
    var filterPanel = this.filterPanel.addFilterPanel();
    this.filterPanel.setActiveFilterPanel(filterPanel);
  },
  onCheckChange: function onCheckChange(node, checked) {
    node.attributes.filterPanel.isActive = checked;
  },
  onClick: function onClick(node) {
    if (node.attributes && node.attributes.filterPanel) {
      this.filterPanel.setActiveFilterPanel(node.attributes.filterPanel);
    }
  },
  createNode: function createNode(filterPanel) {
    // mark filterPanel active
    filterPanel.isActive = true;
    return {
      checked: true,
      editable: true,
      id: filterPanel.id,
      filterPanel: filterPanel,
      leaf: true,
      text: filterPanel.title ? filterPanel.title : filterPanel.id,
      iconCls: filterPanel.app ? filterPanel.app.getIconCls() : 'leaf'
    };
  }
});

/***/ }),
/* 1344 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');

Tine.widgets.grid.FilterPanel = function (config) {
  this.filterToolbarConfig = config;
  Ext.copyTo(this, config, 'useQuickFilter,quickFilterConfig'); // the plugins won't work there

  delete this.filterToolbarConfig.plugins; // apply some filterPanel configs

  Ext.each(['onFilterChange', 'getAllFilterData'], function (p) {
    if (config.hasOwnProperty(p)) {
      this[p] = config[p];
    }
  }, this); // become filterPlugin

  Ext.applyIf(this, new Tine.widgets.grid.FilterPlugin());
  this.filterPanels = [];
  this.addEvents(
  /**
   * @event filterpaneladded
   * Fires when a filterPanel is added
   * @param {Tine.widgets.grid.FilterPanel} this
   * @param {Tine.widgets.grid.FilterToolbar} the filterPanel added
   */
  'filterpaneladded',
  /**
   * @event filterpanelremoved
   * Fires when a filterPanel is removed
   * @param {Tine.widgets.grid.FilterPanel} this
   * @param {Tine.widgets.grid.FilterToolbar} the filterPanel removed
   */
  'filterpanelremoved',
  /**
   * @event filterpanelactivate
   * Fires when a filterPanel is activated
   * @param {Tine.widgets.grid.FilterPanel} this
   * @param {Tine.widgets.grid.FilterToolbar} the filterPanel activated
   */
  'filterpanelactivate');
  Tine.widgets.grid.FilterPanel.superclass.constructor.call(this, {});
};

Ext.extend(Tine.widgets.grid.FilterPanel, Ext.Panel, {
  /**
   * @property activeFilterPanel
   * @type Tine.widgets.grid.FilterToolbar
   */
  activeFilterPanel: null,

  /**
   * @property filterPanels map filterPanelId => filterPanel
   * @type Object
   */
  filterPanels: null,

  /**
   * @property criteriaCount
   * @type Number
   */
  criteriaCount: 0,
  useQuickFilter: true,
  cls: 'tw-ftb-filterpanel',
  layout: 'border',
  border: false,

  /**
   * We expect the filter panel to be layouted
   */
  forceLayout: true,
  initComponent: function initComponent() {
    var filterPanel = this.addFilterPanel();
    this.filterModelMap = filterPanel.filterModelMap;
    this.activeFilterPanel = filterPanel; // this.initQuickFilterField();

    this.advancedSearchEnabled = Tine.Tinebase.featureEnabled('featureShowAdvancedSearch') && this.filterToolbarConfig.app.enableAdvancedSearch;
    this.recordClass = this.filterToolbarConfig.recordClass;
    this.items = [{
      region: 'east',
      width: 200,
      border: false,
      layout: 'fit',
      split: true,
      items: [new Tine.widgets.grid.FilterStructureTreePanel({
        filterPanel: this
      })]
    }, {
      region: 'center',
      border: false,
      layout: 'card',
      activeItem: 0,
      items: [filterPanel],
      autoScroll: false,
      listeners: {
        scope: this,
        afterlayout: this.manageHeight
      }
    }];
    Tine.widgets.grid.FilterPanel.superclass.initComponent.call(this);

    if (this.useQuickFilter) {
      this.quickFilterPlugin = new Tine.widgets.grid.FilterToolbarQuickFilterPlugin(Ext.apply({
        syncFields: false
      }, this.quickFilterConfig));
      this.quickFilterPlugin.init(this);
    }
  },

  /**
   * is persiting this filterPanel is allowed
   * 
   * @return {Boolean}
   */
  isSaveAllowed: function isSaveAllowed() {
    return this.activeFilterPanel.allowSaving;
  },
  getAllFilterData: Tine.widgets.grid.FilterToolbar.prototype.getAllFilterData,
  storeOnBeforeload: Tine.widgets.grid.FilterToolbar.prototype.storeOnBeforeload,
  onFilterRowsChange: function onFilterRowsChange() {
    this.activeFilterPanel.doLayout();
    this.manageHeight();
  },
  onFiltertrigger: function onFiltertrigger() {
    this.activeFilterPanel.onFiltertrigger();
  },
  manageHeight: function manageHeight() {
    if (this.rendered && this.activeFilterPanel.rendered) {
      var tbHeight = this.activeFilterPanel.getHeight(),
          northHeight = this.layout.north ? this.layout.north.panel.getHeight() + 1 : 0,
          eastHeight = this.layout.east && this.layout.east.panel.getEl().child('ul') ? this.layout.east.panel.getEl().child('ul').getHeight() + 29 : 0,
          height = Math.min(Math.max(eastHeight, tbHeight + northHeight), 120);
      this.setHeight(height); // manage scrolling

      if (this.layout.center && tbHeight > 120) {
        this.layout.center.panel.el.child('div[class^="x-panel-body"]', true).scrollTop = 1000000;
        this.layout.center.panel.el.child('div[class^="x-panel-body"]', false).applyStyles('overflow-y: auto');
      }

      if (this.layout.east && eastHeight > 120) {
        this.layout.east.panel.el.child('div[class^="x-panel-body"]', true).scrollTop = 1000000;
      }

      this.ownerCt.layout.layout();
    }
  },
  onAddFilterPanel: function onAddFilterPanel() {
    var filterPanel = this.addFilterPanel();
    this.setActiveFilterPanel(filterPanel);
  },
  addFilterPanel: function addFilterPanel(config) {
    config = config || {};
    var filterPanel = new Tine.widgets.grid.FilterToolbar(Ext.apply({}, this.filterToolbarConfig, config));
    filterPanel.onFilterChange = this.onFilterChange.createDelegate(this);
    this.filterPanels[filterPanel.id] = filterPanel;
    this.criteriaCount++;

    if (this.criteriaCount > 1 && filterPanel.title == filterPanel.generateTitle()) {
      filterPanel.setTitle(filterPanel.title + ' ' + this.criteriaCount);
    }

    this.fireEvent('filterpaneladded', this, filterPanel);
    return filterPanel;
  },

  /**
   * remove filter panel
   * 
   * @param {mixed} filterPanel
   */
  removeFilterPanel: function removeFilterPanel(filterPanel) {
    filterPanel = Ext.isString(filterPanel) ? this.filterPanels[filterPanel] : filterPanel;

    if (!this.filterPanels[filterPanel.id].destroying) {
      this.filterPanels[filterPanel.id].destroy();
    }

    delete this.filterPanels[filterPanel.id];
    this.criteriaCount--;
    this.fireEvent('filterpanelremoved', this, filterPanel);

    for (var id in this.filterPanels) {
      if (this.filterPanels.hasOwnProperty(id)) {
        return this.setActiveFilterPanel(this.filterPanels[id]);
      }
    }
  },
  setActiveFilterPanel: function setActiveFilterPanel(filterPanel) {
    filterPanel = Ext.isString(filterPanel) ? this.filterPanels[filterPanel] : filterPanel;
    this.activeFilterPanel = filterPanel;

    if (this.layout.center) {
      this.layout.center.panel.add(filterPanel);
      this.layout.center.panel.layout.setActiveItem(filterPanel.id);
    }

    filterPanel.doLayout();

    if (filterPanel.activeSheet) {
      // solve layout problems (#6332)
      filterPanel.setActiveSheet(filterPanel.activeSheet);
    }

    this.manageHeight.defer(100, this);
    this.fireEvent('filterpanelactivate', this, filterPanel);
  },
  getQuickFilterField: function getQuickFilterField() {
    return this.quickFilterPlugin.getQuickFilterField();
  },
  getQuickFilterPlugin: function getQuickFilterPlugin() {
    return this.quickFilterPlugin;
  },
  getValue: function getValue() {
    var filters = [];

    for (var id in this.filterPanels) {
      if (this.filterPanels.hasOwnProperty(id) && this.filterPanels[id].isActive) {
        filters.push({
          'condition': 'AND',
          'filters': this.filterPanels[id].getValue(),
          'id': id,
          label: Ext.util.Format.htmlDecode(this.filterPanels[id].title)
        });
      }
    } // NOTE: always trigger an OR condition, otherwise we could lose inactive FilterPanels


    return [{
      'condition': 'OR',
      'filters': filters,
      id: 'FilterPanel'
    }];
  },
  setValue: function setValue(value) {
    // save last filter ?
    var prefs;

    if ((prefs = this.filterToolbarConfig.app.getRegistry().get('preferences')) && prefs.get('defaultpersistentfilter') == '_lastusedfilter_') {
      var lastFilterStateName = this.filterToolbarConfig.recordClass.getMeta('appName') + '-' + this.filterToolbarConfig.recordClass.getMeta('recordName') + '-lastusedfilter';

      if (Ext.encode(Ext.state.Manager.get(lastFilterStateName)) != Ext.encode(value)) {
        Tine.log.debug('Tine.widgets.grid.FilterPanel::setValue save last used filter');
        Ext.state.Manager.set(lastFilterStateName, value);
      }
    } // NOTE: value is always an array representing a filterGroup with condition AND (server limitation)!
    //       so we need to route "alternate criterias" (OR on root level) through this filterGroup for transport
    //       and scrape them out here -> this also means we whipe all other root level filters (could only be implicit once)


    var alternateCriterias = false;
    Ext.each(value, function (filterData) {
      if (filterData.condition && filterData.condition == 'OR') {
        value = filterData.filters;
        alternateCriterias = true;
        return false;
      }
    }, this);

    if (!alternateCriterias) {
      // reset criterias
      this.activeFilterPanel.setTitle(this.activeFilterPanel.generateTitle());

      for (var id in this.filterPanels) {
        if (this.filterPanels.hasOwnProperty(id)) {
          if (this.filterPanels[id] != this.activeFilterPanel) {
            this.removeFilterPanel(this.filterPanels[id]);
          }
        }
      }

      this.activeFilterPanel.setValue(value);
    } // OR condition on root level
    else {
        var keepFilterPanels = [],
            activeFilterPanel = this.activeFilterPanel;
        Ext.each(value, function (filterData) {
          var filterPanel; // refresh existing filter panel

          if (filterData.id && this.filterPanels.hasOwnProperty(filterData.id)) {
            filterPanel = this.filterPanels[filterData.id];
          } // create new filterPanel
          else {
              // NOTE: don't use filterData.id here, it's a ext-comp-* which comes from a different session
              // and might be a totally different element yet.
              filterPanel = this.addFilterPanel();
              this.setActiveFilterPanel(filterPanel);
            }

          filterPanel.setValue(filterData.filters);
          keepFilterPanels.push(filterPanel.id);

          if (filterData.label) {
            filterPanel.setTitle(Ext.util.Format.htmlEncode(filterData.label));
          }
        }, this); // (re)activate filterPanel

        this.setActiveFilterPanel(keepFilterPanels.indexOf(activeFilterPanel.id) > 0 ? activeFilterPanel : keepFilterPanels[0]); // remove unused panels

        for (var id in this.filterPanels) {
          if (this.filterPanels.hasOwnProperty(id) && keepFilterPanels.indexOf(id) < 0 && this.filterPanels[id].isActive == true) {
            this.removeFilterPanel(id);
          }
        }
      }
  }
});

/***/ }),
/* 1345 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * TODO         container filter should extend this
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.PickerFilter
 * @extends     Tine.widgets.grid.FilterModel
 */

Tine.widgets.grid.PickerFilter = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @property Tine.Tinebase.Application app
   */
  app: null,

  /**
   * @cfg field
   * @type String
   */
  field: '',

  /**
   * @cfg defaultOperator
   * @type String
   */
  defaultOperator: 'in',

  /**
   * @cfg defaultValue
   * @type String
   */
  defaultValue: '',

  /**
   * @cfg label
   * @type String
   */
  label: '',

  /**
   * @cfg multiselectField
   */
  multiselectFieldConfig: null,

  /**
   * record picker
   * 
   * @type Tine.Tinebase.widgets.form.RecordPickerComboBox
   */
  picker: null,

  /**
   * record class
   * 
   * @type Tine.Tinebase.data.Record
   */
  recordClass: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.operators = this.operators || ['equals', 'not', 'in', 'notin']; // TODO invent a picker registry

    if (this.picker === null) {
      this.picker = this.recordClass == Tine.Addressbook.Model.Contact ? Tine.Addressbook.SearchCombo : Tine.Tinebase.widgets.form.RecordPickerComboBox;
    }

    this.multiselectFieldConfig = this.multiselectFieldConfig || {
      selectionWidget: new this.picker({
        app: this.app,
        recordClass: this.recordClass,
        blurOnSelect: true
      }),
      recordClass: this.recordClass,
      isSelectionVisible: function isSelectionVisible() {
        return this.selectionWidget.isExpanded();
      }
    };
    Tine.widgets.grid.PickerFilter.superclass.initComponent.call(this);
  },

  /**
   * called on operator change of a filter row
   * @private
   * 
   * TODO keep value widget if old operator / new operator use the same widget?
   */
  onOperatorChange: function onOperatorChange(filter, newOperator, keepValue) {
    var oldOperator = filter.formFields.operator.getValue(),
        oldValues = [].concat(filter.formFields.value.getValue()),
        oldValuesStore = filter.formFields.value.store,
        el = Ext.select('tr[id=' + this.ftb.frowIdPrefix + filter.id + '] td[class^=tw-ftb-frow-value]', this.ftb.el).first(); // make sure we have the old value record datas

    Ext.each(oldValues, function (value, idx) {
      try {
        if (Ext.isPrimitive(value)) {
          oldValues[idx] = oldValuesStore.getById(value).data;
        }
      } catch (e) {
        Tine.log.warn('Tine.widgets.grid.PickerFilter::onOperatorChange could not get record data');
      }
    }, this);
    Tine.widgets.grid.PickerFilter.superclass.onOperatorChange.apply(this, arguments); // NOTE: removeMode got introduced on ext3.1 but is not documented
    //       'childonly' is no ext mode, we just need something other than 'container'

    if (filter.formFields.value && Ext.isFunction(filter.formFields.value.destroy)) {
      filter.formFields.value.removeMode = 'childsonly';
      filter.formFields.value.destroy();
      delete filter.formFields.value;
    }

    filter.formFields.value = this.valueRenderer(filter, el); // retain value(s) on operator change (single -> multi, multi -> multi)

    if (['in', 'notin'].indexOf(newOperator) > -1) {
      filter.formFields.value.setValue(oldValues);
    }

    var width = filter.formFields.value.el.up('.tw-ftb-frow-value').getWidth() - 10;

    if (filter.formFields.value.wrap) {
      filter.formFields.value.wrap.setWidth(width);
    }

    filter.formFields.value.setWidth(width);
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    if (filter.formFields.value) {
      return filter.formFields.value;
    }

    var operator = filter.get('operator') ? filter.get('operator') : this.defaultOperator,
        value;
    Tine.log.debug('Tine.widgets.grid.PickerFilter::valueRenderer() - Creating new value field for ' + operator + ' operator.');

    switch (operator) {
      case 'contains':
        value = this.getClearableTextField(filter, el);
        break;

      case 'equals':
      case 'not':
        value = this.getPicker(filter, el);
        break;

      default:
        value = this.getPickerGridLayerCombo(filter, el);
    }

    value.on('specialkey', function (field, e) {
      if (e.getKey() == e.ENTER) {
        this.onFiltertrigger();
      }
    }, this);
    value.on('select', this.onFiltertrigger, this);
    return value;
  },
  getClearableTextField: function getClearableTextField(filter, el) {
    return new Ext.ux.form.ClearableTextField({
      filter: filter,
      renderTo: el,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      emptyText: this.emptyText,
      listeners: {
        scope: this,
        specialkey: function specialkey(field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        }
      }
    });
  },

  /**
   * get record picker
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   * 
   */
  getPicker: function getPicker(filter, el) {
    Tine.log.debug('Tine.widgets.grid.PickerFilter::getPicker()');
    var result = new this.picker({
      app: this.app,
      recordClass: this.recordClass,
      filter: filter,
      blurOnSelect: true,
      //            listWidth: 500,
      //            listAlign: 'tr-br',
      value: filter.data.value ? filter.data.value : this.defaultValue,
      renderTo: el
    });
    return result;
  },

  /**
   * get picker grid layer combo
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   * 
   */
  getPickerGridLayerCombo: function getPickerGridLayerCombo(filter, el) {
    return new Tine.widgets.grid.PickerFilterValueField(Ext.apply({
      app: this.app,
      filter: filter,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      renderTo: el
    }, this.multiselectFieldConfig));
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tinebase.pickerfilter'] = Tine.widgets.grid.PickerFilter;
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.PickerFilterValueField
 * @extends     Ext.ux.form.LayerCombo
 */

Tine.widgets.grid.PickerFilterValueField = Ext.extend(Ext.ux.form.LayerCombo, {
  layerHeight: 200,
  hideButtons: false,
  formConfig: {
    labelAlign: 'left',
    labelWidth: 30
  },
  labelField: 'name',
  recordClass: null,
  valueStore: null,
  selectionWidget: null,
  labelRenderer: Ext.emptyFn,

  /**
   * init
   */
  initComponent: function initComponent() {
    this.on('beforecollapse', this.onBeforeCollapse, this);

    if (!this.store) {
      this.store = new Ext.data.SimpleStore({
        fields: this.recordClass
      });
    }

    Tine.widgets.grid.PickerFilterValueField.superclass.initComponent.call(this);
  },

  /**
   * get form values
   * 
   * @return {Array}
   */
  getFormValue: function getFormValue() {
    var values = [];
    this.store.each(function (record) {
      values.push(record.data);
    }, this);
    return values;
  },

  /**
   * get items
   * 
   * @return {Array}
   */
  getItems: function getItems() {
    var me = this,
        items = [];
    this.initSelectionWidget();
    this.pickerGridPanel = new Tine.widgets.grid.PickerGridPanel({
      height: this.layerHeight || 'auto',
      recordClass: this.recordClass,
      store: this.store,
      autoExpandColumn: this.labelField,
      getColumnModel: this.getColumnModel.createDelegate(this),
      initActionsAndToolbars: function initActionsAndToolbars() {
        Tine.widgets.grid.PickerGridPanel.prototype.initActionsAndToolbars.call(this);
        this.tbar = new Ext.Toolbar({
          layout: 'fit',
          items: [me.selectionWidget]
        });
      }
    });
    items.push(this.pickerGridPanel);
    return items;
  },

  /**
   * init selection widget
   */
  initSelectionWidget: function initSelectionWidget() {
    this.selectionWidget.on('select', this.onRecordSelect, this);
  },

  /**
   * @return Ext.grid.ColumnModel
   */
  getColumnModel: function getColumnModel() {
    var labelColumn = {
      id: this.labelField,
      header: String.format(i18n._('Selected  {0}'), this.recordClass.getMeta('recordsName')),
      dataIndex: this.labelField
    };

    if (this.labelRenderer != Ext.emptyFn) {
      labelColumn.renderer = this.labelRenderer;
    }

    return new Ext.grid.ColumnModel({
      defaults: {
        sortable: false
      },
      columns: [labelColumn]
    });
  },

  /**
   * record select
   * 
   * @param {String} field
   * @param {Object} recordData
   */
  onRecordSelect: function onRecordSelect(field, recordData) {
    this.addRecord(recordData);
    this.selectionWidget.suspendEvents();
    this.selectionWidget.clearValue();
    this.selectionWidget.resumeEvents();
  },

  /**
   * adds record from selection widget to store
   * 
   * @param {Object} recordData
   */
  addRecord: function addRecord(recordData) {
    Tine.log.debug('Tine.widgets.grid.PickerFilterValueField::addRecord()');
    Tine.log.debug(recordData);
    var data = recordData.data ? recordData.data : recordData.attributes ? recordData.attributes : recordData;
    var existingRecord = this.store.getById(recordData.id);

    if (!existingRecord) {
      this.store.add(new this.recordClass(data));
    } else {
      var idx = this.store.indexOf(existingRecord);
      var row = this.pickerGridPanel.getView().getRow(idx);
      Ext.fly(row).highlight();
    }

    if (this.selectionWidget.selectPanel) {
      this.selectionWidget.selectPanel.close();
    }
  },

  /**
   * @param {String} value
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    value = Ext.isArray(value) ? value : [value];
    Tine.log.debug('Tine.widgets.grid.PickerFilterValueField::setValue()');
    Tine.log.debug(value);
    var recordText = [];
    this.currentValue = [];
    this.store.removeAll();
    var record, id, text;

    for (var i = 0; i < value.length; i++) {
      text = this.getRecordText(value[i]);

      if (text && text !== '') {
        recordText.push(text);
      }
    }

    this.setRawValue(recordText.join(', '));
    return this;
  },

  /**
   * get text from record defined by value (id or something else)
   * 
   * @param {String|Object} value
   * @return {String}
   */
  getRecordText: function getRecordText(value) {
    var id = Ext.isString(value) ? value : value.id,
        record = this.valueStore ? this.valueStore.getById(id) : !Ext.isString(value) ? new this.recordClass(value, id) : null;
    Tine.log.debug('Tine.widgets.grid.PickerFilterValueField::getRecordText()');
    Tine.log.debug(record);

    if (!record) {
      return '';
    } // always copy/clone record because it can't exist in 2 different stores


    this.store.add(record.copy());
    this.currentValue.push(record.id);
    var text = record.get(this.labelField);
    text = this.labelRenderer != Ext.emptyFn ? this.labelRenderer(text) : text;
    return text;
  },

  /**
   * cancel collapse if ctx menu or record selection is shown
   * 
   * @return Boolean
   */
  onBeforeCollapse: function onBeforeCollapse() {
    var result = true;

    if (this.pickerGridPanel) {
      var contextMenuVisible = this.pickerGridPanel.contextMenu && !this.pickerGridPanel.contextMenu.hidden,
          selectionVisible = this.isSelectionVisible();
      result = !(contextMenuVisible || selectionVisible);
    }

    Tine.log.debug('Tine.widgets.grid.PickerFilterValueField::onBeforeCollapse() - collapse: ' + result);
    return result;
  },

  /**
   * is selection visible ?
   * - overwrite this when extending to make sure that the selection widget is no longer visible on collapse
   * 
   * @return {Boolean}
   */
  isSelectionVisible: function isSelectionVisible() {
    return false;
  }
});

/***/ }),
/* 1346 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterToolbarQuickFilterPlugin
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * This plugin provides an external filter field (quickfilter) as a plugin of a filtertoolbar.
 * The filtertoolbar itself will be hidden no filter is set.
 * 
 * @example
 <pre><code>
    // init quickfilter as plugin of filtertoolbar
    this.quickSearchFilterToolbarPlugin = new Tine.widgets.grid.FilterToolbarQuickFilterPlugin();
    this.filterToolbar = new Tine.widgets.grid.FilterToolbar({
        filterModels: Tine.Addressbook.Model.Contact.getFilterModel(),
        defaultFilter: 'query',
        filters: [],
        plugins: [
            this.quickSearchFilterToolbarPlugin
        ]
    });
    
    // put quickfilterfield in a toolbar
    this.tbar = new Ext.Toolbar({
        '->',
        this.quickSearchFilterToolbarPlugin.getQuickFilterField()
    })
</code></pre>
 */

Tine.widgets.grid.FilterToolbarQuickFilterPlugin = function (config) {
  config = config || {};
  this.criteriaIgnores = config.criteriaIgnores || [{
    field: 'container_id',
    operator: 'equals',
    value: {
      path: '/'
    }
  }, {
    field: 'query',
    operator: 'contains',
    value: ''
  }];
  Ext.apply(this, config);
};

Tine.widgets.grid.FilterToolbarQuickFilterPlugin.prototype = {
  /**
   * @cfg {String} quickFilterField
   * 
   * name of quickfilter filed in filter definitions
   */
  quickFilterField: 'query',

  /**
   * filter toolbar we are plugin of
   * 
   * @type {Tine.widgets.grid.FilterToolbar} ftb
   */
  ftb: null,

  /**
   * external quick filter field
   * 
   * @type {Ext.ux.searchField} quickFilter
   */
  quickFilter: null,

  /**
   * filter row of filter toolbar where a quickfilter is set
   * 
   * @type {Ext.data.record}
   */
  quickFilterRow: null,

  /**
   * @cfg {Array} criterias to ignore
   */
  criteriaIgnores: null,

  /**
   * @cfg {Bool} syncFields
   * sync with filtertoolbar
   */
  syncFields: true,

  /**
   * bind value field of this.quickFilterRow to sync process
   */
  bind: function bind() {
    this.quickFilterRow.formFields.value.on('keyup', this.syncField, this);
    this.quickFilterRow.formFields.value.on('change', this.syncField, this);
  },

  /**
   * gets the (extra) quick filter toolbar items
   * 
   * @return {Ext.ButtonGroup}
   */
  getQuickFilterField: function getQuickFilterField() {
    if (!this.quickFilterGroup) {
      this.quickFilterGroup = new Ext.ButtonGroup({
        columns: 1,
        items: [this.quickFilter, {
          xtype: 'toolbar',
          style: {
            border: 0,
            background: 'none'
          },
          items: [this.criteriaText, '->', this.detailsToggleBtn]
        }]
      });
    }

    return this.quickFilterGroup;
  },
  getQuickFilterPlugin: function getQuickFilterPlugin() {
    return this;
  },

  /**
   * gets the quick filter field from the filtertoolbar which is in sync with
   * the (extra) quick filter field. 
   */
  getQuickFilterRowField: function getQuickFilterRowField() {
    if (!this.quickFilterRow) {
      // NOTE: at this point there is no query filter in the filtertoolbar
      var filter = new this.ftb.record({
        field: this.quickFilterField,
        value: this.quickFilter.getValue()
      });
      this.ftb.addFilter(filter);
    }

    return this.quickFilterRow;
  },

  /**
   * called by filtertoolbar in plugin init process
   * 
   * @param {Tine.widgets.grid.FilterToolbar} ftb
   */
  init: function init(ftb) {
    this.ftb = ftb;

    if (this.syncFields) {
      this.ftb.renderFilterRow = this.ftb.renderFilterRow.createSequence(this.onAddFilter, this);
      this.ftb.onFieldChange = this.ftb.onFieldChange.createSequence(this.onFieldChange, this);
      this.ftb.deleteFilter = this.ftb.deleteFilter.createInterceptor(this.onBeforeDeleteFilter, this);
    }

    this.origGetValue = this.ftb.getValue;
    this.ftb.getValue = this.onGetValue.createDelegate(this);
    this.ftb.setValue = this.ftb.setValue.createSequence(this.onSetValue, this);
    this.ftb.onRender = this.ftb.onRender.createSequence(this.onRender, this); //this.ftb.onFilterRowsChange = this.ftb.onFilterRowsChange.createInterceptor(this.onFilterRowsChange, this);

    this.ftb.getQuickFilterField = this.getQuickFilterField.createDelegate(this);
    this.ftb.getQuickFilterPlugin = this.getQuickFilterPlugin.createDelegate(this);
    this.quickFilter = new Ext.ux.SearchField({
      width: 300,
      enableKeyEvents: true
    });
    this.quickFilter.onTrigger1Click = this.quickFilter.onTrigger1Click.createSequence(this.onQuickFilterClear, this);
    this.quickFilter.onTrigger2Click = this.quickFilter.onTrigger2Click.createSequence(this.onQuickFilterTrigger, this);

    if (this.syncFields) {
      this.quickFilter.on('keyup', this.syncField, this);
      this.quickFilter.on('change', this.syncField, this);
    }

    this.criteriaText = new Ext.Panel({
      border: 0,
      html: '',
      bodyStyle: {
        border: 0,
        background: 'none',
        'text-align': 'left',
        'line-height': '11px'
      }
    });
    var stateful = !!this.ftb.recordClass; // autogenerate stateId

    if (stateful) {
      var stateId = this.ftb.recordClass.getMeta('appName') + '-' + this.ftb.recordClass.getMeta('recordName') + '-FilterToolbar-QuickfilterPlugin';
    }

    this.detailsToggleBtn = new Ext.Button(Ext.apply({
      style: {
        'margin-top': '2px'
      },
      enableToggle: true,
      text: i18n._('show details'),
      tooltip: i18n._('Always show advanced filters'),
      scope: this,
      handler: this.onDetailsToggle,
      stateful: stateful,
      stateId: stateful ? stateId : null,
      getState: function getState() {
        return {
          detailsButtonPressed: this.pressed
        };
      },
      applyState: function applyState(state) {
        if (state.detailsButtonPressed) {
          this.setText(i18n._('hide details'));
          this.toggle(state.detailsButtonPressed);
        }
      },
      stateEvents: ['toggle'],
      listeners: {
        scope: this,
        render: function render() {
          // limit width of this.criteriaText
          this.criteriaText.setWidth(this.quickFilterGroup.getWidth() - this.detailsToggleBtn.getWidth());
        }
      }
    }, this.detailsToggleBtnConfig));
    this.ftb.hide();
  },

  /**
   * called when a filter is added to the filtertoolbar
   * 
   * @param {Ext.data.Record} filter
   */
  onAddFilter: function onAddFilter(filter) {
    if (filter.get('field') == this.quickFilterField && !this.quickFilterRow) {
      this.quickFilterRow = filter;
      this.bind(); // preset quickFilter with filterrow value

      this.syncField(filter.formFields.value);
    }
  },

  /**
   * called when the details toggle button gets toggled
   * 
   * @param {Ext.Button} btn
   */
  onDetailsToggle: function onDetailsToggle(btn) {
    btn.setText(btn.pressed ? i18n._('hide details') : i18n._('show details'));
    this.ftb[btn.pressed ? 'show' : 'hide'](); // cares for resizing

    this.ftb.onFilterRowsChange();
  },

  /**
   * called when a filter field of the filtertoolbar changes
   */
  onFieldChange: function onFieldChange(filter, newField) {
    if (filter == this.quickFilterRow) {
      this.onBeforeDeleteFilter(filter);
    }

    if (newField == this.quickFilterField) {
      this.onAddFilter(filter);
    }
  },

  /**
   * called when the filterrows of the filtertoolbar changes
   * 
   * we detect the hidestatus of the filtertoolbar
   *
  onFilterRowsChange: function() {
      this.ftb.searchButtonWrap.removeClass('x-btn-over');
      
      if (this.ftb.filterStore.getCount() <= 1 
          && this.ftb.filterStore.getAt(0).get('field') == this.quickFilterField
          && !this.ftb.filterStore.getAt(0).formFields.value.getValue()
          && !this.detailsToggleBtn.pressed) {
          
          this.ftb.hide();
      } else {
          this.ftb.show();
      }
  },
  */

  /**
   * called before a filter row is deleted from filtertoolbar
   * 
   * @param {Ext.data.Record} filter
   */
  onBeforeDeleteFilter: function onBeforeDeleteFilter(filter) {
    if (filter == this.quickFilterRow) {
      this.quickFilter.setValue('');
      this.unbind();
      delete this.quickFilterRow; // look for an other quickfilterrow

      this.ftb.filterStore.each(function (f) {
        if (f != filter && f.get('field') == this.quickFilterField) {
          this.onAddFilter(f);
          return false;
        }
      }, this);
    }
  },

  /**
   * called when the (external) quick filter is cleared
   */
  onQuickFilterClear: function onQuickFilterClear() {
    if (this.syncFields) {
      this.ftb.deleteFilter(this.quickFilterRow);
    }

    this.quickFilter.reset();
    this.onQuickFilterTrigger();
  },

  /**
   * called when the (external) filter triggers filter action
   */
  onQuickFilterTrigger: function onQuickFilterTrigger() {
    this.ftb.onFiltertrigger.call(this.ftb);
    this.ftb.onFilterRowsChange.call(this.ftb);
  },

  /**
   * called after onRender is called for the filter toolbar
   * 
   * @param {Array} filters
   */
  onRender: function onRender() {
    this.onDetailsToggle(this.detailsToggleBtn);
  },

  /**
   * called after setValue is called for the filter toolbar
   * 
   * @param {Array} filters
   */
  onSetValue: function onSetValue(filters) {
    var _ = window.lodash;
    this.setCriteriaText(filters);

    if (!this.syncFields) {
      this.quickFilter.setValue(_.get(_.find(filters, {
        field: this.quickFilterField
      }), 'value', ''));
    }
  },
  onGetValue: function onGetValue() {
    var value = this.origGetValue.call(this.ftb);

    if (!this.syncFields) {
      value.push({
        field: this.quickFilterField,
        operator: 'contains',
        value: this.quickFilter.getValue(),
        id: 'quickFilter'
      });
    }

    return value;
  },
  getCriteriasText: function getCriteriasText(filters) {
    var criterias = [];
    Ext.each(filters, function (f) {
      for (var i = 0, criteria, ignore; i < this.criteriaIgnores.length; i++) {
        criteria = this.criteriaIgnores[i];
        ignore = true;

        for (var p in criteria) {
          if (criteria.hasOwnProperty(p)) {
            if (Ext.isString(criteria[p]) || Ext.isEmpty(f[p])) {
              ignore &= f.hasOwnProperty(p) && f[p] === criteria[p];
            } else {
              for (var pp in criteria[p]) {
                if (criteria[p].hasOwnProperty(pp)) {
                  ignore &= f.hasOwnProperty(p) && typeof f[p].hasOwnProperty == 'function' && f[p].hasOwnProperty(pp) && f[p][pp] === criteria[p][pp];
                }
              }
            }
          }
        }

        if (ignore || f.id == 'quickFilter') {
          // don't judge them as criterias
          return;
        }
      }

      if (this.ftb.filterModelMap && this.ftb.filterModelMap[f.field]) {
        criterias.push(this.ftb.filterModelMap[f.field].label);
      } else if (f.condition == 'OR' || f.condition == 'AND') {
        criterias = criterias.concat(this.getCriteriasText(f.filters));
      }
    }, this);
    return criterias;
  },

  /**
   * sets this.criteriaText according to filters
   * 
   * @param {Array} filters
   */
  setCriteriaText: function setCriteriaText(filters) {
    var text = '',
        criterias = this.getCriteriasText(filters);

    if (!Ext.isEmpty(criterias)) {
      text = String.format(i18n.ngettext('Your view is limited by {0} criteria:', 'Your view is limited by {0} criterias:', criterias.length), criterias.length) + '<br />' + '&nbsp;' + criterias.join(', ');
    } // If toolbar is hidden, there is no component to update!


    if (this.criteriaText.getContentTarget()) {
      this.criteriaText.update(text);
    }
  },

  /**
   * syncs field contents of this.quickFilterRow and this.quickFilter
   * 
   * @param {Ext.EventObject} e
   * @param {Ext.form.Field} field
   */
  syncField: function syncField(field) {
    if (field == this.quickFilter) {
      this.getQuickFilterRowField().formFields.value.setValue(this.quickFilter.getValue());
    } else {
      this.quickFilter.setValue(this.quickFilterRow.formFields.value.getValue());
    }
  },

  /**
   * unbind value field of this.quickFilterRow from sync process
   */
  unbind: function unbind() {
    this.quickFilterRow.formFields.value.un('keyup', this.syncField, this);
    this.quickFilterRow.formFields.value.un('change', this.syncField, this);
  }
};

/***/ }),
/* 1347 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * a row selection model capable to return filters
 * @constructor
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterSelectionModel
 * @extends     Ext.grid.RowSelectionModel
 */

Tine.widgets.grid.FilterSelectionModel = Ext.extend(Ext.grid.RowSelectionModel, {
  /**
   * @cfg {Ext.data.Store}
   */
  store: null,

  /**
   * @cfg {Tine.widgets.grid.GridPanel}
   */
  gridPanel: null,

  /**
   * @property {Bool}
   */
  isFilterSelect: false,

  /**
   * Returns filterData representing current selection
   * 
   * @return {Array} filterData
   */
  getSelectionFilter: function getSelectionFilter() {
    if (!this.isFilterSelect) {
      var filter = this.getFilterOfRowSelection();
    } else {
      /* cruide hack lets save it as comment, maybe we need it some time ;-)
      var opts = {}
      for (var i=0; i<this.store.events.beforeload.listeners.length; i++) {
          if (this.store.events.beforeload.listeners[i].scope.xtype == 'filterplugin') {
              this.store.events.beforeload.listeners[i].fireFn.call(this.store.events.beforeload.listeners[i].scope, this.store, opts);
          }
      }
      //console.log(opts.params.filter);
      return opts.params.filter;
      */
      var filter = this.getAllFilterData();
    }

    return filter;
  },

  /**
   * get current selection as collection
   * 
   * @return {Ext.util.MixedCollection}
   */
  getSelectionsCollection: function getSelectionsCollection() {
    return this.selections;
  },

  /**
   * returns ids of currently visible page
   * 
   * @return {Array}
   */
  getCurrentPageIds: function getCurrentPageIds() {
    var ids = [];
    this.store.each(function (record) {
      ids.push(record.id);
    }, this);
    return ids;
  },

  /**
   * gets filter data of all filter plugins
   * 
   * NOTE: As we can't find all filter plugins directly we need a litte hack 
   *       to get their data
   *       
   *       We register ourselve as latest beforeload.
   *       In the options.filter we have the filters then.
   */
  getAllFilterData: function getAllFilterData() {
    this.store.on('beforeload', this.storeOnBeforeload, this);
    this.store.load();
    this.store.un('beforeload', this.storeOnBeforeload, this);
    return this.allFilterData;
  },
  storeOnBeforeload: function storeOnBeforeload(store, options) {
    this.allFilterData = options.params.filter;
    this.store.fireEvent('exception');
    return false;
  },

  /**
   * selects all rows 
   * @param {Bool} onlyPage select only rows from current page
   * @return {Void}
   */
  selectAll: function selectAll(onlyPage) {
    this.isFilterSelect = !onlyPage;
    Tine.widgets.grid.FilterSelectionModel.superclass.selectAll.call(this);
  },

  /**
   * @private
   */
  onRefresh: function onRefresh() {
    this.clearSelections(true);
    Tine.widgets.grid.FilterSelectionModel.superclass.onRefresh.call(this);
  },

  /**
   * @private
   */
  onRemove: function onRemove(v, index, r) {
    this.clearSelections(true);
    Tine.widgets.grid.FilterSelectionModel.superclass.onRemove.call(this, v, index, r);
  },

  /**
   * Deselects a row.
   * @param {Number} row The index of the row to deselect
   */
  deselectRow: function deselectRow(index, preventViewNotify) {
    this.isFilterSelect = false;
    Tine.widgets.grid.FilterSelectionModel.superclass.deselectRow.call(this, index, preventViewNotify);
  },

  /**
   * Clears all selections.
   */
  clearSelections: function clearSelections(silent) {
    this.suspendEvents();
    this.isFilterSelect = false;
    Tine.widgets.grid.FilterSelectionModel.superclass.clearSelections.call(this);
    this.resumeEvents();

    if (!silent) {
      this.fireEvent('selectionchange', this);
    }
  },

  /**
   * toggle selection
   */
  toggleSelection: function toggleSelection() {
    if (this.isFilterSelect) {
      this.clearSelections();
    } else {
      this.suspendEvents();
      var index;
      this.store.each(function (record) {
        index = this.store.indexOf(record);

        if (this.isSelected(index)) {
          this.deselectRow(index);
        } else {
          this.selectRow(index, true);
        }
      }, this);
      this.resumeEvents();
      this.fireEvent('selectionchange', this);
    }
  },

  /**
   * Returns number of selected rows
   * 
   * @return {Number}
   */
  getCount: function getCount() {
    if (!this.isFilterSelect) {
      return Tine.widgets.grid.FilterSelectionModel.superclass.getCount.call(this);
    } else {
      return this.store.getTotalCount();
    }
  },

  /**
   * converts a 'normal' row selection into a filter
   * 
   * @private
   * @return {Array} filterData
   */
  getFilterOfRowSelection: function getFilterOfRowSelection() {
    //var idProperty = this.store.fields.getMeta('idProperty');
    var idProperty = this.store.reader.meta.id;
    var ids = [];
    this.each(function (record) {
      ids.push(record.id);
    });
    return [{
      field: idProperty,
      operator: 'in',
      value: ids
    }];
  }
});

/***/ }),
/* 1348 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * Foreign Record Filter
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.ForeignRecordFilter
 * @extends     Tine.widgets.grid.FilterModel
 * 
 * <p>Filter for foreign records</p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 */

Tine.widgets.grid.ForeignRecordFilter = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @cfg {Application} app (required)
   */
  app: null,

  /**
   * @cfg {Record} ownRecordClass own record class for generic filter row
   */
  ownRecordClass: null,

  /**
   * @cfg {Record} foreignRecordClass needed for explicit defined filters
   */
  foreignRecordClass: null,

  /**
   * @cfg {String} foreignRefIdField optional, defaults to idProperty
   * might differ for foreignRecords (many to many relation) filter
   *  -> foreignRefId is not yet part of modelConfiguration :-(
   */
  foreignRefIdField: null,

  /**
   * @cfg {String} linkType {relation|foreignId} needed for explicit defined filters
   */
  linkType: 'relation',

  /**
   * @cfg {String} filterName server side filterGroup Name, needed for explicit defined filters
   */
  filterName: null,

  /**
   * @cfg {String} ownField for explicit filterRow
   */
  ownField: null,

  /**
   * @cfg {String} editDefinitionText untranslated edit definition button text
   */
  editDefinitionText: 'Edit definition',
  // i18n._('Edit definition')

  /**
   * @cfg {Object} optional picker config
   */
  pickerConfig: null,

  /**
   * @cfg {String} startDefinitionText untranslated start definition button text
   */
  startDefinitionText: 'Start definition',
  // i18n._('Start definition')

  /**
   * @property this filterModel is the generic 'related to' filterRow
   * @type Boolean
   */
  isGeneric: false,
  field: 'foreignRecord',

  /**
   * ignore this php models (filter is not shown)
   * @cfg {Array}
   */
  ignoreRelatedModels: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    if (this.ownRecordClass) {
      this.ownRecordClass = Tine.Tinebase.data.RecordMgr.get(this.ownRecordClass);
    }

    if (this.foreignRecordClass) {
      this.foreignRecordClass = Tine.Tinebase.data.RecordMgr.get(this.foreignRecordClass);
    } // TODO: remove this when files can be searched


    this.ignoreRelatedModels = this.ignoreRelatedModels ? this.ignoreRelatedModels.push('Filemanager_Model_Node') : ['Filemanager_Model_Node']; // TODO: remove this when ProductAggregates can be searched (or move this exception to Sales app)

    this.ignoreRelatedModels.push('Sales_Model_ProductAggregate');

    if (this.ownField) {
      this.field = this.ownField;
    }

    this['init' + (this.isGeneric ? 'Generic' : 'Explicit')]();
    Tine.widgets.grid.ForeignRecordFilter.superclass.initComponent.call(this);
  },

  /**
   * init the generic foreign filter row
   */
  initGeneric: function initGeneric() {
    this.label = i18n._('Related to');
    var operators = []; // linkType relations automatic list

    if (this.ownRecordClass.hasField('relations')) {
      var operators = [];
      Ext.each(Tine.widgets.relation.Manager.get(this.app, this.ownRecordClass, this.ignoreRelatedModels), function (relation) {
        if (Tine.Tinebase.common.hasRight('run', relation.relatedApp)) {
          // TODO: leave label as it is?
          var label = relation.text.replace(/ \(.+\)/, '');
          operators.push({
            operator: {
              linkType: 'relation',
              foreignRecordClass: Tine.Tinebase.data.RecordMgr.get(relation.relatedApp, relation.relatedModel)
            },
            label: label
          });
        }
      }, this);
    } // get operators from registry


    Ext.each(Tine.widgets.grid.ForeignRecordFilter.OperatorRegistry.get(this.ownRecordClass), function (def) {
      // translate label
      var foreignRecordClass = Tine.Tinebase.data.RecordMgr.get(def.foreignRecordClass),
          appName = foreignRecordClass.getMeta('appName'),
          app = Tine.Tinebase.appMgr.get(appName),
          label = app ? app.i18n._hidden(def.label) : def.label;
      operators.push({
        operator: {
          linkType: def.linkType,
          foreignRecordClass: foreignRecordClass,
          filterName: def.filterName
        },
        label: label
      });
    }, this); // we need this to detect operator changes

    Ext.each(operators, function (o) {
      o.toString = this.objectToString;
    }, this);
    this.operatorStore = new Ext.data.JsonStore({
      fields: ['operator', 'label'],
      data: operators
    });

    if (this.operatorStore.getCount() > 0) {
      this.defaultOperator = this.operatorStore.getAt(0).get('operator');
    }
  },

  /**
   * init an explicit filter row
   */
  initExplicit: function initExplicit() {
    this.foreignField = this.foreignRefIdField || this.foreignRecordClass.getMeta('idProperty');
    var foreignApp = Tine.Tinebase.appMgr.get(this.foreignRecordClass.getMeta('appName')),
        i18n;

    if (foreignApp) {
      i18n = foreignApp.i18n;
    } else {
      i18n = new Locale.Gettext();
      i18n.textdomain('Tinebase');
    }

    this.itemName = this.foreignRecordClass.getMeta('recordName');

    if (!this.label) {
      this.label = i18n.n_(this.foreignRecordClass.getMeta('recordName'), this.foreignRecordClass.getMeta('recordsName'), 1);
    } else {
      this.label = i18n._(this.label);
    }

    if (!this.operators) {
      this.operators = ['equals', 'not', 'in', 'notin', 'definedBy']; // allOf operator for records fields

      if (this.multipleForeignRecords || this.ownRecordClass && _.get(this.ownRecordClass.getModelConfiguration(), 'fields.' + this.ownField + '.type') === 'records') {
        this.operators.push('allOf');
      }
    } // get operators from registry


    if (this.ownRecordClass) {
      Ext.each(Tine.widgets.grid.ForeignRecordFilter.OperatorRegistry.get(this.ownRecordClass), function (def) {
        // translate label
        var foreignRecordClass = Tine.Tinebase.data.RecordMgr.get(def.foreignRecordClass),
            appName = foreignRecordClass.getMeta('appName'),
            app = Tine.Tinebase.appMgr.get(appName),
            label = app ? app.i18n._hidden(def.label) : def.label;

        if (foreignRecordClass == this.foreignRecordClass) {
          this.operators.push({
            operator: Ext.apply(def, {
              foreignRecordClass: foreignRecordClass
            }),
            label: label
          });
        }
      }, this);
    }

    if (!this.defaultOperator) {
      this.defaultOperator = 'equals';
    }
  },

  /**
   * onDefineRelatedRecord
   * 
   * @param {} filter
   */
  onDefineRelatedRecord: function onDefineRelatedRecord(filter) {
    Tine.log.debug('Tine.widgets.grid.ForeignRecordFilter::onDefineRelatedRecord() - filter:');
    Tine.log.debug(filter);

    if (!filter.toolbar) {
      this.createRelatedRecordToolbar(filter);
    }

    this.ftb.setActiveSheet(filter.toolbar);
    filter.formFields.value.setText(window.i18n._(this.editDefinitionText));
  },

  /**
   * get related record value data
   * 
   * NOTE: generic filters have their foreign record definition in the values
   */
  getRelatedRecordValue: function getRelatedRecordValue(filter) {
    var _ = window.lodash,
        me = this,
        filters = filter.toolbar ? filter.toolbar.getValue() : [],
        foreignRecordClass = filter.foreignRecordDefinition.foreignRecordClass,
        value;

    if (this.isGeneric) {
      value = {
        appName: foreignRecordClass.getMeta('appName'),
        modelName: foreignRecordClass.getMeta('modelName'),
        linkType: filter.foreignRecordDefinition.linkType,
        filterName: filter.foreignRecordDefinition.filterName,
        filters: filters
      };
    } else {
      value = filters;

      var operator = filter.get('operator') || filter.formFields.operator.origGetValue(),
          registeredOperator = _.get(_.find(this.operators, function (o) {
        return _.get(o, 'operator.filterName') == operator;
      }), 'operator', false);

      if (registeredOperator) {
        value.push({
          filterName: registeredOperator.filterName,
          field: ':' + registeredOperator.field,
          operator: registeredOperator.operator,
          value: filter.formFields.value.value
        });
      } else {
        // get value for idField if our own operator is not definedBy
        let [op, options] = me.parseOperator(filter.get('operator'));
        let opMap = {
          not: 'equals',
          // we auto switch definedBy to notDefinedBy for not filters
          notin: 'in',
          // we auto switch definedBy to notDefinedBy for notin filters
          allOf: 'in' // allOf is a setOperator

        };

        if (op != 'definedBy') {
          value.push({
            field: ':' + (me.foreignRefIdField || foreignRecordClass.getMeta('idProperty')),
            operator: opMap[op] || op,
            value: filter.formFields.value.value
          });
        } // get values of filters of our toolbar we are superfilter for (left hand stuff)


        this.ftb.filterStore.each(function (filter) {
          var filterModel = this.ftb.getFilterModel(filter);

          if (filterModel.superFilter && filterModel.superFilter == this) {
            var filterData = this.ftb.getFilterData(filter);
            value.push(filterData);
          }
        }, this);
      }
    }

    return value;
  },

  /**
   * set related record value data
   * @param {} filter
   */
  setRelatedRecordValue: function setRelatedRecordValue(filter) {
    var _ = window.lodash,
        me = this,
        value = filter.get('value'),
        operator = filter.get('operator') || filter.formFields.operator.origGetValue(),
        isRegisteredOperator = _.get(_.find(this.operators, function (o) {
      return _.get(o, 'operator.filterName') == operator;
    }), 'operator', false);

    if (isRegisteredOperator || ['equals', 'not', 'in', 'notin', 'allOf'].indexOf(operator) >= 0) {
      // NOTE: if setValue got called in the valueField internally, value is arguments[1] (createCallback)
      return filter.formFields.value.origSetValue(arguments.length ? arguments[1] : value);
    } // generic: choose right operator : appname -> generic filters have no subfilters an if one day, no left hand once!


    if (this.isGeneric) {
      // get operator
      this.operatorStore.each(function (r) {
        var operator = r.get('operator'),
            foreignRecordClass = operator.foreignRecordClass;

        if (foreignRecordClass.getMeta('appName') == value.appName && foreignRecordClass.getMeta('modelName') == value.modelName) {
          filter.formFields.operator.setValue(operator);
          filter.foreignRecordDefinition = operator;
          return false;
        }
      }, this); // set all content on childToolbar

      if (Ext.isObject(filter.foreignRecordDefinition) && value && Ext.isArray(value.filters) && value.filters.length) {
        if (!filter.toolbar) {
          this.createRelatedRecordToolbar(filter);
        }

        filter.toolbar.setValue(value.filters); // change button text

        if (filter.formFields.value && Ext.isFunction(filter.formFields.value.setText)) {
          filter.formFields.value.setText(window.i18n._(this.editDefinitionText));
        }
      }
    } else {
      if (!Ext.isArray(value)) return; // explicit chose right operator /equals / in /definedBy: left sided values create (multiple) subfilters in filterToolbar

      var foreignRecordDefinition = filter.foreignRecordDefinition,
          foreignRecordClass = foreignRecordDefinition.foreignRecordClass,
          foreignRecordIdProperty = me.foreignRefIdField || foreignRecordClass.getMeta('idProperty'),
          parentFilters = [];
      Ext.each(value, function (filterData, i) {
        if (!Ext.isString(filterData.field)) return;
        if (filterData.implicit) parentFilters.push(filterData);
        var parts = filterData.field.match(/^(:)?(.*)/),
            leftHand = !!parts[1],
            field = parts[2];

        if (leftHand) {
          // leftHand id property and registered operators are handled below
          if (field == foreignRecordIdProperty || filterData.filterName) {
            return;
          } // move filter to leftHand/parent filterToolbar


          if (this.ftb.getFilterModel(filterData.field)) {
            // ftb might have a record with this id
            // and we can't keep it yet
            delete filterData.id;
            this.ftb.addFilter(new this.ftb.record(filterData));
          }

          parentFilters.push(filterData);
        }
      }, this); // remove parent filters

      Ext.each(parentFilters, function (filterData) {
        value.remove(filterData);
      }, this); // if there where no remaining childfilters, hide this filterrow

      if (!value.length) {
        // prevent loop
        filter.set('value', '###NOT SET###');
        filter.set('value', '');
        filter.formFields.operator.setValue(this.defaultOperator);
        this.onOperatorChange(filter, this.defaultOperator, false); // if (not empty value through operator chage)

        Tine.log.info('hide row -> not yet implemented');
      } // a single id filter is always displayed in the parent Toolbar with our own filterRow
      else if (value.length == 1 && [foreignRecordIdProperty, ':' + foreignRecordIdProperty].indexOf(value[0].field) > -1) {
          let finalOp = value[0].operator; // switch back negations of notDefinedby operator

          let [op, options] = this.parseOperator(operator);

          if (op === 'notDefinedBy') {
            let opMap = {
              'equals': 'not',
              'in': 'notin'
            };
            finalOp = opMap[finalOp];
          }

          if (_.get(options, 'setOperator') === 'allOf') {
            finalOp = 'allOf';
          }

          filter.set('value', value[0].value);
          filter.formFields.operator.setValue(finalOp);
          this.onOperatorChange(filter, finalOp, true);
        } // a single registered filter is always displayed in the parent Toolbar with our own filterRow
        else if (value.length == 1 && (registeredOperator = _.get(_.find(this.operators, function (o) {
            return _.get(o, 'operator.filterName') == value[0].filterName;
          }), 'operator', false))) {
            filter.set('value', value[0].value);
            filter.formFields.operator.setValue(registeredOperator.filterName);
            this.onOperatorChange(filter, registeredOperator.filterName, true);
            filter.formFields.value.origSetValue(value[0].value);
          } // set remaining child filters
          else {
              if (!filter.toolbar) {
                this.createRelatedRecordToolbar(filter);
              }

              filter.toolbar.setValue(value);
              filter.formFields.operator.setValue('definedBy');
            }
    }
  },

  /**
   * create a related record toolbar
   */
  createRelatedRecordToolbar: function createRelatedRecordToolbar(filter) {
    Tine.log.debug('Tine.widgets.grid.ForeignRecordFilter::createRelatedRecordToolbar() - filter:');
    Tine.log.debug(filter);
    var foreignRecordDefinition = filter.foreignRecordDefinition,
        foreignRecordClass = foreignRecordDefinition.foreignRecordClass,
        filterModels = foreignRecordClass.getFilterModel(),
        ftb = this.ftb;

    if (!filter.toolbar) {
      // add our subfilters in this toolbar (right hand)
      if (Ext.isFunction(this.getSubFilters)) {
        filterModels = filterModels.concat(this.getSubFilters());
      }

      filter.toolbar = new Tine.widgets.grid.FilterToolbar({
        recordClass: foreignRecordClass,
        filterModels: filterModels,
        defaultFilter: foreignRecordClass.getMeta('defaultFilter') ? foreignRecordClass.getMeta('defaultFilter') : 'query'
      });
      ftb.addFilterSheet(filter.toolbar); // force rendering as we can't set values on non rendered toolbar atm.

      this.ftb.setActiveSheet(filter.toolbar);
      this.ftb.setActiveSheet(this.ftb);
    }
  },

  /**
   * operator renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  operatorRenderer: function operatorRenderer(filter, el) {
    var operator; // init operator value

    filter.set('operator', filter.get('operator') ? filter.get('operator') : this.defaultOperator);

    if (!this.isGeneric) {
      operator = Tine.widgets.grid.ForeignRecordFilter.superclass.operatorRenderer.apply(this, arguments);
      filter.foreignRecordDefinition = {
        linkType: this.linkType,
        foreignRecordClass: this.foreignRecordClass,
        filterName: this.filterName
      };
    } else {
      operator = new Ext.form.ComboBox({
        filter: filter,
        id: 'tw-ftb-frow-operatorcombo-' + filter.id,
        mode: 'local',
        lazyInit: false,
        emptyText: i18n._('select a operator'),
        forceSelection: true,
        typeAhead: true,
        triggerAction: 'all',
        store: this.operatorStore,
        displayField: 'label',
        valueField: 'operator',
        value: filter.get('operator'),
        renderTo: el
      });
      operator.on('select', function (combo, newRecord, newKey) {
        if (combo.value != combo.filter.get('operator')) {
          this.onOperatorChange(combo.filter, combo.value);
        }
      }, this); // init foreignRecordDefinition

      filter.foreignRecordDefinition = filter.get('operator');
    }

    operator.origGetValue = operator.getValue.createDelegate(operator);
    /**
     * get operator value
     *
     * NOTE: operator filed is composed of "<operator>[?<option1>=<value1>[&<optionN>=<valueN]]
     *     operator can be definedBy and notDefinedBy
     *     options (urlencoded) options
     *          condition: condition of the subfiltergroup (and or or)
     *          setOperator: result of subfilter must match oneOf or allOf our records
     *                      (allOf makes sense if our field is of type records (1:n n:m))
     *
     * NOTE: for historic reasons operator might be AND, which means definedBy?condition=and&setOperator=oneOf
     *
     * @return {string}
     */

    operator.getValue = function () {
      // auto switch operator for single line filters
      var op = operator.origGetValue(),
          opMap = {
        not: 'notDefinedBy?condition=and&setOperator=oneOf',
        notin: 'notDefinedBy?condition=and&setOperator=oneOf',
        allOf: 'definedBy?condition=and&setOperator=allOf'
      };
      return opMap[op] || 'definedBy?condition=and&setOperator=oneOf';
    };

    return operator;
  },
  parseOperator: function parseOperator(operator) {
    const parts = String(operator).split('?');
    return [parts[0], Ext.urlDecode(parts[1])];
  },

  /**
   * called on operator change of a filter row
   * @private
   */
  onOperatorChange: function onOperatorChange(filter, newOperator, keepValue) {
    if (this.isGeneric) {
      filter.foreignRecordDefinition = newOperator;
    }

    const oldOperator = filter.get('operator');

    if (oldOperator != newOperator) {
      if (filter.toolbar) {
        filter.toolbar.destroy();
        delete filter.toolbar;
      }
    }

    filter.set('operator', newOperator);

    if (['equals', 'not'].indexOf(oldOperator) > -1 && ['in', 'allOf', 'notin'].indexOf(newOperator) > -1) {
      filter.set('value', _.compact([filter.get('value')]));
    }

    if (!keepValue || [oldOperator, newOperator].indexOf('definedBy') > -1 || ['equals', 'not'].indexOf(newOperator) > -1 && ['in', 'allOf', 'notin'].indexOf(oldOperator) > -1) {
      filter.set('value', '');
    }

    var el = Ext.select('tr[id=' + this.ftb.frowIdPrefix + filter.id + '] td[class^=tw-ftb-frow-value]', this.ftb.el).first(); // NOTE: removeMode got introduced on ext3.1 but is not docuemented
    //       'childonly' is no ext mode, we just need something other than 'container'

    if (filter.formFields.value && Ext.isFunction(filter.formFields.value.destroy)) {
      filter.formFields.value.removeMode = 'childsonly';
      filter.formFields.value.destroy();
      delete filter.formFields.value;
    }

    filter.formFields.value = this.valueRenderer(filter, el);
    var width = filter.formFields.value.el.up('.tw-ftb-frow-value').getWidth() - 10;

    if (filter.formFields.value.wrap) {
      filter.formFields.value.wrap.setWidth(width);
    }

    filter.formFields.value.setWidth(width);
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    var _ = window.lodash,
        me = this,
        operator = filter.get('operator') ? filter.get('operator') : this.defaultOperator,
        value;

    switch (operator) {
      case 'equals':
      case 'not':
      case 'in':
      case 'notin':
      case 'allOf':
        //@TODO find it
        var pickerRecordClass = this.foreignRecordClass;

        if (this.foreignRefIdField) {
          // many 2 many relation
          var foreignRecordConfig = _.get(this.foreignRecordClass.getModelConfiguration(), 'fields.' + this.foreignRefIdField + '.config');

          pickerRecordClass = Tine.Tinebase.data.RecordMgr.get(foreignRecordConfig.appName, foreignRecordConfig.modelName);
        }

        value = Tine.widgets.form.RecordPickerManager.get(pickerRecordClass.getMeta('appName'), pickerRecordClass, Ext.apply({
          filter: filter,
          blurOnSelect: true,
          listWidth: 500,
          listAlign: 'tr-br',
          value: filter.data.value ? filter.data.value : this.defaultValue,
          renderTo: el,
          allowMultiple: ['in', 'notin', 'allOf'].indexOf(operator) > -1
        }, this.pickerConfig));
        value.on('specialkey', function (field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        }, this);
        value.origSetValue = value.setValue.createDelegate(value);
        break;

      default:
        var def = _.get(_.find(this.operators, function (o) {
          return _.get(o, 'operator.filterName') == operator;
        }), 'operator', {}),
            backup = _.reduce(_.keys(def), function (bkup, key) {
          return _.set(bkup, key, me[key]);
        }, {}),
            valueType = _.get(def, 'valueType'); // cope with operator registry values


        if (valueType) {
          _.assign(me, def);

          value = Tine.widgets.grid.FilterModel.prototype.valueRenderer.call(me, filter, el);

          _.assign(me, backup);

          value.origSetValue = value.setValue.createDelegate(value);
        } else {
          this.setRelatedRecordValue(filter);

          if (!filter.formFields.value) {
            value = new Ext.Button({
              text: i18n._(this.startDefinitionText),
              width: el.getWidth() - 10,
              filter: filter,
              renderTo: el,
              handler: this.onDefineRelatedRecord.createDelegate(this, [filter]),
              scope: this
            }); // show button

            el.addClass('x-btn-over'); // change text if setRelatedRecordValue had child filters

            if (filter.toolbar) {
              value.setText(window.i18n._(this.editDefinitionText));
            }
          } else {
            value = filter.formFields.value;
          }
        }

        break;
    }

    value.setValue = this.setRelatedRecordValue.createDelegate(this, [filter], 0);
    value.getValue = this.getRelatedRecordValue.createDelegate(this, [filter]);
    return value;
  },
  //    getSubFilters: function() {
  //        var filterConfigs = this.foreignRecordClass.getFilterModel();
  //        
  //        Ext.each(filterConfigs, function(config) {
  //            this.subFilterModels.push(Tine.widgets.grid.FilterToolbar.prototype.createFilterModel.call(this, config));
  //        }, this);
  //        
  //        return this.subFilterModels;
  //    },
  objectToString: function objectToString() {
    return Ext.encode(this);
  },
  onDestroy: function onDestroy(filterRecord) {
    if (filterRecord.toolbar) {
      this.ftb.removeFilterSheet(filterRecord.toolbar);
      delete filterRecord.toolbar;
    }
  }
});
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterRegistry
 * @singleton
 */

Tine.widgets.grid.ForeignRecordFilter.OperatorRegistry = function () {
  var operators = {};
  return {
    register: function register(appName, modelName, operator) {
      var key = appName + '.' + modelName;

      if (!operators[key]) {
        operators[key] = [];
      }

      operators[key].push(operator);
    },
    get: function get(appName, modelName) {
      if (Ext.isFunction(appName.getMeta)) {
        modelName = appName.getMeta('modelName');
        appName = appName.getMeta('appName');
      }

      var key = appName + '.' + modelName;
      return operators[key] || [];
    }
  };
}();

Tine.widgets.grid.FilterToolbar.FILTERS['foreignrecord'] = Tine.widgets.grid.ForeignRecordFilter;

/***/ }),
/* 1349 */
/***/ (function(module, exports) {

/*!
 * Ext JS Library 3.1.1
 * Copyright(c) 2006-2010 Ext JS, LLC
 * licensing@extjs.com
 * http://www.extjs.com/license
 */
Ext.ns('Ext.ux.grid');
/**
 * @class Ext.ux.grid.GroupSummary
 * @extends Ext.util.Observable
 * A GridPanel plugin that enables dynamic column calculations and a dynamically
 * updated grouped summary row.
 */

Ext.ux.grid.GroupSummary = Ext.extend(Ext.util.Observable, {
  /**
   * @cfg {Function} summaryRenderer Renderer example:<pre><code>
  summaryRenderer: function(v, params, data){
  return ((v === 0 || v > 1) ? '(' + v +' Tasks)' : '(1 Task)');
  },
   * </code></pre>
   */

  /**
   * @cfg {String} summaryType (Optional) The type of
   * calculation to be used for the column.  For options available see
   * {@link #Calculations}.
   */
  constructor: function constructor(config) {
    Ext.apply(this, config);
    Ext.ux.grid.GroupSummary.superclass.constructor.call(this);
  },
  init: function init(grid) {
    this.grid = grid;
    var v = this.view = grid.getView();
    v.doGroupEnd = this.doGroupEnd.createDelegate(this);
    v.afterMethod('onColumnWidthUpdated', this.doWidth, this);
    v.afterMethod('onAllColumnWidthsUpdated', this.doAllWidths, this);
    v.afterMethod('onColumnHiddenUpdated', this.doHidden, this);
    v.afterMethod('onUpdate', this.doUpdate, this);
    v.afterMethod('onRemove', this.doRemove, this);

    if (!this.rowTpl) {
      this.rowTpl = new Ext.Template('<div class="x-grid3-summary-row" style="{tstyle}">', '<table class="x-grid3-summary-table" border="0" cellspacing="0" cellpadding="0" style="{tstyle}">', '<tbody><tr>{cells}</tr></tbody>', '</table></div>');
      this.rowTpl.disableFormats = true;
    }

    this.rowTpl.compile();

    if (!this.cellTpl) {
      this.cellTpl = new Ext.Template('<td class="x-grid3-col x-grid3-cell x-grid3-td-{id} {css}" style="{style}">', '<div class="x-grid3-cell-inner x-grid3-col-{id}" unselectable="on">{value}</div>', "</td>");
      this.cellTpl.disableFormats = true;
    }

    this.cellTpl.compile();
  },

  /**
   * Toggle the display of the summary row on/off
   * @param {Boolean} visible <tt>true</tt> to show the summary, <tt>false</tt> to hide the summary.
   */
  toggleSummaries: function toggleSummaries(visible) {
    var el = this.grid.getGridEl();

    if (el) {
      if (visible === undefined) {
        visible = el.hasClass('x-grid-hide-summary');
      }

      el[visible ? 'removeClass' : 'addClass']('x-grid-hide-summary');
    }
  },
  renderSummary: function renderSummary(o, cs) {
    cs = cs || this.view.getColumnData();
    var cfg = this.grid.getColumnModel().config,
        buf = [],
        c,
        p = {},
        cf,
        last = cs.length - 1;

    for (var i = 0, len = cs.length; i < len; i++) {
      c = cs[i];
      cf = cfg[i];
      p.id = c.id;
      p.style = c.style;
      p.css = i == 0 ? 'x-grid3-cell-first ' : i == last ? 'x-grid3-cell-last ' : '';

      if (cf.summaryType || cf.summaryRenderer) {
        p.value = (cf.summaryRenderer || c.renderer)(o.data[c.name], p, o);
      } else {
        p.value = i == 0 ? '<div style="position:relative" ext:model="' + o.data.model + '" ext:qtip="' + i18n._('Export Records from these Positions') + '" class="x-menu-item-icon action_export">&nbsp;</div>' : '';
      }

      if (p.value == undefined || p.value === "") p.value = "&#160;";
      buf[buf.length] = this.cellTpl.apply(p);
    }

    return this.rowTpl.apply({
      tstyle: 'width:' + this.view.getTotalWidth() + ';',
      cells: buf.join('')
    });
  },

  /**
   * @private
   * @param {Object} rs
   * @param {Object} cs
   */
  calculate: function calculate(rs, cs) {
    var data = {},
        r,
        c,
        cfg = this.grid.getColumnModel().config,
        cf;

    for (var j = 0, jlen = rs.length; j < jlen; j++) {
      r = rs[j];

      for (var i = 0, len = cs.length; i < len; i++) {
        c = cs[i];
        cf = cfg[i];

        if (cf.summaryType) {
          data[c.name] = Ext.ux.grid.GroupSummary.Calculations[cf.summaryType](data[c.name] || 0, r, c.name, data);
        }
      }
    }

    return data;
  },
  doGroupEnd: function doGroupEnd(buf, g, cs, ds, colCount) {
    var data = this.calculate(g.rs, cs);
    data.model = g.rs[0].data.model;
    buf.push('</div>', this.renderSummary({
      data: data
    }, cs), '</div>');
  },
  doWidth: function doWidth(col, w, tw) {
    var gs = this.view.getGroups(),
        s;

    for (var i = 0, len = gs.length; i < len; i++) {
      s = gs[i].childNodes[2];
      s.style.width = tw;
      s.firstChild.style.width = tw;
      s.firstChild.rows[0].childNodes[col].style.width = w;
    }
  },
  doAllWidths: function doAllWidths(ws, tw) {
    var gs = this.view.getGroups(),
        s,
        cells,
        wlen = ws.length;

    for (var i = 0, len = gs.length; i < len; i++) {
      s = gs[i].childNodes[2];
      s.style.width = tw;
      s.firstChild.style.width = tw;
      cells = s.firstChild.rows[0].childNodes;

      for (var j = 0; j < wlen; j++) {
        cells[j].style.width = ws[j];
      }
    }
  },
  doHidden: function doHidden(col, hidden, tw) {
    var gs = this.view.getGroups(),
        s,
        display = hidden ? 'none' : '';

    for (var i = 0, len = gs.length; i < len; i++) {
      s = gs[i].childNodes[2];
      s.style.width = tw;
      s.firstChild.style.width = tw;
      s.firstChild.rows[0].childNodes[col].style.display = display;
    }
  },
  // Note: requires that all (or the first) record in the
  // group share the same group value. Returns false if the group
  // could not be found.
  refreshSummary: function refreshSummary(groupValue) {
    return this.refreshSummaryById(this.view.getGroupId(groupValue));
  },
  getSummaryNode: function getSummaryNode(gid) {
    var g = Ext.fly(gid, '_gsummary');

    if (g) {
      return g.down('.x-grid3-summary-row', true);
    }

    return null;
  },
  refreshSummaryById: function refreshSummaryById(gid) {
    var g = Ext.getDom(gid);

    if (!g) {
      return false;
    }

    var rs = [];
    this.grid.getStore().each(function (r) {
      if (r._groupId == gid) {
        rs[rs.length] = r;
      }
    });
    var cs = this.view.getColumnData(),
        data = this.calculate(rs, cs),
        markup = this.renderSummary({
      data: data
    }, cs),
        existing = this.getSummaryNode(gid);

    if (existing) {
      g.removeChild(existing);
    }

    Ext.DomHelper.append(g, markup);
    return true;
  },
  doUpdate: function doUpdate(ds, record) {
    this.refreshSummaryById(record._groupId);
  },
  doRemove: function doRemove(ds, record, index, isUpdate) {
    if (!isUpdate) {
      this.refreshSummaryById(record._groupId);
    }
  },

  /**
   * Show a message in the summary row.
   * <pre><code>
  grid.on('afteredit', function(){
  var groupValue = 'Ext Forms: Field Anchoring';
  summary.showSummaryMsg(groupValue, 'Updating Summary...');
  });
   * </code></pre>
   * @param {String} groupValue
   * @param {String} msg Text to use as innerHTML for the summary row.
   */
  showSummaryMsg: function showSummaryMsg(groupValue, msg) {
    var gid = this.view.getGroupId(groupValue),
        node = this.getSummaryNode(gid);

    if (node) {
      node.innerHTML = '<div class="x-grid3-summary-msg">' + msg + '</div>';
    }
  }
}); //backwards compat

Ext.grid.GroupSummary = Ext.ux.grid.GroupSummary;
/**
 * Calculation types for summary row:</p><div class="mdetail-params"><ul>
 * <li><b><tt>sum</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>count</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>max</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>min</tt></b> : <div class="sub-desc"></div></li>
 * <li><b><tt>average</tt></b> : <div class="sub-desc"></div></li>
 * </ul></div>
 * <p>Custom calculations may be implemented.  An example of
 * custom <code>summaryType=totalCost</code>:</p><pre><code>
// define a custom summary function
Ext.ux.grid.GroupSummary.Calculations['totalCost'] = function(v, record, field){
    return v + (record.data.estimate * record.dat7a.rate);
};
 * </code></pre>
 * @property Calculations
 */

Ext.ux.grid.GroupSummary.Calculations = {
  'sum': function sum(v, record, field) {
    return v + (record.data[field] || 0);
  },
  'count': function count(v, record, field, data) {
    return data[field + 'count'] ? ++data[field + 'count'] : data[field + 'count'] = 1;
  },
  'max': function max(v, record, field, data) {
    var v = record.data[field];
    var max = data[field + 'max'] === undefined ? data[field + 'max'] = v : data[field + 'max'];
    return v > max ? data[field + 'max'] = v : max;
  },
  'min': function min(v, record, field, data) {
    var v = record.data[field];
    var min = data[field + 'min'] === undefined ? data[field + 'min'] = v : data[field + 'min'];
    return v < min ? data[field + 'min'] = v : min;
  },
  'average': function average(v, record, field, data) {
    var c = data[field + 'count'] ? ++data[field + 'count'] : data[field + 'count'] = 1;
    var t = data[field + 'total'] = (data[field + 'total'] || 0) + (record.data[field] || 0);
    return t === 0 ? 0 : t / c;
  }
};
Ext.grid.GroupSummary.Calculations = Ext.ux.grid.GroupSummary.Calculations;
/**
 * @class Ext.ux.grid.HybridSummary
 * @extends Ext.ux.grid.GroupSummary
 * Adds capability to specify the summary data for the group via json as illustrated here:
 * <pre><code>
{
    data: [
        {
            projectId: 100,     project: 'House',
            taskId:    112, description: 'Paint',
            estimate:    6,        rate:     150,
            due:'06/24/2007'
        },
        ...
    ],

    summaryData: {
        'House': {
            description: 14, estimate: 9,
                   rate: 99, due: new Date(2009, 6, 29),
                   cost: 999
        }
    }
}
 * </code></pre>
 *
 */

Ext.ux.grid.HybridSummary = Ext.extend(Ext.ux.grid.GroupSummary, {
  /**
   * @private
   * @param {Object} rs
   * @param {Object} cs
   */
  calculate: function calculate(rs, cs) {
    var gcol = this.view.getGroupField(),
        gvalue = rs[0].data[gcol],
        gdata = this.getSummaryData(gvalue);
    return gdata || Ext.ux.grid.HybridSummary.superclass.calculate.call(this, rs, cs);
  },

  /**
   * <pre><code>
  grid.on('afteredit', function(){
  var groupValue = 'Ext Forms: Field Anchoring';
  summary.showSummaryMsg(groupValue, 'Updating Summary...');
  setTimeout(function(){ // simulate server call
      // HybridSummary class implements updateSummaryData
      summary.updateSummaryData(groupValue,
          // create data object based on configured dataIndex
          {description: 22, estimate: 888, rate: 888, due: new Date(), cost: 8});
  }, 2000);
  });
   * </code></pre>
   * @param {String} groupValue
   * @param {Object} data data object
   * @param {Boolean} skipRefresh (Optional) Defaults to false
   */
  updateSummaryData: function updateSummaryData(groupValue, data, skipRefresh) {
    var json = this.grid.getStore().reader.jsonData;

    if (!json.summaryData) {
      json.summaryData = {};
    }

    json.summaryData[groupValue] = data;

    if (!skipRefresh) {
      this.refreshSummary(groupValue);
    }
  },

  /**
   * Returns the summaryData for the specified groupValue or null.
   * @param {String} groupValue
   * @return {Object} summaryData
   */
  getSummaryData: function getSummaryData(groupValue) {
    var json = this.grid.getStore().reader.jsonData;

    if (json && json.summaryData) {
      return json.summaryData[groupValue];
    }

    return null;
  }
}); //backwards compat

Ext.grid.HybridSummary = Ext.ux.grid.HybridSummary;
Ext.ComponentMgr.registerPlugin('grouping_grid', Ext.ux.grid.GroupSummary);

/***/ }),
/* 1350 */
/***/ (function(module, exports) {

/**
 * filter own records
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.OwnRecordFilter
 * @extends     Tine.widgets.grid.ForeignRecordFilter
 * 
 * @constructor
 */
Tine.widgets.grid.OwnRecordFilter = Ext.extend(Tine.widgets.grid.ForeignRecordFilter, {
  isGeneric: false,
  initComponent: function initComponent() {
    this.label = this.ftb.generateTitle();
    this.field = this.ownRecordClass.getMeta('idProperty');
    this.defaultOperator = 'definedBy';
    this.foreignRecordClass = this.ownRecordClass;
    Tine.widgets.grid.OwnRecordFilter.superclass.initComponent.call(this);
  },
  getFilterData: function getFilterData(filterRecord) {
    var data = {
      field: this.field,
      id: filterRecord.id,
      label: filterRecord.toolbar ? filterRecord.toolbar.title : null
    };

    if (filterRecord.get('operator') == 'equals') {
      Ext.apply(data, {
        operator: 'equals',
        value: filterRecord.formFields.value.getValue()[0].value
      });
    } else {
      Ext.apply(data, {
        condition: filterRecord.condition || 'AND',
        filters: this.getRelatedRecordValue(filterRecord)
      });
    }

    return data;
  },
  setFilterData: function setFilterData(filterRecord, filterData) {
    // work around store compare bug
    if (Ext.isObject(filterData.filters)) {
      filterData.filters.toString = this.objectToString;
    }

    if (filterData.operator == 'equals') {
      filterData.operator = 'AND';
      filterData.value = [{
        field: ':' + this.field,
        operator: 'equals',
        value: filterData.value
      }];
      filterData.value.toString = this.objectToString;
      filterRecord.set('operator', 'AND');
      filterRecord.set('value', filterData.value);
    } else {
      filterRecord.condition = filterData.condition || 'AND';
    } //filterRecord.set('value', filterData.filters);


    this.setRelatedRecordValue(filterRecord);
  },
  setRelatedRecordValue: function setRelatedRecordValue(filterRecord) {
    if (filterRecord.data.filters) {
      filterRecord.set('value', filterRecord.data.filters);
      delete filterRecord.data.filters;
    }

    Tine.widgets.grid.OwnRecordFilter.superclass.setRelatedRecordValue.apply(this, arguments);
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['ownrecord'] = Tine.widgets.grid.OwnRecordFilter;

/***/ }),
/* 1351 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * quickadd grid panel
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.QuickaddGridPanel
 * @extends     Ext.ux.grid.QuickaddGridPanel
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.grid.QuickaddGridPanel
 */

Tine.widgets.grid.QuickaddGridPanel = Ext.extend(Ext.ux.grid.QuickaddGridPanel, {
  /**
   * @cfg {Tine.Tinebase.data.Record} recordClass
   */
  recordClass: null,

  /**
   * @cfg {Tine.Tinebase.widgets.Dialog.EditDialog} editDialog
   */
  editDialog: null,

  /**
   * @cfg {String} parentRecordField
   */
  parentRecordField: null,

  /**
   * @cfg {String} dataField
   * @deprecated
   * use this (single) field as data instead of whole data object
   */
  dataField: null,

  /**
   * @cfg {Bool} useBBar
   */
  useBBar: false,

  /**
   * @cfg {Bool} readOnly
   */
  readOnly: false,

  /**
   * @private
   */
  clicksToEdit: 'auto',
  frame: true,

  /**
   * @private
   */
  initComponent: function initComponent() {
    var _ = window.lodash,
        me = this,
        parent = me.findParentBy(function (c) {
      return !!c.record;
    }) || me.findParentBy(function (c) {
      return c.editDialog;
    });
    this.modelConfig = this.modelConfig || _.get(this, 'recordClass.getModelConfiguration') ? this.recordClass.getModelConfiguration() : null;
    this.defaultSortInfo = this.defaultSortInfo || {};
    this.initGrid();
    this.initActions();
    this.on('rowcontextmenu', this.onRowContextMenu, this);

    if (!this.store) {
      // create basic store
      this.store = new Ext.data.Store({
        // explicitly create reader
        sortInfo: this.defaultSortInfo,
        reader: new Ext.data.ArrayReader({
          idIndex: 0 // id for each record will be the first element

        }, this.recordClass)
      });
    }

    if (me.parentRecordField && !this.editDialog) {
      me.editDialog = _.get(parent, 'editDialog');
    }

    if (me.editDialog && me.parentRecordField) {
      me.editDialog.on('load', me.onRecordLoad, me);
      me.editDialog.on('recordUpdate', me.onRecordUpdate, me);
    }

    Tine.widgets.grid.QuickaddGridPanel.superclass.initComponent.call(this);
    this.on('newentry', this.onNewentry, this);
  },

  /**
   * init grid
   */
  initGrid: function initGrid() {
    this.plugins = this.plugins || [];
    this.plugins.push(new Ext.ux.grid.GridViewMenuPlugin({}));
    this.sm = new Ext.grid.RowSelectionModel();
    this.sm.on('selectionchange', function (sm) {
      var rowCount = sm.getCount();
      this.deleteAction.setDisabled(rowCount == 0);
    }, this);
    this.cm = !this.cm ? this.getColumnModel() : this.cm;
  },

  /**
   * @private
   */
  initActions: function initActions() {
    this.deleteAction = new Ext.Action({
      text: i18n._('Remove'),
      iconCls: 'actionDelete',
      handler: this.onDelete,
      scope: this,
      disabled: true
    });

    if (this.useBBar) {
      this.bbar = [this.deleteAction];
    }
  },

  /**
   * get column model
   * 
   * @return {Ext.grid.ColumnModel}
   */
  getColumnModel: function getColumnModel() {
    var _ = window.lodash,
        me = this;

    if (!this.colModel) {
      if (this.columns) {
        // convert string cols
        _.each(me.columns, function (col, idx) {
          if (_.isString(col)) {
            var addConfig = _.get(me, 'columnsConfig.' + col, {});

            var config = Tine.widgets.grid.ColumnManager.get(me.recordClass.getMeta('appName'), me.recordClass.getMeta('modelName'), col, 'editDialog', addConfig); // NOTE: in editor grids we need a type based certain min-width

            if (config) {
              me.columns[idx] = config;

              _.each(['quickaddField', 'editor'], function (prop) {
                config[prop] = Ext.ComponentMgr.create(Tine.widgets.form.FieldManager.getByModelConfig(me.recordClass.getMeta('appName'), me.recordClass.getMeta('modelName'), col, Tine.widgets.form.FieldManager.CATEGORY_PROPERTYGRID));
                config.width = config.width || config[prop].minWidth ? Math.max(config.width || 0, config[prop].minWidth || 0) : config.width;
              });
            }
          }
        });

        _.remove(me.columns, _.isString);
      }

      this.colModel = new Ext.grid.ColumnModel({
        defaults: {
          sortable: false
        },
        columns: this.columns || []
      });
    }

    return this.colModel;
  },

  /**
   * new entry event -> add new record to store
   * 
   * @param {Object} recordData
   * @return {Boolean}
   */
  onNewentry: function onNewentry(recordData) {
    var _ = window.lodash,
        defaultData = Ext.isFunction(this.recordClass.getDefaultData) ? this.recordClass.getDefaultData() : {},
        newRecord = new this.recordClass(defaultData, Ext.id());

    _.each(recordData, function (val, key) {
      if (val) {
        // we want to see the red dirty triangles
        Tine.Tinebase.common.assertComparable(val);
        newRecord.set(key, '');
      }

      newRecord.set(key, val);
    });

    if (this.fireEvent('beforeaddrecord', newRecord, this) !== false) {
      this.store.insert(0, [newRecord]);
    }

    return true;
  },

  /**
   * delete event
   */
  onDelete: function onDelete() {
    var selectedRows = this.getSelectionModel().getSelections();

    for (var i = 0; i < selectedRows.length; ++i) {
      this.store.remove(selectedRows[i]);
    }
  },
  onRowContextMenu: function onRowContextMenu(grid, row, e) {
    e.stopEvent();
    var selModel = grid.getSelectionModel();

    if (!selModel.isSelected(row)) {
      // disable preview update if config option is set to false
      this.updateOnSelectionChange = this.updateDetailsPanelOnCtxMenu;
      selModel.selectRow(row);
    }

    this.getContextMenu().showAt(e.getXY()); // reset preview update

    this.updateOnSelectionChange = true;
  },

  /**
   * creates and returns the context  menu
   * @return {Ext.menu.Menu}
   */
  getContextMenu: function getContextMenu() {
    if (!this.contextMenu) {
      var items = [this.deleteAction]; // lookup additional items

      items = items.concat(this.getContextMenuItems());
      this.contextMenu = new Ext.menu.Menu({
        plugins: [{
          ptype: 'ux.itemregistry',
          key: 'Tinebase-MainContextMenu'
        }],
        items: items
      });
    }

    if (this.readOnly) {
      this.deleteAction.setDisabled(true);
    }

    return this.contextMenu;
  },
  getContextMenuItems: function getContextMenuItems() {
    return [];
  },

  /**
   * get next available id
   * @return {Number}
   */
  getNextId: function getNextId() {
    var newid = this.store.getCount() + 1;

    while (this.store.getById(newid)) {
      newid++;
    }

    return newid;
  },

  /**
   * get values from store (as array)
   * 
   * @param {Array}
   * 
   * TODO improve this
   */
  setStoreFromArray: function setStoreFromArray(data) {
    this.store.clearData();

    for (var i = data.length - 1; i >= 0; --i) {
      var recordData = {};

      if (this.dataField === null) {
        recordData = data[i];
      } else {
        recordData[this.dataField] = data[i];
      }

      this.store.insert(0, new this.recordClass(recordData));
    }
  },

  /**
   * get values from store (as array)
   * 
   * @return {Array}
   */
  getFromStoreAsArray: function getFromStoreAsArray(deleteAutoIds) {
    var result = Tine.Tinebase.common.assertComparable([]);
    this.store.each(function (record) {
      var data = this.dataField === null ? record.data : record.get(this.dataField);

      if (deleteAutoIds && String(data.id).match(/ext-gen/)) {
        delete data.id;
      }

      result.push(data);
    }, this);
    return result;
  },
  onRecordLoad: function onRecordLoad(editDialog, record, ticketFn) {
    var _ = window.lodash,
        me = this,
        data = _.get(record, 'data.' + me.parentRecordField) || [],
        idProperty = me.recordClass.getMeta('idProperty'),
        copyOmitFields = _.filter(me.recordClass.getModelConfiguration().fields, {
      copyOmit: true
    });
    /* generic client driven resolve attempt
    var byType = _.groupBy(me.recordClass.getModelConfiguration().fields, 'type'),
        recordsByType = _.groupBy(_.get(byType, 'record', []), function(f) {
            return _.get(f, 'config.appName', '') + '.' + _.get(f, 'config.modelName', '')
        }),
        idMap = {};
     _.assign(byType, recordsByType);
     _.each(['user', 'Addressbook.Contact'], function(type) {
        _.each(byType[type], function(field) {
            idMap[type] = _.uniq(_.concat(_.get(idMap, type, []), _.compact(_.map(data, field.key))));
        });
    });
     // resolve all user and Addressbook.contact -> argh, there is no user API
    */


    if (me.editDialog.copyRecord) {
      _.each(data, function (recordData) {
        recordData[idProperty] = Tine.Tinebase.data.Record.generateUID();

        _.each(copyOmitFields, function (copyOmitField) {
          delete recordData[copyOmitField.key];
        });
      });
    }

    me.setStoreFromArray(data);
  },
  onRecordUpdate: function onRecordUpdate(editDialog, record) {
    var _ = window.lodash,
        me = this,
        data = me.getFromStoreAsArray();
    record.set(me.parentRecordField, data);
  }
});

/***/ }),
/* 1352 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _file_SelectionDialog__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(632);
/* harmony import */ var _file_SelectionDialog__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_file_SelectionDialog__WEBPACK_IMPORTED_MODULE_0__);
/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * @version     $Id
 */

/*global Ext, Tine*/
Ext.ns('Tine.widgets.grid');

/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FileUploadGrid
 * @extends     Ext.grid.GridPanel
 *
 * <p>FileUpload grid for dialogs</p>
 * <p>
 * </p>
 *
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 *
 * @param       {Object} config
 *
 * @constructor Create a new  Tine.widgets.grid.FileUploadGrid
 */

Tine.widgets.grid.FileUploadGrid = Ext.extend(Ext.grid.EditorGridPanel, {
  /**
   * @cfg filesProperty
   * @type String
   */
  filesProperty: 'files',

  /**
   * @cfg showTopToolbar
   * @type Boolean
   * TODO     think about that -> when we deactivate the top toolbar, we lose the dropzone for files!
   */
  //showTopToolbar: null,

  /**
   * @cfg {Bool} readOnly
   */
  readOnly: false,

  /**
   * config values
   * @private
   */
  header: false,
  border: false,
  deferredRender: false,
  autoExpandColumn: 'name',
  showProgress: true,
  i18nFileString: null,
  fileSelectionDialog: null,

  /**
   * init
   * @private
   */
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * @event filesSelected
     * Fired once files where selected from filemanager or from a local source
     */
    'filesSelected');
    this.i18nFileString = this.i18nFileString ? this.i18nFileString : i18n._('File');
    this.record = this.record || null; // init actions

    this.actionUpdater = new Tine.widgets.ActionUpdater({
      evalGrants: false
    });
    this.initSelectionModel();
    this.initToolbarAndContextMenu();
    this.initStore();
    this.initColumnModel();
    this.actionUpdater.updateActions(this.selModel, [_.get(this, 'record.data')]);

    if (!this.plugins) {
      this.plugins = [];
    }

    this.plugins.push(new Ext.ux.grid.GridViewMenuPlugin({}));
    this.enableHdMenu = false;
    Tine.widgets.grid.FileUploadGrid.superclass.initComponent.call(this);
    this.on('rowcontextmenu', function (grid, row, e) {
      e.stopEvent();
      var selModel = grid.getSelectionModel();

      if (!selModel.isSelected(row)) {
        selModel.selectRow(row);
      }

      this.contextMenu.showAt(e.getXY());
    }, this);

    if (!this.record || this.record.id === 0) {
      this.on('celldblclick', function (grid, rowIndex, columnIndex, e) {
        // Don't download if the cell has an editor, just go on with the event
        if (grid.getColumns()[columnIndex] && grid.getColumns()[columnIndex].editor) {
          return true;
        } // In case cell has no editor, just assume a download is intended


        e.stopEvent();
        this.onDownload();
      }, this);
    }

    this.postalSubscriptions = [];
    this.postalSubscriptions.push(postal.subscribe({
      channel: "recordchange",
      topic: 'Tinebase.TempFile.*',
      callback: this.onTempFileChanges.createDelegate(this)
    }));
  },
  onDestroy: function onDestroy() {
    _.each(this.postalSubscriptions, subscription => {
      subscription.unsubscribe();
    });

    return this.supr().onDestroy.call(this);
  },

  /**
   * bus notified about record changes
   */
  onTempFileChanges: function onTempFileChanges(data, e) {
    var existingRecord = _.find(this.store.data.items, item => {
      return _.get(item, 'data.id') === data.id;
    });

    if (existingRecord && e.topic.match(/\.update/)) {
      existingRecord.beginEdit();

      _.each(data, (v, k) => {
        const p = _.find(existingRecord.fields.items, {
          name: k
        });

        if (p &&
        /* preserve uniq name */
        k !== 'name') {
          existingRecord.set(k, v);
        }
      });

      _.assign(_.get(existingRecord, 'data.tempFile', {}), data);

      existingRecord.commit();
    } else if (existingRecord && e.topic.match(/\.delete/)) {
      this.store.remove(existingRecord);
    } else {
      const record = new Ext.ux.file.Upload.file(JSON.parse(JSON.stringify(data)), data.id);
      record.set('tempFile', JSON.parse(JSON.stringify(data)));
      this.store.addUnique(record, 'name');
    } // NOTE: grid doesn't update selections itself


    this.actionUpdater.updateActions(this.selModel, [_.get(this, 'record.data')]);
  },
  setReadOnly: function setReadOnly(readOnly) {
    this.readOnly = readOnly;
    this.action_add.setDisabled(readOnly);
    this.action_remove.setDisabled(readOnly);
  },

  /**
   * on upload failure
   * @private
   */
  onUploadFail: function onUploadFail(uploader, fileRecord) {
    var dataSize;

    if (fileRecord.html5upload) {
      dataSize = Tine.Tinebase.registry.get('maxPostSize');
    } else {
      dataSize = Tine.Tinebase.registry.get('maxFileUploadSize');
    }

    Ext.MessageBox.alert(i18n._('Upload Failed'), i18n._('Could not upload file. Filesize could be too big. Please notify your Administrator. Max upload size:') + ' ' + parseInt(dataSize, 10) / 1048576 + ' MB').setIcon(Ext.MessageBox.ERROR);
    this.getStore().remove(fileRecord);
    if (this.loadMask) this.loadMask.hide();
  },

  /**
   * on remove
   * @param {} button
   * @param {} event
   */
  onRemove: function onRemove(button, event) {
    var selectedRows = this.getSelectionModel().getSelections();

    for (var i = 0; i < selectedRows.length; i += 1) {
      this.store.remove(selectedRows[i]);
      var upload = Tine.Tinebase.uploadManager.getUpload(selectedRows[i].get('uploadKey'));

      if (upload) {
        upload.setPaused(true);
      }
    }
  },

  /**
   * on pause
   * @param {} button
   * @param {} event
   */
  onPause: function onPause(button, event) {
    var selectedRows = this.getSelectionModel().getSelections();

    for (var i = 0; i < selectedRows.length; i++) {
      var upload = Tine.Tinebase.uploadManager.getUpload(selectedRows[i].get('uploadKey'));

      if (upload) {
        upload.setPaused(true);
      }
    }

    this.getSelectionModel().deselectRange(0, this.getSelectionModel().getCount());
  },

  /**
   * on resume
   * @param {} button
   * @param {} event
   */
  onResume: function onResume(button, event) {
    var selectedRows = this.getSelectionModel().getSelections();

    for (var i = 0; i < selectedRows.length; i++) {
      var upload = Tine.Tinebase.uploadManager.getUpload(selectedRows[i].get('uploadKey'));
      upload.resumeUpload();
    }

    this.getSelectionModel().deselectRange(0, this.getSelectionModel().getCount());
  },

  /**
   * init toolbar and context menu
   * @private
   */
  initToolbarAndContextMenu: function initToolbarAndContextMenu() {
    var me = this;
    this.action_add = new Ext.Action(this.getAddAction());
    this.action_remove = new Ext.Action({
      text: String.format(i18n._('Remove {0}'), this.i18nFileString),
      iconCls: 'action_remove',
      scope: this,
      disabled: true,
      handler: this.onRemove
    });
    this.action_pause = new Ext.Action({
      text: i18n._('Pause upload'),
      iconCls: 'action_pause',
      scope: this,
      handler: this.onPause,
      actionUpdater: this.isPauseEnabled
    });
    this.action_resume = new Ext.Action({
      text: i18n._('Resume upload'),
      iconCls: 'action_resume',
      scope: this,
      handler: this.onResume,
      actionUpdater: this.isResumeEnabled
    });
    this.action_download = new Ext.Action({
      requiredGrant: 'readGrant',
      allowMultiple: false,
      actionType: 'download',
      text: i18n._('Download'),
      handler: this.onDownload,
      iconCls: 'action_download',
      scope: this,
      disabled: true,
      hidden: !Tine.Tinebase.configManager.get('downloadsAllowed')
    });
    let contextActions = [];

    if (Tine.Tinebase.common.hasRight('run', 'Filemanager')) {
      this.action_rename = Tine.Filemanager.nodeActionsMgr.get('rename', {
        initialApp: this.app,
        sm: this.getSelectionModel(),
        executor: function executor(record, text) {
          if (_.isFunction(_.get(record, 'set'))) {
            record.set('name', text);
            const tempFile = record.get('tempFile');

            if (tempFile) {
              _.set(tempFile, 'name', text);
            }
          }
        }
      });
      this.action_preview = Tine.Filemanager.nodeActionsMgr.get('preview', {
        initialApp: this.app,
        sm: this.getSelectionModel()
      });
      contextActions = contextActions.concat([this.action_rename, this.action_preview]);
    }

    this.tbar = new Ext.Toolbar({
      items: [this.action_add, this.action_remove, this.action_download],
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-FileUploadGrid-Toolbar'
      }]
    });
    contextActions = contextActions.concat([this.action_download, '-', this.action_remove, this.action_pause, this.action_resume]);
    this.contextMenu = new Ext.menu.Menu({
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-MainContextMenu'
      }, {
        ptype: 'ux.itemregistry',
        key: 'Tinebase-FileUploadGrid-ContextMenu'
      }],
      items: contextActions
    });
    this.actionUpdater.addActions(this.tbar.items);
    this.actionUpdater.addActions(this.contextMenu.items);
  },

  /**
   * init store
   * @private
   */
  initStore: function initStore() {
    this.store = new Ext.data.SimpleStore({
      fields: Ext.ux.file.Upload.file
    });
    this.store.on('add', this.onStoreAdd, this);
    this.loadRecord(this.record);
  },
  onStoreAdd: function onStoreAdd(store, records, idx) {
    Ext.each(records, function (attachment) {
      if (attachment.get('url')) {
        // we can't use Ext.data.connection here as we can't control xhr obj. directly :-(
        var me = this,
            url = attachment.get('url'),
            name = url.split('/').pop(),
            xhr = new XMLHttpRequest();
        xhr.open('GET', url, true);
        xhr.responseType = 'blob';
        store.suspendEvents();
        attachment.set('name', name);
        attachment.set('type', name.split('.').pop());
        store.resumeEvents();

        xhr.onprogress = function (e) {
          var progress = Math.floor(100 * e.loaded / e.total) + '% loaded';
          console.log(e);
        };

        xhr.onload = function (e) {
          //                    attachment.set('type', xhr.response.type);
          //                    attachment.set('size', xhr.response.size);
          const upload = new Ext.ux.file.Upload({
            file: new File([xhr.response], name),
            type: xhr.response.type,
            size: xhr.response.size,
            id: Tine.Tinebase.uploadManager.generateUploadId()
          }); // work around chrome bug which dosn't take type from blob

          upload.file.fileType = xhr.response.type;
          upload.on('uploadfailure', me.onUploadFail, me);
          upload.on('uploadcomplete', me.onUploadComplete, upload.fileRecord);
          upload.on('uploadstart', Tine.Tinebase.uploadManager.onUploadStart, me);
          upload.upload();
          store.remove(attachment);
          store.add(upload.fileRecord);
        };

        xhr.send();
      }
    }, this);
  },

  /**
   * download file
   *
   * @param {} button
   * @param {} event
   */
  onDownload: function onDownload(button, event) {
    var _ = window.lodash,
        selectedRows = this.getSelectionModel().getSelections(),
        fileRow = selectedRows[0],
        recordId = _.get(this.record, 'id', false),
        tempFile = fileRow.get('tempFile');

    if (recordId !== false && (!recordId || Ext.isObject(tempFile && tempFile.status !== 'complete'))) {
      Tine.log.debug('Tine.widgets.grid.FileUploadGrid::onDownload - file not yet available for download');
      return;
    }

    Tine.log.debug('Tine.widgets.grid.FileUploadGrid::onDownload - selected file:');
    Tine.log.debug(fileRow);

    if (Ext.isObject(tempFile)) {
      this.downloadTempFile(tempFile.id);
    } else {
      this.downloadNode(recordId, fileRow.id);
    }
  },

  /**
   * returns add action
   *
   * @return {Object} add action config
   */
  getAddAction: function getAddAction() {
    var me = this;
    return {
      text: String.format(i18n._('Add {0}'), me.i18nFileString),
      iconCls: 'action_add',
      scope: me,
      plugins: [{
        ptype: 'ux.browseplugin',
        multiple: true,
        enableFileDialog: false,
        dropElSelector: 'div[id=' + this.id + ']',
        handler: fileSelection => {
          me.onFilesSelect(fileSelection.getFileList());
        }
      }],
      handler: me.openDialog
    };
  },
  // Constructs a new dialog and opens it. Better to construct a new one everyt
  openDialog: function openDialog() {
    const win = new Tine.Tinebase.widgets.file.SelectionDialog.openWindow({
      windowId: this.id,
      mode: 'source',
      constraint: 'file',
      listeners: {
        scope: this,
        apply: this.onFilesSelect
      }
    });
  },

  /**
   * populate grid store
   *
   * @param {} record
   */
  loadRecord: function loadRecord(record) {
    if (record && record.get(this.filesProperty)) {
      var files = record.get(this.filesProperty);

      for (var i = 0; i < files.length; i += 1) {
        const existing = this.store.getById(files[i].id);

        if (existing) {
          _.each(files[i], (value, key) => {
            existing.set(value, key);
          });
        } else {
          var file = new Ext.ux.file.Upload.file(files[i]);
          file.data.status = 'complete';
          this.store.addUnique(file, 'name');
        }
      }
    }
  },

  /**
   * init cm
   */
  initColumnModel: function initColumnModel() {
    this.cm = new Ext.grid.ColumnModel(this.getColumns());
  },
  getColumns: function getColumns() {
    var columns = [{
      resizable: true,
      id: 'name',
      dataIndex: 'name',
      width: 300,
      header: i18n._('name'),
      renderer: Ext.ux.PercentRendererWithName
    }, {
      resizable: true,
      id: 'size',
      dataIndex: 'size',
      width: 70,
      header: i18n._('size'),
      renderer: Ext.util.Format.fileSize
    }, {
      resizable: true,
      id: 'type',
      dataIndex: 'type',
      width: 70,
      header: i18n._('type') // TODO show type icon?
      //renderer: Ext.util.Format.fileSize

    }];
    return columns;
  },

  /**
   * init sel model
   * @private
   */
  initSelectionModel: function initSelectionModel() {
    this.selModel = new Ext.grid.RowSelectionModel({
      multiSelect: true
    });
    this.selModel.on('selectionchange', function (selModel) {
      var rowCount = selModel.getCount();
      this.action_remove.setDisabled(this.readOnly || rowCount === 0);
      this.actionUpdater.updateActions(selModel, [_.get(this, 'record.data')]);
    }, this);
  },

  /**
   * upload new file and add to store
   */
  onFilesSelect: function onFilesSelect(fileList) {
    if (_.get(fileList, '[0].type') === 'fm_node') {
      this.onFileSelectFromFilemanager(fileList);
    } else {
      _.each(fileList, file => {
        const upload = new Ext.ux.file.Upload({
          file: file,
          id: Tine.Tinebase.uploadManager.generateUploadId(),
          isFolder: false
        });
        upload.on('uploadfailure', this.onUploadFail, this);
        upload.on('uploadcomplete', this.onUploadComplete, upload.fileRecord);
        upload.on('uploadstart', Tine.Tinebase.uploadManager.onUploadStart, this);
        upload.on('uploadinitial', this.onUploadInitial, this);
        upload.upload();
      });
    }

    this.fireEvent('filesSelected');
  },

  /**
   * Add one or more files from filemanager
   *
   * @param nodes
   */
  onFileSelectFromFilemanager: function onFileSelectFromFilemanager(fileLocations) {
    var me = this;

    _.each(fileLocations, async fileLocation => {
      const fileRecord = new Ext.ux.file.Upload.file({
        name: _.get(fileLocation, 'node_id.name'),
        size: _.get(fileLocation, 'node_id.size'),
        type: _.get(fileLocation, 'node_id.contenttype'),
        id: _.get(fileLocation, 'node_id.id'),
        status: 'uploading',
        progress: 80
      });
      this.store.addUnique(fileRecord, 'name');
      Tine.Tinebase.createTempFile(fileLocation).then(tempFileData => {
        fileRecord.beginEdit();
        fileRecord.set('id', _.get(fileRecord, 'data.id', tempFileData.id));
        fileRecord.set('tempFile', tempFileData);
        fileRecord.set('status', 'complete');
        fileRecord.set('progress', 100);
        fileRecord.commit();
      });
    });
  },
  onUploadComplete: function onUploadComplete(upload, fileRecord) {
    fileRecord.beginEdit();
    fileRecord.set('status', 'complete');
    fileRecord.set('progress', 100);

    try {
      fileRecord.commit(false);
    } catch (e) {
      console.log(e);
    }

    Tine.Tinebase.uploadManager.onUploadComplete();
  },
  onUploadInitial: function onUploadInitial(upload, fileRecord) {
    if (fileRecord.get('status') !== 'failure') {
      this.store.addUnique(fileRecord, 'name');
    }
  },

  /**
   * returns true if files are uploading atm
   *
   * @return {Boolean}
   */
  isUploading: function isUploading() {
    var uploadingFiles = this.store.query('status', 'uploading');
    return uploadingFiles.getCount() > 0;
  },
  isPauseEnabled: function isPauseEnabled(action, grants, records) {
    for (var i = 0; i < records.length; i++) {
      if (records[i].get('type') === 'folder') {
        action.hide();
        return;
      }
    }

    for (var i = 0; i < records.length; i++) {
      if (!records[i].get('status') || records[i].get('type ') !== 'folder' && records[i].get('status') !== 'paused' && records[i].get('status') !== 'uploading' && records[i].get('status') !== 'pending') {
        action.hide();
        return;
      }
    }

    action.show();

    for (var i = 0; i < records.length; i++) {
      if (records[i].get('status')) {
        action.setDisabled(false);
      } else {
        action.setDisabled(true);
      }

      if (records[i].get('status') && records[i].get('status') !== 'uploading') {
        action.setDisabled(true);
      }
    }
  },
  isResumeEnabled: function isResumeEnabled(action, grants, records) {
    for (var i = 0; i < records.length; i++) {
      if (records[i].get('type') === 'folder') {
        action.hide();
        return;
      }
    }

    for (var i = 0; i < records.length; i++) {
      if (!records[i].get('status') || records[i].get('type ') !== 'folder' && records[i].get('status') !== 'uploading' && records[i].get('status') !== 'paused' && records[i].get('status') !== 'pending') {
        action.hide();
        return;
      }
    }

    action.show();

    for (var i = 0; i < records.length; i++) {
      if (records[i].get('status')) {
        action.setDisabled(false);
      } else {
        action.setDisabled(true);
      }

      if (records[i].get('status') && records[i].get('status') !== 'paused') {
        action.setDisabled(true);
      }
    }
  },
  downloadNode: function downloadNode(recordId, id) {
    new Ext.ux.file.Download({
      params: {
        method: 'Tinebase.downloadRecordAttachment',
        requestType: 'HTTP',
        nodeId: id,
        recordId: recordId,
        modelName: this.app.name + '_Model_' + this.editDialog.modelName
      }
    }).start();
  },
  downloadTempFile: function downloadTempFile(id) {
    new Ext.ux.file.Download({
      params: {
        method: 'Tinebase.downloadTempfile',
        requestType: 'HTTP',
        tmpfileId: id
      }
    }).start();
  }
});

/***/ }),
/* 1353 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO maybe we should generalize parts of this and have a common parent for this and Tine.widgets.relation.GenericPickerGridPanel
 * TODO add more columns
 * TODO allow to edit description
 */
Ext.ns('Tine.widgets.dialog');
/**
 * @namespace   Tine.widgets.dialog
 * @class       Tine.widgets.dialog.AttachmentsGridPanel
 * @extends     Tine.widgets.grid.FileUploadGrid
 * @author      Philipp Schüle <p.schuele@metaways.de>
 */

Tine.widgets.dialog.AttachmentsGridPanel = Ext.extend(Tine.widgets.grid.FileUploadGrid, {
  /**
   * @cfg for FileUploadGrid
   */
  filesProperty: 'attachments',

  /**
   * The calling EditDialog
   * @type Tine.widgets.dialog.EditDialog
   */
  editDialog: null,

  /**
   * title
   * 
   * @type String
   */
  title: null,

  /**
   * the record
   * @type Record
   */
  record: null,

  /**
   * @type Tinebase.Application
   */
  app: null,

  /**
   * @cfg {String} requiredGrant to make actions
   */
  requiredGrant: 'editGrant',

  /**
   * @cfg {Number} pos
   * position 300 = 100 + 100*2 -> means second one after app specific tabs
   */
  pos: 300,

  /* config */
  frame: true,
  border: true,
  autoScroll: true,
  layout: 'fit',
  canonicalName: 'AttachmentsGrid',
  registerEditDialogEvents: true,

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    this.record = this.editDialog.record;
    this.app = this.editDialog.app;
    this.title = this.i18nTitle = i18n._('Attachments');
    this.i18nFileString = i18n._('Attachment');
    Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.registerSkipItem(this);

    if (this.registerEditDialogEvents) {
      this.editDialog.on('recordUpdate', this.onRecordUpdate, this);
      this.editDialog.on('load', this.onLoadRecord, this);
    }

    Tine.widgets.dialog.AttachmentsGridPanel.superclass.initComponent.call(this);
    this.postalSubscriptions = [];
    this.postalSubscriptions.push(postal.subscribe({
      channel: "recordchange",
      topic: 'Tinebase.Tree_Node.*',
      callback: this.onAttachmentChanges.createDelegate(this)
    }));
    this.on('rowdblclick', this.onRowDbClick, this);
    this.on('keydown', this.onKeyDown, this);
  },
  onDestroy: function onDestroy() {
    _.each(this.postalSubscriptions, subscription => {
      subscription.unsubscribe();
    });

    return this.supr().onDestroy.call(this);
  },

  /**
   * bus notified about record changes
   */
  onAttachmentChanges: function onAttachmentChanges(data, e) {
    const record = Tine.Tinebase.data.Record.setFromJson(data, Tine.Tinebase.Model.Tree_Node);
    const existingRecord = this.store.getById(data.id);

    if (existingRecord && e.topic.match(/\.update/)) {
      const idx = this.store.indexOf(existingRecord);
      const isSelected = this.selModel.isSelected(idx);
      const oldRecord = this.store.getAt(idx); // BE does not set the path / resolve properly

      record.data.path = oldRecord.data.path;
      record.data.created_by = oldRecord.data.created_by;

      if (idx >= 0) {
        this.store.removeAt(idx);
        this.store.insert(idx, [record]);
      } else {
        this.store.add([record]);
      }

      if (isSelected) {
        this.selModel.selectRow(this.store.indexOfId(record.id), true);
      }
    } else if (existingRecord && e.topic.match(/\.delete/)) {
      this.store.remove(existingRecord);
    } else {
      this.store.add([record]);
    } // NOTE: grid doesn't update selections itself


    this.actionUpdater.updateActions(this.selModel, [this.record.data]);
  },

  /**
   * get columns
   * @return Array
   */
  getColumns: function getColumns() {
    var columns = [{
      resizable: true,
      id: 'name',
      dataIndex: 'name',
      width: 150,
      header: i18n._('Name'),
      renderer: Ext.ux.PercentRendererWithName,
      sortable: true
    }, {
      resizable: true,
      id: 'size',
      dataIndex: 'size',
      width: 50,
      header: i18n._('Size'),
      renderer: Ext.util.Format.fileSize,
      sortable: true
    }, {
      resizable: true,
      id: 'contenttype',
      dataIndex: 'contenttype',
      width: 80,
      header: i18n._('Content Type'),
      sortable: true,
      renderer: function renderer(value, meta, record) {
        return _.get(record, 'data.contenttype', _.get(record, 'data.type'));
      }
    }, {
      id: 'creation_time',
      header: i18n._('Creation Time'),
      dataIndex: 'creation_time',
      renderer: Tine.Tinebase.common.dateRenderer,
      width: 80,
      sortable: true
    }, {
      id: 'created_by',
      header: i18n._('Created By'),
      dataIndex: 'created_by',
      renderer: Tine.Tinebase.common.usernameRenderer,
      width: 80,
      sortable: true
    }];
    return columns;
  },

  /**
   * init store
   * @private
   */
  initStore: function initStore() {
    this.store = new Ext.data.SimpleStore({
      fields: Tine.Tinebase.Model.Tree_Node
    });
  },
  onKeyDown: function onKeyDown(e) {
    var selectedRows = this.getSelectionModel().getSelections(),
        rowRecord = selectedRows[0];

    if (e.getKey() == e.SPACE && rowRecord.data.type == 'file') {
      this.action_preview.execute();
    }
  },
  // NOTE: this method is mixed in Tine.Filemanager.NodeGridPanel
  onRowDbClick: function onRowDbClick(grid, row, e) {
    const rowRecord = grid.getStore().getAt(row);

    if (rowRecord.data.type === 'folder') {
      this.expandFolder(rowRecord);
    } else if (!this.readOnly) {
      const dblClickHandlers = [{
        prio: 100,
        fn: _.bind(this.action_preview.execute, this.action_preview)
      }];

      if (Tine.Tinebase.configManager.get('downloadsAllowed') && Tine.Tinebase.registry.get('preferences').get('fileDblClickAction') === 'download') {
        dblClickHandlers[0].fn = _.bind(this.action_download.execute, this.action_download);
      }

      Tine.emit('filesystem.fileDoubleClick', rowRecord, dblClickHandlers);

      const dblClickHandler = _.last(_.sortBy(dblClickHandlers, ['prio']));

      if (dblClickHandler && _.isFunction(dblClickHandler.fn)) {
        dblClickHandler.fn.call(dblClickHandler.scope);
      }
    }
  },

  /**
   * is called from onApplyChanges of the edit dialog per save event
   * 
   * @param {Tine.widgets.dialog.EditDialog} dialog
   * @param {Tine.Tinebase.data.Record} record
   * @return {Boolean}
   */
  onRecordUpdate: function onRecordUpdate(dialog, record) {
    if (record.data.hasOwnProperty('attachments')) {
      Tine.Tinebase.common.assertComparable(record.data.attachments);
    }

    var attachments = Tine.Tinebase.common.assertComparable(this.getData());
    record.set('attachments', attachments);
  },

  /**
   * updates the title ot the tab
   * @param {Integer} count
   */
  updateTitle: function updateTitle(count) {
    count = Ext.isNumber(count) ? count : this.store.getCount();
    this.setTitle(this.i18nTitle + ' (' + count + ')');
  },

  /**
   * populate store
   * 
   * @param {EditDialog} editDialog
   * @param {Record} record
   * @param {Function} ticketFn
   */
  onLoadRecord: function onLoadRecord(editDialog, record, ticketFn) {
    var _ = window.lodash,
        interceptor = ticketFn(),
        attachments = record.get('attachments'),
        evalGrants = editDialog.evalGrants,
        hasRequiredGrant = !evalGrants || _.get(record, record.constructor.getMeta('grantsPath') + '.' + this.requiredGrant);

    this.store.removeAll();

    if (attachments && attachments.length > 0) {
      this.updateTitle(attachments.length);
      var attachmentRecords = [];
      Ext.each(attachments, function (attachment) {
        attachmentRecords.push(new Tine.Tinebase.Model.Tree_Node(attachment, attachment.id));
      }, this);
      this.store.add(attachmentRecords);
    } else {
      this.updateTitle(0);
    } // add other listeners after population


    if (this.store) {
      this.store.on('update', this.updateTitle, this);
      this.store.on('add', this.updateTitle, this);
      this.store.on('remove', this.updateTitle, this);
    }

    if (Ext.isFunction(interceptor)) {
      interceptor();
    }

    this.setReadOnly(!hasRequiredGrant);
    this.actionUpdater.updateActions(this.selModel, [record.data]);
  },

  /**
   * get attachments data as array
   * 
   * @return {Array}
   */
  getData: function getData() {
    var attachments = [];
    this.store.each(function (attachment) {
      attachments.push(attachment.data);
    }, this);
    return attachments;
  }
});

/***/ }),
/* 1354 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1355);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1355 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-form-element .x-wdgt-pickergrid {\n    border: 1px solid #b5b8c8;\n}\n\n.x-form-element .x-wdgt-pickergrid .x-panel-tbar-noheader .x-toolbar, .x-panel-mc .x-panel-tbar .x-toolbar,\n.x-form-element .x-wdgt-pickergrid .x-panel-bbar .x-toolbar {\n    border: none;\n}\n\n.x-form-element .x-wdgt-pickergrid .x-toolbar {\n    background-image: none;\n}", ""]);

// exports


/***/ }),
/* 1356 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.MappingPickerGridPanel
 * @extends     Tine.widgets.grid.PickerGridPanel
 *
 *
 * pick mapped dependent records with can be grouped by other records optionally
 *
 * Example: Project Members(Addressbook.Contact) grouped by Addressbook.Lists
 *
 * NOTE: Members must be defined as mapped dependent records because the (single) referenceId is stored on the depended
 *       record side - we can't add a field to Contacts AND a Contact might me member of multiple Projects.
 *
 * NOTE: Group defining records must be defined as separate map as dynamic typed dependencies not possible in modelconfig
 *
   projectMemberGroupsGrid = Ext.extend(Tine.widgets.grid.MappingPickerGridPanel, {
       field: 'membergroups',
       mappingField: 'groupMemberId'
   });
   projectMembersGrid = Ext.extend(Tine.widgets.grid.MappingPickerGridPanel, {
       field: 'members',
       mappingField: 'memberId',
       groupRecordsGrid: projectMemberGroupsGrid
   });
 *
 * @TODO: both grids should be part of this picker widget
 * @TODO: than the group grid could optional be merged as typed (client only) records here
 * @TODO: when records via group needs own properties in the mapping (e.g. last action), then the server
 *        needs to persist the resolved groupmembers and flag them as gropumembers (see calendar attendee)
 */

Tine.widgets.grid.MappingPickerGridPanel = Ext.extend(Tine.widgets.grid.PickerGridPanel, {
  /**
   * @cfg {String} field - required!
   * field of mapping records.
   */
  field: null,

  /**
   * @cfg {String} mappingField - required!
   * forward reference field in mapping record.
   */
  mappingField: null,

  /**
   * @cfg {String} groupRecordsGrid - optional
   * property name of grid which group records. The groups get automatically resolved when specified
   */
  groupRecordsGrid: null,
  frame: true,
  height: 200,
  initComponent: function initComponent() {
    var _ = window.lodash,
        me = this,
        parent = me.findParentBy(function (c) {
      return c.editDialog;
    }),
        editDialog = _.get(parent, 'editDialog'),
        mappingFieldDef = editDialog.recordClass.getField(me.field),
        mappingRecordClass = mappingFieldDef.getRecordClass(),
        recordDef = mappingRecordClass.getField(me.mappingField),
        recordClass = recordDef.getRecordClass();

    editDialog.on('load', me.onRecordLoad, me);
    editDialog.on('recordUpdate', me.onRecordUpdate, me);
    me.editDialog = editDialog;
    me.recordClass = recordClass;
    me.mappingRecordClass = mappingRecordClass;
    me.store = new Tine.Tinebase.data.RecordStore({
      readOnly: true,
      autoLoad: false,
      recordClass: me.recordClass
    });
    me.store.on('add', me.onRecordUpdate, me);
    me.store.on('update', me.onRecordUpdate, me);
    me.store.on('remove', me.onRecordUpdate, me);
    me.referenceField = mappingFieldDef.fieldDefinition.config.refIdField;
    me.title = recordClass.getRecordsName();
    me.mappingRecordStore = new Tine.Tinebase.data.RecordStore({
      readOnly: true,
      autoLoad: false,
      recordClass: me.mappingRecordClass
    });
    me.afterIsRendered().then(function () {
      var groupRecordStore = _.get(me.editDialog, [me.groupRecordsGrid, 'store'].join('.')),
          groupField = _.get(me.editDialog, [me.groupRecordsGrid, 'field'].join('.')),
          groupMappingField = _.get(me.editDialog, [me.groupRecordsGrid, 'mappingField'].join('.')),
          columns = [].concat(me.colModel.config);

      if (groupRecordStore) {
        groupRecordStore.on('add', me.onRecordLoad, me);
        groupRecordStore.on('remove', me.onRecordLoad, me);
        columns.unshift({
          dataIndex: me.recordClass.getMeta('idProperty'),
          header: i18n._('via'),
          width: 150,
          renderer: function renderer(id, meta, record) {
            return _.reduce(me.mappingRecordStore.data.items, function (names, mappingRecord) {
              if (_.get(mappingRecord, 'data.' + me.mappingField) == id) {
                var groupRecordId = _.get(mappingRecord, 'json.' + groupMappingField, ''),
                    groupRecord = groupRecordStore.getById(groupRecordId);

                if (groupRecord) {
                  names.push(groupRecord.getTitle());
                }
              }

              return names;
            }, []).join(', ');
          }
        });
        me.colModel.setConfig(columns);
      }
    });
    Tine.widgets.grid.MappingPickerGridPanel.superclass.initComponent.apply(me, arguments);
  },
  onRecordLoad: function onRecordLoad() {
    var _ = window.lodash,
        me = this,
        mappingRecordsData = _.get(me.editDialog.record, 'data.' + me.field) || [],
        recordIds = _.reduce(mappingRecordsData, function (ids, mappingRecordData) {
      var recordId = mappingRecordData[me.mappingField];
      return ids.concat([recordId]);
    }, []);

    if (me.editDialog.copyRecord) {
      _.each(mappingRecordsData, function (mappingRecordData) {
        mappingRecordData[me.recordClass.getMeta('idProperty')] = Tine.Tinebase.data.Record.generateUID();
        mappingRecordData[me.referenceField] = me.editDialog.record.id;
      });
    }

    me.mappingRecordStore.loadData({
      results: mappingRecordsData
    }); // fence onRecordUpdate

    me.store.isLoaded = false;
    me.resolveGroupRecords(recordIds).then(function () {
      // NOTE: we don't use resolved data yet - data is missing
      if (false) {} else {
        me.store.on('load', function () {
          me.store.isLoaded = true;
        }, me, {
          single: true
        });
        recordIds = _.reduce(recordIds, function (ids, recordId) {
          return ids.concat(_.isString(recordId) ? recordId : recordId.id);
        }, []);
        me.store.load({
          params: {
            filter: [{
              field: 'id',
              operator: 'in',
              value: recordIds
            }]
          }
        });
      }
    });
  },
  // resolve corresponding records from groupField
  resolveGroupRecords: function resolveGroupRecords(recordIds) {
    var _ = window.lodash,
        me = this,
        groupField = _.get(me.editDialog, [me.groupRecordsGrid, 'field'].join('.')),
        groupMappingField = _.get(me.editDialog, [me.groupRecordsGrid, 'mappingField'].join('.')),
        groupRecordsData = _.get(me.editDialog.record, 'data.' + groupField) || [];

    return !groupRecordsData.length ? Promise.resolve() : new Promise(function (resolve) {
      var groupMappingFieldDef = me.recordClass.getField(groupField),
          groupMappingRecoredClass = groupMappingFieldDef.getRecordClass(),
          groupFieldDef = groupMappingRecoredClass.getField(groupMappingField),
          groupRecoredClass = groupFieldDef.getRecordClass(),
          getGroupRecordMethod = _.get(Tine, groupRecoredClass.getMeta('appName') + '.get' + groupRecoredClass.getMeta('modelName')),
          getRecordPromises = _.reduce(groupRecordsData, function (promises, groupRecordData) {
        var id = _.get(groupRecordData, groupMappingField + '.id') || _.get(groupRecordData, groupMappingField);

        return promises.concat(getGroupRecordMethod(id));
      }, []);

      me.showLoadMask();
      Promise.all(getRecordPromises).then(function (values) {
        _.each(values, function (groupRecordData) {
          var groupRecord = Tine.Tinebase.data.Record.setFromJson(groupRecordData, groupRecoredClass),
              groupTitle = groupRecord.getTitle(),
              mappingRecordsData = _.get(groupRecordData, me.field) || [];
          me.mappingRecordStore.loadData({
            results: mappingRecordsData
          }, true);

          _.each(mappingRecordsData, function (mappingRecordData) {
            var recordId = mappingRecordData[me.mappingField];
            recordIds.push(recordId);
          });
        });

        resolve();
      });
    });
  },
  onRecordUpdate: function onRecordUpdate() {
    var _ = window.lodash,
        me = this,
        recordsData = Tine.Tinebase.common.assertComparable([]);

    _.each(me.store.data.items, function (record, idx) {
      var mappingRecord = {},
          existingMappingIdx = me.mappingRecordStore.find(me.mappingField, record.id),
          existingMappingRecord = existingMappingIdx >= 0 ? me.mappingRecordStore.getAt(existingMappingIdx) : null,
          existingRefId = existingMappingRecord ? existingMappingRecord.get(me.referenceField) : null;
      if (me.isGroupRecord(record)) return;
      mappingRecord[me.mappingField] = record.id;
      mappingRecord[me.referenceField] = me.editDialog.record.id;
      recordsData.push(mappingRecord);
    });

    if (me.store.isLoaded) {
      me.editDialog.record.set(this.field, recordsData);
    }
  },
  actionRemoveUpdater: function actionRemoveUpdater(action, grants, records) {
    var _ = window.lodash,
        me = this,
        containsGroupRecord = _.reduce(records, function (r, s) {
      return r || me.isGroupRecord(s);
    }, false);

    action.setDisabled(containsGroupRecord);
  },
  isGroupRecord: function isGroupRecord(record) {
    var me = this,
        existingMappingIdx = me.mappingRecordStore.find(me.mappingField, record.id),
        existingMappingRecord = existingMappingIdx >= 0 ? me.mappingRecordStore.getAt(existingMappingIdx) : null,
        existingRefId = existingMappingRecord ? existingMappingRecord.get(me.referenceField) : null;
    if (existingMappingRecord && !existingRefId) return true;
    if (existingRefId && existingRefId != me.editDialog.record.id) return true;
    return false;
  }
});

/***/ }),
/* 1357 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * Link GridPanel
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.LinkGridPanel
 * @extends     Tine.widgets.grid.PickerGridPanel
 * 
 * <p>Link GridPanel</p>
 * <p><pre>
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.grid.LinkGridPanel
 */

Tine.widgets.grid.LinkGridPanel = Ext.extend(Tine.widgets.grid.PickerGridPanel, {
  /**
   * @cfg for PickerGridPanel
   */
  recordClass: Tine.Tinebase.Model.Relation,
  autoExpandColumn: 'name',
  enableTbar: true,
  clicksToEdit: 1,
  selectRowAfterAdd: false,
  editDialog: null,

  /**
   * the record
   * @type Record 
   */
  record: null,

  /**
   * relation types can be stored in keyfield
   * @type 
   */
  relationTypesKeyfieldName: null,

  /**
   * relation types for combobox in editor grid
   * @type Array
   */
  relationTypes: null,

  /**
   * default relation type
   * @type String
   */
  defaultType: '',

  /**
   * @type Tinebase.Application 
   */
  app: null,

  /**
   * @cfg {String} requiredGrant to make actions
   */
  requiredGrant: 'editGrant',
  typeColumnHeader: null,

  /**
   * @return Ext.grid.ColumnModel
   * @private
   */
  getColumnModel: function getColumnModel() {
    if (!this.colModel) {
      this.typeEditor = this.relationTypesKeyfieldName ? new Tine.Tinebase.widgets.keyfield.ComboBox({
        app: this.app.appName,
        keyFieldName: this.relationTypesKeyfieldName
      }) : this.relationTypes ? new Ext.form.ComboBox({
        displayField: 'label',
        valueField: 'relation_type',
        mode: 'local',
        triggerAction: 'all',
        lazyInit: false,
        autoExpand: true,
        blurOnSelect: true,
        listClass: 'x-combo-list-small',
        store: new Ext.data.SimpleStore({
          fields: ['label', 'relation_type'],
          data: this.relationTypes
        })
      }) : null;
      this.colModel = new Ext.grid.ColumnModel({
        defaults: {
          sortable: true
        },
        columns: [{
          id: 'name',
          header: i18n._('Name'),
          dataIndex: 'related_record',
          renderer: this.relatedRecordRender,
          scope: this
        }, {
          id: 'type',
          header: this.typeColumnHeader ? this.typeColumnHeader : i18n._('Type'),
          dataIndex: 'type',
          width: 100,
          sortable: true,
          renderer: this.relationTypesKeyfieldName ? Tine.Tinebase.widgets.keyfield.Renderer.get(this.app.appName, this.relationTypesKeyfieldName) : this.relationTypeRenderer,
          scope: this,
          editor: this.typeEditor
        }].concat(this.configColumns)
      });
    }

    return this.colModel;
  },

  /**
   * related record renderer
   * 
   * @param {Record} value
   * @return {String}
   */
  relatedRecordRender: function relatedRecordRender(value) {
    var result = '';

    if (value) {
      result = value.data ? Ext.util.Format.htmlEncode(value.get(this.searchRecordClass.getMeta('titleProperty'))) : value[this.searchRecordClass.getMeta('titleProperty')];
    }

    return result;
  },

  /**
   * type renderer
   * 
   * @param {String} value
   * @return {String}
   */
  relationTypeRenderer: function relationTypeRenderer(value) {
    var result = '';

    if (value) {
      result = this.app.i18n._(Ext.util.Format.capitalize(value));
    }

    return result;
  },

  /**
   * is called after selecting a record in the combo
   * 
   * @param {Tine.Tinebase.widgets.form.RecordPickerComboBox} picker the triggering combo box
   * @param {Tine.Tinebase.data.Record} recordToAdd
   */
  onAddRecordFromCombo: function onAddRecordFromCombo(picker, recordToAdd) {
    // if no record is given, do nothing
    if (!recordToAdd) {
      return;
    }

    var record = new Tine.Tinebase.Model.Relation(Ext.apply({
      related_record: new this.newRecordClass(recordToAdd.data, recordToAdd.id),
      related_id: recordToAdd.id,
      own_id: this.record ? this.record.id : null
    }, picker.relationDefaults), recordToAdd.id);
    Tine.log.debug('Adding new relation:');
    Tine.log.debug(record); // check if already in

    if (this.store.findExact('related_id', recordToAdd.id) === -1) {
      var recordType = record.get('type');

      if (!Ext.isString(recordType) && recordType['default']) {
        record.set('type', recordType['default']);
        record.commit();
      }

      this.store.add([record]);
    }

    picker.reset();
  },

  /**
   * populate store and set record
   * 
   * @param {Record} record
   */
  onRecordLoad: function onRecordLoad(record) {
    var _ = window.lodash,
        evalGrants = this.editDialog.evalGrants,
        hasRequiredGrant = !evalGrants || _.get(record, record.constructor.getMeta('grantsPath') + '.' + this.requiredGrant),
        types = [];

    if (this.record) {
      return;
    }

    this.record = record; //get relation types

    if (this.typeEditor) {
      _.forEach(this.typeEditor.keyFieldConfig.value.records, function (config) {
        types.push(config.id);
      });
    }

    Tine.log.debug('Loading relations into store...');

    if (record.get('relations') && record.get('relations').length > 0) {
      var relationRecords = [];
      Ext.each(record.get('relations'), function (relation) {
        if (types.indexOf(relation.type) >= 0) {
          relation.related_record = new this.searchRecordClass(relation.related_record, relation.related_id);
          relationRecords.push(new Tine.Tinebase.Model.Relation(relation, relation.id));
        }
      }, this);
      this.store.add(relationRecords);
    } // activate highlighting after initial load


    (function () {
      this.highlightRowAfterAdd = true;
    }).defer(400, this); // TODO perhaps we should filter all that do not match the model

    this.setReadOnly(!hasRequiredGrant);
  },

  /**
   * get relations data as array
   *
   * @TODO: do not manupilate store data
   * 
   * @return {Array}
   */
  getData: function getData() {
    var _ = window.lodash,
        relations = [];
    this.store.each(function (record) {
      var relatedRecordData = _.get(record, 'data.related_record.data', false);

      if (relatedRecordData) {
        record.data.related_record = relatedRecordData;
      }

      relations.push(record.data);
    }, this);
    return relations;
  }
});
Ext.reg('wdgt.linkgrid', Tine.widgets.grid.LinkGridPanel);

/***/ }),
/* 1358 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * TODO         this is only used by the Felamimail flag filter atm, we should try to replace this / generalize it
 *              @see Tine.widgets.grid.PickerFilter
 */
Ext.ns('Tine.widgets.grid');
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterModelMultiSelect
 * @extends     Tine.widgets.grid.FilterModel
 * 
 * @author      Philipp Schuele <p.schuele@metaways.de>
 */

Tine.widgets.grid.FilterModelMultiSelect = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @property Tine.Tinebase.Application app
   */
  app: null,

  /**
   * @cfg field
   * @type String
   */
  field: '',

  /**
   * @cfg defaultOperator
   * @type String
   */
  defaultOperator: 'in',

  /**
   * @cfg defaultValue
   * @type String
   */
  defaultValue: '',

  /**
   * @cfg label
   * @type String
   */
  label: '',

  /**
   * @cfg multiselectField
   */
  multiselectFieldConfig: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.operators = this.operators || ['in', 'notin'];
    this.multiselectFieldConfig = this.multiselectFieldConfig || {};
    Tine.widgets.grid.FilterModelMultiSelect.superclass.initComponent.call(this);
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    var value = new Tine.widgets.grid.FilterModelMultiSelectValueField(Ext.apply({
      app: this.app,
      filter: filter,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      renderTo: el
    }, this.multiselectFieldConfig));
    value.on('specialkey', function (field, e) {
      if (e.getKey() == e.ENTER) {
        this.onFiltertrigger();
      }
    }, this);
    value.on('select', this.onFiltertrigger, this);
    return value;
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tinebase.multiselect'] = Tine.widgets.grid.FilterModelMultiSelect;
/**
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.FilterModelMultiSelectValueField
 * @extends     Ext.ux.form.LayerCombo
 * 
 * @author      Philipp Schuele <p.schuele@metaways.de>
 */

Tine.widgets.grid.FilterModelMultiSelectValueField = Ext.extend(Ext.ux.form.LayerCombo, {
  hideButtons: false,
  formConfig: {
    labelAlign: 'left',
    labelWidth: 30
  },
  labelField: 'name',
  xtype: 'checkbox',
  recordClass: null,
  valueStore: null,
  selectionWidget: null,
  labelRenderer: Ext.emptyFn,

  /**
   * init
   */
  initComponent: function initComponent() {
    this.on('beforecollapse', this.onBeforeCollapse, this);

    if (!this.store) {
      this.store = new Ext.data.SimpleStore({
        fields: this.recordClass
      });
    }

    Tine.widgets.grid.FilterModelMultiSelectValueField.superclass.initComponent.call(this);
  },

  /**
   * get form values
   * 
   * @return {Array}
   */
  getFormValue: function getFormValue() {
    var values = [];

    if (this.xtype == 'checkbox') {
      var formValues = this.getInnerForm().getForm().getValues();

      for (var id in formValues) {
        if (formValues[id] === 'on' && this.valueStore.getById(id)) {
          values.push(id);
        }
      }
    } else {
      this.store.each(function (record) {
        values.push(record.data);
      }, this);
    }

    return values;
  },

  /**
   * get items
   * 
   * @return {Array}
   */
  getItems: function getItems() {
    var items = [];

    if (this.xtype == 'wdgt.pickergrid') {
      this.initSelectionWidget(); // defeat scoping :)

      selectionWidget = this.selectionWidget;
      this.pickerGridPanel = new Tine.widgets.grid.PickerGridPanel({
        height: this.layerHeight || 'auto',
        recordClass: this.recordClass,
        store: this.store,
        autoExpandColumn: this.labelField,
        getColumnModel: this.getColumnModel.createDelegate(this),
        initActionsAndToolbars: function initActionsAndToolbars() {
          Tine.widgets.grid.PickerGridPanel.prototype.initActionsAndToolbars.call(this);
          this.tbar = new Ext.Toolbar({
            layout: 'fit',
            items: [selectionWidget]
          });
        }
      });
      items.push(this.pickerGridPanel);
    } else if (this.xtype == 'checkbox') {
      this.valueStore.each(function (record) {
        items.push({
          xtype: this.xtype,
          boxLabel: record.get(this.labelField),
          name: record.get('id') //icon: record.get('status_icon'),

        });
      }, this);
    }

    return items;
  },

  /**
   * init selection widget
   */
  initSelectionWidget: function initSelectionWidget() {
    this.selectionWidget.on('select', this.onRecordSelect, this);
  },

  /**
   * @return Ext.grid.ColumnModel
   */
  getColumnModel: function getColumnModel() {
    var labelColumn = {
      id: this.labelField,
      header: String.format(i18n._('Selected  {0}'), this.recordClass.getMeta('recordsName')),
      dataIndex: this.labelField
    };

    if (this.labelRenderer != Ext.emptyFn) {
      labelColumn.renderer = this.labelRenderer;
    }

    return new Ext.grid.ColumnModel({
      defaults: {
        sortable: false
      },
      columns: [labelColumn]
    });
  },

  /**
   * record select
   * 
   * @param {String} field
   * @param {Object} recordData
   */
  onRecordSelect: function onRecordSelect(field, recordData) {
    this.addRecord(recordData);
    this.selectionWidget.clearValue();
  },

  /**
   * adds record from selection widget to store
   * 
   * @param {Object} recordData
   */
  addRecord: function addRecord(recordData) {
    var data = recordData.data ? recordData.data : recordData.attributes ? recordData.attributes : recordData;
    var existingRecord = this.store.getById(recordData.id);

    if (!existingRecord) {
      this.store.add(new Tine.Tinebase.Model.Container(data));
    } else {
      var idx = this.store.indexOf(existingRecord);
      var row = this.pickerGridPanel.getView().getRow(idx);
      Ext.fly(row).highlight();
    }

    this.selectionWidget.selectPanel.close();
  },

  /**
   * @param {String} value
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    value = Ext.isArray(value) ? value : [value];
    var recordText = [];
    this.currentValue = [];

    if (this.xtype == 'checkbox') {
      this.valueStore.each(function (record) {
        var id = record.get('id');
        var name = record.get(this.labelField);
        Ext.each(value, function (valueId) {
          // NOTE: no type match id's might be int or string and should match anyway!
          if (valueId == id) {
            recordText.push(name);
            this.currentValue.push(id);
          }
        }, this);
      }, this);
    } else {
      this.store.removeAll();
      var record, id, text;

      for (var i = 0; i < value.length; i++) {
        text = this.getRecordText(value[i]);

        if (text && text !== '') {
          recordText.push(text);
        }
      }
    }

    this.setRawValue(recordText.join(', '));
    return this;
  },

  /**
   * get text from record defined by value (id or something else)
   * 
   * @param {String|Object} value
   * @return {String}
   */
  getRecordText: function getRecordText(value) {
    var text = '';
    id = Ext.isString(value) ? value : value.id;
    record = this.valueStore.getById(id);

    if (record) {
      this.currentValue.push(record.id); // always copy/clone record because it can't exist in 2 different stores

      this.store.add(record.copy());
      text = record.get(this.labelField);
      text = this.labelRenderer != Ext.emptyFn ? this.labelRenderer(text) : text;
    }

    return text;
  },

  /**
   * cancel collapse if ctx menu or record selection is shown
   * 
   * @return Boolean
   */
  onBeforeCollapse: function onBeforeCollapse() {
    if (this.pickerGridPanel) {
      var contextMenuVisible = this.pickerGridPanel.contextMenu && !this.pickerGridPanel.contextMenu.hidden,
          selectionVisible = this.isSelectionVisible();
      return !(contextMenuVisible || selectionVisible);
    } else {
      return true;
    }
  },

  /**
   * is selection visible ?
   * - overwrite this when extending to make sure that the selection widget is no longer visible on collapse
   * 
   * @return {Boolean}
   */
  isSelectionVisible: function isSelectionVisible() {
    return false;
  },

  /**
   * sets values to innerForm
   */
  setFormValue: function setFormValue(value) {
    if (this.xtype == 'checkbox') {
      this.getInnerForm().getForm().items.each(function (item) {
        item.setValue(value.indexOf(item.name) >= 0 ? 'on' : 'off');
      }, this);
    }
  }
});

/***/ }),
/* 1359 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Stefanie Stamer <s.stamer@metaways.de>
 * @copyright   Copyright (c) 2007-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');

Tine.widgets.grid.QuotaRenderer = function (usage, limit, useSoftQuota) {
  // template singleton
  if (!Tine.widgets.grid.QuotaRenderer.tpl) {
    Tine.widgets.grid.QuotaRenderer.tpl = new Ext.XTemplate('<div class="x-progress-wrap PercentRenderer" <tpl if="qtip">ext:qtitle="' + i18n._('Quota usage') + '" qwidth="200" qtip="{qtip}"></tpl>', '<div class="x-progress-inner PercentRenderer">', '<div class="x-progress-bar PercentRenderer {cls}"<tpl if="Ext.isNumber(percent)"> style="width:{percent}%"</tpl>>', '<div class="PercentRendererText PercentRenderer">', '<div>{[Tine.Tinebase.common.byteRenderer(values.usage)]}</div>', '</div>', '</div>', '<div class="x-progress-text x-progress-text-back PercentRenderer">', '<div>&#160;</div>', '</div>', '</div>', '</div>').compile();
  }

  usage = parseInt(usage);
  limit = parseInt(limit);
  var data = {
    usage: usage,
    limit: limit,
    percent: limit ? Math.round(usage / limit * 100) : null,
    quota: Tine.Tinebase.configManager.get('quota'),
    cls: limit ? 'PercentBar-below' : 'QuotaRenderer-unlimited',
    qtip: limit ? String.format(i18n._('{0} available (total: {1})'), Tine.Tinebase.common.byteRenderer(limit - usage), Tine.Tinebase.common.byteRenderer(limit)) : ''
  }; // this will enable a color scheme for soft quota or reached limit

  if (data.limit && useSoftQuota && data.percent >= data.quota.softQuota) {
    data.cls = "PercentBar-over";
  }

  if (data.limit && data.usage >= data.limit) {
    data.cls = "PercentBar-limit";
  }

  return Tine.widgets.grid.QuotaRenderer.tpl.apply(data);
};

/***/ }),
/* 1360 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.relation');
/**
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.Manager
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 */

Tine.widgets.relation.Manager = function () {
  var items = {};
  var ignoreApplications = ['Admin', 'Setup', 'Tinebase', 'ActiveSync'];
  return {
    /**
     * returns the relations config
     * @param {String/Tine.Tinebase.Application} app
     * @param {String/Tine.Tinebase.data.Record} recordClass
     * @param {Array} ignoreModels the php model names to ignore (they won't be returned)
     */
    get: function get(app, recordClass, ignoreModels) {
      var key = this.getKey(app, recordClass); // create if not cached

      if (items[key] === undefined) {
        if (Ext.isString(recordClass)) {
          app = Tine.Tinebase.common.resolveApp(app);
          recordClass = Tine[app]['Model'][recordClass];
        }

        this.create(recordClass, key);
      }

      var allRelations = items[key];
      var usedRelations = []; // sort out ignored models

      if (ignoreModels) {
        Ext.each(allRelations, function (relation) {
          if (ignoreModels.indexOf(relation.relatedApp + '_Model_' + relation.relatedModel) == -1) {
            usedRelations.push(relation);
          }
        }, this);
      } else {
        return allRelations;
      }

      return usedRelations;
    },

    /**
     * returns the relations config existence
     * @param {String/Tine.Tinebase.Application} app
     * @param {String/Tine.Tinebase.data.Record} recordClass
     * @return {Boolean}
     */
    has: function has(app, recordClass) {
      var key = this.getKey(app, recordClass); // create if not cached

      if (items[key] === undefined) this.create(recordClass, key);
      return items[key] ? true : false;
    },

    /**
     * creates the relations config if found in registry
     * @param Tine.Tinebase.data.Record recordClass
     * @param {String} key
     * @return {Boolean}
     */
    create: function create(recordClass, key) {
      var registered = [];
      if (!items[key]) items[key] = []; // add generic relations when no config exists

      Tine.Tinebase.data.RecordMgr.each(function (rec) {
        if (Tine.Tinebase.common.hasRight('run', rec.getMeta('appName')) && ignoreApplications.indexOf(rec.getMeta('appName')) == -1 && rec.getFieldNames().indexOf('relations') > -1 && rec.getRecordName()) {
          items[key].push({
            ownModel: recordClass.getMeta('recordName'),
            relatedApp: rec.getMeta('appName'),
            relatedModel: rec.getMeta('modelName'),
            text: rec.getMeta('modelName') === 'Node' ? rec.getAppName() : rec.getRecordName() + '  (' + rec.getAppName() + ')'
          });
        }
      }); // set to false, so not try again

      if (items[key].length == 0) items[key] = false;
    },

    /**
     * returns the key (appName + modelName)
     * @param {String/Tine.Tinebase.Application} appName
     * @param {String/Tine.Tinebase.data.Record} modelName
     * @return {String}
     */
    getKey: function getKey(appName, modelName) {
      const recordClass = Tine.Tinebase.data.RecordMgr.get(appName, modelName);
      return recordClass ? recordClass.getMeta('appName') + recordClass.getMeta('modelName') : '';
    }
  };
}();

/***/ }),
/* 1361 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.relation');
/**
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.GridRenderer
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @extends     Ext.Component
 */

Tine.widgets.relation.GridRenderer = function (config) {
  Ext.apply(this, config);
  Tine.widgets.relation.GridRenderer.superclass.constructor.call(this);
};

Ext.extend(Tine.widgets.relation.GridRenderer, Ext.Component, {
  appName: null,
  type: null,
  foreignApp: null,
  foreignModel: null,
  relModel: null,
  recordClass: null,

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    Tine.log.debug('Initializing relation renderer with config:');
    Tine.log.debug('appName: ' + this.appName + ', type: ' + this.type + ', foreignApp: ' + this.foreignApp + ', foreignModel: ' + this.foreignModel);
    this.relModel = this.foreignApp + '_Model_' + this.foreignModel;
  },
  render: function render(data, metadata, ownRecord) {
    var relations = ownRecord.get('relations');

    if (!_.get(relations, 'length', 0)) {
      return '';
    }

    if (!this.recordClass) {
      if (!Tine[this.foreignApp] || !Tine[this.foreignApp].Model) {
        Tine.log.warn('Tine.widgets.relation.GridRenderer::render - ForeignApp not found: ' + this.foreignApp);
        return '';
      }

      this.recordClass = Tine[this.foreignApp].Model[this.foreignModel];
    }

    for (var index = 0; index < relations.length; index++) {
      var el = relations[index];

      if (el.type == this.type && el.related_model == this.relModel) {
        if (!el.related_record) {
          return i18n._('No Access');
        }

        var record = new this.recordClass(el.related_record);
        return Ext.util.Format.htmlEncode(record.getTitle());
      }
    }
  }
});

/***/ }),
/* 1362 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.relation');
/**
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.MenuItemManager
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 */

Tine.widgets.relation.MenuItemManager = function () {
  var items = {};
  return {
    /**
     * registers the menuitem. just add the config for this action as item.
     * @param {String} appName
     * @param {String} modelName
     * @param {Object} itemConfig
     */
    register: function register(appName, modelName, itemConfig) {
      var key = appName + modelName;

      if (!items[key]) {
        items[key] = [];
      }

      items[key].push(itemConfig);
    },

    /**
     * returns registered menuitems. add runtime config here.
     * @param {String} appName
     * @param {String} modelName
     * @param {Object} config
     * @return {Array}
     */
    get: function get(appName, modelName, config) {
      var key = appName + modelName;
      var ret = [];

      if (items[key]) {
        Ext.each(items[key], function (item) {
          ret.push(new Ext.Action(Ext.apply({}, item, config)));
        });
      }

      return ret;
    }
  };
}();

/***/ }),
/* 1363 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2012-2018 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.relation');

__webpack_require__(633);
/**
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.GenericPickerGridPanel
 * @extends     Tine.widgets.grid.PickerGridPanel
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 */


Tine.widgets.relation.GenericPickerGridPanel = Ext.extend(Tine.widgets.grid.PickerGridPanel, {
  /**
   * @cfg for PickerGridPanel
   */
  recordClass: Tine.Tinebase.Model.Relation,
  clicksToEdit: 1,
  selectRowAfterAdd: false,

  /**
   * disable Toolbar creation, create a custom one
   * @type Boolean
   */
  enableTbar: false,
  title: null,

  /**
   * the record
   * @type Record
   */
  record: null,

  /**
   *
   * @type {String}
   */
  ownRecordClass: null,

  /**
   * @type Tinebase.Application
   */
  app: null,

  /**
   * The calling EditDialog
   * @type Tine.widgets.dialog.EditDialog
   */
  editDialog: null,

  /**
   * reference to relationPanelRegistry from the editdialog
   * 
   * @type {Array}
   */
  relationPanelRegistry: null,

  /* private */

  /**
   * configuration fetched from registry
   * @type {Object}
   * autoconfig
   */
  possibleRelations: null,

  /**
   * Selects the Model to relate to
   * @type {Ext.form.ComboBox} modelCombo
   */
  modelCombo: null,

  /**
   * Array with searchcombos for each model
   * @type {Array}
   */
  searchCombos: null,

  /**
   * The by the modelcombo activated model
   * @type {String}
   */
  activeModel: null,

  /**
   * Array of possible degrees
   * @type {Array} degreeData
   */
  degreeData: null,

  /**
   * keyfieldConfigs shortcuts
   * @type {Object} keyFieldConfigs
   */
  keyFieldConfigs: null,

  /**
   * constrains config
   * @type {Object} constraintsConfig
   */
  constraintsConfig: null,

  /**
   * @cfg {String} requiredGrant to make actions
   */
  requiredGrant: 'editGrant',

  /**
   * @cfg {Boolean} hideRelatedDegree
   * true to hide the degree column
   */
  hideRelatedDegree: true,

  /**
   * @cfg {Number} pos
   * position 200 = 100 + 100*3 -> means third one after app specific tabs
   */
  pos: 400,

  /* config */
  frame: true,
  border: true,
  autoScroll: true,
  layout: 'fit',
  stateful: true,
  stateId: 'widgets-relation-genereic-picker-grid',
  canonicalName: 'RelationsGrid',

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    this.record = this.editDialog.record;
    this.app = this.editDialog.app;
    this.ownRecordClass = this.editDialog.recordClass;
    this.ignoreRelatedModels = this.editDialog.ignoreRelatedModels ? [].concat(this.editDialog.ignoreRelatedModels) : [];
    this.relationPanelRegistry = this.editDialog.relationPanelRegistry;

    if (this.relationPanelRegistry && this.relationPanelRegistry.length) {
      Ext.each(this.relationPanelRegistry, function (panel) {
        if (panel.relatedPhpModel) {
          this.ignoreRelatedModels.push(panel.relatedPhpModel);
        }
      }, this);
    }

    this.possibleRelations = Tine.widgets.relation.Manager.get(this.app, this.ownRecordClass, this.ignoreRelatedModels);
    this.initTbar();
    this.viewConfig = {
      getRowClass: this.getViewRowClass,
      enableRowBody: true
    };
    this.actionEditInNewWindow = new Ext.Action({
      text: i18n._('Edit record'),
      disabled: true,
      scope: this,
      handler: this.onEditInNewWindow,
      iconCls: 'action_edit'
    });
    this.title = this.i18nTitle = i18n.ngettext('Relation', 'Relations', 50);
    this.on('rowdblclick', this.onEditInNewWindow.createDelegate(this), this);
    this.on('beforecontextmenu', this.onBeforeContextMenu.createDelegate(this), this);
    this.contextMenuItems = [this.actionEditInNewWindow]; // preparing keyfield and constrains configs

    this.keyFieldConfigs = {};
    this.constraintsConfig = {};
    Ext.each(this.app.getRegistry().get('relatableModels'), function (rel) {
      if (rel.ownModel == this.ownRecordClass.getMeta('modelName')) {
        if (rel.keyfieldConfig) {
          if (rel.keyfieldConfig.from == 'foreign') {
            this.keyFieldConfigs[rel.relatedApp + rel.relatedModel] = {
              app: rel.relatedApp,
              name: rel.keyfieldConfig.name
            };
          } else {
            this.keyFieldConfigs[this.app.name + rel.ownModel] = {
              app: this.app.name,
              name: rel.keyfieldConfig.name
            };
          }
        }

        if (rel.config) {
          this.constraintsConfig[rel.relatedApp + rel.relatedModel] = rel.config;
        }
      }
    }, this);
    this.degreeData = [['sibling', i18n._('Sibling')], ['parent', i18n._('Parent')], ['child', i18n._('Child')]];
    this.on('beforeedit', this.onBeforeRowEdit, this);
    this.on('validateedit', this.onValidateRowEdit, this);
    this.on('afteredit', this.onAfterRowEdit, this);
    this.editDialog.on('recordUpdate', this.onRecordUpdate, this);
    this.editDialog.on('load', this.loadRecord, this);
    Tine.widgets.relation.GenericPickerGridPanel.superclass.initComponent.call(this);
    this.selModel.on('selectionchange', function (sm) {
      this.actionEditInNewWindow.setDisabled(sm.getCount() != 1);
    }, this);
    this.store.on('add', this.onAdd, this);
  },

  /**
   * is called from onApplyChanges of the edit dialog per save event
   * 
   * @param {Tine.widgets.dialog.EditDialog} dialog
   * @param {Tine.Tinebase.data.Record} record
   * @return {Boolean}
   */
  onRecordUpdate: function onRecordUpdate(dialog, record) {
    // update from relationsPanel if any
    if (this.isValid()) {
      if (record.data.hasOwnProperty('relations')) {
        Tine.Tinebase.common.assertComparable(record.data.relations);
      }

      var relations = [];
      Ext.each(this.relationPanelRegistry, function (panel) {
        relations = relations.concat(this.getData(panel.store));
      }, this);
      relations = Tine.Tinebase.common.assertComparable(relations.concat(this.getData()));
      record.set('relations', relations);
    } else {
      this.editDialog.loadMask.hide();
      this.editDialog.saving = false;
      return false;
    }
  },

  /**
   * updates the title ot the tab
   * @param {Number} count
   */
  updateTitle: function updateTitle(count) {
    if (!Ext.isNumber(count)) {
      count = 0;
      this.store.each(function (record) {
        if (this.ignoreRelatedModels.indexOf(record.get('related_model')) == -1) {
          count++;
        }
      }, this);
    }

    this.setTitle(this.i18nTitle + ' (' + count + ')');
  },

  /**
   * creates the toolbar
   */
  initTbar: function initTbar() {
    var items = [this.getModelCombo(), ' '];
    items = items.concat(this.createSearchCombos());
    this.tbar = new Ext.Toolbar({
      items: items
    });
  },

  /**
   * adds invalid row class to a invalid row and adds the error qtip
   * 
   * @param {Tine.Tinebase.data.Record} record
   * @param {Integer} index
   * @param {Object} rowParams
   * @param {Ext.data.store} store
   * @scope this.view
   * @return {String}
   */
  getViewRowClass: function getViewRowClass(record, index, rowParams, store) {
    var relatedModel = record.get('related_model').split('_Model_');
    relatedModel = Tine[relatedModel[0]].Model ? Tine[relatedModel[0]].Model[relatedModel[1]] : null;
    var ownModel = record.get('own_model').split('_Model_');
    ownModel = Tine[ownModel[0]].Model ? Tine[ownModel[0]].Model[ownModel[1]] : null;

    if (!ownModel || !relatedModel) {
      // TODO add "no access/app not available" class?
      return '';
    }

    if (this.invalidRowRecords && this.invalidRowRecords.indexOf(record.id) !== -1) {
      rowParams.body = '<div style="height: 19px; margin-top: -19px" ext:qtip="' + String.format(i18n._("The maximum number of {0} with the type \"{1}\" is reached. Please change the type of this relation"), ownModel.getRecordsName(), this.grid.typeRenderer(record.get('type'), null, record)) + '"></div>';
      return 'tine-editorgrid-row-invalid';
    } else if (this.invalidRelatedRecords && this.invalidRelatedRecords.indexOf(record.id) !== -1) {
      rowParams.body = '<div style="height: 19px; margin-top: -19px" ext:qtip="' + String.format(i18n._("The maximum number of {0}s with the type \"{1}\" is reached at the {2} you added. Please change the type of this relation or edit the {2}"), ownModel.getRecordsName(), this.grid.typeRenderer(record.get('type'), null, record), relatedModel.getRecordName()) + '"></div>';
      return 'tine-editorgrid-row-invalid';
    }

    rowParams.body = '';
    return '';
  },

  /**
   * calls the editdialog for the model
   */
  onEditInNewWindow: async function onEditInNewWindow() {
    var _ = window.lodash,
        relation = this.getSelectionModel().getSelected(),
        record = this.getRelatedRecord(relation),
        recordClass = Tine.Tinebase.data.RecordMgr.get(record.appName, record.modelName),
        openMethod = record ? _.get(Tine, record.appName + '.' + record.modelName + 'EditDialog.openWindow') : null;

    if (!record) {
      return;
    } else if (record.get('type') === 'folder') {
      const loadMask = new Ext.LoadMask(this.el, {
        msg: 'Loading ...'
      });
      loadMask.show();
      const nodeData = await Tine.Filemanager.getNode(record.id);
      const nodeRecord = Tine.Tinebase.data.Record.setFromJson(nodeData, Tine.Filemanager.Model.Node);
      var win = Tine.WindowFactory.getWindow({
        width: 1024,
        height: 768,
        name: 'Filemanager',
        noParent: true,
        url: nodeRecord.getSystemLink(),
        modal: false
      });
      loadMask.hide();
      loadMask.destroy();
    } else if (openMethod) {
      openMethod({
        record: record,
        mode: 'remote',
        listeners: {
          update: recordData => {
            const record = Tine.Tinebase.data.Record.setFromJson(recordData, recordClass);
            record.data.relations = null;
            delete record.data.relations;
            relation.set('related_record', record.data);
            relation.commit();
          }
        }
      });
    } else {
      Ext.MessageBox.show({
        buttons: Ext.Msg.OK,
        icon: Ext.MessageBox.WARNING,
        title: i18n._('No Dialog'),
        msg: i18n._("The Record can't be opened. There doesn't exist any dialog for editing this Record!")
      });
    }
  },

  /**
   * create record from recordData
   *
   * @param relationRecord
   * @returns {null|Tine.Tinebase.data.Record}
   */
  getRelatedRecord: function getRelatedRecord(relationRecord) {
    var modelName = relationRecord.get('related_model'),
        recordClass = Tine.Tinebase.data.RecordMgr.get(modelName),
        recordData = relationRecord.get('related_record');

    if (recordData) {
      return Ext.isFunction(window.lodash.get(recordData, 'beginEdit')) ? recordData : Tine.Tinebase.data.Record.setFromJson(recordData, recordClass);
    }

    return null;
  },

  /**
   * is called before context menu is shown
   * adds additional menu items from Tine.widgets.relation.MenuItemManager
   * @param {Tine.widgets.grid.PickerGridPanel} grid
   * @param {Integer} index
   * @return {Boolean}
   */
  onBeforeContextMenu: function onBeforeContextMenu(grid, index) {
    var record = grid.store.getAt(index),
        rm = record.get('related_model');

    if (!rm) {
      return;
    }

    var model = rm.split('_Model_');
    var app = Tine.Tinebase.appMgr.get(model[0]);
    var additionalItems = Tine.widgets.relation.MenuItemManager.get(model[0], model[1], {
      scope: app,
      grid: grid,
      gridIndex: index
    });
    Ext.each(additionalItems, function (item) {
      item.setText(app.i18n._(item.getText()));
      this.contextMenu.add(item);

      if (!this.contextMenu.hasOwnProperty('tempItems')) {
        this.contextMenu.tempItems = [];
      }

      this.contextMenu.tempItems.push(item);
    }, this);
  },

  /**
   * creates the model combo
   * @return {Ext.form.ComboBox}
   */
  getModelCombo: function getModelCombo() {
    if (!this.modelCombo) {
      var data = [];
      var id = 0;
      Ext.each(this.possibleRelations, function (rel) {
        data.push([id, rel.text, rel.relatedApp, rel.relatedModel]);
        id++;
      }, this);
      this.modelCombo = new Ext.form.ComboBox({
        store: new Ext.data.ArrayStore({
          fields: ['id', 'text', 'appName', 'modelName'],
          data: data
        }),
        allowBlank: false,
        forceSelection: true,
        value: data.length > 0 ? data[0][0] : null,
        displayField: 'text',
        valueField: 'id',
        idIndex: 0,
        mode: 'local',
        triggerAction: 'all',
        selectOnFocus: true,
        listeners: {
          scope: this,
          select: this.onModelComboSelect
        }
      });
    }

    return this.modelCombo;
  },

  /**
   * is called on change listener of this.modelCombo
   * 
   * @param {Ext.form.ComboBox} combo the calling combo
   * @param {Ext.data.record} selected the selected record
   * @param {Number} index the selection index
   */
  onModelComboSelect: function onModelComboSelect(combo, selected, index) {
    this.showSearchCombo(selected.get('appName'), selected.get('modelName'));
  },

  /**
   * creates the searchcombos for the models
   * @return {Tine.Tinebase.widgets.form.RecordPickerComboBox}
   */
  createSearchCombos: function createSearchCombos() {
    var sc = [];
    this.searchCombos = {};
    Ext.each(this.possibleRelations, function (rel) {
      var key = rel.relatedApp + rel.relatedModel;
      this.searchCombos[key] = Tine.widgets.form.RecordPickerManager.get(rel.relatedApp, rel.relatedModel, {
        width: 300,
        allowBlank: true,
        listeners: {
          scope: this,
          select: this.onAddRecordFromCombo
        }
      });
      sc.push(this.searchCombos[key]);
      this.searchCombos[key].hide();
    }, this);
    this.showSearchCombo(this.possibleRelations[0].relatedApp, this.possibleRelations[0].relatedModel);
    return sc;
  },

  /**
   * shows the active model searchcombo
   * @param {String} appName
   * @param {String} modelName
   */
  showSearchCombo: function showSearchCombo(appName, modelName) {
    var key = appName + modelName;
    if (this.activeModel) this.searchCombos[this.activeModel].hide();
    this.searchCombos[key].show();
    this.activeModel = appName + modelName;
  },

  /**
   * returns the active search combo
   * @return {}
   */
  getActiveSearchCombo: function getActiveSearchCombo() {
    return this.searchCombos[this.activeModel];
  },

  /**
   * @return Ext.grid.ColumnModel
   * @private
   */
  getColumnModel: function getColumnModel() {
    if (!this.colModel) {
      this.degreeEditor = new Ext.form.ComboBox({
        store: new Ext.data.ArrayStore({
          fields: ['id', 'value'],
          data: this.degreeData
        }),
        allowBlank: false,
        displayField: 'value',
        valueField: 'id',
        mode: 'local'
      });
      this.colModel = new Ext.grid.ColumnModel({
        defaults: {
          sortable: true,
          width: 180
        },
        columns: [{
          id: 'related_model',
          dataIndex: 'related_model',
          header: i18n._('Record'),
          editor: false,
          renderer: this.relatedModelRenderer.createDelegate(this),
          scope: this
        }, {
          id: 'related_record',
          dataIndex: 'related_record',
          header: i18n._('Description'),
          renderer: this.relatedRecordRenderer.createDelegate(this),
          editor: false,
          scope: this
        }, {
          id: 'remark',
          dataIndex: 'remark',
          header: i18n._('Remark'),
          renderer: this.remarkRenderer.createDelegate(this),
          editor: Ext.form.Field,
          scope: this,
          width: 120
        }, {
          id: 'related_degree',
          hidden: this.hideRelatedDegree,
          dataIndex: 'related_degree',
          header: i18n._('Dependency'),
          editor: this.degreeEditor,
          renderer: this.degreeRenderer.createDelegate(this),
          scope: this,
          width: 100
        }, {
          id: 'type',
          dataIndex: 'type',
          renderer: this.typeRenderer.createDelegate(this),
          header: i18n._('Type'),
          scope: this,
          width: 120,
          editor: true
        }, {
          id: 'creation_time',
          dataIndex: 'creation_time',
          editor: false,
          renderer: Tine.Tinebase.common.dateTimeRenderer,
          header: i18n._('Creation Time'),
          width: 140
        }]
      });
    }

    return this.colModel;
  },

  /**
   * creates the special editors
   * @param {} o
   */
  onBeforeRowEdit: function onBeforeRowEdit(o) {
    if (this.readOnly) {
      o.cancel = true;
      return;
    }

    var model = o.record.get('related_model').split('_Model_');
    var app = model[0];
    model = model[1];
    var colModel = o.grid.getColumnModel(); // create editor if values are defined in the constraints config

    switch (o.field) {
      case 'type':
        var editor = null;

        if (this.constraintsConfig[app + model]) {
          editor = this.getTypeEditor(this.constraintsConfig[app + model], this.app);
        } else if (this.keyFieldConfigs[app + model]) {
          editor = new Tine.Tinebase.widgets.keyfield.ComboBox({
            app: app,
            keyFieldName: this.keyFieldConfigs[app + model].name
          });
        }

        if (editor) {
          colModel.config[o.column].setEditor(editor);
        } else {
          colModel.config[o.column].setEditor(null);
        }

        break;

      default:
        return;
    }

    if (colModel.config[o.column].editor) {
      colModel.config[o.column].editor.selectedRecord = null;
    }
  },

  /**
   * returns the type editors for each row in the grid
   * 
   * @param {Object} config
   * @param {Tine.Tinebase.Application}
   * 
   * @return {}
   */
  getTypeEditor: function getTypeEditor(config, app) {
    var data = [['', '-']];
    Ext.each(config, function (c) {
      data.push([c.type.toUpperCase(), app.i18n._hidden(c.text)]);
    });
    return new Ext.form.ComboBox({
      store: new Ext.data.ArrayStore({
        fields: ['id', 'value'],
        data: data
      }),
      allowBlank: true,
      displayField: 'value',
      valueField: 'id',
      mode: 'local',
      constraintsConfig: config,
      listeners: {
        scope: this,
        select: this.onTypeChange
      },
      tpl: '<tpl for="."><div class="x-combo-list-item">{value}&nbsp;</div></tpl>'
    });
  },

  /**
   * is called on type change, sets the relationpickercombos accordingly
   * 
   * @param {Ext.form.ComboBox} combo
   * @param {Tine.Tinebase.data.Record} record
   * @param {Number} index
   */
  onTypeChange: function onTypeChange(combo, record, index) {
    var newType = combo.getValue();
    var oldType = combo.startValue;
    var rp = this.editDialog.relationPickers;

    if (rp && rp.length) {
      var relatedRecord;
      Ext.each(rp, function (picker) {
        // remove record from old combo
        if (picker.relationType == oldType) {
          relatedRecord = picker.combo.selectedRecord;
          picker.clear();
        }
      }, this);
      Ext.each(rp, function (picker) {
        if (picker.relationType == newType) {
          picker.setValue(relatedRecord);
        }
      }, this);
    }
  },

  /**
   * related record renderer
   *
   * @param {Record} value
   * @return {String}
   */
  relatedRecordRenderer: function relatedRecordRenderer(recData, meta, relRec) {
    if (recData === undefined) {
      // record has been removed by acl/area lock/...
      meta.css = 'x-form-empty-field';
      return i18n._('No Access');
    }

    var relm = relRec.get('related_model');

    if (!relm) {
      return '';
    }

    var split = relm.split('_Model_');
    var recordClass = Tine[split[0]].Model[split[1]];
    var record = Tine.Tinebase.data.Record.setFromJson(recData, recordClass);
    var result = '';

    if (recData) {
      result = Ext.util.Format.htmlEncode(record.getTitle());
    }

    return result;
  },

  /**
   * renders the remark
   * @param {String} value
   * @param {Object} row
   * @param {Tine.Tinebase.data.Record} record
   * @return {String}
   */
  remarkRenderer: function remarkRenderer(value, row, record) {
    if (record && record.get('related_model')) {
      var app = Tine.Tinebase.appMgr.get(record.get('related_model').split('_Model_')[0]);
    }

    if (!value) {
      value = '';
    } else if (Ext.isObject(value)) {
      var str = '';
      Ext.iterate(value, function (label, val) {
        str += app.i18n._(Ext.util.Format.capitalize(label)) + ': ' + (Ext.isNumber(val) ? val : Ext.util.Format.capitalize(val)) + ', ';
      }, this);
      value = str.replace(/, $/, '');
    } else if (Ext.isArray(value)) {
      var str = '';
      Ext.each(value, function (val) {
        str += (Ext.isNumber(val) ? val : Ext.util.Format.capitalize(val)) + ', ';
      }, this);
      value = str.replace(/, $/, '');
    } else if (value.match(/^\[.*\]$/)) {
      value = Ext.decode(value);
      return this.remarkRenderer(value);
    }

    return Ext.util.Format.htmlEncode(value);
  },

  /**
   * renders the degree
   * @param {String} value
   * @return {String}
   */
  degreeRenderer: function degreeRenderer(value, metaData, record, rowIndex, colIndex, store) {
    if (!this.degreeDataObject) {
      this.degreeDataObject = {};
      Ext.each(this.degreeData, function (dd) {
        this.degreeDataObject[dd[0]] = dd[1];
      }, this);
    }

    var html = this.degreeDataObject[value] ? i18n._(this.degreeDataObject[value]) : '',
        qtip = null;

    if (value != 'sibling') {
      var relatedRecord = this.getRelatedRecord(record),
          ownTitle = this.record.getTitle(),
          relatedTitle = relatedRecord ? relatedRecord.getTitle() : '',
          path = relatedTitle + '/' + ownTitle;
      qtip = Tine.widgets.path.pathRenderer(path); // TODO make css work

      html = '<div ext:qtip="' + Ext.util.Format.htmlEncode(qtip) + '">' + '<span class="x-tine-relation-degree-value">' + html + '</span></div>';
    }

    return html;
  },

  /**
   * renders the titleProperty of the models
   * @param {String} value
   * @return {String}
   */
  relatedModelRenderer: function relatedModelRenderer(value, meta) {
    if (!value) {
      return '';
    }

    var split = value.split('_Model_');

    if (Tine[split[0]] && Tine[split[0]].Model) {
      var model = Tine[split[0]].Model[split[1]];

      if (model.getPhpClassName() === 'Filemanager_Model_Node') {
        return '<span class="tine-recordclass-gridicon ' + model.getMeta('appName') + model.getMeta('modelName') + '">&nbsp;</span>' + model.getAppName();
      }

      return '<span class="tine-recordclass-gridicon ' + model.getMeta('appName') + model.getMeta('modelName') + '">&nbsp;</span>' + model.getRecordName() + ' (' + model.getAppName() + ')';
    } else {
      meta.css = 'x-form-empty-field';
      return String.format(i18n._("No access to {0}"), split[0]);
    }
  },

  /**
   * renders the type
   * @param {String} value
   * @param {Object} row
   * @param {Tine.Tinebase.data.Record} rec
   * @return {String}
   */
  typeRenderer: function typeRenderer(value, row, rec) {
    if (!rec.get('own_model') || !rec.get('related_model')) {
      return '';
    }

    var o = rec.get('own_model').split('_Model_').join('');
    var f = rec.get('related_model').split('_Model_').join('');
    var renderer = Ext.util.Format.htmlEncode;

    if (this.constraintsConfig[f]) {
      Ext.each(this.constraintsConfig[f], function (c) {
        if (c.type == value) value = this.app.i18n._hidden(c.text);
      }, this);
    } else if (this.keyFieldConfigs[o]) {
      renderer = Tine.Tinebase.widgets.keyfield.Renderer.get(this.keyFieldConfigs[o].app, this.keyFieldConfigs[o].name);
    } else if (this.keyFieldConfigs[f]) {
      renderer = Tine.Tinebase.widgets.keyfield.Renderer.get(this.keyFieldConfigs[f].app, this.keyFieldConfigs[f].name);
    } else {
      // lookup other side
      var _ = window.lodash,
          ownRecordClass = Tine.Tinebase.data.RecordMgr.get(rec.get('own_model')),
          foreignRecordClass = Tine.Tinebase.data.RecordMgr.get(rec.get('related_model')),
          foreignApp = foreignRecordClass ? Tine.Tinebase.appMgr.get(foreignRecordClass.getMeta('appName')) : null,
          foreignRelConfs = foreignApp ? foreignApp.getRegistry().get('relatableModels') : [],
          foreignRelConf = ownRecordClass ? _.find(foreignRelConfs, {
        relatedApp: ownRecordClass.getMeta('appName'),
        relatedModel: ownRecordClass.getMeta('modelName')
      }) : null,
          foreignRelTypeConf = _.find(_.get(foreignRelConf, 'config', []), {
        type: value
      });

      if (foreignRelTypeConf && foreignRelTypeConf.text) {
        value = foreignApp.i18n._hidden(foreignRelTypeConf.text);
      }
    }

    return renderer(value);
  },

  /**
   * returns the default relation values
   * @return {Array}
   */
  getRelationDefaults: function getRelationDefaults() {
    return {
      own_backend: 'Sql',
      related_backend: 'Sql',
      own_id: this.record ? this.record.id : null,
      own_model: this.ownRecordClass.getPhpClassName()
    };
  },

  /**
   * is called when selecting a record in the searchCombo (relationpickercombo)
   */
  onAddRecordFromCombo: async function onAddRecordFromCombo(node) {
    let record = null;
    const pickerCombo = this.getActiveSearchCombo();

    if (pickerCombo.hasOwnProperty('store')) {
      record = pickerCombo.store.getById(pickerCombo.getValue());
    } else {
      if (node.leaf === false) {
        record = await Tine.Filemanager.getNode(node.id);
      } else {
        record = node;
      }
    }

    if (!record) {
      return;
    }

    const relconf = Ext.isArray(this.constraintsConfig[this.activeModel]) ? {
      type: this.constraintsConfig[this.activeModel][0]['type']
    } : {};
    this.onAddRecord(record, relconf);

    if (Ext.isFunction(pickerCombo.collapse)) {
      pickerCombo.collapse();
    }

    if (Ext.isFunction(pickerCombo.reset)) {
      pickerCombo.reset();
    }

    if (Ext.isFunction(pickerCombo.focus)) {
      _.delay(() => {
        pickerCombo.focus();
      }, 250);
    }
  },

  /**
   * call to add relation from an external component
   *
   *  @todo refactor this trash
   *
   * @param {Tine.Tinebase.data.Record} record
   * @param {Object} relconf
   */
  onAddRecord: async function onAddRecord(record, relconf) {
    if (record) {
      if (!relconf) {
        relconf = {};
      }

      if (record.data && record.data.hasOwnProperty('relations')) {
        record.data.relations = null;
        delete record.data.relations;
      }

      const rc = Tine.Tinebase.data.RecordMgr.get(relconf.related_model) || this.getActiveSearchCombo().recordClass;
      const appName = rc.getMeta('appName');
      const model = rc.getMeta('modelName');
      const f = appName + model;

      const type = relconf.type || _.get(this.constraintsConfig, f + '[0].type', ''); // per default the first defined type is used


      const relationRecord = new Tine.Tinebase.Model.Relation(Ext.apply(this.getRelationDefaults(), Ext.apply({
        related_record: record.data || record,
        related_id: record.id,
        related_model: rc.getPhpClassName(),
        type: type,
        related_degree: 'sibling'
      }, relconf)), Tine.Tinebase.data.Record.generateUID());
      let mySideValid = true;

      if (this.constraintsConfig[f]) {
        // validate constrains config from own side
        mySideValid = this.checkLocalConstraints(appName, model, relationRecord, type);
      } // if my side is not valid, it's ok to skip related constraints validation, the relation is marked invalid already


      if (mySideValid) {
        await this.validateRelatedConstrainsConfig(record, relationRecord);
      } else {
        this.onAddNewRelationToStore(relationRecord, record);
      }
    }
  },

  /**
   * validates the constrains of the related record , fetches the relations
   * 
   * @param {Tine.Tinebase.data.Record} record
   * @param {Tine.Tinebase.Model.Relation} relationRecord
   */
  validateRelatedConstrainsConfig: function validateRelatedConstrainsConfig(record, relationRecord) {
    return new Promise((fulfill, reject) => {
      const rc = Tine.Tinebase.data.RecordMgr.get(relationRecord.get('related_model')) || this.getActiveSearchCombo().recordClass;
      var appName = rc.getMeta('appName');
      var model = rc.getMeta('modelName');
      var relatedApp = Tine.Tinebase.appMgr.get(appName);
      var relatedConstrainsConfig = relatedApp.getRegistry().get('relatableModels');
      var ownRecordClassName = this.editDialog.recordClass.getMeta('modelName');
      var relatedRecordProxy = _.get(this.searchCombos, appName + model + '.recordProxy') || Tine[appName][model.toLowerCase() + 'Backend'] || new Tine.Tinebase.data.RecordProxy({
        appName: appName,
        modelName: model,
        recordClass: rc
      });

      if (!Ext.isFunction(record.get)) {
        record = relatedRecordProxy.recordReader({
          responseText: Ext.encode(record)
        });
      }

      if (relatedConstrainsConfig) {
        for (var index = 0; index < relatedConstrainsConfig.length; index++) {
          var rcc = relatedConstrainsConfig[index];

          if (rcc.relatedApp == this.app.name && rcc.relatedModel == ownRecordClassName) {
            var myRelatedConstrainsConfig = rcc;
            break;
          }
        }
      } // validate constrains config from other side if a config exists


      if (myRelatedConstrainsConfig) {
        // if relations hasn't been fetched already, fetch them now
        if (!Ext.isArray(record.data.relations) || record.data.relations.length === 0) {
          relatedRecordProxy.loadRecord(record, {
            scope: this,
            success: function success(record) {
              // if record has relations, validate each relation
              if (Ext.isArray(record.get('relations')) && record.get('relations').length > 0) {
                this.onValidateRelatedConstrainsConfig(myRelatedConstrainsConfig.config, relationRecord, appName, model, record);
              } else {
                // if there aren't any relations, no validation is needed
                this.onAddNewRelationToStore(relationRecord, record);
              }

              fulfill();
            },
            // don't break on failure, use given record instead
            failure: function failure() {
              this.onAddNewRelationToStore.createDelegate(this, [relationRecord, record]);
              fulfill();
            }
          });
        } else {
          this.onValidateRelatedConstrainsConfig(myRelatedConstrainsConfig.config, relationRecord, appName, model, record);
          fulfill();
        }
      } else {
        this.onAddNewRelationToStore(relationRecord, record);
        fulfill();
      }
    });
  },

  /**
   * validates the constrains of the related record after fetching relations
   * 
   * @param {Object} constraintsConfig
   * @param {Tine.Tinebase.Model.Relation} relationRecord
   * @param {String} relatedAppName
   * @param {String} relatedModelName
   * @param {Tine.Tinebase.data.Record} record
   */
  onValidateRelatedConstrainsConfig: function onValidateRelatedConstrainsConfig(constraintsConfig, relationRecord, relatedAppName, relatedModelName, record) {
    var invalid = false;
    Ext.each(constraintsConfig, function (conf) {
      if (conf.hasOwnProperty('max') && conf.max > 0 && conf.type == relationRecord.get('type')) {
        var rr = record.get('relations'),
            count = 0;

        for (var index = 0; index < rr.length; index++) {
          if (rr[index].type == conf.type) {
            count++;
          }
        }

        if (count >= conf.max) {
          if (!this.view) {
            this.view = {};
          }

          if (!this.view.invalidRelatedRecords) {
            this.view.invalidRelatedRecords = [];
          }

          this.view.invalidRelatedRecords.push(relationRecord.id);
          invalid = true;
        }
      }
    }, this);

    if (!invalid && Ext.isArray(this.view.invalidRelatedRecords)) {
      var index = this.view.invalidRelatedRecords.indexOf(record.getId());

      if (index > -1) {
        this.view.invalidRelatedRecords.splice(index, 1);
      }
    }

    this.onAddNewRelationToStore(relationRecord, record);
  },

  /**
   * Is called after all validation is done
   * 
   * @param {Tine.Tinebase.Model.Relation} relationRecord
   * @param {Tine.Tinebase.data.Record} record
   */
  onAddNewRelationToStore: function onAddNewRelationToStore(relationRecord, record) {
    var _ = window.lodash;

    if (_.get(relationRecord, 'data.related_record.relations', false)) {
      relationRecord.data.related_record.relations = null;
      delete relationRecord.data.related_record.relations;
    }

    if (this.relationCheck(relationRecord)) {
      Tine.log.debug('Adding new relation:');
      Tine.log.debug(relationRecord);
      this.store.add([relationRecord]);
    }

    this.view.refresh();
  },

  /**
   * checks if record to add is already linked or is the same record
   * @param {Tine.Tinebase.data.Record} recordToAdd
   * @param {String} relatedModel
   * @return {Boolean}
   */
  relationCheck: function relationCheck(recordToAdd, relatedModel) {
    var duplicateIdx = Tine.Tinebase.Model.Relation.findDuplicate(this.store, recordToAdd),
        duplicateIsSelf = this.store.getAt(duplicateIdx) == recordToAdd,
        add = !duplicateIsSelf;

    if (duplicateIdx >= 0 && !duplicateIsSelf) {
      Ext.MessageBox.show({
        title: i18n._('Failure'),
        msg: i18n._('The record you tried to link is already linked. Please edit the existing link.'),
        buttons: Ext.MessageBox.OK,
        icon: Ext.MessageBox.INFO
      });
      add = false;
      return false;
    } // don't allow to relate itself


    if (this.ownRecordClass.getMeta('phpClassName') == relatedModel && recordToAdd.getId() == this.editDialog.record.getId()) {
      Ext.MessageBox.show({
        title: i18n._('Failure'),
        msg: i18n._('You tried to link a record with itself. This is not allowed!'),
        buttons: Ext.MessageBox.OK,
        icon: Ext.MessageBox.ERROR
      });
      add = false;
    }

    return add;
  },

  /**
   * is called after a row has been edited
   * @param {Object} o
   */
  onAfterRowEdit: function onAfterRowEdit(o) {
    this.onUpdate(o.grid.store, o.record);
    this.view.refresh();
  },

  /**
   * validates constrains config, is called after row edit
   * @param {Object} o
   */
  onValidateRowEdit: function onValidateRowEdit(o) {
    if (o.field === 'type') {
      var index = -1;
      this.store.remove(o.record.getId());
      this.removeFromInvalidRelatedRecords(o.record);
      this.removeFromInvalidRowRecords(o.record);
      var model = o.record.get('related_model').split('_Model_');
      var app = model[0];
      model = model[1]; // check constrains from own_record side

      if (this.constraintsConfig[app + model]) {
        this.checkLocalConstraints(app, model, o.record, o.value, o.originalValue);
      } // check constrains from other side


      this.validateRelatedConstrainsConfig(o.record.get('related_record'), o.record, true);
    }

    return true;
  },

  /**
   * Checks local relation constraints
   * 
   * @param {} app
   * @param {} model
   * @param {} checkRecord
   * @param {} type
   * @param {} oldType
   * 
   * @return {Bool}
   */
  checkLocalConstraints: function checkLocalConstraints(app, model, checkRecord, type, oldType) {
    // remove itself at first
    if (!this.view.invalidRowRecords) {
      this.view.invalidRowRecords = [];
    }

    var retVal = true;
    this.view.invalidRowRecords.remove(checkRecord.get('id'));
    Ext.each(this.constraintsConfig[app + model], function (conf) {
      // check new value
      if (conf.max && conf.max > 0 && conf.type == type) {
        var resNew = this.store.queryBy(function (record, id) {
          if (type == record.get('type') && record.get('related_model') == app + '_Model_' + model) {
            return true;
          } else {
            return false;
          }
        }, this); // add all record ids to invalidRecords, if maximum is reached

        if (resNew.getCount() >= conf.max) {
          resNew.each(function (item) {
            if (this.view.invalidRowRecords.indexOf(item.id) === -1) {
              this.view.invalidRowRecords.push(item.id);
              retVal = false;
            }
          }, this);

          if (this.view.invalidRowRecords.indexOf(checkRecord.id) === -1) {
            this.view.invalidRowRecords.push(checkRecord.id);
            retVal = false;
          }
        }
      }

      if (oldType) {
        this.checkOldValidations(app, model, checkRecord, oldType);
      }
    }, this);
    return retVal;
  },

  /**
   * checks existing relation constraints
   * 
   * @param {} app
   * @param {} model
   * @param {} checkRecord
   * @param {} type
   */
  checkOldValidations: function checkOldValidations(app, model, checkRecord, type) {
    // check old value if given
    var configs = this.constraintsConfig[app + model];

    if (configs) {
      for (var index = 0; index < configs.length; index++) {
        var conf = configs[index];

        if (conf.hasOwnProperty('max') && conf.max > 0 && conf.type == type) {
          var resOld = this.store.queryBy(function (record, id) {
            if (type == record.get('type') && record.get('related_model') == app + '_Model_' + model) {
              return true;
            } else {
              return false;
            }
          }, this);

          if (this.view.hasOwnProperty('invalidRowRecords') && Ext.isArray(this.view.invalidRowRecords)) {
            if (resOld.getCount() - 1 <= conf.max) {
              resOld.each(function (item) {
                this.view.invalidRowRecords.remove(item.id);
              }, this);
            }
          }
        }
      }
    }

    this.view.refresh();
  },

  /**
   * removes a record from invalid records array
   * 
   * @param {Tine.Tinebase.data.Record} record
   */
  removeFromInvalidRelatedRecords: function removeFromInvalidRelatedRecords(record) {
    if (Ext.isArray(this.view.invalidRelatedRecords)) {
      var index = this.view.invalidRelatedRecords.indexOf(record.id);

      if (index > -1) {
        this.view.invalidRelatedRecords.splice(index, 1);
      }
    }
  },

  /**
   * removes a record from invalid records array
   * 
   * @param {Tine.Tinebase.data.Record} record
   */
  removeFromInvalidRowRecords: function removeFromInvalidRowRecords(record) {
    if (Ext.isArray(this.view.invalidRowRecords)) {
      var index = this.view.invalidRowRecords.indexOf(record.id);

      if (index > -1) {
        this.view.invalidRowRecords.splice(index, 1);
      }
    }
  },

  /**
   * is called when a record is added to the store
   * @param {Ext.data.SimpleStore} store
   * @param {Array} records
   */
  onAdd: function onAdd(store, records) {
    Ext.each(records, function (record) {
      Ext.each(this.editDialog.relationPickers, function (picker) {
        if (record.get('related_record') && picker.relationType == record.get('type') && record.get('related_id') != picker.getValue() && picker.fullModelName == record.get('related_model')) {
          var split = picker.fullModelName.split('_Model_');
          picker.combo.selectedRecord = new Tine[split[0]].Model[split[1]](record.get('related_record'));
          picker.combo.startRecord = new Tine[split[0]].Model[split[1]](record.get('related_record'));
          picker.combo.setValue(picker.combo.selectedRecord);
          picker.combo.startValue = picker.combo.selectedRecord.get(this.recordClass.getMeta('idProperty'));
        }
      }, this);
    }, this);
  },

  /**
   * is called when a record in the grid changes
   * @param {Ext.data.SimpleStore} store
   * @param {} record
   */
  onUpdate: function onUpdate(store, record) {
    store.each(function (record) {
      Ext.each(this.editDialog.relationPickers, function (picker) {
        if (picker.relationType == record.get('type') && picker.fullModelName == record.get('related_model')) {
          picker.setValue(record.get('related_record'));
        }
      }, this);
    }, this);
    this.updateTitle();
  },

  /**
   * populate store and set record
   * @param {Record} record
   */
  loadRecord: function loadRecord(dialog, record, ticketFn) {
    var _ = window.lodash,
        me = this,
        interceptor = ticketFn(),
        evalGrants = dialog.evalGrants,
        hasRequiredGrant = !evalGrants || _.get(record, record.constructor.getMeta('grantsPath') + '.' + this.requiredGrant);

    this.store.removeAll();

    var relations = _.get(record, 'data.relations');

    if (relations) {
      this.loadRelations(relations, interceptor);
    } else {
      Tine.Tinebase.getRelations('Calendar_Model_Event', record.get('id'), null, [], null, function (response, request) {
        if (response) {
          me.loadRelations(response.results, interceptor);
        }
      }.createDelegate(this));
    }

    this.setReadOnly(!hasRequiredGrant);
  },
  loadRelations: function loadRelations(relations, interceptor) {
    if (relations && relations.length > 0) {
      var relationRecords = [];
      Ext.each(relations, function (relation) {
        if (this.ignoreRelatedModels) {
          if (relation.hasOwnProperty('related_model') && this.ignoreRelatedModels.indexOf(relation.related_model) == -1) {
            relationRecords.push(new Tine.Tinebase.Model.Relation(relation, relation.id));
          }
        } else {
          relationRecords.push(new Tine.Tinebase.Model.Relation(relation, relation.id));
        }
      }, this);
      this.store.add(relationRecords); // sort by creation time

      this.store.sort('creation_time', 'DESC');
      this.updateTitle();
    } else {
      this.updateTitle(0);
    } // add other listeners after population


    if (this.store) {
      this.store.on('update', this.onUpdate, this);
      this.store.on('add', this.updateTitle, this);
      this.store.on('remove', function (store, records, index) {
        Ext.each(records, function (record) {
          Ext.each(this.editDialog.relationPickers, function (picker) {
            if (picker.relationType == record.get('type') && record.get('related_id') == picker.getValue() && picker.fullModelName == record.get('related_model')) {
              picker.clear();
            }
          }, this);
        }, this);
        this.updateTitle();
      }, this);
    }

    interceptor();
  },

  /**
   * remove handler
   * 
   * @param {} button
   * @param {} event
   */
  onRemove: function onRemove(button, event) {
    var selectedRows = this.getSelectionModel().getSelections();

    for (var index = 0; index < selectedRows.length; index++) {
      var split = selectedRows[index].get('related_model').split('_Model_');
      this.checkOldValidations(split[0], split[1], selectedRows[index], selectedRows[index].get('type'));
      this.removeFromInvalidRowRecords(selectedRows[index]);
      this.removeFromInvalidRelatedRecords(selectedRows[index]);
    }

    Tine.widgets.relation.GenericPickerGridPanel.superclass.onRemove.call(this, button, event);
  },

  /**
   * checks if there are invalid relations
   * @return {Boolean}
   */
  isValid: function isValid() {
    if (this.view) {
      if (this.view.hasOwnProperty('invalidRowRecords') && this.view.invalidRowRecords.length > 0) {
        return false;
      }

      if (this.view.hasOwnProperty('invalidRelatedRecords') && this.view.invalidRelatedRecords.length > 0) {
        return false;
      }
    }

    return true;
  },

  /**
   * get relations data as array
   * 
   * @param store if no store is given, this.store will be iterated
   * @return {Array}
   */
  getData: function getData(store) {
    store = store ? store : this.store;
    var relations = [];
    store.each(function (record) {
      if (record.data.related_record) {
        record.data.related_record.relations = null;
        record.data.related_record.relation = null;
        delete record.data.related_record.relations;
        delete record.data.related_record.relation;
      }

      relations.push(record.data);
    }, this);
    return relations;
  }
});

/***/ }),
/* 1364 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var util_waitFor_es6__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3);
/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2020-2020 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

Ext.ns('Tine.widgets.relation');
/**
 * related model specific picker grid
 *
 * acts as a 'mirror' of the GenericPickerGridPanel for _one_ related model of _one_ relation_type and _one_ relation_degree
 *
 * @TODO respect relation constraints
 */

Tine.widgets.relation.PickerGridPanel = Ext.extend(Tine.widgets.grid.PickerGridPanel, {
  /**
   * @cfg {Tine.widgets.dialog.EditDialog}
   */
  editDialog: null,

  /**
   * record class of related record
   *
   * @cfg {Tine.Tinebase.data.Record} recordClass
   */
  recordClass: null,

  /**
   * relation degree of the relation
   * @cfg {String} relationType
   */
  relationDegree: 'sibling',

  /**
   * relation type of the relation
   * @cfg {String} relationType
   */
  relationType: null,
  // private
  suspendOwnStoreEvents: false,
  suspendRelationStoreEvents: false,
  initComponent: function initComponent() {
    if (!this.app && this.recordClass) {
      this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
    }

    this.ownRecordIdProp = this.recordClass.getMeta('idProperty');
    this.asyncInit();
    this.supr().initComponent.call(this);
  },
  asyncInit: async function asyncInit() {
    await Object(util_waitFor_es6__WEBPACK_IMPORTED_MODULE_0__[/* default */ "a"])(() => {
      return this.editDialog.relationsPanel;
    });
    this.store.on('add', this.onOwnStoreAdd, this);
    this.store.on('update', this.onOwnStoreUpdate, this);
    this.store.on('remove', this.onOwnStoreRemove, this);
    this.editDialog.relationsPanel.store.on('add', this.onRelationStoreAdd, this);
    this.editDialog.relationsPanel.store.on('update', this.onRelationStoreUpdate, this);
    this.editDialog.relationsPanel.store.on('remove', this.onRelationStoreRemove, this); // question: are related record updates persistent before dlg is saved?
    // changes are reflected imideatily
    // new record are created after record save // this might be hard to implement?
  },
  onOwnStoreAdd: function onOwnStoreAdd(store, records, idx) {
    if (!this.suspendOwnStoreEvents) {
      _.each(records, record => {
        const existingRelation = this.getRelation(record);

        if (existingRelation) {
          this.onOwnStoreUpdate(store, record, 'UPDATE');
        } else {
          this.withSuspendedRelationStoreEvents(async () => {
            await this.editDialog.relationsPanel.onAddRecord(records[0], {
              type: this.relationType,
              related_model: this.recordClass.getPhpClassName(),
              related_degree: this.relationDegree
            });
          });
        }
      });
    }
  },
  onOwnStoreUpdate: function onOwnStoreUpdate(store, record, operation) {
    // NOTE: we're dealing with relations - we don't want to have the relation of the relations!
    record.data.relations = null;
    delete record.data.relations;

    if (!this.suspendOwnStoreEvents) {
      const relation = this.getRelation(record);
      this.withSuspendedRelationStoreEvents(() => {
        relation.set('related_record', record.data);
        relation.commit();
      });
    }
  },
  onOwnStoreRemove: function onOwnStoreRemove(store, record, idx) {
    if (!this.suspendOwnStoreEvents) {
      this.editDialog.relationsPanel.store.remove(this.getRelation(record));
    }
  },
  onRelationStoreAdd: function onRelationStoreAdd(store, relations, idx) {
    if (!this.suspendRelationStoreEvents) {
      _.each(relations, relation => {
        if (this.isMyRelationKind(relation)) {
          const record = Tine.Tinebase.data.Record.setFromJson(relation.get('related_record'), this.recordClass);

          if (!this.store.getById(record.getId())) {
            this.withSuspendedOwnStoreEvents(() => {
              this.store.add(record);
            });
          } else {
            this.onRelationStoreUpdate(store, relation, 'UPDATE');
          }
        }
      });
    }
  },
  onRelationStoreUpdate: function onRelationStoreUpdate(store, relation, operation) {
    if (!this.suspendRelationStoreEvents) {
      if (this.isMyRelationKind(relation)) {
        const record = Tine.Tinebase.data.Record.setFromJson(relation.get('related_record'), this.recordClass);
        const existingRecord = this.store.getById(record.getId());

        if (existingRecord) {
          this.withSuspendedOwnStoreEvents(() => {
            const idx = this.store.indexOf(record);
            this.store.remove(existingRecord);
            this.store.insert(idx, [record]);
          });
        } else {
          this.onRelationStoreAdd(store, [relation], this.store.getCount());
        }
      }
    }
  },
  onRelationStoreRemove: function onRelationStoreRemove(store, relation, idx) {
    if (!this.suspendRelationStoreEvents) {
      if (this.isMyRelationKind(relation)) {
        const record = Tine.Tinebase.data.Record.setFromJson(relation.get('related_record'), this.recordClass);
        const existingRecord = this.store.getById(record.getId());

        if (existingRecord) {
          this.withSuspendedOwnStoreEvents(() => {
            this.store.remove(existingRecord);
          });
        }
      }
    }
  },
  withSuspendedOwnStoreEvents: async function withSuspendedOwnStoreEvents(fn) {
    const current = this.suspendOwnStoreEvents;
    this.suspendOwnStoreEvents = true;
    await fn();
    this.suspendOwnStoreEvents = current;
  },
  withSuspendedRelationStoreEvents: async function withSuspendedRelationStoreEvents(fn) {
    const current = this.suspendRelationStoreEvents;
    this.suspendRelationStoreEvents = true;
    await fn();
    this.suspendRelationStoreEvents = current;
  },
  isMyRelationKind: function isMyRelationKind(relation) {
    return relation.get('type') === this.relationType && relation.get('related_degree') === this.relationDegree && relation.get('related_model') === this.recordClass.getPhpClassName();
  },
  // @TODO move to relationsPanel - also needed by picker
  getRelation: function getRelation(record) {
    const idx = this.editDialog.relationsPanel.store.findBy(relation => {
      if (this.isMyRelationKind(relation)) {
        const relatedRecord = relation.get('related_record');

        const relatedRecordId = _.get(relatedRecord, 'data.' + this.ownRecordIdProp, _.get(relatedRecord, this.ownRecordIdProp));

        return relatedRecordId === record.getId();
      }
    });
    return this.editDialog.relationsPanel.store.getAt(idx);
  }
});
Ext.reg('tinerelationpickergridpanel', Tine.widgets.relation.PickerGridPanel);

/***/ }),
/* 1365 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2013 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.printer');
/**
 * @namespace   Tine.widgets.printer
 * @class       Tine.widgets.printer.RecordRenderer
 * @author      Stefanie Stamer <s.stamer@metaways.de>
 */

Tine.widgets.printer.fieldRenderer = function (appName, record, fieldValue, label) {
  var html = '',
      app = Tine.Tinebase.appMgr.get(appName),
      value = fieldValue ? fieldValue : '';
  html = '<span class="rp-print-single-label">' + app.i18n._(label) + '</span><span class="rp-print-single-value">' + value + '</span>';
  return html;
};

Tine.widgets.printer.fieldsRenderer = function (appName, record, fieldName) {
  var html = '';
  Ext.each(fieldName, function (field) {
    html += '<div class="rp-print-single-details-row">' + '<span class="rp-print-single-value">' + field + '</span>' + '</div>';
  }, this);
  return html;
};

Tine.widgets.printer.headerRenderer = function () {
  return '<div class="rp-print-single-logo"><img src="' + Tine.installLogo + '"></div>';
};

/***/ }),
/* 1366 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * tine 2.0 app grid panel widget
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.GridPanel
 * @extends     Ext.Panel
 * 
 * <p>Application Grid Panel</p>
 * <p>
 * </p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * @param       {Object} config
 * @constructor
 * Create a new GridPanel
 */

Tine.widgets.grid.GridPanel = function (config) {
  Ext.apply(this, config);
  this.gridConfig = this.gridConfig || {};
  this.defaultSortInfo = this.defaultSortInfo || {};
  this.defaultPaging = this.defaultPaging || {
    start: 0,
    limit: 50
  }; // allow to initialize with string

  this.recordClass = Tine.Tinebase.data.RecordMgr.get(this.recordClass);

  if (!this.app && this.recordClass) {
    this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
  } // autogenerate stateId


  if (this.stateful !== false && !this.stateId) {
    this.stateId = this.recordClass.getMeta('appName') + '-' + this.recordClass.getMeta('recordName') + '-GridPanel';
  }

  if (this.stateId && Ext.isTouchDevice) {
    this.stateId = this.stateId + '-Touch';
  }

  Tine.widgets.grid.GridPanel.superclass.constructor.call(this);
};

Ext.extend(Tine.widgets.grid.GridPanel, Ext.Panel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   * instance of the app object (required)
   */
  app: null,

  /**
   * @cfg {Boolean} asAdminModule is the panel in an admin context? this is passed to the edit dialog, too
   */
  asAdminModule: false,

  /**
   * @cfg {Object} gridConfig
   * Config object for the Ext.grid.GridPanel
   */
  gridConfig: null,

  /**
   * @cfg {Array} customColumnData
   * Config Array for customizing column model columns
   */
  customColumnData: null,

  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,

  /**
   * @cfg {Ext.data.DataProxy} recordProxy
   */
  recordProxy: null,

  /**
   * @cfg {Tine.widgets.grid.FilterToolbar} filterToolbar
   */
  filterToolbar: null,

  /**
   * @cfg {Boolean} evalGrants
   * should grants of a grant-aware records be evaluated (defaults to true)
   */
  evalGrants: true,

  /**
   * @cfg {Boolean} filterSelectionDelete
   * is it allowed to deleteByFilter?
   */
  filterSelectionDelete: false,

  /**
   * @cfg {Object} defaultSortInfo
   */
  defaultSortInfo: null,

  /**
   * @cfg {Object} storeRemoteSort
   */
  storeRemoteSort: true,

  /**
   * @cfg {Boolean} usePagingToolbar 
   */
  usePagingToolbar: true,

  /**
   * @cfg {Object} defaultPaging 
   */
  defaultPaging: null,

  /**
   * @cfg {Object} pagingConfig
   * additional paging config
   */
  pagingConfig: null,

  /**
   * @cfg {Tine.widgets.grid.DetailsPanel} detailsPanel
   * if set, it becomes rendered in region south 
   */
  detailsPanel: null,

  /**
   * @cfg {Array} i18nDeleteQuestion 
   * spechialised strings for deleteQuestion
   */
  i18nDeleteQuestion: null,

  /**
   * @cfg {String} i18nAddRecordAction 
   * spechialised strings for add action button
   */
  i18nAddActionText: null,

  /**
   * @cfg {String} i18nEditRecordAction 
   * specialised strings for edit action button
   */
  i18nEditActionText: null,

  /**
   * @cfg {String} i18nMoveActionText
   * specialised strings for move action button
   */
  i18nMoveActionText: null,

  /**
   * @cfg {Array} i18nDeleteRecordAction 
   * specialised strings for delete action button
   */
  i18nDeleteActionText: null,

  /**
   * Tree panel referenced to this gridpanel
   */
  treePanel: null,

  /**
   * if this resides in a editDialog, this property holds it
   * if it is so, the grid can't save records itsef, just update
   * the editDialogs record property holding these records
   * 
   * @cfg {Tine.widgets.dialog.EditDialog} editDialog
   */
  editDialog: null,

  /**
   * if this resides in an editDialog, this property defines the 
   * property of the record of the editDialog, holding these records
   * 
   * @type {String} editDialogRecordProperty
   */
  editDialogRecordProperty: null,

  /**
   * config passed to edit dialog to open from this grid
   * 
   * @cfg {Object} editDialogConfig
   */
  editDialogConfig: null,

  /**
   * the edit dialog class to open from this grid
   * 
   * @cfg {String} editDialogClass
   */
  editDialogClass: null,

  /**
   * @cfg {String} i18nEmptyText 
   */
  i18nEmptyText: null,

  /**
   * @cfg {String} newRecordIcon 
   * icon for adding new records button
   */
  newRecordIcon: null,

  /**
   * @cfg {Boolean} i18nDeleteRecordAction 
   * update details panel if context menu is shown
   */
  updateDetailsPanelOnCtxMenu: true,

  /**
   * @cfg {Number} autoRefreshInterval (seconds)
   */
  autoRefreshInterval: 300,

  /**
   * @cfg {Boolean} hasFavoritesPanel 
   */
  hasFavoritesPanel: true,

  /**
   * @cfg {Boolean} hasQuickSearchFilterToolbarPlugin 
   */
  hasQuickSearchFilterToolbarPlugin: true,

  /**
   * display selections helper on paging tb
   * @cfg {Boolean} displaySelectionHelper
   */
  displaySelectionHelper: true,

  /**
   * disable 'select all pages' in paging toolbar
   * @cfg {Boolean} disableSelectAllPages
   */
  disableSelectAllPages: false,

  /**
   * enable if records should be multiple editable
   * @cfg {Boolean} multipleEdit
   */
  multipleEdit: false,

  /**
   * set if multiple edit requires special right
   * @type {String}  multipleEditRequiredRight
   */
  multipleEditRequiredRight: null,

  /**
   * enable if selection of 2 records should allow merging
   * @cfg {Boolean} duplicateResolvable
   */
  duplicateResolvable: false,

  /**
   * @property autoRefreshTask
   * @type Ext.util.DelayedTask
   */
  autoRefreshTask: null,

  /**
   * @type Boolean
   * @property updateOnSelectionChange
   */
  updateOnSelectionChange: true,

  /**
   * @type Boolean
   * @property copyEditAction
   * 
   * TODO activate this by default
   */
  copyEditAction: false,

  /**
   * @cfg {Boolean} moveAction
   * activate moveAction
   */
  moveAction: true,

  /**
   * disable delete confirmation by default
   *
   * @type Boolean
   * @property disableDeleteConfirmation
   */
  disableDeleteConfirmation: false,

  /**
   * @type Ext.Toolbar
   * @property actionToolbar
   */
  actionToolbar: null,

  /**
   * @type Ext.ux.grid.PagingToolbar
   * @property pagingToolbar
   */
  pagingToolbar: null,

  /**
   * @type Ext.Menu
   * @property contextMenu
   */
  contextMenu: null,

  /**
   * @property lastStoreTransactionId 
   * @type String
   */
  lastStoreTransactionId: null,

  /**
   * @property editBuffer  - array of ids of records edited since last explicit refresh
   * @type Array of ids
   */
  editBuffer: null,

  /**
   * @property deleteQueue - array of ids of records currently being deleted
   * @type Array of ids
   */
  deleteQueue: null,

  /**
   * configuration object of model from application starter
   * @type object
   */
  modelConfig: null,

  /**
   * group grid by this property
   * 
   * @type {String}
   */
  groupField: null,

  /**
   * header template for the grouping view, if needed
   * 
   * @type String
   */
  groupTextTpl: null,

  /**
   * cols to exclude
   *
   * @type String[]
   * @cfg hideColumns
   */
  hideColumns: null,

  /**
   * @property selectionModel
   * @type Tine.widgets.grid.FilterSelectionModel
   */
  selectionModel: null,

  /**
   * add records from other applications using the split add button
   * - activated by default
   * 
   * @type Boolean
   * @property splitAddButton
   */
  splitAddButton: true,

  /**
   * do initial load (by loading default favorite) after render
   *
   * @type Boolean
   */
  initialLoadAfterRender: true,

  /**
   * add "create new record" button
   * 
   * @type Boolean
   * @property addButton
   */
  addButton: true,
  layout: 'border',
  border: false,
  stateful: true,
  stateIdSuffix: '',

  /**
   * Makes the grid readonly, this means, no dialogs, no actions, nothing else than selection, no dbclick
   */
  readOnly: false,

  /**
   * extend standard initComponent chain
   * 
   * @private
   */
  initComponent: function initComponent() {
    // init some translations
    this.i18nRecordName = this.i18nRecordName ? this.i18nRecordName : this.recordClass.getRecordName();
    this.i18nRecordsName = this.i18nRecordsName ? this.i18nRecordsName : this.recordClass.getRecordsName();
    this.i18nContainerName = this.i18nContainerName ? this.i18nContainerName : this.recordClass.getContainerName();
    this.i18nContainersName = this.i18nContainersName ? this.i18nContainersName : this.recordClass.getContainersName();
    this.i18nEmptyText = this.i18nEmptyText || this.i18nContainersName ? String.format(i18n._("There could not be found any {0}. Please try to change your filter-criteria, view-options or the {1} you search in."), this.i18nRecordsName, this.i18nContainersName ? this.i18nContainersName : this.i18nRecordsName) : String.format(i18n._("There could not be found any {0}. Please try to change your filter-criteria, view-options or change the module you search in."), this.i18nRecordsName);
    this.i18nEditActionText = this.i18nEditActionText ? this.i18nEditActionText : [String.format(i18n.ngettext('Edit {0}', 'Edit {0}', 1), this.i18nRecordName), String.format(i18n.ngettext('Edit {0}', 'Edit {0}', 2), this.i18nRecordsName)];
    this.editDialogConfig = this.editDialogConfig || {};
    this.editBuffer = [];
    this.deleteQueue = [];
    this.hideColumns = this.hideColumns || []; // init generic stuff

    if (this.modelConfig) {
      this.initGeneric();
    }

    this.initFilterPanel();
    this.bufferedLoadGridData = Function.createBuffered(this.loadGridData, 100, this);
    this.initStore();
    this.initGrid(); // init actions

    this.actionUpdater = new Tine.widgets.ActionUpdater({
      recordClass: this.recordClass,
      evalGrants: this.evalGrants
    });

    if (!this.readOnly) {
      this.initActions();
    }

    this.initLayout(); // for some reason IE looses split height when outer layout is layouted

    if (Ext.isIE6 || Ext.isIE7) {
      this.on('show', function () {
        if (this.layout.rendered && this.detailsPanel) {
          var height = this.detailsPanel.getSize().height;
          this.layout.south.split.setCurrentSize(height);
        }
      }, this);
    }

    if (this.detailsPanel) {
      this.on('resize', this.onContentResize, this, {
        buffer: 100
      });
    }

    if (this.listenMessageBus) {
      this.initMessageBus();
    }

    Tine.widgets.grid.GridPanel.superclass.initComponent.call(this);
  },
  onDestroy: function onDestroy() {
    _.each(this.postalSubscriptions, subscription => {
      subscription.unsubscribe();
    });

    return this.supr().onDestroy.call(this);
  },
  initMessageBus: function initMessageBus() {
    this.postalSubscriptions = [];
    this.postalSubscriptions.push(postal.subscribe({
      channel: "recordchange",
      topic: [this.recordClass.getMeta('appName'), this.recordClass.getMeta('modelName'), '*'].join('.'),
      callback: this.onRecordChanges.createDelegate(this)
    }));
  },

  getRecordByData(data) {
    const idProperty = this.recordClass.getMeta('idProperty');
    return this.store.getById(_.get(data, idProperty));
  },

  /**
   * bus notified about record changes
   */
  onRecordChanges: function onRecordChanges(data, e) {
    var existingRecord = this.getRecordByData(data);

    if (e.topic.match(/\.create/)) {
      this.onCreateRecord(data);
    } else if (existingRecord && e.topic.match(/\.update/)) {
      // NOTE: local mode saves again (and again...)
      this.onUpdateRecord(JSON.stringify(data)
      /*, 'local'*/
      );
    } else if (existingRecord && e.topic.match(/\.delete/)) {
      this.store.remove(existingRecord);
    } else {
      // we can't evaluate the filters on client side to check compute if this affects us
      // so just lets reload
      this.bufferedLoadGridData({
        removeStrategy: 'keepBuffered'
      });
    } // NOTE: grid doesn't update selections itself


    this.actionUpdater.updateActions(this.grid.getSelectionModel(), this.getFilteredContainers());
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    var pathSegment = '';

    if (this.canonicalName) {
      // simple segment e.g. when used in a dialog
      pathSegment = this.canonicalName;
    } else if (this.recordClass) {
      // auto segment
      pathSegment = [this.recordClass.getMeta('modelName'), 'Grid'].join(Tine.Tinebase.CanonicalPath.separator);
    }

    return pathSegment;
  },
  onContentResize: function onContentResize() {
    // make sure details panel doesn't hide grid
    if (this.detailsPanel && this.grid) {
      var gridHeight = this.grid.getHeight(),
          detailsHeight = this.detailsPanel.getHeight();

      if (detailsHeight / 2 > gridHeight) {
        var newDetailsHeight = this.getHeight() * .4;
        this.layout.south.panel.setHeight(newDetailsHeight);
        this.doLayout();
      }
    }
  },

  /**
   * initializes generic stuff when used with ModelConfiguration
   */
  initGeneric: function initGeneric() {
    if (this.modelConfig) {
      Tine.log.debug('init generic gridpanel with config:');
      Tine.log.debug(this.modelConfig); // TODO move to uiConfig

      if (this.modelConfig.hasOwnProperty('multipleEdit') && this.modelConfig.multipleEdit === true) {
        this.multipleEdit = true;
        this.multipleEditRequiredRight = this.modelConfig.hasOwnProperty('multipleEditRequiredRight') ? this.modelConfig.multipleEditRequiredRight : null;
      } // TODO move to uiConfig


      if (this.modelConfig.hasOwnProperty('copyEditAction') && this.modelConfig.copyEditAction === true) {
        this.copyEditAction = true;
      }
    } // init generic columnModel


    if (!Ext.isFunction(this.getColumnModel)) {
      _.assign(this.gridConfig, this.initGenericColumnModel());
    }
  },

  /**
   * initialises the filter panel 
   * 
   * @param {Object} config
   */
  initFilterPanel: function initFilterPanel(config) {
    config = Ext.apply(config || {}, this.filterConfig);

    if (!this.filterToolbar && !this.editDialog) {
      var filterModels = [];

      if (this.modelConfig) {
        filterModels = this.getCustomfieldFilters();
      } else if (Ext.isFunction(this.recordClass.getFilterModel)) {
        filterModels = this.recordClass.getFilterModel().concat(this.getCustomfieldFilters());
      }

      this.filterToolbar = new Tine.widgets.grid.FilterPanel(Ext.apply({}, {
        app: this.app,
        recordClass: this.recordClass,
        allowSaving: true,
        filterModels: filterModels,
        defaultFilter: this.recordClass.getMeta('defaultFilter') ? this.recordClass.getMeta('defaultFilter') : 'query',
        filters: this.defaultFilters || []
      }, config));
      this.plugins = this.plugins || [];
      this.plugins.push(this.filterToolbar);
    }
  },

  /**
   * initializes the generic column model on auto bootstrap
   * Note this method is mixedin Tine.widgets.grid.QuickaddGridPanel
   */
  initGenericColumnModel: function initGenericColumnModel() {
    const gridConfig = {};

    if (this.modelConfig) {
      var columns = [],
          appName = this.recordClass.getMeta('appName'),
          modelName = this.recordClass.getMeta('modelName');
      Ext.each(this.modelConfig.fieldKeys, function (key) {
        var config = Tine.widgets.grid.ColumnManager.get(appName, modelName, key, 'mainScreen'); // @todo thats just a hotfix!

        if (['relations', 'customfields'].indexOf(key) !== -1) {
          return;
        }

        if (this.hideColumns && this.hideColumns.indexOf(key) !== -1) {
          return;
        }

        if (config) {
          columns.push(config);
        }
      }, this);

      if (this.modelConfig.hasCustomFields) {
        columns = columns.concat(this.getCustomfieldColumns());
      }

      if (_.find(columns, {
        dataIndex: 'tags'
      })) {
        var tagsCol = _.find(columns, {
          dataIndex: 'tags'
        });

        _.remove(columns, tagsCol);

        columns.unshift(tagsCol);
      }

      if (_.find(columns, {
        dataIndex: 'attachments'
      })) {
        var attachCol = _.find(columns, {
          dataIndex: 'attachments'
        });

        _.remove(columns, attachCol);

        columns.unshift(attachCol);
      }

      _.forEachRight(_.filter(this.modelConfig.fields, {
        type: 'image'
      }), function (field) {
        var imgCol = _.find(columns, {
          dataIndex: field.key
        });

        if (imgCol) {
          _.remove(columns, imgCol);

          columns.unshift(imgCol);
        }
      });

      columns = columns.concat(this.getCustomColumns ? this.getCustomColumns() : []);
      columns = this.customizeColumns ? this.customizeColumns(columns) || columns : columns;
      gridConfig.cm = new Ext.grid.ColumnModel({
        defaults: {
          resizable: true
        },
        columns: columns
      });
      gridConfig.autoExpandColumn = gridConfig.autoExpandColumn || this.autoExpandColumn || this.recordClass.getMeta('titleProperty');
      gridConfig.autoExpandColumn = this.recordClass.hasField(gridConfig.autoExpandColumn) ? gridConfig.autoExpandColumn : null;
    }

    return gridConfig;
  },

  /**
   * template method to allow adding custom columns
   * 
   * @return {Array}
   */
  getCustomColumns: function getCustomColumns() {
    return [];
  },

  /**
   * allows to customize columns
   *
   * @param columns Array
   * @returns {Array}
   */
  customizeColumns: function customizeColumns(columns) {
    if (this.customColumnData) {
      var _ = window.lodash;

      _.forEach(this.customColumnData, function (value) {
        var column = _.find(columns, {
          id: value.id
        });

        if (column) {
          // apply custom cfg
          column = Ext.apply(column, value);
        }
      });

      Tine.log.debug('Tine.widgets.grid.GridPanel.customizeColumns - applied custom column config:');
      Tine.log.debug(columns);
    }

    return columns;
  },

  /**
   * @private
   * 
   * NOTE: Order of items matters! Ext.Layout.Border.SplitRegion.layout() does not
   *       fence the rendering correctly, as such it's impotant, so have the ftb
   *       defined after all other layout items
   */
  initLayout: function initLayout() {
    this.items = [{
      ref: 'centerPanel',
      region: 'center',
      xtype: 'panel',
      layout: 'fit',
      border: false,
      tbar: this.pagingToolbar,
      items: this.grid
    }]; // add detail panel

    if (this.detailsPanel) {
      // just in case it's a config only
      this.detailsPanel = Ext.ComponentMgr.create(this.detailsPanel);
      this.items.push({
        ref: 'southPanel',
        region: 'south',
        border: false,
        collapsible: true,
        collapseMode: 'mini',
        header: false,
        split: true,
        layout: 'fit',
        height: this.detailsPanel.defaultHeight ? this.detailsPanel.defaultHeight : 125,
        items: this.detailsPanel,
        canonicalName: 'DetailsPanel'
      });
      this.detailsPanel.doBind(this.grid);
    } // add filter toolbar


    if (this.filterToolbar) {
      this.items.push({
        region: 'north',
        border: false,
        autoScroll: true,
        items: this.filterToolbar,
        listeners: {
          scope: this,
          afterlayout: function afterlayout(ct) {
            ct.suspendEvents();
            ct.setHeight(Math.min(120, this.filterToolbar.getHeight() + (ct.topToolbar ? ct.topToolbar.getHeight() : 0)));
            ct.getEl().child('div[class^="x-panel-body"]', true).scrollTop = 1000000;
            ct.ownerCt.layout.layout();
            ct.resumeEvents();
          }
        }
      });
    }

    if (this.ownActionToolbar) {
      this.items.push({
        region: 'north',
        height: 55,
        border: false,
        items: this.actionToolbar
      });
    }
  },
  gridPrintRenderer: function gridPrintRenderer() {
    Ext.ux.Printer.print(this.getGrid());
  },

  /**
   * init actions with actionToolbar, contextMenu and actionUpdater
   * 
   * @private
   */
  initActions: function initActions() {
    if (!this.newRecordIcon) {
      Ext.each((this.recordClass ? [this.recordClass.getMeta('appName') + this.recordClass.getMeta('modelName')] : []).concat([this.app.appName + 'IconCls', 'ApplicationIconCls']), function (cls) {
        if (Ext.util.CSS.getRule('.' + cls)) {
          this.newRecordIcon = cls;
          return false;
        }
      }, this);
    }

    var services = Tine.Tinebase.registry.get('serviceMap').services;
    this.action_editInNewWindow = new Ext.Action({
      requiredGrant: 'readGrant',
      requiredMultipleGrant: 'editGrant',
      requiredMultipleRight: this.multipleEditRequiredRight,
      text: this.i18nEditActionText ? this.i18nEditActionText[0] : String.format(i18n._('Edit {0}'), this.i18nRecordName),
      singularText: this.i18nEditActionText ? this.i18nEditActionText[0] : String.format(i18n._('Edit {0}'), this.i18nRecordName),
      pluralText: this.i18nEditActionText ? this.i18nEditActionText[1] : String.format(i18n.ngettext('Edit {0}', 'Edit {0}', 1), this.i18nRecordsName),
      disabled: true,
      translationObject: this.i18nEditActionText ? this.app.i18n : i18n,
      actionType: 'edit',
      handler: this.onEditInNewWindow.createDelegate(this, [{
        actionType: 'edit'
      }]),
      iconCls: 'action_edit',
      scope: this,
      allowMultiple: this.multipleEdit
    });
    this.action_editCopyInNewWindow = new Ext.Action({
      hidden: !this.copyEditAction,
      requiredGrant: 'readGrant',
      text: String.format(i18n._('Copy {0}'), this.i18nRecordName),
      disabled: true,
      actionType: 'copy',
      handler: this.onEditInNewWindow.createDelegate(this, [{
        actionType: 'copy'
      }]),
      iconCls: 'action_editcopy',
      scope: this
    });
    this.action_addInNewWindow = this.addButton ? new Ext.Action({
      requiredGrant: 'addGrant',
      actionType: 'add',
      text: this.i18nAddActionText ? this.app.i18n._hidden(this.i18nAddActionText) : String.format(i18n._('Add {0}'), this.i18nRecordName),
      handler: this.onEditInNewWindow.createDelegate(this, [{
        actionType: 'add'
      }]),
      iconCls: 'action_add',
      scope: this
    }) : null;
    this.actions_print = new Ext.Action({
      requiredGrant: 'readGrant',
      text: i18n._('Print Page'),
      disabled: false,
      handler: this.gridPrintRenderer,
      iconCls: 'action_print',
      scope: this,
      allowMultiple: true
    });
    this.initDeleteAction(services);
    this.action_move = new Ext.Action({
      requiredGrant: 'editGrant',
      requiredMultipleGrant: 'editGrant',
      requiredMultipleRight: this.multipleEditRequiredRight,
      singularText: this.i18nMoveActionText ? this.i18nMoveActionText[0] : String.format(i18n.ngettext('Move {0}', 'Move {0}', 1), this.i18nRecordName),
      pluralText: this.i18nMoveActionText ? this.i18nMoveActionText[1] : String.format(i18n.ngettext('Move {0}', 'Move {0}', 1), this.i18nRecordsName),
      translationObject: this.i18nMoveActionText ? this.app.i18n : i18n,
      text: this.i18nMoveActionText ? this.i18nMoveActionText[0] : String.format(i18n.ngettext('Move {0}', 'Move {0}', 1), this.i18nRecordName),
      disabled: true,
      hidden: !this.moveAction || !this.recordClass.getMeta('containerProperty'),
      actionType: 'edit',
      handler: this.onMoveRecords,
      scope: this,
      iconCls: 'action_move',
      allowMultiple: this.multipleEdit
    });
    this.action_tagsMassAttach = new Tine.widgets.tags.TagsMassAttachAction({
      hidden: !this.recordClass.getField('tags'),
      selectionModel: this.grid.getSelectionModel(),
      recordClass: this.recordClass,
      updateHandler: this.loadGridData.createDelegate(this),
      app: this.app
    });
    this.action_tagsMassDetach = new Tine.widgets.tags.TagsMassDetachAction({
      hidden: !this.recordClass.getField('tags'),
      selectionModel: this.grid.getSelectionModel(),
      recordClass: this.recordClass,
      updateHandler: this.loadGridData.createDelegate(this),
      app: this.app
    });
    this.action_resolveDuplicates = new Ext.Action({
      requiredGrant: null,
      text: String.format(i18n._('Merge {0}'), this.i18nRecordsName),
      iconCls: 'action_resolveDuplicates',
      scope: this,
      handler: this.onResolveDuplicates,
      disabled: false,
      actionUpdater: function actionUpdater(action, grants, records) {
        if (records && records.length != 2) action.setDisabled(true);else action.setDisabled(false);
      }
    });
    this.initExports();
    this.initImports(); // add actions to updater

    this.actionUpdater.addActions([this.action_addInNewWindow, this.action_editInNewWindow, this.action_move, this.action_editCopyInNewWindow, this.action_deleteRecord, this.action_tagsMassAttach, this.action_tagsMassDetach, this.action_resolveDuplicates]); // init actionToolbar (needed for correct fitertoolbar init atm -> fixme)

    this.getActionToolbar();
  },
  initExports: function initExports() {
    if (this.actions_export !== undefined) return;
    var _ = window.lodash,
        exportFunction = this.app.name + '.export' + this.recordClass.getMeta('modelName') + 's',
        additionalItems = []; // create items from available export formats (depricated -> use definitions)

    if (this.modelConfig && this.modelConfig['export']) {
      if (this.modelConfig['export'].supportedFormats) {
        Ext.each(this.modelConfig['export'].supportedFormats, function (format, i) {
          additionalItems.unshift(new Tine.widgets.grid.ExportButton({
            // TODO format toUpper
            text: String.format(i18n._('Export as {0}'), format),
            format: format,
            iconCls: 'tinebase-action-export-' + format,
            exportFunction: exportFunction,
            order: i * 10,
            gridPanel: this
          }));
        }, this);
      }
    } // exports from export definitions


    this.actions_export = Tine.widgets.exportAction.getExportButton(this.recordClass, {
      exportFunction: exportFunction,
      gridPanel: this
    }, Tine.widgets.exportAction.SCOPE_MULTI, additionalItems);

    if (this.actions_export) {
      this.actionUpdater.addActions([this.actions_export]);
    }
  },
  initImports: function initImports() {
    if (this.actions_import !== undefined) return;

    if ( // create items from available import formats (depricated -> use definitions)
    this.modelConfig && this.modelConfig['import'] // imports from import definitions
    || Tine.widgets.importAction.getImports(this.recordClass).length) {
      this.actions_import = new Ext.Action({
        requiredGrant: 'addGrant',
        text: i18n._('Import items'),
        disabled: false,
        handler: this.onImport,
        iconCls: 'action_import',
        scope: this,
        allowMultiple: true
      });
      this.actionUpdater.addActions([this.actions_import]);
    }
  },

  /**
   * import inventory items
   *
   * @param {Button} btn
   */
  onImport: function onImport(btn) {
    var treePanel = this.treePanel || this.app.getMainScreen().getWestPanel().getContainerTreePanel(),
        _ = window.lodash;

    var container = _.get(this.modelConfig, 'import.defaultImportContainerRegistryKey', false);

    if (container) {
      container = treePanel.getDefaultContainer(container);
    } else if (Ext.isFunction(this.getDefaultContainer)) {
      container = this.getDefaultContainer();
    }

    Tine.widgets.dialog.ImportDialog.openWindow({
      appName: this.app.name,
      modelName: this.recordClass.getMeta('modelName'),
      defaultImportContainer: container,
      listeners: {
        scope: this,
        'finish': function finish() {
          this.loadGridData({
            preserveCursor: false,
            preserveSelection: false,
            preserveScroller: false,
            removeStrategy: 'default'
          });
        }
      }
    });
  },

  /**
   * initializes the delete action
   * 
   * @param {Object} services the rpc service map from the registry
   */
  initDeleteAction: function initDeleteAction(services) {
    // note: unprecise plural form here, but this is hard to change
    this.action_deleteRecord = new Ext.Action({
      requiredGrant: 'deleteGrant',
      allowMultiple: true,
      singularText: this.i18nDeleteActionText ? this.i18nDeleteActionText[0] : String.format(i18n.ngettext('Delete {0}', 'Delete {0}', 1), this.i18nRecordName),
      pluralText: this.i18nDeleteActionText ? this.i18nDeleteActionText[1] : String.format(i18n.ngettext('Delete {0}', 'Delete {0}', 1), this.i18nRecordsName),
      translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
      text: this.i18nDeleteActionText ? this.i18nDeleteActionText[0] : String.format(i18n.ngettext('Delete {0}', 'Delete {0}', 1), this.i18nRecordName),
      handler: this.onDeleteRecords,
      disabled: true,
      iconCls: 'action_delete',
      scope: this
    }); // if nested in a editDialog (dependent record), the service won't exist

    if (!this.editDialog) {
      this.disableDeleteActionCheckServiceMap(services);
    }
  },

  /**
   * disable delete action if no delete method was found in serviceMap
   * 
   * @param {Object} services the rpc service map from the registry
   * 
   * TODO this should be configurable as not all grids use remote delete
   */
  disableDeleteActionCheckServiceMap: function disableDeleteActionCheckServiceMap(services) {
    if (services) {
      var serviceKey = this.app.name + '.delete' + this.recordClass.getMeta('modelName') + 's';

      if (!services.hasOwnProperty(serviceKey)) {
        this.action_deleteRecord.setDisabled(1);

        this.action_deleteRecord.initialConfig.actionUpdater = function (action) {
          Tine.log.debug("disable delete action because no delete method was found in serviceMap");
          action.setDisabled(1);
        };
      }
    }
  },

  /**
   * init store
   * @private
   */
  initStore: function initStore() {
    if (this.store) {
      // store is already initialized
      return;
    }

    if (this.recordProxy) {
      if (!this.defaultSortInfo.field) {
        if (this.modelConfig && this.modelConfig.defaultSortInfo) {
          this.defaultSortInfo = this.modelConfig.defaultSortInfo;
        } else if (this.recordClass) {
          var titleProperty = this.recordClass.getMeta('titleProperty'),
              defaultSortField = Ext.isArray(titleProperty) ? titleProperty[1][0] : titleProperty;
          this.defaultSortInfo = this.recordClass.hasField(titleProperty) ? {
            field: defaultSortField,
            order: 'DESC'
          } : null;
        }
      }

      var storeClass = this.groupField ? Ext.data.GroupingStore : Ext.data.Store;
      this.store = new storeClass({
        fields: this.recordClass,
        proxy: this.recordProxy,
        reader: this.recordProxy.getReader(),
        remoteSort: this.storeRemoteSort,
        sortInfo: this.defaultSortInfo,
        groupField: 'month',
        listeners: {
          scope: this,
          'add': this.onStoreAdd,
          'remove': this.onStoreRemove,
          'update': this.onStoreUpdate,
          'beforeload': this.onStoreBeforeload,
          'load': this.onStoreLoad,
          'beforeloadrecords': this.onStoreBeforeLoadRecords,
          'loadexception': this.onStoreLoadException
        }
      });
    } else {
      this.store = new Tine.Tinebase.data.RecordStore({
        recordClass: this.recordClass
      });
    } // init autoRefresh


    this.autoRefreshTask = new Ext.util.DelayedTask(this.loadGridData, this, [{
      removeStrategy: 'keepBuffered',
      autoRefresh: true
    }]);
  },

  /**
   * returns view row class
   */
  getViewRowClass: function getViewRowClass(record, index, rowParams, store) {
    var noLongerInFilter = record.not_in_filter;
    var className = '';

    if (noLongerInFilter) {
      className += 'tine-grid-row-nolongerinfilter';
    }

    return className;
  },

  /**
   * new entry event -> add new record to store
   * 
   * @param {Object} recordData
   * @return {Boolean}
   */
  onStoreNewEntry: function onStoreNewEntry(recordData) {
    var initialData = null;

    if (Ext.isFunction(this.recordClass.getDefaultData)) {
      initialData = Ext.apply(this.recordClass.getDefaultData(), recordData);
    } else {
      initialData = recordData;
    }

    var record = new this.recordClass(initialData);
    this.store.insert(0, [record]);

    if (this.usePagingToolbar) {
      this.pagingToolbar.refresh.disable();
    }

    this.recordProxy.saveRecord(record, {
      scope: this,
      success: function success(newRecord) {
        this.store.suspendEvents();
        this.store.remove(record);
        this.store.insert(0, [newRecord]);
        this.store.resumeEvents();
        this.addToEditBuffer(newRecord);
        this.loadGridData({
          removeStrategy: 'keepBuffered'
        });
      }
    });
    return true;
  },

  /**
   * adds given record and starts editing
   * 
   * @param localRecord
   * @param editProperty
   * @param proxyFn
   * @return {Promise<void>}
   */
  newInlineRecord: async function newInlineRecord(localRecord, editProperty, proxyFn) {
    localRecord.noProxy = true;
    this.store.addUnique(localRecord, editProperty);
    this.grid.getSelectionModel().selectRow(this.store.indexOf(localRecord));
    this.grid.startEditingRecord(localRecord, editProperty);
    const ed = this.grid.activeEditor;
    ed.field.selectText(0, String(ed.field.getValue()).lastIndexOf('.'));
    ed.startValue = Math.random();

    const onCancelEdit = e => {
      this.grid.un('afteredit', onAfterEdit);
      this.store.remove(localRecord);
    };

    ed.on('canceledit', onCancelEdit, this, {
      single: true
    });

    const onAfterEdit = async o => {
      ed.un('canceledit', onCancelEdit);
      this.pagingToolbar.refresh.disable();
      this.store.remove(localRecord);
      this.store.addSorted(localRecord);
      this.grid.getSelectionModel().selectRow(this.store.indexOf(localRecord));
      await proxyFn(localRecord).then(result => {
        if (result === null || result === void 0 ? void 0 : result.data) {
          window.postal.publish({
            channel: "recordchange",
            topic: 'Filemanager.Node.delete',
            data: localRecord.data
          });
          window.postal.publish({
            channel: "recordchange",
            topic: (result.data.path === 'tempFile' ? 'Tinebase.TempFile' : 'Filemanager.Node') + '.create',
            data: result.data
          });
        }
      }).catch(e => {
        window.postal.publish({
          channel: "recordchange",
          topic: 'Filemanager.Node.delete',
          data: localRecord.data
        });
      });
      this.pagingToolbar.refresh.enable();
    };

    this.grid.on('afteredit', onAfterEdit, this, {
      single: true,
      buffer: 100
    });
  },

  /**
   * header is clicked
   * 
   * @param {Object} grid
   * @param {Number} colIdx
   * @param {Event} e
   * @return {Boolean}
   */
  onHeaderClick: function onHeaderClick(grid, colIdx, e) {
    Ext.apply(this.store.lastOptions, {
      preserveCursor: true,
      preserveSelection: true,
      preserveScroller: true,
      removeStrategy: 'default'
    });
  },

  /**
   * called when Records have been added to the Store
   */
  onStoreAdd: function onStoreAdd(store, records, index) {
    this.store.totalLength += records.length;

    if (this.pagingToolbar) {
      this.pagingToolbar.updateInfo();
    }
  },

  /**
   * called when a Record has been removed from the Store
   */
  onStoreRemove: function onStoreRemove(store, record, index) {
    this.store.totalLength--;

    if (this.pagingToolbar) {
      this.pagingToolbar.updateInfo();
    }
  },

  /**
   * called when the store gets updated, e.g. from editgrid
   * 
   * @param {Ext.data.store} store
   * @param {Tine.Tinebase.data.Record} record
   * @param {String} operation
   */
  onStoreUpdate: function onStoreUpdate(store, record, operation) {
    if (record.noProxy) return;

    switch (operation) {
      case Ext.data.Record.EDIT:
        this.addToEditBuffer(record);

        if (this.usePagingToolbar) {
          this.pagingToolbar.refresh.disable();
        } // don't save these records. Add them to the parents' record store


        if (this.editDialog && this.editDialogRecordProperty) {
          var items = [];
          store.each(function (item) {
            items.push(item.data);
          });
          this.editDialog.record.set(this.editDialogRecordProperty, items);
          this.editDialog.fireEvent('updateDependent');
        } else if (this.recordProxy) {
          this.recordProxy.saveRecord(record, {
            scope: this,
            success: function success(updatedRecord) {
              store.commitChanges(); // update record in store to prevent concurrency problems

              record.data = updatedRecord.data;
              this.loadGridData({
                removeStrategy: 'keepBuffered'
              });
            }
          });
          break;
        }

      case Ext.data.Record.COMMIT:
        //nothing to do, as we need to reload the store anyway.
        break;
    }
  },

  /**
   * called before store queries for data
   */
  onStoreBeforeload: function onStoreBeforeload(store, options) {
    // define a transaction
    this.lastStoreTransactionId = options.transactionId = Ext.id();
    options.params = options.params || {}; // always start with an empty filter set!
    // this is important for paging and sort header!

    options.params.filter = [];

    if (!options.removeStrategy || options.removeStrategy !== 'keepBuffered') {
      this.editBuffer = [];
    }

    if (!options.preserveSelection) {
      this.actionUpdater.updateActions([]);
    } // fix nasty paging tb


    Ext.applyIf(options.params, this.defaultPaging);
  },

  /**
   * called after a new set of Records has been loaded
   * 
   * @param  {Ext.data.Store} this.store
   * @param  {Array}          loaded records
   * @param  {Array}          load options
   * @return {Void}
   */
  onStoreLoad: function onStoreLoad(store, records, options) {
    // we always focus the first row so that keynav starts in the grid
    // this resets scroller ;-( -> need a better solution
    //        if (this.store.getCount() > 0) {
    //            this.grid.getView().focusRow(0);
    //        }
    // update the latest filter here, make sure each gridPanel have their own latest filter
    const containerFilter = _.find(_.get(store, 'reader.jsonData.filter[0].filters[0].filters', {}), {
      field: this.recordClass.getMeta('containerProperty')
    });

    const operator = _.get(containerFilter, 'operator', '');

    this.latestFilter = operator.match(/equals|in/) ? _.get(containerFilter, 'value', null) : null; // restore selection

    if (Ext.isArray(options.preserveSelection)) {
      Ext.each(options.preserveSelection, function (record) {
        var row = this.store.indexOfId(record.id);

        if (row >= 0) {
          this.grid.getSelectionModel().selectRow(row, true);
        }
      }, this);
    }

    this.actionUpdater.updateActions(this.grid.getSelectionModel(), this.getFilteredContainers()); // restore scroller

    if (Ext.isNumber(options.preserveScroller)) {
      this.grid.getView().scroller.dom.scrollTop = options.preserveScroller;
    } // reset autoRefresh


    if (window.isMainWindow && this.autoRefreshInterval) {
      this.autoRefreshTask.delay(this.autoRefreshInterval * 1000);
    }
  },

  /**
   * gets currently displayed container in case a container filter is set
   * NOTE: this data is unresolved as it comes from filter and not through json convert!
   */
  getFilteredContainers: function getFilteredContainers() {
    var _this$latestFilter;

    const containerFilter = _.find(_.get(this, 'store.reader.jsonData.filter[0].filters[0].filters', {}), {
      field: this.recordClass.getMeta('containerProperty')
    });

    const operator = _.get(containerFilter, 'operator', '');

    const filter = operator.match(/equals|in/) ? _.get(containerFilter, 'value', null) : null;
    const value = (_this$latestFilter = this.latestFilter) !== null && _this$latestFilter !== void 0 ? _this$latestFilter : filter;
    return value && _.isArray(value) ? [value] : value;
  },

  /**
   * on store load exception
   * 
   * @param {Tine.Tinebase.data.RecordProxy} proxy
   * @param {String} type
   * @param {Object} error
   * @param {Object} options
   */
  onStoreLoadException: function onStoreLoadException(proxy, type, error, options) {
    // reset autoRefresh
    if (window.isMainWindow && this.autoRefreshInterval) {
      this.autoRefreshTask.delay(this.autoRefreshInterval * 5000);
    }

    if (this.usePagingToolbar && this.pagingToolbar.refresh) {
      this.pagingToolbar.refresh.enable();
    }

    if (!options.autoRefresh) {
      proxy.handleRequestException(error);
    } else {
      Tine.log.debug('Tine.widgets.grid.GridPanel::onStoreLoadException -> auto refresh failed.');
    }
  },

  /**
   * onStoreBeforeLoadRecords
   * 
   * @param {Object} o
   * @param {Object} options
   * @param {Boolean} success
   * @param {Ext.data.Store} store
   */
  onStoreBeforeLoadRecords: function onStoreBeforeLoadRecords(o, options, success, store) {
    if (this.lastStoreTransactionId && options.transactionId && this.lastStoreTransactionId !== options.transactionId) {
      Tine.log.debug('onStoreBeforeLoadRecords - cancelling old transaction request.');
      return false;
    } // save selection -> will be applied onLoad


    if (options.preserveSelection) {
      options.preserveSelection = this.grid.getSelectionModel().getSelections();
    } // save scroller -> will be applied onLoad


    if (options.preserveScroller && this.grid.getView().scroller && this.grid.getView().scroller.dom) options.preserveScroller = this.grid.getView().scroller.dom.scrollTop; // apply removeStrategy

    if (!options.removeStrategy || options.removeStrategy === 'default') {
      return true;
    }

    var records = [],
        recordsIds = [],
        recordToLoadCollection = new Ext.util.MixedCollection(); // fill new collection

    Ext.each(o.records, function (record) {
      recordToLoadCollection.add(record.id, record);
    }); // assemble update & keep

    this.store.each(function (currentRecord) {
      var recordToLoad = recordToLoadCollection.get(currentRecord.id);

      if (recordToLoad) {
        // we replace records that are the same, because otherwise this would not work for local changes
        if (recordToLoad.isObsoletedBy(currentRecord)) {
          records.push(currentRecord);
          recordsIds.push(currentRecord.id);
        } else {
          records.push(recordToLoad);
          recordsIds.push(recordToLoad.id);
        }
      } else if (options.removeStrategy === 'keepAll' || options.removeStrategy === 'keepBuffered' && this.editBuffer.indexOf(currentRecord.id) >= 0) {
        var copiedRecord = currentRecord.copy();
        copiedRecord.not_in_filter = true;
        records.push(copiedRecord);
        recordsIds.push(currentRecord.id);
      }
    }, this); // assemble adds

    recordToLoadCollection.each(function (record, idx) {
      if (recordsIds.indexOf(record.id) == -1 && this.deleteQueue.indexOf(record.id) == -1) {
        var lastRecord = recordToLoadCollection.itemAt(idx - 1);
        var lastRecordIdx = lastRecord ? recordsIds.indexOf(lastRecord.id) : -1;
        records.splice(lastRecordIdx + 1, 0, record);
        recordsIds.splice(lastRecordIdx + 1, 0, record.id);
      }
    }, this);
    o.records = records; // hide current records from store.loadRecords()
    // @see 0008210: email grid: set flag does not work sometimes

    this.store.clearData();
  },

  /**
   * perform the initial load of grid data
   */
  initialLoad: function initialLoad() {
    var defaultFavorite = Tine.widgets.persistentfilter.model.PersistentFilter.getDefaultFavorite(this.app.appName, this.recordClass.prototype.modelName),
        favoritesPanel = this.app.getMainScreen() && typeof this.app.getMainScreen().getWestPanel === 'function' && typeof this.app.getMainScreen().getWestPanel().getFavoritesPanel === 'function' && this.hasFavoritesPanel ? this.app.getMainScreen().getWestPanel().getFavoritesPanel() : null;

    if (defaultFavorite && favoritesPanel) {
      favoritesPanel.selectFilter(defaultFavorite);
    } else {
      if (!(this.editDialog && this.editDialogRecordProperty)) {
        this.store.load.defer(10, this.store, [typeof this.autoLoad == 'object' ? this.autoLoad : undefined]);
      } else {
        // editDialog exists, so get the records from there.
        var items = this.editDialog.record.get(this.editDialogRecordProperty);

        if (Ext.isArray(items)) {
          Ext.each(items, function (item) {
            var record = this.recordProxy.recordReader({
              responseText: Ext.encode(item)
            });
            this.store.addSorted(record);
          }, this);
        }
      }
    }

    if (this.usePagingToolbar && this.recordProxy) {
      this.pagingToolbar.refresh.disable.defer(10, this.pagingToolbar.refresh);
    }
  },

  /**
   * init ext grid panel
   * @private
   */
  initGrid: function initGrid() {
    var preferences = Tine.Tinebase.registry.get('preferences');

    if (preferences) {
      this.gridConfig = Ext.applyIf(this.gridConfig || {}, {
        stripeRows: preferences.get('gridStripeRows') ? preferences.get('gridStripeRows') : false,
        loadMask: preferences.get('gridLoadMask') ? preferences.get('gridLoadMask') : false
      }); // added paging number of result read from settings

      if (preferences.get('pageSize') != null) {
        this.defaultPaging = {
          start: 0,
          limit: parseInt(preferences.get('pageSize'), 10)
        };
      }
    } // generic empty text


    this.i18nEmptyText = i18n.gettext('No data to display'); // init sel model

    if (!this.selectionModel) {
      this.selectionModel = new Tine.widgets.grid.FilterSelectionModel({
        moveEditorOnEnter: false,
        store: this.store,
        gridPanel: this
      });
    }

    this.selectionModel.on('selectionchange', function (sm) {
      this.actionUpdater.updateActions(sm, this.getFilteredContainers());
      this.ctxNode = this.selectionModel.getSelections();

      if (this.updateOnSelectionChange && this.detailsPanel) {
        this.detailsPanel.onDetailsUpdate(sm);
      }
    }, this);

    if (this.usePagingToolbar) {
      this.pagingToolbar = new Ext.ux.grid.PagingToolbar(Ext.apply({
        pageSize: this.defaultPaging && this.defaultPaging.limit ? this.defaultPaging.limit : 50,
        store: this.store,
        displayInfo: true,
        displayMsg: i18n._('Displaying records {0} - {1} of {2}').replace(/records/, this.i18nRecordsName),
        emptyMsg: String.format(i18n._("No {0} to display"), this.i18nRecordsName),
        displaySelectionHelper: this.displaySelectionHelper,
        sm: this.selectionModel,
        disableSelectAllPages: this.disableSelectAllPages,
        nested: this.editDialog ? true : false
      }, this.pagingConfig)); // mark next grid refresh as paging-refresh

      this.pagingToolbar.on('beforechange', function () {
        this.grid.getView().isPagingRefresh = true;
      }, this);
    } // which grid to use?
    // TODO find a better way to configure quickadd grid


    var Grid = null;

    if (this.gridConfig.quickaddMandatory) {
      Grid = Ext.ux.grid.QuickaddGridPanel;
      this.gridConfig.validate = true;
    } else {
      Grid = this.gridConfig.gridType || Ext.grid.GridPanel;
    }

    this.gridConfig.store = this.store; // activate grid header menu for column selection

    this.gridConfig.plugins = this.gridConfig.plugins ? this.gridConfig.plugins : [];
    this.gridConfig.plugins.push(new Ext.ux.grid.GridViewMenuPlugin({}));

    if (this.stateful) {
      this.gridConfig.stateful = true;
      this.gridConfig.stateId = this.stateId + '-Grid' + this.stateIdSuffix;
    }

    this.grid = new Grid(Ext.applyIf(this.gridConfig, {
      border: false,
      store: this.store,
      sm: this.selectionModel,
      parentScope: this,
      view: this.createView(),
      recordClass: this.recordClass,
      getDragDropText: this.getDragDropText.createDelegate(this)
    })); // init various grid / sm listeners

    this.grid.on('keydown', this.onKeyDown, this);
    this.grid.on('rowclick', this.onRowClick, this);
    this.grid.on('rowdblclick', this.onRowDblClick, this);
    this.grid.on('newentry', this.onStoreNewEntry, this);
    this.grid.on('headerclick', this.onHeaderClick, this);
    this.grid.on('rowcontextmenu', this.onRowContextMenu, this);
  },
  getDragDropText: function getDragDropText() {
    const titleProperty = this.recordClass.getMeta('titleProperty');

    if (!titleProperty) {
      return Ext.grid.GridView.prototype.getDragDropText.call(this.grid);
    }

    const col = _.indexOf(this.grid.colModel.config, _.find(this.grid.colModel.config, {
      dataIndex: titleProperty
    }));

    const selections = this.grid.selModel.getSelections();

    if (!col || selections.length > 10) {
      return formatMessage('{recordGender, select, male {{recordCount, plural, one {# {recordName} selected} other {# {recordsName} selected}}} female {{recordCount, plural, one {# {recordName} selected} other {# {recordsName} selected}}} other {{recordCount, plural, one {# {recordName} selected} other {# {recordsName} selected}}}}', {
        recordGender: this.recordClass.getRecordGender(),
        recordCount: selections.length,
        recordName: this.recordClass.getRecordName(),
        recordsName: this.recordClass.getRecordsName()
      });
    } // else


    return _.reduce(selections, (html, node) => {
      return html += '<tr>' + this.grid.getView().getCell(this.store.indexOf(node), col).cloneNode(true).outerHTML + '</tr>';
    }, '<table>') + '</table>';
  },

  /**
   * creates and returns the view for the grid
   * 
   * @return {Ext.grid.GridView}
   */
  createView: function createView() {
    // init view
    if (this.groupField && !this.groupTextTpl) {
      this.groupTextTpl = '{text} ({[values.rs.length]} {[values.rs.length > 1 ? "' + i18n._("Records") + '" : "' + i18n._("Record") + '"]})';
    }

    const viewClass = this.groupField ? Ext.grid.GroupingView : Ext.grid.GridView;
    return new viewClass({
      getRowClass: this.getViewRowClass.bind(this),
      autoFill: true,
      forceFit: true,
      ignoreAdd: true,
      emptyText: this.i18nEmptyText,
      groupTextTpl: this.groupTextTpl,
      onLoad: Ext.grid.GridView.prototype.onLoad.createInterceptor(function () {
        if (this.grid.getView().isPagingRefresh) {
          this.grid.getView().isPagingRefresh = false;
          return true;
        }

        return false;
      }, this)
    });
  },

  /**
   * executed after outer panel rendering process
   */
  afterRender: function afterRender() {
    Tine.widgets.grid.GridPanel.superclass.afterRender.apply(this, arguments);

    if (this.initialLoadAfterRender) {
      this.initialLoad();
    }
  },

  /**
   * trigger store load with grid related options
   * 
   * TODO rethink -> preserveCursor and preserveSelection might conflict on page breaks!
   * TODO don't reload details panel when selection is preserved
   * 
   * @param {Object} options
   */
  loadGridData: function loadGridData(options) {
    options = options || {};
    Ext.applyIf(options, {
      callback: Ext.emptyFn,
      scope: this,
      params: {},
      preserveCursor: true,
      preserveSelection: true,
      preserveScroller: true,
      removeStrategy: 'default'
    });

    if (options.preserveCursor && this.usePagingToolbar) {
      options.params.start = this.pagingToolbar.cursor;
    }

    this.store.load(options);
  },

  /**
   * get action toolbar
   * 
   * @return {Ext.Toolbar}
   */
  getActionToolbar: function getActionToolbar() {
    if (!this.actionToolbar) {
      var additionalItems = this.getActionToolbarItems();
      var items = [];

      if (this.action_addInNewWindow) {
        if (this.splitAddButton) {
          items.push(Ext.apply(new Ext.SplitButton(this.action_addInNewWindow), {
            scale: 'medium',
            rowspan: 2,
            iconAlign: 'top',
            arrowAlign: 'right',
            menu: new Ext.menu.Menu({
              items: [],
              plugins: [{
                ptype: 'ux.itemregistry',
                key: 'Tine.widgets.grid.GridPanel.addButton'
              }]
            })
          }));
        } else {
          items.push(Ext.apply(new Ext.Button(this.action_addInNewWindow), {
            scale: 'medium',
            rowspan: 2,
            iconAlign: 'top'
          }));
        }
      }

      if (this.action_editInNewWindow) {
        items.push(Ext.apply(new Ext.Button(this.action_editInNewWindow), {
          scale: 'medium',
          rowspan: 2,
          iconAlign: 'top'
        }));
      }

      if (this.action_deleteRecord) {
        items.push(Ext.apply(new Ext.Button(this.action_deleteRecord), {
          scale: 'medium',
          rowspan: 2,
          iconAlign: 'top'
        }));
      }

      if (this.actions_print) {
        items.push(Ext.apply(new (this.actions_print.initialConfig && this.actions_print.initialConfig.menu ? Ext.SplitButton : Ext.Button)(this.actions_print), {
          scale: 'medium',
          rowspan: 2,
          iconAlign: 'top'
        }));
      }

      var importExportButtons = [];

      if (this.actions_export) {
        importExportButtons.push(Ext.apply(new Ext.Button(this.actions_export), {
          scale: 'small',
          rowspan: 1,
          iconAlign: 'left'
        }));
      }

      if (this.actions_import) {
        importExportButtons.push(Ext.apply(new Ext.Button(this.actions_import), {
          scale: 'small',
          rowspan: 1,
          iconAlign: 'left'
        }));
      }

      if (importExportButtons.length > 0) {
        items.push({
          xtype: 'buttongroup',
          columns: 1,
          frame: false,
          items: importExportButtons
        });
      }

      this.actionToolbar = new Ext.Toolbar({
        canonicalName: [this.recordClass.getMeta('modelName'), 'ActionToolbar'].join(Tine.Tinebase.CanonicalPath.separator),
        items: [{
          xtype: 'buttongroup',
          layout: 'toolbar',
          buttonAlign: 'left',
          enableOverflow: true,
          plugins: [{
            ptype: 'ux.itemregistry',
            key: this.app.appName + '-' + this.recordClass.prototype.modelName + '-GridPanel-ActionToolbar-leftbtngrp'
          }],
          items: items.concat(Ext.isArray(additionalItems) ? additionalItems : [])
        }].concat(Ext.isArray(additionalItems) ? [] : [additionalItems])
      });
      this.actionToolbar.on('resize', this.onActionToolbarResize, this, {
        buffer: 250
      });
      this.actionToolbar.on('show', this.onActionToolbarResize, this);

      if (this.filterToolbar && typeof this.filterToolbar.getQuickFilterField == 'function') {
        this.actionToolbar.add('->', this.filterToolbar.getQuickFilterField());
      }

      this.actionUpdater.addActions(this.actionToolbar.items);
    }

    return this.actionToolbar;
  },
  onActionToolbarResize: function onActionToolbarResize(tb) {
    if (!tb.rendered) return;
    var actionGrp = tb.items.get(0),
        availableWidth = tb.getBox()['width'] - 5,
        maxNeededWidth = Ext.layout.ToolbarLayout.prototype.triggerWidth + 10;
    tb.items.each(function (c, idx) {
      if (idx > 0 && !c.isFill) {
        availableWidth -= c.getPositionEl().dom.parentNode.offsetWidth;
      }
    }, this);
    actionGrp.items.each(function (c) {
      maxNeededWidth += Ext.layout.ToolbarLayout.prototype.getItemWidth(c);
    });
    actionGrp.setWidth(Math.min(availableWidth, maxNeededWidth));
  },

  /**
   * template fn for subclasses to add custom items to action toolbar
   * 
   * @return {Array/Object}
   */
  getActionToolbarItems: function getActionToolbarItems() {
    var items = this.actionToolbarItems || [];

    if (!Ext.isEmpty(items)) {
      // legacy handling! subclasses should register all actions when initializing actions
      this.actionUpdater.addActions(items);
    }

    return items;
  },

  /**
   * returns rows context menu
   * 
   * @param {Ext.grid.GridPanel} grid
   * @param {Number} row
   * @param {Ext.EventObject} e
   * @return {Ext.menu.Menu}
   */
  getContextMenu: function getContextMenu(grid, row, e) {
    if (!this.contextMenu) {
      var items = [];
      if (this.action_addInNewWindow) items.push(this.action_addInNewWindow);
      if (this.action_editInNewWindow) items.push(this.action_editInNewWindow);
      if (this.action_editCopyInNewWindow) items.push(this.action_editCopyInNewWindow);
      if (this.action_move) items.push(this.action_move);
      if (this.action_deleteRecord) items.push(this.action_deleteRecord);

      if (this.duplicateResolvable) {
        items.push(this.action_resolveDuplicates);
      }

      if (this.actions_export) {
        items.push('-', this.actions_export);
      }

      if (this.action_tagsMassAttach && !this.action_tagsMassAttach.hidden) {
        items.push('-', this.action_tagsMassAttach, this.action_tagsMassDetach);
      } // lookup additional items


      items = items.concat(this.getContextMenuItems()); // New record of another app

      this.newRecordMenu = new Ext.menu.Menu({
        items: [],
        plugins: [{
          ptype: 'ux.itemregistry',
          key: this.app.appName + '-' + this.recordClass.prototype.modelName + '-GridPanel-ContextMenu-New'
        }]
      });
      this.newRecordAction = new Ext.Action({
        text: i18n._('New...'),
        hidden: !this.newRecordMenu.items.length,
        iconCls: this.app.getIconCls(),
        scope: this,
        menu: this.newRecordMenu
      });
      items.push(this.newRecordAction); // Add to record of another app            

      this.addToRecordMenu = new Ext.menu.Menu({
        items: [],
        plugins: [{
          ptype: 'ux.itemregistry',
          key: this.app.appName + '-' + this.recordClass.prototype.modelName + '-GridPanel-ContextMenu-Add'
        }]
      });
      this.addToRecordAction = new Ext.Action({
        text: i18n._('Add to...'),
        hidden: !this.addToRecordMenu.items.length,
        iconCls: this.app.getIconCls(),
        scope: this,
        menu: this.addToRecordMenu
      });
      items.push(this.addToRecordAction);
      this.contextMenu = new Ext.menu.Menu({
        items: items,
        plugins: [{
          ptype: 'ux.itemregistry',
          key: this.app.appName + '-' + this.recordClass.prototype.modelName + '-GridPanel-ContextMenu'
        }, {
          ptype: 'ux.itemregistry',
          key: 'Tinebase-MainContextMenu'
        }]
      });
      this.actionUpdater.addActions(this.contextMenu.items);
    }

    return this.contextMenu;
  },

  /**
   * template fn for subclasses to add custom items to context menu
   * 
   * @return {Array}
   */
  getContextMenuItems: function getContextMenuItems() {
    var items = this.contextMenuItems || [];

    if (!Ext.isEmpty(items)) {
      // legacy handling! subclasses should register all actions when initializing actions
      this.actionUpdater.addActions(items);
    }

    return items;
  },

  /**
   * get modlog columns
   * 
   * shouldn' be used anymore
   * @TODO: use applicationstarter and modelconfiguration
   * 
   * @deprecated
   * @return {Array}
   */
  getModlogColumns: function getModlogColumns() {
    var result = [{
      id: 'creation_time',
      header: i18n._('Creation Time'),
      dataIndex: 'creation_time',
      renderer: Tine.Tinebase.common.dateRenderer,
      hidden: true,
      sortable: true
    }, {
      id: 'created_by',
      header: i18n._('Created By'),
      dataIndex: 'created_by',
      renderer: Tine.Tinebase.common.usernameRenderer,
      hidden: true,
      sortable: true
    }, {
      id: 'last_modified_time',
      header: i18n._('Last Modified Time'),
      dataIndex: 'last_modified_time',
      renderer: Tine.Tinebase.common.dateRenderer,
      hidden: true,
      sortable: true
    }, {
      id: 'last_modified_by',
      header: i18n._('Last Modified By'),
      dataIndex: 'last_modified_by',
      renderer: Tine.Tinebase.common.usernameRenderer,
      hidden: true,
      sortable: true
    }];
    return result;
  },

  /**
   * get custom field columns for column model
   * 
   * @return {Array}
   */
  getCustomfieldColumns: function getCustomfieldColumns() {
    var modelName = this.recordClass.getMeta('appName') + '_Model_' + this.recordClass.getMeta('modelName'),
        cfConfigs = Tine.widgets.customfields.ConfigManager.getConfigs(this.app, modelName),
        result = [];
    Ext.each(cfConfigs, function (cfConfig) {
      result.push({
        id: cfConfig.id,
        header: cfConfig.get('definition').label,
        dataIndex: 'customfields',
        renderer: Tine.widgets.customfields.Renderer.get(this.app, cfConfig),
        sortable: false,
        hidden: true
      });
    }, this);
    return result;
  },

  /**
   * get custom field filter for filter toolbar
   * 
   * @return {Array}
   */
  getCustomfieldFilters: function getCustomfieldFilters() {
    var modelName = this.recordClass.getMeta('appName') + '_Model_' + this.recordClass.getMeta('modelName'),
        cfConfigs = Tine.widgets.customfields.ConfigManager.getConfigs(this.app, modelName),
        result = [];
    Ext.each(cfConfigs, function (cfConfig) {
      try {
        var cfDefinition = cfConfig.get('definition');

        switch (cfDefinition.type) {
          case 'record':
            if (_.get(window, cfDefinition.recordConfig.value.records)) {
              result.push({
                filtertype: 'foreignrecord',
                label: cfDefinition.label,
                app: this.app,
                ownRecordClass: this.recordClass,
                foreignRecordClass: eval(cfDefinition.recordConfig.value.records),
                linkType: 'foreignId',
                ownField: 'customfield:' + cfConfig.id,
                pickerConfig: cfDefinition.recordConfig.additionalFilterSpec ? {
                  additionalFilterSpec: cfDefinition.recordConfig.additionalFilterSpec
                } : null
              });
            }

            break;

          case 'keyField':
            result.push({
              filtertype: 'tine.widget.keyfield.filter',
              field: 'customfield:' + cfConfig.id,
              app: this.app,
              keyfieldName: cfConfig.get('name'),
              label: cfDefinition.label
            });
            break;

          default:
            result.push({
              filtertype: 'tinebase.customfield',
              app: this.app,
              cfConfig: cfConfig
            });
            break;
        }
      } catch (e) {
        Tine.log.warn('CustomfieldFilters ' + cfDefinition.label + ' doesnt create');
      }
    }, this);
    return result;
  },

  /**
   * returns filter toolbar
   * @private
   * @deprecated
   * 
   * TODO this seems to be legacy code that is only used in some apps (Calendar, Felamimail, ...)
   *   -> should be removed
   *   -> we use initFilterPanel() now
   */
  getFilterToolbar: function getFilterToolbar(config) {
    config = config || {};
    return new Tine.widgets.grid.FilterPanel(Ext.apply(config, {
      app: this.app,
      recordClass: this.recordClass,
      filterModels: this.recordClass.getFilterModel().concat(this.getCustomfieldFilters()),
      defaultFilter: 'query',
      filters: this.defaultFilters || []
    }));
  },

  /**
   * return store from grid
   * 
   * @return {Ext.data.Store}
   */
  getStore: function getStore() {
    return this.grid.getStore();
  },

  /**
   * return view from grid
   * 
   * @return {Ext.grid.GridView}
   */
  getView: function getView() {
    return this.grid.getView();
  },

  /**
   * return grid
   * 
   * @return {Ext.ux.grid.QuickaddGridPanel|Ext.grid.GridPanel}
   */
  getGrid: function getGrid() {
    return this.grid;
  },

  /**
   * key down handler
   * @private
   */
  onKeyDown: function onKeyDown(e) {
    // no keys for quickadds etc.
    if (e.getTarget('input') || e.getTarget('textarea')) return; // do not catch modified keys (CTRL, ALT)

    if (e.ctrlKey || e.altKey) return;

    switch (e.getKey()) {
      case e.A:
        // select only current page
        this.grid.getSelectionModel().selectAll(true);
        e.stopEvent();
        break;

      case e.C:
        if (this.action_editCopyInNewWindow && !this.action_editCopyInNewWindow.isDisabled()) {
          this.onEditInNewWindow.call(this, {
            actionType: 'copy'
          });
          e.stopEvent();
        }

        break;

      case e.E:
        if (this.action_editInNewWindow && !this.action_editInNewWindow.isDisabled()) {
          this.onEditInNewWindow.call(this, {
            actionType: 'edit'
          });
          e.stopEvent();
        }

        break;

      case e.N:
        if (this.action_addInNewWindow && !this.action_addInNewWindow.isDisabled()) {
          this.onEditInNewWindow.call(this, {
            actionType: 'add'
          });
          e.stopEvent();
        }

        break;

      case e.F:
        if (this.filterToolbar && this.hasQuickSearchFilterToolbarPlugin) {
          e.stopEvent();
          this.filterToolbar.getQuickFilterPlugin().quickFilter.focus();
        }

        break;

      case e.R:
        this.bufferedLoadGridData();
        e.stopEvent();
        break;

      case e.ENTER:
        if (_.isFunction(this.grid.startEditing)) {
          const col = _.find(this.grid.colModel.columns, {
            dataIndex: this.recordClass.getMeta('titleProperty')
          });

          const selections = this.selectionModel.getSelections();

          if (col && selections && selections.length === 1) {
            this.grid.startEditing(this.store.indexOf(selections[0]), _.indexOf(this.grid.colModel.columns, col));
            e.stopEvent();
          }
        }

        break;

      default:
        if ([e.BACKSPACE, e.DELETE].indexOf(e.getKey()) !== -1) {
          if (!this.grid.editing && !this.grid.adding && !this.action_deleteRecord.isDisabled()) {
            this.onDeleteRecords.call(this);
            e.stopEvent();
          }
        }

        if (e.browserEvent.key === '?') {
          // TODO only show keys of actions that are available
          var helpText = i18n._('A: select all visible rows') + '<br/>' + i18n._('C: copy record') + '<br/>' + i18n._('E: edit record') + '<br/>' + i18n._('N: new record') + '<br/>' + i18n._('F: find') + '<br/>' + i18n._('ESC: focus grid') + '<br/>' + i18n._('R: reload grid') + '<br/>';
          Ext.MessageBox.show({
            title: i18n._('Grid Panel Key Bindings'),
            msg: helpText,
            buttons: Ext.Msg.OK,
            icon: Ext.MessageBox.INFO
          });
          e.stopEvent();
        }

    }
  },

  /**
   * row click handler
   * 
   */
  onRowClick: function onRowClick(grid, row, e) {
    var _ = window.lodash,
        sm = grid.getSelectionModel();
    /* TODO check if we need this in IE
    // hack to get percentage editor working
    var cell = Ext.get(grid.getView().getCell(row,1));
    var dom = cell.child('div:last');
    while (cell.first()) {
        cell = cell.first();
        cell.on('click', function(e){
            e.stopPropagation();
            grid.fireEvent('celldblclick', grid, row, 1, e);
        });
    }
    */
    // fix selection of one record if shift/ctrl key is not pressed any longer

    if (e.button === 0 && !e.shiftKey && !e.ctrlKey && !e.getTarget('.x-grid3-row-checker')) {
      if (sm.getCount() == 1 && sm.isSelected(row)) {// return;
      } else {
        sm.clearSelections();
        sm.selectRow(row, false);
        grid.view.focusRow(row);
      }
    }

    if (e.getTarget('.action_attach')) {
      if (Tine.Tinebase.appMgr.isEnabled('Filemanager')) {
        Tine.Filemanager.QuickLookPanel.openWindow({
          record: this.getStore().getAt(row),
          initialApp: this.app,
          sm: sm
        });
      }
    }
  },

  /**
   * row doubleclick handler
   * 
   * @param {} grid
   * @param {} row
   * @param {} e
   */
  onRowDblClick: function onRowDblClick(grid, row, e) {
    this.onEditInNewWindow.call(this, {
      actionType: 'edit'
    });
  },

  /**
   * called on row context click
   * 
   * @param {Ext.grid.GridPanel} grid
   * @param {Number} row
   * @param {Ext.EventObject} e
   */
  onRowContextMenu: function onRowContextMenu(grid, row, e) {
    e.stopEvent();
    var selModel = grid.getSelectionModel();

    if (!selModel.isSelected(row)) {
      // disable preview update if config option is set to false
      this.updateOnSelectionChange = this.updateDetailsPanelOnCtxMenu;
      selModel.selectRow(row);
    }

    var contextMenu = this.getContextMenu(grid, row, e);

    if (contextMenu) {
      contextMenu.showAt(e.getXY());
    } // reset preview update


    this.updateOnSelectionChange = true;
  },

  /**
   * Opens the required EditDialog
   * @param {Object} actionButton the button the action was called from
   * @param {Tine.Tinebase.data.Record} record the record to display/edit in the dialog
   * @param {Array} plugins the plugins used for the edit dialog
   * @param {Object} additionalConfig plain Object, which will be applied to the edit dialog on initComponent
   * @return {Boolean}
   */
  onEditInNewWindow: function onEditInNewWindow(button, record, plugins, additionalConfig) {
    if (!record) {
      if (button.actionType == 'edit' || button.actionType == 'copy') {
        if (!this.action_editInNewWindow || this.action_editInNewWindow.isDisabled()) {
          // if edit action is disabled or not available, we also don't open a new window
          return false;
        }

        var selectedRows = this.grid.getSelectionModel().getSelections();
        record = selectedRows[0];
      } else {
        record = this.createNewRecord();
      }
    } // plugins to add to edit dialog


    var plugins = plugins ? plugins : [];
    var totalcount = this.selectionModel.getCount(),
        selectedRecords = [],
        fixedFields = button.hasOwnProperty('fixedFields') && Ext.isObject(button.fixedFields) ? Ext.encode(button.fixedFields) : null,
        editDialogClass = this.editDialogClass || Tine.widgets.dialog.EditDialog.getConstructor(this.recordClass),
        additionalConfig = additionalConfig ? additionalConfig : {}; // add "multiple_edit_dialog" plugin to dialog, if required

    if (totalcount > 1 && this.multipleEdit && button.actionType == 'edit') {
      Ext.each(this.selectionModel.getSelections(), function (record) {
        selectedRecords.push(record.data);
      }, this);
      plugins.push({
        ptype: 'multiple_edit_dialog',
        selectedRecords: selectedRecords,
        selectionFilter: this.selectionModel.getSelectionFilter(),
        isFilterSelect: this.selectionModel.isFilterSelect,
        totalRecordCount: totalcount
      });
    }

    Tine.log.debug('GridPanel::onEditInNewWindow');
    Tine.log.debug(record);
    var popupWindow = editDialogClass.openWindow(Ext.copyTo(this.editDialogConfig || {}, {
      plugins: Ext.encode(plugins),
      fixedFields: fixedFields,
      additionalConfig: Ext.encode(additionalConfig),
      record: editDialogClass.prototype.mode == 'local' ? Ext.encode(record.data) : record,
      recordId: record.getId(),
      copyRecord: button.actionType == 'copy',
      asAdminModule: this.asAdminModule,
      listeners: {
        scope: this,
        'update': this.selectionModel.getCount() > 1 && this.multipleEdit ? this.onUpdateMultipleRecords : this.onUpdateRecord
      }
    }, 'record,recordId,listeners,fixedFields,copyRecord,plugins,additionalConfig,asAdminModule'));
    return true;
  },

  /**
   * create new record
   *
   * @returns {Tine.Tinebase.data.Record}
   */
  createNewRecord: function createNewRecord() {
    return new this.recordClass(this.recordClass.getDefaultData(), 0);
  },

  /**
   * is called after multiple records have been updated
   */
  onUpdateMultipleRecords: function onUpdateMultipleRecords() {
    this.store.reload();
  },

  onCreateRecord(nodeData, mode) {
    const record = this.createRecord(JSON.stringify(nodeData), mode); // Problem: we can't evaluate filters on client side !!!

    if (mode === 'local') {
      // @TODO add sorted!! (see sort code in onUpdateRecord
      this.store.insert(0, [record]);
    } else {
      this.bufferedLoadGridData({
        removeStrategy: 'keepBuffered'
      });
    }
  },

  createRecord(record, mode) {
    if (!mode && !this.recordProxy) {
      // proxy-less = local if not defined otherwise
      mode = 'local';
    }

    if (Ext.isString(record)) {
      record = this.recordProxy ? this.recordProxy.recordReader({
        responseText: record
      }) : Tine.Tinebase.data.Record.setFromJson(record, this.recordClass);
    } else if (record && Ext.isFunction(record.copy)) {
      record = record.copy();
    }

    if (record.id === 0) {
      // we need to set a id != 0 to make identity handling in stores possible
      // TODO add config for this behaviour?
      record.id = 'new-' + Ext.id();
      record.setId(record.id);
    }

    return record;
  },

  /**
   * on update after edit
   * 
   * @param {String|Tine.Tinebase.data.Record} record
   * @param {String} mode
   */
  onUpdateRecord: function onUpdateRecord(record, mode) {
    if (!this.rendered) {
      return;
    }

    record = this.createRecord(record, mode);
    Tine.log.debug('Tine.widgets.grid.GridPanel::onUpdateRecord() -> record:');
    Tine.log.debug(record, mode);

    if (record && Ext.isFunction(record.copy)) {
      var idx = this.getStore().indexOfId(record.id),
          isSelected = this.getGrid().getSelectionModel().isSelected(idx),
          store = this.getStore();

      if (idx >= 0) {
        // only run do this in local mode as we reload the store in remote mode
        // NOTE: this would otherwise delete the record if a record proxy exists!
        if (mode === 'local') {
          store.removeAt(idx);
          store.insert(idx, [record]);
        }
      } else {
        this.getStore().add([record]);
      } //TODO: use this for msg bus
      // sort new/edited record


      store.remoteSort = false;
      store.sort(_.get(store, 'sortInfo.field', this.recordClass.getMeta('titleField')), _.get(store, 'sortInfo.direction', 'ASC'));
      store.remoteSort = this.storeRemoteSort;

      if (isSelected) {
        this.getGrid().getSelectionModel().selectRow(store.indexOfId(record.id), true);
      }

      this.addToEditBuffer(record);
    }

    if (mode == 'local') {
      this.onStoreUpdate(this.getStore(), record, Ext.data.Record.EDIT);
    } else {
      this.bufferedLoadGridData({
        removeStrategy: 'keepBuffered'
      });
    }
  },
  onMoveRecords: function onMoveRecords() {
    var containerSelectDialog = new Tine.widgets.container.SelectionDialog({
      recordClass: this.recordClass
    });
    containerSelectDialog.on('select', function (dlg, node) {
      var sm = this.grid.getSelectionModel(),
          records = sm.getSelections(),
          recordIds = [].concat(records).map(function (v) {
        return v.id;
      }),
          filter = sm.getSelectionFilter(),
          containerId = node.attributes.id,
          i18nItems = this.app.i18n.n_hidden(this.recordClass.getMeta('recordName'), this.recordClass.getMeta('recordsName'), records.length);

      if (!this.moveMask) {
        this.moveMask = new Ext.LoadMask(this.grid.getEl(), {
          msg: String.format(i18n._('Moving {0}'), i18nItems)
        });
      }

      this.moveMask.show(); // move records to folder

      Ext.Ajax.request({
        params: {
          method: 'Tinebase_Container.moveRecordsToContainer',
          targetContainerId: containerId,
          filterData: filter,
          model: this.recordClass.getMeta('modelName'),
          applicationName: this.recordClass.getMeta('appName')
        },
        scope: this,
        success: function success() {
          this.refreshAfterEdit(recordIds);
          this.onAfterEdit(recordIds);
        },
        failure: function failure(exception) {
          this.refreshAfterEdit(recordIds);
          this.loadGridData();
          Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
        }
      });
    }, this);
  },

  /**
   * is called to resolve conflicts from 2 records
   */
  onResolveDuplicates: function onResolveDuplicates() {
    // TODO: allow more than 2 records      
    if (this.grid.getSelectionModel().getSelections().length != 2) return;
    var selections = [];
    Ext.each(this.grid.getSelectionModel().getSelections(), function (sel) {
      selections.push(sel.data);
    });
    var window = Tine.widgets.dialog.DuplicateMergeDialog.getWindow({
      selections: Ext.encode(selections),
      appName: this.app.name,
      modelName: this.recordClass.getMeta('modelName')
    });
    window.on('contentschange', function () {
      this.store.reload();
    }, this);
  },

  /**
   * add record to edit buffer
   * 
   * @param {String|Tine.Tinebase.data.Record} record
   */
  addToEditBuffer: function addToEditBuffer(record) {
    var recordData = Ext.isString(record) ? Ext.decode(record) : record.data,
        id = recordData[this.recordClass.getMeta('idProperty')];

    if (this.editBuffer.indexOf(id) === -1) {
      this.editBuffer.push(id);
    }
  },

  /**
   * generic delete handler
   */
  onDeleteRecords: function onDeleteRecords(btn, e) {
    var sm = this.grid.getSelectionModel();

    if (sm.isFilterSelect && !this.filterSelectionDelete) {
      Ext.MessageBox.show({
        title: i18n._('Not Allowed'),
        msg: i18n._('You are not allowed to delete all pages at once'),
        buttons: Ext.Msg.OK,
        icon: Ext.MessageBox.INFO
      });
      return;
    }

    var records = sm.getSelectedRecords ? sm.getSelectedRecords() : sm.getSelections();

    if (this.disableDeleteConfirmation || Tine[this.app.appName].registry.get('preferences') && Tine[this.app.appName].registry.get('preferences').get('confirmDelete') !== null && Tine[this.app.appName].registry.get('preferences').get('confirmDelete') == 0) {
      // don't show confirmation question for record deletion
      this.deleteRecords(sm, records);
    } else {
      var recordNames = records[0].getTitle();

      if (records.length > 1) {
        recordNames += ', ...';
      }

      var i18nQuestion = this.i18nDeleteQuestion ? this.app.i18n.n_hidden(this.i18nDeleteQuestion[0], this.i18nDeleteQuestion[1], records.length) : String.format(i18n.ngettext('Do you really want to delete the selected record ({0})?', 'Do you really want to delete the selected records ({0})?', records.length), recordNames);
      Ext.MessageBox.confirm(i18n._('Confirm'), i18nQuestion, function (btn) {
        if (btn == 'yes') {
          this.deleteRecords(sm, records);
        }
      }, this);
    }
  },

  /**
   * delete records
   * 
   * @param {SelectionModel} sm
   * @param {Array} records
   */
  deleteRecords: function deleteRecords(sm, records) {
    // directly remove records from the store (only for non-filter-selection)
    if (Ext.isArray(records) && !(sm.isFilterSelect && this.filterSelectionDelete)) {
      Ext.each(records, function (record) {
        this.store.remove(record);
      }); // if nested in an editDialog, just change the parent record

      if (this.editDialog && this.editDialogRecordProperty) {
        var items = [];
        this.store.each(function (item) {
          items.push(item.data);
        });
        this.editDialog.record.set(this.editDialogRecordProperty, items);
        this.editDialog.fireEvent('updateDependent');
        return;
      }
    }

    if (this.recordProxy) {
      if (this.usePagingToolbar) {
        this.pagingToolbar.refresh.disable();
      }

      var i18nItems = this.app.i18n.n_hidden(this.recordClass.getMeta('recordName'), this.recordClass.getMeta('recordsName'), records.length),
          recordIds = [].concat(records).map(function (v) {
        return v.id;
      });

      if (sm.isFilterSelect && this.filterSelectionDelete) {
        if (!this.deleteMask) {
          this.deleteMask = new Ext.LoadMask(this.grid.getEl(), {
            msg: String.format(i18n._('Deleting {0}'), i18nItems) + ' ' + i18n._('... This may take a long time!')
          });
        }

        this.deleteMask.show();
      }

      this.deleteQueue = this.deleteQueue.concat(recordIds);
      var options = {
        scope: this,
        success: function success() {
          this.refreshAfterDelete(recordIds);
          this.onAfterDelete(recordIds);
        },
        failure: function failure(exception) {
          this.onDeleteFailure(recordIds, exception);
        }
      };

      if (sm.isFilterSelect && this.filterSelectionDelete) {
        this.recordProxy.deleteRecordsByFilter(sm.getSelectionFilter(), options);
      } else {
        this.recordProxy.deleteRecords(records, options);
      }
    }
  },

  /**
   * refresh after delete (hide delete mask or refresh paging toolbar)
   */
  refreshAfterDelete: function refreshAfterDelete(ids) {
    this.deleteQueue = this.deleteQueue.diff(ids);

    if (this.deleteMask) {
      this.deleteMask.hide();
    }

    if (this.usePagingToolbar) {
      this.pagingToolbar.refresh.show();
    }
  },

  /**
   * do something after deletion of records
   * - reload the store
   * 
   * @param {Array} [ids]
   */
  onAfterDelete: function onAfterDelete(ids) {
    this.editBuffer = this.editBuffer.diff(ids);
    this.bufferedLoadGridData({
      removeStrategy: 'keepBuffered'
    });
  },

  /**
   * do something on delete failure
   *
   * @param ids
   * @param exception
   */
  onDeleteFailure: function onDeleteFailure(ids, exception) {
    this.refreshAfterDelete(ids);
    this.loadGridData();
    Tine.Tinebase.ExceptionHandler.handleRequestException(exception, function () {
      this.refreshAfterDelete(ids);
      this.onAfterDelete(ids);
    }, this);
  },

  /**
   * refresh after edit/move
   */
  refreshAfterEdit: function refreshAfterEdit(ids) {
    this.editBuffer = this.editBuffer.diff(ids);

    if (this.moveMask) {
      this.moveMask.hide();
    }

    if (this.editMask) {
      this.editMask.hide();
    }

    if (this.usePagingToolbar) {
      this.pagingToolbar.refresh.show();
    }
  },

  /**
   * do something after edit of records
   *
   * @param {Array} [ids]
   */
  onAfterEdit: function onAfterEdit(ids) {
    this.editBuffer = this.editBuffer.diff(ids);
    this.bufferedLoadGridData({
      removeStrategy: 'keepBuffered'
    });
  }
});

/***/ }),
/* 1367 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2013-2015 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.grid');
/**
 * Bbar Grid Panel
 * 
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.GridPanel
 * @extends     Tine.widgets.grid.GridPanel
 * 
 * <p>Bbar Grid Panel</p>
 * <p><pre>
 *     Grid panel with bottom toolbar for add/edit/delete buttons
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.grid.BbarGridPanel
 */

Tine.widgets.grid.BbarGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
  editDialogRecordProperty: null,
  editDialog: null,
  storeRemoteSort: false,
  usePagingToolbar: false,

  /**
   * inits this cmp
   * 
   * @private
   */
  initComponent: function initComponent() {
    this.bbar = [];
    this.i18nEmptyText = this.i18nEmptyText || String.format(i18n._("There could not be found any {0}. Please try to change your filter-criteria or view-options."), this.i18nRecordsName);
    Tine.widgets.grid.BbarGridPanel.superclass.initComponent.call(this);
    this.fillBottomToolbar();
    this.store.on('add', this.updateTitle, this);
    this.store.on('remove', this.updateTitle, this); // update count of tab

    if (this.editDialogRecordProperty) {
      (function () {
        this.updateTitle(this.editDialog.record.data.hasOwnProperty(this.editDialogRecordProperty) && this.editDialog.record.data[this.editDialogRecordProperty] ? this.editDialog.record.data[this.editDialogRecordProperty].length : 0);
      }).defer(100, this);
    }
  },

  /**
   * overwrites the default function
   */
  initFilterPanel: function initFilterPanel() {},

  /**
   * updates the title ot the tab
   * 
   * @param {Number} count
   */
  updateTitle: function updateTitle(count) {
    count = Ext.isNumber(count) ? count : this.store.getCount();
    this.setTitle((count > 1 ? this.i18nRecordsName : this.i18nRecordName) + ' (' + count + ')');
  },

  /**
   * will be called in Edit Dialog Mode
   */
  fillBottomToolbar: function fillBottomToolbar() {
    var tbar = this.getBottomToolbar();
    tbar.addButton(new Ext.Button(this.action_editInNewWindow));
    tbar.addButton(new Ext.Button(this.action_addInNewWindow));
    tbar.addButton(new Ext.Button(this.action_deleteRecord));
  }
});

/***/ }),
/* 1368 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.keyfield');
/**
 * @namespace   Tine.Tasks
 * @class       Tine.Tinebase.widgets.keyfield.Filter
 * @extends     Tine.widgets.grid.FilterModel
 * 
 * @author      Philipp Schüle <p.schuele@metaways.de>
 */

Tine.Tinebase.widgets.keyfield.Filter = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @property Tine.Tinebase.Application app
   */
  app: null,

  /**
   * @cfg
   * @type String
   */
  keyfieldName: null,
  defaultOperator: 'in',

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.operators = ['in', 'notin'];

    if (this.defaultAll) {
      this.defaultValue = [];
      Tine.Tinebase.widgets.keyfield.StoreMgr.get(this.app.name, this.keyfieldName).each(function (keyFieldRecord) {
        this.defaultValue.push(keyFieldRecord.get('id'));
      }, this);
    }

    Tine.Tinebase.widgets.keyfield.Filter.superclass.initComponent.call(this);
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    var value = new Tine.Tinebase.widgets.keyfield.FilterValueField({
      app: this.app,
      filter: filter,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      renderTo: el,
      keyfieldName: this.keyfieldName
    });
    value.on('specialkey', function (field, e) {
      if (e.getKey() == e.ENTER) {
        this.onFiltertrigger();
      }
    }, this);
    value.on('select', this.onFiltertrigger, this);
    return value;
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tine.widget.keyfield.filter'] = Tine.Tinebase.widgets.keyfield.Filter;
/**
 * @namespace   Tine.Tasks
 * @class       Tine.Tinebase.widgets.keyfield.FilterValueField
 * @extends     Ext.ux.form.LayerCombo
 * 
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * 
 * TODO think about using Tine.widgets.grid.PickerFilterValueField
 */

Tine.Tinebase.widgets.keyfield.FilterValueField = Ext.extend(Ext.ux.form.LayerCombo, {
  hideButtons: false,
  formConfig: {
    labelAlign: 'left',
    labelWidth: 30
  },

  /**
   * @property Tine.Tinebase.Application app
   */
  app: null,

  /**
   * @cfg
   * @type String
   */
  keyfieldName: null,
  getFormValue: function getFormValue() {
    var ids = [];
    var keyfieldStore = Tine.Tinebase.widgets.keyfield.StoreMgr.get(this.app.name, this.keyfieldName);
    var formValues = this.getInnerForm().getForm().getValues();

    for (var id in formValues) {
      if (formValues[id] === 'on' && keyfieldStore.getById(id)) {
        ids.push(id);
      }
    }

    return ids;
  },
  getItems: function getItems() {
    var items = [];
    Tine.Tinebase.widgets.keyfield.StoreMgr.get(this.app.name, this.keyfieldName).each(function (keyfieldRecord) {
      var checkbox = {
        xtype: 'checkbox',
        boxLabel: keyfieldRecord.get('i18nValue'),
        icon: keyfieldRecord.get('icon'),
        name: keyfieldRecord.get('id')
      };

      if (checkbox.icon) {
        checkbox.boxLabel = '<img src="' + keyfieldRecord.get('icon') + '" class="tine-keyfield-icon"/>' + checkbox.boxLabel;
      }

      items.push(checkbox);
    }, this);
    return items;
  },

  /**
   * @param {String} value
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    value = Ext.isArray(value) ? value : [value];
    value = value.map(function (v) {
      return String(v);
    });
    var keyfieldRecordText = [];
    this.currentValue = [];
    Tine.Tinebase.widgets.keyfield.StoreMgr.get(this.app.name, this.keyfieldName).each(function (keyfieldRecord) {
      var id = keyfieldRecord.get('id');
      var name = keyfieldRecord.get('i18nValue');

      if (value.indexOf(id) >= 0) {
        keyfieldRecordText.push(name);
        this.currentValue.push(id);
      }
    }, this);
    this.setRawValue(keyfieldRecordText.join(', '));
    return this;
  },

  /**
   * sets values to innerForm
   */
  setFormValue: function setFormValue(value) {
    this.getInnerForm().getForm().items.each(function (item) {
      item.setValue(value.indexOf(item.name) >= 0 ? 'on' : 'off');
    }, this);
  }
});

/***/ }),
/* 1369 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2015 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.keyfield');
/**
 * quickadd grid panel
 *
 * @TODO: add extra options hasColor, hasIcon, hasStandard?
 * 
 * @namespace   Tine.Tinebase.widgets.keyfield
 * @class       Tine.Tinebase.widgets.keyfield.ConfigGrid
 * @extends     Tine.widgets.grid.QuickaddGridPanel
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2015 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.Tinebase.widgets.keyfield.ConfigGrid
 */

Tine.Tinebase.widgets.keyfield.ConfigGrid = Ext.extend(Tine.widgets.grid.QuickaddGridPanel, {
  /**
   * @cfg {record} (optional) configRecord keyFieldConfig record
   */
  configRecord: null,
  keyFieldOptions: null,
  autoExpandColumn: 'value',
  quickaddMandatory: 'id',
  resetAllOnNew: true,
  useBBar: true,
  border: false,
  defaultCheck: null,
  hasDefaultCheck: true,
  cols: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    if (this.configRecord) {
      // used withing config system
      this.keyFieldOptions = this.configRecord.get('options') || {};
      this.configApp = Tine.Tinebase.appMgr.getById(this.configRecord.get('application_Id'));
    } else {
      // defaults
      this.keyFieldOptions = {
        recordModel: 'Tinebase_Model_KeyFieldRecord'
      };
    }

    this.keyFieldConfig = {};
    this.configI18n = this.configApp ? this.configApp.i18n : i18n;
    this.initStore();

    if (this.hasDefaultCheck) {
      this.defaultCheck = new Ext.ux.grid.CheckColumn({
        id: 'default',
        header: i18n._('Default'),
        dataIndex: 'default',
        sortable: false,
        align: 'center',
        width: 55
      });
      this.plugins = [this.defaultCheck];
    }

    Tine.Tinebase.widgets.keyfield.ConfigGrid.superclass.initComponent.call(this);
    this.getSelectionModel().on('selectionchange', function (sm) {
      var rows = sm.getSelections();
      deletedDisabled = rows.length == 0;
      Ext.each(sm.getSelections(), function (record) {
        deletedDisabled |= record.data.system;
      });
      this.deleteAction.setDisabled(deletedDisabled);
    }, this);
    this.on('beforeedit', this.onBeforeValueEdit, this);
  },

  /**
   * init keyfield store
   *
   * for "normal" keyFields we could work on the default store (client side)
   * this way the client dosn't need a client reload
   *
   *
   */
  initStore: function initStore() {
    var recordClass = this.keyFieldOptions.recordModel && Tine.Tinebase.data.RecordMgr.get(this.keyFieldOptions.recordModel) || Tine.Tinebase.Model.KeyFieldRecord,
        fields = [].concat(recordClass.getFieldDefinitions()); // add default field

    if (this.hasDefaultCheck) {
      fields.unshift({
        name: 'default'
      });
    }

    this.recordClass = Tine.Tinebase.data.Record.create(fields, {});
    this.store = new Ext.data.Store({
      reader: new Ext.data.ArrayReader({
        idIndex: 0
      }, this.recordClass),
      listeners: {
        scope: this,
        'update': function update(store, rec, operation) {
          rec.commit(true); // be sure that only one default is checked

          if (this.hasDefaultCheck && rec.get('default')) {
            // reset other default of same parentId
            var parentId = this.getParentId(rec);
            store.each(function (r) {
              if (this.getParentId(r) == parentId && r.id !== rec.id) {
                r.set('default', false);
                r.commit(true);
              }
            }, this);
          }
        }
      }
    });
  },
  getParentId: function getParentId(r) {
    var parts = String(r.get('id')).split(':'),
        parentId = parts.length > 1 ? parts[0] : '';
    return parentId;
  },

  /**
   * @returns {Ext.grid.ColumnModel}
   */
  getColumnModel: function getColumnModel() {
    if (!this.cols) {
      var fields = this.recordClass.getFieldDefinitions(),
          cols = [this.defaultCheck, {
        id: 'id',
        header: i18n._('ID'),
        dataIndex: 'id',
        hideable: false,
        sortable: false,
        editor: new Ext.form.TextField({}),
        quickaddField: new Ext.form.TextField({
          emptyText: i18n._('Add a New ID...')
        })
      }, {
        id: 'value',
        header: i18n._('Value'),
        dataIndex: 'value',
        hideable: false,
        sortable: false,
        editor: new Ext.form.TextField({}),
        quickaddField: new Ext.form.TextField({
          emptyText: i18n._('Add a New Value...')
        })
      }];
      Ext.each(fields, function (field) {
        if (['default', 'id', 'value', 'i18nValue', 'system'].indexOf(field.name) == -1) {
          switch (field.name) {
            case 'color':
              cols.push({
                id: 'color',
                header: i18n._('Color'),
                dataIndex: 'color',
                sortable: false,
                width: 50,
                editor: new Ext.ux.form.ColorField({}),
                renderer: Tine.Tinebase.common.colorRenderer
              });
              break;

            case 'icon':
              // not supported yet
              break;

            default:
              cols.push(this.getColumn(field));
              break;
          }
        }
      }, this);
    } else {
      cols = this.cols;
    }

    return new Ext.grid.ColumnModel(cols);
  },
  getColumn: function getColumn(field) {
    var col = {
      id: field.name,
      header: field.label ? this.configI18n._(field.label) : field.name,
      dataIndex: field.name,
      sortable: false,
      width: field.uiConfig && field.uiConfig.width ? field.uiConfig.width : 50
    };

    switch (field.type) {
      case 'bool':
        Ext.applyIf(col, {
          align: 'center',
          width: 55
        });
        col = new Ext.ux.grid.CheckColumn(col);
        this.plugins.push(col);
        break;

      case 'percentage':
        Ext.applyIf(col, {
          renderer: Ext.ux.PercentRenderer,
          editor: new Ext.ux.PercentCombo({
            autoExpand: true,
            blurOnSelect: true
          }),
          quickaddField: new Ext.ux.PercentCombo({
            autoExpand: true
          })
        });
        break;

      default:
        col.editor = new Ext.form.TextField({});
        break;
    }

    return col;
  },
  onBeforeValueEdit: function onBeforeValueEdit(o) {
    if (o.record.data.system == true) {
      o.cancel = true;
    }
  },

  /**
  * Do some checking on new entry add
  * 
  * @param {Object} recordData
  */
  onNewentry: function onNewentry(recordData) {
    // check if id exists in grid
    if (this.store.findExact('id', recordData.id) !== -1) {
      Ext.Msg.alert(i18n._('Error'), i18n._('ID already exists'));
      return false;
    }

    if (this.keyFieldOptions.parentField && !String(recordData.id).match(/^.+:.+$/)) {
      Ext.Msg.alert(i18n._('Error'), i18n._('ID needs to follow the syntax PARENTID:ID'));
      return false;
    } // if value is empty, set it to ID


    if (Ext.isEmpty(recordData.value)) {
      recordData.value = recordData.id;
    }

    Tine.Tinebase.widgets.keyfield.ConfigGrid.superclass.onNewentry.apply(this, arguments);
  },

  /**
   * @param value
   */
  setValue: function setValue(value) {
    this.keyFieldConfig = Ext.decode(Ext.encode(value));
    this.setStoreFromArray(value.records); // if there is default value check it

    if (value['default']) {
      // there might be multiple defaults in case of dependend keyFields
      var defaults = Ext.isArray(value['default']) ? value['default'] : [value['default']];
      Ext.each(defaults, function (def) {
        var defaultRecIdx = this.store.findExact('id', def);

        if (defaultRecIdx !== -1) {
          this.store.getAt(defaultRecIdx).set('default', true);
        }
      }, this);
    }
  },

  /**
   * @returns {Array}
   */
  getValue: function getValue() {
    // don't touch other configs than records & default
    var value = Ext.decode(Ext.encode(this.keyFieldConfig)) || {};
    var records = [],
        defaults = [];
    this.store.each(function (rec) {
      var data = Ext.apply({}, rec.data);

      if (data['default'] == true) {
        defaults.push(data.id);
      }

      delete data['default'];
      records.push(data);
    });
    value['records'] = records;
    value['default'] = Ext.isArray(value['default']) ? defaults : defaults[0];
    Tine.Tinebase.common.assertComparable(value);
    return value;
  },

  /**
   * @returns {boolean}
   */
  isValid: function isValid() {
    return true;
  }
});

/***/ }),
/* 1370 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2015 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase.widgets.keyfield');
/**
 * config grid panel
 *
 * @namespace   Tine.Admin.config
 * @class       Tine.Admin.config.ConfigField
 * @extends     Tine.widgets.grid.LayerCombo
 */

Tine.Tinebase.widgets.keyfield.ConfigField = Ext.extend(Ext.ux.form.LayerCombo, {
  /**
   * @cfg {Admin.Model.Config} ConfigRecord
   */
  configRecord: null,
  hideButtons: false,
  layerAlign: 'tr-br?',
  minLayerWidth: 400,
  layerHeight: 300,
  allowBlur: true,
  lazyInit: true,
  formConfig: {
    labelAlign: 'left',
    labelWidth: 30
  },
  configGrid: null,
  initComponent: function initComponent() {
    this.on('beforecollapse', this.onBeforeCollapse, this);
    this.supr().initComponent.call(this);
  },
  getFormValue: function getFormValue() {
    return this.configGrid.getValue();
  },
  getItems: function getItems() {
    this.configGrid = new Tine.Tinebase.widgets.keyfield.ConfigGrid({
      title: i18n._('Key Field Records'),
      height: this.layerHeight - 40 || 'auto',
      configRecord: this.configRecord,
      onStoreChange: Ext.emptyFn
    });
    return [this.configGrid];
  },

  /**
   * cancel collapse if ctx menu is shown
   */
  onBeforeCollapse: function onBeforeCollapse() {
    return (!this.configGrid.contextMenu || this.configGrid.contextMenu.hidden) && !this.configGrid.editing;
  },

  /**
   * @param {String} value
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    this.currentValue = value;
    Tine.Tinebase.common.assertComparable(this.currentValue);
    this.setRawValue('...');
    return this;
  },

  /**
   * sets values to innerForm
   */
  setFormValue: function setFormValue(value) {
    this.configGrid.setValue(this.currentValue);
  }
});

/***/ }),
/* 1371 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tree');
/**
 * generic tree loader for tine trees
 * - calls json method with a filter to return children of a node
 * 
 * @namespace   Tine.widgets.tree
 * @class       Tine.widgets.tree.Loader
 * @extends     Ext.tree.TreeLoader
 */

Tine.widgets.tree.Loader = Ext.extend(Ext.tree.TreeLoader, {
  /**
   * @cfg {Number} how many chars of the containername to display
   */
  displayLength: 25,

  /**
   * @cfg {application}
   */
  app: null,

  /**
   * 
   * @cfg {String} method
   */
  method: null,

  /**
   * 
   * @cfg {Array} of filter objects for search method 
   */
  filter: null,
  url: 'index.php',
  initComponent: function initComponent() {
    this.addEvents(
    /**
     * Fires when virtual nodes are selected
     *
     * @param selected nodes
     */
    'virtualNodesSelected');
    this.supr().initComponent.apply(this, arguments);
  },

  /**
   * @private
   */
  createNode: function createNode() {
    this.inspectCreateNode.apply(this, arguments);
    return Tine.widgets.tree.Loader.superclass.createNode.apply(this, arguments);
  },

  /**
   * returns params for async request
   * 
   * @param {Ext.tree.TreeNode} node
   * @return {Object}
   */
  getParams: function getParams(node) {
    return {
      method: this.method,
      filter: this.filter
    };
  },

  /**
   * template fn for subclasses to inspect createNode
   * 
   * @param {Object} attr
   */
  inspectCreateNode: Ext.EmptyFn,
  processResponse: function processResponse(response, node, callback, scope) {
    // convert tine search response into usual treeLoader structure
    var o = response.responseData || Ext.decode(response.responseText);
    response.responseData = o.hasOwnProperty('totalcount') ? o.results : o; // processed nodes / structures

    var newResponse = []; // read every node

    Ext.each(response.responseData, function (node) {
      var containerName,
          parentNode = newResponse;

      if (!Ext.isString(node.name)) {
        parentNode.push(node);
        return;
      } // Get folder name to final container
      // NOTE: if hierarchy ends with a "/" name gets appended otherwise last part of hierarchy is the display name


      var hierarchy = String(node.hierarchy).match(/\/$/) || !node.hierarchy ? node.hierarchy || '' + node.name : node.hierarchy,
          parts = Ext.isString(hierarchy) ? hierarchy.split("/") : [''];
      containerName = parts[parts.length - 1]; // Remove first "" and last item because they don't belong to the folder names
      // This could be "" if the name starts with a /

      if (parts[0] === "") {
        parts.shift();
      }

      parts.pop();
      Ext.each(parts, function (part, idx, parts, node) {
        var child = this.findNodeByName(part, parentNode);
        this.preloadChildren = true;

        if (!child) {
          var reducedParts = []; // add shared or personal

          reducedParts.push(node.path.split('/')[1]);

          if (node.path.match(/^\/personal/)) {
            // add accountId
            reducedParts.push(node.path.split('/')[2]);
          } // create a path for each virtual node, this path is actually invalid and won't be send to server!


          for (var i = 0; i <= parts.indexOf(part); ++i) {
            reducedParts.push(parts[i]);
          }

          child = {
            'name': part,
            'path': '/' + reducedParts.join('/'),
            'id': Ext.id(),
            'children': [],
            'leaf': false,
            'editable': false,
            'draggable': false,
            'allowDrag': false,
            'allowDrop': false,
            'singleClickExpand': true,
            'listeners': {
              'click': function (node) {
                node.expand(true, true, function (node) {
                  var nodes = [];
                  this.findAllNodes(node, nodes);
                  this.fireEvent('virtualNodesSelected', nodes);
                }.createDelegate(this, [node], false));
                return false;
              }.createDelegate(this)
            }
          };
          parentNode.push(child);
        }

        parentNode = child.children;
      }.createDelegate(this, [node], true), this);
      var nodePathSegments = node.path.split('/');
      var containerId = nodePathSegments.pop();
      nodePathSegments = nodePathSegments.concat(parts);
      nodePathSegments.push(containerId);
      node.longName = node.name;
      node.text = node.name = containerName;
      node.originalPath = node.path;
      node.path = nodePathSegments.join('/');
      parentNode.leaf = true;
      parentNode.push(node);
    }, this);
    response.responseData = newResponse;
    return Tine.widgets.tree.Loader.superclass.processResponse.apply(this, arguments);
  },

  /**
   * Finds children of a node
   *
   * @param node
   * @param nodes
   */
  findAllNodes: function findAllNodes(node, nodes) {
    if (node.leaf && !node.hasChildNodes()) {
      nodes.push(node);
    }

    for (var i = 0; i < node.childNodes.length; i++) {
      this.findAllNodes(node.childNodes[i], nodes);
    }
  },

  /**
   * Search for a node and return if exists
   *
   * @param {string} name
   * @param {object} nodes
   * @return {mixed} node
   */
  findNodeByName: function findNodeByName(name, nodes) {
    var ret = false;
    Ext.each(nodes, function (node) {
      if (node && node.name && node.name == name && Ext.isArray(node.children)) {
        ret = node;
      }
    }, this);
    return ret;
  }
});

/***/ }),
/* 1372 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tree');
/**
 * returns generic tree context menu with
 * - create/add
 * - rename
 * - delete
 * - edit grants
 * 
 * ctxNode class var is required in calling class
 */

Tine.widgets.tree.ContextMenu = {
  /**
   * @cfg {Tine.widgets.ActionManager} actionMgr
   */
  actionMgr: null,

  /**
   * create new Ext.menu.Menu with actions
   * 
   * @param {} config has the node name, actions, etc.
   * @param [] additional menu plugins
   * @return {}
   */
  getMenu: function getMenu(config, plugins) {
    this.config = config;
    /****************** create ITEMS array ****************/

    this.action_add = new Ext.Action({
      text: String.format(i18n._('Add {0}'), this.config.nodeName),
      iconCls: 'action_add',
      handler: this.addNode,
      requiredGrant: 'addGrant',
      scope: this.config
    });
    this.action_rename = new Ext.Action({
      text: String.format(i18n._('Rename {0}'), this.config.nodeName),
      iconCls: 'action_rename',
      handler: this.renameNode,
      scope: this.config,
      requiredGrant: 'editGrant',
      allowMultiple: false
    });
    this.action_delete = new Ext.Action({
      text: String.format(i18n.ngettext('Delete {0}', 'Delete {0}', 1), this.config.nodeName),
      iconCls: 'action_delete',
      handler: this.deleteNode,
      scope: this.config,
      requiredGrant: 'deleteGrant',
      allowMultiple: true
    });
    this.action_grants = new Ext.Action({
      text: String.format(i18n._('Manage {0} Permissions'), this.config.nodeName),
      iconCls: 'action_managePermissions',
      handler: this.managePermissions,
      requiredGrant: 'editGrant',
      scope: this.config
    });
    this.action_properties = new Ext.Action({
      text: String.format(i18n._('{0} Properties'), this.config.nodeName),
      iconCls: 'action_manageProperties',
      handler: this.manageProperties,
      requiredGrant: 'readGrant',
      scope: this.config
    }); // TODO is edit grant required?

    this.action_changecolor = new Ext.Action({
      text: String.format(i18n._('Set {0} color'), this.config.nodeName),
      iconCls: 'action_changecolor',
      //            requiredGrant: 'editGrant',
      allowMultiple: true,
      menu: new Ext.menu.ColorMenu({
        scope: this,
        listeners: {
          show: function show(cmp) {
            const colorPalette = cmp.items.get(0);
            colorPalette.suspendEvents();
            colorPalette.select(this.scope.ctxNode.attributes.color);
            colorPalette.resumeEvents();
          },
          select: this.changeNodeColor,
          scope: this.config
        }
      })
    });
    this.action_reload = new Ext.Action({
      text: String.format(i18n._('Reload {0}'), this.config.nodeName),
      iconCls: 'x-tbar-loading',
      handler: this.reloadNode,
      scope: this.config
    }); // TODO move the next 5 to Filemanager!

    this.action_resume = new Ext.Action({
      text: String.format(i18n._('Resume upload'), config.nodeName),
      iconCls: 'action_resume',
      handler: this.onResume,
      scope: this.config,
      actionUpdater: this.isResumeEnabled
    });
    this.action_pause = new Ext.Action({
      text: String.format(i18n._('Pause upload'), config.nodeName),
      iconCls: 'action_pause',
      handler: this.onPause,
      actionUpdater: this.isPauseEnabled,
      scope: this.config
    });
    this.action_download = new Ext.Action({
      text: String.format(i18n._('Download'), config.nodeName),
      iconCls: 'action_filemanager_save_all',
      handler: this.downloadFile,
      actionUpdater: this.isDownloadEnabled,
      scope: this.config
    });
    this.action_publish = new Ext.Action({
      text: String.format(i18n._('Publish'), config.nodeName),
      iconCls: 'action_publish',
      handler: this.publishFile,
      actionUpdater: true,
      scope: this.config
    });
    var items = [],
        method = '',
        action;

    for (var i = 0; i < config.actions.length; i++) {
      action = config.actions[i];

      if (Ext.isString(action)) {
        method = 'action_' + action;

        if (this.actionMgr && this.actionMgr.has(action)) {
          items.push(this.actionMgr.get(action));
        } else if (this[method]) {
          items.push(this[method]);
        } else {
          Tine.log.warn('Tine.widgets.tree.ContextMenu.getMenu: action "' + action + '" is not definded');
          continue;
        }
      } else if (action && action.isAction) {
        items.push(action);
      } else if (Ext.isObject(action)) {
        items.push(new Ext.Action(action));
      } else {
        Tine.log.warn('Tine.widgets.tree.ContextMenu.getMenu: can\'t cope with action :');
        Tine.log.warn(action);
      }
    }
    /******************* return menu **********************/


    var menuPlugins = [{
      ptype: 'ux.itemregistry',
      key: 'Tinebase-MainContextMenu'
    }];

    if (plugins) {
      menuPlugins = menuPlugins.concat(plugins);
    }

    return new Ext.menu.Menu({
      plugins: menuPlugins,
      items: items
    });
  },

  /**
   * create tree node
   */
  addNode: function addNode() {
    Ext.MessageBox.prompt(String.format(i18n._('New {0}'), this.nodeName), String.format(i18n._('Please enter the name of the new {0}:'), this.nodeName), function (_btn, _text) {
      if (this.scope.ctxNode && _btn == 'ok') {
        if (!_text) {
          Ext.Msg.alert(String.format(i18n._('No {0} added'), this.nodeName), String.format(i18n._('You have to supply a {0} name!'), this.nodeName));
          return;
        }

        Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Creating {0}...'), this.nodeName));
        var parentNode = this.scope.ctxNode;
        var params = {
          method: this.backend + '.add' + this.backendModel,
          name: _text
        }; // TODO try to generalize this and move app specific stuff to app

        if (this.backendModel == 'Node') {
          params.application = this.scope.app.appName || this.scope.appName;
          var filename = parentNode.attributes.nodeRecord.data.path + '/' + _text;
          params.filename = filename;
          params.type = 'folder';
          params.method = this.backend + ".createNode";
        } else if (this.backendModel == 'Container') {
          params.application = this.scope.app.appName || this.scope.appName;
          params.containerType = Tine.Tinebase.container.path2type(parentNode.attributes.path);
          params.modelName = this.scope.app.getMainScreen().getActiveContentType();
          if (params.modelName == '') params.modelName = this.scope.contextModel;
        }

        Ext.Ajax.request({
          params: params,
          scope: this,
          success: function success(result, request) {
            var nodeData = Ext.util.JSON.decode(result.responseText);

            if (nodeData.length == 0) {
              Tine.log.err('Server returned empty node data!');
              Ext.MessageBox.hide();
              return;
            }

            var newNode = this.scope.loader.createNode(nodeData);
            parentNode.expand();
            parentNode.appendChild(newNode);
            this.scope.fireEvent('containeradd', nodeData);
            Ext.MessageBox.hide();
          },
          failure: function failure(result, request) {
            var nodeData = Ext.util.JSON.decode(result.responseText);
            var appContext = Tine[this.scope.app.appName];

            if (appContext && appContext.handleRequestException) {
              appContext.handleRequestException(nodeData.data);
            }
          }
        });
      }
    }, this);
  },

  /**
   * rename tree node
   */
  renameNode: function renameNode() {
    if (this.scope.ctxNode) {
      var node = this.scope.ctxNode;
      Ext.MessageBox.show({
        title: String.format(i18n._('Rename {0}'), this.nodeName),
        msg: String.format(i18n._('Please enter the new name of the {0}:'), this.nodeName),
        buttons: Ext.MessageBox.OKCANCEL,
        value: Ext.util.Format.htmlDecode(node.attributes.longName || node.text),
        fn: function fn(_btn, _text) {
          if (_btn == 'ok') {
            if (!_text) {
              Ext.Msg.alert(String.format(i18n._('Not renamed {0}'), this.nodeName), String.format(i18n._('You have to supply a {0} name!'), this.nodeName));
              return;
            }

            var params = {
              method: this.backend + '.rename' + this.backendModel,
              newName: _text
            };
            params.application = this.scope.app.appName || this.scope.appName;

            if (this.backendModel == 'Node') {
              var filename = node.attributes.path;
              params.sourceFilenames = [filename];
              var targetFilename = "/";
              var sourceSplitArray = filename.split("/");

              for (var i = 1; i < sourceSplitArray.length - 1; i++) {
                targetFilename += sourceSplitArray[i] + '/';
              }

              params.destinationFilenames = [targetFilename + _text];
              params.method = this.backend + '.moveNodes';
            } // TODO try to generalize this


            if (this.backendModel == 'Container') {
              params.containerId = node.attributes.container.id;
            } else if (this.backendModel == 'Folder') {
              var folder = Tine.Tinebase.appMgr.get('Felamimail').getFolderStore().getById(node.attributes.folder_id);
              params.oldGlobalName = folder.get('globalname');
              params.accountId = folder.get('account_id');
            }

            Ext.Ajax.request({
              params: params,
              scope: this,
              success: function success(_result, _request) {
                var nodeData = Ext.util.JSON.decode(_result.responseText);
                node.setText(Ext.util.Format.htmlEncode(_text));
                this.scope.fireEvent('containerrename', nodeData, node, _text);
              },
              failure: function failure(result, request) {
                var nodeData = Ext.util.JSON.decode(result.responseText);
                var appContext = Tine[this.scope.app.appName];

                if (appContext && appContext.handleRequestException) {
                  appContext.handleRequestException(nodeData.data);
                }
              }
            });
          }
        },
        scope: this,
        prompt: true,
        icon: Ext.MessageBox.QUESTION
      });
    }
  },

  /**
   * delete tree node
   */
  deleteNode: function deleteNode() {
    if (this.scope.ctxNode) {
      var node = this.scope.ctxNode;
      Tine.log.debug('Tine.widgets.tree.ContextMenu::deleteNode()');
      Tine.log.debug(node);
      Ext.MessageBox.confirm(i18n._('Confirm'), String.format(i18n._('Do you really want to delete the {0} "{1}"?'), this.nodeName, node.text), function (_btn) {
        if (_btn == 'yes') {
          var params = {
            method: this.backend + '.delete' + this.backendModel
          };

          if (this.backendModel == 'Node') {
            var filenames = [node.attributes.path];
            params.application = this.scope.app.appName || this.scope.appName;
            params.filenames = filenames;
            params.method = this.backend + ".deleteNodes";
          } else if (this.backendModel == 'Container') {
            params.containerId = node.attributes.container.id;
          } else if (this.backendModel == 'Folder') {
            var folder = Tine.Tinebase.appMgr.get('Felamimail').getFolderStore().getById(node.attributes.folder_id);
            params.folder = folder.get('globalname');
            params.accountId = folder.get('account_id');
          } else {
            // use default json api style
            params.ids = [node.id];
            params.method = params.method + 's';
          }

          Ext.Ajax.request({
            params: params,
            scope: this,
            success: function success(_result, _request) {
              if (node) {
                if (node.isSelected()) {
                  this.scope.getSelectionModel().select(node.parentNode);
                  this.scope.fireEvent('click', node.parentNode, Ext.EventObject.setEvent());
                }

                node.remove();

                if (this.backendModel == 'Container') {
                  this.scope.fireEvent('containerdelete', node.attributes.container);
                } else if (this.backendModel == 'Node') {
                  this.scope.fireEvent('containerdelete', node);
                } else {
                  this.scope.fireEvent('containerdelete', node.attributes);
                }
              }
            },
            failure: function failure(result, request) {
              var nodeData = Ext.util.JSON.decode(result.responseText);
              var appContext = Tine[this.scope.app.appName];

              if (appContext && appContext.handleRequestException) {
                appContext.handleRequestException(nodeData.data);
              }
            }
          });
        }
      }, this);
    }
  },

  /**
   * change tree node color
   */
  changeNodeColor: function changeNodeColor(cp, color) {
    if (this.scope.ctxNode) {
      var node = this.scope.ctxNode;
      node.getUI().addClass("x-tree-node-loading");
      Ext.Ajax.request({
        params: {
          method: this.backend + '.set' + this.backendModel + 'Color',
          containerId: node.attributes.container.id,
          color: '#' + color
        },
        scope: this,
        success: function success(_result, _request) {
          var nodeData = Ext.util.JSON.decode(_result.responseText);
          node.getUI().colorNode.setStyle({
            color: nodeData.color
          });
          node.attributes.color = nodeData.color;
          this.scope.fireEvent('containercolorset', nodeData);
          node.getUI().removeClass("x-tree-node-loading");
        },
        failure: function failure(result, request) {
          var nodeData = Ext.util.JSON.decode(result.responseText);
          var appContext = Tine[this.scope.app.appName];

          if (appContext && appContext.handleRequestException) {
            appContext.handleRequestException(nodeData.data);
          }
        }
      });
    }
  },

  /**
   * manage permissions
   * 
   */
  managePermissions: function managePermissions() {
    if (this.scope.ctxNode) {
      var node = this.scope.ctxNode,
          grantsContainer;

      if (node.attributes.nodeRecord && node.attributes.nodeRecord.data.name) {
        grantsContainer = node.attributes.nodeRecord.data.name;
      } else if (node.attributes.container) {
        grantsContainer = node.attributes.container;
      }

      var window = Tine.widgets.container.GrantsDialog.openWindow({
        title: String.format(i18n._('Manage Permissions for {0} "{1}"'), this.nodeName, Ext.util.Format.htmlEncode(grantsContainer.name)),
        containerName: this.nodeName,
        grantContainer: grantsContainer,
        app: this.scope.app.appName
      });
    }
  },

  /**
   * manage properties
   * 
   */
  manageProperties: function manageProperties() {
    if (this.scope.ctxNode) {
      var node = this.scope.ctxNode,
          grantsContainer,
          ctxNodeName;

      if (node.attributes.nodeRecord && node.attributes.nodeRecord.data.name) {
        grantsContainer = node.attributes.nodeRecord.data.name;
      } else if (node.attributes.container) {
        grantsContainer = node.attributes.container;
      }

      ctxNodeName = grantsContainer.name ? grantsContainer.name : grantsContainer;
      var window = Tine.widgets.container.PropertiesDialog.openWindow({
        title: String.format(i18n._('Properties for {0} "{1}"'), this.nodeName, Ext.util.Format.htmlEncode(ctxNodeName)),
        containerName: this.nodeName,
        grantContainer: grantsContainer,
        app: this.scope.app.appName
      });
    }
  },

  /**
   * reload node
   */
  reloadNode: function reloadNode() {
    if (this.scope.ctxNode) {
      var tree = this.scope;
      this.scope.ctxNode.reload(function (node) {
        node.expand();
        node.select(); // update grid

        tree.filterPlugin.onFilterChange();
      });
    }
  }
};

/***/ }),
/* 1373 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tree');
/**
 * filter plugin for container tree
 * 
 * @namespace Tine.widgets.tree
 * @class     Tine.widgets.tree.FilterPlugin
 * @extends   Tine.widgets.grid.FilterPlugin
 */

Tine.widgets.tree.FilterPlugin = Ext.extend(Tine.widgets.grid.FilterPlugin, {
  /**
   * @cfg {Tree Panel} treePanel (required)
   */
  treePanel: null,

  /**
   * @cfg field
   * @type String
   */
  field: 'container_id',

  /**
   * @cfg nodeAttributeField
   * @type String
   */
  nodeAttributeField: 'container',

  /**
   * @cfg singleNodeOperator
   * @type String
   */
  singleNodeOperator: 'equals',

  /**
   * @cfg selectNodes
   * @type Boolean
   */
  selectNodes: true,

  /**
   * get container filter object
   * 
   * @return {Object}
   */
  getFilter: function getFilter() {
    var filter = {
      field: this.field
    },
        sm = this.treePanel.getSelectionModel(),
        multiSelection = typeof sm.getSelectedNodes === 'function',
        selection = multiSelection ? sm.getSelectedNodes() : [sm.getSelectedNode()];
    filter.operator = multiSelection ? 'in' : this.singleNodeOperator;
    var values = [];
    Ext.each(selection, function (node) {
      if (node) {
        // if path was override in frontend for any reason, restore it
        let container = node.attributes[this.nodeAttributeField];

        if (container) {
          container.path = node.attributes.originalPath || node.attributes.path;
          values.push(container);
        }
      }
    }, this);
    filter.value = Ext.isEmpty(values) ? '' : filter.operator === 'in' ? values : values[0];
    return filter;
  },

  /**
   * gets value of this container filter
   */
  getValue: function getValue() {
    // only return values if gridFilter mode
    if (this.treePanel.filterMode !== 'gridFilter') {
      return null;
    }

    return this.getFilter();
  },

  /**
   * sets the selected container (node) of this tree
   * 
   * @param {Array} all filters
   */
  setValue: function setValue(filters, options) {
    if (!this.selectNodes) {
      return null;
    }

    var sm = this.treePanel.getSelectionModel();
    sm.clearSelections(true); // use first OR panel in case of filterPanel

    Ext.each(filters, function (filterData) {
      if (filterData.condition && filterData.condition == 'OR') {
        filters = filterData.filters[0].filters;
        return false;
      }
    }, this);
    Ext.each(filters, function (filter) {
      if (filter.field !== this.field || Ext.isEmpty(filter.value)) {
        return;
      } // save active Element, so we can restore focus after selecting nodes


      this.lastFocusEl = document.activeElement; // save west panel scrolling position so we can restore it after selecting nodes

      var westPanel = this.treePanel.app.getMainScreen().westPanel;

      if (westPanel && westPanel.body) {
        var scroller = westPanel.body.dom;

        if (scroller) {
          this.leftPanelScrollTop = scroller.scrollTop;
        }
      }

      this.treePanel.getSelectionModel().suspendEvents();
      this.selectValue(filter.value, options);
    }, this);
  },

  /**
   * select tree node(s)
   * 
   * @param {String} value
   */
  selectValue: function selectValue(value, options) {
    var values = Ext.isArray(value) ? value : [value];
    Ext.each(values, function (value, idx) {
      if (Ext.isString(value) && !value.path) {
        value = values[idx] = {
          path: value
        };
      }

      var containerPath = value && Ext.isString(value.path) ? value.path.split('/') : [''],
          containerId = containerPath.pop(),
          // NOTE: if hierarchy ends with a "/" name gets appended otherwise last part of hierarchy is the display name
      hierarchy = value ? String(value.hierarchy).match(/\/$/) || !value.hierarchy ? value.hierarchy || '' + value.name : value.hierarchy : '',
          hierarchyPath = hierarchy.split('/');

      if (hierarchyPath[0] == "") {
        hierarchyPath.shift();
      }

      hierarchyPath.pop();
      hierarchyPath.push(containerId);
      containerPath = containerPath.concat(hierarchyPath).join('/');
      var treePath = this.treePanel.getTreePath(containerPath);
      this.selectPath.call(this.treePanel, treePath, null, function () {
        // mark this expansion as done and check if all are done
        value.isExpanded = true;
        var allValuesExpanded = true;
        Ext.each(values, function (v) {
          allValuesExpanded &= v.isExpanded;
        }, this);

        if (allValuesExpanded) {
          this.treePanel.getSelectionModel().resumeEvents();

          if (this.leftPanelScrollTop) {
            try {
              this.treePanel.app.getMainScreen().westPanel.body.dom.scrollTop = this.leftPanelScrollTop;
            } catch (e) {}
          }

          (function () {
            try {
              if (this.lastFocusEl) {
                var scroller = Ext.fly(this.lastFocusEl).up('div[class$=-scroller]'),
                    scrollTop = scroller ? scroller.dom.scrollTop : null; // TODO: is this needed (the element is already focused, atm. IE breaks (https://forge.tine20.org/mantisbt/view.php?id=6916))?

                if (!Ext.isIE) {
                  Ext.fly(this.lastFocusEl).focus();
                }

                if (scrollTop) {
                  scroller.dom.scrollTop = scrollTop;
                }
              }
            } catch (e) {}
          }).defer(10, this);
        }
      }.createDelegate(this), true, options);
    }, this);
  },

  /**
   * Selects the node in this tree at the specified path. A path can be retrieved from a node with {@link Ext.data.Node#getPath}
   * @param {String} path
   * @param {String} attr (optional) The attribute used in the path (see {@link Ext.data.Node#getPath} for more info)
   * @param {Function} callback (optional) The callback to call when the selection is complete. The callback will be called with
   * (bSuccess, oSelNode) where bSuccess is if the selection was successful and oSelNode is the selected node.
   * @param {keep} bool keep current selection
   */
  selectPath: function selectPath(path, attr, callback, keep, options) {
    attr = attr || 'id';
    var keys = path.split(this.pathSeparator),
        v = keys.pop();

    if (keys.length > 1) {
      var f = function f(success, node) {
        if (success && node) {
          var n = node.findChild(attr, v) || node.findChild('path', node.attributes.path + '/' + v);

          if (n) {
            const sm = n.getOwnerTree().getSelectionModel();
            sm.select(n, false, keep, !_.get(options, 'preserveCursor', false));

            if (callback) {
              callback(true, n);
            }
          } else if (callback) {
            callback(false, n);
          }
        } else {
          if (callback) {
            callback(false, node);
          }
        }
      };

      this.expandPath(keys.join(this.pathSeparator), attr, f);
    } else {
      this.root.select();

      if (callback) {
        callback(true, this.root);
      }
    }
  }
});

/***/ }),
/* 1374 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.customfields');

Tine.widgets.customfields.ConfigManager = function () {
  var stores = {};
  var idMap = {};

  var getStore = function getStore(app) {
    app = Tine.Tinebase.appMgr.get(app);

    if (!stores[app.appName]) {
      var _ = window.lodash,
          allCfs = Ext.isFunction(app.getRegistry) ? app.getRegistry().get('customfields') : null; // set defaults -- uiconfig are empty strings :-(

      _.each(allCfs, function (cfConfig) {
        _.each({
          tab: 'customfields',
          'group': '',
          sort: 0
        }, function (defaultValue, field) {
          if (_.get(cfConfig, 'definition.uiconfig.' + field, '') == '') {
            _.set(cfConfig, 'definition.uiconfig.' + field, defaultValue);
          }
        });
      });

      stores[app.appName] = new Ext.data.JsonStore({
        fields: Tine.Tinebase.Model.Customfield,
        data: allCfs ? allCfs : []
      }); // place customefield keyFieldConfig in registry so we can use the standard widgets
      // keyfields are used for key/value customfields with a defined store 

      stores[app.appName].each(function (cfConfig) {
        idMap[cfConfig.id] = cfConfig;
        var definition = cfConfig.get('definition'),
            options = definition.options ? definition.options : {},
            keyFieldConfig = definition.keyFieldConfig ? definition.keyFieldConfig : null;

        if (keyFieldConfig) {
          var config = app.getRegistry().get('config');
          config[cfConfig.get('name')] = keyFieldConfig;
          app.getRegistry().set('config', config);
        }
      });
    }

    return stores[app.appName];
  };
  /**
   * convert config record to record field
   * 
   * @param  {Record} cfConfig
   * @return {Ext.data.Field} field definition
   */


  var config2Field = function config2Field(cfConfig) {
    var def = cfConfig.get('definition');
    return new Ext.data.Field(Ext.apply({
      name: '#' + cfConfig.get('name')
    }, def));
  };

  return {
    /**
     * returns single field config by id
     *
     * @param customfieldId
     * @param asField
     * @return {Record}
     */
    getById: function getById(customfieldId, asField) {
      var cfConfig = idMap[customfieldId];
      return asField ? config2Field(cfConfig) : cfConfig;
    },

    /**
     * returns a single field config
     * 
     * @param {String/Application}  app
     * @param {String}              model
     * @param {String}              name
     * @param {Boolean}             asField
     * @return {Record}
     */
    getConfig: function getConfig(app, model, name, asField) {
      var cfStore = getStore(app),
          cfConfig = null;
      model = model.match(/_Model_/) ? model : (app.appName ? app.appName : app) + '_Model_' + model;
      cfStore.clearFilter(true);
      cfStore.filter('model', model);
      cfConfig = cfStore.findExact('name', name);
      cfConfig = cfConfig > -1 ? cfStore.getAt(cfConfig) : null;
      cfStore.clearFilter(true);
      return asField ? config2Field(cfConfig) : cfConfig;
    },

    /**
     * returns a single field config
     * 
     * @param {String/Application}  app
     * @param {String}              model
     * @param {Boolean}             asFields
     * @return {Array}
     */
    getConfigs: function getConfigs(app, model, asFields) {
      if (Ext.isFunction(model.getMeta)) {
        model = model.getMeta('appName') + '_Model_' + model.getMeta('modelName');
      }

      var cfStore = getStore(app),
          cfConfigs = [];
      cfStore.clearFilter(true);
      cfStore.filter('model', model);
      cfStore.each(function (r) {
        cfConfigs.push(r);
      });
      cfStore.clearFilter(true);

      if (asFields) {
        Ext.each(cfConfigs, function (cfConfig, idx) {
          cfConfigs[idx] = config2Field(cfConfig);
        }, this);
      }

      return cfConfigs;
    }
  };
}();

/***/ }),
/* 1375 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.customfields');
/**
 * wrap for lazy cf init
 *
 * use like this:
 * {
 *    columnWidth: 0.5,
 *    xtype: 'customfield',
 *    modelName: 'Addressbook_Model_Contact',
 *    customFieldName: 'test'
 * }
 */

Tine.widgets.customfields.Field = Ext.extend(Ext.Panel, {
  layout: 'form',
  autoHeight: true,
  border: false,
  initComponent: function initComponent() {
    this.appName = this.appName ? this.appName : this.modelName.split('_')[0];
    var fieldConfig = Tine.widgets.customfields.ConfigManager.getConfig(this.appName, this.modelName, this.customFieldName),
        field = Tine.widgets.customfields.Field.get(this.appName, fieldConfig, {
      anchor: '100%',
      labelSeparator: ''
    });
    this.items = [field];
    Tine.widgets.customfields.Field.superclass.initComponent.call(this);
  }
});
/**
 * get the form field 
 *
 * @static
 * @param {Tine.Tinebase.Application} app the application the customfield belongs to
 * @param {Tine.Tinebase.data.Record} cfConfig customfields config record
 * @param {Object} config additional field config
 * @param {Tine.widgets.dialog.EditDialog} editDialog the calling editdialog - just needed if record must not link itself
 * 
 * @return {Ext.form.Field}
 */

Tine.widgets.customfields.Field.get = function (app, cfConfig, config, editDialog) {
  if (!cfConfig) {
    Tine.log.error('cfConfig empty -> skipping field');
    return Ext.ComponentMgr.create({
      xtype: 'hidden'
    });
  }

  var _ = window.lodash,
      def = cfConfig.get('definition'),
      uiConfig = def && def.uiconfig ? def.uiconfig : {},
      fieldDef = {
    fieldLabel: def.label,
    name: 'customfield_' + cfConfig.get('name'),
    xtype: def.value_search == 1 ? 'customfieldsearchcombo' : uiConfig.xtype,
    customfieldId: cfConfig.id,
    readOnly: cfConfig.get('account_grants').indexOf('writeGrant') < 0,
    requiredGrant: 'editGrant'
  }; // auto xtype per data type
  // @todo support array of scalars
  // @todo suppot recordSets of model

  if (!uiConfig.xtype && def.type && !def.value_search) {
    switch (Ext.util.Format.lowercase(def.type)) {
      case 'keyfield':
        var options = def.options ? def.options : {},
            keyFieldConfig = def.keyFieldConfig ? def.keyFieldConfig : null;
        Ext.apply(fieldDef, {
          xtype: 'widget-keyfieldcombo',
          app: options.app ? options.app : app,
          keyFieldName: options.keyFieldName ? options.keyFieldName : cfConfig.get('name'),
          sortBy: 'id'
        });
        break;

      case 'record':
        var options = def.options ? def.options : {},
            recordConfig = def.recordConfig ? def.recordConfig : null;
        if (!_.get(window, recordConfig.value.records)) return Ext.ComponentMgr.create({
          xtype: 'hidden'
        });
        Ext.apply(fieldDef, {
          xtype: 'tinerecordpickercombobox',
          app: options.app ? options.app : app,
          resizable: true,
          recordClass: eval(recordConfig.value.records),
          allowLinkingItself: false,
          editDialog: editDialog,
          additionalFilterSpec: recordConfig.additionalFilterSpec
        });
        break;

      case 'recordlist':
        var options = def.options ? def.options : {},
            recordListConfig = def.recordListConfig ? def.recordListConfig : null;
        if (!_.get(window, recordListConfig.value.records)) return Ext.ComponentMgr.create({
          xtype: 'hidden'
        });
        Ext.apply(fieldDef, {
          xtype: 'tinerecordspickercombobox',
          app: options.app ? options.app : app,
          resizable: true,
          recordClass: eval(recordListConfig.value.records),
          allowLinkingItself: false,
          editDialog: editDialog
        });
        break;

      case 'integer':
      case 'int':
        fieldDef.xtype = 'numberfield';
        break;

      case 'date':
        fieldDef.xtype = 'datefield';
        fieldDef.listAlign = 'tr-br?';
        break;

      case 'time':
        fieldDef.xtype = 'timefield';
        fieldDef.listAlign = 'tr-br?';
        break;

      case 'datetime':
        fieldDef.xtype = 'datetimefield';
        fieldDef.listAlign = 'tr-br?';
        break;

      case 'boolean':
      case 'bool':
        fieldDef.xtype = 'checkbox';
        fieldDef.hideLabel = true;
        fieldDef.boxLabel = fieldDef.fieldLabel;
        break;

      case 'textarea':
        fieldDef.xtype = 'textarea';
        fieldDef.height = 150;
        break;

      case 'string':
      default:
        fieldDef.xtype = 'textfield';
        break;
    }
  }

  if (def.length) {
    fieldDef.maxLength = def.length;
  }

  if (def.required) {
    fieldDef.allowBlank = false;
  } // custom code overrides


  var overwritesKey = cfConfig.get('model').replace(/_/g, '.') + '.' + cfConfig.get('name');

  var overwrites = _.get(Tine, overwritesKey, {});

  try {
    fieldDef = _.assign(fieldDef, config, overwrites);
    return Ext.ComponentMgr.create(fieldDef);
  } catch (e) {
    Tine.log.debug(e);
    Tine.log.error('Unable to create custom field "' + cfConfig.get('name') + '". Check definition:');
    Tine.log.error(fieldDef);
    return Ext.ComponentMgr.create({
      xtype: 'hidden'
    });
  }
};

Ext.reg('customfield', Tine.widgets.customfields.Field);

/***/ }),
/* 1376 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2015 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.customfields');
/**
 * @namespace   Tine.widgets.customfields
 * @class       Tine.widgets.customfields.FilterModel
 * @extends     Tine.widgets.grid.FilterModel
 */

Tine.widgets.customfields.FilterModel = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * @cfg {Record} cfConfig
   */
  cfConfig: null,
  valueType: 'customfield',

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.field = 'customfield:' + this.cfConfig.id;
    this.cfDefinition = this.cfConfig.get('definition');
    this.label = this.cfDefinition.label;

    switch (this.cfDefinition.type) {
      case 'record':
      case 'keyField':
        // Not used @see {Tine.Tinebase.widgets.grid.GridPanel.getCustomfieldFilters}
        break;

      case 'integer':
      case 'int':
        this.operators = ['equals', 'greater', 'less'];
        this.defaultOperator = 'equals';
        break;

      case 'bool':
      case 'boolean':
        this.valueType = 'bool';
        this.defaultOperator = 'equals';
        this.defaultValue = '0';
        break;

      case 'date':
      case 'datetime':
        this.valueType = 'date';
        this.defaultOperator = 'within';
    }

    Tine.widgets.customfields.FilterModel.superclass.initComponent.call(this);
  },

  /**
   * returns valueType of given filter
   * 
   * added for cf of type record and keyField
   * 
   * @param {Record} filter
   * @return {String}
   */
  getValueType: function getValueType(filter) {
    var operator = filter.get('operator') ? filter.get('operator') : this.defaultOperator,
        valueType = 'selectionComboBox';
    return valueType;
  },

  /**
   * called on operator change of a filter row
   * 
   * modified for cf of type record and keyField
   * 
   * @private
   */
  onOperatorChange: function onOperatorChange(filter, newOperator) {
    this.supr().onOperatorChange.call(this, filter, newOperator);

    if (['record', 'keyField'].indexOf(this.cfDefinition.type) !== -1) {
      var valueType = this.getValueType(filter);

      for (var valueField in filter.valueFields) {
        if (filter.valueFields.hasOwnProperty(valueField)) {
          filter.valueFields[valueField][valueField === valueType ? 'show' : 'hide']();
        }
      }

      filter.formFields.value = filter.valueFields[valueType];

      if (valueType === 'selectionComboBox' && Ext.isArray(filter.formFields.value.value)) {
        filter.formFields.value.setValue(filter.formFields.value.value[0]);
      }
    }
  },

  /**
   * cf value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  cfValueRenderer: function cfValueRenderer(filter, el) {
    var valueType = this.getValueType(filter);
    filter.valueFields = {};
    filter.valueFields.selectionComboBox = Tine.widgets.customfields.Field.get(this.app, this.cfConfig, {
      hidden: valueType !== 'selectionComboBox',
      minListWidth: 350,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      resizable: true,
      filter: filter,
      renderTo: el,
      listeners: {
        scope: this,
        'specialkey': function specialkey(field, e) {
          if (e.getKey() === e.ENTER) {
            this.onFiltertrigger();
          }
        },
        'select': this.onFiltertrigger
      }
    });
    return filter.valueFields[valueType];
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tinebase.customfield'] = Tine.widgets.customfields.FilterModel;

/***/ }),
/* 1377 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.customfields');
/**
 * manages key field renderers
 * 
 * @namespace   Tine.widgets.customfields
 * @class       Tine.widgets.customfields.Renderer
 * @singleton
 */

Tine.widgets.customfields.Renderer = function () {
  var renderers = {};
  return {
    /**
     * returns key field record renderer
     * 
     * @param {String/Application}  app
     * @param {Record}              cfConfig 
     * @param {String}              what pipe seperated field with text|icon
     * @return Ext.data.Store
     */
    get: function get(app, cfConfig, what) {
      var appName = Ext.isString(app) ? app : app.appName,
          app = Tine.Tinebase.appMgr.get(appName),
          cfDefinition = cfConfig.get('definition'),
          cfName = cfConfig.get('name'),
          what = what ? what : 'text|icon',
          whatParts = what.split('|'),
          key = appName + cfConfig.id + what;

      if (!renderers[key]) {
        if (['keyfield'
        /*, 'bool', 'boolean'*/
        ].indexOf(Ext.util.Format.lowercase(cfDefinition.type)) > -1) {
          // NOTE existingkeyfields might come from an other app!
          var app = cfDefinition.options && Ext.isString(cfDefinition.options.app) ? cfDefinition.options.app : app;
          var keyFieldName = cfDefinition.options && Ext.isString(cfDefinition.options.keyFieldName) ? cfDefinition.options.keyFieldName : cfName;

          renderers[key] = function (customfields) {
            customfields = customfields || {};
            return Tine.Tinebase.widgets.keyfield.Renderer.render(app, keyFieldName, customfields[cfName]);
          };
        } else if (['record'].indexOf(Ext.util.Format.lowercase(cfDefinition.type)) > -1 && _.get(window, cfDefinition.recordConfig.value.records)) {
          renderers[key] = function (customfields) {
            var recordClass = eval(cfDefinition.recordConfig.value.records);
            customfields = customfields || {};
            return Ext.isObject(customfields[cfName]) && customfields[cfName].hasOwnProperty(recordClass.getMeta('titleProperty')) ? customfields[cfName][recordClass.getMeta('titleProperty')] : customfields[cfName];
          };
        } else {
          renderers[key] = function (customfields) {
            customfields = customfields || {};

            switch (cfDefinition.type) {
              case 'date':
                return Tine.Tinebase.common.dateRenderer(customfields[cfName]);

              case 'datetime':
                return Tine.Tinebase.common.dateTimeRenderer(customfields[cfName]);

              case 'time':
                return Tine.Tinebase.common.timeRenderer(customfields[cfName]);

              case 'boolean':
                return Tine.Tinebase.common.booleanRenderer(customfields[cfName]);

              case 'recordList':
                return Tine.widgets.customfields.Renderer.recordListRenderer(cfDefinition, customfields[cfName]);

              default:
                return Ext.util.Format.htmlEncode(customfields[cfName] || "");
            }
          };
        }
      }

      return renderers[key];
    },
    recordListRenderer: function recordListRenderer(cfDefinition, value) {
      var title = '';
      Ext.each(value, function (value) {
        var recordClass = eval(cfDefinition.recordListConfig.value.records);
        title += Ext.isObject(value) && value.hasOwnProperty(recordClass.getMeta('titleProperty')) ? value[recordClass.getMeta('titleProperty')] + ' ' : value + '';
      });
      return title;
    },

    /**
     * render a given value
     * 
     * @param {String/Application}  app
     * @param {Record}              cfConfig 
     * @return Ext.data.Store
     */
    render: function render(app, cfConfig, id) {
      var renderer = this.get(app, cfConfig);
      return renderer(id);
    },
    renderAll: function renderAll(app, model, data) {
      var cfDefs = Tine.widgets.customfields.ConfigManager.getConfigs(app, model),
          html = '';
      Ext.each(cfDefs, function (cfDef) {
        var renderedValue = this.render(app, cfDef, data);
        html += '<div class="customfield-rendered-row print-single-details-row">' + '<span class="customfield-rendered-label">' + cfDef.get('definition').label + '</span>' + '<span class="customfield-rendered-value">' + renderedValue + '</span>' + '</div>';
      }, this);
      return html;
    },

    /**
     * register a custom renderer
     * 
     * @param {String/Application}  app
     * @param {Record}              cfConfig 
     * @param {Function}            renderer
     */
    register: function register(app, cfConfig, renderer) {
      var appName = Ext.isString(app) ? app : app.appName,
          cfDefinition = cfConfig.get('definition'),
          cfName = cfConfig.get('name'),
          key = appName + cfConfig.id;
      renderers[key] = renderer;
    }
  };
}();

/***/ }),
/* 1378 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.customfields');
/**
 * CustomfieldsSearchCombo
 * 
 * @namespace   Tine.Tinebase.widgets.customfields
 * @class       Tine.Tinebase.widgets.customfields.CustomfieldSearchCombo
 * @extends     Ext.form.ComboBox
 * 
 * <p>Customfields Search Combo</p>
 * <p>
 * searches for custom field values 
 * 
 * <pre>
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.Tinebase.widgets.customfields.CustomfieldSearchCombo
 */

Tine.widgets.customfields.CustomfieldSearchCombo = Ext.extend(Ext.form.ComboBox, {
  /**
   * @property customfieldId
   * @type String
   */
  customfieldId: null,

  /**
   * config
   */
  forceSelection: false,
  triggerAction: 'all',
  pageSize: 50,
  displayField: 'value',
  valueField: 'value',
  enableKeyEvents: true,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.pageSize = parseInt(Tine.Tinebase.registry.get('preferences').get('pageSize'), 10) || this.pageSize;
    this.store = new Ext.data.JsonStore({
      fields: Tine.Tinebase.Model.CustomfieldValue,
      baseParams: {
        method: 'Tinebase.searchCustomFieldValues',
        sort: 'value',
        dir: 'ASC'
      },
      root: 'results',
      totalProperty: 'totalcount'
    });
    this.on('beforequery', this.onBeforeQuery, this);
    this.on('keypress', this.syncValues, this, {
      buffer: 500
    });
    Tine.widgets.customfields.CustomfieldSearchCombo.superclass.initComponent.call(this);
  },

  /**
   * prepare paging
   * 
   * @param {Ext.data.Store} store
   * @param {Object} options
   */
  onBeforeLoad: function onBeforeLoad(store, options) {
    options.params.paging = {
      start: options.params.start,
      limit: options.params.limit
    };
  },

  /**
   * sync values so values don't get lost if no value is explicitly selected
   * this happens e.g. when ctrl+enter after searching
   */
  syncValues: function syncValues() {
    var val = this.getRawValue();
    this.setValue(val);
  },

  /**
   * use beforequery to set query filter
   * 
   * @param {Object} qevent
   */
  onBeforeQuery: function onBeforeQuery(qevent) {
    this.store.baseParams.filter = [{
      field: 'customfield_id',
      operator: 'equals',
      value: this.customfieldId
    }, {
      field: 'value',
      operator: 'group',
      value: ''
    }, {
      field: 'value',
      operator: 'contains',
      value: qevent.query
    }];
  }
});
Ext.reg('customfieldsearchcombo', Tine.widgets.customfields.CustomfieldSearchCombo);

/***/ }),
/* 1379 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.customfields');

Tine.widgets.customfields.EditDialogPlugin = function (config) {
  Ext.apply(this, config);
  this.tabPanelPosition = 20;
};

Tine.widgets.customfields.EditDialogPlugin.prototype = {
  /**
   * @type Tine.Tinebase.Application app
   */
  app: null,

  /**
   * @type Tine.widgets.dialog.EditDialog editDialog
   */
  editDialog: null,
  // private
  isInitialised: false,
  init: function init(editDialog) {
    if (this.isInitialised) {
      return;
    }

    this.editDialog = editDialog; // edit dialog without recordClass cannot have custom fields

    if (!this.editDialog.recordClass) {
      return;
    }

    this.app = Tine.Tinebase.appMgr.get(this.editDialog.app);
    this.customfieldsValue = []; // compute cf's for cf tab and add a cf tab on demand

    this.editDialog.on('beforerender', this.onBeforeRender, this); // fill/buffer all cf's with values

    this.editDialog.on('load', this.onRecordLoad, this); // load cf for mainTab in editDialog

    this.loadCfForm(); // get all cf values

    this.editDialog.onRecordUpdate = this.editDialog.onRecordUpdate.createSequence(this.onRecordUpdate, this);
    this.isInitialised = true;
  },

  /**
   * dispatch values from customfield property
   */
  onRecordLoad: function onRecordLoad() {
    var form = this.editDialog.getForm(),
        modelName = this.editDialog.recordClass.getMeta('appName') + '_Model_' + this.editDialog.recordClass.getMeta('modelName'),
        name,
        field,
        cfConfig;
    this.customfieldsValue = this.editDialog.record.get('customfields') || {};

    for (name in this.customfieldsValue) {
      field = form.findField('customfield_' + name);
      cfConfig = Tine.widgets.customfields.ConfigManager.getConfig(this.app, modelName, name);

      if (cfConfig) {
        // transform datetime values
        if (['date', 'datetime'].indexOf(Ext.util.Format.lowercase(cfConfig.get('definition').type)) != -1) {
          this.customfieldsValue[name] = Date.parseDate(this.customfieldsValue[name], Date.patterns.ISO8601Long);
        }

        if (field) {
          if (field.isXType('combo') && Ext.isObject(this.customfieldsValue[name])) {
            var record = new field.recordClass(this.customfieldsValue[name]);
            field.setValue(record);
          } else {
            field.setValue(this.customfieldsValue[name]);
          }
        }
      }
    }
  },

  /**
   * combile cf values in customfield property
   */
  onRecordUpdate: function onRecordUpdate() {
    var form = this.editDialog.getForm();
    form.items.each(function (f) {
      var name = f.getName();

      if (Ext.isString(name) && name.match(/^customfield_(.+)$/)) {
        name = name.match(/^customfield_(.+)$/)[1];
        this.customfieldsValue[name] = f.getValue();
      }
    }, this);

    this.customfieldsValue.toString = function () {
      return Ext.util.JSON.encode(this.customfieldsValue);
    };

    this.editDialog.record.set('customfields', this.customfieldsValue);
  },

  /**
   * match item with the key of customfield".
   */
  loadCfForm: function loadCfForm() {
    var _ = window.lodash,
        modelName = this.editDialog.recordClass.getMeta('appName') + '_Model_' + this.editDialog.recordClass.getMeta('modelName'),
        allCfConfigs = Tine.widgets.customfields.ConfigManager.getConfigs(this.app, modelName);

    _.each(allCfConfigs, _.bind(function (fields) {
      if (_.get(fields, 'data.definition.uiconfig.key')) {
        var pos = _.get(fields, 'data.definition.uiconfig.order');

        Ext.ux.ItemRegistry.registerItem(_.get(fields, 'data.definition.uiconfig.key'), Tine.widgets.customfields.Field.get(this.app, fields, {}, this.editDialog), pos ? pos : '0/0');
      }
    }, this));
  },

  /**
   * create cf tab on demand
   */
  onBeforeRender: function onBeforeRender() {
    var _ = window.lodash,
        modelName = this.editDialog.recordClass.getMeta('appName') + '_Model_' + this.editDialog.recordClass.getMeta('modelName'),
        allCfConfigs = Tine.widgets.customfields.ConfigManager.getConfigs(this.app, modelName),
        tabPanel = this.getTabPanel(),
        form = this.editDialog.getForm(),
        cfConfigs = []; // remove already applied cfs / fill the mixed collection

    Ext.each(allCfConfigs, function (cfConfig) {
      if (!form.findField('customfield_' + cfConfig.get('name'))) {
        cfConfigs.push(cfConfig);
      }
    }, this);

    _.each(_.groupBy(cfConfigs, 'data.definition.uiconfig.tab'), _.bind(function (fields, tabId) {
      var tab = tabPanel.items.get(_.isNaN(+tabId) || ['', null].indexOf(tabId) >= 0 ? tabId : +tabId);

      if (!tab) {
        this.addCFTab(fields, tabId);
      } else {
        // evaluate group here?
        _.each(fields, _.bind(function (fieldConfig) {
          var formField = Tine.widgets.customfields.Field.get(this.app, fieldConfig, {}, this.editDialog),
              pos = _.get(fieldConfig, 'data.definition.uiconfig.order');

          Ext.ux.ItemRegistry.registerItem(tab, formField, pos);
        }, this));
      }
    }, this));
  },
  getTabPanel: function getTabPanel() {
    if (!this.tabPanel) {
      // find the first tabPanel and add it there
      this.tabPanel = this.editDialog.items.find(function (item) {
        return Ext.isObject(item) && Ext.isFunction(item.getXType) && item.getXType() == 'tabpanel';
      });
    }

    return this.tabPanel;
  },

  /**
   * create a cf tab
   * 
   * @param {Collection} cfConfigs
   * @param {String} tabName
   */
  addCFTab: function addCFTab(cfConfigs, tabName) {
    var _ = window.lodash,
        groups = _.groupBy(cfConfigs, 'data.definition.uiconfig.group'),
        items = [];

    _.each(groups, _.bind(function (fields, groupName) {
      groupName = !groupName && tabName == 'customfields' ? 'General' : groupName;
      fields = _.sortBy(fields, 'data.definition.uiconfig.order');

      var fieldObjects = _.map(fields, _.bind(Tine.widgets.customfields.Field.get, this, this.app, _, {
        anchor: '95%'
      }, this.editDialog));

      if (groupName) {
        items.push(new Ext.form.FieldSet({
          title: i18n._hidden(groupName),
          autoHeight: true,
          autoWidth: true,
          labelAlign: 'top',
          labelWidth: '90%',
          collapsible: true,
          items: fieldObjects
        }));
      } else {
        items = items.concat(fieldObjects);
      }
    }, this));

    this.getTabPanel().add(new Ext.Panel({
      title: !tabName || tabName == 'customfields' ? i18n._('Custom Fields') : i18n._hidden(tabName),
      pos: this.tabPanelPosition,
      layout: 'form',
      border: true,
      frame: true,
      labelAlign: 'top',
      autoScroll: true,
      items: items,
      defaults: {
        anchor: '100%',
        labelSeparator: ''
      }
    }));
    this.tabPanelPosition++;
  }
};
Ext.preg('tinebase.widgets.customfield.editdialogplugin', Tine.widgets.customfields.EditDialogPlugin);

/***/ }),
/* 1380 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO         this is only used in the phone dial dialog, do we need that?
 */
Ext.ns('Tine.widgets', 'Tine.widgets.customfields');
/**
 * CustomfieldsCombo
 * 
 * @namespace   Tine.widgets.customfields
 * @class       Tine.widgets.customfields.CustomfieldsCombo
 * @extends     Ext.form.ComboBox
 * 
 */

Tine.widgets.customfields.CustomfieldsCombo = Ext.extend(Ext.form.ComboBox, {
  typeAhead: false,
  forceSelection: true,
  mode: 'local',
  triggerAction: 'all',
  initComponent: function initComponent() {
    Tine.widgets.customfields.CustomfieldsCombo.superclass.initComponent.call(this);
  },
  stateEvents: ['select'],
  getState: function getState() {
    return this.getValue();
  },
  applyState: function applyState(state) {
    this.setValue(state);
  }
});

/***/ }),
/* 1381 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.relation');
/**
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.FilterModel
 * @extends     Tine.widgets.grid.FilterModel
 * 
 * @todo CARE FOR SHEET DESTRUCTON!
 * @todo CARE FOR OPERATOR CHANGE
 */

Tine.widgets.relation.FilterModel = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,
  valueType: 'relation',
  field: 'relation',

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.label = i18n._('Relation'); // @TODO wipe some models?

    var relatedModels = [];
    Tine.Tinebase.data.RecordMgr.eachKey(function (operator, record) {
      if (record.hasField('relations') && Ext.isFunction(record.getFilterModel)) {
        var label = Tine.Tinebase.appMgr.get(record.getMeta('appName')).i18n._hidden(record.getMeta('recordsName'));

        relatedModels.push({
          operator: operator,
          label: label
        });
      }
    }, this);
    this.relatedModelStore = this.fieldStore = new Ext.data.JsonStore({
      fields: ['operator', 'label'],
      data: relatedModels
    });
    this.defaultOperator = this.relatedModelStore.getAt(0).get('operator');
    Tine.widgets.relation.FilterModel.superclass.initComponent.call(this);
  },
  onDefineRelatedRecord: function onDefineRelatedRecord(filter) {
    Tine.log.debug('Tine.widgets.relation.FilterModel::onDefineRelatedRecord() - filter:');
    Tine.log.debug(filter);

    if (!filter.sheet) {
      var operator = filter.formFields.operator.getValue(),
          recordClass = Tine.Tinebase.data.RecordMgr.get(operator);
      Tine.log.debug('Tine.widgets.relation.FilterModel::onDefineRelatedRecord() - recordClass:');
      Tine.log.debug(recordClass);
      filter.sheet = new Tine.widgets.grid.FilterToolbar({
        recordClass: recordClass,
        defaultFilter: 'query'
      });
      this.ftb.addFilterSheet(filter.sheet);
    }

    this.ftb.setActiveSheet(filter.sheet);
    filter.formFields.value.setText(i18n._('Defined by ...'));
  },

  /**
   * operator renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  operatorRenderer: function operatorRenderer(filter, el) {
    var operator = new Ext.form.ComboBox({
      filter: filter,
      id: 'tw-ftb-frow-operatorcombo-' + filter.id,
      mode: 'local',
      lazyInit: false,
      emptyText: i18n._('select a operator'),
      forceSelection: true,
      typeAhead: true,
      triggerAction: 'all',
      store: this.relatedModelStore,
      displayField: 'label',
      valueField: 'operator',
      value: filter.get('operator') ? filter.get('operator') : this.defaultOperator,
      renderTo: el
    });
    operator.on('select', function (combo, newRecord, newKey) {
      if (combo.value != combo.filter.get('operator')) {
        this.onOperatorChange(combo.filter, combo.value);
      }
    }, this);
    return operator;
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    var value = new Ext.Button({
      text: i18n._('Define ...'),
      filter: filter,
      renderTo: el,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      handler: this.onDefineRelatedRecord.createDelegate(this, [filter]),
      scope: this,
      getValue: function getValue() {}
    }); // show button

    el.addClass('x-btn-over');
    return value;
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tinebase.relation'] = Tine.widgets.relation.FilterModel;

/***/ }),
/* 1382 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.relation');
/**
 * manages renderers
 * 
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.Renderer
 * @singleton
 */

Tine.widgets.relation.Renderer = function () {
  var renderers = {};
  return {
    renderAll: function renderAll(relations) {
      var html = '';
      Ext.each(relations, function (relation) {
        var relatedRecord = relation.related_record,
            relatedModel = relation.related_model.split('_Model_'),
            app = Tine.Tinebase.appMgr.get(relatedModel[0]),
            model = relatedModel[1],
            relatedModel = Tine[relatedModel[0]].Model[relatedModel[1]],
            record = new relatedModel(relatedRecord);
        html += '<div class="customfield-rendered-row print-single-details-row">' + '<span class="customfield-rendered-label">' + app.i18n._(model) + '</span>' + '<span class="customfield-rendered-value">' + record.getTitle() + '</span>' + '</div>';
      }, this);
      return html;
    },

    /**
     * register a custom renderer
     * 
     * @param {String/Application}  app
     * @param {Record}              cfConfig 
     * @param {Function}            renderer
     */
    register: function register(app, relations, renderer) {
      var key = appName + record.id;
      renderers[key] = renderer;
    }
  };
}();

/***/ }),
/* 1383 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @subpackage  widgets
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */

/*global Ext, Tine*/
Ext.ns('Tine.widgets.account');
/**
 * Account Picker GridPanel
 *
 * @namespace   Tine.widgets.account
 * @class       Tine.widgets.account.PickerGridPanel
 * @extends     Tine.widgets.grid.PickerGridPanel
 *
 * <p>Account Picker GridPanel</p>
 * <p><pre>
 * TODO         use selectAction config?
 * </pre></p>
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * @param       {Object} config
 * @constructor Create a new Tine.widgets.account.PickerGridPanel
 */

Tine.widgets.account.PickerGridPanel = Ext.extend(Tine.widgets.grid.PickerGridPanel, {
  /**
   * @cfg {String} one of 'user', 'group', 'both', 'myself'
   * selectType
   */
  selectType: 'user',

  /**
   * @cfg{String} selectTypeDefault 'user' or 'group' defines which accountType is selected when  {selectType} is true
   */
  selectTypeDefault: 'user',

  /**
   * @cfg {Ext.Action}
   * selectAction
   */
  //selectAction: false,

  /**
   * @cfg {bool}
   * add 'anyone' selection if selectType == 'both'
   */
  selectAnyone: true,

  /**
   * @cfg {bool}
   * add button to add the current user
   */
  selectMyself: false,

  /**
   * @cfg {bool}
   * add role selection
   */
  selectRole: false,

  /**
   * @cfg {bool}
   * show hidden (user) contacts / (group) lists
   */
  showHidden: false,

  /**
   * get only users with defined status (enabled, disabled, expired)
   * get all -> 'enabled expired disabled'
   *
   * @type String
   * @property userStatus
   */
  userStatus: 'enabled',

  /**
   * @cfg {bool} have the record account properties an account prefix?
   */
  hasAccountPrefix: false,

  /**
   * @cfg {String} recordPrefix
   */
  recordPrefix: '',

  /**
   * grid config
   * @private
   */
  autoExpandColumn: 'name',

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.recordPrefix = this.hasAccountPrefix ? 'account_' : '';
    this.recordClass = this.recordClass || Tine.Tinebase.Model.Account;
    this.groupRecordClass = this.groupRecordClass || Tine.Addressbook.Model.List;
    this.roleRecordClass = this.roleRecordClass || Tine.Tinebase.Model.Role;

    if (Tine.Tinebase.configManager.get('anyoneAccountDisabled')) {
      Tine.log.info('Tine.widgets.account.PickerGridPanel::initComponent() -> select anyone disabled in config');
      this.selectAnyone = false;
    }

    Tine.widgets.account.PickerGridPanel.superclass.initComponent.call(this);
    this.store.sort(this.recordPrefix + 'name');
  },

  /**
   * init top toolbar
   */
  initTbar: function initTbar() {
    this.accountTypeSelector = this.getAccountTypeSelector();
    var items = [this.getSearchCombo('user'), this.getSearchCombo('group'), this.getSearchCombo('role')];
    var combo = this.getSearchCombo(this.selectTypeDefault).show();
    combo.setDisabled(this.selectType === 'myself');
    this.comboPanel = new Ext.Panel({
      layout: 'hfit',
      border: false,
      items: items,
      columnWidth: 1
    });
    this.tbar = new Ext.Toolbar({
      items: [this.accountTypeSelector, this.comboPanel],
      layout: 'column'
    });
  },

  /**
   * define actions
   *
   * @return {Ext.Action}
   */
  getAccountTypeSelector: function getAccountTypeSelector() {
    var userActionCfg = {
      text: i18n._('Search User'),
      scope: this,
      iconCls: 'tinebase-accounttype-user',
      handler: this.onSwitchCombo.createDelegate(this, ['contact', 'tinebase-accounttype-user'])
    };
    var groupActionCfg = {
      text: i18n._('Search Group'),
      scope: this,
      iconCls: 'tinebase-accounttype-group',
      handler: this.onSwitchCombo.createDelegate(this, ['group', 'tinebase-accounttype-group'])
    };
    var roleActionCfg = {
      text: i18n._('Search Role'),
      scope: this,
      iconCls: 'tinebase-accounttype-role',
      handler: this.onSwitchCombo.createDelegate(this, ['role', 'tinebase-accounttype-role'])
    };
    var anyoneActionCfg = {
      text: i18n._('Add Anyone'),
      scope: this,
      iconCls: 'tinebase-accounttype-addanyone',
      handler: this.onAddAnyone
    };
    var myselfActionCfg = {
      text: i18n._('Add Myself'),
      scope: this,
      iconCls: 'tinebase-accounttype-user',
      handler: this.onAddMyself.createDelegate(this)
    }; // set items

    var items = [];

    switch (this.selectType) {
      case 'both':
        items = items.concat([userActionCfg, groupActionCfg]);

        if (this.selectRole) {
          items.push(roleActionCfg);
        }

        if (this.selectAnyone) {
          items.push(anyoneActionCfg);
        }

        break;

      case 'user':
        items = [userActionCfg];
        break;

      case 'group':
        items = [groupActionCfg];
        break;

      case 'myself':
        items = [myselfActionCfg];
        break;
    }

    if (this.selectType !== 'myself' && this.selectMyself === true) {
      items.push(myselfActionCfg);
    } // create action


    return new Ext.Action({
      width: 20,
      text: '',
      disabled: false,
      iconCls: this.selectTypeDefault === 'user' ? 'tinebase-accounttype-user' : 'tinebase-accounttype-group',
      menu: new Ext.menu.Menu({
        items: items
      }),
      scope: this
    });
  },

  /**
   * add anyone to grid
   */
  onAddAnyone: function onAddAnyone() {
    var recordData = this.recordDefaults !== null ? this.recordDefaults : {};
    recordData[this.recordPrefix + 'type'] = 'anyone';
    recordData[this.recordPrefix + 'name'] = i18n._('Anyone');
    recordData[this.recordPrefix + 'id'] = 0;
    var record = new this.recordClass(recordData, 0); // check if already in

    if (!this.store.getById(record.id)) {
      this.store.add([record]);
    }
  },
  onAddMyself: function onAddMyself() {
    var currentUser = Tine.Tinebase.registry.get('currentAccount'),
        record,
        recordData = this.recordDefaults !== null ? this.recordDefaults : {}; // user record

    recordData[this.recordPrefix + 'id'] = currentUser.accountId;
    recordData[this.recordPrefix + 'type'] = 'user';
    recordData[this.recordPrefix + 'name'] = currentUser.accountDisplayName;
    recordData[this.recordPrefix + 'data'] = currentUser;
    record = new this.recordClass(recordData, currentUser.accountId); // check if already in

    if (!this.store.getById(record.id)) {
      this.store.add([record]);
    }
  },
  getSearchCombo: function getSearchCombo(type) {
    type = type == 'user' ? 'contact' : type;
    var combo = this['get' + Ext.util.Format.capitalize(type) + 'SearchCombo'](); // This combobox doesn't need a validator.

    combo.validator = function () {
      return true;
    };

    return combo;
  },

  /**
   * @return {Tine.Addressbook.SearchCombo}
   */
  getContactSearchCombo: function getContactSearchCombo() {
    if (!this.contactSearchCombo) {
      this.contactSearchCombo = new Tine.Addressbook.SearchCombo({
        hidden: true,
        accountsStore: this.store,
        emptyText: i18n._('Search for users ...'),
        newRecordClass: this.recordClass,
        newRecordDefaults: this.recordDefaults,
        recordPrefix: this.recordPrefix,
        userOnly: true,
        onSelect: this.onAddRecordFromCombo,
        additionalFilters: this.showHidden ? [{
          field: 'showDisabled',
          operator: 'equals',
          value: true
        }] : []
      });
    }

    return this.contactSearchCombo;
  },

  /**
   * @return {Tine.Tinebase.widgets.form.RecordPickerComboBox}
   */
  getGroupSearchCombo: function getGroupSearchCombo() {
    if (!this.groupSearchCombo) {
      this.groupSearchCombo = new Tine.Tinebase.widgets.form.RecordPickerComboBox({
        hidden: true,
        accountsStore: this.store,
        recordClass: this.groupRecordClass,
        newRecordClass: this.recordClass,
        newRecordDefaults: this.recordDefaults,
        recordPrefix: this.recordPrefix,
        emptyText: i18n._('Search for groups ...'),
        onSelect: this.onAddRecordFromCombo,
        additionalFilters: [{
          field: 'type',
          operator: 'equals',
          value: 'group'
        }]
      });
    }

    return this.groupSearchCombo;
  },
  getRoleSearchCombo: function getRoleSearchCombo() {
    if (!this.roleSearchCombo) {
      this.roleSearchCombo = new Tine.Tinebase.widgets.form.RecordPickerComboBox({
        hidden: true,
        accountsStore: this.store,
        recordClass: this.roleRecordClass,
        newRecordClass: this.recordClass,
        newRecordDefaults: this.recordDefaults,
        recordPrefix: this.recordPrefix,
        emptyText: i18n._('Search for roles ...'),
        onSelect: this.onAddRecordFromCombo
      });
    }

    return this.roleSearchCombo;
  },

  /**
   * @return Ext.grid.ColumnModel
   * @private
   */
  getColumnModel: function getColumnModel() {
    if (!this.colModel) {
      this.colModel = new Ext.grid.ColumnModel({
        defaults: {
          sortable: true
        },
        columns: [{
          id: 'name',
          header: i18n._('Name'),
          width: 200,
          dataIndex: this.recordPrefix + 'name',
          renderer: Tine.Tinebase.common.accountRenderer
        }].concat(this.configColumns)
      });
    }

    return this.colModel;
  },

  /**
   * @param {Record} recordToAdd
   */
  onAddRecordFromCombo: function onAddRecordFromCombo(recordToAdd) {
    var recordData = {},
        record,
        type = String(recordToAdd.constructor.getMeta('modelName')).toLowerCase(); // role record selected

    if (type == 'role') {
      recordData[this.recordPrefix + 'id'] = recordToAdd.data.id;
      recordData[this.recordPrefix + 'type'] = 'role';
      recordData[this.recordPrefix + 'name'] = recordToAdd.data.name;
      recordData[this.recordPrefix + 'data'] = recordToAdd.data;
    } // account record selected
    else if (recordToAdd.data.account_id) {
        // user account record
        recordData[this.recordPrefix + 'id'] = recordToAdd.data.account_id;
        recordData[this.recordPrefix + 'type'] = 'user';
        recordData[this.recordPrefix + 'name'] = recordToAdd.data.n_fileas;
        recordData[this.recordPrefix + 'data'] = recordToAdd.data;
      } // group or addressbook list record selected
      else if (recordToAdd.data.group_id || recordToAdd.data.id) {
          recordData[this.recordPrefix + 'id'] = recordToAdd.data.group_id || recordToAdd.data.id;
          recordData[this.recordPrefix + 'type'] = 'group';
          recordData[this.recordPrefix + 'name'] = recordToAdd.data.name;
          recordData[this.recordPrefix + 'data'] = recordToAdd.data;
        }

    record = new this.newRecordClass(Ext.applyIf(recordData, this.newRecordDefaults), recordData[this.recordPrefix + 'id']); // check if already in

    if (!this.accountsStore.getById(record.id)) {
      this.accountsStore.add([record]);
    }

    this.collapse();
    this.clearValue();
    this.reset(); // fluent adding

    _.delay(() => {
      this.el.focus();
    }, 300);
  },

  /**
   *
   * @param {String} show
   * @param {String} iconCls
   *
   */
  onSwitchCombo: function onSwitchCombo(show, iconCls) {
    Ext.each(['contact', 'group', 'role'], function (type) {
      this.getSearchCombo(type).setVisible(show == type);
    }, this);
    this.getSearchCombo(show).setWidth('auto');
    this.accountTypeSelector.setIconClass(iconCls);
  }
});
Ext.reg('tinerecordpickergrid', Tine.widgets.account.PickerGridPanel);

/***/ }),
/* 1384 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.account');
/**
 * @namespace   Tine.widgets.account
 * @class       Tine.widgets.account.ChangeAccountAction
 * @extends     Ext.Action
 */

Tine.widgets.account.ChangeAccountAction = function (config) {
  config.text = config.text ? config.text : i18n._('Change user account');
  config.iconCls = 'tinebase-accounttype-group';
  config.tooltip = i18n._('Switch to another user\'s account');
  config.handler = this.handleClick.createDelegate(this);
  Ext.apply(this, config);
  Tine.widgets.account.ChangeAccountAction.superclass.constructor.call(this, config);
};

Ext.extend(Tine.widgets.account.ChangeAccountAction, Ext.Action, {
  loadMask: null,
  returnToOriginalUser: false,
  getFormItems: function getFormItems() {
    var roleChangeAllowed = Tine.Tinebase.registry.get("config").roleChangeAllowed.value,
        currentAccountName = Tine.Tinebase.registry.get('currentAccount').accountLoginName,
        store = [];
    Tine.log.debug(roleChangeAllowed);
    Ext.each(roleChangeAllowed[currentAccountName], function (account) {
      store.push([account, account]);
    });
    this.accountSelect = new Ext.form.ComboBox({
      hideLabel: true,
      anchor: '100%',
      app: this.app,
      forceSelection: true,
      store: store,
      listeners: {
        scope: this,
        render: function render(field) {
          field.focus(false, 500);
        },
        select: function select() {
          this.okButton.setDisabled(false); // TODO submit on select?
          //this.onOk();
        }
      }
    });
    return [{
      xtype: 'label',
      text: i18n._('Switch to this user account:')
    }, this.accountSelect];
  },
  handleClick: function handleClick() {
    if (this.returnToOriginalUser) {
      this.onOk();
      return;
    }

    this.okButton = new Ext.Button({
      text: i18n._('Ok'),
      minWidth: 70,
      scope: this,
      handler: this.onOk,
      disabled: true,
      iconCls: 'action_saveAndClose'
    });
    this.win = Tine.WindowFactory.getWindow({
      layout: 'fit',
      width: 300,
      height: 150,
      padding: '5px',
      modal: true,
      title: i18n._('Select Account'),
      items: [{
        xtype: 'form',
        buttonAlign: 'right',
        padding: '5px',
        items: this.getFormItems(),
        buttons: [{
          text: i18n._('Cancel'),
          minWidth: 70,
          scope: this,
          handler: this.onCancel,
          iconCls: 'action_cancel'
        }, this.okButton]
      }]
    });
  },
  onCancel: function onCancel() {
    this.win.close();
  },
  onOk: function onOk() {
    if (this.win) {
      this.loadMask = new Ext.LoadMask(this.win.getEl(), {
        msg: i18n._('Changing user account ...')
      });
      this.loadMask.show();
    }

    var accountToSelect = this.returnToOriginalUser ? null : this.accountSelect.getValue();
    Tine.Tinebase.changeUserAccount(accountToSelect, this.onSuccess.createDelegate(this));
  },
  onSuccess: function onSuccess() {
    Tine.Tinebase.common.reload({});
  }
});

/***/ }),
/* 1385 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * Container select ComboBox widget
 * 
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.SelectionComboBox
 * @extends     Ext.form.ComboBox
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.widgets.container.SelectionComboBox = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * @cfg {Boolean} allowNodeSelect
   */
  allowNodeSelect: false,
  allowToplevelNodeSelect: true,

  /**
   * @cfg {array}
   * default container
   */
  defaultContainer: false,

  /**
   * @cfg {Number} how many chars of the containername to display
   */
  displayLength: 25,

  /**
   * @property {Object} currently displayed container
   */
  selectedContainer: null,

  /**
   * @cfg {Number} list width
   */
  listWidth: 400,

  /**
   * @cfg {string} containerName
   * name of container (singular)
   */
  containerName: 'container',

  /**
   * @cfg {string} containersName
   * name of container (plural)
   */
  containersName: 'containers',

  /**
   * @cfg {Boolean} hideTrigger2
   */
  hideTrigger2: true,

  /**
   * @cfg {String} startPath a container path to start with
   * possible values are: '/', '/personal/someAccountId', '/shared' (defaults to '/')
   * 
   * NOTE: container paths could not express tree paths .../otherUsers!
   */
  startPath: '/',

  /**
   * @cfg {Tine.data.Record} recordClass
   */
  recordClass: null,

  /**
   * @cfg {Array} requiredGrants
   * grants which are required to select leaf node(s)
   */
  requiredGrants: null,

  /**
   * @cfg {String} requiredGrant (legacy - should not be used any more)
   * grants which is required to select leaf node(s)
   */
  requiredGrant: null,

  /**
   *  @cfg {Number} trigger2width
   */
  trigger2width: 100,
  // private
  allowBlank: false,
  triggerAction: 'all',
  forceAll: true,
  lazyInit: true,
  editable: false,
  clearFilterOnReset: false,
  stateful: true,
  stateEvents: ['select'],
  mode: 'remote',
  valueField: 'id',
  displayField: 'name',
  treePanelClass: Tine.widgets.container.TreePanel,

  /**
   * is set to true if subpanels (selectionDialog) are active
   * useful in QuickAddGrid
   * @type Boolean
   */
  hasFocusedSubPanels: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    // autoinit config
    this.appName = !this.appName && this.recordClass ? this.recordClass.getAppName() : this.appName;
    this.containerName = this.containerName == 'container' && this.recordClass ? this.recordClass.getContainerName() : this.containerName;
    this.containersName = this.containersName == 'containers' && this.recordClass ? this.recordClass.getContainersName() : this.containersName; // init state

    if (this.stateful && !this.stateId) {
      if (!this.recordClass) {
        this.stateful = false;
      } else {
        this.stateId = this.recordClass.getMeta('appName') + '-tinebase-widgets-container-selectcombo-' + this.recordClass.getMeta('modelName');
      }
    } // legacy handling for requiredGrant


    if (this.requiredGrant && !this.requiredGrants) {
      this.requiredGrants = [this.requiredGrant];
    } else if (!this.requiredGrant && !this.requiredGrants) {
      // set default required Grants
      this.requiredGrants = ['readGrant'];
    } // no state saving for startPath != /


    this.on('beforestatesave', function () {
      return this.startPath === '/';
    }, this);
    this.initStore();
    this.otherRecord = new Tine.Tinebase.Model.Container({
      id: 'other',
      name: String.format(i18n._('choose other {0}...'), this.containerName)
    }, 'other');
    this.store.add(this.otherRecord);
    this.emptyText = String.format(i18n._('Select a {0}'), this.containerName); // init triggers (needs to be done before standard initTrigger template fn)

    if (!this.hideTrigger2) {
      if (this.triggerClass == 'x-form-arrow-trigger') {
        this.triggerClass = 'x-form-arrow-trigger-rectangle';
      }

      this.triggerConfig = {
        tag: 'span',
        cls: 'x-form-twin-triggers',
        cn: [{
          tag: "img",
          src: Ext.BLANK_IMAGE_URL,
          cls: "x-form-trigger " + this.triggerClass
        }, {
          tag: 'span',
          cls: 'tw-containerselect-trigger2',
          cn: [{
            tag: "img",
            src: Ext.BLANK_IMAGE_URL,
            cls: "x-form-trigger tw-containerselect-trigger2-bg"
          }, {
            tag: "img",
            src: Ext.BLANK_IMAGE_URL,
            cls: "x-form-trigger tw-containerselect-trigger2"
          }, {
            tag: "div",
            style: {
              position: 'absolute',
              top: 0,
              left: '5px'
            }
          }]
        }]
      };
    } // autoconfig app


    if (!this.app && this.appName) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    }

    if (!this.app && this.recordClass) {
      this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
    }

    if (this.app && !this.appName) {
      this.appName = this.app.appName;
    }

    this.recents = {};
    Tine.widgets.container.SelectionComboBox.superclass.initComponent.call(this);

    if (this.defaultContainer) {
      this.selectedContainer = this.defaultContainer;
      this.value = this.defaultContainer.name;
    }

    this.on('blur', function () {
      if (this.hasFocusedSubPanels) {
        return false;
      }
    }, this);
  },

  /**
   * @private
   */
  initStore: function initStore() {
    var state = this.stateful ? Ext.state.Manager.get(this.stateId) : null;
    var recentsData = state && state.recentsData || [];
    this.store = new Ext.data.JsonStore({
      id: 'id',
      data: {
        results: recentsData
      },
      remoteSort: false,
      fields: Tine.Tinebase.Model.Container,
      root: 'results',
      totalProperty: 'totalcount',
      listeners: {
        beforeload: this.onBeforeLoad.createDelegate(this),
        load: this.onStoreLoad.createDelegate(this)
      }
    });
    this.setStoreFilter();
  },
  initTrigger: function initTrigger() {
    if (!this.hideTrigger2) {
      var t1 = this.trigger.first();
      var t2 = this.trigger.last();
      this.trigger2 = t2;
      t1.on("click", this.onTriggerClick, this, {
        preventDefault: true
      });
      t2.on("click", this.onTrigger2Click, this, {
        preventDefault: true
      });
      t1.addClassOnOver('x-form-trigger-over');
      t1.addClassOnClick('x-form-trigger-click');
      t2.addClassOnOver('x-form-trigger-over');
      t2.addClassOnClick('x-form-trigger-click');
    } else {
      Tine.widgets.container.SelectionComboBox.superclass.initTrigger.call(this);
    }
  },
  manageRecents: function manageRecents(recent) {
    recent.set('dtselect', new Date().getTime());
    this.store.remove(this.otherRecord);
    this.store.clearFilter();
    this.store.sort('dtselect', 'DESC'); // keep 10 containers and the nodes in betwwen

    var containerKeepCount = 0;
    this.store.each(function (record) {
      if (containerKeepCount < 10) {
        if (!record.get('is_container_node')) {
          containerKeepCount += 1;
        }

        return;
      }

      this.store.remove(record);
    }, this);
    this.setStoreFilter();
    this.store.add(this.otherRecord);
  },

  /**
   * prepare params for remote search (this.startPath == /personal/*
   * 
   * @param {} store
   * @param {} options
   */
  onBeforeLoad: function onBeforeLoad(store, options) {
    options.params = {
      method: 'Tinebase_Container.searchContainers',
      filter: [{
        field: 'application_id',
        operator: 'equals',
        value: this.app.id
      }]
    };

    if (this.recordClass) {
      options.params.filter.push({
        field: 'model',
        operator: 'equals',
        value: this.recordClass.getMeta('phpClassName')
      });
    }

    if (Tine.Tinebase.container.pathIsPersonalNode(this.startPath)) {
      // direct search
      options.params.filter.push({
        field: 'type',
        operator: 'equals',
        value: Tine.Tinebase.container.TYPE_PERSONAL
      }, {
        field: 'owner_id',
        operator: 'equals',
        value: Tine.Tinebase.container.pathIsPersonalNode(this.startPath)
      });
    } else {
      // validate recents
      this.recents = {};
      this.store.each(function (r) {
        if (r != this.otherRecord) {
          this.recents[r.id] = r.get('dtselect');
        }
      }, this);
      options.params.filter.push({
        field: 'id',
        operator: 'in',
        value: Object.keys(this.recents)
      });
    }
  },
  onStoreLoad: function onStoreLoad() {
    if (!this.store) return;

    if (!Tine.Tinebase.container.pathIsPersonalNode(this.startPath)) {
      this.store.each(function (r) {
        r.set('dtselect', this.recents[r.id]);
      }, this);
      this.store.sort('dtselect', 'DESC');
      this.store.add(this.otherRecord);
    }
  },

  /**
   * filter store according to this.startPath and this.allowNodeSelect
   * 
   * NOTE: If this.startPath != '/' resents are not used as we force remote loads,
   *       thus we don't need to filter in this case!
   */
  setStoreFilter: function setStoreFilter() {
    this.store.clearFilter();
    this.store.sort('dtselect', 'DESC');
    var skipBoundary = this.store.getAt(Math.max(this.store.getCount(), 10) - 1);
    var dtselectMin = skipBoundary ? skipBoundary.get('dtselect') : -1;
    this.store.filterBy(function (record) {
      var keep = (this.allowNodeSelect || !record.get('is_container_node')) && record.get('dtselect') > dtselectMin;
      return keep;
    }, this);
  },
  setTrigger2Text: function setTrigger2Text(text) {
    var trigger2 = this.trigger.last().last().update(text);
  },
  setTrigger2Disabled: function setTrigger2Disabled(bool) {
    if (bool) {
      this.trigger2.setOpacity(0.5);
      this.trigger2.un("click", this.onTrigger2Click, this, {
        preventDefault: true
      });
    } else {
      this.trigger2.setOpacity(1);
      this.trigger2.on("click", this.onTrigger2Click, this, {
        preventDefault: true
      });
    }
  },
  getTrigger2: function getTrigger2() {
    return this.trigger2;
  },
  onTrigger2Click: Ext.emptyFn,
  // private: only blur if dialog is closed
  onBlur: function onBlur() {
    if (!this.dlg) {
      return Tine.widgets.container.SelectionComboBox.superclass.onBlur.apply(this, arguments);
    }
  },
  onSelect: function onSelect(record, index) {
    this.hasFocusedSubPanels = true;

    if (record == this.otherRecord) {
      this.onChoseOther();
    } else {
      this.manageRecents(record);
      Tine.widgets.container.SelectionComboBox.superclass.onSelect.apply(this, arguments);
    }
  },

  /**
   * @private
   */
  onChoseOther: function onChoseOther() {
    this.collapse();
    this.dlg = new Tine.widgets.container.SelectionDialog({
      recordClass: this.recordClass,
      allowNodeSelect: this.allowNodeSelect,
      allowToplevelNodeSelect: this.allowToplevelNodeSelect,
      requiredGrants: this.requiredGrants,
      treePanelClass: this.treePanelClass
    });
    this.dlg.on('select', function (d, node) {
      this.hasFocusedSubPanels = false;
      var container = this.setValue(node.attributes.container);
      this.manageRecents(container);
      this.fireEvent('select', this, node.attributes.container);

      if (this.blurOnSelect) {
        this.fireEvent('blur', this);
      }

      this.validate();
    }, this);
  },

  /**
   * @private
   */
  getValue: function getValue() {
    return this.selectedContainer !== null ? this.selectedContainer.id : '';
  },

  /**
   * @private
   */
  setValue: function setValue(container) {
    if (!container) {
      return;
    }

    if (container.hasOwnProperty('get') && Ext.isFunction(container.get)) {// container is a record -> already in store -> nothing to do
    } else if (this.store.getById(container)) {
      // store already has a record of this container
      container = this.store.getById(container);
    } else if (container.path || container.id) {
      if (container.path && this.store.findExact('path', container.path) >= 0) {
        // store already has a record of this container -> refresh
        this.store.remove(this.store.getAt(this.store.findExact('path', container.path)));
      } // ignore server name for node 'My containers'


      if (container.path && container.path === Tine.Tinebase.container.getMyNodePath()) {
        container.name = null;
      }

      container.name = container.name || Tine.Tinebase.container.path2name(container.path, this.containerName, this.containersName);
      container.id = container.id || container.path;
      container = new Tine.Tinebase.Model.Container(container, container.id);
      this.store.add(container);
    } else {
      // reject container
      return this;
    }

    if (Ext.isObject(container.get('name'))) {
      // sanitize name for display
      container.set('name', container.get('name').name);
    }

    container.set('is_container_node', !!!Tine.Tinebase.container.pathIsContainer(container.get('path')));
    this.selectedContainer = container.data; // make sure other is _last_ entry in list

    this.store.remove(this.otherRecord);
    this.store.add(this.otherRecord);
    Tine.widgets.container.SelectionComboBox.superclass.setValue.call(this, container.id);

    if (container.account_grants) {
      this.setDisabled(!container.account_grants.deleteGrant);
    }

    if (this.qtip) {
      this.qtip.remove();
    }

    return container;
  },

  /**
   * Resets the current field value to the originally loaded value and clears any validation messages.
   * See {@link Ext.form.BasicForm}.{@link Ext.form.BasicForm#trackResetOnLoad trackResetOnLoad}
   */
  reset: function reset() {
    this.supr().setValue(this.originalValue);
    this.supr().reset.call(this);
  },
  applyState: Ext.emptyFn,

  /**
   * @private
   */
  getState: function getState() {
    var recentsData = [];
    this.store.clearFilter();
    this.store.remove(this.otherRecord);
    this.store.each(function (container) {
      var data = Ext.copyTo({}, container.data, Tine.Tinebase.Model.Container.getFieldNames());
      recentsData.push(data);
    }, this);
    this.setStoreFilter();
    this.store.add(this.otherRecord);
    return {
      recentsData: recentsData
    };
  }
});
Ext.reg('tinewidgetscontainerselectcombo', Tine.widgets.container.SelectionComboBox);
Tine.widgets.form.RecordPickerManager.register('Tinebase', 'Container', Tine.widgets.container.SelectionComboBox);

/***/ }),
/* 1386 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * @namespace Tine.widgets.container
 * @class Tine.widgets.container.SelectionDialog
 * @extends Ext.Component
 *
 * This widget shows a modal container selection dialog
 */

Tine.widgets.container.SelectionDialog = Ext.extend(Ext.Component, {
  /**
   * @cfg {Boolean} allowNodeSelect
   */
  allowNodeSelect: false,

  /**
   * @cfg {Boolean} allowToplevelNodeSelect
   */
  allowToplevelNodeSelect: true,

  /**
   * @cfg {Tine.data.Record} recordClass
   */
  recordClass: false,

  /**
   * @cfg {?} defaultContainer
   */
  defaultContainer: null,

  /**
   * @cfg {string}
   * title of dialog
   */
  title: null,

  /**
   * @cfg {Number}
   */
  windowHeight: 400,

  /**
   * @property {Ext.Window}
   */
  win: null,

  /**
   * @property {Ext.tree.TreePanel}
   */
  tree: null,

  /**
   * @cfg {Array} requiredGrants
   * grants which are required to select leaf node(s)
   */
  requiredGrants: ['readGrant'],
  treePanelClass: null,
  allowNonLeafSelection: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    Tine.widgets.container.SelectionDialog.superclass.initComponent.call(this);
    var containerName = this.recordClass ? this.recordClass.getContainerName() : i18n._('Container');
    this.title = this.title ? this.title : String.format(i18n._('please select a {0}'), containerName);
    this.cancelAction = new Ext.Action({
      text: i18n._('Cancel'),
      iconCls: 'action_cancel',
      minWidth: 70,
      handler: this.onCancel,
      scope: this
    });
    this.okAction = new Ext.Action({
      disabled: true,
      text: i18n._('Ok'),
      iconCls: 'action_saveAndClose',
      minWidth: 70,
      handler: this.onOk,
      scope: this
    }); // adjust window height

    if (Ext.getBody().getHeight(true) * 0.7 < this.windowHeight) {
      this.windowHeight = Ext.getBody().getHeight(true) * 0.7;
    }

    this.initTree();
    this.win = Tine.WindowFactory.getWindow({
      title: this.title,
      closeAction: 'close',
      modal: true,
      width: 375,
      height: this.windowHeight,
      minWidth: 375,
      minHeight: this.windowHeight,
      layout: 'fit',
      plain: true,
      bodyStyle: 'padding:5px;',
      buttonAlign: 'right',
      buttons: [this.cancelAction, this.okAction],
      items: [this.tree]
    });
  },
  initTree: function initTree() {
    this.treePanelClass = this.treePanelClass || Tine.widgets.container.TreePanel;
    this.tree = new this.treePanelClass({
      recordClass: this.recordClass,
      allowMultiSelection: false,
      defaultContainer: this.defaultContainer || this.TriggerField ? this.TriggerField.defaultContainer : null,
      requiredGrants: this.requiredGrants,
      hasContextMenu: false,
      hasGrid: false
    });
    this.tree.on('click', this.onTreeNodeClick, this);
    this.tree.on('dblclick', this.onTreeNoceDblClick, this);
  },

  /**
   * @private
   */
  onTreeNodeClick: function onTreeNodeClick(node) {
    var disable = !(node.leaf || this.allowNodeSelect // TODO create isTopLevelNode() in Tine.Tinebase.container
    && (this.allowToplevelNodeSelect || node.attributes && (node.attributes.path.match(/^\/personal/) && node.attributes.path.split("/").length > 3 || node.attributes.path.match(/^\/other/) && node.attributes.path.split("/").length > 3 || node.attributes.path.match(/^\/shared/) && node.attributes.path.split("/").length > 2)));
    (function () {
      if (this.requiredGrants) {
        var selectedContainer = this.tree.getSelectedContainer(this.requiredGrants, false, true);
        disable = !selectedContainer;
      }

      this.okAction.setDisabled(disable);
    }).defer(100, this);

    if (!node.leaf) {
      node.expand();
    }
  },

  /**
   * @private
   */
  onTreeNoceDblClick: function onTreeNoceDblClick(node) {
    if (!this.okAction.isDisabled()) {
      this.onOk();
    }
  },

  /**
   * @private
   */
  onCancel: function onCancel() {
    this.onClose();
  },

  /**
   * @private
   */
  onClose: function onClose() {
    this.win.close();
  },

  /**
   * @private
   */
  onOk: function onOk() {
    var node = this.tree.getSelectionModel().getSelectedNode();

    if (node) {
      if (this.fireEvent('select', this, node) !== false) {
        this.onClose();
      }
    }
  }
});

/***/ }),
/* 1387 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2011-2014 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * render the CalDAV Url into property panel of containers
 * 
 * @class   Tine.widgets.container.CalDAVContainerPropertiesHookField
 * @extends Ext.form.TextField
 */

Tine.widgets.container.CalDAVContainerPropertiesHookField = Ext.extend(Ext.form.TextField, {
  anchor: '100%',
  readOnly: true,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.on('added', this.onContainerAdded, this);
    Tine.widgets.container.CalDAVContainerPropertiesHookField.superclass.initComponent.call(this);
  },

  /**
   * @private
   */
  onContainerAdded: function onContainerAdded() {
    this.app = Tine.Tinebase.appMgr.get(this.appName);
    this.fieldLabel = i18n._('CalDAV URL');
    this.propertiesDialog = this.findParentBy(function (p) {
      return !!p.grantContainer;
    });
    this.grantContainer = this.propertiesDialog.grantContainer;

    if (this.grantContainer.application_id && this.grantContainer.application_id.name) {
      this.hasCalDAVSupport = this.grantContainer.application_id.name == this.appName;
    } else {
      this.hasCalDAVSupport = this.grantContainer.application_id === this.app.id;
    }

    this.hidden = !this.hasCalDAVSupport; // calDAV URL

    this.value = [Tine.Tinebase.common.getUrl('full').replace(/\/$/, ''), // might have an trailing /, we can safely remove it!
    '/calendars/', Tine.Tinebase.registry.get('currentAccount').contact_id, '/', this.grantContainer.id].join('');
  }
});

/***/ }),
/* 1388 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * Container Grants dialog
 * 
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.GrantsDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.container.GrantsDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
  /**
   * @cfg {Tine.Tinebase.container.models.container}
   * Container to manage grants for
   */
  grantContainer: null,

  /**
   * @cfg {string}
   * Name of container folders, e.g. Addressbook
   */
  containerName: null,

  /**
   * @private {Ext.data.JsonStore}
   */
  grantsStore: null,

  /**
   * @private
   */
  windowNamePrefix: 'ContainerGrantsWindow_',
  loadRecord: false,
  tbarItems: [],
  evalGrants: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.containerName = this.containerName ? this.containerName : i18n._('Folder');
    this.grantsGrid = new Tine.widgets.container.GrantsGrid({
      grantContainer: this.grantContainer
    });
    Ext.apply(this.grantsGrid.getStore(), {
      baseParams: {
        method: 'Tinebase_Container.getContainerGrants',
        containerId: this.grantContainer.id
      }
    });
    this.grantsGrid.getStore().load();
    Tine.widgets.container.GrantsDialog.superclass.initComponent.call(this);
  },

  /**
   * init record to edit
   * 
   * - overwritten: we don't have a record here 
   */
  initRecord: function initRecord() {},

  /**
   * returns dialog
   */
  getFormItems: function getFormItems() {
    return this.grantsGrid;
  },

  /**
   * @private
   */
  onApplyChanges: function onApplyChanges(closeWindow) {
    Ext.MessageBox.wait(i18n._('Please wait'), i18n._('Updating Grants'));
    var grants = [];
    this.grantsGrid.getStore().each(function (_record) {
      grants.push(_record.data);
    });
    Ext.Ajax.request({
      params: {
        method: 'Tinebase_Container.setContainerGrants',
        containerId: this.grantContainer.id,
        grants: grants
      },
      scope: this,
      success: function success(_result, _request) {
        Ext.MessageBox.hide();

        if (closeWindow) {
          this.purgeListeners();
          this.window.close();
          return;
        }

        var grants = Ext.util.JSON.decode(_result.responseText);
        this.grantsGrid.getStore().loadData(grants, false);
      },
      failure: function failure(response, options) {
        var responseText = Ext.util.JSON.decode(response.responseText);

        if (responseText.data.code == 505) {
          Ext.Msg.show({
            title: i18n._('Error'),
            msg: i18n._('You are not allowed to remove all admins for this container!'),
            icon: Ext.MessageBox.ERROR,
            buttons: Ext.Msg.OK
          });
        } else {
          // call default exception handler
          var exception = responseText.data ? responseText.data : responseText;
          Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
        }
      }
    });
  }
});
/**
 * grants dialog popup / window
 */

Tine.widgets.container.GrantsDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 700,
    height: 450,
    name: Tine.widgets.container.GrantsDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.container.GrantsDialog',
    contentPanelConstructorConfig: config,
    modal: true
  });
  return window;
};

/***/ }),
/* 1389 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.TreePanel
 * @extends     Ext.tree.TreePanel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @param       {Object} config Configuration options
 * @description
 * <p>Utility class for generating container trees as used in the apps tree panel</p>
 * <p>This widget handles all container related actions like add/rename/delte and manager permissions<p>
 *<p>Example usage:</p>
<pre><code>
var taskPanel =  new Tine.containerTreePanel({
    app: Tine.Tinebase.appMgr.get('Tasks'),
    recordClass: Tine.Tasks.Model.Task
});
</code></pre>
 */

Tine.widgets.container.TreePanel = function (config) {
  Ext.apply(this, config);
  this.addEvents(
  /**
   * @event containeradded
   * Fires when a container was added
   * @param {container} the new container
   */
  'containeradd',
  /**
   * @event containerdelete
   * Fires when a container got deleted
   * @param {container} the deleted container
   */
  'containerdelete',
  /**
   * @event containerrename
   * Fires when a container got renamed
   * @param {container} the renamed container
   */
  'containerrename',
  /**
   * @event containerpermissionchange
   * Fires when a container got renamed
   * @param {container} the container whose permissions where changed
   */
  'containerpermissionchange',
  /**
   * @event containercolorset
   * Fires when a container color got changed
   * @param {container} the container whose color where changed
   */
  'containercolorset');
  Tine.widgets.container.TreePanel.superclass.constructor.call(this);
};

Ext.extend(Tine.widgets.container.TreePanel, Ext.tree.TreePanel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * @cfg {Boolean} allowMultiSelection (defaults to true)
   */
  allowMultiSelection: true,

  /**
   * @cfg {String} defaultContainerPath
   */
  defaultContainerPath: null,

  /**
   * @cfg {array} extraItems additional items to display under all
   */
  extraItems: null,

  /**
   * @cfg {String} filterMode one of:
   *   - gridFilter: hooks into the grids.store
   *   - filterToolbar: hooks into the filterToolbar (container filterModel required)
   */
  filterMode: 'gridFilter',

  /**
   * @cfg {Tine.data.Record} recordClass
   */
  recordClass: null,

  /**
   * @cfg {Array} requiredGrants
   * grants which are required to select leaf node(s)
   */
  requiredGrants: null,

  /**
   * @cfg {Boolean} useContainerColor
   * use container colors
   */
  useContainerColor: false,

  /**
   * @cfg {Boolean} useProperties
   * use container properties
   */
  useProperties: true,

  /**
   * @property {Object}
   * modelConfiguration of recordClass (if available)
   */
  modelConfiguration: null,

  /**
   * @cfg {String}
   * canonical name
   */
  canonicalName: 'ContainerTree',

  /**
   * Referenced grid panel
   */
  gridPanel: null,

  /**
   * TODO move fields to the right place
   *
   * @property {Array}
   */
  filtersToRemove: ['container_id', 'attender', 'path'],
  useArrows: true,
  border: false,
  autoScroll: true,
  enableDrop: true,
  ddGroup: 'containerDDGroup',
  hasPersonalContainer: true,
  hasContextMenu: true,

  /**
   * @fixme not needed => all events hand their events over!!!
   *
   * @property ctxNode holds treenode which got a contextmenu
   * @type Ext.tree.TreeNode
   */
  ctxNode: null,

  /**
   * No user interactions, menus etc. allowed except for browsing
   */
  readOnly: false,

  /**
   * init this treePanel
   */
  initComponent: function initComponent() {
    if (!this.appName && this.recordClass) {
      this.appName = this.recordClass.getMeta('appName');
    }

    if (!this.app) {
      this.app = Tine.Tinebase.appMgr.get(this.appName);
    }

    if (this.allowMultiSelection) {
      this.selModel = new Ext.tree.MultiSelectionModel({});
    }

    if (this.recordClass) {
      this.modelConfiguration = this.recordClass.getModelConfiguration();
    }

    if (this.modelConfiguration) {
      this.hasPersonalContainer = this.modelConfiguration.hasPersonalContainer !== false;
    }

    var containerName = this.recordClass ? this.recordClass.getContainerName() : 'container';
    var containersName = this.recordClass ? this.recordClass.getContainersName() : 'containers'; //ngettext('container', 'containers', n);

    this.containerName = this.containerName || this.app.i18n.n_hidden(containerName, containersName, 1);
    this.containersName = this.containersName || this.app.i18n._hidden(containersName);
    this.loader = this.loader || new Tine.widgets.tree.Loader({
      getParams: this.onBeforeLoad.createDelegate(this),
      inspectCreateNode: this.onBeforeCreateNode.createDelegate(this)
    });
    this.loader.on('virtualNodesSelected', this.onVirtualNodesSelected.createDelegate(this));
    var extraItems = this.getExtraItems();
    this.root = this.getRoot(extraItems);

    if (!this.hasPersonalContainer && !extraItems.length) {
      this.rootVisible = false;
    }

    if (!this.readOnly && !this.dropConfig) {
      // init drop zone
      this.dropConfig = {
        ddGroup: this.ddGroup || 'TreeDD',
        appendOnly: this.ddAppendOnly === true,

        /**
         * @todo check acl!
         */
        onNodeOver: function onNodeOver(n, dd, e, data) {
          var node = n.node; // auto node expand check

          if (node.hasChildNodes() && !node.isExpanded()) {
            this.queueExpand(node);
          }

          return node.attributes.allowDrop ? 'tinebase-tree-drop-move' : false;
        },
        isValidDropPoint: function isValidDropPoint(n, dd, e, data) {
          return n.node.attributes.allowDrop;
        },
        completeDrop: Ext.emptyFn
      };
    }

    if (this.hasContextMenu) {
      this.initContextMenu();
    }

    this.getSelectionModel().on('beforeselect', this.onBeforeSelect, this);
    this.getSelectionModel().on('selectionchange', this.onSelectionChange, this);
    this.on('click', this.onClick, this);

    if (this.hasContextMenu) {
      this.on('contextmenu', this.onContextMenu, this);
    }

    if (!this.readOnly) {
      this.on('beforenodedrop', this.onBeforeNodeDrop, this);
      this.on('append', this.onAppendNode, this);
      this.on('beforecollapsenode', this.onBeforeCollapse, this);
    }

    Tine.widgets.container.TreePanel.superclass.initComponent.call(this);
  },

  /**
   * @param nodes
   */
  onVirtualNodesSelected: function onVirtualNodesSelected(nodes) {
    this.suspendEvents();

    if (0 === nodes.length) {
      return;
    }

    var sm = this.getSelectionModel();

    if (sm && sm.selNodes) {
      sm.clearSelections(true);

      for (var i = 0; i < nodes.length; i++) {
        var node = nodes[i];

        if (sm.isSelected(node)) {
          sm.lastSelNode = node;
          continue;
        }

        sm.selNodes.push(node);
        sm.selMap[node.id] = node;
        sm.lastSelNode = node;
        node.ui.onSelectedChange(true);
      }
    }

    if (this.filterMode == 'filterToolbar' && this.filterPlugin) {
      this.onFilterChange();
    }

    this.resumeEvents();
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    if (this.recordClass) {
      return [this.recordClass.getMeta('modelName'), this.canonicalName].join(Tine.Tinebase.CanonicalPath.separator);
    }
  },
  getRoot: function getRoot(extraItems) {
    return {
      path: '/',
      cls: 'tinebase-tree-hide-collapsetool',
      expanded: true,
      children: [{
        path: Tine.Tinebase.container.getMyNodePath(),
        id: 'personal',
        hidden: !this.hasPersonalContainer
      }, {
        path: '/shared',
        id: 'shared'
      }, {
        path: '/personal',
        id: 'otherUsers',
        hidden: !this.hasPersonalContainer
      }].concat(extraItems)
    };
  },

  /**
   * template fn for subclasses to set default path
   *
   * @return {String}
   */
  getDefaultContainerPath: function getDefaultContainerPath() {
    return this.defaultContainerPath || '/';
  },

  /**
   * template fn for subclasses to append extra items
   *
   * @return {Array}
   */
  getExtraItems: function getExtraItems() {
    return this.extraItems || [];
  },

  /**
   * returns a filter plugin to be used in a grid
   */
  getFilterPlugin: function getFilterPlugin() {
    if (!this.filterPlugin) {
      this.filterPlugin = new Tine.widgets.tree.FilterPlugin({
        treePanel: this
      });
    }

    return this.filterPlugin;
  },

  /**
   * returns object of selected container/filter or null/default
   *
   * @param {Array} [requiredGrants]
   * @param {Tine.Tinebase.Model.Container} [defaultContainer]
   * @param {Boolean} onlySingle use default if more than one container in selection
   * @return {Tine.Tinebase.Model.Container}
   */
  getSelectedContainer: function getSelectedContainer(requiredGrants, defaultContainer, onlySingle) {
    var container = defaultContainer,
        sm = this.getSelectionModel(),
        selection = typeof sm.getSelectedNodes == 'function' ? sm.getSelectedNodes() : [sm.getSelectedNode()];

    if (Ext.isArray(selection) && selection.length > 0 && (!onlySingle || selection.length === 1 || !container)) {
      container = this.getContainerFromSelection(selection, requiredGrants) || container;
    } // postpone this as we don't get the whole container record here
    //        else if (this.filterMode == 'filterToolbar' && this.filterPlugin) {
    //            container = this.getContainerFromFilter() || container;
    //        }


    return container;
  },

  /**
   * get container from selection
   *
   * @param {Array} selection
   * @param {Array} requiredGrants
   * @return {Tine.Tinebase.Model.Container}
   */
  getContainerFromSelection: function getContainerFromSelection(selection, requiredGrants) {
    var result = null;
    Ext.each(selection, function (node) {
      if (node && this.nodeAcceptsContents(node.attributes)) {
        if (!requiredGrants || this.hasGrant(node, requiredGrants)) {
          result = node.attributes.container; // take the first one

          return false;
        }
      }
    }, this);
    return result;
  },

  /**
   * get container from filter toolbar
   *
   * @param {Array} requiredGrants
   * @return {Tine.Tinebase.Model.Container}
   *
   * TODO make this work -> atm we don't get the account grants here (why?)
   */
  getContainerFromFilter: function getContainerFromFilter(requiredGrants) {
    var result = null; // check if single container is selected in filter toolbar 

    var ftb = this.filterPlugin.getGridPanel().filterToolbar,
        filterValue = null;
    ftb.filterStore.each(function (filter) {
      if (filter.get('field') == this.recordClass.getMeta('containerProperty')) {
        filterValue = filter.get('value');

        if (filter.get('operator') == 'equals') {
          result = filterValue;
        } else if (filter.get('operator') == 'in' && filterValue.length == 1) {
          result = filterValue[0];
        } // take the first one


        return false;
      }
    }, this);
    return result;
  },

  /**
   * convert containerPath to treePath
   *
   * @param {String}  containerPath
   * @return {String} treePath
   */
  getTreePath: function getTreePath(containerPath) {
    var treePath = '/' + this.getRootNode().id + (containerPath !== '/' ? containerPath : ''); // replace personal with otherUsers if personal && ! personal/myaccountid

    var matches = containerPath.match(/^\/personal\/{0,1}([0-9a-z_\-]*)\/{0,1}/i);

    if (matches) {
      if (matches[1] != Tine.Tinebase.registry.get('currentAccount').accountId) {
        treePath = treePath.replace('personal', 'otherUsers');
      } else {
        treePath = treePath.replace('personal/' + Tine.Tinebase.registry.get('currentAccount').accountId, 'personal');
      }
    }

    return treePath;
  },

  /**
   * checkes if user has requested grant for given container represented by a tree node
   *
   * @param {Ext.tree.TreeNode} node
   * @param {Array} grant
   * @return {}
   */
  hasGrant: function hasGrant(node, grants) {
    var attr = node.attributes,
        condition = false;

    if (this.nodeAcceptsContents(attr)) {
      condition = true;
      Ext.each(grants, function (grant) {
        condition = condition && attr.container.account_grants[grant];
      }, this);
    }

    return condition;
  },

  /**
   * returns true if node can accept contents
   * - default: only accepts contents if container node is leaf ("virtual" nodes don't accept content)
   *
   * @param nodeAttributes
   * @returns boolean
   */
  nodeAcceptsContents: function nodeAcceptsContents(nodeAttributes) {
    return nodeAttributes && nodeAttributes.leaf;
  },

  /**
   * @private
   * - select default path
   */
  afterRender: function afterRender() {
    Tine.widgets.container.TreePanel.superclass.afterRender.call(this);
    var defaultContainerPath = this.getDefaultContainerPath();

    if (defaultContainerPath && defaultContainerPath != '/') {
      var root = '/' + this.getRootNode().id;
      this.expand(); // @TODO use getTreePath() when filemanager is fixed

      (function () {
        // no initial load triggering here
        this.getSelectionModel().suspendEvents();
        this.selectPath(root + defaultContainerPath, null, function () {
          this.getSelectionModel().resumeEvents();
        }.bind(this));
      }).defer(100, this);
    } else if (!this.hasPersonalContainer) {
      this.expandPath('/shared');
    }
  },

  /**
   * copy from Tine.Filemanager.NodeTreePanel
   * 
   * @todo: Maybe it makes sence to override expand path in extFixes? 
   * 
   * @param path
   * @param attr
   * @param callback
   */
  expandPath: function expandPath(path, attr, callback) {
    if (!path.match(/^\/xnode-/)) {
      path = this.getTreePath(path);
    }

    var keys = path.split(this.pathSeparator);
    var curNode = this.root;
    var curPath = curNode.attributes.path;
    var index = 1;

    var f = function f() {
      if (++index == keys.length) {
        if (callback) {
          callback(true, curNode);
        }

        return;
      }

      if (index > 2) {
        var c = curNode.findChild('path', curPath + '/' + keys[index]);
      } else {
        var c = curNode.findChild('id', keys[index]);
      }

      if (!c) {
        if (callback) {
          callback(false, curNode);
        }

        return;
      }

      curNode = c;
      curPath = c.attributes.path;
      c.expand(false, false, f);
    };

    curNode.expand(false, false, f);
  },

  /**
   * @private
   */
  initContextMenu: function initContextMenu() {
    this.contextMenuUserFolder = Tine.widgets.tree.ContextMenu.getMenu({
      nodeName: this.containerName,
      actions: ['add'],
      scope: this,
      backend: 'Tinebase_Container',
      backendModel: 'Container'
    });
    this.contextMenuSingleContainer = Tine.widgets.tree.ContextMenu.getMenu({
      nodeName: this.containerName,
      actions: ['delete', 'rename', 'grants'].concat(this.useProperties ? ['properties'] : []).concat(this.useContainerColor ? ['changecolor'] : []),
      scope: this,
      backend: 'Tinebase_Container',
      backendModel: 'Container'
    });
    this.contextMenuSingleContainerProperties = Tine.widgets.tree.ContextMenu.getMenu({
      nodeName: this.containerName,
      actions: ['properties'],
      scope: this,
      backend: 'Tinebase_Container',
      backendModel: 'Container'
    });
  },

  /**
   * called when node is appended to this tree
   */
  onAppendNode: function onAppendNode(tree, parent, appendedNode, idx) {
    if (appendedNode.leaf && this.hasGrant(appendedNode, this.requiredGrants)) {
      if (this.useContainerColor) {
        appendedNode.ui.render = appendedNode.ui.render.createSequence(function () {
          this.colorNode = Ext.DomHelper.insertAfter(this.iconNode, {
            tag: 'span',
            html: '&nbsp;&#9673;&nbsp',
            style: {
              color: appendedNode.attributes.container.color || '#808080'
            }
          }, true);
        }, appendedNode.ui);
      }
    }
  },

  /**
   * expand automatically on node click
   *
   * @param {} node
   * @param {} e
   */
  onClick: function onClick(node, e) {
    var sm = this.getSelectionModel(),
        selectedNode = sm.getSelectedNode(); // NOTE: in single select mode, a node click on a selected node does not trigger 
    //       a selection change. We need to do this by hand here

    if (!this.allowMultiSelection && node == selectedNode) {
      this.onSelectionChange(sm, node);
    }

    node.expand();
  },

  /**
   * show context menu
   *
   * @param {} node
   * @param {} event
   */
  onContextMenu: function onContextMenu(node, event) {
    this.ctxNode = node;
    var container = node.attributes.container,
        path = container.path,
        owner;

    if (!Ext.isString(path)) {
      return;
    }

    event.stopPropagation();
    event.preventDefault();

    if (node.attributes.leaf) {
      if (container.account_grants && container.account_grants.adminGrant) {
        this.contextMenuSingleContainer.showAt(event.getXY());
      } else {
        this.contextMenuSingleContainerProperties.showAt(event.getXY());
      }
    } else if (path.match(/^\/shared$/) && (Tine.Tinebase.common.hasRight('admin', this.app.appName) || Tine.Tinebase.common.hasRight('manage_shared_folders', this.app.appName))) {
      this.contextMenuUserFolder.showAt(event.getXY());
    } else if (Tine.Tinebase.registry.get('currentAccount').accountId == Tine.Tinebase.container.pathIsPersonalNode(path)) {
      this.contextMenuUserFolder.showAt(event.getXY());
    }
  },

  /**
   * adopt attr
   *
   * @param {Object} attr
   */
  onBeforeCreateNode: function onBeforeCreateNode(attr) {
    attr.cls = attr.cls || '';

    if (attr.accountDisplayName) {
      attr.name = attr.accountDisplayName;
      attr.path = '/personal/' + attr.accountId;
      attr.id = attr.accountId;
    }

    if (!attr.name && attr.path) {
      attr.name = Tine.Tinebase.container.path2name(attr.path, this.containerName, this.containersName);
    }

    if ('shared' === attr.id && !this.hasPersonalContainer) {
      attr.name = this.containersName;
    }

    Ext.applyIf(attr, {
      text: attr.name,
      qtip: attr.name,
      leaf: !!attr.account_grants,
      allowDrop: !!attr.account_grants && attr.account_grants.addGrant
    });
    attr.text = Tine.Tinebase.EncodingHelper.encode(attr.text);
    attr.qtip = Tine.Tinebase.EncodingHelper.encode(attr.qtip); // copy 'real' data to container space

    attr.container = Ext.copyTo({}, attr, Tine.Tinebase.Model.Container.getFieldNames());
  },

  /**
   * returns params for async request
   *
   * @param {Ext.tree.TreeNode} node
   * @return {Object}
   */
  onBeforeLoad: function onBeforeLoad(node) {
    var path = node.attributes.path;
    var type = Tine.Tinebase.container.path2type(path);
    var owner = Tine.Tinebase.container.pathIsPersonalNode(path);

    if (type === 'personal' && !owner) {
      type = 'otherUsers';
    }

    var params = {
      method: 'Tinebase_Container.getContainer',
      model: this.recordClass.getPhpClassName(),
      containerType: type,
      requiredGrants: this.requiredGrants,
      owner: owner
    };
    return params;
  },

  /**
   * permit selection of nodes with missing required grant
   *
   * @param {} sm
   * @param {} newSelection
   * @param {} oldSelection
   * @return {Boolean}
   */
  onBeforeSelect: function onBeforeSelect(sm, newSelection, oldSelection) {
    if (this.requiredGrant && newSelection.isLeaf()) {
      var accountGrants = newSelection.attributes.container.account_grants || {};

      if (!accountGrants[this.requiredGrant]) {
        var message = '<b>' + String.format(i18n._("You are not allowed to select the {0} '{1}':"), this.containerName, newSelection.attributes.text) + '</b><br />' + String.format(i18n._("{0} grant is required for desired action"), this.requiredGrant);
        Ext.Msg.alert(i18n._('Insufficient Grants'), message);
        return false;
      }
    }
  },

  /**
   * record got dropped on container node
   *
   * @param {Object} dropEvent
   * @private
   *
   * TODO use Ext.Direct
   */
  onBeforeNodeDrop: function onBeforeNodeDrop(dropEvent) {
    var targetContainerId = dropEvent.target.id; // get selection filter from grid

    var sm = this.app.getMainScreen().getCenterPanel().getGrid().getSelectionModel();

    if (sm.getCount() === 0) {
      return false;
    }

    var filter = sm.getSelectionFilter(); // move messages to folder

    Ext.Ajax.request({
      params: {
        method: 'Tinebase_Container.moveRecordsToContainer',
        targetContainerId: targetContainerId,
        filterData: filter,
        model: this.recordClass.getMeta('modelName'),
        applicationName: this.recordClass.getMeta('appName')
      },
      scope: this,
      success: function success(result, request) {
        // update grid
        this.app.getMainScreen().getCenterPanel().loadGridData();
      }
    }); // prevent repair actions

    dropEvent.dropStatus = true;
    return true;
  },

  /**
   * require reload when node is collapsed
   */
  onBeforeCollapse: function onBeforeCollapse(node) {
    // NOTE: we should somehow keep the state if user expands again -> seams hard
    // var selections = this.getSelectionModel().getSelectedNodes();
    this.getSelectionModel().suspendEvents();
    node.removeAll();
    node.loaded = false;
    this.getSelectionModel().resumeEvents();
  },
  onFilterChange: function onFilterChange() {
    // get filterToolbar
    var ftb = this.filterPlugin.getGridPanel().filterToolbar; // in case of filterPanel

    ftb = ftb.activeFilterPanel ? ftb.activeFilterPanel : ftb; // remove all ftb container and /toberemoved/ filters

    ftb.supressEvents = true;
    ftb.filterStore.each(function (filter) {
      var field = filter.get('field');

      if (this.filtersToRemove.indexOf(field) > -1) {
        ftb.deleteFilter(filter, true);
      }
    }, this);
    ftb.supressEvents = false; // set ftb filters according to tree selection

    var containerFilter = this.getFilterPlugin().getFilter();
    ftb.addFilter(new ftb.record(containerFilter));
    ftb.onFiltertrigger();
  },

  /**
   * called when tree selection changes
   *
   * @param {} sm
   * @param {} nodes
   */
  onSelectionChange: function onSelectionChange(sm, nodes) {
    if (this.filterMode == 'gridFilter' && this.filterPlugin) {
      this.filterPlugin.onFilterChange();
    }

    if (this.filterMode == 'filterToolbar' && this.filterPlugin) {
      this.onFilterChange(); // finally select the selected node, as filtertrigger clears all selections

      sm.suspendEvents();
      Ext.each(nodes, function (node) {
        sm.select(node, Ext.EventObject, true);
      }, this);
      sm.resumeEvents();
    }
  },

  /**
   * selects path by container Path
   *
   * @param {String} containerPath
   * @param {String} [attr]
   * @param {Function} [callback]
   */
  selectContainerPath: function selectContainerPath(containerPath, attr, callback) {
    return this.selectPath(this.getTreePath(containerPath), attr, callback);
  },

  /**
   * get default container for new records
   *
   * @param {String} default container registry key
   * @return {Tine.Tinebase.Model.Container}
   */
  getDefaultContainer: function getDefaultContainer(registryKey) {
    if (!registryKey) {
      registryKey = 'defaultContainer';
    }

    var container = Tine[this.appName].registry.get(registryKey);
    return this.getSelectedContainer('addGrant', container, true);
  }
});

/***/ }),
/* 1390 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.container');
/**
 * Container Properties dialog
 * 
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.PropertiesDialog
 * @extends     Tine.widgets.dialog.EditDialog
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.container.PropertiesDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
  /**
   * @cfg {Tine.Tinebase.container.models.container}
   * Container to manage grants for
   */
  grantContainer: null,

  /**
   * @cfg {string}
   * Name of container folders, e.g. Addressbook
   */
  containerName: null,

  /**
   * @private
   */
  windowNamePrefix: 'ContainerPropertiesWindow_',
  loadRecord: false,
  tbarItems: [],
  evalGrants: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    var _ = window.lodash,
        me = this,
        getTranslation = function getTranslation(string) {
      var translation = me.grantsModelApp.i18n._hidden(string);

      return translation != string ? translation : window.i18n._hidden(string);
    };

    if (!this.grantsModel) {
      this.grantsModel = Tine.Tinebase.container.getGrantsModel(this.grantContainer);
    }

    if (!this.grantsModelApp) {
      this.grantsModelApp = Tine.Tinebase.appMgr.get(this.grantsModel.getMeta('appName'));
    } // my grants


    this.myGrants = [];

    for (var grant in this.grantContainer.account_grants) {
      if (this.grantContainer.account_grants.hasOwnProperty(grant) && this.grantContainer.account_grants[grant] && Tine.widgets.container.GrantsGrid.prototype[grant + 'Title'] && this.grantsModel.hasField(grant)) {
        this.myGrants.push({
          title: getTranslation(Tine.widgets.container.GrantsGrid.prototype[grant + 'Title']),
          description: getTranslation(Tine.widgets.container.GrantsGrid.prototype[grant + 'Description'])
        });
      }
    }

    this.myGrantsTemplate = new Ext.XTemplate('<tpl for=".">', '<span class="tine-wordbox" ext:qtip="', '{[this.encode(values.description)]}', '">', '{[this.encode(values.title)]}', '</span>', '</tpl>', {
      encode: function encode(description) {
        return Tine.Tinebase.common.doubleEncode(description);
      }
    }).compile();
    Tine.widgets.container.PropertiesDialog.superclass.initComponent.call(this);
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    return ['', this.app, this.canonicalName, 'ContainerProperties', this.grantsModel.getMeta('')].join(Tine.Tinebase.CanonicalPath.separator);
  },

  /**
   * init record to edit
   * 
   * - overwritten: we don't have a record here 
   */
  initRecord: function initRecord() {},

  /**
   * returns dialog
   */
  getFormItems: function getFormItems() {
    return {
      xtype: 'tabpanel',
      plain: true,
      activeTab: 0,
      items: [{
        title: i18n._('Properties'),
        border: false,
        frame: true,
        layout: 'form',
        labelAlign: 'top',
        labelSeparator: '',
        layoutConfig: {
          trackLabels: true
        },
        plugins: [{
          ptype: 'ux.itemregistry',
          key: 'Tine.widgets.container.PropertiesDialog.FormItems.Properties'
        }],
        items: [{
          xtype: 'textfield',
          anchor: '100%',
          readOnly: true,
          fieldLabel: i18n._('Name'),
          value: this.grantContainer.name
        }, {
          xtype: 'textfield',
          anchor: '100%',
          readOnly: true,
          fieldLabel: i18n._('Hierarchy/Name'),
          value: this.grantContainer.hierarchy
        }, {
          xtype: 'colorfield',
          width: 40,
          readOnly: true,
          fieldLabel: i18n._('Color'),
          value: this.grantContainer.color
        }, {
          xtype: 'label',
          anchor: '100%',
          readOnly: true,
          fieldLabel: i18n._('My Grants'),
          html: this.myGrantsTemplate.applyTemplate(this.myGrants)
        }]
      }]
    };
  },

  /**
   * @private
   */
  onApplyChanges: function onApplyChanges() {
    this.purgeListeners();
    this.window.close();
  }
});
/**
 * grants dialog popup / window
 */

Tine.widgets.container.PropertiesDialog.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 700,
    height: 450,
    name: Tine.widgets.container.PropertiesDialog.windowNamePrefix + Ext.id(),
    contentPanelConstructor: 'Tine.widgets.container.PropertiesDialog',
    contentPanelConstructorConfig: config,
    modal: true
  });
  return window;
};

/***/ }),
/* 1391 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * TODO         extend Tine.widgets.grid.PickerFilter
 */
Ext.ns('Tine.widgets.container');
/**
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.FilterModel
 * @extends     Tine.widgets.grid.FilterModel
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.widgets.container.FilterModel = Ext.extend(Tine.widgets.grid.FilterModel, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * If this component is called from another app than the container belongs to, set this to this app
   * 
   * @cfg {Tine.Tinebase.Application} callingApp
   */
  callingApp: null,

  /**
   * @cfg {Tine.Tinebase.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,

  /**
   * @cfg {Array} operators allowed operators
   */
  operators: ['equals', 'in', 'not', 'notin'],

  /**
   * @cfg {String} field container field (defaults to container_id)
   */
  field: 'container_id',

  /**
   * the label of the filter (autoset from containing recordClass, if none is given)
   * 
   * @type {String}
   */
  label: null,

  /**
   * @cfg {String} defaultOperator default operator, one of <tt>{@link #operators} (defaults to equals)
   */
  defaultOperator: 'equals',

  /**
   * @cfg {String} defaultValue default value (defaults to all)
   */
  defaultValue: {
    path: '/'
  },

  /**
   * @private
   */
  initComponent: function initComponent() {
    // get recordClass if string is given
    if (Ext.isString(this.recordClass)) {
      var split = this.recordClass.split('.');
      this.recordClass = Tine[split[0]].Model[split[1]];
    } // get application if string is given


    if (Ext.isString(this.app)) {
      this.app = Tine.Tinebase.appMgr.get(this.app);
    } // get calling application if string is given


    if (Ext.isString(this.callingApp)) {
      this.callingApp = Tine.Tinebase.appMgr.get(this.callingApp);
    }

    Tine.widgets.container.FilterModel.superclass.initComponent.call(this);
    this.containerName = this.app.i18n.n_hidden(this.recordClass.getMeta('containerName'), this.recordClass.getMeta('containersName'), 1);
    this.containersName = this.app.i18n._hidden(this.recordClass.getMeta('containersName'));
    this.label = this.label ? this.callingApp.i18n._(this.label) : this.containerName;
    this.gender = this.app.i18n._hidden('GENDER_' + this.recordClass.getMeta('containerName'));
  },

  /**
   * returns valueType of given filter
   * 
   * @param {Record} filter
   * @return {String}
   */
  getValueType: function getValueType(filter) {
    var operator = filter.get('operator') ? filter.get('operator') : this.defaultOperator;
    var valueType = 'selectionComboBox';

    switch (operator) {
      case 'notin':
      case 'in':
        valueType = 'FilterModelMultipleValueField';
        break;
    }

    return valueType;
  },

  /**
   * called on operator change of a filter row
   * @private
   */
  onOperatorChange: function onOperatorChange(filter, newOperator) {
    this.supr().onOperatorChange.call(this, filter, newOperator);
    var valueType = this.getValueType(filter);

    for (var valueField in filter.valueFields) {
      filter.valueFields[valueField][valueField == valueType ? 'show' : 'hide']();
    }

    ;
    filter.formFields.value = filter.valueFields[valueType];
    filter.formFields.value.setWidth(filter.formFields.value.width);
    filter.formFields.value.wrap.setWidth(filter.formFields.value.width);
    filter.formFields.value.syncSize();
  },

  /**
   * value renderer
   * 
   * @param {Ext.data.Record} filter line
   * @param {Ext.Element} element to render to 
   */
  valueRenderer: function valueRenderer(filter, el) {
    var valueType = this.getValueType(filter);
    filter.valueFields = {};
    filter.valueFields.selectionComboBox = new Tine.widgets.container.SelectionComboBox({
      hidden: valueType != 'selectionComboBox',
      app: this.app,
      filter: filter,
      listWidth: 200,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      renderTo: el,
      allowNodeSelect: true,
      recordClass: this.recordClass,
      appName: this.recordClass.getMeta('appName'),
      containerName: this.containerName,
      containersName: this.containersName,
      getValue: function getValue() {
        return this.selectedContainer ? this.selectedContainer.path : null;
      },
      setValue: function setValue(value) {
        if (this.filter.get('operator') == 'specialNode' || this.filter.get('operator') == 'personalNode') {
          var operatorText = this.filter.data.operator === 'personalNode' ? i18n._('is personal of') : i18n._('is equal to'); // use equals for node 'My containers'

          if (value.path && value.path === Tine.Tinebase.container.getMyNodePath()) {
            operatorText = i18n._('is equal to');
          }

          this.filter.formFields.operator.setRawValue(operatorText);
        }

        return Tine.widgets.container.SelectionComboBox.prototype.setValue.call(this, value);
      },
      listeners: {
        scope: this,
        select: this.onFiltertrigger,
        specialkey: function specialkey(field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        }
      }
    });
    filter.valueFields.FilterModelMultipleValueField = new Tine.widgets.container.FilterModelMultipleValueField({
      hidden: valueType != 'FilterModelMultipleValueField',
      app: this.app,
      recordClass: this.recordClass,
      containerName: this.containerName,
      containersName: this.containersName,
      filter: filter,
      value: filter.data.value ? filter.data.value : this.defaultValue,
      renderTo: el,
      listeners: {
        scope: this,
        select: this.onFiltertrigger,
        specialkey: function specialkey(field, e) {
          if (e.getKey() == e.ENTER) {
            this.onFiltertrigger();
          }
        }
      }
    });
    return filter.valueFields[valueType];
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tine.widget.container.filtermodel'] = Tine.widgets.container.FilterModel;
/**
 * @namespace   Tine.widgets.container
 * @class       Tine.widgets.container.FilterModelMultipleValueField
 * @extends     Ext.ux.form.LayerCombo
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.widgets.container.FilterModelMultipleValueField = Ext.extend(Ext.ux.form.LayerCombo, {
  /**
   * @cfg {string} containerName
   * name of container (singular)
   */
  containerName: 'container',

  /**
   * @cfg {string} containerName
   * name of container (plural)
   */
  containersName: 'containers',

  /**
   * @cfg {Tine.Tinebase.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,
  hideButtons: false,
  layerAlign: 'tr-br?',
  minLayerWidth: 400,
  layerHeight: 300,
  lazyInit: true,
  formConfig: {
    labelAlign: 'left',
    labelWidth: 30
  },
  initComponent: function initComponent() {
    this.app = this.app || Tine.Tinebase.appMgr.get(this.appName);
    this.recordClass = this.recordClass || Tine.Tinebase.data.RecordMgr.get(this.app, this.modelName);
    this.containerName = this.containerName === 'container' && this.recordClass ? this.recordClass.getContainerName() : this.containerName;
    this.containersName = this.containersName === 'containers' && this.recordClass ? this.recordClass.getContainersName() : this.containersName;
    this.on('beforecollapse', this.onBeforeCollapse, this);
    this.store = new Ext.data.SimpleStore({
      fields: this.recordClass
    });
    this.supr().initComponent.call(this);
  },

  /**
   * @return Ext.grid.ColumnModel
   */
  getColumnModel: function getColumnModel() {
    return new Ext.grid.ColumnModel({
      defaults: {
        sortable: false
      },
      columns: [{
        id: 'name',
        header: String.format(i18n._('Selected {0}'), this.containersName),
        dataIndex: 'name'
      }]
    });
  },

  /**
   * 
   * @return {Array} of containerData
   */
  getFormValue: function getFormValue() {
    var container = [];
    this.store.each(function (containerRecord) {
      container.push(containerRecord.data);
    }, this);
    return container;
  },
  getItems: function getItems() {
    var containerSelectionCombo = this.containerSelectionCombo = new Tine.widgets.container.SelectionComboBox({
      allowNodeSelect: true,
      allowBlank: true,
      blurOnSelect: true,
      recordClass: this.recordClass,
      appName: this.recordClass.getMeta('appName'),
      containerName: this.containerName,
      containersName: this.containersName,
      listeners: {
        scope: this,
        select: this.onContainerSelect
      }
    });
    this.containerGridPanel = new Tine.widgets.grid.PickerGridPanel({
      height: this.layerHeight || 'auto',
      recordClass: Tine.Tinebase.Model.Container,
      store: this.store,
      autoExpandColumn: 'name',
      getColumnModel: this.getColumnModel.createDelegate(this),
      initActionsAndToolbars: function initActionsAndToolbars() {
        Tine.widgets.grid.PickerGridPanel.prototype.initActionsAndToolbars.call(this);
        this.tbar = new Ext.Toolbar({
          layout: 'fit',
          items: [containerSelectionCombo]
        });
      }
    });
    var items = [this.containerGridPanel];
    return items;
  },

  /**
   * cancel collapse if ctx menu or container selection is shown
   * 
   * @return Boolean
   */
  onBeforeCollapse: function onBeforeCollapse() {
    var contextMenuVisible = this.containerGridPanel.contextMenu && !this.containerGridPanel.contextMenu.hidden,
        containerSelectionVisible = this.containerSelectionCombo.dlg && !this.containerSelectionCombo.dlg.win.isDestroyed;
    return !(contextMenuVisible || this.containerSelectionCombo.isExpanded() || containerSelectionVisible);
  },
  onContainerSelect: function onContainerSelect(field, containerData) {
    var existingRecord = this.store.getById(containerData.id);

    if (!existingRecord) {
      var data = containerData.data ? containerData.data : containerData;
      this.store.add(new Tine.Tinebase.Model.Container(data));
    } else {
      var idx = this.store.indexOf(existingRecord);
      var row = this.containerGridPanel.getView().getRow(idx);
      Ext.fly(row).highlight();
    }

    this.containerSelectionCombo.clearValue();
  },

  /**
   * @param {Array/Object} value
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    this.value = value;
    value = Ext.isArray(value) ? value : [value];
    this.currentValue = [];
    this.store.removeAll();
    var containerNames = [];
    Ext.each(value, function (containerData) {
      // ignore broken value
      if (!containerData) return; // ignore server name for node 'My containers'

      if (containerData.path && containerData.path === Tine.Tinebase.container.getMyNodePath()) {
        containerData.name = null;
      }

      containerData.name = containerData.name || Tine.Tinebase.container.path2name(containerData.path, this.containerName, this.containersName);
      containerData.id = containerData.id || containerData.path;
      this.store.add(new Tine.Tinebase.Model.Container(containerData));
      this.currentValue.push(containerData);
      containerNames.push(containerData.name);
    }, this);
    this.setRawValue(containerNames.join(', '));
    this.validate();
    return this;
  },

  /**
   * sets values to innerForm
   */
  setFormValue: function setFormValue(value) {// nothing to do
  }
});
Ext.reg('containerspicker', Tine.widgets.container.FilterModelMultipleValueField);

/***/ }),
/* 1392 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO make initial color work again in Ext.menu.ColorMenu
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tags');
/**
 * Class for a single tag panel
 * 
 * @namespace   Tine.widgets.tags
 * @class       Tine.widgets.tags.TagPanel
 * @extends     Ext.Panel
 */

Tine.widgets.tags.TagPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {Tine.Tinebase.Application} app Application which uses this panel
   */
  app: null,

  /**
   * @cfg {String} recordId Id of record this panel is displayed for
   */
  recordId: '',

  /**
   * @cfg {Array} tags Initial tags
   */
  tags: null,

  /**
   * @var {Ext.data.JsonStore}
   * Holds tags of the record this panel is displayed for
   */
  recordTagsStore: null,

  /**
   * @var {Ext.data.JsonStore} Store for available tags
   */
  availableTagsStore: false,

  /**
   * @var {Ext.form.ComboBox} live search field to search tags to add
   */
  searchField: null,
  iconCls: 'action_tag',
  layout: 'fit',
  bodyStyle: 'padding: 2px 2px 2px 2px',
  collapsible: true,
  border: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.title = i18n._('Tags') + ' (0)';
    this.app = Ext.isString(this.app) ? Tine.Tinebase.appMgr.get(this.app) : this.app; // init recordTagsStore

    this.tags = [];
    var that = this;
    this.recordTagsStore = new Ext.data.JsonStore({
      id: 'id',
      fields: Tine.Tinebase.Model.Tag,
      data: this.tags,
      scope: that,
      listeners: {
        add: that.onChange,
        load: that.onChange,
        remove: that.onChange,
        scope: that
      }
    }); // init availableTagsStore

    this.availableTagsStore = new Ext.data.JsonStore({
      id: 'id',
      root: 'results',
      totalProperty: 'totalCount',
      fields: Tine.Tinebase.Model.Tag,
      baseParams: {
        method: 'Tinebase.searchTags',
        filter: {
          application: this.app.appName,
          grant: 'use'
        },
        paging: {}
      }
    });
    this.searchField = new Tine.widgets.tags.TagCombo({
      app: this.app,
      onlyUsableTags: true,
      disableClearer: true
    });
    this.searchField.on('select', function (searchField, selectedTag) {
      if (this.recordTagsStore.getById(selectedTag.id) === undefined) {
        this.recordTagsStore.add(selectedTag);
      }

      searchField.blur();
      searchField.reset();
    }, this);
    this.bottomBar = new Ext.Container({
      layout: 'column',
      items: [Ext.apply(this.searchField, {
        columnWidth: .99
      }), this.addTagButton = new Ext.Button({
        text: '',
        width: 16,
        iconCls: 'action_add',
        tooltip: i18n._('Add a new personal tag'),
        scope: this,
        hidden: !Tine.Tinebase.common.hasRight('use_personal_tags', this.app.appName),
        handler: function handler() {
          Ext.Msg.prompt(i18n._('Add New Personal Tag'), i18n._('Please note: You create a personal tag. Only you can see it!') + ' <br />' + i18n._('Enter tag name:'), function (btn, text) {
            if (btn == 'ok') {
              this.onTagAdd(text);
            }
          }, this, false, this.searchField.lastQuery);
        }
      })]
    });
    var tagTpl = new Ext.XTemplate('<tpl for=".">', '<div class="x-widget-tag-tagitem" id="{id}">', '<div class="x-widget-tag-tagitem-color" style="background-color: {color};">&#160;</div>', '<div class="x-widget-tag-tagitem-text" ext:qtip="', '{[this.encode(values.name)]}', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</i>&nbsp;[{occurrence}]', '<tpl if="description != null && description.length &gt; 1"><hr>{[this.encode(values.description)]}</tpl>" >', '&nbsp;{[this.encode(values.name)]}', '</div>', '</div>', '</tpl>', {
      encode: function encode(value) {
        return Tine.Tinebase.common.doubleEncode(value);
      }
    });
    this.dataView = new Ext.DataView({
      store: this.recordTagsStore,
      tpl: tagTpl,
      autoHeight: true,
      multiSelect: true,
      overClass: 'x-widget-tag-tagitem-over',
      selectedClass: 'x-widget-tag-tagitem-selected',
      itemSelector: 'div.x-widget-tag-tagitem',
      emptyText: i18n._('No Tags to display')
    });
    this.dataView.on('contextmenu', function (dataView, selectedIdx, node, event) {
      if (!this.dataView.isSelected(selectedIdx)) {
        this.dataView.clearSelections();
        this.dataView.select(selectedIdx);
      }

      event.stopEvent();
      var selectedTags = this.dataView.getSelectedRecords();
      var selectedTag = selectedTags.length == 1 ? selectedTags[0] : null;
      var allowDelete = true;

      for (var i = 0; i < selectedTags.length; i++) {
        if (selectedTags[i].get('type') == 'shared') {
          allowDelete = false;
        }
      }

      var menu = new Ext.menu.Menu({
        plugins: [{
          ptype: 'ux.itemregistry',
          key: 'Tinebase-MainContextMenu'
        }],
        items: [new Ext.Action({
          scope: this,
          text: i18n.ngettext('Detach tag', 'Detach tags', selectedTags.length),
          iconCls: 'x-widget-tag-action-detach',
          handler: function handler() {
            for (var i = 0, j = selectedTags.length; i < j; i++) {
              this.recordTagsStore.remove(selectedTags[i]);
            }
          }
        }), '-', {
          text: i18n._('Edit tag'),
          disabled: !(selectedTag && allowDelete),
          menu: {
            items: [new Ext.Action({
              text: i18n._('Rename Tag'),
              selectedTag: selectedTag,
              scope: this,
              handler: function handler(action) {
                var tag = action.selectedTag;
                Ext.Msg.prompt(i18n._('Rename Tag') + ' "' + tag.get('name') + '"', i18n._('Please enter a new name:'), function (btn, text) {
                  if (btn == 'ok') {
                    tag.set('name', text);
                    this.onTagUpdate(tag);
                  }
                }, this, false, tag.get('name'));
              }
            }), new Ext.Action({
              text: i18n._('Edit Description'),
              selectedTag: selectedTag,
              scope: this,
              handler: function handler(action) {
                var tag = action.selectedTag;
                Ext.Msg.prompt(i18n._('Description for tag') + ' "' + tag.get('name') + '"', i18n._('Please enter new description:'), function (btn, text) {
                  if (btn == 'ok') {
                    tag.set('description', text);
                    this.onTagUpdate(tag);
                  }
                }, this, 30, tag.get('description'));
              }
            }), new Ext.Action({
              text: i18n._('Change Color'),
              iconCls: 'action_changecolor',
              scope: this,
              menu: new Ext.menu.ColorMenu({
                // not working any longer ->
                //value: selectedTag ? selectedTag.get('color') : '#FFFFFF',
                // something like this should work -> 
                // (from extjs api doc: (value) The initial color to highlight (should be a valid 6-digit color hex code without the # symbol). Note that the hex codes are case-sensitive.)
                //value: selectedTag ? Ext.util.Format.lowercase(selectedTag.get('color').substr(1)) : 'ffffff',
                scope: this,
                listeners: {
                  select: function select(menu, color) {
                    color = '#' + color;

                    if (selectedTag.get('color') != color) {
                      selectedTag.set('color', color);
                      this.onTagUpdate(selectedTag);
                    }
                  },
                  scope: this
                }
              })
            })]
          }
        }, new Ext.Action({
          disabled: !allowDelete,
          scope: this,
          text: i18n.ngettext('Delete Tag', 'Delete Tags', selectedTags.length),
          iconCls: 'action_delete',
          handler: function handler() {
            var tagsToDelete = [];

            for (var i = 0, j = selectedTags.length; i < j; i++) {
              // don't request to delete non existing tags
              if (selectedTags[i].id.length > 20) {
                tagsToDelete.push(selectedTags[i].id);
              }
            } // @todo use correct strings: Realy -> Really / disapear -> disappear


            Ext.MessageBox.confirm(i18n.ngettext('Really delete selected tag?', 'Really delete selected tags?', selectedTags.length), i18n.ngettext('The selected tag will be deleted and disappear for all entries', 'The selected tags will be removed and disappear for all entries', selectedTags.length), function (btn) {
              if (btn == 'yes') {
                Ext.MessageBox.wait(i18n._('Please wait a moment...'), i18n.ngettext('Deleting Tag', 'Deleting Tags', selectedTags.length));
                Ext.Ajax.request({
                  params: {
                    method: 'Tinebase.deleteTags',
                    ids: tagsToDelete
                  },
                  success: function success(_result, _request) {
                    // reset avail tag store
                    this.availableTagsStore.lastOptions = null;

                    for (var i = 0, j = selectedTags.length; i < j; i++) {
                      this.recordTagsStore.remove(selectedTags[i]);
                    }

                    Ext.MessageBox.hide();
                  },
                  failure: function failure(result, request) {
                    Ext.MessageBox.alert(i18n._('Failed'), i18n._('Could not delete Tag(s).'));
                  },
                  scope: this
                });
              }
            }, this);
          }
        })]
      });

      if (!this.searchField.disabled) {
        menu.showAt(event.getXY());
      }
    }, this);
    this.formField = {
      layout: 'form',
      items: new Tine.widgets.tags.TagFormField({
        tagsPanel: this,
        recordTagsStore: this.recordTagsStore
      })
    };
    this.items = [{
      xtype: 'panel',
      layout: 'fit',
      bbar: this.bottomBar,
      items: [this.dataView, this.formField]
    }];
    Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.registerSkipItem(this);
    Tine.widgets.tags.TagPanel.superclass.initComponent.call(this);
  },
  getFormField: function getFormField() {
    return this.formField.items;
  },

  /**
   * @private
   */
  onTagAdd: function onTagAdd(tagName) {
    if (tagName.length < 3) {
      Ext.Msg.show({
        title: i18n._('Notice'),
        msg: i18n._('The minimum tag length is three.'),
        buttons: Ext.Msg.OK,
        animEl: 'elId',
        icon: Ext.MessageBox.INFO
      });
    } else {
      var isAttached = false;
      this.recordTagsStore.each(function (tag) {
        if (tag.data.name == tagName) {
          isAttached = true;
        }
      }, this);

      if (!isAttached) {
        var tagToAttach = false;
        this.availableTagsStore.each(function (tag) {
          if (tag.data.name == tagName) {
            tagToAttach = tag;
          }
        }, this);

        if (!tagToAttach) {
          tagToAttach = new Tine.Tinebase.Model.Tag({
            name: tagName,
            type: 'personal',
            description: '',
            color: '#FFFFFF'
          });

          if (!Ext.isIE) {
            this.el.mask();
          }

          Ext.Ajax.request({
            params: {
              method: 'Tinebase.saveTag',
              tag: tagToAttach.data
            },
            success: function success(_result, _request) {
              var tagData = Ext.util.JSON.decode(_result.responseText);
              var newTag = new Tine.Tinebase.Model.Tag(tagData, tagData.id);
              this.recordTagsStore.add(newTag); // reset avail tag store

              this.availableTagsStore.lastOptions = null;
              this.el.unmask();
            },
            failure: function failure(result, request) {
              Ext.MessageBox.alert(i18n._('Failed'), i18n._('Could not create tag.'));
              this.el.unmask();
            },
            scope: this
          });
        } else {
          this.recordTagsStore.add(tagToAttach);
        }
      }
    }
  },
  onTagUpdate: function onTagUpdate(tag) {
    if (tag.get('name').length < 3) {
      Ext.Msg.show({
        title: i18n._('Notice'),
        msg: i18n._('The minimum tag length is three.'),
        buttons: Ext.Msg.OK,
        animEl: 'elId',
        icon: Ext.MessageBox.INFO
      });
    } else {
      this.el.mask();
      Ext.Ajax.request({
        params: {
          method: 'Tinebase.saveTag',
          tag: tag.data
        },
        success: function success(_result, _request) {
          // reset avail tag store
          this.availableTagsStore.lastOptions = null;
          this.el.unmask();
        },
        failure: function failure(result, request) {
          Ext.MessageBox.alert(i18n._('Failed'), i18n._('Could not update tag.'));
          this.el.unmask();
        },
        scope: this
      });
    }
  },

  /**
   * updates the title
   */
  onChange: function onChange() {
    if (this.recordTagsStore) {
      this.title = i18n._('Tags') + ' (' + this.recordTagsStore.getCount() + ')';

      if (this.header) {
        this.setTitle(this.title);
      }
    }
  }
});
Ext.reg('Tine.widgets.tags.TagPanel', Tine.widgets.tags.TagPanel);
/**
 * @private Helper class to have tags processing in the standard form/record cycle
 */

Tine.widgets.tags.TagFormField = Ext.extend(Ext.form.Field, {
  /**
   * @cfg {Ext.data.JsonStore} recordTagsStore a store where the record tags are in.
   */
  recordTagsStore: null,
  name: 'tags',
  hidden: true,
  labelSeparator: '',
  requiredGrant: 'editGrant',

  /**
   * @private
   */
  initComponent: function initComponent() {
    Tine.widgets.tags.TagFormField.superclass.initComponent.call(this); //this.hide();
  },

  /**
   * returns tags data of the current record
   */
  getValue: function getValue() {
    var value = [];
    this.recordTagsStore.each(function (tag) {
      if (tag.id.length > 5 && !String(tag.id).match(/ext-record/)) {
        //if we have a valid id we just return the id
        value.push(tag.id);
      } else {
        //it's a new tag and will be saved on the fly
        value.push(tag.data);
      }
    });
    return value;
  },

  /**
   * sets tags from an array of tag data objects (not records)
   */
  setValue: function setValue(value) {
    // set empty value
    value = value || []; // replace template fields

    Tine.Tinebase.Model.Tag.replaceTemplateField(value);
    this.recordTagsStore.loadData(value);
  },
  setDisabled: function setDisabled(disabled) {
    // disable combo, btn, context
    this.tagsPanel.searchField.setDisabled(disabled);
    this.tagsPanel.addTagButton.setDisabled(disabled);
  }
});
/**
 * Dialog for editing a tag itself
 */

Tine.widgets.tags.TagEditDialog = Ext.extend(Ext.Window, {
  width: 200,
  height: 300,
  layout: 'fit',
  margins: '0px 5px 0px 5px',
  initComponent: function initComponent() {
    this.items = new Ext.form.FormPanel({
      defaults: {
        xtype: 'textfield',
        anchor: '100%'
      },
      labelAlign: 'top',
      items: [{
        name: 'name',
        fieldLabel: 'Name'
      }, {
        name: 'description',
        fieldLabel: i18n._('Description')
      }, {
        name: 'color',
        fieldLabel: i18n._('Color')
      }]
    });
    Tine.widgets.tags.TagEditDialog.superclass.initComponent.call(this);
  }
});
Tine.widgets.tags.EditDialog = Ext.extend(Ext.Window, {
  layout: 'border',
  width: 640,
  heigh: 480,
  initComponent: function initComponent() {
    this.items = [{
      region: 'west',
      split: true
    }, {
      region: 'center',
      split: true
    }];
    Tine.widgets.tags.EditDialog.superclass.call(this);
  }
});

/***/ }),
/* 1393 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 * TODO         use new filter syntax in onBeforeQuery when TagFilter is refactored and extends Tinebase_Model_Filter_FilterGroup 
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tags');
/**
 * @namespace   Tine.widgets.tags
 * @class       Tine.widgets.tags.TagCombo
 * @extends     Ext.ux.form.ClearableComboBox
 */

Tine.widgets.tags.TagCombo = Ext.extend(Ext.ux.form.ClearableComboBox, {
  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * @cfg {Bool} findGlobalTags true to find global tags during search (default: true)
   */
  findGlobalTags: true,

  /**
   * @cfg {Bool} onlyUsableTags true to find only usable flags for the user (default: true)
   */
  onlyUsableTags: false,
  emptyText: null,
  mode: 'remote',
  triggerAction: 'all',
  displayField: 'name',
  valueField: 'id',

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.emptyText = this.emptyText ? this.emptyText : i18n._('tag name');
    this.initStore();
    this.initTemplate();
    Tine.widgets.tags.TagCombo.superclass.initComponent.call(this);
    this.on('select', this.onSelectRecord, this);
    this.on('beforequery', this.onBeforeQuery, this);
  },

  /**
   * hander of select event
   * NOTE: executed after native onSelect method
   */
  onSelectRecord: function onSelectRecord() {
    var v = this.getValue();

    if (String(v) !== String(this.startValue)) {
      this.fireEvent('change', this, v, this.startValue);
    }
  },

  /**
   * use beforequery to set query filter
   * 
   * @param {Event} qevent
   */
  onBeforeQuery: function onBeforeQuery(qevent) {
    var filter = {
      name: qevent.query && qevent.query != '' ? '%' + qevent.query + '%' : '',
      application: this.app ? this.app.appName : '',
      grant: this.onlyUsableTags ? 'use' : 'view'
    };
    this.store.baseParams.filter = filter;
  },

  /**
   * set value
   * 
   * @param {} value
   */
  setValue: function setValue(value) {
    if (typeof value === 'object' && Object.prototype.toString.call(value) === '[object Object]') {
      if (!this.store.getById(value.id)) {
        this.store.addSorted(new Tine.Tinebase.Model.Tag(value));
      }

      value = value.id;
    }

    Tine.widgets.tags.TagCombo.superclass.setValue.call(this, value);
  },

  /**
   * init store
   */
  initStore: function initStore() {
    var baseParams = {
      method: 'Tinebase.searchTags',
      paging: {}
    };
    this.store = new Ext.data.JsonStore({
      id: 'id',
      root: 'results',
      totalProperty: 'totalCount',
      fields: Tine.Tinebase.Model.Tag,
      baseParams: baseParams
    });
  },

  /**
   * init template
   */
  initTemplate: function initTemplate() {
    this.tpl = new Ext.XTemplate('<tpl for=".">', '<div class="x-combo-list-item">', '<div class="tb-grid-tags" style="background-color:{values.color};">&#160;</div>', '<div class="x-widget-tag-tagitem-text" ext:qtip="', '{[this.encode(values.name)]}', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</i>&nbsp;[{occurrence}]', '<tpl if="description != null && description.length &gt; 1"><hr>{[this.encode(values.description)]}</tpl>" >', '&nbsp;{[this.encode(values.name)]}', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</div>', '</div>', '</tpl>', {
      encode: function encode(value) {
        if (value) {
          return Tine.Tinebase.common.doubleEncode(value);
        } else {
          return '';
        }
      }
    });
  }
});
Ext.reg('Tine.widgets.tags.TagCombo', Tine.widgets.tags.TagCombo);
Tine.widgets.form.RecordPickerManager.register('Tinebase', 'Tag', Tine.widgets.tags.TagCombo);

/***/ }),
/* 1394 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license http://www.gnu.org/licenses/agpl.html AGPL Version 3 
 * @author Alexander Stintzing <alex@stintzing.net>
 * @copyright Copyright (c) 2007-2009
 * Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * TODO use new filter syntax in onBeforeQuery when TagFilter is refactored and
 * extends Tinebase_Model_Filter_FilterGroup
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tags');
/**
 * @namespace Tine.widgets.tags
 * @class Tine.widgets.tags.TagToggleBox
 * @extends Ext.tree.TreePanel
 */

Tine.widgets.tags.TagToggleBox = Ext.extend(Ext.form.FormPanel, {
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog tw-tagtogglebox',
  store: null,
  buttonAlign: 'right',
  win: null,
  mode: null,
  anchor: '100% 100%',
  loadMask: null,
  initComponent: function initComponent() {
    this.addEvents('cancel', 'update', 'close');
    this.initStore();
    this.initTemplate();
    this.initView();
    this.initActions();
    this.initButtons();
    this.items = this.getFormItems();
    Tine.widgets.tags.TagToggleBox.superclass.initComponent.call(this);
  },
  initActions: function initActions() {
    this.action_update = new Ext.Action({
      text: this.mode == 'detach' ? i18n._('Detach Tags') : i18n._('Attach Tags'),
      minWidth: 70,
      scope: this,
      handler: this.onUpdate,
      iconCls: 'action_saveAndClose'
    });
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    });
  },
  initStore: function initStore() {
    this.store = new Ext.data.JsonStore({
      id: 'id',
      root: 'results',
      totalProperty: 'totalCount',
      fields: Tine.Tinebase.Model.Tag,
      baseParams: {
        method: 'Tinebase.searchTagsByForeignFilter',
        filterData: this.selectionModel.getSelectionFilter(),
        filterName: this.recordClass.getMeta('appName') + '_Model_' + this.recordClass.getMeta('modelName') + 'Filter'
      }
    });
    this.store.load();
  },
  initButtons: function initButtons() {
    this.fbar = ['->', this.action_cancel, this.action_update];
  },
  getFormItems: function getFormItems() {
    return {
      border: false,
      frame: true,
      layout: 'form',
      items: [{
        region: 'center',
        layout: {
          align: 'stretch',
          type: 'vbox'
        }
      }, this.view]
    };
  },
  initTemplate: function initTemplate() {
    this.tpl = new Ext.XTemplate('<tpl for=".">', '<div class="x-combo-list-item">', '<input class="tagcheckel" type="checkbox" style="margin-right:5px" id="{values.id}" />' + '<div class="tb-grid-tags" style="margin-top:2px;background-color:{values.color};">&#160;</div>', '<div class="x-widget-tag-tagitem-text" style="margin-top:1px" ext:qtip="', '{[this.encode(values.name)]}', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</i>&nbsp;[{occurrence}]', '<tpl if="description != null && description.length &gt; 1"><hr>{[this.encode(values.description)]}</tpl>" >', '&nbsp;{[this.encode(values.name)]}&nbsp;({values.selection_occurrence})', '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>', '</div>', '</div>', '</tpl>', {
      encode: function encode(value) {
        if (value) {
          return Tine.Tinebase.common.doubleEncode(value);
        } else {
          return '';
        }
      }
    });
  },
  initView: function initView() {
    this.view = new Ext.DataView({
      anchor: '100% 100%',
      autoScroll: true,
      store: this.store,
      tpl: this.tpl,
      emptyText: i18n._('No Tags to detach found in the selected records'),
      loadingText: i18n._('Please Wait...'),
      style: 'background:#fff;'
    });
  },
  onCancel: function onCancel() {
    this.fireEvent('cancel');
  },
  // TODO: formitems could not be fetched by formpanel->getform->getvalues
  onUpdate: function onUpdate() {
    this.loadMask = new Ext.LoadMask(this.getEl(), {
      msg: i18n._('Detaching Tags')
    });
    this.loadMask.show();
    var els = Ext.select('input.tagcheckel');
    var checked = [];
    els.each(function (el) {
      if (el.dom.checked) checked.push(el.id);
    });
    var filter = this.selectionModel.getSelectionFilter();
    var filterModel = this.recordClass.getMeta('appName') + '_Model_' + this.recordClass.getMeta('modelName') + 'Filter';
    Tine.Tinebase.detachTagsFromMultipleRecords(filter, filterModel, checked, this.onUpdated.createDelegate(this));
  },
  onUpdated: function onUpdated() {
    this.loadMask.hide();
    this.fireEvent('updated');
  }
});

/***/ }),
/* 1395 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tags');
/**
 * @namespace   Tine.widgets.tags
 * @class       Tine.widgets.tags.TagFilter
 * @extends     Tine.widgets.grid.PickerFilter
 */

Tine.widgets.tags.TagFilter = Ext.extend(Tine.widgets.grid.PickerFilter, {
  field: 'tag',
  defaultOperator: 'equals',
  operators: ['equals', 'not', 'in', 'notin', 'contains'],

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.picker = Tine.widgets.tags.TagCombo;
    this.recordClass = Tine.Tinebase.Model.Tag;
    Tine.widgets.tags.TagFilter.superclass.initComponent.call(this);
    this.label = i18n._('Tag');
  }
});
Tine.widgets.grid.FilterToolbar.FILTERS['tinebase.tag'] = Tine.widgets.tags.TagFilter;

/***/ }),
/* 1396 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tags');
/**
 * @namespace   Tine.widgets.tags
 * @class       Tine.widgets.tags.TagsMassAttachAction
 * @extends     Ext.Action
 */

Tine.widgets.tags.TagsMassAttachAction = function (config) {
  config.text = config.text ? config.text : i18n._('Add Tags');
  config.iconCls = 'action_tag';
  config.handler = config.handler ? config.handler : this.handleClick.createDelegate(this);
  config.scope = config.scope ? config.scope : this.handleClick.createDelegate(this);
  Ext.apply(this, config);
  this.store = new Ext.data.SimpleStore({
    fields: Tine.Tinebase.Model.Tag
  });
  this.store.on('add', this.manageOkBtn, this);
  this.store.on('remove', this.manageOkBtn, this);
  Tine.widgets.tags.TagsMassAttachAction.superclass.constructor.call(this, config);
};

Ext.extend(Tine.widgets.tags.TagsMassAttachAction, Ext.Action, {
  /**
   * called when tags got updates
   * 
   * @type Function
   */
  updateHandler: Ext.emptyFn,

  /**
   * scope of update handler
   * 
   * @type Object
   */
  updateHandlerScope: null,
  loadMask: null,

  /**
   * @cfg {mixed} selectionModel
   * 
   * selection model (required)
   */
  selectionModel: null,

  /**
   * @cfg {function} recordClass
   * 
   * record class of records to filter for (required)
   */
  recordClass: null,
  getFormItems: function getFormItems() {
    return new Tine.widgets.grid.PickerGridPanel({
      height: 'auto',
      searchComboConfig: {
        app: this.app
      },
      recordClass: Tine.Tinebase.Model.Tag,
      store: this.store,
      labelRenderer: Tine.Tinebase.common.tagRenderer
    });
  },
  manageOkBtn: function manageOkBtn() {
    if (this.win && this.win.okButton) {
      this.win.okButton.setDisabled(!this.store.getCount());
    }
  },
  handleClick: function handleClick() {
    // NOTE: in gridPanels ctxMenu (and so this action) is only created once
    this.store.removeAll();
    this.win = Tine.WindowFactory.getWindow({
      layout: 'fit',
      width: 300,
      height: 300,
      padding: '5px',
      modal: true,
      closeAction: 'hide',
      // mhh not working :-(
      title: i18n._('Select Tags'),
      items: [{
        xtype: 'form',
        buttonAlign: 'right',
        border: false,
        layout: 'fit',
        items: this.getFormItems(),
        buttons: [{
          text: i18n._('Cancel'),
          minWidth: 70,
          scope: this,
          handler: this.onCancel,
          iconCls: 'action_cancel'
        }, {
          text: i18n._('Ok'),
          ref: '../../../okButton',
          disabled: this.store ? !this.store.getCount() : true,
          minWidth: 70,
          scope: this,
          handler: this.onOk,
          iconCls: 'action_saveAndClose'
        }]
      }]
    });
  },
  onCancel: function onCancel() {
    this.win.close();
  },
  onOk: function onOk() {
    var tags = [];
    this.store.each(function (r) {
      tags.push(r.data);
    }, this);

    if (!tags.length) {
      this.win.close();
      return;
    }

    this.loadMask = new Ext.LoadMask(this.win.getEl(), {
      msg: i18n._('Attaching Tag')
    });
    this.loadMask.show();
    var filter = this.selectionModel.getSelectionFilter();
    var filterModel = this.recordClass.getMeta('appName') + '_Model_' + this.recordClass.getMeta('modelName') + 'Filter'; // can't use Ext direct because the timeout is not configurable
    //Tine.Tinebase.attachTagToMultipleRecords(filter, filterModel, tag, this.onSuccess.createDelegate(this));

    Ext.Ajax.request({
      scope: this,
      timeout: 1800000,
      // 30 minutes
      success: this.onSuccess.createDelegate(this),
      params: {
        method: 'Tinebase.attachMultipleTagsToMultipleRecords',
        filterData: filter,
        filterName: filterModel,
        tags: tags
      },
      failure: function failure(response, options) {
        this.loadMask.hide();
        Tine.Tinebase.ExceptionHandler.handleRequestException(response, options);
      }
    });
  },
  onSuccess: function onSuccess() {
    this.updateHandler.call(this.updateHandlerScope || this);
    this.loadMask.hide();
    this.win.close();
  }
});

/***/ }),
/* 1397 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets', 'Tine.widgets.tags');
/**
 * @namespace   Tine.widgets.tags
 * @class       Tine.widgets.tags.TagsMassDetachAction
 * @extends     Ext.Action
 */

Tine.widgets.tags.TagsMassDetachAction = function (config) {
  config.text = config.text ? config.text : i18n._('Detach tag(s)');
  config.iconCls = 'x-widget-tag-action-detach';
  config.handler = this.handleClick.createDelegate(this);
  Ext.apply(this, config);
  Tine.widgets.tags.TagsMassDetachAction.superclass.constructor.call(this, config);
};

Ext.extend(Tine.widgets.tags.TagsMassDetachAction, Ext.Action, {
  /**
   * called when tags got updates
   * 
   * @type Function
   */
  updateHandler: Ext.emptyFn,

  /**
   * scope of update handler
   * 
   * @type Object
   */
  updateHandlerScope: null,

  /**
   * @cfg {mixed} selectionModel
   * 
   * selection model (required)
   */
  selectionModel: null,

  /**
   * @cfg {function} recordClass
   * 
   * record class of records to filter for (required)
   */
  recordClass: null,
  formPanel: null,
  initFormPanel: function initFormPanel() {
    this.formPanel = new Tine.widgets.tags.TagToggleBox({
      selectionModel: this.selectionModel,
      recordClass: this.recordClass,
      callingAction: this,
      mode: 'detach'
    });
    this.formPanel.on('cancel', function () {
      this.purgeListeners();
      this.win.close();
    });
    this.formPanel.on('updated', function () {
      this.callingAction.onSuccess();
    });
  },
  handleClick: function handleClick() {
    this.initFormPanel();
    this.win = Tine.WindowFactory.getWindow({
      layout: 'fit',
      width: 300,
      height: 150,
      modal: true,
      title: i18n._('Select Tag(s) to detach'),
      items: this.formPanel
    });
    this.formPanel.win = this.win;
  },
  onSuccess: function onSuccess() {
    this.updateHandler.call(this.updateHandlerScope || this);
    this.win.close();
  }
});

/***/ }),
/* 1398 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2013 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.mainscreen');
/**
 * @namespace   Tine.widgets.mainscreen
 * @class       Tine.widgets.mainscreen.WestPanel
 * @extends     Ext.ux.Portal
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * 
 * @todo make save button working again -> move to here
 * 
 * @constructor
 * @xtype       tine.widgets.mainscreen.westpanel
 */

Tine.widgets.mainscreen.WestPanel = function (config) {
  Ext.apply(this, config);
  this.defaults = {};
  Tine.widgets.mainscreen.WestPanel.superclass.constructor.apply(this, arguments);
};

Ext.extend(Tine.widgets.mainscreen.WestPanel, Ext.ux.Portal, {
  /**
   * @cfg {Array} contentTypes
   * Array of Objects
   * Object Properties: "model", "requiredRight"
   * Prop. model (e.g. "Abc") will be expanded to Tine.Application.Model.Abc
   * Prop. requiredRight (e.g. "read") will be expanded to Tine.Tinebase.common.hasRight('read', this.app.appName, recordClass.getMeta('recordsName').toLowerCase())
   * Prop. singularContainerMode (bool): when true, the records of the model doesn't have containers, so no containertreepanel is rendered
   *                                     but a containertreenode must be defined in Application.js
   * Prop. genericCtxActions (Array of Strings e.g. "['rename','grant']") Creates a Tine.widgets.tree.ContextMenu with the actions in this array                                    
   */
  contentTypes: null,

  /**
   * @cfg {String} contentType
   * defines the contentType (e.g. Xyz), which will be expanded to Tine.Application.Model.Xyz, this panel controls 
   */
  contentType: null,

  /**
   * @cfg {String} containerTreeClass
   * name of container tree class in namespace of this app (defaults to TreePanel)
   * the class name will be expanded to Tine[this.appName][this.containerTreePanelClassName]
   */
  containerTreePanelClassName: 'TreePanel',

  /**
   * @cfg {String} favoritesPanelClassName
   * name of favorites class in namespace of this app (defaults to FilterPanel)
   * the class name will be expanded to Tine[this.appName][this.favoritesPanelClassName]
   */
  favoritesPanelClassName: 'FilterPanel',

  /**
   * @cfg {Bool} hasContainerTreePanel
   * west panel has containerTreePanel (defaults to null -> autodetection)
   */
  hasContainerTreePanel: null,

  /**
   * @cfg {Boolean} defaultCollapseContainerTree
   */
  defaultCollapseContainerTree: false,

  /**
   * @cfg {Bool} hasFavoritesPanel
   * west panel has favorites panel (defaults to null -> autodetection)
   */
  hasFavoritesPanel: null,

  /**
   * @cfg {object} NodeGridPanel
   * needs for filterToolBar in EditDialog
   */
  gridPanel: null,
  layout: 'column',
  cls: 'x-portal',
  defaultType: 'portalcolumn',
  autoHeight: true,
  border: false,
  stateful: true,
  stateEvents: ['collapse', 'expand', 'drop'],

  /**
   * inits this west panel
   */
  initComponent: function initComponent() {
    this.recordClass = Tine.Tinebase.data.RecordMgr.get(this.recordClass);

    if (!this.app && this.recordClass) {
      this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
    }

    this.stateId = this.app.appName + this.getContentType() + '-mainscreen-westpanel';
    this.canonicalName = this.canonicalName ? this.canonicalName : this.getContentType();
    var fpcn = this.getContentType() + this.favoritesPanelClassName;
    this.hasFavoritesPanel = Ext.isBoolean(this.hasFavoritesPanel) ? this.hasFavoritesPanel : !!Tine[this.app.appName][fpcn];

    if (this.hasContainerTreePanel === null) {
      this.hasContainerTreePanel = true;

      if (this.contentTypes) {
        var def = Tine.widgets.MainScreen.prototype.getContentTypeDefinition.call(this, this.contentType);

        if (def && def.singularContainerMode) {
          this.hasContainerTreePanel = false;
        }
      }
    }

    this.items = this.getPortalColumn();
    Tine.widgets.mainscreen.WestPanel.superclass.initComponent.apply(this, arguments);
  },

  /**
   * called after rendering process
   */
  afterRender: function afterRender() {
    Tine.widgets.mainscreen.WestPanel.superclass.afterRender.apply(this, arguments);
    this.getPortalColumn().items.each(function (item, idx) {
      // kill x-scrollers
      if (item.getEl && item.getEl()) {
        this.xScrollKiller(item);
      } else {
        item.on('afterrender', this.xScrollKiller, this);
      } //bubble state events
      // fire selectionchange event of all items as westPanel events


      item.enableBubble(['collapse', 'expand', 'selectionchange']);
    }, this);
  },

  /**
   * initializes the stateif no state is saved
   * overwrites the Ext.Component initState method
   */
  initState: function initState() {
    var state = Ext.state.Manager.get(this.stateId) ? Ext.state.Manager.get(this.stateId) : this.getState();

    if (this.fireEvent('beforestaterestore', this, state) !== false) {
      this.applyState(Ext.apply({}, state));
      this.fireEvent('staterestore', this, state);
    }
  },

  /**
   * applies state to cmp
   * 
   * @param {Object} state
   */
  applyState: function applyState(state) {
    var collection = this.getPortalColumn().items,
        c = new Array(collection.getCount()),
        k = collection.keys,
        items = collection.items; // do not apply broken state

    if (_.filter(state.order, function (v) {
      return _.isNumber(v) && !_.isNaN(v);
    }).length < items.length || _.uniq(state.order).length !== _.concat(state.order)) {
      return;
    }

    Ext.each(state.order, function (position, idx) {
      c[idx] = {
        key: k[position],
        value: items[position],
        index: position
      };
    }, this);

    for (var i = 0, len = collection.length; i < len; i++) {
      if (c[i] && c[i].value) {
        items[i] = c[i].value;
        k[i] = c[i].key;
      }
    }

    collection.fireEvent('sort', collection);
    collection.each(function (item, idx) {
      if (!item || typeof item.addFill === 'function') return;

      if (item.getEl()) {
        item[state.collapsed[idx] ? 'collapse' : 'expand'](false);
      } else {
        item.collapsed = !!state.collapsed[idx];
      }
    }, this);
  },

  /**
   * returns additional items for the westpanel
   * template fn to be overrwiten by subclasses
   * 
   * @return {Array} of Ext.Panel
   */
  getAdditionalItems: function getAdditionalItems() {
    return this.additionalItems || [];
  },
  getContentType: function getContentType() {
    return this.contentType ? this.contentType : '';
  },

  /**
   * returns containerTree panel
   * 
   * @return {Tine.Tinebase.widgets.ContainerTreePanel}
   */
  getContainerTreePanel: function getContainerTreePanel(contentType) {
    contentType = contentType || this.app.getMainScreen().getActiveContentType();
    const panelName = contentType + 'TreePanel';

    if (!this[panelName]) {
      if (Tine[this.app.appName].hasOwnProperty(panelName)) {
        this[panelName] = new Tine[this.app.appName][panelName]({
          app: this.app,
          grid: this.gridPanel
        });
      } else {
        this[panelName] = new Tine.widgets.persistentfilter.PickerPanel({
          app: this.app,
          contentType: contentType,
          grid: this.gridPanel
        });
      }

      this[panelName].on('click', function (node, event) {
        // no scope here -> this means containerTree
        if (node != this.lastClickedNode) {
          this.lastClickedNode = node;
          this.fireEvent('selectionchange');
        }
      });
    }

    return this[panelName];
  },

  /**
   * returns favorites panel
   * 
   * @return {Ext.Panel}
   */
  getFavoritesPanel: function getFavoritesPanel() {
    var ct = this.app.getMainScreen().getActiveContentType(),
        panelName = window.lodash.upperFirst(ct + 'FilterPanel');

    try {
      if (!this[panelName]) {
        var fpConfig = {
          rootVisible: false,
          border: false,
          collapsible: true,
          root: null,
          titleCollapse: true,
          title: '',
          baseCls: 'ux-arrowcollapse',
          app: this.app,
          contentType: ct,
          recordClass: this.recordClass,
          // needs for filterToolBar in EditDialog
          grid: this.gridPanel,
          style: {
            width: '100%',
            overflow: 'hidden'
          },
          treePanel: this.hasContainerTreePanel ? this.getContainerTreePanel() : null,
          listeners: {
            scope: this,
            click: function click(node, event) {
              // this is westPanel
              // fire westpanel event on favorite change
              if (node != this.lastClickedNode) {
                this.lastClickedNode = node;
                this.fireEvent('selectionchange');
              }
            }
          }
        };

        if (Tine[this.app.name].hasOwnProperty(panelName)) {
          this[panelName] = new Tine[this.app.appName][panelName](fpConfig);
        } else {
          this[panelName] = new Tine.widgets.persistentfilter.PickerPanel(fpConfig);
        }
      }
    } catch (e) {
      Tine.log.info('No Favorites Panel created');
    }

    return this[panelName];
  },

  /**
   * returns filter plugin of west panel for given content type
   * 
   * @param {String} contentType
   * @return {Tine.widgets.grid.FilterPlugin}
   */
  getFilterPlugin: function getFilterPlugin(contentType) {
    if (this.hasContainerTreePanel) {
      const ctp = this.getContainerTreePanel(contentType);

      if (ctp.getFilterPlugin) {
        return ctp.getFilterPlugin();
      }
    }

    return new Tine.widgets.grid.FilterPlugin({
      getValue: function getValue() {
        return [];
      }
    });
  },

  /**
   * returns the one and only portalcolumn of this west panel
   * 
   * @return {Ext.ux.PortalColumn}
   */
  getPortalColumn: function getPortalColumn() {
    if (!this.portalColumn) {
      var items = [];

      if (this.hasContainerTreePanel) {
        var containerTreePanel = this.getContainerTreePanel();
        var containersName = containerTreePanel.recordClass ? containerTreePanel.recordClass.getContainersName() : i18n._('containers'); // recheck if container tree is a container tree as in apps not dealing
        // with containers we don't want a collapsed arrow header

        var isContainerTreePanel = typeof containerTreePanel.selectContainerPath === 'function';

        if (isContainerTreePanel) {
          this.defaults = {
            collapsible: true,
            baseCls: 'ux-arrowcollapse',
            animCollapse: true,
            titleCollapse: true,
            draggable: true,
            autoScroll: false
          };
        }

        items.push(Ext.apply(this.getContainerTreePanel(), {
          title: isContainerTreePanel ? containersName : false,
          collapsed: isContainerTreePanel && this.defaultCollapseContainerTree
        }, this.defaults));
      }

      if (this.hasFavoritesPanel) {
        // favorites panel
        items.unshift(Ext.apply(this.getFavoritesPanel(), {
          title: i18n._('Favorites')
        }, this.defaults));
      }

      items = items.concat(this.getAdditionalItems()); // save original/programatical position
      // NOTE: this has to be done before applyState!

      if (items.length) {
        Ext.each(items, function (item, idx) {
          item.startPosition = idx;
        }, this);
      }

      this.portalColumn = new Ext.ux.PortalColumn({
        columnWidth: 1,
        items: items
      });
      this.portalColumn.on('resize', function (cmp, width) {
        this.portalColumn.items.each(function (item) {
          item.setWidth(width);
        }, this);
      }, this);
    }

    return this.portalColumn;
  },

  /**
   * gets state of this cmp
   */
  getState: function getState() {
    var state = {
      order: [],
      collapsed: []
    };
    this.getPortalColumn().items.each(function (item, idx) {
      state.order.push(item.startPosition);
      state.collapsed.push(!!item.collapsed);
    }, this);
    return state;
  },

  /**
   * kill x scrollers of given component
   * 
   * @param {Ext.Component} cmp
   */
  xScrollKiller: function xScrollKiller(cmp) {
    var panelEls = cmp.getEl().child('div[class^=' + this.defaults.baseCls + '-body]');

    if (panelEls) {
      panelEls.applyStyles('overflow-x: hidden'); // IE 11 dosn't respect the style :-(

      panelEls.on('scroll', function (e) {
        panelEls.dom.scrollLeft = 0;
      });
    }
  }
});
Ext.reg('tine.widgets.mainscreen.westpanel', Tine.widgets.mainscreen.WestPanel);

/***/ }),
/* 1399 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase');
/**
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.LicenseScreen
 * @extends     Ext.Window
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @param {Object} config The configuration options.
 */

Tine.Tinebase.LicenseScreen = Ext.extend(Ext.Window, {
  closeAction: 'close',
  modal: true,
  width: 400,
  height: 360,
  minWidth: 400,
  minHeight: 360,
  layout: 'fit',
  title: null,

  /**
   * init component
   */
  initComponent: function initComponent() {
    this.title = i18n._('License');
    this.items = {
      layout: 'fit',
      border: false,
      padding: 10,
      autoScroll: true,
      autoLoad: {
        url: 'LICENSE',
        isUpload: true,
        method: 'GET',
        callback: function callback(el, s, response) {
          el.update(Ext.util.Format.nl2br(response.responseText));
        }
      },
      buttons: [{
        text: i18n._('Ok'),
        iconCls: 'action_saveAndClose',
        handler: this.close,
        scope: this
      }]
    };
    Tine.Tinebase.LicenseScreen.superclass.initComponent.call(this);
  }
});

/***/ }),
/* 1400 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * @copyright   Copyright (c) 2007-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase');
/**
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.CreditsScreen
 * @extends     Ext.Window
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 * 
 * @param {Object} config The configuration options.
 */

Tine.Tinebase.CreditsScreen = Ext.extend(Ext.Window, {
  closeAction: 'close',
  modal: true,
  width: 400,
  height: 360,
  minWidth: 400,
  minHeight: 360,
  layout: 'fit',
  title: null,

  /**
   * init component
   */
  initComponent: function initComponent() {
    this.title = i18n._('Credits');
    this.items = {
      layout: 'fit',
      border: false,
      padding: 10,
      autoScroll: true,
      autoLoad: {
        url: 'CREDITS',
        isUpload: true,
        method: 'GET',
        callback: function callback(el, s, response) {
          el.update(Ext.util.Format.nl2br(response.responseText));
        }
      },
      buttons: [{
        text: i18n._('Ok'),
        iconCls: 'action_saveAndClose',
        handler: this.close,
        scope: this
      }]
    };
    Tine.Tinebase.CreditsScreen.superclass.initComponent.call(this);
  }
});

/***/ }),
/* 1401 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets');
/**
 * Widget for country selection
 *
 * @namespace   Tine.widgets
 * @class       Tine.widgets.CountryCombo
 * @extends     Ext.form.ComboBox
 */

Tine.widgets.CountryCombo = Ext.extend(Ext.form.ComboBox, {
  fieldLabel: 'Country',
  displayField: 'translatedName',
  valueField: 'shortName',
  typeAhead: true,
  forceSelection: true,
  mode: 'local',
  triggerAction: 'all',
  selectOnFocus: true,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.store = this.getCountryStore();
    this.emptyText = i18n._('Select a country...');
    Tine.widgets.CountryCombo.superclass.initComponent.call(this);
  },

  /**
   * @private store has static content
   */
  getCountryStore: function getCountryStore() {
    var store = Ext.StoreMgr.get('Countries');

    if (!store) {
      store = new Ext.data.JsonStore({
        baseParams: {
          method: 'Tinebase.getCountryList'
        },
        root: 'results',
        id: 'shortName',
        fields: ['shortName', 'translatedName'],
        remoteSort: false,
        sortInfo: {
          field: 'translatedName',
          direction: 'ASC'
        }
      });
      Ext.StoreMgr.add('Countries', store);
    }

    var countryList = Locale.getTranslationList('CountryList');

    if (countryList) {
      var storeData = {
        results: []
      };

      for (var shortName in countryList) {
        storeData.results.push({
          shortName: shortName,
          translatedName: countryList[shortName]
        });
      }

      store.loadData(storeData);
    }

    return store;
  }
});
Ext.reg('widget-countrycombo', Tine.widgets.CountryCombo);

/***/ }),
/* 1402 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @author      Michael Spahn <m.spahn@metaways.de
 * @copyright   Copyright (c) 2007-2014 Metaways Infosystems GmbH (http://www.metaways.de)
 **/

/*global Ext, Tine, Locale*/
Ext.ns('Tine.widgets', 'Tine.widgets.activities');
/************************* tab panel *********************************/

/**
 * Class for a activities tab with notes/activities grid*
 * 
 * @namespace   Tine.widgets.activities
 * @class       Tine.widgets.activities.ActivitiesTabPanel
 * @extends     Ext.Panel
 */

Tine.widgets.activities.ActivitiesTabPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {String} app Application which uses this panel
   */
  app: '',

  /**
   * @var {Ext.data.JsonStore}
   * Holds activities of the record this panel is displayed for
   */
  store: null,

  /**
   * the translation object
   */
  translation: null,

  /**
   * @cfg {Object} paging defaults
   */
  paging: {
    start: 0,
    limit: 20,
    sort: 'creation_time',
    dir: 'DESC'
  },

  /**
   * the record id
   */
  record_id: null,

  /**
   * the record model
   */
  record_model: null,

  /**
   * @cfg {Number} pos
   * position 500 = 100 + 100*4 -> means fourth one after app specific tabs
   */
  pos: 500,

  /**
   * other config options
   */
  title: null,
  layout: 'fit',
  canonicalName: 'HistoryGrid',
  border: false,
  getActivitiesGrid: function getActivitiesGrid() {
    // @todo add row expander on select ?
    // @todo add context menu ?
    // @todo add buttons ?        
    // @todo add more renderers ?
    // the columnmodel
    var columnModel = new Ext.grid.ColumnModel([{
      resizable: true,
      id: 'note_type_id',
      header: this.translation.gettext('Type'),
      dataIndex: 'note_type_id',
      width: 15,
      renderer: Tine.widgets.activities.getTypeIcon
    }, {
      resizable: true,
      id: 'note',
      header: this.translation.gettext('Note'),
      dataIndex: 'note',
      renderer: this.noteRenderer.createDelegate(this)
    }, {
      resizable: true,
      id: 'created_by',
      header: this.translation.gettext('Created By'),
      dataIndex: 'created_by',
      width: 70
    }, {
      resizable: true,
      id: 'creation_time',
      header: this.translation.gettext('Timestamp'),
      dataIndex: 'creation_time',
      width: 50,
      renderer: Tine.Tinebase.common.dateTimeRenderer
    }]);
    columnModel.defaultSortable = true; // by default columns are sortable
    // the rowselection model

    var rowSelectionModel = new Ext.grid.RowSelectionModel({
      multiSelect: true
    }); // the paging toolbar

    var pagingToolbar = new Ext.PagingToolbar({
      pageSize: parseInt(Tine.Tinebase.registry.get('preferences').get('pageSize'), 10) || 50,
      store: this.store,
      displayInfo: true,
      displayMsg: this.translation.gettext('Displaying history records {0} - {1} of {2}'),
      emptyMsg: this.translation.gettext("No history to display")
    }); // the gridpanel

    var gridPanel = new Ext.grid.GridPanel({
      cls: 'tw-activities-grid',
      store: this.store,
      cm: columnModel,
      tbar: pagingToolbar,
      selModel: rowSelectionModel,
      border: false,
      //autoExpandColumn: 'note',
      //enableColLock:false,
      //autoHeight: true,
      viewConfig: {
        autoFill: true,
        forceFit: true,
        ignoreAdd: true,
        autoScroll: true
      }
    });
    return gridPanel;
  },
  noteRenderer: function noteRenderer(note) {
    var editDialog = this.findParentBy(function (c) {
      return !!c.record;
    }),
        record = editDialog ? editDialog.record : {},
        recordClass = Tine.Tinebase.data.RecordMgr.get(this.record_model) || Tine.Tinebase.data.RecordMgr.get(this.app + '_Model_' + this.record_model),
        appName = recordClass.getMeta('appName'),
        app = Tine.Tinebase.appMgr.get(appName),
        i18n = app ? app.i18n : window.i18n;
    note = Ext.util.Format.htmlEncode(note);
    note = note.replace(/( +[^ ]+ \(.*? -&gt; [^)]*)\)/g, '<br> \u00A0\u2022\u00A0 $&');

    if (recordClass) {
      Ext.each(recordClass.getFieldDefinitions(), function (field) {
        var _ = window.lodash,
            i18nLabel = field.label ? i18n._hidden(field.label) : field.name,
            regexp = new RegExp(' (' + _.escapeRegExp(field.name) + '|' + _.escapeRegExp(i18nLabel) + ') \\((.*?) (-&gt;) ([^)]*)\\)'),
            struct = regexp.exec(note),
            label = struct && struct.length == 5 ? struct[1] : null,
            oldValue = label ? struct[2] : null,
            newValue = label ? struct[4] : null,
            renderer = Tine.widgets.grid.RendererManager.get(appName, recordClass, field.name, Tine.widgets.grid.RendererManager.CATEGORY_GRIDPANEL);

        if (label) {
          var oldValue = renderer(oldValue, {}, record),
              newValue = renderer(newValue, {}, record);
          note = note.replace(regexp, i18nLabel + ' (' + oldValue + ' \u27bd ' + newValue + ')');
        } else {
          // alternative form
          regexp = new RegExp(' (' + _.escapeRegExp(field.name) + '|' + _.escapeRegExp(i18nLabel) + ') \\((.*)\\)');
          struct = regexp.exec(note);
          label = struct && struct.length == 3 ? struct[1] : null;
          var value = label ? struct[2] : null;
          note = note.replace(regexp, '<br> \u00A0\u2022\u00A0 ' + i18nLabel + ' (' + value + ')');
        }
      }, this);
    }

    return note;
  },

  /**
   * init the contacts json grid store
   */
  initStore: function initStore() {
    this.store = new Ext.data.JsonStore({
      id: 'id',
      autoLoad: false,
      root: 'results',
      totalProperty: 'totalcount',
      fields: Tine.Tinebase.Model.Note,
      remoteSort: true,
      baseParams: {
        method: 'Tinebase.searchNotes'
      },
      sortInfo: {
        field: this.paging.sort,
        direction: this.paging.dir
      }
    }); // register store

    Ext.StoreMgr.add('NotesGridStore', this.store); // prepare filter

    this.store.on('beforeload', function (store, options) {
      if (!options.params) {
        options.params = {};
      }

      this.paging.limit = parseInt(Tine.Tinebase.registry.get('preferences').get('pageSize'), 10); // paging toolbar only works with this properties in the options!

      options.params.sort = store.getSortState() ? store.getSortState().field : this.paging.sort;
      options.params.dir = store.getSortState() ? store.getSortState().direction : this.paging.dir;
      options.params.start = options.params.start ? options.params.start : this.paging.start;
      options.params.limit = options.params.limit ? options.params.limit : this.paging.limit;
      options.params.paging = Ext.copyTo({}, options.params, 'sort,dir,start,limit');
      var filterToolbar = Ext.getCmp('activitiesFilterToolbar'),
          filter = filterToolbar ? filterToolbar.getValue() : [],
          // sanitize model name, we need APP_Model_MODELNAME here
      model = this.record_model.match(/_Model_/) ? this.record_model : this.app + '_Model_' + this.record_model;
      filter.push({
        field: 'record_model',
        operator: 'equals',
        value: model
      }, {
        field: 'record_id',
        operator: 'equals',
        value: this.getRecordId()
      }, {
        field: 'record_backend',
        operator: 'equals',
        value: 'Sql'
      });
      options.params.filter = filter;
    }, this); // add new notes from notes store

    this.store.on('load', function (store, operation) {
      var notesStore = Ext.StoreMgr.lookup('NotesStore');

      if (notesStore) {
        notesStore.each(function (note) {
          if (!note.data.creation_time) {
            store.insert(0, note);
          }
        });
      }
    }, this);
  },

  /**
   * @public
   *
   * @returns {string}
   */
  getRecordId: function getRecordId() {
    return this.record_id ? this.record_id : 0;
  },

  /**
   * @private
   */
  initComponent: function initComponent() {
    // get translations
    this.translation = new Locale.Gettext();
    this.translation.textdomain('Tinebase'); // translate / update title

    this.title = this.translation.gettext('History'); // get store

    this.initStore(); // get grid

    this.activitiesGrid = this.getActivitiesGrid(); // the filter toolbar

    var filterToolbar = new Tine.widgets.grid.FilterToolbar({
      id: 'activitiesFilterToolbar',
      filterModels: [{
        label: i18n._('Quick Search'),
        field: 'query',
        operators: ['contains']
      }, //{label: this.translation._('Time'), field: 'creation_time', operators: ['contains']}
      {
        label: this.translation.gettext('Time'),
        field: 'creation_time',
        valueType: 'date',
        pastOnly: true
      } // user search is note working yet -> see NoteFilter.php
      //{label: this.translation._('User'), field: 'created_by', defaultOperator: 'contains'},
      // type search isn't implemented yet
      //{label: this.translation._('Type'), field: 'note_type_id', defaultOperator: 'contains'}
      ],
      defaultFilter: 'query',
      filters: []
    });
    filterToolbar.on('change', function () {
      this.store.load({});
    }, this);
    this.items = [new Ext.Panel({
      layout: 'border',
      border: false,
      items: [{
        region: 'center',
        xtype: 'panel',
        layout: 'fit',
        border: false,
        items: this.activitiesGrid
      }, {
        region: 'north',
        border: false,
        items: filterToolbar,
        listeners: {
          scope: this,
          afterlayout: function afterlayout(ct) {
            ct.suspendEvents();
            ct.setHeight(filterToolbar.getHeight());
            ct.ownerCt.layout.layout();
            ct.resumeEvents();
          }
        }
      }]
    })]; // load store on activate

    this.on('activate', function (panel) {
      panel.store.load({});
    }); // no support for multiple edit

    Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.registerSkipItem(this);
    Tine.widgets.activities.ActivitiesTabPanel.superclass.initComponent.call(this);
  }
});
Ext.reg('tineactivitiestabpanel', Tine.widgets.activities.ActivitiesTabPanel);
/************************* helper *********************************/

/**
 * get note / activities types store
 * if available, load data from initial data
 *
 * @return Ext.data.JsonStore with activities types
 *
 * @todo translate type names / descriptions
 */

Tine.widgets.activities.getTypesStore = function () {
  var store = Ext.StoreMgr.get('noteTypesStore');

  if (!store) {
    store = new Ext.data.JsonStore({
      fields: Tine.Tinebase.Model.NoteType,
      baseParams: {
        method: 'Tinebase.getNoteTypes'
      },
      root: 'results',
      totalProperty: 'totalcount',
      id: 'id',
      remoteSort: false
    });
    /*if (Tine.Tinebase.registry.get('NoteTypes')) {
        store.loadData(Tine.Tinebase.registry.get('NoteTypes'));
    } else*/

    if (Tine.Tinebase.registry.get('NoteTypes')) {
      store.loadData(Tine.Tinebase.registry.get('NoteTypes'));
    }

    Ext.StoreMgr.add('noteTypesStore', store);
  }

  return store;
};
/**
 * get type icon
 *
 * @param   id of the note type record
 * @returns img tag with icon source
 *
 * @todo use icon_class here
 */


Tine.widgets.activities.getTypeIcon = function (id) {
  var typesStore = Tine.widgets.activities.getTypesStore();
  var typeRecord = typesStore.getById(id);

  if (typeRecord) {
    return '<img src="' + typeRecord.data.icon + '" ext:qtip="' + Tine.Tinebase.common.doubleEncode(typeRecord.data.description) + '" style="height:16px;width:16px" />';
  } else {
    return '';
  }
};

/***/ }),
/* 1403 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2014 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.activities');
/**
 * @namespace   Tine.widgets.activities
 * @class       Tine.widgets.activities.ActivitiesGridPanel
 * @extends     Ext.grid.GridPanel
 * @author      Michael Spahn <m.spahn@metaways.de>
 */

Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
  /**
   * The calling EditDialog
   * @type Tine.widgets.activities.EditDialog
   */
  editDialog: null,

  /**
   * title
   *
   * @type String
   */
  title: null,

  /**
   * the record
   * @type Record
   */
  record: null,

  /**
   * @type Tinebase.Application
   */
  app: null,

  /**
   * @cfg {String} requiredGrant to make actions
   */
  requiredGrant: 'editGrant',

  /**
   * @cfg {Number} pos
   * position 200 = 100 + 100*1 -> means first one after app specific tabs
   */
  pos: 200,

  /* config */
  frame: true,
  border: true,
  autoScroll: true,
  layout: 'fit',
  canonicalName: 'NotesGrid',
  store: null,
  viewConfig: {},

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    this.record = this.editDialog.record;
    this.app = this.editDialog.app;
    this.title = this.i18nTitle = i18n._('Notes'); // init actions

    this.actionUpdater = new Tine.widgets.ActionUpdater({
      evalGrants: false
    });
    this.initToolbarAndContextMenu();
    this.initStore();
    this.initColumnModel();
    this.initSelectionModel(); //Tine.widgets.dialog.MultipleEditDialogPlugin.prototype.registerSkipItem(this);

    this.editDialog.on('load', this.onLoadRecord, this);
    this.editDialog.on('recordUpdate', this.onRecordUpdate, this);
    Tine.widgets.activities.ActivitiesGridPanel.superclass.initComponent.call(this);
    this.on('rowcontextmenu', function (grid, row, e) {
      e.stopEvent();
      var selModel = grid.getSelectionModel();

      if (!selModel.isSelected(row)) {
        selModel.selectRow(row);
      }

      this.contextMenu.showAt(e.getXY());
    }, this);
  },

  /**
   * get columns
   * @return Array
   */
  getColumns: function getColumns() {
    var columns = [{
      id: 'note_type_id',
      header: i18n._('Type'),
      dataIndex: 'note_type_id',
      renderer: Tine.widgets.activities.getTypeIcon,
      width: 30
    }, {
      id: 'note',
      dataIndex: 'note',
      width: 500,
      header: i18n._('Note'),
      sortable: true,
      renderer: this.renderMultipleLines
    }, {
      id: 'created_by',
      header: i18n._('Created By'),
      dataIndex: 'created_by'
    }, {
      id: 'creation_time',
      header: i18n._('Creation time'),
      dataIndex: 'creation_time',
      width: 120,
      renderer: Tine.Tinebase.common.dateTimeRenderer
    }];
    return columns;
  },

  /**
   * There is no option to display multiple lines in extjs 3.* this renderer replaces newlines with html breaks
   *
   * @param value
   * @returns {string}
   */
  renderMultipleLines: function renderMultipleLines(value) {
    return '<div style="white-space:normal !important;">' + Ext.util.Format.nl2br(Ext.util.Format.htmlEncode(value)) + '</div>';
  },

  /**
   * Setup column model for grid
   */
  initColumnModel: function initColumnModel() {
    this.cm = new Ext.grid.ColumnModel(this.getColumns());
    this.cm.defaultSortable = true; // by default columns are sortable
  },

  /**
   * init store
   * @private
   */
  initStore: function initStore() {
    this.store = new Ext.data.SimpleStore({
      fields: Tine.Tinebase.Model.Note
    });
  },

  /**
   * updates the title ot the tab
   * @param {Integer} count
   */
  updateTitle: function updateTitle(count) {
    count = Ext.isNumber(count) ? count : this.store.getCount();
    this.setTitle(this.i18nTitle + ' (' + count + ')');
  },

  /**
   * is called from onApplyChanges of the edit dialog per save event
   *
   * @param {Tine.widgets.dialog.EditDialog} dialog
   * @param {Tine.Tinebase.data.Record} record
   * @return {Boolean}
   */
  onRecordUpdate: function onRecordUpdate(dialog, record) {
    if (record.data.hasOwnProperty('notes')) {
      Tine.Tinebase.common.assertComparable(record.data.notes);
    }

    record.set('notes', Tine.Tinebase.common.assertComparable(this.getData()));
  },

  /**
   * populate store
   *
   * @param {EditDialog} editDialog
   * @param {Record} record
   * @param {Function} ticketFn
   */
  onLoadRecord: function onLoadRecord(editDialog, record, ticketFn) {
    var _ = window.lodash,
        interceptor = ticketFn(),
        notes = record.get('notes'),
        evalGrants = editDialog.evalGrants,
        hasRequiredGrant = !evalGrants || _.get(record, record.constructor.getMeta('grantsPath') + '.' + this.requiredGrant);

    this.store.purgeListeners();
    this.store.removeAll();

    if (notes && notes.length > 0) {
      this.updateTitle(notes.length);
      var notesRecords = [];
      Ext.each(notes, function (notes) {
        notesRecords.push(new Tine.Tinebase.Model.Tree_Node(notes, notes.id));
      }, this);
      this.store.add(notesRecords);
    } else {
      this.updateTitle(0);
    } // add other listeners after population


    if (this.store) {
      this.store.on('update', this.updateTitle, this);
      this.store.on('add', this.updateTitle, this);
      this.store.on('remove', this.updateTitle, this);
    }

    interceptor();
    this.setReadOnly(!hasRequiredGrant);
  },
  setReadOnly: function setReadOnly(readOnly) {
    this.readOnly = readOnly;
    this.action_add.setDisabled(readOnly);
    this.action_remove.setDisabled(readOnly);
  },

  /**
   * init sel model
   * @private
   */
  initSelectionModel: function initSelectionModel() {
    this.selModel = new Ext.grid.RowSelectionModel({
      multiSelect: true
    });
    this.selModel.on('selectionchange', function (selModel) {
      var rowCount = selModel.getCount();
      this.actionUpdater.updateActions(selModel);
      this.action_remove.setDisabled(this.readOnly); // The tine server can't handle edits for notes at the moment
      // @todo make this work
      //this.action_edit.setDisabled(this.readOnly);
    }, this);
  },

  /**
   * init toolbar and context menu
   * @private
   */
  initToolbarAndContextMenu: function initToolbarAndContextMenu() {
    this.action_add = new Ext.Action({
      text: String.format(i18n._('Add {0}'), this.i18nTitle),
      iconCls: 'action_add',
      scope: this,
      handler: this.addNote
    });
    this.action_edit = new Ext.Action({
      text: String.format(i18n._('Edit {0}'), this.i18nTitle),
      iconCls: 'action_edit',
      scope: this,
      disabled: true,
      visible: false,
      handler: this.addNote
    });
    this.action_remove = new Ext.Action({
      text: String.format(i18n._('Remove {0}'), this.i18nTitle),
      iconCls: 'action_remove',
      scope: this,
      disabled: true,
      handler: this.removeNote
    }); //@todo make tine edit notes if client sents modified data

    this.tbar = [this.action_add, //this.action_edit,
    this.action_remove]; //@todo make tine edit notes if client sents modified data

    this.contextMenu = new Ext.menu.Menu({
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-MainContextMenu'
      }],
      items: [//this.action_edit,
      this.action_remove]
    });
  },

  /**
   * Handler: Remove every selected note, 1 or more
   * @param sel
   */
  removeNote: function removeNote(sel) {
    Ext.each(this.getSelectionModel().getSelections(), function (record) {
      this.store.remove(this.store.getById(record.id));
    });
  },

  /**
   * Handler: Opens a dialog and for note creation and saves to store
   * @param action
   * @param event
   */
  addNote: function addNote(button, event) {
    var typesStore = Tine.widgets.activities.getTypesStore();
    var data = []; // if is edit

    var selectedRecord = this.getSelectionModel().getSelected();

    if (selectedRecord && button.iconCls == 'action_edit') {
      var typeId = selectedRecord.get('type_id');
      var note = selectedRecord.get('note');
      var recordId = selectedRecord.id;
    }

    typesStore.each(function (record) {
      if (record.data.is_user_type == 1) {
        data.push({
          'type_id': record.data.id,
          'name': record.data.name
        });
      }
    }, this);
    this.filteredTypeStore = new Ext.data.JsonStore({
      fields: ['type_id', 'name'],
      data: data,
      idIndex: 0
    });
    this.typeComboBox = new Ext.form.ComboBox({
      store: this.filteredTypeStore,
      valueField: 'type_id',
      mode: 'local',
      displayField: 'name',
      fieldLabel: i18n._('Type'),
      forceSelection: true,
      allowBlank: false,
      editable: false,
      anchor: '100% 100%'
    });
    this.typeComboBox.setValue(typeId || 1);

    this.onClose = function () {
      this.window.close();
    };

    this.onCancel = function () {
      this.onClose();
    };

    this.onOk = function () {
      if (this.formPanel.getForm().findField('notification').validate()) {
        var text = this.formPanel.getForm().findField('notification').getValue();
        this.onNoteAdd(text, this.typeComboBox.getValue(), recordId);
        this.onClose();
      }
    };

    this.cancelAction = new Ext.Action({
      text: i18n._('Cancel'),
      iconCls: 'action_cancel',
      minWidth: 70,
      handler: this.onCancel,
      scope: this
    });
    this.okAction = new Ext.Action({
      text: i18n._('Ok'),
      iconCls: 'action_saveAndClose',
      minWidth: 70,
      handler: this.onOk,
      scope: this
    });
    var buttons = [];

    if (Tine.Tinebase.registry && Tine.Tinebase.registry.get('preferences') && Tine.Tinebase.registry.get('preferences').get('dialogactionsOrderStyle') === 'Windows') {
      buttons.push(this.okAction, this.cancelAction);
    } else {
      buttons.push(this.cancelAction, this.okAction);
    }

    this.formPanel = new Ext.FormPanel({
      labelAlign: 'top',
      border: false,
      frame: true,
      buttons: buttons,
      items: [this.typeComboBox, {
        xtype: 'textarea',
        name: 'notification',
        fieldLabel: i18n._('Enter new note:'),
        labelSeparator: '',
        allowBlank: false,
        value: note || '',
        anchor: '100% 100%'
      }]
    });
    this.window = Tine.WindowFactory.getWindow({
      title: i18n._('Add Note'),
      width: 500,
      height: 450,
      modal: true,
      actionAlign: 'right',
      border: false,
      items: this.formPanel
    });
  },

  /**
   * on add note
   * - add note to activities panel
   */
  onNoteAdd: function onNoteAdd(text, typeId, recordId) {
    if (text && typeId && recordId == undefined) {
      var newNote = new Tine.Tinebase.Model.Note({
        note_type_id: typeId,
        note: text
      });
      this.store.add(newNote);
    } else if (text, typeId, recordId) {
      this.store.getById(recordId).set('note_type_id', typeId);
      this.store.getById(recordId).set('note', text);
    }
  },

  /**
   * get notes data as array
   *
   * @return {Array}
   */
  getData: function getData() {
    var notes = [];
    this.store.each(function (record) {
      notes.push(record.data);
    });
    return notes;
  }
});

/***/ }),
/* 1404 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Alexander Stintzing <alex@stintzing.net>
 * @copyright   Copyright (c) 2009-2012 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.relation');
/**
 * @namespace   Tine.widgets.relation
 * @class       Tine.widgets.relation.PickerCombo
 * @author      Alexander Stintzing <a.stintzing@metaways.de>
 */

Tine.widgets.relation.PickerCombo = Ext.extend(Ext.Container, {
  /**
   * config spec for additionalFilters
   *
   * @cfg: {Object} additionalFilterSpec e.g.
   * additionalFilterConfig: {config: { 'name': 'configName', 'appName': 'myApp'}}
   * additionalFilterConfig: {preference: {'appName': 'myApp', 'name': 'preferenceName}}
   * additionalFilterConfig: {favorite: {'appName': 'myApp', 'id': 'favoriteId', 'name': 'optionallyuseaname'}}
   */
  additionalFilterSpec: null,

  /**
   * @cfg {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * @cfg {Tine.widgets.dialog.EditDialog}
   */
  editDialog: null,

  /**
   * the related record can not be chosen in more than one pickerCombo in this.editDialog even if they have different
   * relationTypes
   *
   * NOTE: should be per relationType and degree???  don't we have constraints for this???
   * NOTE: modelUnique is a stupid name -> recordUnique ?
   *
   * @cfg {Boolean} modelUnique
   */
  modelUnique: false,

  /**
   * record class of related record
   *
   * @cfg {Tine.Tinebase.data.Record} recordClass
   */
  recordClass: null,

  /**
   * relation degree of the relation
   * @cfg {String} relationType
   */
  relationDegree: null,

  /**
   * relation type of the relation
   * @cfg {String} relationType
   */
  relationType: null,
  // private
  items: null,
  store: null,
  combo: null,
  layout: 'fit',

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    if (!this.app && this.recordClass) {
      this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
    }

    this.combo = Tine.widgets.form.RecordPickerManager.get(this.app, this.recordClass, Ext.applyIf({}, this));
    this.items = [this.combo];
    this.deferredLoading();
    Tine.widgets.relation.PickerCombo.superclass.initComponent.call(this);
  },

  /**
   * wait until the relationPanel is created
   */
  deferredLoading: function deferredLoading() {
    if (!this.editDialog.relationsPanel) {
      this.deferredLoading.defer(100, this);
      return;
    }

    this.store = this.editDialog.relationsPanel.getStore();
    this.fullModelName = this.recordClass.getMeta('appName') + '_Model_' + this.recordClass.getMeta('modelName');
    this.combo.on('select', function () {
      var value = this.combo.getValue();

      if (value.length) {
        // check if another relationPicker has the same record selected
        if (this.modelUnique) {
          var hasDuplicate = false,
              fieldName;
          Ext.each(this.editDialog.relationPickers, function (picker) {
            if (picker != this) {
              if (picker.getValue() == this.getValue()) {
                hasDuplicate = true;
                fieldName = picker.fieldLabel;
                return false;
              }
            }
          }, this);
        }

        if (hasDuplicate) {
          if (this.combo.startRecord) {
            var split = this.fullModelName.split('_Model_');
            var startRecord = this.combo.startRecord;
          } else {
            startRecord = null;
          }

          this.combo.reset();
          this.combo.setValue(startRecord);
          this.combo.selectedRecord = startRecord;
          this.combo.markInvalid(String.format(i18n._('The {1} "{2}" is already used in the Field "{0}" and can be linked only once!'), fieldName, this.recordClass.getRecordName(), recordToAdd.get(this.recordClass.getMeta('titleProperty'))));
          return false;
        }

        if (value != this.combo.startValue) {
          this.removeIdFromStore(this.combo.startValue);
        }

        this.addRecord(this.combo.selectedRecord);
      } else {
        this.removeIdFromStore(this.combo.startValue);
      }
    }, this);
    if (!this.editDialog.relationPickers) this.editDialog.relationPickers = [];
    this.editDialog.relationPickers.push(this);
  },

  /**
   * Add a record to store if not existing
   * @param recordToAdd
   */
  addRecord: function addRecord(recordToAdd) {
    var record = this.store.findBy(function (record) {
      if (record && record.get('related_id') === this.combo.getValue() && record.get('type') === this.relationType) {
        return true;
      }
    }, this);

    if (record === -1) {
      var relationRecord = new Tine.Tinebase.Model.Relation(Ext.apply(this.editDialog.relationsPanel.getRelationDefaults(), {
        related_record: recordToAdd.data,
        related_id: recordToAdd.id,
        related_model: this.fullModelName,
        type: this.relationType,
        related_degree: this.relationDegree
      }), "".concat(recordToAdd.id, "-").concat(this.relationType));
      this.combo.startRecord = recordToAdd;
      this.store.add(relationRecord);
    }
  },

  /**
   * removes the relation record by the related record id, if the type is the same handled by this combo
   * @param {String} id
   */
  removeIdFromStore: function removeIdFromStore(id) {
    if (id) {
      var oldRecPos = this.store.findBy(function (record) {
        if (record) {
          if (record.get('related_id') == id && record.get('type') == this.relationType) return true;
        } else {
          return false;
        }
      }, this);
      this.store.removeAt(oldRecPos);
    }
  },

  /**
   * Shortcut for the equivalent method of the combo
   */
  setValue: function setValue(v) {
    // If v might be a record, we try to select it and if not in store we create it in relation store
    if (v.hasOwnProperty('data')) {
      this.addRecord(v);
    }

    return this.combo.setValue(v);
  },

  /**
   * Shortcut for the equivalent method of the combo
   */
  clear: function clear() {
    this.combo.startRecord = null;
    return this.combo.setValue(null);
  },

  /**
   * Shortcut for the equivalent method of the combo
   */
  getValue: function getValue() {
    return this.combo.getValue();
  },

  /**
   * Shortcut for the equivalent method of the combo
   */
  setReadOnly: function setReadOnly(v) {
    return this.combo.setReadOnly(v);
  }
});
Ext.reg('tinerelationpickercombo', Tine.widgets.relation.PickerCombo);

/***/ }),
/* 1405 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase.widgets.form');
/**
 * config grid panel
 *
 * @namespace   Tine.Tinebase.widgets.form
 * @class       Tine.Tinebase.widgets.form.RecordsPickerCombo
 * @extends     Tine.widgets.grid.LayerCombo
 */

Tine.Tinebase.widgets.form.RecordsPickerCombo = Ext.extend(Ext.ux.form.LayerCombo, {
  hideButtons: false,
  layerAlign: 'tr-br?',
  minLayerWidth: 400,
  layerHeight: 300,
  allowBlur: true,
  lazyInit: true,
  formConfig: {
    labelAlign: 'left',
    labelWidth: 30
  },
  pickerGrid: null,
  inEditor: true,
  recordClass: null,
  // NOTE: minWidth gets not evaluated by ext - it's just a hint for consumers!
  minWidth: 200,

  /**
   * config spec for additionalFilters - passed to PickerGridPanel
   *
   * @type: {object} e.g.
   * additionalFilterConfig: {config: { 'name': 'configName', 'appName': 'myApp'}}
   * additionalFilterConfig: {preference: {'appName': 'myApp', 'name': 'preferenceName}}
   * additionalFilterConfig: {favorite: {'appName': 'myApp', 'id': 'favoriteId', 'name': 'optionallyuseaname'}}
   */
  additionalFilterSpec: null,
  initComponent: function initComponent() {
    this.emptyText = this.emptyText || (this.readOnly || this.disabled ? '' : i18n._('Search for records ...'));
    this.currentValue = this.currentValue || [];
    Tine.Tinebase.widgets.form.RecordsPickerCombo.superclass.initComponent.call(this);
    this.store = new Ext.data.SimpleStore({
      fields: this.recordClass
    });
    this.on('beforecollapse', this.onBeforeCollapse, this);
  },
  getItems: function getItems() {
    this.pickerGrid = new Tine.widgets.grid.PickerGridPanel({
      recordClass: this.recordClass,
      height: this.layerHeight - 40 || 'auto',
      onStoreChange: Ext.emptyFn,
      store: this.store,
      additionalFilterSpec: this.additionalFilterSpec
    });
    return [this.pickerGrid];
  },

  /**
   * cancel collapse if ctx menu is shown
   */
  onBeforeCollapse: function onBeforeCollapse() {
    return this.pickerGrid && (!this.pickerGrid.contextMenu || this.pickerGrid.contextMenu.hidden) && !this.pickerGrid.editing;
  },

  /**
   * @param {String} value
   * @return {Ext.form.Field} this
   */
  setValue: function setValue(value) {
    var _ = window.lodash;
    value = value || [];
    this.setStoreFromArray(value);

    if (this.rendered) {
      var text = _.reduce(this.store.data.items, function (result, record) {
        return result.concat(record.getTitle());
      }, []).join(', ');

      this.setRawValue(text || this.emptyText);
      this.el[(text ? 'remove' : 'add') + 'Class'](this.emptyClass);
    }

    var oldValue = this.currentValue;
    this.currentValue = value;
    this.value = value;
    Tine.Tinebase.common.assertComparable(this.currentValue);

    if (JSON.stringify(value) != JSON.stringify(oldValue)) {
      this.fireEvent('change', this, value, oldValue);
    }

    return this;
  },
  reset: function reset() {
    this.currentValue = this.originalValue;
    Tine.Tinebase.widgets.form.RecordsPickerCombo.superclass.reset.apply(this, arguments);
  },
  afterRender: function afterRender() {
    Tine.Tinebase.widgets.form.RecordsPickerCombo.superclass.afterRender.apply(this, arguments);

    if (this.currentValue) {
      this.setValue(this.currentValue);
    }
  },

  /**
   * sets values to innerForm (grid)
   */
  setFormValue: function setFormValue(value) {
    if (!value) {
      value = [];
    }

    this.setStoreFromArray(value);
  },

  /**
   * retrieves values from grid
   *
   * @returns {*|Array}
   */
  getFormValue: function getFormValue() {
    return this.getFromStoreAsArray();
  },

  /**
   * get values from store (as array)
   *
   * @param {Array}
   *
   */
  setStoreFromArray: function setStoreFromArray(data) {
    data = data || []; //this.pickerGrid.getStore().clearData();

    this.store.removeAll();

    for (var i = data.length - 1; i >= 0; --i) {
      var recordData = data[i],
          newRecord = new this.recordClass(recordData);
      this.store.insert(0, newRecord);
    }
  },

  /**
   * get values from store (as array)
   *
   * @return {Array}
   *
   */
  getFromStoreAsArray: function getFromStoreAsArray() {
    var result = [];
    this.store.each(function (record) {
      result.push(record.data);
    }, this);
    return result;
  }
});
Ext.reg('tinerecordspickercombobox', Tine.Tinebase.widgets.form.RecordsPickerCombo);

/***/ }),
/* 1406 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.grid');
/**
 * config grid panel
 *
 * @namespace   Tine.widgets.grid
 * @class       Tine.widgets.grid.PickerGridLayerCombo
 * @extends     Tine.Tinebase.widgets.form.RecordsPickerCombo
 */

Tine.widgets.grid.PickerGridLayerCombo = Ext.extend(Tine.Tinebase.widgets.form.RecordsPickerCombo, {
  /**
   * @cfg {Record} gridRecordClass
   */
  gridRecordClass: null,
  initComponent: function initComponent() {
    this.recordClass = this.gridRecordClass;
    Tine.widgets.grid.PickerGridLayerCombo.superclass.initComponent.call(this);
  }
});
Ext.reg('tinepickergridlayercombo', Tine.widgets.grid.PickerGridLayerCombo);

/***/ }),
/* 1407 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     form
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase.widgets.form');
/**
 * Configuration Panel
 * 
 * @namespace   Tine.Tinebase.widgets.form
 * @class       Tine.Tinebase.widgets.form.ConfigPanel
 * @extends     Ext.FormPanel
 * 
 * <p>Configuration Panel</p>
 * <p><pre>
 * NOTE: 
 * - For each section in the config file, a group in the form is added.
 * - Form names are constructed <section>_<subsection>... and transformed transparently by this component
 * - Enabling and Disabling of sections is handled automatically if you give the id 'setup-<section>-group' 
 *   to the checkboxToggle enabled fieldset
 *   
 * TODO         make TABS work
 * TODO         add reload button
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2009 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.Tinebase.widgets.form.ConfigPanel
 */

Tine.Tinebase.widgets.form.ConfigPanel = Ext.extend(Ext.FormPanel, {
  /**
   * @cfg {String} saveMethod 
   * save method (for example 'Setup.saveConfig')
   */
  saveMethod: '',

  /**
   * @cfg {String} registryKey 
   * registry key (for example 'configData')
   */
  registryKey: '',

  /**
   * @cfg {Array} actionToolbarItems
   * additional items for actionToolbar
   */
  actionToolbarItems: [],

  /**
   * form panel cfg
   * 
   * @private
   */
  border: false,
  bodyStyle: 'padding:5px 5px 0',
  labelAlign: 'left',
  labelSeparator: ':',
  labelWidth: 150,
  autoScroll: true,

  /**
   * application object
   * 
   * @property app
   * @type Tine.Tinebase.Application
   */
  app: null,

  /**
   * save config and update setup registry
   */
  onSaveConfig: function onSaveConfig() {
    if (this.isValid()) {
      var configData = this.form2config();
      this.loadMask.show();
      Ext.Ajax.request({
        scope: this,
        params: {
          method: this.saveMethod,
          data: configData
        },
        success: function success(response) {
          var regData = Ext.util.JSON.decode(response.responseText); // replace some registry data

          for (key in regData) {
            if (key != 'status') {
              Tine.Setup.registry.replace(key, regData[key]);
            }
          }

          this.loadMask.hide();
        },
        failure: function failure(response, options) {
          this.loadMask.hide();
          var responseText = Ext.util.JSON.decode(response.responseText),
              exception = responseText.data ? responseText.data : responseText;

          switch (exception.code) {
            // Service Unavailable! / configuration problem
            case 503:
              Ext.MessageBox.show({
                title: i18n._('Configuration Problem'),
                msg: exception.message,
                buttons: Ext.Msg.OK,
                icon: Ext.MessageBox.WARNING,
                fn: function fn() {
                  // TODO only reload own config data
                  Tine.Tinebase.common.reload({});
                }
              });
              break;

            default:
              Tine.Tinebase.ExceptionHandler.handleRequestException(exception);
          }
        }
      });
    } else {
      this.alertInvalidData();
    }
  },
  alertInvalidData: function alertInvalidData() {
    Ext.Msg.alert(this.app.i18n._('Invalid configuration'), this.app.i18n._('You need to correct the red marked fields before config could be saved'));
  },

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.initActions();
    this.items = this.getFormItems();
    Tine.Tinebase.widgets.form.ConfigPanel.superclass.initComponent.call(this);
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.Tinebase.widgets.form.ConfigPanel.superclass.onRender.call(this, ct, position); // always the same shit! when form panel is rendered, the form fields are not yet rendered ;-(

    this.config2form.defer(250, this, [Tine.Setup.registry.get(this.registryKey)]);
    Tine.Setup.registry.on('replace', this.applyRegistryState, this);
    this.loadMask = new Ext.LoadMask(ct, {
      msg: this.app.i18n._('Transferring Configuration...')
    });
  },

  /**
   * applies registry state to this cmp
   */
  applyRegistryState: function applyRegistryState() {},

  /**
   * returns config form (extending classes need to overwrite this)
   * 
   * @private
   * @return {Array} items
   */
  getFormItems: function getFormItems() {
    return [];
  },

  /**
   * transforms form data into a config object
   * 
   * @return {Object} configData
   */
  form2config: function form2config() {
    // getValues only returns RAW HTML content... and we don't want to 
    // define a record here
    var formData = {};
    this.getForm().items.each(function (field) {
      formData[field.name] = field.getValue();
    });
    var configData = {};
    var keyParts, keyPart, keyGroup, dataPath;

    for (var key in formData) {
      keyParts = key.split('_');
      dataPath = configData;

      while (keyPart = keyParts.shift()) {
        if (keyParts.length == 0) {
          dataPath[keyPart] = formData[key];
        } else {
          if (!dataPath[keyPart]) {
            dataPath[keyPart] = {}; // is group active?

            keyGroup = Ext.getCmp('setup-' + keyPart + '-group');

            if (keyGroup && keyGroup.checkboxToggle) {
              dataPath[keyPart].active = !keyGroup.collapsed;
            }
          }

          dataPath = dataPath[keyPart];
        }
      }
    }

    return configData;
  },

  /**
   * loads form with config data
   * 
   * @param  {Object} configData
   */
  config2form: function config2form(configData) {
    var formData = arguments[1] ? arguments[1] : {};
    var currKey = arguments[2] ? arguments[2] : '';
    var keyGroup;

    for (key in configData) {
      if (typeof configData[key] == 'object') {
        this.config2form(configData[key], formData, currKey ? currKey + '_' + key : key);
      } else {
        formData[currKey + '_' + key] = configData[key]; // activate group?

        keyGroup = Ext.getCmp('setup-' + currKey + '-group');

        if (keyGroup && key == 'active' && configData.active) {
          keyGroup.expand();
        }
      }
    } // skip transform calls


    if (!currKey) {
      this.getForm().setValues(formData);
      this.applyRegistryState();
    }
  },

  /**
   * @private
   */
  initActions: function initActions() {
    this.action_saveConfig = new Ext.Action({
      text: this.app.i18n._('Save config'),
      iconCls: 'setup_action_save_config',
      scope: this,
      handler: this.onSaveConfig,
      disabled: true
    }); // TODO add this to reload registry and update form / button

    /*
    this.action_reloadConfig = new Ext.Action({
        text: this.app.i18n._('Reload config'),
        handler: function() {
            Tine.Setup.registry.get(this.registryKey).on('replace', this.config2form, this, [Tine.Setup.registry.get(this.registryKey)]);
            Tine.Tinebase.tineInit.initRegistry();
        },
        iconCls: 'x-tbar-loading',
        scope: this
    });
    */

    this.actions = [this.action_saveConfig //this.action_reloadConfig
    ];
    this.actionToolbar = new Ext.Toolbar({
      items: this.actions.concat(this.actionToolbarItems)
    });
  },

  /**
   * checks if form is valid
   * 
   * @return {Boolean}
   */
  isValid: function isValid() {
    var form = this.getForm();
    return form.isValid();
  },

  /**
   * change card layout card according to combo value
   * 
   * @param {Ext.form.ComboBox} combo
   * @param {String} backendIdPrefix
   */
  changeCard: function changeCard(combo, backendIdPrefix) {
    var value = combo.getValue();
    Tine.log.debug('changeCard() -> value: ' + value);
    var cardPanel = Ext.getCmp(backendIdPrefix + 'CardLayout'),
        cardLayout = cardPanel ? cardPanel.getLayout() : null;

    if (cardLayout && cardLayout !== 'card') {
      Tine.log.debug('changeCard() -> set active item: ' + backendIdPrefix + value);
      cardLayout.setActiveItem(backendIdPrefix + value);
    }
  }
});

/***/ }),
/* 1408 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.form');
Tine.Tinebase.widgets.form.AutoCompleteField = Ext.extend(Ext.form.ComboBox, {
  /**
   * @cfg {String} property 
   * property to autocomplete (required)
   */
  property: null,

  /**
   * @cfg {Ext.data.Record} recordClass
   * record definition class  (required)
   */
  recordClass: null,

  /**
   * config
   */
  forceSelection: false,
  triggerAction: 'all',
  queryParam: 'startswith',
  hideTrigger: true,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.recordClass = this.recordClass || Tine.Tinebase.data.RecordMgr.get(this.appName, this.modelName);

    if (!this.property && this.name) {
      this.property = this.name;
    }

    this.displayField = this.valueField = this.property;
    this.store = new Ext.data.JsonStore({
      fields: [this.property],
      baseParams: {
        method: 'Tinebase.autoComplete',
        appName: this.recordClass.getMeta('appName'),
        modelName: this.recordClass.getMeta('modelName'),
        property: this.property
      },
      root: 'results',
      totalProperty: 'totalcount'
    });
    Tine.Tinebase.widgets.form.AutoCompleteField.superclass.initComponent.call(this);
  }
});
Ext.reg('tine.widget.field.AutoCompleteField', Tine.Tinebase.widgets.form.AutoCompleteField);

/***/ }),
/* 1409 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.form');
/**
 * Upload Button for a _single_ file
 * Calls handler when upload is complete 
 * 
 * @namespace   Tine.widgets.form
 * @class       Tine.widgets.form.FileUploadButton
 * @extends     Ext.Button
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.form.FileUploadButton = Ext.extend(Ext.Button, {
  /**
   * @cfg {Array} allowedTypes
   * array with allowed file types (for example: ['jpg', 'gif', 'png']
   */
  allowedTypes: null,

  /**
   * @cfg {String} uploadTempFileMethod
   */
  uploadTempFileMethod: 'Tinebase.uploadTempFile',

  /**
   * @cfg {String} uploadUrl
   */
  uploadUrl: 'index.php',

  /**
   * @property browsePlugin
   * @type Ext.ux.file.BrowsePlugin
   */
  browsePlugin: null,
  // private config overrides
  iconCls: 'action_upload',
  multiple: false,

  /**
   * init this upload button
   */
  initComponent: function initComponent() {
    this.origHandler = this.handler;
    this.origScope = this.scope;
    this.origIconCls = this.iconCls;
    this.handler = this.onFileSelect;
    this.scope = this;
    this.browsePlugin = new Ext.ux.file.BrowsePlugin({
      multiple: this.multiple
    });
    this.plugins = this.plugins || [];
    this.plugins.push(this.browsePlugin);
    Tine.widgets.form.FileUploadButton.superclass.initComponent.call(this);
  },

  /**
   * called when a file got selected
   * 
   * @param {ux.BrowsePlugin} fileSelector
   * @param {Ext.EventObj} event
   */
  onFileSelect: function onFileSelect(fileSelector, event) {
    if (Ext.isArray(this.allowedTypes) && this.allowedTypes.indexOf(fileSelector.getFileCls()) < 0) {
      Ext.MessageBox.alert(i18n._('Wrong File Type'), [i18n._('Please select a file with one of the following extensions:'), '<br />', this.allowedTypes].join('')).setIcon(Ext.MessageBox.ERROR);
      return;
    }

    this.upload = new Ext.ux.file.Upload({
      fileSelector: fileSelector,
      uploadTempFileMethod: this.uploadTempFileMethod,
      url: this.uploadUrl
    });
    this.upload.on('uploadcomplete', this.onUploadComplete, this);
    this.setIconClass('x-btn-wait');
    this.upload.upload();
  },

  /**
   * called when the upload completed
   * 
   * @param {Ext.ux.file.Upload} upload
   * @param {Ext.ux.file.Upload.file} fileRecord
   */
  onUploadComplete: function onUploadComplete(upload, fileRecord) {
    this.fileRecord = fileRecord;
    this.setText([fileRecord.get('name'), ' (', Tine.Tinebase.common.byteRenderer(fileRecord.get('size')), ')'].join('')); //        this.setIconClass(this.origIconCls);

    this.setIconClass('action_saveAndClose'); // autowidth does not work

    this.setWidth(Ext.util.TextMetrics.measure(this.btnEl, this.text).width + 20);

    if (Ext.isFunction(this.origHandler)) {
      this.origHandler.apply(this.origScope, arguments);
    }
  },
  getTempFileId: function getTempFileId() {
    return this.fileRecord ? this.fileRecord.get('tempFile').id : null;
  }
});
Ext.reg('tw.uploadbutton', Tine.widgets.form.FileUploadButton);

/***/ }),
/* 1410 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2012 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine*/
Ext.ns('Tine.Tinebase.widgets.form');
/**
 * This is a TriggerField which generates a random UID on click
 * (UID generated by Tine.Tinebase.data.Record.generateUID())
 * 
 * @namespace   Tine.Tinebase.widgets.form
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @class       Tine.Tinebase.widgets.form.UidTriggerField
 * @extends     Ext.form.TriggerField
 */

Tine.Tinebase.widgets.form.UidTriggerField = Ext.extend(Ext.form.TriggerField, {
  itemCls: 'tw-uidTriggerField',
  enableKeyEvents: true,

  /**
   * Overrides initComponent to reenable field if it is empty
   */
  initComponent: function initComponent() {
    this.on('keyup', function () {
      this.setHideTrigger(!!this.getValue());
    }, this);
    Tine.Tinebase.widgets.form.UidTriggerField.superclass.initComponent.call(this);
  },

  /**
   * Overrides setValue and shows trigger field if value is empty and hides if it is filled
   *
   * @return {Ext.form.Field} this
   * @param value
   */
  setValue: function setValue(value) {
    this.setHideTrigger(this.getValue());
    return Tine.Tinebase.widgets.form.UidTriggerField.superclass.setValue.call(this, value);
  },

  /**
   * Fills field on click with a random, unique checksum and hides trigger button
   */
  onTriggerClick: function onTriggerClick() {
    if (!this.getValue()) {
      this.setValue(Tine.Tinebase.data.Record.generateUID());
      this.setHideTrigger(true);
    }
  }
});
Ext.reg('tw-uidtriggerfield', Tine.Tinebase.widgets.form.UidTriggerField);

/***/ }),
/* 1411 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.form');
/**
 * Simple password field widget to allow toggling between text and password field
 *
 * @namespace   Tine.Tinebase.widgets.form
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @class       Tine.Tinebase.widgets.form.PasswordTriggerField
 * @extends     Ext.form.TriggerField
 */

Tine.Tinebase.widgets.form.PasswordTriggerField = Ext.extend(Ext.form.TwinTriggerField, {
  /**
   * @cfg {Boolean} unLockable: true,
   */
  unLockable: true,

  /**
   * @cfg {Boolean} locked: true,
   */
  locked: true,

  /**
   * @cfg {Boolean} clipboard: true,
   */
  clipboard: true,

  /**
   * @cfg {Boolean} allowBrowserPasswordManager
   */
  allowBrowserPasswordManager: false,
  hiddenPasswordChr: '●',
  itemCls: 'tw-passwordTriggerField',
  enableKeyEvents: true,
  initComponent: function initComponent() {
    // NOTE: we need to have this in the instance - otherwise we'd overwrite the prototype
    this.defaultAutoCreate = {
      tag: "input",
      type: "password",
      size: "16",
      autocomplete: "off"
    };
    this.defaultAutoCreate.type = this.locked && this.allowBrowserPasswordManager ? 'password' : 'text';

    if (!this.allowBrowserPasswordManager) {
      this.initPreventBrowserPasswordManager();
    }

    if (!this.unLockable) {
      this.afterIsRendered().then(() => {
        this.getTrigger(0).hide();
      });
    }

    Tine.Tinebase.widgets.form.PasswordTriggerField.superclass.initComponent.apply(this, arguments);
  },
  initPreventBrowserPasswordManager: function initPreventBrowserPasswordManager() {
    if (!this.allowBrowserPasswordManager) {
      this.afterIsRendered().then(() => {
        this.el.on('paste', this.transformInput, this);
        this.el.on('keypress', this.transformInput, this);
        this.el.on('keydown', this.transformInput, this);
      });

      this.getValue = () => {
        return this.locked ? this.value || '' : Tine.Tinebase.widgets.form.PasswordTriggerField.superclass.getValue.call(this);
      };

      this.setValue = value => {
        this.value = value;
        this.afterIsRendered().then(() => {
          this.setRawValue(this.locked ? this.hiddenPasswordChr.repeat(this.value.length) : this.value);
        });
      };
    }
  },
  transformInput: function transformInput(e) {
    e = e.browserEvent || e;
    if (!this.locked) return;
    if (e.type === 'keydown' && e.keyCode === 229) return _.defer(_.bind(this.transformIMEInput, this, e));
    if (e.type === 'keydown' && _.indexOf([8
    /* BACKSPACE */
    , 46
    /* DELETE */
    ], e.keyCode) < 0) return;
    if (e.type === 'keypress' && e.metaKey
    /* APPLE CMD */
    && e.keyCode == 118
    /* v */
    ) return;
    if (e.type === 'keypress' && _.indexOf([13
    /* ENTER */
    ], e.keyCode) >= 0) return;
    Ext.lib.Event.stopEvent(e);
    clearTimeout(this.selectTextTimeout);
    let start = e.target.selectionStart;
    const end = e.target.selectionEnd;
    const valueArray = (this.getValue() || '').split('');
    const replacement = e.clipboardData ? e.clipboardData.getData('text') : String.fromCharCode(e.keyCode); // NOTE: keydown & keypress have different keyCodes!

    if (e.type === 'keydown' && _.indexOf([8
    /*BACKSPACE*/
    , 46
    /*DELETE*/
    ], e.keyCode) > -1) {
      start = start - (e.keyCode === 8
      /*BACKSPACE*/
      && start === end);
      valueArray.splice(start, Math.abs(end - start) || 1);
    } else {
      valueArray.splice(start, end - start, replacement);
      start = start + replacement.length;
    }

    this.setValue(valueArray.join(''));
    this.selectTextTimeout = setTimeout(() => {
      this.selectText(start, start);
    }, 20);
  },
  // handle android IME keyboard
  // NOTE: rawValue is updated before this event
  transformIMEInput: function transformIMEInput(e) {
    Ext.lib.Event.stopEvent(e);
    clearTimeout(this.selectTextTimeout);
    const start = e.target.selectionStart;
    const valueArray = (this.getValue() || '').split('');
    const raw = this.getRawValue();
    const replacement = raw.split(this.hiddenPasswordChr).join('');
    const deleteCount = valueArray.length - (raw.length - replacement.length);
    valueArray.splice(start - replacement.length, deleteCount, replacement);
    this.setValue(valueArray.join(''));
    this.selectTextTimeout = setTimeout(() => {
      this.selectText(start, start);
    }, 20);
  },
  initTrigger: function initTrigger() {
    Tine.Tinebase.widgets.form.PasswordTriggerField.superclass.initTrigger.apply(this, arguments);
    this.triggers[0].set({
      'ext:qtip': i18n._('Cleartext/Hidden')
    });
    this.triggers[1].set({
      'ext:qtip': i18n._('Copy to Clipboard')
    });

    if (this.locked) {
      this.triggers[0].addClass('locked');
    }

    if (!this.clipboard) {
      this.triggers[1].hide();
    }
  },
  onTrigger1Click: function onTrigger1Click() {
    this.triggers[0][(this.locked ? 'remove' : 'add') + 'Class']('locked');

    if (this.allowBrowserPasswordManager) {
      this.el.dom.type = this.locked ? 'text' : 'password';
    } else {
      this.value = this.locked ? this.value : this.getRawValue();
      this.setRawValue(this.locked ? this.value : this.hiddenPasswordChr.repeat(this.value.length));
    }

    this.locked = !this.locked;
    this.focus();
  },
  onTrigger2Click: function onTrigger2Click() {
    // NOTE: password fields can not be copied
    var type = this.el.dom.type;
    this.el.dom.type = 'text';
    this.el.dom.select();
    document.execCommand("copy");
    this.el.dom.type = type;
    this.selectText(String(this.getValue()).length);
  }
});
Ext.reg('tw-passwordTriggerField', Tine.Tinebase.widgets.form.PasswordTriggerField);

/***/ }),
/* 1412 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2020 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.file');

Tine.Tinebase.widgets.file.LocationTypePluginFactory = function () {
  const pluginFactories = {
    'download': async function download(config) {
      return __webpack_require__.e(/* import() | Tinebase/js/DownloadFileLocationTypePlugin */ 31).then(__webpack_require__.t.bind(null, 2658, 7)).then(() => {
        return new Tine.Tinebase.widgets.file.LocationTypePlugin.Download(config);
      });
    },
    'upload': async function upload(config) {
      return __webpack_require__.e(/* import() | Tinebase/js/UploadFileLocationTypePlugin */ 34).then(__webpack_require__.t.bind(null, 2659, 7)).then(() => {
        return new Tine.Tinebase.widgets.file.LocationTypePlugin.Upload(config);
      });
    }
  };
  return {
    isRegistered: function isRegistered(type) {
      return pluginFactories.hasOwnProperty(type);
    },
    register: function register(type, factory) {
      pluginFactories[type] = factory;
    },
    create: async function create(type, config) {
      const factory = pluginFactories[type];
      return await factory(config);
    }
  };
}();

/***/ }),
/* 1413 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.dialog');
Tine.Tinebase.widgets.dialog.PasswordDialog = Ext.extend(Tine.Tinebase.dialog.Dialog, {
  /**
   * @cfg {Boolean} allowEmptyPassword
   * Allow to proceed with an empty password
   */
  allowEmptyPassword: false,

  /**
   * @cfg {Boolean} hasPwGen
   * dialog provides password generation action
   */
  hasPwGen: true,

  /**
   * @cfg {Boolean} locked
   * password field is locked (****) per default
   */
  locked: true,

  /**
   * @cfg {String} windowTitle
   * title text when openWindow is used
   */
  windowTitle: '',

  /**
   * @cfg {String} questionText
   * question label for user prompt
   */
  questionText: '',

  /**
   * @cfg {String} passwordFieldLabel
   * label of password field
   */
  passwordFieldLabel: '',

  /**
   * @property {Tine.Tinebase.widgets.form.PasswordTriggerField} passwordField
   * Password field
   */
  passwordField: null,
  layout: 'fit',
  border: false,

  /**
   * Constructor.
   */
  initComponent: function initComponent() {
    this.windowTitle = this.windowTitle || i18n._('Set password');
    this.items = [{
      border: false,
      frame: true,
      layout: 'border',
      items: [{
        region: 'center',
        border: false,
        xtype: 'columnform',
        labelAlign: 'top',
        formDefaults: {
          xtype: 'textfield',
          anchor: '100%',
          labelSeparator: '',
          columnWidth: 1
        },
        items: [[{
          xtype: 'tw-passwordTriggerField',
          fieldLabel: this.passwordFieldLabel || i18n._('Password'),
          name: 'password',
          maxLength: 100,
          allowBlank: this.allowEmptyPassword,
          locked: this.locked,
          clipboard: this.hasPwGen,
          ref: '../../../../passwordField',
          listeners: {
            scope: this,
            paste: this.onChange,
            keyup: this.onChange,
            keydown: this.onKeyDown
          }
        }]]
      }]
    }];

    if (this.questionText) {
      this.items[0].items[0].items[0].unshift({
        xtype: 'label',
        text: this.questionText
      }, {
        xtype: 'label',
        html: '<br>'
      });
    }

    var me = this;
    this.pwgenAction = new Ext.Action({
      disabled: false,
      text: i18n._('Generate password'),
      minWidth: 70,
      iconCls: 'action_managePermissions',
      handler: this.onPWGen.createDelegate(me),
      scope: this
    });

    if (this.hasPwGen) {
      this.tbar = [this.pwgenAction];
    }

    Tine.Tinebase.widgets.dialog.PasswordDialog.superclass.initComponent.call(this);
  },
  afterRender: function afterRender() {
    Tine.Tinebase.widgets.dialog.PasswordDialog.superclass.afterRender.call(this);
    this.buttonApply.setDisabled(!this.allowEmptyPassword);
    this.passwordField.focus(true, 500);
  },

  /**
   * Generate pw
   */
  onPWGen: function onPWGen() {
    var policyConfig = this.policyConfig || Tine.Tinebase.configManager.get('downloadPwPolicy');
    config = {
      minLength: policyConfig ? policyConfig.pwPolicyMinLength : 12,
      minWordChars: policyConfig ? policyConfig.pwPolicyMinWordChars : 5,
      minUppercaseChars: policyConfig ? policyConfig.pwPolicyMinUppercaseChars : 1,
      minSpecialChars: policyConfig ? policyConfig.pwPolicyMinSpecialChars : 1,
      minNumericalChars: policyConfig ? policyConfig.pwPolicyMinNumbers : 1
    };
    var gen = new Tine.Tinebase.PasswordGenerator(config);
    this.passwordField.setValue(gen.generatePassword()); // revalidate button

    this.onChange(this.passwordField);
  },
  onKeyDown: function onKeyDown(f, e) {
    if (e.getKey() === e.ENTER) {
      this.onButtonApply();
    }
  },

  /**
   * Disable ok button if no password entered
   * @param el
   */
  onChange: function onChange(el) {
    _.defer(() => {
      this.buttonApply.setDisabled(!this.allowEmptyPassword && el.getValue().length === 0);
    });
  },
  getEventData: function getEventData(event) {
    if (event === 'apply') {
      return this.passwordField.getValue();
    }
  },

  /**
   * Creates a new pop up dialog/window (acc. configuration)
   *
   * @returns {null}
   */
  openWindow: function openWindow(config) {
    config = config || {};
    this.window = Tine.WindowFactory.getWindow(Ext.apply({
      title: this.windowTitle,
      closeAction: 'close',
      modal: true,
      width: 400,
      height: 130 + (this.hasPwGen ? 20 : 0) + Math.ceil(this.questionText.length / 70) * 20,
      layout: 'fit',
      items: this
    }, config));
    return this.window;
  }
});

/***/ }),
/* 1414 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schüle <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.dialog');
Tine.Tinebase.widgets.dialog.SecondFactorDialog = Ext.extend(Tine.Tinebase.widgets.dialog.PasswordDialog, {
  hasPwGen: false,
  allowEmptyPassword: true,
  height: 120,
  initComponent: function initComponent() {
    this.title = i18n._('Second Factor Password Required');
    Tine.Tinebase.widgets.dialog.SecondFactorDialog.superclass.initComponent.call(this);
    this.on('passwordEntered', function (password) {
      window.postal.publish({
        channel: "messagebus",
        topic: 'secondfactor.check'
      });
      this.loadMask = new Ext.LoadMask(this.getEl(), {
        msg: i18n._('Validating password...')
      });
      this.loadMask.show();
      Ext.Ajax.request({
        params: {
          method: 'Tinebase.validateSecondFactor',
          password: password
        },
        success: function success(_result, _request) {
          this.hideLoadMask();
          var response = Ext.util.JSON.decode(_result.responseText); // TODO add data to messagebus events?

          if (response.success) {
            window.postal.publish({
              channel: "messagebus",
              topic: 'secondfactor.valid'
            });

            if (!Tine.Tinebase.widgets.dialog.SecondFactorDialog.presenceObserver) {
              var secondFactorLifetime = Tine.Tinebase.registry.get('secondFactorSessionLifetime') || 15;
              Tine.Tinebase.widgets.dialog.SecondFactorDialog.presenceObserver = new Tine.Tinebase.PresenceObserver({
                maxAbsenceTime: secondFactorLifetime / 3,
                // ping server each secondFactorLifetime / 3 minutes
                absenceCallback: function absenceCallback(lastPresence, po) {
                  window.postal.publish({
                    channel: "messagebus",
                    topic: 'secondfactor.invalid'
                  });
                },
                presenceCallback: function presenceCallback(lastPresence) {
                  // report presence to server
                  Tine.Tinebase.reportPresence(Ext.encode(lastPresence));
                }
              });
            } else {
              Tine.Tinebase.widgets.dialog.SecondFactorDialog.presenceObserver.startChecking();
            }
          } else {
            window.postal.publish({
              channel: "messagebus",
              topic: 'secondfactor.invalid'
            });
            this.passwordField.setValue(''); // TODO fix z-index?
            //Ext.MessageBox.show({
            //    title: i18n._('Wrong Password'),
            //    msg: i18n._('Invalid second factor password given'),
            //    buttons: Ext.MessageBox.OK
            //});
          }
        },
        failure: function failure() {
          // TODO do some more?
          this.hideLoadMask();
        },
        scope: this
      });
    }, this);
  }
});

/***/ }),
/* 1415 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2016-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.form');
/**
 * Generic 'Edit Record' form
 *
 * @namespace   Tine.widgets.form
 * @class       Tine.widgets.form.RecordForm
 * @extends     Ext.ux.form.ColumnFormPanel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @constructor
 * @param {Object} config The configuration options.
 */

Tine.widgets.form.RecordForm = Ext.extend(Ext.ux.form.ColumnFormPanel, {
  /**
   * record definition class  (required)
   * @cfg {Ext.data.Record} recordClass
   */
  recordClass: null,

  /**
   * {Tine.widgets.dialog.EditDialog} editDialog
   */
  editDialog: null,
  initComponent: function initComponent() {
    var appName = this.recordClass.getMeta('appName'),
        app = Tine.Tinebase.appMgr.get(appName),
        fieldDefinitions = Tine.widgets.form.RecordForm.getFieldDefinitions(this.recordClass);
    this.items = []; // sometimes we need the instances from registry (e.g. printing)

    this.editDialog.recordForm = this;
    Ext.each(fieldDefinitions, function (fieldDefinition) {
      var field = Tine.widgets.form.FieldManager.get(app, this.recordClass, fieldDefinition.fieldName, 'editDialog');

      if (field) {
        // apply basic layout
        field.columnWidth = 1; // add edit dialog
        // TODO do this for all fields??

        if (this.editDialog) {
          field.editDialog = this.editDialog;
        }

        this.items.push([field]);
      }
    }, this);
    Tine.widgets.form.RecordForm.superclass.initComponent.call(this);
  }
});
/**
 * get fieldDefinitions of all fields which should be present in recordForm
 *
 * @param recordClass
 * @return []
 */

Tine.widgets.form.RecordForm.getFieldDefinitions = function (recordClass) {
  var fieldNames = recordClass.getFieldNames(),
      modelConfig = recordClass.getModelConfiguration(),
      fieldsToExclude = ['description', 'tags', 'notes', 'attachments', 'relations', 'customfields'];
  Ext.each(Tine.Tinebase.Model.genericFields, function (field) {
    fieldsToExclude.push(field.name);
  });
  fieldsToExclude.push(recordClass.getMeta('idProperty'));
  return _.reduce(fieldNames, function (fieldDefinitions, fieldName) {
    var fieldDefinition = modelConfig.fields[fieldName];

    if (fieldsToExclude.indexOf(fieldDefinition.fieldName) < 0 && !fieldDefinition.shy) {
      fieldDefinitions.push(fieldDefinition);
    }

    return fieldDefinitions;
  }, []);
};

Tine.widgets.form.RecordForm.getFormHeight = function (recordClass) {
  var dlgConstructor = Tine.widgets.dialog.EditDialog.getConstructor(recordClass),
      fieldDefinitions = Tine.widgets.form.RecordForm.getFieldDefinitions(recordClass),
      formHeight = 38 + 23 + 5; // btnfooter + tabpanel + paddings

  if (dlgConstructor) {
    // toolbar
    if (dlgConstructor.prototype.hasOwnProperty('initButtons')) {
      formHeight += 30;
    }
  }

  Ext.each(fieldDefinitions, function (fieldDefinition) {
    var app = Tine.Tinebase.appMgr.get(recordClass.getMeta('appName')),
        field = Tine.widgets.form.FieldManager.get(app, recordClass, fieldDefinition.fieldName, 'editDialog'),
        height = field ? field.height + 25 || 42 : 0;
    formHeight += height;
  });
  return formHeight;
};

Ext.reg('recordform', Tine.widgets.form.RecordForm);

/***/ }),
/* 1416 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.persistentfilter.model');
/**
 * @namespace   Tine.widgets.persistentfilter
 * @class       Tine.widgets.persistentfilter.model.PersistentFilter
 * @extends     Tine.Tinebase.data.Record
 * 
 * <p>Model of a Persistent Filter</p>
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * 
 * @param       {Object} data
 * @constructor
 * Create a new Tine.widgets.persistentfilter.model.PersistentFilter Record
 */

Tine.widgets.persistentfilter.model.PersistentFilter = Tine.Tinebase.data.Record.create(Tine.Tinebase.Model.genericFields.concat([{
  name: 'id'
}, {
  name: 'application_id'
}, {
  name: 'account_id'
}, {
  name: 'model'
}, {
  name: 'filters'
}, {
  name: 'name'
}, {
  name: 'description'
}, {
  name: 'grants'
}, {
  name: 'account_grants'
}]), {
  appName: 'Tinebase',
  modelName: 'PersistentFilter',
  idProperty: 'id',
  titleProperty: 'name',
  recordName: 'Favorite',
  recordsName: 'Favorites',

  /**
   * is a shared persistent filter
   * 
   * @return {Boolean}
   */
  isShared: function isShared() {
    return this.get('account_id') === null;
  },

  /**
   * is a persistent filter (localized) which is shipped
   * 
   * @return {Boolean}
   */
  isShipped: function isShipped() {
    return this.get('account_id') === null && this.get('created_by') === null;
  },

  /**
   * is default of current user
   * 
   * @return {Boolean}
   */
  isDefault: function isDefault() {
    var app = Tine.Tinebase.appMgr.getById(this.get('application_id'));
    return this.app && this.get('id') === app.getRegistry().get('preferences').get('defaultpersistentfilter');
  }
});
/**
 * @namespace   Tine.widgets.persistentfilter
 * 
 * @param       {String} appName
 * @return      {model.PersistentFilter} or null
 */

Tine.widgets.persistentfilter.model.PersistentFilter.getDefaultFavorite = function (appName, modelName) {
  var app = Tine.Tinebase.appMgr.get(appName),
      appPrefs = app.getRegistry().get('preferences'),
      defaultFavoriteId = appPrefs ? appPrefs.get('defaultpersistentfilter') : null;

  if (defaultFavoriteId === '_lastusedfilter_') {
    var filterData = Ext.state.Manager.get(appName + '-' + modelName + '-lastusedfilter');
    return filterData ? new Tine.widgets.persistentfilter.model.PersistentFilter({
      'filters': filterData,
      'name': '_lastusedfilter_'
    }) : null;
  }

  return defaultFavoriteId ? Tine.widgets.persistentfilter.store.getPersistentFilterStore().getById(defaultFavoriteId) : null;
};
/**
 * @namespace   Tine.widgets.persistentfilter
 * @class       Tine.Tinebase.data.RecordProxy
 * @singelton   Tine.widgets.persistentfilter.model.persistentFilterProxy
 * 
 * <p>Backend for Persistent Filter</p>
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 */


Tine.widgets.persistentfilter.model.persistentFilterProxy = new Tine.Tinebase.data.RecordProxy({
  appName: 'Tinebase_PersistentFilter',
  modelName: 'PersistentFilter',
  recordClass: Tine.widgets.persistentfilter.model.PersistentFilter
});

/***/ }),
/* 1417 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.persistentfilter.store');
/**
 * @namespace   Tine.widgets.persistentfilter
 * @class       Tine.widgets.persistentfilter.store.PersistentFilterStore
 * @extends     Ext.data.ArrayStore
 * 
 * <p>Store for Persistent Filter Records</p>
 * 
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.widgets.persistentfilter.store.PersistentFilterStore
 */

Tine.widgets.persistentfilter.store.PersistentFilterStore = Ext.extend(Ext.data.ArrayStore, {});
/**
 * @namespace   Tine.widgets.persistentfilter
 * 
 * get store of all persistent filters
 * 
 * @static
 * @singleton
 * @return {PersistentFilterStore}
 */

Tine.widgets.persistentfilter.store.getPersistentFilterStore = function () {
  if (!Tine.widgets.persistentfilter.store.persistentFilterStore) {
    if (window.isMainWindow) {
      var fields = Tine.widgets.persistentfilter.model.PersistentFilter.getFieldDefinitions(); // create store

      var s = Tine.widgets.persistentfilter.store.persistentFilterStore = new Tine.widgets.persistentfilter.store.PersistentFilterStore({
        fields: fields,
        listeners: {
          add: (store, records, idx) => {
            let filters = Tine.Tinebase.registry.get('persistentFilters');

            _.set(filters, 'results', _.concat(_.get(filters, 'results'), _.map(records, 'data')));

            _.set(filters, 'totalcount', _.get(filters, 'totalcount') + 1);

            Tine.Tinebase.registry.set("persistentFilters", filters);
          },
          remove: (store, record, idx) => {
            let filters = Tine.Tinebase.registry.get('persistentFilters');

            _.set(filters, 'results', _.pull(_.get(filters, 'results'), _.find(_.get(filters, 'results'), {
              id: record.id
            })));

            _.set(filters, 'totalcount', _.get(filters, 'totalcount') - 1);

            Tine.Tinebase.registry.set("persistentFilters", filters);
          }
        }
      }); // populate store

      var persistentFiltersData = Tine.Tinebase.registry.get("persistentFilters").results;
      s.suspendEvents();
      Ext.each(persistentFiltersData, function (data, index) {
        var filterRecord = new Tine.widgets.persistentfilter.model.PersistentFilter(data);
        s.add(filterRecord);
      }, this);
      s.resumeEvents();
    } else {
      // TODO test this in IE!
      var mainWindow = Ext.ux.PopupWindowMgr.getMainWindow();
      Tine.widgets.persistentfilter.store.persistentFilterStore = mainWindow.Tine.widgets.persistentfilter.store.getPersistentFilterStore();
    }
  }

  return Tine.widgets.persistentfilter.store.persistentFilterStore;
};

/***/ }),
/* 1418 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license http://www.gnu.org/licenses/agpl.html AGPL Version 3 @author
 * Cornelius Weiss <c.weiss@metaways.de> @copyright Copyright (c) 2009-2011
 * Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.persistentfilter');
/**
 * @namespace Tine.widgets.persistentfilter
 * @class Tine.widgets.persistentfilter.PickerPanel
 * @extends Ext.tree.TreePanel
 * 
 * <p>
 * PersistentFilter Picker Panel
 * </p>
 * 
 * @author Cornelius Weiss <c.weiss@metaways.de>
 * @license http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * 
 * @param {Object}
 *            config
 * @constructor Create a new Tine.widgets.persistentfilter.PickerPanel
 */

Tine.widgets.persistentfilter.PickerPanel = Ext.extend(Ext.tree.TreePanel, {
  /**
   * @cfg {application}
   */
  app: null,

  /**
   * @cfg {String} filterMountId mount point of persistent filter folder
   *      (defaults to null -> root node)
   */
  filterMountId: null,

  /**
   * @cfg {String} contentType mainscreen.activeContentType  
   */
  contentType: null,

  /**
   * @private
   */
  autoScroll: false,
  autoHeight: true,
  border: false,
  rootVisible: false,
  enableDD: true,
  stateId: null,

  /**
   * grid favorites panel belongs to
   * 
   * @type Tine.widgets.grid.GridPanel
   */
  grid: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.app = _.isString(this.app) ? Tine.Tinebase.appMgr.get(this.app) : this.app;
    this.stateId = 'widgets-persistentfilter-pickerpanel_' + this.app.name + '_' + this.contentType;
    this.store = this.store || Tine.widgets.persistentfilter.store.getPersistentFilterStore();
    var appName = this.recordClass ? this.recordClass.getMeta('appName') : this.app.appName,
        modelName = this.recordClass ? this.recordClass.getMeta('modelName') : window.lodash.upperFirst(this.contentType),
        filterModelName = this.filterModel || appName + '_Model_' + modelName + 'Filter',
        state = Ext.state.Manager.get(this.stateId, {});

    if (!this.recordClass) {
      this.recordClass = Tine.Tinebase.data.RecordMgr.get(appName, modelName);
    }

    this.recordCollection = this.store.queryBy(function (record, id) {
      if (record.get('application_id') == this.app.id) {
        if (this.contentType || this.filterModel) {
          if (record.get('model') == filterModelName) {
            return true;
          } else {
            return false;
          }
        } else {
          return true;
        }
      }

      return false;
    }, this); // sort filters by translated name

    var self = this;
    this.recordCollection.sort('ASC', function (obj1, obj2) {
      var name1 = Ext.util.Format.htmlEncode(self.app.i18n._hidden(obj1.get('name'))),
          name2 = Ext.util.Format.htmlEncode(self.app.i18n._hidden(obj2.get('name')));
      return name1 > name2 ? 1 : -1;
    });
    var sorting = 10000;
    this.recordCollection.each(function (record) {
      if (state[record.get('id')]) record.set('sorting', state[record.get('id')]);else {
        sorting++;
        record.set('sorting', sorting);
      }
    }, this);
    this.loader = new Tine.widgets.persistentfilter.PickerTreePanelLoader({
      app: this.app,
      recordCollection: this.recordCollection,
      contentType: this.contentType
    });
    new Ext.tree.TreeSorter(this, {
      property: 'sorting',
      sortType: function sortType(node) {
        return node.attributes.sorting;
      }
    });
    this.on('nodedrop', function () {
      this.saveState();
    }, this);
    this.filterNode = this.filterNode || new Ext.tree.AsyncTreeNode({
      text: i18n._('My favorites'),
      id: '_persistentFilters',
      leaf: false,
      expanded: true
    });

    if (this.filterMountId === null) {
      this.root = this.filterNode;
    }

    Tine.widgets.persistentfilter.PickerPanel.superclass.initComponent.call(this);
    this.on('click', function (node) {
      if (node.attributes.isPersistentFilter) {
        this.getFilterToolbar().fireEvent('change', this.getFilterToolbar());
        node.select();
        this.onFilterSelect(this.recordCollection.get(node.id));
      } else if (node.id == '_persistentFilters') {
        node.expand();
        return false;
      }
    }, this);
    this.on('contextmenu', this.onContextMenu, this);
    this.currentUser = Tine.Tinebase.registry.get('currentAccount');
  },

  /**
   * returns canonical path part
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    if (this.recordClass) {
      return [this.recordClass.getMeta('modelName'), 'FavoritesPicker'].join(Tine.Tinebase.CanonicalPath.separator);
    }
  },

  /**
   * @private
   */
  afterRender: function afterRender() {
    Tine.widgets.persistentfilter.PickerPanel.superclass.afterRender.call(this);

    if (this.filterMountId !== null) {
      this.getNodeById(this.filterMountId).appendChild(this.filterNode);
    } // due to dependencies isues we need to wait after render


    var ft = this.getFilterToolbar();

    if (ft) {
      ft.on('change', this.onFilterChange, this);
    }
  },

  /**
   * saves the sort state of the tree
   */
  saveState: function saveState() {
    var state = {};
    var i = 0;
    this.getRootNode().eachChild(function (node) {
      i++;
      node.attributes.sorting = i;
      var rec = this.recordCollection.get(node.attributes.id);
      var oldSort = rec.get('sorting');

      if (oldSort != i) {
        rec.set('sorting', i);
        rec.commit();
      }

      state[node.id] = i;
    }, this);
    Ext.state.Manager.set(this.stateId, state);
  },

  /**
   * load grid from saved filter
   * 
   * NOTE: As all filter plugins add their data on the stores beforeload event
   * we need a litte hack to only present a filterid.
   * 
   * When a filter is selected, we register ourselve as latest beforeload,
   * remove all filter data and paste our filter data. To ensure we are always
   * the last listener, we directly remove the listener afterwards
   */
  onFilterSelect: function onFilterSelect(persistentFilter) {
    var store = this.getGrid().getStore(); // NOTE: this can be removed when all instances of filterplugins are
    // removed

    store.on('beforeload', this.storeOnBeforeload, this);
    store.load({
      persistentFilter: persistentFilter
    });
  },

  /**
   * storeOnBeforeload
   * 
   * @param {}
   *            store
   * @param {}
   *            options
   */
  storeOnBeforeload: function storeOnBeforeload(store, options) {
    options.params.filter = options.persistentFilter.get('filters');
    store.un('beforeload', this.storeOnBeforeload, this);
  },

  /**
   * called on filtertrigger of filter toolbar
   */
  onFilterChange: function onFilterChange() {
    this.getSelectionModel().clearSelections();
  },

  /**
   * returns additional ctx items
   * 
   * @TODO: make this a hooking approach!
   * 
   * @param {model.PersistentFilter}
   * @return {Array}
   */
  getAdditionalCtxItems: function getAdditionalCtxItems(filter) {
    var items = [];
    var as = Tine.Tinebase.appMgr.get('ActiveSync');

    if (as) {
      items = items.concat(as.getPersistentFilterPickerCtxItems(this, filter));
    }

    return items;
  },

  /**
   * returns filter toolbar of mainscreen center panel of app this picker
   * panel belongs to
   */
  getFilterToolbar: function getFilterToolbar() {
    if (!this.filterToolbar) {
      this.filterToolbar = this.getGrid().filterToolbar;
    }

    return this.filterToolbar;
  },

  /**
   * get grid
   * 
   * @return {Tine.widgets.grid.GridPanel}
   */
  getGrid: function getGrid() {
    if (!this.grid) {
      this.grid = this.app.getMainScreen().getCenterPanel();
    }

    return this.grid;
  },

  /**
   * returns persistent filter tree node
   * 
   * @return {Ext.tree.AsyncTreeNode}
   */
  getPersistentFilterNode: function getPersistentFilterNode() {
    return this.filterNode;
  },

  /**
   * handler for ctxmenu clicks on tree nodes
   * 
   * @param {Ext.tree.TreeNode}
   *            node
   * @param {Ext.EventObject}
   *            e
   */
  onContextMenu: function onContextMenu(node, e) {
    if (!node.attributes.isPersistentFilter) {
      return;
    }

    e.stopEvent();
    Tine.log.debug(node);
    var record = this.store.getById(node.id);
    var hasManageRight = this.hasRight(node.attributes);
    var menu = new Ext.menu.Menu({
      plugins: [{
        ptype: 'ux.itemregistry',
        key: 'Tinebase-MainContextMenu'
      }],
      items: [{
        text: i18n._('Delete Favorite'),
        iconCls: 'action_delete',
        hidden: !(hasManageRight || this.hasGrant(node.attributes, 'deleteGrant')),
        handler: this.onDeletePersistentFilter.createDelegate(this, [node, e])
      }, {
        text: i18n._('Edit Favorite'),
        iconCls: 'action_edit',
        hidden: !(hasManageRight || this.hasGrant(node.attributes, 'editGrant')),
        handler: this.onEditPersistentFilter.createDelegate(this, [node, e])
      }, {
        text: i18n._('Overwrite Favorite'),
        iconCls: 'action_saveFilter',
        hidden: !(hasManageRight || this.hasGrant(node.attributes, 'editGrant')),
        handler: this.onOverwritePersistentFilter.createDelegate(this, [node, e])
      }].concat(this.getAdditionalCtxItems(record))
    });
    menu.showAt(e.getXY());
  },

  /**
   * handler to delete filter
   * 
   * @param {Ext.tree.TreeNode}
   *            node
   */
  onDeletePersistentFilter: function onDeletePersistentFilter(node) {
    Ext.MessageBox.confirm(i18n._('Confirm'), String.format(i18n._('Do you really want to delete the favorite "{0}"?'), node.text), function (_btn) {
      if (_btn == 'yes') {
        Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Deleting Favorite "{0}"'), this.containerName, node.text));
        var record = this.store.getById(node.id);
        Tine.widgets.persistentfilter.model.persistentFilterProxy.deleteRecords([record], {
          scope: this,
          success: function success() {
            this.store.remove(record);
            this.recordCollection.remove(record);
            this.filterNode.findChild('id', record.get('id')).remove();
            Ext.MessageBox.hide();
          }
        });
      }
    }, this);
  },

  /**
   * handler to rename filter
   * 
   * @param {Ext.tree.TreeNode}
   *            node
   */
  onEditPersistentFilter: function onEditPersistentFilter(node) {
    var record = this.store.getById(node.id);
    this.getEditWindow(record);
  },

  /**
   * handler to overwrite filter
   * 
   * @param {Ext.tree.TreeNode}
   *            node
   */
  onOverwritePersistentFilter: function onOverwritePersistentFilter(node) {
    var record = this.store.getById(node.id);
    Ext.MessageBox.confirm(i18n._('Overwrite?'), String.format(i18n._('Do you want to overwrite the favorite "{0}"?'), node.text), function (_btn) {
      if (_btn == 'yes') {
        Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Overwriting Favorite "{0}"'), node.text));
        var ftb = this.getFilterToolbar();
        record.set('filters', ftb.getAllFilterData());
        this.createOrUpdateFavorite(record);
      }
    }, this, false, node.text);
  },

  /**
   * save persistent filter
   */
  saveFilter: function saveFilter() {
    var ftb = this.getFilterToolbar();
    var record = this.getNewEmptyRecord();
    record.set('filters', ftb.getAllFilterData()); // recheck that current ftb is saveable

    if (!ftb.isSaveAllowed()) {
      Ext.Msg.alert(i18n._('Could not save Favorite'), i18n._('Your current view does not support favorites'));
      return;
    }

    this.getEditWindow(record);
  },
  getEditWindow: function getEditWindow(record) {
    if (!record.get('id')) {
      var title = i18n._('Create Favorite');
    } else {
      var title = i18n._('Edit Favorite');
    }

    var height = 160;

    if ((this.hasRight() || this.hasGrant(record, 'editGrant')) && !record.isDefault()) {
      height = 440;
    }

    Tine.log.debug('Tine.widgets.persistentfilter.PickerPanel::getEditWindow - create edit window for filter record: ');
    Tine.log.debug(record);
    var newWindow = Tine.WindowFactory.getWindow({
      modal: true,
      app: this.app,
      modelName: this.contentType,
      record: record,
      title: title,
      width: 400,
      height: height,
      contentPanelConstructor: 'Tine.widgets.persistentfilter.EditPersistentFilterPanel',
      contentPanelConstructorConfig: null
    });
    newWindow.on('update', function (win) {
      Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Saving Favorite "{0}"'), record.get('name')));
      this.createOrUpdateFavorite(newWindow.record);
    }, this);
  },

  /**
   * checks right
   * 
   * @param {Object} filter
   * @return {Boolean}
   */
  hasRight: function hasRight(filter) {
    if (filter && filter.created_by == this.currentUser.accountId) {
      return true;
    }

    return Tine.Tinebase.common.hasRight('manage_shared_' + this.contentType.toLowerCase() + '_favorites', this.app.name);
  },

  /**
   * check if user has grant on record 
   * 
   * @param {Record} record
   * @param {String} requiredGrant
   * @return {Boolean}
   * 
   * TODO move this to generic Record
   */
  hasGrant: function hasGrant(record, requiredGrant) {
    var accountGrants = record && record.account_grants ? record.account_grants : record && record.data && record.data.account_grants ? record.data.account_grants : false,
        result = accountGrants && accountGrants[requiredGrant] == true;
    Tine.log.debug('hasGrant(' + requiredGrant + ') -> ' + result);
    return result;
  },

  /**
   * create or update a favorite
   * 
   * @param {Tine.widgets.persistentfilter.model.PersistentFilter} record
   */
  createOrUpdateFavorite: function createOrUpdateFavorite(record) {
    Tine.log.debug('createOrUpdateFavorite() ->');
    Tine.log.debug(record);
    Tine.widgets.persistentfilter.model.persistentFilterProxy.saveRecord(record, {
      scope: this,
      success: function success(savedRecord) {
        Tine.log.debug('savedRecord ->');
        Tine.log.debug(record);
        var existing = this.recordCollection.get(savedRecord.id);

        if (existing) {
          savedRecord.set('sorting', existing.get('sorting'));
          this.store.remove(existing);
          this.recordCollection.remove(existing);
          this.filterNode.findChild('id', existing.get('id')).remove();
        } else {
          var sorting = 0;
          savedRecord.set('sorting', sorting);
        }

        var attr = savedRecord.data;
        this.loader.inspectCreateNode(attr);
        this.filterNode.appendChild(new Ext.tree.TreeNode(attr));
        this.store.add(savedRecord);
        this.recordCollection.add(savedRecord);
        this.recordCollection.sort();

        if (!existing) {
          this.saveState();
        }

        Ext.Msg.hide(); // reload this filter?

        this.selectFilter(savedRecord);
      }
    });
  },

  /**
   * select given persistent filter
   * 
   * @param {model.PersistentFilter}
   *            persistentFilter
   */
  selectFilter: function selectFilter(persistentFilter) {
    if (!persistentFilter) {
      return;
    }

    this.getFilterToolbar().fireEvent('change', this.getFilterToolbar());
    var node = this.getNodeById(persistentFilter.id);

    if (node) {
      this.getSelectionModel().select(node);
    } else {
      // mark for selection
      this.getLoader().selectedFilterId = persistentFilter.id;
    }

    this.onFilterSelect(persistentFilter);
  },

  /**
   * select default favorite
   *
   * NOTE: a lot modules/models don't have a default favorite preference
   */
  selectDefault: function selectDefault() {
    var appName = this.recordClass.getMeta('appName'),
        modelName = this.recordClass.getMeta('modelName'),
        defaultFavorite = Tine.widgets.persistentfilter.model.PersistentFilter.getDefaultFavorite(appName, modelName);
    this.selectFilter(defaultFavorite);
  },
  getNewEmptyRecord: function getNewEmptyRecord() {
    var model = this.filterModel,
        ftb = this.getFilterToolbar();

    if (!model) {
      var recordClass = this.recordClass || (this.treePanel ? this.treePanel.recordClass : ftb.store.reader.recordType);
      model = recordClass.getMeta('appName') + '_Model_' + recordClass.getMeta('modelName') + 'Filter';
    }

    var record = new Tine.widgets.persistentfilter.model.PersistentFilter({
      application_id: this.app.id,
      account_id: Tine.Tinebase.registry.get('currentAccount').accountId,
      model: model,
      filters: null,
      name: null,
      description: null
    });
    return record;
  }
});
/**
 * @namespace Tine.widgets.persistentfilter
 * @class Tine.widgets.persistentfilter.PickerTreePanelLoader
 * @extends Tine.widgets.tree.Loader
 * 
 * <p>
 * PersistentFilter Picker Panel Tree Loader
 * </p>
 * 
 * @author Cornelius Weiss <c.weiss@metaways.de>
 * @license http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * 
 * @param {Object}
 *            config
 * @constructor Create a new Tine.widgets.persistentfilter.PickerTreePanelLoader
 */

Tine.widgets.persistentfilter.PickerTreePanelLoader = Ext.extend(Tine.widgets.tree.Loader, {
  /**
   * @cfg {Ext.util.MixedCollection} recordCollection
   */
  recordCollection: null,

  /**
   * @cfg {String} selectedFilterId id to autoselect
   */
  selectedFilterId: null,

  /**
   * 
   * @param {Ext.tree.TreeNode}
   *            node
   * @param {Function}
   *            callback Function to call after the node has been
   *            loaded. The function is passed the TreeNode which was
   *            requested to be loaded.
   * @param (Object)
   *            scope The cope (this reference) in which the callback
   *            is executed. defaults to the loaded TreeNode.
   */
  requestData: function requestData(node, callback, scope) {
    if (this.fireEvent("beforeload", this, node, callback) !== false) {
      node.beginUpdate();
      this.recordCollection.each(function (record) {
        var n = this.createNode(record.copy().data);

        if (n) {
          node.appendChild(n);
        }
      }, this);
      node.endUpdate();
      this.runCallback(callback, scope || node, [node]);
    } else {
      // if the load is cancelled, make sure we notify
      // the node that we are done
      this.runCallback(callback, scope || node, []);
    }
  },
  inspectCreateNode: function inspectCreateNode(attr) {
    var isPersistentFilter = !!attr.model && !!attr.filters;
    var isShared = attr.account_id === null ? true : false;
    var addText = '';
    var addClass = '';

    if (isShared) {
      addText = i18n._('(shared)');
      addClass = '-shared';
    }

    if (isPersistentFilter) {
      Ext.apply(attr, {
        isPersistentFilter: isPersistentFilter,
        text: Ext.util.Format.htmlEncode(this.app.i18n._hidden(attr.name)),
        qtip: Ext.util.Format.htmlEncode(attr.description ? this.app.i18n._hidden(attr.description) + ' ' + addText : addText),
        selected: attr.id === this.selectedFilterId,
        id: attr.id,
        sorting: attr.sorting,
        draggable: true,
        allowDrop: false,
        leaf: attr.leaf === false ? attr.leaf : true,
        cls: 'tinebase-westpanel-node-favorite' + addClass
      });
    }
  }
});

/***/ }),
/* 1419 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license http://www.gnu.org/licenses/agpl.html AGPL Version 3 @author
 * @author Alexander Stintzing <a.stintzing@metaways.de> 
 * @copyright Copyright (c) 2009-2012
 * Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.widgets.persistentfilter');
/**
 * @namespace Tine.widgets.persistentfilter
 * @class Tine.widgets.persistentfilter.EditPersistentFilterPanel
 * @extends Ext.FormPanel
 * 
 * <p>
 * PersistentFilter Edit Dialog
 * </p>
 * 
 * @author Alexander Stintzing <a.stintzing@metaways.de>
 * @license http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * 
 * @param {Object} config
 */

Tine.widgets.persistentfilter.EditPersistentFilterPanel = Ext.extend(Ext.FormPanel, {
  layout: 'fit',
  border: false,
  cls: 'tw-editdialog',
  bodyStyle: 'padding:5px',
  labelAlign: 'top',
  anchor: '100% 100%',
  deferredRender: false,
  buttonAlign: null,
  bufferResize: 500,

  /**
   * the application the panel belongs to. (auto set by initComponent)
   * 
   * @type {Tine.Tinebase.Application} app
   */
  app: null,

  /**
   * initializes the component
   */
  initComponent: function initComponent() {
    this.addEvents('cancel', 'save', 'close'); // init actions

    this.initActions(); // init buttons and tbar

    this.initButtons();
    this.app = Tine.Tinebase.appMgr.get(this.window.app.name); // get items for this dialog

    this.items = this.getFormItems();
    Tine.widgets.persistentfilter.EditPersistentFilterPanel.superclass.initComponent.call(this);
  },

  /**
   * initializes the actions
   */
  initActions: function initActions() {
    this.action_save = new Ext.Action({
      text: i18n._('OK'),
      minWidth: 70,
      scope: this,
      handler: this.onSave,
      iconCls: 'action_saveAndClose'
    });
    this.action_cancel = new Ext.Action({
      text: i18n._('Cancel'),
      minWidth: 70,
      scope: this,
      handler: this.onCancel,
      iconCls: 'action_cancel'
    });
  },

  /**
   * initializes the buttons
   * use preference settings for order of save and close buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->'];
    this.fbar.push(this.action_cancel, this.action_save);
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.widgets.dialog.EditDialog.superclass.onRender.call(this, ct, position); // load grants

    if (this.window.record) {
      var grants = this.window.record.get('grants') || [];
      this.getGrantsStore().loadData({
        results: grants
      });
    } // generalized keybord map for edit dlgs


    new Ext.KeyMap(this.el, [{
      key: [13],
      ctrl: false,
      fn: this.onSave,
      scope: this
    }]);
  },

  /**
   * is called on save
   */
  onSave: function onSave() {
    if (!this.window.record) {
      this.window.record = this.getNewEmptyRecord();
    }

    var record = this.window.record,
        shipped = this.window.record.isShipped(),
        // if any field has changed of a shipped record, use translation
    shippedChanged = shipped && this.inputTitle.getValue() != this.app.i18n._(this.window.record.get('name')) || shipped && this.inputDescription.getValue() != this.app.i18n._(this.window.record.get('description')) || (this.hasRight() || this.hasEditGrant()) && !this.inputCheck.getValue();

    if (this.inputTitle.isValid()) {
      if (!shipped || shippedChanged) {
        record.set('name', this.inputTitle.getValue());
      }
    } else {
      Ext.Msg.alert(i18n._('Favorite not saved'), this.inputTitle.getActiveError());
      return;
    } // Description of the favorite


    if (this.inputDescription.isValid()) {
      if (!shipped || shippedChanged) {
        record.set('description', this.inputDescription.getValue());
      }
    }

    record.set('account_id', Tine.Tinebase.registry.get('currentAccount').accountId);

    if (this.hasRight() || this.hasEditGrant()) {
      // Favorite Checkbox
      if (this.inputCheck.getValue()) {
        record.set('account_id', null);
      } // set grants


      this.window.record.set('grants', '');
      var grants = [];
      this.grantsStore.each(function (record) {
        grants.push(record.data);
      });
      this.window.record.set('grants', grants);
    }

    this.window.fireEvent('update');
    this.purgeListeners();
    this.window.purgeListeners();
    this.window.close();
  },

  /**
   * is called on cancel
   */
  onCancel: function onCancel() {
    this.fireEvent('cancel');
    this.purgeListeners();
    this.window.close();
  },

  /**
   * returns the needed form items
   * @return {Object}
   */
  getFormItems: function getFormItems() {
    var record = this.window.record,
        shipped = record && record.isShipped(),
        title = shipped ? this.app.i18n._(record.get('name')) : record ? record.get('name') : '',
        description = shipped ? this.app.i18n._(record.get('description')) : record ? record.get('description') : '';
    this.inputTitle = new Ext.form.TextField({
      value: title,
      allowBlank: false,
      fieldLabel: i18n._('Title'),
      width: '97%',
      minLength: 1,
      maxLength: 40
    });
    this.inputDescription = new Ext.form.TextField({
      value: description,
      allowBlank: true,
      fieldLabel: i18n._('Description'),
      width: '97%',
      minLength: 0,
      maxLength: 255
    });
    this.inputCheck = new Ext.form.Checkbox({
      checked: record ? record.isShared() : false,
      hideLabel: true,
      boxLabel: i18n._('Shared Favorite (visible by other users)'),
      disabled: !this.hasRight(),
      listeners: {
        'check': function check(checkbox, value) {
          Tine.log.debug('Tine.widgets.persistentfilter.EditPersistentFilterPanel::inputCheck.check -> ' + value);

          if (value) {
            this.getGrantsGrid().enable();
          } else {
            this.getGrantsGrid().disable();
          }
        },
        scope: this
      }
    });
    var items = [{
      region: 'center',
      layout: {
        align: 'stretch',
        type: 'vbox'
      }
    }, this.inputTitle, this.inputDescription];
    items.push(this.inputCheck);
    items.push(this.getGrantsGrid());

    if (!record.isShared()) {
      this.getGrantsGrid().disable();
    }

    return {
      border: false,
      frame: true,
      layout: 'form',
      items: items
    };
  },

  /**
   * get grants grid
   * 
   * @return Tine.widgets.account.PickerGridPanel
   */
  getGrantsGrid: function getGrantsGrid() {
    if (!this.grantsGrid) {
      var columns = [new Ext.ux.grid.CheckColumn({
        header: i18n._('Read'),
        dataIndex: 'readGrant',
        tooltip: i18n._('The grant to see and use this filter')
      }), new Ext.ux.grid.CheckColumn({
        header: i18n._('Edit'),
        tooltip: i18n._('The grant to edit this filter'),
        dataIndex: 'editGrant'
      }), new Ext.ux.grid.CheckColumn({
        header: i18n._('Delete'),
        tooltip: i18n._('The grant to delete this filter'),
        dataIndex: 'deleteGrant'
      })];
      this.grantsGrid = new Tine.widgets.account.PickerGridPanel({
        selectType: 'both',
        selectRole: true,
        title: i18n._('Permissions'),
        store: this.getGrantsStore(),
        hasAccountPrefix: true,
        configColumns: columns,
        //selectAnyone: true,
        selectTypeDefault: 'group',
        anchor: '97% 65%',
        recordClass: Tine.Tinebase.Model.Grant
      });
    }

    return this.grantsGrid;
  },

  /**
   * get grants store
   * 
   * @return Ext.data.JsonStore
   */
  getGrantsStore: function getGrantsStore() {
    if (!this.grantsStore) {
      this.grantsStore = new Ext.data.JsonStore({
        root: 'results',
        totalProperty: 'totalcount',
        // use account_id here because that simplifies the adding of new records with the search comboboxes
        id: 'account_id',
        fields: Tine.Tinebase.Model.Grant
      });
    }

    return this.grantsStore;
  },

  /**
   * checks the managed_shared_<this.modelName>_right
   * @return {}
   */
  hasRight: function hasRight() {
    var right = Tine.Tinebase.common.hasRight('manage_shared_' + this.window.modelName.toLowerCase() + '_favorites', this.window.app.name);
    return right;
  },

  /**
   * check if user has grant on record 
   * 
   * @param {Record} record
   * @param {String} requiredGrant
   * @return {Boolean}
   * 
   * TODO move this to generic Record
   */
  hasEditGrant: function hasEditGrant() {
    var record = this.window.record,
        accountGrants = record ? record.account_grants || record.data.account_grants : false,
        result = accountGrants && accountGrants['editGrant'] == true;
    Tine.log.debug('hasEditGrant() -> ' + result);
    return result;
  }
});

/***/ }),
/* 1420 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.cweiss@metaways.de>
 * @copyright   Copyright (c) 2016 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.widgets.path');
/**
 * paths block renderer
 *
 * @param {Array} paths
 * @param {String} queryString
 * @returns {string}
 */

Tine.widgets.path.pathsRenderer = function (paths, queryString) {
  var pathsString = '';

  if (Ext.isArray(paths)) {
    Ext.each(paths, function (path) {
      pathsString += Tine.widgets.path.pathRenderer(path, queryString);
    });
  }

  return pathsString ? '<div class="tb-widgets-path-pathsblock">' + pathsString + '</div>' : pathsString;
};
/**
 * single path renderer
 *
 * @param path
 * @param queryString
 * @returns {string}
 */


Tine.widgets.path.pathRenderer = function (path, queryString) {
  var _ = window.lodash,
      pathName = String(_.get(path, "path", path)),
      queryParts = String(queryString || '').trim().split(' ');
  pathName = pathName.replace(/^\//, '').replace(/\//g, '\u0362');
  pathName = Ext.util.Format.htmlEncode(pathName);

  if (queryParts.length) {
    var queryMatchCount = 0,
        search = '';
    Ext.each(queryParts, function (queryPart, idx) {
      search += (search ? '|(' : '(') + window.lodash.escapeRegExp(queryPart) + ')';
    });
    pathName = pathName.replace(new RegExp(search, 'gi'), function (match) {
      queryMatchCount++;
      return '<span class="tb-widgets-path-pathitem-match">' + match + '</span>';
    }); // skip path if no token matched

    if (queryParts.length > queryMatchCount) {
      pathName = '';
    }
  }

  var qtip = pathName.replace(/(?:{(.*?)}){0,1}\u0362/g, function (all, type) {
    return "<br/>&nbsp;" + (type ? type + ' ' : '') + '<span class="tb-widgets-path-pathitem-separator">' + Ext.util.Format.htmlEncode('\u00BB') + '</span>&nbsp;';
  });
  pathName = pathName.replace(/(?:{(.*?)}){0,1}\u0362/g, function (all, type) {
    return "&nbsp;" + (type ? '<span class="tb-widgets-path-pathitem-type">' + type[0] + '</span>' : '') + '<span class="tb-widgets-path-pathitem-separator">' + Ext.util.Format.htmlEncode('\u00BB') + '</span>&nbsp;';
  });
  return pathName ? '<div class="tb-widgets-path-pathitem" ext:qtip="' + Ext.util.Format.htmlEncode(qtip) + '">' + pathName + '</div>' : pathName;
};

/***/ }),
/* 1421 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine', 'Tine.Tinebase');
/**
 * @namespace  Tine.Tinebase
 * @class      Tine.Tinebase.PasswordChangeDialog
 * @extends    Ext.Window
 */

Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
  id: 'changePassword_window',
  closeAction: 'close',
  modal: true,
  width: 350,
  height: 230,
  minWidth: 350,
  minHeight: 230,
  layout: 'fit',
  plain: true,
  title: null,
  // password or pin
  pwType: 'password',
  initComponent: function initComponent() {
    this.currentAccount = Tine.Tinebase.registry.get('currentAccount');
    this.passwordLabel = this.pwType === 'pin' ? i18n._('PIN') : i18n._('Password');
    this.title = this.title !== null ? this.title : String.format(i18n._('Change {0} For "{1}"'), this.passwordLabel, this.currentAccount.accountDisplayName);
    this.items = new Ext.FormPanel({
      bodyStyle: 'padding:5px;',
      buttonAlign: 'right',
      labelAlign: 'top',
      anchor: '100%',
      id: 'changePasswordPanel',
      defaults: {
        xtype: 'tw-passwordTriggerField',
        anchor: '100%'
      },
      items: [{
        id: 'oldPassword',
        clipboard: false,
        fieldLabel: String.format(i18n._('Old {0}'), this.passwordLabel),
        name: 'oldPassword'
      }, {
        id: 'newPassword',
        autocomplete: 'new-password',
        fieldLabel: String.format(i18n._('New {0}'), this.passwordLabel),
        name: 'newPassword'
      }, {
        id: 'newPasswordSecondTime',
        autocomplete: 'new-password',
        fieldLabel: String.format(i18n._('Repeat new {0}'), this.passwordLabel),
        name: 'newPasswordSecondTime'
      }],
      buttons: [{
        text: i18n._('Cancel'),
        iconCls: 'action_cancel',
        handler: function handler() {
          Ext.getCmp('changePassword_window').close();
        }
      }, {
        text: i18n._('Ok'),
        iconCls: 'action_saveAndClose',
        handler: function handler() {
          var form = Ext.getCmp('changePasswordPanel').getForm();
          var values;

          if (!this.loadMask) {
            this.loadMask = new Ext.LoadMask(this.getEl(), {
              msg: String.format(i18n._('Changing {0}'), this.passwordLabel)
            });
          }

          this.loadMask.show();

          if (form.isValid()) {
            values = form.getFieldValues();

            if (values.newPassword == values.newPasswordSecondTime) {
              Ext.Ajax.request({
                params: {
                  method: this.pwType === 'pin' ? 'Tinebase.changePin' : 'Tinebase.changePassword',
                  oldPassword: values.oldPassword,
                  newPassword: values.newPassword
                },
                success: function success(_result, _request) {
                  this.loadMask.hide();
                  var response = Ext.util.JSON.decode(_result.responseText);

                  if (response.success) {
                    Ext.getCmp('changePassword_window').close();
                    Ext.MessageBox.show({
                      title: i18n._('Success'),
                      msg: String.format(i18n._('Your {0} has been changed.'), this.passwordLabel),
                      buttons: Ext.MessageBox.OK,
                      icon: Ext.MessageBox.INFO
                    });

                    if (this.pwType === 'password') {
                      Ext.Ajax.request({
                        params: {
                          method: 'Tinebase.updateCredentialCache',
                          password: values.newPassword
                        }
                      });
                    }
                  } else {
                    Ext.MessageBox.show({
                      title: i18n._('Failure'),
                      msg: Ext.util.Format.nl2br(response.errorMessage),
                      buttons: Ext.MessageBox.OK,
                      icon: Ext.MessageBox.ERROR
                    });
                  }
                },
                scope: this
              });
            } else {
              this.loadMask.hide();
              Ext.MessageBox.show({
                title: i18n._('Failure'),
                msg: String.format(i18n._('{0} mismatch, please correct.'), this.passwordLabel),
                buttons: Ext.MessageBox.OK,
                icon: Ext.MessageBox.ERROR
              });
            }
          }
        },
        scope: this
      }]
    });
    Tine.Tinebase.PasswordChangeDialog.superclass.initComponent.call(this);
  }
});

/***/ }),
/* 1422 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine', 'Tine.Tinebase');
/**
 * @namespace  Tine.Tinebase
 * @class      Tine.Tinebase.AboutDialog
 * @extends    Ext.Window
 */

Tine.Tinebase.AboutDialog = Ext.extend(Ext.Window, {
  closeAction: 'close',
  modal: true,
  width: 400,
  height: 360,
  minWidth: 400,
  minHeight: 360,
  layout: 'fit',
  title: null,
  initAboutTpl: function initAboutTpl() {
    this.aboutTpl = new Ext.XTemplate('<div class="tb-about-dlg">', '<div class="tb-about-img"><a href="{logoLink}" target="_blank"><img src="{logo}" /></a></div>', '<div class="tb-link-home"><a href="{logoLink}" target="_blank">{linkText}</a></div>', '<div class="tb-about-version">Version: {codeName}</div>', '<div class="tb-about-build">({packageString})</div>', '<div class="tb-about-copyright">Copyright: 2007-{[new Date().getFullYear()]}&nbsp;<a href="http://www.metaways.de/" target="_blank">Metaways Infosystems GmbH</a></div>', '<div class="tb-about-credits-license"><p><a href="javascript:void()" class="license" /><a href="javascript:void()" class="credits" /></p></div>', '</div>');
  },
  initComponent: function initComponent() {
    this.title = String.format(i18n._('About {0}'), Tine.title);
    this.initAboutTpl();
    var version = Tine.Tinebase.registry.get('version') ? Tine.Tinebase.registry.get('version') : {
      codeName: 'unknown',
      packageString: 'unknown'
    };
    this.items = {
      layout: 'fit',
      border: false,
      html: this.aboutTpl.applyTemplate({
        logo: Tine.logo,
        logoLink: Tine.weburl,
        linkText: String.format(i18n._('Learn more about {0}'), Tine.title),
        codeName: version.codeName,
        packageString: version.packageString
      }),
      buttons: [{
        text: i18n._('Ok'),
        iconCls: 'action_saveAndClose',
        handler: this.close,
        scope: this
      }]
    }; // create links

    this.on('afterrender', function () {
      var el = this.getEl().select('div.tb-about-dlg div.tb-about-credits-license a.license');
      el.insertHtml('beforeBegin', ' ' + i18n._('Released under different') + ' ');
      el.insertHtml('beforeEnd', i18n._('Open Source Licenses'));
      el.on('click', function () {
        var ls = new Tine.Tinebase.LicenseScreen();
        ls.show();
      });
      var el = this.getEl().select('div.tb-about-dlg div.tb-about-credits-license a.credits');
      el.insertHtml('beforeBegin', ' ' + i18n._('with the help of our') + ' ');
      el.insertHtml('beforeEnd', i18n._('Contributors'));
      el.on('click', function () {
        var cs = new Tine.Tinebase.CreditsScreen();
        cs.show();
      });
    }, this);
    Tine.Tinebase.AboutDialog.superclass.initComponent.call(this);
  }
});

/***/ }),
/* 1423 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * Main appStarter/picker app pile panel
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.AppPile
 * @extends     Ext.Panel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.AppPile = Ext.extend(Ext.Panel, {
  /**
   * @property apps
   * @type Ext.util.Observable
   */
  apps: null,

  /**
   * @property defaultApp
   * @type Tine.Application
   */
  defaultApp: null,

  /**
   * @private
   * @property {Object} items
   * holds internal item elements
   */
  els: {},

  /**
   * @private
   */
  border: false,
  layout: 'fit',
  autoScroll: true,

  /**
   * @private
   * @todo: register app.on('titlechange', ...)
   */
  initComponent: function initComponent() {
    this.apps = Tine.Tinebase.appMgr.getAll();
    this.defaultApp = Tine.Tinebase.appMgr.getDefault();
    Tine.Tinebase.MainScreen.on('appactivate', this.onActivateApp, this);
    Tine.Tinebase.AppPile.superclass.initComponent.call(this);
    this.tpl = new Ext.XTemplate('<div class="x-panel-header x-panel-header-noborder x-unselectable x-accordion-hd">', '<img class="x-panel-inline-icon {iconCls}" src="' + Ext.BLANK_IMAGE_URL + '"/>', '<span class="x-panel-header-text app-panel-apptitle-text">{title}</span>', '</div>').compile();
  },

  /**
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.Tinebase.AppPile.superclass.onRender.call(this, ct, position);
    this.apps.each(function (app) {
      if (app.hasMainScreen) {
        this.els[app.appName] = this.tpl.insertFirst(this.body, {
          title: app.getTitle(),
          iconCls: app.getIconCls()
        }, true);
        this.els[app.appName].setStyle('cursor', 'pointer');
        this.els[app.appName].addClassOnOver('app-panel-header-over');
        this.els[app.appName].on('click', this.onAppTitleClick, this, app);
      }
    }, this); // limit to max pile height

    this.on('resize', function () {
      var appHeaders = Ext.DomQuery.select('div[class^=x-panel-header]', this.el.dom);

      for (var i = 0, height = 0; i < appHeaders.length; i++) {
        height += Ext.fly(appHeaders[i]).getHeight();
      }

      if (arguments[2] && arguments[2] > height) {
        this.setHeight(height);
      }
    });
    this.setActiveItem(this.els[this.defaultApp.appName]);
  },

  /**
   * executed when an app get activated by mainscreen
   * 
   * @param {Tine.Application} app
   */
  onActivateApp: function onActivateApp(app) {
    this.setActiveItem(this.els[app.appName]);
  },

  /**
   * @private
   */
  onAppTitleClick: function onAppTitleClick(e, dom, app) {
    this.setActiveItem(Ext.get(dom));
    Tine.Tinebase.MainScreen.activate(app);
  },

  /**
   * @private
   */
  setActiveItem: function setActiveItem(el) {
    for (var appName in this.els) {
      if (el) {
        if (el == this.els[appName] || el.parent() == this.els[appName]) {
          this.els[appName].addClass('app-panel-header-active');
        } else {
          this.els[appName].removeClass('app-panel-header-active');
        }
      }
    }
  }
});

/***/ }),
/* 1424 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');

__webpack_require__(1425);
/**
 * Main appStarter/picker tab panel
 * 
 * @todo discuss: have a set of default apps?
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.AppTabsPanel
 * @extends     Ext.TabPanel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */


Tine.Tinebase.AppTabsPanel = function (config) {
  Ext.apply(this, config);
  this.plugins = [new Ext.ux.TabPanelSortPlugin({
    dragZoneConfig: {
      onBeforeDrag: this.onBeforeDrag.createDelegate(this),
      scroll: false
    },
    dropZoneConfig: {
      getTargetFromEvent: this.getTargetFromEvent.createDelegate(this)
    }
  }), 'ux.tabpanelstripcompressorplugin'];
  Tine.Tinebase.AppTabsPanel.superclass.constructor.call(this, config);
};

Ext.extend(Tine.Tinebase.AppTabsPanel, Ext.TabPanel, {
  stateful: true,
  stateEvents: ['add', 'remove', 'tabchange', 'tabsort'],
  stateId: 'tinebase-mainscreen-apptabs',

  /**
   * @cfg {Array} of Strings currentTab ids
   */
  currentTabs: null,
  // private
  findTargets: function findTargets(e) {
    var item = null,
        itemEl = e.getTarget('li:not(.x-tab-edge)', this.strip);

    if (itemEl) {
      item = this.getComponent(itemEl.id.split(this.idDelimiter)[1]);

      if (item && item.disabled) {
        return {
          close: null,
          item: null,
          el: null
        };
      }
    }

    return {
      close: e.getTarget('.x-tab-strip-close', this.strip),
      item: item,
      el: itemEl
    };
  },

  /**
   * init appTabsPanel
   */
  initComponent: function initComponent() {
    Ext.apply(this, Ext.state.Manager.get(this.stateId));
    this.initMenu();
    this.items = [{
      id: this.app2id('menu'),
      title: Tine.title,
      iconCls: 'tine-favicon',
      closable: true,
      noCompress: true,
      listeners: {
        scope: this,
        beforeclose: this.onBeforeTabClose
      }
    }].concat(this.getDefaultTabItems()); // set states last active app to the sessions default app
    //Tine.Tinebase.appMgr.setDefault(this.id2appName(this.activeTab));

    Tine.Tinebase.MainScreen.on('appactivate', this.onActivateApp, this);
    this.on('beforetabchange', this.onBeforeTabChange, this);
    this.on('tabsort', this.onTabChange, this);
    this.on('add', this.onTabChange, this);
    this.on('remove', this.onTabChange, this);
    this.supr().initComponent.call(this); // fake an access stack

    for (var i = 1, tabCount = this.items.getCount(); i < tabCount; i++) {
      this.stack.add(this.items.get(i));
    }
  },
  setActiveTab: function setActiveTab(item) {
    this.supr().setActiveTab.apply(this, arguments);
    var appName = this.id2appName(item);

    if (appName !== 'menu') {
      var app = Tine.Tinebase.appMgr.get(appName),
          activeApp = Tine.Tinebase.MainScreen.getActiveApp();

      if (app != activeApp) {
        Tine.Tinebase.router.setRoute(app.getRoute());
      }
    }
  },

  /**
   * init the combined appchooser/tine menu
   */
  initMenu: function initMenu() {
    this.menu = new Ext.menu.Menu({
      layout: 'column',
      width: 400,
      autoHeight: true,
      style: {
        'background-image': 'none'
      },
      defaults: {
        xtype: 'menu',
        floating: false,
        columnWidth: 0.5,
        hidden: false,
        listeners: {
          scope: this,
          itemclick: function itemclick(item, e) {
            this.menu.hide();
          }
        },
        style: {
          //'border-color': 'transparent'
          'border': '0'
        }
      },
      items: [{
        items: this.getAppItems(),
        style: {
          'border-right': '1px solid #E2E2E3'
        }
      }, {
        plugins: [{
          ptype: 'ux.itemregistry',
          key: 'Tine.Tinebase.AppMenu.Additionals'
        }],
        items: Tine.Tinebase.MainScreen.getMainMenu().getMainActions()
      }]
    });
  },

  /**
   * executed after render
   */
  afterRender: function afterRender() {
    // no state from tab!
    this.activeTab = undefined;
    this.supr().afterRender.apply(this, arguments);
    this.menuTabEl = Ext.get(this.getTabEl(0));
    this.menuTabEl.addClass('tine-mainscreen-apptabspanel-menu-tabel'); // remove plain style

    this.header.removeClass('x-tab-panel-header-plain');
  },

  /**
   * get app items for the tabPanel
   * 
   * @return {Array}
   */
  getAppItems: function getAppItems() {
    var appItems = [];
    Tine.Tinebase.appMgr.getAll().each(function (app) {
      if (app.hasMainScreen) {
        appItems.push({
          text: app.getTitle(),
          iconCls: app.getIconCls(),
          handler: this.onAppItemClick.createDelegate(this, [app])
        });
      }
    }, this);
    return appItems.reverse();
  },

  /**
   * get default tab items configurations
   * 
   * @return {Array}
   */
  getDefaultTabItems: function getDefaultTabItems() {
    if (Ext.isEmpty(this.currentTabs)) {
      this.currentTabs = [this.id2appName(Tine.Tinebase.appMgr.getDefault())];
    }

    var tabItems = [];
    Ext.each(this.currentTabs, function (appName) {
      var app = Tine.Tinebase.appMgr.get(appName);

      if (app) {
        tabItems.push(this.getTabItem(app));
      }
    }, this);
    return tabItems;
  },

  /**
   * deny drag on menuEl
   * @param {} e
   * @return {}
   */
  onBeforeDrag: function onBeforeDrag(data, e) {
    return e.getTarget('li[class*=mainscreen-apptabspanel-menu-tabel]', 10) ? false : true;
  },

  /**
   * deny drop on menuEl
   * @param {} e
   * @return {}
   */
  getTargetFromEvent: function getTargetFromEvent(e) {
    var target = e.getTarget('ul[class^=x-tab]', 10),
        li = this.findTargets(e);

    if (li.el && li.el == this.menuTabEl.dom) {
      return false;
    }

    return target;
  },

  /**
   * get tabs state
   * 
   * @return {Object}
   */
  getState: function getState() {
    return {
      currentTabs: this.currentTabs,
      activeTab: Ext.isNumber(this.activeTab) ? this.activeTab : this.items.indexOf(this.activeTab)
    };
  },

  /**
   * get tab item configuration
   * 
   * @param {Tine.Application} app
   * @return {Object}
   */
  getTabItem: function getTabItem(app) {
    return {
      id: this.app2id(app),
      title: app.getTitle(),
      iconCls: app.getIconCls(),
      closable: true,
      listeners: {
        scope: this,
        beforeclose: this.onBeforeTabClose
      }
    };
  },

  /**
   * executed when an app get activated by mainscreen
   * 
   * @param {Tine.Application} app
   */
  onActivateApp: function onActivateApp(app) {
    var tab = this.getItem(this.app2id(app)) || this.add(this.getTabItem(app));
    this.setActiveTab(tab);
  },

  /**
   * executed when an app item in this.menu is clicked
   * 
   * @param {Tine.Application} app
   */
  onAppItemClick: function onAppItemClick(app) {
    Tine.Tinebase.MainScreen.activate(app);
    this.menu.hide();
  },

  /**
   * executed on tab changes
   * 
   * @param {TabPanel} this
   * @param {Panel} newTab The tab being activated
   * @param {Panel} currentTab The current active tab
   */
  onBeforeTabChange: function onBeforeTabChange(tp, newTab, currentTab) {
    if (this.id2appName(newTab) === 'menu') {
      this.menu.show.defer(10, this.menu, [this.menuTabEl, 'tl-bl']);
      return false;
    }
  },

  /**
   * executed before a tab panel is closed
   * 
   * @param {Ext.Panel} tab
   * @return {boolean}
   */
  onBeforeTabClose: function onBeforeTabClose(tab) {
    if (this.id2appName(tab) === 'menu') {
      return this.onBeforeTabChange(this, tab, this.activeTab);
    } // don't close last app panel


    return this.items.getCount() > 2;
  },

  /**
   * executed when tabs chages
   */
  onTabChange: function onTabChange() {
    var tabCount = this.items.getCount();
    var closable = tabCount > 2;
    this.currentTabs = [];

    for (var i = 1, tab, el; i < tabCount; i++) {
      tab = this.items.get(i); // update currentTabs

      this.currentTabs.push(this.id2appName(tab.id)); // handle closeables

      tab.closable = closable;
      el = this.getTabEl(i);

      if (el) {
        Ext.get(el)[closable ? 'addClass' : 'removeClass']('x-tab-strip-closable');
      }
    }
  },

  /**
   * returns appName of given tab/id
   * 
   * @param {Ext.Panel/String/Number} id
   * @return {String} appName
   */
  id2appName: function id2appName(id) {
    if (Ext.isNumber(id)) {
      if (Ext.isArray(this.items)) {
        id = this.items[id] ? this.items[id].id : null;
      } else {
        id = this.items.get(id);
      }
    }

    if (Ext.isObject(id) && !Ext.isEmpty(id)) {
      id = id.id;
    }

    if (Ext.isString(id)) {
      return id.split('-').pop();
    }

    return null;
  },

  /**
   * returns tab id of given app
   * @param {Tine.Application/String} app
   */
  app2id: function app2id(app) {
    var appName = app.appName || app;
    return this.id + '-' + appName;
  }
});

/***/ }),
/* 1425 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2018 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Ext.ux');
/**
 * @namespace   Ext.ux
 * @class       Ext.ux.TabPanelStripCompressorPlugin
 *
 * @constructor
 * @param {Object} config Configurations options
 */

Ext.ux.TabPanelStripCompressorPlugin = function (config) {
  Ext.apply(this, config);
};

Ext.ux.TabPanelStripCompressorPlugin.prototype = {
  /**
   * tabpanel
   * @type object
   */
  tabpanel: null,

  /**
   * init this plugin
   *
   * @param {Ext.Component} cmp
   */
  init: function init(cmp) {
    this.tabpanel = cmp;
    this.originalWidth = {};
    this.compressedWidth = {};
    this.compressed = [];
    this.tabpanel.on('render', this.onRender, this);
  },
  onRender: function onRender(tabpanel) {
    this.tabpanel.ownerCt.on('resize', this.onResize, this);
    this.tabpanel.on('add', this.onResize, this, {
      buffer: 100
    });
    this.tabpanel.on('remove', this.onResize, this, {
      buffer: 100
    });
    this.tabpanel.on('tabchange', this.onResize, this);
    this.onResize();
  },
  onResize: function onResize() {
    active = this.tabpanel.strip.down('li.x-tab-strip-active');

    if (active) {
      Ext.fly(active).child('.x-tab-strip-inner', true).style.width = 'auto';
      var w = Ext.fly(active).child('.x-tab-strip-inner').getWidth();
      Ext.fly(active).child('.x-tab-strip-inner', true).style.width = w + 'px';
    }

    var count = this.tabpanel.items.length,
        ce = this.tabpanel.tabPosition != 'bottom' ? 'header' : 'footer',
        ow = this.tabpanel[ce].dom.offsetWidth,
        aw = this.tabpanel[ce].dom.clientWidth,
        edge = this.tabpanel.strip.down('li.x-tab-edge').getBox().right,
        lis = this.tabpanel.strip.query('li:not(.x-tab-edge)');
    this.saveOriginalWidths(lis);

    if (edge > aw) {
      this.compress(lis, edge - aw);
    } else {
      this.expand(lis, aw - edge);
    }
  },
  compress: function compress(lis, by) {
    var _ = window.lodash,
        me = this,
        toCompress = me.getDynamic(lis),
        potential = _.reduce(toCompress, function (p, li) {
      return p.concat(Ext.fly(li).child('.x-tab-strip-inner', true).offsetWidth - 16);
    }, []),
        widths = me.getCompressedWidth(potential, by);

    _.each(toCompress, function (li, i) {
      var inner = Ext.fly(li).child('.x-tab-strip-inner', true);
      inner.style.width = 16 + widths[i] + 'px';
    });
  },
  expand: function expand(lis, by) {
    var _ = window.lodash,
        me = this,
        toExpand = me.getDynamic(lis),
        potential = _.reduce(toExpand, function (p, li) {
      var originalWidth = me.originalWidth[li.id];
      return p.concat(Math.max(0, originalWidth - Ext.fly(li).child('.x-tab-strip-inner', true).offsetWidth));
    }, []),
        widths = me.getExpandWidth(potential, by);

    _.each(toExpand, function (li, i) {
      var originalWidth = me.originalWidth[li.id],
          inner = Ext.fly(li).child('.x-tab-strip-inner', true);
      inner.style.width = originalWidth - widths[i] + 'px';
    });
  },
  // beginn with largest
  getCompressedWidth: function getCompressedWidth(potential, by) {
    var _ = window.lodash,
        used = 0,
        map = _.groupBy(potential),
        sorted = _.uniq([].concat(potential).sort(function (a, b) {
      return a - b;
    })),
        currWidth = sorted[sorted.length - 1],
        currWidhtCount = map[currWidth].length,
        d = Math.min(by, sorted.length > 1 ? (sorted[sorted.length - 1] - sorted[sorted.length - 2]) * currWidhtCount : sorted[0] * currWidhtCount),
        widths = _.map(potential, function (w) {
      var newWidth = w;

      if (w == currWidth) {
        newWidth = w - d / currWidhtCount;
        used += w - newWidth;
      }

      return newWidth;
    });

    if (used < by && _.sum(widths) && used > 1) {
      // console.warn('widths: ' + widths + ' by: ' + by + ' used: ' + used)
      return this.getCompressedWidth(widths, by - used);
    }

    return widths;
  },
  // expand aquidistantly (all with potential at the same rate)
  getExpandWidth: function getExpandWidth(potential, by) {
    var _ = window.lodash,
        used = 0,
        sorted = _.compact(_.uniq([].concat(potential).sort(function (a, b) {
      return a - b;
    }))),
        expandCount = sorted.length,
        currWidth = sorted[0],
        d = Math.min(by / expandCount, currWidth),
        widths = _.map(potential, function (w) {
      var newWidth = w;

      if (w) {
        newWidth = w - d;
        used += d;
      }

      return newWidth;
    });

    if (used < by && _.sum(widths) && used > 1) {
      // console.warn('widths: ' + widths + ' by: ' + by + ' used: ' + used)
      return this.getExpandWidth(widths, by - used);
    }

    return widths;
  },
  getDynamic: function getDynamic(lis) {
    var _ = window.lodash,
        me = this;
    return _.filter(lis, function (li) {
      return !me.tabpanel.get(li.id.split('__')[1]).noCompress && !Ext.fly(li).hasClass('x-tab-strip-active');
    });
  },
  saveOriginalWidths: function saveOriginalWidths(lis) {
    for (var i = 0, len = lis.length; i < len; i++) {
      if (!this.originalWidth[lis[i].id] && !Ext.fly(lis[i]).hasClass('x-tab-strip-active')) {
        var text = Ext.fly(lis[i]).child('.x-tab-strip-text', true);
        this.originalWidth[lis[i].id] = text.offsetWidth;
      }
    }
  }
};
Ext.preg('ux.tabpanelstripcompressorplugin', Ext.ux.TabPanelStripCompressorPlugin);

/***/ }),
/* 1426 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
Tine.Tinebase.MainContextMenu = Ext.extend(Ext.menu.Menu, {
  /**
   * context component
   * @property {Ext.Component}
   */
  context: null,
  initComponent: function initComponent() {
    this.plugins = [{
      ptype: 'ux.itemregistry',
      key: 'Tinebase-MainContextMenu'
    }];
    this.items = [];
    this.supr().initComponent.call(this);
  },
  onRender: function onRender() {
    // hide fist separator
    var firstItem = this.items.get(0);

    if (firstItem && firstItem.isXType('menuseparator')) {
      this.items.get(0).hide();
    }

    this.supr().onRender.call(this);
  },
  onHide: function onHide() {
    if (this.isVisible() && Ext.isFunction(Ext.EventObject.getSignature)) {
      Tine.Tinebase.MainContextMenu.hideEventSignature = Ext.EventObject.getSignature();
    }

    this.supr().onHide.call(this);
  }
});
/**
 * show main/global context menu if it has itmes
 *
 * @static
 * @param {Ext.EventObject} e
 * @returns {Ext.Component}
 */

Tine.Tinebase.MainContextMenu.showIf = function (e) {
  var menu = Tine.Tinebase.MainContextMenu.menu = new Tine.Tinebase.MainContextMenu({});

  if (menu.items.length) {
    menu.showAt(e.getXY());
    return menu;
  }
};
/**
 * get main context items
 *
 * @static
 * @param {Ext.EventObject} e
 * @returns {Ext.util.MixedCollection}
 */


Tine.Tinebase.MainContextMenu.getItems = function (e) {
  var menu = Tine.Tinebase.MainContextMenu.menu = new Tine.Tinebase.MainContextMenu({});
  return menu.items;
};
/**
 * get target component
 *
 * @static
 * @param {Ext.EventObject} e
 * @returns {Ext.Component}
 */


Tine.Tinebase.MainContextMenu.getCmp = function (e) {
  var target = e && e.target ? e.getTarget('[id^=ext-comp]', 30) : null,
      component = target ? Ext.ComponentMgr.get(target.id) : null;
  return component;
};

Tine.Tinebase.MainContextMenu.isVisible = function () {
  return Tine.Tinebase.MainContextMenu.hideEventSignature && Tine.Tinebase.MainContextMenu.hideEventSignature == Ext.EventObject.getSignature();
};

Tine.Tinebase.MainContextMenu.hide = function () {
  if (Tine.Tinebase.MainContextMenu.menu && Tine.Tinebase.MainContextMenu.menu.hide) {
    Tine.Tinebase.MainContextMenu.menu.hide();
  }
};

/***/ }),
/* 1427 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2011 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * Tine 2.0 jsclient main menu
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.MainMenu
 * @extends     Ext.Toolbar
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
  /**
   * @cfg {Boolean} showMainMenu
   */
  showMainMenu: false,
  style: {
    'padding': '0px 2px'
  },
  cls: 'tbar-mainmenu',

  /**
   * @type Array
   * @property mainActions
   */
  mainActions: null,
  initComponent: function initComponent() {
    this.initActions();
    this.onlineStatus = new Ext.ux.ConnectionStatus({
      showIcon: true,
      showText: false
    });
    this.items = this.getItems();
    var buttonTpl = new Ext.Template('<table id="{4}" cellspacing="0" class="x-btn {3}"><tbody class="{1}">', '<tr><td class="x-btn-ml"><i>&#160;</i></td><td class="x-btn-mc"><em class="{2}" unselectable="on"><button type="{0}"></button></em></td><td class="x-btn-mr"><i>&#160;</i></td></tr>', '</tbody></table>').compile();
    Ext.each(this.items, function (item) {
      item.template = buttonTpl;
    }, this);
    this.plugins = this.plugins || [];
    this.plugins.push({
      ptype: 'ux.itemregistry',
      key: 'Tine.Tinebase.MainMenu'
    });
    this.supr().initComponent.call(this);
  },
  getItems: function getItems() {
    return [{
      text: Tine.title,
      hidden: !this.showMainMenu,
      menu: {
        id: 'Tinebase_System_Menu',
        items: this.getMainActions()
      }
    }, '->', // removed in tine20.com
    //this.actionLearnMore,
    this.actionLicenseExpire, // TODO add a bigger spacer here?
    {
      xtype: 'spacer'
    }, {
      text: Ext.util.Format.htmlEncode(String.format(i18n._('User: {0}'), Tine.Tinebase.registry.get('currentAccount').accountDisplayName)),
      menu: this.getUserActions(),
      menuAlign: 'tr-br',
      iconCls: 'tine-grid-row-action-icon ' + (Tine.Tinebase.registry.get('userAccountChanged') ? 'renderer_accountUserChangedIcon' : 'renderer_accountUserIcon')
    }, this.onlineStatus, this.action_logout];
  },

  /**
   * returns all main actions
   * 
   * @return {Array}
   */
  getMainActions: function getMainActions() {
    if (!this.mainActions) {
      this.mainActions = [this.action_aboutTine, this.action_userManual, '-', this.getUserActions(), '-', this.action_logout];

      if (Tine.Tinebase.registry.get("version").buildType.match(/(DEVELOPMENT|DEBUG)/)) {
        this.mainActions.splice(2, 0, '-', this.action_showDebugConsole);
      }
    }

    return this.mainActions;
  },
  getUserActions: function getUserActions() {
    if (!this.userActions) {
      this.userActions = [this.action_editProfile, this.action_showPreferencesDialog, this.action_notificationPermissions, this.action_changePassword];

      if (Tine.Tinebase.registry.get('secondFactorPinChangeAllowed')) {
        this.userActions = this.userActions.concat(this.action_changePin);
      }

      if (Tine.Tinebase.registry.get('userAccountChanged')) {
        this.action_returnToOriginalUser = new Tine.widgets.account.ChangeAccountAction({
          returnToOriginalUser: true,
          text: i18n._('Return to original user account')
        });
        this.userActions = this.userActions.concat(this.action_returnToOriginalUser);
      } else if (Tine.Tinebase.registry.get("config") && Tine.Tinebase.registry.get("config").roleChangeAllowed && Tine.Tinebase.registry.get("config").roleChangeAllowed.value) {
        this.action_changeUserAccount = new Tine.widgets.account.ChangeAccountAction({});
        var roleChangeAllowed = Tine.Tinebase.registry.get("config").roleChangeAllowed.value,
            currentAccountName = Tine.Tinebase.registry.get('currentAccount').accountLoginName;

        if (roleChangeAllowed[currentAccountName]) {
          this.userActions = this.userActions.concat(this.action_changeUserAccount);
        }
      }

      var regItems = Ext.ux.ItemRegistry.itemMap['Tine.Tinebase.MainMenu.userActions'] || [];
      Ext.each(regItems, function (reg) {
        var addItem = reg.item;
        this.userActions.push(addItem);
      }, this);
    }

    return this.userActions;
  },

  getActionByPos(registerItemPosition) {
    return _.filter(this.items.items, item => {
      return (item === null || item === void 0 ? void 0 : item.registerdItemPos) === registerItemPosition;
    });
  },

  /**
   * initialize actions
   * @private
   */
  initActions: function initActions() {
    this.action_aboutTine = new Ext.Action({
      text: String.format(i18n._('About {0}'), Tine.title),
      handler: this.onAboutTine20,
      iconCls: 'action_about'
    });
    this.action_userManual = new Ext.Action({
      text: String.format(i18n._('Help')),
      iconCls: 'action_userManual',
      handler: this.onShowHelp,
      hidden: Tine.Tinebase.common.hasRight('run', 'UserManual'),
      scope: this
    });
    this.action_showDebugConsole = new Ext.Action({
      text: i18n._('Debug Console (Ctrl + F11)'),
      handler: Tine.Tinebase.common.showDebugConsole,
      iconCls: 'tinebase-action-debug-console'
    });
    this.action_showPreferencesDialog = new Ext.Action({
      text: i18n._('Preferences'),
      disabled: false,
      handler: this.onEditPreferences,
      iconCls: 'action_adminMode'
    });
    this.action_editProfile = new Ext.Action({
      text: i18n._('Edit Profile'),
      disabled: !Tine.Tinebase.common.hasRight('manage_own_profile', 'Tinebase'),
      handler: this.onEditProfile,
      iconCls: 'tinebase-accounttype-user'
    });
    this.action_changePassword = new Ext.Action({
      text: i18n._('Change password'),
      handler: this.onChangePassword,
      disabled: !Tine.Tinebase.configManager.get('changepw'),
      iconCls: 'action_password'
    });
    this.action_changePin = new Ext.Action({
      text: i18n._('Change PIN'),
      handler: this.onChangePin,
      //disabled: (! Tine.Tinebase.configManager.get('changepin')),
      iconCls: 'action_password'
    });
    this.action_logout = new Ext.Action({
      text: i18n._('Logout'),
      tooltip: String.format(i18n._('Logout from {0}'), Tine.title),
      iconCls: 'action_logOut',
      handler: this.onLogout,
      scope: this
    });
    this.actionLearnMore = new Ext.Action({
      text: String.format(i18n._('Learn more about {0}'), Tine.title),
      tooltip: Tine.weburl,
      iconCls: 'tine-favicon',
      handler: function handler() {
        window.open(Tine.weburl, '_blank');
      },
      scope: this
    });
    var licenseExpiresIn = Tine.Tinebase.registry.get('licenseExpire'),
        // TODO move this to the license definitions on the server?
    licenseExpiresInThreshold = 90,
        licenseExpiresInThresholdRed = 14,
        licenseExpiredSince = Tine.Tinebase.registry.get('licenseExpiredSince');
    this.actionLicenseExpire = '';

    if (Tine.Tinebase.common.hasRight('show_license_info', 'Tinebase')) {
      if (licenseExpiresIn && licenseExpiresIn < licenseExpiresInThreshold) {
        this.actionLicenseExpire = new Ext.Action({
          text: String.format(i18n._('The license expires in {0} days'), licenseExpiresIn),
          tooltip: String.format(i18n._('Please visit the shop at {0}'), Tine.shop),
          iconCls: licenseExpiresIn < licenseExpiresInThresholdRed ? 'tine-license-red' : 'tine-license',
          handler: function handler() {
            window.open(Tine.shop, '_blank');
          },
          scope: this
        });
      } else if (licenseExpiredSince) {
        this.actionLicenseExpire = new Ext.Action({
          text: i18n._('Your Tine 2.0 Business Edition expired.'),
          tooltip: String.format(i18n._('Please visit the shop at {0}'), Tine.shop),
          iconCls: 'tine-license',
          handler: function handler() {
            window.open(Tine.shop, '_blank');
          },
          scope: this
        });
      }
    }

    this.action_notificationPermissions = new Ext.Action({
      text: i18n._('Allow desktop notifications'),
      tooltip: i18n._('Request permissions for webkit desktop notifications.'),
      iconCls: 'action_edit',
      disabled: !window.Notification || this.systemTrayNotificationsEnabled(),
      handler: this.requestNotificationPermission,
      scope: this
    });
  },
  systemTrayNotificationsEnabled: function systemTrayNotificationsEnabled() {
    return window.Notification && window.Notification.permission == 'granted';
  },
  requestNotificationPermission: function requestNotificationPermission() {
    window.Notification.requestPermission(Ext.emptyFn);
  },

  /**
   * open new window/tab to show help and tutorial
   */
  onShowHelp: function onShowHelp() {
    window.open(Tine.helpUrl, '_blank');
  },

  /**
   * @private
   */
  onAboutTine20: function onAboutTine20() {
    var aboutDialog = new Tine.Tinebase.AboutDialog();
    aboutDialog.show();
  },

  /**
   * @private
   */
  onChangePassword: function onChangePassword() {
    var passwordDialog = new Tine.Tinebase.PasswordChangeDialog();
    passwordDialog.show();
  },

  /**
   * @private
   */
  onChangePin: function onChangePin() {
    var passwordDialog = new Tine.Tinebase.PasswordChangeDialog({
      pwType: 'pin'
    });
    passwordDialog.show();
  },

  /**
   * @private
   */
  onEditPreferences: function onEditPreferences() {
    Tine.widgets.dialog.Preferences.openWindow({});
  },

  /**
   * @private
   */
  onEditProfile: function onEditProfile() {
    Tine.widgets.dialog.Preferences.openWindow({
      initialCardName: 'Tinebase.UserProfile'
    });
  },

  /**
   * the logout button handler function
   * @private
   */
  onLogout: function onLogout() {
    if (Tine.Tinebase.registry.get('confirmLogout') != '0') {
      Ext.MessageBox.confirm(i18n._('Confirm'), i18n._('Are you sure you want to logout?'), function (btn, text) {
        if (btn == 'yes') {
          this._doLogout();
        }
      }, this);
    } else {
      this._doLogout();
    }
  },

  /**
   * logout user & redirect
   * @static
   */
  _doLogout: async function _doLogout() {
    Ext.MessageBox.wait(i18n._('Logging you out...'), i18n._('Please wait!'));
    const response = await Tine.Tinebase.logout(); // clear the authenticated mod_ssl session

    if (window.crypto && Ext.isFunction(window.crypto.logout)) {
      window.crypto.logout();
    }

    if (response.logoutUrls) {
      const {
        ssoLogout
      } = await __webpack_require__.e(/* import() | SSO/js/logout */ 22).then(__webpack_require__.bind(null, 29));
      await ssoLogout(response);
    }

    return await Tine.Tinebase.common.reload({
      clearCache: true,
      redirectAlways: Tine.Tinebase.configManager.get('redirectAlways'),
      redirectUrl: Tine.Tinebase.configManager.get('redirectUrl')
    });
  }
});

/***/ }),
/* 1428 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase');
/**
 * Tine 2.0 jsclient MainScreen with app selection, menu etc.
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.MainScreenPanel
 * @extends     Ext.Container
 * @singleton   
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.MainScreen = null;

Tine.Tinebase.MainScreenPanel = function (config) {
  this.addEvents(
  /**
   * @event beforeappappactivate
   * fired before an application gets appactivated. Retrun false to stop activation
   * @param {Tine.Aplication} app about to appactivate
   */
  'beforeappappactivate',
  /**
   * @event appactivate
   * fired when an application gets appactivated
   * @param {Tine.Aplication} appactivated app
   */
  'appactivate',
  /**
   * @event beforeappappdeactivate
   * fired before an application gets appdeactivated. Retrun false to stop deactivation
   * @param {Tine.Aplication} app about to appdeactivate
   */
  'beforeappappdeactivate',
  /**
   * @event appdeactivate
   * fired when an application gets appdeactivated
   * @param {Tine.Aplication} appdeactivated app
   */
  'appdeactivate',
  /**
   * @event windowopenexception
   * windowopenexceptionated
   * @param {} Exception
   */
  'windowopenexception'); // NOTE: this is a cruid method to create some kind of singleton...

  Tine.Tinebase.MainScreen = this;
  Tine.Tinebase.MainScreenPanel.superclass.constructor.call(this, config);
};

Ext.extend(Tine.Tinebase.MainScreenPanel, Ext.Container, {
  border: false,
  layout: {
    type: 'vbox',
    align: 'stretch',
    padding: '0'
  },

  /**
   * the active app
   * @type {Tine.Tinebase.Application}
   */
  app: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.initLayout();
    this.supr().initComponent.apply(this, arguments);
  },

  /**
   * @private
   */
  initLayout: function initLayout() {
    this.items = [{
      ref: 'topBox',
      cls: 'tine-mainscreen-topbox',
      border: false,
      html: '<div class="tine-mainscreen-topbox-left"></div><div class="tine-mainscreen-topbox-middle"></div><div class="tine-mainscreen-topbox-right"></div>'
    }, {
      cls: 'tine-mainscreen-mainmenu',
      height: 20,
      layout: 'fit',
      border: false,
      items: this.getMainMenu()
    }, {
      ref: 'appTabs',
      cls: 'tine-mainscreen-apptabs',
      hidden: this.hideAppTabs,
      border: false,
      height: 30,
      items: new Tine.Tinebase.AppTabsPanel({
        plain: true
      })
    }, {
      ref: 'centerPanel',
      cls: 'tine-mainscreen-centerpanel',
      flex: 1,
      border: false,
      layout: 'card'
    }];
  },

  /**
   * returns main menu
   * 
   * @return {Ext.Menu}
   */
  getMainMenu: function getMainMenu() {
    if (!this.mainMenu) {
      this.mainMenu = new Tine.Tinebase.MainMenu({
        showMainMenu: false
      });
    }

    return this.mainMenu;
  },

  /**
   * returns center (card) panel
   *
   * @returns {Ext.Panel}
   */
  getCenterPanel: function getCenterPanel() {
    return this.centerPanel;
  },

  /**
   * appMgr app activation listener
   * 
   * @param {Tine.Application} app
   */
  onAppActivate: function onAppActivate(app) {
    Tine.log.info('Activating app ' + app.appName);
    this.app = app; // set document / browser title

    var postfix = Tine.Tinebase.registry.get('titlePostfix') ? Tine.Tinebase.registry.get('titlePostfix') : '',
        // some apps (Felamimail atm) can add application specific title postfixes
    // TODO generalize this
    appPostfix = document.title.match(/^\([0-9]+\) /) ? document.title.match(/^\([0-9]+\) /)[0] : '';
    document.title = Ext.util.Format.stripTags(appPostfix + Tine.title + postfix + ' - ' + app.getTitle());
  },

  /**
   * executed after rendering process
   * 
   * @private
   */
  afterRender: function afterRender() {
    this.supr().afterRender.apply(this, arguments);
    var expiredSince = Tine.Tinebase.registry.get('licenseExpiredSince');

    if (expiredSince && expiredSince != false) {
      var licensePopup = new Ext.Window({
        title: i18n._('License expired'),
        layout: 'fit',
        width: 500,
        height: 100,
        closable: false,
        items: new Ext.Panel({
          html: i18n._('Your Tine 2.0 Business Edition license expired. Please buy a license at:') + '<br/><a target="_blank" href="' + Tine.shop + '" border="0"> Tine 2.0 Shop </a></ul>'
        }),
        buttons: [{
          text: 'Close',
          disabled: true,
          handler: function handler(ev) {
            licensePopup.hide();
          },
          listeners: {
            afterrender: function afterrender(btn) {
              setTimeout(function () {
                btn.setDisabled(false);
              }, expiredSince * 1000);
            }
          }
        }]
      });
      licensePopup.show();
    } // check for new version
    // TODO add helper function for fetching config ... this condition sucks.


    if ((!Tine.Tinebase.registry.get("config") || !Tine.Tinebase.registry.get("config").versionCheck || Tine.Tinebase.registry.get("config").versionCheck.value) && Tine.Tinebase.common.hasRight('check_version', 'Tinebase')) {
      Tine.widgets.VersionCheck();
    }

    if (Tine.Tinebase.registry.get('mustchangepw')) {
      var passwordDialog = new Tine.Tinebase.PasswordChangeDialog({
        title: i18n._('Your password expired. Please enter a new user password:')
      });
      passwordDialog.show();
    }
  },

  /**
   * activate application
   *
   * @param {Tine.Application} app
   * @return {Boolean}
   */
  activate: function activate(app) {
    if (app) {
      // activation via routing only
      if (Tine.Tinebase.router.getRoute()[0] != app.appName) {
        Tine.Tinebase.router.setRoute(app.getRoute());
        return;
      }

      if (app == this.getActiveApp()) {
        // app is already active, nothing to do
        return true;
      }

      if (this.app) {
        if (this.fireEvent('beforeappappdeactivate', this.app) === false || this.app.onBeforeDeActivate() === false) {
          return false;
        }

        this.app.onDeActivate();
        this.fireEvent('appdeactivate', this.app);
        this.app = null;
      }

      if (this.fireEvent('beforeappappactivate', app) === false || app.onBeforeActivate() === false) {
        return false;
      }

      this.setActiveCenterPanel(app.getMainScreen(), true);
      this.app = app;
      this.onAppActivate(app);
      app.onActivate();
      this.fireEvent('appactivate', app);
    } else {
      app = Tine.Tinebase.appMgr.getDefault();
      Tine.Tinebase.router.setRoute(app.getRoute());
    }
  },

  /**
   * returns currently activated app
   * @return {Tine.Application}
   */
  getActiveApp: function getActiveApp() {
    return this.app;
  },

  /**
   * set the active center panel
   * @param panel
   */
  setActiveCenterPanel: function setActiveCenterPanel(panel, keep) {
    if (panel.app) {
      // neede for legacy handling
      this.app = panel.app;
    }

    var cardPanel = this.getCenterPanel();
    Ext.ux.layout.CardLayout.helper.setActiveCardPanelItem(cardPanel, panel, keep);
  },

  /**
   * sets the active content panel
   *
   * @deprecated
   * @param {Ext.Panel} item Panel to activate
   * @param {Bool} keep keep panel
   */
  setActiveContentPanel: function setActiveContentPanel(panel, keep) {
    Tine.log.warn('Tine.Tinebase.MainScreenPanel.setActiveContentPanel is deprecated, use <App>.Mainscreen.setActiveContentPanel instead ' + new Error().stack);
    return this.app.getMainScreen().setActiveContentPanel(panel, keep);
  },

  /**
   * sets the active tree panel
   *
   * @deprecated
   * @param {Ext.Panel} panel Panel to activate
   * @param {Bool} keep keep panel
   */
  setActiveTreePanel: function setActiveTreePanel(panel, keep) {
    Tine.log.warn('Tine.Tinebase.MainScreenPanel.setActiveTreePanel is deprecated, use <App>.Mainscreen.setActiveTreePanel instead ' + new Error().stack);
    return this.app.getMainScreen().setActiveTreePanel(panel, keep);
  },

  /**
   * sets the active module tree panel
   *
   * @deprecated
   * @param {Ext.Panel} panel Panel to activate
   * @param {Bool} keep keep panel
   */
  setActiveModulePanel: function setActiveModulePanel(panel, keep) {
    Tine.log.warn('Tine.Tinebase.MainScreenPanel.setActiveModulePanel is deprecated, use <App>.Mainscreen.setActiveModulePanel instead ' + new Error().stack);
    return this.app.getMainScreen().setActiveModulePanel(panel, keep);
  },

  /**
   * sets item
   *
   * @deprecated
   * @param {Ext.Toolbar} panel toolbar to activate
   * @param {Bool} keep keep panel
   */
  setActiveToolbar: function setActiveToolbar(panel, keep) {
    Tine.log.warn('Tine.Tinebase.MainScreenPanel.setActiveToolbar is deprecated, use <App>.Mainscreen.setActiveToolbar instead ' + new Error().stack);
    return this.app.getMainScreen().setActiveToolbar(panel, keep);
  },

  /**
   * gets the currently displayed toolbar
   *
   * @deprecated
   * @return {Ext.Toolbar}
   */
  getActiveToolbar: function getActiveToolbar() {
    Tine.log.warn('Tine.Tinebase.MainScreenPanel.getActiveToolbar is deprecated, use <App>.Mainscreen.getActiveToolbar instead ' + new Error().stack);
    return this.app.getMainScreen().getActiveToolbar();
  }
});
/**
 * lazy mainscreen init
 *
 * @static
 * @param app
 */

Tine.Tinebase.MainScreenPanel.show = function (app) {
  var mainCardPanel = Tine.Tinebase.viewport.tineViewportMaincardpanel;

  if (!Tine.Tinebase.MainScreen) {
    new Tine.Tinebase.MainScreenPanel();
    mainCardPanel.add(Tine.Tinebase.MainScreen);
    mainCardPanel.layout.setActiveItem(Tine.Tinebase.MainScreen.id);
    Tine.Tinebase.MainScreen.doLayout();
  }

  Tine.Tinebase.MainScreen.activate(app);
};

/***/ }),
/* 1429 */
/***/ (function(module, exports) {

/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2009-2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine*/
Ext.ns('Tine.Tinebase');
/**
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.LoginPanel
 * @extends     Ext.Panel
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
  /**
   * @cfg {String} defaultUsername prefilled username
   */
  defaultUsername: '',

  /**
   * @cfg {String} defaultPassword prefilled password
   */
  defaultPassword: '',

  /**
   * @cfg {String}
   * translated heads up text
   */
  headsUpText: '',

  /**
   * @cfg {String} loginMethod server side login method
   */
  loginMethod: 'Tinebase.login',

  /**
   * @cfg {String} onLogin callback after successful login
   */
  onLogin: Ext.emptyFn,

  /**
   * @cfg {Boolean} show infobox (survey, links, text)
   */
  showInfoBox: true,

  /**
   * @cfg {String} scope scope of login callback
   */
  scope: null,
  layout: 'fit',
  border: false,

  /**
   * return loginPanel
   * 
   * @return {Ext.FormPanel}
   */
  getLoginPanel: function getLoginPanel() {
    //Do we have a custom Logo for branding?
    var modSsl = Tine.Tinebase.registry.get('modSsl'),
        logo = Tine.installLogo;

    if (!this.loginPanel) {
      this.loginPanel = new Ext.Container({
        getForm: function getForm() {
          return this.items.get(0).getForm();
        },
        layout: 'vbox',
        width: 320,
        height: 450,
        layoutConfig: {
          align: 'stretch'
        },
        items: [new Ext.FormPanel({
          height: 210,
          frame: true,
          labelWidth: 90,
          cls: 'tb-login-panel',
          items: [{
            xtype: 'label',
            cls: 'tb-login-big-label',
            text: i18n._('Login')
          }, {
            xtype: 'tinelangchooser',
            name: 'locale',
            width: 170,
            tabindex: 1
          }, {
            xtype: 'textfield',
            tabindex: 2,
            width: 170,
            fieldLabel: i18n._('Username'),
            name: 'username',
            allowBlank: modSsl ? false : true,
            validateOnBlur: false,
            selectOnFocus: true,
            value: this.defaultUsername ? this.defaultUsername : undefined,
            disabled: modSsl ? true : false,
            listeners: {
              scope: this,
              render: function render(field) {
                field.el.dom.setAttribute('autocapitalize', 'none');
                field.el.dom.setAttribute('autocorrect', 'off');

                if (Ext.supportsUserFocus) {
                  field.focus(false, 250);
                }
              },
              focus: function focus(field) {
                if (Ext.isTouchDevice) {
                  Ext.getBody().dom.scrollTop = this.loginPanel.getBox()['y'] - 10;
                }
              }
            }
          }, {
            xtype: 'tw-passwordTriggerField',
            allowBrowserPasswordManager: this.allowBrowserPasswordManager,
            unLockable: !this.allowBrowserPasswordManager,
            clipboard: false,
            tabindex: 3,
            width: 170,
            fieldLabel: i18n._('Password'),
            name: 'password',
            selectOnFocus: true,
            value: this.defaultPassword,
            disabled: modSsl ? true : false,
            listeners: {
              render: this.setLastLoginUser.createDelegate(this)
            }
          }, {
            xtype: 'displayfield',
            style: {
              align: 'center',
              marginTop: '10px'
            },
            value: i18n._('Certificate detected. Please, press Login button to proceed.'),
            hidden: modSsl ? false : true
          }, {
            xtype: 'container',
            layout: 'hbox',
            items: [{
              width: 95
            }, {
              xtype: 'button',
              width: 170,
              text: i18n._('Login'),
              scope: this,
              handler: this.onLoginPress
            }]
          }, {
            xtype: 'container',
            style: 'padding-top: 2px',
            layout: 'hbox',
            hidden: !Tine.Tinebase.registry.get('sso'),
            items: [{
              width: 95
            }, {
              xtype: 'button',
              width: 170,
              text: i18n._('Login via OpenID Connect'),
              scope: this,
              handler: this.onOIDCLoginPress
            }]
          }]
        }), {
          xtype: 'container',
          style: 'height: 5px;'
        }, {
          xtype: 'container',
          cls: 'tb-login-lobobox',
          border: false,
          html: '<div class="tb-login-headsup-box">' + this.headsUpText + '</div><a target="_blank" href="' + Tine.websiteUrl + '" border="0"><img src="' + logo + '" /></a>'
        }, {
          xtype: 'container',
          style: 'height: 5px;'
        }, {
          xtype: 'container',
          hidden: !this.infoText,
          cls: 'tb-login-infotext',
          border: false,
          html: this.infoText
        }]
      });
    }

    return this.loginPanel;
  },
  setLastLoginUser: function setLastLoginUser(field) {
    var lastUser;
    lastUser = Ext.util.Cookies.get('TINE20LASTUSERID');

    if (lastUser) {
      this.loginPanel.getForm().findField('username').setValue(lastUser);
      field.focus(false, 250);
    }
  },
  getVersionPanel: function getVersionPanel() {
    if (!this.versionPanel) {
      var version = Tine.Tinebase.registry.get('version') ? Tine.Tinebase.registry.get('version') : {
        codeName: 'unknown',
        packageString: 'unknown'
      };
      var versionHtml = '<label class="tb-version-label">' + i18n._('Version') + ':</label> ' + '<label class="tb-version-codename">' + version.codeName + '</label> ' + '<label class="tb-version-packagestring">(' + version.packageString + ')</label>';
      this.versionPanel = new Ext.Container({
        layout: 'fit',
        cls: 'tb-version-tinepanel',
        border: false,
        defaults: {
          xtype: 'label'
        },
        items: [{
          html: versionHtml
        }]
      });
    }

    return this.versionPanel;
  },
  getCommunityPanel: function getCommunityPanel() {
    if (!this.communityPanel) {
      var translationPanel = [],
          stats = Tine.__translationData.translationStats,
          version = Tine.clientVersion.packageString.match(/\d+\.\d+\.\d+/),
          language = Tine.Tinebase.registry.get('locale').language,
          // TODO make stats work again (currently displays 100% for all langs)
      //percentageCompleted =  stats ? Math.floor(100 * stats.translated / stats.total) : undefined;
      percentageCompleted = undefined;
      this.communityPanel = new Ext.Container({
        layout: 'fit',
        cls: 'tb-login-tinepanel',
        border: false,
        defaults: {
          xtype: 'label'
        },
        items: [{
          cls: 'tb-login-big-label',
          html: String.format(i18n._('{0} is made for you'), Tine.title)
        }, {
          html: '<p>' + String.format(i18n._('{0} wants to make business collaboration easier and more enjoyable - for your needs! So you are warmly welcome to discuss with us, bring in ideas and get help.'), Tine.title) + '</p>'
        }, {
          cls: 'tb-login-big-label-spacer',
          html: '&nbsp;'
        }, {
          html: '<ul>' + '<li><a target="_blank" href="' + Tine.weburl + '" border="0">' + String.format(i18n._('{0} Homepage'), Tine.title) + '</a></li>' + '</ul><br/>'
        }, {
          cls: 'tb-login-big-label',
          html: i18n._('Translations')
        }, {
          html: Ext.isDefined(percentageCompleted) ? '<p>' + String.format(i18n._('Translation state of {0}: {1}%.'), language, percentageCompleted) + '</p>' : ''
        }, {
          html: '<p>' + String.format(i18n._('If the state of your language is not satisfying, or if you miss a language, please consider becoming a {0} translator.'), Tine.title) + '</p>'
        }, {
          html: '<br/><ul>' + '<li><a target="_blank" href="https://github.com/tine20/Tine-2.0-Open-Source-Groupware-and-CRM/wiki/EN%3Atranslation-Howto" border="0">' + String.format(i18n._('{0} Translation Howto'), Tine.title) + '</a></li>' + '<li><a target="_blank" href="https://www.transifex.com/projects/p/tine20/" border="0">' + i18n._('Detailed Language Statistics') + '</a></li>' + '</ul>'
        }]
      });
    }

    return this.communityPanel;
  },
  getLicenseInformationPanel: function getLicenseInformationPanel() {
    if (!this.licensePanel) {
      var items = [];
      var licenseCheck = Tine.Tinebase.registry.get('licenseStatus');

      if (licenseCheck === 'status_no_license_available' || licenseCheck === 'status_license_invalid') {
        // EXPIRED!
        let licenseFailed = [{
          cls: 'tb-login-big-label',
          html: licenseCheck === 'status_license_invalid' ? i18n._('Your Tine 2.0 Business Edition expired.') : i18n._('Tine 2.0 Business Edition trial')
        }, {
          html: '<p>' + (licenseCheck === 'status_license_invalid' ? i18n._('Your Tine 2.0 Business Edition license is expired! Users cannot login any more. Please contact Metaways Infosystems GmbH to buy a new license.') : i18n._('Please contact Metaways Infosystems GmbH to buy a valid license.'))
        }];
        items = licenseFailed.concat(items);
      }

      this.licensePanel = new Ext.Container({
        layout: 'fit',
        cls: 'tb-login-tinepanel',
        border: false,
        defaults: {
          xtype: 'label'
        },
        items: items
      });
    }

    return this.licensePanel;
  },
  getPoweredByPanel: function getPoweredByPanel() {
    if (!this.poweredByPanel) {
      this.poweredByPanel = new Ext.Container({
        layout: 'fit',
        cls: 'powered-by-panel',
        width: 200,
        height: 50,
        border: false,
        defaults: {
          xtype: 'label'
        },
        items: [{
          html: "<div class='tine-viewport-poweredby' style='position: absolute; bottom: 10px; right: 10px; font:normal 12px arial, helvetica,tahoma,sans-serif;'>" + i18n._("Powered by:") + " <a target='_blank' href='" + Tine.weburl + "' title='" + i18n._("online open source groupware and crm") + "'>" + Tine.title + "</a>"
        }]
      });
    }

    return this.poweredByPanel;
  },
  getSurveyData: function getSurveyData(cb) {
    var ds = new Ext.data.Store({
      proxy: new Ext.data.ScriptTagProxy({
        url: 'https://versioncheck.tine20.net/surveyCheck/surveyCheck.php'
      }),
      reader: new Ext.data.JsonReader({
        root: 'survey'
      }, ['title', 'subtitle', 'duration', 'langs', 'link', 'enddate', 'htmlmessage', 'version'])
    });
    ds.on('load', function (store, records) {
      var survey = records[0];
      cb.call(this, survey);
    }, this);
    ds.load({
      params: {
        lang: Tine.Tinebase.registry.get('locale').locale
      }
    });
  },
  getSurveyPanel: function getSurveyPanel() {
    if (!this.surveyPanel) {
      this.surveyPanel = new Ext.Container({
        layout: 'fit',
        cls: 'tb-login-surveypanel',
        border: false,
        defaults: {
          xtype: 'label'
        },
        items: []
      });

      if (!Tine.Tinebase.registry.get('denySurveys')) {
        Tine.log.debug('getSurveyPanel() - fetching survey data ...');
        this.getSurveyData(function (survey) {
          Tine.log.debug(survey);

          if (typeof survey.get === 'function') {
            var enddate = Date.parseDate(survey.get('enddate'), Date.patterns.ISO8601Long);
            var version = survey.get('version');
            Tine.log.debug('Survey version: ' + version + ' / Tine version: ' + Tine.clientVersion.packageString);
            Tine.log.debug('Survey enddate: ' + enddate);

            if (Ext.isDate(enddate) && enddate.getTime() > new Date().getTime() && Tine.clientVersion.packageString.indexOf(version) === 0) {
              Tine.log.debug('Show survey panel');
              survey.data.lang_duration = String.format(i18n._('about {0} minutes'), survey.data.duration);
              survey.data.link = 'https://versioncheck.tine20.net/surveyCheck/surveyCheck.php?participate';
              this.surveyPanel.add([{
                cls: 'tb-login-big-label',
                html: i18n._('Tine 2.0 needs your help')
              }, {
                html: '<p>' + i18n._('We regularly need your feedback to make the next Tine 2.0 releases fit your needs even better. Help us and yourself by participating:') + '</p>'
              }, {
                html: this.getSurveyTemplate().apply(survey.data)
              }, {
                xtype: 'button',
                width: 120,
                text: i18n._('participate!'),
                handler: function handler() {
                  window.open(survey.data.link);
                }
              }]);
              this.surveyPanel.doLayout();
            }
          }
        });
      }
    }

    return this.surveyPanel;
  },
  getSurveyTemplate: function getSurveyTemplate() {
    if (!this.surveyTemplate) {
      this.surveyTemplate = new Ext.XTemplate('<br/ >', '<p><b>{title}</b></p>', '<p><a target="_blank" href="{link}" border="0">{subtitle}</a></p>', '<br/>', '<p>', i18n._('Languages'), ': {langs}</p>', '<p>', i18n._('Duration'), ': {lang_duration}</p>', '<br/>').compile();
    }

    return this.surveyTemplate;
  },

  /**
   * checks browser compatibility and show messages if unknown/incompatible
   * 
   * ie6-11, gecko2 -> bad
   * unknown browser -> may not work
   * 
   * @return {Ext.Container}
   */
  getBrowserIncompatiblePanel: function getBrowserIncompatiblePanel() {
    if (!this.browserIncompatiblePanel) {
      this.browserIncompatiblePanel = new Ext.Container({
        layout: 'fit',
        cls: 'tb-login-surveypanel',
        border: false,
        defaults: {
          xtype: 'label'
        },
        items: []
      });
      var browserSupport = 'compatible';

      if (Ext.isIE6 || Ext.isGecko2 || Ext.isIE || Ext.isNewIE) {
        browserSupport = 'incompatible';
      } else if (!(Ext.isWebKit || Ext.isGecko || Ext.isEdge)) {
        // yepp we also mean -> Ext.isOpera
        browserSupport = 'unknown';
      }

      var items = [];

      if (browserSupport == 'incompatible') {
        items = [{
          cls: 'tb-login-big-label',
          html: i18n._('Browser incompatible')
        }, {
          html: '<p>' + i18n._('Your browser is not supported by Tine 2.0.') + '<br/><br/></p>'
        }];
      } else if (browserSupport == 'unknown') {
        items = [{
          cls: 'tb-login-big-label',
          html: i18n._('Browser incompatible?')
        }, {
          html: '<p>' + i18n._('You are using an unrecognized browser. This could result in unexpected behaviour.') + '<br/><br/></p>'
        }];
      }

      if (browserSupport != 'compatible') {
        this.browserIncompatiblePanel.add(items.concat([{
          html: '<p>' + i18n._('You might try one of these browsers:') + '<br/>' + '<a href="https://www.google.com/chrome" target="_blank">Google Chrome</a><br/>' + '<a href="https://www.mozilla.com/firefox/" target="_blank">Mozilla Firefox</a><br/>' + '<a href="https://www.apple.com/safari/" target="_blank">Apple Safari</a><br/>' + '<a href="https://www.microsoft.com/en-us/windows/microsoft-edge" target="_blank">Microsoft Edge</a>' + '<br/></p>'
        }]));
        this.browserIncompatiblePanel.doLayout();
      }
    }

    return this.browserIncompatiblePanel;
  },
  initComponent: function initComponent() {
    this.initLayout();
    this.supr().initComponent.call(this);
    this.checkOIDCLogin();
  },
  checkOIDCLogin: function checkOIDCLogin() {
    var oidcResponse = window.location.hash;

    if (oidcResponse.match(/access_token/)) {
      Ext.MessageBox.wait(String.format(i18n._('Login successful. Loading {0}...'), Tine.title), i18n._('Please wait!'));
      Ext.Ajax.request({
        scope: this,
        params: {
          method: 'Tinebase.openIDCLogin',
          oidcResponse: oidcResponse
        },
        timeout: 60000,
        // 1 minute
        success: this.onLoginSuccess
      });
    }
  },
  onLoginFail: async function onLoginFail(response, request) {
    const exception = _.get(JSON.parse(response.responseText), 'data', {});

    const me = this;

    switch (exception.code) {
      case 630:
        const mfaDevices = exception.mfaUserConfigs;
        return Tine.Tinebase.areaLocks.unlock(exception.area, {
          mfaDevices,
          username: me.getLoginPanel().getForm().findField('username').getValue(),

          USERABORTMethod() {
            Ext.MessageBox.hide();
          },

          unlockMethod(areaName, MFAUserConfigId, MFAPassword) {
            me.onLoginPress({
              MFAUserConfigId,
              MFAPassword
            });
          },

          triggerMFAMethod(MFAUserConfigId) {
            if (mfaDevices.length > 1) {
              me.onLoginPress({
                MFAUserConfigId
              });
            }
          }

        });
        break;

      case 631:
        return Tine.Tinebase.areaLocks.onMFAFail(exception.area, exception, {
          retryMethod() {
            me.onLoginPress();
          }

        });
        break;

      default:
        return Tine.Tinebase.ExceptionHandler.handleRequestException(response);
        break;
    }
  },
  onLoginSuccess: function onLoginSuccess(response) {
    var responseData = Ext.util.JSON.decode(response.responseText);

    if (responseData.success === true) {
      Ext.MessageBox.wait(String.format(i18n._('Login successful. Loading {0}...'), Tine.title), i18n._('Please wait!'));
      window.document.title = this.originalTitle;
      response.responseData = responseData;
      this.onLogin.call(this.scope, response);
    } else {
      var modSsl = Tine.Tinebase.registry.get('modSsl');
      var resultMsg = modSsl ? i18n._('There was an error verifying your certificate!') : i18n._('Your username and/or your password are wrong!');
      Ext.MessageBox.show({
        title: i18n._('Login failure'),
        msg: resultMsg,
        buttons: Ext.MessageBox.OK,
        icon: Ext.MessageBox.ERROR,
        fn: function () {
          this.getLoginPanel().getForm().findField('password').focus(true);

          if (document.getElementById('useCaptcha')) {
            if (typeof responseData.c1 != 'undefined') {
              document.getElementById('imgCaptcha').src = 'data:image/png;base64,' + responseData.c1;
              document.getElementById('contImgCaptcha').style.visibility = 'visible';
            }
          }
        }.createDelegate(this)
      });
    }
  },
  initLayout: function initLayout() {
    var infoPanelItems = this.showInfoBox ? [this.getBrowserIncompatiblePanel(), this.getLicenseInformationPanel() // removed for Tine 2.0 Business Edition
    //this.getCommunityPanel(),
    //this.getSurveyPanel()
    ] : [];
    this.infoPanel = new Ext.Container({
      cls: 'tb-login-infosection',
      border: false,
      width: 300,
      height: 520,
      // bad idea to hardcode height here
      layout: 'vbox',
      layoutConfig: {
        align: 'stretch'
      },
      items: infoPanelItems
    });
    this.items = [{
      xtype: 'container',
      layout: window.innerWidth < 768 ? 'column' : 'absolute',
      border: false,
      items: [this.getLoginPanel(), this.infoPanel, this.getPoweredByPanel(), this.getVersionPanel()]
    }];
  },

  /**
   * do the actual login
   */
  onLoginPress: function onLoginPress(additionalParams) {
    var form = this.getLoginPanel().getForm(),
        values = form.getFieldValues();

    if (form.isValid()) {
      Ext.MessageBox.wait(i18n._('Logging you in...'), i18n._('Please wait'));
      Ext.Ajax.request({
        scope: this,
        params: _.assign({
          method: this.loginMethod,
          username: values.username,
          password: values.password
        }, additionalParams),
        timeout: 60000,
        // 1 minute
        success: this.onLoginSuccess,
        failure: this.onLoginFail
      });
    } else {
      Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
    }
  },
  onOIDCLoginPress: function onOIDCLoginPress() {
    Ext.MessageBox.wait(i18n._('Redirecting to SSO Identity Provider'), i18n._('Please wait!'));
    window.location.href = 'http://localhost:4000/index.php?method=Tinebase.openIDCLogin';
  },
  onRender: function onRender(ct, position) {
    this.supr().onRender.apply(this, arguments);
    this.map = new Ext.KeyMap(this.el, [{
      key: [10, 13],
      scope: this,
      fn: this.onLoginPress
    }]);
    this.originalTitle = window.document.title;
    var postfix = Tine.Tinebase.registry.get('titlePostfix') ? Tine.Tinebase.registry.get('titlePostfix') : '';
    window.document.title = Ext.util.Format.stripTags(Tine.title + postfix + ' - ' + i18n._('Please enter your login data'));
  },
  onResize: function onResize() {
    this.supr().onResize.apply(this, arguments);
    var box = this.getBox(),
        loginBox = this.getLoginPanel().rendered ? this.getLoginPanel().getBox() : {
      width: this.getLoginPanel().width,
      height: this.getLoginPanel().height
    },
        infoBox = this.infoPanel.rendered ? this.infoPanel.getBox() : {
      width: this.infoPanel.width,
      height: this.infoPanel.height
    };
    var top = (box.height - loginBox.height) / 2;

    if (box.height - top < infoBox.height) {
      top = box.height - infoBox.height;
    }

    var loginLeft = (box.width - loginBox.width) / 2;

    if (loginLeft + loginBox.width + infoBox.width > box.width) {
      loginLeft = box.width - loginBox.width - infoBox.width;
    }

    this.getLoginPanel().setPosition(loginLeft, top);
    this.infoPanel.setPosition(loginLeft + loginBox.width, top);
    this.getPoweredByPanel().setPosition(box.width - this.poweredByPanel.width, box.height - this.poweredByPanel.height);
  },
  renderSurveyPanel: function renderSurveyPanel(survey) {
    var items = [{
      cls: 'tb-login-big-label',
      html: i18n._('Tine 2.0 needs your help')
    }, {
      html: '<p>' + i18n._('We regularly need your feedback to make the next Tine 2.0 releases fit your needs even better. Help us and yourself by participating:') + '</p>'
    }];
  }
});

/***/ }),
/* 1430 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine, Locale*/
Ext.ns('Tine.Tinebase');
/**
 * admin settings panel
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.AdminPanel
 * @extends     Ext.TabPanel
 * 
 * <p>Tinebase Admin Panel</p>
 * <p><pre>
 * </pre></p>
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 * 
 * @param       {Object} config
 * @constructor
 * Create a new Tine.Tinebase.AdminPanel
 * @TODO        Invent some kind of registry for inner panels
 */

Tine.Tinebase.AdminPanel = Ext.extend(Ext.TabPanel, {
  activeItem: 0,
  border: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.items = [new Tine.Admin.config.GridPanel({
      configApp: Tine.Tinebase.appMgr.get('Tinebase')
    }), new Tine.Tinebase.Admin.UserProfileConfigPanel({})];
    Tine.Tinebase.AdminPanel.superclass.initComponent.call(this);
  }
});
/**
 * Tinebase Admin Panel Popup
 * 
 * @param   {Object} config
 * @return  {Ext.ux.Window}
 */

Tine.Tinebase.AdminPanel.openWindow = function (config) {
  var window = Tine.WindowFactory.getWindow({
    width: 500,
    height: 470,
    name: 'tinebase-admin-panel',
    contentPanelConstructor: 'Tine.Tinebase.AdminPanel',
    contentPanelConstructorConfig: config
  });
};

Ext.ns('Tine.Tinebase.Admin');
Tine.Tinebase.Admin.UserProfileConfigPanel = Ext.extend(Ext.Panel, {
  // TODO: extend some kind of AppAdminPanel
  layout: 'fit',
  border: false,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.title = i18n._('Profile Information');
    this.items = [];
    this.applyAction = new Ext.Action({
      text: i18n._('Apply'),
      disabled: true,
      iconCls: 'action_applyChanges',
      handler: this.applyConfig.createDelegate(this)
    });
    this.buttons = [this.applyAction];
    Tine.Tinebase.getUserProfileConfig(this.initProfileTable, this);
    this.supr().initComponent.call(this);
  },
  afterRender: function afterRender() {
    this.supr().afterRender.apply(this, arguments);
    this.loadMask = new Ext.LoadMask(this.getEl(), {
      msg: i18n._('Please Wait')
    });

    if (!this.store) {
      (function () {
        this.loadMask.show();
      }).defer(50, this);
    }
  },
  applyConfig: function applyConfig() {
    var userProfileConfig = {
      readableFields: [],
      updateableFields: []
    };
    this.store.each(function (field) {
      var fieldName = field.get('fieldName');

      if (field.get('readGrant')) {
        userProfileConfig.readableFields.push(fieldName);
      }

      if (field.get('editGrant')) {
        userProfileConfig.updateableFields.push(fieldName);
      }
    }, this);
    this.loadMask.show();
    Tine.Tinebase.setUserProfileConfig(userProfileConfig, function () {
      this.store.commitChanges();
      this.applyAction.setDisabled(true);
      this.loadMask.hide();
    }, this);
  },
  initProfileTable: function initProfileTable(userProfileConfig) {
    var adbI18n = new Locale.Gettext();
    adbI18n.textdomain('Addressbook');
    var fieldData = [];
    Ext.each(userProfileConfig.possibleFields, function (fieldName) {
      var fieldDefinition = Tine.Addressbook.Model.Contact.getField(fieldName);
      fieldData.push([fieldName, adbI18n._hidden(fieldDefinition.label), userProfileConfig.readableFields.indexOf(fieldName) >= 0, userProfileConfig.updateableFields.indexOf(fieldName) >= 0]);
    }, this);
    this.store = new Ext.data.ArrayStore({
      autoDestroy: true,
      fields: ['fieldName', 'fieldLabel', 'readGrant', 'editGrant'],
      data: fieldData,
      listeners: {
        scope: this,
        update: this.onStoreUpdate
      }
    });
    var cbs = [new Ext.ux.grid.CheckColumn({
      header: i18n._('Read'),
      tooltip: i18n._('The field is readable part of the profile'),
      dataIndex: 'readGrant',
      width: 55
    }), new Ext.ux.grid.CheckColumn({
      header: i18n._('Edit'),
      tooltip: i18n._('The field is editable part of the profile'),
      dataIndex: 'editGrant',
      width: 55
    })];
    this.userProfileConfigGrid = new Ext.grid.EditorGridPanel({
      layout: 'fit',
      store: this.store,
      autoExpandColumn: 'fieldName',
      plugins: cbs,
      columns: [{
        id: 'fieldName',
        header: i18n._('Field Name'),
        dataIndex: 'fieldLabel'
      }].concat(cbs)
    });
    this.add(this.userProfileConfigGrid);
    this.doLayout();

    if (this.loadMask) {
      this.loadMask.hide();
    }
  },
  onStoreUpdate: function onStoreUpdate() {
    this.applyAction.setDisabled(false);
  }
});

/***/ }),
/* 1431 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * user profile panel
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.UserProfilePanel
 * @extends     Ext.form.FormPanel
 * @consturctor
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 */

Tine.Tinebase.UserProfilePanel = Ext.extend(Ext.Panel, {
  genericFields: ['account_id', 'created_by', 'creation_time', 'last_modified_by', 'last_modified_time', 'is_deleted', 'deleted_time', 'deleted_by'],
  layout: 'form',
  border: true,
  labelAlign: 'top',
  autoScroll: true,
  defaults: {
    anchor: '95%',
    labelSeparator: ''
  },
  bodyStyle: 'padding:5px',
  initComponent: function initComponent() {
    Tine.Tinebase.getUserProfile(Tine.Tinebase.registry.get('currentAccount').accountId, this.onData.createDelegate(this));
    this.items = [];
    this.supr().initComponent.apply(this, arguments);
  },
  onData: function onData(userProfileInfo) {
    var userProfile = userProfileInfo.userProfile,
        readableFields = userProfileInfo.readableFields,
        updateableFields = userProfileInfo.updateableFields;
    var adbI18n = new Locale.Gettext();
    adbI18n.textdomain('Addressbook');
    Ext.each(readableFields, function (fieldName) {
      // don't display generic fields
      var fieldDefinition = Tine.Addressbook.Model.Contact.getField(fieldName);

      if (!fieldDefinition) {
        return;
      }

      switch (fieldName) {
        default:
          this.add(new Ext.form.TextField({
            hidden: this.genericFields.indexOf(fieldName) >= 0,
            name: fieldName,
            value: userProfile[fieldName],
            fieldLabel: adbI18n._hidden(fieldDefinition.label),
            readOnly: updateableFields.indexOf(fieldName) < 0
          }));
          break;
      }
    }, this);
    this.doLayout();
  }
});

/***/ }),
/* 1432 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * translations for js prototypes
 * 
 * @package     Tine
 * @subpackage  Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Philipp Schuele <p.schuele@metaways.de>
 * @copyright   Copyright (c) 2010 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.namespace('Tine.Tinebase');
/**
 * this is called in tineInit::initLocale() to make sure we translate some plugin strings by overwriting prototype values
 */

Tine.Tinebase.prototypeTranslation = function () {
  // html editor plugin translations
  Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[1].tooltip.title = i18n._('Outdent Text');
  Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[1].overflowText = i18n._('Outdent Text');
  Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[2].tooltip.title = i18n._('Indent Text');
  Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[2].overflowText = i18n._('Indent Text');
  Ext.ux.form.HtmlEditor.RemoveFormat.prototype.midasBtns[1].tooltip.title = i18n._('Remove Formatting');
  Ext.ux.form.HtmlEditor.RemoveFormat.prototype.midasBtns[1].overflowText = i18n._('Remove Formatting');
};

/***/ }),
/* 1433 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.CanonicalPath');
/**
 * @static
 * @type {string}
 */

Tine.Tinebase.CanonicalPath.separator = '/';
/**
 * get full canonical path of given component
 *
 * $static
 * @param {Ext.Component} component
 */

Tine.Tinebase.CanonicalPath.getPath = function (component) {
  var _ = window.lodash,
      pathParts = [],
      pathPart;

  while (component) {
    pathPart = Tine.Tinebase.CanonicalPath.getPathPart(component);

    if (pathPart && !pathParts.join(Tine.Tinebase.CanonicalPath.separator).match(new RegExp('^' + _.escapeRegExp(pathPart)))) {
      pathParts.unshift(pathPart);
    } // stop if pathPart starts with a separator -> counts as root


    component = String(pathPart).charAt(0) != Tine.Tinebase.CanonicalPath.separator && Ext.isFunction(component.findParentBy) ? component.findParentBy(Tine.Tinebase.CanonicalPath.hasPathPart) : false;
  }

  return pathParts.join(Tine.Tinebase.CanonicalPath.separator);
};
/**
 * return canonical path part
 *
 * @static
 * @param {Ext.Component} component
 * @returns {String}
 */


Tine.Tinebase.CanonicalPath.getPathPart = function (component) {
  return Tine.Tinebase.CanonicalPath.hasPathPart(component) ? component.getCanonicalPathSegment() : '';
};
/**
 * checks if component has canonical path part
 *
 * @static
 * @param {Ext.Component} component
 * @returns {Bool}
 */


Tine.Tinebase.CanonicalPath.hasPathPart = function (component) {
  return Ext.isFunction(component.getCanonicalPathSegment);
};
/**
 * activate  as much as possible :)
 *
 * @TODO
 *  - activate views/ranges (e.g. calendar)
 *  - activate filtertoolbar
 *  - activate and find paths in windows
 * @TODO
 * - rethink forward resolution/activation of paths, we need this for tests to stear UI
 *
 * @private
 * @static
 */


Tine.Tinebase.CanonicalPath.activateAll = function () {
  Tine.Tinebase.appMgr.apps.each(function (app) {
    Tine.Tinebase.MainScreen.activate(app);
    var mainScreen = app.getMainScreen(),
        westPanel = mainScreen ? mainScreen.getWestPanel() : null,
        moduleTree = mainScreen && mainScreen.useModuleTreePanel && Ext.isFunction(mainScreen.getModuleTreePanel) ? mainScreen.getModuleTreePanel() : null; // activate mainscreens of all contenttypes

    if (moduleTree && Ext.isFunction(moduleTree.getRootNode)) {
      Ext.each(moduleTree.getRootNode().childNodes, function (node) {
        mainScreen.setActiveContentType(node.attributes.contentType);
      });
    } else if (westPanel && Ext.isFunction(westPanel.getRootNode)) {
      Ext.each(westPanel.getRootNode().childNodes, function (node) {
        // Admin, but not Voipmanager :)
        if (!node.childNodes.length) {
          node.fireEvent('click', node, {});
        }
      });
    }
  }); // query for all openWindow methods

  var openers = {};

  var rfn = function rfn(o) {
    lodash.forEach(o, function (value, key) {
      if (lodash.isObject(value) && lodash.isFunction(value.openWindow)) {
        openers[key] = value.openWindow;
      } else if (lodash.isPlainObject(value)) {
        rfn(value);
      }
    });
  };

  rfn(Tine);
  Tine.WindowFactory.windowType = 'Ext';
  lodash.forEach(openers, function (opnr, name) {
    try {
      console.info(name);
      opnr({});
    } catch (e) {}
  });
};
/**
 * gets canonical pathes of all created components
 *
 * @private
 * @static
 * @returns {Array}
 */


Tine.Tinebase.CanonicalPath.getAllPaths = function () {
  var paths = [];
  Ext.ComponentMgr.all.each(function (component) {
    var canonicalPath = Tine.Tinebase.CanonicalPath.getPath(component);

    if (canonicalPath) {
      paths.push(canonicalPath);
    }
  });
  return paths.unique().sort();
};
/**
 * generic canonical name support for components
 */


Ext.override(Ext.Component, {
  /**
   * canonical name
   * @cfg {String} canonicalName
   */
  canonicalName: null,

  /**
   * returns canonical name / path segment
   * @returns {string}
   */
  getCanonicalPathSegment: function getCanonicalPathSegment() {
    return this.canonicalName;
  }
});

/***/ }),
/* 1434 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.cweiss@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine', 'Tine.Tinebase');
/**
 * checks users presence according to dom events
 *
 * NOTE: this method intercepts Ext.EventObjectImpl as a lot of events might not bubble till window object
 *       This needs to be adopted as more other frameworks we introduce
 *
 * @namespace  Tine.Tinebase
 * @class      Tine.Tinebase.PresenceObserver
 */

Tine.Tinebase.PresenceObserver = function (config) {
  Ext.apply(this, config);
  this.checkTask = new Ext.util.DelayedTask(this.checkPresence, this);
  this.startChecking();
};

Tine.Tinebase.PresenceObserver.prototype = {
  /**
   * @cfg {integer} maxAbsenceTime in minutes
   */
  maxAbsenceTime: 240,

  /**
   * @cfg {integer} presenceCheckInterval in seconds
   */
  presenceCheckInterval: 5,

  /**
   * @cfg {Function} callback to be called when absence is detected
   */
  absenceCallback: Ext.emptyFn,

  /**
   * @cfg {Function} callback to be called each time presence is detected
   */
  presenceCallback: Ext.emptyFn,

  /**
   * @cfg {Object} scope to the callbacks are called in
   */
  scope: window,

  /**
   * @property {Ext.util.DelayedTask} checkTask
   */
  checkTask: null,
  startChecking: function startChecking() {
    var now = new Date(),
        firstCheck = now.add(Date.MINUTE, this.maxAbsenceTime);
    this.state = 'presence';
    this.setLastPresence(now);
    Tine.log.debug('Tine.Tinebase.PresenceObserver.startChecking register fist presence check for ' + firstCheck);
    this.checkTask.delay(this.maxAbsenceTime * 60000);
  },
  stopChecking: function stopChecking() {
    this.checkTask.cancel();
  },
  checkPresence: function checkPresence() {
    var now = new Date(),
        nowTS = now.getTime(),
        lastPresence = this.getLastPresence(),
        state = lastPresence + this.maxAbsenceTime * 60000 <= nowTS ? 'absence' : 'presence';
    Tine.log.debug('Tine.Tinebase.PresenceObserver.checkPresence checking presece now ' + now);
    Tine.log.debug('Tine.Tinebase.PresenceObserver.checkPresence state: "' + state + '" as last presence detected at ' + new Date(lastPresence));

    if (state == 'absence') {
      Tine.log.info('Tine.Tinebase.PresenceObserver.checkPresence no presence detected for ' + this.maxAbsenceTime + ' minutes');

      if (this.state == 'presence') {
        this.state = 'absence';
        this.absenceCallback.call(this.scope, new Date(lastPresence), this);
      } // wait for user to return


      this.checkTask.delay(this.presenceCheckInterval * 1000);
    } else {
      var nextCheck = this.maxAbsenceTime * 60000 - (nowTS - lastPresence);
      Tine.log.debug('Tine.Tinebase.PresenceObserver.checkPresence next presence check at ' + now.add(Date.MILLI, nextCheck));
      this.state = 'presence';
      this.checkTask.delay(nextCheck);
      this.presenceCallback.call(this.scope, new Date(lastPresence), this);
    }
  },

  /**
   * get last presence timestamp
   *
   * @returns {number}
   */
  getLastPresence: function getLastPresence() {
    var myLastPresence = // last prsence from this window
    Tine.Tinebase.PresenceObserver.lastPresence,
        otherLastPresence = // last presence set by other windows
    Tine.Tinebase.registry.get('lastPresence');

    if (myLastPresence > otherLastPresence) {
      this.setLastPresence(myLastPresence);
    }

    return Tine.Tinebase.PresenceObserver.lastPresence;
  },
  setLastPresence: function setLastPresence(ts) {
    ts = ts.getTime ? ts.getTime() : ts;
    Tine.Tinebase.PresenceObserver.lastPresence = ts;
    Tine.Tinebase.registry.set('lastPresence', ts);
  }
};
/**
 * @static {Number} lastPresence last event timestamp
 */

Tine.Tinebase.PresenceObserver.lastPresence = null;
Ext.EventObjectImpl.prototype.setEvent = Ext.EventObjectImpl.prototype.setEvent.createInterceptor(function (e) {
  // timeStamp property of object sucks, see https://developers.google.com/web/updates/2016/01/high-res-timestamps
  Tine.Tinebase.PresenceObserver.lastPresence = new Date().getTime();
});

/***/ }),
/* 1435 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * PasswordGenerator.
 *
 * @param config
 * @constructor
 */

Tine.Tinebase.PasswordGenerator = function (config) {
  this.minLength = config.minLength || 12;
  this.minWordChars = config.minWordChars || 5;
  this.minUppercaseChars = config.minUppercaseChars || 1;
  this.minSpecialChars = config.minSpecialChars || 1;
  this.minNumericalChars = config.minNumericalChars || 0;
};

Tine.Tinebase.PasswordGenerator.prototype = {
  /**
   * Ascii range for uppercase characters
   * @private
   */
  uppercaseChars: [65, 90],

  /**
   * Ascii range for lowercase characters
   * @private
   */
  lowercaseChars: [97, 122],

  /**
   * Ascii range for special chars
   * @private
   */
  specialChars: [33, 46],

  /**
   * Ascii range for numerical chars
   * @private
   */
  numericalChars: [48, 57],

  /**
   * Characters to be used in password
   * @private
   */
  characters: [],

  /**
   * Generates a random password based on the minimal criteria defined in config
   */
  generatePassword: function generatePassword() {
    this.characters = [];
    this.addCharsOfType(this.uppercaseChars, this.minUppercaseChars);
    this.addCharsOfType(this.specialChars, this.minSpecialChars);
    this.addCharsOfType(this.numericalChars, this.minNumericalChars);
    this.addCharsOfType(this.lowercaseChars, this.minWordChars);
    this.addCharsOfType(this.lowercaseChars, this.minLength - this.characters.length);
    var _ = window.lodash;
    return _.join(_.shuffle(this.characters), '');
  },

  /**
   * @private
   * @param range
   * @param min
   */
  addCharsOfType: function addCharsOfType(range, min) {
    for (var i = 0; i < min; i++) {
      this.characters.push(this.getRandomCharOfRange(range));
    }
  },

  /**
   * @private
   * @param range
   * @return {string}
   */
  getRandomCharOfRange: function getRandomCharOfRange(range) {
    var _ = window.lodash;
    return String.fromCharCode(_.random(range[0], range[1]));
  }
};

/***/ }),
/* 1436 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Michael Spahn <m.spahn@metaways.de>
 * @copyright   Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * File picker dialog
 *
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.RangeSliderComponent
 * @extends     Ext.Component
 * @constructor
 * @param       {Object} config The configuration options.
 */

Tine.Tinebase.RangeSliderComponent = Ext.extend(Ext.BoxComponent, {
  minWidth: 100,
  height: 25,
  slider: null,
  sliderResizer: null,
  sliderLabel: null,
  sliderBorder: null,
  maxRange: 23.99,
  currentStart: 0,
  currentEnd: 23.99,
  cls: 'rangeslider-component',
  name: null,

  /**
   * @private
   */
  initComponent: function initComponent() {
    this.supr().initComponent.apply(this, arguments);
    this.on('afterrender', this.onAfterRender);
  },

  /**
   * We have an element called sliderBorder which can be styled.
   *
   * The sliderWrap is used to calculate positions of the slider within this element, therefor you shouldn't apply
   * box model affecting styles to the slider itself or the the sliderWrap.
   *
   * The slider is a simple div which is managed by Ext.Resizable and contains a span which can be used as a label.
   *
   * @todo: maybe this can be done better
   *
   * @private
   */
  initSlider: function initSlider() {
    this.sliderWrap = new Ext.Element(document.createElement('div'));
    this.sliderBorder = new Ext.Element(document.createElement('div'));
    this.sliderBorder.addClass('rangeslider-component-sliderBorder');
    this.slider = new Ext.Element(document.createElement('div'));
    this.slider.addClass('rangeslider-component-slider');
    this.sliderLabel = new Ext.Element(document.createElement('span'));
    this.sliderLabel.setHeight(this.height);
    this.sliderLabel.addClass('rangeslider-component-slider-label');
    this.slider.appendChild(this.sliderLabel);
    this.sliderWrap.appendChild(this.slider);
    this.sliderBorder.appendChild(this.sliderWrap);
    this.getEl().appendChild(this.sliderBorder);
    this.sliderResizer = new Ext.Resizable(this.slider, {
      handles: 'e w',
      pinned: true,
      dynamic: true
    });
  },

  /**
   * @private
   */
  onAfterRender: function onAfterRender() {
    this.initSlider();
    this.setSliderWidth(this.currentStart, this.currentEnd);
  },

  /**
   * @private
   *
   * In case you won't use this class for a hour, min slider, you should override this function and update the label yourself
   */
  updateLabel: function updateLabel() {
    this.sliderLabel.setWidth(this.sliderResizer.getEl().getWidth());

    if (this.sliderLabel.getWidth() > this.slider.getWidth()) {
      this.sliderLabel.hide();
    } else {
      this.sliderLabel.show();
    }

    var hoursStart = Tine.Tinebase.common.trunc(this.currentStart);
    var minStart = Tine.Tinebase.common.trunc(Math.round(this.currentStart % 1 * 100) * 0.60);
    var hoursEnd = Tine.Tinebase.common.trunc(this.currentEnd);
    var minEnd = Tine.Tinebase.common.trunc(this.currentEnd % 1 * 100 * 0.60);
    var startDate = new Date();
    startDate.setHours(hoursStart);
    startDate.setMinutes(minStart);
    var endDate = new Date();
    endDate.setHours(hoursEnd);
    endDate.setMinutes(minEnd);
    var pattern = 'H:i';
    this.sliderLabel.update(startDate.format(pattern) + ' - ' + endDate.format(pattern));
  },

  /**
   * @private
   */
  getCropFactor: function getCropFactor() {
    return this.sliderWrap.getWidth(true) / this.maxRange;
  },

  /**
   * @private
   */
  onSliderResize: function onSliderResize() {
    var el = this.sliderResizer.getEl();
    var offsetLeft = el.getOffsetsTo(this.sliderWrap)[0];
    var offsetWidth = el.dom.offsetWidth;
    var cropFactor = this.getCropFactor();
    this.currentStart = offsetLeft / cropFactor;
    this.currentEnd = (offsetLeft + offsetWidth) / cropFactor;
    var invalidState = false;

    if (this.currentEnd > this.maxRange) {
      this.currentEnd = this.maxRange;
      invalidState = true;
    }

    if (this.currentStart < 0) {
      this.currentStart = 0;
      invalidState = true;
    }

    if (true === invalidState) {
      this.setSliderWidth(this.currentStart, this.currentEnd);
    }

    this.updateLabel();
  },

  /**
   *  @private
   */
  resizeElement: function resizeElement() {
    var box = Ext.Resizable.prototype.resizeElement.apply(this.sliderResizer);
    this.onSliderResize();
    return box;
  },

  /**
   * Set the slider width
   *
   * @param start 0-23.99
   * @param end 0-23.99
   */
  setSliderWidth: function setSliderWidth(start, end) {
    // End is not allowed to be smaller
    if (end < start) {
      return;
    }

    this.currentStart = start;
    this.currentEnd = end;
    var cropFactor = this.getCropFactor();
    var leftOffset = start * cropFactor;
    var width = end * cropFactor - start * cropFactor;
    this.slider.alignTo(this.sliderWrap, 'tl-tl', [leftOffset, 0]);
    this.sliderResizer.resizeElement = this.resizeElement.createDelegate(this);
    this.sliderResizer.on('resize', this.onSliderResize.createDelegate(this));
    this.sliderResizer.resizeTo(width, this.sliderResizer.getEl().getHeight());
  },

  /**
   * Returns current span
   */
  getRange: function getRange() {
    return [this.currentStart, this.currentEnd];
  },

  /**
   * Set slider to a certain position by entering an array with start and end
   */
  setRange: function setRange(range) {
    if (!Ext.isArray(range) || range.length !== 2) {
      return;
    }

    this.setSliderWidth(range[0], range[1]);
  }
});

/***/ }),
/* 1437 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2019 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.BL');
Tine.Tinebase.BL.BLConfigPanel = Ext.extend(Tine.widgets.grid.QuickaddGridPanel, {
  /**
   * @cfg {Tine.Tinebase.data.Record} owningRecordClass
   * record class with blConfig field
   */
  owningRecordClass: null,

  /**
   * @cfg {String}
   * field name in owningRecordClass where blConfig is configured/stored
   */
  owningField: 'blpipe',

  /**
   * @cfg {String}
   * path to get/put data
   */
  dataPath: 'data.blpipe',

  /**
   * cfg {Record} record class having a dynamicRecord field
   */
  recordClass: null,

  /**
   * @cfg {String} 
   * property holding the dynamic record
   */
  dynamicRecordField: 'configRecord',
  initComponent: function initComponent() {
    var _ = window.lodash,
        me = this;

    if (!this.owningRecordClass && this.editDialog) {
      this.owningRecordClass = this.editDialog.recordClass;
    }

    this.recordClass = this.recordClass || Tine.Tinebase.data.RecordMgr.get(_.get(this.owningRecordClass.getField(this.owningField), 'fieldDefinition.config.recordClassName'));
    this.modelConfig = this.modelConfig || _.get(this, 'recordClass.getModelConfiguration') ? this.recordClass.getModelConfiguration() : null;
    this.classNameField = this.classNameField || _.get(this.recordClass.getField(this.dynamicRecordField), 'fieldDefinition.config.refModelField', 'classname');
    this.title = this.hasOwnProperty('title') ? this.title : this.recordClass.getRecordsName();
    this.quickaddMandatory = this.classNameField;
    this.autoExpandColumn = this.dynamicRecordField; // @TODO: move to fieldManager?

    this.BLElementConfigClassNames = _.get(this.recordClass.getField(this.classNameField), 'fieldDefinition.config.availableModels', []);
    this.BLElementPicker = new Ext.form.ComboBox({
      listWidth: 200,
      store: _.reduce(this.BLElementConfigClassNames, function (arr, classname) {
        var recordClass = Tine.Tinebase.data.RecordMgr.get(classname);

        if (recordClass) {
          arr.push([classname, recordClass.getRecordName()
          /*, recordClass.getDescription()*/
          ]);
        }

        return arr;
      }, []),
      typeAhead: true,
      triggerAction: 'all',
      emptyText: i18n._('Add new Element...'),
      selectOnFocus: true,
      blurOnSelect: true
    });

    _.assign(this, Tine.widgets.grid.GridPanel.prototype.initGenericColumnModel.call(this));

    this.on('beforeaddrecord', this.onBeforeAddBLElementRecord, this);
    this.on('celldblclick', this.onCellDoubleClick, this);
    this.supr().initComponent.call(this);
  },
  customizeColumns: function customizeColumns(columns) {
    _.each(columns, col => {
      col.editor = Tine.widgets.form.FieldManager.get(this.recordClass.getMeta('appName'), this.recordClass, col.dataIndex, Tine.widgets.form.FieldManager.CATEGORY_PROPERTYGRID);
    });

    _.assign(_.find(columns, {
      dataIndex: this.classNameField
    }), {
      quickaddField: this.BLElementPicker,
      editor: null // be cautious, fieldManager might return smth.

    });
  },
  onRender: function onRender() {
    this.supr().onRender.apply(this, arguments);

    if (!this.editDialog) {
      this.editDialog = this.findParentBy(function (c) {
        return c instanceof Tine.widgets.dialog.EditDialog;
      });
    }

    this.editDialog.on('load', this.onRecordLoad, this);
    this.editDialog.on('recordUpdate', this.onRecordUpdate, this); // NOTE: in case we are rendered after record was load

    this.onRecordLoad(this.editDialog, this.editDialog.record);
  },
  onBeforeAddBLElementRecord: function onBeforeAddBLElementRecord(newRecord) {
    this.openEditDialog(newRecord);
    return false;
  },
  onCellDoubleClick: function onCellDoubleClick(grid, row, col) {
    if (!this.readOnly) {
      var configWrapper = this.store.getAt(row);
      this.openEditDialog(configWrapper);
    }
  },
  openEditDialog: function openEditDialog(configWrapper) {
    var recordClass = Tine.Tinebase.data.RecordMgr.get(configWrapper.get(this.classNameField)),
        editDialogClass = Tine.widgets.dialog.EditDialog.getConstructor(recordClass),
        configRecord = configWrapper.get(this.dynamicRecordField) || {};

    if (!configRecord.data) {
      configRecord = Tine.Tinebase.data.Record.setFromJson(configRecord, recordClass);
    }

    if (editDialogClass) {
      editDialogClass.openWindow({
        mode: 'local',
        record: Ext.encode(configRecord.data),
        recordId: configRecord.getId(),
        blConfigPanel: this,
        configWrapper: configWrapper,
        listeners: {
          scope: this,
          'update': function update(updatedRecord) {
            if (!updatedRecord.data) {
              updatedRecord = Tine.Tinebase.data.Record.setFromJson(updatedRecord, recordClass);
            }

            Tine.Tinebase.common.assertComparable(updatedRecord.data);
            configWrapper.set(this.dynamicRecordField, updatedRecord.data);

            if (this.store.indexOf(configWrapper) < 0) {
              this.store.add([configWrapper]);
            }
          }
        }
      });
    }
  },
  onRecordLoad: function onRecordLoad(editDialog, record) {
    var _ = window.lodash,
        data = _.get(record, this.dataPath) || [];
    this.setStoreFromArray(data);
  },
  onRecordUpdate: function onRecordUpdate(editDialog, record) {
    var _ = window.lodash,
        data = this.getFromStoreAsArray();

    _.set(record, this.dataPath, data);
  }
});

/***/ }),
/* 1438 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1439);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1439 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/**\n * fixes to the extjs css files \n *\n * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3\n * @author      Cornelius Weiss <c.weiss@metaways.de>\n * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)\n * @version     $Id$\n */\n\n/**\n * Ext sets the z-index for masks to 20000 and for windows to 9000. As such\n * Windows get hidden when a underlaying element gets masked. To fix this we set\n * the mask index to 5000\n */\n.ext-el-mask {z-index: 5000;}\n.ext-el-mask-msg {z-index: 5001;}\n\n/* only included in expamples :-(*/\n.x-menu-title {\n    background: #D6E3F2;\n    border-style: solid;\n    border-color:#DAE6F4 #99bbe8 #99bbe8 #DAE6F4;\n    border-width: 1px;\n    margin:-2px -2px 0;\n    color:#15428b;\n    font:bold 10px tahoma,arial,verdana,sans-serif;\n    display:block;\n    padding:3px;\n}\n\n.x-panel-inline-icon,\n.x-btn-text-icon .x-btn-icon-small-left .x-btn-text,\n.x-tree-node-collapsed .x-tree-node-icon,\n.x-tree-node-expanded .x-tree-node-icon,\n.x-tree-node-leaf .x-tree-node-icon,\n.ext-strict .x-menu-item-icon {\n    background-size: 16px 16px !important;\n}\n", ""]);

// exports


/***/ }),
/* 1440 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1441);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1441 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "html,\nbody {\n  font: normal 12px verdana;\n  margin: 0;\n  padding: 0;\n  border: 0 none;\n  overflow: hidden;\n  height: 100%;\n}\n/* see ace-tm styles */\n.string {\n  color: #036a07;\n}\n.number {\n  color: #0000cd;\n}\n.boolean {\n  color: #585cf6;\n}\n.null {\n  color: magenta;\n}\n.key {\n  color: #318495;\n}\n.ApplicationIconCls {\n  background-image: url(" + escape(__webpack_require__(365)) + ");\n}\n.x-dialog-info {\n  background-image: url(" + escape(__webpack_require__(635)) + ");\n}\n.x-dialog-question {\n  background-image: url(" + escape(__webpack_require__(636)) + ");\n}\n.x-dialog-warn {\n  background-image: url(" + escape(__webpack_require__(637)) + ");\n}\n/* ----- ext fixes -------------------------------------------------------------*/\n/* auto column sizing */\n.x-grid3-hd-row td {\n  box-sizing: border-box;\n}\n.x-grid3-row td,\n.x-grid3-summary-row td {\n  padding-left: 0px;\n  padding-right: 0px;\n}\n/* active table heads when header is multi line */\ntd.x-grid3-hd-over,\ntd.sort-asc,\ntd.sort-desc {\n  background-image: linear-gradient(to bottom, #ebf3fd, #c3daf9 80%, #ebf3fd);\n}\ntd.sort-desc .x-grid3-hd-inner,\ntd.sort-asc .x-grid3-hd-inner,\ntd.x-grid3-hd-over .x-grid3-hd-inner {\n  background-image: none;\n  background-color: transparent;\n}\n/* ----- actions -------------------------------------------------------------*/\n.action_add {\n  background-image: url(" + escape(__webpack_require__(386)) + ") !important;\n}\n.action_enable {\n  background-image: url(" + escape(__webpack_require__(366)) + ") !important;\n}\n.action_disable {\n  background-image: url(" + escape(__webpack_require__(387)) + ") !important;\n}\n.action_cut {\n  background-image: url(" + escape(__webpack_require__(1442)) + ") !important;\n}\n.action_cut_break {\n  background-image: url(" + escape(__webpack_require__(1443)) + ") !important;\n}\n.action_copy {\n  background-image: url(" + escape(__webpack_require__(530)) + ") !important;\n}\n.action_paste {\n  background-image: url(" + escape(__webpack_require__(1444)) + ") !important;\n}\n.action_remove {\n  background-image: url(" + escape(__webpack_require__(638)) + ") !important;\n}\n.action_edit {\n  background-image: url(" + escape(__webpack_require__(388)) + ") !important;\n}\n.action_move {\n  background-image: url(" + escape(__webpack_require__(531)) + ") !important;\n}\n.action_editcopy {\n  background-image: url(" + escape(__webpack_require__(639)) + ") !important;\n}\n.action_system_link {\n  background-image: url(" + escape(__webpack_require__(1445)) + ") !important;\n}\n/* START svg fixes */\n.x-btn-icon {\n  background-size: 16px 16px !important;\n  background-position: top !important;\n  background-repeat: no-repeat;\n}\n.x-btn-icon-medium-top button {\n  background-size: 22px 22px;\n  background-position: top !important;\n  background-repeat: no-repeat;\n}\n.x-btn-icon-medium-top div.x-btn-image {\n  background-position-y: 2px;\n}\n.x-btn-icon-medium-top .x-btn-split div.x-btn-image {\n  background-position-y: 2px;\n}\n.x-btn-icon-large-top button {\n  background-size: 32px 32px;\n  background-position: top !important;\n  background-repeat: no-repeat;\n}\n/* END svg fixes */\n.action_rename {\n  background-image: url(" + escape(__webpack_require__(388)) + ") !important;\n}\n.action_changecolor {\n  background-image: url(" + escape(__webpack_require__(1446)) + ") !important;\n}\n.action_delete,\n.actionDelete {\n  background-image: url(" + escape(__webpack_require__(638)) + ") !important;\n}\n.x-tbar-page-prev {\n  background-image: url(" + escape(__webpack_require__(389)) + ") !important;\n}\n.x-tbar-page-next {\n  background-image: url(" + escape(__webpack_require__(221)) + ") !important;\n}\n.action_applyChanges {\n  background-image: url(" + escape(__webpack_require__(366)) + ") !important;\n}\n.action_cancel {\n  background-image: url(" + escape(__webpack_require__(387)) + ") !important;\n}\n.action_saveAndClose {\n  background-image: url(" + escape(__webpack_require__(366)) + ") !important;\n}\n.action_next {\n  background-image: url(" + escape(__webpack_require__(221)) + ") !important;\n}\n.x-tbar-loading {\n  background-image: url(" + escape(__webpack_require__(640)) + ") !important;\n}\n.action_previous {\n  background-image: url(" + escape(__webpack_require__(389)) + ") !important;\n}\n.action_managePermissions {\n  background-image: url(" + escape(__webpack_require__(222)) + ") !important;\n}\n.action_manageProperties {\n  background-image: url(" + escape(__webpack_require__(223)) + ") !important;\n}\n.action_addContact {\n  background-image: url(" + escape(__webpack_require__(390)) + ") !important;\n}\n.action_deleteContact {\n  background-image: url(" + escape(__webpack_require__(532)) + ") !important;\n}\n.action_exportAsPdf {\n  background-image: url(" + escape(__webpack_require__(1447)) + ") !important;\n}\n.action_showArchived {\n  background-image: url(" + escape(__webpack_require__(1448)) + ") !important;\n}\n.action_logOut {\n  background-image: url(" + escape(__webpack_require__(1449)) + ") !important;\n}\n.action_login {\n  background-image: url(" + escape(__webpack_require__(640)) + ") !important;\n}\n.action_loadTutorial,\n.action_userManual {\n  background-image: url(" + escape(__webpack_require__(533)) + ") !important;\n}\n.action_uploadImage {\n  background-image: url(" + escape(__webpack_require__(1450)) + ") !important;\n}\n.action_cropImage {\n  background-image: url(" + escape(__webpack_require__(1451)) + ") !important;\n}\n.action_originalImage {\n  background-image: url(" + escape(__webpack_require__(1452)) + ") !important;\n}\n.action_export {\n  background-image: url(" + escape(__webpack_require__(534)) + ") !important;\n}\n.action_import {\n  background-image: url(" + escape(__webpack_require__(1453)) + ") !important;\n}\n.action_about {\n  background-image: url(" + escape(__webpack_require__(223)) + ") !important;\n}\n.action_adminMode {\n  background-image: url(" + escape(__webpack_require__(142)) + ") !important;\n}\n.action_composeEmail {\n  background-image: url(" + escape(__webpack_require__(212)) + ") !important;\n}\n.action_print {\n  background-image: url(" + escape(__webpack_require__(1454)) + ") !important;\n}\n.clipboard {\n  background-image: url(" + escape(__webpack_require__(530)) + ") !important;\n}\n.info {\n  background-image: url(" + escape(__webpack_require__(223)) + ") !important;\n}\n.action_printPreview {\n  background-image: url(" + escape(__webpack_require__(1455)) + ") !important;\n}\n.action_resolveDuplicates {\n  background-image: url(" + escape(__webpack_require__(1456)) + ") !important;\n}\n.tinebase-action-export-xls {\n  background-image: url(" + escape(__webpack_require__(1457)) + ") !important;\n}\n.tinebase-action-export-doc {\n  background-image: url(" + escape(__webpack_require__(1458)) + ") !important;\n}\n.tinebase-action-export-ods {\n  background-image: url(" + escape(__webpack_require__(1459)) + ") !important;\n}\n.tinebase-action-export-csv {\n  background-image: url(" + escape(__webpack_require__(1460)) + ") !important;\n}\n.action_options {\n  background-image: url(" + escape(__webpack_require__(142)) + ") !important;\n}\n.action_attach {\n  background-image: url(" + escape(__webpack_require__(535)) + ") !important;\n}\n.action_image {\n  background-image: url(" + escape(__webpack_require__(641)) + ") !important;\n}\n.tinebase-action-debug-console {\n  background-image: url(" + escape(__webpack_require__(365)) + ") !important;\n}\n.tinebase-dd-drop-ok-copy .x-dd-drop-icon {\n  background-image: url(" + escape(__webpack_require__(639)) + ") !important;\n}\n.tinebase-dd-drop-ok-move .x-dd-drop-icon {\n  background-image: url(" + escape(__webpack_require__(531)) + ") !important;\n}\n/* ----- drop-icon-size ------------------------------------------------------*/\n.x-dd-drop-icon {\n  top: 0px;\n  height: 100%;\n  background-position-y: center;\n  background-size: 16px 16px;\n}\n.x-dd-drop-nodrop .x-dd-drop-icon {\n  background-image: url(" + escape(__webpack_require__(536)) + ");\n}\n.x-dd-drop-ok .x-dd-drop-icon {\n  background-image: url(" + escape(__webpack_require__(1461)) + ");\n}\n.x-dd-drop-ok-add .x-dd-drop-icon {\n  background-image: url(" + escape(__webpack_require__(224)) + ");\n}\n/* ----- tree classes --------------------------------------------------------*/\n.tinebase-tree-drop-move .x-dd-drop-icon {\n  background-image: url(" + escape(__webpack_require__(531)) + ") !important;\n}\n.tinebase-tree-hide-collapsetool .x-tree-ec-icon {\n  background: 0;\n}\n.tinebase-westpanel-node-favorite img.x-tree-node-icon {\n  background-image: url(" + escape(__webpack_require__(642)) + ");\n}\n.tinebase-westpanel-node-favorite-shared img.x-tree-node-icon {\n  background-image: url(" + escape(__webpack_require__(1462)) + ");\n}\n.action-tinebase-favorite {\n  background-image: url(" + escape(__webpack_require__(642)) + ") !important;\n}\n/* ----- login dialog --------------------------------------------------------*/\n.tb-login-panel form {\n  padding: 20px 10px 20px 20px;\n}\n.tb-login-lobobox {\n  text-align: right;\n  height: 60px;\n}\n.tb-login-headsup-box {\n  color: gray;\n  text-align: left;\n  font-size: 32px;\n  font-weight: bold;\n  position: absolute;\n  bottom: 0px;\n}\n.tb-login-lobobox img {\n  max-width: 300px;\n  max-height: 80px;\n}\n.tb-login-big-label {\n  font-size: 16px;\n  font-weight: bold;\n  /*color: gray;*/\n  line-height: 35px;\n}\n.tb-login-button-spacer {\n  height: 30px;\n}\n.tb-login-infosection {\n  padding-left: 20px;\n}\n.tb-login-infosection,\n.tb-login-infotext {\n  color: gray;\n  line-height: 17px;\n  /*margin-top:-12px;*/\n}\n.tb-login-infosection a {\n  text-decoration: none;\n  font-style: normal;\n  color: #1E78AD;\n}\n.tb-login-infotext-logo {\n  max-height: 50px;\n}\n.tb-login-infotext-label {\n  font-weight: bold;\n  font-size: 16px;\n  margin-bottom: 5px;\n}\n/*.tb-login-infosection .tb-login-surveypanel {*/\n/*    padding-top: 20px;*/\n/*}*/\n/* ----- about dialog --------------------------------------------------------*/\n.tb-about-dlg {\n  text-align: center;\n}\n.tb-about-img {\n  margin-top: 10px;\n}\n.tb-about-img img {\n  max-width: 380px;\n  max-height: 80px;\n}\n.tb-about-version {\n  margin-top: 50px;\n  font-weight: bold;\n}\n.tb-about-build {\n  font-size: smaller;\n}\n.tb-about-copyright {\n  margin-top: 50px;\n}\n.tb-about-credits-license {\n  margin-top: 10px;\n}\n.tb-about-whatsnew p {\n  background: transparent url(" + escape(__webpack_require__(223)) + ") left top no-repeat;\n  padding: 2px 0 2px 20px;\n}\n/* -------- tags renderer ------------------------------------------------------------*/\n.tw-tagtogglebox .tagcheckel {\n  display: inline;\n  margin-right: 3px;\n}\n.tw-tagtogglebox .tb-grid-tags {\n  display: inline;\n  position: absolute;\n  float: inherit;\n  top: 3px;\n}\n.tb-grid-tags {\n  width: 8px;\n  height: 8px;\n  border: 1px solid black;\n  float: left;\n  margin-right: 2px;\n  margin-top: 3px;\n  border-radius: 5px;\n}\n.x-grid3-cell-inner .tb-grid-tags {\n  margin-top: 1px;\n}\n.tw-tagtogglebox .x-combo-list-item {\n  position: relative;\n}\n.x-menu-item-text .tb-grid-tags {\n  margin-top: 4px;\n}\n.x-menu-item-text .x-widget-tag-tagitem-text {\n  line-height: 16px;\n}\n/* ----- account renderer ------------------------------------------------------------*/\n.renderer {\n  width: 16px;\n  float: left;\n  padding-left: 5px;\n}\n.renderer_accountUserIcon {\n  background-image: url(" + escape(__webpack_require__(225)) + ") !important;\n}\n.renderer_accountUserChangedIcon {\n  background-image: url(" + escape(__webpack_require__(225)) + ") !important;\n  background-color: red !important;\n}\n.renderer_accountAnyoneIcon {\n  background-image: url(" + escape(__webpack_require__(169)) + ") !important;\n}\n.renderer_accountGroupIcon {\n  background-image: url(" + escape(__webpack_require__(169)) + ") !important;\n}\n.renderer_accountGroupmemberIcon {\n  background-image: url(" + escape(__webpack_require__(537)) + ") !important;\n}\n.renderer_accountRoleIcon {\n  background-image: url(" + escape(__webpack_require__(643)) + ") !important;\n}\n.renderer_accountContactIcon {\n  background-image: url(" + escape(__webpack_require__(225)) + ") !important;\n}\n.tinebase-accounttype-user {\n  background-image: url(" + escape(__webpack_require__(225)) + ") !important;\n}\n.tinebase-accounttype-group {\n  background-image: url(" + escape(__webpack_require__(169)) + ") !important;\n}\n.tinebase-accounttype-role {\n  background-image: url(" + escape(__webpack_require__(643)) + ") !important;\n}\n.tinebase-accounttype-addanyone {\n  background-image: url(" + escape(__webpack_require__(169)) + ") !important;\n}\n/* TODO make this work */\n.x-tine-relation-degree-value {\n  color: black;\n  font-size: 11px;\n}\n.action_mute_noteification {\n  background-image: url(" + escape(__webpack_require__(1463)) + ") !important;\n}\n.action_noteification {\n  background-image: url(" + escape(__webpack_require__(1464)) + ") !important;\n}\n.action_preview {\n  background-image: url(" + escape(__webpack_require__(644)) + ") !important;\n}\n/* ----- notes ------------------------------------------------------------*/\n.notes_noteIcon {\n  background-image: url(" + escape(__webpack_require__(388)) + ") !important;\n}\n.notes_telephoneIcon {\n  background-image: url(" + escape(__webpack_require__(367)) + ") !important;\n}\n.notes_emailIcon {\n  background-image: url(" + escape(__webpack_require__(212)) + ") !important;\n}\n.descriptionIcon {\n  background-image: url(" + escape(__webpack_require__(1465)) + ") !important;\n}\n/* ----- mainmenu ------------------------------------------------------------*/\n/*\n.tine-mainscreen-mainmenu .x-toolbar {\n    background-image: url(../../images/tbar-menu-bg.gif);\n    border: 0;\n    margin-top: -1px;\n    height: 18px;\n}\n*/\n.tine-mainscreen-mainmenu .x-toolbar {\n  background-color: #EBF3FD;\n  border: none;\n  background-image: url(" + escape(__webpack_require__(645)) + ");\n}\n.tine-mainscreen-mainmenu .x-toolbar .x-btn td {\n  background: none;\n  border: none;\n}\n.tine-mainscreen-mainmenu .x-toolbar-ct {\n  margin-top: -2px;\n}\n.tine-mainscreen-mainmenu .x-btn-over td.x-btn-mc,\n.tine-mainscreen-mainmenu .x-btn-over td.x-btn-mc button {\n  text-decoration: underline;\n}\n.x-btn-group-bwrap .x-toolbar-cell {\n  vertical-align: top;\n}\n.tine-favicon {\n  /* NOTE: favicon is configured at runtime! */\n  background-size: 16px 16px;\n}\n.x-btn-image.tine-favicon,\nspan .x-tab-strip-text.tine-favicon {\n  background-position-y: 2px !important;\n  background-size: 15px 15px !important;\n}\n.tine-mainscreen-apptabs .x-tab-strip-wrap ul.x-tab-strip-top {\n  background-color: #EBF3FD;\n  background-image: url(" + escape(__webpack_require__(645)) + ");\n  border-bottom-color: #8db2e3;\n  background-position: 0px -20px;\n}\n.tine-mainscreen-apptabs .x-tab-panel-header {\n  border: none;\n}\n/*\n.tine-mainscreen-apptabs .x-tab-strip-wrap {\n    padding-top: 2px;\n}\n*/\n/*.tine-mainscreen-apptabspanel-menu-tabel .x-tab-left {*/\n/*    background-image: url(../../images/tabs_sprite_slope_right.gif);*/\n/*    padding-right: 24px;*/\n/*}*/\n/*.tine-mainscreen-apptabspanel-menu-tabel {*/\n/*    margin-right: -10px;*/\n/*}*/\n/*.x-tab-strip .tine-mainscreen-apptabspanel-menu-tabel span.x-tab-strip-text {*/\n/*    padding-right: 10px;*/\n/*}*/\n.x-tab-strip li.tine-mainscreen-apptabspanel-menu-tabel a.x-tab-strip-close,\n.x-tab-strip li.tine-mainscreen-apptabspanel-menu-tabel a.x-tab-strip-close:hover {\n  background-image: url(" + escape(__webpack_require__(226)) + ");\n  background-size: 11px 11px;\n  top: 5px;\n  /*right: 19px;*/\n}\n.x-tab-strip li.tine-mainscreen-apptabspanel-menu-tabel span.x-tab-strip-text:hover,\n.x-tab-strip-active li.tine-mainscreen-apptabspanel-menu-tabel span.x-tab-strip-text {\n  color: #000000;\n  font-weight: normal;\n}\nul.x-tab-strip li.tine-mainscreen-apptabspanel-menu-tabel {\n  background-color: #D9DFD7;\n}\nul.x-tab-strip li.tine-mainscreen-apptabspanel-menu-tabel:hover {\n  background-color: #C3CED8;\n}\n/* ----- appchooser panel-----------------------------------------------------*/\n.app-panel-title {\n  font-size: 15px;\n  font-weight: normal;\n  padding-top: 7px;\n}\n.app-panel-header-active {\n  background: transparent url(" + escape(__webpack_require__(605)) + ") repeat-x scroll 0pt -9px;\n  /*background:#EBF3FD url(../../library/ExtJS/resources/images/default/grid/grid3-hrow-over.gif) repeat-x scroll left bottom;*/\n}\n.app-panel-header-over {\n  /*background:transparent url(../../library/ExtJS/resources/images/default/panel/light-hd.gif) repeat-x scroll 0pt -9px;*/\n  background: #EBF3FD url(" + escape(__webpack_require__(233)) + ") repeat-x scroll left bottom;\n}\n.app-panel-appicon-text {\n  position: absolute;\n  top: 0px;\n  width: 20px;\n  overflow: hidden;\n}\n.app-panel-apptitle-text {\n  margin-left: 5px;\n}\n/******* grid row classes *********/\n.grid_row_enabled td {\n  font-weight: bold;\n  /* background-color: '#b5efc8'; */\n}\n.grid_row_disabled td {\n  /* background-color: '#efb5b5'; */\n}\n.x-grid3-cell-inner,\n.x-grid3-hd-inner {\n  white-space: nowrap;\n}\n.tw-activities-grid .x-grid3-cell-inner {\n  white-space: normal;\n}\n.tine-grid-row-nolongerinfilter td {\n  color: #aaaaaa;\n}\n.tine-grid-row-action-icon {\n  background-size: 16px 16px;\n  background-repeat: no-repeat;\n  height: 16px;\n  margin: -2px;\n}\n/******* grid cell classes *********/\n.tine-grid-cell-hint {\n  background-image: url(" + escape(__webpack_require__(226)) + ");\n  position: absolute;\n  top: 0px;\n  right: 0px;\n  width: 10px;\n}\n.tine-grid-cell-no-dirty {\n  background-image: url(" + escape(__webpack_require__(231)) + ");\n}\n.tine-gird-cell-date,\n.tine-gird-cell-datetime,\n.tine-gird-cell-time,\n.tine-gird-cell-number {\n  text-align: right;\n}\n.tine-dublicateResolve-cell {\n  text-align: left !important;\n}\n.tine-editorgrid-row-invalid,\n.x-grid3-row-selected .tine-editorgrid-row-invalid {\n  border: 1px dotted red!important;\n}\n.tine-duplicateresolve-keepvalue {\n  color: #006600;\n}\n.tine-duplicateresolve-discardvalue {\n  color: #660000;\n}\n.tine-duplicateresolve-adoptedvalue {\n  color: #666666;\n}\n.tine-recordclass-gridicon {\n  background-repeat: no-repeat;\n  display: block;\n  height: 16px;\n  width: 16px;\n  margin: -2px 5px -2px 0;\n  float: left;\n  background-size: 16px;\n}\n/******** downloads ***********/\n.tinebase-download-link {\n  cursor: pointer;\n  color: blue;\n  display: inline-block;\n}\n.tinebase-download-link b {\n  color: black;\n}\nspan:hover.tinebase-download-link {\n  color: #4444ff;\n  background-image: url(" + escape(__webpack_require__(143)) + ") !important;\n  background-repeat: no-repeat;\n  background-position: right;\n  background-size: 10px 10px;\n}\n.tinebase-download-link-wait {\n  margin-top: 2px;\n  margin-left: 2px;\n  height: 10px;\n  float: right;\n  width: 10px;\n}\n.tinebase-download-link.tinebase-download-all {\n  margin-right: 2px;\n}\n.action_download {\n  background-image: url(" + escape(__webpack_require__(170)) + ") !important;\n}\n.action_upload {\n  background-image: url(" + escape(__webpack_require__(538)) + ") !important;\n}\n.action_upload_uploading {\n  animation-name: uploading-animation;\n  animation-duration: 1500ms;\n  animation-iteration-count: infinite;\n}\n.action_upload_idle {\n  background-image: url(" + escape(__webpack_require__(539)) + ") !important;\n}\n/******** email ***********/\na:hover.tinebase-email-link {\n  cursor: pointer;\n  color: #4444ff;\n}\n.tinebase-addtocontacts-link {\n  cursor: pointer;\n  color: blue;\n}\nspan:hover.tinebase-addtocontacts-link {\n  color: #4444ff;\n}\n.tinebase-showheaders-link {\n  cursor: pointer;\n  color: blue;\n}\nspan:hover.tinebase-showheaders-link {\n  color: #4444ff;\n}\n.tine-keyfield-icon {\n  width: 12px;\n  height: 12px;\n  vertical-align: text-bottom;\n  padding-right: 4px;\n  transform: scale(1.3);\n}\n.x-grid .tine-keyfield-icon {\n  vertical-align: text-top;\n}\n/*.x-combo-list-item .tine-keyfield-icon {\n    padding-right: 4px;\n}*/\n.search-item {\n  border: 1px solid white;\n}\n.search-combo-col td {\n  max-width: 0;\n  overflow: hidden;\n  text-overflow: ellipsis;\n  white-space: nowrap;\n}\n/* multiple edit dialog */\n.tinebase-editmultipledialog-noneedit,\ninput.tinebase-editmultipledialog-noneedit,\ntextarea.x-form-field.tinebase-editmultipledialog-noneedit {\n  background-color: #f4f1d3;\n  background-image: none!important;\n}\n.tinebase-editmultipledialog-clearer.over,\n.tinebase-editmultipledialog-clearer {\n  background-image: url(" + escape(__webpack_require__(227)) + ") !important;\n  background-position: 0px;\n  height: 14px;\n  width: 14px;\n  top: 7px;\n  display: block;\n  position: absolute;\n  z-index: 9;\n  background-size: 14px 14px;\n}\n.tinebase-editmultipledialog-clearer.hidden {\n  border-bottom: none;\n  background-image: url(" + escape(__webpack_require__(231)) + ");\n}\n.tinebase-editmultipledialog-clearer.undo.over,\n.tinebase-editmultipledialog-clearer.undo {\n  background-position: center;\n  background-image: url(" + escape(__webpack_require__(1466)) + ") !important;\n  border-bottom: none;\n}\n.tinebase-editmultipledialog-dirty {\n  position: absolute;\n  left: 0;\n  /*background-image:url(../../images/icon-set/icon_data-dirty_red.svg) !important;*/\n  background-image: url(" + escape(__webpack_require__(595)) + ");\n  background-repeat: no-repeat;\n}\n.tinebase-editmultipledialog-dirtycheck {\n  background-color: #F4F1D3;\n  /* #F9F9A3 */\n  border: 1px solid #B5B8C8;\n  padding: 2px 2px 1px 2px;\n  border-radius: 3px;\n}\n.tine-wordbox {\n  border: 1px solid gray;\n  margin-left: 3px;\n  border-radius: 2px;\n  padding: 0px 5px;\n  background-color: white;\n}\n/* token mode edit dialog */\n.tinebase-tokenedit-textfield {\n  color: white;\n}\n.tinebase-tokenedit-tokenbox {\n  position: absolute;\n  background-color: white;\n  z-index: 100;\n  overflow: hidden;\n}\n.tinebase-tokenedit-token {\n  border: 1px solid gray;\n  margin-right: 3px;\n}\n.tinebase-tokenedit-tokenbox-area .tinebase-tokenedit-token {\n  display: inline-block;\n  line-height: 13px;\n}\n.tinebase-tokenedit-token-selected {\n  background-color: #FFFFAE;\n}\n.tinebase-tokenedit-position {\n  display: none;\n  width: 0px;\n  border: 1px solid gray;\n  margin-right: 3px;\n  line-height: 13px;\n  overflow: hidden;\n}\n.tb-version-tinepanel {\n  display: none;\n}\n.tine-license-red {\n  background-color: red !important;\n}\n.tb-widgets-path-pathsblock {\n  padding-top: 2px;\n  padding-left: 4px;\n}\n.tb-widgets-path-pathitem {\n  font-size: 9px;\n  color: grey;\n  text-overflow: ellipsis;\n  white-space: nowrap;\n  overflow: hidden;\n  display: block;\n}\n.tb-widgets-path-pathitem-match {\n  color: black;\n}\n.tb-widgets-path-pathitem-type {\n  color: black;\n  font-size: 7px;\n}\n.tb-widgets-path-pathitem-separator {\n  color: black;\n}\n.x-form-field-trigger-wrap input {\n  border-top-right-radius: 0px;\n  border-bottom-right-radius: 0px;\n}\n.x-form-radio-group .x-form-item {\n  padding-left: 2px;\n}\n.rangeslider-component-sliderwrap {\n  border: 1px solid black;\n}\n.rangeslider-component-sliderBorder {\n  border: 1px solid black;\n  border-radius: 3px;\n  background-color: #cdcdcd;\n}\n.rangeslider-component .rangeslider-component-slider .rangeslider-component-slider-label {\n  display: table-cell;\n  text-align: center;\n  vertical-align: middle;\n  white-space: nowrap;\n  padding-left: 10px;\n  padding-right: 10px;\n}\n.rangeslider-component .rangeslider-component-slider {\n  background-color: #b7f8bd;\n  overflow: hidden;\n}\n.x-item-disabled.rangeslider-component .rangeslider-component-slider,\n.x-item-disabled.rangeslider-component .rangeslider-component-slider-label {\n  visibility: hidden !important;\n}\n.ext-el-mask-msg.tb-arealocks-msg,\n.ext-el-mask-msg.tb-arealocks-msg div,\n.tb-arealocks-msg .ext-el-mask-wait x-mask-wait {\n  border: none !important;\n  background: none;\n  cursor: pointer;\n}\n.ext-el-mask-msg {\n  border: none;\n  background: none;\n  cursor: pointer;\n}\n.ext-el-mask-msg div {\n  padding-left: 23px;\n}\n.tine-tinebase-recorddisplaypanel-displayfield .x-form-display-field {\n  display: inline-block;\n}\n.x-tree-node-expanded .x-tree-node-icon {\n  background-image: url(" + escape(__webpack_require__(1467)) + ") !important;\n}\n.x-tree-node-collapsed .x-tree-node-icon {\n  background-image: url(" + escape(__webpack_require__(163)) + ") !important;\n}\n.x-tree-node-leaf .x-tree-node-icon {\n  background-image: url(" + escape(__webpack_require__(163)) + ");\n}\n/*.x-form-field-wrap .x-form-search-trigger {*/\n/*background-image: url(../../images/icon-set/icon_search.svg);*/\n/*}*/\n.x-tab-strip .x-tab-with-icon span.x-tab-strip-text {\n  background-size: 16px 16px;\n  padding-left: 20px;\n  background-position: 0 2px;\n  background-repeat: no-repeat;\n}\n.x-btn.x-btn-icon .x-tbar-page-first {\n  background: url(" + escape(__webpack_require__(1468)) + ") !important;\n  background-size: cover !important;\n}\n.x-btn.x-btn-icon .x-tbar-page-prev {\n  background: url(" + escape(__webpack_require__(389)) + ") !important;\n  background-size: cover !important;\n}\n.x-btn.x-btn-icon .x-tbar-page-last {\n  background: url(" + escape(__webpack_require__(1469)) + ") !important;\n  background-size: cover !important;\n}\n.x-btn.x-btn-icon .x-tbar-page-next {\n  background: url(" + escape(__webpack_require__(221)) + ") !important;\n  background-size: cover !important;\n}\n.x-cols-icon {\n  background: url(" + escape(__webpack_require__(1470)) + ") !important;\n}\n/* only works for small btns as we don't have to align them*/\n.x-btn {\n  position: relative;\n}\n.x-btn-image {\n  top: 2px;\n  position: absolute;\n  width: 16px;\n  height: 16px;\n  background-size: cover;\n  background-repeat: no-repeat;\n}\n.x-btn-medium.x-btn-icon-medium-top .x-btn-arrow .x-btn-image {\n  margin-left: -5px;\n}\n.x-btn-medium.x-btn-icon-medium-top .x-btn-split .x-btn-image {\n  margin-left: -7px;\n}\n.x-btn-medium.x-btn-icon-medium-top .x-btn-image {\n  background-repeat: no-repeat;\n  top: 0px;\n  left: 0px;\n  position: absolute;\n  width: 100%;\n  height: 100%;\n  background-size: 29px 29px;\n  background-position-x: center;\n}\n/* loading animations */\n@keyframes loading-animation {\n  from {\n    transform: rotate(0deg);\n  }\n  to {\n    transform: rotate(360deg);\n  }\n}\n/* loading animations */\n@keyframes uploading-animation {\n  0% {\n    background-image: url(" + escape(__webpack_require__(1471)) + ");\n  }\n  10% {\n    background-image: url(" + escape(__webpack_require__(1472)) + ");\n  }\n  20% {\n    background-image: url(" + escape(__webpack_require__(1473)) + ");\n  }\n  30% {\n    background-image: url(" + escape(__webpack_require__(1474)) + ");\n  }\n  40% {\n    background-image: url(" + escape(__webpack_require__(1475)) + ");\n  }\n  50% {\n    background-image: url(" + escape(__webpack_require__(1476)) + ");\n  }\n  60% {\n    background-image: url(" + escape(__webpack_require__(646)) + ");\n  }\n  100% {\n    background-image: url(" + escape(__webpack_require__(646)) + ");\n  }\n}\n.tine-viewport-waitcycle,\n.loading-indicator-wait,\n.x-tree-node-loading .x-tree-node-icon,\n.x-mask-wait,\n.x-btn-wait + div,\ndiv.x-btn-wait,\n.x-item-disabled .x-tbar-loading + div,\n.tinebase-download-link-anim .tinebase-download-link-wait,\n.felamimail-node-statusbox-progress-loading,\n.x-item-disabled .x-tbar-loading {\n  animation-name: loading-animation;\n  animation-duration: 1000ms;\n  animation-iteration-count: infinite;\n  animation-timing-function: cubic-bezier(0.17, 0.67, 0.52, 0.71);\n}\n.tine-viewport-waitcycle {\n  position: absolute;\n  top: 50%;\n  left: 50%;\n  width: 32px;\n  height: 32px;\n}\n.x-tree-node-el.x-tree-node-loading img.x-tree-node-icon,\n.x-item-disabled .x-tbar-loading,\n.x-btn-wait {\n  background-image: none !important;\n}\n.x-tree-node-loading .x-tree-node-icon,\n.x-item-disabled .x-tbar-loading + div,\n.x-item-disabled div.x-tbar-loading,\ndiv.x-btn-wait,\n.x-btn-wait + div {\n  width: 12px;\n  height: 12px;\n  top: 5px;\n  left: 5px;\n}\n.x-tree-node-loading .x-tree-node-icon,\n.loading-indicator-wait,\n.tine-viewport-waitcycle,\n.x-mask-wait,\n.x-item-disabled .x-tbar-loading + div,\n.x-item-disabled div.x-tbar-loading,\ndiv.x-btn-wait,\n.tinebase-download-link-anim .tinebase-download-link-wait,\n.felamimail-node-statusbox-progress-loading,\n.x-btn-wait + div {\n  box-sizing: border-box;\n  border: 2px solid #ccc !important;\n  border-top: 2px solid #2196f3 !important;\n  border-radius: 100%;\n}\n.x-pie-0 {\n  background-image: url(" + escape(__webpack_require__(1477)) + ");\n}\n.x-pie-10 {\n  background-image: url(" + escape(__webpack_require__(1478)) + ");\n}\n.x-pie-20 {\n  background-image: url(" + escape(__webpack_require__(1479)) + ");\n}\n.x-pie-30 {\n  background-image: url(" + escape(__webpack_require__(1480)) + ");\n}\n.x-pie-40 {\n  background-image: url(" + escape(__webpack_require__(1481)) + ");\n}\n.x-pie-50 {\n  background-image: url(" + escape(__webpack_require__(1482)) + ");\n}\n.x-pie-60 {\n  background-image: url(" + escape(__webpack_require__(1483)) + ");\n}\n.x-pie-70 {\n  background-image: url(" + escape(__webpack_require__(1484)) + ");\n}\n.x-pie-80 {\n  background-image: url(" + escape(__webpack_require__(1485)) + ");\n}\n.x-pie-90 {\n  background-image: url(" + escape(__webpack_require__(1486)) + ");\n}\n.x-pie-100 {\n  background-image: url(" + escape(__webpack_require__(1487)) + ");\n}\n.MD .x-pie-0,\n.LG .x-pie-0 {\n  background-image: url(" + escape(__webpack_require__(1488)) + ");\n}\n.MD .x-pie-10,\n.LG .x-pie-10 {\n  background-image: url(" + escape(__webpack_require__(1489)) + ");\n}\n.MD .x-pie-20,\n.LG .x-pie-20 {\n  background-image: url(" + escape(__webpack_require__(1490)) + ");\n}\n.MD .x-pie-30,\n.LG .x-pie-30 {\n  background-image: url(" + escape(__webpack_require__(1491)) + ");\n}\n.MD .x-pie-40,\n.LG .x-pie-40 {\n  background-image: url(" + escape(__webpack_require__(1492)) + ");\n}\n.MD .x-pie-50,\n.LG .x-pie-50 {\n  background-image: url(" + escape(__webpack_require__(1493)) + ");\n}\n.MD .x-pie-60,\n.LG .x-pie-60 {\n  background-image: url(" + escape(__webpack_require__(1494)) + ");\n}\n.MD .x-pie-70,\n.LG .x-pie-70 {\n  background-image: url(" + escape(__webpack_require__(1495)) + ");\n}\n.MD .x-pie-80,\n.LG .x-pie-80 {\n  background-image: url(" + escape(__webpack_require__(1496)) + ");\n}\n.MD .x-pie-90,\n.LG .x-pie-90 {\n  background-image: url(" + escape(__webpack_require__(1497)) + ");\n}\n.MD .x-pie-100,\n.LG .x-pie-100 {\n  background-image: url(" + escape(__webpack_require__(1498)) + ");\n}\n.x-btn-medium.x-btn-icon-medium-top div.x-btn-wait {\n  width: 28px;\n  height: 28px;\n  left: 14px;\n}\n.x-tree-node-loading .x-tree-node-icon {\n  margin-top: 3px;\n}\n.x-mask-loading {\n  background: none;\n  border: none;\n}\n.x-mask-loading div {\n  background-image: none !important;\n}\n.x-mask-wait {\n  left: 8px;\n  padding: 0px !important;\n  position: absolute;\n  top: 6px;\n  height: 16px;\n  width: 16px;\n  margin: 0px;\n  background-image: none !important;\n}\n.loading-indicator-wait {\n  position: absolute;\n  top: 4px;\n  left: 4px;\n  width: 14px;\n  height: 14px;\n}\n.x-combo-list-inner .loading-indicator {\n  background: none;\n}\n", ""]);

// exports


/***/ }),
/* 1442 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bclip-path:url(%23SVGID_2_);%7D %3C/style%3E %3Cg%3E %3Cg%3E %3Cdefs%3E %3Crect id='SVGID_1_' x='1' y='7' width='40.7' height='29.3'/%3E %3C/defs%3E %3CclipPath id='SVGID_2_'%3E %3Cuse xlink:href='%23SVGID_1_' style='overflow:visible;'/%3E %3C/clipPath%3E %3Cpath class='st0' d='M37.5,12.4c0,0-2.2-1.9-4.1-0.9c-1.5,0.8-10.7,5.5-14.9,7.6l-5.8-3.3c0.6-1.1,0.7-2.4,0.4-3.7 c-0.4-1.6-1.6-3.1-3.3-4.1c-3-1.7-6.7-1.1-8.1,1.5c-0.6,1.1-0.8,2.4-0.4,3.7c0.4,1.6,1.6,3.1,3.3,4.1c0.7,0.4,1.5,0.7,2.3,0.8 c0,0,0,0,0,0c0.1,0,0.1,0,0.2,0c4.8,0.7,7.3,2.1,8.5,3c-1.2,1-3.7,2.3-8.5,3c-0.1,0-0.1,0-0.2,0c0,0,0,0,0,0 C6,24.3,5.2,24.6,4.5,25c-1.7,1-2.8,2.5-3.3,4.1c-0.3,1.3-0.2,2.6,0.4,3.7c1.5,2.6,5.1,3.2,8.1,1.5c1.7-1,2.8-2.5,3.3-4.1 c0.3-1.3,0.2-2.6-0.4-3.7l5.8-3.3c4.1,2.1,13.4,6.7,14.9,7.6c1.9,1.1,4.1-0.9,4.1-0.9l-15.4-8.8L37.5,12.4z M10.1,14.3 c-0.7,1.2-2.6,1.3-4.2,0.4c-1-0.5-1.7-1.4-1.9-2.3c-0.1-0.4-0.2-1,0.1-1.5c0.7-1.2,2.6-1.3,4.2-0.4c1,0.6,1.7,1.4,1.9,2.3 C10.4,13.2,10.4,13.8,10.1,14.3L10.1,14.3z M10.3,29.5c-0.3,0.9-1,1.8-1.9,2.3c-1.6,0.9-3.6,0.7-4.2-0.4c-0.3-0.5-0.2-1.1-0.1-1.5 c0.2-0.9,1-1.8,1.9-2.3c1.6-0.9,3.6-0.7,4.2,0.4C10.4,28.5,10.4,29.1,10.3,29.5L10.3,29.5z M10.3,29.5'/%3E %3C/g%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1443 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M39.5,7.9c-0.3-0.3-0.7-0.5-1.2-0.5h-9.9V5.6c0-0.5-0.2-0.8-0.5-1.2S27.3,4,26.9,4H11.5c-0.5,0-1,0.1-1.5,0.3 C9.5,4.6,9,4.8,8.7,5.2l-5.3,5.3c-0.3,0.3-0.6,0.8-0.8,1.3c-0.2,0.5-0.3,1-0.3,1.5V33c0,0.5,0.2,0.8,0.5,1.2s0.7,0.5,1.2,0.5h9.9 v1.7c0,0.5,0.2,0.8,0.5,1.2s0.7,0.5,1.2,0.5h23c0.5,0,0.8-0.2,1.2-0.5s0.5-0.7,0.5-1.2V9C40,8.6,39.8,8.2,39.5,7.9z M4.9,12.1 l5.4-5.4c0.1-0.1,0.4-0.3,0.7-0.4v6.4H4.5C4.7,12.4,4.8,12.2,4.9,12.1z M14.9,13.9c-0.3,0.3-0.6,0.8-0.8,1.3c-0.2,0.5-0.3,1-0.3,1.5 v15.8H4.4V15h7.1c0.5,0,0.8-0.2,1.2-0.5s0.5-0.7,0.5-1.2V6.2h13.1v1.2H23c-0.5,0-1,0.1-1.5,0.3c-0.5,0.2-1,0.5-1.3,0.8L14.9,13.9z M22.5,9.7v6.4h-6.4c0.1-0.3,0.2-0.6,0.4-0.7l5.4-5.4C22,9.9,22.2,9.8,22.5,9.7z M37.9,35.8H15.9V18.3h7.1c0.5,0,0.8-0.2,1.2-0.5 s0.5-0.7,0.5-1.2V9.5h13.1V35.8z'/%3E %3Cpath d='M22.4,23.1c0-0.2,0.1-0.3,0.2-0.4l0.9-0.9c0.1-0.1,0.3-0.2,0.4-0.2c0.2,0,0.3,0.1,0.4,0.2l3,3l3-3c0.1-0.1,0.3-0.2,0.4-0.2 c0.2,0,0.3,0.1,0.4,0.2l0.9,0.9c0.1,0.1,0.2,0.3,0.2,0.4c0,0.2-0.1,0.3-0.2,0.4l-3,3l3,3c0.1,0.1,0.2,0.3,0.2,0.4 c0,0.2-0.1,0.3-0.2,0.4l-0.9,0.9c-0.1,0.1-0.3,0.2-0.4,0.2c-0.2,0-0.3-0.1-0.4-0.2l-3-3l-3,3c-0.1,0.1-0.3,0.2-0.4,0.2 c-0.2,0-0.3-0.1-0.4-0.2l-0.9-0.9c-0.1-0.1-0.2-0.3-0.2-0.4c0-0.2,0.1-0.3,0.2-0.4l3-3l-3-3C22.5,23.4,22.4,23.3,22.4,23.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1444 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='paste-from-clipboard' d='M28,8.5c-0.7-0.4-1.4-0.8-2.1-1c-0.3-0.8-0.8-1.6-1.5-2.1C23.5,4.5,22.3,4,21,4 c-1.2,0-2.5,0.5-3.4,1.3c-0.6,0.6-1.1,1.3-1.5,2.1c-0.7,0.2-1.4,0.5-2.1,1h-2.8C9.5,8.5,8,9.9,8,11.7v23c0,1.8,1.5,3.3,3.3,3.3h19.5 c1.8,0,3.3-1.5,3.3-3.3v-23c0-1.8-1.5-3.3-3.3-3.3H28z M18.3,8.9c0-0.1,0.1-0.3,0.1-0.4c0.4-1.2,1.4-2,2.7-2c1.2,0,2.3,0.9,2.7,2 c0,0.1,0.1,0.3,0.1,0.4c0.1,0.3,0.3,0.6,0.6,0.7c1.2,0.3,2.1,0.8,2.7,1.3c0.1,0.1,0.2,0.2,0.3,0.3c0.4,0.5,0.1,1.1-0.5,1.1H15.2 c-0.6,0-0.9-0.7-0.5-1.1c0.1-0.1,0.2-0.2,0.3-0.3c0.6-0.6,1.6-1,2.7-1.3C18,9.5,18.2,9.2,18.3,8.9L18.3,8.9z M31.7,11.7v23 c0,0.5-0.4,0.9-0.9,0.9H11.3c-0.5,0-0.9-0.4-0.9-0.9v-23c0-0.5,0.4-0.9,0.9-0.9h0.9c0,0.1-0.1,0.2-0.1,0.4c-0.1,0.6,0,1.1,0.3,1.7 c0.2,0.5,0.6,1,1.1,1.3c0.5,0.3,1.1,0.5,1.7,0.5h11.7c0.6,0,1.2-0.2,1.7-0.5c0.5-0.3,0.8-0.8,1.1-1.3c0.2-0.5,0.3-1.1,0.3-1.7 c0-0.1,0-0.2-0.1-0.4h0.9C31.3,10.9,31.7,11.2,31.7,11.7L31.7,11.7z M31.7,11.7 M21,10.1c0.7,0,1.2-0.5,1.2-1.2c0-0.2,0-0.3-0.1-0.4 C22,8,21.6,7.7,21,7.7c-0.5,0-1,0.3-1.1,0.8c-0.1,0.1-0.1,0.3-0.1,0.4C19.8,9.6,20.4,10.1,21,10.1L21,10.1z M21,10.1 M15.4,26.4 c-0.1-0.1-0.2-0.3-0.2-0.4v-1.2c0-0.2,0.1-0.3,0.2-0.4s0.3-0.2,0.4-0.2h4.3v-4.3c0-0.2,0.1-0.3,0.2-0.4s0.3-0.2,0.4-0.2h1.2 c0.2,0,0.3,0.1,0.4,0.2s0.2,0.3,0.2,0.4v4.3h4.3c0.2,0,0.3,0.1,0.4,0.2s0.2,0.3,0.2,0.4V26c0,0.2-0.1,0.3-0.2,0.4s-0.3,0.2-0.4,0.2 h-4.3v4.3c0,0.2-0.1,0.3-0.2,0.4s-0.3,0.2-0.4,0.2h-1.2c-0.2,0-0.3-0.1-0.4-0.2s-0.2-0.3-0.2-0.4v-4.3h-4.3 C15.6,26.6,15.5,26.5,15.4,26.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1445 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M15.9,26c-1.4-1.4-2.1-3.1-2.1-5.1c0-2,0.7-3.7,2.1-5.1c1.4-1.4,3.1-2.1,5.1-2.1c2,0,3.7,0.7,5.1,2.1 c0.8,0.8,1.4,1.7,1.7,2.7l6.1,6.1l3.4-0.5c0.2,0,0.3-0.1,0.4-0.3c0.1-0.2,0.2-0.3,0.2-0.5v-4.9c0-0.2-0.1-0.4-0.2-0.5 c-0.1-0.2-0.3-0.2-0.5-0.3l-4-0.6c-0.2-0.7-0.5-1.4-0.9-2.2c0.3-0.4,0.7-0.9,1.2-1.6c0.5-0.7,0.9-1.2,1.1-1.5 c0.1-0.2,0.2-0.3,0.2-0.5c0-0.2-0.1-0.4-0.2-0.5c-0.5-0.8-1.7-2-3.6-3.8C30.8,7.1,30.7,7,30.5,7c-0.2,0-0.4,0.1-0.5,0.2l-3.1,2.4 c-0.6-0.3-1.3-0.6-2-0.8l-0.6-4.1c0-0.2-0.1-0.3-0.3-0.5C23.8,4.1,23.6,4,23.4,4h-4.9c-0.4,0-0.7,0.2-0.8,0.6 c-0.2,0.7-0.4,2.1-0.6,4.1c-0.7,0.2-1.4,0.5-2,0.8l-3-2.4C11.8,7.1,11.6,7,11.4,7c-0.3,0-1,0.5-2.1,1.6c-1.1,1.1-1.8,1.8-2.2,2.4 C7,11.1,7,11.3,7,11.4c0,0.2,0.1,0.4,0.2,0.5c1,1.2,1.8,2.2,2.4,3c-0.4,0.7-0.7,1.4-0.9,2l-4.1,0.6c-0.2,0-0.3,0.1-0.4,0.3 S4,18.3,4,18.5v4.9c0,0.2,0.1,0.4,0.2,0.5c0.1,0.2,0.3,0.2,0.5,0.3l4,0.6c0.2,0.7,0.5,1.4,0.9,2.2c-0.3,0.4-0.7,0.9-1.2,1.6 c-0.5,0.7-0.9,1.2-1.1,1.5c-0.1,0.2-0.2,0.3-0.2,0.5c0,0.2,0.1,0.4,0.2,0.5c0.6,0.8,1.8,2,3.6,3.7c0.2,0.2,0.3,0.2,0.6,0.2 c0.2,0,0.4-0.1,0.6-0.2l3.1-2.4c0.6,0.3,1.3,0.6,2,0.8l0.6,4.1c0,0.2,0.1,0.3,0.3,0.5c0.2,0.1,0.3,0.2,0.5,0.2h4.9 c0.4,0,0.7-0.2,0.8-0.6c0.2-0.7,0.4-1.9,0.6-3.7L19,27.9C17.8,27.6,16.8,26.9,15.9,26z'/%3E %3C/g%3E %3Cpath d='M35.7,32.8c0-0.3-0.1-0.6-0.3-0.8l-2.4-2.4c-0.2-0.2-0.5-0.3-0.8-0.3c-0.3,0-0.6,0.1-0.8,0.4c0,0,0.1,0.1,0.2,0.2 c0.1,0.1,0.2,0.2,0.3,0.3c0,0,0.1,0.1,0.2,0.2c0.1,0.1,0.1,0.2,0.2,0.3c0,0.1,0,0.2,0,0.3c0,0.3-0.1,0.6-0.3,0.8s-0.5,0.3-0.8,0.3 c-0.1,0-0.2,0-0.3,0c-0.1,0-0.2-0.1-0.3-0.2c-0.1-0.1-0.2-0.1-0.2-0.2c0,0-0.1-0.1-0.3-0.3s-0.2-0.2-0.2-0.2 c-0.3,0.2-0.4,0.5-0.4,0.9c0,0.3,0.1,0.6,0.3,0.8l2.4,2.4c0.2,0.2,0.5,0.3,0.8,0.3c0.3,0,0.6-0.1,0.8-0.3l1.7-1.7 C35.5,33.4,35.7,33.2,35.7,32.8z M27.4,24.6c0-0.3-0.1-0.6-0.3-0.8l-2.4-2.4c-0.2-0.2-0.5-0.3-0.8-0.3c-0.3,0-0.6,0.1-0.8,0.3 l-1.7,1.7c-0.2,0.2-0.3,0.5-0.3,0.8c0,0.3,0.1,0.6,0.3,0.8l2.4,2.4c0.2,0.2,0.5,0.3,0.8,0.3c0.3,0,0.6-0.1,0.8-0.4 c0,0-0.1-0.1-0.2-0.2c-0.1-0.1-0.2-0.2-0.3-0.3c0,0-0.1-0.1-0.2-0.2c-0.1-0.1-0.1-0.2-0.2-0.3c0-0.1,0-0.2,0-0.3 c0-0.3,0.1-0.6,0.3-0.8s0.5-0.3,0.8-0.3c0.1,0,0.2,0,0.3,0c0.1,0,0.2,0.1,0.3,0.2c0.1,0.1,0.2,0.1,0.2,0.2c0,0,0.1,0.1,0.3,0.3 c0.1,0.1,0.2,0.2,0.2,0.2C27.3,25.2,27.4,24.9,27.4,24.6z M37.9,32.8c0,0.9-0.3,1.7-1,2.4l-1.7,1.7c-0.6,0.6-1.4,1-2.4,1 c-0.9,0-1.7-0.3-2.4-1L28,34.5c-0.6-0.6-1-1.4-1-2.4c0-1,0.3-1.8,1-2.4l-1-1c-0.7,0.7-1.5,1-2.4,1c-0.9,0-1.7-0.3-2.4-1l-2.4-2.4 c-0.7-0.7-1-1.4-1-2.4c0-0.9,0.3-1.7,1-2.4l1.7-1.7c0.6-0.6,1.4-1,2.4-1c0.9,0,1.7,0.3,2.4,1l2.4,2.4c0.6,0.6,1,1.4,1,2.4 c0,1-0.3,1.8-1,2.4l1,1c0.7-0.7,1.5-1,2.4-1c0.9,0,1.7,0.3,2.4,1l2.4,2.4C37.6,31.1,37.9,31.9,37.9,32.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 1446 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M20.8,29.1c0-0.6-0.2-1.1-0.5-1.6c0,0-0.1-0.2-0.4-0.5c-0.2-0.3-0.4-0.6-0.6-0.9c-0.2-0.3-0.4-0.6-0.6-1s-0.4-0.8-0.5-1.2 c-0.1-0.2-0.2-0.4-0.5-0.4s-0.4,0.1-0.5,0.4c-0.1,0.4-0.3,0.7-0.5,1.2s-0.4,0.8-0.6,1c-0.2,0.3-0.4,0.5-0.6,0.9 c-0.2,0.3-0.3,0.5-0.4,0.5c-0.3,0.5-0.5,1-0.5,1.6c0,0.8,0.3,1.5,0.9,2.1c0.6,0.6,1.3,0.9,2.1,0.9c0.8,0,1.5-0.3,2.1-0.9 S20.8,30,20.8,29.1z M32.7,26.2c0,3.3-1.2,6.1-3.5,8.4S24.1,38,20.8,38s-6.1-1.2-8.4-3.5S9,29.5,9,26.2c0-2.2,0.6-4.4,1.9-6.4 c0.1-0.1,0.6-0.8,1.4-2.1c0.9-1.3,1.6-2.4,2.3-3.5s1.5-2.4,2.3-4.1s1.5-3.2,1.9-4.7C19,5,19.3,4.7,19.7,4.4C20,4.1,20.4,4,20.8,4 s0.8,0.1,1.2,0.4c0.4,0.3,0.7,0.6,0.8,1.1c0.4,1.4,1.1,3,1.9,4.7s1.6,3,2.3,4.1c0.7,1.1,1.5,2.2,2.3,3.5c0.9,1.3,1.4,2,1.4,2.1 C32,21.8,32.7,23.9,32.7,26.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1447 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.5,17.1h-0.7v-3.3c0,0,0,0,0-0.1c0-0.1,0-0.3-0.1-0.4l-5.5-6.2c0,0,0,0,0,0c0,0-0.1-0.1-0.1-0.1c0,0,0,0,0,0 c0,0-0.1,0-0.1,0c0,0,0,0,0,0c0,0-0.1,0-0.1,0H12.4c-0.6,0-1.1,0.5-1.1,1.1v9h-0.7c-0.9,0-1.6,0.7-1.6,1.6V27c0,0.9,0.7,1.6,1.6,1.6 h0.7v5.7c0,0.6,0.5,1.1,1.1,1.1h18.3c0.6,0,1.1-0.5,1.1-1.1v-5.7h0.7c0.9,0,1.6-0.7,1.6-1.6v-8.3C34.1,17.8,33.4,17.1,32.5,17.1 L32.5,17.1z M12.4,8.1h12.9v5.7c0,0.3,0.2,0.6,0.6,0.6h4.9v2.8H12.4V8.1z M30.7,33.9H12.4v-5.4h18.3V33.9z M28.8,26.3 M15.4,18.7 c0.5,0,0.9,0.1,1.2,0.2c0.3,0.1,0.6,0.3,0.8,0.6s0.4,0.5,0.5,0.8c0.1,0.3,0.1,0.6,0.1,0.9c0,0.3,0,0.6-0.1,0.9 c-0.1,0.3-0.3,0.6-0.5,0.8s-0.5,0.4-0.8,0.6c-0.3,0.1-0.7,0.2-1.2,0.2h-1.8v2.7h-1.7v-7.7H15.4z M14.9,22.3c0.2,0,0.4,0,0.6,0 c0.2,0,0.3-0.1,0.5-0.2c0.1-0.1,0.2-0.2,0.3-0.3c0.1-0.2,0.1-0.3,0.1-0.6s0-0.4-0.1-0.6c-0.1-0.2-0.2-0.3-0.3-0.3 c-0.1-0.1-0.3-0.1-0.5-0.2s-0.4,0-0.6,0h-1.3v2.3H14.9z M22.4,18.7c0.5,0,1,0.1,1.4,0.2c0.4,0.2,0.8,0.4,1.1,0.7 c0.3,0.3,0.6,0.7,0.7,1.2s0.3,1,0.3,1.7c0,0.6-0.1,1.1-0.2,1.5s-0.4,0.9-0.6,1.2c-0.3,0.3-0.7,0.6-1.1,0.8c-0.4,0.2-0.9,0.3-1.5,0.3 h-3.3v-7.7H22.4z M22.3,24.9c0.2,0,0.5,0,0.7-0.1s0.4-0.2,0.6-0.4c0.2-0.2,0.3-0.4,0.4-0.7c0.1-0.3,0.2-0.7,0.2-1.1 c0-0.4,0-0.7-0.1-1c-0.1-0.3-0.2-0.6-0.4-0.8c-0.2-0.2-0.4-0.4-0.7-0.5c-0.3-0.1-0.6-0.2-1-0.2h-1.2v4.8H22.3z M32.4,18.7v1.4h-3.7 v1.8h3.2v1.3h-3.2v3.2H27v-7.7H32.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1448 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.8,10h3.3v4.6H7.4V10h3.3v0.4c0,0.5,0.5,1,1.1,1h3.9c0.6,0,1.1-0.4,1.1-1V10z M18.6,25.7h-1.8v0.4c0,0.5-0.5,1-1.1,1 h-3.9c-0.6,0-1.1-0.4-1.1-1v-0.4H7.4v4.6h12.7v-3.1C19.5,26.6,19,26.1,18.6,25.7z M20.1,18.1h-3.3v0.4c0,0.5-0.5,1-1.1,1h-3.9 c-0.6,0-1.1-0.4-1.1-1v-0.4H7.4v4.5H19c0.3-0.3,0.7-0.7,1.1-1.1V18.1z M24,33.2c0,0.7-0.6,1.3-1.3,1.3H4.8c-0.7,0-1.3-0.6-1.3-1.3 V6.7c0-0.7,0.6-1.3,1.3-1.3h17.9C23.4,5.4,24,6,24,6.7v12.2c0.8-0.4,1.7-0.8,2.5-1.1V4.2c0-0.7-0.6-1.2-1.2-1.2h-23 C1.6,3,1,3.6,1,4.2v31.6c0,0.7,0.6,1.2,1.2,1.2h23c0.7,0,1.2-0.6,1.2-1.2v-4.9c-0.9-0.3-1.7-0.6-2.5-1.1V33.2z M42.1,24.3l-0.4,0.5 c0,0.1-1.1,1.4-3,2.8c-2.5,1.8-5.2,2.8-7.8,2.8c-2.6,0-5.3-1-7.8-2.8c-1.9-1.4-2.9-2.7-3-2.8l-0.4-0.5l0.4-0.5c0-0.1,1.1-1.4,3-2.8 c2.5-1.8,5.2-2.8,7.8-2.8c2.6,0,5.3,1,7.8,2.8c1.9,1.4,2.9,2.7,3,2.8L42.1,24.3z M30.9,28.3c2.2,0,4-1.8,4-4s-1.8-4-4-4 c-1,0-2,0.4-2.7,1.1l-0.6-0.7c-1.2,0.5-2.3,1.1-3.1,1.7c-1,0.7-1.7,1.4-2.1,1.9c0.4,0.5,1.2,1.2,2.1,1.9c0.8,0.6,1.9,1.2,3.1,1.7 c-1-0.9-1.6-2.2-1.6-3.6c0-0.4,0-0.8,0.1-1.1l0.9,0.2c-0.1,0.3-0.1,0.7-0.1,1C26.9,26.5,28.7,28.3,30.9,28.3L30.9,28.3z M37.3,26.2 c1-0.7,1.7-1.4,2.1-1.9c-0.4-0.5-1.2-1.2-2.1-1.9c-0.8-0.6-1.9-1.2-3.1-1.7c1,0.9,1.6,2.2,1.6,3.6c0,1.4-0.6,2.7-1.6,3.6 C35.5,27.4,36.5,26.8,37.3,26.2L37.3,26.2z M37.3,26.2 M30.1,23.6l-1.6-1.8c0.6-0.6,1.4-0.9,2.2-0.9c1.8,0,3.2,1.4,3.2,3.2 c0,1.8-1.4,3.2-3.2,3.2c-1.8,0-3.2-1.4-3.2-3.2c0-0.3,0-0.6,0.1-0.9L30.1,23.6z M27.7,23.2'/%3E %3C/svg%3E\""

/***/ }),
/* 1449 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M 38 13.4 L 38 29 C 38 30.8 37.4 32.3 36.1 33.5 C 34.8 34.7 33.4 35.4 31.6 35.4 L 24.5 35.4 C 24.3 35.4 24.1 35.3 24 35.2 C 23.9 35.1 23.8 34.9 23.8 34.7 C 23.8 34.6 23.8 34.5 23.8 34.3 C 23.8 34.1 23.8 33.9 23.8 33.7 C 23.8 33.5 23.8 33.4 23.9 33.2 C 23.9 33 24 32.9 24.1 32.8 C 24.2 32.7 24.4 32.7 24.6 32.7 L 31.7 32.7 C 32.7 32.7 33.5 32.4 34.2 31.7 C 34.9 31 35.2 30.2 35.2 29.2 L 35.2 13.4 C 35.2 12.4 34.9 11.6 34.2 10.9 C 33.5 10.2 32.7 9.9 31.7 9.9 L 24.8 9.9 L 24.5 9.9 L 24.2 9.8 L 24 9.6 L 23.8 9.4 L 23.8 9.1 C 23.8 9 23.8 8.9 23.8 8.7 C 23.8 8.5 23.8 8.3 23.8 8.1 C 23.8 7.9 23.8 7.8 23.9 7.6 C 24 7.4 24 7.3 24.1 7.2 C 24.2 7 24.4 7 24.6 7 L 31.7 7 C 33.5 7 35 7.6 36.2 8.9 C 37.4 10.2 38 11.6 38 13.4 Z' transform='matrix(-1, 0, 0, -1, 42, 42.400002)'/%3E %3Cpath d='M 38.498 21.161 C 38.498 21.561 38.398 21.861 38.098 22.161 L 26.098 34.161 C 25.798 34.461 25.498 34.561 25.098 34.561 C 24.698 34.561 24.398 34.461 24.098 34.161 C 23.798 33.861 23.698 33.561 23.698 33.161 L 23.698 26.761 L 13.698 26.761 C 13.298 26.761 12.998 26.661 12.698 26.361 C 12.398 26.061 12.298 25.761 12.298 25.361 L 12.298 16.861 C 12.298 16.461 12.398 16.161 12.698 15.861 C 12.998 15.561 13.298 15.461 13.698 15.461 L 23.598 15.461 L 23.598 9.061 C 23.598 8.661 23.698 8.361 23.998 8.061 C 24.298 7.761 24.598 7.661 24.998 7.661 C 25.398 7.661 25.698 7.761 25.998 8.061 L 37.998 20.061 C 38.398 20.461 38.498 20.761 38.498 21.161 Z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1450 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28.7,31.9c0-0.3-0.1-0.6-0.3-0.8s-0.5-0.3-0.8-0.3c-0.3,0-0.6,0.1-0.8,0.3s-0.3,0.5-0.3,0.8s0.1,0.6,0.3,0.8 c0.2,0.2,0.5,0.3,0.8,0.3c0.3,0,0.6-0.1,0.8-0.3C28.6,32.5,28.7,32.3,28.7,31.9z M33.2,31.9c0-0.3-0.1-0.6-0.3-0.8s-0.5-0.3-0.8-0.3 s-0.6,0.1-0.8,0.3s-0.3,0.5-0.3,0.8s0.1,0.6,0.3,0.8c0.2,0.2,0.5,0.3,0.8,0.3s0.6-0.1,0.8-0.3C33.1,32.5,33.2,32.3,33.2,31.9z M35.5,28v5.7c0,0.5-0.2,0.9-0.5,1.2s-0.7,0.5-1.2,0.5H7.7c-0.5,0-0.9-0.2-1.2-0.5C6.2,34.5,6,34.1,6,33.6V28c0-0.5,0.2-0.9,0.5-1.2 c0.3-0.3,0.7-0.5,1.2-0.5h7.6c0.2,0.7,0.7,1.2,1.2,1.6c0.6,0.4,1.2,0.6,2,0.6H23c0.7,0,1.4-0.2,2-0.6s1-1,1.2-1.6h7.6 c0.5,0,0.9,0.2,1.2,0.5C35.3,27.1,35.5,27.5,35.5,28z M29.7,16.5c-0.2,0.5-0.5,0.7-1,0.7h-4.5v7.9c0,0.3-0.1,0.6-0.3,0.8 s-0.5,0.3-0.8,0.3h-4.5c-0.3,0-0.6-0.1-0.8-0.3c-0.2-0.2-0.3-0.5-0.3-0.8v-7.9h-4.5c-0.5,0-0.8-0.2-1-0.7c-0.2-0.5-0.1-0.9,0.2-1.2 l7.9-7.9C20.2,7.1,20.4,7,20.7,7c0.3,0,0.6,0.1,0.8,0.3l7.9,7.9C29.8,15.6,29.9,16,29.7,16.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1451 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:none;%7D %3C/style%3E %3Cg%3E %3Cpolygon class='st0' points='15.4,28.5 28.5,28.5 28.5,15.5 '/%3E %3Cpolygon class='st0' points='26.9,13.9 13.8,13.9 13.8,26.9 '/%3E %3Cpath d='M34.2,28.5h-3.5V13.2l4.1-4.1c0.4-0.4,0.4-1.2,0-1.6c-0.4-0.4-1.2-0.4-1.6,0l-4.1,4.1H13.8V8.1c0-0.6-0.5-1.1-1.1-1.1 c-0.6,0-1.1,0.5-1.1,1.1v3.5H8.1c-0.6,0-1.1,0.5-1.1,1.1c0,0.6,0.5,1.1,1.1,1.1h3.4v15.8c0,0.1,0,0.3,0.1,0.4 c0.1,0.3,0.3,0.5,0.6,0.6c0.1,0.1,0.3,0.1,0.4,0.1h15.8v3.4c0,0.6,0.5,1.1,1.1,1.1c0.6,0,1.1-0.5,1.1-1.1v-3.4h3.5 c0.6,0,1.1-0.5,1.1-1.1C35.3,29,34.8,28.5,34.2,28.5z M26.9,13.9L13.8,26.9V13.9H26.9z M15.4,28.5l13.1-13.1v13.1H15.4z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1452 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.7,24.5c0.8-0.3,1.6-0.6,2.4-1V34c0,0.7-0.5,1.2-1.2,1.2H1.2C0.5,35.3,0,34.7,0,34V8.2C0,7.5,0.5,7,1.2,7h34.7 c0.7,0,1.2,0.5,1.2,1.2v3.6c-0.8-0.4-1.6-0.8-2.4-1V9.4H2.4v18.2l10.9-8.7l5.6,10.9l7.8-4.9l8.1,5.8V24.5z M40.7,17.3 c0-0.1-1.1-1.4-3-2.8c-2.5-1.8-5.2-2.8-7.8-2.8c-2.6,0-5.3,1-7.8,2.8c-1.9,1.4-2.9,2.7-3,2.8l-0.4,0.5l0.4,0.5c0,0.1,1.1,1.4,3,2.8 c2.5,1.8,5.2,2.8,7.8,2.8c2.6,0,5.3-1,7.8-2.8c1.9-1.4,2.9-2.7,3-2.8l0.4-0.5L40.7,17.3z M29.9,21.8c-2.2,0-4-1.8-4-4 c0-0.3,0-0.7,0.1-1l-0.9-0.2C25.1,17,25,17.4,25,17.8c0,1.4,0.6,2.7,1.6,3.6c-1.2-0.5-2.3-1.1-3.1-1.7c-1-0.7-1.7-1.4-2.1-1.9 c0.4-0.5,1.2-1.2,2.1-1.9c0.8-0.6,1.9-1.2,3.1-1.7l0.6,0.7c0.7-0.7,1.7-1.1,2.7-1.1c2.2,0,4,1.8,4,4S32.1,21.8,29.9,21.8L29.9,21.8z M36.3,19.7c-0.8,0.6-1.9,1.2-3.1,1.7c1-0.9,1.6-2.2,1.6-3.6c0-1.4-0.6-2.7-1.6-3.6c1.2,0.5,2.3,1.1,3.1,1.7c1,0.7,1.7,1.4,2.1,1.9 C38,18.3,37.3,19,36.3,19.7L36.3,19.7z M36.3,19.7 M26.7,16.7c-0.1,0.3-0.1,0.6-0.1,0.9c0,1.8,1.4,3.2,3.2,3.2 c1.8,0,3.2-1.4,3.2-3.2c0-1.8-1.4-3.2-3.2-3.2c-0.9,0-1.6,0.3-2.2,0.9l1.6,1.8L26.7,16.7z M26.7,16.7'/%3E %3C/svg%3E\""

/***/ }),
/* 1453 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28.8,35.6H4.5V6.4h14.6v7.9c0,0.5,0.2,0.9,0.5,1.3c0.4,0.4,0.8,0.5,1.3,0.5h7.9v2h2.4v-3.8c0-0.5-0.1-1.1-0.4-1.7 c-0.3-0.6-0.6-1.1-0.9-1.4L24,5.3c-0.4-0.4-0.8-0.7-1.4-0.9C22,4.1,21.4,4,20.9,4h-17C3.4,4,2.9,4.2,2.6,4.5 C2.2,4.9,2.1,5.3,2.1,5.8v30.4c0,0.5,0.2,0.9,0.5,1.3S3.4,38,3.9,38h25.5c0.5,0,0.9-0.2,1.3-0.5s0.5-0.8,0.5-1.3v-3.1h-2.4V35.6z M21.5,6.6c0.4,0.1,0.6,0.3,0.8,0.4l5.9,5.9c0.2,0.2,0.3,0.4,0.4,0.8h-7.1V6.6z M40.9,25.3c0,0.3-0.1,0.5-0.3,0.7l-5.2,5.2 c-0.2,0.2-0.4,0.3-0.7,0.3c-0.3,0-0.5-0.1-0.7-0.3l-0.6-0.6c-0.2-0.2-0.3-0.4-0.3-0.7s0.1-0.5,0.3-0.7l2.3-2.3H20.6 c-0.3,0-0.5-0.1-0.7-0.3s-0.3-0.4-0.3-0.7v-1c0-0.3,0.1-0.5,0.3-0.7s0.4-0.3,0.7-0.3h15.2l-2.3-2.3c-0.2-0.2-0.3-0.4-0.3-0.7 s0.1-0.5,0.3-0.7l0.6-0.6c0.2-0.2,0.4-0.3,0.7-0.3c0.3,0,0.5,0.1,0.7,0.3l5.2,5.2C40.8,24.7,40.9,25,40.9,25.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1454 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M13.1,33h16.5v-4.7H13.1V33z M13.1,21.2h16.5v-7.1h-3c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3v-3H13.1V21.2z M34.3,22.3 c0-0.3-0.1-0.6-0.4-0.8c-0.2-0.2-0.5-0.4-0.8-0.4c-0.3,0-0.6,0.1-0.8,0.4C32.1,21.7,32,22,32,22.3s0.1,0.6,0.4,0.8 c0.2,0.2,0.5,0.4,0.8,0.4c0.3,0,0.6-0.1,0.8-0.4C34.2,22.9,34.3,22.7,34.3,22.3z M36.7,22.3V30c0,0.2-0.1,0.3-0.2,0.4 c-0.1,0.1-0.3,0.2-0.4,0.2H32v3c0,0.5-0.2,0.9-0.5,1.3s-0.8,0.5-1.3,0.5H12.5c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3v-3H6.6 c-0.2,0-0.3-0.1-0.4-0.2S6,30.2,6,30v-7.7c0-1,0.3-1.8,1-2.5s1.5-1,2.5-1h1.2v-10c0-0.5,0.2-0.9,0.5-1.3C11.6,7.2,12,7,12.5,7h12.4 c0.5,0,1,0.1,1.6,0.4c0.6,0.2,1.1,0.5,1.4,0.9l2.8,2.8c0.3,0.3,0.6,0.8,0.9,1.4c0.2,0.6,0.4,1.1,0.4,1.6v4.7h1.2c1,0,1.8,0.3,2.5,1 S36.7,21.4,36.7,22.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1455 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M24.4,31.1c0.8,0.4,1.6,0.7,2.4,0.9v1.6c0,0.5-0.2,0.9-0.5,1.3c-0.3,0.3-0.8,0.5-1.3,0.5H7.3c-0.5,0-0.9-0.2-1.3-0.5 c-0.3-0.3-0.5-0.8-0.5-1.3v-3H1.4c-0.2,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.2-0.3-0.2-0.4v-7.7c0-1,0.3-1.8,1-2.5s1.5-1,2.5-1h1.2v-10 c0-0.5,0.2-0.9,0.5-1.3C6.4,7.2,6.8,7,7.3,7h12.4c0.5,0,1,0.1,1.6,0.4s1.1,0.5,1.4,0.9l2.8,2.8c0.3,0.3,0.6,0.8,0.9,1.4 c0.2,0.6,0.4,1.1,0.4,1.6v3.5c-0.8,0.2-1.6,0.5-2.4,0.9v-4.4h-3c-0.5,0-0.9-0.2-1.3-0.5c-0.3-0.3-0.5-0.8-0.5-1.3v-3H7.9v11.8h12.2 c-1.9,1.5-3,2.9-3.1,3l-0.5,0.6l0.5,0.6c0.1,0.1,1.1,1.4,2.9,2.8H7.9V33h16.5V31.1z M41.9,24.8l-0.4,0.5c0,0.1-1.1,1.4-3,2.8 c-2.5,1.8-5.2,2.8-7.8,2.8c-2.6,0-5.3-1-7.8-2.8c-1.9-1.4-2.9-2.7-3-2.8l-0.4-0.5l0.4-0.5c0-0.1,1.1-1.4,3-2.8 c2.5-1.8,5.2-2.8,7.8-2.8c2.6,0,5.3,1,7.8,2.8c1.9,1.4,2.9,2.7,3,2.8L41.9,24.8z M30.7,28.7c2.2,0,4-1.8,4-4s-1.8-4-4-4 c-1,0-2,0.4-2.7,1.1l-0.6-0.7c-1.2,0.5-2.3,1.1-3.1,1.7c-1,0.7-1.7,1.4-2.1,1.9c0.4,0.5,1.2,1.2,2.1,1.9c0.8,0.6,1.9,1.2,3.1,1.7 c-1-0.9-1.6-2.2-1.6-3.6c0-0.4,0-0.8,0.1-1.1l0.9,0.2c-0.1,0.3-0.1,0.7-0.1,1C26.7,27,28.5,28.7,30.7,28.7L30.7,28.7z M37.1,26.7 c1-0.7,1.7-1.4,2.1-1.9c-0.4-0.5-1.2-1.2-2.1-1.9c-0.8-0.6-1.9-1.2-3.1-1.7c1,0.9,1.6,2.2,1.6,3.6c0,1.4-0.6,2.7-1.6,3.6 C35.2,27.9,36.3,27.2,37.1,26.7L37.1,26.7z M37.1,26.7 M29.9,24l-1.6-1.8c0.6-0.6,1.4-0.9,2.2-0.9c1.8,0,3.2,1.4,3.2,3.2 c0,1.8-1.4,3.2-3.2,3.2c-1.8,0-3.2-1.4-3.2-3.2c0-0.3,0-0.6,0.1-0.9L29.9,24z M27.5,23.6'/%3E %3C/svg%3E\""

/***/ }),
/* 1456 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M1,33.3v-5.1c5.3,0,8-2.6,10.6-5.2c0.6-0.6,1.3-1.3,1.9-1.8c-0.7-0.6-1.3-1.2-1.9-1.8C9,16.7,6.3,14.1,1,14.1V9 c7.4,0,11.3,3.9,14.2,6.7c1.7,1.7,2.8,2.7,3.9,2.9c0.1,0,0.3,0,0.4,0v0.1h12.2l-2.1-5.3c-0.1-0.2,0-0.4,0.1-0.5 c0.2-0.1,0.4-0.1,0.5,0l10.4,8c0.1,0.1,0.2,0.2,0.2,0.3c0,0.1-0.1,0.3-0.2,0.3l-10.4,8c-0.1,0.1-0.2,0.1-0.3,0.1 c-0.1,0-0.2,0-0.3-0.1c-0.2-0.1-0.2-0.3-0.1-0.5l2.1-5.3H19.5c0,0,0,0,0,0c-0.1,0-0.3,0-0.4,0c-1.2,0.2-2.2,1.2-3.9,2.9 C12.3,29.4,8.4,33.3,1,33.3L1,33.3z M1,33.3'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1457 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.5,17.2h-0.7v-3.3c0,0,0,0,0-0.1c0-0.1,0-0.3-0.1-0.4l-5.5-6.2c0,0,0,0,0,0c0,0-0.1-0.1-0.1-0.1c0,0,0,0,0,0 c0,0-0.1,0-0.1,0c0,0,0,0,0,0c0,0-0.1,0-0.1,0H12.4c-0.6,0-1.1,0.5-1.1,1.1v9h-0.7c-0.9,0-1.6,0.7-1.6,1.6v8.3 c0,0.9,0.7,1.6,1.6,1.6h0.7v5.7c0,0.6,0.5,1.1,1.1,1.1h18.3c0.6,0,1.1-0.5,1.1-1.1v-5.7h0.7c0.9,0,1.6-0.7,1.6-1.6v-8.3 C34.1,17.9,33.4,17.2,32.5,17.2L32.5,17.2z M12.4,8.2h12.9v5.7c0,0.3,0.2,0.6,0.6,0.6h4.9v2.8H12.4V8.2z M30.7,34H12.4v-5.4h18.3V34 z M28.8,26.4 M13.7,23h-2v2h2.4v1.3h-3.7v-7.6H14V20h-2.4v1.8h2V23z M16.8,21.4l0.9-2.6h1.5l-1.5,3.8l1.5,3.8h-1.5l-0.9-2.6 l-0.9,2.6h-1.5l1.5-3.8l-1.5-3.8h1.5L16.8,21.4z M24.1,23.8c0,0.9-0.2,1.5-0.6,2s-0.9,0.7-1.6,0.7c-0.7,0-1.3-0.3-1.7-0.8 c-0.4-0.6-0.6-1.4-0.6-2.4v-1.3c0-1,0.2-1.8,0.6-2.4s1-0.8,1.7-0.8c0.7,0,1.2,0.2,1.6,0.7c0.4,0.5,0.6,1.1,0.6,2h-1.3 c0-0.5-0.1-0.9-0.2-1.1c-0.1-0.2-0.4-0.3-0.7-0.3c-0.3,0-0.6,0.1-0.7,0.4s-0.2,0.8-0.2,1.4v1.4c0,0.8,0.1,1.3,0.2,1.5 c0.1,0.3,0.4,0.4,0.7,0.4c0.3,0,0.6-0.1,0.7-0.3c0.1-0.2,0.2-0.5,0.2-1.1H24.1z M28.2,23h-2v2h2.4v1.3h-3.7v-7.6h3.7V20h-2.4v1.8h2 V23z M30.6,25h2.3v1.3h-3.6v-7.6h1.3V25z'/%3E %3C/svg%3E\""

/***/ }),
/* 1458 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.5,17.1h-0.7v-3.3c0,0,0,0,0-0.1c0-0.1,0-0.3-0.1-0.4l-5.5-6.2c0,0,0,0,0,0c0,0-0.1-0.1-0.1-0.1c0,0,0,0,0,0 c0,0-0.1,0-0.1,0c0,0,0,0,0,0c0,0-0.1,0-0.1,0H12.4c-0.6,0-1.1,0.5-1.1,1.1v9h-0.7c-0.9,0-1.6,0.7-1.6,1.6V27c0,0.9,0.7,1.6,1.6,1.6 h0.7v5.7c0,0.6,0.5,1.1,1.1,1.1h18.3c0.6,0,1.1-0.5,1.1-1.1v-5.7h0.7c0.9,0,1.6-0.7,1.6-1.6v-8.3C34.1,17.8,33.4,17.1,32.5,17.1 L32.5,17.1z M12.4,8.1h12.9v5.7c0,0.3,0.2,0.6,0.6,0.6h4.9v2.8H12.4V8.1z M25.7,22.4c0,2.5-1.5,4.1-3.8,4.1c-2.3,0-3.6-1.7-3.6-3.9 c0-2.3,1.5-4,3.8-4C24.4,18.5,25.7,20.3,25.7,22.4L25.7,22.4z M10.7,26.3v-7.6c0.6-0.1,1.5-0.2,2.4-0.2c1.5,0,2.4,0.3,3.2,0.8 c0.8,0.6,1.3,1.5,1.3,2.9c0,1.5-0.5,2.5-1.3,3.1c-0.8,0.7-2,1-3.6,1C11.8,26.4,11.1,26.4,10.7,26.3L10.7,26.3z M30.7,33.9H12.4v-5.4 h18.3V33.9z M30.8,25c0.5,0,1.1-0.1,1.5-0.3l0.3,1.4c-0.3,0.2-1,0.3-2,0.3c-2.7,0-4-1.7-4-3.9c0-2.6,1.9-4.1,4.2-4.1 c0.9,0,1.6,0.2,1.9,0.3l-0.4,1.4c-0.4-0.1-0.8-0.3-1.5-0.3c-1.4,0-2.5,0.8-2.5,2.5C28.3,24,29.3,25,30.8,25L30.8,25z M30.8,25 M15.7,22.4c0-1.6-0.9-2.4-2.4-2.4c-0.4,0-0.6,0-0.8,0.1v5c0.1,0,0.4,0,0.6,0C14.6,25.1,15.7,24.2,15.7,22.4L15.7,22.4z M15.7,22.4 M20.2,22.5c0,1.5,0.7,2.6,1.9,2.6c1.2,0,1.9-1.1,1.9-2.6c0-1.4-0.7-2.6-1.9-2.6C20.8,19.9,20.2,21,20.2,22.5L20.2,22.5z M20.2,22.5 '/%3E %3C/svg%3E\""

/***/ }),
/* 1459 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.5,17.1h-0.7v-3.3c0,0,0,0,0-0.1c0-0.1,0-0.3-0.1-0.4l-5.5-6.2c0,0,0,0,0,0c0,0-0.1-0.1-0.1-0.1c0,0,0,0,0,0 c0,0-0.1,0-0.1,0c0,0,0,0,0,0c0,0-0.1,0-0.1,0H12.4c-0.6,0-1.1,0.5-1.1,1.1v9h-0.7c-0.9,0-1.6,0.7-1.6,1.6V27c0,0.9,0.7,1.6,1.6,1.6 h0.7v5.7c0,0.6,0.5,1.1,1.1,1.1h18.3c0.6,0,1.1-0.5,1.1-1.1v-5.7h0.7c0.9,0,1.6-0.7,1.6-1.6v-8.3C34.1,17.8,33.4,17.1,32.5,17.1 L32.5,17.1z M12.4,8.1h12.9v5.7c0,0.3,0.2,0.6,0.6,0.6h4.9v2.8H12.4V8.1z M25.8,22.3c0,1.4-0.5,2.4-1.2,3c-0.8,0.7-2,1-3.4,1 c-0.9,0-1.5-0.1-1.9-0.1v-7.3c0.6-0.1,1.4-0.2,2.3-0.2c1.4,0,2.3,0.3,3.1,0.8C25.4,20.1,25.8,21,25.8,22.3L25.8,22.3z M10.9,22.5 c0-2.2,1.4-3.9,3.6-3.9c2.3,0,3.5,1.7,3.5,3.8c0,2.5-1.5,3.9-3.7,3.9C12.2,26.3,10.9,24.7,10.9,22.5L10.9,22.5z M30.7,33.9H12.4 v-5.4h18.3V33.9z M28.8,26.3c-0.9,0-1.7-0.2-2.1-0.5l0.3-1.4c0.5,0.2,1.2,0.5,1.9,0.5c0.8,0,1.2-0.3,1.2-0.8c0-0.5-0.4-0.7-1.3-1.1 c-1.2-0.4-2.1-1.1-2.1-2.2c0-1.3,1.1-2.3,2.8-2.3c0.8,0,1.5,0.2,1.9,0.4l-0.4,1.4c-0.3-0.1-0.8-0.4-1.6-0.4c-0.7,0-1.1,0.3-1.1,0.7 c0,0.5,0.4,0.7,1.4,1.1c1.3,0.5,1.9,1.2,1.9,2.2C31.8,25.3,30.8,26.3,28.8,26.3L28.8,26.3z M28.8,26.3 M21.7,20 c-0.4,0-0.6,0-0.8,0.1v4.9c0.1,0,0.4,0,0.6,0c1.5,0,2.5-0.8,2.5-2.6C24.1,20.8,23.1,20,21.7,20L21.7,20z M21.7,20 M16.3,22.5 c0-1.3-0.6-2.5-1.8-2.5c-1.1,0-1.8,1.1-1.8,2.5c0,1.5,0.7,2.5,1.8,2.5C15.7,25,16.3,23.9,16.3,22.5L16.3,22.5z M16.3,22.5'/%3E %3C/svg%3E\""

/***/ }),
/* 1460 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M32.2,17.1h-0.7v-3.3c0,0,0,0,0-0.1c0-0.1,0-0.3-0.1-0.4l-5.5-6.2c0,0,0,0,0,0c0,0-0.1-0.1-0.1-0.1c0,0,0,0,0,0 c0,0-0.1,0-0.1,0c0,0,0,0,0,0c0,0-0.1,0-0.1,0H12.1C11.5,7,11,7.5,11,8.1v9h-0.7c-0.9,0-1.6,0.7-1.6,1.6V27c0,0.9,0.7,1.6,1.6,1.6 H11v5.7c0,0.6,0.5,1.1,1.1,1.1h18.3c0.6,0,1.1-0.5,1.1-1.1v-5.7h0.7c0.9,0,1.6-0.7,1.6-1.6v-8.3C33.8,17.8,33.1,17.1,32.2,17.1 L32.2,17.1z M12.1,8.1H25v5.7c0,0.3,0.2,0.6,0.6,0.6h4.9v2.8H12.1V8.1z M30.4,33.9H12.1v-5.4h18.3V33.9z M28.5,26.3 M18.5,24.2 c0,0.9-0.2,1.5-0.6,2s-0.9,0.7-1.6,0.7c-0.7,0-1.3-0.3-1.7-0.8c-0.4-0.6-0.6-1.4-0.6-2.4v-1.3c0-1,0.2-1.8,0.6-2.4s1-0.8,1.7-0.8 c0.7,0,1.2,0.2,1.6,0.7c0.4,0.5,0.6,1.1,0.6,2h-1.3c0-0.5-0.1-0.9-0.2-1.1s-0.4-0.3-0.7-0.3c-0.3,0-0.6,0.1-0.7,0.4 s-0.2,0.8-0.2,1.4v1.4c0,0.8,0.1,1.3,0.2,1.5c0.1,0.3,0.4,0.4,0.7,0.4c0.3,0,0.6-0.1,0.7-0.3c0.1-0.2,0.2-0.5,0.2-1.1H18.5z M22,24.7c0-0.3-0.1-0.5-0.2-0.7c-0.1-0.2-0.4-0.3-0.7-0.5c-0.6-0.3-1.1-0.6-1.4-1c-0.3-0.4-0.4-0.8-0.4-1.4c0-0.6,0.2-1.1,0.6-1.5 s0.9-0.6,1.5-0.6c0.4,0,0.7,0.1,1.1,0.3s0.5,0.5,0.7,0.8c0.2,0.4,0.2,0.8,0.2,1.2H22c0-0.4-0.1-0.6-0.2-0.8 c-0.1-0.2-0.3-0.3-0.6-0.3c-0.2,0-0.4,0.1-0.5,0.2c-0.1,0.2-0.2,0.4-0.2,0.6c0,0.2,0.1,0.4,0.2,0.6s0.4,0.3,0.7,0.5 c0.6,0.3,1.1,0.6,1.4,1c0.3,0.4,0.4,0.9,0.4,1.5c0,0.7-0.2,1.2-0.5,1.5c-0.4,0.4-0.8,0.6-1.4,0.6c-0.4,0-0.8-0.1-1.1-0.3 c-0.3-0.2-0.6-0.5-0.8-0.9c-0.2-0.4-0.3-0.8-0.3-1.3h1.3c0,0.4,0.1,0.8,0.2,1c0.1,0.2,0.4,0.3,0.7,0.3C21.8,25.6,22,25.3,22,24.7z M26.3,24.6l1.1-5.5h1.4l-1.8,7.6h-1.3l-1.8-7.6h1.4L26.3,24.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1461 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M33.3,15.8L20.6,28.5c-0.2,0.2-0.5,0.3-0.8,0.3c-0.3,0-0.6-0.1-0.8-0.3l-5.4-5.4c-0.2-0.2-0.3-0.5-0.3-0.8 c0-0.3,0.1-0.6,0.3-0.8l0.8-0.8c0.2-0.2,0.5-0.3,0.8-0.3s0.6,0.1,0.8,0.3l3.8,3.8l11-11c0.2-0.2,0.5-0.3,0.8-0.3 c0.3,0,0.6,0.1,0.8,0.3l0.8,0.8c0.2,0.2,0.3,0.5,0.3,0.8S33.5,15.6,33.3,15.8z'/%3E %3Cpath d='M8.3,18.3c-0.3,0-0.6,0.1-0.8,0.2c0.3-1.2,0.8-2.3,1.4-3.4c1.3-2.2,3-3.9,5.2-5.2S18.6,8,21.2,8c2.6,0,4.9,0.6,7.1,1.9 c0.8,0.5,1.6,1.1,2.3,1.7l-1.8,1.8c-0.5-0.5-1.1-0.9-1.8-1.3c-1.8-1-3.7-1.6-5.8-1.6c-2.1,0-4,0.5-5.8,1.6c-1.8,1-3.2,2.4-4.2,4.2 c-0.5,0.9-0.9,1.8-1.2,2.8l-0.2-0.2C9.3,18.5,8.9,18.3,8.3,18.3z M32.7,22.2c0,2.1-0.5,4-1.6,5.8c-1,1.8-2.4,3.2-4.2,4.2 c-1.8,1-3.7,1.6-5.8,1.6c-1.2,0-2.4-0.2-3.5-0.6c-0.4,0.3-0.8,0.4-1.2,0.4c-0.6,0-1.1-0.2-1.5-0.6l-7.6-7.6c0.3,1.4,0.8,2.7,1.5,3.9 c1.3,2.2,3,3.9,5.2,5.2s4.5,1.9,7.1,1.9c2.6,0,4.9-0.6,7.1-1.9c2.2-1.3,3.9-3,5.2-5.2c1.3-2.2,1.9-4.5,1.9-7.1c0-2-0.4-3.8-1.1-5.5 l-2,2C32.5,19.8,32.7,20.9,32.7,22.2z M16.4,33.6c0.5,0,0.9-0.1,1.2-0.4c-0.8-0.3-1.6-0.6-2.3-1c-1.8-1-3.2-2.4-4.2-4.2 c-1-1.8-1.6-3.7-1.6-5.8c0-1.1,0.1-2.1,0.4-3l-0.2-0.2c-0.4-0.4-0.9-0.6-1.5-0.6c-0.3,0-0.6,0.1-0.8,0.2C7.2,19.6,7,20.9,7,22.2 c0,1.1,0.1,2.2,0.4,3.2L15,33C15.4,33.4,15.9,33.6,16.4,33.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1462 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M25,23.7l4.1-4l-5.7-0.8l-2.6-5.2l-2.6,5.2l-5.7,0.8l4.1,4l-1,5.7l5.1-2.7l5.1,2.7L25,23.7z M35.7,18c0,0.3-0.2,0.5-0.5,0.9 l-6.5,6.3l1.5,8.9c0,0.1,0,0.2,0,0.4c0,0.6-0.2,0.9-0.7,0.9c-0.2,0-0.5-0.1-0.7-0.2l-8-4.2l-8,4.2c-0.3,0.1-0.5,0.2-0.7,0.2 c-0.3,0-0.4-0.1-0.6-0.3c-0.1-0.2-0.2-0.4-0.2-0.6c0-0.1,0-0.2,0-0.4l1.5-8.9l-6.5-6.3C6.1,18.5,6,18.2,6,18c0-0.4,0.3-0.7,1-0.8 l9-1.3l4-8.1C20.2,7.2,20.5,7,20.9,7s0.6,0.2,0.9,0.7l4,8.1l9,1.3C35.4,17.3,35.7,17.5,35.7,18z'/%3E %3C/svg%3E\""

/***/ }),
/* 1463 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M30.4,16.4H12.3c-0.9,0-1.5-0.6-1.5-1.3s0.7-1.3,1.5-1.3h18.1c0.9,0,1.5,0.6,1.5,1.3S31.3,16.4,30.4,16.4z M31.9,21.6 c0-0.7-0.7-1.3-1.5-1.3H12.3c-0.9,0-1.5,0.6-1.5,1.3s0.7,1.3,1.5,1.3h18.1C31.3,22.9,31.9,22.3,31.9,21.6z M35.1,31.7l-6.5-4 c-0.2-0.1-0.4-0.2-0.7-0.2H12.4l-3.8,2.6h19l8.2,5.1c0.2,0.1,0.5,0.2,0.7,0.2c0.2,0,0.4,0,0.6-0.2c0.4-0.2,0.6-0.6,0.6-1.1V10.4 l-2.6,1.7V31.7z M7.4,9.6h23.1L34.3,7H6.1C5.4,7,4.9,7.6,4.9,8.3v18.6l2.6-1.7V9.6z'/%3E %3Cpath d='M37.3,9.3L6.7,30c-0.6,0.4-1.3,0.2-1.7-0.4s-0.3-1.4,0.3-1.8L35.9,7.2c0.6-0.4,1.3-0.2,1.7,0.4C38,8.1,37.9,8.9,37.3,9.3z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1464 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28.7,16.4h-15c-0.7,0-1.3-0.6-1.3-1.3s0.6-1.3,1.3-1.3h15c0.7,0,1.3,0.6,1.3,1.3S29.5,16.4,28.7,16.4z M30,21.6 c0-0.7-0.6-1.3-1.3-1.3h-15c-0.7,0-1.3,0.6-1.3,1.3s0.6,1.3,1.3,1.3h15C29.5,22.9,30,22.3,30,21.6z M37.2,35.1 c0.4-0.2,0.6-0.6,0.6-1.1V8.3c0-0.7-0.6-1.3-1.3-1.3H6.3C5.6,7,5,7.6,5,8.3v20.5c0,0.7,0.6,1.3,1.3,1.3h21.5l8.2,5.1 c0.2,0.1,0.5,0.2,0.7,0.2C36.8,35.3,37,35.3,37.2,35.1z M7.6,9.6h27.7v22.1l-6.5-4c-0.2-0.1-0.4-0.2-0.7-0.2H7.6V9.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1465 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M20.8,6.5c-3.1,0-6,0.5-8.7,1.6s-4.8,2.5-6.4,4.3S3.4,16,3.4,18.1c0,1.7,0.5,3.3,1.6,4.9s2.6,2.9,4.6,4l2,1.1l-0.6,2.2 c-0.4,1.4-0.9,2.7-1.6,3.9c2.3-1,4.4-2.3,6.3-3.9l1-0.9l1.3,0.1c1,0.1,2,0.2,3,0.2c3.1,0,6-0.5,8.7-1.6s4.8-2.5,6.4-4.3 s2.4-3.7,2.4-5.8s-0.8-4-2.4-5.8S32.2,9.1,29.5,8S23.9,6.5,20.8,6.5z M40.6,18.2c0,2.6-0.9,4.9-2.7,7.1s-4.2,3.9-7.2,5.2 c-3,1.3-6.4,1.9-10,1.9c-1,0-2.1-0.1-3.2-0.2c-2.9,2.6-6.3,4.4-10.2,5.4c-0.7,0.2-1.6,0.4-2.5,0.5H4.8c-0.2,0-0.4-0.1-0.6-0.2 c-0.2-0.2-0.3-0.4-0.4-0.6v0c0-0.1,0-0.1,0-0.3c0-0.1,0.1-0.2,0-0.2s0-0.1,0.1-0.2l0.1-0.2L4.3,36l0.2-0.2c0.1-0.1,0.3-0.4,0.7-0.8 c0.4-0.4,0.6-0.7,0.8-0.8c0.2-0.2,0.4-0.5,0.7-0.9c0.3-0.4,0.5-0.8,0.7-1.1c0.2-0.3,0.4-0.8,0.6-1.3c0.2-0.5,0.4-1.1,0.6-1.7 c-2.3-1.3-4.1-2.9-5.5-4.9s-2-4-2-6.2c0-2.6,0.9-4.9,2.7-7.1s4.2-3.9,7.2-5.2S17.2,4,20.8,4s6.9,0.6,10,1.9s5.4,3,7.2,5.2 S40.6,15.6,40.6,18.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1466 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23050505;%7D %3C/style%3E %3Cg%3E %3Cg%3E %3Cpath class='st0' d='M40.6,23.4V23c0-6.6-5.3-11.9-11.9-11.9H11.7v-3c0-0.9-1-1.4-1.7-0.9l-8.5,5.9c-0.6,0.4-0.6,1.4,0,1.8 l8.5,5.9c0.7,0.5,1.7,0,1.7-0.9V17h16.9c3.3,0,6,2.7,6,6v0.4c0,3.3-2.7,6-6,6l-26.3,0c-0.7,0-1.2,0.6-1.2,1.3c0,1.1,0,2.6,0,3.6 c0,0.6,0.5,1.1,1.1,1.1h26.4C35.2,35.3,40.6,30,40.6,23.4L40.6,23.4z M40.6,23.4'/%3E %3C/g%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1467 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Icon_FileManager' d='M37.9,23.2c0-0.5-0.4-0.7-1.1-0.7H14.9c-0.5,0-1.1,0.1-1.7,0.4c-0.6,0.3-1.1,0.6-1.4,1.1l-5.9,7.3 c-0.2,0.3-0.4,0.6-0.4,0.8c0,0.5,0.4,0.7,1.1,0.7h21.9c0.5,0,1.1-0.1,1.7-0.4c0.6-0.3,1.1-0.7,1.4-1.1l5.9-7.3 C37.7,23.7,37.9,23.4,37.9,23.2z M14.9,19.9h15.5v-3.2c0-0.5-0.2-1-0.6-1.4s-0.8-0.6-1.4-0.6H16.8c-0.5,0-1-0.2-1.4-0.6 c-0.4-0.4-0.6-0.8-0.6-1.4v-1.3c0-0.5-0.2-1-0.6-1.4S13.5,9.6,13,9.6H6.5c-0.5,0-1,0.2-1.4,0.6S4.6,11,4.6,11.5v17.2l5.2-6.3 c0.6-0.7,1.4-1.3,2.3-1.8C13,20.1,14,19.9,14.9,19.9z M40.4,23.2c0,0.8-0.3,1.6-0.9,2.4l-5.9,7.3c-0.6,0.7-1.4,1.3-2.3,1.8 c-1,0.5-1.9,0.7-2.8,0.7H6.5c-1.2,0-2.3-0.4-3.2-1.3S2,32.1,2,30.8V11.5c0-1.2,0.4-2.3,1.3-3.2S5.3,7,6.5,7H13 c1.2,0,2.3,0.4,3.2,1.3c0.9,0.9,1.3,1.9,1.3,3.2v0.6h11c1.2,0,2.3,0.4,3.2,1.3c0.9,0.9,1.3,1.9,1.3,3.2v3.2h3.9c0.7,0,1.4,0.2,2,0.5 c0.6,0.3,1.1,0.8,1.3,1.4C40.3,22.2,40.4,22.7,40.4,23.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1468 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M19.5,20.5L32.7,7.3C32.9,7.1,33.1,7,33.4,7s0.5,0.1,0.7,0.3l1.4,1.4c0.2,0.2,0.3,0.4,0.3,0.7s-0.1,0.5-0.3,0.7L24.3,21.2 l11.2,11.2c0.2,0.2,0.3,0.4,0.3,0.7s-0.1,0.5-0.3,0.7L34,35c-0.2,0.2-0.4,0.3-0.7,0.3s-0.5-0.1-0.7-0.3L19.5,21.8 c-0.2-0.2-0.3-0.4-0.3-0.7C19.2,20.9,19.3,20.7,19.5,20.5z M13.4,7.3c-0.2,0.2-0.3,0.4-0.3,0.7V11v23.4c0,0.3,0.1,0.5,0.3,0.7 c0.2,0.2,0.4,0.3,0.7,0.3h2c0.3,0,0.5-0.1,0.7-0.3s0.3-0.4,0.3-0.7V10.9l0-2.9c0-0.3-0.1-0.5-0.3-0.7C16.6,7.1,16.3,7,16.1,7h-2 C13.8,7,13.6,7.1,13.4,7.3z M7.3,7.3C7.1,7.4,7,7.7,7,7.9V11v23.4c0,0.3,0.1,0.5,0.3,0.7c0.2,0.2,0.4,0.3,0.7,0.3h2 c0.3,0,0.5-0.1,0.7-0.3c0.2-0.2,0.3-0.4,0.3-0.7V10.9l0-2.9c0-0.3-0.1-0.5-0.3-0.7C10.4,7.1,10.2,7,9.9,7h-2C7.7,7,7.4,7.1,7.3,7.3z '/%3E %3C/svg%3E\""

/***/ }),
/* 1469 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links_4_' d='M23.5,21.2c0-0.2-0.1-0.5-0.3-0.7L10,7.3C9.8,7.1,9.6,7,9.4,7S8.9,7.1,8.7,7.3L7.3,8.7 C7.1,8.9,7,9.1,7,9.4C7,9.6,7.1,9.8,7.3,10l11.2,11.2L7.3,32.3C7.1,32.5,7,32.7,7,33c0,0.2,0.1,0.5,0.3,0.7l1.4,1.4 c0.2,0.2,0.4,0.3,0.7,0.3s0.5-0.1,0.7-0.3l13.2-13.2C23.4,21.6,23.5,21.4,23.5,21.2z'/%3E %3Cpath id='Pfeil_links_5_' d='M29.3,35.1c0.2-0.2,0.3-0.4,0.3-0.7v-3.1V7.9c0-0.3-0.1-0.5-0.3-0.7C29.2,7.1,28.9,7,28.7,7h-2 c-0.3,0-0.5,0.1-0.7,0.3c-0.2,0.2-0.3,0.4-0.3,0.7v23.6l0,2.9c0,0.3,0.1,0.5,0.3,0.7c0.2,0.2,0.4,0.3,0.7,0.3h2 C28.9,35.3,29.2,35.2,29.3,35.1z'/%3E %3Cpath id='Pfeil_links_6_' d='M35.5,35.1c0.2-0.2,0.3-0.4,0.3-0.7v-3.1V7.9c0-0.3-0.1-0.5-0.3-0.7C35.3,7.1,35.1,7,34.8,7h-2 c-0.3,0-0.5,0.1-0.7,0.3c-0.2,0.2-0.3,0.4-0.3,0.7v23.6l0,2.9c0,0.3,0.1,0.5,0.3,0.7c0.2,0.2,0.4,0.3,0.7,0.3h2 C35.1,35.3,35.3,35.2,35.5,35.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1470 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.8,7.9C35.2,7.3,34.5,7,33.7,7H9C8.1,7,7.4,7.3,6.9,7.9C6.3,8.4,6,9.1,6,10v22.4c0,0.8,0.3,1.5,0.9,2.1 C7.4,35,8.1,35.3,9,35.3h24.8c0.8,0,1.5-0.3,2.1-0.9s0.9-1.3,0.9-2.1V10C36.7,9.1,36.4,8.4,35.8,7.9z M20.2,27.7 c0,0.2,0,0.3-0.1,0.4c-0.1,0.1-0.2,0.2-0.4,0.2H8.9c-0.1,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.1-0.3-0.1-0.4v-1.2c0-0.2,0-0.3,0.1-0.4 c0.1-0.1,0.2-0.2,0.4-0.2h10.8c0.1,0,0.3,0.1,0.4,0.2c0.1,0.1,0.1,0.3,0.1,0.4V27.7z M20.2,21.6c0,0.2,0,0.3-0.1,0.4 c-0.1,0.1-0.2,0.2-0.4,0.2H8.9c-0.1,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.1-0.3-0.1-0.4v-1.2c0-0.2,0-0.3,0.1-0.4c0.1-0.1,0.2-0.2,0.4-0.2 h10.8c0.1,0,0.3,0.1,0.4,0.2c0.1,0.1,0.1,0.3,0.1,0.4V21.6z M20.2,15.5c0,0.2,0,0.3-0.1,0.4c-0.1,0.1-0.2,0.2-0.4,0.2H8.9 c-0.1,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.1-0.3-0.1-0.4v-1.2c0-0.2,0-0.3,0.1-0.4c0.1-0.1,0.2-0.2,0.4-0.2h10.8c0.1,0,0.3,0.1,0.4,0.2 c0.1,0.1,0.1,0.3,0.1,0.4V15.5z M34.3,27.7c0,0.2,0,0.3-0.1,0.4c-0.1,0.1-0.2,0.2-0.4,0.2H23c-0.1,0-0.3-0.1-0.4-0.2 c-0.1-0.1-0.1-0.3-0.1-0.4v-1.2c0-0.2,0-0.3,0.1-0.4c0.1-0.1,0.2-0.2,0.4-0.2h10.8c0.1,0,0.3,0.1,0.4,0.2c0.1,0.1,0.1,0.3,0.1,0.4 V27.7z M34.3,21.6c0,0.2,0,0.3-0.1,0.4c-0.1,0.1-0.2,0.2-0.4,0.2H23c-0.1,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.1-0.3-0.1-0.4v-1.2 c0-0.2,0-0.3,0.1-0.4c0.1-0.1,0.2-0.2,0.4-0.2h10.8c0.1,0,0.3,0.1,0.4,0.2c0.1,0.1,0.1,0.3,0.1,0.4V21.6z M34.3,15.5 c0,0.2,0,0.3-0.1,0.4c-0.1,0.1-0.2,0.2-0.4,0.2H23c-0.1,0-0.3-0.1-0.4-0.2c-0.1-0.1-0.1-0.3-0.1-0.4v-1.2c0-0.2,0-0.3,0.1-0.4 c0.1-0.1,0.2-0.2,0.4-0.2h10.8c0.1,0,0.3,0.1,0.4,0.2c0.1,0.1,0.1,0.3,0.1,0.4V15.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1471 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_0.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='20.352941' inkscape:cx='20.086961' inkscape:cy='14.966928' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z M 27.1,32.1 22.9,29.9 c -0.250551,-0.131241 -0.4,-0.3 -0.6,-0.3 -0.2,0 -0.5,0.1 -0.6,0.3 l -4.2,2.2 c -0.375826,0.196861 -2.4,0.6 -2.2,1 0.2,0.4 0.450337,0.794257 0.8,0.6 h 3.6 v 0.2 c 0,0.2 0.1,0.4 0.3,0.6 0.2,0.2 0.4,-1.7 0.6,-1.7 H 24 c 0.2,0 0.4,1.9 0.6,1.7 0.2,-0.2 0.3,-0.4 0.3,-0.6 v -0.2 h 3.6 c 0.4,0 0.7,-0.2 0.8,-0.6 0.1,-0.4 -2,-0.7 -2.2,-1 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccscsscssscsssssscssc'/%3E %3C/svg%3E\""

/***/ }),
/* 1472 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_1.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='81.411764' inkscape:cx='23.028459' inkscape:cy='8.2581751' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z m -8.9,12.8 -6.2,-6.2 c -0.2,-0.2 -0.4,-0.3 -0.6,-0.3 -0.2,0 -0.5,0.1 -0.6,0.3 l -6.2,6.2 c -0.3,0.3 -0.4,0.6 -0.2,1 0.2,0.4 0.450337,0.794257 0.8,0.6 h 3.6 v 0.2 c 0,0.2 0.1,0.4 0.3,0.6 0.2,0.2 0.4,-1.7 0.6,-1.7 H 24 c 0.2,0 0.4,1.9 0.6,1.7 0.2,-0.2 0.3,-0.4 0.3,-0.6 v -0.2 h 3.6 c 0.4,0 0.7,-0.2 0.8,-0.6 0.1,-0.4 0,-0.7 -0.2,-1 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccscsscssscsssssscssc'/%3E %3C/svg%3E\""

/***/ }),
/* 1473 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_2.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='20.352941' inkscape:cx='19.764136' inkscape:cy='21.048437' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z m -8.9,6.8 -6.2,-6.2 c -0.2,-0.2 -0.4,-0.3 -0.6,-0.3 -0.2,0 -0.5,0.1 -0.6,0.3 l -6.2,6.2 c -0.3,0.3 -0.4,0.6 -0.2,1 0.2,0.4 0.450337,0.794257 0.8,0.6 h 3.6 v 4.2 c 0,0.2 0.1,0.4 0.3,0.6 0.2,0.2 0.4,0.3 0.6,0.3 H 24 c 0.2,0 0.4,-0.1 0.6,-0.3 0.2,-0.2 0.3,-0.4 0.3,-0.6 v -4.2 h 3.6 c 0.4,0 0.7,-0.2 0.8,-0.6 0.1,-0.4 0,-0.7 -0.2,-1 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccscsscssscsssssscssc'/%3E %3C/svg%3E\""

/***/ }),
/* 1474 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_3.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='20.352941' inkscape:cx='19.764136' inkscape:cy='21.048437' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z m -8.9,0.8 -6.2,-6.2 c -0.2,-0.2 -0.4,-0.3 -0.6,-0.3 -0.2,0 -0.5,0.1 -0.6,0.3 l -6.2,6.2 c -0.3,0.3 -0.4,0.6 -0.2,1 0.2,0.4 0.4,0.6 0.8,0.6 h 3.6 v 6.2 c 0,0.2 0.1,0.4 0.3,0.6 0.2,0.2 0.4,0.3 0.6,0.3 H 24 c 0.2,0 0.4,-0.1 0.6,-0.3 0.2,-0.2 0.3,-0.4 0.3,-0.6 v -6.2 h 3.6 c 0.4,0 0.7,-0.2 0.8,-0.6 0.1,-0.4 0,-0.7 -0.2,-1 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccscsscssscsssssscssc'/%3E %3C/svg%3E\""

/***/ }),
/* 1475 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_4.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='20.352941' inkscape:cx='19.764136' inkscape:cy='21.048437' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z M 29.1,14.1 22.9,7.9 C 22.7,7.7 22.5,7.6 22.3,7.6 c -0.2,0 -0.5,0.1 -0.6,0.3 l -6.2,6.2 c -0.3,0.3 -0.4,0.6 -0.2,1 0.2,0.4 0.4,0.6 0.8,0.6 h 3.6 v 6.2 c 0,0.2 0.1,0.4 0.3,0.6 0.2,0.2 0.4,0.3 0.6,0.3 H 24 c 0.2,0 0.4,-0.1 0.6,-0.3 0.2,-0.2 0.3,-0.4 0.3,-0.6 v -6.2 h 3.6 c 0.4,0 0.7,-0.2 0.8,-0.6 0.1,-0.4 0,-0.7 -0.2,-1 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccscsscssscsssssscssc'/%3E %3C/svg%3E\""

/***/ }),
/* 1476 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='UTF-8' standalone='no'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg xmlns:dc='http://purl.org/dc/elements/1.1/' xmlns:cc='http://creativecommons.org/ns%23' xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns%23' xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' xmlns:sodipodi='http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd' xmlns:inkscape='http://www.inkscape.org/namespaces/inkscape' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' sodipodi:docname='icon_filemanager_uploading_5.svg' inkscape:version='0.92.5 (2060ec1f9f, 2020-04-08)' width='42.5' height='42.5'%3E%3Cmetadata id='metadata64'%3E%3Crdf:RDF%3E%3Ccc:Work rdf:about=''%3E%3Cdc:format%3Eimage/svg+xml%3C/dc:format%3E%3Cdc:type rdf:resource='http://purl.org/dc/dcmitype/StillImage'/%3E%3Cdc:title/%3E%3C/cc:Work%3E%3C/rdf:RDF%3E%3C/metadata%3E%3Cdefs id='defs62'/%3E%3Csodipodi:namedview pagecolor='%23ffffff' bordercolor='%23666666' borderopacity='1' objecttolerance='10' gridtolerance='10' guidetolerance='10' inkscape:pageopacity='0' inkscape:pageshadow='2' inkscape:window-width='1864' inkscape:window-height='1043' id='namedview60' showgrid='false' inkscape:zoom='28.783405' inkscape:cx='11.871878' inkscape:cy='32.221635' inkscape:window-x='56' inkscape:window-y='0' inkscape:window-maximized='1' inkscape:current-layer='Ebene_1'/%3E %3Cpath d='M 9.8,18.1 H 7.2 v -10 c 0,-0.5 0.4,-0.8 1,-0.8 h 7.6 c 0.3,0 0.7,0.2 0.8,0.4 l 1.4,2 h 17 c 0.5,0 1,0.4 1,0.8 v 7.7 H 33.2 V 12.4 H 9.8 Z M 38,19.3 c -0.1,-0.1 -0.3,-0.2 -0.5,-0.2 h -7.1 l 3,2.8 h 0.9 c 0.2,0 0.4,0.1 0.5,0.2 0.1,0.1 0.2,0.3 0.2,0.5 l -2,9.2 c -0.1,0.3 -0.3,0.5 -0.7,0.5 H 10.8 c -0.3,0 -0.6,-0.2 -0.7,-0.5 L 8.3,22.6 c 0,-0.2 0,-0.3 0.2,-0.5 C 8.6,22 8.8,21.9 9,21.9 h 1.8 l 2.9,-2.8 h -8 C 5.5,19.1 5.3,19.2 5.2,19.3 5,19.4 5,19.6 5,19.8 l 2.7,14.4 c 0.1,0.3 0.3,0.5 0.7,0.5 h 26.3 c 0.4,0 0.6,-0.2 0.7,-0.5 l 2.7,-14.4 c 0.1,-0.2 0,-0.4 -0.1,-0.5 z M 29.1,10.1 26.9,7.9 C 26.7,7.7 22.5,7.6 22.3,7.6 c -0.2,0 -4.5,0.1 -4.6,0.3 l -2.2,2.2 c -0.3,0.3 -0.4,0.6 -0.2,1 0.2,0.4 0.4,0.6 0.8,0.6 h 3.6 v 4.2 c 0,0.2 0.1,0.4 0.3,0.6 0.2,0.2 0.4,0.3 0.6,0.3 H 24 c 0.2,0 0.4,-0.1 0.6,-0.3 0.2,-0.2 0.3,-0.4 0.3,-0.6 v -4.2 h 3.6 c 0.4,0 0.7,-0.2 0.8,-0.6 0.1,-0.4 0,-0.7 -0.2,-1 z' id='path57' inkscape:connector-curvature='0' sodipodi:nodetypes='ccsssccsscccccssccssccssccssccscccssccscsscssscsssssscssc'/%3E %3C/svg%3E\""

/***/ }),
/* 1477 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath d='M 35.6 21 C 35.6 18.4 34.9 15.9 33.6 13.7 C 32.3 11.5 30.5 9.7 28.3 8.4 C 26.1 7.1 23.6 6.4 21 6.4 C 18.4 6.4 15.9 7.1 13.7 8.4 C 11.5 9.7 9.7 11.5 8.4 13.7 C 7.1 15.9 6.4 18.4 6.4 21 C 6.4 23.6 7.1 26.1 8.4 28.3 C 9.7 30.5 11.5 32.3 13.7 33.6 C 15.9 34.9 18.4 35.6 21 35.6 C 23.6 35.6 26.1 34.9 28.3 33.6 C 30.5 32.3 32.3 30.5 33.6 28.3 C 34.9 26.1 35.6 23.6 35.6 21 Z M 38 21 C 38 24.1 37.2 26.9 35.7 29.5 C 34.2 32.1 32.1 34.2 29.5 35.7 C 26.9 37.2 24.1 38 21 38 C 17.9 38 15.1 37.2 12.5 35.7 C 9.9 34.2 7.8 32.1 6.3 29.5 C 4.8 26.9 4 24.1 4 21 C 4 17.9 4.8 15.1 6.3 12.5 C 7.8 9.9 9.9 7.8 12.5 6.3 C 15.1 4.8 17.9 4 21 4 C 24.1 4 26.9 4.8 29.5 6.3 C 32.1 7.8 34.2 9.9 35.7 12.5 C 37.2 15.1 38 17.9 38 21 Z'/%3E %3C/svg%3E\""

/***/ }),
/* 1478 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M35.7,12.5c-1.1-1.9-2.5-3.5-4.2-4.9l-1.4,2c1.4,1.1,2.6,2.5,3.6,4.1c1.3,2.2,2,4.7,2,7.3s-0.7,5.1-2,7.3 c-1.3,2.2-3.1,4-5.3,5.3c-2.2,1.3-4.7,2-7.3,2c-2.6,0-5.1-0.7-7.3-2c-2.2-1.3-4-3.1-5.3-5.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3 c1.3-2.2,3.1-4,5.3-5.3c2.1-1.2,4.4-1.9,6.9-1.9V4c-2.9,0.1-5.6,0.8-8.1,2.3c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21 c0,3.1,0.8,5.9,2.3,8.5s3.6,4.7,6.2,6.2c2.6,1.5,5.5,2.3,8.5,2.3c3.1,0,5.9-0.8,8.5-2.3c2.6-1.5,4.7-3.6,6.2-6.2S38,24.1,38,21 C38,17.9,37.2,15.1,35.7,12.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1479 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M37.3,16.1L35,16.9c0.4,1.3,0.6,2.7,0.6,4.1c0,2.6-0.7,5.1-2,7.3c-1.3,2.2-3.1,4-5.3,5.3c-2.2,1.3-4.7,2-7.3,2 c-2.6,0-5.1-0.7-7.3-2c-2.2-1.3-4-3.1-5.3-5.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3c2.2-1.3,4.5-1.9,7.1-1.9 l0-2.4c-3,0-5.7,0.8-8.3,2.3c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21c0,3.1,0.8,5.9,2.3,8.5s3.6,4.7,6.2,6.2 c2.6,1.5,5.5,2.3,8.5,2.3c3.1,0,5.9-0.8,8.5-2.3c2.6-1.5,4.7-3.6,6.2-6.2S38,24.1,38,21C38,19.3,37.8,17.7,37.3,16.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1480 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M37.3,16l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9c0,0.7-0.1,1.3-0.3,1.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5C38,19.3,37.7,17.6,37.3,16 z'/%3E %3Cpath d='M33.6,28.3c-1.3,2.2-3.1,4-5.3,5.3c-2.2,1.3-4.7,2-7.3,2c-2.6,0-5.1-0.7-7.3-2c-2.2-1.3-4-3.1-5.3-5.3c-1.3-2.2-2-4.7-2-7.3 s0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3c2.2-1.3,4.5-1.9,7.1-1.9l0-2.4c-3,0-5.8,0.8-8.3,2.3c-2.6,1.5-4.7,3.6-6.2,6.2 C4.8,15.1,4,17.9,4,21c0,3.1,0.8,5.9,2.3,8.5c1.5,2.6,3.6,4.7,6.2,6.2c2.6,1.5,5.5,2.3,8.5,2.3c3.1,0,5.9-0.8,8.5-2.3 c2.6-1.5,4.7-3.6,6.2-6.2c0.6-1,1-2,1.4-3.1l-2.3-0.7C34.5,26.6,34.1,27.5,33.6,28.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1481 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.7,28,22.3,27.8,22.9z'/%3E %3Cpath d='M25.4,26.6l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.6z'/%3E %3Cpath d='M28.3,33.6c-2.2,1.3-4.7,2-7.3,2c-2.6,0-5.1-0.7-7.3-2c-2.2-1.3-4-3.1-5.3-5.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3 c1.3-2.2,3.1-4,5.3-5.3c2.2-1.3,4.5-1.9,7-1.9V4c-3,0-5.7,0.8-8.3,2.3c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21 c0,3.1,0.8,5.9,2.3,8.5c1.5,2.6,3.6,4.7,6.2,6.2c2.6,1.5,5.5,2.3,8.5,2.3c3.1,0,5.9-0.8,8.5-2.3c0.4-0.3,0.8-0.5,1.2-0.8l-1.4-2 C29,33.1,28.7,33.4,28.3,33.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1482 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.7,28,22.3,27.8,22.9z'/%3E %3Cpath d='M21.3,38c3.5-0.1,6.8-1.2,9.4-3.1l-5.8-8c-1,0.7-2.3,1.1-3.6,1.2V38z'/%3E %3Cpath d='M25.4,26.6l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.6z'/%3E %3Cpath d='M8.4,28.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3c2.2-1.3,4.5-1.9,7-1.9L20.8,4c-3,0-5.8,0.8-8.3,2.3 c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21c0,3.1,0.8,5.9,2.3,8.5c1.5,2.6,3.6,4.7,6.2,6.2c2.5,1.5,5.2,2.2,8.2,2.3l0-2.4 c-2.5-0.1-4.8-0.7-7-1.9C11.5,32.3,9.7,30.5,8.4,28.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1483 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.7,28,22.3,27.8,22.9z'/%3E %3Cpath d='M21.3,38c3.5-0.1,6.8-1.2,9.4-3.1l-5.8-8c-1,0.7-2.3,1.1-3.6,1.2V38z'/%3E %3Cpath d='M11.3,34.9c2.7,1.9,5.9,3,9.4,3.1v-9.9c-1.3-0.1-2.6-0.5-3.6-1.2L11.3,34.9z'/%3E %3Cpath d='M25.4,26.6l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.6z'/%3E %3Cpath d='M8.4,28.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3c2.1-1.2,4.4-1.9,6.9-1.9V4c-2.9,0.1-5.7,0.8-8.2,2.3 c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21c0,3.1,0.8,5.9,2.3,8.5c1.2,2,2.7,3.7,4.5,5l1.4-2C10.6,31.4,9.4,30,8.4,28.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1484 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.7,28,22.3,27.8,22.9z'/%3E %3Cpath d='M21.3,38c3.5-0.1,6.8-1.2,9.4-3.1l-5.8-8c-1,0.7-2.3,1.1-3.6,1.2V38z'/%3E %3Cpath d='M11.3,34.9c2.7,1.9,5.9,3,9.4,3.1v-9.9c-1.3-0.1-2.6-0.5-3.6-1.2L11.3,34.9z'/%3E %3Cpath d='M25.4,26.6l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.6z'/%3E %3Cpath d='M14.4,23.5l-9.4,3.1c1.1,3.2,3.2,6,5.8,8l5.8-8C15.6,25.8,14.8,24.7,14.4,23.5z'/%3E %3Cpath d='M6.4,21c0-2.6,0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3c2.1-1.3,4.5-1.9,7-1.9V4c-3,0-5.7,0.8-8.2,2.3c-2.6,1.5-4.7,3.6-6.2,6.2 C4.8,15.1,4,17.9,4,21c0,1.7,0.2,3.3,0.7,4.9L7,25.2C6.7,23.8,6.4,22.4,6.4,21z'/%3E %3C/svg%3E\""

/***/ }),
/* 1485 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.7,28,22.3,27.8,22.9z'/%3E %3Cpath d='M21.3,38c3.5-0.1,6.8-1.2,9.4-3.1l-5.8-8c-1,0.7-2.3,1.1-3.6,1.2V38z'/%3E %3Cpath d='M11.3,34.9c2.7,1.9,5.9,3,9.4,3.1v-9.9c-1.3-0.1-2.6-0.5-3.6-1.2L11.3,34.9z'/%3E %3Cpath d='M25.4,26.6l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.6z'/%3E %3Cpath d='M14.4,23.5l-9.4,3.1c1.1,3.2,3.2,6,5.8,8l5.8-8C15.6,25.8,14.8,24.7,14.4,23.5z'/%3E %3Cpath d='M14.2,19.1L4.7,16C4.3,17.6,4,19.3,4,21c0,1.7,0.3,3.4,0.7,5l9.4-3.1c-0.2-0.6-0.3-1.2-0.3-1.9C13.9,20.3,14,19.7,14.2,19.1 z'/%3E %3Cpath d='M8.4,13.7c1.3-2.2,3.1-4,5.3-5.3c2.1-1.2,4.5-1.9,7-1.9l0-2.4c-2.9,0.1-5.7,0.8-8.2,2.3c-2.6,1.5-4.7,3.6-6.2,6.2 c-0.5,0.9-1,1.8-1.3,2.8l2.3,0.9C7.6,15.3,7.9,14.5,8.4,13.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 1486 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.6,28,22.3,27.8,22.9z'/%3E %3Cpath d='M21.3,38c3.5-0.1,6.8-1.2,9.4-3.1l-5.8-8c-1,0.7-2.3,1.1-3.6,1.2V38z'/%3E %3Cpath d='M11.3,34.9c2.7,1.9,5.9,3,9.4,3.1v-9.9c-1.3-0.1-2.6-0.5-3.6-1.2L11.3,34.9z'/%3E %3Cpath d='M25.4,26.5l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.5z'/%3E %3Cpath d='M14.4,23.5l-9.4,3.1c1.1,3.2,3.2,6,5.8,8l5.8-8C15.6,25.8,14.8,24.7,14.4,23.5z'/%3E %3Cpath d='M16.6,15.4l-5.8-8c-2.7,2-4.7,4.8-5.8,8l9.4,3.1C14.8,17.3,15.6,16.2,16.6,15.4z'/%3E %3Cpath d='M14.2,19.1L4.7,16C4.3,17.6,4,19.3,4,21c0,1.7,0.3,3.4,0.7,5l9.4-3.1c-0.2-0.6-0.3-1.2-0.3-1.9 C13.9,20.3,14,19.7,14.2,19.1z'/%3E %3Cpath d='M13.7,8.4c2.1-1.2,4.3-1.9,6.8-1.9c0.1,0,0.2-0.1,0.2-0.2l0-2.1c0-0.1-0.1-0.2-0.2-0.2c-2.9,0.1-5.5,0.8-7.9,2.3 c-0.4,0.2-0.8,0.5-1.2,0.8l1.4,2C13,8.8,13.3,8.6,13.7,8.4z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1487 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M30.7,7.1c-2.7-1.9-5.9-3-9.4-3.1v9.9c1.3,0.1,2.6,0.5,3.6,1.2L30.7,7.1z'/%3E %3Cpath d='M27.7,18.5l9.4-3.1c-1.1-3.2-3.2-6-5.8-8l-5.8,8C26.4,16.2,27.2,17.3,27.7,18.5z'/%3E %3Cpath d='M27.8,22.9l9.4,3.1c0.5-1.6,0.7-3.2,0.7-5c0-1.7-0.3-3.4-0.7-5l-9.4,3.1c0.2,0.6,0.3,1.2,0.3,1.9 C28.1,21.6,28,22.3,27.8,22.9z'/%3E %3Cpath d='M20.7,4c-3.5,0.1-6.8,1.2-9.4,3.1l5.8,8c1-0.7,2.3-1.1,3.6-1.2V4z'/%3E %3Cpath d='M21.3,38c3.5-0.1,6.8-1.2,9.4-3.1l-5.8-8c-1,0.7-2.3,1.1-3.6,1.2V38z'/%3E %3Cpath d='M11.3,34.9c2.7,1.9,5.9,3,9.4,3.1v-9.9c-1.3-0.1-2.6-0.5-3.6-1.2L11.3,34.9z'/%3E %3Cpath d='M25.4,26.5l5.8,8c2.7-2,4.7-4.8,5.8-8l-9.4-3.1C27.2,24.7,26.4,25.8,25.4,26.5z'/%3E %3Cpath d='M14.4,23.5l-9.4,3.1c1.1,3.2,3.2,6,5.8,8l5.8-8C15.6,25.8,14.8,24.7,14.4,23.5z'/%3E %3Cpath d='M16.6,15.4l-5.8-8c-2.7,2-4.7,4.8-5.8,8l9.4,3.1C14.8,17.3,15.6,16.2,16.6,15.4z'/%3E %3Cpath d='M14.2,19.1L4.7,16C4.3,17.6,4,19.3,4,21c0,1.7,0.3,3.4,0.7,5l9.4-3.1c-0.2-0.6-0.3-1.2-0.3-1.9 C13.9,20.3,14,19.7,14.2,19.1z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1488 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.6,21c0-2.6-0.7-5.1-2-7.3s-3.1-4-5.3-5.3s-4.7-2-7.3-2s-5.1,0.7-7.3,2s-4,3.1-5.3,5.3s-2,4.7-2,7.3s0.7,5.1,2,7.3 s3.1,4,5.3,5.3s4.7,2,7.3,2s5.1-0.7,7.3-2s4-3.1,5.3-5.3S35.6,23.6,35.6,21z M38,21c0,3.1-0.8,5.9-2.3,8.5s-3.6,4.7-6.2,6.2 S24.1,38,21,38s-5.9-0.8-8.5-2.3s-4.7-3.6-6.2-6.2S4,24.1,4,21s0.8-5.9,2.3-8.5s3.6-4.7,6.2-6.2S17.9,4,21,4s5.9,0.8,8.5,2.3 s4.7,3.6,6.2,6.2S38,17.9,38,21z M20.7,21c0,1-0.2,1.8-0.6,2.4c-0.5,0.8-1.1,1.2-2,1.2s-1.6-0.4-2-1.2c-0.4-0.7-0.6-1.5-0.6-2.4 c0-1,0.2-1.8,0.6-2.4c0.5-0.8,1.1-1.2,2-1.2s1.6,0.4,2,1.2C20.5,19.3,20.7,20.1,20.7,21z M19.2,21.1c0-0.5-0.1-1-0.2-1.4 c-0.2-0.6-0.5-0.8-0.9-0.8s-0.8,0.3-1,0.8c-0.1,0.4-0.2,0.8-0.2,1.4c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8 C18.9,23.3,19.2,22.5,19.2,21.1z M24.9,20.6c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5s-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1 c0-0.4,0.1-0.8,0.3-1.1c0.2-0.3,0.5-0.5,1-0.5s0.7,0.2,1,0.5C24.8,19.8,24.9,20.1,24.9,20.6z M24.1,20.6c0-0.5-0.1-0.7-0.4-0.7 s-0.4,0.2-0.4,0.7s0.1,0.7,0.4,0.7C23.9,21.3,24.1,21.1,24.1,20.6z M27.1,19.1l-2.5,5.5h-1l2.5-5.5H27.1z M28.2,23.1 c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1 c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5C28.1,22.3,28.2,22.6,28.2,23.1z M27.4,23.1c0-0.5-0.1-0.7-0.4-0.7s-0.4,0.2-0.4,0.7 s0.1,0.7,0.4,0.7C27.2,23.8,27.4,23.6,27.4,23.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1489 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38,21c0,3.1-0.8,5.9-2.3,8.5s-3.6,4.7-6.2,6.2C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3c-2.6-1.5-4.7-3.6-6.2-6.2 S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5c1.5-2.6,3.6-4.7,6.2-6.2C15,4.8,17.7,4.1,20.6,4v2.4c-2.5,0.1-4.8,0.7-6.9,1.9 c-2.2,1.3-4,3.1-5.3,5.3c-1.3,2.2-2,4.7-2,7.3s0.7,5.1,2,7.3c1.3,2.2,3.1,4,5.3,5.3c2.2,1.3,4.7,2,7.3,2c2.6,0,5.1-0.7,7.3-2 c2.2-1.3,4-3.1,5.3-5.3c1.3-2.2,2-4.7,2-7.3s-0.7-5.1-2-7.3c-0.9-1.6-2.1-3-3.6-4.1l1.4-2c1.7,1.3,3.1,2.9,4.2,4.9 C37.2,15.1,38,17.9,38,21z M22.3,4c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1c0,0,0,0,0,0c0,0,0.1,0,0.1,0C23.9,8.7,24.9,9,26,9.5 c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0c0,0,0.1,0,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0 c0,0,0.1,0,0.1,0.1l2.6-3.6c-0.4-0.3-0.8-0.5-1.2-0.8C29,6,28.4,5.7,27.8,5.4c0,0,0,0,0,0c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0 c0,0-0.1,0-0.1-0.1c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0c-1.5-0.6-3.1-0.9-4.7-1.1C22.4,4.1,22.4,4,22.3,4C22.3,4,22.3,4,22.3,4z M15.6,17.6h-1l-1.9,1.2l0.6,1.1l0.9-0.5v5.2h1.4V17.6z M21.3,18.6c-0.5-0.8-1.1-1.2-2-1.2c-0.9,0-1.6,0.4-2,1.2 c-0.4,0.7-0.6,1.5-0.6,2.4c0,1,0.2,1.8,0.6,2.4c0.5,0.8,1.1,1.2,2,1.2c0.9,0,1.6-0.4,2-1.2c0.4-0.7,0.6-1.5,0.6-2.4 C21.8,20.1,21.7,19.3,21.3,18.6z M19.3,23.3c-0.4,0-0.8-0.3-1-0.8c-0.1-0.4-0.2-0.8-0.2-1.4c0-0.6,0.1-1,0.2-1.4 c0.2-0.5,0.5-0.8,1-0.8c0.4,0,0.8,0.3,0.9,0.8c0.1,0.4,0.2,0.8,0.2,1.4C20.4,22.5,20,23.3,19.3,23.3z M25.8,19.5 c-0.2-0.3-0.5-0.5-1-0.5s-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5s0.7-0.2,1-0.5 c0.2-0.3,0.3-0.6,0.3-1.1C26.1,20.1,26,19.8,25.8,19.5z M24.8,21.3c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7 c0.3,0,0.4,0.2,0.4,0.7C25.2,21.1,25.1,21.3,24.8,21.3z M27.2,19.1l-2.5,5.5h1l2.5-5.5H27.2z M29.1,22c-0.2-0.3-0.5-0.5-1-0.5 c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5c0.4,0,0.7-0.2,1-0.5 c0.2-0.3,0.3-0.6,0.3-1.1C29.4,22.6,29.3,22.3,29.1,22z M28.1,23.8c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7 c0.3,0,0.4,0.2,0.4,0.7C28.5,23.6,28.4,23.8,28.1,23.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 1490 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.8,24.5h-4.4v-0.9c0-0.7,0.3-1.3,0.8-1.9c0.2-0.3,0.7-0.7,1.4-1.2c0.5-0.4,0.8-0.7,0.8-1c0-0.2-0.1-0.4-0.3-0.5 c-0.2-0.1-0.4-0.2-0.6-0.2c-0.4,0-0.7,0.3-1,0.8l-1.2-0.7c0.5-1,1.2-1.5,2.2-1.5c0.7,0,1.2,0.2,1.6,0.5c0.4,0.4,0.7,0.9,0.7,1.5 c0,0.5-0.2,1-0.6,1.5c0,0-0.4,0.3-1.2,1c-0.5,0.4-0.8,0.8-0.9,1.2h2.8V24.5z M22.3,21c0,1-0.2,1.8-0.6,2.4c-0.5,0.8-1.1,1.2-2,1.2 c-0.9,0-1.6-0.4-2-1.2c-0.4-0.6-0.6-1.4-0.6-2.4c0-1,0.2-1.8,0.6-2.4c0.5-0.8,1.1-1.2,2-1.2c0.9,0,1.6,0.4,2,1.2 C22.1,19.3,22.3,20.1,22.3,21z M20.8,21c0-0.5-0.1-1-0.2-1.4c-0.2-0.6-0.5-0.8-0.9-0.8c-0.4,0-0.8,0.3-1,0.8 c-0.1,0.4-0.2,0.8-0.2,1.4c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8C20.5,23.2,20.8,22.5,20.8,21z M26.5,20.5 c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5c-0.4,0-0.7-0.2-1-0.5C24.1,21.4,24,21,24,20.5c0-0.4,0.1-0.8,0.3-1.1 c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5C26.4,19.7,26.5,20.1,26.5,20.5z M25.7,20.5c0-0.5-0.1-0.7-0.4-0.7 c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7C25.5,21.3,25.7,21,25.7,20.5z M28.7,19l-2.5,5.5h-1l2.5-5.5H28.7z M29.8,23 c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1 c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5C29.7,22.2,29.8,22.6,29.8,23z M29,23c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7 c0,0.5,0.1,0.7,0.4,0.7C28.8,23.8,29,23.5,29,23z M37.3,16.1L35,16.9c0.4,1.3,0.6,2.7,0.6,4.1c0,2.6-0.7,5.1-2,7.3 c-1.3,2.2-3.1,4-5.3,5.3c-2.2,1.3-4.7,2-7.3,2c-2.6,0-5.1-0.7-7.3-2c-2.2-1.3-4-3.1-5.3-5.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3 c1.3-2.2,3.1-4,5.3-5.3c2.2-1.3,4.5-1.9,7.1-1.9l0-2.4c-3,0-5.7,0.8-8.3,2.3c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21 c0,3.1,0.8,5.9,2.3,8.5s3.6,4.7,6.2,6.2c2.6,1.5,5.5,2.3,8.5,2.3c3.1,0,5.9-0.8,8.5-2.3c2.6-1.5,4.7-3.6,6.2-6.2S38,24.1,38,21 C38,19.3,37.8,17.7,37.3,16.1z M22.3,4c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1c0,0,0,0,0,0c0,0,0.1,0,0.1,0 c1.1,0.1,2.2,0.4,3.2,0.9c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0c0,0,0.1,0,0.1,0.1 c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0c0,0,0.1,0,0.1,0.1l2.6-3.6c-0.4-0.3-0.8-0.5-1.2-0.8C29,6,28.4,5.7,27.8,5.4c0,0,0,0,0,0 c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1-0.1c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0c-1.5-0.6-3.1-0.9-4.7-1.1 C22.4,4.1,22.4,4,22.3,4C22.3,4,22.3,4,22.3,4z M31.3,7.4l-2.6,3.6c0.1,0,0.1,0.1,0.2,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1 c0.8,0.6,1.4,1.3,2,2.1c0.1,0.2,0.3,0.4,0.4,0.6c0,0,0,0,0,0c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.1,0.1,0.2 c0,0,0,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0.1,0.1,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1 c0,0.1,0.1,0.2,0.1,0.2c0,0,0,0,0,0c0.1,0.2,0.2,0.4,0.3,0.6c0.1,0.2,0.2,0.5,0.3,0.7l4.3-1.4c-0.1-0.4-0.3-0.8-0.4-1.1 c-0.3-0.6-0.6-1.2-0.9-1.8c-0.5-0.9-1.1-1.7-1.8-2.5c0,0,0,0-0.1-0.1c0,0,0-0.1-0.1-0.1c-0.3-0.3-0.5-0.6-0.8-0.9 C32.5,8.4,31.9,7.9,31.3,7.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1491 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.8,25.7l2.3,0.7c-0.4,1.1-0.8,2.1-1.4,3.1c-1.5,2.6-3.6,4.7-6.2,6.2C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3 c-2.6-1.5-4.7-3.6-6.2-6.2S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5c1.5-2.6,3.6-4.7,6.2-6.2C15,4.8,17.8,4,20.8,4l0,2.4 c-2.6,0-4.9,0.7-7.1,1.9c-2.2,1.3-4,3.1-5.3,5.3c-1.3,2.2-2,4.7-2,7.3s0.7,5.1,2,7.3c1.3,2.2,3.1,4,5.3,5.3c2.2,1.3,4.7,2,7.3,2 c2.6,0,5.1-0.7,7.3-2c2.2-1.3,4-3.1,5.3-5.3C34.1,27.5,34.5,26.6,34.8,25.7z M16.5,21.5c-0.1-0.3-0.3-0.5-0.6-0.7 c0.4-0.4,0.6-0.8,0.6-1.3c0-0.6-0.2-1.1-0.6-1.5c-0.4-0.4-0.9-0.6-1.5-0.6c-1.1,0-1.8,0.5-2.2,1.5l1.3,0.6c0.2-0.5,0.5-0.7,0.9-0.7 c0.2,0,0.4,0.1,0.6,0.2c0.2,0.1,0.3,0.3,0.3,0.5c0,0.5-0.4,0.8-1.2,0.8v1.1c0.4,0,0.7,0,0.9,0.2c0.3,0.1,0.4,0.4,0.4,0.8 c0,0.3-0.1,0.5-0.3,0.6c-0.2,0.2-0.4,0.2-0.7,0.2c-0.2,0-0.5-0.1-0.6-0.2c-0.2-0.2-0.3-0.3-0.4-0.6L12.1,23c0.4,1.1,1.1,1.6,2.3,1.6 c0.7,0,1.2-0.2,1.6-0.6c0.4-0.4,0.7-1,0.7-1.6C16.7,22.1,16.7,21.8,16.5,21.5z M21.8,18.6c-0.5-0.8-1.1-1.2-2-1.2 c-0.9,0-1.6,0.4-2,1.2c-0.4,0.7-0.6,1.5-0.6,2.4c0,0.9,0.2,1.7,0.6,2.4c0.5,0.8,1.1,1.2,2,1.2c0.9,0,1.6-0.4,2-1.2 c0.4-0.7,0.6-1.5,0.6-2.4C22.4,20,22.2,19.2,21.8,18.6z M19.8,23.2c-0.4,0-0.8-0.3-1-0.8c-0.1-0.4-0.2-0.8-0.2-1.4 c0-0.6,0.1-1,0.2-1.4c0.2-0.5,0.5-0.8,1-0.8c0.4,0,0.7,0.3,0.9,0.8C20.9,20,21,20.5,21,21C21,22.5,20.6,23.2,19.8,23.2z M26.3,19.4 c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5 c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1C26.6,20.1,26.5,19.7,26.3,19.4z M25.4,21.3c-0.3,0-0.4-0.2-0.4-0.7 c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7C25.8,21,25.6,21.3,25.4,21.3z M27.8,19l-2.5,5.5h1l2.5-5.5H27.8z M29.6,21.9 c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5 c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1C29.9,22.6,29.8,22.2,29.6,21.9z M28.7,23.8c-0.3,0-0.4-0.2-0.4-0.7 c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7C29.1,23.5,28.9,23.8,28.7,23.8z M22.3,4c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1 c0,0,0,0,0,0c0,0,0.1,0,0.1,0c1.1,0.1,2.2,0.4,3.2,0.9c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0 c0,0,0.1,0,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0c0,0,0.1,0,0.1,0.1l2.6-3.6c-0.4-0.3-0.8-0.5-1.2-0.8 c-0.6-0.3-1.1-0.6-1.7-0.9c0,0,0,0,0,0c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1-0.1c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0 c-1.5-0.6-3.1-0.9-4.7-1.1C22.4,4.1,22.3,4,22.3,4C22.3,4,22.3,4,22.3,4z M33,9c0.3,0.3,0.5,0.6,0.8,0.9c0,0,0,0.1,0.1,0.1 c0,0,0,0,0.1,0.1c0.7,0.8,1.3,1.6,1.8,2.5c0.3,0.6,0.6,1.2,0.9,1.8c0.2,0.4,0.3,0.7,0.4,1.1l-4.3,1.4c-0.1-0.2-0.2-0.5-0.3-0.7 c-0.1-0.2-0.2-0.4-0.3-0.6c0,0,0,0,0,0c0-0.1-0.1-0.2-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1 c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2 c0,0,0,0,0,0c-0.1-0.2-0.3-0.4-0.4-0.6c-0.6-0.8-1.3-1.5-2-2.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.1,0-0.1-0.1-0.2-0.1l2.6-3.6 C31.9,7.9,32.5,8.4,33,9z M38,21c0,0.7,0,1.4-0.1,2c-0.1,0.8-0.2,1.6-0.5,2.4c-0.1,0.2-0.1,0.4-0.2,0.6L33,24.6c0-0.1,0-0.1,0.1-0.2 c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0.1-0.5,0.2-1,0.3-1.6c0.1-0.4,0.1-0.9,0.1-1.3c0,0,0,0,0,0 c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.4,0-0.9-0.1-1.3 c-0.1-0.5-0.2-1-0.3-1.6c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.1,0-0.1-0.1-0.2l4.2-1.4 c0.1,0.2,0.1,0.4,0.2,0.6c0.2,0.8,0.4,1.6,0.5,2.4C38,19.6,38,20.3,38,21z'/%3E %3C/svg%3E\""

/***/ }),
/* 1492 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M29.3,32.9l1.4,2c-0.4,0.3-0.8,0.6-1.2,0.8C26.9,37.2,24.1,38,21,38c-3.1,0-5.9-0.8-8.5-2.3c-2.6-1.5-4.7-3.6-6.2-6.2 S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5c1.5-2.6,3.6-4.7,6.2-6.2C15,4.8,17.8,4.1,20.7,4v2.4c-2.5,0-4.9,0.7-7,1.9 c-2.2,1.3-4,3.1-5.3,5.3c-1.3,2.2-2,4.7-2,7.3s0.7,5.1,2,7.3c1.3,2.2,3.1,4,5.3,5.3c2.2,1.3,4.7,2,7.3,2c2.6,0,5.1-0.7,7.3-2 C28.7,33.4,29,33.2,29.3,32.9z M16.9,21.7h-0.5v-1.6l-1.3-0.2v1.8h-1.4l2.5-4.2h-1.5L12,21.9V23h3.1v1.5h1.3V23h0.5V21.7z M21.9,18.6c-0.5-0.8-1.1-1.2-2-1.2c-0.9,0-1.6,0.4-2,1.2c-0.4,0.7-0.6,1.5-0.6,2.4c0,0.9,0.2,1.7,0.6,2.4c0.5,0.8,1.1,1.2,2,1.2 c0.9,0,1.6-0.4,2-1.2c0.4-0.7,0.6-1.5,0.6-2.4C22.5,20,22.3,19.2,21.9,18.6z M19.9,23.2c-0.4,0-0.8-0.3-1-0.8 c-0.1-0.4-0.2-0.8-0.2-1.4c0-0.6,0.1-1,0.2-1.4c0.2-0.5,0.5-0.8,1-0.8c0.4,0,0.7,0.3,0.9,0.8C21,20,21,20.5,21,21 C21,22.5,20.7,23.2,19.9,23.2z M26.4,19.4c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1 c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1C26.7,20.1,26.6,19.7,26.4,19.4z M25.5,21.3c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7C25.8,21,25.7,21.3,25.5,21.3z M27.8,19l-2.5,5.5h1 l2.5-5.5H27.8z M29.7,21.9c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1 c0.2,0.3,0.5,0.5,1,0.5c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1C30,22.6,29.9,22.2,29.7,21.9z M28.7,23.8 c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7C29.1,23.5,29,23.8,28.7,23.8z M36.7,27.7 c0.2-0.4,0.3-0.7,0.4-1.1l-4.3-1.4c-0.1,0.2-0.2,0.5-0.3,0.7c-0.1,0.2-0.2,0.4-0.3,0.6c0,0,0,0,0,0c0,0.1-0.1,0.2-0.1,0.2 c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.1 c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0c-0.1,0.2-0.3,0.4-0.4,0.6c-0.6,0.8-1.3,1.5-2,2.1 c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1l2.6,3.6c0.6-0.5,1.2-1,1.8-1.6c0.3-0.3,0.6-0.6,0.8-0.9c0,0,0,0,0-0.1 c0,0,0-0.1,0.1-0.1c0.7-0.8,1.3-1.6,1.8-2.5C36.1,28.9,36.4,28.3,36.7,27.7z M22.3,4c0,0,0.1,0,0.1,0c1.6,0.1,3.2,0.5,4.7,1.1 c0,0,0,0,0,0c0.1,0,0.1,0,0.2,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0c0.1,0,0.1,0.1,0.2,0.1c0,0,0,0,0,0c0.6,0.3,1.2,0.6,1.7,0.9 c0.4,0.2,0.8,0.5,1.2,0.8l-2.6,3.6c0,0-0.1,0-0.1-0.1c0,0,0,0-0.1,0c0,0-0.1-0.1-0.1-0.1c0,0-0.1,0-0.1-0.1c0,0,0,0,0,0 c-0.1-0.1-0.2-0.1-0.3-0.2c0,0,0,0,0,0c-0.5-0.3-1-0.5-1.5-0.7c-1-0.4-2.1-0.7-3.2-0.9c0,0-0.1,0-0.1,0c0,0,0,0,0,0 c-0.4-0.1-0.8-0.1-1.3-0.1V4C21.6,4,22,4,22.3,4C22.3,4,22.3,4,22.3,4z M33,9c0.3,0.3,0.5,0.6,0.8,0.9c0,0,0,0.1,0.1,0.1 c0,0,0,0,0.1,0.1c0.7,0.8,1.3,1.6,1.8,2.5c0.3,0.6,0.6,1.2,0.9,1.8c0.2,0.4,0.3,0.7,0.4,1.1l-4.3,1.4c-0.1-0.2-0.2-0.5-0.3-0.7 c-0.1-0.2-0.2-0.4-0.3-0.6c0,0,0,0,0,0c0-0.1-0.1-0.2-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1 c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2 c0,0,0,0,0,0c-0.1-0.2-0.3-0.4-0.4-0.6c-0.6-0.8-1.3-1.5-2-2.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.1,0-0.1-0.1-0.2-0.1l2.6-3.6 C31.9,7.9,32.5,8.4,33,9z M38,21c0,0.7,0,1.4-0.1,2c-0.1,0.8-0.2,1.6-0.5,2.4c-0.1,0.2-0.1,0.4-0.2,0.6L33,24.6c0-0.1,0-0.1,0.1-0.2 c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0.1-0.5,0.2-1,0.3-1.6c0.1-0.4,0.1-0.9,0.1-1.3c0,0,0,0,0,0 c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.4,0-0.9-0.1-1.3 c-0.1-0.5-0.2-1-0.3-1.6c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.1,0-0.1-0.1-0.2l4.2-1.4 c0.1,0.2,0.1,0.4,0.2,0.6c0.2,0.8,0.4,1.6,0.5,2.4C38,19.6,38,20.3,38,21z'/%3E %3C/svg%3E\""

/***/ }),
/* 1493 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M20.7,35.6l0,2.4c-2.9-0.1-5.7-0.8-8.2-2.3c-2.6-1.5-4.7-3.6-6.2-6.2S4,24.1,4,21c0-3.1,0.8-5.9,2.3-8.5 c1.5-2.6,3.6-4.7,6.2-6.2C15,4.8,17.8,4,20.8,4l-0.1,2.4c-2.5,0-4.9,0.7-7,1.9c-2.2,1.3-4,3.1-5.3,5.3c-1.3,2.2-2,4.7-2,7.3 s0.7,5.1,2,7.3c1.3,2.2,3.1,4,5.3,5.3C15.8,34.9,18.2,35.5,20.7,35.6z M16.2,20.3c-0.4-0.4-1-0.7-1.7-0.7c-0.3,0-0.6,0.1-0.9,0.2v-1 h2.7v-1.4h-4v3.9h1.2c0.3-0.3,0.6-0.4,0.9-0.4c0.3,0,0.6,0.1,0.7,0.3c0.2,0.2,0.3,0.4,0.3,0.8c0,0.3-0.1,0.6-0.2,0.8 c-0.2,0.2-0.4,0.4-0.8,0.4c-0.5,0-0.8-0.3-1-0.9l-1.3,0.4c0.4,1.2,1.1,1.8,2.3,1.8c0.8,0,1.4-0.2,1.8-0.7c0.4-0.4,0.6-1.1,0.6-1.8 C16.8,21.3,16.6,20.8,16.2,20.3z M21.8,18.6c-0.5-0.8-1.1-1.2-2-1.2c-0.9,0-1.6,0.4-2,1.2c-0.4,0.7-0.6,1.5-0.6,2.4 c0,0.9,0.2,1.7,0.6,2.4c0.5,0.8,1.1,1.2,2,1.2c0.9,0,1.6-0.4,2-1.2c0.4-0.7,0.6-1.5,0.6-2.4C22.4,20,22.2,19.2,21.8,18.6z M19.8,23.2c-0.4,0-0.8-0.3-1-0.8c-0.1-0.4-0.2-0.8-0.2-1.4c0-0.6,0.1-1,0.2-1.4c0.2-0.5,0.5-0.8,1-0.8c0.4,0,0.7,0.3,0.9,0.8 c0.1,0.4,0.2,0.8,0.2,1.4C20.9,22.5,20.5,23.2,19.8,23.2z M26.3,19.4c-0.2-0.3-0.5-0.5-1-0.5s-0.7,0.2-1,0.5 c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5s0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1 C26.6,20.1,26.5,19.7,26.3,19.4z M25.3,21.3c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7 C25.7,21,25.6,21.3,25.3,21.3z M27.7,19l-2.5,5.5h1l2.5-5.5H27.7z M29.6,21.9c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5 c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1 C29.9,22.6,29.8,22.2,29.6,21.9z M28.6,23.8c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7 C29,23.5,28.9,23.8,28.6,23.8z M36.7,27.7c0.2-0.4,0.3-0.7,0.4-1.1l-4.3-1.4c-0.1,0.2-0.2,0.5-0.3,0.7c-0.1,0.2-0.2,0.4-0.3,0.6 c0,0,0,0,0,0c0,0.1-0.1,0.2-0.1,0.2c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1 c0,0-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0 c-0.1,0.2-0.3,0.4-0.4,0.6c-0.6,0.8-1.3,1.5-2,2.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1l2.6,3.6 c0.6-0.5,1.2-1,1.8-1.6c0.3-0.3,0.6-0.6,0.8-0.9c0,0,0,0,0-0.1c0,0,0-0.1,0.1-0.1c0.7-0.8,1.3-1.6,1.8-2.5 C36.1,28.9,36.4,28.3,36.7,27.7z M27.5,36.7c-0.1,0-0.1,0.1-0.2,0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1,0c-0.1,0-0.1,0-0.2,0.1 c0,0,0,0,0,0c-1.4,0.5-2.9,0.9-4.4,1c-0.4,0-0.7,0-1.1,0.1v-4.5c0.5,0,0.9,0,1.4-0.1c1.1-0.1,2.2-0.4,3.2-0.9c0.5-0.2,1-0.5,1.5-0.7 c0,0,0,0,0.1,0c0,0,0.1-0.1,0.1-0.1c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0.1,0c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0,0c0,0,0.1,0,0.1-0.1 l2.6,3.6c-0.4,0.3-0.8,0.5-1.2,0.8C28.9,36.1,28.2,36.4,27.5,36.7C27.5,36.7,27.5,36.7,27.5,36.7z M22.3,4c0,0,0.1,0,0.1,0 c1.6,0.1,3.2,0.5,4.7,1.1c0,0,0,0,0,0c0.1,0,0.1,0,0.2,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0c0.1,0,0.1,0.1,0.2,0.1c0,0,0,0,0,0 c0.6,0.3,1.2,0.6,1.7,0.9c0.4,0.2,0.8,0.5,1.2,0.8l-2.6,3.6c0,0-0.1,0-0.1-0.1c0,0,0,0-0.1,0c0,0-0.1-0.1-0.1-0.1c0,0-0.1,0-0.1-0.1 c0,0,0,0,0,0c-0.1-0.1-0.2-0.1-0.3-0.2c0,0,0,0,0,0c-0.5-0.3-1-0.5-1.5-0.7c-1-0.4-2.1-0.7-3.2-0.9c0,0-0.1,0-0.1,0c0,0,0,0,0,0 c-0.4-0.1-0.8-0.1-1.3-0.1V4C21.6,4,22,4,22.3,4C22.3,4,22.3,4,22.3,4z M33,9c0.3,0.3,0.5,0.6,0.8,0.9c0,0,0,0.1,0.1,0.1 c0,0,0,0,0.1,0.1c0.7,0.8,1.3,1.6,1.8,2.5c0.3,0.6,0.6,1.2,0.9,1.8c0.2,0.4,0.3,0.7,0.4,1.1l-4.3,1.4c-0.1-0.2-0.2-0.5-0.3-0.7 c-0.1-0.2-0.2-0.4-0.3-0.6c0,0,0,0,0,0c0-0.1-0.1-0.2-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1 c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2 c0,0,0,0,0,0c-0.1-0.2-0.3-0.4-0.4-0.6c-0.6-0.8-1.3-1.5-2-2.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.1,0-0.1-0.1-0.2-0.1l2.6-3.6 C31.9,7.9,32.5,8.4,33,9z M38,21c0,0.7,0,1.4-0.1,2c-0.1,0.8-0.2,1.6-0.5,2.4c-0.1,0.2-0.1,0.4-0.2,0.6L33,24.6c0-0.1,0-0.1,0.1-0.2 c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0.1-0.5,0.2-1,0.3-1.6c0.1-0.4,0.1-0.9,0.1-1.3c0,0,0,0,0,0 c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.4,0-0.9-0.1-1.3 c-0.1-0.5-0.2-1-0.3-1.6c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.1,0-0.1-0.1-0.2l4.2-1.4 c0.1,0.2,0.1,0.4,0.2,0.6c0.2,0.8,0.4,1.6,0.5,2.4C38,19.6,38,20.3,38,21z'/%3E %3C/svg%3E\""

/***/ }),
/* 1494 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.8,22.2c0,0.7-0.2,1.3-0.6,1.7c-0.4,0.4-1,0.7-1.7,0.7c-0.7,0-1.3-0.3-1.7-0.8c-0.4-0.5-0.6-1.1-0.6-1.8 c0-1.9,0.7-3.3,2.1-4.4H16c-0.6,0.5-1,0.9-1.3,1.2c-0.4,0.5-0.7,0.9-0.9,1.4c0.2-0.2,0.5-0.2,0.8-0.2c0.7,0,1.2,0.2,1.6,0.7 C16.6,21,16.8,21.5,16.8,22.2z M15.4,22.2c0-0.3-0.1-0.5-0.3-0.7c-0.2-0.2-0.4-0.3-0.7-0.3c-0.3,0-0.5,0.1-0.6,0.3 c-0.2,0.2-0.2,0.4-0.2,0.7c0,0.3,0.1,0.5,0.3,0.7c0.2,0.2,0.4,0.3,0.6,0.3c0.3,0,0.5-0.1,0.6-0.3C15.3,22.7,15.4,22.4,15.4,22.2z M22.3,21c0,0.9-0.2,1.8-0.6,2.4c-0.5,0.8-1.1,1.2-2,1.2c-0.9,0-1.6-0.4-2-1.2c-0.4-0.6-0.6-1.4-0.6-2.4c0-0.9,0.2-1.8,0.6-2.4 c0.5-0.8,1.1-1.2,2-1.2c0.9,0,1.6,0.4,2,1.2C22.1,19.2,22.3,20,22.3,21z M20.9,21c0-0.5-0.1-1-0.2-1.4c-0.2-0.6-0.5-0.8-0.9-0.8 c-0.4,0-0.8,0.3-1,0.8c-0.1,0.4-0.2,0.8-0.2,1.4c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8C20.5,23.2,20.9,22.5,20.9,21z M26.5,20.5c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5c-0.4,0-0.7-0.2-1-0.5C24.1,21.3,24,21,24,20.5c0-0.4,0.1-0.8,0.3-1.1 c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5C26.4,19.7,26.5,20.1,26.5,20.5z M25.7,20.5c0-0.5-0.1-0.7-0.4-0.7 c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7C25.5,21.3,25.7,21,25.7,20.5z M28.7,19l-2.5,5.5h-1l2.5-5.5H28.7z M29.8,23 c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1 c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5C29.7,22.2,29.8,22.6,29.8,23z M29,23c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7 c0,0.5,0.1,0.7,0.4,0.7C28.8,23.8,29,23.5,29,23z M8.4,28.3c-1.3-2.2-2-4.7-2-7.3s0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3 c2.1-1.2,4.4-1.9,6.9-1.9V4c-2.9,0.1-5.7,0.8-8.2,2.3c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21c0,3.1,0.8,5.9,2.3,8.5 c1.2,2,2.7,3.7,4.5,5l1.4-2C10.6,31.4,9.4,30,8.4,28.3z M35.7,29.5c-0.5,0.9-1.1,1.7-1.8,2.5c0,0,0,0.1-0.1,0.1c0,0,0,0,0,0.1 c-0.3,0.3-0.5,0.6-0.8,0.9c-0.6,0.6-1.2,1.1-1.8,1.6L28.6,31c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0.1,0c0,0,0.1-0.1,0.1-0.1 c0.8-0.6,1.4-1.3,2-2.1c0.1-0.2,0.3-0.4,0.4-0.6c0,0,0,0,0,0c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1c0-0.1,0.1-0.1,0.1-0.2 c0,0,0-0.1,0.1-0.1c0,0,0.1-0.1,0.1-0.1c0,0,0.1-0.1,0.1-0.1c0,0,0-0.1,0.1-0.1c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1 c0-0.1,0.1-0.2,0.1-0.2c0,0,0,0,0,0c0.1-0.2,0.2-0.4,0.3-0.6c0.1-0.2,0.2-0.5,0.3-0.7l4.3,1.4c-0.1,0.4-0.3,0.8-0.4,1.1 C36.4,28.3,36.1,28.9,35.7,29.5z M27.5,36.7c0.7-0.3,1.4-0.6,2-1c0.4-0.2,0.8-0.5,1.2-0.8l-2.6-3.6c0,0-0.1,0-0.1,0.1c0,0,0,0,0,0 c-0.1,0-0.1,0.1-0.2,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.5,0.3-1,0.5-1.5,0.7 c-1,0.4-2.1,0.7-3.2,0.9c-0.5,0.1-0.9,0.1-1.4,0.1V38c0.4,0,0.7,0,1.1-0.1c1.5-0.1,3-0.5,4.4-1c0,0,0,0,0,0c0.1,0,0.1,0,0.2-0.1 c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0C27.4,36.8,27.4,36.8,27.5,36.7C27.5,36.7,27.5,36.7,27.5,36.7z M19.7,38c0.3,0,0.6,0,1,0v-4.5 c-0.4,0-0.8,0-1.3-0.1c0,0,0,0,0,0c0,0-0.1,0-0.1,0c-1.1-0.1-2.2-0.4-3.2-0.9c-0.5-0.2-1-0.5-1.5-0.7c0,0,0,0,0,0 c-0.2-0.1-0.3-0.2-0.5-0.3c0,0-0.1-0.1-0.1-0.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1l-2.6,3.6c0.4,0.3,0.8,0.5,1.2,0.8 c0.6,0.3,1.1,0.6,1.7,0.9c0,0,0,0,0,0c0.1,0,0.1,0.1,0.2,0.1c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0c0.1,0,0.1,0,0.2,0.1c0,0,0,0,0,0 c1.5,0.6,3.1,0.9,4.7,1.1C19.6,38,19.7,38,19.7,38C19.7,38,19.7,38,19.7,38z M22.3,4c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1 c0,0,0,0,0,0c0,0,0.1,0,0.1,0c1.1,0.1,2.2,0.4,3.2,0.9c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0 c0,0,0.1,0,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0c0,0,0.1,0,0.1,0.1l2.6-3.6c-0.4-0.3-0.8-0.5-1.2-0.8 c-0.6-0.3-1.1-0.6-1.7-0.9c0,0,0,0,0,0c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1-0.1c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0 c-1.5-0.6-3.1-0.9-4.7-1.1C22.4,4.1,22.3,4,22.3,4C22.3,4,22.3,4,22.3,4z M31.3,7.4L28.6,11c0.1,0,0.1,0.1,0.2,0.1 c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1c0.8,0.6,1.4,1.3,2,2.1c0.1,0.2,0.3,0.4,0.4,0.6c0,0,0,0,0,0c0,0.1,0.1,0.1,0.1,0.2 c0,0,0,0,0,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0.1,0.1,0.1 c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.2,0.1,0.2c0,0,0,0,0,0c0.1,0.2,0.2,0.4,0.3,0.6c0.1,0.2,0.2,0.5,0.3,0.7l4.3-1.4 c-0.1-0.4-0.3-0.8-0.4-1.1c-0.3-0.6-0.6-1.2-0.9-1.8c-0.5-0.9-1.1-1.7-1.8-2.5c0,0,0,0-0.1-0.1c0,0,0-0.1-0.1-0.1 C33.6,9.5,33.3,9.3,33,9C32.5,8.4,31.9,7.9,31.3,7.4z M37.9,19c-0.1-0.8-0.2-1.6-0.5-2.4c-0.1-0.2-0.1-0.4-0.2-0.6L33,17.4 c0,0.1,0,0.1,0.1,0.2c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0.1,0.5,0.2,1,0.3,1.6c0.1,0.4,0.1,0.9,0.1,1.3 c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0 c0,0.4,0,0.9-0.1,1.3c-0.1,0.5-0.2,1-0.3,1.6c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.1,0,0.1-0.1,0.2l4.2,1.4 c0.1-0.2,0.1-0.4,0.2-0.6c0.2-0.8,0.4-1.6,0.5-2.4c0.1-0.7,0.1-1.4,0.1-2C38,20.3,38,19.6,37.9,19z'/%3E %3C/svg%3E\""

/***/ }),
/* 1495 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.8,18.7c-0.7,0.9-1.2,1.8-1.5,2.7c-0.3,0.9-0.4,1.9-0.4,3.1h-1.5c0-1,0.1-2,0.4-3c0.3-1,0.8-1.9,1.4-2.7h-1.7v0.6h-1.2 v-1.9h4.5V18.7z M22.1,21c0,0.9-0.2,1.8-0.6,2.4c-0.5,0.8-1.1,1.2-2,1.2c-0.9,0-1.6-0.4-2-1.2c-0.4-0.6-0.6-1.4-0.6-2.4 c0-0.9,0.2-1.8,0.6-2.4c0.5-0.8,1.1-1.2,2-1.2c0.9,0,1.6,0.4,2,1.2C21.9,19.2,22.1,20,22.1,21z M20.7,21c0-0.5-0.1-1-0.2-1.4 c-0.2-0.6-0.5-0.8-0.9-0.8c-0.4,0-0.8,0.3-1,0.8c-0.1,0.4-0.2,0.8-0.2,1.4c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8 C20.3,23.2,20.7,22.5,20.7,21z M26.3,20.5c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5s-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1 c0-0.4,0.1-0.8,0.3-1.1c0.2-0.3,0.5-0.5,1-0.5s0.7,0.2,1,0.5C26.2,19.7,26.3,20.1,26.3,20.5z M25.5,20.5c0-0.5-0.1-0.7-0.4-0.7 c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7C25.4,21.3,25.5,21,25.5,20.5z M28.5,19L26,24.5h-1l2.5-5.5H28.5z M29.6,23 c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1 c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5C29.5,22.2,29.6,22.6,29.6,23z M28.8,23c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7 c0,0.5,0.1,0.7,0.4,0.7C28.7,23.8,28.8,23.5,28.8,23z M6.4,21c0-2.6,0.7-5.1,2-7.3c1.3-2.2,3.1-4,5.3-5.3c2.1-1.3,4.5-1.9,7-1.9V4 c-3,0-5.7,0.8-8.2,2.3c-2.6,1.5-4.7,3.6-6.2,6.2C4.8,15.1,4,17.9,4,21c0,1.7,0.2,3.3,0.7,4.9L7,25.2C6.7,23.8,6.4,22.5,6.4,21z M35.7,29.5c-0.5,0.9-1.1,1.7-1.8,2.5c0,0,0,0.1-0.1,0.1c0,0,0,0,0,0.1c-0.3,0.3-0.5,0.6-0.8,0.9c-0.6,0.6-1.2,1.1-1.8,1.6L28.6,31 c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0.1,0c0,0,0.1-0.1,0.1-0.1c0.8-0.6,1.4-1.3,2-2.1c0.1-0.2,0.3-0.4,0.4-0.6c0,0,0,0,0,0 c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1c0-0.1,0.1-0.1,0.1-0.2c0,0,0-0.1,0.1-0.1c0,0,0.1-0.1,0.1-0.1c0,0,0.1-0.1,0.1-0.1 c0,0,0-0.1,0.1-0.1c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1c0-0.1,0.1-0.2,0.1-0.2c0,0,0,0,0,0c0.1-0.2,0.2-0.4,0.3-0.6 c0.1-0.2,0.2-0.5,0.3-0.7l4.3,1.4c-0.1,0.4-0.3,0.8-0.4,1.1C36.4,28.3,36.1,28.9,35.7,29.5z M27.5,36.7c0.7-0.3,1.4-0.6,2-1 c0.4-0.2,0.8-0.5,1.2-0.8l-2.6-3.6c0,0-0.1,0-0.1,0.1c0,0,0,0,0,0c-0.1,0-0.1,0.1-0.2,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1 c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.5,0.3-1,0.5-1.5,0.7c-1,0.4-2.1,0.7-3.2,0.9c-0.5,0.1-0.9,0.1-1.4,0.1V38 c0.4,0,0.7,0,1.1-0.1c1.5-0.1,3-0.5,4.4-1c0,0,0,0,0,0c0.1,0,0.1,0,0.2-0.1c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0 C27.4,36.8,27.4,36.8,27.5,36.7C27.5,36.7,27.5,36.7,27.5,36.7z M19.7,38c0.3,0,0.6,0,1,0v-4.5c-0.4,0-0.8,0-1.3-0.1c0,0,0,0,0,0 c0,0-0.1,0-0.1,0c-1.1-0.1-2.2-0.4-3.2-0.9c-0.5-0.2-1-0.5-1.5-0.7c0,0,0,0,0,0c-0.2-0.1-0.3-0.2-0.5-0.3c0,0-0.1-0.1-0.1-0.1 c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1l-2.6,3.6c0.4,0.3,0.8,0.5,1.2,0.8c0.6,0.3,1.1,0.6,1.7,0.9c0,0,0,0,0,0c0.1,0,0.1,0.1,0.2,0.1 c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0c0.1,0,0.1,0,0.2,0.1c0,0,0,0,0,0c1.5,0.6,3.1,0.9,4.7,1.1C19.6,38,19.7,38,19.7,38 C19.7,38,19.7,38,19.7,38z M10.8,34.6l2.6-3.6c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.8-0.6-1.4-1.3-2-2.1 c-0.1-0.2-0.3-0.4-0.4-0.6c0,0,0,0,0,0c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1 c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.2-0.1-0.2 c0,0,0,0,0,0c-0.1-0.2-0.2-0.4-0.3-0.6c-0.1-0.2-0.2-0.5-0.3-0.7l-4.3,1.4c0.1,0.4,0.3,0.8,0.4,1.1c0.3,0.6,0.6,1.2,0.9,1.8 c0.5,0.9,1.1,1.7,1.8,2.5c0,0,0,0,0.1,0.1c0,0,0,0.1,0.1,0.1C8.4,32.5,8.7,32.8,9,33C9.5,33.6,10.1,34.1,10.8,34.6z M22.3,4 c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1c0,0,0,0,0,0c0,0,0.1,0,0.1,0c1.1,0.1,2.2,0.4,3.2,0.9c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0 c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0c0,0,0.1,0,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0c0,0,0.1,0,0.1,0.1l2.6-3.6 c-0.4-0.3-0.8-0.5-1.2-0.8c-0.6-0.3-1.1-0.6-1.7-0.9c0,0,0,0,0,0c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1-0.1 c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0c-1.5-0.6-3.1-0.9-4.7-1.1C22.4,4.1,22.3,4,22.3,4C22.3,4,22.3,4,22.3,4z M31.3,7.4L28.6,11 c0.1,0,0.1,0.1,0.2,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1c0.8,0.6,1.4,1.3,2,2.1c0.1,0.2,0.3,0.4,0.4,0.6c0,0,0,0,0,0 c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1 c0,0,0,0.1,0.1,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.2,0.1,0.2c0,0,0,0,0,0c0.1,0.2,0.2,0.4,0.3,0.6 c0.1,0.2,0.2,0.5,0.3,0.7l4.3-1.4c-0.1-0.4-0.3-0.8-0.4-1.1c-0.3-0.6-0.6-1.2-0.9-1.8c-0.5-0.9-1.1-1.7-1.8-2.5c0,0,0,0-0.1-0.1 c0,0,0-0.1-0.1-0.1C33.6,9.5,33.3,9.3,33,9C32.5,8.4,31.9,7.9,31.3,7.4z M37.9,19c-0.1-0.8-0.2-1.6-0.5-2.4 c-0.1-0.2-0.1-0.4-0.2-0.6L33,17.4c0,0.1,0,0.1,0.1,0.2c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0 c0.1,0.5,0.2,1,0.3,1.6c0.1,0.4,0.1,0.9,0.1,1.3c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1 c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.4,0,0.9-0.1,1.3c-0.1,0.5-0.2,1-0.3,1.6c0,0,0,0,0,0c0,0,0,0.1,0,0.1 c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.1,0,0.1-0.1,0.2l4.2,1.4c0.1-0.2,0.1-0.4,0.2-0.6c0.2-0.8,0.4-1.6,0.5-2.4c0.1-0.7,0.1-1.4,0.1-2 C38,20.3,38,19.6,37.9,19z'/%3E %3C/svg%3E\""

/***/ }),
/* 1496 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.8,22.3c0,0.7-0.2,1.2-0.7,1.7c-0.5,0.4-1,0.6-1.7,0.6c-0.7,0-1.3-0.2-1.7-0.6c-0.4-0.4-0.7-1-0.7-1.7 c0-0.7,0.3-1.2,1-1.7c-0.2-0.1-0.4-0.3-0.5-0.6c-0.1-0.3-0.2-0.5-0.2-0.7c0-0.6,0.2-1,0.6-1.4c0.4-0.4,0.9-0.6,1.5-0.6 c0.6,0,1.1,0.2,1.5,0.6c0.4,0.4,0.6,0.8,0.6,1.4c0,0.2-0.1,0.5-0.2,0.7c-0.1,0.2-0.3,0.4-0.5,0.6C16.5,21.1,16.8,21.6,16.8,22.3z M15.4,22.3c0-0.3-0.1-0.5-0.3-0.7c-0.2-0.2-0.4-0.3-0.7-0.3c-0.3,0-0.5,0.1-0.7,0.3c-0.2,0.2-0.3,0.4-0.3,0.7 c0,0.3,0.1,0.5,0.3,0.7c0.2,0.2,0.4,0.3,0.7,0.3c0.3,0,0.5-0.1,0.7-0.3C15.3,22.7,15.4,22.5,15.4,22.3z M15.2,19.4 c0-0.2-0.1-0.4-0.2-0.5c-0.1-0.1-0.3-0.2-0.5-0.2c-0.2,0-0.4,0.1-0.5,0.2c-0.1,0.1-0.2,0.3-0.2,0.5c0,0.2,0.1,0.4,0.2,0.5 c0.1,0.1,0.3,0.2,0.5,0.2c0.2,0,0.4-0.1,0.5-0.2C15.1,19.8,15.2,19.6,15.2,19.4z M22.4,21c0,0.9-0.2,1.8-0.6,2.4 c-0.5,0.8-1.1,1.2-2,1.2c-0.9,0-1.6-0.4-2-1.2c-0.4-0.6-0.6-1.4-0.6-2.4c0-0.9,0.2-1.8,0.6-2.4c0.5-0.8,1.1-1.2,2-1.2 c0.9,0,1.6,0.4,2,1.2C22.2,19.2,22.4,20,22.4,21z M21,21c0-0.5-0.1-1-0.2-1.4c-0.2-0.6-0.5-0.8-0.9-0.8c-0.4,0-0.8,0.3-1,0.8 c-0.1,0.4-0.2,0.8-0.2,1.4c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8C20.6,23.2,21,22.5,21,21z M26.6,20.5c0,0.4-0.1,0.8-0.3,1.1 c-0.2,0.3-0.5,0.5-1,0.5s-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1c0.2-0.3,0.5-0.5,1-0.5s0.7,0.2,1,0.5 C26.5,19.7,26.6,20.1,26.6,20.5z M25.8,20.5c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7 C25.7,21.3,25.8,21,25.8,20.5z M28.8,19l-2.5,5.5h-1l2.5-5.5H28.8z M29.9,23c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5 c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5 C29.8,22.2,29.9,22.6,29.9,23z M29.1,23c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7 C29,23.7,29.1,23.5,29.1,23z M35.7,29.5c-0.5,0.9-1.1,1.7-1.8,2.5c0,0,0,0.1-0.1,0.1c0,0,0,0,0,0.1c-0.3,0.3-0.5,0.6-0.8,0.9 c-0.6,0.6-1.2,1.1-1.8,1.6L28.6,31c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0.1,0c0,0,0.1-0.1,0.1-0.1c0.8-0.6,1.4-1.3,2-2.1 c0.1-0.2,0.3-0.4,0.4-0.6c0,0,0,0,0,0c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1c0-0.1,0.1-0.1,0.1-0.2c0,0,0-0.1,0.1-0.1 c0,0,0.1-0.1,0.1-0.1c0,0,0.1-0.1,0.1-0.1c0,0,0-0.1,0.1-0.1c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1c0-0.1,0.1-0.2,0.1-0.2 c0,0,0,0,0,0c0.1-0.2,0.2-0.4,0.3-0.6c0.1-0.2,0.2-0.5,0.3-0.7l4.3,1.4c-0.1,0.4-0.3,0.8-0.4,1.1C36.4,28.3,36.1,28.9,35.7,29.5z M27.5,36.7c0.7-0.3,1.4-0.6,2-1c0.4-0.2,0.8-0.5,1.2-0.8l-2.6-3.6c0,0-0.1,0-0.1,0.1c0,0,0,0,0,0c-0.1,0-0.1,0.1-0.2,0.1 c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.5,0.3-1,0.5-1.5,0.7c-1,0.4-2.1,0.7-3.2,0.9 c-0.5,0.1-0.9,0.1-1.4,0.1V38c0.4,0,0.7,0,1.1-0.1c1.5-0.1,3-0.5,4.4-1c0,0,0,0,0,0c0.1,0,0.1,0,0.2-0.1c0,0,0.1,0,0.1,0 c0,0,0.1,0,0.1,0C27.4,36.8,27.4,36.8,27.5,36.7C27.5,36.7,27.5,36.7,27.5,36.7z M19.7,38c0.3,0,0.6,0,1,0v-4.5 c-0.4,0-0.8,0-1.3-0.1c0,0,0,0,0,0c0,0-0.1,0-0.1,0c-1.1-0.1-2.2-0.4-3.2-0.9c-0.5-0.2-1-0.5-1.5-0.7c0,0,0,0,0,0 c-0.2-0.1-0.3-0.2-0.5-0.3c0,0-0.1-0.1-0.1-0.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1l-2.6,3.6c0.4,0.3,0.8,0.5,1.2,0.8 c0.6,0.3,1.1,0.6,1.7,0.9c0,0,0,0,0,0c0.1,0,0.1,0.1,0.2,0.1c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0c0.1,0,0.1,0,0.2,0.1c0,0,0,0,0,0 c1.5,0.6,3.1,0.9,4.7,1.1C19.6,38,19.7,38,19.7,38C19.7,38,19.7,38,19.7,38z M10.8,34.6l2.6-3.6c-0.1,0-0.1-0.1-0.2-0.1 c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.8-0.6-1.4-1.3-2-2.1c-0.1-0.2-0.3-0.4-0.4-0.6c0,0,0,0,0,0c0-0.1-0.1-0.1-0.1-0.2 c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1 c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.2-0.1-0.2c0,0,0,0,0,0c-0.1-0.2-0.2-0.4-0.3-0.6c-0.1-0.2-0.2-0.5-0.3-0.7 l-4.3,1.4c0.1,0.4,0.3,0.8,0.4,1.1c0.3,0.6,0.6,1.2,0.9,1.8c0.5,0.9,1.1,1.7,1.8,2.5c0,0,0,0,0.1,0.1c0,0,0,0.1,0.1,0.1 C8.4,32.5,8.7,32.8,9,33C9.5,33.6,10.1,34.1,10.8,34.6z M22.3,4c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1c0,0,0,0,0,0 c0,0,0.1,0,0.1,0c1.1,0.1,2.2,0.4,3.2,0.9c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0 c0,0,0.1,0,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0c0,0,0.1,0,0.1,0.1l2.6-3.6c-0.4-0.3-0.8-0.5-1.2-0.8 c-0.6-0.3-1.1-0.6-1.7-0.9c0,0,0,0,0,0c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1-0.1c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0 c-1.5-0.6-3.1-0.9-4.7-1.1C22.4,4.1,22.3,4,22.3,4C22.3,4,22.3,4,22.3,4z M31.3,7.4L28.6,11c0.1,0,0.1,0.1,0.2,0.1 c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1c0.8,0.6,1.4,1.3,2,2.1c0.1,0.2,0.3,0.4,0.4,0.6c0,0,0,0,0,0c0,0.1,0.1,0.1,0.1,0.2 c0,0,0,0,0,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0.1,0.1,0.1 c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.2,0.1,0.2c0,0,0,0,0,0c0.1,0.2,0.2,0.4,0.3,0.6c0.1,0.2,0.2,0.5,0.3,0.7l4.3-1.4 c-0.1-0.4-0.3-0.8-0.4-1.1c-0.3-0.6-0.6-1.2-0.9-1.8c-0.5-0.9-1.1-1.7-1.8-2.5c0,0,0,0-0.1-0.1c0,0,0-0.1-0.1-0.1 C33.6,9.5,33.3,9.3,33,9C32.5,8.4,31.9,7.9,31.3,7.4z M37.9,19c-0.1-0.8-0.2-1.6-0.5-2.4c-0.1-0.2-0.1-0.4-0.2-0.6L33,17.4 c0,0.1,0,0.1,0.1,0.2c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0.1,0.5,0.2,1,0.3,1.6c0.1,0.4,0.1,0.9,0.1,1.3 c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0 c0,0.4,0,0.9-0.1,1.3c-0.1,0.5-0.2,1-0.3,1.6c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.1,0,0.1-0.1,0.2l4.2,1.4 c0.1-0.2,0.1-0.4,0.2-0.6c0.2-0.8,0.4-1.6,0.5-2.4c0.1-0.7,0.1-1.4,0.1-2C38,20.3,38,19.6,37.9,19z M9,17.4L4.7,16 c-0.1,0.2-0.1,0.4-0.2,0.6c-0.2,0.8-0.4,1.6-0.5,2.4C4,19.6,4,20.3,4,21c0,0.7,0,1.4,0.1,2c0.1,0.8,0.2,1.6,0.5,2.4 c0.1,0.2,0.1,0.4,0.2,0.6L9,24.6c0-0.1,0-0.1-0.1-0.2c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0 c-0.1-0.5-0.2-1-0.3-1.6c-0.1-0.4-0.1-0.9-0.1-1.3c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1 c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.4,0-0.9,0.1-1.3c0.1-0.5,0.2-1,0.3-1.6c0,0,0,0,0,0c0,0,0-0.1,0-0.1 c0,0,0-0.1,0-0.1c0,0,0,0,0,0C9,17.6,9,17.5,9,17.4z M8.4,13.7c1.3-2.2,3.1-4,5.3-5.3c2.1-1.2,4.5-1.9,7-1.9l0-2.4 c-2.9,0.1-5.7,0.8-8.2,2.3c-2.6,1.5-4.7,3.6-6.2,6.2c-0.5,0.9-1,1.8-1.3,2.8l2.3,0.9C7.6,15.3,7.9,14.5,8.4,13.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 1497 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M12.7,9.1l-1.4-2c0.4-0.3,0.8-0.5,1.2-0.8C15,4.8,17.7,4.1,20.6,4l0.1,2.4c-2.5,0.1-4.8,0.7-7,1.9C13.3,8.6,13,8.8,12.7,9.1 z M16.3,18.2c-0.4-0.5-1-0.8-1.7-0.8c-0.7,0-1.3,0.2-1.7,0.7c-0.4,0.5-0.6,1-0.6,1.8c0,0.7,0.2,1.2,0.6,1.6c0.4,0.4,0.9,0.6,1.6,0.6 c0.3,0,0.6-0.1,0.8-0.2c-0.2,0.5-0.5,1-0.9,1.4c-0.3,0.3-0.7,0.7-1.3,1.1h1.8c1.3-1,2-2.5,2-4.4C16.9,19.4,16.7,18.7,16.3,18.2z M15.1,20.5c-0.2,0.2-0.4,0.3-0.7,0.3c-0.3,0-0.5-0.1-0.7-0.3c-0.2-0.2-0.3-0.4-0.3-0.7c0-0.3,0.1-0.5,0.3-0.7 c0.2-0.2,0.4-0.3,0.6-0.3c0.3,0,0.5,0.1,0.6,0.3c0.2,0.2,0.3,0.4,0.3,0.7C15.4,20,15.3,20.3,15.1,20.5z M21.7,18.6 c-0.5-0.8-1.1-1.2-2-1.2c-0.9,0-1.6,0.4-2,1.2c-0.4,0.7-0.6,1.5-0.6,2.4c0,0.9,0.2,1.7,0.6,2.4c0.5,0.8,1.1,1.2,2,1.2 c0.9,0,1.6-0.4,2-1.2c0.4-0.7,0.6-1.5,0.6-2.4C22.3,20,22.1,19.2,21.7,18.6z M19.7,23.2c-0.4,0-0.8-0.3-1-0.8 c-0.1-0.4-0.2-0.8-0.2-1.4c0-0.6,0.1-1,0.2-1.4c0.2-0.5,0.5-0.8,1-0.8c0.4,0,0.7,0.3,0.9,0.8c0.1,0.4,0.2,0.8,0.2,1.4 C20.8,22.5,20.5,23.2,19.7,23.2z M26.2,19.4c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1 c0,0.4,0.1,0.8,0.3,1.1c0.2,0.3,0.5,0.5,1,0.5c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1C26.5,20.1,26.4,19.7,26.2,19.4z M25.3,21.3c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7C25.7,21,25.5,21.3,25.3,21.3z M27.6,19l-2.5,5.5h1 l2.5-5.5H27.6z M29.5,21.9c-0.2-0.3-0.5-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.5c-0.2,0.3-0.3,0.6-0.3,1.1c0,0.4,0.1,0.8,0.3,1.1 c0.2,0.3,0.5,0.5,1,0.5c0.4,0,0.7-0.2,1-0.5c0.2-0.3,0.3-0.6,0.3-1.1C29.8,22.6,29.7,22.2,29.5,21.9z M28.6,23.8 c-0.3,0-0.4-0.2-0.4-0.7c0-0.5,0.1-0.7,0.4-0.7c0.3,0,0.4,0.2,0.4,0.7C29,23.5,28.8,23.8,28.6,23.8z M36.7,27.7 c0.2-0.4,0.3-0.7,0.4-1.1l-4.3-1.4c-0.1,0.2-0.2,0.5-0.3,0.7c-0.1,0.2-0.2,0.4-0.3,0.6c0,0,0,0,0,0c0,0.1-0.1,0.2-0.1,0.2 c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.1 c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0c-0.1,0.2-0.3,0.4-0.4,0.6c-0.6,0.8-1.3,1.5-2,2.1 c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1l2.6,3.6c0.6-0.5,1.2-1,1.8-1.6c0.3-0.3,0.6-0.6,0.8-0.9c0,0,0,0,0-0.1 c0,0,0-0.1,0.1-0.1c0.7-0.8,1.3-1.6,1.8-2.5C36.1,28.9,36.4,28.3,36.7,27.7z M27.5,36.7c-0.1,0-0.1,0.1-0.2,0.1c0,0-0.1,0-0.1,0 c0,0-0.1,0-0.1,0c-0.1,0-0.1,0-0.2,0.1c0,0,0,0,0,0c-1.4,0.5-2.9,0.9-4.4,1c-0.4,0-0.7,0-1.1,0.1v-4.5c0.5,0,0.9,0,1.4-0.1 c1.1-0.1,2.2-0.4,3.2-0.9c0.5-0.2,1-0.5,1.5-0.7c0,0,0,0,0.1,0c0,0,0.1-0.1,0.1-0.1c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0.1,0 c0.1,0,0.1-0.1,0.2-0.1c0,0,0,0,0,0c0,0,0.1,0,0.1-0.1l2.6,3.6c-0.4,0.3-0.8,0.5-1.2,0.8C28.9,36.1,28.2,36.4,27.5,36.7 C27.5,36.7,27.5,36.7,27.5,36.7z M19.7,38c0,0-0.1,0-0.1,0c-1.6-0.1-3.2-0.5-4.7-1.1c0,0,0,0,0,0c-0.1,0-0.1,0-0.2-0.1 c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1,0c-0.1,0-0.1-0.1-0.2-0.1c0,0,0,0,0,0c-0.6-0.3-1.2-0.5-1.7-0.9c-0.4-0.2-0.8-0.5-1.2-0.8l2.6-3.6 c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0.2,0.1,0.3,0.2,0.5,0.3c0,0,0,0,0,0c0.5,0.3,1,0.5,1.5,0.7 c1,0.4,2.1,0.7,3.2,0.9c0,0,0.1,0,0.1,0c0,0,0,0,0,0c0.4,0.1,0.8,0.1,1.3,0.1V38C20.4,38,20.1,38,19.7,38C19.7,38,19.7,38,19.7,38z M9,33c-0.3-0.3-0.5-0.6-0.8-0.9c0,0,0-0.1-0.1-0.1c0,0,0,0-0.1-0.1c-0.7-0.8-1.3-1.6-1.8-2.5c-0.3-0.6-0.6-1.2-0.9-1.8 c-0.2-0.4-0.3-0.7-0.4-1.1l4.3-1.4c0.1,0.2,0.2,0.5,0.3,0.7c0.1,0.2,0.2,0.4,0.3,0.6c0,0,0,0,0,0c0,0.1,0.1,0.2,0.1,0.2 c0,0,0,0,0,0.1C9.9,26.9,10,27,10,27c0,0,0,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0.1,0.1,0.1 c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0c0.1,0.2,0.3,0.4,0.4,0.6c0.6,0.8,1.3,1.5,2,2.1 c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1c0.1,0,0.1,0.1,0.2,0.1l-2.6,3.6C10.1,34.1,9.5,33.6,9,33z M6.3,12.5C6.8,11.6,7.4,10.8,8,10 c0,0,0-0.1,0.1-0.1c0,0,0,0,0.1-0.1C8.4,9.5,8.7,9.3,9,9c0.6-0.6,1.2-1.1,1.8-1.6l2.6,3.6c-0.1,0-0.1,0.1-0.2,0.1c0,0,0,0-0.1,0.1 c0,0-0.1,0.1-0.1,0.1c-0.8,0.6-1.4,1.3-2,2.1c-0.1,0.2-0.3,0.4-0.4,0.6c0,0,0,0,0,0c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0.1 c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.1c0,0.1-0.1,0.1-0.1,0.2 c0,0,0,0,0,0.1c0,0.1-0.1,0.2-0.1,0.2c0,0,0,0,0,0c-0.1,0.2-0.2,0.4-0.3,0.6c-0.1,0.2-0.2,0.5-0.3,0.7l-4.3-1.4 c0.1-0.4,0.3-0.8,0.4-1.1C5.6,13.7,5.9,13.1,6.3,12.5z M22.3,4c0,0,0.1,0,0.1,0c1.6,0.1,3.2,0.5,4.7,1.1c0,0,0,0,0,0 c0.1,0,0.1,0,0.2,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0c0.1,0,0.1,0.1,0.2,0.1c0,0,0,0,0,0c0.6,0.3,1.2,0.6,1.7,0.9 c0.4,0.2,0.8,0.5,1.2,0.8l-2.6,3.6c0,0-0.1,0-0.1-0.1c0,0,0,0-0.1,0c0,0-0.1-0.1-0.1-0.1c0,0-0.1,0-0.1-0.1c0,0,0,0,0,0 c-0.1-0.1-0.2-0.1-0.3-0.2c0,0,0,0,0,0c-0.5-0.3-1-0.5-1.5-0.7c-1-0.4-2.1-0.7-3.2-0.9c0,0-0.1,0-0.1,0c0,0,0,0,0,0 c-0.4-0.1-0.8-0.1-1.3-0.1V4C21.6,4,22,4,22.3,4C22.3,4,22.3,4,22.3,4z M33,9c0.3,0.3,0.5,0.6,0.8,0.9c0,0,0,0.1,0.1,0.1 c0,0,0,0,0.1,0.1c0.7,0.8,1.3,1.6,1.8,2.5c0.3,0.6,0.6,1.2,0.9,1.8c0.2,0.4,0.3,0.7,0.4,1.1l-4.3,1.4c-0.1-0.2-0.2-0.5-0.3-0.7 c-0.1-0.2-0.2-0.4-0.3-0.6c0,0,0,0,0,0c0-0.1-0.1-0.2-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1 c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2 c0,0,0,0,0,0c-0.1-0.2-0.3-0.4-0.4-0.6c-0.6-0.8-1.3-1.5-2-2.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.1,0-0.1-0.1-0.2-0.1l2.6-3.6 C31.9,7.9,32.5,8.4,33,9z M38,21c0,0.7,0,1.4-0.1,2c-0.1,0.8-0.2,1.6-0.5,2.4c-0.1,0.2-0.1,0.4-0.2,0.6L33,24.6c0-0.1,0-0.1,0.1-0.2 c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0.1-0.5,0.2-1,0.3-1.6c0.1-0.4,0.1-0.9,0.1-1.3c0,0,0,0,0,0 c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.4,0-0.9-0.1-1.3 c-0.1-0.5-0.2-1-0.3-1.6c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.1,0-0.1-0.1-0.2l4.2-1.4 c0.1,0.2,0.1,0.4,0.2,0.6c0.2,0.8,0.4,1.6,0.5,2.4C38,19.6,38,20.3,38,21z M8.9,17.6C8.9,17.6,8.9,17.6,8.9,17.6c0,0.1,0,0.1,0,0.1 c0,0,0,0.1,0,0.1c0,0,0,0,0,0c-0.1,0.5-0.2,1-0.3,1.6c-0.1,0.4-0.1,0.9-0.1,1.3c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1 c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.4,0,0.9,0.1,1.3c0.1,0.5,0.2,1,0.3,1.6 c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.1,0,0.1,0.1,0.2L4.7,26c-0.1-0.2-0.1-0.4-0.2-0.6 c-0.2-0.8-0.4-1.6-0.5-2.4C4,22.4,4,21.7,4,21c0-0.7,0-1.4,0.1-2c0.1-0.8,0.2-1.6,0.5-2.4c0.1-0.2,0.1-0.4,0.2-0.6L9,17.4 C9,17.5,9,17.6,8.9,17.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1498 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M13.3,24.5h-1.4v-5.2L11,19.8l-0.6-1.1l1.9-1.2h1V24.5z M19.2,21c0,0.9-0.2,1.8-0.6,2.4c-0.5,0.8-1.1,1.2-2,1.2 c-0.9,0-1.6-0.4-2-1.2C14.2,22.8,14,22,14,21c0-0.9,0.2-1.8,0.6-2.4c0.5-0.8,1.1-1.2,2-1.2c0.9,0,1.6,0.4,2,1.2 C19,19.2,19.2,20,19.2,21z M17.8,21c0-0.5-0.1-1-0.2-1.4c-0.2-0.6-0.5-0.8-0.9-0.8c-0.4,0-0.8,0.3-1,0.8c-0.1,0.4-0.2,0.8-0.2,1.4 c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8C17.4,23.2,17.8,22.5,17.8,21z M24.6,21c0,0.9-0.2,1.8-0.6,2.4c-0.5,0.8-1.1,1.2-2,1.2 c-0.9,0-1.6-0.4-2-1.2c-0.4-0.6-0.6-1.4-0.6-2.4c0-0.9,0.2-1.8,0.6-2.4c0.5-0.8,1.1-1.2,2-1.2c0.9,0,1.6,0.4,2,1.2 C24.4,19.2,24.6,20,24.6,21z M23.2,21c0-0.5-0.1-1-0.2-1.4c-0.2-0.6-0.5-0.8-0.9-0.8c-0.4,0-0.8,0.3-1,0.8C21,20,20.9,20.5,20.9,21 c0,0.5,0.1,1,0.2,1.4c0.2,0.5,0.5,0.8,1,0.8C22.8,23.2,23.2,22.5,23.2,21z M28.3,20.5c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5 c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5 C28.2,19.7,28.3,20.1,28.3,20.5z M27.5,20.5c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7 C27.4,21.3,27.5,21,27.5,20.5z M30.5,19L28,24.5h-1l2.5-5.5H30.5z M31.6,23c0,0.4-0.1,0.8-0.3,1.1c-0.2,0.3-0.5,0.5-1,0.5 c-0.4,0-0.7-0.2-1-0.5c-0.2-0.3-0.3-0.6-0.3-1.1c0-0.4,0.1-0.8,0.3-1.1c0.2-0.3,0.5-0.5,1-0.5c0.4,0,0.7,0.2,1,0.5 C31.5,22.2,31.6,22.6,31.6,23z M30.8,23c0-0.5-0.1-0.7-0.4-0.7c-0.3,0-0.4,0.2-0.4,0.7c0,0.5,0.1,0.7,0.4,0.7 C30.7,23.8,30.8,23.5,30.8,23z M36.7,27.7c0.2-0.4,0.3-0.7,0.4-1.1l-4.3-1.4c-0.1,0.2-0.2,0.5-0.3,0.7c-0.1,0.2-0.2,0.4-0.3,0.6 c0,0,0,0,0,0c0,0.1-0.1,0.2-0.1,0.2c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0.1-0.1,0.1c0,0-0.1,0.1-0.1,0.1 c0,0-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0.1c0,0.1-0.1,0.1-0.1,0.2c0,0,0,0,0,0 c-0.1,0.2-0.3,0.4-0.4,0.6c-0.6,0.8-1.3,1.5-2,2.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1l2.6,3.6 c0.6-0.5,1.2-1,1.8-1.6c0.3-0.3,0.6-0.6,0.8-0.9c0,0,0,0,0-0.1c0,0,0-0.1,0.1-0.1c0.7-0.8,1.3-1.6,1.8-2.5 C36.1,28.9,36.4,28.3,36.7,27.7z M27.5,36.7c0.7-0.3,1.4-0.6,2-1c0.4-0.2,0.8-0.5,1.2-0.8l-2.6-3.6c0,0-0.1,0-0.1,0.1c0,0,0,0,0,0 c-0.1,0-0.1,0.1-0.2,0.1c0,0,0,0-0.1,0c-0.1,0-0.1,0.1-0.2,0.1c0,0-0.1,0.1-0.1,0.1c0,0,0,0-0.1,0c-0.5,0.3-1,0.5-1.5,0.7 c-1,0.4-2.1,0.7-3.2,0.9c-0.5,0.1-0.9,0.1-1.4,0.1V38c0.4,0,0.7,0,1.1-0.1c1.5-0.1,3-0.5,4.4-1c0,0,0,0,0,0c0.1,0,0.1,0,0.2-0.1 c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0C27.4,36.8,27.4,36.8,27.5,36.7C27.5,36.7,27.5,36.7,27.5,36.7z M19.7,38c0.3,0,0.6,0,1,0v-4.5 c-0.4,0-0.8,0-1.3-0.1c0,0,0,0,0,0c0,0-0.1,0-0.1,0c-1.1-0.1-2.2-0.4-3.2-0.9c-0.5-0.2-1-0.5-1.5-0.7c0,0,0,0,0,0 c-0.2-0.1-0.3-0.2-0.5-0.3c0,0-0.1-0.1-0.1-0.1c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1l-2.6,3.6c0.4,0.3,0.8,0.5,1.2,0.8 c0.6,0.3,1.1,0.6,1.7,0.9c0,0,0,0,0,0c0.1,0,0.1,0.1,0.2,0.1c0,0,0.1,0,0.1,0c0,0,0.1,0,0.1,0c0.1,0,0.1,0,0.2,0.1c0,0,0,0,0,0 c1.5,0.6,3.1,0.9,4.7,1.1C19.6,38,19.7,38,19.7,38C19.7,38,19.7,38,19.7,38z M10.8,34.6l2.6-3.6c-0.1,0-0.1-0.1-0.2-0.1 c0,0-0.1,0-0.1-0.1c0,0-0.1,0-0.1-0.1c-0.8-0.6-1.4-1.3-2-2.1c-0.1-0.2-0.3-0.4-0.4-0.6c0,0,0,0,0,0c0-0.1-0.1-0.1-0.1-0.2 c0,0,0,0,0-0.1c0-0.1-0.1-0.1-0.1-0.2c0,0,0-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0-0.1-0.1-0.1-0.1c0,0,0-0.1-0.1-0.1 c0-0.1-0.1-0.1-0.1-0.2c0,0,0,0,0-0.1c0-0.1-0.1-0.2-0.1-0.2c0,0,0,0,0,0c-0.1-0.2-0.2-0.4-0.3-0.6c-0.1-0.2-0.2-0.5-0.3-0.7 l-4.3,1.4c0.1,0.4,0.3,0.8,0.4,1.1c0.3,0.6,0.6,1.2,0.9,1.8c0.5,0.9,1.1,1.7,1.8,2.5c0,0,0,0,0.1,0.1c0,0,0,0.1,0.1,0.1 C8.4,32.5,8.7,32.8,9,33C9.5,33.6,10.1,34.1,10.8,34.6z M5.4,14.3c-0.2,0.4-0.3,0.7-0.4,1.1l4.3,1.4c0.1-0.2,0.2-0.5,0.3-0.7 c0.1-0.2,0.2-0.4,0.3-0.6c0,0,0,0,0,0c0-0.1,0.1-0.2,0.1-0.2c0,0,0,0,0-0.1C9.9,15.1,10,15,10,15c0,0,0-0.1,0.1-0.1 c0,0,0.1-0.1,0.1-0.1c0,0,0.1-0.1,0.1-0.1c0,0,0-0.1,0.1-0.1c0-0.1,0.1-0.1,0.1-0.2c0,0,0,0,0-0.1c0-0.1,0.1-0.1,0.1-0.2 c0,0,0,0,0,0c0.1-0.2,0.3-0.4,0.4-0.6c0.6-0.8,1.3-1.5,2-2.1c0,0,0.1-0.1,0.1-0.1c0,0,0,0,0.1-0.1c0.1,0,0.1-0.1,0.2-0.1l-2.6-3.6 C10.1,7.9,9.5,8.4,9,9C8.7,9.3,8.4,9.5,8.2,9.8c0,0,0,0-0.1,0.1c0,0,0,0.1-0.1,0.1c-0.7,0.8-1.3,1.6-1.8,2.5 C5.9,13.1,5.6,13.7,5.4,14.3z M14.5,5.3c-0.7,0.3-1.3,0.6-2,1c-0.4,0.2-0.8,0.5-1.2,0.8l2.6,3.6c0,0,0.1,0,0.1-0.1c0,0,0,0,0,0 c0.1,0,0.1-0.1,0.2-0.1c0,0,0.1,0,0.1,0c0.1,0,0.1-0.1,0.2-0.1c0,0,0.1-0.1,0.1-0.1c0,0,0,0,0,0c0.5-0.3,1-0.5,1.5-0.7 c1-0.4,2.1-0.7,3.2-0.9c0,0,0.1,0,0.1,0c0,0,0,0,0,0c0.4-0.1,0.8-0.1,1.3-0.1V4c-0.3,0-0.6,0-1,0c0,0,0,0,0,0c0,0-0.1,0-0.1,0 c-1.5,0.1-3,0.5-4.5,1c0,0,0,0,0,0c-0.1,0-0.1,0.1-0.2,0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1,0C14.6,5.2,14.6,5.3,14.5,5.3 C14.5,5.3,14.5,5.3,14.5,5.3z M22.3,4c-0.3,0-0.6,0-1,0v4.5c0.4,0,0.8,0,1.3,0.1c0,0,0,0,0,0c0,0,0.1,0,0.1,0 c1.1,0.1,2.2,0.4,3.2,0.9c0.5,0.2,1,0.5,1.5,0.7c0,0,0,0,0,0c0.1,0.1,0.2,0.1,0.3,0.2c0,0,0,0,0,0c0,0,0.1,0,0.1,0.1 c0,0,0.1,0.1,0.1,0.1c0,0,0,0,0.1,0c0,0,0.1,0,0.1,0.1l2.6-3.6c-0.4-0.3-0.8-0.5-1.2-0.8c-0.6-0.3-1.1-0.6-1.7-0.9c0,0,0,0,0,0 c-0.1,0-0.1-0.1-0.2-0.1c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1-0.1c-0.1,0-0.1,0-0.2-0.1c0,0,0,0,0,0c-1.5-0.6-3.1-0.9-4.7-1.1 C22.4,4.1,22.3,4,22.3,4C22.3,4,22.3,4,22.3,4z M31.3,7.4L28.6,11c0.1,0,0.1,0.1,0.2,0.1c0,0,0.1,0,0.1,0.1c0,0,0.1,0,0.1,0.1 c0.8,0.6,1.4,1.3,2,2.1c0.1,0.2,0.3,0.4,0.4,0.6c0,0,0,0,0,0c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1c0,0.1,0.1,0.1,0.1,0.2 c0,0,0,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0.1,0.1,0.1,0.1c0,0,0,0.1,0.1,0.1c0,0.1,0.1,0.1,0.1,0.2c0,0,0,0,0,0.1 c0,0.1,0.1,0.2,0.1,0.2c0,0,0,0,0,0c0.1,0.2,0.2,0.4,0.3,0.6c0.1,0.2,0.2,0.5,0.3,0.7l4.3-1.4c-0.1-0.4-0.3-0.8-0.4-1.1 c-0.3-0.6-0.6-1.2-0.9-1.8c-0.5-0.9-1.1-1.7-1.8-2.5c0,0,0,0-0.1-0.1c0,0,0-0.1-0.1-0.1C33.6,9.5,33.3,9.3,33,9 C32.5,8.4,31.9,7.9,31.3,7.4z M37.9,19c-0.1-0.8-0.2-1.6-0.5-2.4c-0.1-0.2-0.1-0.4-0.2-0.6L33,17.4c0,0.1,0,0.1,0.1,0.2c0,0,0,0,0,0 c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0.1,0.5,0.2,1,0.3,1.6c0.1,0.4,0.1,0.9,0.1,1.3c0,0,0,0,0,0c0,0,0,0.1,0,0.1 c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.4,0,0.9-0.1,1.3 c-0.1,0.5-0.2,1-0.3,1.6c0,0,0,0,0,0c0,0,0,0.1,0,0.1c0,0,0,0.1,0,0.1c0,0,0,0,0,0c0,0.1,0,0.1-0.1,0.2l4.2,1.4 c0.1-0.2,0.1-0.4,0.2-0.6c0.2-0.8,0.4-1.6,0.5-2.4c0.1-0.7,0.1-1.4,0.1-2C38,20.3,38,19.6,37.9,19z M9,17.4L4.7,16 c-0.1,0.2-0.1,0.4-0.2,0.6c-0.2,0.8-0.4,1.6-0.5,2.4C4,19.6,4,20.3,4,21c0,0.7,0,1.4,0.1,2c0.1,0.8,0.2,1.6,0.5,2.4 c0.1,0.2,0.1,0.4,0.2,0.6L9,24.6c0-0.1,0-0.1-0.1-0.2c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0 c-0.1-0.5-0.2-1-0.3-1.6c-0.1-0.4-0.1-0.9-0.1-1.3c0,0,0,0,0,0c0,0,0-0.1,0-0.1c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0-0.1,0-0.1 c0,0,0,0,0-0.1c0,0,0-0.1,0-0.1c0,0,0,0,0,0c0-0.4,0-0.9,0.1-1.3c0.1-0.5,0.2-1,0.3-1.6c0,0,0,0,0,0c0,0,0-0.1,0-0.1 c0,0,0-0.1,0-0.1c0,0,0,0,0,0C9,17.6,9,17.5,9,17.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1499 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1500);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1500 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-grid3-cell.x-grid-mimeicon {\n    background-repeat: no-repeat;\n    background-size: 16px 16px;\n    position: relative;\n}\n\n.x-grid3-cell.x-grid-mimeicon .x-grid3-cell-inner {\n    margin-left: 14px;\n}\n\n.x-grid3-cell .mime-icon-overlay {\n    position: absolute;\n    top: 1px;\n    left: 0px;\n    width: 16px;\n    height: 16px;\n    background-repeat: no-repeat;\n    background-size: 16px 16px;\n}\n\n.mime-icon-link {\n    background-image: url(" + escape(__webpack_require__(1501)) + ");\n}\n\n/**folder**/\n.mime-icon-folder,\n.mime-type-application-slash-vnd-dot-sss-cod,\n.mime-type-application-slash-nasdata {\n    background-image: url(" + escape(__webpack_require__(163)) + ");\n}\n/**file**/\n.mime-icon-file,\n.mime-type-application-slash-vnd-dot-truedoc,\n.mime-type-application-slash-vnd-dot-trueapp {\n    background-image: url(" + escape(__webpack_require__(1502)) + ");\n}\n\n/**audio**/\n.mime-content-type-audio,\n.mime-type-application-slash-vnd-dot-dolby-dot-mobile-dot-1,\n.mime-type-application-slash-vnd-dot-dolby-dot-mobile-dot-2,\n.mime-type-application-slash-vnd-dot-jisp,\n.mime-type-application-slash-vnd-dot-koan,\n.mime-type-application-slash-vnd-dot-dzr,\n.mime-type-application-slash-vnd-dot-jam,\n.mime-type-application-slash-mp4,\n.mime-type-application-slash-vnd-dot-yamaha-dot-smaf-audio,\n.mime-type-application-slash-vnd-dot-nokia-dot-iSDS-radio-presets,\n.mime-type-application-slash-vnd-dot-nokia-dot-radio-preset,\n.mime-type-application-slash-vnd-dot-nokia-dot-radio-presets {\n    background-image: url(" + escape(__webpack_require__(1503)) + ");\n}\n\n/**font**/\n.mime-content-type-font,\n.mime-type-application-slash-vnd-dot-ms-fontobject,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-fontTable-plus-xml,\n.mime-type-application-slash-font-woff,\n.mime-type-application-slash-font-tdpfr,\n.mime-type-font-slash-font-tdpfr,\n.mime-type-font-slash-woff,\n.mime-type-application-slash-font-sfnt,\n.mime-type-font-slash-sfnt,\n.mime-type-application-slash-vnd-dot-font-fontforge-sfd,\n.mime-type-application-slash-vnd-dot-psfs,\n.mime-type-application-slash-vnd-dot-dvb.pfr {\n\n\n}\n\n/**ebooks**/\n.mime-type-application-slash-oebps-package-plus-xml,\n\n    /**images**/\n.mime-content-type-image,\n.mime-type-application-slash-vnd-dot-3gpp-dot-pic-bw-large,\n.mime-type-application-slash-vnd-dot-3gpp-dot-pic-bw-small,\n.mime-type-application-slash-vnd-dot-3gpp-dot-pic-bw-var,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-image,\n.mime-type-application-slash-vnd-dot-is-xpr,\n.mime-type-application-slash-vnd-dot-nitf {\n    background-image: url(" + escape(__webpack_require__(641)) + ");\n}\n\n/**text**/\n/*** plain **/\n.mime-content-type-text,\n.mime-type-text-slash-troff,\n.mime-icon-text-slash-plain,\n.mime-type-text-slash-strings,\n.mime-type-application-slash-n-quads,\n.mime-type-application-slash-vnd-dot-astraea-software-dot-iota {\n    background-image: url(" + escape(__webpack_require__(1504)) + ");\n}\n/*** formatted **/\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text,\n.mime-type-application-slash-vnd-dot-msword,\n.mime-type-application-slash-vnd-dot-msword-dot-document-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text-master,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text-web,\n.mime-type-application-slash-vnd-dot-sealedmedia-dot-softseal-dot-pdf,\n.mime-type-text-slash-richtext,\n.mime-type-text-slash-rtx,\n.mime-type-application-slash-vnd-dot-ms-word-dot-document-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text-master,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text-web,\n.mime-type-application-slash-vnd-dot-collabio-dot-xodocuments-dot-document,\n.mime-type-application-slash-prs-dot-alvestrand-dot-titrax-sheet,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-comments-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-document,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-document-dot-glossary-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-document-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-footer-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-numbering-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-styles-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-document,\n.mime-type-application-slash-commonground,\n.mime-type-application-slash-oxps,\n.mime-type-application-slash-prs-dot-cww,\n.mime-type-application-slash-rtf,\n.mime-type-text-slash-rtf,\n.mime-type-application-slash-urc-grpsheet-plus-xml,\n.mime-type-application-slash-vnd-dot-ahead-dot-space,\n.mime-type-application-slash-vnd-dot-apple-dot-pages,\n.mime-type-application-slash-msword,\n.mime-type-application-slash-vnd-dot-wolfram-dot-mathematica,\n.mime-type-application-slash-ODA,\n.mime-type-application-slash-vnd-dot-ms-xpsdocument,\n.mime-type-application-slash-vnd-dot-wordperfect,\n.mime-type-application-slash-vnd-dot-framemaker,\n.mime-type-application-slash-vnd-dot-kde-dot-kword,\n.mime-type-application-slash-macwriteii,\n.mime-type-application-slash-vnd-dot-document-plus-json,\n.mime-type-text-slash-enriched {\n    background-image: url(" + escape(__webpack_require__(1505)) + ");\n}\n\n/**movie**/\n.mime-content-type-video,\n.mime-type-application-slash-vnd-dot-arastra-dot-swi,\n.mime-type-application-slash-vnd-dot-aristanetworks-dot-swi,\n.mime-type-application-slash-vnd-dot-aristanetworks-dot-swi,\n.mime-type-application-slash-vnd-dot-pvi-dot-ptid1,\n.mime-type-application-slash-vnd-dot-youtube-dot-yt,\n.mime-type-application-slash-vnd-dot-dvb-dot-ait,\n.mime-type-application-slash-vnd-dot-dvb-dot-dvbj,\n.mime-type-application-slash-vnd-dot-dvb-dot-esgcontainer,\n.mime-type-application-slash-vnd-dot-dvb-dot-ipdcdftnotifaccess,\n.mime-type-application-slash-vnd-dot-dvb-dot-ipdcesgaccess,\n.mime-type-application-slash-vnd-dot-dvb-dot-ipdcesgaccess2,\n.mime-type-application-slash-vnd-dot-dvb-dot-ipdcesgpdd,\n.mime-type-application-slash-vnd-dot-dvb-dot-ipdcroaming,\n.mime-type-application-slash-vnd-dot-dvb-dot-iptv-dot-alfec-base,\n.mime-type-application-slash-vnd-dot-dvb-dot-iptv-dot-alfec-enhancement,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-aggregate-root-plus-xml,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-containhttps,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-generic-plus-xml,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-ia-msglist-plus-xml,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-ia-registration-request-plus-xml,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-ia-registration-response-plus-xml,\n.mime-type-application-slash-vnd-dot-dvb-dot-notif-init-plus-xml,\n.mime-type-application-slash-vnd-dot-pvi-dot-ptid1,\n.mime-type-application-slash-vnd-dot-adobe-dot-flash-dot-movie,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-drm-trigger-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-imd-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-notification-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-provisioningtrigger,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sgboot,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sgdd-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sgdu,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-simple-symbol-container,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-smartcard-trigger-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sprov-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-stkm,\n.mime-type-application-slash-vnd-dot-tmobile-livetv,\n.mime-type-text-slash-vnd-dot-dvb-dot-subtitle {\n    background-image: url(" + escape(__webpack_require__(1506)) + ");\n}\n\n/**pdf**/\n.mime-type-application-slash-pdf {\n    background-image: url(" + escape(__webpack_require__(1507)) + ");\n}\n\n\n/**drawing**/\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-graphics,\n.mime-type-application-slash-vnd-dot-chemdraw-plus-xml,\n.mime-type-application-slash-vnd-dot-criticaltools-dot-wbs-plus-xml,\n.mime-icon-application-slash-x-krita,\n.mime-type-application-slash-vnd-dot-vectorworks,\n.mime-type-application-slash-vnd-dot-immervision-ivp,\n.mime-type-application-slash-vnd-dot-immervision-ivu,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-vmlDrawing,\n.mime-type-application-slash-vnd-dot-micrografx-dot-flo,\n.mime-type-application-slash-vnd-dot-micrografx-dot-igx,\n.mime-type-application-slash-vnd-dot-geoplan,\n.mime-type-application-slash-vnd-dot-geospace,\n.mime-type-application-slash-vnd-dot-gerber,\n.mime-type-text-slash-vnd-dot-ascii-art,\n.mime-type-application-slash-vnd-dot-cinderella,\n.mime-type-application-slash-vnd-dot-ecowin-dot-chart,\n.mime-type-application-slash-iges,\n.mime-type-application-slash-vnd-dot-mcd,\n.mime-type-application-slash-vnd-dot-kde-dot-kchart,\n.mime-type-application-slash-vnd-dot-kde-dot-karbon {\n    background-image: url(" + escape(__webpack_require__(1508)) + ");\n}\n\n/**grafics**/\n\n.mime-type-application-slash-srgs,\n.mime-type-application-slash-srgs-plus-xml,\n.mime-type-application-slash-sru-plus-xml,\n.mime-type-application-slash-stix-plus-json,\n.mime-type-application-slash-ssml-plus-xml,\n.mime-type-application-slash-rdf-plus-xml,\n.mime-type-application-slash-vnd-dot-patentdive,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawingml-dot-diagramLayout-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawingml-dot-diagramData-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawingml-dot-diagramColors-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawingml-dot-chartshapes-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawingml-dot-chart-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawing-plus-xml,\n.mime-type-application-slash-vnd-dot-openeye-dot-oeb,\n.mime-type-application-slash-prs-dot-xsf-plus-xml,\n.mime-type-application-slash-vnd-dot-dynageo,\n.mime-type-application-slash-vnd-dot-Quark-dot-QuarkXPress,\n.mime-type-application-slash-vnd-dot-fujitsu-dot-oasys2,\n.mime-type-application-slash-vnd-dot-fujitsu-dot-oasys3,\n.mime-type-application-slash-vnd-dot-fujitsu-dot-oasysgp,\n.mime-type-application-slash-vnd-dot-fujitsu-dot-oasysprs {\n/*    background-image: url(../../images/icon-set/icon_file_grafics.svg); */\n}\n\n/**charts**/\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-drawingml-dot-diagramStyle-plus-xml,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-chart,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-chart,\n.mime-type-application-slash-vnd-dot-FloGraphIt,\n.mime-type-text-slash-vnd-dot-graphviz,\n.mime-type-text-slash-vnd-dot-gml,\n.mime-type-application-slash-vnd-dot-onepagertamx,\n.mime-type-application-slash-vnd-dot-SimTech-MindMapper,\n.mime-type-application-slash-vnd-dot-xara,\n.mime-type-application-slash-vnd-dot-onepager,\n.mime-type-application-slash-vnd-dot-onepagertamp,\n.mime-type-application-slash-vnd-dot-kde-dot-kivio,\n.mime-type-application-slash-vnd-dot-kde-dot-kivio,\n.mime-type-application-slash-vnd-dot-visio {\n /*   background-image: url(../../images/icon-set/icon_file_charts.svg); */\n}\n\n/**spreadsheet**/\n.mime-type-text-slash-csv,\n.mime-type-text-slash-x-csv,\n.mime-type-application-slash-x-csv,\n.mime-type-application-slash-x-csv,\n.mime-type-text-slash-csv-schema,\n.mime-type-application-slash-comma-separated-values,\n.mime-type-application-slash-x-comma-separated-values,\n.mime-type-application-slash-vnd-dot-ms-excel,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-addin-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-sheet-dot-binary-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-sheet-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-sheet,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-dialogsheet-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-calcChain-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-chartsheet-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-comments-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-connections-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-dialogsheet-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-externalLink-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-pivotCacheDefinition-plus-xml,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-spreadsheet,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-pivotCacheRecords-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-pivotTable-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-revisionLog-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-queryTable-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-sharedStrings-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-sheet,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-sheet-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-table-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-tableSingleCells-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-worksheet-plus-xml,\n.mime-type-application-slash-vnd-dot-collabio-dot-xodocuments-dot-spreadsheet,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-spreadsheet,\n.mime-type-application-slash-vnd-dot-tableschema-plus-json,\n.mime-type-application-slash-resource-lists-diff-plus-xml,\n.mime-type-application-slash-vnd-dot-uri-map,\n.mime-type-text-slash-tab-separated-values,\n.mime-type-application-slash-csvm-plus-json,\n.mime-type-application-slash-news-checkgroups,\n.mime-type-application-slash-n-triples,\n.mime-type-application-slash-vnd-dot-isac-dot-fcs {\n    background-image: url(" + escape(__webpack_require__(540)) + ");\n}\n\n/**presentations**/\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-presentation,\n.mime-type-application-slash-vnd-dot-openxmlformats-package-dot-core-properties-plus,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-presentation-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slideshow-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-presentation,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slideshow,\n.mime-type-application-slash-vnd-dot-ms-powerpoint,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-addin-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-presentation-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-slideshow-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-presentation,\n.mime-type-application-slash-vnd-dot-apple-dot-keynote,\n.mime-type-application-slash-vnd-dot-ibm-dot-modcap,\n.mime-type-application-slash-vnd-dot-openxmlformats-fficedocument-dot-presentationml-dot-presentation,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-presProps-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slide,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slide-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slideLayout-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slideMaster-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slideshow,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-tableStyles-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-tags-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-viewProps-plus-xml,\n.mime-type-application-slash-vnd-dot-collabio-dot-xodocuments-dot-presentation,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-comments-plus-xml,\n.mime-type-application-slash-vnd-dot-kde-dot-kpresenter,\n.mime-type-application-slash-smil,\n.mime-type-application-slash-smil-plus-xml,\n.mime-type-application-slash-vnd-dot-afpc-dot-afplinedata,\n.mime-type-application-slash-vnd-dot-afpc-dot-modca {\n    background-image: url(" + escape(__webpack_require__(1509)) + ");\n}\n\n/**archives**/\n.mime-type-application-slash-vnd-dot-rar,\n.mime-type-application-slash-vnd-dot-geogebra-dot-file,\n.mime-type-application-slash-zip,\n.mime-type-application-slash-zlib,\n.mime-type-application-slash-zstd,\n.mime-type-application-slash-vnd-dot-software602-dot-filler-dot-form-plus-xml,\n.mime-type-application-slash-vnd-dot-tao-dot-intent-module-archive,\n.mime-type-application-slash-gzip,\n.mime-type-application-slash-dca-rft,\n.mime-type-application-slash-vnd-dot-ibm-dot-secure-container,\n.mime-type-application-slash-vnd-dot-fuzzysheet,\n.mime-type-application-slash-vnd-dot-seemail,\n.mime-type-application-slash-vnd-dot-software602-dot-filler-dot-form-xml-zip,\n.mime-type-application-slash-vnd-dot-semd,\n.mime-type-application-slash-vnd-dot-semf,\n.mime-type-application-slash-fastinfoset,\n.mime-type-application-slash-vnd-dot-americandynamics-dot-acc,\n.mime-type-application-slash-prs-dot-hpub-plus-zip,\n.mime-type-application-slash-vnd-dot-fastcopy-disk-image,\n.mime-type-application-slash-vnd-dot-imagemeter-dot-folder-plus-zip,\n.mime-type-application-slash-vnd-dot-imagemeter-dot-image-plus-zip,\n.mime-type-application-slash-vnd-dot-ims-dot-imsccv1p1,\n.mime-type-application-slash-vnd-dot-ims-dot-imsccv1p2,\n.mime-type-application-slash-vnd-dot-ims-dot-imsccv1p3,\n.mime-type-application-slash-vnd-dot-ms-cab-compressed,\n.mime-type-application-slash-vnd-dot-msa-disk-image,\n.mime-type-application-slash-ogg,\n.mime-type-application-slash-vnd-dot-openxmlformats-package-dot-relationships-plus-xml,\n.mime-type-application-slash-vnd-dot-insors-dot-igm,\n.mime-type-application-slash-vnd-dot-efi-dot-img\n.mime-type-application-slash-vnd-dot-efi-dot-img\n.mime-type-application-slash-vnd-dot-wolfram-dot-mathematica-dot-package\n.mime-type-application-slash-mathml-presentation-plus-xml {\n    background-image: url(" + escape(__webpack_require__(1510)) + ");\n}\n\n/**binaray file types**/\n.mime-type-application-slash-vnd-dot-3gpp-dot-sms,\n.mime-type-application-slash-octet-stream,\n.mime-type-application-slash-vnd-dot-3gpp-dot-state-and-event-info-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-ussd-plus-xml,\n.mime-type-application-slash-vnd-dot-epson-dot-esf,\n.mime-type-application-slash-vnd-dot-epson-dot-msf,\n.mime-type-application-slash-vnd-dot-epson-dot-quickanime,\n.mime-type-application-slash-vnd-dot-epson-dot-salt,\n.mime-type-application-slash-vnd-dot-epson-dot-ssf {\n    background-image: url(" + escape(__webpack_require__(1511)) + ");\n}\n\n/**codeing**/\n.mime-type-text-slash-turtle,\n.mime-type-text-slash-markdown,\n.mime-type-application-slash-vnd-dot-ufdl,\n.mime-type-application-slash-cbor,\n.mime-type-text-slash-css,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-database,\n.mime-type-application-slash-vnd-dot-sqlite3,\n.mime-type-application-slash-sql,\n.mime-type-application-slash-vnd-dot-microsoft-dot-windows-dot-thumbnail-cache,\n.mime-type-text-slash-directory,\n.mime-type-application-slash-vnd-dot-balsamiq-dot-bmpr,\n.mime-type-application-slash-vnd-dot-informedcontrol-dot-rms-plus-xml,\n.mime-type-application-slash-vnd-dot-ims-dot-lis-dot-v2-dotresult-plus-json,\n.mime-type-application-slash-vnd-dot-informix-visionary,\n.mime-type-application-slash-vnd.visionary,\n.mime-type-text-slash-vnd-dot-fly,\n.mime-type-text-slash-html,\n.mime-type-application-slash-prs-dot-plucker,\n.mime-type-application-slash-javascript,\n.mime-type-text-slash-javascript,\n.mime-type-application-slash-vnd-dot-cab-jscript,\n.mime-type-application-slash-vnd-dot-coffeescript,\n.mime-type-text-slash-ecmascript,\n.mime-type-application-slash-node,\n.mime-type-application-slash-vnd-dot-dart,\n.mime-type-application-slash-vnd-dot-las-dot-las-plus-json,\n.mime-type-application-slash-vnd-dot-las-dot-las-plus-xml,\n.mime-type-application-slash-postscript,\n.mime-type-application-slash-sparql-query,\n.mime-type-application-slash-sparql-results-plus-xml,\n.mime-type-application-slash-vnd-dot-acucobol,\n.mime-type-application-slash-xslt-plus-xml,\n.mime-type-application-slash-vnd-dot-geonext,\n.mime-type-text-slash-jcr-cnd,\n.mime-type-application-slash-vnd-dot-osgi-dot-bundle,\n.mime-type-text-slash-turtle,\n.mime-type-application-slash-http,\n.mime-type-application-slash-vnd-dot-umajin,\n.mime-type-application-slash-vnd-dot-fujitsu-dot-oasys,\n.mime-type-application-slash-merge-patch-plus-json,\n.mime-type-application-slash-vnd-dot-ecowin-dot-filerequest,\n.mime-type-application-slash-vnd-dot-ecowin-dot-fileupdate,\n.mime-type-application-slash-vnd-dot-ecowin-dot-series,\n.mime-type-application-slash-vnd-dot-ecowin-dot-seriesrequest,\n.mime-type-application-slash-vnd-dot-ecowin-dot-seriesupdate,\n.mime-type-application-slash-urc-targetdesc-plus-xml,\n.mime-type-application-slash-vnd-dot-powerbuilder6,\n.mime-type-application-slash-vnd-dot-powerbuilder6-s,\n.mime-type-application-slash-vnd-dot-powerbuilder7,\n.mime-type-application-slash-vnd-dot-powerbuilder75,\n.mime-type-application-slash-vnd-dot-powerbuilder75-s,\n.mime-type-application-slash-vnd-dot-powerbuilder7-s {\n  /*  background-image: url(../../images/icon-set/icon_file_codeing.svg); */\n}\n/**deploys java to the browser @ToDo**/\n.mime-type-application-slash-atomcat-plus-xml {\n}\n\n/**System**/\n.mime-type-application-slash-vnd-dot-palm,\n.mime-type-application-slash-efi,\n.mime-type-text-slash-troff,\n.mime-type-application-slash-vnd-dot-autopackage,\n.mime-type-application-slash-vnd-dot-dna,\n.mime-type-application-slash-vnd-dot-microsoft-dot-portable-executable,\n.mime-type-application-slash-vnd-dot-ms-office-dot-activeX-plus-xml,\n.mime-type-application-slash-rtx,\n.mime-type-application-slash-vnd-dot-debian-dot-binary-package,\n.mime-type-text-slash-vnd-dot-debian-dot-copyright,\n.mime-type-application-slash-applefile,\n.mime-type-application-slash-riscos,\n.mime-type-application-slash-vnd-dot-macports-dot-portpkg,\n.mime-type-application-slash-vnd-dot-macports-dot-portpkg,\n.mime-type-application-slash-vnd-dot-panoply,\n.mime-type-application-slash-vnd-dot-proteus-dot-magazine {\n}\n\n/**Calendar**/\n.mime-type-application-slash-vnd-dot-3lightssoftware-dot-imagescal,\n.mime-type-text-slash-calendar,\n.mime-type-application-slash-calendar-plus-json,\n.mime-type-application-slash-calendar-plus-xml,\n.mime-type-application-slash-vnd-dot-sus-calendar,\n.mime-type-application-slash-vnd-dot-llamagraphics-dot-life-balance-dot-desktop,\n.mime-type-application-slash-vnd-dot-llamagraphics-dot-life-balance-dot-exchange-plus-xml,\n.mime-type-application-slash-slate {\n/*    background-image: url(../../images/icon-set/icon_file_calendar.svg); */\n}\n\n/**Mail**/\n.mime-type-application-slash-vnd-dot-gmx,\n.mime-type-application-slash-wordperfect5-dot-1,\n.mime-type-application-slash-vnd-dot-sss-ntf,\n.mime-type-application-slash-yin-plus-xml,\n.mime-type-application-slash-vnd-dot-grafeq,\n.mime-type-application-slash-activemessage,\n.mime-type-application-slash-atomicmail,\n.mime-type-application-slash-batch-SMTP,\n.mime-type-application-slash-mbox,\n.mime-type-application-slash-vnd-dot-omads-email-plus-xml,\n.mime-type-application-slash-vnd-dot-shana-dot-informed-dot-formdata,\n.mime-type-application-slash-yin-plus-xml,\n.mime-type-application-slash-vnd-dot-minisoft-hp3000-save,\n.mime-type-application-slash-vnd-dot-ms-tnef,\n.mime-type-application-slash-vnd-dot-eudora-dot-data,\n.mime-type-application-slash-mac-binhex40,\n.mime-type-application-slash-vnd-dot-emclient-dot-accessrequest-plus-xml {\n}\n\n/**Project**/\n.mime-type-application-slash-vnd-dot-ms-project {\n}\n\n/**Print**/\n.mime-type-application-slash-vnd-dot-ms-PrintSchemaTicket-plus-xml,\n.mime-type-application-slash-vnd-dot-ms-windows-dot-printerpairing,\n.mime-type-application-slash-vnd-dot-fujixerox-dot-ART4,\n.mime-type-application-slash-vnd-dot-fujixerox-dot-ART-EX,\n.mime-type-application-slash-vnd-dot-canon-cpdl,\n.mime-type-application-slash-vnd-dot-canon-lips,\n.mime-type-application-slash-vnd-dot-cups-raw,\n.mime-type-application-slash-vnd-dot-ms-windows-dot-nwprinting-dot-oob,\n.mime-type-application-slash-vnd-dot-cups-pdf,\n.mime-type-application-slash-vnd-dot-cups-postscript,\n.mime-type-application-slash-vnd-dot-cups-raster,\n.mime-type-application-slash-vnd-dot-cups-ppd,\n.mime-type-application-slash-remote-printing,\n.mime-type-application-slash-vnd-dot-ibm-dot-afplinedata,\n.mime-type-application-slash-vnd-dot-ms-3mfdocument,\n.mime-type-application-slash-vnd-dot-ms-PrintDeviceCapabilities-plus-xml,\n.mime-type-application-slash-vnd-dot-hp-HPGL,\n.mime-type-application-slash-vnd-dot-hp-hpid,\n.mime-type-application-slash-vnd-dot-hp-hps,\n.mime-type-application-slash-vnd-dot-hp-jlyt,\n.mime-type-application-slash-vnd-dot-hp-PCL,\n.mime-type-application-slash-vnd-dot-hp-PCLXL,\n.mime-type-application-slash-vnd-dot-wrq-hp3000-labelled,\n.mime-type-application-slash-vnd-dot-ms-windows-dot-wsd-dot-oob,\n.mime-type-application-slash-vnd-dot-windows-dot-devicepairing,\n.mime-type-application-slash-vnd-dot-ms-windows-dot-devicepairing,\n.mime-type-application-slash-ipp,\n.mime-type-application-slash-vnd-dot-pwg-xhtml-print-plus-xml,\n.mime-type-application-slash-vnd-dot-eprints-dot-data-plus-xml,\n.mime-type-text-slash-vnd-dot-hgl {\n}\n\n/**Media**/\n.mime-type-application-slash-vnd-dot-siren-plus-json,\n.mime-type-application-slash-vnd-dot-hc-plus-json,\n.mime-type-application-slash-smpte336m,\n.mime-type-application-slash-mediaservercontrol-plus-xml,\n.mime-type-application-slash-vnd-dot-verimatrix-dot-vcas,\n.mime-type-application-slash-andrew-inset,\n.mime-type-application-slash-media_control-plus-xml,\n.mime-type-application-slash-vnd-dot-svd,\n.mime-type-application-slash-vnd-dot-yamaha-dot-openscoreformat-dot-osfpvg-plus-xml,\n.mime-type-application-slash-vnd-dot-yamaha-dot-openscoreformat,\n.mime-type-application-slash-vnd-dot-musician,\n.mime-type-application-slash-vnd-dot-music-niff,\n.mime-type-text-slash-vnd-dot-a,\n.mime-type-text-slash-vnd-dot-abc,\n.mime-type-application-slash-vnd-dot-doremir-dot-scorecloud-binary-document,\n.mime-type-application-slash-vnd-dot-recordare-dot-musicxml,\n.mime-type-application-slash-vnd-dot-recordare-dot-musicxml-plus-xml,\n.mime-type-application-slash-vnd-dot-smaf,\n.mime-type-application-slash-vnd-dot-httphone,\n.mime-type-application-slash-vnd-dot-yamaha-dot-hv-dic,\n.mime-type-application-slash-vnd-dot-yamaha-dot-hv-script,\n.mime-type-application-slash-vnd-dot-yamaha-dot-hv-voice,\n.mime-type-text-slash-1d-interleaved-parityfec,\n.mime-type-application-slash-mxf,\n.mime-type-application-slash-vemmi,\n.mime-type-application-slash-sdp,\n.mime-type-application-slash-vnd-dot-apple-dot-mpegurl,\n.mime-type-application-slash-vnd-dot-audiograph,\n.mime-type-application-slash-vnd-dot-comicbook-rar,\n.mime-type-application-slash-vnd-dot-comicbook-plus-zip,\n.mime-type-application-slash-vnd-dot-ezpix-album,\n.mime-type-application-slash-vnd-dot-ezpix-package,\n.mime-type-application-slash-vnd-dot-iccprofile,\n.mime-type-application-slash-vnd-dot-mseq,\n.mime-type-application-slash-vnd-dot-multiad-dot-creator,\n.mime-type-application-slash-vnd-dot-multiad-dot-creator-dot-cif,\n.mime-type-application-slash-vnd-dot-muvee-dot-stylem,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-drm-trigger-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-imd-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-notification-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-provisioningtrigger,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sgboot,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sgdd-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sgdu,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-simple-symbol-container,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-smartcard-trigger-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-sprov-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-stkm,\n.mime-type-application-slash-gltf-buffer,\n.mime-type-application-slash-hyperstudio,\n.mime-type-application-slash-vnd-dot-fluxtime-dot-clip,\n.mime-type-application-slash-dashdelta,\n.mime-type-application-slash-vnd-dot-oipf-dot-contentaccessstreaming-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-dae-dot-svg-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-dae-dot-xhtml-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-mippvcontrolmessage-plus-xml,\n.mime-type-application-slash-vnd-dot-marlin-dot-drm-dot-actiontoken-plus-xml,\n.mime-type-application-slash-vnd-dot-marlin-dot-drm-dot-conftoken-plus-xml,\n.mime-type-application-slash-vnd-dot-marlin-dot-drm-dot-license-plus-xml,\n.mime-type-application-slash-vnd-dot-marlin-dot-drm-dot-mdcf,\n.mime-type-application-slash-vnd-dot-ms-wpl,\n.mime-type-application-slash-smil-plus-xml,\n.mime-type-text-slash-vnd-dot-in3d-dot-3dml,\n.mime-type-text-slash-vnd-dot-in3d-dot-spot,\n.mime-type-application-slash-vnd-dot-publishare-delta-tree,\n.mime-type-application-slash-vnd-dot-3gpp-dot-srvcc-ext-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-SRVCC-info-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-state-and-event-info-plus-xml,\n.mime-type-application-slash-3gpp-ims-plus-xml,\n.mime-type-application-slash-vnd-dot-easykaraoked-dot-cdgdownload,\n.mime-type-text-slash-vnd-dot-IPTC-dot-NewsML,\n.mime-type-application-slash-vnd-dot-dtg-dot-local,\n.mime-type-application-slash-vnd-dot-dtg-dot-local-dot-flash,\n.mime-type-application-slash-vnd-dot-dtg-dot-local-dot-html,\n.mime-type-application-slash-vnd-dot-enliven,\n.mime-type-application-slash-vnd-dot-drive-plus-json {\n}\n\n/**Application**/\n.mime-type-application-slash-Name,\n.mime-type-application-slash-vnd-dot-pmi-dot-widget,\n.mime-type-text-slash-cache-manifest,\n.mime-type-application-slash-vnd-dot-apple-dot-installer-plus-xml,\n.mime-type-application-slash-vnd-dot-ibm-dot-electronic-media,\n.mime-type-application-slash-vnd-dot-ms-artgalry,\n.mime-type-application-slash-widget,\n.mime-type-application-slash-vnd-dot-wolfram-dot-player,\n.mime-type-application-slash-vnd-dot-ms-works,\n.mime-type-application-slash-DCD,\n.mime-type-application-slash-vnd-dot-kde-dot-kontour,\n.mime-type-application-slash-vnd-dot-osa-dot-netdeploy {\n}\n\n/**Policy**/\n.mime-type-application-slash-vnd-dot-etsi-dot-overload-control-policy-dataset-plus-xml,\n.mime-type-application-slash-wspolicy-plus-xml,\n.mime-type-application-slash-xacml-plus-xml,\n.mime-type-application-slash-media-policy-dataset-plus-xml,\n.mime-type-application-slash-vnd-dot-xacml-plus-json,\n.mime-type-application-slash-load-control-plus-xml {\n}\n\n/**Analytics**/\n.mime-type-application-slash-vnd-dot-spotfire-dot-sfs,\n.mime-type-application-slash-vnd-dot-spotfire-dot-dxp,\n.mime-type-application-slash-vnd-dot-businessobjects,\n.mime-type-application-slash-ipfix {\n}\n\n/**Mobile**/\n.mime-type-application-slash-3gpdash-qoe-report-plus-xml,\n.mime-type-application-slash-vnd-dot-syncml-dot-dmddf-plus-xml,\n.mime-type-application-slash-vnd-dot-syncml-dot-dmtnds-plus-wbxml,\n.mime-type-application-slash-vnd-dot-syncml-dot-dmtnds-plus-xml,\n.mime-type-application-slash-vnd-dot-syncml-dot-dmddf-plus-wbxml,\n.mime-type-application-slash-vnd-dot-syncml-dot-dm-plus-wbxml,\n.mime-type-application-slash-vnd-dot-syncml-dot-dm-plus-xml,\n.mime-type-application-slash-vnd-dot-syncml-dot-ds-dot-notification,\n.mime-type-application-slash-vnd-dot-syncml-plus-xml,\n.mime-type-application-slash-vnd-dot-yaoweme,\n.mime-type-application-slash-call-completion,\n.mime-type-application-slash-vnd-dot-ezpix-package,\n.mime-type-application-slash-vnd-dot-HandHeld-Entertainment-plus-xml,\n.mime-type-application-slash-mikey,\n.mime-type-application-slash-vnd-dot-3gpp-dot-bsf-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-GMOP-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mc-signalling-ear,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcdata-payload,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcdata-signalling,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-affiliation-command-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-floor-request-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-info-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-location-info-plus-xml,\n.mime-type-application-slash-simpleSymbolContainer,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-associated-procedure-parameter-plus-xml,\n.mime-type-application-slash-vnd-dot-sbm-dot-cid,\n.mime-type-application-slash-vnd-dot-sbm-dot-mid2,\n.mime-type-application-slash-vnd-dot-mfmp,\n.mime-type-application-slash-vnd-dot-jcp-dot-javame-dot-midlet-rms,\n.mime-type-application-slash-vnd-dot-picsel,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-mbms-usage-info-plus-xml,\n.mime-type-application-slash-vnd-dot-ntt-local-dot-content-share,\n.mime-type-application-slash-vnd-dot-3gpp-dot-ussd-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-prose-pc3ch-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-prose-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp2-dot-bcmcsinfo-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp2-dot-tcap,\n.mime-type-application-slash-vnd-dot-oma-dot-drm-dot-risd-plus-xml {\n}\n\n/**Map**/\n.mime-type-application-slash-vnd-dot-openstreetmap-dot-data-plus-xml,\n.mime-type-application-slash-vnd-dot-trueapp,\n.mime-type-application-slash-vnd-dot-triscape-dot-mxs,\n.mime-type-application-slash-vnd-dot-geo-plus-json,\n.mime-type-application-slash-alto-costmap-plus-json,\n.mime-type-application-slash-vnd-dot-ecdis-update,\n.mime-type-application-slash-vnd-dot-google-earth-dot-kml-plus-xml,\n.mime-type-application-slash-vnd-dot-google-earth-dot-kmz,\n.mime-type-application-slash-geo-plus-json,\n.mime-type-application-slash-geo-plus-json-seq,\n.mime-type-application-slash-geopackage-plus-sqlite3,\n.mime-type-application-slash-gml-plus-xml,\n.mime-type-application-slash-vnd-dot-mapbox-vector-tile,\n.mime-type-application-slash-vnd-dot-sailingtracker-dot-track,\n.mime-type-application-slash-vnd-dot-sailingtracker-dot-track,\n.mime-type-application-slash-vnd-dot-sailingtracker-dot-track,\n.mime-type-application-slash-vnd-dot-route66-dot-link66-plus-xml,\n.mime-type-application-slash-vnd-dot-nokia-dot-landmark-plus-wbxml,\n.mime-type-application-slash-vnd-dot-nokia-dot-landmark-plus-xml,\n.mime-type-application-slash-vnd-dot-nokia-dot-landmarkcollection-plus-xml,\n.mime-type-application-slash-vnd-dot-obn,\n.mime-type-application-slash-vnd-dot-osgeo-dot-mapguide-dot-package,\n.mime-type-application-slash-lostsync-plus-xml {\n}\n\n/**Protocol**/\n.mime-type-text-slash-rfc822-headers,\n.mime-type-application-slash-activity-plus-json,\n.mime-type-application-slash-vnd-dot-wap-dot-sic,\n.mime-type-application-slash-vnd-dot-wap-dot-slc,\n.mime-type-application-slash-vnd-dot-wap-dot-wbxml,\n.mime-type-application-slash-vnd-dot-wap-dot-wmlc,\n.mime-type-application-slash-vnd-dot-wap-dot-wmlscriptc,\n.mime-type-application-slash-xcap-att-plus-xml,\n.mime-type-application-slash-xcap-caps-plus-xml,\n.mime-type-application-slash-xcap-diff-plus-xml,\n.mime-type-application-slash-xcap-el-plus-xml,\n.mime-type-application-slash-xcap-error-plus-xml,\n.mime-type-application-slash-xcap-ns-plus-xml,\n.mime-type-application-slash-vnd-dot-wfa-dot-p2p,\n.mime-type-application-slash-wsdl-plus-xml,\n.mime-type-application-slash-vnd-dot-pcos,\n.mime-type-application-slash-vnd-dot-syncml-dot-dm-dot-notification,\n.mime-type-text-slash-ulpfec,\n.mime-type-application-slash-bacnet-xdd-plus-zip,\n.mime-type-application-slash-vnd-dot-tcpdump-dot-pcap,\n.mime-type-application-slash-cdni,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-audit-conf-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-audit-conn-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-audit-dialog-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-audit-stream-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-audit-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-conf-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-base-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-fax-detect-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-fax-sendrecv-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-group-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-speech-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-transform-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-dialog-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-msml-plus-xml,\n.mime-type-application-slash-beep-plus-xml,\n.mime-type-application-slash-mud-plus-json,\n.mime-type-application-slash-vnd-dot-yamaha-dot-remote-setup,\n.mime-type-application-slash-vnd-dot-yamaha-dot-tunnel-udpencap,\n.mime-type-application-slash-ppsp-tracker-plus-json,\n.mime-type-application-slash-dssc-plus-der,\n.mime-type-application-slash-dssc-plus-xml,\n.mime-type-application-slash-epp-plus-xml,\n.mime-type-application-slash-vnd-dot-otps-dot-ct-kip-plus-xml,\n.mime-type-application-slash-soap-plus-fastinfoset,\n.mime-type-application-slash-soap-plus-xml,\n.mime-type-application-slash-spirits-event-plus-xml,\n.mime-type-application-slash-vnd-dot-adobe-dot-formscentral-dot-fcdt,\n.mime-type-application-slash-vnd-dot-aether-dot-imp,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite-dot-adsi,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite-dot-fis,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite-dot-gotap,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite-dot-kmr,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite-dot-ttc,\n.mime-type-application-slash-vnd-dot-motorola-dot-flexsuite-dot-wem,\n.mime-type-application-slash-vnd-dot-avistar-plus-xml,\n.mime-type-application-slash-cpl-plus-xml,\n.mime-type-application-slash-simple-message-summary,\n.mime-type-application-slash-vnd-dot-ieee-dot-1905,\n.mime-type-application-slash-vnd-dot-yamaha-dot-smaf-phrase,\n.mime-type-text-slash-t140,\n.mime-type-text-slash-rtploopback,\n.mime-type-text-slash-rtp-enc-aescm128,\n.mime-type-text-slash-t140,\n.mime-type-application-slash-alto-costmapfilter-plus-json,\n.mime-type-application-slash-alto-directory-plus-json,\n.mime-type-application-slash-alto-endpointprop-plus-json,\n.mime-type-application-slash-alto-endpointpropparams-plus-json,\n.mime-type-application-slash-alto-endpointcost-plus-json,\n.mime-type-application-slash-alto-endpointcostparams-plus-json,\n.mime-type-application-slash-alto-networkmapfilter-plus-json,\n.mime-type-application-slash-alto-networkmap-plus-json,\n.mime-type-application-slash-vnd-dot-etsi-dot-pstn-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvcommand-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvdiscovery-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvprofile-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvsad-bc-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvsad-cod-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvsad-npvr-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvservice-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvsync-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-mcid-plus-xml,\n.mime-type-application-slash-vnd-dot-wv-dot-ssp-plus-xml,\n.mime-type-application-slash-trickle-ice-sdpfrag,\n.mime-type-application-slash-vnd-dot-blueice-dot-multipass,\n.mime-type-application-slash-vnd-dot-orange-dot-indata,\n.mime-type-application-slash-vnd-dot-ocf-plus-cbor,\n.mime-type-application-slash-vnd-dot-s3sms,\n.mime-type-application-slash-vnd-dot-mediastation-dot-cdkey,\n.mime-type-application-slash-vnd-dot-realvnc-dot-bed,\n.mime-type-text-slash-vnd-dot-net2phone-dot-commcenter-dot-command,\n.mime-type-text-slash-vnld-dot-radisys-dot-msml-basic-layout,\n.mime-type-application-slash-lost-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-push,\n.mime-type-application-slash-isup,\n.mime-type-application-slash-vnd-dot-liberty-request-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-dcd,\n.mime-type-application-slash-vnd-dot-wmf-dot-bootstrap,\n.mime-type-text-slash-vnd-dot-wap-dot-sl,\n.mime-type-text-slash-vnd-dot-wap-dot-wml,\n.mime-type-text-slash-vnd-dot-wap-dot-wmlscript,\n.mime-type-text-slash-vnd-dot-wap-dot-si {\n\n}\n\n/**Modeling Language**/\n.mime-type-application-slash-yang,\n.mime-type-application-slash-yang-data-plus-json,\n.mime-type-application-slash-yang-data-plus-xml,\n.mime-type-application-slash-yang-patch-plus-xml,\n.mime-type-application-slash-yang-patch-plus-json,\n.mime-type-application-slash-x400-bp,\n.mime-type-application-slash-vnd-dot-sema {\n}\n\n/**XML**/\n.mime-type-text-slash-xml,\n.mime-type-application-slash-vnd-dot-balsamiq-dot-bmml-plus-xml,\n.mime-type-application-slash-vnd-dot-genomatix-dot-tuxedo,\n.mime-type-application-slash-xml,\n.mime-type-application-slash-shf-plus-xml,\n.mime-type-application-slash-vnd-dot-xmi-plus-xml,\n.mime-type-application-slash-xhtml-plus-xml,\n.mime-type-application-slash-xml,\n.mime-type-text-slash-vnd-dot-ms-mediapackage,\n.mime-type-application-slash-xml-external-parsed-entity,\n.mime-type-application-slash-xml-patch-plus-xml,\n.mime-type-application-slash-emotionml-plus-xml,\n.mime-type-application-slash-xmpp-plus-xml,\n.mime-type-application-slash-vnd-dot-sun-dot-wadl-plus-xml,\n.mime-type-application-slash-vnd-dot-uoml-plus-xml,\n.mime-type-application-slash-patch-ops-error-plus-xml,\n.mime-type-application-slash-relax-ng-compact-syntax,\n.mime-type-application-slash-clue_info-plus-xml,\n.mime-type-application-slash-sgml-open-catalog,\n.mime-type-application-slash-sgml,\n.mime-type-application-slash-xop-plus-xml,\n.mime-type-application-slash-xv-plus-xml,\n.mime-type-text-slash-sgml,\n.mime-type-application-slash-CDFX-plus-XML,\n.mime-type-application-slash-exi,\n.mime-type-application-slash-vnd-dot-adobe-dot-xdp-plus-xml,\n.mime-type-application-slash-vnd-dot-adobe-dot-xfdf,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-extended-properties-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-customXmlProperties-plus-xml,\n.mime-type-application-slash-lgr-plus-xml,\n.mime-type-text-slash-xml-external-parsed-entity,\n.mime-type-text-slash-n3,\n.mime-type-application-slash-p2p-overlay-plus-xml {\n}\n\n/**Extension/Libarary/Plug-in/Toolkit**/\n.mime-type-application-slash-xcon-conference-info-diff-plus-xml,\n.mime-type-application-slash-xcon-conference-info-plus-xml,\n.mime-type-application-slash-ccmp-plus-xml,\n.mime-type-application-slash-vnd-dot-visionary,\n.mime-type-application-slash-xenc-plus-xml,\n.mime-type-application-slash-CEA,\n.mime-type-application-slash-conference-info-plus-xml,\n.mime-type-application-slash-prs-dot-rdf-xml-crypt,\n.mime-type-application-slash-xenc-plus-xml,\n.mime-type-application-slash-nss,\n.mime-type-application-slash-vnd-dot-ibm-dot-MiniPay,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-addin-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-sheet-dot-binary-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-sheet-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-addin-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-presentation-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-presentation-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-slide-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-slideshow-dot-macroEnabled-dot-12,\n.mime-type-application-slash-xenc-plus-xml,\n.mime-type-application-slash-vnd-dot-think-cell-dot-ppttc-plus-json,\n.mime-type-application-slash-geoxacml-plus-xml,\n.mime-type-application-slash-sep-exi,\n.mime-type-application-slash-sep-plus-xml,\n.mime-type-application-slash-vnd-dot-ericsson-dot-quickcall,\n.mime-type-application-slash-vnd-dot-oftn-dot-l10n-plus-json,\n.mime-type-application-slash-vnd-dot-mynfc,\n.mime-type-application-slash-vnd-dot-hyperdrive-plus-json,\n.mime-type-application-slash-vnd-dot-mif,\n.mime-type-application-slash-vnd-dot-intercon-dot-formnet,\n.mime-type-application-slash-vnd-dot-oma-dot-pal-plus-xml,\n.mime-type-application-slash-vnd-dot-intercon-dot-formnet,\n.mime-type-application-slash-vnd-dot-dreamfactory {\n}\n\n/**LookUp**/\n.mime-type-text-slash-dns,\n.mime-type-application-slash-cnrp-plus-xml,\n.mime-type-application-slash-whoispp-query,\n.mime-type-application-slash-rdap-plus-json,\n.mime-type-application-slash-vnd-dot-maxmind-dot-maxmind-db {\n}\n\n/**E-Commerce/Retail**/\n.mime-type-application-slash-vnd-dot-vividence-dot-scriptfile,\n.mime-type-application-slash-eshop,\n.mime-type-application-slash-vnd-dot-street-stream,\n.mime-type-application-slash-mpeg4-generic,\n.mime-type-application-slash-mpeg4-iod,\n.mime-type-application-slash-mpeg4-iod-xmt,\n.mime-type-application-slash-vnd-dot-vcx,\n.mime-type-application-slash-vnd-dot-nearst-dot-inv-plus-json,\n.mime-type-application-slash-vnd-dot-nokia-dot-catalogs {\n}\n\n/**Payment**/\n.mime-type-application-slash-cybercash,\n.mime-type-application-slash-set-payment,\n.mime-type-application-slash-set-payment-initiation,\n.mime-type-application-slash-set-registration,\n.mime-type-application-slash-set-registration-initiation,\n.mime-type-application-slash-vnd-dot-anser-web-certificate-issue-initiation,\n.mime-type-application-slash-vnd-dot-commerce-battelle,\n.mime-type-application-slash-vnd-dot-japannet-directory-service,\n.mime-type-application-slash-vnd-dot-japannet-jpnstore-wakeup,\n.mime-type-application-slash-vnd-dot-japannet-payment-wakeup,\n.mime-type-application-slash-vnd-dot-japannet-registration,\n.mime-type-application-slash-vnd-dot-japannet-registration-wakeup,\n.mime-type-application-slash-vnd-dot-japannet-setstore-wakeup,\n.mime-type-application-slash-vnd-dot-japannet-verification,\n.mime-type-application-slash-vnd-dot-japannet-verification-wakeup,\n.mime-type-application-slash-vnd-dot-cybank,\n.mime-type-application-slash-IOTP,\n.mime-type-application-slash-cybercash {\n}\n\n/**Management / CRM / ERP**/\n.mime-type-application-slash-vnd-dot-uplanet-dot-alert,\n.mime-type-application-slash-vnd-dot-uplanet-dot-alert-wbxml,\n.mime-type-application-slash-vnd-dot-uplanet-dot-bearer-choice,\n.mime-type-application-slash-vnd-dot-uplanet-dot-bearer-choice-wbxml,\n.mime-type-application-slash-vnd-dot-uplanet-dot-cacheop,\n.mime-type-application-slash-vnd-dot-uplanet-dot-cacheop-wbxml,\n.mime-type-application-slash-vnd-dot-uplanet-dot-channel,\n.mime-type-application-slash-vnd-dot-uplanet-dot-channel-wbxml,\n.mime-type-application-slash-vnd-dot-uplanet-dot-list,\n.mime-type-application-slash-vnd-dot-uplanet-dot-listcmd,\n.mime-type-application-slash-vnd-dot-uplanet-dot-listcmd-wbxml,\n.mime-type-application-slash-vnd-dot-uplanet-dot-list-wbxml,\n.mime-type-application-slash-vnd-dot-uplanet-dot-signal,\n.mime-type-application-slash-vnd-dot-wmc,\n.mime-type-application-slash-cms,\n.mime-type-application-slash-vnd-dot-shootproof-plus-json,\n.mime-type-application-slash-cfw,\n.mime-type-application-slash-mbms-associated-procedure-description-plus-xml,\n.mime-type-application-slash-mbms-deregister-plus-xml,\n.mime-type-application-slash-mbms-envelope-plus-xml,\n.mime-type-application-slash-mbms-msk-response-plus-xml,\n.mime-type-application-slash-mbms-msk-plus-xml,\n.mime-type-application-slash-mbms-protection-description-plus-xml,\n.mime-type-application-slash-mbms-reception-report-plus-xml,\n.mime-type-application-slash-mbms-register-response-plus-xml,\n.mime-type-application-slash-mbms-register-plus-xml,\n.mime-type-application-slash-mbms-schedule-plus-xml,\n.mime-type-application-slash-mbms-user-service-description-plus-xml,\n.mime-type-application-slash-mrb-consumer-plus-xml,\n.mime-type-application-slash-mrb-publish-plus-xml,\n.mime-type-application-slash-vnd-dot-collection-dot-doc-plus-json,\n.mime-type-application-slash-vnd-dot-collection-plus-json,\n.mime-type-application-slash-vnd-dot-collection-dot-next-plus-json,\n.mime-type-application-slash-vnd-dot-filmit-dot-zfc,\n.mime-type-application-slash-vnd-dot-rainstor-dot-data,\n.mime-type-application-slash-vnd-dot-oma-dot-lwm2m-plus-json,\n.mime-type-application-slash-vnd-dot-oma-dot-lwm2m-plus-tlv,\n.mime-type-application-slash-vnd-dot-dm-dot-delegation-plus-xml {\n}\n\n/**Communication**/\n.mime-type-application-slash-vnd-dot-nokia-dot-pcd-plus-wbxml,\n.mime-type-application-slash-vnd-dot-nokia-dot-pcd-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-sms,\n.mime-type-application-slash-vnd-dot-3gpp-dot-sms-plus-xml,\n.mime-type-application-slash-dialog-info-plus-xml,\n.mime-type-application-slash-vnd-dot-vidsoft-dot-vidconference,\n.mime-type-application-slash-DIT,\n.mime-type-application-slash-csta-plus-xml,\n.mime-type-application-slash-CSTAdata-plus-xml,\n.mime-type-application-slash-EmergencyCallData-dot-Comment-plus-xml,\n.mime-type-application-slash-EmergencyCallData-dot-DeviceInfo-plus-xml,\n.mime-type-application-slash-EmergencyCallData-dot-eCall-dot-MSD,\n.mime-type-application-slash-EmergencyCallData-dot-ProviderInfo-plus-xml,\n.mime-type-application-slash-EmergencyCallData-dot-ServiceInfo-plus-xml,\n.mime-type-application-slash-EmergencyCallData-dot-SubscriberInfo-plus-xml,\n.mime-type-application-slash-EmergencyCallData-dot-VEDS-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-access-transfer-events-plus-xml,\n.mime-type-application-slash-vnd-dot-xmpie-dot-cpkg,\n.mime-type-application-slash-vnd-dot-xmpie-dot-dpkg,\n.mime-type-application-slash-vnd-dot-xmpie-dot-plan,\n.mime-type-application-slash-vnd-dot-xmpie-dot-ppkg,\n.mime-type-application-slash-vnd-dot-xmpie-dot-xlim,\n.mime-type-application-slash-vnd-dot-groove-account,\n.mime-type-application-slash-vnd-dot-groove-help,\n.mime-type-application-slash-vnd-dot-groove-identity-message,\n.mime-type-application-slash-vnd-dot-groove-injector,\n.mime-type-application-slash-vnd-dot-groove-tool-message,\n.mime-type-application-slash-vnd-dot-groove-vcard,\n.mime-type-application-slash-vnd-dot-hal-plus-json,\n.mime-type-application-slash-vnd-dot-hal-plus-xml,\n.mime-type-application-slash-ccxml-plus-xml,\n.mime-type-text-slash-vnd-dot-motorola-dot-reflex,\n.mime-type-application-slash-reginfo-plus-xml,\n.mime-type-application-slash-im-iscomposing-plus-xml,\n.mime-type-application-slash-voicexml-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-signed-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mid-call-plus-xml,\n.mime-type-text-slash-RED,\n.mime-type-application-slash-vnd-dot-oma-dotpoc-dotdetailed-progress-report-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dotpoc-dotfinal-report-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dotpoc-dotgroups-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dotpoc-dotinvocation-descriptor-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dotpoc-dotoptimized-progress-report-plus-xml,\n.mime-type-application-slash-vnd-dot-radisys-dot-moml-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp-v2x-local-service-information,\n.mime-type-application-slash-vnd-dot-3gpp2-dot-sms,\n.mime-type-application-slash-vnd-dot-innopath-dot-wamp-dot-notification,\n.mime-type-application-slash-webpush-options-plus-json {\n}\n\n/**Financially**/\n.mime-type-application-slash-AML,\n.mime-type-application-slash-ATF,\n.mime-type-application-slash-vnd-dot-tri-dot-onesource,\n.mime-type-application-slash-EDI-consent,\n.mime-type-application-slash-EDIFACT,\n.mime-type-application-slash-EDI-X12,\n.mime-type-application-slash-vnd-dot-intu-dot-qfx,\n.mime-type-application-slash-vnd-dot-intu-dot-qbo {\n}\n\n/**Demo**/\n.mime-type-application-slash-ATFX {\n}\n\n/**tests**/\n.mime-type-application-slash-atomsvc-plus-xml,\n.mime-type-application-slash-provenance-plus-xml {\n}\n\n/**Authentication**/\n.mime-type-application-slash-auth-policy-plus-xml,\n.mime-type-application-slash-tnauthlist,\n.mime-type-application-slash-ocsp-request,\n.mime-type-application-slash-ocsp-response,\n.mime-type-application-slash-samlassertion-plus-xml,\n.mime-type-application-slash-samlmetadata-plus-xml {\n}\n\n/**Cloud**/\n.mime-type-application-slash-vnd-dot-firemonkeys-dot-cloudcell,\n.mime-type-application-slash-cdmi-capability,\n.mime-type-application-slash-cdmi-container,\n.mime-type-application-slash-cdmi-domain,\n.mime-type-application-slash-cdmi-object,\n.mime-type-application-slash-cdmi-queue,\n.mime-type-application-slash-scim-plus-json,\n.mime-type-application-slash-vnd-dot-eszigno3-plus-xml {\n\n}\n\n/**Configuration**/\n.mime-type-application-slash-vnd-dot-nokia-dot-iptv-dot-config-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-settings-plus-xml,\n.mime-type-application-slash-vnd-dot-cluetrust-dot-cartomobile-config-pkg,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-settings-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-webSettings-plus-xml,\n.mime-type-application-slash-vnd-dot-cluetrust-dot-cartomobile-config,\n.mime-type-application-slash-vnd-dot-coreos-dot-ignition-plus-json,\n.mime-type-application-slash-coap-group-plus-json,\n.mime-type-application-slash-coap-payload,\n.mime-type-application-slash-poc-settings-plus-xml,\n.mime-type-application-slash-vnd-dot-onepagertat,\n.mime-type-application-slash-vnd-dot-wt-dot-stf {\n}\n\n/**Security**/\n.mime-type-application-slash-cwt,\n.mime-type-application-slash-vnd-dot-ms-playready-dot-initiator-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-cspg-hexbinary,\n.mime-type-application-slash-voucher-cms-plus-json,\n.mime-type-application-slash-vnd-dot-miele-plus-json,\n.mime-type-application-slash-vnd-dot-ipunplugged-dot-rcprofile,\n.mime-type-application-slash-vnd-dot-oma-dot-scidm-dot-messages-plus-xml,\n.mime-type-application-slash-vnd-dot-mitsubishi-dot-misty-guard-dot-trustweb,\n.mime-type-application-slash-vnd-dot-ctc-posml {\n}\n\n/**Visioning/Distribution authoring**/\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-commentAuthors-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-userNames-plus-xml,\n.mime-type-application-slash-davmount-plus-xml {\n}\n\n/**Medical**/\n.mime-type-application-slash-vnd-dot-bint-dot-med-content,\n.mime-type-application-slash-dicom,\n.mime-type-application-slash-dicom-plus-json,\n.mime-type-application-slash-dicom-plus-xml,\n.mime-type-application-slash-fhir-plus-json,\n.mime-type-application-slash-fhir-plus-xml,\n.mime-type-application-slash-vnd-dot-MFER,\n.mime-type-application-slash-vnd-dot-piaccess-dot-application-licence,\n.mime-type-application-slash-vnd-dot-apothekende-dot-reservation-plus-json\n.mime-type-application-slash-vnd-dot-novadigm-dot-EDM,\n.mime-type-application-slash-vnd-dot-novadigm-dot-EDX,\n.mime-type-application-slash-vnd-dot-novadigm-dot-EXT\n{\n\n}\n\n/**Input/Output**/\n.mime-type-application-slash-nlsml-plus-xml,\n.mime-type-application-slash-emma-plus-xml,\n.mime-type-application-slash-pls-plus-xml,\n.mime-type-application-slash-vnd-dot-chipnuts-dot-karaoke-mmd,\n.mime-type-application-slash-kpml-request-plus-xml,\n.mime-type-application-slash-kpml-response-plus-xml,\n.mime-type-application-slash-inkml-plus-xml {\n\n}\n\n/**E-Book**/\n.mime-type-application-slash-epub-plus-zip,\n.mime-type-application-slash-vnd-dot-amazon-dot-mobi8-ebook {\n}\n\n/**Remote-Control**/\n.mime-type-application-slash-urc-uisocketdesc-plus-xml,\n.mime-type-application-slash-vnd-dot-ntt-local-dot-ogw_remote-access,\n.mime-type-application-slash-H224,\n.mime-type-application-slash-vnd-dot-oma-scws-config,\n.mime-type-application-slash-vnd-dot-oma-scws-http-request,\n.mime-type-application-slash-vnd-dot-oma-scws-http-response,\n.mime-type-application-slash-vnd-dot-globalplatform-dot-card-content-mgt,\n.mime-type-application-slash-vnd-dot-globalplatform-dot-card-content-mgt-response,\n.mime-type-application-slash-vnd-dot-ntt-local-dot-sip-ta_remote {\n}\n\n/**Encryption/Cryptography**/\n.mime-type-application-slash-mosskey-data,\n.mime-type-application-slash-mosskey-request,\n.mime-type-application-slash-vnd-dot-airzip-dot-filesecure-dot-azf,\n.mime-type-application-slash-vnd-dot-airzip-dot-filesecure-dot-azs,\n.mime-type-application-slash-ibe-key-request-plus-xml,\n.mime-type-application-slash-pgp-encrypted,\n.mime-type-application-slash-pkcs10,\n.mime-type-application-slash-pkcs7-mime,\n.mime-type-application-slash-pkcs8-encrypted,\n.mime-type-application-slash-pkcs12,\n.mime-type-application-slash-cose,\n.mime-type-application-slash-ibe-key-request-plus-xml,\n.mime-type-application-slash-ibe-pkg-reply-plus-xml,\n.mime-type-application-slash-ibe-pp-data,\n.mime-type-application-slash-vnd-dot-pawaafile {\n}\n\n/**MetaData**/\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-sheetMetadata-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-styles-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-slideUpdateInfo-plus-xml,\n.mime-type-application-slash-mets-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-revisionHeaders-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-revisionHeaders-plus-xml,\n.mime-type-application-slash-metalink4-plus-xml,\n.mime-type-application-slash-MF4,\n.mime-type-application-slash-ttml-plus-xml,\n.mime-type-application-slash-tve-trigger,\n.mime-type-application-slash-vnd-dot-datapackage-plus-json,\n.mime-type-application-slash-vnd-dot-dataresource-plus-json,\n.mime-type-application-slash-vnd-dot-shana-dot-informed-dot-package,\n.mime-type-application-slash-ATF,\n.mime-type-application-slash-mods-plus-xml,\n.mime-type-application-slash-vnd-dot-dataresource-plus-json,\n.mime-type-application-slash-rlmi-plus-xml,\n.mime-type-application-slash-fits,\n.mime-type-application-slash-mods-plus-xml,\n.mime-type-application-slash-vnd-dot-netfpx,\n.mime-type-application-slash-mads-plus-xml,\n.mime-type-application-slash-marcxml-plus-xml,\n.mime-type-application-slash-marc,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-custom-properties-plus-xml,\n.mime-type-application-slash-mads-plus-xml {\n\n}\n\n/**Json**/\n.mime-type-application-slash-json,\n.mime-type-application-slash-json-patch-plus-json,\n.mime-type-application-slash-jose,\n.mime-type-application-slash-jose-plus-json,\n.mime-type-application-slash-jrd-plus-json,\n.mime-type-application-slash-json-seq,\n.mime-type-application-slash-ld-plus-json {\n}\n\n\n/* ToDo */\n/*ERROR+CORRECTION+TESTING*/\n/*parity encoding for RTP*/\n.mime-type-application-slash-parityfec,\n    /*general framework*/\n    /*Forward Error Correction*/\n.mime-type-application-slash-raptorfec,\n    /*Raptor Forward Error Correction Scheme*/\n.mime-type-text-slash-raptorfec, /* text/raptorfec */\n    /*tlsrpt*/\n    /*sending systems can share statistics and specific information about potential failures with recipient domains*/\n    /*detect potential attacks and diagnose unintentional misconfigurations*/\n.mime-type-application-slash-tlsrpt-plus-gzip,\n.mime-type-application-slash-tlsrpt-plus-json,\n.mime-type-application-slash-vnd-dot-bbf-dot-usp-dot-msg-plus-json,\n    /*Protocol*/\n    /*Signaling, Delivery, Synchronization, and Error Protection*/\n.mime-type-application-slash-route-apd-plus-xml,\n.mime-type-application-slash-route-s-tsid-plus-xml,\n.mime-type-application-slash-route-usd-plus-xml,\n    /*Signaling, Delivery, Synchronization, and Error Protection*/\n.mime-type-application-slash-mmt-usd-plus-xml,\n    /*1-D Interleaved Parity FEC Scheme for FEC Framework*/\n.mime-type-application-slash-1d-interleaved-parityfec,\n    /*The RTP payload format for generic forward error correction allows RTP participants to\n     improve loss resiliency through the use of traditional parity-based channel codes*/\n.mime-type-text-slash-parityfec {\n}\n\n/**Keys**/\n.mime-type-application-slash-moss-keys,\n.mime-type-application-slash-dskpp-plus-xml,\n.mime-type-application-slash-pgp-keys,\n.mime-type-application-slash-pkcs8,\n.mime-type-application-slash-rpki-ghostbusters,\n.mime-type-application-slash-rpki-manifest,\n.mime-type-application-slash-rpki-publication,\n.mime-type-application-slash-rpki-roa,\n.mime-type-application-slash-rpki-updown,\n.mime-type-application-slash-vnd-dot-contact-dot-cmsg,\n.mime-type-application-slash-vnd-dot-oma-dot-bcast-dot-ltkm,\n.mime-type-application-slash-cose-key,\n.mime-type-application-slash-cose-key-set,\n.mime-type-application-slash-pskc-plus-xml,\n.mime-type-application-slash-jwk-plus-json,\n.mime-type-application-slash-jwk-set-plus-json {\n}\n\n/**Signature**/\n.mime-type-application-slash-vnd-dot-openxmlformats-package-dot-digital-signature-xmlsignature-plus-xml,\n.mime-type-application-slash-moss-signature,\n.mime-type-application-slash-vnd-dot-3gpp-dot-mcptt-signed-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-asic-s-plus-zip,\n.mime-type-application-slash-vnd-dot-etsi-dot-asic-e-plus-zip,\n.mime-type-application-slash-vnd-dot-etsi-dot-tsl-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-tsl-dot-der,\n.mime-type-application-slash-vnd-dot-etsi-dot-simservs-plus-xml,\n.mime-type-application-slash-pgp-signature,\n.mime-type-application-slash-pkcs7-signature,\n.mime-type-application-slash-pkix-pkipath,\n.mime-type-application-slash-QSIG {\n}\n\n/**Cretificate**/\n.mime-type-application-slash-pkixcmp,\n.mime-type-application-slash-pkix-attr-cert,\n.mime-type-application-slash-pkix-cert,\n.mime-type-application-slash-pkix-crl,\n.mime-type-application-slash-scvp-cv-request,\n.mime-type-application-slash-scvp-cv-response,\n.mime-type-application-slash-scvp-vp-request,\n.mime-type-application-slash-scvp-vp-response {\n}\n\n/**Error**/\n.mime-type-application-slash-problem-plus-json,\n.mime-type-application-slash-problem-plus-xml,\n.mime-type-application-slash-tamp-error,\n.mime-type-application-slash-alto-error-plus-json,\n.mime-type-application-slash-vnd-dot-mason-plus-json {\n}\n\n/**Token**/\n.mime-type-application-slash-vnd-dot-etsi-dot-timestamp-token,\n.mime-type-application-slash-secevent-plus-jwt,\n.mime-type-application-slash-secevent-plus-jwt {\n}\n\n/**Logging**/\n.mime-type-application-slash-vnd-dot-webturbo,\n.mime-type-application-slash-senml-exi,\n.mime-type-application-slash-senml-plus-cbor,\n.mime-type-application-slash-senml-plus-json,\n.mime-type-application-slash-senml-plus-xml,\n.mime-type-application-slash-sensml-exi,\n.mime-type-application-slash-sensml-plus-cbor,\n.mime-type-application-slash-sensml-plus-json,\n.mime-type-application-slash-sensml-plus-xml,\n.mime-type-application-slash-ODX {\n}\n\n/**Managemant**/\n.mime-type-application-slash-vnd-dot-bbf-dot-usp-dot-msg,\n.mime-type-application-slash-tamp-apex-update,\n.mime-type-application-slash-tamp-apex-update-confirm,\n.mime-type-application-slash-tamp-community-update,\n.mime-type-application-slash-tamp-community-update-confirm,\n.mime-type-application-slash-tamp-sequence-adjust,\n.mime-type-application-slash-tamp-sequence-adjust-confirm,\n.mime-type-application-slash-tamp-status-query,\n.mime-type-application-slash-tamp-status-response,\n.mime-type-application-slash-tamp-update,\n.mime-type-application-slash-tamp-update-confirm,\n.mime-type-application-slash-vnd-dot-motorola-dot-iprm,\n.mime-type-application-slash-vnd-dot-ibm-dot-rights-management\n.mime-type-application-slash-encaprtp,\n.mime-type-application-slash-rtploopback,\n.mime-type-application-slash-scaip-plus-xml,\n.mime-type-application-slash-vnd-dot-fdsn-dot-mseed,\n.mime-type-application-slash-vnd-dot-fdsn-dot-seed,\n.mime-type-application-slash-vnd-dot-1000minds-dot-decision-model-plus-xml,\n.mime-type-application-slash-vnd-dot-meridian-slingshot,\n.mime-type-application-slash-vq-rtcpxr {\n}\n\n/**API**/\n.mime-type-application-slash-vnd-dot-amadeus-plus-json,\n.mime-type-application-slash-vnd-dot-byu-dot-uapi-plus-json,\n.mime-type-text-slash-vnd-dot-curl,\n.mime-type-application-slash-vnd-dot-tmd-dot-mediaflex-dot-api-plus-xml,\n.mime-type-application-slash-taxii-plus-json,\n.mime-type-application-slash-vnd-dot-avalon-plus-json,\n.mime-type-application-slash-vnd-dot-restful-plus-json,\n.mime-type-application-slash-vnd-dot-micro-plus-json,\n.mime-type-application-slash-vnd-dot-pagerduty-plus-json,\n.mime-type-application-slash-vnd-dot-artsquare,\n.mime-type-application-slash-vnd-dot-oma-dot-xcap-directory-plus-xml {\n\n}\n\n/**Timestamp**/\n.mime-type-application-slash-timestamp-query,\n.mime-type-application-slash-timestamp-reply,\n.mime-type-application-slash-timestamped-data,\n.mime-type-application-slash-ulpfec {\n}\n\n/**Profiles-Person**/\n.mime-type-text-slash-Name,\n.mime-type-application-slash-passport,\n.mime-type-application-slash-vnd-dot-oma-dot-cab-user-prefs-plus-xml,\n.mime-type-application-slash-session-info,\n.mime-type-application-slash-vnd-dot-frogans-dot-fnc,\n.mime-type-application-slash-vnd-dot-frogans-dot-ltf,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvprofile-plus-xml,\n.mime-type-application-slash-vnd-dot-etsi-dot-iptvueprofile-plus-xml,\n.mime-type-text-slash-vcard,\n.mime-type-application-slash-vnd-dot-oipf-dot-ueprofile-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-userprofile-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-pae-dot-gem,\n.mime-type-application-slash-vnd-dot-oipf-dot-spdiscovery-plus-xml,\n.mime-type-application-slash-vnd-dot-oipf-dot-spdlist-plus-xml,\n.mime-type-application-slash-vnd-dot-espass-espass-plus-zip {\n}\n\n/**Profiles**/\n.mime-type-application-slash-vnd-dot-evolv-dot-ecig-dot-profile,\n.mime-type-application-slash-vcard-plus-json,\n.mime-type-application-slash-vcard-plus-xml,\n.mime-type-application-slash-vnd-dot-lotus-freelance,\n.mime-type-application-slash-vnd-dot-lotus-approach,\n.mime-type-application-slash-vnd-dot-lotus-1-2-3,\n.mime-type-application-slash-vnd-dot-lotus-notes,\n.mime-type-application-slash-vnd-dot-lotus-organizer,\n.mime-type-application-slash-vnd-dot-lotus-screencam,\n.mime-type-application-slash-vnd-dot-lotus-wordpro,\n.mime-type-application-slash-vnd-dot-Mobius-dot-DAF,\n.mime-type-application-slash-vnd-dot-Mobius-dot-DIS,\n.mime-type-application-slash-vnd-dot-Mobius-dot-MBK,\n.mime-type-application-slash-vnd-dot-Mobius-dot-MQY,\n.mime-type-application-slash-vnd-dot-Mobius-dot-MSL,\n.mime-type-application-slash-vnd-dot-Mobius-dot-PLC,\n.mime-type-application-slash-vnd-dot-Mobius-dot-TXF {\n}\n\n/**Profiles-Product**/\n.mime-type-application-slash-provenance-plus-xml,\n.mime-type-application-slash-PDX {\n}\n\n/**Notes**/\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-notesMaster-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-notesSlide-plus-xml,\n.mime-type-application-slash-vnd-dot-3M-dot-Post-it-Notes,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-footnotes-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-endnotes-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-handoutMaster-plus-xml {\n}\n\n/**Accounting**/\n.mime-type-application-slash-vnd-dot-banana-accounting,\n.mime-type-application-slash-vnd-dot-accpac-dot-simply-dot-aso,\n.mime-type-application-slash-vnd-dot-accpac-dot-simply-dot-imp,\n.mime-type-application-slash-vnd-dot-gov-dot-sk-dot-e-form-plus-xml,\n.mime-type-application-slash-vnd-dot-gov-dot-sk-dot-e-form-plus-zip,\n.mime-type-application-slash-vnd-dot-gov-dot-sk-dot-xmldatacontainer-plus-xml {\n}\n\n/**Financial-Transaction**/\n.mime-type-application-slash-vnd-dot-fints {\n}\n\n/**Exchange/Transport/Export/Import**/ /*todo add*/\n.mime-type-application-slash-vnd-dot-adobe-dot-fxp,\n    /*general purpose format for transferring AmigaDE content to Amiga enabled devices*/\n.mime-type-application-slash-vnd-dot-amiga-dot-ami,\n    /*Profille*/\n.mime-type-application-slash-vnd-dot-evolv-dot-ecig-dot-settings,\n.mime-type-application-slash-vnd-dot-evolv-dot-ecig-dot-settings,\n.mime-type-application-slash-vnd-dot-evolv-dot-ecig-dot-theme,\n    /*OMA DS*/\n    /*exchange of file*/\n.mime-type-application-slash-vnd-dot-omads-file-plus-xml,\n    /*exchange of folder object */\n.mime-type-application-slash-vnd-dot-omads-folder-plus-xml,\n    /*exchange messages*/\n.mime-type-application-slash-vnd-dot-omaloc-supl-init,\n    /*shana informed interchange*/\n.mime-type-application-slash-vnd-dot-shana-dot-informed-dot-interchange,\n    /*standardize the way localizable data are passed between tools*/\n.mime-type-application-slash-xliff-plus-xml,\n    /*Wang Information Transfer Architecture*/\n.mime-type-application-slash-wita,\n    /*transferring delta files with the Safe Transfer-ASM product*/\n.mime-type-application-slash-vnd-dot-sss-dtf,\n    /*for the use and exchange of digital data*/\n.mime-type-application-slash-CALS-1840,\n    /*EST client requests a list of CA-desired CSR attributes from the CA by sending an HTTPS GET message to the EST server*/\n.mime-type-application-slash-csrattrs,\n    /*Presence Information Data Format*/\n    /*transporting of either only the changed parts or the full PIDF-based presence information*/\n.mime-type-application-slash-pidf-diff-plus-xml,\n    /*entity that contains presence information*/\n.mime-type-application-slash-pidf-plus-xml,\n    /*used to carry information between the SPIRITS client and server*/\n.mime-type-application-slash-spirits-event-plus-xml,\n    /*transparent transport in SIP of ISDN messages and ISDN */\n.mime-type-application-slash-vnd-dot-cirpack-dot-isdn-ext,\n    /*exporting and importing D2L Brightspace course data*/\n.mime-type-application-slash-vnd-dot-d2l-dot-coursepackage1p0-plus-zip,\n    /*application communicating with Smart Delivery*/\n.mime-type-application-slash-vnd-dot-ffsns,\n    /*This content type is used to define messages that are exchanged between OMA IMPS Clients and Servers.*/\n.mime-type-application-slash-vnd-dot-wv-dot-csp-plus-xml,\n.mime-type-application-slash-vnd-dot-wv-dot-csp-plus-wbxml,\n    /*Digital Document Transmission (DX)*/\n.mime-type-application-slash-dec-dx,\n    /*intended to be consumed and produced solely by Blink*/\n.mime-type-application-slash-vnd-dot-blink-idb-value-wrapper,\n    /*Packages are used for transporting documents between the Lucidoc server and the Lucidoc Editor*/\n.mime-type-application-slash-vnd-dot-irepository-dot-package-plus-xml,\n    /*convey information of the current ISDN system via NGN network*/\n.mime-type-application-slash-vnd-dot-jsk-dot-isdn-ngn,\n    /*general purpose format for transferring AmigaDE content to Amiga enabled devices*/\n.mime-type-application-slash-vnd-dot-amiga-dot-ami,\n    /*use Nimn data format to exchange data between same or two different applications*/\n.mime-type-application-slash-vnd-dot-nimn,\n    /*File transfer application on information device*/\n.mime-type-application-slash-vnd-dot-ntt-local-dot-sip-ta_tcp_stream,\n    /*File transfer application on information device*/\n.mime-type-application-slash-vnd-dot-ntt-local.file-transfer,\n    /*The Atom \"deleted-entry\" Element. Atom ermöglicht den plattformunabhängigen Austausch von Informationen z. B. für Web-Feeds*/\n.mime-type-application-slash-atomdeleted-plus-xml,\n    /*National Imagery Transmission Format (NITFS)\n    is a U.S. Department of Defense (DoD) and Federal Intelligence Community (IC) suite of standards for the\n    exchange,storage, and transmission of digital-imagery products and image-related products */\n.mime-type-text-slash-vnd-dot-IPTC-dot-NITF {\n}\n\n/**Uploade**/\n.mime-type-application-slash-vnd-dot-adobe-dot-partial-upload,\n.mime-type-application-slash-x-www-form-urlencoded {\n}\n\n/**Download**/\n.mime-type-application-slash-vnd-dot-cosmocaller,\n.mime-type-application-slash-vnd-dot-oipf-dot-contentaccessdownload-plus-xml,\n.mime-type-application-slash-vnd-dot-ruckus-dot-download,\n.mime-type-application-slash-vnd-dot-oma-dot-dd2-plus-xml {\n}\n\n/**Frameworks**/\n.mime-type-application-slash-framework-attributes-plus-xml,\n.mime-type-application-slash-msc-ivr-plus-xml,\n.mime-type-application-slash-msc-mixer-plus-xml,\n.mime-type-application-slash-vnd-dot-apache-dot-thrift-dot-binary,\n.mime-type-application-slash-vnd-dot-apache-dot-thrift-dot-compact,\n.mime-type-application-slash-vnd-dot-apache-dot-thrift-dot-json,\n.mime-type-application-slash-vnd-dot-api-plus-json,\n.mime-type-application-slash-vnd-dot-osgi.subsystem {\n}\n\n/**Bluetooth**/\n.mime-type-application-slash-vnd-dot-bluetooth-dot-ep-dot-oob,\n.mime-type-application-slash-vnd-dot-bluetooth-dot-le-dot-oob {\n}\n\n/**Education**/\n.mime-type-application-slash-vnd-dot-hhe-dot-lesson-player,\n.mime-type-application-slash-vnd-dot-smart-dot-notebook,\n.mime-type-application-slash-vnd-dot-smart-dot-teacher,\n.mime-type-application-slash-vnd-dot-crick-dot-clicker,\n.mime-type-application-slash-vnd-dot-crick-dot-clicker-dot-keyboard,\n.mime-type-application-slash-vnd-dot-crick-dot-clicker-dot-palette,\n.mime-type-application-slash-vnd-dot-crick-dot-clicker-dot-wordbank,\n.mime-type-application-slash-vnd-dot-geogebra-dot-tool,\n.mime-type-application-slash-vnd-dot-vd-study,\n.mime-type-application-slash-vnd-dot-RenLearn-dot-rlprint,\n.mime-type-application-slash-tei-plus-xml,\n.mime-type-application-slash-vnd-dot-ms-ims,\n.mime-type-application-slash-vnd-dot-ms-lrm,\n.mime-type-application-slash-vnd-dot-olpc-sugar,\n.mime-type-application-slash-vnd-dot-anki,\n.mime-type-application-slash-vnd-dot-kahootz,\n.mime-type-application-slash-vnd-dot-quobject-quoxdocument,\n.mime-type-application-slash-vnd-dot-neurolanguage-dot-nlu,\n.mime-type-application-slash-vnd-dot-ims-dot-lti-dot-v2.toolconsumerprofile-plus-json,\n.mime-type-application-slash-vnd-dot-ims-dot-lti-dot-v2-dot-toolproxy.id-plus-json,\n.mime-type-application-slash-vnd-dot-ims-dot-lti-dot-v2-dot-toolproxy-plus-json,\n.mime-type-application-slash-vnd-dot-ims-dot-lti-dot-v2-dot-toolsettings-plus-json,\n.mime-type-application-slash-vnd-dot-ims-dot-lti-dot-v2-dot-toolsettings-dot-simple-plus-json {\n}\n\n/**money**/\n.mime-type-application-slash-vnd-dot-rig-dot-cryptonote,\n.mime-type-application-slash-vnd-dot-ecip-dot-rlp,\n.mime-type-application-slash-vnd-dot-claymore {\n}\n\n/*todo\n\n */\n\n/*undefined*/\n.mime-type-application-slash-vnd-dot-msign,\n.mime-type-application-slash-vnd-dot-cyan-dot-dean-dot-root-plus-xml,\n.mime-type-application-slash-vnd-dot-tml,\n.mime-type-application-slash-vnd-dot-ctct-dot-ws-plus-xml,\n.mime-type-application-slash-vnd-dot-cyan-dot-dean-dot-root-plus-xml,\n.mime-type-application-slash-vnd-dot-bekitzur-stech-plus-json,\n.mime-type-text-slash-vnld-dot-radisys-dot-msml-basic-layout,\n.mime-type-text-slash-vnd-dot-trolltech-dot-linguist,\n.mime-type-text-slash-vnd-dot-si-dot-uricatalogue,\n.mime-type-text-slash-vnd-dot-latex-z,\n.mime-type-text-slash-vnd-dot-sun-dot-j2me-dot-app-descriptor,\n.mime-type-text-slash-mizar,\n.mime-type-text-slash-parameters,\n.mime-type-text-slash-provenance-notation,\n.mime-type-text-slash-prs-dot-fallenstein-dot-rst,\n.mime-type-text-slash-prs-dot-prop-dot-logic,\n.mime-type-text-slash-vnd-dot-fmi-dot-flexstor,\n.mime-type-application-slash-vnd-dot-enphase-dot-envoy,\n.mime-type-application-slash-vnd-dot-hcl-bireports,\n.mime-type-application-slash-vnd-dot-kenameaapp,\n.mime-type-application-slash-vnd-dot-kodak-descriptor,\n.mime-type-application-slash-vnd-dot-oxli-dot-countgraph,\n.mime-type-application-slash-vnd-dot-preminet,\n.mime-type-application-slash-vnd-dot-rapid,\n.mime-type-application-slash-vnd-dot-capasystems-pg-plus-json,\n.mime-type-application-slash-vnd-dot-cendio-dot-thinlinc-dot-clientconf,\n.mime-type-application-slash-vnd-dot-century-systems-dot-tcp_stream,\n.mime-type-application-slash-vnd-dot-zzazz-dot-deck-plus-xml,\n.mime-type-application-slash-vnd-dot-data-vision-dot-rdz,\n.mime-type-application-slash-fastsoap,\n.mime-type-application-slash-cccex,\n.mime-type-text-slash-fwdred,\n.mime-type-text-slash-grammar-ref-list,\n.mime-type-application-slash-vnd-dot-trid-dot-tpt,\n.mime-type-application-slash-vnd-dot-yamaha-dot-through-ngn,\n.mime-type-application-slash-cea-2018-plus-xml,\n.mime-type-application-slash-vnd-dot-nokia-dot-conml-plus-wbxml,\n.mime-type-application-slash-vnd-dot-nokia-dot-conml-plus-xml,\n.mime-type-application-slash-vnd-dot-onepagertatp,\n.mime-type-application-slash-vnd-dot-onepagertatx,\n.mime-type-application-slash-vnd-dot-Kinar,\n.mime-type-application-slash-vnd-dot-dtg-dot-local,\n.mime-type-application-slash-vnd-dot-heroku-plus-json,\n.mime-type-application-slash-vnd-dot-ims-dot-lis.v2.result-plus-json,\n.mime-type-application-slash-vnd-dot-oma-dot-dcdc,\n    /*todo ? lookup again*/\n.mime-type-application-slash-reputon-plus-json,\n.mime-type-application-slash-vnd-dot-qualcomm-dot-brew-app-res,\n.mime-type-application-slash-vnd-dot-quarantainenet,\n.mime-type-application-slash-vnd-dot-informedcontrol-dot-rms-plus-xml,\n    /*proprietary to Nokia*/\n.mime-type-application-slash-vnd-dot-nokia-dot-ncd,\n.mime-type-application-slash-vnd-dot-ncd-dot-control,\n.mime-type-application-slash-vnd-dot-ncd-dot-reference,\n    /*InterTrust Technologies Corporation*/\n.mime-type-application-slash-vnd-dot-intertrust-dot-digibox,\n.mime-type-application-slash-vnd-dot-intertrust-dot-nncp,\n    /*content-type provides a mechanism for representing a compound object,\n     such as a text document with two gif images.\n\n    A compound object consists of multiple components. One such\n    component is the root component, which contains references to other\n    components of the compound object.  These components may, in turn,\n    contain references to other components of the compound object*/\n.mime-type-application-slash-vnd-dot-pwg-multiplexed,\n    /*Web browser based client for Financial Plate*/\n.mime-type-application-slash-vnd-dot-dir-bi-dot-plate-dl-nosuffix,\n    /*could be a reference*/\n    /*intended to act as a hyperlink in web documents, since from the user's perspective, clicking on a link to a\nfile of this type will run Dream Seeker and connect it to the target site*/\n.mime-type-text-slash-vnd-dot-DMClientScript,\n\n    /*exchange of fraud intelligence data.*/\n.mime-type-application-slash-thraud-plus-xml,\n    /*solely by the UD Grid MP product between the MP Agent and the Grid MP services*/\n.mime-type-application-slash-vnd-dot-gridmp,\n    /**/\n.mime-type-application-slash-vnd-dot-fujixerox-dot-ddd,\n.mime-type-application-slash-vnd-dot-fujixerox-dot-docuworks,\n.mime-type-application-slash-vnd-dot-fujixerox-dot-docuworks-dot-binder,\n.mime-type-application-slash-vnd-dot-fujixerox-dot-docuworks-dot-container,\n.mime-type-application-slash-vnd-dot-fujixerox-dot-HBPL,\n    /*deca*/\n.mime-type-application-slash-vnd-dot-dece-dot-data,\n.mime-type-application-slash-vnd-dot-dece-dot-ttml-plus-xml,\n.mime-type-application-slash-vnd-dot-dece-dot-unspecified,\n.mime-type-application-slash-vnd-dot-dece-dot-zip,\n    /*FCS Express*/\n.mime-type-application-slash-vnd-dot-denovo-dot-fcselayout-link,\n    /*games*/\n.mime-type-application-slash-vnd-dot-hzn-3d-crossword,\n.mime-type-application-slash-vnd-dot-fsc-dot-weblaunch,\n.mime-type-application-slash-vnd-dot-stepmania-dot-package,\n.mime-type-application-slash-vnd-dot-stepmania-dot-stepchart,\n.mime-type-application-slash-vnd-dot-solent-dot-sdkm-plus-xml,\n.mime-type-application-slash-vnd-dot-stepmania-dot-package,\n.mime-type-application-slash-vnd-dot-stepmania-dot-stepchart,\n.mime-type-application-slash-vnd-dot-valve-dot-source-dot-material,\n.mime-type-application-slash-vnd-dot-amundsen-dot-maze-plus-xml,\n.mime-type-application-slash-vnd-dot-antix-dot-game-component,\n.mime-type-application-slash-vnd-dot-igloader,\n.mime-type-application-slash-vnd-dot-mophun-dot-application,\n.mime-type-application-slash-vnd-dot-mophun-dot-certificate,\n.mime-type-application-slash-vnd-dot-chess-pgn,\n.mime-type-application-slash-vnd-dot-openblox-dot-game-binary,\n.mime-type-application-slash-vnd-dot-openblox-dot-game-plus-xml,\n.mime-type-application-slash-vnd-dot-ubisoft-dot-webplayer,\n.mime-type-application-slash-vnd-dot-pocketlearn,\n    /*Movies are recorded key presses for playing video games automatically.*/\n.mime-type-application-slash-vnd-dot-desmume-dot-movie,\n    /*Clonk Game*/\n.mime-type-application-slash-vnd-dot-clonk-dot-c4group,\n    /*gamme engine*/\n.mime-type-application-slash-vnd-dot-unity,\n    /*Antenna House Formatter to specify a barcode data*/\n.mime-type-application-slash-vnd-dot-ah-barcode,\n    /*Gerber-Format ist eine Standard-Dateistruktur im ASCII-Format, die den Datenaustausch zwischen CAD (Entwicklung) und CAM (Produktion) ermöglicht.\n     Es wird vor allem im Bereich von elektronischen CAD-Programmen (EDA – Electronic Design Automation) zur Ausgabe der Layoutdaten bei Leiterplatten verwendet.*/\n.mime-type-application-slash-vnd-dot-rs-274x,\n    /*N-Gage von Nokia ist ein Smartphone mit eingebauter Spielkonsole*/\n.mime-type-application-slash-vnd-dot-nokia-dot-n-gage-dot-ac-plus-xml,\n.mime-type-application-slash-vnd-dot-nokia-dot-n-gage-dot-data,\n.mime-type-application-slash-vnd-dot-nokia-dot-n-gage-dot-symbian-dot-install,\n    /*Neural Network Processors*/\n.mime-type-application-slash-vnd-dot-nervana,\n    /*nintendo rom=Read-Only Memory*/\n.mime-type-application-slash-vnd-dot-nintendo-dot-snes-dot-rom,\n.mime-type-application-slash-vnd-dot-nintendo-dot-nitro-dot-rom,\n    /*Three-dimensional model created by LEGO Digital Designer (LDD)*/\n.mime-type-application-slash-LXF,\n    /*Kidspiration*/\n.mime-type-application-slash-vnd-dot-kidspiration,\n    /*OSGi Deployment Package*/\n.mime-type-application-slash-vnd-dot-osgi-dot-dp,\n    /*attempt to bring some of the advantages of these vocabulary aware specifications under a standard vocabulary from [microformats2]*/\n.mime-type-application-slash-jf2feed-plus-json,\n    /*Intercon FormNet files are intended for use only by Intercon FormNet WebMaker\n     (the  \"design\" tool) and Intercon FormNet Surfer (a Netscape Navigator-compatible plug-in)*/\n.mime-type-application-slash-vnd-dot-intercon-dot-formnet,\n    /*Tariff Information shall identify the payload*/\n.mime-type-application-slash-vnd-dot-etsi-dot-sci-plus-xml,\n    /*Proprietary Proctor & Gamble Standard Reporting System.*/\n.mime-type-application-slash-vnd-dot-pg-dot-format,\n.mime-type-application-slash-vnd-dot-pg-dot-osasli,\n    /*Kidspiration Activity (Inspiration Software Inc.)*/\n.mime-type-application-slash-vnd-dot-kidspiration,\n    /*vertical systems supporting transportation construction ?*/\n.mime-type-application-slash-vnd-dot-infotech-dptproject, /* todo check dbt*/\n.mime-type-application-slash-vnd-dot-infotech-dptproject-plus-xml,\n    /*HDT is a binary format that represents RDF Data in a compact manner*/\n.mime-type-application-slash-vnd-dot-hdt,\n    /*Digital Xpress Reports (DXR) and Digital Xpress Reports-Unified Viewer(DXR-UV).*/\n.mime-type-application-slash-vnd-dot-dxr {\n}\n\n/**GUI**/\n.mime-type-application-slash-vnd-dot-scribus,\n.mime-type-application-slash-vnd-dot-yellowriver-custom-menu,\n.mime-type-application-slash-vnd-dot-mozilla-dot-xul-plus-xml,\n.mime-type-application-slash-vnd-dot-hydrostatix-dot-sof-data,\n.mime-type-application-slash-vnd-dot-hyper-item-plus-json,\n.mime-type-application-slash-vnd-dot-hyper-plus-json {\n\n}\n\n/**Template/Theme**/\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-chart-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-spreadsheet-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-presentation-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-text-template,\n.mime-type-application-slash-vnd-dot-msword-dot-template-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-image-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-graphics-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-formula-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-graphics-template,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-spreadsheet-template,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-template,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-template-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-presentation-template,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-template,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-template-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-chart-template,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-template,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-template-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-ms-powerpoint-dot-template-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-groove-tool-template,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-template,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-template,\n.mime-type-application-slash-vnd-dot-crick-dot-clicker-dot-template,\n.mime-type-application-slash-vnd-dot-commonspace,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-wordprocessingml-dot-template-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-collabio-dot-xodocuments-dot-document-template,\n.mime-type-application-slash-vnd-dot-collabio-dot-xodocuments-dot-presentation-template,\n.mime-type-application-slash-vnd-dot-collabio-dot-xodocuments-dot-spreadsheet-template,\n.mime-type-application-slash-vnd-dot-ms-word-dot-template-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-kde-dot-kspread,\n.mime-type-application-slash-fdt-plus-xml,\n.mime-type-application-slash-vnd-dot-ms-excel-dot-template-dot-macroEnabled-dot-12,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-template-dot-main-plus-xml,\n.mime-type-application-slash-vnd-dot-ms-officetheme,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-theme-plus-xml,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-themeOverride-plus-xml,\n.mime-type-application-slash-vnd-dot-uiq-dot-theme,\n.mime-type-application-slash-vnd-dot-shana-dot-informed-dot-formtemplate,\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-presentationml-dot-handoutMaster-plus-xml,\n.mime-type-text-slash-vnd-dot-esmertec-dot-theme-descriptor,\n.mime-type-application-slash-its-plus-xml {\n}\n\n/**Help-Documentation**/\n.mime-type-application-slash-vnd-dot-ms-htmlhelp,\n.mime-type-application-slash-vnd-dot-fdf {\n}\n\n/**Addressbook**/\n.mime-type-application-slash-vnd-dot-oma-dot-cab-address-book-plus-xml,\n.mime-type-application-slash-held-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-cab-feature-handler-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-cab-pcc-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-cab-subs-invite-plus-xml,\n.mime-type-application-slash-vnd-dot-oma-dot-cab-user-prefs-plus-xml {\n}\n\n/**Formual**/\n.mime-type-application-slash-vnd-dot-xfdl,\n.mime-type-application-slash-vnd-dot-xfdl-dot-webform,\n.mime-type-application-slash-atom-plus-xml,\n.mime-type-application-slash-vnd-dot-wqd,\n.mime-type-text-slash-prs-dot-lines-dot-tag {\n}\n\n/**Measurement**/\n.mime-type-application-slash-vnd-dot-sigrok-dot-session,\n.mime-type-application-slash-sieve,\n.mime-type-application-slash-A2L {\n}\n\n/**VM**/\n.mime-type-application-slash-vnd-dot-etsi-dot-mheg5,\n.mime-type-application-slash-vnd-dot-futoin-plus-cbor,\n.mime-type-application-slash-vnd-dot-futoin-plus-json,\n.mime-type-application-slash-vnd-dot-previewsystems-dot-box {\n}\n\n/**Example**/\n.mime-type-text-slash-example {\n}\n\n/**Math**/\n.mime-type-application-slash-vnd-dot-afpc-dot-modca,\n.mime-type-application-slash-cellml-plus-xml,\n.mime-type-application-slash-vnd-dot-oasis-dot-opendocument-dot-formula,\n.mime-type-application-slash-vnd-dot-geometry-explorer,\n.mime-type-application-slash-vnd-dot-zul,\n.mime-type-application-slash-vnd-dot-geocube-plus-xml,\n.mime-type-application-slash-vnd-dot-kde-dot-kformula,\n.mime-type-application-slash-vnd-dot-dpgraph,\n.mime-type-application-slash-vnd-dot-intergeo,\n.mime-type-application-slash-mathml-content-plus-xml,\n.mime-type-application-slash-mathml-plus-xml {\n}\n\n/**Biology**/\n.mime-type-application-slash-vnd-dot-medcalcdata,\n.mime-type-application-slash-vnd-dot-biopax-dot-rdf-plus-xml,\n.mime-type-application-slash-sbml-plus-xml {\n}\n\n/**DNS**/\n.mime-type-application-slash-dns,\n.mime-type-application-slash-dns-plus-json,\n.mime-type-application-slash-dns-message {\n}\n\n/**Group**/\n.mime-type-application-slash-vnd-dot-poc-dot-group-advertisement-plus-xml,\n.mime-type-application-slash-news-groupinfo,\n.mime-type-application-slash-vnd-dot-etsi-dot-aoc-plus-xml,\n.mime-type-application-slash-vnd-dot-fut-misnet,\n.mime-type-application-slash-coap-payload,\n.mime-type-application-slash-coap-group-plus-json,\n.mime-type-application-slash-coap-payload,\n.mime-type-application-slash-vnd-dot-etsi-dot-cug-plus-xml {\n}\n\n/**Resources**/\n.mime-type-application-slash-urc-ressheet-plus-xml,\n.mime-type-application-slash-vnd-dot-3gpp2-dot-bcmcsinfo-plus-xml-dot-bcmcsinfo-plus-xml,\n.mime-type-text-slash-uri-list,\n.mime-type-application-slash-vnd-dot-oracle-dot-resource-plus-json,\n.mime-type-application-slash-rfc-plus-xml,\n.mime-type-application-slash-mathematica,\n.mime-type-application-slash-watcherinfo-plus-xml,\n.mime-type-application-slash-link-format,\n.mime-type-application-slash-vnd-dot-leap-plus-json,\n.mime-type-application-slash-vnd-dot-oma-dot-group-usage-list-plus-xml,\n.mime-type-application-slash-rls-services-plus-xml {\n}\n\n/**Dependencies**/\n.mime-type-application-slash-vnd-dot-openxmlformats-officedocument-dot-spreadsheetml-dot-volatileDependencies-plus-xml {\n}\n\n/**Indexing**/\n.mime-type-application-slash-index,\n.mime-type-application-slash-index-dot-cmd,\n.mime-type-application-slash-index-dot-obj,\n.mime-type-application-slash-index-dot-response,\n.mime-type-application-slash-index-dot-vnd,\n.mime-type-application-slash-vnd-dot-citationstyles-dot-style-plus-xml {\n}\n\n/**Filter**/\n.mime-type-application-slash-simple-filter-plus-xml,\n.mime-type-application-slash-simple-filter-plus-xml {\n}\n\n/**Sealed**/\n.mime-type-application-slash-vnd-dot-sealed-dot-3df,\n.mime-type-application-slash-vnd-dot-sealed-dot-csf,\n.mime-type-application-slash-vnd-dot-sealed-dot-doc,\n.mime-type-application-slash-vnd-dot-sealed-dot-eml,\n.mime-type-application-slash-vnd-dot-sealed-dot-mht,\n.mime-type-application-slash-vnd-dot-sealed-dot-net,\n.mime-type-application-slash-vnd-dot-sealed-dot-ppt,\n.mime-type-application-slash-vnd-dot-sealed-dot-tiff,\n.mime-type-application-slash-vnd-dot-sealed-dot-xls,\n.mime-type-application-slash-vnd-dot-sealedmedia-dot-softseal-dot-html,\n.mime-type-application-slash-vnd-dot-noblenet-directory,\n.mime-type-application-slash-vnd-dot-noblenet-sealer,\n.mime-type-application-slash-vnd-dot-noblenet-web {\n}\n\n/**DRM**/\n.mime-type-application-slash-vnd-dot-ms-wmdrm-dot-lic-chlg-req,\n.mime-type-application-slash-vnd-dot-ms-wmdrm-dot-lic-resp,\n.mime-type-application-slash-vnd-dot-ms-wmdrm-dot-meter-chlg-req,\n.mime-type-application-slash-vnd-dot-ms-wmdrm-dot-meter-resp {\n}\n\n/**News**/\n.mime-type-application-slash-news-transmission,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-catalogitem-plus-xml,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-conceptitem-plus-xml,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-knowledgeitem-plus-xml,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-newsitem-plus-xml,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-newsmessage-plus-xml,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-packageitem-plus-xml,\n.mime-type-application-slash-vnd-dot-iptc-dot-g2-dot-planningitem-plus-xml {\n}\n", ""]);

// exports


/***/ }),
/* 1501 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.52 42.52' style='enable-background:new 0 0 42.52 42.52;' xmlns='http://www.w3.org/2000/svg' width='42.52' height='42.52'%3E %3Cg style='' transform='matrix(1.149095, 0, 0, 1.149095, -0.311634, -6.291357)'%3E %3Cpath d='M 6.949 35.612 L 9.246 35.612 C 9.697 35.612 10.107 35.602 10.466 35.572 C 10.825 35.542 11.184 35.492 11.543 35.422 C 11.902 35.352 12.21 35.252 12.476 35.132 C 12.743 35.013 12.989 34.853 13.215 34.663 C 13.44 34.473 13.625 34.243 13.768 33.973 C 13.912 33.703 14.025 33.393 14.107 33.033 C 14.189 32.673 14.23 32.263 14.23 31.803 C 14.23 31.553 14.219 31.273 14.199 30.963 C 14.199 30.933 14.189 30.883 14.178 30.803 C 14.168 30.723 14.158 30.663 14.158 30.623 C 14.158 30.553 14.178 30.503 14.219 30.453 C 14.26 30.403 14.312 30.383 14.384 30.383 C 14.455 30.383 14.527 30.423 14.578 30.503 C 14.609 30.543 14.64 30.593 14.671 30.653 C 14.701 30.713 14.732 30.783 14.763 30.853 C 14.794 30.933 14.824 30.983 14.835 31.013 C 15.429 32.303 15.717 33.333 15.717 34.083 C 15.717 34.983 15.594 35.742 15.347 36.352 C 14.599 38.182 12.558 39.092 9.246 39.092 L 6.949 39.092 M 3.35 37.662' style='' transform='matrix(-0.702704, 0.711483, -0.711483, -0.702704, 40.947855, 52.364746)'/%3E %3C/g%3E %3Cpath d='M 12.199 27.336 L 14.244 25.292 C 14.416 25.119 14.508 24.912 14.508 24.66 C 14.508 24.407 14.416 24.2 14.244 24.028 L 13.727 23.51 C 13.554 23.338 13.336 23.246 13.095 23.246 C 12.854 23.246 12.635 23.338 12.463 23.51 L 7.924 28.048 C 7.752 28.209 7.671 28.416 7.671 28.68 C 7.671 28.933 7.752 29.14 7.924 29.312 L 12.463 33.851 C 12.647 34.023 12.854 34.104 13.095 34.104 C 13.336 34.104 13.543 34.023 13.727 33.851 L 14.244 33.334 C 14.416 33.162 14.508 32.943 14.508 32.702 C 14.508 32.461 14.416 32.242 14.244 32.07 L 12.199 30.025' style='' transform='matrix(-0.702704, 0.711483, -0.711483, -0.702704, 39.283899, 40.935039)'/%3E %3C/svg%3E\""

/***/ }),
/* 1502 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath d='M 34.5 11.2 C 34.9 11.6 35.2 12 35.4 12.6 C 35.7 13.2 35.8 13.8 35.8 14.3 L 35.8 36.2 C 35.8 36.7 35.6 37.1 35.3 37.5 C 34.9 37.8 34.5 38 34 38 L 8.5 38 C 8 38 7.6 37.8 7.2 37.5 C 6.8 37.1 6.7 36.7 6.7 36.2 L 6.7 5.8 C 6.7 5.3 6.9 4.9 7.2 4.5 C 7.5 4.2 7.9 4 8.5 4 L 25.5 4 C 26 4 26.6 4.1 27.2 4.4 C 27.8 4.7 28.3 5 28.6 5.3 L 34.5 11.2 Z M 26.1 6.6 L 26.1 13.7 L 33.2 13.7 C 33.1 13.3 32.9 13.1 32.8 12.9 L 26.8 7 C 26.7 6.8 26.4 6.7 26.1 6.6 Z M 33.4 35.6 L 33.4 16.2 L 25.5 16.2 C 25 16.2 24.6 16 24.2 15.7 C 23.8 15.3 23.7 14.9 23.7 14.4 L 23.7 6.4 L 9.1 6.4 L 9.1 35.6 L 33.4 35.6 Z'/%3E %3C/svg%3E\""

/***/ }),
/* 1503 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.5,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.4,38,33.9,38H8.4 c-0.5,0-0.9-0.2-1.3-0.5c-0.3-0.4-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.5,4.2,7.9,4,8.4,4h17c0.5,0,1.1,0.1,1.7,0.4 s1.1,0.6,1.4,0.9L34.5,11.2z M26,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.8,7C26.7,6.8,26.4,6.7,26,6.6z M33.3,35.6V16.2h-7.9 c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3v-8H9v29.2C9,35.6,33.3,35.6,33.3,35.6z M21.2,32.3c0,0.4-0.2,0.7-0.5,0.8 c-0.1,0.1-0.3,0.1-0.4,0.1c-0.2,0-0.4-0.1-0.6-0.2l-5-4.1h-2.6c-0.5,0-0.9-0.4-0.9-0.9v-3.6c0-0.5,0.4-0.9,0.9-0.9h2.6l5-4.1 c0.3-0.2,0.6-0.3,1-0.1c0.3,0.1,0.5,0.5,0.5,0.8V32.3z M24.7,30.9L24.7,30.9c-0.3,0-0.5-0.1-0.7-0.3l-0.1-0.1 c-0.3-0.3-0.4-0.8-0.1-1.2c0.7-0.9,1-2,1-3.1c0-1.2-0.4-2.4-1.2-3.3c-0.3-0.4-0.3-0.9,0.1-1.2l0.1-0.1c0.2-0.2,0.4-0.3,0.7-0.3 c0.3,0,0.5,0.1,0.7,0.3c1.1,1.3,1.6,2.9,1.6,4.6c0,1.6-0.5,3.1-1.4,4.4C25.2,30.7,25,30.9,24.7,30.9L24.7,30.9z M28.5,33.7 c-0.2,0.2-0.4,0.3-0.7,0.3l0,0c-0.2,0-0.5-0.1-0.6-0.3l-0.1-0.1c-0.3-0.3-0.4-0.9-0.1-1.2c1.5-1.7,2.3-4,2.3-6.2 c0-2.4-0.9-4.6-2.4-6.4c-0.3-0.4-0.3-0.9,0-1.2l0.1-0.1c0.2-0.2,0.4-0.3,0.7-0.3c0.3,0,0.5,0.1,0.7,0.3c1.9,2.1,2.9,4.9,2.9,7.7 C31.2,28.9,30.2,31.6,28.5,33.7L28.5,33.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 1504 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.5,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.4,38,33.9,38H8.4 c-0.5,0-0.9-0.2-1.3-0.5c-0.3-0.4-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.5,4.2,7.9,4,8.4,4h17c0.5,0,1.1,0.1,1.7,0.4 s1.1,0.6,1.4,0.9L34.5,11.2z M26,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.8,7C26.7,6.8,26.4,6.7,26,6.6z M33.3,35.6V16.2h-7.9 c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3v-8H9v29.2C9,35.6,33.3,35.6,33.3,35.6z'/%3E %3Cpath id='Text' d='M18.3,26h-3.2l-0.6,2.4H12l3.6-11.8h2.2l3.7,11.8H19L18.3,26z M15.6,24h2.2l-1.1-4.2L15.6,24z M26.6,28.4 c-0.1-0.1-0.1-0.4-0.2-0.7c-0.4,0.6-1,0.8-1.7,0.8s-1.3-0.2-1.8-0.7s-0.7-1.1-0.7-1.9c0-0.9,0.3-1.6,0.9-2.1s1.4-0.8,2.5-0.8h0.7 v-0.7c0-0.4-0.1-0.7-0.2-0.8c-0.1-0.2-0.3-0.2-0.6-0.2c-0.6,0-0.9,0.3-0.9,1h-2.3c0-0.8,0.3-1.5,0.9-2s1.4-0.8,2.3-0.8 c1,0,1.7,0.2,2.2,0.7s0.8,1.2,0.8,2.1v4.1c0,0.8,0.1,1.3,0.3,1.8v0.1h-2.2V28.4z M25.2,26.8c0.3,0,0.5-0.1,0.6-0.2s0.3-0.2,0.4-0.4 v-1.8h-0.5c-0.4,0-0.7,0.1-0.9,0.4c-0.2,0.2-0.3,0.6-0.3,1C24.5,26.4,24.7,26.8,25.2,26.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 1505 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.4,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.3,38,33.8,38H8.3 c-0.5,0-0.9-0.2-1.3-0.5c-0.3-0.4-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.4,4.2,7.8,4,8.3,4h17c0.5,0,1.1,0.1,1.7,0.4 s1.1,0.6,1.4,0.9L34.4,11.2z M25.9,6.6v7.1H33c-0.1-0.4-0.3-0.6-0.4-0.8L26.7,7C26.6,6.8,26.3,6.7,25.9,6.6z M33.2,35.6V16.2h-7.9 c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3v-8H8.9v29.2C8.9,35.6,33.2,35.6,33.2,35.6z M29.4,30.8c-0.1-0.1-0.1-0.3-0.2-0.6 c-0.4,0.5-0.9,0.8-1.5,0.8c-0.7,0-1.2-0.2-1.7-0.7c-0.4-0.4-0.7-1-0.7-1.7c0-0.8,0.3-1.5,0.8-2s1.3-0.7,2.3-0.7H29v-0.6 c0-0.4-0.1-0.6-0.2-0.8c-0.1-0.1-0.3-0.2-0.5-0.2c-0.5,0-0.8,0.3-0.8,0.9h-2c0-0.7,0.3-1.4,0.8-1.8c0.6-0.5,1.3-0.7,2.1-0.7 c0.9,0,1.6,0.2,2.1,0.7s0.7,1.1,0.7,2V29c0,0.7,0.1,1.2,0.3,1.6v0.1L29.4,30.8L29.4,30.8z M27.3,29.3c0.2,0,0.4,0,0.6-0.1 s0.3-0.2,0.4-0.3v-1.7h-0.5c-0.4,0-0.6,0.1-0.8,0.3c-0.2,0.2-0.3,0.5-0.3,0.9C26.6,29,26.8,29.3,27.3,29.3z M21,33.2H11V17.6h10 V33.2z M18.1,30.6h2.3L17,19.8h-2l-3.4,10.8h2.3l0.6-2.2h3L18.1,30.6z M16,22.7l1,3.9h-2L16,22.7z M25.2,18.4v-0.8h-3.5v0.8H23v14.1 h-1.3v0.8h3.5v-0.8h-1.3V18.4H25.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1506 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M33.9,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S33.8,38,33.3,38H7.8 c-0.5,0-0.9-0.2-1.3-0.5C6.2,37.1,6,36.7,6,36.2V5.8c0-0.5,0.2-0.9,0.5-1.3C6.9,4.2,7.3,4,7.8,4h17c0.5,0,1.1,0.1,1.7,0.4 c0.6,0.3,1.1,0.6,1.4,0.9L33.9,11.2z M25.4,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.2,7C26.1,6.8,25.8,6.7,25.4,6.6z M32.7,35.6 V16.2h-7.9c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3V6.4H8.4v29.2H32.7z M28.3,18.6H12.8c-1.1,0-2,1-2,1.8v11.3 c0,0.8,0.9,1.8,2,1.8h15.4c1.1,0,2-1,2-1.8V20.6C30.2,19.8,29.3,18.6,28.3,18.6L28.3,18.6z M22.8,20.1h1.7v1.3h-1.7V20.1z M19.7,20.1h1.7v1.3h-1.7V20.1z M16.6,20.1h1.7v1.3h-1.7V20.1z M15.3,32.1h-1.7v-1.3h1.7V32.1z M15.3,21.4h-1.7v-1.3h1.7V21.4z M18.3,32.1h-1.7v-1.3h1.7V32.1z M21.4,32.1h-1.7v-1.3h1.7V32.1z M24.4,32.1h-1.7v-1.3h1.7V32.1z M23.6,26.4L19,29.3 c-0.3,0.2-0.6,0-0.6-0.4v-5.7c0-0.3,0.3-0.5,0.6-0.4l4.6,2.9C23.9,25.9,23.9,26.3,23.6,26.4L23.6,26.4z M27.5,32.1h-1.7v-1.3h1.7 V32.1z M27.5,21.4h-1.7v-1.3h1.7V21.4z M27.5,21.4'/%3E %3C/svg%3E\""

/***/ }),
/* 1507 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M33.9,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S33.8,38,33.3,38H7.8 c-0.5,0-0.9-0.2-1.3-0.5C6.2,37.1,6,36.7,6,36.2V5.8c0-0.5,0.2-0.9,0.5-1.3C6.9,4.2,7.3,4,7.8,4h17c0.5,0,1.1,0.1,1.7,0.4 c0.6,0.3,1.1,0.6,1.4,0.9L33.9,11.2z M25.4,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.2,7C26.1,6.8,25.8,6.7,25.4,6.6z M32.7,35.6 V16.2h-7.9c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3V6.4H8.4v29.2H32.7z M27,23.4c-0.3,0-1.3,0.1-2.5,0.3 c-0.8-0.6-1.6-1.3-2.1-1.8c-0.7-0.7-1.2-1.3-1.8-1.9c0.8-2.5,1.1-3.7,1.1-4.4c0-2.9-1-3.5-2.6-3.5c-1.2,0-2.6,0.6-2.6,3.6 c0,1.3,0.7,2.9,2.1,4.7c-0.3,1-0.7,2.3-1.2,3.6c-0.2,0.7-0.5,1.3-0.7,1.8c-0.2,0.1-0.4,0.2-0.6,0.3c-0.7,0.3-1.3,0.7-2,0.9 c-2.8,1.3-4.6,2.2-4.6,3.9c0,1.2,1.4,2,2.6,2c1.6,0,4-2.2,5.8-5.8c1.8-0.7,4.1-1.3,6-1.6c1.5,1.1,3.1,2.2,3.8,2.2 c2.1,0,2.6-1.2,2.6-2.3C30.5,23.4,28.1,23.4,27,23.4z M12.3,31.2c-0.5,0-0.8-0.2-0.9-0.3c0-0.6,1.8-1.5,3.6-2.3 c0.1-0.1,0.2-0.1,0.3-0.2C14.1,30.4,12.8,31.2,12.3,31.2z M18.3,15.7c0-1.8,0.6-1.8,0.9-1.8c0.6,0,0.9,0,0.9,1.7 c0,0.4-0.2,1.3-0.7,2.7C18.7,17.3,18.3,16.4,18.3,15.7z M19,25c0.1-0.2,0.1-0.3,0.2-0.5c0.3-1,0.6-1.8,0.9-2.6 c0.4,0.4,0.7,0.8,1.2,1.2c0.2,0.2,0.6,0.5,1.1,1C21.2,24.4,20.1,24.7,19,25z M27.9,26c-0.2-0.1-0.8-0.4-1.5-0.8c0.2,0,0.4,0,0.5,0 c1.3,0,1.6,0.1,1.7,0.3C28.7,25.9,28.7,26,27.9,26z'/%3E %3C/svg%3E\""

/***/ }),
/* 1508 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.6,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.5,38,34,38H8.5 c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.6,4.2,8,4,8.5,4h17c0.5,0,1.1,0.1,1.7,0.4 c0.6,0.3,1.1,0.6,1.4,0.9L34.6,11.2z M26.1,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.9,7C26.8,6.8,26.5,6.7,26.1,6.6z M33.4,35.6 V16.2h-7.9c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3V6.4H9.1v29.2H33.4z M17,27.1c-0.1,0.9,0.1,1.9,0.8,2.9c1.4,2.3,3.5,3.2,5,3 c0,0,0.1,0,0.1,0c0,0,0.1-0.1,0.1-0.1c0-0.1,0-0.2,0-0.2c-0.6-0.7-0.4-1.4-0.2-2.2c0.2-0.9,0.4-1.9-0.2-3.1c-0.8-1.5-1.7-2-2.4-2.2 C20,25,19.8,25,19.7,25l-2.5,1.5C17.1,26.7,17,26.9,17,27.1z M19.7,26.3c0.1-0.2,0.3-0.3,0.6-0.3c0,0,0.1,0,0.1,0 c1.3,0.6,1.5,1.7,1.6,1.8c0,0.3-0.1,0.5-0.4,0.6c-0.1,0-0.1,0-0.2,0c0,0,0,0,0,0c-0.2,0-0.3-0.2-0.3-0.4c0,0-0.2-0.7-1-1.1 c-0.1-0.1-0.2-0.1-0.3-0.3C19.6,26.5,19.6,26.4,19.7,26.3z M11.3,13.4c0.5-0.3,1.1-0.1,1.5,0.3c0.2,0.3,5,7.5,5.7,8.5 c0.3,0.5,0.7,1.4,1,2.2l-2.5,1.5c-0.5-0.7-1.1-1.4-1.5-1.9c-0.6-1.1-4.4-8.8-4.6-9.2C10.6,14.3,10.8,13.7,11.3,13.4z M23.4,29.2 c0.2-0.1,0.4-0.1,0.6-0.1c0,0,0.1,0,0.1,0c0.3,0,0.7,0.1,1.1,0.1c0.3,0.1,0.7,0.1,0.9,0.1c0.2,0,0.2,0,0.2,0 c0.2-0.2-0.1-0.9-0.2-1.2c0-0.1-0.1-0.1-0.1-0.2c-0.2-0.6-0.3-1.2-0.1-1.8c0.2-0.5,0.7-0.9,1.3-1c0.2,0,0.4-0.1,0.6-0.1 c0.2,0,0.4,0,0.6,0c0.2,0,0.4,0,0.7,0c0.7,0,1.2-0.2,1.4-0.6c0.5-0.8-0.1-2.1-0.7-2.7c0,0,0-0.1,0-0.1c0,0,0.1,0,0.1,0 c0.8,0.5,1.3,1.5,1.2,2.4c0,0.5-0.2,1.1-0.9,1.6c-0.4,0.2-1,0.3-1.7,0.3c-0.6,0-1.2,0.1-1.4,0.3c-0.1,0.1-0.1,0.1-0.1,0.2 c0,0.4,0.3,0.9,0.5,1.3c0.4,0.8,0.8,1.6,0.1,2.5c-0.6,0.8-1.4,0.8-2.2,0.8c-0.1,0-0.1,0-0.2,0c-0.4,0-0.8,0-1.2,0.1 c-0.3,0.1-0.4,0.3-0.5,0.7c0,0.3-0.2,0.5-0.3,0.6c0-0.1-0.1-0.2-0.2-0.3c-0.4-0.5-0.3-0.9-0.1-1.8C23.2,30.1,23.3,29.7,23.4,29.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1509 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.5,12.8c-0.3-0.6-0.6-1.1-0.9-1.4l-5.9-5.9c-0.4-0.4-0.8-0.7-1.4-0.9c-0.6-0.3-1.2-0.4-1.7-0.4h-17 C8,4.1,7.6,4.3,7.2,4.7C6.9,5,6.7,5.4,6.7,6v30.4c0,0.5,0.2,0.9,0.5,1.3s0.8,0.5,1.3,0.5H34c0.5,0,0.9-0.2,1.3-0.5 c0.4-0.4,0.5-0.8,0.5-1.3V14.5C35.9,14,35.7,13.4,35.5,12.8z M26.1,6.7c0.4,0.1,0.6,0.3,0.8,0.4l5.9,5.9c0.2,0.2,0.3,0.4,0.4,0.8 h-7.1V6.7z M33.4,35.7h-4.2l0.6,0.8c0.2,0.3,0.1,0.7-0.2,0.9c-0.1,0.1-0.3,0.1-0.4,0.1c-0.2,0-0.9-0.1-1-0.3l-1.1-1.5H15.7l-1.1,1.5 c-0.1,0.2-0.9,0.3-1.1,0.3c-0.1,0-0.3,0-0.4-0.1c-0.3-0.2-0.4-0.6-0.2-0.9l0.6-0.8H9.1V6.6h14.6v7.9c0,0.5,0.2,0.9,0.5,1.3 c0.4,0.4,0.8,0.5,1.3,0.5h7.9V35.7z M29.2,31.8c0.4,0,0.7-0.3,0.7-0.7v-7.9h1.2c0.4,0,0.7-0.3,0.7-0.7V19c0-0.4-0.3-0.7-0.7-0.7 H11.6c-0.4,0-0.7,0.3-0.7,0.7v3.5c0,0.4,0.3,0.7,0.7,0.7h1.2v7.9c0,0.4,0.3,0.7,0.7,0.7h2.7l-2.8,4l-0.6,0.8 c-0.2,0.3-0.1,0.7,0.2,0.9c0.1,0.1,0.3,0.1,0.4,0.1c0.2,0,1-0.1,1.1-0.3l1.1-1.5l2.8-4h5.8l2.8,4l1.1,1.5c0.1,0.2,0.8,0.3,1,0.3 c0.1,0,0.3,0,0.4-0.1c0.3-0.2,0.5-0.6,0.2-0.9l-0.5-0.9l-2.8-4L29.2,31.8L29.2,31.8z M12.6,21.7v-1.8h17.6v1.8H12.6z M14.5,30.2v-7 h13.8v7H14.5z M23.3,24.5c0.3,0.2,0.3,0.7,0.1,1l-2.2,2.7c-0.2,0.2-0.4,0.3-0.7,0.2l-2.2-0.6l-1.1,1.1c-0.1,0.1-0.3,0.2-0.5,0.2 s-0.3-0.1-0.5-0.2c-0.3-0.3-0.3-0.7,0-1l1.4-1.4c0.2-0.2,0.4-0.2,0.6-0.2l2.2,0.6l2-2.4C22.6,24.3,23.1,24.3,23.3,24.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1510 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.7,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.6,38,34.1,38H8.6 c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.7,4.2,8.1,4,8.6,4h17c0.5,0,1.1,0.1,1.7,0.4 c0.6,0.3,1.1,0.6,1.4,0.9L34.7,11.2z M26.2,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L27,7C26.9,6.8,26.6,6.7,26.2,6.6z M33.5,35.6V16.2 h-7.9c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3V6.4H9.2v29.2H33.5z M13.8,22.5v-3.9h4V19c0,0.4,0.6,0.8,1.3,0.8h4.8 c0.7,0,1.3-0.4,1.3-0.8v-0.3h4v3.9H13.8z M25.1,29.7V30c0,0.4-0.6,0.8-1.3,0.8h-4.8c-0.7,0-1.3-0.4-1.3-0.8v-0.3h-4v3.9h15.3v-3.9 H25.1z M25.1,24.2v0.3c0,0.4-0.6,0.8-1.3,0.8h-4.8c-0.7,0-1.3-0.4-1.3-0.8v-0.3h-4V28h15.3v-3.8H25.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1511 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 24.0.3, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M34.5,11.2c0.4,0.4,0.7,0.8,0.9,1.4c0.3,0.6,0.4,1.2,0.4,1.7v21.9c0,0.5-0.2,0.9-0.5,1.3S34.4,38,33.9,38H8.4 c-0.5,0-0.9-0.2-1.3-0.5c-0.4-0.4-0.5-0.8-0.5-1.3V5.8c0-0.5,0.2-0.9,0.5-1.3C7.5,4.2,7.9,4,8.4,4h17c0.5,0,1.1,0.1,1.7,0.4 c0.6,0.3,1.1,0.6,1.4,0.9L34.5,11.2z M26,6.6v7.1h7.1c-0.1-0.4-0.3-0.6-0.4-0.8L26.8,7C26.7,6.9,26.4,6.7,26,6.6z M33.3,35.6V16.2 h-7.9c-0.5,0-0.9-0.2-1.3-0.5s-0.5-0.8-0.5-1.3V6.5H9v29.2H33.3z'/%3E %3Cpath d='M14.3,25.1h-1.4v-5.6l-1.4,0.5v-1.2l2.7-1.1h0.2V25.1z M20.7,22.1c0,1-0.2,1.8-0.6,2.3c-0.4,0.5-0.9,0.8-1.6,0.8 c-0.7,0-1.2-0.3-1.6-0.8c-0.4-0.5-0.6-1.3-0.6-2.2v-1.4c0-1,0.2-1.8,0.5-2.3c0.4-0.5,0.9-0.8,1.6-0.8s1.2,0.3,1.6,0.8 c0.4,0.5,0.6,1.3,0.6,2.3V22.1z M19.2,20.6c0-0.6-0.1-1-0.2-1.3c-0.1-0.3-0.3-0.4-0.5-0.4c-0.5,0-0.7,0.5-0.7,1.6v1.8 c0,0.6,0.1,1,0.2,1.3c0.1,0.3,0.3,0.4,0.5,0.4c0.2,0,0.4-0.1,0.5-0.4c0.1-0.3,0.2-0.7,0.2-1.2V20.6z M24.8,25.1h-1.4v-5.6l-1.4,0.5 v-1.2l2.7-1.1h0.2V25.1z M31.1,22.1c0,1-0.2,1.8-0.6,2.3c-0.4,0.5-0.9,0.8-1.6,0.8c-0.7,0-1.2-0.3-1.6-0.8c-0.4-0.5-0.6-1.3-0.6-2.2 v-1.4c0-1,0.2-1.8,0.5-2.3c0.4-0.5,0.9-0.8,1.6-0.8s1.2,0.3,1.6,0.8c0.4,0.5,0.6,1.3,0.6,2.3V22.1z M29.7,20.6c0-0.6-0.1-1-0.2-1.3 c-0.1-0.3-0.3-0.4-0.5-0.4c-0.5,0-0.7,0.5-0.7,1.6v1.8c0,0.6,0.1,1,0.2,1.3c0.1,0.3,0.3,0.4,0.5,0.4c0.2,0,0.4-0.1,0.5-0.4 c0.1-0.3,0.2-0.7,0.2-1.2V20.6z M15.4,30.1c0,1-0.2,1.8-0.6,2.3c-0.4,0.5-0.9,0.8-1.6,0.8c-0.7,0-1.2-0.3-1.6-0.8 c-0.4-0.5-0.6-1.3-0.6-2.2v-1.4c0-1,0.2-1.8,0.5-2.3c0.4-0.5,0.9-0.8,1.6-0.8s1.2,0.3,1.6,0.8c0.4,0.5,0.6,1.3,0.6,2.3V30.1z M14,28.6c0-0.6-0.1-1-0.2-1.3s-0.3-0.4-0.5-0.4c-0.5,0-0.7,0.5-0.7,1.6v1.8c0,0.6,0.1,1,0.2,1.3c0.1,0.3,0.3,0.4,0.5,0.4 c0.2,0,0.4-0.1,0.5-0.4c0.1-0.3,0.2-0.7,0.2-1.2V28.6z M20.7,30.1c0,1-0.2,1.8-0.6,2.3c-0.4,0.5-0.9,0.8-1.6,0.8 c-0.7,0-1.2-0.3-1.6-0.8c-0.4-0.5-0.6-1.3-0.6-2.2v-1.4c0-1,0.2-1.8,0.5-2.3c0.4-0.5,0.9-0.8,1.6-0.8s1.2,0.3,1.6,0.8 c0.4,0.5,0.6,1.3,0.6,2.3V30.1z M19.2,28.6c0-0.6-0.1-1-0.2-1.3s-0.3-0.4-0.5-0.4c-0.5,0-0.7,0.5-0.7,1.6v1.8c0,0.6,0.1,1,0.2,1.3 c0.1,0.3,0.3,0.4,0.5,0.4c0.2,0,0.4-0.1,0.5-0.4c0.1-0.3,0.2-0.7,0.2-1.2V28.6z M24.8,33.2h-1.4v-5.6l-1.4,0.5v-1.2l2.7-1.1h0.2 V33.2z M31.1,30.1c0,1-0.2,1.8-0.6,2.3c-0.4,0.5-0.9,0.8-1.6,0.8c-0.7,0-1.2-0.3-1.6-0.8c-0.4-0.5-0.6-1.3-0.6-2.2v-1.4 c0-1,0.2-1.8,0.5-2.3c0.4-0.5,0.9-0.8,1.6-0.8s1.2,0.3,1.6,0.8c0.4,0.5,0.6,1.3,0.6,2.3V30.1z M29.7,28.6c0-0.6-0.1-1-0.2-1.3 c-0.1-0.3-0.3-0.4-0.5-0.4c-0.5,0-0.7,0.5-0.7,1.6v1.8c0,0.6,0.1,1,0.2,1.3c0.1,0.3,0.3,0.4,0.5,0.4c0.2,0,0.4-0.1,0.5-0.4 c0.1-0.3,0.2-0.7,0.2-1.2V28.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1512 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1513);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1513 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/**\n * make form elements small in text and height\n *\n * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3\n * @author      Cornelius Weiss <c.weiss@metaways.de>\n * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)\n * @version     $Id$\n */\n\n.x-tool-toggle-expander {\n    position: relative;\n    top: -23px;\n    left: 1px;\n    margin-bottom: -15px;\n}\n\n.x-ux-form-icontextfield-labelicon {\n    width: 13px;\n    height: 13px;\n}\n\n.ext-strict .x-form-text {\n    height: 15px;\n}\n\n.ext-webkit .x-form-text {\n    height: 17px;\n    padding-top: 0px;\n    padding-bottom: 0px;\n}\n\n.x-form-field {\n    font-size: 11px;\n}\n\n.x-form-label-top .x-form-check-wrap {\n    margin-top: -4px;\n}\n\n.ext-gecko .x-form-label-top .x-form-check-wrap {\n    margin-top: -6px;\n}\n    \n.x-form-label-top .x-hide-label .x-form-check-wrap {\n    margin-top: 0;\n}\n\n.x-form-cb-label {\n    top: 1px;\n}\n\n.x-form-check-wrap {\n    position: relative;\n    display: inline-block;\n}\n\n.x-form-check-wrap input {\n    top: 7px;\n    position: absolute;\n    display: inline-block;\n}\n\n.x-form-check-wrap .x-form-cb-label {\n    white-space: nowrap;\n    border-left: 17px solid transparent;\n    box-sizing: border-box;\n    text-overflow: ellipsis;\n    width: 100%;\n    display: inline-block;\n    overflow: hidden;\n    margin-left: 0;\n}\n\n.x-form-item {\n    font-size: 11px;\n    /*font-weight: bold;*/\n    margin-bottom: 2px;\n}\n.ext-gecko .x-window-body .x-form-item {\n    overflow: hidden;\n}\n\n.x-fieldset {\n    padding: 5px 5px 0px 5px;\n    margin: 0px;\n    margin-bottom: 5px;\n}\n\n.x-form-field-wrap .x-form-trigger {\n    height: 18px;\n}\n\n.ext-webkit .x-form-field-wrap .x-form-trigger {\n    height: 18px;\n}\n\n.ext-webkit .x-small-editor .x-form-trigger {\n    height: 17px;\n}\n\n.ext-webkit .x-small-editor .x-form-text {\n    padding-top: 0px;\n    padding-bottom: 0px;\n}\n\n/*.x-tab-strip-top .x-tab-strip-active .x-tab-right span.x-tab-strip-text {*/\n/*    padding-bottom: 3px;*/\n/*}*/\n\n/*.x-tab-strip span.x-tab-strip-text {*/\n/*    padding:3px 0pt;*/\n/*}*/\n\n.ext-ie .x-form-twin-triggers {\n    padding-top: 6px;\n    padding-left: 0;\n}\n\n.x-progress-text {\n    font-size: 10px;\n    font-weight: bold;\n}\n", ""]);

// exports


/***/ }),
/* 1514 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1515);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1515 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".ux-arrowcollapse {\n    /*position:relative;*/\n    padding-bottom:5px;\n    overflow:hidden;\n}\n\n.ux-arrowcollapse .x-tool-toggle {\n    background:#fff url(" + escape(__webpack_require__(164)) + ") no-repeat -18px 0;\n    position: relative;\n    top: 8px;\n    float: left;\n}\n\n.ux-arrowcollapse-plain .x-tool-toggle {\n    background-color: #DFE8F6;\n}\n\n.x-panel-collapsed .ux-arrowcollapse-header .x-tool-toggle {\n    background-position: -2px 0;\n}\n\n.x-panel-collapsed .ux-arrowcollapse-header .x-tool-toggle-over {\n    background-position: -34px 0;\n}\n\n.ux-arrowcollapse-header .x-tool-toggle-over {\n    background-position: -50px 0;\n}\n\n.ux-arrowcollapse .ux-arrowcollapse-header {\n    line-height: 24px;\n    padding:0;\n    /*border-bottom:1px solid #c3daf9;*/\n}\n\n.ux-arrowcollapse .ux-arrowcollapse-header-text {\n    font-size:11px;\n    font-family:tahoma,arial,sans-serif;\n    line-height:13px;\n    text-transform:uppercase;\n    position:relative;\n    left:5px;\n    top:5px;\n    /*padding:1px 5px 1px 20px;*/\n    color:#4e79b2;\n    }\n \n.ux-arrowcollapse-body {\n    overflow:hidden;\n}\n\n.ux-arrowcollapse-bwrap {\n    overflow:hidden;\n    zoom:1;\n}\n", ""]);

// exports


/***/ }),
/* 1516 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1517);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1517 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".ux-subformpanel {\n    /*position:relative;*/\n    padding-bottom:5px;\n    overflow:hidden;\n}\n\n.ux-subformpanel .x-tool-toggle {\n    background:#fff url(" + escape(__webpack_require__(164)) + ") no-repeat -18px 0;\n    position: relative;\n    top: 8px;\n    float: left;\n}\n\n.ux-subformpanel-plain .x-tool-toggle {\n    background-color: #DFE8F6;\n}\n\n.x-panel-collapsed .ux-subformpanel-header .x-tool-toggle {\n    background-position: -2px 0;\n}\n\n.x-panel-collapsed .ux-subformpanel-header .x-tool-toggle-over {\n    background-position: -34px 0;\n}\n\n.ux-subformpanel-header .x-tool-toggle-over {\n    background-position: -50px 0;\n}\n\n.ux-subformpanel .ux-subformpanel-header {\n    line-height: 24px;\n    padding:0;\n    /*border-bottom:1px solid #c3daf9;*/\n}\n\n.ux-subformpanel .ux-subformpanel-header-text {\n    color: #a0a0a0;\n    font-size: 18px;\n    font-weight: bold;\n    position:relative;\n    }\n\n.ux-subformpanel-body {\n    overflow:hidden;\n}\n\n.ux-subformpanel-bwrap {\n    overflow:hidden;\n    zoom:1;\n}\n", ""]);

// exports


/***/ }),
/* 1518 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1519);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1519 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-ux-connectionstatus-online {\n    background-image: url(" + escape(__webpack_require__(1520)) + ") !important;;\n}\n\n.x-ux-connectionstatus-offline {\n    background-image: url(" + escape(__webpack_require__(1521)) + ") !important;;\n}\n\n.x-ux-connectionstatus-unknown {\n    background-image: url(" + escape(__webpack_require__(1522)) + ") !important;;\n}\n\n.x-ux-connectionstatus.x-btn-icon .x-btn-small .x-btn-text {\n    background-size: 14px 14px !important;\n    background-position: 1px 1px !important;\n}", ""]);

// exports


/***/ }),
/* 1520 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 43 43' style='enable-background:new 0 0 43 43;' xml:space='preserve' width='43' height='43'%3E %3Cpath d='M32.9,24.4c-0.5,0-1-0.2-1.4-0.6c-5.4-5.4-14.2-5.4-19.6,0c-0.8,0.8-2,0.8-2.8,0c-0.8-0.8-0.8-2,0-2.8c7-7,18.3-7,25.2,0 c0.8,0.8,0.8,2,0,2.8C33.9,24.2,33.4,24.4,32.9,24.4L32.9,24.4z M32.9,24.4 M27.5,29.8c-0.5,0-1-0.2-1.4-0.6 c-1.2-1.2-2.7-1.8-4.4-1.8c-1.6,0-3.2,0.6-4.4,1.8c-0.8,0.8-2,0.8-2.8,0c-0.8-0.8-0.8-2,0-2.8c1.9-1.9,4.5-3,7.2-3s5.3,1.1,7.2,3 c0.8,0.8,0.8,2,0,2.8C28.5,29.6,28,29.8,27.5,29.8L27.5,29.8z M27.5,29.8 M24.3,33.6c0,1.5-1.2,2.7-2.7,2.7c-1.5,0-2.7-1.2-2.7-2.7 c0-1.5,1.2-2.7,2.7-2.7C23.1,30.9,24.3,32.1,24.3,33.6L24.3,33.6z M24.3,33.6 M38.4,18.9c-0.5,0-1-0.2-1.4-0.6 c-8.4-8.4-22.1-8.4-30.5,0c-0.8,0.8-2,0.8-2.8,0c-0.8-0.8-0.8-2,0-2.8C8.4,10.7,14.8,8,21.7,8c6.8,0,13.3,2.7,18.1,7.5 c0.8,0.8,0.8,2,0,2.8C39.4,18.7,38.9,18.9,38.4,18.9L38.4,18.9z M38.4,18.9'/%3E %3C/svg%3E\""

/***/ }),
/* 1521 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 43 43' style='enable-background:new 0 0 43 43;' xml:space='preserve' width='43' height='43'%3E %3Cpath d='M24.3,33.6c0,1.5-1.2,2.7-2.7,2.7c-1.5,0-2.7-1.2-2.7-2.7c0-1.5,1.2-2.7,2.7-2.7C23.1,30.9,24.3,32.1,24.3,33.6L24.3,33.6z M24.3,33.6 M24.7,28.2c0.1-0.9,0.3-2.4,0.4-4.2c1.4,0.5,2.7,1.3,3.7,2.4c0.8,0.8,0.8,2,0,2.8c-0.4,0.4-0.9,0.6-1.4,0.6 c-0.5,0-1-0.2-1.4-0.6C25.7,28.8,25.2,28.5,24.7,28.2z M14.5,26.4c-0.8,0.8-0.8,2,0,2.8c0.8,0.8,2,0.8,2.8,0c0.4-0.4,0.8-0.7,1.3-1 c-0.1-1.2-0.3-2.7-0.4-4.2C16.8,24.5,15.5,25.3,14.5,26.4z M9.1,21c-0.8,0.8-0.8,2,0,2.8c0.8,0.8,2,0.8,2.8,0c1.7-1.7,3.8-2.9,6-3.5 c-0.1-1.7-0.2-3.2-0.3-4C14.5,17,11.5,18.6,9.1,21z M34.3,21c-2.4-2.4-5.4-4-8.6-4.7c-0.1,0.9-0.2,2.4-0.3,4c2.2,0.6,4.3,1.8,6,3.5 c0.4,0.4,0.9,0.6,1.4,0.6c0.5,0,1-0.2,1.4-0.6C35.1,23,35.1,21.8,34.3,21z M38.4,18.9c0.5,0,1-0.2,1.4-0.6c0.8-0.8,0.8-2,0-2.8 C34.9,10.7,28.5,8,21.7,8c-6.8,0-13.3,2.7-18.1,7.5c-0.8,0.8-0.8,2,0,2.8c0.8,0.8,2,0.8,2.8,0c8.4-8.4,22.1-8.4,30.5,0 C37.3,18.7,37.8,18.9,38.4,18.9L38.4,18.9z M38.4,18.9 M21.7,24.2 M21.1,14c1.1-0.3,2.2,0.3,2.7,1.3c0.2,0.4,0.2,0.7,0.2,1.2 c-0.1,1.2-0.6,9.9-0.6,10.5c0,1-0.8,1.7-1.7,1.7C20.8,28.6,20,28,20,27c-0.2-2.8-0.3-5.5-0.5-8.3c-0.1-0.7-0.1-1.5-0.2-2.2 C19.3,15.3,20,14.3,21.1,14L21.1,14z M21.2,9.7'/%3E %3C/svg%3E\""

/***/ }),
/* 1522 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 43 43' style='enable-background:new 0 0 43 43;' xml:space='preserve' width='43' height='43'%3E %3Cpath d='M24.3,33.6c0,1.5-1.2,2.7-2.7,2.7c-1.5,0-2.7-1.2-2.7-2.7c0-1.5,1.2-2.7,2.7-2.7C23.1,30.9,24.3,32.1,24.3,33.6L24.3,33.6z M24.3,33.6 M38.4,18.9c-0.5,0-1-0.2-1.4-0.6c-8.4-8.4-22.1-8.4-30.5,0c-0.8,0.8-2,0.8-2.8,0c-0.8-0.8-0.8-2,0-2.8 C8.4,10.7,14.8,8,21.7,8c6.8,0,13.3,2.7,18.1,7.5c0.8,0.8,0.8,2,0,2.8C39.4,18.7,38.9,18.9,38.4,18.9L38.4,18.9z M38.4,18.9 M12.6,18.3c-1.3,0.7-2.5,1.6-3.6,2.7c-0.8,0.8-0.8,2,0,2.8c0.8,0.8,2,0.8,2.8,0c1.2-1.2,2.5-2.1,4-2.8c-1.1-0.9-2.6-2.1-3-2.5 C12.8,18.4,12.7,18.3,12.6,18.3z M34.3,21c-1.1-1.1-2.3-2-3.5-2.7c0,0.1,0.1,0.3,0.1,0.4c0.3,1.9,0.2,3.3-0.3,4.3 c0.3,0.3,0.6,0.5,0.9,0.8c0.4,0.4,0.9,0.6,1.4,0.6c0.5,0,1-0.2,1.4-0.6C35.1,23,35.1,21.8,34.3,21z M25.4,28.1 c0,0.2-0.1,0.3-0.1,0.5c0.3,0.2,0.5,0.4,0.7,0.6c0.4,0.4,0.9,0.6,1.4,0.6c0.5,0,1-0.2,1.4-0.6c0.8-0.8,0.8-2,0-2.8 c-0.3-0.3-0.6-0.6-1-0.8c-0.2,0.1-0.5,0.3-0.8,0.5C26.1,26.7,25.5,27.5,25.4,28.1z M18.5,23.9c-1.5,0.5-2.9,1.3-4,2.5 c-0.8,0.8-0.8,2,0,2.8c0.8,0.8,2,0.8,2.8,0c0.3-0.3,0.5-0.5,0.8-0.7C18,28.1,18,27.5,18,26.8C18,26,18.1,24.9,18.5,23.9z M29.9,20.4 c0,0.7-0.1,1.4-0.3,2s-0.6,1.1-1,1.5s-0.8,0.8-1.2,1c-0.3,0.2-0.8,0.5-1.3,0.8c-0.5,0.3-0.8,0.5-1,0.6s-0.4,0.3-0.6,0.5 c-0.2,0.2-0.3,0.4-0.3,0.6v0.7c0,0.2-0.1,0.4-0.2,0.5s-0.3,0.2-0.5,0.2h-3.6c-0.2,0-0.4-0.1-0.5-0.2s-0.2-0.3-0.2-0.5v-1.5 c0-0.5,0.1-1,0.2-1.4c0.2-0.4,0.3-0.8,0.5-1.1s0.5-0.5,0.9-0.8c0.4-0.3,0.7-0.4,0.9-0.6s0.6-0.3,1-0.5c0.8-0.4,1.3-0.7,1.7-1 c0.3-0.3,0.5-0.6,0.5-1.1c0-0.6-0.3-1.2-1-1.6c-0.6-0.4-1.4-0.7-2.1-0.7c-0.8,0-1.5,0.2-2.1,0.6c-0.4,0.3-1,0.9-1.8,1.8 c-0.1,0.2-0.3,0.3-0.6,0.3c-0.2,0-0.3,0-0.4-0.1l-2.4-1.8c-0.1-0.1-0.2-0.3-0.3-0.4c0-0.2,0-0.4,0.1-0.5c1.8-2.9,4.4-4.3,7.8-4.3 c1.9,0,3.7,0.7,5.3,2C29.1,16.9,29.9,18.5,29.9,20.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1523 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1524);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1524 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-panel-footer-wizard {\n    border-color:#a9bfd3;\n    border-style:solid;\n    border-width:0 1px 1px 1px;\n    background:#d0def0 url(" + escape(__webpack_require__(218)) + ") repeat-x top left;\n}\n\n.x-panel-footer-wizard-status {\n    padding-left: 5px;\n    padding-top: 11px;\n    color:#15428b;\n    font:bold 11px tahoma,arial,verdana,sans-serif;\n    float:left;\n    width:auto;\n}\n", ""]);

// exports


/***/ }),
/* 1525 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1526);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1526 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*\n * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3\n * @author      Cornelius Weiss <c.weiss@metaways.de>\n * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)\n * @version     $Id$\n */\n\n.PercentRenderer {\n    height: 12px;\n    position: relative;\n}\n\n.x-toolbar .PercentRendererText div,\n.PercentRendererText {\n    color:#000000;\n    font-size:9px;\n    font-weight:bold;\n    left:0pt;\n    padding:0px 5px;\n    position:absolute;\n    text-align:center;\n    white-space: nowrap;\n}\n\n.PercentBar-unlimited {\n    border-top-color:#d1e4fd;\n    border-bottom-color:#7fa9e4;\n    border-right-color:#7fa9e4;\n}\n\n.PercentBar-below {\n    border-right: none;\n    background-color: #c6e8ae;\n    background-image: none;\n    /*background-color:#9cbfee;*/\n    /*background-image:url(../../../images/progress/progress-bgGreen.gif) !important;*/\n    border-top-color:#c6e8ae !important;\n    border-bottom-color:#7fa9e4;\n    border-right-color:#7fa9e4;\n}\n\n.PercentBar-over {\n    border-right: none;\n    background-color: #fff5b8;\n    background-image: none;\n    /*background-color:#9cbfee;*/\n    /*background-image:url(../../../images/progress/progress-bgYellow.gif) !important;*/\n    border-top-color:#fff5b8 !important;\n    border-bottom-color:#7fa9e4;\n    border-right-color:#7fa9e4;\n}\n\n.PercentBar-limit {\n    border-right: none;\n    background-color: #f7bfbf;\n    background-image: none;\n    /*background-color:#9cbfee;*/\n    /*background-image:url(../../../images/progress/progress-bgRed.gif) !important;*/\n    border-top-color:#f7bfbf !important;\n    border-bottom-color:#7fa9e4;\n    border-right-color:#7fa9e4;\n}\n\n/* some progress bar colors */\n/* @see 0008254: Allow colors in Tasks progressbar */\n.PercentRenderer-progress-bar10 { background-color: #f36 !important; background-image: none !important; }\n.PercentRenderer-progress-bar20 { background-color: #e69 !important; background-image: none !important; }\n.PercentRenderer-progress-bar30 { background-color: #d8a !important; background-image: none !important; }\n.PercentRenderer-progress-bar40 { background-color: #c9a !important; background-image: none !important; }\n.PercentRenderer-progress-bar50 { background-color: #baa !important; background-image: none !important; }\n.PercentRenderer-progress-bar60 { background-color: #aa9 !important; background-image: none !important; }\n.PercentRenderer-progress-bar70 { background-color: #aa8 !important; background-image: none !important; }\n.PercentRenderer-progress-bar80 { background-color: #ab8 !important; background-image: none !important; }\n.PercentRenderer-progress-bar90 { background-color: #9b8 !important; background-image: none !important; }\n.PercentRenderer-progress-bar100 { background-color: #8c7 !important; background-image: none !important; }\n\n.PercentRenderer-progress-barBelow { background-color: #8c7 !important; background-image: none !important; }\n.PercentRenderer-progress-barOver { background-color: #fed35d !important; background-image: none !important; }\n.PercentRenderer-progress-barLimit { background-color: #f77a4d !important; background-image: none !important; }\n\n.QuotaRenderer-unlimited {background-color: transparent !important; background-image: none !important; border: none; padding-top:1px; position: relative}\n", ""]);

// exports


/***/ }),
/* 1527 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1528);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1528 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-date-picker-wk {\n    /*background:#A9BFD3 url(../../../library/ExtJS/resources/images/default/toolbar/bg.gif) repeat-x scroll left top;*/\n    background-color: #F0F0F0;\n    border-color:#D0D0D0;\n    border-right:1px solid #D0D0D0;\n    text-align: center;\n    vertical-align:middle;\n}\n\n.x-date-picker-wk-wkrowover {\n    background-color: #F0F0F0;\n}\n", ""]);

// exports


/***/ }),
/* 1529 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1530);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1530 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-grid3-quickadd .x-grid3-header {\n    background: #f9f9f9 url(" + escape(__webpack_require__(1531)) + ") repeat-x left -2px;\n}\n\n.x-grid3-quickadd .new-row {\n    height:20px;\n}\n.x-grid3-quickadd .new-row .x-small-editor {\n    overflow:hidden;\n    width:100%;\n}\n.x-grid3-quickadd .new-row .x-small-editor input {\n    font-size:11px;\n}", ""]);

// exports


/***/ }),
/* 1531 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhAgAwAIcAANDQ0Mra8Ovs7uzt7+3u8O7v8e/w8vDx8/Hy9PL3/Pn5+QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAP8ALAAAAAACADAAAAgvABUIHEiwYEEECBEcWMjQgEMDBQoQmEhgwAABGAUAAJAgQcaPIEOKHEkSY4AAAQEAOw=="

/***/ }),
/* 1532 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1533);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1533 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-ux-form-icontextfield-labelicon {\n    width: 16px;\n    height: 16px;\n    position: relative;\n    top: 3px;\n    margin-right: 3px;\n    margin-top: -3px;  \n}\n", ""]);

// exports


/***/ }),
/* 1534 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1535);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1535 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-grid3-drag-insert-above {\n    border-top: 2px solid black;\n}\n.x-grid3-drag-insert-below {\n    border-bottom: 2px solid black;\n}\n\n.x-grid3-drag-append {\n    \n}\n", ""]);

// exports


/***/ }),
/* 1536 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1537);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1537 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "\n.ux-action-column-cell .x-grid3-cell-inner {\n    padding: 1px;\n}\n.ux-action-column-item {\n    float: left;\n    min-width: 16px;\n    height: 16px;\n    background-repeat: no-repeat;\n    margin: 0 5px 0 0;\n    cursor: pointer;\n    background-size: 16px;\n}\n\n.ux-action-column-item span {\n    padding: 0 0 0 20px;\n    line-height: 18px;\n}\n", ""]);

// exports


/***/ }),
/* 1538 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1539);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1539 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".ext-ux-grid-gridviewmenuplugin-menuBtn.x-grid3-hd-btn {\n    display:block;\n}\n\n.ext-ux-grid-gridviewmenuplugin-menuBtn.x-grid3-hd-btn {\n    background-size: 16px 16px;\n    background-image:url(" + escape(__webpack_require__(541)) + ");\n    width:16px;\n    background-color: #eeeeee;\n}\n\na.ext-ux-grid-gridviewmenuplugin-menuBtn.x-grid3-hd-btn:hover {\n    background-position: center;\n}\n", ""]);

// exports


/***/ }),
/* 1540 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1541);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1541 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-tool-expand .x-tool-toggle {\n    background-position:0pt -195px;\n}\n\n.x-tool-collapse .x-tool-toggle {\n    background-position:0pt -210px;\n}", ""]);

// exports


/***/ }),
/* 1542 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1543);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1543 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".ux-imagefield-ct {\n     border:1px solid #B5B8C8;\n}\n.ux-imagefield-button{\n     position:absolute;\n     top:0px;\n     width: 100%;\n     height: 100%;\n}\n.ux-imagefield-text{\n    position: absolute;\n    text-align:center;\n}\n", ""]);

// exports


/***/ }),
/* 1544 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1545);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1545 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-form-spinner-proxy{\n    /*background-color:#ff00cc;*/\n}\n.x-form-field-wrap img.x-form-spinner-trigger {\n    background:transparent url(" + escape(__webpack_require__(1546)) + ") no-repeat 0 0;\n}\n\n.x-form-field-wrap .x-form-spinner-overup{\n    background-position:-17px 0;\n}\n.x-form-field-wrap .x-form-spinner-clickup{\n    background-position:-34px 0;\n}\n.x-form-field-wrap .x-form-spinner-overdown{\n    background-position:-51px 0;\n}\n.x-form-field-wrap .x-form-spinner-clickdown{\n    background-position:-68px 0;\n}\n\n.x-trigger-wrap-focus .x-form-spinner-trigger{\n    background-position:-85px 0;\n}\n.x-trigger-wrap-focus .x-form-spinner-overup{\n    background-position:-102px 0;\n}\n.x-trigger-wrap-focus .x-form-spinner-clickup{\n    background-position:-119px 0;\n}\n.x-trigger-wrap-focus .x-form-spinner-overdown{\n    background-position:-136px 0;\n}\n.x-trigger-wrap-focus .x-form-spinner-clickdown{\n    background-position:-153px 0;\n}\n.x-trigger-wrap-focus .x-form-trigger{\n    border-bottom: 1px solid #7eadd9;\n}\n\n.x-form-field-wrap .x-form-spinner-splitter {\n    line-height:1px;\n    font-size:1px;\n    background:transparent url(" + escape(__webpack_require__(1547)) + ") no-repeat 0 0;\n    position:absolute;\n    cursor: n-resize;\n}\n.x-trigger-wrap-focus .x-form-spinner-splitter{\n    background-position:-14px 0;\n}\n", ""]);

// exports


/***/ }),
/* 1546 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhMgEXANUAAAAAADJRi0D/QH6t2a7Q47HQ5LW4yLvP6L3Y6MDU68bY7Mrb5srd9c3d6s3k/s7g9dHR0dPh6tPi8tbp/9nm9dra2tvo893z/+Hh4eTy+uny9+n5/+3t7e3z+fH2+vPz8/X5/Pv8/QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkKACIALAAAAAAyARcAAAb/QINwSCwaBIOkcskcIJvQpMBIHU6r1Ge0qd0uu15pmAkOC0TotHrNbrOx2fFXrix77Vt8VBDq+/+AFQaAhH8HAwuJiouMh4WPgo+FkZKAjpWGiIybipeYfZ6fh26kpW2ffpSoh5ytoZivlaytm4cft7i3IbkffQYSwMESFh4Wwn2amw2cA7y4u7m+zrq8vsLBxMbByBvd3t0h3xvIrcubA9fA2cch6Onr2+2m86bT0NEhv9fw8cmL5ufeFbvGTdw4g+SUtWrmLESAe7j0CbMAIgAIbcDacYrgIcI5ew+dGQAJ8ZZEbBUvHhtgcNxDcRo3cfTIyN3ElBgltHuHcyW9/59tGoYUua/nSpkdmRW1mFMnS5gvYfpLNJOZ0ABDdZ0cVhErCArbpi6IkJKmIobRsGbtNbKaWoj5lnoFm/HpN4dYw3mLuYisRbOJbKrrapGuU7mFwwJdnMZt3monKar9erRv2YAoJxt2CjWvVEZ+QQAOzKE0h15qH5eOG4wC4bl1QRMWvWiA6dN4335YbeA26tS7eAtznTqx0wzIM7gEvgE5X6qzAQsmnpry4davjctjvNj0b92mWUugrjms5cmjbZKHXTf58rfNnfvz6zW999z4d+d7wF8C4dwgSPDAc/Shd9Z9b4GXD4J5KWgAfw/4l6BXArbjHn7wZUBgdrQFBv+hhA1SOOAAH/43WYUDcNcdbhOGxFt/Joo4oiIF1lcbjC0GyJ+FymHomXw0cihdeLrhx0E+DDAggQeTSYaVB04FmSNNtq1W5FtH9mblY0YiqSSTXjkZAJQ8ZvDfeyBomEyBAFKZ5JJNEkbmAG+CyZScTqkI1JYhGZnll3GqBSUDMbFpYGCAhoknoQMgdyaAQI4V418HltZLH7tdGpyXSoIQQoCdfioBo4k0YGeAci5TJW6Ysrqplq5m6od+BiQZKqj+icroBbxq2EdyfmRwQUymnpjqAnS+6Smuy47ajq25MqvrdnrOY+mssfKmrK7RjkpqsRQei+y20oK66wW+hgD/7K+8agSuRSCOac6qt9UbXq22Qpgvf0nyRdanHv3bIb321rtgwQVzyoC+STLcDq+9Igdxcu2uuWzAFyO67wMb95tsw/yCzDGj1dKDcML4LhyyyiOTKinAL3c4rsgdezyxxBELWzF0MAts1gAQBF1BLx9UYDTRFUDwgQFBQzD0LkY/XbTSTAuN9NFQU33A1gp4EIIHChzQ9ddhZzAAAWgTUMDaaa9dQNoDbC2212DPTfYBZss9dt17lx0313SH3TfeAzhg+ATLTuAA4p8qbnbaarONtttwlzyP1VBjPbXWdvMd+NaPTy555G/DDfjdgxN+eOKLs+5A6KS3PToBQDv9/8FbGORW9NJW46770FUP7btauxuwdQIdCPpuBwnAjkAHIHSAAAHPRz897ccn/+Tyzf+NvPJ2Mp/3Ad9vH373hjswG+KTvX422tVLTz308tNuuSm2D4/V1EuTr7285yMc/Og3vfhdD3vlA6BamKc69U2GfV4xXOgMOD/rwa1pwgtRAPhXtfxpkIMYvN0Hk9Y/wLWobqErgAYE1TW1aOBtf5vbCf2mNzvlBoUxbKEGcZg+CD7kge6b3AqfpMMAvNB+9yNF70YYtBIW8YZhE6AKWWinI2JPhjuMotlWlyPFBXGKRKxi6Wq3ROIljWpN86AZm9hBNe7vjCU0YWrqJkC1If/AhoJCAAzlhkUWgi6GfSTiH/lYREE2kIvV8WIK73hCPSIxiW0IYXE2x7lAjimKUmTkDh15RUvS8ZA+9IoXv6jJHz6Jk2QsIyV5l8YMbvCMaGylCF/ZtDjK8ZJyM5vbClDKU7INkH385Phq6MdBEtJOwixc+loHRAkOYJe9HJMeYQhJN8hyjbU0HjEN+Ue3RdMD09zjNnGZS2Ui0iKjdJ837eTLX6axd5SM5TXjycp5wrKSxPwk4XbJS2SGs5P5xCTh+GhCfQ4zoHzc4jKZCYJ06hKa/qRciqrJhncKL574lKE+97nOPO4SoBoV6CG52NCFPnRtpQTnR1MZwnvKU5b/Lq0nTN9pS711QKQn7ahKJUpQrt2UoAe1KU6B6dOhLnR16VQnPxm5019StKIWxWhGxfZToD4TotLkJ0ipKtKRIvWoOe1nVlf6zrKmUaZmPWsb05rNnh6vp2FFqfS0StS3WtWt5INrXfNq1aP61Zn8lGs4nfpUNbC1rDW1q1UD+7zB/tKtCXCrQv9q0qtCc650PSxN13pYtHZWm3hdbGBHK87QJnSvkkWtXikLVsuSdqWFNaxm22ra0742sFsN7WRZC9jbknW2bARucIWbWN261re5xWtQTbtc4/J2mXF97SNjK9ypGte3K63taZ+bvuiSlnbV9SxbxZvW4ir3uLdNZ25qtVtO9v6Ru73FLjVji4bwgla73h2telcL3/zilqWfta993ctR+e73ru5t7nnhq1QDT5S+A04weqWr2r72d8LfBfB4ObvhCLPXv3QlsILXK2EGgxi29BWBh/GLYf1WeLsXlu8vgwAAOw=="

/***/ }),
/* 1547 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhHAACAJEAAJrG/6yomf///wAAACwAAAAAHAACAAACCpSPqRvt/4CclBYAOw=="

/***/ }),
/* 1548 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1549);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1549 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-html-editor-tb .x-btn-icon .x-btn-text {\n    background-image: none;\n}\n\n.x-btn-icon .x-btn-small .x-btn-image {\n    background-size: 18px 18px !important;\n}\n\n.x-html-editor-tb .x-edit-bold, .x-menu-item img.x-edit-bold {\n    background: url(" + escape(__webpack_require__(1550)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-italic, .x-menu-item img.x-edit-italic {\n    background: url(" + escape(__webpack_require__(1551)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-underline, .x-menu-item img.x-edit-underline {\n    background: url(" + escape(__webpack_require__(1552)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-increasefontsize, .x-menu-item img.x-edit-increasefontsize {\n    background: url(" + escape(__webpack_require__(1553)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-decreasefontsize, .x-menu-item img.x-edit-decreasefontsize {\n    background: url(" + escape(__webpack_require__(1554)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-forecolor, .x-menu-item img.x-edit-forecolor {\n    background: url(" + escape(__webpack_require__(1555)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-backcolor, .x-menu-item img.x-edit-backcolor {\n    background: url(" + escape(__webpack_require__(1556)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-justifyleft, .x-menu-item img.x-edit-justifyleft {\n    background: url(" + escape(__webpack_require__(1557)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-justifycenter, .x-menu-item img.x-edit-justifycenter {\n    background: url(" + escape(__webpack_require__(1558)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-justifyright, .x-menu-item img.x-edit-justifyright {\n    background: url(" + escape(__webpack_require__(1559)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-createlink, .x-menu-item img.x-edit-createlink {\n    background: url(" + escape(__webpack_require__(368)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-insertorderedlist, .x-menu-item img.x-edit-insertorderedlist {\n    background: url(" + escape(__webpack_require__(1560)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-insertunorderedlist, .x-menu-item img.x-edit-insertunorderedlist {\n    background: url(" + escape(__webpack_require__(1561)) + ") !important;\n}\n\n.x-html-editor-tb .x-edit-sourceedit, .x-menu-item img.x-edit-sourceedit {\n    background: url(" + escape(__webpack_require__(1562)) + ") !important;\n}\n\n/*\n    html editor plugin button icons\n*/\n.x-edit-indent {background: url(" + escape(__webpack_require__(1563)) + ") 0 0 no-repeat !important;}\n.x-edit-outdent {background: url(" + escape(__webpack_require__(1564)) + ") 0 0 no-repeat !important;}\n.x-edit-removeFormat {background: url(" + escape(__webpack_require__(1565)) + ") 0 0 no-repeat !important;}\n.x-edit-toggleFormat {background: url(" + escape(__webpack_require__(1566)) + ") 0 0 no-repeat !important;}\n.x-edit-strikeThrough {background: url(" + escape(__webpack_require__(1567)) + ") 0 0 no-repeat !important;}\n.x-edit-formatblockPre {background: url(" + escape(__webpack_require__(365)) + ") 0 0 no-repeat !important;}\n\n/*\n    These are examples of styles for the button icons\n\n.x-edit-wordpaste {background: url(../images/document-word-text.png) 0 0 no-repeat !important;}\n.x-edit-table {background: url(../images/table.png) 0 0 no-repeat !important;}\n.x-edit-hr {background: url(../images/edit-rule.png) 0 0 no-repeat !important;}\n.x-edit-char {background: url(../images/edit-char.png) 0 0 no-repeat !important;}\n.x-edit-subscript {background: url(../images/text_sub.png) 0 0 no-repeat !important;}\n.x-edit-superscript {background: url(../images/text_super.png) 0 0 no-repeat !important;}\n*/\n\n/*\n    These styles are used for the character map\n*/\n.char-item {\n    float: left; \n    border: 1px solid #99BBE8; \n    margin: 3px; \n    text-align: center; \n    vertical-align: middle; \n    width: 20px; \n    height: 20px; \n    font-size: 14px;\n    color: #15428B;\n    cursor: pointer;\n}\n\n.char-item.x-view-selected {\n    background-color: #777;\n}\n\n.char-over {\n    border: 1px solid #15428B;\n    background-color:#d0def0;\n}\n", ""]);

// exports


/***/ }),
/* 1550 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M7.9,34.2c1.1,0,1.9-0.2,2.4-0.4c0.8-0.4,1.2-1.3,1.2-2.5V11.1c0-1.2-0.4-2-1.2-2.4C9.9,8.4,9.1,8.3,7.9,8.2V7.1h12.8 c2.5,0,4.5,0.3,6.2,0.9c3.1,1.1,4.6,3,4.6,5.8c0,1.7-0.6,3.1-1.9,4.1c-1.3,1-2.6,1.6-4.1,1.9v0.4c1.5,0.3,2.9,0.8,4,1.5 c2.2,1.4,3.3,3.3,3.3,5.8c0,2.3-1.1,4.2-3.2,5.6c-2.1,1.4-5,2.1-8.5,2.1H7.9V34.2z M23.4,18.5c0.9-0.8,1.3-2.3,1.3-4.5 c0-1.6-0.3-2.9-0.9-4c-0.6-1.1-1.7-1.6-3.3-1.6c-0.9,0-1.5,0.1-1.8,0.4c-0.3,0.3-0.5,0.8-0.5,1.6v9.3C20.8,19.7,22.5,19.3,23.4,18.5 z M18.5,33c0.3,0.6,1,0.9,1.9,0.9c2,0,3.3-0.5,4.1-1.6c0.8-1.1,1.2-2.6,1.2-4.6c0-2.9-0.9-4.9-2.6-5.9c-1.1-0.6-2.7-0.9-5-0.8v10.4 C18.2,32.1,18.3,32.7,18.5,33z'/%3E %3C/svg%3E\""

/***/ }),
/* 1551 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M12.8,34.5c1-0.1,1.7-0.3,2.1-0.5c0.6-0.4,1.1-1.3,1.4-2.6l5.3-19c0.2-0.8,0.3-1.3,0.4-1.6c0.1-0.3,0.1-0.6,0.1-0.9 c0-0.7-0.2-1.2-0.7-1.4c-0.4-0.3-1.2-0.4-2.4-0.5V7.2h10.7v0.7c-1.1,0.2-1.9,0.4-2.3,0.7C27,8.9,26.6,9.7,26.2,11l-5.3,19 c-0.2,0.7-0.3,1.2-0.4,1.7c-0.1,0.4-0.1,0.8-0.1,1c0,0.7,0.2,1.2,0.7,1.4c0.5,0.2,1.2,0.4,2.2,0.4v0.7H12.8V34.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1552 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Crect x='6.1' y='34.5' width='30.1' height='1.2'/%3E %3Cpath d='M17.9,5.1v0.8c-1.6,0.1-2.7,0.4-3.1,0.8c-0.5,0.4-0.7,1.4-0.7,3v13.4c0,2.2,0.3,3.9,0.9,5.1c1.1,2.2,3.2,3.4,6.4,3.4 c3.4,0,5.7-1.1,6.9-3.4c0.7-1.3,1-3.3,1-5.9V11.3C29.3,9,29,7.6,28.4,7c-0.5-0.6-1.6-0.9-3.1-1.1V5.1H35v0.8 c-1.6,0.2-2.7,0.6-3.2,1.2c-0.5,0.6-0.7,2-0.7,4.2v10.9c0,2.9-0.4,5.2-1.3,6.8c-1.6,3-4.8,4.5-9.3,4.5c-4.5,0-7.6-1.5-9.3-4.4 c-0.9-1.6-1.3-3.7-1.3-6.3V9.6c0-1.5-0.2-2.5-0.7-2.9C8.7,6.3,7.6,6,6.1,5.9V5.1H17.9z'/%3E %3C/svg%3E\""

/***/ }),
/* 1553 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M6.1,35.2v-0.8c1.1-0.1,1.9-0.5,2.4-1.2c0.5-0.7,1.5-2.6,2.7-5.6l8.7-20.4h0.8l10.4,23.6c0.7,1.6,1.2,2.5,1.7,2.9 c0.4,0.4,1.1,0.6,2.1,0.8v0.8H24.3v-0.8c1.2-0.1,2-0.2,2.3-0.4c0.4-0.2,0.5-0.5,0.5-1.1c0-0.2-0.1-0.6-0.2-1.1 c-0.1-0.5-0.3-1.1-0.6-1.6l-1.7-4h-11c-1.1,2.7-1.7,4.4-1.9,5c-0.2,0.6-0.3,1.1-0.3,1.4c0,0.7,0.3,1.2,0.9,1.5c0.4,0.2,1,0.3,2,0.4 v0.8H6.1z M24,24.6l-4.8-11.4l-4.8,11.4H24z M30.8,7.2c-0.1,0-0.3,0-0.3,0.1L27,10.8c-0.1,0.1-0.1,0.2-0.1,0.3s0,0.3,0.1,0.3 c0.1,0.1,0.2,0.1,0.3,0.1h7c0.1,0,0.3,0,0.3-0.1c0.1-0.1,0.1-0.2,0.1-0.3s0-0.3-0.1-0.3l-3.5-3.5C31,7.2,30.9,7.2,30.8,7.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1554 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M8.1,35.3v-0.6c0.8-0.1,1.4-0.4,1.7-0.9s1.1-1.9,2-4.1l6.3-14.8h0.6L26.2,32c0.5,1.1,0.9,1.8,1.2,2.1 c0.3,0.3,0.8,0.5,1.5,0.5v0.6h-7.7v-0.6c0.9-0.1,1.5-0.2,1.7-0.3s0.4-0.4,0.4-0.8c0-0.1,0-0.4-0.1-0.8s-0.2-0.8-0.4-1.2l-1.2-2.9h-8 c-0.8,2-1.3,3.2-1.4,3.6c-0.1,0.4-0.2,0.8-0.2,1c0,0.5,0.2,0.9,0.6,1.1c0.3,0.1,0.7,0.2,1.4,0.3v0.6H8.1V35.3z M21.1,27.5l-3.5-8.3 l-3.5,8.3H21.1z'/%3E %3Cpath d='M28.4,11.5L25,8c-0.1-0.1-0.1-0.2-0.1-0.3s0-0.3,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h7c0.1,0,0.3,0,0.3,0.1 c0.1,0.1,0.1,0.2,0.1,0.3s0,0.3-0.1,0.3l-3.5,3.5c-0.1,0.1-0.2,0.1-0.3,0.1S28.5,11.6,28.4,11.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1555 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23E4003A;%7D %3C/style%3E %3Cpath class='st0' d='M7.3,32.9v-0.8c1.1-0.1,1.9-0.5,2.4-1.2c0.5-0.7,1.5-2.6,2.7-5.6L21.1,5H22l10.4,23.6c0.7,1.6,1.2,2.5,1.7,2.9 c0.4,0.4,1.1,0.6,2.1,0.8v0.8H25.5v-0.8c1.2-0.1,2-0.2,2.3-0.4c0.4-0.2,0.5-0.5,0.5-1.1c0-0.2-0.1-0.6-0.2-1.1s-0.3-1.1-0.6-1.6 l-1.7-4H15c-1.1,2.7-1.7,4.4-1.9,5s-0.3,1.1-0.3,1.4c0,0.7,0.3,1.2,0.9,1.5c0.4,0.2,1,0.3,2,0.4v0.8H7.3V32.9z M25.2,22.3l-4.8-11.4 l-4.8,11.4H25.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1556 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cstyle type='text/css'%3E .st0%7Bfill:%23FFED00;%7D %3C/style%3E %3Crect x='3.1' y='10.2' class='st0' width='27.6' height='22'/%3E %3Cpath d='M7.4,24.4c0.8-0.5,2.4-1.2,4.7-2.1v-1.1c0-0.9-0.1-1.5-0.3-1.8c-0.3-0.6-0.9-0.9-1.8-0.9c-0.4,0-0.9,0.1-1.2,0.3 c-0.4,0.2-0.6,0.5-0.6,1c0,0.1,0,0.3,0.1,0.5c0,0.2,0.1,0.4,0.1,0.5c0,0.5-0.2,0.8-0.5,1C7.7,21.9,7.5,22,7.2,22 c-0.4,0-0.7-0.1-0.9-0.4C6.1,21.4,6,21.1,6,20.8c0-0.6,0.4-1.2,1.1-1.9c0.7-0.7,1.8-1,3.3-1c1.7,0,2.8,0.5,3.4,1.6 c0.3,0.6,0.5,1.5,0.5,2.6v5.2c0,0.5,0,0.8,0.1,1c0.1,0.3,0.3,0.5,0.7,0.5c0.2,0,0.4,0,0.5-0.1c0.1-0.1,0.4-0.2,0.7-0.4V29 c-0.3,0.3-0.6,0.6-0.9,0.8c-0.5,0.3-1,0.5-1.5,0.5c-0.6,0-1-0.2-1.3-0.6s-0.4-0.8-0.4-1.4c-0.7,0.6-1.2,1-1.7,1.3 c-0.8,0.5-1.5,0.7-2.2,0.7c-0.7,0-1.4-0.3-1.9-0.8c-0.5-0.5-0.8-1.2-0.8-2C5.5,26.3,6.2,25.3,7.4,24.4z M12.1,23 c-1,0.3-1.8,0.7-2.4,1.1c-1.2,0.8-1.9,1.6-1.9,2.6c0,0.8,0.3,1.4,0.8,1.7c0.3,0.2,0.7,0.4,1.1,0.4c0.6,0,1.1-0.2,1.6-0.5 s0.8-0.7,0.8-1.2V23z M16.4,13.7v-0.4c1-0.2,1.9-0.5,2.6-0.7c0.8-0.3,1.2-0.4,1.3-0.4c0,0.1,0,0.1,0,0.2v7.8c0.2-0.4,0.6-0.8,1-1.2 c0.8-0.6,1.7-1,2.7-1c1.3,0,2.3,0.5,3.2,1.6s1.3,2.4,1.3,4.1c0,1.8-0.6,3.4-1.7,4.7c-1.2,1.3-2.7,1.9-4.6,1.9c-1,0-1.9-0.2-2.8-0.6 c-0.9-0.4-1.4-0.8-1.4-1.1V15.1c0-0.5-0.1-0.9-0.2-1.1c-0.1-0.2-0.5-0.3-1-0.3L16.4,13.7z M21.3,29.2c0.6,0.2,1.1,0.3,1.6,0.3 c1.2,0,2.1-0.4,2.7-1.3c0.6-0.9,0.9-2,0.9-3.3s-0.3-2.5-0.8-3.5c-0.5-1.1-1.4-1.6-2.6-1.6c-0.6,0-1.2,0.2-1.8,0.6 c-0.6,0.4-0.9,0.8-0.9,1.4v6.6C20.3,28.7,20.7,29,21.3,29.2z M35,22.8c0.1,0,0.3,0,0.3-0.1l3.5-3.5c0.1-0.1,0.1-0.2,0.1-0.3 s0-0.3-0.1-0.3c-0.1-0.1-0.2-0.1-0.3-0.1h-7c-0.1,0-0.3,0-0.3,0.1c-0.1,0.1-0.1,0.2-0.1,0.3s0,0.3,0.1,0.3l3.5,3.5 C34.8,22.8,34.9,22.8,35,22.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 1557 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='linksbündig_1_' d='M35.4,26v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H6.7c-0.2,0-0.3,0-0.5-0.1S6,28.9,6,28.8V26 c0-0.1,0.1-0.2,0.2-0.3c0.1-0.1,0.3-0.1,0.5-0.1h28.1c0.2,0,0.3,0,0.5,0.1C35.4,25.8,35.4,25.9,35.4,26z M34.3,32.1v2.8 c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H6.6c-0.2,0-0.3,0-0.5-0.1C6.1,35.1,6,35,6,34.9v-2.8c0-0.1,0.1-0.2,0.2-0.3 c0.1-0.1,0.3-0.1,0.5-0.1h27.1c0.2,0,0.3,0,0.5,0.1C34.3,31.9,34.3,32,34.3,32.1z M32.1,19.7v2.8c0,0.1-0.1,0.2-0.2,0.3 c-0.1,0.1-0.3,0.1-0.4,0.1H6.6c-0.2,0-0.3,0-0.4-0.1C6.1,22.7,6,22.6,6,22.5v-2.8c0-0.1,0.1-0.2,0.2-0.3c0.1-0.1,0.3-0.1,0.4-0.1 h24.9c0.2,0,0.3,0,0.4,0.1C32.1,19.5,32.1,19.6,32.1,19.7z M27.5,13.6v2.8c0,0.1,0,0.2-0.1,0.3c-0.1,0.1-0.2,0.1-0.3,0.1H6.5 c-0.1,0-0.2,0-0.3-0.1C6,16.6,6,16.4,6,16.3v-2.8c0-0.1,0-0.2,0.1-0.3s0.2-0.1,0.3-0.1H27c0.1,0,0.2,0,0.3,0.1S27.5,13.4,27.5,13.6z M34.3,7.5v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H6.6c-0.2,0-0.3,0-0.5-0.1C6.1,10.5,6,10.3,6,10.2V7.5c0-0.1,0.1-0.2,0.2-0.3 C6.3,7,6.5,7,6.6,7h27.1c0.2,0,0.3,0,0.5,0.1C34.3,7.2,34.3,7.3,34.3,7.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1558 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='mittelachsig' d='M10.6,31.8c0.1-0.1,0.2-0.1,0.3-0.1h18.9c0.1,0,0.2,0,0.3,0.1c0.1,0.1,0.1,0.2,0.1,0.3v2.8 c0,0.1,0,0.2-0.1,0.3c-0.1,0.1-0.2,0.1-0.3,0.1H10.9c-0.1,0-0.2,0-0.3-0.1s-0.1-0.2-0.1-0.3v-2.8C10.5,32,10.5,31.9,10.6,31.8z M7.3,7.1C7.4,7,7.5,7,7.7,7h27.1c0.2,0,0.3,0,0.5,0.1c0.1,0.1,0.2,0.2,0.2,0.3v2.8c0,0.1-0.1,0.2-0.2,0.3c-0.1,0.1-0.3,0.1-0.5,0.1 H7.7c-0.2,0-0.3,0-0.5-0.1c-0.1-0.1-0.2-0.2-0.2-0.3V7.5C7.1,7.3,7.1,7.2,7.3,7.1z M6.2,25.8c0.1-0.1,0.3-0.1,0.5-0.1h28.1 c0.2,0,0.3,0,0.5,0.1c0.1,0.1,0.2,0.2,0.2,0.3v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H6.7c-0.2,0-0.3,0-0.5-0.1 C6.1,29.1,6,29,6,28.9v-2.8C6,26,6.1,25.9,6.2,25.8z M7.8,19.4c0.1-0.1,0.3-0.1,0.4-0.1h24.9c0.2,0,0.3,0,0.4,0.1s0.2,0.2,0.2,0.3 v2.8c0,0.1-0.1,0.2-0.2,0.3c-0.1,0.1-0.3,0.1-0.4,0.1H8.3c-0.2,0-0.3,0-0.4-0.1c-0.1-0.1-0.2-0.2-0.2-0.3v-2.8 C7.7,19.6,7.7,19.5,7.8,19.4z M11.8,13.4c0.1-0.1,0.2-0.1,0.3-0.1h17.5c0.1,0,0.2,0,0.3,0.1s0.1,0.2,0.1,0.3v2.8 c0,0.1,0,0.2-0.1,0.3s-0.2,0.1-0.3,0.1H12.1c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8C11.7,13.6,11.7,13.4,11.8,13.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1559 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='rechtachsig' d='M6.2,25.7c0.1-0.1,0.3-0.1,0.5-0.1h28.1c0.2,0,0.3,0,0.5,0.1c0.1,0.1,0.2,0.2,0.2,0.3v2.8 c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H6.7c-0.2,0-0.3,0-0.5-0.1C6.1,29,6,28.9,6,28.8V26C6,25.9,6.1,25.8,6.2,25.7z M7.3,31.8 c0.1-0.1,0.3-0.1,0.5-0.1h27.1c0.2,0,0.3,0,0.5,0.1c0.1,0.1,0.2,0.2,0.2,0.3v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H7.7 c-0.2,0-0.3,0-0.5-0.1c-0.1-0.1-0.2-0.2-0.2-0.3v-2.8C7.1,32,7.1,31.9,7.3,31.8z M9.5,19.4c0.1-0.1,0.3-0.1,0.4-0.1l24.9,0 c0.2,0,0.3,0,0.4,0.1c0.1,0.1,0.2,0.2,0.2,0.3v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.4,0.1H9.9c-0.2,0-0.3,0-0.4-0.1 c-0.1-0.1-0.2-0.2-0.2-0.3v-2.8C9.3,19.6,9.3,19.5,9.5,19.4z M14.1,13.2c0.1-0.1,0.2-0.1,0.3-0.1h20.5c0.1,0,0.2,0,0.3,0.1 s0.1,0.2,0.1,0.3v2.8c0,0.1,0,0.2-0.1,0.3c-0.1,0.1-0.2,0.1-0.3,0.1H14.4c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8 C13.9,13.4,14,13.3,14.1,13.2z M7.3,7.1C7.4,7,7.5,7,7.7,7h27.1c0.2,0,0.3,0,0.5,0.1c0.1,0.1,0.2,0.2,0.2,0.3v2.8 c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1H7.7c-0.2,0-0.3,0-0.5-0.1c-0.1-0.1-0.2-0.2-0.2-0.3V7.5C7.1,7.3,7.1,7.2,7.3,7.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1560 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38.2,29.9v3.9c0,0.2-0.1,0.3-0.2,0.5s-0.3,0.2-0.5,0.2H10.5c-0.2,0-0.3-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5v-3.9 c0-0.2,0.1-0.3,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h27.1c0.2,0,0.3,0.1,0.5,0.2C38.1,29.5,38.2,29.7,38.2,29.9z M38.2,18.7v3.9 c0,0.2-0.1,0.3-0.2,0.5c-0.1,0.1-0.3,0.2-0.5,0.2H10.5c-0.2,0-0.3-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5v-3.9c0-0.2,0.1-0.3,0.2-0.5 c0.1-0.1,0.3-0.2,0.5-0.2h27.1c0.2,0,0.3,0.1,0.5,0.2S38.2,18.5,38.2,18.7z M38.2,7.7v3.9c0,0.2-0.1,0.3-0.2,0.5s-0.3,0.2-0.5,0.2 H10.5c-0.2,0-0.3-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5V7.7c0-0.2,0.1-0.3,0.2-0.5C10.1,7.1,10.3,7,10.5,7h27.1 c0.2,0,0.3,0.1,0.5,0.2S38.2,7.5,38.2,7.7z M5.7,6.2C5.7,6.2,5.7,6.2,5.7,6.2l0,5.3c0,0.2,0.1,0.4,0.2,0.4s0.3,0.1,0.7,0.1v0.1H4.1 v-0.1c0.4,0,0.6-0.1,0.7-0.1S5,11.7,5,11.4V7.4c0-0.1,0-0.2-0.1-0.3S4.8,6.9,4.7,6.9C4.6,6.9,4.5,7,4.4,7C4.3,7,4.2,7.1,4,7.1V7 L5.7,6.2L5.7,6.2C5.7,6.2,5.7,6.2,5.7,6.2z M3.3,23.1c1.1-1.1,1.8-1.9,2.2-2.5s0.6-1,0.6-1.5c0-0.4-0.1-0.8-0.4-1s-0.5-0.3-0.8-0.3 c-0.4,0-0.7,0.1-1,0.4c-0.1,0.2-0.3,0.4-0.4,0.7l-0.2,0c0.1-0.7,0.4-1.1,0.7-1.4s0.7-0.4,1.1-0.4c0.5,0,0.9,0.2,1.2,0.5 c0.3,0.3,0.5,0.7,0.5,1.1c0,0.5-0.2,0.9-0.5,1.4c-0.3,0.4-1.1,1.2-2.2,2.4h2c0.3,0,0.5,0,0.6-0.1s0.2-0.2,0.4-0.5L7.3,22l-0.5,1.2 H3.3V23.1z M4.4,33.7C4.7,33.9,4.9,34,5.1,34c0.4,0,0.7-0.1,0.9-0.4s0.3-0.6,0.3-0.9c0-0.3-0.1-0.6-0.2-0.8 c-0.3-0.4-0.7-0.6-1.4-0.6c0,0-0.1,0-0.1,0c0,0-0.1,0-0.1,0l0-0.1c0.5-0.2,0.8-0.4,1.1-0.6s0.4-0.5,0.4-0.9c0-0.3-0.1-0.6-0.3-0.7 c-0.2-0.2-0.5-0.3-0.7-0.3c-0.3,0-0.6,0.1-0.9,0.4c-0.1,0.1-0.3,0.3-0.4,0.6l-0.1,0c0.1-0.4,0.3-0.8,0.7-1.1s0.7-0.4,1.1-0.4 c0.4,0,0.8,0.1,1,0.4c0.2,0.2,0.4,0.5,0.4,0.9c0,0.3-0.1,0.5-0.3,0.8c-0.1,0.1-0.3,0.3-0.5,0.5c0.3,0.1,0.5,0.3,0.7,0.4 c0.3,0.3,0.5,0.7,0.5,1.2c0,0.6-0.2,1-0.7,1.5s-1.1,0.6-1.9,0.6c-0.4,0-0.6-0.1-0.8-0.2c-0.1-0.1-0.2-0.2-0.2-0.3 c0-0.1,0-0.1,0.1-0.2c0-0.1,0.1-0.1,0.2-0.1C3.9,33.5,4.1,33.5,4.4,33.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 1561 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38.2,29.9v3.9c0,0.2-0.1,0.3-0.2,0.5s-0.3,0.2-0.5,0.2H10.5c-0.2,0-0.3-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5v-3.9 c0-0.2,0.1-0.3,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h27.1c0.2,0,0.3,0.1,0.5,0.2C38.1,29.5,38.2,29.7,38.2,29.9z M38.2,18.7v3.9 c0,0.2-0.1,0.3-0.2,0.5c-0.1,0.1-0.3,0.2-0.5,0.2H10.5c-0.2,0-0.3-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5v-3.9c0-0.2,0.1-0.3,0.2-0.5 c0.1-0.1,0.3-0.2,0.5-0.2h27.1c0.2,0,0.3,0.1,0.5,0.2S38.2,18.5,38.2,18.7z M38.2,7.7v3.9c0,0.2-0.1,0.3-0.2,0.5s-0.3,0.2-0.5,0.2 H10.5c-0.2,0-0.3-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5V7.7c0-0.2,0.1-0.3,0.2-0.5C10.1,7.1,10.3,7,10.5,7h27.1 c0.2,0,0.3,0.1,0.5,0.2S38.2,7.5,38.2,7.7z M4,10.6c-0.3-0.3-0.5-0.7-0.5-1.2c0-0.5,0.2-0.9,0.5-1.2s0.7-0.5,1.2-0.5 s0.9,0.2,1.2,0.5s0.5,0.7,0.5,1.2c0,0.5-0.2,0.9-0.5,1.2s-0.7,0.5-1.2,0.5C4.8,11.1,4.4,10.9,4,10.6z M4,21.6 c-0.3-0.3-0.5-0.7-0.5-1.2c0-0.5,0.2-0.9,0.5-1.2s0.7-0.5,1.2-0.5s0.9,0.2,1.2,0.5s0.5,0.7,0.5,1.2c0,0.5-0.2,0.9-0.5,1.2 s-0.7,0.5-1.2,0.5C4.8,22.1,4.4,21.9,4,21.6z M4,32.6c-0.3-0.3-0.5-0.7-0.5-1.2c0-0.5,0.2-0.9,0.5-1.2s0.7-0.5,1.2-0.5 s0.9,0.2,1.2,0.5s0.5,0.7,0.5,1.2c0,0.5-0.2,0.9-0.5,1.2s-0.7,0.5-1.2,0.5C4.8,33.1,4.4,32.9,4,32.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1562 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M8.4,19.2l5.5,2.4V25l-8.8-4.4v-2.9l8.8-4.4v3.4L8.4,19.2z M17.9,28.2h-2.5l5.3-19.1h2.5L17.9,28.2z M26.1,31.8l1.4-3 l-4-1.8l-1.4,3l0.4,1.1l1.8-0.7l0.7,1.8L26.1,31.8z M29.4,15c-0.3-0.1-0.5,0-0.6,0.3l-4.2,9.1c-0.1,0.3-0.1,0.5,0.2,0.6 c0.3,0.1,0.5,0,0.6-0.3l4.2-9.1C29.7,15.3,29.6,15.1,29.4,15z M28,12.4l7.5,3.4l-8,17.6l-5.5,2.1L20.1,30L28,12.4z M37.4,11.7 l-1.1,2.4l-7.5-3.4l1.1-2.4c0.2-0.5,0.6-0.8,1.1-1c0.5-0.2,1-0.2,1.5,0l4,1.8c0.5,0.2,0.8,0.6,1,1.1C37.6,10.7,37.6,11.2,37.4,11.7z '/%3E %3C/svg%3E\""

/***/ }),
/* 1563 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M35.3,7.5v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1h-28c-0.2,0-0.3,0-0.5-0.1S6,10.3,6,10.2V7.5c0-0.1,0.1-0.2,0.2-0.3 C6.3,7,6.5,7,6.7,7h28c0.2,0,0.3,0,0.5,0.1C35.2,7.2,35.3,7.3,35.3,7.5z'/%3E %3Cpath d='M24,13.6v2.8c0,0.1,0,0.2-0.1,0.3c-0.1,0.1-0.2,0.1-0.3,0.1H6.5c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8 c0-0.1,0-0.2,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h17.2c0.1,0,0.2,0,0.3,0.1C24,13.4,24,13.5,24,13.6z'/%3E %3Cpath d='M24,19.7v2.8c0,0.1,0,0.2-0.1,0.3c-0.1,0.1-0.2,0.1-0.3,0.1H6.5c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8 c0-0.1,0-0.2,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h17.2c0.1,0,0.2,0,0.3,0.1C24,19.5,24,19.6,24,19.7z'/%3E %3Cpath d='M24,26.1v2.8c0,0.1,0,0.2-0.1,0.3c-0.1,0.1-0.2,0.1-0.3,0.1H6.5c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8 c0-0.1,0-0.2,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h17.2c0.1,0,0.2,0,0.3,0.1C24,25.8,24,25.9,24,26.1z'/%3E %3Cpath d='M35.3,32.1v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1h-28c-0.2,0-0.3,0-0.5-0.1S6,35,6,34.9v-2.8c0-0.1,0.1-0.2,0.2-0.3 c0.1-0.1,0.3-0.1,0.5-0.1h28c0.2,0,0.3,0,0.5,0.1C35.2,31.9,35.3,32,35.3,32.1z'/%3E %3Cpath d='M31.8,21.7l-3.5,3.5c-0.1,0.1-0.2,0.1-0.3,0.1s-0.3,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-7c0-0.1,0-0.3,0.1-0.3 c0.1-0.1,0.2-0.1,0.3-0.1s0.3,0,0.3,0.1l3.5,3.5c0.1,0.1,0.1,0.2,0.1,0.3S31.9,21.6,31.8,21.7z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1564 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M36.3,7.5v2.8c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1h-28c-0.2,0-0.3,0-0.5-0.1S7,10.3,7,10.2V7.5c0-0.1,0.1-0.2,0.2-0.3 C7.3,7,7.5,7,7.7,7h28c0.2,0,0.3,0,0.5,0.1C36.2,7.2,36.3,7.3,36.3,7.5z M36.3,13.6v2.8c0,0.1,0,0.2-0.1,0.3s-0.2,0.1-0.3,0.1H18.7 c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8c0-0.1,0-0.2,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h17.2c0.1,0,0.2,0,0.3,0.1 C36.3,13.4,36.3,13.5,36.3,13.6z M36.3,19.7v2.8c0,0.1,0,0.2-0.1,0.3S36,23,35.9,23H18.7c-0.1,0-0.2,0-0.3-0.1 c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8c0-0.1,0-0.2,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h17.2c0.1,0,0.2,0,0.3,0.1S36.3,19.6,36.3,19.7z M36.3,26.1v2.8c0,0.1,0,0.2-0.1,0.3s-0.2,0.1-0.3,0.1H18.7c-0.1,0-0.2,0-0.3-0.1c-0.1-0.1-0.1-0.2-0.1-0.3v-2.8 c0-0.1,0-0.2,0.1-0.3c0.1-0.1,0.2-0.1,0.3-0.1h17.2c0.1,0,0.2,0,0.3,0.1C36.3,25.8,36.3,25.9,36.3,26.1z M36.3,32.1v2.8 c0,0.1-0.1,0.2-0.2,0.3s-0.3,0.1-0.5,0.1h-28c-0.2,0-0.3,0-0.5-0.1S7,35,7,34.9v-2.8c0-0.1,0.1-0.2,0.2-0.3c0.1-0.1,0.3-0.1,0.5-0.1 h28c0.2,0,0.3,0,0.5,0.1C36.2,31.9,36.3,32,36.3,32.1z M10.2,21.3c0,0.1,0,0.3,0.1,0.3l3.5,3.5c0.1,0.1,0.2,0.1,0.3,0.1 s0.3,0,0.3-0.1c0.1-0.1,0.1-0.2,0.1-0.3v-7c0-0.1,0-0.3-0.1-0.3s-0.2-0.1-0.3-0.1s-0.3,0-0.3,0.1L10.4,21 C10.3,21.1,10.2,21.2,10.2,21.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1565 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38.1,35.1L24.3,35l16.2-16.2c0.4-0.4,0.4-1.2,0-1.6L27.6,4.3C27.4,4.1,27.1,4,26.8,4c-0.3,0-0.6,0.1-0.8,0.3L1.6,28.7 c-0.4,0.4-0.4,1.2,0,1.6L9,37.7C9.2,37.9,9.5,38,9.8,38h29.9c0.6,0,1.5-0.4,1.5-1.5c0-0.6-0.7-1.3-1.3-1.3L38.1,35.1z M26.7,7.6 l10.5,10.5L24.8,30.5L14.3,20L26.7,7.6z M19.7,35.2h-9.2l-5.7-5.7l7.2-7.2l10.3,10.3L19.7,35.2z M20.3,35.7'/%3E %3C/svg%3E\""

/***/ }),
/* 1566 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M9.2,7.1h24.1l0.2,7.3h-1c-0.5-2.3-1.1-3.8-1.9-4.5c-0.8-0.7-2.4-1-4.9-1h-2.4v21.8c0,1.6,0.3,2.7,0.8,3.1 c0.5,0.4,1.6,0.7,3.4,0.8v0.8H15.1v-0.8c1.8-0.1,2.9-0.4,3.4-0.9c0.4-0.5,0.7-1.6,0.7-3.4V8.9h-2.4c-2.4,0-4,0.3-4.8,1 c-0.9,0.7-1.5,2.2-1.9,4.5H9L9.2,7.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1567 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.2.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M20.2,22.5h7.7c0.5,0.4,0.8,0.8,1.2,1.2c0.9,1.2,1.4,2.6,1.4,4.2c0,2.2-0.8,4-2.4,5.4s-3.7,2.2-6.2,2.2 c-1.3,0-2.6-0.2-4-0.7c-1.4-0.5-2.2-0.7-2.4-0.7c-0.5,0-0.8,0.1-1,0.4c-0.2,0.3-0.3,0.6-0.3,0.9h-0.9l-1.2-8.8h0.9 c0.7,1.8,1.5,3.3,2.4,4.4c1.6,1.9,3.7,2.9,6.1,2.9c1.3,0,2.4-0.4,3.4-1.2s1.4-2,1.4-3.5c0-1.3-0.5-2.5-1.4-3.5c-0.6-0.6-2-1.6-4-2.8 L20.2,22.5z M36.3,20.6H6.2v1.2h30.1V20.6z M20.7,17.6c-1.4-0.8-2.3-1.6-3-2.4c-0.6-0.7-1-1.7-1-2.7c0-1.2,0.4-2.1,1.3-2.8 c0.8-0.7,1.8-1,2.9-1c1.4,0,2.9,0.5,4.4,1.6c1.5,1,2.6,2.9,3.2,5.5h1l-0.9-8.8h-0.8c-0.1,0.4-0.3,0.8-0.5,1 c-0.2,0.2-0.5,0.4-1.1,0.4c-0.2,0-0.9-0.2-2.3-0.7s-2.4-0.7-3.4-0.7c-2.3,0-4.1,0.7-5.5,2.1c-1.4,1.4-2.1,3.1-2.1,5.2 c0,1.6,0.6,3,1.7,4.3c0.4,0.4,0.8,0.8,1.3,1.2h8.1L20.7,17.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1568 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1569);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1569 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".ux-layercombo-layer form {\n    background-color: #E5EDF8\n}", ""]);

// exports


/***/ }),
/* 1570 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1571);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1571 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".ux-pp-field {\n    width: 100%;\n}\n\n.ux-pp-field {\n    float: left;\n}\n\n.ux-pp-range {\n    float: left;\n}\n\n.ux-pp-controls {\n    float: left;\n    position: relative;\n}\n\n.ux-pp-period {\n    width: 100%;\n    padding-top: 2px;\n    box-sizing: border-box;\n    border-left: 15px solid transparent;\n    border-right: 15px solid transparent;\n    text-align: center;\n    cursor: pointer;\n}\n\n.ux-pp-prev {\n    background-image: url(" + escape(__webpack_require__(593)) + ");\n    left: 0px;\n}\n\n.ux-pp-prev:hover {\n    background-image: url(" + escape(__webpack_require__(591)) + ");\n}\n\n.ux-pp-next {\n    background-image: url(" + escape(__webpack_require__(592)) + ");\n    right: 0px;\n    top: 0px;\n}\n\n.ux-pp-next:hover {\n    background-image: url(" + escape(__webpack_require__(590)) + ");\n}\n\n.ux-pp-prev, .ux-pp-next, .ux-pp-mode {\n    overflow: hidden;\n    width: 15px;\n    height: 15px;\n    cursor: pointer;\n    position: absolute;\n    margin: 2px;\n    opacity: 0.6;\n}\n\n.ux-pp-mode {\n    background-image: url(" + escape(__webpack_require__(395)) + ");\n    left: 17px;\n}\n.ux-pp-mode-absolute {\n    background-position: 15px -135px;\n}\n\n.ux-pp-mode-relative {\n    background-position: 0px -135px;\n}\n\n.x-pp-combo {\n    position: absolute;\n    top: 0;\n}\n\n.x-pp-combo .ux-pp-prev, .x-pp-combo .ux-pp-next {\n    margin-top: 1px;\n}\n\n.x-pp-combo .ux-pp-period {\n    margin-top: 1px;\n}\n\n.ux-pp-this .ux-pp-period {\n    font-weight: bold;\n}", ""]);

// exports


/***/ }),
/* 1572 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1573);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1573 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-ux-display .x-panel-body {\n    background-color: #F3F6F7;\n}\n.x-ux-display .x-panel-bwrap {\n    background: none;\n}\n\n.x-ux-display .x-form-item {\n    overflow: hidden;\n    line-height: 12px;\n}\n\n.x-ux-display label.x-form-item-label {\n    white-space: nowrap;\n    color:#A0A0A0;\n    text-align:right;\n    font-size:11px;\n    padding-left: 5px;\n    padding-bottom: 1px;\n}\n\n.x-ux-display .x-form-element {\n    color:#404040;\n    font-family:verdana;\n    font-size:11px;\n    padding-left: 5px !important;\n}\n\n.x-form-item.x-ux-dislplay-no-label,\n.x-ux-display .x-form-element.x-ux-dislplay-no-label {\n    padding: 0 !important;\n}\n\n.x-ux-display textarea.x-ux-display-textarea {\n    background: none;\n    border: none;\n}\n\n.x-ux-display .x-ux-display-background-border textarea.x-ux-display-textarea {\n    background: none;\n    border: none;\n    /*border: 1px solid #99BBE8;*/\n    /*-moz-border-radius: 8px;*/\n    /*-webkit-border-radius: 8px;*/\n    /*-khtml-border-radius: 8px;*/\n}\n\n.x-ux-display .x-ux-display-background-solid {\n    border: none;\n    /*border: 1px solid #e5e6fe;*/\n    /*background-color: #e5e6fe;*/\n    /*-moz-border-radius: 8px;*/\n    /*-webkit-border-radius: 8px;*/\n    /*-khtml-border-radius: 8px;*/\n}\n\n.x-ux-display .x-ux-display-background-inner {\n    border: none;\n    /*background-color: #e5e6fe;*/\n    /*-moz-border-radius: 0px;*/\n    /*-webkit-border-radius: 0px;*/\n    /*-khtml-border-radius: 0px;*/\n}\n\n.x-ux-display .x-ux-display-background-border {\n    border: none;\n    /*border: 1px solid #99BBE8;*/\n    /*-moz-border-radius: 8px;*/\n    /*-webkit-border-radius: 8px;*/\n    /*-khtml-border-radius: 8px;*/\n}\n\n.x-ux-display-background-border {\n    background-color: #F3F6F7;\n}\n\n.x-ux-display .x-ux-display-declaration {\n    color:#A0A0A0;\n    font-size:12px;\n    font-weight:bold;\n}\n\n.x-ux-display .x-ux-display-header {\n    color:#505050;\n    font-size:10px;\n    font-weight:bold;\n}\n\n.x-ux-display .x-ux-display-header .x-tree-node-leaf img {\n    height: 16px;\n}\n\n.x-ux-display .x-ux-display-background-declaration {\n    position: absolute;\n    left:5px;\n    bottom:6px;\n}\n\n.x-ux-display .x-form-item {\n    display: flex;\n    padding-left: 2px;\n}\n\n/* NOTE: this makes ugly details panel in edit dialogs\n.tw-editdialog .x-form-item .x-form-display-field {*/\n    /*border: 1px solid #b5b8c8;*/\n    /*padding: 3px;*/\n    /*height: 11px;*/\n    /*background-color:#fff;*/\n    /*background-image:url(../../../../themes/tine20/resources/images/tine20/form/text-bg.gif);*/\n/*}*/\n\n.x-ux-displayfield-text {\n    background-image: none;\n}\n\n.x-ux-display p {\n    padding: 2px;\n    color: #505050;\n}\n", ""]);

// exports


/***/ }),
/* 1574 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1575);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1575 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * \n */\n.ux-layout-center-item {\n    margin:0 auto;\n    text-align:left;\n}\n.ux-layout-center .x-panel-body,   \nbody.ux-layout-center {            \n    text-align:center;\n}\n", ""]);

// exports


/***/ }),
/* 1576 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1577);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1577 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Ext JS Library 3.1+\n * Copyright(c) 2006-2009 Ext JS, LLC\n * licensing@extjs.com\n * http://www.extjs.com/license\n */\n.x-treegrid-root-table {\n    border-right: 1px solid;\n}\n\n.x-treegrid-root-node {\n    overflow: auto;\n}\n\n.x-treegrid-hd-hidden {\n    visibility: hidden;\n    border: 0;\n    width: 0;\n}\n\n.x-treegrid-col {\n    border-bottom: 1px solid;\n    height: 20px;\n    overflow: hidden;\n    vertical-align: top;\n    -o-text-overflow: ellipsis;\n    text-overflow: ellipsis;\n    white-space: nowrap;\n}\n\n.x-treegrid-text {\n    padding-left: 4px;\n    -moz-user-select: none;\n    -khtml-user-select: none;\n}\n\n.x-treegrid-resizer {\n    border-left:1px solid;\n    border-right:1px solid;\n    position:absolute;\n    left:0;\n    top:0;\n}\n\n.x-treegrid-header-inner {\n    overflow: hidden;\n}\n\n.x-treegrid-root-table,\n.x-treegrid-col {\n    border-color: #ededed;\n}\n\n.x-treegrid-resizer {\n    border-left-color:#555;\n    border-right-color:#555;\n}", ""]);

// exports


/***/ }),
/* 1578 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1579);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1579 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "span.x-form-twin-triggers img.x-form-locked-trigger{\n    background-image: url(" + escape(__webpack_require__(647)) + ");\n    cursor:pointer;\n}\n\nspan.x-form-twin-triggers img.x-form-unlocked-trigger{\n    background-image: url(" + escape(__webpack_require__(648)) + ");\n    cursor:pointer;\n}", ""]);

// exports


/***/ }),
/* 1580 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1581);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1581 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "img.x-form-trigger.x-form-locked-trigger{\n    background-image: url(" + escape(__webpack_require__(647)) + ");\n    cursor:pointer;\n}\n\nimg.x-form-trigger.x-form-unlocked-trigger{\n    background-image: url(" + escape(__webpack_require__(648)) + ");\n    cursor:pointer;\n}", ""]);

// exports


/***/ }),
/* 1582 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1583);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1583 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-ux-menu-title {\n    background: #ebeadb url(" + escape(__webpack_require__(232)) + ") repeat-x;\n    border-bottom:1px solid #99bbe8;\n    color:#15428b;\n    font:bold 10px tahoma,arial,verdana,sans-serif;\n    display:block;\n    padding:3px;\n}", ""]);

// exports


/***/ }),
/* 1584 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1585);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1585 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-ux-messagebox-msg .x-box-mc {\n    font-size:14px;\n}\n#x-ux-messagebox-msg-div {\n    position:absolute;\n    left:100px;\n    top:10px;\n    width:250px;\n    z-index:20000;\n}\n", ""]);

// exports


/***/ }),
/* 1586 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1587);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1587 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-panel-footer .x-form-item label {\n    float: left;\n}\n.x-panel-footer .x-form-item div {\n    padding-top: 0px;\n}\n.tw-editdialog .x-panel-footer {\n    background-color: rgb(240, 240, 240);\n}\n", ""]);

// exports


/***/ }),
/* 1588 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1589);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1589 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-widget-tag-action-detach {\n    background-image:url(" + escape(__webpack_require__(1590)) + ") !important;\n}\n\n.action_tag {\n    background-image:url(" + escape(__webpack_require__(1591)) + ") !important;\n}\n\n.action_tag_delete {\n    background-image:url(" + escape(__webpack_require__(1592)) + ") !important;\n}\n\n.x-widget-tag-tagitem {\n    margin: 1px 2px 1px 1px;\n    background-color: #FFF8E0;\n    height: 13px;\n    border: 1px solid gray;\n    float: left;\n    color: gray;\n}\n\n.x-widget-tag-tagitem-color {\n    padding: 0 0 0 0;\n    margin: 0 0 0 0;\n    float: left;\n    background-color: #FFFFFF;\n    border-right: 1px solid gray;\n    width: 3px;\n    height: 13px;\n}\n.tw-tagtogglebox .x-widget-tag-tagitem-text {\n    display: inline;\n    padding: 0 5px 0 10px;\n}\n.x-widget-tag-tagitem-text {\n    padding: 0 5px 0 5px;\n    margin: 0 0 0 0;\n    line-height: 13px;\n    font-size: 11px;\n    font-weight: normal;\n    font-style: italic;\n}\n\n.x-widget-tag-tagitem-over {\n    /*background-color: #EFEFEF;*/\n    border: 1px solid black;\n    color: black;\n}\n\n.x-widget-tag-tagitem-selected {\n    background-color: #FFFFCE;\n    border: 1px solid black;\n    color: black;\n}\n\n.x-widget-tag-qtip-occurrence {\n    font-size: 8px;\n    font-style: bold;\n}", ""]);

// exports


/***/ }),
/* 1590 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath id='tag_detache' d='M18.3,29.4l-6.1-6.1c-0.4-0.4-0.4-1,0-1.3l10.4-10.4L17.1,6c-0.6-0.6-1.3-1-2.3-1.4C13.9,4.2,13,4,12.2,4 H2.9c-0.8,0-1.4,0.3-2,0.9S0,6.1,0,6.9v9.3c0,0.8,0.2,1.7,0.6,2.6c0.4,1,0.9,1.7,1.4,2.3l16,16c0.6,0.6,1.2,0.8,2,0.8 c0.8,0,1.5-0.3,2-0.8l6.9-6.9h-9.6C19.2,30.2,18.5,29.6,18.3,29.4z M9.2,13.2C8.6,13.8,8,14,7.2,14c-0.8,0-1.5-0.3-2-0.8 c-0.6-0.6-0.8-1.2-0.8-2c0-0.8,0.3-1.5,0.8-2c0.6-0.6,1.2-0.8,2-0.8c0.8,0,1.5,0.3,2,0.8c0.6,0.6,0.8,1.2,0.8,2 C10,12,9.8,12.6,9.2,13.2z M41.7,27H30.1l12.2-12.2c0.3-0.3,0.3-0.8,0-1.1l-9.2-9.2c-0.2-0.2-0.4-0.2-0.6-0.2 c-0.2,0-0.4,0.1-0.6,0.2L14.4,21.9c-0.3,0.3-0.3,0.8,0,1.1l5.3,5.3c0.2,0.2,0.4,0.2,0.6,0.2h21.4c0.4,0,0.8-0.4,0.8-0.8 C42.5,27.3,42.2,27,41.7,27L41.7,27z M32.5,6.2l8.1,8.1l-4.1,4.1L31,23.8l-8.1-8.1L32.5,6.2z M27.8,27'/%3E %3C/svg%3E\""

/***/ }),
/* 1591 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M14,11.2c0-0.8-0.3-1.5-0.8-2c-0.6-0.6-1.2-0.8-2-0.8s-1.5,0.3-2,0.8c-0.6,0.6-0.8,1.2-0.8,2s0.3,1.5,0.8,2 c0.6,0.6,1.2,0.8,2,0.8s1.5-0.3,2-0.8C13.8,12.6,14,12,14,11.2z M38,24.1c0,0.8-0.3,1.5-0.8,2l-11,11c-0.6,0.6-1.3,0.8-2,0.8 c-0.8,0-1.5-0.3-2-0.8l-16-16c-0.6-0.6-1-1.3-1.4-2.3S4,17,4,16.2V6.9c0-0.8,0.3-1.4,0.9-2S6.1,4,6.9,4h9.3c0.8,0,1.7,0.2,2.6,0.6 s1.7,0.9,2.3,1.4l16,16C37.7,22.6,38,23.3,38,24.1z'/%3E %3C/svg%3E\""

/***/ }),
/* 1592 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M37.1,22l-16-16c-0.6-0.6-1.3-1-2.3-1.4C17.9,4.2,17,4,16.2,4H6.9c-0.8,0-1.4,0.3-2,0.9S4,6.1,4,6.9v9.3 c0,0.8,0.2,1.7,0.6,2.6c0.4,1,0.9,1.7,1.4,2.3l16,16c0.6,0.6,1.2,0.8,2,0.8c0.8,0,1.5-0.3,2-0.8l11-11c0.6-0.6,0.8-1.2,0.8-2 C38,23.3,37.7,22.6,37.1,22z M13.2,13.2c-0.6,0.6-1.2,0.8-2,0.8s-1.5-0.3-2-0.8c-0.6-0.6-0.8-1.2-0.8-2s0.3-1.5,0.8-2 c0.6-0.6,1.2-0.8,2-0.8s1.5,0.3,2,0.8c0.6,0.6,0.8,1.2,0.8,2S13.8,12.6,13.2,13.2z M31.6,23.7c0,0.2-0.1,0.4-0.2,0.5 c-0.1,0.1-0.3,0.2-0.5,0.2h-6.3v6.3c0,0.2-0.1,0.4-0.2,0.5c-0.1,0.1-0.3,0.2-0.5,0.2h-1.5c-0.2,0-0.4-0.1-0.5-0.2 c-0.1-0.1-0.2-0.3-0.2-0.5l0-6.3l-6.3,0c-0.2,0-0.4-0.1-0.5-0.2c-0.1-0.1-0.2-0.3-0.2-0.5v-1.5c0-0.2,0.1-0.4,0.2-0.5 c0.1-0.1,0.3-0.2,0.5-0.2l6.3,0l0-6.3c0-0.2,0.1-0.4,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h1.5c0.2,0,0.4,0.1,0.5,0.2 c0.1,0.1,0.2,0.3,0.2,0.5v6.3h6.3c0.2,0,0.4,0.1,0.5,0.2c0.1,0.1,0.2,0.3,0.2,0.5V23.7z'/%3E %3C/svg%3E\""

/***/ }),
/* 1593 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1594);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1594 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".action_delThisFilter {\n    background-image:url(" + escape(__webpack_require__(542)) + ") !important;\n}\n\n.action_delAllFilter {\n    background-image:url(" + escape(__webpack_require__(1595)) + ") !important;\n}\n\n.action_addFilter {\n    background-image:url(" + escape(__webpack_require__(224)) + ") !important;\n}\n\n.action_saveFilter {\n    background-image:url(" + escape(__webpack_require__(1596)) + ") !important;\n}\n\n.action_startFilter {\n    background-image:url(" + escape(__webpack_require__(649)) + ") !important;\n}\n\n.x-panel-bwrap .tw-filtertoolbar  {\n    background-image: none;\n    background-color: #E5EDF8;\n}\n\n\n.tw-filtertoolbar  td { \n    padding: 0px 5px 0px;\n}\n\n.tw-filtertoolbar .tw-ftb-frow-pbutton { \n    padding: 0px 0px 0px;\n}\n\n.tw-filtertoolbar .tw-ftb-frow-mbutton { \n    padding: 0px 0px 0px;\n}\n\n.tw-filtertoolbar .tw-ftb-frow-prefix {\n    text-align: right;\n}\n\n/* fix Ext.Button Layout */\n.tw-filtertoolbar .x-btn td {\n    padding: 0px;\n}\n.tw-filtertoolbar .x-btn-icon .x-btn-center {\n    padding:1px;\n}\n\n/* criteria tabls \n.tw-ftb-criteria-tabs .x-tab-strip-wrap {\n    background-color: #E5EDF8;\n}\n\n.tw-ftb-criteria-tabs .x-tab-strip-wrap ul {\n    border-bottom-color: #CEDFF5;\n}\n*/\n\n/* structure treepanel\n.tw-ftb-filterstructure-treepanel .x-panel-tbar-noborder .x-toolbar {\n    background-image: none;\n    background-color: #E5EDF8;\n    border-color: #E5EDF8;\n}\n.tw-ftb-filterstructure-treepanel .x-panel-body {\n    background-color: #E5EDF8;\n    border-color: #E5EDF8;\n}\n*/\n\n.tw-ftb-filterstructure-treepanel .x-panel-tbar-noborder .x-toolbar,\n.tw-ftb-filterstructure-treepanel .x-panel-body,\n.tw-ftb-filterpanel .x-panel-body,\n.tw-ftb-filterpanel .x-toolbar {\n    background-image: none;\n    background-color: #E5EDF8;\n    border-bottom: none;\n}\n\n.tw-ftb-filterpanel .ux-arrowcollapse .x-tool-toggle {\n    background-color: #E5EDF8;\n}\n/*\n.tw-filtertoolbar .fw-ftb-actionrow td { \n    padding: 0px 5px 1px;\n}\n*/\n", ""]);

// exports


/***/ }),
/* 1595 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath d='M 35.6 21 C 35.6 18.4 34.9 15.9 33.6 13.7 C 32.3 11.5 30.5 9.7 28.3 8.4 C 26.1 7.1 23.6 6.4 21 6.4 C 18.4 6.4 15.9 7.1 13.7 8.4 C 11.5 9.7 9.7 11.5 8.4 13.7 C 7.1 15.9 6.4 18.4 6.4 21 C 6.4 23.6 7.1 26.1 8.4 28.3 C 9.7 30.5 11.5 32.3 13.7 33.6 C 15.9 34.9 18.4 35.6 21 35.6 C 23.6 35.6 26.1 34.9 28.3 33.6 C 30.5 32.3 32.3 30.5 33.6 28.3 C 34.9 26.1 35.6 23.6 35.6 21 Z M 38 21 C 38 24.1 37.2 26.9 35.7 29.5 C 34.2 32.1 32.1 34.2 29.5 35.7 C 26.9 37.2 24.1 38 21 38 C 17.9 38 15.1 37.2 12.5 35.7 C 9.9 34.2 7.8 32.1 6.3 29.5 C 4.8 26.9 4 24.1 4 21 C 4 17.9 4.8 15.1 6.3 12.5 C 7.8 9.9 9.9 7.8 12.5 6.3 C 15.1 4.8 17.9 4 21 4 C 24.1 4 26.9 4.8 29.5 6.3 C 32.1 7.8 34.2 9.9 35.7 12.5 C 37.2 15.1 38 17.9 38 21 Z M 21.7 30.8 L 20.3 30.8 C 20.1 30.8 19.9 30.7 19.8 30.6 C 19.7 30.5 19.6 30.3 19.6 30.1 L 19.6 22.4 L 11.9 22.4 C 11.7 22.4 11.5 22.3 11.4 22.2 C 11.3 22.1 11.2 21.9 11.2 21.7 L 11.2 20.3 C 11.2 20.1 11.3 19.9 11.4 19.8 C 11.5 19.7 11.7 19.6 11.9 19.6 L 19.6 19.6 L 19.6 11.9 C 19.6 11.7 19.7 11.5 19.8 11.4 C 19.9 11.3 20.1 11.2 20.3 11.2 L 21.7 11.2 C 21.9 11.2 22.1 11.3 22.2 11.4 C 22.3 11.5 22.4 11.7 22.4 11.9 L 22.4 19.6 L 30.1 19.6 C 30.3 19.6 30.5 19.7 30.6 19.8 C 30.7 19.9 30.8 20.1 30.8 20.3 L 30.8 21.7 C 30.8 21.9 30.7 22.1 30.6 22.2 C 30.5 22.3 30.3 22.4 30.1 22.4 L 22.4 22.4 L 22.4 30.1 C 22.4 30.3 22.3 30.5 22.2 30.6 C 22.1 30.7 21.9 30.8 21.7 30.8 Z' transform='matrix(0.707107, 0.707107, -0.707107, 0.707107, 21, -8.698485)'/%3E %3C/svg%3E\""

/***/ }),
/* 1596 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 21.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M38,14.3v20.6c0,0.6-0.2,1.1-0.6,1.5S36.5,37,35.9,37h-4c0.3-0.4,0.5-0.8,0.5-1.4V24.9c0-1.2-1-2.1-2.1-2.1H11.8 c-1.2,0-2.1,1-2.1,2.1v10.7c0,0.5,0.2,1,0.5,1.4h-4c-0.6,0-1.1-0.2-1.5-0.6S4,35.5,4,34.9V5.1C4,4.5,4.2,4,4.6,3.6S5.5,3,6.1,3H10 C9.8,3.3,9.7,3.6,9.7,4v11.3c0,1,0.8,1.9,1.9,1.9h13.4c1,0,1.9-0.8,1.9-1.9V4c0-0.4-0.1-0.7-0.3-1h0.2c0.6,0,1.2,0.1,1.9,0.4 c0.7,0.3,1.3,0.6,1.7,1.1l6.2,6.2c0.4,0.4,0.8,1,1.1,1.7C37.9,13.1,38,13.7,38,14.3z M12.5,34.2h17v-8.5h-17V34.2z M18.9,14.3h4.3 c0.2,0,0.4-0.1,0.5-0.2s0.2-0.3,0.2-0.5V6.5c0-0.2-0.1-0.4-0.2-0.5c-0.1-0.1-0.3-0.2-0.5-0.2h-4.3c-0.2,0-0.4,0.1-0.5,0.2 c-0.1,0.1-0.2,0.3-0.2,0.5v7.1c0,0.2,0.1,0.4,0.2,0.5S18.7,14.3,18.9,14.3z'/%3E %3C/svg%3E\""

/***/ }),
/* 1597 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1598);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1598 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "\n.x-form-field-wrap .x-form-account-trigger {\n    background-image:url(" + escape(__webpack_require__(1599)) + ");\n    cursor:pointer;\n}", ""]);

// exports


/***/ }),
/* 1599 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAOfnAAACAAEEAAUIBAcJBQgLBwoMCA8RDRASDxIUERQVExcYFhwdGx0fHB8gHh0hIyAhHx4iJCEjICQiJiAkJiIkISQlIyUpKyooKygpJyYqLCcrLSosKSktLystKiwtKy0uLCsvMS4vLSkwNywwMioxOC8xLisyOC4yNDAyLzIzMS41PDQ2MzA3PjM3OTc5Njg5Nzo7OTQ8QjU8QzY9RDs9Oj0/PDtAQj5APT9APjpBSEBBPz1CRDtDST1ESz5FTD9GTTlITUVHREFIT0RJS0dJRkhJR0NKUUVKTElKSENLUkhMTkpMSkVNU0tNSkxOS01SVE9UVlVWVFNXWlZaXFhcXlldX1pfYVNiZ19hXl1iZGJkYV1lbGBlZ15mbWpsaV5we2pucWdvdmx3g3J5gWt+iXV8hHZ9hXJ+in1/fG+CjXOCiHqBiXOClHaCjnGEj4GDgIKEgXmFkn+GjoWHhHiLl3uKnIeJhn6Kl4aLjoSMk3+OoIuNioCPoYyOi4OSmJCSj5GTkIiXqpKXmX2crIqZrIybopSfraGjoJemuZmou36t2qWnpKepppirxJKxwaSttZ+vtpOzwpS0w6KxxZ6yyp+zy5e3x6m0wqu7wbS4x7e5tqi71Li6t7q8ua++0rC/072/vL7Bva/D3LDE3bLF3rfHzbXI4bbJ4zn/QrfK5KvP5a/P38jKx7jM5bnN2azQ5snLyLnN5q3R57HR4bvP6LzQ6cDR18bS4NDSz9HT0NLU0dPV0tTW09XX1Mba5tbY1cfb59vY3Nja1sXc/Nnb18nd98fe/sve+Mzf+c/f89ze283g+tDg9NTg7tHh9d7g3dbi8NDk/tbn7ers6evu6u3v697y/+jw+e7w7d/z/+/x7uD1//Dy7+X1/Ob3/fP18uj5//T38+n6//n7+Pf9//j+//7//P///////////////////////////////////////////////////////////////////////////////////////////////////yH+EUNyZWF0ZWQgd2l0aCBHSU1QACwAAAAAZgAYAAAI/gAzCRxIsGAmVIoSKlzIUBHChhATPozYcCLFhRYvSizHsaPHj8EykRtJsqRJWoqAqVzJsiVKkzBLvowZE2XLmyxRctvJs2dPjpmgCR1KlGg5cylxKlVUtOnQo4rASZ1Klao5pEqX+tza81tQp06xZr3JFGxTpFXTWk06lqUibXDhVgOFJQqgZ3G1jfs6tNklKlDy3CIqtu3Ksn3/Bh48FC1Vb6WySBEkba1ht9gyZ2akxUmQInY0Y9vrrHRpQ1aaBDmyxrSzwip9QZryRI6rlopcO0OtmrVrpN6CB3/ExTMSPMK9wQYmm7Zt3NWiV4OlgwiNDitwsJK+l5l3Zp9s/ljHbsPT9+WFqigJMsQM7u/gxV9fUf68om74u9naMX6FDlv5oacee+65JV01fcBQQgUMfgAHd5kkI2EycSjIYAUflDEhbJjIh10NmLg1IYUWNqihhEhlo2I2fpSIoRwrcujhCiC6Rc2N1HjhAgUP9EiBFzjudcyQx3SxY48PUNAFkbCt4eIHY7hFZJFH+rjkkCmuCEaVSYIRI1vAOLlgg1EeNs2Z03ixQQMLtLkAGmgKSWQXa7q5gBhMgskFlxRsIeWcdbqJJ5aKWGOoNWEE2qYah8K2J48++nmYMpQqs8gGDCigAAVNdFJpOJmYIqopgViQqQIO/NDIqNcoMsur/rNcoegCX8D6iiKjkmqqpqmuKmqrwwQ7DCIanDoBE5sI2yqssc5a66u3EiMtMcLsgQICCCARyrTEgJqrKWyAgO0PlOTa6ivovjJIBqdCIIQj6d76bbjjlsuqIsbka8wwfJiArRGk6GvMuemu2+678SoizMILH5KCAQaE8AfDwoAay8UXE0ICxBzU0QrGBKO7ihsjYAuEJfHeinHGGxvQ8ccXt7rMzDMnogLEIgSCDM0hvzJyyQicnLIivfTCyRxBYIDCAQNE8IIOb2jSC6i11FJJGz4ozbTTOZwxSS09q3sCx3SoknDVV2e9dNMvdP11q9FEQ4oeRlywttM93EFK/jRhDzK2y2UnzAsvN5TgwQMFDKB4AhVQ4AIvVNcywwiHJ7544yyArQi6kqTRg9Zs20BGJOgqUvXklSs+AOMUZA53NDyckPrlEsTA9+avdP753S+ITvqtu+yCQAMDAGD88QAovkvkwxePvPGKa46uDJQjrjrrLZRedfPPQz+A5nFz373it09fveWrN579rbq07/778Ede9fz000+w+M8rrn39/M//etwADGAA70e87iVvAKXLhQIXyMAGyq9/9WuVLCZIwQpa8FYQ7N//BMjB21nwgxW8FS5GSMISmvCBGayaBEEIQgym0H6K6KAMV8jCCyrChDgsIQpTSMMaUtCFXi9UYQxlyMEe+lAWIsxhDneYQSP6EIhB3CAR4+bEGiZRiSfMRBD9p4gjhtB0WwTfFAfYRS9O8IpYJCETIVhFFkLxhVKcYhtbeMM06lCLYZzjB9/IwyGOkYplNOOtAgIAOw=="

/***/ }),
/* 1600 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1601);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1601 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".preview-panel {\n    padding: 5px;\n    white-space: normal;\n    height: 100%;\n    background-color: #e5edf8;\n    position: relative;\n    display: inline;\n}\n\n.preview-panel img {\n    vertical-align: middle;\n    -moz-border-radius: 8px;\n    -webkit-border-radius: 8px;\n    -khtml-border-radius: 8px;\n}\n\n.preview-panel-left {\n    float: left;\n    font-size: 10px;\n    color: #404040;\n    font-family: verdana;\n    line-height: 16px;\n    overflow-y: auto;\n}\n\n.preview-panel-right {\n    float: right;\n    font-size: 10px;\n    color: #404040;\n    font-family: verdana;\n    line-height: 16px;\n}\n\n.preview-panel-bold {\n    font-weight: bold;\n}\n\n.preview-panel-image {\n    padding:0px;\n    display: table-cell;\n    vertical-align: middle;\n    position: relative;\n    left: -7px;\n}\n\n.preview-panel-office {\n    width: 360px;\n    margin: 5px 2px 5px 5px;\n}\n\n.preview-panel-privat {\n    width: 360px;\n    margin: 5px 2px 5px 5px;\n}\n\n.preview-panel-description {\n    width: 200px;\n    position: relative;\n    height: 97px;\n    margin: 5px 2px 5px 5px;\n    padding: 5px;\n    border: solid 3px #e5e6fe;\n    overflow: hidden;\n}\n\n.preview-panel-description,\n.preview-panel-description a,\n.preview-panel-description a:link,\n.preview-panel-description a:visited,\n.preview-panel-description a:hover,\n.preview-panel-description a:active {\n    color: #a0a0a0;\n    text-decoration: none;\n}\n\n.preview-panel-address {\n    width: 150px;\n    padding: 5px;\n}\n\n.preview-panel-contact {\n    width: 180px;\n    padding: 5px;\n}\n\n.bordercorner_1 {\n    background-image: url(" + escape(__webpack_require__(1602)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    top: 0;\n    left: 0;\n    width: 4px;\n    height: 4px;\n}\n\n.bordercorner_2 {\n    background-image: url(" + escape(__webpack_require__(1603)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    top: 0;\n    right: 0;\n    width: 4px;\n    height: 4px;\n}\n\n.bordercorner_3 {\n    background-image: url(" + escape(__webpack_require__(1604)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    left: 0;\n    bottom: 0;\n    width: 4px;\n    height: 4px;\n}\n\n.bordercorner_4 {\n    background-image: url(" + escape(__webpack_require__(1605)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    right: 0;\n    bottom: 0;\n    width: 4px;\n    height: 4px;\n}\n\n.preview-panel-adressbook-nobreak {\n    min-width: 1075px;\n}\n\n.bordercorner_gray_1 {\n    background-image: url(" + escape(__webpack_require__(1606)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    top: -3px;\n    left: -3px;\n    width: 5px;\n    height: 5px;\n}\n\n.bordercorner_gray_2 {\n    background-image: url(" + escape(__webpack_require__(1607)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    top: -3px;\n    right: -3px;\n    width: 5px;\n    height: 5px;\n}\n\n.bordercorner_gray_3 {\n    background-image: url(" + escape(__webpack_require__(1608)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    left: -3px;\n    bottom: -3px;\n    width: 5px;\n    height: 5px;\n}\n\n.bordercorner_gray_4 {\n    background-image: url(" + escape(__webpack_require__(1609)) + ");\n    background-repeat: no-repeat;\n    background-position: left top;\n    position: absolute;\n    right: -3px;\n    bottom: -3px;\n    width: 5px;\n    height: 5px;\n}\n\n.preview-panel-declaration {\n    color: #a0a0a0;\n    font-size: 18px;\n    position: absolute;\n    font-weight: bold;\n    left: 5px;\n    bottom: 6px;\n}\n\n.preview-panel-symbolcompare {\n    color: #a0a0a0;\n    width: 45px;\n    text-align: right;\n    display: block;\n    float: left;\n    overflow: hidden;\n    padding-right: 5px;\n}\n\n/* Multi */\n.preview-multi-panel-description {\n    width: 98%;\n    position: relative;\n    height: 97px;\n    padding: 3px;\n}\n\n.preview-multi-panel-left {\n    float: left;\n    position: relative;\n    width: 50%;\n    height: 100%;\n    padding: 5px;\n    border-right: 5px solid white;\n    font-family: verdana, sans-serif;\n    box-sizing: border-box;\n}\n\n.preview-multi-panel-right {\n    float: left;\n    position: relative;\n    width: 50%;\n    height: 100%;\n    padding: 5px;\n    border: solid 3px #e5e6fe;\n    font-family: verdana, sans-serif;\n    box-sizing: border-box;\n}\n\n.preview-multi-panel-leftside {\n    width: 200px;\n    padding: 5px;\n}\n\n/* TODO make this right-aligned */\n.preview-multi-panel-rightside {\n    width: auto;\n    padding: 5px;\n    padding-left: 150px;\n}\n\n.preview-multi-panel-nobreak {\n    min-width: 900px;\n    padding: 5px;\n    height: 100%;\n    box-sizing: border-box;\n}", ""]);

// exports


/***/ }),
/* 1602 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAAEAKIEAPz//////f3//////wAAAAAAAAAAAAAAACH5BAEAAAQALAAAAAAEAAQAQAMJOBMS9EM88EgCADs="

/***/ }),
/* 1603 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAAEAKIGAP3///7+//7///z//////f///wAAAAAAACH5BAEAAAYALAAAAAAEAAQAQAMICBRlTm40JxIAOw=="

/***/ }),
/* 1604 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAAEAKIGAP3///7//f///vz///7//////wAAAAAAACH5BAEAAAYALAAAAAAEAAQAQAMJWLY0G8uQIkACADs="

/***/ }),
/* 1605 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBAAEAKIFAP/9/v7///z//////////gAAAAAAAAAAACH5BAEAAAUALAAAAAAEAAQAQAMJWBoqpIWQQUACADs="

/***/ }),
/* 1606 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBQAFAMQAAOfm/ubm/ebk/OXn//7//+Tl/OXm+//+//7//uXm/f3//+Xl/Ofm//7//ebn/v7+/+Xm/OXl/ufn/+bl/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAAAALAAAAAAFAAUAQAUVIPVQyjQNyUQgTOFAByUAUWNIwRICADs="

/***/ }),
/* 1607 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBQAFALMAAOXl/ebm/uXn/+bm/+bn/+Xm/ebl+/3///7//eXm/ubl/f///wAAAAAAAAAAAAAAACH5BAAAAAAALAAAAAAFAAUAQAQQ0By0qiLJkCIUSgNgBcVwRAA7"

/***/ }),
/* 1608 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBQAFAMQAAObl/+Tl/+Tn+/3//f7//ufl/+Xl/+bn/Obo/+Xn/eXm//7+/+fl/v///uXl/eXm/efm//7//////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAAAALAAAAAAFAAUAQAUVYPEITtRIywAQUKAckYEkjiQx0BMCADs="

/***/ }),
/* 1609 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhBQAFAMQAAObn/ubm/eXk/v/+/ebl/Obm/+Xm+////f3//eXn/ubl/ubn/+fl/+Xm/f3//+Tm/uXm//7//+Xm/v///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAAAALAAAAAAFAAUAQAUV4CQYUFA40zQsCcRESiNJyAMQ0RECADs="

/***/ }),
/* 1610 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1611);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1611 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "\n.prefpanel_adminMode {\n    color: red;\n}\n", ""]);

// exports


/***/ }),
/* 1612 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1613);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1613 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".tw-uidTriggerField .x-form-field-wrap .x-form-trigger {\n    background-image: url(" + escape(__webpack_require__(1614)) + ");\n}\n", ""]);

// exports


/***/ }),
/* 1614 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODlhZgAYAPcAAP//////zP//mf//Zv//M///AP/M///MzP/Mmf/MZv/MM//MAP+Z//+ZzP+Zmf+ZZv+ZM/+ZAP9m//9mzP9mmf9mZv9mM/9mAP8z//8zzP8zmf8zZv8zM/8zAP8A//8AzP8Amf8AZv8AM/8AAMz//8z/zMz/mcz/Zsz/M8z/AMzM/8zMzMzMmczMZszMM8zMAMyZ/8yZzMyZmcyZZsyZM8yZAMxm/8xmzMxmmcxmZsxmM8xmAMwz/8wzzMwzmcwzZswzM8wzAMwA/8wAzMwAmcwAZswAM8wAAJn//5n/zJn/mZn/Zpn/M5n/AJnM/5nMzJnMmZnMZpnMM5nMAJmZ/5mZzJmZmZmZZpmZM5mZAJlm/5lmzJlmmZlmZplmM5lmAJkz/5kzzJkzmZkzZpkzM5kzAJkA/5kAzJkAmZkAZpkAM5kAAGb//2b/zGb/mWb/Zmb/M2b/AGbM/2bMzGbMmWbMZmbMM2bMAGaZ/2aZzGaZmWaZZmaZM2aZAGZm/2ZmzGZmmWZmZmZmM2ZmAGYz/2YzzGYzmWYzZmYzM2YzAGYA/2YAzGYAmWYAZmYAM2YAADP//zP/zDP/mTP/ZjP/MzP/ADPM/zPMzDPMmTPMZjPMMzPMADOZ/zOZzDOZmTOZZjOZMzOZADNm/zNmzDNmmTNmZjNmMzNmADMz/zMzzDMzmTMzZjMzMzMzADMA/zMAzDMAmTMAZjMAMzMAAAD//wD/zAD/mQD/ZgD/MwD/AADM/wDMzADMmQDMZgDMMwDMAACZ/wCZzACZmQCZZgCZMwCZAABm/wBmzABmmQBmZgBmMwBmAAAz/wAzzAAzmQAzZgAzMwAzAAAA/wAAzAAAmQAAZgAAMwAAAO/v79Xq/8rb5rHQ5K7Q436t2bW5xMng+cPX7tDk+tTn+xYYGtXq/rbF07zQ4dbm8p+orq/Q5LDQ5EJHSt/0/+f0+/f8/tno7OTw88zW2PX29dvd1+Xn4NbXvezs6O7u6+3sy/Dv4922VO/n3tfEss2zn4BFH////yH5BAEAAP8ALAAAAABmABgAAAj/AL0JHEiwoDcA3RIqXMiwG8KGEBM+jNhwIsWFFi9KBMCxo8eP87y5G0mypElz3bSpXMmyJUqTMEu+jBkTZcubLFFi28mzZ0+OImma5JgSp9Fu2ZIqXbqUqNChCI0e9YmNnjd7+/Dhy7dTXtCS8Ly1y6dV3sioN82h0xavXr14KpEyBect3Lt5894lRQgz7NiyZ4u6XNv2bdyd++jZ42eFFT8ECiLjw+ZObDts8NqtaLyCX+QE+NqhZQvXW2N0LCIrqKdN7rlw4co19uZZAehsCNtdzryZVefPoUfHK306dWTW3RD368ePH7py2O7hS0CAsmV7zJs/102PumjB8WQs//f2XOWKFgpaJ303nny5bOLmUcfdTTf25s7LcfcuXHw/9+ah1xo2+STQzwz8zINOICvsBJl17cBjoAz8aLNgPLpB9p1K8ehzYD+yBeKNSqmpd86EFS5oTlKQ0RchihYGgmE7GqLV4YchjqhNicnpkwA29fCz2TjoQKbAZJWx4yM7nZljBZG14cMOWj5q481/T1rRz3Hq+UhOZ7JBGdk89CmZAJP8OCnmkVMWVeWVpo2jJZc9ghYSOlf4swMNCdizU5I+0nNnnnsmAA87barkYz0roGMFoTToA1eXCcwTD3mQtnDOXt2YKSimevJ5aKLaLNroo6FKetg+CegDwas6eP8hSIM8JflOq69CMIOs5iCKqI24QkBDrILoGFc2J7r6ag68NtXprcrqyquvpMYT7LCyGjvgTvfUgw9eWfbk1TfkfrNCPOZso8c4epT7TTvdcCOvvAI98cS6eszLjVzwrTCPNuBkuRS87p6bLr7uwqsvN/Xey66+yVEVEivrIIBAV964W65aFPPTD7kKLyzvE+hQvJy8/C5FV8f8JEWwxt9wvI7HIMcrMjckm9wPylTtNE8g48zgAMYwk7sN0FfIUPPNIyMtA8pMJUWOOUDP0I/L3RT9zdHjJL000084zXPP2KAzTiD3EK212YGUGzLT6wYyb8pMsS0O1lp/w7bbNsP/ffbcZFe1zjj0qF00OIOD8zXT3LAyztxRK/XN4N/grTXi4yj+bt9MOw544FZcg47hRYeOzuJwX5PvvpErhY7olmttOuo366H62IGLm3HeGsObzu/ABy88661H/TLvfAuvfPD75u6TV7BFL/304cCrzvXYZ6898cUP3A314MNmvfbkY9+88zxBHz718G7j/vvwx89991ivz3438ecP//noY6O+/dFrn/70Nz/6wQuA0hPgAOUXsf79D4EKXOD7Cti9AyJQfPiT4P4aiD6viOODIAyhCCOoQQoWD14iTGEISShB/nXQGyqMIQsXaMLWoTCGKZzhAF3oPA/icIQZ1KD7DWoYuRv+EIQ6JGA3AgIAOw=="

/***/ }),
/* 1615 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1616);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1616 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*\n * Tine 2.0\n *\n * @license      http://www.gnu.org/licenses/agpl.html AGPL Version 3\n * @author       Michael Spahn <m.spahn@metaways.de>\n * @copyright    Copyright (c) 2017 Metaways Infosystems GmbH (http://www.metaways.de)\n *\n */\n\n.tw-FileSelectionArea td,\n.tw-FileSelectionArea tr,\n.tw-FileSelectionArea table {\n    background-image: none;\n}\n\n.tw-FileSelectionArea {\n    background-color: #F0F0F0 !important;\n    border: 2px grey dashed !important;\n    border-radius: 5px !important;\n    margin-left: 2px;\n    margin-top: 2px;\n}\n\n.tw-FileSelectionArea div.x-btn-image {\n    width: 100%;\n    height: 100%;\n    background-size: contain;\n    background-position: center;\n    opacity: 0.3;\n}\n", ""]);

// exports


/***/ }),
/* 1617 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1618);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1618 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".tw-passwordTriggerField .x-form-field-wrap .x-form-trigger:nth-child(1) {\n    background-image: url(" + escape(__webpack_require__(1619)) + ");\n}\n\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger.locked:nth-child(1) {\n    background-image: url(" + escape(__webpack_require__(1620)) + ");\n}\n\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger:nth-child(2) {\n    background-image:url(" + escape(__webpack_require__(1621)) + ") !important;\n}", ""]);

// exports


/***/ }),
/* 1619 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODdhZgAYAPcAAAAAAEdHR01NTVtbW2RkZGtrbG9wcnNzc3Z3eHd6fHR7gHp7e31/gH6BhIODhH6Ein6GkYWHioaJi4qLjI2PkY2RlIqTm5KTk4eVnpOWmpSanYibp5SbopubnJyeoZ6hpI6ir5ajq6OjpJylsZymraOnq5qouZuor6WprICq0p+rsqKrs6urrH+s1n6t2aOuvKqusayxtZ6yvqSyvLOzs6K0wq20uqm1xbO1urK5vrW5yJ+6yqW8yq68za+8xbO8w7u8vbm+wqO/0K+/0bC/0qTA0abAz7XAxrXBybzBxcLCxLbD07zEy6nF1rnF0rPG3MLGyqnH2rXI3rzIzsPJzbzK2r3K06zL3bXL4sXM08zMzbnN5K7O4sLO2rrP6MvP0q7Q47HQ5LvQ6b7Q5szQ1MfR1tLS0sHT6MTT3czU28jV48bW4dTW2sTY783Z39LZ3s3a6dra2sbb9Mrb5tPc48vd9Mbe+tDe68nf+dzf4s/g9NPh7tzh5dXj8dzj6+Pj483k/+Pq7evr6+Ls9O7u8OXy+vLy8t70/+j3/Or6/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkAAIsALAAAAABmABgAAAj/AHUIHEiwoEAXCBMqXMiwocOHECNKbKioosWLGBXpyMjRoos5IEOKHDnHRceOJk9m/EiyJUgXhmLKnElTY5+bOHPu2YNTEUuXJF3kHNpnZ08XiZIqVYqoUCGlPoG2hElTpqA/M20SvblHTZejUoNuvakGiZU7N30uXUvHBh1ESaOGFUm1qiEgCwTJ1ApHjd+/XThEgENYrss1a+j2gWPlh+PHJSqQYGKli6EWifYciQGjM4wVFRzEmELFjaGfJNegGelCEJAJsGM7IOCABgsWWmyuWdGhd+8LEwpUsEH8D2qRa6r40KG4y48gSZRIB3KBQgwmWZj8aVFoihIyZsKb/1Ei4cOXN2yoCGoBdEaD1SFbX9A700wBM4Ku0tBYp8oH+jG5xgAbfvhBhxYfocHEEQwy+MMKEnBgxYRruKCHE0rE8ceGf2jRQQlf0EEHFHGkUMgP+OWXnxITQOFHIIFox94PGVRAwY0UBJcACiusgESFglxAU5AOGKIiDYbo0F8HgpgRx1VxTJDBIAUe6MIaSKBAw5ZbsjDBAigE4ZgVLtSxRBJAsACEFmbQYB0dBWZR4olUCGAnEF9cIMEXMMa43RwfPKmiIFocEISIb8SAhnxm2CkAEGYQMN+RSS4JhKNAAFGABwaKiCAaOdAwqCBxiNABHXzkkV2ZS+TQgaMsXP/gAA5fUJEGiSkc8sOl+YngwQITZAFFEm/IOAeTMwkiggN58OEsDIsGCYUA+R1wQQEi/CECDX8gqWQVHfAqCAIRIIACGR7EkManObDQZoZmvAaDH3nkQQYTrOJwAbWCRNAABTjkECYTJeoKRAACENLBAg50AAULHlCRxJ8eaOGoCIVO4Oyzi8ZxARQIE3IAAR1gfMEFZrCQJBY9dEBDyAcU8IEISVzgwapXzCCCCJgurC52VvDgAhY1xHBByAtE4AEOMSz9wxcp2DEDDgLU28GmJTABwwdQ/PBGC2BwoAS/DlyrQRoowJDGCle44PGl9S4wgIdxdMBCHCrrwPIFNFT/nQcCCGj9RQk4pIFvzjvzuwADE8Twgwc2MCE0FjfEwILfDnjwAxVQBEHFD1lEPcOlZrDRgQOg05FGFnR4DbYGSiBNQAUeMJHBBVmo0HaUjZZeNocc5r1FDxl8IYDvH4iovOEuIN4BzAygEIOr1wm9xQ04jF36BYWLyAYd2LUAyA1raqHFBB+kUeD6OnwNhgZw5zHb42V8kD7bLphxgRLma6oE8H/AW5K2MIRwSUcEgUuDAhWYBSo0T2d9i5sGmJCELOSAMkITwxBWcBsRSIACkWOCCJnwgzSIbwkl8IAILoAADtjgMT8QCB1eZ7HSwSYNbqCDG3Kou/zRIDYFKEDJ/3ZGRCAkyQtSeEEGMkABAyhgBD2K4gvo8MAS1JANE8jBHJQ3h6C5QAxS6MEMZpCBB3DgBj1IYxqJ4AfxyWELVaiCBSzQgzGc4Y53bMMgXPA+/mlBCQdwi/LoMIceiic8BxDBIQ+ZJDE40pFPgEANHknJQjSvBiTo0gQk8AMrTOGTTOiBEb64hS1ggWgm6AEWSsnKLewRELCE5ROkIIdY2tKSYJABcC6wgAJwgATABOYJatC2RZpvkeJpJCW9sEpKPtKSXGiCDEgQAgsoAAMyqIE2tcmDtjkTC0/AghecKQZL2hIQeMDDOWOJSy5c4Z0K2MA75/lOLoAhf8jMpxmUSa3OfloyDAANAxd2AAIhBPSg93SmF8bpTxes86Gw/OdBixAFLhw0oPfUZz752U9nSjSg7sTCRQGa0I6S05wQXedHASrSkZIUnxplpA5MelIXuPSmJaXpMx2a0nOu9KYYhWlMw8NRnf4UqGHIqU7LydOestOmSEWoUIdaVJoeFahKNWpTnQqIq+J0qjGtqkm96tKsWnWrTiXrSDM61GTOdKmOVOtFzTpWtPZUrlINCAA7"

/***/ }),
/* 1620 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODdhZgAYAOYAAAAAAE5OTV9fYF9gYGNjY2doaWtra25vcGpyd21yeXR0dHJ2enZ6f3p6enp+g4OEhIOGiouLi4uOkJKSk5SWmJWanZqcnpudoJygo5ajq5SltJylraWlpaCmq5+nsZypsKOpr6SstKysrH6t2Z2uuaSuuaewu6uxtaOyxLOzs621uq+3wbW4yKK5x6y5yr29vrTAxLXBybrDyLrF0sXFx8HGyrfH2sLKz7PM48TM0szMzbnN5snO1MDP2a7Q47HQ5LvQ6cfR1svS19LS0szT2srW48bX4dfX2c3Z39Ta3dra28rb5tTd5Mbe+sve9dHe7N7e4c/g9Nbh593i5uLi49Tj8c3k/93k6+Lm7N/n8eTr7+Xr8uvr693s8Ozt8OXx+fLy8t70/+f4/un6/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkAAGUALAAAAABmABgAAAf/gCyCg4SFgiOIiYqLjI2Oj5CRko1klZaXmGQsmZyWI0ugoaKjSyOdnaanmZ+kraAjYLGys7SaVbe4ubpkrK6kI7rBubxjxcbHyLy+rbC0slxUs7bCVU9Fw73LocDU1tjIx19dx8raos3OYC8NXLLTwiYL2Obn1FXx3+DFMA1ixuX0SnHRIaKgQQ4GDERY+MLWjBAgIoIIsSHhwggrAJIy0mMUsIcSJ1ZUuDDjiC9ETqhcCeIAyQgyNI7i6JFLCipccubUYeCFDh00JmiKEgLKlaNHa/T8GVSmqBALPBI1ivSKUp9AhZ5UcUWLVy1bbizN6jQU1JopdOakMuHBkSFw/yOAYeEkRNWjbd/GVRajg9+/GCwuVFGq7t0reeEOicDri4qvXym4Vcz4U9+/fgO/JDzCppIIE4ZwGEKgAZQjqOXSDUEENI8LPAaYRn2k8pIQTKbo1n2V6YTCrF3Dln06Na8wKpKAFoJBSOnitZXh3s17bFCBKYaI8MLFggUCCqAoiPB5bl0i27dYuABePHnbIKjrThwXOHov6tmHH//5ePLtXliAQXv8wSffFPQtVooSIiyWlgUGTNDACwEEoMMEc+GwgRARpKAFhBJSaOEEX4zgwwdBgHaDBTcIMFtqPoygIYcegjhhhReW2EQJraWwxQUR3jhiiSemOMGKLb5YW/+MDIqWUwQEDDEBFQqxlaEHOXDAxRUSRDlllSSa+EEO211hQQUD7PdejDhgqSWXXlIZAVs68qjlFl1KKSedYpLphZloqvkZkyJQYSgXD0zQziwYsrDDBrlRgUWii8oS5ok0fhikiBfG+GikkypKS5hWlHAUFltAICqjRH6QqY2cThCjdkoYytMQtHDRKBAeMMHEFTkUgOssuraa5ZZ5fjmnrCPw6iuwwuZKqqlXZEGEAcM+c+mYbya7J7NDvMABByI0QMADF12UwlxAuLDBuwycm+5CJRAJqRRUXEHpqDG2++4G8aI7b70jWGFDCCGU4IC887pgLxP46ruqpbMqNoTlAqNZrBi7QHQMRAIaeCwyEPYiAXGw2caia78igzyyxyVaIbPMC6Aw881WlHxytMSCq/HPG7Pw8tAdE9lCBhkAzHC6JLBM9Mgx4yz1zEYjrbTATFcM9M8cPy1yiT+E/QMOCGgg9tk/OO110QVPPTXYYpNtNtpha721xV2vTfIIdPddd7N6s+3223z7Tbfdd8OV99pwG3622oy3PfjNjTv+d+IaL+515ZZDvrnkk8vMueOIJ67506Mb7jnqoIeeut+l33060a/3vTrtrU9e++EjYI630IHvbfnjgAcedeiiFz582iMEAgA7"

/***/ }),
/* 1621 */
/***/ (function(module, exports) {

module.exports = "data:image/gif;base64,R0lGODdhZgAYAOYAAAAAAJqDTq6IAMydAcqgAMyqAKysrH6t2Z2vuqSvvbywa7WyjsGybZWzw6K0waS0vai0xKm0v7S0tLi0kZi2x7W4yLi4uL65k666ya28xbLA0cXCm6bD1rDD2//DALfEzbvEzs3FesbGxs7HnOTHOr7J0MfJytLJgdrJS8rKysvKo7PL4//LAMPM1K3O4bnO58zO0NXOmPTOAa7Q47HQ5LvQ6c/Qpd/Qgc/R0cTS2snS29LS0uDSS+HSgNTTreLUfv/UAN3ViMDW78bW4fPWOOLamOXarP/aAcrb5tvb2+zbS8be+sve9c/g9Orgrf3iONTj8ePjt83k/+Tk5OTo6ePu9u7u7vDw7+Xy+t70//P09Or6/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAkAAF0ALAAAAABmABgAAAf/gBWCg4SFggeIiYqLjI2Oj5CRko1clZaXmFwVmZyWB0igoaKjSAednaanmZ+kraAHWrGxOykiKbKymlC7uzC1Jry8XKyupAfBUL4iwMjDW8/POLUp0NDDxa2wTj09IxYSBgYXNz1Gsbo+Jycb3+ET6j6719ijx+nr7QbvJ/FQzlFBgqjIdyFglGfzQqX4lU3LEyU8ikyZOCUGCiVErmjR9TAixYoXicgjBmrhsmxQOkqkaBHjyC0qP7YkgvCTjRAh2IEzsACnilAHrBzpwUVLkqNJpnDpIcOKFV1DiyJNulTGSCQ3c+brGeLnKyhRjSJVynQklrBTycrAguVaTJYh/4FaAfJD1o67dxUUWKilQhO6dvHu0KtBg1uIKyfOBPq37izBhA0fwAL4MV69OXJcQzu2qlzAXHac2lGBCWjRnZJ84nxULVDTdUOfUk05NmpOqpFU1iJ4cIEMGYYEpVtJ9DlMpGEXL7oRU+7dvfUCF65c9vFLqrMQt94c+6fTpzIEZfFjefdLycmbx/3ddvgDTNRbZ59FvnH2ustzzyQ+if3RFazwXyctHDDDdsadV0kDBwio322ZFLjEgJwUOMN/Ci54gH8PAujgcgQaiCEnDH4oW4gTdhjihSqSuKEHLWZC2gswglihiDFiwiCNOV5SoBQ1nngjizZmwuAOQSbBif8WVCRRQQ1JLkmFDjgWqeMBUOqnZCZMUgmkllJSOUOQEF6JJJiXiCVBX1lWsqUlYiVQhYFknsJgm1y8WUmcc37pJiZiYTDnmGgCSgUFByBJAjcMOJeEBDuw6cGiPTSKXRIRvIAFnYWmeSiWkzLqaKabAkmppZYcVYEUmxL6Z5pHIeBCogMQQMAAAqS5QwB3sVnrrbnCuesLNbQaJaxJyIrlr7jqGgCxpTIb7J67SsEqnac6+oALMyQqmC0L1QJpr0/WYG4NHbSgbgsgQEBssQfQEGql2nKL5bnorsuuu+aWaq21QuSgw8AtaPDvpjRI66wLNHTb28OCsYnvxBMjrLCIsAEw3C3FHPd7wL8gh3xwvDSUTAMHJaRcwgcOrFCywxBDLHHHFZNsMsoqs+xyw/fSjK+/IgeNsMlEF/2ytzH3NrPPHhvt9NFM//xx0ELb/DTRMCcdcblRw3u10Rt3DS/VVX9ddNZakyu212abHHbXQJM9cttuI512pFxHPTTdb+s9tdxz081zIAA7"

/***/ }),
/* 1622 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1623);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1623 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "#csscheck {\n    display: none;\n}\n\ndiv.page\n{\n    page-break-after: always;\n    page-break-inside: avoid;\n}\n\n.rp-print-title {\n    text-align: center;\n    font-size: 20px;\n}\n/* ------------ single record ------------ */\n\n.rp-print-single-details-row:nth-of-type(odd) {\n    background: #e0e0e0;\n}\n\n.customfield-rendered-label,\n.rp-print-single-label{\n    font-style: italic;\n    display: inline-block;\n    width: 6cm;\n}\n\n.rp-print-single-block-heading {\n    font-weight: bold;\n}\n\n.rp-print-single-block {\n    margin-left: 0.5cm;\n}\n\n.rp-print-single-value {\n\n}\n\n.rp-print-single-summary {\n    font-weight: bold;\n    font-size: 25px;\n}\n\n.rp-print-single {\n    margin-left: 1cm;\n    margin-right: 1cm;\n}\n\n.rp-print-single-logo {\n    text-align: right;\n    margin-bottom: 1cm;\n}\n.rp-print-single-logo img {\n    max-width: 400px;\n    max-height: 80px;\n}\n\n.rp-print-single-image {\n    text-align: left;\n}\n\n.rp-print-single .gridpanelrenderer_header_title,\n.rp-print-single .gridpanelrenderer_header_logo {\n    display: none;\n}\n\n.rp-print-single-tags {\n    margin-top: 2px;\n}\n\n.x-widget-tag-tagitem {\n    margin: 1px 2px 1px 1px;\n    background-color: #FFF8E0;\n    height: 16px;\n    border: 1px solid gray;\n    float: left;\n    color: gray;\n}\n\n.x-widget-tag-tagitem-color {\n    padding: 0 0 0 0;\n    margin: 0 0 0 0;\n    float: left;\n    background-color: #FFFFFF;\n    border-right: 1px solid gray;\n    width: 4px;\n    height: 16px;\n}\n\n.x-widget-tag-tagitem-text {\n    padding: 0 5px 0 5px;\n    margin: 0 0 0 0;\n    line-height: 16px;\n    font-weight: normal;\n    font-style: italic;\n}\n\n.x-clear {\n    clear: both;\n    height: 0;\n    overflow: hidden;\n    line-height: 0;\n    font-size: 0;\n}\n", ""]);

// exports


/***/ }),
/* 1624 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1625);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1625 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "\n.gx-popup-anc{background:transparent url(" + escape(__webpack_require__(1626)) + ") no-repeat 0 0;position:relative;top:-1px;left:5px;z-index:2;height:16px;width:31px;}", ""]);

// exports


/***/ }),
/* 1626 */
/***/ (function(module, exports) {

module.exports = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB8AAAAQCAYAAADu+KTsAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAfRJREFUeNq0VUtOAkEQra4eBhaigBCEhGg0fpbCxr34g40JCcFP0CO48ApuXegJjJuJ93Dj1sTEE3gGd1jVP6b5CGLoUFRPdU29V11d0+Lu6fUcAG5vOnvA4/PrG+Y1dsoppR9e3ljdI/1FPDEG5zBvYMZFszZEQAgAXmRtBZ0IpekXs/V9tL9Qwr6jgHliwYG23SOwXSICqIEkBZOxgEL0NAFkAhpAWB/Q/gjs04OtUtIDNjjggY8isLmSimVFQbGnAG3mEtmm16Wz9TQReuD3xwEPgfM43d/1CGwUkwRosmECZAsYEHWm6M2FIhGQXi/6GZu48Cs4v9yq+wTWCkmVYcDg0pZCZxqYsihgEqSH1YIP3KpXI/aZAlxvWfuw6hGo5JMmQ73V0sxt1pLqy7qyHHrA7QMCRn1GJoKjCwxwduQTKOdCd/gcAexnzetx4A69j9KsyykyD8wBsrW8PPEJFLOh114IusZsjwNfHNciW6rAEJ4ILkwtUdgWEtBt+AQKmdBsuS5BfinhAXcbtajfFbZD/lBzt72GyFWz5hHILSbUGus48HWTtlrY9gPXmnKammfSCcgsJLSOSZZk8DvA9sE+zqRD569jhS7eRPBJY5DAuA/INEPQrTbrXaFuQ5JHkudZAgT/uKg403eSj1kD/AgwAM3+h5KqbC2/AAAAAElFTkSuQmCC"

/***/ }),
/* 1627 */
/***/ (function(module, exports, __webpack_require__) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */
__webpack_require__(1628);

const qtipSatzart = Ext.util.Format.nl2br("10=Land\n20=Regierungsbezirk\n30=Region (nur in Baden-W\xFCrttemberg)\n40=Kreis\n50=Gemeindeverband\n&nbsp;Erl\xE4uterung der K\xFCrzel:\n&nbsp;&nbsp;Land 08 Baden-W\xFCrttemberg:\n&nbsp;&nbsp;&nbsp;VVG=Vereinbarte Verwaltungsgemeinschaft\n&nbsp;&nbsp;&nbsp;GVV=Gemeinde Verwaltungsverband\n&nbsp;&nbsp;Land 09 Bayern:\n&nbsp;&nbsp;&nbsp;Vgem=Verwaltungsgemeinschaft\n60=Gemeinde ");
const qtipTextkennzeichen = Ext.util.Format.nl2br("41=Kreisfreie Stadt\n42=Stadtkreis (nur in Baden-W\xFCrttemberg)\n43=Kreis\n44=Landkreis\n45=Regionalverband (nur im Saarland)\n50=Verbandsfreie Gemeinde\n51=Amt\n52=Samtgemeinde\n53=Verbandsgemeinde\n54=Verwaltungsgemeinschaft \n55=Kirchspielslandgemeinde\n56=Verwaltungsverband \n58=Erf\xFCllende Gemeinde\n60=Markt\n61=Kreisfreie Stadt\n62=Stadtkreis (nur in Baden-W\xFCrttemberg)\n63=Stadt\n64=Kreisangeh\xF6rige Gemeinde\n65=gemeindefreies Gebiet-bewohnt\n66=gemeindefreies Gebiet-unbewohnt\n67=Gro\xDFe Kreisstadt");
const qtipLand = Ext.util.Format.nl2br("01 Schleswig-Holstein\n02 Hamburg\n03 Niedersachsen\n04 Bremen\n05 Nordrhein-Westfalen\n06 Hessen\n07 Rheinland-Pfalz\n08 Baden-W\xFCrttemberg\n09 Bayern\n10 Saarland\n11 Berlin\n12 Brandenburg\n13 Mecklenburg-Vorpommern\n14 Sachsen\n15 Sachsen-Anhalt\n16 Th\xFCringen");
const template = new Ext.XTemplate('<table class="x-ars-xplain">' + '   <tr>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-satzart" rowSpan="2" ext:qtip="' + qtipSatzart + '">Satzart</td>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-textkennzeichen" rowSpan="2" ext:qtip="' + qtipTextkennzeichen + '">Textkennzeichen</td>' + '       <td class="x-ars-xplain-regionalschluessel" colspan="5">' + '           <table class="x-ars-xplain-group">' + '               <tr>' + '                   <td>&nbsp;</td>' + '                   <td rowspan="2">Amtlicher Regionalschlüssel</td>' + '                   <td>&nbsp;</td>' + '               </tr>' + '               <tr>' + '                   <td class="x-ars-xplain-leftcorner">&nbsp;</td>' + '                   <td class="x-ars-xplain-rightcorner">&nbsp;</td>' + '               </tr>' + '           </table>' + '       </td>' + '       <td class="x-ars-xplain-leer" rowspan="2"></td>' + '       <td class="x-ars-xplain-leer" rowspan="2"></td>' + '   </tr>' + '   <tr>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-land" ext:qtip="' + qtipLand + '">Land</td>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-rb" ext:qtip="Regierungsbezirk">RB</td>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-kreis">Kreis</td>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-vb" ext:qtip="Gemeindeverband">VB</td>' + '       <td class="x-ars-xplain-col x-ars-xplain-label-gem" ext:qtip="Gemeinde">Gem</td>' + '   </tr>' + '   <tr>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-satzart"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.satzArt)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-textkennzeichen"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.textkenzeichen)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-land"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.arsLand)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-rb"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.arsRB)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-kreis"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.arsKreis)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-vb"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.arsVB)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-value-gem"><input type="text" class="x-form-text x-form-field" value="{[this.encode(values.arsGem)]}"></td>' + '       <td class="x-ars-xplain-data x-ars-xplain-col x-ars-xplain-value-stand" ext:qtip="Letzte Aktuallisierung der Daten">stand: {[this.stand(values)]}</td>' + '       <td class="x-ars-xplain-data x-ars-xplain-col x-ars-xplain-show-original-btn" data-attachment="{[this.path(values)]}" data-id="{[this.getId(values)]}" ext:qtip="Zeige original Datensatz"></td>' + '   </tr>' + '</table>', {
  encode: function encode(v) {
    return v ? Ext.util.Format.htmlEncode(v) : '';
  },

  path(v) {
    return _.get(v, 'relations[0].related_record.path');
  },

  getId(v) {
    return _.get(v, 'relations[0].related_record.id');
  },

  stand(v) {
    const stand = v.last_modified_time || v.creation_time;
    return stand ? stand.format('d.m.Y') : '-';
  }

}).compile();
Ext.onReady(() => {
  Ext.getBody().on('click', function (e) {
    const target = e.getTarget('.x-ars-xplain-show-original-btn', 1, true);

    if (target) {
      const path = target.dom.dataset.attachment;
      const id = target.dom.dataset.id;
      Tine.OnlyOfficeIntegrator.OnlyOfficeEditDialog.openWindow({
        recordData: {
          path: path,
          id: id
        },
        id: id
      });
    }
  });
});
const ExplainForm = Ext.extend(Ext.form.Field, {
  // fieldLabel: 'Amtlicher Regionalschlüssel',
  hideLabel: true,
  defaultAutoCreate: {
    tag: 'div'
  },

  onRender() {
    this.supr().onRender.apply(this, arguments);
    template.overwrite(this.el, {});
  },

  setValue(value, record) {
    template.overwrite(this.el, record.data);
  }

});
Ext.reg('ars-explain-field', ExplainForm);
Tine.widgets.form.FieldManager.register('Tinebase', 'CommunityIdentNr', 'arsCombined', {
  xtype: 'ars-explain-field',
  height: 75
}, Tine.widgets.form.FieldManager.CATEGORY_EDITDIALOG);

/***/ }),
/* 1628 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1629);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1629 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "table.x-ars-xplain,\n.x-ars-xplain table {\n  border-spacing: 0px;\n}\n.x-ars-xplain-col {\n  padding: 2px;\n  vertical-align: bottom;\n  hyphens: auto;\n  width: 34px;\n  max-width: 46px;\n}\n.x-ars-xplain-group {\n  width: 100%;\n  text-align: center;\n}\n.x-ars-xplain-group tr {\n  height: 18px;\n}\n.x-ars-xplain-label-land {\n  border-left: 1px solid lightgray;\n}\n.x-ars-xplain-label-gem {\n  border-right: 1px solid lightgray;\n}\n.x-ars-xplain-leftcorner {\n  border-left: 1px solid lightgray;\n  border-top: 1px solid lightgray;\n  min-width: 10px;\n}\n.x-ars-xplain-rightcorner {\n  border-right: 1px solid lightgray;\n  border-top: 1px solid lightgray;\n  min-width: 10px;\n}\n.x-ars-xplain-data {\n  max-width: 46px;\n}\n.x-ars-xplain-data input {\n  width: 30px;\n  text-align: center;\n}\n.x-ars-xplain-value-stand {\n  font-size: 8px;\n}\n.x-ars-xplain-show-original-btn {\n  background-image: url(" + escape(__webpack_require__(540)) + ");\n  background-position: center;\n  background-repeat: no-repeat;\n  background-size: 14px;\n}\n.x-ars-xplain-show-original-btn:hover {\n  background-size: 16px;\n}\n.TinebaseCommunityIdentNr {\n  background-image: url(" + escape(__webpack_require__(540)) + ") !important;\n}\n", ""]);

// exports


/***/ }),
/* 1630 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Stefanie Stamer <s.stamer@metaways.de>
 * @copyright   Copyright (c) 2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
Tine.Tinebase.CommunityIdentNrPicker = Ext.extend(Tine.Tinebase.widgets.form.RecordPickerComboBox, {
  allowBlank: true,
  itemSelector: 'div.search-item',
  minListWidth: 450,
  // private
  initComponent: function initComponent() {
    this.app = Tine.Tinebase.appMgr.get('Tinebase');
    this.recordClass = Tine.Tinebase.Model.CommunityIdentNr;
    this.emptyText = this.app.i18n._('Search for Community Identification Numbers ...');
    this.initTemplate();
    Tine.Tinebase.CommunityIdentNrPicker.superclass.initComponent.call(this);
  },

  /**
   * use beforequery to set query filter
   *
   * @param {Event} qevent
   */
  onBeforeQuery: function onBeforeQuery(qevent) {
    Tine.Tinebase.CommunityIdentNrPicker.superclass.onBeforeQuery.apply(this, arguments);
    const filter = this.store.baseParams.filter;

    const queryFilter = _.find(filter, {
      field: 'query'
    });

    const nameFilter = {
      field: 'gemeindenamen',
      operator: 'startswith',
      value: qevent.query
    };
    const numberFilter = {
      field: 'arsCombined',
      operator: 'startswith',
      value: qevent.query
    };

    _.remove(filter, queryFilter);

    filter.push({
      condition: "OR",
      filters: [nameFilter, numberFilter]
    });
  },

  /**
   * init template
   * @private
   */
  initTemplate: function initTemplate() {
    // Custom rendering Template
    if (!this.tpl) {
      this.tpl = new Ext.XTemplate('<tpl for="."><div class="search-item">', '<table cellspacing="0" cellpadding="2" border="0" style="font-size: 11px;" width="100%">', '<tr>', '<td style="width:30%">{[this.encode(values.arsCombined)]}</td>', '<td style="width:40%">{[this.encode(values.gemeindenamen)]}</td>', '<td style="width:30%">{[this.getType(values.satzArt)]}</td>', '</tr>', '</table>', '</div></tpl>', {
        encode: function encode(values) {
          return Ext.util.Format.htmlEncode(values);
        },
        getType: function getType(values) {
          switch (values) {
            case 10:
              return 'Land';
              break;

            case 20:
              return 'Regierungsbezirk';
              break;

            case 30:
              return 'Region (nur in Baden-Württemberg)';
              break;

            case 40:
              return 'Kreis';
              break;

            case 50:
              return 'Gemeindeverband';
              break;

            case 60:
              return 'Gemeinde';
              break;

            default:
              return '';
          }
        }
      });
    }
  }
});
Ext.reg('communityidentnrpicker', Tine.Tinebase.CommunityIdentNrPicker);
Tine.widgets.form.RecordPickerManager.register('Tinebase', 'CommunityIdentNr', Tine.Tinebase.CommunityIdentNrPicker);

/***/ }),
/* 1631 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Tinebase
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Stefanie Stamer <s.stamer@metaways.de>
 * @copyright   Copyright (c) 2007-2021 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.Tinebase');
/**
 * CommunityIdentNrGridPanel
 * 
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.CommunityIdentNrGridPanel
 * @extends     Tine.widgets.grid.GridPanel
 * 
 * <p>CommunityIdentNr Grid Panel</p>
 *
 * @param       {Object} config
 * @constructor
 * Create a new Tine.Tinebase.CommunityIdentNrGridPanel
 */

Tine.Tinebase.CommunityIdentNrGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
  recordClass: Tine.Tinebase.Model.CommunityIdentNr,
  copyEditAction: false,
  multipleEdit: false,
  moveAction: false,
  duplicateResolvable: false,

  /**
   * @cfg {Bool} hasDetailsPanel
   */
  hasDetailsPanel: false,

  /**
   * inits this cmp
   * @private
   */
  initComponent: function initComponent() {
    Tine.Tinebase.CommunityIdentNrGridPanel.superclass.initComponent.call(this);
  },
  initActions: function initActions() {
    Tine.Tinebase.CommunityIdentNrGridPanel.superclass.initActions.apply(this, arguments);
    this.action_addInNewWindow.hide();
    this.action_editInNewWindow.hide();
    this.action_deleteRecord.hide();
    this.actions_import.hide();
  }
});

/***/ }),
/* 1632 */
/***/ (function(module, exports) {

Ext.ns('Tine.Tinebase');
Tine.Tinebase.CommunityIdentNrEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
  /**
   * @private
   */
  windowNamePrefix: 'CommunityIdentNrEditWindow_',
  appName: 'Tinebase',
  modelName: 'CommunityIdentNr',
  windowHeight: 600,
  evalGrants: false,

  /**
   * inits the component
   */
  initComponent: function initComponent() {
    this.recordClass = Tine.Tinebase.Model.CommunityIdentNr;
    Tine.Tinebase.CommunityIdentNrEditDialog.superclass.initComponent.call(this);
  },

  /**
   * executed after record got updated from proxy, if json Data is given, it's used
   *
   * @private
   */
  onAfterRecordLoad: function onAfterRecordLoad(jsonData) {
    Tine.Tinebase.CommunityIdentNrEditDialog.superclass.onAfterRecordLoad.call(this); //It should not be possible to edit COmmunity Ident Nrs via Edit Dialog

    this.btnSaveAndClose.hide(true);
  }
});

/***/ }),
/* 1633 */
/***/ (function(module, exports, __webpack_require__) {

/* WEBPACK VAR INJECTION */(function(global) {var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
 * Waves v0.7.6
 * http://fian.my.id/Waves
 *
 * Copyright 2014-2018 Alfiana E. Sibuea and other contributors
 * Released under the MIT license
 * https://github.com/fians/Waves/blob/master/LICENSE
 */

;(function(window, factory) {
    'use strict';

    // AMD. Register as an anonymous module.  Wrap in function so we have access
    // to root via `this`.
    if (true) {
        !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = (function() {
            window.Waves = factory.call(window);
            return window.Waves;
        }).apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__),
				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
    }

    // Node. Does not work with strict CommonJS, but only CommonJS-like
    // environments that support module.exports, like Node.
    else {}
})(typeof global === 'object' ? global : this, function() {
    'use strict';

    var Waves            = Waves || {};
    var $$               = document.querySelectorAll.bind(document);
    var toString         = Object.prototype.toString;
    var isTouchAvailable = 'ontouchstart' in window;


    // Find exact position of element
    function isWindow(obj) {
        return obj !== null && obj === obj.window;
    }

    function getWindow(elem) {
        return isWindow(elem) ? elem : elem.nodeType === 9 && elem.defaultView;
    }

    function isObject(value) {
        var type = typeof value;
        return type === 'function' || type === 'object' && !!value;
    }

    function isDOMNode(obj) {
        return isObject(obj) && obj.nodeType > 0;
    }

    function getWavesElements(nodes) {
        var stringRepr = toString.call(nodes);

        if (stringRepr === '[object String]') {
            return $$(nodes);
        } else if (isObject(nodes) && /^\[object (Array|HTMLCollection|NodeList|Object)\]$/.test(stringRepr) && nodes.hasOwnProperty('length')) {
            return nodes;
        } else if (isDOMNode(nodes)) {
            return [nodes];
        }

        return [];
    }

    function offset(elem) {
        var docElem, win,
            box = { top: 0, left: 0 },
            doc = elem && elem.ownerDocument;

        docElem = doc.documentElement;

        if (typeof elem.getBoundingClientRect !== typeof undefined) {
            box = elem.getBoundingClientRect();
        }
        win = getWindow(doc);
        return {
            top: box.top + win.pageYOffset - docElem.clientTop,
            left: box.left + win.pageXOffset - docElem.clientLeft
        };
    }

    function convertStyle(styleObj) {
        var style = '';

        for (var prop in styleObj) {
            if (styleObj.hasOwnProperty(prop)) {
                style += (prop + ':' + styleObj[prop] + ';');
            }
        }

        return style;
    }

    var Effect = {

        // Effect duration
        duration: 750,

        // Effect delay (check for scroll before showing effect)
        delay: 200,

        show: function(e, element, velocity) {

            // Disable right click
            if (e.button === 2) {
                return false;
            }

            element = element || this;

            // Create ripple
            var ripple = document.createElement('div');
            ripple.className = 'waves-ripple waves-rippling';
            element.appendChild(ripple);

            // Get click coordinate and element width
            var pos       = offset(element);
            var relativeY = 0;
            var relativeX = 0;
            // Support for touch devices
            if('touches' in e && e.touches.length) {
                relativeY   = (e.touches[0].pageY - pos.top);
                relativeX   = (e.touches[0].pageX - pos.left);
            }
            //Normal case
            else {
                relativeY   = (e.pageY - pos.top);
                relativeX   = (e.pageX - pos.left);
            }
            // Support for synthetic events
            relativeX = relativeX >= 0 ? relativeX : 0;
            relativeY = relativeY >= 0 ? relativeY : 0;

            var scale     = 'scale(' + ((element.clientWidth / 100) * 3) + ')';
            var translate = 'translate(0,0)';

            if (velocity) {
                translate = 'translate(' + (velocity.x) + 'px, ' + (velocity.y) + 'px)';
            }

            // Attach data to element
            ripple.setAttribute('data-hold', Date.now());
            ripple.setAttribute('data-x', relativeX);
            ripple.setAttribute('data-y', relativeY);
            ripple.setAttribute('data-scale', scale);
            ripple.setAttribute('data-translate', translate);

            // Set ripple position
            var rippleStyle = {
                top: relativeY + 'px',
                left: relativeX + 'px'
            };

            ripple.classList.add('waves-notransition');
            ripple.setAttribute('style', convertStyle(rippleStyle));
            ripple.classList.remove('waves-notransition');

            // Scale the ripple
            rippleStyle['-webkit-transform'] = scale + ' ' + translate;
            rippleStyle['-moz-transform'] = scale + ' ' + translate;
            rippleStyle['-ms-transform'] = scale + ' ' + translate;
            rippleStyle['-o-transform'] = scale + ' ' + translate;
            rippleStyle.transform = scale + ' ' + translate;
            rippleStyle.opacity = '1';

            var duration = e.type === 'mousemove' ? 2500 : Effect.duration;
            rippleStyle['-webkit-transition-duration'] = duration + 'ms';
            rippleStyle['-moz-transition-duration']    = duration + 'ms';
            rippleStyle['-o-transition-duration']      = duration + 'ms';
            rippleStyle['transition-duration']         = duration + 'ms';

            ripple.setAttribute('style', convertStyle(rippleStyle));
        },

        hide: function(e, element) {
            element = element || this;

            var ripples = element.getElementsByClassName('waves-rippling');

            for (var i = 0, len = ripples.length; i < len; i++) {
                removeRipple(e, element, ripples[i]);
            }

            if (isTouchAvailable) {
                element.removeEventListener('touchend', Effect.hide);
                element.removeEventListener('touchcancel', Effect.hide);
            }

            element.removeEventListener('mouseup', Effect.hide);
            element.removeEventListener('mouseleave', Effect.hide);
        }
    };

    /**
     * Collection of wrapper for HTML element that only have single tag
     * like <input> and <img>
     */
    var TagWrapper = {

        // Wrap <input> tag so it can perform the effect
        input: function(element) {

            var parent = element.parentNode;

            // If input already have parent just pass through
            if (parent.tagName.toLowerCase() === 'i' && parent.classList.contains('waves-effect')) {
                return;
            }

            // Put element class and style to the specified parent
            var wrapper       = document.createElement('i');
            wrapper.className = element.className + ' waves-input-wrapper';
            element.className = 'waves-button-input';

            // Put element as child
            parent.replaceChild(wrapper, element);
            wrapper.appendChild(element);

            // Apply element color and background color to wrapper
            var elementStyle    = window.getComputedStyle(element, null);
            var color           = elementStyle.color;
            var backgroundColor = elementStyle.backgroundColor;

            wrapper.setAttribute('style', 'color:' + color + ';background:' + backgroundColor);
            element.setAttribute('style', 'background-color:rgba(0,0,0,0);');

        },

        // Wrap <img> tag so it can perform the effect
        img: function(element) {

            var parent = element.parentNode;

            // If input already have parent just pass through
            if (parent.tagName.toLowerCase() === 'i' && parent.classList.contains('waves-effect')) {
                return;
            }

            // Put element as child
            var wrapper  = document.createElement('i');
            parent.replaceChild(wrapper, element);
            wrapper.appendChild(element);

        }
    };

    /**
     * Hide the effect and remove the ripple. Must be
     * a separate function to pass the JSLint...
     */
    function removeRipple(e, el, ripple) {

        // Check if the ripple still exist
        if (!ripple) {
            return;
        }

        ripple.classList.remove('waves-rippling');

        var relativeX = ripple.getAttribute('data-x');
        var relativeY = ripple.getAttribute('data-y');
        var scale     = ripple.getAttribute('data-scale');
        var translate = ripple.getAttribute('data-translate');

        // Get delay beetween mousedown and mouse leave
        var diff = Date.now() - Number(ripple.getAttribute('data-hold'));
        var delay = 350 - diff;

        if (delay < 0) {
            delay = 0;
        }

        if (e.type === 'mousemove') {
            delay = 150;
        }

        // Fade out ripple after delay
        var duration = e.type === 'mousemove' ? 2500 : Effect.duration;

        setTimeout(function() {

            var style = {
                top: relativeY + 'px',
                left: relativeX + 'px',
                opacity: '0',

                // Duration
                '-webkit-transition-duration': duration + 'ms',
                '-moz-transition-duration': duration + 'ms',
                '-o-transition-duration': duration + 'ms',
                'transition-duration': duration + 'ms',
                '-webkit-transform': scale + ' ' + translate,
                '-moz-transform': scale + ' ' + translate,
                '-ms-transform': scale + ' ' + translate,
                '-o-transform': scale + ' ' + translate,
                'transform': scale + ' ' + translate
            };

            ripple.setAttribute('style', convertStyle(style));

            setTimeout(function() {
                try {
                    el.removeChild(ripple);
                } catch (e) {
                    return false;
                }
            }, duration);

        }, delay);
    }


    /**
     * Disable mousedown event for 500ms during and after touch
     */
    var TouchHandler = {

        /* uses an integer rather than bool so there's no issues with
         * needing to clear timeouts if another touch event occurred
         * within the 500ms. Cannot mouseup between touchstart and
         * touchend, nor in the 500ms after touchend. */
        touches: 0,

        allowEvent: function(e) {

            var allow = true;

            if (/^(mousedown|mousemove)$/.test(e.type) && TouchHandler.touches) {
                allow = false;
            }

            return allow;
        },
        registerEvent: function(e) {
            var eType = e.type;

            if (eType === 'touchstart') {

                TouchHandler.touches += 1; // push

            } else if (/^(touchend|touchcancel)$/.test(eType)) {

                setTimeout(function() {
                    if (TouchHandler.touches) {
                        TouchHandler.touches -= 1; // pop after 500ms
                    }
                }, 500);

            }
        }
    };


    /**
     * Delegated click handler for .waves-effect element.
     * returns null when .waves-effect element not in "click tree"
     */
    function getWavesEffectElement(e) {

        if (TouchHandler.allowEvent(e) === false) {
            return null;
        }

        var element = null;
        var target = e.target || e.srcElement;

        while (target.parentElement) {
            if ( (!(target instanceof SVGElement)) && target.classList.contains('waves-effect')) {
                element = target;
                break;
            }
            target = target.parentElement;
        }

        return element;
    }

    /**
     * Bubble the click and show effect if .waves-effect elem was found
     */
    function showEffect(e) {

        // Disable effect if element has "disabled" property on it
        // In some cases, the event is not triggered by the current element
        // if (e.target.getAttribute('disabled') !== null) {
        //     return;
        // }

        var element = getWavesEffectElement(e);

        if (element !== null) {

            // Make it sure the element has either disabled property, disabled attribute or 'disabled' class
            if (element.disabled || element.getAttribute('disabled') || element.classList.contains('disabled')) {
                return;
            }

            TouchHandler.registerEvent(e);

            if (e.type === 'touchstart' && Effect.delay) {

                var hidden = false;

                var timer = setTimeout(function () {
                    timer = null;
                    Effect.show(e, element);
                }, Effect.delay);

                var hideEffect = function(hideEvent) {

                    // if touch hasn't moved, and effect not yet started: start effect now
                    if (timer) {
                        clearTimeout(timer);
                        timer = null;
                        Effect.show(e, element);
                    }
                    if (!hidden) {
                        hidden = true;
                        Effect.hide(hideEvent, element);
                    }

                    removeListeners();
                };

                var touchMove = function(moveEvent) {
                    if (timer) {
                        clearTimeout(timer);
                        timer = null;
                    }
                    hideEffect(moveEvent);

                    removeListeners();
                };

                element.addEventListener('touchmove', touchMove, false);
                element.addEventListener('touchend', hideEffect, false);
                element.addEventListener('touchcancel', hideEffect, false);

                var removeListeners = function() {
                    element.removeEventListener('touchmove', touchMove);
                    element.removeEventListener('touchend', hideEffect);
                    element.removeEventListener('touchcancel', hideEffect);
                };
            } else {

                Effect.show(e, element);

                if (isTouchAvailable) {
                    element.addEventListener('touchend', Effect.hide, false);
                    element.addEventListener('touchcancel', Effect.hide, false);
                }

                element.addEventListener('mouseup', Effect.hide, false);
                element.addEventListener('mouseleave', Effect.hide, false);
            }
        }
    }

    Waves.init = function(options) {
        var body = document.body;

        options = options || {};

        if ('duration' in options) {
            Effect.duration = options.duration;
        }

        if ('delay' in options) {
            Effect.delay = options.delay;
        }

        if (isTouchAvailable) {
            body.addEventListener('touchstart', showEffect, false);
            body.addEventListener('touchcancel', TouchHandler.registerEvent, false);
            body.addEventListener('touchend', TouchHandler.registerEvent, false);
        }

        body.addEventListener('mousedown', showEffect, false);
    };


    /**
     * Attach Waves to dynamically loaded inputs, or add .waves-effect and other
     * waves classes to a set of elements. Set drag to true if the ripple mouseover
     * or skimming effect should be applied to the elements.
     */
    Waves.attach = function(elements, classes) {

        elements = getWavesElements(elements);

        if (toString.call(classes) === '[object Array]') {
            classes = classes.join(' ');
        }

        classes = classes ? ' ' + classes : '';

        var element, tagName;

        for (var i = 0, len = elements.length; i < len; i++) {

            element = elements[i];
            tagName = element.tagName.toLowerCase();

            if (['input', 'img'].indexOf(tagName) !== -1) {
                TagWrapper[tagName](element);
                element = element.parentElement;
            }

            if (element.className.indexOf('waves-effect') === -1) {
                element.className += ' waves-effect' + classes;
            }
        }
    };


    /**
     * Cause a ripple to appear in an element via code.
     */
    Waves.ripple = function(elements, options) {
        elements = getWavesElements(elements);
        var elementsLen = elements.length;

        options          = options || {};
        options.wait     = options.wait || 0;
        options.position = options.position || null; // default = centre of element


        if (elementsLen) {
            var element, pos, off, centre = {}, i = 0;
            var mousedown = {
                type: 'mousedown',
                button: 1
            };
            var hideRipple = function(mouseup, element) {
                return function() {
                    Effect.hide(mouseup, element);
                };
            };

            for (; i < elementsLen; i++) {
                element = elements[i];
                pos = options.position || {
                    x: element.clientWidth / 2,
                    y: element.clientHeight / 2
                };

                off      = offset(element);
                centre.x = off.left + pos.x;
                centre.y = off.top + pos.y;

                mousedown.pageX = centre.x;
                mousedown.pageY = centre.y;

                Effect.show(mousedown, element);

                if (options.wait >= 0 && options.wait !== null) {
                    var mouseup = {
                        type: 'mouseup',
                        button: 1
                    };

                    setTimeout(hideRipple(mouseup, element), options.wait);
                }
            }
        }
    };

    /**
     * Remove all ripples from an element.
     */
    Waves.calm = function(elements) {
        elements = getWavesElements(elements);
        var mouseup = {
            type: 'mouseup',
            button: 1
        };

        for (var i = 0, len = elements.length; i < len; i++) {
            Effect.hide(mouseup, elements[i]);
        }
    };

    /**
     * Deprecated API fallback
     */
    Waves.displayEffect = function(options) {
        console.error('Waves.displayEffect() has been deprecated and will be removed in future version. Please use Waves.init() to initialize Waves effect');
        Waves.init(options);
    };

    return Waves;
});

/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(9)))

/***/ }),
/* 1634 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1635);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1635 */
/***/ (function(module, exports, __webpack_require__) {

exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, "/*!\n * Waves v0.7.6\n * http://fian.my.id/Waves \n * \n * Copyright 2014-2018 Alfiana E. Sibuea and other contributors \n * Released under the MIT license \n * https://github.com/fians/Waves/blob/master/LICENSE */\n.waves-effect {\n  position: relative;\n  cursor: pointer;\n  display: inline-block;\n  overflow: hidden;\n  -webkit-user-select: none;\n  -moz-user-select: none;\n  -ms-user-select: none;\n  user-select: none;\n  -webkit-tap-highlight-color: transparent;\n}\n.waves-effect .waves-ripple {\n  position: absolute;\n  border-radius: 50%;\n  width: 100px;\n  height: 100px;\n  margin-top: -50px;\n  margin-left: -50px;\n  opacity: 0;\n  background: rgba(0, 0, 0, 0.2);\n  background: -webkit-radial-gradient(rgba(0, 0, 0, 0.2) 0, rgba(0, 0, 0, 0.3) 40%, rgba(0, 0, 0, 0.4) 50%, rgba(0, 0, 0, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  background: -o-radial-gradient(rgba(0, 0, 0, 0.2) 0, rgba(0, 0, 0, 0.3) 40%, rgba(0, 0, 0, 0.4) 50%, rgba(0, 0, 0, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  background: -moz-radial-gradient(rgba(0, 0, 0, 0.2) 0, rgba(0, 0, 0, 0.3) 40%, rgba(0, 0, 0, 0.4) 50%, rgba(0, 0, 0, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  background: radial-gradient(rgba(0, 0, 0, 0.2) 0, rgba(0, 0, 0, 0.3) 40%, rgba(0, 0, 0, 0.4) 50%, rgba(0, 0, 0, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  -webkit-transition: all 0.5s ease-out;\n  -moz-transition: all 0.5s ease-out;\n  -o-transition: all 0.5s ease-out;\n  transition: all 0.5s ease-out;\n  -webkit-transition-property: -webkit-transform, opacity;\n  -moz-transition-property: -moz-transform, opacity;\n  -o-transition-property: -o-transform, opacity;\n  transition-property: transform, opacity;\n  -webkit-transform: scale(0) translate(0, 0);\n  -moz-transform: scale(0) translate(0, 0);\n  -ms-transform: scale(0) translate(0, 0);\n  -o-transform: scale(0) translate(0, 0);\n  transform: scale(0) translate(0, 0);\n  pointer-events: none;\n}\n.waves-effect.waves-light .waves-ripple {\n  background: rgba(255, 255, 255, 0.4);\n  background: -webkit-radial-gradient(rgba(255, 255, 255, 0.2) 0, rgba(255, 255, 255, 0.3) 40%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  background: -o-radial-gradient(rgba(255, 255, 255, 0.2) 0, rgba(255, 255, 255, 0.3) 40%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  background: -moz-radial-gradient(rgba(255, 255, 255, 0.2) 0, rgba(255, 255, 255, 0.3) 40%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n  background: radial-gradient(rgba(255, 255, 255, 0.2) 0, rgba(255, 255, 255, 0.3) 40%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0.5) 60%, rgba(255, 255, 255, 0) 70%);\n}\n.waves-effect.waves-classic .waves-ripple {\n  background: rgba(0, 0, 0, 0.2);\n}\n.waves-effect.waves-classic.waves-light .waves-ripple {\n  background: rgba(255, 255, 255, 0.4);\n}\n.waves-notransition {\n  -webkit-transition: none !important;\n  -moz-transition: none !important;\n  -o-transition: none !important;\n  transition: none !important;\n}\n.waves-button,\n.waves-circle {\n  -webkit-transform: translateZ(0);\n  -moz-transform: translateZ(0);\n  -ms-transform: translateZ(0);\n  -o-transform: translateZ(0);\n  transform: translateZ(0);\n  -webkit-mask-image: -webkit-radial-gradient(circle, white 100%, black 100%);\n}\n.waves-button,\n.waves-button:hover,\n.waves-button:visited,\n.waves-button-input {\n  white-space: nowrap;\n  vertical-align: middle;\n  cursor: pointer;\n  border: none;\n  outline: none;\n  color: inherit;\n  background-color: rgba(0, 0, 0, 0);\n  font-size: 1em;\n  line-height: 1em;\n  text-align: center;\n  text-decoration: none;\n  z-index: 1;\n}\n.waves-button {\n  padding: 0.85em 1.1em;\n  border-radius: 0.2em;\n}\n.waves-button-input {\n  margin: 0;\n  padding: 0.85em 1.1em;\n}\n.waves-input-wrapper {\n  border-radius: 0.2em;\n  vertical-align: bottom;\n}\n.waves-input-wrapper.waves-button {\n  padding: 0;\n}\n.waves-input-wrapper .waves-button-input {\n  position: relative;\n  top: 0;\n  left: 0;\n  z-index: 1;\n}\n.waves-circle {\n  text-align: center;\n  width: 2.5em;\n  height: 2.5em;\n  line-height: 2.5em;\n  border-radius: 50%;\n}\n.waves-float {\n  -webkit-mask-image: none;\n  -webkit-box-shadow: 0px 1px 1.5px 1px rgba(0, 0, 0, 0.12);\n  box-shadow: 0px 1px 1.5px 1px rgba(0, 0, 0, 0.12);\n  -webkit-transition: all 300ms;\n  -moz-transition: all 300ms;\n  -o-transition: all 300ms;\n  transition: all 300ms;\n}\n.waves-float:active {\n  -webkit-box-shadow: 0px 8px 20px 1px rgba(0, 0, 0, 0.3);\n  box-shadow: 0px 8px 20px 1px rgba(0, 0, 0, 0.3);\n}\n.waves-block {\n  display: block;\n}\n", ""]);

// exports


/***/ }),
/* 1636 */
/***/ (function(module, exports, __webpack_require__) {

// style-loader: Adds some css to the DOM by adding a <style> tag

// load the styles
var content = __webpack_require__(1637);
if(typeof content === 'string') content = [[module.i, content, '']];
// Prepare cssTransformation
var transform;

var options = {"hmr":true}
options.transform = transform
// add the styles to the DOM
var update = __webpack_require__(17)(content, options);
if(content.locals) module.exports = content.locals;
// Hot Module Replacement
if(false) {}

/***/ }),
/* 1637 */
/***/ (function(module, exports, __webpack_require__) {

var escape = __webpack_require__(108);
exports = module.exports = __webpack_require__(16)(false);
// imports


// module
exports.push([module.i, ".x-btn.waves-effect {\n  display: table;\n}\n.x-tree-node-el.waves-effect {\n  display: block;\n}\n/* TABPANEL */\n.x-tab-strip-top .x-tab-strip-active .x-tab-right span.x-tab-strip-text {\n  padding-bottom: 5px;\n}\n.x-tab-strip .x-tab-strip-top {\n  border-bottom: none;\n}\n.x-tab-panel-header,\n.x-tab-panel-footer,\n.x-tab-panel-header,\n.x-tab-panel-footer,\n.x-tab-panel-header-plain .x-tab-strip-spacer,\n.x-tab-panel-footer-plain .x-tab-strip-spacer {\n  border-color: #0062a7;\n  background-color: #0062a7;\n}\n/* AppTabs */\n.tine-mainscreen-apptabs .x-tab-strip-wrap ul.x-tab-strip-top {\n  background-color: #0062a7;\n  background-image: none;\n}\n.tine-mainscreen-apptabs ul.x-tab-strip li {\n  height: 30px;\n  background-color: #0062a7;\n}\n.tine-mainscreen-apptabs ul.x-tab-strip span.x-tab-strip-text,\n.tine-mainscreen-apptabs ul.x-tab-strip a.x-tab-strip-close {\n  color: black;\n  filter: invert(100%);\n}\n.tine-mainscreen-apptabs ul.x-tab-strip li.x-tab-strip-active,\n.tine-mainscreen-apptabs ul.x-tab-strip li:hover {\n  background-color: #ffffff;\n}\n.tine-mainscreen-apptabs ul.x-tab-strip li.x-tab-strip-active span.x-tab-strip-text,\n.tine-mainscreen-apptabs ul.x-tab-strip li:hover span.x-tab-strip-text,\n.tine-mainscreen-apptabs ul.x-tab-strip li.x-tab-strip-active a.x-tab-strip-close,\n.tine-mainscreen-apptabs ul.x-tab-strip li:hover a.x-tab-strip-close {\n  filter: invert(0%);\n}\n.tine-mainscreen-apptabs .x-tab-strip-top,\n.tine-mainscreen-apptabs .x-tab-right {\n  padding-top: 4px;\n}\nul.x-tab-strip li {\n  background-color: #8cb8d7;\n  margin-left: 0px;\n}\nli.x-item-disabled span.x-tab-strip-text,\nli.x-item-disabled span.x-tab-strip-text:hover {\n  color: black !important;\n}\nul.x-tab-strip li.x-tab-strip-active {\n  background-color: #0062a7;\n}\nul.x-tab-strip-top {\n  border-color: #0062a7;\n}\n.x-tab-strip-top .x-tab-right,\n.x-tab-strip-top .x-tab-left,\n.x-tab-strip-top .x-tab-strip-inner {\n  background-image: none;\n}\n.x-tab-strip .x-tab-with-icon span.x-tab-strip-text {\n  padding-left: 18px;\n}\n.x-tab-strip span.x-tab-strip-text {\n  font-size: 10px;\n  color: #3d2716;\n  text-transform: uppercase;\n}\n.x-tab-strip span.x-tab-strip-text:hover,\n.x-tab-strip-active span.x-tab-strip-text,\n.x-tab-strip-active .x-tab-strip-close {\n  font-weight: normal;\n  filter: invert(89%) sepia(81%) saturate(2%) hue-rotate(17deg) brightness(115%) contrast(101%);\n}\n.x-tab-strip .x-tab-strip-closable .x-tab-left {\n  padding-right: 15px;\n}\n.x-tab-strip .x-tab-strip-closable a.x-tab-strip-close {\n  background-image: url(" + escape(__webpack_require__(227)) + ");\n  background-size: 8px;\n  background-position: 1px 1px;\n}\n.x-tab-strip .x-tab-strip-closable a.x-tab-strip-close:hover {\n  background-image: url(" + escape(__webpack_require__(227)) + ");\n  background-size: 10px;\n  background-position: 0px;\n}\nspan.x-tab-strip-text.tine-favicon {\n  font-size: 12px;\n  text-transform: lowercase;\n}\n/* BUTTON */\n.x-toolbar .x-btn-over .x-btn-mc em.x-btn-split,\n.x-toolbar .x-btn-click .x-btn-mc em.x-btn-split,\n.x-toolbar .x-btn-menu-active .x-btn-mc em.x-btn-split,\n.x-toolbar .x-btn-pressed .x-btn-mc em.x-btn-split {\n  background-image: none;\n}\n.x-btn-tl,\n.x-btn-tc,\n.x-btn-tr,\n.x-btn-ml,\n.x-btn-mc,\n.x-btn-mr,\n.x-btn-bl,\n.x-btn-bc,\n.x-btn-br {\n  background-color: #eaeef1;\n  background-image: none;\n  transition: background-color 0.2s ease-out;\n}\n.x-btn-over .x-btn-tl,\n.x-btn-over .x-btn-tc,\n.x-btn-over .x-btn-tr,\n.x-btn-over .x-btn-ml,\n.x-btn-over .x-btn-mc,\n.x-btn-over .x-btn-mr,\n.x-btn-over .x-btn-bl,\n.x-btn-over .x-btn-bc,\n.x-btn-over .x-btn-br {\n  background-color: #cbd5dd;\n  transition: background-color 0.2s;\n}\n.x-btn-pressed .x-btn-tl,\n.x-btn-pressed .x-btn-tc,\n.x-btn-pressed .x-btn-tr,\n.x-btn-pressed .x-btn-ml,\n.x-btn-pressed .x-btn-mc,\n.x-btn-pressed .x-btn-mr,\n.x-btn-pressed .x-btn-bl,\n.x-btn-pressed .x-btn-bc,\n.x-btn-pressed .x-btn-br {\n  background-color: #adbcc8;\n}\n.x-toolbar .x-btn-mc em.x-btn-split .x-btn-text {\n  border-right: 1px solid transparent;\n}\n.x-toolbar .x-btn-over .x-btn-mc em.x-btn-split,\n.x-toolbar .x-btn-click .x-btn-mc em.x-btn-split,\n.x-toolbar .x-btn-menu-active .x-btn-mc em.x-btn-split,\n.x-toolbar .x-btn-pressed .x-btn-mc em.x-btn-split {\n  background-image: url(" + escape(__webpack_require__(143)) + ");\n  background-size: 12px;\n}\n.x-toolbar .x-btn-over .x-btn-mc em.x-btn-split .x-btn-text,\n.x-toolbar .x-btn-click .x-btn-mc em.x-btn-split .x-btn-text,\n.x-toolbar .x-btn-menu-active .x-btn-mc em.x-btn-split .x-btn-text,\n.x-toolbar .x-btn-pressed .x-btn-mc em.x-btn-split .x-btn-text {\n  border-right: 1px dotted;\n}\n.x-btn-mc em.x-btn-arrow,\n.x-toolbar .x-btn-mc em.x-btn-split {\n  background-image: url(" + escape(__webpack_require__(143)) + ");\n  background-size: 10px;\n  background-position-y: center;\n}\n.tine-mainscreen-mainmenu .x-toolbar {\n  background-image: none;\n  background-color: #0062a7;\n}\n.tine-mainscreen-mainmenu .x-toolbar .renderer_accountUserChangedIcon {\n  background-color: white !important;\n}\n.tine-mainscreen-mainmenu .x-btn {\n  color: black;\n  filter: invert(89%) sepia(81%) saturate(2%) hue-rotate(17deg) brightness(115%) contrast(101%);\n}\n/* TOOLBAR */\n.x-toolbar {\n  background-image: none;\n  background-color: #f2f2f2;\n  border: none !important;\n}\n.x-toolbar .x-btn-tl,\n.x-toolbar .x-btn-tc,\n.x-toolbar .x-btn-tr,\n.x-toolbar .x-btn-ml,\n.x-toolbar .x-btn-mc,\n.x-toolbar .x-btn-mr,\n.x-toolbar .x-btn-bl,\n.x-toolbar .x-btn-bc,\n.x-toolbar .x-btn-br {\n  background-color: #f2f2f2;\n  background-image: none;\n  transition: background-color 0.2s ease-out;\n}\n.x-toolbar .x-btn-over .x-btn-tl,\n.x-toolbar .x-btn-over .x-btn-tc,\n.x-toolbar .x-btn-over .x-btn-tr,\n.x-toolbar .x-btn-over .x-btn-ml,\n.x-toolbar .x-btn-over .x-btn-mc,\n.x-toolbar .x-btn-over .x-btn-mr,\n.x-toolbar .x-btn-over .x-btn-bl,\n.x-toolbar .x-btn-over .x-btn-bc,\n.x-toolbar .x-btn-over .x-btn-br {\n  background-color: #d9d9d9;\n  transition: background-color 0.2s;\n}\n.x-toolbar .x-btn-pressed .x-btn-tl,\n.x-toolbar .x-btn-pressed .x-btn-tc,\n.x-toolbar .x-btn-pressed .x-btn-tr,\n.x-toolbar .x-btn-pressed .x-btn-ml,\n.x-toolbar .x-btn-pressed .x-btn-mc,\n.x-toolbar .x-btn-pressed .x-btn-mr,\n.x-toolbar .x-btn-pressed .x-btn-bl,\n.x-toolbar .x-btn-pressed .x-btn-bc,\n.x-toolbar .x-btn-pressed .x-btn-br {\n  background-color: #bfbfbf;\n}\n.x-toolbar .xtb-sep {\n  background-image: none;\n}\n.x-toolbar div.xtb-text,\n.x-toolbar label {\n  padding: 0px 2px 0;\n  line-height: 15px;\n}\n.checkbox-footbar {\n  vertical-align: middle;\n}\n.checkbox-footbar .x-form-check-wrap {\n  line-height: 19px !important;\n}\n.checkbox-footbar .x-form-check-wrap input {\n  top: 0px;\n}\n.checkbox-footbar .x-form-cb-label {\n  border-left: 18px solid transparent;\n  vertical-align: middle;\n}\n.x-btn-group-tc,\n.x-btn-group-tl,\n.x-btn-group-tr,\n.x-btn-group-bc,\n.x-btn-group-bl,\n.x-btn-group-br,\n.x-btn-group-ml,\n.x-btn-group-mr,\n.x-btn-group-notitle .x-btn-group-tc {\n  background-image: none;\n}\n.x-panel-footer .x-btn-tl,\n.x-panel-footer .x-btn-tc,\n.x-panel-footer .x-btn-tr,\n.x-panel-footer .x-btn-ml,\n.x-panel-footer .x-btn-mc,\n.x-panel-footer .x-btn-mr,\n.x-panel-footer .x-btn-bl,\n.x-panel-footer .x-btn-bc,\n.x-panel-footer .x-btn-br {\n  background-color: #d7d7d7;\n  background-image: none;\n  transition: background-color 0.2s ease-out;\n}\n.x-panel-footer .x-btn-over .x-btn-tl,\n.x-panel-footer .x-btn-over .x-btn-tc,\n.x-panel-footer .x-btn-over .x-btn-tr,\n.x-panel-footer .x-btn-over .x-btn-ml,\n.x-panel-footer .x-btn-over .x-btn-mc,\n.x-panel-footer .x-btn-over .x-btn-mr,\n.x-panel-footer .x-btn-over .x-btn-bl,\n.x-panel-footer .x-btn-over .x-btn-bc,\n.x-panel-footer .x-btn-over .x-btn-br {\n  background-color: #bdbdbd;\n  transition: background-color 0.2s;\n}\n.x-panel-footer .x-btn-pressed .x-btn-tl,\n.x-panel-footer .x-btn-pressed .x-btn-tc,\n.x-panel-footer .x-btn-pressed .x-btn-tr,\n.x-panel-footer .x-btn-pressed .x-btn-ml,\n.x-panel-footer .x-btn-pressed .x-btn-mc,\n.x-panel-footer .x-btn-pressed .x-btn-mr,\n.x-panel-footer .x-btn-pressed .x-btn-bl,\n.x-panel-footer .x-btn-pressed .x-btn-bc,\n.x-panel-footer .x-btn-pressed .x-btn-br {\n  background-color: #a3a3a3;\n}\n.x-btn-group {\n  padding: 0px;\n}\n.x-btn-group-tl,\n.x-btn-group-bl,\n.x-btn-group-br {\n  height: 0;\n}\n.x-btn-group-mc {\n  padding: 0;\n}\n.x-toolbar-more-icon {\n  background-image: url(" + escape(__webpack_require__(1638)) + ") !important;\n}\n/* MAIN NORTH TOOLBAR */\n.tine-mainscreen-centerpanel-north .x-btn-tl,\n.tine-mainscreen-centerpanel-north .x-btn-tc,\n.tine-mainscreen-centerpanel-north .x-btn-tr,\n.tine-mainscreen-centerpanel-north .x-btn-ml,\n.tine-mainscreen-centerpanel-north .x-btn-mc,\n.tine-mainscreen-centerpanel-north .x-btn-mr,\n.tine-mainscreen-centerpanel-north .x-btn-bl,\n.tine-mainscreen-centerpanel-north .x-btn-bc,\n.tine-mainscreen-centerpanel-north .x-btn-br {\n  background-color: #ffffff;\n  background-image: none;\n  transition: background-color 0.2s ease-out;\n}\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-tl,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-tc,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-tr,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-ml,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-mc,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-mr,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-bl,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-bc,\n.tine-mainscreen-centerpanel-north .x-btn-over .x-btn-br {\n  background-color: #e6e6e6;\n  transition: background-color 0.2s;\n}\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-tl,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-tc,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-tr,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-ml,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-mc,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-mr,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-bl,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-bc,\n.tine-mainscreen-centerpanel-north .x-btn-pressed .x-btn-br {\n  background-color: #cccccc;\n}\n.tine-mainscreen-centerpanel-north .x-toolbar {\n  background-color: #ffffff;\n  padding: 0;\n  border-bottom: 1px #d9d9d9 solid !important;\n}\n.tine-mainscreen-centerpanel-north .x-toolbar .x-item-disabled {\n  opacity: 0.5;\n}\n.tine-mainscreen-centerpanel-north .x-toolbar .x-btn-group .x-toolbar {\n  border-bottom: 0px !important;\n}\n.tine-mainscreen-centerpanel-north .x-panel-bwrap {\n  background-color: #f2f2f2;\n  color: black;\n}\n.tine-mainscreen-centerpanel-north .x-panel-body {\n  color: black;\n}\n.tine-mainscreen-centerpanel-north .x-btn .x-btn-text,\n.tine-mainscreen-centerpanel-north .x-item-disabled .x-btn-text {\n  color: #000000 !important;\n}\n.tine-mainscreen-centerpanel-north .x-toolbar .x-btn-mc em.x-btn-arrow .x-btn-image,\n.tine-mainscreen-centerpanel-north .x-toolbar .x-btn-mc em.x-btn-split .x-btn-image {\n  filter: none;\n}\n.tine-mainscreen-centerpanel-north .x-btn em.x-btn-arrow .x-btn-text,\n.tine-mainscreen-centerpanel-north .x-btn em.x-btn-split .x-btn-text {\n  color: #000000 !important;\n}\n.tine-mainscreen-centerpanel-north input {\n  background: transparent;\n  width: 258px;\n  border-top: none;\n  border-left: none;\n  border-right: none;\n  border-bottom: 1px solid black !important;\n  color: #000000;\n}\n.tine-mainscreen-centerpanel-north .x-form-trigger {\n  background-position: 0 !important;\n  border-bottom: none;\n  background-size: 14px;\n  background-color: transparent !important;\n  box-sizing: border-box;\n  border-bottom: 1px solid black !important;\n}\n.tine-mainscreen-centerpanel-north .x-trigger-wrap-focus .x-form-trigger {\n  border-bottom: 1px solid black !important;\n}\n.tine-mainscreen-centerpanel-north .x-btn-medium.x-btn-icon-medium-top .x-btn-image {\n  background-size: 27px 29px;\n}\n/* FILTER TOOLBAR */\n.tw-ftb-filterpanel .ux-arrowcollapse .x-tool-toggle,\n.tw-ftb-filterpanel .x-layout-split,\n.tw-ftb-filterstructure-treepanel .x-panel-tbar-noborder .x-toolbar,\n.tw-ftb-filterstructure-treepanel .x-panel-body,\n.tw-ftb-filterpanel .x-panel-body,\n.tw-ftb-filterpanel .x-toolbar,\n.x-panel-bwrap .tw-filtertoolbar,\n.tw-filtertoolbar {\n  background-color: #d9d9d9;\n}\n.tw-filtertoolbar .x-btn-tl,\n.tw-filtertoolbar .x-btn-tc,\n.tw-filtertoolbar .x-btn-tr,\n.tw-filtertoolbar .x-btn-ml,\n.tw-filtertoolbar .x-btn-mc,\n.tw-filtertoolbar .x-btn-mr,\n.tw-filtertoolbar .x-btn-bl,\n.tw-filtertoolbar .x-btn-bc,\n.tw-filtertoolbar .x-btn-br {\n  background-color: #d9d9d9;\n  background-image: none;\n  transition: background-color 0.2s ease-out;\n}\n.tw-filtertoolbar .x-btn-over .x-btn-tl,\n.tw-filtertoolbar .x-btn-over .x-btn-tc,\n.tw-filtertoolbar .x-btn-over .x-btn-tr,\n.tw-filtertoolbar .x-btn-over .x-btn-ml,\n.tw-filtertoolbar .x-btn-over .x-btn-mc,\n.tw-filtertoolbar .x-btn-over .x-btn-mr,\n.tw-filtertoolbar .x-btn-over .x-btn-bl,\n.tw-filtertoolbar .x-btn-over .x-btn-bc,\n.tw-filtertoolbar .x-btn-over .x-btn-br {\n  background-color: #bfbfbf;\n  transition: background-color 0.2s;\n}\n.tw-filtertoolbar .x-btn-pressed .x-btn-tl,\n.tw-filtertoolbar .x-btn-pressed .x-btn-tc,\n.tw-filtertoolbar .x-btn-pressed .x-btn-tr,\n.tw-filtertoolbar .x-btn-pressed .x-btn-ml,\n.tw-filtertoolbar .x-btn-pressed .x-btn-mc,\n.tw-filtertoolbar .x-btn-pressed .x-btn-mr,\n.tw-filtertoolbar .x-btn-pressed .x-btn-bl,\n.tw-filtertoolbar .x-btn-pressed .x-btn-bc,\n.tw-filtertoolbar .x-btn-pressed .x-btn-br {\n  background-color: #a6a6a6;\n}\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-tl,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-tc,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-tr,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-ml,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-mc,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-mr,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-bl,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-bc,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-br {\n  background-color: #d9d9d9;\n}\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-tl,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-tc,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-tr,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-ml,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-mc,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-mr,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-bl,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-bc,\n.tw-filtertoolbar .tw-ftb-frow-searchbutton .x-btn-over .x-btn-over .x-btn-br {\n  background-color: #f2f2f2;\n}\n.tw-filtertoolbar .x-btn-over .x-btn-tl,\n.tw-filtertoolbar .x-btn-over .x-btn-tc,\n.tw-filtertoolbar .x-btn-over .x-btn-tr,\n.tw-filtertoolbar .x-btn-over .x-btn-ml,\n.tw-filtertoolbar .x-btn-over .x-btn-mc,\n.tw-filtertoolbar .x-btn-over .x-btn-mr,\n.tw-filtertoolbar .x-btn-over .x-btn-bl,\n.tw-filtertoolbar .x-btn-over .x-btn-bc,\n.tw-filtertoolbar .x-btn-over .x-btn-br {\n  background-color: #f2f2f2;\n}\n.tw-ftb-filterstructure-treepanel span.ux-arrowcollapse-header-text {\n  color: #4c4c4c;\n}\n.tw-ftb-filterstructure-treepanel div.x-tree-selected {\n  background-color: #f2f2f2;\n}\n/* PANEL */\n.x-panel-tr,\n.x-panel-tc,\n.x-panel-tl,\n.x-panel-mr,\n.x-panel-mc,\n.x-panel-ml,\n.x-panel-br,\n.x-panel-bc,\n.x-panel-bl,\n.x-panel-bwrap,\n.x-panel-ghost,\n.x-panel-ghost ul {\n  background-image: none;\n  background-color: #c0ced8;\n  border: none;\n}\n/* FORM PANEL */\n.x-form .x-panel-tr,\n.x-form .x-panel-tc,\n.x-form .x-panel-tl,\n.x-form .x-panel-mr,\n.x-form .x-panel-mc,\n.x-form .x-panel-ml,\n.x-form .x-panel-br,\n.x-form .x-panel-bc,\n.x-form .x-panel-bl,\n.x-form .x-panel-bwrap {\n  background-image: none;\n  background-color: #eaeef1;\n}\n.x-form ul.x-tab-strip-top {\n  background: none;\n  background-color: #eaeef1;\n}\n.x-panel-header {\n  background-image: none;\n  background-color: #f2f2f2;\n  border: none;\n}\n.x-form .x-panel-tl,\n.x-form .x-panel-tc,\n.x-form .x-panel-tr {\n  border: none;\n  background-color: #f2f2f2;\n}\n.x-accordion-hd {\n  background-image: none;\n  background-color: #f2f2f2;\n}\n.x-border-layout-ct {\n  background-color: #f2f2f2;\n}\n.x-layout-collapsed,\n.x-layout-split {\n  background-color: white;\n}\n/* FORM */\n.x-form-text,\ntextarea.x-form-field {\n  background-image: none;\n}\n.tw-editdialog .x-grid3 {\n  background-color: #eaeef1;\n}\n.tw-editdialog .x-grid-panel .x-panel-body {\n  border: none;\n}\n.tw-editdialog .x-panel-header {\n  background: none;\n  color: black;\n  font-weight: normal;\n  font-style: normal;\n}\n.x-form-text,\ntextarea.x-form-field {\n  border-left: none !important;\n  border-right: none !important;\n  border-top: none !important;\n}\n.x-form-field-wrap .x-form-trigger {\n  background-position-y: -1px;\n  background-position-x: 1px;\n  border-bottom: none;\n}\n.x-form-text,\ntextarea.x-form-field {\n  border-color: #f2f2f2;\n}\n/* PROGRESS */\n.x-form-text-progress {\n  background: linear-gradient(to right, #F9EC31 var(--scroll), transparent 0);\n  background-repeat: no-repeat;\n  position: fixed;\n  width: 100%;\n  height: 4px;\n  z-index: 1;\n}\n.x-grid3-check-col {\n  background-image: url(" + escape(__webpack_require__(1639)) + ");\n}\n.x-grid3-check-col-on {\n  background-image: url(" + escape(__webpack_require__(1640)) + ");\n}\n.x-grid3-cell-inner .x-grid3-check-col,\n.x-grid3-cell-inner .x-grid3-check-col-on {\n  background-size: 18px;\n}\n.x-tree-node .x-type-data-pending,\n.x-type-data-pending td {\n  opacity: 0.6;\n}\n.x-form-focus,\ntextarea.x-form-focus {\n  border-color: #0062a7;\n}\n.x-form-trigger-flat {\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.x-form-trigger-flat:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-trigger-wrap-focus .x-form-trigger {\n  border-bottom: 1px solid #0062a7 !important;\n  box-sizing: border-box;\n}\n.x-form-field-wrap .x-form-trigger,\n.x-form-trigger.x-form-arrow-trigger,\n.x-form-trigger {\n  background-image: url(" + escape(__webpack_require__(143)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.x-form-field-wrap .x-form-trigger:hover,\n.x-form-trigger.x-form-arrow-trigger:hover,\n.x-form-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-form-trigger.x-form-search-trigger {\n  background-image: url(" + escape(__webpack_require__(649)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.x-form-trigger.x-form-search-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-form-trigger.x-form-clear-trigger {\n  background-image: url(" + escape(__webpack_require__(227)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.x-form-trigger.x-form-clear-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-form-field-wrap .x-form-date-trigger {\n  background-image: url(" + escape(__webpack_require__(369)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.x-form-field-wrap .x-form-date-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-form-field-wrap img.x-form-spinner-trigger {\n  background-image: url(" + escape(__webpack_require__(1641)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n  background-position-y: 3px !important;\n}\n.x-form-field-wrap img.x-form-spinner-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-form-field-wrap img.x-form-spinner-trigger:hover {\n  background-position-y: 2px !important;\n}\n.tw-uidTriggerField .x-form-field-wrap .x-form-trigger {\n  background-image: url(" + escape(__webpack_require__(543)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n  background-size: 17px;\n}\n.tw-uidTriggerField .x-form-field-wrap .x-form-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.tw-uidTriggerField .x-form-field-wrap .x-form-trigger:hover {\n  background-size: 19px;\n}\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger:nth-child(1) {\n  background-image: url(" + escape(__webpack_require__(644)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger:nth-child(1):hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger.locked:nth-child(1) {\n  background-image: url(" + escape(__webpack_require__(1642)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger.locked:nth-child(1):hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger:nth-child(2) {\n  background-image: url(" + escape(__webpack_require__(530)) + ") !important;\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.tw-passwordTriggerField .x-form-field-wrap .x-form-trigger:nth-child(2):hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\nspan.x-form-twin-triggers img.x-form-unlocked-trigger {\n  background-image: url(" + escape(__webpack_require__(370)) + ") !important;\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\nspan.x-form-twin-triggers img.x-form-unlocked-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\nspan.x-form-twin-triggers img.x-form-locked-trigger {\n  background-image: url(" + escape(__webpack_require__(371)) + ") !important;\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\nspan.x-form-twin-triggers img.x-form-locked-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\nspan.x-form-twin-triggers img.x-form-clear-trigger {\n  background-image: url(" + escape(__webpack_require__(227)) + ") !important;\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n  background-size: 11px;\n  background-position-y: 2px !important;\n}\nspan.x-form-twin-triggers img.x-form-clear-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\nspan.x-form-twin-triggers img.x-form-clear-trigger:hover {\n  background-size: 13px;\n  background-position-y: 1px !important;\n}\n.tw-recordEditField .x-form-field-wrap .x-form-trigger {\n  background-image: url(" + escape(__webpack_require__(388)) + ");\n  background-position: 2px 1px !important;\n  border-bottom: none;\n  background-size: 13px;\n  background-color: white;\n  border-bottom: 1px solid #f2f2f2;\n  box-sizing: border-box;\n}\n.tw-recordEditField .x-form-field-wrap .x-form-trigger:hover {\n  background-size: 15px 15px !important;\n  background-position: 1px 0px !important;\n}\n.x-html-editor-wrap {\n  border: none;\n}\n.x-combo-list {\n  border: none;\n}\n.x-combo-list .x-combo-selected {\n  background-color: #dbecf4;\n  border-color: #dbecf4 !important;\n}\n.x-form-invalid-tip .x-tip-body {\n  background-image: url(" + escape(__webpack_require__(544)) + ") !important;\n  background-size: 20px 20px;\n  background-position: 0 4px;\n  color: #000 !important;\n  filter: invert(89%) sepia(81%) saturate(2%) hue-rotate(17deg) brightness(115%) contrast(101%);\n}\n.x-form-invalid {\n  background-color: #fee !important;\n  border-bottom: 1px solid #ff7870 !important;\n}\n.x-form-invalid + span img.x-form-trigger {\n  background-color: #fee !important;\n  border-bottom: 1px solid #ff7870 !important;\n}\n/* GRID */\n.x-grid3-header,\n.cal-timelinepanel-header-label,\n.cal-timelinepanel-header,\n.cal-monthview-inner-header,\n.cal-daysviewpanel-daysheader,\n.x-grid3-quickadd .x-grid3-header {\n  background-image: none;\n  background-color: #c0ced8;\n}\n.x-grid3-hd .x-grid3-hd-inner {\n  white-space: normal;\n  display: -webkit-box;\n  -webkit-line-clamp: 3;\n  -webkit-box-orient: vertical;\n}\n.x-grid3-header {\n  hyphens: auto;\n}\n.ext-ux-grid-gridviewmenuplugin-menuBtn.x-grid3-hd-btn {\n  border-left: 1px solid #eee;\n  background-color: #c0ced8;\n}\ntd.x-grid3-hd-over,\ntd.sort-asc,\ntd.sort-desc,\ntd.x-grid3-hd-menu-open .x-grid3-hd-inner {\n  background-image: none;\n  background-color: #a1b6c5;\n}\n.x-grid3-hd-btn,\n.x-grid3-hd-over .x-grid3-hd-btn {\n  background-image: url(" + escape(__webpack_require__(143)) + ");\n  background-size: 12px;\n  background-color: inherit;\n}\na.x-grid3-hd-btn:hover {\n  background-position: 0% 50%;\n  background-size: 14px;\n}\n.x-grid3-sort-icon {\n  background-size: 16px;\n  background-position-y: center;\n  width: 16px;\n  height: 16px;\n}\n.sort-asc .x-grid3-sort-icon {\n  background-image: url(" + escape(__webpack_require__(1643)) + ");\n}\n.sort-desc .x-grid3-sort-icon {\n  background-image: url(" + escape(__webpack_require__(1644)) + ");\n}\n.xg-hmenu-sort-asc .x-menu-item-icon {\n  background-image: url(" + escape(__webpack_require__(1645)) + ");\n}\n.xg-hmenu-sort-desc .x-menu-item-icon {\n  background-image: url(" + escape(__webpack_require__(1646)) + ");\n}\n.x-grid3-row-selected {\n  background-color: #dbecf4 !important;\n  border-color: #dbecf4;\n}\n/* DATEPICKER */\n.x-date-middle,\n.x-date-left,\n.x-date-right {\n  background-image: none;\n  background-color: #f2f2f2;\n}\n.x-date-middle .x-btn .x-btn-text {\n  color: #000;\n}\n.x-date-left a {\n  background-image: url(" + escape(__webpack_require__(389)) + ");\n  background-size: 18px;\n}\n.x-date-right a {\n  background-image: url(" + escape(__webpack_require__(221)) + ");\n  background-size: 18px;\n}\n.x-date-inner th {\n  height: 30px;\n  background-color: #2196f3;\n  background-image: none;\n  border: none;\n  color: #FFF;\n}\n.x-date-middle .x-btn-mc em.x-btn-arrow {\n  background-image: url(" + escape(__webpack_require__(143)) + ");\n  background-size: 12px;\n  background-position-y: center;\n}\n.x-date-middle .x-btn-mc em.x-btn-arrow button {\n  margin-right: 2px;\n  border-right: 1px solid transparent;\n}\n.x-date-middle .x-btn-mc em.x-btn-arrow button:hover {\n  border-right: 1px dotted;\n}\ntd.x-date-mp-sel a,\n.x-date-inner .x-date-selected a {\n  background-image: none;\n  background-color: #66ccff;\n}\n.x-date-mp-btns,\n.x-date-bottom {\n  background-image: none;\n  background-color: #f2f2f2;\n}\n.x-date-mp-btns button {\n  color: #000;\n  background-color: #d9d9d9;\n  border: none;\n}\n/* WINDOW */\n.x-window-tl,\n.x-window-tc,\n.x-window-tr,\n.x-window-ml,\n.x-window-mc,\n.x-window-mr,\n.x-window-bl,\n.x-window-bc,\n.x-window-br,\n.x-window-body,\n.x-window-plain .x-window-body {\n  background-image: none !important;\n  background-color: #c0ced8 !important;\n  border: none !important;\n}\n.ext-mb-content + .x-progress-wrap {\n  border: none;\n}\n.ext-mb-content + .x-progress-wrap .x-progress-bar {\n  background-image: none;\n  background-color: #0062a7;\n  border: none;\n}\n.ext-mb-content + .x-progress-wrap .x-progress-inner {\n  background-color: #fff;\n  background-image: none;\n  height: 20px;\n}\n.x-window-dlg .ext-mb-info {\n  background-image: url(" + escape(__webpack_require__(635)) + ");\n  background-size: 35px;\n}\n.x-window-dlg .ext-mb-question {\n  background-image: url(" + escape(__webpack_require__(636)) + ");\n  background-size: 35px;\n}\n.x-window-dlg .ext-mb-warning,\n.x-window-dlg .ext-mb-error {\n  background-image: url(" + escape(__webpack_require__(637)) + ");\n  background-size: 35px;\n}\n.x-progress-bar {\n  background-image: none;\n  border-top-color: #9cbfee;\n  border-bottom-color: #9cbfee;\n}\n.x-progress-inner {\n  background-image: none;\n}\n.x-window {\n  box-shadow: 10px 10px 15px silver;\n}\n.x-window .x-tool {\n  background-size: 13px 13px;\n  background-position: 1px 1px !important;\n}\n.x-window .x-tool:hover {\n  background-size: 15px 15px !important;\n  background-position: 0 0 !important;\n}\n.x-window .x-tool-close {\n  background-image: url(" + escape(__webpack_require__(227)) + ") !important;\n}\n.x-window-tl .x-window-header {\n  color: black;\n}\n.x-tool {\n  background-size: 13px 13px;\n  background-position: 1px 1px !important;\n  background-image: url(" + escape(__webpack_require__(545)) + ");\n}\n.x-tool:hover {\n  background-size: 15px 15px !important;\n  background-position: 0 0 !important;\n}\n.x-panel-collapsed .x-tool {\n  background-image: url(" + escape(__webpack_require__(143)) + ");\n}\n/* TIPS */\n.x-tip {\n  box-shadow: 10px 10px 15px silver;\n}\n.x-tip .x-tip-tc,\n.x-tip .x-tip-tl,\n.x-tip .x-tip-tr,\n.x-tip .x-tip-bc,\n.x-tip .x-tip-bl,\n.x-tip .x-tip-br,\n.x-tip .x-tip-ml,\n.x-tip .x-tip-mr {\n  background-image: none;\n  background-color: #163047;\n}\n.x-tip .x-tip-header-text {\n  text-decoration: underline;\n  font-style: italic;\n  color: #fff;\n  font-weight: bold;\n}\n.x-tip .x-tip-body {\n  color: #fff;\n  font-weight: bold;\n}\n.x-tip .x-tip-body b {\n  text-decoration: underline;\n  font-style: italic;\n}\n.x-tip .x-tip-bl.x-panel-nofooter {\n  height: 5px;\n}\n/* MENU */\n.x-menu-list {\n  padding: 0;\n  background-color: #f2f2f2;\n}\n.x-menu-floating {\n  border: none;\n}\n.x-menu-item-active {\n  background-image: none;\n  background-color: #d9d9d9;\n  border-color: #d9d9d9;\n  border-style: none;\n  border-left: 2px solid #a6a6a6;\n  margin: 0;\n  padding: 1px;\n}\n/* COMBOBOX */\n.x-combo-list {\n  background-color: #f2f2f2;\n}\n.x-combo-list .x-combo-selected {\n  background-color: #d9d9d9;\n}\n.x-combo-list .x-combo-list-inner {\n  border-color: black;\n}\n/* TREE */\n.x-tree-node .x-tree-selected {\n  background-color: #dbecf4;\n}\n.x-tree-arrows .x-tree-elbow-minus,\n.x-tree-arrows .x-tree-elbow-plus,\n.x-tree-arrows .x-tree-elbow-end-minus,\n.x-tree-arrows .x-tree-elbow-end-plus {\n  background-position: 3px 3px;\n  background-size: 12px;\n}\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-minus,\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-plus,\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-end-minus,\n.x-tree-arrows .x-tree-ec-over .x-tree-elbow-end-plus {\n  background-position: 2px 2px;\n  background-size: 14px;\n}\n.x-tree-arrows .x-tree-elbow-minus,\n.x-tree-arrows .x-tree-elbow-end-minus {\n  background-image: url(" + escape(__webpack_require__(650)) + ");\n}\n.x-tree-arrows .x-tree-elbow-plus,\n.x-tree-arrows .x-tree-elbow-end-plus {\n  background-image: url(" + escape(__webpack_require__(221)) + ");\n}\n/* ARROW COLLAPSE */\n.ux-arrowcollapse .x-tool-toggle {\n  background-image: url(" + escape(__webpack_require__(650)) + ");\n  background-position: 2px 2px !important;\n  background-size: 12px;\n}\n.x-panel-collapsed .ux-arrowcollapse-header .x-tool-toggle {\n  background-image: url(" + escape(__webpack_require__(221)) + ");\n}\n.ux-arrowcollapse-header .x-tool-toggle-over {\n  background-size: 14px;\n}\n/* ACCORDION */\n.x-panel-collapsed .x-accordion-hd .x-tool-toggle {\n  background-image: url(" + escape(__webpack_require__(1647)) + ");\n  background-position: 1px 1px;\n  background-size: 14px;\n}\n.x-accordion-hd .x-tool-toggle {\n  background-image: url(" + escape(__webpack_require__(1648)) + ");\n  background-position: 1px 1px;\n  background-size: 14px;\n}\n.x-accordion-hd .x-tool-toggle-over {\n  background-position: 0 1px !important;\n  background-size: 16px !important;\n}\n", ""]);

// exports


/***/ }),
/* 1638 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links_1_' d='M 35.5 21.2 C 35.5 21 35.4 20.7 35.2 20.5 L 22 7.3 C 21.8 7.1 21.6 7 21.4 7 C 21.2 7 20.9 7.1 20.7 7.3 L 19.3 8.7 C 19.1 8.9 19 9.1 19 9.4 C 19 9.6 19.1 9.9 19.3 10.1 L 30.5 21.3 L 19.3 32.3 C 19.1 32.5 19 32.7 19 33 C 19 33.2 19.1 33.5 19.3 33.7 L 20.7 35.1 C 20.9 35.3 21.1 35.4 21.4 35.4 C 21.7 35.4 21.9 35.3 22.1 35.1 L 35.3 21.9 C 35.4 21.6 35.5 21.4 35.5 21.2 Z'/%3E %3Cpath id='path-1' d='M 23.608 21.038 C 23.608 20.838 23.508 20.538 23.308 20.338 L 10.108 7.138 C 9.908 6.938 9.708 6.838 9.508 6.838 C 9.308 6.838 9.008 6.938 8.808 7.138 L 7.408 8.538 C 7.208 8.738 7.108 8.938 7.108 9.238 C 7.108 9.438 7.208 9.738 7.408 9.938 L 18.608 21.138 L 7.408 32.138 C 7.208 32.338 7.108 32.538 7.108 32.838 C 7.108 33.038 7.208 33.338 7.408 33.538 L 8.808 34.938 C 9.008 35.138 9.208 35.238 9.508 35.238 C 9.808 35.238 10.008 35.138 10.208 34.938 L 23.408 21.738 C 23.508 21.438 23.608 21.238 23.608 21.038 Z'/%3E %3C/svg%3E\""

/***/ }),
/* 1639 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M35.4,14.7V7.8c0-0.4-0.3-0.7-0.7-0.7H28h-1.4H7.8c-0.4,0-0.7,0.3-0.7,0.7v27c0,0.4,0.3,0.7,0.7,0.7h27 c0.4,0,0.7-0.3,0.7-0.7V16.5L35.4,14.7L35.4,14.7z M10.4,10.5h21.7v21.6H10.4V10.5z'/%3E %3C/svg%3E\""

/***/ }),
/* 1640 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cg%3E %3Cpath d='M40.2,12.4L37.8,10c-0.3-0.3-0.7-0.3-1,0L24.2,22.6l-4.5-4.5c-0.3-0.3-0.7-0.3-1,0l-2.5,2.5c-0.1,0.1-0.2,0.3-0.2,0.5 c0,0.2,0.1,0.4,0.2,0.5l7.4,7.4c0.1,0.1,0.3,0.2,0.5,0.2c0.2,0,0.3-0.1,0.5-0.2l15.6-15.5c0.1-0.1,0.2-0.3,0.2-0.5 C40.4,12.7,40.4,12.6,40.2,12.4z'/%3E %3Cpath d='M32,32H10.5V10.5h22l2.9-2.7c0-0.4-0.3-0.7-0.7-0.7h-27c-0.4,0-0.7,0.3-0.7,0.7v27c0,0.4,0.3,0.7,0.7,0.7h27 c0.4,0,0.7-0.3,0.7-0.7V21.9L32,25.5L32,32L32,32z'/%3E %3C/g%3E %3C/svg%3E\""

/***/ }),
/* 1641 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath id='Pfeil_links_2_' d='M 21.2 1 C 21 1 20.7 1.1 20.5 1.3 L 7.3 14.5 C 7.1 14.7 7 14.9 7 15.2 C 7 15.4 7.1 15.7 7.3 15.9 L 8.7 17.3 C 8.9 17.5 9.1 17.6 9.4 17.6 C 9.6 17.6 9.9 17.5 10.1 17.3 L 21.3 6.1 L 32.5 17.3 C 32.7 17.5 32.9 17.6 33.2 17.6 C 33.5 17.6 33.7 17.5 33.9 17.3 L 35.3 15.9 C 35.5 15.7 35.6 15.5 35.6 15.2 C 35.6 15 35.5 14.7 35.3 14.5 L 21.8 1.3 C 21.6 1.1 21.4 1 21.2 1 Z'/%3E %3Cpath id='Pfeil_links_3_' d='M 21.2 41.5 C 21 41.5 20.7 41.4 20.5 41.2 L 7.3 28 C 7.1 27.8 7 27.6 7 27.4 C 7 27.2 7.1 26.9 7.3 26.7 L 8.7 25.3 C 8.9 25.1 9.1 25 9.4 25 C 9.6 25 9.9 25.1 10.1 25.3 L 21.3 36.5 L 32.5 25.3 C 32.7 25.1 32.9 25 33.2 25 C 33.5 25 33.7 25.1 33.9 25.3 L 35.3 26.7 C 35.5 26.9 35.6 27.1 35.6 27.4 C 35.6 27.7 35.2 27.8 35 28 L 21.8 41.2 C 21.6 41.4 21.4 41.5 21.2 41.5 Z'/%3E %3C/svg%3E\""

/***/ }),
/* 1642 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.0.6, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M16.1,20.1c-0.2,0.5-0.2,1-0.2,1.6c0,3,2.4,5.4,5.4,5.4c3,0,5.4-2.4,5.4-5.4s-2.4-5.4-5.4-5.4c-1.4,0-2.7,0.6-3.7,1.5l2.6,3 L16.1,20.1z M16.1,20.1'/%3E %3Cpath d='M41.7,20.8c-0.1-0.1-2.1-2.7-5.7-5.3c-4.7-3.5-9.8-5.3-14.8-5.3c-5,0-10.1,1.8-14.8,5.3c-3.5,2.6-5.6,5.2-5.7,5.3L0,21.7 l0.7,0.9c0.1,0.1,2.1,2.7,5.7,5.3c4.7,3.5,9.8,5.3,14.8,5.3c5,0,10.1-1.8,14.8-5.3c3.5-2.6,5.6-5.2,5.7-5.3l0.7-0.9L41.7,20.8z M21.2,29.8c-4.4,0-8.1-3.6-8.1-8.1c0-0.7,0.1-1.4,0.3-2l-1.8-0.3c-0.2,0.7-0.3,1.5-0.3,2.3c0,2.9,1.2,5.5,3.2,7.3 C12,28,9.8,26.7,8.2,25.6c-2-1.5-3.5-2.9-4.4-3.9c0.9-0.9,2.4-2.4,4.4-3.9c1.6-1.2,3.8-2.5,6.3-3.4l1.2,1.4c1.4-1.3,3.4-2.2,5.5-2.2 c4.4,0,8.1,3.6,8.1,8.1S25.7,29.8,21.2,29.8L21.2,29.8z M34.2,25.6C32.6,26.7,30.5,28,28,29c2-1.8,3.2-4.4,3.2-7.3 c0-2.9-1.2-5.5-3.2-7.3c2.5,0.9,4.7,2.2,6.3,3.4c2,1.5,3.5,2.9,4.4,3.9C37.7,22.6,36.2,24.1,34.2,25.6L34.2,25.6z M34.2,25.6'/%3E %3Cpath d='M34.9,11.4c0,0.1-0.1,0.2-0.1,0.2c-2.4,2.4-6.1,6-10.9,10.8S15.4,30.9,13,33.3L11.3,35c-0.2,0.2-0.4,0.3-0.7,0.2 c-0.2,0-0.8-0.7-2-1.9c-0.2-0.2-0.2-0.4-0.1-0.6C8.6,32.6,32.2,9.2,32.2,9.2c0.2-0.2,0.4-0.3,0.7-0.2c0.1,0,0.2,0.1,0.3,0.2 c0.1,0.1,0.3,0.3,0.5,0.4c0.2,0.2,0.3,0.3,0.5,0.5s0.3,0.3,0.5,0.5c0.2,0.2,0.3,0.3,0.3,0.3C35,11,35,11.2,34.9,11.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1643 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath d='M 28 7 C 27.7 7 27.5 7.1 27.3 7.3 L 22.1 12.5 C 21.9 12.7 21.8 12.9 21.8 13.2 C 21.8 13.5 21.9 13.7 22.1 13.9 L 22.7 14.5 C 22.9 14.7 23.1 14.8 23.4 14.8 C 23.7 14.8 23.9 14.7 24.1 14.5 L 26.4 12.2 L 26.4 34.2 C 26.4 34.5 26.5 34.7 26.7 34.9 C 26.9 35.1 27.1 35.2 27.4 35.2 L 28.4 35.2 C 28.7 35.2 28.9 35.1 29.1 34.9 C 29.3 34.7 29.4 34.5 29.4 34.2 L 29.4 12.2 L 31.7 14.5 C 31.9 14.7 32.1 14.8 32.4 14.8 C 32.7 14.8 32.9 14.7 33.1 14.5 L 33.7 13.9 C 33.9 13.7 34 13.5 34 13.2 C 34 12.9 33.9 12.7 33.7 12.5 L 28.5 7.3 C 28.6 7.1 28.3 7 28 7 Z'/%3E %3C/svg%3E\""

/***/ }),
/* 1644 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28,35.2c-0.3,0-0.5-0.1-0.7-0.3l-5.2-5.2c-0.2-0.2-0.3-0.4-0.3-0.7c0-0.3,0.1-0.5,0.3-0.7l0.6-0.6c0.2-0.2,0.4-0.3,0.7-0.3 s0.5,0.1,0.7,0.3l2.3,2.3V8c0-0.3,0.1-0.5,0.3-0.7c0.2-0.2,0.4-0.3,0.7-0.3h1c0.3,0,0.5,0.1,0.7,0.3c0.2,0.2,0.3,0.4,0.3,0.7v22 l2.3-2.3c0.2-0.2,0.4-0.3,0.7-0.3c0.3,0,0.5,0.1,0.7,0.3l0.6,0.6c0.2,0.2,0.3,0.4,0.3,0.7c0,0.3-0.1,0.5-0.3,0.7l-5.2,5.2 C28.6,35.1,28.3,35.2,28,35.2z'/%3E %3C/svg%3E\""

/***/ }),
/* 1645 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3Csvg version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xmlns='http://www.w3.org/2000/svg' width='42.5' height='42.5'%3E %3Cpath d='M16.3,17.4h-3.6l-0.6,2.4H9.3l4-12.9h2.5l4,12.9h-2.8L16.3,17.4z M13.3,15h2.3l-1.2-4.5L13.3,15z'/%3E %3Cpath d='M13,32.9h6.7v2.4H9.2v-1.6l6.3-8.8H9.3v-2.4h10.5V24L13,32.9z'/%3E %3Cpath d='M 29 7 C 28.7 7 28.5 7.1 28.3 7.3 L 23.1 12.5 C 22.9 12.7 22.8 12.9 22.8 13.2 C 22.8 13.5 22.9 13.7 23.1 13.9 L 23.7 14.5 C 23.9 14.7 24.1 14.8 24.4 14.8 C 24.7 14.8 24.9 14.7 25.1 14.5 L 27.4 12.2 L 27.4 34.2 C 27.4 34.5 27.5 34.7 27.7 34.9 C 27.9 35.1 28.1 35.2 28.4 35.2 L 29.4 35.2 C 29.7 35.2 29.9 35.1 30.1 34.9 C 30.3 34.7 30.4 34.5 30.4 34.2 L 30.4 12.2 L 32.7 14.5 C 32.9 14.7 33.1 14.8 33.4 14.8 C 33.7 14.8 33.9 14.7 34.1 14.5 L 34.7 13.9 C 34.9 13.7 35 13.5 35 13.2 C 35 12.9 34.9 12.7 34.7 12.5 L 29.5 7.3 C 29.6 7.1 29.3 7 29 7 Z'/%3E %3C/svg%3E\""

/***/ }),
/* 1646 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 25.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M28,35.2c-0.3,0-0.5-0.1-0.7-0.3l-5.2-5.2c-0.2-0.2-0.3-0.4-0.3-0.7c0-0.3,0.1-0.5,0.3-0.7l0.6-0.6c0.2-0.2,0.4-0.3,0.7-0.3 s0.5,0.1,0.7,0.3l2.3,2.3V8c0-0.3,0.1-0.5,0.3-0.7c0.2-0.2,0.4-0.3,0.7-0.3h1c0.3,0,0.5,0.1,0.7,0.3c0.2,0.2,0.3,0.4,0.3,0.7v22 l2.3-2.3c0.2-0.2,0.4-0.3,0.7-0.3c0.3,0,0.5,0.1,0.7,0.3l0.6,0.6c0.2,0.2,0.3,0.4,0.3,0.7c0,0.3-0.1,0.5-0.3,0.7l-5.2,5.2 C28.6,35.1,28.3,35.2,28,35.2z'/%3E %3Cpath d='M16.3,32.8h-3.6l-0.6,2.4H9.3l4-12.9h2.5l4,12.9H17L16.3,32.8z M13.4,30.4h2.3L14.5,26L13.4,30.4z'/%3E %3Cpath d='M13,17.4h6.7v2.4H9.2v-1.6l6.3-8.8H9.3V6.9h10.5v1.6L13,17.4z'/%3E %3C/svg%3E\""

/***/ }),
/* 1647 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.1.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M21.7,30.8h-1.4c-0.2,0-0.4-0.1-0.5-0.2s-0.2-0.3-0.2-0.5v-7.7h-7.7c-0.2,0-0.4-0.1-0.5-0.2s-0.2-0.3-0.2-0.5v-1.4 c0-0.2,0.1-0.4,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h7.7v-7.7c0-0.2,0.1-0.4,0.2-0.5s0.3-0.2,0.5-0.2h1.4c0.2,0,0.4,0.1,0.5,0.2 c0.1,0.1,0.2,0.3,0.2,0.5v7.7h7.7c0.2,0,0.4,0.1,0.5,0.2s0.2,0.3,0.2,0.5v1.4c0,0.2-0.1,0.4-0.2,0.5s-0.3,0.2-0.5,0.2h-7.7v7.7 c0,0.2-0.1,0.4-0.2,0.5S21.9,30.8,21.7,30.8z'/%3E %3C/svg%3E\""

/***/ }),
/* 1648 */
/***/ (function(module, exports) {

module.exports = "\"data:image/svg+xml,%3C?xml version='1.0' encoding='utf-8'?%3E %3C!-- Generator: Adobe Illustrator 23.1.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --%3E %3Csvg version='1.1' id='Ebene_1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' x='0px' y='0px' viewBox='0 0 42.5 42.5' style='enable-background:new 0 0 42.5 42.5;' xml:space='preserve' width='42.5' height='42.5'%3E %3Cpath d='M19.6,22.4h-7.7c-0.2,0-0.4-0.1-0.5-0.2s-0.2-0.3-0.2-0.5v-1.4c0-0.2,0.1-0.4,0.2-0.5c0.1-0.1,0.3-0.2,0.5-0.2h7.7h10.5 c0.2,0,0.4,0.1,0.5,0.2s0.2,0.3,0.2,0.5v1.4c0,0.2-0.1,0.4-0.2,0.5s-0.3,0.2-0.5,0.2H19.6z'/%3E %3C/svg%3E\""

/***/ }),
/* 1649 */
/***/ (function(module, exports, __webpack_require__) {



//
// Generated on Tue Dec 16 2014 12:13:47 GMT+0100 (CET) by Charlie Robbins, Paolo Fragomeni & the Contributors (Using Codesurgeon).
// Version 1.2.6
//

(function (exports) {

/*
 * browser.js: Browser specific functionality for director.
 *
 * (C) 2011, Charlie Robbins, Paolo Fragomeni, & the Contributors.
 * MIT LICENSE
 *
 */

var dloc = document.location;

function dlocHashEmpty() {
  // Non-IE browsers return '' when the address bar shows '#'; Director's logic
  // assumes both mean empty.
  return dloc.hash === '' || dloc.hash === '#';
}

var listener = {
  mode: 'modern',
  hash: dloc.hash,
  history: false,

  check: function () {
    var h = dloc.hash;
    if (h != this.hash) {
      this.hash = h;
      this.onHashChanged();
    }
  },

  fire: function () {
    if (this.mode === 'modern') {
      this.history === true ? window.onpopstate() : window.onhashchange();
    }
    else {
      this.onHashChanged();
    }
  },

  init: function (fn, history) {
    var self = this;
    this.history = history;

    if (!Router.listeners) {
      Router.listeners = [];
    }

    function onchange(onChangeEvent) {
      for (var i = 0, l = Router.listeners.length; i < l; i++) {
        Router.listeners[i](onChangeEvent);
      }
    }

    //note IE8 is being counted as 'modern' because it has the hashchange event
    if ('onhashchange' in window && (document.documentMode === undefined
      || document.documentMode > 7)) {
      // At least for now HTML5 history is available for 'modern' browsers only
      if (this.history === true) {
        // There is an old bug in Chrome that causes onpopstate to fire even
        // upon initial page load. Since the handler is run manually in init(),
        // this would cause Chrome to run it twise. Currently the only
        // workaround seems to be to set the handler after the initial page load
        // http://code.google.com/p/chromium/issues/detail?id=63040
        setTimeout(function() {
          window.onpopstate = onchange;
        }, 500);
      }
      else {
        window.onhashchange = onchange;
      }
      this.mode = 'modern';
    }
    else {
      //
      // IE support, based on a concept by Erik Arvidson ...
      //
      var frame = document.createElement('iframe');
      frame.id = 'state-frame';
      frame.style.display = 'none';
      document.body.appendChild(frame);
      this.writeFrame('');

      if ('onpropertychange' in document && 'attachEvent' in document) {
        document.attachEvent('onpropertychange', function () {
          if (event.propertyName === 'location') {
            self.check();
          }
        });
      }

      window.setInterval(function () { self.check(); }, 50);

      this.onHashChanged = onchange;
      this.mode = 'legacy';
    }

    Router.listeners.push(fn);

    return this.mode;
  },

  destroy: function (fn) {
    if (!Router || !Router.listeners) {
      return;
    }

    var listeners = Router.listeners;

    for (var i = listeners.length - 1; i >= 0; i--) {
      if (listeners[i] === fn) {
        listeners.splice(i, 1);
      }
    }
  },

  setHash: function (s) {
    // Mozilla always adds an entry to the history
    if (this.mode === 'legacy') {
      this.writeFrame(s);
    }

    if (this.history === true) {
      window.history.pushState({}, document.title, s);
      // Fire an onpopstate event manually since pushing does not obviously
      // trigger the pop event.
      this.fire();
    } else {
      dloc.hash = (s[0] === '/') ? s : '/' + s;
    }
    return this;
  },

  writeFrame: function (s) {
    // IE support...
    var f = document.getElementById('state-frame');
    var d = f.contentDocument || f.contentWindow.document;
    d.open();
    d.write("<script>_hash = '" + s + "'; onload = parent.listener.syncHash;<script>");
    d.close();
  },

  syncHash: function () {
    // IE support...
    var s = this._hash;
    if (s != dloc.hash) {
      dloc.hash = s;
    }
    return this;
  },

  onHashChanged: function () {}
};

var Router = exports.Router = function (routes) {
  if (!(this instanceof Router)) return new Router(routes);

  this.params   = {};
  this.routes   = {};
  this.methods  = ['on', 'once', 'after', 'before'];
  this.scope    = [];
  this._methods = {};

  this._insert = this.insert;
  this.insert = this.insertEx;

  this.historySupport = (window.history != null ? window.history.pushState : null) != null

  this.configure();
  this.mount(routes || {});
};

Router.prototype.init = function (r) {
  var self = this
    , routeTo;
  this.handler = function(onChangeEvent) {
    var newURL = onChangeEvent && onChangeEvent.newURL || window.location.hash;
    var url = self.history === true ? self.getPath() : newURL.replace(/.*#/, '');
    self.dispatch('on', url.charAt(0) === '/' ? url : '/' + url);
  };

  listener.init(this.handler, this.history);

  if (this.history === false) {
    if (dlocHashEmpty() && r) {
      dloc.hash = r;
    } else if (!dlocHashEmpty()) {
      self.dispatch('on', '/' + dloc.hash.replace(/^(#\/|#|\/)/, ''));
    }
  }
  else {
    if (this.convert_hash_in_init) {
      // Use hash as route
      routeTo = dlocHashEmpty() && r ? r : !dlocHashEmpty() ? dloc.hash.replace(/^#/, '') : null;
      if (routeTo) {
        window.history.replaceState({}, document.title, routeTo);
      }
    }
    else {
      // Use canonical url
      routeTo = this.getPath();
    }

    // Router has been initialized, but due to the chrome bug it will not
    // yet actually route HTML5 history state changes. Thus, decide if should route.
    if (routeTo || this.run_in_init === true) {
      this.handler();
    }
  }

  return this;
};

Router.prototype.explode = function () {
  var v = this.history === true ? this.getPath() : dloc.hash;
  if (v.charAt(1) === '/') { v=v.slice(1) }
  return v.slice(1, v.length).split("/");
};

Router.prototype.setRoute = function (i, v, val) {
  var url = this.explode();

  if (typeof i === 'number' && typeof v === 'string') {
    url[i] = v;
  }
  else if (typeof val === 'string') {
    url.splice(i, v, s);
  }
  else {
    url = [i];
  }

  listener.setHash(url.join('/'));
  return url;
};

//
// ### function insertEx(method, path, route, parent)
// #### @method {string} Method to insert the specific `route`.
// #### @path {Array} Parsed path to insert the `route` at.
// #### @route {Array|function} Route handlers to insert.
// #### @parent {Object} **Optional** Parent "routes" to insert into.
// insert a callback that will only occur once per the matched route.
//
Router.prototype.insertEx = function(method, path, route, parent) {
  if (method === "once") {
    method = "on";
    route = function(route) {
      var once = false;
      return function() {
        if (once) return;
        once = true;
        return route.apply(this, arguments);
      };
    }(route);
  }
  return this._insert(method, path, route, parent);
};

Router.prototype.getRoute = function (v) {
  var ret = v;

  if (typeof v === "number") {
    ret = this.explode()[v];
  }
  else if (typeof v === "string"){
    var h = this.explode();
    ret = h.indexOf(v);
  }
  else {
    ret = this.explode();
  }

  return ret;
};

Router.prototype.destroy = function () {
  listener.destroy(this.handler);
  return this;
};

Router.prototype.getPath = function () {
  var path = window.location.pathname;
  if (path.substr(0, 1) !== '/') {
    path = '/' + path;
  }
  return path;
};
function _every(arr, iterator) {
  for (var i = 0; i < arr.length; i += 1) {
    if (iterator(arr[i], i, arr) === false) {
      return;
    }
  }
}

function _flatten(arr) {
  var flat = [];
  for (var i = 0, n = arr.length; i < n; i++) {
    flat = flat.concat(arr[i]);
  }
  return flat;
}

function _asyncEverySeries(arr, iterator, callback) {
  if (!arr.length) {
    return callback();
  }
  var completed = 0;
  (function iterate() {
    iterator(arr[completed], function(err) {
      if (err || err === false) {
        callback(err);
        callback = function() {};
      } else {
        completed += 1;
        if (completed === arr.length) {
          callback();
        } else {
          iterate();
        }
      }
    });
  })();
}

function paramifyString(str, params, mod) {
  mod = str;
  for (var param in params) {
    if (params.hasOwnProperty(param)) {
      mod = params[param](str);
      if (mod !== str) {
        break;
      }
    }
  }
  return mod === str ? "([._a-zA-Z0-9-%()]+)" : mod;
}

function regifyString(str, params) {
  var matches, last = 0, out = "";
  while (matches = str.substr(last).match(/[^\w\d\- %@&]*\*[^\w\d\- %@&]*/)) {
    last = matches.index + matches[0].length;
    matches[0] = matches[0].replace(/^\*/, "([_.()!\\ %@&a-zA-Z0-9-]+)");
    out += str.substr(0, matches.index) + matches[0];
  }
  str = out += str.substr(last);
  var captures = str.match(/:([^\/]+)/ig), capture, length;
  if (captures) {
    length = captures.length;
    for (var i = 0; i < length; i++) {
      capture = captures[i];
      if (capture.slice(0, 2) === "::") {
        str = capture.slice(1);
      } else {
        str = str.replace(capture, paramifyString(capture, params));
      }
    }
  }
  return str;
}

function terminator(routes, delimiter, start, stop) {
  var last = 0, left = 0, right = 0, start = (start || "(").toString(), stop = (stop || ")").toString(), i;
  for (i = 0; i < routes.length; i++) {
    var chunk = routes[i];
    if (chunk.indexOf(start, last) > chunk.indexOf(stop, last) || ~chunk.indexOf(start, last) && !~chunk.indexOf(stop, last) || !~chunk.indexOf(start, last) && ~chunk.indexOf(stop, last)) {
      left = chunk.indexOf(start, last);
      right = chunk.indexOf(stop, last);
      if (~left && !~right || !~left && ~right) {
        var tmp = routes.slice(0, (i || 1) + 1).join(delimiter);
        routes = [ tmp ].concat(routes.slice((i || 1) + 1));
      }
      last = (right > left ? right : left) + 1;
      i = 0;
    } else {
      last = 0;
    }
  }
  return routes;
}

var QUERY_SEPARATOR = /\?.*/;

Router.prototype.configure = function(options) {
  options = options || {};
  for (var i = 0; i < this.methods.length; i++) {
    this._methods[this.methods[i]] = true;
  }
  this.recurse = options.recurse || this.recurse || false;
  this.async = options.async || false;
  this.delimiter = options.delimiter || "/";
  this.strict = typeof options.strict === "undefined" ? true : options.strict;
  this.notfound = options.notfound;
  this.resource = options.resource;
  this.history = options.html5history && this.historySupport || false;
  this.run_in_init = this.history === true && options.run_handler_in_init !== false;
  this.convert_hash_in_init = this.history === true && options.convert_hash_in_init !== false;
  this.every = {
    after: options.after || null,
    before: options.before || null,
    on: options.on || null
  };
  return this;
};

Router.prototype.param = function(token, matcher) {
  if (token[0] !== ":") {
    token = ":" + token;
  }
  var compiled = new RegExp(token, "g");
  this.params[token] = function(str) {
    return str.replace(compiled, matcher.source || matcher);
  };
  return this;
};

Router.prototype.on = Router.prototype.route = function(method, path, route) {
  var self = this;
  if (!route && typeof path == "function") {
    route = path;
    path = method;
    method = "on";
  }
  if (Array.isArray(path)) {
    return path.forEach(function(p) {
      self.on(method, p, route);
    });
  }
  if (path.source) {
    path = path.source.replace(/\\\//ig, "/");
  }
  if (Array.isArray(method)) {
    return method.forEach(function(m) {
      self.on(m.toLowerCase(), path, route);
    });
  }
  path = path.split(new RegExp(this.delimiter));
  path = terminator(path, this.delimiter);
  this.insert(method, this.scope.concat(path), route);
};

Router.prototype.path = function(path, routesFn) {
  var self = this, length = this.scope.length;
  if (path.source) {
    path = path.source.replace(/\\\//ig, "/");
  }
  path = path.split(new RegExp(this.delimiter));
  path = terminator(path, this.delimiter);
  this.scope = this.scope.concat(path);
  routesFn.call(this, this);
  this.scope.splice(length, path.length);
};

Router.prototype.dispatch = function(method, path, callback) {
  var self = this, fns = this.traverse(method, path.replace(QUERY_SEPARATOR, ""), this.routes, ""), invoked = this._invoked, after;
  this._invoked = true;
  if (!fns || fns.length === 0) {
    this.last = [];
    if (typeof this.notfound === "function") {
      this.invoke([ this.notfound ], {
        method: method,
        path: path
      }, callback);
    }
    return false;
  }
  if (this.recurse === "forward") {
    fns = fns.reverse();
  }
  function updateAndInvoke() {
    self.last = fns.after;
    self.invoke(self.runlist(fns), self, callback);
  }
  after = this.every && this.every.after ? [ this.every.after ].concat(this.last) : [ this.last ];
  if (after && after.length > 0 && invoked) {
    if (this.async) {
      this.invoke(after, this, updateAndInvoke);
    } else {
      this.invoke(after, this);
      updateAndInvoke();
    }
    return true;
  }
  updateAndInvoke();
  return true;
};

Router.prototype.invoke = function(fns, thisArg, callback) {
  var self = this;
  var apply;
  if (this.async) {
    apply = function(fn, next) {
      if (Array.isArray(fn)) {
        return _asyncEverySeries(fn, apply, next);
      } else if (typeof fn == "function") {
        fn.apply(thisArg, (fns.captures || []).concat(next));
      }
    };
    _asyncEverySeries(fns, apply, function() {
      if (callback) {
        callback.apply(thisArg, arguments);
      }
    });
  } else {
    apply = function(fn) {
      if (Array.isArray(fn)) {
        return _every(fn, apply);
      } else if (typeof fn === "function") {
        return fn.apply(thisArg, fns.captures || []);
      } else if (typeof fn === "string" && self.resource) {
        self.resource[fn].apply(thisArg, fns.captures || []);
      }
    };
    _every(fns, apply);
  }
};

Router.prototype.traverse = function(method, path, routes, regexp, filter) {
  var fns = [], current, exact, match, next, that;
  function filterRoutes(routes) {
    if (!filter) {
      return routes;
    }
    function deepCopy(source) {
      var result = [];
      for (var i = 0; i < source.length; i++) {
        result[i] = Array.isArray(source[i]) ? deepCopy(source[i]) : source[i];
      }
      return result;
    }
    function applyFilter(fns) {
      for (var i = fns.length - 1; i >= 0; i--) {
        if (Array.isArray(fns[i])) {
          applyFilter(fns[i]);
          if (fns[i].length === 0) {
            fns.splice(i, 1);
          }
        } else {
          if (!filter(fns[i])) {
            fns.splice(i, 1);
          }
        }
      }
    }
    var newRoutes = deepCopy(routes);
    newRoutes.matched = routes.matched;
    newRoutes.captures = routes.captures;
    newRoutes.after = routes.after.filter(filter);
    applyFilter(newRoutes);
    return newRoutes;
  }
  if (path === this.delimiter && routes[method]) {
    next = [ [ routes.before, routes[method] ].filter(Boolean) ];
    next.after = [ routes.after ].filter(Boolean);
    next.matched = true;
    next.captures = [];
    return filterRoutes(next);
  }
  for (var r in routes) {
    if (routes.hasOwnProperty(r) && (!this._methods[r] || this._methods[r] && typeof routes[r] === "object" && !Array.isArray(routes[r]))) {
      current = exact = regexp + this.delimiter + r;
      if (!this.strict) {
        exact += "[" + this.delimiter + "]?";
      }
      match = path.match(new RegExp("^" + exact));
      if (!match) {
        continue;
      }
      if (match[0] && match[0] == path && routes[r][method]) {
        next = [ [ routes[r].before, routes[r][method] ].filter(Boolean) ];
        next.after = [ routes[r].after ].filter(Boolean);
        next.matched = true;
        next.captures = match.slice(1);
        if (this.recurse && routes === this.routes) {
          next.push([ routes.before, routes.on ].filter(Boolean));
          next.after = next.after.concat([ routes.after ].filter(Boolean));
        }
        return filterRoutes(next);
      }
      next = this.traverse(method, path, routes[r], current);
      if (next.matched) {
        if (next.length > 0) {
          fns = fns.concat(next);
        }
        if (this.recurse) {
          fns.push([ routes[r].before, routes[r].on ].filter(Boolean));
          next.after = next.after.concat([ routes[r].after ].filter(Boolean));
          if (routes === this.routes) {
            fns.push([ routes["before"], routes["on"] ].filter(Boolean));
            next.after = next.after.concat([ routes["after"] ].filter(Boolean));
          }
        }
        fns.matched = true;
        fns.captures = next.captures;
        fns.after = next.after;
        return filterRoutes(fns);
      }
    }
  }
  return false;
};

Router.prototype.insert = function(method, path, route, parent) {
  var methodType, parentType, isArray, nested, part;
  path = path.filter(function(p) {
    return p && p.length > 0;
  });
  parent = parent || this.routes;
  part = path.shift();
  if (/\:|\*/.test(part) && !/\\d|\\w/.test(part)) {
    part = regifyString(part, this.params);
  }
  if (path.length > 0) {
    parent[part] = parent[part] || {};
    return this.insert(method, path, route, parent[part]);
  }
  if (!part && !path.length && parent === this.routes) {
    methodType = typeof parent[method];
    switch (methodType) {
     case "function":
      parent[method] = [ parent[method], route ];
      return;
     case "object":
      parent[method].push(route);
      return;
     case "undefined":
      parent[method] = route;
      return;
    }
    return;
  }
  parentType = typeof parent[part];
  isArray = Array.isArray(parent[part]);
  if (parent[part] && !isArray && parentType == "object") {
    methodType = typeof parent[part][method];
    switch (methodType) {
     case "function":
      parent[part][method] = [ parent[part][method], route ];
      return;
     case "object":
      parent[part][method].push(route);
      return;
     case "undefined":
      parent[part][method] = route;
      return;
    }
  } else if (parentType == "undefined") {
    nested = {};
    nested[method] = route;
    parent[part] = nested;
    return;
  }
  throw new Error("Invalid route context: " + parentType);
};



Router.prototype.extend = function(methods) {
  var self = this, len = methods.length, i;
  function extend(method) {
    self._methods[method] = true;
    self[method] = function() {
      var extra = arguments.length === 1 ? [ method, "" ] : [ method ];
      self.on.apply(self, extra.concat(Array.prototype.slice.call(arguments)));
    };
  }
  for (i = 0; i < len; i++) {
    extend(methods[i]);
  }
};

Router.prototype.runlist = function(fns) {
  var runlist = this.every && this.every.before ? [ this.every.before ].concat(_flatten(fns)) : _flatten(fns);
  if (this.every && this.every.on) {
    runlist.push(this.every.on);
  }
  runlist.captures = fns.captures;
  runlist.source = fns.source;
  return runlist;
};

Router.prototype.mount = function(routes, path) {
  if (!routes || typeof routes !== "object" || Array.isArray(routes)) {
    return;
  }
  var self = this;
  path = path || [];
  if (!Array.isArray(path)) {
    path = path.split(self.delimiter);
  }
  function insertOrMount(route, local) {
    var rename = route, parts = route.split(self.delimiter), routeType = typeof routes[route], isRoute = parts[0] === "" || !self._methods[parts[0]], event = isRoute ? "on" : rename;
    if (isRoute) {
      rename = rename.slice((rename.match(new RegExp("^" + self.delimiter)) || [ "" ])[0].length);
      parts.shift();
    }
    if (isRoute && routeType === "object" && !Array.isArray(routes[route])) {
      local = local.concat(parts);
      self.mount(routes[route], local);
      return;
    }
    if (isRoute) {
      local = local.concat(rename.split(self.delimiter));
      local = terminator(local, self.delimiter);
    }
    self.insert(event, local, routes[route]);
  }
  for (var route in routes) {
    if (routes.hasOwnProperty(route)) {
      insertOrMount(route, path.slice(0));
    }
  }
};



}( true ? exports : undefined));

/***/ }),
/* 1650 */
/***/ (function(module, exports, __webpack_require__) {

Ext.ns('Ext.ux.screenshot');
/**
 *
 * @param {Window} win
 * @param {Object} options
 *      type: 'png',                // png|jpeg|webp(chrome only)
 *      dpi: 300,
 *      download: false,
 *      filename: 'screenshot',     // without extension
 *      grabMouse: false,
 * @return {Promise}
 */

Ext.ux.screenshot.get = function (win, options) {
  var _ = window.lodash; // defaults

  options = _.assign({}, {
    type: 'png',
    dpi: 300,
    download: false,
    filename: 'screenshot',
    grabMouse: false
  }, options);
  return new Promise(function (fulfill, reject) {
    __webpack_require__.e(/* require.ensure | Tinebase/js/html2canvas */ 42).then((function () {
      var html2canvas = __webpack_require__(391);

      html2canvas(win.document.body, {
        grabMouse: options.grabMouse,
        scale: options.dpi / 96
      }).then(function (canvas) {
        var mimeType = 'image/' + options.type,
            dataUrl = canvas.toDataURL(mimeType);

        if (options.download) {
          var downloadLink = document.createElement("a");
          downloadLink.href = dataUrl.replace("image/png", "image/octet-stream");
          downloadLink.download = options.filename + '.' + options.type;
          win.document.body.appendChild(downloadLink);
          downloadLink.click();
          win.document.body.removeChild(downloadLink);
        }

        fulfill(dataUrl);
      });
    }).bind(null, __webpack_require__)).catch(__webpack_require__.oe);
  });
};

Ext.ux.screenshot.ux = function (win, options) {
  // display countdown
  var secondsLeft = Ext.isNumber(options.countdown) ? options.countdown : 3;

  if (secondsLeft) {
    Ext.getBody().mask(String.format('Taking Screenshot in {0} seconds', secondsLeft));
    options.countdown = --secondsLeft;
    return Ext.ux.screenshot.ux.defer(1000, win, [win, options]);
  }

  Ext.getBody().unmask();
  Ext.ux.screenshot.get(win, options);
};

/***/ }),
/* 1651 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _ProgressRenderer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1652);
/* harmony import */ var _ProgressRenderer__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_ProgressRenderer__WEBPACK_IMPORTED_MODULE_0__);
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Ching En Cheng <c.cheng@metaways.de>
 * @copyright   Copyright (c) 2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */

Ext.ns('Ext.ux.file');
Ext.ux.file.UploadManagementDialog = Ext.extend(Tine.Tinebase.dialog.Dialog, {
  /**
   * Tine.Filemanager.Model.DownloadLink
   */
  record: null,

  /**
   * Filemanager
   */
  app: null,
  windowNamePrefix: 'FilePublishedDialog_',
  layout: 'fit',
  border: false,
  frame: false,
  uploadStore: null,
  buttonAlign: null,

  /**
   * Constructor.
   */
  initComponent: function initComponent() {
    this.app = this.app || Tine.Tinebase.appMgr.get('Filemanager');
    this.totalSize = 0;
    this.window.setTitle(this.app.i18n._('Uploads Monitor'));
    this.postalSubscriptions = [];
    this.postalSubscriptions.push(postal.subscribe({
      channel: "recordchange",
      topic: 'Filemanager.Node.*',
      callback: _.bind(this.onUploadRecordChange, this)
    }));
    this.uploadStore = new Ext.data.ArrayStore({
      sortInfo: {
        field: 'last_upload_time',
        direction: 'ASC'
      },
      fields: [{
        name: 'name'
      }, {
        name: 'size',
        type: 'int'
      }, {
        name: 'status'
      }, {
        name: 'path'
      }, {
        name: 'last_upload_time'
      }]
    });
    this.clearAllUploadsButton = {
      xtype: 'button',
      text: this.app.i18n._('Stop and Clear All Uploads'),
      iconCls: 'action_cancel',
      minWidth: 120,
      scope: this,
      handler: async () => {
        await Tine.Tinebase.uploadManager.resetUploadChannels();
        this.uploadStore.removeAll();
        this.progressBar.show();
        this.progressBar.update(Tine.ux.file.ProgressRenderer(0, 0,
        /*use SoftQuota*/
        false));
      }
    };
    this.byUserGrid = new Ext.grid.GridPanel({
      store: this.uploadStore,
      flex: 1,
      columns: [{
        id: 'name',
        header: 'Name',
        width: 150,
        sortable: true,
        dataIndex: 'name',
        renderer: Ext.ux.PercentRendererWithName
      }, {
        id: 'path',
        header: 'Path',
        width: 100,
        sortable: true,
        dataIndex: 'path'
      }, {
        id: 'size',
        header: 'Size',
        width: 70,
        sortable: true,
        dataIndex: 'size',
        renderer: Tine.Tinebase.common.byteRenderer.createDelegate(this, [2, undefined], 3)
      }, {
        id: 'status',
        header: 'Status',
        width: 70,
        sortable: true,
        dataIndex: 'status'
      }, {
        id: 'last_upload_time',
        header: 'Upload Date',
        width: 150,
        sortable: true,
        dataIndex: 'last_upload_time',
        renderer: Tine.Tinebase.common.dateTimeRenderer
      }],
      stripeRows: true,
      autoExpandColumn: 'name',
      autoExpandMin: 200,
      autoShow: true
    });
    this.byUserGrid.on('render', function (grid) {
      const store = grid.getStore(); // Capture the Store.

      const view = grid.getView(); // Capture the GridView.

      grid.tip = new Ext.ToolTip({
        width: 300,
        target: view.mainBody,
        // The overall target element.
        delegate: '.x-grid3-row',
        // Each grid row causes its own seperate show and hide.
        trackMouse: true,
        // Moving within the row should not hide the tip.
        renderTo: document.body,
        // Render immediately so that tip.body can be
        //  referenced prior to the first show.
        listeners: {
          // Change content dynamically depending on which element
          //  triggered the show.
          beforeshow: function updateTipBody(tip) {
            const rowIndex = view.findRowIndex(tip.triggerElement);
            let path = store.getAt(rowIndex).data.path;
            path = path.startsWith('/') ? path.substring(1) : path;
            path = path.replace(/\//g, '/<br />');
            tip.body.dom.innerHTML = path;
          }
        }
      });
    });
    this.progressBar = new Ext.Component({
      style: {
        marginTop: '3px',
        width: '200px',
        height: '16px'
      }
    });
    this.items = [{
      layout: 'vbox',
      align: 'stretch',
      pack: 'start',
      border: false,
      autoScroll: true,
      items: [this.byUserGrid]
    }];
    this.tbar = [{
      xtype: 'label',
      text: this.app.i18n._('Total Uploads : '),
      minWidth: 150
    }, this.progressBar, '->', this.clearAllUploadsButton];
    this.initButtons();
    Ext.ux.file.UploadManagementDialog.superclass.initComponent.call(this);
  },

  /**
   * init buttons
   */
  initButtons: function initButtons() {
    this.fbar = ['->', {
      text: this.applyButtonText ? this.app.i18n._hidden(this.applyButtonText) : i18n._('Ok'),
      minWidth: 100,
      ref: '../buttonApply',
      scope: this,
      handler: this.onButtonApply,
      iconCls: 'action_saveAndClose'
    }];
  },
  afterRender: async function afterRender() {
    this.supr().afterRender.call(this);
    await this.loadUploadData();
  },

  async loadUploadData() {
    const tasks = await Tine.Tinebase.uploadManager.getAllFileUploadTasks();

    _.each(tasks, task => {
      let recordData = task.args.nodeData;
      recordData.id = Tine.Tinebase.data.Record.generateUID();
      const record = Tine.Tinebase.data.Record.setFromJson(recordData, Tine.Filemanager.Model.Node);
      record.data.status = task.status;
      record.data.last_upload_time = _.isString(recordData.last_upload_time) ? recordData.last_upload_time : recordData.last_upload_time.toJSON();

      if (record.data.status === 'pending') {
        this.uploadStore.insert(0, [record]);
      } else {
        this.uploadStore.addSorted(record);
      }
    });

    this.updateProgressBar();
  },

  /**
   * get record by data path
   * @param data
   */
  getRecordByData(data) {
    const store = this.uploadStore;
    return _.find(store.data.items, node => {
      return node.get('path') === (data === null || data === void 0 ? void 0 : data.path);
    }) || _.find(store.data.items, node => {
      return (node === null || node === void 0 ? void 0 : node.id) === (data === null || data === void 0 ? void 0 : data.id);
    });
  },

  onUploadRecordChange(recordData, e) {
    if (!this.rendered) {
      return;
    }

    let record = Tine.Tinebase.data.Record.setFromJson(recordData, Tine.Filemanager.Model.Node);

    if (record && Ext.isFunction(record.copy)) {
      if (record.data.type === 'folder') {
        return;
      }

      record.data.status = recordData.status;
      record.data.last_upload_time = recordData.last_upload_time;
      const store = this.uploadStore;

      if (e.topic.match(/\.create/)) {
        store.insert(0, [record]);
      }

      if (e.topic.match(/\.update/)) {
        const existRecord = this.getRecordByData(recordData);
        record.data.id = existRecord.id;
        record.id = existRecord.id;
        const idx = store.indexOfId(existRecord.id);
        store.removeAt(idx);

        if (existRecord.data.status === 'pending' && record.data.status === 'uploading') {
          store.insert(0, [record]);
        } else if (record.data.status === 'failed' || record.data.status === 'complete') {
          store.add([record]);
        } else {
          store.insert(idx, [record]);
        }
      }
    }

    if (record && e.topic.match(/\.delete/)) {
      this.store.remove(record);
    }

    this.updateProgressBar();
  },

  /**
   * update progress bar
   *
   * this monitor can not grab data from uploadManager , unless caculate tasks here
   */
  updateProgressBar: function updateProgressBar() {
    const total = _.sum(_.map(this.uploadStore.data.items, 'data.size'));

    const completedUploads = this.uploadStore.query('status', 'complete');

    let current = _.sum(_.map(completedUploads.items, 'data.size'));

    const uploadingFiles = this.uploadStore.query('status', 'uploading');

    _.each(uploadingFiles.items, upload => {
      const progress = parseInt(_.last(_.split(upload.data.contenttype, ';')).replace('progress=', ''));
      current += upload.data.size * progress / 100;
    });

    this.progressBar.update(Tine.ux.file.ProgressRenderer(current, total,
    /*use SoftQuota*/
    false));
    this.progressBar.show();
  },
  onDestroy: function onDestroy() {
    _.each(this.postalSubscriptions, subscription => {
      subscription.unsubscribe();
    });

    return this.supr().onDestroy.call(this);
  }
});

Ext.ux.file.UploadManagementDialog.openWindow = function (config) {
  var id = 0;
  return Tine.WindowFactory.getWindow({
    width: 400,
    height: 300,
    name: Ext.ux.file.UploadManagementDialog.prototype.windowNamePrefix + id,
    contentPanelConstructor: 'Ext.ux.file.UploadManagementDialog',
    contentPanelConstructorConfig: config
  });
};

/***/ }),
/* 1652 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 * 
 * @package     Ext
 * @subpackage  ux
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Stefanie Stamer <s.stamer@metaways.de>
 * @copyright   Copyright (c) 2007-2017 Metaways Infosystems GmbH (http://www.metaways.de)
 *
 */
Ext.ns('Tine.ux.file');

Tine.ux.file.ProgressRenderer = function (current, total, useSoftQuota) {
  // template singleton
  if (!Tine.ux.file.ProgressRenderer.tpl) {
    Tine.ux.file.ProgressRenderer.tpl = new Ext.XTemplate('<div class="x-progress-wrap PercentRenderer" <tpl if="qtip">ext:qtitle="' + i18n._('Upload progress') + '" qwidth="200" qtip="{qtip}"></tpl>', '<div class="x-progress-inner PercentRenderer">', '<div class="x-progress-bar PercentRenderer {cls}"<tpl if="Ext.isNumber(percent)"> style="width:{percent}%"</tpl>>', '<div class="PercentRendererText PercentRenderer">', '<div>{[Tine.Tinebase.common.byteRenderer(values.current)]} / {[Tine.Tinebase.common.byteRenderer(values.total)]}</div>', '</div>', '</div>', '<div class="x-progress-text x-progress-text-back PercentRenderer">', '<div>&#160;</div>', '</div>', '</div>', '</div>').compile();
  }

  current = parseInt(current);
  total = parseInt(total);
  var data = {
    current: current,
    total: total,
    percent: total ? Math.round(current / total * 100) : null,
    quota: Tine.Tinebase.configManager.get('quota'),
    cls: total ? 'PercentBar-unlimited' : 'ProgressRenderer-below',
    qtip: total ? String.format(i18n._('{0} available (total: {1})'), Tine.Tinebase.common.byteRenderer(total - current), Tine.Tinebase.common.byteRenderer(total)) : ''
  };

  if (data.total && data.current >= data.total) {
    data.cls = "PercentBar-below";
  }

  return Tine.ux.file.ProgressRenderer.tpl.apply(data);
};

/***/ }),
/* 1653 */
/***/ (function(module, exports) {

/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Ching En Cheng <c.cheng@metaways.de>
 * @copyright   Copyright (c) 2021 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase');
/**
 * user profile panel
 *
 * @namespace   Tine.Tinebase
 * @class       Tine.Tinebase.UploadManagerStatusButton
 * @extends     Ext.Button
 * @author      Ching En Cheng <c.cheng@metaways.de>
 */

Tine.Tinebase.UploadManagerStatusButton = Ext.extend(Ext.Button, {
  /**
   * @cfg {boolean} showIcon
   */
  showIcon: true,
  // private config overrides
  iconCls: 'action_upload_idle',

  /**
   * @property {String} status
   */
  status: 'idle',
  initComponent: function initComponent() {
    Tine.Tinebase.UploadManagerStatusButton.superclass.initComponent.call(this);
  },
  handler: function handler() {
    Ext.ux.file.UploadManagementDialog.openWindow();
  },

  uploadActive() {
    this.setIconClass('action_upload_uploading');
  },

  uploadIdle() {
    this.setIconClass('action_upload_idle');
  }

});
Ext.onReady(() => {
  Ext.ux.ItemRegistry.registerItem('Tine.Tinebase.MainMenu', Tine.Tinebase.UploadManagerStatusButton, 55);
});

/***/ }),
/* 1654 */,
/* 1655 */,
/* 1656 */,
/* 1657 */,
/* 1658 */,
/* 1659 */,
/* 1660 */,
/* 1661 */,
/* 1662 */,
/* 1663 */,
/* 1664 */,
/* 1665 */,
/* 1666 */,
/* 1667 */,
/* 1668 */,
/* 1669 */,
/* 1670 */,
/* 1671 */,
/* 1672 */,
/* 1673 */,
/* 1674 */,
/* 1675 */,
/* 1676 */,
/* 1677 */,
/* 1678 */,
/* 1679 */,
/* 1680 */,
/* 1681 */,
/* 1682 */,
/* 1683 */,
/* 1684 */,
/* 1685 */,
/* 1686 */,
/* 1687 */,
/* 1688 */,
/* 1689 */,
/* 1690 */,
/* 1691 */,
/* 1692 */,
/* 1693 */,
/* 1694 */,
/* 1695 */,
/* 1696 */,
/* 1697 */,
/* 1698 */,
/* 1699 */,
/* 1700 */,
/* 1701 */,
/* 1702 */,
/* 1703 */,
/* 1704 */,
/* 1705 */,
/* 1706 */,
/* 1707 */,
/* 1708 */,
/* 1709 */,
/* 1710 */,
/* 1711 */,
/* 1712 */,
/* 1713 */,
/* 1714 */,
/* 1715 */,
/* 1716 */,
/* 1717 */,
/* 1718 */,
/* 1719 */,
/* 1720 */,
/* 1721 */,
/* 1722 */,
/* 1723 */,
/* 1724 */,
/* 1725 */,
/* 1726 */,
/* 1727 */,
/* 1728 */,
/* 1729 */,
/* 1730 */,
/* 1731 */,
/* 1732 */,
/* 1733 */,
/* 1734 */,
/* 1735 */,
/* 1736 */,
/* 1737 */,
/* 1738 */,
/* 1739 */,
/* 1740 */,
/* 1741 */,
/* 1742 */,
/* 1743 */,
/* 1744 */,
/* 1745 */,
/* 1746 */,
/* 1747 */,
/* 1748 */,
/* 1749 */,
/* 1750 */,
/* 1751 */,
/* 1752 */,
/* 1753 */,
/* 1754 */,
/* 1755 */,
/* 1756 */,
/* 1757 */,
/* 1758 */,
/* 1759 */,
/* 1760 */,
/* 1761 */,
/* 1762 */,
/* 1763 */,
/* 1764 */,
/* 1765 */,
/* 1766 */,
/* 1767 */,
/* 1768 */,
/* 1769 */,
/* 1770 */,
/* 1771 */,
/* 1772 */,
/* 1773 */,
/* 1774 */,
/* 1775 */,
/* 1776 */,
/* 1777 */,
/* 1778 */,
/* 1779 */,
/* 1780 */,
/* 1781 */,
/* 1782 */,
/* 1783 */,
/* 1784 */,
/* 1785 */,
/* 1786 */,
/* 1787 */,
/* 1788 */,
/* 1789 */,
/* 1790 */,
/* 1791 */,
/* 1792 */,
/* 1793 */,
/* 1794 */,
/* 1795 */,
/* 1796 */,
/* 1797 */,
/* 1798 */,
/* 1799 */,
/* 1800 */,
/* 1801 */,
/* 1802 */,
/* 1803 */,
/* 1804 */,
/* 1805 */,
/* 1806 */,
/* 1807 */,
/* 1808 */,
/* 1809 */,
/* 1810 */,
/* 1811 */,
/* 1812 */,
/* 1813 */,
/* 1814 */,
/* 1815 */,
/* 1816 */,
/* 1817 */,
/* 1818 */,
/* 1819 */,
/* 1820 */,
/* 1821 */,
/* 1822 */,
/* 1823 */,
/* 1824 */,
/* 1825 */,
/* 1826 */,
/* 1827 */,
/* 1828 */,
/* 1829 */,
/* 1830 */,
/* 1831 */,
/* 1832 */,
/* 1833 */,
/* 1834 */,
/* 1835 */,
/* 1836 */,
/* 1837 */,
/* 1838 */,
/* 1839 */,
/* 1840 */,
/* 1841 */,
/* 1842 */,
/* 1843 */,
/* 1844 */,
/* 1845 */,
/* 1846 */,
/* 1847 */,
/* 1848 */,
/* 1849 */,
/* 1850 */,
/* 1851 */,
/* 1852 */,
/* 1853 */,
/* 1854 */,
/* 1855 */,
/* 1856 */,
/* 1857 */,
/* 1858 */,
/* 1859 */,
/* 1860 */,
/* 1861 */,
/* 1862 */,
/* 1863 */,
/* 1864 */,
/* 1865 */,
/* 1866 */,
/* 1867 */,
/* 1868 */,
/* 1869 */,
/* 1870 */,
/* 1871 */,
/* 1872 */,
/* 1873 */,
/* 1874 */,
/* 1875 */,
/* 1876 */,
/* 1877 */,
/* 1878 */,
/* 1879 */,
/* 1880 */,
/* 1881 */,
/* 1882 */,
/* 1883 */,
/* 1884 */,
/* 1885 */,
/* 1886 */,
/* 1887 */,
/* 1888 */,
/* 1889 */,
/* 1890 */,
/* 1891 */,
/* 1892 */,
/* 1893 */,
/* 1894 */,
/* 1895 */,
/* 1896 */,
/* 1897 */,
/* 1898 */,
/* 1899 */,
/* 1900 */,
/* 1901 */,
/* 1902 */,
/* 1903 */,
/* 1904 */,
/* 1905 */,
/* 1906 */,
/* 1907 */,
/* 1908 */,
/* 1909 */,
/* 1910 */,
/* 1911 */,
/* 1912 */,
/* 1913 */,
/* 1914 */,
/* 1915 */,
/* 1916 */,
/* 1917 */,
/* 1918 */,
/* 1919 */,
/* 1920 */,
/* 1921 */,
/* 1922 */,
/* 1923 */,
/* 1924 */,
/* 1925 */,
/* 1926 */,
/* 1927 */,
/* 1928 */,
/* 1929 */,
/* 1930 */,
/* 1931 */,
/* 1932 */,
/* 1933 */,
/* 1934 */,
/* 1935 */,
/* 1936 */,
/* 1937 */,
/* 1938 */,
/* 1939 */,
/* 1940 */,
/* 1941 */,
/* 1942 */,
/* 1943 */,
/* 1944 */,
/* 1945 */,
/* 1946 */,
/* 1947 */,
/* 1948 */,
/* 1949 */,
/* 1950 */,
/* 1951 */,
/* 1952 */,
/* 1953 */,
/* 1954 */,
/* 1955 */,
/* 1956 */,
/* 1957 */,
/* 1958 */,
/* 1959 */,
/* 1960 */,
/* 1961 */,
/* 1962 */,
/* 1963 */,
/* 1964 */,
/* 1965 */,
/* 1966 */,
/* 1967 */,
/* 1968 */,
/* 1969 */,
/* 1970 */,
/* 1971 */,
/* 1972 */,
/* 1973 */,
/* 1974 */,
/* 1975 */,
/* 1976 */,
/* 1977 */,
/* 1978 */,
/* 1979 */,
/* 1980 */,
/* 1981 */,
/* 1982 */,
/* 1983 */,
/* 1984 */,
/* 1985 */,
/* 1986 */,
/* 1987 */,
/* 1988 */,
/* 1989 */,
/* 1990 */,
/* 1991 */,
/* 1992 */,
/* 1993 */,
/* 1994 */,
/* 1995 */,
/* 1996 */,
/* 1997 */,
/* 1998 */,
/* 1999 */,
/* 2000 */,
/* 2001 */,
/* 2002 */,
/* 2003 */,
/* 2004 */,
/* 2005 */,
/* 2006 */,
/* 2007 */,
/* 2008 */,
/* 2009 */,
/* 2010 */,
/* 2011 */,
/* 2012 */,
/* 2013 */,
/* 2014 */,
/* 2015 */,
/* 2016 */,
/* 2017 */,
/* 2018 */,
/* 2019 */,
/* 2020 */,
/* 2021 */,
/* 2022 */,
/* 2023 */,
/* 2024 */,
/* 2025 */,
/* 2026 */,
/* 2027 */,
/* 2028 */,
/* 2029 */,
/* 2030 */,
/* 2031 */,
/* 2032 */,
/* 2033 */,
/* 2034 */,
/* 2035 */,
/* 2036 */,
/* 2037 */,
/* 2038 */,
/* 2039 */,
/* 2040 */,
/* 2041 */,
/* 2042 */,
/* 2043 */,
/* 2044 */,
/* 2045 */,
/* 2046 */,
/* 2047 */,
/* 2048 */,
/* 2049 */,
/* 2050 */,
/* 2051 */,
/* 2052 */,
/* 2053 */,
/* 2054 */,
/* 2055 */,
/* 2056 */,
/* 2057 */,
/* 2058 */,
/* 2059 */,
/* 2060 */,
/* 2061 */,
/* 2062 */,
/* 2063 */,
/* 2064 */,
/* 2065 */,
/* 2066 */,
/* 2067 */,
/* 2068 */,
/* 2069 */,
/* 2070 */,
/* 2071 */,
/* 2072 */,
/* 2073 */,
/* 2074 */,
/* 2075 */,
/* 2076 */,
/* 2077 */,
/* 2078 */,
/* 2079 */,
/* 2080 */,
/* 2081 */,
/* 2082 */,
/* 2083 */,
/* 2084 */,
/* 2085 */,
/* 2086 */,
/* 2087 */,
/* 2088 */,
/* 2089 */,
/* 2090 */,
/* 2091 */,
/* 2092 */,
/* 2093 */,
/* 2094 */,
/* 2095 */,
/* 2096 */,
/* 2097 */,
/* 2098 */,
/* 2099 */,
/* 2100 */,
/* 2101 */,
/* 2102 */,
/* 2103 */,
/* 2104 */,
/* 2105 */,
/* 2106 */,
/* 2107 */,
/* 2108 */,
/* 2109 */,
/* 2110 */,
/* 2111 */,
/* 2112 */,
/* 2113 */,
/* 2114 */,
/* 2115 */,
/* 2116 */,
/* 2117 */,
/* 2118 */,
/* 2119 */,
/* 2120 */,
/* 2121 */,
/* 2122 */,
/* 2123 */,
/* 2124 */,
/* 2125 */,
/* 2126 */,
/* 2127 */,
/* 2128 */,
/* 2129 */,
/* 2130 */,
/* 2131 */,
/* 2132 */,
/* 2133 */,
/* 2134 */,
/* 2135 */,
/* 2136 */,
/* 2137 */,
/* 2138 */,
/* 2139 */,
/* 2140 */,
/* 2141 */,
/* 2142 */,
/* 2143 */,
/* 2144 */,
/* 2145 */,
/* 2146 */,
/* 2147 */,
/* 2148 */,
/* 2149 */,
/* 2150 */,
/* 2151 */,
/* 2152 */,
/* 2153 */,
/* 2154 */,
/* 2155 */,
/* 2156 */,
/* 2157 */,
/* 2158 */,
/* 2159 */,
/* 2160 */,
/* 2161 */,
/* 2162 */,
/* 2163 */,
/* 2164 */,
/* 2165 */,
/* 2166 */,
/* 2167 */,
/* 2168 */,
/* 2169 */,
/* 2170 */,
/* 2171 */,
/* 2172 */,
/* 2173 */,
/* 2174 */,
/* 2175 */,
/* 2176 */,
/* 2177 */,
/* 2178 */,
/* 2179 */,
/* 2180 */,
/* 2181 */,
/* 2182 */,
/* 2183 */,
/* 2184 */,
/* 2185 */,
/* 2186 */,
/* 2187 */,
/* 2188 */,
/* 2189 */,
/* 2190 */,
/* 2191 */,
/* 2192 */,
/* 2193 */,
/* 2194 */,
/* 2195 */,
/* 2196 */,
/* 2197 */,
/* 2198 */,
/* 2199 */,
/* 2200 */,
/* 2201 */,
/* 2202 */,
/* 2203 */,
/* 2204 */,
/* 2205 */,
/* 2206 */,
/* 2207 */,
/* 2208 */,
/* 2209 */,
/* 2210 */,
/* 2211 */,
/* 2212 */,
/* 2213 */,
/* 2214 */,
/* 2215 */,
/* 2216 */,
/* 2217 */,
/* 2218 */,
/* 2219 */,
/* 2220 */,
/* 2221 */,
/* 2222 */,
/* 2223 */,
/* 2224 */,
/* 2225 */,
/* 2226 */,
/* 2227 */,
/* 2228 */,
/* 2229 */,
/* 2230 */,
/* 2231 */,
/* 2232 */,
/* 2233 */,
/* 2234 */,
/* 2235 */,
/* 2236 */,
/* 2237 */,
/* 2238 */,
/* 2239 */,
/* 2240 */,
/* 2241 */,
/* 2242 */,
/* 2243 */,
/* 2244 */,
/* 2245 */,
/* 2246 */,
/* 2247 */,
/* 2248 */,
/* 2249 */,
/* 2250 */,
/* 2251 */,
/* 2252 */,
/* 2253 */,
/* 2254 */,
/* 2255 */,
/* 2256 */,
/* 2257 */,
/* 2258 */,
/* 2259 */,
/* 2260 */,
/* 2261 */,
/* 2262 */,
/* 2263 */,
/* 2264 */,
/* 2265 */,
/* 2266 */,
/* 2267 */,
/* 2268 */,
/* 2269 */,
/* 2270 */,
/* 2271 */,
/* 2272 */,
/* 2273 */,
/* 2274 */,
/* 2275 */,
/* 2276 */,
/* 2277 */,
/* 2278 */,
/* 2279 */,
/* 2280 */,
/* 2281 */,
/* 2282 */,
/* 2283 */,
/* 2284 */,
/* 2285 */,
/* 2286 */,
/* 2287 */,
/* 2288 */,
/* 2289 */,
/* 2290 */,
/* 2291 */,
/* 2292 */,
/* 2293 */,
/* 2294 */,
/* 2295 */,
/* 2296 */,
/* 2297 */,
/* 2298 */,
/* 2299 */,
/* 2300 */,
/* 2301 */,
/* 2302 */,
/* 2303 */,
/* 2304 */,
/* 2305 */,
/* 2306 */,
/* 2307 */,
/* 2308 */,
/* 2309 */,
/* 2310 */,
/* 2311 */,
/* 2312 */,
/* 2313 */,
/* 2314 */,
/* 2315 */,
/* 2316 */,
/* 2317 */,
/* 2318 */,
/* 2319 */,
/* 2320 */,
/* 2321 */,
/* 2322 */,
/* 2323 */,
/* 2324 */,
/* 2325 */,
/* 2326 */,
/* 2327 */,
/* 2328 */,
/* 2329 */,
/* 2330 */,
/* 2331 */,
/* 2332 */,
/* 2333 */,
/* 2334 */,
/* 2335 */,
/* 2336 */,
/* 2337 */,
/* 2338 */,
/* 2339 */,
/* 2340 */,
/* 2341 */,
/* 2342 */,
/* 2343 */,
/* 2344 */,
/* 2345 */,
/* 2346 */,
/* 2347 */,
/* 2348 */,
/* 2349 */,
/* 2350 */,
/* 2351 */,
/* 2352 */,
/* 2353 */,
/* 2354 */,
/* 2355 */,
/* 2356 */,
/* 2357 */,
/* 2358 */,
/* 2359 */,
/* 2360 */,
/* 2361 */,
/* 2362 */,
/* 2363 */,
/* 2364 */,
/* 2365 */,
/* 2366 */,
/* 2367 */,
/* 2368 */,
/* 2369 */,
/* 2370 */,
/* 2371 */,
/* 2372 */,
/* 2373 */,
/* 2374 */,
/* 2375 */,
/* 2376 */,
/* 2377 */,
/* 2378 */,
/* 2379 */,
/* 2380 */,
/* 2381 */,
/* 2382 */,
/* 2383 */,
/* 2384 */,
/* 2385 */,
/* 2386 */,
/* 2387 */,
/* 2388 */,
/* 2389 */,
/* 2390 */,
/* 2391 */,
/* 2392 */,
/* 2393 */,
/* 2394 */,
/* 2395 */,
/* 2396 */,
/* 2397 */,
/* 2398 */,
/* 2399 */,
/* 2400 */,
/* 2401 */,
/* 2402 */,
/* 2403 */,
/* 2404 */,
/* 2405 */,
/* 2406 */,
/* 2407 */,
/* 2408 */,
/* 2409 */,
/* 2410 */,
/* 2411 */,
/* 2412 */,
/* 2413 */,
/* 2414 */,
/* 2415 */,
/* 2416 */,
/* 2417 */,
/* 2418 */,
/* 2419 */,
/* 2420 */,
/* 2421 */,
/* 2422 */,
/* 2423 */,
/* 2424 */,
/* 2425 */,
/* 2426 */,
/* 2427 */,
/* 2428 */,
/* 2429 */,
/* 2430 */,
/* 2431 */,
/* 2432 */,
/* 2433 */,
/* 2434 */,
/* 2435 */,
/* 2436 */,
/* 2437 */,
/* 2438 */,
/* 2439 */,
/* 2440 */,
/* 2441 */,
/* 2442 */,
/* 2443 */,
/* 2444 */,
/* 2445 */,
/* 2446 */,
/* 2447 */,
/* 2448 */,
/* 2449 */,
/* 2450 */,
/* 2451 */,
/* 2452 */,
/* 2453 */,
/* 2454 */,
/* 2455 */,
/* 2456 */,
/* 2457 */,
/* 2458 */,
/* 2459 */,
/* 2460 */,
/* 2461 */,
/* 2462 */,
/* 2463 */,
/* 2464 */,
/* 2465 */,
/* 2466 */,
/* 2467 */,
/* 2468 */,
/* 2469 */,
/* 2470 */,
/* 2471 */,
/* 2472 */,
/* 2473 */,
/* 2474 */,
/* 2475 */,
/* 2476 */,
/* 2477 */,
/* 2478 */,
/* 2479 */,
/* 2480 */,
/* 2481 */,
/* 2482 */,
/* 2483 */,
/* 2484 */,
/* 2485 */,
/* 2486 */,
/* 2487 */,
/* 2488 */,
/* 2489 */,
/* 2490 */,
/* 2491 */,
/* 2492 */,
/* 2493 */,
/* 2494 */,
/* 2495 */,
/* 2496 */,
/* 2497 */,
/* 2498 */,
/* 2499 */,
/* 2500 */,
/* 2501 */,
/* 2502 */,
/* 2503 */,
/* 2504 */,
/* 2505 */,
/* 2506 */,
/* 2507 */,
/* 2508 */,
/* 2509 */,
/* 2510 */,
/* 2511 */,
/* 2512 */,
/* 2513 */,
/* 2514 */,
/* 2515 */,
/* 2516 */,
/* 2517 */,
/* 2518 */,
/* 2519 */,
/* 2520 */,
/* 2521 */,
/* 2522 */,
/* 2523 */,
/* 2524 */,
/* 2525 */,
/* 2526 */,
/* 2527 */,
/* 2528 */,
/* 2529 */,
/* 2530 */,
/* 2531 */,
/* 2532 */,
/* 2533 */,
/* 2534 */,
/* 2535 */,
/* 2536 */,
/* 2537 */,
/* 2538 */,
/* 2539 */,
/* 2540 */,
/* 2541 */,
/* 2542 */,
/* 2543 */,
/* 2544 */,
/* 2545 */,
/* 2546 */,
/* 2547 */,
/* 2548 */,
/* 2549 */,
/* 2550 */,
/* 2551 */,
/* 2552 */,
/* 2553 */,
/* 2554 */,
/* 2555 */,
/* 2556 */,
/* 2557 */,
/* 2558 */,
/* 2559 */,
/* 2560 */,
/* 2561 */,
/* 2562 */,
/* 2563 */,
/* 2564 */,
/* 2565 */,
/* 2566 */,
/* 2567 */,
/* 2568 */,
/* 2569 */,
/* 2570 */,
/* 2571 */,
/* 2572 */,
/* 2573 */,
/* 2574 */,
/* 2575 */,
/* 2576 */,
/* 2577 */,
/* 2578 */,
/* 2579 */,
/* 2580 */,
/* 2581 */,
/* 2582 */,
/* 2583 */,
/* 2584 */,
/* 2585 */,
/* 2586 */,
/* 2587 */,
/* 2588 */,
/* 2589 */,
/* 2590 */,
/* 2591 */,
/* 2592 */,
/* 2593 */,
/* 2594 */,
/* 2595 */,
/* 2596 */,
/* 2597 */,
/* 2598 */,
/* 2599 */,
/* 2600 */,
/* 2601 */,
/* 2602 */,
/* 2603 */,
/* 2604 */,
/* 2605 */,
/* 2606 */,
/* 2607 */,
/* 2608 */,
/* 2609 */,
/* 2610 */,
/* 2611 */,
/* 2612 */,
/* 2613 */,
/* 2614 */,
/* 2615 */,
/* 2616 */,
/* 2617 */,
/* 2618 */,
/* 2619 */,
/* 2620 */,
/* 2621 */,
/* 2622 */,
/* 2623 */,
/* 2624 */,
/* 2625 */,
/* 2626 */,
/* 2627 */,
/* 2628 */,
/* 2629 */,
/* 2630 */,
/* 2631 */,
/* 2632 */,
/* 2633 */,
/* 2634 */,
/* 2635 */,
/* 2636 */,
/* 2637 */,
/* 2638 */,
/* 2639 */,
/* 2640 */,
/* 2641 */,
/* 2642 */,
/* 2643 */,
/* 2644 */,
/* 2645 */,
/* 2646 */,
/* 2647 */,
/* 2648 */,
/* 2649 */,
/* 2650 */,
/* 2651 */,
/* 2652 */,
/* 2653 */,
/* 2654 */,
/* 2655 */,
/* 2656 */,
/* 2657 */,
/* 2658 */,
/* 2659 */,
/* 2660 */,
/* 2661 */,
/* 2662 */,
/* 2663 */,
/* 2664 */,
/* 2665 */,
/* 2666 */,
/* 2667 */,
/* 2668 */,
/* 2669 */,
/* 2670 */,
/* 2671 */,
/* 2672 */,
/* 2673 */,
/* 2674 */,
/* 2675 */,
/* 2676 */,
/* 2677 */,
/* 2678 */,
/* 2679 */,
/* 2680 */,
/* 2681 */,
/* 2682 */,
/* 2683 */,
/* 2684 */,
/* 2685 */,
/* 2686 */,
/* 2687 */,
/* 2688 */,
/* 2689 */,
/* 2690 */,
/* 2691 */,
/* 2692 */,
/* 2693 */,
/* 2694 */,
/* 2695 */,
/* 2696 */,
/* 2697 */,
/* 2698 */,
/* 2699 */,
/* 2700 */,
/* 2701 */,
/* 2702 */,
/* 2703 */,
/* 2704 */,
/* 2705 */,
/* 2706 */,
/* 2707 */,
/* 2708 */,
/* 2709 */,
/* 2710 */,
/* 2711 */,
/* 2712 */,
/* 2713 */,
/* 2714 */,
/* 2715 */,
/* 2716 */,
/* 2717 */,
/* 2718 */,
/* 2719 */,
/* 2720 */,
/* 2721 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXTERNAL MODULE: ./node_modules/pseudo-worker/polyfill.js
var polyfill = __webpack_require__(1159);

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/keys.js
var keys = __webpack_require__(399);
var keys_default = /*#__PURE__*/__webpack_require__.n(keys);

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/define-property.js
var define_property = __webpack_require__(168);
var define_property_default = /*#__PURE__*/__webpack_require__.n(define_property);

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/symbol.js
var symbol = __webpack_require__(1169);
var symbol_default = /*#__PURE__*/__webpack_require__.n(symbol);

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/promise.js
var promise = __webpack_require__(622);
var promise_default = /*#__PURE__*/__webpack_require__.n(promise);

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/event.js

function _defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
} /* eslint class-methods-use-this: ["error", { "exceptMethods": ["getName", "getType"] }] */
/* eslint-env es6 */

class Event {
  constructor() {
    _defineProperty(this, 'store', {});
    _defineProperty(
      this,
      'verifierPattern',
      /^[a-z0-9-_]+:before$|after$|retry$|\*$/
    );
    _defineProperty(this, 'wildcards', ['*', 'error', 'completed']);
    _defineProperty(this, 'emptyFunc', () => {});
    this.store.before = {};
    this.store.after = {};
    this.store.retry = {};
    this.store.wildcard = {};
    this.store.error = this.emptyFunc;
    this.store.completed = this.emptyFunc;
    this.store['*'] = this.emptyFunc;
  }

  /**
   * Create event
   *
   * @param  {String} key
   * @param  {Function} cb
   * @return {void}
   *
   * @api public
   */
  on(key, cb) {
    if (typeof cb !== 'function')
      throw new Error('Event should be an function');
    if (this.isValid(key)) this.add(key, cb);
  }

  /**
   * Run event via it's key
   *
   * @param  {String} key
   * @param  {Any} args
   * @return {void}
   *
   * @api public
   */
  emit(key, args) {
    if (this.wildcards.indexOf(key) > -1) {
      this.wildcard(key, ...[key, args]);
    } else {
      const type = this.getType(key);
      const name = this.getName(key);

      if (this.store[type]) {
        const cb = this.store[type][name] || this.emptyFunc;
        cb.call(null, args);
      }
    }

    this.wildcard('*', key, args);
  }

  /**
   * Run wildcard events
   *
   * @param  {String} key
   * @param  {String} actionKey
   * @param  {Any} args
   * @return {void}
   *
   * @api public
   */
  wildcard(key, actionKey, args) {
    if (this.store.wildcard[key]) {
      this.store.wildcard[key].call(null, actionKey, args);
    }
  }

  /**
   * Add event to store
   *
   * @param  {String} key
   * @param  {Function} cb
   * @return {void}
   *
   * @api public
   */
  add(key, cb) {
    if (this.wildcards.indexOf(key) > -1) {
      this.store.wildcard[key] = cb;
    } else {
      const type = this.getType(key);
      const name = this.getName(key);
      this.store[type][name] = cb;
    }
  }

  /**
   * Check event in store
   *
   * @param  {String} key
   * @return {Boolean}
   *
   * @api public
   */
  has(key) {
    try {
      const keys = key.split(':');
      return keys.length > 1
        ? !!this.store[keys[1]][keys[0]]
        : !!this.store.wildcard[keys[0]];
    } catch (e) {
      return false;
    }
  }

  /**
   * Get event name by parse key
   *
   * @param  {String} key
   * @return {String}
   *
   * @api public
   */
  getName(key) {
    const parsed = key.match(/(.*):.*/);
    return parsed ? parsed[1] : '';
  }

  /**
   * Get event type by parse key
   *
   * @param  {String} key
   * @return {String}
   *
   * @api public
   */
  getType(key) {
    const parsed = key.match(/^[a-z0-9-_]+:(.*)/);
    return parsed ? parsed[1] : '';
  }

  /**
   * Checker of event keys
   *
   * @param  {String} key
   * @return {Boolean}
   *
   * @api public
   */
  isValid(key) {
    return this.verifierPattern.test(key) || this.wildcards.indexOf(key) > -1;
  }
}

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/parse-int.js
var parse_int = __webpack_require__(1202);
var parse_int_default = /*#__PURE__*/__webpack_require__.n(parse_int);

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/date/now.js
var now = __webpack_require__(1207);
var now_default = /*#__PURE__*/__webpack_require__.n(now);

// EXTERNAL MODULE: ./node_modules/group-by/index.js
var group_by = __webpack_require__(1210);
var group_by_default = /*#__PURE__*/__webpack_require__.n(group_by);

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/adapters/inmemory.js

function inmemory_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}

class InMemoryAdapter {
  constructor(config) {
    inmemory_defineProperty(this, 'config', void 0);
    inmemory_defineProperty(this, 'prefix', void 0);
    inmemory_defineProperty(this, 'store', {});
    this.config = config;
    this.prefix = this.config.get('prefix');
  }

  /**
   * Take item from store by key
   *
   * @param  {String} key
   * @return {Promise<ITask>} (array)
   *
   * @api public
   */
  async get(name) {
    const collName = this.storageName(name);
    return [...this.getCollection(collName)];
  }

  /**
   * Add item to store
   *
   * @param  {String} key
   * @param  {String} value
   * @return {Promise<Any>}
   *
   * @api public
   */
  async set(key, value) {
    this.store[this.storageName(key)] = [...value];
    return value;
  }

  /**
   * Item checker in store
   *
   * @param  {String} key
   * @return {Promise<Boolean>}
   *
   * @api public
   */
  async has(key) {
    return Object.prototype.hasOwnProperty.call(
      this.store,
      this.storageName(key)
    );
  }

  /**
   * Remove item
   *
   * @param  {String} key
   * @return {Promise<Any>}
   *
   * @api public
   */
  async clear(key) {
    const result = (await this.has(key))
      ? delete this.store[this.storageName(key)]
      : false;
    this.store = { ...this.store };
    return result;
  }

  /**
   * Compose collection name by suffix
   *
   * @param  {String} suffix
   * @return {String}
   *
   * @api public
   */
  storageName(suffix) {
    return suffix.startsWith(this.getPrefix())
      ? suffix
      : `${this.getPrefix()}_${suffix}`;
  }

  /**
   * Get prefix of channel collection
   *
   * @return {String}
   *
   * @api public
   */
  getPrefix() {
    return this.config.get('prefix');
  }

  /**
   * Get collection
   *
   * @param  {String} name
   * @return {String}
   *
   * @api private
   */
  getCollection(name) {
    const has = Object.prototype.hasOwnProperty.call(this.store, name);
    if (!has) this.store[name] = [];
    return this.store[name];
  }
}

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/json/stringify.js
var stringify = __webpack_require__(1212);
var stringify_default = /*#__PURE__*/__webpack_require__.n(stringify);

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/adapters/localstorage.js


function localstorage_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}

/* global localStorage */

class localstorage_LocalStorageAdapter {
  constructor(config) {
    localstorage_defineProperty(this, 'config', void 0);
    localstorage_defineProperty(this, 'prefix', void 0);
    this.config = config;
    this.prefix = this.config.get('prefix');
  }

  /**
   * Take item from local storage by key
   *
   * @param  {String} key
   * @return {Promise<ITask>} (array)
   *
   * @api public
   */
  async get(name) {
    const result = localStorage.getItem(this.storageName(name));
    return JSON.parse(result) || [];
  }

  /**
   * Add item to local storage
   *
   * @param  {String} key
   * @param  {String} value
   * @return {Promise<Any>}
   *
   * @api public
   */
  async set(key, value) {
    localStorage.setItem(this.storageName(key), stringify_default()(value));
    return value;
  }

  /**
   * Item checker in local storage
   *
   * @param  {String} key
   * @return {Promise<Boolean>}
   *
   * @api public
   */
  async has(key) {
    return Object.prototype.hasOwnProperty.call(
      localStorage,
      this.storageName(key)
    );
  }

  /**
   * Remove item
   *
   * @param  {String} key
   * @return {Promise<Any>}
   *
   * @api public
   */
  async clear(key) {
    const result = (await this.has(key))
      ? delete localStorage[this.storageName(key)]
      : false;
    return result;
  }

  /**
   * Compose collection name by suffix
   *
   * @param  {String} suffix
   * @return {String}
   *
   * @api public
   */
  storageName(suffix) {
    return suffix.startsWith(this.getPrefix())
      ? suffix
      : `${this.getPrefix()}_${suffix}`;
  }

  /**
   * Get prefix of channel collection
   *
   * @return {String}
   *
   * @api public
   */
  getPrefix() {
    return this.config.get('prefix');
  }
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/adapters/index.js





// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/array/is-array.js
var is_array = __webpack_require__(1214);
var is_array_default = /*#__PURE__*/__webpack_require__.n(is_array);

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/utils.js


/* eslint comma-dangle: ["error", "never"] */

/**
 * Check property in object
 *
 * @param  {Object} obj
 * @return {Boolean}
 *
 * @api public
 */
function hasProperty(func, name) {
  return Object.prototype.hasOwnProperty.call(func, name);
}

/**
 * Check method in initiated class
 *
 * @param  {Class} instance
 * @param  {String} method
 * @return {Boolean}
 *
 * @api public
 */
function hasMethod(instance, method) {
  return instance instanceof Object && method in instance;
}

/**
 * Check function type
 *
 * @param  {Function} func
 * @return {Boolean}
 *
 * @api public
 */
function isFunction(func) {
  return func instanceof Function;
}

/**
 * Remove some tasks by some conditions
 *
 * @param  {Function} func
 * @return {Boolean}
 *
 * @api public
 */
function excludeSpecificTasks(task) {
  const conditions = is_array_default()(this) ? this : ['freezed', 'locked'];
  const results = [];

  conditions.forEach((c) => {
    results.push(hasProperty(task, c) === false || task[c] === false);
  });

  return !(results.indexOf(false) > -1);
}

/**
 * Clear tasks by it's tags
 *
 * @param  {ITask} task
 * @return {Boolean}
 *
 * @api public
 */
function utilClearByTag(task) {
  if (!excludeSpecificTasks.call(['locked'], task)) {
    return false;
  }
  return task.tag === this;
}

/**
 * Sort by fifo
 *
 * @param  {ITask} a
 * @param  {ITask} b
 * @return {Any}
 *
 * @api public
 */
function fifo(a, b) {
  return a.createdAt - b.createdAt;
}

/**
 * Sort by lifo
 *
 * @param  {ITask} a
 * @param  {ITask} b
 * @return {Any}
 *
 * @api public
 */
function lifo(a, b) {
  return b.createdAt - a.createdAt;
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/storage-capsule.js








// eslint-disable-next-line no-underscore-dangle
function storage_capsule_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}

/* eslint no-console: ["error", { allow: ["warn", "error"] }] */
/* eslint no-underscore-dangle: [2, { "allow": ["_id"] }] */
/* eslint class-methods-use-this: ["error", { "exceptMethods": ["generateId"] }] */

class storage_capsule_StorageCapsule {
  constructor(config, storage) {
    // eslint-disable-next-line no-void
    storage_capsule_defineProperty(this, 'config', void 0);
    // eslint-disable-next-line no-void
    storage_capsule_defineProperty(this, 'storage', void 0);
    // eslint-disable-next-line no-void
    storage_capsule_defineProperty(this, 'storageChannel', void 0);
    // eslint-disable-next-line no-void
    storage_capsule_defineProperty(this, 'storageJobFifo', void 0);
    this.config = config;
    this.storage = this.initialize(storage);
    this.storageJobFifo = [];
  }

  initialize(Storage) {
    /* eslint no-else-return: off */
    if (typeof Storage === 'object') {
      return Storage;
    } else if (typeof Storage === 'function') {
      return new Storage(this.config);
    } else if (this.config.get('storage') === 'localstorage') {
      return new localstorage_LocalStorageAdapter(this.config);
    }
    return new InMemoryAdapter(this.config);
  }

  /**
   * make sure storage actions are executed (and finished) in the order they are called
   *
   * @return {any[]}
   *
   * @api public
   */
  storageQueue() {
    return new Promise((resolve) => {
      this.storageJobFifo.push(resolve);

      if (this.storageJobFifo.length === 1) {
        this.nextJob();
      }
    });
  }

  /**
   * execute next job in storage job buffer
   *
   * @return {any[]}
   */
  nextJob() {
    const resolve = this.storageJobFifo[0];

    const wrap = async (fn, args) => {
      // eslint-disable-next-line no-useless-catch
      try {
        // eslint-disable-next-line prefer-spread
        const result = await this.storage[fn].apply(this.storage, args);
        this.storageJobFifo.splice(0, 1);

        if (this.storageJobFifo.length > 0) {
          setTimeout(this.nextJob(), 1);
        }

        return result;
      } catch (error) {
        throw error;
      }
    };

    if (resolve) {
      resolve({
        // eslint-disable-next-line no-unused-vars
        async get(key) { return wrap('get'); },
        // eslint-disable-next-line no-unused-vars,prefer-rest-params
        async set(key, value) { return wrap('set', arguments); },
        // eslint-disable-next-line no-unused-vars,prefer-rest-params
        async has(key) { return wrap('has', arguments); },
        async clear() { return wrap('clear'); },
      });
    }
  }

  /**
   * Select a channel by channel name
   *
   * @param  {String} name
   * @return {StorageCapsule}
   *
   * @api public
   */
  channel(name) {
    this.storageChannel = name;
    return this;
  }

  /**
   * Fetch tasks from storage with ordered
   *
   * @return {any[]}
   *
   * @api public
   */
  async fetch() {
    const all = (await this.all()).filter(excludeSpecificTasks);
    const tasks = group_by_default()(all, 'priority');
    return keys_default()(tasks)
      .map((key) => parse_int_default()(key, 10))
      .sort((a, b) => b - a)
      .reduce(this.reduceTasks(tasks), []);
  }

  /**
   * Save task to storage
   *
   * @param  {ITask} task
   * @return {String|Boolean}
   *
   * @api public
   */
  async save(task) {
    if (typeof task !== 'object') return false;

    // get all tasks current channel's
    const tasks = await this.storage.get(this.storageChannel);

    // Check the channel limit.
    // If limit is exceeded, does not insert new task
    if (await this.isExceeded()) {
      console.warn(
        `Task limit exceeded: The '${
          this.storageChannel
        }' channel limit is ${this.config.get('limit')}`
      );
      return false;
    }

    // prepare all properties before save
    // example: createdAt etc.
    const newTask = this.prepareTask(task);

    // add task to storage
    tasks.push(newTask);

    // save tasks
    await this.storage.set(this.storageChannel, tasks);

    return newTask._id;
  }

  /**
   * Update channel store.
   *
   * @return {string}
   *   The value. This annotation can be used for type hinting purposes.
   */
  async update(id, update) {
    const result = await this.storageQueue().then(async (storage) => {
      const data = await this.all();
      const index = data.findIndex((t) => t._id === id);

      // if index not found, return false
      if (index < 0) return false;

      // merge existing object with given update object
      data[index] = { ...data[index], ...update };
      await storage.set(this.storageChannel, data);

      return true;
    });

    return result;
  }

  /**
   * Remove task from storage
   *
   * @param  {String} id
   * @return {string}
   *
   * @api public
   */
  async delete(id) {
    const result = await this.storageQueue().then(async (storage) => {
      const data = await this.all();
      const index = data.findIndex((d) => d._id === id);

      if (index < 0) return false;
      console.log(data);
      delete data[index];
      
      await storage.set(
        this.storageChannel,
        data.filter((d) => d)
      );

      return true;
    });

    return result;
  }

  /**
   * Get all tasks
   *
   * @return {Any[]}
   *
   * @api public
   */
  async all() {
    const items = await this.storage.get(this.storageChannel);
    return items;
  }

  /**
   * Generate unique id
   *
   * @return {String}
   *
   * @api public
   */
  generateId() {
    return ((1 + Math.random()) * 0x10000).toString(16);
  }

  /**
   * Add some necessary properties
   *
   * @param  {String} id
   * @return {ITask}
   *
   * @api public
   */
  prepareTask(task) {
    /* eslint no-param-reassign: off */
    const newTask = {};
    keys_default()(task).forEach((key) => {
      newTask[key] = task[key];
    });
    newTask.createdAt = now_default()();
    newTask._id = this.generateId();
    return newTask;
  }

  /**
   * Add some necessary properties
   *
   * @param  {ITask[]} tasks
   * @return {Function}
   *
   * @api public
   */
  reduceTasks(tasks) {
    const reduceFunc = (result, key) => {
      if (this.config.get('principle') === 'lifo') {
        return result.concat(tasks[key].sort(lifo));
      }
      return result.concat(tasks[key].sort(fifo));
    };

    return reduceFunc.bind(this);
  }

  /**
   * Task limit checker
   *
   * @return {Boolean}
   *
   * @api public
   */
  async isExceeded() {
    const limit = this.config.get('limit');
    const tasks = (await this.all()).filter(excludeSpecificTasks);
    return !(limit === -1 || limit > tasks.length);
  }

  /**
   * Clear tasks with given channel name
   *
   * @param  {String} channel
   * @return {void}
   *
   * @api public
   */
  async clear(channel) {
    this.storageJobFifo = [];
    await this.storage.clear(channel);
  }
}

// EXTERNAL MODULE: ./node_modules/@babel/runtime-corejs2/core-js/object/values.js
var values = __webpack_require__(1217);
var values_default = /*#__PURE__*/__webpack_require__.n(values);

// EXTERNAL MODULE: ./node_modules/object-path/index.js
var object_path = __webpack_require__(1221);
var object_path_default = /*#__PURE__*/__webpack_require__.n(object_path);

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/enum/log.events.js
/* harmony default export */ var log_events = ({
  queue: {
    created: 'New task created.',
    next: 'Next task processing.',
    starting: 'Queue listener starting.',
    stopping: 'Queue listener stopping.',
    stopped: 'Queue listener stopped.',
    empty: 'channel is empty...',
    'not-found': 'worker not found',
    offline: 'Disconnected',
    online: 'Connected',
  },

  event: {
    created: 'event created',
    fired: 'Event fired.',
    'wildcard-fired': 'Wildcard event fired.',
  },
});

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/console.js



/* eslint no-console: ["error", { allow: ["log", "groupCollapsed", "groupEnd"] }] */

function log(...args) {
  console.log(...args);
}

function taskAddedLog([task]) {
  log(
    `%c${String.fromCharCode(43)} (${task.handler}) -> ${object_path_default.a.get(
      log_events,
      'queue.created'
    )}`,
    'color: green;font-weight: bold;'
  );
}

function queueStartLog([type]) {
  log(
    `%c${String.fromCharCode(8211)} (${type}) -> ${object_path_default.a.get(
      log_events,
      'queue.starting'
    )}`,
    'color: #3fa5f3;font-weight: bold;'
  );
}

function nextTaskLog([type]) {
  log(
    `%c${String.fromCharCode(187)} (${type}) -> ${object_path_default.a.get(
      log_events,
      'queue.next'
    )}`,
    'color: #3fa5f3;font-weight: bold;'
  );
}

function queueStoppingLog([type]) {
  log(
    `%c${String.fromCharCode(8226)} (${type}) -> ${object_path_default.a.get(
      log_events,
      'queue.stopping'
    )}`,
    'color: #ff7f94;font-weight: bold;'
  );
}

function queueStoppedLog([type]) {
  log(
    `%c${String.fromCharCode(8226)} (${type}) -> ${object_path_default.a.get(
      log_events,
      'queue.stopped'
    )}`,
    'color: #ff7f94;font-weight: bold;'
  );
}

function queueEmptyLog([type]) {
  log(
    `%c${type} ${object_path_default.a.get(log_events, 'queue.empty')}`,
    'color: #ff7f94;font-weight: bold;'
  );
}

function eventCreatedLog([key, name]) {
  log(
    `%c(${name}) -> ${key} ${object_path_default.a.get(log_events, 'event.created')}`,
    'color: #66cee3;font-weight: bold;'
  );
}

function eventFiredLog([key, name]) {
  log(
    `%c(${key}) -> ${object_path_default.a.get(log_events, `event.${name}`)}`,
    'color: #a0dc3c;font-weight: bold;'
  );
}

function notFoundLog([name]) {
  log(
    `%c${String.fromCharCode(215)} (${name}) -> ${object_path_default.a.get(
      log_events,
      'queue.not-found'
    )}`,
    'color: #b92e2e;font-weight: bold;'
  );
}

function workerRunninLog([worker, workerInstance, task, channel, deps]) {
  console.groupCollapsed(`${worker.name || task.handler} - ${task.label}`);
  log(`%cchannel: ${channel}`, 'color: blue;');
  log(`%clabel: ${task.label || ''}`, 'color: blue;');
  log(`%chandler: ${task.handler}`, 'color: blue;');
  log(`%cpriority: ${task.priority}`, 'color: blue;');
  log(`%cunique: ${task.unique || 'false'}`, 'color: blue;');
  log(`%cretry: ${workerInstance.retry || '1'}`, 'color: blue;');
  log(`%ctried: ${task.tried ? task.tried + 1 : '1'}`, 'color: blue;');
  log(`%ctag: ${task.tag || ''}`, 'color: blue;');
  log('%cargs:', 'color: blue;');
  log(task.args || '');
  console.groupCollapsed('dependencies');
  log(...(deps[worker.name] || []));
  console.groupEnd();
}

function workerDoneLog([result, task, workerInstance]) {
  if (result === true) {
    log(`%c${String.fromCharCode(10003)} Task completed!`, 'color: green;');
  } else if (!result && task.tried < workerInstance.retry) {
    log('%cTask will be retried!', 'color: #d8410c;');
  } else {
    log(
      `%c${String.fromCharCode(10005)} Task failed and freezed!`,
      'color: #ef6363;'
    );
  }
  console.groupEnd();
}

function workerFailedLog() {
  log(`%c${String.fromCharCode(10005)} Task failed!`, 'color: red;');
  console.groupEnd();
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/helpers.js


/* eslint import/no-cycle: "off" */







/* global Worker */
/* eslint no-underscore-dangle: [2, { "allow": ["_id"] }] */
/* eslint no-param-reassign: "error" */
/* eslint use-isnan: "error" */

/**
 * Task priority controller helper
 * Context: Channel
 *
 * @return {ITask}
 * @param {ITask} task
 *
 * @api private
 */
function checkPriority(task) {
  task.priority = task.priority || 0;

  if (typeof task.priority !== 'number') task.priority = 0;

  return task;
}

/**
 * Shortens function the db belongsto current channel
 * Context: Channel
 *
 * @return {StorageCapsule}
 *
 * @api private
 */
function db() {
  return this.storage.channel(this.name());
}

/**
 * Get unfreezed tasks by the filter function
 * Context: Channel
 *
 * @return {ITask}
 *
 * @api private
 */
async function getTasksWithoutFreezed() {
  return (await db.call(this).all()).filter(
    excludeSpecificTasks.bind(['freezed'])
  );
}

/**
 * Log proxy helper
 * Context: Channel
 *
 * @return {void}
 * @param {string} key
 * @param {string} data
 * @param {boolean} cond
 *
 * @api private
 */
function logProxy(wrapperFunc, ...args) {
  if (this.config.get('debug') && typeof wrapperFunc === 'function') {
    wrapperFunc(args);
  }
}

/**
 * New task save helper
 * Context: Channel
 *
 * @param {ITask} task
 * @return {string|boolean}
 *
 * @api private
 */
async function saveTask(task) {
  const result = await db.call(this).save(checkPriority(task));
  return result;
}

/**
 * Task remove helper
 * Context: Channel
 *
 * @param {string} id
 * @return {boolean}
 *
 * @api private
 */
async function removeTask(id) {
  const result = await db.call(this).delete(id);
  return result;
}

/**
 * Events dispatcher helper
 * Context: Channel
 *
 * @param {ITask} task
 * @param {string} type
 * @return {void}
 *
 * @api private
 */
function dispatchEvents(task, type) {
  if (!('tag' in task)) return false;

  const events = [
    [`${task.tag}:${type}`, 'fired'],
    [`${task.tag}:*`, 'wildcard-fired'],
  ];

  events.forEach((e) => {
    this.event.emit(e[0], task);
    logProxy.call(this, eventFiredLog, ...e);
  });

  return true;
}

/**
 * Queue stopper helper
 * Context: Channel
 *
 * @return {void}
 *
 * @api private
 */
function stopQueue() {
  this.stop();

  this.running = false;

  clearTimeout(this.currentTimeout);

  logProxy.call(this, queueStoppedLog, 'stop');
}

/**
 * Failed job handler
 * Context: Channel
 *
 * @param {ITask} task
 * @return {ITask} job
 * @return {Function}
 *
 * @api private
 */
async function failedJobHandler(task) {
  return async function childFailedHandler() {
    removeTask.call(this, task._id);

    this.event.emit('error', task);

    logProxy.call(this, workerFailedLog);

    /* istanbul ignore next */
    await this.next();
  };
}

/**
 * Helper of the lock task of the current job
 * Context: Channel
 *
 * @param {ITask} task
 * @return {boolean}
 *
 * @api private
 */
async function lockTask(task) {
  const result = await db.call(this).update(task._id, { locked: true });
  return result;
}

/**
 * Class event luancher helper
 * Context: Channel
 *
 * @param {string} name
 * @param {IWorker} worker
 * @param {any} args
 * @return {boolean|void}
 *
 * @api private
 */
function fireJobInlineEvent(name, worker, args) {
  if (hasMethod(worker, name) && isFunction(worker[name])) {
    worker[name].call(worker, args);
    return true;
  }
  return false;
}

/**
 * Process handler of succeeded job
 * Context: Channel
 *
 * @param {ITask} task
 * @return {void}
 *
 * @api private
 */
function successProcess(task) {
  removeTask.call(this, task._id);
}

/**
 * Update task's retry value
 * Context: Channel
 *
 * @param {ITask} task
 * @param {IWorker} worker
 * @return {ITask}
 *
 * @api private
 */
function updateRetry(task, worker) {
  if (!('retry' in worker)) worker.retry = 1;

  if (!('tried' in task)) {
    task.tried = 0;
    task.retry = worker.retry;
  }

  task.tried += 1;

  if (task.tried >= worker.retry) {
    task.freezed = true;
  }

  return task;
}

/**
 * Process handler of retried job
 * Context: Channel
 *
 * @param {ITask} task
 * @param {IWorker} worker
 * @return {boolean}
 *
 * @api private
 */
async function retryProcess(task, worker) {
  // dispacth custom retry event
  dispatchEvents.call(this, task, 'retry');

  // update retry value
  const updateTask = updateRetry.call(this, task, worker);

  // delete lock property for next process
  updateTask.locked = false;

  const result = await db.call(this).update(task._id, updateTask);

  return result;
}

/**
 * Succeed job handler
 * Context: Channel
 *
 * @param {ITask} task
 * @param {IWorker} worker
 * @return {Function}
 *
 * @api private
 */
async function successJobHandler(task, worker) {
  const self = this;
  return async function childSuccessJobHandler(result) {
    // dispatch job process after runs a task but only non error jobs
    if (result) {
      // go ahead to success process
      successProcess.call(self, task);
    } else {
      // go ahead to retry process
      await retryProcess.call(self, task, worker);
    }

    // fire job after event
    fireJobInlineEvent.call(self, 'after', worker, task.args);

    // dispacth custom after event
    dispatchEvents.call(self, task, 'after');

    // show console
    logProxy.call(self, workerDoneLog, result, task, worker);

    // try next queue job
    await self.next();
  };
}

/**
 * Job handler helper
 * Context: Channel
 *
 * @param {ITask} task
 * @param {IJob} worker
 * @param {IWorker} workerInstance
 * @return {Function}
 *
 * @api private
 */
function loopHandler(
  task,
  worker,
  workerInstance
) {
  return async function childLoopHandler() {
    let workerPromise;
    const self = this;

    // lock the current task for prevent race condition
    await lockTask.call(self, task);

    // fire job before event
    fireJobInlineEvent.call(this, 'before', workerInstance, task.args);

    // dispacth custom before event
    dispatchEvents.call(this, task, 'before');

    // if has any dependency in dependencies, get it
    const deps = queue_Queue.workerDeps[task.handler];

    // preparing worker dependencies
    const dependencies = values_default()(deps || {});

    // show console
    logProxy.call(
      this,
      workerRunninLog,
      worker,
      workerInstance,
      task,
      self.name(),
      queue_Queue.workerDeps
    );

    // Check worker instance and route the process via instance
    if (workerInstance instanceof Worker) {
      // start the native worker by passing task parameters and dependencies.
      // Note: Native worker parameters can not be class or function.
      workerInstance.postMessage({ args: task.args, dependencies });

      // Wrap the worker with promise class.
      workerPromise = new promise_default.a((resolve) => {
        // Set function to worker onmessage event for handle the repsonse of worker.
        workerInstance.onmessage = (response) => {
          resolve(worker.handler(response));

          // Terminate browser worker.
          workerInstance.terminate();
        };
      });
    } else {
      // This is custom worker class.
      // Call the handle function in worker and get promise instance.
      workerPromise = workerInstance.handle.call(
        workerInstance,
        task.args,
        ...dependencies
      );
    }

    workerPromise
      // Handle worker return process.
      .then(
        (await successJobHandler.call(self, task, workerInstance)).bind(self)
      )
      // Handle errors in worker while it was running.
      .catch((await failedJobHandler.call(self, task)).bind(self));
  };
}

/**
 * Timeout creator helper
 * Context: Channel
 *
 * @return {number}
 *
 * @api private
 */
async function createTimeout() {
  // if running any job, stop it
  // the purpose here is to prevent cocurrent operation in same channel
  clearTimeout(this.currentTimeout);

  // Get next task
  const task = (await db.call(this).fetch()).shift();

  if (task === undefined) {
    logProxy.call(this, queueEmptyLog, this.name());
    this.event.emit('completed', task);
    return 0;
  }

  if (!queue_Queue.worker.has(task.handler)) {
    logProxy.call(this, notFoundLog, task.handler);
    await (await failedJobHandler.call(this, task)).call(this);
    return 0;
  }

  // Get worker with handler name
  const JobWorker = queue_Queue.worker.get(task.handler);

  // Create a worker instance
  const workerInstance =
    typeof JobWorker === 'object' ? new Worker(JobWorker.uri) : new JobWorker();

  // get always last updated config value
  const timeout = this.config.get('timeout');

  // create a array with handler parameters for shorten line numbers
  const params = [task, JobWorker, workerInstance];

  // Get handler function for handle on completed event
  const handler = (await loopHandler.call(this, ...params)).bind(this);

  // create new timeout for process a job in queue
  // binding loopHandler function to setTimeout
  // then return the timeout instance
  this.currentTimeout = setTimeout(handler, timeout);

  return this.currentTimeout;
}

/**
 * Set the status to false of queue
 * Context: Channel
 *
 * @return {void}
 *
 * @api private
 */
function statusOff() {
  this.running = false;
}

/**
 * Checks whether a task is replicable or not
 * Context: Channel
 *
 * @param {ITask} task
 * @return {boolean}
 *
 * @api private
 */
async function canMultiple(task) {
  if (typeof task !== 'object' || task.unique !== true) return true;
  return (await this.hasByTag(task.tag)) === false;
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/channel.js
function channel_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}



/* eslint import/no-cycle: "off" */








/* eslint no-underscore-dangle: [2, { "allow": ["_id"] }] */

const channelName = symbol_default()('channel-name');

class channel_Channel {
  constructor(name, config) {
    channel_defineProperty(this, 'stopped', true);
    channel_defineProperty(this, 'running', false);
    channel_defineProperty(this, 'timeout', void 0);
    channel_defineProperty(this, 'storage', void 0);
    channel_defineProperty(this, 'config', void 0);
    channel_defineProperty(this, 'event', new Event());
    this.config = config;

    // save channel name to this class with symbolic key
    this[channelName] = name;

    // if custom storage driver exists, setup it
    const { drivers } = queue_Queue;
    const storage = new storage_capsule_StorageCapsule(config, drivers.storage);
    this.storage = storage.channel(name);
  }

  /**
   * Get channel name
   *
   * @return {String} channel name
   *
   * @api public
   */
  name() {
    return this[channelName];
  }

  /**
   * Create new job to channel
   *
   * @param  {Object} task
   * @return {String|Boolean} job
   *
   * @api public
   */
  async add(task) {
    if (!(await canMultiple.call(this, task))) return false;

    const id = await saveTask.call(this, task);

    if (id && this.running === true) {
      await this.start();
    }

    // pass activity to the log service.
    logProxy.call(this, taskAddedLog, task);

    return id;
  }

  /**
   * Process next job
   *
   * @return {void}
   *
   * @api public
   */
  async next() {
    if (this.stopped) {
      return stopQueue.call(this);
    }

    // Generate a log message
    logProxy.call(this, nextTaskLog, 'next');

    // start queue again
    await this.start();

    return true;
  }

  /**
   * Start queue listener
   *
   * @return {Boolean} job
   *
   * @api public
   */
  async start() {
    this.stopped = false;
    this.running = true;

    logProxy.call(this, queueStartLog, 'start');

    // Create a timeout for start the queue
    await createTimeout.call(this);
  }

  /**
   * Stop queue listener after end of current task
   *
   * @return {Void}
   *
   * @api public
   */
  stop() {
    logProxy.call(this, queueStoppingLog, 'stop');
    this.stopped = true;
  }

  /**
   * Stop queue listener including current task
   *
   * @return {Void}
   *
   * @api public
   */
  forceStop() {
    /* istanbul ignore next */
    stopQueue.call(this);
  }

  /**
   * Check if the channel working
   *
   * @return {Boolean}
   *
   * @api public
   */
  status() {
    return this.running;
  }

  /**
   * Check whether there is any task
   *
   * @return {Booelan}
   *
   * @api public
   */
  async isEmpty() {
    return (await this.count()) < 1;
  }

  /**
   * Get task count
   *
   * @return {Number}
   *
   * @api public
   */
  async count() {
    return (await getTasksWithoutFreezed.call(this)).length;
  }

  /**
   * Get task count by tag
   *
   * @param  {String} tag
   * @return {Array<ITask>}
   *
   * @api public
   */
  async countByTag(tag) {
    return (await getTasksWithoutFreezed.call(this)).filter(
      (t) => t.tag === tag
    ).length;
  }

  /**
   * Remove all tasks from channel
   *
   * @return {Boolean}
   *
   * @api public
   */
  async clear() {
    if (!this.name()) return false;
    await this.storage.clear(this.name());
    return true;
  }

  /**
   * Remove all tasks from channel by tag
   *
   * @param  {String} tag
   * @return {Boolean}
   *
   * @api public
   */
  async clearByTag(tag) {
    const self = this;
    const data = await db.call(self).all();
    const removes = data.filter(utilClearByTag.bind(tag)).map(async (t) => {
      const result = await db.call(self).delete(t._id);
      return result;
    });
    await promise_default.a.all(removes);
  }

  /**
   * Check a task whether exists by job id
   *
   * @param  {String} tag
   * @return {Boolean}
   *
   * @api public
   */
  async has(id) {
    return (
      (await getTasksWithoutFreezed.call(this)).findIndex((t) => t._id === id) >
      -1
    );
  }

  /**
   * Check a task whether exists by tag
   *
   * @param  {String} tag
   * @return {Boolean}
   *
   * @api public
   */
  async hasByTag(tag) {
    return (
      (await getTasksWithoutFreezed.call(this)).findIndex(
        (t) => t.tag === tag
      ) > -1
    );
  }

  /**
   * Set action events
   *
   * @param  {String} key
   * @param  {Function} cb
   * @return {Void}
   *
   * @api public
   */
  on(key, cb) {
    this.event.on(...[key, cb]);
    logProxy.call(this, eventCreatedLog, key, this.name());
  }
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/container.js

function container_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}

class Container {
  constructor() {
    container_defineProperty(this, 'store', {});
  }

  // freeze(id: string): void {
  //   console.log(this, id);
  // }

  // add(value: any): void {
  //   console.log(this, value);
  // }

  /**
   * Check item in container
   *
   * @param  {String} id
   * @return {Boolean}
   *
   * @api public
   */
  has(id) {
    return Object.prototype.hasOwnProperty.call(this.store, id);
  }

  /**
   * Get item from container
   *
   * @param  {String} id
   * @return {Any}
   *
   * @api public
   */
  get(id) {
    return this.store[id];
  }

  /**
   * Get all items from container
   *
   * @return {Object}
   *
   * @api public
   */
  all() {
    return this.store;
  }

  /**
   * Add item to container
   *
   * @param  {String} id
   * @param  {Any} value
   * @return {void}
   *
   * @api public
   */
  bind(id, value) {
    this.store[id] = value;
  }

  /**
   * Merge continers
   *
   * @param  {Object} data
   * @return {void}
   *
   * @api public
   */
  merge(data = {}) {
    this.store = { ...this.store, ...data };
  }

  /**
   * Remove item from container
   *
   * @param  {String} id
   * @return {Boolean}
   *
   * @api public
   */
  remove(id) {
    if (!this.has(id)) return false;
    return delete this.store[id];
  }

  /**
   * Remove all items from container
   *
   * @return {void}
   *
   * @api public
   */
  removeAll() {
    this.store = {};
  }
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/enum/config.data.js
/* harmony default export */ var config_data = ({
  defaultStorage: 'localstorage',
  prefix: 'sq_jobs',
  timeout: 1000,
  limit: -1,
  principle: 'fifo',
  debug: true,
});

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/config.js


function config_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}



class config_Config {
  constructor(config = {}) {
    config_defineProperty(this, 'config', {});
    config_defineProperty(this, 'timeout', void 0);
    config_defineProperty(this, 'storage', void 0);
    config_defineProperty(this, 'principle', void 0);
    config_defineProperty(this, 'prefix', void 0);
    config_defineProperty(this, 'limit', void 0);
    this.merge(config_data);
    this.merge(config);
  }

  /**
   * Set config to global config reference
   *
   * @param  {String} name
   * @param  {Any} value
   * @return {void}
   *
   * @api public
   */
  set(name, value) {
    this.config[name] = value;
  }

  /**
   * Get a config
   *
   * @param  {String} name
   * @return {any}
   *
   * @api public
   */
  get(name) {
    return this.config[name];
  }

  /**
   * Check config property
   *
   * @param  {String} name
   * @return {any}
   *
   * @api public
   */
  has(name) {
    return Object.prototype.hasOwnProperty.call(this.config, name);
  }

  /**
   * Merge two config object
   *
   * @param  {String} name
   * @return {void}
   *
   * @api public
   */
  merge(config) {
    keys_default()(config).forEach((key) => {
      this.config[key] = config[key];
    });
  }

  /**
   * Remove a config
   *
   * @param  {String} name
   * @return {Boolean}
   *
   * @api public
   */
  remove(name) {
    return delete this.config[name];
  }

  /**
   * Get all config
   *
   * @param  {String} name
   * @return {IConfig[]}
   *
   * @api public
   */
  all() {
    return this.config;
  }
}

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/queue.js


function queue_defineProperty(obj, key, value) {
  if (key in obj) {
    define_property_default()(obj, key, {
      value: value,
      enumerable: true,
      configurable: true,
      writable: true,
    });
  } else {
    obj[key] = value;
  }
  return obj;
}
/* eslint import/no-cycle: "off" */





class queue_Queue {
  constructor(config) {
    queue_defineProperty(this, 'config', void 0);
    queue_defineProperty(this, 'container', void 0);
    this.config = new config_Config(config);
    this.container = queue_Queue.container;
  }

  /**
   * Create a new channel
   *
   * @param  {String} task
   * @return {Queue} channel
   *
   * @api public
   */
  create(channel) {
    if (!this.container.has(channel)) {
      this.container.bind(channel, new channel_Channel(channel, this.config));
    }
    return this.container.get(channel);
  }

  /**
   * Get channel instance by channel name
   *
   * @param  {String} name
   * @return {Queue}
   *
   * @api public
   */
  channel(name) {
    if (!this.container.has(name)) {
      throw new Error(`"${name}" channel not found`);
    }
    return this.container.get(name);
  }

  /**
   * Set config timeout value
   *
   * @param  {Number} val
   * @return {Void}
   *
   * @api public
   */
  setTimeout(val) {
    this.config.set('timeout', val);
  }

  /**
   * Set config limit value
   *
   * @param  {Number} val
   * @return {Void}
   *
   * @api public
   */
  setLimit(val) {
    this.config.set('limit', val);
  }

  /**
   * Set config prefix value
   *
   * @param  {String} val
   * @return {Void}
   *
   * @api public
   */
  setPrefix(val) {
    this.config.set('prefix', val);
  }

  /**
   * Set config priciple value
   *
   * @param  {String} val
   * @return {Void}
   *
   * @api public
   */
  setPrinciple(val) {
    this.config.set('principle', val);
  }

  /**
   * Set config debug value
   *
   * @param  {Boolean} val
   * @return {Void}
   *
   * @api public
   */
  setDebug(val) {
    this.config.set('debug', val);
  }

  setStorage(val) {
    this.config.set('storage', val);
  }
}
queue_defineProperty(queue_Queue, 'FIFO', 'fifo');
queue_defineProperty(queue_Queue, 'LIFO', 'lifo');
queue_defineProperty(queue_Queue, 'drivers', {});
queue_defineProperty(queue_Queue, 'workerDeps', {});
queue_defineProperty(queue_Queue, 'container', void 0);
queue_defineProperty(queue_Queue, 'worker', void 0);
queue_defineProperty(queue_Queue, 'workers', void 0);
queue_defineProperty(queue_Queue, 'deps', void 0);
queue_defineProperty(queue_Queue, 'use', void 0);

queue_Queue.worker = new Container();

queue_Queue.container = new Container();

/**
 * Register worker
 *
 * @param  {Array<IJob>} jobs
 * @return {Void}
 *
 * @api public
 */
queue_Queue.workers = function workers(workersObj = {}) {
  if (!(workersObj instanceof Object)) {
    throw new Error('The parameters should be object.');
  }

  queue_Queue.worker.merge(workersObj);
};

/**
 * Added workers dependencies
 *
 * @param  {Object} driver
 * @return {Void}
 *
 * @api public
 */
queue_Queue.deps = function deps(dependencies = {}) {
  if (!(dependencies instanceof Object)) {
    throw new Error('The parameters should be object.');
  }
  queue_Queue.workerDeps = dependencies;
};

/**
 * Setup a custom driver
 *
 * @param  {Object} driver
 * @return {Void}
 *
 * @api public
 */
queue_Queue.use = function use(driver = {}) {
  keys_default()(driver).forEach((name) => {
    queue_Queue.drivers[name] = driver[name];
  });
};

// CONCATENATED MODULE: ./node_modules/storage-based-queue/lib/index.js



/* global window:true */

if (typeof window !== 'undefined') {
  window.Queue = queue_Queue;
}

/* harmony default export */ var lib = (queue_Queue);

// CONCATENATED MODULE: ./ux/file/UploadChannel.js



class UploadChannel_UploadChannel extends channel_Channel {
  constructor(name, config) {
    super(name, config);
    this.islocked = false;
  }
  /**
   * add batch of Tasks
   * NOTE: saves a copy of all Tasks in local storage to be used for progress computations (adds a cleanup tasks as last job)
   * all tasks need to have a common progress interface: (bytesTotal / bytesUploaded fields)
   * all tasks need to have common fields: appName, label (e.g. Filemanager /path/to/file)
   */


  async addBatch(tasks) {
    const taskIDs = []; // add task and save copy

    await _.reduce(tasks, (prev, task) => {
      return prev.then(async () => {
        const taskId = await this.add(task);
        const uploadId = task.args.uploadId;
        Tine.Tinebase.uploadManager.tasks[uploadId] = [];
        Tine.Tinebase.uploadManager.tasks[uploadId] = task;
        Tine.Tinebase.uploadManager.tasks[uploadId]._id = taskId;
        return taskIDs.push(taskId);
      });
    }, Promise.resolve());
    return taskIDs;
  }
  /**
   * get all direct child nodes of given path which are not yet processed
   * NOTE: have progress info on each returned node
   */


  getAllTasks() {
    var _this6 = this;

    return _asyncToGenerator(function* () {
      return yield getTasksWithoutFreezed.call(_this6);
    })();
  }
  /**
   * Check a task whether exists by job id
   *
   * @return {Boolean}
   *
   * @api public
   * @param id
   */


  get(id) {
    var _this9 = this;

    return _asyncToGenerator(function* () {
      return (yield getTasksWithoutFreezed.call(_this9)).filter(function (t) {
        return t._id === id;
      });
    })();
  }

}

function _asyncToGenerator(fn) {
  return function () {
    var gen = fn.apply(this, arguments);
    return new Promise(function (resolve, reject) {
      function step(key, arg) {
        try {
          var info = gen[key](arg);
          var value = info.value;
        } catch (error) {
          reject(error);
          return;
        }

        if (info.done) {
          resolve(value);
        } else {
          return Promise.resolve(value).then(function (value) {
            step('next', value);
          }, function (err) {
            step('throw', err);
          });
        }
      }

      return step('next');
    });
  };
}

/* harmony default export */ var file_UploadChannel = (UploadChannel_UploadChannel);
// CONCATENATED MODULE: ./ux/file/UploadQueue.js



class UploadQueue_UploadQueue extends lib {
  /**
   * Create a new channel
   *
   * @return {Queue} channel
   *
   * @api public
   * @param channel
   */
  create(channel) {
    if (!this.container.has(channel)) {
      this.container.bind(channel, new file_UploadChannel(channel, this.config));
    }

    return this.container.get(channel);
  }

}

/* harmony default export */ var file_UploadQueue = (UploadQueue_UploadQueue);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/defineProperty.js
var defineProperty = __webpack_require__(144);
var defineProperty_default = /*#__PURE__*/__webpack_require__.n(defineProperty);

// CONCATENATED MODULE: /root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Filemanager/js/CreateFolderTask.js

class CreateFolderTask_CreateFolderTask {
  constructor() {
    defineProperty_default()(this, "retry", 3);
  }

  handle(args) {
    return new Promise(async (resolve, reject) => {
      if (args.existNode) {
        args.nodeData.status = 'complete';
        await Tine.Tinebase.uploadManager.updateTaskByArgs(args);
        resolve(true);
      } else {
        await Tine.Filemanager.createNode(args.uploadId, 'folder', [], false).then(async response => {
          args.nodeData = response;
          args.nodeData.status = 'complete';
          const task = await Tine.Tinebase.uploadManager.updateTaskByArgs(args);
          window.postal.publish({
            channel: "recordchange",
            topic: 'Filemanager.Node.update',
            data: task.args.nodeData
          });
          Tine.Tinebase.uploadManager.removeVirtualNode(args.uploadId);
          return resolve(true);
        }).catch(async e => {
          if (e.message === 'file exists') {
            args.nodeData.status = 'complete';
            await Tine.Tinebase.uploadManager.updateTaskByArgs(args);
            return resolve(true);
          } else {
            // retry
            return resolve(false);
          }
        });
      }
    });
  }

}
// CONCATENATED MODULE: /root/packaging/tine20.com/2021.11/source/tine20build/temp/tine20/Filemanager/js/UploadFileTask.js

class UploadFileTask_UploadFileTask {
  constructor() {
    defineProperty_default()(this, "retry", 3);
  }

  async handle(args) {
    console.log("FilemanagerUploadFileTask on window : ".concat(postal.instanceId())); // Should return true or false value (boolean) that end of the all process
    // If process rejected, current task will be removed from task pool in worker.

    return new Promise(async (resolve, reject) => {
      const upload = Tine.Tinebase.uploadManager.getUpload(args.uploadId);

      if (!upload) {
        reject('upload is not found!');
      }

      const updateTask = async function updateTask(args) {
        try {
          const task = await Tine.Tinebase.uploadManager.updateTaskByArgs(args);
          window.postal.publish({
            channel: "recordchange",
            topic: 'Filemanager.Node.update',
            data: task.args.nodeData
          });
        } catch (e) {
          Tine.Tinebase.uploadManager.unregisterUpload(args.uploadId);
          reject('update task to storage failed');
        }
      };

      upload.on('uploadprogress', async (upload, fileRecord) => {
        args.nodeData.status = fileRecord.get('status');
        args.nodeData.progress = fileRecord.get('progress');
        args.nodeData.contenttype = "vnd.adobe.partial-upload; final_type=".concat(fileRecord.get('type'), "; progress=").concat(fileRecord.get('progress'));
        await updateTask(args);
      });
      upload.on('uploadcomplete', async (upload, fileRecord) => {
        args.nodeData.contenttype = "vnd.adobe.partial-upload; final_type=".concat(fileRecord.get('type'), "; progress=").concat(fileRecord.get('progress'));
        args.nodeData.progress = fileRecord.get('progress');
        await updateTask(args); //need to update grid with existing node id

        args.nodeData = await Tine.Filemanager.createNode(args.uploadId, fileRecord.get('type'), fileRecord.get('id'), true);
        args.nodeData.progress = 100;
        args.nodeData.status = 'complete';
        await updateTask(args);
        resolve(true);
      });
      upload.on('uploadfailure', async (upload, fileRecord) => {
        args.nodeData.status = 'failed';
        await updateTask(args);
        reject('upload failed');
      });

      try {
        const type = "vnd.adobe.partial-upload; final_type=".concat(args.nodeData.type);
        args.nodeData = await Tine.Filemanager.createNode(args.uploadId, type, [], args === null || args === void 0 ? void 0 : args.overwrite);
        args.nodeData.status = 'pending';
        args.nodeData.size = args === null || args === void 0 ? void 0 : args.fileSize;
        Tine.Tinebase.uploadManager.removeVirtualNode(args.uploadId);
      } catch (e) {
        if (e.data.code === 403) {
          args.nodeData.status = 'failed';
          const task = await Tine.Tinebase.uploadManager.updateTaskByArgs(args);
          window.postal.publish({
            channel: "recordchange",
            topic: 'Filemanager.Node.delete',
            data: task.args.nodeData
          });
          Tine.Tinebase.uploadManager.removeVirtualNode(args.uploadId);
          reject(e.message);
          throw e;
        }

        if (e.message === 'file exists') {
          const button = await new Promise(resolve => {
            if (Tine.Tinebase.uploadManager.applyToAll[args.batchID]) {
              const button = Tine.Tinebase.uploadManager.applyToAll[args.batchID];
              resolve(button);
            } else {
              Tine.Filemanager.DuplicateFileUploadDialog.openWindow({
                uploadId: args.uploadId,
                batchID: args.batchID,
                fileName: args.nodeData.name,
                fileType: 'file',
                scope: this,
                handler: async function handler(button) {
                  resolve(button);
                }
              });
            }
          });

          if (button === 'stop' || button === 'skip') {
            args.nodeData.status = 'cancelled';
            await updateTask(args);
            Tine.Tinebase.uploadManager.removeVirtualNode(args.uploadId);
            return resolve(true);
          }

          args.nodeData = await Tine.Filemanager.getNode(_.get(e, 'data.existingnodesinfo[0].id'));
          args.nodeData.contenttype = "vnd.adobe.partial-upload; final_type=".concat(args.nodeData.contenttype, "; progress=0");
          args.nodeData.status = 'pending';
          args.overwrite = true;
        }

        if (e.message === 'Node not found') {
          const type = "vnd.adobe.partial-upload; final_type=".concat(args.nodeData.type, "; progress=0");
          args.nodeData = await Tine.Filemanager.createNode(args.uploadId, type, [], _.get(args, 'overwrite', false));
        }
      }

      await updateTask(args);

      try {
        upload.upload();
      } catch (e) {
        reject('upload failed');
      }
    });
  }

}
// CONCATENATED MODULE: ./ux/file/UploadManager.js




Ext.ns('Ext.ux.file');
/**
 * a simple file upload manager
 * collects all uploads
 *
 * @namespace   Ext.ux.file
 * @class       Ext.ux.file.UploadManager
 */

Ext.ux.file.UploadManager = function (config) {
  Ext.apply(this, config);
  Ext.ux.file.UploadManager.superclass.constructor.apply(this, arguments);
  file_UploadQueue.workers({
    FilemanagerCreateFolderTask: CreateFolderTask_CreateFolderTask
  });
  file_UploadQueue.workers({
    FilemanagerUploadFileTask: UploadFileTask_UploadFileTask
  });
  this.queue = new file_UploadQueue({
    storage: "inmemory",
    prefix: "/Tine.Tinebase.uploads",
    timeout: 1500,
    limit: 2000,
    principle: 'fifo'
  });
  this.uploads = {};
  this.workerChannels = [];
  this.fileObjects = [];
  this.mainChannel = null;
  this.virtualNodes = {};
  this.tasks = {};
  this.addEvents(
  /**
   * @event uploadcomplete
   * Fires when the upload was done successfully
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'uploadcomplete',
  /**
   * @event uploadfailure
   * Fires when the upload failed
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'uploadfailure',
  /**
   * @event uploadprogress
   * Fires on upload progress (html5 only)
   * @param {Ext.ux.file.Upload} thistasks
   * @param {Ext.Record} Ext.ux.file.Upload.file
   * @param {XMLHttpRequestProgressEvent}
   */
  'uploadprogress',
  /**
   * @event uploadstart
   * Fires on upload progress (html5 only)
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'uploadstart',
  /**
   * @event uploadstart
   * Fires on upload progress (html5 only)
   * @param {Ext.ux.file.Upload} this
   * @param {Ext.Record} Ext.ux.file.Upload.file
   */
  'update');
};

Ext.extend(Ext.ux.file.UploadManager, Ext.util.Observable, {
  /**
   * current running uploads
   */
  runningUploads: 0,

  /**
   * max channel count, also the number of allowed concurrent uploads
   */
  maxChannels: 5,

  /**
   * @cfg (String) upload id prefix
   */
  uploadIdPrefix: "tine-upload-",

  /**
   * holds the uploads
   */
  uploads: null,

  /**
   * counts session uploads
   */
  uploadCount: 0,

  /**
   * if main channel is adding tasks to worker channels
   */
  adding: false,

  /**
   *  store the apply to all status og every batch uploads
   */
  applyToAll: [],

  /**
   *  total Upload byte of all unfinished uploads
   */
  totalUploadByte: 0,

  /**
   *  current Upload byte of all unfinished uploads
   */
  currentUploadByte: 0,

  onInitFs(fs) {
    fs.root.getFile('log.txt', {
      create: true,
      exclusive: true
    }, function (fileEntry) {
      fileEntry.isFile === true;
      fileEntry.name === 'log.txt';
      fileEntry.fullPath === '/log.txt';
    }, this.errorHandler);
  },

  errorHandler(e) {
    var msg = '';

    switch (e.code) {
      case FileError.QUOTA_EXCEEDED_ERR:
        msg = 'QUOTA_EXCEEDED_ERR';
        break;

      case FileError.NOT_FOUND_ERR:
        msg = 'NOT_FOUND_ERR';
        break;

      case FileError.SECURITY_ERR:
        msg = 'SECURITY_ERR';
        break;

      case FileError.INVALID_MODIFICATION_ERR:
        msg = 'INVALID_MODIFICATION_ERR';
        break;

      case FileError.INVALID_STATE_ERR:
        msg = 'INVALID_STATE_ERR';
        break;

      default:
        msg = 'Unknown Error';
        break;
    }

    console.log('Error: ' + msg);
  },

  /**
   * init channels
   *
   * initial all channels and events
   * resolve tasks in storage
   */
  async InitChannels() {
    this.mainChannel = this.queue.create("Channel-Upload-main");
    await this.resolveFailedUploadTasks();

    for (let i = 0; i < this.maxChannels; i++) {
      //create task
      const channel = this.queue.create("Channel-Upload-".concat(i));
      this.workerChannels.push(channel);
      channel.start().then(async () => {
        await channel.clear();
      }); // add event listener when worker channel finish the task

      channel.on('active:after', async result => {
        this.unregisterUpload(result.args.uploadId);
        await this.activateDependentTasks();
        await this.addTaskToWorkerChannel();
      });
      channel.on("error", async result => {});
    }
  },

  /**
   * check batch upload complete
   *
   * update icon in main menu, if uploads with same batch id are complete
   */
  async checkBatchUploadComplete() {
    let tasks = await this.getAllFileUploadTasks();

    const incompleteTasks = _.filter(tasks, task => {
      return task.status === 'uploading' || task.status === 'pending';
    });

    if (incompleteTasks.length === 0) {
      var _actions$;

      const actions = Tine.Tinebase.MainScreen.getMainMenu().getActionByPos(55);
      (_actions$ = actions[0]) === null || _actions$ === void 0 ? void 0 : _actions$.uploadIdle();
    }
  },

  /**
   * update task by upload id
   *
   * - keep task up to date in storage
   * - args must have uploadId
   */
  async updateTaskByArgs(args) {
    try {
      const uploadId = args.uploadId;
      const hasTask = await this.mainChannel.has(this.tasks[uploadId]._id);

      if (hasTask) {
        args.nodeData.last_upload_time = new Date().toJSON();
        let diff = {
          args: args
        };
        diff.status = diff.args.nodeData.status;
        await this.mainChannel.storage.update(this.tasks[uploadId]._id, diff);
        const task = await this.mainChannel.get(this.tasks[uploadId]._id);
        return task[0];
      }
    } catch (e) {
      return null;
    }
  },

  /**
   * queue uploads
   *
   */
  async queueUploads(
  /* any task type */
  tasks) {
    var _actions$2;

    _.each(tasks, task => {
      var _task$args, _task$args2;

      const uploadId = (_task$args = task.args) === null || _task$args === void 0 ? void 0 : _task$args.uploadId;
      this.virtualNodes[uploadId] = (_task$args2 = task.args) === null || _task$args2 === void 0 ? void 0 : _task$args2.nodeData;

      if (false
      /* filesystem accessa api */
      ) {} else {
        var _task$args3;

        const uploadFile = (_task$args3 = task.args) === null || _task$args3 === void 0 ? void 0 : _task$args3.fileObject;

        if (uploadFile) {
          this.fileObjects[uploadId] = uploadFile; // old file handle
        }
      }

      _.set(task, 'tag', _.size(task.dependencies) > 0 ? 'inactive' : 'active');
    });

    const taskIds = await this.mainChannel.addBatch(tasks);
    await this.addTaskToWorkerChannel();
    const actions = Tine.Tinebase.MainScreen.getMainMenu().getActionByPos(55);
    (_actions$2 = actions[0]) === null || _actions$2 === void 0 ? void 0 : _actions$2.uploadActive();
    return taskIds;
  },

  /**
   * get virtual node by path
   *
   * Tine.Filemanager.nodeBackendMixin.searchRecord method needs all the pending nodeData,
   * so that user can switch folders while uploading
   */
  getVirtualNodesByPath(path) {
    return _.filter(this.virtualNodes, node => {
      if (node) {
        if (node.path.endsWith('/')) {
          return node.path.replace(node.name, '') === "".concat(path, "/");
        } else {
          return node.path.replace(node.name, '') === "".concat(path);
        }
      }
    });
  },

  /**
   * remove virtual node by path
   *
   */
  removeVirtualNode(uploadId) {
    delete this.virtualNodes[uploadId];
  },

  /**
   * return inactiveChannel or activeChannel has task with on of the task.depended ids
   *
   * @param task
   * @returns {Promise<boolean>}
   */
  async hasUnmetDependencies(
  /* any task type */
  task) {
    let hasUnmetDependencies = false;
    let tasks = await this.mainChannel.getAllTasks();

    const taskIDs = _.map(_.filter(tasks, {
      tag: 'inactive'
    }), '_id');

    await _.reduce(this.workerChannels, (prev, channel) => {
      return prev.then(async () => {
        const task = await channel.getAllTasks();
        if (task.length) taskIDs.push(task._id);
        return Promise.resolve();
      });
    }, Promise.resolve());

    _.each(task.dependencies, taskId => {
      if (_.includes(taskIDs, taskId)) {
        hasUnmetDependencies = true;
      }
    });

    return hasUnmetDependencies;
  },

  /**
   * after shift task from main channel to worker channel,
   * add new taskId as dependency to all inactive tasks
   * @param oldTaskId
   * @param newTaskId
   * @returns {Promise<void>}
   */
  async addWorkerChannelDependencies(oldTaskId, newTaskId) {
    let tasks = await this.mainChannel.getAllTasks();
    const promises = [];

    _.each(_.filter(tasks, {
      tag: 'inactive'
    }), task => {
      if (_.includes(task.dependencies, oldTaskId)) {
        task.dependencies.push(newTaskId);
        promises.push(this.mainChannel.storage.update(task._id, {
          dependencies: task.dependencies
        }));
      }
    });

    await Promise.allSettled(promises);
  },

  /**
   * every upload in the upload manager gets queued initially
   *
   * @returns {String} upload id
   */
  generateUploadId() {
    return this.uploadIdPrefix + (1000 + this.uploadCount++).toString();
  },

  /**
   * returns upload by uploadId
   *
   * @param uploadId {String} upload id
   * @returns (Ext.ux.file.Upload} Upload object
   */
  getUpload(uploadId) {
    var _this$uploads$uploadI;

    const fileObject = this.fileObjects[uploadId]; // || this.getItFromLoccalStorage();

    if (this.fileObjects[uploadId] && !this.uploads[uploadId]) {
      this.uploads[uploadId] = new Ext.ux.file.Upload({
        file: this.fileObjects[uploadId],
        id: uploadId,
        isFolder: false
      });
    }

    return (_this$uploads$uploadI = this.uploads[uploadId]) !== null && _this$uploads$uploadI !== void 0 ? _this$uploads$uploadI : null;
  },

  /**
   * returns all file upload tasks in storage
   *
   * @returns (Ext.ux.file.Upload} Upload object
   */
  async getAllFileUploadTasks() {
    let fileUploadTasks = await this.mainChannel.getAllTasks();
    return _.filter(fileUploadTasks, {
      handler: 'FilemanagerUploadFileTask'
    });
  },

  /**
   * returns upload by uploadId
   *
   * @param uploadId {String} upload id
   * @returns (Ext.ux.file.Upload} Upload object
   */
  getFileObject(uploadId) {
    return this.fileObjects[uploadId]; // || this.getItFromLoccalStorage();
  },

  /**
   * remove upload from the upload manager
   *
   * @param id
   */
  unregisterUpload(id) {
    delete this.uploads[id];
  },

  /**
   * on upload complete handler
   */
  onUploadComplete() {
    Tine.Tinebase.uploadManager.runningUploads = Math.max(0, Tine.Tinebase.uploadManager.runningUploads - 1);
  },

  /**
   * on upload start handler
   */
  onUploadStart() {
    Tine.Tinebase.uploadManager.runningUploads = Math.min(Tine.Tinebase.uploadManager.maxChannels, Tine.Tinebase.uploadManager.runningUploads + 1);
  },

  /**
   *  add task to worker channel
   *  - execute when a task is completed
   *  - execute once a task is queued in main channel
   *  - it scan all worker channels , collect empty channels and add tasks to them
   *  - add new generated taskId as dependency to inactive tasks
   *
   * @returns {Promise<void>}
   */
  async addTaskToWorkerChannel() {
    // worker channels would call this method parallel , but we want to execute this method in serialize way ,
    // so we use adding flag to deal with race condition
    if (this.adding === false) {
      this.adding = true; // every time we add task to worker channel , we need to get all the tasks with tag 'active'

      let allTasks = await this.mainChannel.getAllTasks();
      const emptyChannels = []; // collect empty channels

      await _.reduce(this.workerChannels, (prev, channel) => {
        return prev.then(async () => {
          const count = await channel.count();

          if (count === 0) {
            emptyChannels.push(channel);
          }

          return Promise.resolve();
        });
      }, Promise.resolve()); // collect active tasks

      let tasks = _.filter(allTasks, {
        tag: 'active'
      }); // add tasks to worker channel , and  then add new generated taskId as dependency to inactive tasks


      await _.reduce(emptyChannels, (prev, channel) => {
        return prev.then(async () => {
          const task = _.head(tasks);

          tasks = _.drop(tasks);

          if (task) {
            const oldTaskId = task._id;
            const newTaskId = await channel.add(task);
            await this.mainChannel.storage.update(task._id, {
              tag: channel.name(),
              status: task.status
            });
            await this.addWorkerChannelDependencies(oldTaskId, newTaskId);
          }

          return Promise.resolve();
        });
      }, Promise.resolve());
      await this.checkBatchUploadComplete();
      this.adding = false;
    }
  },

  /**
   * overwrite batch uploads
   *
   * set overwrite flog for the tasks that need to be overwritten
   */
  async overwriteBatchUploads(batchID) {
    this.applyToAll[batchID] = 'replace';
    let allTasks = await this.mainChannel.getAllTasks();

    let tasks = _.filter(allTasks, task => {
      return task.args.batchID = batchID;
    });

    const promises = [];

    _.each(tasks, task => {
      task.args.overwrite = true;
      promises.push(this.mainChannel.storage.update(task._id, {
        args: task.args
      }));
    });

    await Promise.allSettled(promises);
  },

  /**
   * stop batch uploads
   *
   * in order to update batch uploads in display dialog , postal message should be called for each node
   * TODO: do we have better solution ?
   */
  async stopBatchUploads(batchID) {
    this.applyToAll[batchID] = 'stop'; // clean up WorkerChannels

    await _.reduce(this.workerChannels, (prev, channel) => {
      return prev.then(async () => {
        await channel.forceStop();
        await channel.clear();
        await channel.start();
        return Promise.resolve();
      });
    }, Promise.resolve()); // update task status in storage and ui

    let allTasks = await this.mainChannel.getAllTasks();
    const promises = [];

    _.each(allTasks, task => {
      if (task.args.batchID === batchID && task.status !== 'complete') {
        task.args.nodeData.status = 'cancelled';
        window.postal.publish({
          channel: "recordchange",
          topic: 'Filemanager.Node.update',
          data: task.args.nodeData
        });
        promises.push(this.mainChannel.storage.update(task._id, {
          args: task.args,
          status: 'failed'
        }));
        Tine.Tinebase.uploadManager.removeVirtualNode(task.args.uploadId);
      }
    });

    await Promise.allSettled(promises).then(async () => {
      await this.checkBatchUploadComplete();
      this.adding = false;
    });
  },

  /**
   * reset all upload channels
   *
   * reset all tasks in main channel and worker channels
   */
  async resetUploadChannels() {
    await this.mainChannel.stop();
    await this.mainChannel.clear();
    await _.reduce(this.workerChannels, (prev, channel) => {
      return prev.then(async () => {
        await channel.stop();
        await channel.clear();
        await channel.start();
        return Promise.resolve();
      });
    }, Promise.resolve());
    this.uploads = {};
    this.adding = false;
    await this.checkBatchUploadComplete();
  },

  /**
   * activate dependent tasks
   *
   * switch inactive task to active once all the dependencies are resolved
   */
  async activateDependentTasks() {
    let tasks = await this.mainChannel.getAllTasks();
    tasks = _.filter(tasks, {
      tag: 'inactive'
    });

    if (tasks.length > 0) {
      // move tasks to activeChannel if the dependencies task are completed
      await _.reduce(tasks, (prev, task) => {
        return prev.then(async () => {
          const dep = await this.hasUnmetDependencies(task);

          if (!dep) {
            await this.mainChannel.storage.update(task._id, {
              tag: 'active'
            });
          }

          return Promise.resolve();
        });
      }, Promise.resolve());
    }
  },

  /**
   * resolve failed upload tasks
   *
   * update status of all failed and unfinished tasks
   *
   * @returns {Promise<void>}
   */
  async resolveFailedUploadTasks() {
    const tasks = await this.getAllFileUploadTasks();
    const promises = [];

    _.each(tasks, async task => {
      const status = task.args.nodeData.status;

      if (status !== 'complete') {
        promises.push(this.mainChannel.storage.update(task._id, {
          status: 'failed'
        }));
      }
    });

    await Promise.allSettled(promises);
  }

});

/***/ }),
/* 2722 */,
/* 2723 */,
/* 2724 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXPORTS
__webpack_require__.d(__webpack_exports__, "getDataTransferFiles", function() { return /* reexport */ getDataTransferFiles; });
__webpack_require__.d(__webpack_exports__, "getDroppedOrSelectedFiles", function() { return /* reexport */ getDroppedOrSelectedFiles; });

// CONCATENATED MODULE: ./node_modules/html5-file-selector/src/Html5FileSelector.js
const DEFAULT_FILES_TO_IGNORE = [
  '.DS_Store', // OSX indexing file
  'Thumbs.db'  // Windows indexing file
];

// map of common (mostly media types) mime types to use when the browser does not supply the mime type
const EXTENSION_TO_MIME_TYPE_MAP = {
  avi: 'video/avi',
  gif: 'image/gif',
  ico: 'image/x-icon',
  jpeg: 'image/jpeg',
  jpg: 'image/jpeg',
  mkv: 'video/x-matroska',
  mov: 'video/quicktime',
  mp4: 'video/mp4',
  pdf: 'application/pdf',
  png: 'image/png',
  zip: 'application/zip'
};

function shouldIgnoreFile(file) {
  return DEFAULT_FILES_TO_IGNORE.indexOf(file.name) >= 0;
}

function copyString(aString) {
  return ` ${aString}`.slice(1);
}

function traverseDirectory(entry) {
  const reader = entry.createReader();
  // Resolved when the entire directory is traversed
  return new Promise((resolveDirectory) => {
    const iterationAttempts = [];
    const errorHandler = () => {};
    function readEntries() {
      // According to the FileSystem API spec, readEntries() must be called until
      // it calls the callback with an empty array.
      reader.readEntries((batchEntries) => {
        if (!batchEntries.length) {
          // Done iterating this particular directory
          resolveDirectory(Promise.all(iterationAttempts));
        } else {
          // Add a list of promises for each directory entry.  If the entry is itself
          // a directory, then that promise won't resolve until it is fully traversed.
          iterationAttempts.push(Promise.all(batchEntries.map((batchEntry) => {
            if (batchEntry.isDirectory) {
              return traverseDirectory(batchEntry);
            }
            return Promise.resolve(batchEntry);
          })));
          // Try calling readEntries() again for the same dir, according to spec
          readEntries();
        }
      }, errorHandler);
    }
    // initial call to recursive entry reader function
    readEntries();
  });
}

// package the file in an object that includes the fullPath from the file entry
// that would otherwise be lost
function packageFile(file, entry) {
  let fileTypeOverride = '';
  // handle some browsers sometimes missing mime types for dropped files
  const hasExtension = file.name && file.name.lastIndexOf('.') !== -1;
  if (hasExtension && !file.type) {
    const fileExtension = (file.name || '').split('.').pop();
    fileTypeOverride = EXTENSION_TO_MIME_TYPE_MAP[fileExtension];
  }
  return {
    fileObject: file, // provide access to the raw File object (required for uploading)
    fullPath: entry ? copyString(entry.fullPath) : (file.webkitRelativePath !== '' ? file.webkitRelativePath : `/${file.name}`),
    lastModified: file.lastModified,
    lastModifiedDate: file.lastModifiedDate,
    name: file.name,
    size: file.size,
    type: file.type ? file.type : fileTypeOverride,
    webkitRelativePath: file.webkitRelativePath
  };
}

function getFile(entry) {
  return new Promise((resolve) => {
    entry.file((file) => {
      resolve(packageFile(file, entry));
    });
  });
}

function handleFilePromises(promises, fileList) {
  return Promise.all(promises).then((files) => {
    files.forEach((file) => {
      if (!shouldIgnoreFile(file)) {
        fileList.push(file);
      }
    });
    return fileList;
  });
}

function getDataTransferFiles(dataTransfer) {
  const dataTransferFiles = [];
  const folderPromises = [];
  const filePromises = [];

  [].slice.call(dataTransfer.items).forEach((listItem) => {
    if (typeof listItem.webkitGetAsEntry === 'function') {
      const entry = listItem.webkitGetAsEntry();

      if (entry) {
        if (entry.isDirectory) {
          folderPromises.push(traverseDirectory(entry));
        } else {
          filePromises.push(getFile(entry));
        }
      }
    } else {
      dataTransferFiles.push(listItem);
    }
  });
  if (folderPromises.length) {
    const flatten = (array) => array.reduce((a, b) => a.concat(Array.isArray(b) ? flatten(b) : b), []);
    return Promise.all(folderPromises).then((fileEntries) => {
      const flattenedEntries = flatten(fileEntries);
      // collect async promises to convert each fileEntry into a File object
      flattenedEntries.forEach((fileEntry) => {
        filePromises.push(getFile(fileEntry));
      });
      return handleFilePromises(filePromises, dataTransferFiles);
    });
  } else if (filePromises.length) {
    return handleFilePromises(filePromises, dataTransferFiles);
  }
  return Promise.resolve(dataTransferFiles);
}

/**
 * This function should be called from both the onDrop event from your drag/drop
 * dropzone as well as from the HTML5 file selector input field onChange event
 * handler.  Pass the event object from the triggered event into this function.
 * Supports mix of files and folders dropped via drag/drop.
 *
 * Returns: an array of File objects, that includes all files within folders
 *   and subfolders of the dropped/selected items.
 */
function getDroppedOrSelectedFiles(event) {
  const dataTransfer = event.dataTransfer;
  if (dataTransfer && dataTransfer.items) {
    return getDataTransferFiles(dataTransfer).then((fileList) => {
      return Promise.resolve(fileList);
    });
  }
  const files = [];
  const dragDropFileList = dataTransfer && dataTransfer.files;
  const inputFieldFileList = event.target && event.target.files;
  const fileList = dragDropFileList || inputFieldFileList || [];
  // convert the FileList to a simple array of File objects
  for (let i = 0; i < fileList.length; i++) {
    files.push(packageFile(fileList[i]));
  }
  return Promise.resolve(files);
}

// CONCATENATED MODULE: ./node_modules/html5-file-selector/src/index.js
/**
 * Html5 File Selector
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE.txt file in the root directory of this source tree.
 */




/***/ }),
/* 2725 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// CONCATENATED MODULE: ./util/filterSpec.js
const expandFilter = (filterSpec, filter) => {
  filter = filter || [];

  if (filterSpec) {
    if (filterSpec.config) {
      filter = filter.concat(Tine.Tinebase.configManager.get(filterSpec.config.name, filterSpec.config.appName));
    } // @TODO: we might need a JSON.parse - implement when needed


    if (filterSpec.preference) {
      filter = filter.concat(Tine.Tinebase.appMgr.get(filterSpec.preference.appName).getRegistry().get('preferences').get(filterSpec.preference.name));
    }

    if (filterSpec.favorite) {
      Tine.log.warn('Implement me');
    }
  }

  return filter;
};


// CONCATENATED MODULE: ./widgets/form/RecordPickerComboBox.js
/* 
 * Tine 2.0
 * 
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2007-2008 Metaways Infosystems GmbH (http://www.metaways.de)
 */

/*global Ext, Tine*/
Ext.ns('Tine.Tinebase.widgets.form');

/**
 * @namespace   Tine.Tinebase.widgets.form
 * @author      Cornelius Weiss <c.weiss@metaways.de>
 * @class       Tine.Tinebase.widgets.form.RecordPickerComboBox
 * @extends     Ext.form.ComboBox
 * 
 * <p>Abstract base class for recordPickers like account/group pickers </p>
 * 
 * Usage:
 * <pre><code>
var resourcePicker = new Tine.Tinebase.widgets.form.RecordPickerComboBox({
    recordClass: Tine.Calendar.Model.Resource
});
   </code></pre>
 */

Tine.Tinebase.widgets.form.RecordPickerComboBox = Ext.extend(Ext.ux.form.ClearableComboBox, {
  /**
   * @cfg {bool} blurOnSelect
   * blur this combo when record got selected, useful to be used in editor grids (defaults to false)
   */
  blurOnSelect: false,

  /**
   * @cfg {Tine.Tinebase.data.Record} recordClass
   * model of record to be picked (required) 
   */
  recordClass: null,

  /**
   * @cfg {Tine.Tinebase.data.RecordProxy} recordProxy
   * record backend 
   */
  recordProxy: null,

  /**
   * @property app
   * @type Tine.Tinebase.Application
   */
  app: null,

  /**
   * @type Tine.Tinebase.data.Record selectedRecord
   * @property selectedRecord 
   * The last record which was selected
   */
  selectedRecord: null,

  /**
   * sort by field
   * 
   * @type String 
   */
  sortBy: null,

  /**
   * sort direction
   * 
   * @type String 
   */
  sortDir: 'ASC',

  /**
   * @type string
   * @property lastStoreTransactionId
   */
  lastStoreTransactionId: null,

  /**
   * if set to false, it is not possible to add the same record handled in this.editDialog
   * this.editDialog must also be set
   * 
   * @cfg {Boolean} allowLinkingItself
   */
  allowLinkingItself: null,

  /**
   * the editDialog, the form is nested in. Just needed if this.allowLinkingItself is set to false
   * 
   * @type Tine.widgets.dialog.EditDialog editDialog
   */
  editDialog: null,

  /**
   * always use additional filter
   * 
   * @type {Array}
   */
  additionalFilters: null,

  /**
   * config spec for additionalFilters
   *
   * @type: {object} e.g.
   * additionalFilterConfig: {config: { 'name': 'configName', 'appName': 'myApp'}}
   * additionalFilterConfig: {preference: {'appName': 'myApp', 'name': 'preferenceName}}
   * additionalFilterConfig: {favorite: {'appName': 'myApp', 'id': 'favoriteId', 'name': 'optionallyuseaname'}}
   */
  additionalFilterSpec: null,
  triggerAction: 'all',
  pageSize: 50,
  forceSelection: true,
  minListWidth: 300,
  // NOTE: minWidth gets not evaluated by ext - it's just a hint for consumers!
  minWidth: 180,
  initComponent: function initComponent() {
    this.app = Tine.Tinebase.appMgr.get(this.recordClass.getMeta('appName'));
    this.displayField = this.recordClass.getMeta('titleProperty');
    this.valueField = this.recordClass.getMeta('idProperty');
    this.disableClearer = !this.allowBlank;
    this.emptyText = this.emptyText || (this.readOnly || this.disabled ? '' : String.format(i18n._('Search for {0} ...'), this.recordClass.getRecordName() || _('Record')));
    this.loadingText = i18n._('Searching...');
    this.pageSize = parseInt(Tine.Tinebase.registry.get('preferences').get('pageSize'), 10) || this.pageSize;
    this.store = new Tine.Tinebase.data.RecordStore({
      remoteSort: true,
      readOnly: true,
      proxy: this.recordProxy || undefined,
      totalProperty: this.totalProperty,
      root: this.root,
      recordClass: this.recordClass
    });
    this.on('beforequery', this.onBeforeQuery, this);
    this.store.on('beforeloadrecords', this.onStoreBeforeLoadRecords, this);
    this.initTemplate();
    this.additionalFilters = expandFilter(this.additionalFilterSpec, this.additionalFilters);
    Tine.Tinebase.widgets.form.RecordPickerComboBox.superclass.initComponent.call(this);
  },

  /**
   * respect record.getTitle method
   */
  initTemplate: function initTemplate() {
    if (!this.tpl) {
      this.tpl = new Ext.XTemplate('<tpl for="."><div class="x-combo-list-item" ext:qtip="{[this.doubleEncode(values.description)]}">{[this.getTitle(values.' + this.recordClass.getMeta('idProperty') + ')]}</div></tpl>', {
        getTitle: function (id) {
          var record = this.getStore().getById(id),
              title = record ? record.getTitle() : ' ';
          return Ext.util.Format.htmlEncode(title);
        }.createDelegate(this)
      });
    }
  },
  // TODO re-init this.list if it goes away?
  // NOTE: we sometimes lose this.list (how?). prevent error by checking existence.
  doResize: function doResize(w) {
    if (!Ext.isDefined(this.listWidth) && this.list) {
      var lw = Math.max(w, this.minListWidth);
      this.list.setWidth(lw);
      this.innerList.setWidth(lw - this.list.getFrameWidth('lr'));
    }
  },

  /**
   * prepare paging and sort
   * 
   * @param {Ext.data.Store} store
   * @param {Object} options
   */
  onBeforeLoad: function onBeforeLoad(store, options) {
    Tine.Tinebase.widgets.form.RecordPickerComboBox.superclass.onBeforeLoad.call(this, store, options);
    this.lastStoreTransactionId = options.transactionId = Ext.id();
    Ext.apply(options.params, {
      sort: this.sortBy ? this.sortBy : this.displayField,
      dir: this.sortDir
    });
  },

  /**
   * onStoreBeforeLoadRecords
   * 
   * @param {Object} o
   * @param {Object} options
   * @param {Boolean} success
   * @param {Ext.data.Store} store
   */
  onStoreBeforeLoadRecords: function onStoreBeforeLoadRecords(o, options, success, store) {
    if (!this.lastStoreTransactionId || options.transactionId && this.lastStoreTransactionId !== options.transactionId) {
      Tine.log.debug('Tine.Tinebase.widgets.form.RecordPickerComboBox::onStoreBeforeLoadRecords cancelling old transaction request.');
      return false;
    }
  },

  /**
   * use beforequery to set query filter
   * 
   * @param {Object} qevent
   */
  onBeforeQuery: function onBeforeQuery(qevent) {
    var filter = [{
      field: 'query',
      operator: 'contains',
      value: qevent.query
    }];

    if (this.additionalFilters !== null && this.additionalFilters.length > 0) {
      for (var i = 0; i < this.additionalFilters.length; i++) {
        filter.push(this.additionalFilters[i]);
      }
    }

    this.store.baseParams.filter = filter;
    this.tpl.lastQuery = qevent.query;
  },

  /**
   * get last usesed query
   *
   * @returns {String}
   */
  getLastQuery: function getLastQuery() {
    return this.lastQuery;
  },

  /**
   * relay contextmenu events
   * 
   * @param {Ext.Container} ct
   * @param {Number} position
   * @private
   */
  onRender: function onRender(ct, position) {
    Tine.Tinebase.widgets.form.RecordPickerComboBox.superclass.onRender.call(this, ct, position);
    var c = this.getEl();
    this.mon(c, {
      scope: this,
      contextmenu: Ext.emptyFn
    });
    this.relayEvents(c, ['contextmenu']);
  },

  /**
   * store a copy of the selected record
   * 
   * @param {Tine.Tinebase.data.Record} record
   * @param {Number} index
   */
  onSelect: function onSelect(record, index) {
    this.selectedRecord = record;
    return Tine.Tinebase.widgets.form.RecordPickerComboBox.superclass.onSelect.call(this, record, index);
  },

  /**
   * on keypressed("enter") event to add record
   * 
   * @param {Tine.Addressbook.SearchCombo} combo
   * @param {Event} event
   */
  onSpecialkey: function onSpecialkey(combo, event) {
    if (event.getKey() === event.ENTER) {
      var id = combo.getValue();
      var record = this.store.getById(id);
      this.onSelect(record);
    }
  },

  /**
   * set value and prefill store if needed
   * 
   * @param {mixed} value
   */
  setValue: function setValue(value) {
    if (value) {
      // value is a record
      if (typeof value.get === 'function') {
        if (this.store.indexOf(value) < 0) {
          this.store.addSorted(value);
        }

        value = value.get(this.valueField);
      } // value is a js object
      else if (Ext.isObject(value)) {
          var record = this.recordProxy ? this.recordProxy.recordReader({
            responseText: Ext.encode(value)
          }) : new this.recordClass(value);

          if (!this.store.getById(value.id)) {
            this.store.addSorted(record);
          }

          value = value[this.valueField] || '';
        } // value is the current id
        else if (Ext.isPrimitive(value) && value == this.getValue()) {
            return this.setValue(this.selectedRecord);
          }
    }

    var r = value !== "" ? this.findRecord(this.valueField,
    /* id = */
    value) : null,
        text = value,
        description = '';

    if (r) {
      text = typeof r.getComboBoxTitle === "function" ? r.getComboBoxTitle() : r.getTitle();
      description = r.get('description') || description;
      this.selectedRecord = r;

      if (this.allowLinkingItself === false) {
        // check if editDialog exists
        if (this.editDialog && this.editDialog.record && r.getId() == this.editDialog.record.getId()) {
          Ext.MessageBox.show({
            title: i18n._('Failure'),
            msg: i18n._('You tried to link a record with itself. This is not allowed!'),
            buttons: Ext.MessageBox.OK,
            icon: Ext.MessageBox.ERROR
          });
          return;
        }
      }
    } else if (Ext.isDefined(this.valueNotFoundText)) {
      text = this.valueNotFoundText;
    }

    this.lastSelectionText = text;

    if (this.hiddenField) {
      this.hiddenField.value = Ext.value(value, '');
    }

    Tine.Tinebase.widgets.form.RecordPickerComboBox.superclass.setValue.call(this, text);
    var el = this.getEl();

    if (el) {
      el.set({
        qtip: Tine.Tinebase.common.doubleEncode(description)
      });
    }

    this.value = value;
    return this;
  }
});
Ext.reg('tinerecordpickercombobox', Tine.Tinebase.widgets.form.RecordPickerComboBox);

/***/ }),
/* 2726 */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXTERNAL MODULE: ./widgets/file/SelectionDialog.js
var SelectionDialog = __webpack_require__(632);

// CONCATENATED MODULE: ./widgets/file/locationRenderer.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2020 Metaways Infosystems GmbH (http://www.metaways.de)
 */

Ext.ns('Tine.Tinebase.widgets.file');

Tine.Tinebase.widgets.file.locationRenderer = function (location) {// @TODO: return invisible html and replace async with visible rendering
};

Tine.Tinebase.widgets.file.locationRenderer.getLocationPlugin = async function (location, pluginConfig) {
  if (!Tine.Tinebase.widgets.file.LocationTypePluginFactory.isRegistered(location.type)) {
    Tine.log.warn("no LocationTypePlugin for \"".concat(location.type, "\" registered"));
    return location.fileName;
  }

  return await Tine.Tinebase.widgets.file.LocationTypePluginFactory.create(location.type, _.get(pluginConfig, location.type, {}));
};

Tine.Tinebase.widgets.file.locationRenderer.getLocationHtml = async function (location, pluginConfig) {
  const plugin = await Tine.Tinebase.widgets.file.locationRenderer.getLocationPlugin(location, pluginConfig);
  return "<span cls=\"file-location-renderer ".concat(plugin.iconCls, "\">") + plugin.getLocationName(location) + "</span>";
};

Tine.Tinebase.widgets.file.locationRenderer.getLocationName = async function (location, pluginConfig) {
  const plugin = await Tine.Tinebase.widgets.file.locationRenderer.getLocationPlugin(location, pluginConfig);
  return plugin.getLocationName(location);
};
// CONCATENATED MODULE: ./widgets/file/SelectionField.js
/*
 * Tine 2.0
 *
 * @license     http://www.gnu.org/licenses/agpl.html AGPL Version 3
 * @author      Cornelius Weiß <c.weiss@metaways.de>
 * @copyright   Copyright (c) 2020 Metaways Infosystems GmbH (http://www.metaways.de)
 */
Ext.ns('Tine.Tinebase.widgets.file');

Tine.Tinebase.widgets.file.SelectionField = Ext.extend(Ext.form.TriggerField, {
  /**
   * @cfg {String} mode one of source|target
   */
  mode: 'source',

  /**
   * @cfg {String} locationTypesEnabled list of enabled plugins
   */
  locationTypesEnabled: 'fm_node,local',

  /**
   * @cfg {Boolean} allowMultiple
   * allow to select multiple fiels at once (source mode only)
   */
  allowMultiple: true,

  /**
   * @cfg {String|RegExp}
   * A constraint allows to alter the selection behaviour of the picker, for example only allow to select files.
   * By default, file and folder are allowed to be selected, the concrete implementation needs to define it's purpose
   */
  constraint: null,

  /**
   * @cfg {String} initialPath
   * initial filemanager path
   */
  initialPath: null,

  /**
   * @cfg {String} fileName
   * @property {String} fileName
   * (initial) fileName
   */
  fileName: null,

  /**
   * @cfg {Object} pluginConfig
   * config to pass to specific plugin
   * {<pluginName>: {...}}
   */
  pluginConfig: null,
  // private
  editable: false,
  onTriggerClick: function onTriggerClick() {
    Tine.Tinebase.widgets.file.SelectionDialog.openWindow(_.assign(this.getSelectionDialogConfig(), {
      listeners: {
        apply: _.bind(this.onDialogApply, this)
      }
    }));
  },
  onDialogApply: async function onDialogApply(locations) {
    await this.setValue(locations);
    this.fireEvent('select', this, locations);

    if (this.blurOnSelect) {
      this.fireEvent('blur', this);
    }

    this.validate();
  },
  setValue: async function setValue(locations) {
    this.value = _.isArray(locations) ? locations : [locations];
    Tine.Tinebase.common.assertComparable(this.value);
    const async = await __webpack_require__.e(/* import() | Tinebase/js/async */ 37).then(__webpack_require__.bind(null, 2657));
    const locationNames = await async.map(this.value, Tine.Tinebase.widgets.file.locationRenderer.getLocationName);
    this.setRawValue(_.join(locationNames, ', '));
  },
  getValue: function getValue() {
    return this.mode === 'source' && this.allowMultiple ? this.value : _.get(this.value, '[0]');
  },
  getSelectionDialogConfig: function getSelectionDialogConfig() {
    return {
      mode: this.mode,
      locationTypesEnabled: this.locationTypesEnabled,
      allowMultiple: this.allowMultiple,
      constraint: this.constraint,
      initialPath: this.initialPath,
      fileName: this.fileName,
      pluginConfig: this.pluginConfig
    };
  }
});
Ext.reg('fileselectionfield', Tine.Tinebase.widgets.file.SelectionField);

/***/ })
]]);