@rh-support/components 1.1.22 → 1.1.23

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.
@@ -1,4 +1,5 @@
1
1
  /// <reference types="react" />
2
+ import './errorMessage.scss';
2
3
  export interface IAppErrorObj {
3
4
  title: string;
4
5
  message: string | JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"errorMessage.d.ts","sourceRoot":"","sources":["../../../src/helperFunctions/errorMessage.tsx"],"names":[],"mappings":";AAKA,MAAM,WAAW,YAAY;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,CAAC;CACjC;AAED,MAAM,WAAW,SAAS;IACtB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;CACxC;AAqCD,iBAAS,wBAAwB,CAAC,KAAK,KAAA,EAAE,aAAa,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,GAAG,CAAC,OAAO,CAwCxF;AAED,iBAAS,iBAAiB,CAAC,KAAK,KAAA,EAAE,WAAW,CAAC,EAAE,SAAS,GAAG,MAAM,CAIjE;AAED,OAAO,EAAE,wBAAwB,EAAE,iBAAiB,EAAE,CAAC"}
1
+ {"version":3,"file":"errorMessage.d.ts","sourceRoot":"","sources":["../../../src/helperFunctions/errorMessage.tsx"],"names":[],"mappings":";AAAA,OAAO,qBAAqB,CAAC;AAS7B,MAAM,WAAW,YAAY;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,CAAC;CACjC;AAED,MAAM,WAAW,SAAS;IACtB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;CACxC;AAsDD,iBAAS,wBAAwB,CAAC,KAAK,KAAA,EAAE,aAAa,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,GAAG,CAAC,OAAO,CAwCxF;AAED,iBAAS,iBAAiB,CAAC,KAAK,KAAA,EAAE,WAAW,CAAC,EAAE,SAAS,GAAG,MAAM,CAIjE;AAED,OAAO,EAAE,wBAAwB,EAAE,iBAAiB,EAAE,CAAC"}
@@ -4,14 +4,21 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.errorMessageTitle = exports.formattedApiErrorMessage = void 0;
7
+ require("./errorMessage.scss");
8
+ var react_core_1 = require("@patternfly/react-core");
9
+ var external_link_alt_icon_1 = __importDefault(require("@patternfly/react-icons/dist/js/icons/external-link-alt-icon"));
7
10
  var isEmpty_1 = __importDefault(require("lodash/isEmpty"));
8
11
  var react_1 = __importDefault(require("react"));
9
12
  var SupportFeedbackForm_1 = require("../SupportFeedbackForm");
10
13
  var defaultTitle = "Sorry, we're experiencing an error";
11
- var defaultErrorMessage = (react_1.default.createElement("p", null,
12
- "Please ",
13
- react_1.default.createElement(SupportFeedbackForm_1.SupportFeedbackForm, { isInline: true }),
14
- " if you continue to see this message."));
14
+ var errorMessageButtonLabel = 'contact us';
15
+ var defaultErrorMessage = (react_1.default.createElement("p", { className: "pf-u-mb-0" },
16
+ "Try refreshing the page. Please ",
17
+ react_1.default.createElement(SupportFeedbackForm_1.SupportFeedbackForm, { isInline: true, buttonLabel: errorMessageButtonLabel }),
18
+ " if the problem persists.",
19
+ react_1.default.createElement("br", null),
20
+ react_1.default.createElement(react_core_1.Button, { variant: "link", component: "a", href: "https://status.redhat.com/", "data-tracking-id": "redirect-status-portal-button", target: "_blank", icon: react_1.default.createElement(external_link_alt_icon_1.default, { className: "status-portal-button-icon" }), iconPosition: "right", className: "pf-u-pl-0", isInline: true, "aria-label": "View status page" }, "View status page"),
21
+ ' '));
15
22
  var defaultErrorObj = {
16
23
  500: {
17
24
  title: defaultTitle,
@@ -0,0 +1,3 @@
1
+ .status-portal-button-icon {
2
+ font-size: var(--pf-global--icon--FontSize--sm);
3
+ }
@@ -1,4 +1,5 @@
1
1
  /// <reference types="react" />
2
+ import './errorMessage.scss';
2
3
  export interface IAppErrorObj {
3
4
  title: string;
4
5
  message: string | JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"errorMessage.d.ts","sourceRoot":"","sources":["../../../src/helperFunctions/errorMessage.tsx"],"names":[],"mappings":";AAKA,MAAM,WAAW,YAAY;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,CAAC;CACjC;AAED,MAAM,WAAW,SAAS;IACtB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;CACxC;AAqCD,iBAAS,wBAAwB,CAAC,KAAK,KAAA,EAAE,aAAa,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,GAAG,CAAC,OAAO,CAwCxF;AAED,iBAAS,iBAAiB,CAAC,KAAK,KAAA,EAAE,WAAW,CAAC,EAAE,SAAS,GAAG,MAAM,CAIjE;AAED,OAAO,EAAE,wBAAwB,EAAE,iBAAiB,EAAE,CAAC"}
1
+ {"version":3,"file":"errorMessage.d.ts","sourceRoot":"","sources":["../../../src/helperFunctions/errorMessage.tsx"],"names":[],"mappings":";AAAA,OAAO,qBAAqB,CAAC;AAS7B,MAAM,WAAW,YAAY;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,GAAG,GAAG,CAAC,OAAO,CAAC;CACjC;AAED,MAAM,WAAW,SAAS;IACtB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;CACxC;AAsDD,iBAAS,wBAAwB,CAAC,KAAK,KAAA,EAAE,aAAa,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,GAAG,CAAC,OAAO,CAwCxF;AAED,iBAAS,iBAAiB,CAAC,KAAK,KAAA,EAAE,WAAW,CAAC,EAAE,SAAS,GAAG,MAAM,CAIjE;AAED,OAAO,EAAE,wBAAwB,EAAE,iBAAiB,EAAE,CAAC"}
@@ -1,11 +1,18 @@
1
+ import './errorMessage.scss';
2
+ import { Button } from '@patternfly/react-core';
3
+ import ExternalLinkAltIcon from '@patternfly/react-icons/dist/js/icons/external-link-alt-icon';
1
4
  import isEmpty from 'lodash/isEmpty';
2
5
  import React from 'react';
3
6
  import { SupportFeedbackForm } from '../SupportFeedbackForm';
4
7
  const defaultTitle = "Sorry, we're experiencing an error";
5
- const defaultErrorMessage = (React.createElement("p", null,
6
- "Please ",
7
- React.createElement(SupportFeedbackForm, { isInline: true }),
8
- " if you continue to see this message."));
8
+ const errorMessageButtonLabel = 'contact us';
9
+ const defaultErrorMessage = (React.createElement("p", { className: "pf-u-mb-0" },
10
+ "Try refreshing the page. Please ",
11
+ React.createElement(SupportFeedbackForm, { isInline: true, buttonLabel: errorMessageButtonLabel }),
12
+ " if the problem persists.",
13
+ React.createElement("br", null),
14
+ React.createElement(Button, { variant: "link", component: "a", href: "https://status.redhat.com/", "data-tracking-id": "redirect-status-portal-button", target: "_blank", icon: React.createElement(ExternalLinkAltIcon, { className: "status-portal-button-icon" }), iconPosition: "right", className: "pf-u-pl-0", isInline: true, "aria-label": "View status page" }, "View status page"),
15
+ ' '));
9
16
  const defaultErrorObj = {
10
17
  500: {
11
18
  title: defaultTitle,
@@ -0,0 +1,3 @@
1
+ .status-portal-button-icon {
2
+ font-size: var(--pf-global--icon--FontSize--sm);
3
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rh-support/components",
3
- "version": "1.1.22",
3
+ "version": "1.1.23",
4
4
  "description": "Contains all reusabel components for support app",
5
5
  "author": "Vikas Rathee <vrathee@redhat.com>",
6
6
  "license": "ISC",
@@ -128,5 +128,5 @@
128
128
  "not ie <= 11",
129
129
  "not op_mini all"
130
130
  ],
131
- "gitHead": "95f6b6477203d61a26c97454278664b6023eb2cf"
131
+ "gitHead": "1fba07cc7a41e8388393d62c86e3c12df383f428"
132
132
  }