@hed-hog/core 0.0.297 → 0.0.299
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/dist/auth/auth.controller.d.ts +10 -10
- package/dist/auth/auth.service.d.ts +10 -10
- package/dist/dashboard/dashboard/dashboard.controller.d.ts +3 -0
- package/dist/dashboard/dashboard/dashboard.controller.d.ts.map +1 -1
- package/dist/dashboard/dashboard/dashboard.service.d.ts +3 -0
- package/dist/dashboard/dashboard/dashboard.service.d.ts.map +1 -1
- package/dist/dashboard/dashboard-component/dashboard-component.controller.d.ts +12 -0
- package/dist/dashboard/dashboard-component/dashboard-component.controller.d.ts.map +1 -1
- package/dist/dashboard/dashboard-component/dashboard-component.controller.js +22 -0
- package/dist/dashboard/dashboard-component/dashboard-component.controller.js.map +1 -1
- package/dist/dashboard/dashboard-component/dashboard-component.service.d.ts +15 -0
- package/dist/dashboard/dashboard-component/dashboard-component.service.d.ts.map +1 -1
- package/dist/dashboard/dashboard-component/dashboard-component.service.js +110 -3
- package/dist/dashboard/dashboard-component/dashboard-component.service.js.map +1 -1
- package/dist/dashboard/dashboard-component/dto/create.dto.d.ts +1 -0
- package/dist/dashboard/dashboard-component/dto/create.dto.d.ts.map +1 -1
- package/dist/dashboard/dashboard-component/dto/create.dto.js +5 -0
- package/dist/dashboard/dashboard-component/dto/create.dto.js.map +1 -1
- package/dist/dashboard/dashboard-component/dto/update.dto.d.ts +1 -0
- package/dist/dashboard/dashboard-component/dto/update.dto.d.ts.map +1 -1
- package/dist/dashboard/dashboard-component/dto/update.dto.js +5 -0
- package/dist/dashboard/dashboard-component/dto/update.dto.js.map +1 -1
- package/dist/dashboard/dashboard-component-role/dashboard-component-role.controller.d.ts +1 -0
- package/dist/dashboard/dashboard-component-role/dashboard-component-role.controller.d.ts.map +1 -1
- package/dist/dashboard/dashboard-component-role/dashboard-component-role.service.d.ts +1 -0
- package/dist/dashboard/dashboard-component-role/dashboard-component-role.service.d.ts.map +1 -1
- package/dist/dashboard/dashboard-core/dashboard-core.controller.d.ts +21 -1
- package/dist/dashboard/dashboard-core/dashboard-core.controller.d.ts.map +1 -1
- package/dist/dashboard/dashboard-core/dashboard-core.controller.js +9 -0
- package/dist/dashboard/dashboard-core/dashboard-core.controller.js.map +1 -1
- package/dist/dashboard/dashboard-core/dashboard-core.module.d.ts.map +1 -1
- package/dist/dashboard/dashboard-core/dashboard-core.module.js +6 -1
- package/dist/dashboard/dashboard-core/dashboard-core.module.js.map +1 -1
- package/dist/dashboard/dashboard-core/dashboard-core.service.d.ts +180 -2
- package/dist/dashboard/dashboard-core/dashboard-core.service.d.ts.map +1 -1
- package/dist/dashboard/dashboard-core/dashboard-core.service.js +619 -9
- package/dist/dashboard/dashboard-core/dashboard-core.service.js.map +1 -1
- package/dist/dashboard/dashboard-item/dashboard-item.controller.d.ts +1 -0
- package/dist/dashboard/dashboard-item/dashboard-item.controller.d.ts.map +1 -1
- package/dist/dashboard/dashboard-item/dashboard-item.service.d.ts +1 -0
- package/dist/dashboard/dashboard-item/dashboard-item.service.d.ts.map +1 -1
- package/dist/file/file.controller.d.ts.map +1 -1
- package/dist/file/file.controller.js +16 -0
- package/dist/file/file.controller.js.map +1 -1
- package/dist/file/file.service.d.ts +7 -1
- package/dist/file/file.service.d.ts.map +1 -1
- package/dist/file/file.service.js +38 -1
- package/dist/file/file.service.js.map +1 -1
- package/dist/file/provider/s3.provider.d.ts +1 -0
- package/dist/file/provider/s3.provider.d.ts.map +1 -1
- package/dist/file/provider/s3.provider.js +38 -29
- package/dist/file/provider/s3.provider.js.map +1 -1
- package/dist/oauth/oauth.service.d.ts.map +1 -1
- package/dist/oauth/oauth.service.js +2 -1
- package/dist/oauth/oauth.service.js.map +1 -1
- package/dist/user/constants/user.constants.d.ts +1 -0
- package/dist/user/constants/user.constants.d.ts.map +1 -1
- package/dist/user/constants/user.constants.js +2 -1
- package/dist/user/constants/user.constants.js.map +1 -1
- package/dist/user/user.controller.d.ts +10 -10
- package/dist/user/user.service.d.ts +30 -30
- package/dist/user/user.service.d.ts.map +1 -1
- package/dist/user/user.service.js +2 -1
- package/dist/user/user.service.js.map +1 -1
- package/hedhog/data/dashboard_item.yaml +10 -10
- package/hedhog/data/route.yaml +20 -0
- package/hedhog/frontend/app/dashboard/[slug]/dashboard-content.tsx.ejs +212 -34
- package/hedhog/frontend/app/dashboard/[slug]/types.ts.ejs +3 -0
- package/hedhog/frontend/app/dashboard/[slug]/widget-renderer.tsx.ejs +136 -23
- package/hedhog/frontend/app/dashboard/components/add-widget-selector-dialog.tsx.ejs +266 -85
- package/hedhog/frontend/app/dashboard/components/widgets/core..gitkeep.ejs +11 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.account-security.tsx.ejs +192 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.email-notifications.tsx.ejs +226 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.locale-config.tsx.ejs +168 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.mail-config.tsx.ejs +199 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.oauth-config.tsx.ejs +175 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.profile-card.tsx.ejs +186 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.storage-config.tsx.ejs +196 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.theme-config.tsx.ejs +213 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.user-roles.tsx.ejs +132 -0
- package/hedhog/frontend/app/dashboard/components/widgets/core.user-sessions.tsx.ejs +236 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.alerts.tsx.ejs +108 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.cash-balance-kpi.tsx.ejs +66 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.cash-flow-chart.tsx.ejs +122 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.default-kpi.tsx.ejs +63 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.payable-30d-kpi.tsx.ejs +73 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.receivable-30d-kpi.tsx.ejs +73 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.upcoming-payable.tsx.ejs +123 -0
- package/hedhog/frontend/app/dashboard/components/widgets/finance.upcoming-receivable.tsx.ejs +118 -0
- package/hedhog/frontend/messages/en.json +93 -0
- package/hedhog/frontend/messages/pt.json +93 -0
- package/hedhog/frontend/public/dashboard-previews/.gitkeep +12 -0
- package/hedhog/frontend/public/dashboard-previews/account-security.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/active-users-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/activity-timeline.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/cash-balance-kpi.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/cash-flow-chart.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/default-kpi.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/email-notifications.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/financial-alerts.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/login-history-chart.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/mail-sent-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/mail-sent-chart.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/menus-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/payable-30d-kpi.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/permissions-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/permissions-chart.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/profile-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/receivable-30d-kpi.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/routes-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/session-activity-chart.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/sessions-today-card.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/stat-access-level.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/stat-actions-today.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/stat-consecutive-days.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/stat-online-time.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/upcoming-payable.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/upcoming-receivable.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/user-growth-chart.png +0 -0
- package/hedhog/frontend/public/dashboard-previews/user-roles.png +0 -0
- package/hedhog/frontend/{app/dashboard/components/widgets → widgets}/account-security.tsx.ejs +33 -29
- package/hedhog/frontend/widgets/active-users-card.tsx.ejs +58 -0
- package/hedhog/frontend/widgets/activity-timeline.tsx.ejs +223 -0
- package/hedhog/frontend/{app/dashboard/components/widgets → widgets}/email-notifications.tsx.ejs +85 -61
- package/hedhog/frontend/widgets/locale-config.tsx.ejs +168 -0
- package/hedhog/frontend/widgets/login-history-chart.tsx.ejs +115 -0
- package/hedhog/frontend/widgets/mail-config.tsx.ejs +199 -0
- package/hedhog/frontend/widgets/mail-sent-card.tsx.ejs +58 -0
- package/hedhog/frontend/widgets/mail-sent-chart.tsx.ejs +149 -0
- package/hedhog/frontend/widgets/menus-card.tsx.ejs +58 -0
- package/hedhog/frontend/widgets/oauth-config.tsx.ejs +175 -0
- package/hedhog/frontend/widgets/permissions-card.tsx.ejs +61 -0
- package/hedhog/frontend/widgets/permissions-chart.tsx.ejs +156 -0
- package/hedhog/frontend/{app/dashboard/components/widgets → widgets}/profile-card.tsx.ejs +3 -3
- package/hedhog/frontend/widgets/routes-card.tsx.ejs +58 -0
- package/hedhog/frontend/widgets/session-activity-chart.tsx.ejs +183 -0
- package/hedhog/frontend/widgets/sessions-today-card.tsx.ejs +62 -0
- package/hedhog/frontend/widgets/stat-access-level.tsx.ejs +57 -0
- package/hedhog/frontend/widgets/stat-actions-today.tsx.ejs +57 -0
- package/hedhog/frontend/widgets/stat-consecutive-days.tsx.ejs +57 -0
- package/hedhog/frontend/widgets/stat-online-time.tsx.ejs +57 -0
- package/hedhog/frontend/widgets/storage-config.tsx.ejs +196 -0
- package/hedhog/frontend/widgets/theme-config.tsx.ejs +213 -0
- package/hedhog/frontend/widgets/user-growth-chart.tsx.ejs +210 -0
- package/hedhog/frontend/{app/dashboard/components/widgets → widgets}/user-roles.tsx.ejs +12 -14
- package/hedhog/frontend/{app/dashboard/components/widgets → widgets}/user-sessions.tsx.ejs +1 -1
- package/hedhog/table/dashboard_component.yaml +7 -0
- package/hedhog/table/mail_sent_user.yaml +75 -0
- package/package.json +4 -4
- package/src/dashboard/dashboard-component/dashboard-component.controller.ts +36 -12
- package/src/dashboard/dashboard-component/dashboard-component.service.ts +150 -3
- package/src/dashboard/dashboard-component/dto/create.dto.ts +4 -0
- package/src/dashboard/dashboard-component/dto/update.dto.ts +4 -0
- package/src/dashboard/dashboard-core/dashboard-core.controller.ts +5 -0
- package/src/dashboard/dashboard-core/dashboard-core.module.ts +6 -1
- package/src/dashboard/dashboard-core/dashboard-core.service.ts +874 -8
- package/src/file/file.controller.ts +37 -13
- package/src/file/file.service.ts +47 -5
- package/src/file/provider/s3.provider.ts +39 -29
- package/src/oauth/oauth.service.ts +8 -7
- package/src/user/constants/user.constants.ts +1 -0
- package/src/user/user.service.ts +2 -1
- package/hedhog/frontend/app/dashboard/components/widgets/locale-config.tsx.ejs +0 -309
- package/hedhog/frontend/app/dashboard/components/widgets/mail-config.tsx.ejs +0 -445
- package/hedhog/frontend/app/dashboard/components/widgets/oauth-config.tsx.ejs +0 -296
- package/hedhog/frontend/app/dashboard/components/widgets/storage-config.tsx.ejs +0 -340
- package/hedhog/frontend/app/dashboard/components/widgets/theme-config.tsx.ejs +0 -275
- /package/hedhog/frontend/app/dashboard/components/widgets/{active-users-card.tsx.ejs → core.active-users-card.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{activity-timeline.tsx.ejs → core.activity-timeline.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{login-history-chart.tsx.ejs → core.login-history-chart.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{mail-sent-card.tsx.ejs → core.mail-sent-card.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{mail-sent-chart.tsx.ejs → core.mail-sent-chart.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{menus-card.tsx.ejs → core.menus-card.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{permissions-card.tsx.ejs → core.permissions-card.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{permissions-chart.tsx.ejs → core.permissions-chart.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{routes-card.tsx.ejs → core.routes-card.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{session-activity-chart.tsx.ejs → core.session-activity-chart.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{sessions-today-card.tsx.ejs → core.sessions-today-card.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{stat-access-level.tsx.ejs → core.stat-access-level.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{stat-actions-today.tsx.ejs → core.stat-actions-today.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{stat-consecutive-days.tsx.ejs → core.stat-consecutive-days.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{stat-online-time.tsx.ejs → core.stat-online-time.tsx.ejs} +0 -0
- /package/hedhog/frontend/app/dashboard/components/widgets/{user-growth-chart.tsx.ejs → core.user-growth-chart.tsx.ejs} +0 -0
|
@@ -904,10 +904,13 @@
|
|
|
904
904
|
"AddWidgetDialog": {
|
|
905
905
|
"title": "Select Dashboard Components",
|
|
906
906
|
"description": "Choose the components you want to display on your dashboard.",
|
|
907
|
+
"selectedOfTotal": "{selected} selected of {total}",
|
|
907
908
|
"noComponentsAvailable": "No components available at the moment.",
|
|
908
909
|
"dimensions": "Dimensions",
|
|
909
910
|
"resizable": "Resizable",
|
|
910
911
|
"fixedSize": "Fixed size",
|
|
912
|
+
"select": "Select",
|
|
913
|
+
"selected": "Selected",
|
|
911
914
|
"cancel": "Cancel",
|
|
912
915
|
"add": "Add"
|
|
913
916
|
},
|
|
@@ -1026,6 +1029,96 @@
|
|
|
1026
1029
|
"hoursAgo": "{count}h ago",
|
|
1027
1030
|
"daysAgo": "{count} day ago",
|
|
1028
1031
|
"daysAgoPlural": "{count} days ago"
|
|
1032
|
+
},
|
|
1033
|
+
"emailNotifications": {
|
|
1034
|
+
"title": "Email Notifications",
|
|
1035
|
+
"description": "System email flow in the last 14 days",
|
|
1036
|
+
"received": "Received",
|
|
1037
|
+
"read": "Read",
|
|
1038
|
+
"unread": "Unread",
|
|
1039
|
+
"error": "Error",
|
|
1040
|
+
"receivedShort": "Recv.",
|
|
1041
|
+
"readShort": "Read",
|
|
1042
|
+
"unreadShort": "Unrd.",
|
|
1043
|
+
"errorShort": "Err."
|
|
1044
|
+
},
|
|
1045
|
+
"localeConfig": {
|
|
1046
|
+
"title": "Localization",
|
|
1047
|
+
"description": "Locale and regional format summary",
|
|
1048
|
+
"configured": "Configured",
|
|
1049
|
+
"pending": "Pending",
|
|
1050
|
+
"enabled": "Enabled",
|
|
1051
|
+
"disabled": "Disabled",
|
|
1052
|
+
"total": "Total",
|
|
1053
|
+
"timezone": "Timezone",
|
|
1054
|
+
"dateFormat": "Date format",
|
|
1055
|
+
"timeFormat": "Time format",
|
|
1056
|
+
"enabledLocales": "Enabled locales",
|
|
1057
|
+
"noneEnabled": "No locale enabled",
|
|
1058
|
+
"notSet": "Not set"
|
|
1059
|
+
},
|
|
1060
|
+
"mailConfig": {
|
|
1061
|
+
"title": "Mail Configuration",
|
|
1062
|
+
"description": "Provider and delivery overview",
|
|
1063
|
+
"configured": "Configured",
|
|
1064
|
+
"pending": "Pending",
|
|
1065
|
+
"templates": "Templates",
|
|
1066
|
+
"sentTotal": "Sent total",
|
|
1067
|
+
"sent30Days": "Sent (30d)",
|
|
1068
|
+
"sender": "Default sender",
|
|
1069
|
+
"providers": "Providers",
|
|
1070
|
+
"selectedProvider": "Selected: {provider}",
|
|
1071
|
+
"selected": "Selected",
|
|
1072
|
+
"missingKeys": "Missing keys: {count}",
|
|
1073
|
+
"allKeysPresent": "All required keys present",
|
|
1074
|
+
"noProviders": "No providers found",
|
|
1075
|
+
"none": "None",
|
|
1076
|
+
"notSet": "Not set"
|
|
1077
|
+
},
|
|
1078
|
+
"oauthConfig": {
|
|
1079
|
+
"title": "OAuth Providers",
|
|
1080
|
+
"description": "Social login readiness summary",
|
|
1081
|
+
"configured": "Configured",
|
|
1082
|
+
"pending": "Pending",
|
|
1083
|
+
"enabled": "Enabled",
|
|
1084
|
+
"disabled": "Disabled",
|
|
1085
|
+
"configuredProviders": "Configured",
|
|
1086
|
+
"connectedAccounts": "Connected",
|
|
1087
|
+
"scopesCount": "Scopes: {count}",
|
|
1088
|
+
"connectedUsers": "Users: {count}",
|
|
1089
|
+
"missingKeys": "Missing keys: {count}",
|
|
1090
|
+
"allKeysPresent": "All required keys present",
|
|
1091
|
+
"noProviders": "No providers found"
|
|
1092
|
+
},
|
|
1093
|
+
"storageConfig": {
|
|
1094
|
+
"title": "Storage Profiles",
|
|
1095
|
+
"description": "Active providers and profile health",
|
|
1096
|
+
"configured": "Configured",
|
|
1097
|
+
"pending": "Pending",
|
|
1098
|
+
"profiles": "Profiles",
|
|
1099
|
+
"active": "Active",
|
|
1100
|
+
"providers": "Providers",
|
|
1101
|
+
"defaultProfile": "Default profile",
|
|
1102
|
+
"defaults": "defaults",
|
|
1103
|
+
"providerSummary": "{active} active of {total}",
|
|
1104
|
+
"defaultTag": "Default",
|
|
1105
|
+
"inactive": "Inactive",
|
|
1106
|
+
"noProfiles": "No profiles found",
|
|
1107
|
+
"notSet": "Not set"
|
|
1108
|
+
},
|
|
1109
|
+
"themeConfig": {
|
|
1110
|
+
"title": "Theme and Branding",
|
|
1111
|
+
"description": "Visual identity configuration snapshot",
|
|
1112
|
+
"configured": "Configured",
|
|
1113
|
+
"pending": "Pending",
|
|
1114
|
+
"tokens": "Tokens",
|
|
1115
|
+
"font": "Font",
|
|
1116
|
+
"textSize": "Text size",
|
|
1117
|
+
"radius": "Radius",
|
|
1118
|
+
"lightPalette": "Light palette",
|
|
1119
|
+
"darkPalette": "Dark palette",
|
|
1120
|
+
"primary": "Primary",
|
|
1121
|
+
"notSet": "Not set"
|
|
1029
1122
|
}
|
|
1030
1123
|
},
|
|
1031
1124
|
"HomePage": {
|
|
@@ -907,10 +907,13 @@
|
|
|
907
907
|
"AddWidgetDialog": {
|
|
908
908
|
"title": "Selecionar Componentes do Dashboard",
|
|
909
909
|
"description": "Escolha os componentes que deseja exibir no seu dashboard.",
|
|
910
|
+
"selectedOfTotal": "{selected} selecionados de {total}",
|
|
910
911
|
"noComponentsAvailable": "Nenhum componente disponível no momento.",
|
|
911
912
|
"dimensions": "Dimensões",
|
|
912
913
|
"resizable": "Redimensionável",
|
|
913
914
|
"fixedSize": "Tamanho fixo",
|
|
915
|
+
"select": "Selecionar",
|
|
916
|
+
"selected": "Selecionado",
|
|
914
917
|
"cancel": "Cancelar",
|
|
915
918
|
"add": "Adicionar"
|
|
916
919
|
},
|
|
@@ -1031,6 +1034,96 @@
|
|
|
1031
1034
|
"hoursAgo": "{count}h atrás",
|
|
1032
1035
|
"daysAgo": "{count} dia atrás",
|
|
1033
1036
|
"daysAgoPlural": "{count} dias atrás"
|
|
1037
|
+
},
|
|
1038
|
+
"emailNotifications": {
|
|
1039
|
+
"title": "Notificações por E-mail",
|
|
1040
|
+
"description": "Fluxo de e-mails do sistema nos últimos 14 dias",
|
|
1041
|
+
"received": "Recebidos",
|
|
1042
|
+
"read": "Lidos",
|
|
1043
|
+
"unread": "Não lidos",
|
|
1044
|
+
"error": "Com erro",
|
|
1045
|
+
"receivedShort": "Rec.",
|
|
1046
|
+
"readShort": "Lid.",
|
|
1047
|
+
"unreadShort": "N. lid.",
|
|
1048
|
+
"errorShort": "Erro"
|
|
1049
|
+
},
|
|
1050
|
+
"localeConfig": {
|
|
1051
|
+
"title": "Localização",
|
|
1052
|
+
"description": "Resumo de idiomas e formatos regionais",
|
|
1053
|
+
"configured": "Configurado",
|
|
1054
|
+
"pending": "Pendente",
|
|
1055
|
+
"enabled": "Ativos",
|
|
1056
|
+
"disabled": "Inativos",
|
|
1057
|
+
"total": "Total",
|
|
1058
|
+
"timezone": "Fuso horário",
|
|
1059
|
+
"dateFormat": "Formato de data",
|
|
1060
|
+
"timeFormat": "Formato de hora",
|
|
1061
|
+
"enabledLocales": "Idiomas ativos",
|
|
1062
|
+
"noneEnabled": "Nenhum idioma ativo",
|
|
1063
|
+
"notSet": "Não definido"
|
|
1064
|
+
},
|
|
1065
|
+
"mailConfig": {
|
|
1066
|
+
"title": "Configuração de E-mail",
|
|
1067
|
+
"description": "Resumo de provedor e entrega",
|
|
1068
|
+
"configured": "Configurado",
|
|
1069
|
+
"pending": "Pendente",
|
|
1070
|
+
"templates": "Templates",
|
|
1071
|
+
"sentTotal": "Enviados total",
|
|
1072
|
+
"sent30Days": "Enviados (30d)",
|
|
1073
|
+
"sender": "Remetente padrão",
|
|
1074
|
+
"providers": "Provedores",
|
|
1075
|
+
"selectedProvider": "Selecionado: {provider}",
|
|
1076
|
+
"selected": "Selecionado",
|
|
1077
|
+
"missingKeys": "Chaves pendentes: {count}",
|
|
1078
|
+
"allKeysPresent": "Todas as chaves obrigatórias presentes",
|
|
1079
|
+
"noProviders": "Nenhum provedor encontrado",
|
|
1080
|
+
"none": "Nenhum",
|
|
1081
|
+
"notSet": "Não definido"
|
|
1082
|
+
},
|
|
1083
|
+
"oauthConfig": {
|
|
1084
|
+
"title": "Provedores OAuth",
|
|
1085
|
+
"description": "Resumo de prontidão para login social",
|
|
1086
|
+
"configured": "Configurado",
|
|
1087
|
+
"pending": "Pendente",
|
|
1088
|
+
"enabled": "Ativo",
|
|
1089
|
+
"disabled": "Inativo",
|
|
1090
|
+
"configuredProviders": "Configurados",
|
|
1091
|
+
"connectedAccounts": "Conectadas",
|
|
1092
|
+
"scopesCount": "Escopos: {count}",
|
|
1093
|
+
"connectedUsers": "Usuários: {count}",
|
|
1094
|
+
"missingKeys": "Chaves pendentes: {count}",
|
|
1095
|
+
"allKeysPresent": "Todas as chaves obrigatórias presentes",
|
|
1096
|
+
"noProviders": "Nenhum provedor encontrado"
|
|
1097
|
+
},
|
|
1098
|
+
"storageConfig": {
|
|
1099
|
+
"title": "Perfis de Armazenamento",
|
|
1100
|
+
"description": "Provedores ativos e saúde dos perfis",
|
|
1101
|
+
"configured": "Configurado",
|
|
1102
|
+
"pending": "Pendente",
|
|
1103
|
+
"profiles": "Perfis",
|
|
1104
|
+
"active": "Ativos",
|
|
1105
|
+
"providers": "Provedores",
|
|
1106
|
+
"defaultProfile": "Perfil padrão",
|
|
1107
|
+
"defaults": "padrões",
|
|
1108
|
+
"providerSummary": "{active} ativos de {total}",
|
|
1109
|
+
"defaultTag": "Padrão",
|
|
1110
|
+
"inactive": "Inativo",
|
|
1111
|
+
"noProfiles": "Nenhum perfil encontrado",
|
|
1112
|
+
"notSet": "Não definido"
|
|
1113
|
+
},
|
|
1114
|
+
"themeConfig": {
|
|
1115
|
+
"title": "Tema e Identidade",
|
|
1116
|
+
"description": "Resumo da configuração visual do sistema",
|
|
1117
|
+
"configured": "Configurado",
|
|
1118
|
+
"pending": "Pendente",
|
|
1119
|
+
"tokens": "Tokens",
|
|
1120
|
+
"font": "Fonte",
|
|
1121
|
+
"textSize": "Tamanho do texto",
|
|
1122
|
+
"radius": "Raio",
|
|
1123
|
+
"lightPalette": "Paleta clara",
|
|
1124
|
+
"darkPalette": "Paleta escura",
|
|
1125
|
+
"primary": "Primária",
|
|
1126
|
+
"notSet": "Não definido"
|
|
1034
1127
|
}
|
|
1035
1128
|
},
|
|
1036
1129
|
"HomePage": {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# Dashboard Widget Previews
|
|
2
|
+
#
|
|
3
|
+
# Place one .webp file per dashboard component, named exactly by the component slug.
|
|
4
|
+
# Example: active-users-card.webp, user-sessions.webp
|
|
5
|
+
#
|
|
6
|
+
# These files are copied by `hedhog add` / `hedhog dev apply` to:
|
|
7
|
+
# apps/admin/public/libraries/core/dashboard-previews/<slug>.webp
|
|
8
|
+
#
|
|
9
|
+
# The admin selector loads them as:
|
|
10
|
+
# /libraries/core/dashboard-previews/<slug>.webp
|
|
11
|
+
#
|
|
12
|
+
# If a file is missing, the selector card falls back gracefully (image hidden).
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/hedhog/frontend/{app/dashboard/components/widgets → widgets}/account-security.tsx.ejs
RENAMED
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
|
|
3
|
-
import { Button } from '@/components/ui/button';
|
|
4
2
|
import {
|
|
5
3
|
Card,
|
|
6
4
|
CardContent,
|
|
@@ -34,6 +32,13 @@ const ICON_MAP: Record<string, React.ElementType> = {
|
|
|
34
32
|
sessions: AlertTriangle,
|
|
35
33
|
};
|
|
36
34
|
|
|
35
|
+
const CHECK_ROUTE_MAP: Record<string, string> = {
|
|
36
|
+
password: '/core/account/password',
|
|
37
|
+
'2fa': '/core/account/2fa',
|
|
38
|
+
email: '/core/account/email',
|
|
39
|
+
sessions: '/core/account/sessions',
|
|
40
|
+
};
|
|
41
|
+
|
|
37
42
|
function AccountSecurityContent({ data }: { data: AccountSecurityData }) {
|
|
38
43
|
const t = useTranslations('core.DashboardPage.accountSecurity');
|
|
39
44
|
const router = useRouter();
|
|
@@ -60,60 +65,66 @@ function AccountSecurityContent({ data }: { data: AccountSecurityData }) {
|
|
|
60
65
|
|
|
61
66
|
return (
|
|
62
67
|
<Card className="flex h-full min-h-0 flex-col overflow-hidden">
|
|
63
|
-
<CardHeader className="shrink-0 pb-
|
|
68
|
+
<CardHeader className="shrink-0 px-4 pb-2 pt-4 sm:px-5">
|
|
64
69
|
<div className="flex items-center gap-2">
|
|
65
70
|
<ShieldCheck className="h-5 w-5 text-emerald-600 dark:text-emerald-400" />
|
|
66
71
|
<div>
|
|
67
72
|
<CardTitle className="text-base font-semibold">
|
|
68
73
|
{t('title')}
|
|
69
74
|
</CardTitle>
|
|
70
|
-
<CardDescription>
|
|
75
|
+
<CardDescription className="text-xs sm:text-sm">
|
|
76
|
+
{t('description')}
|
|
77
|
+
</CardDescription>
|
|
71
78
|
</div>
|
|
72
79
|
</div>
|
|
73
80
|
</CardHeader>
|
|
74
|
-
<CardContent className="flex min-h-0 flex-1 flex-col overflow-auto pt-0">
|
|
75
|
-
<div className="mb-
|
|
81
|
+
<CardContent className="flex min-h-0 flex-1 flex-col overflow-auto px-4 pb-3 pt-0 sm:px-5 sm:pb-4">
|
|
82
|
+
<div className="mb-2 flex flex-col items-center gap-1.5 rounded-xl bg-muted/50 p-2 sm:mb-3 sm:gap-2 sm:p-3">
|
|
76
83
|
<div className="flex items-baseline gap-1">
|
|
77
84
|
<span
|
|
78
|
-
className={`text-
|
|
85
|
+
className={`text-2xl font-bold tracking-tight sm:text-3xl ${scoreColor}`}
|
|
79
86
|
>
|
|
80
87
|
{score}
|
|
81
88
|
</span>
|
|
82
|
-
<span className="text-
|
|
89
|
+
<span className="text-xs text-muted-foreground sm:text-sm">
|
|
83
90
|
/100
|
|
84
91
|
</span>
|
|
85
92
|
</div>
|
|
86
93
|
<Progress
|
|
87
94
|
value={score}
|
|
88
|
-
className="h-
|
|
95
|
+
className="h-1.5 w-full max-w-70"
|
|
89
96
|
style={
|
|
90
97
|
{
|
|
91
98
|
'--progress-foreground': progressColor,
|
|
92
99
|
} as any
|
|
93
100
|
}
|
|
94
101
|
/>
|
|
95
|
-
<p className="text-[
|
|
102
|
+
<p className="text-[10px] text-muted-foreground sm:text-[11px]">
|
|
96
103
|
{score >= 80 ? t('wellProtected') : t('recommendProtections')}
|
|
97
104
|
</p>
|
|
98
105
|
</div>
|
|
99
106
|
|
|
100
|
-
<div className="flex flex-col gap-1
|
|
107
|
+
<div className="flex flex-col gap-1">
|
|
101
108
|
{data.checks.map((item) => {
|
|
102
109
|
const Icon = ICON_MAP[item.id] ?? ShieldCheck;
|
|
103
110
|
return (
|
|
104
|
-
<
|
|
111
|
+
<button
|
|
112
|
+
type="button"
|
|
105
113
|
key={item.id}
|
|
106
|
-
|
|
114
|
+
onClick={() =>
|
|
115
|
+
router.push(CHECK_ROUTE_MAP[item.id] ?? '/core/account')
|
|
116
|
+
}
|
|
117
|
+
className="group flex w-full cursor-pointer flex-wrap items-start gap-2 rounded-lg p-2 text-left transition-colors hover:bg-muted/50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring sm:items-center sm:gap-2.5 sm:p-2.5"
|
|
107
118
|
>
|
|
108
119
|
<div
|
|
109
|
-
className={`flex h-
|
|
120
|
+
className={`flex h-7 w-7 shrink-0 items-center justify-center rounded-lg sm:h-8 sm:w-8 ${
|
|
110
121
|
item.enabled
|
|
111
122
|
? 'bg-emerald-50 dark:bg-emerald-950/40'
|
|
112
123
|
: 'bg-muted'
|
|
113
124
|
}`}
|
|
114
125
|
>
|
|
115
126
|
<Icon
|
|
116
|
-
className={`h-3.5 w-3.5
|
|
127
|
+
className={`h-3.5 w-3.5 ${
|
|
117
128
|
item.enabled
|
|
118
129
|
? 'text-emerald-600 dark:text-emerald-400'
|
|
119
130
|
: 'text-muted-foreground'
|
|
@@ -122,7 +133,7 @@ function AccountSecurityContent({ data }: { data: AccountSecurityData }) {
|
|
|
122
133
|
</div>
|
|
123
134
|
<div className="flex min-w-0 flex-1 flex-col">
|
|
124
135
|
<div className="flex flex-wrap items-center gap-2">
|
|
125
|
-
<span className="wrap-break-word text-[
|
|
136
|
+
<span className="wrap-break-word text-[12px] font-medium text-foreground sm:text-[13px]">
|
|
126
137
|
{t(`labels.${item.labelKey}` as any) || item.labelKey}
|
|
127
138
|
</span>
|
|
128
139
|
{item.enabled ? (
|
|
@@ -131,23 +142,16 @@ function AccountSecurityContent({ data }: { data: AccountSecurityData }) {
|
|
|
131
142
|
<AlertTriangle className="h-3.5 w-3.5 text-amber-500" />
|
|
132
143
|
)}
|
|
133
144
|
</div>
|
|
134
|
-
<span className="text-[
|
|
145
|
+
<span className="text-[10px] text-muted-foreground sm:text-[11px]">
|
|
135
146
|
{t(`descriptions.${item.descriptionKey}` as any) ||
|
|
136
147
|
item.descriptionKey}
|
|
137
148
|
</span>
|
|
138
149
|
</div>
|
|
139
|
-
|
|
140
|
-
<
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
className="mt-1 w-full shrink-0 gap-1 text-xs sm:mt-0 sm:w-auto"
|
|
145
|
-
>
|
|
146
|
-
{t('activate')}
|
|
147
|
-
<ChevronRight className="h-3 w-3" />
|
|
148
|
-
</Button>
|
|
149
|
-
)}
|
|
150
|
-
</div>
|
|
150
|
+
<div className="mt-0.5 flex w-full shrink-0 items-center justify-end gap-1 text-[11px] font-medium text-foreground sm:mt-0 sm:w-auto sm:text-xs">
|
|
151
|
+
{!item.enabled && <span>{t('activate')}</span>}
|
|
152
|
+
<ChevronRight className="h-3 w-3" />
|
|
153
|
+
</div>
|
|
154
|
+
</button>
|
|
151
155
|
);
|
|
152
156
|
})}
|
|
153
157
|
</div>
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { useWidgetData } from '@/hooks/use-widget-data';
|
|
2
|
+
import { Users } from 'lucide-react';
|
|
3
|
+
import { useTranslations } from 'next-intl';
|
|
4
|
+
import StatCard from '../stats';
|
|
5
|
+
import { WidgetWrapper } from '../widget-wrapper';
|
|
6
|
+
|
|
7
|
+
interface ActiveUsersProps {
|
|
8
|
+
widget?: any;
|
|
9
|
+
onRemove?: () => void;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
interface UserStatsData {
|
|
13
|
+
cards?: {
|
|
14
|
+
activeUsers?: {
|
|
15
|
+
value: number;
|
|
16
|
+
change: number | null;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export default function ActiveUsers({ widget, onRemove }: ActiveUsersProps) {
|
|
22
|
+
const t = useTranslations('core.Dashboard');
|
|
23
|
+
|
|
24
|
+
const { data, isLoading, isAccessDenied, isError } =
|
|
25
|
+
useWidgetData<UserStatsData>({
|
|
26
|
+
endpoint: '/dashboard-core/stats/overview/users',
|
|
27
|
+
queryKey: 'dashboard-stats-users',
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
const value = data?.cards?.activeUsers?.value?.toLocaleString('pt-BR') || '0';
|
|
31
|
+
const change = data?.cards?.activeUsers?.change;
|
|
32
|
+
const changeType =
|
|
33
|
+
change !== null && change !== undefined && change >= 0 ? 'up' : 'down';
|
|
34
|
+
|
|
35
|
+
return (
|
|
36
|
+
<WidgetWrapper
|
|
37
|
+
isLoading={isLoading}
|
|
38
|
+
isAccessDenied={isAccessDenied}
|
|
39
|
+
isError={isError}
|
|
40
|
+
widgetName={widget?.name || t('activeUsers')}
|
|
41
|
+
onRemove={onRemove}
|
|
42
|
+
>
|
|
43
|
+
<StatCard
|
|
44
|
+
title={t('activeUsers')}
|
|
45
|
+
value={value}
|
|
46
|
+
change={
|
|
47
|
+
change !== null && change !== undefined
|
|
48
|
+
? `${change > 0 ? '+' : ''}${change}%`
|
|
49
|
+
: undefined
|
|
50
|
+
}
|
|
51
|
+
changeType={changeType}
|
|
52
|
+
icon={<Users className="h-6 w-6 text-blue-500" />}
|
|
53
|
+
iconBg="bg-blue-500/10"
|
|
54
|
+
delay={50}
|
|
55
|
+
/>
|
|
56
|
+
</WidgetWrapper>
|
|
57
|
+
);
|
|
58
|
+
}
|