UNPKG

fannypack-v5

Version:

An accessible, composable, and friendly React UI Kit

177 lines (147 loc) 6.04 kB
import 'react'; import '../Provider/ThemeContext.js'; import 'classnames'; import { css } from 'emotion'; import '@emotion/core'; import 'emotion-theming'; import '@emotion/styled'; import '../utils/useTheme.js'; import { a as _taggedTemplateLiteralLoose } from '../chunk-0c448560.js'; import 'lodash/kebabCase'; import 'tinycolor2'; import '../utils/isFunction.js'; import '../utils/get.js'; import { theme, fontSize, palette, space, fontWeight, altitude } from '../utils/theme.js'; import '../utils/omit.js'; import '../utils/pick.js'; import '../utils/cssProps.js'; import '../utils/useLocalStorage.js'; import '../Provider/ColorModeContext.js'; import '../utils/useColorMode.js'; import '../utils/useStyle.js'; import '../utils/omitBy.js'; import '../utils/useDefaultProps.js'; import '../utils/useDebounce.js'; import 'lodash/uniq'; import '../utils/useClassName.js'; import '../utils/useBreakpoint.js'; import '../utils/uniqueId.js'; import '../utils/times.js'; import '../utils/parseIcons.js'; import '../utils/colors.js'; import '../utils/palette.js'; import '../utils/mergeRefs.js'; import 'deepmerge'; import 'lodash/set'; import '../utils/applyTheme.js'; import '../utils/bindFns.js'; import '../utils/createComponent.js'; import '../utils/createElement.js'; import '../utils/createHook.js'; import '../utils/forwardRefWithUse.js'; import '../utils/fieldAdaptors.js'; import '@emotion/is-prop-valid'; import '../utils/htmlProps.js'; import '../utils/OutsideClickHandler.js'; function _templateObject9() { var data = _taggedTemplateLiteralLoose(["\n && {\n position: absolute;\n padding: ", "rem;\n margin-top: ", "rem;\n width: max-content;\n max-width: 400px;\n z-index: 999999;\n ", ";\n }\n\n & {\n ", ";\n }\n"]); _templateObject9 = function _templateObject9() { return data; }; return data; } function _templateObject8() { var data = _taggedTemplateLiteralLoose(["\n && {\n font-size: ", "rem;\n padding: ", "rem;\n min-height: unset;\n }\n\n & {\n ", ";\n }\n"]); _templateObject8 = function _templateObject8() { return data; }; return data; } function _templateObject7() { var data = _taggedTemplateLiteralLoose(["\n display: block;\n font-size: ", "rem;\n\n & {\n ", ";\n }\n"]); _templateObject7 = function _templateObject7() { return data; }; return data; } function _templateObject6() { var data = _taggedTemplateLiteralLoose(["\n color: ", ";\n margin-left: ", "rem;\n font-weight: ", ";\n font-size: ", "rem;\n\n & {\n ", ";\n }\n"]); _templateObject6 = function _templateObject6() { return data; }; return data; } function _templateObject5() { var data = _taggedTemplateLiteralLoose(["\n font-size: ", "rem;\n color: ", ";\n margin-left: ", "rem;\n line-height: 1;\n\n & {\n ", ";\n }\n"]); _templateObject5 = function _templateObject5() { return data; }; return data; } function _templateObject4() { var data = _taggedTemplateLiteralLoose(["\n display: block;\n font-size: ", "rem;\n\n & {\n ", ";\n }\n"]); _templateObject4 = function _templateObject4() { return data; }; return data; } function _templateObject3() { var data = _taggedTemplateLiteralLoose(["\n display: block;\n font-size: ", "rem;\n\n & {\n ", ";\n }\n"]); _templateObject3 = function _templateObject3() { return data; }; return data; } function _templateObject2() { var data = _taggedTemplateLiteralLoose(["\n & {\n ", ";\n }\n"]); _templateObject2 = function _templateObject2() { return data; }; return data; } function _templateObject() { var data = _taggedTemplateLiteralLoose(["\n & {\n ", ";\n }\n"]); _templateObject = function _templateObject() { return data; }; return data; } var FieldWrapper = function FieldWrapper(styleProps) { return css(_templateObject(), theme(styleProps.themeKey, "css.root")(styleProps)); }; var Label = function Label(styleProps) { return css(_templateObject2(), theme(styleProps.themeKey, "css.root")(styleProps)); }; var DescriptionText = function DescriptionText(styleProps) { return css(_templateObject3(), fontSize('150')(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var HintText = function HintText(styleProps) { return css(_templateObject4(), fontSize('150')(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var OptionalText = function OptionalText(styleProps) { return css(_templateObject5(), fontSize('150')(styleProps), palette('text100')(styleProps), space(2)(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var RequiredText = function RequiredText(styleProps) { return css(_templateObject6(), palette('danger')(styleProps), space(1)(styleProps), fontWeight('semibold')(styleProps), fontSize('150')(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var ValidationText = function ValidationText(styleProps) { return css(_templateObject7(), fontSize('150')(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var TooltipTrigger = function TooltipTrigger(styleProps) { return css(_templateObject8(), fontSize('100')(styleProps), space(1)(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var TooltipPopover = function TooltipPopover(styleProps) { return css(_templateObject9(), space(1, 'major')(styleProps), space(1, 'major')(styleProps), altitude('300')(styleProps), theme(styleProps.themeKey, "css.root")(styleProps)); }; var styles = /*#__PURE__*/Object.freeze({ FieldWrapper: FieldWrapper, Label: Label, DescriptionText: DescriptionText, HintText: HintText, OptionalText: OptionalText, RequiredText: RequiredText, ValidationText: ValidationText, TooltipTrigger: TooltipTrigger, TooltipPopover: TooltipPopover }); export { DescriptionText as D, FieldWrapper as F, HintText as H, Label as L, OptionalText as O, RequiredText as R, TooltipTrigger as T, ValidationText as V, TooltipPopover as a, styles as s };