Sha256: a699c9fe31500f65cf7f3f0cc1dbc4a497cd3563b482b475cee8d537f4a9de6c

Contents?: true

Size: 513 Bytes

Versions: 52

Compression:

Stored size: 513 Bytes

Contents

# Used for Czech, Slovak.

module RailsI18n
  module Pluralization
    module WestSlavic
      def self.rule
        lambda do |n|
          if n == 1
            :one
          elsif [2, 3, 4].include?(n)
            :few
          else
            :other
          end
        end
      end

      def self.with_locale(locale)
        { locale => {
            :'i18n' => {
              :plural => {
                :keys => [:one, :few, :other],
                :rule => rule }}}}
      end
    end
  end
end

Version data entries

52 entries across 52 versions & 2 rubygems

Version Path
rails-i18n-7.0.6 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-7.0.5 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-7.0.3 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-7.0.2 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-7.0.1 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-6.0.0 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-6.0.0.beta1 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.1.3 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.1.2 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.1.1 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.1.0 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.4 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.3 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.2 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.1 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.0 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-4.0.9 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.0.beta4 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.0.beta3 lib/rails_i18n/common_pluralizations/west_slavic.rb
rails-i18n-5.0.0.beta2 lib/rails_i18n/common_pluralizations/west_slavic.rb