Releases: projectblacklight/blacklight
v5.5.0
New Features and improvements
#888 Improve the responsive design of the facet sidebar to maintain a 2-column layout on tablet-sized browsers
#913 Update the AJAX Modal to detect and gracefully handle network errors
#914 Extract catalog/search_results
partial from catalog/index
to render the search result, search controls, etc.
#919 Add debug logging to the solr document partial lookup logic
Bug Fixes
#918 Ignore an empty f[facet][] query parameter.
#922 Update the bookmarks HTML to match the expected bootstrap form DOM
#928 Fix the FacetPaginator for kaminari 0.16
#935 Support i18n keys for constraint field labels
#940 Update the constraints HTML to remove a bad anchor tag
Upgrade Guide
v5.4.0
New Features and improvements
#864 Configuration for facets, index and show fields, sort fields, and document_index_views should support configurable if
and unless
constraints
#852 support bookmark export using a callback url
support Rails 4.1
polymorphic associations from bookmarks to solr documents
New translations
#854 Add pt-BR translation (h/t @rvalyi)
Bug Fixes
#872 render_document_index helper should pass locals through to the templates
#868 clicking a facet label should not scroll the user's browser
#866 escape date values for sending to solr
#850 search bar in Firefox is truncated
#848 set the Solr :row
parameter if no default parameter is provided
#880 bookmark cite and email links should be restricted to the current page
Upgrade Guide
-
This release includes a new database migration. After updating the gem, you should also run:
$ rake blacklight:install:migrations
to get the latest migrations.
-
If you are running Rails 3, you MUST set
Blacklight.secret_key
in an initializer. Consider using something like value ofSecureRandom.hex(64)
to seed this secret. This value should be private.Under Rails 4, Blacklight will use the application-wide secret key base.
Blacklight 5.3.0
New Features and improvements
- #840 add
blacklight_config.show.route
configuration for generating links to solr documents - #842 extract
#type_field_to_partial_name
helper to translate a document format to a partial suffix - #845 extract useful partials and helpers from
layouts/blacklight
so local applications can override the layout, but continue to use blacklight-provided functionality - #846 add
blacklight:check:solr
andblacklight:check:controller
rake tasks for validating Blacklight's connection to Solr
Bug Fixes
- #844 Fix the "Back to Search" behavior (arguably broken since Blacklgiht 4.5) from search results not on the first page. The new behavior also ensures if the user navigates to a result using the
catalog#show
pagination, the Back to Search link returns them to the search result page that includes their current document, not the one they started from. - Fix ajax modal form selector to ensure forms within an ajax modal stay within the modal
Blacklight 5.2.0
This release contains a number of new features, but most importantly adds compatibility with Rails 4.1 and Ruby 2.1.1.
New Features and improvements
#787 Extract DocumentPresenter
module from BlacklightHelperBehavior
methods
#788 Extract RequestBuilder
module from SolrHelper
#811 Add Spanish locale file
#783 add :include_in_request
configuration option to augment add_facet_fields_to_solr_request!
and add_field_configuration_to_solr_request!
#819 Add new configuration options for Solr requests for single documents, document_solr_path
and document_unique_id_param
, allowing Blacklight to work with the RealTimeGetComponent in Solr 4.x
#818 Add default_per_page
configuration to the Blacklight configuration
#814 Generate jettywrapper as part of the blacklight:install process
#796 OpenStructWithHashAccess should respond to #to_json/#as_json as if it were a hash
#795 Facet HTML id
attributes should be a parameterized version of the field name, not the field label
#794 Add more configuration examples to the generated blacklight config
#831 pass the current partial name to the document_partial_name
helper, to allow partial-specific formats for documents
Bug Fixes
#821 Fix catalog#opensearch view under Rails 3.x
#791 Use ActiveSupport::Benchmarkable
with instance-level accessors, not class-level accessors
#786 Ensure page titles are HTML safe
#785 Fix two-arg form of SolrHelper#find
to pass through the solr request path
#780 remove unused #history_session
accessor
#778, #808, #806, #798 General test suite improvements
Upgrade Notes
The HTML ID change in #795 may be backwards-incompatible in some applications. If your application's css or javascript uses the old-style HTML id calculation, you will need to either update your assets to use the new ID, or override the #facet_field_id
helper to restore the old behavior.
Blacklight 5.1.0
New Features
- #764 Support for wild-card based field configuration, e.g.
config.add_facet_field '*_facet'
config.add_show_field '*_display'
config.add_index_field 'title_*'
- #762 Add
solr_params
configuration option for index, show and facet fields to add field-scoped parameters to the solr request.
config.add_index_field 'an_index_field', solr_params: { 'hl.alternativeField' => 'field_x'}
config.add_show_field 'a_show_field', solr_params: { 'hl.alternativeField' => 'field_y'}
config.add_field_configuration_to_solr_request!
config.add_facet_field 'some-field', solr_params: { 'facet.mincount' =>15 }
config.add_facet_fields_to_solr_request!
- #761 Add configuration for registering additional search result (
catalog#index
) response formats
config.index.respond_to.yaml = true
config.index.respond_to.yaml = { layout: 'custom-layout' }
Bug fixes and improvements
- #766 Update
InvalidSolrID
rescuing to provide a regular HTTP 404 page instead of rendering the search page with a flash message. - #777 Merge the code for rendering facets at
catalog#facet
with the code that renders facets on a search results page. This fixes also fixes bug where facets configured withsingle: true
would not be rendered correctly oncatalog#facet
. - #776 Updates Blacklight-provided URL helpers (e.g.
link_to_query
) to use#search_action_url
and#search_action_path
to ensure they can be properly used outside of aBlacklight::Catalog
instance, or within another Rails engine.
This also adds #search_action_path
, an equivalent to #search_action_url
, producing a relative path instead of an absolute URL
- #774 When rendering the Blacklight thumbnail partial, allow the renderer to disable linking the thumbnail to the search result (the default)
Blacklight 5.0.2
This release fixes two defects discovered in Blacklight 5.0.1:
Blacklight 5.0.1
Blacklight 5.0.0
Major Changes
Bootstrap 3 (#640)
Blacklight 5.x updates the views and helpers to use Bootstrap 3.x. As part of this update, we've tweaked the default theme to align closer with Bootstrap conventions. This is a major change, and applications that have overridden the Blacklight / Bootstrap 2.x themes will need to be updated.
MARC-specific code extracted into blacklight-marc (#606)
We've extracted the library / MARC-format specific code from Blacklight into a separate gem, http://github.com/projectblacklight/blacklight_marc. Going forward, this gem will be a home for additional MARC-specific features that wouldn't make sense in the Blacklight core.
Remove deprecated code and views
Deprecated methods and templates have been marked as deprecated in Blacklight 4.x releases and have been removed in Blacklight 5.x.
Other methods have been marked as deprecated in Blacklight 5.x (to be removed in Blacklight 6.x):
- Blacklight.solr (use #blacklight_solr accessor instead)
- config.show and config.index parameters have been re-organized to use consistent methods
Features
#640 (and #642, #643, #651, #667, #671, #675, #677, #713, #720) Convert front end to Bootstrap 3 and improve default Blacklight theme.
#606 Refactor MARC-specific code from Blacklight into a separate blacklight-marc gem
#665 Add interface for building the Solr request parameters (instead of modifying a ruby hash directly)
#683 Allow blacklight's catalog configuration to control partials to render for index and show views
#680 Simple schema.org support in the Blacklight configuration
#721 Search results view type picker
#716 Add :collapse
to add_facet_field configuration to determine if the facet should be displayed collapsed (the default) or expanded
#697 Add :accessor
to add_index/show_field
configuration to call a method on the SolrDocument instead of looking in a solr field for a value.
Improvements
#657 Improve the AJAX modal (details in ticket)
#656 Use a 303 See Other
redirect to redirect from catalog#update to the catalog#show page (triggered by the search context javascript)
#655 Catalog controller routes should be configurable
#684 page_entries_info should use Rails-formatted numbers
#681 update blacklight-jetty to use Solr 4.6.0
#711 RSolr can be configured to use POST
requests instead of PUT
#714 Ensure view types persist between searches
#729 Better support for different index views
#658 Remove zebra_stripe.js
Upgrade guide
-
Update your application to the terminal Blacklight 4.x release (4.7.0, as of this writing) to receive notices of deprecated behaviors used in your local application.
-
remove the line
@import 'bootstrap-responsive';
fromapp/assets/stylesheets/blacklight.css.scss
. This file has been removed in Bootstrap 3. -
The FeedbackController (deprecated in 4.x) has been removed. If your application used this feature from Blacklight, consider a 3rd party implementation or roll your own.
-
Update your Gemfile to use Blacklight 5.0.0.
gem 'blacklight', ' ~> 5.0'
-
Add the
blacklight-marc
gem to your Gemfile. If you are not using MARC-flavor metadata, you can omit them gem, and remove any references toBlacklight::Solr::Document::Marc
from your SolrDocument class. -
Update your CatalogController configuration to:
-
rename
config.show.html_title
toconfig.show.title_field
-
rename
config.show.heading
toconfig.show.title_field
-
rename
config.show.display_type
toconfig.show.display_type_field
-
rename
config.index.show_link
toconfig.index.title_field
-
rename
config.index.record_display_type
toconfig.index.display_type_field
Note:
config.show
can be omitted if the fields to render are the same
-
Blacklight 4.7.0
Blacklight 4.7.0 provides deprecation warnings and backports of features from Blacklight 5.0. It is the terminal release of Blacklight 4.x. Many of the listed features and deprecations were released as part of Blacklight 4.6 point releases.
Backports:
#711 Allowing solr query to use either get or post http method based on the http_method configuration parameter
#714 View type should persist between searches
#717 Add configuration options to add_facet_field 'field', :show => to allow "run-time" configuration when the solr data and request context are available, with a couple different options.
Add i18n strings for displaying index and show field labels
Add blacklight_solr and blaclight_solr_config helpers to Blacklight::SolrHelper
Deprecation warnings (including directions for updating to non-deprecated methods) are provided inline and as logged deprecation warnings.
Deprecated classes include:
- FeedbackController
- Mash
Deprecated helpers include:
- sidebar_items
- topbar_items
- default_html_head
- extra_head_content
- stylesheet_links
- javascript_includes
- render_head_content
- render_stylesheet_includes
- render_js_includes
- render_extra_head_content
- adjust_for_results_view
- render_pagination_info
- paginate_params
- paginate_rsolr_response
- adjust_for_results_view
- format_num
- index_field_names
- index_field_labels
- document_show_field_labels
- response_has_no_search_results?
- hash_as_hidden_fields
- citation_title
Other deprecations include:
- Blacklight.solr
- Blacklight.models_dir
- Blacklight.controllers_dir
- Blacklight.jruby?
- Blacklight.locate_path
- Hash#to_mash
- User#has_bookmarks?
- User#has_searches?
- User#documents_to_bookmark=
Blacklight 4.6.3
We’ve released Blacklight 4.6.3 with more deprecations and backports from the
Blacklight 5.x work:
Deprecations:
- FeedbackController
- #paginate_rsolr_response helper
Backports:
- #711 Allowing solr query to use either get or post http method based on the http_method configuration parameter
- #714 View type should persist between searches
- #717 Add configuration options to
add_facet_field 'field', :show =>
to
allow "run-time" configuration when the solr data and request context
are available, with a couple different options.