Sha256: 21cc2e90b317f42b027fd63670bd7f271d9622ee83101625269f22b232e9c7a7
Contents?: true
Size: 1 KB
Versions: 7
Compression:
Stored size: 1 KB
Contents
# frozen_string_literal: true module Primer module Beta # @label BorderBox class BorderBoxPreview < ViewComponent::Preview # @label Default options # # @param padding [Symbol] select [default, condensed] def default(padding: :default) render(Primer::Beta::BorderBox.new(padding: padding)) do |component| component.header { "Header" } component.body { "Body" } component.row { "Row one" } component.row { "Row two" } component.row { "Row three" } component.footer { "Footer" } end end # @label Row schemes # # @param padding [Symbol] select [default, condensed] # @param scheme [Symbol] select [default, neutral, info, warning] def row_schemes(padding: :default, scheme: :default) render(Primer::Beta::BorderBox.new(padding: padding)) do |component| component.row(scheme: scheme) { "#{scheme.to_s.capitalize} scheme" } end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems