Skip to content

Commit

Permalink
Sc 23205 (#1139)
Browse files Browse the repository at this point in the history
* Display table border

* Increases member detail modal width, changes overflow to auto

* Increases padding below vasp details table

* Fixes text overflow in table
  • Loading branch information
daniellemaxwell authored Jan 10, 2024
1 parent b8c9e1b commit 2e8e910
Show file tree
Hide file tree
Showing 12 changed files with 7 additions and 29 deletions.
1 change: 0 additions & 1 deletion web/gds-user-ui/src/application/store/stepper.slice.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ const stepperSlice: any = createSlice({
if (state?.steps?.length > 1) {
state?.steps?.map((step: any) => {
if (step.key === payload.step) {
console.log('payload.status', payload.status);
step.status = payload.status;
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ interface KycThresholdRowProps {
| undefined;
}
const KycThresholdRow = (data: KycThresholdRowProps) => {
console.log('[] KycThresholdRowProps data', data);
const { kyc_threshold, kyc_threshold_currency, has_required_regulatory_program } =
data?.data as any;
const shouldShowKycThreshold = kyc_threshold || +kyc_threshold !== 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ const TrixoReview: React.FC = () => {

const [trixoData, setTrixoData] = useState([]);

console.log('[] TRIXO FORM REVIEW PAGE', certificateStep?.form?.trixo);

const hasErrors = certificateStep?.errors;

useEffect(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ interface TrixoReviewProps {
data?: any;
}
function TrixoReviewDataTable({ data }: TrixoReviewProps) {
console.log('[] TRIXO FORM DATA TABLE PAGE', data);
const getConductsCustomerKYC = (conductsCustomerKYC: boolean) => {
return conductsCustomerKYC ? t`Yes` : t`No`;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,12 @@ export const useSafeDisableIconButton = (permission: TUserPermission, condition:

useEffect(() => {
let once = false;
console.log('[useSafeDisableIconButton] mount');
if (!once) {
once = true;
const d = !isCurrentUser(condition) && hasPermission(permission);
setIsDisabled(d);
}
return () => {
console.log('useSafeDisableIconButton: unmount');
once = true;
};
}, [permission, condition]);
Expand Down
1 change: 0 additions & 1 deletion web/gds-user-ui/src/components/NameIdentifier/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ const NameIdentifier: React.ForwardRefExoticComponent<

// set default value for the first legal name
useEffect(() => {
console.log('[] 1 name', name);
if (type === 'legal' && fields.length === 1) {
const value = `${name}[0].legal_person_name` as string;
setValue(`${value}`, getOrganizationName || '');
Expand Down
15 changes: 4 additions & 11 deletions web/gds-user-ui/src/components/OrganizationProfile/TrisaDetail.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,16 @@ const TrisaDetail: React.FC<TrisaDetailProps> = ({ data, type }) => {
color={'#252733'}
fontSize={18}
p={4}
mb={10}
mt={10}
my={10}
px={7}>
<Stack width={'100%'}>
<Heading as={'h1'} fontSize={19} pb={7} pt={4}>
<Heading as={'h1'} fontSize={19} pt={4} mb={2}>
{t`Your TRISA ${type} Details`}
</Heading>
<Stack fontSize={18}>
<Stack fontSize={18} pb={4} overflow={'auto'}>
<Table
sx={{
thead: { fontWeight: 'bold' },
Tr: {
borderStyle: 'hidden'
}
}}>
<Thead
sx={{
Expand All @@ -60,7 +56,7 @@ const TrisaDetail: React.FC<TrisaDetailProps> = ({ data, type }) => {
}
}}>
<Tr>
<Td pt={'1rem !important'}>
<Td>
<Trans id="ID">ID</Trans>
</Td>
<Td>
Expand All @@ -80,9 +76,6 @@ const TrisaDetail: React.FC<TrisaDetailProps> = ({ data, type }) => {
<Tbody
sx={{
'*': {
fontSize: '1rem',

'td:first-child': {},
td: {
paddingInlineStart: 0.5
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const TrisaImplementation: React.FC<TrisaImplementationProps> = ({ data }) => {
mb={7}
px={7}>
<Stack width={'100%'}>
<Heading as={'h1'} fontSize={19} pb={2} pt={4}>
<Heading as={'h1'} fontSize={19} pb={2} pt={2}>
<Trans id="TRISA Implementations">TRISA Implementations</Trans>
</Heading>
<Text pb={7}>
Expand Down
7 changes: 0 additions & 7 deletions web/gds-user-ui/src/hooks/useCertificateStepper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ import { getStepNumber } from 'components/BasicDetailsForm/util';
const useCertificateStepper = () => {
const dispatch = useDispatch();
const currentStep: number = useSelector(getCurrentStep);
console.log('[useCertificateStepper] currentStep', currentStep);

const removeMissingFields = (steps: TStep[]) => {
return steps.map((step: TStep) => {
Expand All @@ -50,16 +49,13 @@ const useCertificateStepper = () => {
};

const nextStep = (data?: any) => {
console.log('[nextStep] data', data);
const errorFields = data?.errors;
const stepNumber = getStepNumber(data?.step) || currentStep;
console.log('[nextStep] errorFields', errorFields);

if (data && errorFields && Object.keys(errorFields).length > 0) {
dispatch(setStepStatus({ step: stepNumber, status: LSTATUS.ERROR }));
} else {
// setInitialState(data?.form);
console.log('[nextStep] setStepStatus', stepNumber);
dispatch(setStepStatus({ step: stepNumber, status: LSTATUS.COMPLETE }));
}
if (currentStep === 5) {
Expand Down Expand Up @@ -122,7 +118,6 @@ const useCertificateStepper = () => {
mainnetSubmitted: value?.state?.mainnetSubmitted || false,
deletedSteps: []
};
console.log('[setInitialState] state', state);
dispatch(setInitialValue(state));
};

Expand Down Expand Up @@ -223,14 +218,12 @@ const useCertificateStepper = () => {
const elm = Store.getState().stepper.deletedSteps;
const found = elm.filter((s: TDeleteStep) => s.step === step);
if (!found.length) {
console.log('![updateDeleteStepState] add new step', values);
const payload = {
step,
isDeleted: true
};
dispatch(setDeletedSteps(payload));
} else {
console.log('[updateDeleteStepState] add new step', values);
// change the status to true
dispatch(setDeletedStepValue({ step, isDeleted }));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ const MemberModal = ({ isOpen, onClose, member: memberId }: MemberModalProps) =>
closeOnOverlayClick={false}
isOpen={isOpen}
onClose={onClose}
size="lg"
data-testid="member-modal">
<ModalOverlay />
<ModalContent width={'100%'} maxHeight={'1000px'}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const MemberDetail = ({ member }: MemberDetailProps) => {
return (
<>
<Stack w="full" pb={5}>
<SimpleGrid minChildWidth="280px" spacing="20px" maxH={'700px'} overflowY={'scroll'}>
<SimpleGrid spacing="20px" maxH={'700px'} overflowY={'auto'}>
<List>
<ListItem fontWeight={'bold'}>
<Trans>Website</Trans>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ const MemberTableList = () => {

// if network changes, we need to refetch members
useEffect(() => {
// console.log('network changed');
getMembers();
}, [network, getMembers]);

Expand Down

0 comments on commit 2e8e910

Please sign in to comment.