hplx-feature-library 1.0.161 → 1.0.163
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/APIAction-Dwk0qXbN.cjs +9 -0
- package/dist/APIAction-Zpy6wLQC.js +4033 -0
- package/dist/Attachments/components/document-canvas/document-pen-tool.d.ts +1 -1
- package/dist/Attachments/components/drag-drop-overlay.d.ts +1 -1
- package/dist/Attachments/components/edit-document-modal.d.ts +1 -1
- package/dist/Attachments/components/uploading-toast.d.ts +1 -1
- package/dist/Attachments/context/index.d.ts +2 -2
- package/dist/Attachments/hooks/useDropdownPosition.d.ts +1 -1
- package/dist/Attachments/index.js +12640 -11157
- package/dist/CameraCapture/index.d.ts +1 -1
- package/dist/PatientAddEdit/index.js +665 -4323
- package/dist/PatientPopup/action/APIAction.d.ts +65 -0
- package/dist/PatientPopup/app/PatientPopupContainer.d.ts +6 -0
- package/dist/PatientPopup/app/PatientPopupContext.d.ts +30 -0
- package/dist/PatientPopup/common/common.d.ts +14 -0
- package/dist/PatientPopup/components/Lab/HPLXLab.d.ts +8 -0
- package/dist/PatientPopup/components/Lab/LISLab.d.ts +8 -0
- package/dist/PatientPopup/components/Lab/LabTable.d.ts +5 -0
- package/dist/PatientPopup/components/Lab/index.d.ts +5 -0
- package/dist/PatientPopup/components/Loader/Loader.d.ts +2 -0
- package/dist/PatientPopup/components/Pagination.d.ts +9 -0
- package/dist/PatientPopup/components/Profile/Abha.d.ts +11 -0
- package/dist/PatientPopup/components/Profile/PatientDetailsModal.d.ts +1 -0
- package/dist/PatientPopup/components/Profile/Profile.d.ts +11 -0
- package/dist/PatientPopup/components/Profile/Sms.d.ts +2 -0
- package/dist/PatientPopup/components/Visits/Table.d.ts +11 -0
- package/dist/PatientPopup/components/Visits/index.d.ts +15 -0
- package/dist/PatientPopup/components/addBills/AddBillFooter.d.ts +2 -0
- package/dist/PatientPopup/components/addBills/AddBills.d.ts +5 -0
- package/dist/PatientPopup/components/addBills/AddBillsTable.d.ts +17 -0
- package/dist/PatientPopup/components/addBills/DropDown.d.ts +15 -0
- package/dist/PatientPopup/components/appointment/AllAppts.d.ts +8 -0
- package/dist/PatientPopup/components/appointment/Appointment.d.ts +2 -0
- package/dist/PatientPopup/components/appointment/AppointmentsTable.d.ts +10 -0
- package/dist/PatientPopup/components/bills/Bills.d.ts +6 -0
- package/dist/PatientPopup/components/bills/BillsTable.d.ts +11 -0
- package/dist/PatientPopup/components/deposit/DepositSection.d.ts +9 -0
- package/dist/PatientPopup/components/mainNavItem/MainNavItem.d.ts +13 -0
- package/dist/PatientPopup/components/patientPopupBody/PatientPopupBody.d.ts +8 -0
- package/dist/PatientPopup/components/patientPopupHeader/PatientPopupHeader.d.ts +10 -0
- package/dist/PatientPopup/components/patientPopupSummary/BillSummary.d.ts +19 -0
- package/dist/PatientPopup/components/patientPopupSummary/ConsultationDetails.d.ts +14 -0
- package/dist/PatientPopup/components/patientPopupSummary/DeleteItem.d.ts +11 -0
- package/dist/PatientPopup/components/patientPopupSummary/DepositRefundSummary.d.ts +8 -0
- package/dist/PatientPopup/components/patientPopupSummary/LabServiceDetails.d.ts +13 -0
- package/dist/PatientPopup/components/patientPopupSummary/OtherServiceDetails.d.ts +13 -0
- package/dist/PatientPopup/components/patientPopupSummary/PatientPopupSummary.d.ts +8 -0
- package/dist/PatientPopup/components/patientPopupSummary/PaymentCard.d.ts +25 -0
- package/dist/PatientPopup/components/patientPopupSummary/ServiceLevelBillSummary.d.ts +18 -0
- package/dist/PatientPopup/components/payments/DepositRefundTable.d.ts +14 -0
- package/dist/PatientPopup/components/payments/OtherServicesTable.d.ts +16 -0
- package/dist/PatientPopup/components/payments/PaymentEditModal.d.ts +15 -0
- package/dist/PatientPopup/components/payments/PaymentHeader.d.ts +7 -0
- package/dist/PatientPopup/components/payments/Payments.d.ts +5 -0
- package/dist/PatientPopup/components/payments/PaymentsTable.d.ts +14 -0
- package/dist/PatientPopup/constants/AppConstants.d.ts +123 -0
- package/dist/PatientPopup/index.d.ts +1 -0
- package/dist/PatientPopup/index.js +135387 -0
- package/dist/PatientPopup/types/hplxAPITypes.d.ts +37 -0
- package/dist/PatientPopup/utils/PrintFontLoader.d.ts +4 -0
- package/dist/PatientPopup/utils/helperFunctions.d.ts +3 -0
- package/dist/PediatricsCalculator/components/PediatricsCalculatorTableContext.d.ts +1 -1
- package/dist/PediatricsCalculator/index.js +1 -1
- package/dist/PediatricsCalculatorTable-bTvt7SWQ.cjs +9 -0
- package/dist/PediatricsCalculatorTable-qu37FR7D.js +1175 -0
- package/dist/ReusableModal-2GKjVVbf.cjs +1 -0
- package/dist/ReusableModal-BL_DwV8I.js +29 -0
- package/dist/Subscription/components/SubscriptionBadge.d.ts +2 -0
- package/dist/changePasswordModal/APIAction/APIActions.d.ts +8 -0
- package/dist/changePasswordModal/component/ChangePasswordModal.d.ts +14 -0
- package/dist/common/APIAction/APIAction.d.ts +17 -44
- package/dist/common/utils/NetworkInstance.d.ts +2 -2
- package/dist/common/utils/common-utils.d.ts +10 -12
- package/dist/components/{customDropdown/CustomDropdown.d.ts → CustomDropdown.d.ts} +2 -2
- package/dist/components/{toggleButtons/ToggleButtons.d.ts → ToggleButtons.d.ts} +1 -1
- package/dist/constants/CommonConstant.d.ts +13 -1
- package/dist/fonts/AnekMalayalam-Bold.ttf +0 -0
- package/dist/fonts/AnekMalayalam-Regular.ttf +0 -0
- package/dist/fonts/Arial-Bold-Italic.ttf +0 -0
- package/dist/fonts/Arial-Bold.ttf +0 -0
- package/dist/fonts/Arial-Italic.ttf +0 -0
- package/dist/fonts/Arial.ttf +0 -0
- package/dist/fonts/IndianRupee.ttf +0 -0
- package/dist/fonts/MuktaMaheePunjabi-Bold.ttf +0 -0
- package/dist/fonts/MuktaMaheePunjabi-Regular.ttf +0 -0
- package/dist/fonts/Noto-Sans-Telugu-Bold.ttf +0 -0
- package/dist/fonts/Noto-Sans-Telugu-Regular.ttf +0 -0
- package/dist/fonts/NotoNastaliqUrdu-Bold.ttf +0 -0
- package/dist/fonts/NotoNastaliqUrdu-Regular.ttf +0 -0
- package/dist/fonts/NotoSansArabic-Bold.ttf +0 -0
- package/dist/fonts/NotoSansArabic.ttf +0 -0
- package/dist/fonts/NotoSansHindi-Bold.ttf +0 -0
- package/dist/fonts/NotoSansHindi.ttf +0 -0
- package/dist/fonts/NotoSansKannada-Bold.ttf +0 -0
- package/dist/fonts/NotoSansKannada.ttf +0 -0
- package/dist/fonts/NotoSansOriya-Bold.ttf +0 -0
- package/dist/fonts/NotoSansOriya.ttf +0 -0
- package/dist/fonts/NotoSansTamil-Bold.ttf +0 -0
- package/dist/fonts/NotoSansTamil.ttf +0 -0
- package/dist/fonts/NotoSerifGujarati-Bold.ttf +0 -0
- package/dist/fonts/NotoSerifGujarati-Regular.ttf +0 -0
- package/dist/fonts/Roboto-Regular.ttf +0 -0
- package/dist/fonts/Times-Bold-Italic.ttf +0 -0
- package/dist/fonts/Times-Bold.ttf +0 -0
- package/dist/fonts/Times-Italic.ttf +0 -0
- package/dist/fonts/Times.ttf +0 -0
- package/dist/fonts/TiroBangla-Bold.ttf +0 -0
- package/dist/fonts/TiroBangla-Regular.ttf +0 -0
- package/dist/fonts/Verdana-Bold-Italic.ttf +0 -0
- package/dist/fonts/Verdana-Bold.ttf +0 -0
- package/dist/fonts/Verdana-Italic.ttf +0 -0
- package/dist/fonts/Verdana.ttf +0 -0
- package/dist/hooks/useMediaQuery.d.ts +1 -0
- package/dist/hplx-feature-library.css +1 -1
- package/dist/index-BzwuwvT5.js +961 -0
- package/dist/index-CJ2AKRoq.cjs +102 -0
- package/dist/index-CRCsQdYf.cjs +32 -0
- package/dist/{index-Cl3h7bnz.js → index-UPYT3B9g.js} +2823 -2700
- package/dist/index.d.ts +0 -5
- package/dist/index.js +2 -12
- package/dist/nineDots/NineDotsTypes.d.ts +22 -0
- package/dist/nineDots/NineDotsUtils.d.ts +3 -0
- package/dist/nineDots/nineDots.d.ts +3 -0
- package/dist/searchPatients/SearchPatients.d.ts +11 -0
- package/dist/types/ApiResponseTypes.d.ts +49 -8
- package/dist/types/CommonTypes.d.ts +37 -10
- package/dist/types/PatientAddEditTypes.d.ts +2 -8
- package/dist/types/PatientPopupTypes/index.js +1 -0
- package/dist/types/PatientPopupTypes.d.ts +836 -0
- package/dist/userProfile/APIAction/APIActions.d.ts +18 -0
- package/dist/userProfile/UserProfile.d.ts +18 -0
- package/dist/userProfile/UserProfileItem.d.ts +7 -0
- package/dist/warning-BozzKWdr.js +38 -0
- package/dist/warning-W0tkkrLJ.cjs +1 -0
- package/package.json +22 -33
- package/dist/AlertPopup/index.js +0 -79
- package/dist/AllInvestigations/components/AllInvestigationsTable.d.ts +0 -19
- package/dist/AllInvestigations/index.d.ts +0 -1
- package/dist/AllInvestigations/index.js +0 -4
- package/dist/AllInvestigations/utils/test-tange-util.d.ts +0 -8
- package/dist/AllInvestigationsTable-9CE_uDGv.cjs +0 -80
- package/dist/AllInvestigationsTable-HC9dOdiS.js +0 -16964
- package/dist/CustomDropdown/index.js +0 -256
- package/dist/DateTimePicker/DateAndTimePicker/index.js +0 -5908
- package/dist/PediatricsCalculatorTable-CB1YOoVy.js +0 -833
- package/dist/PediatricsCalculatorTable-CPXBdrqk.cjs +0 -1
- package/dist/ReusableTable/ReusableTable.d.ts +0 -3
- package/dist/ReusableTable/ReusableTableConstants.d.ts +0 -8
- package/dist/ReusableTable/ReusableTableTypes.d.ts +0 -96
- package/dist/ReusableTable/components/EmptyTableContainer.d.ts +0 -12
- package/dist/ReusableTable/components/FilterCheckbox.d.ts +0 -8
- package/dist/ReusableTable/components/FilterDropdown.d.ts +0 -17
- package/dist/ReusableTable/components/Pagination.d.ts +0 -2
- package/dist/ReusableTable/components/TableBody.d.ts +0 -2
- package/dist/ReusableTable/components/TableCell.d.ts +0 -3
- package/dist/ReusableTable/components/TableFilterSelect.d.ts +0 -12
- package/dist/ReusableTable/components/TableHead.d.ts +0 -2
- package/dist/ReusableTable/components/TableMain.d.ts +0 -2
- package/dist/ReusableTable/components/TableRow.d.ts +0 -3
- package/dist/ReusableTable/context/TableContext.d.ts +0 -21
- package/dist/ReusableTable/context/TableContextBase.d.ts +0 -26
- package/dist/ReusableTable/context/useTableContext.d.ts +0 -2
- package/dist/ToggleButtons/index.js +0 -17
- package/dist/TrendGraphs/AreaChartComponent.d.ts +0 -9
- package/dist/TrendGraphs/LineChartComponent/DataPointToolTip.d.ts +0 -16
- package/dist/TrendGraphs/LineChartComponent/LineChartBody.d.ts +0 -2
- package/dist/TrendGraphs/LineChartComponent/LineChartHeader.d.ts +0 -2
- package/dist/TrendGraphs/LineChartComponent/index.d.ts +0 -2
- package/dist/TrendGraphs/context/index.d.ts +0 -2
- package/dist/TrendGraphs/hooks/useTrendGraphContext.d.ts +0 -2
- package/dist/TrendGraphs/utils/index.d.ts +0 -4
- package/dist/clsx-C11secjj.cjs +0 -1
- package/dist/clsx-OuTLNxxd.js +0 -16
- package/dist/components/Modal.d.ts +0 -5
- package/dist/components/alertPopup/index.d.ts +0 -1
- package/dist/components/customDropdown/index.d.ts +0 -1
- package/dist/components/dateTimePicker/DateAndTimePicker.d.ts +0 -21
- package/dist/components/dateTimePicker/index.d.ts +0 -1
- package/dist/components/toggleButtons/index.d.ts +0 -1
- package/dist/constants/TrendGraphsConstants.d.ts +0 -2
- package/dist/dayjs.min-D8X6dnmr.cjs +0 -1
- package/dist/dayjs.min-SMxpcMQi.js +0 -284
- package/dist/index-BFfWEART.js +0 -995
- package/dist/index-BVfQUI8j.cjs +0 -98
- package/dist/index-CHAEpyb1.cjs +0 -32
- package/dist/index-CJFGOBPb.js +0 -122
- package/dist/index-DfcUmlge.cjs +0 -17
- package/dist/parseISO-AwyR5Nhg.cjs +0 -1
- package/dist/parseISO-Cso9HWPX.js +0 -1414
- package/dist/types/AllInvestigationTypes/index.js +0 -4
- package/dist/types/AllInvestigationTypes.d.ts +0 -45
- package/dist/types/TrendGraphTypes.d.ts +0 -19
- package/dist/useClickOutside-BjJyGTec.js +0 -14
- package/dist/useClickOutside-DsVG12Cs.cjs +0 -1
- /package/dist/components/{alertPopup/AlertPopup.d.ts → AlertPopup.d.ts} +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const e=require("./index-BVfQUI8j.cjs"),c=require("react"),k=require("./constants/PediatricsCalculatorConstants/index.js"),g=require("./CustomDropdown/index.js"),ae=require("./AlertPopup/index.js"),re=require("./index-CHAEpyb1.cjs"),se=c.createContext(null),le=()=>{const i=c.useContext(se);if(!i)throw new Error("usePediatricsCalculatorTableContext must be used inside a MedicineTableProvider");return i},oe=({effectiveEditMode:i,rowData:s,isSavedToLibrary:j,onSave:_,onCancel:b,onEdit:E,onCheckboxToggle:o})=>{const{variant:w,externallyTriggeredEditMode:L,setRowToDelete:R,openPopupForRow:D}=le();return w==="standard"?i?e.jsxRuntimeExports.jsxs("div",{className:"hfl-grid hfl-grid-cols-[1fr_1fr] hfl-border-1 hfl-border-Gray-200 hfl-rounded-lg ",children:[e.jsxRuntimeExports.jsx("button",{className:"hfl-px-3 hfl-py-1 hfl-text-Blue_gray-800 hfl-border-r-1 hover:hfl-bg-Primary-50",onClick:_,children:e.jsxRuntimeExports.jsx(e.bs,{variant:"Medium",type:"Text xs",className:"hfl-text-Blue_gray-800",children:"Save"})}),e.jsxRuntimeExports.jsx("button",{className:"hfl-px-3 hfl-py-2 hfl-text-Error-600 hover:hfl-bg-Error-50",onClick:b,children:e.jsxRuntimeExports.jsx(e.bs,{variant:"Medium",type:"Text xs",className:"",children:"Cancel"})})]}):e.jsxRuntimeExports.jsxs("div",{className:"hfl-grid hfl-grid-cols-[1fr_1fr_1fr] hfl-border-1 hfl-border-Gray-200 hfl-rounded-lg",children:[e.jsxRuntimeExports.jsx("button",{className:"hfl-px-3 hfl-py-1 hfl-text-Blue_gray-800 hover:hfl-bg-Primary-50",onClick:E,children:e.jsxRuntimeExports.jsx(e.bs,{variant:"Medium",type:"Text xs",className:"",children:"Edit"})}),e.jsxRuntimeExports.jsx("button",{className:"hfl-px-3 hfl-py-2 hfl-text-Blue_gray-800 hfl-border-x-1 hover:hfl-bg-Primary-50",onClick:()=>D?.(s),children:e.jsxRuntimeExports.jsx(e.bs,{variant:"Medium",type:"Text xs",className:"",children:"Copy"})}),e.jsxRuntimeExports.jsx("button",{className:"hx_delete hfl-px-3 hfl-py-2 hfl-text-Error-500 hover:hfl-bg-Error-50",onClick:()=>R?.(s.rowId)})]}):e.jsxRuntimeExports.jsx(e.Os,{disabled:!L,text:"Save this to Pediatric Calculator Library ",id:s.rowId,size:"md",onClick:o,isMarked:j??!1,checkboxClasses:"hfl-mt-2",checkBoxInnerDivClasses:"hfl-text-Blue-600 hfl-bg-Blue-50"},s.rowId)};var Q,te;function ce(){if(te)return Q;te=1;var i="Expected a function",s=NaN,j="[object Symbol]",_=/^\s+|\s+$/g,b=/^[-+]0x[0-9a-f]+$/i,E=/^0b[01]+$/i,o=/^0o[0-7]+$/i,w=parseInt,L=typeof e.commonjsGlobal=="object"&&e.commonjsGlobal&&e.commonjsGlobal.Object===Object&&e.commonjsGlobal,R=typeof self=="object"&&self&&self.Object===Object&&self,D=L||R||Function("return this")(),F=Object.prototype,W=F.toString,O=Math.max,n=Math.min,d=function(){return D.Date.now()};function N(a,m,x){var f,T,v,r,l,I,y=0,A=!1,V=!1,t=!0;if(typeof a!="function")throw new TypeError(i);m=z(m)||0,M(x)&&(A=!!x.leading,V="maxWait"in x,v=V?O(z(x.maxWait)||0,m):v,t="trailing"in x?!!x.trailing:t);function u(h){var $=f,J=T;return f=T=void 0,y=h,r=a.apply(J,$),r}function p(h){return y=h,l=setTimeout(K,m),A?u(h):r}function S(h){var $=h-I,J=h-y,ee=m-$;return V?n(ee,v-J):ee}function q(h){var $=h-I,J=h-y;return I===void 0||$>=m||$<0||V&&J>=v}function K(){var h=d();if(q(h))return Z(h);l=setTimeout(K,S(h))}function Z(h){return l=void 0,t&&f?u(h):(f=T=void 0,r)}function ne(){l!==void 0&&clearTimeout(l),y=0,f=I=T=l=void 0}function ie(){return l===void 0?r:Z(d())}function X(){var h=d(),$=q(h);if(f=arguments,T=this,I=h,$){if(l===void 0)return p(I);if(V)return l=setTimeout(K,m),u(I)}return l===void 0&&(l=setTimeout(K,m)),r}return X.cancel=ne,X.flush=ie,X}function M(a){var m=typeof a;return!!a&&(m=="object"||m=="function")}function C(a){return!!a&&typeof a=="object"}function P(a){return typeof a=="symbol"||C(a)&&W.call(a)==j}function z(a){if(typeof a=="number")return a;if(P(a))return s;if(M(a)){var m=typeof a.valueOf=="function"?a.valueOf():a;a=M(m)?m+"":m}if(typeof a!="string")return a===0?a:+a;a=a.replace(_,"");var x=E.test(a);return x||o.test(a)?w(a.slice(2),x?2:8):b.test(a)?s:+a}return Q=N,Q}var ue=ce();const de=e.getDefaultExportFromCjs(ue),Y=(i,s)=>{const j=parseFloat(i),_=parseFloat(s);if(!i||!s||isNaN(j)||isNaN(_)||_===0)return"";const b=j/_;return Number.isInteger(b)?b.toString(10):b.toFixed(3).replace(/\.?0+$/,"")},G=i=>/^(\d+)?(\.)?(\d*)?$/.test(i),B=({label:i,children:s})=>e.jsxRuntimeExports.jsxs(e.bs,{variant:"Regular",type:"Text sm",className:"hfl-grid hfl-grid-cols-2 hfl-items-center hfl-text-Blue_gray-800 hfl-justify-between hfl-gap-8",children:[e.jsxRuntimeExports.jsxs("span",{className:"hfl-flex-shrink-0",children:[i,":"]}),e.jsxRuntimeExports.jsx("div",{className:"hfl-flex-1 hfl-min-w-0",children:s})]}),H=({label:i,value:s})=>e.jsxRuntimeExports.jsxs(e.bs,{variant:"Regular",type:"Text sm",className:"hfl-flex hfl-text-Blue_gray-800 hfl-gap-1",children:[e.jsxRuntimeExports.jsxs("span",{className:"hfl-flex-shrink-0",children:[i,":"]}),e.jsxRuntimeExports.jsx(e.bs,{variant:"Bold",type:"Text sm",className:"hfl-text-Blue_gray-800 hfl-break-words hfl-min-w-0",children:s||"--"})]}),U=({children:i,className:s=""})=>e.jsxRuntimeExports.jsx(e.bs,{variant:"Regular",type:"Text sm",className:`hfl-text-Blue_gray-800 hfl-px-2 hfl-break-words hfl-overflow-wrap-anywhere hfl-min-w-0 ${s}`,children:i}),fe=c.memo(function({rowData:s,isEditing:j,setIsEditing:_,onSaveRow:b,allowCustomMedicineInput:E}){const{variant:o,externallyTriggeredEditMode:w,externallyTriggeredEditRowIds:L,getMedicineOptions:R,onRowChange:D,onRowDelete:F}=le(),[W,O]=c.useState([]),[n,d]=c.useState(s),[N,M]=c.useState(s.medicine_name);c.useEffect(()=>{j||M(s.medicine_name)},[s.medicine_name,j]),c.useEffect(()=>{j||d(s)},[s,j]);const C=async t=>(await R?.(t))?.map(p=>({label:p.doctorMedicineName,value:p}))||[],z=w||L?.includes(s.rowId)||j,a=c.useMemo(()=>n.out_of_range||s.out_of_range,[n.out_of_range,s.out_of_range]),m=c.useMemo(()=>n?.isDosageMismatch||s?.isDosageMismatch,[n?.isDosageMismatch,s?.isDosageMismatch]),x=c.useMemo(()=>n.calculation_type===k.C_MedicineCalculatorList[0]?n.calculation_fields:null,[n.calculation_fields,n.calculation_type]),f=c.useMemo(()=>n.calculation_type===k.C_MedicineCalculatorList[1]?n.calculation_fields:null,[n.calculation_fields,n.calculation_type]),T=(t,u)=>{let p;if(t==="calculation_type"){const S=u,q={frequency:n.calculation_fields.frequency,pedia_dosage:o==="standard"?n.calculation_fields.pedia_dosage:n.pedia_dosage};p={...n,calculation_type:S,calculation_fields:S==="mg/kg/dose"?{...k.C_DefaultMgKgFields,...q}:{...k.C_DefaultMlKgFields,...q}}}else p={...n,[t]:u};d(p),o==="prescription"&&v(p,t)},v=c.useMemo(()=>de((t,u)=>{D?.(t,u||void 0)},500),[D]),r=c.useMemo(()=>e.jsxRuntimeExports.jsxs("div",{className:"hfl-mb-1 hfl-flex hfl-w-max hfl-items-center hfl-rounded hfl-border-1 hfl-border-Warning-400 hfl-bg-Warning-50 hfl-p-1 hfl-px-2",children:[e.jsxRuntimeExports.jsx("div",{className:"hx_warning hfl-text-Error-400"}),e.jsxRuntimeExports.jsx(e.bs,{variant:"Regular",type:"Text sm",className:"hfl-px-2 hfl-text-1 hfl-text-Error-500",children:"Dosage exceed safety limits"})]}),[]);c.useEffect(()=>()=>{v.cancel()},[v]);const l=c.useCallback((t,u)=>{d(p=>{let S={...p.calculation_fields,[t]:u};if(t==="frequency"&&o==="standard"){const K=k.C_FrequencyDosageMap[u]||[];K.length>0&&(S={...S,pedia_dosage:K[0]})}const q={...p,calculation_fields:S};return o==="prescription"&&v(q,t),q})},[v,o]),I=async()=>{const t={...n,calculation_fields:{...n.calculation_fields}};await b?.(t)&&v({...t,isNewlyAdded:!1,isEditing:!1})},y=async()=>{if(!s.medicine_name||s.medicine_name.trim()===""){F?.(s.rowId);return}d(s),o==="standard"&&_(!1)},A=t=>o==="prescription"&&(t==="medicine_name"||t==="generic_name"||t==="type"||t==="calculation_type")?!1:z,V=()=>{const t=!(n?.isSavedToLibrary??!1),u={...n,isSavedToLibrary:t};d(u),v(u,"isSavedToLibrary")};return e.jsxRuntimeExports.jsxs("div",{className:`medicine-row hfl-grid hfl-grid-cols-[1.36fr_1.36fr_1.02fr_1.25fr_2.27fr_1.36fr_1.36fr] hfl-gap-2 hfl-px-2 hfl-py-1 hfl-border-b-1 hfl-border-Gray-200 ${z?"hfl-bg-gradient-to-b hfl-from-White_20 hfl-to-Primary-50":""} ${o==="prescription"&&!n.pedia_data_available?"hfl-hidden":""}`,children:[e.jsxRuntimeExports.jsx("div",{className:"hfl-w-full hfl-py-2.5 hfl-min-w-0",children:A("medicine_name")?e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",btnClassName:"hfl-w-full",inputClassName:"hfl-w-full",inputValue:n.medicine_name,showInput:!0,disableInputAutoSize:!0,inputChangeHandler:async t=>{if(T("medicine_name",t),t.trim()){const u=await C(t);O(u)}else O([])},onInputFocus:async()=>{const t=await C(n.medicine_name);O(t)},onChangeHandler:t=>{const u=t.value,p=k.C_MedicineTypeList.find(S=>S.val===u.medicineType);d(S=>({...S,medicine_name:u.doctorMedicineName,medicine_id:u.medicineId,generic_name:u.doctorGenericName,type:p?.type??""})),M(u.doctorMedicineName)},options:W,isSearchable:!0,placeholder:"Search medicine",disabled:!n?.isNewlyAdded,inputProps:{onBlur:t=>{const u=t.relatedTarget;if(!(u&&u.closest(".custom-dropdown-menu"))&&!E){const p=n.medicine_name?.trim()||"";W.some(q=>q.label===p)||d(q=>({...q,medicine_name:N}))}}}}):e.jsxRuntimeExports.jsx(U,{children:s.medicine_name})}),e.jsxRuntimeExports.jsx("div",{className:"hfl-w-full hfl-py-2.5 hfl-min-w-0",children:A("generic_name")?e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",inputClassName:"hfl-w-full",btnClassName:"hfl-w-full",inputValue:n.generic_name,showInput:!0,disableInputAutoSize:!0,inputChangeHandler:t=>T("generic_name",t),hideDropdownIcon:!0}):e.jsxRuntimeExports.jsx(U,{children:s.generic_name})}),e.jsxRuntimeExports.jsx("div",{className:"hfl-w-full hfl-py-2.5 hfl-min-w-0",children:A("type")?e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",btnClassName:"hfl-w-full",placeholder:"Select",showInput:!1,disableInputAutoSize:!0,selectedOption:(()=>{const t=k.C_MedicineTypeList.find(u=>u.type===n.type);return t?{label:t.type,value:t.type}:void 0})(),options:k.C_MedicineTypeList.map(t=>({label:t.type,value:t.type})),onChangeHandler:t=>T("type",t.value)}):e.jsxRuntimeExports.jsx(U,{children:s.type||""})}),e.jsxRuntimeExports.jsx("div",{className:"hfl-w-full hfl-py-2.5 hfl-min-w-0",children:A("calculation_type")?e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",btnClassName:"hfl-w-full",placeholder:"Select",showInput:!1,disableInputAutoSize:!0,selectedOption:{label:n.calculation_type,value:n.calculation_type},options:k.C_MedicineCalculatorList.map(t=>({label:t,value:t})),onChangeHandler:t=>T("calculation_type",t.value)}):e.jsxRuntimeExports.jsx(U,{children:s.calculation_type})}),e.jsxRuntimeExports.jsx("div",{className:"hfl-flex hfl-w-full hfl-flex-col hfl-gap-2 hfl-py-2.5 hfl-px-2",children:A("calculation_fields")?e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[x&&e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx(B,{label:"Drug Strength",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"e.g., 250",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:x.drug_strength||"",inputChangeHandler:t=>{G(t)&&l("drug_strength",t)}})}),e.jsxRuntimeExports.jsx(B,{label:"Dose/mg/kg",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"e.g., 15",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:x.dose_mg_kg||"",inputChangeHandler:t=>{G(t)&&l("dose_mg_kg",t)}})}),e.jsxRuntimeExports.jsx(B,{label:"Frequency",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"Frequency",showInput:!1,selectedOption:n.calculation_fields.frequency?{label:n.calculation_fields.frequency,value:n.calculation_fields.frequency}:void 0,options:k.C_MedicineFrequencyList.map(t=>({label:t,value:t})),onChangeHandler:t=>{l("frequency",t.value)}})}),e.jsxRuntimeExports.jsx(B,{label:"Max Dose (mg)",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"Max mg/dose",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:x.max_mg_dose||"",inputChangeHandler:t=>{G(t)&&l("max_mg_dose",t)}})}),e.jsxRuntimeExports.jsx(B,{label:"Max Day (mg)",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"Max mg/day",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:x.max_mg_day||"",inputChangeHandler:t=>{G(t)&&l("max_mg_day",t)}})})]}),f&&e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx(B,{label:"Drug Strength/mL",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"e.g., 250",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:f.drug_strength||"",inputChangeHandler:t=>{G(t)&&(l("drug_strength",t),l("dose_ml_kg",Y(f.dose_mg_kg,t)))}})}),e.jsxRuntimeExports.jsx(B,{label:"Dose/mg/kg",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"e.g., 15",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:f.dose_mg_kg||"",inputChangeHandler:t=>{G(t)&&(l("dose_mg_kg",t),l("dose_ml_kg",Y(t,f.drug_strength)))}})}),e.jsxRuntimeExports.jsx(B,{label:"Dose/mL/kg",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",disabled:!0,placeholder:"e.g., 5",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:Y(f.dose_mg_kg,f.drug_strength)||"",inputChangeHandler:t=>{G(t)&&l("dose_ml_kg",t)}})}),e.jsxRuntimeExports.jsx(B,{label:"Frequency",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"Frequency",showInput:!1,selectedOption:n.calculation_fields.frequency?{label:n.calculation_fields.frequency,value:n.calculation_fields.frequency}:void 0,options:k.C_MedicineFrequencyList.map(t=>({label:t,value:t})),onChangeHandler:t=>{l("frequency",t.value)}})}),e.jsxRuntimeExports.jsx(B,{label:"Max Dose (mL)",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"Max mL/dose",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:f.max_ml_dose||"",inputChangeHandler:t=>{G(t)&&l("max_ml_dose",t)}})}),e.jsxRuntimeExports.jsx(B,{label:"Max Day (mL)",children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",placeholder:"Max mL/day",showInput:!0,hideDropdownIcon:!0,disableInputAutoSize:!0,inputType:"text",inputValue:f.max_ml_day||"",inputChangeHandler:t=>{G(t)&&l("max_ml_day",t)}})})]})]}):e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[x&&e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx(H,{label:"Drug Strength",value:x.drug_strength}),e.jsxRuntimeExports.jsx(H,{label:"Dose/mg/kg",value:x.dose_mg_kg}),e.jsxRuntimeExports.jsx(H,{label:"Frequency",value:x.frequency}),e.jsxRuntimeExports.jsx(H,{label:"Max Dose (mg)",value:x.max_mg_dose}),e.jsxRuntimeExports.jsx(H,{label:"Max Day (mg)",value:x.max_mg_day})]}),f&&e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx(H,{label:"Drug Strength/mL",value:f.drug_strength}),e.jsxRuntimeExports.jsx(H,{label:"Dose/mg/kg",value:f.dose_mg_kg}),e.jsxRuntimeExports.jsx(H,{label:"Dose/mL/kg",value:f.dose_ml_kg}),e.jsxRuntimeExports.jsx(H,{label:"Frequency",value:f.frequency}),e.jsxRuntimeExports.jsx(H,{label:"Max Dose (mL)",value:f.max_ml_dose}),e.jsxRuntimeExports.jsx(H,{label:"Max Day (mL)",value:f.max_ml_day})]})]})}),e.jsxRuntimeExports.jsx("div",{className:"hfl-w-full hfl-py-2.5 hfl-min-w-0",children:A("pedia_dosage")?(()=>{const t=n.calculation_fields.frequency,u=k.C_FrequencyDosageMap[t]||[];return e.jsxRuntimeExports.jsx(e.jsxRuntimeExports.Fragment,{children:e.jsxRuntimeExports.jsx(g,{wrapperClass:"hfl-w-full",btnClassName:"hfl-w-full",inputClassName:"hfl-w-full",placeholder:"Select",showInput:o!=="standard",disableInputAutoSize:!0,inputValue:o==="standard"?n.calculation_fields.pedia_dosage:n.pedia_dosage,inputChangeHandler:p=>o==="prescription"?T("pedia_dosage",p):l("pedia_dosage",p),selectedOption:o==="standard"?{label:n.calculation_fields.pedia_dosage,value:n.calculation_fields.pedia_dosage}:void 0,options:o!=="prescription"?u.map(p=>({label:p,value:p})):void 0,onChangeHandler:o!=="prescription"?p=>l("pedia_dosage",p.value):void 0,hideDropdownIcon:o==="prescription",showEmptyDropdownPopup:o!=="prescription",showErrorMsg:o==="prescription"?a||m:!1,errorMsg:o==="prescription"&&a?"Dosage Exceeds Safety Limits":o==="prescription"&&m?"Dosage is in mismatch with selected type of Frequency":""})})})():e.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-flex-col hfl-h-full hfl-justify-between hfl-min-w-0",children:[e.jsxRuntimeExports.jsx(U,{children:o==="prescription"?s.pedia_dosage:s.calculation_fields.pedia_dosage}),a&&r]})}),e.jsxRuntimeExports.jsx("div",{className:"hfl-w-full hfl-py-2.5 hfl-min-w-0",children:e.jsxRuntimeExports.jsx(oe,{effectiveEditMode:z,rowData:s,isSavedToLibrary:n.isSavedToLibrary??!1,onSave:I,onCancel:y,onEdit:()=>_(!0),onCheckboxToggle:V})})]})},(i,s)=>i.isEditing===s.isEditing&&i.rowData.rowId===s.rowData.rowId&&i.rowData.isEditing===s.rowData.isEditing&&i.rowData.medicine_name===s.rowData.medicine_name&&i.rowData.generic_name===s.rowData.generic_name&&i.rowData.type===s.rowData.type&&i.rowData.pedia_dosage===s.rowData.pedia_dosage&&i.rowData.calculation_type===s.rowData.calculation_type&&JSON.stringify(i.rowData.calculation_fields)===JSON.stringify(s.rowData.calculation_fields)&&i.rowData.out_of_range===s.rowData.out_of_range&&i.rowData.isDosageMismatch===s.rowData.isDosageMismatch&&i.rowData.calculation_fields.pedia_dosage===s.rowData.calculation_fields.pedia_dosage&&i.rowData?.isNewlyAdded===s.rowData?.isNewlyAdded&&i.rowData?.pedia_data_available===s.rowData?.pedia_data_available),xe=({open:i,onCancel:s,onCopySave:j,rowMedicineData:_,getMedicineOptions:b})=>{const[E,o]=c.useState([]),[w,L]=c.useState(""),[R,D]=c.useState([]),F=c.useCallback(async d=>{const M=(await b?.(d))?.map(C=>({label:C.doctorMedicineName,value:C}));D(M||[])},[b]);c.useEffect(()=>{i&&F(w)},[w,F,i]);const W=d=>{const N=d.value;E.some(C=>C.medicineId===N.medicineId&&C.doctorMedicineName.trim().toLowerCase()===N.doctorMedicineName.trim().toLowerCase())||o(C=>[...C,N]),L(""),D([])},O=d=>{o(N=>N.filter(M=>M.medicineId!==d))},n=async()=>{w.trim()||await F("")};return e.jsxRuntimeExports.jsxs(re.Modal,{isOpen:i,onRequestClose:s,shouldCloseOnOverlayClick:!1,style:{overlay:{backgroundColor:"rgba(52, 64, 84, 0.5)",zIndex:1030},content:{zIndex:1031,maxWidth:"600px",maxHeight:"50vh",height:"auto",margin:"auto",borderRadius:"12px",padding:"0px",display:"flex",flexDirection:"column"}},children:[e.jsxRuntimeExports.jsx(e.bs,{variant:"Bold",type:"Text lg",className:"hfl-text-White hfl-bg-gradient_primary_600_500_90 hfl-px-6 hfl-py-2",children:"Please select medicine to copy"}),e.jsxRuntimeExports.jsxs("div",{className:"hfl-px-6 hfl-py-5 hfl-flex hfl-flex-col hfl-gap-6 hfl-overflow-y-auto hfl-flex-1",children:[e.jsxRuntimeExports.jsx(g,{inputValue:w,showInput:!0,isSearchable:!0,disableInputAutoSize:!0,inputChangeHandler:L,onChangeHandler:W,onInputFocus:n,options:R,placeholder:"Search for medicines"}),e.jsxRuntimeExports.jsx("div",{className:"hfl-flex hfl-flex-wrap hfl-gap-2",children:E.map(d=>e.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-items-center hfl-bg-Gray-100 hfl-px-2 hfl-py-0.5 hfl-rounded-md hfl-gap-1",children:[e.jsxRuntimeExports.jsx(e.bs,{variant:"Regular",type:"Text sm",className:"hfl-text-nowrap",children:d.doctorMedicineName}),e.jsxRuntimeExports.jsx("button",{className:"hfl-text-Blue_gray-800",onClick:()=>O(d.medicineId),children:e.jsxRuntimeExports.jsx("i",{className:"hx_close"})})]},d.doctorMedicineName+d.medicineId))})]}),e.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-justify-end hfl-gap-2.5 hfl-bg-Gray-50 hfl-px-7 hfl-py-3 hfl-border-t hfl-border-Gray-200",children:[e.jsxRuntimeExports.jsx(e.Ku,{size:"md",textField:"Cancel",onClick:s,hierarchy:"Secondary-Grey"}),e.jsxRuntimeExports.jsx(e.Ku,{size:"md",textField:"Save",disabled:!E||E.length==0,onClick:async()=>{await j(_,E)&&s()},className:"hfl-bg-Primary-600 hfl-text-White disabled:hfl-opacity-50 disabled:hfl-cursor-not-allowed",hierarchy:"Primary"})]})]})},pe=c.forwardRef(({data:i=[],variant:s,externallyTriggeredEditRowIds:j=[],externallyTriggeredEditMode:_=!1,allowCustomMedicineInput:b=!0,getMedicineOptions:E,onRowChange:o,onRowDelete:w,onRowCopy:L,onSaveRow:R,externalSaveTrigger:D,setSearchDisabled:F},W)=>{const[O,n]=c.useState(null),[d,N]=c.useState(!1),[M,C]=c.useState(),P=c.useCallback((r,l,I)=>{const y=i.find(V=>V.rowId===r);if(!y)return;const A={...y,...l};o?.(A,I||void 0)},[i,o]),z=c.useCallback(async()=>{const r=i.filter(l=>l.isEditing&&l.medicine_name);if(r.length!==0)try{await R?.(r)&&r.forEach(I=>{o?.({...I,isEditing:!1})})}catch(l){console.error("Bulk save failed",l)}finally{F?.(!1)}},[i,R,o,F]);c.useEffect(()=>{D&&z()},[D,z]),c.useEffect(()=>{const r=i.some(l=>l.isEditing);F?.(r)},[i,F]);const a=c.useCallback(r=>{C(r),N(!0)},[]),m=c.useCallback(async()=>{if(O)try{await w?.(O)}catch(r){console.error("Delete failed",r)}finally{n(null)}},[O,w]),x=c.useCallback(()=>{n(null)},[]),f=c.useCallback(async r=>{try{return await R?.([r])?(o?.({...r,isEditing:!1}),!0):!1}catch(l){return console.error("Save row failed",l),!1}},[R,o]),T=c.useCallback(async()=>{const r=i.filter(l=>l.isEditing&&l.medicine_name);if(r.length===0)return!0;try{const l=await R?.(r);return l&&i.map(y=>y.isEditing?{...y,isEditing:!1}:y).forEach(y=>o?.(y)),!!l}catch(l){return console.error("External bulk save failed",l),!1}},[i,R,o]);c.useImperativeHandle(W,()=>({triggerExternalSave:T}));const v={variant:s,externallyTriggeredEditMode:_,externallyTriggeredEditRowIds:j,getMedicineOptions:E,onRowChange:(r,l)=>{P(r.rowId,r,l),o?.(r,l)},onRowDelete:w,onRowCopy:L,setRowToDelete:n,openPopupForRow:a};return e.jsxRuntimeExports.jsxs("div",{className:"hfl-border-1 hfl-border-Gray-200",children:[e.jsxRuntimeExports.jsx("div",{className:"table-header hfl-grid hfl-grid-cols-[1.36fr_1.36fr_1.02fr_1.25fr_2.27fr_1.36fr_1.36fr] hfl-gap-2 hfl-py-2 hfl-px-2 hfl-font-bold hfl-border-b-1 hfl-border-Gray-200 hfl-bg-Blue_gray-50",children:k.C_Table_Column_Name.map(r=>e.jsxRuntimeExports.jsx(e.bs,{variant:"Medium",type:"Text sm",className:"hfl-text-Blue_gray-600",children:r},r))}),e.jsxRuntimeExports.jsxs(se.Provider,{value:v,children:[e.jsxRuntimeExports.jsx("div",{className:"table-body",children:i.length===0?e.jsxRuntimeExports.jsx(e.bs,{variant:"Medium",type:"Text sm",className:"hfl-text-Blue_gray-600 hfl-px-2 hfl-py-3",children:"No medicines added"}):i.map(r=>e.jsxRuntimeExports.jsx(fe,{rowData:r,isEditing:r.isEditing||!1,setIsEditing:l=>P(r.rowId,{isEditing:l}),onSaveRow:f,allowCustomMedicineInput:b},r.rowId))}),e.jsxRuntimeExports.jsx(ae,{headingText:"Delete Medicine",subHeadingText:"Are you sure you want to delete this medicine?",openState:!!O,positiveButtonText:"Delete",negativeButtonText:"Cancel",positiveActionCallback:m,negativeActionCallback:x,classNameNegativeBtn:"hfl-bg-Blue-600",classNamePositiveBtn:"hfl-bg-Error-500 hover:hfl-bg-Error-700 hfl-text-White",closePopupCallback:x}),e.jsxRuntimeExports.jsx(xe,{open:d,onCancel:()=>N(!1),onCopySave:L,rowMedicineData:M,getMedicineOptions:E})]})]})});exports.PediatricsCalculatorTable=pe;
|
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
import { I_TableFilterProps } from './components/TableFilterSelect';
|
|
2
|
-
import { PinnableValues } from './ReusableTableConstants';
|
|
3
|
-
export interface IPaginationProps {
|
|
4
|
-
activePage: number;
|
|
5
|
-
pageSize: number;
|
|
6
|
-
currentPageRowCount: number;
|
|
7
|
-
totalRecords: number;
|
|
8
|
-
}
|
|
9
|
-
export interface ResuableTableNoDataProps {
|
|
10
|
-
title: string;
|
|
11
|
-
description: string;
|
|
12
|
-
onPageReload: () => void;
|
|
13
|
-
titleClassName?: string;
|
|
14
|
-
descriptionClassName?: string;
|
|
15
|
-
containerClassName?: string;
|
|
16
|
-
buttonClassName?: string;
|
|
17
|
-
imageClassName?: string;
|
|
18
|
-
}
|
|
19
|
-
export interface ReusableTableProps<T> {
|
|
20
|
-
tableRef: React.RefObject<HTMLDivElement>;
|
|
21
|
-
tableMainParentDivRef?: React.RefObject<HTMLDivElement>;
|
|
22
|
-
tableBodyParentDivRef?: React.RefObject<HTMLDivElement>;
|
|
23
|
-
columns: ITableColDef<T>[];
|
|
24
|
-
tableName: string;
|
|
25
|
-
rows: Array<T>;
|
|
26
|
-
paginationProps?: IPaginationProps;
|
|
27
|
-
showPagination?: boolean;
|
|
28
|
-
onPaginationClick?: ((activePage: number) => void) | undefined;
|
|
29
|
-
displayHeaderName?: string;
|
|
30
|
-
tableClassesToOverride?: string;
|
|
31
|
-
headerRowClasses?: string;
|
|
32
|
-
rowClassesForSpecificIndex?: {
|
|
33
|
-
index: number;
|
|
34
|
-
rowClasses: string;
|
|
35
|
-
};
|
|
36
|
-
tableBodyClassesToOverride?: string;
|
|
37
|
-
hideHeader?: boolean;
|
|
38
|
-
displayHeaderClassesToOverride?: string;
|
|
39
|
-
displayPaginationClassesToOverride?: string;
|
|
40
|
-
displayNoDataFoundProps?: ResuableTableNoDataProps;
|
|
41
|
-
enableTableFilter?: boolean;
|
|
42
|
-
tableFilterProps?: I_TableFilterProps;
|
|
43
|
-
headerAndPaginationDivClasses?: string;
|
|
44
|
-
tableMainParentDivClasses?: string;
|
|
45
|
-
tableMainDivClasses?: string;
|
|
46
|
-
}
|
|
47
|
-
export interface ITableColDef<T> {
|
|
48
|
-
field: string;
|
|
49
|
-
headerCellClasses?: string;
|
|
50
|
-
cellClasses?: string;
|
|
51
|
-
description?: string;
|
|
52
|
-
fieldHeaderName: string;
|
|
53
|
-
width?: string;
|
|
54
|
-
maxWidth?: string;
|
|
55
|
-
minWidth?: string;
|
|
56
|
-
pinned?: (typeof PinnableValues)[keyof typeof PinnableValues];
|
|
57
|
-
renderHeaderCell?: (column: ITableColDef<T>) => React.ReactNode;
|
|
58
|
-
renderCell?: (value: unknown, row: T, column: ITableColDef<T>, rowIndex: number) => React.ReactNode;
|
|
59
|
-
valueFormatter?: (value: unknown, row: T, column: ITableColDef<T>, rowIndex: number) => React.ReactNode;
|
|
60
|
-
enableFilter?: boolean;
|
|
61
|
-
enableColumnCheckbox?: boolean;
|
|
62
|
-
isCheckBoxMarked?: boolean;
|
|
63
|
-
onColumnCheckboxClick?: (isMarked: boolean) => void;
|
|
64
|
-
filterValues?: ITableDropdown[];
|
|
65
|
-
onFilterCheck?: (value: string) => void;
|
|
66
|
-
filterClassName?: string;
|
|
67
|
-
filterButtonClassName?: string;
|
|
68
|
-
showApplyFilter?: boolean;
|
|
69
|
-
onApplyFilter?: (field: string) => void;
|
|
70
|
-
resetFilterData?: (field: string) => void;
|
|
71
|
-
showSearch?: boolean;
|
|
72
|
-
searchQuery?: string;
|
|
73
|
-
setSearchQuery?: (value: string) => void;
|
|
74
|
-
dropdownCloseEventOnClickOutside?: () => void;
|
|
75
|
-
}
|
|
76
|
-
export interface ITableCellProps<T> {
|
|
77
|
-
children: React.ReactNode;
|
|
78
|
-
isHeaderCell?: boolean;
|
|
79
|
-
column: ITableColDef<T>;
|
|
80
|
-
colIndex: number;
|
|
81
|
-
rowIndex?: number;
|
|
82
|
-
}
|
|
83
|
-
export interface ITableRowProps {
|
|
84
|
-
children: React.ReactNode;
|
|
85
|
-
isHeaderRow: boolean;
|
|
86
|
-
classes?: string;
|
|
87
|
-
}
|
|
88
|
-
export interface ITableHeadProps<T> {
|
|
89
|
-
columns: ITableColDef<T>[];
|
|
90
|
-
}
|
|
91
|
-
export interface ITableDropdown {
|
|
92
|
-
key?: string;
|
|
93
|
-
name: string;
|
|
94
|
-
isSelected: boolean;
|
|
95
|
-
isDisabled?: boolean;
|
|
96
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
interface EmptyTableProps {
|
|
2
|
-
title: string;
|
|
3
|
-
description: string;
|
|
4
|
-
onPageRefresh: () => void;
|
|
5
|
-
buttonClassName: string;
|
|
6
|
-
titleClassName: string;
|
|
7
|
-
descriptionClassName: string;
|
|
8
|
-
containerClassName: string;
|
|
9
|
-
imageClassName: string;
|
|
10
|
-
}
|
|
11
|
-
declare function EmptyTableContainer(props: EmptyTableProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
-
export default EmptyTableContainer;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
interface FilterCheckboxProps {
|
|
2
|
-
label: string;
|
|
3
|
-
onCheck: (value: string) => void;
|
|
4
|
-
isSelected: boolean;
|
|
5
|
-
isDisabled: boolean;
|
|
6
|
-
}
|
|
7
|
-
declare function FilterCheckbox(props: FilterCheckboxProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
-
export default FilterCheckbox;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { ITableDropdown } from '../ReusableTableTypes';
|
|
2
|
-
interface FilterDropdownProps {
|
|
3
|
-
options: ITableDropdown[];
|
|
4
|
-
onCheck: (name: string) => void;
|
|
5
|
-
showSearch: boolean;
|
|
6
|
-
searchQuery?: string;
|
|
7
|
-
setSearchQuery?: (query: string) => void;
|
|
8
|
-
filterclassname: string;
|
|
9
|
-
filterButtonStyles?: string;
|
|
10
|
-
showApplyFilter: boolean;
|
|
11
|
-
onApplyFilter?: (field: string) => void;
|
|
12
|
-
field: string;
|
|
13
|
-
resetDropDownData?: (field: string) => void;
|
|
14
|
-
dropdownCloseEventOnClickOutside?: () => void;
|
|
15
|
-
}
|
|
16
|
-
declare const FilterDropdown: <T>(props: FilterDropdownProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
|
-
export default FilterDropdown;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { ITableDropdown } from '../ReusableTableTypes';
|
|
2
|
-
export interface I_TableFilterProps {
|
|
3
|
-
options: ITableDropdown[];
|
|
4
|
-
filterclassname: string;
|
|
5
|
-
filterButtonStyles: string;
|
|
6
|
-
clearFilterButtonStyles: string;
|
|
7
|
-
showApplyFilter: boolean;
|
|
8
|
-
onApplyFilter: (filterOptions: ITableDropdown[]) => void;
|
|
9
|
-
onClearFilter: () => void;
|
|
10
|
-
}
|
|
11
|
-
declare const TableFilterSelect: (props: I_TableFilterProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
-
export default TableFilterSelect;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { default as React } from 'react';
|
|
2
|
-
import { ITableColDef, ResuableTableNoDataProps, IPaginationProps } from '../ReusableTableTypes';
|
|
3
|
-
export declare const TableProvider: <T>({ children, initialColumns, rowData, headerRowClasses, rowClassesForSpecificIndex, tableBodyClassesToOverride, hideHeader, paginationProps, onPaginationClick, displayPaginationClassesToOverride, displayNoDataFoundProps, enableTableFilter, tableBodyParentDivRef, tableMainDivClasses, }: {
|
|
4
|
-
children: React.ReactNode;
|
|
5
|
-
initialColumns: Array<ITableColDef<T>>;
|
|
6
|
-
rowData: Array<T>;
|
|
7
|
-
headerRowClasses: string;
|
|
8
|
-
rowClassesForSpecificIndex: {
|
|
9
|
-
index: number;
|
|
10
|
-
rowClasses: string;
|
|
11
|
-
};
|
|
12
|
-
tableBodyClassesToOverride: string;
|
|
13
|
-
hideHeader: boolean;
|
|
14
|
-
paginationProps: IPaginationProps;
|
|
15
|
-
onPaginationClick: ((activePage: number) => void) | undefined;
|
|
16
|
-
displayPaginationClassesToOverride: string;
|
|
17
|
-
displayNoDataFoundProps: ResuableTableNoDataProps | undefined;
|
|
18
|
-
enableTableFilter: boolean;
|
|
19
|
-
tableBodyParentDivRef?: React.RefObject<HTMLDivElement>;
|
|
20
|
-
tableMainDivClasses?: string;
|
|
21
|
-
}) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { default as React, SetStateAction } from 'react';
|
|
2
|
-
import { IPaginationProps, ITableColDef, ResuableTableNoDataProps } from '../ReusableTableTypes';
|
|
3
|
-
export interface TableContextProps<T> {
|
|
4
|
-
rowsData: Array<T>;
|
|
5
|
-
allColumns: ITableColDef<T>[];
|
|
6
|
-
headerRowClasses: string;
|
|
7
|
-
rowClassesForSpecificIndex: {
|
|
8
|
-
index: number;
|
|
9
|
-
rowClasses: string;
|
|
10
|
-
};
|
|
11
|
-
tableBodyClassesToOverride: string;
|
|
12
|
-
hideHeader: boolean;
|
|
13
|
-
leftPinnedColumns: ITableColDef<T>[];
|
|
14
|
-
rightPinnedColumns: ITableColDef<T>[];
|
|
15
|
-
nonPinnedColumns: ITableColDef<T>[];
|
|
16
|
-
paginationProps: IPaginationProps;
|
|
17
|
-
onPaginationClick: ((activePage: number) => void) | undefined;
|
|
18
|
-
showDropdown: string | null;
|
|
19
|
-
setShowDropdown: React.Dispatch<SetStateAction<string | null>>;
|
|
20
|
-
displayPaginationClassesToOverride: string;
|
|
21
|
-
displayNoDataFoundProps: ResuableTableNoDataProps | undefined;
|
|
22
|
-
enableTableFilter: boolean;
|
|
23
|
-
tableBodyParentDivRef?: React.RefObject<HTMLDivElement>;
|
|
24
|
-
tableMainDivClasses?: string;
|
|
25
|
-
}
|
|
26
|
-
export declare const TableContext: React.Context<TableContextProps<any> | undefined>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { j as e, K as f } from "../index-Cl3h7bnz.js";
|
|
2
|
-
function n(r) {
|
|
3
|
-
const { options: h, selectedOption: a, onChangeHandler: s } = r;
|
|
4
|
-
return /* @__PURE__ */ e.jsx("div", { className: "hfl-flex hfl-gap-2 hfl-h-full hfl-items-center hfl-px-4 hfl-justify-center hfl-py-1", children: h?.map((l) => /* @__PURE__ */ e.jsx("div", { className: "hfl-bg-White hfl-rounded-lg", children: /* @__PURE__ */ e.jsx(
|
|
5
|
-
f,
|
|
6
|
-
{
|
|
7
|
-
onClick: () => s && s(l),
|
|
8
|
-
hierarchy: a?.label === l.label ? "Primary" : "Secondary-Grey",
|
|
9
|
-
size: "sm",
|
|
10
|
-
textField: l.label,
|
|
11
|
-
className: a?.label === l.label ? "hfl-bg-Blue-600" : ""
|
|
12
|
-
}
|
|
13
|
-
) }, l.label)) });
|
|
14
|
-
}
|
|
15
|
-
export {
|
|
16
|
-
n as default
|
|
17
|
-
};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { TrendGraphData } from '../types/TrendGraphTypes';
|
|
2
|
-
interface AreaChartProps {
|
|
3
|
-
trendData: TrendGraphData;
|
|
4
|
-
containerWidth: number;
|
|
5
|
-
containerHeight: number;
|
|
6
|
-
showError?: (message: string) => void;
|
|
7
|
-
}
|
|
8
|
-
declare function AreaChartComponent(props: AreaChartProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
export default AreaChartComponent;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
interface PayloadItem {
|
|
2
|
-
value: number;
|
|
3
|
-
payload: {
|
|
4
|
-
date: string;
|
|
5
|
-
value: number;
|
|
6
|
-
};
|
|
7
|
-
dataKey: string;
|
|
8
|
-
name: string;
|
|
9
|
-
}
|
|
10
|
-
interface DataPointTooltipProps {
|
|
11
|
-
active?: boolean;
|
|
12
|
-
payload?: PayloadItem[];
|
|
13
|
-
label?: string | number;
|
|
14
|
-
}
|
|
15
|
-
declare const DataPointTooltip: React.FC<DataPointTooltipProps>;
|
|
16
|
-
export default DataPointTooltip;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { I_AllInvestigations } from '../../types/AllInvestigationTypes';
|
|
2
|
-
import { TrendGraphData, TrendGraphDataPoint } from '../../types/TrendGraphTypes';
|
|
3
|
-
export declare function isValidTrendGraphData(data: TrendGraphData): boolean;
|
|
4
|
-
export declare const convertRowToTrendGraphData: (row: I_AllInvestigations) => TrendGraphDataPoint[];
|
package/dist/clsx-C11secjj.cjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";function i(r){var f,n,t="";if(typeof r=="string"||typeof r=="number")t+=r;else if(typeof r=="object")if(Array.isArray(r)){var s=r.length;for(f=0;f<s;f++)r[f]&&(n=i(r[f]))&&(t&&(t+=" "),t+=n)}else for(n in r)r[n]&&(t&&(t+=" "),t+=n);return t}function o(){for(var r,f,n=0,t="",s=arguments.length;n<s;n++)(r=arguments[n])&&(f=i(r))&&(t&&(t+=" "),t+=f);return t}exports.clsx=o;
|
package/dist/clsx-OuTLNxxd.js
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
function a(r) {
|
|
2
|
-
var f, n, t = "";
|
|
3
|
-
if (typeof r == "string" || typeof r == "number") t += r;
|
|
4
|
-
else if (typeof r == "object") if (Array.isArray(r)) {
|
|
5
|
-
var o = r.length;
|
|
6
|
-
for (f = 0; f < o; f++) r[f] && (n = a(r[f])) && (t && (t += " "), t += n);
|
|
7
|
-
} else for (n in r) r[n] && (t && (t += " "), t += n);
|
|
8
|
-
return t;
|
|
9
|
-
}
|
|
10
|
-
function i() {
|
|
11
|
-
for (var r, f, n = 0, t = "", o = arguments.length; n < o; n++) (r = arguments[n]) && (f = a(r)) && (t && (t += " "), t += f);
|
|
12
|
-
return t;
|
|
13
|
-
}
|
|
14
|
-
export {
|
|
15
|
-
i as c
|
|
16
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as AlertPopup } from './AlertPopup';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as CustomDropdown } from './CustomDropdown';
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { RefObject } from 'react';
|
|
2
|
-
interface DateAndTimePickerProps {
|
|
3
|
-
inputDate: Date;
|
|
4
|
-
triggerType?: 'button' | 'input';
|
|
5
|
-
placeholderCTA?: string;
|
|
6
|
-
placeholderCTAStyles?: string;
|
|
7
|
-
inputPlaceholder?: string;
|
|
8
|
-
inputFieldClassName?: string;
|
|
9
|
-
displayDateFormat?: string;
|
|
10
|
-
minDate?: Date | null;
|
|
11
|
-
maxDate?: Date | null;
|
|
12
|
-
applyChanges: (selectedDate: Date) => void;
|
|
13
|
-
datePickerAbsoluteClasses: string;
|
|
14
|
-
highlightClickedCell?: boolean;
|
|
15
|
-
sectionRef?: RefObject<HTMLDivElement>;
|
|
16
|
-
inputIcon?: string;
|
|
17
|
-
inputIconClasses?: string;
|
|
18
|
-
datePickerMainDivClasses?: string;
|
|
19
|
-
}
|
|
20
|
-
declare const DateAndTimePicker: ({ inputDate, placeholderCTA, placeholderCTAStyles, minDate, maxDate, applyChanges, datePickerAbsoluteClasses, triggerType, inputPlaceholder, inputFieldClassName, displayDateFormat, sectionRef, highlightClickedCell, inputIcon, inputIconClasses, datePickerMainDivClasses, }: DateAndTimePickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
|
-
export default DateAndTimePicker;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default as DateAndTimePicker } from './DateAndTimePicker';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from './ToggleButtons';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const G=require("./index-BVfQUI8j.cjs");var W={exports:{}},K=W.exports,E;function X(){return E||(E=1,function(V,nt){(function(A,x){V.exports=x()})(K,function(){var A=1e3,x=6e4,U=36e5,I="millisecond",S="second",w="minute",_="hour",y="day",H="week",m="month",q="quarter",M="year",O="date",J="Invalid Date",B=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,P=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,Q={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(s){var n=["th","st","nd","rd"],t=s%100;return"["+s+(n[(t-20)%10]||n[t]||n[0])+"]"}},F=function(s,n,t){var r=String(s);return!r||r.length>=n?s:""+Array(n+1-r.length).join(t)+s},R={s:F,z:function(s){var n=-s.utcOffset(),t=Math.abs(n),r=Math.floor(t/60),e=t%60;return(n<=0?"+":"-")+F(r,2,"0")+":"+F(e,2,"0")},m:function s(n,t){if(n.date()<t.date())return-s(t,n);var r=12*(t.year()-n.year())+(t.month()-n.month()),e=n.clone().add(r,m),i=t-e<0,u=n.clone().add(r+(i?-1:1),m);return+(-(r+(t-e)/(i?e-u:u-e))||0)},a:function(s){return s<0?Math.ceil(s)||0:Math.floor(s)},p:function(s){return{M:m,y:M,w:H,d:y,D:O,h:_,m:w,s:S,ms:I,Q:q}[s]||String(s||"").toLowerCase().replace(/s$/,"")},u:function(s){return s===void 0}},k="en",D={};D[k]=Q;var Z="$isDayjsObject",N=function(s){return s instanceof C||!(!s||!s[Z])},T=function s(n,t,r){var e;if(!n)return k;if(typeof n=="string"){var i=n.toLowerCase();D[i]&&(e=i),t&&(D[i]=t,e=i);var u=n.split("-");if(!e&&u.length>1)return s(u[0])}else{var o=n.name;D[o]=n,e=o}return!r&&e&&(k=e),e||!r&&k},f=function(s,n){if(N(s))return s.clone();var t=typeof n=="object"?n:{};return t.date=s,t.args=arguments,new C(t)},a=R;a.l=T,a.i=N,a.w=function(s,n){return f(s,{locale:n.$L,utc:n.$u,x:n.$x,$offset:n.$offset})};var C=function(){function s(t){this.$L=T(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[Z]=!0}var n=s.prototype;return n.parse=function(t){this.$d=function(r){var e=r.date,i=r.utc;if(e===null)return new Date(NaN);if(a.u(e))return new Date;if(e instanceof Date)return new Date(e);if(typeof e=="string"&&!/Z$/i.test(e)){var u=e.match(B);if(u){var o=u[2]-1||0,c=(u[7]||"0").substring(0,3);return i?new Date(Date.UTC(u[1],o,u[3]||1,u[4]||0,u[5]||0,u[6]||0,c)):new Date(u[1],o,u[3]||1,u[4]||0,u[5]||0,u[6]||0,c)}}return new Date(e)}(t),this.init()},n.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},n.$utils=function(){return a},n.isValid=function(){return this.$d.toString()!==J},n.isSame=function(t,r){var e=f(t);return this.startOf(r)<=e&&e<=this.endOf(r)},n.isAfter=function(t,r){return f(t)<this.startOf(r)},n.isBefore=function(t,r){return this.endOf(r)<f(t)},n.$g=function(t,r,e){return a.u(t)?this[r]:this.set(e,t)},n.unix=function(){return Math.floor(this.valueOf()/1e3)},n.valueOf=function(){return this.$d.getTime()},n.startOf=function(t,r){var e=this,i=!!a.u(r)||r,u=a.p(t),o=function(p,$){var v=a.w(e.$u?Date.UTC(e.$y,$,p):new Date(e.$y,$,p),e);return i?v:v.endOf(y)},c=function(p,$){return a.w(e.toDate()[p].apply(e.toDate("s"),(i?[0,0,0,0]:[23,59,59,999]).slice($)),e)},h=this.$W,d=this.$M,l=this.$D,b="set"+(this.$u?"UTC":"");switch(u){case M:return i?o(1,0):o(31,11);case m:return i?o(1,d):o(0,d+1);case H:var g=this.$locale().weekStart||0,j=(h<g?h+7:h)-g;return o(i?l-j:l+(6-j),d);case y:case O:return c(b+"Hours",0);case _:return c(b+"Minutes",1);case w:return c(b+"Seconds",2);case S:return c(b+"Milliseconds",3);default:return this.clone()}},n.endOf=function(t){return this.startOf(t,!1)},n.$set=function(t,r){var e,i=a.p(t),u="set"+(this.$u?"UTC":""),o=(e={},e[y]=u+"Date",e[O]=u+"Date",e[m]=u+"Month",e[M]=u+"FullYear",e[_]=u+"Hours",e[w]=u+"Minutes",e[S]=u+"Seconds",e[I]=u+"Milliseconds",e)[i],c=i===y?this.$D+(r-this.$W):r;if(i===m||i===M){var h=this.clone().set(O,1);h.$d[o](c),h.init(),this.$d=h.set(O,Math.min(this.$D,h.daysInMonth())).$d}else o&&this.$d[o](c);return this.init(),this},n.set=function(t,r){return this.clone().$set(t,r)},n.get=function(t){return this[a.p(t)]()},n.add=function(t,r){var e,i=this;t=Number(t);var u=a.p(r),o=function(d){var l=f(i);return a.w(l.date(l.date()+Math.round(d*t)),i)};if(u===m)return this.set(m,this.$M+t);if(u===M)return this.set(M,this.$y+t);if(u===y)return o(1);if(u===H)return o(7);var c=(e={},e[w]=x,e[_]=U,e[S]=A,e)[u]||1,h=this.$d.getTime()+t*c;return a.w(h,this)},n.subtract=function(t,r){return this.add(-1*t,r)},n.format=function(t){var r=this,e=this.$locale();if(!this.isValid())return e.invalidDate||J;var i=t||"YYYY-MM-DDTHH:mm:ssZ",u=a.z(this),o=this.$H,c=this.$m,h=this.$M,d=e.weekdays,l=e.months,b=e.meridiem,g=function($,v,Y,L){return $&&($[v]||$(r,i))||Y[v].slice(0,L)},j=function($){return a.s(o%12||12,$,"0")},p=b||function($,v,Y){var L=$<12?"AM":"PM";return Y?L.toLowerCase():L};return i.replace(P,function($,v){return v||function(Y){switch(Y){case"YY":return String(r.$y).slice(-2);case"YYYY":return a.s(r.$y,4,"0");case"M":return h+1;case"MM":return a.s(h+1,2,"0");case"MMM":return g(e.monthsShort,h,l,3);case"MMMM":return g(l,h);case"D":return r.$D;case"DD":return a.s(r.$D,2,"0");case"d":return String(r.$W);case"dd":return g(e.weekdaysMin,r.$W,d,2);case"ddd":return g(e.weekdaysShort,r.$W,d,3);case"dddd":return d[r.$W];case"H":return String(o);case"HH":return a.s(o,2,"0");case"h":return j(1);case"hh":return j(2);case"a":return p(o,c,!0);case"A":return p(o,c,!1);case"m":return String(c);case"mm":return a.s(c,2,"0");case"s":return String(r.$s);case"ss":return a.s(r.$s,2,"0");case"SSS":return a.s(r.$ms,3,"0");case"Z":return u}return null}($)||u.replace(":","")})},n.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},n.diff=function(t,r,e){var i,u=this,o=a.p(r),c=f(t),h=(c.utcOffset()-this.utcOffset())*x,d=this-c,l=function(){return a.m(u,c)};switch(o){case M:i=l()/12;break;case m:i=l();break;case q:i=l()/3;break;case H:i=(d-h)/6048e5;break;case y:i=(d-h)/864e5;break;case _:i=d/U;break;case w:i=d/x;break;case S:i=d/A;break;default:i=d}return e?i:a.a(i)},n.daysInMonth=function(){return this.endOf(m).$D},n.$locale=function(){return D[this.$L]},n.locale=function(t,r){if(!t)return this.$L;var e=this.clone(),i=T(t,r,!0);return i&&(e.$L=i),e},n.clone=function(){return a.w(this.$d,this)},n.toDate=function(){return new Date(this.valueOf())},n.toJSON=function(){return this.isValid()?this.toISOString():null},n.toISOString=function(){return this.$d.toISOString()},n.toString=function(){return this.$d.toUTCString()},s}(),z=C.prototype;return f.prototype=z,[["$ms",I],["$s",S],["$m",w],["$H",_],["$W",y],["$M",m],["$y",M],["$D",O]].forEach(function(s){z[s[1]]=function(n){return this.$g(n,s[0],s[1])}}),f.extend=function(s,n){return s.$i||(s(n,C,f),s.$i=!0),f},f.locale=T,f.isDayjs=N,f.unix=function(s){return f(1e3*s)},f.en=D[k],f.Ls=D,f.p={},f})}(W)),W.exports}var tt=X();const et=G.getDefaultExportFromCjs(tt);exports.dayjs=et;
|