document.getElementById('inputText').addEventListener('input', function() { const text = this.value.trim(); const words = text.split(/\s+/).filter(word => word.length > 0); const wordCount = words.length; const wordLimit = 3000; if (wordCount > wordLimit) { this.value = words.slice(0, wordLimit).join(' '); } document.getElementById('wordCount').textContent = `الفاظ کی تعداد: ${Math.min(wordCount, wordLimit)} / ${wordLimit}`; });
body { font-family: 'Noto Nastaliq Urdu', sans-serif; direction: rtl; text-align: right; padding: 0; margin: 0; } header { background-color: #333; color: #fff; padding: 10px 0; } nav ul { list-style: none; padding: 0; margin: 0; display: flex; justify-content: center; } nav ul li { margin: 0 15px; } nav ul li a { color: #fff; text-decoration: none; } main { padding: 20px; max-width: 800px; margin: 0 auto; } textarea { width: 100%; height: 200px; padding: 10px; font-size: 16px; box-sizing: border-box; } p { margin-top: 10px; font-size: 18px; }
ورڈ کاؤنٹر

ورڈ کاؤنٹر

الفاظ کی تعداد: 0 / 3000