feat: add Zakat calculator (per-member, Nisab + 2.5% rate)
Closes the Zakat gap identified in the competitive benchmark against Rafiq. Per-member module (nf_zakat_records, same author-owns/family-reads RLS pattern as Insurance/Wassiyah/Waqf) computing 2.5% due on zakatable wealth (cash, gold, silver, business assets, investments) once above a user-entered Nisab threshold, minus deductible short-term liabilities. Manual entry only, matching the app's existing philosophy — no live gold price feed. Covered by e2e-zakat.cjs (7/7).
This commit is contained in:
+14
-12
@@ -19,6 +19,7 @@
|
||||
import MutawalliDashboard from './lib/MutawalliDashboard.svelte';
|
||||
import FamilyTree from './lib/FamilyTree.svelte';
|
||||
import InsurancePolicies from './lib/InsurancePolicies.svelte';
|
||||
import ZakatCalculator from './lib/ZakatCalculator.svelte';
|
||||
|
||||
let currentLang = $state('en');
|
||||
lang.subscribe(v => currentLang = v);
|
||||
@@ -42,8 +43,8 @@
|
||||
}
|
||||
});
|
||||
|
||||
const tabs = ['Coverage', 'Faraid', 'Assets', 'Insurance', 'Wassiyah', 'Hibah', 'Family Waqf', 'Nominate', 'Trigger', 'Mutawalli', 'Tree', 'Claims (H2)', 'Family', 'Settings'];
|
||||
const icons = ['🎯', '📊', '📁', '🛡️', '📜', '🎁', '⛲', '📇', '⚡', '🕋', '🌳', '🔗', '👥', '⚙️'];
|
||||
const tabs = ['Coverage', 'Faraid', 'Assets', 'Insurance', 'Zakat', 'Wassiyah', 'Hibah', 'Family Waqf', 'Nominate', 'Trigger', 'Mutawalli', 'Tree', 'Claims (H2)', 'Family', 'Settings'];
|
||||
const icons = ['🎯', '📊', '📁', '🛡️', '🌙', '📜', '🎁', '⛲', '📇', '⚡', '🕋', '🌳', '🔗', '👥', '⚙️'];
|
||||
let activeTab = $state(0);
|
||||
|
||||
function handleKeydown(e) {
|
||||
@@ -101,16 +102,17 @@
|
||||
{:else if activeTab === 1}<FaraidCalculator />
|
||||
{:else if activeTab === 2}<AssetRegistry />
|
||||
{: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}
|
||||
{:else if activeTab === 4}<ZakatCalculator />
|
||||
{:else if activeTab === 5}<WassiyahGenerator />
|
||||
{:else if activeTab === 6}<HibahTracker />
|
||||
{:else if activeTab === 7}<FamilyWaqfDesignator />
|
||||
{:else if activeTab === 8}<NominationRegistry />
|
||||
{:else if activeTab === 9}<DeathTrigger />
|
||||
{:else if activeTab === 10}<MutawalliDashboard />
|
||||
{:else if activeTab === 11}<FamilyTree />
|
||||
{:else if activeTab === 12}<DigitalClaims />
|
||||
{:else if activeTab === 13}<FamilyManagement />
|
||||
{:else if activeTab === 14}
|
||||
<div class="module">
|
||||
<div class="module-header">
|
||||
<h2>Settings</h2>
|
||||
|
||||
Reference in New Issue
Block a user