zod-ir 1.0.0 → 1.0.1

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.
Files changed (2) hide show
  1. package/README.md +27 -11
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,18 +1,34 @@
1
- # Zod Iranian Utils 🇮🇷
1
+ # Zod Iranian Utils
2
2
 
3
- A lightweight, TypeScript-first collection of Zod validators for Iranian specific data structures.
3
+ <div align="center">
4
4
 
5
- ## Features
5
+ ![npm version](https://img.shields.io/npm/v/zod-ir?style=flat-square)
6
+ ![npm bundle size](https://img.shields.io/bundlephobia/minzip/zod-ir?style=flat-square)
7
+ ![license](https://img.shields.io/npm/l/zod-ir?style=flat-square)
6
8
 
7
- - **Melli Code** (National ID) validation with official algorithm.
8
- - 💳 **Bank Card** validation using Luhn algorithm.
9
- - 📱 **Mobile Number** validation (supports +98, 09xx, 9xx).
10
- - 🌍 **Bilingual Error Messages** (Persian & English).
11
- - 🌲 **Tree-shakable** & Type-safe.
9
+ **A lightweight, type-safe Zod extension for validating Iranian specific data.**
10
+ Compatible with **React Hook Form**, **Next.js**, and Node.js backends.
12
11
 
13
- ## Installation
12
+ </div>
13
+
14
+ ## Features ✨
15
+
16
+ - ✅ **National Code (Code Melli):** Validates using the official checksum algorithm.
17
+ - 💳 **Bank Card:** Validates 16-digit card numbers using the Luhn algorithm.
18
+ - 📱 **Mobile Number:** Validates Iranian mobile formats (`09xx`, `+989xx`, `9xx`).
19
+ - 🌍 **Bilingual:** Built-in error messages in **Persian (Farsi)** and **English**.
20
+ - 🌲 **Tree-shakable:** Import only what you need.
21
+ - 🛡️ **Zero Dependency:** (Only requires `zod` as a peer dependency).
22
+
23
+ ---
24
+
25
+ ## Installation 📦
26
+
27
+ You need to install `zod` and `zod-ir`:
14
28
 
15
29
  ```bash
16
- npm install zod zod-iranian-utils
30
+ npm install zod zod-ir
31
+ # or
32
+ yarn add zod zod-ir
17
33
  # or
18
- yarn add zod zod-iranian-utils
34
+ pnpm add zod zod-ir
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zod-ir",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Essential Zod validators for Iranian specific data (National Code, Card Number, Mobile)",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",