oolib 2.188.5 → 2.188.6
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.
|
@@ -173,7 +173,7 @@ exports.CheckboxList.argTypes = {
|
|
|
173
173
|
};
|
|
174
174
|
var CheckboxInput = function (args) {
|
|
175
175
|
var _a = (0, react_1.useState)([]), value = _a[0], setValue = _a[1];
|
|
176
|
-
var _b = (0, react_1.useState)({ value: "smth", display: "Squidward" }), option = _b[0], setOption = _b[1];
|
|
176
|
+
var _b = (0, react_1.useState)({ value: "smth", display: "Squidward", desc: 'This is an explanation' }), option = _b[0], setOption = _b[1];
|
|
177
177
|
(0, react_1.useEffect)(function () {
|
|
178
178
|
setOption(__assign(__assign({}, option), { display: args.option1 }));
|
|
179
179
|
}, [args.option1]);
|
|
@@ -52,7 +52,7 @@ var useStyleUpdateAfterToggleTransition_1 = require("../../../utils/useStyleUpda
|
|
|
52
52
|
var StyledContainer = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n border-radius: 0.8rem;\n border: 1px solid ", ";\n background: #ffffff;\n box-shadow: 0px 4px 10px 0px rgba(0, 0, 0, 0.06);\n"], ["\n border-radius: 0.8rem;\n border: 1px solid ", ";\n background: #ffffff;\n box-shadow: 0px 4px 10px 0px rgba(0, 0, 0, 0.06);\n"])), colors_1.colors.grey10);
|
|
53
53
|
var StyledHeader = styled_components_1.default.button(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n width: 100%;\n padding: 1rem 1.6rem;\n text-align: left;\n background: none;\n border: none;\n cursor: pointer;\n display: flex;\n align-items: center;\n"], ["\n width: 100%;\n padding: 1rem 1.6rem;\n text-align: left;\n background: none;\n border: none;\n cursor: pointer;\n display: flex;\n align-items: center;\n"])));
|
|
54
54
|
var StyledRightHeaderSection = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n display: flex;\n align-items: center;\n"], ["\n display: flex;\n align-items: center;\n"])));
|
|
55
|
-
var ArrowWrapper = styled_components_1.default.button(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n border: none;\n background: none;\n cursor: pointer;\n width: 2rem;\n display: flex;\n align-items: center;\n justify-content: center;\n transform: rotate(", "deg);\n ", ";\n"], ["\n border: none;\n background: none;\n cursor: pointer;\n width: 2rem;\n display: flex;\n align-items: center;\n justify-content: center;\n transform: rotate(", "deg);\n ", ";\n"])), function (props) { return (props.isExpanded ?
|
|
55
|
+
var ArrowWrapper = styled_components_1.default.button(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n border: none;\n background: none;\n cursor: pointer;\n width: 2rem;\n display: flex;\n align-items: center;\n justify-content: center;\n transform: rotate(", "deg);\n ", ";\n"], ["\n border: none;\n background: none;\n cursor: pointer;\n width: 2rem;\n display: flex;\n align-items: center;\n justify-content: center;\n transform: rotate(", "deg);\n ", ";\n"])), function (props) { return (props.isExpanded ? 180 : 0); }, (0, mixins_1.transition)("transform"));
|
|
56
56
|
var StyledContentWrapper = styled_components_1.default.div(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n display: flex;\n align-items: flex-end;\n \n ", "\n height: ", ";\n"], ["\n display: flex;\n align-items: flex-end;\n \n ", "\n height: ", ";\n"])), function (_a) {
|
|
57
57
|
var expandAnimationDuration = _a.expandAnimationDuration;
|
|
58
58
|
return (0, mixins_1.transition)("height ".concat(expandAnimationDuration / 1000, "s ease-out"));
|
|
@@ -43,6 +43,8 @@ var CheckboxInput = function (_a) {
|
|
|
43
43
|
: genCheckboxButton({ disabled: true }) //else rightWrongResult has come in, but this doesnt have to be marked right or wrong
|
|
44
44
|
: genCheckboxButton() // rightWrongResult has not come in. so gen normal radio button
|
|
45
45
|
),
|
|
46
|
-
react_1.default.createElement(
|
|
46
|
+
react_1.default.createElement("div", null,
|
|
47
|
+
react_1.default.createElement(Typo2_1.UI_BODY_SM_DF, { bold: rightWrongResult && isSelected, color: disabled ? grey40 : grey80, invert: invert }, option.display),
|
|
48
|
+
option.desc && react_1.default.createElement(Typo2_1.UI_CAPTION_DF, null, option.desc))));
|
|
47
49
|
};
|
|
48
50
|
exports.CheckboxInput = CheckboxInput;
|