From d957ceef6d333567eb1e22dbb119c1c858e6375d Mon Sep 17 00:00:00 2001 From: samaradel Date: Wed, 26 Jun 2024 17:00:32 +0300 Subject: [PATCH] - Remove password input wrapper - Create prepend inner icon for inputs with type password - Fix show/hide icon selection when press tab - Fix the order of dialog actions tabindex --- .../src/components/password_input_wrapper.vue | 15 - packages/playground/src/config.ts | 2 - .../playground/src/global-components.d.ts | 2 - .../src/hooks/use_password_input.ts | 11 - .../src/weblets/profile_manager.vue | 271 ++++++++++-------- 5 files changed, 145 insertions(+), 156 deletions(-) delete mode 100644 packages/playground/src/components/password_input_wrapper.vue delete mode 100644 packages/playground/src/hooks/use_password_input.ts diff --git a/packages/playground/src/components/password_input_wrapper.vue b/packages/playground/src/components/password_input_wrapper.vue deleted file mode 100644 index 3f1c56b0dc..0000000000 --- a/packages/playground/src/components/password_input_wrapper.vue +++ /dev/null @@ -1,15 +0,0 @@ - - - - - diff --git a/packages/playground/src/config.ts b/packages/playground/src/config.ts index 0a9c9201e5..695333c8f8 100644 --- a/packages/playground/src/config.ts +++ b/packages/playground/src/config.ts @@ -10,12 +10,10 @@ import InputValidator from "./components/input_validator.vue"; import TfSelectCountry from "./components/node_selector/select_location_internals/TfSelectCountry.vue"; import TfSelectRegion from "./components/node_selector/select_location_internals/TfSelectRegion.vue"; import TfSelectionDetails from "./components/node_selector/TfSelectionDetails.vue"; -import PasswordInputWrapper from "./components/password_input_wrapper.vue"; import ViewLayout from "./components/view_layout.vue"; import WebletLayout from "./components/weblet_layout.vue"; import * as validators from "./utils/validators"; const GLOBAL_COMPONENTS: { [key: string]: Component } = { - PasswordInputWrapper, WebletLayout, CopyInputWrapper, DTabs, diff --git a/packages/playground/src/global-components.d.ts b/packages/playground/src/global-components.d.ts index 44f7ab4b49..d94858a2b2 100644 --- a/packages/playground/src/global-components.d.ts +++ b/packages/playground/src/global-components.d.ts @@ -9,13 +9,11 @@ import InputValidator from "./components/input_validator.vue"; import TfSelectCountry from "./components/node_selector/select_location_internals/TfSelectCountry.vue"; import TfSelectRegion from "./components/node_selector/select_location_internals/TfSelectRegion.vue"; import TfSelectionDetails from "./components/node_selector/TfSelectionDetails.vue"; -import PasswordInputWrapper from "./components/password_input_wrapper.vue"; import ViewLayout from "./components/view_layout.vue"; import WebletLayout from "./components/weblet_layout.vue"; import type * as validators from "./utils/validators"; declare module "@vue/runtime-core" { export interface GlobalComponents { - PasswordInputWrapper: typeof PasswordInputWrapper; WebletLayout: typeof WebletLayout; CopyInputWrapper: typeof CopyInputWrapper; DTabs: typeof DTabs; diff --git a/packages/playground/src/hooks/use_password_input.ts b/packages/playground/src/hooks/use_password_input.ts deleted file mode 100644 index a060fac2c3..0000000000 --- a/packages/playground/src/hooks/use_password_input.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { computed, reactive, ref } from "vue"; - -export function usePasswordInput(defaultShow = false) { - const show = ref(defaultShow); - - return reactive({ - type: computed(() => (show.value ? "text" : "password")), - "append-inner-icon": computed(() => (show.value ? "mdi-eye-outline" : "mdi-eye-off-outline")), - "onClick:append-inner": () => (show.value = !show.value), - }); -} diff --git a/packages/playground/src/weblets/profile_manager.vue b/packages/playground/src/weblets/profile_manager.vue index 2c36454672..5cdfdcb654 100644 --- a/packages/playground/src/weblets/profile_manager.vue +++ b/packages/playground/src/weblets/profile_manager.vue @@ -117,87 +117,90 @@ > + + + + + - - - + + + {{ loginError }} @@ -319,11 +332,14 @@
- Close + + Close +