PageRenderTime 42ms CodeModel.GetById 16ms RepoModel.GetById 1ms app.codeStats 0ms

/config/locales/cldr/plurals.rb

https://github.com/prodigeni/diaspora
Ruby | 54 lines | 54 code | 0 blank | 0 comment | 91 complexity | a90c316192ab2660d594633374abb98d MD5 | raw file
Possible License(s): JSON, AGPL-1.0
  1. {
  2. :'art-nvi' => { :i18n => {:plural => { :keys => [:zero, :one, :two, :few, :other], :rule => lambda { |n| n == 0 ? :zero : n == 1 ? :one : n == 2 ? :two : n == 3 ? :few : :other }, :js_rule => 'function (n) { return n == 0 ? "zero" : n == 1 ? "one" : n == 2 ? "two" : n == 3 ? "few" : "other" }' } } },
  3. :ar => { :i18n => {:plural => { :keys => [:zero, :one, :two, :few, :many, :other], :rule => lambda { |n| n == 0 ? :zero : n == 1 ? :one : n == 2 ? :two : [3, 4, 5, 6, 7, 8, 9, 10].include?(n % 100) ? :few : [11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99].include?(n % 100) ? :many : :other }, :js_rule => 'function (n) { return n == 0 ? "zero" : n == 1 ? "one" : n == 2 ? "two" : jQuery.inArray(n % 100, [3, 4, 5, 6, 7, 8, 9, 10]) != -1 ? "few" : jQuery.inArray(n % 100, [11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99]) != -1 ? "many" : "other" }' } } },
  4. :bg => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  5. :br => { :i18n => {:plural => { :keys => [:one, :two, :few, :many, :other], :rule => lambda { |n| n % 10 == 1 && n ? :one : n % 10 == 2 && n ? :two : [3, 4].include?(n % 10) && ![10, 11, 12, 13, 14, 15, 16, 17, 18, 19].include?(n % 100) ? :few : n != 0 && n % 1000000 == 0 ? :many : :other }, :js_rule => 'function (n) { return n % 10 == 1 && n ? "one" : n % 10 == 2 && n ? "two" : jQuery.inArray(n % 10, [3, 4]) != -1 && !jQuery.inArray(n % 100, [10, 11, 12, 13, 14, 15, 16, 17, 18, 19]) != -1 ? "few" : n != 0 && n % 1000000 == 0 ? "many" : "other" }' } } },
  6. :ca => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  7. :cs => { :i18n => {:plural => { :keys => [:one, :few, :other], :rule => lambda { |n| n == 1 ? :one : [2, 3, 4].include?(n) ? :few : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : jQuery.inArray(n, [2, 3, 4]) != -1 ? "few" : "other" }' } } },
  8. :cy => { :i18n => {:plural => { :keys => [:zero, :one, :two, :few, :many, :other], :rule => lambda { |n| n == 0 ? :zero : n == 1 ? :one : n == 2 ? :two : n == 3 ? :few : n == 6 ? :many : :other }, :js_rule => 'function (n) { return n == 0 ? "zero" : n == 1 ? "one" : n == 2 ? "two" : n == 3 ? "few" : n == 6 ? "many" : "other" }' } } },
  9. :da => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  10. :de => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  11. :el => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  12. :en => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  13. :eo => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  14. :es => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  15. :et => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  16. :eu => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  17. :fi => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  18. :fil => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| [0, 1].include?(n) ? :one : :other }, :js_rule => 'function (n) { return jQuery.inArray(n, [0, 1]) != -1 ? "one" : "other" }' } } },
  19. :fr => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n.between?(0, 2) && n != 2 ? :one : :other }, :js_rule => 'function (n) { return n >= 0 && n <= 2 && n != 2 ? "one" : "other" }' } } },
  20. :ga => { :i18n => {:plural => { :keys => [:one, :two, :few, :many, :other], :rule => lambda { |n| n == 1 ? :one : n == 2 ? :two : [3, 4, 5, 6].include?(n) ? :few : [7, 8, 9, 10].include?(n) ? :many : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : n == 2 ? "two" : jQuery.inArray(n, [3, 4, 5, 6]) != -1 ? "few" : jQuery.inArray(n, [7, 8, 9, 10]) != -1 ? "many" : "other" }' } } },
  21. :gl => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  22. :he => { :i18n => {:plural => { :keys => [:one, :two, :many, :other], :rule => lambda { |n| n == 1 ? :one : n == 2 ? :two : n != 0 ? :many : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : n == 2 ? "two" : n != 0 ? "many" : "other" }' } } },
  23. :hu => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  24. :hy => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  25. :id => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  26. :is => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  27. :it => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  28. :ja => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  29. :ka => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  30. :ko => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  31. :lt => { :i18n => {:plural => { :keys => [:one, :few, :other], :rule => lambda { |n| n % 10 == 1 && ![11, 12, 13, 14, 15, 16, 17, 18, 19].include?(n % 100) ? :one : [2, 3, 4, 5, 6, 7, 8, 9].include?(n % 10) && ![11, 12, 13, 14, 15, 16, 17, 18, 19].include?(n % 100) ? :few : :other }, :js_rule => 'function (n) { return n % 10 == 1 && !jQuery.inArray(n % 100, [11, 12, 13, 14, 15, 16, 17, 18, 19]) != -1 ? "one" : jQuery.inArray(n % 10, [2, 3, 4, 5, 6, 7, 8, 9]) != -1 && !jQuery.inArray(n % 100, [11, 12, 13, 14, 15, 16, 17, 18, 19]) != -1 ? "few" : "other" }' } } },
  32. :mk => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n % 10 == 1 && n != 11 ? :one : :other }, :js_rule => 'function (n) { return n % 10 == 1 && n != 11 ? "one" : "other" }' } } },
  33. :ml => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  34. :ms => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  35. :nb => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  36. :nl => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  37. :nn => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  38. :pa => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  39. :pl => { :i18n => {:plural => { :keys => [:one, :few, :many, :other], :rule => lambda { |n| n == 1 ? :one : [2, 3, 4].include?(n % 10) && ![12, 13, 14].include?(n % 100) ? :few : n != 1 && [0, 1].include?(n % 10) || [5, 6, 7, 8, 9].include?(n % 10) || [12, 13, 14].include?(n % 100) ? :many : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : jQuery.inArray(n % 10, [2, 3, 4]) != -1 && !jQuery.inArray(n % 100, [12, 13, 14]) != -1 ? "few" : n != 1 && jQuery.inArray(n % 10, [0, 1]) != -1 || jQuery.inArray(n % 10, [5, 6, 7, 8, 9]) != -1 || jQuery.inArray(n % 100, [12, 13, 14]) != -1 ? "many" : "other" }' } } },
  40. :pt => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  41. :ro => { :i18n => {:plural => { :keys => [:one, :few, :other], :rule => lambda { |n| n == 1 ? :one : n == 0 ? :few : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : n == 0 ? "few" : "other" }' } } },
  42. :ru => { :i18n => {:plural => { :keys => [:one, :few, :many, :other], :rule => lambda { |n| n % 10 == 1 && n % 100 != 11 ? :one : [2, 3, 4].include?(n % 10) && ![12, 13, 14].include?(n % 100) ? :few : n % 10 == 0 || [5, 6, 7, 8, 9].include?(n % 10) || [11, 12, 13, 14].include?(n % 100) ? :many : :other }, :js_rule => 'function (n) { return n % 10 == 1 && n % 100 != 11 ? "one" : jQuery.inArray(n % 10, [2, 3, 4]) != -1 && !jQuery.inArray(n % 100, [12, 13, 14]) != -1 ? "few" : n % 10 == 0 || jQuery.inArray(n % 10, [5, 6, 7, 8, 9]) != -1 || jQuery.inArray(n % 100, [11, 12, 13, 14]) != -1 ? "many" : "other" }' } } },
  43. :sk => { :i18n => {:plural => { :keys => [:one, :few, :other], :rule => lambda { |n| n == 1 ? :one : [2, 3, 4].include?(n) ? :few : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : jQuery.inArray(n, [2, 3, 4]) != -1 ? "few" : "other" }' } } },
  44. :sl => { :i18n => {:plural => { :keys => [:one, :two, :few, :other], :rule => lambda { |n| n % 100 == 1 ? :one : n % 100 == 2 ? :two : [3, 4].include?(n % 100) ? :few : :other }, :js_rule => 'function (n) { return n % 100 == 1 ? "one" : n % 100 == 2 ? "two" : jQuery.inArray(n % 100, [3, 4]) != -1 ? "few" : "other" }' } } },
  45. :sq => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  46. :sr => { :i18n => {:plural => { :keys => [:one, :few, :many, :other], :rule => lambda { |n| n % 10 == 1 && n % 100 != 11 ? :one : [2, 3, 4].include?(n % 10) && ![12, 13, 14].include?(n % 100) ? :few : n % 10 == 0 || [5, 6, 7, 8, 9].include?(n % 10) || [11, 12, 13, 14].include?(n % 100) ? :many : :other }, :js_rule => 'function (n) { return n % 10 == 1 && n % 100 != 11 ? "one" : jQuery.inArray(n % 10, [2, 3, 4]) != -1 && !jQuery.inArray(n % 100, [12, 13, 14]) != -1 ? "few" : n % 10 == 0 || jQuery.inArray(n % 10, [5, 6, 7, 8, 9]) != -1 || jQuery.inArray(n % 100, [11, 12, 13, 14]) != -1 ? "many" : "other" }' } } },
  47. :sv => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  48. :te => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  49. :tr => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  50. :uk => { :i18n => {:plural => { :keys => [:one, :few, :many, :other], :rule => lambda { |n| n % 10 == 1 && n % 100 != 11 ? :one : [2, 3, 4].include?(n % 10) && ![12, 13, 14].include?(n % 100) ? :few : n % 10 == 0 || [5, 6, 7, 8, 9].include?(n % 10) || [11, 12, 13, 14].include?(n % 100) ? :many : :other }, :js_rule => 'function (n) { return n % 10 == 1 && n % 100 != 11 ? "one" : jQuery.inArray(n % 10, [2, 3, 4]) != -1 && !jQuery.inArray(n % 100, [12, 13, 14]) != -1 ? "few" : n % 10 == 0 || jQuery.inArray(n % 10, [5, 6, 7, 8, 9]) != -1 || jQuery.inArray(n % 100, [11, 12, 13, 14]) != -1 ? "many" : "other" }' } } },
  51. :ur => { :i18n => {:plural => { :keys => [:one, :other], :rule => lambda { |n| n == 1 ? :one : :other }, :js_rule => 'function (n) { return n == 1 ? "one" : "other" }' } } },
  52. :vi => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } },
  53. :zh => { :i18n => {:plural => { :keys => [:other], :rule => lambda { |n| :other }, :js_rule => 'function (n) { return "other" }' } } }
  54. }