@gympass/yoga 7.91.1 → 7.92.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.
|
@@ -71,16 +71,16 @@ var import_StyledFeedback = require("./StyledFeedback");
|
|
|
71
71
|
const ICON_SIZE = 64;
|
|
72
72
|
const VARIANT_ICONS = {
|
|
73
73
|
success: {
|
|
74
|
-
as: import_yoga_icons.
|
|
75
|
-
fill: "hope"
|
|
74
|
+
as: import_yoga_icons.Success
|
|
76
75
|
},
|
|
77
76
|
informative: {
|
|
78
|
-
as: import_yoga_icons.
|
|
79
|
-
fill: "relax"
|
|
77
|
+
as: import_yoga_icons.Information
|
|
80
78
|
},
|
|
81
79
|
attention: {
|
|
82
|
-
as: import_yoga_icons.
|
|
83
|
-
|
|
80
|
+
as: import_yoga_icons.Attention
|
|
81
|
+
},
|
|
82
|
+
delayed: {
|
|
83
|
+
as: import_yoga_icons.Delayed
|
|
84
84
|
}
|
|
85
85
|
};
|
|
86
86
|
function isChildFromComponent(child, component) {
|
|
@@ -121,7 +121,7 @@ function Feedback(_a) {
|
|
|
121
121
|
__spreadProps(__spreadValues({}, iconProps), {
|
|
122
122
|
size: ICON_SIZE,
|
|
123
123
|
mb: "large",
|
|
124
|
-
"data-testid":
|
|
124
|
+
"data-testid": `feedback-icon-${variant}`
|
|
125
125
|
})
|
|
126
126
|
),
|
|
127
127
|
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_StyledFeedback.TextContainer, { children: [
|
|
@@ -72,7 +72,7 @@ describe("<Feedback />", () => {
|
|
|
72
72
|
const { getByTestId } = renderWithTheme(
|
|
73
73
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.Feedback, { variant: "success", title, description })
|
|
74
74
|
);
|
|
75
|
-
expect(getByTestId("feedback-icon")).toMatchSnapshot();
|
|
75
|
+
expect(getByTestId("feedback-icon-success")).toMatchSnapshot();
|
|
76
76
|
});
|
|
77
77
|
it("should render the icon for informative variant", () => {
|
|
78
78
|
const { getByTestId } = renderWithTheme(
|
|
@@ -85,12 +85,18 @@ describe("<Feedback />", () => {
|
|
|
85
85
|
}
|
|
86
86
|
)
|
|
87
87
|
);
|
|
88
|
-
expect(getByTestId("feedback-icon")).toMatchSnapshot();
|
|
88
|
+
expect(getByTestId("feedback-icon-informative")).toMatchSnapshot();
|
|
89
89
|
});
|
|
90
90
|
it("should render the icon for attention variant", () => {
|
|
91
91
|
const { getByTestId } = renderWithTheme(
|
|
92
92
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.Feedback, { variant: "attention", title, description })
|
|
93
93
|
);
|
|
94
|
-
expect(getByTestId("feedback-icon")).toMatchSnapshot();
|
|
94
|
+
expect(getByTestId("feedback-icon-attention")).toMatchSnapshot();
|
|
95
|
+
});
|
|
96
|
+
it("should render the icon for delayed variant", () => {
|
|
97
|
+
const { getByTestId } = renderWithTheme(
|
|
98
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import__.Feedback, { variant: "delayed", title, description })
|
|
99
|
+
);
|
|
100
|
+
expect(getByTestId("feedback-icon-delayed")).toMatchSnapshot();
|
|
95
101
|
});
|
|
96
102
|
});
|
|
@@ -32,7 +32,7 @@ var __objRest = (source, exclude) => {
|
|
|
32
32
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
33
33
|
import { arrayOf, node, oneOf, oneOfType, string, bool } from "prop-types";
|
|
34
34
|
import React from "react";
|
|
35
|
-
import {
|
|
35
|
+
import { Attention, Delayed, Information, Success } from "@gympass/yoga-icons";
|
|
36
36
|
import Icon from "../../Icon";
|
|
37
37
|
import Box from "../../Box";
|
|
38
38
|
import Text from "../../Text";
|
|
@@ -47,16 +47,16 @@ import {
|
|
|
47
47
|
const ICON_SIZE = 64;
|
|
48
48
|
const VARIANT_ICONS = {
|
|
49
49
|
success: {
|
|
50
|
-
as:
|
|
51
|
-
fill: "hope"
|
|
50
|
+
as: Success
|
|
52
51
|
},
|
|
53
52
|
informative: {
|
|
54
|
-
as:
|
|
55
|
-
fill: "relax"
|
|
53
|
+
as: Information
|
|
56
54
|
},
|
|
57
55
|
attention: {
|
|
58
|
-
as:
|
|
59
|
-
|
|
56
|
+
as: Attention
|
|
57
|
+
},
|
|
58
|
+
delayed: {
|
|
59
|
+
as: Delayed
|
|
60
60
|
}
|
|
61
61
|
};
|
|
62
62
|
function isChildFromComponent(child, component) {
|
|
@@ -97,7 +97,7 @@ function Feedback(_a) {
|
|
|
97
97
|
__spreadProps(__spreadValues({}, iconProps), {
|
|
98
98
|
size: ICON_SIZE,
|
|
99
99
|
mb: "large",
|
|
100
|
-
"data-testid":
|
|
100
|
+
"data-testid": `feedback-icon-${variant}`
|
|
101
101
|
})
|
|
102
102
|
),
|
|
103
103
|
/* @__PURE__ */ jsxs(TextContainer, { children: [
|
|
@@ -49,7 +49,7 @@ describe("<Feedback />", () => {
|
|
|
49
49
|
const { getByTestId } = renderWithTheme(
|
|
50
50
|
/* @__PURE__ */ jsx(Feedback, { variant: "success", title, description })
|
|
51
51
|
);
|
|
52
|
-
expect(getByTestId("feedback-icon")).toMatchSnapshot();
|
|
52
|
+
expect(getByTestId("feedback-icon-success")).toMatchSnapshot();
|
|
53
53
|
});
|
|
54
54
|
it("should render the icon for informative variant", () => {
|
|
55
55
|
const { getByTestId } = renderWithTheme(
|
|
@@ -62,12 +62,18 @@ describe("<Feedback />", () => {
|
|
|
62
62
|
}
|
|
63
63
|
)
|
|
64
64
|
);
|
|
65
|
-
expect(getByTestId("feedback-icon")).toMatchSnapshot();
|
|
65
|
+
expect(getByTestId("feedback-icon-informative")).toMatchSnapshot();
|
|
66
66
|
});
|
|
67
67
|
it("should render the icon for attention variant", () => {
|
|
68
68
|
const { getByTestId } = renderWithTheme(
|
|
69
69
|
/* @__PURE__ */ jsx(Feedback, { variant: "attention", title, description })
|
|
70
70
|
);
|
|
71
|
-
expect(getByTestId("feedback-icon")).toMatchSnapshot();
|
|
71
|
+
expect(getByTestId("feedback-icon-attention")).toMatchSnapshot();
|
|
72
|
+
});
|
|
73
|
+
it("should render the icon for delayed variant", () => {
|
|
74
|
+
const { getByTestId } = renderWithTheme(
|
|
75
|
+
/* @__PURE__ */ jsx(Feedback, { variant: "delayed", title, description })
|
|
76
|
+
);
|
|
77
|
+
expect(getByTestId("feedback-icon-delayed")).toMatchSnapshot();
|
|
72
78
|
});
|
|
73
79
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gympass/yoga",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.92.0",
|
|
4
4
|
"description": "Gympass component library",
|
|
5
5
|
"main": "./cjs",
|
|
6
6
|
"types": "./typings/index.d.ts",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@gympass/yoga-common": "^1.3.0",
|
|
30
30
|
"@gympass/yoga-helpers": "^1.0.4",
|
|
31
|
-
"@gympass/yoga-icons": "^1.
|
|
31
|
+
"@gympass/yoga-icons": "^1.18.0",
|
|
32
32
|
"@gympass/yoga-illustrations": "^0.5.2",
|
|
33
33
|
"@gympass/yoga-system": "^0.11.1",
|
|
34
34
|
"@gympass/yoga-tokens": "^3.2.2",
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
"react-native": "0.72.3",
|
|
58
58
|
"styled-components": "^4.4.0"
|
|
59
59
|
},
|
|
60
|
-
"gitHead": "
|
|
60
|
+
"gitHead": "d3d44375e5ab0b126e8df60bd41618494f10e935",
|
|
61
61
|
"module": "./esm",
|
|
62
62
|
"private": false,
|
|
63
63
|
"react-native": "./cjs/index.native.js"
|