Module: Protos::Typography
- Defined in:
- lib/protos/typography.rb,
lib/protos/typography/heading.rb,
lib/protos/typography/paragraph.rb,
lib/protos/typography/inline_link.rb
Defined Under Namespace
Classes: Heading, InlineLink, Paragraph
Instance Method Summary
collapse
Instance Method Details
#h1 ⇒ Object
12
13
14
|
# File 'lib/protos/typography.rb', line 12
def h1(**, &)
render Heading.new(level: 1, size: :xl, **, &)
end
|
#h2 ⇒ Object
16
17
18
|
# File 'lib/protos/typography.rb', line 16
def h2(**, &)
render Heading.new(level: 2, size: :lg, **, &)
end
|
#h3 ⇒ Object
20
21
22
|
# File 'lib/protos/typography.rb', line 20
def h3(**, &)
render Heading.new(level: 3, size: :md, **, &)
end
|
#h4 ⇒ Object
24
25
26
|
# File 'lib/protos/typography.rb', line 24
def h4(**, &)
render Heading.new(level: 4, size: :sm, **, &)
end
|
#inline_a ⇒ Object
32
33
34
|
# File 'lib/protos/typography.rb', line 32
def inline_a(**, &)
render InlineLink.new(**, &)
end
|
#p ⇒ Object
28
29
30
|
# File 'lib/protos/typography.rb', line 28
def p(**, &)
render Paragraph.new(**, &)
end
|