hyrax 2.0.3 → 2.1.0.beta1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.eslintrc +0 -1
- data/.github/CONTRIBUTING.md +1 -1
- data/.rubocop.yml +8 -4
- data/.rubocop_fixme.yml +20 -2
- data/.travis.yml +3 -3
- data/README.md +12 -4
- data/app/actors/hyrax/actors/abstract_actor.rb +1 -1
- data/app/actors/hyrax/actors/apply_permission_template_actor.rb +17 -1
- data/app/actors/hyrax/actors/attach_members_actor.rb +2 -2
- data/app/actors/hyrax/actors/collections_membership_actor.rb +147 -12
- data/app/actors/hyrax/actors/create_with_remote_files_actor.rb +15 -9
- data/app/actors/hyrax/actors/default_admin_set_actor.rb +3 -3
- data/app/actors/hyrax/actors/file_set_actor.rb +10 -6
- data/app/actors/hyrax/actors/interpret_visibility_actor.rb +1 -1
- data/app/assets/javascripts/hyrax.js +13 -7
- data/app/assets/javascripts/hyrax/admin/admin_set_controls.es6 +5 -3
- data/app/assets/javascripts/hyrax/admin/collection_type/participants.es6 +13 -0
- data/app/assets/javascripts/hyrax/admin/collection_type/settings.es6 +60 -0
- data/app/assets/javascripts/hyrax/admin/collection_type_controls.es6 +15 -0
- data/app/assets/javascripts/hyrax/app.js.erb +29 -7
- data/app/assets/javascripts/hyrax/autocomplete.es6 +10 -5
- data/app/assets/javascripts/hyrax/autocomplete/default.es6 +1 -1
- data/app/assets/javascripts/hyrax/autocomplete/linked_data.es6 +1 -1
- data/app/assets/javascripts/hyrax/autocomplete/{work.es6 → resource.es6} +10 -4
- data/app/assets/javascripts/hyrax/collection_types.es6 +65 -0
- data/app/assets/javascripts/hyrax/collections.js +168 -3
- data/app/assets/javascripts/hyrax/collections/editor.es6 +7 -1
- data/app/assets/javascripts/hyrax/collections_forms.js +108 -0
- data/app/assets/javascripts/hyrax/editor.es6 +17 -3
- data/app/assets/javascripts/hyrax/fileupload.js +1 -0
- data/app/assets/javascripts/hyrax/relationships.js +2 -1
- data/app/assets/javascripts/hyrax/relationships/confirm_remove_dialog.es6 +45 -0
- data/app/assets/javascripts/hyrax/relationships/control.es6 +25 -10
- data/app/assets/javascripts/hyrax/relationships/registry.es6 +28 -25
- data/app/assets/javascripts/hyrax/relationships/registry_entry.es6 +40 -33
- data/app/assets/javascripts/hyrax/relationships/resource.es6 +10 -0
- data/app/assets/javascripts/hyrax/select_collection_type.es6 +39 -0
- data/app/assets/javascripts/hyrax/{per_page.es6 → sort_and_per_page.es6} +1 -1
- data/app/assets/javascripts/hyrax/tabbed_form.es6 +35 -0
- data/app/assets/stylesheets/_bootstrap-default-overrides.scss +15 -0
- data/app/assets/stylesheets/fileupload/jquery.fileupload-ui.scss +6 -0
- data/app/assets/stylesheets/hyrax/_accessibility.scss +16 -0
- data/app/assets/stylesheets/hyrax/_catalog.scss +88 -1
- data/app/assets/stylesheets/hyrax/_collection_types.scss +53 -0
- data/app/assets/stylesheets/hyrax/_collections.scss +616 -22
- data/app/assets/stylesheets/hyrax/_featured.scss +16 -0
- data/app/assets/stylesheets/hyrax/_file-listing.scss +9 -2
- data/app/assets/stylesheets/hyrax/_forms.scss +46 -0
- data/app/assets/stylesheets/hyrax/_home-page.scss +10 -0
- data/app/assets/stylesheets/hyrax/_hyrax.scss +3 -2
- data/app/assets/stylesheets/hyrax/_positioning.scss +0 -11
- data/app/assets/stylesheets/hyrax/_recent.scss +26 -0
- data/app/assets/stylesheets/hyrax/_representative-media.scss +7 -0
- data/app/assets/stylesheets/hyrax/_select_collection_type.scss +45 -0
- data/app/assets/stylesheets/hyrax/_select_work_type.scss +0 -4
- data/app/assets/stylesheets/hyrax/_styles.scss +2 -17
- data/app/assets/stylesheets/hyrax/_variables.scss +2 -2
- data/app/assets/stylesheets/hyrax/_viewer.scss +8 -0
- data/app/assets/stylesheets/hyrax/_work-show.scss +44 -6
- data/app/assets/stylesheets/hyrax/dashboard.scss +7 -2
- data/app/authorities/qa/authorities/collections.rb +30 -0
- data/app/builders/hyrax/manifest_helper.rb +36 -0
- data/app/controllers/concerns/hyrax/admin/stats_behavior.rb +1 -1
- data/app/controllers/concerns/hyrax/admin/users_controller_behavior.rb +1 -1
- data/app/controllers/concerns/hyrax/collections_controller_behavior.rb +37 -40
- data/app/controllers/concerns/hyrax/controller.rb +0 -9
- data/app/controllers/concerns/hyrax/themed_layout_controller.rb +4 -1
- data/app/controllers/concerns/hyrax/works_controller_behavior.rb +22 -11
- data/app/controllers/hyrax/admin/admin_sets_controller.rb +24 -15
- data/app/controllers/hyrax/admin/appearances_controller.rb +1 -1
- data/app/controllers/hyrax/admin/collection_type_participants_controller.rb +44 -0
- data/app/controllers/hyrax/admin/collection_types_controller.rb +97 -0
- data/app/controllers/hyrax/admin/features_controller.rb +1 -1
- data/app/controllers/hyrax/admin/permission_template_accesses_controller.rb +55 -13
- data/app/controllers/hyrax/admin/permission_templates_controller.rb +66 -23
- data/app/controllers/hyrax/admin/workflow_roles_controller.rb +1 -1
- data/app/controllers/hyrax/admin/workflows_controller.rb +1 -1
- data/app/controllers/hyrax/batch_edits_controller.rb +1 -1
- data/app/controllers/hyrax/batch_uploads_controller.rb +1 -1
- data/app/controllers/hyrax/citations_controller.rb +3 -12
- data/app/controllers/hyrax/collections_controller.rb +8 -9
- data/app/controllers/hyrax/content_blocks_controller.rb +1 -1
- data/app/controllers/hyrax/dashboard/collection_members_controller.rb +73 -0
- data/app/controllers/hyrax/dashboard/collections_controller.rb +210 -54
- data/app/controllers/hyrax/dashboard/nest_collections_controller.rb +106 -0
- data/app/controllers/hyrax/dashboard/profiles_controller.rb +1 -1
- data/app/controllers/hyrax/dashboard/works_controller.rb +1 -9
- data/app/controllers/hyrax/dashboard_controller.rb +1 -1
- data/app/controllers/hyrax/file_sets_controller.rb +7 -75
- data/app/controllers/hyrax/my/collections_controller.rb +26 -1
- data/app/controllers/hyrax/my/works_controller.rb +16 -1
- data/app/controllers/hyrax/my_controller.rb +5 -19
- data/app/controllers/hyrax/notifications_controller.rb +1 -1
- data/app/controllers/hyrax/pages_controller.rb +3 -2
- data/app/controllers/hyrax/stats_controller.rb +3 -0
- data/app/controllers/hyrax/transfers_controller.rb +1 -1
- data/app/forms/hyrax/forms/admin/appearance.rb +2 -2
- data/app/forms/hyrax/forms/admin/collection_type_form.rb +24 -0
- data/app/forms/hyrax/forms/admin/collection_type_participant_form.rb +16 -0
- data/app/forms/hyrax/forms/admin_set_form.rb +1 -1
- data/app/forms/hyrax/forms/batch_edit_form.rb +28 -7
- data/app/forms/hyrax/forms/collection_form.rb +71 -13
- data/app/forms/hyrax/forms/dashboard/nest_collection_form.rb +98 -0
- data/app/forms/hyrax/forms/permission_template_form.rb +13 -13
- data/app/forms/hyrax/forms/work_form.rb +58 -14
- data/app/helpers/hyrax/ability_helper.rb +3 -0
- data/app/helpers/hyrax/citations_behaviors/formatters/chicago_formatter.rb +3 -10
- data/app/helpers/hyrax/collections_helper.rb +10 -2
- data/app/helpers/hyrax/dashboard_helper_behavior.rb +0 -4
- data/app/helpers/hyrax/hyrax_helper_behavior.rb +19 -5
- data/app/helpers/hyrax/trophy_helper.rb +0 -1
- data/app/indexers/hyrax/indexes_workflow.rb +1 -1
- data/app/indexers/hyrax/repository_reindexer.rb +19 -0
- data/app/jobs/hyrax/application_job.rb +1 -1
- data/app/jobs/import_export_job.rb +1 -1
- data/app/jobs/user_edit_profile_event_job.rb +1 -1
- data/app/models/admin_set.rb +5 -2
- data/app/models/collection_branding_info.rb +39 -0
- data/app/models/concerns/hyrax/ability.rb +26 -49
- data/app/models/concerns/hyrax/ability/admin_set_ability.rb +40 -0
- data/app/models/concerns/hyrax/ability/collection_ability.rb +40 -0
- data/app/models/concerns/hyrax/ability/collection_type_ability.rb +16 -0
- data/app/models/concerns/hyrax/ability/permission_template_ability.rb +18 -0
- data/app/models/concerns/hyrax/ability/solr_document_ability.rb +18 -0
- data/app/models/concerns/hyrax/collection_behavior.rb +86 -3
- data/app/models/concerns/hyrax/collection_nesting.rb +41 -0
- data/app/models/concerns/hyrax/file_set/belongs_to_works.rb +0 -15
- data/app/models/concerns/hyrax/file_set_behavior.rb +0 -1
- data/app/models/concerns/hyrax/has_rendering.rb +11 -0
- data/app/models/concerns/hyrax/human_readable_type.rb +3 -0
- data/app/models/concerns/hyrax/solr_document/metadata.rb +3 -0
- data/app/models/concerns/hyrax/solr_document_behavior.rb +8 -2
- data/app/models/concerns/hyrax/user.rb +11 -6
- data/app/models/concerns/hyrax/with_events.rb +12 -6
- data/app/models/concerns/hyrax/work_behavior.rb +3 -1
- data/app/models/hyrax/batch_create_operation.rb +1 -1
- data/app/models/hyrax/collection_type.rb +155 -0
- data/app/models/hyrax/collection_type_participant.rb +39 -0
- data/app/models/hyrax/operation.rb +14 -2
- data/app/models/hyrax/permission_template.rb +23 -1
- data/app/models/hyrax/permission_template_access.rb +56 -7
- data/app/models/hyrax/uploaded_file.rb +4 -1
- data/app/models/sipity/workflow.rb +6 -4
- data/app/presenters/hyrax/admin/workflow_role_presenter.rb +3 -3
- data/app/presenters/hyrax/admin_set_options_presenter.rb +1 -1
- data/app/presenters/hyrax/admin_set_presenter.rb +16 -0
- data/app/presenters/hyrax/collection_options_presenter.rb +1 -0
- data/app/presenters/hyrax/collection_presenter.rb +134 -6
- data/app/presenters/hyrax/displays_image.rb +39 -0
- data/app/presenters/hyrax/file_set_presenter.rb +1 -4
- data/app/presenters/hyrax/fixity_status_presenter.rb +2 -2
- data/app/presenters/hyrax/homepage_presenter.rb +20 -0
- data/app/presenters/hyrax/menu_presenter.rb +2 -1
- data/app/presenters/hyrax/select_collection_type_list_presenter.rb +42 -0
- data/app/presenters/hyrax/select_collection_type_presenter.rb +11 -0
- data/app/presenters/hyrax/select_type_presenter.rb +13 -4
- data/app/presenters/hyrax/work_show_presenter.rb +52 -1
- data/app/renderers/hyrax/renderers/attribute_renderer.rb +1 -1
- data/app/renderers/hyrax/renderers/license_attribute_renderer.rb +1 -1
- data/app/renderers/hyrax/renderers/rights_statement_attribute_renderer.rb +3 -2
- data/app/search_builders/hyrax/admin_admin_set_member_search_builder.rb +10 -1
- data/app/search_builders/hyrax/admin_set_search_builder.rb +9 -2
- data/app/search_builders/hyrax/collection_member_search_builder.rb +21 -8
- data/app/search_builders/hyrax/collection_search_builder.rb +37 -0
- data/app/search_builders/hyrax/dashboard/collections_search_builder.rb +42 -0
- data/app/search_builders/hyrax/dashboard/managed_search_filters.rb +24 -0
- data/app/search_builders/hyrax/dashboard/nested_collections_search_builder.rb +123 -0
- data/app/search_builders/hyrax/dashboard/works_search_builder.rb +18 -0
- data/app/search_builders/hyrax/filter_suppressed_with_roles.rb +5 -1
- data/app/search_builders/hyrax/my/collections_search_builder.rb +20 -3
- data/app/search_builders/hyrax/nested_collections_parent_search_builder.rb +27 -0
- data/app/search_builders/hyrax/search_filters.rb +8 -0
- data/app/services/hyrax/adapters/nesting_index_adapter.rb +192 -0
- data/app/services/hyrax/admin_set_create_service.rb +3 -2
- data/app/services/hyrax/admin_set_member_service.rb +40 -0
- data/app/services/hyrax/batch_create_failure_service.rb +4 -3
- data/app/services/hyrax/collection_types/create_service.rb +143 -0
- data/app/services/hyrax/collection_types/permissions_service.rb +233 -0
- data/app/services/hyrax/collections/collection_member_service.rb +91 -0
- data/app/services/hyrax/collections/managed_collections_service.rb +16 -0
- data/app/services/hyrax/collections/migration_service.rb +81 -0
- data/app/services/hyrax/collections/nested_collection_persistence_service.rb +26 -0
- data/app/services/hyrax/collections/nested_collection_query_service.rb +187 -0
- data/app/services/hyrax/collections/permissions_create_service.rb +71 -0
- data/app/services/hyrax/collections/permissions_service.rb +234 -0
- data/app/services/hyrax/collections_service.rb +3 -3
- data/app/services/hyrax/default_middleware_stack.rb +35 -0
- data/app/services/hyrax/file_set_fixity_check_service.rb +1 -1
- data/app/services/hyrax/graph_exporter.rb +19 -15
- data/app/services/hyrax/iiif_authorization_service.rb +19 -0
- data/app/services/hyrax/multiple_membership_checker.rb +78 -0
- data/app/services/hyrax/noid.rb +1 -3
- data/app/services/hyrax/qa_select_service.rb +11 -2
- data/app/services/hyrax/workflow/status_list_service.rb +1 -1
- data/app/services/hyrax/working_directory.rb +0 -8
- data/app/services/hyrax/works/managed_works_service.rb +16 -0
- data/app/views/_flash_msg.html.erb +1 -1
- data/app/views/_masthead.html.erb +0 -1
- data/app/views/catalog/_document.html.erb +3 -1
- data/app/views/catalog/_document_list.html.erb +2 -2
- data/app/views/catalog/_index_header_list_collection.html.erb +4 -3
- data/app/views/catalog/_index_header_list_default.html.erb +3 -3
- data/app/views/catalog/_index_list_default.html.erb +29 -14
- data/app/views/catalog/_thumbnail_list_collection.html.erb +3 -4
- data/app/views/catalog/_thumbnail_list_default.html.erb +5 -3
- data/app/views/hyrax/admin/admin_sets/_form.html.erb +2 -1
- data/app/views/hyrax/admin/admin_sets/_form_participant_table.html.erb +1 -1
- data/app/views/hyrax/admin/admin_sets/_form_participants.html.erb +1 -1
- data/app/views/hyrax/admin/admin_sets/_show_document_list_row.html.erb +3 -3
- data/app/views/hyrax/admin/admin_sets/edit.html.erb +1 -1
- data/app/views/hyrax/admin/collection_types/_form.html.erb +61 -0
- data/app/views/hyrax/admin/collection_types/_form_metadata.html.erb +2 -0
- data/app/views/hyrax/admin/collection_types/_form_metadata_admin_set.html.erb +2 -0
- data/app/views/hyrax/admin/collection_types/_form_participant_table.html.erb +26 -0
- data/app/views/hyrax/admin/collection_types/_form_participants.html.erb +62 -0
- data/app/views/hyrax/admin/collection_types/_form_settings.html.erb +39 -0
- data/app/views/hyrax/admin/collection_types/edit.html.erb +10 -0
- data/app/views/hyrax/admin/collection_types/index.html.erb +88 -0
- data/app/views/hyrax/admin/collection_types/new.html.erb +10 -0
- data/app/views/hyrax/base/_attribute_rows.html.erb +1 -0
- data/app/views/hyrax/base/_citations.html.erb +10 -6
- data/app/views/hyrax/base/_form_child_work_relationships.html.erb +22 -29
- data/app/views/hyrax/base/_form_files.html.erb +29 -16
- data/app/views/hyrax/base/_form_media.html.erb +1 -0
- data/app/views/hyrax/base/_form_member_of_collections.html.erb +44 -6
- data/app/views/hyrax/base/_form_metadata.html.erb +0 -3
- data/app/views/hyrax/base/_form_progress.html.erb +2 -1
- data/app/views/hyrax/base/_form_relationships.html.erb +3 -2
- data/app/views/hyrax/base/_form_rendering.html.erb +14 -0
- data/app/views/hyrax/base/_form_representative.html.erb +2 -2
- data/app/views/hyrax/base/_form_share.html.erb +44 -41
- data/app/views/hyrax/base/_form_thumbnail.html.erb +2 -2
- data/app/views/hyrax/base/_guts4form.html.erb +2 -2
- data/app/views/hyrax/base/_member.html.erb +3 -4
- data/app/views/hyrax/base/_metadata.html.erb +1 -5
- data/app/views/hyrax/base/_relationships.html.erb +1 -1
- data/app/views/hyrax/base/_relationships_parent_row.html.erb +1 -1
- data/app/views/hyrax/base/_representative_media.html.erb +8 -2
- data/app/views/hyrax/base/_work_title.erb +14 -7
- data/app/views/hyrax/base/_work_type.html.erb +4 -0
- data/app/views/hyrax/base/_workflow_actions.html.erb +7 -7
- data/app/views/hyrax/base/_workflow_actions_widget.erb +4 -2
- data/app/views/hyrax/base/show.html.erb +35 -26
- data/app/views/hyrax/batch_edits/edit.html.erb +1 -1
- data/app/views/hyrax/collections/_collection_description.erb +1 -1
- data/app/views/hyrax/collections/_default_group.html.erb +9 -11
- data/app/views/hyrax/collections/_list_collections.html.erb +19 -12
- data/app/views/hyrax/collections/_paginate.html.erb +5 -4
- data/app/views/hyrax/collections/_search_form.html.erb +1 -1
- data/app/views/hyrax/collections/_search_results.html.erb +0 -2
- data/app/views/hyrax/collections/_show_descriptions.html.erb +7 -6
- data/app/views/hyrax/collections/_show_document_list.html.erb +3 -3
- data/app/views/hyrax/collections/_show_document_list_row.html.erb +3 -3
- data/app/views/hyrax/collections/_show_parent_collections.html.erb +41 -0
- data/app/views/hyrax/collections/_sort_and_per_page.html.erb +16 -24
- data/app/views/hyrax/collections/_subcollection_list.html.erb +13 -0
- data/app/views/hyrax/collections/_view_type_group.html.erb +1 -1
- data/app/views/hyrax/collections/show.html.erb +120 -31
- data/app/views/hyrax/dashboard/collections/_button_for_batch_delete_collection.html.erb +4 -0
- data/app/views/hyrax/dashboard/collections/_button_for_remove_selected_from_collection.html.erb +0 -1
- data/app/views/hyrax/dashboard/collections/_button_for_update_collection.html.erb +1 -1
- data/app/views/hyrax/dashboard/collections/_button_remove_from_collection.html.erb +1 -1
- data/app/views/hyrax/dashboard/collections/_collection_title.html.erb +25 -0
- data/app/views/hyrax/dashboard/collections/_document_list.html.erb +1 -5
- data/app/views/hyrax/dashboard/collections/_edit_actions.html.erb +2 -2
- data/app/views/hyrax/dashboard/collections/_flash_msg.html.erb +9 -0
- data/app/views/hyrax/dashboard/collections/_form.html.erb +46 -24
- data/app/views/hyrax/dashboard/collections/_form_branding.html.erb +153 -0
- data/app/views/hyrax/dashboard/collections/_form_default_group_delt.html.erb +27 -0
- data/app/views/hyrax/dashboard/collections/_form_discovery.html.erb +18 -0
- data/app/views/hyrax/dashboard/collections/_form_share.html.erb +69 -81
- data/app/views/hyrax/dashboard/collections/_form_share_table.html.erb +31 -0
- data/app/views/hyrax/dashboard/collections/_list_collections.html.erb +54 -37
- data/app/views/hyrax/dashboard/collections/_modal_remove_from_collection.html.erb +17 -0
- data/app/views/hyrax/dashboard/collections/_modal_remove_sub_collection.html.erb +17 -0
- data/app/views/hyrax/dashboard/collections/_show_actions.html.erb +27 -21
- data/app/views/hyrax/dashboard/collections/_show_add_items_actions.html.erb +25 -0
- data/app/views/hyrax/dashboard/collections/_show_document_list.html.erb +4 -3
- data/app/views/hyrax/dashboard/collections/_show_document_list_row.html.erb +6 -5
- data/app/views/hyrax/dashboard/collections/_show_parent_collection_row.html.erb +6 -0
- data/app/views/hyrax/dashboard/collections/_show_parent_collections.html.erb +37 -0
- data/app/views/hyrax/dashboard/collections/_show_subcollection_actions.html.erb +26 -0
- data/app/views/hyrax/dashboard/collections/_sort_and_per_page.html.erb +28 -27
- data/app/views/hyrax/dashboard/collections/_subcollection_list.html.erb +21 -0
- data/app/views/hyrax/dashboard/collections/_work_action_menu.html.erb +1 -1
- data/app/views/hyrax/dashboard/collections/edit.html.erb +8 -31
- data/app/views/hyrax/dashboard/collections/new.html.erb +2 -3
- data/app/views/hyrax/dashboard/collections/show.html.erb +102 -35
- data/app/views/hyrax/dashboard/sidebar/_configuration.html.erb +5 -0
- data/app/views/hyrax/dashboard/sidebar/_repository_content.html.erb +0 -5
- data/app/views/hyrax/dashboard/sidebar/_tasks.html.erb +10 -0
- data/app/views/hyrax/dashboard/works/_default_group.html.erb +1 -0
- data/app/views/hyrax/dashboard/works/_list_works.html.erb +4 -0
- data/app/views/hyrax/file_sets/_extra_fields_modal.html.erb +1 -1
- data/app/views/hyrax/file_sets/_form.html.erb +2 -2
- data/app/views/hyrax/file_sets/_show_characterization_details.html.erb +1 -1
- data/app/views/hyrax/file_sets/media_display/_image.html.erb +3 -5
- data/app/views/hyrax/file_sets/media_display/_office_document.html.erb +3 -5
- data/app/views/hyrax/file_sets/media_display/_pdf.html.erb +3 -5
- data/app/views/hyrax/homepage/_featured.html.erb +5 -5
- data/app/views/hyrax/homepage/_featured_fields.html.erb +10 -14
- data/app/views/hyrax/homepage/_featured_works.html.erb +1 -1
- data/app/views/hyrax/homepage/_home_content.html.erb +2 -2
- data/app/views/hyrax/homepage/_recent_document.html.erb +14 -12
- data/app/views/hyrax/homepage/_recently_uploaded.html.erb +2 -6
- data/app/views/hyrax/homepage/index.html.erb +4 -2
- data/app/views/hyrax/my/_admin_set_action_menu.html.erb +54 -0
- data/app/views/hyrax/my/_collection_action_menu.html.erb +41 -9
- data/app/views/hyrax/my/_facet_pivot.html.erb +26 -0
- data/app/views/hyrax/my/_search_header.html.erb +1 -15
- data/app/views/hyrax/my/_sort_and_per_page.html.erb +12 -13
- data/app/views/hyrax/my/_work_action_menu.html.erb +17 -15
- data/app/views/hyrax/my/collections/_batch_actions.html.erb +5 -0
- data/app/views/hyrax/my/collections/_default_group.html.erb +21 -12
- data/app/views/hyrax/my/collections/_list_collections.html.erb +57 -35
- data/app/views/hyrax/my/collections/_modal_add_subcollection.html.erb +38 -0
- data/app/views/hyrax/my/collections/_modal_add_to_collection.html.erb +31 -0
- data/app/views/hyrax/my/collections/_modal_add_to_collection_deny.html.erb +12 -0
- data/app/views/hyrax/my/collections/_modal_add_to_collection_permission_deny.html.erb +12 -0
- data/app/views/hyrax/my/collections/_modal_collection_types_to_create.html.erb +36 -0
- data/app/views/hyrax/my/collections/_modal_delete_admin_set_deny.html.erb +12 -0
- data/app/views/hyrax/my/collections/_modal_delete_collection.html.erb +19 -0
- data/app/views/hyrax/my/collections/_modal_delete_collection_deny.html.erb +14 -0
- data/app/views/hyrax/my/collections/_modal_delete_deny.html.erb +14 -0
- data/app/views/hyrax/my/collections/_modal_delete_empty_collection.html.erb +18 -0
- data/app/views/hyrax/my/collections/_modal_delete_selected_collections.html.erb +17 -0
- data/app/views/hyrax/my/collections/_modal_edit_deny.html.erb +14 -0
- data/app/views/hyrax/my/collections/_tabs.html.erb +3 -3
- data/app/views/hyrax/my/collections/index.html.erb +46 -21
- data/app/views/hyrax/my/works/_batch_actions.html.erb +14 -0
- data/app/views/hyrax/my/works/_default_group.html.erb +10 -12
- data/app/views/hyrax/my/works/_tabs.html.erb +1 -1
- data/app/views/hyrax/my/works/index.html.erb +7 -5
- data/app/views/hyrax/notifications/_notifications.html.erb +3 -3
- data/app/views/hyrax/permissions/confirm_access.html.erb +1 -1
- data/app/views/hyrax/stats/file.html.erb +1 -1
- data/app/views/hyrax/stats/work.html.erb +1 -1
- data/app/views/hyrax/transfers/_received.html.erb +1 -1
- data/app/views/hyrax/transfers/_sent.html.erb +1 -1
- data/app/views/hyrax/uploads/_js_templates_branding.html.erb +120 -0
- data/app/views/hyrax/users/_activity_log.html.erb +3 -3
- data/app/views/kaminari/blacklight_compact/_paginator.html.erb +23 -0
- data/app/views/layouts/hyrax.html.erb +9 -11
- data/app/views/layouts/{dashboard.html.erb → hyrax/dashboard.html.erb} +0 -0
- data/app/views/shared/_select_work_type_modal.html.erb +25 -26
- data/config/features.rb +4 -0
- data/config/initializers/hyrax_callbacks.rb +2 -2
- data/config/initializers/samvera-nesting_indexer_initializer.rb +15 -0
- data/config/locales/hyrax.de.yml +364 -79
- data/config/locales/hyrax.en.yml +874 -584
- data/config/locales/hyrax.es.yml +323 -35
- data/config/locales/hyrax.fr.yml +323 -39
- data/config/locales/hyrax.it.yml +322 -39
- data/config/locales/hyrax.pt-BR.yml +317 -39
- data/config/locales/hyrax.zh.yml +420 -142
- data/config/routes.rb +17 -0
- data/hyrax.gemspec +58 -57
- data/lib/generators/hyrax/assets_generator.rb +2 -4
- data/lib/generators/hyrax/clamav_generator.rb +0 -2
- data/lib/generators/hyrax/config_generator.rb +0 -2
- data/lib/generators/hyrax/install_generator.rb +12 -3
- data/lib/generators/hyrax/riiif_generator.rb +54 -0
- data/lib/generators/hyrax/templates/app/assets/images/us_404.svg +91 -0
- data/lib/generators/hyrax/templates/config/initializers/hyrax.rb +48 -3
- data/lib/generators/hyrax/templates/config/initializers/riiif.rb +26 -0
- data/lib/generators/hyrax/templates/config/locales/hyrax.en.yml +4 -4
- data/lib/generators/hyrax/templates/config/locales/hyrax.fr.yml +0 -4
- data/lib/generators/hyrax/templates/db/migrate/20170808160431_create_collection_types.rb.erb +17 -0
- data/lib/generators/hyrax/templates/db/migrate/20170808160432_update_collection_type_column_names.rb.erb +9 -0
- data/lib/generators/hyrax/templates/db/migrate/20170810190549_update_collection_type_column_options.rb.erb +9 -0
- data/lib/generators/hyrax/templates/db/migrate/20170816180307_create_collection_branding_infos.rb.erb +15 -0
- data/lib/generators/hyrax/templates/db/migrate/20170817152654_create_collection_type_participants.rb.erb +11 -0
- data/lib/generators/hyrax/templates/db/migrate/20170821152307_rename_admin_set_id_to_source_id.rb.erb +5 -0
- data/lib/generators/hyrax/templates/db/migrate/20171103080032_add_collection_type_sharing_options.rb.erb +5 -0
- data/lib/generators/hyrax/templates/db/seeds.rb +226 -22
- data/lib/generators/hyrax/work/templates/controller.rb.erb +1 -1
- data/lib/generators/hyrax/work/templates/feature_spec.rb.erb +37 -1
- data/lib/generators/hyrax/work/templates/form.rb.erb +1 -0
- data/lib/generators/hyrax/work/templates/indexer.rb.erb +0 -1
- data/lib/generators/hyrax/work/templates/locale.de.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/locale.en.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/locale.es.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/locale.fr.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/locale.it.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/locale.pt-BR.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/locale.zh.yml.erb +1 -1
- data/lib/generators/hyrax/work/templates/model.rb.erb +0 -2
- data/lib/hyrax.rb +1 -1
- data/lib/hyrax/configuration.rb +96 -7
- data/lib/hyrax/engine.rb +5 -4
- data/lib/hyrax/rails/routes.rb +1 -1
- data/lib/hyrax/version.rb +1 -1
- data/lib/tasks/default_admin_set.rake +5 -3
- data/lib/tasks/default_collection_type.rake +19 -0
- data/lib/tasks/migrate.rake +8 -0
- data/spec/abilities/ability_spec.rb +4 -1
- data/spec/abilities/admin_set_ability_spec.rb +172 -0
- data/spec/abilities/collection_ability_spec.rb +194 -0
- data/spec/abilities/collection_type_ability_spec.rb +72 -0
- data/spec/abilities/file_set_abilities_spec.rb +3 -3
- data/spec/abilities/generic_work_abilities_spec.rb +5 -5
- data/spec/abilities/permission_template_ability_spec.rb +145 -0
- data/spec/abilities/solr_document_ability_spec.rb +27 -0
- data/spec/actors/hyrax/actors/apply_permission_template_actor_spec.rb +96 -28
- data/spec/actors/hyrax/actors/collections_membership_actor_spec.rb +283 -15
- data/spec/actors/hyrax/actors/create_with_remote_files_actor_spec.rb +7 -7
- data/spec/actors/hyrax/actors/default_admin_set_actor_spec.rb +1 -1
- data/spec/actors/hyrax/actors/file_actor_spec.rb +0 -1
- data/spec/actors/hyrax/actors/file_set_actor_spec.rb +8 -6
- data/spec/actors/hyrax/actors/generic_work_actor_spec.rb +11 -39
- data/spec/actors/hyrax/actors/interpret_visibility_actor_spec.rb +15 -15
- data/spec/actors/hyrax/actors/model_actor_spec.rb +0 -2
- data/spec/authorities/qa/authorities/collections_spec.rb +68 -0
- data/spec/channels/hyrax/application_cable/channel_spec.rb +1 -1
- data/spec/channels/hyrax/application_cable/connection_spec.rb +1 -1
- data/spec/channels/hyrax/notifications_channel_spec.rb +1 -1
- data/spec/controllers/catalog_controller_spec.rb +1 -1
- data/spec/controllers/hyrax/admin/admin_sets_controller_spec.rb +27 -1
- data/spec/controllers/hyrax/admin/collection_type_participants_controller_spec.rb +152 -0
- data/spec/controllers/hyrax/admin/collection_types_controller_spec.rb +320 -0
- data/spec/controllers/hyrax/admin/permission_template_accesses_controller_spec.rb +68 -29
- data/spec/controllers/hyrax/admin/permission_templates_controller_spec.rb +37 -10
- data/spec/controllers/hyrax/admin/strategies_controller_spec.rb +2 -13
- data/spec/controllers/hyrax/admin/workflow_roles_controller_spec.rb +52 -2
- data/spec/controllers/hyrax/batch_edits_controller_spec.rb +75 -4
- data/spec/controllers/hyrax/batch_uploads_controller_spec.rb +2 -2
- data/spec/controllers/hyrax/collections_controller_spec.rb +15 -6
- data/spec/controllers/hyrax/content_blocks_controller_spec.rb +5 -5
- data/spec/controllers/hyrax/dashboard/collection_members_controller_spec.rb +408 -0
- data/spec/controllers/hyrax/dashboard/collections_controller_spec.rb +114 -18
- data/spec/controllers/hyrax/dashboard/nest_collections_controller_spec.rb +360 -0
- data/spec/controllers/hyrax/dashboard/profiles_controller_spec.rb +2 -2
- data/spec/controllers/hyrax/dashboard/works_controller_spec.rb +1 -1
- data/spec/controllers/hyrax/downloads_controller_spec.rb +3 -3
- data/spec/controllers/hyrax/featured_work_lists_controller_spec.rb +2 -2
- data/spec/controllers/hyrax/file_sets_controller_spec.rb +8 -136
- data/spec/controllers/hyrax/fixity_checks_controller_spec.rb +1 -1
- data/spec/controllers/hyrax/generic_works_controller_spec.rb +64 -2
- data/spec/controllers/hyrax/homepage_controller_spec.rb +1 -1
- data/spec/controllers/hyrax/my/works_controller_spec.rb +4 -1
- data/spec/controllers/hyrax/pages_controller_spec.rb +11 -11
- data/spec/controllers/hyrax/users_controller_spec.rb +1 -1
- data/spec/controllers/hyrax/workflow_actions_controller_spec.rb +1 -1
- data/spec/conversions/power_converters/polymorphic_type_spec.rb +2 -2
- data/spec/conversions/power_converters/sipity_agent_spec.rb +1 -1
- data/spec/conversions/power_converters/sipity_role_spec.rb +1 -1
- data/spec/conversions/power_converters/sipity_workflow_state_spec.rb +1 -1
- data/spec/factories/admin_sets.rb +3 -3
- data/spec/factories/collection_branding_infos.rb +11 -0
- data/spec/factories/collection_type_participants.rb +8 -0
- data/spec/factories/collection_types.rb +104 -0
- data/spec/factories/collections.rb +323 -0
- data/spec/factories/collections_factory.rb +106 -3
- data/spec/factories/file_sets.rb +2 -2
- data/spec/factories/generic_works.rb +22 -14
- data/spec/factories/object_id.rb +6 -0
- data/spec/factories/permission_templates.rb +46 -8
- data/spec/factories/users.rb +1 -1
- data/spec/factory_tests/collections_factory_spec.rb +211 -0
- data/spec/features/admin_spec.rb +1 -1
- data/spec/features/batch_create_spec.rb +1 -1
- data/spec/features/batch_edit_spec.rb +0 -1
- data/spec/features/browse_catalog_spec.rb +1 -3
- data/spec/features/browse_dashboard_works_spec.rb +0 -1
- data/spec/features/collection_multi_membership_spec.rb +188 -0
- data/spec/features/collection_spec.rb +45 -7
- data/spec/features/collection_type_spec.rb +338 -0
- data/spec/features/create_child_work_spec.rb +1 -1
- data/spec/features/create_work_admin_spec.rb +44 -0
- data/spec/features/create_work_spec.rb +1 -1
- data/spec/features/dashboard/all_works.rb +1 -1
- data/spec/features/dashboard/collection_spec.rb +724 -115
- data/spec/features/delete_work_spec.rb +1 -1
- data/spec/features/edit_file_spec.rb +1 -1
- data/spec/features/edit_work_spec.rb +1 -1
- data/spec/features/embargo_spec.rb +1 -1
- data/spec/features/homepage_spec.rb +3 -3
- data/spec/features/lease_spec.rb +1 -1
- data/spec/features/notifications_spec.rb +2 -2
- data/spec/features/ownership_transfer_spec.rb +1 -2
- data/spec/features/proxy_spec.rb +1 -1
- data/spec/features/search_spec.rb +12 -11
- data/spec/features/static_pages_spec.rb +1 -1
- data/spec/features/users_spec.rb +1 -1
- data/spec/features/work_generator_spec.rb +1 -1
- data/spec/features/work_show_spec.rb +4 -4
- data/spec/features/workflow_roles_spec.rb +1 -1
- data/spec/features/workflow_state_changes_spec.rb +2 -2
- data/spec/forms/hyrax/forms/admin/collection_type_form_spec.rb +106 -0
- data/spec/forms/hyrax/forms/admin/collection_type_participant_form_spec.rb +10 -0
- data/spec/forms/hyrax/forms/admin_set_form_spec.rb +1 -1
- data/spec/forms/hyrax/forms/batch_edit_form_spec.rb +1 -1
- data/spec/forms/hyrax/forms/batch_upload_form_spec.rb +1 -0
- data/spec/forms/hyrax/forms/collection_form_spec.rb +52 -4
- data/spec/forms/hyrax/forms/dashboard/nest_collection_form_spec.rb +159 -0
- data/spec/forms/hyrax/forms/permission_template_form_spec.rb +15 -12
- data/spec/forms/hyrax/forms/work_form_spec.rb +61 -12
- data/spec/forms/hyrax/forms/workflow_action_form_spec.rb +1 -1
- data/spec/forms/hyrax/generic_work_form_spec.rb +6 -3
- data/spec/helpers/hyrax/ability_helper_spec.rb +11 -0
- data/spec/helpers/hyrax/collections_helper_spec.rb +17 -39
- data/spec/helpers/hyrax/content_block_helper_spec.rb +1 -1
- data/spec/helpers/{dashboard_helper_spec.rb → hyrax/dashboard_helper_behavior_spec.rb} +1 -12
- data/spec/helpers/hyrax/trophy_helper_spec.rb +1 -1
- data/spec/helpers/hyrax_helper_spec.rb +0 -3
- data/spec/indexers/hyrax/generic_work_indexer_spec.rb +4 -4
- data/spec/indexers/hyrax/repository_reindexer_spec.rb +8 -0
- data/spec/javascripts/relationships_control_spec.js.coffee +3 -3
- data/spec/javascripts/settings_spec.js +73 -0
- data/spec/jobs/user_edit_profile_event_job_spec.rb +1 -1
- data/spec/lib/hyrax/configuration_spec.rb +16 -0
- data/spec/models/admin_set_spec.rb +42 -4
- data/spec/models/collection_branding_info_spec.rb +61 -0
- data/spec/models/collection_spec.rb +228 -3
- data/spec/models/concerns/hyrax/collection_nesting_spec.rb +64 -0
- data/spec/models/file_set_spec.rb +4 -4
- data/spec/models/generic_work_spec.rb +1 -1
- data/spec/models/hyrax/batch_create_operation_spec.rb +59 -0
- data/spec/models/hyrax/collection_type_participant_spec.rb +43 -0
- data/spec/models/hyrax/collection_type_spec.rb +235 -0
- data/spec/models/hyrax/operation_spec.rb +27 -1
- data/spec/models/hyrax/permission_template_access_spec.rb +128 -5
- data/spec/models/hyrax/permission_template_spec.rb +85 -29
- data/spec/models/hyrax/user_usage_stats_spec.rb +1 -1
- data/spec/models/hyrax/work_behavior_spec.rb +12 -2
- data/spec/models/sipity/agent_spec.rb +1 -1
- data/spec/models/sipity/comment_spec.rb +1 -1
- data/spec/models/sipity/entity_spec.rb +3 -3
- data/spec/models/sipity/entity_specific_responsibility_spec.rb +1 -1
- data/spec/models/sipity/notifiable_context_spec.rb +1 -1
- data/spec/models/sipity/notification_recipient_spec.rb +1 -1
- data/spec/models/sipity/notification_spec.rb +1 -1
- data/spec/models/sipity/role_spec.rb +1 -1
- data/spec/models/sipity/workflow_action_spec.rb +1 -1
- data/spec/models/sipity/workflow_responsibility_spec.rb +1 -1
- data/spec/models/sipity/workflow_role_spec.rb +1 -1
- data/spec/models/sipity/workflow_spec.rb +7 -7
- data/spec/models/sipity/workflow_state_action_permission_spec.rb +1 -1
- data/spec/models/sipity/workflow_state_action_spec.rb +1 -1
- data/spec/models/sipity/workflow_state_spec.rb +1 -1
- data/spec/models/solr_document_spec.rb +24 -0
- data/spec/models/user_mailbox_spec.rb +0 -2
- data/spec/models/user_spec.rb +7 -7
- data/spec/presenters/hyrax/admin/users_presenter_spec.rb +2 -2
- data/spec/presenters/hyrax/admin_set_options_presenter_spec.rb +7 -7
- data/spec/presenters/hyrax/admin_set_presenter_spec.rb +20 -0
- data/spec/presenters/hyrax/collection_options_presenter_spec.rb +2 -0
- data/spec/presenters/hyrax/collection_presenter_spec.rb +375 -6
- data/spec/presenters/hyrax/file_set_presenter_spec.rb +124 -5
- data/spec/presenters/hyrax/inspect_work_presenter_spec.rb +1 -1
- data/spec/presenters/hyrax/menu_presenter_spec.rb +5 -0
- data/spec/presenters/hyrax/select_collection_type_list_presenter_spec.rb +59 -0
- data/spec/presenters/hyrax/select_collection_type_presenter_spec.rb +10 -0
- data/spec/presenters/hyrax/select_type_presenter_spec.rb +12 -0
- data/spec/presenters/hyrax/work_show_presenter_spec.rb +116 -1
- data/spec/presenters/hyrax/workflow_presenter_spec.rb +1 -1
- data/spec/renderers/hyrax/renderers/attribute_renderer_spec.rb +6 -6
- data/spec/renderers/hyrax/renderers/date_attribute_renderer_spec.rb +2 -2
- data/spec/renderers/hyrax/renderers/external_link_attribute_renderer_spec.rb +1 -1
- data/spec/renderers/hyrax/renderers/faceted_attribute_renderer_spec.rb +2 -2
- data/spec/renderers/hyrax/renderers/license_attribute_renderer_spec.rb +2 -2
- data/spec/renderers/hyrax/renderers/linked_attribute_renderer_spec.rb +2 -2
- data/spec/renderers/hyrax/renderers/rights_statement_attribute_renderer_spec.rb +10 -1
- data/spec/requests/riiif_spec.rb +32 -0
- data/spec/routing/collection_permission_templates_routes_spec.rb +31 -0
- data/spec/routing/collection_types_routes.rb +35 -0
- data/spec/routing/dashboard_routes_spec.rb +37 -0
- data/spec/routing/route_spec.rb +4 -10
- data/spec/search_builders/hyrax/admin_admin_set_member_search_builder_spec.rb +2 -2
- data/spec/search_builders/hyrax/admin_set_search_builder_spec.rb +4 -40
- data/spec/search_builders/hyrax/collection_member_search_builder_spec.rb +53 -0
- data/spec/search_builders/hyrax/collection_search_builder_spec.rb +74 -0
- data/spec/search_builders/hyrax/dashboard/collections_search_builder_spec.rb +92 -0
- data/spec/search_builders/hyrax/dashboard/nested_collections_search_builder_spec.rb +85 -0
- data/spec/search_builders/hyrax/dashboard/works_search_builder_spec.rb +44 -0
- data/spec/search_builders/hyrax/my/collections_search_builder_spec.rb +35 -0
- data/spec/search_builders/hyrax/work_search_builder_spec.rb +47 -10
- data/spec/services/hyrax/adapters/nesting_index_adapter_spec.rb +191 -0
- data/spec/services/hyrax/admin_set_create_service_spec.rb +6 -2
- data/spec/services/hyrax/admin_set_member_service_spec.rb +21 -0
- data/spec/services/hyrax/batch_create_failure_service_spec.rb +6 -2
- data/spec/services/hyrax/collection_types/create_service_spec.rb +91 -0
- data/spec/services/hyrax/collection_types/permissions_service_spec.rb +297 -0
- data/spec/services/hyrax/collections/collection_member_service_spec.rb +49 -0
- data/spec/services/hyrax/collections/managed_collections_service_spec.rb +17 -0
- data/spec/services/hyrax/collections/migration_service_spec.rb +280 -0
- data/spec/services/hyrax/collections/nested_collection_persistence_service_spec.rb +28 -0
- data/spec/services/hyrax/collections/nested_collection_query_service_spec.rb +353 -0
- data/spec/services/hyrax/collections/permissions_create_service_spec.rb +41 -0
- data/spec/services/hyrax/collections/permissions_service_spec.rb +278 -0
- data/spec/services/hyrax/collections_service_spec.rb +30 -8
- data/spec/services/hyrax/embargo_service_spec.rb +26 -5
- data/spec/services/hyrax/iiif_authorization_service_spec.rb +43 -0
- data/spec/services/hyrax/multiple_membership_checker_spec.rb +155 -0
- data/spec/services/hyrax/qa_select_service_spec.rb +8 -2
- data/spec/services/hyrax/workflow/notification_configuration_parameter_spec.rb +1 -1
- data/spec/services/hyrax/workflow/notification_generator_spec.rb +1 -1
- data/spec/services/hyrax/workflow/permission_generator_spec.rb +1 -1
- data/spec/services/hyrax/workflow/permission_query_spec.rb +2 -2
- data/spec/services/hyrax/workflow/status_list_service_spec.rb +1 -1
- data/spec/services/hyrax/workflow/workflow_factory_spec.rb +1 -1
- data/spec/services/hyrax/workflow/workflow_schema_spec.rb +1 -1
- data/spec/services/hyrax/works/managed_works_service_spec.rb +17 -0
- data/spec/spec_helper.rb +34 -4
- data/spec/support/features/session_helpers.rb +1 -1
- data/spec/support/matchers/collection_type_property_matchers.rb +29 -0
- data/spec/test_app_templates/lib/generators/test_app_generator.rb +64 -24
- data/spec/views/_flash_msg.html.erb_spec.rb +0 -2
- data/spec/views/_user_util_links.html.erb_spec.rb +0 -2
- data/spec/views/catalog/_index_list_default.html.erb_spec.rb +9 -9
- data/spec/views/hyrax/admin/admin_sets/_form_participant_table.html.erb_spec.rb +42 -20
- data/spec/views/hyrax/admin/collection_types/_form.html.erb_spec.rb +43 -0
- data/spec/views/hyrax/admin/collection_types/_form_metadata.html.erb_spec.rb +27 -0
- data/spec/views/hyrax/admin/collection_types/_form_metadata_admin_set.html.erb_spec.rb +27 -0
- data/spec/views/hyrax/admin/collection_types/_form_participants.html.erb_spec.rb +16 -0
- data/spec/views/hyrax/admin/collection_types/_form_participants_table.html.erb_spec.rb +73 -0
- data/spec/views/hyrax/admin/collection_types/_form_settings.html.erb_spec.rb +106 -0
- data/spec/views/hyrax/admin/collection_types/index.html.erb_spec.rb +41 -0
- data/spec/views/hyrax/admin/users/index.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/base/_form.html.erb_spec.rb +18 -42
- data/spec/views/hyrax/base/_form_child_work_relationships.html.erb_spec.rb +11 -22
- data/spec/views/hyrax/base/_form_files.html.erb_spec.rb +38 -0
- data/spec/views/hyrax/base/_form_progress.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/base/_form_relationships.html.erb_spec.rb +1 -2
- data/spec/views/hyrax/base/_form_rendering.html.erb_spec.rb +18 -0
- data/spec/views/hyrax/base/file_manager.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/base/show.html.erb_spec.rb +24 -5
- data/spec/views/hyrax/collections/_show_descriptions.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/collections/_show_parent_collections.html.erb_spec.rb +124 -0
- data/spec/views/hyrax/collections/_sort_and_per_page.html.erb_spec.rb +60 -0
- data/spec/views/hyrax/collections/_subcollection_list.html.erb_spec.rb +39 -0
- data/spec/views/hyrax/collections/show.html.erb_spec.rb +20 -23
- data/spec/views/hyrax/dashboard/_sidebar.html.erb_spec.rb +14 -9
- data/spec/views/hyrax/dashboard/collections/_form.html.erb_spec.rb +5 -1
- data/spec/views/hyrax/dashboard/collections/_form_branding.html.erb_spec.rb +23 -0
- data/spec/views/hyrax/dashboard/collections/_form_discovery.erb_spec.rb +67 -0
- data/spec/views/hyrax/dashboard/collections/_form_share.erb_spec.rb +13 -34
- data/spec/views/hyrax/dashboard/collections/_form_share_table.html.erb_spec.rb +108 -0
- data/spec/views/hyrax/dashboard/collections/_show_actions.html.erb_spec.rb +64 -0
- data/spec/views/hyrax/dashboard/collections/_show_add_items_actions.html.erb_spec.rb +44 -0
- data/spec/views/hyrax/dashboard/collections/_show_descriptions.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/dashboard/collections/_show_parent_collection_row.html.erb_spec.rb +23 -0
- data/spec/views/hyrax/dashboard/collections/_show_parent_collections.html.erb_spec.rb +118 -0
- data/spec/views/hyrax/dashboard/collections/_show_subcollection_actions.html.erb_spec.rb +62 -0
- data/spec/views/hyrax/dashboard/collections/_sort_and_per_page.html.erb_spec.rb +60 -0
- data/spec/views/hyrax/dashboard/collections/_subcollection_list.html.erb_spec.rb +63 -0
- data/spec/views/hyrax/dashboard/collections/_work_action_menu.html.erb_spec.rb +18 -0
- data/spec/views/hyrax/dashboard/collections/edit.html.erb_spec.rb +5 -13
- data/spec/views/hyrax/dashboard/collections/show.html.erb_spec.rb +86 -9
- data/spec/views/hyrax/file_sets/_show_actions.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/homepage/_featured_works.html.erb_spec.rb +1 -1
- data/spec/views/hyrax/homepage/index.html.erb_spec.rb +14 -5
- data/spec/views/hyrax/my/_collection_action_menu.html.erb_spec.rb +65 -0
- data/spec/views/hyrax/my/_search_header.html.erb_spec.rb +6 -6
- data/spec/views/hyrax/my/_work_action_menu.html.erb_spec.rb +6 -4
- data/spec/views/hyrax/my/collections/_list_collections.html.erb_spec.rb +90 -22
- data/spec/views/hyrax/my/works/index.html.erb_spec.rb +3 -1
- data/spec/views/hyrax/users/_user_info.html.erb_spec.rb +16 -18
- data/spec/views/pages/show.html.erb_spec.rb +1 -1
- data/spec/views/shared/select_work_type_modal.html.erb_spec.rb +36 -10
- data/tasks/hyrax_dev.rake +27 -4
- data/template.rb +2 -1
- metadata +578 -290
- data/.solr_wrapper +0 -6
- data/app/assets/javascripts/hyrax/relationships/work.es6 +0 -7
- data/app/assets/javascripts/hyrax/workflow_actions_affix.js +0 -14
- data/app/assets/stylesheets/hyrax/_work_editor.scss +0 -17
- data/app/controllers/concerns/hyrax/parent_container.rb +0 -35
- data/app/helpers/dashboard_helper.rb +0 -3
- data/app/services/hyrax/parent_service.rb +0 -19
- data/app/views/catalog/_show_partials/_default.html.erb +0 -21
- data/app/views/catalog/_show_partials/_default_details.html.erb +0 -15
- data/app/views/catalog/_show_partials/_facets.html.erb +0 -52
- data/app/views/hyrax/base/_browse_everything.html.erb +0 -6
- data/app/views/hyrax/base/_find_work_widget.html.erb +0 -10
- data/app/views/hyrax/dashboard/collections/_form_default_group.html.erb +0 -25
- data/app/views/hyrax/dashboard/collections/_form_permission.html.erb +0 -24
- data/app/views/hyrax/file_sets/jq_upload.json.jbuilder +0 -8
- data/solr/config/_rest_managed.json +0 -3
- data/solr/config/admin-extra.html +0 -31
- data/solr/config/elevate.xml +0 -36
- data/solr/config/mapping-ISOLatin1Accent.txt +0 -246
- data/solr/config/protwords.txt +0 -21
- data/solr/config/schema.xml +0 -366
- data/solr/config/scripts.conf +0 -24
- data/solr/config/solrconfig.xml +0 -322
- data/solr/config/spellings.txt +0 -2
- data/solr/config/stopwords.txt +0 -58
- data/solr/config/stopwords_en.txt +0 -58
- data/solr/config/synonyms.txt +0 -31
- data/solr/config/xslt/example.xsl +0 -132
- data/solr/config/xslt/example_atom.xsl +0 -67
- data/solr/config/xslt/example_rss.xsl +0 -66
- data/solr/config/xslt/luke.xsl +0 -337
- data/spec/abilities/admin_set_abilities_spec.rb +0 -15
- data/spec/abilities/collection_abilities_spec.rb +0 -51
- data/spec/features/admin_admin_set_spec.rb +0 -30
- data/spec/helpers/hyrax/citations_behaviors/formatters/chicago_formatter_spec.rb +0 -10
- data/spec/services/hyrax/parent_service_spec.rb +0 -11
- data/spec/support/uploaded_file_monkeypatch.rb +0 -6
- data/spec/views/hyrax/base/_browse_everything.html.erb_spec.rb +0 -17
- data/spec/views/hyrax/base/_find_work_widget.html.erb_spec.rb +0 -20
data/config/routes.rb
CHANGED
@@ -132,6 +132,12 @@ Hyrax::Engine.routes.draw do
|
|
132
132
|
put :remove_member
|
133
133
|
end
|
134
134
|
end
|
135
|
+
post 'collections/:id', controller: 'collection_members', action: :update_members
|
136
|
+
post 'collections/:child_id/within', controller: 'nest_collections', action: 'create_relationship_within', as: 'create_nest_collection_within'
|
137
|
+
get 'collections/:parent_id/under', controller: 'nest_collections', action: 'create_collection_under', as: 'create_subcollection_under'
|
138
|
+
post 'collections/:parent_id/under', controller: 'nest_collections', action: 'create_relationship_under', as: 'create_nest_collection_under'
|
139
|
+
post 'collections/:child_id/remove_parent/:parent_id', controller: 'nest_collections', action: 'remove_relationship_above', as: 'remove_parent_relationship_above'
|
140
|
+
post 'collections/:parent_id/remove_child/:child_id', controller: 'nest_collections', action: 'remove_relationship_under', as: 'remove_child_relationship_under'
|
135
141
|
resources :profiles, only: [:show, :edit, :update]
|
136
142
|
end
|
137
143
|
|
@@ -155,6 +161,15 @@ Hyrax::Engine.routes.draw do
|
|
155
161
|
get '/shares', controller: 'my/shares', action: :index, as: 'dashboard_shares'
|
156
162
|
get '/shares/page/:page', controller: 'my/shares', action: :index
|
157
163
|
get '/shares/facet/:id', controller: 'my/shares', action: :facet, as: 'dashboard_shares_facet'
|
164
|
+
scope :collections do
|
165
|
+
get '/permission_template/new' => 'admin/permission_templates#new', as: :new_dashboard_collection_permission_template
|
166
|
+
get '/:collection_id/permission_template/edit' => 'admin/permission_templates#edit', as: :edit_dashboard_collection_permission_template
|
167
|
+
get '/:collection_id/permission_template' => 'admin/permission_templates#show', as: :dashboard_collection_permission_template
|
168
|
+
patch '/:collection_id/permission_template' => 'admin/permission_templates#update'
|
169
|
+
put '/:collection_id/permission_template' => 'admin/permission_templates#update'
|
170
|
+
delete '/:collection_id/permission_template' => 'admin/permission_templates#destroy'
|
171
|
+
post '/:collection_id/permission_template' => 'admin/permission_templates#create'
|
172
|
+
end
|
158
173
|
end
|
159
174
|
|
160
175
|
# Contact form routes
|
@@ -222,6 +237,8 @@ Hyrax::Engine.routes.draw do
|
|
222
237
|
resources :workflows
|
223
238
|
resources :workflow_roles
|
224
239
|
resource :appearance
|
240
|
+
resources :collection_types, except: :show
|
241
|
+
resources :collection_type_participants, only: [:create, :destroy]
|
225
242
|
end
|
226
243
|
|
227
244
|
resources :content_blocks, only: [] do
|
data/hyrax.gemspec
CHANGED
@@ -1,5 +1,3 @@
|
|
1
|
-
# -*- encoding: utf-8 -*-
|
2
|
-
|
3
1
|
lib = File.expand_path('../lib', __FILE__)
|
4
2
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
3
|
require 'hyrax/version'
|
@@ -8,13 +6,13 @@ Gem::Specification.new do |spec|
|
|
8
6
|
spec.authors = ["Justin Coyne", 'Michael J. Giarlo', "Carolyn Cole", "Matt Zumwalt", 'Jeremy Friesen', 'Trey Pendragon', 'Esmé Cowles']
|
9
7
|
spec.email = ["jcoyne85@stanford.edu", 'mjgiarlo@stanford.edu', 'cam156@psu.edu', 'matt@databindery.com', "jeremy.n.friesen@gmail.com", 'tpendragon@princeton.edu', 'escowles@ticklefish.org']
|
10
8
|
spec.description = 'Hyrax is a featureful Samvera front-end based on the latest and greatest Samvera software components.'
|
11
|
-
spec.summary = <<-
|
9
|
+
spec.summary = <<-SUMMARY
|
12
10
|
Hyrax is a front-end based on the robust Samvera framework, providing a user
|
13
11
|
interface for common repository features. Hyrax offers the ability to create
|
14
12
|
repository object types on demand, to deposit content via multiple workflows,
|
15
13
|
and to describe content with flexible metadata. Numerous optional features may
|
16
14
|
be turned on in the administrative dashboard or added through plugins.
|
17
|
-
|
15
|
+
SUMMARY
|
18
16
|
|
19
17
|
spec.homepage = "http://github.com/samvera/hyrax"
|
20
18
|
|
@@ -31,67 +29,70 @@ EOF
|
|
31
29
|
# http://guides.rubyonrails.org/maintenance_policy.html
|
32
30
|
spec.add_dependency 'rails', '~> 5.0'
|
33
31
|
|
34
|
-
spec.add_dependency '
|
35
|
-
spec.add_dependency '
|
36
|
-
spec.add_dependency '
|
37
|
-
spec.add_dependency '
|
38
|
-
spec.add_dependency 'browse-everything', '>= 0.10.5'
|
39
|
-
spec.add_dependency 'blacklight', '~> 6.9'
|
32
|
+
spec.add_dependency 'active-fedora', '~> 11.5', '>= 11.5.2'
|
33
|
+
spec.add_dependency 'almond-rails', '~> 0.1'
|
34
|
+
spec.add_dependency 'awesome_nested_set', '~> 3.1'
|
35
|
+
spec.add_dependency 'blacklight', '~> 6.14'
|
40
36
|
spec.add_dependency 'blacklight-gallery', '~> 0.7'
|
41
|
-
spec.add_dependency '
|
37
|
+
spec.add_dependency 'breadcrumbs_on_rails', '~> 3.0'
|
38
|
+
spec.add_dependency 'browse-everything', '>= 0.10.5'
|
39
|
+
spec.add_dependency 'carrierwave', '~> 1.0'
|
40
|
+
spec.add_dependency 'clipboard-rails', '~> 1.5'
|
41
|
+
spec.add_dependency 'dry-equalizer', '~> 0.2'
|
42
|
+
spec.add_dependency 'dry-struct', '~> 0.1'
|
43
|
+
spec.add_dependency 'dry-validation', '~> 0.9'
|
44
|
+
spec.add_dependency 'flipflop', '~> 2.3'
|
45
|
+
# Pin more tightly because 0.x gems are potentially unstable
|
46
|
+
spec.add_dependency 'flot-rails', '~> 0.0.6'
|
42
47
|
spec.add_dependency 'font-awesome-rails', '~> 4.2'
|
43
|
-
spec.add_dependency '
|
48
|
+
spec.add_dependency 'hydra-derivatives', '~> 3.3'
|
49
|
+
spec.add_dependency 'hydra-editor', '~> 3.3'
|
50
|
+
spec.add_dependency 'hydra-head', '>= 10.5.0'
|
51
|
+
spec.add_dependency 'hydra-works', '~> 0.16'
|
52
|
+
spec.add_dependency 'iiif_manifest', '~> 0.3.0'
|
53
|
+
spec.add_dependency 'jquery-datatables-rails', '~> 3.4'
|
54
|
+
spec.add_dependency 'jquery-ui-rails', '~> 6.0'
|
44
55
|
spec.add_dependency 'json-schema' # for Arkivo
|
45
|
-
|
56
|
+
# Pin more tightly because 0.x gems are potentially unstable
|
57
|
+
spec.add_dependency 'kaminari_route_prefix', '~> 0.1.1'
|
58
|
+
spec.add_dependency 'legato', '~> 0.3'
|
59
|
+
spec.add_dependency 'linkeddata' # Required for getting values from geonames
|
46
60
|
spec.add_dependency 'mailboxer', '~> 0.12'
|
47
|
-
spec.add_dependency '
|
61
|
+
spec.add_dependency 'nest', '~> 3.1'
|
62
|
+
spec.add_dependency 'noid-rails', '~> 3.0.0'
|
48
63
|
spec.add_dependency 'oauth'
|
49
64
|
spec.add_dependency 'oauth2', '~> 1.2'
|
50
|
-
spec.add_dependency 'signet'
|
51
|
-
spec.add_dependency 'legato', '~> 0.3'
|
52
65
|
spec.add_dependency 'posix-spawn'
|
53
|
-
spec.add_dependency '
|
54
|
-
spec.add_dependency '
|
55
|
-
# Pin more tightly because 0.x gems are potentially unstable
|
56
|
-
spec.add_dependency 'flot-rails', '~> 0.0.6'
|
57
|
-
spec.add_dependency 'almond-rails', '~> 0.1'
|
66
|
+
spec.add_dependency 'power_converter', '~> 0.1', '>= 0.1.2'
|
67
|
+
spec.add_dependency 'pul_uv_rails', '~> 2.0'
|
58
68
|
spec.add_dependency 'qa', '~> 2.0' # questioning_authority
|
59
|
-
spec.add_dependency 'flipflop', '~> 2.3'
|
60
|
-
spec.add_dependency 'jquery-datatables-rails', '~> 3.4'
|
61
|
-
spec.add_dependency 'rdf-rdfxml' # controlled vocabulary importer
|
62
|
-
spec.add_dependency 'clipboard-rails', '~> 1.5'
|
63
|
-
# Devise 4.5 removes the 'trackable' module, which we depend on
|
64
|
-
spec.add_dependency 'devise', '<= 4.4.99'
|
65
69
|
spec.add_dependency 'rails_autolink', '~> 1.1'
|
66
|
-
spec.add_dependency '
|
67
|
-
spec.add_dependency '
|
68
|
-
spec.add_dependency 'breadcrumbs_on_rails', '~> 3.0'
|
69
|
-
# Pin more tightly because 0.x gems are potentially unstable
|
70
|
-
spec.add_dependency 'kaminari_route_prefix', '~> 0.1.1'
|
71
|
-
spec.add_dependency 'power_converter', '~> 0.1', '>= 0.1.2'
|
72
|
-
spec.add_dependency 'dry-validation', '~> 0.9'
|
73
|
-
spec.add_dependency 'dry-equalizer', '~> 0.2'
|
74
|
-
spec.add_dependency 'dry-struct', '~> 0.1'
|
70
|
+
spec.add_dependency 'rdf-rdfxml' # controlled vocabulary importer
|
71
|
+
spec.add_dependency 'redis-namespace', '~> 1.5'
|
75
72
|
spec.add_dependency 'redlock', '>= 0.1.2'
|
76
73
|
spec.add_dependency 'retriable', '>= 2.9', '< 4.0'
|
77
|
-
spec.add_dependency '
|
78
|
-
spec.add_dependency '
|
74
|
+
spec.add_dependency 'samvera-nesting_indexer', '~> 1.0', '>= 1.0.1'
|
75
|
+
spec.add_dependency 'select2-rails', '~> 3.5'
|
76
|
+
spec.add_dependency 'signet'
|
77
|
+
spec.add_dependency 'tinymce-rails', '~> 4.1'
|
79
78
|
|
80
|
-
|
81
|
-
spec.add_development_dependency '
|
79
|
+
# temporary pin to 2.17 due to failures caused in 2.18.0
|
80
|
+
spec.add_development_dependency "capybara", '~> 2.4', '< 2.18.0'
|
81
|
+
spec.add_development_dependency 'capybara-maleficent', '~> 0.2'
|
82
|
+
spec.add_development_dependency "chromedriver-helper"
|
82
83
|
spec.add_development_dependency 'database_cleaner', '~> 1.3'
|
83
|
-
spec.add_development_dependency '
|
84
|
+
spec.add_development_dependency 'engine_cart', '~> 1.2'
|
85
|
+
spec.add_development_dependency "equivalent-xml", '~> 0.5'
|
86
|
+
spec.add_development_dependency "factory_bot_rails", '~> 4.4'
|
84
87
|
spec.add_development_dependency 'fcrepo_wrapper', '~> 0.5', '>= 0.5.1'
|
85
|
-
spec.add_development_dependency '
|
86
|
-
spec.add_development_dependency
|
88
|
+
spec.add_development_dependency "jasmine", '~> 2.3', '< 2.99'
|
89
|
+
spec.add_development_dependency "jasmine-core", '~> 2.3', '< 2.99'
|
90
|
+
spec.add_development_dependency 'mida', '~> 0.3'
|
87
91
|
spec.add_development_dependency 'rspec-activemodel-mocks', '~> 1.0'
|
88
|
-
spec.add_development_dependency
|
89
|
-
spec.add_development_dependency '
|
90
|
-
spec.add_development_dependency "chromedriver-helper"
|
92
|
+
spec.add_development_dependency 'rspec-its', '~> 1.1'
|
93
|
+
spec.add_development_dependency 'rspec-rails', '~> 3.1'
|
91
94
|
spec.add_development_dependency "selenium-webdriver"
|
92
|
-
spec.add_development_dependency
|
93
|
-
spec.add_development_dependency "equivalent-xml", '~> 0.5'
|
94
|
-
spec.add_development_dependency "jasmine", '~> 2.3'
|
95
|
+
spec.add_development_dependency 'solr_wrapper', '~> 1.1'
|
95
96
|
# Pin rubocop and rubocop-rspec tightly. Minor-level version bumps
|
96
97
|
# in these gems cause Rubocop violations, and those violations cause
|
97
98
|
# continuous integration builds to fail, and those failures prevent
|
@@ -102,20 +103,20 @@ EOF
|
|
102
103
|
# conventions. This allows us to take a managed approach to code
|
103
104
|
# style -- we choose to update style when we wish, not when a
|
104
105
|
# minor-level version bump in a dependency comes out.
|
105
|
-
spec.add_development_dependency 'rubocop', '~> 0.49.1'
|
106
|
-
spec.add_development_dependency 'rubocop-rspec', '~> 1.16.0'
|
107
|
-
spec.add_development_dependency 'shoulda-matchers', '~> 3.1'
|
108
|
-
spec.add_development_dependency 'rails-controller-testing', '~> 1'
|
109
|
-
spec.add_development_dependency 'webmock'
|
110
106
|
spec.add_development_dependency 'i18n-debug' if ENV['I18N_DEBUG']
|
111
107
|
spec.add_development_dependency 'i18n_yaml_sorter' unless ENV['TRAVIS']
|
108
|
+
spec.add_development_dependency 'rails-controller-testing', '~> 1'
|
109
|
+
spec.add_development_dependency 'rubocop', '~> 0.51.0'
|
110
|
+
spec.add_development_dependency 'rubocop-rspec', '~> 1.20.1'
|
111
|
+
spec.add_development_dependency 'shoulda-callback-matchers', '~> 1.1.1'
|
112
|
+
spec.add_development_dependency 'shoulda-matchers', '~> 3.1'
|
113
|
+
spec.add_development_dependency 'webmock'
|
112
114
|
|
113
115
|
########################################################
|
114
116
|
# Temporarily pinned dependencies. INCLUDE EXPLANATIONS.
|
115
117
|
#
|
116
|
-
# simple_form 3.5.1 broke
|
117
|
-
|
118
|
-
spec.add_dependency 'simple_form', '~> 3.2', '<= 3.5.0'
|
118
|
+
# simple_form 3.5.1 broke local and Travis builds in bad ways for unknown reasons
|
119
|
+
spec.add_dependency 'simple_form', '=3.5.0'
|
119
120
|
# parser 2.5.0.0 broke local and Travis rubocop checks due to a change in parsing
|
120
121
|
spec.add_development_dependency 'parser', '< 2.5'
|
121
122
|
end
|
@@ -1,5 +1,3 @@
|
|
1
|
-
# -*- encoding : utf-8 -*-
|
2
|
-
|
3
1
|
require 'rails/generators'
|
4
2
|
|
5
3
|
class Hyrax::AssetsGenerator < Rails::Generators::Base
|
@@ -20,10 +18,10 @@ class Hyrax::AssetsGenerator < Rails::Generators::Base
|
|
20
18
|
def inject_js
|
21
19
|
return if hyrax_javascript_installed?
|
22
20
|
insert_into_file 'app/assets/javascripts/application.js', after: '//= require_tree .' do
|
23
|
-
<<-
|
21
|
+
<<-JS.strip_heredoc
|
24
22
|
|
25
23
|
//= require hyrax
|
26
|
-
|
24
|
+
JS
|
27
25
|
end
|
28
26
|
end
|
29
27
|
|
@@ -1,7 +1,11 @@
|
|
1
1
|
module Hyrax
|
2
2
|
class Install < Rails::Generators::Base
|
3
3
|
source_root File.expand_path('../templates', __FILE__)
|
4
|
+
|
4
5
|
argument :model_name, type: :string, default: "user", desc: "Model name for User model (primarily passed to devise, but also used elsewhere)"
|
6
|
+
|
7
|
+
class_option :'skip-riiif', type: :boolean, default: false, desc: "Skip generating RIIIF image service."
|
8
|
+
|
5
9
|
desc """
|
6
10
|
This generator makes the following changes to your application:
|
7
11
|
1. Runs installers for blacklight & hydra-head (which also install & configure devise)
|
@@ -24,7 +28,8 @@ module Hyrax
|
|
24
28
|
14. Updates simple_form to use browser validations
|
25
29
|
15. Installs Blacklight gallery (and removes it's scss)
|
26
30
|
16. Install jquery-datatables
|
27
|
-
17. Initializes the
|
31
|
+
17. Initializes the noid-rails database-backed minter
|
32
|
+
18. Generates RIIIF image server implementation
|
28
33
|
"""
|
29
34
|
|
30
35
|
def run_required_generators
|
@@ -160,8 +165,12 @@ module Hyrax
|
|
160
165
|
end
|
161
166
|
end
|
162
167
|
|
163
|
-
def
|
164
|
-
generate '
|
168
|
+
def noid_rails_database_minter_initialize
|
169
|
+
generate 'noid:rails:install'
|
170
|
+
end
|
171
|
+
|
172
|
+
def riiif_image_server
|
173
|
+
generate 'hyrax:riiif' unless options[:'skip-riiif']
|
165
174
|
end
|
166
175
|
end
|
167
176
|
end
|
@@ -0,0 +1,54 @@
|
|
1
|
+
require 'rails/generators'
|
2
|
+
|
3
|
+
class Hyrax::RiiifGenerator < Rails::Generators::Base
|
4
|
+
source_root File.expand_path('../templates', __FILE__)
|
5
|
+
|
6
|
+
desc '
|
7
|
+
This generator makes the following changes to your application:
|
8
|
+
1. Adds riiif dependency to application Gemfile
|
9
|
+
2. Copies riiif initializer to application
|
10
|
+
3. Mounts riiif engine within application
|
11
|
+
4. Overrides Hyrax config variables to use riiif for image and info URLs
|
12
|
+
5. Copies 404 image for riiif unauthorized responses'
|
13
|
+
|
14
|
+
def banner
|
15
|
+
say_status('info', 'GENERATING RIIIF IMAGE SERVER', :blue)
|
16
|
+
end
|
17
|
+
|
18
|
+
def add_to_gemfile
|
19
|
+
gem 'riiif', '~> 1.1'
|
20
|
+
|
21
|
+
Bundler.with_clean_env do
|
22
|
+
run "bundle install"
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
def copy_initializer
|
27
|
+
copy_file 'config/initializers/riiif.rb'
|
28
|
+
end
|
29
|
+
|
30
|
+
def mount_route
|
31
|
+
route "mount Riiif::Engine => 'images', as: :riiif if Hyrax.config.iiif_image_server?"
|
32
|
+
end
|
33
|
+
|
34
|
+
def override_image_url_builder_in_hyrax_config
|
35
|
+
insert_into_file 'config/initializers/hyrax.rb', before: /^ # config.iiif_image_url_builder/ do
|
36
|
+
" config.iiif_image_url_builder = lambda do |file_id, base_url, size|\n" \
|
37
|
+
" Riiif::Engine.routes.url_helpers.image_url(file_id, host: base_url, size: size)\n" \
|
38
|
+
" end\n"
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
def override_info_url_builder_in_hyrax_config
|
43
|
+
insert_into_file 'config/initializers/hyrax.rb', before: /^ # config.iiif_info_url_builder/ do
|
44
|
+
" config.iiif_info_url_builder = lambda do |file_id, base_url|\n" \
|
45
|
+
" uri = Riiif::Engine.routes.url_helpers.info_url(file_id, host: base_url)\n" \
|
46
|
+
" uri.sub(%r{/info\\.json\\Z}, '')\n" \
|
47
|
+
" end\n"
|
48
|
+
end
|
49
|
+
end
|
50
|
+
|
51
|
+
def copy_unauthorized_image
|
52
|
+
copy_file 'app/assets/images/us_404.svg'
|
53
|
+
end
|
54
|
+
end
|
@@ -0,0 +1,91 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
3
|
+
|
4
|
+
<svg
|
5
|
+
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
6
|
+
xmlns:cc="http://creativecommons.org/ns#"
|
7
|
+
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
8
|
+
xmlns:svg="http://www.w3.org/2000/svg"
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
10
|
+
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
11
|
+
version="1.1"
|
12
|
+
width="600"
|
13
|
+
height="600"
|
14
|
+
id="svg2997">
|
15
|
+
<defs
|
16
|
+
id="defs19" />
|
17
|
+
<metadata
|
18
|
+
id="metadata3002">
|
19
|
+
<rdf:RDF>
|
20
|
+
<cc:Work
|
21
|
+
rdf:about="">
|
22
|
+
<dc:format>image/svg+xml</dc:format>
|
23
|
+
<dc:type
|
24
|
+
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
25
|
+
<dc:title />
|
26
|
+
</cc:Work>
|
27
|
+
</rdf:RDF>
|
28
|
+
</metadata>
|
29
|
+
<g
|
30
|
+
transform="translate(-88.571,-155.22)"
|
31
|
+
id="g3057">
|
32
|
+
<g
|
33
|
+
transform="translate(88.571,155.22)"
|
34
|
+
id="g4097">
|
35
|
+
<path
|
36
|
+
d="M 0,50 C 0,22.386 22.385,0 50,0 h 500 c 27.614,0 50,22.386 50,50 v 500 c 0,27.615 -22.386,50 -50,50 H 50 C 22.385,600 0,577.62 0,550 V 50 z"
|
37
|
+
inkscape:connector-curvature="0"
|
38
|
+
id="path4099" />
|
39
|
+
<path
|
40
|
+
d="M 300,300"
|
41
|
+
inkscape:connector-curvature="0"
|
42
|
+
id="path4101" />
|
43
|
+
</g>
|
44
|
+
<g
|
45
|
+
id="g3051">
|
46
|
+
<g
|
47
|
+
transform="matrix(0.39465,0,0,0.39465,-753.67,260.87)"
|
48
|
+
id="g3783-5-2">
|
49
|
+
<path
|
50
|
+
d="M 2455.5,-227.53 2151.8,40.85 c 95.691,54.056 160.31,156.69 160.31,274.44 0,58.027 -15.751,112.35 -43.125,159.03 -6.0012,10.234 -12.637,20.046 -19.719,29.5 -2.8607,4.7586 -5.6558,9.5784 -8.3125,14.469 -2.9441,5.4198 -5.7516,10.895 -8.4375,16.469 -2.6858,5.574 -5.2368,11.249 -7.6562,16.969 -2.4194,5.7202 -4.6987,11.485 -6.8438,17.344 -2.145,5.8584 -4.1686,11.793 -6.0312,17.781 -1.8627,5.9886 -3.584,12.045 -5.1563,18.156 -1.5722,6.1108 -2.9761,12.275 -4.25,18.5 -1.2738,6.225 -2.4076,12.513 -3.375,18.844 -0.9673,6.3311 -1.7845,12.727 -2.4375,19.156 -0.6529,6.4293 -1.1382,12.887 -1.4687,19.406 -0.3305,6.5194 -0.5,13.086 -0.5,19.688 0,6.6015 0.1695,13.168 0.5,19.688 0.3305,6.5194 0.8158,12.977 1.4687,19.406 0.653,6.4293 1.4702,12.825 2.4375,19.156 0.9674,6.3311 2.1012,12.619 3.375,18.844 1.2739,6.2249 2.6778,12.389 4.25,18.5 1.5723,6.1107 3.2936,12.168 5.1563,18.156 1.8626,5.9886 3.8862,11.923 6.0312,17.781 2.1451,5.8587 4.4244,11.624 6.8438,17.344 2.4194,5.7202 4.9704,11.394 7.6562,16.969 2.6859,5.5735 5.4934,11.049 8.4375,16.469 2.9442,5.4198 6.0242,10.773 9.2188,16.031 3.1946,5.2572 6.5006,10.444 9.9375,15.531 3.4369,5.0873 7.0163,10.059 10.688,14.969 3.6712,4.9086 7.4462,9.7459 11.344,14.469 3.8976,4.7228 7.9154,9.3465 12.031,13.875 4.1159,4.5285 8.3301,8.9547 12.656,13.281 4.3262,4.3259 8.7528,8.5403 13.281,12.656 4.5285,4.1159 9.1522,8.1341 13.875,12.031 4.7227,3.8978 9.5597,7.6726 14.469,11.344 4.9091,3.6712 9.8815,7.2506 14.969,10.688 5.0873,3.4369 10.274,6.7429 15.531,9.9375 5.2576,3.1946 10.612,6.2742 16.031,9.2188 5.4198,2.9438 10.895,5.7519 16.469,8.4374 5.574,2.6861 11.249,5.2369 16.969,7.6563 5.7202,2.4194 11.485,4.6988 17.344,6.8437 2.7997,1.0254 5.6701,1.9143 8.5,2.875 6.9951,1.9608 14.006,3.8715 21.062,5.6876 7.998,2.0571 16.02,4.0424 24.094,5.9062 6.8303,1.5767 13.708,3.0358 20.594,4.4688 1.2538,0.2606 2.4951,0.556 3.75,0.8124 8.1474,1.6676 16.313,3.2508 24.531,4.7188 8.2182,1.468 16.495,2.8271 24.781,4.0938 8.2864,1.2655 16.586,2.4377 24.938,3.5 8.3519,1.0612 16.742,2.0199 25.156,2.875 8.4148,0.8541 16.869,1.6046 25.344,2.25 8.1324,0.6183 16.283,1.1079 24.469,1.5312 0.6494,0 1.287,-0.062 1.9375,-0.062 7.3954,0 14.692,0.3998 21.938,1 81.289,6.7337 152.44,50.344 197.44,112.94 44.998,-62.594 116.15,-106.2 197.44,-112.94 7.2451,-0.6002 14.542,-1 21.938,-1 0.6505,0 1.2881,0.062 1.9375,0.062 8.1855,-0.4233 16.336,-0.9129 24.469,-1.5312 8.475,-0.6453 16.929,-1.3959 25.344,-2.25 8.4148,-0.8551 16.804,-1.8138 25.156,-2.875 8.3518,-1.0623 16.651,-2.2345 24.938,-3.5 8.2862,-1.2667 16.563,-2.6258 24.781,-4.0938 8.2182,-1.468 16.384,-3.0512 24.531,-4.7188 1.2549,-0.2563 2.4963,-0.5519 3.75,-0.8124 6.8856,-1.4329 13.764,-2.8922 20.594,-4.4688 8.074,-1.8639 16.096,-3.8491 24.094,-5.9062 7.0562,-1.8161 14.067,-3.7268 21.062,-5.6876 2.83,-0.9608 5.7003,-1.8496 8.5,-2.875 5.8586,-2.1449 11.624,-4.4243 17.344,-6.8437 5.7202,-2.4194 11.395,-4.9701 16.969,-7.6563 5.5737,-2.6856 11.049,-5.4937 16.469,-8.4374 5.4198,-2.9445 10.774,-6.0243 16.031,-9.2188 5.2573,-3.1947 10.444,-6.5007 15.531,-9.9375 5.0873,-3.437 10.06,-7.0164 14.969,-10.688 4.909,-3.6713 9.746,-7.4459 14.469,-11.344 4.7228,-3.8973 9.3465,-7.9154 13.875,-12.031 4.5285,-4.116 8.9551,-8.3304 13.281,-12.656 4.326,-4.3265 8.5403,-8.7529 12.656,-13.281 4.1159,-4.5286 8.1338,-9.1523 12.031,-13.875 3.8977,-4.7228 7.6726,-9.5601 11.344,-14.469 3.6712,-4.9095 7.2506,-9.8816 10.688,-14.969 3.4369,-5.0874 6.7429,-10.274 9.9375,-15.531 3.1946,-5.258 6.2745,-10.612 9.2188,-16.031 2.944,-5.4199 5.7516,-10.895 8.4374,-16.469 2.6858,-5.5743 5.2369,-11.249 7.6563,-16.969 2.4194,-5.7203 4.6987,-11.485 6.8437,-17.344 2.145,-5.8581 4.1687,-11.793 6.0313,-17.781 1.8627,-5.9887 3.584,-12.046 5.1563,-18.156 1.5722,-6.111 2.9759,-12.275 4.25,-18.5 1.2736,-6.2252 2.4076,-12.513 3.375,-18.844 0.9672,-6.3312 1.7845,-12.727 2.4374,-19.156 0.6531,-6.4293 1.1383,-12.887 1.4688,-19.406 0.3305,-6.5195 0.5,-13.086 0.5,-19.688 0,-6.6016 -0.1695,-13.168 -0.5,-19.688 -0.3305,-6.5195 -0.8157,-12.977 -1.4688,-19.406 -0.6529,-6.4293 -1.4702,-12.825 -2.4374,-19.156 -0.9674,-6.3312 -2.1014,-12.619 -3.375,-18.844 -1.274,-6.225 -2.6779,-12.389 -4.25,-18.5 -1.5725,-6.1108 -3.2936,-12.168 -5.1563,-18.156 -1.8626,-5.9887 -3.8862,-11.923 -6.0313,-17.781 -2.145,-5.8584 -4.4243,-11.624 -6.8437,-17.344 -2.4194,-5.7203 -4.9703,-11.395 -7.6563,-16.969 -2.6857,-5.574 -5.4933,-11.049 -8.4374,-16.469 -2.6568,-4.8905 -5.4518,-9.7102 -8.3126,-14.469 -7.0815,-9.4541 -13.718,-19.266 -19.719,-29.5 -27.374,-46.682 -43.125,-101 -43.125,-159.03 0,-117.74 64.621,-220.38 160.31,-274.44 l -303.75,-268.38 c -56.769,55.377 -133.8,90 -219.38,90 -85.284,0 -162.66,-34.95 -219.38,-90 -56.718,55.05 -134.09,90 -219.38,90 -85.57,0 -162.61,-34.623 -219.38,-90 z m 438.75,140.62 c 9.315,0 16.875,7.56 16.875,16.875 0,9.315 -7.56,16.875 -16.875,16.875 -9.315,0 -16.875,-7.56 -16.875,-16.875 0,-9.315 7.56,-16.875 16.875,-16.875 z m 0,1080 c 9.315,0 16.875,7.56 16.875,16.875 0,9.315 -7.56,16.875 -16.875,16.875 -9.315,0 -16.875,-7.56 -16.875,-16.875 0,-9.315 7.56,-16.875 16.875,-16.875 z"
|
51
|
+
inkscape:connector-curvature="0"
|
52
|
+
id="path2939-8-9"
|
53
|
+
style="fill:#ffffff;stroke:#000000;stroke-width:0.89999998;stroke-miterlimit:4;stroke-dasharray:none" />
|
54
|
+
</g>
|
55
|
+
<rect
|
56
|
+
width="36.103001"
|
57
|
+
height="33.429001"
|
58
|
+
rx="37.5"
|
59
|
+
ry="33.429001"
|
60
|
+
x="369.06"
|
61
|
+
y="217.97"
|
62
|
+
id="rect3047"
|
63
|
+
style="fill:#ffffff;fill-rule:nonzero" />
|
64
|
+
<rect
|
65
|
+
width="29.417999"
|
66
|
+
height="26.743"
|
67
|
+
rx="16.5"
|
68
|
+
ry="13.929"
|
69
|
+
x="371.73001"
|
70
|
+
y="645.85999"
|
71
|
+
id="rect3049"
|
72
|
+
style="fill:#ffffff;fill-rule:nonzero" />
|
73
|
+
</g>
|
74
|
+
</g>
|
75
|
+
<g
|
76
|
+
id="routenum"
|
77
|
+
style="font-size:440.29998779px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;writing-mode:lr-tb;text-anchor:middle;fill:#000000;font-family:Roadgeek 2005 Series B">
|
78
|
+
<path
|
79
|
+
d="m 164.9,151.54 h 26.444 v 198.01 h 19.564 v 26.444 h -19.564 v 69.012 H 164.9 V 375.994 H 81.699 V 349.55 L 164.9,151.54 m 0,198.01 V 218.62 L 110.292,349.55 H 164.9"
|
80
|
+
inkscape:connector-curvature="0"
|
81
|
+
id="path2993" />
|
82
|
+
<path
|
83
|
+
d="m 300.97,145.73 c 14.189,3e-4 26.229,5.2317 36.118,15.694 6.4496,6.7366 10.893,16.053 13.329,27.949 6.5929,31.102 9.8894,67.364 9.8896,108.79 -1.4e-4,41.565 -3.2967,77.898 -9.8896,109 -2.8667,13.903 -8.5281,24.437 -16.984,31.604 -9.4597,8.0263 -20.567,12.039 -33.323,12.039 -14.906,-10e-6 -27.304,-5.2314 -37.193,-15.694 -6.3064,-6.7364 -10.678,-16.053 -13.114,-27.949 -6.5931,-30.959 -9.8896,-67.22 -9.8896,-108.79 -2e-5,-41.135 3.2965,-77.468 9.8896,-109 2.8665,-13.902 8.5279,-24.509 16.984,-31.819 9.4595,-7.8827 20.854,-11.824 34.183,-11.824 m -0.42998,31.174 c -13.186,2.7e-4 -21.427,9.6032 -24.724,28.809 -1.1467,7.0232 -2.7233,20.353 -4.7298,39.988 -1.72,17.199 -2.5799,34.614 -2.5799,52.243 -5e-5,20.496 1.4332,43.428 4.2998,68.797 2.5798,22.789 5.303,36.548 8.1696,41.278 4.873,7.7397 11.251,11.61 19.134,11.609 12.899,3e-5 20.997,-9.6029 24.294,-28.809 1.2898,-7.3096 2.8664,-20.639 4.7298,-39.988 1.7198,-17.199 2.5798,-34.757 2.5799,-52.673 -1.2e-4,-23.075 -2.0784,-51.239 -6.2347,-84.491 -1.4334,-12.326 -3.5116,-20.71 -6.2347,-25.154 -4.7299,-7.7394 -10.965,-11.609 -18.704,-11.609"
|
84
|
+
inkscape:connector-curvature="0"
|
85
|
+
id="path2995" />
|
86
|
+
<path
|
87
|
+
d="m 466.27,151.54 h 26.444 v 198.01 h 19.564 v 26.444 h -19.564 v 69.012 H 466.27 V 375.994 H 383.069 V 349.55 L 466.27,151.54 m 0,198.01 V 218.62 l -54.608,130.93 h 54.608"
|
88
|
+
inkscape:connector-curvature="0"
|
89
|
+
id="path2997" />
|
90
|
+
</g>
|
91
|
+
</svg>
|
@@ -16,6 +16,11 @@ Hyrax.config do |config|
|
|
16
16
|
# avoid clashes if you plan to use the default (dct:isPartOf) for other relations.
|
17
17
|
# config.admin_set_predicate = ::RDF::DC.isPartOf
|
18
18
|
|
19
|
+
# Which RDF term should be used to relate objects to a rendering?
|
20
|
+
# If this is a new repository, you may want to set a custom predicate term here to
|
21
|
+
# avoid clashes if you plan to use the default (dct:hasFormat) for other relations.
|
22
|
+
# config.rendering_predicate = ::RDF::DC.hasFormat
|
23
|
+
|
19
24
|
# Email recipient of messages sent via the contact form
|
20
25
|
# config.contact_email = "repo-admin@example.org"
|
21
26
|
|
@@ -69,7 +74,7 @@ Hyrax.config do |config|
|
|
69
74
|
# config.noid_template = ".reeddeeddk"
|
70
75
|
|
71
76
|
# Use the database-backed minter class
|
72
|
-
# config.noid_minter_class =
|
77
|
+
# config.noid_minter_class = Noid::Rails::Minter::Db
|
73
78
|
|
74
79
|
# Store identifier minter's state in a file for later replayability
|
75
80
|
# config.minter_statefile = '/tmp/minter-state'
|
@@ -111,6 +116,41 @@ Hyrax.config do |config|
|
|
111
116
|
# The default is true.
|
112
117
|
# config.work_requires_files = true
|
113
118
|
|
119
|
+
# Enable IIIF image service. This is required to use the
|
120
|
+
# UniversalViewer-ified show page
|
121
|
+
#
|
122
|
+
# If you have run the riiif generator, an embedded riiif service
|
123
|
+
# will be used to deliver images via IIIF. If you have not, you will
|
124
|
+
# need to configure the following other configuration values to work
|
125
|
+
# with your image server:
|
126
|
+
#
|
127
|
+
# * iiif_image_url_builder
|
128
|
+
# * iiif_info_url_builder
|
129
|
+
# * iiif_image_compliance_level_uri
|
130
|
+
# * iiif_image_size_default
|
131
|
+
#
|
132
|
+
# Default is false
|
133
|
+
# config.iiif_image_server = false
|
134
|
+
|
135
|
+
# Returns a URL that resolves to an image provided by a IIIF image server
|
136
|
+
# config.iiif_image_url_builder = lambda do |file_id, base_url, size|
|
137
|
+
# "#{base_url}/downloads/#{file_id.split('/').first}"
|
138
|
+
# end
|
139
|
+
|
140
|
+
# Returns a URL that resolves to an info.json file provided by a IIIF image server
|
141
|
+
# config.iiif_info_url_builder = lambda do |_, _|
|
142
|
+
# ""
|
143
|
+
# end
|
144
|
+
|
145
|
+
# Returns a URL that indicates your IIIF image server compliance level
|
146
|
+
# config.iiif_image_compliance_level_uri = 'http://iiif.io/api/image/2/level2.json'
|
147
|
+
|
148
|
+
# Returns a IIIF image size default
|
149
|
+
# config.iiif_image_size_default = '600,'
|
150
|
+
|
151
|
+
# Fields to display in the IIIF metadata section; default is the required fields
|
152
|
+
# config.iiif_metadata_fields = Hyrax::Forms::WorkForm.required_fields
|
153
|
+
|
114
154
|
# Should a button with "Share my work" show on the front page to all users (even those not logged in)?
|
115
155
|
# config.display_share_button_when_not_logged_in = true
|
116
156
|
|
@@ -180,8 +220,13 @@ Hyrax.config do |config|
|
|
180
220
|
# config.lock_time_to_live = 60_000
|
181
221
|
|
182
222
|
## Do not alter unless you understand how ActiveFedora handles URI/ID translation
|
183
|
-
# config.translate_id_to_uri =
|
184
|
-
#
|
223
|
+
# config.translate_id_to_uri = lambda do |uri|
|
224
|
+
# baseparts = 2 + [(Noid::Rails::Config.template.gsub(/\.[rsz]/, '').length.to_f / 2).ceil, 4].min
|
225
|
+
# uri.to_s.sub(baseurl, '').split('/', baseparts).last
|
226
|
+
# end
|
227
|
+
# config.translate_uri_to_id = lambda do |id|
|
228
|
+
# "#{ActiveFedora.fedora.host}#{ActiveFedora.fedora.base_path}/#{Noid::Rails.treeify(id)}"
|
229
|
+
# end
|
185
230
|
|
186
231
|
## Fedora import/export tool
|
187
232
|
#
|