when icon indicating copy to clipboard operation
when copied to clipboard

Exact dates with human readable months rules

Open fred01 opened this issue 7 years ago • 1 comments

Hi! Can you, please, add exact date rules for both languages? i.e. 25 april at 2.25pm and 25 апреля в 2.30 вечера

fred01 avatar Apr 21 '18 17:04 fred01

It works if you use : as a separator for time:

gore> r, err := w.Parse("25 april at 2:25pm", time.Now())
&when.Result{
  Index:  0,
  Text:   "25 april at 2:25pm",
  Source: "25 april at 2:25pm",
  Time:   2019-04-25 14:25:12 Local,
}
nil
gore> r, err := w.Parse("25 апреля в 2:30 вечера", time.Now())
&when.Result{
  Index:  19,
  Text:   "2:30 вечера",
  Source: "25 апреля в 2:30 вечера",
  Time:   2019-02-27 14:30:14 Local,
}
nil

orsinium avatar Feb 27 '19 09:02 orsinium