@djb25/digit-ui-module-common 1.0.6 → 1.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +29 -1
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +29 -1
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -2868,6 +2868,8 @@ const CitizenPayment = _ref => {
|
|
|
2868
2868
|
moduleCode = _ref.moduleCode;
|
|
2869
2869
|
const _useRouteMatch = useRouteMatch(),
|
|
2870
2870
|
currentPath = _useRouteMatch.path;
|
|
2871
|
+
const _useLocation = useLocation(),
|
|
2872
|
+
routerState = _useLocation.state;
|
|
2871
2873
|
const commonProps = {
|
|
2872
2874
|
stateCode,
|
|
2873
2875
|
cityCode,
|
|
@@ -2906,7 +2908,33 @@ const CitizenPayment = _ref => {
|
|
|
2906
2908
|
show: pathname.includes("/failure")
|
|
2907
2909
|
}];
|
|
2908
2910
|
const getDynamicBreadcrumbs = () => {
|
|
2909
|
-
|
|
2911
|
+
let activeCrumbs = crumbs.filter(crumb => crumb.show);
|
|
2912
|
+
const isWNS = pathname.includes("/WS") || pathname.includes("/SW") || window.location.search.includes("workflow=WNS");
|
|
2913
|
+
if (isWNS) {
|
|
2914
|
+
activeCrumbs.splice(1, 0, {
|
|
2915
|
+
path: "/digit-ui/citizen/ws-home",
|
|
2916
|
+
label: t("ES_TITLE_WATER_AND_SEWERAGE"),
|
|
2917
|
+
show: true
|
|
2918
|
+
});
|
|
2919
|
+
if (routerState !== null && routerState !== void 0 && routerState.fromMyApplications || routerState !== null && routerState !== void 0 && routerState.fromApplicationDetails) {
|
|
2920
|
+
activeCrumbs.splice(2, 0, {
|
|
2921
|
+
path: "/digit-ui/citizen/ws/my-applications",
|
|
2922
|
+
label: t("CS_HOME_MY_APPLICATIONS"),
|
|
2923
|
+
show: true
|
|
2924
|
+
});
|
|
2925
|
+
}
|
|
2926
|
+
if (routerState !== null && routerState !== void 0 && routerState.fromApplicationDetails) {
|
|
2927
|
+
activeCrumbs.splice(3, 0, {
|
|
2928
|
+
label: t("WS_APPLICATION_DETAILS_HEADER"),
|
|
2929
|
+
show: true,
|
|
2930
|
+
onClick: () => window.history.back()
|
|
2931
|
+
});
|
|
2932
|
+
}
|
|
2933
|
+
}
|
|
2934
|
+
if (activeCrumbs.length > 0) {
|
|
2935
|
+
activeCrumbs[activeCrumbs.length - 1].path = "";
|
|
2936
|
+
}
|
|
2937
|
+
return activeCrumbs;
|
|
2910
2938
|
};
|
|
2911
2939
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Switch, null, /*#__PURE__*/React.createElement(AppContainer, null, /*#__PURE__*/React.createElement("div", {
|
|
2912
2940
|
className: "ground-container employee-app-container form-container"
|