@gympass/yoga 7.130.0 → 7.131.1
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/cjs/ActionRequirement/native/ActionRequirement.js +29 -16
- package/cjs/Avatar/native/Avatar.js +12 -18
- package/cjs/Banner/native/Banner.js +44 -36
- package/cjs/Button/native/Button.js +79 -81
- package/cjs/Button/native/Icon.js +6 -14
- package/cjs/Button/native/Link.js +18 -5
- package/cjs/Button/native/Outline.js +11 -17
- package/cjs/Button/native/withTouchable.js +5 -11
- package/cjs/Card/native/Card/Card.js +2 -8
- package/cjs/Card/native/EventCard/EventCard.js +13 -18
- package/cjs/Card/native/GymCard/CheckIn/CheckIn.js +1 -4
- package/cjs/Card/native/PlanCard/Content.js +7 -14
- package/cjs/Card/native/PlanCard/List.js +3 -8
- package/cjs/Card/native/PlanCard/PlanCard.js +7 -5
- package/cjs/Checkbox/native/Checkbox.js +11 -22
- package/cjs/Checkbox/native/Switch.js +3 -8
- package/cjs/Chips/native/Chips.js +6 -15
- package/cjs/Divider/native/Divider.js +1 -4
- package/cjs/Dropdown/native/Backdrop.js +4 -9
- package/cjs/Dropdown/native/Dropdown.js +8 -17
- package/cjs/Dropdown/native/Options.android.js +2 -6
- package/cjs/Dropdown/native/Options.ios.js +5 -10
- package/cjs/Input/native/Helper.js +8 -18
- package/cjs/Input/native/Input.js +18 -35
- package/cjs/Input/native/Password.js +7 -14
- package/cjs/Input/web/Input.js +9 -3
- package/cjs/Input/web/Input.test.js +9 -0
- package/cjs/List/native/ListItem.js +3 -8
- package/cjs/Progress/native/Progress.js +14 -10
- package/cjs/RadioGroup/native/Button/RadioButton.js +1 -4
- package/cjs/RadioGroup/native/Radio/Radio.js +1 -5
- package/cjs/RadioGroup/native/RadioGroup.js +12 -7
- package/cjs/Rating/native/Rating.js +8 -17
- package/cjs/Result/native/Attendances.js +1 -5
- package/cjs/Result/native/Details.js +4 -9
- package/cjs/Result/native/Result/index.js +7 -16
- package/cjs/Result/native/Tags.js +1 -4
- package/cjs/Skeleton/native/Skeleton.js +10 -7
- package/cjs/Slider/native/Label.js +1 -4
- package/cjs/Slider/native/Marker.js +15 -20
- package/cjs/Slider/native/Slider.js +8 -18
- package/cjs/Slider/native/Step.js +1 -4
- package/cjs/Slider/native/Tooltip.js +9 -6
- package/cjs/Snackbar/native/Snackbar.js +9 -20
- package/cjs/Snackbar/native/SnackbarAnimationWrapper.js +1 -4
- package/cjs/Stepper/native/Dots.js +1 -6
- package/cjs/Stepper/native/Line.js +1 -6
- package/cjs/Stepper/native/Stepper.js +1 -6
- package/cjs/Tag/native/Informative.js +4 -10
- package/cjs/Tag/native/Tag.js +11 -6
- package/cjs/Text/native/Text.js +40 -9
- package/cjs/TextArea/native/TextArea.js +38 -17
- package/esm/ActionRequirement/native/ActionRequirement.js +29 -16
- package/esm/Avatar/native/Avatar.js +12 -18
- package/esm/Banner/native/Banner.js +44 -36
- package/esm/Button/native/Button.js +79 -81
- package/esm/Button/native/Icon.js +6 -14
- package/esm/Button/native/Link.js +18 -5
- package/esm/Button/native/Outline.js +11 -17
- package/esm/Button/native/withTouchable.js +5 -11
- package/esm/Card/native/Card/Card.js +2 -8
- package/esm/Card/native/EventCard/EventCard.js +13 -18
- package/esm/Card/native/GymCard/CheckIn/CheckIn.js +1 -4
- package/esm/Card/native/PlanCard/Content.js +7 -14
- package/esm/Card/native/PlanCard/List.js +3 -8
- package/esm/Card/native/PlanCard/PlanCard.js +7 -5
- package/esm/Checkbox/native/Checkbox.js +11 -22
- package/esm/Checkbox/native/Switch.js +3 -8
- package/esm/Chips/native/Chips.js +6 -15
- package/esm/Divider/native/Divider.js +1 -4
- package/esm/Dropdown/native/Backdrop.js +4 -9
- package/esm/Dropdown/native/Dropdown.js +8 -17
- package/esm/Dropdown/native/Options.android.js +2 -6
- package/esm/Dropdown/native/Options.ios.js +5 -10
- package/esm/Input/native/Helper.js +8 -18
- package/esm/Input/native/Input.js +18 -35
- package/esm/Input/native/Password.js +7 -14
- package/esm/Input/web/Input.js +9 -3
- package/esm/Input/web/Input.test.js +9 -0
- package/esm/List/native/ListItem.js +3 -8
- package/esm/Progress/native/Progress.js +14 -10
- package/esm/RadioGroup/native/Button/RadioButton.js +1 -4
- package/esm/RadioGroup/native/Radio/Radio.js +1 -5
- package/esm/RadioGroup/native/RadioGroup.js +12 -7
- package/esm/Rating/native/Rating.js +8 -17
- package/esm/Result/native/Attendances.js +1 -5
- package/esm/Result/native/Details.js +4 -9
- package/esm/Result/native/Result/index.js +7 -16
- package/esm/Result/native/Tags.js +1 -4
- package/esm/Skeleton/native/Skeleton.js +10 -7
- package/esm/Slider/native/Label.js +1 -4
- package/esm/Slider/native/Marker.js +15 -20
- package/esm/Slider/native/Slider.js +8 -18
- package/esm/Slider/native/Step.js +1 -4
- package/esm/Slider/native/Tooltip.js +9 -6
- package/esm/Snackbar/native/Snackbar.js +9 -20
- package/esm/Snackbar/native/SnackbarAnimationWrapper.js +1 -4
- package/esm/Stepper/native/Dots.js +1 -6
- package/esm/Stepper/native/Line.js +1 -6
- package/esm/Stepper/native/Stepper.js +1 -6
- package/esm/Tag/native/Informative.js +4 -10
- package/esm/Tag/native/Tag.js +11 -6
- package/esm/Text/native/Text.js +40 -9
- package/esm/TextArea/native/TextArea.js +38 -17
- package/package.json +2 -2
|
@@ -17,6 +17,18 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
var __objRest = (source, exclude) => {
|
|
21
|
+
var target = {};
|
|
22
|
+
for (var prop in source)
|
|
23
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
24
|
+
target[prop] = source[prop];
|
|
25
|
+
if (source != null && __getOwnPropSymbols)
|
|
26
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
27
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
28
|
+
target[prop] = source[prop];
|
|
29
|
+
}
|
|
30
|
+
return target;
|
|
31
|
+
};
|
|
20
32
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
21
33
|
import React from "react";
|
|
22
34
|
import { arrayOf, bool, node, oneOfType, string } from "prop-types";
|
|
@@ -26,17 +38,25 @@ import Box from "../../Box";
|
|
|
26
38
|
import { Title } from "./ActionRequirementStyles";
|
|
27
39
|
import Text from "../../Text";
|
|
28
40
|
const StyledActionRequirement = styled.View``;
|
|
29
|
-
function ActionRequirement(
|
|
30
|
-
|
|
41
|
+
function ActionRequirement(_a) {
|
|
42
|
+
var _b = _a, {
|
|
31
43
|
title,
|
|
32
44
|
description,
|
|
33
|
-
children,
|
|
34
|
-
checkable,
|
|
35
|
-
illustration,
|
|
36
|
-
list,
|
|
37
|
-
titleAsTextDisplay
|
|
38
|
-
} =
|
|
39
|
-
|
|
45
|
+
children = void 0,
|
|
46
|
+
checkable = void 0,
|
|
47
|
+
illustration = void 0,
|
|
48
|
+
list = void 0,
|
|
49
|
+
titleAsTextDisplay = false
|
|
50
|
+
} = _b, rest = __objRest(_b, [
|
|
51
|
+
"title",
|
|
52
|
+
"description",
|
|
53
|
+
"children",
|
|
54
|
+
"checkable",
|
|
55
|
+
"illustration",
|
|
56
|
+
"list",
|
|
57
|
+
"titleAsTextDisplay"
|
|
58
|
+
]);
|
|
59
|
+
return /* @__PURE__ */ jsxs(StyledActionRequirement, __spreadProps(__spreadValues({}, rest), { children: [
|
|
40
60
|
illustration && /* @__PURE__ */ jsx(Box, { children: illustration }),
|
|
41
61
|
titleAsTextDisplay ? /* @__PURE__ */ jsx(Text.Display2, { children: title }) : /* @__PURE__ */ jsx(Title, { children: title }),
|
|
42
62
|
/* @__PURE__ */ jsx(Text.Body1, { mt: "small", color: "deep", children: description }),
|
|
@@ -54,13 +74,6 @@ ActionRequirement.propTypes = {
|
|
|
54
74
|
list: oneOfType([arrayOf(node), node]),
|
|
55
75
|
titleAsTextDisplay: bool
|
|
56
76
|
};
|
|
57
|
-
ActionRequirement.defaultProps = {
|
|
58
|
-
children: void 0,
|
|
59
|
-
checkable: void 0,
|
|
60
|
-
illustration: void 0,
|
|
61
|
-
list: void 0,
|
|
62
|
-
titleAsTextDisplay: false
|
|
63
|
-
};
|
|
64
77
|
var ActionRequirement_default = ActionRequirement;
|
|
65
78
|
export {
|
|
66
79
|
ActionRequirement_default as default
|
|
@@ -49,7 +49,13 @@ const BorderImage = styled(Box).attrs(({ theme: { yoga } }) => {
|
|
|
49
49
|
})`
|
|
50
50
|
position: absolute;
|
|
51
51
|
`;
|
|
52
|
-
const Content = ({
|
|
52
|
+
const Content = ({
|
|
53
|
+
icon = BuildingFilled,
|
|
54
|
+
src = void 0,
|
|
55
|
+
fill = "white",
|
|
56
|
+
content,
|
|
57
|
+
stroke
|
|
58
|
+
}) => {
|
|
53
59
|
if (src) {
|
|
54
60
|
return /* @__PURE__ */ jsx(Box, { as: Image, width: "100%", height: "100%", source: src });
|
|
55
61
|
}
|
|
@@ -62,13 +68,13 @@ const Avatar = forwardRef(
|
|
|
62
68
|
(_a, ref) => {
|
|
63
69
|
var _b = _a, {
|
|
64
70
|
icon = BuildingFilled,
|
|
65
|
-
src,
|
|
71
|
+
src = void 0,
|
|
66
72
|
children,
|
|
67
|
-
fill,
|
|
73
|
+
fill = "white",
|
|
68
74
|
stroke,
|
|
69
|
-
borderRadius,
|
|
70
|
-
width,
|
|
71
|
-
height
|
|
75
|
+
borderRadius = "small",
|
|
76
|
+
width = 48,
|
|
77
|
+
height = 48
|
|
72
78
|
} = _b, props = __objRest(_b, [
|
|
73
79
|
"icon",
|
|
74
80
|
"src",
|
|
@@ -114,11 +120,6 @@ Content.propTypes = __spreadValues({
|
|
|
114
120
|
icon: func,
|
|
115
121
|
fill: string
|
|
116
122
|
}, Box.propTypes);
|
|
117
|
-
Content.defaultProps = {
|
|
118
|
-
src: void 0,
|
|
119
|
-
fill: "white",
|
|
120
|
-
icon: BuildingFilled
|
|
121
|
-
};
|
|
122
123
|
Avatar.propTypes = __spreadValues({
|
|
123
124
|
src: ImagePropTypes.source,
|
|
124
125
|
icon: func,
|
|
@@ -127,13 +128,6 @@ Avatar.propTypes = __spreadValues({
|
|
|
127
128
|
height: number,
|
|
128
129
|
borderRadius: string
|
|
129
130
|
}, Box.propTypes);
|
|
130
|
-
Avatar.defaultProps = __spreadValues({
|
|
131
|
-
src: void 0,
|
|
132
|
-
fill: "white",
|
|
133
|
-
width: 48,
|
|
134
|
-
height: 48,
|
|
135
|
-
borderRadius: "small"
|
|
136
|
-
}, Box.defaultProps);
|
|
137
131
|
Avatar.displayName = "Avatar";
|
|
138
132
|
var Avatar_default = Avatar;
|
|
139
133
|
export {
|
|
@@ -87,38 +87,52 @@ BannerActionButton.propTypes = {
|
|
|
87
87
|
action: func.isRequired
|
|
88
88
|
}).isRequired
|
|
89
89
|
};
|
|
90
|
-
const Banner = forwardRef(
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
90
|
+
const Banner = forwardRef(
|
|
91
|
+
(_c, ref) => {
|
|
92
|
+
var _d = _c, {
|
|
93
|
+
icon = void 0,
|
|
94
|
+
variant = "informative",
|
|
95
|
+
message,
|
|
96
|
+
primaryButton = void 0,
|
|
97
|
+
secondaryButton = void 0
|
|
98
|
+
} = _d, rest = __objRest(_d, [
|
|
99
|
+
"icon",
|
|
100
|
+
"variant",
|
|
101
|
+
"message",
|
|
102
|
+
"primaryButton",
|
|
103
|
+
"secondaryButton"
|
|
104
|
+
]);
|
|
105
|
+
return /* @__PURE__ */ jsxs(StyledBanner, __spreadProps(__spreadValues({ ref, variant }, rest), { children: [
|
|
106
|
+
/* @__PURE__ */ jsxs(Box, { flexDirection: "row", flex: 1, alignItems: "center", children: [
|
|
107
|
+
icon && /* @__PURE__ */ jsx(
|
|
108
|
+
Icon,
|
|
109
|
+
{
|
|
110
|
+
as: icon,
|
|
111
|
+
size: "medium",
|
|
112
|
+
fill: "secondary",
|
|
113
|
+
marginRight: "xxsmall"
|
|
114
|
+
}
|
|
115
|
+
),
|
|
116
|
+
/* @__PURE__ */ jsx(Text.Body2, { flex: 1, marginTop: "xxsmall", marginBottom: "xxsmall", children: message }),
|
|
117
|
+
primaryButton && !secondaryButton && /* @__PURE__ */ jsx(BannerActionButton, { button: primaryButton, marginLeft: "xxsmall" })
|
|
118
|
+
] }),
|
|
119
|
+
primaryButton && secondaryButton && /* @__PURE__ */ jsxs(
|
|
120
|
+
Box,
|
|
96
121
|
{
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
122
|
+
display: "flex",
|
|
123
|
+
flex: 1,
|
|
124
|
+
justifyContent: "flex-end",
|
|
125
|
+
flexDirection: "row",
|
|
126
|
+
marginBottom: "xxsmall",
|
|
127
|
+
children: [
|
|
128
|
+
/* @__PURE__ */ jsx(BannerActionButton, { button: primaryButton, marginRight: "xxxsmall" }),
|
|
129
|
+
/* @__PURE__ */ jsx(BannerActionButton, { button: secondaryButton })
|
|
130
|
+
]
|
|
101
131
|
}
|
|
102
|
-
)
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
primaryButton && secondaryButton && /* @__PURE__ */ jsxs(
|
|
107
|
-
Box,
|
|
108
|
-
{
|
|
109
|
-
display: "flex",
|
|
110
|
-
flex: 1,
|
|
111
|
-
justifyContent: "flex-end",
|
|
112
|
-
flexDirection: "row",
|
|
113
|
-
marginBottom: "xxsmall",
|
|
114
|
-
children: [
|
|
115
|
-
/* @__PURE__ */ jsx(BannerActionButton, { button: primaryButton, marginRight: "xxxsmall" }),
|
|
116
|
-
/* @__PURE__ */ jsx(BannerActionButton, { button: secondaryButton })
|
|
117
|
-
]
|
|
118
|
-
}
|
|
119
|
-
)
|
|
120
|
-
] }));
|
|
121
|
-
});
|
|
132
|
+
)
|
|
133
|
+
] }));
|
|
134
|
+
}
|
|
135
|
+
);
|
|
122
136
|
const BannerActionButtonType = shape({
|
|
123
137
|
label: string.isRequired,
|
|
124
138
|
action: func.isRequired
|
|
@@ -148,12 +162,6 @@ Banner.propTypes = {
|
|
|
148
162
|
);
|
|
149
163
|
}
|
|
150
164
|
};
|
|
151
|
-
Banner.defaultProps = {
|
|
152
|
-
icon: void 0,
|
|
153
|
-
variant: "informative",
|
|
154
|
-
primaryButton: void 0,
|
|
155
|
-
secondaryButton: void 0
|
|
156
|
-
};
|
|
157
165
|
var Banner_default = Banner;
|
|
158
166
|
export {
|
|
159
167
|
Banner_default as default
|
|
@@ -103,83 +103,91 @@ const ButtonContainer = styled.View`
|
|
|
103
103
|
`;
|
|
104
104
|
}}
|
|
105
105
|
`;
|
|
106
|
-
const Button = forwardRef(
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
106
|
+
const Button = forwardRef((props, ref) => {
|
|
107
|
+
const defaultValues = {
|
|
108
|
+
children: "Button",
|
|
109
|
+
full: false,
|
|
110
|
+
disabled: false,
|
|
111
|
+
small: false,
|
|
112
|
+
pressed: false,
|
|
113
|
+
inverted: false,
|
|
114
|
+
secondary: false,
|
|
115
|
+
icon: void 0
|
|
116
|
+
};
|
|
117
|
+
const _a = __spreadValues(__spreadValues({}, defaultValues), props), {
|
|
118
|
+
children,
|
|
119
|
+
full,
|
|
120
|
+
disabled,
|
|
121
|
+
small,
|
|
122
|
+
pressed,
|
|
123
|
+
inverted,
|
|
124
|
+
secondary,
|
|
125
|
+
icon: Icon,
|
|
126
|
+
theme: {
|
|
127
|
+
yoga: {
|
|
128
|
+
components: { button }
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
} = _a, rest = __objRest(_a, [
|
|
132
|
+
"children",
|
|
133
|
+
"full",
|
|
134
|
+
"disabled",
|
|
135
|
+
"small",
|
|
136
|
+
"pressed",
|
|
137
|
+
"inverted",
|
|
138
|
+
"secondary",
|
|
139
|
+
"icon",
|
|
140
|
+
"theme"
|
|
141
|
+
]);
|
|
142
|
+
const state = secondary ? "secondary" : "primary";
|
|
143
|
+
let textColor = button.types.contained.font.default.color;
|
|
144
|
+
if (disabled) {
|
|
145
|
+
textColor = button.types.contained.font.disabled.color;
|
|
146
|
+
} else if (inverted) {
|
|
147
|
+
textColor = button.types.contained.backgroundColor[state].default;
|
|
148
|
+
if (pressed) {
|
|
149
|
+
textColor = button.types.contained.backgroundColor[state].pressed;
|
|
150
|
+
}
|
|
151
|
+
} else if (pressed) {
|
|
152
|
+
textColor = button.types.contained.font.pressed.color;
|
|
153
|
+
}
|
|
154
|
+
return /* @__PURE__ */ jsxs(
|
|
155
|
+
ButtonContainer,
|
|
156
|
+
__spreadProps(__spreadValues({}, rest), {
|
|
110
157
|
full,
|
|
158
|
+
pressed,
|
|
111
159
|
disabled,
|
|
112
160
|
small,
|
|
113
|
-
pressed,
|
|
114
161
|
inverted,
|
|
115
162
|
secondary,
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
"small",
|
|
127
|
-
"pressed",
|
|
128
|
-
"inverted",
|
|
129
|
-
"secondary",
|
|
130
|
-
"icon",
|
|
131
|
-
"theme"
|
|
132
|
-
]);
|
|
133
|
-
const state = secondary ? "secondary" : "primary";
|
|
134
|
-
let textColor = button.types.contained.font.default.color;
|
|
135
|
-
if (disabled) {
|
|
136
|
-
textColor = button.types.contained.font.disabled.color;
|
|
137
|
-
} else if (inverted) {
|
|
138
|
-
textColor = button.types.contained.backgroundColor[state].default;
|
|
139
|
-
if (pressed) {
|
|
140
|
-
textColor = button.types.contained.backgroundColor[state].pressed;
|
|
141
|
-
}
|
|
142
|
-
} else if (pressed) {
|
|
143
|
-
textColor = button.types.contained.font.pressed.color;
|
|
144
|
-
}
|
|
145
|
-
return /* @__PURE__ */ jsxs(
|
|
146
|
-
ButtonContainer,
|
|
147
|
-
__spreadProps(__spreadValues({}, rest), {
|
|
148
|
-
full,
|
|
149
|
-
pressed,
|
|
150
|
-
disabled,
|
|
151
|
-
small,
|
|
152
|
-
inverted,
|
|
153
|
-
secondary,
|
|
154
|
-
ref,
|
|
155
|
-
children: [
|
|
156
|
-
Icon && /* @__PURE__ */ jsx(
|
|
157
|
-
Icon,
|
|
158
|
-
{
|
|
159
|
-
width: small ? button.icon.size.small : button.icon.size.default,
|
|
160
|
-
height: small ? button.icon.size.small : button.icon.size.default,
|
|
161
|
-
fill: textColor,
|
|
162
|
-
style: {
|
|
163
|
-
marginRight: button.icon.margin.right
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
),
|
|
167
|
-
/* @__PURE__ */ jsx(
|
|
168
|
-
Label,
|
|
169
|
-
{
|
|
170
|
-
disabled,
|
|
171
|
-
pressed,
|
|
172
|
-
inverted,
|
|
173
|
-
small,
|
|
174
|
-
color: textColor,
|
|
175
|
-
children
|
|
163
|
+
ref,
|
|
164
|
+
children: [
|
|
165
|
+
Icon && /* @__PURE__ */ jsx(
|
|
166
|
+
Icon,
|
|
167
|
+
{
|
|
168
|
+
width: small ? button.icon.size.small : button.icon.size.default,
|
|
169
|
+
height: small ? button.icon.size.small : button.icon.size.default,
|
|
170
|
+
fill: textColor,
|
|
171
|
+
style: {
|
|
172
|
+
marginRight: button.icon.margin.right
|
|
176
173
|
}
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
174
|
+
}
|
|
175
|
+
),
|
|
176
|
+
/* @__PURE__ */ jsx(
|
|
177
|
+
Label,
|
|
178
|
+
{
|
|
179
|
+
disabled,
|
|
180
|
+
pressed,
|
|
181
|
+
inverted,
|
|
182
|
+
small,
|
|
183
|
+
color: textColor,
|
|
184
|
+
children
|
|
185
|
+
}
|
|
186
|
+
)
|
|
187
|
+
]
|
|
188
|
+
})
|
|
189
|
+
);
|
|
190
|
+
});
|
|
183
191
|
Button.propTypes = {
|
|
184
192
|
children: node,
|
|
185
193
|
full: bool,
|
|
@@ -191,16 +199,6 @@ Button.propTypes = {
|
|
|
191
199
|
/** an Icon from yoga-icons package */
|
|
192
200
|
icon: oneOfType([bool, func])
|
|
193
201
|
};
|
|
194
|
-
Button.defaultProps = {
|
|
195
|
-
children: "Button",
|
|
196
|
-
full: false,
|
|
197
|
-
disabled: false,
|
|
198
|
-
small: false,
|
|
199
|
-
pressed: false,
|
|
200
|
-
inverted: false,
|
|
201
|
-
secondary: false,
|
|
202
|
-
icon: void 0
|
|
203
|
-
};
|
|
204
202
|
const ButtonWithTouchable = withTouchable(withTheme(Button));
|
|
205
203
|
var Button_default = ButtonWithTouchable;
|
|
206
204
|
export {
|
|
@@ -78,17 +78,17 @@ const ButtonContainer = styled.View`
|
|
|
78
78
|
const ButtonIcon = forwardRef(
|
|
79
79
|
(_a, ref) => {
|
|
80
80
|
var _b = _a, {
|
|
81
|
-
icon,
|
|
81
|
+
icon = void 0,
|
|
82
82
|
theme: {
|
|
83
83
|
yoga: {
|
|
84
84
|
components: { button }
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
|
-
small,
|
|
88
|
-
pressed,
|
|
89
|
-
disabled,
|
|
90
|
-
inverted,
|
|
91
|
-
secondary
|
|
87
|
+
small = false,
|
|
88
|
+
pressed = false,
|
|
89
|
+
disabled = false,
|
|
90
|
+
inverted = false,
|
|
91
|
+
secondary = false
|
|
92
92
|
} = _b, props = __objRest(_b, [
|
|
93
93
|
"icon",
|
|
94
94
|
"theme",
|
|
@@ -141,14 +141,6 @@ ButtonIcon.propTypes = {
|
|
|
141
141
|
secondary: bool,
|
|
142
142
|
icon: oneOfType([node, func])
|
|
143
143
|
};
|
|
144
|
-
ButtonIcon.defaultProps = {
|
|
145
|
-
small: false,
|
|
146
|
-
disabled: false,
|
|
147
|
-
pressed: false,
|
|
148
|
-
inverted: false,
|
|
149
|
-
secondary: false,
|
|
150
|
-
icon: void 0
|
|
151
|
-
};
|
|
152
144
|
ButtonIcon.displayName = "Button.Icon";
|
|
153
145
|
var Icon_default = withTouchable(withTheme(ButtonIcon));
|
|
154
146
|
export {
|
|
@@ -17,6 +17,18 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
var __objRest = (source, exclude) => {
|
|
21
|
+
var target = {};
|
|
22
|
+
for (var prop in source)
|
|
23
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
24
|
+
target[prop] = source[prop];
|
|
25
|
+
if (source != null && __getOwnPropSymbols)
|
|
26
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
27
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
28
|
+
target[prop] = source[prop];
|
|
29
|
+
}
|
|
30
|
+
return target;
|
|
31
|
+
};
|
|
20
32
|
import { jsx } from "react/jsx-runtime";
|
|
21
33
|
import React, { forwardRef } from "react";
|
|
22
34
|
import styled from "styled-components";
|
|
@@ -52,15 +64,16 @@ const Link = styled(Label)`
|
|
|
52
64
|
`;
|
|
53
65
|
}}
|
|
54
66
|
`;
|
|
55
|
-
const ButtonLink = forwardRef(
|
|
67
|
+
const ButtonLink = forwardRef(
|
|
68
|
+
(_a, ref) => {
|
|
69
|
+
var _b = _a, { disabled = false, secondary = false } = _b, props = __objRest(_b, ["disabled", "secondary"]);
|
|
70
|
+
return /* @__PURE__ */ jsx(Link, __spreadProps(__spreadValues({ disabled, secondary }, props), { ref }));
|
|
71
|
+
}
|
|
72
|
+
);
|
|
56
73
|
ButtonLink.propTypes = {
|
|
57
74
|
disabled: bool,
|
|
58
75
|
secondary: bool
|
|
59
76
|
};
|
|
60
|
-
ButtonLink.defaultProps = {
|
|
61
|
-
disabled: false,
|
|
62
|
-
secondary: false
|
|
63
|
-
};
|
|
64
77
|
ButtonLink.displayName = "Button.Link";
|
|
65
78
|
var Link_default = withTouchable(ButtonLink);
|
|
66
79
|
export {
|
|
@@ -107,12 +107,13 @@ const ButtonContainerOutline = styled(ButtonContainer)`
|
|
|
107
107
|
const ButtonOutline = forwardRef(
|
|
108
108
|
(_a, ref) => {
|
|
109
109
|
var _b = _a, {
|
|
110
|
-
children,
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
small,
|
|
114
|
-
|
|
115
|
-
inverted,
|
|
110
|
+
children = "Button",
|
|
111
|
+
full = false,
|
|
112
|
+
disabled = false,
|
|
113
|
+
small = false,
|
|
114
|
+
pressed = false,
|
|
115
|
+
inverted = false,
|
|
116
|
+
secondary = false,
|
|
116
117
|
theme: {
|
|
117
118
|
yoga: {
|
|
118
119
|
colors,
|
|
@@ -125,11 +126,12 @@ const ButtonOutline = forwardRef(
|
|
|
125
126
|
}
|
|
126
127
|
} = _b, rest = __objRest(_b, [
|
|
127
128
|
"children",
|
|
129
|
+
"full",
|
|
128
130
|
"disabled",
|
|
129
|
-
"pressed",
|
|
130
131
|
"small",
|
|
131
|
-
"
|
|
132
|
+
"pressed",
|
|
132
133
|
"inverted",
|
|
134
|
+
"secondary",
|
|
133
135
|
"theme"
|
|
134
136
|
]);
|
|
135
137
|
const state = secondary ? "secondary" : "primary";
|
|
@@ -147,6 +149,7 @@ const ButtonOutline = forwardRef(
|
|
|
147
149
|
return /* @__PURE__ */ jsx(
|
|
148
150
|
ButtonContainerOutline,
|
|
149
151
|
__spreadProps(__spreadValues({}, rest), {
|
|
152
|
+
full,
|
|
150
153
|
disabled,
|
|
151
154
|
pressed,
|
|
152
155
|
small,
|
|
@@ -179,15 +182,6 @@ ButtonOutline.propTypes = {
|
|
|
179
182
|
inverted: bool,
|
|
180
183
|
secondary: bool
|
|
181
184
|
};
|
|
182
|
-
ButtonOutline.defaultProps = {
|
|
183
|
-
children: "Button",
|
|
184
|
-
full: false,
|
|
185
|
-
disabled: false,
|
|
186
|
-
small: false,
|
|
187
|
-
pressed: false,
|
|
188
|
-
inverted: false,
|
|
189
|
-
secondary: false
|
|
190
|
-
};
|
|
191
185
|
var Outline_default = withTouchable(withTheme(ButtonOutline));
|
|
192
186
|
export {
|
|
193
187
|
Outline_default as default
|
|
@@ -36,9 +36,11 @@ import { element, func } from "prop-types";
|
|
|
36
36
|
const withTouchable = (Component) => {
|
|
37
37
|
const WithTouchable = (_a) => {
|
|
38
38
|
var _b = _a, {
|
|
39
|
-
onPressIn
|
|
40
|
-
|
|
41
|
-
|
|
39
|
+
onPressIn = () => {
|
|
40
|
+
},
|
|
41
|
+
onPressOut = () => {
|
|
42
|
+
},
|
|
43
|
+
onChange = void 0,
|
|
42
44
|
onPress = onChange
|
|
43
45
|
} = _b, rest = __objRest(_b, [
|
|
44
46
|
"onPressIn",
|
|
@@ -70,14 +72,6 @@ const withTouchable = (Component) => {
|
|
|
70
72
|
onChange: func,
|
|
71
73
|
onPress: func
|
|
72
74
|
};
|
|
73
|
-
WithTouchable.defaultProps = {
|
|
74
|
-
onPressIn: () => {
|
|
75
|
-
},
|
|
76
|
-
onPressOut: () => {
|
|
77
|
-
},
|
|
78
|
-
onChange: void 0,
|
|
79
|
-
onPress: void 0
|
|
80
|
-
};
|
|
81
75
|
return WithTouchable;
|
|
82
76
|
};
|
|
83
77
|
withTouchable.propTypes = {
|
|
@@ -113,9 +113,9 @@ const RibbonText = styled(Text.Tiny)`
|
|
|
113
113
|
`;
|
|
114
114
|
const Card = React.forwardRef(
|
|
115
115
|
(_a, ref) => {
|
|
116
|
-
var _b = _a, { ribbon, children, hasShadow } = _b, rest = __objRest(_b, ["ribbon", "children", "hasShadow"]);
|
|
116
|
+
var _b = _a, { ribbon = {}, children = null, variant = "", hasShadow = true } = _b, rest = __objRest(_b, ["ribbon", "children", "variant", "hasShadow"]);
|
|
117
117
|
const CardWrapper = hasShadow ? CardShadow : Box;
|
|
118
|
-
return /* @__PURE__ */ jsx(CardWrapper, { children: /* @__PURE__ */ jsxs(CardStyled, __spreadProps(__spreadValues({ ref }, rest), { hasShadow, children: [
|
|
118
|
+
return /* @__PURE__ */ jsx(CardWrapper, { children: /* @__PURE__ */ jsxs(CardStyled, __spreadProps(__spreadValues({ ref }, rest), { variant, hasShadow, children: [
|
|
119
119
|
Object.keys(ribbon).length > 0 && /* @__PURE__ */ jsx(Ribbon, { variant: ribbon.variant, children: /* @__PURE__ */ jsx(RibbonText, { variant: ribbon.variant, children: ribbon.text }) }),
|
|
120
120
|
children
|
|
121
121
|
] })) });
|
|
@@ -176,12 +176,6 @@ Card.propTypes = {
|
|
|
176
176
|
/** applies a shadow to the card (enabled by default) */
|
|
177
177
|
hasShadow: bool
|
|
178
178
|
};
|
|
179
|
-
Card.defaultProps = {
|
|
180
|
-
ribbon: {},
|
|
181
|
-
children: null,
|
|
182
|
-
variant: "",
|
|
183
|
-
hasShadow: true
|
|
184
|
-
};
|
|
185
179
|
Card.displayName = "Card";
|
|
186
180
|
var Card_default = Card;
|
|
187
181
|
export {
|
|
@@ -113,9 +113,9 @@ const ButtonLink = styled(Button.Link)`
|
|
|
113
113
|
`;
|
|
114
114
|
const SmallCard = ({
|
|
115
115
|
date: { month, day, dayOfWeek },
|
|
116
|
-
active,
|
|
117
|
-
event,
|
|
118
|
-
onPress
|
|
116
|
+
active = false,
|
|
117
|
+
event = void 0,
|
|
118
|
+
onPress = void 0
|
|
119
119
|
}) => /* @__PURE__ */ jsxs(DateInfo, { small: true, active, pv: "medium", bg: active ? "primary" : "white", children: [
|
|
120
120
|
/* @__PURE__ */ jsx(Top, { children: onPress ? /* @__PURE__ */ jsx(
|
|
121
121
|
Indicator,
|
|
@@ -161,8 +161,16 @@ const FullCard = withTheme(
|
|
|
161
161
|
] })
|
|
162
162
|
] })
|
|
163
163
|
);
|
|
164
|
-
const EventCard = (
|
|
165
|
-
|
|
164
|
+
const EventCard = (props) => {
|
|
165
|
+
const defaultValues = {
|
|
166
|
+
small: false,
|
|
167
|
+
active: false,
|
|
168
|
+
event: void 0,
|
|
169
|
+
link: "",
|
|
170
|
+
onLinkPress: void 0,
|
|
171
|
+
onPress: void 0
|
|
172
|
+
};
|
|
173
|
+
const _a = __spreadValues(__spreadValues({}, defaultValues), props), { onPress, small } = _a, rest = __objRest(_a, ["onPress", "small"]);
|
|
166
174
|
return /* @__PURE__ */ jsx(TouchableWithoutFeedback, { onPress, children: /* @__PURE__ */ jsx(Event, __spreadProps(__spreadValues({ small }, rest), { children: small ? /* @__PURE__ */ jsx(SmallCard, __spreadValues({ onPress }, rest)) : /* @__PURE__ */ jsx(FullCard, __spreadValues({}, rest)) })) });
|
|
167
175
|
};
|
|
168
176
|
EventCard.propTypes = {
|
|
@@ -187,14 +195,6 @@ EventCard.propTypes = {
|
|
|
187
195
|
onLinkPress: func,
|
|
188
196
|
onPress: func
|
|
189
197
|
};
|
|
190
|
-
EventCard.defaultProps = {
|
|
191
|
-
small: false,
|
|
192
|
-
active: false,
|
|
193
|
-
event: void 0,
|
|
194
|
-
link: "",
|
|
195
|
-
onLinkPress: void 0,
|
|
196
|
-
onPress: void 0
|
|
197
|
-
};
|
|
198
198
|
SmallCard.propTypes = {
|
|
199
199
|
date: shape({
|
|
200
200
|
day: string,
|
|
@@ -212,11 +212,6 @@ SmallCard.propTypes = {
|
|
|
212
212
|
]),
|
|
213
213
|
onPress: func
|
|
214
214
|
};
|
|
215
|
-
SmallCard.defaultProps = {
|
|
216
|
-
active: false,
|
|
217
|
-
event: void 0,
|
|
218
|
-
onPress: void 0
|
|
219
|
-
};
|
|
220
215
|
FullCard.propTypes = EventCard.propTypes;
|
|
221
216
|
EventCard.displayName = "EventCard";
|
|
222
217
|
var EventCard_default = EventCard;
|
|
@@ -67,7 +67,7 @@ const CheckIn = (_a) => {
|
|
|
67
67
|
var _b = _a, {
|
|
68
68
|
name,
|
|
69
69
|
address,
|
|
70
|
-
avatar,
|
|
70
|
+
avatar = void 0,
|
|
71
71
|
distance,
|
|
72
72
|
rating,
|
|
73
73
|
theme: {
|
|
@@ -103,9 +103,6 @@ CheckIn.propTypes = {
|
|
|
103
103
|
distance: string.isRequired,
|
|
104
104
|
rating: number.isRequired
|
|
105
105
|
};
|
|
106
|
-
CheckIn.defaultProps = {
|
|
107
|
-
avatar: void 0
|
|
108
|
-
};
|
|
109
106
|
CheckIn.displayName = "GymCard.CheckIn";
|
|
110
107
|
var CheckIn_default = withTheme(CheckIn);
|
|
111
108
|
export {
|