@gravity-ui/blog-constructor 1.0.0 → 1.1.0-alpha.0
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +61 -1
- package/build/cjs/blocks/Author/Author.css +31 -0
- package/build/cjs/blocks/Banner/Banner.css +58 -0
- package/build/cjs/blocks/CTA/CTA.css +56 -0
- package/build/cjs/blocks/ColoredText/ColoredText.css +28 -0
- package/build/cjs/blocks/Layout/Layout.css +22 -0
- package/build/cjs/blocks/Media/Media.css +41 -0
- package/build/cjs/blocks/Meta/Meta.css +7 -0
- package/build/cjs/blocks/YFM/__tests__/YFM.test.d.ts +1 -0
- package/build/cjs/blocks/YFM/__tests__/YFM.test.js +16 -0
- package/build/cjs/components/ButtonWithIcon/ButtonWithIcon.css +76 -0
- package/build/cjs/components/FeedHeader/FeedHeader.css +54 -0
- package/build/cjs/components/FeedHeader/components/Controls/Controls.css +108 -0
- package/build/cjs/components/FeedHeader/components/CustomSelectOption/CustomSelectOption.css +14 -0
- package/build/cjs/components/FeedHeader/components/CustomSwitcher/CustomSwitcher.css +53 -0
- package/build/cjs/components/Paginator/Paginator.css +54 -0
- package/build/cjs/components/PostCard/PostCard.css +85 -0
- package/build/cjs/components/PostInfo/PostInfo.css +88 -0
- package/build/cjs/components/Posts/Posts.css +28 -0
- package/build/cjs/components/PostsEmpty/PostsEmpty.css +25 -0
- package/build/cjs/components/PostsError/PostError.css +30 -0
- package/build/cjs/components/Search/Search.css +32 -0
- package/build/cjs/components/Wrapper/Wrapper.css +32 -0
- package/build/cjs/containers/BlogPage/BlogPage.css +21 -0
- package/build/cjs/containers/BlogPostPage/BlogPostPage.css +251 -0
- package/build/cjs/models/blocks.d.ts +0 -1
- package/build/esm/blocks/Author/Author.css +31 -0
- package/build/esm/blocks/Banner/Banner.css +58 -0
- package/build/esm/blocks/CTA/CTA.css +56 -0
- package/build/esm/blocks/ColoredText/ColoredText.css +28 -0
- package/build/esm/blocks/Layout/Layout.css +22 -0
- package/build/esm/blocks/Media/Media.css +41 -0
- package/build/esm/blocks/Meta/Meta.css +7 -0
- package/build/esm/blocks/YFM/__tests__/YFM.test.d.ts +1 -0
- package/build/esm/blocks/YFM/__tests__/YFM.test.js +11 -0
- package/build/esm/components/ButtonWithIcon/ButtonWithIcon.css +76 -0
- package/build/esm/components/FeedHeader/FeedHeader.css +54 -0
- package/build/esm/components/FeedHeader/components/Controls/Controls.css +108 -0
- package/build/esm/components/FeedHeader/components/CustomSelectOption/CustomSelectOption.css +14 -0
- package/build/esm/components/FeedHeader/components/CustomSwitcher/CustomSwitcher.css +53 -0
- package/build/esm/components/Paginator/Paginator.css +54 -0
- package/build/esm/components/PostCard/PostCard.css +85 -0
- package/build/esm/components/PostInfo/PostInfo.css +88 -0
- package/build/esm/components/Posts/Posts.css +28 -0
- package/build/esm/components/PostsEmpty/PostsEmpty.css +25 -0
- package/build/esm/components/PostsError/PostError.css +30 -0
- package/build/esm/components/Search/Search.css +32 -0
- package/build/esm/components/Wrapper/Wrapper.css +32 -0
- package/build/esm/containers/BlogPage/BlogPage.css +21 -0
- package/build/esm/containers/BlogPostPage/BlogPostPage.css +251 -0
- package/build/esm/models/blocks.d.ts +0 -1
- package/package.json +38 -28
- package/server/models/blocks.d.ts +0 -1
- package/styles/mixins.css +2 -0
- package/styles/mixins.scss +0 -11
- package/styles/root.css +21 -0
- package/styles/styles.css +196 -0
- package/styles/variables.css +0 -0
- package/styles/yfm.css +103 -0
package/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# @gravity-ui/blog-constructor ·
|
1
|
+
# @gravity-ui/blog-constructor · [![npm package](https://img.shields.io/npm/v/@gravity-ui/blog-constructor)](https://www.npmjs.com/package/@gravity-ui/blog-constructor)
|
2
2
|
|
3
3
|
## Install
|
4
4
|
|
@@ -6,6 +6,66 @@
|
|
6
6
|
npm install @gravity-ui/blog-constructor
|
7
7
|
```
|
8
8
|
|
9
|
+
## Blog-constructor
|
10
|
+
|
11
|
+
`Blog-constructor` is a library based on the [Page-constructor](https://github.com/gravity-ui/page-constructor) library for creating blog format web pages. Blog-constructor uses the [`custom`](https://github.com/gravity-ui/page-constructor#custom-blocks) prop from page-constructor to add the components needed for the blog.
|
12
|
+
|
13
|
+
### Getting started
|
14
|
+
|
15
|
+
The blog-constructor has both client components and server components for import. The blog pages is imported as a React component. To make sure it runs properly, wrap it in `BlogConstructorProvider`:
|
16
|
+
|
17
|
+
```jsx
|
18
|
+
import {BlogPage, BlogConstructorProvider} from '@gravity-ui/blog-constructor';
|
19
|
+
|
20
|
+
// Main blog page
|
21
|
+
<BlogConstructorProvider>
|
22
|
+
<BlogPage
|
23
|
+
content={content}
|
24
|
+
posts={posts}
|
25
|
+
tags={tags}
|
26
|
+
getPosts={handleGetPosts}
|
27
|
+
settings={settings}
|
28
|
+
/>
|
29
|
+
</BlogConstructorProvider>
|
30
|
+
|
31
|
+
---
|
32
|
+
|
33
|
+
import {BlogPostPage, BlogConstructorProvider} from '@gravity-ui/blog-constructor';
|
34
|
+
|
35
|
+
// Post page
|
36
|
+
<BlogConstructorProvider {...providerProps}>
|
37
|
+
<BlogPostPage
|
38
|
+
content={content}
|
39
|
+
post={post}
|
40
|
+
suggestedPosts={suggestedPosts}
|
41
|
+
settings={settings}
|
42
|
+
shareOptions={shareOptions}
|
43
|
+
/>
|
44
|
+
</BlogConstructorProvider>
|
45
|
+
|
46
|
+
```
|
47
|
+
|
48
|
+
Also blog-constructor have server components to help you transform your data if you need
|
49
|
+
|
50
|
+
```jsx
|
51
|
+
import {
|
52
|
+
transformPost,
|
53
|
+
sanitizeMeta,
|
54
|
+
createReadableContent,
|
55
|
+
transformPageContent,
|
56
|
+
} from '@gravity-ui/blog-constructor/server';
|
57
|
+
```
|
58
|
+
|
59
|
+
## i18n
|
60
|
+
|
61
|
+
To make sure the i18n library used in your project runs properly, perform its initialization and set the project's current locale value in `lang`. For example:
|
62
|
+
|
63
|
+
```typescript
|
64
|
+
import {configure, Lang} from '@gravity-ui/blog-constructor';
|
65
|
+
|
66
|
+
configure({lang: Lang.En});
|
67
|
+
```
|
68
|
+
|
9
69
|
## Development
|
10
70
|
|
11
71
|
```bash
|
@@ -0,0 +1,31 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-author__layout {
|
4
|
+
display: flex;
|
5
|
+
align-items: flex-start;
|
6
|
+
flex-direction: row;
|
7
|
+
overflow: hidden;
|
8
|
+
}
|
9
|
+
@media (max-width: 1081px) {
|
10
|
+
.bc-author__layout {
|
11
|
+
width: 50%;
|
12
|
+
}
|
13
|
+
}
|
14
|
+
@media (max-width: 577px) {
|
15
|
+
.bc-author__layout {
|
16
|
+
width: 100%;
|
17
|
+
}
|
18
|
+
}
|
19
|
+
.bc-author__description {
|
20
|
+
color: var(--yc-color-text-primary);
|
21
|
+
}
|
22
|
+
.bc-author__content {
|
23
|
+
display: flex;
|
24
|
+
flex-wrap: wrap;
|
25
|
+
justify-content: flex-start;
|
26
|
+
align-content: flex-start;
|
27
|
+
position: relative;
|
28
|
+
}
|
29
|
+
.bc-author__container {
|
30
|
+
background-color: var(--yc-color-promo-base-silver);
|
31
|
+
}
|
@@ -0,0 +1,58 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-banner {
|
4
|
+
margin-top: 16px;
|
5
|
+
padding-bottom: 16px;
|
6
|
+
}
|
7
|
+
.bc-banner__content {
|
8
|
+
width: 100%;
|
9
|
+
border-radius: var(--bc-border-radius);
|
10
|
+
position: relative;
|
11
|
+
display: flex;
|
12
|
+
flex-direction: row;
|
13
|
+
}
|
14
|
+
.bc-banner__container {
|
15
|
+
width: 100%;
|
16
|
+
border-radius: var(--bc-border-radius);
|
17
|
+
display: flex;
|
18
|
+
min-height: 220px;
|
19
|
+
}
|
20
|
+
.bc-banner__container_offset_large {
|
21
|
+
padding: calc(128px - 96px) 0 16px;
|
22
|
+
margin-bottom: -48px;
|
23
|
+
}
|
24
|
+
.bc-banner__info, .bc-banner__image {
|
25
|
+
flex: 1;
|
26
|
+
}
|
27
|
+
.bc-banner__info {
|
28
|
+
padding: 32px;
|
29
|
+
display: flex;
|
30
|
+
justify-content: space-between;
|
31
|
+
flex-direction: column;
|
32
|
+
align-items: baseline;
|
33
|
+
}
|
34
|
+
.bc-banner__image {
|
35
|
+
margin: var(--pc-image-padding);
|
36
|
+
border-radius: calc(var(--pc-border-radius) - var(--pc-image-padding));
|
37
|
+
width: calc(100% - 8px);
|
38
|
+
height: calc(100% - 8px);
|
39
|
+
object-fit: cover;
|
40
|
+
}
|
41
|
+
.bc-banner__image-container {
|
42
|
+
height: 100%;
|
43
|
+
}
|
44
|
+
.bc-banner__image-container_image-size_s {
|
45
|
+
width: 25%;
|
46
|
+
}
|
47
|
+
.bc-banner__image-container_image-size_m {
|
48
|
+
width: 50%;
|
49
|
+
}
|
50
|
+
@media (max-width: 577px) {
|
51
|
+
.bc-banner__content {
|
52
|
+
flex-direction: column;
|
53
|
+
}
|
54
|
+
.bc-banner__image-container_image-size_s, .bc-banner__image-container_image-size_m {
|
55
|
+
width: 100%;
|
56
|
+
height: 236px;
|
57
|
+
}
|
58
|
+
}
|
@@ -0,0 +1,56 @@
|
|
1
|
+
.bc-cta__card {
|
2
|
+
display: flex;
|
3
|
+
background-color: var(--yc-color-base-float);
|
4
|
+
border-radius: var(--bc-border-radius);
|
5
|
+
min-height: 80px;
|
6
|
+
align-content: center;
|
7
|
+
justify-content: center;
|
8
|
+
flex-direction: column;
|
9
|
+
flex-grow: 1;
|
10
|
+
padding: 32px;
|
11
|
+
}
|
12
|
+
.bc-cta__button {
|
13
|
+
display: flex;
|
14
|
+
padding-bottom: 16px;
|
15
|
+
}
|
16
|
+
.bc-cta__content {
|
17
|
+
display: flex;
|
18
|
+
flex-direction: column;
|
19
|
+
}
|
20
|
+
@media (min-width: 577px) {
|
21
|
+
.bc-cta__content {
|
22
|
+
display: flex;
|
23
|
+
flex-direction: row;
|
24
|
+
}
|
25
|
+
.bc-cta__button {
|
26
|
+
padding-bottom: 0px;
|
27
|
+
}
|
28
|
+
.bc-cta__button_layout {
|
29
|
+
width: 100%;
|
30
|
+
max-width: 100%;
|
31
|
+
margin-right: 0px;
|
32
|
+
}
|
33
|
+
.bc-cta__button_layout_2 {
|
34
|
+
width: calc(50% - (16px / 2));
|
35
|
+
max-width: 50%;
|
36
|
+
margin-right: 16px;
|
37
|
+
}
|
38
|
+
.bc-cta__button_layout_2:nth-child(2n) {
|
39
|
+
margin-right: 0px;
|
40
|
+
}
|
41
|
+
.bc-cta__button_layout_3 {
|
42
|
+
width: calc(33.3333333333% - (32px / 3));
|
43
|
+
margin-right: 16px;
|
44
|
+
}
|
45
|
+
.bc-cta__button_layout_3:nth-child(3n) {
|
46
|
+
margin-right: 0px;
|
47
|
+
}
|
48
|
+
.bc-cta__button_layout_4 {
|
49
|
+
width: calc(25% - (48px / 4));
|
50
|
+
max-width: 50%;
|
51
|
+
margin-right: 16px;
|
52
|
+
}
|
53
|
+
.bc-cta__button_layout_4:nth-child(4n) {
|
54
|
+
margin-right: 0px;
|
55
|
+
}
|
56
|
+
}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
.bc-colored-text__container {
|
2
|
+
display: flex;
|
3
|
+
border-radius: var(--bc-border-radius);
|
4
|
+
overflow: hidden;
|
5
|
+
position: relative;
|
6
|
+
}
|
7
|
+
.bc-colored-text__picture-container {
|
8
|
+
position: absolute;
|
9
|
+
overflow: hidden;
|
10
|
+
width: 100%;
|
11
|
+
height: 100%;
|
12
|
+
border-radius: var(--bc-border-radius);
|
13
|
+
z-index: 1;
|
14
|
+
top: 0;
|
15
|
+
left: 0;
|
16
|
+
}
|
17
|
+
.bc-colored-text__picture {
|
18
|
+
object-fit: cover;
|
19
|
+
height: 100%;
|
20
|
+
width: 100%;
|
21
|
+
}
|
22
|
+
.bc-colored-text__text-content {
|
23
|
+
position: inherit;
|
24
|
+
z-index: 2;
|
25
|
+
height: 100%;
|
26
|
+
width: 100%;
|
27
|
+
padding: 32px;
|
28
|
+
}
|
@@ -0,0 +1,22 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-layout {
|
4
|
+
margin: 0;
|
5
|
+
padding: 0;
|
6
|
+
}
|
7
|
+
.bc-layout__left-col.bc-layout__left-col {
|
8
|
+
padding: 0;
|
9
|
+
}
|
10
|
+
|
11
|
+
.bc-layout__right-col.bc-layout__right-col {
|
12
|
+
padding: 0;
|
13
|
+
}
|
14
|
+
|
15
|
+
.bc-layout__row {
|
16
|
+
padding: 0;
|
17
|
+
margin: 0;
|
18
|
+
}
|
19
|
+
.bc-layout__item {
|
20
|
+
margin: 0;
|
21
|
+
padding: 0 8px;
|
22
|
+
}
|
@@ -0,0 +1,41 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-media__text-content {
|
4
|
+
padding-top: 16px;
|
5
|
+
}
|
6
|
+
.bc-media__container {
|
7
|
+
position: relative;
|
8
|
+
height: 100%;
|
9
|
+
}
|
10
|
+
.bc-media__border {
|
11
|
+
position: relative;
|
12
|
+
height: 100%;
|
13
|
+
width: 100%;
|
14
|
+
border-radius: calc(var(--bc-border-radius) + 1px);
|
15
|
+
border: 1px solid var(--yc-color-line-generic);
|
16
|
+
overflow: hidden;
|
17
|
+
}
|
18
|
+
.bc-media__content {
|
19
|
+
position: relative;
|
20
|
+
top: 0;
|
21
|
+
right: 0;
|
22
|
+
width: 100%;
|
23
|
+
height: 100%;
|
24
|
+
overflow: hidden;
|
25
|
+
object-fit: cover;
|
26
|
+
border-radius: var(--bc-border-radius);
|
27
|
+
}
|
28
|
+
.bc-media__video {
|
29
|
+
height: 100%;
|
30
|
+
}
|
31
|
+
.bc-media__video > video {
|
32
|
+
width: 100%;
|
33
|
+
height: auto;
|
34
|
+
border-radius: var(--bc-border-radius);
|
35
|
+
}
|
36
|
+
.bc-media__image {
|
37
|
+
width: 100%;
|
38
|
+
height: 100%;
|
39
|
+
object-fit: cover;
|
40
|
+
border-radius: var(--bc-border-radius);
|
41
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1,16 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
+
};
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
const react_1 = __importDefault(require("react"));
|
7
|
+
const react_2 = require("@testing-library/react");
|
8
|
+
const YFM_1 = require("../YFM");
|
9
|
+
const text = 'YFM block';
|
10
|
+
describe('YFM', () => {
|
11
|
+
test('Has id', async () => {
|
12
|
+
(0, react_2.render)(react_1.default.createElement(YFM_1.YFM, { text: text }));
|
13
|
+
const yfm = react_2.screen.getByText(text);
|
14
|
+
expect(yfm).toHaveClass('yfm');
|
15
|
+
});
|
16
|
+
});
|
@@ -0,0 +1,76 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-button-with-icon {
|
4
|
+
display: inline-block;
|
5
|
+
margin: 0;
|
6
|
+
padding: 0;
|
7
|
+
font: inherit;
|
8
|
+
border: none;
|
9
|
+
outline: none;
|
10
|
+
color: inherit;
|
11
|
+
background: none;
|
12
|
+
cursor: pointer;
|
13
|
+
outline: none;
|
14
|
+
display: flex;
|
15
|
+
align-items: center;
|
16
|
+
justify-content: center;
|
17
|
+
transition: color 0.2s;
|
18
|
+
}
|
19
|
+
.utilityfocus .bc-button-with-icon:focus {
|
20
|
+
outline: 2px solid #ffdb4d;
|
21
|
+
}
|
22
|
+
.bc-button-with-icon_size_xs {
|
23
|
+
height: 24px;
|
24
|
+
width: 24px;
|
25
|
+
}
|
26
|
+
.bc-button-with-icon_size_s {
|
27
|
+
height: 28px;
|
28
|
+
width: 28px;
|
29
|
+
}
|
30
|
+
.bc-button-with-icon_size_m {
|
31
|
+
height: 32px;
|
32
|
+
width: 32px;
|
33
|
+
}
|
34
|
+
.bc-button-with-icon_size_n {
|
35
|
+
height: 36px;
|
36
|
+
width: 36px;
|
37
|
+
}
|
38
|
+
.bc-button-with-icon_theme_primary {
|
39
|
+
color: var(--www-text-content-color);
|
40
|
+
transition: color 0.2s;
|
41
|
+
}
|
42
|
+
.bc-button-with-icon_theme_primary:hover {
|
43
|
+
color: var(--yc-color-text-primary);
|
44
|
+
}
|
45
|
+
.bc-button-with-icon_theme_secondary {
|
46
|
+
color: var(--yc-color-text-secondary);
|
47
|
+
transition: color 0.2s;
|
48
|
+
}
|
49
|
+
.bc-button-with-icon_theme_secondary:hover {
|
50
|
+
color: var(--www-text-content-color);
|
51
|
+
}
|
52
|
+
.bc-button-with-icon_theme_link {
|
53
|
+
color: var(--www-text-content-color);
|
54
|
+
transition: color 0.2s;
|
55
|
+
}
|
56
|
+
.bc-button-with-icon_theme_link:hover {
|
57
|
+
color: var(--yc-color-text-link-hover);
|
58
|
+
}
|
59
|
+
.bc-button-with-icon_theme_accent {
|
60
|
+
color: var(--yc-color-text-yandex-red);
|
61
|
+
transition: opacity 0.2s;
|
62
|
+
opacity: 0.7;
|
63
|
+
}
|
64
|
+
.bc-button-with-icon_theme_accent:hover {
|
65
|
+
opacity: 1;
|
66
|
+
}
|
67
|
+
.bc-button-with-icon_disabled {
|
68
|
+
cursor: default;
|
69
|
+
color: var(--yc-color-text-secondary);
|
70
|
+
}
|
71
|
+
.bc-button-with-icon_disabled:hover {
|
72
|
+
color: var(--yc-color-text-secondary);
|
73
|
+
}
|
74
|
+
.mobile .bc-button-with-icon:hover {
|
75
|
+
color: inherit;
|
76
|
+
}
|
@@ -0,0 +1,54 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-feed-header {
|
4
|
+
margin-top: 16px;
|
5
|
+
}
|
6
|
+
.bc-feed-header__header {
|
7
|
+
padding: 16px 0;
|
8
|
+
}
|
9
|
+
.bc-feed-header__content {
|
10
|
+
position: relative;
|
11
|
+
height: 100%;
|
12
|
+
padding-bottom: 0;
|
13
|
+
}
|
14
|
+
.bc-feed-header__content_offset_large {
|
15
|
+
padding: calc(128px - 96px) 0 16px;
|
16
|
+
margin-bottom: -48px;
|
17
|
+
}
|
18
|
+
.bc-feed-header__content_theme_dark.bc-feed-header__content_theme_dark .bc-feed-header__title,
|
19
|
+
.bc-feed-header__content_theme_dark.bc-feed-header__content_theme_dark .bc-feed-header__description * {
|
20
|
+
color: var(--yc-color-text-light-primary);
|
21
|
+
}
|
22
|
+
|
23
|
+
.bc-feed-header_has-background {
|
24
|
+
height: calc(100% + 96px);
|
25
|
+
}
|
26
|
+
.bc-feed-header__content {
|
27
|
+
position: relative;
|
28
|
+
z-index: 10;
|
29
|
+
}
|
30
|
+
.bc-feed-header__background, .bc-feed-header__background-media {
|
31
|
+
z-index: 5;
|
32
|
+
}
|
33
|
+
.bc-feed-header__background {
|
34
|
+
position: absolute;
|
35
|
+
top: 0;
|
36
|
+
left: 50%;
|
37
|
+
width: 1440px;
|
38
|
+
transform: translateX(-50%);
|
39
|
+
max-width: 100vw;
|
40
|
+
height: 100%;
|
41
|
+
border-radius: var(--bc-border-radius);
|
42
|
+
}
|
43
|
+
@media (max-width: 769px) {
|
44
|
+
.bc-feed-header_has-background .bc-feed-header__background-img {
|
45
|
+
display: none;
|
46
|
+
}
|
47
|
+
.bc-feed-header_has-background .bc-feed-header__content_vertical-offset_s, .bc-feed-header_has-background .bc-feed-header__content_vertical-offset_m, .bc-feed-header_has-background .bc-feed-header__content_vertical-offset_l, .bc-feed-header_has-background .bc-feed-header__content_vertical-offset_xl {
|
48
|
+
padding: calc(96px - 16px) 0;
|
49
|
+
}
|
50
|
+
}
|
51
|
+
.mobile .bc-feed-header_has-background .bc-feed-header__title {
|
52
|
+
font-size: var(--yc-text-display-2-font-size);
|
53
|
+
line-height: var(--yc-text-display-2-line-height);
|
54
|
+
}
|
@@ -0,0 +1,108 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-feed-controls__header {
|
4
|
+
position: relative;
|
5
|
+
display: flex;
|
6
|
+
flex-direction: column;
|
7
|
+
border-radius: var(--bc-border-radius);
|
8
|
+
padding-bottom: 20px;
|
9
|
+
z-index: 10;
|
10
|
+
}
|
11
|
+
.bc-feed-controls__header-item {
|
12
|
+
display: flex;
|
13
|
+
justify-content: center;
|
14
|
+
flex-wrap: wrap;
|
15
|
+
}
|
16
|
+
.bc-feed-controls__header-item_title {
|
17
|
+
font-size: var(--yc-text-display-4-font-size);
|
18
|
+
line-height: var(--yc-text-display-4-line-height);
|
19
|
+
padding-top: 112px;
|
20
|
+
padding-bottom: 96px;
|
21
|
+
}
|
22
|
+
.bc-feed-controls__search {
|
23
|
+
background-color: var(--yc-color-base-background);
|
24
|
+
border-radius: 10px;
|
25
|
+
width: 100%;
|
26
|
+
max-width: 100%;
|
27
|
+
}
|
28
|
+
.bc-feed-controls__search .yc-text-input_view_normal .yc-text-input__control {
|
29
|
+
border-color: var(--yc-color-base-background);
|
30
|
+
}
|
31
|
+
.bc-feed-controls__select {
|
32
|
+
background-color: var(--yc-color-base-background);
|
33
|
+
border-radius: 10px;
|
34
|
+
width: 100%;
|
35
|
+
}
|
36
|
+
.bc-feed-controls__popup.bc-feed-controls__popup {
|
37
|
+
border-radius: 12px;
|
38
|
+
}
|
39
|
+
.bc-feed-controls__popup.bc-feed-controls__popup .yc-select-filter + .yc-select-list {
|
40
|
+
margin-top: 0;
|
41
|
+
}
|
42
|
+
.bc-feed-controls__popup.bc-feed-controls__popup .yc-select-filter + .yc-select-list::-webkit-scrollbar {
|
43
|
+
display: none;
|
44
|
+
}
|
45
|
+
.bc-feed-controls__popup.bc-feed-controls__popup .yc-list__item {
|
46
|
+
margin: 4px;
|
47
|
+
border-radius: 8px;
|
48
|
+
}
|
49
|
+
.bc-feed-controls__popup.bc-feed-controls__popup .yc-select-filter {
|
50
|
+
margin-top: 4px;
|
51
|
+
padding: 4px;
|
52
|
+
border-bottom: 1px solid var(--yc-color-line-generic);
|
53
|
+
}
|
54
|
+
.bc-feed-controls__popup.bc-feed-controls__popup .yc-select-filter .yc-text-input__control.yc-text-input__control_type_input {
|
55
|
+
border: none;
|
56
|
+
}
|
57
|
+
|
58
|
+
.bc-feed-controls__popup-filter .yc-text-input__control {
|
59
|
+
font-size: var(--yc-text-body-2-font-size);
|
60
|
+
line-height: var(--yc-text-body-2-line-height);
|
61
|
+
border: none;
|
62
|
+
}
|
63
|
+
.bc-feed-controls__popup-filter .yc-text-input__control:hover, .bc-feed-controls__popup-filter .yc-text-input__control:focus {
|
64
|
+
border: none;
|
65
|
+
}
|
66
|
+
.bc-feed-controls__select:hover {
|
67
|
+
background-color: var(--yc-color-base-background);
|
68
|
+
width: 100%;
|
69
|
+
}
|
70
|
+
.bc-feed-controls__saved-only-button {
|
71
|
+
border-radius: 10px;
|
72
|
+
}
|
73
|
+
.bc-feed-controls__saved-only-button_savedOnly {
|
74
|
+
--yc-button-background-color: var(--pc-monochrome-button-background-color);
|
75
|
+
--yc-button-background-color-hover: var(--pc-monochrome-button-background-color-hover);
|
76
|
+
}
|
77
|
+
.bc-feed-controls__saved-only-button_savedOnly, .bc-feed-controls__saved-only-button_savedOnly:link, .bc-feed-controls__saved-only-button_savedOnly:visited, .bc-feed-controls__saved-only-button_savedOnly:active, .bc-feed-controls__saved-only-button_savedOnly:focus {
|
78
|
+
color: var(--pc-monochrome-button-color);
|
79
|
+
}
|
80
|
+
.bc-feed-controls__saved-only-button_savedOnly:hover {
|
81
|
+
color: var(--pc-monochrome-button-color);
|
82
|
+
}
|
83
|
+
.bc-feed-controls__saved-only-button_savedOnly:focus {
|
84
|
+
color: var(--yc-color-base-background);
|
85
|
+
}
|
86
|
+
.bc-feed-controls__filter-item {
|
87
|
+
margin-right: 8px;
|
88
|
+
margin-left: 8px;
|
89
|
+
margin-bottom: 12px;
|
90
|
+
min-width: 230px;
|
91
|
+
flex-grow: 1;
|
92
|
+
}
|
93
|
+
@media (min-width: 577px) {
|
94
|
+
.bc-feed-controls__filter-item {
|
95
|
+
max-width: 240px;
|
96
|
+
}
|
97
|
+
}
|
98
|
+
.bc-feed-controls__filter-item_width-auto {
|
99
|
+
width: auto;
|
100
|
+
min-width: auto;
|
101
|
+
flex-grow: 0;
|
102
|
+
}
|
103
|
+
.bc-feed-controls__icon {
|
104
|
+
color: var(--yc-my-color-brand-normal);
|
105
|
+
}
|
106
|
+
.bc-feed-controls__icon_savedOnly {
|
107
|
+
color: var(--yc-color-base-background);
|
108
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-feed-custom-select-option {
|
4
|
+
font-size: var(--yc-text-body-2-font-size);
|
5
|
+
line-height: var(--yc-text-body-2-line-height);
|
6
|
+
display: flex;
|
7
|
+
}
|
8
|
+
.bc-feed-custom-select-option__icon {
|
9
|
+
margin-right: 6px;
|
10
|
+
}
|
11
|
+
.bc-feed-custom-select-option__icon > svg {
|
12
|
+
width: 20px;
|
13
|
+
height: 20px;
|
14
|
+
}
|
@@ -0,0 +1,53 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-feed-custom-switcher__custom-switcher {
|
4
|
+
font-size: var(--yc-text-body-2-font-size);
|
5
|
+
line-height: var(--yc-text-body-2-line-height);
|
6
|
+
position: relative;
|
7
|
+
display: flex;
|
8
|
+
flex-direction: row;
|
9
|
+
align-items: center;
|
10
|
+
background-color: var(--yc-color-base-background);
|
11
|
+
border: 1px solid var(--yc-color-base-background);
|
12
|
+
border-radius: 10px;
|
13
|
+
width: 100%;
|
14
|
+
line-height: 42px;
|
15
|
+
}
|
16
|
+
.bc-feed-custom-switcher__custom-switcher + .yc-popup-wrapper.yc-popup-wrapper_open {
|
17
|
+
position: absolute !important;
|
18
|
+
inset: auto !important;
|
19
|
+
transform: translate3d(0, 4px, 0) !important;
|
20
|
+
}
|
21
|
+
.bc-feed-custom-switcher__custom-switcher:hover {
|
22
|
+
border-color: var(--yc-color-base-generic-hover);
|
23
|
+
cursor: pointer;
|
24
|
+
}
|
25
|
+
.bc-feed-custom-switcher__custom-switcher-element_content {
|
26
|
+
display: inline-block;
|
27
|
+
flex-grow: 1;
|
28
|
+
overflow: hidden;
|
29
|
+
text-overflow: ellipsis;
|
30
|
+
white-space: nowrap;
|
31
|
+
padding: 0 12px;
|
32
|
+
}
|
33
|
+
.bc-feed-custom-switcher__custom-switcher-element_counter {
|
34
|
+
align-items: center;
|
35
|
+
height: 20px;
|
36
|
+
padding: 0 6px;
|
37
|
+
background-color: var(--yc-color-base-selection);
|
38
|
+
border-radius: 4px;
|
39
|
+
transition: backgound-color 0.1s linear;
|
40
|
+
font-size: var(--yc-text-body-1-font-size);
|
41
|
+
line-height: var(--yc-text-body-1-line-height);
|
42
|
+
}
|
43
|
+
.bc-feed-custom-switcher__custom-switcher-element_arrow {
|
44
|
+
display: flex;
|
45
|
+
align-items: center;
|
46
|
+
justify-content: center;
|
47
|
+
min-width: 30px;
|
48
|
+
height: 100%;
|
49
|
+
}
|
50
|
+
.bc-feed-custom-switcher__switcher-arrow {
|
51
|
+
width: 16px;
|
52
|
+
height: 16px;
|
53
|
+
}
|
@@ -0,0 +1,54 @@
|
|
1
|
+
/* use this for style redefinitions to awoid problems with
|
2
|
+
unpredictable css rules order in build */
|
3
|
+
.bc-paginator {
|
4
|
+
margin: 0;
|
5
|
+
padding: 0;
|
6
|
+
list-style: none;
|
7
|
+
display: flex;
|
8
|
+
align-items: center;
|
9
|
+
}
|
10
|
+
.bc-paginator__item {
|
11
|
+
display: inline-flex;
|
12
|
+
align-items: center;
|
13
|
+
justify-content: center;
|
14
|
+
min-width: 44px;
|
15
|
+
min-height: 44px;
|
16
|
+
margin-left: 4px;
|
17
|
+
padding: 12px 0px;
|
18
|
+
color: var(--yc-color-text-primary);
|
19
|
+
font-size: var(--yc-text-body-2-font-size);
|
20
|
+
line-height: var(--yc-text-body-2-line-height);
|
21
|
+
}
|
22
|
+
.bc-paginator__item_type_page {
|
23
|
+
--bc-border-radius: 10px;
|
24
|
+
width: 44px;
|
25
|
+
height: 44px;
|
26
|
+
cursor: pointer;
|
27
|
+
border-radius: var(--bc-border-radius);
|
28
|
+
}
|
29
|
+
.bc-paginator__item_type_page:hover {
|
30
|
+
background: var(--yc-color-base-simple-hover);
|
31
|
+
}
|
32
|
+
.bc-paginator__item_type_page.bc-paginator__item_active {
|
33
|
+
background: var(--yc-color-base-simple-hover);
|
34
|
+
cursor: default;
|
35
|
+
}
|
36
|
+
.bc-paginator__pagination {
|
37
|
+
display: flex;
|
38
|
+
flex-direction: row;
|
39
|
+
justify-content: center;
|
40
|
+
align-items: center;
|
41
|
+
width: 100%;
|
42
|
+
}
|
43
|
+
@media (max-width: 577px) {
|
44
|
+
.bc-paginator__pagination {
|
45
|
+
flex-direction: column;
|
46
|
+
}
|
47
|
+
}
|
48
|
+
.bc-paginator__pagination-block {
|
49
|
+
display: flex;
|
50
|
+
flex-direction: row;
|
51
|
+
justify-content: center;
|
52
|
+
align-items: center;
|
53
|
+
margin-bottom: 4px;
|
54
|
+
}
|