@redneckz/wildless-cms-uni-blocks 0.3.43 → 0.3.44
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/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +7 -7
- package/bundle/bundle.umd.min.js +1 -1
- package/dist/components/Footer/Footer.js +1 -1
- package/dist/components/Footer/Footer.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocs.js +1 -1
- package/dist/components/LinkDocs/LinkDocs.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/dist/components/OtherProducts/OtherProducts.js +2 -2
- package/dist/components/OtherProducts/OtherProducts.js.map +1 -1
- package/dist/components/OtherProducts/OtherProductsContent.d.ts +2 -0
- package/dist/components/ProductBlock/ProductBlock.js +1 -1
- package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
- package/dist/components/ProductTile/ProductTile.js +1 -1
- package/dist/components/ProductTile/ProductTile.js.map +1 -1
- package/dist/content-page-repository/transformPicture.js +4 -1
- package/dist/content-page-repository/transformPicture.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/Footer/Footer.js +1 -1
- package/lib/components/Footer/Footer.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocs.js +1 -1
- package/lib/components/LinkDocs/LinkDocs.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocsListItem.js +1 -1
- package/lib/components/OtherProducts/OtherProducts.js +2 -2
- package/lib/components/OtherProducts/OtherProducts.js.map +1 -1
- package/lib/components/OtherProducts/OtherProductsContent.d.ts +2 -0
- package/lib/components/ProductBlock/ProductBlock.js +1 -1
- package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
- package/lib/components/ProductTile/ProductTile.js +1 -1
- package/lib/components/ProductTile/ProductTile.js.map +1 -1
- package/lib/content-page-repository/transformPicture.js +4 -1
- package/lib/content-page-repository/transformPicture.js.map +1 -1
- package/mobile/dist/components/OtherProducts/OtherProducts.js +2 -2
- package/mobile/dist/components/OtherProducts/OtherProducts.js.map +1 -1
- package/mobile/dist/components/OtherProducts/OtherProductsContent.d.ts +2 -0
- package/mobile/dist/components/ProductTile/ProductTile.js +1 -1
- package/mobile/dist/components/ProductTile/ProductTile.js.map +1 -1
- package/mobile/dist/content-page-repository/transformPicture.js +4 -1
- package/mobile/dist/content-page-repository/transformPicture.js.map +1 -1
- package/mobile/lib/components/OtherProducts/OtherProducts.js +2 -2
- package/mobile/lib/components/OtherProducts/OtherProducts.js.map +1 -1
- package/mobile/lib/components/OtherProducts/OtherProductsContent.d.ts +2 -0
- package/mobile/lib/components/ProductTile/ProductTile.js +1 -1
- package/mobile/lib/components/ProductTile/ProductTile.js.map +1 -1
- package/mobile/lib/content-page-repository/transformPicture.js +4 -1
- package/mobile/lib/content-page-repository/transformPicture.js.map +1 -1
- package/mobile/src/components/OtherProducts/OtherProducts.tsx +18 -13
- package/mobile/src/components/OtherProducts/OtherProductsContent.ts +2 -0
- package/mobile/src/components/ProductTile/ProductTile.tsx +1 -1
- package/mobile/src/content-page-repository/transformPicture.ts +5 -1
- package/package.json +1 -1
- package/src/components/Footer/Footer.tsx +2 -2
- package/src/components/LinkDocs/LinkDocs.tsx +1 -1
- package/src/components/LinkDocs/LinkDocsListItem.tsx +1 -1
- package/src/components/OtherProducts/OtherProducts.fixture.tsx +12 -11
- package/src/components/OtherProducts/OtherProducts.tsx +18 -13
- package/src/components/OtherProducts/OtherProductsContent.ts +2 -0
- package/src/components/ProductBlock/ProductBlock.tsx +1 -1
- package/src/components/ProductTile/ProductTile.tsx +1 -1
- package/src/content-page-repository/transformPicture.ts +5 -1
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ColorPalette } from '../../types';
|
|
1
2
|
import type { BlockDef, ColumnsCount } from '../../ui-kit/BlocksList/BlocksListProps';
|
|
2
3
|
|
|
3
4
|
/**
|
|
@@ -29,4 +30,5 @@ export interface OtherProductsContent {
|
|
|
29
30
|
* @maxItems 10
|
|
30
31
|
*/
|
|
31
32
|
blockItems?: blockItemCommonProps[];
|
|
33
|
+
colorPalette?: ColorPalette;
|
|
32
34
|
}
|
|
@@ -33,7 +33,7 @@ export const ProductTile = JSX<ProductTileProps>(
|
|
|
33
33
|
}) => {
|
|
34
34
|
return (
|
|
35
35
|
<section
|
|
36
|
-
className={`bg-white text-primary-text font-sans p-9 box-border ${className} ${
|
|
36
|
+
className={`bg-white overflow-hidden text-primary-text font-sans p-9 box-border ${className} ${
|
|
37
37
|
productTileStyleMap[version]
|
|
38
38
|
} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `}
|
|
39
39
|
id={anchor}
|
|
@@ -36,7 +36,11 @@ async function transformImg(
|
|
|
36
36
|
|
|
37
37
|
const imgPath = `${path.dirname(pagePath)}/${src}`;
|
|
38
38
|
let chain = sharp(imgPath);
|
|
39
|
-
if (size)
|
|
39
|
+
if (size)
|
|
40
|
+
chain = chain.resize(size?.width, size?.height, {
|
|
41
|
+
fit: sharp.fit.contain,
|
|
42
|
+
background: [0, 0, 0, 0],
|
|
43
|
+
});
|
|
40
44
|
if (format) chain = chain.toFormat(format, options);
|
|
41
45
|
|
|
42
46
|
const transformedSrc = transformSrc(src, transformationOptions);
|
package/package.json
CHANGED
|
@@ -26,7 +26,7 @@ export const Footer = JSX<FooterProps>(
|
|
|
26
26
|
anchor = null,
|
|
27
27
|
}) => {
|
|
28
28
|
return (
|
|
29
|
-
<footer className={`px-9 pt-9 pb-
|
|
29
|
+
<footer className={`px-9 pt-9 pb-10 bg-white ${className || ''}`} id={anchor}>
|
|
30
30
|
<div className="flex items-stretch gap-[54px] pb-[30px] xl:gap-8">
|
|
31
31
|
<Logo className={LEFT_COL_WIDTH_FULL_HD} />
|
|
32
32
|
<SearchBar context={context} className="grow" />
|
|
@@ -43,7 +43,7 @@ export const Footer = JSX<FooterProps>(
|
|
|
43
43
|
</div>
|
|
44
44
|
<Sitemap className="pt-[3px]" context={context} items={topItems} />
|
|
45
45
|
</div>
|
|
46
|
-
<HorizontalNavigation className="mt-
|
|
46
|
+
<HorizontalNavigation className="mt-[98px]" links={relatedEnterprises} context={context} />
|
|
47
47
|
<TextInformation links={documents} context={context} />
|
|
48
48
|
</footer>
|
|
49
49
|
);
|
|
@@ -35,7 +35,7 @@ export const LinkDocs = JSX<LinkDocsProps>(
|
|
|
35
35
|
anchor = null,
|
|
36
36
|
}) => {
|
|
37
37
|
return (
|
|
38
|
-
<section className={`font-sans text-primary-text p-
|
|
38
|
+
<section className={`font-sans text-primary-text p-[50px] bg-white ${className}`} id={anchor}>
|
|
39
39
|
{title ? (
|
|
40
40
|
<Heading
|
|
41
41
|
headingType="h2"
|
|
@@ -5,7 +5,7 @@ import { LinkDocsListItemBase } from './LinkDocsListItemBase';
|
|
|
5
5
|
export const LinkDocsListItem = JSX<LinkDocsListItemProps>(({ className = '', doc, icon }) => (
|
|
6
6
|
<LinkDocsListItemBase
|
|
7
7
|
className={`flex h-full box-border ${className}`}
|
|
8
|
-
iconClassName="mr-
|
|
8
|
+
iconClassName="mr-2.5 min-w-6 min-h-6 text-primary-text"
|
|
9
9
|
textClassName="self-center font-light"
|
|
10
10
|
suffixClassName="text-secondary-text group-hover:text-primary-main"
|
|
11
11
|
doc={doc}
|
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
import { context } from '../../setup-fixture';
|
|
2
|
-
import {
|
|
3
|
-
import { PRODUCT_TILE, PRODUCT_PENSION_TILE } from '../ProductTile/ProductTile.fixture';
|
|
4
|
-
import { TEXT_BLOCK } from '../TextBlock/TextBlock.fixture';
|
|
5
|
-
import { TILE, TILE_PREMIUM } from '../Tile/Tile.fixture';
|
|
2
|
+
import { defaultProps as GALLERY } from '../Gallery/Gallery.fixture';
|
|
6
3
|
import { HEADLINE } from '../Headline/Headline.fixture';
|
|
7
|
-
import { PICTURE_TEXT } from '../PictureText/PictureText.fixture';
|
|
8
4
|
import { linkDocsContentExample } from '../LinkDocs/linkDocsContentExample';
|
|
9
|
-
import { defaultProps as GALLERY } from '../Gallery/Gallery.fixture';
|
|
10
5
|
import { defaultProps as MINI_GALLERY } from '../MiniGallery/MiniGallery.fixture';
|
|
11
|
-
import {
|
|
6
|
+
import { PICTURE_TEXT } from '../PictureText/PictureText.fixture';
|
|
7
|
+
import { PRODUCT_BLOCK } from '../ProductBlock/ProductBlock.fixture';
|
|
8
|
+
import { PRODUCT_PENSION_TILE, PRODUCT_TILE } from '../ProductTile/ProductTile.fixture';
|
|
9
|
+
import { TEXT_BLOCK } from '../TextBlock/TextBlock.fixture';
|
|
10
|
+
import { TILE, TILE_PREMIUM } from '../Tile/Tile.fixture';
|
|
12
11
|
import type { OtherProductsProps } from './OtherProducts';
|
|
12
|
+
import { OtherProducts } from './OtherProducts';
|
|
13
13
|
|
|
14
14
|
import type {
|
|
15
|
-
ProductBlockBlockListDef,
|
|
16
|
-
ProductTileBlockListDef,
|
|
17
|
-
TextBlockBlockListDef,
|
|
18
|
-
TileBlockListDef,
|
|
19
15
|
GalleryBlockListDef,
|
|
20
16
|
HeadlineBlockListDef,
|
|
21
17
|
LinkDocsBlockListDef,
|
|
22
18
|
MiniGalleryBlockListDef,
|
|
23
19
|
PictureTextBlockListDef,
|
|
20
|
+
ProductBlockBlockListDef,
|
|
21
|
+
ProductTileBlockListDef,
|
|
22
|
+
TextBlockBlockListDef,
|
|
23
|
+
TileBlockListDef,
|
|
24
24
|
} from '../../ui-kit/BlocksList/BlocksListProps';
|
|
25
25
|
|
|
26
26
|
const TEXT_BLOCK_OTHER_BLOCK: TextBlockBlockListDef = {
|
|
@@ -80,6 +80,7 @@ const MINI_GALLERY_OTHER_BLOCK: MiniGalleryBlockListDef = {
|
|
|
80
80
|
|
|
81
81
|
const propsBlock: OtherProductsProps = {
|
|
82
82
|
context,
|
|
83
|
+
colorPalette: 'pc',
|
|
83
84
|
blockItems: [
|
|
84
85
|
{
|
|
85
86
|
label: 'OtherProducts №1 Tiles',
|
|
@@ -5,16 +5,21 @@ import { OtherProductsItem } from './OtherProductsItem';
|
|
|
5
5
|
|
|
6
6
|
export interface OtherProductsProps extends OtherProductsContent, UniBlockProps {}
|
|
7
7
|
|
|
8
|
-
export const OtherProducts = JSX<OtherProductsProps>(
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
8
|
+
export const OtherProducts = JSX<OtherProductsProps>(
|
|
9
|
+
({ blockItems, colorPalette, context, className = "" }) => {
|
|
10
|
+
return (
|
|
11
|
+
<section
|
|
12
|
+
data-theme={colorPalette || null}
|
|
13
|
+
className={`font-sans bg-white text-primary-text ${className}`}
|
|
14
|
+
>
|
|
15
|
+
{blockItems?.length ? (
|
|
16
|
+
<div className="list-none m-0 p-0">
|
|
17
|
+
{blockItems.map((item, i) => (
|
|
18
|
+
<OtherProductsItem key={`BlockItem${i}`} {...item} context={context} />
|
|
19
|
+
))}
|
|
20
|
+
</div>
|
|
21
|
+
) : null}
|
|
22
|
+
</section>
|
|
23
|
+
);
|
|
24
|
+
},
|
|
25
|
+
);
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ColorPalette } from '../../types';
|
|
1
2
|
import type { BlockDef, ColumnsCount } from '../../ui-kit/BlocksList/BlocksListProps';
|
|
2
3
|
|
|
3
4
|
/**
|
|
@@ -29,4 +30,5 @@ export interface OtherProductsContent {
|
|
|
29
30
|
* @maxItems 10
|
|
30
31
|
*/
|
|
31
32
|
blockItems?: blockItemCommonProps[];
|
|
33
|
+
colorPalette?: ColorPalette;
|
|
32
34
|
}
|
|
@@ -34,7 +34,7 @@ export const ProductBlock = JSX<ProductBlockProps>((props) => {
|
|
|
34
34
|
|
|
35
35
|
return (
|
|
36
36
|
<section
|
|
37
|
-
className={`font-sans pt-10 pl-[50px] pb-[50px] pr-[7.5rem] box-border min-h-[420px] ${productBlockStyleMap[version]} ${className}`}
|
|
37
|
+
className={`font-sans overflow-hidden pt-10 pl-[50px] pb-[50px] pr-[7.5rem] box-border min-h-[420px] ${productBlockStyleMap[version]} ${className}`}
|
|
38
38
|
id={anchor}
|
|
39
39
|
>
|
|
40
40
|
{renderBackwardButton('Все дебетовые карты', version, 'mb-10')}
|
|
@@ -33,7 +33,7 @@ export const ProductTile = JSX<ProductTileProps>(
|
|
|
33
33
|
}) => {
|
|
34
34
|
return (
|
|
35
35
|
<section
|
|
36
|
-
className={`bg-white text-primary-text font-sans p-9 box-border ${className} ${
|
|
36
|
+
className={`bg-white overflow-hidden text-primary-text font-sans p-9 box-border ${className} ${
|
|
37
37
|
productTileStyleMap[version]
|
|
38
38
|
} ${getTileRightPadding(className)} ${getTileMinHeight(className)} `}
|
|
39
39
|
id={anchor}
|
|
@@ -36,7 +36,11 @@ async function transformImg(
|
|
|
36
36
|
|
|
37
37
|
const imgPath = `${path.dirname(pagePath)}/${src}`;
|
|
38
38
|
let chain = sharp(imgPath);
|
|
39
|
-
if (size)
|
|
39
|
+
if (size)
|
|
40
|
+
chain = chain.resize(size?.width, size?.height, {
|
|
41
|
+
fit: sharp.fit.contain,
|
|
42
|
+
background: [0, 0, 0, 0],
|
|
43
|
+
});
|
|
40
44
|
if (format) chain = chain.toFormat(format, options);
|
|
41
45
|
|
|
42
46
|
const transformedSrc = transformSrc(src, transformationOptions);
|