mirror of https://github.com/IoTcat/sakura2.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
6320 lines
803 KiB
6320 lines
803 KiB
5 years ago
|
/******/ (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] = {
|
||
|
/******/ i: moduleId,
|
||
|
/******/ l: false,
|
||
|
/******/ exports: {}
|
||
|
/******/ };
|
||
|
/******/
|
||
|
/******/ // Execute the module function
|
||
|
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
||
|
/******/
|
||
|
/******/ // Flag the module as loaded
|
||
|
/******/ module.l = 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;
|
||
|
/******/
|
||
|
/******/ // define getter function for harmony exports
|
||
|
/******/ __webpack_require__.d = function(exports, name, getter) {
|
||
|
/******/ if(!__webpack_require__.o(exports, name)) {
|
||
|
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
|
||
|
/******/ }
|
||
|
/******/ };
|
||
|
/******/
|
||
|
/******/ // define __esModule on exports
|
||
|
/******/ __webpack_require__.r = function(exports) {
|
||
|
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
||
|
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
||
|
/******/ }
|
||
|
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
||
|
/******/ };
|
||
|
/******/
|
||
|
/******/ // create a fake namespace object
|
||
|
/******/ // mode & 1: value is a module id, require it
|
||
|
/******/ // mode & 2: merge all properties of value into the ns
|
||
|
/******/ // mode & 4: return value when already ns object
|
||
|
/******/ // mode & 8|1: behave like require
|
||
|
/******/ __webpack_require__.t = function(value, mode) {
|
||
|
/******/ if(mode & 1) value = __webpack_require__(value);
|
||
|
/******/ if(mode & 8) return value;
|
||
|
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
|
||
|
/******/ var ns = Object.create(null);
|
||
|
/******/ __webpack_require__.r(ns);
|
||
|
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
|
||
|
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
|
||
|
/******/ return ns;
|
||
|
/******/ };
|
||
|
/******/
|
||
|
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
||
|
/******/ __webpack_require__.n = function(module) {
|
||
|
/******/ var getter = module && module.__esModule ?
|
||
|
/******/ function getDefault() { return module['default']; } :
|
||
|
/******/ function getModuleExports() { return module; };
|
||
|
/******/ __webpack_require__.d(getter, 'a', getter);
|
||
|
/******/ return getter;
|
||
|
/******/ };
|
||
|
/******/
|
||
|
/******/ // Object.prototype.hasOwnProperty.call
|
||
|
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
||
|
/******/
|
||
|
/******/ // __webpack_public_path__
|
||
|
/******/ __webpack_require__.p = "/dist/";
|
||
|
/******/
|
||
|
/******/
|
||
|
/******/ // Load entry module and return exports
|
||
|
/******/ return __webpack_require__(__webpack_require__.s = 0);
|
||
|
/******/ })
|
||
|
/************************************************************************/
|
||
|
/******/ ({
|
||
|
|
||
|
/***/ "./node_modules/@material/base/component.js":
|
||
|
/*!**************************************************!*\
|
||
|
!*** ./node_modules/@material/base/component.js ***!
|
||
|
\**************************************************/
|
||
|
/*! exports provided: MDCComponent, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCComponent", function() { return MDCComponent; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 MDCComponent = /** @class */ (function () {
|
||
|
function MDCComponent(root, foundation) {
|
||
|
var args = [];
|
||
|
for (var _i = 2; _i < arguments.length; _i++) {
|
||
|
args[_i - 2] = arguments[_i];
|
||
|
}
|
||
|
this.root_ = root;
|
||
|
this.initialize.apply(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__spread"](args));
|
||
|
// Note that we initialize foundation here and not within the constructor's default param so that
|
||
|
// this.root_ is defined and can be used within the foundation class.
|
||
|
this.foundation_ = foundation === undefined ? this.getDefaultFoundation() : foundation;
|
||
|
this.foundation_.init();
|
||
|
this.initialSyncWithDOM();
|
||
|
}
|
||
|
MDCComponent.attachTo = function (root) {
|
||
|
// Subclasses which extend MDCBase should provide an attachTo() method that takes a root element and
|
||
|
// returns an instantiated component with its root set to that element. Also note that in the cases of
|
||
|
// subclasses, an explicit foundation class will not have to be passed in; it will simply be initialized
|
||
|
// from getDefaultFoundation().
|
||
|
return new MDCComponent(root, new _foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]({}));
|
||
|
};
|
||
|
/* istanbul ignore next: method param only exists for typing purposes; it does not need to be unit tested */
|
||
|
MDCComponent.prototype.initialize = function () {
|
||
|
var _args = [];
|
||
|
for (var _i = 0; _i < arguments.length; _i++) {
|
||
|
_args[_i] = arguments[_i];
|
||
|
}
|
||
|
// Subclasses can override this to do any additional setup work that would be considered part of a
|
||
|
// "constructor". Essentially, it is a hook into the parent constructor before the foundation is
|
||
|
// initialized. Any additional arguments besides root and foundation will be passed in here.
|
||
|
};
|
||
|
MDCComponent.prototype.getDefaultFoundation = function () {
|
||
|
// Subclasses must override this method to return a properly configured foundation class for the
|
||
|
// component.
|
||
|
throw new Error('Subclasses must override getDefaultFoundation to return a properly configured ' +
|
||
|
'foundation class');
|
||
|
};
|
||
|
MDCComponent.prototype.initialSyncWithDOM = function () {
|
||
|
// Subclasses should override this method if they need to perform work to synchronize with a host DOM
|
||
|
// object. An example of this would be a form control wrapper that needs to synchronize its internal state
|
||
|
// to some property or attribute of the host DOM. Please note: this is *not* the place to perform DOM
|
||
|
// reads/writes that would cause layout / paint, as this is called synchronously from within the constructor.
|
||
|
};
|
||
|
MDCComponent.prototype.destroy = function () {
|
||
|
// Subclasses may implement this method to release any resources / deregister any listeners they have
|
||
|
// attached. An example of this might be deregistering a resize event from the window object.
|
||
|
this.foundation_.destroy();
|
||
|
};
|
||
|
MDCComponent.prototype.listen = function (evtType, handler, options) {
|
||
|
this.root_.addEventListener(evtType, handler, options);
|
||
|
};
|
||
|
MDCComponent.prototype.unlisten = function (evtType, handler, options) {
|
||
|
this.root_.removeEventListener(evtType, handler, options);
|
||
|
};
|
||
|
/**
|
||
|
* Fires a cross-browser-compatible custom event from the component root of the given type, with the given data.
|
||
|
*/
|
||
|
MDCComponent.prototype.emit = function (evtType, evtData, shouldBubble) {
|
||
|
if (shouldBubble === void 0) { shouldBubble = false; }
|
||
|
var evt;
|
||
|
if (typeof CustomEvent === 'function') {
|
||
|
evt = new CustomEvent(evtType, {
|
||
|
bubbles: shouldBubble,
|
||
|
detail: evtData,
|
||
|
});
|
||
|
}
|
||
|
else {
|
||
|
evt = document.createEvent('CustomEvent');
|
||
|
evt.initCustomEvent(evtType, shouldBubble, false, evtData);
|
||
|
}
|
||
|
this.root_.dispatchEvent(evt);
|
||
|
};
|
||
|
return MDCComponent;
|
||
|
}());
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCComponent);
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/base/foundation.js":
|
||
|
/*!***************************************************!*\
|
||
|
!*** ./node_modules/@material/base/foundation.js ***!
|
||
|
\***************************************************/
|
||
|
/*! exports provided: MDCFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCFoundation", function() { return MDCFoundation; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 MDCFoundation = /** @class */ (function () {
|
||
|
function MDCFoundation(adapter) {
|
||
|
if (adapter === void 0) { adapter = {}; }
|
||
|
this.adapter_ = adapter;
|
||
|
}
|
||
|
Object.defineProperty(MDCFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
// Classes extending MDCFoundation should implement this method to return an object which exports every
|
||
|
// CSS class the foundation class needs as a property. e.g. {ACTIVE: 'mdc-component--active'}
|
||
|
return {};
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCFoundation, "strings", {
|
||
|
get: function () {
|
||
|
// Classes extending MDCFoundation should implement this method to return an object which exports all
|
||
|
// semantic strings as constants. e.g. {ARIA_ROLE: 'tablist'}
|
||
|
return {};
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCFoundation, "numbers", {
|
||
|
get: function () {
|
||
|
// Classes extending MDCFoundation should implement this method to return an object which exports all
|
||
|
// of its semantic numbers as constants. e.g. {ANIMATION_DELAY_MS: 350}
|
||
|
return {};
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCFoundation, "defaultAdapter", {
|
||
|
get: function () {
|
||
|
// Classes extending MDCFoundation may choose to implement this getter in order to provide a convenient
|
||
|
// way of viewing the necessary methods of an adapter. In the future, this could also be used for adapter
|
||
|
// validation.
|
||
|
return {};
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCFoundation.prototype.init = function () {
|
||
|
// Subclasses should override this method to perform initialization routines (registering events, etc.)
|
||
|
};
|
||
|
MDCFoundation.prototype.destroy = function () {
|
||
|
// Subclasses should override this method to perform de-initialization routines (de-registering events, etc.)
|
||
|
};
|
||
|
return MDCFoundation;
|
||
|
}());
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/dom/events.js":
|
||
|
/*!**********************************************!*\
|
||
|
!*** ./node_modules/@material/dom/events.js ***!
|
||
|
\**********************************************/
|
||
|
/*! exports provided: applyPassive */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "applyPassive", function() { return applyPassive; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
/**
|
||
|
* Stores result from applyPassive to avoid redundant processing to detect
|
||
|
* passive event listener support.
|
||
|
*/
|
||
|
var supportsPassive_;
|
||
|
/**
|
||
|
* Determine whether the current browser supports passive event listeners, and
|
||
|
* if so, use them.
|
||
|
*/
|
||
|
function applyPassive(globalObj, forceRefresh) {
|
||
|
if (globalObj === void 0) { globalObj = window; }
|
||
|
if (forceRefresh === void 0) { forceRefresh = false; }
|
||
|
if (supportsPassive_ === undefined || forceRefresh) {
|
||
|
var isSupported_1 = false;
|
||
|
try {
|
||
|
globalObj.document.addEventListener('test', function () { return undefined; }, {
|
||
|
get passive() {
|
||
|
isSupported_1 = true;
|
||
|
return isSupported_1;
|
||
|
},
|
||
|
});
|
||
|
}
|
||
|
catch (e) {
|
||
|
} // tslint:disable-line:no-empty cannot throw error due to tests. tslint also disables console.log.
|
||
|
supportsPassive_ = isSupported_1;
|
||
|
}
|
||
|
return supportsPassive_ ? { passive: true } : false;
|
||
|
}
|
||
|
//# sourceMappingURL=events.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/dom/ponyfill.js":
|
||
|
/*!************************************************!*\
|
||
|
!*** ./node_modules/@material/dom/ponyfill.js ***!
|
||
|
\************************************************/
|
||
|
/*! exports provided: closest, matches */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "closest", function() { return closest; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "matches", function() { return matches; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
/**
|
||
|
* @fileoverview A "ponyfill" is a polyfill that doesn't modify the global prototype chain.
|
||
|
* This makes ponyfills safer than traditional polyfills, especially for libraries like MDC.
|
||
|
*/
|
||
|
function closest(element, selector) {
|
||
|
if (element.closest) {
|
||
|
return element.closest(selector);
|
||
|
}
|
||
|
var el = element;
|
||
|
while (el) {
|
||
|
if (matches(el, selector)) {
|
||
|
return el;
|
||
|
}
|
||
|
el = el.parentElement;
|
||
|
}
|
||
|
return null;
|
||
|
}
|
||
|
function matches(element, selector) {
|
||
|
var nativeMatches = element.matches
|
||
|
|| element.webkitMatchesSelector
|
||
|
|| element.msMatchesSelector;
|
||
|
return nativeMatches.call(element, selector);
|
||
|
}
|
||
|
//# sourceMappingURL=ponyfill.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/floating-label/component.js":
|
||
|
/*!************************************************************!*\
|
||
|
!*** ./node_modules/@material/floating-label/component.js ***!
|
||
|
\************************************************************/
|
||
|
/*! exports provided: MDCFloatingLabel */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCFloatingLabel", function() { return MDCFloatingLabel; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/floating-label/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 MDCFloatingLabel = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCFloatingLabel, _super);
|
||
|
function MDCFloatingLabel() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCFloatingLabel.attachTo = function (root) {
|
||
|
return new MDCFloatingLabel(root);
|
||
|
};
|
||
|
/**
|
||
|
* Styles the label to produce the label shake for errors.
|
||
|
* @param shouldShake If true, shakes the label by adding a CSS class; otherwise, stops shaking by removing the class.
|
||
|
*/
|
||
|
MDCFloatingLabel.prototype.shake = function (shouldShake) {
|
||
|
this.foundation_.shake(shouldShake);
|
||
|
};
|
||
|
/**
|
||
|
* Styles the label to float/dock.
|
||
|
* @param shouldFloat If true, floats the label by adding a CSS class; otherwise, docks it by removing the class.
|
||
|
*/
|
||
|
MDCFloatingLabel.prototype.float = function (shouldFloat) {
|
||
|
this.foundation_.float(shouldFloat);
|
||
|
};
|
||
|
MDCFloatingLabel.prototype.getWidth = function () {
|
||
|
return this.foundation_.getWidth();
|
||
|
};
|
||
|
MDCFloatingLabel.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = {
|
||
|
addClass: function (className) { return _this.root_.classList.add(className); },
|
||
|
removeClass: function (className) { return _this.root_.classList.remove(className); },
|
||
|
getWidth: function () { return _this.root_.scrollWidth; },
|
||
|
registerInteractionHandler: function (evtType, handler) { return _this.listen(evtType, handler); },
|
||
|
deregisterInteractionHandler: function (evtType, handler) { return _this.unlisten(evtType, handler); },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCFloatingLabelFoundation"](adapter);
|
||
|
};
|
||
|
return MDCFloatingLabel;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/floating-label/constants.js":
|
||
|
/*!************************************************************!*\
|
||
|
!*** ./node_modules/@material/floating-label/constants.js ***!
|
||
|
\************************************************************/
|
||
|
/*! exports provided: cssClasses */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 cssClasses = {
|
||
|
LABEL_FLOAT_ABOVE: 'mdc-floating-label--float-above',
|
||
|
LABEL_SHAKE: 'mdc-floating-label--shake',
|
||
|
ROOT: 'mdc-floating-label',
|
||
|
};
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/floating-label/foundation.js":
|
||
|
/*!*************************************************************!*\
|
||
|
!*** ./node_modules/@material/floating-label/foundation.js ***!
|
||
|
\*************************************************************/
|
||
|
/*! exports provided: MDCFloatingLabelFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCFloatingLabelFoundation", function() { return MDCFloatingLabelFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/floating-label/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 MDCFloatingLabelFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCFloatingLabelFoundation, _super);
|
||
|
function MDCFloatingLabelFoundation(adapter) {
|
||
|
var _this = _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCFloatingLabelFoundation.defaultAdapter, adapter)) || this;
|
||
|
_this.shakeAnimationEndHandler_ = function () { return _this.handleShakeAnimationEnd_(); };
|
||
|
return _this;
|
||
|
}
|
||
|
Object.defineProperty(MDCFloatingLabelFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCFloatingLabelFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCFloatingLabelAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
getWidth: function () { return 0; },
|
||
|
registerInteractionHandler: function () { return undefined; },
|
||
|
deregisterInteractionHandler: function () { return undefined; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCFloatingLabelFoundation.prototype.init = function () {
|
||
|
this.adapter_.registerInteractionHandler('animationend', this.shakeAnimationEndHandler_);
|
||
|
};
|
||
|
MDCFloatingLabelFoundation.prototype.destroy = function () {
|
||
|
this.adapter_.deregisterInteractionHandler('animationend', this.shakeAnimationEndHandler_);
|
||
|
};
|
||
|
/**
|
||
|
* Returns the width of the label element.
|
||
|
*/
|
||
|
MDCFloatingLabelFoundation.prototype.getWidth = function () {
|
||
|
return this.adapter_.getWidth();
|
||
|
};
|
||
|
/**
|
||
|
* Styles the label to produce a shake animation to indicate an error.
|
||
|
* @param shouldShake If true, adds the shake CSS class; otherwise, removes shake class.
|
||
|
*/
|
||
|
MDCFloatingLabelFoundation.prototype.shake = function (shouldShake) {
|
||
|
var LABEL_SHAKE = MDCFloatingLabelFoundation.cssClasses.LABEL_SHAKE;
|
||
|
if (shouldShake) {
|
||
|
this.adapter_.addClass(LABEL_SHAKE);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(LABEL_SHAKE);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Styles the label to float or dock.
|
||
|
* @param shouldFloat If true, adds the float CSS class; otherwise, removes float and shake classes to dock the label.
|
||
|
*/
|
||
|
MDCFloatingLabelFoundation.prototype.float = function (shouldFloat) {
|
||
|
var _a = MDCFloatingLabelFoundation.cssClasses, LABEL_FLOAT_ABOVE = _a.LABEL_FLOAT_ABOVE, LABEL_SHAKE = _a.LABEL_SHAKE;
|
||
|
if (shouldFloat) {
|
||
|
this.adapter_.addClass(LABEL_FLOAT_ABOVE);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(LABEL_FLOAT_ABOVE);
|
||
|
this.adapter_.removeClass(LABEL_SHAKE);
|
||
|
}
|
||
|
};
|
||
|
MDCFloatingLabelFoundation.prototype.handleShakeAnimationEnd_ = function () {
|
||
|
var LABEL_SHAKE = MDCFloatingLabelFoundation.cssClasses.LABEL_SHAKE;
|
||
|
this.adapter_.removeClass(LABEL_SHAKE);
|
||
|
};
|
||
|
return MDCFloatingLabelFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCFloatingLabelFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/line-ripple/component.js":
|
||
|
/*!*********************************************************!*\
|
||
|
!*** ./node_modules/@material/line-ripple/component.js ***!
|
||
|
\*********************************************************/
|
||
|
/*! exports provided: MDCLineRipple */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCLineRipple", function() { return MDCLineRipple; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/line-ripple/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 MDCLineRipple = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCLineRipple, _super);
|
||
|
function MDCLineRipple() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCLineRipple.attachTo = function (root) {
|
||
|
return new MDCLineRipple(root);
|
||
|
};
|
||
|
/**
|
||
|
* Activates the line ripple
|
||
|
*/
|
||
|
MDCLineRipple.prototype.activate = function () {
|
||
|
this.foundation_.activate();
|
||
|
};
|
||
|
/**
|
||
|
* Deactivates the line ripple
|
||
|
*/
|
||
|
MDCLineRipple.prototype.deactivate = function () {
|
||
|
this.foundation_.deactivate();
|
||
|
};
|
||
|
/**
|
||
|
* Sets the transform origin given a user's click location.
|
||
|
* The `rippleCenter` is the x-coordinate of the middle of the ripple.
|
||
|
*/
|
||
|
MDCLineRipple.prototype.setRippleCenter = function (xCoordinate) {
|
||
|
this.foundation_.setRippleCenter(xCoordinate);
|
||
|
};
|
||
|
MDCLineRipple.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = {
|
||
|
addClass: function (className) { return _this.root_.classList.add(className); },
|
||
|
removeClass: function (className) { return _this.root_.classList.remove(className); },
|
||
|
hasClass: function (className) { return _this.root_.classList.contains(className); },
|
||
|
setStyle: function (propertyName, value) { return _this.root_.style.setProperty(propertyName, value); },
|
||
|
registerEventHandler: function (evtType, handler) { return _this.listen(evtType, handler); },
|
||
|
deregisterEventHandler: function (evtType, handler) { return _this.unlisten(evtType, handler); },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCLineRippleFoundation"](adapter);
|
||
|
};
|
||
|
return MDCLineRipple;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/line-ripple/constants.js":
|
||
|
/*!*********************************************************!*\
|
||
|
!*** ./node_modules/@material/line-ripple/constants.js ***!
|
||
|
\*********************************************************/
|
||
|
/*! exports provided: cssClasses */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 cssClasses = {
|
||
|
LINE_RIPPLE_ACTIVE: 'mdc-line-ripple--active',
|
||
|
LINE_RIPPLE_DEACTIVATING: 'mdc-line-ripple--deactivating',
|
||
|
};
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/line-ripple/foundation.js":
|
||
|
/*!**********************************************************!*\
|
||
|
!*** ./node_modules/@material/line-ripple/foundation.js ***!
|
||
|
\**********************************************************/
|
||
|
/*! exports provided: MDCLineRippleFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCLineRippleFoundation", function() { return MDCLineRippleFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/line-ripple/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 MDCLineRippleFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCLineRippleFoundation, _super);
|
||
|
function MDCLineRippleFoundation(adapter) {
|
||
|
var _this = _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCLineRippleFoundation.defaultAdapter, adapter)) || this;
|
||
|
_this.transitionEndHandler_ = function (evt) { return _this.handleTransitionEnd(evt); };
|
||
|
return _this;
|
||
|
}
|
||
|
Object.defineProperty(MDCLineRippleFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCLineRippleFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCLineRippleAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
hasClass: function () { return false; },
|
||
|
setStyle: function () { return undefined; },
|
||
|
registerEventHandler: function () { return undefined; },
|
||
|
deregisterEventHandler: function () { return undefined; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCLineRippleFoundation.prototype.init = function () {
|
||
|
this.adapter_.registerEventHandler('transitionend', this.transitionEndHandler_);
|
||
|
};
|
||
|
MDCLineRippleFoundation.prototype.destroy = function () {
|
||
|
this.adapter_.deregisterEventHandler('transitionend', this.transitionEndHandler_);
|
||
|
};
|
||
|
MDCLineRippleFoundation.prototype.activate = function () {
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].LINE_RIPPLE_DEACTIVATING);
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].LINE_RIPPLE_ACTIVE);
|
||
|
};
|
||
|
MDCLineRippleFoundation.prototype.setRippleCenter = function (xCoordinate) {
|
||
|
this.adapter_.setStyle('transform-origin', xCoordinate + "px center");
|
||
|
};
|
||
|
MDCLineRippleFoundation.prototype.deactivate = function () {
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].LINE_RIPPLE_DEACTIVATING);
|
||
|
};
|
||
|
MDCLineRippleFoundation.prototype.handleTransitionEnd = function (evt) {
|
||
|
// Wait for the line ripple to be either transparent or opaque
|
||
|
// before emitting the animation end event
|
||
|
var isDeactivating = this.adapter_.hasClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].LINE_RIPPLE_DEACTIVATING);
|
||
|
if (evt.propertyName === 'opacity') {
|
||
|
if (isDeactivating) {
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].LINE_RIPPLE_ACTIVE);
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].LINE_RIPPLE_DEACTIVATING);
|
||
|
}
|
||
|
}
|
||
|
};
|
||
|
return MDCLineRippleFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCLineRippleFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/notched-outline/component.js":
|
||
|
/*!*************************************************************!*\
|
||
|
!*** ./node_modules/@material/notched-outline/component.js ***!
|
||
|
\*************************************************************/
|
||
|
/*! exports provided: MDCNotchedOutline */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCNotchedOutline", function() { return MDCNotchedOutline; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _material_floating_label_foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @material/floating-label/foundation */ "./node_modules/@material/floating-label/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/notched-outline/constants.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/notched-outline/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2017 Google Inc.
|
||
|
*
|
||
|
* 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 MDCNotchedOutline = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCNotchedOutline, _super);
|
||
|
function MDCNotchedOutline() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCNotchedOutline.attachTo = function (root) {
|
||
|
return new MDCNotchedOutline(root);
|
||
|
};
|
||
|
MDCNotchedOutline.prototype.initialSyncWithDOM = function () {
|
||
|
this.notchElement_ = this.root_.querySelector(_constants__WEBPACK_IMPORTED_MODULE_3__["strings"].NOTCH_ELEMENT_SELECTOR);
|
||
|
var label = this.root_.querySelector('.' + _material_floating_label_foundation__WEBPACK_IMPORTED_MODULE_2__["MDCFloatingLabelFoundation"].cssClasses.ROOT);
|
||
|
if (label) {
|
||
|
label.style.transitionDuration = '0s';
|
||
|
this.root_.classList.add(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].OUTLINE_UPGRADED);
|
||
|
requestAnimationFrame(function () {
|
||
|
label.style.transitionDuration = '';
|
||
|
});
|
||
|
}
|
||
|
else {
|
||
|
this.root_.classList.add(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].NO_LABEL);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Updates classes and styles to open the notch to the specified width.
|
||
|
* @param notchWidth The notch width in the outline.
|
||
|
*/
|
||
|
MDCNotchedOutline.prototype.notch = function (notchWidth) {
|
||
|
this.foundation_.notch(notchWidth);
|
||
|
};
|
||
|
/**
|
||
|
* Updates classes and styles to close the notch.
|
||
|
*/
|
||
|
MDCNotchedOutline.prototype.closeNotch = function () {
|
||
|
this.foundation_.closeNotch();
|
||
|
};
|
||
|
MDCNotchedOutline.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = {
|
||
|
addClass: function (className) { return _this.root_.classList.add(className); },
|
||
|
removeClass: function (className) { return _this.root_.classList.remove(className); },
|
||
|
setNotchWidthProperty: function (width) { return _this.notchElement_.style.setProperty('width', width + 'px'); },
|
||
|
removeNotchWidthProperty: function () { return _this.notchElement_.style.removeProperty('width'); },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_4__["MDCNotchedOutlineFoundation"](adapter);
|
||
|
};
|
||
|
return MDCNotchedOutline;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/notched-outline/constants.js":
|
||
|
/*!*************************************************************!*\
|
||
|
!*** ./node_modules/@material/notched-outline/constants.js ***!
|
||
|
\*************************************************************/
|
||
|
/*! exports provided: cssClasses, numbers, strings */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return numbers; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 strings = {
|
||
|
NOTCH_ELEMENT_SELECTOR: '.mdc-notched-outline__notch',
|
||
|
};
|
||
|
var numbers = {
|
||
|
// This should stay in sync with $mdc-notched-outline-padding * 2.
|
||
|
NOTCH_ELEMENT_PADDING: 8,
|
||
|
};
|
||
|
var cssClasses = {
|
||
|
NO_LABEL: 'mdc-notched-outline--no-label',
|
||
|
OUTLINE_NOTCHED: 'mdc-notched-outline--notched',
|
||
|
OUTLINE_UPGRADED: 'mdc-notched-outline--upgraded',
|
||
|
};
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/notched-outline/foundation.js":
|
||
|
/*!**************************************************************!*\
|
||
|
!*** ./node_modules/@material/notched-outline/foundation.js ***!
|
||
|
\**************************************************************/
|
||
|
/*! exports provided: MDCNotchedOutlineFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCNotchedOutlineFoundation", function() { return MDCNotchedOutlineFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/notched-outline/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2017 Google Inc.
|
||
|
*
|
||
|
* 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 MDCNotchedOutlineFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCNotchedOutlineFoundation, _super);
|
||
|
function MDCNotchedOutlineFoundation(adapter) {
|
||
|
return _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCNotchedOutlineFoundation.defaultAdapter, adapter)) || this;
|
||
|
}
|
||
|
Object.defineProperty(MDCNotchedOutlineFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCNotchedOutlineFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCNotchedOutlineFoundation, "numbers", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCNotchedOutlineFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCNotchedOutlineAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
setNotchWidthProperty: function () { return undefined; },
|
||
|
removeNotchWidthProperty: function () { return undefined; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
/**
|
||
|
* Adds the outline notched selector and updates the notch width calculated based off of notchWidth.
|
||
|
*/
|
||
|
MDCNotchedOutlineFoundation.prototype.notch = function (notchWidth) {
|
||
|
var OUTLINE_NOTCHED = MDCNotchedOutlineFoundation.cssClasses.OUTLINE_NOTCHED;
|
||
|
if (notchWidth > 0) {
|
||
|
notchWidth += _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"].NOTCH_ELEMENT_PADDING; // Add padding from left/right.
|
||
|
}
|
||
|
this.adapter_.setNotchWidthProperty(notchWidth);
|
||
|
this.adapter_.addClass(OUTLINE_NOTCHED);
|
||
|
};
|
||
|
/**
|
||
|
* Removes notched outline selector to close the notch in the outline.
|
||
|
*/
|
||
|
MDCNotchedOutlineFoundation.prototype.closeNotch = function () {
|
||
|
var OUTLINE_NOTCHED = MDCNotchedOutlineFoundation.cssClasses.OUTLINE_NOTCHED;
|
||
|
this.adapter_.removeClass(OUTLINE_NOTCHED);
|
||
|
this.adapter_.removeNotchWidthProperty();
|
||
|
};
|
||
|
return MDCNotchedOutlineFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCNotchedOutlineFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/ripple/component.js":
|
||
|
/*!****************************************************!*\
|
||
|
!*** ./node_modules/@material/ripple/component.js ***!
|
||
|
\****************************************************/
|
||
|
/*! exports provided: MDCRipple */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCRipple", function() { return MDCRipple; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _material_dom_events__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @material/dom/events */ "./node_modules/@material/dom/events.js");
|
||
|
/* harmony import */ var _material_dom_ponyfill__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @material/dom/ponyfill */ "./node_modules/@material/dom/ponyfill.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/ripple/foundation.js");
|
||
|
/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./util */ "./node_modules/@material/ripple/util.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 MDCRipple = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCRipple, _super);
|
||
|
function MDCRipple() {
|
||
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
||
|
_this.disabled = false;
|
||
|
return _this;
|
||
|
}
|
||
|
MDCRipple.attachTo = function (root, opts) {
|
||
|
if (opts === void 0) { opts = { isUnbounded: undefined }; }
|
||
|
var ripple = new MDCRipple(root);
|
||
|
// Only override unbounded behavior if option is explicitly specified
|
||
|
if (opts.isUnbounded !== undefined) {
|
||
|
ripple.unbounded = opts.isUnbounded;
|
||
|
}
|
||
|
return ripple;
|
||
|
};
|
||
|
MDCRipple.createAdapter = function (instance) {
|
||
|
return {
|
||
|
addClass: function (className) { return instance.root_.classList.add(className); },
|
||
|
browserSupportsCssVars: function () { return _util__WEBPACK_IMPORTED_MODULE_5__["supportsCssVariables"](window); },
|
||
|
computeBoundingRect: function () { return instance.root_.getBoundingClientRect(); },
|
||
|
containsEventTarget: function (target) { return instance.root_.contains(target); },
|
||
|
deregisterDocumentInteractionHandler: function (evtType, handler) {
|
||
|
return document.documentElement.removeEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
},
|
||
|
deregisterInteractionHandler: function (evtType, handler) {
|
||
|
return instance.root_.removeEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
},
|
||
|
deregisterResizeHandler: function (handler) { return window.removeEventListener('resize', handler); },
|
||
|
getWindowPageOffset: function () { return ({ x: window.pageXOffset, y: window.pageYOffset }); },
|
||
|
isSurfaceActive: function () { return Object(_material_dom_ponyfill__WEBPACK_IMPORTED_MODULE_3__["matches"])(instance.root_, ':active'); },
|
||
|
isSurfaceDisabled: function () { return Boolean(instance.disabled); },
|
||
|
isUnbounded: function () { return Boolean(instance.unbounded); },
|
||
|
registerDocumentInteractionHandler: function (evtType, handler) {
|
||
|
return document.documentElement.addEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
},
|
||
|
registerInteractionHandler: function (evtType, handler) {
|
||
|
return instance.root_.addEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
},
|
||
|
registerResizeHandler: function (handler) { return window.addEventListener('resize', handler); },
|
||
|
removeClass: function (className) { return instance.root_.classList.remove(className); },
|
||
|
updateCssVariable: function (varName, value) { return instance.root_.style.setProperty(varName, value); },
|
||
|
};
|
||
|
};
|
||
|
Object.defineProperty(MDCRipple.prototype, "unbounded", {
|
||
|
get: function () {
|
||
|
return Boolean(this.unbounded_);
|
||
|
},
|
||
|
set: function (unbounded) {
|
||
|
this.unbounded_ = Boolean(unbounded);
|
||
|
this.setUnbounded_();
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCRipple.prototype.activate = function () {
|
||
|
this.foundation_.activate();
|
||
|
};
|
||
|
MDCRipple.prototype.deactivate = function () {
|
||
|
this.foundation_.deactivate();
|
||
|
};
|
||
|
MDCRipple.prototype.layout = function () {
|
||
|
this.foundation_.layout();
|
||
|
};
|
||
|
MDCRipple.prototype.getDefaultFoundation = function () {
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_4__["MDCRippleFoundation"](MDCRipple.createAdapter(this));
|
||
|
};
|
||
|
MDCRipple.prototype.initialSyncWithDOM = function () {
|
||
|
var root = this.root_;
|
||
|
this.unbounded = 'mdcRippleIsUnbounded' in root.dataset;
|
||
|
};
|
||
|
/**
|
||
|
* Closure Compiler throws an access control error when directly accessing a
|
||
|
* protected or private property inside a getter/setter, like unbounded above.
|
||
|
* By accessing the protected property inside a method, we solve that problem.
|
||
|
* That's why this function exists.
|
||
|
*/
|
||
|
MDCRipple.prototype.setUnbounded_ = function () {
|
||
|
this.foundation_.setUnbounded(Boolean(this.unbounded_));
|
||
|
};
|
||
|
return MDCRipple;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/ripple/constants.js":
|
||
|
/*!****************************************************!*\
|
||
|
!*** ./node_modules/@material/ripple/constants.js ***!
|
||
|
\****************************************************/
|
||
|
/*! exports provided: cssClasses, strings, numbers */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return numbers; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 cssClasses = {
|
||
|
// Ripple is a special case where the "root" component is really a "mixin" of sorts,
|
||
|
// given that it's an 'upgrade' to an existing component. That being said it is the root
|
||
|
// CSS class that all other CSS classes derive from.
|
||
|
BG_FOCUSED: 'mdc-ripple-upgraded--background-focused',
|
||
|
FG_ACTIVATION: 'mdc-ripple-upgraded--foreground-activation',
|
||
|
FG_DEACTIVATION: 'mdc-ripple-upgraded--foreground-deactivation',
|
||
|
ROOT: 'mdc-ripple-upgraded',
|
||
|
UNBOUNDED: 'mdc-ripple-upgraded--unbounded',
|
||
|
};
|
||
|
var strings = {
|
||
|
VAR_FG_SCALE: '--mdc-ripple-fg-scale',
|
||
|
VAR_FG_SIZE: '--mdc-ripple-fg-size',
|
||
|
VAR_FG_TRANSLATE_END: '--mdc-ripple-fg-translate-end',
|
||
|
VAR_FG_TRANSLATE_START: '--mdc-ripple-fg-translate-start',
|
||
|
VAR_LEFT: '--mdc-ripple-left',
|
||
|
VAR_TOP: '--mdc-ripple-top',
|
||
|
};
|
||
|
var numbers = {
|
||
|
DEACTIVATION_TIMEOUT_MS: 225,
|
||
|
FG_DEACTIVATION_MS: 150,
|
||
|
INITIAL_ORIGIN_SCALE: 0.6,
|
||
|
PADDING: 10,
|
||
|
TAP_DELAY_MS: 300,
|
||
|
};
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/ripple/foundation.js":
|
||
|
/*!*****************************************************!*\
|
||
|
!*** ./node_modules/@material/ripple/foundation.js ***!
|
||
|
\*****************************************************/
|
||
|
/*! exports provided: MDCRippleFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCRippleFoundation", function() { return MDCRippleFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/ripple/constants.js");
|
||
|
/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./util */ "./node_modules/@material/ripple/util.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
// Activation events registered on the root element of each instance for activation
|
||
|
var ACTIVATION_EVENT_TYPES = [
|
||
|
'touchstart', 'pointerdown', 'mousedown', 'keydown',
|
||
|
];
|
||
|
// Deactivation events registered on documentElement when a pointer-related down event occurs
|
||
|
var POINTER_DEACTIVATION_EVENT_TYPES = [
|
||
|
'touchend', 'pointerup', 'mouseup', 'contextmenu',
|
||
|
];
|
||
|
// simultaneous nested activations
|
||
|
var activatedTargets = [];
|
||
|
var MDCRippleFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCRippleFoundation, _super);
|
||
|
function MDCRippleFoundation(adapter) {
|
||
|
var _this = _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCRippleFoundation.defaultAdapter, adapter)) || this;
|
||
|
_this.activationAnimationHasEnded_ = false;
|
||
|
_this.activationTimer_ = 0;
|
||
|
_this.fgDeactivationRemovalTimer_ = 0;
|
||
|
_this.fgScale_ = '0';
|
||
|
_this.frame_ = { width: 0, height: 0 };
|
||
|
_this.initialSize_ = 0;
|
||
|
_this.layoutFrame_ = 0;
|
||
|
_this.maxRadius_ = 0;
|
||
|
_this.unboundedCoords_ = { left: 0, top: 0 };
|
||
|
_this.activationState_ = _this.defaultActivationState_();
|
||
|
_this.activationTimerCallback_ = function () {
|
||
|
_this.activationAnimationHasEnded_ = true;
|
||
|
_this.runDeactivationUXLogicIfReady_();
|
||
|
};
|
||
|
_this.activateHandler_ = function (e) { return _this.activate_(e); };
|
||
|
_this.deactivateHandler_ = function () { return _this.deactivate_(); };
|
||
|
_this.focusHandler_ = function () { return _this.handleFocus(); };
|
||
|
_this.blurHandler_ = function () { return _this.handleBlur(); };
|
||
|
_this.resizeHandler_ = function () { return _this.layout(); };
|
||
|
return _this;
|
||
|
}
|
||
|
Object.defineProperty(MDCRippleFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCRippleFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCRippleFoundation, "numbers", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCRippleFoundation, "defaultAdapter", {
|
||
|
get: function () {
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
browserSupportsCssVars: function () { return true; },
|
||
|
computeBoundingRect: function () { return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 }); },
|
||
|
containsEventTarget: function () { return true; },
|
||
|
deregisterDocumentInteractionHandler: function () { return undefined; },
|
||
|
deregisterInteractionHandler: function () { return undefined; },
|
||
|
deregisterResizeHandler: function () { return undefined; },
|
||
|
getWindowPageOffset: function () { return ({ x: 0, y: 0 }); },
|
||
|
isSurfaceActive: function () { return true; },
|
||
|
isSurfaceDisabled: function () { return true; },
|
||
|
isUnbounded: function () { return true; },
|
||
|
registerDocumentInteractionHandler: function () { return undefined; },
|
||
|
registerInteractionHandler: function () { return undefined; },
|
||
|
registerResizeHandler: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
updateCssVariable: function () { return undefined; },
|
||
|
};
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCRippleFoundation.prototype.init = function () {
|
||
|
var _this = this;
|
||
|
var supportsPressRipple = this.supportsPressRipple_();
|
||
|
this.registerRootHandlers_(supportsPressRipple);
|
||
|
if (supportsPressRipple) {
|
||
|
var _a = MDCRippleFoundation.cssClasses, ROOT_1 = _a.ROOT, UNBOUNDED_1 = _a.UNBOUNDED;
|
||
|
requestAnimationFrame(function () {
|
||
|
_this.adapter_.addClass(ROOT_1);
|
||
|
if (_this.adapter_.isUnbounded()) {
|
||
|
_this.adapter_.addClass(UNBOUNDED_1);
|
||
|
// Unbounded ripples need layout logic applied immediately to set coordinates for both shade and ripple
|
||
|
_this.layoutInternal_();
|
||
|
}
|
||
|
});
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.destroy = function () {
|
||
|
var _this = this;
|
||
|
if (this.supportsPressRipple_()) {
|
||
|
if (this.activationTimer_) {
|
||
|
clearTimeout(this.activationTimer_);
|
||
|
this.activationTimer_ = 0;
|
||
|
this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_ACTIVATION);
|
||
|
}
|
||
|
if (this.fgDeactivationRemovalTimer_) {
|
||
|
clearTimeout(this.fgDeactivationRemovalTimer_);
|
||
|
this.fgDeactivationRemovalTimer_ = 0;
|
||
|
this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_DEACTIVATION);
|
||
|
}
|
||
|
var _a = MDCRippleFoundation.cssClasses, ROOT_2 = _a.ROOT, UNBOUNDED_2 = _a.UNBOUNDED;
|
||
|
requestAnimationFrame(function () {
|
||
|
_this.adapter_.removeClass(ROOT_2);
|
||
|
_this.adapter_.removeClass(UNBOUNDED_2);
|
||
|
_this.removeCssVars_();
|
||
|
});
|
||
|
}
|
||
|
this.deregisterRootHandlers_();
|
||
|
this.deregisterDeactivationHandlers_();
|
||
|
};
|
||
|
/**
|
||
|
* @param evt Optional event containing position information.
|
||
|
*/
|
||
|
MDCRippleFoundation.prototype.activate = function (evt) {
|
||
|
this.activate_(evt);
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.deactivate = function () {
|
||
|
this.deactivate_();
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.layout = function () {
|
||
|
var _this = this;
|
||
|
if (this.layoutFrame_) {
|
||
|
cancelAnimationFrame(this.layoutFrame_);
|
||
|
}
|
||
|
this.layoutFrame_ = requestAnimationFrame(function () {
|
||
|
_this.layoutInternal_();
|
||
|
_this.layoutFrame_ = 0;
|
||
|
});
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.setUnbounded = function (unbounded) {
|
||
|
var UNBOUNDED = MDCRippleFoundation.cssClasses.UNBOUNDED;
|
||
|
if (unbounded) {
|
||
|
this.adapter_.addClass(UNBOUNDED);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(UNBOUNDED);
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.handleFocus = function () {
|
||
|
var _this = this;
|
||
|
requestAnimationFrame(function () {
|
||
|
return _this.adapter_.addClass(MDCRippleFoundation.cssClasses.BG_FOCUSED);
|
||
|
});
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.handleBlur = function () {
|
||
|
var _this = this;
|
||
|
requestAnimationFrame(function () {
|
||
|
return _this.adapter_.removeClass(MDCRippleFoundation.cssClasses.BG_FOCUSED);
|
||
|
});
|
||
|
};
|
||
|
/**
|
||
|
* We compute this property so that we are not querying information about the client
|
||
|
* until the point in time where the foundation requests it. This prevents scenarios where
|
||
|
* client-side feature-detection may happen too early, such as when components are rendered on the server
|
||
|
* and then initialized at mount time on the client.
|
||
|
*/
|
||
|
MDCRippleFoundation.prototype.supportsPressRipple_ = function () {
|
||
|
return this.adapter_.browserSupportsCssVars();
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.defaultActivationState_ = function () {
|
||
|
return {
|
||
|
activationEvent: undefined,
|
||
|
hasDeactivationUXRun: false,
|
||
|
isActivated: false,
|
||
|
isProgrammatic: false,
|
||
|
wasActivatedByPointer: false,
|
||
|
wasElementMadeActive: false,
|
||
|
};
|
||
|
};
|
||
|
/**
|
||
|
* supportsPressRipple Passed from init to save a redundant function call
|
||
|
*/
|
||
|
MDCRippleFoundation.prototype.registerRootHandlers_ = function (supportsPressRipple) {
|
||
|
var _this = this;
|
||
|
if (supportsPressRipple) {
|
||
|
ACTIVATION_EVENT_TYPES.forEach(function (evtType) {
|
||
|
_this.adapter_.registerInteractionHandler(evtType, _this.activateHandler_);
|
||
|
});
|
||
|
if (this.adapter_.isUnbounded()) {
|
||
|
this.adapter_.registerResizeHandler(this.resizeHandler_);
|
||
|
}
|
||
|
}
|
||
|
this.adapter_.registerInteractionHandler('focus', this.focusHandler_);
|
||
|
this.adapter_.registerInteractionHandler('blur', this.blurHandler_);
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.registerDeactivationHandlers_ = function (evt) {
|
||
|
var _this = this;
|
||
|
if (evt.type === 'keydown') {
|
||
|
this.adapter_.registerInteractionHandler('keyup', this.deactivateHandler_);
|
||
|
}
|
||
|
else {
|
||
|
POINTER_DEACTIVATION_EVENT_TYPES.forEach(function (evtType) {
|
||
|
_this.adapter_.registerDocumentInteractionHandler(evtType, _this.deactivateHandler_);
|
||
|
});
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.deregisterRootHandlers_ = function () {
|
||
|
var _this = this;
|
||
|
ACTIVATION_EVENT_TYPES.forEach(function (evtType) {
|
||
|
_this.adapter_.deregisterInteractionHandler(evtType, _this.activateHandler_);
|
||
|
});
|
||
|
this.adapter_.deregisterInteractionHandler('focus', this.focusHandler_);
|
||
|
this.adapter_.deregisterInteractionHandler('blur', this.blurHandler_);
|
||
|
if (this.adapter_.isUnbounded()) {
|
||
|
this.adapter_.deregisterResizeHandler(this.resizeHandler_);
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.deregisterDeactivationHandlers_ = function () {
|
||
|
var _this = this;
|
||
|
this.adapter_.deregisterInteractionHandler('keyup', this.deactivateHandler_);
|
||
|
POINTER_DEACTIVATION_EVENT_TYPES.forEach(function (evtType) {
|
||
|
_this.adapter_.deregisterDocumentInteractionHandler(evtType, _this.deactivateHandler_);
|
||
|
});
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.removeCssVars_ = function () {
|
||
|
var _this = this;
|
||
|
var rippleStrings = MDCRippleFoundation.strings;
|
||
|
var keys = Object.keys(rippleStrings);
|
||
|
keys.forEach(function (key) {
|
||
|
if (key.indexOf('VAR_') === 0) {
|
||
|
_this.adapter_.updateCssVariable(rippleStrings[key], null);
|
||
|
}
|
||
|
});
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.activate_ = function (evt) {
|
||
|
var _this = this;
|
||
|
if (this.adapter_.isSurfaceDisabled()) {
|
||
|
return;
|
||
|
}
|
||
|
var activationState = this.activationState_;
|
||
|
if (activationState.isActivated) {
|
||
|
return;
|
||
|
}
|
||
|
// Avoid reacting to follow-on events fired by touch device after an already-processed user interaction
|
||
|
var previousActivationEvent = this.previousActivationEvent_;
|
||
|
var isSameInteraction = previousActivationEvent && evt !== undefined && previousActivationEvent.type !== evt.type;
|
||
|
if (isSameInteraction) {
|
||
|
return;
|
||
|
}
|
||
|
activationState.isActivated = true;
|
||
|
activationState.isProgrammatic = evt === undefined;
|
||
|
activationState.activationEvent = evt;
|
||
|
activationState.wasActivatedByPointer = activationState.isProgrammatic ? false : evt !== undefined && (evt.type === 'mousedown' || evt.type === 'touchstart' || evt.type === 'pointerdown');
|
||
|
var hasActivatedChild = evt !== undefined && activatedTargets.length > 0 && activatedTargets.some(function (target) { return _this.adapter_.containsEventTarget(target); });
|
||
|
if (hasActivatedChild) {
|
||
|
// Immediately reset activation state, while preserving logic that prevents touch follow-on events
|
||
|
this.resetActivationState_();
|
||
|
return;
|
||
|
}
|
||
|
if (evt !== undefined) {
|
||
|
activatedTargets.push(evt.target);
|
||
|
this.registerDeactivationHandlers_(evt);
|
||
|
}
|
||
|
activationState.wasElementMadeActive = this.checkElementMadeActive_(evt);
|
||
|
if (activationState.wasElementMadeActive) {
|
||
|
this.animateActivation_();
|
||
|
}
|
||
|
requestAnimationFrame(function () {
|
||
|
// Reset array on next frame after the current event has had a chance to bubble to prevent ancestor ripples
|
||
|
activatedTargets = [];
|
||
|
if (!activationState.wasElementMadeActive
|
||
|
&& evt !== undefined
|
||
|
&& (evt.key === ' ' || evt.keyCode === 32)) {
|
||
|
// If space was pressed, try again within an rAF call to detect :active, because different UAs report
|
||
|
// active states inconsistently when they're called within event handling code:
|
||
|
// - https://bugs.chromium.org/p/chromium/issues/detail?id=635971
|
||
|
// - https://bugzilla.mozilla.org/show_bug.cgi?id=1293741
|
||
|
// We try first outside rAF to support Edge, which does not exhibit this problem, but will crash if a CSS
|
||
|
// variable is set within a rAF callback for a submit button interaction (#2241).
|
||
|
activationState.wasElementMadeActive = _this.checkElementMadeActive_(evt);
|
||
|
if (activationState.wasElementMadeActive) {
|
||
|
_this.animateActivation_();
|
||
|
}
|
||
|
}
|
||
|
if (!activationState.wasElementMadeActive) {
|
||
|
// Reset activation state immediately if element was not made active.
|
||
|
_this.activationState_ = _this.defaultActivationState_();
|
||
|
}
|
||
|
});
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.checkElementMadeActive_ = function (evt) {
|
||
|
return (evt !== undefined && evt.type === 'keydown') ? this.adapter_.isSurfaceActive() : true;
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.animateActivation_ = function () {
|
||
|
var _this = this;
|
||
|
var _a = MDCRippleFoundation.strings, VAR_FG_TRANSLATE_START = _a.VAR_FG_TRANSLATE_START, VAR_FG_TRANSLATE_END = _a.VAR_FG_TRANSLATE_END;
|
||
|
var _b = MDCRippleFoundation.cssClasses, FG_DEACTIVATION = _b.FG_DEACTIVATION, FG_ACTIVATION = _b.FG_ACTIVATION;
|
||
|
var DEACTIVATION_TIMEOUT_MS = MDCRippleFoundation.numbers.DEACTIVATION_TIMEOUT_MS;
|
||
|
this.layoutInternal_();
|
||
|
var translateStart = '';
|
||
|
var translateEnd = '';
|
||
|
if (!this.adapter_.isUnbounded()) {
|
||
|
var _c = this.getFgTranslationCoordinates_(), startPoint = _c.startPoint, endPoint = _c.endPoint;
|
||
|
translateStart = startPoint.x + "px, " + startPoint.y + "px";
|
||
|
translateEnd = endPoint.x + "px, " + endPoint.y + "px";
|
||
|
}
|
||
|
this.adapter_.updateCssVariable(VAR_FG_TRANSLATE_START, translateStart);
|
||
|
this.adapter_.updateCssVariable(VAR_FG_TRANSLATE_END, translateEnd);
|
||
|
// Cancel any ongoing activation/deactivation animations
|
||
|
clearTimeout(this.activationTimer_);
|
||
|
clearTimeout(this.fgDeactivationRemovalTimer_);
|
||
|
this.rmBoundedActivationClasses_();
|
||
|
this.adapter_.removeClass(FG_DEACTIVATION);
|
||
|
// Force layout in order to re-trigger the animation.
|
||
|
this.adapter_.computeBoundingRect();
|
||
|
this.adapter_.addClass(FG_ACTIVATION);
|
||
|
this.activationTimer_ = setTimeout(function () { return _this.activationTimerCallback_(); }, DEACTIVATION_TIMEOUT_MS);
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.getFgTranslationCoordinates_ = function () {
|
||
|
var _a = this.activationState_, activationEvent = _a.activationEvent, wasActivatedByPointer = _a.wasActivatedByPointer;
|
||
|
var startPoint;
|
||
|
if (wasActivatedByPointer) {
|
||
|
startPoint = Object(_util__WEBPACK_IMPORTED_MODULE_3__["getNormalizedEventCoords"])(activationEvent, this.adapter_.getWindowPageOffset(), this.adapter_.computeBoundingRect());
|
||
|
}
|
||
|
else {
|
||
|
startPoint = {
|
||
|
x: this.frame_.width / 2,
|
||
|
y: this.frame_.height / 2,
|
||
|
};
|
||
|
}
|
||
|
// Center the element around the start point.
|
||
|
startPoint = {
|
||
|
x: startPoint.x - (this.initialSize_ / 2),
|
||
|
y: startPoint.y - (this.initialSize_ / 2),
|
||
|
};
|
||
|
var endPoint = {
|
||
|
x: (this.frame_.width / 2) - (this.initialSize_ / 2),
|
||
|
y: (this.frame_.height / 2) - (this.initialSize_ / 2),
|
||
|
};
|
||
|
return { startPoint: startPoint, endPoint: endPoint };
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.runDeactivationUXLogicIfReady_ = function () {
|
||
|
var _this = this;
|
||
|
// This method is called both when a pointing device is released, and when the activation animation ends.
|
||
|
// The deactivation animation should only run after both of those occur.
|
||
|
var FG_DEACTIVATION = MDCRippleFoundation.cssClasses.FG_DEACTIVATION;
|
||
|
var _a = this.activationState_, hasDeactivationUXRun = _a.hasDeactivationUXRun, isActivated = _a.isActivated;
|
||
|
var activationHasEnded = hasDeactivationUXRun || !isActivated;
|
||
|
if (activationHasEnded && this.activationAnimationHasEnded_) {
|
||
|
this.rmBoundedActivationClasses_();
|
||
|
this.adapter_.addClass(FG_DEACTIVATION);
|
||
|
this.fgDeactivationRemovalTimer_ = setTimeout(function () {
|
||
|
_this.adapter_.removeClass(FG_DEACTIVATION);
|
||
|
}, _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"].FG_DEACTIVATION_MS);
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.rmBoundedActivationClasses_ = function () {
|
||
|
var FG_ACTIVATION = MDCRippleFoundation.cssClasses.FG_ACTIVATION;
|
||
|
this.adapter_.removeClass(FG_ACTIVATION);
|
||
|
this.activationAnimationHasEnded_ = false;
|
||
|
this.adapter_.computeBoundingRect();
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.resetActivationState_ = function () {
|
||
|
var _this = this;
|
||
|
this.previousActivationEvent_ = this.activationState_.activationEvent;
|
||
|
this.activationState_ = this.defaultActivationState_();
|
||
|
// Touch devices may fire additional events for the same interaction within a short time.
|
||
|
// Store the previous event until it's safe to assume that subsequent events are for new interactions.
|
||
|
setTimeout(function () { return _this.previousActivationEvent_ = undefined; }, MDCRippleFoundation.numbers.TAP_DELAY_MS);
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.deactivate_ = function () {
|
||
|
var _this = this;
|
||
|
var activationState = this.activationState_;
|
||
|
// This can happen in scenarios such as when you have a keyup event that blurs the element.
|
||
|
if (!activationState.isActivated) {
|
||
|
return;
|
||
|
}
|
||
|
var state = tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, activationState);
|
||
|
if (activationState.isProgrammatic) {
|
||
|
requestAnimationFrame(function () { return _this.animateDeactivation_(state); });
|
||
|
this.resetActivationState_();
|
||
|
}
|
||
|
else {
|
||
|
this.deregisterDeactivationHandlers_();
|
||
|
requestAnimationFrame(function () {
|
||
|
_this.activationState_.hasDeactivationUXRun = true;
|
||
|
_this.animateDeactivation_(state);
|
||
|
_this.resetActivationState_();
|
||
|
});
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.animateDeactivation_ = function (_a) {
|
||
|
var wasActivatedByPointer = _a.wasActivatedByPointer, wasElementMadeActive = _a.wasElementMadeActive;
|
||
|
if (wasActivatedByPointer || wasElementMadeActive) {
|
||
|
this.runDeactivationUXLogicIfReady_();
|
||
|
}
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.layoutInternal_ = function () {
|
||
|
var _this = this;
|
||
|
this.frame_ = this.adapter_.computeBoundingRect();
|
||
|
var maxDim = Math.max(this.frame_.height, this.frame_.width);
|
||
|
// Surface diameter is treated differently for unbounded vs. bounded ripples.
|
||
|
// Unbounded ripple diameter is calculated smaller since the surface is expected to already be padded appropriately
|
||
|
// to extend the hitbox, and the ripple is expected to meet the edges of the padded hitbox (which is typically
|
||
|
// square). Bounded ripples, on the other hand, are fully expected to expand beyond the surface's longest diameter
|
||
|
// (calculated based on the diagonal plus a constant padding), and are clipped at the surface's border via
|
||
|
// `overflow: hidden`.
|
||
|
var getBoundedRadius = function () {
|
||
|
var hypotenuse = Math.sqrt(Math.pow(_this.frame_.width, 2) + Math.pow(_this.frame_.height, 2));
|
||
|
return hypotenuse + MDCRippleFoundation.numbers.PADDING;
|
||
|
};
|
||
|
this.maxRadius_ = this.adapter_.isUnbounded() ? maxDim : getBoundedRadius();
|
||
|
// Ripple is sized as a fraction of the largest dimension of the surface, then scales up using a CSS scale transform
|
||
|
this.initialSize_ = Math.floor(maxDim * MDCRippleFoundation.numbers.INITIAL_ORIGIN_SCALE);
|
||
|
this.fgScale_ = "" + this.maxRadius_ / this.initialSize_;
|
||
|
this.updateLayoutCssVars_();
|
||
|
};
|
||
|
MDCRippleFoundation.prototype.updateLayoutCssVars_ = function () {
|
||
|
var _a = MDCRippleFoundation.strings, VAR_FG_SIZE = _a.VAR_FG_SIZE, VAR_LEFT = _a.VAR_LEFT, VAR_TOP = _a.VAR_TOP, VAR_FG_SCALE = _a.VAR_FG_SCALE;
|
||
|
this.adapter_.updateCssVariable(VAR_FG_SIZE, this.initialSize_ + "px");
|
||
|
this.adapter_.updateCssVariable(VAR_FG_SCALE, this.fgScale_);
|
||
|
if (this.adapter_.isUnbounded()) {
|
||
|
this.unboundedCoords_ = {
|
||
|
left: Math.round((this.frame_.width / 2) - (this.initialSize_ / 2)),
|
||
|
top: Math.round((this.frame_.height / 2) - (this.initialSize_ / 2)),
|
||
|
};
|
||
|
this.adapter_.updateCssVariable(VAR_LEFT, this.unboundedCoords_.left + "px");
|
||
|
this.adapter_.updateCssVariable(VAR_TOP, this.unboundedCoords_.top + "px");
|
||
|
}
|
||
|
};
|
||
|
return MDCRippleFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCRippleFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/ripple/index.js":
|
||
|
/*!************************************************!*\
|
||
|
!*** ./node_modules/@material/ripple/index.js ***!
|
||
|
\************************************************/
|
||
|
/*! exports provided: util, MDCRipple, cssClasses, strings, numbers, MDCRippleFoundation */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _util__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./util */ "./node_modules/@material/ripple/util.js");
|
||
|
/* harmony reexport (module object) */ __webpack_require__.d(__webpack_exports__, "util", function() { return _util__WEBPACK_IMPORTED_MODULE_0__; });
|
||
|
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./component */ "./node_modules/@material/ripple/component.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCRipple", function() { return _component__WEBPACK_IMPORTED_MODULE_1__["MDCRipple"]; });
|
||
|
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/ripple/constants.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"]; });
|
||
|
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/ripple/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCRippleFoundation", function() { return _foundation__WEBPACK_IMPORTED_MODULE_3__["MDCRippleFoundation"]; });
|
||
|
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
//# sourceMappingURL=index.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/ripple/util.js":
|
||
|
/*!***********************************************!*\
|
||
|
!*** ./node_modules/@material/ripple/util.js ***!
|
||
|
\***********************************************/
|
||
|
/*! exports provided: supportsCssVariables, getNormalizedEventCoords */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "supportsCssVariables", function() { return supportsCssVariables; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "getNormalizedEventCoords", function() { return getNormalizedEventCoords; });
|
||
|
/**
|
||
|
* Stores result from supportsCssVariables to avoid redundant processing to
|
||
|
* detect CSS custom variable support.
|
||
|
*/
|
||
|
var supportsCssVariables_;
|
||
|
function detectEdgePseudoVarBug(windowObj) {
|
||
|
// Detect versions of Edge with buggy var() support
|
||
|
// See: https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/11495448/
|
||
|
var document = windowObj.document;
|
||
|
var node = document.createElement('div');
|
||
|
node.className = 'mdc-ripple-surface--test-edge-var-bug';
|
||
|
// Append to head instead of body because this script might be invoked in the
|
||
|
// head, in which case the body doesn't exist yet. The probe works either way.
|
||
|
document.head.appendChild(node);
|
||
|
// The bug exists if ::before style ends up propagating to the parent element.
|
||
|
// Additionally, getComputedStyle returns null in iframes with display: "none" in Firefox,
|
||
|
// but Firefox is known to support CSS custom properties correctly.
|
||
|
// See: https://bugzilla.mozilla.org/show_bug.cgi?id=548397
|
||
|
var computedStyle = windowObj.getComputedStyle(node);
|
||
|
var hasPseudoVarBug = computedStyle !== null && computedStyle.borderTopStyle === 'solid';
|
||
|
if (node.parentNode) {
|
||
|
node.parentNode.removeChild(node);
|
||
|
}
|
||
|
return hasPseudoVarBug;
|
||
|
}
|
||
|
function supportsCssVariables(windowObj, forceRefresh) {
|
||
|
if (forceRefresh === void 0) { forceRefresh = false; }
|
||
|
var CSS = windowObj.CSS;
|
||
|
var supportsCssVars = supportsCssVariables_;
|
||
|
if (typeof supportsCssVariables_ === 'boolean' && !forceRefresh) {
|
||
|
return supportsCssVariables_;
|
||
|
}
|
||
|
var supportsFunctionPresent = CSS && typeof CSS.supports === 'function';
|
||
|
if (!supportsFunctionPresent) {
|
||
|
return false;
|
||
|
}
|
||
|
var explicitlySupportsCssVars = CSS.supports('--css-vars', 'yes');
|
||
|
// See: https://bugs.webkit.org/show_bug.cgi?id=154669
|
||
|
// See: README section on Safari
|
||
|
var weAreFeatureDetectingSafari10plus = (CSS.supports('(--css-vars: yes)') &&
|
||
|
CSS.supports('color', '#00000000'));
|
||
|
if (explicitlySupportsCssVars || weAreFeatureDetectingSafari10plus) {
|
||
|
supportsCssVars = !detectEdgePseudoVarBug(windowObj);
|
||
|
}
|
||
|
else {
|
||
|
supportsCssVars = false;
|
||
|
}
|
||
|
if (!forceRefresh) {
|
||
|
supportsCssVariables_ = supportsCssVars;
|
||
|
}
|
||
|
return supportsCssVars;
|
||
|
}
|
||
|
function getNormalizedEventCoords(evt, pageOffset, clientRect) {
|
||
|
if (!evt) {
|
||
|
return { x: 0, y: 0 };
|
||
|
}
|
||
|
var x = pageOffset.x, y = pageOffset.y;
|
||
|
var documentX = x + clientRect.left;
|
||
|
var documentY = y + clientRect.top;
|
||
|
var normalizedX;
|
||
|
var normalizedY;
|
||
|
// Determine touch point relative to the ripple container.
|
||
|
if (evt.type === 'touchstart') {
|
||
|
var touchEvent = evt;
|
||
|
normalizedX = touchEvent.changedTouches[0].pageX - documentX;
|
||
|
normalizedY = touchEvent.changedTouches[0].pageY - documentY;
|
||
|
}
|
||
|
else {
|
||
|
var mouseEvent = evt;
|
||
|
normalizedX = mouseEvent.pageX - documentX;
|
||
|
normalizedY = mouseEvent.pageY - documentY;
|
||
|
}
|
||
|
return { x: normalizedX, y: normalizedY };
|
||
|
}
|
||
|
//# sourceMappingURL=util.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/character-counter/component.js":
|
||
|
/*!*************************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/character-counter/component.js ***!
|
||
|
\*************************************************************************/
|
||
|
/*! exports provided: MDCTextFieldCharacterCounter */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldCharacterCounter", function() { return MDCTextFieldCharacterCounter; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/character-counter/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTextFieldCharacterCounter = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldCharacterCounter, _super);
|
||
|
function MDCTextFieldCharacterCounter() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCTextFieldCharacterCounter.attachTo = function (root) {
|
||
|
return new MDCTextFieldCharacterCounter(root);
|
||
|
};
|
||
|
Object.defineProperty(MDCTextFieldCharacterCounter.prototype, "foundation", {
|
||
|
get: function () {
|
||
|
return this.foundation_;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCTextFieldCharacterCounter.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
var adapter = {
|
||
|
setContent: function (content) {
|
||
|
_this.root_.textContent = content;
|
||
|
},
|
||
|
};
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTextFieldCharacterCounterFoundation"](adapter);
|
||
|
};
|
||
|
return MDCTextFieldCharacterCounter;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/character-counter/constants.js":
|
||
|
/*!*************************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/character-counter/constants.js ***!
|
||
|
\*************************************************************************/
|
||
|
/*! exports provided: strings, cssClasses */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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 cssClasses = {
|
||
|
ROOT: 'mdc-text-field-character-counter',
|
||
|
};
|
||
|
var strings = {
|
||
|
ROOT_SELECTOR: "." + cssClasses.ROOT,
|
||
|
};
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/character-counter/foundation.js":
|
||
|
/*!**************************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/character-counter/foundation.js ***!
|
||
|
\**************************************************************************/
|
||
|
/*! exports provided: MDCTextFieldCharacterCounterFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldCharacterCounterFoundation", function() { return MDCTextFieldCharacterCounterFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/character-counter/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTextFieldCharacterCounterFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldCharacterCounterFoundation, _super);
|
||
|
function MDCTextFieldCharacterCounterFoundation(adapter) {
|
||
|
return _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCTextFieldCharacterCounterFoundation.defaultAdapter, adapter)) || this;
|
||
|
}
|
||
|
Object.defineProperty(MDCTextFieldCharacterCounterFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldCharacterCounterFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldCharacterCounterFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCTextFieldCharacterCounterAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
return {
|
||
|
setContent: function () { return undefined; },
|
||
|
};
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCTextFieldCharacterCounterFoundation.prototype.setCounterValue = function (currentLength, maxLength) {
|
||
|
currentLength = Math.min(currentLength, maxLength);
|
||
|
this.adapter_.setContent(currentLength + " / " + maxLength);
|
||
|
};
|
||
|
return MDCTextFieldCharacterCounterFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCTextFieldCharacterCounterFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/character-counter/index.js":
|
||
|
/*!*********************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/character-counter/index.js ***!
|
||
|
\*********************************************************************/
|
||
|
/*! exports provided: characterCountCssClasses, characterCountStrings, MDCTextFieldCharacterCounter, MDCTextFieldCharacterCounterFoundation */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./component */ "./node_modules/@material/textfield/character-counter/component.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldCharacterCounter", function() { return _component__WEBPACK_IMPORTED_MODULE_0__["MDCTextFieldCharacterCounter"]; });
|
||
|
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/character-counter/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldCharacterCounterFoundation", function() { return _foundation__WEBPACK_IMPORTED_MODULE_1__["MDCTextFieldCharacterCounterFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/character-counter/constants.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "characterCountCssClasses", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "characterCountStrings", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"]; });
|
||
|
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
//# sourceMappingURL=index.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/component.js":
|
||
|
/*!*******************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/component.js ***!
|
||
|
\*******************************************************/
|
||
|
/*! exports provided: MDCTextField */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextField", function() { return MDCTextField; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _material_dom_events__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @material/dom/events */ "./node_modules/@material/dom/events.js");
|
||
|
/* harmony import */ var _material_dom_ponyfill__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @material/dom/ponyfill */ "./node_modules/@material/dom/ponyfill.js");
|
||
|
/* harmony import */ var _material_floating_label_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @material/floating-label/component */ "./node_modules/@material/floating-label/component.js");
|
||
|
/* harmony import */ var _material_line_ripple_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @material/line-ripple/component */ "./node_modules/@material/line-ripple/component.js");
|
||
|
/* harmony import */ var _material_notched_outline_component__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @material/notched-outline/component */ "./node_modules/@material/notched-outline/component.js");
|
||
|
/* harmony import */ var _material_ripple_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @material/ripple/component */ "./node_modules/@material/ripple/component.js");
|
||
|
/* harmony import */ var _material_ripple_foundation__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @material/ripple/foundation */ "./node_modules/@material/ripple/foundation.js");
|
||
|
/* harmony import */ var _character_counter_component__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./character-counter/component */ "./node_modules/@material/textfield/character-counter/component.js");
|
||
|
/* harmony import */ var _character_counter_foundation__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./character-counter/foundation */ "./node_modules/@material/textfield/character-counter/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/constants.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/foundation.js");
|
||
|
/* harmony import */ var _helper_text_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./helper-text/component */ "./node_modules/@material/textfield/helper-text/component.js");
|
||
|
/* harmony import */ var _helper_text_foundation__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./helper-text/foundation */ "./node_modules/@material/textfield/helper-text/foundation.js");
|
||
|
/* harmony import */ var _icon_component__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./icon/component */ "./node_modules/@material/textfield/icon/component.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTextField = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextField, _super);
|
||
|
function MDCTextField() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCTextField.attachTo = function (root) {
|
||
|
return new MDCTextField(root);
|
||
|
};
|
||
|
MDCTextField.prototype.initialize = function (rippleFactory, lineRippleFactory, helperTextFactory, characterCounterFactory, iconFactory, labelFactory, outlineFactory) {
|
||
|
if (rippleFactory === void 0) { rippleFactory = function (el, foundation) { return new _material_ripple_component__WEBPACK_IMPORTED_MODULE_7__["MDCRipple"](el, foundation); }; }
|
||
|
if (lineRippleFactory === void 0) { lineRippleFactory = function (el) { return new _material_line_ripple_component__WEBPACK_IMPORTED_MODULE_5__["MDCLineRipple"](el); }; }
|
||
|
if (helperTextFactory === void 0) { helperTextFactory = function (el) { return new _helper_text_component__WEBPACK_IMPORTED_MODULE_13__["MDCTextFieldHelperText"](el); }; }
|
||
|
if (characterCounterFactory === void 0) { characterCounterFactory = function (el) { return new _character_counter_component__WEBPACK_IMPORTED_MODULE_9__["MDCTextFieldCharacterCounter"](el); }; }
|
||
|
if (iconFactory === void 0) { iconFactory = function (el) { return new _icon_component__WEBPACK_IMPORTED_MODULE_15__["MDCTextFieldIcon"](el); }; }
|
||
|
if (labelFactory === void 0) { labelFactory = function (el) { return new _material_floating_label_component__WEBPACK_IMPORTED_MODULE_4__["MDCFloatingLabel"](el); }; }
|
||
|
if (outlineFactory === void 0) { outlineFactory = function (el) { return new _material_notched_outline_component__WEBPACK_IMPORTED_MODULE_6__["MDCNotchedOutline"](el); }; }
|
||
|
this.input_ = this.root_.querySelector(_constants__WEBPACK_IMPORTED_MODULE_11__["strings"].INPUT_SELECTOR);
|
||
|
var labelElement = this.root_.querySelector(_constants__WEBPACK_IMPORTED_MODULE_11__["strings"].LABEL_SELECTOR);
|
||
|
this.label_ = labelElement ? labelFactory(labelElement) : null;
|
||
|
var lineRippleElement = this.root_.querySelector(_constants__WEBPACK_IMPORTED_MODULE_11__["strings"].LINE_RIPPLE_SELECTOR);
|
||
|
this.lineRipple_ = lineRippleElement ? lineRippleFactory(lineRippleElement) : null;
|
||
|
var outlineElement = this.root_.querySelector(_constants__WEBPACK_IMPORTED_MODULE_11__["strings"].OUTLINE_SELECTOR);
|
||
|
this.outline_ = outlineElement ? outlineFactory(outlineElement) : null;
|
||
|
// Helper text
|
||
|
var helperTextStrings = _helper_text_foundation__WEBPACK_IMPORTED_MODULE_14__["MDCTextFieldHelperTextFoundation"].strings;
|
||
|
var nextElementSibling = this.root_.nextElementSibling;
|
||
|
var hasHelperLine = (nextElementSibling && nextElementSibling.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_11__["cssClasses"].HELPER_LINE));
|
||
|
var helperTextEl = hasHelperLine && nextElementSibling && nextElementSibling.querySelector(helperTextStrings.ROOT_SELECTOR);
|
||
|
this.helperText_ = helperTextEl ? helperTextFactory(helperTextEl) : null;
|
||
|
// Character counter
|
||
|
var characterCounterStrings = _character_counter_foundation__WEBPACK_IMPORTED_MODULE_10__["MDCTextFieldCharacterCounterFoundation"].strings;
|
||
|
var characterCounterEl = this.root_.querySelector(characterCounterStrings.ROOT_SELECTOR);
|
||
|
// If character counter is not found in root element search in sibling element.
|
||
|
if (!characterCounterEl && hasHelperLine && nextElementSibling) {
|
||
|
characterCounterEl = nextElementSibling.querySelector(characterCounterStrings.ROOT_SELECTOR);
|
||
|
}
|
||
|
this.characterCounter_ = characterCounterEl ? characterCounterFactory(characterCounterEl) : null;
|
||
|
this.leadingIcon_ = null;
|
||
|
this.trailingIcon_ = null;
|
||
|
var iconElements = this.root_.querySelectorAll(_constants__WEBPACK_IMPORTED_MODULE_11__["strings"].ICON_SELECTOR);
|
||
|
if (iconElements.length > 0) {
|
||
|
if (iconElements.length > 1) { // Has both icons.
|
||
|
this.leadingIcon_ = iconFactory(iconElements[0]);
|
||
|
this.trailingIcon_ = iconFactory(iconElements[1]);
|
||
|
}
|
||
|
else {
|
||
|
if (this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_11__["cssClasses"].WITH_LEADING_ICON)) {
|
||
|
this.leadingIcon_ = iconFactory(iconElements[0]);
|
||
|
}
|
||
|
else {
|
||
|
this.trailingIcon_ = iconFactory(iconElements[0]);
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
this.ripple = this.createRipple_(rippleFactory);
|
||
|
};
|
||
|
MDCTextField.prototype.destroy = function () {
|
||
|
if (this.ripple) {
|
||
|
this.ripple.destroy();
|
||
|
}
|
||
|
if (this.lineRipple_) {
|
||
|
this.lineRipple_.destroy();
|
||
|
}
|
||
|
if (this.helperText_) {
|
||
|
this.helperText_.destroy();
|
||
|
}
|
||
|
if (this.characterCounter_) {
|
||
|
this.characterCounter_.destroy();
|
||
|
}
|
||
|
if (this.leadingIcon_) {
|
||
|
this.leadingIcon_.destroy();
|
||
|
}
|
||
|
if (this.trailingIcon_) {
|
||
|
this.trailingIcon_.destroy();
|
||
|
}
|
||
|
if (this.label_) {
|
||
|
this.label_.destroy();
|
||
|
}
|
||
|
if (this.outline_) {
|
||
|
this.outline_.destroy();
|
||
|
}
|
||
|
_super.prototype.destroy.call(this);
|
||
|
};
|
||
|
/**
|
||
|
* Initializes the Text Field's internal state based on the environment's
|
||
|
* state.
|
||
|
*/
|
||
|
MDCTextField.prototype.initialSyncWithDOM = function () {
|
||
|
this.disabled = this.input_.disabled;
|
||
|
};
|
||
|
Object.defineProperty(MDCTextField.prototype, "value", {
|
||
|
get: function () {
|
||
|
return this.foundation_.getValue();
|
||
|
},
|
||
|
/**
|
||
|
* @param value The value to set on the input.
|
||
|
*/
|
||
|
set: function (value) {
|
||
|
this.foundation_.setValue(value);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "disabled", {
|
||
|
get: function () {
|
||
|
return this.foundation_.isDisabled();
|
||
|
},
|
||
|
/**
|
||
|
* @param disabled Sets the Text Field disabled or enabled.
|
||
|
*/
|
||
|
set: function (disabled) {
|
||
|
this.foundation_.setDisabled(disabled);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "valid", {
|
||
|
get: function () {
|
||
|
return this.foundation_.isValid();
|
||
|
},
|
||
|
/**
|
||
|
* @param valid Sets the Text Field valid or invalid.
|
||
|
*/
|
||
|
set: function (valid) {
|
||
|
this.foundation_.setValid(valid);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "required", {
|
||
|
get: function () {
|
||
|
return this.input_.required;
|
||
|
},
|
||
|
/**
|
||
|
* @param required Sets the Text Field to required.
|
||
|
*/
|
||
|
set: function (required) {
|
||
|
this.input_.required = required;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "pattern", {
|
||
|
get: function () {
|
||
|
return this.input_.pattern;
|
||
|
},
|
||
|
/**
|
||
|
* @param pattern Sets the input element's validation pattern.
|
||
|
*/
|
||
|
set: function (pattern) {
|
||
|
this.input_.pattern = pattern;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "minLength", {
|
||
|
get: function () {
|
||
|
return this.input_.minLength;
|
||
|
},
|
||
|
/**
|
||
|
* @param minLength Sets the input element's minLength.
|
||
|
*/
|
||
|
set: function (minLength) {
|
||
|
this.input_.minLength = minLength;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "maxLength", {
|
||
|
get: function () {
|
||
|
return this.input_.maxLength;
|
||
|
},
|
||
|
/**
|
||
|
* @param maxLength Sets the input element's maxLength.
|
||
|
*/
|
||
|
set: function (maxLength) {
|
||
|
// Chrome throws exception if maxLength is set to a value less than zero
|
||
|
if (maxLength < 0) {
|
||
|
this.input_.removeAttribute('maxLength');
|
||
|
}
|
||
|
else {
|
||
|
this.input_.maxLength = maxLength;
|
||
|
}
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "min", {
|
||
|
get: function () {
|
||
|
return this.input_.min;
|
||
|
},
|
||
|
/**
|
||
|
* @param min Sets the input element's min.
|
||
|
*/
|
||
|
set: function (min) {
|
||
|
this.input_.min = min;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "max", {
|
||
|
get: function () {
|
||
|
return this.input_.max;
|
||
|
},
|
||
|
/**
|
||
|
* @param max Sets the input element's max.
|
||
|
*/
|
||
|
set: function (max) {
|
||
|
this.input_.max = max;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "step", {
|
||
|
get: function () {
|
||
|
return this.input_.step;
|
||
|
},
|
||
|
/**
|
||
|
* @param step Sets the input element's step.
|
||
|
*/
|
||
|
set: function (step) {
|
||
|
this.input_.step = step;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "helperTextContent", {
|
||
|
/**
|
||
|
* Sets the helper text element content.
|
||
|
*/
|
||
|
set: function (content) {
|
||
|
this.foundation_.setHelperTextContent(content);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "leadingIconAriaLabel", {
|
||
|
/**
|
||
|
* Sets the aria label of the leading icon.
|
||
|
*/
|
||
|
set: function (label) {
|
||
|
this.foundation_.setLeadingIconAriaLabel(label);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "leadingIconContent", {
|
||
|
/**
|
||
|
* Sets the text content of the leading icon.
|
||
|
*/
|
||
|
set: function (content) {
|
||
|
this.foundation_.setLeadingIconContent(content);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "trailingIconAriaLabel", {
|
||
|
/**
|
||
|
* Sets the aria label of the trailing icon.
|
||
|
*/
|
||
|
set: function (label) {
|
||
|
this.foundation_.setTrailingIconAriaLabel(label);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "trailingIconContent", {
|
||
|
/**
|
||
|
* Sets the text content of the trailing icon.
|
||
|
*/
|
||
|
set: function (content) {
|
||
|
this.foundation_.setTrailingIconContent(content);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextField.prototype, "useNativeValidation", {
|
||
|
/**
|
||
|
* Enables or disables the use of native validation. Use this for custom validation.
|
||
|
* @param useNativeValidation Set this to false to ignore native input validation.
|
||
|
*/
|
||
|
set: function (useNativeValidation) {
|
||
|
this.foundation_.setUseNativeValidation(useNativeValidation);
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
/**
|
||
|
* Focuses the input element.
|
||
|
*/
|
||
|
MDCTextField.prototype.focus = function () {
|
||
|
this.input_.focus();
|
||
|
};
|
||
|
/**
|
||
|
* Recomputes the outline SVG path for the outline element.
|
||
|
*/
|
||
|
MDCTextField.prototype.layout = function () {
|
||
|
var openNotch = this.foundation_.shouldFloat;
|
||
|
this.foundation_.notchOutline(openNotch);
|
||
|
};
|
||
|
MDCTextField.prototype.getDefaultFoundation = function () {
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, this.getRootAdapterMethods_(), this.getInputAdapterMethods_(), this.getLabelAdapterMethods_(), this.getLineRippleAdapterMethods_(), this.getOutlineAdapterMethods_());
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_12__["MDCTextFieldFoundation"](adapter, this.getFoundationMap_());
|
||
|
};
|
||
|
MDCTextField.prototype.getRootAdapterMethods_ = function () {
|
||
|
var _this = this;
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function (className) { return _this.root_.classList.add(className); },
|
||
|
removeClass: function (className) { return _this.root_.classList.remove(className); },
|
||
|
hasClass: function (className) { return _this.root_.classList.contains(className); },
|
||
|
registerTextFieldInteractionHandler: function (evtType, handler) { return _this.listen(evtType, handler); },
|
||
|
deregisterTextFieldInteractionHandler: function (evtType, handler) { return _this.unlisten(evtType, handler); },
|
||
|
registerValidationAttributeChangeHandler: function (handler) {
|
||
|
var getAttributesList = function (mutationsList) {
|
||
|
return mutationsList
|
||
|
.map(function (mutation) { return mutation.attributeName; })
|
||
|
.filter(function (attributeName) { return attributeName; });
|
||
|
};
|
||
|
var observer = new MutationObserver(function (mutationsList) { return handler(getAttributesList(mutationsList)); });
|
||
|
var config = { attributes: true };
|
||
|
observer.observe(_this.input_, config);
|
||
|
return observer;
|
||
|
},
|
||
|
deregisterValidationAttributeChangeHandler: function (observer) { return observer.disconnect(); },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
};
|
||
|
MDCTextField.prototype.getInputAdapterMethods_ = function () {
|
||
|
var _this = this;
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
getNativeInput: function () { return _this.input_; },
|
||
|
isFocused: function () { return document.activeElement === _this.input_; },
|
||
|
registerInputInteractionHandler: function (evtType, handler) {
|
||
|
return _this.input_.addEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
},
|
||
|
deregisterInputInteractionHandler: function (evtType, handler) {
|
||
|
return _this.input_.removeEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
},
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
};
|
||
|
MDCTextField.prototype.getLabelAdapterMethods_ = function () {
|
||
|
var _this = this;
|
||
|
return {
|
||
|
floatLabel: function (shouldFloat) { return _this.label_ && _this.label_.float(shouldFloat); },
|
||
|
getLabelWidth: function () { return _this.label_ ? _this.label_.getWidth() : 0; },
|
||
|
hasLabel: function () { return Boolean(_this.label_); },
|
||
|
shakeLabel: function (shouldShake) { return _this.label_ && _this.label_.shake(shouldShake); },
|
||
|
};
|
||
|
};
|
||
|
MDCTextField.prototype.getLineRippleAdapterMethods_ = function () {
|
||
|
var _this = this;
|
||
|
return {
|
||
|
activateLineRipple: function () {
|
||
|
if (_this.lineRipple_) {
|
||
|
_this.lineRipple_.activate();
|
||
|
}
|
||
|
},
|
||
|
deactivateLineRipple: function () {
|
||
|
if (_this.lineRipple_) {
|
||
|
_this.lineRipple_.deactivate();
|
||
|
}
|
||
|
},
|
||
|
setLineRippleTransformOrigin: function (normalizedX) {
|
||
|
if (_this.lineRipple_) {
|
||
|
_this.lineRipple_.setRippleCenter(normalizedX);
|
||
|
}
|
||
|
},
|
||
|
};
|
||
|
};
|
||
|
MDCTextField.prototype.getOutlineAdapterMethods_ = function () {
|
||
|
var _this = this;
|
||
|
return {
|
||
|
closeOutline: function () { return _this.outline_ && _this.outline_.closeNotch(); },
|
||
|
hasOutline: function () { return Boolean(_this.outline_); },
|
||
|
notchOutline: function (labelWidth) { return _this.outline_ && _this.outline_.notch(labelWidth); },
|
||
|
};
|
||
|
};
|
||
|
/**
|
||
|
* @return A map of all subcomponents to subfoundations.
|
||
|
*/
|
||
|
MDCTextField.prototype.getFoundationMap_ = function () {
|
||
|
return {
|
||
|
characterCounter: this.characterCounter_ ? this.characterCounter_.foundation : undefined,
|
||
|
helperText: this.helperText_ ? this.helperText_.foundation : undefined,
|
||
|
leadingIcon: this.leadingIcon_ ? this.leadingIcon_.foundation : undefined,
|
||
|
trailingIcon: this.trailingIcon_ ? this.trailingIcon_.foundation : undefined,
|
||
|
};
|
||
|
};
|
||
|
MDCTextField.prototype.createRipple_ = function (rippleFactory) {
|
||
|
var _this = this;
|
||
|
var isTextArea = this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_11__["cssClasses"].TEXTAREA);
|
||
|
var isOutlined = this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_11__["cssClasses"].OUTLINED);
|
||
|
if (isTextArea || isOutlined) {
|
||
|
return null;
|
||
|
}
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, _material_ripple_component__WEBPACK_IMPORTED_MODULE_7__["MDCRipple"].createAdapter(this), { isSurfaceActive: function () { return _material_dom_ponyfill__WEBPACK_IMPORTED_MODULE_3__["matches"](_this.input_, ':active'); }, registerInteractionHandler: function (evtType, handler) { return _this.input_.addEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])()); }, deregisterInteractionHandler: function (evtType, handler) {
|
||
|
return _this.input_.removeEventListener(evtType, handler, Object(_material_dom_events__WEBPACK_IMPORTED_MODULE_2__["applyPassive"])());
|
||
|
} });
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return rippleFactory(this.root_, new _material_ripple_foundation__WEBPACK_IMPORTED_MODULE_8__["MDCRippleFoundation"](adapter));
|
||
|
};
|
||
|
return MDCTextField;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/constants.js":
|
||
|
/*!*******************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/constants.js ***!
|
||
|
\*******************************************************/
|
||
|
/*! exports provided: cssClasses, strings, numbers, VALIDATION_ATTR_WHITELIST, ALWAYS_FLOAT_TYPES */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return numbers; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "VALIDATION_ATTR_WHITELIST", function() { return VALIDATION_ATTR_WHITELIST; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ALWAYS_FLOAT_TYPES", function() { return ALWAYS_FLOAT_TYPES; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 strings = {
|
||
|
ARIA_CONTROLS: 'aria-controls',
|
||
|
ICON_SELECTOR: '.mdc-text-field__icon',
|
||
|
INPUT_SELECTOR: '.mdc-text-field__input',
|
||
|
LABEL_SELECTOR: '.mdc-floating-label',
|
||
|
LINE_RIPPLE_SELECTOR: '.mdc-line-ripple',
|
||
|
OUTLINE_SELECTOR: '.mdc-notched-outline',
|
||
|
};
|
||
|
var cssClasses = {
|
||
|
DENSE: 'mdc-text-field--dense',
|
||
|
DISABLED: 'mdc-text-field--disabled',
|
||
|
FOCUSED: 'mdc-text-field--focused',
|
||
|
FULLWIDTH: 'mdc-text-field--fullwidth',
|
||
|
HELPER_LINE: 'mdc-text-field-helper-line',
|
||
|
INVALID: 'mdc-text-field--invalid',
|
||
|
NO_LABEL: 'mdc-text-field--no-label',
|
||
|
OUTLINED: 'mdc-text-field--outlined',
|
||
|
ROOT: 'mdc-text-field',
|
||
|
TEXTAREA: 'mdc-text-field--textarea',
|
||
|
WITH_LEADING_ICON: 'mdc-text-field--with-leading-icon',
|
||
|
WITH_TRAILING_ICON: 'mdc-text-field--with-trailing-icon',
|
||
|
};
|
||
|
var numbers = {
|
||
|
DENSE_LABEL_SCALE: 0.923,
|
||
|
LABEL_SCALE: 0.75,
|
||
|
};
|
||
|
/**
|
||
|
* Whitelist based off of https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/HTML5/Constraint_validation
|
||
|
* under the "Validation-related attributes" section.
|
||
|
*/
|
||
|
var VALIDATION_ATTR_WHITELIST = [
|
||
|
'pattern', 'min', 'max', 'required', 'step', 'minlength', 'maxlength',
|
||
|
];
|
||
|
/**
|
||
|
* Label should always float for these types as they show some UI even if value is empty.
|
||
|
*/
|
||
|
var ALWAYS_FLOAT_TYPES = [
|
||
|
'color', 'date', 'datetime-local', 'month', 'range', 'time', 'week',
|
||
|
];
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/foundation.js":
|
||
|
/*!********************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/foundation.js ***!
|
||
|
\********************************************************/
|
||
|
/*! exports provided: MDCTextFieldFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldFoundation", function() { return MDCTextFieldFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 POINTERDOWN_EVENTS = ['mousedown', 'touchstart'];
|
||
|
var INTERACTION_EVENTS = ['click', 'keydown'];
|
||
|
var MDCTextFieldFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldFoundation, _super);
|
||
|
/**
|
||
|
* @param adapter
|
||
|
* @param foundationMap Map from subcomponent names to their subfoundations.
|
||
|
*/
|
||
|
function MDCTextFieldFoundation(adapter, foundationMap) {
|
||
|
if (foundationMap === void 0) { foundationMap = {}; }
|
||
|
var _this = _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCTextFieldFoundation.defaultAdapter, adapter)) || this;
|
||
|
_this.isFocused_ = false;
|
||
|
_this.receivedUserInput_ = false;
|
||
|
_this.isValid_ = true;
|
||
|
_this.useNativeValidation_ = true;
|
||
|
_this.helperText_ = foundationMap.helperText;
|
||
|
_this.characterCounter_ = foundationMap.characterCounter;
|
||
|
_this.leadingIcon_ = foundationMap.leadingIcon;
|
||
|
_this.trailingIcon_ = foundationMap.trailingIcon;
|
||
|
_this.inputFocusHandler_ = function () { return _this.activateFocus(); };
|
||
|
_this.inputBlurHandler_ = function () { return _this.deactivateFocus(); };
|
||
|
_this.inputInputHandler_ = function () { return _this.handleInput(); };
|
||
|
_this.setPointerXOffset_ = function (evt) { return _this.setTransformOrigin(evt); };
|
||
|
_this.textFieldInteractionHandler_ = function () { return _this.handleTextFieldInteraction(); };
|
||
|
_this.validationAttributeChangeHandler_ = function (attributesList) { return _this.handleValidationAttributeChange(attributesList); };
|
||
|
return _this;
|
||
|
}
|
||
|
Object.defineProperty(MDCTextFieldFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldFoundation, "numbers", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldFoundation.prototype, "shouldAlwaysFloat_", {
|
||
|
get: function () {
|
||
|
var type = this.getNativeInput_().type;
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["ALWAYS_FLOAT_TYPES"].indexOf(type) >= 0;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldFoundation.prototype, "shouldFloat", {
|
||
|
get: function () {
|
||
|
return this.shouldAlwaysFloat_ || this.isFocused_ || Boolean(this.getValue()) || this.isBadInput_();
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldFoundation.prototype, "shouldShake", {
|
||
|
get: function () {
|
||
|
return !this.isFocused_ && !this.isValid() && Boolean(this.getValue());
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCTextFieldAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
hasClass: function () { return true; },
|
||
|
registerTextFieldInteractionHandler: function () { return undefined; },
|
||
|
deregisterTextFieldInteractionHandler: function () { return undefined; },
|
||
|
registerInputInteractionHandler: function () { return undefined; },
|
||
|
deregisterInputInteractionHandler: function () { return undefined; },
|
||
|
registerValidationAttributeChangeHandler: function () { return new MutationObserver(function () { return undefined; }); },
|
||
|
deregisterValidationAttributeChangeHandler: function () { return undefined; },
|
||
|
getNativeInput: function () { return null; },
|
||
|
isFocused: function () { return false; },
|
||
|
activateLineRipple: function () { return undefined; },
|
||
|
deactivateLineRipple: function () { return undefined; },
|
||
|
setLineRippleTransformOrigin: function () { return undefined; },
|
||
|
shakeLabel: function () { return undefined; },
|
||
|
floatLabel: function () { return undefined; },
|
||
|
hasLabel: function () { return false; },
|
||
|
getLabelWidth: function () { return 0; },
|
||
|
hasOutline: function () { return false; },
|
||
|
notchOutline: function () { return undefined; },
|
||
|
closeOutline: function () { return undefined; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCTextFieldFoundation.prototype.init = function () {
|
||
|
var _this = this;
|
||
|
if (this.adapter_.isFocused()) {
|
||
|
this.inputFocusHandler_();
|
||
|
}
|
||
|
else if (this.adapter_.hasLabel() && this.shouldFloat) {
|
||
|
this.notchOutline(true);
|
||
|
this.adapter_.floatLabel(true);
|
||
|
}
|
||
|
this.adapter_.registerInputInteractionHandler('focus', this.inputFocusHandler_);
|
||
|
this.adapter_.registerInputInteractionHandler('blur', this.inputBlurHandler_);
|
||
|
this.adapter_.registerInputInteractionHandler('input', this.inputInputHandler_);
|
||
|
POINTERDOWN_EVENTS.forEach(function (evtType) {
|
||
|
_this.adapter_.registerInputInteractionHandler(evtType, _this.setPointerXOffset_);
|
||
|
});
|
||
|
INTERACTION_EVENTS.forEach(function (evtType) {
|
||
|
_this.adapter_.registerTextFieldInteractionHandler(evtType, _this.textFieldInteractionHandler_);
|
||
|
});
|
||
|
this.validationObserver_ =
|
||
|
this.adapter_.registerValidationAttributeChangeHandler(this.validationAttributeChangeHandler_);
|
||
|
this.setCharacterCounter_(this.getValue().length);
|
||
|
};
|
||
|
MDCTextFieldFoundation.prototype.destroy = function () {
|
||
|
var _this = this;
|
||
|
this.adapter_.deregisterInputInteractionHandler('focus', this.inputFocusHandler_);
|
||
|
this.adapter_.deregisterInputInteractionHandler('blur', this.inputBlurHandler_);
|
||
|
this.adapter_.deregisterInputInteractionHandler('input', this.inputInputHandler_);
|
||
|
POINTERDOWN_EVENTS.forEach(function (evtType) {
|
||
|
_this.adapter_.deregisterInputInteractionHandler(evtType, _this.setPointerXOffset_);
|
||
|
});
|
||
|
INTERACTION_EVENTS.forEach(function (evtType) {
|
||
|
_this.adapter_.deregisterTextFieldInteractionHandler(evtType, _this.textFieldInteractionHandler_);
|
||
|
});
|
||
|
this.adapter_.deregisterValidationAttributeChangeHandler(this.validationObserver_);
|
||
|
};
|
||
|
/**
|
||
|
* Handles user interactions with the Text Field.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.handleTextFieldInteraction = function () {
|
||
|
var nativeInput = this.adapter_.getNativeInput();
|
||
|
if (nativeInput && nativeInput.disabled) {
|
||
|
return;
|
||
|
}
|
||
|
this.receivedUserInput_ = true;
|
||
|
};
|
||
|
/**
|
||
|
* Handles validation attribute changes
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.handleValidationAttributeChange = function (attributesList) {
|
||
|
var _this = this;
|
||
|
attributesList.some(function (attributeName) {
|
||
|
if (_constants__WEBPACK_IMPORTED_MODULE_2__["VALIDATION_ATTR_WHITELIST"].indexOf(attributeName) > -1) {
|
||
|
_this.styleValidity_(true);
|
||
|
return true;
|
||
|
}
|
||
|
return false;
|
||
|
});
|
||
|
if (attributesList.indexOf('maxlength') > -1) {
|
||
|
this.setCharacterCounter_(this.getValue().length);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Opens/closes the notched outline.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.notchOutline = function (openNotch) {
|
||
|
if (!this.adapter_.hasOutline()) {
|
||
|
return;
|
||
|
}
|
||
|
if (openNotch) {
|
||
|
var isDense = this.adapter_.hasClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].DENSE);
|
||
|
var labelScale = isDense ? _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"].DENSE_LABEL_SCALE : _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"].LABEL_SCALE;
|
||
|
var labelWidth = this.adapter_.getLabelWidth() * labelScale;
|
||
|
this.adapter_.notchOutline(labelWidth);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.closeOutline();
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Activates the text field focus state.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.activateFocus = function () {
|
||
|
this.isFocused_ = true;
|
||
|
this.styleFocused_(this.isFocused_);
|
||
|
this.adapter_.activateLineRipple();
|
||
|
if (this.adapter_.hasLabel()) {
|
||
|
this.notchOutline(this.shouldFloat);
|
||
|
this.adapter_.floatLabel(this.shouldFloat);
|
||
|
this.adapter_.shakeLabel(this.shouldShake);
|
||
|
}
|
||
|
if (this.helperText_) {
|
||
|
this.helperText_.showToScreenReader();
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Sets the line ripple's transform origin, so that the line ripple activate
|
||
|
* animation will animate out from the user's click location.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setTransformOrigin = function (evt) {
|
||
|
var touches = evt.touches;
|
||
|
var targetEvent = touches ? touches[0] : evt;
|
||
|
var targetClientRect = targetEvent.target.getBoundingClientRect();
|
||
|
var normalizedX = targetEvent.clientX - targetClientRect.left;
|
||
|
this.adapter_.setLineRippleTransformOrigin(normalizedX);
|
||
|
};
|
||
|
/**
|
||
|
* Handles input change of text input and text area.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.handleInput = function () {
|
||
|
this.autoCompleteFocus();
|
||
|
this.setCharacterCounter_(this.getValue().length);
|
||
|
};
|
||
|
/**
|
||
|
* Activates the Text Field's focus state in cases when the input value
|
||
|
* changes without user input (e.g. programmatically).
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.autoCompleteFocus = function () {
|
||
|
if (!this.receivedUserInput_) {
|
||
|
this.activateFocus();
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Deactivates the Text Field's focus state.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.deactivateFocus = function () {
|
||
|
this.isFocused_ = false;
|
||
|
this.adapter_.deactivateLineRipple();
|
||
|
var isValid = this.isValid();
|
||
|
this.styleValidity_(isValid);
|
||
|
this.styleFocused_(this.isFocused_);
|
||
|
if (this.adapter_.hasLabel()) {
|
||
|
this.notchOutline(this.shouldFloat);
|
||
|
this.adapter_.floatLabel(this.shouldFloat);
|
||
|
this.adapter_.shakeLabel(this.shouldShake);
|
||
|
}
|
||
|
if (!this.shouldFloat) {
|
||
|
this.receivedUserInput_ = false;
|
||
|
}
|
||
|
};
|
||
|
MDCTextFieldFoundation.prototype.getValue = function () {
|
||
|
return this.getNativeInput_().value;
|
||
|
};
|
||
|
/**
|
||
|
* @param value The value to set on the input Element.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setValue = function (value) {
|
||
|
// Prevent Safari from moving the caret to the end of the input when the value has not changed.
|
||
|
if (this.getValue() !== value) {
|
||
|
this.getNativeInput_().value = value;
|
||
|
}
|
||
|
this.setCharacterCounter_(value.length);
|
||
|
var isValid = this.isValid();
|
||
|
this.styleValidity_(isValid);
|
||
|
if (this.adapter_.hasLabel()) {
|
||
|
this.notchOutline(this.shouldFloat);
|
||
|
this.adapter_.floatLabel(this.shouldFloat);
|
||
|
this.adapter_.shakeLabel(this.shouldShake);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* @return The custom validity state, if set; otherwise, the result of a native validity check.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.isValid = function () {
|
||
|
return this.useNativeValidation_
|
||
|
? this.isNativeInputValid_() : this.isValid_;
|
||
|
};
|
||
|
/**
|
||
|
* @param isValid Sets the custom validity state of the Text Field.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setValid = function (isValid) {
|
||
|
this.isValid_ = isValid;
|
||
|
this.styleValidity_(isValid);
|
||
|
var shouldShake = !isValid && !this.isFocused_;
|
||
|
if (this.adapter_.hasLabel()) {
|
||
|
this.adapter_.shakeLabel(shouldShake);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Enables or disables the use of native validation. Use this for custom validation.
|
||
|
* @param useNativeValidation Set this to false to ignore native input validation.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setUseNativeValidation = function (useNativeValidation) {
|
||
|
this.useNativeValidation_ = useNativeValidation;
|
||
|
};
|
||
|
MDCTextFieldFoundation.prototype.isDisabled = function () {
|
||
|
return this.getNativeInput_().disabled;
|
||
|
};
|
||
|
/**
|
||
|
* @param disabled Sets the text-field disabled or enabled.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setDisabled = function (disabled) {
|
||
|
this.getNativeInput_().disabled = disabled;
|
||
|
this.styleDisabled_(disabled);
|
||
|
};
|
||
|
/**
|
||
|
* @param content Sets the content of the helper text.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setHelperTextContent = function (content) {
|
||
|
if (this.helperText_) {
|
||
|
this.helperText_.setContent(content);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Sets the aria label of the leading icon.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setLeadingIconAriaLabel = function (label) {
|
||
|
if (this.leadingIcon_) {
|
||
|
this.leadingIcon_.setAriaLabel(label);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Sets the text content of the leading icon.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setLeadingIconContent = function (content) {
|
||
|
if (this.leadingIcon_) {
|
||
|
this.leadingIcon_.setContent(content);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Sets the aria label of the trailing icon.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setTrailingIconAriaLabel = function (label) {
|
||
|
if (this.trailingIcon_) {
|
||
|
this.trailingIcon_.setAriaLabel(label);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Sets the text content of the trailing icon.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setTrailingIconContent = function (content) {
|
||
|
if (this.trailingIcon_) {
|
||
|
this.trailingIcon_.setContent(content);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Sets character counter values that shows characters used and the total character limit.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.setCharacterCounter_ = function (currentLength) {
|
||
|
if (!this.characterCounter_) {
|
||
|
return;
|
||
|
}
|
||
|
var maxLength = this.getNativeInput_().maxLength;
|
||
|
if (maxLength === -1) {
|
||
|
throw new Error('MDCTextFieldFoundation: Expected maxlength html property on text input or textarea.');
|
||
|
}
|
||
|
this.characterCounter_.setCounterValue(currentLength, maxLength);
|
||
|
};
|
||
|
/**
|
||
|
* @return True if the Text Field input fails in converting the user-supplied value.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.isBadInput_ = function () {
|
||
|
// The badInput property is not supported in IE 11 💩.
|
||
|
return this.getNativeInput_().validity.badInput || false;
|
||
|
};
|
||
|
/**
|
||
|
* @return The result of native validity checking (ValidityState.valid).
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.isNativeInputValid_ = function () {
|
||
|
return this.getNativeInput_().validity.valid;
|
||
|
};
|
||
|
/**
|
||
|
* Styles the component based on the validity state.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.styleValidity_ = function (isValid) {
|
||
|
var INVALID = MDCTextFieldFoundation.cssClasses.INVALID;
|
||
|
if (isValid) {
|
||
|
this.adapter_.removeClass(INVALID);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.addClass(INVALID);
|
||
|
}
|
||
|
if (this.helperText_) {
|
||
|
this.helperText_.setValidity(isValid);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Styles the component based on the focused state.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.styleFocused_ = function (isFocused) {
|
||
|
var FOCUSED = MDCTextFieldFoundation.cssClasses.FOCUSED;
|
||
|
if (isFocused) {
|
||
|
this.adapter_.addClass(FOCUSED);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(FOCUSED);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Styles the component based on the disabled state.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.styleDisabled_ = function (isDisabled) {
|
||
|
var _a = MDCTextFieldFoundation.cssClasses, DISABLED = _a.DISABLED, INVALID = _a.INVALID;
|
||
|
if (isDisabled) {
|
||
|
this.adapter_.addClass(DISABLED);
|
||
|
this.adapter_.removeClass(INVALID);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(DISABLED);
|
||
|
}
|
||
|
if (this.leadingIcon_) {
|
||
|
this.leadingIcon_.setDisabled(isDisabled);
|
||
|
}
|
||
|
if (this.trailingIcon_) {
|
||
|
this.trailingIcon_.setDisabled(isDisabled);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* @return The native text input element from the host environment, or an object with the same shape for unit tests.
|
||
|
*/
|
||
|
MDCTextFieldFoundation.prototype.getNativeInput_ = function () {
|
||
|
// this.adapter_ may be undefined in foundation unit tests. This happens when testdouble is creating a mock object
|
||
|
// and invokes the shouldShake/shouldFloat getters (which in turn call getValue(), which calls this method) before
|
||
|
// init() has been called from the MDCTextField constructor. To work around that issue, we return a dummy object.
|
||
|
var nativeInput = this.adapter_ ? this.adapter_.getNativeInput() : null;
|
||
|
return nativeInput || {
|
||
|
disabled: false,
|
||
|
maxLength: -1,
|
||
|
type: 'input',
|
||
|
validity: {
|
||
|
badInput: false,
|
||
|
valid: true,
|
||
|
},
|
||
|
value: '',
|
||
|
};
|
||
|
};
|
||
|
return MDCTextFieldFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCTextFieldFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/helper-text/component.js":
|
||
|
/*!*******************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/helper-text/component.js ***!
|
||
|
\*******************************************************************/
|
||
|
/*! exports provided: MDCTextFieldHelperText */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldHelperText", function() { return MDCTextFieldHelperText; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/helper-text/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2017 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTextFieldHelperText = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldHelperText, _super);
|
||
|
function MDCTextFieldHelperText() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCTextFieldHelperText.attachTo = function (root) {
|
||
|
return new MDCTextFieldHelperText(root);
|
||
|
};
|
||
|
Object.defineProperty(MDCTextFieldHelperText.prototype, "foundation", {
|
||
|
get: function () {
|
||
|
return this.foundation_;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCTextFieldHelperText.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = {
|
||
|
addClass: function (className) { return _this.root_.classList.add(className); },
|
||
|
removeClass: function (className) { return _this.root_.classList.remove(className); },
|
||
|
hasClass: function (className) { return _this.root_.classList.contains(className); },
|
||
|
setAttr: function (attr, value) { return _this.root_.setAttribute(attr, value); },
|
||
|
removeAttr: function (attr) { return _this.root_.removeAttribute(attr); },
|
||
|
setContent: function (content) {
|
||
|
_this.root_.textContent = content;
|
||
|
},
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTextFieldHelperTextFoundation"](adapter);
|
||
|
};
|
||
|
return MDCTextFieldHelperText;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/helper-text/constants.js":
|
||
|
/*!*******************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/helper-text/constants.js ***!
|
||
|
\*******************************************************************/
|
||
|
/*! exports provided: strings, cssClasses */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 cssClasses = {
|
||
|
HELPER_TEXT_PERSISTENT: 'mdc-text-field-helper-text--persistent',
|
||
|
HELPER_TEXT_VALIDATION_MSG: 'mdc-text-field-helper-text--validation-msg',
|
||
|
ROOT: 'mdc-text-field-helper-text',
|
||
|
};
|
||
|
var strings = {
|
||
|
ARIA_HIDDEN: 'aria-hidden',
|
||
|
ROLE: 'role',
|
||
|
ROOT_SELECTOR: "." + cssClasses.ROOT,
|
||
|
};
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/helper-text/foundation.js":
|
||
|
/*!********************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/helper-text/foundation.js ***!
|
||
|
\********************************************************************/
|
||
|
/*! exports provided: MDCTextFieldHelperTextFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldHelperTextFoundation", function() { return MDCTextFieldHelperTextFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/helper-text/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2017 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTextFieldHelperTextFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldHelperTextFoundation, _super);
|
||
|
function MDCTextFieldHelperTextFoundation(adapter) {
|
||
|
return _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCTextFieldHelperTextFoundation.defaultAdapter, adapter)) || this;
|
||
|
}
|
||
|
Object.defineProperty(MDCTextFieldHelperTextFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldHelperTextFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldHelperTextFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCTextFieldHelperTextAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
hasClass: function () { return false; },
|
||
|
setAttr: function () { return undefined; },
|
||
|
removeAttr: function () { return undefined; },
|
||
|
setContent: function () { return undefined; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
/**
|
||
|
* Sets the content of the helper text field.
|
||
|
*/
|
||
|
MDCTextFieldHelperTextFoundation.prototype.setContent = function (content) {
|
||
|
this.adapter_.setContent(content);
|
||
|
};
|
||
|
/**
|
||
|
* @param isPersistent Sets the persistency of the helper text.
|
||
|
*/
|
||
|
MDCTextFieldHelperTextFoundation.prototype.setPersistent = function (isPersistent) {
|
||
|
if (isPersistent) {
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].HELPER_TEXT_PERSISTENT);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].HELPER_TEXT_PERSISTENT);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* @param isValidation True to make the helper text act as an error validation message.
|
||
|
*/
|
||
|
MDCTextFieldHelperTextFoundation.prototype.setValidation = function (isValidation) {
|
||
|
if (isValidation) {
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].HELPER_TEXT_VALIDATION_MSG);
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].HELPER_TEXT_VALIDATION_MSG);
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Makes the helper text visible to the screen reader.
|
||
|
*/
|
||
|
MDCTextFieldHelperTextFoundation.prototype.showToScreenReader = function () {
|
||
|
this.adapter_.removeAttr(_constants__WEBPACK_IMPORTED_MODULE_2__["strings"].ARIA_HIDDEN);
|
||
|
};
|
||
|
/**
|
||
|
* Sets the validity of the helper text based on the input validity.
|
||
|
*/
|
||
|
MDCTextFieldHelperTextFoundation.prototype.setValidity = function (inputIsValid) {
|
||
|
var helperTextIsPersistent = this.adapter_.hasClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].HELPER_TEXT_PERSISTENT);
|
||
|
var helperTextIsValidationMsg = this.adapter_.hasClass(_constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"].HELPER_TEXT_VALIDATION_MSG);
|
||
|
var validationMsgNeedsDisplay = helperTextIsValidationMsg && !inputIsValid;
|
||
|
if (validationMsgNeedsDisplay) {
|
||
|
this.adapter_.setAttr(_constants__WEBPACK_IMPORTED_MODULE_2__["strings"].ROLE, 'alert');
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.removeAttr(_constants__WEBPACK_IMPORTED_MODULE_2__["strings"].ROLE);
|
||
|
}
|
||
|
if (!helperTextIsPersistent && !validationMsgNeedsDisplay) {
|
||
|
this.hide_();
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Hides the help text from screen readers.
|
||
|
*/
|
||
|
MDCTextFieldHelperTextFoundation.prototype.hide_ = function () {
|
||
|
this.adapter_.setAttr(_constants__WEBPACK_IMPORTED_MODULE_2__["strings"].ARIA_HIDDEN, 'true');
|
||
|
};
|
||
|
return MDCTextFieldHelperTextFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCTextFieldHelperTextFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/helper-text/index.js":
|
||
|
/*!***************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/helper-text/index.js ***!
|
||
|
\***************************************************************/
|
||
|
/*! exports provided: helperTextCssClasses, helperTextStrings, MDCTextFieldHelperText, MDCTextFieldHelperTextFoundation */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./component */ "./node_modules/@material/textfield/helper-text/component.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldHelperText", function() { return _component__WEBPACK_IMPORTED_MODULE_0__["MDCTextFieldHelperText"]; });
|
||
|
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/helper-text/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldHelperTextFoundation", function() { return _foundation__WEBPACK_IMPORTED_MODULE_1__["MDCTextFieldHelperTextFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/helper-text/constants.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "helperTextCssClasses", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "helperTextStrings", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"]; });
|
||
|
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
//# sourceMappingURL=index.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/icon/component.js":
|
||
|
/*!************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/icon/component.js ***!
|
||
|
\************************************************************/
|
||
|
/*! exports provided: MDCTextFieldIcon */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldIcon", function() { return MDCTextFieldIcon; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/icon/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2017 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTextFieldIcon = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldIcon, _super);
|
||
|
function MDCTextFieldIcon() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCTextFieldIcon.attachTo = function (root) {
|
||
|
return new MDCTextFieldIcon(root);
|
||
|
};
|
||
|
Object.defineProperty(MDCTextFieldIcon.prototype, "foundation", {
|
||
|
get: function () {
|
||
|
return this.foundation_;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCTextFieldIcon.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = {
|
||
|
getAttr: function (attr) { return _this.root_.getAttribute(attr); },
|
||
|
setAttr: function (attr, value) { return _this.root_.setAttribute(attr, value); },
|
||
|
removeAttr: function (attr) { return _this.root_.removeAttribute(attr); },
|
||
|
setContent: function (content) {
|
||
|
_this.root_.textContent = content;
|
||
|
},
|
||
|
registerInteractionHandler: function (evtType, handler) { return _this.listen(evtType, handler); },
|
||
|
deregisterInteractionHandler: function (evtType, handler) { return _this.unlisten(evtType, handler); },
|
||
|
notifyIconAction: function () { return _this.emit(_foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTextFieldIconFoundation"].strings.ICON_EVENT, {} /* evtData */, true /* shouldBubble */); },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
return new _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTextFieldIconFoundation"](adapter);
|
||
|
};
|
||
|
return MDCTextFieldIcon;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/icon/constants.js":
|
||
|
/*!************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/icon/constants.js ***!
|
||
|
\************************************************************/
|
||
|
/*! exports provided: strings, cssClasses */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2016 Google Inc.
|
||
|
*
|
||
|
* 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 strings = {
|
||
|
ICON_EVENT: 'MDCTextField:icon',
|
||
|
ICON_ROLE: 'button',
|
||
|
};
|
||
|
var cssClasses = {
|
||
|
ROOT: 'mdc-text-field__icon',
|
||
|
};
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/icon/foundation.js":
|
||
|
/*!*************************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/icon/foundation.js ***!
|
||
|
\*************************************************************/
|
||
|
/*! exports provided: MDCTextFieldIconFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldIconFoundation", function() { return MDCTextFieldIconFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/icon/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2017 Google Inc.
|
||
|
*
|
||
|
* 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 INTERACTION_EVENTS = ['click', 'keydown'];
|
||
|
var MDCTextFieldIconFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTextFieldIconFoundation, _super);
|
||
|
function MDCTextFieldIconFoundation(adapter) {
|
||
|
var _this = _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCTextFieldIconFoundation.defaultAdapter, adapter)) || this;
|
||
|
_this.savedTabIndex_ = null;
|
||
|
_this.interactionHandler_ = function (evt) { return _this.handleInteraction(evt); };
|
||
|
return _this;
|
||
|
}
|
||
|
Object.defineProperty(MDCTextFieldIconFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldIconFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTextFieldIconFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCTextFieldIconAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
getAttr: function () { return null; },
|
||
|
setAttr: function () { return undefined; },
|
||
|
removeAttr: function () { return undefined; },
|
||
|
setContent: function () { return undefined; },
|
||
|
registerInteractionHandler: function () { return undefined; },
|
||
|
deregisterInteractionHandler: function () { return undefined; },
|
||
|
notifyIconAction: function () { return undefined; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCTextFieldIconFoundation.prototype.init = function () {
|
||
|
var _this = this;
|
||
|
this.savedTabIndex_ = this.adapter_.getAttr('tabindex');
|
||
|
INTERACTION_EVENTS.forEach(function (evtType) {
|
||
|
_this.adapter_.registerInteractionHandler(evtType, _this.interactionHandler_);
|
||
|
});
|
||
|
};
|
||
|
MDCTextFieldIconFoundation.prototype.destroy = function () {
|
||
|
var _this = this;
|
||
|
INTERACTION_EVENTS.forEach(function (evtType) {
|
||
|
_this.adapter_.deregisterInteractionHandler(evtType, _this.interactionHandler_);
|
||
|
});
|
||
|
};
|
||
|
MDCTextFieldIconFoundation.prototype.setDisabled = function (disabled) {
|
||
|
if (!this.savedTabIndex_) {
|
||
|
return;
|
||
|
}
|
||
|
if (disabled) {
|
||
|
this.adapter_.setAttr('tabindex', '-1');
|
||
|
this.adapter_.removeAttr('role');
|
||
|
}
|
||
|
else {
|
||
|
this.adapter_.setAttr('tabindex', this.savedTabIndex_);
|
||
|
this.adapter_.setAttr('role', _constants__WEBPACK_IMPORTED_MODULE_2__["strings"].ICON_ROLE);
|
||
|
}
|
||
|
};
|
||
|
MDCTextFieldIconFoundation.prototype.setAriaLabel = function (label) {
|
||
|
this.adapter_.setAttr('aria-label', label);
|
||
|
};
|
||
|
MDCTextFieldIconFoundation.prototype.setContent = function (content) {
|
||
|
this.adapter_.setContent(content);
|
||
|
};
|
||
|
MDCTextFieldIconFoundation.prototype.handleInteraction = function (evt) {
|
||
|
var isEnterKey = evt.key === 'Enter' || evt.keyCode === 13;
|
||
|
if (evt.type === 'click' || isEnterKey) {
|
||
|
this.adapter_.notifyIconAction();
|
||
|
}
|
||
|
};
|
||
|
return MDCTextFieldIconFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCTextFieldIconFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/icon/index.js":
|
||
|
/*!********************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/icon/index.js ***!
|
||
|
\********************************************************/
|
||
|
/*! exports provided: iconCssClasses, iconStrings, MDCTextFieldIcon, MDCTextFieldIconFoundation */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./component */ "./node_modules/@material/textfield/icon/component.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldIcon", function() { return _component__WEBPACK_IMPORTED_MODULE_0__["MDCTextFieldIcon"]; });
|
||
|
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/icon/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldIconFoundation", function() { return _foundation__WEBPACK_IMPORTED_MODULE_1__["MDCTextFieldIconFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/icon/constants.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "iconCssClasses", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "iconStrings", function() { return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"]; });
|
||
|
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
//# sourceMappingURL=index.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/textfield/index.js":
|
||
|
/*!***************************************************!*\
|
||
|
!*** ./node_modules/@material/textfield/index.js ***!
|
||
|
\***************************************************/
|
||
|
/*! exports provided: MDCTextField, cssClasses, strings, numbers, VALIDATION_ATTR_WHITELIST, ALWAYS_FLOAT_TYPES, MDCTextFieldFoundation, characterCountCssClasses, characterCountStrings, helperTextCssClasses, helperTextStrings, iconCssClasses, iconStrings, MDCTextFieldCharacterCounter, MDCTextFieldCharacterCounterFoundation, MDCTextFieldHelperText, MDCTextFieldHelperTextFoundation, MDCTextFieldIcon, MDCTextFieldIconFoundation */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./component */ "./node_modules/@material/textfield/component.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextField", function() { return _component__WEBPACK_IMPORTED_MODULE_0__["MDCTextField"]; });
|
||
|
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/textfield/constants.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["strings"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["numbers"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "VALIDATION_ATTR_WHITELIST", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["VALIDATION_ATTR_WHITELIST"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "ALWAYS_FLOAT_TYPES", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["ALWAYS_FLOAT_TYPES"]; });
|
||
|
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/textfield/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldFoundation", function() { return _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTextFieldFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _character_counter_index__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./character-counter/index */ "./node_modules/@material/textfield/character-counter/index.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "characterCountCssClasses", function() { return _character_counter_index__WEBPACK_IMPORTED_MODULE_3__["characterCountCssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "characterCountStrings", function() { return _character_counter_index__WEBPACK_IMPORTED_MODULE_3__["characterCountStrings"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldCharacterCounter", function() { return _character_counter_index__WEBPACK_IMPORTED_MODULE_3__["MDCTextFieldCharacterCounter"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldCharacterCounterFoundation", function() { return _character_counter_index__WEBPACK_IMPORTED_MODULE_3__["MDCTextFieldCharacterCounterFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _helper_text_index__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./helper-text/index */ "./node_modules/@material/textfield/helper-text/index.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "helperTextCssClasses", function() { return _helper_text_index__WEBPACK_IMPORTED_MODULE_4__["helperTextCssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "helperTextStrings", function() { return _helper_text_index__WEBPACK_IMPORTED_MODULE_4__["helperTextStrings"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldHelperText", function() { return _helper_text_index__WEBPACK_IMPORTED_MODULE_4__["MDCTextFieldHelperText"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldHelperTextFoundation", function() { return _helper_text_index__WEBPACK_IMPORTED_MODULE_4__["MDCTextFieldHelperTextFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _icon_index__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./icon/index */ "./node_modules/@material/textfield/icon/index.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "iconCssClasses", function() { return _icon_index__WEBPACK_IMPORTED_MODULE_5__["iconCssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "iconStrings", function() { return _icon_index__WEBPACK_IMPORTED_MODULE_5__["iconStrings"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldIcon", function() { return _icon_index__WEBPACK_IMPORTED_MODULE_5__["MDCTextFieldIcon"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTextFieldIconFoundation", function() { return _icon_index__WEBPACK_IMPORTED_MODULE_5__["MDCTextFieldIconFoundation"]; });
|
||
|
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
//# sourceMappingURL=index.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/component.js":
|
||
|
/*!*********************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/component.js ***!
|
||
|
\*********************************************************/
|
||
|
/*! exports provided: MDCTopAppBar */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTopAppBar", function() { return MDCTopAppBar; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/component */ "./node_modules/@material/base/component.js");
|
||
|
/* harmony import */ var _material_ripple_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @material/ripple/component */ "./node_modules/@material/ripple/component.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/top-app-bar/constants.js");
|
||
|
/* harmony import */ var _fixed_foundation__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./fixed/foundation */ "./node_modules/@material/top-app-bar/fixed/foundation.js");
|
||
|
/* harmony import */ var _short_foundation__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./short/foundation */ "./node_modules/@material/top-app-bar/short/foundation.js");
|
||
|
/* harmony import */ var _standard_foundation__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./standard/foundation */ "./node_modules/@material/top-app-bar/standard/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTopAppBar = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTopAppBar, _super);
|
||
|
function MDCTopAppBar() {
|
||
|
return _super !== null && _super.apply(this, arguments) || this;
|
||
|
}
|
||
|
MDCTopAppBar.attachTo = function (root) {
|
||
|
return new MDCTopAppBar(root);
|
||
|
};
|
||
|
MDCTopAppBar.prototype.initialize = function (rippleFactory) {
|
||
|
if (rippleFactory === void 0) { rippleFactory = function (el) { return _material_ripple_component__WEBPACK_IMPORTED_MODULE_2__["MDCRipple"].attachTo(el); }; }
|
||
|
this.navIcon_ = this.root_.querySelector(_constants__WEBPACK_IMPORTED_MODULE_3__["strings"].NAVIGATION_ICON_SELECTOR);
|
||
|
// Get all icons in the toolbar and instantiate the ripples
|
||
|
var icons = [].slice.call(this.root_.querySelectorAll(_constants__WEBPACK_IMPORTED_MODULE_3__["strings"].ACTION_ITEM_SELECTOR));
|
||
|
if (this.navIcon_) {
|
||
|
icons.push(this.navIcon_);
|
||
|
}
|
||
|
this.iconRipples_ = icons.map(function (icon) {
|
||
|
var ripple = rippleFactory(icon);
|
||
|
ripple.unbounded = true;
|
||
|
return ripple;
|
||
|
});
|
||
|
this.scrollTarget_ = window;
|
||
|
};
|
||
|
MDCTopAppBar.prototype.initialSyncWithDOM = function () {
|
||
|
this.handleNavigationClick_ = this.foundation_.handleNavigationClick.bind(this.foundation_);
|
||
|
this.handleWindowResize_ = this.foundation_.handleWindowResize.bind(this.foundation_);
|
||
|
this.handleTargetScroll_ = this.foundation_.handleTargetScroll.bind(this.foundation_);
|
||
|
this.scrollTarget_.addEventListener('scroll', this.handleTargetScroll_);
|
||
|
if (this.navIcon_) {
|
||
|
this.navIcon_.addEventListener('click', this.handleNavigationClick_);
|
||
|
}
|
||
|
var isFixed = this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].FIXED_CLASS);
|
||
|
var isShort = this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].SHORT_CLASS);
|
||
|
if (!isShort && !isFixed) {
|
||
|
window.addEventListener('resize', this.handleWindowResize_);
|
||
|
}
|
||
|
};
|
||
|
MDCTopAppBar.prototype.destroy = function () {
|
||
|
this.iconRipples_.forEach(function (iconRipple) { return iconRipple.destroy(); });
|
||
|
this.scrollTarget_.removeEventListener('scroll', this.handleTargetScroll_);
|
||
|
if (this.navIcon_) {
|
||
|
this.navIcon_.removeEventListener('click', this.handleNavigationClick_);
|
||
|
}
|
||
|
var isFixed = this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].FIXED_CLASS);
|
||
|
var isShort = this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].SHORT_CLASS);
|
||
|
if (!isShort && !isFixed) {
|
||
|
window.removeEventListener('resize', this.handleWindowResize_);
|
||
|
}
|
||
|
_super.prototype.destroy.call(this);
|
||
|
};
|
||
|
MDCTopAppBar.prototype.setScrollTarget = function (target) {
|
||
|
// Remove scroll handler from the previous scroll target
|
||
|
this.scrollTarget_.removeEventListener('scroll', this.handleTargetScroll_);
|
||
|
this.scrollTarget_ = target;
|
||
|
// Initialize scroll handler on the new scroll target
|
||
|
this.handleTargetScroll_ =
|
||
|
this.foundation_.handleTargetScroll.bind(this.foundation_);
|
||
|
this.scrollTarget_.addEventListener('scroll', this.handleTargetScroll_);
|
||
|
};
|
||
|
MDCTopAppBar.prototype.getDefaultFoundation = function () {
|
||
|
var _this = this;
|
||
|
// DO NOT INLINE this variable. For backward compatibility, foundations take a Partial<MDCFooAdapter>.
|
||
|
// To ensure we don't accidentally omit any methods, we need a separate, strongly typed adapter variable.
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
var adapter = {
|
||
|
hasClass: function (className) { return _this.root_.classList.contains(className); },
|
||
|
addClass: function (className) { return _this.root_.classList.add(className); },
|
||
|
removeClass: function (className) { return _this.root_.classList.remove(className); },
|
||
|
setStyle: function (property, value) { return _this.root_.style.setProperty(property, value); },
|
||
|
getTopAppBarHeight: function () { return _this.root_.clientHeight; },
|
||
|
notifyNavigationIconClicked: function () { return _this.emit(_constants__WEBPACK_IMPORTED_MODULE_3__["strings"].NAVIGATION_EVENT, {}); },
|
||
|
getViewportScrollY: function () {
|
||
|
var win = _this.scrollTarget_;
|
||
|
var el = _this.scrollTarget_;
|
||
|
return win.pageYOffset !== undefined ? win.pageYOffset : el.scrollTop;
|
||
|
},
|
||
|
getTotalActionItems: function () { return _this.root_.querySelectorAll(_constants__WEBPACK_IMPORTED_MODULE_3__["strings"].ACTION_ITEM_SELECTOR).length; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
var foundation;
|
||
|
if (this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].SHORT_CLASS)) {
|
||
|
foundation = new _short_foundation__WEBPACK_IMPORTED_MODULE_5__["MDCShortTopAppBarFoundation"](adapter);
|
||
|
}
|
||
|
else if (this.root_.classList.contains(_constants__WEBPACK_IMPORTED_MODULE_3__["cssClasses"].FIXED_CLASS)) {
|
||
|
foundation = new _fixed_foundation__WEBPACK_IMPORTED_MODULE_4__["MDCFixedTopAppBarFoundation"](adapter);
|
||
|
}
|
||
|
else {
|
||
|
foundation = new _standard_foundation__WEBPACK_IMPORTED_MODULE_6__["MDCTopAppBarFoundation"](adapter);
|
||
|
}
|
||
|
return foundation;
|
||
|
};
|
||
|
return MDCTopAppBar;
|
||
|
}(_material_base_component__WEBPACK_IMPORTED_MODULE_1__["MDCComponent"]));
|
||
|
|
||
|
//# sourceMappingURL=component.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/constants.js":
|
||
|
/*!*********************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/constants.js ***!
|
||
|
\*********************************************************/
|
||
|
/*! exports provided: cssClasses, numbers, strings */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return cssClasses; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return numbers; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return strings; });
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 cssClasses = {
|
||
|
FIXED_CLASS: 'mdc-top-app-bar--fixed',
|
||
|
FIXED_SCROLLED_CLASS: 'mdc-top-app-bar--fixed-scrolled',
|
||
|
SHORT_CLASS: 'mdc-top-app-bar--short',
|
||
|
SHORT_COLLAPSED_CLASS: 'mdc-top-app-bar--short-collapsed',
|
||
|
SHORT_HAS_ACTION_ITEM_CLASS: 'mdc-top-app-bar--short-has-action-item',
|
||
|
};
|
||
|
var numbers = {
|
||
|
DEBOUNCE_THROTTLE_RESIZE_TIME_MS: 100,
|
||
|
MAX_TOP_APP_BAR_HEIGHT: 128,
|
||
|
};
|
||
|
var strings = {
|
||
|
ACTION_ITEM_SELECTOR: '.mdc-top-app-bar__action-item',
|
||
|
NAVIGATION_EVENT: 'MDCTopAppBar:nav',
|
||
|
NAVIGATION_ICON_SELECTOR: '.mdc-top-app-bar__navigation-icon',
|
||
|
ROOT_SELECTOR: '.mdc-top-app-bar',
|
||
|
TITLE_SELECTOR: '.mdc-top-app-bar__title',
|
||
|
};
|
||
|
|
||
|
//# sourceMappingURL=constants.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/fixed/foundation.js":
|
||
|
/*!****************************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/fixed/foundation.js ***!
|
||
|
\****************************************************************/
|
||
|
/*! exports provided: MDCFixedTopAppBarFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCFixedTopAppBarFoundation", function() { return MDCFixedTopAppBarFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../constants */ "./node_modules/@material/top-app-bar/constants.js");
|
||
|
/* harmony import */ var _standard_foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../standard/foundation */ "./node_modules/@material/top-app-bar/standard/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 MDCFixedTopAppBarFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCFixedTopAppBarFoundation, _super);
|
||
|
function MDCFixedTopAppBarFoundation() {
|
||
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
||
|
/**
|
||
|
* State variable for the previous scroll iteration top app bar state
|
||
|
*/
|
||
|
_this.wasScrolled_ = false;
|
||
|
return _this;
|
||
|
}
|
||
|
/**
|
||
|
* Scroll handler for applying/removing the modifier class on the fixed top app bar.
|
||
|
* @override
|
||
|
*/
|
||
|
MDCFixedTopAppBarFoundation.prototype.handleTargetScroll = function () {
|
||
|
var currentScroll = this.adapter_.getViewportScrollY();
|
||
|
if (currentScroll <= 0) {
|
||
|
if (this.wasScrolled_) {
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"].FIXED_SCROLLED_CLASS);
|
||
|
this.wasScrolled_ = false;
|
||
|
}
|
||
|
}
|
||
|
else {
|
||
|
if (!this.wasScrolled_) {
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"].FIXED_SCROLLED_CLASS);
|
||
|
this.wasScrolled_ = true;
|
||
|
}
|
||
|
}
|
||
|
};
|
||
|
return MDCFixedTopAppBarFoundation;
|
||
|
}(_standard_foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTopAppBarFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCFixedTopAppBarFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/foundation.js":
|
||
|
/*!**********************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/foundation.js ***!
|
||
|
\**********************************************************/
|
||
|
/*! exports provided: MDCTopAppBarBaseFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTopAppBarBaseFoundation", function() { return MDCTopAppBarBaseFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _material_base_foundation__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/base/foundation */ "./node_modules/@material/base/foundation.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/top-app-bar/constants.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 MDCTopAppBarBaseFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTopAppBarBaseFoundation, _super);
|
||
|
/* istanbul ignore next: optional argument is not a branch statement */
|
||
|
function MDCTopAppBarBaseFoundation(adapter) {
|
||
|
return _super.call(this, tslib__WEBPACK_IMPORTED_MODULE_0__["__assign"]({}, MDCTopAppBarBaseFoundation.defaultAdapter, adapter)) || this;
|
||
|
}
|
||
|
Object.defineProperty(MDCTopAppBarBaseFoundation, "strings", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["strings"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTopAppBarBaseFoundation, "cssClasses", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["cssClasses"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTopAppBarBaseFoundation, "numbers", {
|
||
|
get: function () {
|
||
|
return _constants__WEBPACK_IMPORTED_MODULE_2__["numbers"];
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
Object.defineProperty(MDCTopAppBarBaseFoundation, "defaultAdapter", {
|
||
|
/**
|
||
|
* See {@link MDCTopAppBarAdapter} for typing information on parameters and return types.
|
||
|
*/
|
||
|
get: function () {
|
||
|
// tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.
|
||
|
return {
|
||
|
addClass: function () { return undefined; },
|
||
|
removeClass: function () { return undefined; },
|
||
|
hasClass: function () { return false; },
|
||
|
setStyle: function () { return undefined; },
|
||
|
getTopAppBarHeight: function () { return 0; },
|
||
|
notifyNavigationIconClicked: function () { return undefined; },
|
||
|
getViewportScrollY: function () { return 0; },
|
||
|
getTotalActionItems: function () { return 0; },
|
||
|
};
|
||
|
// tslint:enable:object-literal-sort-keys
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
/** Other variants of TopAppBar foundation overrides this method */
|
||
|
MDCTopAppBarBaseFoundation.prototype.handleTargetScroll = function () { }; // tslint:disable-line:no-empty
|
||
|
/** Other variants of TopAppBar foundation overrides this method */
|
||
|
MDCTopAppBarBaseFoundation.prototype.handleWindowResize = function () { }; // tslint:disable-line:no-empty
|
||
|
MDCTopAppBarBaseFoundation.prototype.handleNavigationClick = function () {
|
||
|
this.adapter_.notifyNavigationIconClicked();
|
||
|
};
|
||
|
return MDCTopAppBarBaseFoundation;
|
||
|
}(_material_base_foundation__WEBPACK_IMPORTED_MODULE_1__["MDCFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCTopAppBarBaseFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/index.js":
|
||
|
/*!*****************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/index.js ***!
|
||
|
\*****************************************************/
|
||
|
/*! exports provided: MDCTopAppBar, cssClasses, numbers, strings, MDCTopAppBarBaseFoundation, MDCFixedTopAppBarFoundation, MDCShortTopAppBarFoundation, MDCTopAppBarFoundation */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./component */ "./node_modules/@material/top-app-bar/component.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTopAppBar", function() { return _component__WEBPACK_IMPORTED_MODULE_0__["MDCTopAppBar"]; });
|
||
|
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./constants */ "./node_modules/@material/top-app-bar/constants.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "cssClasses", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "numbers", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["numbers"]; });
|
||
|
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "strings", function() { return _constants__WEBPACK_IMPORTED_MODULE_1__["strings"]; });
|
||
|
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./foundation */ "./node_modules/@material/top-app-bar/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTopAppBarBaseFoundation", function() { return _foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTopAppBarBaseFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _fixed_foundation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./fixed/foundation */ "./node_modules/@material/top-app-bar/fixed/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCFixedTopAppBarFoundation", function() { return _fixed_foundation__WEBPACK_IMPORTED_MODULE_3__["MDCFixedTopAppBarFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _short_foundation__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./short/foundation */ "./node_modules/@material/top-app-bar/short/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCShortTopAppBarFoundation", function() { return _short_foundation__WEBPACK_IMPORTED_MODULE_4__["MDCShortTopAppBarFoundation"]; });
|
||
|
|
||
|
/* harmony import */ var _standard_foundation__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./standard/foundation */ "./node_modules/@material/top-app-bar/standard/foundation.js");
|
||
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "MDCTopAppBarFoundation", function() { return _standard_foundation__WEBPACK_IMPORTED_MODULE_5__["MDCTopAppBarFoundation"]; });
|
||
|
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2019 Google Inc.
|
||
|
*
|
||
|
* 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.
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
//# sourceMappingURL=index.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/short/foundation.js":
|
||
|
/*!****************************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/short/foundation.js ***!
|
||
|
\****************************************************************/
|
||
|
/*! exports provided: MDCShortTopAppBarFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCShortTopAppBarFoundation", function() { return MDCShortTopAppBarFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../constants */ "./node_modules/@material/top-app-bar/constants.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../foundation */ "./node_modules/@material/top-app-bar/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 MDCShortTopAppBarFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCShortTopAppBarFoundation, _super);
|
||
|
/* istanbul ignore next: optional argument is not a branch statement */
|
||
|
function MDCShortTopAppBarFoundation(adapter) {
|
||
|
var _this = _super.call(this, adapter) || this;
|
||
|
_this.isCollapsed_ = false;
|
||
|
_this.isAlwaysCollapsed_ = false;
|
||
|
return _this;
|
||
|
}
|
||
|
Object.defineProperty(MDCShortTopAppBarFoundation.prototype, "isCollapsed", {
|
||
|
// Public visibility for backward compatibility.
|
||
|
get: function () {
|
||
|
return this.isCollapsed_;
|
||
|
},
|
||
|
enumerable: true,
|
||
|
configurable: true
|
||
|
});
|
||
|
MDCShortTopAppBarFoundation.prototype.init = function () {
|
||
|
_super.prototype.init.call(this);
|
||
|
if (this.adapter_.getTotalActionItems() > 0) {
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"].SHORT_HAS_ACTION_ITEM_CLASS);
|
||
|
}
|
||
|
// If initialized with SHORT_COLLAPSED_CLASS, the bar should always be collapsed
|
||
|
this.setAlwaysCollapsed(this.adapter_.hasClass(_constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"].SHORT_COLLAPSED_CLASS));
|
||
|
};
|
||
|
/**
|
||
|
* Set if the short top app bar should always be collapsed.
|
||
|
*
|
||
|
* @param value When `true`, bar will always be collapsed. When `false`, bar may collapse or expand based on scroll.
|
||
|
*/
|
||
|
MDCShortTopAppBarFoundation.prototype.setAlwaysCollapsed = function (value) {
|
||
|
this.isAlwaysCollapsed_ = !!value;
|
||
|
if (this.isAlwaysCollapsed_) {
|
||
|
this.collapse_();
|
||
|
}
|
||
|
else {
|
||
|
// let maybeCollapseBar_ determine if the bar should be collapsed
|
||
|
this.maybeCollapseBar_();
|
||
|
}
|
||
|
};
|
||
|
MDCShortTopAppBarFoundation.prototype.getAlwaysCollapsed = function () {
|
||
|
return this.isAlwaysCollapsed_;
|
||
|
};
|
||
|
/**
|
||
|
* Scroll handler for applying/removing the collapsed modifier class on the short top app bar.
|
||
|
* @override
|
||
|
*/
|
||
|
MDCShortTopAppBarFoundation.prototype.handleTargetScroll = function () {
|
||
|
this.maybeCollapseBar_();
|
||
|
};
|
||
|
MDCShortTopAppBarFoundation.prototype.maybeCollapseBar_ = function () {
|
||
|
if (this.isAlwaysCollapsed_) {
|
||
|
return;
|
||
|
}
|
||
|
var currentScroll = this.adapter_.getViewportScrollY();
|
||
|
if (currentScroll <= 0) {
|
||
|
if (this.isCollapsed_) {
|
||
|
this.uncollapse_();
|
||
|
}
|
||
|
}
|
||
|
else {
|
||
|
if (!this.isCollapsed_) {
|
||
|
this.collapse_();
|
||
|
}
|
||
|
}
|
||
|
};
|
||
|
MDCShortTopAppBarFoundation.prototype.uncollapse_ = function () {
|
||
|
this.adapter_.removeClass(_constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"].SHORT_COLLAPSED_CLASS);
|
||
|
this.isCollapsed_ = false;
|
||
|
};
|
||
|
MDCShortTopAppBarFoundation.prototype.collapse_ = function () {
|
||
|
this.adapter_.addClass(_constants__WEBPACK_IMPORTED_MODULE_1__["cssClasses"].SHORT_COLLAPSED_CLASS);
|
||
|
this.isCollapsed_ = true;
|
||
|
};
|
||
|
return MDCShortTopAppBarFoundation;
|
||
|
}(_foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTopAppBarBaseFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCShortTopAppBarFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/@material/top-app-bar/standard/foundation.js":
|
||
|
/*!*******************************************************************!*\
|
||
|
!*** ./node_modules/@material/top-app-bar/standard/foundation.js ***!
|
||
|
\*******************************************************************/
|
||
|
/*! exports provided: MDCTopAppBarFoundation, default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "MDCTopAppBarFoundation", function() { return MDCTopAppBarFoundation; });
|
||
|
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! tslib */ "./node_modules/tslib/tslib.es6.js");
|
||
|
/* harmony import */ var _constants__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../constants */ "./node_modules/@material/top-app-bar/constants.js");
|
||
|
/* harmony import */ var _foundation__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../foundation */ "./node_modules/@material/top-app-bar/foundation.js");
|
||
|
/**
|
||
|
* @license
|
||
|
* Copyright 2018 Google Inc.
|
||
|
*
|
||
|
* 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 INITIAL_VALUE = 0;
|
||
|
var MDCTopAppBarFoundation = /** @class */ (function (_super) {
|
||
|
tslib__WEBPACK_IMPORTED_MODULE_0__["__extends"](MDCTopAppBarFoundation, _super);
|
||
|
/* istanbul ignore next: optional argument is not a branch statement */
|
||
|
function MDCTopAppBarFoundation(adapter) {
|
||
|
var _this = _super.call(this, adapter) || this;
|
||
|
/**
|
||
|
* Indicates if the top app bar was docked in the previous scroll handler iteration.
|
||
|
*/
|
||
|
_this.wasDocked_ = true;
|
||
|
/**
|
||
|
* Indicates if the top app bar is docked in the fully shown position.
|
||
|
*/
|
||
|
_this.isDockedShowing_ = true;
|
||
|
/**
|
||
|
* Variable for current scroll position of the top app bar
|
||
|
*/
|
||
|
_this.currentAppBarOffsetTop_ = 0;
|
||
|
/**
|
||
|
* Used to prevent the top app bar from being scrolled out of view during resize events
|
||
|
*/
|
||
|
_this.isCurrentlyBeingResized_ = false;
|
||
|
/**
|
||
|
* The timeout that's used to throttle the resize events
|
||
|
*/
|
||
|
_this.resizeThrottleId_ = INITIAL_VALUE;
|
||
|
/**
|
||
|
* The timeout that's used to debounce toggling the isCurrentlyBeingResized_ variable after a resize
|
||
|
*/
|
||
|
_this.resizeDebounceId_ = INITIAL_VALUE;
|
||
|
_this.lastScrollPosition_ = _this.adapter_.getViewportScrollY();
|
||
|
_this.topAppBarHeight_ = _this.adapter_.getTopAppBarHeight();
|
||
|
return _this;
|
||
|
}
|
||
|
MDCTopAppBarFoundation.prototype.destroy = function () {
|
||
|
_super.prototype.destroy.call(this);
|
||
|
this.adapter_.setStyle('top', '');
|
||
|
};
|
||
|
/**
|
||
|
* Scroll handler for the default scroll behavior of the top app bar.
|
||
|
* @override
|
||
|
*/
|
||
|
MDCTopAppBarFoundation.prototype.handleTargetScroll = function () {
|
||
|
var currentScrollPosition = Math.max(this.adapter_.getViewportScrollY(), 0);
|
||
|
var diff = currentScrollPosition - this.lastScrollPosition_;
|
||
|
this.lastScrollPosition_ = currentScrollPosition;
|
||
|
// If the window is being resized the lastScrollPosition_ needs to be updated but the
|
||
|
// current scroll of the top app bar should stay in the same position.
|
||
|
if (!this.isCurrentlyBeingResized_) {
|
||
|
this.currentAppBarOffsetTop_ -= diff;
|
||
|
if (this.currentAppBarOffsetTop_ > 0) {
|
||
|
this.currentAppBarOffsetTop_ = 0;
|
||
|
}
|
||
|
else if (Math.abs(this.currentAppBarOffsetTop_) > this.topAppBarHeight_) {
|
||
|
this.currentAppBarOffsetTop_ = -this.topAppBarHeight_;
|
||
|
}
|
||
|
this.moveTopAppBar_();
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Top app bar resize handler that throttle/debounce functions that execute updates.
|
||
|
* @override
|
||
|
*/
|
||
|
MDCTopAppBarFoundation.prototype.handleWindowResize = function () {
|
||
|
var _this = this;
|
||
|
// Throttle resize events 10 p/s
|
||
|
if (!this.resizeThrottleId_) {
|
||
|
this.resizeThrottleId_ = setTimeout(function () {
|
||
|
_this.resizeThrottleId_ = INITIAL_VALUE;
|
||
|
_this.throttledResizeHandler_();
|
||
|
}, _constants__WEBPACK_IMPORTED_MODULE_1__["numbers"].DEBOUNCE_THROTTLE_RESIZE_TIME_MS);
|
||
|
}
|
||
|
this.isCurrentlyBeingResized_ = true;
|
||
|
if (this.resizeDebounceId_) {
|
||
|
clearTimeout(this.resizeDebounceId_);
|
||
|
}
|
||
|
this.resizeDebounceId_ = setTimeout(function () {
|
||
|
_this.handleTargetScroll();
|
||
|
_this.isCurrentlyBeingResized_ = false;
|
||
|
_this.resizeDebounceId_ = INITIAL_VALUE;
|
||
|
}, _constants__WEBPACK_IMPORTED_MODULE_1__["numbers"].DEBOUNCE_THROTTLE_RESIZE_TIME_MS);
|
||
|
};
|
||
|
/**
|
||
|
* Function to determine if the DOM needs to update.
|
||
|
*/
|
||
|
MDCTopAppBarFoundation.prototype.checkForUpdate_ = function () {
|
||
|
var offscreenBoundaryTop = -this.topAppBarHeight_;
|
||
|
var hasAnyPixelsOffscreen = this.currentAppBarOffsetTop_ < 0;
|
||
|
var hasAnyPixelsOnscreen = this.currentAppBarOffsetTop_ > offscreenBoundaryTop;
|
||
|
var partiallyShowing = hasAnyPixelsOffscreen && hasAnyPixelsOnscreen;
|
||
|
// If it's partially showing, it can't be docked.
|
||
|
if (partiallyShowing) {
|
||
|
this.wasDocked_ = false;
|
||
|
}
|
||
|
else {
|
||
|
// Not previously docked and not partially showing, it's now docked.
|
||
|
if (!this.wasDocked_) {
|
||
|
this.wasDocked_ = true;
|
||
|
return true;
|
||
|
}
|
||
|
else if (this.isDockedShowing_ !== hasAnyPixelsOnscreen) {
|
||
|
this.isDockedShowing_ = hasAnyPixelsOnscreen;
|
||
|
return true;
|
||
|
}
|
||
|
}
|
||
|
return partiallyShowing;
|
||
|
};
|
||
|
/**
|
||
|
* Function to move the top app bar if needed.
|
||
|
*/
|
||
|
MDCTopAppBarFoundation.prototype.moveTopAppBar_ = function () {
|
||
|
if (this.checkForUpdate_()) {
|
||
|
// Once the top app bar is fully hidden we use the max potential top app bar height as our offset
|
||
|
// so the top app bar doesn't show if the window resizes and the new height > the old height.
|
||
|
var offset = this.currentAppBarOffsetTop_;
|
||
|
if (Math.abs(offset) >= this.topAppBarHeight_) {
|
||
|
offset = -_constants__WEBPACK_IMPORTED_MODULE_1__["numbers"].MAX_TOP_APP_BAR_HEIGHT;
|
||
|
}
|
||
|
this.adapter_.setStyle('top', offset + 'px');
|
||
|
}
|
||
|
};
|
||
|
/**
|
||
|
* Throttled function that updates the top app bar scrolled values if the
|
||
|
* top app bar height changes.
|
||
|
*/
|
||
|
MDCTopAppBarFoundation.prototype.throttledResizeHandler_ = function () {
|
||
|
var currentHeight = this.adapter_.getTopAppBarHeight();
|
||
|
if (this.topAppBarHeight_ !== currentHeight) {
|
||
|
this.wasDocked_ = false;
|
||
|
// Since the top app bar has a different height depending on the screen width, this
|
||
|
// will ensure that the top app bar remains in the correct location if
|
||
|
// completely hidden and a resize makes the top app bar a different height.
|
||
|
this.currentAppBarOffsetTop_ -= this.topAppBarHeight_ - currentHeight;
|
||
|
this.topAppBarHeight_ = currentHeight;
|
||
|
}
|
||
|
this.handleTargetScroll();
|
||
|
};
|
||
|
return MDCTopAppBarFoundation;
|
||
|
}(_foundation__WEBPACK_IMPORTED_MODULE_2__["MDCTopAppBarBaseFoundation"]));
|
||
|
|
||
|
// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (MDCTopAppBarFoundation);
|
||
|
//# sourceMappingURL=foundation.js.map
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/parallax-js/dist/parallax.js":
|
||
|
/*!***************************************************!*\
|
||
|
!*** ./node_modules/parallax-js/dist/parallax.js ***!
|
||
|
\***************************************************/
|
||
|
/*! no static exports found */
|
||
|
/***/ (function(module, exports, __webpack_require__) {
|
||
|
|
||
|
/* WEBPACK VAR INJECTION */(function(global) {var require;var require;(function(f){if(true){module.exports=f()}else { var g; }})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
|
||
|
/*
|
||
|
object-assign
|
||
|
(c) Sindre Sorhus
|
||
|
@license MIT
|
||
|
*/
|
||
|
|
||
|
'use strict';
|
||
|
/* eslint-disable no-unused-vars */
|
||
|
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
||
|
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
||
|
var propIsEnumerable = Object.prototype.propertyIsEnumerable;
|
||
|
|
||
|
function toObject(val) {
|
||
|
if (val === null || val === undefined) {
|
||
|
throw new TypeError('Object.assign cannot be called with null or undefined');
|
||
|
}
|
||
|
|
||
|
return Object(val);
|
||
|
}
|
||
|
|
||
|
function shouldUseNative() {
|
||
|
try {
|
||
|
if (!Object.assign) {
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
// Detect buggy property enumeration order in older V8 versions.
|
||
|
|
||
|
// https://bugs.chromium.org/p/v8/issues/detail?id=4118
|
||
|
var test1 = new String('abc'); // eslint-disable-line no-new-wrappers
|
||
|
test1[5] = 'de';
|
||
|
if (Object.getOwnPropertyNames(test1)[0] === '5') {
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
||
|
var test2 = {};
|
||
|
for (var i = 0; i < 10; i++) {
|
||
|
test2['_' + String.fromCharCode(i)] = i;
|
||
|
}
|
||
|
var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
|
||
|
return test2[n];
|
||
|
});
|
||
|
if (order2.join('') !== '0123456789') {
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
||
|
var test3 = {};
|
||
|
'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
|
||
|
test3[letter] = letter;
|
||
|
});
|
||
|
if (Object.keys(Object.assign({}, test3)).join('') !==
|
||
|
'abcdefghijklmnopqrst') {
|
||
|
return false;
|
||
|
}
|
||
|
|
||
|
return true;
|
||
|
} catch (err) {
|
||
|
// We don't expect any of the above to throw, but better to be safe.
|
||
|
return false;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
module.exports = shouldUseNative() ? Object.assign : function (target, source) {
|
||
|
var from;
|
||
|
var to = toObject(target);
|
||
|
var symbols;
|
||
|
|
||
|
for (var s = 1; s < arguments.length; s++) {
|
||
|
from = Object(arguments[s]);
|
||
|
|
||
|
for (var key in from) {
|
||
|
if (hasOwnProperty.call(from, key)) {
|
||
|
to[key] = from[key];
|
||
|
}
|
||
|
}
|
||
|
|
||
|
if (getOwnPropertySymbols) {
|
||
|
symbols = getOwnPropertySymbols(from);
|
||
|
for (var i = 0; i < symbols.length; i++) {
|
||
|
if (propIsEnumerable.call(from, symbols[i])) {
|
||
|
to[symbols[i]] = from[symbols[i]];
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
return to;
|
||
|
};
|
||
|
|
||
|
},{}],2:[function(require,module,exports){
|
||
|
(function (process){
|
||
|
// Generated by CoffeeScript 1.12.2
|
||
|
(function() {
|
||
|
var getNanoSeconds, hrtime, loadTime, moduleLoadTime, nodeLoadTime, upTime;
|
||
|
|
||
|
if ((typeof performance !== "undefined" && performance !== null) && performance.now) {
|
||
|
module.exports = function() {
|
||
|
return performance.now();
|
||
|
};
|
||
|
} else if ((typeof process !== "undefined" && process !== null) && process.hrtime) {
|
||
|
module.exports = function() {
|
||
|
return (getNanoSeconds() - nodeLoadTime) / 1e6;
|
||
|
};
|
||
|
hrtime = process.hrtime;
|
||
|
getNanoSeconds = function() {
|
||
|
var hr;
|
||
|
hr = hrtime();
|
||
|
return hr[0] * 1e9 + hr[1];
|
||
|
};
|
||
|
moduleLoadTime = getNanoSeconds();
|
||
|
upTime = process.uptime() * 1e9;
|
||
|
nodeLoadTime = moduleLoadTime - upTime;
|
||
|
} else if (Date.now) {
|
||
|
module.exports = function() {
|
||
|
return Date.now() - loadTime;
|
||
|
};
|
||
|
loadTime = Date.now();
|
||
|
} else {
|
||
|
module.exports = function() {
|
||
|
return new Date().getTime() - loadTime;
|
||
|
};
|
||
|
loadTime = new Date().getTime();
|
||
|
}
|
||
|
|
||
|
}).call(this);
|
||
|
|
||
|
|
||
|
|
||
|
}).call(this,require('_process'))
|
||
|
|
||
|
},{"_process":3}],3:[function(require,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; };
|
||
|
|
||
|
},{}],4:[function(require,module,exports){
|
||
|
(function (global){
|
||
|
var now = require('performance-now')
|
||
|
, root = typeof window === 'undefined' ? global : window
|
||
|
, vendors = ['moz', 'webkit']
|
||
|
, suffix = 'AnimationFrame'
|
||
|
, raf = root['request' + suffix]
|
||
|
, caf = root['cancel' + suffix] || root['cancelRequest' + suffix]
|
||
|
|
||
|
for(var i = 0; !raf && i < vendors.length; i++) {
|
||
|
raf = root[vendors[i] + 'Request' + suffix]
|
||
|
caf = root[vendors[i] + 'Cancel' + suffix]
|
||
|
|| root[vendors[i] + 'CancelRequest' + suffix]
|
||
|
}
|
||
|
|
||
|
// Some versions of FF have rAF but not cAF
|
||
|
if(!raf || !caf) {
|
||
|
var last = 0
|
||
|
, id = 0
|
||
|
, queue = []
|
||
|
, frameDuration = 1000 / 60
|
||
|
|
||
|
raf = function(callback) {
|
||
|
if(queue.length === 0) {
|
||
|
var _now = now()
|
||
|
, next = Math.max(0, frameDuration - (_now - last))
|
||
|
last = next + _now
|
||
|
setTimeout(function() {
|
||
|
var cp = queue.slice(0)
|
||
|
// Clear queue here to prevent
|
||
|
// callbacks from appending listeners
|
||
|
// to the current frame's queue
|
||
|
queue.length = 0
|
||
|
for(var i = 0; i < cp.length; i++) {
|
||
|
if(!cp[i].cancelled) {
|
||
|
try{
|
||
|
cp[i].callback(last)
|
||
|
} catch(e) {
|
||
|
setTimeout(function() { throw e }, 0)
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}, Math.round(next))
|
||
|
}
|
||
|
queue.push({
|
||
|
handle: ++id,
|
||
|
callback: callback,
|
||
|
cancelled: false
|
||
|
})
|
||
|
return id
|
||
|
}
|
||
|
|
||
|
caf = function(handle) {
|
||
|
for(var i = 0; i < queue.length; i++) {
|
||
|
if(queue[i].handle === handle) {
|
||
|
queue[i].cancelled = true
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
|
||
|
module.exports = function(fn) {
|
||
|
// Wrap in a new function to prevent
|
||
|
// `cancel` potentially being assigned
|
||
|
// to the native rAF function
|
||
|
return raf.call(root, fn)
|
||
|
}
|
||
|
module.exports.cancel = function() {
|
||
|
caf.apply(root, arguments)
|
||
|
}
|
||
|
module.exports.polyfill = function() {
|
||
|
root.requestAnimationFrame = raf
|
||
|
root.cancelAnimationFrame = caf
|
||
|
}
|
||
|
|
||
|
}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
|
||
|
|
||
|
},{"performance-now":2}],5:[function(require,module,exports){
|
||
|
'use strict';
|
||
|
|
||
|
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; }; }();
|
||
|
|
||
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
||
|
|
||
|
/**
|
||
|
* Parallax.js
|
||
|
* @author Matthew Wagerfield - @wagerfield, René Roth - mail@reneroth.org
|
||
|
* @description Creates a parallax effect between an array of layers,
|
||
|
* driving the motion from the gyroscope output of a smartdevice.
|
||
|
* If no gyroscope is available, the cursor position is used.
|
||
|
*/
|
||
|
|
||
|
var rqAnFr = require('raf');
|
||
|
var objectAssign = require('object-assign');
|
||
|
|
||
|
var helpers = {
|
||
|
propertyCache: {},
|
||
|
vendors: [null, ['-webkit-', 'webkit'], ['-moz-', 'Moz'], ['-o-', 'O'], ['-ms-', 'ms']],
|
||
|
|
||
|
clamp: function clamp(value, min, max) {
|
||
|
return min < max ? value < min ? min : value > max ? max : value : value < max ? max : value > min ? min : value;
|
||
|
},
|
||
|
data: function data(element, name) {
|
||
|
return helpers.deserialize(element.getAttribute('data-' + name));
|
||
|
},
|
||
|
deserialize: function deserialize(value) {
|
||
|
if (value === 'true') {
|
||
|
return true;
|
||
|
} else if (value === 'false') {
|
||
|
return false;
|
||
|
} else if (value === 'null') {
|
||
|
return null;
|
||
|
} else if (!isNaN(parseFloat(value)) && isFinite(value)) {
|
||
|
return parseFloat(value);
|
||
|
} else {
|
||
|
return value;
|
||
|
}
|
||
|
},
|
||
|
camelCase: function camelCase(value) {
|
||
|
return value.replace(/-+(.)?/g, function (match, character) {
|
||
|
return character ? character.toUpperCase() : '';
|
||
|
});
|
||
|
},
|
||
|
accelerate: function accelerate(element) {
|
||
|
helpers.css(element, 'transform', 'translate3d(0,0,0) rotate(0.0001deg)');
|
||
|
helpers.css(element, 'transform-style', 'preserve-3d');
|
||
|
helpers.css(element, 'backface-visibility', 'hidden');
|
||
|
},
|
||
|
transformSupport: function transformSupport(value) {
|
||
|
var element = document.createElement('div'),
|
||
|
propertySupport = false,
|
||
|
propertyValue = null,
|
||
|
featureSupport = false,
|
||
|
cssProperty = null,
|
||
|
jsProperty = null;
|
||
|
for (var i = 0, l = helpers.vendors.length; i < l; i++) {
|
||
|
if (helpers.vendors[i] !== null) {
|
||
|
cssProperty = helpers.vendors[i][0] + 'transform';
|
||
|
jsProperty = helpers.vendors[i][1] + 'Transform';
|
||
|
} else {
|
||
|
cssProperty = 'transform';
|
||
|
jsProperty = 'transform';
|
||
|
}
|
||
|
if (element.style[jsProperty] !== undefined) {
|
||
|
propertySupport = true;
|
||
|
break;
|
||
|
}
|
||
|
}
|
||
|
switch (value) {
|
||
|
case '2D':
|
||
|
featureSupport = propertySupport;
|
||
|
break;
|
||
|
case '3D':
|
||
|
if (propertySupport) {
|
||
|
var body = document.body || document.createElement('body'),
|
||
|
documentElement = document.documentElement,
|
||
|
documentOverflow = documentElement.style.overflow,
|
||
|
isCreatedBody = false;
|
||
|
|
||
|
if (!document.body) {
|
||
|
isCreatedBody = true;
|
||
|
documentElement.style.overflow = 'hidden';
|
||
|
documentElement.appendChild(body);
|
||
|
body.style.overflow = 'hidden';
|
||
|
body.style.background = '';
|
||
|
}
|
||
|
|
||
|
body.appendChild(element);
|
||
|
element.style[jsProperty] = 'translate3d(1px,1px,1px)';
|
||
|
propertyValue = window.getComputedStyle(element).getPropertyValue(cssProperty);
|
||
|
featureSupport = propertyValue !== undefined && propertyValue.length > 0 && propertyValue !== 'none';
|
||
|
documentElement.style.overflow = documentOverflow;
|
||
|
body.removeChild(element);
|
||
|
|
||
|
if (isCreatedBody) {
|
||
|
body.removeAttribute('style');
|
||
|
body.parentNode.removeChild(body);
|
||
|
}
|
||
|
}
|
||
|
break;
|
||
|
}
|
||
|
return featureSupport;
|
||
|
},
|
||
|
css: function css(element, property, value) {
|
||
|
var jsProperty = helpers.propertyCache[property];
|
||
|
if (!jsProperty) {
|
||
|
for (var i = 0, l = helpers.vendors.length; i < l; i++) {
|
||
|
if (helpers.vendors[i] !== null) {
|
||
|
jsProperty = helpers.camelCase(helpers.vendors[i][1] + '-' + property);
|
||
|
} else {
|
||
|
jsProperty = property;
|
||
|
}
|
||
|
if (element.style[jsProperty] !== undefined) {
|
||
|
helpers.propertyCache[property] = jsProperty;
|
||
|
break;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
element.style[jsProperty] = value;
|
||
|
}
|
||
|
};
|
||
|
|
||
|
var MAGIC_NUMBER = 30,
|
||
|
DEFAULTS = {
|
||
|
relativeInput: false,
|
||
|
clipRelativeInput: false,
|
||
|
inputElement: null,
|
||
|
hoverOnly: false,
|
||
|
calibrationThreshold: 100,
|
||
|
calibrationDelay: 500,
|
||
|
supportDelay: 500,
|
||
|
calibrateX: false,
|
||
|
calibrateY: true,
|
||
|
invertX: true,
|
||
|
invertY: true,
|
||
|
limitX: false,
|
||
|
limitY: false,
|
||
|
scalarX: 10.0,
|
||
|
scalarY: 10.0,
|
||
|
frictionX: 0.1,
|
||
|
frictionY: 0.1,
|
||
|
originX: 0.5,
|
||
|
originY: 0.5,
|
||
|
pointerEvents: false,
|
||
|
precision: 1,
|
||
|
onReady: null,
|
||
|
selector: null
|
||
|
};
|
||
|
|
||
|
var Parallax = function () {
|
||
|
function Parallax(element, options) {
|
||
|
_classCallCheck(this, Parallax);
|
||
|
|
||
|
this.element = element;
|
||
|
|
||
|
var data = {
|
||
|
calibrateX: helpers.data(this.element, 'calibrate-x'),
|
||
|
calibrateY: helpers.data(this.element, 'calibrate-y'),
|
||
|
invertX: helpers.data(this.element, 'invert-x'),
|
||
|
invertY: helpers.data(this.element, 'invert-y'),
|
||
|
limitX: helpers.data(this.element, 'limit-x'),
|
||
|
limitY: helpers.data(this.element, 'limit-y'),
|
||
|
scalarX: helpers.data(this.element, 'scalar-x'),
|
||
|
scalarY: helpers.data(this.element, 'scalar-y'),
|
||
|
frictionX: helpers.data(this.element, 'friction-x'),
|
||
|
frictionY: helpers.data(this.element, 'friction-y'),
|
||
|
originX: helpers.data(this.element, 'origin-x'),
|
||
|
originY: helpers.data(this.element, 'origin-y'),
|
||
|
pointerEvents: helpers.data(this.element, 'pointer-events'),
|
||
|
precision: helpers.data(this.element, 'precision'),
|
||
|
relativeInput: helpers.data(this.element, 'relative-input'),
|
||
|
clipRelativeInput: helpers.data(this.element, 'clip-relative-input'),
|
||
|
hoverOnly: helpers.data(this.element, 'hover-only'),
|
||
|
inputElement: document.querySelector(helpers.data(this.element, 'input-element')),
|
||
|
selector: helpers.data(this.element, 'selector')
|
||
|
};
|
||
|
|
||
|
for (var key in data) {
|
||
|
if (data[key] === null) {
|
||
|
delete data[key];
|
||
|
}
|
||
|
}
|
||
|
|
||
|
objectAssign(this, DEFAULTS, data, options);
|
||
|
|
||
|
if (!this.inputElement) {
|
||
|
this.inputElement = this.element;
|
||
|
}
|
||
|
|
||
|
this.calibrationTimer = null;
|
||
|
this.calibrationFlag = true;
|
||
|
this.enabled = false;
|
||
|
this.depthsX = [];
|
||
|
this.depthsY = [];
|
||
|
this.raf = null;
|
||
|
|
||
|
this.bounds = null;
|
||
|
this.elementPositionX = 0;
|
||
|
this.elementPositionY = 0;
|
||
|
this.elementWidth = 0;
|
||
|
this.elementHeight = 0;
|
||
|
|
||
|
this.elementCenterX = 0;
|
||
|
this.elementCenterY = 0;
|
||
|
|
||
|
this.elementRangeX = 0;
|
||
|
this.elementRangeY = 0;
|
||
|
|
||
|
this.calibrationX = 0;
|
||
|
this.calibrationY = 0;
|
||
|
|
||
|
this.inputX = 0;
|
||
|
this.inputY = 0;
|
||
|
|
||
|
this.motionX = 0;
|
||
|
this.motionY = 0;
|
||
|
|
||
|
this.velocityX = 0;
|
||
|
this.velocityY = 0;
|
||
|
|
||
|
this.onMouseMove = this.onMouseMove.bind(this);
|
||
|
this.onDeviceOrientation = this.onDeviceOrientation.bind(this);
|
||
|
this.onDeviceMotion = this.onDeviceMotion.bind(this);
|
||
|
this.onOrientationTimer = this.onOrientationTimer.bind(this);
|
||
|
this.onMotionTimer = this.onMotionTimer.bind(this);
|
||
|
this.onCalibrationTimer = this.onCalibrationTimer.bind(this);
|
||
|
this.onAnimationFrame = this.onAnimationFrame.bind(this);
|
||
|
this.onWindowResize = this.onWindowResize.bind(this);
|
||
|
|
||
|
this.windowWidth = null;
|
||
|
this.windowHeight = null;
|
||
|
this.windowCenterX = null;
|
||
|
this.windowCenterY = null;
|
||
|
this.windowRadiusX = null;
|
||
|
this.windowRadiusY = null;
|
||
|
this.portrait = false;
|
||
|
this.desktop = !navigator.userAgent.match(/(iPhone|iPod|iPad|Android|BlackBerry|BB10|mobi|tablet|opera mini|nexus 7)/i);
|
||
|
this.motionSupport = !!window.DeviceMotionEvent && !this.desktop;
|
||
|
this.orientationSupport = !!window.DeviceOrientationEvent && !this.desktop;
|
||
|
this.orientationStatus = 0;
|
||
|
this.motionStatus = 0;
|
||
|
|
||
|
this.initialise();
|
||
|
}
|
||
|
|
||
|
_createClass(Parallax, [{
|
||
|
key: 'initialise',
|
||
|
value: function initialise() {
|
||
|
if (this.transform2DSupport === undefined) {
|
||
|
this.transform2DSupport = helpers.transformSupport('2D');
|
||
|
this.transform3DSupport = helpers.transformSupport('3D');
|
||
|
}
|
||
|
|
||
|
// Configure Context Styles
|
||
|
if (this.transform3DSupport) {
|
||
|
helpers.accelerate(this.element);
|
||
|
}
|
||
|
|
||
|
var style = window.getComputedStyle(this.element);
|
||
|
if (style.getPropertyValue('position') === 'static') {
|
||
|
this.element.style.position = 'relative';
|
||
|
}
|
||
|
|
||
|
// Pointer events
|
||
|
if (!this.pointerEvents) {
|
||
|
this.element.style.pointerEvents = 'none';
|
||
|
}
|
||
|
|
||
|
// Setup
|
||
|
this.updateLayers();
|
||
|
this.updateDimensions();
|
||
|
this.enable();
|
||
|
this.queueCalibration(this.calibrationDelay);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'doReadyCallback',
|
||
|
value: function doReadyCallback() {
|
||
|
if (this.onReady) {
|
||
|
this.onReady();
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'updateLayers',
|
||
|
value: function updateLayers() {
|
||
|
if (this.selector) {
|
||
|
this.layers = this.element.querySelectorAll(this.selector);
|
||
|
} else {
|
||
|
this.layers = this.element.children;
|
||
|
}
|
||
|
|
||
|
if (!this.layers.length) {
|
||
|
console.warn('ParallaxJS: Your scene does not have any layers.');
|
||
|
}
|
||
|
|
||
|
this.depthsX = [];
|
||
|
this.depthsY = [];
|
||
|
|
||
|
for (var index = 0; index < this.layers.length; index++) {
|
||
|
var layer = this.layers[index];
|
||
|
|
||
|
if (this.transform3DSupport) {
|
||
|
helpers.accelerate(layer);
|
||
|
}
|
||
|
|
||
|
layer.style.position = index ? 'absolute' : 'relative';
|
||
|
layer.style.display = 'block';
|
||
|
layer.style.left = 0;
|
||
|
layer.style.top = 0;
|
||
|
|
||
|
var depth = helpers.data(layer, 'depth') || 0;
|
||
|
this.depthsX.push(helpers.data(layer, 'depth-x') || depth);
|
||
|
this.depthsY.push(helpers.data(layer, 'depth-y') || depth);
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'updateDimensions',
|
||
|
value: function updateDimensions() {
|
||
|
this.windowWidth = window.innerWidth;
|
||
|
this.windowHeight = window.innerHeight;
|
||
|
this.windowCenterX = this.windowWidth * this.originX;
|
||
|
this.windowCenterY = this.windowHeight * this.originY;
|
||
|
this.windowRadiusX = Math.max(this.windowCenterX, this.windowWidth - this.windowCenterX);
|
||
|
this.windowRadiusY = Math.max(this.windowCenterY, this.windowHeight - this.windowCenterY);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'updateBounds',
|
||
|
value: function updateBounds() {
|
||
|
this.bounds = this.inputElement.getBoundingClientRect();
|
||
|
this.elementPositionX = this.bounds.left;
|
||
|
this.elementPositionY = this.bounds.top;
|
||
|
this.elementWidth = this.bounds.width;
|
||
|
this.elementHeight = this.bounds.height;
|
||
|
this.elementCenterX = this.elementWidth * this.originX;
|
||
|
this.elementCenterY = this.elementHeight * this.originY;
|
||
|
this.elementRangeX = Math.max(this.elementCenterX, this.elementWidth - this.elementCenterX);
|
||
|
this.elementRangeY = Math.max(this.elementCenterY, this.elementHeight - this.elementCenterY);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'queueCalibration',
|
||
|
value: function queueCalibration(delay) {
|
||
|
clearTimeout(this.calibrationTimer);
|
||
|
this.calibrationTimer = setTimeout(this.onCalibrationTimer, delay);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'enable',
|
||
|
value: function enable() {
|
||
|
if (this.enabled) {
|
||
|
return;
|
||
|
}
|
||
|
this.enabled = true;
|
||
|
|
||
|
if (this.orientationSupport) {
|
||
|
this.portrait = false;
|
||
|
window.addEventListener('deviceorientation', this.onDeviceOrientation);
|
||
|
this.detectionTimer = setTimeout(this.onOrientationTimer, this.supportDelay);
|
||
|
} else if (this.motionSupport) {
|
||
|
this.portrait = false;
|
||
|
window.addEventListener('devicemotion', this.onDeviceMotion);
|
||
|
this.detectionTimer = setTimeout(this.onMotionTimer, this.supportDelay);
|
||
|
} else {
|
||
|
this.calibrationX = 0;
|
||
|
this.calibrationY = 0;
|
||
|
this.portrait = false;
|
||
|
window.addEventListener('mousemove', this.onMouseMove);
|
||
|
this.doReadyCallback();
|
||
|
}
|
||
|
|
||
|
window.addEventListener('resize', this.onWindowResize);
|
||
|
this.raf = rqAnFr(this.onAnimationFrame);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'disable',
|
||
|
value: function disable() {
|
||
|
if (!this.enabled) {
|
||
|
return;
|
||
|
}
|
||
|
this.enabled = false;
|
||
|
|
||
|
if (this.orientationSupport) {
|
||
|
window.removeEventListener('deviceorientation', this.onDeviceOrientation);
|
||
|
} else if (this.motionSupport) {
|
||
|
window.removeEventListener('devicemotion', this.onDeviceMotion);
|
||
|
} else {
|
||
|
window.removeEventListener('mousemove', this.onMouseMove);
|
||
|
}
|
||
|
|
||
|
window.removeEventListener('resize', this.onWindowResize);
|
||
|
rqAnFr.cancel(this.raf);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'calibrate',
|
||
|
value: function calibrate(x, y) {
|
||
|
this.calibrateX = x === undefined ? this.calibrateX : x;
|
||
|
this.calibrateY = y === undefined ? this.calibrateY : y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'invert',
|
||
|
value: function invert(x, y) {
|
||
|
this.invertX = x === undefined ? this.invertX : x;
|
||
|
this.invertY = y === undefined ? this.invertY : y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'friction',
|
||
|
value: function friction(x, y) {
|
||
|
this.frictionX = x === undefined ? this.frictionX : x;
|
||
|
this.frictionY = y === undefined ? this.frictionY : y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'scalar',
|
||
|
value: function scalar(x, y) {
|
||
|
this.scalarX = x === undefined ? this.scalarX : x;
|
||
|
this.scalarY = y === undefined ? this.scalarY : y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'limit',
|
||
|
value: function limit(x, y) {
|
||
|
this.limitX = x === undefined ? this.limitX : x;
|
||
|
this.limitY = y === undefined ? this.limitY : y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'origin',
|
||
|
value: function origin(x, y) {
|
||
|
this.originX = x === undefined ? this.originX : x;
|
||
|
this.originY = y === undefined ? this.originY : y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'setInputElement',
|
||
|
value: function setInputElement(element) {
|
||
|
this.inputElement = element;
|
||
|
this.updateDimensions();
|
||
|
}
|
||
|
}, {
|
||
|
key: 'setPosition',
|
||
|
value: function setPosition(element, x, y) {
|
||
|
x = x.toFixed(this.precision) + 'px';
|
||
|
y = y.toFixed(this.precision) + 'px';
|
||
|
if (this.transform3DSupport) {
|
||
|
helpers.css(element, 'transform', 'translate3d(' + x + ',' + y + ',0)');
|
||
|
} else if (this.transform2DSupport) {
|
||
|
helpers.css(element, 'transform', 'translate(' + x + ',' + y + ')');
|
||
|
} else {
|
||
|
element.style.left = x;
|
||
|
element.style.top = y;
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onOrientationTimer',
|
||
|
value: function onOrientationTimer() {
|
||
|
if (this.orientationSupport && this.orientationStatus === 0) {
|
||
|
this.disable();
|
||
|
this.orientationSupport = false;
|
||
|
this.enable();
|
||
|
} else {
|
||
|
this.doReadyCallback();
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onMotionTimer',
|
||
|
value: function onMotionTimer() {
|
||
|
if (this.motionSupport && this.motionStatus === 0) {
|
||
|
this.disable();
|
||
|
this.motionSupport = false;
|
||
|
this.enable();
|
||
|
} else {
|
||
|
this.doReadyCallback();
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onCalibrationTimer',
|
||
|
value: function onCalibrationTimer() {
|
||
|
this.calibrationFlag = true;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onWindowResize',
|
||
|
value: function onWindowResize() {
|
||
|
this.updateDimensions();
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onAnimationFrame',
|
||
|
value: function onAnimationFrame() {
|
||
|
this.updateBounds();
|
||
|
var calibratedInputX = this.inputX - this.calibrationX,
|
||
|
calibratedInputY = this.inputY - this.calibrationY;
|
||
|
if (Math.abs(calibratedInputX) > this.calibrationThreshold || Math.abs(calibratedInputY) > this.calibrationThreshold) {
|
||
|
this.queueCalibration(0);
|
||
|
}
|
||
|
if (this.portrait) {
|
||
|
this.motionX = this.calibrateX ? calibratedInputY : this.inputY;
|
||
|
this.motionY = this.calibrateY ? calibratedInputX : this.inputX;
|
||
|
} else {
|
||
|
this.motionX = this.calibrateX ? calibratedInputX : this.inputX;
|
||
|
this.motionY = this.calibrateY ? calibratedInputY : this.inputY;
|
||
|
}
|
||
|
this.motionX *= this.elementWidth * (this.scalarX / 100);
|
||
|
this.motionY *= this.elementHeight * (this.scalarY / 100);
|
||
|
if (!isNaN(parseFloat(this.limitX))) {
|
||
|
this.motionX = helpers.clamp(this.motionX, -this.limitX, this.limitX);
|
||
|
}
|
||
|
if (!isNaN(parseFloat(this.limitY))) {
|
||
|
this.motionY = helpers.clamp(this.motionY, -this.limitY, this.limitY);
|
||
|
}
|
||
|
this.velocityX += (this.motionX - this.velocityX) * this.frictionX;
|
||
|
this.velocityY += (this.motionY - this.velocityY) * this.frictionY;
|
||
|
for (var index = 0; index < this.layers.length; index++) {
|
||
|
var layer = this.layers[index],
|
||
|
depthX = this.depthsX[index],
|
||
|
depthY = this.depthsY[index],
|
||
|
xOffset = this.velocityX * (depthX * (this.invertX ? -1 : 1)),
|
||
|
yOffset = this.velocityY * (depthY * (this.invertY ? -1 : 1));
|
||
|
this.setPosition(layer, xOffset, yOffset);
|
||
|
}
|
||
|
this.raf = rqAnFr(this.onAnimationFrame);
|
||
|
}
|
||
|
}, {
|
||
|
key: 'rotate',
|
||
|
value: function rotate(beta, gamma) {
|
||
|
// Extract Rotation
|
||
|
var x = (beta || 0) / MAGIC_NUMBER,
|
||
|
// -90 :: 90
|
||
|
y = (gamma || 0) / MAGIC_NUMBER; // -180 :: 180
|
||
|
|
||
|
// Detect Orientation Change
|
||
|
var portrait = this.windowHeight > this.windowWidth;
|
||
|
if (this.portrait !== portrait) {
|
||
|
this.portrait = portrait;
|
||
|
this.calibrationFlag = true;
|
||
|
}
|
||
|
|
||
|
if (this.calibrationFlag) {
|
||
|
this.calibrationFlag = false;
|
||
|
this.calibrationX = x;
|
||
|
this.calibrationY = y;
|
||
|
}
|
||
|
|
||
|
this.inputX = x;
|
||
|
this.inputY = y;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onDeviceOrientation',
|
||
|
value: function onDeviceOrientation(event) {
|
||
|
var beta = event.beta;
|
||
|
var gamma = event.gamma;
|
||
|
if (beta !== null && gamma !== null) {
|
||
|
this.orientationStatus = 1;
|
||
|
this.rotate(beta, gamma);
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onDeviceMotion',
|
||
|
value: function onDeviceMotion(event) {
|
||
|
var beta = event.rotationRate.beta;
|
||
|
var gamma = event.rotationRate.gamma;
|
||
|
if (beta !== null && gamma !== null) {
|
||
|
this.motionStatus = 1;
|
||
|
this.rotate(beta, gamma);
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'onMouseMove',
|
||
|
value: function onMouseMove(event) {
|
||
|
var clientX = event.clientX,
|
||
|
clientY = event.clientY;
|
||
|
|
||
|
// reset input to center if hoverOnly is set and we're not hovering the element
|
||
|
if (this.hoverOnly && (clientX < this.elementPositionX || clientX > this.elementPositionX + this.elementWidth || clientY < this.elementPositionY || clientY > this.elementPositionY + this.elementHeight)) {
|
||
|
this.inputX = 0;
|
||
|
this.inputY = 0;
|
||
|
return;
|
||
|
}
|
||
|
|
||
|
if (this.relativeInput) {
|
||
|
// Clip mouse coordinates inside element bounds.
|
||
|
if (this.clipRelativeInput) {
|
||
|
clientX = Math.max(clientX, this.elementPositionX);
|
||
|
clientX = Math.min(clientX, this.elementPositionX + this.elementWidth);
|
||
|
clientY = Math.max(clientY, this.elementPositionY);
|
||
|
clientY = Math.min(clientY, this.elementPositionY + this.elementHeight);
|
||
|
}
|
||
|
// Calculate input relative to the element.
|
||
|
if (this.elementRangeX && this.elementRangeY) {
|
||
|
this.inputX = (clientX - this.elementPositionX - this.elementCenterX) / this.elementRangeX;
|
||
|
this.inputY = (clientY - this.elementPositionY - this.elementCenterY) / this.elementRangeY;
|
||
|
}
|
||
|
} else {
|
||
|
// Calculate input relative to the window.
|
||
|
if (this.windowRadiusX && this.windowRadiusY) {
|
||
|
this.inputX = (clientX - this.windowCenterX) / this.windowRadiusX;
|
||
|
this.inputY = (clientY - this.windowCenterY) / this.windowRadiusY;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}, {
|
||
|
key: 'destroy',
|
||
|
value: function destroy() {
|
||
|
this.disable();
|
||
|
|
||
|
clearTimeout(this.calibrationTimer);
|
||
|
clearTimeout(this.detectionTimer);
|
||
|
|
||
|
this.element.removeAttribute('style');
|
||
|
for (var index = 0; index < this.layers.length; index++) {
|
||
|
this.layers[index].removeAttribute('style');
|
||
|
}
|
||
|
|
||
|
delete this.element;
|
||
|
delete this.layers;
|
||
|
}
|
||
|
}, {
|
||
|
key: 'version',
|
||
|
value: function version() {
|
||
|
return '3.1.0';
|
||
|
}
|
||
|
}]);
|
||
|
|
||
|
return Parallax;
|
||
|
}();
|
||
|
|
||
|
module.exports = Parallax;
|
||
|
|
||
|
},{"object-assign":1,"raf":4}]},{},[5])(5)
|
||
|
});
|
||
|
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIm5vZGVfbW9kdWxlcy9icm93c2VyLXBhY2svX3ByZWx1ZGUuanMiLCJub2RlX21vZHVsZXMvb2JqZWN0LWFzc2lnbi9pbmRleC5qcyIsIm5vZGVfbW9kdWxlcy9wZXJmb3JtYW5jZS1ub3cvbGliL3BlcmZvcm1hbmNlLW5vdy5qcyIsIm5vZGVfbW9kdWxlcy9wcm9jZXNzL2Jyb3dzZXIuanMiLCJub2RlX21vZHVsZXMvcmFmL2luZGV4LmpzIiwic3JjL3BhcmFsbGF4LmpzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBO0FDQUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7OztBQzFGQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7OztBQ3BDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOzs7QUN4TEE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7Ozs7Ozs7Ozs7QUN4RUE7Ozs7Ozs7O0FBUUEsSUFBTSxTQUFTLFFBQVEsS0FBUixDQUFmO0FBQ0EsSUFBTSxlQUFlLFFBQVEsZUFBUixDQUFyQjs7QUFFQSxJQUFNLFVBQVU7QUFDZCxpQkFBZSxFQUREO0FBRWQsV0FBUyxDQUFDLElBQUQsRUFBTyxDQUFDLFVBQUQsRUFBWSxRQUFaLENBQVAsRUFBOEIsQ0FBQyxPQUFELEVBQVMsS0FBVCxDQUE5QixFQUErQyxDQUFDLEtBQUQsRUFBTyxHQUFQLENBQS9DLEVBQTRELENBQUMsTUFBRCxFQUFRLElBQVIsQ0FBNUQsQ0FGSzs7QUFJZCxPQUpjLGlCQUlSLEtBSlEsRUFJRCxHQUpDLEVBSUksR0FKSixFQUlTO0FBQ3JCLFdBQU8sTUFBTSxHQUFOLEdBQ0YsUUFBUSxHQUFSLEdBQWMsR0FBZCxHQUFvQixRQUFRLEdBQVIsR0FBYyxHQUFkLEdBQW9CLEtBRHRDLEdBRUYsUUFBUSxHQUFSLEdBQWMsR0FBZCxHQUFvQixRQUFRLEdBQVIsR0FBYyxHQUFkLEdBQW9CLEtBRjdDO0FBR0QsR0FSYTtBQVVkLE1BVmMsZ0JBVVQsT0FWUyxFQVVBLElBVkEsRUFVTTtBQUNsQixXQUFPLFFBQVEsV0FBUixDQUFvQixRQUFRLFlBQVIsQ0FBcUIsVUFBUSxJQUE3QixDQUFwQixDQUFQO0FBQ0QsR0FaYTtBQWNkLGFBZGMsdUJBY0YsS0FkRSxFQWNLO0FBQ2pCLFFBQUksVUFBVSxNQUFkLEVBQXNCO0FBQ3BCLGFBQU8sSUFBUDtBQUNELEtBRkQsTUFFTyxJQUFJLFVBQVUsT0FBZCxFQUF1QjtBQUM1QixhQUFPLEtBQVA7QUFDRCxLQUZNLE1BRUEsSUFBSSxVQUFVLE1BQWQsRUFBc0I7QUFDM0IsYUFBTyxJQUFQO0FBQ0QsS0FGTSxNQUVBLElBQUksQ0FBQyxNQUFNLFdBQVcsS0FBWCxDQUFOLENBQUQsSUFBNkIsU0FBUyxLQUF
|
||
|
|
||
|
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! ./../../webpack/buildin/global.js */ "./node_modules/webpack/buildin/global.js")))
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/tslib/tslib.es6.js":
|
||
|
/*!*****************************************!*\
|
||
|
!*** ./node_modules/tslib/tslib.es6.js ***!
|
||
|
\*****************************************/
|
||
|
/*! exports provided: __extends, __assign, __rest, __decorate, __param, __metadata, __awaiter, __generator, __exportStar, __values, __read, __spread, __spreadArrays, __await, __asyncGenerator, __asyncDelegator, __asyncValues, __makeTemplateObject, __importStar, __importDefault */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__extends", function() { return __extends; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__assign", function() { return __assign; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__rest", function() { return __rest; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__decorate", function() { return __decorate; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__param", function() { return __param; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__metadata", function() { return __metadata; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__awaiter", function() { return __awaiter; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__generator", function() { return __generator; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__exportStar", function() { return __exportStar; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__values", function() { return __values; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__read", function() { return __read; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__spread", function() { return __spread; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__spreadArrays", function() { return __spreadArrays; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__await", function() { return __await; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__asyncGenerator", function() { return __asyncGenerator; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__asyncDelegator", function() { return __asyncDelegator; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__asyncValues", function() { return __asyncValues; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__makeTemplateObject", function() { return __makeTemplateObject; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__importStar", function() { return __importStar; });
|
||
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "__importDefault", function() { return __importDefault; });
|
||
|
/*! *****************************************************************************
|
||
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
||
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||
|
this file except in compliance with the License. You may obtain a copy of the
|
||
|
License at http://www.apache.org/licenses/LICENSE-2.0
|
||
|
|
||
|
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||
|
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||
|
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||
|
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||
|
|
||
|
See the Apache Version 2.0 License for specific language governing permissions
|
||
|
and limitations under the License.
|
||
|
***************************************************************************** */
|
||
|
/* global Reflect, Promise */
|
||
|
|
||
|
var extendStatics = function(d, b) {
|
||
|
extendStatics = Object.setPrototypeOf ||
|
||
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
||
|
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
||
|
return extendStatics(d, b);
|
||
|
};
|
||
|
|
||
|
function __extends(d, b) {
|
||
|
extendStatics(d, b);
|
||
|
function __() { this.constructor = d; }
|
||
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
||
|
}
|
||
|
|
||
|
var __assign = function() {
|
||
|
__assign = Object.assign || function __assign(t) {
|
||
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
||
|
s = arguments[i];
|
||
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
||
|
}
|
||
|
return t;
|
||
|
}
|
||
|
return __assign.apply(this, arguments);
|
||
|
}
|
||
|
|
||
|
function __rest(s, e) {
|
||
|
var t = {};
|
||
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
||
|
t[p] = s[p];
|
||
|
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
||
|
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
||
|
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
||
|
t[p[i]] = s[p[i]];
|
||
|
}
|
||
|
return t;
|
||
|
}
|
||
|
|
||
|
function __decorate(decorators, target, key, desc) {
|
||
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
||
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
||
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
||
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
||
|
}
|
||
|
|
||
|
function __param(paramIndex, decorator) {
|
||
|
return function (target, key) { decorator(target, key, paramIndex); }
|
||
|
}
|
||
|
|
||
|
function __metadata(metadataKey, metadataValue) {
|
||
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
|
||
|
}
|
||
|
|
||
|
function __awaiter(thisArg, _arguments, P, generator) {
|
||
|
return new (P || (P = Promise))(function (resolve, reject) {
|
||
|
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
||
|
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
||
|
function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }
|
||
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
||
|
});
|
||
|
}
|
||
|
|
||
|
function __generator(thisArg, body) {
|
||
|
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
||
|
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
||
|
function verb(n) { return function (v) { return step([n, v]); }; }
|
||
|
function step(op) {
|
||
|
if (f) throw new TypeError("Generator is already executing.");
|
||
|
while (_) try {
|
||
|
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
||
|
if (y = 0, t) op = [op[0] & 2, t.value];
|
||
|
switch (op[0]) {
|
||
|
case 0: case 1: t = op; break;
|
||
|
case 4: _.label++; return { value: op[1], done: false };
|
||
|
case 5: _.label++; y = op[1]; op = [0]; continue;
|
||
|
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
||
|
default:
|
||
|
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
||
|
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
||
|
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
||
|
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
||
|
if (t[2]) _.ops.pop();
|
||
|
_.trys.pop(); continue;
|
||
|
}
|
||
|
op = body.call(thisArg, _);
|
||
|
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
||
|
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
||
|
}
|
||
|
}
|
||
|
|
||
|
function __exportStar(m, exports) {
|
||
|
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
|
||
|
}
|
||
|
|
||
|
function __values(o) {
|
||
|
var m = typeof Symbol === "function" && o[Symbol.iterator], i = 0;
|
||
|
if (m) return m.call(o);
|
||
|
return {
|
||
|
next: function () {
|
||
|
if (o && i >= o.length) o = void 0;
|
||
|
return { value: o && o[i++], done: !o };
|
||
|
}
|
||
|
};
|
||
|
}
|
||
|
|
||
|
function __read(o, n) {
|
||
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
||
|
if (!m) return o;
|
||
|
var i = m.call(o), r, ar = [], e;
|
||
|
try {
|
||
|
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
||
|
}
|
||
|
catch (error) { e = { error: error }; }
|
||
|
finally {
|
||
|
try {
|
||
|
if (r && !r.done && (m = i["return"])) m.call(i);
|
||
|
}
|
||
|
finally { if (e) throw e.error; }
|
||
|
}
|
||
|
return ar;
|
||
|
}
|
||
|
|
||
|
function __spread() {
|
||
|
for (var ar = [], i = 0; i < arguments.length; i++)
|
||
|
ar = ar.concat(__read(arguments[i]));
|
||
|
return ar;
|
||
|
}
|
||
|
|
||
|
function __spreadArrays() {
|
||
|
for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;
|
||
|
for (var r = Array(s), k = 0, i = 0; i < il; i++)
|
||
|
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
|
||
|
r[k] = a[j];
|
||
|
return r;
|
||
|
};
|
||
|
|
||
|
function __await(v) {
|
||
|
return this instanceof __await ? (this.v = v, this) : new __await(v);
|
||
|
}
|
||
|
|
||
|
function __asyncGenerator(thisArg, _arguments, generator) {
|
||
|
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
|
||
|
var g = generator.apply(thisArg, _arguments || []), i, q = [];
|
||
|
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
|
||
|
function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
|
||
|
function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }
|
||
|
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
|
||
|
function fulfill(value) { resume("next", value); }
|
||
|
function reject(value) { resume("throw", value); }
|
||
|
function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }
|
||
|
}
|
||
|
|
||
|
function __asyncDelegator(o) {
|
||
|
var i, p;
|
||
|
return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
|
||
|
function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
|
||
|
}
|
||
|
|
||
|
function __asyncValues(o) {
|
||
|
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
|
||
|
var m = o[Symbol.asyncIterator], i;
|
||
|
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
|
||
|
function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
|
||
|
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }
|
||
|
}
|
||
|
|
||
|
function __makeTemplateObject(cooked, raw) {
|
||
|
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
||
|
return cooked;
|
||
|
};
|
||
|
|
||
|
function __importStar(mod) {
|
||
|
if (mod && mod.__esModule) return mod;
|
||
|
var result = {};
|
||
|
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
|
||
|
result.default = mod;
|
||
|
return result;
|
||
|
}
|
||
|
|
||
|
function __importDefault(mod) {
|
||
|
return (mod && mod.__esModule) ? mod : { default: mod };
|
||
|
}
|
||
|
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./node_modules/webpack/buildin/global.js":
|
||
|
/*!***********************************!*\
|
||
|
!*** (webpack)/buildin/global.js ***!
|
||
|
\***********************************/
|
||
|
/*! no static exports found */
|
||
|
/***/ (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;
|
||
|
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/scss/index.scss":
|
||
|
/*!*****************************!*\
|
||
|
!*** ./src/scss/index.scss ***!
|
||
|
\*****************************/
|
||
|
/*! no static exports found */
|
||
|
/***/ (function(module, exports, __webpack_require__) {
|
||
|
|
||
|
module.exports = __webpack_require__.p + "bundle.css";
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/ts/components/mdcConf.ts":
|
||
|
/*!**************************************!*\
|
||
|
!*** ./src/ts/components/mdcConf.ts ***!
|
||
|
\**************************************/
|
||
|
/*! exports provided: default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _material_ripple__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @material/ripple */ "./node_modules/@material/ripple/index.js");
|
||
|
/* harmony import */ var _material_textfield__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @material/textfield */ "./node_modules/@material/textfield/index.js");
|
||
|
/* harmony import */ var _material_top_app_bar__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @material/top-app-bar */ "./node_modules/@material/top-app-bar/index.js");
|
||
|
/**
|
||
|
* Copyright 2019 Mashiro
|
||
|
* @description material-components initial configuration
|
||
|
* @author Mashiro
|
||
|
* @license MIT
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
const Conf = [['.mdc-top-app-bar', _material_top_app_bar__WEBPACK_IMPORTED_MODULE_2__["MDCTopAppBar"]], ['.mdc-text-field', _material_textfield__WEBPACK_IMPORTED_MODULE_1__["MDCTextField"]], [['.mdc-button', '.primary-action'], _material_ripple__WEBPACK_IMPORTED_MODULE_0__["MDCRipple"]]];
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (Conf);
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/ts/components/mdcInit.ts":
|
||
|
/*!**************************************!*\
|
||
|
!*** ./src/ts/components/mdcInit.ts ***!
|
||
|
\**************************************/
|
||
|
/*! exports provided: default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _mdcConf__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./mdcConf */ "./src/ts/components/mdcConf.ts");
|
||
|
/**
|
||
|
* Copyright 2019 Mashiro
|
||
|
* @description material-components initial handler
|
||
|
* @author Mashiro
|
||
|
* @license MIT
|
||
|
*/
|
||
|
|
||
|
const Conf = _mdcConf__WEBPACK_IMPORTED_MODULE_0__["default"];
|
||
|
/**
|
||
|
* Initial [material-components-web](https://github.com/material-components/material-components-web/)
|
||
|
* through configuration in `mdcConf.ts``.
|
||
|
* See <https://git.io/JegHJ>
|
||
|
*/
|
||
|
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (function () {
|
||
|
let components = [];
|
||
|
|
||
|
for (const i of Conf) {
|
||
|
if (typeof i[0] == 'string') {
|
||
|
const component = i[0];
|
||
|
const constructor = i[1];
|
||
|
components.map.call(document.querySelectorAll(component), function (e) {
|
||
|
return new constructor(e);
|
||
|
});
|
||
|
} else if (typeof i[0] == 'object') {
|
||
|
const component = i[0].join(',');
|
||
|
const constructor = i[1];
|
||
|
components.map.call(document.querySelectorAll(component), function (e) {
|
||
|
return new constructor(e);
|
||
|
});
|
||
|
}
|
||
|
}
|
||
|
});
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/ts/index.ts":
|
||
|
/*!*************************!*\
|
||
|
!*** ./src/ts/index.ts ***!
|
||
|
\*************************/
|
||
|
/*! no exports provided */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _modules_coverImgInit__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./modules/coverImgInit */ "./src/ts/modules/coverImgInit.ts");
|
||
|
/* harmony import */ var _modules_headerBarScrollHandler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./modules/headerBarScrollHandler */ "./src/ts/modules/headerBarScrollHandler.ts");
|
||
|
/* harmony import */ var _components_mdcInit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./components/mdcInit */ "./src/ts/components/mdcInit.ts");
|
||
|
/**
|
||
|
* Copyright 2019 Mashiro
|
||
|
* @description Main
|
||
|
* @author Mashiro
|
||
|
* @license MIT
|
||
|
*/
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
window.onscroll = function () {
|
||
|
Object(_modules_headerBarScrollHandler__WEBPACK_IMPORTED_MODULE_1__["default"])();
|
||
|
};
|
||
|
|
||
|
window.onload = function () {
|
||
|
Object(_modules_coverImgInit__WEBPACK_IMPORTED_MODULE_0__["default"])();
|
||
|
Object(_components_mdcInit__WEBPACK_IMPORTED_MODULE_2__["default"])();
|
||
|
};
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/ts/modules/coverImgInit.ts":
|
||
|
/*!****************************************!*\
|
||
|
!*** ./src/ts/modules/coverImgInit.ts ***!
|
||
|
\****************************************/
|
||
|
/*! exports provided: default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var parallax_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! parallax-js */ "./node_modules/parallax-js/dist/parallax.js");
|
||
|
/* harmony import */ var parallax_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(parallax_js__WEBPACK_IMPORTED_MODULE_0__);
|
||
|
/**
|
||
|
* Copyright 2019 Mashiro
|
||
|
* @description Sakura theme module
|
||
|
* @author Mashiro
|
||
|
* @license MIT
|
||
|
*/
|
||
|
|
||
|
/**
|
||
|
* Initial index cover image and image box.
|
||
|
* Include Parallax box initial and `#cover-img-container` size initial.
|
||
|
*/
|
||
|
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (function () {
|
||
|
let coverImgContainer = document.querySelector("#cover-img-container");
|
||
|
coverImgContainer.style.height = `${window.innerHeight}px`;
|
||
|
let headerTopAfter = document.querySelector("#header-top-after");
|
||
|
headerTopAfter.style.height = `${window.innerHeight}px`;
|
||
|
|
||
|
/**
|
||
|
* cover: `img#cover-img`
|
||
|
*/
|
||
|
let coverImg = {};
|
||
|
/**
|
||
|
* mark: `figure#cover-img-container`
|
||
|
*/
|
||
|
|
||
|
let coverBox = {};
|
||
|
/**
|
||
|
* layer: `div#img-view`
|
||
|
*/
|
||
|
|
||
|
let coverView = {};
|
||
|
coverImg.e = document.querySelector("#cover-img");
|
||
|
coverImg.w = coverImg.e.naturalWidth;
|
||
|
coverImg.h = coverImg.e.naturalHeight;
|
||
|
coverBox.e = document.querySelector("#cover-img-container");
|
||
|
coverBox.w = coverBox.e.offsetWidth;
|
||
|
coverBox.h = coverBox.e.offsetHeight;
|
||
|
coverView.e = document.querySelector("#img-view");
|
||
|
coverBox.e.style.height = `${window.innerHeight}px`;
|
||
|
coverBox.f = coverBox.w >= 1000 || coverBox.h >= 1000 ? 1000 : 500;
|
||
|
|
||
|
if (coverBox.w >= coverBox.h) {
|
||
|
coverBox.i = coverBox.w / coverBox.f * 50;
|
||
|
coverBox.y = coverBox.i;
|
||
|
coverBox.x = coverBox.i * coverBox.w / coverBox.h;
|
||
|
} else {
|
||
|
coverBox.i = coverBox.h / coverBox.f * 50;
|
||
|
coverBox.x = coverBox.i;
|
||
|
coverBox.y = coverBox.i * coverBox.h / coverBox.w;
|
||
|
}
|
||
|
|
||
|
coverView.e.style.cssText = `
|
||
|
width: ${coverBox.w + coverBox.x}px;
|
||
|
height: ${coverBox.h + coverBox.y}px;
|
||
|
margin-left: ${-0.5 * coverBox.x}px;
|
||
|
margin-top: ${-0.5 * coverBox.y}px`;
|
||
|
coverImg.e.style.cssText = `
|
||
|
width: ${coverView.w + coverView.x}px;
|
||
|
height: ${coverView.h + coverView.y}px`;
|
||
|
|
||
|
if (!coverImg.w) {
|
||
|
coverImg.w = coverImg.e.offsetWidth;
|
||
|
coverImg.h = coverImg.e.offsetHeight;
|
||
|
}
|
||
|
|
||
|
coverImg._w = coverImg.e.parentElement.offsetWidth;
|
||
|
coverImg._h = coverImg.e.parentElement.offsetHeight;
|
||
|
coverImg.ratio = coverImg.h / coverImg.w;
|
||
|
|
||
|
if (coverImg._h / coverImg._w > coverImg.ratio) {
|
||
|
coverImg.e.style.height = coverImg._h + 'px';
|
||
|
coverImg.e.style.width = coverImg._h / coverImg.ratio + 'px';
|
||
|
} else {
|
||
|
coverImg.e.style.width = coverImg._w + 'px';
|
||
|
coverImg.e.style.height = coverImg._w * coverImg.ratio + 'px';
|
||
|
}
|
||
|
|
||
|
coverImg.e.style.left = (coverImg._w - parseInt(coverImg.e.style.width)) / 2 + 'px';
|
||
|
coverImg.e.style.top = (coverImg._h - parseInt(coverImg.e.style.height)) / 2 + 'px';
|
||
|
let scene = document.querySelector('#cover-img-container');
|
||
|
let parallaxInstance = new parallax_js__WEBPACK_IMPORTED_MODULE_0___default.a(scene);
|
||
|
});
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/ts/modules/headerBarScrollHandler.ts":
|
||
|
/*!**************************************************!*\
|
||
|
!*** ./src/ts/modules/headerBarScrollHandler.ts ***!
|
||
|
\**************************************************/
|
||
|
/*! exports provided: default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/* harmony import */ var _scrollDirection__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./scrollDirection */ "./src/ts/modules/scrollDirection.ts");
|
||
|
/**
|
||
|
* @description Sakura theme module
|
||
|
* @author Mashiro
|
||
|
* @since 19/10/31
|
||
|
* @license MIT
|
||
|
*/
|
||
|
|
||
|
/**
|
||
|
* Site top bar handler when page scroll
|
||
|
*/
|
||
|
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (function () {
|
||
|
let ele = document.querySelector("#nav-header");
|
||
|
|
||
|
if (Object(_scrollDirection__WEBPACK_IMPORTED_MODULE_0__["default"])('y') == 'down') {
|
||
|
ele.style.top = `-120px`;
|
||
|
} else if (Object(_scrollDirection__WEBPACK_IMPORTED_MODULE_0__["default"])('y') == 'up') {
|
||
|
ele.style.top = `0px`;
|
||
|
}
|
||
|
});
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ "./src/ts/modules/scrollDirection.ts":
|
||
|
/*!*******************************************!*\
|
||
|
!*** ./src/ts/modules/scrollDirection.ts ***!
|
||
|
\*******************************************/
|
||
|
/*! exports provided: default */
|
||
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
||
|
|
||
|
"use strict";
|
||
|
__webpack_require__.r(__webpack_exports__);
|
||
|
/**
|
||
|
* @description Sakura theme module
|
||
|
* @author Mashiro
|
||
|
* @since 19/10/31
|
||
|
* @license MIT
|
||
|
*/
|
||
|
let scrollAction = {
|
||
|
x: undefined,
|
||
|
y: undefined,
|
||
|
d: undefined
|
||
|
};
|
||
|
/**
|
||
|
* Detect window scroll direction
|
||
|
* @param {string} direction option: `Y`/`y` - horizontal; `X`/`x` - vertical
|
||
|
* @return {string} return window scroll direction
|
||
|
*/
|
||
|
|
||
|
/* harmony default export */ __webpack_exports__["default"] = (function (direction) {
|
||
|
if (scrollAction.x == undefined) {
|
||
|
scrollAction.x = window.pageXOffset;
|
||
|
scrollAction.y = window.pageYOffset;
|
||
|
}
|
||
|
|
||
|
let diffX = scrollAction.x - window.pageXOffset;
|
||
|
let diffY = scrollAction.y - window.pageYOffset;
|
||
|
|
||
|
if (direction == 'x' || direction == 'X') {
|
||
|
if (diffX < 0) {
|
||
|
scrollAction.d = 'right';
|
||
|
} else if (diffX > 0) {
|
||
|
scrollAction.d = 'left';
|
||
|
}
|
||
|
} else {
|
||
|
if (diffY < 0) {
|
||
|
scrollAction.d = 'down';
|
||
|
} else if (diffY > 0) {
|
||
|
scrollAction.d = 'up';
|
||
|
}
|
||
|
}
|
||
|
|
||
|
scrollAction.x = window.pageXOffset;
|
||
|
scrollAction.y = window.pageYOffset;
|
||
|
return scrollAction.d;
|
||
|
});
|
||
|
|
||
|
/***/ }),
|
||
|
|
||
|
/***/ 0:
|
||
|
/*!*****************************************************!*\
|
||
|
!*** multi ./src/scss/index.scss ./src/ts/index.ts ***!
|
||
|
\*****************************************************/
|
||
|
/*! no static exports found */
|
||
|
/***/ (function(module, exports, __webpack_require__) {
|
||
|
|
||
|
__webpack_require__(/*! ./src/scss/index.scss */"./src/scss/index.scss");
|
||
|
module.exports = __webpack_require__(/*! ./src/ts/index.ts */"./src/ts/index.ts");
|
||
|
|
||
|
|
||
|
/***/ })
|
||
|
|
||
|
/******/ });
|
||
|
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vd2VicGFjay9ib290c3RyYXAiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9iYXNlL2NvbXBvbmVudC5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL2Jhc2UvZm91bmRhdGlvbi5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL2RvbS9ldmVudHMuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9kb20vcG9ueWZpbGwuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9mbG9hdGluZy1sYWJlbC9jb21wb25lbnQuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9mbG9hdGluZy1sYWJlbC9jb25zdGFudHMuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9mbG9hdGluZy1sYWJlbC9mb3VuZGF0aW9uLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvbGluZS1yaXBwbGUvY29tcG9uZW50LmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvbGluZS1yaXBwbGUvY29uc3RhbnRzLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvbGluZS1yaXBwbGUvZm91bmRhdGlvbi5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL25vdGNoZWQtb3V0bGluZS9jb21wb25lbnQuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9ub3RjaGVkLW91dGxpbmUvY29uc3RhbnRzLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvbm90Y2hlZC1vdXRsaW5lL2ZvdW5kYXRpb24uanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC9yaXBwbGUvY29tcG9uZW50LmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvcmlwcGxlL2NvbnN0YW50cy5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL3JpcHBsZS9mb3VuZGF0aW9uLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvcmlwcGxlL2luZGV4LmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvcmlwcGxlL3V0aWwuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvY2hhcmFjdGVyLWNvdW50ZXIvY29tcG9uZW50LmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdGV4dGZpZWxkL2NoYXJhY3Rlci1jb3VudGVyL2NvbnN0YW50cy5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL3RleHRmaWVsZC9jaGFyYWN0ZXItY291bnRlci9mb3VuZGF0aW9uLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdGV4dGZpZWxkL2NoYXJhY3Rlci1jb3VudGVyL2luZGV4LmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdGV4dGZpZWxkL2NvbXBvbmVudC5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL3RleHRmaWVsZC9jb25zdGFudHMuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvZm91bmRhdGlvbi5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL3RleHRmaWVsZC9oZWxwZXItdGV4dC9jb21wb25lbnQuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvaGVscGVyLXRleHQvY29uc3RhbnRzLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdGV4dGZpZWxkL2hlbHBlci10ZXh0L2ZvdW5kYXRpb24uanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvaGVscGVyLXRleHQvaW5kZXguanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvaWNvbi9jb21wb25lbnQuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvaWNvbi9jb25zdGFudHMuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvaWNvbi9mb3VuZGF0aW9uLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdGV4dGZpZWxkL2ljb24vaW5kZXguanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90ZXh0ZmllbGQvaW5kZXguanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90b3AtYXBwLWJhci9jb21wb25lbnQuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90b3AtYXBwLWJhci9jb25zdGFudHMuanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL0BtYXRlcmlhbC90b3AtYXBwLWJhci9maXhlZC9mb3VuZGF0aW9uLmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdG9wLWFwcC1iYXIvZm91bmRhdGlvbi5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL3RvcC1hcHAtYmFyL2luZGV4LmpzIiwid2VicGFjazovLy8uL25vZGVfbW9kdWxlcy9AbWF0ZXJpYWwvdG9wLWFwcC1iYXIvc2hvcnQvZm91bmRhdGlvbi5qcyIsIndlYnBhY2s6Ly8vLi9ub2RlX21vZHVsZXMvQG1hdGVyaWFsL3RvcC1hcHAtYmFyL3N0YW5kYXJkL2ZvdW5kYXRpb24uanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL3BhcmFsbGF4LWpzL2Rpc3QvcGFyYWxsYXguanMiLCJ3ZWJwYWNrOi8vLy4vbm9kZV9tb2R1bGVzL3RzbGliL3RzbGliLmVzNi5qcyIsIndlYnBhY2s6Ly8vKHdlYnBhY2spL2J1aWxkaW4vZ2xvYmFsLmpzIiwid2VicGFjazovLy8uL3NyYy9zY3NzL2luZGV4LnNjc3MiLCJ3ZWJwYWNrOi8vLy4vc3JjL3RzL2NvbXBvbmVudHMvbWRjQ29uZi50cyIsIndlYnBhY2s6Ly8vLi9zcmMvdHMvY29tcG9uZW50cy9tZGNJbml0LnRzIiwid2VicGFjazovLy8uL3NyYy90cy9pbmRleC50cyIsIndlYnBhY2s6Ly8
|