@collectionspace/cspace-public-browser 2.1.0 → 2.1.2
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.
- package/dist/cspacePublicBrowser.js +12 -12
- package/dist/cspacePublicBrowser.min.js +1 -1
- package/lib/components/detail/DetailPanel.js +1 -1
- package/lib/components/detail/ImageGallery.js +1 -1
- package/lib/components/detail/InstitutionHoldingList.js +1 -1
- package/lib/components/layout/Panel.js +1 -1
- package/lib/components/layout/ScrollTopButton.js +1 -1
- package/lib/components/pages/DetailPage.js +1 -1
- package/lib/components/pages/SearchPage.js +1 -1
- package/lib/components/search/entry/SearchEntryForm.js +1 -1
- package/lib/components/search/entry/SearchQueryInput.js +1 -1
- package/lib/components/search/entry/SortSelect.js +1 -1
- package/lib/components/search/result/Filter.js +1 -1
- package/lib/components/search/result/FilterPanel.js +1 -1
- package/lib/components/search/result/FilterSearchInput.js +1 -1
- package/lib/components/search/result/SearchResultImage.js +1 -1
- package/lib/components/search/result/SearchResultList.js +1 -1
- package/lib/components/search/result/SearchResultPanel.js +1 -1
- package/lib/config/anthro.js +2 -2
- package/lib/config/default.js +68 -12
- package/lib/config/fcart.js +1 -1
- package/lib/config/lhmc.js +8 -1
- package/lib/config/materials.js +6 -3
- package/lib/helpers/formatHelpers.js +3 -1
- package/lib/index.js +1 -1
- package/lib/reducers/index.js +1 -1
- package/package.json +1 -1
- package/src/config/anthro.js +3 -2
- package/src/config/default.js +73 -11
- package/src/config/fcart.js +2 -1
- package/src/config/lhmc.js +8 -0
- package/src/config/materials.js +5 -3
- package/src/helpers/formatHelpers.jsx +4 -0
package/src/config/fcart.js
CHANGED
package/src/config/lhmc.js
CHANGED
package/src/config/materials.js
CHANGED
|
@@ -4,6 +4,7 @@ import { getItemShortID } from 'cspace-refname';
|
|
|
4
4
|
import {
|
|
5
5
|
displayName,
|
|
6
6
|
filterLink,
|
|
7
|
+
head,
|
|
7
8
|
linkText,
|
|
8
9
|
inlineList,
|
|
9
10
|
listOf,
|
|
@@ -1070,9 +1071,10 @@ export default {
|
|
|
1070
1071
|
linkValue: false,
|
|
1071
1072
|
})),
|
|
1072
1073
|
},
|
|
1073
|
-
|
|
1074
|
+
objectCount: {
|
|
1074
1075
|
label: 'Holdings',
|
|
1075
|
-
field: 'collectionobjects_common:
|
|
1076
|
+
field: 'collectionobjects_common:objectCountGroupList',
|
|
1077
|
+
format: head(valueAt({ path: 'objectCount' })),
|
|
1076
1078
|
},
|
|
1077
1079
|
objectStatusList: {
|
|
1078
1080
|
label: 'Type',
|
|
@@ -1138,7 +1140,7 @@ export default {
|
|
|
1138
1140
|
},
|
|
1139
1141
|
group_sample_holdings: {
|
|
1140
1142
|
fields: [
|
|
1141
|
-
'
|
|
1143
|
+
'objectCount',
|
|
1142
1144
|
'objectStatusList',
|
|
1143
1145
|
],
|
|
1144
1146
|
className: 'inline',
|
|
@@ -299,6 +299,10 @@ export const paragraphs = (array) => (
|
|
|
299
299
|
array && array.length > 0 && array.map((value, index) => <p key={index}>{value}</p>)
|
|
300
300
|
);
|
|
301
301
|
|
|
302
|
+
export const head = (format) => (array, fieldName) => (
|
|
303
|
+
Array.isArray(array) && array.length > 0 ? format(array[0], fieldName) : null
|
|
304
|
+
);
|
|
305
|
+
|
|
302
306
|
export const valueAt = (config) => (data) => {
|
|
303
307
|
const {
|
|
304
308
|
path,
|