feat: add insurance/Takaful tracking, liabilities, and asset ownership verification
Per-member Insurance & Takaful tab (life/Takaful/medical/asset policies, same author-owns/family-reads pattern as Wassiyah/Waqf), a family-shared Liabilities section on the Asset Registry (kept distinct from assets since Faraid requires debts settled before distribution), and dual-path asset ownership verification (proof document + confirm by either the mutawalli/agent or any other family member, since not every demo family has an agent assigned). All proof documents share a new private nf-asset-documents storage bucket with the same RLS pattern as person photos. Mutawalli dashboard now surfaces each member's insurance policies. Covered by e2e-insurance-verification.cjs (12/12); full regression sweep 233/233 across all suites.
This commit is contained in:
+14
-12
@@ -18,6 +18,7 @@
|
||||
import FamilyManagement from './lib/FamilyManagement.svelte';
|
||||
import MutawalliDashboard from './lib/MutawalliDashboard.svelte';
|
||||
import FamilyTree from './lib/FamilyTree.svelte';
|
||||
import InsurancePolicies from './lib/InsurancePolicies.svelte';
|
||||
|
||||
let currentLang = $state('en');
|
||||
lang.subscribe(v => currentLang = v);
|
||||
@@ -41,8 +42,8 @@
|
||||
}
|
||||
});
|
||||
|
||||
const tabs = ['Coverage', 'Faraid', 'Assets', 'Wassiyah', 'Hibah', 'Family Waqf', 'Nominate', 'Trigger', 'Mutawalli', 'Tree', 'Claims (H2)', 'Family', 'Settings'];
|
||||
const icons = ['🎯', '📊', '📁', '📜', '🎁', '⛲', '📇', '⚡', '🕋', '🌳', '🔗', '👥', '⚙️'];
|
||||
const tabs = ['Coverage', 'Faraid', 'Assets', 'Insurance', 'Wassiyah', 'Hibah', 'Family Waqf', 'Nominate', 'Trigger', 'Mutawalli', 'Tree', 'Claims (H2)', 'Family', 'Settings'];
|
||||
const icons = ['🎯', '📊', '📁', '🛡️', '📜', '🎁', '⛲', '📇', '⚡', '🕋', '🌳', '🔗', '👥', '⚙️'];
|
||||
let activeTab = $state(0);
|
||||
|
||||
function handleKeydown(e) {
|
||||
@@ -99,16 +100,17 @@
|
||||
{#if activeTab === 0}<CoverageDashboard />
|
||||
{:else if activeTab === 1}<FaraidCalculator />
|
||||
{:else if activeTab === 2}<AssetRegistry />
|
||||
{:else if activeTab === 3}<WassiyahGenerator />
|
||||
{:else if activeTab === 4}<HibahTracker />
|
||||
{:else if activeTab === 5}<FamilyWaqfDesignator />
|
||||
{:else if activeTab === 6}<NominationRegistry />
|
||||
{:else if activeTab === 7}<DeathTrigger />
|
||||
{:else if activeTab === 8}<MutawalliDashboard />
|
||||
{:else if activeTab === 9}<FamilyTree />
|
||||
{:else if activeTab === 10}<DigitalClaims />
|
||||
{:else if activeTab === 11}<FamilyManagement />
|
||||
{:else if activeTab === 12}
|
||||
{:else if activeTab === 3}<InsurancePolicies />
|
||||
{:else if activeTab === 4}<WassiyahGenerator />
|
||||
{:else if activeTab === 5}<HibahTracker />
|
||||
{:else if activeTab === 6}<FamilyWaqfDesignator />
|
||||
{:else if activeTab === 7}<NominationRegistry />
|
||||
{:else if activeTab === 8}<DeathTrigger />
|
||||
{:else if activeTab === 9}<MutawalliDashboard />
|
||||
{:else if activeTab === 10}<FamilyTree />
|
||||
{:else if activeTab === 11}<DigitalClaims />
|
||||
{:else if activeTab === 12}<FamilyManagement />
|
||||
{:else if activeTab === 13}
|
||||
<div class="module">
|
||||
<div class="module-header">
|
||||
<h2>Settings</h2>
|
||||
|
||||
Reference in New Issue
Block a user