contentful_converter 0.0.1.13 → 0.0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b1237c1b023971ca2e44261d2f1bfbe0d6945ec4c857b212446a82785de4cbce
|
4
|
+
data.tar.gz: ceab77b90406545fabe458c82b2dcb242c47e4f87edb8136edfca25da787f999
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 23dc5e0c24d82fea3dc3588862f70c25bd7ba3aa9feb66fca8728e1b50a652cc56ea69ed1328bfdb050e4d27c4a23977741b41a46703205bc7fc005648d51629
|
7
|
+
data.tar.gz: 6517391e888f88dc67a799aecf914acd76f9e759402a9929405c454a03ba4741628948515fbbe578b349d7720e7c4cc360407ae9e6238bd0b0863d70beed70b0
|
data/README.md
CHANGED
@@ -132,10 +132,11 @@ ContentfulConverter.convert('<h3>hello world</h3>')
|
|
132
132
|
}
|
133
133
|
```
|
134
134
|
|
135
|
-
**`<embed />`**
|
135
|
+
**`<embed />` AND `<img />`**
|
136
136
|
|
137
137
|
If you want to add an embedded entry block, you need to create an `<embed>` element in HTML
|
138
|
-
with src
|
138
|
+
with src and type attributes, for ID and entry type. Images will be converted into
|
139
|
+
embedded-asset-blocks by default and the src will be used as an ID.
|
139
140
|
|
140
141
|
* Embedded Entry block: `<embed src="id_of_your_entry_123" type="entry"/>`
|
141
142
|
```ruby
|
@@ -155,6 +156,7 @@ with src as the entry ID and type for the entry type.
|
|
155
156
|
```
|
156
157
|
|
157
158
|
* Embedded Asset block: `<embed src="id_of_your_entry_123" type="asset"/>`
|
159
|
+
Images: `<img src='id_of_your_entry_123' />`
|
158
160
|
```ruby
|
159
161
|
{
|
160
162
|
data: {
|
@@ -21,11 +21,11 @@ module ContentfulConverter
|
|
21
21
|
end
|
22
22
|
|
23
23
|
def options
|
24
|
-
hyperlink_entry_option(type_value.capitalize)
|
24
|
+
hyperlink_entry_option(type_value.to_s.capitalize)
|
25
25
|
end
|
26
26
|
|
27
27
|
def type_value
|
28
|
-
nokogiri_node[:type] ||
|
28
|
+
nokogiri_node[:type] || :asset
|
29
29
|
end
|
30
30
|
|
31
31
|
def parsed_link
|