@rh-support/troubleshoot 1.1.1 → 1.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/lib/esm/components/Review/Review.js +1 -1
- package/lib/esm/components/SessionRestore/SessionRestore.d.ts.map +1 -1
- package/lib/esm/components/SessionRestore/SessionRestore.js +0 -1
- package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelectorImage.d.ts.map +1 -1
- package/lib/esm/components/shared/fileUpload/fileSelectors/WidgetFileSelectorImage.js +11 -5
- package/lib/esm/reducers/CaseHelpers.d.ts.map +1 -1
- package/lib/esm/reducers/CaseHelpers.js +4 -3
- package/package.json +5 -5
|
@@ -54,8 +54,8 @@ export default function Review(props) {
|
|
|
54
54
|
React.createElement(ContactPhoneNumber, null))),
|
|
55
55
|
React.createElement(ContactPhoneNumberAlert, null),
|
|
56
56
|
React.createElement(Fts, { inlineEditable: true, initialIsEditing: isEmpty(contactInfo24x7), hideSaveCancel: true }),
|
|
57
|
-
React.createElement(CaseGroup, null),
|
|
58
57
|
React.createElement(CaseLanguageSelector, null),
|
|
58
|
+
React.createElement(CaseGroup, null),
|
|
59
59
|
canSeeEmailNotifications && React.createElement(CaseContactSelector, null),
|
|
60
60
|
React.createElement(RHAssociatesSelector, null),
|
|
61
61
|
React.createElement(OpenReferenceNumber, { inlineEditable: false, hideSaveCancel: true }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SessionRestore.d.ts","sourceRoot":"","sources":["../../../../src/components/SessionRestore/SessionRestore.tsx"],"names":[],"mappings":"AAUA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAQvD,OAAO,EAGH,eAAe,EAElB,MAAM,iCAAiC,CAAC;AAiBzC,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;CACpD;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"SessionRestore.d.ts","sourceRoot":"","sources":["../../../../src/components/SessionRestore/SessionRestore.tsx"],"names":[],"mappings":"AAUA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAQvD,OAAO,EAGH,eAAe,EAElB,MAAM,iCAAiC,CAAC;AAiBzC,UAAU,MAAM;IACZ,UAAU,EAAE,mBAAmB,CAAC,eAAe,CAAC,CAAC;CACpD;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,eA8U3C"}
|
|
@@ -192,7 +192,6 @@ export function SessionRestore(props) {
|
|
|
192
192
|
// Automatically restoring a troubleshooting session in case creation can lead to overwriting open-case section details
|
|
193
193
|
// Making sure we prefer already filled information in this case.
|
|
194
194
|
if (isAutoRestoringSession && !isCaseSubmit && isCaseCreate) {
|
|
195
|
-
sessionDetails.type = caseDetails.caseType;
|
|
196
195
|
sessionDetails.accountNumber = caseDetails.accountNumberRef;
|
|
197
196
|
sessionDetails.contactSsoUsername = caseDetails.contactSSOName;
|
|
198
197
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WidgetFileSelectorImage.d.ts","sourceRoot":"","sources":["../../../../../../src/components/shared/fileUpload/fileSelectors/WidgetFileSelectorImage.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAS5D,UAAU,MAAO,SAAQ,gBAAgB;IACrC,WAAW,EAAE,OAAO,CAAC;IACrB,SAAS,EAAE,OAAO,CAAC;CACtB;AAED,iBAAS,uBAAuB,CAAC,EAAE,EAAO,EAAE,SAAc,EAAE,WAAW,EAAE,SAAiB,EAAE,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"WidgetFileSelectorImage.d.ts","sourceRoot":"","sources":["../../../../../../src/components/shared/fileUpload/fileSelectors/WidgetFileSelectorImage.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAS5D,UAAU,MAAO,SAAQ,gBAAgB;IACrC,WAAW,EAAE,OAAO,CAAC;IACrB,SAAS,EAAE,OAAO,CAAC;CACtB;AAED,iBAAS,uBAAuB,CAAC,EAAE,EAAO,EAAE,SAAc,EAAE,WAAW,EAAE,SAAiB,EAAE,EAAE,MAAM,eA4DnG;AAED,eAAe,uBAAuB,CAAC"}
|
|
@@ -32,11 +32,17 @@ function WidgetFileSelectorImage({ id = '', className = '', isSessionId, isPriva
|
|
|
32
32
|
' ',
|
|
33
33
|
React.createElement("p", { className: "pf-u-danger-color-200" }, rejectedFiles.map((rejectedFile) => {
|
|
34
34
|
const isImage = /image\/*/.test(rejectedFile.type);
|
|
35
|
-
return !isImage
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
35
|
+
return !isImage ? (React.createElement("div", null,
|
|
36
|
+
"$",
|
|
37
|
+
rejectedFile.name,
|
|
38
|
+
" ",
|
|
39
|
+
React.createElement(Trans, null, "is not an image"))) : rejectedFile.size > MAX_SIZE ? (React.createElement("div", null,
|
|
40
|
+
"$",
|
|
41
|
+
rejectedFile.name,
|
|
42
|
+
" ",
|
|
43
|
+
React.createElement(Trans, null, "exceeded max size limit of"),
|
|
44
|
+
" $",
|
|
45
|
+
humanizeSize(MAX_SIZE))) : ('');
|
|
40
46
|
}))));
|
|
41
47
|
}
|
|
42
48
|
export default WidgetFileSelectorImage;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseHelpers.d.ts","sourceRoot":"","sources":["../../../src/reducers/CaseHelpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,qDAAqD,CAAC;AACpG,OAAO,EAAE,YAAY,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,yCAAyC,CAAC;AACvG,OAAO,EAAE,YAAY,EAAE,MAAM,iDAAiD,CAAC;AAC/E,OAAO,EAAE,QAAQ,EAAE,MAAM,wCAAwC,CAAC;AAClE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KAAG,OAE5E,CAAC;AAEF,eAAO,MAAM,yBAAyB,gBACrB,YAAY,6BACE,MAAM,mBAChB,MAAM,KACxB,QAAQ,YAAY,CA+BtB,CAAC;AACF,eAAO,MAAM,yBAAyB,gBACrB,QAAQ,YAAY,CAAC,gCACJ,QAAQ,EAAE,KACzC,eA2CF,CAAC"}
|
|
@@ -102,6 +102,9 @@ export const getSeverityDescription = (severity) => {
|
|
|
102
102
|
export const isClusterIDValid = (caseState, allProducts) => {
|
|
103
103
|
const case_details = caseState.caseDetails;
|
|
104
104
|
const productHasClusterID = isClusterIdEnabledForProduct(case_details.product, allProducts);
|
|
105
|
+
//if product doesn't have clusterId we don't need to validate value
|
|
106
|
+
if (!productHasClusterID)
|
|
107
|
+
return true;
|
|
105
108
|
const majorVersion = (case_details.version && getVersion(case_details.version).major) || '';
|
|
106
109
|
const isOpenShiftV3 = case_details.product === 'OpenShift Container Platform' && majorVersion === '3';
|
|
107
110
|
const hasValidClusterId = () => !isEmpty(case_details.openshiftClusterID) &&
|
|
@@ -122,9 +125,7 @@ export const isClusterIDValid = (caseState, allProducts) => {
|
|
|
122
125
|
const hasValidV3ClusterName = () => isEmpty(case_details.openshiftClusterID) &&
|
|
123
126
|
!isEmpty(caseState.v3ClusterName) &&
|
|
124
127
|
(case_details.noClusterIdReasonExplanation === 'v3-cluster' || isOpenShiftV3);
|
|
125
|
-
return
|
|
126
|
-
? hasValidClusterId() || hasValidReason() || hasValidReasonExplanation() || hasValidV3ClusterName()
|
|
127
|
-
: true;
|
|
128
|
+
return hasValidClusterId() || hasValidReason() || hasValidReasonExplanation() || hasValidV3ClusterName();
|
|
128
129
|
};
|
|
129
130
|
// Add a !isEmpty to to make any KTQuestion Mandatory in isCaseStateValid
|
|
130
131
|
export const isCaseStateValid = (caseState, loggedInUserJwtToken) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rh-support/troubleshoot",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -73,10 +73,10 @@
|
|
|
73
73
|
"@patternfly/react-core": "4.264.0",
|
|
74
74
|
"@progress/kendo-drawing": "^1.6.0",
|
|
75
75
|
"@progress/kendo-react-pdf": "^3.12.0",
|
|
76
|
-
"@rh-support/components": "1.
|
|
77
|
-
"@rh-support/react-context": "1.0
|
|
76
|
+
"@rh-support/components": "1.3.0",
|
|
77
|
+
"@rh-support/react-context": "1.1.0",
|
|
78
78
|
"@rh-support/types": "0.2.1-beta.58",
|
|
79
|
-
"@rh-support/user-permissions": "1.0
|
|
79
|
+
"@rh-support/user-permissions": "1.1.0",
|
|
80
80
|
"@rh-support/utils": "1.0.10-beta.58",
|
|
81
81
|
"@types/react-redux": "^7.1.12",
|
|
82
82
|
"@types/redux": "^3.6.0",
|
|
@@ -145,5 +145,5 @@
|
|
|
145
145
|
"not ie <= 11",
|
|
146
146
|
"not op_mini all"
|
|
147
147
|
],
|
|
148
|
-
"gitHead": "
|
|
148
|
+
"gitHead": "4b6aad750ee63be3cd580f2bbb26772accd89ae0"
|
|
149
149
|
}
|