@bento-core/table 1.0.1-ccdihub.116 → 1.0.1-ccdihub.117

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.
@@ -35,10 +35,13 @@ const CPIView = _ref => {
35
35
  backgroundColor: 'white',
36
36
  border: '1px solid black',
37
37
  color: 'black',
38
- font: 'Poppins',
38
+ fontFamily: 'Poppins',
39
39
  fontWeight: 400,
40
+ fontStyle: 'Regular',
40
41
  fontSize: '13px',
41
- lineHeight: '17.5px'
42
+ lineHeight: '17.5px',
43
+ letterSpacing: '-0.01em',
44
+ padding: '10px'
42
45
  }
43
46
  }));
44
47
  const classes = useStyles();
@@ -63,6 +66,14 @@ const CPIView = _ref => {
63
66
  padding: 0,
64
67
  marginLeft: '3px'
65
68
  };
69
+ const italicText = {
70
+ fontFamily: 'Poppins',
71
+ fontWeight: 400,
72
+ fontStyle: 'italic',
73
+ fontSize: '13px',
74
+ lineHeight: '19px',
75
+ letterSpacing: '-0.01em'
76
+ };
66
77
  const icon = {
67
78
  marginLeft: '10px',
68
79
  position: 'relative',
@@ -116,16 +127,28 @@ const CPIView = _ref => {
116
127
  arrow: classes.arrow,
117
128
  tooltip: classes.tooltip
118
129
  },
119
- title: externalData.length && internalData.length === 0 ? /*#__PURE__*/_react.default.createElement("div", null, "All mapped identifiers in the CCDI Participant Index (CPI) are available", /*#__PURE__*/_react.default.createElement("span", {
130
+ title: externalData.length === 1 && internalData.length === 0 ? /*#__PURE__*/_react.default.createElement("div", null, "dbGaP identifier mapped in the CCDI Participant Index (CPI) is available", /*#__PURE__*/_react.default.createElement("span", {
131
+ role: "button",
132
+ onClick: handleModalOpen,
133
+ tabIndex: 0,
134
+ style: button
135
+ }, "here.")) : externalData.length > 1 && internalData.length === 0 ? /*#__PURE__*/_react.default.createElement("div", null, "Multiple alternative identifiers mapped in the CCDI Participant Index (CPI) are available", /*#__PURE__*/_react.default.createElement("span", {
120
136
  role: "button",
121
137
  onClick: handleModalOpen,
122
138
  tabIndex: 0,
123
139
  style: button
124
140
  }, "here.")) : /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement("div", {
125
141
  style: {
126
- marginBottom: '3px'
142
+ marginBottom: '6px'
143
+ }
144
+ }, "This participant has more than one identifier in CCDI Hub studies:"), internalData.map(e => /*#__PURE__*/_react.default.createElement("div", {
145
+ key: e.associated_id,
146
+ style: italicText
147
+ }, "".concat(e.associated_id, ", ").concat(e.repository_of_synonym_id))), /*#__PURE__*/_react.default.createElement("div", {
148
+ style: {
149
+ marginTop: '6px'
127
150
  }
128
- }, "Identifier mapped in CCDI Hub:"), internalData.map(e => /*#__PURE__*/_react.default.createElement("div", null, "".concat(e.associated_id, ", ").concat(e.repository_of_synonym_id))), /*#__PURE__*/_react.default.createElement("p", null, "All mapped identifiers in the CCDI Participant Index (CPI) are available", /*#__PURE__*/_react.default.createElement("span", {
151
+ }, "Additional alternative identifiers mapped in the CCDI Participant Index (CPI) for this participant are available", /*#__PURE__*/_react.default.createElement("span", {
129
152
  role: "button",
130
153
  onClick: handleModalOpen,
131
154
  tabIndex: 0,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bento-core/table",
3
- "version": "1.0.1-ccdihub.116",
3
+ "version": "1.0.1-ccdihub.117",
4
4
  "main": "dist/index.js",
5
5
  "scripts": {
6
6
  "build": "npm run lint && cross-env-shell rm -rf dist && NODE_ENV=production BABEL_ENV=es babel src --out-dir dist --copy-files",
@@ -30,10 +30,13 @@ const CPIView = ({
30
30
  backgroundColor: 'white',
31
31
  border: '1px solid black',
32
32
  color: 'black',
33
- font: 'Poppins',
33
+ fontFamily: 'Poppins',
34
34
  fontWeight: 400,
35
+ fontStyle: 'Regular',
35
36
  fontSize: '13px',
36
37
  lineHeight: '17.5px',
38
+ letterSpacing: '-0.01em',
39
+ padding: '10px',
37
40
  },
38
41
  }));
39
42
 
@@ -64,6 +67,15 @@ const CPIView = ({
64
67
  marginLeft: '3px',
65
68
  };
66
69
 
70
+ const italicText = {
71
+ fontFamily: 'Poppins',
72
+ fontWeight: 400,
73
+ fontStyle: 'italic',
74
+ fontSize: '13px',
75
+ lineHeight: '19px',
76
+ letterSpacing: '-0.01em',
77
+ };
78
+
67
79
  const icon = {
68
80
  marginLeft: '10px',
69
81
  position: 'relative',
@@ -123,25 +135,34 @@ const CPIView = ({
123
135
  }}
124
136
  classes={{ arrow: classes.arrow, tooltip: classes.tooltip }}
125
137
  title={
126
- (externalData.length && internalData.length === 0
138
+ (externalData.length === 1 && internalData.length === 0
127
139
  ? (
128
140
  <div>
129
- All mapped identifiers in the CCDI Participant Index (CPI) are available
141
+ dbGaP identifier mapped in the CCDI Participant Index (CPI) is available
130
142
  <span role="button" onClick={handleModalOpen} tabIndex={0} style={button}>here.</span>
131
143
  </div>
132
144
  )
133
- : (
134
- <div>
135
- <div style={{ marginBottom: '3px' }}>Identifier mapped in CCDI Hub:</div>
136
- {internalData.map((e) => (
137
- <div>{`${e.associated_id}, ${e.repository_of_synonym_id}`}</div>
138
- ))}
139
- <p>
140
- All mapped identifiers in the CCDI Participant Index (CPI) are available
145
+ : externalData.length > 1 && internalData.length === 0
146
+ ? (
147
+ <div>
148
+ Multiple alternative identifiers mapped in the
149
+ CCDI Participant Index (CPI) are available
141
150
  <span role="button" onClick={handleModalOpen} tabIndex={0} style={button}>here.</span>
142
- </p>
143
- </div>
144
- )
151
+ </div>
152
+ )
153
+ : (
154
+ <div>
155
+ <div style={{ marginBottom: '6px' }}>This participant has more than one identifier in CCDI Hub studies:</div>
156
+ {internalData.map((e) => (
157
+ <div key={e.associated_id} style={italicText}>{`${e.associated_id}, ${e.repository_of_synonym_id}`}</div>
158
+ ))}
159
+ <div style={{ marginTop: '6px' }}>
160
+ Additional alternative identifiers mapped in the
161
+ CCDI Participant Index (CPI) for this participant are available
162
+ <span role="button" onClick={handleModalOpen} tabIndex={0} style={button}>here.</span>
163
+ </div>
164
+ </div>
165
+ )
145
166
  )
146
167
  }
147
168
  >