@pedidopago/ui 1.13.34 → 1.13.36
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"carousel-slide-container.d.ts","sourceRoot":"","sources":["../../../src/components/Carousel/carousel-slide-container.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExC,wBAAgB,sBAAsB,CAAC,EACrC,GAAQ,EACR,gBAAgB,EAChB,QAAQ,EACR,YAAY,EACZ,UAAU,EACV,WAAW,EACX,GAAG,QAAQ,EACZ,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"carousel-slide-container.d.ts","sourceRoot":"","sources":["../../../src/components/Carousel/carousel-slide-container.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExC,wBAAgB,sBAAsB,CAAC,EACrC,GAAQ,EACR,gBAAgB,EAChB,QAAQ,EACR,YAAY,EACZ,UAAU,EACV,WAAW,EACX,GAAG,QAAQ,EACZ,EAAE,aAAa,2CAsEf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";function _typeof(obj){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj},_typeof(obj)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.CarouselSlideContainer=CarouselSlideContainer;var _react=require("react"),_classnames=_interopRequireDefault(require("classnames")),_carouselContext=require("./contexts/carousel-context"),_styles=require("./styles"),_jsxRuntime=require("react/jsx-runtime"),_excluded=["gap","hideArrowButtons","children","buttonShadow","leftButton","rightButton"];function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);enumerableOnly&&(symbols=symbols.filter(function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable})),keys.push.apply(keys,symbols)}return keys}function _objectSpread(target){for(var source,i=1;i<arguments.length;i++)source=null==arguments[i]?{}:arguments[i],i%2?ownKeys(Object(source),!0).forEach(function(key){_defineProperty(target,key,source[key])}):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach(function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key))});return target}function _defineProperty(obj,key,value){return key=_toPropertyKey(key),key in obj?Object.defineProperty(obj,key,{value:value,enumerable:!0,configurable:!0,writable:!0}):obj[key]=value,obj}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return"symbol"===_typeof(key)?key:key+""}function _toPrimitive(input,hint){if("object"!==_typeof(input)||null===input)return input;var prim=input[Symbol.toPrimitive];if(prim!==void 0){var res=prim.call(input,hint||"default");if("object"!==_typeof(res))return res;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===hint?String:Number)(input)}function _objectWithoutProperties(source,excluded){if(null==source)return{};var key,i,target=_objectWithoutPropertiesLoose(source,excluded);if(Object.getOwnPropertySymbols){var sourceSymbolKeys=Object.getOwnPropertySymbols(source);for(i=0;i<sourceSymbolKeys.length;i++)key=sourceSymbolKeys[i],0<=excluded.indexOf(key)||Object.prototype.propertyIsEnumerable.call(source,key)&&(target[key]=source[key])}return target}function _objectWithoutPropertiesLoose(source,excluded){if(null==source)return{};var key,i,target={},sourceKeys=Object.keys(source);for(i=0;i<sourceKeys.length;i++)key=sourceKeys[i],0<=excluded.indexOf(key)||(target[key]=source[key]);return target}function CarouselSlideContainer(_ref){var _ref$gap=_ref.gap,gap=void 0===_ref$gap?16:_ref$gap,hideArrowButtons=_ref.hideArrowButtons,children=_ref.children,buttonShadow=_ref.buttonShadow,leftButton=_ref.leftButton,rightButton=_ref.rightButton,divProps=_objectWithoutProperties(_ref,_excluded),carouselCtx=(0,_react.useContext)(_carouselContext.CarouselContext),customLeftButton=null===leftButton||void 0===leftButton?void 0:leftButton(function(){return carouselCtx.moveCarousel("left")}),customRightButton=null===rightButton||void 0===rightButton?void 0:rightButton(function(){return carouselCtx.moveCarousel("right")});return/*#__PURE__*/(0,_jsxRuntime.jsxs)("div",_objectSpread(_objectSpread({style:{position:"relative",overflow:"hidden",width:"100%",height:"100%"}},
|
|
1
|
+
"use strict";function _typeof(obj){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(obj){return typeof obj}:function(obj){return obj&&"function"==typeof Symbol&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj},_typeof(obj)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.CarouselSlideContainer=CarouselSlideContainer;var _react=require("react"),_classnames=_interopRequireDefault(require("classnames")),_carouselContext=require("./contexts/carousel-context"),_styles=require("./styles"),_jsxRuntime=require("react/jsx-runtime"),_excluded=["gap","hideArrowButtons","children","buttonShadow","leftButton","rightButton"],_excluded2=["onScroll"];function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);enumerableOnly&&(symbols=symbols.filter(function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable})),keys.push.apply(keys,symbols)}return keys}function _objectSpread(target){for(var source,i=1;i<arguments.length;i++)source=null==arguments[i]?{}:arguments[i],i%2?ownKeys(Object(source),!0).forEach(function(key){_defineProperty(target,key,source[key])}):Object.getOwnPropertyDescriptors?Object.defineProperties(target,Object.getOwnPropertyDescriptors(source)):ownKeys(Object(source)).forEach(function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key))});return target}function _defineProperty(obj,key,value){return key=_toPropertyKey(key),key in obj?Object.defineProperty(obj,key,{value:value,enumerable:!0,configurable:!0,writable:!0}):obj[key]=value,obj}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return"symbol"===_typeof(key)?key:key+""}function _toPrimitive(input,hint){if("object"!==_typeof(input)||null===input)return input;var prim=input[Symbol.toPrimitive];if(prim!==void 0){var res=prim.call(input,hint||"default");if("object"!==_typeof(res))return res;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===hint?String:Number)(input)}function _objectWithoutProperties(source,excluded){if(null==source)return{};var key,i,target=_objectWithoutPropertiesLoose(source,excluded);if(Object.getOwnPropertySymbols){var sourceSymbolKeys=Object.getOwnPropertySymbols(source);for(i=0;i<sourceSymbolKeys.length;i++)key=sourceSymbolKeys[i],0<=excluded.indexOf(key)||Object.prototype.propertyIsEnumerable.call(source,key)&&(target[key]=source[key])}return target}function _objectWithoutPropertiesLoose(source,excluded){if(null==source)return{};var key,i,target={},sourceKeys=Object.keys(source);for(i=0;i<sourceKeys.length;i++)key=sourceKeys[i],0<=excluded.indexOf(key)||(target[key]=source[key]);return target}function CarouselSlideContainer(_ref){var _ref$gap=_ref.gap,gap=void 0===_ref$gap?16:_ref$gap,hideArrowButtons=_ref.hideArrowButtons,children=_ref.children,buttonShadow=_ref.buttonShadow,leftButton=_ref.leftButton,rightButton=_ref.rightButton,divProps=_objectWithoutProperties(_ref,_excluded),carouselCtx=(0,_react.useContext)(_carouselContext.CarouselContext),customLeftButton=null===leftButton||void 0===leftButton?void 0:leftButton(function(){return carouselCtx.moveCarousel("left")}),customRightButton=null===rightButton||void 0===rightButton?void 0:rightButton(function(){return carouselCtx.moveCarousel("right")}),_onScroll=divProps.onScroll,containerProps=_objectWithoutProperties(divProps,_excluded2);return/*#__PURE__*/(0,_jsxRuntime.jsxs)("div",_objectSpread(_objectSpread({style:{position:"relative",overflow:"hidden",width:"100%",height:"100%"}},containerProps),{},{children:[/*#__PURE__*/(0,_jsxRuntime.jsx)(_styles.SliderContainer,{ref:carouselCtx.sliderRef,onTouchMove:function onTouchMove(){carouselCtx.hideLeftButton(!0),carouselCtx.hideRightButton(!0)},onTouchStart:carouselCtx.handleEnter,onTouchEnd:carouselCtx.beginMomentumTracking,className:"slider_container",style:{gap:gap+"px"},onMouseDown:carouselCtx.handleMouseDown,onMouseUp:carouselCtx.handleMouseUp,onMouseMove:carouselCtx.handleMouseMove,onMouseEnter:carouselCtx.handleEnter,onMouseLeave:carouselCtx.handleMouseLeave,onWheel:carouselCtx.handleWheel,onScroll:function onScroll(event){null===_onScroll||void 0===_onScroll?void 0:_onScroll(event),carouselCtx.handleScroll(event)},children:children}),!hideArrowButtons&&/*#__PURE__*/(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[/*#__PURE__*/(0,_jsxRuntime.jsx)(_styles.ContainerButton,{className:(0,_classnames.default)("left_button hide",{button_shadow:buttonShadow}),onMouseLeave:carouselCtx.handleMouseLeave,"aria-disabled":1===carouselCtx.currentActive,onMouseEnter:carouselCtx.handleEnter,ref:carouselCtx.leftButtonRef,children:customLeftButton}),/*#__PURE__*/(0,_jsxRuntime.jsx)(_styles.ContainerButton,{className:(0,_classnames.default)("right_button",{button_shadow:buttonShadow}),"aria-disabled":carouselCtx.itemsHasNoOverflow,onMouseLeave:carouselCtx.handleMouseLeave,onMouseEnter:carouselCtx.handleEnter,ref:carouselCtx.rightButtonRef,children:customRightButton})]})]}))}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/Input/styles.ts"],"names":[],"mappings":";AAKA,OAAO,EAAE,mBAAmB,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,eAAO,MAAM,iBAAiB;;;;;;yGAsG7B,CAAC;AAEF,eAAO,MAAM,WAAW;;;yGAQvB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;yGAKxB,CAAC;AAEF,eAAO,MAAM,eAAe;;;yGAK3B,CAAC;AAEF,eAAO,MAAM,SAAS;;;;;yGAUrB,CAAC;AAQF,eAAO,MAAM,KAAK;;;+HA8BjB,CAAC;AAEF,eAAO,MAAM,UAAU;;;;;;kHAkBtB,CAAC;AAEF,eAAO,MAAM,QAAQ;;;;;2HAsCpB,CAAC;AAEF,eAAO,MAAM,MAAM;;;+GAQlB,CAAC;AAEF,eAAO,MAAM,UAAU;;;2GAItB,CAAC;AAEF,eAAO,MAAM,UAAU;;;
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../src/components/Input/styles.ts"],"names":[],"mappings":";AAKA,OAAO,EAAE,mBAAmB,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,eAAO,MAAM,iBAAiB;;;;;;yGAsG7B,CAAC;AAEF,eAAO,MAAM,WAAW;;;yGAQvB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;yGAKxB,CAAC;AAEF,eAAO,MAAM,eAAe;;;yGAK3B,CAAC;AAEF,eAAO,MAAM,SAAS;;;;;yGAUrB,CAAC;AAQF,eAAO,MAAM,KAAK;;;+HA8BjB,CAAC;AAEF,eAAO,MAAM,UAAU;;;;;;kHAkBtB,CAAC;AAEF,eAAO,MAAM,QAAQ;;;;;2HAsCpB,CAAC;AAEF,eAAO,MAAM,MAAM;;;+GAQlB,CAAC;AAEF,eAAO,MAAM,UAAU;;;2GAItB,CAAC;AAEF,eAAO,MAAM,UAAU;;;wHAOtB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;yGAgCxB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.LegendText=exports.Legend=exports.InputLabel=exports.InputIcon=exports.InputGroupElement=exports.InputContentRow=exports.InputContent=exports.InputColumn=exports.Input=exports.HelperText=exports.Fieldset=exports.AddonElement=void 0;var _templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9,_templateObject10,_templateObject11,_templateObject12,_templateObject13,_styled=_interopRequireDefault(require("@emotion/styled")),_react=require("@emotion/react"),_invertColor=require("../../utils//invertColor");function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _taggedTemplateLiteral(strings,raw){return raw||(raw=strings.slice(0)),Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}))}var InputGroupElement=_styled.default.div(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n width: 100%;\n border-radius: ",";\n font-weight: ",";\n transition: all 0.2s ease-in-out;\n\n &:hover fieldset {\n border-color: ",";\n }\n\n &:hover > div > div:first-of-type {\n border-color: ",";\n &:hover label {\n color: ",";\n }\n }\n\n &:focus-within > div > div:first-of-type {\n background: ",";\n border-color: ",";\n }\n\n > div > div:first-of-type span {\n color: ",";\n }\n\n &:focus-within {\n border-radius: 2px solid ",";\n }\n &:focus-within label {\n color: ",";\n }\n\n &:focus-within > div {\n box-shadow: 0 0 0 2px\n ",";\n }\n\n &:focus-within label {\n transform: translate(19px, -11px) scale(0.8);\n\n background-color: ",";\n\n height: 20px;\n }\n\n &:focus-within fieldset {\n border-width: 2px;\n border-color: ",";\n }\n\n ","\n\n & label {\n transform: ",";\n height: ",";\n background: ",";\n }\n"])),function(props){return props.theme.borderRadius.default},function(props){return props.theme.fontWeight[400]},function(_ref){var theme=_ref.theme,alert=_ref.alert,hasDisabled=_ref.hasDisabled;return alert&&!hasDisabled?theme.colors[alert].default+"66":hasDisabled?"none":theme.colors.primary.hover},function(_ref2){var theme=_ref2.theme,alert=_ref2.alert,hasDisabled=_ref2.hasDisabled;return alert&&!hasDisabled?theme.colors[alert].default+"66":hasDisabled?"none":theme.colors.primary.hover},function(_ref3){var theme=_ref3.theme,hasDisabled=_ref3.hasDisabled;return!hasDisabled&&theme.colors.neutral.neutral5},function(props){return!props.alert&&props.withAddon&&props.theme.colors.primary.disabled},function(props){return!props.alert&&props.withAddon&&props.theme.colors.primary.hover},function(props){return props.alert?(0,_invertColor.invertColor)(props.theme.colors[props.alert].default,!0):props.theme.colors.neutral.black},function(props){return props.theme.colors.primary.disabled},function(_ref4){var theme=_ref4.theme;return theme.colors.neutral.neutral5},function(props){return props.alert?"".concat(props.theme.colors[props.alert].blurred,"33"):props.theme.colors.primary.disabled},function(_ref5){var theme=_ref5.theme;return theme.colors.neutral.white},function(props){return!props.alert&&props.theme.colors.primary.hover},function(props){return props.addonContent&&(0,_react.css)(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["\n &:focus-within > div > div:first-of-type {\n border-color: ",";\n background-color: ",";\n }\n "])),props.alert?"transparent":props.theme.colors.primary.focus,props.alert&&"success"===props.alert?props.theme.colors.primary.focus:"")},function(_ref6){var hasValueOnInput=_ref6.hasValueOnInput,withIcon=_ref6.withIcon;return hasValueOnInput?"translate(19px, -11px) scale(0.8) !important":withIcon?"translate(60px, calc(100% - 10px))":"translate(20px, calc(100% - 10px))"},function(_ref7){var hasValueOnInput=_ref7.hasValueOnInput;return hasValueOnInput?"20px":"unset"},function(_ref8){var hasValueOnInput=_ref8.hasValueOnInput,theme=_ref8.theme;return hasValueOnInput?theme.colors.neutral.white:"transparent"});exports.InputGroupElement=InputGroupElement;var InputColumn=_styled.default.div(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n position: relative;\n display: grid;\n grid-template-columns: repeat(12, 1fr);\n align-items: center;\n border-radius: ",";\n width: 100%;\n min-height: 56px;\n"])),function(props){return props.theme.borderRadius.default});exports.InputColumn=InputColumn;var InputContent=_styled.default.div(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n width: 100%;\n position: relative;\n grid-column: ",";\n height: 100%;\n"])),function(props){return props.withAddon?"2 / end":"1 / end"});exports.InputContent=InputContent;var InputContentRow=_styled.default.div(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n display: flex;\n position: relative;\n align-items: center;\n height: 100%;\n"])));exports.InputContentRow=InputContentRow;var InputIcon=_styled.default.div(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n position: relative;\n z-index: ",";\n display: flex;\n margin: auto;\n padding: 0 20px;\n align-items: center;\n justify-content: center;\n cursor: ",";\n color: ",";\n"])),function(props){return props.theme.zIndex.level1},function(props){return props.clickable?"pointer":"default"},function(props){return props.theme.colors.neutral.neutral5});exports.InputIcon=InputIcon;function inputPadding(props){var leftIcon=props.leftIcon,withIcon=props.withIcon;return leftIcon||withIcon?"0 0":"0 20px"}var Input=_styled.default.input(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n width: 100%;\n padding: ",";\n flex: 1;\n height: 100%;\n border: none;\n color: ",";\n &:disabled {\n color: ",";\n }\n\n &::placeholder {\n color: ",";\n }\n\n font-family: inherit;\n outline: none;\n font-size: ",";\n background-color: transparent;\n position: relative;\n font-weight: 500;\n\n &:-webkit-autofill {\n height: calc(100% - 4px);\n margin-right: 2px;\n border-top-right-radius: 0.35rem;\n border-bottom-right-radius: 0.35rem;\n -webkit-box-shadow: 0 0 0 100px "," inset;\n -webkit-text-fill-color: ",";\n }\n"])),inputPadding,function(props){return props.theme.colors.neutral.black},function(_ref9){var theme=_ref9.theme;return theme.colors.neutral.neutral5},function(_ref10){var theme=_ref10.theme;return theme.colors.neutral.neutral4},function(props){return props.theme.fontSizes.xs},function(_ref11){var theme=_ref11.theme;return theme.colorByTheme("#f8faf9","#465953")},function(_ref12){var theme=_ref12.theme;return theme.colors.neutral.black});exports.Input=Input;var InputLabel=_styled.default.label(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["\n top: 0;\n left: 0;\n height: auto;\n padding: 0 6px;\n position: absolute;\n z-index: ",";\n pointer-events: none;\n color: ",";\n background-color: transparent;\n transform-origin: left;\n transition: all ease 0.2s;\n font-weight: 500;\n\n white-space: nowrap;\n max-width: ",";\n overflow: hidden;\n text-overflow: ellipsis;\n"])),function(props){return props.theme.zIndex.level1},function(props){return props.theme.colors.neutral.neutral3},function(_ref13){var withIcon=_ref13.withIcon;return withIcon?"65%":"85%"});exports.InputLabel=InputLabel;var Fieldset=_styled.default.fieldset(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n margin: 0;\n top: 0;\n pointer-events: none;\n padding: 0 17px;\n overflow: hidden;\n\n background-color: ",";\n\n border-radius: ",";\n border: 2px solid\n ",";\n border-left: ",";\n\n transition: all 0.2s ease;\n"])),function(_ref14){var alert=_ref14.alert,theme=_ref14.theme,hasDisabled=_ref14.hasDisabled;return alert&&!hasDisabled?"".concat(theme.colors[alert].blurred,"33"):hasDisabled?theme.colors.neutral.neutral1:"transparent"},function(props){return props.withAddon?"0 ".concat(props.theme.borderRadius.default," ").concat(props.theme.borderRadius.default," 0"):props.theme.borderRadius.default},function(_ref15){var theme=_ref15.theme,hasDisabled=_ref15.hasDisabled,alert=_ref15.alert;return alert&&!hasDisabled?theme.colors[alert].default:theme.colors.neutral.neutral2},function(props){return props.withAddon?"none !important":"auto"});exports.Fieldset=Fieldset;var Legend=_styled.default.legend(_templateObject10||(_templateObject10=_taggedTemplateLiteral(["\n padding: 0;\n width: auto;\n max-width: 0.01px;\n font-size: 14px;\n height: 0px;\n visibility: hidden;\n transition: all 0.1s;\n"])));exports.Legend=Legend;var LegendText=_styled.default.span(_templateObject11||(_templateObject11=_taggedTemplateLiteral(["\n padding: 0 2px;\n display: inline-block;\n visibility: hidden;\n"])));exports.LegendText=LegendText;var HelperText=_styled.default.span(_templateObject12||(_templateObject12=_taggedTemplateLiteral(["\n font-size: ",";\n\n color: ",";\n padding: 0 20px;\n"])),function(props){return props.theme.fontSizes.xxs},function(props){return props.alert&&"success"!==props.alert?props.theme.colors[props.alert].default:props.theme.colors.neutral.neutral4});exports.HelperText=HelperText;var AddonElement=_styled.default.div(_templateObject13||(_templateObject13=_taggedTemplateLiteral(["\n padding: 0 20px;\n height: 100%;\n\n background-color: ",";\n\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.2s ease;\n border: 2px solid\n ",";\n border-right: none;\n\n border-radius: "," 0 0\n ",";\n"])),function(props){return props.alert&&!props.hasDisabled?props.theme.colors[props.alert].default:props.hasDisabled?props.theme.colors.neutral.neutral2:props.theme.colors.neutral.neutral1},function(_ref16){var theme=_ref16.theme,hasDisabled=_ref16.hasDisabled,alert=_ref16.alert;return alert&&!hasDisabled?theme.colors[alert].default:theme.colors.neutral.neutral2},function(props){return props.theme.borderRadius.default},function(props){return props.theme.borderRadius.default});exports.AddonElement=AddonElement;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.LegendText=exports.Legend=exports.InputLabel=exports.InputIcon=exports.InputGroupElement=exports.InputContentRow=exports.InputContent=exports.InputColumn=exports.Input=exports.HelperText=exports.Fieldset=exports.AddonElement=void 0;var _templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,_templateObject8,_templateObject9,_templateObject10,_templateObject11,_templateObject12,_templateObject13,_styled=_interopRequireDefault(require("@emotion/styled")),_react=require("@emotion/react"),_invertColor=require("../../utils//invertColor");function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _taggedTemplateLiteral(strings,raw){return raw||(raw=strings.slice(0)),Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}))}var InputGroupElement=_styled.default.div(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n width: 100%;\n border-radius: ",";\n font-weight: ",";\n transition: all 0.2s ease-in-out;\n\n &:hover fieldset {\n border-color: ",";\n }\n\n &:hover > div > div:first-of-type {\n border-color: ",";\n &:hover label {\n color: ",";\n }\n }\n\n &:focus-within > div > div:first-of-type {\n background: ",";\n border-color: ",";\n }\n\n > div > div:first-of-type span {\n color: ",";\n }\n\n &:focus-within {\n border-radius: 2px solid ",";\n }\n &:focus-within label {\n color: ",";\n }\n\n &:focus-within > div {\n box-shadow: 0 0 0 2px\n ",";\n }\n\n &:focus-within label {\n transform: translate(19px, -11px) scale(0.8);\n\n background-color: ",";\n\n height: 20px;\n }\n\n &:focus-within fieldset {\n border-width: 2px;\n border-color: ",";\n }\n\n ","\n\n & label {\n transform: ",";\n height: ",";\n background: ",";\n }\n"])),function(props){return props.theme.borderRadius.default},function(props){return props.theme.fontWeight[400]},function(_ref){var theme=_ref.theme,alert=_ref.alert,hasDisabled=_ref.hasDisabled;return alert&&!hasDisabled?theme.colors[alert].default+"66":hasDisabled?"none":theme.colors.primary.hover},function(_ref2){var theme=_ref2.theme,alert=_ref2.alert,hasDisabled=_ref2.hasDisabled;return alert&&!hasDisabled?theme.colors[alert].default+"66":hasDisabled?"none":theme.colors.primary.hover},function(_ref3){var theme=_ref3.theme,hasDisabled=_ref3.hasDisabled;return!hasDisabled&&theme.colors.neutral.neutral5},function(props){return!props.alert&&props.withAddon&&props.theme.colors.primary.disabled},function(props){return!props.alert&&props.withAddon&&props.theme.colors.primary.hover},function(props){return props.alert?(0,_invertColor.invertColor)(props.theme.colors[props.alert].default,!0):props.theme.colors.neutral.black},function(props){return props.theme.colors.primary.disabled},function(_ref4){var theme=_ref4.theme;return theme.colors.neutral.neutral5},function(props){return props.alert?"".concat(props.theme.colors[props.alert].blurred,"33"):props.theme.colors.primary.disabled},function(_ref5){var theme=_ref5.theme;return theme.colors.neutral.white},function(props){return!props.alert&&props.theme.colors.primary.hover},function(props){return props.addonContent&&(0,_react.css)(_templateObject2||(_templateObject2=_taggedTemplateLiteral(["\n &:focus-within > div > div:first-of-type {\n border-color: ",";\n background-color: ",";\n }\n "])),props.alert?"transparent":props.theme.colors.primary.focus,props.alert&&"success"===props.alert?props.theme.colors.primary.focus:"")},function(_ref6){var hasValueOnInput=_ref6.hasValueOnInput,withIcon=_ref6.withIcon;return hasValueOnInput?"translate(19px, -11px) scale(0.8) !important":withIcon?"translate(60px, calc(100% - 10px))":"translate(20px, calc(100% - 10px))"},function(_ref7){var hasValueOnInput=_ref7.hasValueOnInput;return hasValueOnInput?"20px":"unset"},function(_ref8){var hasValueOnInput=_ref8.hasValueOnInput,theme=_ref8.theme;return hasValueOnInput?theme.colors.neutral.white:"transparent"});exports.InputGroupElement=InputGroupElement;var InputColumn=_styled.default.div(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n position: relative;\n display: grid;\n grid-template-columns: repeat(12, 1fr);\n align-items: center;\n border-radius: ",";\n width: 100%;\n min-height: 56px;\n"])),function(props){return props.theme.borderRadius.default});exports.InputColumn=InputColumn;var InputContent=_styled.default.div(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["\n width: 100%;\n position: relative;\n grid-column: ",";\n height: 100%;\n"])),function(props){return props.withAddon?"2 / end":"1 / end"});exports.InputContent=InputContent;var InputContentRow=_styled.default.div(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["\n display: flex;\n position: relative;\n align-items: center;\n height: 100%;\n"])));exports.InputContentRow=InputContentRow;var InputIcon=_styled.default.div(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n position: relative;\n z-index: ",";\n display: flex;\n margin: auto;\n padding: 0 20px;\n align-items: center;\n justify-content: center;\n cursor: ",";\n color: ",";\n"])),function(props){return props.theme.zIndex.level1},function(props){return props.clickable?"pointer":"default"},function(props){return props.theme.colors.neutral.neutral5});exports.InputIcon=InputIcon;function inputPadding(props){var leftIcon=props.leftIcon,withIcon=props.withIcon;return leftIcon||withIcon?"0 0":"0 20px"}var Input=_styled.default.input(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n width: 100%;\n padding: ",";\n flex: 1;\n height: 100%;\n border: none;\n color: ",";\n &:disabled {\n color: ",";\n }\n\n &::placeholder {\n color: ",";\n }\n\n font-family: inherit;\n outline: none;\n font-size: ",";\n background-color: transparent;\n position: relative;\n font-weight: 500;\n\n &:-webkit-autofill {\n height: calc(100% - 4px);\n margin-right: 2px;\n border-top-right-radius: 0.35rem;\n border-bottom-right-radius: 0.35rem;\n -webkit-box-shadow: 0 0 0 100px "," inset;\n -webkit-text-fill-color: ",";\n }\n"])),inputPadding,function(props){return props.theme.colors.neutral.black},function(_ref9){var theme=_ref9.theme;return theme.colors.neutral.neutral5},function(_ref10){var theme=_ref10.theme;return theme.colors.neutral.neutral4},function(props){return props.theme.fontSizes.xs},function(_ref11){var theme=_ref11.theme;return theme.colorByTheme("#f8faf9","#465953")},function(_ref12){var theme=_ref12.theme;return theme.colors.neutral.black});exports.Input=Input;var InputLabel=_styled.default.label(_templateObject8||(_templateObject8=_taggedTemplateLiteral(["\n top: 0;\n left: 0;\n height: auto;\n padding: 0 6px;\n position: absolute;\n z-index: ",";\n pointer-events: none;\n color: ",";\n background-color: transparent;\n transform-origin: left;\n transition: all ease 0.2s;\n font-weight: 500;\n\n white-space: nowrap;\n max-width: ",";\n overflow: hidden;\n text-overflow: ellipsis;\n"])),function(props){return props.theme.zIndex.level1},function(props){return props.theme.colors.neutral.neutral3},function(_ref13){var withIcon=_ref13.withIcon;return withIcon?"65%":"85%"});exports.InputLabel=InputLabel;var Fieldset=_styled.default.fieldset(_templateObject9||(_templateObject9=_taggedTemplateLiteral(["\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n margin: 0;\n top: 0;\n pointer-events: none;\n padding: 0 17px;\n overflow: hidden;\n\n background-color: ",";\n\n border-radius: ",";\n border: 2px solid\n ",";\n border-left: ",";\n\n transition: all 0.2s ease;\n"])),function(_ref14){var alert=_ref14.alert,theme=_ref14.theme,hasDisabled=_ref14.hasDisabled;return alert&&!hasDisabled?"".concat(theme.colors[alert].blurred,"33"):hasDisabled?theme.colors.neutral.neutral1:"transparent"},function(props){return props.withAddon?"0 ".concat(props.theme.borderRadius.default," ").concat(props.theme.borderRadius.default," 0"):props.theme.borderRadius.default},function(_ref15){var theme=_ref15.theme,hasDisabled=_ref15.hasDisabled,alert=_ref15.alert;return alert&&!hasDisabled?theme.colors[alert].default:theme.colors.neutral.neutral2},function(props){return props.withAddon?"none !important":"auto"});exports.Fieldset=Fieldset;var Legend=_styled.default.legend(_templateObject10||(_templateObject10=_taggedTemplateLiteral(["\n padding: 0;\n width: auto;\n max-width: 0.01px;\n font-size: 14px;\n height: 0px;\n visibility: hidden;\n transition: all 0.1s;\n"])));exports.Legend=Legend;var LegendText=_styled.default.span(_templateObject11||(_templateObject11=_taggedTemplateLiteral(["\n padding: 0 2px;\n display: inline-block;\n visibility: hidden;\n"])));exports.LegendText=LegendText;var HelperText=_styled.default.span(_templateObject12||(_templateObject12=_taggedTemplateLiteral(["\n font-size: ",";\n\n color: ",";\n"])),function(props){return props.theme.fontSizes.xxs},function(props){return props.alert&&"success"!==props.alert?props.theme.colors[props.alert].default:props.theme.colors.neutral.neutral4});exports.HelperText=HelperText;var AddonElement=_styled.default.div(_templateObject13||(_templateObject13=_taggedTemplateLiteral(["\n padding: 0 20px;\n height: 100%;\n\n background-color: ",";\n\n display: flex;\n align-items: center;\n justify-content: center;\n transition: all 0.2s ease;\n border: 2px solid\n ",";\n border-right: none;\n\n border-radius: "," 0 0\n ",";\n"])),function(props){return props.alert&&!props.hasDisabled?props.theme.colors[props.alert].default:props.hasDisabled?props.theme.colors.neutral.neutral2:props.theme.colors.neutral.neutral1},function(_ref16){var theme=_ref16.theme,hasDisabled=_ref16.hasDisabled,alert=_ref16.alert;return alert&&!hasDisabled?theme.colors[alert].default:theme.colors.neutral.neutral2},function(props){return props.theme.borderRadius.default},function(props){return props.theme.borderRadius.default});exports.AddonElement=AddonElement;
|