qt-ui-kit 1.0.47 → 1.0.49

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/dist/index.mjs CHANGED
@@ -11180,6 +11180,7 @@ var IntegrationService = /* @__PURE__ */ ((IntegrationService6) => {
11180
11180
  IntegrationService6["MSMAIL"] = "microsoft_mail";
11181
11181
  IntegrationService6["MSCAL"] = "microsoft_calendar";
11182
11182
  IntegrationService6["AJIRA"] = "atlassian_jira";
11183
+ IntegrationService6["CLKUP"] = "clickup";
11183
11184
  return IntegrationService6;
11184
11185
  })(IntegrationService || {});
11185
11186
  var BaseIconName = /* @__PURE__ */ ((BaseIconName2) => {
@@ -16036,8 +16037,12 @@ function SingleEvent({
16036
16037
  return /* @__PURE__ */ jsxs20(
16037
16038
  "div",
16038
16039
  {
16039
- className: "flex flex-col rounded-3xl bg-qtneutral-200 py-4 px-4 gap-4 h-min",
16040
- onClick: () => setExpanded(!expanded),
16040
+ className: "flex flex-col rounded-3xl bg-qtneutral-200 py-4 px-4 gap-4 h-min debug",
16041
+ onClick: (e) => {
16042
+ if (e.target === e.currentTarget) {
16043
+ setExpanded(!expanded);
16044
+ }
16045
+ },
16041
16046
  children: [
16042
16047
  /* @__PURE__ */ jsxs20("div", { className: "flex gap-2 place-items-center", children: [
16043
16048
  /* @__PURE__ */ jsx30(
@@ -16101,7 +16106,10 @@ function EventCard({
16101
16106
  urgency: d.urgency,
16102
16107
  service: d.service,
16103
16108
  body: d.eventBody,
16104
- startExpanded: i == eventData.length - 1
16109
+ startExpanded: i == eventData.length - 1,
16110
+ sender: d.sender,
16111
+ source: d.source,
16112
+ subjectLine: d.subjectLine
16105
16113
  }
16106
16114
  )) : /* @__PURE__ */ jsx31(Fragment11, { children: " " }) });
16107
16115
  case "ticket" /* TICKET */:
@@ -16111,7 +16119,10 @@ function EventCard({
16111
16119
  urgency: d.urgency,
16112
16120
  service: d.service,
16113
16121
  body: d.eventBody,
16114
- startExpanded: i == eventData.length - 1
16122
+ startExpanded: i == eventData.length - 1,
16123
+ sender: d.sender,
16124
+ source: d.source,
16125
+ subjectLine: d.subjectLine
16115
16126
  }
16116
16127
  )) : /* @__PURE__ */ jsx31(Fragment11, { children: " " }) });
16117
16128
  default:
@@ -16142,7 +16153,11 @@ function EventCard({
16142
16153
  }
16143
16154
 
16144
16155
  // src/components/organisms/message_body/email_body.tsx
16156
+ import DOMPurify from "dompurify";
16145
16157
  import { jsx as jsx32, jsxs as jsxs22 } from "react/jsx-runtime";
16158
+ function isHtml(content) {
16159
+ return /<\/?[a-z][\s\S]*>/i.test(content);
16160
+ }
16146
16161
  function EmailBody({
16147
16162
  subjectLine,
16148
16163
  to,
@@ -16158,13 +16173,20 @@ function EmailBody({
16158
16173
  /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`Subject: ${subjectLine}`] }),
16159
16174
  /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`To: ${to}`] }),
16160
16175
  /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`Date: ${date}`] }),
16161
- /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`from: ${from}`] }),
16176
+ /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`From: ${from}`] }),
16162
16177
  /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`CC: ${CC}`] }),
16163
16178
  /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`BCC: ${BCC}`] }),
16164
16179
  /* @__PURE__ */ jsx32(MetadataRow, { metadata: [`Attachments: ${attachments}`] })
16165
16180
  ] }),
16166
16181
  /* @__PURE__ */ jsx32("hr", { className: "text-qtneutral-500" }),
16167
- /* @__PURE__ */ jsx32("div", { className: "body-medium", children: body })
16182
+ /* @__PURE__ */ jsx32("div", { className: "body-medium prose break-all", children: body ? isHtml(body) ? /* @__PURE__ */ jsx32(
16183
+ "div",
16184
+ {
16185
+ dangerouslySetInnerHTML: {
16186
+ __html: DOMPurify.sanitize(body)
16187
+ }
16188
+ }
16189
+ ) : /* @__PURE__ */ jsx32("pre", { className: "whitespace-pre-wrap", children: body }) : null })
16168
16190
  ] });
16169
16191
  }
16170
16192
 
@@ -16191,7 +16213,10 @@ function MarkdownRenderer({ content, truncated }) {
16191
16213
  return /* @__PURE__ */ jsx34(
16192
16214
  "div",
16193
16215
  {
16194
- className: clsx8("flex flex-col markdown", truncated && "line-clamp-3"),
16216
+ className: clsx8(
16217
+ "flex flex-col markdown break-all",
16218
+ truncated && "line-clamp-3"
16219
+ ),
16195
16220
  children: /* @__PURE__ */ jsx34(ReactMarkdown, { remarkPlugins: [remarkGfm], children: content })
16196
16221
  }
16197
16222
  );