Aus öffentlichen Paketdaten erstellte Orientierung.
Ein Flutter-Paket, das einen persischen (Farsi, Shamsi, Jalali) Datums- und Zeitwähler bereitstellt, inspiriert durch Material Design. Es ermöglicht Benutzern die Auswahl von Daten und Zeiten im Jalali-Kalendersystem, ideal für Anwendungen mit persischsprachigen Nutzern. Der Picker unterstützt alle wichtigen Plattformen wie Android, iOS, Web, macOS, Windows und Linux und sorgt für eine konsistente Benutzererfahrung über Geräte hinweg. Er integriert sich nahtlos in den Flutter-UI-Framework und bietet anpassbare Stil- und Verhaltensmöglichkeiten.
Anwendungsfälle
Datumsauswahl im persischen Kalender
Anwendungen für iranische oder persischsprachige Benutzer erstellen
Integration des Jalaali-Kalenders in Formulare
Unterstützung mehrsprachiger Dateneingabe
Kultursensible Benutzeroberflächen erstellen
Hauptmerkmale
Jalali-(persisches) Kalenderunterstützung
Material-inspiriertes Design
Plattformübergreifende Kompatibilität
Anpassbare Erscheinung
Einfache Integration mit Flutter-Formularen
Zeit- und Datumsauswahl
Geeignet für
Apps für den Iran oder persischsprachige Regionen
Entwickler, die Funktionen für den persischen Kalender benötigen
Projekte, die kulturrelevante Datumsauswahl benötigen
Flutter-Apps mit Internationalisierungsbedarf
UI-Komponenten, die lokalisierte Datums-Eingaben benötigen
Hinweise
Erfahrung mit dem persischen Kalendersystem erforderlich
Möglicherweise sind zusätzliche Lokalisierungsoptionen für nicht-persische Texte erforderlich
Mögliche Unterschiede bei der plattformspezifischen Darstellung
Eingeschränkte Dokumentation im Vergleich zu Mainstream-Paketen
Abhängig von externem GitHub-Repository für Updates
Original-README
Originaler README-Schnappschuss aus dem verknüpften Quell-Repository. Aktuelle Inhalte finden Sie im Repository.
Persian (Farsi, Shamsi, Jalali) Date & Time Picker for Flutter
Overview
A Persian Date & Time picker inspired by Material Design's DateTime picker, built on the shamsi_date library. It offers full support for the Persian (Jalali) calendar and is highly customizable, including compatibility with Material 3.
Additionally, it supports multiple languages, including Persian, Dari, Kurdish, Pashto, and custom locales, all while ensuring seamless integration with Flutter and maintaining Material Design standards.
️ Features
🌟 Fully supports Persian (Jalali) calendar
🛠 Highly customizable
💻 Supports Material 3
🌎 Multi-language support: Persian, Dari, Kurdish, Pashto, and custom locales
📱 Compatible with Material Design standards
️ Getting Started
To use the Persian DateTime Picker, add the package to your pubspec.yaml:
You can customize the styles of the PersianDateTimePicker and PersianCupertinoDatePicker using the DatePickerTheme within your app's ThemeData. Additionally, you can apply specific styles by wrapping the date picker with Theme in the builder.
Example for Persian Date Picker
Add the DatePickerTheme to your ThemeData:
returnMaterialApp(
theme: ThemeData(
// Other theme properties...
datePickerTheme: DatePickerTheme(
backgroundColor: Colors.white, // Background color of the date picker
primaryColor: Colors.teal, // Primary color for the date picker
textColor: Colors.black, // Text color// Customize more properties as needed
),
),
// ...
);
Customizing Persian Date Picker with Theme in Builder
You can also customize the Persian date picker on a per-instance basis by wrapping it with a Theme in the builder:
All customization options for the PersianDateTimePicker and PersianCupertinoDatePicker are similar to those of the native Flutter date pickers. You can easily apply styles using ThemeData, DatePickerTheme, or by wrapping the pickers with Theme in the builder, just like you would with native Flutter widgets.
6. Using Material 2 Instead of Material 3
If you prefer to use Material 2 instead of Material 3 for your application, you can do so by setting the useMaterial3 parameter to false in the MaterialApp widget. This ensures that the application uses the Material 2 design principles.
Example
Here’s how to set up your MaterialApp to use Material 2:
returnMaterialApp(
title: 'Persian DateTime Picker',
theme: ThemeData(
useMaterial3: false, // Set to false to use Material 2
datePickerTheme: DatePickerTheme(
backgroundColor: Colors.white,
primaryColor: Colors.teal,
textColor: Colors.black,
// Additional customizations
),
),
home: MyHomePage(),
);
️ Support Us
Feel free to check it out and give it a ️ if you love it.
Follow me for more updates and projects!
️ Contributions and Feedback
Pull requests and feedback are always welcome!
Feel free to reach out at [mem.amir.m@gmail.com](mailto:mem.amir.m@gmail.com) or connect with me on LinkedIn.