Sha256: 949e9b3bf8007c364a3957a441b8895bfc4c8b0029d8683e3ecd03c22283f81a
Contents?: true
Size: 424 Bytes
Versions: 8
Compression:
Stored size: 424 Bytes
Contents
# frozen_string_literal: true module Katalyst module Navigation # Renders an HTML button using `button_to`. class Button < Item HTTP_METHODS = %i[get post patch put delete].index_by(&:itself).freeze enum method: HTTP_METHODS, _prefix: :http validates :title, :url, :http_method, presence: true validates :http_method, inclusion: { in: HTTP_METHODS.values.map(&:to_s) } end end end
Version data entries
8 entries across 8 versions & 1 rubygems