scrivito_pdf_widget 1.0.15 → 1.0.17

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 432d34faad6f28832549f3200ef7661db994550a
4
- data.tar.gz: cbe937565ad53ddcf52fac26b0d9b8b2cde1e388
3
+ metadata.gz: 6b152bc63cc87b053b9fd9091d655383591e55da
4
+ data.tar.gz: bab8eb2601d6b4cd39fd69775572921fa263ca1e
5
5
  SHA512:
6
- metadata.gz: 75c3eab034daaabc585180a2851dc4d3961c46000a2eeba51085e4e220ff5fe9d3c52132b154a78e19c470b2be402169c61e63daa219fcb033cfbf855efcc88e
7
- data.tar.gz: 152994e9c539f79c8a43928effc3c156febe5683fd57332278437987a4bd935bf817df8c36ed7042cbf470e709f7463f81358a7a33b658d229dff26c4960d7e2
6
+ metadata.gz: 7378c8856c1c58cfe65c2a1159b6d96774fe98a67260304c2f9f36ac6c4f80a7578a16a7e3e7ca864295eb72138d6e4c73787772759cef013747d15aefcf3358
7
+ data.tar.gz: 6ef71eb1c7a06a6b087a9d903494c1c3f5363a7f8398e967ad3f5bc846c5c412f344120049621ad200561eacc81f7c344e8c455a42dbe0d6acaba156c6f5c362
data/app/models/pdf.rb CHANGED
@@ -1,5 +1,4 @@
1
1
  class Pdf < Obj
2
- attribute :headline, :string
3
2
  attribute :description, :html
4
3
  attribute :blob, :binary
5
4
 
@@ -0,0 +1,7 @@
1
+ <div class="aler alert-info">
2
+ This attribute are used as meta information for semantic web. It is based on <a href="http://schema.org/MediaObject">http://schema.org/MediaObject</a>.
3
+ </div>
4
+
5
+ <%= scrivito_details_for 'Description' do %>
6
+ <%= scrivito_tag(:div, @obj, :description) %>
7
+ <% end %>
@@ -3,7 +3,7 @@
3
3
  <meta itemprop="contentSize" value="<%= number_to_human_size(pdf.binary_length) %>"/>
4
4
  <meta itemprop="encodingFormat" value="pdf"/>
5
5
 
6
- <meta itemprop="name" value="<%= pdf.title %>"/>
6
+ <meta itemprop="name" value="<%= pdf.name %>"/>
7
7
  <meta itemprop="description" value="<%= pdf.description %>"/>
8
8
 
9
9
  <canvas></canvas>
@@ -2,10 +2,8 @@
2
2
  <%= scrivito_tag(:div, widget, :pdf, data: {filter: PdfWidget.filter}) %>
3
3
  <% end %>
4
4
 
5
- <%= scrivito_details_for 'Title' do %>
6
- <%= scrivito_tag(:div, widget, :title %>
7
- <% end %>
8
-
9
- <%= scrivito_details_for 'Description' do %>
10
- <%= scrivito_tag(:div, widget, :description %>
5
+ <% if widget.pdf.present? %>
6
+ <%= scrivito_details_for 'Description' do %>
7
+ <%= scrivito_tag(:div, widget.pdf, :description) %>
8
+ <% end %>
11
9
  <% end %>
@@ -1,3 +1,3 @@
1
1
  module ScrivitoPdfWidget
2
- VERSION = "1.0.15"
2
+ VERSION = "1.0.17"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scrivito_pdf_widget
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.15
4
+ version: 1.0.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scrivito
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-03 00:00:00.000000000 Z
11
+ date: 2015-06-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -74,6 +74,7 @@ files:
74
74
  - app/assets/stylesheets/scrivito_pdf_widget/widget.css
75
75
  - app/models/pdf.rb
76
76
  - app/models/pdf_widget.rb
77
+ - app/views/pdf/details.html.erb
77
78
  - app/views/pdf_widget/_inline_pdf.html.erb
78
79
  - app/views/pdf_widget/details.html.erb
79
80
  - app/views/pdf_widget/show.html.erb
@@ -103,7 +104,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
103
104
  version: '0'
104
105
  requirements: []
105
106
  rubyforge_project:
106
- rubygems_version: 2.2.2
107
+ rubygems_version: 2.4.5
107
108
  signing_key:
108
109
  specification_version: 4
109
110
  summary: Display a PDF on your Page.