@thecb/components 4.0.15-beta.0 → 4.0.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.js CHANGED
@@ -37970,7 +37970,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
37970
37970
  fields = _ref.fields,
37971
37971
  actions = _ref.actions,
37972
37972
  showErrors = _ref.showErrors,
37973
- fees = _ref.fees,
37974
37973
  _ref$handleSubmit = _ref.handleSubmit,
37975
37974
  handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit;
37976
37975
 
@@ -38105,13 +38104,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
38105
38104
  onChange: toggleCheckbox,
38106
38105
  checked: defaultMethod.value,
38107
38106
  hidden: hideDefaultPayment
38108
- }), !!(fees === null || fees === void 0 ? void 0 : fees.value) && /*#__PURE__*/React__default.createElement(Alert$1, {
38109
- heading: "Processing Fee",
38110
- text: "There is a processing fee of ".concat(fees.type === "FLAT" ? "".concat(displayCurrency(fees.value)) : "".concat(fees.value * 100, "%"), " ").concat(ifElse(isNil, always(""), function (a) {
38111
- return "with a minimum of ".concat(displayCurrency(a), " ");
38112
- })(fees.minimumInCents), "on all bank account payments."),
38113
- variant: "info",
38114
- showQuitLink: false
38115
38107
  })));
38116
38108
  };
38117
38109
 
@@ -38168,7 +38160,6 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
38168
38160
  fields = _ref.fields,
38169
38161
  actions = _ref.actions,
38170
38162
  showErrors = _ref.showErrors,
38171
- fees = _ref.fees,
38172
38163
  _ref$handleSubmit = _ref.handleSubmit,
38173
38164
  handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit,
38174
38165
  isMobile = _ref.isMobile;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thecb/components",
3
- "version": "4.0.15-beta.0",
3
+ "version": "4.0.17",
4
4
  "description": "Common lib for CityBase react components",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",
@@ -1,6 +1,5 @@
1
1
  import React, { useEffect, useState } from "react";
2
2
  import styled from "styled-components";
3
- import { ifElse, isNil, always } from "ramda";
4
3
  import Checkbox from "../../atoms/checkbox";
5
4
  import {
6
5
  required,
@@ -14,9 +13,8 @@ import {
14
13
  FormInputColumn,
15
14
  FormContainer
16
15
  } from "../../atoms/form-layouts";
17
- import Alert from "../../atoms/alert";
18
16
  import AccountAndRoutingModal from "../account-and-routing-modal";
19
- import { displayCurrency, noop } from "../../../util/general";
17
+ import { noop } from "../../../util/general";
20
18
 
21
19
  const ModalWrapper = styled.div``;
22
20
 
@@ -30,7 +28,6 @@ const PaymentFormACH = ({
30
28
  fields,
31
29
  actions,
32
30
  showErrors,
33
- fees,
34
31
  handleSubmit = noop
35
32
  }) => {
36
33
  if (clearOnDismount) {
@@ -165,22 +162,6 @@ const PaymentFormACH = ({
165
162
  hidden={hideDefaultPayment}
166
163
  />
167
164
  )}
168
- {!!fees?.value && (
169
- <Alert
170
- heading="Processing Fee"
171
- text={`There is a processing fee of ${
172
- fees.type === "FLAT"
173
- ? `${displayCurrency(fees.value)}`
174
- : `${fees.value * 100}%`
175
- } ${ifElse(
176
- isNil,
177
- always(""),
178
- a => `with a minimum of ${displayCurrency(a)} `
179
- )(fees.minimumInCents)}on all bank account payments.`}
180
- variant="info"
181
- showQuitLink={false}
182
- />
183
- )}
184
165
  </FormInputColumn>
185
166
  </FormContainer>
186
167
  );
@@ -1,7 +1,6 @@
1
1
  import React, { useEffect } from "react";
2
2
  import { required, hasLength, matchesRegex } from "redux-freeform";
3
- import { ifElse, isNil, always } from "ramda";
4
- import { checkCardBrand, displayCurrency, noop } from "../../../util/general";
3
+ import { checkCardBrand, noop } from "../../../util/general";
5
4
  import { expirationDateFormat, creditCardFormat } from "../../../util/formats";
6
5
  import {
7
6
  FormInput,
@@ -10,7 +9,6 @@ import {
10
9
  FormInputRow
11
10
  } from "../../atoms/form-layouts";
12
11
  import { Box } from "../../atoms/layouts";
13
- import Alert from "../../atoms/alert";
14
12
 
15
13
  const nameOnCardErrors = {
16
14
  [required.error]: "Name is required"
@@ -40,7 +38,6 @@ const PaymentFormCard = ({
40
38
  fields,
41
39
  actions,
42
40
  showErrors,
43
- fees,
44
41
  handleSubmit = noop,
45
42
  isMobile
46
43
  }) => {