auth0-lock 11.35.0 → 12.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.browserslistrc +1 -0
- package/.circleci/config.yml +3 -1
- package/.shiprc +4 -5
- package/CHANGELOG.md +25 -0
- package/DEVELOPMENT.md +1 -1
- package/README.md +20 -16
- package/karma.conf.js +1 -1
- package/lib/CSSCore.js +1 -4
- package/lib/__tests__/auth_button.js +12 -22
- package/lib/__tests__/connection/database/actions.js +48 -49
- package/lib/__tests__/connection/database/index.js +22 -28
- package/lib/__tests__/connection/database/login_pane.js +24 -47
- package/lib/__tests__/connection/database/password_reset_confirmation.js +23 -32
- package/lib/__tests__/connection/database/reset_password.js +17 -39
- package/lib/__tests__/connection/database/signed_up_confirmation.js +23 -32
- package/lib/__tests__/connection/enterprise/actions.js +22 -47
- package/lib/__tests__/connection/enterprise/hrd_pane.js +16 -33
- package/lib/__tests__/connection/enterprise/hrd_screen.js +26 -40
- package/lib/__tests__/connection/enterprise/quick_auth_screen.js +32 -75
- package/lib/__tests__/connection/passwordless/ask_vcode.js +29 -51
- package/lib/__tests__/connection/passwordless/email_sent_confirmation.js +23 -32
- package/lib/__tests__/connection/passwordless/passwordless.js +35 -97
- package/lib/__tests__/core/actions.js +23 -46
- package/lib/__tests__/core/client/index.js +10 -13
- package/lib/__tests__/core/index.js +46 -94
- package/lib/__tests__/core/remote_data.js +14 -20
- package/lib/__tests__/core/signed_in_confirmation.js +23 -32
- package/lib/__tests__/core/sso/last_login_screen.js +27 -50
- package/lib/__tests__/core/tenant.js +10 -12
- package/lib/__tests__/core/web_api/helper.js +6 -14
- package/lib/__tests__/core/web_api/p2_api.js +38 -33
- package/lib/__tests__/core/web_api.js +37 -33
- package/lib/__tests__/engine/classic/login.js +20 -41
- package/lib/__tests__/engine/classic/mfa_login_screen.js +6 -19
- package/lib/__tests__/engine/classic/sign_up_pane.js +33 -55
- package/lib/__tests__/engine/classic/sign_up_screen.js +18 -45
- package/lib/__tests__/engine/classic.js +13 -6
- package/lib/__tests__/engine/passwordless/social_or_email_login_screen.js +7 -28
- package/lib/__tests__/engine/passwordless/social_or_phone_number_login_screen.js +7 -28
- package/lib/__tests__/engine/passwordless.js +2 -5
- package/lib/__tests__/field/captcha/recaptcha_enterprise.js +27 -27
- package/lib/__tests__/field/captcha/recaptchav2.js +27 -27
- package/lib/__tests__/field/captcha.js +39 -51
- package/lib/__tests__/field/custom_input.js +23 -47
- package/lib/__tests__/field/email.js +2 -3
- package/lib/__tests__/field/email_pane.js +25 -48
- package/lib/__tests__/field/field.js +9 -13
- package/lib/__tests__/field/login_pane.js +30 -34
- package/lib/__tests__/field/mfa_code_pane.js +13 -28
- package/lib/__tests__/field/option_selection_pane.js +7 -25
- package/lib/__tests__/field/password.js +6 -12
- package/lib/__tests__/field/password_pane.js +29 -46
- package/lib/__tests__/field/phone_number_pane.js +18 -41
- package/lib/__tests__/field/social_buttons_pane.js +30 -47
- package/lib/__tests__/field/username.js +27 -48
- package/lib/__tests__/field/username_pane.js +30 -47
- package/lib/__tests__/field/vcode.js +5 -13
- package/lib/__tests__/field/vcode_pane.js +20 -44
- package/lib/__tests__/i18n.js +28 -53
- package/lib/__tests__/quick-auth/actions.js +4 -27
- package/lib/__tests__/setup-tests.js +7 -9
- package/lib/__tests__/testUtils.js +41 -58
- package/lib/__tests__/ui/box/chrome.js +24 -49
- package/lib/__tests__/ui/box/confirmation_pane.js +23 -42
- package/lib/__tests__/ui/box/container.js +21 -46
- package/lib/__tests__/ui/box/global_message.js +60 -37
- package/lib/__tests__/ui/input/email_input.js +6 -17
- package/lib/__tests__/ui/input/input_wrap.js +6 -19
- package/lib/__tests__/ui/input/password/password_strength.js +13 -15
- package/lib/__tests__/ui/input/password_input.js +22 -27
- package/lib/__tests__/utils/format.js +10 -17
- package/lib/__tests__/utils/url_utils.js +2 -5
- package/lib/avatar/gravatar_provider.js +13 -28
- package/lib/avatar.js +22 -41
- package/lib/browser.js +372 -23
- package/lib/connection/captcha.js +15 -34
- package/lib/connection/database/actions.js +39 -108
- package/lib/connection/database/index.js +90 -191
- package/lib/connection/database/login_pane.js +107 -147
- package/lib/connection/database/login_sign_up_tabs.js +106 -125
- package/lib/connection/database/mfa_pane.js +50 -69
- package/lib/connection/database/password_reset_confirmation.js +51 -73
- package/lib/connection/database/reset_password.js +116 -132
- package/lib/connection/database/reset_password_pane.js +45 -56
- package/lib/connection/database/sign_up_terms.js +17 -23
- package/lib/connection/database/signed_up_confirmation.js +52 -75
- package/lib/connection/enterprise/actions.js +23 -52
- package/lib/connection/enterprise/hrd_pane.js +60 -76
- package/lib/connection/enterprise/hrd_screen.js +60 -75
- package/lib/connection/enterprise/kerberos_screen.js +46 -60
- package/lib/connection/enterprise/quick_auth_screen.js +46 -64
- package/lib/connection/enterprise/single_sign_on_notice.js +14 -26
- package/lib/connection/enterprise.js +51 -84
- package/lib/connection/passwordless/actions.js +29 -65
- package/lib/connection/passwordless/ask_vcode.js +53 -60
- package/lib/connection/passwordless/email_sent_confirmation.js +129 -179
- package/lib/connection/passwordless/index.js +36 -68
- package/lib/connection/social/index.js +12 -15
- package/lib/core/actions.js +33 -85
- package/lib/core/client/index.js +38 -58
- package/lib/core/client/settings.js +12 -20
- package/lib/core/error_screen.js +38 -52
- package/lib/core/index.js +154 -305
- package/lib/core/loading_screen.js +61 -71
- package/lib/core/pane_separator.js +10 -10
- package/lib/core/remote_data.js +30 -51
- package/lib/core/screen.js +85 -79
- package/lib/core/signed_in_confirmation.js +51 -73
- package/lib/core/sso/data.js +9 -17
- package/lib/core/sso/index.js +5 -6
- package/lib/core/sso/last_login_screen.js +46 -63
- package/lib/core/tenant/index.js +37 -59
- package/lib/core/tenant/settings.js +11 -15
- package/lib/core/web_api/helper.js +22 -28
- package/lib/core/web_api/p2_api.js +162 -171
- package/lib/core/web_api.js +106 -94
- package/lib/core.js +126 -160
- package/lib/engine/classic/login.js +92 -144
- package/lib/engine/classic/mfa_login_screen.js +61 -67
- package/lib/engine/classic/sign_up_pane.js +89 -123
- package/lib/engine/classic/sign_up_screen.js +112 -158
- package/lib/engine/classic.js +122 -183
- package/lib/engine/passwordless/social_or_email_login_screen.js +80 -116
- package/lib/engine/passwordless/social_or_phone_number_login_screen.js +79 -110
- package/lib/engine/passwordless.js +75 -104
- package/lib/field/actions.js +11 -17
- package/lib/field/captcha/captcha_pane.js +83 -103
- package/lib/field/captcha/recaptcha.js +140 -145
- package/lib/field/captcha.js +7 -10
- package/lib/field/custom_input.js +37 -50
- package/lib/field/email/email_pane.js +90 -109
- package/lib/field/email.js +17 -35
- package/lib/field/index.js +50 -87
- package/lib/field/mfa-code/mfa_code_pane.js +57 -71
- package/lib/field/mfa_code.js +15 -21
- package/lib/field/option_selection_pane.js +16 -22
- package/lib/field/password/password_pane.js +79 -91
- package/lib/field/password.js +8 -14
- package/lib/field/phone-number/locations.js +7 -3
- package/lib/field/phone-number/phone_number_pane.js +87 -124
- package/lib/field/phone_number.js +16 -30
- package/lib/field/social/event.js +9 -12
- package/lib/field/social/social_buttons_pane.js +93 -121
- package/lib/field/username/username_pane.js +105 -123
- package/lib/field/username.js +16 -26
- package/lib/field/vcode/vcode_pane.js +67 -93
- package/lib/field/vcode.js +5 -5
- package/lib/i18n/af.js +7 -4
- package/lib/i18n/ar.js +7 -4
- package/lib/i18n/az.js +7 -4
- package/lib/i18n/bg.js +7 -4
- package/lib/i18n/ca.js +7 -4
- package/lib/i18n/cs.js +7 -4
- package/lib/i18n/da.js +7 -4
- package/lib/i18n/de.js +7 -3
- package/lib/i18n/el.js +7 -4
- package/lib/i18n/en.js +9 -4
- package/lib/i18n/es.js +7 -3
- package/lib/i18n/et.js +7 -4
- package/lib/i18n/fa.js +7 -4
- package/lib/i18n/fi.js +7 -4
- package/lib/i18n/fr.js +7 -4
- package/lib/i18n/he.js +7 -4
- package/lib/i18n/hr.js +7 -4
- package/lib/i18n/hu.js +7 -4
- package/lib/i18n/id.js +7 -4
- package/lib/i18n/it.js +7 -3
- package/lib/i18n/ja.js +7 -4
- package/lib/i18n/ko.js +7 -4
- package/lib/i18n/lt.js +7 -4
- package/lib/i18n/lv.js +7 -4
- package/lib/i18n/ms.js +7 -4
- package/lib/i18n/nb.js +7 -4
- package/lib/i18n/nl.js +7 -4
- package/lib/i18n/nn.js +7 -4
- package/lib/i18n/no.js +7 -4
- package/lib/i18n/pl.js +7 -4
- package/lib/i18n/pt-br.js +7 -3
- package/lib/i18n/pt.js +7 -4
- package/lib/i18n/ro.js +7 -4
- package/lib/i18n/ru.js +7 -4
- package/lib/i18n/sk.js +7 -4
- package/lib/i18n/sl.js +7 -4
- package/lib/i18n/sr.js +7 -4
- package/lib/i18n/sv.js +7 -4
- package/lib/i18n/tr.js +7 -4
- package/lib/i18n/ua.js +7 -4
- package/lib/i18n/uk.js +7 -4
- package/lib/i18n/vi.js +7 -4
- package/lib/i18n/zh-tw.js +7 -4
- package/lib/i18n/zh.js +7 -4
- package/lib/i18n.js +38 -75
- package/lib/index.js +14 -17
- package/lib/lock.js +29 -32
- package/lib/passwordless.js +29 -31
- package/lib/quick-auth/actions.js +19 -26
- package/lib/quick_auth.js +8 -10
- package/lib/sanitizer.js +5 -5
- package/lib/store/index.js +22 -42
- package/lib/sync.js +21 -42
- package/lib/ui/box/button.js +85 -105
- package/lib/ui/box/chrome.js +463 -548
- package/lib/ui/box/confirmation_pane.js +34 -48
- package/lib/ui/box/container.js +305 -339
- package/lib/ui/box/global_message.js +51 -60
- package/lib/ui/box/header.js +155 -177
- package/lib/ui/box/multisize_slide.js +233 -229
- package/lib/ui/box/success_pane.js +34 -37
- package/lib/ui/box.js +88 -93
- package/lib/ui/button/auth_button.js +44 -51
- package/lib/ui/input/captcha_input.js +162 -181
- package/lib/ui/input/checkbox_input.js +57 -59
- package/lib/ui/input/email_input.js +117 -124
- package/lib/ui/input/input_wrap.js +65 -80
- package/lib/ui/input/location_input.js +130 -150
- package/lib/ui/input/mfa_code_input.js +98 -98
- package/lib/ui/input/password/password_strength.js +103 -127
- package/lib/ui/input/password_input.js +141 -147
- package/lib/ui/input/phone_number_input.js +101 -109
- package/lib/ui/input/select_input.js +120 -132
- package/lib/ui/input/text_input.js +89 -84
- package/lib/ui/input/username_input.js +109 -115
- package/lib/ui/input/vcode_input.js +110 -118
- package/lib/ui/list.js +224 -247
- package/lib/ui/pane/quick_auth_pane.js +55 -80
- package/lib/utils/atom.js +55 -48
- package/lib/utils/cache.js +54 -43
- package/lib/utils/cdn_utils.js +17 -31
- package/lib/utils/createRef.js +3 -1
- package/lib/utils/data_utils.js +10 -16
- package/lib/utils/fn_utils.js +5 -4
- package/lib/utils/format.js +6 -8
- package/lib/utils/id_utils.js +4 -3
- package/lib/utils/jsonp_utils.js +20 -17
- package/lib/utils/media_utils.js +4 -2
- package/lib/utils/preload_utils.js +4 -3
- package/lib/utils/string_utils.js +4 -4
- package/lib/utils/url_utils.js +4 -3
- package/package.json +48 -34
- package/webpack.config.js +36 -3
|
@@ -1,154 +1,130 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
var
|
|
10
|
-
|
|
11
|
-
var
|
|
12
|
-
|
|
13
|
-
var _react2 = _interopRequireDefault(_react);
|
|
14
|
-
|
|
15
|
-
var _policy = require('password-sheriff/lib/policy');
|
|
16
|
-
|
|
17
|
-
var _policy2 = _interopRequireDefault(_policy);
|
|
18
|
-
|
|
19
|
-
var _format = require('../../../utils/format');
|
|
20
|
-
|
|
21
|
-
var _format2 = _interopRequireDefault(_format);
|
|
22
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
|
+
var _react = _interopRequireDefault(require("react"));
|
|
10
|
+
var _policy = _interopRequireDefault(require("password-sheriff/lib/policy"));
|
|
11
|
+
var _format = _interopRequireDefault(require("../../../utils/format"));
|
|
23
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
24
|
-
|
|
13
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
14
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
15
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
16
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
17
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
18
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
19
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
25
20
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
26
|
-
|
|
27
|
-
function
|
|
28
|
-
|
|
29
|
-
function
|
|
30
|
-
|
|
31
|
-
|
|
21
|
+
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, _toPropertyKey(descriptor.key), descriptor); } }
|
|
22
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
23
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
24
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
25
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
26
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
27
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
28
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
29
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
30
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
31
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
32
|
+
var PasswordStrength = /*#__PURE__*/function (_React$Component) {
|
|
32
33
|
_inherits(PasswordStrength, _React$Component);
|
|
33
|
-
|
|
34
|
+
var _super = _createSuper(PasswordStrength);
|
|
34
35
|
function PasswordStrength() {
|
|
35
36
|
_classCallCheck(this, PasswordStrength);
|
|
36
|
-
|
|
37
|
-
return _possibleConstructorReturn(this, _React$Component.apply(this, arguments));
|
|
37
|
+
return _super.apply(this, arguments);
|
|
38
38
|
}
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
{ className: className },
|
|
69
|
-
_react2.default.createElement(List, { items: analysis.rules })
|
|
70
|
-
);
|
|
71
|
-
};
|
|
72
|
-
|
|
39
|
+
_createClass(PasswordStrength, [{
|
|
40
|
+
key: "render",
|
|
41
|
+
value: function render() {
|
|
42
|
+
var _this$props = this.props,
|
|
43
|
+
password = _this$props.password,
|
|
44
|
+
policy = _this$props.policy,
|
|
45
|
+
messages = _this$props.messages;
|
|
46
|
+
var analysis = new _policy.default(policy.toJS()).missing(password);
|
|
47
|
+
// TODO: add a component for fadeIn / fadeOut animations?
|
|
48
|
+
var className = 'auth0-lock-password-strength animated ' + (!analysis.verified ? 'fadeIn' : 'fadeOut');
|
|
49
|
+
var prepareMessage = function prepareMessage(items) {
|
|
50
|
+
items && items.forEach(function (o) {
|
|
51
|
+
if (messages[o.code]) {
|
|
52
|
+
o.message = messages[o.code];
|
|
53
|
+
}
|
|
54
|
+
o.message = _format.default.apply(void 0, [o.message].concat(_toConsumableArray(o.format || [])));
|
|
55
|
+
if (o.items) {
|
|
56
|
+
prepareMessage(o.items);
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
};
|
|
60
|
+
prepareMessage(analysis.rules);
|
|
61
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
|
62
|
+
className: className
|
|
63
|
+
}, /*#__PURE__*/_react.default.createElement(List, {
|
|
64
|
+
items: analysis.rules
|
|
65
|
+
}));
|
|
66
|
+
}
|
|
67
|
+
}]);
|
|
73
68
|
return PasswordStrength;
|
|
74
|
-
}(
|
|
75
|
-
|
|
69
|
+
}(_react.default.Component);
|
|
76
70
|
exports.default = PasswordStrength;
|
|
77
|
-
|
|
78
|
-
|
|
79
71
|
PasswordStrength.propTypes = {
|
|
80
|
-
messages:
|
|
81
|
-
password:
|
|
82
|
-
policy:
|
|
72
|
+
messages: _propTypes.default.object.isRequired,
|
|
73
|
+
password: _propTypes.default.string.isRequired,
|
|
74
|
+
policy: _propTypes.default.object.isRequired
|
|
83
75
|
};
|
|
84
|
-
|
|
85
76
|
PasswordStrength.defaultProps = {
|
|
86
77
|
messages: {}
|
|
87
78
|
};
|
|
88
|
-
|
|
89
|
-
var List = function (_React$Component2) {
|
|
79
|
+
var List = /*#__PURE__*/function (_React$Component2) {
|
|
90
80
|
_inherits(List, _React$Component2);
|
|
91
|
-
|
|
81
|
+
var _super2 = _createSuper(List);
|
|
92
82
|
function List() {
|
|
93
83
|
_classCallCheck(this, List);
|
|
94
|
-
|
|
95
|
-
return _possibleConstructorReturn(this, _React$Component2.apply(this, arguments));
|
|
84
|
+
return _super2.apply(this, arguments);
|
|
96
85
|
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
) : null;
|
|
109
|
-
};
|
|
110
|
-
|
|
86
|
+
_createClass(List, [{
|
|
87
|
+
key: "render",
|
|
88
|
+
value: function render() {
|
|
89
|
+
var items = this.props.items;
|
|
90
|
+
return items && items.length ? /*#__PURE__*/_react.default.createElement("ul", null, items.map(function (x, i) {
|
|
91
|
+
return /*#__PURE__*/_react.default.createElement(Item, _extends({}, x, {
|
|
92
|
+
key: i
|
|
93
|
+
}));
|
|
94
|
+
})) : null;
|
|
95
|
+
}
|
|
96
|
+
}]);
|
|
111
97
|
return List;
|
|
112
|
-
}(
|
|
113
|
-
|
|
98
|
+
}(_react.default.Component);
|
|
114
99
|
List.propTypes = {
|
|
115
|
-
items:
|
|
100
|
+
items: _propTypes.default.arrayOf(_propTypes.default.object)
|
|
116
101
|
};
|
|
117
|
-
|
|
118
|
-
var Item = function (_React$Component3) {
|
|
102
|
+
var Item = /*#__PURE__*/function (_React$Component3) {
|
|
119
103
|
_inherits(Item, _React$Component3);
|
|
120
|
-
|
|
104
|
+
var _super3 = _createSuper(Item);
|
|
121
105
|
function Item() {
|
|
122
106
|
_classCallCheck(this, Item);
|
|
123
|
-
|
|
124
|
-
return _possibleConstructorReturn(this, _React$Component3.apply(this, arguments));
|
|
107
|
+
return _super3.apply(this, arguments);
|
|
125
108
|
}
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
message
|
|
142
|
-
),
|
|
143
|
-
_react2.default.createElement(List, { items: items })
|
|
144
|
-
);
|
|
145
|
-
};
|
|
146
|
-
|
|
109
|
+
_createClass(Item, [{
|
|
110
|
+
key: "render",
|
|
111
|
+
value: function render() {
|
|
112
|
+
var _this$props2 = this.props,
|
|
113
|
+
items = _this$props2.items,
|
|
114
|
+
message = _this$props2.message,
|
|
115
|
+
verified = _this$props2.verified;
|
|
116
|
+
var className = verified ? 'auth0-lock-checked' : '';
|
|
117
|
+
return /*#__PURE__*/_react.default.createElement("li", {
|
|
118
|
+
className: className
|
|
119
|
+
}, /*#__PURE__*/_react.default.createElement("span", null, message), /*#__PURE__*/_react.default.createElement(List, {
|
|
120
|
+
items: items
|
|
121
|
+
}));
|
|
122
|
+
}
|
|
123
|
+
}]);
|
|
147
124
|
return Item;
|
|
148
|
-
}(
|
|
149
|
-
|
|
125
|
+
}(_react.default.Component);
|
|
150
126
|
Item.propTypes = {
|
|
151
|
-
items:
|
|
152
|
-
message:
|
|
153
|
-
verified:
|
|
127
|
+
items: _propTypes.default.array,
|
|
128
|
+
message: _propTypes.default.string.isRequired,
|
|
129
|
+
verified: _propTypes.default.bool.isRequired
|
|
154
130
|
};
|
|
@@ -1,169 +1,163 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
exports
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
var
|
|
9
|
-
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
var
|
|
15
|
-
|
|
16
|
-
var _input_wrap = require('./input_wrap');
|
|
17
|
-
|
|
18
|
-
var _input_wrap2 = _interopRequireDefault(_input_wrap);
|
|
19
|
-
|
|
20
|
-
var _password_strength = require('./password/password_strength');
|
|
21
|
-
|
|
22
|
-
var _password_strength2 = _interopRequireDefault(_password_strength);
|
|
23
|
-
|
|
24
|
-
var _index = require('../../core/index');
|
|
25
|
-
|
|
26
|
-
var l = _interopRequireWildcard(_index);
|
|
27
|
-
|
|
28
|
-
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
|
|
29
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.IconSvg = void 0;
|
|
7
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
var _input_wrap = _interopRequireDefault(require("./input_wrap"));
|
|
10
|
+
var _password_strength = _interopRequireDefault(require("./password/password_strength"));
|
|
11
|
+
var l = _interopRequireWildcard(require("../../core/index"));
|
|
12
|
+
var _excluded = ["invalidHint", "showPasswordStrengthMessage", "isValid", "onChange", "policy", "strengthMessages", "value", "showPassword", "lock"];
|
|
13
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
30
15
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
31
|
-
|
|
32
|
-
function
|
|
33
|
-
|
|
16
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
17
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
18
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
19
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
34
20
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
35
|
-
|
|
36
|
-
function
|
|
37
|
-
|
|
38
|
-
function
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
21
|
+
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, _toPropertyKey(descriptor.key), descriptor); } }
|
|
22
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
23
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
24
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
25
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
26
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
27
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
28
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
29
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
30
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
31
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
32
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
33
|
+
var IconSvg = /*#__PURE__*/_react.default.createElement("svg", {
|
|
34
|
+
"aria-hidden": "true",
|
|
35
|
+
focusable: "false",
|
|
36
|
+
width: "11px",
|
|
37
|
+
height: "14px",
|
|
38
|
+
viewBox: "0 0 13 16",
|
|
39
|
+
version: "1.1",
|
|
40
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
41
|
+
xmlnsXlink: "http://www.w3.org/1999/xlink",
|
|
42
|
+
className: "auth0-lock-icon auth0-lock-icon-box"
|
|
43
|
+
}, /*#__PURE__*/_react.default.createElement("g", {
|
|
44
|
+
stroke: "none",
|
|
45
|
+
strokeWidth: "1",
|
|
46
|
+
fill: "none",
|
|
47
|
+
fillRule: "evenodd"
|
|
48
|
+
}, /*#__PURE__*/_react.default.createElement("g", {
|
|
49
|
+
transform: "translate(-288.000000, -1508.000000)",
|
|
50
|
+
fill: "#888888"
|
|
51
|
+
}, /*#__PURE__*/_react.default.createElement("path", {
|
|
52
|
+
d: "M299,1523.998 L290,1523.998 C288.896,1523.998 288,1523.102 288,1521.999 L288,1515.999 C288,1514.895 288.896,1513.998 290,1513.998 L290,1513.998 L290,1512.499 C290,1510.015 292.015,1507.999 294.5,1507.999 C296.985,1507.999 299,1510.015 299,1512.499 L299,1513.999 C300.104,1513.999 301,1514.895 301,1515.999 L301,1521.999 C301,1523.103 300.104,1523.998 299,1523.998 L299,1523.998 Z M298,1512.499 C298,1510.566 296.433,1508.999 294.5,1508.999 C292.567,1508.999 291,1510.566 291,1512.499 L291,1513.998 L298,1513.998 L298,1512.499 L298,1512.499 Z M300,1515.999 C300,1515.446 299.552,1514.998 299,1514.998 L290,1514.998 C289.447,1514.998 289,1515.446 289,1515.999 L289,1521.999 C289,1522.551 289.447,1522.998 290,1522.998 L299,1522.998 C299.552,1522.998 300,1522.551 300,1521.999 L300,1515.999 L300,1515.999 Z M294.5,1520.998 C294.224,1520.998 294,1520.774 294,1520.498 L294,1517.498 C294,1517.223 294.224,1516.999 294.5,1516.999 C294.776,1516.999 295,1517.223 295,1517.498 L295,1520.498 C295,1520.774 294.776,1520.998 294.5,1520.998 L294.5,1520.998 Z"
|
|
53
|
+
}))));
|
|
54
|
+
exports.IconSvg = IconSvg;
|
|
55
|
+
var PasswordInput = /*#__PURE__*/function (_React$Component) {
|
|
65
56
|
_inherits(PasswordInput, _React$Component);
|
|
66
|
-
|
|
57
|
+
var _super = _createSuper(PasswordInput);
|
|
67
58
|
function PasswordInput(props) {
|
|
59
|
+
var _this;
|
|
68
60
|
_classCallCheck(this, PasswordInput);
|
|
69
|
-
|
|
70
|
-
var _this = _possibleConstructorReturn(this, _React$Component.call(this, props));
|
|
71
|
-
|
|
61
|
+
_this = _super.call(this, props);
|
|
72
62
|
_this.state = {};
|
|
73
63
|
return _this;
|
|
74
64
|
}
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
{
|
|
65
|
+
_createClass(PasswordInput, [{
|
|
66
|
+
key: "focus",
|
|
67
|
+
value: function focus() {
|
|
68
|
+
this.refs.input && this.refs.input.focus();
|
|
69
|
+
}
|
|
70
|
+
}, {
|
|
71
|
+
key: "hasFocus",
|
|
72
|
+
value: function hasFocus() {
|
|
73
|
+
return this.state.focused;
|
|
74
|
+
}
|
|
75
|
+
}, {
|
|
76
|
+
key: "render",
|
|
77
|
+
value: function render() {
|
|
78
|
+
var _this$props = this.props,
|
|
79
|
+
invalidHint = _this$props.invalidHint,
|
|
80
|
+
showPasswordStrengthMessage = _this$props.showPasswordStrengthMessage,
|
|
81
|
+
isValid = _this$props.isValid,
|
|
82
|
+
onChange = _this$props.onChange,
|
|
83
|
+
policy = _this$props.policy,
|
|
84
|
+
strengthMessages = _this$props.strengthMessages,
|
|
85
|
+
value = _this$props.value,
|
|
86
|
+
showPassword = _this$props.showPassword,
|
|
87
|
+
lock = _this$props.lock,
|
|
88
|
+
props = _objectWithoutProperties(_this$props, _excluded);
|
|
89
|
+
var _this$state = this.state,
|
|
90
|
+
focused = _this$state.focused,
|
|
91
|
+
changing = _this$state.changing;
|
|
92
|
+
var allowPasswordAutocomplete = l.ui.allowPasswordAutocomplete(lock);
|
|
93
|
+
var passwordStrength = policy && focused && changing && showPasswordStrengthMessage ? /*#__PURE__*/_react.default.createElement(_password_strength.default, {
|
|
94
|
+
messages: strengthMessages,
|
|
95
|
+
password: value,
|
|
96
|
+
policy: policy
|
|
97
|
+
}) : null;
|
|
98
|
+
return /*#__PURE__*/_react.default.createElement(_input_wrap.default, {
|
|
109
99
|
after: passwordStrength,
|
|
110
100
|
focused: focused,
|
|
111
101
|
invalidHint: invalidHint,
|
|
112
102
|
isValid: isValid,
|
|
113
|
-
name:
|
|
103
|
+
name: "password",
|
|
114
104
|
icon: IconSvg
|
|
115
|
-
},
|
|
116
|
-
|
|
117
|
-
ref: 'input',
|
|
105
|
+
}, /*#__PURE__*/_react.default.createElement("input", _extends({
|
|
106
|
+
ref: "input",
|
|
118
107
|
type: showPassword ? 'text' : 'password',
|
|
119
|
-
id: l.id(lock)
|
|
120
|
-
name:
|
|
121
|
-
className:
|
|
108
|
+
id: "".concat(l.id(lock), "-password"),
|
|
109
|
+
name: "password",
|
|
110
|
+
className: "auth0-lock-input",
|
|
122
111
|
autoComplete: allowPasswordAutocomplete ? 'on' : 'off',
|
|
123
|
-
autoCapitalize:
|
|
124
|
-
autoCorrect:
|
|
125
|
-
spellCheck:
|
|
112
|
+
autoCapitalize: "off",
|
|
113
|
+
autoCorrect: "off",
|
|
114
|
+
spellCheck: "false",
|
|
126
115
|
onChange: this.handleOnChange.bind(this),
|
|
127
116
|
onFocus: this.handleFocus.bind(this),
|
|
128
117
|
onBlur: this.handleBlur.bind(this),
|
|
129
118
|
value: value,
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
}, props))
|
|
134
|
-
);
|
|
135
|
-
};
|
|
136
|
-
|
|
137
|
-
PasswordInput.prototype.handleOnChange = function handleOnChange(e) {
|
|
138
|
-
var state = this.state;
|
|
139
|
-
state.changing = true;
|
|
140
|
-
this.setState(state);
|
|
141
|
-
if (this.props.onChange) {
|
|
142
|
-
this.props.onChange(e);
|
|
119
|
+
"aria-label": "Password",
|
|
120
|
+
"aria-invalid": !isValid,
|
|
121
|
+
"aria-describedby": !isValid && !policy && invalidHint ? "auth0-lock-error-msg-password" : undefined
|
|
122
|
+
}, props)));
|
|
143
123
|
}
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
124
|
+
}, {
|
|
125
|
+
key: "handleOnChange",
|
|
126
|
+
value: function handleOnChange(e) {
|
|
127
|
+
var state = this.state;
|
|
128
|
+
state.changing = true;
|
|
129
|
+
this.setState(state);
|
|
130
|
+
if (this.props.onChange) {
|
|
131
|
+
this.props.onChange(e);
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}, {
|
|
135
|
+
key: "handleFocus",
|
|
136
|
+
value: function handleFocus() {
|
|
137
|
+
this.setState({
|
|
138
|
+
focused: true
|
|
139
|
+
});
|
|
140
|
+
}
|
|
141
|
+
}, {
|
|
142
|
+
key: "handleBlur",
|
|
143
|
+
value: function handleBlur() {
|
|
144
|
+
this.setState({
|
|
145
|
+
focused: false
|
|
146
|
+
});
|
|
147
|
+
}
|
|
148
|
+
}]);
|
|
154
149
|
return PasswordInput;
|
|
155
|
-
}(
|
|
156
|
-
|
|
157
|
-
PasswordInput.propTypes = {
|
|
158
|
-
invalidHint: _propTypes2.default.string.isRequired,
|
|
159
|
-
showPasswordStrengthMessage: _propTypes2.default.bool.isRequired,
|
|
160
|
-
isValid: _propTypes2.default.bool.isRequired,
|
|
161
|
-
onChange: _propTypes2.default.func.isRequired,
|
|
162
|
-
placeholder: _propTypes2.default.string,
|
|
163
|
-
policy: _propTypes2.default.object,
|
|
164
|
-
strengthMessages: _propTypes2.default.object,
|
|
165
|
-
value: _propTypes2.default.string.isRequired,
|
|
166
|
-
showPassword: _propTypes2.default.bool.isRequired,
|
|
167
|
-
lock: _propTypes2.default.object.isRequired
|
|
168
|
-
};
|
|
150
|
+
}(_react.default.Component);
|
|
169
151
|
exports.default = PasswordInput;
|
|
152
|
+
_defineProperty(PasswordInput, "propTypes", {
|
|
153
|
+
invalidHint: _propTypes.default.string.isRequired,
|
|
154
|
+
showPasswordStrengthMessage: _propTypes.default.bool.isRequired,
|
|
155
|
+
isValid: _propTypes.default.bool.isRequired,
|
|
156
|
+
onChange: _propTypes.default.func.isRequired,
|
|
157
|
+
placeholder: _propTypes.default.string,
|
|
158
|
+
policy: _propTypes.default.object,
|
|
159
|
+
strengthMessages: _propTypes.default.object,
|
|
160
|
+
value: _propTypes.default.string.isRequired,
|
|
161
|
+
showPassword: _propTypes.default.bool.isRequired,
|
|
162
|
+
lock: _propTypes.default.object.isRequired
|
|
163
|
+
});
|