@jetbrains/kotlin-web-site-ui 0.0.0-foundation-changes.1 → 0.0.0-foundation-changes.2
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/out/components/cta-block/cta-block/cta-block.js +22 -0
- package/out/components/cta-block/cta-block/index.js +6 -0
- package/out/components/cta-block/cta-block/v2/cta-block.js +35 -0
- package/out/components/cta-block/cta-block/v2/cta-block.module.pcss.js +9 -0
- package/out/components/cta-block/typography/create-text-cn.js +26 -0
- package/out/components/cta-block/typography/hooks.js +6 -0
- package/package.json +1 -1
- package/out/components/cta-block/index.js +0 -7
- /package/out/components/cta-block/{v1 → cta-block/v1}/cta-block.js +0 -0
- /package/out/components/cta-block/{v1 → cta-block/v1}/cta-block.module.pcss.js +0 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { CtaBlock as CtaBlock$1 } from './v2/cta-block.js';
|
|
3
|
+
|
|
4
|
+
function CtaBlock(props) {
|
|
5
|
+
if (props.adaptive !== 'layout') {
|
|
6
|
+
const {
|
|
7
|
+
adaptive,
|
|
8
|
+
...rest
|
|
9
|
+
} = props;
|
|
10
|
+
return React.createElement(CtaBlock$1, { ...rest
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
const {
|
|
15
|
+
adaptive,
|
|
16
|
+
...rest
|
|
17
|
+
} = props;
|
|
18
|
+
return React.createElement(CtaBlock$1, { ...rest
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export { CtaBlock };
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import cn from 'classnames';
|
|
3
|
+
import 'bem-cn-fast';
|
|
4
|
+
import { useTextStyles } from '../../typography/hooks.js';
|
|
5
|
+
import styles from './cta-block.module.pcss.js';
|
|
6
|
+
|
|
7
|
+
function CtaBlock({
|
|
8
|
+
className,
|
|
9
|
+
theme,
|
|
10
|
+
classTopTitle,
|
|
11
|
+
topTitle,
|
|
12
|
+
classMainTitle,
|
|
13
|
+
mainTitle,
|
|
14
|
+
classContent,
|
|
15
|
+
children,
|
|
16
|
+
classButtons,
|
|
17
|
+
buttons
|
|
18
|
+
}) {
|
|
19
|
+
const textCn = useTextStyles(theme || 'dark');
|
|
20
|
+
return React.createElement("div", {
|
|
21
|
+
className: cn(className, styles.wrapper)
|
|
22
|
+
}, React.createElement("div", {
|
|
23
|
+
className: cn(styles.layout, 'ktl-layout ktl-layout--center')
|
|
24
|
+
}, topTitle && React.createElement("div", {
|
|
25
|
+
className: cn(classTopTitle, styles.topTitle, textCn('ktl-text-3'))
|
|
26
|
+
}, topTitle), React.createElement("h2", {
|
|
27
|
+
className: cn(classMainTitle, styles.mainTitle, textCn('ktl-hero'))
|
|
28
|
+
}, mainTitle), children && React.createElement("div", {
|
|
29
|
+
className: cn(classContent, styles.content)
|
|
30
|
+
}, children), buttons && React.createElement("div", {
|
|
31
|
+
className: cn(classButtons, styles.buttons)
|
|
32
|
+
}, buttons)));
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export { CtaBlock };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
var styles = {
|
|
2
|
+
"wrapper": "ktl-cta-block-module_wrapper_pE-pv",
|
|
3
|
+
"topTitle": "ktl-cta-block-module_top-title_8ly2n",
|
|
4
|
+
"mainTitle": "ktl-cta-block-module_main-title_iq1p4",
|
|
5
|
+
"content": "ktl-cta-block-module_content_QQ4PV",
|
|
6
|
+
"buttons": "ktl-cta-block-module_buttons_KPToV",
|
|
7
|
+
"layout": "ktl-cta-block-module_layout_ExLIm"
|
|
8
|
+
};
|
|
9
|
+
export { styles as default };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import bemCnFast from 'bem-cn-fast';
|
|
2
|
+
|
|
3
|
+
function createTextCn(theme) {
|
|
4
|
+
if (!theme) {
|
|
5
|
+
throw new TypeError('theme argument is required');
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
function textCn(type = 'ktl-text-1', params = {
|
|
9
|
+
paragraphOffsetAuto: false,
|
|
10
|
+
hardness: undefined,
|
|
11
|
+
external: false,
|
|
12
|
+
mode: undefined
|
|
13
|
+
}) {
|
|
14
|
+
return bemCnFast(type)({
|
|
15
|
+
'paragraph-offset-auto': params.paragraphOffsetAuto,
|
|
16
|
+
hardness: params.hardness,
|
|
17
|
+
external: params.external,
|
|
18
|
+
mode: params.mode,
|
|
19
|
+
theme
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
return textCn;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export { createTextCn };
|
package/package.json
CHANGED
|
File without changes
|
|
File without changes
|