@manuscripts/style-guide 0.31.24 → 0.31.26

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.
@@ -109,7 +109,7 @@ const BaseInformation = ({ submission, handleDateChange, userRole }) => {
109
109
  react_1.default.createElement(Label, null, "Published:"),
110
110
  react_1.default.createElement(Value, null, (0, date_fns_1.format)(submission.publishedDate || 0, 'd MMM yyyy, EEEE')))),
111
111
  react_1.default.createElement(Label, null, "Article ID:"),
112
- react_1.default.createElement(Value, null, submission.id),
112
+ react_1.default.createElement(Value, null, submission.code),
113
113
  react_1.default.createElement(Label, null, "DOI:"),
114
114
  react_1.default.createElement(Value, null, submission.doi),
115
115
  react_1.default.createElement(Label, null, "Journal:"),
@@ -53,6 +53,9 @@ const getLWCapabilities = (project, profile, lwRole, actions) => {
53
53
  editNotTracked: false,
54
54
  accessEditor: true,
55
55
  formatArticle: !isViewer(),
56
+ editArticle: !isViewer(),
57
+ editMetadata: !(isViewer() || isAnnotator()),
58
+ shareProject: isOwner(),
56
59
  };
57
60
  };
58
61
  exports.getLWCapabilities = getLWCapabilities;
@@ -84,7 +84,7 @@ export const BaseInformation = ({ submission, handleDateChange, userRole }) => {
84
84
  React.createElement(Label, null, "Published:"),
85
85
  React.createElement(Value, null, format(submission.publishedDate || 0, 'd MMM yyyy, EEEE')))),
86
86
  React.createElement(Label, null, "Article ID:"),
87
- React.createElement(Value, null, submission.id),
87
+ React.createElement(Value, null, submission.code),
88
88
  React.createElement(Label, null, "DOI:"),
89
89
  React.createElement(Value, null, submission.doi),
90
90
  React.createElement(Label, null, "Journal:"),
@@ -47,6 +47,9 @@ export const getLWCapabilities = (project, profile, lwRole, actions) => {
47
47
  editNotTracked: false,
48
48
  accessEditor: true,
49
49
  formatArticle: !isViewer(),
50
+ editArticle: !isViewer(),
51
+ editMetadata: !(isViewer() || isAnnotator()),
52
+ shareProject: isOwner(),
50
53
  };
51
54
  };
52
55
  export const getAllPermitted = () => {
@@ -21,6 +21,7 @@ export declare enum SubmissionCriticality {
21
21
  }
22
22
  export declare type Submission = {
23
23
  id: string;
24
+ code: string;
24
25
  doi: string;
25
26
  title: string;
26
27
  journal: Journal;
@@ -33,6 +33,9 @@ export declare type Capabilities = {
33
33
  editNotTracked: boolean;
34
34
  accessEditor: boolean;
35
35
  formatArticle: boolean;
36
+ editArticle: boolean;
37
+ editMetadata: boolean;
38
+ shareProject: boolean;
36
39
  };
37
40
  export interface ProviderProps {
38
41
  project?: Project;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@manuscripts/style-guide",
3
3
  "description": "Shared components for Manuscripts applications",
4
- "version": "0.31.24",
4
+ "version": "0.31.26",
5
5
  "repository": "gitlab:atypon-opensource/manuscripts-style-guide",
6
6
  "license": "Apache-2.0",
7
7
  "main": "dist/cjs",