@edx/frontend-app-alacarte-checkout 1.30.0 → 1.31.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.
Files changed (34) hide show
  1. package/dist/components/CheckoutGate/CheckoutGate.js +1 -1
  2. package/dist/components/CheckoutGate/CheckoutGate.js.map +1 -1
  3. package/dist/components/HelpCenter/HelpCenter.d.ts +3 -0
  4. package/dist/components/HelpCenter/HelpCenter.js +13 -0
  5. package/dist/components/HelpCenter/HelpCenter.js.map +1 -0
  6. package/dist/components/HelpCenter/messages.d.ts +13 -0
  7. package/dist/components/HelpCenter/messages.js +15 -0
  8. package/dist/components/HelpCenter/messages.js.map +1 -0
  9. package/dist/components/OrderHistory/OrderHistory.d.ts +3 -0
  10. package/dist/components/OrderHistory/OrderHistory.js +10 -0
  11. package/dist/components/OrderHistory/OrderHistory.js.map +1 -0
  12. package/dist/components/OrderHistory/OrderHistoryHeader.d.ts +3 -0
  13. package/dist/components/OrderHistory/OrderHistoryHeader.js +9 -0
  14. package/dist/components/OrderHistory/OrderHistoryHeader.js.map +1 -0
  15. package/dist/components/OrderHistory/OrderHistoryTabDetails/CoursePayments.d.ts +3 -0
  16. package/dist/components/OrderHistory/OrderHistoryTabDetails/CoursePayments.js +9 -0
  17. package/dist/components/OrderHistory/OrderHistoryTabDetails/CoursePayments.js.map +1 -0
  18. package/dist/components/OrderHistory/OrderHistoryTabDetails/SubscriptionPayments.d.ts +3 -0
  19. package/dist/components/OrderHistory/OrderHistoryTabDetails/SubscriptionPayments.js +9 -0
  20. package/dist/components/OrderHistory/OrderHistoryTabDetails/SubscriptionPayments.js.map +1 -0
  21. package/dist/components/OrderHistory/OrderHistoryTabDetails/messages.d.ts +18 -0
  22. package/dist/components/OrderHistory/OrderHistoryTabDetails/messages.js +20 -0
  23. package/dist/components/OrderHistory/OrderHistoryTabDetails/messages.js.map +1 -0
  24. package/dist/components/OrderHistory/OrderHistoryTabs/OrderHistoryTabs.d.ts +2 -0
  25. package/dist/components/OrderHistory/OrderHistoryTabs/OrderHistoryTabs.js +32 -0
  26. package/dist/components/OrderHistory/OrderHistoryTabs/OrderHistoryTabs.js.map +1 -0
  27. package/dist/components/OrderHistory/messages.d.ts +23 -0
  28. package/dist/components/OrderHistory/messages.js +25 -0
  29. package/dist/components/OrderHistory/messages.js.map +1 -0
  30. package/dist/routes.js +27 -0
  31. package/dist/routes.js.map +1 -1
  32. package/dist/style.scss +1 -0
  33. package/dist/styles/components/orderHistory.scss +3 -0
  34. package/package.json +1 -1
@@ -37,7 +37,7 @@ const CheckoutGate = (_a) => {
37
37
  if (gateStatus === 'blocked') {
38
38
  return (_jsx(_Fragment, { children: _jsx(CountryUnavailableModal, { isOpen: true, homeUrl: homeUrl }) }));
39
39
  }
40
- return (_jsx(Checkout, Object.assign({}, checkoutProps, { userCountry: userCountry, homeUrl: homeUrl, orderHistoryUrl: learnerDashboardUrl })));
40
+ return (_jsx(Checkout, Object.assign({}, checkoutProps, { userCountry: userCountry, homeUrl: homeUrl, orderHistoryUrl: "/aca-order-history" })));
41
41
  };
42
42
  export default CheckoutGate;
43
43
  //# sourceMappingURL=CheckoutGate.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"CheckoutGate.js","sourceRoot":"","sources":["../../../src/components/CheckoutGate/CheckoutGate.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACnE,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,uBAAuB,MAAM,oDAAoD,CAAC;AAEzF,OAAO,QAAQ,MAAM,YAAY,CAAC;AAalC,MAAM,YAAY,GAAG,CAAC,EAMF,EAAE,EAAE;QANF,EACpB,mBAAmB,EACnB,OAAO,GAAG,GAAG,EACb,kBAAkB,EAClB,sBAAsB,OAEJ,EADf,aAAa,cALI,kFAMrB,CADiB;IAEhB,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IACpC,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,eAAe,CAAC;QAC/D,MAAM,EAAE,aAAa,CAAC,MAAM;QAC5B,aAAa,EAAE,aAAa,CAAC,aAAa;QAC1C,cAAc,EAAE,aAAa,CAAC,cAAc;QAC5C,kBAAkB;QAClB,sBAAsB;QACtB,mBAAmB;KACpB,CAAC,CAAC;IAEH,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,OAAO,CACL,cAAK,SAAS,EAAC,mBAAmB,EAAC,IAAI,EAAC,QAAQ,eAAW,QAAQ,YACjE,KAAC,OAAO,IAAC,SAAS,EAAC,QAAQ,EAAC,gBAAgB,EAAC,6BAAwB,GAAG,GACpE,CACP,CAAC;IACJ,CAAC;IAED,IAAI,UAAU,KAAK,OAAO,EAAE,CAAC;QAC3B,OAAO,CACL,MAAC,KAAK,IAAC,OAAO,EAAC,QAAQ,EAAC,IAAI,EAAE,SAAS,aACpC,WAAW,aAAX,WAAW,cAAX,WAAW,GACT,aAAa,CAAC,QAAQ,CAAC,mBAAmB,CAAC,EAAE,GAAG,EAClD,mBAAmB,IAAI,CACtB,YAAG,IAAI,EAAE,mBAAmB,EAAE,SAAS,EAAC,YAAY,6CAEhD,CACL,IACK,CACT,CAAC;IACJ,CAAC;IAED,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,OAAO,CACL,4BACE,KAAC,uBAAuB,IAAC,MAAM,QAAC,OAAO,EAAE,OAAO,GAAI,GACnD,CACJ,CAAC;IACJ,CAAC;IAED,OAAO,CACL,KAAC,QAAQ,oBACH,aAAa,IACjB,WAAW,EAAE,WAAW,EACxB,OAAO,EAAE,OAAO,EAChB,eAAe,EAAE,mBAAmB,IACpC,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import { Alert, Spinner } from '@openedx/paragon';\nimport { Error as ErrorIcon } from '@openedx/paragon/icons';\nimport { useIntl } from '@openedx/frontend-base';\nimport { useCheckoutGate } from '../../data/hooks/useCheckoutGate';\nimport Checkout from '../Checkout/Checkout';\nimport CountryUnavailableModal from '../CountryUnavailableModal/CountryUnavailableModal';\nimport type { CheckoutProps } from '../Checkout/Checkout';\nimport messages from './Messages';\n\nexport interface CheckoutGateProps extends CheckoutProps {\n /** URL linked in session-error recovery messaging. */\n learnerDashboardUrl?: string,\n /** Homepage URL for the country-unavailable modal CTA. */\n homeUrl?: string,\n /** ALC-307 compliance-check endpoint — decides whether the learner is embargoed. */\n complianceCheckUrl?: string,\n /** When true, skip the compliance-check request. */\n disableComplianceCheck?: boolean,\n}\n\nconst CheckoutGate = ({\n learnerDashboardUrl,\n homeUrl = '/',\n complianceCheckUrl,\n disableComplianceCheck,\n ...checkoutProps\n}: CheckoutGateProps) => {\n const { formatMessage } = useIntl();\n const { gateStatus, userCountry, gateMessage } = useCheckoutGate({\n apiUrl: checkoutProps.apiUrl,\n edxSessionUrl: checkoutProps.edxSessionUrl,\n geolocationUrl: checkoutProps.geolocationUrl,\n complianceCheckUrl,\n disableComplianceCheck,\n learnerDashboardUrl,\n });\n\n if (gateStatus === 'loading') {\n return (\n <div className=\"processing-screen\" role=\"status\" aria-live=\"polite\">\n <Spinner animation=\"border\" screenReaderText=\"Checking your account…\" />\n </div>\n );\n }\n\n if (gateStatus === 'error') {\n return (\n <Alert variant=\"danger\" icon={ErrorIcon}>\n {gateMessage\n ?? formatMessage(messages.defaultErrorMessage)}{' '}\n {learnerDashboardUrl && (\n <a href={learnerDashboardUrl} className=\"alert-link\">\n Go to your learner dashboard\n </a>\n )}\n </Alert>\n );\n }\n\n if (gateStatus === 'blocked') {\n return (\n <>\n <CountryUnavailableModal isOpen homeUrl={homeUrl} />\n </>\n );\n }\n\n return (\n <Checkout\n {...checkoutProps}\n userCountry={userCountry}\n homeUrl={homeUrl}\n orderHistoryUrl={learnerDashboardUrl}\n />\n );\n};\n\nexport default CheckoutGate;\n"]}
1
+ {"version":3,"file":"CheckoutGate.js","sourceRoot":"","sources":["../../../src/components/CheckoutGate/CheckoutGate.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,KAAK,IAAI,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACnE,OAAO,QAAQ,MAAM,sBAAsB,CAAC;AAC5C,OAAO,uBAAuB,MAAM,oDAAoD,CAAC;AAEzF,OAAO,QAAQ,MAAM,YAAY,CAAC;AAalC,MAAM,YAAY,GAAG,CAAC,EAMF,EAAE,EAAE;QANF,EACpB,mBAAmB,EACnB,OAAO,GAAG,GAAG,EACb,kBAAkB,EAClB,sBAAsB,OAEJ,EADf,aAAa,cALI,kFAMrB,CADiB;IAEhB,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IACpC,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,eAAe,CAAC;QAC/D,MAAM,EAAE,aAAa,CAAC,MAAM;QAC5B,aAAa,EAAE,aAAa,CAAC,aAAa;QAC1C,cAAc,EAAE,aAAa,CAAC,cAAc;QAC5C,kBAAkB;QAClB,sBAAsB;QACtB,mBAAmB;KACpB,CAAC,CAAC;IAEH,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,OAAO,CACL,cAAK,SAAS,EAAC,mBAAmB,EAAC,IAAI,EAAC,QAAQ,eAAW,QAAQ,YACjE,KAAC,OAAO,IAAC,SAAS,EAAC,QAAQ,EAAC,gBAAgB,EAAC,6BAAwB,GAAG,GACpE,CACP,CAAC;IACJ,CAAC;IAED,IAAI,UAAU,KAAK,OAAO,EAAE,CAAC;QAC3B,OAAO,CACL,MAAC,KAAK,IAAC,OAAO,EAAC,QAAQ,EAAC,IAAI,EAAE,SAAS,aACpC,WAAW,aAAX,WAAW,cAAX,WAAW,GACT,aAAa,CAAC,QAAQ,CAAC,mBAAmB,CAAC,EAAE,GAAG,EAClD,mBAAmB,IAAI,CACtB,YAAG,IAAI,EAAE,mBAAmB,EAAE,SAAS,EAAC,YAAY,6CAEhD,CACL,IACK,CACT,CAAC;IACJ,CAAC;IAED,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC7B,OAAO,CACL,4BACE,KAAC,uBAAuB,IAAC,MAAM,QAAC,OAAO,EAAE,OAAO,GAAI,GACnD,CACJ,CAAC;IACJ,CAAC;IACD,OAAO,CACL,KAAC,QAAQ,oBACH,aAAa,IACjB,WAAW,EAAE,WAAW,EACxB,OAAO,EAAE,OAAO,EAChB,eAAe,EAAC,oBAAoB,IACpC,CACH,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import { Alert, Spinner } from '@openedx/paragon';\nimport { Error as ErrorIcon } from '@openedx/paragon/icons';\nimport { useIntl } from '@openedx/frontend-base';\nimport { useCheckoutGate } from '../../data/hooks/useCheckoutGate';\nimport Checkout from '../Checkout/Checkout';\nimport CountryUnavailableModal from '../CountryUnavailableModal/CountryUnavailableModal';\nimport type { CheckoutProps } from '../Checkout/Checkout';\nimport messages from './Messages';\n\nexport interface CheckoutGateProps extends CheckoutProps {\n /** URL linked in session-error recovery messaging. */\n learnerDashboardUrl?: string,\n /** Homepage URL for the country-unavailable modal CTA. */\n homeUrl?: string,\n /** ALC-307 compliance-check endpoint — decides whether the learner is embargoed. */\n complianceCheckUrl?: string,\n /** When true, skip the compliance-check request. */\n disableComplianceCheck?: boolean,\n}\n\nconst CheckoutGate = ({\n learnerDashboardUrl,\n homeUrl = '/',\n complianceCheckUrl,\n disableComplianceCheck,\n ...checkoutProps\n}: CheckoutGateProps) => {\n const { formatMessage } = useIntl();\n const { gateStatus, userCountry, gateMessage } = useCheckoutGate({\n apiUrl: checkoutProps.apiUrl,\n edxSessionUrl: checkoutProps.edxSessionUrl,\n geolocationUrl: checkoutProps.geolocationUrl,\n complianceCheckUrl,\n disableComplianceCheck,\n learnerDashboardUrl,\n });\n\n if (gateStatus === 'loading') {\n return (\n <div className=\"processing-screen\" role=\"status\" aria-live=\"polite\">\n <Spinner animation=\"border\" screenReaderText=\"Checking your account…\" />\n </div>\n );\n }\n\n if (gateStatus === 'error') {\n return (\n <Alert variant=\"danger\" icon={ErrorIcon}>\n {gateMessage\n ?? formatMessage(messages.defaultErrorMessage)}{' '}\n {learnerDashboardUrl && (\n <a href={learnerDashboardUrl} className=\"alert-link\">\n Go to your learner dashboard\n </a>\n )}\n </Alert>\n );\n }\n\n if (gateStatus === 'blocked') {\n return (\n <>\n <CountryUnavailableModal isOpen homeUrl={homeUrl} />\n </>\n );\n }\n return (\n <Checkout\n {...checkoutProps}\n userCountry={userCountry}\n homeUrl={homeUrl}\n orderHistoryUrl=\"/aca-order-history\"\n />\n );\n};\n\nexport default CheckoutGate;\n"]}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const HelpCenter: React.FC;
3
+ export default HelpCenter;
@@ -0,0 +1,13 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { Link } from 'react-router-dom';
3
+ import { useIntl } from '@openedx/frontend-base';
4
+ import messages from './messages';
5
+ import { LEARNER_HELP_CENTER_URL } from '../../constants';
6
+ import Icon from '@openedx/paragon/dist/Icon';
7
+ import { Launch } from '@openedx/paragon/icons';
8
+ const HelpCenter = () => {
9
+ const { formatMessage } = useIntl();
10
+ return (_jsx("div", { className: "manage-help mt-5 pt-4 border-top", children: _jsxs("p", { className: "manage-help__text text-gray-700 small mb-0", children: [formatMessage(messages.helpLinkText), ' ', _jsxs(Link, { to: LEARNER_HELP_CENTER_URL, className: "manage-help__link text-primary-500 d-inline-flex align-items-center", target: "_blank", rel: "noopener noreferrer", children: [formatMessage(messages.helpLink), _jsx(Icon, { src: Launch, className: "icon mr-1", "data-testid": "help-center-icon" })] })] }) }));
11
+ };
12
+ export default HelpCenter;
13
+ //# sourceMappingURL=HelpCenter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"HelpCenter.js","sourceRoot":"","sources":["../../../src/components/HelpCenter/HelpCenter.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEjD,OAAO,QAAQ,MAAM,YAAY,CAAC;AAClC,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC;AAC1D,OAAO,IAAI,MAAM,4BAA4B,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAEhD,MAAM,UAAU,GAAa,GAAG,EAAE;IAChC,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IAEpC,OAAO,CACL,cAAK,SAAS,EAAC,kCAAkC,YAC/C,aAAG,SAAS,EAAC,4CAA4C,aACtD,aAAa,CAAC,QAAQ,CAAC,YAAY,CAAC,EACpC,GAAG,EACJ,MAAC,IAAI,IAAC,EAAE,EAAE,uBAAuB,EAAE,SAAS,EAAC,qEAAqE,EAAC,MAAM,EAAC,QAAQ,EAAC,GAAG,EAAC,qBAAqB,aACzJ,aAAa,CAAC,QAAQ,CAAC,QAAQ,CAAC,EACjC,KAAC,IAAI,IAAC,GAAG,EAAE,MAAM,EAAE,SAAS,EAAC,WAAW,iBAAa,kBAAkB,GAAG,IACrE,IACL,GACA,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,UAAU,CAAC","sourcesContent":["import React from 'react';\nimport { Link } from 'react-router-dom';\nimport { useIntl } from '@openedx/frontend-base';\n\nimport messages from './messages';\nimport { LEARNER_HELP_CENTER_URL } from '../../constants';\nimport Icon from '@openedx/paragon/dist/Icon';\nimport { Launch } from '@openedx/paragon/icons';\n\nconst HelpCenter: React.FC = () => {\n const { formatMessage } = useIntl();\n\n return (\n <div className=\"manage-help mt-5 pt-4 border-top\">\n <p className=\"manage-help__text text-gray-700 small mb-0\">\n {formatMessage(messages.helpLinkText)}\n {' '}\n <Link to={LEARNER_HELP_CENTER_URL} className=\"manage-help__link text-primary-500 d-inline-flex align-items-center\" target=\"_blank\" rel=\"noopener noreferrer\">\n {formatMessage(messages.helpLink)}\n <Icon src={Launch} className=\"icon mr-1\" data-testid=\"help-center-icon\" />\n </Link>\n </p>\n </div>\n );\n};\n\nexport default HelpCenter;\n"]}
@@ -0,0 +1,13 @@
1
+ declare const messages: {
2
+ helpLinkText: {
3
+ id: string;
4
+ defaultMessage: string;
5
+ description: string;
6
+ };
7
+ helpLink: {
8
+ id: string;
9
+ defaultMessage: string;
10
+ description: string;
11
+ };
12
+ };
13
+ export default messages;
@@ -0,0 +1,15 @@
1
+ import { defineMessages } from '@openedx/frontend-base';
2
+ const messages = defineMessages({
3
+ helpLinkText: {
4
+ id: 'helpLinkText',
5
+ defaultMessage: 'Need more help? Visit the',
6
+ description: 'Text before the help center link',
7
+ },
8
+ helpLink: {
9
+ id: 'helpLink',
10
+ defaultMessage: 'Learner Help Center',
11
+ description: 'Text for the help center link',
12
+ },
13
+ });
14
+ export default messages;
15
+ //# sourceMappingURL=messages.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/components/HelpCenter/messages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD,MAAM,QAAQ,GAAG,cAAc,CAAC;IAC9B,YAAY,EAAE;QACZ,EAAE,EAAE,cAAc;QAClB,cAAc,EAAE,2BAA2B;QAC3C,WAAW,EAAE,kCAAkC;KAChD;IACD,QAAQ,EAAE;QACR,EAAE,EAAE,UAAU;QACd,cAAc,EAAE,qBAAqB;QACrC,WAAW,EAAE,+BAA+B;KAC7C;CACF,CAAC,CAAC;AAEH,eAAe,QAAQ,CAAC","sourcesContent":["import { defineMessages } from '@openedx/frontend-base';\n\nconst messages = defineMessages({\n helpLinkText: {\n id: 'helpLinkText',\n defaultMessage: 'Need more help? Visit the',\n description: 'Text before the help center link',\n },\n helpLink: {\n id: 'helpLink',\n defaultMessage: 'Learner Help Center',\n description: 'Text for the help center link',\n },\n});\n\nexport default messages;\n"]}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const OrderHistory: React.FC;
3
+ export default OrderHistory;
@@ -0,0 +1,10 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { Container, Row, Col, } from '@openedx/paragon';
3
+ import OrderHistoryTabs from './OrderHistoryTabs/OrderHistoryTabs';
4
+ import OrderHistoryHeader from './OrderHistoryHeader';
5
+ import HelpCenter from '../HelpCenter/HelpCenter';
6
+ const OrderHistory = () => {
7
+ return (_jsxs(_Fragment, { children: [_jsxs(Container, { fluid: true, size: "xl", children: [_jsx(OrderHistoryHeader, {}), _jsx(Row, { children: _jsx(Col, { xs: 12, lg: 8, children: _jsx(OrderHistoryTabs, {}) }) })] }), _jsx(Container, { fluid: true, className: "mt-4 bg-light-300", children: _jsx(Container, { fluid: true, size: "xl", className: "mb-4", children: _jsx(Row, { children: _jsx(Col, { xs: 12, lg: 8, children: _jsx(HelpCenter, {}) }) }) }) })] }));
8
+ };
9
+ export default OrderHistory;
10
+ //# sourceMappingURL=OrderHistory.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"OrderHistory.js","sourceRoot":"","sources":["../../../src/components/OrderHistory/OrderHistory.tsx"],"names":[],"mappings":";AACA,OAAO,EACL,SAAS,EACT,GAAG,EACH,GAAG,GACJ,MAAM,kBAAkB,CAAC;AAC1B,OAAO,gBAAgB,MAAM,qCAAqC,CAAC;AACnE,OAAO,kBAAkB,MAAM,sBAAsB,CAAC;AACtD,OAAO,UAAU,MAAM,0BAA0B,CAAC;AAElD,MAAM,YAAY,GAAa,GAAG,EAAE;IAClC,OAAO,CACL,8BACE,MAAC,SAAS,IAAC,KAAK,QAAC,IAAI,EAAC,IAAI,aACxB,KAAC,kBAAkB,KAAG,EACtB,KAAC,GAAG,cACF,KAAC,GAAG,IAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,YAChB,KAAC,gBAAgB,KAAG,GAChB,GACF,IACI,EACZ,KAAC,SAAS,IAAC,KAAK,QAAC,SAAS,EAAC,mBAAmB,YAC5C,KAAC,SAAS,IAAC,KAAK,QAAC,IAAI,EAAC,IAAI,EAAC,SAAS,EAAC,MAAM,YACzC,KAAC,GAAG,cACF,KAAC,GAAG,IAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,YAChB,KAAC,UAAU,KAAG,GACV,GACF,GACI,GACF,IACX,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import React from 'react';\nimport {\n Container,\n Row,\n Col,\n} from '@openedx/paragon';\nimport OrderHistoryTabs from './OrderHistoryTabs/OrderHistoryTabs';\nimport OrderHistoryHeader from './OrderHistoryHeader';\nimport HelpCenter from '../HelpCenter/HelpCenter';\n\nconst OrderHistory: React.FC = () => {\n return (\n <>\n <Container fluid size=\"xl\">\n <OrderHistoryHeader />\n <Row>\n <Col xs={12} lg={8}>\n <OrderHistoryTabs />\n </Col>\n </Row>\n </Container>\n <Container fluid className=\"mt-4 bg-light-300\">\n <Container fluid size=\"xl\" className=\"mb-4\">\n <Row>\n <Col xs={12} lg={8}>\n <HelpCenter />\n </Col>\n </Row>\n </Container>\n </Container>\n </>\n );\n};\n\nexport default OrderHistory;\n"]}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const OrderHistoryHeader: React.FC;
3
+ export default OrderHistoryHeader;
@@ -0,0 +1,9 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useIntl } from '@openedx/frontend-base';
3
+ import messages from './messages';
4
+ const OrderHistoryHeader = () => {
5
+ const { formatMessage } = useIntl();
6
+ return (_jsxs("header", { className: "manage-header", children: [_jsx("h1", { className: "manage-header__title h1 text-primary-500 mb-2 mt-4 orderHistoryTitle", children: formatMessage(messages.orderHistoryTitle) }), _jsx("p", { className: "manage-header__subtitle text-gray-700 mb-2.5", children: formatMessage(messages.orderHistorySubTitle) })] }));
7
+ };
8
+ export default OrderHistoryHeader;
9
+ //# sourceMappingURL=OrderHistoryHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"OrderHistoryHeader.js","sourceRoot":"","sources":["../../../src/components/OrderHistory/OrderHistoryHeader.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEjD,OAAO,QAAQ,MAAM,YAAY,CAAC;AAElC,MAAM,kBAAkB,GAAa,GAAG,EAAE;IACxC,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IAEpC,OAAO,CACL,kBAAQ,SAAS,EAAC,eAAe,aAC/B,aAAI,SAAS,EAAC,sEAAsE,YACjF,aAAa,CAAC,QAAQ,CAAC,iBAAiB,CAAC,GACvC,EACL,YAAG,SAAS,EAAC,8CAA8C,YACxD,aAAa,CAAC,QAAQ,CAAC,oBAAoB,CAAC,GAC3C,IACG,CACV,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,kBAAkB,CAAC","sourcesContent":["import React from 'react';\nimport { useIntl } from '@openedx/frontend-base';\n\nimport messages from './messages';\n\nconst OrderHistoryHeader: React.FC = () => {\n const { formatMessage } = useIntl();\n\n return (\n <header className=\"manage-header\">\n <h1 className=\"manage-header__title h1 text-primary-500 mb-2 mt-4 orderHistoryTitle\">\n {formatMessage(messages.orderHistoryTitle)}\n </h1>\n <p className=\"manage-header__subtitle text-gray-700 mb-2.5\">\n {formatMessage(messages.orderHistorySubTitle)}\n </p>\n </header>\n );\n};\n\nexport default OrderHistoryHeader;\n"]}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const CoursePayments: React.FC;
3
+ export default CoursePayments;
@@ -0,0 +1,9 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useIntl } from '@openedx/frontend-base';
3
+ import messages from './messages';
4
+ const CoursePayments = () => {
5
+ const { formatMessage } = useIntl();
6
+ return (_jsxs("section", { className: "pt-4", "aria-labelledby": "course-payments-empty-heading", children: [_jsx("h2", { id: "course-payments-empty-heading", className: "h5 font-weight-bold text-primary-700 mb-1", children: formatMessage(messages.otherPurchasesTitle) }), _jsx("p", { className: "medium text-gray-700 mb-0", children: formatMessage(messages.coursePurchasesEmptyMessage) })] }));
7
+ };
8
+ export default CoursePayments;
9
+ //# sourceMappingURL=CoursePayments.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CoursePayments.js","sourceRoot":"","sources":["../../../../src/components/OrderHistory/OrderHistoryTabDetails/CoursePayments.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,QAAQ,MAAM,YAAY,CAAC;AAElC,MAAM,cAAc,GAAa,GAAG,EAAE;IACpC,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IAEpC,OAAO,CACL,mBAAS,SAAS,EAAC,MAAM,qBAAiB,+BAA+B,aACvE,aAAI,EAAE,EAAC,+BAA+B,EAAC,SAAS,EAAC,2CAA2C,YACzF,aAAa,CAAC,QAAQ,CAAC,mBAAmB,CAAC,GACzC,EACL,YAAG,SAAS,EAAC,2BAA2B,YACrC,aAAa,CAAC,QAAQ,CAAC,2BAA2B,CAAC,GAClD,IACI,CACX,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import React from 'react';\nimport { useIntl } from '@openedx/frontend-base';\nimport messages from './messages';\n\nconst CoursePayments: React.FC = () => {\n const { formatMessage } = useIntl();\n\n return (\n <section className=\"pt-4\" aria-labelledby=\"course-payments-empty-heading\">\n <h2 id=\"course-payments-empty-heading\" className=\"h5 font-weight-bold text-primary-700 mb-1\">\n {formatMessage(messages.otherPurchasesTitle)}\n </h2>\n <p className=\"medium text-gray-700 mb-0\">\n {formatMessage(messages.coursePurchasesEmptyMessage)}\n </p>\n </section>\n );\n};\n\nexport default CoursePayments;\n"]}
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const SubscriptionPayments: React.FC;
3
+ export default SubscriptionPayments;
@@ -0,0 +1,9 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { useIntl } from '@openedx/frontend-base';
3
+ import messages from './messages';
4
+ const SubscriptionPayments = () => {
5
+ const { formatMessage } = useIntl();
6
+ return (_jsx("section", { className: "pt-4", children: _jsx("p", { className: "medium text-gray-700 mb-0", children: formatMessage(messages.subscriptionPaymentsEmptyMessage) }) }));
7
+ };
8
+ export default SubscriptionPayments;
9
+ //# sourceMappingURL=SubscriptionPayments.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SubscriptionPayments.js","sourceRoot":"","sources":["../../../../src/components/OrderHistory/OrderHistoryTabDetails/SubscriptionPayments.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,QAAQ,MAAM,YAAY,CAAC;AAElC,MAAM,oBAAoB,GAAa,GAAG,EAAE;IAC1C,MAAM,EAAE,aAAa,EAAE,GAAG,OAAO,EAAE,CAAC;IAEpC,OAAO,CACL,kBAAS,SAAS,EAAC,MAAM,YACvB,YAAG,SAAS,EAAC,2BAA2B,YACrC,aAAa,CAAC,QAAQ,CAAC,gCAAgC,CAAC,GACvD,GACI,CACX,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,oBAAoB,CAAC","sourcesContent":["import React from 'react';\nimport { useIntl } from '@openedx/frontend-base';\nimport messages from './messages';\n\nconst SubscriptionPayments: React.FC = () => {\n const { formatMessage } = useIntl();\n\n return (\n <section className=\"pt-4\">\n <p className=\"medium text-gray-700 mb-0\">\n {formatMessage(messages.subscriptionPaymentsEmptyMessage)}\n </p>\n </section>\n );\n};\n\nexport default SubscriptionPayments;\n"]}
@@ -0,0 +1,18 @@
1
+ declare const messages: {
2
+ otherPurchasesTitle: {
3
+ id: string;
4
+ defaultMessage: string;
5
+ description: string;
6
+ };
7
+ coursePurchasesEmptyMessage: {
8
+ id: string;
9
+ defaultMessage: string;
10
+ description: string;
11
+ };
12
+ subscriptionPaymentsEmptyMessage: {
13
+ id: string;
14
+ defaultMessage: string;
15
+ description: string;
16
+ };
17
+ };
18
+ export default messages;
@@ -0,0 +1,20 @@
1
+ import { defineMessages } from '@openedx/frontend-base';
2
+ const messages = defineMessages({
3
+ otherPurchasesTitle: {
4
+ id: 'orderHistory.coursePayments.otherPurchasesTitle',
5
+ defaultMessage: 'Other purchases',
6
+ description: 'Heading above the list of other course purchases.',
7
+ },
8
+ coursePurchasesEmptyMessage: {
9
+ id: 'orderHistory.coursePayments.emptyMessage',
10
+ defaultMessage: 'Courses you purchased in the last 180 days will appear here. If possible, please retain receipts for your records.',
11
+ description: 'Message shown when there are no course purchases to display.',
12
+ },
13
+ subscriptionPaymentsEmptyMessage: {
14
+ id: 'orderHistory.subscriptionPayments.emptyMessage',
15
+ defaultMessage: 'Subscription payments you made in the last 180 days will appear here. If possible, please retain receipts for your records.',
16
+ description: 'Message shown when there are no subscription payments to display.',
17
+ },
18
+ });
19
+ export default messages;
20
+ //# sourceMappingURL=messages.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../../src/components/OrderHistory/OrderHistoryTabDetails/messages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD,MAAM,QAAQ,GAAG,cAAc,CAAC;IAC9B,mBAAmB,EAAE;QACnB,EAAE,EAAE,iDAAiD;QACrD,cAAc,EAAE,iBAAiB;QACjC,WAAW,EAAE,mDAAmD;KACjE;IACD,2BAA2B,EAAE;QAC3B,EAAE,EAAE,0CAA0C;QAC9C,cAAc,EAAE,oHAAoH;QACpI,WAAW,EAAE,8DAA8D;KAC5E;IACD,gCAAgC,EAAE;QAChC,EAAE,EAAE,gDAAgD;QACpD,cAAc,EAAE,6HAA6H;QAC7I,WAAW,EAAE,mEAAmE;KACjF;CACF,CAAC,CAAC;AAEH,eAAe,QAAQ,CAAC","sourcesContent":["import { defineMessages } from '@openedx/frontend-base';\n\nconst messages = defineMessages({\n otherPurchasesTitle: {\n id: 'orderHistory.coursePayments.otherPurchasesTitle',\n defaultMessage: 'Other purchases',\n description: 'Heading above the list of other course purchases.',\n },\n coursePurchasesEmptyMessage: {\n id: 'orderHistory.coursePayments.emptyMessage',\n defaultMessage: 'Courses you purchased in the last 180 days will appear here. If possible, please retain receipts for your records.',\n description: 'Message shown when there are no course purchases to display.',\n },\n subscriptionPaymentsEmptyMessage: {\n id: 'orderHistory.subscriptionPayments.emptyMessage',\n defaultMessage: 'Subscription payments you made in the last 180 days will appear here. If possible, please retain receipts for your records.',\n description: 'Message shown when there are no subscription payments to display.',\n },\n});\n\nexport default messages;\n"]}
@@ -0,0 +1,2 @@
1
+ declare const OrderHistoryTabs: () => import("react/jsx-runtime").JSX.Element;
2
+ export default OrderHistoryTabs;
@@ -0,0 +1,32 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { useMemo, useState, useCallback } from 'react';
3
+ import { Tabs, Tab } from '@openedx/paragon';
4
+ import SubscriptionPayments from '../OrderHistoryTabDetails/SubscriptionPayments';
5
+ import CoursePayments from '../OrderHistoryTabDetails/CoursePayments';
6
+ const OrderHistoryTabs = () => {
7
+ var _a;
8
+ const orderHistoryTabs = useMemo(() => {
9
+ const tabs = [
10
+ {
11
+ key: 'courses',
12
+ title: 'Subscription Payments',
13
+ panel: _jsx(SubscriptionPayments, {}),
14
+ },
15
+ {
16
+ key: 'programs',
17
+ title: 'Course Payments',
18
+ panel: _jsx(CoursePayments, {}),
19
+ },
20
+ ];
21
+ return tabs;
22
+ }, []);
23
+ const [activeTab, setActiveTab] = useState(orderHistoryTabs[0].key);
24
+ const handleTabSelect = useCallback((tabKey) => {
25
+ if (tabKey) {
26
+ setActiveTab(tabKey);
27
+ }
28
+ }, []);
29
+ return (_jsx(Tabs, { id: "order-history-tabs", defaultActiveKey: (_a = orderHistoryTabs[0]) === null || _a === void 0 ? void 0 : _a.key, activeKey: activeTab, onSelect: handleTabSelect, className: "mb-4", mountOnEnter: true, children: orderHistoryTabs.map(tab => (_jsx(Tab, { eventKey: tab.key, title: tab.title, children: tab.panel }, tab.key))) }));
30
+ };
31
+ export default OrderHistoryTabs;
32
+ //# sourceMappingURL=OrderHistoryTabs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"OrderHistoryTabs.js","sourceRoot":"","sources":["../../../../src/components/OrderHistory/OrderHistoryTabs/OrderHistoryTabs.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAC9D,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,kBAAkB,CAAC;AAC7C,OAAO,oBAAoB,MAAM,gDAAgD,CAAC;AAClF,OAAO,cAAc,MAAM,0CAA0C,CAAC;AAEtE,MAAM,gBAAgB,GAAG,GAAG,EAAE;;IAC5B,MAAM,gBAAgB,GAAG,OAAO,CAAC,GAAG,EAAE;QACpC,MAAM,IAAI,GAAG;YACX;gBACE,GAAG,EAAE,SAAS;gBACd,KAAK,EAAE,uBAAuB;gBAC9B,KAAK,EAAE,KAAC,oBAAoB,KAAG;aAChC;YACD;gBACE,GAAG,EAAE,UAAU;gBACf,KAAK,EAAE,iBAAiB;gBACxB,KAAK,EAAE,KAAC,cAAc,KAAG;aAC1B;SACF,CAAC;QAEF,OAAO,IAAI,CAAC;IACd,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC,GAAG,QAAQ,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;IACpE,MAAM,eAAe,GAAG,WAAW,CAAC,CAAC,MAAM,EAAE,EAAE;QAC7C,IAAI,MAAM,EAAE,CAAC;YACX,YAAY,CAAC,MAAM,CAAC,CAAC;QACvB,CAAC;IACH,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACL,KAAC,IAAI,IACH,EAAE,EAAC,oBAAoB,EACvB,gBAAgB,EAAE,MAAA,gBAAgB,CAAC,CAAC,CAAC,0CAAE,GAAG,EAC1C,SAAS,EAAE,SAAS,EACpB,QAAQ,EAAE,eAAe,EACzB,SAAS,EAAC,MAAM,EAChB,YAAY,kBAEX,gBAAgB,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,CAC3B,KAAC,GAAG,IAAC,QAAQ,EAAE,GAAG,CAAC,GAAG,EAAE,KAAK,EAAE,GAAG,CAAC,KAAK,YACrC,GAAG,CAAC,KAAK,IADmC,GAAG,CAAC,GAAG,CAEhD,CACP,CAAC,GACG,CACR,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,gBAAgB,CAAC","sourcesContent":["import React, { useMemo, useState, useCallback } from 'react';\nimport { Tabs, Tab } from '@openedx/paragon';\nimport SubscriptionPayments from '../OrderHistoryTabDetails/SubscriptionPayments';\nimport CoursePayments from '../OrderHistoryTabDetails/CoursePayments';\n\nconst OrderHistoryTabs = () => {\n const orderHistoryTabs = useMemo(() => {\n const tabs = [\n {\n key: 'courses',\n title: 'Subscription Payments',\n panel: <SubscriptionPayments />,\n },\n {\n key: 'programs',\n title: 'Course Payments',\n panel: <CoursePayments />,\n },\n ];\n\n return tabs;\n }, []);\n\n const [activeTab, setActiveTab] = useState(orderHistoryTabs[0].key);\n const handleTabSelect = useCallback((tabKey) => {\n if (tabKey) {\n setActiveTab(tabKey);\n }\n }, []);\n\n return (\n <Tabs\n id=\"order-history-tabs\"\n defaultActiveKey={orderHistoryTabs[0]?.key}\n activeKey={activeTab}\n onSelect={handleTabSelect}\n className=\"mb-4\"\n mountOnEnter\n >\n {orderHistoryTabs.map(tab => (\n <Tab eventKey={tab.key} title={tab.title} key={tab.key}>\n {tab.panel}\n </Tab>\n ))}\n </Tabs>\n );\n};\n\nexport default OrderHistoryTabs;\n"]}
@@ -0,0 +1,23 @@
1
+ declare const messages: {
2
+ orderHistoryTitle: {
3
+ id: string;
4
+ defaultMessage: string;
5
+ description: string;
6
+ };
7
+ orderHistorySubTitle: {
8
+ id: string;
9
+ defaultMessage: string;
10
+ description: string;
11
+ };
12
+ subscriptionPaymentsTab: {
13
+ id: string;
14
+ defaultMessage: string;
15
+ description: string;
16
+ };
17
+ coursePaymentsTab: {
18
+ id: string;
19
+ defaultMessage: string;
20
+ description: string;
21
+ };
22
+ };
23
+ export default messages;
@@ -0,0 +1,25 @@
1
+ import { defineMessages } from '@openedx/frontend-base';
2
+ const messages = defineMessages({
3
+ orderHistoryTitle: {
4
+ id: 'orderHistoryTitle',
5
+ defaultMessage: 'Order History',
6
+ description: 'Heading for order history',
7
+ },
8
+ orderHistorySubTitle: {
9
+ id: 'orderHistorySubTitle',
10
+ defaultMessage: 'View previous purchases and manage your subscription. ',
11
+ description: 'Page subtitle under Order History',
12
+ },
13
+ subscriptionPaymentsTab: {
14
+ id: 'subscriptionPaymentsTab',
15
+ defaultMessage: 'Subscription payments',
16
+ description: 'Subscription payments tab label',
17
+ },
18
+ coursePaymentsTab: {
19
+ id: 'coursePaymentsTab',
20
+ defaultMessage: 'Course payments',
21
+ description: 'Course payments tab label',
22
+ }
23
+ });
24
+ export default messages;
25
+ //# sourceMappingURL=messages.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"messages.js","sourceRoot":"","sources":["../../../src/components/OrderHistory/messages.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAExD,MAAM,QAAQ,GAAG,cAAc,CAAC;IAC9B,iBAAiB,EAAE;QACjB,EAAE,EAAE,mBAAmB;QACvB,cAAc,EAAE,eAAe;QAC/B,WAAW,EAAE,2BAA2B;KACzC;IACD,oBAAoB,EAAE;QACpB,EAAE,EAAE,sBAAsB;QAC1B,cAAc,EAAE,wDAAwD;QACxE,WAAW,EAAE,mCAAmC;KACjD;IACD,uBAAuB,EAAE;QACvB,EAAE,EAAE,yBAAyB;QAC7B,cAAc,EAAE,uBAAuB;QACvC,WAAW,EAAE,iCAAiC;KAC/C;IACD,iBAAiB,EAAE;QACjB,EAAE,EAAE,mBAAmB;QACvB,cAAc,EAAE,iBAAiB;QACjC,WAAW,EAAE,2BAA2B;KACzC;CACF,CAAC,CAAC;AAEH,eAAe,QAAQ,CAAC","sourcesContent":["import { defineMessages } from '@openedx/frontend-base';\n\nconst messages = defineMessages({\n orderHistoryTitle: {\n id: 'orderHistoryTitle',\n defaultMessage: 'Order History',\n description: 'Heading for order history',\n },\n orderHistorySubTitle: {\n id: 'orderHistorySubTitle',\n defaultMessage: 'View previous purchases and manage your subscription. ',\n description: 'Page subtitle under Order History',\n },\n subscriptionPaymentsTab: {\n id: 'subscriptionPaymentsTab',\n defaultMessage: 'Subscription payments',\n description: 'Subscription payments tab label',\n },\n coursePaymentsTab: {\n id: 'coursePaymentsTab',\n defaultMessage: 'Course payments',\n description: 'Course payments tab label',\n }\n});\n\nexport default messages;\n"]}
package/dist/routes.js CHANGED
@@ -61,6 +61,33 @@ const routes = [
61
61
  },
62
62
  ],
63
63
  },
64
+ {
65
+ id: 'org.openedx.frontend.route.template.main.aca-order-history',
66
+ path: 'aca-order-history',
67
+ loader: protectedLoader,
68
+ handle: {
69
+ roles: [acaCheckoutRole],
70
+ },
71
+ lazy() {
72
+ return __awaiter(this, void 0, void 0, function* () {
73
+ const module = yield import(
74
+ /* webpackChunkName: "template-main" */ './Main');
75
+ return { Component: module.default };
76
+ });
77
+ },
78
+ children: [
79
+ {
80
+ index: true,
81
+ lazy() {
82
+ return __awaiter(this, void 0, void 0, function* () {
83
+ const module = yield import(
84
+ /* webpackChunkName: "OrderHistory" */ './components/OrderHistory/OrderHistory');
85
+ return { Component: module.default };
86
+ });
87
+ },
88
+ },
89
+ ],
90
+ },
64
91
  ];
65
92
  export default routes;
66
93
  //# sourceMappingURL=routes.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"routes.js","sourceRoot":"","sources":["../src/routes.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EACL,mBAAmB,GACpB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAE9C;;;;;;;;GAQG;AACH,MAAM,uBAAuB,GAAG,CAAC,UAAkB,EAAW,EAAE;IAC9D,MAAM,EAAE,QAAQ,EAAE,GAAG,IAAI,GAAG,CAAC,UAAU,CAAC,CAAC;IACzC,OAAO,QAAQ,KAAK,WAAW;WAC1B,QAAQ,KAAK,WAAW;WACxB,QAAQ,CAAC,QAAQ,CAAC,iBAAiB,CAAC;WACpC,QAAQ,CAAC,QAAQ,CAAC,iBAAiB,CAAC;WACpC,QAAQ,CAAC,QAAQ,CAAC,YAAY,CAAC;WAC/B,QAAQ,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;AACtC,CAAC,CAAC;AAEF,MAAM,eAAe,GAAG,CAAO,IAAI,EAAE,EAAE;IACrC,IAAI,CAAC,uBAAuB,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,MAAM,mBAAmB,CAAC,IAAI,CAAC,CAAC;IAClC,CAAC;IAED,OAAO,IAAI,CAAC;AACd,CAAC,CAAA,CAAC;AAEF,MAAM,MAAM,GAAG;IACb;QACE,EAAE,EAAE,uDAAuD;QAC3D,IAAI,EAAE,cAAc;QACpB,MAAM,EAAE,eAAe;QACvB,MAAM,EAAE;YACN,KAAK,EAAE,CAAC,eAAe,CAAC;SACzB;QACK,IAAI;;gBACR,MAAM,MAAM,GAAG,MAAM,MAAM;gBACzB,uCAAuC,CAAC,QAAQ,CACjD,CAAC;gBACF,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,CAAC;YACvC,CAAC;SAAA;QACD,QAAQ,EAAE;YACR;gBACE,KAAK,EAAE,IAAI;gBACL,IAAI;;wBACR,MAAM,MAAM,GAAG,MAAM,MAAM;wBACzB,sCAAsC,CAAC,6BAA6B,CACrE,CAAC;wBACF,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,CAAC;oBACvC,CAAC;iBAAA;aACF;SACF;KACF;CACF,CAAC;AAEF,eAAe,MAAM,CAAC","sourcesContent":["import {\n authenticatedLoader,\n} from '@openedx/frontend-base';\n\nimport { acaCheckoutRole } from './constants';\n\n/**\n * LMS JWT cookies are host-bound to localhost:18000. On https://localhost or an\n * ngrok tunnel they are missing, so authenticatedLoader sends you to LMS login\n * → usually /dashboard. DEV_MOCK_SESSION covers Viax tokens for that case.\n *\n * Do not use getAppConfig() here — app configs are registered after the router\n * is created, so the first loader pass often sees an empty config and still\n * redirects. Use the request hostname instead.\n */\nconst shouldSkipLmsCookieAuth = (requestUrl: string): boolean => {\n const { hostname } = new URL(requestUrl);\n return hostname === 'localhost'\n || hostname === '127.0.0.1'\n || hostname.endsWith('.ngrok-free.app')\n || hostname.endsWith('.ngrok-free.dev')\n || hostname.endsWith('.ngrok.app')\n || hostname.endsWith('.ngrok.io');\n};\n\nconst protectedLoader = async (args) => {\n if (!shouldSkipLmsCookieAuth(args.request.url)) {\n await authenticatedLoader(args);\n }\n\n return null;\n};\n\nconst routes = [\n {\n id: 'org.openedx.frontend.route.template.main.aca-checkout',\n path: 'aca-checkout',\n loader: protectedLoader,\n handle: {\n roles: [acaCheckoutRole],\n },\n async lazy() {\n const module = await import(\n /* webpackChunkName: \"template-main\" */ './Main'\n );\n return { Component: module.default };\n },\n children: [\n {\n index: true,\n async lazy() {\n const module = await import(\n /* webpackChunkName: \"CheckoutPage\" */ './checkoutPage/CheckoutPage'\n );\n return { Component: module.default };\n },\n },\n ],\n },\n];\n\nexport default routes;\n"]}
1
+ {"version":3,"file":"routes.js","sourceRoot":"","sources":["../src/routes.tsx"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EACL,mBAAmB,GACpB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAE9C;;;;;;;;GAQG;AACH,MAAM,uBAAuB,GAAG,CAAC,UAAkB,EAAW,EAAE;IAC9D,MAAM,EAAE,QAAQ,EAAE,GAAG,IAAI,GAAG,CAAC,UAAU,CAAC,CAAC;IACzC,OAAO,QAAQ,KAAK,WAAW;WAC1B,QAAQ,KAAK,WAAW;WACxB,QAAQ,CAAC,QAAQ,CAAC,iBAAiB,CAAC;WACpC,QAAQ,CAAC,QAAQ,CAAC,iBAAiB,CAAC;WACpC,QAAQ,CAAC,QAAQ,CAAC,YAAY,CAAC;WAC/B,QAAQ,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;AACtC,CAAC,CAAC;AAEF,MAAM,eAAe,GAAG,CAAO,IAAI,EAAE,EAAE;IACrC,IAAI,CAAC,uBAAuB,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;QAC/C,MAAM,mBAAmB,CAAC,IAAI,CAAC,CAAC;IAClC,CAAC;IAED,OAAO,IAAI,CAAC;AACd,CAAC,CAAA,CAAC;AAEF,MAAM,MAAM,GAAG;IACb;QACE,EAAE,EAAE,uDAAuD;QAC3D,IAAI,EAAE,cAAc;QACpB,MAAM,EAAE,eAAe;QACvB,MAAM,EAAE;YACN,KAAK,EAAE,CAAC,eAAe,CAAC;SACzB;QACK,IAAI;;gBACR,MAAM,MAAM,GAAG,MAAM,MAAM;gBACzB,uCAAuC,CAAC,QAAQ,CACjD,CAAC;gBACF,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,CAAC;YACvC,CAAC;SAAA;QACD,QAAQ,EAAE;YACR;gBACE,KAAK,EAAE,IAAI;gBACL,IAAI;;wBACR,MAAM,MAAM,GAAG,MAAM,MAAM;wBACzB,sCAAsC,CAAC,6BAA6B,CACrE,CAAC;wBACF,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,CAAC;oBACvC,CAAC;iBAAA;aACF;SACF;KACF;IACD;QACE,EAAE,EAAE,4DAA4D;QAChE,IAAI,EAAE,mBAAmB;QACzB,MAAM,EAAE,eAAe;QACvB,MAAM,EAAE;YACN,KAAK,EAAE,CAAC,eAAe,CAAC;SACzB;QACK,IAAI;;gBACR,MAAM,MAAM,GAAG,MAAM,MAAM;gBACzB,uCAAuC,CAAC,QAAQ,CACjD,CAAC;gBACF,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,CAAC;YACvC,CAAC;SAAA;QACD,QAAQ,EAAE;YACR;gBACE,KAAK,EAAE,IAAI;gBACL,IAAI;;wBACR,MAAM,MAAM,GAAG,MAAM,MAAM;wBACzB,sCAAsC,CAAC,wCAAwC,CAChF,CAAC;wBACF,OAAO,EAAE,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,CAAC;oBACvC,CAAC;iBAAA;aACF;SACF;KACF;CACF,CAAC;AAEF,eAAe,MAAM,CAAC","sourcesContent":["import {\n authenticatedLoader,\n} from '@openedx/frontend-base';\n\nimport { acaCheckoutRole } from './constants';\n\n/**\n * LMS JWT cookies are host-bound to localhost:18000. On https://localhost or an\n * ngrok tunnel they are missing, so authenticatedLoader sends you to LMS login\n * → usually /dashboard. DEV_MOCK_SESSION covers Viax tokens for that case.\n *\n * Do not use getAppConfig() here — app configs are registered after the router\n * is created, so the first loader pass often sees an empty config and still\n * redirects. Use the request hostname instead.\n */\nconst shouldSkipLmsCookieAuth = (requestUrl: string): boolean => {\n const { hostname } = new URL(requestUrl);\n return hostname === 'localhost'\n || hostname === '127.0.0.1'\n || hostname.endsWith('.ngrok-free.app')\n || hostname.endsWith('.ngrok-free.dev')\n || hostname.endsWith('.ngrok.app')\n || hostname.endsWith('.ngrok.io');\n};\n\nconst protectedLoader = async (args) => {\n if (!shouldSkipLmsCookieAuth(args.request.url)) {\n await authenticatedLoader(args);\n }\n\n return null;\n};\n\nconst routes = [\n {\n id: 'org.openedx.frontend.route.template.main.aca-checkout',\n path: 'aca-checkout',\n loader: protectedLoader,\n handle: {\n roles: [acaCheckoutRole],\n },\n async lazy() {\n const module = await import(\n /* webpackChunkName: \"template-main\" */ './Main'\n );\n return { Component: module.default };\n },\n children: [\n {\n index: true,\n async lazy() {\n const module = await import(\n /* webpackChunkName: \"CheckoutPage\" */ './checkoutPage/CheckoutPage'\n );\n return { Component: module.default };\n },\n },\n ],\n },\n {\n id: 'org.openedx.frontend.route.template.main.aca-order-history',\n path: 'aca-order-history',\n loader: protectedLoader,\n handle: {\n roles: [acaCheckoutRole],\n },\n async lazy() {\n const module = await import(\n /* webpackChunkName: \"template-main\" */ './Main'\n );\n return { Component: module.default };\n },\n children: [\n {\n index: true,\n async lazy() {\n const module = await import(\n /* webpackChunkName: \"OrderHistory\" */ './components/OrderHistory/OrderHistory'\n );\n return { Component: module.default };\n },\n },\n ],\n },\n];\n\nexport default routes;\n"]}
package/dist/style.scss CHANGED
@@ -18,4 +18,5 @@
18
18
  @use "./styles/components/alacarteNotice.scss";
19
19
  @use "./styles/components/alacarteConfirmation.scss";
20
20
  @use "./styles/components/orderBlockedModal.scss";
21
+ @use "./styles/components/orderHistory.scss";
21
22
  @use "./styles/components/alacarteDebugPanel.scss"; // TEMPORARY — remove alongside AlacarteDebugPanel.
@@ -0,0 +1,3 @@
1
+ .orderHistoryTitle {
2
+ font-weight: 800;
3
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edx/frontend-app-alacarte-checkout",
3
- "version": "1.30.0",
3
+ "version": "1.31.0",
4
4
  "description": "alacarte Checkout Frontend application",
5
5
  "repository": {
6
6
  "type": "git",