@daeryun/dr_components 0.3.2 → 0.3.3

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 (133) hide show
  1. package/dist/asset/images/myCase/icon/check_box.webp +0 -0
  2. package/dist/asset/images/myCase/icon/check_box_gray.webp +0 -0
  3. package/dist/cjs/tsconfig-cjs.tsbuildinfo +1 -1
  4. package/dist/components/banner/TopBanner.stories.jsx +8 -4
  5. package/dist/components/banner/TopBanner.stories.tsx +8 -4
  6. package/dist/components/page/MyCase/MyCasePage.d.ts +3 -0
  7. package/dist/components/page/MyCase/MyCasePage.jsx +21 -0
  8. package/dist/components/page/MyCase/MyCasePage.tsx +33 -0
  9. package/dist/components/page/MyCase/[id]/MyCaseDetailPage.d.ts +3 -0
  10. package/dist/components/page/MyCase/[id]/MyCaseDetailPage.jsx +78 -0
  11. package/dist/components/page/MyCase/[id]/MyCaseDetailPage.tsx +156 -0
  12. package/dist/components/page/MyCase/[id]/_component/ContactInfo.d.ts +2 -0
  13. package/dist/components/page/MyCase/[id]/_component/ContactInfo.jsx +89 -0
  14. package/dist/components/page/MyCase/[id]/_component/ContactInfo.tsx +115 -0
  15. package/dist/components/page/MyCase/[id]/_component/DetailInfo.d.ts +6 -0
  16. package/dist/components/page/MyCase/[id]/_component/DetailInfo.jsx +44 -0
  17. package/dist/components/page/MyCase/[id]/_component/DetailInfo.tsx +93 -0
  18. package/dist/components/page/MyCase/[id]/_component/TimeLine.d.ts +6 -0
  19. package/dist/components/page/MyCase/[id]/_component/TimeLine.jsx +46 -0
  20. package/dist/components/page/MyCase/[id]/_component/TimeLine.tsx +73 -0
  21. package/dist/components/page/MyCase/[id]/_component/_caseInquiry/CaseInquiry.d.ts +11 -0
  22. package/dist/components/page/MyCase/[id]/_component/_caseInquiry/CaseInquiry.jsx +80 -0
  23. package/dist/components/page/MyCase/[id]/_component/_caseInquiry/CaseInquiry.tsx +187 -0
  24. package/dist/components/page/MyCase/[id]/_component/_document/Document.d.ts +6 -0
  25. package/dist/components/page/MyCase/[id]/_component/_document/Document.jsx +31 -0
  26. package/dist/components/page/MyCase/[id]/_component/_document/Document.tsx +53 -0
  27. package/dist/components/page/MyCase/[id]/_component/_document/DocumentLine.d.ts +6 -0
  28. package/dist/components/page/MyCase/[id]/_component/_document/DocumentLine.jsx +44 -0
  29. package/dist/components/page/MyCase/[id]/_component/_document/DocumentLine.tsx +61 -0
  30. package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryAddModal.d.ts +7 -0
  31. package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryAddModal.jsx +107 -0
  32. package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryAddModal.tsx +150 -0
  33. package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryConfirmModal.d.ts +7 -0
  34. package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryConfirmModal.jsx +24 -0
  35. package/dist/components/page/MyCase/[id]/_component/_modal/CaseInquiryConfirmModal.tsx +57 -0
  36. package/dist/components/page/MyCase/[id]/_component/_modal/ContractModal.d.ts +5 -0
  37. package/dist/components/page/MyCase/[id]/_component/_modal/ContractModal.jsx +37 -0
  38. package/dist/components/page/MyCase/[id]/_component/_modal/ContractModal.tsx +59 -0
  39. package/dist/components/page/MyCase/[id]/_component/_modal/ModalCotainer.d.ts +7 -0
  40. package/dist/components/page/MyCase/[id]/_component/_modal/ModalCotainer.jsx +26 -0
  41. package/dist/components/page/MyCase/[id]/_component/_modal/ModalCotainer.tsx +39 -0
  42. package/dist/components/page/MyCase/[id]/_component/_textarea/TextArea.d.ts +7 -0
  43. package/dist/components/page/MyCase/[id]/_component/_textarea/TextArea.jsx +4 -0
  44. package/dist/components/page/MyCase/[id]/_component/_textarea/TextArea.tsx +24 -0
  45. package/dist/components/page/MyCase/_actions/action.d.ts +34 -0
  46. package/dist/components/page/MyCase/_actions/action.js +143 -0
  47. package/dist/components/page/MyCase/_actions/action.ts +163 -0
  48. package/dist/components/page/MyCase/_component/CaseContainer.d.ts +2 -0
  49. package/dist/components/page/MyCase/_component/CaseContainer.jsx +194 -0
  50. package/dist/components/page/MyCase/_component/CaseContainer.tsx +242 -0
  51. package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenu.d.ts +8 -0
  52. package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenu.jsx +43 -0
  53. package/dist/components/page/MyCase/_component/_breadCrumble/CategoryMenu.tsx +73 -0
  54. package/dist/components/page/MyCase/_component/_button/Badge.d.ts +14 -0
  55. package/dist/components/page/MyCase/_component/_button/Badge.jsx +16 -0
  56. package/dist/components/page/MyCase/_component/_button/Badge.tsx +22 -0
  57. package/dist/components/page/MyCase/_component/_button/SubColor1Button.d.ts +7 -0
  58. package/dist/components/page/MyCase/_component/_button/SubColor1Button.jsx +9 -0
  59. package/dist/components/page/MyCase/_component/_button/SubColor1Button.tsx +33 -0
  60. package/dist/components/page/MyCase/_component/_button/SubMenuButton.d.ts +7 -0
  61. package/dist/components/page/MyCase/_component/_button/SubMenuButton.jsx +9 -0
  62. package/dist/components/page/MyCase/_component/_button/SubMenuButton.tsx +31 -0
  63. package/dist/components/page/MyCase/_component/_empty/EmptyTable.d.ts +6 -0
  64. package/dist/components/page/MyCase/_component/_empty/EmptyTable.jsx +75 -0
  65. package/dist/components/page/MyCase/_component/_empty/EmptyTable.tsx +86 -0
  66. package/dist/components/page/MyCase/_component/_layout/CaseLayout.d.ts +7 -0
  67. package/dist/components/page/MyCase/_component/_layout/CaseLayout.jsx +11 -0
  68. package/dist/components/page/MyCase/_component/_layout/CaseLayout.tsx +29 -0
  69. package/dist/components/page/MyCase/_component/_layout/CaseWrapper.d.ts +12 -0
  70. package/dist/components/page/MyCase/_component/_layout/CaseWrapper.jsx +25 -0
  71. package/dist/components/page/MyCase/_component/_layout/CaseWrapper.tsx +41 -0
  72. package/dist/components/page/MyCase/_component/_layout/HeaderLayout.d.ts +4 -0
  73. package/dist/components/page/MyCase/_component/_layout/HeaderLayout.jsx +4 -0
  74. package/dist/components/page/MyCase/_component/_layout/HeaderLayout.tsx +5 -0
  75. package/dist/components/page/MyCase/_component/_layout/IntroWrapper.d.ts +9 -0
  76. package/dist/components/page/MyCase/_component/_layout/IntroWrapper.jsx +30 -0
  77. package/dist/components/page/MyCase/_component/_layout/IntroWrapper.tsx +71 -0
  78. package/dist/components/page/MyCase/_component/_loading/Loading.d.ts +2 -0
  79. package/dist/components/page/MyCase/_component/_loading/Loading.jsx +89 -0
  80. package/dist/components/page/MyCase/_component/_loading/Loading.tsx +92 -0
  81. package/dist/components/page/MyCase/_component/_pagination/PaginationComponent.d.ts +10 -0
  82. package/dist/components/page/MyCase/_component/_pagination/PaginationComponent.jsx +80 -0
  83. package/dist/components/page/MyCase/_component/_pagination/PaginationComponent.tsx +133 -0
  84. package/dist/components/page/MyCase/_component/_table/CaseLine.d.ts +5 -0
  85. package/dist/components/page/MyCase/_component/_table/CaseLine.jsx +66 -0
  86. package/dist/components/page/MyCase/_component/_table/CaseLine.tsx +139 -0
  87. package/dist/components/page/MyCase/_component/_table/CaseTabSwiper.d.ts +9 -0
  88. package/dist/components/page/MyCase/_component/_table/CaseTabSwiper.jsx +65 -0
  89. package/dist/components/page/MyCase/_component/_table/CaseTabSwiper.tsx +79 -0
  90. package/dist/components/page/MyCase/_component/_table/CaseTable.d.ts +9 -0
  91. package/dist/components/page/MyCase/_component/_table/CaseTable.jsx +62 -0
  92. package/dist/components/page/MyCase/_component/_table/CaseTable.tsx +93 -0
  93. package/dist/components/page/MyCase/_component/_table/CaseTableMo.d.ts +9 -0
  94. package/dist/components/page/MyCase/_component/_table/CaseTableMo.jsx +11 -0
  95. package/dist/components/page/MyCase/_component/_table/CaseTableMo.tsx +28 -0
  96. package/dist/components/page/MyCase/_component/_table/CaseTableMoBox.d.ts +5 -0
  97. package/dist/components/page/MyCase/_component/_table/CaseTableMoBox.jsx +39 -0
  98. package/dist/components/page/MyCase/_component/_table/CaseTableMoBox.tsx +55 -0
  99. package/dist/components/page/MyCase/_fetchers/addMyCaseQuestion.d.ts +6 -0
  100. package/dist/components/page/MyCase/_fetchers/addMyCaseQuestion.js +31 -0
  101. package/dist/components/page/MyCase/_fetchers/addMyCaseQuestion.ts +22 -0
  102. package/dist/components/page/MyCase/_fetchers/getCase.d.ts +5 -0
  103. package/dist/components/page/MyCase/_fetchers/getCase.js +30 -0
  104. package/dist/components/page/MyCase/_fetchers/getCase.ts +21 -0
  105. package/dist/components/page/MyCase/_fetchers/getCaseList.d.ts +6 -0
  106. package/dist/components/page/MyCase/_fetchers/getCaseList.js +30 -0
  107. package/dist/components/page/MyCase/_fetchers/getCaseList.ts +21 -0
  108. package/dist/components/page/MyCase/_fetchers/getCourtFileList.d.ts +5 -0
  109. package/dist/components/page/MyCase/_fetchers/getCourtFileList.js +30 -0
  110. package/dist/components/page/MyCase/_fetchers/getCourtFileList.ts +21 -0
  111. package/dist/components/page/MyCase/_fetchers/getMyCaseQuestion.d.ts +7 -0
  112. package/dist/components/page/MyCase/_fetchers/getMyCaseQuestion.js +30 -0
  113. package/dist/components/page/MyCase/_fetchers/getMyCaseQuestion.ts +24 -0
  114. package/dist/components/page/MyCase/_fetchers/getMyFileList.d.ts +5 -0
  115. package/dist/components/page/MyCase/_fetchers/getMyFileList.js +30 -0
  116. package/dist/components/page/MyCase/_fetchers/getMyFileList.ts +21 -0
  117. package/dist/components/page/MyCase/_fetchers/getTimeLine.d.ts +5 -0
  118. package/dist/components/page/MyCase/_fetchers/getTimeLine.js +30 -0
  119. package/dist/components/page/MyCase/_fetchers/getTimeLine.ts +21 -0
  120. package/dist/components/page/MyCase/_lib/catagoryMenuName.d.ts +8 -0
  121. package/dist/components/page/MyCase/_lib/catagoryMenuName.js +8 -0
  122. package/dist/components/page/MyCase/_lib/catagoryMenuName.ts +11 -0
  123. package/dist/components/page/MyCase/_lib/pagination/locale/ko_KR.d.ts +15 -0
  124. package/dist/components/page/MyCase/_lib/pagination/locale/ko_KR.js +21 -0
  125. package/dist/components/page/MyCase/_type/type.d.ts +73 -0
  126. package/dist/components/page/MyCase/_type/type.js +1 -0
  127. package/dist/components/page/MyCase/_type/type.ts +81 -0
  128. package/dist/components/page/index.d.ts +1 -0
  129. package/dist/components/page/index.js +1 -1
  130. package/dist/components/page/index.ts +1 -1
  131. package/dist/styles/globals.css +2332 -235
  132. package/dist/tsconfig.tsbuildinfo +1 -1
  133. package/package.json +1 -1
@@ -0,0 +1,156 @@
1
+ import React, { useEffect, useState } from 'react';
2
+ import { useTranslation } from 'next-i18next';
3
+ import IntroWrapper from '../_component/_layout/IntroWrapper';
4
+ import CaseLayout from '../_component/_layout/CaseLayout';
5
+ import SubMenuButton from '../_component/_button/SubMenuButton';
6
+ import HeaderLayout from '../_component/_layout/HeaderLayout';
7
+ import DetailInfo from './_component/DetailInfo';
8
+ import { useParams, usePathname, useRouter, useSearchParams } from 'next/navigation';
9
+ import { useQuery } from 'react-query';
10
+ import getCase from '../_fetchers/getCase';
11
+ import { DetailList, FetchType, FileList, Question, TimeLineType } from '../_type/type';
12
+ import {
13
+ actionGetCourtFileList,
14
+ actionGetDetailList,
15
+ actionGetMyCaseQuestion,
16
+ actionGetMyFileList,
17
+ actionGetTimeLine
18
+ } from '../_actions/action';
19
+ import background from '../../../../../asset/images/myCase/background.webp';
20
+ import backgroundTb from '../../../../../asset/images/myCase/background_tb.webp';
21
+ import backgroundMo from '../../../../../asset/images/myCase/background_mo.webp';
22
+ import TimeLine from './_component/TimeLine';
23
+ import Document from './_component/_document/Document';
24
+ import ContactInfo from './_component/ContactInfo';
25
+ import CaseInquiry from './_component/_caseInquiry/CaseInquiry';
26
+ import CaseTabSwiper from '../_component/_table/CaseTabSwiper';
27
+ const Intro = () => {
28
+ const { t } = useTranslation('common');
29
+ const [selected, setSelected] = useState<string>('사건 정보');
30
+ const router = useRouter();
31
+ const searchParams = useSearchParams();
32
+ const params = useParams();
33
+ const id = params?.id;
34
+
35
+ const { page, tap, subTap } = Object.fromEntries(searchParams.entries());
36
+ const pageNumber = page ? Number(page) : 1;
37
+ const [pageSize, setPageSize] = useState(3);
38
+
39
+ const { data: detailList, isLoading: detailListLoading } = actionGetDetailList(id as string);
40
+ const { data: timeLine, isLoading: timeLineLoading } = actionGetTimeLine(id as string);
41
+ const { data: courtFileList, isLoading: courtFileListLoading } = actionGetCourtFileList(id as string);
42
+ const { data: myFileList, isLoading: myFileListLoading } = actionGetMyFileList(id as string);
43
+ const {
44
+ data: myCaseQuestion,
45
+ isLoading: myCaseQuestionLoading,
46
+ refetch: myCaseQuestionRefetch
47
+ } = actionGetMyCaseQuestion(id as string, pageNumber, pageSize);
48
+
49
+ return (
50
+ <div className=" mt-[70px] min-h-[800px] md:mt-[78px] md2:mt-[88px]">
51
+ <IntroWrapper
52
+ title={'상세 사건 정보'}
53
+ subTitle={'대륜과 진행하고 있는 나의 사건 현황을 한눈에 확인할 수 있습니다.'}
54
+ backgroundImage={background}
55
+ backgroundTbImage={backgroundTb}
56
+ backgroundMoImage={backgroundMo}
57
+ outerClassName="h-[300px] sm-top:h-[448px] lg:h-[513px]"
58
+ />
59
+
60
+ <div className={'relative z-[1] '}>
61
+ {/*header 크기 -> 115px max-lg2:90px max-xs:83px*/}
62
+ <HeaderLayout>
63
+ <div className="sm-top:mt-[283px] mt-[210px] lg:mt-[302px] ">
64
+ <div className="max-sm-top:hidden sm-top:gap-[32px] flex items-center justify-center lg:gap-[28px]">
65
+ <SubMenuButton
66
+ title="사건 정보"
67
+ isSelected={selected === '사건 정보'}
68
+ onClick={() => setSelected('사건 정보')}
69
+ />
70
+ <SubMenuButton
71
+ title="사건 타임라인"
72
+ isSelected={selected === '사건 타임라인'}
73
+ onClick={() => setSelected('사건 타임라인')}
74
+ />
75
+ {/* <SubMenuButton
76
+ title="문서함"
77
+ isSelected={selected === '문서함'}
78
+ onClick={() => setSelected('문서함')}
79
+ /> */}
80
+ <SubMenuButton
81
+ title="계약정보"
82
+ isSelected={selected === '계약정보'}
83
+ onClick={() => setSelected('계약정보')}
84
+ />
85
+ <SubMenuButton
86
+ title="사건문의"
87
+ isSelected={selected === '사건문의'}
88
+ onClick={() => setSelected('사건문의')}
89
+ />
90
+ </div>
91
+ <div className="sm-top:hidden 2sm:pl-[40px]">
92
+ <CaseTabSwiper id="case-tab-swiper3" scrollClassName="max-[500px]:!block">
93
+ <SubMenuButton
94
+ title="사건 정보"
95
+ isSelected={selected === '사건 정보'}
96
+ onClick={() => setSelected('사건 정보')}
97
+ outerClassName="ml-[20px]"
98
+ />
99
+ <SubMenuButton
100
+ title="사건 타임라인"
101
+ isSelected={selected === '사건 타임라인'}
102
+ onClick={() => setSelected('사건 타임라인')}
103
+ />
104
+ {/* <SubMenuButton
105
+ title="문서함"
106
+ isSelected={selected === '문서함'}
107
+ onClick={() => setSelected('문서함')}
108
+ /> */}
109
+ <SubMenuButton
110
+ title="계약정보"
111
+ isSelected={selected === '계약정보'}
112
+ onClick={() => setSelected('계약정보')}
113
+ />
114
+ <SubMenuButton
115
+ title="사건문의"
116
+ isSelected={selected === '사건문의'}
117
+ onClick={() => setSelected('사건문의')}
118
+ outerClassName="!mr-[0px]"
119
+ />
120
+ </CaseTabSwiper>
121
+ </div>
122
+ </div>
123
+ {selected === '사건 정보' && (
124
+ <DetailInfo detailList={detailList?.data as DetailList} isLoading={detailListLoading} />
125
+ )}
126
+ {selected === '사건 타임라인' && (
127
+ <TimeLine
128
+ timeLine={timeLine?.list as unknown as TimeLineType[][]}
129
+ isLoading={timeLineLoading}
130
+ />
131
+ )}
132
+ {/* {selected === '문서함' && (
133
+ <Document
134
+ courtFileList={courtFileList?.data as FileList[]}
135
+ myFileList={myFileList?.data as FileList[]}
136
+ />
137
+ )} */}
138
+ {selected === '계약정보' && <ContactInfo />}
139
+ {selected === '사건문의' && (
140
+ <CaseInquiry
141
+ myCaseQuestion={myCaseQuestion?.list as unknown as Question[]}
142
+ id={id as string}
143
+ refetch={myCaseQuestionRefetch}
144
+ pageSize={pageSize}
145
+ totalLength={myCaseQuestion?.totalLength ?? 0}
146
+ pageNumber={pageNumber}
147
+ onChange={() => {}}
148
+ />
149
+ )}
150
+ </HeaderLayout>
151
+ </div>
152
+ </div>
153
+ );
154
+ };
155
+
156
+ export default Intro;
@@ -0,0 +1,2 @@
1
+ declare const ContactInfo: () => import("react").JSX.Element;
2
+ export default ContactInfo;
@@ -0,0 +1,89 @@
1
+ import dayjs from 'dayjs';
2
+ import CaseLayout from '../../_component/_layout/CaseLayout';
3
+ import { useState } from 'react';
4
+ import ContractModal from './_modal/ContractModal';
5
+ const Label = ({ title, status }) => {
6
+ return (<div className="flex flex-row items-center gap-[4px] sm-top:gap-[8px]">
7
+ <div className={`h-[6px] w-[6px] rounded-full sm-top:h-[8px] sm-top:w-[8px] lg:h-[12px] lg:w-[12px] ${status ? 'bg-mycaseMainColor' : 'bg-grayScale4'}`}/>
8
+ <p className={`body_small2_mo sm-top:body_small2_tb lg:body_small2 ${status ? 'text-mycaseMainColor' : 'text-grayScale4'}`}>
9
+ {title}
10
+ </p>
11
+ </div>);
12
+ };
13
+ const LineBox = ({ children, title }) => {
14
+ return (<div className=" border-b-[1px] border-solid border-grayScale6 pb-[8px] pt-[24px] sm-top:py-[24px]">
15
+ {title && <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">{title}</p>}
16
+ <div className="flex flex-row items-center justify-between">{children}</div>
17
+ </div>);
18
+ };
19
+ const ContactInfo = () => {
20
+ const list = {
21
+ payment_status: 'partial', //일부납/완납
22
+ deposit_amount: 10000000, // 착수금
23
+ remaining_amount: 4500000, // 잔여금액
24
+ payments: [
25
+ {
26
+ title: '상담비',
27
+ created_at: '2025-02-18 14:53:14',
28
+ amount: 110000,
29
+ method: '신용카드 - 현대카드 (일시불)'
30
+ },
31
+ {
32
+ title: '수임료',
33
+ created_at: '2025-02-19 14:53:14',
34
+ amount: 3290000,
35
+ method: '신용카드 - 롯데카드 (03개월 할부)'
36
+ },
37
+ { title: '수임료', created_at: '2025-02-20 14:53:14', amount: 1600000, method: '계좌이체 - 신한은행' },
38
+ { title: '수임료', created_at: '2025-02-21 14:53:14', amount: 500000, method: '계좌이체 - 현대카드' }
39
+ ]
40
+ };
41
+ const [isOpen, setIsOpen] = useState(false);
42
+ return (<CaseLayout isMobilePadding={false} outerClassName="mt-[35px] sm-top:mt-[24px] lg:mt-[40px] " innerClassName={'pt-[32px] px-[20px] pb-[40px] 2sm:px-[40px] sm-top:mt-[24px] sm-top:px-[50px] sm-top:pb-[60px] sm-top:pt-[56px] lg:pt-[60px] lg:pb-[80px] lg:px-[60px]'}>
43
+ <div className="flex flex-row items-center justify-between">
44
+ <div className="flex flex-row gap-[12px] sm-top:gap-[28px] lg:gap-[32px]">
45
+ <Label title="일부납" status={list.payment_status === 'partial'}/>
46
+ <Label title="완납" status={list.payment_status !== 'partial'}/>
47
+ </div>
48
+ <button className={`flex h-[26px] w-[66px] items-center justify-center rounded-[13px] border border-solid border-black sm-top:h-[39px] sm-top:w-[96px] sm-top:rounded-[20px] lg:h-[41px] lg:w-[95px] lg:rounded-[21px]`} onClick={() => setIsOpen(!isOpen)}>
49
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2">내 약정서</p>
50
+ </button>
51
+ </div>
52
+
53
+ <div className={'mt-[16px] sm-top:mt-[28px] lg:mt-[26px]'}>
54
+ <LineBox>
55
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">착수금</p>
56
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">
57
+ {list.deposit_amount.toLocaleString()}원
58
+ </p>
59
+ </LineBox>
60
+
61
+ {list.payments.map((item, index) => (<LineBox key={index} title={index === 0 ? '입금액' : ''}>
62
+ <div className={`${index === 0 ? 'mt-[13px] sm-top:mt-[16px] lg:mt-[25px] ' : ''} flex flex-col gap-[8px] sm-top:gap-[12px] lg:gap-[8px]`}>
63
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
64
+ {item.title}
65
+ </p>
66
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
67
+ {dayjs(item.created_at).format('YYYY.MM.DD HH:mm')}
68
+ </p>
69
+ </div>
70
+ <div className="flex flex-col items-end gap-[8px] sm-top:gap-[12px] lg:gap-[8px]">
71
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">
72
+ {item.amount.toLocaleString()}원
73
+ </p>
74
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
75
+ {item.method}
76
+ </p>
77
+ </div>
78
+ </LineBox>))}
79
+ <LineBox>
80
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">잔여금액</p>
81
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">
82
+ {list.remaining_amount.toLocaleString()}원
83
+ </p>
84
+ </LineBox>
85
+ </div>
86
+ <ContractModal isOpen={isOpen} onClose={() => setIsOpen(false)}/>
87
+ </CaseLayout>);
88
+ };
89
+ export default ContactInfo;
@@ -0,0 +1,115 @@
1
+ import dayjs from 'dayjs';
2
+ import CaseLayout from '../../_component/_layout/CaseLayout';
3
+ import { PaymentList, Payment } from '../../_type/type';
4
+ import { useState } from 'react';
5
+ import ContractModal from './_modal/ContractModal';
6
+
7
+ const Label = ({ title, status }: { title: string; status: boolean }) => {
8
+ return (
9
+ <div className="flex flex-row items-center gap-[4px] sm-top:gap-[8px]">
10
+ <div
11
+ className={`h-[6px] w-[6px] rounded-full sm-top:h-[8px] sm-top:w-[8px] lg:h-[12px] lg:w-[12px] ${status ? 'bg-mycaseMainColor' : 'bg-grayScale4'}`}
12
+ />
13
+ <p
14
+ className={`body_small2_mo sm-top:body_small2_tb lg:body_small2 ${status ? 'text-mycaseMainColor' : 'text-grayScale4'}`}
15
+ >
16
+ {title}
17
+ </p>
18
+ </div>
19
+ );
20
+ };
21
+ const LineBox = ({ children, title }: { children: React.ReactNode; title?: string }) => {
22
+ return (
23
+ <div className=" border-b-[1px] border-solid border-grayScale6 pb-[8px] pt-[24px] sm-top:py-[24px]">
24
+ {title && <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">{title}</p>}
25
+ <div className="flex flex-row items-center justify-between">{children}</div>
26
+ </div>
27
+ );
28
+ };
29
+ const ContactInfo = () => {
30
+ const list: PaymentList = {
31
+ payment_status: 'partial', //일부납/완납
32
+ deposit_amount: 10000000, // 착수금
33
+ remaining_amount: 4500000, // 잔여금액
34
+ payments: [
35
+ {
36
+ title: '상담비',
37
+ created_at: '2025-02-18 14:53:14',
38
+ amount: 110000,
39
+ method: '신용카드 - 현대카드 (일시불)'
40
+ },
41
+ {
42
+ title: '수임료',
43
+ created_at: '2025-02-19 14:53:14',
44
+ amount: 3290000,
45
+ method: '신용카드 - 롯데카드 (03개월 할부)'
46
+ },
47
+ { title: '수임료', created_at: '2025-02-20 14:53:14', amount: 1600000, method: '계좌이체 - 신한은행' },
48
+ { title: '수임료', created_at: '2025-02-21 14:53:14', amount: 500000, method: '계좌이체 - 현대카드' }
49
+ ]
50
+ };
51
+ const [isOpen, setIsOpen] = useState(false);
52
+ return (
53
+ <CaseLayout
54
+ isMobilePadding={false}
55
+ outerClassName="mt-[35px] sm-top:mt-[24px] lg:mt-[40px] "
56
+ innerClassName={
57
+ 'pt-[32px] px-[20px] pb-[40px] 2sm:px-[40px] sm-top:mt-[24px] sm-top:px-[50px] sm-top:pb-[60px] sm-top:pt-[56px] lg:pt-[60px] lg:pb-[80px] lg:px-[60px]'
58
+ }
59
+ >
60
+ <div className="flex flex-row items-center justify-between">
61
+ <div className="flex flex-row gap-[12px] sm-top:gap-[28px] lg:gap-[32px]">
62
+ <Label title="일부납" status={list.payment_status === 'partial'} />
63
+ <Label title="완납" status={list.payment_status !== 'partial'} />
64
+ </div>
65
+ <button
66
+ className={`flex h-[26px] w-[66px] items-center justify-center rounded-[13px] border border-solid border-black sm-top:h-[39px] sm-top:w-[96px] sm-top:rounded-[20px] lg:h-[41px] lg:w-[95px] lg:rounded-[21px]`}
67
+ onClick={() => setIsOpen(!isOpen)}
68
+ >
69
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2">내 약정서</p>
70
+ </button>
71
+ </div>
72
+
73
+ <div className={'mt-[16px] sm-top:mt-[28px] lg:mt-[26px]'}>
74
+ <LineBox>
75
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">착수금</p>
76
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">
77
+ {list.deposit_amount.toLocaleString()}원
78
+ </p>
79
+ </LineBox>
80
+
81
+ {list.payments.map((item, index) => (
82
+ <LineBox key={index} title={index === 0 ? '입금액' : ''}>
83
+ <div
84
+ className={`${index === 0 ? 'mt-[13px] sm-top:mt-[16px] lg:mt-[25px] ' : ''} flex flex-col gap-[8px] sm-top:gap-[12px] lg:gap-[8px]`}
85
+ >
86
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
87
+ {item.title}
88
+ </p>
89
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
90
+ {dayjs(item.created_at).format('YYYY.MM.DD HH:mm')}
91
+ </p>
92
+ </div>
93
+ <div className="flex flex-col items-end gap-[8px] sm-top:gap-[12px] lg:gap-[8px]">
94
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">
95
+ {item.amount.toLocaleString()}원
96
+ </p>
97
+ <p className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
98
+ {item.method}
99
+ </p>
100
+ </div>
101
+ </LineBox>
102
+ ))}
103
+ <LineBox>
104
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">잔여금액</p>
105
+ <p className="text-black body_medium1_mo sm-top:body_medium1_tb lg:body_medium1">
106
+ {list.remaining_amount.toLocaleString()}원
107
+ </p>
108
+ </LineBox>
109
+ </div>
110
+ <ContractModal isOpen={isOpen} onClose={() => setIsOpen(false)} />
111
+ </CaseLayout>
112
+ );
113
+ };
114
+
115
+ export default ContactInfo;
@@ -0,0 +1,6 @@
1
+ import { DetailList } from '../../_type/type';
2
+ declare const DetailInfo: ({ detailList, isLoading }: {
3
+ detailList: DetailList;
4
+ isLoading: boolean;
5
+ }) => import("react").JSX.Element;
6
+ export default DetailInfo;
@@ -0,0 +1,44 @@
1
+ import Image from 'next/image';
2
+ import Link from 'next/link';
3
+ import CaseLayout from '../../_component/_layout/CaseLayout';
4
+ import Loading from '../../_component/_loading/Loading';
5
+ import caseLookupLinkout from '../../../../../asset/images/mycase/icon/case_lookup_linkout.webp';
6
+ const Line = ({ title, content, isFirst = false }) => {
7
+ return (<div className={`lg;py-[28px] border-grayScale5 sm-top:py-[20px] flex flex-row border-solid py-[20px] ${isFirst ? 'border-y-[1px]' : 'border-b-[1px]'}`}>
8
+ <div className="body_medium2_mo sm-top:body_medium2_tb lg:body_medium2 w-[30%]">{title}</div>
9
+ <div className="body_medium1_mo sm-top:body_medium1_tb lg:body_medium1 w-[70%]">
10
+ {Array.isArray(content)
11
+ ? content.map((item, index) => <div key={index}>{item}</div>)
12
+ : content
13
+ ? content
14
+ : '-'}
15
+ </div>
16
+ </div>);
17
+ };
18
+ const DetailInfo = ({ detailList, isLoading }) => {
19
+ var _a, _b, _c;
20
+ return (<CaseLayout isMobilePadding={false} outerClassName="mt-[35px] sm-top:mt-[24px] lg:mt-[40px] " innerClassName={'px-[20px] 2sm:px-[40px] pt-[30px] pb-[40px] sm-top:px-[50px] sm-top:pt-[56px] sm-top:pb-[50px] lg:pt-[60px] lg:pb-[80px] lg:px-[60px]'}>
21
+ {isLoading ? (<Loading />) : (<>
22
+ <Line title="사건번호" content={detailList === null || detailList === void 0 ? void 0 : detailList.case_number} isFirst/>
23
+ <Line title="법원명" content={detailList === null || detailList === void 0 ? void 0 : detailList.agency_name}/>
24
+ <Line title="사건명" content={detailList === null || detailList === void 0 ? void 0 : detailList.title}/>
25
+ <Line title="진행단계" content={detailList === null || detailList === void 0 ? void 0 : detailList.state}/>
26
+ <Line title="사건 시작일" content={detailList === null || detailList === void 0 ? void 0 : detailList.accept_date}/>
27
+ <Line title="사건 종료일" content={detailList === null || detailList === void 0 ? void 0 : detailList.end_date}/>
28
+ <Line title="담당 변호사" content={detailList === null || detailList === void 0 ? void 0 : detailList.lawyer}/>
29
+ <Line title="나의 정보" content={`${(_a = detailList === null || detailList === void 0 ? void 0 : detailList.my_info) === null || _a === void 0 ? void 0 : _a.position} / ${(_b = detailList === null || detailList === void 0 ? void 0 : detailList.my_info) === null || _b === void 0 ? void 0 : _b.name} / ${(_c = detailList === null || detailList === void 0 ? void 0 : detailList.my_info) === null || _c === void 0 ? void 0 : _c.tel}`}/>
30
+ <Line title="상대방 정보" content={(detailList === null || detailList === void 0 ? void 0 : detailList.other_info.length) > 0
31
+ ? detailList === null || detailList === void 0 ? void 0 : detailList.other_info.map((info, index) => `${info.position} / ${info.name} / ${info.tel}`)
32
+ : '-'}/>
33
+ <Link href="#" className={'itesm-center sm-top:mt-[20px] top-[16px] mt-[16px] flex w-full justify-end'}>
34
+ <div className="flex flex-row items-center gap-[8px] lg:gap-[12px]">
35
+ <Image src={caseLookupLinkout} alt="edit" width={28} height={28} className="sm-top:h-[20px] sm-top:w-[20px] h-[16px] w-[16px] lg:h-[28px] lg:w-[28px]"/>
36
+ <p className="body_medium2_mo sm-top:body_medium2_tb lg:body_medium2">
37
+ 대법원 사건 조회하기
38
+ </p>
39
+ </div>
40
+ </Link>
41
+ </>)}
42
+ </CaseLayout>);
43
+ };
44
+ export default DetailInfo;
@@ -0,0 +1,93 @@
1
+ import { useQuery } from 'react-query';
2
+ import getCase from '../../_fetchers/getCase';
3
+ import { useState } from 'react';
4
+ import { DetailList } from '../../_type/type';
5
+ import Image from 'next/image';
6
+ import Link from 'next/link';
7
+ import CaseLayout from '../../_component/_layout/CaseLayout';
8
+ import Loading from '../../_component/_loading/Loading';
9
+ import caseLookupLinkout from '../../../../../asset/images/mycase/icon/case_lookup_linkout.webp';
10
+ const Line = ({
11
+ title,
12
+ content,
13
+ isFirst = false
14
+ }: {
15
+ title: string;
16
+ content: string | string[];
17
+ isFirst?: boolean;
18
+ }) => {
19
+ return (
20
+ <div
21
+ className={`lg;py-[28px] border-grayScale5 sm-top:py-[20px] flex flex-row border-solid py-[20px] ${
22
+ isFirst ? 'border-y-[1px]' : 'border-b-[1px]'
23
+ }`}
24
+ >
25
+ <div className="body_medium2_mo sm-top:body_medium2_tb lg:body_medium2 w-[30%]">{title}</div>
26
+ <div className="body_medium1_mo sm-top:body_medium1_tb lg:body_medium1 w-[70%]">
27
+ {Array.isArray(content)
28
+ ? content.map((item, index) => <div key={index}>{item}</div>)
29
+ : content
30
+ ? content
31
+ : '-'}
32
+ </div>
33
+ </div>
34
+ );
35
+ };
36
+ const DetailInfo = ({ detailList, isLoading }: { detailList: DetailList; isLoading: boolean }) => {
37
+ return (
38
+ <CaseLayout
39
+ isMobilePadding={false}
40
+ outerClassName="mt-[35px] sm-top:mt-[24px] lg:mt-[40px] "
41
+ innerClassName={
42
+ 'px-[20px] 2sm:px-[40px] pt-[30px] pb-[40px] sm-top:px-[50px] sm-top:pt-[56px] sm-top:pb-[50px] lg:pt-[60px] lg:pb-[80px] lg:px-[60px]'
43
+ }
44
+ >
45
+ {isLoading ? (
46
+ <Loading />
47
+ ) : (
48
+ <>
49
+ <Line title="사건번호" content={detailList?.case_number} isFirst />
50
+ <Line title="법원명" content={detailList?.agency_name} />
51
+ <Line title="사건명" content={detailList?.title} />
52
+ <Line title="진행단계" content={detailList?.state} />
53
+ <Line title="사건 시작일" content={detailList?.accept_date} />
54
+ <Line title="사건 종료일" content={detailList?.end_date} />
55
+ <Line title="담당 변호사" content={detailList?.lawyer} />
56
+ <Line
57
+ title="나의 정보"
58
+ content={`${detailList?.my_info?.position} / ${detailList?.my_info?.name} / ${detailList?.my_info?.tel}`}
59
+ />
60
+ <Line
61
+ title="상대방 정보"
62
+ content={
63
+ detailList?.other_info.length > 0
64
+ ? detailList?.other_info.map(
65
+ (info, index) => `${info.position} / ${info.name} / ${info.tel}`
66
+ )
67
+ : '-'
68
+ }
69
+ />
70
+ <Link
71
+ href="#"
72
+ className={'itesm-center sm-top:mt-[20px] top-[16px] mt-[16px] flex w-full justify-end'}
73
+ >
74
+ <div className="flex flex-row items-center gap-[8px] lg:gap-[12px]">
75
+ <Image
76
+ src={caseLookupLinkout}
77
+ alt="edit"
78
+ width={28}
79
+ height={28}
80
+ className="sm-top:h-[20px] sm-top:w-[20px] h-[16px] w-[16px] lg:h-[28px] lg:w-[28px]"
81
+ />
82
+ <p className="body_medium2_mo sm-top:body_medium2_tb lg:body_medium2">
83
+ 대법원 사건 조회하기
84
+ </p>
85
+ </div>
86
+ </Link>
87
+ </>
88
+ )}
89
+ </CaseLayout>
90
+ );
91
+ };
92
+
93
+ export default DetailInfo;
@@ -0,0 +1,6 @@
1
+ import { TimeLineType } from '../../_type/type';
2
+ declare const TimeLine: ({ timeLine, isLoading }: {
3
+ timeLine: TimeLineType[][];
4
+ isLoading: boolean;
5
+ }) => import("react").JSX.Element;
6
+ export default TimeLine;
@@ -0,0 +1,46 @@
1
+ import dayjs from 'dayjs';
2
+ import CaseLayout from '../../_component/_layout/CaseLayout';
3
+ import Image from 'next/image';
4
+ import checkCircle from '../../../../../asset/images/mycase/icon/check_circle.webp';
5
+ import checkCircle2 from '../../../../../asset/images/mycase/icon/check_circle2.webp';
6
+ const TimeBox = ({ item }) => {
7
+ return (<div className="sm-top:py-[20px] sm-top:px-[28px] sm-top:rounded-[8px] bg-grayScale7 rounded-[4px] px-[20px] py-[16px] lg:rounded-[12px] lg:px-[28px] lg:py-[20px]">
8
+ <div className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
9
+ {dayjs(item.progress_time).format('YYYY.MM.DD HH:mm')}
10
+ </div>
11
+ <div className="body_medium2_mo sm-top:body_medium2_tb lg:body_medium2 sm-top:mt-[6px] mt-[8px] lg:mt-[8px]">
12
+ {item.title}
13
+ </div>
14
+ </div>);
15
+ };
16
+ const TimeContainer = ({ list, isFirst }) => {
17
+ const imgUrl = list[0].is_highest_court ? checkCircle : checkCircle2;
18
+ const color = list[0].is_highest_court ? 'text-subColor05' : 'text-mycaseMainColor';
19
+ const borderColor = list[0].is_highest_court ? 'border-subColor05' : 'border-mycaseMainColor';
20
+ return (<>
21
+ <div className="sm-top:gap-[16px] flex flex-col gap-[14px] lg:gap-[13px]">
22
+ <div className="sm-top:gap-[12px] flex flex-row items-center gap-[8px]">
23
+ <Image unoptimized src={imgUrl} alt="arrow" width={24} height={24} className="sm-top:w-[20px] sm-top:h-[20px] h-[16px] w-[16px] lg:h-[24px] lg:w-[24px]"/>
24
+ <p className={`body_medium1_mo sm-top:body_medium1_tb lg:body_medium1 ${color}`}>
25
+ {list[0].title}
26
+ </p>
27
+ </div>
28
+ <div className={`sm-top:ml-[6px] sm-top:pl-[22px] ml-[8px] pl-[16px] lg:ml-[12px] lg:pl-[28px] ${borderColor} flex flex-col gap-[16px] ` +
29
+ `${isFirst ? '' : 'sm-top:border-l-[1.5px] border-l-[1px] border-solid lg:border-l-[2px] '}`}>
30
+ {list.map((item) => {
31
+ return <TimeBox key={item.idx} item={item}/>;
32
+ })}
33
+ </div>
34
+ </div>
35
+ </>);
36
+ };
37
+ const TimeLine = ({ timeLine, isLoading }) => {
38
+ return (<CaseLayout isMobilePadding={false} outerClassName="mt-[35px] sm-top:mt-[24px] lg:mt-[40px] " innerClassName={'pt-[32px] px-[20px] 2sm:px-[40px] sm-top:px-[50px] sm-top:pt-[56px] sm-top:pb-[80px] lg:pt-[60px] lg:pb-[80px] lg:px-[60px]'}>
39
+ <div className="flex flex-col gap-[16px]">
40
+ {timeLine.map((list, index) => {
41
+ return <TimeContainer key={index} list={list} isFirst={index === timeLine.length - 1}/>;
42
+ })}
43
+ </div>
44
+ </CaseLayout>);
45
+ };
46
+ export default TimeLine;
@@ -0,0 +1,73 @@
1
+ import dayjs from 'dayjs';
2
+ import CaseLayout from '../../_component/_layout/CaseLayout';
3
+ import Image from 'next/image';
4
+ import { TimeLineType } from '../../_type/type';
5
+ import checkCircle from '../../../../../asset/images/mycase/icon/check_circle.webp';
6
+ import checkCircle2 from '../../../../../asset/images/mycase/icon/check_circle2.webp';
7
+
8
+ const TimeBox = ({ item }: { item: any }) => {
9
+ return (
10
+ <div className="sm-top:py-[20px] sm-top:px-[28px] sm-top:rounded-[8px] bg-grayScale7 rounded-[4px] px-[20px] py-[16px] lg:rounded-[12px] lg:px-[28px] lg:py-[20px]">
11
+ <div className="body_small2_mo sm-top:body_small2_tb lg:body_small2 text-grayScale2">
12
+ {dayjs(item.progress_time).format('YYYY.MM.DD HH:mm')}
13
+ </div>
14
+ <div className="body_medium2_mo sm-top:body_medium2_tb lg:body_medium2 sm-top:mt-[6px] mt-[8px] lg:mt-[8px]">
15
+ {item.title}
16
+ </div>
17
+ </div>
18
+ );
19
+ };
20
+ const TimeContainer = ({ list, isFirst }: { list: TimeLineType[]; isFirst: boolean }) => {
21
+ const imgUrl = list[0].is_highest_court ? checkCircle : checkCircle2;
22
+ const color = list[0].is_highest_court ? 'text-subColor05' : 'text-mycaseMainColor';
23
+ const borderColor = list[0].is_highest_court ? 'border-subColor05' : 'border-mycaseMainColor';
24
+ return (
25
+ <>
26
+ <div className="sm-top:gap-[16px] flex flex-col gap-[14px] lg:gap-[13px]">
27
+ <div className="sm-top:gap-[12px] flex flex-row items-center gap-[8px]">
28
+ <Image
29
+ unoptimized
30
+ src={imgUrl}
31
+ alt="arrow"
32
+ width={24}
33
+ height={24}
34
+ className="sm-top:w-[20px] sm-top:h-[20px] h-[16px] w-[16px] lg:h-[24px] lg:w-[24px]"
35
+ />
36
+ <p className={`body_medium1_mo sm-top:body_medium1_tb lg:body_medium1 ${color}`}>
37
+ {list[0].title}
38
+ </p>
39
+ </div>
40
+ <div
41
+ className={
42
+ `sm-top:ml-[6px] sm-top:pl-[22px] ml-[8px] pl-[16px] lg:ml-[12px] lg:pl-[28px] ${borderColor} flex flex-col gap-[16px] ` +
43
+ `${isFirst ? '' : 'sm-top:border-l-[1.5px] border-l-[1px] border-solid lg:border-l-[2px] '}`
44
+ }
45
+ >
46
+ {list.map((item: any) => {
47
+ return <TimeBox key={item.idx} item={item} />;
48
+ })}
49
+ </div>
50
+ </div>
51
+ </>
52
+ );
53
+ };
54
+
55
+ const TimeLine = ({ timeLine, isLoading }: { timeLine: TimeLineType[][]; isLoading: boolean }) => {
56
+ return (
57
+ <CaseLayout
58
+ isMobilePadding={false}
59
+ outerClassName="mt-[35px] sm-top:mt-[24px] lg:mt-[40px] "
60
+ innerClassName={
61
+ 'pt-[32px] px-[20px] 2sm:px-[40px] sm-top:px-[50px] sm-top:pt-[56px] sm-top:pb-[80px] lg:pt-[60px] lg:pb-[80px] lg:px-[60px]'
62
+ }
63
+ >
64
+ <div className="flex flex-col gap-[16px]">
65
+ {timeLine.map((list, index) => {
66
+ return <TimeContainer key={index} list={list} isFirst={index === timeLine.length - 1} />;
67
+ })}
68
+ </div>
69
+ </CaseLayout>
70
+ );
71
+ };
72
+
73
+ export default TimeLine;