@hmcts/ccpay-web-component 6.2.16 → 6.2.17-beta
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/esm2022/lib/components/payment-view/payment-view.component.mjs +2 -2
- package/esm2022/lib/components/service-request/service-request.component.mjs +2 -2
- package/esm2022/lib/payment-lib.component.mjs +22 -1
- package/fesm2022/hmcts-ccpay-web-component.mjs +23 -2
- package/fesm2022/hmcts-ccpay-web-component.mjs.map +1 -1
- package/lib/payment-lib.component.d.ts +17 -0
- package/package.json +1 -1
|
@@ -133,6 +133,23 @@ export declare class PaymentLibComponent implements OnInit {
|
|
|
133
133
|
* @param feeCode this is the fee code used to find out all refunds rejected refunds.
|
|
134
134
|
*/
|
|
135
135
|
isTheCurrentRefundRejectedForTheFee(feeCode: string): boolean;
|
|
136
|
+
/**
|
|
137
|
+
* Rounds very small values to zero if they fall below a specified threshold.
|
|
138
|
+
*
|
|
139
|
+
* This is useful for eliminating floating-point precision errors that result in
|
|
140
|
+
* extremely small non-zero values (e.g., 1.1368683772161603e-13) which should
|
|
141
|
+
* logically be treated as zero.
|
|
142
|
+
*
|
|
143
|
+
* @param value - The numeric value to evaluate and potentially round.
|
|
144
|
+
* @param threshold - The minimum absolute value considered significant. Defaults to 1e-10.
|
|
145
|
+
* @returns The original value if it's above the threshold, or 0 if it's below.
|
|
146
|
+
*
|
|
147
|
+
* @example
|
|
148
|
+
* roundTinyValue(1.1368683772161603e-13); // returns 0
|
|
149
|
+
* roundTinyValue(0.00001); // returns 0.00001
|
|
150
|
+
*/
|
|
151
|
+
roundTinyValue(value: number, threshold?: number): number;
|
|
152
|
+
getRoundedOverPayment(): number;
|
|
136
153
|
static ɵfac: i0.ɵɵFactoryDeclaration<PaymentLibComponent, never>;
|
|
137
154
|
static ɵcmp: i0.ɵɵComponentDeclaration<PaymentLibComponent, "ccpay-payment-lib", never, { "API_ROOT": { "alias": "API_ROOT"; "required": false; }; "BULKSCAN_API_ROOT": { "alias": "BULKSCAN_API_ROOT"; "required": false; }; "REFUNDS_API_ROOT": { "alias": "REFUNDS_API_ROOT"; "required": false; }; "NOTIFICATION_API_ROOT": { "alias": "NOTIFICATION_API_ROOT"; "required": false; }; "CARDPAYMENTRETURNURL": { "alias": "CARDPAYMENTRETURNURL"; "required": false; }; "CCD_CASE_NUMBER": { "alias": "CCD_CASE_NUMBER"; "required": false; }; "EXC_REFERENCE": { "alias": "EXC_REFERENCE"; "required": false; }; "PAYMENT_METHOD": { "alias": "PAYMENT_METHOD"; "required": false; }; "VIEW": { "alias": "VIEW"; "required": false; }; "VIEWSERVICE": { "alias": "VIEWSERVICE"; "required": false; }; "PAYMENT_GROUP_REF": { "alias": "PAYMENT_GROUP_REF"; "required": false; }; "TAKEPAYMENT": { "alias": "TAKEPAYMENT"; "required": false; }; "SERVICEREQUEST": { "alias": "SERVICEREQUEST"; "required": false; }; "DCN_NUMBER": { "alias": "DCN_NUMBER"; "required": false; }; "SELECTED_OPTION": { "alias": "SELECTED_OPTION"; "required": false; }; "ISBSENABLE": { "alias": "ISBSENABLE"; "required": false; }; "ISSFENABLE": { "alias": "ISSFENABLE"; "required": false; }; "ISTURNOFF": { "alias": "ISTURNOFF"; "required": false; }; "CASETYPE": { "alias": "CASETYPE"; "required": false; }; "ISPAYMENTSTATUSENABLED": { "alias": "ISPAYMENTSTATUSENABLED"; "required": false; }; "rootUrl": { "alias": "rootUrl"; "required": false; }; "REFUNDLIST": { "alias": "REFUNDLIST"; "required": false; }; "USERID": { "alias": "USERID"; "required": false; }; "LOGGEDINUSERROLES": { "alias": "LOGGEDINUSERROLES"; "required": false; }; "LOGGEDINUSEREMAIL": { "alias": "LOGGEDINUSEREMAIL"; "required": false; }; "isFromServiceRequestPage": { "alias": "isFromServiceRequestPage"; "required": false; }; }, {}, never, never, false, never>;
|
|
138
155
|
}
|