Skip to content

Commit

Permalink
adding CSS changes (#1363)
Browse files Browse the repository at this point in the history
Co-authored-by: NabeelAyubee <[email protected]>
  • Loading branch information
nabeelmd-eGov and NabeelAyubee authored Sep 6, 2024
1 parent 28cae30 commit 88b1d15
Show file tree
Hide file tree
Showing 22 changed files with 85 additions and 47 deletions.
2 changes: 1 addition & 1 deletion micro-ui/web/micro-ui-internals/example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"@egovernments/digit-ui-module-open-payment":"0.0.1",
"@egovernments/digit-ui-module-engagement": "1.5.20",
"@egovernments/digit-ui-components": "0.0.2-beta.31",
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"@egovernments/digit-ui-module-sandbox": "0.0.1",
"http-proxy-middleware": "^1.0.5",
"react": "17.0.2",
Expand Down
2 changes: 1 addition & 1 deletion micro-ui/web/micro-ui-internals/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"lodash": "4.17.21",
"microbundle-crl": "0.13.11",
"@egovernments/digit-ui-components": "0.0.2-beta.31",
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"react": "17.0.2",
"react-dom": "17.0.2",
"react-hook-form": "6.15.8",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -644,7 +644,7 @@ input[type="number"] {
.citizen-form-wrapper {
width: calc(100% - 219px);
display: flex;
justify-content: center;
justify-content: flex-start;
margin-top: 1rem;
padding-left: 16px;
padding-right: 16px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -315,3 +315,21 @@
justify-content: center;
}
}
.main.center-container.citizen-home-container {
z-index: 100;
justify-content: flex-start;
}
.SideBarStatic {
z-index: 10;
height: 100vh;
}
.citizen-home-footer {
position: absolute;
bottom: 0;
}
.citizen-form-wrapper {
justify-content: flex-start;
.citizen-card-input.citizen-card-input--front {
margin-bottom: 0;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
},
"dependencies": {
"@egovernments/digit-ui-components": "0.0.2-beta.31",
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"react": "17.0.2",
"react-dom": "17.0.2",
"react-i18next": "11.16.2",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import {
BackLink,
CitizenHomeCard,
CitizenInfoLabel,
Loader,
} from "@egovernments/digit-ui-components";
import { CustomSVG } from "@egovernments/digit-ui-components";
} from "@egovernments/digit-ui-react-components";

import { BackLink, CustomSVG } from "@egovernments/digit-ui-components";

import React, { Fragment } from "react";
import { useTranslation } from "react-i18next";
Expand Down Expand Up @@ -97,7 +97,7 @@ const CitizenHome = ({
<div className="citizen-all-services-wrapper">
{location.pathname.includes(
"sanitation-ui/citizen/all-services"
) ? null : (
) || (location.pathname.includes("sandbox-ui") && location.pathname.includes("all-services")) ? null : (
<BackLink />
)}
<div className="citizenAllServiceGrid">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,24 +183,24 @@ const StaticCitizenSideBar = ({ linkData, islinkDataLoading }) => {
<React.Fragment>
{t("CS_COMMON_HELPLINE")}
<div className="telephone" style={{ marginTop: "-10%" }}>
{storeData?.tenants.map((i) => {
{storeData?.tenants?.map((i) => {
i.code === tenantId ? (
<div className="link">
<a href={`tel:${storeData?.tenants[i].contactNumber}`}>
{storeData?.tenants[i].contactNumber}
<a href={`tel:${storeData?.tenants?.[i].contactNumber}`}>
{storeData?.tenants?.[i].contactNumber}
</a>
</div>
) : (
<div className="link">
<a href={`tel:${storeData?.tenants[0].contactNumber}`}>
{storeData?.tenants[0].contactNumber}
<a href={`tel:${storeData?.tenants?.[0].contactNumber}`}>
{storeData?.tenants?.[0].contactNumber}
</a>
</div>
);
})}
<div className="link">
<a href={`tel:${storeData?.tenants[0].contactNumber}`}>
{storeData?.tenants[0].contactNumber}
<a href={`tel:${storeData?.tenants?.[0].contactNumber}`}>
{storeData?.tenants?.[0].contactNumber}
</a>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { BackLink, CardHeader, CardLabelError, PageBasedInput, SearchOnRadioButtons } from "@egovernments/digit-ui-components";
import { BackLink } from "@egovernments/digit-ui-components";
import { CardHeader, CardLabelError, PageBasedInput, SearchOnRadioButtons } from "@egovernments/digit-ui-react-components";
import React, { useMemo, useState } from "react";
import { useTranslation } from "react-i18next";
import { useHistory, useLocation } from "react-router-dom";
Expand Down Expand Up @@ -83,6 +84,7 @@ const { data: subTenants, refetch, isLoading: isLoadingSubTenants } = requestCri
const redirectBackTo = location.state?.redirectBackTo;
if(window?.globalPath === "sandbox-ui"){
history.push(`/${window?.contextPath}/citizen/all-services`);
return;
}
if (redirectBackTo) {
history.replace(redirectBackTo);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
PTIcon,
Loader,
WhatsNewCard,
} from "@egovernments/digit-ui-components";
} from "@egovernments/digit-ui-react-components";
import React from "react";
import { useTranslation } from "react-i18next";
import { useHistory } from "react-router-dom";
Expand Down Expand Up @@ -57,8 +57,8 @@ const Home = () => {
if (redirectURL) {
history.push(`/${window?.contextPath}/citizen/${redirectURL}`);
}
/* fix for sanitation ui */
if (window?.location?.href?.includes?.("sanitation-ui")|| window?.location?.href?.includes?.("sandbox-ui")) {
/* fix for sanitation ui & sandbox*/
if (window?.location?.href?.includes?.("sanitation-ui") || window?.location?.href?.includes?.("sandbox-ui")) {
history.push(`/${window?.contextPath}/citizen/all-services`);
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { AppContainer, BackLink ,Toast} from "@egovernments/digit-ui-components";
import { AppContainer, BackLink, Toast } from "@egovernments/digit-ui-components";
import React, { useEffect, useMemo, useState } from "react";
import { useTranslation } from "react-i18next";
import { Route, Switch, useHistory, useLocation, useRouteMatch } from "react-router-dom";
Expand Down Expand Up @@ -233,7 +233,7 @@ const Login = ({ stateCode, isUserRegistered = true }) => {
<div className="citizen-form-wrapper">
<Switch>
<AppContainer>
<BackLink />
{location.pathname.includes("login") ? null : <BackLink />}
<Route path={`${path}`} exact>
<SelectMobileNumber
onSelect={selectMobileNumber}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ const Home = ({
mobileView={mobileView}
handleUserDropdownSelection={handleUserDropdownSelection}
logoUrl={logoUrl}
showSidebar={true}
showSidebar={false}
linkData={linkData}
islinkDataLoading={islinkDataLoading}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"react-router-dom": "5.3.0"
},
"dependencies": {
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"@egovernments/digit-ui-module-utilities":"1.0.1-beta.39",
"jsonpath": "^1.1.1",
"react": "17.0.2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"react-router-dom": "5.3.0"
},
"dependencies": {
"@egovernments/digit-ui-react-components": "1.8.2-beta.4",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"@egovernments/digit-ui-components": "0.0.2-beta.18",
"react": "17.0.2",
"react-dom": "17.0.2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"react-router-dom": "5.3.0"
},
"dependencies": {
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"lodash.merge": "^4.6.2",
"react": "17.0.2",
"react-dom": "17.0.2",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"react-router-dom": "5.3.0"
},
"dependencies": {
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"@egovernments/digit-ui-components": "0.0.2-beta.18",
"react": "17.0.2",
"react-date-range": "^1.4.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ export const SandboxModule = ({ stateCode, userType, tenants }) => {
const { path, url } = useRouteMatch();
const tenantId = Digit.ULBService.getCurrentTenantId();
const moduleCode = ["sandbox"];
const MDMSmoduleCode = [`rainmaker-mdms`, `rainmaker-workbench`, `rainmaker-schema`];
const language = Digit.StoreData.getCurrentLanguage();
const { isLoading, data: store } = Digit.Services.useStore({
stateCode,
Expand All @@ -18,7 +19,12 @@ export const SandboxModule = ({ stateCode, userType, tenants }) => {
modulePrefix: "digit",
});

if (isLoading) {
const { isLoading: isMDMSLoading, data: MDMSstore } = Digit.Services.useStore({
stateCode,
MDMSmoduleCode,
language,
});
if (isLoading && isMDMSLoading) {
return <Loader />;
}
return <EmployeeApp path={path} stateCode={stateCode} userType={userType} tenants={tenants} />;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ const ModuleMasterTable = () => {
onError: (error, variables) => {
console.log(error);
setShowPopUp(false);
setShowToast({ key: "error", label: error, isError: true });
setShowToast({ key: "error", label: check ? "MANNUAL_MASTER_SETUP_ERROR" : "DEFAULT_MASTER_SETUP_ERROR", isError: true });
},
onSuccess: async (data) => {
setShowPopUp(false);
setShowToast({ key: "success", label: "SUCCESS" });
setShowToast({ key: "success", label: check ? "MANNUAL_MASTER_SETUP_SUCCESS" : "DEFAULT_MASTER_SETUP_SUCCESS" });
},
}
);
Expand All @@ -68,8 +68,8 @@ const ModuleMasterTable = () => {
type={"default"}
className={"masterHandlerPopup"}
footerclassName={"masterHandlerPopUpFooter"}
heading={t("ES_CAMPAIGN_UPLOAD_BOUNDARY_DATA_MODAL_HEADER")}
children={[<div>{t("ES_CAMPAIGN_UPLOAD_BOUNDARY_DATA_MODAL_TEXT")}</div>]}
heading={t("SANDBOX_SETUP_MASTER_MODAL_HEADER")}
children={[<div>{t("SANDBOX_SETUP_MASTER_MODAL_TEXT")}</div>]}
onOverlayClick={() => {}}
footerChildren={[
<Button
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,38 +7,35 @@ export const setupMasterConfig = {
module: "PGR",
active: true,
description: "COMPLAINT_MANAGEMENT_DESCRIPTION",
masterDescription: "COMPLAINT_MANAGEMENT_SETUP_MASTER_DESCRIPTION",
actionText: "SETUP_NOW",
features: [
{
id: 1,
name: "COMPLAINT_MANAGEMENT_REGISTRATION",
name: "COMPLAINT_MANAGEMENT_REGISTRATION_LOGIN_CREATION",
},
{
id: 2,
name: "COMPLAINT_MANAGEMENT_FEATURE_LOGIN_CREATION",
},
{
id: 3,
name: "COMPLAINT_MANAGEMENT_LODGING_FILE",
},
{
id: 4,
id: 3,
name: "COMPLAINT_MANAGEMENT_ASSIGNING_COMPLAINT",
},
{
id: 5,
id: 4,
name: "COMPLAINT_MANAGEMENT_RESOLVING_COMPLAINT",
},
{
id: 6,
id: 5,
name: "COMPLAINT_MANAGEMENT_MANAGE_COMPLAINTS",
},
{
id: 7,
id: 6,
name: "COMPLAINT_MANAGEMENT_TRACK_COMPLAINTS",
},
{
id: 8,
id: 7,
name: "COMPLAINT_MANAGEMENT_DASHBOARD_REPORTS",
},
],
Expand All @@ -48,6 +45,7 @@ export const setupMasterConfig = {
module: "HCM",
active: true,
description: "HCM_DESCRIPTION",
masterDescription: "HCM_SETUP_MASTER_DESCRIPTION",
actionText: "SETUP_NOW",
features: [
{
Expand All @@ -61,15 +59,20 @@ export const setupMasterConfig = {
module: "HRMS",
active: true,
description: "HRMS_DESCRIPTION",
masterDescription: "HRMS_SETUP_MASTER_DESCRIPTION",
actionText: "SETUP_NOW",
features: [
{
id: 1,
name: "HRMS_REGISTRATION",
name: "HRMS_REGISTRATION_LOGIN_CREATION",
},
{
id: 2,
name: "HRMS_LOGIN_CREATION",
name: "HRMS_MODIFY_EMPLOYEE",
},
{
id: 3,
name: "HRMS_VIEW_EMPLOYEE",
},
],
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"dependencies": {
"@cyntler/react-doc-viewer": "1.10.3",
"@egovernments/digit-ui-components": "0.0.2-beta.18",
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"axios": "^1.7.2",
"react": "17.0.2",
"react-date-range": "^1.4.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
},
"dependencies": {
"@egovernments/digit-ui-components": "0.0.2-beta.18",
"@egovernments/digit-ui-react-components": "1.8.2-beta.12",
"@egovernments/digit-ui-react-components": "1.8.2-beta.13",
"@rjsf/core": "5.10.0",
"@rjsf/utils": "5.10.0",
"@rjsf/validator-ajv8": "5.10.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@egovernments/digit-ui-react-components",
"version": "1.8.2-beta.12",
"version": "1.8.2-beta.13",
"license": "MIT",
"main": "dist/index.js",
"module": "dist/index.modern.js",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useReducer } from "react"
import React, { useEffect, useReducer } from "react"
import RadioButtons from "../atoms/RadioButtons"
import TextInput from "../atoms/TextInput"
import { SearchIconSvg } from "../atoms/svgindex"
Expand All @@ -9,9 +9,18 @@ const SearchOnRadioButtons = ({options,optionsKey,additionalWrapperClass,onSelec
switch (action.type){
case "filter":
return action.options.filter(i => i[optionsKey].toUpperCase().includes(action.payload.toUpperCase()))
default:
return state;

}
}

useEffect(()=>{
if(options){
optionsDispatch({type: "filter", payload: "", options})
}
},[options])

const [ filteredOptions, optionsDispatch ] = useReducer(optionsReducer, options)

function defaultSearchQueryChange(e){
Expand Down

0 comments on commit 88b1d15

Please sign in to comment.