@daeryun/dr_components 0.2.15 → 0.2.17
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.
- package/dist/cjs/tsconfig-cjs.tsbuildinfo +1 -1
- package/dist/components/BrochureBtn/BrochureBtn.d.ts +1 -0
- package/dist/components/BrochureBtn/BrochureBtn.jsx +5 -4
- package/dist/components/BrochureBtn/BrochureBtn.stories.d.ts +1 -0
- package/dist/components/BrochureBtn/BrochureBtn.tsx +12 -5
- package/dist/components/Fix/index.jsx +2 -2
- package/dist/components/Fix/index.tsx +8 -1
- package/dist/components/Footer/Footer.stories.jsx +2 -1
- package/dist/components/Footer/Footer.stories.tsx +2 -1
- package/dist/components/Footer/IFooterTypes.d.ts +1 -0
- package/dist/components/Footer/IFooterTypes.ts +1 -0
- package/dist/components/Footer/index.d.ts +1 -1
- package/dist/components/Footer/index.jsx +4 -4
- package/dist/components/Footer/index.tsx +4 -1
- package/dist/components/Header/Header.d.ts +1 -1
- package/dist/components/Header/Header.jsx +2 -2
- package/dist/components/Header/Header.tsx +5 -1
- package/dist/components/Header/Menu.d.ts +1 -1
- package/dist/components/Header/Menu.jsx +3 -3
- package/dist/components/Header/Menu.tsx +15 -1
- package/dist/components/Header/MobileMenu.d.ts +1 -1
- package/dist/components/Header/MobileMenu.jsx +2 -2
- package/dist/components/Header/MobileMenu.tsx +3 -1
- package/dist/components/Header/PCMenu.d.ts +1 -1
- package/dist/components/Header/PCMenu.jsx +2 -2
- package/dist/components/Header/PCMenu.tsx +7 -2
- package/dist/lib/utils.d.ts +1 -0
- package/dist/lib/utils.js +9 -0
- package/dist/lib/utils.ts +10 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/header.d.ts +4 -0
- package/dist/types/header.ts +4 -0
- package/package.json +1 -1
|
@@ -26,7 +26,9 @@ const Header = ({
|
|
|
26
26
|
keywordArr,
|
|
27
27
|
categoryType,
|
|
28
28
|
doNotWrite,
|
|
29
|
-
name
|
|
29
|
+
name,
|
|
30
|
+
isBrochureBtn,
|
|
31
|
+
isMedical
|
|
30
32
|
}: IHeaderType) => {
|
|
31
33
|
const router = useRouter();
|
|
32
34
|
const mobile = require('is-mobile');
|
|
@@ -255,6 +257,8 @@ const Header = ({
|
|
|
255
257
|
tel={tel}
|
|
256
258
|
logo={logo}
|
|
257
259
|
keywordArr={keywordArr}
|
|
260
|
+
isBrochureBtn={isBrochureBtn}
|
|
261
|
+
isMedical={isMedical}
|
|
258
262
|
/>
|
|
259
263
|
|
|
260
264
|
{!menuToggle && (
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IMenuType } from '../../types/header';
|
|
3
|
-
declare const Menu: ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo }: IMenuType) => React.JSX.Element;
|
|
3
|
+
declare const Menu: ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo, isBrochureBtn, isMedical }: IMenuType) => React.JSX.Element;
|
|
4
4
|
export default Menu;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import MobileMenu from './MobileMenu';
|
|
3
3
|
import PCMenu from './PCMenu';
|
|
4
|
-
const Menu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo }) => {
|
|
4
|
+
const Menu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo, isBrochureBtn, isMedical }) => {
|
|
5
5
|
return (<>
|
|
6
|
-
<MobileMenu logo={logo} handleMenuToggle={handleMenuToggle} opacity={opacity} menuToggle={menuToggle} routes={routes} tel={tel} keywordArr={keywordArr}/>
|
|
7
|
-
<PCMenu handleMenuToggle={handleMenuToggle} opacity={opacity} menuToggle={menuToggle} routes={routes} tel={tel}/>
|
|
6
|
+
<MobileMenu logo={logo} handleMenuToggle={handleMenuToggle} opacity={opacity} menuToggle={menuToggle} routes={routes} tel={tel} keywordArr={keywordArr} isBrochureBtn={isBrochureBtn} isMedical={isMedical}/>
|
|
7
|
+
<PCMenu handleMenuToggle={handleMenuToggle} opacity={opacity} menuToggle={menuToggle} routes={routes} tel={tel} isBrochureBtn={isBrochureBtn} isMedical={isMedical}/>
|
|
8
8
|
</>);
|
|
9
9
|
};
|
|
10
10
|
export default Menu;
|
|
@@ -3,7 +3,17 @@ import MobileMenu from './MobileMenu';
|
|
|
3
3
|
import PCMenu from './PCMenu';
|
|
4
4
|
import { IMenuType } from '../../types/header';
|
|
5
5
|
|
|
6
|
-
const Menu = ({
|
|
6
|
+
const Menu = ({
|
|
7
|
+
handleMenuToggle,
|
|
8
|
+
opacity,
|
|
9
|
+
menuToggle,
|
|
10
|
+
routes,
|
|
11
|
+
tel,
|
|
12
|
+
keywordArr,
|
|
13
|
+
logo,
|
|
14
|
+
isBrochureBtn,
|
|
15
|
+
isMedical
|
|
16
|
+
}: IMenuType) => {
|
|
7
17
|
return (
|
|
8
18
|
<>
|
|
9
19
|
<MobileMenu
|
|
@@ -14,6 +24,8 @@ const Menu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr,
|
|
|
14
24
|
routes={routes}
|
|
15
25
|
tel={tel}
|
|
16
26
|
keywordArr={keywordArr}
|
|
27
|
+
isBrochureBtn={isBrochureBtn}
|
|
28
|
+
isMedical={isMedical}
|
|
17
29
|
/>
|
|
18
30
|
<PCMenu
|
|
19
31
|
handleMenuToggle={handleMenuToggle}
|
|
@@ -21,6 +33,8 @@ const Menu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr,
|
|
|
21
33
|
menuToggle={menuToggle}
|
|
22
34
|
routes={routes}
|
|
23
35
|
tel={tel}
|
|
36
|
+
isBrochureBtn={isBrochureBtn}
|
|
37
|
+
isMedical={isMedical}
|
|
24
38
|
/>
|
|
25
39
|
</>
|
|
26
40
|
);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IMobileMenuType } from '../../types/header';
|
|
3
|
-
declare const MobileMenu: ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo, isBrochureBtn }: IMobileMenuType) => React.JSX.Element;
|
|
3
|
+
declare const MobileMenu: ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo, isBrochureBtn, isMedical }: IMobileMenuType) => React.JSX.Element;
|
|
4
4
|
export default MobileMenu;
|
|
@@ -12,7 +12,7 @@ import M_right from '../../asset/images/header/m_right.webp';
|
|
|
12
12
|
import Call from '../../asset/images/header/h_call_line_b.webp';
|
|
13
13
|
import { blankArr } from '../../types/header';
|
|
14
14
|
import BrochureBtn from '../BrochureBtn/BrochureBtn';
|
|
15
|
-
const MobileMenu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo, isBrochureBtn }) => {
|
|
15
|
+
const MobileMenu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywordArr, logo, isBrochureBtn, isMedical }) => {
|
|
16
16
|
const router = useRouter();
|
|
17
17
|
const mobile = require('is-mobile');
|
|
18
18
|
const [isMobile, setIsMobile] = useState(false);
|
|
@@ -199,7 +199,7 @@ const MobileMenu = ({ handleMenuToggle, opacity, menuToggle, routes, tel, keywor
|
|
|
199
199
|
<Image src={Call} width={57} height={57} alt={'전화상담'} className={'h-auto w-[30px]'}/>
|
|
200
200
|
{tel}
|
|
201
201
|
</Link>
|
|
202
|
-
{isBrochureBtn ? (<BrochureBtn width={'280px'} height={'58px'} className={'scale-75 max-md:-mx-[23px] max-xs:scale-[0.7] max-2xs:-mx-[15px] max-2xs:mt-1 '}/>) : (<></>)}
|
|
202
|
+
{isBrochureBtn ? (<BrochureBtn width={'280px'} height={'58px'} className={'scale-75 max-md:-mx-[23px] max-xs:scale-[0.7] max-2xs:-mx-[15px] max-2xs:mt-1 '} isMedical={isMedical}/>) : (<></>)}
|
|
203
203
|
</div>
|
|
204
204
|
</nav>
|
|
205
205
|
</span>
|
|
@@ -21,7 +21,8 @@ const MobileMenu = ({
|
|
|
21
21
|
tel,
|
|
22
22
|
keywordArr,
|
|
23
23
|
logo,
|
|
24
|
-
isBrochureBtn
|
|
24
|
+
isBrochureBtn,
|
|
25
|
+
isMedical
|
|
25
26
|
}: IMobileMenuType) => {
|
|
26
27
|
const router = useRouter();
|
|
27
28
|
const mobile = require('is-mobile');
|
|
@@ -355,6 +356,7 @@ const MobileMenu = ({
|
|
|
355
356
|
className={
|
|
356
357
|
'scale-75 max-md:-mx-[23px] max-xs:scale-[0.7] max-2xs:-mx-[15px] max-2xs:mt-1 '
|
|
357
358
|
}
|
|
359
|
+
isMedical={isMedical}
|
|
358
360
|
/>
|
|
359
361
|
) : (
|
|
360
362
|
<></>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { IPcMenuType } from '../../types/header';
|
|
3
|
-
declare const PCMenu: ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochureBtn }: IPcMenuType) => React.JSX.Element;
|
|
3
|
+
declare const PCMenu: ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochureBtn, isMedical }: IPcMenuType) => React.JSX.Element;
|
|
4
4
|
export default PCMenu;
|
|
@@ -10,7 +10,7 @@ import Menu from '../../asset/images/header/menu_x.webp';
|
|
|
10
10
|
import Window from '../../asset/images/header/image_b.webp';
|
|
11
11
|
import Call from '../../asset/images/header/h_call_line_b.webp';
|
|
12
12
|
import BrochureBtn from '../BrochureBtn/BrochureBtn';
|
|
13
|
-
const PCMenu = ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochureBtn }) => {
|
|
13
|
+
const PCMenu = ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochureBtn, isMedical }) => {
|
|
14
14
|
const mobile = require('is-mobile');
|
|
15
15
|
const [isMobile, setIsMobile] = useState(false);
|
|
16
16
|
const router = useRouter();
|
|
@@ -120,7 +120,7 @@ const PCMenu = ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochure
|
|
|
120
120
|
</span>
|
|
121
121
|
</div>
|
|
122
122
|
</Link>
|
|
123
|
-
{isBrochureBtn ? (<BrochureBtn width={'280px'} height={'58px'} className={'ml-16'}/>) : (<></>)}
|
|
123
|
+
{isBrochureBtn ? (<BrochureBtn width={'280px'} height={'58px'} className={'ml-16'} isMedical={isMedical}/>) : (<></>)}
|
|
124
124
|
</div>
|
|
125
125
|
</div>
|
|
126
126
|
</div>
|
|
@@ -14,7 +14,7 @@ import Call from '../../asset/images/header/h_call_line_b.webp';
|
|
|
14
14
|
import { IPcMenuType } from '../../types/header';
|
|
15
15
|
import BrochureBtn from '../BrochureBtn/BrochureBtn';
|
|
16
16
|
|
|
17
|
-
const PCMenu = ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochureBtn }: IPcMenuType) => {
|
|
17
|
+
const PCMenu = ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochureBtn, isMedical }: IPcMenuType) => {
|
|
18
18
|
const mobile = require('is-mobile');
|
|
19
19
|
const [isMobile, setIsMobile] = useState<boolean>(false);
|
|
20
20
|
|
|
@@ -228,7 +228,12 @@ const PCMenu = ({ handleMenuToggle, opacity, menuToggle, tel, routes, isBrochure
|
|
|
228
228
|
</div>
|
|
229
229
|
</Link>
|
|
230
230
|
{isBrochureBtn ? (
|
|
231
|
-
<BrochureBtn
|
|
231
|
+
<BrochureBtn
|
|
232
|
+
width={'280px'}
|
|
233
|
+
height={'58px'}
|
|
234
|
+
className={'ml-16'}
|
|
235
|
+
isMedical={isMedical}
|
|
236
|
+
/>
|
|
232
237
|
) : (
|
|
233
238
|
<></>
|
|
234
239
|
)}
|
package/dist/lib/utils.d.ts
CHANGED
|
@@ -25,3 +25,4 @@ export declare function telValidator(tel: string): boolean;
|
|
|
25
25
|
export declare const consonantRegExp: (str: string, testStr: string) => true | RegExpMatchArray | null;
|
|
26
26
|
export declare const getDomainHandler: (centerCode: string, subDomain: string) => string;
|
|
27
27
|
export declare const replaceInitialData: (str: string, initialData: IInitialDataTypes) => string;
|
|
28
|
+
export declare const getSeoTemplateSearchTitle: (str: string) => string[];
|
package/dist/lib/utils.js
CHANGED
|
@@ -357,3 +357,12 @@ export const replaceInitialData = (str, initialData) => {
|
|
|
357
357
|
.replace('*consult_date*', initialData.consult_date.toLocaleString())
|
|
358
358
|
.replace('*main_date*', initialData.main_date.toLocaleString());
|
|
359
359
|
};
|
|
360
|
+
//seo template 쿼리내부 공통 함수
|
|
361
|
+
export const getSeoTemplateSearchTitle = (str) => {
|
|
362
|
+
return str
|
|
363
|
+
.replace('/', ' ')
|
|
364
|
+
.replace(',', ' ')
|
|
365
|
+
.replace('(', ' ')
|
|
366
|
+
.replace(/(?<!소년)범죄/g, ' ')
|
|
367
|
+
.split(' ');
|
|
368
|
+
};
|
package/dist/lib/utils.ts
CHANGED
|
@@ -390,3 +390,13 @@ export const replaceInitialData = (str: string, initialData: IInitialDataTypes)
|
|
|
390
390
|
.replace('*consult_date*', initialData.consult_date.toLocaleString())
|
|
391
391
|
.replace('*main_date*', initialData.main_date.toLocaleString());
|
|
392
392
|
};
|
|
393
|
+
|
|
394
|
+
//seo template 쿼리내부 공통 함수
|
|
395
|
+
export const getSeoTemplateSearchTitle = (str: string) => {
|
|
396
|
+
return str
|
|
397
|
+
.replace('/', ' ')
|
|
398
|
+
.replace(',', ' ')
|
|
399
|
+
.replace('(', ' ')
|
|
400
|
+
.replace(/(?<!소년)범죄/g, ' ')
|
|
401
|
+
.split(' ');
|
|
402
|
+
};
|