@sima-land/moleculas 12.0.0 → 12.1.0
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/desktop/components/product-card/product-card.module.scss +1 -0
- package/desktop/components/promotion-card/index.d.ts +4 -1
- package/desktop/components/promotion-card/index.js +2 -0
- package/desktop/components/promotion-card/index.module.scss +2 -1
- package/desktop/components/promotion-card/placeholder.d.ts +7 -0
- package/desktop/components/promotion-card/placeholder.js +19 -0
- package/desktop/components/promotion-card/placeholder.module.scss +18 -0
- package/desktop/components/promotion-card/variables.scss +2 -0
- package/package.json +1 -1
|
@@ -15,4 +15,7 @@ export interface PromotionCardProps extends React.HTMLAttributes<HTMLDivElement>
|
|
|
15
15
|
* @param props Свойства.
|
|
16
16
|
* @return Элемент.
|
|
17
17
|
*/
|
|
18
|
-
export declare const PromotionCard:
|
|
18
|
+
export declare const PromotionCard: {
|
|
19
|
+
({ promotionType, href, imageSrc, title, subtitle, dueDate, volumeDiscount, postfix, className, ...restProps }: PromotionCardProps): JSX.Element;
|
|
20
|
+
Placeholder: (props: React.HTMLAttributes<HTMLDivElement>) => JSX.Element;
|
|
21
|
+
};
|
|
@@ -40,6 +40,7 @@ const estimate_1 = require("./estimate");
|
|
|
40
40
|
const watch_1 = __importDefault(require("@sima-land/ui-quarks/icons/16x16/Stroked/watch"));
|
|
41
41
|
const classnames_1 = __importDefault(require("classnames"));
|
|
42
42
|
const index_module_scss_1 = __importDefault(require("./index.module.scss"));
|
|
43
|
+
const placeholder_1 = require("./placeholder");
|
|
43
44
|
const PromotionName = {
|
|
44
45
|
gift: 'Подарок',
|
|
45
46
|
special: 'Спецпредложение',
|
|
@@ -77,3 +78,4 @@ const PromotionCard = (_a) => {
|
|
|
77
78
|
postfix && (react_1.default.createElement("div", { className: index_module_scss_1.default.postfix }, postfix)))))));
|
|
78
79
|
};
|
|
79
80
|
exports.PromotionCard = PromotionCard;
|
|
81
|
+
exports.PromotionCard.Placeholder = placeholder_1.PromotionCardPlaceholder;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@use 'node_modules/@sima-land/ui-nucleons/colors';
|
|
2
2
|
@use 'node_modules/@sima-land/ui-nucleons/breakpoints';
|
|
3
|
+
@use './variables';
|
|
3
4
|
@import 'node_modules/@sima-land/ui-nucleons/styling/shadows.module';
|
|
4
5
|
|
|
5
6
|
.root {
|
|
@@ -24,7 +25,7 @@
|
|
|
24
25
|
.banner {
|
|
25
26
|
position: relative;
|
|
26
27
|
width: 100%;
|
|
27
|
-
padding-top:
|
|
28
|
+
padding-top: variables.$banner-height;
|
|
28
29
|
background: colors.$gray8;
|
|
29
30
|
border-radius: 8px 8px 0 0;
|
|
30
31
|
overflow: hidden;
|
|
@@ -0,0 +1,19 @@
|
|
|
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
|
+
exports.PromotionCardPlaceholder = void 0;
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const placeholder_module_scss_1 = __importDefault(require("./placeholder.module.scss"));
|
|
9
|
+
const classnames_1 = __importDefault(require("classnames"));
|
|
10
|
+
/**
|
|
11
|
+
* Компонент отображения состояния загрузки карточки акции.
|
|
12
|
+
* @param props Свойства div.
|
|
13
|
+
* @return Элемент.
|
|
14
|
+
*/
|
|
15
|
+
const PromotionCardPlaceholder = (props) => (react_1.default.createElement("div", Object.assign({}, props),
|
|
16
|
+
react_1.default.createElement("div", { className: classnames_1.default(placeholder_module_scss_1.default.part, placeholder_module_scss_1.default.banner) }),
|
|
17
|
+
react_1.default.createElement("div", { className: classnames_1.default(placeholder_module_scss_1.default.part, placeholder_module_scss_1.default.text) }),
|
|
18
|
+
react_1.default.createElement("div", { className: classnames_1.default(placeholder_module_scss_1.default.part, placeholder_module_scss_1.default.text) })));
|
|
19
|
+
exports.PromotionCardPlaceholder = PromotionCardPlaceholder;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
@use 'node_modules/@sima-land/ui-nucleons/colors';
|
|
2
|
+
@use './variables';
|
|
3
|
+
|
|
4
|
+
.part {
|
|
5
|
+
background: colors.$gray4;
|
|
6
|
+
border-radius: 4px;
|
|
7
|
+
& + & {
|
|
8
|
+
margin-top: 12px;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.banner {
|
|
13
|
+
padding-top: variables.$banner-height;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.text {
|
|
17
|
+
height: 48px;
|
|
18
|
+
}
|