Edit-mode now shows the previously selected KYC document type + uploaded file thumbnail
(loads from /clients/{id}/identifiers + /client_identifiers/{id}/documents). Same for
address proof on the India address step. Closes the gap where editing a client showed
an empty file picker even when proof had been uploaded on create.
Identifier-save hardened across all three callsites (create-client, edit-client,
identities-tab.createIdentifierWithDocs) - the KYC chip picker proofId is a CODE
string ('AADHAAR'), but backend ClientIdentifierRequest.documentTypeId is Long, which
Spring rejects with HttpMessageNotReadableException -> 400. resolveDocumentTypeId
helper looks up the code against /kyc/proof-types?type=id and substitutes the numeric
CodeValue id before posting. Skips silently for constitution-specific non-individual
docs that have no CodeValue mapping.
KYC payload normalises panNumber / enterprisePan / gstinNumber / cinNumber via
toUpperCase + whitespace strip so user-typed lowercase or trailing spaces don't trip
the backend regex (validation.msg.CLIENTKYC.panNumber.does.not.match.regexp).
State name match in client-address save now normalises both sides (lowercase, collapse
underscores + spaces) so legacy MADHYA_PRADESH resolves to 'Madhya Pradesh' returned
by api.postalpincode.in. Backed by tenant migration 0297.
Identities-tab resolver flattened - was returning identifiers before the per-row
forkJoin(getClientIdentificationDocuments) completed, so the view rendered empty
documents arrays. Now uses switchMap + forkJoin so the resolver awaits completion.
Also bundles concurrent work-in-progress on letter-mgmt, organization, users,
bank-calendar, shell, nominee/notes/identifier dialogs, and theming.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
610 lines
11 KiB
SCSS
610 lines
11 KiB
SCSS
/**
|
|
* Copyright since 2025 Mifos Initiative
|
|
*
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
*/
|
|
|
|
:host {
|
|
--dsd-blue: #1d4ed8;
|
|
--dsd-blue-d: #1e40af;
|
|
--dsd-blue-l: #eff6ff;
|
|
--dsd-blue-tint: #dbeafe;
|
|
--dsd-green: #15803d;
|
|
--dsd-green-l: #dcfce7;
|
|
--dsd-amber: #d97706;
|
|
--dsd-amber-l: #fef3c7;
|
|
--dsd-red: #b91c1c;
|
|
--dsd-red-l: #fee2e2;
|
|
--dsd-red-tint: #fecaca;
|
|
--dsd-purple: #6d28d9;
|
|
--dsd-purple-l: #ede9fe;
|
|
--dsd-g50: #f8fafc;
|
|
--dsd-g100: #f1f5f9;
|
|
--dsd-g200: #e2e8f0;
|
|
--dsd-g300: #cbd5e1;
|
|
--dsd-g500: #64748b;
|
|
--dsd-g700: #334155;
|
|
--dsd-g900: #0f172a;
|
|
|
|
display: block;
|
|
}
|
|
|
|
.dsd-root {
|
|
background: #fff;
|
|
padding: 16px 20px 18px;
|
|
width: 100%;
|
|
max-width: 580px;
|
|
max-height: 90vh;
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 16px;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.mono {
|
|
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
}
|
|
|
|
/* ───────── Header ───────── */
|
|
.dsd-head {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
gap: 14px;
|
|
padding-bottom: 12px;
|
|
border-bottom: 1px solid var(--dsd-g200);
|
|
}
|
|
|
|
.dsd-head-l {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 12px;
|
|
}
|
|
|
|
.dsd-head-ic {
|
|
width: 40px;
|
|
height: 40px;
|
|
flex-shrink: 0;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 12px;
|
|
background: var(--dsd-purple);
|
|
color: #fff;
|
|
font-size: 17px;
|
|
}
|
|
|
|
.dsd-head-t {
|
|
margin: 0;
|
|
font-size: 16px;
|
|
font-weight: 800;
|
|
color: var(--dsd-g900);
|
|
line-height: 1.2;
|
|
}
|
|
|
|
.dsd-head-s {
|
|
margin-top: 3px;
|
|
font-size: 11.5px;
|
|
color: var(--dsd-g500);
|
|
}
|
|
|
|
.dsd-head-r {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.dsd-who {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
padding: 5px 10px 5px 7px;
|
|
border-radius: 999px;
|
|
background: var(--dsd-blue-l);
|
|
border: 1px solid var(--dsd-blue-tint);
|
|
max-width: 200px;
|
|
}
|
|
|
|
.dsd-who-ic {
|
|
width: 24px;
|
|
height: 24px;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 50%;
|
|
background: var(--dsd-blue-d);
|
|
color: #fff;
|
|
font-size: 11px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.dsd-who-txt {
|
|
display: flex;
|
|
flex-direction: column;
|
|
line-height: 1.1;
|
|
min-width: 0;
|
|
}
|
|
|
|
.dsd-who-name {
|
|
font-size: 11.5px;
|
|
font-weight: 700;
|
|
color: var(--dsd-g900);
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.dsd-who-uname {
|
|
font-size: 10px;
|
|
color: var(--dsd-blue-d);
|
|
margin-top: 1px;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.dsd-x {
|
|
width: 32px;
|
|
height: 32px;
|
|
border-radius: 999px;
|
|
border: 1px solid var(--dsd-g200);
|
|
background: #fff;
|
|
color: var(--dsd-g500);
|
|
cursor: pointer;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 13px;
|
|
flex-shrink: 0;
|
|
transition: all 0.12s ease;
|
|
|
|
&:hover {
|
|
background: var(--dsd-red-l);
|
|
color: var(--dsd-red);
|
|
border-color: var(--dsd-red-tint);
|
|
}
|
|
}
|
|
|
|
/* ───────── Body ───────── */
|
|
.dsd-body {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 14px;
|
|
overflow-y: auto;
|
|
padding-right: 2px;
|
|
}
|
|
|
|
/* Status row at the top of body */
|
|
.dsd-status-row {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.dsd-status-pill {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
padding: 4px 11px;
|
|
border-radius: 999px;
|
|
font-size: 11px;
|
|
font-weight: 800;
|
|
letter-spacing: 0.04em;
|
|
text-transform: uppercase;
|
|
|
|
fa-icon {
|
|
font-size: 10px;
|
|
}
|
|
|
|
&--ok {
|
|
background: var(--dsd-green-l);
|
|
color: var(--dsd-green);
|
|
border: 1px solid #bbf7d0;
|
|
}
|
|
|
|
&--warn {
|
|
background: var(--dsd-amber-l);
|
|
color: var(--dsd-amber);
|
|
border: 1px solid #fde68a;
|
|
}
|
|
|
|
&--muted {
|
|
background: var(--dsd-blue-l);
|
|
color: var(--dsd-blue-d);
|
|
border: 1px solid var(--dsd-blue-tint);
|
|
}
|
|
}
|
|
|
|
.dsd-status-meta {
|
|
font-size: 12px;
|
|
color: var(--dsd-g500);
|
|
}
|
|
|
|
/* ───────── DSC details card ───────── */
|
|
.dsd-card {
|
|
border: 1px solid var(--dsd-g200);
|
|
border-radius: 12px;
|
|
background: linear-gradient(180deg, #fafbff 0%, #fff 60%);
|
|
overflow: hidden;
|
|
}
|
|
|
|
.dsd-card-h {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 12px;
|
|
padding: 12px 14px;
|
|
border-bottom: 1px solid var(--dsd-g200);
|
|
background: var(--dsd-purple-l);
|
|
}
|
|
|
|
.dsd-card-h-ic {
|
|
width: 32px;
|
|
height: 32px;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 9px;
|
|
background: var(--dsd-purple);
|
|
color: #fff;
|
|
font-size: 14px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.dsd-card-name {
|
|
font-size: 14px;
|
|
font-weight: 800;
|
|
color: var(--dsd-g900);
|
|
line-height: 1.2;
|
|
}
|
|
|
|
.dsd-card-type {
|
|
font-size: 11px;
|
|
color: var(--dsd-g500);
|
|
margin-top: 2px;
|
|
}
|
|
|
|
.dsd-cert-pill {
|
|
margin-left: auto;
|
|
padding: 3px 10px;
|
|
border-radius: 999px;
|
|
font-size: 10px;
|
|
font-weight: 800;
|
|
letter-spacing: 0.05em;
|
|
text-transform: uppercase;
|
|
background: var(--dsd-g100);
|
|
color: var(--dsd-g700);
|
|
|
|
&--ok {
|
|
background: var(--dsd-green-l);
|
|
color: var(--dsd-green);
|
|
}
|
|
|
|
&--warn {
|
|
background: var(--dsd-amber-l);
|
|
color: var(--dsd-amber);
|
|
}
|
|
|
|
&--bad {
|
|
background: var(--dsd-red-l);
|
|
color: var(--dsd-red);
|
|
}
|
|
}
|
|
|
|
.dsd-card-grid {
|
|
display: grid;
|
|
grid-template-columns: 1fr 1fr;
|
|
gap: 10px 14px;
|
|
padding: 12px 14px;
|
|
}
|
|
|
|
.dsd-span-2 {
|
|
grid-column: 1 / -1;
|
|
}
|
|
|
|
.dsd-card-l {
|
|
display: block;
|
|
font-size: 9.5px;
|
|
font-weight: 700;
|
|
letter-spacing: 0.06em;
|
|
text-transform: uppercase;
|
|
color: var(--dsd-g500);
|
|
margin-bottom: 2px;
|
|
}
|
|
|
|
.dsd-card-v {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
font-size: 12.5px;
|
|
font-weight: 600;
|
|
color: var(--dsd-g900);
|
|
word-break: break-word;
|
|
}
|
|
|
|
.dsd-expiry-chip {
|
|
padding: 2px 8px;
|
|
border-radius: 999px;
|
|
font-size: 10px;
|
|
font-weight: 700;
|
|
letter-spacing: 0.04em;
|
|
text-transform: uppercase;
|
|
|
|
&--ok {
|
|
background: var(--dsd-green-l);
|
|
color: var(--dsd-green);
|
|
}
|
|
|
|
&--warn {
|
|
background: var(--dsd-amber-l);
|
|
color: var(--dsd-amber);
|
|
}
|
|
|
|
&--bad {
|
|
background: var(--dsd-red-l);
|
|
color: var(--dsd-red);
|
|
}
|
|
}
|
|
|
|
/* ───────── File chip ───────── */
|
|
.dsd-file-chip {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 12px;
|
|
padding: 10px 14px;
|
|
border-radius: 10px;
|
|
background: var(--dsd-blue-l);
|
|
border: 1px solid var(--dsd-blue-tint);
|
|
}
|
|
|
|
.dsd-file-ic {
|
|
width: 32px;
|
|
height: 32px;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
border-radius: 9px;
|
|
background: var(--dsd-blue-d);
|
|
color: #fff;
|
|
font-size: 13px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.dsd-file-info {
|
|
min-width: 0;
|
|
flex: 1;
|
|
}
|
|
|
|
.dsd-file-l {
|
|
font-size: 10px;
|
|
font-weight: 700;
|
|
letter-spacing: 0.06em;
|
|
text-transform: uppercase;
|
|
color: var(--dsd-blue-d);
|
|
}
|
|
|
|
.dsd-file-v {
|
|
font-size: 12.5px;
|
|
font-weight: 700;
|
|
color: var(--dsd-g900);
|
|
word-break: break-all;
|
|
margin-top: 2px;
|
|
}
|
|
|
|
/* ───────── Empty (not-mapped) state ───────── */
|
|
.dsd-empty {
|
|
display: flex;
|
|
align-items: flex-start;
|
|
gap: 12px;
|
|
padding: 14px 16px;
|
|
border: 1px dashed var(--dsd-g300);
|
|
border-radius: 10px;
|
|
background: var(--dsd-g50);
|
|
color: var(--dsd-g700);
|
|
|
|
p {
|
|
margin: 6px 0 0;
|
|
font-size: 12.5px;
|
|
color: var(--dsd-g500);
|
|
line-height: 1.5;
|
|
}
|
|
}
|
|
|
|
.dsd-empty-ic {
|
|
width: 36px;
|
|
height: 36px;
|
|
border-radius: 50%;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
background: var(--dsd-purple-l);
|
|
color: var(--dsd-purple);
|
|
font-size: 16px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
/* ───────── Footer actions ───────── */
|
|
.dsd-actions {
|
|
display: flex;
|
|
justify-content: flex-end;
|
|
gap: 10px;
|
|
padding-top: 6px;
|
|
}
|
|
|
|
.dsd-btn {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
height: 38px;
|
|
padding: 0 18px;
|
|
border-radius: 9px;
|
|
border: 1px solid var(--dsd-g200);
|
|
background: #fff;
|
|
color: var(--dsd-g700);
|
|
font-size: 13px;
|
|
font-weight: 700;
|
|
letter-spacing: 0.01em;
|
|
cursor: pointer;
|
|
transition: all 0.12s ease;
|
|
|
|
fa-icon {
|
|
font-size: 12px;
|
|
}
|
|
|
|
&--ghost {
|
|
background: #fff;
|
|
color: var(--dsd-g700);
|
|
border-color: var(--dsd-g200);
|
|
|
|
fa-icon {
|
|
color: var(--dsd-g500);
|
|
}
|
|
|
|
&:hover {
|
|
background: var(--dsd-g50);
|
|
border-color: var(--dsd-g300);
|
|
color: var(--dsd-g900);
|
|
}
|
|
}
|
|
|
|
&--primary {
|
|
background: linear-gradient(135deg, var(--dsd-purple) 0%, var(--dsd-blue-d) 100%);
|
|
color: #fff;
|
|
border-color: var(--dsd-blue-d);
|
|
box-shadow: 0 2px 6px -2px rgb(29 78 216 / 35%);
|
|
|
|
fa-icon {
|
|
color: #fff;
|
|
}
|
|
|
|
&:hover {
|
|
background: linear-gradient(135deg, #5b21b6 0%, #1e3a8a 100%);
|
|
box-shadow: 0 4px 12px -3px rgb(29 78 216 / 45%);
|
|
}
|
|
}
|
|
}
|
|
|
|
/* ───────── Loading skeleton ───────── */
|
|
.dsd-body--loading {
|
|
min-height: 120px;
|
|
}
|
|
|
|
.dsd-skeleton {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 10px;
|
|
padding: 4px 2px;
|
|
}
|
|
|
|
.dsd-skel {
|
|
height: 14px;
|
|
border-radius: 6px;
|
|
background: linear-gradient(90deg, var(--dsd-g100) 0%, var(--dsd-g200) 50%, var(--dsd-g100) 100%);
|
|
background-size: 200% 100%;
|
|
animation: dsd-shimmer 1.4s linear infinite;
|
|
|
|
&--h {
|
|
height: 28px;
|
|
border-radius: 8px;
|
|
width: 60%;
|
|
}
|
|
}
|
|
|
|
.dsd-skel-grid {
|
|
display: grid;
|
|
grid-template-columns: 1fr 1fr;
|
|
gap: 8px 14px;
|
|
|
|
.dsd-skel {
|
|
height: 32px;
|
|
border-radius: 8px;
|
|
}
|
|
}
|
|
|
|
@keyframes dsd-shimmer {
|
|
0% {
|
|
background-position: 200% 0;
|
|
}
|
|
|
|
100% {
|
|
background-position: -200% 0;
|
|
}
|
|
}
|
|
|
|
/* ───────── Operator card (not-mapped state) ───────── */
|
|
.dsd-op-card {
|
|
display: flex;
|
|
align-items: flex-start;
|
|
gap: 12px;
|
|
padding: 12px 14px;
|
|
border-radius: 12px;
|
|
background: linear-gradient(135deg, #eef2ff 0%, var(--dsd-blue-l) 100%);
|
|
border: 1px solid var(--dsd-blue-tint);
|
|
}
|
|
|
|
.dsd-op-avatar {
|
|
width: 38px;
|
|
height: 38px;
|
|
border-radius: 50%;
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
background: linear-gradient(135deg, var(--dsd-blue-d) 0%, var(--dsd-purple) 100%);
|
|
color: #fff;
|
|
font-size: 16px;
|
|
flex-shrink: 0;
|
|
box-shadow: 0 2px 6px -2px rgb(29 78 216 / 40%);
|
|
}
|
|
|
|
.dsd-op-body {
|
|
flex: 1;
|
|
min-width: 0;
|
|
}
|
|
|
|
.dsd-op-name {
|
|
font-size: 13.5px;
|
|
font-weight: 800;
|
|
color: var(--dsd-g900);
|
|
line-height: 1.2;
|
|
}
|
|
|
|
.dsd-op-meta {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
gap: 6px;
|
|
margin-top: 2px;
|
|
font-size: 11px;
|
|
color: var(--dsd-g500);
|
|
font-weight: 600;
|
|
}
|
|
|
|
.dsd-op-sep {
|
|
color: var(--dsd-g300);
|
|
}
|
|
|
|
.dsd-op-prev {
|
|
margin-top: 8px;
|
|
padding-top: 8px;
|
|
border-top: 1px dashed var(--dsd-blue-tint);
|
|
font-size: 11.5px;
|
|
color: var(--dsd-g700);
|
|
|
|
fa-icon {
|
|
color: var(--dsd-amber);
|
|
margin-right: 6px;
|
|
}
|
|
|
|
strong {
|
|
color: var(--dsd-g900);
|
|
}
|
|
|
|
em {
|
|
font-style: normal;
|
|
font-weight: 700;
|
|
color: var(--dsd-amber);
|
|
}
|
|
}
|