From 47ed805ac7e83b685683d94c0afd1935d96c04e1 Mon Sep 17 00:00:00 2001 From: Ruslan Bakiev <572431+veikab@users.noreply.github.com> Date: Mon, 23 Feb 2026 11:15:29 +0700 Subject: [PATCH] refactor(frontend): extract auth and topbar workspace components --- .../components/workspace/CrmWorkspaceApp.vue | 137 ++++-------------- .../workspace/auth/CrmAuthLoading.vue | 5 + .../workspace/auth/CrmAuthLoginForm.vue | 47 ++++++ .../workspace/header/CrmWorkspaceTopbar.vue | 100 +++++++++++++ 4 files changed, 181 insertions(+), 108 deletions(-) create mode 100644 frontend/app/components/workspace/auth/CrmAuthLoading.vue create mode 100644 frontend/app/components/workspace/auth/CrmAuthLoginForm.vue create mode 100644 frontend/app/components/workspace/header/CrmWorkspaceTopbar.vue diff --git a/frontend/app/components/workspace/CrmWorkspaceApp.vue b/frontend/app/components/workspace/CrmWorkspaceApp.vue index 0efc8c4..7ffdaf9 100644 --- a/frontend/app/components/workspace/CrmWorkspaceApp.vue +++ b/frontend/app/components/workspace/CrmWorkspaceApp.vue @@ -1,5 +1,8 @@ + + + + + + Login + Sign in with phone and password. + + + + {{ props.error }} + + {{ props.busy ? "Logging in..." : "Login" }} + + + + + + diff --git a/frontend/app/components/workspace/header/CrmWorkspaceTopbar.vue b/frontend/app/components/workspace/header/CrmWorkspaceTopbar.vue new file mode 100644 index 0000000..94a2032 --- /dev/null +++ b/frontend/app/components/workspace/header/CrmWorkspaceTopbar.vue @@ -0,0 +1,100 @@ + + + + + + + + Contacts + + + Calendar + + + Documents + + + + + + + + {{ props.authInitials }} + + + {{ props.authDisplayName }} + + + + {{ props.authDisplayName }} + Settings + + + + + Telegram Business + {{ props.telegramStatusLabel }} + + + {{ props.telegramConnectBusy ? "Connecting..." : "Connect Telegram" }} + + + {{ props.telegramConnectNotice }} + + + + + Logout + + + + + +
Sign in with phone and password.
{{ props.error }}
{{ props.authDisplayName }}
Settings
+ {{ props.telegramConnectNotice }} +