@daeryun/dr_components 0.1.96 → 0.1.97

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 (45) hide show
  1. package/dist/cjs/tsconfig-cjs.tsbuildinfo +1 -1
  2. package/dist/components/CountingSection/CountingSection.jsx +6 -0
  3. package/dist/components/CountingSection/CountingSection.tsx +6 -0
  4. package/dist/components/MapFix/MapFix.stories.jsx +0 -1
  5. package/dist/components/MapFix/MapFix.stories.tsx +0 -1
  6. package/dist/components/page/index.d.ts +0 -1
  7. package/dist/components/page/index.js +0 -1
  8. package/dist/components/page/index.ts +0 -1
  9. package/dist/lib/utils.d.ts +0 -2
  10. package/dist/lib/utils.js +0 -23
  11. package/dist/lib/utils.ts +0 -25
  12. package/dist/styles/globals.css +0 -699
  13. package/dist/tsconfig.tsbuildinfo +1 -1
  14. package/package.json +2 -2
  15. package/dist/asset/images/strength/01.webp +0 -0
  16. package/dist/asset/images/strength/010.webp +0 -0
  17. package/dist/asset/images/strength/011.webp +0 -0
  18. package/dist/asset/images/strength/02.webp +0 -0
  19. package/dist/asset/images/strength/03.webp +0 -0
  20. package/dist/asset/images/strength/04.webp +0 -0
  21. package/dist/asset/images/strength/05.webp +0 -0
  22. package/dist/asset/images/strength/06.webp +0 -0
  23. package/dist/asset/images/strength/07.webp +0 -0
  24. package/dist/asset/images/strength/08.webp +0 -0
  25. package/dist/asset/images/strength/09.webp +0 -0
  26. package/dist/asset/images/strength/arrow.webp +0 -0
  27. package/dist/asset/images/strength/bg.webp +0 -0
  28. package/dist/asset/images/strength/mo.webp +0 -0
  29. package/dist/asset/images/strength/red_arrow.webp +0 -0
  30. package/dist/asset/images/strength/tb.webp +0 -0
  31. package/dist/components/common/strength/index.d.ts +0 -8
  32. package/dist/components/common/strength/index.js +0 -184
  33. package/dist/components/common/strength/index.ts +0 -185
  34. package/dist/components/page/Strength/Strength.d.ts +0 -5
  35. package/dist/components/page/Strength/Strength.jsx +0 -9
  36. package/dist/components/page/Strength/Strength.stories.d.ts +0 -6
  37. package/dist/components/page/Strength/Strength.stories.jsx +0 -54
  38. package/dist/components/page/Strength/Strength.stories.tsx +0 -61
  39. package/dist/components/page/Strength/Strength.tsx +0 -13
  40. package/dist/components/page/Strength/StrengthIntro.d.ts +0 -6
  41. package/dist/components/page/Strength/StrengthIntro.jsx +0 -247
  42. package/dist/components/page/Strength/StrengthIntro.tsx +0 -355
  43. package/dist/components/page/Strength/StrengthList.d.ts +0 -6
  44. package/dist/components/page/Strength/StrengthList.jsx +0 -106
  45. package/dist/components/page/Strength/StrengthList.tsx +0 -189
@@ -1,106 +0,0 @@
1
- import React from 'react';
2
- import Image from 'next/image';
3
- import useBrowser from '../../common/hook/useBrowser';
4
- import { strengthList } from '../../common/strength';
5
- import { replaceInitialData } from '../../../lib';
6
- const StrengthList = ({ initialData }) => {
7
- const { width } = useBrowser();
8
- return (<section className={'max-md: relative flex w-full flex-col gap-[220px] overflow-hidden pb-[220px] pt-[240px] ' +
9
- 'max-3xl:gap-[180px] ' +
10
- 'max-lg:gap-[136px] max-lg:pb-[100px] max-lg:pt-[140px] ' +
11
- 'max-md:gap-[56px] max-md:pb-20 max-md:pt-[58px]'}>
12
- {strengthList.map((item, index) => {
13
- const isOdd = width > 1023 ? (index + 1) % 2 !== 0 : true;
14
- return (<div key={index}>
15
- <div className={'relative mx-auto flex w-full max-w-[1920px] gap-[60px] px-[190px] ' +
16
- 'max-3xl:gap-[40px] max-3xl:px-[80px] ' +
17
- 'max-lg:flex-col max-lg:gap-[36px] max-lg:px-[60px] ' +
18
- 'max-md2:px-[40px] ' +
19
- 'max-md:gap-[18px] ' +
20
- 'max-2sm:px-[20px] '}>
21
- {/*이미지*/}
22
- <div className={'w-full ' + (isOdd ? 'flex justify-end max-lg:justify-center' : '')}>
23
- {isOdd ? (<ImageSection index={index}/>) : (<ListSection initialData={initialData} item={item} index={index}/>)}
24
- </div>
25
-
26
- <div className={'w-[48.6%] shrink-0 max-lg:w-full'}>
27
- {isOdd ? (<ListSection initialData={initialData} item={item} index={index}/>) : (<ImageSection index={index}/>)}
28
- </div>
29
- </div>
30
- </div>);
31
- })}
32
- </section>);
33
- };
34
- export default StrengthList;
35
- const ImageSection = ({ index }) => {
36
- const isOdd = (index + 1) % 2 !== 0;
37
- return (<>
38
- <div className={'relative z-20 h-[400px] w-full max-w-[740px] max-3xl:h-[300px] max-lg:h-[400px] max-lg:max-w-[unset] max-md2:h-[300px] max-md:h-[250px] max-xs:h-[180px] '}>
39
- <span className={'absolute -top-10 z-10 flex h-20 w-20 items-center justify-center bg-[#AB0634] text-[40px] font-[800] leading-none tracking-[-0.8px] text-white ' +
40
- 'max-3xl:top-[-28px] max-3xl:h-14 max-3xl:w-14 max-3xl:text-[24px] ' +
41
- 'max-lg:h-20 max-lg:w-20 max-lg:text-[40px] ' +
42
- 'max-md2:top-[-28px] max-md2:h-14 max-md2:w-14 max-md2:text-[24px] ' +
43
- 'max-md:top-[-24px] max-md:h-12 max-md:w-12 max-md:text-[22px] ' +
44
- 'max-xs:top-[-18px] max-xs:h-9 max-xs:w-9 max-xs:text-[16px] ' +
45
- (isOdd
46
- ? 'left-10 max-3xl:left-[28px] max-lg:left-10 max-md2:left-[28px] max-md:left-[24px] max-xs:left-4 '
47
- : 'right-10 max-3xl:right-[28px] max-lg:right-10 max-md2:right-[28px] max-md:right-[24px] max-xs:right-4')}>
48
- {index < 9 ? `0${index + 1}` : index + 1}
49
- </span>
50
- <Image id={`strength_${index}_img`} src={`https://d1tgonli21s4df.cloudfront.net/strength/0${index + 1}.webp`} alt={'강점 배경 ' + (index + 1)} fill className={'object-cover'}/>
51
- </div>
52
- </>);
53
- };
54
- const ListSection = ({ initialData, item, index }) => {
55
- const isOdd = (index + 1) % 2 !== 0;
56
- return (<>
57
- <h2 id={`strength_${index}`} className={'mb-4 text-[24px] font-[800] tracking-[-0.96px] text-[#AB0634] ' +
58
- 'max-4xl:text-[22px] ' +
59
- 'max-xxl:text-[20px] ' +
60
- 'max-md:mb-3 max-md:text-[18px] max-md:tracking-[-0.72px] '}>
61
- {replaceInitialData(item.subTitle, initialData)}
62
- </h2>
63
- <p className={'mb-10 break-keep text-[32px] font-[800] leading-[1.33] tracking-[-1.28px] md:whitespace-pre-wrap ' +
64
- (index === 9 || index === 10
65
- ? ' w-full tracking-[-1.6px] '
66
- : index === 5
67
- ? 'tracking-[-1.28px] 4xl:w-[85%] '
68
- : ' tracking-[-1.28px] 4xl:w-[90%] ') +
69
- 'max-4xl:text-[28px] ' +
70
- 'max-xxl:text-[25px] ' +
71
- 'max-lg:text-[32px] ' +
72
- 'max-md2:text-[28px] ' +
73
- 'max-md:mb-7 max-md:text-[24px] max-md:tracking-[-0.96px]'}>
74
- {item.title}
75
- </p>
76
- <div className={'relative flex min-h-[285px] flex-col gap-11 bg-[#F5F5F5] py-[40px] max-3xl:min-h-[210px] max-lg:min-h-[unset] max-md:gap-[23px] max-md:py-[30px]'}>
77
- {/*배경*/}
78
- <div className={'absolute top-0 h-full w-[300vw] translate-x-[-50%] bg-[#F5F5F5]'}></div>
79
- {item.list.map((list, index) => {
80
- return (<span key={index} className={'relative z-10 break-keep'}>
81
- {list.liTitle.length > 0 ? (<h3 className={'mb-[22px] text-[24px] font-bold leading-tight tracking-[-0.96px] ' +
82
- 'max-4xl:text-[22px] ' +
83
- 'max-xxl:text-[20px] ' +
84
- 'max-lg:text-[24px] ' +
85
- 'max-md2:text-[20px] ' +
86
- 'max-md:mb-[16px] max-md:tracking-[-1px]'}>
87
- {replaceInitialData(list.liTitle, initialData)}
88
- </h3>) : (<></>)}
89
-
90
- <ul key={'ul_' + index} className={(isOdd ? 'w-[96.5%]' : '') + ' list-outside list-["-__"] pl-[22px]'}>
91
- {list.li.map((liItem, index) => {
92
- return (<li key={'li_' + index} className={'list-item pb-1 text-[24px] tracking-[-0.96px] lg:whitespace-pre-wrap ' +
93
- 'max-4xl:text-[20px] ' +
94
- 'max-xxl:text-[18px] ' +
95
- 'max-lg:text-[20px] ' +
96
- 'max-md2:text-[18px] ' +
97
- 'max-md:text-[16px] max-md:tracking-[-0.64px]'}>
98
- {replaceInitialData(liItem, initialData)}
99
- </li>);
100
- })}
101
- </ul>
102
- </span>);
103
- })}
104
- </div>
105
- </>);
106
- };
@@ -1,189 +0,0 @@
1
- import React, { useEffect, useRef, useState } from 'react';
2
- import Image from 'next/image';
3
- import useBrowser from '../../common/hook/useBrowser';
4
- import { IInitialDataTypes } from '../../common';
5
- import { strengthList } from '../../common/strength';
6
- import { replaceInitialData } from '../../../lib';
7
- const StrengthList = ({ initialData }: { initialData: IInitialDataTypes }) => {
8
- const { width } = useBrowser();
9
- return (
10
- <section
11
- className={
12
- 'max-md: relative flex w-full flex-col gap-[220px] overflow-hidden pb-[220px] pt-[240px] ' +
13
- 'max-3xl:gap-[180px] ' +
14
- 'max-lg:gap-[136px] max-lg:pb-[100px] max-lg:pt-[140px] ' +
15
- 'max-md:gap-[56px] max-md:pb-20 max-md:pt-[58px]'
16
- }
17
- >
18
- {strengthList.map((item, index) => {
19
- const isOdd = width > 1023 ? (index + 1) % 2 !== 0 : true;
20
-
21
- return (
22
- <div key={index}>
23
- <div
24
- className={
25
- 'relative mx-auto flex w-full max-w-[1920px] gap-[60px] px-[190px] ' +
26
- 'max-3xl:gap-[40px] max-3xl:px-[80px] ' +
27
- 'max-lg:flex-col max-lg:gap-[36px] max-lg:px-[60px] ' +
28
- 'max-md2:px-[40px] ' +
29
- 'max-md:gap-[18px] ' +
30
- 'max-2sm:px-[20px] '
31
- }
32
- >
33
- {/*이미지*/}
34
- <div className={'w-full ' + (isOdd ? 'flex justify-end max-lg:justify-center' : '')}>
35
- {isOdd ? (
36
- <ImageSection index={index} />
37
- ) : (
38
- <ListSection initialData={initialData} item={item} index={index} />
39
- )}
40
- </div>
41
-
42
- <div className={'w-[48.6%] shrink-0 max-lg:w-full'}>
43
- {isOdd ? (
44
- <ListSection initialData={initialData} item={item} index={index} />
45
- ) : (
46
- <ImageSection index={index} />
47
- )}
48
- </div>
49
- </div>
50
- </div>
51
- );
52
- })}
53
- </section>
54
- );
55
- };
56
-
57
- export default StrengthList;
58
-
59
- const ImageSection = ({ index }: { index: number }) => {
60
- const isOdd = (index + 1) % 2 !== 0;
61
- return (
62
- <>
63
- <div
64
- className={
65
- 'relative z-20 h-[400px] w-full max-w-[740px] max-3xl:h-[300px] max-lg:h-[400px] max-lg:max-w-[unset] max-md2:h-[300px] max-md:h-[250px] max-xs:h-[180px] '
66
- }
67
- >
68
- <span
69
- className={
70
- 'absolute -top-10 z-10 flex h-20 w-20 items-center justify-center bg-[#AB0634] text-[40px] font-[800] leading-none tracking-[-0.8px] text-white ' +
71
- 'max-3xl:top-[-28px] max-3xl:h-14 max-3xl:w-14 max-3xl:text-[24px] ' +
72
- 'max-lg:h-20 max-lg:w-20 max-lg:text-[40px] ' +
73
- 'max-md2:top-[-28px] max-md2:h-14 max-md2:w-14 max-md2:text-[24px] ' +
74
- 'max-md:top-[-24px] max-md:h-12 max-md:w-12 max-md:text-[22px] ' +
75
- 'max-xs:top-[-18px] max-xs:h-9 max-xs:w-9 max-xs:text-[16px] ' +
76
- (isOdd
77
- ? 'left-10 max-3xl:left-[28px] max-lg:left-10 max-md2:left-[28px] max-md:left-[24px] max-xs:left-4 '
78
- : 'right-10 max-3xl:right-[28px] max-lg:right-10 max-md2:right-[28px] max-md:right-[24px] max-xs:right-4')
79
- }
80
- >
81
- {index < 9 ? `0${index + 1}` : index + 1}
82
- </span>
83
- <Image
84
- id={`strength_${index}_img`}
85
- src={`https://d1tgonli21s4df.cloudfront.net/strength/0${index + 1}.webp`}
86
- alt={'강점 배경 ' + (index + 1)}
87
- fill
88
- className={'object-cover'}
89
- />
90
- </div>
91
- </>
92
- );
93
- };
94
- const ListSection = ({
95
- initialData,
96
- item,
97
- index
98
- }: {
99
- index: number;
100
- initialData: IInitialDataTypes;
101
- item: { subTitle: string; title: string; list: { liTitle: string; li: string[] }[] };
102
- }) => {
103
- const isOdd = (index + 1) % 2 !== 0;
104
- return (
105
- <>
106
- <h2
107
- id={`strength_${index}`}
108
- className={
109
- 'mb-4 text-[24px] font-[800] tracking-[-0.96px] text-[#AB0634] ' +
110
- 'max-4xl:text-[22px] ' +
111
- 'max-xxl:text-[20px] ' +
112
- 'max-md:mb-3 max-md:text-[18px] max-md:tracking-[-0.72px] '
113
- }
114
- >
115
- {replaceInitialData(item.subTitle, initialData)}
116
- </h2>
117
- <p
118
- className={
119
- 'mb-10 break-keep text-[32px] font-[800] leading-[1.33] tracking-[-1.28px] md:whitespace-pre-wrap ' +
120
- (index === 9 || index === 10
121
- ? ' w-full tracking-[-1.6px] '
122
- : index === 5
123
- ? 'tracking-[-1.28px] 4xl:w-[85%] '
124
- : ' tracking-[-1.28px] 4xl:w-[90%] ') +
125
- 'max-4xl:text-[28px] ' +
126
- 'max-xxl:text-[25px] ' +
127
- 'max-lg:text-[32px] ' +
128
- 'max-md2:text-[28px] ' +
129
- 'max-md:mb-7 max-md:text-[24px] max-md:tracking-[-0.96px]'
130
- }
131
- >
132
- {item.title}
133
- </p>
134
- <div
135
- className={
136
- 'relative flex min-h-[285px] flex-col gap-11 bg-[#F5F5F5] py-[40px] max-3xl:min-h-[210px] max-lg:min-h-[unset] max-md:gap-[23px] max-md:py-[30px]'
137
- }
138
- >
139
- {/*배경*/}
140
- <div className={'absolute top-0 h-full w-[300vw] translate-x-[-50%] bg-[#F5F5F5]'}></div>
141
- {item.list.map((list, index) => {
142
- return (
143
- <span key={index} className={'relative z-10 break-keep'}>
144
- {list.liTitle.length > 0 ? (
145
- <h3
146
- className={
147
- 'mb-[22px] text-[24px] font-bold leading-tight tracking-[-0.96px] ' +
148
- 'max-4xl:text-[22px] ' +
149
- 'max-xxl:text-[20px] ' +
150
- 'max-lg:text-[24px] ' +
151
- 'max-md2:text-[20px] ' +
152
- 'max-md:mb-[16px] max-md:tracking-[-1px]'
153
- }
154
- >
155
- {replaceInitialData(list.liTitle, initialData)}
156
- </h3>
157
- ) : (
158
- <></>
159
- )}
160
-
161
- <ul
162
- key={'ul_' + index}
163
- className={(isOdd ? 'w-[96.5%]' : '') + ' list-outside list-["-__"] pl-[22px]'}
164
- >
165
- {list.li.map((liItem, index) => {
166
- return (
167
- <li
168
- key={'li_' + index}
169
- className={
170
- 'list-item pb-1 text-[24px] tracking-[-0.96px] lg:whitespace-pre-wrap ' +
171
- 'max-4xl:text-[20px] ' +
172
- 'max-xxl:text-[18px] ' +
173
- 'max-lg:text-[20px] ' +
174
- 'max-md2:text-[18px] ' +
175
- 'max-md:text-[16px] max-md:tracking-[-0.64px]'
176
- }
177
- >
178
- {replaceInitialData(liItem, initialData)}
179
- </li>
180
- );
181
- })}
182
- </ul>
183
- </span>
184
- );
185
- })}
186
- </div>
187
- </>
188
- );
189
- };