Sha256: 6d1f0486219422fb9aaa2fe381c59fcdfd4aff7c58cbc4aa89170dfd4d8ebb6f

Contents?: true

Size: 590 Bytes

Versions: 9

Compression:

Stored size: 590 Bytes

Contents

# frozen_string_literal: true

require 'eac_ruby_utils/core_ext'

module Ehbrs
  module Tools
    class Runner
      class Videos
        class Languages
          class Labelized < ::SimpleDelegator
            attr_reader :runner

            def initialize(runner, object)
              @runner = runner
              super(object)
            end

            def to_label
              return to_s unless runner.keep_languages?

              to_s.colorize(runner.keep_languages.include?(language) ? :green : :red)
            end
          end
        end
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
ehbrs-tools-0.43.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.42.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.39.1 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.39.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.38.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.37.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.36.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.35.1 lib/ehbrs/tools/runner/videos/languages/labelized.rb
ehbrs-tools-0.35.0 lib/ehbrs/tools/runner/videos/languages/labelized.rb