Skip to content

Commit 00ca56b

Browse files
jonasjabarigitbook-bot
authored andcommitted
GitBook: [master] 147 pages modified
1 parent c5ef3a4 commit 00ca56b

File tree

145 files changed

+17883
-145
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

145 files changed

+17883
-145
lines changed

SUMMARY.md

Lines changed: 143 additions & 144 deletions
Large diffs are not rendered by default.

api/100-components/README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Core Components
2+
3+
Matestack provides you with a wide set of core components that enable you to easily build your UI.
4+
5+
Please use the sidebar to navigate to the component documentations.
6+

api/100-components/abbr.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Matestack Core Component: Abbr
2+
3+
The HTML `<abbr>` tag, implemented in Ruby.
4+
5+
## Parameters
6+
7+
This component expects 1 required param and various optional configuration params and can either yield content or display what gets passed to the `text` configuration param.
8+
9+
### Title - required
10+
11+
Expects a string with the meaning of the abbreviation contained within the tag.
12+
13+
### Text \(optional\)
14+
15+
Expects a string which will be displayed as the content inside the `<abbr>` tag. If this is not passed, a block must be passed instead.
16+
17+
### HMTL attributes \(optional\)
18+
19+
This component accepts all the canonical [HTML global attributes](https://www.w3schools.com/tags/ref_standardattributes.asp) like `id` or `class`.
20+
21+
## Examples
22+
23+
### Example 1 - render options\[:text\] param
24+
25+
```ruby
26+
abbr title: 'Hypertext Markup Language', text: 'HTML'
27+
```
28+
29+
returns
30+
31+
```markup
32+
<abbr title="Hypertext Markup Language">HTML</abbr>
33+
```
34+
35+
### Example 2 - yield a given block
36+
37+
```ruby
38+
abbr title: 'Cascading Style Sheets' do
39+
span text: 'CSS'
40+
end
41+
```
42+
43+
returns
44+
45+
```markup
46+
<abbr title="Cascading Style Sheets"><span>CSS</span></abbr>
47+
```
48+

0 commit comments

Comments
 (0)