trepur_components 0.2.36 → 0.2.37
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.
|
@@ -101,16 +101,19 @@ const Card = _ref => {
|
|
|
101
101
|
let imageClassList = 'w-full ';
|
|
102
102
|
imageClassList += !cardImageBelowTitle ? roundedImage : '';
|
|
103
103
|
imageClassList += cardImageClass;
|
|
104
|
+
|
|
105
|
+
const toggleHover = isHovering => {
|
|
106
|
+
onHover && isHovering ? setShowHoverButtons(true) : setShowHoverButtons(false);
|
|
107
|
+
};
|
|
108
|
+
|
|
104
109
|
return /*#__PURE__*/_react.default.createElement("div", _extends({
|
|
105
110
|
key: cardId
|
|
106
111
|
}, cardId && {
|
|
107
112
|
id: cardId
|
|
108
113
|
}, {
|
|
109
|
-
className: classList
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
}, onHover && {
|
|
113
|
-
onMouseLeave: () => setShowHoverButtons(false)
|
|
114
|
+
className: classList,
|
|
115
|
+
onMouseEnter: () => toggleHover(true),
|
|
116
|
+
onMouseLeave: () => toggleHover(false)
|
|
114
117
|
}), /*#__PURE__*/_react.default.createElement("div", {
|
|
115
118
|
className: "card-content flex flex-1 flex-col"
|
|
116
119
|
}, mp4File || webmFile || ogvFile ? /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -49,7 +49,6 @@ const Form = _ref => {
|
|
|
49
49
|
}), components && components.map(component => {
|
|
50
50
|
if (component.type === 'Input') {
|
|
51
51
|
return /*#__PURE__*/_react.default.createElement(_Input.default, {
|
|
52
|
-
key: i,
|
|
53
52
|
classes: component.classes,
|
|
54
53
|
label: component.label,
|
|
55
54
|
placeholder: component.placeholder,
|
|
@@ -58,7 +57,6 @@ const Form = _ref => {
|
|
|
58
57
|
});
|
|
59
58
|
} else if (component.type === 'Button') {
|
|
60
59
|
return /*#__PURE__*/_react.default.createElement(_Button.default, {
|
|
61
|
-
key: i,
|
|
62
60
|
type: component.htmlType,
|
|
63
61
|
onClick: onClick,
|
|
64
62
|
classes: component.classes,
|