@paro.io/expert-shared-components 1.12.41 → 1.12.42
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.
|
@@ -12,11 +12,11 @@ interface Message {
|
|
|
12
12
|
}
|
|
13
13
|
interface DiscussionSectionProps {
|
|
14
14
|
disputeId?: string;
|
|
15
|
-
|
|
15
|
+
escalationNumber?: number;
|
|
16
16
|
currentUser: any;
|
|
17
17
|
messages: Message[];
|
|
18
18
|
onCreateMessage: (variables: any) => Promise<any>;
|
|
19
19
|
isInternal?: boolean;
|
|
20
20
|
}
|
|
21
|
-
export declare const DiscussionSection: ({ disputeId,
|
|
21
|
+
export declare const DiscussionSection: ({ disputeId, escalationNumber, currentUser, messages, onCreateMessage, isInternal, }: DiscussionSectionProps) => JSX.Element;
|
|
22
22
|
export {};
|
|
@@ -40,7 +40,7 @@ const react_1 = __importStar(require("react"));
|
|
|
40
40
|
const base_ui_1 = require("@paro.io/base-ui");
|
|
41
41
|
const dayjs_1 = __importDefault(require("dayjs"));
|
|
42
42
|
const base_icons_1 = require("@paro.io/base-icons");
|
|
43
|
-
const DiscussionSection = ({ disputeId,
|
|
43
|
+
const DiscussionSection = ({ disputeId, escalationNumber, currentUser, messages, onCreateMessage, isInternal = false, }) => {
|
|
44
44
|
const [newMessage, setNewMessage] = (0, react_1.useState)('');
|
|
45
45
|
const [visibility, setVisibility] = (0, react_1.useState)('ALL');
|
|
46
46
|
const [isLoading, setIsLoading] = (0, react_1.useState)(false);
|
|
@@ -55,7 +55,7 @@ const DiscussionSection = ({ disputeId, escalationId, currentUser, messages, onC
|
|
|
55
55
|
return;
|
|
56
56
|
try {
|
|
57
57
|
setIsLoading(true);
|
|
58
|
-
const inputData = Object.assign({ messageText: newMessage, visibility, senderId: currentUser === null || currentUser === void 0 ? void 0 : currentUser.userId }, (disputeId ? { disputeId } : {
|
|
58
|
+
const inputData = Object.assign({ messageText: newMessage, visibility, senderId: currentUser === null || currentUser === void 0 ? void 0 : currentUser.userId }, (disputeId ? { disputeId } : { escalationNumber }));
|
|
59
59
|
yield onCreateMessage({
|
|
60
60
|
variables: {
|
|
61
61
|
input: inputData,
|
package/lib/index.d.ts
CHANGED
|
@@ -11,7 +11,6 @@ export { ServiceLinesTemplate } from './components/ServiceLinesTemplate';
|
|
|
11
11
|
export { sharedUtils } from './components/shared/utils';
|
|
12
12
|
export { ActiveProjectCard } from './components/ProjectCard/ActiveProjectCard';
|
|
13
13
|
export { InvoiceCard } from './components/Invoices/InvoiceCard';
|
|
14
|
-
export { DiscussionThread } from './components/DiscussionThread';
|
|
15
14
|
export { fileUploader } from './components/FileUploader';
|
|
16
15
|
export { DiscussionSection } from './components/Invoices/DiscussionSection';
|
|
17
16
|
export { fileDownloader } from './components/FileDownloader';
|
package/lib/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Escalations = exports.fileDownloader = exports.DiscussionSection = exports.fileUploader = exports.
|
|
3
|
+
exports.Escalations = exports.fileDownloader = exports.DiscussionSection = exports.fileUploader = exports.InvoiceCard = exports.ActiveProjectCard = exports.sharedUtils = exports.ServiceLinesTemplate = exports.HeaderNavBar = exports.DocumentCenter = exports.ProfileCompletedPercentage = exports.ExpertProfileHeader = exports.OrganizationChart = exports.FirmEmployeeSection = exports.ClientReferenceSection = exports.Reviews = exports.ReviewsTab = void 0;
|
|
4
4
|
var ReviewsTab_1 = require("./components/ReviewsTab");
|
|
5
5
|
Object.defineProperty(exports, "ReviewsTab", { enumerable: true, get: function () { return ReviewsTab_1.ReviewsTab; } });
|
|
6
6
|
var Reviews_1 = require("./components/Reviews");
|
|
@@ -27,8 +27,6 @@ var ActiveProjectCard_1 = require("./components/ProjectCard/ActiveProjectCard");
|
|
|
27
27
|
Object.defineProperty(exports, "ActiveProjectCard", { enumerable: true, get: function () { return ActiveProjectCard_1.ActiveProjectCard; } });
|
|
28
28
|
var InvoiceCard_1 = require("./components/Invoices/InvoiceCard");
|
|
29
29
|
Object.defineProperty(exports, "InvoiceCard", { enumerable: true, get: function () { return InvoiceCard_1.InvoiceCard; } });
|
|
30
|
-
var DiscussionThread_1 = require("./components/DiscussionThread");
|
|
31
|
-
Object.defineProperty(exports, "DiscussionThread", { enumerable: true, get: function () { return DiscussionThread_1.DiscussionThread; } });
|
|
32
30
|
var FileUploader_1 = require("./components/FileUploader");
|
|
33
31
|
Object.defineProperty(exports, "fileUploader", { enumerable: true, get: function () { return FileUploader_1.fileUploader; } });
|
|
34
32
|
var DiscussionSection_1 = require("./components/Invoices/DiscussionSection");
|