@activecollab/components
Version:
ActiveCollab Components
40 lines (39 loc) • 3.47 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.StyledLabel = exports.StyledInput = exports.StyledCheckbox = void 0;
var _styledComponents = _interopRequireWildcard(require("styled-components"));
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
var StyledInput = exports.StyledInput = _styledComponents.default.input.withConfig({
displayName: "Styles__StyledInput",
componentId: "sc-y7zymm-0"
})(["border:0px;clip:rect(0px,0px,0px,0px);cursor:pointer;height:1px;margin:-1px;opacity:0;overflow:hidden;padding:0px;position:absolute;white-space:nowrap;width:1px;"]);
StyledInput.displayName = "StyledInput";
var StyledLabel = exports.StyledLabel = _styledComponents.default.label.withConfig({
displayName: "Styles__StyledLabel",
componentId: "sc-y7zymm-1"
})([""]);
StyledLabel.displayName = "StyledLabel";
var StyledCheckbox = exports.StyledCheckbox = _styledComponents.default.div.withConfig({
displayName: "Styles__StyledCheckbox",
componentId: "sc-y7zymm-2"
})(["height:16px;width:16px;position:relative;transition-duration:0.2s;border-radius:2px;path{transition-duration:0.2s;stroke:transparent;stroke-dashoffset:12;stroke-dasharray:12;}svg{cursor:pointer;border-radius:2px;fill:transparent;}", " rect{transition-duration:0.2s;", " ", "}", ":disabled ~ ", "{opacity:0.5;cursor:not-allowed;}", ":focus ~ ", "{", "}&:not(.c-checkbox__controlled) ", ":hover:not(:checked) ~ ", "{path{stroke:var(--color-secondary-500);stroke-dashoffset:24;}rect{stroke:var(--color-secondary);", " stroke-width:3px;}}", " ", ":checked ~ ", "{path{", "}rect{stroke:var(--color-secondary);stroke-width:19px;", "}}"], function (props) {
return props.$disabled && (0, _styledComponents.css)(["svg{cursor:not-allowed;}"]);
}, function (props) {
return !props.mixed && (0, _styledComponents.css)(["stroke:var(--color-theme-500);"]);
}, function (props) {
return props.mixed && (0, _styledComponents.css)(["stroke:transparent;"]);
}, StyledInput, StyledLabel, StyledInput, StyledLabel, function (props) {
return !props.mixed && (0, _styledComponents.css)(["rect{stroke:var(--color-secondary);stroke-width:3px;}"]);
}, StyledInput, StyledLabel, function (props) {
return props.mixed && (0, _styledComponents.css)(["stroke:transparent;"]);
}, function (props) {
return props.hover && !props.mixed && (0, _styledComponents.css)(["", ":not(:checked) ~ ", "{path{stroke:var(--color-secondary-500);stroke-dashoffset:24;}rect{stroke:var(--color-secondary);stroke-width:3px;}}"], StyledInput, StyledLabel);
}, StyledInput, StyledLabel, function (props) {
return !props.mixed && (0, _styledComponents.css)(["stroke:var(--page-paper-main);stroke-dashoffset:24;"]);
}, function (props) {
return props.mixed && (0, _styledComponents.css)(["stroke:transparent;"]);
});
StyledCheckbox.displayName = "StyledCheckbox";
//# sourceMappingURL=Styles.js.map