newspaper_works 0.1.0 → 1.0.0
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 +5 -5
- data/.coveralls.yml +2 -0
- data/.gitignore +4 -0
- data/.travis.yml +2 -2
- data/README.md +14 -13
- data/app/services/newspaper_works/jp2_derivative_service.rb +1 -3
- data/app/services/newspaper_works/newspaper_page_derivative_service.rb +37 -15
- data/app/services/newspaper_works/pdf_derivative_service.rb +4 -7
- data/app/services/newspaper_works/tiff_derivative_service.rb +5 -9
- data/app/views/newspaper_works/base/_attribute_rows.html.erb +72 -24
- data/config/locales/newspaper_article.de.yml +1 -1
- data/config/locales/newspaper_article.en.yml +1 -1
- data/config/locales/newspaper_article.es.yml +1 -1
- data/config/locales/newspaper_article.fr.yml +1 -1
- data/config/locales/newspaper_article.it.yml +1 -1
- data/config/locales/newspaper_article.pt-BR.yml +1 -1
- data/config/locales/newspaper_article.zh.yml +1 -1
- data/config/locales/newspaper_container.de.yml +1 -1
- data/config/locales/newspaper_container.en.yml +1 -1
- data/config/locales/newspaper_container.es.yml +1 -1
- data/config/locales/newspaper_container.fr.yml +1 -1
- data/config/locales/newspaper_container.it.yml +1 -1
- data/config/locales/newspaper_container.pt-BR.yml +1 -1
- data/config/locales/newspaper_container.zh.yml +1 -1
- data/config/locales/newspaper_issue.de.yml +1 -1
- data/config/locales/newspaper_issue.en.yml +1 -1
- data/config/locales/newspaper_issue.es.yml +1 -1
- data/config/locales/newspaper_issue.fr.yml +1 -1
- data/config/locales/newspaper_issue.it.yml +2 -2
- data/config/locales/newspaper_issue.pt-BR.yml +2 -2
- data/config/locales/newspaper_issue.zh.yml +2 -2
- data/config/locales/newspaper_page.de.yml +1 -1
- data/config/locales/newspaper_page.en.yml +1 -1
- data/config/locales/newspaper_page.es.yml +1 -1
- data/config/locales/newspaper_page.fr.yml +1 -1
- data/config/locales/newspaper_page.it.yml +1 -1
- data/config/locales/newspaper_page.pt-BR.yml +1 -1
- data/config/locales/newspaper_page.zh.yml +1 -1
- data/config/locales/newspaper_title.de.yml +1 -1
- data/config/locales/newspaper_title.en.yml +1 -1
- data/config/locales/newspaper_title.es.yml +1 -1
- data/config/locales/newspaper_title.fr.yml +1 -1
- data/config/locales/newspaper_title.it.yml +1 -1
- data/config/locales/newspaper_title.pt-BR.yml +1 -1
- data/config/locales/newspaper_title.zh.yml +1 -1
- data/config/locales/newspaper_works.de.yml +98 -0
- data/config/locales/newspaper_works.en.yml +67 -0
- data/config/locales/newspaper_works.es.yml +96 -0
- data/config/locales/newspaper_works.fr.yml +97 -0
- data/config/locales/newspaper_works.it.yml +90 -0
- data/config/locales/newspaper_works.pt-BR.yml +96 -0
- data/config/locales/newspaper_works.zh.yml +90 -0
- data/config/vendor/fits.xml +55 -0
- data/config/vendor/imagemagick-6-policy.xml +39 -39
- data/lib/newspaper_works.rb +2 -0
- data/lib/newspaper_works/image_tool.rb +119 -0
- data/lib/newspaper_works/jp2_image_metadata.rb +81 -0
- data/lib/newspaper_works/text_extraction.rb +1 -0
- data/lib/newspaper_works/text_extraction/hocr_reader.rb +173 -0
- data/lib/newspaper_works/text_extraction/page_ocr.rb +37 -51
- data/lib/newspaper_works/text_extraction/render_alto.rb +4 -4
- data/lib/newspaper_works/version.rb +1 -1
- data/newspaper_works.gemspec +2 -3
- data/spec/features/search_results_thumbnail_highlights_spec.rb +1 -1
- data/spec/fixtures/files/ocr_mono_text_hocr.html +78 -0
- data/spec/lib/newspaper_works/image_tool_spec.rb +109 -0
- data/spec/lib/newspaper_works/ingest/ingest_shared.rb +3 -3
- data/spec/lib/newspaper_works/ingest/newspaper_page_ingest_spec.rb +2 -2
- data/spec/lib/newspaper_works/jp2_image_metadata_spec.rb +37 -0
- data/spec/lib/newspaper_works/text_extraction/hocr_reader_spec.rb +45 -0
- data/spec/lib/newspaper_works/text_extraction/page_ocr_spec.rb +3 -3
- data/spec/lib/newspaper_works/text_extraction/render_alto_spec.rb +14 -14
- data/spec/services/newspaper_works/jp2_derivative_service_spec.rb +10 -13
- data/spec/services/newspaper_works/newspaper_page_derivative_service_spec.rb +10 -8
- data/spec/services/newspaper_works/pdf_derivative_service_spec.rb +11 -7
- data/spec/services/newspaper_works/tiff_derivative_service_spec.rb +17 -10
- data/spec/spec_helper.rb +19 -0
- metadata +21 -22
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 6e9b9c0ca19656d5b0654d96b5e3f8f31303dfe3a9df388643702a871b64ccbb
|
4
|
+
data.tar.gz: 485b605170e6740250ef85b0eac19880c84a4c2472486bffb1adc66beb548915
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a180e466f1e80b83e538f7e3687e982f9a30892901f23044bcbb3cc2a89248686a717d097163fa5c4771c5a726bd2d86c7d9c3ab6ce3ae0c9a2d2404cf4ce7ff
|
7
|
+
data.tar.gz: 74794d3456d451b094d83f75378e506383ed0f8da876a9cb5882c696e594fb0a89df1cf300240651cbe3317bffa766672398950133b62b62949a684d08f12f7c
|
data/.coveralls.yml
ADDED
data/.gitignore
CHANGED
data/.travis.yml
CHANGED
@@ -30,8 +30,8 @@ before_install:
|
|
30
30
|
- sudo unzip /opt/install/fits-1.4.1.zip -d /opt/install/fits-1.4.1
|
31
31
|
- sudo chmod +x /opt/install/fits-1.4.1/*.sh
|
32
32
|
- sudo ln -s /opt/install/fits-1.4.1/fits.sh /usr/local/bin/fits.sh
|
33
|
-
- sudo wget -q -O /etc/ImageMagick-6/policy.xml https://raw.githubusercontent.com/
|
34
|
-
- sudo wget -q -O /opt/install/fits-1.4.1/xml/fits.xml https://
|
33
|
+
- sudo wget -q -O /etc/ImageMagick-6/policy.xml https://raw.githubusercontent.com/samvera-labs/newspaper_works/master/config/vendor/imagemagick-6-policy.xml
|
34
|
+
- sudo wget -q -O /opt/install/fits-1.4.1/xml/fits.xml https://raw.githubusercontent.com/samvera-labs/newspaper_works/82d0c18d1679696a762fd7083db83dac49de9b35/config/vendor/fits.xml
|
35
35
|
rvm:
|
36
36
|
- 2.5.5
|
37
37
|
|
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
NewspaperWorks
|
2
2
|
===================================================
|
3
3
|
Code:
|
4
|
-
[](https://travis-ci.org/samvera-labs/newspaper_works) [](https://coveralls.io/github/samvera-labs/newspaper_works?branch=master)
|
5
5
|
|
6
6
|
Docs:
|
7
7
|
[](./LICENSE)
|
@@ -21,7 +21,7 @@ Jump in: [](http://slack.samv
|
|
21
21
|
- [Configuration changes you should make after running the installer](#configuration-changes-you-should-make-after-running-the-installer)
|
22
22
|
- [Ingesting Content](#ingesting-content)
|
23
23
|
- [Developing, Testing, and Contributing](#developing-testing-and-contributing)
|
24
|
-
- [Contributing](#contributing)
|
24
|
+
- [Contributing](#contributing)
|
25
25
|
- [Acknowledgements](#acknowledgements)
|
26
26
|
- [Sponsoring Organizations](#sponsoring-organizations)
|
27
27
|
- [More Information](#more-information)
|
@@ -45,10 +45,10 @@ NewspaperWorks supports:
|
|
45
45
|
* OCR keyword match highlighting
|
46
46
|
* viewer with page navigation and deep zooming
|
47
47
|
|
48
|
-
A complete list of features can be found [here](wiki/Features-List).
|
48
|
+
A complete list of features can be found [here](https://github.com/samvera-labs/newspaper_works/wiki/Features-List).
|
49
49
|
|
50
50
|
## Documentation
|
51
|
-
A set of helpful documents to help you learn more and deploy NewspaperWorks can be found on the [Project Wiki](
|
51
|
+
A set of helpful documents to help you learn more and deploy NewspaperWorks can be found on the [Project Wiki](https://github.com/samvera-labs/newspaper_works/wiki), including a PCDM model diagram, metadata schema, batch ingest instructions, and more details on installing, developing, and testing the code.
|
52
52
|
|
53
53
|
## Requirements
|
54
54
|
|
@@ -66,10 +66,11 @@ A set of helpful documents to help you learn more and deploy NewspaperWorks can
|
|
66
66
|
* [LibreOffice](https://www.libreoffice.org/)
|
67
67
|
* [ghostscript](https://www.ghostscript.com/)
|
68
68
|
* [poppler-utils](https://poppler.freedesktop.org/)
|
69
|
-
* [
|
69
|
+
* [ImageMagick](https://github.com/ImageMagick/ImageMagick6)
|
70
|
+
- _ImageMagick policy XML may need to be more permissive in both resources and source media types allowed. See template [policy.xml](config/vendor/imagemagick-6-policy.xml)._
|
70
71
|
* [libcurl3](https://packages.ubuntu.com/search?keywords=libcurl3)
|
71
72
|
|
72
|
-
See the [wiki](
|
73
|
+
See the [wiki](https://github.com/samvera-labs/newspaper_works/wiki/Installing,-Developing,-and-Testing) for more details on how to install and configure dependencies.
|
73
74
|
|
74
75
|
# Installation
|
75
76
|
NewspaperWorks easily integrates with your Hyrax 2.5.x applications.
|
@@ -91,7 +92,7 @@ NewspaperWorks easily integrates with your Hyrax 2.5.x applications.
|
|
91
92
|
### Configuration changes you should make after running the installer:
|
92
93
|
|
93
94
|
#### in config/intitializers/hyrax.rb:
|
94
|
-
* set `config.geonames_username`
|
95
|
+
* set `config.geonames_username`
|
95
96
|
* Enables geolocation tagging of content
|
96
97
|
* [how to create a Geonames username](http://www.geonames.org/login)
|
97
98
|
* set `config.work_requires_files = false`
|
@@ -106,9 +107,9 @@ NewspaperWorks easily integrates with your Hyrax 2.5.x applications.
|
|
106
107
|
|
107
108
|
NewspaperWorks supports a range of different ingest workflows:
|
108
109
|
* single-item ingest via the UI
|
109
|
-
* batch ingest of [NDNP materials](
|
110
|
-
* batch ingest of [PDF issues](
|
111
|
-
* batch ingest of [TIFF or JP2 master files](
|
110
|
+
* batch ingest of [NDNP materials](https://github.com/samvera-labs/newspaper_works/wiki/NDNP-Batch-Ingest-Guide) (page-level digitization) via command line
|
111
|
+
* batch ingest of [PDF issues](https://github.com/samvera-labs/newspaper_works/wiki/PDF-Batch-Ingest-Guide) via command line
|
112
|
+
* batch ingest of [TIFF or JP2 master files](https://github.com/samvera-labs/newspaper_works/wiki/TIFF-or-JP2-Batch-Ingest-Guide) via command line
|
112
113
|
|
113
114
|
The ingest process creates a full complement of derivatives for each Page object, including:
|
114
115
|
* TIFF
|
@@ -117,13 +118,13 @@ The ingest process creates a full complement of derivatives for each Page object
|
|
117
118
|
* OCR text
|
118
119
|
* word-coordinate JSON
|
119
120
|
|
120
|
-
For more information on derivatives, see the [wiki](
|
121
|
+
For more information on derivatives, see the [wiki](https://github.com/samvera-labs/newspaper_works/wiki/Image-Format-and-Derivative-Notes).
|
121
122
|
|
122
123
|
# Developing, Testing, and Contributing
|
123
124
|
|
124
|
-
Detailed information regarding development and testing environments setup and configuration can be found [here](
|
125
|
+
Detailed information regarding development and testing environments setup and configuration can be found [here](https://github.com/samvera-labs/newspaper_works/wiki/Installing,-Developing,-and-Testing)
|
125
126
|
|
126
|
-
A Vagrant VM is available for users and developers to quickly and easily deploy the latest NewspaperWorks codebase using Vagrant and VirtualBox. See [samvera-newspapers-vagrant](https://github.com/
|
127
|
+
A Vagrant VM is available for users and developers to quickly and easily deploy the latest NewspaperWorks codebase using Vagrant and VirtualBox. See [samvera-newspapers-vagrant](https://github.com/samvera-labs/samvera-newspapers-vagrant) for more.
|
127
128
|
|
128
129
|
Additionally, the [NewspaperWorks Demo Site](https://newspaperworks.digitalnewspapers.org/) is available for those interested in testing out NewspaperWorks as deployed in a vanilla Hyrax application. (**NOTE:** The demo site may not be running the latest release of NewspaperWorks.)
|
129
130
|
|
@@ -22,13 +22,11 @@ module NewspaperWorks
|
|
22
22
|
# Target file extension of this service plugin:
|
23
23
|
TARGET_EXT = 'jp2'.freeze
|
24
24
|
|
25
|
-
attr_accessor :source_meta
|
26
25
|
attr_reader :file_set
|
27
26
|
delegate :uri, :mime_type, to: :file_set
|
28
27
|
|
29
28
|
def initialize(file_set)
|
30
29
|
# cached result string for imagemagick `identify` command
|
31
|
-
@source_meta = nil
|
32
30
|
@command = nil
|
33
31
|
@unlink_after_creation = []
|
34
32
|
super(file_set)
|
@@ -66,7 +64,7 @@ module NewspaperWorks
|
|
66
64
|
# source introspection:
|
67
65
|
|
68
66
|
def tiff_source?
|
69
|
-
identify
|
67
|
+
identify[:content_type] == 'image/tiff'
|
70
68
|
end
|
71
69
|
|
72
70
|
def make_symlink
|
@@ -2,7 +2,7 @@ module NewspaperWorks
|
|
2
2
|
# Base type for derivative services specific to NewspaperPage only
|
3
3
|
class NewspaperPageDerivativeService
|
4
4
|
attr_reader :file_set, :master_format
|
5
|
-
delegate :uri,
|
5
|
+
delegate :uri, to: :file_set
|
6
6
|
|
7
7
|
TARGET_EXT = nil
|
8
8
|
|
@@ -47,27 +47,21 @@ module NewspaperWorks
|
|
47
47
|
end
|
48
48
|
|
49
49
|
def identify
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
Open3.popen3(cmd) do |_stdin, stdout, _stderr, _wait_thr|
|
57
|
-
@source_meta = stdout.read
|
58
|
-
end
|
59
|
-
end
|
60
|
-
@source_meta
|
50
|
+
return @source_meta unless @source_meta.nil?
|
51
|
+
@source_meta = NewspaperWorks::ImageTool.new(@source_path).metadata
|
52
|
+
end
|
53
|
+
|
54
|
+
def mime_type
|
55
|
+
identify[:content_type]
|
61
56
|
end
|
62
57
|
|
63
58
|
def use_color?
|
64
|
-
|
65
|
-
!(identify.include?('Gray') || one_bit?)
|
59
|
+
identify[:color] == 'color'
|
66
60
|
end
|
67
61
|
|
68
62
|
# is source one-bit monochrome?
|
69
63
|
def one_bit?
|
70
|
-
identify
|
64
|
+
identify[:color] == 'monochrome'
|
71
65
|
end
|
72
66
|
|
73
67
|
def create_derivatives(filename)
|
@@ -86,6 +80,34 @@ module NewspaperWorks
|
|
86
80
|
end
|
87
81
|
end
|
88
82
|
|
83
|
+
def jp2_to_intermediate
|
84
|
+
intermediate_path = File.join(Dir.mktmpdir, 'intermediate.tif')
|
85
|
+
jp2_cmd = "opj_decompress -i #{@source_path} -o #{intermediate_path}"
|
86
|
+
# make intermediate, then...
|
87
|
+
`#{jp2_cmd}`
|
88
|
+
intermediate_path
|
89
|
+
end
|
90
|
+
|
91
|
+
def convert_cmd
|
92
|
+
raise NotImplementedError, 'Calling subclass missing convert_cmd method'
|
93
|
+
end
|
94
|
+
|
95
|
+
# convert non-JP2 source/primary file to PDF derivative with ImageMagick6
|
96
|
+
# calls convert_cmd on calling subclasses
|
97
|
+
def im_convert
|
98
|
+
`#{convert_cmd}`
|
99
|
+
end
|
100
|
+
|
101
|
+
# convert JP2 source/primary file to PDF derivative, via
|
102
|
+
# opj_decompress to intermediate TIFF, then ImageMagick6 convert
|
103
|
+
def jp2_convert
|
104
|
+
# jp2 source -> intermediate
|
105
|
+
intermediate_path = jp2_to_intermediate
|
106
|
+
@source_path = intermediate_path
|
107
|
+
# intermediate -> PDF
|
108
|
+
im_convert
|
109
|
+
end
|
110
|
+
|
89
111
|
# def cleanup_derivatives; end
|
90
112
|
end
|
91
113
|
end
|
@@ -16,9 +16,6 @@ module NewspaperWorks
|
|
16
16
|
'-depth 8 ' \
|
17
17
|
'-compress jpeg %<out_file>s'.freeze
|
18
18
|
|
19
|
-
# graphicsmagick prefix, may be needed for jp2 source on Ubuntu
|
20
|
-
GM_PREFX = 'gm '.freeze
|
21
|
-
|
22
19
|
def initialize(file_set)
|
23
20
|
super(file_set)
|
24
21
|
end
|
@@ -27,8 +24,7 @@ module NewspaperWorks
|
|
27
24
|
# JP2 source, and whether we have color or grayscale material.
|
28
25
|
def convert_cmd
|
29
26
|
template = use_color? ? COLOR_PDF_CMD : GRAY_PDF_CMD
|
30
|
-
|
31
|
-
@source_path.ends_with?('jp2') ? GM_PREFIX + cmd : cmd
|
27
|
+
format(template, source_file: @source_path, out_file: @dest_path)
|
32
28
|
end
|
33
29
|
|
34
30
|
def create_derivatives(filename)
|
@@ -38,8 +34,9 @@ module NewspaperWorks
|
|
38
34
|
# no creation if pdf master
|
39
35
|
return if mime_type == 'application/pdf'
|
40
36
|
|
41
|
-
# Get and run
|
42
|
-
|
37
|
+
# Get and run conversion command
|
38
|
+
return jp2_convert if mime_type == 'image/jp2'
|
39
|
+
im_convert
|
43
40
|
end
|
44
41
|
end
|
45
42
|
end
|
@@ -21,9 +21,6 @@ module NewspaperWorks
|
|
21
21
|
'-depth 24 ' \
|
22
22
|
'-compress lzw %<out_file>s'.freeze
|
23
23
|
|
24
|
-
# graphicsmagick prefix, may be needed for jp2 source on Ubuntu
|
25
|
-
GM_PREFX = 'gm '.freeze
|
26
|
-
|
27
24
|
def initialize(file_set)
|
28
25
|
super(file_set)
|
29
26
|
end
|
@@ -35,20 +32,19 @@ module NewspaperWorks
|
|
35
32
|
source_path += '[0]' if @source_path.ends_with?('pdf')
|
36
33
|
template = use_color? ? COLOR_CMD : GRAY_CMD
|
37
34
|
template = MONO_CMD if one_bit?
|
38
|
-
|
39
|
-
# normalization of command based on source
|
40
|
-
@source_path.ends_with?('jp2') ? GM_PREFIX + cmd : cmd
|
35
|
+
format(template, source_file: source_path, out_file: @dest_path)
|
41
36
|
end
|
42
37
|
|
43
38
|
def create_derivatives(filename)
|
44
39
|
# Base class takes care of loading @source_path, @dest_path
|
45
40
|
super(filename)
|
46
41
|
|
47
|
-
# no creation if
|
42
|
+
# no creation of TIFF deriviative if primary is TIFF
|
48
43
|
return if mime_type == 'image/tiff'
|
49
44
|
|
50
|
-
|
51
|
-
|
45
|
+
return jp2_convert if mime_type == 'image/jp2'
|
46
|
+
# Otherwise, get, run imagemagick command to convert
|
47
|
+
im_convert
|
52
48
|
end
|
53
49
|
end
|
54
50
|
end
|
@@ -1,34 +1,82 @@
|
|
1
1
|
<%# newspaper_core_metadata attributes %>
|
2
2
|
<%= presenter.attribute_to_html(:date_modified, label: t('hyrax.base.show.last_modified'), html_dl: true) %>
|
3
|
-
<%= presenter.attribute_to_html(:alternative_title,
|
4
|
-
|
3
|
+
<%= presenter.attribute_to_html(:alternative_title,
|
4
|
+
label: t('newspaper_works.attributes.alternative_title.label'),
|
5
|
+
html_dl: true) %>
|
6
|
+
<%= presenter.attribute_to_html(:genre,
|
7
|
+
label: t('newspaper_works.attributes.genre.label'),
|
8
|
+
render_as: :faceted, html_dl: true) %>
|
9
|
+
<%= presenter.attribute_to_html(:publication_title,
|
10
|
+
label: t('newspaper_works.attributes.publication_title.label'),
|
11
|
+
render_as: :faceted, html_dl: true) %>
|
5
12
|
<%= presenter.attribute_to_html(:place_of_publication_label,
|
6
|
-
label:
|
13
|
+
label: t('newspaper_works.attributes.place_of_publication.label'),
|
14
|
+
render_as: :faceted, html_dl: true) %>
|
15
|
+
<%= presenter.attribute_to_html(:issn,
|
16
|
+
label: t('newspaper_works.attributes.issn.label'),
|
17
|
+
render_as: :faceted, html_dl: true) %>
|
18
|
+
<%= presenter.attribute_to_html(:lccn,
|
19
|
+
label: t('newspaper_works.attributes.lccn.label'),
|
20
|
+
render_as: :faceted, html_dl: true) %>
|
21
|
+
<%= presenter.attribute_to_html(:oclcnum,
|
22
|
+
label: t('newspaper_works.attributes.oclcnum.label'),
|
23
|
+
render_as: :faceted, html_dl: true) %>
|
24
|
+
<%= presenter.attribute_to_html(:held_by,
|
25
|
+
label: t('newspaper_works.attributes.held_by.label'),
|
7
26
|
render_as: :faceted, html_dl: true) %>
|
8
|
-
<%= presenter.attribute_to_html(:issn, render_as: :faceted, html_dl: true) %>
|
9
|
-
<%= presenter.attribute_to_html(:lccn, render_as: :faceted, html_dl: true) %>
|
10
|
-
<%= presenter.attribute_to_html(:oclcnum, render_as: :faceted, html_dl: true) %>
|
11
|
-
<%= presenter.attribute_to_html(:held_by, render_as: :faceted, html_dl: true) %>
|
12
27
|
<%# scanned_media_metadata attributes %>
|
13
|
-
<%= presenter.attribute_to_html(:text_direction,
|
14
|
-
|
15
|
-
|
28
|
+
<%= presenter.attribute_to_html(:text_direction,
|
29
|
+
label: t('newspaper_works.attributes.text_direction.label'),
|
30
|
+
html_dl: true) %>
|
31
|
+
<%= presenter.attribute_to_html(:page_number,
|
32
|
+
label: t('newspaper_works.attributes.page_number.label'),
|
33
|
+
html_dl: true) %>
|
34
|
+
<%= presenter.attribute_to_html(:section,
|
35
|
+
label: t('newspaper_works.attributes.section.label'),
|
36
|
+
html_dl: true) %>
|
16
37
|
<%# newspaper_article attributes %>
|
17
|
-
<%= presenter.attribute_to_html(:author,
|
18
|
-
|
19
|
-
|
20
|
-
<%= presenter.attribute_to_html(:
|
21
|
-
|
22
|
-
|
23
|
-
<%= presenter.attribute_to_html(:
|
38
|
+
<%= presenter.attribute_to_html(:author,
|
39
|
+
label: t('newspaper_works.attributes.author.label'),
|
40
|
+
render_as: :faceted, html_dl: true) %>
|
41
|
+
<%= presenter.attribute_to_html(:photographer,
|
42
|
+
label: t('newspaper_works.attributes.photographer.label'),
|
43
|
+
render_as: :faceted, html_dl: true) %>
|
44
|
+
<%= presenter.attribute_to_html(:volume,
|
45
|
+
label: t('newspaper_works.attributes.volume.label'),
|
46
|
+
html_dl: true) %>
|
47
|
+
<%= presenter.attribute_to_html(:issue_number,
|
48
|
+
label: t('newspaper_works.attributes.issue_number.label'),
|
49
|
+
html_dl: true) %>
|
50
|
+
<%= presenter.attribute_to_html(:geographic_coverage,
|
51
|
+
label: t('newspaper_works.attributes.geographic_coverage.label'),
|
52
|
+
render_as: :faceted, html_dl: true) %>
|
53
|
+
<%= presenter.attribute_to_html(:extent,
|
54
|
+
label: t('newspaper_works.attributes.extent.label'),html_dl: true) %>
|
55
|
+
<%= presenter.attribute_to_html(:publication_date,
|
56
|
+
label: t('newspaper_works.attributes.publication_date.label'),
|
57
|
+
render_as: :date, html_dl: true) %>
|
24
58
|
<%# newspaper_title attributes %>
|
25
|
-
<%= presenter.attribute_to_html(:edition_number,
|
26
|
-
|
27
|
-
|
28
|
-
<%= presenter.attribute_to_html(:
|
29
|
-
|
30
|
-
|
31
|
-
<%= presenter.attribute_to_html(:
|
59
|
+
<%= presenter.attribute_to_html(:edition_number,
|
60
|
+
label: t('newspaper_works.attributes.edition_number.label'),
|
61
|
+
html_dl: true) %>
|
62
|
+
<%= presenter.attribute_to_html(:edition_name,
|
63
|
+
label: t('newspaper_works.attributes.edition_name.label'),
|
64
|
+
html_dl: true) %>
|
65
|
+
<%= presenter.attribute_to_html(:frequency,
|
66
|
+
label: t('newspaper_works.attributes.frequency.label'),
|
67
|
+
html_dl: true) %>
|
68
|
+
<%= presenter.attribute_to_html(:preceded_by,
|
69
|
+
label: t('newspaper_works.attributes.preceded_by.label'),
|
70
|
+
render_as: :faceted, html_dl: true) %>
|
71
|
+
<%= presenter.attribute_to_html(:succeeded_by,
|
72
|
+
label: t('newspaper_works.attributes.succeeded_by.label'),
|
73
|
+
render_as: :faceted, html_dl: true) %>
|
74
|
+
<%= presenter.attribute_to_html(:publication_date_start,
|
75
|
+
label: t('newspaper_works.attributes.publication_date_start.label'),
|
76
|
+
render_as: :date, html_dl: true) %>
|
77
|
+
<%= presenter.attribute_to_html(:publication_date_end,
|
78
|
+
label: t('newspaper_works.attributes.publication_date_end.label'),
|
79
|
+
render_as: :date, html_dl: true) %>
|
32
80
|
<%# hyrax %>
|
33
81
|
<%= presenter.attribute_to_html(:creator, render_as: :faceted, html_dl: true) %>
|
34
82
|
<%= presenter.attribute_to_html(:contributor, render_as: :faceted, html_dl: true) %>
|