DIACRITICS_MAP = {
'À' => [ 'A', "\u{0300}" ],
'Á' => [ 'A', "\u{0301}" ],
'Â' => [ 'A', "\u{0302}" ],
'Ã' => [ 'A', "\u{0303}" ],
'Ä' => [ 'A', "\u{0308}" ],
'Å' => [ 'A', "\u{030A}" ],
'Ç' => [ 'C', "\u{0327}" ],
'È' => [ 'E', "\u{0300}" ],
'É' => [ 'E', "\u{0301}" ],
'Ê' => [ 'E', "\u{0302}" ],
'Ë' => [ 'E', "\u{0308}" ],
'Ì' => [ 'I', "\u{0300}" ],
'Í' => [ 'I', "\u{0301}" ],
'Î' => [ 'I', "\u{0302}" ],
'Ï' => [ 'I', "\u{0308}" ],
'Ð' => [ 'D', "\u{0335}" ],
'Ñ' => [ 'N', "\u{0303}" ],
'Ò' => [ 'O', "\u{0300}" ],
'Ó' => [ 'O', "\u{0301}" ],
'Ô' => [ 'O', "\u{0302}" ],
'Õ' => [ 'O', "\u{0303}" ],
'Ö' => [ 'O', "\u{0308}" ],
'Ø' => [ 'O', "\u{0337}" ],
'Ù' => [ 'U', "\u{0300}" ],
'Ú' => [ 'U', "\u{0301}" ],
'Û' => [ 'U', "\u{0302}" ],
'Ü' => [ 'U', "\u{0308}" ],
'Ý' => [ 'Y', "\u{0301}" ],
'à' => [ 'a', "\u{0300}" ],
'á' => [ 'a', "\u{0301}" ],
'â' => [ 'a', "\u{0302}" ],
'ã' => [ 'a', "\u{0303}" ],
'ä' => [ 'a', "\u{0308}" ],
'å' => [ 'a', "\u{030A}" ],
'ç' => [ 'c', "\u{0327}" ],
'è' => [ 'e', "\u{0300}" ],
'é' => [ 'e', "\u{0301}" ],
'ê' => [ 'e', "\u{0302}" ],
'ë' => [ 'e', "\u{0308}" ],
'ì' => [ 'ı', "\u{0300}" ],
'í' => [ 'ı', "\u{0301}" ],
'î' => [ 'ı', "\u{0302}" ],
'ï' => [ 'ı', "\u{0308}" ],
'ð' => [ 'd', "\u{0335}" ],
'ñ' => [ 'n', "\u{0303}" ],
'ò' => [ 'o', "\u{0300}" ],
'ó' => [ 'o', "\u{0301}" ],
'ô' => [ 'o', "\u{0302}" ],
'õ' => [ 'o', "\u{0303}" ],
'ö' => [ 'o', "\u{0308}" ],
'ø' => [ 'o', "\u{0337}" ],
'ù' => [ 'u', "\u{0300}" ],
'ú' => [ 'u', "\u{0301}" ],
'û' => [ 'u', "\u{0302}" ],
'ü' => [ 'u', "\u{0308}" ],
'ý' => [ 'y', "\u{0301}" ],
'ÿ' => [ 'y', "\u{0308}" ]
}.map { |k,v| [k, v.join('')] }.to_h
This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at http://ift.tt/jcXqJW.
Комментариев нет:
Отправить комментарий