@daeryun/dr_components 1.2.52 → 1.2.54

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.
@@ -14,12 +14,20 @@ import Link from 'next/link';
14
14
  import useBrowser from '../hook/useBrowser';
15
15
  import { SetterOrUpdater } from 'recoil';
16
16
  import { usePathname, useRouter } from 'next/navigation';
17
+ import PCTopBanner from './PCTopBanner';
18
+ import MobileTopBanner from './MobileTopBanner';
19
+ import { isTopPopupMobileHidden } from './common';
17
20
 
18
21
  //배너타입
19
- interface IBannerTypes {
22
+ export interface IBannerTypes {
20
23
  color_code: string;
21
- days: number[];
24
+ days: string[];
25
+ start_at: string;
26
+ start_hour: number;
27
+ start_min: number;
22
28
  end_at: string;
29
+ end_hour: number;
30
+ end_min: number;
23
31
  file_alt: string;
24
32
  file_path: string;
25
33
  file_type: string;
@@ -29,7 +37,6 @@ interface IBannerTypes {
29
37
  p_link: string;
30
38
  p_sort: number;
31
39
  save_file_name: string;
32
- start_at: string;
33
40
  pc_link?: string;
34
41
  mobile_link?: string;
35
42
  }
@@ -109,6 +116,10 @@ const TopBanner = ({ setBannerHeight }: { setBannerHeight?: SetterOrUpdater<numb
109
116
  //팝업 리스트
110
117
  const [popup, setPopup] = useState<IBannerTypes[]>([]);
111
118
 
119
+ const [mobileOpen, setMobileOpen] = useState<boolean>(() => {
120
+ return !isTopPopupMobileHidden();
121
+ });
122
+
112
123
  const addClickCnt = (idx: number) => {
113
124
  paramFetch('https://mng.daeryunlaw.com/api/popup/top/click', { idx: idx }, null);
114
125
  };
@@ -335,171 +346,13 @@ const TopBanner = ({ setBannerHeight }: { setBannerHeight?: SetterOrUpdater<numb
335
346
 
336
347
  return (
337
348
  <>
338
- <div ref={bannerRef} className={style.header_banner_wrap}>
339
- {/* pc */}
340
- {width > 900 && (
341
- <div className={style.header_banner}>
342
- {popup && popup.filter(item => item.file_type === 'file_pc').length > 0 ? (
343
- <Swiper
344
- autoplay={{ delay: 5000 }}
345
- modules={[Autoplay]}
346
- loop={popup.filter(item => item.file_type === 'file_pc').length > 1}
347
- >
348
- {popup.length > 0 ? (
349
- popup
350
- .filter(
351
- (item: any) =>
352
- item.file_type === 'file_pc' &&
353
- isCurrentTimeWithinPopupRange(
354
- item.days,
355
- item.startHour,
356
- item.startMin,
357
- item.endHour,
358
- item.endMin
359
- )
360
- )
361
- .map((item: IBannerTypes, index: number) => {
362
- // {popup.length > 0 ? popup.filter((item: IBannerTypes) => item.file_type === 'file_pc').map((item: IBannerTypes, index: number) => {
363
- return (
364
- <SwiperSlide key={index}>
365
- <div className={style.header_banner_btn}>
366
- <button
367
- onClick={() => {
368
- filterClose(item.idx);
369
- addCookie(item.idx);
370
- }}
371
- >
372
- 하루동안 보지않기
373
- </button>
374
- <button
375
- onClick={() => {
376
- filterClose(item.idx);
377
- }}
378
- >
379
- <Image
380
- src="/images/banner_btn.webp"
381
- alt="대륜 배너 닫기 이미지"
382
- width={42}
383
- height={42}
384
- />
385
- </button>
386
- </div>
387
- <div
388
- className={style.banner_block}
389
- style={{ background: `#${item.color_code}` }}
390
- >
391
- <Link
392
- href={item.pc_link || item.p_link}
393
- target={item.link_type}
394
- onClick={() => {
395
- addClickCnt(item.idx);
396
- }}
397
- rel={validateUrl(item.p_link)}
398
- >
399
- <Image
400
- src={
401
- ImagePath +
402
- item.file_path +
403
- '/' +
404
- item.save_file_name
405
- }
406
- alt={item.file_alt}
407
- width={2000}
408
- height={60}
409
- priority={true}
410
- quality={100}
411
- loading={'eager'}
412
- />
413
- {/*<Image src={"/images/대표메인_팝업_PC.jpg"} alt={item.file_alt} width={1920} height={50} priority={true} />*/}
414
- </Link>
415
- </div>
416
- </SwiperSlide>
417
- );
418
- })
419
- ) : (
420
- <></>
421
- )}
422
- </Swiper>
423
- ) : (
424
- <></>
425
- )}
426
- </div>
427
- )}
428
-
429
- {/* mobile */}
430
- {width <= 900 && (
431
- <div
432
- className={classNames({
433
- [style.header_banner_m]: true
434
- })}
435
- >
436
- {popup && popup.filter(item => item.file_type === 'file_mobile').length > 0 ? (
437
- <Swiper
438
- autoplay={{ delay: 5000 }}
439
- modules={[Autoplay]}
440
- loop={popup.filter((item: IBannerTypes) => item.file_type === 'file_mobile').length > 1}
441
- >
442
- {popup.length > 0 ? (
443
- popup
444
- .filter((item: IBannerTypes) => item.file_type === 'file_mobile')
445
- .map((item: IBannerTypes, index: number) => {
446
- return (
447
- <SwiperSlide key={index}>
448
- <div className={style.header_banner_m_btn}>
449
- <button
450
- onClick={() => {
451
- filterClose(item.idx);
452
- addCookie(item.idx);
453
- }}
454
- >
455
- 하루동안 보지않기
456
- </button>
457
- <button
458
- onClick={() => {
459
- filterClose(item.idx);
460
- }}
461
- >
462
- 닫기
463
- </button>
464
- </div>
465
- <div className={style.banner_block_m}>
466
- <Link
467
- href={item.mobile_link || item.p_link}
468
- target={item.link_type}
469
- rel={validateUrl(item.p_link)}
470
- >
471
- <Image
472
- src={
473
- ImagePath +
474
- item.file_path +
475
- '/' +
476
- item.save_file_name
477
- }
478
- alt={item.file_alt}
479
- width={900}
480
- height={150}
481
- priority={true}
482
- onClick={() => {
483
- addClickCnt(item.idx);
484
- }}
485
- quality={100}
486
- />
487
- {/*<Image src={"/images/대표메인_팝업_900.jpg"} alt={item.file_alt} width={900} height={70} priority={true} />*/}
488
- </Link>
489
- </div>
490
- </SwiperSlide>
491
- );
492
- })
493
- ) : (
494
- <></>
495
- )}
496
- </Swiper>
497
- ) : (
498
- <></>
499
- )}
500
- </div>
501
- )}
502
- </div>
349
+ {/*pc*/}
350
+ {width > 900 && <PCTopBanner popup={popup} setPopup={setPopup} addClickCnt={addClickCnt} />}
351
+
352
+ {/*mobile*/}
353
+ {width <= 900 && mobileOpen && (
354
+ <MobileTopBanner popup={popup} setMobileOpen={setMobileOpen} addClickCnt={addClickCnt} />
355
+ )}
503
356
  </>
504
357
  );
505
358
  };
@@ -0,0 +1,3 @@
1
+ import { IBannerTypes } from './TopBanner';
2
+ export declare const isTopPopupMobileHidden: () => boolean;
3
+ export declare const tempData: IBannerTypes[];
@@ -0,0 +1,163 @@
1
+ export const isTopPopupMobileHidden = () => {
2
+ if (typeof window === 'undefined')
3
+ return false;
4
+ const hideUntil = localStorage.getItem('topPopupMobileHideUntil');
5
+ if (!hideUntil)
6
+ return false;
7
+ return Number(hideUntil) > Date.now();
8
+ };
9
+ // 임시데이터
10
+ export const tempData = [
11
+ {
12
+ idx: 89,
13
+ color_code: '',
14
+ days: ['월', '화', '수', '목', '금', '토', '일'],
15
+ end_at: '2026-01-16T13:26:00.000Z',
16
+ end_hour: 23,
17
+ end_min: 59,
18
+ file_alt: '법무법인대륜 상단 팝업이미지',
19
+ file_path: '/topBanner',
20
+ file_type: 'file_tab',
21
+ is_show: true,
22
+ link_type: '_blank',
23
+ p_link: 'https://www.daeryunlaw.com/suit/form?type=ST006',
24
+ p_sort: 4,
25
+ save_file_name: 'top_banner_01_tb.webp',
26
+ start_at: '2025-12-02T13:26:00.000Z',
27
+ start_hour: 0,
28
+ start_min: 0
29
+ },
30
+ {
31
+ idx: 89,
32
+ color_code: '',
33
+ days: ['월', '화', '수', '목', '금', '토', '일'],
34
+ end_at: '2026-01-16T13:26:00.000Z',
35
+ end_hour: 23,
36
+ end_min: 59,
37
+ file_alt: '법무법인대륜 상단 팝업이미지',
38
+ file_path: '/topBanner',
39
+ file_type: 'file_mobile',
40
+ is_show: true,
41
+ link_type: '_blank',
42
+ p_link: 'https://www.daeryunlaw.com/suit/form?type=ST006',
43
+ p_sort: 4,
44
+ save_file_name: 'top_banner_01_mo.webp',
45
+ start_at: '2025-12-02T13:26:00.000Z',
46
+ start_hour: 0,
47
+ start_min: 0
48
+ },
49
+ {
50
+ idx: 94,
51
+ color_code: '',
52
+ days: ['월', '화', '수', '목', '금', '토', '일'],
53
+ end_at: '2026-01-27T11:26:00.000Z',
54
+ end_hour: 23,
55
+ end_min: 59,
56
+ file_alt: '법무법인대륜 상단 팝업이미지',
57
+ file_path: '/topBanner',
58
+ file_type: 'file_tab',
59
+ is_show: true,
60
+ link_type: '_blank',
61
+ p_link: 'https://www.daeryunlaw.com/seminar/24',
62
+ p_sort: 3,
63
+ save_file_name: 'top_banner_02_tb.webp',
64
+ start_at: '2026-01-14T11:26:00.000Z',
65
+ start_hour: 0,
66
+ start_min: 0
67
+ },
68
+ {
69
+ idx: 94,
70
+ color_code: '',
71
+ days: ['월', '화', '수', '목', '금', '토', '일'],
72
+ end_at: '2026-01-27T11:26:00.000Z',
73
+ end_hour: 23,
74
+ end_min: 59,
75
+ file_alt: '법무법인대륜 상단 팝업이미지',
76
+ file_path: '/topBanner',
77
+ file_type: 'file_mobile',
78
+ is_show: true,
79
+ link_type: '_blank',
80
+ p_link: 'https://www.daeryunlaw.com/seminar/24',
81
+ p_sort: 3,
82
+ save_file_name: 'top_banner_02_mo.webp',
83
+ start_at: '2026-01-14T11:26:00.000Z',
84
+ start_hour: 0,
85
+ start_min: 0
86
+ },
87
+ {
88
+ idx: 93,
89
+ color_code: '',
90
+ days: ['월', '화', '수', '목', '금', '토', '일'],
91
+ end_at: '2026-01-29T16:35:00.000Z',
92
+ end_hour: 23,
93
+ end_min: 59,
94
+ file_alt: '법무법인대륜 상단 팝업이미지',
95
+ file_path: '/topBanner',
96
+ file_type: 'file_tab',
97
+ is_show: true,
98
+ link_type: '_blank',
99
+ p_link: 'https://www.daeryunlaw.com/notice/6038',
100
+ p_sort: 2,
101
+ save_file_name: 'top_banner_03_tb.webp',
102
+ start_at: '2026-01-14T16:35:00.000Z',
103
+ start_hour: 0,
104
+ start_min: 0
105
+ },
106
+ {
107
+ idx: 93,
108
+ color_code: '',
109
+ days: ['월', '화', '수', '목', '금', '토', '일'],
110
+ end_at: '2026-01-29T16:35:00.000Z',
111
+ end_hour: 23,
112
+ end_min: 59,
113
+ file_alt: '법무법인대륜 상단 팝업이미지',
114
+ file_path: '/topBanner',
115
+ file_type: 'file_mobile',
116
+ is_show: true,
117
+ link_type: '_blank',
118
+ p_link: 'https://www.daeryunlaw.com/notice/6038',
119
+ p_sort: 2,
120
+ save_file_name: 'top_banner_03_mo.webp',
121
+ start_at: '2026-01-14T16:35:00.000Z',
122
+ start_hour: 0,
123
+ start_min: 0
124
+ },
125
+ {
126
+ idx: 90,
127
+ color_code: '',
128
+ days: ['월', '화', '수', '목', '금', '토', '일'],
129
+ end_at: '2026-01-23T11:14:00.000Z',
130
+ end_hour: 23,
131
+ end_min: 59,
132
+ file_alt: '법무법인대륜 상단 팝업이미지',
133
+ file_path: '/topBanner',
134
+ file_type: 'file_tab',
135
+ is_show: true,
136
+ link_type: '_blank',
137
+ p_link: 'https://forms.gle/verSBoCxvqraQy68A',
138
+ p_sort: 1,
139
+ save_file_name: 'top_banner_04_tb.webp',
140
+ start_at: '2025-12-16T11:14:00.000Z',
141
+ start_hour: 0,
142
+ start_min: 0
143
+ },
144
+ {
145
+ idx: 90,
146
+ color_code: '',
147
+ days: ['월', '화', '수', '목', '금', '토', '일'],
148
+ end_at: '2026-01-23T11:14:00.000Z',
149
+ end_hour: 23,
150
+ end_min: 59,
151
+ file_alt: '법무법인대륜 상단 팝업이미지',
152
+ file_path: '/topBanner',
153
+ file_type: 'file_mobile',
154
+ is_show: true,
155
+ link_type: '_blank',
156
+ p_link: 'https://forms.gle/verSBoCxvqraQy68A',
157
+ p_sort: 1,
158
+ save_file_name: 'top_banner_04_mo.webp',
159
+ start_at: '2025-12-16T11:14:00.000Z',
160
+ start_hour: 0,
161
+ start_min: 0
162
+ }
163
+ ];
@@ -0,0 +1,167 @@
1
+ //모바일용 하루동안보지않기 판별
2
+ import { IBannerTypes } from './TopBanner'
3
+
4
+ export const isTopPopupMobileHidden = () => {
5
+ if (typeof window === 'undefined') return false
6
+
7
+ const hideUntil = localStorage.getItem('topPopupMobileHideUntil')
8
+ if (!hideUntil) return false
9
+
10
+ return Number(hideUntil) > Date.now()
11
+ }
12
+
13
+ // 임시데이터
14
+ export const tempData: IBannerTypes[] = [
15
+ {
16
+ idx: 89,
17
+ color_code: '',
18
+ days: ['월', '화', '수', '목', '금', '토', '일'],
19
+ end_at: '2026-01-16T13:26:00.000Z',
20
+ end_hour: 23,
21
+ end_min: 59,
22
+ file_alt: '법무법인대륜 상단 팝업이미지',
23
+ file_path: '/topBanner',
24
+ file_type: 'file_tab',
25
+ is_show: true,
26
+ link_type: '_blank',
27
+ p_link: 'https://www.daeryunlaw.com/suit/form?type=ST006',
28
+ p_sort: 4,
29
+ save_file_name: 'top_banner_01_tb.webp',
30
+ start_at: '2025-12-02T13:26:00.000Z',
31
+ start_hour: 0,
32
+ start_min: 0
33
+ },
34
+ {
35
+ idx: 89,
36
+ color_code: '',
37
+ days: ['월', '화', '수', '목', '금', '토', '일'],
38
+ end_at: '2026-01-16T13:26:00.000Z',
39
+ end_hour: 23,
40
+ end_min: 59,
41
+ file_alt: '법무법인대륜 상단 팝업이미지',
42
+ file_path: '/topBanner',
43
+ file_type: 'file_mobile',
44
+ is_show: true,
45
+ link_type: '_blank',
46
+ p_link: 'https://www.daeryunlaw.com/suit/form?type=ST006',
47
+ p_sort: 4,
48
+ save_file_name: 'top_banner_01_mo.webp',
49
+ start_at: '2025-12-02T13:26:00.000Z',
50
+ start_hour: 0,
51
+ start_min: 0
52
+ },
53
+ {
54
+ idx: 94,
55
+ color_code: '',
56
+ days: ['월', '화', '수', '목', '금', '토', '일'],
57
+ end_at: '2026-01-27T11:26:00.000Z',
58
+ end_hour: 23,
59
+ end_min: 59,
60
+ file_alt: '법무법인대륜 상단 팝업이미지',
61
+ file_path: '/topBanner',
62
+ file_type: 'file_tab',
63
+ is_show: true,
64
+ link_type: '_blank',
65
+ p_link: 'https://www.daeryunlaw.com/seminar/24',
66
+ p_sort: 3,
67
+ save_file_name: 'top_banner_02_tb.webp',
68
+ start_at: '2026-01-14T11:26:00.000Z',
69
+ start_hour: 0,
70
+ start_min: 0
71
+ },
72
+ {
73
+ idx: 94,
74
+ color_code: '',
75
+ days: ['월', '화', '수', '목', '금', '토', '일'],
76
+ end_at: '2026-01-27T11:26:00.000Z',
77
+ end_hour: 23,
78
+ end_min: 59,
79
+ file_alt: '법무법인대륜 상단 팝업이미지',
80
+ file_path: '/topBanner',
81
+ file_type: 'file_mobile',
82
+ is_show: true,
83
+ link_type: '_blank',
84
+ p_link: 'https://www.daeryunlaw.com/seminar/24',
85
+ p_sort: 3,
86
+ save_file_name: 'top_banner_02_mo.webp',
87
+ start_at: '2026-01-14T11:26:00.000Z',
88
+ start_hour: 0,
89
+ start_min: 0
90
+ },
91
+ {
92
+ idx: 93,
93
+ color_code: '',
94
+ days: ['월', '화', '수', '목', '금', '토', '일'],
95
+ end_at: '2026-01-29T16:35:00.000Z',
96
+ end_hour: 23,
97
+ end_min: 59,
98
+ file_alt: '법무법인대륜 상단 팝업이미지',
99
+ file_path: '/topBanner',
100
+ file_type: 'file_tab',
101
+ is_show: true,
102
+ link_type: '_blank',
103
+ p_link: 'https://www.daeryunlaw.com/notice/6038',
104
+ p_sort: 2,
105
+ save_file_name: 'top_banner_03_tb.webp',
106
+ start_at: '2026-01-14T16:35:00.000Z',
107
+ start_hour: 0,
108
+ start_min: 0
109
+ },
110
+ {
111
+ idx: 93,
112
+ color_code: '',
113
+ days: ['월', '화', '수', '목', '금', '토', '일'],
114
+ end_at: '2026-01-29T16:35:00.000Z',
115
+ end_hour: 23,
116
+ end_min: 59,
117
+ file_alt: '법무법인대륜 상단 팝업이미지',
118
+ file_path: '/topBanner',
119
+ file_type: 'file_mobile',
120
+ is_show: true,
121
+ link_type: '_blank',
122
+ p_link: 'https://www.daeryunlaw.com/notice/6038',
123
+ p_sort: 2,
124
+ save_file_name: 'top_banner_03_mo.webp',
125
+ start_at: '2026-01-14T16:35:00.000Z',
126
+ start_hour: 0,
127
+ start_min: 0
128
+ },
129
+ {
130
+ idx: 90,
131
+ color_code: '',
132
+ days: ['월', '화', '수', '목', '금', '토', '일'],
133
+ end_at: '2026-01-23T11:14:00.000Z',
134
+ end_hour: 23,
135
+ end_min: 59,
136
+ file_alt: '법무법인대륜 상단 팝업이미지',
137
+ file_path: '/topBanner',
138
+ file_type: 'file_tab',
139
+ is_show: true,
140
+ link_type: '_blank',
141
+ p_link: 'https://forms.gle/verSBoCxvqraQy68A',
142
+ p_sort: 1,
143
+ save_file_name: 'top_banner_04_tb.webp',
144
+ start_at: '2025-12-16T11:14:00.000Z',
145
+ start_hour: 0,
146
+ start_min: 0
147
+ },
148
+ {
149
+ idx: 90,
150
+ color_code: '',
151
+ days: ['월', '화', '수', '목', '금', '토', '일'],
152
+ end_at: '2026-01-23T11:14:00.000Z',
153
+ end_hour: 23,
154
+ end_min: 59,
155
+ file_alt: '법무법인대륜 상단 팝업이미지',
156
+ file_path: '/topBanner',
157
+ file_type: 'file_mobile',
158
+ is_show: true,
159
+ link_type: '_blank',
160
+ p_link: 'https://forms.gle/verSBoCxvqraQy68A',
161
+ p_sort: 1,
162
+ save_file_name: 'top_banner_04_mo.webp',
163
+ start_at: '2025-12-16T11:14:00.000Z',
164
+ start_hour: 0,
165
+ start_min: 0
166
+ }
167
+ ]
@@ -2,7 +2,7 @@ export declare const getSearchKeywordJson: (searchKeywords: {
2
2
  code_name: string;
3
3
  survey_title: string;
4
4
  }[]) => {
5
- [key: string]: string[];
5
+ [x: string]: string[];
6
6
  };
7
7
  export declare const tabTypes: {
8
8
  tab: string;
@@ -85,12 +85,15 @@ const BasicInfo = ({ lawyerInfo, codeList, centerCode, isUseWrapper, integrateSe
85
85
  <span className={'mb-1 block whitespace-pre-line text-[70px] font-[800] leading-[1.14] tracking-[-0.9px] max-xl:text-[64px] max-lg:text-[56px] max-md2:mb-0 max-md2:text-[48px] max-xs:text-[40px] '}>
86
86
  {searchColorLawyerText(lawyerInfo.l_name.replace(/\(/g, '\n('), integrateSearch)}
87
87
  </span>
88
- {lawyerInfo.l_position ? (<span className={'text-[28px] font-[500] leading-[1.42] tracking-[-0.7px] ' +
88
+ {lawyerInfo.l_position ? (<span className={'whitespace-pre-wrap ' +
89
+ 'text-[28px] font-[600] leading-[1.42] tracking-[-0.7px] ' +
89
90
  'max-xl:text-[26px] ' +
90
91
  'max-lg:text-[24px] ' +
91
92
  'max-md2:text-[22px] '}>
92
93
  &nbsp;
93
- {searchColorLawyerText(lawyerInfo.l_position, integrateSearch)}
94
+ {searchColorLawyerText(lawyerInfo.l_position.length >= 20
95
+ ? lawyerInfo.l_position.replace(/\//g, '/\n')
96
+ : lawyerInfo.l_position, integrateSearch)}
94
97
  </span>) : (<></>)}
95
98
 
96
99
  {lawyerInfo.l_introduce_shorts && (<div className={'flex h-[49px] w-[189px] cursor-pointer items-center justify-center gap-[4px] rounded-[24.5px] bg-[#fff] text-[22px] font-[600]'} onClick={() => {
@@ -152,15 +155,19 @@ const BasicInfo = ({ lawyerInfo, codeList, centerCode, isUseWrapper, integrateSe
152
155
  <Image src={YoutubeArrow} alt={'유튜브'} width={13} height={14} className={'h-[14px]'}/>
153
156
  </div>
154
157
  </div>
155
- {lawyerInfo.l_position && (<span className={'mt-2 block text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'}>
156
- {searchColorLawyerText(lawyerInfo.l_position, integrateSearch)}
158
+ {lawyerInfo.l_position && (<span className={'mt-2 block whitespace-pre-wrap text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'}>
159
+ {searchColorLawyerText(lawyerInfo.l_position.length >= 20
160
+ ? lawyerInfo.l_position.replace(/\//g, '/\n')
161
+ : lawyerInfo.l_position, integrateSearch)}
157
162
  </span>)}
158
163
  </>) : (<>
159
164
  <span className={'block whitespace-nowrap text-[50px] font-[800] leading-[1.14] tracking-[-0.9px] max-md:text-[46px] max-xs:text-[40px]'}>
160
165
  {searchColorLawyerText(lawyerInfo.l_name, integrateSearch)}
161
166
  </span>
162
- {lawyerInfo.l_position && (<span className={'mt-2 block text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'}>
163
- {searchColorLawyerText(lawyerInfo.l_position, integrateSearch)}
167
+ {lawyerInfo.l_position && (<span className={'mt-2 block whitespace-pre-wrap text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'}>
168
+ {searchColorLawyerText(lawyerInfo.l_position.length >= 20
169
+ ? lawyerInfo.l_position.replace(/\//g, '/\n')
170
+ : lawyerInfo.l_position, integrateSearch)}
164
171
  </span>)}
165
172
  </>)}
166
173
  </div>
@@ -155,14 +155,20 @@ const BasicInfo = ({
155
155
  {lawyerInfo.l_position ? (
156
156
  <span
157
157
  className={
158
- 'text-[28px] font-[500] leading-[1.42] tracking-[-0.7px] ' +
158
+ 'whitespace-pre-wrap ' +
159
+ 'text-[28px] font-[600] leading-[1.42] tracking-[-0.7px] ' +
159
160
  'max-xl:text-[26px] ' +
160
161
  'max-lg:text-[24px] ' +
161
162
  'max-md2:text-[22px] '
162
163
  }
163
164
  >
164
165
  &nbsp;
165
- {searchColorLawyerText(lawyerInfo.l_position, integrateSearch)}
166
+ {searchColorLawyerText(
167
+ lawyerInfo.l_position.length >= 20
168
+ ? lawyerInfo.l_position.replace(/\//g, '/\n')
169
+ : lawyerInfo.l_position,
170
+ integrateSearch
171
+ )}
166
172
  </span>
167
173
  ) : (
168
174
  <></>
@@ -314,10 +320,15 @@ const BasicInfo = ({
314
320
  {lawyerInfo.l_position && (
315
321
  <span
316
322
  className={
317
- 'mt-2 block text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'
323
+ 'mt-2 block whitespace-pre-wrap text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'
318
324
  }
319
325
  >
320
- {searchColorLawyerText(lawyerInfo.l_position, integrateSearch)}
326
+ {searchColorLawyerText(
327
+ lawyerInfo.l_position.length >= 20
328
+ ? lawyerInfo.l_position.replace(/\//g, '/\n')
329
+ : lawyerInfo.l_position,
330
+ integrateSearch
331
+ )}
321
332
  </span>
322
333
  )}
323
334
  </>
@@ -333,10 +344,15 @@ const BasicInfo = ({
333
344
  {lawyerInfo.l_position && (
334
345
  <span
335
346
  className={
336
- 'mt-2 block text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'
347
+ 'mt-2 block whitespace-pre-wrap text-[22px] font-[600] leading-[1.42] tracking-[-0.7px] max-xs:text-[20px]'
337
348
  }
338
349
  >
339
- {searchColorLawyerText(lawyerInfo.l_position, integrateSearch)}
350
+ {searchColorLawyerText(
351
+ lawyerInfo.l_position.length >= 20
352
+ ? lawyerInfo.l_position.replace(/\//g, '/\n')
353
+ : lawyerInfo.l_position,
354
+ integrateSearch
355
+ )}
340
356
  </span>
341
357
  )}
342
358
  </>