@skalfa/skalfa-component 1.0.20 → 1.0.21
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.
|
@@ -54,7 +54,7 @@ function InputPasswordComponent({ label, tip, leftIcon, rightIcon, value, invali
|
|
|
54
54
|
}, onBlur: (e) => {
|
|
55
55
|
props.onBlur?.(e);
|
|
56
56
|
setTimeout(() => inputHandler.setFocus(false), 100);
|
|
57
|
-
}, autoComplete: "off" }), leftIcon && ((0, jsx_runtime_1.jsx)(skalfa_icon_1.Icon, { className: (0, _utils_1.cn)("input-icon", "input-icon-left", (0, _utils_1.pcn)(className, "icon")), icon: leftIcon })), rightIcon && ((0, jsx_runtime_1.jsx)(skalfa_icon_1.Icon, { className: (0, _utils_1.cn)("input-icon", "input-icon-right", (0, _utils_1.pcn)(className, "icon")), icon: rightIcon }))] }), invalidMessage && ((0, jsx_runtime_1.jsx)("small", { className: "input-error-message", children: invalidMessage })), strength && ((0, jsx_runtime_1.jsxs)("div", { className: "flex items-center gap-2 mt-1", children: [(0, jsx_runtime_1.jsx)("div", { className: (0, _utils_1.cn)("password-strength-bar", strength === "weak" && "password-strength-bar-weak", strength === "strong" && "password-strength-bar-strong", strength === "excellent" && "password-strength-bar-excellent") }), (0, jsx_runtime_1.jsx)("div", { className: (0, _utils_1.cn)("password-strength-bar", strength === "weak" && "password-strength-bar-empty", strength === "strong" && "password-strength-bar-strong", strength === "excellent" && "password-strength-bar-excellent") }), (0, jsx_runtime_1.jsx)("div", { className: (0, _utils_1.cn)("password-strength-bar", (strength === "weak" || strength === "strong") && "password-strength-bar-empty", strength === "excellent" && "password-strength-bar-excellent") })
|
|
57
|
+
}, autoComplete: "off" }), leftIcon && ((0, jsx_runtime_1.jsx)(skalfa_icon_1.Icon, { className: (0, _utils_1.cn)("input-icon", "input-icon-left", (0, _utils_1.pcn)(className, "icon")), icon: leftIcon })), rightIcon && ((0, jsx_runtime_1.jsx)(skalfa_icon_1.Icon, { className: (0, _utils_1.cn)("input-icon", "input-icon-right", (0, _utils_1.pcn)(className, "icon")), icon: rightIcon }))] }), invalidMessage && ((0, jsx_runtime_1.jsx)("small", { className: "input-error-message", children: invalidMessage })), strength && ((0, jsx_runtime_1.jsxs)("div", { className: "flex items-center gap-2 mt-1", children: [(0, jsx_runtime_1.jsx)("div", { className: (0, _utils_1.cn)("password-strength-bar", strength === "weak" && "password-strength-bar-weak", strength === "strong" && "password-strength-bar-strong", strength === "excellent" && "password-strength-bar-excellent") }), (0, jsx_runtime_1.jsx)("div", { className: (0, _utils_1.cn)("password-strength-bar", strength === "weak" && "password-strength-bar-empty", strength === "strong" && "password-strength-bar-strong", strength === "excellent" && "password-strength-bar-excellent") }), (0, jsx_runtime_1.jsx)("div", { className: (0, _utils_1.cn)("password-strength-bar", (strength === "weak" || strength === "strong") && "password-strength-bar-empty", strength === "excellent" && "password-strength-bar-excellent") })] })), (0, jsx_runtime_1.jsxs)("div", { className: "input-password-confirm-wrapper", children: [(0, jsx_runtime_1.jsx)("label", { htmlFor: randomConfirmId, className: (0, _utils_1.cn)("input-label", (0, _utils_1.pcn)(className, "label")), children: l.base.passwordConfirm ? l.base.passwordConfirm() : "Password Confirm" }), (0, jsx_runtime_1.jsx)("div", { className: "relative", children: (0, jsx_runtime_1.jsx)("input", { ...props, placeholder: l.base.passwordConfirm ? l.base.passwordConfirm() : "Repeat password...", id: randomConfirmId, type: "password", className: (0, _utils_1.cn)("input", leftIcon && "input-with-left-icon", rightIcon && "input-with-right-icon", (0, _utils_1.pcn)(className, "base"), isConfirmMismatch && "input-error"), value: confirmPassword, onChange: (e) => {
|
|
58
58
|
setConfirmPassword(e.target.value);
|
|
59
59
|
onChange?.(password, e.target.value);
|
|
60
60
|
}, autoComplete: "off" }) })] }), isConfirmMismatch && ((0, jsx_runtime_1.jsx)("small", { className: "input-error-message", children: l.base.passwordConfirmFailed ? l.base.passwordConfirmFailed() : "Passwords do not match!" }))] }));
|
package/package.json
CHANGED
|
@@ -199,7 +199,7 @@ export function InputPasswordComponent({
|
|
|
199
199
|
strength === "excellent" && "password-strength-bar-excellent",
|
|
200
200
|
)}
|
|
201
201
|
/>
|
|
202
|
-
<span
|
|
202
|
+
{/* <span
|
|
203
203
|
className={cn(
|
|
204
204
|
"password-strength-text",
|
|
205
205
|
strength === "weak" && "password-strength-text-weak",
|
|
@@ -208,7 +208,7 @@ export function InputPasswordComponent({
|
|
|
208
208
|
)}
|
|
209
209
|
>
|
|
210
210
|
{strength === "weak" ? "Weak" : strength === "strong" ? "Strong" : "Excellent"}
|
|
211
|
-
</span>
|
|
211
|
+
</span> */}
|
|
212
212
|
</div>
|
|
213
213
|
)}
|
|
214
214
|
|