Skip to content
This repository has been archived by the owner on Aug 20, 2022. It is now read-only.

Commit

Permalink
General Arabic Language (#226)
Browse files Browse the repository at this point in the history
* General Arabic Language

General Arabic & for United Arab Emirates as well

* Use of Inline Datepicker
  • Loading branch information
fengyuanchen authored Sep 29, 2020
2 parents e151659 + 91cd8bc commit 1155127
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,18 @@ Initialize with `$.fn.datepicker` method.
```js
$('[data-toggle="datepicker"]').datepicker();
```
## Use as Inline
```html
<div id="inline-datepicker"></div>
```
```js
$(document).ready(function(){
$('#inline-datepicker').datepicker({
// language: 'ar-AE',
inline: true,
});
});
```

[⬆ back to top](#table-of-contents)

Expand Down
17 changes: 17 additions & 0 deletions i18n/datepicker.ar-AE.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('jquery')) :
typeof define === 'function' && define.amd ? define(['jquery'], factory) :
(factory(global.jQuery));
}(this, (function ($) {
'use strict';

$.fn.datepicker.languages['ar-AE'] = {
format: 'dd/mm/yyyy',
days: ['الأحد', 'الأثنين', 'الثلاثاء', 'الأربعاء', 'الخميس', 'الجمعة', 'السبت'],
daysShort: ['أحد', 'أثنين', 'ثلاثاء', 'اربعاء', 'خميس', 'جمعة', 'سبت'],
daysMin: ['أ', 'ث', 'ث', 'أ', 'خ', 'ج', 'س'],
weekStart: 1,
months: ['كانون الثاني', ' فبراير', 'مارس', 'أبريل', 'قد', 'يونيو', 'يوليو', 'أغسطس', 'سبتمبر', ' اكتوبر', ' نوفمبر', 'ديسمبر'],
monthsShort: ['كانون الثاني', ' فبراير', 'مارس', 'أبريل', 'قد', 'يونيو', 'يوليو', 'أغسطس', 'سبتمبر', ' اكتوبر', ' نوفمبر', 'ديسمبر'],
};
})));

0 comments on commit 1155127

Please sign in to comment.