Skip to content

Commit

Permalink
Merge branch 'dev' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
iamkun authored Oct 4, 2023
2 parents 55e89bf + a947a51 commit e363522
Show file tree
Hide file tree
Showing 11 changed files with 52 additions and 34 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ English | [简体中文](./docs/zh-cn/README.zh-CN.md) | [日本語](./docs/ja/R
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square&colorB=51C838"
alt="NPM Version"></a>
<a href="https://travis-ci.com/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
6 changes: 3 additions & 3 deletions docs/es-es/README-es-es.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Español (España) | [English](../../README.md) | [简体中文](../zh-cn/README.zh-CN.md) | [日本語](../ja/README-ja.md) | [Português Brasileiro](../pt-br/README-pt-br.md) | [한국어](../ko/README-ko.md) | [Русский](../ru/README-ru.md) | [עברית](./docs/he/README-he.md)
Español (España) | [English](../../README.md) | [简体中文](../zh-cn/README.zh-CN.md) | [日本語](../ja/README-ja.md) | [Português Brasileiro](../pt-br/README-pt-br.md) | [한국어](../ko/README-ko.md) | [Русский](../ru/README-ru.md) | [עברית](./docs/he/README-he.md)

<p align="center"><a href="https://day.js.org/" target="_blank" rel="noopener noreferrer"><img width="550"
src="https://user-images.githubusercontent.com/17680888/39081119-3057bbe2-456e-11e8-862c-646133ad4b43.png"
Expand All @@ -11,8 +11,8 @@ Español (España) | [English](../../README.md) | [简体中文](../zh-cn/README
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square&colorB=51C838"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
23 changes: 11 additions & 12 deletions docs/he/README-he.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square&colorB=51C838"
alt="NPM Version"></a>
<a href="https://travis-ci.com/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand All @@ -24,7 +24,7 @@
</a>
</p>

> Day.js היא ספרייה מינימלסטית לפענוח, אימות, מניפולציה והצגה של תאריכים ושעות לדפדפנים מודרנים עם תאימות גבוהה ל-API של Moment.js. אם השתמשתם ב-Moment.js, אתם כבר יודעים את Day.js
> Day.js היא ספרייה מינימלסטית לפענוח, אימות, מניפולציה והצגה של תאריכים ושעות לדפדפנים מודרנים עם תאימות גבוהה ל-API של Moment.js. אם השתמשתם ב-Moment.js, אתם כבר יודעים את Day.js
<div dir="ltr">

Expand All @@ -43,13 +43,13 @@ dayjs().startOf('month').add(1, 'day').set('year', 2018).format('YYYY-MM-DD HH:m

---

## צעדים ראשונים
## צעדים ראשונים

### דוקומנטצייה
### דוקומנטצייה
באתר [day.js.org](https://day.js.org/) ניתן למצוא פרטים נוספים, API, ותיעודים נוספים.


### התקנה
### התקנה

```console
npm install dayjs --save
Expand All @@ -58,7 +58,7 @@ npm install dayjs --save
📚[מדריך התקנה](https://day.js.org/docs/en/installation/installation)

### API
מאוד קל להשתמש ב-Day.js לפענוח, אימות, מניפולציה והצגה של תאריכים ושעות.
מאוד קל להשתמש ב-Day.js לפענוח, אימות, מניפולציה והצגה של תאריכים ושעות.

<div dir="ltr">

Expand Down Expand Up @@ -126,9 +126,8 @@ dayjs().format('Q Do k kk X x') // כעת יותר אפשרויות זמינות
<img src="https://user-images.githubusercontent.com/3455798/270162667-c7bd2ebe-675e-45c6-a2c9-dc67f3b65d6e.png">
</a>

## ספונסרים
תמכו בפרויקט זה כדי להיות ספונסר. קבלו לוגו עם קישור לאתר שלכם שיופיע כאן.

### ספונסרים
תמכו בפרויקט זה כדי להיות ספונסר. קבלו לוגו עם קישור לאתר שלכם שיופיע כאן.

[[תמיכה דרך Github](https://github.com/sponsors/iamkun/)] [[תמיכה דרך OpenCollective](https://opencollective.com/dayjs#sponsor)]

Expand Down Expand Up @@ -156,7 +155,7 @@ dayjs().format('Q Do k kk X x') // כעת יותר אפשרויות זמינות
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="https://opencollective.com/datawrapper" target="_blank"><img width="70" src="https://images.opencollective.com/datawrapper/c13e229/logo.png"></a>

## תורמים
## תורמים

פרויקט זה קיים הודות לכל האנשים שתמכו בו.

Expand All @@ -171,7 +170,7 @@ dayjs().format('Q Do k kk X x') // כעת יותר אפשרויות זמינות
<br />
<a href="https://opencollective.com/dayjs#backers" target="_blank"><img src="https://opencollective.com/dayjs/contributors.svg?width=890" /></a>

## רישיון
## רישיון

Day.js מורשה לשימוש עם [רישיון MIT](./LICENSE).
</div>
4 changes: 2 additions & 2 deletions docs/ja/README-ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
4 changes: 2 additions & 2 deletions docs/ko/README-ko.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
4 changes: 2 additions & 2 deletions docs/pt-br/README-pt-br.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ Português Brasileiro | [English](../../README.md) | [简体中文](../zh-cn/REA
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
6 changes: 3 additions & 3 deletions docs/ru/README-ru.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square&colorB=51C838"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down Expand Up @@ -78,7 +78,7 @@ Day.js обладает великолепной поддержкой интер
```javascript
import 'dayjs/locale/es' // загрузка по требованию

dayjs.locale('es') // глобальное использование Испанской локали
dayjs.locale('es') // глобальное использование Испанской локали

dayjs('2018-05-05').locale('zh-cn').format() // использование упрощённой Китайской локали в конкретном случае
```
Expand Down
6 changes: 3 additions & 3 deletions docs/si/README-si.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square&colorB=51C838"
alt="NPM Version"></a>
<a href="https://travis-ci.com/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down Expand Up @@ -106,7 +106,7 @@ dayjs().format('Q Do k kk X x') // more available formats

## අනුග්‍රාහකයින්

අනුග්‍රහය දැක්වීමෙන් මෙම ව්‍යාපෘතියට සහාය වන්න. ඔබගේ අඩවියේ සබැඳියක් සමඟ ඔබගේ ලාංඡනය මෙහි පෙන්වනු ඇත.
අනුග්‍රහය දැක්වීමෙන් මෙම ව්‍යාපෘතියට සහාය වන්න. ඔබගේ අඩවියේ සබැඳියක් සමඟ ඔබගේ ලාංඡනය මෙහි පෙන්වනු ඇත.

[[ගිට්හබ් හරහා අනුග්‍රාහකයෙකු වන්න](https://github.com/sponsors/iamkun/)] [[ඕපන්කලෙක්ටිව් හරහා අනුග්‍රාහකයෙකු වන්න](https://opencollective.com/dayjs#sponsor)]

Expand Down
4 changes: 2 additions & 2 deletions docs/tr/README-tr.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ Türkçe | [English](../../README.md) | [简体中文](../zh-cn/README.zh-CN.md)
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square&colorB=51C838"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
4 changes: 2 additions & 2 deletions docs/zh-cn/README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
alt="Gzip Size"></a>
<a href="https://www.npmjs.com/package/dayjs"><img src="https://img.shields.io/npm/v/dayjs.svg?style=flat-square"
alt="NPM Version"></a>
<a href="https://travis-ci.org/iamkun/dayjs"><img
src="https://img.shields.io/travis/iamkun/dayjs/master.svg?style=flat-square" alt="Build Status"></a>
<a href="https://github.com/iamkun/dayjs/actions/workflows/check.yml"><img
src="https://img.shields.io/github/actions/workflow/status/iamkun/dayjs/check.yml?style=flat-square" alt="Build Status"></a>
<a href="https://codecov.io/gh/iamkun/dayjs"><img
src="https://img.shields.io/codecov/c/github/iamkun/dayjs/master.svg?style=flat-square" alt="Codecov"></a>
<a href="https://github.com/iamkun/dayjs/blob/master/LICENSE"><img
Expand Down
21 changes: 20 additions & 1 deletion src/locale/zh-hk.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ const locale = {
L: 'YYYY/MM/DD',
LL: 'YYYY年M月D日',
LLL: 'YYYY年M月D日 HH:mm',
LLLL: 'YYYY年M月D日dddd HH:mm'
LLLL: 'YYYY年M月D日dddd HH:mm',
l: 'YYYY/M/D',
ll: 'YYYY年M月D日',
lll: 'YYYY年M月D日 HH:mm',
llll: 'YYYY年M月D日dddd HH:mm'
},
relativeTime: {
future: '%s內',
Expand All @@ -38,6 +42,21 @@ const locale = {
MM: '%d 個月',
y: '一年',
yy: '%d 年'
},
meridiem: (hour, minute) => {
const hm = (hour * 100) + minute
if (hm < 600) {
return '凌晨'
} else if (hm < 900) {
return '早上'
} else if (hm < 1100) {
return '上午'
} else if (hm < 1300) {
return '中午'
} else if (hm < 1800) {
return '下午'
}
return '晚上'
}
}

Expand Down

0 comments on commit e363522

Please sign in to comment.