Sha256: 0db192c6f59f430a5adf29bf5020b70ed4128d06caa6186a937438edf367b4ed

Contents?: true

Size: 750 Bytes

Versions: 3

Compression:

Stored size: 750 Bytes

Contents

# encoding: utf-8

require_relative '../border'

module TTY
  class Table
    class Border
      # A class that represents no border.
      class Null < Border

        def_border do
          center SPACE_CHAR
        end

        # A stub top line
        #
        # @api private
        def top_line
          border_options ? super : nil
        end

        # A stub separator line
        #
        # @api private
        def separator
          return [] if border_options.separator == EACH_ROW
          border_options ? super : nil
        end

        # A stub bottom line
        #
        # @api private
        def bottom_line
          border_options ? super : nil
        end
      end # Null
    end # Border
  end # Table
end # TTY

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
tty-table-0.10.0 lib/tty/table/border/null.rb
tty-table-0.9.0 lib/tty/table/border/null.rb
tty-table-0.8.0 lib/tty/table/border/null.rb