@maxio-com/self-service 1.4.3 → 1.5.0
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/maxio-components.cjs.js +1 -1
- package/dist/maxio-components.esm.js +1 -1
- package/dist/maxio-components.umd.js +65 -10
- package/package.json +1 -1
- package/typings/packages/custom-ui-components/src/components/molecules/Alert/Alert.d.ts +5 -2
- package/typings/packages/custom-ui-components/src/components/molecules/Alert/Alert.styles.d.ts +0 -1
- package/typings/packages/custom-ui-components/src/components/molecules/Alert/components/Title.d.ts +8 -0
- package/typings/packages/custom-ui-components/src/components/molecules/Alert/components/Title.styles.d.ts +2 -0
- package/typings/packages/custom-ui-components/src/components/molecules/Alert/components/index.d.ts +2 -1
- package/typings/packages/icons/src/Icon.styles.d.ts +1 -1
- package/typings/packages/subscriptions-manager/src/components/PlanChangeAlerts/PlanChangeAlerts.d.ts +2 -1
- package/typings/packages/subscriptions-manager/src/components/PlanChangeSummary/PlanChangeSummary.d.ts +5 -2
- package/typings/packages/subscriptions-manager/src/components/PlanChangeSummary/components/NonProratedColumns.d.ts +10 -0
- package/typings/packages/subscriptions-manager/src/components/PlanChangeSummary/components/ProratedColumns.d.ts +8 -0
- package/typings/packages/subscriptions-manager/src/components/PlanChangeSummary/components/index.d.ts +2 -0
- package/typings/packages/subscriptions-manager/src/containers/PreviewProductMigrationContainer/PreviewProductMigrationContainer.d.ts +2 -1
|
@@ -3591,7 +3591,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
3591
3591
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
3592
3592
|
|
|
3593
3593
|
"use strict";
|
|
3594
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"Container\": () => (/* binding */ Container)
|
|
3594
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"Container\": () => (/* binding */ Container)\n/* harmony export */ });\n/* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! styled-components */ \"./node_modules/.pnpm/styled-components@5.3.5_7i5myeigehqah43i5u7wbekgba/node_modules/styled-components/dist/styled-components.browser.esm.js\");\n/* harmony import */ var styled_system__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! styled-system */ \"./node_modules/.pnpm/styled-system@5.1.5/node_modules/styled-system/dist/index.esm.js\");\n/* harmony import */ var _theme__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../theme */ \"./packages/custom-ui-components/src/theme/index.ts\");\n\n\n\nvar Container = styled_components__WEBPACK_IMPORTED_MODULE_2__[\"default\"].div.withConfig({\n displayName: \"Alertstyles__Container\",\n componentId: \"maxio-components__sc-gxtxj5-0\"\n})([\"&&&{box-sizing:border-box;\", \";\", \";\", \";}\"], function (props) {\n return (0,styled_system__WEBPACK_IMPORTED_MODULE_0__.variant)(_theme__WEBPACK_IMPORTED_MODULE_1__.ThemeUtilities.getComponentVariant(props, 'Alert', 'size'));\n}, function (props) {\n return (0,styled_system__WEBPACK_IMPORTED_MODULE_0__.variant)(_theme__WEBPACK_IMPORTED_MODULE_1__.ThemeUtilities.getComponentVariant(props, 'Alert', 'color'));\n}, (0,styled_components__WEBPACK_IMPORTED_MODULE_2__.css)(function (props) {\n return _theme__WEBPACK_IMPORTED_MODULE_1__.ThemeUtilities.getComponentCSSOverrides(props, 'Alert');\n}));\n\n//# sourceURL=webpack://Maxio/./packages/custom-ui-components/src/components/molecules/Alert/Alert.styles.ts?");
|
|
3595
3595
|
|
|
3596
3596
|
/***/ }),
|
|
3597
3597
|
|
|
@@ -3602,7 +3602,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
3602
3602
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
3603
3603
|
|
|
3604
3604
|
"use strict";
|
|
3605
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var
|
|
3605
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _atoms__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../atoms */ \"./packages/custom-ui-components/src/components/atoms/index.ts\");\n/* harmony import */ var _Alert_styles__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Alert.styles */ \"./packages/custom-ui-components/src/components/molecules/Alert/Alert.styles.ts\");\n/* harmony import */ var _components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./components */ \"./packages/custom-ui-components/src/components/molecules/Alert/components/index.ts\");\n\n\n\n\n\nvar Alert = function Alert(_ref) {\n var title = _ref.title,\n _ref$color = _ref.color,\n color = _ref$color === void 0 ? 'primary' : _ref$color,\n _ref$size = _ref.size,\n size = _ref$size === void 0 ? 'regular' : _ref$size,\n buttonLabel = _ref.buttonLabel,\n icon = _ref.icon,\n onClick = _ref.onClick,\n children = _ref.children;\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Alert_styles__WEBPACK_IMPORTED_MODULE_2__.Container, {\n size: size,\n color: color,\n role: \"alert\"\n }, title && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components__WEBPACK_IMPORTED_MODULE_3__.Title, {\n text: title,\n icon: icon\n }), children, buttonLabel && onClick && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_atoms__WEBPACK_IMPORTED_MODULE_1__.Box, {\n marginTop: 4\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_atoms__WEBPACK_IMPORTED_MODULE_1__.Button, {\n label: buttonLabel,\n onClick: onClick,\n color: \"secondary\"\n })));\n};\n\nAlert.TextMessage = _components__WEBPACK_IMPORTED_MODULE_3__.TextMessage;\nAlert.Title = _components__WEBPACK_IMPORTED_MODULE_3__.Title;\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Alert);\n\n//# sourceURL=webpack://Maxio/./packages/custom-ui-components/src/components/molecules/Alert/Alert.tsx?");
|
|
3606
3606
|
|
|
3607
3607
|
/***/ }),
|
|
3608
3608
|
|
|
@@ -3617,6 +3617,28 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
3617
3617
|
|
|
3618
3618
|
/***/ }),
|
|
3619
3619
|
|
|
3620
|
+
/***/ "./packages/custom-ui-components/src/components/molecules/Alert/components/Title.styles.ts":
|
|
3621
|
+
/*!*************************************************************************************************!*\
|
|
3622
|
+
!*** ./packages/custom-ui-components/src/components/molecules/Alert/components/Title.styles.ts ***!
|
|
3623
|
+
\*************************************************************************************************/
|
|
3624
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
3625
|
+
|
|
3626
|
+
"use strict";
|
|
3627
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"TitleWrapper\": () => (/* binding */ TitleWrapper)\n/* harmony export */ });\n/* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! styled-components */ \"./node_modules/.pnpm/styled-components@5.3.5_7i5myeigehqah43i5u7wbekgba/node_modules/styled-components/dist/styled-components.browser.esm.js\");\n/* harmony import */ var styled_system__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! styled-system */ \"./node_modules/.pnpm/styled-system@5.1.5/node_modules/styled-system/dist/index.esm.js\");\n\n\nvar TitleWrapper = styled_components__WEBPACK_IMPORTED_MODULE_1__[\"default\"].div.withConfig({\n displayName: \"Titlestyles__TitleWrapper\",\n componentId: \"maxio-components__sc-1t0vg3w-0\"\n})([\"&&&{display:flex;align-items:center;\", \";}\"], styled_system__WEBPACK_IMPORTED_MODULE_0__.grid);\n\n//# sourceURL=webpack://Maxio/./packages/custom-ui-components/src/components/molecules/Alert/components/Title.styles.ts?");
|
|
3628
|
+
|
|
3629
|
+
/***/ }),
|
|
3630
|
+
|
|
3631
|
+
/***/ "./packages/custom-ui-components/src/components/molecules/Alert/components/Title.tsx":
|
|
3632
|
+
/*!*******************************************************************************************!*\
|
|
3633
|
+
!*** ./packages/custom-ui-components/src/components/molecules/Alert/components/Title.tsx ***!
|
|
3634
|
+
\*******************************************************************************************/
|
|
3635
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
3636
|
+
|
|
3637
|
+
"use strict";
|
|
3638
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"Title\": () => (/* binding */ Title)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _chargify_icons__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/icons */ \"./packages/icons/src/index.ts\");\n/* harmony import */ var _atoms__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../atoms */ \"./packages/custom-ui-components/src/components/atoms/index.ts\");\n/* harmony import */ var _Title_styles__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./Title.styles */ \"./packages/custom-ui-components/src/components/molecules/Alert/components/Title.styles.ts\");\n\n\n\n\nvar Title = function Title(_ref) {\n var text = _ref.text,\n icon = _ref.icon;\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_atoms__WEBPACK_IMPORTED_MODULE_2__.Box, {\n marginBottom: 2\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Title_styles__WEBPACK_IMPORTED_MODULE_3__.TitleWrapper, {\n gridGap: 2\n }, icon && /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_icons__WEBPACK_IMPORTED_MODULE_1__.Icon, {\n type: icon,\n fill: \"currentColor\",\n size: 16\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_atoms__WEBPACK_IMPORTED_MODULE_2__.BodyText, {\n variant: \"body2\",\n color: \"inherit\",\n fontWeight: 600\n }, text)));\n};\n\n//# sourceURL=webpack://Maxio/./packages/custom-ui-components/src/components/molecules/Alert/components/Title.tsx?");
|
|
3639
|
+
|
|
3640
|
+
/***/ }),
|
|
3641
|
+
|
|
3620
3642
|
/***/ "./packages/custom-ui-components/src/components/molecules/Alert/components/index.ts":
|
|
3621
3643
|
/*!******************************************************************************************!*\
|
|
3622
3644
|
!*** ./packages/custom-ui-components/src/components/molecules/Alert/components/index.ts ***!
|
|
@@ -3624,7 +3646,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
3624
3646
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
3625
3647
|
|
|
3626
3648
|
"use strict";
|
|
3627
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"TextMessage\": () => (/* reexport safe */ _TextMessage__WEBPACK_IMPORTED_MODULE_0__.TextMessage)\n/* harmony export */ });\n/* harmony import */ var _TextMessage__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./TextMessage */ \"./packages/custom-ui-components/src/components/molecules/Alert/components/TextMessage.tsx\");\n\n\n\n//# sourceURL=webpack://Maxio/./packages/custom-ui-components/src/components/molecules/Alert/components/index.ts?");
|
|
3649
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"TextMessage\": () => (/* reexport safe */ _TextMessage__WEBPACK_IMPORTED_MODULE_0__.TextMessage),\n/* harmony export */ \"Title\": () => (/* reexport safe */ _Title__WEBPACK_IMPORTED_MODULE_1__.Title)\n/* harmony export */ });\n/* harmony import */ var _TextMessage__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./TextMessage */ \"./packages/custom-ui-components/src/components/molecules/Alert/components/TextMessage.tsx\");\n/* harmony import */ var _Title__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Title */ \"./packages/custom-ui-components/src/components/molecules/Alert/components/Title.tsx\");\n\n\n\n\n//# sourceURL=webpack://Maxio/./packages/custom-ui-components/src/components/molecules/Alert/components/index.ts?");
|
|
3628
3650
|
|
|
3629
3651
|
/***/ }),
|
|
3630
3652
|
|
|
@@ -6594,7 +6616,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
6594
6616
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
6595
6617
|
|
|
6596
6618
|
"use strict";
|
|
6597
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"IconWrapper\": () => (/* binding */ IconWrapper)\n/* harmony export */ });\n/* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! styled-components */ \"./node_modules/.pnpm/styled-components@5.3.5_7i5myeigehqah43i5u7wbekgba/node_modules/styled-components/dist/styled-components.browser.esm.js\");\n/* harmony import */ var styled_system__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! styled-system */ \"./node_modules/.pnpm/styled-system@5.1.5/node_modules/styled-system/dist/index.esm.js\");\n\n\nvar IconWrapper = styled_components__WEBPACK_IMPORTED_MODULE_1__[\"default\"].
|
|
6619
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"IconWrapper\": () => (/* binding */ IconWrapper)\n/* harmony export */ });\n/* harmony import */ var styled_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! styled-components */ \"./node_modules/.pnpm/styled-components@5.3.5_7i5myeigehqah43i5u7wbekgba/node_modules/styled-components/dist/styled-components.browser.esm.js\");\n/* harmony import */ var styled_system__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! styled-system */ \"./node_modules/.pnpm/styled-system@5.1.5/node_modules/styled-system/dist/index.esm.js\");\n\n\nvar IconWrapper = styled_components__WEBPACK_IMPORTED_MODULE_1__[\"default\"].span.withConfig({\n displayName: \"Iconstyles__IconWrapper\",\n componentId: \"maxio-components__sc-r7ym3h-0\"\n})([\"&&&{display:inline-flex;line-height:0;\", \";}&&& .svg-inline--fa{width:\", \";height:\", \";}\"], styled_system__WEBPACK_IMPORTED_MODULE_0__.color, function (_ref) {\n var size = _ref.size;\n return size ? \"\".concat(size, \"px\") : '100%';\n}, function (_ref2) {\n var size = _ref2.size;\n return size ? \"\".concat(size, \"px\") : '100%';\n});\n\n//# sourceURL=webpack://Maxio/./packages/icons/src/Icon.styles.ts?");
|
|
6598
6620
|
|
|
6599
6621
|
/***/ }),
|
|
6600
6622
|
|
|
@@ -8002,7 +8024,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
8002
8024
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8003
8025
|
|
|
8004
8026
|
"use strict";
|
|
8005
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PlanChangeAlerts\": () => (/* binding */ PlanChangeAlerts)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\n\n\n\nvar PlanChangeAlerts = function PlanChangeAlerts(_ref) {\n var basePlanPrice = _ref.basePlanPrice,\n productChangeStrategy = _ref.productChangeStrategy,\n nextBillingDate = _ref.nextBillingDate,\n totalCharge = _ref.totalCharge;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_2__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n var commonAlertProps = {\n color: 'success',\n icon: 'receipt'\n };\n\n switch (productChangeStrategy) {\n case 'prorated':\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert, _objectSpread(
|
|
8027
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PlanChangeAlerts\": () => (/* binding */ PlanChangeAlerts)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }\n\nfunction _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }\n\n\n\n\nvar PlanChangeAlerts = function PlanChangeAlerts(_ref) {\n var basePlanPrice = _ref.basePlanPrice,\n productChangeStrategy = _ref.productChangeStrategy,\n nextBillingDate = _ref.nextBillingDate,\n totalCharge = _ref.totalCharge,\n creditBalance = _ref.creditBalance;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_2__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n var commonAlertProps = {\n color: 'success',\n icon: 'receipt'\n };\n\n switch (productChangeStrategy) {\n case 'prorated':\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert, _objectSpread({}, commonAlertProps), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert.Title, {\n text: t('plan_change.prorated_title', {\n totalCharge: totalCharge,\n credit: creditBalance\n }),\n icon: 'receipt'\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert.Title, {\n text: t('plan_change.plan_change_immediately'),\n icon: 'clock'\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert.Title, {\n text: t('plan_change.prorated_renewed_title', {\n date: nextBillingDate\n }),\n icon: 'calendar'\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'success.main'\n }, t('plan_change.prorated_description')));\n\n case 'non-prorated':\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert, _objectSpread({}, commonAlertProps), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert.Title, {\n text: t('plan_change.instant_title', {\n totalCharge: totalCharge\n }),\n icon: 'receipt'\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert.Title, {\n text: t('plan_change.plan_change_immediately'),\n icon: 'clock'\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'success.main'\n }, t('plan_change.instant_description')));\n\n case 'delayed':\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Alert, _objectSpread(_objectSpread({}, commonAlertProps), {}, {\n title: t('plan_change.delayed_title', {\n date: nextBillingDate,\n basePlanPrice: basePlanPrice\n })\n }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'success.main'\n }, t('plan_change.delayed_description')));\n }\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeAlerts/PlanChangeAlerts.tsx?");
|
|
8006
8028
|
|
|
8007
8029
|
/***/ }),
|
|
8008
8030
|
|
|
@@ -8024,7 +8046,40 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
8024
8046
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8025
8047
|
|
|
8026
8048
|
"use strict";
|
|
8027
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PlanChangeSummary\": () => (/* binding */ PlanChangeSummary)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var
|
|
8049
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PlanChangeSummary\": () => (/* binding */ PlanChangeSummary)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/Trans.js\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n/* harmony import */ var _components_index__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./components/index */ \"./packages/subscriptions-manager/src/components/PlanChangeSummary/components/index.ts\");\n\n\n\n\nvar PlanChangeSummary = function PlanChangeSummary(_ref) {\n var productName = _ref.productName,\n basePlanPrice = _ref.basePlanPrice,\n productChangeStrategy = _ref.productChangeStrategy,\n existingBalance = _ref.existingBalance,\n billingEndDate = _ref.billingEndDate,\n nextBillingAmount = _ref.nextBillingAmount,\n currentProductName = _ref.currentProductName,\n proratedCreditAmount = _ref.proratedCreditAmount;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_3__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n var isProrated = productChangeStrategy === 'prorated';\n var isImmediate = productChangeStrategy === 'non-prorated';\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Box, {\n marginBottom: 6\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body1',\n color: 'black.main'\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react_i18next__WEBPACK_IMPORTED_MODULE_4__.Trans, {\n t: t,\n i18nKey: 'plan_change.plan_change_from_to',\n tOptions: {\n currentPlan: currentProductName,\n newPlan: productName\n }\n }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Box, {\n marginBottom: 9\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Row, {\n rowGap: 8\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 24\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Heading, {\n variant: 'h4'\n }, t('plan_change.plan_summary_title', {\n planName: productName\n }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 12\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'gray.dark',\n fontWeight: 600\n }, t('plan_change.base_plan_price'))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 12\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n textAlign: 'right',\n color: 'success.main',\n fontWeight: 700\n }, basePlanPrice)), isProrated ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_index__WEBPACK_IMPORTED_MODULE_2__.ProratedColumns, {\n productName: productName,\n billingEndDate: billingEndDate,\n proratedCreditAmount: proratedCreditAmount\n }) : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_index__WEBPACK_IMPORTED_MODULE_2__.NonProratedColumns, {\n isImmediate: isImmediate,\n nextBillingAmount: nextBillingAmount,\n billingEndDate: billingEndDate,\n existingBalance: existingBalance,\n productName: productName\n }))));\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeSummary/PlanChangeSummary.tsx?");
|
|
8050
|
+
|
|
8051
|
+
/***/ }),
|
|
8052
|
+
|
|
8053
|
+
/***/ "./packages/subscriptions-manager/src/components/PlanChangeSummary/components/NonProratedColumns.tsx":
|
|
8054
|
+
/*!***********************************************************************************************************!*\
|
|
8055
|
+
!*** ./packages/subscriptions-manager/src/components/PlanChangeSummary/components/NonProratedColumns.tsx ***!
|
|
8056
|
+
\***********************************************************************************************************/
|
|
8057
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8058
|
+
|
|
8059
|
+
"use strict";
|
|
8060
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"NonProratedColumns\": () => (/* binding */ NonProratedColumns)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n\n\n\nvar NonProratedColumns = function NonProratedColumns(_ref) {\n var existingBalance = _ref.existingBalance,\n productName = _ref.productName,\n billingEndDate = _ref.billingEndDate,\n nextBillingAmount = _ref.nextBillingAmount,\n isImmediate = _ref.isImmediate;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_2__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, isImmediate ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 16\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'gray.dark',\n fontWeight: 600\n }, t('plan_change.current_credit_service_balance'))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 8\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n textAlign: 'right',\n color: 'success.main',\n fontWeight: 700\n }, existingBalance))) : null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 16\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'gray.dark',\n fontWeight: 600\n }, t('plan_change.next_billing_amount', {\n planName: productName,\n date: billingEndDate\n }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 8\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n textAlign: 'right',\n color: 'success.main',\n fontWeight: 700\n }, nextBillingAmount)));\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeSummary/components/NonProratedColumns.tsx?");
|
|
8061
|
+
|
|
8062
|
+
/***/ }),
|
|
8063
|
+
|
|
8064
|
+
/***/ "./packages/subscriptions-manager/src/components/PlanChangeSummary/components/ProratedColumns.tsx":
|
|
8065
|
+
/*!********************************************************************************************************!*\
|
|
8066
|
+
!*** ./packages/subscriptions-manager/src/components/PlanChangeSummary/components/ProratedColumns.tsx ***!
|
|
8067
|
+
\********************************************************************************************************/
|
|
8068
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8069
|
+
|
|
8070
|
+
"use strict";
|
|
8071
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"ProratedColumns\": () => (/* binding */ ProratedColumns)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n\n\n\nvar ProratedColumns = function ProratedColumns(_ref) {\n var proratedCreditAmount = _ref.proratedCreditAmount,\n productName = _ref.productName,\n billingEndDate = _ref.billingEndDate;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_2__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 12\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n variant: 'body2',\n color: 'gray.dark',\n fontWeight: 600\n }, t('plan_change.prorated_credit', {\n planName: productName,\n date: billingEndDate\n }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.Column, {\n span: 12\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_1__.BodyText, {\n textAlign: 'right',\n color: 'success.main',\n fontWeight: 700\n }, proratedCreditAmount)));\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeSummary/components/ProratedColumns.tsx?");
|
|
8072
|
+
|
|
8073
|
+
/***/ }),
|
|
8074
|
+
|
|
8075
|
+
/***/ "./packages/subscriptions-manager/src/components/PlanChangeSummary/components/index.ts":
|
|
8076
|
+
/*!*********************************************************************************************!*\
|
|
8077
|
+
!*** ./packages/subscriptions-manager/src/components/PlanChangeSummary/components/index.ts ***!
|
|
8078
|
+
\*********************************************************************************************/
|
|
8079
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8080
|
+
|
|
8081
|
+
"use strict";
|
|
8082
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"NonProratedColumns\": () => (/* reexport safe */ _NonProratedColumns__WEBPACK_IMPORTED_MODULE_1__.NonProratedColumns),\n/* harmony export */ \"ProratedColumns\": () => (/* reexport safe */ _ProratedColumns__WEBPACK_IMPORTED_MODULE_0__.ProratedColumns)\n/* harmony export */ });\n/* harmony import */ var _ProratedColumns__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ProratedColumns */ \"./packages/subscriptions-manager/src/components/PlanChangeSummary/components/ProratedColumns.tsx\");\n/* harmony import */ var _NonProratedColumns__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./NonProratedColumns */ \"./packages/subscriptions-manager/src/components/PlanChangeSummary/components/NonProratedColumns.tsx\");\n\n\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeSummary/components/index.ts?");
|
|
8028
8083
|
|
|
8029
8084
|
/***/ }),
|
|
8030
8085
|
|
|
@@ -8046,7 +8101,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
8046
8101
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8047
8102
|
|
|
8048
8103
|
"use strict";
|
|
8049
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PlanChangeSummaryCharges\": () => (/* binding */ PlanChangeSummaryCharges)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var i18next__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! i18next */ \"./node_modules/.pnpm/i18next@21.9.1/node_modules/i18next/dist/esm/i18next.js\");\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _chargify_formatters__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @chargify/formatters */ \"./packages/formatters/src/index.ts\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n/* harmony import */ var _Summary__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../Summary */ \"./packages/subscriptions-manager/src/components/Summary/index.ts\");\n/* harmony import */ var _utils_mapChargeSummaryToTable__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./utils/mapChargeSummaryToTable */ \"./packages/subscriptions-manager/src/components/PlanChangeSummaryCharges/utils/mapChargeSummaryToTable.ts\");\n/* harmony import */ var _TotalCharge__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../TotalCharge */ \"./packages/subscriptions-manager/src/components/TotalCharge/index.ts\");\n\n\n\n\n\n\n\n\nvar PlanChangeSummaryCharges = function PlanChangeSummaryCharges(_ref) {\n var changePlanPreview = _ref.changePlanPreview,\n currency = _ref.currency;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_7__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Summary__WEBPACK_IMPORTED_MODULE_4__.Summary, {\n paddingX: 5,\n paddingTop: 2,\n marginBottom:
|
|
8104
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PlanChangeSummaryCharges\": () => (/* binding */ PlanChangeSummaryCharges)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var i18next__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! i18next */ \"./node_modules/.pnpm/i18next@21.9.1/node_modules/i18next/dist/esm/i18next.js\");\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _chargify_formatters__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @chargify/formatters */ \"./packages/formatters/src/index.ts\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n/* harmony import */ var _Summary__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../Summary */ \"./packages/subscriptions-manager/src/components/Summary/index.ts\");\n/* harmony import */ var _utils_mapChargeSummaryToTable__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./utils/mapChargeSummaryToTable */ \"./packages/subscriptions-manager/src/components/PlanChangeSummaryCharges/utils/mapChargeSummaryToTable.ts\");\n/* harmony import */ var _TotalCharge__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../TotalCharge */ \"./packages/subscriptions-manager/src/components/TotalCharge/index.ts\");\n\n\n\n\n\n\n\n\nvar PlanChangeSummaryCharges = function PlanChangeSummaryCharges(_ref) {\n var changePlanPreview = _ref.changePlanPreview,\n currency = _ref.currency;\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_7__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Summary__WEBPACK_IMPORTED_MODULE_4__.Summary, {\n paddingX: 5,\n paddingTop: 2,\n marginBottom: 6\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_TotalCharge__WEBPACK_IMPORTED_MODULE_6__.TotalCharge, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.SummaryTable, {\n rows: (0,_utils_mapChargeSummaryToTable__WEBPACK_IMPORTED_MODULE_5__.mapChargeSummaryToTable)({\n changePlanPreview: changePlanPreview,\n t: t,\n language: i18next__WEBPACK_IMPORTED_MODULE_1__[\"default\"].language,\n currency: currency\n }),\n columnSpans: [12, 12]\n })), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.Box, {\n paddingTop: 3,\n paddingBottom: 4\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.Row, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.Column, {\n span: 12\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.BodyText, {\n variant: \"body1\",\n color: \"success.main\",\n fontWeight: 3\n }, t('plan_change.total_charge'))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.Column, {\n span: 12\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_3__.BodyText, {\n variant: \"body1\",\n color: \"success.main\",\n textAlign: \"right\",\n fontWeight: 3\n }, (0,_chargify_formatters__WEBPACK_IMPORTED_MODULE_2__.formatCurrency)(currency, changePlanPreview.totalInCents > 0 ? changePlanPreview.totalInCents : 0, i18next__WEBPACK_IMPORTED_MODULE_1__[\"default\"].language))))));\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeSummaryCharges/PlanChangeSummaryCharges.tsx?");
|
|
8050
8105
|
|
|
8051
8106
|
/***/ }),
|
|
8052
8107
|
|
|
@@ -8068,7 +8123,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
8068
8123
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
8069
8124
|
|
|
8070
8125
|
"use strict";
|
|
8071
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"mapChargeSummaryToTable\": () => (/* binding */ mapChargeSummaryToTable)\n/* harmony export */ });\n/* harmony import */ var _chargify_formatters__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @chargify/formatters */ \"./packages/formatters/src/index.ts\");\n\nvar mapChargeSummaryToTable = function mapChargeSummaryToTable(_ref) {\n var changePlanPreview = _ref.changePlanPreview,\n t = _ref.t,\n language = _ref.language,\n currency = _ref.currency;\n\n var formatAmount = function formatAmount(amount) {\n return (0,_chargify_formatters__WEBPACK_IMPORTED_MODULE_0__.formatCurrency)(currency, amount, language);\n };\n\n var chargesSummary = [[{\n value: t('plan_change.subtotal'),\n fontWeight: 3,\n fontSize: 1\n }, {\n value: formatAmount(changePlanPreview.subtotalInCents
|
|
8126
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"mapChargeSummaryToTable\": () => (/* binding */ mapChargeSummaryToTable)\n/* harmony export */ });\n/* harmony import */ var _chargify_formatters__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @chargify/formatters */ \"./packages/formatters/src/index.ts\");\n\nvar mapChargeSummaryToTable = function mapChargeSummaryToTable(_ref) {\n var changePlanPreview = _ref.changePlanPreview,\n t = _ref.t,\n language = _ref.language,\n currency = _ref.currency;\n\n var formatAmount = function formatAmount(amount) {\n return (0,_chargify_formatters__WEBPACK_IMPORTED_MODULE_0__.formatCurrency)(currency, amount, language);\n };\n\n var positiveCreditBalance = changePlanPreview.totalInCents > 0;\n var chargesSummary = [[{\n value: t('plan_change.subtotal'),\n fontWeight: 3,\n fontSize: 1\n }, {\n value: formatAmount(changePlanPreview.subtotalInCents),\n fontWeight: 3,\n fontSize: 1,\n textAlign: 'right'\n }], [{\n value: t('plan_change.taxes'),\n fontWeight: 3,\n fontSize: 1\n }, {\n value: formatAmount(changePlanPreview.totalTaxInCents),\n fontWeight: 3,\n fontSize: 1,\n textAlign: 'right'\n }]];\n\n if (changePlanPreview.productChangeStrategy === 'prorated') {\n chargesSummary.push([{\n value: positiveCreditBalance ? t('plan_change.credit_balance_to_be_applied') : t('plan_change.credit_balance_change'),\n fontWeight: 3,\n fontSize: 1\n }, {\n value: \"\".concat(positiveCreditBalance ? '' : '+').concat(formatAmount(Math.abs(changePlanPreview.totalInCents))),\n fontWeight: 3,\n fontSize: 1,\n textAlign: 'right'\n }]);\n }\n\n return chargesSummary;\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/components/PlanChangeSummaryCharges/utils/mapChargeSummaryToTable.ts?");
|
|
8072
8127
|
|
|
8073
8128
|
/***/ }),
|
|
8074
8129
|
|
|
@@ -9014,7 +9069,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
9014
9069
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9015
9070
|
|
|
9016
9071
|
"use strict";
|
|
9017
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PreviewProductMigrationContainer\": () => (/* binding */ PreviewProductMigrationContainer)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var i18next__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! i18next */ \"./node_modules/.pnpm/i18next@21.9.1/node_modules/i18next/dist/esm/i18next.js\");\n/* harmony import */ var
|
|
9072
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PreviewProductMigrationContainer\": () => (/* binding */ PreviewProductMigrationContainer)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var i18next__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! i18next */ \"./node_modules/.pnpm/i18next@21.9.1/node_modules/i18next/dist/esm/i18next.js\");\n/* harmony import */ var _xstate_react__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @xstate/react */ \"./node_modules/.pnpm/@xstate+react@3.0.1_csov6svwxizbqjpbal6caks7le/node_modules/@xstate/react/es/useSelector.js\");\n/* harmony import */ var _chargify_formatters__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @chargify/formatters */ \"./packages/formatters/src/index.ts\");\n/* harmony import */ var _components_PlanChangeSummaryCharges__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../components/PlanChangeSummaryCharges */ \"./packages/subscriptions-manager/src/components/PlanChangeSummaryCharges/index.ts\");\n/* harmony import */ var _machines_changePlan__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../machines/changePlan */ \"./packages/subscriptions-manager/src/machines/changePlan/index.ts\");\n/* harmony import */ var _components_PlanChangeSummary__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../components/PlanChangeSummary */ \"./packages/subscriptions-manager/src/components/PlanChangeSummary/index.ts\");\n/* harmony import */ var _components__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../components */ \"./packages/subscriptions-manager/src/components/index.ts\");\n\n\n\n\n\n\n\n\nvar PreviewProductMigrationContainer = function PreviewProductMigrationContainer(_ref) {\n var changePlanService = _ref.changePlanService,\n currency = _ref.currency,\n currentProductName = _ref.currentProductName;\n var planPreview = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_7__.useSelector)(changePlanService, _machines_changePlan__WEBPACK_IMPORTED_MODULE_4__.changePlanSelectors.getChangePlanPreview);\n var productChangeStrategy = planPreview.productChangeStrategy,\n product = planPreview.product,\n existingBalanceInCents = planPreview.existingBalanceInCents,\n billingEndDate = planPreview.billingEndDate,\n totalInCents = planPreview.totalInCents,\n proratedAdjustmentInCents = planPreview.proratedAdjustmentInCents;\n\n var formatAmount = function formatAmount(amount) {\n return (0,_chargify_formatters__WEBPACK_IMPORTED_MODULE_2__.formatCurrency)(currency, amount, i18next__WEBPACK_IMPORTED_MODULE_1__[\"default\"].language);\n };\n\n var nextBillingAmountInCents = product.priceInCents - existingBalanceInCents;\n var isNotDelayed = productChangeStrategy !== 'delayed';\n var basePlanPrice = formatAmount(product.priceInCents);\n var totalCharge = formatAmount(totalInCents > 0 ? totalInCents : 0);\n var nextBillingDate = (0,_chargify_formatters__WEBPACK_IMPORTED_MODULE_2__.formatDate)(billingEndDate, i18next__WEBPACK_IMPORTED_MODULE_1__[\"default\"].language);\n var existingBalance = formatAmount(existingBalanceInCents);\n var nextBillingAmount = formatAmount(nextBillingAmountInCents);\n var proratedCreditAmount = formatAmount(proratedAdjustmentInCents);\n var creditBalance = formatAmount(totalInCents < 0 ? Math.abs(totalInCents) : 0);\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(\"div\", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_PlanChangeSummary__WEBPACK_IMPORTED_MODULE_5__.PlanChangeSummary, {\n currentProductName: currentProductName,\n productChangeStrategy: productChangeStrategy,\n productName: product.name,\n basePlanPrice: basePlanPrice,\n billingEndDate: (0,_chargify_formatters__WEBPACK_IMPORTED_MODULE_2__.formatDate)(billingEndDate),\n existingBalance: existingBalance,\n nextBillingAmount: nextBillingAmount,\n proratedCreditAmount: proratedCreditAmount\n }), isNotDelayed ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_PlanChangeSummaryCharges__WEBPACK_IMPORTED_MODULE_3__[\"default\"], {\n changePlanPreview: planPreview,\n currency: currency\n }) : null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components__WEBPACK_IMPORTED_MODULE_6__.PlanChangeAlerts, {\n creditBalance: creditBalance,\n productChangeStrategy: productChangeStrategy,\n nextBillingDate: nextBillingDate,\n basePlanPrice: basePlanPrice,\n totalCharge: totalCharge\n }));\n};\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/containers/PreviewProductMigrationContainer/PreviewProductMigrationContainer.tsx?");
|
|
9018
9073
|
|
|
9019
9074
|
/***/ }),
|
|
9020
9075
|
|
|
@@ -10532,7 +10587,7 @@ eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harm
|
|
|
10532
10587
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
10533
10588
|
|
|
10534
10589
|
"use strict";
|
|
10535
|
-
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _xstate_react__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @xstate/react */ \"./node_modules/.pnpm/@xstate+react@3.0.1_csov6svwxizbqjpbal6caks7le/node_modules/@xstate/react/es/useSelector.js\");\n/* harmony import */ var _chargify_toasts__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/toasts */ \"./packages/toasts/src/index.ts\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n/* harmony import */ var _hooks__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../hooks */ \"./packages/subscriptions-manager/src/hooks/index.ts\");\n/* harmony import */ var _contexts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../contexts */ \"./packages/subscriptions-manager/src/contexts/index.ts\");\n/* harmony import */ var _machines__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../machines */ \"./packages/subscriptions-manager/src/machines/index.ts\");\n/* harmony import */ var _machines_changePlan__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../machines/changePlan */ \"./packages/subscriptions-manager/src/machines/changePlan/index.ts\");\n/* harmony import */ var _containers_ChangePlanContainer__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../containers/ChangePlanContainer */ \"./packages/subscriptions-manager/src/containers/ChangePlanContainer/index.ts\");\n/* harmony import */ var _containers_PreviewProductMigrationContainer__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../containers/PreviewProductMigrationContainer */ \"./packages/subscriptions-manager/src/containers/PreviewProductMigrationContainer/index.ts\");\n/* harmony import */ var _components_ErrorAlert__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./components/ErrorAlert */ \"./packages/subscriptions-manager/src/modals/ChangeSubscriptionPlan/components/Content/components/ErrorAlert.tsx\");\n\n\n\n\n\n\n\n\n\n\n\n\n\nvar Content = function Content(_ref) {\n var onClose = _ref.onClose,\n catalogId = _ref.catalogId,\n subscriptionId = _ref.subscriptionId,\n displayMode = _ref.displayMode,\n onProcessingUpdate = _ref.onProcessingUpdate;\n var toastService = (0,_chargify_toasts__WEBPACK_IMPORTED_MODULE_1__.useToastMessages)();\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_10__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n var _useContext = (0,react__WEBPACK_IMPORTED_MODULE_0__.useContext)(_contexts__WEBPACK_IMPORTED_MODULE_4__.GlobalStateContext),\n subscriptionsService = _useContext.subscriptionsService;\n\n var _useSelector = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_11__.useSelector)(subscriptionsService, _machines__WEBPACK_IMPORTED_MODULE_5__.subscriptionsSelectors.getSubscriptionById(catalogId, subscriptionId)),\n subscription = _useSelector.subscription;\n\n var onPlanChangeSuccess = function onPlanChangeSuccess() {\n onClose(true);\n toastService.show({\n level: 'success',\n message: t('plan_change.success_plan_change')\n });\n };\n\n var changePlanService = (0,_hooks__WEBPACK_IMPORTED_MODULE_3__.useChangePlan)(catalogId, subscriptionId, subscription.product.id, onPlanChangeSuccess);\n var currentPlanId = subscription.product.id;\n\n var _useSelector2 = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_11__.useSelector)(changePlanService, _machines_changePlan__WEBPACK_IMPORTED_MODULE_6__.changePlanSelectors.getChangePlanStatus),\n configurePlanStep = _useSelector2.configurePlanStep,\n previewPlanStep = _useSelector2.previewPlanStep,\n configurePlanStepLoading = _useSelector2.configurePlanStepLoading,\n updatePlanLoading = _useSelector2.updatePlanLoading,\n previewPlanLoading = _useSelector2.previewPlanLoading,\n isError = _useSelector2.isError;\n\n var selectedPlan = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_11__.useSelector)(changePlanService, _machines_changePlan__WEBPACK_IMPORTED_MODULE_6__.changePlanSelectors.getSelectedPlan);\n (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {\n changePlanService.send({\n type: 'GET_PRODUCTS'\n });\n }, []);\n (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {\n onProcessingUpdate(updatePlanLoading);\n }, [updatePlanLoading, onProcessingUpdate]);\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Card, {\n border: displayMode === 'layer' ? 'sharp' : 'rounded'\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Card.Header, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Modal.Title, {\n onClose: onClose,\n title:
|
|
10590
|
+
eval("/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ \"./node_modules/.pnpm/react@18.2.0/node_modules/react/index.js\");\n/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var react_i18next__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! react-i18next */ \"./node_modules/.pnpm/react-i18next@11.18.6_4sidbwfhen5r7txudrvpua6nty/node_modules/react-i18next/dist/es/useTranslation.js\");\n/* harmony import */ var _xstate_react__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @xstate/react */ \"./node_modules/.pnpm/@xstate+react@3.0.1_csov6svwxizbqjpbal6caks7le/node_modules/@xstate/react/es/useSelector.js\");\n/* harmony import */ var _chargify_toasts__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @chargify/toasts */ \"./packages/toasts/src/index.ts\");\n/* harmony import */ var _chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @chargify/custom-ui-components */ \"./packages/custom-ui-components/src/index.ts\");\n/* harmony import */ var _hooks__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../hooks */ \"./packages/subscriptions-manager/src/hooks/index.ts\");\n/* harmony import */ var _contexts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../contexts */ \"./packages/subscriptions-manager/src/contexts/index.ts\");\n/* harmony import */ var _machines__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../machines */ \"./packages/subscriptions-manager/src/machines/index.ts\");\n/* harmony import */ var _machines_changePlan__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../machines/changePlan */ \"./packages/subscriptions-manager/src/machines/changePlan/index.ts\");\n/* harmony import */ var _containers_ChangePlanContainer__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../containers/ChangePlanContainer */ \"./packages/subscriptions-manager/src/containers/ChangePlanContainer/index.ts\");\n/* harmony import */ var _containers_PreviewProductMigrationContainer__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../../../containers/PreviewProductMigrationContainer */ \"./packages/subscriptions-manager/src/containers/PreviewProductMigrationContainer/index.ts\");\n/* harmony import */ var _components_ErrorAlert__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./components/ErrorAlert */ \"./packages/subscriptions-manager/src/modals/ChangeSubscriptionPlan/components/Content/components/ErrorAlert.tsx\");\n\n\n\n\n\n\n\n\n\n\n\n\n\nvar Content = function Content(_ref) {\n var onClose = _ref.onClose,\n catalogId = _ref.catalogId,\n subscriptionId = _ref.subscriptionId,\n displayMode = _ref.displayMode,\n onProcessingUpdate = _ref.onProcessingUpdate;\n var toastService = (0,_chargify_toasts__WEBPACK_IMPORTED_MODULE_1__.useToastMessages)();\n\n var _useTranslation = (0,react_i18next__WEBPACK_IMPORTED_MODULE_10__.useTranslation)(['subscriptions-manager']),\n t = _useTranslation.t;\n\n var _useContext = (0,react__WEBPACK_IMPORTED_MODULE_0__.useContext)(_contexts__WEBPACK_IMPORTED_MODULE_4__.GlobalStateContext),\n subscriptionsService = _useContext.subscriptionsService;\n\n var _useSelector = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_11__.useSelector)(subscriptionsService, _machines__WEBPACK_IMPORTED_MODULE_5__.subscriptionsSelectors.getSubscriptionById(catalogId, subscriptionId)),\n subscription = _useSelector.subscription;\n\n var onPlanChangeSuccess = function onPlanChangeSuccess() {\n onClose(true);\n toastService.show({\n level: 'success',\n message: t('plan_change.success_plan_change')\n });\n };\n\n var changePlanService = (0,_hooks__WEBPACK_IMPORTED_MODULE_3__.useChangePlan)(catalogId, subscriptionId, subscription.product.id, onPlanChangeSuccess);\n var currentPlanId = subscription.product.id;\n\n var _useSelector2 = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_11__.useSelector)(changePlanService, _machines_changePlan__WEBPACK_IMPORTED_MODULE_6__.changePlanSelectors.getChangePlanStatus),\n configurePlanStep = _useSelector2.configurePlanStep,\n previewPlanStep = _useSelector2.previewPlanStep,\n configurePlanStepLoading = _useSelector2.configurePlanStepLoading,\n updatePlanLoading = _useSelector2.updatePlanLoading,\n previewPlanLoading = _useSelector2.previewPlanLoading,\n isError = _useSelector2.isError;\n\n var selectedPlan = (0,_xstate_react__WEBPACK_IMPORTED_MODULE_11__.useSelector)(changePlanService, _machines_changePlan__WEBPACK_IMPORTED_MODULE_6__.changePlanSelectors.getSelectedPlan);\n (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {\n changePlanService.send({\n type: 'GET_PRODUCTS'\n });\n }, []);\n (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {\n onProcessingUpdate(updatePlanLoading);\n }, [updatePlanLoading, onProcessingUpdate]);\n var modalTitle = configurePlanStep ? t('plan_change.change_plan') : t('plan_change.summary_title');\n return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Card, {\n border: displayMode === 'layer' ? 'sharp' : 'rounded'\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Card.Header, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Modal.Title, {\n onClose: onClose,\n title: modalTitle\n })), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Card.Body, null, isError ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_components_ErrorAlert__WEBPACK_IMPORTED_MODULE_9__.ErrorAlert, null) : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, configurePlanStepLoading ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.SkeletonLoader, {\n height: 400\n }) : null, configurePlanStep ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_containers_ChangePlanContainer__WEBPACK_IMPORTED_MODULE_7__[\"default\"], {\n changePlanService: changePlanService,\n currency: subscription.currency,\n currentPlanId: currentPlanId\n }) : null, previewPlanStep ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_containers_PreviewProductMigrationContainer__WEBPACK_IMPORTED_MODULE_8__[\"default\"], {\n currentProductName: subscription.product.name,\n currency: subscription.currency,\n changePlanService: changePlanService\n }) : null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Card.Footer, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Button.Group, {\n alignment: \"right\"\n }, previewPlanStep && !isError ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Box, {\n marginRight: 'auto'\n }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Button, {\n color: 'secondary',\n label: t('go_back', {\n ns: 'common'\n }),\n onClick: function onClick() {\n return changePlanService.send({\n type: 'GO_BACK'\n });\n },\n iconLeft: 'chevronLeft'\n })) : null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Button, {\n color: \"secondary\",\n label: t('close', {\n ns: 'common'\n }),\n onClick: function onClick() {\n return onClose(false);\n }\n }), configurePlanStep && !isError ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Button, {\n isLoading: previewPlanLoading,\n label: t('continue', {\n ns: 'common'\n }),\n disabled: selectedPlan === currentPlanId,\n loadingText: t('processing', {\n ns: 'common'\n }),\n onClick: function onClick() {\n return changePlanService.send({\n type: 'GET_PREVIEW_PRODUCT_MIGRATION'\n });\n }\n }) : null, previewPlanStep && !isError ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_chargify_custom_ui_components__WEBPACK_IMPORTED_MODULE_2__.Button, {\n label: t('confirm_changes', {\n ns: 'common'\n }),\n isLoading: updatePlanLoading,\n loadingText: t('processing', {\n ns: 'common'\n }),\n onClick: function onClick() {\n return changePlanService.send({\n type: 'CONFIRM_CHANGE_PLAN'\n });\n }\n }) : null)));\n};\n\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Content);\n\n//# sourceURL=webpack://Maxio/./packages/subscriptions-manager/src/modals/ChangeSubscriptionPlan/components/Content/Content.tsx?");
|
|
10536
10591
|
|
|
10537
10592
|
/***/ }),
|
|
10538
10593
|
|
package/package.json
CHANGED
|
@@ -9,12 +9,15 @@ export interface AlertProps {
|
|
|
9
9
|
onClick?: () => void;
|
|
10
10
|
buttonLabel?: string;
|
|
11
11
|
icon?: IconType;
|
|
12
|
-
whiteSpace?: 'pre-line' | 'normal';
|
|
13
12
|
}
|
|
14
13
|
declare const Alert: {
|
|
15
|
-
({ title, color, size, buttonLabel, icon, onClick, children,
|
|
14
|
+
({ title, color, size, buttonLabel, icon, onClick, children, }: AlertProps): JSX.Element;
|
|
16
15
|
TextMessage: ({ children, ...rest }: {
|
|
17
16
|
children: React.ReactNode;
|
|
18
17
|
} & import("../../atoms/BodyText/BodyText").BodyTextProps) => JSX.Element;
|
|
18
|
+
Title: ({ text, icon }: {
|
|
19
|
+
text: string;
|
|
20
|
+
icon?: "close" | "edit" | "plus" | "clock" | "search" | "chevronDown" | "chevronLeft" | "chevronRight" | "calendar" | "check" | "spinner" | "questionCircle" | "receipt" | "file" | "fileSolid" | "filter" | "arrowDown" | "filePlus" | "filePdf" | "circleInfo" | "circleCheck" | "exclamationTriangle" | "ellipsis" | "circleCross";
|
|
21
|
+
}) => JSX.Element;
|
|
19
22
|
};
|
|
20
23
|
export default Alert;
|
package/typings/packages/custom-ui-components/src/components/molecules/Alert/Alert.styles.d.ts
CHANGED
|
@@ -3,4 +3,3 @@ export declare const Container: import("styled-components").StyledComponent<"div
|
|
|
3
3
|
color: Color;
|
|
4
4
|
size: Size;
|
|
5
5
|
}, never>;
|
|
6
|
-
export declare const IconWrapper: import("styled-components").StyledComponent<"div", any, import("styled-system").MarginProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>> & import("styled-system").PaddingProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>> & import("styled-system").LayoutProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>> & import("styled-system").JustifyContentProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>>, never>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { ColorProps } from 'styled-system';
|
|
2
|
-
export declare const IconWrapper: import("styled-components").StyledComponent<"
|
|
2
|
+
export declare const IconWrapper: import("styled-components").StyledComponent<"span", any, {
|
|
3
3
|
size: number;
|
|
4
4
|
} & ColorProps<Required<import("styled-system").Theme<import("styled-system").TLengthStyledSystem>>, string | number | symbol>, never>;
|
package/typings/packages/subscriptions-manager/src/components/PlanChangeAlerts/PlanChangeAlerts.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ declare type Props = {
|
|
|
5
5
|
nextBillingDate: string;
|
|
6
6
|
basePlanPrice: string;
|
|
7
7
|
totalCharge: string;
|
|
8
|
+
creditBalance: string;
|
|
8
9
|
};
|
|
9
|
-
export declare const PlanChangeAlerts: ({ basePlanPrice, productChangeStrategy, nextBillingDate, totalCharge, }: Props) => JSX.Element;
|
|
10
|
+
export declare const PlanChangeAlerts: ({ basePlanPrice, productChangeStrategy, nextBillingDate, totalCharge, creditBalance, }: Props) => JSX.Element;
|
|
10
11
|
export {};
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { ProductChangeStrategy } from '../../machines/changePlan/index';
|
|
2
3
|
declare type Props = {
|
|
3
4
|
productName: string;
|
|
4
5
|
basePlanPrice: string;
|
|
5
|
-
|
|
6
|
+
productChangeStrategy: ProductChangeStrategy;
|
|
6
7
|
existingBalance: string;
|
|
7
8
|
billingEndDate: string;
|
|
8
9
|
nextBillingAmount: string;
|
|
10
|
+
proratedCreditAmount: string;
|
|
11
|
+
currentProductName: string;
|
|
9
12
|
};
|
|
10
|
-
export declare const PlanChangeSummary: ({ productName, basePlanPrice,
|
|
13
|
+
export declare const PlanChangeSummary: ({ productName, basePlanPrice, productChangeStrategy, existingBalance, billingEndDate, nextBillingAmount, currentProductName, proratedCreditAmount, }: Props) => JSX.Element;
|
|
11
14
|
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare type Props = {
|
|
3
|
+
existingBalance: string;
|
|
4
|
+
billingEndDate: string;
|
|
5
|
+
nextBillingAmount: string;
|
|
6
|
+
productName: string;
|
|
7
|
+
isImmediate: boolean;
|
|
8
|
+
};
|
|
9
|
+
export declare const NonProratedColumns: ({ existingBalance, productName, billingEndDate, nextBillingAmount, isImmediate, }: Props) => JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare type Props = {
|
|
3
|
+
productName: string;
|
|
4
|
+
billingEndDate: string;
|
|
5
|
+
proratedCreditAmount: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const ProratedColumns: ({ proratedCreditAmount, productName, billingEndDate, }: Props) => JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -4,6 +4,7 @@ import { ChangePlanInterpreter } from '../../machines/changePlan/types';
|
|
|
4
4
|
declare type Props = {
|
|
5
5
|
changePlanService: ChangePlanInterpreter;
|
|
6
6
|
currency: Currency;
|
|
7
|
+
currentProductName: string;
|
|
7
8
|
};
|
|
8
|
-
export declare const PreviewProductMigrationContainer: ({ changePlanService, currency, }: Props) => JSX.Element;
|
|
9
|
+
export declare const PreviewProductMigrationContainer: ({ changePlanService, currency, currentProductName, }: Props) => JSX.Element;
|
|
9
10
|
export {};
|