From 5d84f336f8f5008dd7a253c1f895706d4273e715 Mon Sep 17 00:00:00 2001 From: Ed Grosvenor Date: Fri, 3 Jul 2020 12:23:47 -0500 Subject: [PATCH] WIP --- README.md | 2 +- src/Languages.php | 29 +++++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 09352bb..17aa425 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Sundial -Natural Language Date / Time Processing for PHP 7.4+ +Natural Language Date / Time String Parsing for PHP 7.4+

diff --git a/src/Languages.php b/src/Languages.php index fd5888c..5c71cb3 100644 --- a/src/Languages.php +++ b/src/Languages.php @@ -43,4 +43,33 @@ public function eng(): array ], ]; } + + public function esp(): array + { + return [ + 'months' => [ + '1' => [' enero '], + '2' => [' febrero ', ' feb '], + '3' => [' marzo ', ' mar '], + '4' => [' abril ', ' abr '], + '5' => [' mayo '], + '6' => [' junio ', ' jun '], + '7' => [' julio ', ' jul '], + '8' => [' agosto ',], + '9' => [' septiembre ', ' sept ', 'set'], + '10' => [' octubre ', ' oct '], + '11' => [' noviembre ', ' nov '], + '12' => [' diciembre ', ' dic '], + ], + 'days' => [ + 'sunday' => [' domingo ', ' d ', ' do ', ' dom '], + 'monday' => [' lunes ', ' lu ', ' lu ', ' lun '], + 'tuesday' => [' martes ', ' m ', ' ma', ' mar '], + 'wednesday' => [' miércoles ', ' miercoles ', ' x ', ' mi ', ' mie ', ' mié '], + 'thursday' => [' jueves ', ' j ', ' ju ', ' jue '], + 'friday' => [' viernes ', ' v ', ' vi ', ' vie '], + 'saturday' => [' sábado ', ' sabado ', ' s ', ' sá ', ' sa ', ' sab '], + ], + ]; + } }