@threatcaptain/tc-reports 0.2.16 → 0.2.17
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.cjs +85 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +86 -2
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -52827,6 +52827,89 @@ const InsuranceHealthGauge = ({
|
|
|
52827
52827
|
) })
|
|
52828
52828
|
] });
|
|
52829
52829
|
};
|
|
52830
|
+
const InsuranceImpactCards = ({
|
|
52831
|
+
score
|
|
52832
|
+
}) => {
|
|
52833
|
+
const getCardClasses = (score2) => {
|
|
52834
|
+
if (score2 >= 775) return "bg-green-50 border-green-200";
|
|
52835
|
+
if (score2 >= 700) return "bg-green-50 border-green-300";
|
|
52836
|
+
if (score2 >= 625) return "bg-blue-50 border-blue-200";
|
|
52837
|
+
if (score2 >= 550) return "bg-yellow-50 border-yellow-200";
|
|
52838
|
+
if (score2 >= 450) return "bg-orange-50 border-orange-200";
|
|
52839
|
+
return "bg-red-50 border-red-200";
|
|
52840
|
+
};
|
|
52841
|
+
const getIconClasses = (score2) => {
|
|
52842
|
+
if (score2 >= 775) return "text-green-600";
|
|
52843
|
+
if (score2 >= 700) return "text-green-600";
|
|
52844
|
+
if (score2 >= 625) return "text-blue-600";
|
|
52845
|
+
if (score2 >= 550) return "text-yellow-600";
|
|
52846
|
+
if (score2 >= 450) return "text-orange-600";
|
|
52847
|
+
return "text-red-600";
|
|
52848
|
+
};
|
|
52849
|
+
const getTextClasses = (score2) => {
|
|
52850
|
+
if (score2 >= 775) return "text-green-900";
|
|
52851
|
+
if (score2 >= 700) return "text-green-900";
|
|
52852
|
+
if (score2 >= 625) return "text-blue-900";
|
|
52853
|
+
if (score2 >= 550) return "text-yellow-900";
|
|
52854
|
+
if (score2 >= 450) return "text-orange-900";
|
|
52855
|
+
return "text-red-900";
|
|
52856
|
+
};
|
|
52857
|
+
const getDescriptionClasses = (score2) => {
|
|
52858
|
+
if (score2 >= 775) return "text-green-700";
|
|
52859
|
+
if (score2 >= 700) return "text-green-700";
|
|
52860
|
+
if (score2 >= 625) return "text-blue-700";
|
|
52861
|
+
if (score2 >= 550) return "text-yellow-700";
|
|
52862
|
+
if (score2 >= 450) return "text-orange-700";
|
|
52863
|
+
return "text-red-700";
|
|
52864
|
+
};
|
|
52865
|
+
const getCoverageText = (score2) => {
|
|
52866
|
+
if (score2 >= 775) return "Premium coverage with enhanced terms";
|
|
52867
|
+
if (score2 >= 700) return "Comprehensive coverage options available";
|
|
52868
|
+
if (score2 >= 625) return "Good coverage with standard terms";
|
|
52869
|
+
if (score2 >= 550) return "Limited coverage options";
|
|
52870
|
+
if (score2 >= 450) return "Restricted coverage with exclusions";
|
|
52871
|
+
return "Minimal coverage, high exclusions";
|
|
52872
|
+
};
|
|
52873
|
+
const getPremiumText = (score2) => {
|
|
52874
|
+
if (score2 >= 775) return "Preferred rates with significant discounts";
|
|
52875
|
+
if (score2 >= 700) return "Competitive rates, potential discounts";
|
|
52876
|
+
if (score2 >= 625) return "Standard market rates";
|
|
52877
|
+
if (score2 >= 550) return "Above-average premiums";
|
|
52878
|
+
if (score2 >= 450) return "High premiums with surcharges";
|
|
52879
|
+
return "Very high premiums, difficult to place";
|
|
52880
|
+
};
|
|
52881
|
+
const getUnderwritingText = (score2) => {
|
|
52882
|
+
if (score2 >= 775) return "Fast-track approval, minimal documentation";
|
|
52883
|
+
if (score2 >= 700) return "Streamlined approval process";
|
|
52884
|
+
if (score2 >= 625) return "Standard review and approval";
|
|
52885
|
+
if (score2 >= 550) return "Extended review process";
|
|
52886
|
+
if (score2 >= 450) return "Detailed review, additional requirements";
|
|
52887
|
+
return "Extensive review, may require risk mitigation plan";
|
|
52888
|
+
};
|
|
52889
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-1 md:grid-cols-3 gap-4", children: [
|
|
52890
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card, { className: getCardClasses(score), children: /* @__PURE__ */ jsxRuntime.jsx(CardContent, { className: "pt-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start space-x-3", children: [
|
|
52891
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Shield, { className: `h-5 w-5 mt-0.5 ${getIconClasses(score)}` }),
|
|
52892
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
52893
|
+
/* @__PURE__ */ jsxRuntime.jsx("h4", { className: `font-medium ${getTextClasses(score)}`, children: "Coverage Availability" }),
|
|
52894
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: `text-sm mt-1 ${getDescriptionClasses(score)}`, children: getCoverageText(score) })
|
|
52895
|
+
] })
|
|
52896
|
+
] }) }) }),
|
|
52897
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card, { className: getCardClasses(score), children: /* @__PURE__ */ jsxRuntime.jsx(CardContent, { className: "pt-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start space-x-3", children: [
|
|
52898
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.TrendingUp, { className: `h-5 w-5 mt-0.5 ${getIconClasses(score)}` }),
|
|
52899
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
52900
|
+
/* @__PURE__ */ jsxRuntime.jsx("h4", { className: `font-medium ${getTextClasses(score)}`, children: "Premium Impact" }),
|
|
52901
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: `text-sm mt-1 ${getDescriptionClasses(score)}`, children: getPremiumText(score) })
|
|
52902
|
+
] })
|
|
52903
|
+
] }) }) }),
|
|
52904
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card, { className: getCardClasses(score), children: /* @__PURE__ */ jsxRuntime.jsx(CardContent, { className: "pt-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start space-x-3", children: [
|
|
52905
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.FileText, { className: `h-5 w-5 mt-0.5 ${getIconClasses(score)}` }),
|
|
52906
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
52907
|
+
/* @__PURE__ */ jsxRuntime.jsx("h4", { className: `font-medium ${getTextClasses(score)}`, children: "Underwriting Process" }),
|
|
52908
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: `text-sm mt-1 ${getDescriptionClasses(score)}`, children: getUnderwritingText(score) })
|
|
52909
|
+
] })
|
|
52910
|
+
] }) }) })
|
|
52911
|
+
] });
|
|
52912
|
+
};
|
|
52830
52913
|
const InsuranceHealthScore = ({ reportData }) => {
|
|
52831
52914
|
const { insuranceHealthData } = reportData;
|
|
52832
52915
|
const score = insuranceHealthData.score || 650;
|
|
@@ -52955,7 +53038,8 @@ const InsuranceHealthScore = ({ reportData }) => {
|
|
|
52955
53038
|
}
|
|
52956
53039
|
})() })
|
|
52957
53040
|
] })
|
|
52958
|
-
] })
|
|
53041
|
+
] }),
|
|
53042
|
+
/* @__PURE__ */ jsxRuntime.jsx(InsuranceImpactCards, { score })
|
|
52959
53043
|
] }),
|
|
52960
53044
|
/* @__PURE__ */ jsxRuntime.jsxs("section", { className: "report-page space-y-6 border-t border-slate-200 pt-8", children: [
|
|
52961
53045
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center space-x-3", children: [
|