Skip to content

Commit

Permalink
v2.9.2 (#76)
Browse files Browse the repository at this point in the history
* update release showViz to be based on DOI status

* prepare v2.9.2
  • Loading branch information
sampsonj authored Jul 25, 2024
1 parent 832e586 commit 90d316c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 15 deletions.
3 changes: 2 additions & 1 deletion lib/service/ReleaseService.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ exports.default = exports.PROVISIONAL_RELEASE = exports.LATEST_AND_PROVISIONAL =
var _NeonContextService = _interopRequireDefault(require("./NeonContextService"));
var _typeUtil = require("../util/typeUtil");
var _internal = require("../types/internal");
var _neonApi = require("../types/neonApi");
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
const LATEST_AND_PROVISIONAL = exports.LATEST_AND_PROVISIONAL = 'LATEST_AND_PROVISIONAL';
Expand Down Expand Up @@ -126,7 +127,7 @@ const ReleaseService = {
description: appliedDoiStatus.release,
showCitation: true,
showDoi: true,
showViz: false
showViz: (0, _typeUtil.exists)(appliedDoiStatus.status) && appliedDoiStatus.status === _neonApi.DoiStatusType.FINDABLE
};
return transformed;
},
Expand Down
22 changes: 11 additions & 11 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "portal-core-components",
"version": "2.9.1",
"version": "2.9.2",
"main": "./lib/index.js",
"private": true,
"homepage": "http://localhost:3010/core-components",
Expand Down
5 changes: 3 additions & 2 deletions src/lib_components/service/ReleaseService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import NeonContextService from './NeonContextService';
import { exists, existsNonEmpty, isStringNonEmpty } from '../util/typeUtil';
import { UserRelease } from '../types/neonContext';
import { Release as InternalRelease, IReleaseLike, ReleaseProps } from '../types/internal';
import { DataProductDoiStatus, DataProductRelease } from '../types/neonApi';
import { DataProductDoiStatus, DataProductRelease, DoiStatusType } from '../types/neonApi';
import { Nullable } from '../types/core';

export const LATEST_AND_PROVISIONAL = 'LATEST_AND_PROVISIONAL';
Expand Down Expand Up @@ -223,7 +223,8 @@ const ReleaseService: IReleaseService = {
description: appliedDoiStatus.release,
showCitation: true,
showDoi: true,
showViz: false,
showViz: exists(appliedDoiStatus.status)
&& (appliedDoiStatus.status === DoiStatusType.FINDABLE),
};
return transformed as IReleaseLike;
},
Expand Down

0 comments on commit 90d316c

Please sign in to comment.